diff --git a/dist/index.js b/dist/index.js index bd61313d..c06bf3bf 100644 --- a/dist/index.js +++ b/dist/index.js @@ -21,7 +21,7 @@ GFS4: `),console.error(e)});bi[Ws]||(RT=global[Ws]||[],kT(bi,RT),bi.close=functi `,finalEOL:s=!0,replacer:p=null,spaces:c}={}){let i=s?t:"";return JSON.stringify(e,p,c).replace(/\n/g,t)+i}function zH(e){return Buffer.isBuffer(e)&&(e=e.toString("utf8")),e.replace(/^\uFEFF/,"")}ZS.exports={stringify:KH,stripBom:zH}});var i7=le((ehe,r7)=>{var Dl;try{Dl=ki()}catch(e){Dl=require("fs")}var zd=Hi(),{stringify:e7,stripBom:t7}=Kd();async function XH(e,t={}){typeof t=="string"&&(t={encoding:t});let s=t.fs||Dl,p="throws"in t?t.throws:!0,c=await zd.fromCallback(s.readFile)(e,t);c=t7(c);let i;try{i=JSON.parse(c,t?t.reviver:null)}catch(d){if(p)throw d.message=`${e}: ${d.message}`,d;return null}return i}var YH=zd.fromPromise(XH);function JH(e,t={}){typeof t=="string"&&(t={encoding:t});let s=t.fs||Dl,p="throws"in t?t.throws:!0;try{let c=s.readFileSync(e,t);return c=t7(c),JSON.parse(c,t.reviver)}catch(c){if(p)throw c.message=`${e}: ${c.message}`,c;return null}}async function QH(e,t,s={}){let p=s.fs||Dl,c=e7(t,s);await zd.fromCallback(p.writeFile)(e,c,s)}var ZH=zd.fromPromise(QH);function eW(e,t,s={}){let p=s.fs||Dl,c=e7(t,s);return p.writeFileSync(e,c,s)}var tW={readFile:YH,readFileSync:JH,writeFile:ZH,writeFileSync:eW};r7.exports=tW});var n7=le((the,s7)=>{"use strict";var Xd=i7();s7.exports={readJson:Xd.readFile,readJsonSync:Xd.readFileSync,writeJson:Xd.writeFile,writeJsonSync:Xd.writeFileSync}});var Yd=le((rhe,l7)=>{"use strict";var rW=Hi().fromCallback,cp=ki(),a7=require("path"),o7=Ks(),iW=xa().pathExists;function sW(e,t,s,p){typeof s=="function"&&(p=s,s="utf8");let c=a7.dirname(e);iW(c,(i,d)=>{if(i)return p(i);if(d)return cp.writeFile(e,t,s,p);o7.mkdirs(c,a=>{if(a)return p(a);cp.writeFile(e,t,s,p)})})}function nW(e,...t){let s=a7.dirname(e);if(cp.existsSync(s))return cp.writeFileSync(e,...t);o7.mkdirsSync(s),cp.writeFileSync(e,...t)}l7.exports={outputFile:rW(sW),outputFileSync:nW}});var p7=le((ihe,u7)=>{"use strict";var{stringify:aW}=Kd(),{outputFile:oW}=Yd();async function lW(e,t,s={}){let p=aW(t,s);await oW(e,p,s)}u7.exports=lW});var d7=le((she,c7)=>{"use strict";var{stringify:uW}=Kd(),{outputFileSync:pW}=Yd();function cW(e,t,s){let p=uW(t,s);pW(e,p,s)}c7.exports=cW});var f7=le((nhe,h7)=>{"use strict";var dW=Hi().fromPromise,Ri=n7();Ri.outputJson=dW(p7());Ri.outputJsonSync=d7();Ri.outputJSON=Ri.outputJson;Ri.outputJSONSync=Ri.outputJsonSync;Ri.writeJSON=Ri.writeJson;Ri.writeJSONSync=Ri.writeJsonSync;Ri.readJSON=Ri.readJson;Ri.readJSONSync=Ri.readJsonSync;h7.exports=Ri});var v7=le((ahe,b7)=>{"use strict";var m7=ki(),u0=require("path"),hW=a0().copySync,y7=up().removeSync,fW=Ks().mkdirpSync,g7=fo();function mW(e,t,s){s=s||{};let p=s.overwrite||s.clobber||!1,{srcStat:c,isChangingCase:i=!1}=g7.checkPathsSync(e,t,"move",s);return g7.checkParentPathsSync(e,c,t,"move"),yW(t)||fW(u0.dirname(t)),gW(e,t,p,i)}function yW(e){let t=u0.dirname(e);return u0.parse(t).root===t}function gW(e,t,s,p){if(p)return p0(e,t,s);if(s)return y7(t),p0(e,t,s);if(m7.existsSync(t))throw new Error("dest already exists.");return p0(e,t,s)}function p0(e,t,s){try{m7.renameSync(e,t)}catch(p){if(p.code!=="EXDEV")throw p;return bW(e,t,s)}}function bW(e,t,s){return hW(e,t,{overwrite:s,errorOnExist:!0}),y7(e)}b7.exports=mW});var T7=le((ohe,E7)=>{"use strict";E7.exports={moveSync:v7()}});var x7=le((lhe,P7)=>{"use strict";var vW=ki(),c0=require("path"),EW=o0().copy,S7=up().remove,TW=Ks().mkdirp,SW=xa().pathExists,w7=fo();function wW(e,t,s,p){typeof s=="function"&&(p=s,s={});let c=s.overwrite||s.clobber||!1;w7.checkPaths(e,t,"move",s,(i,d)=>{if(i)return p(i);let{srcStat:a,isChangingCase:o=!1}=d;w7.checkParentPaths(e,a,t,"move",n=>{if(n)return p(n);if(_W(t))return _7(e,t,c,o,p);TW(c0.dirname(t),l=>l?p(l):_7(e,t,c,o,p))})})}function _W(e){let t=c0.dirname(e);return c0.parse(t).root===t}function _7(e,t,s,p,c){if(p)return d0(e,t,s,c);if(s)return S7(t,i=>i?c(i):d0(e,t,s,c));SW(t,(i,d)=>i?c(i):d?c(new Error("dest already exists.")):d0(e,t,s,c))}function d0(e,t,s,p){vW.rename(e,t,c=>c?c.code!=="EXDEV"?p(c):PW(e,t,s,p):p())}function PW(e,t,s,p){EW(e,t,{overwrite:s,errorOnExist:!0},i=>i?p(i):S7(e,p))}P7.exports=wW});var C7=le((uhe,A7)=>{"use strict";var xW=Hi().fromCallback;A7.exports={move:xW(x7())}});var Jd=le((phe,I7)=>{"use strict";I7.exports=Tt(Tt(Tt(Tt(Tt(Tt(Tt(Tt(Tt(Tt(Tt(Tt({},ho()),a0()),o0()),CS()),QS()),f7()),Ks()),T7()),C7()),Yd()),xa()),up())});var h0=le(cr=>{"use strict";var Qd=cr&&cr.__awaiter||function(e,t,s,p){function c(i){return i instanceof s?i:new s(function(d){d(i)})}return new(s||(s=Promise))(function(i,d){function a(l){try{n(p.next(l))}catch(g){d(g)}}function o(l){try{n(p.throw(l))}catch(g){d(g)}}function n(l){l.done?i(l.value):c(l.value).then(a,o)}n((p=p.apply(e,t||[])).next())})},Ss;Object.defineProperty(cr,"__esModule",{value:!0});var AW=require("assert"),CW=require("fs"),kl=require("path");Ss=CW.promises,cr.chmod=Ss.chmod,cr.copyFile=Ss.copyFile,cr.lstat=Ss.lstat,cr.mkdir=Ss.mkdir,cr.readdir=Ss.readdir,cr.readlink=Ss.readlink,cr.rename=Ss.rename,cr.rmdir=Ss.rmdir,cr.stat=Ss.stat,cr.symlink=Ss.symlink,cr.unlink=Ss.unlink;cr.IS_WINDOWS=process.platform==="win32";function IW(e){return Qd(this,void 0,void 0,function*(){try{yield cr.stat(e)}catch(t){if(t.code==="ENOENT")return!1;throw t}return!0})}cr.exists=IW;function NW(e,t=!1){return Qd(this,void 0,void 0,function*(){return(t?yield cr.stat(e):yield cr.lstat(e)).isDirectory()})}cr.isDirectory=NW;function OW(e){if(e=kW(e),!e)throw new Error('isRooted() parameter "p" cannot be empty');return cr.IS_WINDOWS?e.startsWith("\\")||/^[A-Z]:/i.test(e):e.startsWith("/")}cr.isRooted=OW;function k7(e,t=1e3,s=1){return Qd(this,void 0,void 0,function*(){if(AW.ok(e,"a path argument must be provided"),e=kl.resolve(e),s>=t)return cr.mkdir(e);try{yield cr.mkdir(e);return}catch(p){switch(p.code){case"ENOENT":{yield k7(kl.dirname(e),t,s+1),yield cr.mkdir(e);return}default:{let c;try{c=yield cr.stat(e)}catch(i){throw p}if(!c.isDirectory())throw p}}}})}cr.mkdirP=k7;function DW(e,t){return Qd(this,void 0,void 0,function*(){let s;try{s=yield cr.stat(e)}catch(c){c.code!=="ENOENT"&&console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${c}`)}if(s&&s.isFile()){if(cr.IS_WINDOWS){let c=kl.extname(e).toUpperCase();if(t.some(i=>i.toUpperCase()===c))return e}else if(R7(s))return e}let p=e;for(let c of t){e=p+c,s=void 0;try{s=yield cr.stat(e)}catch(i){i.code!=="ENOENT"&&console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${i}`)}if(s&&s.isFile()){if(cr.IS_WINDOWS){try{let i=kl.dirname(e),d=kl.basename(e).toUpperCase();for(let a of yield cr.readdir(i))if(d===a.toUpperCase()){e=kl.join(i,a);break}}catch(i){console.log(`Unexpected error attempting to determine the actual case of the file '${e}': ${i}`)}return e}else if(R7(s))return e}}return""})}cr.tryGetExecutablePath=DW;function kW(e){return e=e||"",cr.IS_WINDOWS?(e=e.replace(/\//g,"\\"),e.replace(/\\\\+/g,"\\")):e.replace(/\/\/+/g,"/")}function R7(e){return(e.mode&1)>0||(e.mode&8)>0&&e.gid===process.getgid()||(e.mode&64)>0&&e.uid===process.getuid()}});var B7=le(zn=>{"use strict";var mo=zn&&zn.__awaiter||function(e,t,s,p){function c(i){return i instanceof s?i:new s(function(d){d(i)})}return new(s||(s=Promise))(function(i,d){function a(l){try{n(p.next(l))}catch(g){d(g)}}function o(l){try{n(p.throw(l))}catch(g){d(g)}}function n(l){l.done?i(l.value):c(l.value).then(a,o)}n((p=p.apply(e,t||[])).next())})};Object.defineProperty(zn,"__esModule",{value:!0});var RW=require("child_process"),Kn=require("path"),LW=require("util"),fr=h0(),f0=LW.promisify(RW.exec);function FW(e,t,s={}){return mo(this,void 0,void 0,function*(){let{force:p,recursive:c}=MW(s),i=(yield fr.exists(t))?yield fr.stat(t):null;if(i&&i.isFile()&&!p)return;let d=i&&i.isDirectory()?Kn.join(t,Kn.basename(e)):t;if(!(yield fr.exists(e)))throw new Error(`no such file or directory: ${e}`);if((yield fr.stat(e)).isDirectory())if(c)yield j7(e,d,0,p);else throw new Error(`Failed to copy. ${e} is a directory, but tried to copy without recursive flag.`);else{if(Kn.relative(e,d)==="")throw new Error(`'${d}' and '${e}' are the same file`);yield M7(e,d,p)}})}zn.cp=FW;function jW(e,t,s={}){return mo(this,void 0,void 0,function*(){if(yield fr.exists(t)){let p=!0;if((yield fr.isDirectory(t))&&(t=Kn.join(t,Kn.basename(e)),p=yield fr.exists(t)),p)if(s.force==null||s.force)yield L7(t);else throw new Error("Destination already exists")}yield m0(Kn.dirname(t)),yield fr.rename(e,t)})}zn.mv=jW;function L7(e){return mo(this,void 0,void 0,function*(){if(fr.IS_WINDOWS){try{(yield fr.isDirectory(e,!0))?yield f0(`rd /s /q "${e}"`):yield f0(`del /f /a "${e}"`)}catch(t){if(t.code!=="ENOENT")throw t}try{yield fr.unlink(e)}catch(t){if(t.code!=="ENOENT")throw t}}else{let t=!1;try{t=yield fr.isDirectory(e)}catch(s){if(s.code!=="ENOENT")throw s;return}t?yield f0(`rm -rf "${e}"`):yield fr.unlink(e)}})}zn.rmRF=L7;function m0(e){return mo(this,void 0,void 0,function*(){yield fr.mkdirP(e)})}zn.mkdirP=m0;function F7(e,t){return mo(this,void 0,void 0,function*(){if(!e)throw new Error("parameter 'tool' is required");if(t&&!(yield F7(e,!1)))throw fr.IS_WINDOWS?new Error(`Unable to locate executable file: ${e}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also verify the file has a valid extension for an executable file.`):new Error(`Unable to locate executable file: ${e}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also check the file mode to verify the file is executable.`);try{let s=[];if(fr.IS_WINDOWS&&process.env.PATHEXT)for(let c of process.env.PATHEXT.split(Kn.delimiter))c&&s.push(c);if(fr.isRooted(e)){let c=yield fr.tryGetExecutablePath(e,s);return c||""}if(e.includes("/")||fr.IS_WINDOWS&&e.includes("\\"))return"";let p=[];if(process.env.PATH)for(let c of process.env.PATH.split(Kn.delimiter))c&&p.push(c);for(let c of p){let i=yield fr.tryGetExecutablePath(c+Kn.sep+e,s);if(i)return i}return""}catch(s){throw new Error(`which failed with message ${s.message}`)}})}zn.which=F7;function MW(e){let t=e.force==null?!0:e.force,s=Boolean(e.recursive);return{force:t,recursive:s}}function j7(e,t,s,p){return mo(this,void 0,void 0,function*(){if(s>=255)return;s++,yield m0(t);let c=yield fr.readdir(e);for(let i of c){let d=`${e}/${i}`,a=`${t}/${i}`;(yield fr.lstat(d)).isDirectory()?yield j7(d,a,s,p):yield M7(d,a,p)}yield fr.chmod(t,(yield fr.stat(e)).mode)})}function M7(e,t,s){return mo(this,void 0,void 0,function*(){if((yield fr.lstat(e)).isSymbolicLink()){try{yield fr.lstat(t),yield fr.unlink(t)}catch(c){c.code==="EPERM"&&(yield fr.chmod(t,"0666"),yield fr.unlink(t))}let p=yield fr.readlink(e);yield fr.symlink(p,t,fr.IS_WINDOWS?"junction":null)}else(!(yield fr.exists(t))||s)&&(yield fr.copyFile(e,t))})}});var q7=le(Ki=>{"use strict";var BW=Ki&&Ki.__createBinding||(Object.create?function(e,t,s,p){p===void 0&&(p=s),Object.defineProperty(e,p,{enumerable:!0,get:function(){return t[s]}})}:function(e,t,s,p){p===void 0&&(p=s),e[p]=t[s]}),UW=Ki&&Ki.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),Rl=Ki&&Ki.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var s in e)s!=="default"&&Object.hasOwnProperty.call(e,s)&&BW(t,e,s);return UW(t,e),t},U7=Ki&&Ki.__awaiter||function(e,t,s,p){function c(i){return i instanceof s?i:new s(function(d){d(i)})}return new(s||(s=Promise))(function(i,d){function a(l){try{n(p.next(l))}catch(g){d(g)}}function o(l){try{n(p.throw(l))}catch(g){d(g)}}function n(l){l.done?i(l.value):c(l.value).then(a,o)}n((p=p.apply(e,t||[])).next())})};Object.defineProperty(Ki,"__esModule",{value:!0});Ki.argStringToArray=Ki.ToolRunner=void 0;var Zd=Rl(require("os")),V7=Rl(require("events")),VW=Rl(require("child_process")),$W=Rl(require("path")),GW=Rl(B7()),$7=Rl(h0()),qW=require("timers"),eh=process.platform==="win32",G7=class extends V7.EventEmitter{constructor(t,s,p){super();if(!t)throw new Error("Parameter 'toolPath' cannot be null or empty.");this.toolPath=t,this.args=s||[],this.options=p||{}}_debug(t){this.options.listeners&&this.options.listeners.debug&&this.options.listeners.debug(t)}_getCommandString(t,s){let p=this._getSpawnFileName(),c=this._getSpawnArgs(t),i=s?"":"[command]";if(eh)if(this._isCmdFile()){i+=p;for(let d of c)i+=` ${d}`}else if(t.windowsVerbatimArguments){i+=`"${p}"`;for(let d of c)i+=` ${d}`}else{i+=this._windowsQuoteCmdArg(p);for(let d of c)i+=` ${this._windowsQuoteCmdArg(d)}`}else{i+=p;for(let d of c)i+=` ${d}`}return i}_processLineBuffer(t,s,p){try{let c=s+t.toString(),i=c.indexOf(Zd.EOL);for(;i>-1;){let d=c.substring(0,i);p(d),c=c.substring(i+Zd.EOL.length),i=c.indexOf(Zd.EOL)}return c}catch(c){return this._debug(`error processing line. Failed with error ${c}`),""}}_getSpawnFileName(){return eh&&this._isCmdFile()?process.env.COMSPEC||"cmd.exe":this.toolPath}_getSpawnArgs(t){if(eh&&this._isCmdFile()){let s=`/D /S /C "${this._windowsQuoteCmdArg(this.toolPath)}`;for(let p of this.args)s+=" ",s+=t.windowsVerbatimArguments?p:this._windowsQuoteCmdArg(p);return s+='"',[s]}return this.args}_endsWith(t,s){return t.endsWith(s)}_isCmdFile(){let t=this.toolPath.toUpperCase();return this._endsWith(t,".CMD")||this._endsWith(t,".BAT")}_windowsQuoteCmdArg(t){if(!this._isCmdFile())return this._uvQuoteCmdArg(t);if(!t)return'""';let s=[" "," ","&","(",")","[","]","{","}","^","=",";","!","'","+",",","`","~","|","<",">",'"'],p=!1;for(let d of t)if(s.some(a=>a===d)){p=!0;break}if(!p)return t;let c='"',i=!0;for(let d=t.length;d>0;d--)c+=t[d-1],i&&t[d-1]==="\\"?c+="\\":t[d-1]==='"'?(i=!0,c+='"'):i=!1;return c+='"',c.split("").reverse().join("")}_uvQuoteCmdArg(t){if(!t)return'""';if(!t.includes(" ")&&!t.includes(" ")&&!t.includes('"'))return t;if(!t.includes('"')&&!t.includes("\\"))return`"${t}"`;let s='"',p=!0;for(let c=t.length;c>0;c--)s+=t[c-1],p&&t[c-1]==="\\"?s+="\\":t[c-1]==='"'?(p=!0,s+="\\"):p=!1;return s+='"',s.split("").reverse().join("")}_cloneExecOptions(t){t=t||{};let s={cwd:t.cwd||process.cwd(),env:t.env||process.env,silent:t.silent||!1,windowsVerbatimArguments:t.windowsVerbatimArguments||!1,failOnStdErr:t.failOnStdErr||!1,ignoreReturnCode:t.ignoreReturnCode||!1,delay:t.delay||1e4};return s.outStream=t.outStream||process.stdout,s.errStream=t.errStream||process.stderr,s}_getSpawnOptions(t,s){t=t||{};let p={};return p.cwd=t.cwd,p.env=t.env,p.windowsVerbatimArguments=t.windowsVerbatimArguments||this._isCmdFile(),t.windowsVerbatimArguments&&(p.argv0=`"${s}"`),p}exec(){return U7(this,void 0,void 0,function*(){return!$7.isRooted(this.toolPath)&&(this.toolPath.includes("/")||eh&&this.toolPath.includes("\\"))&&(this.toolPath=$W.resolve(process.cwd(),this.options.cwd||process.cwd(),this.toolPath)),this.toolPath=yield GW.which(this.toolPath,!0),new Promise((t,s)=>U7(this,void 0,void 0,function*(){this._debug(`exec tool: ${this.toolPath}`),this._debug("arguments:");for(let n of this.args)this._debug(` ${n}`);let p=this._cloneExecOptions(this.options);!p.silent&&p.outStream&&p.outStream.write(this._getCommandString(p)+Zd.EOL);let c=new th(p,this.toolPath);if(c.on("debug",n=>{this._debug(n)}),this.options.cwd&&!(yield $7.exists(this.options.cwd)))return s(new Error(`The cwd: ${this.options.cwd} does not exist!`));let i=this._getSpawnFileName(),d=VW.spawn(i,this._getSpawnArgs(p),this._getSpawnOptions(this.options,i)),a="";d.stdout&&d.stdout.on("data",n=>{this.options.listeners&&this.options.listeners.stdout&&this.options.listeners.stdout(n),!p.silent&&p.outStream&&p.outStream.write(n),a=this._processLineBuffer(n,a,l=>{this.options.listeners&&this.options.listeners.stdline&&this.options.listeners.stdline(l)})});let o="";if(d.stderr&&d.stderr.on("data",n=>{c.processStderr=!0,this.options.listeners&&this.options.listeners.stderr&&this.options.listeners.stderr(n),!p.silent&&p.errStream&&p.outStream&&(p.failOnStdErr?p.errStream:p.outStream).write(n),o=this._processLineBuffer(n,o,l=>{this.options.listeners&&this.options.listeners.errline&&this.options.listeners.errline(l)})}),d.on("error",n=>{c.processError=n.message,c.processExited=!0,c.processClosed=!0,c.CheckComplete()}),d.on("exit",n=>{c.processExitCode=n,c.processExited=!0,this._debug(`Exit code ${n} received from tool '${this.toolPath}'`),c.CheckComplete()}),d.on("close",n=>{c.processExitCode=n,c.processExited=!0,c.processClosed=!0,this._debug(`STDIO streams have closed for tool '${this.toolPath}'`),c.CheckComplete()}),c.on("done",(n,l)=>{a.length>0&&this.emit("stdline",a),o.length>0&&this.emit("errline",o),d.removeAllListeners(),n?s(n):t(l)}),this.options.input){if(!d.stdin)throw new Error("child process missing stdin");d.stdin.end(this.options.input)}}))})}};Ki.ToolRunner=G7;function HW(e){let t=[],s=!1,p=!1,c="";function i(d){p&&d!=='"'&&(c+="\\"),c+=d,p=!1}for(let d=0;d0&&(t.push(c),c="");continue}i(a)}return c.length>0&&t.push(c.trim()),t}Ki.argStringToArray=HW;var th=class extends V7.EventEmitter{constructor(t,s){super();if(this.processClosed=!1,this.processError="",this.processExitCode=0,this.processExited=!1,this.processStderr=!1,this.delay=1e4,this.done=!1,this.timeout=null,!s)throw new Error("toolPath must not be empty");this.options=t,this.toolPath=s,t.delay&&(this.delay=t.delay)}CheckComplete(){this.done||(this.processClosed?this._setResult():this.processExited&&(this.timeout=qW.setTimeout(th.HandleTimeout,this.delay,this)))}_debug(t){this.emit("debug",t)}_setResult(){let t;this.processExited&&(this.processError?t=new Error(`There was an error when attempting to execute the process '${this.toolPath}'. This may indicate the process failed to start. Error: ${this.processError}`):this.processExitCode!==0&&!this.options.ignoreReturnCode?t=new Error(`The process '${this.toolPath}' failed with exit code ${this.processExitCode}`):this.processStderr&&this.options.failOnStdErr&&(t=new Error(`The process '${this.toolPath}' failed because one or more lines were written to the STDERR stream`))),this.timeout&&(clearTimeout(this.timeout),this.timeout=null),this.done=!0,this.emit("done",t,this.processExitCode)}static HandleTimeout(t){if(!t.done){if(!t.processClosed&&t.processExited){let s=`The STDIO streams did not close within ${t.delay/1e3} seconds of the exit event from process '${t.toolPath}'. This may indicate a child process inherited the STDIO streams and has not yet exited.`;t._debug(s)}t._setResult()}}}});var rh=le(zi=>{"use strict";var WW=zi&&zi.__createBinding||(Object.create?function(e,t,s,p){p===void 0&&(p=s),Object.defineProperty(e,p,{enumerable:!0,get:function(){return t[s]}})}:function(e,t,s,p){p===void 0&&(p=s),e[p]=t[s]}),KW=zi&&zi.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),zW=zi&&zi.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var s in e)s!=="default"&&Object.hasOwnProperty.call(e,s)&&WW(t,e,s);return KW(t,e),t},H7=zi&&zi.__awaiter||function(e,t,s,p){function c(i){return i instanceof s?i:new s(function(d){d(i)})}return new(s||(s=Promise))(function(i,d){function a(l){try{n(p.next(l))}catch(g){d(g)}}function o(l){try{n(p.throw(l))}catch(g){d(g)}}function n(l){l.done?i(l.value):c(l.value).then(a,o)}n((p=p.apply(e,t||[])).next())})};Object.defineProperty(zi,"__esModule",{value:!0});zi.getExecOutput=zi.exec=void 0;var W7=require("string_decoder"),K7=zW(q7());function z7(e,t,s){return H7(this,void 0,void 0,function*(){let p=K7.argStringToArray(e);if(p.length===0)throw new Error("Parameter 'commandLine' cannot be null or empty.");let c=p[0];return t=p.slice(1).concat(t||[]),new K7.ToolRunner(c,t,s).exec()})}zi.exec=z7;function XW(e,t,s){var p,c;return H7(this,void 0,void 0,function*(){let i="",d="",a=new W7.StringDecoder("utf8"),o=new W7.StringDecoder("utf8"),n=(p=s==null?void 0:s.listeners)===null||p===void 0?void 0:p.stdout,l=(c=s==null?void 0:s.listeners)===null||c===void 0?void 0:c.stderr,g=E=>{d+=o.write(E),l&&l(E)},h=E=>{i+=a.write(E),n&&n(E)},m=Object.assign(Object.assign({},s==null?void 0:s.listeners),{stdout:h,stderr:g}),b=yield z7(e,t,Object.assign(Object.assign({},s),{listeners:m}));return i+=a.end(),d+=o.end(),{exitCode:b,stdout:i,stderr:d}})}zi.getExecOutput=XW});var dp=le((She,X7)=>{var YW="2.0.0",JW=256,QW=Number.MAX_SAFE_INTEGER||9007199254740991,ZW=16;X7.exports={SEMVER_SPEC_VERSION:YW,MAX_LENGTH:JW,MAX_SAFE_INTEGER:QW,MAX_SAFE_COMPONENT_LENGTH:ZW}});var hp=le((whe,Y7)=>{var eK=typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...e)=>console.error("SEMVER",...e):()=>{};Y7.exports=eK});var yo=le((Na,J7)=>{var{MAX_SAFE_COMPONENT_LENGTH:y0}=dp(),tK=hp();Na=J7.exports={};var rK=Na.re=[],At=Na.src=[],Ct=Na.t={},iK=0,er=(e,t,s)=>{let p=iK++;tK(p,t),Ct[e]=p,At[p]=t,rK[p]=new RegExp(t,s?"g":void 0)};er("NUMERICIDENTIFIER","0|[1-9]\\d*");er("NUMERICIDENTIFIERLOOSE","[0-9]+");er("NONNUMERICIDENTIFIER","\\d*[a-zA-Z-][a-zA-Z0-9-]*");er("MAINVERSION",`(${At[Ct.NUMERICIDENTIFIER]})\\.(${At[Ct.NUMERICIDENTIFIER]})\\.(${At[Ct.NUMERICIDENTIFIER]})`);er("MAINVERSIONLOOSE",`(${At[Ct.NUMERICIDENTIFIERLOOSE]})\\.(${At[Ct.NUMERICIDENTIFIERLOOSE]})\\.(${At[Ct.NUMERICIDENTIFIERLOOSE]})`);er("PRERELEASEIDENTIFIER",`(?:${At[Ct.NUMERICIDENTIFIER]}|${At[Ct.NONNUMERICIDENTIFIER]})`);er("PRERELEASEIDENTIFIERLOOSE",`(?:${At[Ct.NUMERICIDENTIFIERLOOSE]}|${At[Ct.NONNUMERICIDENTIFIER]})`);er("PRERELEASE",`(?:-(${At[Ct.PRERELEASEIDENTIFIER]}(?:\\.${At[Ct.PRERELEASEIDENTIFIER]})*))`);er("PRERELEASELOOSE",`(?:-?(${At[Ct.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${At[Ct.PRERELEASEIDENTIFIERLOOSE]})*))`);er("BUILDIDENTIFIER","[0-9A-Za-z-]+");er("BUILD",`(?:\\+(${At[Ct.BUILDIDENTIFIER]}(?:\\.${At[Ct.BUILDIDENTIFIER]})*))`);er("FULLPLAIN",`v?${At[Ct.MAINVERSION]}${At[Ct.PRERELEASE]}?${At[Ct.BUILD]}?`);er("FULL",`^${At[Ct.FULLPLAIN]}$`);er("LOOSEPLAIN",`[v=\\s]*${At[Ct.MAINVERSIONLOOSE]}${At[Ct.PRERELEASELOOSE]}?${At[Ct.BUILD]}?`);er("LOOSE",`^${At[Ct.LOOSEPLAIN]}$`);er("GTLT","((?:<|>)?=?)");er("XRANGEIDENTIFIERLOOSE",`${At[Ct.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);er("XRANGEIDENTIFIER",`${At[Ct.NUMERICIDENTIFIER]}|x|X|\\*`);er("XRANGEPLAIN",`[v=\\s]*(${At[Ct.XRANGEIDENTIFIER]})(?:\\.(${At[Ct.XRANGEIDENTIFIER]})(?:\\.(${At[Ct.XRANGEIDENTIFIER]})(?:${At[Ct.PRERELEASE]})?${At[Ct.BUILD]}?)?)?`);er("XRANGEPLAINLOOSE",`[v=\\s]*(${At[Ct.XRANGEIDENTIFIERLOOSE]})(?:\\.(${At[Ct.XRANGEIDENTIFIERLOOSE]})(?:\\.(${At[Ct.XRANGEIDENTIFIERLOOSE]})(?:${At[Ct.PRERELEASELOOSE]})?${At[Ct.BUILD]}?)?)?`);er("XRANGE",`^${At[Ct.GTLT]}\\s*${At[Ct.XRANGEPLAIN]}$`);er("XRANGELOOSE",`^${At[Ct.GTLT]}\\s*${At[Ct.XRANGEPLAINLOOSE]}$`);er("COERCE",`(^|[^\\d])(\\d{1,${y0}})(?:\\.(\\d{1,${y0}}))?(?:\\.(\\d{1,${y0}}))?(?:$|[^\\d])`);er("COERCERTL",At[Ct.COERCE],!0);er("LONETILDE","(?:~>?)");er("TILDETRIM",`(\\s*)${At[Ct.LONETILDE]}\\s+`,!0);Na.tildeTrimReplace="$1~";er("TILDE",`^${At[Ct.LONETILDE]}${At[Ct.XRANGEPLAIN]}$`);er("TILDELOOSE",`^${At[Ct.LONETILDE]}${At[Ct.XRANGEPLAINLOOSE]}$`);er("LONECARET","(?:\\^)");er("CARETTRIM",`(\\s*)${At[Ct.LONECARET]}\\s+`,!0);Na.caretTrimReplace="$1^";er("CARET",`^${At[Ct.LONECARET]}${At[Ct.XRANGEPLAIN]}$`);er("CARETLOOSE",`^${At[Ct.LONECARET]}${At[Ct.XRANGEPLAINLOOSE]}$`);er("COMPARATORLOOSE",`^${At[Ct.GTLT]}\\s*(${At[Ct.LOOSEPLAIN]})$|^$`);er("COMPARATOR",`^${At[Ct.GTLT]}\\s*(${At[Ct.FULLPLAIN]})$|^$`);er("COMPARATORTRIM",`(\\s*)${At[Ct.GTLT]}\\s*(${At[Ct.LOOSEPLAIN]}|${At[Ct.XRANGEPLAIN]})`,!0);Na.comparatorTrimReplace="$1$2$3";er("HYPHENRANGE",`^\\s*(${At[Ct.XRANGEPLAIN]})\\s+-\\s+(${At[Ct.XRANGEPLAIN]})\\s*$`);er("HYPHENRANGELOOSE",`^\\s*(${At[Ct.XRANGEPLAINLOOSE]})\\s+-\\s+(${At[Ct.XRANGEPLAINLOOSE]})\\s*$`);er("STAR","(<|>)?=?\\s*\\*");er("GTE0","^\\s*>=\\s*0.0.0\\s*$");er("GTE0PRE","^\\s*>=\\s*0.0.0-0\\s*$")});var fp=le((_he,Q7)=>{var sK=["includePrerelease","loose","rtl"],nK=e=>e?typeof e!="object"?{loose:!0}:sK.filter(t=>e[t]).reduce((t,s)=>(t[s]=!0,t),{}):{};Q7.exports=nK});var ih=le((Phe,t8)=>{var Z7=/^[0-9]+$/,e8=(e,t)=>{let s=Z7.test(e),p=Z7.test(t);return s&&p&&(e=+e,t=+t),e===t?0:s&&!p?-1:p&&!s?1:ee8(t,e);t8.exports={compareIdentifiers:e8,rcompareIdentifiers:aK}});var _i=le((xhe,n8)=>{var sh=hp(),{MAX_LENGTH:r8,MAX_SAFE_INTEGER:nh}=dp(),{re:i8,t:s8}=yo(),oK=fp(),{compareIdentifiers:mp}=ih(),ws=class{constructor(t,s){if(s=oK(s),t instanceof ws){if(t.loose===!!s.loose&&t.includePrerelease===!!s.includePrerelease)return t;t=t.version}else if(typeof t!="string")throw new TypeError(`Invalid Version: ${t}`);if(t.length>r8)throw new TypeError(`version is longer than ${r8} characters`);sh("SemVer",t,s),this.options=s,this.loose=!!s.loose,this.includePrerelease=!!s.includePrerelease;let p=t.trim().match(s.loose?i8[s8.LOOSE]:i8[s8.FULL]);if(!p)throw new TypeError(`Invalid Version: ${t}`);if(this.raw=t,this.major=+p[1],this.minor=+p[2],this.patch=+p[3],this.major>nh||this.major<0)throw new TypeError("Invalid major version");if(this.minor>nh||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>nh||this.patch<0)throw new TypeError("Invalid patch version");p[4]?this.prerelease=p[4].split(".").map(c=>{if(/^[0-9]+$/.test(c)){let i=+c;if(i>=0&&i=0;)typeof this.prerelease[p]=="number"&&(this.prerelease[p]++,p=-2);p===-1&&this.prerelease.push(0)}s&&(this.prerelease[0]===s?isNaN(this.prerelease[1])&&(this.prerelease=[s,0]):this.prerelease=[s,0]);break;default:throw new Error(`invalid increment argument: ${t}`)}return this.format(),this.raw=this.version,this}};n8.exports=ws});var go=le((Ahe,u8)=>{var{MAX_LENGTH:lK}=dp(),{re:a8,t:o8}=yo(),l8=_i(),uK=fp(),pK=(e,t)=>{if(t=uK(t),e instanceof l8)return e;if(typeof e!="string"||e.length>lK||!(t.loose?a8[o8.LOOSE]:a8[o8.FULL]).test(e))return null;try{return new l8(e,t)}catch(p){return null}};u8.exports=pK});var c8=le((Che,p8)=>{var cK=go(),dK=(e,t)=>{let s=cK(e,t);return s?s.version:null};p8.exports=dK});var h8=le((Ihe,d8)=>{var hK=go(),fK=(e,t)=>{let s=hK(e.trim().replace(/^[=v]+/,""),t);return s?s.version:null};d8.exports=fK});var m8=le((Nhe,f8)=>{var mK=_i(),yK=(e,t,s,p)=>{typeof s=="string"&&(p=s,s=void 0);try{return new mK(e,s).inc(t,p).version}catch(c){return null}};f8.exports=yK});var _s=le((Ohe,g8)=>{var y8=_i(),gK=(e,t,s)=>new y8(e,s).compare(new y8(t,s));g8.exports=gK});var ah=le((Dhe,b8)=>{var bK=_s(),vK=(e,t,s)=>bK(e,t,s)===0;b8.exports=vK});var T8=le((khe,E8)=>{var v8=go(),EK=ah(),TK=(e,t)=>{if(EK(e,t))return null;{let s=v8(e),p=v8(t),c=s.prerelease.length||p.prerelease.length,i=c?"pre":"",d=c?"prerelease":"";for(let a in s)if((a==="major"||a==="minor"||a==="patch")&&s[a]!==p[a])return i+a;return d}};E8.exports=TK});var w8=le((Rhe,S8)=>{var SK=_i(),wK=(e,t)=>new SK(e,t).major;S8.exports=wK});var P8=le((Lhe,_8)=>{var _K=_i(),PK=(e,t)=>new _K(e,t).minor;_8.exports=PK});var A8=le((Fhe,x8)=>{var xK=_i(),AK=(e,t)=>new xK(e,t).patch;x8.exports=AK});var I8=le((jhe,C8)=>{var CK=go(),IK=(e,t)=>{let s=CK(e,t);return s&&s.prerelease.length?s.prerelease:null};C8.exports=IK});var O8=le((Mhe,N8)=>{var NK=_s(),OK=(e,t,s)=>NK(t,e,s);N8.exports=OK});var k8=le((Bhe,D8)=>{var DK=_s(),kK=(e,t)=>DK(e,t,!0);D8.exports=kK});var oh=le((Uhe,L8)=>{var R8=_i(),RK=(e,t,s)=>{let p=new R8(e,s),c=new R8(t,s);return p.compare(c)||p.compareBuild(c)};L8.exports=RK});var j8=le((Vhe,F8)=>{var LK=oh(),FK=(e,t)=>e.sort((s,p)=>LK(s,p,t));F8.exports=FK});var B8=le(($he,M8)=>{var jK=oh(),MK=(e,t)=>e.sort((s,p)=>jK(p,s,t));M8.exports=MK});var yp=le((Ghe,U8)=>{var BK=_s(),UK=(e,t,s)=>BK(e,t,s)>0;U8.exports=UK});var lh=le((qhe,V8)=>{var VK=_s(),$K=(e,t,s)=>VK(e,t,s)<0;V8.exports=$K});var g0=le((Hhe,$8)=>{var GK=_s(),qK=(e,t,s)=>GK(e,t,s)!==0;$8.exports=qK});var uh=le((Whe,G8)=>{var HK=_s(),WK=(e,t,s)=>HK(e,t,s)>=0;G8.exports=WK});var ph=le((Khe,q8)=>{var KK=_s(),zK=(e,t,s)=>KK(e,t,s)<=0;q8.exports=zK});var b0=le((zhe,H8)=>{var XK=ah(),YK=g0(),JK=yp(),QK=uh(),ZK=lh(),ez=ph(),tz=(e,t,s,p)=>{switch(t){case"===":return typeof e=="object"&&(e=e.version),typeof s=="object"&&(s=s.version),e===s;case"!==":return typeof e=="object"&&(e=e.version),typeof s=="object"&&(s=s.version),e!==s;case"":case"=":case"==":return XK(e,s,p);case"!=":return YK(e,s,p);case">":return JK(e,s,p);case">=":return QK(e,s,p);case"<":return ZK(e,s,p);case"<=":return ez(e,s,p);default:throw new TypeError(`Invalid operator: ${t}`)}};H8.exports=tz});var K8=le((Xhe,W8)=>{var rz=_i(),iz=go(),{re:ch,t:dh}=yo(),sz=(e,t)=>{if(e instanceof rz)return e;if(typeof e=="number"&&(e=String(e)),typeof e!="string")return null;t=t||{};let s=null;if(!t.rtl)s=e.match(ch[dh.COERCE]);else{let p;for(;(p=ch[dh.COERCERTL].exec(e))&&(!s||s.index+s[0].length!==e.length);)(!s||p.index+p[0].length!==s.index+s[0].length)&&(s=p),ch[dh.COERCERTL].lastIndex=p.index+p[1].length+p[2].length;ch[dh.COERCERTL].lastIndex=-1}return s===null?null:iz(`${s[2]}.${s[3]||"0"}.${s[4]||"0"}`,t)};W8.exports=sz});var X8=le((Yhe,z8)=>{"use strict";z8.exports=function(e){e.prototype[Symbol.iterator]=function*(){for(let t=this.head;t;t=t.next)yield t.value}}});var J8=le((Jhe,Y8)=>{"use strict";Y8.exports=vr;vr.Node=bo;vr.create=vr;function vr(e){var t=this;if(t instanceof vr||(t=new vr),t.tail=null,t.head=null,t.length=0,e&&typeof e.forEach=="function")e.forEach(function(c){t.push(c)});else if(arguments.length>0)for(var s=0,p=arguments.length;s1)s=t;else if(this.head)p=this.head.next,s=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var c=0;p!==null;c++)s=e(s,p.value,c),p=p.next;return s};vr.prototype.reduceReverse=function(e,t){var s,p=this.tail;if(arguments.length>1)s=t;else if(this.tail)p=this.tail.prev,s=this.tail.value;else throw new TypeError("Reduce of empty list with no initial value");for(var c=this.length-1;p!==null;c--)s=e(s,p.value,c),p=p.prev;return s};vr.prototype.toArray=function(){for(var e=new Array(this.length),t=0,s=this.head;s!==null;t++)e[t]=s.value,s=s.next;return e};vr.prototype.toArrayReverse=function(){for(var e=new Array(this.length),t=0,s=this.tail;s!==null;t++)e[t]=s.value,s=s.prev;return e};vr.prototype.slice=function(e,t){t=t||this.length,t<0&&(t+=this.length),e=e||0,e<0&&(e+=this.length);var s=new vr;if(tthis.length&&(t=this.length);for(var p=0,c=this.head;c!==null&&pthis.length&&(t=this.length);for(var p=this.length,c=this.tail;c!==null&&p>t;p--)c=c.prev;for(;c!==null&&p>e;p--,c=c.prev)s.push(c.value);return s};vr.prototype.splice=function(e,t,...s){e>this.length&&(e=this.length-1),e<0&&(e=this.length+e);for(var p=0,c=this.head;c!==null&&p{"use strict";var lz=J8(),vo=Symbol("max"),Xn=Symbol("length"),Ll=Symbol("lengthCalculator"),gp=Symbol("allowStale"),Eo=Symbol("maxAge"),Yn=Symbol("dispose"),Q8=Symbol("noDisposeOnSet"),ui=Symbol("lruList"),Xs=Symbol("cache"),Z8=Symbol("updateAgeOnGet"),v0=()=>1,e5=class{constructor(t){if(typeof t=="number"&&(t={max:t}),t||(t={}),t.max&&(typeof t.max!="number"||t.max<0))throw new TypeError("max must be a non-negative number");let s=this[vo]=t.max||1/0,p=t.length||v0;if(this[Ll]=typeof p!="function"?v0:p,this[gp]=t.stale||!1,t.maxAge&&typeof t.maxAge!="number")throw new TypeError("maxAge must be a number");this[Eo]=t.maxAge||0,this[Yn]=t.dispose,this[Q8]=t.noDisposeOnSet||!1,this[Z8]=t.updateAgeOnGet||!1,this.reset()}set max(t){if(typeof t!="number"||t<0)throw new TypeError("max must be a non-negative number");this[vo]=t||1/0,bp(this)}get max(){return this[vo]}set allowStale(t){this[gp]=!!t}get allowStale(){return this[gp]}set maxAge(t){if(typeof t!="number")throw new TypeError("maxAge must be a non-negative number");this[Eo]=t,bp(this)}get maxAge(){return this[Eo]}set lengthCalculator(t){typeof t!="function"&&(t=v0),t!==this[Ll]&&(this[Ll]=t,this[Xn]=0,this[ui].forEach(s=>{s.length=this[Ll](s.value,s.key),this[Xn]+=s.length})),bp(this)}get lengthCalculator(){return this[Ll]}get length(){return this[Xn]}get itemCount(){return this[ui].length}rforEach(t,s){s=s||this;for(let p=this[ui].tail;p!==null;){let c=p.prev;r5(this,t,p,s),p=c}}forEach(t,s){s=s||this;for(let p=this[ui].head;p!==null;){let c=p.next;r5(this,t,p,s),p=c}}keys(){return this[ui].toArray().map(t=>t.key)}values(){return this[ui].toArray().map(t=>t.value)}reset(){this[Yn]&&this[ui]&&this[ui].length&&this[ui].forEach(t=>this[Yn](t.key,t.value)),this[Xs]=new Map,this[ui]=new lz,this[Xn]=0}dump(){return this[ui].map(t=>hh(this,t)?!1:{k:t.key,v:t.value,e:t.now+(t.maxAge||0)}).toArray().filter(t=>t)}dumpLru(){return this[ui]}set(t,s,p){if(p=p||this[Eo],p&&typeof p!="number")throw new TypeError("maxAge must be a number");let c=p?Date.now():0,i=this[Ll](s,t);if(this[Xs].has(t)){if(i>this[vo])return Fl(this,this[Xs].get(t)),!1;let o=this[Xs].get(t).value;return this[Yn]&&(this[Q8]||this[Yn](t,o.value)),o.now=c,o.maxAge=p,o.value=s,this[Xn]+=i-o.length,o.length=i,this.get(t),bp(this),!0}let d=new t5(t,s,i,c,p);return d.length>this[vo]?(this[Yn]&&this[Yn](t,s),!1):(this[Xn]+=d.length,this[ui].unshift(d),this[Xs].set(t,this[ui].head),bp(this),!0)}has(t){if(!this[Xs].has(t))return!1;let s=this[Xs].get(t).value;return!hh(this,s)}get(t){return E0(this,t,!0)}peek(t){return E0(this,t,!1)}pop(){let t=this[ui].tail;return t?(Fl(this,t),t.value):null}del(t){Fl(this,this[Xs].get(t))}load(t){this.reset();let s=Date.now();for(let p=t.length-1;p>=0;p--){let c=t[p],i=c.e||0;if(i===0)this.set(c.k,c.v);else{let d=i-s;d>0&&this.set(c.k,c.v,d)}}}prune(){this[Xs].forEach((t,s)=>E0(this,s,!1))}},E0=(e,t,s)=>{let p=e[Xs].get(t);if(p){let c=p.value;if(hh(e,c)){if(Fl(e,p),!e[gp])return}else s&&(e[Z8]&&(p.value.now=Date.now()),e[ui].unshiftNode(p));return c.value}},hh=(e,t)=>{if(!t||!t.maxAge&&!e[Eo])return!1;let s=Date.now()-t.now;return t.maxAge?s>t.maxAge:e[Eo]&&s>e[Eo]},bp=e=>{if(e[Xn]>e[vo])for(let t=e[ui].tail;e[Xn]>e[vo]&&t!==null;){let s=t.prev;Fl(e,t),t=s}},Fl=(e,t)=>{if(t){let s=t.value;e[Yn]&&e[Yn](s.key,s.value),e[Xn]-=s.length,e[Xs].delete(s.key),e[ui].removeNode(t)}},t5=class{constructor(t,s,p,c,i){this.key=t,this.value=s,this.length=p,this.now=c,this.maxAge=i||0}},r5=(e,t,s,p)=>{let c=s.value;hh(e,c)&&(Fl(e,s),e[gp]||(c=void 0)),c&&t.call(p,c.value,c.key,e)};i5.exports=e5});var Ps=le((Zhe,l5)=>{var jl=class{constructor(t,s){if(s=pz(s),t instanceof jl)return t.loose===!!s.loose&&t.includePrerelease===!!s.includePrerelease?t:new jl(t.raw,s);if(t instanceof T0)return this.raw=t.value,this.set=[[t]],this.format(),this;if(this.options=s,this.loose=!!s.loose,this.includePrerelease=!!s.includePrerelease,this.raw=t,this.set=t.split(/\s*\|\|\s*/).map(p=>this.parseRange(p.trim())).filter(p=>p.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${t}`);if(this.set.length>1){let p=this.set[0];if(this.set=this.set.filter(c=>!a5(c[0])),this.set.length===0)this.set=[p];else if(this.set.length>1){for(let c of this.set)if(c.length===1&&mz(c[0])){this.set=[c];break}}}this.format()}format(){return this.range=this.set.map(t=>t.join(" ").trim()).join("||").trim(),this.range}toString(){return this.range}parseRange(t){t=t.trim();let p=`parseRange:${Object.keys(this.options).join(",")}:${t}`,c=n5.get(p);if(c)return c;let i=this.options.loose,d=i?Pi[vi.HYPHENRANGELOOSE]:Pi[vi.HYPHENRANGE];t=t.replace(d,Pz(this.options.includePrerelease)),Jr("hyphen replace",t),t=t.replace(Pi[vi.COMPARATORTRIM],dz),Jr("comparator trim",t,Pi[vi.COMPARATORTRIM]),t=t.replace(Pi[vi.TILDETRIM],hz),t=t.replace(Pi[vi.CARETTRIM],fz),t=t.split(/\s+/).join(" ");let a=i?Pi[vi.COMPARATORLOOSE]:Pi[vi.COMPARATOR],o=t.split(" ").map(h=>yz(h,this.options)).join(" ").split(/\s+/).map(h=>_z(h,this.options)).filter(this.options.loose?h=>!!h.match(a):()=>!0).map(h=>new T0(h,this.options)),n=o.length,l=new Map;for(let h of o){if(a5(h))return[h];l.set(h.value,h)}l.size>1&&l.has("")&&l.delete("");let g=[...l.values()];return n5.set(p,g),g}intersects(t,s){if(!(t instanceof jl))throw new TypeError("a Range is required");return this.set.some(p=>o5(p,s)&&t.set.some(c=>o5(c,s)&&p.every(i=>c.every(d=>i.intersects(d,s)))))}test(t){if(!t)return!1;if(typeof t=="string")try{t=new cz(t,this.options)}catch(s){return!1}for(let s=0;se.value==="<0.0.0-0",mz=e=>e.value==="",o5=(e,t)=>{let s=!0,p=e.slice(),c=p.pop();for(;s&&p.length;)s=p.every(i=>c.intersects(i,t)),c=p.pop();return s},yz=(e,t)=>(Jr("comp",e,t),e=vz(e,t),Jr("caret",e),e=gz(e,t),Jr("tildes",e),e=Tz(e,t),Jr("xrange",e),e=wz(e,t),Jr("stars",e),e),Li=e=>!e||e.toLowerCase()==="x"||e==="*",gz=(e,t)=>e.trim().split(/\s+/).map(s=>bz(s,t)).join(" "),bz=(e,t)=>{let s=t.loose?Pi[vi.TILDELOOSE]:Pi[vi.TILDE];return e.replace(s,(p,c,i,d,a)=>{Jr("tilde",e,p,c,i,d,a);let o;return Li(c)?o="":Li(i)?o=`>=${c}.0.0 <${+c+1}.0.0-0`:Li(d)?o=`>=${c}.${i}.0 <${c}.${+i+1}.0-0`:a?(Jr("replaceTilde pr",a),o=`>=${c}.${i}.${d}-${a} <${c}.${+i+1}.0-0`):o=`>=${c}.${i}.${d} <${c}.${+i+1}.0-0`,Jr("tilde return",o),o})},vz=(e,t)=>e.trim().split(/\s+/).map(s=>Ez(s,t)).join(" "),Ez=(e,t)=>{Jr("caret",e,t);let s=t.loose?Pi[vi.CARETLOOSE]:Pi[vi.CARET],p=t.includePrerelease?"-0":"";return e.replace(s,(c,i,d,a,o)=>{Jr("caret",e,c,i,d,a,o);let n;return Li(i)?n="":Li(d)?n=`>=${i}.0.0${p} <${+i+1}.0.0-0`:Li(a)?i==="0"?n=`>=${i}.${d}.0${p} <${i}.${+d+1}.0-0`:n=`>=${i}.${d}.0${p} <${+i+1}.0.0-0`:o?(Jr("replaceCaret pr",o),i==="0"?d==="0"?n=`>=${i}.${d}.${a}-${o} <${i}.${d}.${+a+1}-0`:n=`>=${i}.${d}.${a}-${o} <${i}.${+d+1}.0-0`:n=`>=${i}.${d}.${a}-${o} <${+i+1}.0.0-0`):(Jr("no pr"),i==="0"?d==="0"?n=`>=${i}.${d}.${a}${p} <${i}.${d}.${+a+1}-0`:n=`>=${i}.${d}.${a}${p} <${i}.${+d+1}.0-0`:n=`>=${i}.${d}.${a} <${+i+1}.0.0-0`),Jr("caret return",n),n})},Tz=(e,t)=>(Jr("replaceXRanges",e,t),e.split(/\s+/).map(s=>Sz(s,t)).join(" ")),Sz=(e,t)=>{e=e.trim();let s=t.loose?Pi[vi.XRANGELOOSE]:Pi[vi.XRANGE];return e.replace(s,(p,c,i,d,a,o)=>{Jr("xRange",e,p,c,i,d,a,o);let n=Li(i),l=n||Li(d),g=l||Li(a),h=g;return c==="="&&h&&(c=""),o=t.includePrerelease?"-0":"",n?c===">"||c==="<"?p="<0.0.0-0":p="*":c&&h?(l&&(d=0),a=0,c===">"?(c=">=",l?(i=+i+1,d=0,a=0):(d=+d+1,a=0)):c==="<="&&(c="<",l?i=+i+1:d=+d+1),c==="<"&&(o="-0"),p=`${c+i}.${d}.${a}${o}`):l?p=`>=${i}.0.0${o} <${+i+1}.0.0-0`:g&&(p=`>=${i}.${d}.0${o} <${i}.${+d+1}.0-0`),Jr("xRange return",p),p})},wz=(e,t)=>(Jr("replaceStars",e,t),e.trim().replace(Pi[vi.STAR],"")),_z=(e,t)=>(Jr("replaceGTE0",e,t),e.trim().replace(Pi[t.includePrerelease?vi.GTE0PRE:vi.GTE0],"")),Pz=e=>(t,s,p,c,i,d,a,o,n,l,g,h,m)=>(Li(p)?s="":Li(c)?s=`>=${p}.0.0${e?"-0":""}`:Li(i)?s=`>=${p}.${c}.0${e?"-0":""}`:d?s=`>=${s}`:s=`>=${s}${e?"-0":""}`,Li(n)?o="":Li(l)?o=`<${+n+1}.0.0-0`:Li(g)?o=`<${n}.${+l+1}.0-0`:h?o=`<=${n}.${l}.${g}-${h}`:e?o=`<${n}.${l}.${+g+1}-0`:o=`<=${o}`,`${s} ${o}`.trim()),xz=(e,t,s)=>{for(let p=0;p0){let c=e[p].semver;if(c.major===t.major&&c.minor===t.minor&&c.patch===t.patch)return!0}return!1}return!0}});var vp=le((efe,h5)=>{var Ep=Symbol("SemVer ANY"),Tp=class{static get ANY(){return Ep}constructor(t,s){if(s=Az(s),t instanceof Tp){if(t.loose===!!s.loose)return t;t=t.value}w0("comparator",t,s),this.options=s,this.loose=!!s.loose,this.parse(t),this.semver===Ep?this.value="":this.value=this.operator+this.semver.version,w0("comp",this)}parse(t){let s=this.options.loose?u5[p5.COMPARATORLOOSE]:u5[p5.COMPARATOR],p=t.match(s);if(!p)throw new TypeError(`Invalid comparator: ${t}`);this.operator=p[1]!==void 0?p[1]:"",this.operator==="="&&(this.operator=""),p[2]?this.semver=new c5(p[2],this.options.loose):this.semver=Ep}toString(){return this.value}test(t){if(w0("Comparator.test",t,this.options.loose),this.semver===Ep||t===Ep)return!0;if(typeof t=="string")try{t=new c5(t,this.options)}catch(s){return!1}return S0(t,this.operator,this.semver,this.options)}intersects(t,s){if(!(t instanceof Tp))throw new TypeError("a Comparator is required");if((!s||typeof s!="object")&&(s={loose:!!s,includePrerelease:!1}),this.operator==="")return this.value===""?!0:new d5(t.value,s).test(this.value);if(t.operator==="")return t.value===""?!0:new d5(this.value,s).test(t.semver);let p=(this.operator===">="||this.operator===">")&&(t.operator===">="||t.operator===">"),c=(this.operator==="<="||this.operator==="<")&&(t.operator==="<="||t.operator==="<"),i=this.semver.version===t.semver.version,d=(this.operator===">="||this.operator==="<=")&&(t.operator===">="||t.operator==="<="),a=S0(this.semver,"<",t.semver,s)&&(this.operator===">="||this.operator===">")&&(t.operator==="<="||t.operator==="<"),o=S0(this.semver,">",t.semver,s)&&(this.operator==="<="||this.operator==="<")&&(t.operator===">="||t.operator===">");return p||c||i&&d||a||o}};h5.exports=Tp;var Az=fp(),{re:u5,t:p5}=yo(),S0=b0(),w0=hp(),c5=_i(),d5=Ps()});var Sp=le((tfe,f5)=>{var Cz=Ps(),Iz=(e,t,s)=>{try{t=new Cz(t,s)}catch(p){return!1}return t.test(e)};f5.exports=Iz});var y5=le((rfe,m5)=>{var Nz=Ps(),Oz=(e,t)=>new Nz(e,t).set.map(s=>s.map(p=>p.value).join(" ").trim().split(" "));m5.exports=Oz});var b5=le((ife,g5)=>{var Dz=_i(),kz=Ps(),Rz=(e,t,s)=>{let p=null,c=null,i=null;try{i=new kz(t,s)}catch(d){return null}return e.forEach(d=>{i.test(d)&&(!p||c.compare(d)===-1)&&(p=d,c=new Dz(p,s))}),p};g5.exports=Rz});var E5=le((sfe,v5)=>{var Lz=_i(),Fz=Ps(),jz=(e,t,s)=>{let p=null,c=null,i=null;try{i=new Fz(t,s)}catch(d){return null}return e.forEach(d=>{i.test(d)&&(!p||c.compare(d)===1)&&(p=d,c=new Lz(p,s))}),p};v5.exports=jz});var w5=le((nfe,S5)=>{var _0=_i(),Mz=Ps(),T5=yp(),Bz=(e,t)=>{e=new Mz(e,t);let s=new _0("0.0.0");if(e.test(s)||(s=new _0("0.0.0-0"),e.test(s)))return s;s=null;for(let p=0;p{let a=new _0(d.semver.version);switch(d.operator){case">":a.prerelease.length===0?a.patch++:a.prerelease.push(0),a.raw=a.format();case"":case">=":(!i||T5(a,i))&&(i=a);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${d.operator}`)}}),i&&(!s||T5(s,i))&&(s=i)}return s&&e.test(s)?s:null};S5.exports=Bz});var P5=le((afe,_5)=>{var Uz=Ps(),Vz=(e,t)=>{try{return new Uz(e,t).range||"*"}catch(s){return null}};_5.exports=Vz});var fh=le((ofe,I5)=>{var $z=_i(),x5=vp(),{ANY:Gz}=x5,qz=Ps(),Hz=Sp(),A5=yp(),C5=lh(),Wz=ph(),Kz=uh(),zz=(e,t,s,p)=>{e=new $z(e,p),t=new qz(t,p);let c,i,d,a,o;switch(s){case">":c=A5,i=Wz,d=C5,a=">",o=">=";break;case"<":c=C5,i=Kz,d=A5,a="<",o="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(Hz(e,t,p))return!1;for(let n=0;n{m.semver===Gz&&(m=new x5(">=0.0.0")),g=g||m,h=h||m,c(m.semver,g.semver,p)?g=m:d(m.semver,h.semver,p)&&(h=m)}),g.operator===a||g.operator===o||(!h.operator||h.operator===a)&&i(e,h.semver))return!1;if(h.operator===o&&d(e,h.semver))return!1}return!0};I5.exports=zz});var O5=le((lfe,N5)=>{var Xz=fh(),Yz=(e,t,s)=>Xz(e,t,">",s);N5.exports=Yz});var k5=le((ufe,D5)=>{var Jz=fh(),Qz=(e,t,s)=>Jz(e,t,"<",s);D5.exports=Qz});var F5=le((pfe,L5)=>{var R5=Ps(),Zz=(e,t,s)=>(e=new R5(e,s),t=new R5(t,s),e.intersects(t));L5.exports=Zz});var M5=le((cfe,j5)=>{var eX=Sp(),tX=_s();j5.exports=(e,t,s)=>{let p=[],c=null,i=null,d=e.sort((l,g)=>tX(l,g,s));for(let l of d)eX(l,t,s)?(i=l,c||(c=l)):(i&&p.push([c,i]),i=null,c=null);c&&p.push([c,null]);let a=[];for(let[l,g]of p)l===g?a.push(l):!g&&l===d[0]?a.push("*"):g?l===d[0]?a.push(`<=${g}`):a.push(`${l} - ${g}`):a.push(`>=${l}`);let o=a.join(" || "),n=typeof t.raw=="string"?t.raw:String(t);return o.length{var B5=Ps(),mh=vp(),{ANY:P0}=mh,wp=Sp(),x0=_s(),rX=(e,t,s={})=>{if(e===t)return!0;e=new B5(e,s),t=new B5(t,s);let p=!1;e:for(let c of e.set){for(let i of t.set){let d=iX(c,i,s);if(p=p||d!==null,d)continue e}if(p)return!1}return!0},iX=(e,t,s)=>{if(e===t)return!0;if(e.length===1&&e[0].semver===P0){if(t.length===1&&t[0].semver===P0)return!0;s.includePrerelease?e=[new mh(">=0.0.0-0")]:e=[new mh(">=0.0.0")]}if(t.length===1&&t[0].semver===P0){if(s.includePrerelease)return!0;t=[new mh(">=0.0.0")]}let p=new Set,c,i;for(let m of e)m.operator===">"||m.operator===">="?c=U5(c,m,s):m.operator==="<"||m.operator==="<="?i=V5(i,m,s):p.add(m.semver);if(p.size>1)return null;let d;if(c&&i){if(d=x0(c.semver,i.semver,s),d>0)return null;if(d===0&&(c.operator!==">="||i.operator!=="<="))return null}for(let m of p){if(c&&!wp(m,String(c),s)||i&&!wp(m,String(i),s))return null;for(let b of t)if(!wp(m,String(b),s))return!1;return!0}let a,o,n,l,g=i&&!s.includePrerelease&&i.semver.prerelease.length?i.semver:!1,h=c&&!s.includePrerelease&&c.semver.prerelease.length?c.semver:!1;g&&g.prerelease.length===1&&i.operator==="<"&&g.prerelease[0]===0&&(g=!1);for(let m of t){if(l=l||m.operator===">"||m.operator===">=",n=n||m.operator==="<"||m.operator==="<=",c){if(h&&m.semver.prerelease&&m.semver.prerelease.length&&m.semver.major===h.major&&m.semver.minor===h.minor&&m.semver.patch===h.patch&&(h=!1),m.operator===">"||m.operator===">="){if(a=U5(c,m,s),a===m&&a!==c)return!1}else if(c.operator===">="&&!wp(c.semver,String(m),s))return!1}if(i){if(g&&m.semver.prerelease&&m.semver.prerelease.length&&m.semver.major===g.major&&m.semver.minor===g.minor&&m.semver.patch===g.patch&&(g=!1),m.operator==="<"||m.operator==="<="){if(o=V5(i,m,s),o===m&&o!==i)return!1}else if(i.operator==="<="&&!wp(i.semver,String(m),s))return!1}if(!m.operator&&(i||c)&&d!==0)return!1}return!(c&&n&&!i&&d!==0||i&&l&&!c&&d!==0||h||g)},U5=(e,t,s)=>{if(!e)return t;let p=x0(e.semver,t.semver,s);return p>0?e:p<0||t.operator===">"&&e.operator===">="?t:e},V5=(e,t,s)=>{if(!e)return t;let p=x0(e.semver,t.semver,s);return p<0?e:p>0||t.operator==="<"&&e.operator==="<="?t:e};$5.exports=rX});var H5=le((hfe,q5)=>{var A0=yo();q5.exports={re:A0.re,src:A0.src,tokens:A0.t,SEMVER_SPEC_VERSION:dp().SEMVER_SPEC_VERSION,SemVer:_i(),compareIdentifiers:ih().compareIdentifiers,rcompareIdentifiers:ih().rcompareIdentifiers,parse:go(),valid:c8(),clean:h8(),inc:m8(),diff:T8(),major:w8(),minor:P8(),patch:A8(),prerelease:I8(),compare:_s(),rcompare:O8(),compareLoose:k8(),compareBuild:oh(),sort:j8(),rsort:B8(),gt:yp(),lt:lh(),eq:ah(),neq:g0(),gte:uh(),lte:ph(),cmp:b0(),coerce:K8(),Comparator:vp(),Range:Ps(),satisfies:Sp(),toComparators:y5(),maxSatisfying:b5(),minSatisfying:E5(),minVersion:w5(),validRange:P5(),outside:fh(),gtr:O5(),ltr:k5(),intersects:F5(),simplifyRange:M5(),subset:G5()}});var aw=le((xfe,nw)=>{"use strict";var C0;try{C0=Map}catch(e){}var I0;try{I0=Set}catch(e){}function iw(e,t,s){if(!e||typeof e!="object"||typeof e=="function")return e;if(e.nodeType&&"cloneNode"in e)return e.cloneNode(!0);if(e instanceof Date)return new Date(e.getTime());if(e instanceof RegExp)return new RegExp(e);if(Array.isArray(e))return e.map(sw);if(C0&&e instanceof C0)return new Map(Array.from(e.entries()));if(I0&&e instanceof I0)return new Set(Array.from(e.values()));if(e instanceof Object){t.push(e);var p=Object.create(e);s.push(p);for(var c in e){var i=t.findIndex(function(d){return d===e[c]});p[c]=i>-1?s[i]:iw(e[c],t,s)}return p}return e}function sw(e){return iw(e,[],[])}nw.exports=sw});var _p=le(N0=>{"use strict";Object.defineProperty(N0,"__esModule",{value:!0});N0.default=cX;var nX=Object.prototype.toString,aX=Error.prototype.toString,oX=RegExp.prototype.toString,lX=typeof Symbol!="undefined"?Symbol.prototype.toString:()=>"",uX=/^Symbol\((.*)\)(.*)$/;function pX(e){return e!=+e?"NaN":e===0&&1/e<0?"-0":""+e}function ow(e,t=!1){if(e==null||e===!0||e===!1)return""+e;let s=typeof e;if(s==="number")return pX(e);if(s==="string")return t?`"${e}"`:e;if(s==="function")return"[Function "+(e.name||"anonymous")+"]";if(s==="symbol")return lX.call(e).replace(uX,"Symbol($1)");let p=nX.call(e).slice(8,-1);return p==="Date"?isNaN(e.getTime())?""+e:e.toISOString(e):p==="Error"||e instanceof Error?"["+aX.call(e)+"]":p==="RegExp"?oX.call(e):null}function cX(e,t){let s=ow(e,t);return s!==null?s:JSON.stringify(e,function(p,c){let i=ow(this[p],t);return i!==null?i:c},2)}});var Jn=le(pi=>{"use strict";Object.defineProperty(pi,"__esModule",{value:!0});pi.default=pi.array=pi.object=pi.boolean=pi.date=pi.number=pi.string=pi.mixed=void 0;var lw=dX(_p());function dX(e){return e&&e.__esModule?e:{default:e}}var uw={default:"${path} is invalid",required:"${path} is a required field",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:({path:e,type:t,value:s,originalValue:p})=>{let c=p!=null&&p!==s,i=`${e} must be a \`${t}\` type, but the final value was: \`${(0,lw.default)(s,!0)}\``+(c?` (cast from the value \`${(0,lw.default)(p,!0)}\`).`:".");return s===null&&(i+='\n If "null" is intended as an empty value be sure to mark the schema as `.nullable()`'),i},defined:"${path} must be defined"};pi.mixed=uw;var pw={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"};pi.string=pw;var cw={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"};pi.number=cw;var dw={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"};pi.date=dw;var hw={isValue:"${path} field must be ${value}"};pi.boolean=hw;var fw={noUnknown:"${path} field has unspecified keys: ${unknown}"};pi.object=fw;var mw={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must be have ${length} items"};pi.array=mw;var hX=Object.assign(Object.create(null),{mixed:uw,string:pw,number:cw,date:dw,object:fw,array:mw,boolean:hw});pi.default=hX});var gw=le((Ife,yw)=>{var fX=Object.prototype,mX=fX.hasOwnProperty;function yX(e,t){return e!=null&&mX.call(e,t)}yw.exports=yX});var gh=le((Nfe,bw)=>{var gX=gw(),bX=S1();function vX(e,t){return e!=null&&bX(e,t,gX)}bw.exports=vX});var Ml=le(bh=>{"use strict";Object.defineProperty(bh,"__esModule",{value:!0});bh.default=void 0;var EX=e=>e&&e.__isYupSchema__;bh.default=EX});var Tw=le(vh=>{"use strict";Object.defineProperty(vh,"__esModule",{value:!0});vh.default=void 0;var TX=vw(gh()),SX=vw(Ml());function vw(e){return e&&e.__esModule?e:{default:e}}var Ew=class{constructor(t,s){if(this.refs=t,this.refs=t,typeof s=="function"){this.fn=s;return}if(!(0,TX.default)(s,"is"))throw new TypeError("`is:` is required for `when()` conditions");if(!s.then&&!s.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:p,then:c,otherwise:i}=s,d=typeof p=="function"?p:(...a)=>a.every(o=>o===p);this.fn=function(...a){let o=a.pop(),n=a.pop(),l=d(...a)?c:i;if(!!l)return typeof l=="function"?l(n):n.concat(l.resolve(o))}}resolve(t,s){let p=this.refs.map(i=>i.getValue(s==null?void 0:s.value,s==null?void 0:s.parent,s==null?void 0:s.context)),c=this.fn.apply(t,p.concat(t,s));if(c===void 0||c===t)return t;if(!(0,SX.default)(c))throw new TypeError("conditions must return a schema object");return c.resolve(s)}},wX=Ew;vh.default=wX});var D0=le(O0=>{"use strict";Object.defineProperty(O0,"__esModule",{value:!0});O0.default=_X;function _X(e){return e==null?[]:[].concat(e)}});var To=le(Eh=>{"use strict";Object.defineProperty(Eh,"__esModule",{value:!0});Eh.default=void 0;var PX=Sw(_p()),xX=Sw(D0());function Sw(e){return e&&e.__esModule?e:{default:e}}function k0(){return k0=Object.assign||function(e){for(var t=1;t(0,PX.default)(s[i])):typeof t=="function"?t(s):t}static isError(t){return t&&t.name==="ValidationError"}constructor(t,s,p,c){super();this.name="ValidationError",this.value=s,this.path=p,this.type=c,this.errors=[],this.inner=[],(0,xX.default)(t).forEach(i=>{Pp.isError(i)?(this.errors.push(...i.errors),this.inner=this.inner.concat(i.inner.length?i.inner:i)):this.errors.push(i)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0],Error.captureStackTrace&&Error.captureStackTrace(this,Pp)}};Eh.default=Pp});var Th=le(L0=>{"use strict";Object.defineProperty(L0,"__esModule",{value:!0});L0.default=NX;var R0=CX(To());function CX(e){return e&&e.__esModule?e:{default:e}}var IX=e=>{let t=!1;return(...s)=>{t||(t=!0,e(...s))}};function NX(e,t){let{endEarly:s,tests:p,args:c,value:i,errors:d,sort:a,path:o}=e,n=IX(t),l=p.length,g=[];if(d=d||[],!l)return d.length?n(new R0.default(d,i,o)):n(null,i);for(let h=0;h{function OX(e){return function(t,s,p){for(var c=-1,i=Object(t),d=p(t),a=d.length;a--;){var o=d[e?a:++c];if(s(i[o],o,i)===!1)break}return t}}ww.exports=OX});var xw=le((jfe,Pw)=>{var DX=_w(),kX=DX();Pw.exports=kX});var Cw=le((Mfe,Aw)=>{function RX(e,t){for(var s=-1,p=Array(e);++s{function LX(){return!1}Iw.exports=LX});var F0=le((xp,Bl)=>{var FX=yn(),jX=Nw(),Ow=typeof xp=="object"&&xp&&!xp.nodeType&&xp,Dw=Ow&&typeof Bl=="object"&&Bl&&!Bl.nodeType&&Bl,MX=Dw&&Dw.exports===Ow,kw=MX?FX.Buffer:void 0,BX=kw?kw.isBuffer:void 0,UX=BX||jX;Bl.exports=UX});var Lw=le((Ufe,Rw)=>{var VX=yl(),$X=hd(),GX=gl(),qX="[object Arguments]",HX="[object Array]",WX="[object Boolean]",KX="[object Date]",zX="[object Error]",XX="[object Function]",YX="[object Map]",JX="[object Number]",QX="[object Object]",ZX="[object RegExp]",eY="[object Set]",tY="[object String]",rY="[object WeakMap]",iY="[object ArrayBuffer]",sY="[object DataView]",nY="[object Float32Array]",aY="[object Float64Array]",oY="[object Int8Array]",lY="[object Int16Array]",uY="[object Int32Array]",pY="[object Uint8Array]",cY="[object Uint8ClampedArray]",dY="[object Uint16Array]",hY="[object Uint32Array]",kr={};kr[nY]=kr[aY]=kr[oY]=kr[lY]=kr[uY]=kr[pY]=kr[cY]=kr[dY]=kr[hY]=!0;kr[qX]=kr[HX]=kr[iY]=kr[WX]=kr[sY]=kr[KX]=kr[zX]=kr[XX]=kr[YX]=kr[JX]=kr[QX]=kr[ZX]=kr[eY]=kr[tY]=kr[rY]=!1;function fY(e){return GX(e)&&$X(e.length)&&!!kr[VX(e)]}Rw.exports=fY});var jw=le((Vfe,Fw)=>{function mY(e){return function(t){return e(t)}}Fw.exports=mY});var Bw=le((Cp,Ul)=>{var yY=l1(),Mw=typeof Cp=="object"&&Cp&&!Cp.nodeType&&Cp,Ap=Mw&&typeof Ul=="object"&&Ul&&!Ul.nodeType&&Ul,gY=Ap&&Ap.exports===Mw,j0=gY&&yY.process,bY=function(){try{var e=Ap&&Ap.require&&Ap.require("util").types;return e||j0&&j0.binding&&j0.binding("util")}catch(t){}}();Ul.exports=bY});var M0=le(($fe,$w)=>{var vY=Lw(),EY=jw(),Uw=Bw(),Vw=Uw&&Uw.isTypedArray,TY=Vw?EY(Vw):vY;$w.exports=TY});var qw=le((Gfe,Gw)=>{var SY=Cw(),wY=dd(),_Y=mn(),PY=F0(),xY=cd(),AY=M0(),CY=Object.prototype,IY=CY.hasOwnProperty;function NY(e,t){var s=_Y(e),p=!s&&wY(e),c=!s&&!p&&PY(e),i=!s&&!p&&!c&&AY(e),d=s||p||c||i,a=d?SY(e.length,String):[],o=a.length;for(var n in e)(t||IY.call(e,n))&&!(d&&(n=="length"||c&&(n=="offset"||n=="parent")||i&&(n=="buffer"||n=="byteLength"||n=="byteOffset")||xY(n,o)))&&a.push(n);return a}Gw.exports=NY});var Ww=le((qfe,Hw)=>{var OY=Object.prototype;function DY(e){var t=e&&e.constructor,s=typeof t=="function"&&t.prototype||OY;return e===s}Hw.exports=DY});var zw=le((Hfe,Kw)=>{function kY(e,t){return function(s){return e(t(s))}}Kw.exports=kY});var Yw=le((Wfe,Xw)=>{var RY=zw(),LY=RY(Object.keys,Object);Xw.exports=LY});var Qw=le((Kfe,Jw)=>{var FY=Ww(),jY=Yw(),MY=Object.prototype,BY=MY.hasOwnProperty;function UY(e){if(!FY(e))return jY(e);var t=[];for(var s in Object(e))BY.call(e,s)&&s!="constructor"&&t.push(s);return t}Jw.exports=UY});var e_=le((zfe,Zw)=>{var VY=u1(),$Y=hd();function GY(e){return e!=null&&$Y(e.length)&&!VY(e)}Zw.exports=GY});var Sh=le((Xfe,t_)=>{var qY=qw(),HY=Qw(),WY=e_();function KY(e){return WY(e)?qY(e):HY(e)}t_.exports=KY});var B0=le((Yfe,r_)=>{var zY=xw(),XY=Sh();function YY(e,t){return e&&zY(e,t,XY)}r_.exports=YY});var s_=le((Jfe,i_)=>{var JY=Vu();function QY(){this.__data__=new JY,this.size=0}i_.exports=QY});var a_=le((Qfe,n_)=>{function ZY(e){var t=this.__data__,s=t.delete(e);return this.size=t.size,s}n_.exports=ZY});var l_=le((Zfe,o_)=>{function eJ(e){return this.__data__.get(e)}o_.exports=eJ});var p_=le((eme,u_)=>{function tJ(e){return this.__data__.has(e)}u_.exports=tJ});var d_=le((tme,c_)=>{var rJ=Vu(),iJ=od(),sJ=ld(),nJ=200;function aJ(e,t){var s=this.__data__;if(s instanceof rJ){var p=s.__data__;if(!iJ||p.length{var oJ=Vu(),lJ=s_(),uJ=a_(),pJ=l_(),cJ=p_(),dJ=d_();function Vl(e){var t=this.__data__=new oJ(e);this.size=t.size}Vl.prototype.clear=lJ;Vl.prototype.delete=uJ;Vl.prototype.get=pJ;Vl.prototype.has=cJ;Vl.prototype.set=dJ;h_.exports=Vl});var m_=le((ime,f_)=>{var hJ="__lodash_hash_undefined__";function fJ(e){return this.__data__.set(e,hJ),this}f_.exports=fJ});var g_=le((sme,y_)=>{function mJ(e){return this.__data__.has(e)}y_.exports=mJ});var v_=le((nme,b_)=>{var yJ=ld(),gJ=m_(),bJ=g_();function wh(e){var t=-1,s=e==null?0:e.length;for(this.__data__=new yJ;++t{function vJ(e,t){for(var s=-1,p=e==null?0:e.length;++s{function EJ(e,t){return e.has(t)}S_.exports=EJ});var V0=le((lme,__)=>{var TJ=v_(),SJ=T_(),wJ=w_(),_J=1,PJ=2;function xJ(e,t,s,p,c,i){var d=s&_J,a=e.length,o=t.length;if(a!=o&&!(d&&o>a))return!1;var n=i.get(e),l=i.get(t);if(n&&l)return n==t&&l==e;var g=-1,h=!0,m=s&PJ?new TJ:void 0;for(i.set(e,t),i.set(t,e);++g{var AJ=yn(),CJ=AJ.Uint8Array;P_.exports=CJ});var C_=le((pme,A_)=>{function IJ(e){var t=-1,s=Array(e.size);return e.forEach(function(p,c){s[++t]=[c,p]}),s}A_.exports=IJ});var N_=le((cme,I_)=>{function NJ(e){var t=-1,s=Array(e.size);return e.forEach(function(p){s[++t]=p}),s}I_.exports=NJ});var L_=le((dme,R_)=>{var O_=ml(),D_=x_(),OJ=ad(),DJ=V0(),kJ=C_(),RJ=N_(),LJ=1,FJ=2,jJ="[object Boolean]",MJ="[object Date]",BJ="[object Error]",UJ="[object Map]",VJ="[object Number]",$J="[object RegExp]",GJ="[object Set]",qJ="[object String]",HJ="[object Symbol]",WJ="[object ArrayBuffer]",KJ="[object DataView]",k_=O_?O_.prototype:void 0,$0=k_?k_.valueOf:void 0;function zJ(e,t,s,p,c,i,d){switch(s){case KJ:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case WJ:return!(e.byteLength!=t.byteLength||!i(new D_(e),new D_(t)));case jJ:case MJ:case VJ:return OJ(+e,+t);case BJ:return e.name==t.name&&e.message==t.message;case $J:case qJ:return e==t+"";case UJ:var a=kJ;case GJ:var o=p&LJ;if(a||(a=RJ),e.size!=t.size&&!o)return!1;var n=d.get(e);if(n)return n==t;p|=FJ,d.set(e,t);var l=DJ(a(e),a(t),p,c,i,d);return d.delete(e),l;case HJ:if($0)return $0.call(e)==$0.call(t)}return!1}R_.exports=zJ});var j_=le((hme,F_)=>{var XJ=_1(),YJ=mn();function JJ(e,t,s){var p=t(e);return YJ(e)?p:XJ(p,s(e))}F_.exports=JJ});var B_=le((fme,M_)=>{function QJ(e,t){for(var s=-1,p=e==null?0:e.length,c=0,i=[];++s{function ZJ(){return[]}U_.exports=ZJ});var q_=le((yme,G_)=>{var eQ=B_(),tQ=V_(),rQ=Object.prototype,iQ=rQ.propertyIsEnumerable,$_=Object.getOwnPropertySymbols,sQ=$_?function(e){return e==null?[]:(e=Object(e),eQ($_(e),function(t){return iQ.call(e,t)}))}:tQ;G_.exports=sQ});var W_=le((gme,H_)=>{var nQ=j_(),aQ=q_(),oQ=Sh();function lQ(e){return nQ(e,oQ,aQ)}H_.exports=lQ});var X_=le((bme,z_)=>{var K_=W_(),uQ=1,pQ=Object.prototype,cQ=pQ.hasOwnProperty;function dQ(e,t,s,p,c,i){var d=s&uQ,a=K_(e),o=a.length,n=K_(t),l=n.length;if(o!=l&&!d)return!1;for(var g=o;g--;){var h=a[g];if(!(d?h in t:cQ.call(t,h)))return!1}var m=i.get(e),b=i.get(t);if(m&&b)return m==t&&b==e;var E=!0;i.set(e,t),i.set(t,e);for(var _=d;++g{var hQ=wa(),fQ=yn(),mQ=hQ(fQ,"DataView");Y_.exports=mQ});var Z_=le((Eme,Q_)=>{var yQ=wa(),gQ=yn(),bQ=yQ(gQ,"Promise");Q_.exports=bQ});var tP=le((Tme,eP)=>{var vQ=wa(),EQ=yn(),TQ=vQ(EQ,"Set");eP.exports=TQ});var iP=le((Sme,rP)=>{var SQ=wa(),wQ=yn(),_Q=SQ(wQ,"WeakMap");rP.exports=_Q});var cP=le((wme,pP)=>{var G0=J_(),q0=od(),H0=Z_(),W0=tP(),K0=iP(),sP=yl(),$l=c1(),nP="[object Map]",PQ="[object Object]",aP="[object Promise]",oP="[object Set]",lP="[object WeakMap]",uP="[object DataView]",xQ=$l(G0),AQ=$l(q0),CQ=$l(H0),IQ=$l(W0),NQ=$l(K0),So=sP;(G0&&So(new G0(new ArrayBuffer(1)))!=uP||q0&&So(new q0)!=nP||H0&&So(H0.resolve())!=aP||W0&&So(new W0)!=oP||K0&&So(new K0)!=lP)&&(So=function(e){var t=sP(e),s=t==PQ?e.constructor:void 0,p=s?$l(s):"";if(p)switch(p){case xQ:return uP;case AQ:return nP;case CQ:return aP;case IQ:return oP;case NQ:return lP}return t});pP.exports=So});var vP=le((_me,bP)=>{var z0=U0(),OQ=V0(),DQ=L_(),kQ=X_(),dP=cP(),hP=mn(),fP=F0(),RQ=M0(),LQ=1,mP="[object Arguments]",yP="[object Array]",_h="[object Object]",FQ=Object.prototype,gP=FQ.hasOwnProperty;function jQ(e,t,s,p,c,i){var d=hP(e),a=hP(t),o=d?yP:dP(e),n=a?yP:dP(t);o=o==mP?_h:o,n=n==mP?_h:n;var l=o==_h,g=n==_h,h=o==n;if(h&&fP(e)){if(!fP(t))return!1;d=!0,l=!1}if(h&&!l)return i||(i=new z0),d||RQ(e)?OQ(e,t,s,p,c,i):DQ(e,t,o,s,p,c,i);if(!(s&LQ)){var m=l&&gP.call(e,"__wrapped__"),b=g&&gP.call(t,"__wrapped__");if(m||b){var E=m?e.value():e,_=b?t.value():t;return i||(i=new z0),c(E,_,s,p,i)}}return h?(i||(i=new z0),kQ(e,t,s,p,c,i)):!1}bP.exports=jQ});var X0=le((Pme,SP)=>{var MQ=vP(),EP=gl();function TP(e,t,s,p,c){return e===t?!0:e==null||t==null||!EP(e)&&!EP(t)?e!==e&&t!==t:MQ(e,t,s,p,TP,c)}SP.exports=TP});var _P=le((xme,wP)=>{var BQ=U0(),UQ=X0(),VQ=1,$Q=2;function GQ(e,t,s,p){var c=s.length,i=c,d=!p;if(e==null)return!i;for(e=Object(e);c--;){var a=s[c];if(d&&a[2]?a[1]!==e[a[0]]:!(a[0]in e))return!1}for(;++c{var qQ=Mu();function HQ(e){return e===e&&!qQ(e)}PP.exports=HQ});var AP=le((Cme,xP)=>{var WQ=Y0(),KQ=Sh();function zQ(e){for(var t=KQ(e),s=t.length;s--;){var p=t[s],c=e[p];t[s]=[p,c,WQ(c)]}return t}xP.exports=zQ});var J0=le((Ime,CP)=>{function XQ(e,t){return function(s){return s==null?!1:s[e]===t&&(t!==void 0||e in Object(s))}}CP.exports=XQ});var NP=le((Nme,IP)=>{var YQ=_P(),JQ=AP(),QQ=J0();function ZQ(e){var t=JQ(e);return t.length==1&&t[0][2]?QQ(t[0][0],t[0][1]):function(s){return s===e||YQ(s,e,t)}}IP.exports=ZQ});var DP=le((Ome,OP)=>{var eZ=X0(),tZ=h1(),rZ=w1(),iZ=nd(),sZ=Y0(),nZ=J0(),aZ=Sl(),oZ=1,lZ=2;function uZ(e,t){return iZ(e)&&sZ(t)?nZ(aZ(e),t):function(s){var p=tZ(s,e);return p===void 0&&p===t?rZ(s,e):eZ(t,p,oZ|lZ)}}OP.exports=uZ});var RP=le((Dme,kP)=>{function pZ(e){return function(t){return t==null?void 0:t[e]}}kP.exports=pZ});var FP=le((kme,LP)=>{var cZ=ud();function dZ(e){return function(t){return cZ(t,e)}}LP.exports=dZ});var MP=le((Rme,jP)=>{var hZ=RP(),fZ=FP(),mZ=nd(),yZ=Sl();function gZ(e){return mZ(e)?hZ(yZ(e)):fZ(e)}jP.exports=gZ});var Q0=le((Lme,BP)=>{var bZ=NP(),vZ=DP(),EZ=P1(),TZ=mn(),SZ=MP();function wZ(e){return typeof e=="function"?e:e==null?EZ:typeof e=="object"?TZ(e)?vZ(e[0],e[1]):bZ(e):SZ(e)}BP.exports=wZ});var Z0=le((Fme,UP)=>{var _Z=pd(),PZ=B0(),xZ=Q0();function AZ(e,t){var s={};return t=xZ(t,3),PZ(e,function(p,c,i){_Z(s,c,t(p,c,i))}),s}UP.exports=AZ});var Ip=le((jme,HP)=>{"use strict";function wo(e){this._maxSize=e,this.clear()}wo.prototype.clear=function(){this._size=0,this._values=Object.create(null)};wo.prototype.get=function(e){return this._values[e]};wo.prototype.set=function(e,t){return this._size>=this._maxSize&&this.clear(),e in this._values||this._size++,this._values[e]=t};var CZ=/[^.^\]^[]+|(?=\[\]|\.\.)/g,VP=/^\d+$/,IZ=/^\d/,NZ=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,OZ=/^\s*(['"]?)(.*?)(\1)\s*$/,ey=512,$P=new wo(ey),GP=new wo(ey),qP=new wo(ey);HP.exports={Cache:wo,split:ry,normalizePath:ty,setter:function(e){var t=ty(e);return GP.get(e)||GP.set(e,function(p,c){for(var i=0,d=t.length,a=p;i{"use strict";Object.defineProperty(Np,"__esModule",{value:!0});Np.create=jZ;Np.default=void 0;var FZ=Ip(),Ph={context:"$",value:"."};function jZ(e,t){return new xh(e,t)}var xh=class{constructor(t,s={}){if(typeof t!="string")throw new TypeError("ref must be a string, got: "+t);if(this.key=t.trim(),t==="")throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===Ph.context,this.isValue=this.key[0]===Ph.value,this.isSibling=!this.isContext&&!this.isValue;let p=this.isContext?Ph.context:this.isValue?Ph.value:"";this.path=this.key.slice(p.length),this.getter=this.path&&(0,FZ.getter)(this.path,!0),this.map=s.map}getValue(t,s,p){let c=this.isContext?p:this.isValue?t:s;return this.getter&&(c=this.getter(c||{})),this.map&&(c=this.map(c)),c}cast(t,s){return this.getValue(t,s==null?void 0:s.parent,s==null?void 0:s.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(t){return t&&t.__isYupRef}};Np.default=xh;xh.prototype.__isYupRef=!0});var WP=le(ny=>{"use strict";Object.defineProperty(ny,"__esModule",{value:!0});ny.default=VZ;var MZ=sy(Z0()),Ah=sy(To()),BZ=sy(_o());function sy(e){return e&&e.__esModule?e:{default:e}}function Ch(){return Ch=Object.assign||function(e){for(var t=1;t=0)&&(s[c]=e[c]);return s}function VZ(e){function t(s,p){let{value:c,path:i="",label:d,options:a,originalValue:o,sync:n}=s,l=UZ(s,["value","path","label","options","originalValue","sync"]),{name:g,test:h,params:m,message:b}=e,{parent:E,context:_}=a;function C(I){return BZ.default.isRef(I)?I.getValue(c,E,_):I}function T(I={}){let S=(0,MZ.default)(Ch({value:c,originalValue:o,label:d,path:I.path||i},m,I.params),C),j=new Ah.default(Ah.default.formatError(I.message||b,S),c,S.path,I.type||g);return j.params=S,j}let w=Ch({path:i,parent:E,type:g,createError:T,resolve:C,options:a,originalValue:o},l);if(!n){try{Promise.resolve(h.call(w,c,w)).then(I=>{Ah.default.isError(I)?p(I):I?p(null,I):p(T())})}catch(I){p(I)}return}let A;try{var x;if(A=h.call(w,c,w),typeof((x=A)==null?void 0:x.then)=="function")throw new Error(`Validation test of type: "${w.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`)}catch(I){p(I);return}Ah.default.isError(A)?p(A):A?p(null,A):p(T())}return t.OPTIONS=e,t}});var ay=le(Op=>{"use strict";Object.defineProperty(Op,"__esModule",{value:!0});Op.getIn=KP;Op.default=void 0;var $Z=Ip(),GZ=e=>e.substr(0,e.length-1).substr(1);function KP(e,t,s,p=s){let c,i,d;return t?((0,$Z.forEach)(t,(a,o,n)=>{let l=o?GZ(a):a;if(e=e.resolve({context:p,parent:c,value:s}),e.innerType){let g=n?parseInt(l,10):0;if(s&&g>=s.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${a}, in the path: ${t}. because there is no value at that index. `);c=s,s=s&&s[g],e=e.innerType}if(!n){if(!e.fields||!e.fields[l])throw new Error(`The schema does not contain the path: ${t}. (failed at: ${d} which is a type: "${e._type}")`);c=s,s=s&&s[l],e=e.fields[l]}i=l,d=o?"["+a+"]":"."+a}),{schema:e,parent:c,parentPath:i}):{parent:c,parentPath:t,schema:e}}var qZ=(e,t,s,p)=>KP(e,t,s,p).schema,HZ=qZ;Op.default=HZ});var XP=le(Nh=>{"use strict";Object.defineProperty(Nh,"__esModule",{value:!0});Nh.default=void 0;var zP=WZ(_o());function WZ(e){return e&&e.__esModule?e:{default:e}}var Ih=class{constructor(){this.list=new Set,this.refs=new Map}get size(){return this.list.size+this.refs.size}describe(){let t=[];for(let s of this.list)t.push(s);for(let[,s]of this.refs)t.push(s.describe());return t}toArray(){return Array.from(this.list).concat(Array.from(this.refs.values()))}add(t){zP.default.isRef(t)?this.refs.set(t.key,t):this.list.add(t)}delete(t){zP.default.isRef(t)?this.refs.delete(t.key):this.list.delete(t)}has(t,s){if(this.list.has(t))return!0;let p,c=this.refs.values();for(;p=c.next(),!p.done;)if(s(p.value)===t)return!0;return!1}clone(){let t=new Ih;return t.list=new Set(this.list),t.refs=new Map(this.refs),t}merge(t,s){let p=this.clone();return t.list.forEach(c=>p.add(c)),t.refs.forEach(c=>p.add(c)),s.list.forEach(c=>p.delete(c)),s.refs.forEach(c=>p.delete(c)),p}};Nh.default=Ih});var Zn=le(Dh=>{"use strict";Object.defineProperty(Dh,"__esModule",{value:!0});Dh.default=void 0;var YP=Qn(aw()),Gl=Jn(),KZ=Qn(Tw()),JP=Qn(Th()),Oh=Qn(WP()),QP=Qn(_p()),zZ=Qn(_o()),XZ=ay(),YZ=Qn(D0()),ZP=Qn(To()),ex=Qn(XP());function Qn(e){return e&&e.__esModule?e:{default:e}}function xs(){return xs=Object.assign||function(e){for(var t=1;t{this.typeError(Gl.mixed.notType)}),this.type=(t==null?void 0:t.type)||"mixed",this.spec=xs({strip:!1,strict:!1,abortEarly:!0,recursive:!0,nullable:!1,presence:"optional"},t==null?void 0:t.spec)}get _type(){return this.type}_typeCheck(t){return!0}clone(t){if(this._mutate)return t&&Object.assign(this.spec,t),this;let s=Object.create(Object.getPrototypeOf(this));return s.type=this.type,s._typeError=this._typeError,s._whitelistError=this._whitelistError,s._blacklistError=this._blacklistError,s._whitelist=this._whitelist.clone(),s._blacklist=this._blacklist.clone(),s.exclusiveTests=xs({},this.exclusiveTests),s.deps=[...this.deps],s.conditions=[...this.conditions],s.tests=[...this.tests],s.transforms=[...this.transforms],s.spec=(0,YP.default)(xs({},this.spec,t)),s}label(t){var s=this.clone();return s.spec.label=t,s}meta(...t){if(t.length===0)return this.spec.meta;let s=this.clone();return s.spec.meta=Object.assign(s.spec.meta||{},t[0]),s}withMutation(t){let s=this._mutate;this._mutate=!0;let p=t(this);return this._mutate=s,p}concat(t){if(!t||t===this)return this;if(t.type!==this.type&&this.type!=="mixed")throw new TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${t.type}`);let s=this,p=t.clone(),c=xs({},s.spec,p.spec);return p.spec=c,p._typeError||(p._typeError=s._typeError),p._whitelistError||(p._whitelistError=s._whitelistError),p._blacklistError||(p._blacklistError=s._blacklistError),p._whitelist=s._whitelist.merge(t._whitelist,t._blacklist),p._blacklist=s._blacklist.merge(t._blacklist,t._whitelist),p.tests=s.tests,p.exclusiveTests=s.exclusiveTests,p.withMutation(i=>{t.tests.forEach(d=>{i.test(d.OPTIONS)})}),p}isType(t){return this.spec.nullable&&t===null?!0:this._typeCheck(t)}resolve(t){let s=this;if(s.conditions.length){let p=s.conditions;s=s.clone(),s.conditions=[],s=p.reduce((c,i)=>i.resolve(c,t),s),s=s.resolve(t)}return s}cast(t,s={}){let p=this.resolve(xs({value:t},s)),c=p._cast(t,s);if(t!==void 0&&s.assert!==!1&&p.isType(c)!==!0){let i=(0,QP.default)(t),d=(0,QP.default)(c);throw new TypeError(`The value of ${s.path||"field"} could not be cast to a value that satisfies the schema type: "${p._type}". attempted value: ${i} -`+(d!==i?`result of cast: ${d}`:""))}return c}_cast(t,s){let p=t===void 0?t:this.transforms.reduce((c,i)=>i.call(this,c,t,this),t);return p===void 0&&(p=this.getDefault()),p}_validate(t,s={},p){let{sync:c,path:i,from:d=[],originalValue:a=t,strict:o=this.spec.strict,abortEarly:n=this.spec.abortEarly}=s,l=t;o||(l=this._cast(l,xs({assert:!1},s)));let g={value:l,path:i,options:s,originalValue:a,schema:this,label:this.spec.label,sync:c,from:d},h=[];this._typeError&&h.push(this._typeError),this._whitelistError&&h.push(this._whitelistError),this._blacklistError&&h.push(this._blacklistError),(0,JP.default)({args:g,value:l,path:i,sync:c,tests:h,endEarly:n},m=>{if(m)return void p(m,l);(0,JP.default)({tests:this.tests,args:g,path:i,sync:c,value:l,endEarly:n},p)})}validate(t,s,p){let c=this.resolve(xs({},s,{value:t}));return typeof p=="function"?c._validate(t,s,p):new Promise((i,d)=>c._validate(t,s,(a,o)=>{a?d(a):i(o)}))}validateSync(t,s){let p=this.resolve(xs({},s,{value:t})),c;return p._validate(t,xs({},s,{sync:!0}),(i,d)=>{if(i)throw i;c=d}),c}isValid(t,s){return this.validate(t,s).then(()=>!0,p=>{if(ZP.default.isError(p))return!1;throw p})}isValidSync(t,s){try{return this.validateSync(t,s),!0}catch(p){if(ZP.default.isError(p))return!1;throw p}}_getDefault(){let t=this.spec.default;return t==null?t:typeof t=="function"?t.call(this):(0,YP.default)(t)}getDefault(t){return this.resolve(t||{})._getDefault()}default(t){return arguments.length===0?this._getDefault():this.clone({default:t})}strict(t=!0){var s=this.clone();return s.spec.strict=t,s}_isPresent(t){return t!=null}defined(t=Gl.mixed.defined){return this.test({message:t,name:"defined",exclusive:!0,test(s){return s!==void 0}})}required(t=Gl.mixed.required){return this.clone({presence:"required"}).withMutation(s=>s.test({message:t,name:"required",exclusive:!0,test(p){return this.schema._isPresent(p)}}))}notRequired(){var t=this.clone({presence:"optional"});return t.tests=t.tests.filter(s=>s.OPTIONS.name!=="required"),t}nullable(t=!0){var s=this.clone({nullable:t!==!1});return s}transform(t){var s=this.clone();return s.transforms.push(t),s}test(...t){let s;if(t.length===1?typeof t[0]=="function"?s={test:t[0]}:s=t[0]:t.length===2?s={name:t[0],test:t[1]}:s={name:t[0],message:t[1],test:t[2]},s.message===void 0&&(s.message=Gl.mixed.default),typeof s.test!="function")throw new TypeError("`test` is a required parameters");let p=this.clone(),c=(0,Oh.default)(s),i=s.exclusive||s.name&&p.exclusiveTests[s.name]===!0;if(s.exclusive&&!s.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return s.name&&(p.exclusiveTests[s.name]=!!s.exclusive),p.tests=p.tests.filter(d=>!(d.OPTIONS.name===s.name&&(i||d.OPTIONS.test===c.OPTIONS.test))),p.tests.push(c),p}when(t,s){!Array.isArray(t)&&typeof t!="string"&&(s=t,t=".");let p=this.clone(),c=(0,YZ.default)(t).map(i=>new zZ.default(i));return c.forEach(i=>{i.isSibling&&p.deps.push(i.key)}),p.conditions.push(new KZ.default(c,s)),p}typeError(t){var s=this.clone();return s._typeError=(0,Oh.default)({message:t,name:"typeError",test(p){return p!==void 0&&!this.schema.isType(p)?this.createError({params:{type:this.schema._type}}):!0}}),s}oneOf(t,s=Gl.mixed.oneOf){var p=this.clone();return t.forEach(c=>{p._whitelist.add(c),p._blacklist.delete(c)}),p._whitelistError=(0,Oh.default)({message:s,name:"oneOf",test(c){if(c===void 0)return!0;let i=this.schema._whitelist;return i.has(c,this.resolve)?!0:this.createError({params:{values:i.toArray().join(", ")}})}}),p}notOneOf(t,s=Gl.mixed.notOneOf){var p=this.clone();return t.forEach(c=>{p._blacklist.add(c),p._whitelist.delete(c)}),p._blacklistError=(0,Oh.default)({message:s,name:"notOneOf",test(c){let i=this.schema._blacklist;return i.has(c,this.resolve)?this.createError({params:{values:i.toArray().join(", ")}}):!0}}),p}strip(t=!0){let s=this.clone();return s.spec.strip=t,s}describe(){let t=this.clone(),{label:s,meta:p}=t.spec;return{meta:p,label:s,type:t.type,oneOf:t._whitelist.describe(),notOneOf:t._blacklist.describe(),tests:t.tests.map(i=>({name:i.OPTIONS.name,params:i.OPTIONS.params})).filter((i,d,a)=>a.findIndex(o=>o.name===i.name)===d)}}};Dh.default=En;En.prototype.__isYupSchema__=!0;for(let e of["validate","validateSync"])En.prototype[`${e}At`]=function(t,s,p={}){let{parent:c,parentPath:i,schema:d}=(0,XZ.getIn)(this,t,s,p.context);return d[e](c&&c[i],xs({},p,{parent:c,path:t}))};for(let e of["equals","is"])En.prototype[e]=En.prototype.oneOf;for(let e of["not","nope"])En.prototype[e]=En.prototype.notOneOf;En.prototype.optional=En.prototype.notRequired});var rx=le(Dp=>{"use strict";Object.defineProperty(Dp,"__esModule",{value:!0});Dp.create=tx;Dp.default=void 0;var JZ=QZ(Zn());function QZ(e){return e&&e.__esModule?e:{default:e}}var oy=JZ.default,ZZ=oy;Dp.default=ZZ;function tx(){return new oy}tx.prototype=oy.prototype});var ql=le(kh=>{"use strict";Object.defineProperty(kh,"__esModule",{value:!0});kh.default=void 0;var eee=e=>e==null;kh.default=eee});var ox=le(kp=>{"use strict";Object.defineProperty(kp,"__esModule",{value:!0});kp.create=ax;kp.default=void 0;var tee=nx(Zn()),ix=Jn(),sx=nx(ql());function nx(e){return e&&e.__esModule?e:{default:e}}function ax(){return new Rh}var Rh=class extends tee.default{constructor(){super({type:"boolean"});this.withMutation(()=>{this.transform(function(t){if(!this.isType(t)){if(/^(true|1)$/i.test(String(t)))return!0;if(/^(false|0)$/i.test(String(t)))return!1}return t})})}_typeCheck(t){return t instanceof Boolean&&(t=t.valueOf()),typeof t=="boolean"}isTrue(t=ix.boolean.isValue){return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"true"},test(s){return(0,sx.default)(s)||s===!0}})}isFalse(t=ix.boolean.isValue){return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"false"},test(s){return(0,sx.default)(s)||s===!1}})}};kp.default=Rh;ax.prototype=Rh.prototype});var px=le(Rp=>{"use strict";Object.defineProperty(Rp,"__esModule",{value:!0});Rp.create=ux;Rp.default=void 0;var Tn=Jn(),ea=lx(ql()),ree=lx(Zn());function lx(e){return e&&e.__esModule?e:{default:e}}var iee=/^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))$/i,see=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,nee=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,aee=e=>(0,ea.default)(e)||e===e.trim(),oee={}.toString();function ux(){return new Lh}var Lh=class extends ree.default{constructor(){super({type:"string"});this.withMutation(()=>{this.transform(function(t){if(this.isType(t)||Array.isArray(t))return t;let s=t!=null&&t.toString?t.toString():t;return s===oee?t:s})})}_typeCheck(t){return t instanceof String&&(t=t.valueOf()),typeof t=="string"}_isPresent(t){return super._isPresent(t)&&!!t.length}length(t,s=Tn.string.length){return this.test({message:s,name:"length",exclusive:!0,params:{length:t},test(p){return(0,ea.default)(p)||p.length===this.resolve(t)}})}min(t,s=Tn.string.min){return this.test({message:s,name:"min",exclusive:!0,params:{min:t},test(p){return(0,ea.default)(p)||p.length>=this.resolve(t)}})}max(t,s=Tn.string.max){return this.test({name:"max",exclusive:!0,message:s,params:{max:t},test(p){return(0,ea.default)(p)||p.length<=this.resolve(t)}})}matches(t,s){let p=!1,c,i;return s&&(typeof s=="object"?{excludeEmptyString:p=!1,message:c,name:i}=s:c=s),this.test({name:i||"matches",message:c||Tn.string.matches,params:{regex:t},test:d=>(0,ea.default)(d)||d===""&&p||d.search(t)!==-1})}email(t=Tn.string.email){return this.matches(iee,{name:"email",message:t,excludeEmptyString:!0})}url(t=Tn.string.url){return this.matches(see,{name:"url",message:t,excludeEmptyString:!0})}uuid(t=Tn.string.uuid){return this.matches(nee,{name:"uuid",message:t,excludeEmptyString:!1})}ensure(){return this.default("").transform(t=>t===null?"":t)}trim(t=Tn.string.trim){return this.transform(s=>s!=null?s.trim():s).test({message:t,name:"trim",test:aee})}lowercase(t=Tn.string.lowercase){return this.transform(s=>(0,ea.default)(s)?s:s.toLowerCase()).test({message:t,name:"string_case",exclusive:!0,test:s=>(0,ea.default)(s)||s===s.toLowerCase()})}uppercase(t=Tn.string.uppercase){return this.transform(s=>(0,ea.default)(s)?s:s.toUpperCase()).test({message:t,name:"string_case",exclusive:!0,test:s=>(0,ea.default)(s)||s===s.toUpperCase()})}};Rp.default=Lh;ux.prototype=Lh.prototype});var hx=le(Lp=>{"use strict";Object.defineProperty(Lp,"__esModule",{value:!0});Lp.create=dx;Lp.default=void 0;var Po=Jn(),xo=cx(ql()),lee=cx(Zn());function cx(e){return e&&e.__esModule?e:{default:e}}var uee=e=>e!=+e;function dx(){return new Fh}var Fh=class extends lee.default{constructor(){super({type:"number"});this.withMutation(()=>{this.transform(function(t){let s=t;if(typeof s=="string"){if(s=s.replace(/\s/g,""),s==="")return NaN;s=+s}return this.isType(s)?s:parseFloat(s)})})}_typeCheck(t){return t instanceof Number&&(t=t.valueOf()),typeof t=="number"&&!uee(t)}min(t,s=Po.number.min){return this.test({message:s,name:"min",exclusive:!0,params:{min:t},test(p){return(0,xo.default)(p)||p>=this.resolve(t)}})}max(t,s=Po.number.max){return this.test({message:s,name:"max",exclusive:!0,params:{max:t},test(p){return(0,xo.default)(p)||p<=this.resolve(t)}})}lessThan(t,s=Po.number.lessThan){return this.test({message:s,name:"max",exclusive:!0,params:{less:t},test(p){return(0,xo.default)(p)||pthis.resolve(t)}})}positive(t=Po.number.positive){return this.moreThan(0,t)}negative(t=Po.number.negative){return this.lessThan(0,t)}integer(t=Po.number.integer){return this.test({name:"integer",message:t,test:s=>(0,xo.default)(s)||Number.isInteger(s)})}truncate(){return this.transform(t=>(0,xo.default)(t)?t:t|0)}round(t){var s,p=["ceil","floor","round","trunc"];if(t=((s=t)==null?void 0:s.toLowerCase())||"round",t==="trunc")return this.truncate();if(p.indexOf(t.toLowerCase())===-1)throw new TypeError("Only valid options for round() are: "+p.join(", "));return this.transform(c=>(0,xo.default)(c)?c:Math[t](c))}};Lp.default=Fh;dx.prototype=Fh.prototype});var fx=le(ly=>{"use strict";Object.defineProperty(ly,"__esModule",{value:!0});ly.default=cee;var pee=/^(\d{4}|[+\-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,\.](\d{1,}))?)?(?:(Z)|([+\-])(\d{2})(?::?(\d{2}))?)?)?$/;function cee(e){var t=[1,4,5,6,7,10,11],s=0,p,c;if(c=pee.exec(e)){for(var i=0,d;d=t[i];++i)c[d]=+c[d]||0;c[2]=(+c[2]||1)-1,c[3]=+c[3]||1,c[7]=c[7]?String(c[7]).substr(0,3):0,(c[8]===void 0||c[8]==="")&&(c[9]===void 0||c[9]==="")?p=+new Date(c[1],c[2],c[3],c[4],c[5],c[6],c[7]):(c[8]!=="Z"&&c[9]!==void 0&&(s=c[10]*60+c[11],c[9]==="+"&&(s=0-s)),p=Date.UTC(c[1],c[2],c[3],c[4],c[5]+s,c[6],c[7]))}else p=Date.parse?Date.parse(e):NaN;return p}});var gx=le(jp=>{"use strict";Object.defineProperty(jp,"__esModule",{value:!0});jp.create=py;jp.default=void 0;var dee=jh(fx()),mx=Jn(),yx=jh(ql()),hee=jh(_o()),fee=jh(Zn());function jh(e){return e&&e.__esModule?e:{default:e}}var uy=new Date(""),mee=e=>Object.prototype.toString.call(e)==="[object Date]";function py(){return new Fp}var Fp=class extends fee.default{constructor(){super({type:"date"});this.withMutation(()=>{this.transform(function(t){return this.isType(t)?t:(t=(0,dee.default)(t),isNaN(t)?uy:new Date(t))})})}_typeCheck(t){return mee(t)&&!isNaN(t.getTime())}prepareParam(t,s){let p;if(hee.default.isRef(t))p=t;else{let c=this.cast(t);if(!this._typeCheck(c))throw new TypeError(`\`${s}\` must be a Date or a value that can be \`cast()\` to a Date`);p=c}return p}min(t,s=mx.date.min){let p=this.prepareParam(t,"min");return this.test({message:s,name:"min",exclusive:!0,params:{min:t},test(c){return(0,yx.default)(c)||c>=this.resolve(p)}})}max(t,s=mx.date.max){var p=this.prepareParam(t,"max");return this.test({message:s,name:"max",exclusive:!0,params:{max:t},test(c){return(0,yx.default)(c)||c<=this.resolve(p)}})}};jp.default=Fp;Fp.INVALID_DATE=uy;py.prototype=Fp.prototype;py.INVALID_DATE=uy});var vx=le((Yme,bx)=>{function yee(e,t,s,p){var c=-1,i=e==null?0:e.length;for(p&&i&&(s=e[++c]);++c{function gee(e){return function(t){return e==null?void 0:e[t]}}Ex.exports=gee});var wx=le((Qme,Sx)=>{var bee=Tx(),vee={\u00C0:"A",\u00C1:"A",\u00C2:"A",\u00C3:"A",\u00C4:"A",\u00C5:"A",\u00E0:"a",\u00E1:"a",\u00E2:"a",\u00E3:"a",\u00E4:"a",\u00E5:"a",\u00C7:"C",\u00E7:"c",\u00D0:"D",\u00F0:"d",\u00C8:"E",\u00C9:"E",\u00CA:"E",\u00CB:"E",\u00E8:"e",\u00E9:"e",\u00EA:"e",\u00EB:"e",\u00CC:"I",\u00CD:"I",\u00CE:"I",\u00CF:"I",\u00EC:"i",\u00ED:"i",\u00EE:"i",\u00EF:"i",\u00D1:"N",\u00F1:"n",\u00D2:"O",\u00D3:"O",\u00D4:"O",\u00D5:"O",\u00D6:"O",\u00D8:"O",\u00F2:"o",\u00F3:"o",\u00F4:"o",\u00F5:"o",\u00F6:"o",\u00F8:"o",\u00D9:"U",\u00DA:"U",\u00DB:"U",\u00DC:"U",\u00F9:"u",\u00FA:"u",\u00FB:"u",\u00FC:"u",\u00DD:"Y",\u00FD:"y",\u00FF:"y",\u00C6:"Ae",\u00E6:"ae",\u00DE:"Th",\u00FE:"th",\u00DF:"ss",\u0100:"A",\u0102:"A",\u0104:"A",\u0101:"a",\u0103:"a",\u0105:"a",\u0106:"C",\u0108:"C",\u010A:"C",\u010C:"C",\u0107:"c",\u0109:"c",\u010B:"c",\u010D:"c",\u010E:"D",\u0110:"D",\u010F:"d",\u0111:"d",\u0112:"E",\u0114:"E",\u0116:"E",\u0118:"E",\u011A:"E",\u0113:"e",\u0115:"e",\u0117:"e",\u0119:"e",\u011B:"e",\u011C:"G",\u011E:"G",\u0120:"G",\u0122:"G",\u011D:"g",\u011F:"g",\u0121:"g",\u0123:"g",\u0124:"H",\u0126:"H",\u0125:"h",\u0127:"h",\u0128:"I",\u012A:"I",\u012C:"I",\u012E:"I",\u0130:"I",\u0129:"i",\u012B:"i",\u012D:"i",\u012F:"i",\u0131:"i",\u0134:"J",\u0135:"j",\u0136:"K",\u0137:"k",\u0138:"k",\u0139:"L",\u013B:"L",\u013D:"L",\u013F:"L",\u0141:"L",\u013A:"l",\u013C:"l",\u013E:"l",\u0140:"l",\u0142:"l",\u0143:"N",\u0145:"N",\u0147:"N",\u014A:"N",\u0144:"n",\u0146:"n",\u0148:"n",\u014B:"n",\u014C:"O",\u014E:"O",\u0150:"O",\u014D:"o",\u014F:"o",\u0151:"o",\u0154:"R",\u0156:"R",\u0158:"R",\u0155:"r",\u0157:"r",\u0159:"r",\u015A:"S",\u015C:"S",\u015E:"S",\u0160:"S",\u015B:"s",\u015D:"s",\u015F:"s",\u0161:"s",\u0162:"T",\u0164:"T",\u0166:"T",\u0163:"t",\u0165:"t",\u0167:"t",\u0168:"U",\u016A:"U",\u016C:"U",\u016E:"U",\u0170:"U",\u0172:"U",\u0169:"u",\u016B:"u",\u016D:"u",\u016F:"u",\u0171:"u",\u0173:"u",\u0174:"W",\u0175:"w",\u0176:"Y",\u0177:"y",\u0178:"Y",\u0179:"Z",\u017B:"Z",\u017D:"Z",\u017A:"z",\u017C:"z",\u017E:"z",\u0132:"IJ",\u0133:"ij",\u0152:"Oe",\u0153:"oe",\u0149:"'n",\u017F:"s"},Eee=bee(vee);Sx.exports=Eee});var Px=le((Zme,_x)=>{var Tee=wx(),See=Tl(),wee=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,_ee="\\u0300-\\u036f",Pee="\\ufe20-\\ufe2f",xee="\\u20d0-\\u20ff",Aee=_ee+Pee+xee,Cee="["+Aee+"]",Iee=RegExp(Cee,"g");function Nee(e){return e=See(e),e&&e.replace(wee,Tee).replace(Iee,"")}_x.exports=Nee});var Ax=le((e1e,xx)=>{var Oee=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function Dee(e){return e.match(Oee)||[]}xx.exports=Dee});var Ix=le((t1e,Cx)=>{var kee=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function Ree(e){return kee.test(e)}Cx.exports=Ree});var zx=le((r1e,Kx)=>{var Nx="\\ud800-\\udfff",Lee="\\u0300-\\u036f",Fee="\\ufe20-\\ufe2f",jee="\\u20d0-\\u20ff",Mee=Lee+Fee+jee,Ox="\\u2700-\\u27bf",Dx="a-z\\xdf-\\xf6\\xf8-\\xff",Bee="\\xac\\xb1\\xd7\\xf7",Uee="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",Vee="\\u2000-\\u206f",$ee=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",kx="A-Z\\xc0-\\xd6\\xd8-\\xde",Gee="\\ufe0e\\ufe0f",Rx=Bee+Uee+Vee+$ee,Lx="['\u2019]",Fx="["+Rx+"]",qee="["+Mee+"]",jx="\\d+",Hee="["+Ox+"]",Mx="["+Dx+"]",Bx="[^"+Nx+Rx+jx+Ox+Dx+kx+"]",Wee="\\ud83c[\\udffb-\\udfff]",Kee="(?:"+qee+"|"+Wee+")",zee="[^"+Nx+"]",Ux="(?:\\ud83c[\\udde6-\\uddff]){2}",Vx="[\\ud800-\\udbff][\\udc00-\\udfff]",Hl="["+kx+"]",Xee="\\u200d",$x="(?:"+Mx+"|"+Bx+")",Yee="(?:"+Hl+"|"+Bx+")",Gx="(?:"+Lx+"(?:d|ll|m|re|s|t|ve))?",qx="(?:"+Lx+"(?:D|LL|M|RE|S|T|VE))?",Hx=Kee+"?",Wx="["+Gee+"]?",Jee="(?:"+Xee+"(?:"+[zee,Ux,Vx].join("|")+")"+Wx+Hx+")*",Qee="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Zee="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",ete=Wx+Hx+Jee,tte="(?:"+[Hee,Ux,Vx].join("|")+")"+ete,rte=RegExp([Hl+"?"+Mx+"+"+Gx+"(?="+[Fx,Hl,"$"].join("|")+")",Yee+"+"+qx+"(?="+[Fx,Hl+$x,"$"].join("|")+")",Hl+"?"+$x+"+"+Gx,Hl+"+"+qx,Zee,Qee,jx,tte].join("|"),"g");function ite(e){return e.match(rte)||[]}Kx.exports=ite});var Yx=le((i1e,Xx)=>{var ste=Ax(),nte=Ix(),ate=Tl(),ote=zx();function lte(e,t,s){return e=ate(e),t=s?void 0:t,t===void 0?nte(e)?ote(e):ste(e):e.match(t)||[]}Xx.exports=lte});var cy=le((s1e,Jx)=>{var ute=vx(),pte=Px(),cte=Yx(),dte="['\u2019]",hte=RegExp(dte,"g");function fte(e){return function(t){return ute(cte(pte(t).replace(hte,"")),e,"")}}Jx.exports=fte});var Zx=le((n1e,Qx)=>{var mte=cy(),yte=mte(function(e,t,s){return e+(s?"_":"")+t.toLowerCase()});Qx.exports=yte});var tA=le((a1e,eA)=>{function gte(e,t,s){var p=-1,c=e.length;t<0&&(t=-t>c?0:c+t),s=s>c?c:s,s<0&&(s+=c),c=t>s?0:s-t>>>0,t>>>=0;for(var i=Array(c);++p{var bte=tA();function vte(e,t,s){var p=e.length;return s=s===void 0?p:s,!t&&s>=p?e:bte(e,t,s)}rA.exports=vte});var dy=le((l1e,sA)=>{var Ete="\\ud800-\\udfff",Tte="\\u0300-\\u036f",Ste="\\ufe20-\\ufe2f",wte="\\u20d0-\\u20ff",_te=Tte+Ste+wte,Pte="\\ufe0e\\ufe0f",xte="\\u200d",Ate=RegExp("["+xte+Ete+_te+Pte+"]");function Cte(e){return Ate.test(e)}sA.exports=Cte});var aA=le((u1e,nA)=>{function Ite(e){return e.split("")}nA.exports=Ite});var fA=le((p1e,hA)=>{var oA="\\ud800-\\udfff",Nte="\\u0300-\\u036f",Ote="\\ufe20-\\ufe2f",Dte="\\u20d0-\\u20ff",kte=Nte+Ote+Dte,Rte="\\ufe0e\\ufe0f",Lte="["+oA+"]",hy="["+kte+"]",fy="\\ud83c[\\udffb-\\udfff]",Fte="(?:"+hy+"|"+fy+")",lA="[^"+oA+"]",uA="(?:\\ud83c[\\udde6-\\uddff]){2}",pA="[\\ud800-\\udbff][\\udc00-\\udfff]",jte="\\u200d",cA=Fte+"?",dA="["+Rte+"]?",Mte="(?:"+jte+"(?:"+[lA,uA,pA].join("|")+")"+dA+cA+")*",Bte=dA+cA+Mte,Ute="(?:"+[lA+hy+"?",hy,uA,pA,Lte].join("|")+")",Vte=RegExp(fy+"(?="+fy+")|"+Ute+Bte,"g");function $te(e){return e.match(Vte)||[]}hA.exports=$te});var yA=le((c1e,mA)=>{var Gte=aA(),qte=dy(),Hte=fA();function Wte(e){return qte(e)?Hte(e):Gte(e)}mA.exports=Wte});var bA=le((d1e,gA)=>{var Kte=iA(),zte=dy(),Xte=yA(),Yte=Tl();function Jte(e){return function(t){t=Yte(t);var s=zte(t)?Xte(t):void 0,p=s?s[0]:t.charAt(0),c=s?Kte(s,1).join(""):t.slice(1);return p[e]()+c}}gA.exports=Jte});var EA=le((h1e,vA)=>{var Qte=bA(),Zte=Qte("toUpperCase");vA.exports=Zte});var SA=le((f1e,TA)=>{var ere=Tl(),tre=EA();function rre(e){return tre(ere(e).toLowerCase())}TA.exports=rre});var _A=le((m1e,wA)=>{var ire=SA(),sre=cy(),nre=sre(function(e,t,s){return t=t.toLowerCase(),e+(s?ire(t):t)});wA.exports=nre});var xA=le((y1e,PA)=>{var are=pd(),ore=B0(),lre=Q0();function ure(e,t){var s={};return t=lre(t,3),ore(e,function(p,c,i){are(s,t(p,c,i),p)}),s}PA.exports=ure});var CA=le((g1e,my)=>{my.exports=function(e){return AA(pre(e),e)};my.exports.array=AA;function AA(e,t){var s=e.length,p=new Array(s),c={},i=s,d=cre(t),a=dre(e);for(t.forEach(function(n){if(!a.has(n[0])||!a.has(n[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});i--;)c[i]||o(e[i],i,new Set);return p;function o(n,l,g){if(g.has(n)){var h;try{h=", node was:"+JSON.stringify(n)}catch(E){h=""}throw new Error("Cyclic dependency"+h)}if(!a.has(n))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(n));if(!c[l]){c[l]=!0;var m=d.get(n)||new Set;if(m=Array.from(m),l=m.length){g.add(n);do{var b=m[--l];o(b,a.get(b),g)}while(l);g.delete(n)}p[--s]=n}}}function pre(e){for(var t=new Set,s=0,p=e.length;s{"use strict";Object.defineProperty(yy,"__esModule",{value:!0});yy.default=bre;var hre=Mh(gh()),fre=Mh(CA()),mre=Ip(),yre=Mh(_o()),gre=Mh(Ml());function Mh(e){return e&&e.__esModule?e:{default:e}}function bre(e,t=[]){let s=[],p=[];function c(i,d){var a=(0,mre.split)(i)[0];~p.indexOf(a)||p.push(a),~t.indexOf(`${d}-${a}`)||s.push([d,a])}for(let i in e)if((0,hre.default)(e,i)){let d=e[i];~p.indexOf(i)||p.push(i),yre.default.isRef(d)&&d.isSibling?c(d.path,i):(0,gre.default)(d)&&"deps"in d&&d.deps.forEach(a=>c(a,i))}return fre.default.array(p,s).reverse()}});var OA=le(gy=>{"use strict";Object.defineProperty(gy,"__esModule",{value:!0});gy.default=vre;function NA(e,t){let s=1/0;return e.some((p,c)=>{var i;if(((i=t.path)==null?void 0:i.indexOf(p))!==-1)return s=c,!0}),s}function vre(e){return(t,s)=>NA(e,t)-NA(e,s)}});var MA=le(Mp=>{"use strict";Object.defineProperty(Mp,"__esModule",{value:!0});Mp.create=jA;Mp.default=void 0;var DA=Sn(gh()),kA=Sn(Zx()),Ere=Sn(_A()),Tre=Sn(xA()),Sre=Sn(Z0()),wre=Ip(),RA=Jn(),_re=Sn(IA()),LA=Sn(OA()),Pre=Sn(Th()),xre=Sn(To()),by=Sn(Zn());function Sn(e){return e&&e.__esModule?e:{default:e}}function Wl(){return Wl=Object.assign||function(e){for(var t=1;tObject.prototype.toString.call(e)==="[object Object]";function Are(e,t){let s=Object.keys(e.fields);return Object.keys(t).filter(p=>s.indexOf(p)===-1)}var Cre=(0,LA.default)([]),Bh=class extends by.default{constructor(t){super({type:"object"});this.fields=Object.create(null),this._sortErrors=Cre,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{this.transform(function(p){if(typeof p=="string")try{p=JSON.parse(p)}catch(c){p=null}return this.isType(p)?p:null}),t&&this.shape(t)})}_typeCheck(t){return FA(t)||typeof t=="function"}_cast(t,s={}){var p;let c=super._cast(t,s);if(c===void 0)return this.getDefault();if(!this._typeCheck(c))return c;let i=this.fields,d=(p=s.stripUnknown)!=null?p:this.spec.noUnknown,a=this._nodes.concat(Object.keys(c).filter(g=>this._nodes.indexOf(g)===-1)),o={},n=Wl({},s,{parent:o,__validating:s.__validating||!1}),l=!1;for(let g of a){let h=i[g],m=(0,DA.default)(c,g);if(h){let b,E=c[g];n.path=(s.path?`${s.path}.`:"")+g,h=h.resolve({value:E,context:s.context,parent:o});let _="spec"in h?h.spec:void 0,C=_==null?void 0:_.strict;if(_==null?void 0:_.strip){l=l||g in c;continue}b=!s.__validating||!C?h.cast(c[g],n):c[g],b!==void 0&&(o[g]=b)}else m&&!d&&(o[g]=c[g]);o[g]!==c[g]&&(l=!0)}return l?o:c}_validate(t,s={},p){let c=[],{sync:i,from:d=[],originalValue:a=t,abortEarly:o=this.spec.abortEarly,recursive:n=this.spec.recursive}=s;d=[{schema:this,value:a},...d],s.__validating=!0,s.originalValue=a,s.from=d,super._validate(t,s,(l,g)=>{if(l){if(!xre.default.isError(l)||o)return void p(l,g);c.push(l)}if(!n||!FA(g)){p(c[0]||null,g);return}a=a||g;let h=this._nodes.map(m=>(b,E)=>{let _=m.indexOf(".")===-1?(s.path?`${s.path}.`:"")+m:`${s.path||""}["${m}"]`,C=this.fields[m];if(C&&"validate"in C){C.validate(g[m],Wl({},s,{path:_,from:d,strict:!0,parent:g,originalValue:a[m]}),E);return}E(null)});(0,Pre.default)({sync:i,tests:h,value:g,errors:c,endEarly:o,sort:this._sortErrors,path:s.path},p)})}clone(t){let s=super.clone(t);return s.fields=Wl({},this.fields),s._nodes=this._nodes,s._excludedEdges=this._excludedEdges,s._sortErrors=this._sortErrors,s}concat(t){let s=super.concat(t),p=s.fields;for(let[c,i]of Object.entries(this.fields)){let d=p[c];d===void 0?p[c]=i:d instanceof by.default&&i instanceof by.default&&(p[c]=i.concat(d))}return s.withMutation(()=>s.shape(p))}getDefaultFromShape(){let t={};return this._nodes.forEach(s=>{let p=this.fields[s];t[s]="default"in p?p.getDefault():void 0}),t}_getDefault(){if("default"in this.spec)return super._getDefault();if(!!this._nodes.length)return this.getDefaultFromShape()}shape(t,s=[]){let p=this.clone(),c=Object.assign(p.fields,t);if(p.fields=c,p._sortErrors=(0,LA.default)(Object.keys(c)),s.length){Array.isArray(s[0])||(s=[s]);let i=s.map(([d,a])=>`${d}-${a}`);p._excludedEdges=p._excludedEdges.concat(i)}return p._nodes=(0,_re.default)(c,p._excludedEdges),p}pick(t){let s={};for(let p of t)this.fields[p]&&(s[p]=this.fields[p]);return this.clone().withMutation(p=>(p.fields={},p.shape(s)))}omit(t){let s=this.clone(),p=s.fields;s.fields={};for(let c of t)delete p[c];return s.withMutation(()=>s.shape(p))}from(t,s,p){let c=(0,wre.getter)(t,!0);return this.transform(i=>{if(i==null)return i;let d=i;return(0,DA.default)(i,t)&&(d=Wl({},i),p||delete d[t],d[s]=c(i)),d})}noUnknown(t=!0,s=RA.object.noUnknown){typeof t=="string"&&(s=t,t=!0);let p=this.test({name:"noUnknown",exclusive:!0,message:s,test(c){if(c==null)return!0;let i=Are(this.schema,c);return!t||i.length===0||this.createError({params:{unknown:i.join(", ")}})}});return p.spec.noUnknown=t,p}unknown(t=!0,s=RA.object.noUnknown){return this.noUnknown(!t,s)}transformKeys(t){return this.transform(s=>s&&(0,Tre.default)(s,(p,c)=>t(c)))}camelCase(){return this.transformKeys(Ere.default)}snakeCase(){return this.transformKeys(kA.default)}constantCase(){return this.transformKeys(t=>(0,kA.default)(t).toUpperCase())}describe(){let t=super.describe();return t.fields=(0,Sre.default)(this.fields,s=>s.describe()),t}};Mp.default=Bh;function jA(e){return new Bh(e)}jA.prototype=Bh.prototype});var UA=le(Bp=>{"use strict";Object.defineProperty(Bp,"__esModule",{value:!0});Bp.create=BA;Bp.default=void 0;var vy=Kl(ql()),Ire=Kl(Ml()),Nre=Kl(_p()),Ey=Jn(),Ore=Kl(Th()),Dre=Kl(To()),kre=Kl(Zn());function Kl(e){return e&&e.__esModule?e:{default:e}}function Uh(){return Uh=Object.assign||function(e){for(var t=1;t{this.transform(function(s){if(typeof s=="string")try{s=JSON.parse(s)}catch(p){s=null}return this.isType(s)?s:null})})}_typeCheck(t){return Array.isArray(t)}get _subType(){return this.innerType}_cast(t,s){let p=super._cast(t,s);if(!this._typeCheck(p)||!this.innerType)return p;let c=!1,i=p.map((d,a)=>{let o=this.innerType.cast(d,Uh({},s,{path:`${s.path||""}[${a}]`}));return o!==d&&(c=!0),o});return c?i:p}_validate(t,s={},p){var c,i;let d=[],a=s.sync,o=s.path,n=this.innerType,l=(c=s.abortEarly)!=null?c:this.spec.abortEarly,g=(i=s.recursive)!=null?i:this.spec.recursive,h=s.originalValue!=null?s.originalValue:t;super._validate(t,s,(m,b)=>{if(m){if(!Dre.default.isError(m)||l)return void p(m,b);d.push(m)}if(!g||!n||!this._typeCheck(b)){p(d[0]||null,b);return}h=h||b;let E=new Array(b.length);for(let _=0;_n.validate(C,w,x)}(0,Ore.default)({sync:a,path:o,value:b,errors:d,endEarly:l,tests:E},p)})}clone(t){let s=super.clone(t);return s.innerType=this.innerType,s}concat(t){let s=super.concat(t);return s.innerType=this.innerType,t.innerType&&(s.innerType=s.innerType?s.innerType.concat(t.innerType):t.innerType),s}of(t){let s=this.clone();if(!(0,Ire.default)(t))throw new TypeError("`array.of()` sub-schema must be a valid yup schema not: "+(0,Nre.default)(t));return s.innerType=t,s}length(t,s=Ey.array.length){return this.test({message:s,name:"length",exclusive:!0,params:{length:t},test(p){return(0,vy.default)(p)||p.length===this.resolve(t)}})}min(t,s){return s=s||Ey.array.min,this.test({message:s,name:"min",exclusive:!0,params:{min:t},test(p){return(0,vy.default)(p)||p.length>=this.resolve(t)}})}max(t,s){return s=s||Ey.array.max,this.test({message:s,name:"max",exclusive:!0,params:{max:t},test(p){return(0,vy.default)(p)||p.length<=this.resolve(t)}})}ensure(){return this.default(()=>[]).transform((t,s)=>this._typeCheck(t)?t:s==null?[]:[].concat(s))}compact(t){let s=t?(p,c,i)=>!t(p,c,i):p=>!!p;return this.transform(p=>p!=null?p.filter(s):p)}describe(){let t=super.describe();return this.innerType&&(t.innerType=this.innerType.describe()),t}nullable(t=!0){return super.nullable(t)}defined(){return super.defined()}required(t){return super.required(t)}};Bp.default=Vh;BA.prototype=Vh.prototype});var VA=le(Up=>{"use strict";Object.defineProperty(Up,"__esModule",{value:!0});Up.create=Fre;Up.default=void 0;var Rre=Lre(Ml());function Lre(e){return e&&e.__esModule?e:{default:e}}function Fre(e){return new Ty(e)}var Ty=class{constructor(t){this.type="lazy",this.__isYupSchema__=!0,this._resolve=(s,p={})=>{let c=this.builder(s,p);if(!(0,Rre.default)(c))throw new TypeError("lazy() functions must return a valid schema");return c.resolve(p)},this.builder=t}resolve(t){return this._resolve(t.value,t)}cast(t,s){return this._resolve(t,s).cast(t,s)}validate(t,s,p){return this._resolve(t,s).validate(t,s,p)}validateSync(t,s){return this._resolve(t,s).validateSync(t,s)}validateAt(t,s,p){return this._resolve(s,p).validateAt(t,s,p)}validateSyncAt(t,s,p){return this._resolve(s,p).validateSyncAt(t,s,p)}describe(){return null}isValid(t,s){return this._resolve(t,s).isValid(t,s)}isValidSync(t,s){return this._resolve(t,s).isValidSync(t,s)}},jre=Ty;Up.default=jre});var $A=le(Sy=>{"use strict";Object.defineProperty(Sy,"__esModule",{value:!0});Sy.default=Ure;var Mre=Bre(Jn());function Bre(e){return e&&e.__esModule?e:{default:e}}function Ure(e){Object.keys(e).forEach(t=>{Object.keys(e[t]).forEach(s=>{Mre.default[t][s]=e[t][s]})})}});var JA=le(Rr=>{"use strict";Object.defineProperty(Rr,"__esModule",{value:!0});Rr.addMethod=Kre;Object.defineProperty(Rr,"MixedSchema",{enumerable:!0,get:function(){return GA.default}});Object.defineProperty(Rr,"mixed",{enumerable:!0,get:function(){return GA.create}});Object.defineProperty(Rr,"BooleanSchema",{enumerable:!0,get:function(){return wy.default}});Object.defineProperty(Rr,"bool",{enumerable:!0,get:function(){return wy.create}});Object.defineProperty(Rr,"boolean",{enumerable:!0,get:function(){return wy.create}});Object.defineProperty(Rr,"StringSchema",{enumerable:!0,get:function(){return qA.default}});Object.defineProperty(Rr,"string",{enumerable:!0,get:function(){return qA.create}});Object.defineProperty(Rr,"NumberSchema",{enumerable:!0,get:function(){return HA.default}});Object.defineProperty(Rr,"number",{enumerable:!0,get:function(){return HA.create}});Object.defineProperty(Rr,"DateSchema",{enumerable:!0,get:function(){return WA.default}});Object.defineProperty(Rr,"date",{enumerable:!0,get:function(){return WA.create}});Object.defineProperty(Rr,"ObjectSchema",{enumerable:!0,get:function(){return KA.default}});Object.defineProperty(Rr,"object",{enumerable:!0,get:function(){return KA.create}});Object.defineProperty(Rr,"ArraySchema",{enumerable:!0,get:function(){return zA.default}});Object.defineProperty(Rr,"array",{enumerable:!0,get:function(){return zA.create}});Object.defineProperty(Rr,"ref",{enumerable:!0,get:function(){return Vre.create}});Object.defineProperty(Rr,"lazy",{enumerable:!0,get:function(){return $re.create}});Object.defineProperty(Rr,"ValidationError",{enumerable:!0,get:function(){return Gre.default}});Object.defineProperty(Rr,"reach",{enumerable:!0,get:function(){return qre.default}});Object.defineProperty(Rr,"isSchema",{enumerable:!0,get:function(){return XA.default}});Object.defineProperty(Rr,"setLocale",{enumerable:!0,get:function(){return Hre.default}});Object.defineProperty(Rr,"BaseSchema",{enumerable:!0,get:function(){return Wre.default}});var GA=Ao(rx()),wy=Ao(ox()),qA=Ao(px()),HA=Ao(hx()),WA=Ao(gx()),KA=Ao(MA()),zA=Ao(UA()),Vre=_o(),$re=VA(),Gre=Vp(To()),qre=Vp(ay()),XA=Vp(Ml()),Hre=Vp($A()),Wre=Vp(Zn());function Vp(e){return e&&e.__esModule?e:{default:e}}function YA(){if(typeof WeakMap!="function")return null;var e=new WeakMap;return YA=function(){return e},e}function Ao(e){if(e&&e.__esModule)return e;if(e===null||typeof e!="object"&&typeof e!="function")return{default:e};var t=YA();if(t&&t.has(e))return t.get(e);var s={},p=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var c in e)if(Object.prototype.hasOwnProperty.call(e,c)){var i=p?Object.getOwnPropertyDescriptor(e,c):null;i&&(i.get||i.set)?Object.defineProperty(s,c,i):s[c]=e[c]}return s.default=e,t&&t.set(e,s),s}function Kre(e,t,s){if(!e||!(0,XA.default)(e.prototype))throw new TypeError("You must provide a yup schema constructor function");if(typeof t!="string")throw new TypeError("A Method name must be provided");if(typeof s!="function")throw new TypeError("Method function must be provided");e.prototype[t]=s}});var aC=le((J1e,iie)=>{iie.exports={name:"dotenv",version:"16.0.3",description:"Loads environment variables from .env file",main:"lib/main.js",types:"lib/main.d.ts",exports:{".":{require:"./lib/main.js",types:"./lib/main.d.ts",default:"./lib/main.js"},"./config":"./config.js","./config.js":"./config.js","./lib/env-options":"./lib/env-options.js","./lib/env-options.js":"./lib/env-options.js","./lib/cli-options":"./lib/cli-options.js","./lib/cli-options.js":"./lib/cli-options.js","./package.json":"./package.json"},scripts:{"dts-check":"tsc --project tests/types/tsconfig.json",lint:"standard","lint-readme":"standard-markdown",pretest:"npm run lint && npm run dts-check",test:"tap tests/*.js --100 -Rspec",prerelease:"npm test",release:"standard-version"},repository:{type:"git",url:"git://github.com/motdotla/dotenv.git"},keywords:["dotenv","env",".env","environment","variables","config","settings"],readmeFilename:"README.md",license:"BSD-2-Clause",devDependencies:{"@types/node":"^17.0.9",decache:"^4.6.1",dtslint:"^3.7.0",sinon:"^12.0.1",standard:"^16.0.4","standard-markdown":"^7.1.0","standard-version":"^9.3.2",tap:"^15.1.6",tar:"^6.1.11",typescript:"^4.5.4"},engines:{node:">=12"}}});var lC=le((Q1e,zh)=>{var sie=require("fs"),oC=require("path"),nie=require("os"),aie=aC(),oie=aie.version,lie=/(?:^|^)\s*(?:export\s+)?([\w.-]+)(?:\s*=\s*?|:\s+?)(\s*'(?:\\'|[^'])*'|\s*"(?:\\"|[^"])*"|\s*`(?:\\`|[^`])*`|[^#\r\n]+)?\s*(?:#.*)?(?:$|$)/mg;function uie(e){let t={},s=e.toString();s=s.replace(/\r\n?/mg,` +`+(d!==i?`result of cast: ${d}`:""))}return c}_cast(t,s){let p=t===void 0?t:this.transforms.reduce((c,i)=>i.call(this,c,t,this),t);return p===void 0&&(p=this.getDefault()),p}_validate(t,s={},p){let{sync:c,path:i,from:d=[],originalValue:a=t,strict:o=this.spec.strict,abortEarly:n=this.spec.abortEarly}=s,l=t;o||(l=this._cast(l,xs({assert:!1},s)));let g={value:l,path:i,options:s,originalValue:a,schema:this,label:this.spec.label,sync:c,from:d},h=[];this._typeError&&h.push(this._typeError),this._whitelistError&&h.push(this._whitelistError),this._blacklistError&&h.push(this._blacklistError),(0,JP.default)({args:g,value:l,path:i,sync:c,tests:h,endEarly:n},m=>{if(m)return void p(m,l);(0,JP.default)({tests:this.tests,args:g,path:i,sync:c,value:l,endEarly:n},p)})}validate(t,s,p){let c=this.resolve(xs({},s,{value:t}));return typeof p=="function"?c._validate(t,s,p):new Promise((i,d)=>c._validate(t,s,(a,o)=>{a?d(a):i(o)}))}validateSync(t,s){let p=this.resolve(xs({},s,{value:t})),c;return p._validate(t,xs({},s,{sync:!0}),(i,d)=>{if(i)throw i;c=d}),c}isValid(t,s){return this.validate(t,s).then(()=>!0,p=>{if(ZP.default.isError(p))return!1;throw p})}isValidSync(t,s){try{return this.validateSync(t,s),!0}catch(p){if(ZP.default.isError(p))return!1;throw p}}_getDefault(){let t=this.spec.default;return t==null?t:typeof t=="function"?t.call(this):(0,YP.default)(t)}getDefault(t){return this.resolve(t||{})._getDefault()}default(t){return arguments.length===0?this._getDefault():this.clone({default:t})}strict(t=!0){var s=this.clone();return s.spec.strict=t,s}_isPresent(t){return t!=null}defined(t=Gl.mixed.defined){return this.test({message:t,name:"defined",exclusive:!0,test(s){return s!==void 0}})}required(t=Gl.mixed.required){return this.clone({presence:"required"}).withMutation(s=>s.test({message:t,name:"required",exclusive:!0,test(p){return this.schema._isPresent(p)}}))}notRequired(){var t=this.clone({presence:"optional"});return t.tests=t.tests.filter(s=>s.OPTIONS.name!=="required"),t}nullable(t=!0){var s=this.clone({nullable:t!==!1});return s}transform(t){var s=this.clone();return s.transforms.push(t),s}test(...t){let s;if(t.length===1?typeof t[0]=="function"?s={test:t[0]}:s=t[0]:t.length===2?s={name:t[0],test:t[1]}:s={name:t[0],message:t[1],test:t[2]},s.message===void 0&&(s.message=Gl.mixed.default),typeof s.test!="function")throw new TypeError("`test` is a required parameters");let p=this.clone(),c=(0,Oh.default)(s),i=s.exclusive||s.name&&p.exclusiveTests[s.name]===!0;if(s.exclusive&&!s.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return s.name&&(p.exclusiveTests[s.name]=!!s.exclusive),p.tests=p.tests.filter(d=>!(d.OPTIONS.name===s.name&&(i||d.OPTIONS.test===c.OPTIONS.test))),p.tests.push(c),p}when(t,s){!Array.isArray(t)&&typeof t!="string"&&(s=t,t=".");let p=this.clone(),c=(0,YZ.default)(t).map(i=>new zZ.default(i));return c.forEach(i=>{i.isSibling&&p.deps.push(i.key)}),p.conditions.push(new KZ.default(c,s)),p}typeError(t){var s=this.clone();return s._typeError=(0,Oh.default)({message:t,name:"typeError",test(p){return p!==void 0&&!this.schema.isType(p)?this.createError({params:{type:this.schema._type}}):!0}}),s}oneOf(t,s=Gl.mixed.oneOf){var p=this.clone();return t.forEach(c=>{p._whitelist.add(c),p._blacklist.delete(c)}),p._whitelistError=(0,Oh.default)({message:s,name:"oneOf",test(c){if(c===void 0)return!0;let i=this.schema._whitelist;return i.has(c,this.resolve)?!0:this.createError({params:{values:i.toArray().join(", ")}})}}),p}notOneOf(t,s=Gl.mixed.notOneOf){var p=this.clone();return t.forEach(c=>{p._blacklist.add(c),p._whitelist.delete(c)}),p._blacklistError=(0,Oh.default)({message:s,name:"notOneOf",test(c){let i=this.schema._blacklist;return i.has(c,this.resolve)?this.createError({params:{values:i.toArray().join(", ")}}):!0}}),p}strip(t=!0){let s=this.clone();return s.spec.strip=t,s}describe(){let t=this.clone(),{label:s,meta:p}=t.spec;return{meta:p,label:s,type:t.type,oneOf:t._whitelist.describe(),notOneOf:t._blacklist.describe(),tests:t.tests.map(i=>({name:i.OPTIONS.name,params:i.OPTIONS.params})).filter((i,d,a)=>a.findIndex(o=>o.name===i.name)===d)}}};Dh.default=En;En.prototype.__isYupSchema__=!0;for(let e of["validate","validateSync"])En.prototype[`${e}At`]=function(t,s,p={}){let{parent:c,parentPath:i,schema:d}=(0,XZ.getIn)(this,t,s,p.context);return d[e](c&&c[i],xs({},p,{parent:c,path:t}))};for(let e of["equals","is"])En.prototype[e]=En.prototype.oneOf;for(let e of["not","nope"])En.prototype[e]=En.prototype.notOneOf;En.prototype.optional=En.prototype.notRequired});var rx=le(Dp=>{"use strict";Object.defineProperty(Dp,"__esModule",{value:!0});Dp.create=tx;Dp.default=void 0;var JZ=QZ(Zn());function QZ(e){return e&&e.__esModule?e:{default:e}}var oy=JZ.default,ZZ=oy;Dp.default=ZZ;function tx(){return new oy}tx.prototype=oy.prototype});var ql=le(kh=>{"use strict";Object.defineProperty(kh,"__esModule",{value:!0});kh.default=void 0;var eee=e=>e==null;kh.default=eee});var ox=le(kp=>{"use strict";Object.defineProperty(kp,"__esModule",{value:!0});kp.create=ax;kp.default=void 0;var tee=nx(Zn()),ix=Jn(),sx=nx(ql());function nx(e){return e&&e.__esModule?e:{default:e}}function ax(){return new Rh}var Rh=class extends tee.default{constructor(){super({type:"boolean"});this.withMutation(()=>{this.transform(function(t){if(!this.isType(t)){if(/^(true|1)$/i.test(String(t)))return!0;if(/^(false|0)$/i.test(String(t)))return!1}return t})})}_typeCheck(t){return t instanceof Boolean&&(t=t.valueOf()),typeof t=="boolean"}isTrue(t=ix.boolean.isValue){return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"true"},test(s){return(0,sx.default)(s)||s===!0}})}isFalse(t=ix.boolean.isValue){return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"false"},test(s){return(0,sx.default)(s)||s===!1}})}};kp.default=Rh;ax.prototype=Rh.prototype});var px=le(Rp=>{"use strict";Object.defineProperty(Rp,"__esModule",{value:!0});Rp.create=ux;Rp.default=void 0;var Tn=Jn(),ea=lx(ql()),ree=lx(Zn());function lx(e){return e&&e.__esModule?e:{default:e}}var iee=/^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))$/i,see=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,nee=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,aee=e=>(0,ea.default)(e)||e===e.trim(),oee={}.toString();function ux(){return new Lh}var Lh=class extends ree.default{constructor(){super({type:"string"});this.withMutation(()=>{this.transform(function(t){if(this.isType(t)||Array.isArray(t))return t;let s=t!=null&&t.toString?t.toString():t;return s===oee?t:s})})}_typeCheck(t){return t instanceof String&&(t=t.valueOf()),typeof t=="string"}_isPresent(t){return super._isPresent(t)&&!!t.length}length(t,s=Tn.string.length){return this.test({message:s,name:"length",exclusive:!0,params:{length:t},test(p){return(0,ea.default)(p)||p.length===this.resolve(t)}})}min(t,s=Tn.string.min){return this.test({message:s,name:"min",exclusive:!0,params:{min:t},test(p){return(0,ea.default)(p)||p.length>=this.resolve(t)}})}max(t,s=Tn.string.max){return this.test({name:"max",exclusive:!0,message:s,params:{max:t},test(p){return(0,ea.default)(p)||p.length<=this.resolve(t)}})}matches(t,s){let p=!1,c,i;return s&&(typeof s=="object"?{excludeEmptyString:p=!1,message:c,name:i}=s:c=s),this.test({name:i||"matches",message:c||Tn.string.matches,params:{regex:t},test:d=>(0,ea.default)(d)||d===""&&p||d.search(t)!==-1})}email(t=Tn.string.email){return this.matches(iee,{name:"email",message:t,excludeEmptyString:!0})}url(t=Tn.string.url){return this.matches(see,{name:"url",message:t,excludeEmptyString:!0})}uuid(t=Tn.string.uuid){return this.matches(nee,{name:"uuid",message:t,excludeEmptyString:!1})}ensure(){return this.default("").transform(t=>t===null?"":t)}trim(t=Tn.string.trim){return this.transform(s=>s!=null?s.trim():s).test({message:t,name:"trim",test:aee})}lowercase(t=Tn.string.lowercase){return this.transform(s=>(0,ea.default)(s)?s:s.toLowerCase()).test({message:t,name:"string_case",exclusive:!0,test:s=>(0,ea.default)(s)||s===s.toLowerCase()})}uppercase(t=Tn.string.uppercase){return this.transform(s=>(0,ea.default)(s)?s:s.toUpperCase()).test({message:t,name:"string_case",exclusive:!0,test:s=>(0,ea.default)(s)||s===s.toUpperCase()})}};Rp.default=Lh;ux.prototype=Lh.prototype});var hx=le(Lp=>{"use strict";Object.defineProperty(Lp,"__esModule",{value:!0});Lp.create=dx;Lp.default=void 0;var Po=Jn(),xo=cx(ql()),lee=cx(Zn());function cx(e){return e&&e.__esModule?e:{default:e}}var uee=e=>e!=+e;function dx(){return new Fh}var Fh=class extends lee.default{constructor(){super({type:"number"});this.withMutation(()=>{this.transform(function(t){let s=t;if(typeof s=="string"){if(s=s.replace(/\s/g,""),s==="")return NaN;s=+s}return this.isType(s)?s:parseFloat(s)})})}_typeCheck(t){return t instanceof Number&&(t=t.valueOf()),typeof t=="number"&&!uee(t)}min(t,s=Po.number.min){return this.test({message:s,name:"min",exclusive:!0,params:{min:t},test(p){return(0,xo.default)(p)||p>=this.resolve(t)}})}max(t,s=Po.number.max){return this.test({message:s,name:"max",exclusive:!0,params:{max:t},test(p){return(0,xo.default)(p)||p<=this.resolve(t)}})}lessThan(t,s=Po.number.lessThan){return this.test({message:s,name:"max",exclusive:!0,params:{less:t},test(p){return(0,xo.default)(p)||pthis.resolve(t)}})}positive(t=Po.number.positive){return this.moreThan(0,t)}negative(t=Po.number.negative){return this.lessThan(0,t)}integer(t=Po.number.integer){return this.test({name:"integer",message:t,test:s=>(0,xo.default)(s)||Number.isInteger(s)})}truncate(){return this.transform(t=>(0,xo.default)(t)?t:t|0)}round(t){var s,p=["ceil","floor","round","trunc"];if(t=((s=t)==null?void 0:s.toLowerCase())||"round",t==="trunc")return this.truncate();if(p.indexOf(t.toLowerCase())===-1)throw new TypeError("Only valid options for round() are: "+p.join(", "));return this.transform(c=>(0,xo.default)(c)?c:Math[t](c))}};Lp.default=Fh;dx.prototype=Fh.prototype});var fx=le(ly=>{"use strict";Object.defineProperty(ly,"__esModule",{value:!0});ly.default=cee;var pee=/^(\d{4}|[+\-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,\.](\d{1,}))?)?(?:(Z)|([+\-])(\d{2})(?::?(\d{2}))?)?)?$/;function cee(e){var t=[1,4,5,6,7,10,11],s=0,p,c;if(c=pee.exec(e)){for(var i=0,d;d=t[i];++i)c[d]=+c[d]||0;c[2]=(+c[2]||1)-1,c[3]=+c[3]||1,c[7]=c[7]?String(c[7]).substr(0,3):0,(c[8]===void 0||c[8]==="")&&(c[9]===void 0||c[9]==="")?p=+new Date(c[1],c[2],c[3],c[4],c[5],c[6],c[7]):(c[8]!=="Z"&&c[9]!==void 0&&(s=c[10]*60+c[11],c[9]==="+"&&(s=0-s)),p=Date.UTC(c[1],c[2],c[3],c[4],c[5]+s,c[6],c[7]))}else p=Date.parse?Date.parse(e):NaN;return p}});var gx=le(jp=>{"use strict";Object.defineProperty(jp,"__esModule",{value:!0});jp.create=py;jp.default=void 0;var dee=jh(fx()),mx=Jn(),yx=jh(ql()),hee=jh(_o()),fee=jh(Zn());function jh(e){return e&&e.__esModule?e:{default:e}}var uy=new Date(""),mee=e=>Object.prototype.toString.call(e)==="[object Date]";function py(){return new Fp}var Fp=class extends fee.default{constructor(){super({type:"date"});this.withMutation(()=>{this.transform(function(t){return this.isType(t)?t:(t=(0,dee.default)(t),isNaN(t)?uy:new Date(t))})})}_typeCheck(t){return mee(t)&&!isNaN(t.getTime())}prepareParam(t,s){let p;if(hee.default.isRef(t))p=t;else{let c=this.cast(t);if(!this._typeCheck(c))throw new TypeError(`\`${s}\` must be a Date or a value that can be \`cast()\` to a Date`);p=c}return p}min(t,s=mx.date.min){let p=this.prepareParam(t,"min");return this.test({message:s,name:"min",exclusive:!0,params:{min:t},test(c){return(0,yx.default)(c)||c>=this.resolve(p)}})}max(t,s=mx.date.max){var p=this.prepareParam(t,"max");return this.test({message:s,name:"max",exclusive:!0,params:{max:t},test(c){return(0,yx.default)(c)||c<=this.resolve(p)}})}};jp.default=Fp;Fp.INVALID_DATE=uy;py.prototype=Fp.prototype;py.INVALID_DATE=uy});var vx=le((Yme,bx)=>{function yee(e,t,s,p){var c=-1,i=e==null?0:e.length;for(p&&i&&(s=e[++c]);++c{function gee(e){return function(t){return e==null?void 0:e[t]}}Ex.exports=gee});var wx=le((Qme,Sx)=>{var bee=Tx(),vee={\u00C0:"A",\u00C1:"A",\u00C2:"A",\u00C3:"A",\u00C4:"A",\u00C5:"A",\u00E0:"a",\u00E1:"a",\u00E2:"a",\u00E3:"a",\u00E4:"a",\u00E5:"a",\u00C7:"C",\u00E7:"c",\u00D0:"D",\u00F0:"d",\u00C8:"E",\u00C9:"E",\u00CA:"E",\u00CB:"E",\u00E8:"e",\u00E9:"e",\u00EA:"e",\u00EB:"e",\u00CC:"I",\u00CD:"I",\u00CE:"I",\u00CF:"I",\u00EC:"i",\u00ED:"i",\u00EE:"i",\u00EF:"i",\u00D1:"N",\u00F1:"n",\u00D2:"O",\u00D3:"O",\u00D4:"O",\u00D5:"O",\u00D6:"O",\u00D8:"O",\u00F2:"o",\u00F3:"o",\u00F4:"o",\u00F5:"o",\u00F6:"o",\u00F8:"o",\u00D9:"U",\u00DA:"U",\u00DB:"U",\u00DC:"U",\u00F9:"u",\u00FA:"u",\u00FB:"u",\u00FC:"u",\u00DD:"Y",\u00FD:"y",\u00FF:"y",\u00C6:"Ae",\u00E6:"ae",\u00DE:"Th",\u00FE:"th",\u00DF:"ss",\u0100:"A",\u0102:"A",\u0104:"A",\u0101:"a",\u0103:"a",\u0105:"a",\u0106:"C",\u0108:"C",\u010A:"C",\u010C:"C",\u0107:"c",\u0109:"c",\u010B:"c",\u010D:"c",\u010E:"D",\u0110:"D",\u010F:"d",\u0111:"d",\u0112:"E",\u0114:"E",\u0116:"E",\u0118:"E",\u011A:"E",\u0113:"e",\u0115:"e",\u0117:"e",\u0119:"e",\u011B:"e",\u011C:"G",\u011E:"G",\u0120:"G",\u0122:"G",\u011D:"g",\u011F:"g",\u0121:"g",\u0123:"g",\u0124:"H",\u0126:"H",\u0125:"h",\u0127:"h",\u0128:"I",\u012A:"I",\u012C:"I",\u012E:"I",\u0130:"I",\u0129:"i",\u012B:"i",\u012D:"i",\u012F:"i",\u0131:"i",\u0134:"J",\u0135:"j",\u0136:"K",\u0137:"k",\u0138:"k",\u0139:"L",\u013B:"L",\u013D:"L",\u013F:"L",\u0141:"L",\u013A:"l",\u013C:"l",\u013E:"l",\u0140:"l",\u0142:"l",\u0143:"N",\u0145:"N",\u0147:"N",\u014A:"N",\u0144:"n",\u0146:"n",\u0148:"n",\u014B:"n",\u014C:"O",\u014E:"O",\u0150:"O",\u014D:"o",\u014F:"o",\u0151:"o",\u0154:"R",\u0156:"R",\u0158:"R",\u0155:"r",\u0157:"r",\u0159:"r",\u015A:"S",\u015C:"S",\u015E:"S",\u0160:"S",\u015B:"s",\u015D:"s",\u015F:"s",\u0161:"s",\u0162:"T",\u0164:"T",\u0166:"T",\u0163:"t",\u0165:"t",\u0167:"t",\u0168:"U",\u016A:"U",\u016C:"U",\u016E:"U",\u0170:"U",\u0172:"U",\u0169:"u",\u016B:"u",\u016D:"u",\u016F:"u",\u0171:"u",\u0173:"u",\u0174:"W",\u0175:"w",\u0176:"Y",\u0177:"y",\u0178:"Y",\u0179:"Z",\u017B:"Z",\u017D:"Z",\u017A:"z",\u017C:"z",\u017E:"z",\u0132:"IJ",\u0133:"ij",\u0152:"Oe",\u0153:"oe",\u0149:"'n",\u017F:"s"},Eee=bee(vee);Sx.exports=Eee});var Px=le((Zme,_x)=>{var Tee=wx(),See=Tl(),wee=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,_ee="\\u0300-\\u036f",Pee="\\ufe20-\\ufe2f",xee="\\u20d0-\\u20ff",Aee=_ee+Pee+xee,Cee="["+Aee+"]",Iee=RegExp(Cee,"g");function Nee(e){return e=See(e),e&&e.replace(wee,Tee).replace(Iee,"")}_x.exports=Nee});var Ax=le((e1e,xx)=>{var Oee=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function Dee(e){return e.match(Oee)||[]}xx.exports=Dee});var Ix=le((t1e,Cx)=>{var kee=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function Ree(e){return kee.test(e)}Cx.exports=Ree});var zx=le((r1e,Kx)=>{var Nx="\\ud800-\\udfff",Lee="\\u0300-\\u036f",Fee="\\ufe20-\\ufe2f",jee="\\u20d0-\\u20ff",Mee=Lee+Fee+jee,Ox="\\u2700-\\u27bf",Dx="a-z\\xdf-\\xf6\\xf8-\\xff",Bee="\\xac\\xb1\\xd7\\xf7",Uee="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",Vee="\\u2000-\\u206f",$ee=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",kx="A-Z\\xc0-\\xd6\\xd8-\\xde",Gee="\\ufe0e\\ufe0f",Rx=Bee+Uee+Vee+$ee,Lx="['\u2019]",Fx="["+Rx+"]",qee="["+Mee+"]",jx="\\d+",Hee="["+Ox+"]",Mx="["+Dx+"]",Bx="[^"+Nx+Rx+jx+Ox+Dx+kx+"]",Wee="\\ud83c[\\udffb-\\udfff]",Kee="(?:"+qee+"|"+Wee+")",zee="[^"+Nx+"]",Ux="(?:\\ud83c[\\udde6-\\uddff]){2}",Vx="[\\ud800-\\udbff][\\udc00-\\udfff]",Hl="["+kx+"]",Xee="\\u200d",$x="(?:"+Mx+"|"+Bx+")",Yee="(?:"+Hl+"|"+Bx+")",Gx="(?:"+Lx+"(?:d|ll|m|re|s|t|ve))?",qx="(?:"+Lx+"(?:D|LL|M|RE|S|T|VE))?",Hx=Kee+"?",Wx="["+Gee+"]?",Jee="(?:"+Xee+"(?:"+[zee,Ux,Vx].join("|")+")"+Wx+Hx+")*",Qee="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Zee="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",ete=Wx+Hx+Jee,tte="(?:"+[Hee,Ux,Vx].join("|")+")"+ete,rte=RegExp([Hl+"?"+Mx+"+"+Gx+"(?="+[Fx,Hl,"$"].join("|")+")",Yee+"+"+qx+"(?="+[Fx,Hl+$x,"$"].join("|")+")",Hl+"?"+$x+"+"+Gx,Hl+"+"+qx,Zee,Qee,jx,tte].join("|"),"g");function ite(e){return e.match(rte)||[]}Kx.exports=ite});var Yx=le((i1e,Xx)=>{var ste=Ax(),nte=Ix(),ate=Tl(),ote=zx();function lte(e,t,s){return e=ate(e),t=s?void 0:t,t===void 0?nte(e)?ote(e):ste(e):e.match(t)||[]}Xx.exports=lte});var cy=le((s1e,Jx)=>{var ute=vx(),pte=Px(),cte=Yx(),dte="['\u2019]",hte=RegExp(dte,"g");function fte(e){return function(t){return ute(cte(pte(t).replace(hte,"")),e,"")}}Jx.exports=fte});var Zx=le((n1e,Qx)=>{var mte=cy(),yte=mte(function(e,t,s){return e+(s?"_":"")+t.toLowerCase()});Qx.exports=yte});var tA=le((a1e,eA)=>{function gte(e,t,s){var p=-1,c=e.length;t<0&&(t=-t>c?0:c+t),s=s>c?c:s,s<0&&(s+=c),c=t>s?0:s-t>>>0,t>>>=0;for(var i=Array(c);++p{var bte=tA();function vte(e,t,s){var p=e.length;return s=s===void 0?p:s,!t&&s>=p?e:bte(e,t,s)}rA.exports=vte});var dy=le((l1e,sA)=>{var Ete="\\ud800-\\udfff",Tte="\\u0300-\\u036f",Ste="\\ufe20-\\ufe2f",wte="\\u20d0-\\u20ff",_te=Tte+Ste+wte,Pte="\\ufe0e\\ufe0f",xte="\\u200d",Ate=RegExp("["+xte+Ete+_te+Pte+"]");function Cte(e){return Ate.test(e)}sA.exports=Cte});var aA=le((u1e,nA)=>{function Ite(e){return e.split("")}nA.exports=Ite});var fA=le((p1e,hA)=>{var oA="\\ud800-\\udfff",Nte="\\u0300-\\u036f",Ote="\\ufe20-\\ufe2f",Dte="\\u20d0-\\u20ff",kte=Nte+Ote+Dte,Rte="\\ufe0e\\ufe0f",Lte="["+oA+"]",hy="["+kte+"]",fy="\\ud83c[\\udffb-\\udfff]",Fte="(?:"+hy+"|"+fy+")",lA="[^"+oA+"]",uA="(?:\\ud83c[\\udde6-\\uddff]){2}",pA="[\\ud800-\\udbff][\\udc00-\\udfff]",jte="\\u200d",cA=Fte+"?",dA="["+Rte+"]?",Mte="(?:"+jte+"(?:"+[lA,uA,pA].join("|")+")"+dA+cA+")*",Bte=dA+cA+Mte,Ute="(?:"+[lA+hy+"?",hy,uA,pA,Lte].join("|")+")",Vte=RegExp(fy+"(?="+fy+")|"+Ute+Bte,"g");function $te(e){return e.match(Vte)||[]}hA.exports=$te});var yA=le((c1e,mA)=>{var Gte=aA(),qte=dy(),Hte=fA();function Wte(e){return qte(e)?Hte(e):Gte(e)}mA.exports=Wte});var bA=le((d1e,gA)=>{var Kte=iA(),zte=dy(),Xte=yA(),Yte=Tl();function Jte(e){return function(t){t=Yte(t);var s=zte(t)?Xte(t):void 0,p=s?s[0]:t.charAt(0),c=s?Kte(s,1).join(""):t.slice(1);return p[e]()+c}}gA.exports=Jte});var EA=le((h1e,vA)=>{var Qte=bA(),Zte=Qte("toUpperCase");vA.exports=Zte});var SA=le((f1e,TA)=>{var ere=Tl(),tre=EA();function rre(e){return tre(ere(e).toLowerCase())}TA.exports=rre});var _A=le((m1e,wA)=>{var ire=SA(),sre=cy(),nre=sre(function(e,t,s){return t=t.toLowerCase(),e+(s?ire(t):t)});wA.exports=nre});var xA=le((y1e,PA)=>{var are=pd(),ore=B0(),lre=Q0();function ure(e,t){var s={};return t=lre(t,3),ore(e,function(p,c,i){are(s,t(p,c,i),p)}),s}PA.exports=ure});var CA=le((g1e,my)=>{my.exports=function(e){return AA(pre(e),e)};my.exports.array=AA;function AA(e,t){var s=e.length,p=new Array(s),c={},i=s,d=cre(t),a=dre(e);for(t.forEach(function(n){if(!a.has(n[0])||!a.has(n[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});i--;)c[i]||o(e[i],i,new Set);return p;function o(n,l,g){if(g.has(n)){var h;try{h=", node was:"+JSON.stringify(n)}catch(E){h=""}throw new Error("Cyclic dependency"+h)}if(!a.has(n))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(n));if(!c[l]){c[l]=!0;var m=d.get(n)||new Set;if(m=Array.from(m),l=m.length){g.add(n);do{var b=m[--l];o(b,a.get(b),g)}while(l);g.delete(n)}p[--s]=n}}}function pre(e){for(var t=new Set,s=0,p=e.length;s{"use strict";Object.defineProperty(yy,"__esModule",{value:!0});yy.default=bre;var hre=Mh(gh()),fre=Mh(CA()),mre=Ip(),yre=Mh(_o()),gre=Mh(Ml());function Mh(e){return e&&e.__esModule?e:{default:e}}function bre(e,t=[]){let s=[],p=[];function c(i,d){var a=(0,mre.split)(i)[0];~p.indexOf(a)||p.push(a),~t.indexOf(`${d}-${a}`)||s.push([d,a])}for(let i in e)if((0,hre.default)(e,i)){let d=e[i];~p.indexOf(i)||p.push(i),yre.default.isRef(d)&&d.isSibling?c(d.path,i):(0,gre.default)(d)&&"deps"in d&&d.deps.forEach(a=>c(a,i))}return fre.default.array(p,s).reverse()}});var OA=le(gy=>{"use strict";Object.defineProperty(gy,"__esModule",{value:!0});gy.default=vre;function NA(e,t){let s=1/0;return e.some((p,c)=>{var i;if(((i=t.path)==null?void 0:i.indexOf(p))!==-1)return s=c,!0}),s}function vre(e){return(t,s)=>NA(e,t)-NA(e,s)}});var MA=le(Mp=>{"use strict";Object.defineProperty(Mp,"__esModule",{value:!0});Mp.create=jA;Mp.default=void 0;var DA=Sn(gh()),kA=Sn(Zx()),Ere=Sn(_A()),Tre=Sn(xA()),Sre=Sn(Z0()),wre=Ip(),RA=Jn(),_re=Sn(IA()),LA=Sn(OA()),Pre=Sn(Th()),xre=Sn(To()),by=Sn(Zn());function Sn(e){return e&&e.__esModule?e:{default:e}}function Wl(){return Wl=Object.assign||function(e){for(var t=1;tObject.prototype.toString.call(e)==="[object Object]";function Are(e,t){let s=Object.keys(e.fields);return Object.keys(t).filter(p=>s.indexOf(p)===-1)}var Cre=(0,LA.default)([]),Bh=class extends by.default{constructor(t){super({type:"object"});this.fields=Object.create(null),this._sortErrors=Cre,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{this.transform(function(p){if(typeof p=="string")try{p=JSON.parse(p)}catch(c){p=null}return this.isType(p)?p:null}),t&&this.shape(t)})}_typeCheck(t){return FA(t)||typeof t=="function"}_cast(t,s={}){var p;let c=super._cast(t,s);if(c===void 0)return this.getDefault();if(!this._typeCheck(c))return c;let i=this.fields,d=(p=s.stripUnknown)!=null?p:this.spec.noUnknown,a=this._nodes.concat(Object.keys(c).filter(g=>this._nodes.indexOf(g)===-1)),o={},n=Wl({},s,{parent:o,__validating:s.__validating||!1}),l=!1;for(let g of a){let h=i[g],m=(0,DA.default)(c,g);if(h){let b,E=c[g];n.path=(s.path?`${s.path}.`:"")+g,h=h.resolve({value:E,context:s.context,parent:o});let _="spec"in h?h.spec:void 0,C=_==null?void 0:_.strict;if(_==null?void 0:_.strip){l=l||g in c;continue}b=!s.__validating||!C?h.cast(c[g],n):c[g],b!==void 0&&(o[g]=b)}else m&&!d&&(o[g]=c[g]);o[g]!==c[g]&&(l=!0)}return l?o:c}_validate(t,s={},p){let c=[],{sync:i,from:d=[],originalValue:a=t,abortEarly:o=this.spec.abortEarly,recursive:n=this.spec.recursive}=s;d=[{schema:this,value:a},...d],s.__validating=!0,s.originalValue=a,s.from=d,super._validate(t,s,(l,g)=>{if(l){if(!xre.default.isError(l)||o)return void p(l,g);c.push(l)}if(!n||!FA(g)){p(c[0]||null,g);return}a=a||g;let h=this._nodes.map(m=>(b,E)=>{let _=m.indexOf(".")===-1?(s.path?`${s.path}.`:"")+m:`${s.path||""}["${m}"]`,C=this.fields[m];if(C&&"validate"in C){C.validate(g[m],Wl({},s,{path:_,from:d,strict:!0,parent:g,originalValue:a[m]}),E);return}E(null)});(0,Pre.default)({sync:i,tests:h,value:g,errors:c,endEarly:o,sort:this._sortErrors,path:s.path},p)})}clone(t){let s=super.clone(t);return s.fields=Wl({},this.fields),s._nodes=this._nodes,s._excludedEdges=this._excludedEdges,s._sortErrors=this._sortErrors,s}concat(t){let s=super.concat(t),p=s.fields;for(let[c,i]of Object.entries(this.fields)){let d=p[c];d===void 0?p[c]=i:d instanceof by.default&&i instanceof by.default&&(p[c]=i.concat(d))}return s.withMutation(()=>s.shape(p))}getDefaultFromShape(){let t={};return this._nodes.forEach(s=>{let p=this.fields[s];t[s]="default"in p?p.getDefault():void 0}),t}_getDefault(){if("default"in this.spec)return super._getDefault();if(!!this._nodes.length)return this.getDefaultFromShape()}shape(t,s=[]){let p=this.clone(),c=Object.assign(p.fields,t);if(p.fields=c,p._sortErrors=(0,LA.default)(Object.keys(c)),s.length){Array.isArray(s[0])||(s=[s]);let i=s.map(([d,a])=>`${d}-${a}`);p._excludedEdges=p._excludedEdges.concat(i)}return p._nodes=(0,_re.default)(c,p._excludedEdges),p}pick(t){let s={};for(let p of t)this.fields[p]&&(s[p]=this.fields[p]);return this.clone().withMutation(p=>(p.fields={},p.shape(s)))}omit(t){let s=this.clone(),p=s.fields;s.fields={};for(let c of t)delete p[c];return s.withMutation(()=>s.shape(p))}from(t,s,p){let c=(0,wre.getter)(t,!0);return this.transform(i=>{if(i==null)return i;let d=i;return(0,DA.default)(i,t)&&(d=Wl({},i),p||delete d[t],d[s]=c(i)),d})}noUnknown(t=!0,s=RA.object.noUnknown){typeof t=="string"&&(s=t,t=!0);let p=this.test({name:"noUnknown",exclusive:!0,message:s,test(c){if(c==null)return!0;let i=Are(this.schema,c);return!t||i.length===0||this.createError({params:{unknown:i.join(", ")}})}});return p.spec.noUnknown=t,p}unknown(t=!0,s=RA.object.noUnknown){return this.noUnknown(!t,s)}transformKeys(t){return this.transform(s=>s&&(0,Tre.default)(s,(p,c)=>t(c)))}camelCase(){return this.transformKeys(Ere.default)}snakeCase(){return this.transformKeys(kA.default)}constantCase(){return this.transformKeys(t=>(0,kA.default)(t).toUpperCase())}describe(){let t=super.describe();return t.fields=(0,Sre.default)(this.fields,s=>s.describe()),t}};Mp.default=Bh;function jA(e){return new Bh(e)}jA.prototype=Bh.prototype});var UA=le(Bp=>{"use strict";Object.defineProperty(Bp,"__esModule",{value:!0});Bp.create=BA;Bp.default=void 0;var vy=Kl(ql()),Ire=Kl(Ml()),Nre=Kl(_p()),Ey=Jn(),Ore=Kl(Th()),Dre=Kl(To()),kre=Kl(Zn());function Kl(e){return e&&e.__esModule?e:{default:e}}function Uh(){return Uh=Object.assign||function(e){for(var t=1;t{this.transform(function(s){if(typeof s=="string")try{s=JSON.parse(s)}catch(p){s=null}return this.isType(s)?s:null})})}_typeCheck(t){return Array.isArray(t)}get _subType(){return this.innerType}_cast(t,s){let p=super._cast(t,s);if(!this._typeCheck(p)||!this.innerType)return p;let c=!1,i=p.map((d,a)=>{let o=this.innerType.cast(d,Uh({},s,{path:`${s.path||""}[${a}]`}));return o!==d&&(c=!0),o});return c?i:p}_validate(t,s={},p){var c,i;let d=[],a=s.sync,o=s.path,n=this.innerType,l=(c=s.abortEarly)!=null?c:this.spec.abortEarly,g=(i=s.recursive)!=null?i:this.spec.recursive,h=s.originalValue!=null?s.originalValue:t;super._validate(t,s,(m,b)=>{if(m){if(!Dre.default.isError(m)||l)return void p(m,b);d.push(m)}if(!g||!n||!this._typeCheck(b)){p(d[0]||null,b);return}h=h||b;let E=new Array(b.length);for(let _=0;_n.validate(C,w,x)}(0,Ore.default)({sync:a,path:o,value:b,errors:d,endEarly:l,tests:E},p)})}clone(t){let s=super.clone(t);return s.innerType=this.innerType,s}concat(t){let s=super.concat(t);return s.innerType=this.innerType,t.innerType&&(s.innerType=s.innerType?s.innerType.concat(t.innerType):t.innerType),s}of(t){let s=this.clone();if(!(0,Ire.default)(t))throw new TypeError("`array.of()` sub-schema must be a valid yup schema not: "+(0,Nre.default)(t));return s.innerType=t,s}length(t,s=Ey.array.length){return this.test({message:s,name:"length",exclusive:!0,params:{length:t},test(p){return(0,vy.default)(p)||p.length===this.resolve(t)}})}min(t,s){return s=s||Ey.array.min,this.test({message:s,name:"min",exclusive:!0,params:{min:t},test(p){return(0,vy.default)(p)||p.length>=this.resolve(t)}})}max(t,s){return s=s||Ey.array.max,this.test({message:s,name:"max",exclusive:!0,params:{max:t},test(p){return(0,vy.default)(p)||p.length<=this.resolve(t)}})}ensure(){return this.default(()=>[]).transform((t,s)=>this._typeCheck(t)?t:s==null?[]:[].concat(s))}compact(t){let s=t?(p,c,i)=>!t(p,c,i):p=>!!p;return this.transform(p=>p!=null?p.filter(s):p)}describe(){let t=super.describe();return this.innerType&&(t.innerType=this.innerType.describe()),t}nullable(t=!0){return super.nullable(t)}defined(){return super.defined()}required(t){return super.required(t)}};Bp.default=Vh;BA.prototype=Vh.prototype});var VA=le(Up=>{"use strict";Object.defineProperty(Up,"__esModule",{value:!0});Up.create=Fre;Up.default=void 0;var Rre=Lre(Ml());function Lre(e){return e&&e.__esModule?e:{default:e}}function Fre(e){return new Ty(e)}var Ty=class{constructor(t){this.type="lazy",this.__isYupSchema__=!0,this._resolve=(s,p={})=>{let c=this.builder(s,p);if(!(0,Rre.default)(c))throw new TypeError("lazy() functions must return a valid schema");return c.resolve(p)},this.builder=t}resolve(t){return this._resolve(t.value,t)}cast(t,s){return this._resolve(t,s).cast(t,s)}validate(t,s,p){return this._resolve(t,s).validate(t,s,p)}validateSync(t,s){return this._resolve(t,s).validateSync(t,s)}validateAt(t,s,p){return this._resolve(s,p).validateAt(t,s,p)}validateSyncAt(t,s,p){return this._resolve(s,p).validateSyncAt(t,s,p)}describe(){return null}isValid(t,s){return this._resolve(t,s).isValid(t,s)}isValidSync(t,s){return this._resolve(t,s).isValidSync(t,s)}},jre=Ty;Up.default=jre});var $A=le(Sy=>{"use strict";Object.defineProperty(Sy,"__esModule",{value:!0});Sy.default=Ure;var Mre=Bre(Jn());function Bre(e){return e&&e.__esModule?e:{default:e}}function Ure(e){Object.keys(e).forEach(t=>{Object.keys(e[t]).forEach(s=>{Mre.default[t][s]=e[t][s]})})}});var JA=le(Rr=>{"use strict";Object.defineProperty(Rr,"__esModule",{value:!0});Rr.addMethod=Kre;Object.defineProperty(Rr,"MixedSchema",{enumerable:!0,get:function(){return GA.default}});Object.defineProperty(Rr,"mixed",{enumerable:!0,get:function(){return GA.create}});Object.defineProperty(Rr,"BooleanSchema",{enumerable:!0,get:function(){return wy.default}});Object.defineProperty(Rr,"bool",{enumerable:!0,get:function(){return wy.create}});Object.defineProperty(Rr,"boolean",{enumerable:!0,get:function(){return wy.create}});Object.defineProperty(Rr,"StringSchema",{enumerable:!0,get:function(){return qA.default}});Object.defineProperty(Rr,"string",{enumerable:!0,get:function(){return qA.create}});Object.defineProperty(Rr,"NumberSchema",{enumerable:!0,get:function(){return HA.default}});Object.defineProperty(Rr,"number",{enumerable:!0,get:function(){return HA.create}});Object.defineProperty(Rr,"DateSchema",{enumerable:!0,get:function(){return WA.default}});Object.defineProperty(Rr,"date",{enumerable:!0,get:function(){return WA.create}});Object.defineProperty(Rr,"ObjectSchema",{enumerable:!0,get:function(){return KA.default}});Object.defineProperty(Rr,"object",{enumerable:!0,get:function(){return KA.create}});Object.defineProperty(Rr,"ArraySchema",{enumerable:!0,get:function(){return zA.default}});Object.defineProperty(Rr,"array",{enumerable:!0,get:function(){return zA.create}});Object.defineProperty(Rr,"ref",{enumerable:!0,get:function(){return Vre.create}});Object.defineProperty(Rr,"lazy",{enumerable:!0,get:function(){return $re.create}});Object.defineProperty(Rr,"ValidationError",{enumerable:!0,get:function(){return Gre.default}});Object.defineProperty(Rr,"reach",{enumerable:!0,get:function(){return qre.default}});Object.defineProperty(Rr,"isSchema",{enumerable:!0,get:function(){return XA.default}});Object.defineProperty(Rr,"setLocale",{enumerable:!0,get:function(){return Hre.default}});Object.defineProperty(Rr,"BaseSchema",{enumerable:!0,get:function(){return Wre.default}});var GA=Ao(rx()),wy=Ao(ox()),qA=Ao(px()),HA=Ao(hx()),WA=Ao(gx()),KA=Ao(MA()),zA=Ao(UA()),Vre=_o(),$re=VA(),Gre=Vp(To()),qre=Vp(ay()),XA=Vp(Ml()),Hre=Vp($A()),Wre=Vp(Zn());function Vp(e){return e&&e.__esModule?e:{default:e}}function YA(){if(typeof WeakMap!="function")return null;var e=new WeakMap;return YA=function(){return e},e}function Ao(e){if(e&&e.__esModule)return e;if(e===null||typeof e!="object"&&typeof e!="function")return{default:e};var t=YA();if(t&&t.has(e))return t.get(e);var s={},p=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var c in e)if(Object.prototype.hasOwnProperty.call(e,c)){var i=p?Object.getOwnPropertyDescriptor(e,c):null;i&&(i.get||i.set)?Object.defineProperty(s,c,i):s[c]=e[c]}return s.default=e,t&&t.set(e,s),s}function Kre(e,t,s){if(!e||!(0,XA.default)(e.prototype))throw new TypeError("You must provide a yup schema constructor function");if(typeof t!="string")throw new TypeError("A Method name must be provided");if(typeof s!="function")throw new TypeError("Method function must be provided");e.prototype[t]=s}});var aC=le((J1e,iie)=>{iie.exports={_args:[["dotenv@16.0.3","/home/runner/work/jest-coverage-report-action/jest-coverage-report-action"]],_development:!0,_from:"dotenv@16.0.3",_id:"dotenv@16.0.3",_inBundle:!1,_integrity:"sha512-7GO6HghkA5fYG9TYnNxi14/7K9f5occMlp3zXAuSxn7CKCxt9xbNWG7yF8hTCSUchlfWSe3uLmlPfigevRItzQ==",_location:"/dotenv",_phantomChildren:{},_requested:{type:"version",registry:!0,raw:"dotenv@16.0.3",name:"dotenv",escapedName:"dotenv",rawSpec:"16.0.3",saveSpec:null,fetchSpec:"16.0.3"},_requiredBy:["/c12"],_resolved:"https://registry.npmjs.org/dotenv/-/dotenv-16.0.3.tgz",_spec:"16.0.3",_where:"/home/runner/work/jest-coverage-report-action/jest-coverage-report-action",bugs:{url:"https://github.com/motdotla/dotenv/issues"},description:"Loads environment variables from .env file",devDependencies:{"@types/node":"^17.0.9",decache:"^4.6.1",dtslint:"^3.7.0",sinon:"^12.0.1",standard:"^16.0.4","standard-markdown":"^7.1.0","standard-version":"^9.3.2",tap:"^15.1.6",tar:"^6.1.11",typescript:"^4.5.4"},engines:{node:">=12"},exports:{".":{require:"./lib/main.js",types:"./lib/main.d.ts",default:"./lib/main.js"},"./config":"./config.js","./config.js":"./config.js","./lib/env-options":"./lib/env-options.js","./lib/env-options.js":"./lib/env-options.js","./lib/cli-options":"./lib/cli-options.js","./lib/cli-options.js":"./lib/cli-options.js","./package.json":"./package.json"},homepage:"https://github.com/motdotla/dotenv#readme",keywords:["dotenv","env",".env","environment","variables","config","settings"],license:"BSD-2-Clause",main:"lib/main.js",name:"dotenv",repository:{type:"git",url:"git://github.com/motdotla/dotenv.git"},scripts:{"dts-check":"tsc --project tests/types/tsconfig.json",lint:"standard","lint-readme":"standard-markdown",prerelease:"npm test",pretest:"npm run lint && npm run dts-check",release:"standard-version",test:"tap tests/*.js --100 -Rspec"},types:"lib/main.d.ts",version:"16.0.3"}});var lC=le((Q1e,zh)=>{var sie=require("fs"),oC=require("path"),nie=require("os"),aie=aC(),oie=aie.version,lie=/(?:^|^)\s*(?:export\s+)?([\w.-]+)(?:\s*=\s*?|:\s+?)(\s*'(?:\\'|[^'])*'|\s*"(?:\\"|[^"])*"|\s*`(?:\\`|[^`])*`|[^#\r\n]+)?\s*(?:#.*)?(?:$|$)/mg;function uie(e){let t={},s=e.toString();s=s.replace(/\r\n?/mg,` `);let p;for(;(p=lie.exec(s))!=null;){let c=p[1],i=p[2]||"";i=i.trim();let d=i[0];i=i.replace(/^(['"`])([\s\S]*)\1$/mg,"$2"),d==='"'&&(i=i.replace(/\\n/g,` `),i=i.replace(/\\r/g,"\r")),t[c]=i}return t}function Cy(e){console.log(`[dotenv@${oie}][DEBUG] ${e}`)}function pie(e){return e[0]==="~"?oC.join(nie.homedir(),e.slice(1)):e}function cie(e){let t=oC.resolve(process.cwd(),".env"),s="utf8",p=Boolean(e&&e.debug),c=Boolean(e&&e.override);e&&(e.path!=null&&(t=pie(e.path)),e.encoding!=null&&(s=e.encoding));try{let i=Kh.parse(sie.readFileSync(t,{encoding:s}));return Object.keys(i).forEach(function(d){Object.prototype.hasOwnProperty.call(process.env,d)?(c===!0&&(process.env[d]=i[d]),p&&Cy(c===!0?`"${d}" is already defined in \`process.env\` and WAS overwritten`:`"${d}" is already defined in \`process.env\` and was NOT overwritten`)):process.env[d]=i[d]}),{parsed:i}}catch(i){return p&&Cy(`Failed to load ${t} ${i.message}`),{error:i}}}var Kh={config:cie,parse:uie};zh.exports.config=Kh.config;zh.exports.parse=Kh.parse;zh.exports=Kh});var pC=le((Z1e,uC)=>{(()=>{var e={"./node_modules/.pnpm/create-require@1.1.1/node_modules/create-require/create-require.js":(c,i,d)=>{let a=d("module"),o=d("path"),n=d("fs");c.exports=function(l){return l||(l=process.cwd()),function(g){try{return n.lstatSync(g).isDirectory()}catch(h){return!1}}(l)&&(l=o.join(l,"index.js")),a.createRequire?a.createRequire(l):a.createRequireFromPath?a.createRequireFromPath(l):function(g){let h=new a.Module(g,null);return h.filename=g,h.paths=a.Module._nodeModulePaths(o.dirname(g)),h._compile("module.exports = require;",g),h.exports}(l)}},"./node_modules/.pnpm/lru-cache@6.0.0/node_modules/lru-cache/index.js":(c,i,d)=>{"use strict";let a=d("./node_modules/.pnpm/yallist@4.0.0/node_modules/yallist/yallist.js"),o=Symbol("max"),n=Symbol("length"),l=Symbol("lengthCalculator"),g=Symbol("allowStale"),h=Symbol("maxAge"),m=Symbol("dispose"),b=Symbol("noDisposeOnSet"),E=Symbol("lruList"),_=Symbol("cache"),C=Symbol("updateAgeOnGet"),T=()=>1,w=(F,q,D)=>{let $=F[_].get(q);if($){let z=$.value;if(A(F,z)){if(I(F,$),!F[g])return}else D&&(F[C]&&($.value.now=Date.now()),F[E].unshiftNode($));return z.value}},A=(F,q)=>{if(!q||!q.maxAge&&!F[h])return!1;let D=Date.now()-q.now;return q.maxAge?D>q.maxAge:F[h]&&D>F[h]},x=F=>{if(F[n]>F[o])for(let q=F[E].tail;F[n]>F[o]&&q!==null;){let D=q.prev;I(F,q),q=D}},I=(F,q)=>{if(q){let D=q.value;F[m]&&F[m](D.key,D.value),F[n]-=D.length,F[_].delete(D.key),F[E].removeNode(q)}};class S{constructor(q,D,$,z,K){this.key=q,this.value=D,this.length=$,this.now=z,this.maxAge=K||0}}let j=(F,q,D,$)=>{let z=D.value;A(F,z)&&(I(F,D),F[g]||(z=void 0)),z&&q.call($,z.value,z.key,F)};c.exports=class{constructor(F){if(typeof F=="number"&&(F={max:F}),F||(F={}),F.max&&(typeof F.max!="number"||F.max<0))throw new TypeError("max must be a non-negative number");this[o]=F.max||1/0;let q=F.length||T;if(this[l]=typeof q!="function"?T:q,this[g]=F.stale||!1,F.maxAge&&typeof F.maxAge!="number")throw new TypeError("maxAge must be a number");this[h]=F.maxAge||0,this[m]=F.dispose,this[b]=F.noDisposeOnSet||!1,this[C]=F.updateAgeOnGet||!1,this.reset()}set max(F){if(typeof F!="number"||F<0)throw new TypeError("max must be a non-negative number");this[o]=F||1/0,x(this)}get max(){return this[o]}set allowStale(F){this[g]=!!F}get allowStale(){return this[g]}set maxAge(F){if(typeof F!="number")throw new TypeError("maxAge must be a non-negative number");this[h]=F,x(this)}get maxAge(){return this[h]}set lengthCalculator(F){typeof F!="function"&&(F=T),F!==this[l]&&(this[l]=F,this[n]=0,this[E].forEach(q=>{q.length=this[l](q.value,q.key),this[n]+=q.length})),x(this)}get lengthCalculator(){return this[l]}get length(){return this[n]}get itemCount(){return this[E].length}rforEach(F,q){q=q||this;for(let D=this[E].tail;D!==null;){let $=D.prev;j(this,F,D,q),D=$}}forEach(F,q){q=q||this;for(let D=this[E].head;D!==null;){let $=D.next;j(this,F,D,q),D=$}}keys(){return this[E].toArray().map(F=>F.key)}values(){return this[E].toArray().map(F=>F.value)}reset(){this[m]&&this[E]&&this[E].length&&this[E].forEach(F=>this[m](F.key,F.value)),this[_]=new Map,this[E]=new a,this[n]=0}dump(){return this[E].map(F=>!A(this,F)&&{k:F.key,v:F.value,e:F.now+(F.maxAge||0)}).toArray().filter(F=>F)}dumpLru(){return this[E]}set(F,q,D){if((D=D||this[h])&&typeof D!="number")throw new TypeError("maxAge must be a number");let $=D?Date.now():0,z=this[l](q,F);if(this[_].has(F)){if(z>this[o])return I(this,this[_].get(F)),!1;let O=this[_].get(F).value;return this[m]&&(this[b]||this[m](F,O.value)),O.now=$,O.maxAge=D,O.value=q,this[n]+=z-O.length,O.length=z,this.get(F),x(this),!0}let K=new S(F,q,z,$,D);return K.length>this[o]?(this[m]&&this[m](F,q),!1):(this[n]+=K.length,this[E].unshift(K),this[_].set(F,this[E].head),x(this),!0)}has(F){if(!this[_].has(F))return!1;let q=this[_].get(F).value;return!A(this,q)}get(F){return w(this,F,!0)}peek(F){return w(this,F,!1)}pop(){let F=this[E].tail;return F?(I(this,F),F.value):null}del(F){I(this,this[_].get(F))}load(F){this.reset();let q=Date.now();for(let D=F.length-1;D>=0;D--){let $=F[D],z=$.e||0;if(z===0)this.set($.k,$.v);else{let K=z-q;K>0&&this.set($.k,$.v,K)}}}prune(){this[_].forEach((F,q)=>w(this,q,!1))}}},"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/index.js":(c,i,d)=>{let a=d("./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/opts-arg.js"),o=d("./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/path-arg.js"),{mkdirpNative:n,mkdirpNativeSync:l}=d("./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/mkdirp-native.js"),{mkdirpManual:g,mkdirpManualSync:h}=d("./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/mkdirp-manual.js"),{useNative:m,useNativeSync:b}=d("./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/use-native.js"),E=(_,C)=>(_=o(_),C=a(C),m(C)?n(_,C):g(_,C));E.sync=(_,C)=>(_=o(_),C=a(C),b(C)?l(_,C):h(_,C)),E.native=(_,C)=>n(o(_),a(C)),E.manual=(_,C)=>g(o(_),a(C)),E.nativeSync=(_,C)=>l(o(_),a(C)),E.manualSync=(_,C)=>h(o(_),a(C)),c.exports=E},"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/find-made.js":(c,i,d)=>{let{dirname:a}=d("path"),o=(l,g,h)=>h===g?Promise.resolve():l.statAsync(g).then(m=>m.isDirectory()?h:void 0,m=>m.code==="ENOENT"?o(l,a(g),g):void 0),n=(l,g,h)=>{if(h!==g)try{return l.statSync(g).isDirectory()?h:void 0}catch(m){return m.code==="ENOENT"?n(l,a(g),g):void 0}};c.exports={findMade:o,findMadeSync:n}},"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/mkdirp-manual.js":(c,i,d)=>{let{dirname:a}=d("path"),o=(l,g,h)=>{g.recursive=!1;let m=a(l);return m===l?g.mkdirAsync(l,g).catch(b=>{if(b.code!=="EISDIR")throw b}):g.mkdirAsync(l,g).then(()=>h||l,b=>{if(b.code==="ENOENT")return o(m,g).then(E=>o(l,g,E));if(b.code!=="EEXIST"&&b.code!=="EROFS")throw b;return g.statAsync(l).then(E=>{if(E.isDirectory())return h;throw b},()=>{throw b})})},n=(l,g,h)=>{let m=a(l);if(g.recursive=!1,m===l)try{return g.mkdirSync(l,g)}catch(b){if(b.code!=="EISDIR")throw b;return}try{return g.mkdirSync(l,g),h||l}catch(b){if(b.code==="ENOENT")return n(l,g,n(m,g,h));if(b.code!=="EEXIST"&&b.code!=="EROFS")throw b;try{if(!g.statSync(l).isDirectory())throw b}catch(E){throw b}}};c.exports={mkdirpManual:o,mkdirpManualSync:n}},"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/mkdirp-native.js":(c,i,d)=>{let{dirname:a}=d("path"),{findMade:o,findMadeSync:n}=d("./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/find-made.js"),{mkdirpManual:l,mkdirpManualSync:g}=d("./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/mkdirp-manual.js");c.exports={mkdirpNative:(h,m)=>(m.recursive=!0,a(h)===h?m.mkdirAsync(h,m):o(m,h).then(b=>m.mkdirAsync(h,m).then(()=>b).catch(E=>{if(E.code==="ENOENT")return l(h,m);throw E}))),mkdirpNativeSync:(h,m)=>{if(m.recursive=!0,a(h)===h)return m.mkdirSync(h,m);let b=n(m,h);try{return m.mkdirSync(h,m),b}catch(E){if(E.code==="ENOENT")return g(h,m);throw E}}}},"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/opts-arg.js":(c,i,d)=>{let{promisify:a}=d("util"),o=d("fs");c.exports=n=>{if(n)if(typeof n=="object")n=Tt({mode:511,fs:o},n);else if(typeof n=="number")n={mode:n,fs:o};else{if(typeof n!="string")throw new TypeError("invalid options argument");n={mode:parseInt(n,8),fs:o}}else n={mode:511,fs:o};return n.mkdir=n.mkdir||n.fs.mkdir||o.mkdir,n.mkdirAsync=a(n.mkdir),n.stat=n.stat||n.fs.stat||o.stat,n.statAsync=a(n.stat),n.statSync=n.statSync||n.fs.statSync||o.statSync,n.mkdirSync=n.mkdirSync||n.fs.mkdirSync||o.mkdirSync,n}},"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/path-arg.js":(c,i,d)=>{let a=process.env.__TESTING_MKDIRP_PLATFORM__||process.platform,{resolve:o,parse:n}=d("path");c.exports=l=>{if(/\0/.test(l))throw Object.assign(new TypeError("path must be a string without null bytes"),{path:l,code:"ERR_INVALID_ARG_VALUE"});if(l=o(l),a==="win32"){let g=/[*|"<>?:]/,{root:h}=n(l);if(g.test(l.substr(h.length)))throw Object.assign(new Error("Illegal characters in path."),{path:l,code:"EINVAL"})}return l}},"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/use-native.js":(c,i,d)=>{let a=d("fs"),o=(process.env.__TESTING_MKDIRP_NODE_VERSION__||process.version).replace(/^v/,"").split("."),n=+o[0]>10||+o[0]==10&&+o[1]>=12,l=n?h=>h.mkdir===a.mkdir:()=>!1,g=n?h=>h.mkdirSync===a.mkdirSync:()=>!1;c.exports={useNative:l,useNativeSync:g}},"./node_modules/.pnpm/mlly@0.5.14/node_modules/mlly/dist lazy recursive":c=>{function i(d){return Promise.resolve().then(()=>{var a=new Error("Cannot find module '"+d+"'");throw a.code="MODULE_NOT_FOUND",a})}i.keys=()=>[],i.resolve=i,i.id="./node_modules/.pnpm/mlly@0.5.14/node_modules/mlly/dist lazy recursive",c.exports=i},"./node_modules/.pnpm/object-hash@3.0.0/node_modules/object-hash/index.js":(c,i,d)=>{"use strict";var a=d("crypto");function o(E,_){return function(C,T){var w;if(w=T.algorithm!=="passthrough"?a.createHash(T.algorithm):new b,w.write===void 0&&(w.write=w.update,w.end=w.update),m(T,w).dispatch(C),w.update||w.end(""),w.digest)return w.digest(T.encoding==="buffer"?void 0:T.encoding);var A=w.read();return T.encoding==="buffer"?A:A.toString(T.encoding)}(E,_=g(E,_))}(i=c.exports=o).sha1=function(E){return o(E)},i.keys=function(E){return o(E,{excludeValues:!0,algorithm:"sha1",encoding:"hex"})},i.MD5=function(E){return o(E,{algorithm:"md5",encoding:"hex"})},i.keysMD5=function(E){return o(E,{algorithm:"md5",encoding:"hex",excludeValues:!0})};var n=a.getHashes?a.getHashes().slice():["sha1","md5"];n.push("passthrough");var l=["buffer","hex","binary","base64"];function g(E,_){_=_||{};var C={};if(C.algorithm=_.algorithm||"sha1",C.encoding=_.encoding||"hex",C.excludeValues=!!_.excludeValues,C.algorithm=C.algorithm.toLowerCase(),C.encoding=C.encoding.toLowerCase(),C.ignoreUnknown=_.ignoreUnknown===!0,C.respectType=_.respectType!==!1,C.respectFunctionNames=_.respectFunctionNames!==!1,C.respectFunctionProperties=_.respectFunctionProperties!==!1,C.unorderedArrays=_.unorderedArrays===!0,C.unorderedSets=_.unorderedSets!==!1,C.unorderedObjects=_.unorderedObjects!==!1,C.replacer=_.replacer||void 0,C.excludeKeys=_.excludeKeys||void 0,E===void 0)throw new Error("Object argument required.");for(var T=0;T=0)return this.dispatch("[CIRCULAR:"+I+"]");if(C.push(w),typeof Buffer!="undefined"&&Buffer.isBuffer&&Buffer.isBuffer(w))return T("buffer:"),T(w);if(x==="object"||x==="function"||x==="asyncfunction"){var S=Object.keys(w);E.unorderedObjects&&(S=S.sort()),E.respectType===!1||h(w)||S.splice(0,0,"prototype","__proto__","constructor"),E.excludeKeys&&(S=S.filter(function(F){return!E.excludeKeys(F)})),T("object:"+S.length+":");var j=this;return S.forEach(function(F){j.dispatch(F),T(":"),E.excludeValues||j.dispatch(w[F]),T(",")})}if(!this["_"+x]){if(E.ignoreUnknown)return T("["+x+"]");throw new Error('Unknown object type "'+x+'"')}this["_"+x](w)},_array:function(w,A){A=A!==void 0?A:E.unorderedArrays!==!1;var x=this;if(T("array:"+w.length+":"),!A||w.length<=1)return w.forEach(function(j){return x.dispatch(j)});var I=[],S=w.map(function(j){var F=new b,q=C.slice();return m(E,F,q).dispatch(j),I=I.concat(q.slice(C.length)),F.read().toString()});return C=C.concat(I),S.sort(),this._array(S,!1)},_date:function(w){return T("date:"+w.toJSON())},_symbol:function(w){return T("symbol:"+w.toString())},_error:function(w){return T("error:"+w.toString())},_boolean:function(w){return T("bool:"+w.toString())},_string:function(w){T("string:"+w.length+":"),T(w.toString())},_function:function(w){T("fn:"),h(w)?this.dispatch("[native]"):this.dispatch(w.toString()),E.respectFunctionNames!==!1&&this.dispatch("function-name:"+String(w.name)),E.respectFunctionProperties&&this._object(w)},_number:function(w){return T("number:"+w.toString())},_xml:function(w){return T("xml:"+w.toString())},_null:function(){return T("Null")},_undefined:function(){return T("Undefined")},_regexp:function(w){return T("regex:"+w.toString())},_uint8array:function(w){return T("uint8array:"),this.dispatch(Array.prototype.slice.call(w))},_uint8clampedarray:function(w){return T("uint8clampedarray:"),this.dispatch(Array.prototype.slice.call(w))},_int8array:function(w){return T("int8array:"),this.dispatch(Array.prototype.slice.call(w))},_uint16array:function(w){return T("uint16array:"),this.dispatch(Array.prototype.slice.call(w))},_int16array:function(w){return T("int16array:"),this.dispatch(Array.prototype.slice.call(w))},_uint32array:function(w){return T("uint32array:"),this.dispatch(Array.prototype.slice.call(w))},_int32array:function(w){return T("int32array:"),this.dispatch(Array.prototype.slice.call(w))},_float32array:function(w){return T("float32array:"),this.dispatch(Array.prototype.slice.call(w))},_float64array:function(w){return T("float64array:"),this.dispatch(Array.prototype.slice.call(w))},_arraybuffer:function(w){return T("arraybuffer:"),this.dispatch(new Uint8Array(w))},_url:function(w){return T("url:"+w.toString())},_map:function(w){T("map:");var A=Array.from(w);return this._array(A,E.unorderedSets!==!1)},_set:function(w){T("set:");var A=Array.from(w);return this._array(A,E.unorderedSets!==!1)},_file:function(w){return T("file:"),this.dispatch([w.name,w.size,w.type,w.lastModfied])},_blob:function(){if(E.ignoreUnknown)return T("[blob]");throw Error(`Hashing Blob objects is currently not supported (see https://github.com/puleos/object-hash/issues/26) @@ -2227,7 +2227,7 @@ Defaulting to 2020, but this will stop working in the future.`)),t.ecmaVersion=1 `;case 114:return"\r";case 120:return String.fromCharCode(this.readHexChar(2));case 117:return Oa(this.readCodePoint());case 116:return" ";case 98:return"\b";case 118:return"\v";case 102:return"\f";case 13:this.input.charCodeAt(this.pos)===10&&++this.pos;case 10:return this.options.locations&&(this.lineStart=this.pos,++this.curLine),"";case 56:case 57:if(this.strict&&this.invalidStringToken(this.pos-1,"Invalid escape sequence"),e){var s=this.pos-1;return this.invalidStringToken(s,"Invalid escape sequence in template string"),null}default:if(t>=48&&t<=55){var p=this.input.substr(this.pos-1,3).match(/^[0-7]+/)[0],c=parseInt(p,8);return c>255&&(p=p.slice(0,-1),c=parseInt(p,8)),this.pos+=p.length-1,t=this.input.charCodeAt(this.pos),(p!=="0"||t===56||t===57)&&(this.strict||e)&&this.invalidStringToken(this.pos-1-p.length,e?"Octal literal in template string":"Octal literal in strict mode"),String.fromCharCode(c)}return Xl(t)?"":String.fromCharCode(t)}};ur.readHexChar=function(e){var t=this.pos,s=this.readInt(16,e);return s===null&&this.invalidStringToken(t,"Bad character escape sequence"),s};ur.readWord1=function(){this.containsEsc=!1;for(var e="",t=!0,s=this.pos,p=this.options.ecmaVersion>=6;this.posdI(s))}catch(s){return dI(s)}}function dI(e){let t=new Error(e);return t.code=e.code,Error.captureStackTrace(t,cI),Promise.reject(t)}var sse={read:nse};function nse(e){return hI(No.default.dirname(e))}function hI(e){try{return{string:Os.default.readFileSync(No.default.toNamespacedPath(No.default.join(e,"package.json")),"utf8")}}catch(t){if(t.code==="ENOENT"){let s=No.default.dirname(e);return e!==s?hI(s):{string:void 0}}throw t}}var ase=process.platform==="win32",ose={}.hasOwnProperty,Ds={},fI=new Map,lse="__node_internal_",mI;Ds.ERR_INVALID_MODULE_SPECIFIER=_n("ERR_INVALID_MODULE_SPECIFIER",(e,t,s=void 0)=>`Invalid module "${e}" ${t}${s?` imported from ${s}`:""}`,TypeError);Ds.ERR_INVALID_PACKAGE_CONFIG=_n("ERR_INVALID_PACKAGE_CONFIG",(e,t,s)=>`Invalid package config ${e}${t?` while importing ${t}`:""}${s?`. ${s}`:""}`,Error);Ds.ERR_INVALID_PACKAGE_TARGET=_n("ERR_INVALID_PACKAGE_TARGET",(e,t,s,p=!1,c=void 0)=>{let i=typeof s=="string"&&!p&&s.length>0&&!s.startsWith("./");return t==="."?((0,nf.default)(p===!1),`Invalid "exports" main target ${JSON.stringify(s)} defined in the package config ${e}package.json${c?` imported from ${c}`:""}${i?'; targets must start with "./"':""}`):`Invalid "${p?"imports":"exports"}" target ${JSON.stringify(s)} defined for '${t}' in the package config ${e}package.json${c?` imported from ${c}`:""}${i?'; targets must start with "./"':""}`},Error);Ds.ERR_MODULE_NOT_FOUND=_n("ERR_MODULE_NOT_FOUND",(e,t,s="package")=>`Cannot find ${s} '${e}' imported from ${t}`,Error);Ds.ERR_PACKAGE_IMPORT_NOT_DEFINED=_n("ERR_PACKAGE_IMPORT_NOT_DEFINED",(e,t,s)=>`Package import specifier "${e}" is not defined${t?` in package ${t}package.json`:""} imported from ${s}`,TypeError);Ds.ERR_PACKAGE_PATH_NOT_EXPORTED=_n("ERR_PACKAGE_PATH_NOT_EXPORTED",(e,t,s=void 0)=>t==="."?`No "exports" main defined in ${e}package.json${s?` imported from ${s}`:""}`:`Package subpath '${t}' is not defined by "exports" in ${e}package.json${s?` imported from ${s}`:""}`,Error);Ds.ERR_UNSUPPORTED_DIR_IMPORT=_n("ERR_UNSUPPORTED_DIR_IMPORT","Directory import '%s' is not supported resolving ES modules imported from %s",Error);Ds.ERR_UNKNOWN_FILE_EXTENSION=_n("ERR_UNKNOWN_FILE_EXTENSION",'Unknown file extension "%s" for %s',TypeError);Ds.ERR_INVALID_ARG_VALUE=_n("ERR_INVALID_ARG_VALUE",(e,t,s="is invalid")=>{let p=(0,af.inspect)(t);return p.length>128&&(p=`${p.slice(0,128)}...`),`The ${e.includes(".")?"property":"argument"} '${e}' ${s}. Received ${p}`},TypeError);Ds.ERR_UNSUPPORTED_ESM_URL_SCHEME=_n("ERR_UNSUPPORTED_ESM_URL_SCHEME",e=>{let t="Only file and data URLs are supported by the default ESM loader";return ase&&e.protocol.length===2&&(t+=". On Windows, absolute paths must be valid file:// URLs"),t+=`. Received protocol '${e.protocol}'`,t},Error);function _n(e,t,s){return fI.set(e,t),use(s,e)}function use(e,t){return s;function s(...p){let c=Error.stackTraceLimit;zy()&&(Error.stackTraceLimit=0);let i=new e;zy()&&(Error.stackTraceLimit=c);let d=dse(t,p,i);return Object.defineProperty(i,"message",{value:d,enumerable:!1,writable:!0,configurable:!0}),Object.defineProperty(i,"toString",{value(){return`${this.name} [${t}]: ${this.message}`},enumerable:!1,writable:!0,configurable:!0}),pse(i,e.name,t),i.code=t,i}}var pse=yI(function(e,t,s){e=cse(e),e.name=`${t} [${s}]`,e.stack,t==="SystemError"?Object.defineProperty(e,"name",{value:t,enumerable:!1,writable:!0,configurable:!0}):delete e.name});function zy(){let e=Object.getOwnPropertyDescriptor(Error,"stackTraceLimit");return e===void 0?Object.isExtensible(Error):ose.call(e,"writable")?e.writable:e.set!==void 0}function yI(e){let t=lse+e.name;return Object.defineProperty(e,"name",{value:t}),e}var cse=yI(function(e){let t=zy();return t&&(mI=Error.stackTraceLimit,Error.stackTraceLimit=Number.POSITIVE_INFINITY),Error.captureStackTrace(e),t&&(Error.stackTraceLimit=mI),e});function dse(e,t,s){let p=fI.get(e);if(typeof p=="function")return(0,nf.default)(p.length<=t.length,`Code: ${e}; The provided arguments length (${t.length}) does not match the required ones (${p.length}).`),Reflect.apply(p,s,t);let c=(p.match(/%[dfijoOs]/g)||[]).length;return(0,nf.default)(c===t.length,`Code: ${e}; The provided arguments length (${t.length}) does not match the required ones (${c}).`),t.length===0?p:(t.unshift(p),Reflect.apply(af.format,null,t))}var{ERR_UNKNOWN_FILE_EXTENSION:hse}=Ds,fse={__proto__:null,".cjs":"commonjs",".js":"module",".mjs":"module"};function mse(e){if(e.startsWith("node:"))return{format:"builtin"};let t=new Qt.URL(e);if(t.protocol==="data:"){let{1:s}=/^([^/]+\/[^;,]+)[^,]*?(;base64)?,/.exec(t.pathname)||[null,null];return{format:s==="text/javascript"?"module":null}}if(t.protocol==="file:"){let s=No.default.extname(t.pathname),p;if(s===".js"?p=Ise(t.href)==="module"?"module":"commonjs":p=fse[s],!p)throw new hse(s,(0,Qt.fileURLToPath)(e));return{format:p||null}}return{format:null}}var{ERR_INVALID_MODULE_SPECIFIER:of,ERR_INVALID_PACKAGE_CONFIG:Xy,ERR_INVALID_PACKAGE_TARGET:yse,ERR_MODULE_NOT_FOUND:Yy,ERR_PACKAGE_IMPORT_NOT_DEFINED:gse,ERR_PACKAGE_PATH_NOT_EXPORTED:bse,ERR_UNSUPPORTED_DIR_IMPORT:vse,ERR_UNSUPPORTED_ESM_URL_SCHEME:g0e,ERR_INVALID_ARG_VALUE:b0e}=Ds,gI={}.hasOwnProperty;Object.freeze(["node","import"]);var bI=/(^|\\|\/)(\.\.?|node_modules)(\\|\/|$)/,vI=/\*/g,Ese=/%2f|%2c/i,EI=new Set,lf=new Map;function TI(e,t,s,p){let c=(0,Qt.fileURLToPath)(t);EI.has(c+"|"+e)||(EI.add(c+"|"+e),process.emitWarning(`Use of deprecated folder mapping "${e}" in the ${s?'"exports"':'"imports"'} field module resolution of the package at ${c}${p?` imported from ${(0,Qt.fileURLToPath)(p)}`:""}. Update this package.json to use a subpath pattern like "${e}*".`,"DeprecationWarning","DEP0148"))}function SI(e,t,s,p){let{format:c}=mse(e.href);if(c!=="module")return;let i=(0,Qt.fileURLToPath)(e.href),d=(0,Qt.fileURLToPath)(new URL(".",t)),a=(0,Qt.fileURLToPath)(s);p?process.emitWarning(`Package ${d} has a "main" field set to ${JSON.stringify(p)}, excluding the full filename and extension to the resolved file at "${i.slice(d.length)}", imported from ${a}. Automatic extension resolution of the "main" field isdeprecated for ES modules.`,"DeprecationWarning","DEP0151"):process.emitWarning(`No "main" or "exports" field defined in the package.json for ${d} resolving the main entry point "${i.slice(d.length)}", imported from ${a}. -Default "index" lookups for the main are deprecated for ES modules.`,"DeprecationWarning","DEP0151")}function Jy(e){try{return(0,Os.statSync)(e)}catch(t){return new Os.Stats}}function wI(e,t,s){let p=lf.get(e);if(p!==void 0)return p;let c=sse.read(e).string;if(c===void 0){let h={pjsonPath:e,exists:!1,main:void 0,name:void 0,type:"none",exports:void 0,imports:void 0};return lf.set(e,h),h}let i;try{i=JSON.parse(c)}catch(h){throw new Xy(e,(s?`"${t}" from `:"")+(0,Qt.fileURLToPath)(s||t),h.message)}let{exports:d,imports:a,main:o,name:n,type:l}=i,g={pjsonPath:e,exists:!0,main:typeof o=="string"?o:void 0,name:typeof n=="string"?n:void 0,type:l==="module"||l==="commonjs"?l:"none",exports:d,imports:a&&typeof a=="object"?a:void 0};return lf.set(e,g),g}function Qy(e){let t=new URL("./package.json",e);for(;!t.pathname.endsWith("node_modules/package.json");){let i=wI((0,Qt.fileURLToPath)(t),e);if(i.exists)return i;let d=t;if(t=new URL("../package.json",t),t.pathname===d.pathname)break}let s=(0,Qt.fileURLToPath)(t),p={pjsonPath:s,exists:!1,main:void 0,name:void 0,type:"none",exports:void 0,imports:void 0};return lf.set(s,p),p}function Zy(e){return Jy((0,Qt.fileURLToPath)(e)).isFile()}function Tse(e,t,s){let p;if(t.main!==void 0){if(p=new URL(`./${t.main}`,e),Zy(p))return p;let d=[`./${t.main}.js`,`./${t.main}.json`,`./${t.main}.node`,`./${t.main}/index.js`,`./${t.main}/index.json`,`./${t.main}/index.node`],a=-1;for(;++a=0&&t<4294967295}function Ql(e,t,s,p,c,i,d,a){if(typeof t=="string")return Pse(t,s,p,e,c,i,d,a);if(Array.isArray(t)){let o=t;if(o.length===0)return null;let n,l=-1;for(;++l=n.length&&n.length>d.length||n[n.length-1]==="/"&&t.startsWith(n)&&n.length>d.length)&&(d=n)}if(d){let n=i[d],l=d[d.length-1]==="*",g=t.slice(d.length-(l?1:0)),h=Ql(e,n,g,d,p,l,!1,c);return h==null&&eg(t,e,p),l||TI(d,e,!0,p),{resolved:h,exact:l}}eg(t,e,p)}function Cse(e,t,s){if(e==="#"||e.startsWith("#/")){let i="is not a valid internal imports specifier name";throw new of(e,i,(0,Qt.fileURLToPath)(t))}let p,c=Qy(t);if(c.exists){p=(0,Qt.pathToFileURL)(c.pjsonPath);let i=c.imports;if(i)if(gI.call(i,e)){let d=Ql(p,i[e],"",e,t,!1,!0,s);if(d!==null)return{resolved:d,exact:!0}}else{let d="",a=Object.getOwnPropertyNames(i),o=-1;for(;++o=n.length&&n.length>d.length||n[n.length-1]==="/"&&e.startsWith(n)&&n.length>d.length)&&(d=n)}if(d){let n=i[d],l=d[d.length-1]==="*",g=e.slice(d.length-(l?1:0)),h=Ql(p,n,g,d,t,l,!0,s);if(h!==null)return l||TI(d,p,!1,t),{resolved:h,exact:l}}}}wse(e,p,t)}function Ise(e){return Qy(e).type}function Nse(e,t){let s=e.indexOf("/"),p=!0,c=!1;e[0]==="@"&&(c=!0,s===-1||e.length===0?p=!1:s=e.indexOf("/",s+1));let i=s===-1?e:e.slice(0,s),d=-1;for(;++dnew URL(Rse(a.toString())));p.length||p.push(Fse);let c=[...p];for(let a of p)a.protocol==="file:"&&(c.push(new URL("./",a)),c.push(new URL(uI(a.pathname,"_index.js"),a)),c.push(new URL("./node_modules",a)));let i;for(let a of c){if(i=xI(e,a,s),i)break;for(let o of["","/index"]){for(let n of t.extensions||jse)if(i=xI(e+o+n,a,s),i)break;if(i)break}}if(!i){let a=new Error(`Cannot find module ${e} imported from ${c.join(", ")}`);throw a.code="ERR_MODULE_NOT_FOUND",a}let d=(0,Os.realpathSync)(tg(i));return(0,Qt.pathToFileURL)(d).toString()}function Use(e,t){return Bse(e,t)}function Vse(e,t){return tg(Use(e,t))}function rg(e,t){return cI(Vse,e,t)}var $se={startingFrom:".",rootPattern:/^node_modules$/,reverse:!1,test:e=>{try{if((0,ig.statSync)(e).isFile())return!0}catch(t){}return null}};async function AI(e,t={}){let s=Tt(Tt({},$se),t),p=Ys(s.startingFrom),c=p[0]==="/",i=p.split("/").filter(Boolean);c&&(i[0]="/"+i[0]);let d=i.findIndex(a=>a.match(s.rootPattern));if(d===-1&&(d=0),s.reverse)for(let a=d+1;a<=i.length;a++){let o=Hh(...i.slice(0,a),e);if(await s.test(o))return o}else for(let a=i.length;a>d;a--){let o=Hh(...i.slice(0,a),e);if(await s.test(o))return o}throw new Error(`Cannot find matching ${e} in ${s.startingFrom} or parent directories`)}function CI(e,t={}){return AI(e,t)}var Gse=["yarn.lock","package-lock.json","pnpm-lock.yaml","npm-shrinkwrap.json"];async function qse(e=process.cwd(),t={}){let s=Js(e)?e:await rg(e,t),p=Tt({startingFrom:s},t);for(let c of Gse)try{return await CI(c,p)}catch(i){}throw new Error("No lockfile found from "+e)}async function II(e=process.cwd(),t={}){let s=Js(e)?e:await rg(e,t),p=Tt({startingFrom:s},t);try{let c=await CI(".git/config",p);return(0,Qp.resolve)(c,"../..")}catch(c){}try{let c=await qse(s,ar(Tt({},p),{reverse:!0}));return(0,Qp.dirname)(c)}catch(c){}try{let c=await AI(s,p);return(0,Qp.dirname)(c)}catch(c){}throw new Error("Cannot detect workspace root from "+e)}async function soe(e){var p,c,i;let t=(p=e.env)!=null?p:process.env,s=await noe({cwd:e.cwd,fileName:(c=e.fileName)!=null?c:".env",env:t,interpolate:(i=e.interpolate)!=null?i:!0});for(let d in s)!d.startsWith("_")&&t[d]===void 0&&(t[d]=s[d]);return s}async function noe(e){let t=Object.create(null),s=Ys(e.cwd,e.fileName);if((0,gu.existsSync)(s)){let p=PD.parse(await gu.promises.readFile(s,"utf-8"));Object.assign(t,p)}return e.env._applied||(Object.assign(t,e.env),t._applied=!0),e.interpolate&&aoe(t),t}function aoe(e,t={},s=p=>p){function p(i){return t[i]!==void 0?t[i]:e[i]}function c(i,d=[]){if(typeof i!="string")return i;let a=i.match(/(.?\${?(?:[a-zA-Z0-9_:]+)?}?)/g)||[];return s(a.reduce((o,n)=>{let l=/(.?)\${?([a-zA-Z0-9_:]+)?}?/g.exec(n),g=l[1],h,m;if(g==="\\")m=l[0],h=m.replace("\\$","$");else{let b=l[2];if(m=l[0].substring(g.length),d.includes(b))return console.warn(`Please avoid recursive environment variables ( loop: ${d.join(" > ")} > ${b} )`),"";h=p(b),h=c(h,[...d,b])}return h!==void 0?o.replace(m,h):o},i))}for(let i in e)e[i]=c(p(i))}async function CD(e){var d,a;e.cwd=Ys(process.cwd(),e.cwd||"."),e.name=e.name||"config",e.configFile=(d=e.configFile)!=null?d:e.name!=="config"?`${e.name}.config`:"config",e.rcFile=(a=e.rcFile)!=null?a:`.${e.name}rc`,e.extend!==!1&&(e.extend=Tt({extendKey:"extends"},e.extend)),e.jiti=e.jiti||(0,AD.default)(null,Tt({interopDefault:!0,requireCache:!1,esmResolve:!0},e.jitiOptions));let t={config:{},cwd:e.cwd,configFile:Ys(e.cwd,e.configFile),layers:[]};e.dotenv&&await soe(Tt({cwd:e.cwd},e.dotenv===!0?{}:e.dotenv));let{config:s,configFile:p}=await ND(".",e);p&&(t.configFile=p);let c={};if(e.rcFile){if(e.globalRc){Object.assign(c,PC({name:e.rcFile,dir:e.cwd}));let o=await II(e.cwd).catch(()=>null);o&&Object.assign(c,Xh({name:e.rcFile,dir:o}))}Object.assign(c,Xh({name:e.rcFile,dir:e.cwd}))}t.config=Gp(e.overrides,s,c,e.defaultConfig),e.extend&&(await ID(t.config,e),t.layers=t.config._layers,delete t.config._layers,t.config=Gp(t.config,...t.layers.map(o=>o.config)));let i=[e.overrides&&{config:e.overrides,configFile:void 0,cwd:void 0},{config:s,configFile:e.configFile,cwd:e.cwd},e.rcFile&&{config:c,configFile:e.rcFile}].filter(o=>o&&o.config);return t.layers=[...i,...t.layers],e.defaults&&(t.config=Gp(t.config,e.defaults)),t}async function ID(e,t){if(e._layers=e._layers||[],!t.extend)return;let s=t.extend.extendKey;typeof s=="string"&&(s=[s]);let p=[];for(let c of s)p.push(...(Array.isArray(e[c])?e[c]:[e[c]]).filter(Boolean)),delete e[c];for(let c of p){if(typeof c!="string"){console.warn(`Cannot extend config from \`${JSON.stringify(c)}\` (which should be a string) in ${t.cwd}`);continue}let i=await ND(c,t);if(!i.config){console.warn(`Cannot extend config from \`${c}\` in ${t.cwd}`);continue}await ID(i.config,ar(Tt({},t),{cwd:i.cwd})),e._layers.push(i),i.config._layers&&(e._layers.push(...i.config._layers),delete i.config._layers)}}var ooe=["github:","gitlab:","bitbucket:","https://"],loe=/^(@[a-z0-9-~][a-z0-9-._~]*\/)?[a-z0-9-~][a-z0-9-._~]*$/;async function ND(e,t){if(t.resolve){let i=await t.resolve(e,t);if(i)return i}if(ooe.some(i=>e.startsWith(i))){let i=new URL(e),d=i.pathname.split("/").slice(2).join("/"),a=i.protocol+i.pathname.split("/").slice(0,2).join("/"),o=Ys(xD.default.tmpdir(),"c12/",a.replace(/[#:@/\\]/g,"_"));await gu.promises.rm(o,{recursive:!0}).catch(()=>{});let n=await Promise.resolve().then(()=>Ft(_D())).then(g=>g.default||g),l=await n.fetch(a);await n.extract(l,o),e=Ys(o,d)}if(loe.test(e))try{e=t.jiti.resolve(e,{paths:[t.cwd]})}catch(i){}let s=!Wh(e),p=Ys(t.cwd,s?e:Ay(e));s&&(e=t.configFile);let c={config:null,cwd:p};try{c.configFile=t.jiti.resolve(Ys(p,e),{paths:[p]})}catch(i){}return(0,gu.existsSync)(c.configFile)&&(c.config=t.jiti(c.configFile),typeof c.config=="function"&&(c.config=await c.config())),c}var OD=e=>CD({cwd:e,name:"jest"});var DD=async e=>{try{let t=await OD(e);return t==null?void 0:t.coverageThreshold}catch(t){console.log("[Warning] Failed to parse jest configuration.",'"coverageThreshold" from config file will be ignored.',t);return}};var RD=async(e,t)=>{let s=await DD(e);return(0,kD.default)(s)?{global:{branches:t,functions:t,lines:t,statements:t}}:s};var LD=Ft(Gn());async function FD(e,t){return(await e.rest.pulls.get(ar(Tt({},LD.context.repo),{pull_number:t.pullRequest.number,headers:{accept:"application/vnd.github.v3.patch"}}))).data}var jD=async(e=Py())=>{let[t,s]=await ci("initialize",e,eC),p=!!(s==null?void 0:s.pullRequest);if(!t||!s)throw Error("Initialization failed.");let[c,i]=await ci("parseThreshold",e,()=>{var b;return RD((b=s.workingDirectory)!=null?b:process.cwd(),s.threshold)}),[d,a]=await ci("headCoverage",e,async()=>await _y(e,s,!1,s.coverageFile));a&&e.add(a);let[o]=await ci("switchToBase",e,async b=>{var _,C;let E=(C=(_=s==null?void 0:s.pullRequest)==null?void 0:_.base)==null?void 0:C.ref;(!p||!E||!!s.baseCoverageFile)&&b(),await rC(E)}),n=Py(),[,l]=await ci("baseCoverage",e,async b=>(!o&&!s.baseCoverageFile&&b(),await _y(n,s,!0,s.baseCoverageFile)));await ci("switchBack",e,async b=>{o||b(),await iC()}),l&&e.add(l);let[,g]=await ci("checkThreshold",e,async b=>((!d||!c)&&b(),X9(a,i,s.workingDirectory,e))),[h,m]=await ci("generateReportContent",e,async()=>PT(e,s,g!=null?g:[]));await ci("publishReport",e,async b=>{(!h||!s.output.includes("comment"))&&b();let E=(0,Ho.getOctokit)(s.token);p?await k3(m.text,s,Ho.context.repo,s.pullRequest,E):await O4(m.text,Ho.context.repo,E)}),await ci("setOutputs",e,b=>{(!h||!s.output.includes("report-markdown"))&&b(),s.output.includes("report-markdown")&&(0,im.setOutput)("report",m.text)}),await ci("failedTestsAnnotations",e,async b=>{(!d||!["all","failed-tests"].includes(s.annotations))&&b();let E=g4(a);E.length===0&&b(),await(0,Ho.getOctokit)(s.token).rest.checks.create(I4(m.runReport,E,s))}),await ci("coverageAnnotations",e,async b=>{var C;(!d||!["all","coverage"].includes(s.annotations))&&b();let E=c4(a);E.length===0&&b();let _=(0,Ho.getOctokit)(s.token);if((C=s.pullRequest)==null?void 0:C.number){let T=await FD(_,s);E=x4(E,T)}await _.rest.checks.create(A4(E,s))}),e.get().errors.length>0&&(0,im.setFailed)(gt("failed"))};jD(); +Default "index" lookups for the main are deprecated for ES modules.`,"DeprecationWarning","DEP0151")}function Jy(e){try{return(0,Os.statSync)(e)}catch(t){return new Os.Stats}}function wI(e,t,s){let p=lf.get(e);if(p!==void 0)return p;let c=sse.read(e).string;if(c===void 0){let h={pjsonPath:e,exists:!1,main:void 0,name:void 0,type:"none",exports:void 0,imports:void 0};return lf.set(e,h),h}let i;try{i=JSON.parse(c)}catch(h){throw new Xy(e,(s?`"${t}" from `:"")+(0,Qt.fileURLToPath)(s||t),h.message)}let{exports:d,imports:a,main:o,name:n,type:l}=i,g={pjsonPath:e,exists:!0,main:typeof o=="string"?o:void 0,name:typeof n=="string"?n:void 0,type:l==="module"||l==="commonjs"?l:"none",exports:d,imports:a&&typeof a=="object"?a:void 0};return lf.set(e,g),g}function Qy(e){let t=new URL("./package.json",e);for(;!t.pathname.endsWith("node_modules/package.json");){let i=wI((0,Qt.fileURLToPath)(t),e);if(i.exists)return i;let d=t;if(t=new URL("../package.json",t),t.pathname===d.pathname)break}let s=(0,Qt.fileURLToPath)(t),p={pjsonPath:s,exists:!1,main:void 0,name:void 0,type:"none",exports:void 0,imports:void 0};return lf.set(s,p),p}function Zy(e){return Jy((0,Qt.fileURLToPath)(e)).isFile()}function Tse(e,t,s){let p;if(t.main!==void 0){if(p=new URL(`./${t.main}`,e),Zy(p))return p;let d=[`./${t.main}.js`,`./${t.main}.json`,`./${t.main}.node`,`./${t.main}/index.js`,`./${t.main}/index.json`,`./${t.main}/index.node`],a=-1;for(;++a=0&&t<4294967295}function Ql(e,t,s,p,c,i,d,a){if(typeof t=="string")return Pse(t,s,p,e,c,i,d,a);if(Array.isArray(t)){let o=t;if(o.length===0)return null;let n,l=-1;for(;++l=n.length&&n.length>d.length||n[n.length-1]==="/"&&t.startsWith(n)&&n.length>d.length)&&(d=n)}if(d){let n=i[d],l=d[d.length-1]==="*",g=t.slice(d.length-(l?1:0)),h=Ql(e,n,g,d,p,l,!1,c);return h==null&&eg(t,e,p),l||TI(d,e,!0,p),{resolved:h,exact:l}}eg(t,e,p)}function Cse(e,t,s){if(e==="#"||e.startsWith("#/")){let i="is not a valid internal imports specifier name";throw new of(e,i,(0,Qt.fileURLToPath)(t))}let p,c=Qy(t);if(c.exists){p=(0,Qt.pathToFileURL)(c.pjsonPath);let i=c.imports;if(i)if(gI.call(i,e)){let d=Ql(p,i[e],"",e,t,!1,!0,s);if(d!==null)return{resolved:d,exact:!0}}else{let d="",a=Object.getOwnPropertyNames(i),o=-1;for(;++o=n.length&&n.length>d.length||n[n.length-1]==="/"&&e.startsWith(n)&&n.length>d.length)&&(d=n)}if(d){let n=i[d],l=d[d.length-1]==="*",g=e.slice(d.length-(l?1:0)),h=Ql(p,n,g,d,t,l,!0,s);if(h!==null)return l||TI(d,p,!1,t),{resolved:h,exact:l}}}}wse(e,p,t)}function Ise(e){return Qy(e).type}function Nse(e,t){let s=e.indexOf("/"),p=!0,c=!1;e[0]==="@"&&(c=!0,s===-1||e.length===0?p=!1:s=e.indexOf("/",s+1));let i=s===-1?e:e.slice(0,s),d=-1;for(;++dnew URL(Rse(a.toString())));p.length||p.push(Fse);let c=[...p];for(let a of p)a.protocol==="file:"&&(c.push(new URL("./",a)),c.push(new URL(uI(a.pathname,"_index.js"),a)),c.push(new URL("./node_modules",a)));let i;for(let a of c){if(i=xI(e,a,s),i)break;for(let o of["","/index"]){for(let n of t.extensions||jse)if(i=xI(e+o+n,a,s),i)break;if(i)break}}if(!i){let a=new Error(`Cannot find module ${e} imported from ${c.join(", ")}`);throw a.code="ERR_MODULE_NOT_FOUND",a}let d=(0,Os.realpathSync)(tg(i));return(0,Qt.pathToFileURL)(d).toString()}function Use(e,t){return Bse(e,t)}function Vse(e,t){return tg(Use(e,t))}function rg(e,t){return cI(Vse,e,t)}var $se={startingFrom:".",rootPattern:/^node_modules$/,reverse:!1,test:e=>{try{if((0,ig.statSync)(e).isFile())return!0}catch(t){}return null}};async function AI(e,t={}){let s=Tt(Tt({},$se),t),p=Ys(s.startingFrom),c=p[0]==="/",i=p.split("/").filter(Boolean);c&&(i[0]="/"+i[0]);let d=i.findIndex(a=>a.match(s.rootPattern));if(d===-1&&(d=0),s.reverse)for(let a=d+1;a<=i.length;a++){let o=Hh(...i.slice(0,a),e);if(await s.test(o))return o}else for(let a=i.length;a>d;a--){let o=Hh(...i.slice(0,a),e);if(await s.test(o))return o}throw new Error(`Cannot find matching ${e} in ${s.startingFrom} or parent directories`)}function CI(e,t={}){return AI(e,t)}var Gse=["yarn.lock","package-lock.json","pnpm-lock.yaml","npm-shrinkwrap.json"];async function qse(e=process.cwd(),t={}){let s=Js(e)?e:await rg(e,t),p=Tt({startingFrom:s},t);for(let c of Gse)try{return await CI(c,p)}catch(i){}throw new Error("No lockfile found from "+e)}async function II(e=process.cwd(),t={}){let s=Js(e)?e:await rg(e,t),p=Tt({startingFrom:s},t);try{let c=await CI(".git/config",p);return(0,Qp.resolve)(c,"../..")}catch(c){}try{let c=await qse(s,ar(Tt({},p),{reverse:!0}));return(0,Qp.dirname)(c)}catch(c){}try{let c=await AI(s,p);return(0,Qp.dirname)(c)}catch(c){}throw new Error("Cannot detect workspace root from "+e)}async function soe(e){var p,c,i;let t=(p=e.env)!=null?p:process.env,s=await noe({cwd:e.cwd,fileName:(c=e.fileName)!=null?c:".env",env:t,interpolate:(i=e.interpolate)!=null?i:!0});for(let d in s)!d.startsWith("_")&&t[d]===void 0&&(t[d]=s[d]);return s}async function noe(e){let t=Object.create(null),s=Ys(e.cwd,e.fileName);if((0,gu.existsSync)(s)){let p=PD.parse(await gu.promises.readFile(s,"utf-8"));Object.assign(t,p)}return e.env._applied||(Object.assign(t,e.env),t._applied=!0),e.interpolate&&aoe(t),t}function aoe(e,t={},s=p=>p){function p(i){return t[i]!==void 0?t[i]:e[i]}function c(i,d=[]){if(typeof i!="string")return i;let a=i.match(/(.?\${?(?:[a-zA-Z0-9_:]+)?}?)/g)||[];return s(a.reduce((o,n)=>{let l=/(.?)\${?([a-zA-Z0-9_:]+)?}?/g.exec(n),g=l[1],h,m;if(g==="\\")m=l[0],h=m.replace("\\$","$");else{let b=l[2];if(m=l[0].substring(g.length),d.includes(b))return console.warn(`Please avoid recursive environment variables ( loop: ${d.join(" > ")} > ${b} )`),"";h=p(b),h=c(h,[...d,b])}return h!==void 0?o.replace(m,h):o},i))}for(let i in e)e[i]=c(p(i))}async function CD(e){var d,a;e.cwd=Ys(process.cwd(),e.cwd||"."),e.name=e.name||"config",e.configFile=(d=e.configFile)!=null?d:e.name!=="config"?`${e.name}.config`:"config",e.rcFile=(a=e.rcFile)!=null?a:`.${e.name}rc`,e.extend!==!1&&(e.extend=Tt({extendKey:"extends"},e.extend)),e.jiti=e.jiti||(0,AD.default)(null,Tt({interopDefault:!0,requireCache:!1,esmResolve:!0},e.jitiOptions));let t={config:{},cwd:e.cwd,configFile:Ys(e.cwd,e.configFile),layers:[]};e.dotenv&&await soe(Tt({cwd:e.cwd},e.dotenv===!0?{}:e.dotenv));let{config:s,configFile:p}=await ND(".",e);p&&(t.configFile=p);let c={};if(e.rcFile){if(e.globalRc){Object.assign(c,PC({name:e.rcFile,dir:e.cwd}));let o=await II(e.cwd).catch(()=>null);o&&Object.assign(c,Xh({name:e.rcFile,dir:o}))}Object.assign(c,Xh({name:e.rcFile,dir:e.cwd}))}t.config=Gp(e.overrides,s,c,e.defaultConfig),e.extend&&(await ID(t.config,e),t.layers=t.config._layers,delete t.config._layers,t.config=Gp(t.config,...t.layers.map(o=>o.config)));let i=[e.overrides&&{config:e.overrides,configFile:void 0,cwd:void 0},{config:s,configFile:e.configFile,cwd:e.cwd},e.rcFile&&{config:c,configFile:e.rcFile}].filter(o=>o&&o.config);return t.layers=[...i,...t.layers],e.defaults&&(t.config=Gp(t.config,e.defaults)),t}async function ID(e,t){if(e._layers=e._layers||[],!t.extend)return;let s=t.extend.extendKey;typeof s=="string"&&(s=[s]);let p=[];for(let c of s)p.push(...(Array.isArray(e[c])?e[c]:[e[c]]).filter(Boolean)),delete e[c];for(let c of p){if(typeof c!="string"){console.warn(`Cannot extend config from \`${JSON.stringify(c)}\` (which should be a string) in ${t.cwd}`);continue}let i=await ND(c,t);if(!i.config){console.warn(`Cannot extend config from \`${c}\` in ${t.cwd}`);continue}await ID(i.config,ar(Tt({},t),{cwd:i.cwd})),e._layers.push(i),i.config._layers&&(e._layers.push(...i.config._layers),delete i.config._layers)}}var ooe=["github:","gitlab:","bitbucket:","https://"],loe=/^(@[a-z0-9-~][a-z0-9-._~]*\/)?[a-z0-9-~][a-z0-9-._~]*$/;async function ND(e,t){if(t.resolve){let i=await t.resolve(e,t);if(i)return i}if(ooe.some(i=>e.startsWith(i))){let i=new URL(e),d=i.pathname.split("/").slice(2).join("/"),a=i.protocol+i.pathname.split("/").slice(0,2).join("/"),o=Ys(xD.default.tmpdir(),"c12/",a.replace(/[#:@/\\]/g,"_"));await gu.promises.rm(o,{recursive:!0}).catch(()=>{});let n=await Promise.resolve().then(()=>Ft(_D())).then(g=>g.default||g),l=await n.fetch(a);await n.extract(l,o),e=Ys(o,d)}if(loe.test(e))try{e=t.jiti.resolve(e,{paths:[t.cwd]})}catch(i){}let s=!Wh(e),p=Ys(t.cwd,s?e:Ay(e));s&&(e=t.configFile);let c={config:null,cwd:p};try{c.configFile=t.jiti.resolve(Ys(p,e),{paths:[p]})}catch(i){}return(0,gu.existsSync)(c.configFile)&&(c.config=t.jiti(c.configFile),typeof c.config=="function"&&(c.config=await c.config())),c}var OD=async e=>{let{config:t}=await CD({cwd:e,name:"jest"});return t};var DD=async e=>{try{let t=await OD(e);return t==null?void 0:t.coverageThreshold}catch(t){console.log("[Warning] Failed to parse jest configuration.",'"coverageThreshold" from config file will be ignored.',t);return}};var RD=async(e,t)=>{let s=await DD(e);return(0,kD.default)(s)?{global:{branches:t,functions:t,lines:t,statements:t}}:s};var LD=Ft(Gn());async function FD(e,t){return(await e.rest.pulls.get(ar(Tt({},LD.context.repo),{pull_number:t.pullRequest.number,headers:{accept:"application/vnd.github.v3.patch"}}))).data}var jD=async(e=Py())=>{let[t,s]=await ci("initialize",e,eC),p=!!(s==null?void 0:s.pullRequest);if(!t||!s)throw Error("Initialization failed.");let[c,i]=await ci("parseThreshold",e,()=>{var b;return RD((b=s.workingDirectory)!=null?b:process.cwd(),s.threshold)}),[d,a]=await ci("headCoverage",e,async()=>await _y(e,s,!1,s.coverageFile));a&&e.add(a);let[o]=await ci("switchToBase",e,async b=>{var _,C;let E=(C=(_=s==null?void 0:s.pullRequest)==null?void 0:_.base)==null?void 0:C.ref;(!p||!E||!!s.baseCoverageFile)&&b(),await rC(E)}),n=Py(),[,l]=await ci("baseCoverage",e,async b=>(!o&&!s.baseCoverageFile&&b(),await _y(n,s,!0,s.baseCoverageFile)));await ci("switchBack",e,async b=>{o||b(),await iC()}),l&&e.add(l);let[,g]=await ci("checkThreshold",e,async b=>((!d||!c)&&b(),X9(a,i,s.workingDirectory,e))),[h,m]=await ci("generateReportContent",e,async()=>PT(e,s,g!=null?g:[]));await ci("publishReport",e,async b=>{(!h||!s.output.includes("comment"))&&b();let E=(0,Ho.getOctokit)(s.token);p?await k3(m.text,s,Ho.context.repo,s.pullRequest,E):await O4(m.text,Ho.context.repo,E)}),await ci("setOutputs",e,b=>{(!h||!s.output.includes("report-markdown"))&&b(),s.output.includes("report-markdown")&&(0,im.setOutput)("report",m.text)}),await ci("failedTestsAnnotations",e,async b=>{(!d||!["all","failed-tests"].includes(s.annotations))&&b();let E=g4(a);E.length===0&&b(),await(0,Ho.getOctokit)(s.token).rest.checks.create(I4(m.runReport,E,s))}),await ci("coverageAnnotations",e,async b=>{var C;(!d||!["all","coverage"].includes(s.annotations))&&b();let E=c4(a);E.length===0&&b();let _=(0,Ho.getOctokit)(s.token);if((C=s.pullRequest)==null?void 0:C.number){let T=await FD(_,s);E=x4(E,T)}await _.rest.checks.create(A4(E,s))}),e.get().errors.length>0&&(0,im.setFailed)(gt("failed"))};jD(); /*! * fill-range * diff --git a/dist/index.js.map b/dist/index.js.map index e8733040..f77a855c 100644 --- a/dist/index.js.map +++ b/dist/index.js.map @@ -1,7 +1,7 @@ { "version": 3, "sources": ["../node_modules/@actions/core/src/utils.ts", "../node_modules/@actions/core/src/command.ts", "../node_modules/@actions/core/src/file-command.ts", "../node_modules/uuid/dist/rng.js", "../node_modules/uuid/dist/regex.js", "../node_modules/uuid/dist/validate.js", "../node_modules/uuid/dist/stringify.js", "../node_modules/uuid/dist/v1.js", "../node_modules/uuid/dist/parse.js", "../node_modules/uuid/dist/v35.js", "../node_modules/uuid/dist/md5.js", "../node_modules/uuid/dist/v3.js", "../node_modules/uuid/dist/v4.js", "../node_modules/uuid/dist/sha1.js", "../node_modules/uuid/dist/v5.js", "../node_modules/uuid/dist/nil.js", "../node_modules/uuid/dist/version.js", "../node_modules/uuid/dist/index.js", "../node_modules/@actions/http-client/src/proxy.ts", "../node_modules/tunnel/lib/tunnel.js", "../node_modules/tunnel/index.js", "../node_modules/@actions/http-client/src/index.ts", "../node_modules/@actions/http-client/src/auth.ts", "../node_modules/@actions/core/src/oidc-utils.ts", "../node_modules/@actions/core/src/summary.ts", "../node_modules/@actions/core/src/path-utils.ts", "../node_modules/@actions/core/src/core.ts", "../node_modules/@actions/github/src/context.ts", "../node_modules/@actions/github/src/internal/utils.ts", "../node_modules/universal-user-agent/dist-src/index.js", "../node_modules/before-after-hook/lib/register.js", "../node_modules/before-after-hook/lib/add.js", "../node_modules/before-after-hook/lib/remove.js", "../node_modules/before-after-hook/index.js", "../node_modules/is-plain-object/dist/is-plain-object.js", "../node_modules/@octokit/endpoint/dist-src/util/lowercase-keys.js", "../node_modules/@octokit/endpoint/dist-src/util/merge-deep.js", "../node_modules/@octokit/endpoint/dist-src/util/remove-undefined-properties.js", "../node_modules/@octokit/endpoint/dist-src/merge.js", "../node_modules/@octokit/endpoint/dist-src/util/add-query-parameters.js", "../node_modules/@octokit/endpoint/dist-src/util/extract-url-variable-names.js", "../node_modules/@octokit/endpoint/dist-src/util/omit.js", "../node_modules/@octokit/endpoint/dist-src/util/url-template.js", "../node_modules/@octokit/endpoint/dist-src/parse.js", "../node_modules/@octokit/endpoint/dist-src/endpoint-with-defaults.js", "../node_modules/@octokit/endpoint/dist-src/with-defaults.js", "../node_modules/@octokit/endpoint/dist-src/version.js", "../node_modules/@octokit/endpoint/dist-src/defaults.js", "../node_modules/@octokit/endpoint/dist-src/index.js", "../node_modules/node-fetch/node_modules/webidl-conversions/lib/index.js", "../node_modules/node-fetch/node_modules/whatwg-url/lib/utils.js", "../node_modules/node-fetch/node_modules/tr46/index.js", "../node_modules/node-fetch/node_modules/whatwg-url/lib/url-state-machine.js", "../node_modules/node-fetch/node_modules/whatwg-url/lib/URL-impl.js", "../node_modules/node-fetch/node_modules/whatwg-url/lib/URL.js", "../node_modules/node-fetch/node_modules/whatwg-url/lib/public-api.js", "../node_modules/node-fetch/lib/index.js", "../node_modules/deprecation/dist-node/index.js", "../node_modules/wrappy/wrappy.js", "../node_modules/once/once.js", "../node_modules/@octokit/request-error/dist-src/index.js", "../node_modules/@octokit/request/dist-src/version.js", "../node_modules/@octokit/request/dist-src/get-buffer-response.js", "../node_modules/@octokit/request/dist-src/fetch-wrapper.js", "../node_modules/@octokit/request/dist-src/with-defaults.js", "../node_modules/@octokit/request/dist-src/index.js", "../node_modules/@octokit/graphql/dist-src/version.js", "../node_modules/@octokit/graphql/dist-src/error.js", "../node_modules/@octokit/graphql/dist-src/graphql.js", "../node_modules/@octokit/graphql/dist-src/with-defaults.js", "../node_modules/@octokit/graphql/dist-src/index.js", "../node_modules/@octokit/auth-token/dist-src/auth.js", "../node_modules/@octokit/auth-token/dist-src/with-authorization-prefix.js", "../node_modules/@octokit/auth-token/dist-src/hook.js", "../node_modules/@octokit/auth-token/dist-src/index.js", "../node_modules/@octokit/core/dist-src/version.js", "../node_modules/@octokit/core/dist-src/index.js", "../node_modules/@octokit/plugin-rest-endpoint-methods/dist-src/generated/endpoints.js", "../node_modules/@octokit/plugin-rest-endpoint-methods/dist-src/version.js", "../node_modules/@octokit/plugin-rest-endpoint-methods/dist-src/endpoints-to-methods.js", "../node_modules/@octokit/plugin-rest-endpoint-methods/dist-src/index.js", "../node_modules/@octokit/plugin-paginate-rest/dist-src/version.js", "../node_modules/@octokit/plugin-paginate-rest/dist-src/normalize-paginated-list-response.js", "../node_modules/@octokit/plugin-paginate-rest/dist-src/iterator.js", "../node_modules/@octokit/plugin-paginate-rest/dist-src/paginate.js", "../node_modules/@octokit/plugin-paginate-rest/dist-src/compose-paginate.js", "../node_modules/@octokit/plugin-paginate-rest/dist-src/generated/paginating-endpoints.js", "../node_modules/@octokit/plugin-paginate-rest/dist-src/paginating-endpoints.js", "../node_modules/@octokit/plugin-paginate-rest/dist-src/index.js", "../node_modules/@actions/github/src/utils.ts", "../node_modules/@actions/github/src/github.ts", "../node_modules/lodash/isArray.js", "../node_modules/lodash/_freeGlobal.js", "../node_modules/lodash/_root.js", "../node_modules/lodash/_Symbol.js", "../node_modules/lodash/_getRawTag.js", "../node_modules/lodash/_objectToString.js", "../node_modules/lodash/_baseGetTag.js", "../node_modules/lodash/isObjectLike.js", "../node_modules/lodash/isSymbol.js", "../node_modules/lodash/_isKey.js", "../node_modules/lodash/isObject.js", "../node_modules/lodash/isFunction.js", "../node_modules/lodash/_coreJsData.js", "../node_modules/lodash/_isMasked.js", "../node_modules/lodash/_toSource.js", "../node_modules/lodash/_baseIsNative.js", "../node_modules/lodash/_getValue.js", "../node_modules/lodash/_getNative.js", "../node_modules/lodash/_nativeCreate.js", "../node_modules/lodash/_hashClear.js", "../node_modules/lodash/_hashDelete.js", "../node_modules/lodash/_hashGet.js", "../node_modules/lodash/_hashHas.js", "../node_modules/lodash/_hashSet.js", "../node_modules/lodash/_Hash.js", "../node_modules/lodash/_listCacheClear.js", "../node_modules/lodash/eq.js", "../node_modules/lodash/_assocIndexOf.js", "../node_modules/lodash/_listCacheDelete.js", "../node_modules/lodash/_listCacheGet.js", "../node_modules/lodash/_listCacheHas.js", "../node_modules/lodash/_listCacheSet.js", "../node_modules/lodash/_ListCache.js", "../node_modules/lodash/_Map.js", "../node_modules/lodash/_mapCacheClear.js", "../node_modules/lodash/_isKeyable.js", "../node_modules/lodash/_getMapData.js", "../node_modules/lodash/_mapCacheDelete.js", "../node_modules/lodash/_mapCacheGet.js", "../node_modules/lodash/_mapCacheHas.js", "../node_modules/lodash/_mapCacheSet.js", "../node_modules/lodash/_MapCache.js", "../node_modules/lodash/memoize.js", "../node_modules/lodash/_memoizeCapped.js", "../node_modules/lodash/_stringToPath.js", "../node_modules/lodash/_arrayMap.js", "../node_modules/lodash/_baseToString.js", "../node_modules/lodash/toString.js", "../node_modules/lodash/_castPath.js", "../node_modules/lodash/_toKey.js", "../node_modules/lodash/_baseGet.js", "../node_modules/lodash/get.js", "../node_modules/ansi-regex/index.js", "../node_modules/strip-ansi/index.js", "../node_modules/parse-diff/index.js", "../node_modules/lodash/_defineProperty.js", "../node_modules/lodash/_baseAssignValue.js", "../node_modules/lodash/_assignValue.js", "../node_modules/lodash/_isIndex.js", "../node_modules/lodash/_baseSet.js", "../node_modules/lodash/_basePickBy.js", "../node_modules/lodash/_baseHasIn.js", "../node_modules/lodash/_baseIsArguments.js", "../node_modules/lodash/isArguments.js", "../node_modules/lodash/isLength.js", "../node_modules/lodash/_hasPath.js", "../node_modules/lodash/hasIn.js", "../node_modules/lodash/_basePick.js", "../node_modules/lodash/_arrayPush.js", "../node_modules/lodash/_isFlattenable.js", "../node_modules/lodash/_baseFlatten.js", "../node_modules/lodash/flatten.js", "../node_modules/lodash/_apply.js", "../node_modules/lodash/_overRest.js", "../node_modules/lodash/constant.js", "../node_modules/lodash/identity.js", "../node_modules/lodash/_baseSetToString.js", "../node_modules/lodash/_shortOut.js", "../node_modules/lodash/_setToString.js", "../node_modules/lodash/_flatRest.js", "../node_modules/lodash/pick.js", "../node_modules/lodash/isNil.js", "../node_modules/braces/lib/utils.js", "../node_modules/braces/lib/stringify.js", "../node_modules/is-number/index.js", "../node_modules/to-regex-range/index.js", "../node_modules/fill-range/index.js", "../node_modules/braces/lib/compile.js", "../node_modules/braces/lib/expand.js", "../node_modules/braces/lib/constants.js", "../node_modules/braces/lib/parse.js", "../node_modules/braces/index.js", "../node_modules/picomatch/lib/constants.js", "../node_modules/picomatch/lib/utils.js", "../node_modules/picomatch/lib/scan.js", "../node_modules/picomatch/lib/parse.js", "../node_modules/picomatch/lib/picomatch.js", "../node_modules/picomatch/index.js", "../node_modules/micromatch/index.js", "../node_modules/repeat-string/index.js", "../node_modules/markdown-table/index.js", "../node_modules/universalify/index.js", "../node_modules/graceful-fs/polyfills.js", "../node_modules/graceful-fs/legacy-streams.js", "../node_modules/graceful-fs/clone.js", "../node_modules/graceful-fs/graceful-fs.js", "../node_modules/fs-extra/lib/fs/index.js", "../node_modules/fs-extra/lib/mkdirs/utils.js", "../node_modules/fs-extra/lib/mkdirs/make-dir.js", "../node_modules/fs-extra/lib/mkdirs/index.js", "../node_modules/fs-extra/lib/util/utimes.js", "../node_modules/fs-extra/lib/util/stat.js", "../node_modules/fs-extra/lib/copy-sync/copy-sync.js", "../node_modules/fs-extra/lib/copy-sync/index.js", "../node_modules/fs-extra/lib/path-exists/index.js", "../node_modules/fs-extra/lib/copy/copy.js", "../node_modules/fs-extra/lib/copy/index.js", "../node_modules/fs-extra/lib/remove/rimraf.js", "../node_modules/fs-extra/lib/remove/index.js", "../node_modules/fs-extra/lib/empty/index.js", "../node_modules/fs-extra/lib/ensure/file.js", "../node_modules/fs-extra/lib/ensure/link.js", "../node_modules/fs-extra/lib/ensure/symlink-paths.js", "../node_modules/fs-extra/lib/ensure/symlink-type.js", "../node_modules/fs-extra/lib/ensure/symlink.js", "../node_modules/fs-extra/lib/ensure/index.js", "../node_modules/jsonfile/utils.js", "../node_modules/jsonfile/index.js", "../node_modules/fs-extra/lib/json/jsonfile.js", "../node_modules/fs-extra/lib/output/index.js", "../node_modules/fs-extra/lib/json/output-json.js", "../node_modules/fs-extra/lib/json/output-json-sync.js", "../node_modules/fs-extra/lib/json/index.js", "../node_modules/fs-extra/lib/move-sync/move-sync.js", "../node_modules/fs-extra/lib/move-sync/index.js", "../node_modules/fs-extra/lib/move/move.js", "../node_modules/fs-extra/lib/move/index.js", "../node_modules/fs-extra/lib/index.js", "../node_modules/@actions/io/src/io-util.ts", "../node_modules/@actions/io/src/io.ts", "../node_modules/@actions/exec/src/toolrunner.ts", "../node_modules/@actions/exec/src/exec.ts", "../node_modules/semver/internal/constants.js", "../node_modules/semver/internal/debug.js", "../node_modules/semver/internal/re.js", "../node_modules/semver/internal/parse-options.js", "../node_modules/semver/internal/identifiers.js", "../node_modules/semver/classes/semver.js", "../node_modules/semver/functions/parse.js", "../node_modules/semver/functions/valid.js", "../node_modules/semver/functions/clean.js", "../node_modules/semver/functions/inc.js", "../node_modules/semver/functions/compare.js", "../node_modules/semver/functions/eq.js", "../node_modules/semver/functions/diff.js", "../node_modules/semver/functions/major.js", "../node_modules/semver/functions/minor.js", "../node_modules/semver/functions/patch.js", "../node_modules/semver/functions/prerelease.js", "../node_modules/semver/functions/rcompare.js", "../node_modules/semver/functions/compare-loose.js", "../node_modules/semver/functions/compare-build.js", "../node_modules/semver/functions/sort.js", "../node_modules/semver/functions/rsort.js", "../node_modules/semver/functions/gt.js", "../node_modules/semver/functions/lt.js", "../node_modules/semver/functions/neq.js", "../node_modules/semver/functions/gte.js", "../node_modules/semver/functions/lte.js", "../node_modules/semver/functions/cmp.js", "../node_modules/semver/functions/coerce.js", "../node_modules/yallist/iterator.js", "../node_modules/yallist/yallist.js", "../node_modules/lru-cache/index.js", "../node_modules/semver/classes/range.js", "../node_modules/semver/classes/comparator.js", "../node_modules/semver/functions/satisfies.js", "../node_modules/semver/ranges/to-comparators.js", "../node_modules/semver/ranges/max-satisfying.js", "../node_modules/semver/ranges/min-satisfying.js", "../node_modules/semver/ranges/min-version.js", "../node_modules/semver/ranges/valid.js", "../node_modules/semver/ranges/outside.js", "../node_modules/semver/ranges/gtr.js", "../node_modules/semver/ranges/ltr.js", "../node_modules/semver/ranges/intersects.js", "../node_modules/semver/ranges/simplify.js", "../node_modules/semver/ranges/subset.js", "../node_modules/semver/index.js", "../node_modules/nanoclone/index.js", "../node_modules/yup/lib/util/printValue.js", "../node_modules/yup/lib/locale.js", "../node_modules/lodash/_baseHas.js", "../node_modules/lodash/has.js", "../node_modules/yup/lib/util/isSchema.js", "../node_modules/yup/lib/Condition.js", "../node_modules/yup/lib/util/toArray.js", "../node_modules/yup/lib/ValidationError.js", "../node_modules/yup/lib/util/runTests.js", "../node_modules/lodash/_createBaseFor.js", "../node_modules/lodash/_baseFor.js", "../node_modules/lodash/_baseTimes.js", "../node_modules/lodash/stubFalse.js", "../node_modules/lodash/isBuffer.js", "../node_modules/lodash/_baseIsTypedArray.js", "../node_modules/lodash/_baseUnary.js", "../node_modules/lodash/_nodeUtil.js", "../node_modules/lodash/isTypedArray.js", "../node_modules/lodash/_arrayLikeKeys.js", "../node_modules/lodash/_isPrototype.js", "../node_modules/lodash/_overArg.js", "../node_modules/lodash/_nativeKeys.js", "../node_modules/lodash/_baseKeys.js", "../node_modules/lodash/isArrayLike.js", "../node_modules/lodash/keys.js", "../node_modules/lodash/_baseForOwn.js", "../node_modules/lodash/_stackClear.js", "../node_modules/lodash/_stackDelete.js", "../node_modules/lodash/_stackGet.js", "../node_modules/lodash/_stackHas.js", "../node_modules/lodash/_stackSet.js", "../node_modules/lodash/_Stack.js", "../node_modules/lodash/_setCacheAdd.js", "../node_modules/lodash/_setCacheHas.js", "../node_modules/lodash/_SetCache.js", "../node_modules/lodash/_arraySome.js", "../node_modules/lodash/_cacheHas.js", "../node_modules/lodash/_equalArrays.js", "../node_modules/lodash/_Uint8Array.js", "../node_modules/lodash/_mapToArray.js", "../node_modules/lodash/_setToArray.js", "../node_modules/lodash/_equalByTag.js", "../node_modules/lodash/_baseGetAllKeys.js", "../node_modules/lodash/_arrayFilter.js", "../node_modules/lodash/stubArray.js", "../node_modules/lodash/_getSymbols.js", "../node_modules/lodash/_getAllKeys.js", "../node_modules/lodash/_equalObjects.js", "../node_modules/lodash/_DataView.js", "../node_modules/lodash/_Promise.js", "../node_modules/lodash/_Set.js", "../node_modules/lodash/_WeakMap.js", "../node_modules/lodash/_getTag.js", "../node_modules/lodash/_baseIsEqualDeep.js", "../node_modules/lodash/_baseIsEqual.js", "../node_modules/lodash/_baseIsMatch.js", "../node_modules/lodash/_isStrictComparable.js", "../node_modules/lodash/_getMatchData.js", "../node_modules/lodash/_matchesStrictComparable.js", "../node_modules/lodash/_baseMatches.js", "../node_modules/lodash/_baseMatchesProperty.js", "../node_modules/lodash/_baseProperty.js", "../node_modules/lodash/_basePropertyDeep.js", "../node_modules/lodash/property.js", "../node_modules/lodash/_baseIteratee.js", "../node_modules/lodash/mapValues.js", "../node_modules/property-expr/index.js", "../node_modules/yup/lib/Reference.js", "../node_modules/yup/lib/util/createValidation.js", "../node_modules/yup/lib/util/reach.js", "../node_modules/yup/lib/util/ReferenceSet.js", "../node_modules/yup/lib/schema.js", "../node_modules/yup/lib/mixed.js", "../node_modules/yup/lib/util/isAbsent.js", "../node_modules/yup/lib/boolean.js", "../node_modules/yup/lib/string.js", "../node_modules/yup/lib/number.js", "../node_modules/yup/lib/util/isodate.js", "../node_modules/yup/lib/date.js", "../node_modules/lodash/_arrayReduce.js", "../node_modules/lodash/_basePropertyOf.js", "../node_modules/lodash/_deburrLetter.js", "../node_modules/lodash/deburr.js", "../node_modules/lodash/_asciiWords.js", "../node_modules/lodash/_hasUnicodeWord.js", "../node_modules/lodash/_unicodeWords.js", "../node_modules/lodash/words.js", "../node_modules/lodash/_createCompounder.js", "../node_modules/lodash/snakeCase.js", "../node_modules/lodash/_baseSlice.js", "../node_modules/lodash/_castSlice.js", "../node_modules/lodash/_hasUnicode.js", "../node_modules/lodash/_asciiToArray.js", "../node_modules/lodash/_unicodeToArray.js", "../node_modules/lodash/_stringToArray.js", "../node_modules/lodash/_createCaseFirst.js", "../node_modules/lodash/upperFirst.js", "../node_modules/lodash/capitalize.js", "../node_modules/lodash/camelCase.js", "../node_modules/lodash/mapKeys.js", "../node_modules/toposort/index.js", "../node_modules/yup/lib/util/sortFields.js", "../node_modules/yup/lib/util/sortByKeyOrder.js", "../node_modules/yup/lib/object.js", "../node_modules/yup/lib/array.js", "../node_modules/yup/lib/Lazy.js", "../node_modules/yup/lib/setLocale.js", "../node_modules/yup/lib/index.js", "../node_modules/dotenv/lib/main.js", "../node_modules/jiti/dist/jiti.js", "../node_modules/jiti/dist/babel.js", "../node_modules/jiti/lib/index.js", "../node_modules/flat/index.js", "../node_modules/tar/lib/high-level-opt.js", "../node_modules/tar/node_modules/safe-buffer/index.js", "../node_modules/tar/lib/buffer.js", "../node_modules/minipass/node_modules/yallist/iterator.js", "../node_modules/minipass/node_modules/yallist/yallist.js", "../node_modules/safe-buffer/index.js", "../node_modules/minipass/index.js", "../node_modules/minizlib/constants.js", "../node_modules/minizlib/index.js", "../node_modules/tar/lib/types.js", "../node_modules/tar/lib/normalize-windows-path.js", "../node_modules/tar/lib/read-entry.js", "../node_modules/tar/lib/large-numbers.js", "../node_modules/tar/lib/header.js", "../node_modules/tar/lib/pax.js", "../node_modules/tar/lib/strip-trailing-slashes.js", "../node_modules/tar/lib/warn-mixin.js", "../node_modules/tar/lib/winchars.js", "../node_modules/tar/lib/strip-absolute-path.js", "../node_modules/tar/lib/mode-fix.js", "../node_modules/tar/lib/write-entry.js", "../node_modules/tar/node_modules/yallist/iterator.js", "../node_modules/tar/node_modules/yallist/yallist.js", "../node_modules/tar/lib/pack.js", "../node_modules/fs-minipass/index.js", "../node_modules/tar/lib/parse.js", "../node_modules/tar/lib/list.js", "../node_modules/tar/lib/create.js", "../node_modules/tar/lib/replace.js", "../node_modules/tar/lib/update.js", "../node_modules/mkdirp/index.js", "../node_modules/chownr/chownr.js", "../node_modules/tar/lib/mkdir.js", "../node_modules/tar/lib/path-reservations.js", "../node_modules/tar/lib/unpack.js", "../node_modules/tar/lib/extract.js", "../node_modules/tar/index.js", "../node_modules/gittar/lib/index.js", "../src/run.ts", "../src/annotations/createCoverageAnnotations.ts", "../src/utils/i18n.ts", "../src/utils/insertArgs.ts", "../src/utils/isValidNumber.ts", "../src/annotations/createFailedTestsAnnotations.ts", "../src/filters/onlyChanged.ts", "../src/format/annotations/formatCoverageAnnotations.ts", "../src/format/annotations/formatFailedTestsAnnotations.ts", "../src/format/annotations/getFailedTestsAnnotationsBody.ts", "../src/report/generateCommitReport.ts", "../src/constants/getReportTag.ts", "../src/report/fetchPreviousReport.ts", "../src/report/generatePRReport.ts", "../src/stages/checkThreshold.ts", "../src/typings/Report.ts", "../src/utils/accumulateCoverageDetails.ts", "../src/utils/checkSingleThreshold.ts", "../src/format/getPercents.ts", "../src/typings/ThresholdResult.ts", "../src/utils/getCoverageForDirectory.ts", "../src/format/counters.ts", "../src/utils/getFileCoverageMap.ts", "../src/utils/joinPaths.ts", "../src/stages/createReport.ts", "../src/constants/GITHUB_MESSAGE_SIZE_LIMIT.ts", "../src/format/details/findCommonPath.ts", "../src/format/details/parseDetails.ts", "../src/format/summary/getSummary.ts", "../src/format/summary/parseSummary.ts", "../src/format/details/formatCoverageDetailsPart.ts", "../src/format/details/shrinkLongPath.ts", "../src/utils/decimalToString.ts", "../src/utils/formatPercentageDelta.ts", "../src/utils/formatPercentage.ts", "../src/utils/getStatusOfPercents.ts", "../src/format/details/getFileCoverageDetailRow.ts", "../src/utils/createMarkdownSpoiler.ts", "../src/utils/withExplanation.ts", "../src/format/details/getDecreasedCoverage.ts", "../src/format/details/getNewFilesCoverage.ts", "../src/format/details/formatCoverageDetails.ts", "../src/format/summary/formatCoverageSummary.ts", "../src/format/getFormattedCoverage.ts", "../src/format/formatCoverage.ts", "../src/typings/ActionError.ts", "../src/utils/getConsoleLink.ts", "../src/format/formatErrors.ts", "../src/format/formatRunReport.ts", "../src/format/formatThresholdResults.ts", "../src/format/getFailureDetails.ts", "../src/format/summary/getTestRunSummary.ts", "../src/stages/collectCoverage.ts", "../src/constants/REPORT_PATH.ts", "../src/stages/installDependencies.ts", "../src/utils/removeDirectory.ts", "../src/stages/parseCoverage.ts", "../src/stages/runTest.ts", "../src/utils/isOldScript.ts", "../src/utils/getTestCommand.ts", "../src/typings/Options.ts", "../src/utils/runStage.ts", "../src/stages/getCoverage.ts", "../src/stages/switchBranch.ts", "../src/utils/DataCollector.ts", "../src/utils/getNormalThreshold.ts", "../node_modules/c12/dist/index.mjs", "../node_modules/pathe/dist/shared/pathe.f81973bb.mjs", "../node_modules/rc9/dist/index.mjs", "../node_modules/destr/dist/index.mjs", "../node_modules/defu/dist/defu.mjs", "../node_modules/pkg-types/dist/index.mjs", "../node_modules/acorn/dist/acorn.mjs", "../node_modules/mlly/dist/index.mjs", "../node_modules/ufo/dist/index.mjs", "../src/utils/parseJestConfig.ts", "../src/utils/tryGetJestThreshold.ts", "../src/utils/getPrPatch.ts", "../src/index.ts"], - "sourcesContent": [null, null, null, "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = rng;\n\nvar _crypto = _interopRequireDefault(require(\"crypto\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nconst rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate\n\nlet poolPtr = rnds8Pool.length;\n\nfunction rng() {\n if (poolPtr > rnds8Pool.length - 16) {\n _crypto.default.randomFillSync(rnds8Pool);\n\n poolPtr = 0;\n }\n\n return rnds8Pool.slice(poolPtr, poolPtr += 16);\n}", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _default = /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _regex = _interopRequireDefault(require(\"./regex.js\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction validate(uuid) {\n return typeof uuid === 'string' && _regex.default.test(uuid);\n}\n\nvar _default = validate;\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _validate = _interopRequireDefault(require(\"./validate.js\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\n/**\n * Convert array of 16 byte values to UUID string format of the form:\n * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX\n */\nconst byteToHex = [];\n\nfor (let i = 0; i < 256; ++i) {\n byteToHex.push((i + 0x100).toString(16).substr(1));\n}\n\nfunction stringify(arr, offset = 0) {\n // Note: Be careful editing this code! It's been tuned for performance\n // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434\n const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one\n // of the following:\n // - One or more input array values don't map to a hex octet (leading to\n // \"undefined\" in the uuid)\n // - Invalid input values for the RFC `version` or `variant` fields\n\n if (!(0, _validate.default)(uuid)) {\n throw TypeError('Stringified UUID is invalid');\n }\n\n return uuid;\n}\n\nvar _default = stringify;\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _rng = _interopRequireDefault(require(\"./rng.js\"));\n\nvar _stringify = _interopRequireDefault(require(\"./stringify.js\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\n// **`v1()` - Generate time-based UUID**\n//\n// Inspired by https://github.com/LiosK/UUID.js\n// and http://docs.python.org/library/uuid.html\nlet _nodeId;\n\nlet _clockseq; // Previous uuid creation time\n\n\nlet _lastMSecs = 0;\nlet _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details\n\nfunction v1(options, buf, offset) {\n let i = buf && offset || 0;\n const b = buf || new Array(16);\n options = options || {};\n let node = options.node || _nodeId;\n let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not\n // specified. We do this lazily to minimize issues related to insufficient\n // system entropy. See #189\n\n if (node == null || clockseq == null) {\n const seedBytes = options.random || (options.rng || _rng.default)();\n\n if (node == null) {\n // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1)\n node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]];\n }\n\n if (clockseq == null) {\n // Per 4.2.2, randomize (14 bit) clockseq\n clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff;\n }\n } // UUID timestamps are 100 nano-second units since the Gregorian epoch,\n // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so\n // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs'\n // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00.\n\n\n let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock\n // cycle to simulate higher resolution clock\n\n let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs)\n\n const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression\n\n if (dt < 0 && options.clockseq === undefined) {\n clockseq = clockseq + 1 & 0x3fff;\n } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new\n // time interval\n\n\n if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) {\n nsecs = 0;\n } // Per 4.2.1.2 Throw error if too many uuids are requested\n\n\n if (nsecs >= 10000) {\n throw new Error(\"uuid.v1(): Can't create more than 10M uuids/sec\");\n }\n\n _lastMSecs = msecs;\n _lastNSecs = nsecs;\n _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch\n\n msecs += 12219292800000; // `time_low`\n\n const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000;\n b[i++] = tl >>> 24 & 0xff;\n b[i++] = tl >>> 16 & 0xff;\n b[i++] = tl >>> 8 & 0xff;\n b[i++] = tl & 0xff; // `time_mid`\n\n const tmh = msecs / 0x100000000 * 10000 & 0xfffffff;\n b[i++] = tmh >>> 8 & 0xff;\n b[i++] = tmh & 0xff; // `time_high_and_version`\n\n b[i++] = tmh >>> 24 & 0xf | 0x10; // include version\n\n b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant)\n\n b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low`\n\n b[i++] = clockseq & 0xff; // `node`\n\n for (let n = 0; n < 6; ++n) {\n b[i + n] = node[n];\n }\n\n return buf || (0, _stringify.default)(b);\n}\n\nvar _default = v1;\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _validate = _interopRequireDefault(require(\"./validate.js\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction parse(uuid) {\n if (!(0, _validate.default)(uuid)) {\n throw TypeError('Invalid UUID');\n }\n\n let v;\n const arr = new Uint8Array(16); // Parse ########-....-....-....-............\n\n arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24;\n arr[1] = v >>> 16 & 0xff;\n arr[2] = v >>> 8 & 0xff;\n arr[3] = v & 0xff; // Parse ........-####-....-....-............\n\n arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8;\n arr[5] = v & 0xff; // Parse ........-....-####-....-............\n\n arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8;\n arr[7] = v & 0xff; // Parse ........-....-....-####-............\n\n arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8;\n arr[9] = v & 0xff; // Parse ........-....-....-....-############\n // (Use \"/\" to avoid 32-bit truncation when bit-shifting high-order bytes)\n\n arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff;\n arr[11] = v / 0x100000000 & 0xff;\n arr[12] = v >>> 24 & 0xff;\n arr[13] = v >>> 16 & 0xff;\n arr[14] = v >>> 8 & 0xff;\n arr[15] = v & 0xff;\n return arr;\n}\n\nvar _default = parse;\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = _default;\nexports.URL = exports.DNS = void 0;\n\nvar _stringify = _interopRequireDefault(require(\"./stringify.js\"));\n\nvar _parse = _interopRequireDefault(require(\"./parse.js\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction stringToBytes(str) {\n str = unescape(encodeURIComponent(str)); // UTF8 escape\n\n const bytes = [];\n\n for (let i = 0; i < str.length; ++i) {\n bytes.push(str.charCodeAt(i));\n }\n\n return bytes;\n}\n\nconst DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8';\nexports.DNS = DNS;\nconst URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8';\nexports.URL = URL;\n\nfunction _default(name, version, hashfunc) {\n function generateUUID(value, namespace, buf, offset) {\n if (typeof value === 'string') {\n value = stringToBytes(value);\n }\n\n if (typeof namespace === 'string') {\n namespace = (0, _parse.default)(namespace);\n }\n\n if (namespace.length !== 16) {\n throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)');\n } // Compute hash of namespace and value, Per 4.3\n // Future: Use spread syntax when supported on all platforms, e.g. `bytes =\n // hashfunc([...namespace, ... value])`\n\n\n let bytes = new Uint8Array(16 + value.length);\n bytes.set(namespace);\n bytes.set(value, namespace.length);\n bytes = hashfunc(bytes);\n bytes[6] = bytes[6] & 0x0f | version;\n bytes[8] = bytes[8] & 0x3f | 0x80;\n\n if (buf) {\n offset = offset || 0;\n\n for (let i = 0; i < 16; ++i) {\n buf[offset + i] = bytes[i];\n }\n\n return buf;\n }\n\n return (0, _stringify.default)(bytes);\n } // Function#name is not settable on some platforms (#270)\n\n\n try {\n generateUUID.name = name; // eslint-disable-next-line no-empty\n } catch (err) {} // For CommonJS default export support\n\n\n generateUUID.DNS = DNS;\n generateUUID.URL = URL;\n return generateUUID;\n}", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _crypto = _interopRequireDefault(require(\"crypto\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction md5(bytes) {\n if (Array.isArray(bytes)) {\n bytes = Buffer.from(bytes);\n } else if (typeof bytes === 'string') {\n bytes = Buffer.from(bytes, 'utf8');\n }\n\n return _crypto.default.createHash('md5').update(bytes).digest();\n}\n\nvar _default = md5;\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _v = _interopRequireDefault(require(\"./v35.js\"));\n\nvar _md = _interopRequireDefault(require(\"./md5.js\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nconst v3 = (0, _v.default)('v3', 0x30, _md.default);\nvar _default = v3;\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _rng = _interopRequireDefault(require(\"./rng.js\"));\n\nvar _stringify = _interopRequireDefault(require(\"./stringify.js\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction v4(options, buf, offset) {\n options = options || {};\n\n const rnds = options.random || (options.rng || _rng.default)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved`\n\n\n rnds[6] = rnds[6] & 0x0f | 0x40;\n rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided\n\n if (buf) {\n offset = offset || 0;\n\n for (let i = 0; i < 16; ++i) {\n buf[offset + i] = rnds[i];\n }\n\n return buf;\n }\n\n return (0, _stringify.default)(rnds);\n}\n\nvar _default = v4;\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _crypto = _interopRequireDefault(require(\"crypto\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction sha1(bytes) {\n if (Array.isArray(bytes)) {\n bytes = Buffer.from(bytes);\n } else if (typeof bytes === 'string') {\n bytes = Buffer.from(bytes, 'utf8');\n }\n\n return _crypto.default.createHash('sha1').update(bytes).digest();\n}\n\nvar _default = sha1;\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _v = _interopRequireDefault(require(\"./v35.js\"));\n\nvar _sha = _interopRequireDefault(require(\"./sha1.js\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nconst v5 = (0, _v.default)('v5', 0x50, _sha.default);\nvar _default = v5;\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _default = '00000000-0000-0000-0000-000000000000';\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _validate = _interopRequireDefault(require(\"./validate.js\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction version(uuid) {\n if (!(0, _validate.default)(uuid)) {\n throw TypeError('Invalid UUID');\n }\n\n return parseInt(uuid.substr(14, 1), 16);\n}\n\nvar _default = version;\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"v1\", {\n enumerable: true,\n get: function () {\n return _v.default;\n }\n});\nObject.defineProperty(exports, \"v3\", {\n enumerable: true,\n get: function () {\n return _v2.default;\n }\n});\nObject.defineProperty(exports, \"v4\", {\n enumerable: true,\n get: function () {\n return _v3.default;\n }\n});\nObject.defineProperty(exports, \"v5\", {\n enumerable: true,\n get: function () {\n return _v4.default;\n }\n});\nObject.defineProperty(exports, \"NIL\", {\n enumerable: true,\n get: function () {\n return _nil.default;\n }\n});\nObject.defineProperty(exports, \"version\", {\n enumerable: true,\n get: function () {\n return _version.default;\n }\n});\nObject.defineProperty(exports, \"validate\", {\n enumerable: true,\n get: function () {\n return _validate.default;\n }\n});\nObject.defineProperty(exports, \"stringify\", {\n enumerable: true,\n get: function () {\n return _stringify.default;\n }\n});\nObject.defineProperty(exports, \"parse\", {\n enumerable: true,\n get: function () {\n return _parse.default;\n }\n});\n\nvar _v = _interopRequireDefault(require(\"./v1.js\"));\n\nvar _v2 = _interopRequireDefault(require(\"./v3.js\"));\n\nvar _v3 = _interopRequireDefault(require(\"./v4.js\"));\n\nvar _v4 = _interopRequireDefault(require(\"./v5.js\"));\n\nvar _nil = _interopRequireDefault(require(\"./nil.js\"));\n\nvar _version = _interopRequireDefault(require(\"./version.js\"));\n\nvar _validate = _interopRequireDefault(require(\"./validate.js\"));\n\nvar _stringify = _interopRequireDefault(require(\"./stringify.js\"));\n\nvar _parse = _interopRequireDefault(require(\"./parse.js\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }", null, "'use strict';\n\nvar net = require('net');\nvar tls = require('tls');\nvar http = require('http');\nvar https = require('https');\nvar events = require('events');\nvar assert = require('assert');\nvar util = require('util');\n\n\nexports.httpOverHttp = httpOverHttp;\nexports.httpsOverHttp = httpsOverHttp;\nexports.httpOverHttps = httpOverHttps;\nexports.httpsOverHttps = httpsOverHttps;\n\n\nfunction httpOverHttp(options) {\n var agent = new TunnelingAgent(options);\n agent.request = http.request;\n return agent;\n}\n\nfunction httpsOverHttp(options) {\n var agent = new TunnelingAgent(options);\n agent.request = http.request;\n agent.createSocket = createSecureSocket;\n agent.defaultPort = 443;\n return agent;\n}\n\nfunction httpOverHttps(options) {\n var agent = new TunnelingAgent(options);\n agent.request = https.request;\n return agent;\n}\n\nfunction httpsOverHttps(options) {\n var agent = new TunnelingAgent(options);\n agent.request = https.request;\n agent.createSocket = createSecureSocket;\n agent.defaultPort = 443;\n return agent;\n}\n\n\nfunction TunnelingAgent(options) {\n var self = this;\n self.options = options || {};\n self.proxyOptions = self.options.proxy || {};\n self.maxSockets = self.options.maxSockets || http.Agent.defaultMaxSockets;\n self.requests = [];\n self.sockets = [];\n\n self.on('free', function onFree(socket, host, port, localAddress) {\n var options = toOptions(host, port, localAddress);\n for (var i = 0, len = self.requests.length; i < len; ++i) {\n var pending = self.requests[i];\n if (pending.host === options.host && pending.port === options.port) {\n // Detect the request to connect same origin server,\n // reuse the connection.\n self.requests.splice(i, 1);\n pending.request.onSocket(socket);\n return;\n }\n }\n socket.destroy();\n self.removeSocket(socket);\n });\n}\nutil.inherits(TunnelingAgent, events.EventEmitter);\n\nTunnelingAgent.prototype.addRequest = function addRequest(req, host, port, localAddress) {\n var self = this;\n var options = mergeOptions({request: req}, self.options, toOptions(host, port, localAddress));\n\n if (self.sockets.length >= this.maxSockets) {\n // We are over limit so we'll add it to the queue.\n self.requests.push(options);\n return;\n }\n\n // If we are under maxSockets create a new one.\n self.createSocket(options, function(socket) {\n socket.on('free', onFree);\n socket.on('close', onCloseOrRemove);\n socket.on('agentRemove', onCloseOrRemove);\n req.onSocket(socket);\n\n function onFree() {\n self.emit('free', socket, options);\n }\n\n function onCloseOrRemove(err) {\n self.removeSocket(socket);\n socket.removeListener('free', onFree);\n socket.removeListener('close', onCloseOrRemove);\n socket.removeListener('agentRemove', onCloseOrRemove);\n }\n });\n};\n\nTunnelingAgent.prototype.createSocket = function createSocket(options, cb) {\n var self = this;\n var placeholder = {};\n self.sockets.push(placeholder);\n\n var connectOptions = mergeOptions({}, self.proxyOptions, {\n method: 'CONNECT',\n path: options.host + ':' + options.port,\n agent: false,\n headers: {\n host: options.host + ':' + options.port\n }\n });\n if (options.localAddress) {\n connectOptions.localAddress = options.localAddress;\n }\n if (connectOptions.proxyAuth) {\n connectOptions.headers = connectOptions.headers || {};\n connectOptions.headers['Proxy-Authorization'] = 'Basic ' +\n new Buffer(connectOptions.proxyAuth).toString('base64');\n }\n\n debug('making CONNECT request');\n var connectReq = self.request(connectOptions);\n connectReq.useChunkedEncodingByDefault = false; // for v0.6\n connectReq.once('response', onResponse); // for v0.6\n connectReq.once('upgrade', onUpgrade); // for v0.6\n connectReq.once('connect', onConnect); // for v0.7 or later\n connectReq.once('error', onError);\n connectReq.end();\n\n function onResponse(res) {\n // Very hacky. This is necessary to avoid http-parser leaks.\n res.upgrade = true;\n }\n\n function onUpgrade(res, socket, head) {\n // Hacky.\n process.nextTick(function() {\n onConnect(res, socket, head);\n });\n }\n\n function onConnect(res, socket, head) {\n connectReq.removeAllListeners();\n socket.removeAllListeners();\n\n if (res.statusCode !== 200) {\n debug('tunneling socket could not be established, statusCode=%d',\n res.statusCode);\n socket.destroy();\n var error = new Error('tunneling socket could not be established, ' +\n 'statusCode=' + res.statusCode);\n error.code = 'ECONNRESET';\n options.request.emit('error', error);\n self.removeSocket(placeholder);\n return;\n }\n if (head.length > 0) {\n debug('got illegal response body from proxy');\n socket.destroy();\n var error = new Error('got illegal response body from proxy');\n error.code = 'ECONNRESET';\n options.request.emit('error', error);\n self.removeSocket(placeholder);\n return;\n }\n debug('tunneling connection has established');\n self.sockets[self.sockets.indexOf(placeholder)] = socket;\n return cb(socket);\n }\n\n function onError(cause) {\n connectReq.removeAllListeners();\n\n debug('tunneling socket could not be established, cause=%s\\n',\n cause.message, cause.stack);\n var error = new Error('tunneling socket could not be established, ' +\n 'cause=' + cause.message);\n error.code = 'ECONNRESET';\n options.request.emit('error', error);\n self.removeSocket(placeholder);\n }\n};\n\nTunnelingAgent.prototype.removeSocket = function removeSocket(socket) {\n var pos = this.sockets.indexOf(socket)\n if (pos === -1) {\n return;\n }\n this.sockets.splice(pos, 1);\n\n var pending = this.requests.shift();\n if (pending) {\n // If we have pending requests and a socket gets closed a new one\n // needs to be created to take over in the pool for the one that closed.\n this.createSocket(pending, function(socket) {\n pending.request.onSocket(socket);\n });\n }\n};\n\nfunction createSecureSocket(options, cb) {\n var self = this;\n TunnelingAgent.prototype.createSocket.call(self, options, function(socket) {\n var hostHeader = options.request.getHeader('host');\n var tlsOptions = mergeOptions({}, self.options, {\n socket: socket,\n servername: hostHeader ? hostHeader.replace(/:.*$/, '') : options.host\n });\n\n // 0 is dummy port for v0.6\n var secureSocket = tls.connect(0, tlsOptions);\n self.sockets[self.sockets.indexOf(socket)] = secureSocket;\n cb(secureSocket);\n });\n}\n\n\nfunction toOptions(host, port, localAddress) {\n if (typeof host === 'string') { // since v0.10\n return {\n host: host,\n port: port,\n localAddress: localAddress\n };\n }\n return host; // for v0.11 or later\n}\n\nfunction mergeOptions(target) {\n for (var i = 1, len = arguments.length; i < len; ++i) {\n var overrides = arguments[i];\n if (typeof overrides === 'object') {\n var keys = Object.keys(overrides);\n for (var j = 0, keyLen = keys.length; j < keyLen; ++j) {\n var k = keys[j];\n if (overrides[k] !== undefined) {\n target[k] = overrides[k];\n }\n }\n }\n }\n return target;\n}\n\n\nvar debug;\nif (process.env.NODE_DEBUG && /\\btunnel\\b/.test(process.env.NODE_DEBUG)) {\n debug = function() {\n var args = Array.prototype.slice.call(arguments);\n if (typeof args[0] === 'string') {\n args[0] = 'TUNNEL: ' + args[0];\n } else {\n args.unshift('TUNNEL:');\n }\n console.error.apply(console, args);\n }\n} else {\n debug = function() {};\n}\nexports.debug = debug; // for test\n", "module.exports = require('./lib/tunnel');\n", null, null, null, null, null, null, null, null, "export function getUserAgent() {\n if (typeof navigator === \"object\" && \"userAgent\" in navigator) {\n return navigator.userAgent;\n }\n if (typeof process === \"object\" && \"version\" in process) {\n return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`;\n }\n return \"\";\n}\n", "module.exports = register;\n\nfunction register(state, name, method, options) {\n if (typeof method !== \"function\") {\n throw new Error(\"method for before hook must be a function\");\n }\n\n if (!options) {\n options = {};\n }\n\n if (Array.isArray(name)) {\n return name.reverse().reduce(function (callback, name) {\n return register.bind(null, state, name, callback, options);\n }, method)();\n }\n\n return Promise.resolve().then(function () {\n if (!state.registry[name]) {\n return method(options);\n }\n\n return state.registry[name].reduce(function (method, registered) {\n return registered.hook.bind(null, method, options);\n }, method)();\n });\n}\n", "module.exports = addHook;\n\nfunction addHook(state, kind, name, hook) {\n var orig = hook;\n if (!state.registry[name]) {\n state.registry[name] = [];\n }\n\n if (kind === \"before\") {\n hook = function (method, options) {\n return Promise.resolve()\n .then(orig.bind(null, options))\n .then(method.bind(null, options));\n };\n }\n\n if (kind === \"after\") {\n hook = function (method, options) {\n var result;\n return Promise.resolve()\n .then(method.bind(null, options))\n .then(function (result_) {\n result = result_;\n return orig(result, options);\n })\n .then(function () {\n return result;\n });\n };\n }\n\n if (kind === \"error\") {\n hook = function (method, options) {\n return Promise.resolve()\n .then(method.bind(null, options))\n .catch(function (error) {\n return orig(error, options);\n });\n };\n }\n\n state.registry[name].push({\n hook: hook,\n orig: orig,\n });\n}\n", "module.exports = removeHook;\n\nfunction removeHook(state, name, method) {\n if (!state.registry[name]) {\n return;\n }\n\n var index = state.registry[name]\n .map(function (registered) {\n return registered.orig;\n })\n .indexOf(method);\n\n if (index === -1) {\n return;\n }\n\n state.registry[name].splice(index, 1);\n}\n", "var register = require('./lib/register')\nvar addHook = require('./lib/add')\nvar removeHook = require('./lib/remove')\n\n// bind with array of arguments: https://stackoverflow.com/a/21792913\nvar bind = Function.bind\nvar bindable = bind.bind(bind)\n\nfunction bindApi (hook, state, name) {\n var removeHookRef = bindable(removeHook, null).apply(null, name ? [state, name] : [state])\n hook.api = { remove: removeHookRef }\n hook.remove = removeHookRef\n\n ;['before', 'error', 'after', 'wrap'].forEach(function (kind) {\n var args = name ? [state, kind, name] : [state, kind]\n hook[kind] = hook.api[kind] = bindable(addHook, null).apply(null, args)\n })\n}\n\nfunction HookSingular () {\n var singularHookName = 'h'\n var singularHookState = {\n registry: {}\n }\n var singularHook = register.bind(null, singularHookState, singularHookName)\n bindApi(singularHook, singularHookState, singularHookName)\n return singularHook\n}\n\nfunction HookCollection () {\n var state = {\n registry: {}\n }\n\n var hook = register.bind(null, state)\n bindApi(hook, state)\n\n return hook\n}\n\nvar collectionHookDeprecationMessageDisplayed = false\nfunction Hook () {\n if (!collectionHookDeprecationMessageDisplayed) {\n console.warn('[before-after-hook]: \"Hook()\" repurposing warning, use \"Hook.Collection()\". Read more: https://git.io/upgrade-before-after-hook-to-1.4')\n collectionHookDeprecationMessageDisplayed = true\n }\n return HookCollection()\n}\n\nHook.Singular = HookSingular.bind()\nHook.Collection = HookCollection.bind()\n\nmodule.exports = Hook\n// expose constructors as a named property for TypeScript\nmodule.exports.Hook = Hook\nmodule.exports.Singular = Hook.Singular\nmodule.exports.Collection = Hook.Collection\n", "'use strict';\n\nObject.defineProperty(exports, '__esModule', { value: true });\n\n/*!\n * is-plain-object \n *\n * Copyright (c) 2014-2017, Jon Schlinkert.\n * Released under the MIT License.\n */\n\nfunction isObject(o) {\n return Object.prototype.toString.call(o) === '[object Object]';\n}\n\nfunction isPlainObject(o) {\n var ctor,prot;\n\n if (isObject(o) === false) return false;\n\n // If has modified constructor\n ctor = o.constructor;\n if (ctor === undefined) return true;\n\n // If has modified prototype\n prot = ctor.prototype;\n if (isObject(prot) === false) return false;\n\n // If constructor does not have an Object-specific method\n if (prot.hasOwnProperty('isPrototypeOf') === false) {\n return false;\n }\n\n // Most likely a plain Object\n return true;\n}\n\nexports.isPlainObject = isPlainObject;\n", "export function lowercaseKeys(object) {\n if (!object) {\n return {};\n }\n return Object.keys(object).reduce((newObj, key) => {\n newObj[key.toLowerCase()] = object[key];\n return newObj;\n }, {});\n}\n", "import { isPlainObject } from \"is-plain-object\";\nexport function mergeDeep(defaults, options) {\n const result = Object.assign({}, defaults);\n Object.keys(options).forEach((key) => {\n if (isPlainObject(options[key])) {\n if (!(key in defaults))\n Object.assign(result, { [key]: options[key] });\n else\n result[key] = mergeDeep(defaults[key], options[key]);\n }\n else {\n Object.assign(result, { [key]: options[key] });\n }\n });\n return result;\n}\n", "export function removeUndefinedProperties(obj) {\n for (const key in obj) {\n if (obj[key] === undefined) {\n delete obj[key];\n }\n }\n return obj;\n}\n", "import { lowercaseKeys } from \"./util/lowercase-keys\";\nimport { mergeDeep } from \"./util/merge-deep\";\nimport { removeUndefinedProperties } from \"./util/remove-undefined-properties\";\nexport function merge(defaults, route, options) {\n if (typeof route === \"string\") {\n let [method, url] = route.split(\" \");\n options = Object.assign(url ? { method, url } : { url: method }, options);\n }\n else {\n options = Object.assign({}, route);\n }\n // lowercase header names before merging with defaults to avoid duplicates\n options.headers = lowercaseKeys(options.headers);\n // remove properties with undefined values before merging\n removeUndefinedProperties(options);\n removeUndefinedProperties(options.headers);\n const mergedOptions = mergeDeep(defaults || {}, options);\n // mediaType.previews arrays are merged, instead of overwritten\n if (defaults && defaults.mediaType.previews.length) {\n mergedOptions.mediaType.previews = defaults.mediaType.previews\n .filter((preview) => !mergedOptions.mediaType.previews.includes(preview))\n .concat(mergedOptions.mediaType.previews);\n }\n mergedOptions.mediaType.previews = mergedOptions.mediaType.previews.map((preview) => preview.replace(/-preview/, \"\"));\n return mergedOptions;\n}\n", "export function addQueryParameters(url, parameters) {\n const separator = /\\?/.test(url) ? \"&\" : \"?\";\n const names = Object.keys(parameters);\n if (names.length === 0) {\n return url;\n }\n return (url +\n separator +\n names\n .map((name) => {\n if (name === \"q\") {\n return (\"q=\" + parameters.q.split(\"+\").map(encodeURIComponent).join(\"+\"));\n }\n return `${name}=${encodeURIComponent(parameters[name])}`;\n })\n .join(\"&\"));\n}\n", "const urlVariableRegex = /\\{[^}]+\\}/g;\nfunction removeNonChars(variableName) {\n return variableName.replace(/^\\W+|\\W+$/g, \"\").split(/,/);\n}\nexport function extractUrlVariableNames(url) {\n const matches = url.match(urlVariableRegex);\n if (!matches) {\n return [];\n }\n return matches.map(removeNonChars).reduce((a, b) => a.concat(b), []);\n}\n", "export function omit(object, keysToOmit) {\n return Object.keys(object)\n .filter((option) => !keysToOmit.includes(option))\n .reduce((obj, key) => {\n obj[key] = object[key];\n return obj;\n }, {});\n}\n", "// Based on https://github.com/bramstein/url-template, licensed under BSD\n// TODO: create separate package.\n//\n// Copyright (c) 2012-2014, Bram Stein\n// All rights reserved.\n// Redistribution and use in source and binary forms, with or without\n// modification, are permitted provided that the following conditions\n// are met:\n// 1. Redistributions of source code must retain the above copyright\n// notice, this list of conditions and the following disclaimer.\n// 2. Redistributions in binary form must reproduce the above copyright\n// notice, this list of conditions and the following disclaimer in the\n// documentation and/or other materials provided with the distribution.\n// 3. The name of the author may not be used to endorse or promote products\n// derived from this software without specific prior written permission.\n// THIS SOFTWARE IS PROVIDED BY THE AUTHOR \"AS IS\" AND ANY EXPRESS OR IMPLIED\n// WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF\n// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO\n// EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,\n// INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,\n// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,\n// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY\n// OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\n// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,\n// EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n/* istanbul ignore file */\nfunction encodeReserved(str) {\n return str\n .split(/(%[0-9A-Fa-f]{2})/g)\n .map(function (part) {\n if (!/%[0-9A-Fa-f]/.test(part)) {\n part = encodeURI(part).replace(/%5B/g, \"[\").replace(/%5D/g, \"]\");\n }\n return part;\n })\n .join(\"\");\n}\nfunction encodeUnreserved(str) {\n return encodeURIComponent(str).replace(/[!'()*]/g, function (c) {\n return \"%\" + c.charCodeAt(0).toString(16).toUpperCase();\n });\n}\nfunction encodeValue(operator, value, key) {\n value =\n operator === \"+\" || operator === \"#\"\n ? encodeReserved(value)\n : encodeUnreserved(value);\n if (key) {\n return encodeUnreserved(key) + \"=\" + value;\n }\n else {\n return value;\n }\n}\nfunction isDefined(value) {\n return value !== undefined && value !== null;\n}\nfunction isKeyOperator(operator) {\n return operator === \";\" || operator === \"&\" || operator === \"?\";\n}\nfunction getValues(context, operator, key, modifier) {\n var value = context[key], result = [];\n if (isDefined(value) && value !== \"\") {\n if (typeof value === \"string\" ||\n typeof value === \"number\" ||\n typeof value === \"boolean\") {\n value = value.toString();\n if (modifier && modifier !== \"*\") {\n value = value.substring(0, parseInt(modifier, 10));\n }\n result.push(encodeValue(operator, value, isKeyOperator(operator) ? key : \"\"));\n }\n else {\n if (modifier === \"*\") {\n if (Array.isArray(value)) {\n value.filter(isDefined).forEach(function (value) {\n result.push(encodeValue(operator, value, isKeyOperator(operator) ? key : \"\"));\n });\n }\n else {\n Object.keys(value).forEach(function (k) {\n if (isDefined(value[k])) {\n result.push(encodeValue(operator, value[k], k));\n }\n });\n }\n }\n else {\n const tmp = [];\n if (Array.isArray(value)) {\n value.filter(isDefined).forEach(function (value) {\n tmp.push(encodeValue(operator, value));\n });\n }\n else {\n Object.keys(value).forEach(function (k) {\n if (isDefined(value[k])) {\n tmp.push(encodeUnreserved(k));\n tmp.push(encodeValue(operator, value[k].toString()));\n }\n });\n }\n if (isKeyOperator(operator)) {\n result.push(encodeUnreserved(key) + \"=\" + tmp.join(\",\"));\n }\n else if (tmp.length !== 0) {\n result.push(tmp.join(\",\"));\n }\n }\n }\n }\n else {\n if (operator === \";\") {\n if (isDefined(value)) {\n result.push(encodeUnreserved(key));\n }\n }\n else if (value === \"\" && (operator === \"&\" || operator === \"?\")) {\n result.push(encodeUnreserved(key) + \"=\");\n }\n else if (value === \"\") {\n result.push(\"\");\n }\n }\n return result;\n}\nexport function parseUrl(template) {\n return {\n expand: expand.bind(null, template),\n };\n}\nfunction expand(template, context) {\n var operators = [\"+\", \"#\", \".\", \"/\", \";\", \"?\", \"&\"];\n return template.replace(/\\{([^\\{\\}]+)\\}|([^\\{\\}]+)/g, function (_, expression, literal) {\n if (expression) {\n let operator = \"\";\n const values = [];\n if (operators.indexOf(expression.charAt(0)) !== -1) {\n operator = expression.charAt(0);\n expression = expression.substr(1);\n }\n expression.split(/,/g).forEach(function (variable) {\n var tmp = /([^:\\*]*)(?::(\\d+)|(\\*))?/.exec(variable);\n values.push(getValues(context, operator, tmp[1], tmp[2] || tmp[3]));\n });\n if (operator && operator !== \"+\") {\n var separator = \",\";\n if (operator === \"?\") {\n separator = \"&\";\n }\n else if (operator !== \"#\") {\n separator = operator;\n }\n return (values.length !== 0 ? operator : \"\") + values.join(separator);\n }\n else {\n return values.join(\",\");\n }\n }\n else {\n return encodeReserved(literal);\n }\n });\n}\n", "import { addQueryParameters } from \"./util/add-query-parameters\";\nimport { extractUrlVariableNames } from \"./util/extract-url-variable-names\";\nimport { omit } from \"./util/omit\";\nimport { parseUrl } from \"./util/url-template\";\nexport function parse(options) {\n // https://fetch.spec.whatwg.org/#methods\n let method = options.method.toUpperCase();\n // replace :varname with {varname} to make it RFC 6570 compatible\n let url = (options.url || \"/\").replace(/:([a-z]\\w+)/g, \"{$1}\");\n let headers = Object.assign({}, options.headers);\n let body;\n let parameters = omit(options, [\n \"method\",\n \"baseUrl\",\n \"url\",\n \"headers\",\n \"request\",\n \"mediaType\",\n ]);\n // extract variable names from URL to calculate remaining variables later\n const urlVariableNames = extractUrlVariableNames(url);\n url = parseUrl(url).expand(parameters);\n if (!/^http/.test(url)) {\n url = options.baseUrl + url;\n }\n const omittedParameters = Object.keys(options)\n .filter((option) => urlVariableNames.includes(option))\n .concat(\"baseUrl\");\n const remainingParameters = omit(parameters, omittedParameters);\n const isBinaryRequest = /application\\/octet-stream/i.test(headers.accept);\n if (!isBinaryRequest) {\n if (options.mediaType.format) {\n // e.g. application/vnd.github.v3+json => application/vnd.github.v3.raw\n headers.accept = headers.accept\n .split(/,/)\n .map((preview) => preview.replace(/application\\/vnd(\\.\\w+)(\\.v3)?(\\.\\w+)?(\\+json)?$/, `application/vnd$1$2.${options.mediaType.format}`))\n .join(\",\");\n }\n if (options.mediaType.previews.length) {\n const previewsFromAcceptHeader = headers.accept.match(/[\\w-]+(?=-preview)/g) || [];\n headers.accept = previewsFromAcceptHeader\n .concat(options.mediaType.previews)\n .map((preview) => {\n const format = options.mediaType.format\n ? `.${options.mediaType.format}`\n : \"+json\";\n return `application/vnd.github.${preview}-preview${format}`;\n })\n .join(\",\");\n }\n }\n // for GET/HEAD requests, set URL query parameters from remaining parameters\n // for PATCH/POST/PUT/DELETE requests, set request body from remaining parameters\n if ([\"GET\", \"HEAD\"].includes(method)) {\n url = addQueryParameters(url, remainingParameters);\n }\n else {\n if (\"data\" in remainingParameters) {\n body = remainingParameters.data;\n }\n else {\n if (Object.keys(remainingParameters).length) {\n body = remainingParameters;\n }\n else {\n headers[\"content-length\"] = 0;\n }\n }\n }\n // default content-type for JSON if body is set\n if (!headers[\"content-type\"] && typeof body !== \"undefined\") {\n headers[\"content-type\"] = \"application/json; charset=utf-8\";\n }\n // GitHub expects 'content-length: 0' header for PUT/PATCH requests without body.\n // fetch does not allow to set `content-length` header, but we can set body to an empty string\n if ([\"PATCH\", \"PUT\"].includes(method) && typeof body === \"undefined\") {\n body = \"\";\n }\n // Only return body/request keys if present\n return Object.assign({ method, url, headers }, typeof body !== \"undefined\" ? { body } : null, options.request ? { request: options.request } : null);\n}\n", "import { merge } from \"./merge\";\nimport { parse } from \"./parse\";\nexport function endpointWithDefaults(defaults, route, options) {\n return parse(merge(defaults, route, options));\n}\n", "import { endpointWithDefaults } from \"./endpoint-with-defaults\";\nimport { merge } from \"./merge\";\nimport { parse } from \"./parse\";\nexport function withDefaults(oldDefaults, newDefaults) {\n const DEFAULTS = merge(oldDefaults, newDefaults);\n const endpoint = endpointWithDefaults.bind(null, DEFAULTS);\n return Object.assign(endpoint, {\n DEFAULTS,\n defaults: withDefaults.bind(null, DEFAULTS),\n merge: merge.bind(null, DEFAULTS),\n parse,\n });\n}\n", "export const VERSION = \"6.0.12\";\n", "import { getUserAgent } from \"universal-user-agent\";\nimport { VERSION } from \"./version\";\nconst userAgent = `octokit-endpoint.js/${VERSION} ${getUserAgent()}`;\n// DEFAULTS has all properties set that EndpointOptions has, except url.\n// So we use RequestParameters and add method as additional required property.\nexport const DEFAULTS = {\n method: \"GET\",\n baseUrl: \"https://api.github.com\",\n headers: {\n accept: \"application/vnd.github.v3+json\",\n \"user-agent\": userAgent,\n },\n mediaType: {\n format: \"\",\n previews: [],\n },\n};\n", "import { withDefaults } from \"./with-defaults\";\nimport { DEFAULTS } from \"./defaults\";\nexport const endpoint = withDefaults(null, DEFAULTS);\n", "\"use strict\";\n\nvar conversions = {};\nmodule.exports = conversions;\n\nfunction sign(x) {\n return x < 0 ? -1 : 1;\n}\n\nfunction evenRound(x) {\n // Round x to the nearest integer, choosing the even integer if it lies halfway between two.\n if ((x % 1) === 0.5 && (x & 1) === 0) { // [even number].5; round down (i.e. floor)\n return Math.floor(x);\n } else {\n return Math.round(x);\n }\n}\n\nfunction createNumberConversion(bitLength, typeOpts) {\n if (!typeOpts.unsigned) {\n --bitLength;\n }\n const lowerBound = typeOpts.unsigned ? 0 : -Math.pow(2, bitLength);\n const upperBound = Math.pow(2, bitLength) - 1;\n\n const moduloVal = typeOpts.moduloBitLength ? Math.pow(2, typeOpts.moduloBitLength) : Math.pow(2, bitLength);\n const moduloBound = typeOpts.moduloBitLength ? Math.pow(2, typeOpts.moduloBitLength - 1) : Math.pow(2, bitLength - 1);\n\n return function(V, opts) {\n if (!opts) opts = {};\n\n let x = +V;\n\n if (opts.enforceRange) {\n if (!Number.isFinite(x)) {\n throw new TypeError(\"Argument is not a finite number\");\n }\n\n x = sign(x) * Math.floor(Math.abs(x));\n if (x < lowerBound || x > upperBound) {\n throw new TypeError(\"Argument is not in byte range\");\n }\n\n return x;\n }\n\n if (!isNaN(x) && opts.clamp) {\n x = evenRound(x);\n\n if (x < lowerBound) x = lowerBound;\n if (x > upperBound) x = upperBound;\n return x;\n }\n\n if (!Number.isFinite(x) || x === 0) {\n return 0;\n }\n\n x = sign(x) * Math.floor(Math.abs(x));\n x = x % moduloVal;\n\n if (!typeOpts.unsigned && x >= moduloBound) {\n return x - moduloVal;\n } else if (typeOpts.unsigned) {\n if (x < 0) {\n x += moduloVal;\n } else if (x === -0) { // don't return negative zero\n return 0;\n }\n }\n\n return x;\n }\n}\n\nconversions[\"void\"] = function () {\n return undefined;\n};\n\nconversions[\"boolean\"] = function (val) {\n return !!val;\n};\n\nconversions[\"byte\"] = createNumberConversion(8, { unsigned: false });\nconversions[\"octet\"] = createNumberConversion(8, { unsigned: true });\n\nconversions[\"short\"] = createNumberConversion(16, { unsigned: false });\nconversions[\"unsigned short\"] = createNumberConversion(16, { unsigned: true });\n\nconversions[\"long\"] = createNumberConversion(32, { unsigned: false });\nconversions[\"unsigned long\"] = createNumberConversion(32, { unsigned: true });\n\nconversions[\"long long\"] = createNumberConversion(32, { unsigned: false, moduloBitLength: 64 });\nconversions[\"unsigned long long\"] = createNumberConversion(32, { unsigned: true, moduloBitLength: 64 });\n\nconversions[\"double\"] = function (V) {\n const x = +V;\n\n if (!Number.isFinite(x)) {\n throw new TypeError(\"Argument is not a finite floating-point value\");\n }\n\n return x;\n};\n\nconversions[\"unrestricted double\"] = function (V) {\n const x = +V;\n\n if (isNaN(x)) {\n throw new TypeError(\"Argument is NaN\");\n }\n\n return x;\n};\n\n// not quite valid, but good enough for JS\nconversions[\"float\"] = conversions[\"double\"];\nconversions[\"unrestricted float\"] = conversions[\"unrestricted double\"];\n\nconversions[\"DOMString\"] = function (V, opts) {\n if (!opts) opts = {};\n\n if (opts.treatNullAsEmptyString && V === null) {\n return \"\";\n }\n\n return String(V);\n};\n\nconversions[\"ByteString\"] = function (V, opts) {\n const x = String(V);\n let c = undefined;\n for (let i = 0; (c = x.codePointAt(i)) !== undefined; ++i) {\n if (c > 255) {\n throw new TypeError(\"Argument is not a valid bytestring\");\n }\n }\n\n return x;\n};\n\nconversions[\"USVString\"] = function (V) {\n const S = String(V);\n const n = S.length;\n const U = [];\n for (let i = 0; i < n; ++i) {\n const c = S.charCodeAt(i);\n if (c < 0xD800 || c > 0xDFFF) {\n U.push(String.fromCodePoint(c));\n } else if (0xDC00 <= c && c <= 0xDFFF) {\n U.push(String.fromCodePoint(0xFFFD));\n } else {\n if (i === n - 1) {\n U.push(String.fromCodePoint(0xFFFD));\n } else {\n const d = S.charCodeAt(i + 1);\n if (0xDC00 <= d && d <= 0xDFFF) {\n const a = c & 0x3FF;\n const b = d & 0x3FF;\n U.push(String.fromCodePoint((2 << 15) + (2 << 9) * a + b));\n ++i;\n } else {\n U.push(String.fromCodePoint(0xFFFD));\n }\n }\n }\n }\n\n return U.join('');\n};\n\nconversions[\"Date\"] = function (V, opts) {\n if (!(V instanceof Date)) {\n throw new TypeError(\"Argument is not a Date object\");\n }\n if (isNaN(V)) {\n return undefined;\n }\n\n return V;\n};\n\nconversions[\"RegExp\"] = function (V, opts) {\n if (!(V instanceof RegExp)) {\n V = new RegExp(V);\n }\n\n return V;\n};\n", "\"use strict\";\n\nmodule.exports.mixin = function mixin(target, source) {\n const keys = Object.getOwnPropertyNames(source);\n for (let i = 0; i < keys.length; ++i) {\n Object.defineProperty(target, keys[i], Object.getOwnPropertyDescriptor(source, keys[i]));\n }\n};\n\nmodule.exports.wrapperSymbol = Symbol(\"wrapper\");\nmodule.exports.implSymbol = Symbol(\"impl\");\n\nmodule.exports.wrapperForImpl = function (impl) {\n return impl[module.exports.wrapperSymbol];\n};\n\nmodule.exports.implForWrapper = function (wrapper) {\n return wrapper[module.exports.implSymbol];\n};\n\n", "\"use strict\";\n\nvar punycode = require(\"punycode\");\nvar mappingTable = require(\"./lib/mappingTable.json\");\n\nvar PROCESSING_OPTIONS = {\n TRANSITIONAL: 0,\n NONTRANSITIONAL: 1\n};\n\nfunction normalize(str) { // fix bug in v8\n return str.split('\\u0000').map(function (s) { return s.normalize('NFC'); }).join('\\u0000');\n}\n\nfunction findStatus(val) {\n var start = 0;\n var end = mappingTable.length - 1;\n\n while (start <= end) {\n var mid = Math.floor((start + end) / 2);\n\n var target = mappingTable[mid];\n if (target[0][0] <= val && target[0][1] >= val) {\n return target;\n } else if (target[0][0] > val) {\n end = mid - 1;\n } else {\n start = mid + 1;\n }\n }\n\n return null;\n}\n\nvar regexAstralSymbols = /[\\uD800-\\uDBFF][\\uDC00-\\uDFFF]/g;\n\nfunction countSymbols(string) {\n return string\n // replace every surrogate pair with a BMP symbol\n .replace(regexAstralSymbols, '_')\n // then get the length\n .length;\n}\n\nfunction mapChars(domain_name, useSTD3, processing_option) {\n var hasError = false;\n var processed = \"\";\n\n var len = countSymbols(domain_name);\n for (var i = 0; i < len; ++i) {\n var codePoint = domain_name.codePointAt(i);\n var status = findStatus(codePoint);\n\n switch (status[1]) {\n case \"disallowed\":\n hasError = true;\n processed += String.fromCodePoint(codePoint);\n break;\n case \"ignored\":\n break;\n case \"mapped\":\n processed += String.fromCodePoint.apply(String, status[2]);\n break;\n case \"deviation\":\n if (processing_option === PROCESSING_OPTIONS.TRANSITIONAL) {\n processed += String.fromCodePoint.apply(String, status[2]);\n } else {\n processed += String.fromCodePoint(codePoint);\n }\n break;\n case \"valid\":\n processed += String.fromCodePoint(codePoint);\n break;\n case \"disallowed_STD3_mapped\":\n if (useSTD3) {\n hasError = true;\n processed += String.fromCodePoint(codePoint);\n } else {\n processed += String.fromCodePoint.apply(String, status[2]);\n }\n break;\n case \"disallowed_STD3_valid\":\n if (useSTD3) {\n hasError = true;\n }\n\n processed += String.fromCodePoint(codePoint);\n break;\n }\n }\n\n return {\n string: processed,\n error: hasError\n };\n}\n\nvar combiningMarksRegex = /[\\u0300-\\u036F\\u0483-\\u0489\\u0591-\\u05BD\\u05BF\\u05C1\\u05C2\\u05C4\\u05C5\\u05C7\\u0610-\\u061A\\u064B-\\u065F\\u0670\\u06D6-\\u06DC\\u06DF-\\u06E4\\u06E7\\u06E8\\u06EA-\\u06ED\\u0711\\u0730-\\u074A\\u07A6-\\u07B0\\u07EB-\\u07F3\\u0816-\\u0819\\u081B-\\u0823\\u0825-\\u0827\\u0829-\\u082D\\u0859-\\u085B\\u08E4-\\u0903\\u093A-\\u093C\\u093E-\\u094F\\u0951-\\u0957\\u0962\\u0963\\u0981-\\u0983\\u09BC\\u09BE-\\u09C4\\u09C7\\u09C8\\u09CB-\\u09CD\\u09D7\\u09E2\\u09E3\\u0A01-\\u0A03\\u0A3C\\u0A3E-\\u0A42\\u0A47\\u0A48\\u0A4B-\\u0A4D\\u0A51\\u0A70\\u0A71\\u0A75\\u0A81-\\u0A83\\u0ABC\\u0ABE-\\u0AC5\\u0AC7-\\u0AC9\\u0ACB-\\u0ACD\\u0AE2\\u0AE3\\u0B01-\\u0B03\\u0B3C\\u0B3E-\\u0B44\\u0B47\\u0B48\\u0B4B-\\u0B4D\\u0B56\\u0B57\\u0B62\\u0B63\\u0B82\\u0BBE-\\u0BC2\\u0BC6-\\u0BC8\\u0BCA-\\u0BCD\\u0BD7\\u0C00-\\u0C03\\u0C3E-\\u0C44\\u0C46-\\u0C48\\u0C4A-\\u0C4D\\u0C55\\u0C56\\u0C62\\u0C63\\u0C81-\\u0C83\\u0CBC\\u0CBE-\\u0CC4\\u0CC6-\\u0CC8\\u0CCA-\\u0CCD\\u0CD5\\u0CD6\\u0CE2\\u0CE3\\u0D01-\\u0D03\\u0D3E-\\u0D44\\u0D46-\\u0D48\\u0D4A-\\u0D4D\\u0D57\\u0D62\\u0D63\\u0D82\\u0D83\\u0DCA\\u0DCF-\\u0DD4\\u0DD6\\u0DD8-\\u0DDF\\u0DF2\\u0DF3\\u0E31\\u0E34-\\u0E3A\\u0E47-\\u0E4E\\u0EB1\\u0EB4-\\u0EB9\\u0EBB\\u0EBC\\u0EC8-\\u0ECD\\u0F18\\u0F19\\u0F35\\u0F37\\u0F39\\u0F3E\\u0F3F\\u0F71-\\u0F84\\u0F86\\u0F87\\u0F8D-\\u0F97\\u0F99-\\u0FBC\\u0FC6\\u102B-\\u103E\\u1056-\\u1059\\u105E-\\u1060\\u1062-\\u1064\\u1067-\\u106D\\u1071-\\u1074\\u1082-\\u108D\\u108F\\u109A-\\u109D\\u135D-\\u135F\\u1712-\\u1714\\u1732-\\u1734\\u1752\\u1753\\u1772\\u1773\\u17B4-\\u17D3\\u17DD\\u180B-\\u180D\\u18A9\\u1920-\\u192B\\u1930-\\u193B\\u19B0-\\u19C0\\u19C8\\u19C9\\u1A17-\\u1A1B\\u1A55-\\u1A5E\\u1A60-\\u1A7C\\u1A7F\\u1AB0-\\u1ABE\\u1B00-\\u1B04\\u1B34-\\u1B44\\u1B6B-\\u1B73\\u1B80-\\u1B82\\u1BA1-\\u1BAD\\u1BE6-\\u1BF3\\u1C24-\\u1C37\\u1CD0-\\u1CD2\\u1CD4-\\u1CE8\\u1CED\\u1CF2-\\u1CF4\\u1CF8\\u1CF9\\u1DC0-\\u1DF5\\u1DFC-\\u1DFF\\u20D0-\\u20F0\\u2CEF-\\u2CF1\\u2D7F\\u2DE0-\\u2DFF\\u302A-\\u302F\\u3099\\u309A\\uA66F-\\uA672\\uA674-\\uA67D\\uA69F\\uA6F0\\uA6F1\\uA802\\uA806\\uA80B\\uA823-\\uA827\\uA880\\uA881\\uA8B4-\\uA8C4\\uA8E0-\\uA8F1\\uA926-\\uA92D\\uA947-\\uA953\\uA980-\\uA983\\uA9B3-\\uA9C0\\uA9E5\\uAA29-\\uAA36\\uAA43\\uAA4C\\uAA4D\\uAA7B-\\uAA7D\\uAAB0\\uAAB2-\\uAAB4\\uAAB7\\uAAB8\\uAABE\\uAABF\\uAAC1\\uAAEB-\\uAAEF\\uAAF5\\uAAF6\\uABE3-\\uABEA\\uABEC\\uABED\\uFB1E\\uFE00-\\uFE0F\\uFE20-\\uFE2D]|\\uD800[\\uDDFD\\uDEE0\\uDF76-\\uDF7A]|\\uD802[\\uDE01-\\uDE03\\uDE05\\uDE06\\uDE0C-\\uDE0F\\uDE38-\\uDE3A\\uDE3F\\uDEE5\\uDEE6]|\\uD804[\\uDC00-\\uDC02\\uDC38-\\uDC46\\uDC7F-\\uDC82\\uDCB0-\\uDCBA\\uDD00-\\uDD02\\uDD27-\\uDD34\\uDD73\\uDD80-\\uDD82\\uDDB3-\\uDDC0\\uDE2C-\\uDE37\\uDEDF-\\uDEEA\\uDF01-\\uDF03\\uDF3C\\uDF3E-\\uDF44\\uDF47\\uDF48\\uDF4B-\\uDF4D\\uDF57\\uDF62\\uDF63\\uDF66-\\uDF6C\\uDF70-\\uDF74]|\\uD805[\\uDCB0-\\uDCC3\\uDDAF-\\uDDB5\\uDDB8-\\uDDC0\\uDE30-\\uDE40\\uDEAB-\\uDEB7]|\\uD81A[\\uDEF0-\\uDEF4\\uDF30-\\uDF36]|\\uD81B[\\uDF51-\\uDF7E\\uDF8F-\\uDF92]|\\uD82F[\\uDC9D\\uDC9E]|\\uD834[\\uDD65-\\uDD69\\uDD6D-\\uDD72\\uDD7B-\\uDD82\\uDD85-\\uDD8B\\uDDAA-\\uDDAD\\uDE42-\\uDE44]|\\uD83A[\\uDCD0-\\uDCD6]|\\uDB40[\\uDD00-\\uDDEF]/;\n\nfunction validateLabel(label, processing_option) {\n if (label.substr(0, 4) === \"xn--\") {\n label = punycode.toUnicode(label);\n processing_option = PROCESSING_OPTIONS.NONTRANSITIONAL;\n }\n\n var error = false;\n\n if (normalize(label) !== label ||\n (label[3] === \"-\" && label[4] === \"-\") ||\n label[0] === \"-\" || label[label.length - 1] === \"-\" ||\n label.indexOf(\".\") !== -1 ||\n label.search(combiningMarksRegex) === 0) {\n error = true;\n }\n\n var len = countSymbols(label);\n for (var i = 0; i < len; ++i) {\n var status = findStatus(label.codePointAt(i));\n if ((processing === PROCESSING_OPTIONS.TRANSITIONAL && status[1] !== \"valid\") ||\n (processing === PROCESSING_OPTIONS.NONTRANSITIONAL &&\n status[1] !== \"valid\" && status[1] !== \"deviation\")) {\n error = true;\n break;\n }\n }\n\n return {\n label: label,\n error: error\n };\n}\n\nfunction processing(domain_name, useSTD3, processing_option) {\n var result = mapChars(domain_name, useSTD3, processing_option);\n result.string = normalize(result.string);\n\n var labels = result.string.split(\".\");\n for (var i = 0; i < labels.length; ++i) {\n try {\n var validation = validateLabel(labels[i]);\n labels[i] = validation.label;\n result.error = result.error || validation.error;\n } catch(e) {\n result.error = true;\n }\n }\n\n return {\n string: labels.join(\".\"),\n error: result.error\n };\n}\n\nmodule.exports.toASCII = function(domain_name, useSTD3, processing_option, verifyDnsLength) {\n var result = processing(domain_name, useSTD3, processing_option);\n var labels = result.string.split(\".\");\n labels = labels.map(function(l) {\n try {\n return punycode.toASCII(l);\n } catch(e) {\n result.error = true;\n return l;\n }\n });\n\n if (verifyDnsLength) {\n var total = labels.slice(0, labels.length - 1).join(\".\").length;\n if (total.length > 253 || total.length === 0) {\n result.error = true;\n }\n\n for (var i=0; i < labels.length; ++i) {\n if (labels.length > 63 || labels.length === 0) {\n result.error = true;\n break;\n }\n }\n }\n\n if (result.error) return null;\n return labels.join(\".\");\n};\n\nmodule.exports.toUnicode = function(domain_name, useSTD3) {\n var result = processing(domain_name, useSTD3, PROCESSING_OPTIONS.NONTRANSITIONAL);\n\n return {\n domain: result.string,\n error: result.error\n };\n};\n\nmodule.exports.PROCESSING_OPTIONS = PROCESSING_OPTIONS;\n", "\"use strict\";\r\nconst punycode = require(\"punycode\");\r\nconst tr46 = require(\"tr46\");\r\n\r\nconst specialSchemes = {\r\n ftp: 21,\r\n file: null,\r\n gopher: 70,\r\n http: 80,\r\n https: 443,\r\n ws: 80,\r\n wss: 443\r\n};\r\n\r\nconst failure = Symbol(\"failure\");\r\n\r\nfunction countSymbols(str) {\r\n return punycode.ucs2.decode(str).length;\r\n}\r\n\r\nfunction at(input, idx) {\r\n const c = input[idx];\r\n return isNaN(c) ? undefined : String.fromCodePoint(c);\r\n}\r\n\r\nfunction isASCIIDigit(c) {\r\n return c >= 0x30 && c <= 0x39;\r\n}\r\n\r\nfunction isASCIIAlpha(c) {\r\n return (c >= 0x41 && c <= 0x5A) || (c >= 0x61 && c <= 0x7A);\r\n}\r\n\r\nfunction isASCIIAlphanumeric(c) {\r\n return isASCIIAlpha(c) || isASCIIDigit(c);\r\n}\r\n\r\nfunction isASCIIHex(c) {\r\n return isASCIIDigit(c) || (c >= 0x41 && c <= 0x46) || (c >= 0x61 && c <= 0x66);\r\n}\r\n\r\nfunction isSingleDot(buffer) {\r\n return buffer === \".\" || buffer.toLowerCase() === \"%2e\";\r\n}\r\n\r\nfunction isDoubleDot(buffer) {\r\n buffer = buffer.toLowerCase();\r\n return buffer === \"..\" || buffer === \"%2e.\" || buffer === \".%2e\" || buffer === \"%2e%2e\";\r\n}\r\n\r\nfunction isWindowsDriveLetterCodePoints(cp1, cp2) {\r\n return isASCIIAlpha(cp1) && (cp2 === 58 || cp2 === 124);\r\n}\r\n\r\nfunction isWindowsDriveLetterString(string) {\r\n return string.length === 2 && isASCIIAlpha(string.codePointAt(0)) && (string[1] === \":\" || string[1] === \"|\");\r\n}\r\n\r\nfunction isNormalizedWindowsDriveLetterString(string) {\r\n return string.length === 2 && isASCIIAlpha(string.codePointAt(0)) && string[1] === \":\";\r\n}\r\n\r\nfunction containsForbiddenHostCodePoint(string) {\r\n return string.search(/\\u0000|\\u0009|\\u000A|\\u000D|\\u0020|#|%|\\/|:|\\?|@|\\[|\\\\|\\]/) !== -1;\r\n}\r\n\r\nfunction containsForbiddenHostCodePointExcludingPercent(string) {\r\n return string.search(/\\u0000|\\u0009|\\u000A|\\u000D|\\u0020|#|\\/|:|\\?|@|\\[|\\\\|\\]/) !== -1;\r\n}\r\n\r\nfunction isSpecialScheme(scheme) {\r\n return specialSchemes[scheme] !== undefined;\r\n}\r\n\r\nfunction isSpecial(url) {\r\n return isSpecialScheme(url.scheme);\r\n}\r\n\r\nfunction defaultPort(scheme) {\r\n return specialSchemes[scheme];\r\n}\r\n\r\nfunction percentEncode(c) {\r\n let hex = c.toString(16).toUpperCase();\r\n if (hex.length === 1) {\r\n hex = \"0\" + hex;\r\n }\r\n\r\n return \"%\" + hex;\r\n}\r\n\r\nfunction utf8PercentEncode(c) {\r\n const buf = new Buffer(c);\r\n\r\n let str = \"\";\r\n\r\n for (let i = 0; i < buf.length; ++i) {\r\n str += percentEncode(buf[i]);\r\n }\r\n\r\n return str;\r\n}\r\n\r\nfunction utf8PercentDecode(str) {\r\n const input = new Buffer(str);\r\n const output = [];\r\n for (let i = 0; i < input.length; ++i) {\r\n if (input[i] !== 37) {\r\n output.push(input[i]);\r\n } else if (input[i] === 37 && isASCIIHex(input[i + 1]) && isASCIIHex(input[i + 2])) {\r\n output.push(parseInt(input.slice(i + 1, i + 3).toString(), 16));\r\n i += 2;\r\n } else {\r\n output.push(input[i]);\r\n }\r\n }\r\n return new Buffer(output).toString();\r\n}\r\n\r\nfunction isC0ControlPercentEncode(c) {\r\n return c <= 0x1F || c > 0x7E;\r\n}\r\n\r\nconst extraPathPercentEncodeSet = new Set([32, 34, 35, 60, 62, 63, 96, 123, 125]);\r\nfunction isPathPercentEncode(c) {\r\n return isC0ControlPercentEncode(c) || extraPathPercentEncodeSet.has(c);\r\n}\r\n\r\nconst extraUserinfoPercentEncodeSet =\r\n new Set([47, 58, 59, 61, 64, 91, 92, 93, 94, 124]);\r\nfunction isUserinfoPercentEncode(c) {\r\n return isPathPercentEncode(c) || extraUserinfoPercentEncodeSet.has(c);\r\n}\r\n\r\nfunction percentEncodeChar(c, encodeSetPredicate) {\r\n const cStr = String.fromCodePoint(c);\r\n\r\n if (encodeSetPredicate(c)) {\r\n return utf8PercentEncode(cStr);\r\n }\r\n\r\n return cStr;\r\n}\r\n\r\nfunction parseIPv4Number(input) {\r\n let R = 10;\r\n\r\n if (input.length >= 2 && input.charAt(0) === \"0\" && input.charAt(1).toLowerCase() === \"x\") {\r\n input = input.substring(2);\r\n R = 16;\r\n } else if (input.length >= 2 && input.charAt(0) === \"0\") {\r\n input = input.substring(1);\r\n R = 8;\r\n }\r\n\r\n if (input === \"\") {\r\n return 0;\r\n }\r\n\r\n const regex = R === 10 ? /[^0-9]/ : (R === 16 ? /[^0-9A-Fa-f]/ : /[^0-7]/);\r\n if (regex.test(input)) {\r\n return failure;\r\n }\r\n\r\n return parseInt(input, R);\r\n}\r\n\r\nfunction parseIPv4(input) {\r\n const parts = input.split(\".\");\r\n if (parts[parts.length - 1] === \"\") {\r\n if (parts.length > 1) {\r\n parts.pop();\r\n }\r\n }\r\n\r\n if (parts.length > 4) {\r\n return input;\r\n }\r\n\r\n const numbers = [];\r\n for (const part of parts) {\r\n if (part === \"\") {\r\n return input;\r\n }\r\n const n = parseIPv4Number(part);\r\n if (n === failure) {\r\n return input;\r\n }\r\n\r\n numbers.push(n);\r\n }\r\n\r\n for (let i = 0; i < numbers.length - 1; ++i) {\r\n if (numbers[i] > 255) {\r\n return failure;\r\n }\r\n }\r\n if (numbers[numbers.length - 1] >= Math.pow(256, 5 - numbers.length)) {\r\n return failure;\r\n }\r\n\r\n let ipv4 = numbers.pop();\r\n let counter = 0;\r\n\r\n for (const n of numbers) {\r\n ipv4 += n * Math.pow(256, 3 - counter);\r\n ++counter;\r\n }\r\n\r\n return ipv4;\r\n}\r\n\r\nfunction serializeIPv4(address) {\r\n let output = \"\";\r\n let n = address;\r\n\r\n for (let i = 1; i <= 4; ++i) {\r\n output = String(n % 256) + output;\r\n if (i !== 4) {\r\n output = \".\" + output;\r\n }\r\n n = Math.floor(n / 256);\r\n }\r\n\r\n return output;\r\n}\r\n\r\nfunction parseIPv6(input) {\r\n const address = [0, 0, 0, 0, 0, 0, 0, 0];\r\n let pieceIndex = 0;\r\n let compress = null;\r\n let pointer = 0;\r\n\r\n input = punycode.ucs2.decode(input);\r\n\r\n if (input[pointer] === 58) {\r\n if (input[pointer + 1] !== 58) {\r\n return failure;\r\n }\r\n\r\n pointer += 2;\r\n ++pieceIndex;\r\n compress = pieceIndex;\r\n }\r\n\r\n while (pointer < input.length) {\r\n if (pieceIndex === 8) {\r\n return failure;\r\n }\r\n\r\n if (input[pointer] === 58) {\r\n if (compress !== null) {\r\n return failure;\r\n }\r\n ++pointer;\r\n ++pieceIndex;\r\n compress = pieceIndex;\r\n continue;\r\n }\r\n\r\n let value = 0;\r\n let length = 0;\r\n\r\n while (length < 4 && isASCIIHex(input[pointer])) {\r\n value = value * 0x10 + parseInt(at(input, pointer), 16);\r\n ++pointer;\r\n ++length;\r\n }\r\n\r\n if (input[pointer] === 46) {\r\n if (length === 0) {\r\n return failure;\r\n }\r\n\r\n pointer -= length;\r\n\r\n if (pieceIndex > 6) {\r\n return failure;\r\n }\r\n\r\n let numbersSeen = 0;\r\n\r\n while (input[pointer] !== undefined) {\r\n let ipv4Piece = null;\r\n\r\n if (numbersSeen > 0) {\r\n if (input[pointer] === 46 && numbersSeen < 4) {\r\n ++pointer;\r\n } else {\r\n return failure;\r\n }\r\n }\r\n\r\n if (!isASCIIDigit(input[pointer])) {\r\n return failure;\r\n }\r\n\r\n while (isASCIIDigit(input[pointer])) {\r\n const number = parseInt(at(input, pointer));\r\n if (ipv4Piece === null) {\r\n ipv4Piece = number;\r\n } else if (ipv4Piece === 0) {\r\n return failure;\r\n } else {\r\n ipv4Piece = ipv4Piece * 10 + number;\r\n }\r\n if (ipv4Piece > 255) {\r\n return failure;\r\n }\r\n ++pointer;\r\n }\r\n\r\n address[pieceIndex] = address[pieceIndex] * 0x100 + ipv4Piece;\r\n\r\n ++numbersSeen;\r\n\r\n if (numbersSeen === 2 || numbersSeen === 4) {\r\n ++pieceIndex;\r\n }\r\n }\r\n\r\n if (numbersSeen !== 4) {\r\n return failure;\r\n }\r\n\r\n break;\r\n } else if (input[pointer] === 58) {\r\n ++pointer;\r\n if (input[pointer] === undefined) {\r\n return failure;\r\n }\r\n } else if (input[pointer] !== undefined) {\r\n return failure;\r\n }\r\n\r\n address[pieceIndex] = value;\r\n ++pieceIndex;\r\n }\r\n\r\n if (compress !== null) {\r\n let swaps = pieceIndex - compress;\r\n pieceIndex = 7;\r\n while (pieceIndex !== 0 && swaps > 0) {\r\n const temp = address[compress + swaps - 1];\r\n address[compress + swaps - 1] = address[pieceIndex];\r\n address[pieceIndex] = temp;\r\n --pieceIndex;\r\n --swaps;\r\n }\r\n } else if (compress === null && pieceIndex !== 8) {\r\n return failure;\r\n }\r\n\r\n return address;\r\n}\r\n\r\nfunction serializeIPv6(address) {\r\n let output = \"\";\r\n const seqResult = findLongestZeroSequence(address);\r\n const compress = seqResult.idx;\r\n let ignore0 = false;\r\n\r\n for (let pieceIndex = 0; pieceIndex <= 7; ++pieceIndex) {\r\n if (ignore0 && address[pieceIndex] === 0) {\r\n continue;\r\n } else if (ignore0) {\r\n ignore0 = false;\r\n }\r\n\r\n if (compress === pieceIndex) {\r\n const separator = pieceIndex === 0 ? \"::\" : \":\";\r\n output += separator;\r\n ignore0 = true;\r\n continue;\r\n }\r\n\r\n output += address[pieceIndex].toString(16);\r\n\r\n if (pieceIndex !== 7) {\r\n output += \":\";\r\n }\r\n }\r\n\r\n return output;\r\n}\r\n\r\nfunction parseHost(input, isSpecialArg) {\r\n if (input[0] === \"[\") {\r\n if (input[input.length - 1] !== \"]\") {\r\n return failure;\r\n }\r\n\r\n return parseIPv6(input.substring(1, input.length - 1));\r\n }\r\n\r\n if (!isSpecialArg) {\r\n return parseOpaqueHost(input);\r\n }\r\n\r\n const domain = utf8PercentDecode(input);\r\n const asciiDomain = tr46.toASCII(domain, false, tr46.PROCESSING_OPTIONS.NONTRANSITIONAL, false);\r\n if (asciiDomain === null) {\r\n return failure;\r\n }\r\n\r\n if (containsForbiddenHostCodePoint(asciiDomain)) {\r\n return failure;\r\n }\r\n\r\n const ipv4Host = parseIPv4(asciiDomain);\r\n if (typeof ipv4Host === \"number\" || ipv4Host === failure) {\r\n return ipv4Host;\r\n }\r\n\r\n return asciiDomain;\r\n}\r\n\r\nfunction parseOpaqueHost(input) {\r\n if (containsForbiddenHostCodePointExcludingPercent(input)) {\r\n return failure;\r\n }\r\n\r\n let output = \"\";\r\n const decoded = punycode.ucs2.decode(input);\r\n for (let i = 0; i < decoded.length; ++i) {\r\n output += percentEncodeChar(decoded[i], isC0ControlPercentEncode);\r\n }\r\n return output;\r\n}\r\n\r\nfunction findLongestZeroSequence(arr) {\r\n let maxIdx = null;\r\n let maxLen = 1; // only find elements > 1\r\n let currStart = null;\r\n let currLen = 0;\r\n\r\n for (let i = 0; i < arr.length; ++i) {\r\n if (arr[i] !== 0) {\r\n if (currLen > maxLen) {\r\n maxIdx = currStart;\r\n maxLen = currLen;\r\n }\r\n\r\n currStart = null;\r\n currLen = 0;\r\n } else {\r\n if (currStart === null) {\r\n currStart = i;\r\n }\r\n ++currLen;\r\n }\r\n }\r\n\r\n // if trailing zeros\r\n if (currLen > maxLen) {\r\n maxIdx = currStart;\r\n maxLen = currLen;\r\n }\r\n\r\n return {\r\n idx: maxIdx,\r\n len: maxLen\r\n };\r\n}\r\n\r\nfunction serializeHost(host) {\r\n if (typeof host === \"number\") {\r\n return serializeIPv4(host);\r\n }\r\n\r\n // IPv6 serializer\r\n if (host instanceof Array) {\r\n return \"[\" + serializeIPv6(host) + \"]\";\r\n }\r\n\r\n return host;\r\n}\r\n\r\nfunction trimControlChars(url) {\r\n return url.replace(/^[\\u0000-\\u001F\\u0020]+|[\\u0000-\\u001F\\u0020]+$/g, \"\");\r\n}\r\n\r\nfunction trimTabAndNewline(url) {\r\n return url.replace(/\\u0009|\\u000A|\\u000D/g, \"\");\r\n}\r\n\r\nfunction shortenPath(url) {\r\n const path = url.path;\r\n if (path.length === 0) {\r\n return;\r\n }\r\n if (url.scheme === \"file\" && path.length === 1 && isNormalizedWindowsDriveLetter(path[0])) {\r\n return;\r\n }\r\n\r\n path.pop();\r\n}\r\n\r\nfunction includesCredentials(url) {\r\n return url.username !== \"\" || url.password !== \"\";\r\n}\r\n\r\nfunction cannotHaveAUsernamePasswordPort(url) {\r\n return url.host === null || url.host === \"\" || url.cannotBeABaseURL || url.scheme === \"file\";\r\n}\r\n\r\nfunction isNormalizedWindowsDriveLetter(string) {\r\n return /^[A-Za-z]:$/.test(string);\r\n}\r\n\r\nfunction URLStateMachine(input, base, encodingOverride, url, stateOverride) {\r\n this.pointer = 0;\r\n this.input = input;\r\n this.base = base || null;\r\n this.encodingOverride = encodingOverride || \"utf-8\";\r\n this.stateOverride = stateOverride;\r\n this.url = url;\r\n this.failure = false;\r\n this.parseError = false;\r\n\r\n if (!this.url) {\r\n this.url = {\r\n scheme: \"\",\r\n username: \"\",\r\n password: \"\",\r\n host: null,\r\n port: null,\r\n path: [],\r\n query: null,\r\n fragment: null,\r\n\r\n cannotBeABaseURL: false\r\n };\r\n\r\n const res = trimControlChars(this.input);\r\n if (res !== this.input) {\r\n this.parseError = true;\r\n }\r\n this.input = res;\r\n }\r\n\r\n const res = trimTabAndNewline(this.input);\r\n if (res !== this.input) {\r\n this.parseError = true;\r\n }\r\n this.input = res;\r\n\r\n this.state = stateOverride || \"scheme start\";\r\n\r\n this.buffer = \"\";\r\n this.atFlag = false;\r\n this.arrFlag = false;\r\n this.passwordTokenSeenFlag = false;\r\n\r\n this.input = punycode.ucs2.decode(this.input);\r\n\r\n for (; this.pointer <= this.input.length; ++this.pointer) {\r\n const c = this.input[this.pointer];\r\n const cStr = isNaN(c) ? undefined : String.fromCodePoint(c);\r\n\r\n // exec state machine\r\n const ret = this[\"parse \" + this.state](c, cStr);\r\n if (!ret) {\r\n break; // terminate algorithm\r\n } else if (ret === failure) {\r\n this.failure = true;\r\n break;\r\n }\r\n }\r\n}\r\n\r\nURLStateMachine.prototype[\"parse scheme start\"] = function parseSchemeStart(c, cStr) {\r\n if (isASCIIAlpha(c)) {\r\n this.buffer += cStr.toLowerCase();\r\n this.state = \"scheme\";\r\n } else if (!this.stateOverride) {\r\n this.state = \"no scheme\";\r\n --this.pointer;\r\n } else {\r\n this.parseError = true;\r\n return failure;\r\n }\r\n\r\n return true;\r\n};\r\n\r\nURLStateMachine.prototype[\"parse scheme\"] = function parseScheme(c, cStr) {\r\n if (isASCIIAlphanumeric(c) || c === 43 || c === 45 || c === 46) {\r\n this.buffer += cStr.toLowerCase();\r\n } else if (c === 58) {\r\n if (this.stateOverride) {\r\n if (isSpecial(this.url) && !isSpecialScheme(this.buffer)) {\r\n return false;\r\n }\r\n\r\n if (!isSpecial(this.url) && isSpecialScheme(this.buffer)) {\r\n return false;\r\n }\r\n\r\n if ((includesCredentials(this.url) || this.url.port !== null) && this.buffer === \"file\") {\r\n return false;\r\n }\r\n\r\n if (this.url.scheme === \"file\" && (this.url.host === \"\" || this.url.host === null)) {\r\n return false;\r\n }\r\n }\r\n this.url.scheme = this.buffer;\r\n this.buffer = \"\";\r\n if (this.stateOverride) {\r\n return false;\r\n }\r\n if (this.url.scheme === \"file\") {\r\n if (this.input[this.pointer + 1] !== 47 || this.input[this.pointer + 2] !== 47) {\r\n this.parseError = true;\r\n }\r\n this.state = \"file\";\r\n } else if (isSpecial(this.url) && this.base !== null && this.base.scheme === this.url.scheme) {\r\n this.state = \"special relative or authority\";\r\n } else if (isSpecial(this.url)) {\r\n this.state = \"special authority slashes\";\r\n } else if (this.input[this.pointer + 1] === 47) {\r\n this.state = \"path or authority\";\r\n ++this.pointer;\r\n } else {\r\n this.url.cannotBeABaseURL = true;\r\n this.url.path.push(\"\");\r\n this.state = \"cannot-be-a-base-URL path\";\r\n }\r\n } else if (!this.stateOverride) {\r\n this.buffer = \"\";\r\n this.state = \"no scheme\";\r\n this.pointer = -1;\r\n } else {\r\n this.parseError = true;\r\n return failure;\r\n }\r\n\r\n return true;\r\n};\r\n\r\nURLStateMachine.prototype[\"parse no scheme\"] = function parseNoScheme(c) {\r\n if (this.base === null || (this.base.cannotBeABaseURL && c !== 35)) {\r\n return failure;\r\n } else if (this.base.cannotBeABaseURL && c === 35) {\r\n this.url.scheme = this.base.scheme;\r\n this.url.path = this.base.path.slice();\r\n this.url.query = this.base.query;\r\n this.url.fragment = \"\";\r\n this.url.cannotBeABaseURL = true;\r\n this.state = \"fragment\";\r\n } else if (this.base.scheme === \"file\") {\r\n this.state = \"file\";\r\n --this.pointer;\r\n } else {\r\n this.state = \"relative\";\r\n --this.pointer;\r\n }\r\n\r\n return true;\r\n};\r\n\r\nURLStateMachine.prototype[\"parse special relative or authority\"] = function parseSpecialRelativeOrAuthority(c) {\r\n if (c === 47 && this.input[this.pointer + 1] === 47) {\r\n this.state = \"special authority ignore slashes\";\r\n ++this.pointer;\r\n } else {\r\n this.parseError = true;\r\n this.state = \"relative\";\r\n --this.pointer;\r\n }\r\n\r\n return true;\r\n};\r\n\r\nURLStateMachine.prototype[\"parse path or authority\"] = function parsePathOrAuthority(c) {\r\n if (c === 47) {\r\n this.state = \"authority\";\r\n } else {\r\n this.state = \"path\";\r\n --this.pointer;\r\n }\r\n\r\n return true;\r\n};\r\n\r\nURLStateMachine.prototype[\"parse relative\"] = function parseRelative(c) {\r\n this.url.scheme = this.base.scheme;\r\n if (isNaN(c)) {\r\n this.url.username = this.base.username;\r\n this.url.password = this.base.password;\r\n this.url.host = this.base.host;\r\n this.url.port = this.base.port;\r\n this.url.path = this.base.path.slice();\r\n this.url.query = this.base.query;\r\n } else if (c === 47) {\r\n this.state = \"relative slash\";\r\n } else if (c === 63) {\r\n this.url.username = this.base.username;\r\n this.url.password = this.base.password;\r\n this.url.host = this.base.host;\r\n this.url.port = this.base.port;\r\n this.url.path = this.base.path.slice();\r\n this.url.query = \"\";\r\n this.state = \"query\";\r\n } else if (c === 35) {\r\n this.url.username = this.base.username;\r\n this.url.password = this.base.password;\r\n this.url.host = this.base.host;\r\n this.url.port = this.base.port;\r\n this.url.path = this.base.path.slice();\r\n this.url.query = this.base.query;\r\n this.url.fragment = \"\";\r\n this.state = \"fragment\";\r\n } else if (isSpecial(this.url) && c === 92) {\r\n this.parseError = true;\r\n this.state = \"relative slash\";\r\n } else {\r\n this.url.username = this.base.username;\r\n this.url.password = this.base.password;\r\n this.url.host = this.base.host;\r\n this.url.port = this.base.port;\r\n this.url.path = this.base.path.slice(0, this.base.path.length - 1);\r\n\r\n this.state = \"path\";\r\n --this.pointer;\r\n }\r\n\r\n return true;\r\n};\r\n\r\nURLStateMachine.prototype[\"parse relative slash\"] = function parseRelativeSlash(c) {\r\n if (isSpecial(this.url) && (c === 47 || c === 92)) {\r\n if (c === 92) {\r\n this.parseError = true;\r\n }\r\n this.state = \"special authority ignore slashes\";\r\n } else if (c === 47) {\r\n this.state = \"authority\";\r\n } else {\r\n this.url.username = this.base.username;\r\n this.url.password = this.base.password;\r\n this.url.host = this.base.host;\r\n this.url.port = this.base.port;\r\n this.state = \"path\";\r\n --this.pointer;\r\n }\r\n\r\n return true;\r\n};\r\n\r\nURLStateMachine.prototype[\"parse special authority slashes\"] = function parseSpecialAuthoritySlashes(c) {\r\n if (c === 47 && this.input[this.pointer + 1] === 47) {\r\n this.state = \"special authority ignore slashes\";\r\n ++this.pointer;\r\n } else {\r\n this.parseError = true;\r\n this.state = \"special authority ignore slashes\";\r\n --this.pointer;\r\n }\r\n\r\n return true;\r\n};\r\n\r\nURLStateMachine.prototype[\"parse special authority ignore slashes\"] = function parseSpecialAuthorityIgnoreSlashes(c) {\r\n if (c !== 47 && c !== 92) {\r\n this.state = \"authority\";\r\n --this.pointer;\r\n } else {\r\n this.parseError = true;\r\n }\r\n\r\n return true;\r\n};\r\n\r\nURLStateMachine.prototype[\"parse authority\"] = function parseAuthority(c, cStr) {\r\n if (c === 64) {\r\n this.parseError = true;\r\n if (this.atFlag) {\r\n this.buffer = \"%40\" + this.buffer;\r\n }\r\n this.atFlag = true;\r\n\r\n // careful, this is based on buffer and has its own pointer (this.pointer != pointer) and inner chars\r\n const len = countSymbols(this.buffer);\r\n for (let pointer = 0; pointer < len; ++pointer) {\r\n const codePoint = this.buffer.codePointAt(pointer);\r\n\r\n if (codePoint === 58 && !this.passwordTokenSeenFlag) {\r\n this.passwordTokenSeenFlag = true;\r\n continue;\r\n }\r\n const encodedCodePoints = percentEncodeChar(codePoint, isUserinfoPercentEncode);\r\n if (this.passwordTokenSeenFlag) {\r\n this.url.password += encodedCodePoints;\r\n } else {\r\n this.url.username += encodedCodePoints;\r\n }\r\n }\r\n this.buffer = \"\";\r\n } else if (isNaN(c) || c === 47 || c === 63 || c === 35 ||\r\n (isSpecial(this.url) && c === 92)) {\r\n if (this.atFlag && this.buffer === \"\") {\r\n this.parseError = true;\r\n return failure;\r\n }\r\n this.pointer -= countSymbols(this.buffer) + 1;\r\n this.buffer = \"\";\r\n this.state = \"host\";\r\n } else {\r\n this.buffer += cStr;\r\n }\r\n\r\n return true;\r\n};\r\n\r\nURLStateMachine.prototype[\"parse hostname\"] =\r\nURLStateMachine.prototype[\"parse host\"] = function parseHostName(c, cStr) {\r\n if (this.stateOverride && this.url.scheme === \"file\") {\r\n --this.pointer;\r\n this.state = \"file host\";\r\n } else if (c === 58 && !this.arrFlag) {\r\n if (this.buffer === \"\") {\r\n this.parseError = true;\r\n return failure;\r\n }\r\n\r\n const host = parseHost(this.buffer, isSpecial(this.url));\r\n if (host === failure) {\r\n return failure;\r\n }\r\n\r\n this.url.host = host;\r\n this.buffer = \"\";\r\n this.state = \"port\";\r\n if (this.stateOverride === \"hostname\") {\r\n return false;\r\n }\r\n } else if (isNaN(c) || c === 47 || c === 63 || c === 35 ||\r\n (isSpecial(this.url) && c === 92)) {\r\n --this.pointer;\r\n if (isSpecial(this.url) && this.buffer === \"\") {\r\n this.parseError = true;\r\n return failure;\r\n } else if (this.stateOverride && this.buffer === \"\" &&\r\n (includesCredentials(this.url) || this.url.port !== null)) {\r\n this.parseError = true;\r\n return false;\r\n }\r\n\r\n const host = parseHost(this.buffer, isSpecial(this.url));\r\n if (host === failure) {\r\n return failure;\r\n }\r\n\r\n this.url.host = host;\r\n this.buffer = \"\";\r\n this.state = \"path start\";\r\n if (this.stateOverride) {\r\n return false;\r\n }\r\n } else {\r\n if (c === 91) {\r\n this.arrFlag = true;\r\n } else if (c === 93) {\r\n this.arrFlag = false;\r\n }\r\n this.buffer += cStr;\r\n }\r\n\r\n return true;\r\n};\r\n\r\nURLStateMachine.prototype[\"parse port\"] = function parsePort(c, cStr) {\r\n if (isASCIIDigit(c)) {\r\n this.buffer += cStr;\r\n } else if (isNaN(c) || c === 47 || c === 63 || c === 35 ||\r\n (isSpecial(this.url) && c === 92) ||\r\n this.stateOverride) {\r\n if (this.buffer !== \"\") {\r\n const port = parseInt(this.buffer);\r\n if (port > Math.pow(2, 16) - 1) {\r\n this.parseError = true;\r\n return failure;\r\n }\r\n this.url.port = port === defaultPort(this.url.scheme) ? null : port;\r\n this.buffer = \"\";\r\n }\r\n if (this.stateOverride) {\r\n return false;\r\n }\r\n this.state = \"path start\";\r\n --this.pointer;\r\n } else {\r\n this.parseError = true;\r\n return failure;\r\n }\r\n\r\n return true;\r\n};\r\n\r\nconst fileOtherwiseCodePoints = new Set([47, 92, 63, 35]);\r\n\r\nURLStateMachine.prototype[\"parse file\"] = function parseFile(c) {\r\n this.url.scheme = \"file\";\r\n\r\n if (c === 47 || c === 92) {\r\n if (c === 92) {\r\n this.parseError = true;\r\n }\r\n this.state = \"file slash\";\r\n } else if (this.base !== null && this.base.scheme === \"file\") {\r\n if (isNaN(c)) {\r\n this.url.host = this.base.host;\r\n this.url.path = this.base.path.slice();\r\n this.url.query = this.base.query;\r\n } else if (c === 63) {\r\n this.url.host = this.base.host;\r\n this.url.path = this.base.path.slice();\r\n this.url.query = \"\";\r\n this.state = \"query\";\r\n } else if (c === 35) {\r\n this.url.host = this.base.host;\r\n this.url.path = this.base.path.slice();\r\n this.url.query = this.base.query;\r\n this.url.fragment = \"\";\r\n this.state = \"fragment\";\r\n } else {\r\n if (this.input.length - this.pointer - 1 === 0 || // remaining consists of 0 code points\r\n !isWindowsDriveLetterCodePoints(c, this.input[this.pointer + 1]) ||\r\n (this.input.length - this.pointer - 1 >= 2 && // remaining has at least 2 code points\r\n !fileOtherwiseCodePoints.has(this.input[this.pointer + 2]))) {\r\n this.url.host = this.base.host;\r\n this.url.path = this.base.path.slice();\r\n shortenPath(this.url);\r\n } else {\r\n this.parseError = true;\r\n }\r\n\r\n this.state = \"path\";\r\n --this.pointer;\r\n }\r\n } else {\r\n this.state = \"path\";\r\n --this.pointer;\r\n }\r\n\r\n return true;\r\n};\r\n\r\nURLStateMachine.prototype[\"parse file slash\"] = function parseFileSlash(c) {\r\n if (c === 47 || c === 92) {\r\n if (c === 92) {\r\n this.parseError = true;\r\n }\r\n this.state = \"file host\";\r\n } else {\r\n if (this.base !== null && this.base.scheme === \"file\") {\r\n if (isNormalizedWindowsDriveLetterString(this.base.path[0])) {\r\n this.url.path.push(this.base.path[0]);\r\n } else {\r\n this.url.host = this.base.host;\r\n }\r\n }\r\n this.state = \"path\";\r\n --this.pointer;\r\n }\r\n\r\n return true;\r\n};\r\n\r\nURLStateMachine.prototype[\"parse file host\"] = function parseFileHost(c, cStr) {\r\n if (isNaN(c) || c === 47 || c === 92 || c === 63 || c === 35) {\r\n --this.pointer;\r\n if (!this.stateOverride && isWindowsDriveLetterString(this.buffer)) {\r\n this.parseError = true;\r\n this.state = \"path\";\r\n } else if (this.buffer === \"\") {\r\n this.url.host = \"\";\r\n if (this.stateOverride) {\r\n return false;\r\n }\r\n this.state = \"path start\";\r\n } else {\r\n let host = parseHost(this.buffer, isSpecial(this.url));\r\n if (host === failure) {\r\n return failure;\r\n }\r\n if (host === \"localhost\") {\r\n host = \"\";\r\n }\r\n this.url.host = host;\r\n\r\n if (this.stateOverride) {\r\n return false;\r\n }\r\n\r\n this.buffer = \"\";\r\n this.state = \"path start\";\r\n }\r\n } else {\r\n this.buffer += cStr;\r\n }\r\n\r\n return true;\r\n};\r\n\r\nURLStateMachine.prototype[\"parse path start\"] = function parsePathStart(c) {\r\n if (isSpecial(this.url)) {\r\n if (c === 92) {\r\n this.parseError = true;\r\n }\r\n this.state = \"path\";\r\n\r\n if (c !== 47 && c !== 92) {\r\n --this.pointer;\r\n }\r\n } else if (!this.stateOverride && c === 63) {\r\n this.url.query = \"\";\r\n this.state = \"query\";\r\n } else if (!this.stateOverride && c === 35) {\r\n this.url.fragment = \"\";\r\n this.state = \"fragment\";\r\n } else if (c !== undefined) {\r\n this.state = \"path\";\r\n if (c !== 47) {\r\n --this.pointer;\r\n }\r\n }\r\n\r\n return true;\r\n};\r\n\r\nURLStateMachine.prototype[\"parse path\"] = function parsePath(c) {\r\n if (isNaN(c) || c === 47 || (isSpecial(this.url) && c === 92) ||\r\n (!this.stateOverride && (c === 63 || c === 35))) {\r\n if (isSpecial(this.url) && c === 92) {\r\n this.parseError = true;\r\n }\r\n\r\n if (isDoubleDot(this.buffer)) {\r\n shortenPath(this.url);\r\n if (c !== 47 && !(isSpecial(this.url) && c === 92)) {\r\n this.url.path.push(\"\");\r\n }\r\n } else if (isSingleDot(this.buffer) && c !== 47 &&\r\n !(isSpecial(this.url) && c === 92)) {\r\n this.url.path.push(\"\");\r\n } else if (!isSingleDot(this.buffer)) {\r\n if (this.url.scheme === \"file\" && this.url.path.length === 0 && isWindowsDriveLetterString(this.buffer)) {\r\n if (this.url.host !== \"\" && this.url.host !== null) {\r\n this.parseError = true;\r\n this.url.host = \"\";\r\n }\r\n this.buffer = this.buffer[0] + \":\";\r\n }\r\n this.url.path.push(this.buffer);\r\n }\r\n this.buffer = \"\";\r\n if (this.url.scheme === \"file\" && (c === undefined || c === 63 || c === 35)) {\r\n while (this.url.path.length > 1 && this.url.path[0] === \"\") {\r\n this.parseError = true;\r\n this.url.path.shift();\r\n }\r\n }\r\n if (c === 63) {\r\n this.url.query = \"\";\r\n this.state = \"query\";\r\n }\r\n if (c === 35) {\r\n this.url.fragment = \"\";\r\n this.state = \"fragment\";\r\n }\r\n } else {\r\n // TODO: If c is not a URL code point and not \"%\", parse error.\r\n\r\n if (c === 37 &&\r\n (!isASCIIHex(this.input[this.pointer + 1]) ||\r\n !isASCIIHex(this.input[this.pointer + 2]))) {\r\n this.parseError = true;\r\n }\r\n\r\n this.buffer += percentEncodeChar(c, isPathPercentEncode);\r\n }\r\n\r\n return true;\r\n};\r\n\r\nURLStateMachine.prototype[\"parse cannot-be-a-base-URL path\"] = function parseCannotBeABaseURLPath(c) {\r\n if (c === 63) {\r\n this.url.query = \"\";\r\n this.state = \"query\";\r\n } else if (c === 35) {\r\n this.url.fragment = \"\";\r\n this.state = \"fragment\";\r\n } else {\r\n // TODO: Add: not a URL code point\r\n if (!isNaN(c) && c !== 37) {\r\n this.parseError = true;\r\n }\r\n\r\n if (c === 37 &&\r\n (!isASCIIHex(this.input[this.pointer + 1]) ||\r\n !isASCIIHex(this.input[this.pointer + 2]))) {\r\n this.parseError = true;\r\n }\r\n\r\n if (!isNaN(c)) {\r\n this.url.path[0] = this.url.path[0] + percentEncodeChar(c, isC0ControlPercentEncode);\r\n }\r\n }\r\n\r\n return true;\r\n};\r\n\r\nURLStateMachine.prototype[\"parse query\"] = function parseQuery(c, cStr) {\r\n if (isNaN(c) || (!this.stateOverride && c === 35)) {\r\n if (!isSpecial(this.url) || this.url.scheme === \"ws\" || this.url.scheme === \"wss\") {\r\n this.encodingOverride = \"utf-8\";\r\n }\r\n\r\n const buffer = new Buffer(this.buffer); // TODO: Use encoding override instead\r\n for (let i = 0; i < buffer.length; ++i) {\r\n if (buffer[i] < 0x21 || buffer[i] > 0x7E || buffer[i] === 0x22 || buffer[i] === 0x23 ||\r\n buffer[i] === 0x3C || buffer[i] === 0x3E) {\r\n this.url.query += percentEncode(buffer[i]);\r\n } else {\r\n this.url.query += String.fromCodePoint(buffer[i]);\r\n }\r\n }\r\n\r\n this.buffer = \"\";\r\n if (c === 35) {\r\n this.url.fragment = \"\";\r\n this.state = \"fragment\";\r\n }\r\n } else {\r\n // TODO: If c is not a URL code point and not \"%\", parse error.\r\n if (c === 37 &&\r\n (!isASCIIHex(this.input[this.pointer + 1]) ||\r\n !isASCIIHex(this.input[this.pointer + 2]))) {\r\n this.parseError = true;\r\n }\r\n\r\n this.buffer += cStr;\r\n }\r\n\r\n return true;\r\n};\r\n\r\nURLStateMachine.prototype[\"parse fragment\"] = function parseFragment(c) {\r\n if (isNaN(c)) { // do nothing\r\n } else if (c === 0x0) {\r\n this.parseError = true;\r\n } else {\r\n // TODO: If c is not a URL code point and not \"%\", parse error.\r\n if (c === 37 &&\r\n (!isASCIIHex(this.input[this.pointer + 1]) ||\r\n !isASCIIHex(this.input[this.pointer + 2]))) {\r\n this.parseError = true;\r\n }\r\n\r\n this.url.fragment += percentEncodeChar(c, isC0ControlPercentEncode);\r\n }\r\n\r\n return true;\r\n};\r\n\r\nfunction serializeURL(url, excludeFragment) {\r\n let output = url.scheme + \":\";\r\n if (url.host !== null) {\r\n output += \"//\";\r\n\r\n if (url.username !== \"\" || url.password !== \"\") {\r\n output += url.username;\r\n if (url.password !== \"\") {\r\n output += \":\" + url.password;\r\n }\r\n output += \"@\";\r\n }\r\n\r\n output += serializeHost(url.host);\r\n\r\n if (url.port !== null) {\r\n output += \":\" + url.port;\r\n }\r\n } else if (url.host === null && url.scheme === \"file\") {\r\n output += \"//\";\r\n }\r\n\r\n if (url.cannotBeABaseURL) {\r\n output += url.path[0];\r\n } else {\r\n for (const string of url.path) {\r\n output += \"/\" + string;\r\n }\r\n }\r\n\r\n if (url.query !== null) {\r\n output += \"?\" + url.query;\r\n }\r\n\r\n if (!excludeFragment && url.fragment !== null) {\r\n output += \"#\" + url.fragment;\r\n }\r\n\r\n return output;\r\n}\r\n\r\nfunction serializeOrigin(tuple) {\r\n let result = tuple.scheme + \"://\";\r\n result += serializeHost(tuple.host);\r\n\r\n if (tuple.port !== null) {\r\n result += \":\" + tuple.port;\r\n }\r\n\r\n return result;\r\n}\r\n\r\nmodule.exports.serializeURL = serializeURL;\r\n\r\nmodule.exports.serializeURLOrigin = function (url) {\r\n // https://url.spec.whatwg.org/#concept-url-origin\r\n switch (url.scheme) {\r\n case \"blob\":\r\n try {\r\n return module.exports.serializeURLOrigin(module.exports.parseURL(url.path[0]));\r\n } catch (e) {\r\n // serializing an opaque origin returns \"null\"\r\n return \"null\";\r\n }\r\n case \"ftp\":\r\n case \"gopher\":\r\n case \"http\":\r\n case \"https\":\r\n case \"ws\":\r\n case \"wss\":\r\n return serializeOrigin({\r\n scheme: url.scheme,\r\n host: url.host,\r\n port: url.port\r\n });\r\n case \"file\":\r\n // spec says \"exercise to the reader\", chrome says \"file://\"\r\n return \"file://\";\r\n default:\r\n // serializing an opaque origin returns \"null\"\r\n return \"null\";\r\n }\r\n};\r\n\r\nmodule.exports.basicURLParse = function (input, options) {\r\n if (options === undefined) {\r\n options = {};\r\n }\r\n\r\n const usm = new URLStateMachine(input, options.baseURL, options.encodingOverride, options.url, options.stateOverride);\r\n if (usm.failure) {\r\n return \"failure\";\r\n }\r\n\r\n return usm.url;\r\n};\r\n\r\nmodule.exports.setTheUsername = function (url, username) {\r\n url.username = \"\";\r\n const decoded = punycode.ucs2.decode(username);\r\n for (let i = 0; i < decoded.length; ++i) {\r\n url.username += percentEncodeChar(decoded[i], isUserinfoPercentEncode);\r\n }\r\n};\r\n\r\nmodule.exports.setThePassword = function (url, password) {\r\n url.password = \"\";\r\n const decoded = punycode.ucs2.decode(password);\r\n for (let i = 0; i < decoded.length; ++i) {\r\n url.password += percentEncodeChar(decoded[i], isUserinfoPercentEncode);\r\n }\r\n};\r\n\r\nmodule.exports.serializeHost = serializeHost;\r\n\r\nmodule.exports.cannotHaveAUsernamePasswordPort = cannotHaveAUsernamePasswordPort;\r\n\r\nmodule.exports.serializeInteger = function (integer) {\r\n return String(integer);\r\n};\r\n\r\nmodule.exports.parseURL = function (input, options) {\r\n if (options === undefined) {\r\n options = {};\r\n }\r\n\r\n // We don't handle blobs, so this just delegates:\r\n return module.exports.basicURLParse(input, { baseURL: options.baseURL, encodingOverride: options.encodingOverride });\r\n};\r\n", "\"use strict\";\nconst usm = require(\"./url-state-machine\");\n\nexports.implementation = class URLImpl {\n constructor(constructorArgs) {\n const url = constructorArgs[0];\n const base = constructorArgs[1];\n\n let parsedBase = null;\n if (base !== undefined) {\n parsedBase = usm.basicURLParse(base);\n if (parsedBase === \"failure\") {\n throw new TypeError(\"Invalid base URL\");\n }\n }\n\n const parsedURL = usm.basicURLParse(url, { baseURL: parsedBase });\n if (parsedURL === \"failure\") {\n throw new TypeError(\"Invalid URL\");\n }\n\n this._url = parsedURL;\n\n // TODO: query stuff\n }\n\n get href() {\n return usm.serializeURL(this._url);\n }\n\n set href(v) {\n const parsedURL = usm.basicURLParse(v);\n if (parsedURL === \"failure\") {\n throw new TypeError(\"Invalid URL\");\n }\n\n this._url = parsedURL;\n }\n\n get origin() {\n return usm.serializeURLOrigin(this._url);\n }\n\n get protocol() {\n return this._url.scheme + \":\";\n }\n\n set protocol(v) {\n usm.basicURLParse(v + \":\", { url: this._url, stateOverride: \"scheme start\" });\n }\n\n get username() {\n return this._url.username;\n }\n\n set username(v) {\n if (usm.cannotHaveAUsernamePasswordPort(this._url)) {\n return;\n }\n\n usm.setTheUsername(this._url, v);\n }\n\n get password() {\n return this._url.password;\n }\n\n set password(v) {\n if (usm.cannotHaveAUsernamePasswordPort(this._url)) {\n return;\n }\n\n usm.setThePassword(this._url, v);\n }\n\n get host() {\n const url = this._url;\n\n if (url.host === null) {\n return \"\";\n }\n\n if (url.port === null) {\n return usm.serializeHost(url.host);\n }\n\n return usm.serializeHost(url.host) + \":\" + usm.serializeInteger(url.port);\n }\n\n set host(v) {\n if (this._url.cannotBeABaseURL) {\n return;\n }\n\n usm.basicURLParse(v, { url: this._url, stateOverride: \"host\" });\n }\n\n get hostname() {\n if (this._url.host === null) {\n return \"\";\n }\n\n return usm.serializeHost(this._url.host);\n }\n\n set hostname(v) {\n if (this._url.cannotBeABaseURL) {\n return;\n }\n\n usm.basicURLParse(v, { url: this._url, stateOverride: \"hostname\" });\n }\n\n get port() {\n if (this._url.port === null) {\n return \"\";\n }\n\n return usm.serializeInteger(this._url.port);\n }\n\n set port(v) {\n if (usm.cannotHaveAUsernamePasswordPort(this._url)) {\n return;\n }\n\n if (v === \"\") {\n this._url.port = null;\n } else {\n usm.basicURLParse(v, { url: this._url, stateOverride: \"port\" });\n }\n }\n\n get pathname() {\n if (this._url.cannotBeABaseURL) {\n return this._url.path[0];\n }\n\n if (this._url.path.length === 0) {\n return \"\";\n }\n\n return \"/\" + this._url.path.join(\"/\");\n }\n\n set pathname(v) {\n if (this._url.cannotBeABaseURL) {\n return;\n }\n\n this._url.path = [];\n usm.basicURLParse(v, { url: this._url, stateOverride: \"path start\" });\n }\n\n get search() {\n if (this._url.query === null || this._url.query === \"\") {\n return \"\";\n }\n\n return \"?\" + this._url.query;\n }\n\n set search(v) {\n // TODO: query stuff\n\n const url = this._url;\n\n if (v === \"\") {\n url.query = null;\n return;\n }\n\n const input = v[0] === \"?\" ? v.substring(1) : v;\n url.query = \"\";\n usm.basicURLParse(input, { url, stateOverride: \"query\" });\n }\n\n get hash() {\n if (this._url.fragment === null || this._url.fragment === \"\") {\n return \"\";\n }\n\n return \"#\" + this._url.fragment;\n }\n\n set hash(v) {\n if (v === \"\") {\n this._url.fragment = null;\n return;\n }\n\n const input = v[0] === \"#\" ? v.substring(1) : v;\n this._url.fragment = \"\";\n usm.basicURLParse(input, { url: this._url, stateOverride: \"fragment\" });\n }\n\n toJSON() {\n return this.href;\n }\n};\n", "\"use strict\";\n\nconst conversions = require(\"webidl-conversions\");\nconst utils = require(\"./utils.js\");\nconst Impl = require(\".//URL-impl.js\");\n\nconst impl = utils.implSymbol;\n\nfunction URL(url) {\n if (!this || this[impl] || !(this instanceof URL)) {\n throw new TypeError(\"Failed to construct 'URL': Please use the 'new' operator, this DOM object constructor cannot be called as a function.\");\n }\n if (arguments.length < 1) {\n throw new TypeError(\"Failed to construct 'URL': 1 argument required, but only \" + arguments.length + \" present.\");\n }\n const args = [];\n for (let i = 0; i < arguments.length && i < 2; ++i) {\n args[i] = arguments[i];\n }\n args[0] = conversions[\"USVString\"](args[0]);\n if (args[1] !== undefined) {\n args[1] = conversions[\"USVString\"](args[1]);\n }\n\n module.exports.setup(this, args);\n}\n\nURL.prototype.toJSON = function toJSON() {\n if (!this || !module.exports.is(this)) {\n throw new TypeError(\"Illegal invocation\");\n }\n const args = [];\n for (let i = 0; i < arguments.length && i < 0; ++i) {\n args[i] = arguments[i];\n }\n return this[impl].toJSON.apply(this[impl], args);\n};\nObject.defineProperty(URL.prototype, \"href\", {\n get() {\n return this[impl].href;\n },\n set(V) {\n V = conversions[\"USVString\"](V);\n this[impl].href = V;\n },\n enumerable: true,\n configurable: true\n});\n\nURL.prototype.toString = function () {\n if (!this || !module.exports.is(this)) {\n throw new TypeError(\"Illegal invocation\");\n }\n return this.href;\n};\n\nObject.defineProperty(URL.prototype, \"origin\", {\n get() {\n return this[impl].origin;\n },\n enumerable: true,\n configurable: true\n});\n\nObject.defineProperty(URL.prototype, \"protocol\", {\n get() {\n return this[impl].protocol;\n },\n set(V) {\n V = conversions[\"USVString\"](V);\n this[impl].protocol = V;\n },\n enumerable: true,\n configurable: true\n});\n\nObject.defineProperty(URL.prototype, \"username\", {\n get() {\n return this[impl].username;\n },\n set(V) {\n V = conversions[\"USVString\"](V);\n this[impl].username = V;\n },\n enumerable: true,\n configurable: true\n});\n\nObject.defineProperty(URL.prototype, \"password\", {\n get() {\n return this[impl].password;\n },\n set(V) {\n V = conversions[\"USVString\"](V);\n this[impl].password = V;\n },\n enumerable: true,\n configurable: true\n});\n\nObject.defineProperty(URL.prototype, \"host\", {\n get() {\n return this[impl].host;\n },\n set(V) {\n V = conversions[\"USVString\"](V);\n this[impl].host = V;\n },\n enumerable: true,\n configurable: true\n});\n\nObject.defineProperty(URL.prototype, \"hostname\", {\n get() {\n return this[impl].hostname;\n },\n set(V) {\n V = conversions[\"USVString\"](V);\n this[impl].hostname = V;\n },\n enumerable: true,\n configurable: true\n});\n\nObject.defineProperty(URL.prototype, \"port\", {\n get() {\n return this[impl].port;\n },\n set(V) {\n V = conversions[\"USVString\"](V);\n this[impl].port = V;\n },\n enumerable: true,\n configurable: true\n});\n\nObject.defineProperty(URL.prototype, \"pathname\", {\n get() {\n return this[impl].pathname;\n },\n set(V) {\n V = conversions[\"USVString\"](V);\n this[impl].pathname = V;\n },\n enumerable: true,\n configurable: true\n});\n\nObject.defineProperty(URL.prototype, \"search\", {\n get() {\n return this[impl].search;\n },\n set(V) {\n V = conversions[\"USVString\"](V);\n this[impl].search = V;\n },\n enumerable: true,\n configurable: true\n});\n\nObject.defineProperty(URL.prototype, \"hash\", {\n get() {\n return this[impl].hash;\n },\n set(V) {\n V = conversions[\"USVString\"](V);\n this[impl].hash = V;\n },\n enumerable: true,\n configurable: true\n});\n\n\nmodule.exports = {\n is(obj) {\n return !!obj && obj[impl] instanceof Impl.implementation;\n },\n create(constructorArgs, privateData) {\n let obj = Object.create(URL.prototype);\n this.setup(obj, constructorArgs, privateData);\n return obj;\n },\n setup(obj, constructorArgs, privateData) {\n if (!privateData) privateData = {};\n privateData.wrapper = obj;\n\n obj[impl] = new Impl.implementation(constructorArgs, privateData);\n obj[impl][utils.wrapperSymbol] = obj;\n },\n interface: URL,\n expose: {\n Window: { URL: URL },\n Worker: { URL: URL }\n }\n};\n\n", "\"use strict\";\n\nexports.URL = require(\"./URL\").interface;\nexports.serializeURL = require(\"./url-state-machine\").serializeURL;\nexports.serializeURLOrigin = require(\"./url-state-machine\").serializeURLOrigin;\nexports.basicURLParse = require(\"./url-state-machine\").basicURLParse;\nexports.setTheUsername = require(\"./url-state-machine\").setTheUsername;\nexports.setThePassword = require(\"./url-state-machine\").setThePassword;\nexports.serializeHost = require(\"./url-state-machine\").serializeHost;\nexports.serializeInteger = require(\"./url-state-machine\").serializeInteger;\nexports.parseURL = require(\"./url-state-machine\").parseURL;\n", "'use strict';\n\nObject.defineProperty(exports, '__esModule', { value: true });\n\nfunction _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }\n\nvar Stream = _interopDefault(require('stream'));\nvar http = _interopDefault(require('http'));\nvar Url = _interopDefault(require('url'));\nvar whatwgUrl = _interopDefault(require('whatwg-url'));\nvar https = _interopDefault(require('https'));\nvar zlib = _interopDefault(require('zlib'));\n\n// Based on https://github.com/tmpvar/jsdom/blob/aa85b2abf07766ff7bf5c1f6daafb3726f2f2db5/lib/jsdom/living/blob.js\n\n// fix for \"Readable\" isn't a named export issue\nconst Readable = Stream.Readable;\n\nconst BUFFER = Symbol('buffer');\nconst TYPE = Symbol('type');\n\nclass Blob {\n\tconstructor() {\n\t\tthis[TYPE] = '';\n\n\t\tconst blobParts = arguments[0];\n\t\tconst options = arguments[1];\n\n\t\tconst buffers = [];\n\t\tlet size = 0;\n\n\t\tif (blobParts) {\n\t\t\tconst a = blobParts;\n\t\t\tconst length = Number(a.length);\n\t\t\tfor (let i = 0; i < length; i++) {\n\t\t\t\tconst element = a[i];\n\t\t\t\tlet buffer;\n\t\t\t\tif (element instanceof Buffer) {\n\t\t\t\t\tbuffer = element;\n\t\t\t\t} else if (ArrayBuffer.isView(element)) {\n\t\t\t\t\tbuffer = Buffer.from(element.buffer, element.byteOffset, element.byteLength);\n\t\t\t\t} else if (element instanceof ArrayBuffer) {\n\t\t\t\t\tbuffer = Buffer.from(element);\n\t\t\t\t} else if (element instanceof Blob) {\n\t\t\t\t\tbuffer = element[BUFFER];\n\t\t\t\t} else {\n\t\t\t\t\tbuffer = Buffer.from(typeof element === 'string' ? element : String(element));\n\t\t\t\t}\n\t\t\t\tsize += buffer.length;\n\t\t\t\tbuffers.push(buffer);\n\t\t\t}\n\t\t}\n\n\t\tthis[BUFFER] = Buffer.concat(buffers);\n\n\t\tlet type = options && options.type !== undefined && String(options.type).toLowerCase();\n\t\tif (type && !/[^\\u0020-\\u007E]/.test(type)) {\n\t\t\tthis[TYPE] = type;\n\t\t}\n\t}\n\tget size() {\n\t\treturn this[BUFFER].length;\n\t}\n\tget type() {\n\t\treturn this[TYPE];\n\t}\n\ttext() {\n\t\treturn Promise.resolve(this[BUFFER].toString());\n\t}\n\tarrayBuffer() {\n\t\tconst buf = this[BUFFER];\n\t\tconst ab = buf.buffer.slice(buf.byteOffset, buf.byteOffset + buf.byteLength);\n\t\treturn Promise.resolve(ab);\n\t}\n\tstream() {\n\t\tconst readable = new Readable();\n\t\treadable._read = function () {};\n\t\treadable.push(this[BUFFER]);\n\t\treadable.push(null);\n\t\treturn readable;\n\t}\n\ttoString() {\n\t\treturn '[object Blob]';\n\t}\n\tslice() {\n\t\tconst size = this.size;\n\n\t\tconst start = arguments[0];\n\t\tconst end = arguments[1];\n\t\tlet relativeStart, relativeEnd;\n\t\tif (start === undefined) {\n\t\t\trelativeStart = 0;\n\t\t} else if (start < 0) {\n\t\t\trelativeStart = Math.max(size + start, 0);\n\t\t} else {\n\t\t\trelativeStart = Math.min(start, size);\n\t\t}\n\t\tif (end === undefined) {\n\t\t\trelativeEnd = size;\n\t\t} else if (end < 0) {\n\t\t\trelativeEnd = Math.max(size + end, 0);\n\t\t} else {\n\t\t\trelativeEnd = Math.min(end, size);\n\t\t}\n\t\tconst span = Math.max(relativeEnd - relativeStart, 0);\n\n\t\tconst buffer = this[BUFFER];\n\t\tconst slicedBuffer = buffer.slice(relativeStart, relativeStart + span);\n\t\tconst blob = new Blob([], { type: arguments[2] });\n\t\tblob[BUFFER] = slicedBuffer;\n\t\treturn blob;\n\t}\n}\n\nObject.defineProperties(Blob.prototype, {\n\tsize: { enumerable: true },\n\ttype: { enumerable: true },\n\tslice: { enumerable: true }\n});\n\nObject.defineProperty(Blob.prototype, Symbol.toStringTag, {\n\tvalue: 'Blob',\n\twritable: false,\n\tenumerable: false,\n\tconfigurable: true\n});\n\n/**\n * fetch-error.js\n *\n * FetchError interface for operational errors\n */\n\n/**\n * Create FetchError instance\n *\n * @param String message Error message for human\n * @param String type Error type for machine\n * @param String systemError For Node.js system error\n * @return FetchError\n */\nfunction FetchError(message, type, systemError) {\n Error.call(this, message);\n\n this.message = message;\n this.type = type;\n\n // when err.type is `system`, err.code contains system error code\n if (systemError) {\n this.code = this.errno = systemError.code;\n }\n\n // hide custom error implementation details from end-users\n Error.captureStackTrace(this, this.constructor);\n}\n\nFetchError.prototype = Object.create(Error.prototype);\nFetchError.prototype.constructor = FetchError;\nFetchError.prototype.name = 'FetchError';\n\nlet convert;\ntry {\n\tconvert = require('encoding').convert;\n} catch (e) {}\n\nconst INTERNALS = Symbol('Body internals');\n\n// fix an issue where \"PassThrough\" isn't a named export for node <10\nconst PassThrough = Stream.PassThrough;\n\n/**\n * Body mixin\n *\n * Ref: https://fetch.spec.whatwg.org/#body\n *\n * @param Stream body Readable stream\n * @param Object opts Response options\n * @return Void\n */\nfunction Body(body) {\n\tvar _this = this;\n\n\tvar _ref = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {},\n\t _ref$size = _ref.size;\n\n\tlet size = _ref$size === undefined ? 0 : _ref$size;\n\tvar _ref$timeout = _ref.timeout;\n\tlet timeout = _ref$timeout === undefined ? 0 : _ref$timeout;\n\n\tif (body == null) {\n\t\t// body is undefined or null\n\t\tbody = null;\n\t} else if (isURLSearchParams(body)) {\n\t\t// body is a URLSearchParams\n\t\tbody = Buffer.from(body.toString());\n\t} else if (isBlob(body)) ; else if (Buffer.isBuffer(body)) ; else if (Object.prototype.toString.call(body) === '[object ArrayBuffer]') {\n\t\t// body is ArrayBuffer\n\t\tbody = Buffer.from(body);\n\t} else if (ArrayBuffer.isView(body)) {\n\t\t// body is ArrayBufferView\n\t\tbody = Buffer.from(body.buffer, body.byteOffset, body.byteLength);\n\t} else if (body instanceof Stream) ; else {\n\t\t// none of the above\n\t\t// coerce to string then buffer\n\t\tbody = Buffer.from(String(body));\n\t}\n\tthis[INTERNALS] = {\n\t\tbody,\n\t\tdisturbed: false,\n\t\terror: null\n\t};\n\tthis.size = size;\n\tthis.timeout = timeout;\n\n\tif (body instanceof Stream) {\n\t\tbody.on('error', function (err) {\n\t\t\tconst error = err.name === 'AbortError' ? err : new FetchError(`Invalid response body while trying to fetch ${_this.url}: ${err.message}`, 'system', err);\n\t\t\t_this[INTERNALS].error = error;\n\t\t});\n\t}\n}\n\nBody.prototype = {\n\tget body() {\n\t\treturn this[INTERNALS].body;\n\t},\n\n\tget bodyUsed() {\n\t\treturn this[INTERNALS].disturbed;\n\t},\n\n\t/**\n * Decode response as ArrayBuffer\n *\n * @return Promise\n */\n\tarrayBuffer() {\n\t\treturn consumeBody.call(this).then(function (buf) {\n\t\t\treturn buf.buffer.slice(buf.byteOffset, buf.byteOffset + buf.byteLength);\n\t\t});\n\t},\n\n\t/**\n * Return raw response as Blob\n *\n * @return Promise\n */\n\tblob() {\n\t\tlet ct = this.headers && this.headers.get('content-type') || '';\n\t\treturn consumeBody.call(this).then(function (buf) {\n\t\t\treturn Object.assign(\n\t\t\t// Prevent copying\n\t\t\tnew Blob([], {\n\t\t\t\ttype: ct.toLowerCase()\n\t\t\t}), {\n\t\t\t\t[BUFFER]: buf\n\t\t\t});\n\t\t});\n\t},\n\n\t/**\n * Decode response as json\n *\n * @return Promise\n */\n\tjson() {\n\t\tvar _this2 = this;\n\n\t\treturn consumeBody.call(this).then(function (buffer) {\n\t\t\ttry {\n\t\t\t\treturn JSON.parse(buffer.toString());\n\t\t\t} catch (err) {\n\t\t\t\treturn Body.Promise.reject(new FetchError(`invalid json response body at ${_this2.url} reason: ${err.message}`, 'invalid-json'));\n\t\t\t}\n\t\t});\n\t},\n\n\t/**\n * Decode response as text\n *\n * @return Promise\n */\n\ttext() {\n\t\treturn consumeBody.call(this).then(function (buffer) {\n\t\t\treturn buffer.toString();\n\t\t});\n\t},\n\n\t/**\n * Decode response as buffer (non-spec api)\n *\n * @return Promise\n */\n\tbuffer() {\n\t\treturn consumeBody.call(this);\n\t},\n\n\t/**\n * Decode response as text, while automatically detecting the encoding and\n * trying to decode to UTF-8 (non-spec api)\n *\n * @return Promise\n */\n\ttextConverted() {\n\t\tvar _this3 = this;\n\n\t\treturn consumeBody.call(this).then(function (buffer) {\n\t\t\treturn convertBody(buffer, _this3.headers);\n\t\t});\n\t}\n};\n\n// In browsers, all properties are enumerable.\nObject.defineProperties(Body.prototype, {\n\tbody: { enumerable: true },\n\tbodyUsed: { enumerable: true },\n\tarrayBuffer: { enumerable: true },\n\tblob: { enumerable: true },\n\tjson: { enumerable: true },\n\ttext: { enumerable: true }\n});\n\nBody.mixIn = function (proto) {\n\tfor (const name of Object.getOwnPropertyNames(Body.prototype)) {\n\t\t// istanbul ignore else: future proof\n\t\tif (!(name in proto)) {\n\t\t\tconst desc = Object.getOwnPropertyDescriptor(Body.prototype, name);\n\t\t\tObject.defineProperty(proto, name, desc);\n\t\t}\n\t}\n};\n\n/**\n * Consume and convert an entire Body to a Buffer.\n *\n * Ref: https://fetch.spec.whatwg.org/#concept-body-consume-body\n *\n * @return Promise\n */\nfunction consumeBody() {\n\tvar _this4 = this;\n\n\tif (this[INTERNALS].disturbed) {\n\t\treturn Body.Promise.reject(new TypeError(`body used already for: ${this.url}`));\n\t}\n\n\tthis[INTERNALS].disturbed = true;\n\n\tif (this[INTERNALS].error) {\n\t\treturn Body.Promise.reject(this[INTERNALS].error);\n\t}\n\n\tlet body = this.body;\n\n\t// body is null\n\tif (body === null) {\n\t\treturn Body.Promise.resolve(Buffer.alloc(0));\n\t}\n\n\t// body is blob\n\tif (isBlob(body)) {\n\t\tbody = body.stream();\n\t}\n\n\t// body is buffer\n\tif (Buffer.isBuffer(body)) {\n\t\treturn Body.Promise.resolve(body);\n\t}\n\n\t// istanbul ignore if: should never happen\n\tif (!(body instanceof Stream)) {\n\t\treturn Body.Promise.resolve(Buffer.alloc(0));\n\t}\n\n\t// body is stream\n\t// get ready to actually consume the body\n\tlet accum = [];\n\tlet accumBytes = 0;\n\tlet abort = false;\n\n\treturn new Body.Promise(function (resolve, reject) {\n\t\tlet resTimeout;\n\n\t\t// allow timeout on slow response body\n\t\tif (_this4.timeout) {\n\t\t\tresTimeout = setTimeout(function () {\n\t\t\t\tabort = true;\n\t\t\t\treject(new FetchError(`Response timeout while trying to fetch ${_this4.url} (over ${_this4.timeout}ms)`, 'body-timeout'));\n\t\t\t}, _this4.timeout);\n\t\t}\n\n\t\t// handle stream errors\n\t\tbody.on('error', function (err) {\n\t\t\tif (err.name === 'AbortError') {\n\t\t\t\t// if the request was aborted, reject with this Error\n\t\t\t\tabort = true;\n\t\t\t\treject(err);\n\t\t\t} else {\n\t\t\t\t// other errors, such as incorrect content-encoding\n\t\t\t\treject(new FetchError(`Invalid response body while trying to fetch ${_this4.url}: ${err.message}`, 'system', err));\n\t\t\t}\n\t\t});\n\n\t\tbody.on('data', function (chunk) {\n\t\t\tif (abort || chunk === null) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif (_this4.size && accumBytes + chunk.length > _this4.size) {\n\t\t\t\tabort = true;\n\t\t\t\treject(new FetchError(`content size at ${_this4.url} over limit: ${_this4.size}`, 'max-size'));\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\taccumBytes += chunk.length;\n\t\t\taccum.push(chunk);\n\t\t});\n\n\t\tbody.on('end', function () {\n\t\t\tif (abort) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tclearTimeout(resTimeout);\n\n\t\t\ttry {\n\t\t\t\tresolve(Buffer.concat(accum, accumBytes));\n\t\t\t} catch (err) {\n\t\t\t\t// handle streams that have accumulated too much data (issue #414)\n\t\t\t\treject(new FetchError(`Could not create Buffer from response body for ${_this4.url}: ${err.message}`, 'system', err));\n\t\t\t}\n\t\t});\n\t});\n}\n\n/**\n * Detect buffer encoding and convert to target encoding\n * ref: http://www.w3.org/TR/2011/WD-html5-20110113/parsing.html#determining-the-character-encoding\n *\n * @param Buffer buffer Incoming buffer\n * @param String encoding Target encoding\n * @return String\n */\nfunction convertBody(buffer, headers) {\n\tif (typeof convert !== 'function') {\n\t\tthrow new Error('The package `encoding` must be installed to use the textConverted() function');\n\t}\n\n\tconst ct = headers.get('content-type');\n\tlet charset = 'utf-8';\n\tlet res, str;\n\n\t// header\n\tif (ct) {\n\t\tres = /charset=([^;]*)/i.exec(ct);\n\t}\n\n\t// no charset in content type, peek at response body for at most 1024 bytes\n\tstr = buffer.slice(0, 1024).toString();\n\n\t// html5\n\tif (!res && str) {\n\t\tres = / 0 && arguments[0] !== undefined ? arguments[0] : undefined;\n\n\t\tthis[MAP] = Object.create(null);\n\n\t\tif (init instanceof Headers) {\n\t\t\tconst rawHeaders = init.raw();\n\t\t\tconst headerNames = Object.keys(rawHeaders);\n\n\t\t\tfor (const headerName of headerNames) {\n\t\t\t\tfor (const value of rawHeaders[headerName]) {\n\t\t\t\t\tthis.append(headerName, value);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn;\n\t\t}\n\n\t\t// We don't worry about converting prop to ByteString here as append()\n\t\t// will handle it.\n\t\tif (init == null) ; else if (typeof init === 'object') {\n\t\t\tconst method = init[Symbol.iterator];\n\t\t\tif (method != null) {\n\t\t\t\tif (typeof method !== 'function') {\n\t\t\t\t\tthrow new TypeError('Header pairs must be iterable');\n\t\t\t\t}\n\n\t\t\t\t// sequence>\n\t\t\t\t// Note: per spec we have to first exhaust the lists then process them\n\t\t\t\tconst pairs = [];\n\t\t\t\tfor (const pair of init) {\n\t\t\t\t\tif (typeof pair !== 'object' || typeof pair[Symbol.iterator] !== 'function') {\n\t\t\t\t\t\tthrow new TypeError('Each header pair must be iterable');\n\t\t\t\t\t}\n\t\t\t\t\tpairs.push(Array.from(pair));\n\t\t\t\t}\n\n\t\t\t\tfor (const pair of pairs) {\n\t\t\t\t\tif (pair.length !== 2) {\n\t\t\t\t\t\tthrow new TypeError('Each header pair must be a name/value tuple');\n\t\t\t\t\t}\n\t\t\t\t\tthis.append(pair[0], pair[1]);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t// record\n\t\t\t\tfor (const key of Object.keys(init)) {\n\t\t\t\t\tconst value = init[key];\n\t\t\t\t\tthis.append(key, value);\n\t\t\t\t}\n\t\t\t}\n\t\t} else {\n\t\t\tthrow new TypeError('Provided initializer must be an object');\n\t\t}\n\t}\n\n\t/**\n * Return combined header value given name\n *\n * @param String name Header name\n * @return Mixed\n */\n\tget(name) {\n\t\tname = `${name}`;\n\t\tvalidateName(name);\n\t\tconst key = find(this[MAP], name);\n\t\tif (key === undefined) {\n\t\t\treturn null;\n\t\t}\n\n\t\treturn this[MAP][key].join(', ');\n\t}\n\n\t/**\n * Iterate over all headers\n *\n * @param Function callback Executed for each item with parameters (value, name, thisArg)\n * @param Boolean thisArg `this` context for callback function\n * @return Void\n */\n\tforEach(callback) {\n\t\tlet thisArg = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : undefined;\n\n\t\tlet pairs = getHeaders(this);\n\t\tlet i = 0;\n\t\twhile (i < pairs.length) {\n\t\t\tvar _pairs$i = pairs[i];\n\t\t\tconst name = _pairs$i[0],\n\t\t\t value = _pairs$i[1];\n\n\t\t\tcallback.call(thisArg, value, name, this);\n\t\t\tpairs = getHeaders(this);\n\t\t\ti++;\n\t\t}\n\t}\n\n\t/**\n * Overwrite header values given name\n *\n * @param String name Header name\n * @param String value Header value\n * @return Void\n */\n\tset(name, value) {\n\t\tname = `${name}`;\n\t\tvalue = `${value}`;\n\t\tvalidateName(name);\n\t\tvalidateValue(value);\n\t\tconst key = find(this[MAP], name);\n\t\tthis[MAP][key !== undefined ? key : name] = [value];\n\t}\n\n\t/**\n * Append a value onto existing header\n *\n * @param String name Header name\n * @param String value Header value\n * @return Void\n */\n\tappend(name, value) {\n\t\tname = `${name}`;\n\t\tvalue = `${value}`;\n\t\tvalidateName(name);\n\t\tvalidateValue(value);\n\t\tconst key = find(this[MAP], name);\n\t\tif (key !== undefined) {\n\t\t\tthis[MAP][key].push(value);\n\t\t} else {\n\t\t\tthis[MAP][name] = [value];\n\t\t}\n\t}\n\n\t/**\n * Check for header name existence\n *\n * @param String name Header name\n * @return Boolean\n */\n\thas(name) {\n\t\tname = `${name}`;\n\t\tvalidateName(name);\n\t\treturn find(this[MAP], name) !== undefined;\n\t}\n\n\t/**\n * Delete all header values given name\n *\n * @param String name Header name\n * @return Void\n */\n\tdelete(name) {\n\t\tname = `${name}`;\n\t\tvalidateName(name);\n\t\tconst key = find(this[MAP], name);\n\t\tif (key !== undefined) {\n\t\t\tdelete this[MAP][key];\n\t\t}\n\t}\n\n\t/**\n * Return raw headers (non-spec api)\n *\n * @return Object\n */\n\traw() {\n\t\treturn this[MAP];\n\t}\n\n\t/**\n * Get an iterator on keys.\n *\n * @return Iterator\n */\n\tkeys() {\n\t\treturn createHeadersIterator(this, 'key');\n\t}\n\n\t/**\n * Get an iterator on values.\n *\n * @return Iterator\n */\n\tvalues() {\n\t\treturn createHeadersIterator(this, 'value');\n\t}\n\n\t/**\n * Get an iterator on entries.\n *\n * This is the default iterator of the Headers object.\n *\n * @return Iterator\n */\n\t[Symbol.iterator]() {\n\t\treturn createHeadersIterator(this, 'key+value');\n\t}\n}\nHeaders.prototype.entries = Headers.prototype[Symbol.iterator];\n\nObject.defineProperty(Headers.prototype, Symbol.toStringTag, {\n\tvalue: 'Headers',\n\twritable: false,\n\tenumerable: false,\n\tconfigurable: true\n});\n\nObject.defineProperties(Headers.prototype, {\n\tget: { enumerable: true },\n\tforEach: { enumerable: true },\n\tset: { enumerable: true },\n\tappend: { enumerable: true },\n\thas: { enumerable: true },\n\tdelete: { enumerable: true },\n\tkeys: { enumerable: true },\n\tvalues: { enumerable: true },\n\tentries: { enumerable: true }\n});\n\nfunction getHeaders(headers) {\n\tlet kind = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'key+value';\n\n\tconst keys = Object.keys(headers[MAP]).sort();\n\treturn keys.map(kind === 'key' ? function (k) {\n\t\treturn k.toLowerCase();\n\t} : kind === 'value' ? function (k) {\n\t\treturn headers[MAP][k].join(', ');\n\t} : function (k) {\n\t\treturn [k.toLowerCase(), headers[MAP][k].join(', ')];\n\t});\n}\n\nconst INTERNAL = Symbol('internal');\n\nfunction createHeadersIterator(target, kind) {\n\tconst iterator = Object.create(HeadersIteratorPrototype);\n\titerator[INTERNAL] = {\n\t\ttarget,\n\t\tkind,\n\t\tindex: 0\n\t};\n\treturn iterator;\n}\n\nconst HeadersIteratorPrototype = Object.setPrototypeOf({\n\tnext() {\n\t\t// istanbul ignore if\n\t\tif (!this || Object.getPrototypeOf(this) !== HeadersIteratorPrototype) {\n\t\t\tthrow new TypeError('Value of `this` is not a HeadersIterator');\n\t\t}\n\n\t\tvar _INTERNAL = this[INTERNAL];\n\t\tconst target = _INTERNAL.target,\n\t\t kind = _INTERNAL.kind,\n\t\t index = _INTERNAL.index;\n\n\t\tconst values = getHeaders(target, kind);\n\t\tconst len = values.length;\n\t\tif (index >= len) {\n\t\t\treturn {\n\t\t\t\tvalue: undefined,\n\t\t\t\tdone: true\n\t\t\t};\n\t\t}\n\n\t\tthis[INTERNAL].index = index + 1;\n\n\t\treturn {\n\t\t\tvalue: values[index],\n\t\t\tdone: false\n\t\t};\n\t}\n}, Object.getPrototypeOf(Object.getPrototypeOf([][Symbol.iterator]())));\n\nObject.defineProperty(HeadersIteratorPrototype, Symbol.toStringTag, {\n\tvalue: 'HeadersIterator',\n\twritable: false,\n\tenumerable: false,\n\tconfigurable: true\n});\n\n/**\n * Export the Headers object in a form that Node.js can consume.\n *\n * @param Headers headers\n * @return Object\n */\nfunction exportNodeCompatibleHeaders(headers) {\n\tconst obj = Object.assign({ __proto__: null }, headers[MAP]);\n\n\t// http.request() only supports string as Host header. This hack makes\n\t// specifying custom Host header possible.\n\tconst hostHeaderKey = find(headers[MAP], 'Host');\n\tif (hostHeaderKey !== undefined) {\n\t\tobj[hostHeaderKey] = obj[hostHeaderKey][0];\n\t}\n\n\treturn obj;\n}\n\n/**\n * Create a Headers object from an object of headers, ignoring those that do\n * not conform to HTTP grammar productions.\n *\n * @param Object obj Object of headers\n * @return Headers\n */\nfunction createHeadersLenient(obj) {\n\tconst headers = new Headers();\n\tfor (const name of Object.keys(obj)) {\n\t\tif (invalidTokenRegex.test(name)) {\n\t\t\tcontinue;\n\t\t}\n\t\tif (Array.isArray(obj[name])) {\n\t\t\tfor (const val of obj[name]) {\n\t\t\t\tif (invalidHeaderCharRegex.test(val)) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\tif (headers[MAP][name] === undefined) {\n\t\t\t\t\theaders[MAP][name] = [val];\n\t\t\t\t} else {\n\t\t\t\t\theaders[MAP][name].push(val);\n\t\t\t\t}\n\t\t\t}\n\t\t} else if (!invalidHeaderCharRegex.test(obj[name])) {\n\t\t\theaders[MAP][name] = [obj[name]];\n\t\t}\n\t}\n\treturn headers;\n}\n\nconst INTERNALS$1 = Symbol('Response internals');\n\n// fix an issue where \"STATUS_CODES\" aren't a named export for node <10\nconst STATUS_CODES = http.STATUS_CODES;\n\n/**\n * Response class\n *\n * @param Stream body Readable stream\n * @param Object opts Response options\n * @return Void\n */\nclass Response {\n\tconstructor() {\n\t\tlet body = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;\n\t\tlet opts = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n\n\t\tBody.call(this, body, opts);\n\n\t\tconst status = opts.status || 200;\n\t\tconst headers = new Headers(opts.headers);\n\n\t\tif (body != null && !headers.has('Content-Type')) {\n\t\t\tconst contentType = extractContentType(body);\n\t\t\tif (contentType) {\n\t\t\t\theaders.append('Content-Type', contentType);\n\t\t\t}\n\t\t}\n\n\t\tthis[INTERNALS$1] = {\n\t\t\turl: opts.url,\n\t\t\tstatus,\n\t\t\tstatusText: opts.statusText || STATUS_CODES[status],\n\t\t\theaders,\n\t\t\tcounter: opts.counter\n\t\t};\n\t}\n\n\tget url() {\n\t\treturn this[INTERNALS$1].url || '';\n\t}\n\n\tget status() {\n\t\treturn this[INTERNALS$1].status;\n\t}\n\n\t/**\n * Convenience property representing if the request ended normally\n */\n\tget ok() {\n\t\treturn this[INTERNALS$1].status >= 200 && this[INTERNALS$1].status < 300;\n\t}\n\n\tget redirected() {\n\t\treturn this[INTERNALS$1].counter > 0;\n\t}\n\n\tget statusText() {\n\t\treturn this[INTERNALS$1].statusText;\n\t}\n\n\tget headers() {\n\t\treturn this[INTERNALS$1].headers;\n\t}\n\n\t/**\n * Clone this response\n *\n * @return Response\n */\n\tclone() {\n\t\treturn new Response(clone(this), {\n\t\t\turl: this.url,\n\t\t\tstatus: this.status,\n\t\t\tstatusText: this.statusText,\n\t\t\theaders: this.headers,\n\t\t\tok: this.ok,\n\t\t\tredirected: this.redirected\n\t\t});\n\t}\n}\n\nBody.mixIn(Response.prototype);\n\nObject.defineProperties(Response.prototype, {\n\turl: { enumerable: true },\n\tstatus: { enumerable: true },\n\tok: { enumerable: true },\n\tredirected: { enumerable: true },\n\tstatusText: { enumerable: true },\n\theaders: { enumerable: true },\n\tclone: { enumerable: true }\n});\n\nObject.defineProperty(Response.prototype, Symbol.toStringTag, {\n\tvalue: 'Response',\n\twritable: false,\n\tenumerable: false,\n\tconfigurable: true\n});\n\nconst INTERNALS$2 = Symbol('Request internals');\nconst URL = Url.URL || whatwgUrl.URL;\n\n// fix an issue where \"format\", \"parse\" aren't a named export for node <10\nconst parse_url = Url.parse;\nconst format_url = Url.format;\n\n/**\n * Wrapper around `new URL` to handle arbitrary URLs\n *\n * @param {string} urlStr\n * @return {void}\n */\nfunction parseURL(urlStr) {\n\t/*\n \tCheck whether the URL is absolute or not\n \t\tScheme: https://tools.ietf.org/html/rfc3986#section-3.1\n \tAbsolute URL: https://tools.ietf.org/html/rfc3986#section-4.3\n */\n\tif (/^[a-zA-Z][a-zA-Z\\d+\\-.]*:/.exec(urlStr)) {\n\t\turlStr = new URL(urlStr).toString();\n\t}\n\n\t// Fallback to old implementation for arbitrary URLs\n\treturn parse_url(urlStr);\n}\n\nconst streamDestructionSupported = 'destroy' in Stream.Readable.prototype;\n\n/**\n * Check if a value is an instance of Request.\n *\n * @param Mixed input\n * @return Boolean\n */\nfunction isRequest(input) {\n\treturn typeof input === 'object' && typeof input[INTERNALS$2] === 'object';\n}\n\nfunction isAbortSignal(signal) {\n\tconst proto = signal && typeof signal === 'object' && Object.getPrototypeOf(signal);\n\treturn !!(proto && proto.constructor.name === 'AbortSignal');\n}\n\n/**\n * Request class\n *\n * @param Mixed input Url or Request instance\n * @param Object init Custom options\n * @return Void\n */\nclass Request {\n\tconstructor(input) {\n\t\tlet init = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n\n\t\tlet parsedURL;\n\n\t\t// normalize input\n\t\tif (!isRequest(input)) {\n\t\t\tif (input && input.href) {\n\t\t\t\t// in order to support Node.js' Url objects; though WHATWG's URL objects\n\t\t\t\t// will fall into this branch also (since their `toString()` will return\n\t\t\t\t// `href` property anyway)\n\t\t\t\tparsedURL = parseURL(input.href);\n\t\t\t} else {\n\t\t\t\t// coerce input to a string before attempting to parse\n\t\t\t\tparsedURL = parseURL(`${input}`);\n\t\t\t}\n\t\t\tinput = {};\n\t\t} else {\n\t\t\tparsedURL = parseURL(input.url);\n\t\t}\n\n\t\tlet method = init.method || input.method || 'GET';\n\t\tmethod = method.toUpperCase();\n\n\t\tif ((init.body != null || isRequest(input) && input.body !== null) && (method === 'GET' || method === 'HEAD')) {\n\t\t\tthrow new TypeError('Request with GET/HEAD method cannot have body');\n\t\t}\n\n\t\tlet inputBody = init.body != null ? init.body : isRequest(input) && input.body !== null ? clone(input) : null;\n\n\t\tBody.call(this, inputBody, {\n\t\t\ttimeout: init.timeout || input.timeout || 0,\n\t\t\tsize: init.size || input.size || 0\n\t\t});\n\n\t\tconst headers = new Headers(init.headers || input.headers || {});\n\n\t\tif (inputBody != null && !headers.has('Content-Type')) {\n\t\t\tconst contentType = extractContentType(inputBody);\n\t\t\tif (contentType) {\n\t\t\t\theaders.append('Content-Type', contentType);\n\t\t\t}\n\t\t}\n\n\t\tlet signal = isRequest(input) ? input.signal : null;\n\t\tif ('signal' in init) signal = init.signal;\n\n\t\tif (signal != null && !isAbortSignal(signal)) {\n\t\t\tthrow new TypeError('Expected signal to be an instanceof AbortSignal');\n\t\t}\n\n\t\tthis[INTERNALS$2] = {\n\t\t\tmethod,\n\t\t\tredirect: init.redirect || input.redirect || 'follow',\n\t\t\theaders,\n\t\t\tparsedURL,\n\t\t\tsignal\n\t\t};\n\n\t\t// node-fetch-only options\n\t\tthis.follow = init.follow !== undefined ? init.follow : input.follow !== undefined ? input.follow : 20;\n\t\tthis.compress = init.compress !== undefined ? init.compress : input.compress !== undefined ? input.compress : true;\n\t\tthis.counter = init.counter || input.counter || 0;\n\t\tthis.agent = init.agent || input.agent;\n\t}\n\n\tget method() {\n\t\treturn this[INTERNALS$2].method;\n\t}\n\n\tget url() {\n\t\treturn format_url(this[INTERNALS$2].parsedURL);\n\t}\n\n\tget headers() {\n\t\treturn this[INTERNALS$2].headers;\n\t}\n\n\tget redirect() {\n\t\treturn this[INTERNALS$2].redirect;\n\t}\n\n\tget signal() {\n\t\treturn this[INTERNALS$2].signal;\n\t}\n\n\t/**\n * Clone this request\n *\n * @return Request\n */\n\tclone() {\n\t\treturn new Request(this);\n\t}\n}\n\nBody.mixIn(Request.prototype);\n\nObject.defineProperty(Request.prototype, Symbol.toStringTag, {\n\tvalue: 'Request',\n\twritable: false,\n\tenumerable: false,\n\tconfigurable: true\n});\n\nObject.defineProperties(Request.prototype, {\n\tmethod: { enumerable: true },\n\turl: { enumerable: true },\n\theaders: { enumerable: true },\n\tredirect: { enumerable: true },\n\tclone: { enumerable: true },\n\tsignal: { enumerable: true }\n});\n\n/**\n * Convert a Request to Node.js http request options.\n *\n * @param Request A Request instance\n * @return Object The options object to be passed to http.request\n */\nfunction getNodeRequestOptions(request) {\n\tconst parsedURL = request[INTERNALS$2].parsedURL;\n\tconst headers = new Headers(request[INTERNALS$2].headers);\n\n\t// fetch step 1.3\n\tif (!headers.has('Accept')) {\n\t\theaders.set('Accept', '*/*');\n\t}\n\n\t// Basic fetch\n\tif (!parsedURL.protocol || !parsedURL.hostname) {\n\t\tthrow new TypeError('Only absolute URLs are supported');\n\t}\n\n\tif (!/^https?:$/.test(parsedURL.protocol)) {\n\t\tthrow new TypeError('Only HTTP(S) protocols are supported');\n\t}\n\n\tif (request.signal && request.body instanceof Stream.Readable && !streamDestructionSupported) {\n\t\tthrow new Error('Cancellation of streamed requests with AbortSignal is not supported in node < 8');\n\t}\n\n\t// HTTP-network-or-cache fetch steps 2.4-2.7\n\tlet contentLengthValue = null;\n\tif (request.body == null && /^(POST|PUT)$/i.test(request.method)) {\n\t\tcontentLengthValue = '0';\n\t}\n\tif (request.body != null) {\n\t\tconst totalBytes = getTotalBytes(request);\n\t\tif (typeof totalBytes === 'number') {\n\t\t\tcontentLengthValue = String(totalBytes);\n\t\t}\n\t}\n\tif (contentLengthValue) {\n\t\theaders.set('Content-Length', contentLengthValue);\n\t}\n\n\t// HTTP-network-or-cache fetch step 2.11\n\tif (!headers.has('User-Agent')) {\n\t\theaders.set('User-Agent', 'node-fetch/1.0 (+https://github.com/bitinn/node-fetch)');\n\t}\n\n\t// HTTP-network-or-cache fetch step 2.15\n\tif (request.compress && !headers.has('Accept-Encoding')) {\n\t\theaders.set('Accept-Encoding', 'gzip,deflate');\n\t}\n\n\tlet agent = request.agent;\n\tif (typeof agent === 'function') {\n\t\tagent = agent(parsedURL);\n\t}\n\n\tif (!headers.has('Connection') && !agent) {\n\t\theaders.set('Connection', 'close');\n\t}\n\n\t// HTTP-network fetch step 4.2\n\t// chunked encoding is handled by Node.js\n\n\treturn Object.assign({}, parsedURL, {\n\t\tmethod: request.method,\n\t\theaders: exportNodeCompatibleHeaders(headers),\n\t\tagent\n\t});\n}\n\n/**\n * abort-error.js\n *\n * AbortError interface for cancelled requests\n */\n\n/**\n * Create AbortError instance\n *\n * @param String message Error message for human\n * @return AbortError\n */\nfunction AbortError(message) {\n Error.call(this, message);\n\n this.type = 'aborted';\n this.message = message;\n\n // hide custom error implementation details from end-users\n Error.captureStackTrace(this, this.constructor);\n}\n\nAbortError.prototype = Object.create(Error.prototype);\nAbortError.prototype.constructor = AbortError;\nAbortError.prototype.name = 'AbortError';\n\nconst URL$1 = Url.URL || whatwgUrl.URL;\n\n// fix an issue where \"PassThrough\", \"resolve\" aren't a named export for node <10\nconst PassThrough$1 = Stream.PassThrough;\n\nconst isDomainOrSubdomain = function isDomainOrSubdomain(destination, original) {\n\tconst orig = new URL$1(original).hostname;\n\tconst dest = new URL$1(destination).hostname;\n\n\treturn orig === dest || orig[orig.length - dest.length - 1] === '.' && orig.endsWith(dest);\n};\n\n/**\n * Fetch function\n *\n * @param Mixed url Absolute url or Request instance\n * @param Object opts Fetch options\n * @return Promise\n */\nfunction fetch(url, opts) {\n\n\t// allow custom promise\n\tif (!fetch.Promise) {\n\t\tthrow new Error('native promise missing, set fetch.Promise to your favorite alternative');\n\t}\n\n\tBody.Promise = fetch.Promise;\n\n\t// wrap http.request into fetch\n\treturn new fetch.Promise(function (resolve, reject) {\n\t\t// build request object\n\t\tconst request = new Request(url, opts);\n\t\tconst options = getNodeRequestOptions(request);\n\n\t\tconst send = (options.protocol === 'https:' ? https : http).request;\n\t\tconst signal = request.signal;\n\n\t\tlet response = null;\n\n\t\tconst abort = function abort() {\n\t\t\tlet error = new AbortError('The user aborted a request.');\n\t\t\treject(error);\n\t\t\tif (request.body && request.body instanceof Stream.Readable) {\n\t\t\t\trequest.body.destroy(error);\n\t\t\t}\n\t\t\tif (!response || !response.body) return;\n\t\t\tresponse.body.emit('error', error);\n\t\t};\n\n\t\tif (signal && signal.aborted) {\n\t\t\tabort();\n\t\t\treturn;\n\t\t}\n\n\t\tconst abortAndFinalize = function abortAndFinalize() {\n\t\t\tabort();\n\t\t\tfinalize();\n\t\t};\n\n\t\t// send request\n\t\tconst req = send(options);\n\t\tlet reqTimeout;\n\n\t\tif (signal) {\n\t\t\tsignal.addEventListener('abort', abortAndFinalize);\n\t\t}\n\n\t\tfunction finalize() {\n\t\t\treq.abort();\n\t\t\tif (signal) signal.removeEventListener('abort', abortAndFinalize);\n\t\t\tclearTimeout(reqTimeout);\n\t\t}\n\n\t\tif (request.timeout) {\n\t\t\treq.once('socket', function (socket) {\n\t\t\t\treqTimeout = setTimeout(function () {\n\t\t\t\t\treject(new FetchError(`network timeout at: ${request.url}`, 'request-timeout'));\n\t\t\t\t\tfinalize();\n\t\t\t\t}, request.timeout);\n\t\t\t});\n\t\t}\n\n\t\treq.on('error', function (err) {\n\t\t\treject(new FetchError(`request to ${request.url} failed, reason: ${err.message}`, 'system', err));\n\t\t\tfinalize();\n\t\t});\n\n\t\treq.on('response', function (res) {\n\t\t\tclearTimeout(reqTimeout);\n\n\t\t\tconst headers = createHeadersLenient(res.headers);\n\n\t\t\t// HTTP fetch step 5\n\t\t\tif (fetch.isRedirect(res.statusCode)) {\n\t\t\t\t// HTTP fetch step 5.2\n\t\t\t\tconst location = headers.get('Location');\n\n\t\t\t\t// HTTP fetch step 5.3\n\t\t\t\tlet locationURL = null;\n\t\t\t\ttry {\n\t\t\t\t\tlocationURL = location === null ? null : new URL$1(location, request.url).toString();\n\t\t\t\t} catch (err) {\n\t\t\t\t\t// error here can only be invalid URL in Location: header\n\t\t\t\t\t// do not throw when options.redirect == manual\n\t\t\t\t\t// let the user extract the errorneous redirect URL\n\t\t\t\t\tif (request.redirect !== 'manual') {\n\t\t\t\t\t\treject(new FetchError(`uri requested responds with an invalid redirect URL: ${location}`, 'invalid-redirect'));\n\t\t\t\t\t\tfinalize();\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// HTTP fetch step 5.5\n\t\t\t\tswitch (request.redirect) {\n\t\t\t\t\tcase 'error':\n\t\t\t\t\t\treject(new FetchError(`uri requested responds with a redirect, redirect mode is set to error: ${request.url}`, 'no-redirect'));\n\t\t\t\t\t\tfinalize();\n\t\t\t\t\t\treturn;\n\t\t\t\t\tcase 'manual':\n\t\t\t\t\t\t// node-fetch-specific step: make manual redirect a bit easier to use by setting the Location header value to the resolved URL.\n\t\t\t\t\t\tif (locationURL !== null) {\n\t\t\t\t\t\t\t// handle corrupted header\n\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\theaders.set('Location', locationURL);\n\t\t\t\t\t\t\t} catch (err) {\n\t\t\t\t\t\t\t\t// istanbul ignore next: nodejs server prevent invalid response headers, we can't test this through normal request\n\t\t\t\t\t\t\t\treject(err);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'follow':\n\t\t\t\t\t\t// HTTP-redirect fetch step 2\n\t\t\t\t\t\tif (locationURL === null) {\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// HTTP-redirect fetch step 5\n\t\t\t\t\t\tif (request.counter >= request.follow) {\n\t\t\t\t\t\t\treject(new FetchError(`maximum redirect reached at: ${request.url}`, 'max-redirect'));\n\t\t\t\t\t\t\tfinalize();\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// HTTP-redirect fetch step 6 (counter increment)\n\t\t\t\t\t\t// Create a new Request object.\n\t\t\t\t\t\tconst requestOpts = {\n\t\t\t\t\t\t\theaders: new Headers(request.headers),\n\t\t\t\t\t\t\tfollow: request.follow,\n\t\t\t\t\t\t\tcounter: request.counter + 1,\n\t\t\t\t\t\t\tagent: request.agent,\n\t\t\t\t\t\t\tcompress: request.compress,\n\t\t\t\t\t\t\tmethod: request.method,\n\t\t\t\t\t\t\tbody: request.body,\n\t\t\t\t\t\t\tsignal: request.signal,\n\t\t\t\t\t\t\ttimeout: request.timeout,\n\t\t\t\t\t\t\tsize: request.size\n\t\t\t\t\t\t};\n\n\t\t\t\t\t\tif (!isDomainOrSubdomain(request.url, locationURL)) {\n\t\t\t\t\t\t\tfor (const name of ['authorization', 'www-authenticate', 'cookie', 'cookie2']) {\n\t\t\t\t\t\t\t\trequestOpts.headers.delete(name);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// HTTP-redirect fetch step 9\n\t\t\t\t\t\tif (res.statusCode !== 303 && request.body && getTotalBytes(request) === null) {\n\t\t\t\t\t\t\treject(new FetchError('Cannot follow redirect with body being a readable stream', 'unsupported-redirect'));\n\t\t\t\t\t\t\tfinalize();\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// HTTP-redirect fetch step 11\n\t\t\t\t\t\tif (res.statusCode === 303 || (res.statusCode === 301 || res.statusCode === 302) && request.method === 'POST') {\n\t\t\t\t\t\t\trequestOpts.method = 'GET';\n\t\t\t\t\t\t\trequestOpts.body = undefined;\n\t\t\t\t\t\t\trequestOpts.headers.delete('content-length');\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// HTTP-redirect fetch step 15\n\t\t\t\t\t\tresolve(fetch(new Request(locationURL, requestOpts)));\n\t\t\t\t\t\tfinalize();\n\t\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// prepare response\n\t\t\tres.once('end', function () {\n\t\t\t\tif (signal) signal.removeEventListener('abort', abortAndFinalize);\n\t\t\t});\n\t\t\tlet body = res.pipe(new PassThrough$1());\n\n\t\t\tconst response_options = {\n\t\t\t\turl: request.url,\n\t\t\t\tstatus: res.statusCode,\n\t\t\t\tstatusText: res.statusMessage,\n\t\t\t\theaders: headers,\n\t\t\t\tsize: request.size,\n\t\t\t\ttimeout: request.timeout,\n\t\t\t\tcounter: request.counter\n\t\t\t};\n\n\t\t\t// HTTP-network fetch step 12.1.1.3\n\t\t\tconst codings = headers.get('Content-Encoding');\n\n\t\t\t// HTTP-network fetch step 12.1.1.4: handle content codings\n\n\t\t\t// in following scenarios we ignore compression support\n\t\t\t// 1. compression support is disabled\n\t\t\t// 2. HEAD request\n\t\t\t// 3. no Content-Encoding header\n\t\t\t// 4. no content response (204)\n\t\t\t// 5. content not modified response (304)\n\t\t\tif (!request.compress || request.method === 'HEAD' || codings === null || res.statusCode === 204 || res.statusCode === 304) {\n\t\t\t\tresponse = new Response(body, response_options);\n\t\t\t\tresolve(response);\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t// For Node v6+\n\t\t\t// Be less strict when decoding compressed responses, since sometimes\n\t\t\t// servers send slightly invalid responses that are still accepted\n\t\t\t// by common browsers.\n\t\t\t// Always using Z_SYNC_FLUSH is what cURL does.\n\t\t\tconst zlibOptions = {\n\t\t\t\tflush: zlib.Z_SYNC_FLUSH,\n\t\t\t\tfinishFlush: zlib.Z_SYNC_FLUSH\n\t\t\t};\n\n\t\t\t// for gzip\n\t\t\tif (codings == 'gzip' || codings == 'x-gzip') {\n\t\t\t\tbody = body.pipe(zlib.createGunzip(zlibOptions));\n\t\t\t\tresponse = new Response(body, response_options);\n\t\t\t\tresolve(response);\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t// for deflate\n\t\t\tif (codings == 'deflate' || codings == 'x-deflate') {\n\t\t\t\t// handle the infamous raw deflate response from old servers\n\t\t\t\t// a hack for old IIS and Apache servers\n\t\t\t\tconst raw = res.pipe(new PassThrough$1());\n\t\t\t\traw.once('data', function (chunk) {\n\t\t\t\t\t// see http://stackoverflow.com/questions/37519828\n\t\t\t\t\tif ((chunk[0] & 0x0F) === 0x08) {\n\t\t\t\t\t\tbody = body.pipe(zlib.createInflate());\n\t\t\t\t\t} else {\n\t\t\t\t\t\tbody = body.pipe(zlib.createInflateRaw());\n\t\t\t\t\t}\n\t\t\t\t\tresponse = new Response(body, response_options);\n\t\t\t\t\tresolve(response);\n\t\t\t\t});\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t// for br\n\t\t\tif (codings == 'br' && typeof zlib.createBrotliDecompress === 'function') {\n\t\t\t\tbody = body.pipe(zlib.createBrotliDecompress());\n\t\t\t\tresponse = new Response(body, response_options);\n\t\t\t\tresolve(response);\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t// otherwise, use response as-is\n\t\t\tresponse = new Response(body, response_options);\n\t\t\tresolve(response);\n\t\t});\n\n\t\twriteToStream(req, request);\n\t});\n}\n/**\n * Redirect code matching\n *\n * @param Number code Status code\n * @return Boolean\n */\nfetch.isRedirect = function (code) {\n\treturn code === 301 || code === 302 || code === 303 || code === 307 || code === 308;\n};\n\n// expose Promise\nfetch.Promise = global.Promise;\n\nmodule.exports = exports = fetch;\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.default = exports;\nexports.Headers = Headers;\nexports.Request = Request;\nexports.Response = Response;\nexports.FetchError = FetchError;\n", "'use strict';\n\nObject.defineProperty(exports, '__esModule', { value: true });\n\nclass Deprecation extends Error {\n constructor(message) {\n super(message); // Maintains proper stack trace (only available on V8)\n\n /* istanbul ignore next */\n\n if (Error.captureStackTrace) {\n Error.captureStackTrace(this, this.constructor);\n }\n\n this.name = 'Deprecation';\n }\n\n}\n\nexports.Deprecation = Deprecation;\n", "// Returns a wrapper function that returns a wrapped callback\n// The wrapper function should do some stuff, and return a\n// presumably different callback function.\n// This makes sure that own properties are retained, so that\n// decorations and such are not lost along the way.\nmodule.exports = wrappy\nfunction wrappy (fn, cb) {\n if (fn && cb) return wrappy(fn)(cb)\n\n if (typeof fn !== 'function')\n throw new TypeError('need wrapper function')\n\n Object.keys(fn).forEach(function (k) {\n wrapper[k] = fn[k]\n })\n\n return wrapper\n\n function wrapper() {\n var args = new Array(arguments.length)\n for (var i = 0; i < args.length; i++) {\n args[i] = arguments[i]\n }\n var ret = fn.apply(this, args)\n var cb = args[args.length-1]\n if (typeof ret === 'function' && ret !== cb) {\n Object.keys(cb).forEach(function (k) {\n ret[k] = cb[k]\n })\n }\n return ret\n }\n}\n", "var wrappy = require('wrappy')\nmodule.exports = wrappy(once)\nmodule.exports.strict = wrappy(onceStrict)\n\nonce.proto = once(function () {\n Object.defineProperty(Function.prototype, 'once', {\n value: function () {\n return once(this)\n },\n configurable: true\n })\n\n Object.defineProperty(Function.prototype, 'onceStrict', {\n value: function () {\n return onceStrict(this)\n },\n configurable: true\n })\n})\n\nfunction once (fn) {\n var f = function () {\n if (f.called) return f.value\n f.called = true\n return f.value = fn.apply(this, arguments)\n }\n f.called = false\n return f\n}\n\nfunction onceStrict (fn) {\n var f = function () {\n if (f.called)\n throw new Error(f.onceError)\n f.called = true\n return f.value = fn.apply(this, arguments)\n }\n var name = fn.name || 'Function wrapped with `once`'\n f.onceError = name + \" shouldn't be called more than once\"\n f.called = false\n return f\n}\n", "import { Deprecation } from \"deprecation\";\nimport once from \"once\";\nconst logOnceCode = once((deprecation) => console.warn(deprecation));\nconst logOnceHeaders = once((deprecation) => console.warn(deprecation));\n/**\n * Error with extra properties to help with debugging\n */\nexport class RequestError extends Error {\n constructor(message, statusCode, options) {\n super(message);\n // Maintains proper stack trace (only available on V8)\n /* istanbul ignore next */\n if (Error.captureStackTrace) {\n Error.captureStackTrace(this, this.constructor);\n }\n this.name = \"HttpError\";\n this.status = statusCode;\n let headers;\n if (\"headers\" in options && typeof options.headers !== \"undefined\") {\n headers = options.headers;\n }\n if (\"response\" in options) {\n this.response = options.response;\n headers = options.response.headers;\n }\n // redact request credentials without mutating original request options\n const requestCopy = Object.assign({}, options.request);\n if (options.request.headers.authorization) {\n requestCopy.headers = Object.assign({}, options.request.headers, {\n authorization: options.request.headers.authorization.replace(/ .*$/, \" [REDACTED]\"),\n });\n }\n requestCopy.url = requestCopy.url\n // client_id & client_secret can be passed as URL query parameters to increase rate limit\n // see https://developer.github.com/v3/#increasing-the-unauthenticated-rate-limit-for-oauth-applications\n .replace(/\\bclient_secret=\\w+/g, \"client_secret=[REDACTED]\")\n // OAuth tokens can be passed as URL query parameters, although it is not recommended\n // see https://developer.github.com/v3/#oauth2-token-sent-in-a-header\n .replace(/\\baccess_token=\\w+/g, \"access_token=[REDACTED]\");\n this.request = requestCopy;\n // deprecations\n Object.defineProperty(this, \"code\", {\n get() {\n logOnceCode(new Deprecation(\"[@octokit/request-error] `error.code` is deprecated, use `error.status`.\"));\n return statusCode;\n },\n });\n Object.defineProperty(this, \"headers\", {\n get() {\n logOnceHeaders(new Deprecation(\"[@octokit/request-error] `error.headers` is deprecated, use `error.response.headers`.\"));\n return headers || {};\n },\n });\n }\n}\n", "export const VERSION = \"5.6.3\";\n", "export default function getBufferResponse(response) {\n return response.arrayBuffer();\n}\n", "import { isPlainObject } from \"is-plain-object\";\nimport nodeFetch from \"node-fetch\";\nimport { RequestError } from \"@octokit/request-error\";\nimport getBuffer from \"./get-buffer-response\";\nexport default function fetchWrapper(requestOptions) {\n const log = requestOptions.request && requestOptions.request.log\n ? requestOptions.request.log\n : console;\n if (isPlainObject(requestOptions.body) ||\n Array.isArray(requestOptions.body)) {\n requestOptions.body = JSON.stringify(requestOptions.body);\n }\n let headers = {};\n let status;\n let url;\n const fetch = (requestOptions.request && requestOptions.request.fetch) || nodeFetch;\n return fetch(requestOptions.url, Object.assign({\n method: requestOptions.method,\n body: requestOptions.body,\n headers: requestOptions.headers,\n redirect: requestOptions.redirect,\n }, \n // `requestOptions.request.agent` type is incompatible\n // see https://github.com/octokit/types.ts/pull/264\n requestOptions.request))\n .then(async (response) => {\n url = response.url;\n status = response.status;\n for (const keyAndValue of response.headers) {\n headers[keyAndValue[0]] = keyAndValue[1];\n }\n if (\"deprecation\" in headers) {\n const matches = headers.link && headers.link.match(/<([^>]+)>; rel=\"deprecation\"/);\n const deprecationLink = matches && matches.pop();\n log.warn(`[@octokit/request] \"${requestOptions.method} ${requestOptions.url}\" is deprecated. It is scheduled to be removed on ${headers.sunset}${deprecationLink ? `. See ${deprecationLink}` : \"\"}`);\n }\n if (status === 204 || status === 205) {\n return;\n }\n // GitHub API returns 200 for HEAD requests\n if (requestOptions.method === \"HEAD\") {\n if (status < 400) {\n return;\n }\n throw new RequestError(response.statusText, status, {\n response: {\n url,\n status,\n headers,\n data: undefined,\n },\n request: requestOptions,\n });\n }\n if (status === 304) {\n throw new RequestError(\"Not modified\", status, {\n response: {\n url,\n status,\n headers,\n data: await getResponseData(response),\n },\n request: requestOptions,\n });\n }\n if (status >= 400) {\n const data = await getResponseData(response);\n const error = new RequestError(toErrorMessage(data), status, {\n response: {\n url,\n status,\n headers,\n data,\n },\n request: requestOptions,\n });\n throw error;\n }\n return getResponseData(response);\n })\n .then((data) => {\n return {\n status,\n url,\n headers,\n data,\n };\n })\n .catch((error) => {\n if (error instanceof RequestError)\n throw error;\n throw new RequestError(error.message, 500, {\n request: requestOptions,\n });\n });\n}\nasync function getResponseData(response) {\n const contentType = response.headers.get(\"content-type\");\n if (/application\\/json/.test(contentType)) {\n return response.json();\n }\n if (!contentType || /^text\\/|charset=utf-8$/.test(contentType)) {\n return response.text();\n }\n return getBuffer(response);\n}\nfunction toErrorMessage(data) {\n if (typeof data === \"string\")\n return data;\n // istanbul ignore else - just in case\n if (\"message\" in data) {\n if (Array.isArray(data.errors)) {\n return `${data.message}: ${data.errors.map(JSON.stringify).join(\", \")}`;\n }\n return data.message;\n }\n // istanbul ignore next - just in case\n return `Unknown error: ${JSON.stringify(data)}`;\n}\n", "import fetchWrapper from \"./fetch-wrapper\";\nexport default function withDefaults(oldEndpoint, newDefaults) {\n const endpoint = oldEndpoint.defaults(newDefaults);\n const newApi = function (route, parameters) {\n const endpointOptions = endpoint.merge(route, parameters);\n if (!endpointOptions.request || !endpointOptions.request.hook) {\n return fetchWrapper(endpoint.parse(endpointOptions));\n }\n const request = (route, parameters) => {\n return fetchWrapper(endpoint.parse(endpoint.merge(route, parameters)));\n };\n Object.assign(request, {\n endpoint,\n defaults: withDefaults.bind(null, endpoint),\n });\n return endpointOptions.request.hook(request, endpointOptions);\n };\n return Object.assign(newApi, {\n endpoint,\n defaults: withDefaults.bind(null, endpoint),\n });\n}\n", "import { endpoint } from \"@octokit/endpoint\";\nimport { getUserAgent } from \"universal-user-agent\";\nimport { VERSION } from \"./version\";\nimport withDefaults from \"./with-defaults\";\nexport const request = withDefaults(endpoint, {\n headers: {\n \"user-agent\": `octokit-request.js/${VERSION} ${getUserAgent()}`,\n },\n});\n", "export const VERSION = \"4.8.0\";\n", "function _buildMessageForResponseErrors(data) {\n return (`Request failed due to following response errors:\\n` +\n data.errors.map((e) => ` - ${e.message}`).join(\"\\n\"));\n}\nexport class GraphqlResponseError extends Error {\n constructor(request, headers, response) {\n super(_buildMessageForResponseErrors(response));\n this.request = request;\n this.headers = headers;\n this.response = response;\n this.name = \"GraphqlResponseError\";\n // Expose the errors and response data in their shorthand properties.\n this.errors = response.errors;\n this.data = response.data;\n // Maintains proper stack trace (only available on V8)\n /* istanbul ignore next */\n if (Error.captureStackTrace) {\n Error.captureStackTrace(this, this.constructor);\n }\n }\n}\n", "import { GraphqlResponseError } from \"./error\";\nconst NON_VARIABLE_OPTIONS = [\n \"method\",\n \"baseUrl\",\n \"url\",\n \"headers\",\n \"request\",\n \"query\",\n \"mediaType\",\n];\nconst FORBIDDEN_VARIABLE_OPTIONS = [\"query\", \"method\", \"url\"];\nconst GHES_V3_SUFFIX_REGEX = /\\/api\\/v3\\/?$/;\nexport function graphql(request, query, options) {\n if (options) {\n if (typeof query === \"string\" && \"query\" in options) {\n return Promise.reject(new Error(`[@octokit/graphql] \"query\" cannot be used as variable name`));\n }\n for (const key in options) {\n if (!FORBIDDEN_VARIABLE_OPTIONS.includes(key))\n continue;\n return Promise.reject(new Error(`[@octokit/graphql] \"${key}\" cannot be used as variable name`));\n }\n }\n const parsedOptions = typeof query === \"string\" ? Object.assign({ query }, options) : query;\n const requestOptions = Object.keys(parsedOptions).reduce((result, key) => {\n if (NON_VARIABLE_OPTIONS.includes(key)) {\n result[key] = parsedOptions[key];\n return result;\n }\n if (!result.variables) {\n result.variables = {};\n }\n result.variables[key] = parsedOptions[key];\n return result;\n }, {});\n // workaround for GitHub Enterprise baseUrl set with /api/v3 suffix\n // https://github.com/octokit/auth-app.js/issues/111#issuecomment-657610451\n const baseUrl = parsedOptions.baseUrl || request.endpoint.DEFAULTS.baseUrl;\n if (GHES_V3_SUFFIX_REGEX.test(baseUrl)) {\n requestOptions.url = baseUrl.replace(GHES_V3_SUFFIX_REGEX, \"/api/graphql\");\n }\n return request(requestOptions).then((response) => {\n if (response.data.errors) {\n const headers = {};\n for (const key of Object.keys(response.headers)) {\n headers[key] = response.headers[key];\n }\n throw new GraphqlResponseError(requestOptions, headers, response.data);\n }\n return response.data.data;\n });\n}\n", "import { request as Request } from \"@octokit/request\";\nimport { graphql } from \"./graphql\";\nexport function withDefaults(request, newDefaults) {\n const newRequest = request.defaults(newDefaults);\n const newApi = (query, options) => {\n return graphql(newRequest, query, options);\n };\n return Object.assign(newApi, {\n defaults: withDefaults.bind(null, newRequest),\n endpoint: Request.endpoint,\n });\n}\n", "import { request } from \"@octokit/request\";\nimport { getUserAgent } from \"universal-user-agent\";\nimport { VERSION } from \"./version\";\nimport { withDefaults } from \"./with-defaults\";\nexport const graphql = withDefaults(request, {\n headers: {\n \"user-agent\": `octokit-graphql.js/${VERSION} ${getUserAgent()}`,\n },\n method: \"POST\",\n url: \"/graphql\",\n});\nexport { GraphqlResponseError } from \"./error\";\nexport function withCustomRequest(customRequest) {\n return withDefaults(customRequest, {\n method: \"POST\",\n url: \"/graphql\",\n });\n}\n", "const REGEX_IS_INSTALLATION_LEGACY = /^v1\\./;\nconst REGEX_IS_INSTALLATION = /^ghs_/;\nconst REGEX_IS_USER_TO_SERVER = /^ghu_/;\nexport async function auth(token) {\n const isApp = token.split(/\\./).length === 3;\n const isInstallation = REGEX_IS_INSTALLATION_LEGACY.test(token) ||\n REGEX_IS_INSTALLATION.test(token);\n const isUserToServer = REGEX_IS_USER_TO_SERVER.test(token);\n const tokenType = isApp\n ? \"app\"\n : isInstallation\n ? \"installation\"\n : isUserToServer\n ? \"user-to-server\"\n : \"oauth\";\n return {\n type: \"token\",\n token: token,\n tokenType,\n };\n}\n", "/**\n * Prefix token for usage in the Authorization header\n *\n * @param token OAuth token or JSON Web Token\n */\nexport function withAuthorizationPrefix(token) {\n if (token.split(/\\./).length === 3) {\n return `bearer ${token}`;\n }\n return `token ${token}`;\n}\n", "import { withAuthorizationPrefix } from \"./with-authorization-prefix\";\nexport async function hook(token, request, route, parameters) {\n const endpoint = request.endpoint.merge(route, parameters);\n endpoint.headers.authorization = withAuthorizationPrefix(token);\n return request(endpoint);\n}\n", "import { auth } from \"./auth\";\nimport { hook } from \"./hook\";\nexport const createTokenAuth = function createTokenAuth(token) {\n if (!token) {\n throw new Error(\"[@octokit/auth-token] No token passed to createTokenAuth\");\n }\n if (typeof token !== \"string\") {\n throw new Error(\"[@octokit/auth-token] Token passed to createTokenAuth is not a string\");\n }\n token = token.replace(/^(token|bearer) +/i, \"\");\n return Object.assign(auth.bind(null, token), {\n hook: hook.bind(null, token),\n });\n};\n", "export const VERSION = \"3.6.0\";\n", "import { getUserAgent } from \"universal-user-agent\";\nimport { Collection } from \"before-after-hook\";\nimport { request } from \"@octokit/request\";\nimport { withCustomRequest } from \"@octokit/graphql\";\nimport { createTokenAuth } from \"@octokit/auth-token\";\nimport { VERSION } from \"./version\";\nexport class Octokit {\n constructor(options = {}) {\n const hook = new Collection();\n const requestDefaults = {\n baseUrl: request.endpoint.DEFAULTS.baseUrl,\n headers: {},\n request: Object.assign({}, options.request, {\n // @ts-ignore internal usage only, no need to type\n hook: hook.bind(null, \"request\"),\n }),\n mediaType: {\n previews: [],\n format: \"\",\n },\n };\n // prepend default user agent with `options.userAgent` if set\n requestDefaults.headers[\"user-agent\"] = [\n options.userAgent,\n `octokit-core.js/${VERSION} ${getUserAgent()}`,\n ]\n .filter(Boolean)\n .join(\" \");\n if (options.baseUrl) {\n requestDefaults.baseUrl = options.baseUrl;\n }\n if (options.previews) {\n requestDefaults.mediaType.previews = options.previews;\n }\n if (options.timeZone) {\n requestDefaults.headers[\"time-zone\"] = options.timeZone;\n }\n this.request = request.defaults(requestDefaults);\n this.graphql = withCustomRequest(this.request).defaults(requestDefaults);\n this.log = Object.assign({\n debug: () => { },\n info: () => { },\n warn: console.warn.bind(console),\n error: console.error.bind(console),\n }, options.log);\n this.hook = hook;\n // (1) If neither `options.authStrategy` nor `options.auth` are set, the `octokit` instance\n // is unauthenticated. The `this.auth()` method is a no-op and no request hook is registered.\n // (2) If only `options.auth` is set, use the default token authentication strategy.\n // (3) If `options.authStrategy` is set then use it and pass in `options.auth`. Always pass own request as many strategies accept a custom request instance.\n // TODO: type `options.auth` based on `options.authStrategy`.\n if (!options.authStrategy) {\n if (!options.auth) {\n // (1)\n this.auth = async () => ({\n type: \"unauthenticated\",\n });\n }\n else {\n // (2)\n const auth = createTokenAuth(options.auth);\n // @ts-ignore \u00AF\\_(\u30C4)_/\u00AF\n hook.wrap(\"request\", auth.hook);\n this.auth = auth;\n }\n }\n else {\n const { authStrategy, ...otherOptions } = options;\n const auth = authStrategy(Object.assign({\n request: this.request,\n log: this.log,\n // we pass the current octokit instance as well as its constructor options\n // to allow for authentication strategies that return a new octokit instance\n // that shares the same internal state as the current one. The original\n // requirement for this was the \"event-octokit\" authentication strategy\n // of https://github.com/probot/octokit-auth-probot.\n octokit: this,\n octokitOptions: otherOptions,\n }, options.auth));\n // @ts-ignore \u00AF\\_(\u30C4)_/\u00AF\n hook.wrap(\"request\", auth.hook);\n this.auth = auth;\n }\n // apply plugins\n // https://stackoverflow.com/a/16345172\n const classConstructor = this.constructor;\n classConstructor.plugins.forEach((plugin) => {\n Object.assign(this, plugin(this, options));\n });\n }\n static defaults(defaults) {\n const OctokitWithDefaults = class extends this {\n constructor(...args) {\n const options = args[0] || {};\n if (typeof defaults === \"function\") {\n super(defaults(options));\n return;\n }\n super(Object.assign({}, defaults, options, options.userAgent && defaults.userAgent\n ? {\n userAgent: `${options.userAgent} ${defaults.userAgent}`,\n }\n : null));\n }\n };\n return OctokitWithDefaults;\n }\n /**\n * Attach a plugin (or many) to your Octokit instance.\n *\n * @example\n * const API = Octokit.plugin(plugin1, plugin2, plugin3, ...)\n */\n static plugin(...newPlugins) {\n var _a;\n const currentPlugins = this.plugins;\n const NewOctokit = (_a = class extends this {\n },\n _a.plugins = currentPlugins.concat(newPlugins.filter((plugin) => !currentPlugins.includes(plugin))),\n _a);\n return NewOctokit;\n }\n}\nOctokit.VERSION = VERSION;\nOctokit.plugins = [];\n", "const Endpoints = {\n actions: {\n addCustomLabelsToSelfHostedRunnerForOrg: [\n \"POST /orgs/{org}/actions/runners/{runner_id}/labels\",\n ],\n addCustomLabelsToSelfHostedRunnerForRepo: [\n \"POST /repos/{owner}/{repo}/actions/runners/{runner_id}/labels\",\n ],\n addSelectedRepoToOrgSecret: [\n \"PUT /orgs/{org}/actions/secrets/{secret_name}/repositories/{repository_id}\",\n ],\n approveWorkflowRun: [\n \"POST /repos/{owner}/{repo}/actions/runs/{run_id}/approve\",\n ],\n cancelWorkflowRun: [\n \"POST /repos/{owner}/{repo}/actions/runs/{run_id}/cancel\",\n ],\n createOrUpdateEnvironmentSecret: [\n \"PUT /repositories/{repository_id}/environments/{environment_name}/secrets/{secret_name}\",\n ],\n createOrUpdateOrgSecret: [\"PUT /orgs/{org}/actions/secrets/{secret_name}\"],\n createOrUpdateRepoSecret: [\n \"PUT /repos/{owner}/{repo}/actions/secrets/{secret_name}\",\n ],\n createRegistrationTokenForOrg: [\n \"POST /orgs/{org}/actions/runners/registration-token\",\n ],\n createRegistrationTokenForRepo: [\n \"POST /repos/{owner}/{repo}/actions/runners/registration-token\",\n ],\n createRemoveTokenForOrg: [\"POST /orgs/{org}/actions/runners/remove-token\"],\n createRemoveTokenForRepo: [\n \"POST /repos/{owner}/{repo}/actions/runners/remove-token\",\n ],\n createWorkflowDispatch: [\n \"POST /repos/{owner}/{repo}/actions/workflows/{workflow_id}/dispatches\",\n ],\n deleteActionsCacheById: [\n \"DELETE /repos/{owner}/{repo}/actions/caches/{cache_id}\",\n ],\n deleteActionsCacheByKey: [\n \"DELETE /repos/{owner}/{repo}/actions/caches{?key,ref}\",\n ],\n deleteArtifact: [\n \"DELETE /repos/{owner}/{repo}/actions/artifacts/{artifact_id}\",\n ],\n deleteEnvironmentSecret: [\n \"DELETE /repositories/{repository_id}/environments/{environment_name}/secrets/{secret_name}\",\n ],\n deleteOrgSecret: [\"DELETE /orgs/{org}/actions/secrets/{secret_name}\"],\n deleteRepoSecret: [\n \"DELETE /repos/{owner}/{repo}/actions/secrets/{secret_name}\",\n ],\n deleteSelfHostedRunnerFromOrg: [\n \"DELETE /orgs/{org}/actions/runners/{runner_id}\",\n ],\n deleteSelfHostedRunnerFromRepo: [\n \"DELETE /repos/{owner}/{repo}/actions/runners/{runner_id}\",\n ],\n deleteWorkflowRun: [\"DELETE /repos/{owner}/{repo}/actions/runs/{run_id}\"],\n deleteWorkflowRunLogs: [\n \"DELETE /repos/{owner}/{repo}/actions/runs/{run_id}/logs\",\n ],\n disableSelectedRepositoryGithubActionsOrganization: [\n \"DELETE /orgs/{org}/actions/permissions/repositories/{repository_id}\",\n ],\n disableWorkflow: [\n \"PUT /repos/{owner}/{repo}/actions/workflows/{workflow_id}/disable\",\n ],\n downloadArtifact: [\n \"GET /repos/{owner}/{repo}/actions/artifacts/{artifact_id}/{archive_format}\",\n ],\n downloadJobLogsForWorkflowRun: [\n \"GET /repos/{owner}/{repo}/actions/jobs/{job_id}/logs\",\n ],\n downloadWorkflowRunAttemptLogs: [\n \"GET /repos/{owner}/{repo}/actions/runs/{run_id}/attempts/{attempt_number}/logs\",\n ],\n downloadWorkflowRunLogs: [\n \"GET /repos/{owner}/{repo}/actions/runs/{run_id}/logs\",\n ],\n enableSelectedRepositoryGithubActionsOrganization: [\n \"PUT /orgs/{org}/actions/permissions/repositories/{repository_id}\",\n ],\n enableWorkflow: [\n \"PUT /repos/{owner}/{repo}/actions/workflows/{workflow_id}/enable\",\n ],\n getActionsCacheList: [\"GET /repos/{owner}/{repo}/actions/caches\"],\n getActionsCacheUsage: [\"GET /repos/{owner}/{repo}/actions/cache/usage\"],\n getActionsCacheUsageByRepoForOrg: [\n \"GET /orgs/{org}/actions/cache/usage-by-repository\",\n ],\n getActionsCacheUsageForEnterprise: [\n \"GET /enterprises/{enterprise}/actions/cache/usage\",\n ],\n getActionsCacheUsageForOrg: [\"GET /orgs/{org}/actions/cache/usage\"],\n getAllowedActionsOrganization: [\n \"GET /orgs/{org}/actions/permissions/selected-actions\",\n ],\n getAllowedActionsRepository: [\n \"GET /repos/{owner}/{repo}/actions/permissions/selected-actions\",\n ],\n getArtifact: [\"GET /repos/{owner}/{repo}/actions/artifacts/{artifact_id}\"],\n getEnvironmentPublicKey: [\n \"GET /repositories/{repository_id}/environments/{environment_name}/secrets/public-key\",\n ],\n getEnvironmentSecret: [\n \"GET /repositories/{repository_id}/environments/{environment_name}/secrets/{secret_name}\",\n ],\n getGithubActionsDefaultWorkflowPermissionsEnterprise: [\n \"GET /enterprises/{enterprise}/actions/permissions/workflow\",\n ],\n getGithubActionsDefaultWorkflowPermissionsOrganization: [\n \"GET /orgs/{org}/actions/permissions/workflow\",\n ],\n getGithubActionsDefaultWorkflowPermissionsRepository: [\n \"GET /repos/{owner}/{repo}/actions/permissions/workflow\",\n ],\n getGithubActionsPermissionsOrganization: [\n \"GET /orgs/{org}/actions/permissions\",\n ],\n getGithubActionsPermissionsRepository: [\n \"GET /repos/{owner}/{repo}/actions/permissions\",\n ],\n getJobForWorkflowRun: [\"GET /repos/{owner}/{repo}/actions/jobs/{job_id}\"],\n getOrgPublicKey: [\"GET /orgs/{org}/actions/secrets/public-key\"],\n getOrgSecret: [\"GET /orgs/{org}/actions/secrets/{secret_name}\"],\n getPendingDeploymentsForRun: [\n \"GET /repos/{owner}/{repo}/actions/runs/{run_id}/pending_deployments\",\n ],\n getRepoPermissions: [\n \"GET /repos/{owner}/{repo}/actions/permissions\",\n {},\n { renamed: [\"actions\", \"getGithubActionsPermissionsRepository\"] },\n ],\n getRepoPublicKey: [\"GET /repos/{owner}/{repo}/actions/secrets/public-key\"],\n getRepoSecret: [\"GET /repos/{owner}/{repo}/actions/secrets/{secret_name}\"],\n getReviewsForRun: [\n \"GET /repos/{owner}/{repo}/actions/runs/{run_id}/approvals\",\n ],\n getSelfHostedRunnerForOrg: [\"GET /orgs/{org}/actions/runners/{runner_id}\"],\n getSelfHostedRunnerForRepo: [\n \"GET /repos/{owner}/{repo}/actions/runners/{runner_id}\",\n ],\n getWorkflow: [\"GET /repos/{owner}/{repo}/actions/workflows/{workflow_id}\"],\n getWorkflowAccessToRepository: [\n \"GET /repos/{owner}/{repo}/actions/permissions/access\",\n ],\n getWorkflowRun: [\"GET /repos/{owner}/{repo}/actions/runs/{run_id}\"],\n getWorkflowRunAttempt: [\n \"GET /repos/{owner}/{repo}/actions/runs/{run_id}/attempts/{attempt_number}\",\n ],\n getWorkflowRunUsage: [\n \"GET /repos/{owner}/{repo}/actions/runs/{run_id}/timing\",\n ],\n getWorkflowUsage: [\n \"GET /repos/{owner}/{repo}/actions/workflows/{workflow_id}/timing\",\n ],\n listArtifactsForRepo: [\"GET /repos/{owner}/{repo}/actions/artifacts\"],\n listEnvironmentSecrets: [\n \"GET /repositories/{repository_id}/environments/{environment_name}/secrets\",\n ],\n listJobsForWorkflowRun: [\n \"GET /repos/{owner}/{repo}/actions/runs/{run_id}/jobs\",\n ],\n listJobsForWorkflowRunAttempt: [\n \"GET /repos/{owner}/{repo}/actions/runs/{run_id}/attempts/{attempt_number}/jobs\",\n ],\n listLabelsForSelfHostedRunnerForOrg: [\n \"GET /orgs/{org}/actions/runners/{runner_id}/labels\",\n ],\n listLabelsForSelfHostedRunnerForRepo: [\n \"GET /repos/{owner}/{repo}/actions/runners/{runner_id}/labels\",\n ],\n listOrgSecrets: [\"GET /orgs/{org}/actions/secrets\"],\n listRepoSecrets: [\"GET /repos/{owner}/{repo}/actions/secrets\"],\n listRepoWorkflows: [\"GET /repos/{owner}/{repo}/actions/workflows\"],\n listRunnerApplicationsForOrg: [\"GET /orgs/{org}/actions/runners/downloads\"],\n listRunnerApplicationsForRepo: [\n \"GET /repos/{owner}/{repo}/actions/runners/downloads\",\n ],\n listSelectedReposForOrgSecret: [\n \"GET /orgs/{org}/actions/secrets/{secret_name}/repositories\",\n ],\n listSelectedRepositoriesEnabledGithubActionsOrganization: [\n \"GET /orgs/{org}/actions/permissions/repositories\",\n ],\n listSelfHostedRunnersForOrg: [\"GET /orgs/{org}/actions/runners\"],\n listSelfHostedRunnersForRepo: [\"GET /repos/{owner}/{repo}/actions/runners\"],\n listWorkflowRunArtifacts: [\n \"GET /repos/{owner}/{repo}/actions/runs/{run_id}/artifacts\",\n ],\n listWorkflowRuns: [\n \"GET /repos/{owner}/{repo}/actions/workflows/{workflow_id}/runs\",\n ],\n listWorkflowRunsForRepo: [\"GET /repos/{owner}/{repo}/actions/runs\"],\n reRunJobForWorkflowRun: [\n \"POST /repos/{owner}/{repo}/actions/jobs/{job_id}/rerun\",\n ],\n reRunWorkflow: [\"POST /repos/{owner}/{repo}/actions/runs/{run_id}/rerun\"],\n reRunWorkflowFailedJobs: [\n \"POST /repos/{owner}/{repo}/actions/runs/{run_id}/rerun-failed-jobs\",\n ],\n removeAllCustomLabelsFromSelfHostedRunnerForOrg: [\n \"DELETE /orgs/{org}/actions/runners/{runner_id}/labels\",\n ],\n removeAllCustomLabelsFromSelfHostedRunnerForRepo: [\n \"DELETE /repos/{owner}/{repo}/actions/runners/{runner_id}/labels\",\n ],\n removeCustomLabelFromSelfHostedRunnerForOrg: [\n \"DELETE /orgs/{org}/actions/runners/{runner_id}/labels/{name}\",\n ],\n removeCustomLabelFromSelfHostedRunnerForRepo: [\n \"DELETE /repos/{owner}/{repo}/actions/runners/{runner_id}/labels/{name}\",\n ],\n removeSelectedRepoFromOrgSecret: [\n \"DELETE /orgs/{org}/actions/secrets/{secret_name}/repositories/{repository_id}\",\n ],\n reviewPendingDeploymentsForRun: [\n \"POST /repos/{owner}/{repo}/actions/runs/{run_id}/pending_deployments\",\n ],\n setAllowedActionsOrganization: [\n \"PUT /orgs/{org}/actions/permissions/selected-actions\",\n ],\n setAllowedActionsRepository: [\n \"PUT /repos/{owner}/{repo}/actions/permissions/selected-actions\",\n ],\n setCustomLabelsForSelfHostedRunnerForOrg: [\n \"PUT /orgs/{org}/actions/runners/{runner_id}/labels\",\n ],\n setCustomLabelsForSelfHostedRunnerForRepo: [\n \"PUT /repos/{owner}/{repo}/actions/runners/{runner_id}/labels\",\n ],\n setGithubActionsDefaultWorkflowPermissionsEnterprise: [\n \"PUT /enterprises/{enterprise}/actions/permissions/workflow\",\n ],\n setGithubActionsDefaultWorkflowPermissionsOrganization: [\n \"PUT /orgs/{org}/actions/permissions/workflow\",\n ],\n setGithubActionsDefaultWorkflowPermissionsRepository: [\n \"PUT /repos/{owner}/{repo}/actions/permissions/workflow\",\n ],\n setGithubActionsPermissionsOrganization: [\n \"PUT /orgs/{org}/actions/permissions\",\n ],\n setGithubActionsPermissionsRepository: [\n \"PUT /repos/{owner}/{repo}/actions/permissions\",\n ],\n setSelectedReposForOrgSecret: [\n \"PUT /orgs/{org}/actions/secrets/{secret_name}/repositories\",\n ],\n setSelectedRepositoriesEnabledGithubActionsOrganization: [\n \"PUT /orgs/{org}/actions/permissions/repositories\",\n ],\n setWorkflowAccessToRepository: [\n \"PUT /repos/{owner}/{repo}/actions/permissions/access\",\n ],\n },\n activity: {\n checkRepoIsStarredByAuthenticatedUser: [\"GET /user/starred/{owner}/{repo}\"],\n deleteRepoSubscription: [\"DELETE /repos/{owner}/{repo}/subscription\"],\n deleteThreadSubscription: [\n \"DELETE /notifications/threads/{thread_id}/subscription\",\n ],\n getFeeds: [\"GET /feeds\"],\n getRepoSubscription: [\"GET /repos/{owner}/{repo}/subscription\"],\n getThread: [\"GET /notifications/threads/{thread_id}\"],\n getThreadSubscriptionForAuthenticatedUser: [\n \"GET /notifications/threads/{thread_id}/subscription\",\n ],\n listEventsForAuthenticatedUser: [\"GET /users/{username}/events\"],\n listNotificationsForAuthenticatedUser: [\"GET /notifications\"],\n listOrgEventsForAuthenticatedUser: [\n \"GET /users/{username}/events/orgs/{org}\",\n ],\n listPublicEvents: [\"GET /events\"],\n listPublicEventsForRepoNetwork: [\"GET /networks/{owner}/{repo}/events\"],\n listPublicEventsForUser: [\"GET /users/{username}/events/public\"],\n listPublicOrgEvents: [\"GET /orgs/{org}/events\"],\n listReceivedEventsForUser: [\"GET /users/{username}/received_events\"],\n listReceivedPublicEventsForUser: [\n \"GET /users/{username}/received_events/public\",\n ],\n listRepoEvents: [\"GET /repos/{owner}/{repo}/events\"],\n listRepoNotificationsForAuthenticatedUser: [\n \"GET /repos/{owner}/{repo}/notifications\",\n ],\n listReposStarredByAuthenticatedUser: [\"GET /user/starred\"],\n listReposStarredByUser: [\"GET /users/{username}/starred\"],\n listReposWatchedByUser: [\"GET /users/{username}/subscriptions\"],\n listStargazersForRepo: [\"GET /repos/{owner}/{repo}/stargazers\"],\n listWatchedReposForAuthenticatedUser: [\"GET /user/subscriptions\"],\n listWatchersForRepo: [\"GET /repos/{owner}/{repo}/subscribers\"],\n markNotificationsAsRead: [\"PUT /notifications\"],\n markRepoNotificationsAsRead: [\"PUT /repos/{owner}/{repo}/notifications\"],\n markThreadAsRead: [\"PATCH /notifications/threads/{thread_id}\"],\n setRepoSubscription: [\"PUT /repos/{owner}/{repo}/subscription\"],\n setThreadSubscription: [\n \"PUT /notifications/threads/{thread_id}/subscription\",\n ],\n starRepoForAuthenticatedUser: [\"PUT /user/starred/{owner}/{repo}\"],\n unstarRepoForAuthenticatedUser: [\"DELETE /user/starred/{owner}/{repo}\"],\n },\n apps: {\n addRepoToInstallation: [\n \"PUT /user/installations/{installation_id}/repositories/{repository_id}\",\n {},\n { renamed: [\"apps\", \"addRepoToInstallationForAuthenticatedUser\"] },\n ],\n addRepoToInstallationForAuthenticatedUser: [\n \"PUT /user/installations/{installation_id}/repositories/{repository_id}\",\n ],\n checkToken: [\"POST /applications/{client_id}/token\"],\n createFromManifest: [\"POST /app-manifests/{code}/conversions\"],\n createInstallationAccessToken: [\n \"POST /app/installations/{installation_id}/access_tokens\",\n ],\n deleteAuthorization: [\"DELETE /applications/{client_id}/grant\"],\n deleteInstallation: [\"DELETE /app/installations/{installation_id}\"],\n deleteToken: [\"DELETE /applications/{client_id}/token\"],\n getAuthenticated: [\"GET /app\"],\n getBySlug: [\"GET /apps/{app_slug}\"],\n getInstallation: [\"GET /app/installations/{installation_id}\"],\n getOrgInstallation: [\"GET /orgs/{org}/installation\"],\n getRepoInstallation: [\"GET /repos/{owner}/{repo}/installation\"],\n getSubscriptionPlanForAccount: [\n \"GET /marketplace_listing/accounts/{account_id}\",\n ],\n getSubscriptionPlanForAccountStubbed: [\n \"GET /marketplace_listing/stubbed/accounts/{account_id}\",\n ],\n getUserInstallation: [\"GET /users/{username}/installation\"],\n getWebhookConfigForApp: [\"GET /app/hook/config\"],\n getWebhookDelivery: [\"GET /app/hook/deliveries/{delivery_id}\"],\n listAccountsForPlan: [\"GET /marketplace_listing/plans/{plan_id}/accounts\"],\n listAccountsForPlanStubbed: [\n \"GET /marketplace_listing/stubbed/plans/{plan_id}/accounts\",\n ],\n listInstallationReposForAuthenticatedUser: [\n \"GET /user/installations/{installation_id}/repositories\",\n ],\n listInstallations: [\"GET /app/installations\"],\n listInstallationsForAuthenticatedUser: [\"GET /user/installations\"],\n listPlans: [\"GET /marketplace_listing/plans\"],\n listPlansStubbed: [\"GET /marketplace_listing/stubbed/plans\"],\n listReposAccessibleToInstallation: [\"GET /installation/repositories\"],\n listSubscriptionsForAuthenticatedUser: [\"GET /user/marketplace_purchases\"],\n listSubscriptionsForAuthenticatedUserStubbed: [\n \"GET /user/marketplace_purchases/stubbed\",\n ],\n listWebhookDeliveries: [\"GET /app/hook/deliveries\"],\n redeliverWebhookDelivery: [\n \"POST /app/hook/deliveries/{delivery_id}/attempts\",\n ],\n removeRepoFromInstallation: [\n \"DELETE /user/installations/{installation_id}/repositories/{repository_id}\",\n {},\n { renamed: [\"apps\", \"removeRepoFromInstallationForAuthenticatedUser\"] },\n ],\n removeRepoFromInstallationForAuthenticatedUser: [\n \"DELETE /user/installations/{installation_id}/repositories/{repository_id}\",\n ],\n resetToken: [\"PATCH /applications/{client_id}/token\"],\n revokeInstallationAccessToken: [\"DELETE /installation/token\"],\n scopeToken: [\"POST /applications/{client_id}/token/scoped\"],\n suspendInstallation: [\"PUT /app/installations/{installation_id}/suspended\"],\n unsuspendInstallation: [\n \"DELETE /app/installations/{installation_id}/suspended\",\n ],\n updateWebhookConfigForApp: [\"PATCH /app/hook/config\"],\n },\n billing: {\n getGithubActionsBillingOrg: [\"GET /orgs/{org}/settings/billing/actions\"],\n getGithubActionsBillingUser: [\n \"GET /users/{username}/settings/billing/actions\",\n ],\n getGithubAdvancedSecurityBillingGhe: [\n \"GET /enterprises/{enterprise}/settings/billing/advanced-security\",\n ],\n getGithubAdvancedSecurityBillingOrg: [\n \"GET /orgs/{org}/settings/billing/advanced-security\",\n ],\n getGithubPackagesBillingOrg: [\"GET /orgs/{org}/settings/billing/packages\"],\n getGithubPackagesBillingUser: [\n \"GET /users/{username}/settings/billing/packages\",\n ],\n getSharedStorageBillingOrg: [\n \"GET /orgs/{org}/settings/billing/shared-storage\",\n ],\n getSharedStorageBillingUser: [\n \"GET /users/{username}/settings/billing/shared-storage\",\n ],\n },\n checks: {\n create: [\"POST /repos/{owner}/{repo}/check-runs\"],\n createSuite: [\"POST /repos/{owner}/{repo}/check-suites\"],\n get: [\"GET /repos/{owner}/{repo}/check-runs/{check_run_id}\"],\n getSuite: [\"GET /repos/{owner}/{repo}/check-suites/{check_suite_id}\"],\n listAnnotations: [\n \"GET /repos/{owner}/{repo}/check-runs/{check_run_id}/annotations\",\n ],\n listForRef: [\"GET /repos/{owner}/{repo}/commits/{ref}/check-runs\"],\n listForSuite: [\n \"GET /repos/{owner}/{repo}/check-suites/{check_suite_id}/check-runs\",\n ],\n listSuitesForRef: [\"GET /repos/{owner}/{repo}/commits/{ref}/check-suites\"],\n rerequestRun: [\n \"POST /repos/{owner}/{repo}/check-runs/{check_run_id}/rerequest\",\n ],\n rerequestSuite: [\n \"POST /repos/{owner}/{repo}/check-suites/{check_suite_id}/rerequest\",\n ],\n setSuitesPreferences: [\n \"PATCH /repos/{owner}/{repo}/check-suites/preferences\",\n ],\n update: [\"PATCH /repos/{owner}/{repo}/check-runs/{check_run_id}\"],\n },\n codeScanning: {\n deleteAnalysis: [\n \"DELETE /repos/{owner}/{repo}/code-scanning/analyses/{analysis_id}{?confirm_delete}\",\n ],\n getAlert: [\n \"GET /repos/{owner}/{repo}/code-scanning/alerts/{alert_number}\",\n {},\n { renamedParameters: { alert_id: \"alert_number\" } },\n ],\n getAnalysis: [\n \"GET /repos/{owner}/{repo}/code-scanning/analyses/{analysis_id}\",\n ],\n getSarif: [\"GET /repos/{owner}/{repo}/code-scanning/sarifs/{sarif_id}\"],\n listAlertInstances: [\n \"GET /repos/{owner}/{repo}/code-scanning/alerts/{alert_number}/instances\",\n ],\n listAlertsForOrg: [\"GET /orgs/{org}/code-scanning/alerts\"],\n listAlertsForRepo: [\"GET /repos/{owner}/{repo}/code-scanning/alerts\"],\n listAlertsInstances: [\n \"GET /repos/{owner}/{repo}/code-scanning/alerts/{alert_number}/instances\",\n {},\n { renamed: [\"codeScanning\", \"listAlertInstances\"] },\n ],\n listRecentAnalyses: [\"GET /repos/{owner}/{repo}/code-scanning/analyses\"],\n updateAlert: [\n \"PATCH /repos/{owner}/{repo}/code-scanning/alerts/{alert_number}\",\n ],\n uploadSarif: [\"POST /repos/{owner}/{repo}/code-scanning/sarifs\"],\n },\n codesOfConduct: {\n getAllCodesOfConduct: [\"GET /codes_of_conduct\"],\n getConductCode: [\"GET /codes_of_conduct/{key}\"],\n },\n codespaces: {\n addRepositoryForSecretForAuthenticatedUser: [\n \"PUT /user/codespaces/secrets/{secret_name}/repositories/{repository_id}\",\n ],\n codespaceMachinesForAuthenticatedUser: [\n \"GET /user/codespaces/{codespace_name}/machines\",\n ],\n createForAuthenticatedUser: [\"POST /user/codespaces\"],\n createOrUpdateRepoSecret: [\n \"PUT /repos/{owner}/{repo}/codespaces/secrets/{secret_name}\",\n ],\n createOrUpdateSecretForAuthenticatedUser: [\n \"PUT /user/codespaces/secrets/{secret_name}\",\n ],\n createWithPrForAuthenticatedUser: [\n \"POST /repos/{owner}/{repo}/pulls/{pull_number}/codespaces\",\n ],\n createWithRepoForAuthenticatedUser: [\n \"POST /repos/{owner}/{repo}/codespaces\",\n ],\n deleteForAuthenticatedUser: [\"DELETE /user/codespaces/{codespace_name}\"],\n deleteFromOrganization: [\n \"DELETE /orgs/{org}/members/{username}/codespaces/{codespace_name}\",\n ],\n deleteRepoSecret: [\n \"DELETE /repos/{owner}/{repo}/codespaces/secrets/{secret_name}\",\n ],\n deleteSecretForAuthenticatedUser: [\n \"DELETE /user/codespaces/secrets/{secret_name}\",\n ],\n exportForAuthenticatedUser: [\n \"POST /user/codespaces/{codespace_name}/exports\",\n ],\n getExportDetailsForAuthenticatedUser: [\n \"GET /user/codespaces/{codespace_name}/exports/{export_id}\",\n ],\n getForAuthenticatedUser: [\"GET /user/codespaces/{codespace_name}\"],\n getPublicKeyForAuthenticatedUser: [\n \"GET /user/codespaces/secrets/public-key\",\n ],\n getRepoPublicKey: [\n \"GET /repos/{owner}/{repo}/codespaces/secrets/public-key\",\n ],\n getRepoSecret: [\n \"GET /repos/{owner}/{repo}/codespaces/secrets/{secret_name}\",\n ],\n getSecretForAuthenticatedUser: [\n \"GET /user/codespaces/secrets/{secret_name}\",\n ],\n listDevcontainersInRepositoryForAuthenticatedUser: [\n \"GET /repos/{owner}/{repo}/codespaces/devcontainers\",\n ],\n listForAuthenticatedUser: [\"GET /user/codespaces\"],\n listInOrganization: [\n \"GET /orgs/{org}/codespaces\",\n {},\n { renamedParameters: { org_id: \"org\" } },\n ],\n listInRepositoryForAuthenticatedUser: [\n \"GET /repos/{owner}/{repo}/codespaces\",\n ],\n listRepoSecrets: [\"GET /repos/{owner}/{repo}/codespaces/secrets\"],\n listRepositoriesForSecretForAuthenticatedUser: [\n \"GET /user/codespaces/secrets/{secret_name}/repositories\",\n ],\n listSecretsForAuthenticatedUser: [\"GET /user/codespaces/secrets\"],\n removeRepositoryForSecretForAuthenticatedUser: [\n \"DELETE /user/codespaces/secrets/{secret_name}/repositories/{repository_id}\",\n ],\n repoMachinesForAuthenticatedUser: [\n \"GET /repos/{owner}/{repo}/codespaces/machines\",\n ],\n setRepositoriesForSecretForAuthenticatedUser: [\n \"PUT /user/codespaces/secrets/{secret_name}/repositories\",\n ],\n startForAuthenticatedUser: [\"POST /user/codespaces/{codespace_name}/start\"],\n stopForAuthenticatedUser: [\"POST /user/codespaces/{codespace_name}/stop\"],\n stopInOrganization: [\n \"POST /orgs/{org}/members/{username}/codespaces/{codespace_name}/stop\",\n ],\n updateForAuthenticatedUser: [\"PATCH /user/codespaces/{codespace_name}\"],\n },\n dependabot: {\n addSelectedRepoToOrgSecret: [\n \"PUT /orgs/{org}/dependabot/secrets/{secret_name}/repositories/{repository_id}\",\n ],\n createOrUpdateOrgSecret: [\n \"PUT /orgs/{org}/dependabot/secrets/{secret_name}\",\n ],\n createOrUpdateRepoSecret: [\n \"PUT /repos/{owner}/{repo}/dependabot/secrets/{secret_name}\",\n ],\n deleteOrgSecret: [\"DELETE /orgs/{org}/dependabot/secrets/{secret_name}\"],\n deleteRepoSecret: [\n \"DELETE /repos/{owner}/{repo}/dependabot/secrets/{secret_name}\",\n ],\n getOrgPublicKey: [\"GET /orgs/{org}/dependabot/secrets/public-key\"],\n getOrgSecret: [\"GET /orgs/{org}/dependabot/secrets/{secret_name}\"],\n getRepoPublicKey: [\n \"GET /repos/{owner}/{repo}/dependabot/secrets/public-key\",\n ],\n getRepoSecret: [\n \"GET /repos/{owner}/{repo}/dependabot/secrets/{secret_name}\",\n ],\n listOrgSecrets: [\"GET /orgs/{org}/dependabot/secrets\"],\n listRepoSecrets: [\"GET /repos/{owner}/{repo}/dependabot/secrets\"],\n listSelectedReposForOrgSecret: [\n \"GET /orgs/{org}/dependabot/secrets/{secret_name}/repositories\",\n ],\n removeSelectedRepoFromOrgSecret: [\n \"DELETE /orgs/{org}/dependabot/secrets/{secret_name}/repositories/{repository_id}\",\n ],\n setSelectedReposForOrgSecret: [\n \"PUT /orgs/{org}/dependabot/secrets/{secret_name}/repositories\",\n ],\n },\n dependencyGraph: {\n createRepositorySnapshot: [\n \"POST /repos/{owner}/{repo}/dependency-graph/snapshots\",\n ],\n diffRange: [\n \"GET /repos/{owner}/{repo}/dependency-graph/compare/{basehead}\",\n ],\n },\n emojis: { get: [\"GET /emojis\"] },\n enterpriseAdmin: {\n addCustomLabelsToSelfHostedRunnerForEnterprise: [\n \"POST /enterprises/{enterprise}/actions/runners/{runner_id}/labels\",\n ],\n disableSelectedOrganizationGithubActionsEnterprise: [\n \"DELETE /enterprises/{enterprise}/actions/permissions/organizations/{org_id}\",\n ],\n enableSelectedOrganizationGithubActionsEnterprise: [\n \"PUT /enterprises/{enterprise}/actions/permissions/organizations/{org_id}\",\n ],\n getAllowedActionsEnterprise: [\n \"GET /enterprises/{enterprise}/actions/permissions/selected-actions\",\n ],\n getGithubActionsPermissionsEnterprise: [\n \"GET /enterprises/{enterprise}/actions/permissions\",\n ],\n getServerStatistics: [\n \"GET /enterprise-installation/{enterprise_or_org}/server-statistics\",\n ],\n listLabelsForSelfHostedRunnerForEnterprise: [\n \"GET /enterprises/{enterprise}/actions/runners/{runner_id}/labels\",\n ],\n listSelectedOrganizationsEnabledGithubActionsEnterprise: [\n \"GET /enterprises/{enterprise}/actions/permissions/organizations\",\n ],\n removeAllCustomLabelsFromSelfHostedRunnerForEnterprise: [\n \"DELETE /enterprises/{enterprise}/actions/runners/{runner_id}/labels\",\n ],\n removeCustomLabelFromSelfHostedRunnerForEnterprise: [\n \"DELETE /enterprises/{enterprise}/actions/runners/{runner_id}/labels/{name}\",\n ],\n setAllowedActionsEnterprise: [\n \"PUT /enterprises/{enterprise}/actions/permissions/selected-actions\",\n ],\n setCustomLabelsForSelfHostedRunnerForEnterprise: [\n \"PUT /enterprises/{enterprise}/actions/runners/{runner_id}/labels\",\n ],\n setGithubActionsPermissionsEnterprise: [\n \"PUT /enterprises/{enterprise}/actions/permissions\",\n ],\n setSelectedOrganizationsEnabledGithubActionsEnterprise: [\n \"PUT /enterprises/{enterprise}/actions/permissions/organizations\",\n ],\n },\n gists: {\n checkIsStarred: [\"GET /gists/{gist_id}/star\"],\n create: [\"POST /gists\"],\n createComment: [\"POST /gists/{gist_id}/comments\"],\n delete: [\"DELETE /gists/{gist_id}\"],\n deleteComment: [\"DELETE /gists/{gist_id}/comments/{comment_id}\"],\n fork: [\"POST /gists/{gist_id}/forks\"],\n get: [\"GET /gists/{gist_id}\"],\n getComment: [\"GET /gists/{gist_id}/comments/{comment_id}\"],\n getRevision: [\"GET /gists/{gist_id}/{sha}\"],\n list: [\"GET /gists\"],\n listComments: [\"GET /gists/{gist_id}/comments\"],\n listCommits: [\"GET /gists/{gist_id}/commits\"],\n listForUser: [\"GET /users/{username}/gists\"],\n listForks: [\"GET /gists/{gist_id}/forks\"],\n listPublic: [\"GET /gists/public\"],\n listStarred: [\"GET /gists/starred\"],\n star: [\"PUT /gists/{gist_id}/star\"],\n unstar: [\"DELETE /gists/{gist_id}/star\"],\n update: [\"PATCH /gists/{gist_id}\"],\n updateComment: [\"PATCH /gists/{gist_id}/comments/{comment_id}\"],\n },\n git: {\n createBlob: [\"POST /repos/{owner}/{repo}/git/blobs\"],\n createCommit: [\"POST /repos/{owner}/{repo}/git/commits\"],\n createRef: [\"POST /repos/{owner}/{repo}/git/refs\"],\n createTag: [\"POST /repos/{owner}/{repo}/git/tags\"],\n createTree: [\"POST /repos/{owner}/{repo}/git/trees\"],\n deleteRef: [\"DELETE /repos/{owner}/{repo}/git/refs/{ref}\"],\n getBlob: [\"GET /repos/{owner}/{repo}/git/blobs/{file_sha}\"],\n getCommit: [\"GET /repos/{owner}/{repo}/git/commits/{commit_sha}\"],\n getRef: [\"GET /repos/{owner}/{repo}/git/ref/{ref}\"],\n getTag: [\"GET /repos/{owner}/{repo}/git/tags/{tag_sha}\"],\n getTree: [\"GET /repos/{owner}/{repo}/git/trees/{tree_sha}\"],\n listMatchingRefs: [\"GET /repos/{owner}/{repo}/git/matching-refs/{ref}\"],\n updateRef: [\"PATCH /repos/{owner}/{repo}/git/refs/{ref}\"],\n },\n gitignore: {\n getAllTemplates: [\"GET /gitignore/templates\"],\n getTemplate: [\"GET /gitignore/templates/{name}\"],\n },\n interactions: {\n getRestrictionsForAuthenticatedUser: [\"GET /user/interaction-limits\"],\n getRestrictionsForOrg: [\"GET /orgs/{org}/interaction-limits\"],\n getRestrictionsForRepo: [\"GET /repos/{owner}/{repo}/interaction-limits\"],\n getRestrictionsForYourPublicRepos: [\n \"GET /user/interaction-limits\",\n {},\n { renamed: [\"interactions\", \"getRestrictionsForAuthenticatedUser\"] },\n ],\n removeRestrictionsForAuthenticatedUser: [\"DELETE /user/interaction-limits\"],\n removeRestrictionsForOrg: [\"DELETE /orgs/{org}/interaction-limits\"],\n removeRestrictionsForRepo: [\n \"DELETE /repos/{owner}/{repo}/interaction-limits\",\n ],\n removeRestrictionsForYourPublicRepos: [\n \"DELETE /user/interaction-limits\",\n {},\n { renamed: [\"interactions\", \"removeRestrictionsForAuthenticatedUser\"] },\n ],\n setRestrictionsForAuthenticatedUser: [\"PUT /user/interaction-limits\"],\n setRestrictionsForOrg: [\"PUT /orgs/{org}/interaction-limits\"],\n setRestrictionsForRepo: [\"PUT /repos/{owner}/{repo}/interaction-limits\"],\n setRestrictionsForYourPublicRepos: [\n \"PUT /user/interaction-limits\",\n {},\n { renamed: [\"interactions\", \"setRestrictionsForAuthenticatedUser\"] },\n ],\n },\n issues: {\n addAssignees: [\n \"POST /repos/{owner}/{repo}/issues/{issue_number}/assignees\",\n ],\n addLabels: [\"POST /repos/{owner}/{repo}/issues/{issue_number}/labels\"],\n checkUserCanBeAssigned: [\"GET /repos/{owner}/{repo}/assignees/{assignee}\"],\n create: [\"POST /repos/{owner}/{repo}/issues\"],\n createComment: [\n \"POST /repos/{owner}/{repo}/issues/{issue_number}/comments\",\n ],\n createLabel: [\"POST /repos/{owner}/{repo}/labels\"],\n createMilestone: [\"POST /repos/{owner}/{repo}/milestones\"],\n deleteComment: [\n \"DELETE /repos/{owner}/{repo}/issues/comments/{comment_id}\",\n ],\n deleteLabel: [\"DELETE /repos/{owner}/{repo}/labels/{name}\"],\n deleteMilestone: [\n \"DELETE /repos/{owner}/{repo}/milestones/{milestone_number}\",\n ],\n get: [\"GET /repos/{owner}/{repo}/issues/{issue_number}\"],\n getComment: [\"GET /repos/{owner}/{repo}/issues/comments/{comment_id}\"],\n getEvent: [\"GET /repos/{owner}/{repo}/issues/events/{event_id}\"],\n getLabel: [\"GET /repos/{owner}/{repo}/labels/{name}\"],\n getMilestone: [\"GET /repos/{owner}/{repo}/milestones/{milestone_number}\"],\n list: [\"GET /issues\"],\n listAssignees: [\"GET /repos/{owner}/{repo}/assignees\"],\n listComments: [\"GET /repos/{owner}/{repo}/issues/{issue_number}/comments\"],\n listCommentsForRepo: [\"GET /repos/{owner}/{repo}/issues/comments\"],\n listEvents: [\"GET /repos/{owner}/{repo}/issues/{issue_number}/events\"],\n listEventsForRepo: [\"GET /repos/{owner}/{repo}/issues/events\"],\n listEventsForTimeline: [\n \"GET /repos/{owner}/{repo}/issues/{issue_number}/timeline\",\n ],\n listForAuthenticatedUser: [\"GET /user/issues\"],\n listForOrg: [\"GET /orgs/{org}/issues\"],\n listForRepo: [\"GET /repos/{owner}/{repo}/issues\"],\n listLabelsForMilestone: [\n \"GET /repos/{owner}/{repo}/milestones/{milestone_number}/labels\",\n ],\n listLabelsForRepo: [\"GET /repos/{owner}/{repo}/labels\"],\n listLabelsOnIssue: [\n \"GET /repos/{owner}/{repo}/issues/{issue_number}/labels\",\n ],\n listMilestones: [\"GET /repos/{owner}/{repo}/milestones\"],\n lock: [\"PUT /repos/{owner}/{repo}/issues/{issue_number}/lock\"],\n removeAllLabels: [\n \"DELETE /repos/{owner}/{repo}/issues/{issue_number}/labels\",\n ],\n removeAssignees: [\n \"DELETE /repos/{owner}/{repo}/issues/{issue_number}/assignees\",\n ],\n removeLabel: [\n \"DELETE /repos/{owner}/{repo}/issues/{issue_number}/labels/{name}\",\n ],\n setLabels: [\"PUT /repos/{owner}/{repo}/issues/{issue_number}/labels\"],\n unlock: [\"DELETE /repos/{owner}/{repo}/issues/{issue_number}/lock\"],\n update: [\"PATCH /repos/{owner}/{repo}/issues/{issue_number}\"],\n updateComment: [\"PATCH /repos/{owner}/{repo}/issues/comments/{comment_id}\"],\n updateLabel: [\"PATCH /repos/{owner}/{repo}/labels/{name}\"],\n updateMilestone: [\n \"PATCH /repos/{owner}/{repo}/milestones/{milestone_number}\",\n ],\n },\n licenses: {\n get: [\"GET /licenses/{license}\"],\n getAllCommonlyUsed: [\"GET /licenses\"],\n getForRepo: [\"GET /repos/{owner}/{repo}/license\"],\n },\n markdown: {\n render: [\"POST /markdown\"],\n renderRaw: [\n \"POST /markdown/raw\",\n { headers: { \"content-type\": \"text/plain; charset=utf-8\" } },\n ],\n },\n meta: {\n get: [\"GET /meta\"],\n getOctocat: [\"GET /octocat\"],\n getZen: [\"GET /zen\"],\n root: [\"GET /\"],\n },\n migrations: {\n cancelImport: [\"DELETE /repos/{owner}/{repo}/import\"],\n deleteArchiveForAuthenticatedUser: [\n \"DELETE /user/migrations/{migration_id}/archive\",\n ],\n deleteArchiveForOrg: [\n \"DELETE /orgs/{org}/migrations/{migration_id}/archive\",\n ],\n downloadArchiveForOrg: [\n \"GET /orgs/{org}/migrations/{migration_id}/archive\",\n ],\n getArchiveForAuthenticatedUser: [\n \"GET /user/migrations/{migration_id}/archive\",\n ],\n getCommitAuthors: [\"GET /repos/{owner}/{repo}/import/authors\"],\n getImportStatus: [\"GET /repos/{owner}/{repo}/import\"],\n getLargeFiles: [\"GET /repos/{owner}/{repo}/import/large_files\"],\n getStatusForAuthenticatedUser: [\"GET /user/migrations/{migration_id}\"],\n getStatusForOrg: [\"GET /orgs/{org}/migrations/{migration_id}\"],\n listForAuthenticatedUser: [\"GET /user/migrations\"],\n listForOrg: [\"GET /orgs/{org}/migrations\"],\n listReposForAuthenticatedUser: [\n \"GET /user/migrations/{migration_id}/repositories\",\n ],\n listReposForOrg: [\"GET /orgs/{org}/migrations/{migration_id}/repositories\"],\n listReposForUser: [\n \"GET /user/migrations/{migration_id}/repositories\",\n {},\n { renamed: [\"migrations\", \"listReposForAuthenticatedUser\"] },\n ],\n mapCommitAuthor: [\"PATCH /repos/{owner}/{repo}/import/authors/{author_id}\"],\n setLfsPreference: [\"PATCH /repos/{owner}/{repo}/import/lfs\"],\n startForAuthenticatedUser: [\"POST /user/migrations\"],\n startForOrg: [\"POST /orgs/{org}/migrations\"],\n startImport: [\"PUT /repos/{owner}/{repo}/import\"],\n unlockRepoForAuthenticatedUser: [\n \"DELETE /user/migrations/{migration_id}/repos/{repo_name}/lock\",\n ],\n unlockRepoForOrg: [\n \"DELETE /orgs/{org}/migrations/{migration_id}/repos/{repo_name}/lock\",\n ],\n updateImport: [\"PATCH /repos/{owner}/{repo}/import\"],\n },\n orgs: {\n blockUser: [\"PUT /orgs/{org}/blocks/{username}\"],\n cancelInvitation: [\"DELETE /orgs/{org}/invitations/{invitation_id}\"],\n checkBlockedUser: [\"GET /orgs/{org}/blocks/{username}\"],\n checkMembershipForUser: [\"GET /orgs/{org}/members/{username}\"],\n checkPublicMembershipForUser: [\"GET /orgs/{org}/public_members/{username}\"],\n convertMemberToOutsideCollaborator: [\n \"PUT /orgs/{org}/outside_collaborators/{username}\",\n ],\n createInvitation: [\"POST /orgs/{org}/invitations\"],\n createWebhook: [\"POST /orgs/{org}/hooks\"],\n deleteWebhook: [\"DELETE /orgs/{org}/hooks/{hook_id}\"],\n get: [\"GET /orgs/{org}\"],\n getMembershipForAuthenticatedUser: [\"GET /user/memberships/orgs/{org}\"],\n getMembershipForUser: [\"GET /orgs/{org}/memberships/{username}\"],\n getWebhook: [\"GET /orgs/{org}/hooks/{hook_id}\"],\n getWebhookConfigForOrg: [\"GET /orgs/{org}/hooks/{hook_id}/config\"],\n getWebhookDelivery: [\n \"GET /orgs/{org}/hooks/{hook_id}/deliveries/{delivery_id}\",\n ],\n list: [\"GET /organizations\"],\n listAppInstallations: [\"GET /orgs/{org}/installations\"],\n listBlockedUsers: [\"GET /orgs/{org}/blocks\"],\n listCustomRoles: [\"GET /organizations/{organization_id}/custom_roles\"],\n listFailedInvitations: [\"GET /orgs/{org}/failed_invitations\"],\n listForAuthenticatedUser: [\"GET /user/orgs\"],\n listForUser: [\"GET /users/{username}/orgs\"],\n listInvitationTeams: [\"GET /orgs/{org}/invitations/{invitation_id}/teams\"],\n listMembers: [\"GET /orgs/{org}/members\"],\n listMembershipsForAuthenticatedUser: [\"GET /user/memberships/orgs\"],\n listOutsideCollaborators: [\"GET /orgs/{org}/outside_collaborators\"],\n listPendingInvitations: [\"GET /orgs/{org}/invitations\"],\n listPublicMembers: [\"GET /orgs/{org}/public_members\"],\n listWebhookDeliveries: [\"GET /orgs/{org}/hooks/{hook_id}/deliveries\"],\n listWebhooks: [\"GET /orgs/{org}/hooks\"],\n pingWebhook: [\"POST /orgs/{org}/hooks/{hook_id}/pings\"],\n redeliverWebhookDelivery: [\n \"POST /orgs/{org}/hooks/{hook_id}/deliveries/{delivery_id}/attempts\",\n ],\n removeMember: [\"DELETE /orgs/{org}/members/{username}\"],\n removeMembershipForUser: [\"DELETE /orgs/{org}/memberships/{username}\"],\n removeOutsideCollaborator: [\n \"DELETE /orgs/{org}/outside_collaborators/{username}\",\n ],\n removePublicMembershipForAuthenticatedUser: [\n \"DELETE /orgs/{org}/public_members/{username}\",\n ],\n setMembershipForUser: [\"PUT /orgs/{org}/memberships/{username}\"],\n setPublicMembershipForAuthenticatedUser: [\n \"PUT /orgs/{org}/public_members/{username}\",\n ],\n unblockUser: [\"DELETE /orgs/{org}/blocks/{username}\"],\n update: [\"PATCH /orgs/{org}\"],\n updateMembershipForAuthenticatedUser: [\n \"PATCH /user/memberships/orgs/{org}\",\n ],\n updateWebhook: [\"PATCH /orgs/{org}/hooks/{hook_id}\"],\n updateWebhookConfigForOrg: [\"PATCH /orgs/{org}/hooks/{hook_id}/config\"],\n },\n packages: {\n deletePackageForAuthenticatedUser: [\n \"DELETE /user/packages/{package_type}/{package_name}\",\n ],\n deletePackageForOrg: [\n \"DELETE /orgs/{org}/packages/{package_type}/{package_name}\",\n ],\n deletePackageForUser: [\n \"DELETE /users/{username}/packages/{package_type}/{package_name}\",\n ],\n deletePackageVersionForAuthenticatedUser: [\n \"DELETE /user/packages/{package_type}/{package_name}/versions/{package_version_id}\",\n ],\n deletePackageVersionForOrg: [\n \"DELETE /orgs/{org}/packages/{package_type}/{package_name}/versions/{package_version_id}\",\n ],\n deletePackageVersionForUser: [\n \"DELETE /users/{username}/packages/{package_type}/{package_name}/versions/{package_version_id}\",\n ],\n getAllPackageVersionsForAPackageOwnedByAnOrg: [\n \"GET /orgs/{org}/packages/{package_type}/{package_name}/versions\",\n {},\n { renamed: [\"packages\", \"getAllPackageVersionsForPackageOwnedByOrg\"] },\n ],\n getAllPackageVersionsForAPackageOwnedByTheAuthenticatedUser: [\n \"GET /user/packages/{package_type}/{package_name}/versions\",\n {},\n {\n renamed: [\n \"packages\",\n \"getAllPackageVersionsForPackageOwnedByAuthenticatedUser\",\n ],\n },\n ],\n getAllPackageVersionsForPackageOwnedByAuthenticatedUser: [\n \"GET /user/packages/{package_type}/{package_name}/versions\",\n ],\n getAllPackageVersionsForPackageOwnedByOrg: [\n \"GET /orgs/{org}/packages/{package_type}/{package_name}/versions\",\n ],\n getAllPackageVersionsForPackageOwnedByUser: [\n \"GET /users/{username}/packages/{package_type}/{package_name}/versions\",\n ],\n getPackageForAuthenticatedUser: [\n \"GET /user/packages/{package_type}/{package_name}\",\n ],\n getPackageForOrganization: [\n \"GET /orgs/{org}/packages/{package_type}/{package_name}\",\n ],\n getPackageForUser: [\n \"GET /users/{username}/packages/{package_type}/{package_name}\",\n ],\n getPackageVersionForAuthenticatedUser: [\n \"GET /user/packages/{package_type}/{package_name}/versions/{package_version_id}\",\n ],\n getPackageVersionForOrganization: [\n \"GET /orgs/{org}/packages/{package_type}/{package_name}/versions/{package_version_id}\",\n ],\n getPackageVersionForUser: [\n \"GET /users/{username}/packages/{package_type}/{package_name}/versions/{package_version_id}\",\n ],\n listPackagesForAuthenticatedUser: [\"GET /user/packages\"],\n listPackagesForOrganization: [\"GET /orgs/{org}/packages\"],\n listPackagesForUser: [\"GET /users/{username}/packages\"],\n restorePackageForAuthenticatedUser: [\n \"POST /user/packages/{package_type}/{package_name}/restore{?token}\",\n ],\n restorePackageForOrg: [\n \"POST /orgs/{org}/packages/{package_type}/{package_name}/restore{?token}\",\n ],\n restorePackageForUser: [\n \"POST /users/{username}/packages/{package_type}/{package_name}/restore{?token}\",\n ],\n restorePackageVersionForAuthenticatedUser: [\n \"POST /user/packages/{package_type}/{package_name}/versions/{package_version_id}/restore\",\n ],\n restorePackageVersionForOrg: [\n \"POST /orgs/{org}/packages/{package_type}/{package_name}/versions/{package_version_id}/restore\",\n ],\n restorePackageVersionForUser: [\n \"POST /users/{username}/packages/{package_type}/{package_name}/versions/{package_version_id}/restore\",\n ],\n },\n projects: {\n addCollaborator: [\"PUT /projects/{project_id}/collaborators/{username}\"],\n createCard: [\"POST /projects/columns/{column_id}/cards\"],\n createColumn: [\"POST /projects/{project_id}/columns\"],\n createForAuthenticatedUser: [\"POST /user/projects\"],\n createForOrg: [\"POST /orgs/{org}/projects\"],\n createForRepo: [\"POST /repos/{owner}/{repo}/projects\"],\n delete: [\"DELETE /projects/{project_id}\"],\n deleteCard: [\"DELETE /projects/columns/cards/{card_id}\"],\n deleteColumn: [\"DELETE /projects/columns/{column_id}\"],\n get: [\"GET /projects/{project_id}\"],\n getCard: [\"GET /projects/columns/cards/{card_id}\"],\n getColumn: [\"GET /projects/columns/{column_id}\"],\n getPermissionForUser: [\n \"GET /projects/{project_id}/collaborators/{username}/permission\",\n ],\n listCards: [\"GET /projects/columns/{column_id}/cards\"],\n listCollaborators: [\"GET /projects/{project_id}/collaborators\"],\n listColumns: [\"GET /projects/{project_id}/columns\"],\n listForOrg: [\"GET /orgs/{org}/projects\"],\n listForRepo: [\"GET /repos/{owner}/{repo}/projects\"],\n listForUser: [\"GET /users/{username}/projects\"],\n moveCard: [\"POST /projects/columns/cards/{card_id}/moves\"],\n moveColumn: [\"POST /projects/columns/{column_id}/moves\"],\n removeCollaborator: [\n \"DELETE /projects/{project_id}/collaborators/{username}\",\n ],\n update: [\"PATCH /projects/{project_id}\"],\n updateCard: [\"PATCH /projects/columns/cards/{card_id}\"],\n updateColumn: [\"PATCH /projects/columns/{column_id}\"],\n },\n pulls: {\n checkIfMerged: [\"GET /repos/{owner}/{repo}/pulls/{pull_number}/merge\"],\n create: [\"POST /repos/{owner}/{repo}/pulls\"],\n createReplyForReviewComment: [\n \"POST /repos/{owner}/{repo}/pulls/{pull_number}/comments/{comment_id}/replies\",\n ],\n createReview: [\"POST /repos/{owner}/{repo}/pulls/{pull_number}/reviews\"],\n createReviewComment: [\n \"POST /repos/{owner}/{repo}/pulls/{pull_number}/comments\",\n ],\n deletePendingReview: [\n \"DELETE /repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}\",\n ],\n deleteReviewComment: [\n \"DELETE /repos/{owner}/{repo}/pulls/comments/{comment_id}\",\n ],\n dismissReview: [\n \"PUT /repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}/dismissals\",\n ],\n get: [\"GET /repos/{owner}/{repo}/pulls/{pull_number}\"],\n getReview: [\n \"GET /repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}\",\n ],\n getReviewComment: [\"GET /repos/{owner}/{repo}/pulls/comments/{comment_id}\"],\n list: [\"GET /repos/{owner}/{repo}/pulls\"],\n listCommentsForReview: [\n \"GET /repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}/comments\",\n ],\n listCommits: [\"GET /repos/{owner}/{repo}/pulls/{pull_number}/commits\"],\n listFiles: [\"GET /repos/{owner}/{repo}/pulls/{pull_number}/files\"],\n listRequestedReviewers: [\n \"GET /repos/{owner}/{repo}/pulls/{pull_number}/requested_reviewers\",\n ],\n listReviewComments: [\n \"GET /repos/{owner}/{repo}/pulls/{pull_number}/comments\",\n ],\n listReviewCommentsForRepo: [\"GET /repos/{owner}/{repo}/pulls/comments\"],\n listReviews: [\"GET /repos/{owner}/{repo}/pulls/{pull_number}/reviews\"],\n merge: [\"PUT /repos/{owner}/{repo}/pulls/{pull_number}/merge\"],\n removeRequestedReviewers: [\n \"DELETE /repos/{owner}/{repo}/pulls/{pull_number}/requested_reviewers\",\n ],\n requestReviewers: [\n \"POST /repos/{owner}/{repo}/pulls/{pull_number}/requested_reviewers\",\n ],\n submitReview: [\n \"POST /repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}/events\",\n ],\n update: [\"PATCH /repos/{owner}/{repo}/pulls/{pull_number}\"],\n updateBranch: [\n \"PUT /repos/{owner}/{repo}/pulls/{pull_number}/update-branch\",\n ],\n updateReview: [\n \"PUT /repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}\",\n ],\n updateReviewComment: [\n \"PATCH /repos/{owner}/{repo}/pulls/comments/{comment_id}\",\n ],\n },\n rateLimit: { get: [\"GET /rate_limit\"] },\n reactions: {\n createForCommitComment: [\n \"POST /repos/{owner}/{repo}/comments/{comment_id}/reactions\",\n ],\n createForIssue: [\n \"POST /repos/{owner}/{repo}/issues/{issue_number}/reactions\",\n ],\n createForIssueComment: [\n \"POST /repos/{owner}/{repo}/issues/comments/{comment_id}/reactions\",\n ],\n createForPullRequestReviewComment: [\n \"POST /repos/{owner}/{repo}/pulls/comments/{comment_id}/reactions\",\n ],\n createForRelease: [\n \"POST /repos/{owner}/{repo}/releases/{release_id}/reactions\",\n ],\n createForTeamDiscussionCommentInOrg: [\n \"POST /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}/reactions\",\n ],\n createForTeamDiscussionInOrg: [\n \"POST /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/reactions\",\n ],\n deleteForCommitComment: [\n \"DELETE /repos/{owner}/{repo}/comments/{comment_id}/reactions/{reaction_id}\",\n ],\n deleteForIssue: [\n \"DELETE /repos/{owner}/{repo}/issues/{issue_number}/reactions/{reaction_id}\",\n ],\n deleteForIssueComment: [\n \"DELETE /repos/{owner}/{repo}/issues/comments/{comment_id}/reactions/{reaction_id}\",\n ],\n deleteForPullRequestComment: [\n \"DELETE /repos/{owner}/{repo}/pulls/comments/{comment_id}/reactions/{reaction_id}\",\n ],\n deleteForRelease: [\n \"DELETE /repos/{owner}/{repo}/releases/{release_id}/reactions/{reaction_id}\",\n ],\n deleteForTeamDiscussion: [\n \"DELETE /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/reactions/{reaction_id}\",\n ],\n deleteForTeamDiscussionComment: [\n \"DELETE /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}/reactions/{reaction_id}\",\n ],\n listForCommitComment: [\n \"GET /repos/{owner}/{repo}/comments/{comment_id}/reactions\",\n ],\n listForIssue: [\"GET /repos/{owner}/{repo}/issues/{issue_number}/reactions\"],\n listForIssueComment: [\n \"GET /repos/{owner}/{repo}/issues/comments/{comment_id}/reactions\",\n ],\n listForPullRequestReviewComment: [\n \"GET /repos/{owner}/{repo}/pulls/comments/{comment_id}/reactions\",\n ],\n listForRelease: [\n \"GET /repos/{owner}/{repo}/releases/{release_id}/reactions\",\n ],\n listForTeamDiscussionCommentInOrg: [\n \"GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}/reactions\",\n ],\n listForTeamDiscussionInOrg: [\n \"GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/reactions\",\n ],\n },\n repos: {\n acceptInvitation: [\n \"PATCH /user/repository_invitations/{invitation_id}\",\n {},\n { renamed: [\"repos\", \"acceptInvitationForAuthenticatedUser\"] },\n ],\n acceptInvitationForAuthenticatedUser: [\n \"PATCH /user/repository_invitations/{invitation_id}\",\n ],\n addAppAccessRestrictions: [\n \"POST /repos/{owner}/{repo}/branches/{branch}/protection/restrictions/apps\",\n {},\n { mapToData: \"apps\" },\n ],\n addCollaborator: [\"PUT /repos/{owner}/{repo}/collaborators/{username}\"],\n addStatusCheckContexts: [\n \"POST /repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks/contexts\",\n {},\n { mapToData: \"contexts\" },\n ],\n addTeamAccessRestrictions: [\n \"POST /repos/{owner}/{repo}/branches/{branch}/protection/restrictions/teams\",\n {},\n { mapToData: \"teams\" },\n ],\n addUserAccessRestrictions: [\n \"POST /repos/{owner}/{repo}/branches/{branch}/protection/restrictions/users\",\n {},\n { mapToData: \"users\" },\n ],\n checkCollaborator: [\"GET /repos/{owner}/{repo}/collaborators/{username}\"],\n checkVulnerabilityAlerts: [\n \"GET /repos/{owner}/{repo}/vulnerability-alerts\",\n ],\n codeownersErrors: [\"GET /repos/{owner}/{repo}/codeowners/errors\"],\n compareCommits: [\"GET /repos/{owner}/{repo}/compare/{base}...{head}\"],\n compareCommitsWithBasehead: [\n \"GET /repos/{owner}/{repo}/compare/{basehead}\",\n ],\n createAutolink: [\"POST /repos/{owner}/{repo}/autolinks\"],\n createCommitComment: [\n \"POST /repos/{owner}/{repo}/commits/{commit_sha}/comments\",\n ],\n createCommitSignatureProtection: [\n \"POST /repos/{owner}/{repo}/branches/{branch}/protection/required_signatures\",\n ],\n createCommitStatus: [\"POST /repos/{owner}/{repo}/statuses/{sha}\"],\n createDeployKey: [\"POST /repos/{owner}/{repo}/keys\"],\n createDeployment: [\"POST /repos/{owner}/{repo}/deployments\"],\n createDeploymentStatus: [\n \"POST /repos/{owner}/{repo}/deployments/{deployment_id}/statuses\",\n ],\n createDispatchEvent: [\"POST /repos/{owner}/{repo}/dispatches\"],\n createForAuthenticatedUser: [\"POST /user/repos\"],\n createFork: [\"POST /repos/{owner}/{repo}/forks\"],\n createInOrg: [\"POST /orgs/{org}/repos\"],\n createOrUpdateEnvironment: [\n \"PUT /repos/{owner}/{repo}/environments/{environment_name}\",\n ],\n createOrUpdateFileContents: [\"PUT /repos/{owner}/{repo}/contents/{path}\"],\n createPagesSite: [\"POST /repos/{owner}/{repo}/pages\"],\n createRelease: [\"POST /repos/{owner}/{repo}/releases\"],\n createTagProtection: [\"POST /repos/{owner}/{repo}/tags/protection\"],\n createUsingTemplate: [\n \"POST /repos/{template_owner}/{template_repo}/generate\",\n ],\n createWebhook: [\"POST /repos/{owner}/{repo}/hooks\"],\n declineInvitation: [\n \"DELETE /user/repository_invitations/{invitation_id}\",\n {},\n { renamed: [\"repos\", \"declineInvitationForAuthenticatedUser\"] },\n ],\n declineInvitationForAuthenticatedUser: [\n \"DELETE /user/repository_invitations/{invitation_id}\",\n ],\n delete: [\"DELETE /repos/{owner}/{repo}\"],\n deleteAccessRestrictions: [\n \"DELETE /repos/{owner}/{repo}/branches/{branch}/protection/restrictions\",\n ],\n deleteAdminBranchProtection: [\n \"DELETE /repos/{owner}/{repo}/branches/{branch}/protection/enforce_admins\",\n ],\n deleteAnEnvironment: [\n \"DELETE /repos/{owner}/{repo}/environments/{environment_name}\",\n ],\n deleteAutolink: [\"DELETE /repos/{owner}/{repo}/autolinks/{autolink_id}\"],\n deleteBranchProtection: [\n \"DELETE /repos/{owner}/{repo}/branches/{branch}/protection\",\n ],\n deleteCommitComment: [\"DELETE /repos/{owner}/{repo}/comments/{comment_id}\"],\n deleteCommitSignatureProtection: [\n \"DELETE /repos/{owner}/{repo}/branches/{branch}/protection/required_signatures\",\n ],\n deleteDeployKey: [\"DELETE /repos/{owner}/{repo}/keys/{key_id}\"],\n deleteDeployment: [\n \"DELETE /repos/{owner}/{repo}/deployments/{deployment_id}\",\n ],\n deleteFile: [\"DELETE /repos/{owner}/{repo}/contents/{path}\"],\n deleteInvitation: [\n \"DELETE /repos/{owner}/{repo}/invitations/{invitation_id}\",\n ],\n deletePagesSite: [\"DELETE /repos/{owner}/{repo}/pages\"],\n deletePullRequestReviewProtection: [\n \"DELETE /repos/{owner}/{repo}/branches/{branch}/protection/required_pull_request_reviews\",\n ],\n deleteRelease: [\"DELETE /repos/{owner}/{repo}/releases/{release_id}\"],\n deleteReleaseAsset: [\n \"DELETE /repos/{owner}/{repo}/releases/assets/{asset_id}\",\n ],\n deleteTagProtection: [\n \"DELETE /repos/{owner}/{repo}/tags/protection/{tag_protection_id}\",\n ],\n deleteWebhook: [\"DELETE /repos/{owner}/{repo}/hooks/{hook_id}\"],\n disableAutomatedSecurityFixes: [\n \"DELETE /repos/{owner}/{repo}/automated-security-fixes\",\n ],\n disableLfsForRepo: [\"DELETE /repos/{owner}/{repo}/lfs\"],\n disableVulnerabilityAlerts: [\n \"DELETE /repos/{owner}/{repo}/vulnerability-alerts\",\n ],\n downloadArchive: [\n \"GET /repos/{owner}/{repo}/zipball/{ref}\",\n {},\n { renamed: [\"repos\", \"downloadZipballArchive\"] },\n ],\n downloadTarballArchive: [\"GET /repos/{owner}/{repo}/tarball/{ref}\"],\n downloadZipballArchive: [\"GET /repos/{owner}/{repo}/zipball/{ref}\"],\n enableAutomatedSecurityFixes: [\n \"PUT /repos/{owner}/{repo}/automated-security-fixes\",\n ],\n enableLfsForRepo: [\"PUT /repos/{owner}/{repo}/lfs\"],\n enableVulnerabilityAlerts: [\n \"PUT /repos/{owner}/{repo}/vulnerability-alerts\",\n ],\n generateReleaseNotes: [\n \"POST /repos/{owner}/{repo}/releases/generate-notes\",\n ],\n get: [\"GET /repos/{owner}/{repo}\"],\n getAccessRestrictions: [\n \"GET /repos/{owner}/{repo}/branches/{branch}/protection/restrictions\",\n ],\n getAdminBranchProtection: [\n \"GET /repos/{owner}/{repo}/branches/{branch}/protection/enforce_admins\",\n ],\n getAllEnvironments: [\"GET /repos/{owner}/{repo}/environments\"],\n getAllStatusCheckContexts: [\n \"GET /repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks/contexts\",\n ],\n getAllTopics: [\"GET /repos/{owner}/{repo}/topics\"],\n getAppsWithAccessToProtectedBranch: [\n \"GET /repos/{owner}/{repo}/branches/{branch}/protection/restrictions/apps\",\n ],\n getAutolink: [\"GET /repos/{owner}/{repo}/autolinks/{autolink_id}\"],\n getBranch: [\"GET /repos/{owner}/{repo}/branches/{branch}\"],\n getBranchProtection: [\n \"GET /repos/{owner}/{repo}/branches/{branch}/protection\",\n ],\n getClones: [\"GET /repos/{owner}/{repo}/traffic/clones\"],\n getCodeFrequencyStats: [\"GET /repos/{owner}/{repo}/stats/code_frequency\"],\n getCollaboratorPermissionLevel: [\n \"GET /repos/{owner}/{repo}/collaborators/{username}/permission\",\n ],\n getCombinedStatusForRef: [\"GET /repos/{owner}/{repo}/commits/{ref}/status\"],\n getCommit: [\"GET /repos/{owner}/{repo}/commits/{ref}\"],\n getCommitActivityStats: [\"GET /repos/{owner}/{repo}/stats/commit_activity\"],\n getCommitComment: [\"GET /repos/{owner}/{repo}/comments/{comment_id}\"],\n getCommitSignatureProtection: [\n \"GET /repos/{owner}/{repo}/branches/{branch}/protection/required_signatures\",\n ],\n getCommunityProfileMetrics: [\"GET /repos/{owner}/{repo}/community/profile\"],\n getContent: [\"GET /repos/{owner}/{repo}/contents/{path}\"],\n getContributorsStats: [\"GET /repos/{owner}/{repo}/stats/contributors\"],\n getDeployKey: [\"GET /repos/{owner}/{repo}/keys/{key_id}\"],\n getDeployment: [\"GET /repos/{owner}/{repo}/deployments/{deployment_id}\"],\n getDeploymentStatus: [\n \"GET /repos/{owner}/{repo}/deployments/{deployment_id}/statuses/{status_id}\",\n ],\n getEnvironment: [\n \"GET /repos/{owner}/{repo}/environments/{environment_name}\",\n ],\n getLatestPagesBuild: [\"GET /repos/{owner}/{repo}/pages/builds/latest\"],\n getLatestRelease: [\"GET /repos/{owner}/{repo}/releases/latest\"],\n getPages: [\"GET /repos/{owner}/{repo}/pages\"],\n getPagesBuild: [\"GET /repos/{owner}/{repo}/pages/builds/{build_id}\"],\n getPagesHealthCheck: [\"GET /repos/{owner}/{repo}/pages/health\"],\n getParticipationStats: [\"GET /repos/{owner}/{repo}/stats/participation\"],\n getPullRequestReviewProtection: [\n \"GET /repos/{owner}/{repo}/branches/{branch}/protection/required_pull_request_reviews\",\n ],\n getPunchCardStats: [\"GET /repos/{owner}/{repo}/stats/punch_card\"],\n getReadme: [\"GET /repos/{owner}/{repo}/readme\"],\n getReadmeInDirectory: [\"GET /repos/{owner}/{repo}/readme/{dir}\"],\n getRelease: [\"GET /repos/{owner}/{repo}/releases/{release_id}\"],\n getReleaseAsset: [\"GET /repos/{owner}/{repo}/releases/assets/{asset_id}\"],\n getReleaseByTag: [\"GET /repos/{owner}/{repo}/releases/tags/{tag}\"],\n getStatusChecksProtection: [\n \"GET /repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks\",\n ],\n getTeamsWithAccessToProtectedBranch: [\n \"GET /repos/{owner}/{repo}/branches/{branch}/protection/restrictions/teams\",\n ],\n getTopPaths: [\"GET /repos/{owner}/{repo}/traffic/popular/paths\"],\n getTopReferrers: [\"GET /repos/{owner}/{repo}/traffic/popular/referrers\"],\n getUsersWithAccessToProtectedBranch: [\n \"GET /repos/{owner}/{repo}/branches/{branch}/protection/restrictions/users\",\n ],\n getViews: [\"GET /repos/{owner}/{repo}/traffic/views\"],\n getWebhook: [\"GET /repos/{owner}/{repo}/hooks/{hook_id}\"],\n getWebhookConfigForRepo: [\n \"GET /repos/{owner}/{repo}/hooks/{hook_id}/config\",\n ],\n getWebhookDelivery: [\n \"GET /repos/{owner}/{repo}/hooks/{hook_id}/deliveries/{delivery_id}\",\n ],\n listAutolinks: [\"GET /repos/{owner}/{repo}/autolinks\"],\n listBranches: [\"GET /repos/{owner}/{repo}/branches\"],\n listBranchesForHeadCommit: [\n \"GET /repos/{owner}/{repo}/commits/{commit_sha}/branches-where-head\",\n ],\n listCollaborators: [\"GET /repos/{owner}/{repo}/collaborators\"],\n listCommentsForCommit: [\n \"GET /repos/{owner}/{repo}/commits/{commit_sha}/comments\",\n ],\n listCommitCommentsForRepo: [\"GET /repos/{owner}/{repo}/comments\"],\n listCommitStatusesForRef: [\n \"GET /repos/{owner}/{repo}/commits/{ref}/statuses\",\n ],\n listCommits: [\"GET /repos/{owner}/{repo}/commits\"],\n listContributors: [\"GET /repos/{owner}/{repo}/contributors\"],\n listDeployKeys: [\"GET /repos/{owner}/{repo}/keys\"],\n listDeploymentStatuses: [\n \"GET /repos/{owner}/{repo}/deployments/{deployment_id}/statuses\",\n ],\n listDeployments: [\"GET /repos/{owner}/{repo}/deployments\"],\n listForAuthenticatedUser: [\"GET /user/repos\"],\n listForOrg: [\"GET /orgs/{org}/repos\"],\n listForUser: [\"GET /users/{username}/repos\"],\n listForks: [\"GET /repos/{owner}/{repo}/forks\"],\n listInvitations: [\"GET /repos/{owner}/{repo}/invitations\"],\n listInvitationsForAuthenticatedUser: [\"GET /user/repository_invitations\"],\n listLanguages: [\"GET /repos/{owner}/{repo}/languages\"],\n listPagesBuilds: [\"GET /repos/{owner}/{repo}/pages/builds\"],\n listPublic: [\"GET /repositories\"],\n listPullRequestsAssociatedWithCommit: [\n \"GET /repos/{owner}/{repo}/commits/{commit_sha}/pulls\",\n ],\n listReleaseAssets: [\n \"GET /repos/{owner}/{repo}/releases/{release_id}/assets\",\n ],\n listReleases: [\"GET /repos/{owner}/{repo}/releases\"],\n listTagProtection: [\"GET /repos/{owner}/{repo}/tags/protection\"],\n listTags: [\"GET /repos/{owner}/{repo}/tags\"],\n listTeams: [\"GET /repos/{owner}/{repo}/teams\"],\n listWebhookDeliveries: [\n \"GET /repos/{owner}/{repo}/hooks/{hook_id}/deliveries\",\n ],\n listWebhooks: [\"GET /repos/{owner}/{repo}/hooks\"],\n merge: [\"POST /repos/{owner}/{repo}/merges\"],\n mergeUpstream: [\"POST /repos/{owner}/{repo}/merge-upstream\"],\n pingWebhook: [\"POST /repos/{owner}/{repo}/hooks/{hook_id}/pings\"],\n redeliverWebhookDelivery: [\n \"POST /repos/{owner}/{repo}/hooks/{hook_id}/deliveries/{delivery_id}/attempts\",\n ],\n removeAppAccessRestrictions: [\n \"DELETE /repos/{owner}/{repo}/branches/{branch}/protection/restrictions/apps\",\n {},\n { mapToData: \"apps\" },\n ],\n removeCollaborator: [\n \"DELETE /repos/{owner}/{repo}/collaborators/{username}\",\n ],\n removeStatusCheckContexts: [\n \"DELETE /repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks/contexts\",\n {},\n { mapToData: \"contexts\" },\n ],\n removeStatusCheckProtection: [\n \"DELETE /repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks\",\n ],\n removeTeamAccessRestrictions: [\n \"DELETE /repos/{owner}/{repo}/branches/{branch}/protection/restrictions/teams\",\n {},\n { mapToData: \"teams\" },\n ],\n removeUserAccessRestrictions: [\n \"DELETE /repos/{owner}/{repo}/branches/{branch}/protection/restrictions/users\",\n {},\n { mapToData: \"users\" },\n ],\n renameBranch: [\"POST /repos/{owner}/{repo}/branches/{branch}/rename\"],\n replaceAllTopics: [\"PUT /repos/{owner}/{repo}/topics\"],\n requestPagesBuild: [\"POST /repos/{owner}/{repo}/pages/builds\"],\n setAdminBranchProtection: [\n \"POST /repos/{owner}/{repo}/branches/{branch}/protection/enforce_admins\",\n ],\n setAppAccessRestrictions: [\n \"PUT /repos/{owner}/{repo}/branches/{branch}/protection/restrictions/apps\",\n {},\n { mapToData: \"apps\" },\n ],\n setStatusCheckContexts: [\n \"PUT /repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks/contexts\",\n {},\n { mapToData: \"contexts\" },\n ],\n setTeamAccessRestrictions: [\n \"PUT /repos/{owner}/{repo}/branches/{branch}/protection/restrictions/teams\",\n {},\n { mapToData: \"teams\" },\n ],\n setUserAccessRestrictions: [\n \"PUT /repos/{owner}/{repo}/branches/{branch}/protection/restrictions/users\",\n {},\n { mapToData: \"users\" },\n ],\n testPushWebhook: [\"POST /repos/{owner}/{repo}/hooks/{hook_id}/tests\"],\n transfer: [\"POST /repos/{owner}/{repo}/transfer\"],\n update: [\"PATCH /repos/{owner}/{repo}\"],\n updateBranchProtection: [\n \"PUT /repos/{owner}/{repo}/branches/{branch}/protection\",\n ],\n updateCommitComment: [\"PATCH /repos/{owner}/{repo}/comments/{comment_id}\"],\n updateInformationAboutPagesSite: [\"PUT /repos/{owner}/{repo}/pages\"],\n updateInvitation: [\n \"PATCH /repos/{owner}/{repo}/invitations/{invitation_id}\",\n ],\n updatePullRequestReviewProtection: [\n \"PATCH /repos/{owner}/{repo}/branches/{branch}/protection/required_pull_request_reviews\",\n ],\n updateRelease: [\"PATCH /repos/{owner}/{repo}/releases/{release_id}\"],\n updateReleaseAsset: [\n \"PATCH /repos/{owner}/{repo}/releases/assets/{asset_id}\",\n ],\n updateStatusCheckPotection: [\n \"PATCH /repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks\",\n {},\n { renamed: [\"repos\", \"updateStatusCheckProtection\"] },\n ],\n updateStatusCheckProtection: [\n \"PATCH /repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks\",\n ],\n updateWebhook: [\"PATCH /repos/{owner}/{repo}/hooks/{hook_id}\"],\n updateWebhookConfigForRepo: [\n \"PATCH /repos/{owner}/{repo}/hooks/{hook_id}/config\",\n ],\n uploadReleaseAsset: [\n \"POST /repos/{owner}/{repo}/releases/{release_id}/assets{?name,label}\",\n { baseUrl: \"https://uploads.github.com\" },\n ],\n },\n search: {\n code: [\"GET /search/code\"],\n commits: [\"GET /search/commits\"],\n issuesAndPullRequests: [\"GET /search/issues\"],\n labels: [\"GET /search/labels\"],\n repos: [\"GET /search/repositories\"],\n topics: [\"GET /search/topics\"],\n users: [\"GET /search/users\"],\n },\n secretScanning: {\n getAlert: [\n \"GET /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}\",\n ],\n listAlertsForEnterprise: [\n \"GET /enterprises/{enterprise}/secret-scanning/alerts\",\n ],\n listAlertsForOrg: [\"GET /orgs/{org}/secret-scanning/alerts\"],\n listAlertsForRepo: [\"GET /repos/{owner}/{repo}/secret-scanning/alerts\"],\n listLocationsForAlert: [\n \"GET /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/locations\",\n ],\n updateAlert: [\n \"PATCH /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}\",\n ],\n },\n teams: {\n addOrUpdateMembershipForUserInOrg: [\n \"PUT /orgs/{org}/teams/{team_slug}/memberships/{username}\",\n ],\n addOrUpdateProjectPermissionsInOrg: [\n \"PUT /orgs/{org}/teams/{team_slug}/projects/{project_id}\",\n ],\n addOrUpdateRepoPermissionsInOrg: [\n \"PUT /orgs/{org}/teams/{team_slug}/repos/{owner}/{repo}\",\n ],\n checkPermissionsForProjectInOrg: [\n \"GET /orgs/{org}/teams/{team_slug}/projects/{project_id}\",\n ],\n checkPermissionsForRepoInOrg: [\n \"GET /orgs/{org}/teams/{team_slug}/repos/{owner}/{repo}\",\n ],\n create: [\"POST /orgs/{org}/teams\"],\n createDiscussionCommentInOrg: [\n \"POST /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments\",\n ],\n createDiscussionInOrg: [\"POST /orgs/{org}/teams/{team_slug}/discussions\"],\n deleteDiscussionCommentInOrg: [\n \"DELETE /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}\",\n ],\n deleteDiscussionInOrg: [\n \"DELETE /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}\",\n ],\n deleteInOrg: [\"DELETE /orgs/{org}/teams/{team_slug}\"],\n getByName: [\"GET /orgs/{org}/teams/{team_slug}\"],\n getDiscussionCommentInOrg: [\n \"GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}\",\n ],\n getDiscussionInOrg: [\n \"GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}\",\n ],\n getMembershipForUserInOrg: [\n \"GET /orgs/{org}/teams/{team_slug}/memberships/{username}\",\n ],\n list: [\"GET /orgs/{org}/teams\"],\n listChildInOrg: [\"GET /orgs/{org}/teams/{team_slug}/teams\"],\n listDiscussionCommentsInOrg: [\n \"GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments\",\n ],\n listDiscussionsInOrg: [\"GET /orgs/{org}/teams/{team_slug}/discussions\"],\n listForAuthenticatedUser: [\"GET /user/teams\"],\n listMembersInOrg: [\"GET /orgs/{org}/teams/{team_slug}/members\"],\n listPendingInvitationsInOrg: [\n \"GET /orgs/{org}/teams/{team_slug}/invitations\",\n ],\n listProjectsInOrg: [\"GET /orgs/{org}/teams/{team_slug}/projects\"],\n listReposInOrg: [\"GET /orgs/{org}/teams/{team_slug}/repos\"],\n removeMembershipForUserInOrg: [\n \"DELETE /orgs/{org}/teams/{team_slug}/memberships/{username}\",\n ],\n removeProjectInOrg: [\n \"DELETE /orgs/{org}/teams/{team_slug}/projects/{project_id}\",\n ],\n removeRepoInOrg: [\n \"DELETE /orgs/{org}/teams/{team_slug}/repos/{owner}/{repo}\",\n ],\n updateDiscussionCommentInOrg: [\n \"PATCH /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}\",\n ],\n updateDiscussionInOrg: [\n \"PATCH /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}\",\n ],\n updateInOrg: [\"PATCH /orgs/{org}/teams/{team_slug}\"],\n },\n users: {\n addEmailForAuthenticated: [\n \"POST /user/emails\",\n {},\n { renamed: [\"users\", \"addEmailForAuthenticatedUser\"] },\n ],\n addEmailForAuthenticatedUser: [\"POST /user/emails\"],\n block: [\"PUT /user/blocks/{username}\"],\n checkBlocked: [\"GET /user/blocks/{username}\"],\n checkFollowingForUser: [\"GET /users/{username}/following/{target_user}\"],\n checkPersonIsFollowedByAuthenticated: [\"GET /user/following/{username}\"],\n createGpgKeyForAuthenticated: [\n \"POST /user/gpg_keys\",\n {},\n { renamed: [\"users\", \"createGpgKeyForAuthenticatedUser\"] },\n ],\n createGpgKeyForAuthenticatedUser: [\"POST /user/gpg_keys\"],\n createPublicSshKeyForAuthenticated: [\n \"POST /user/keys\",\n {},\n { renamed: [\"users\", \"createPublicSshKeyForAuthenticatedUser\"] },\n ],\n createPublicSshKeyForAuthenticatedUser: [\"POST /user/keys\"],\n deleteEmailForAuthenticated: [\n \"DELETE /user/emails\",\n {},\n { renamed: [\"users\", \"deleteEmailForAuthenticatedUser\"] },\n ],\n deleteEmailForAuthenticatedUser: [\"DELETE /user/emails\"],\n deleteGpgKeyForAuthenticated: [\n \"DELETE /user/gpg_keys/{gpg_key_id}\",\n {},\n { renamed: [\"users\", \"deleteGpgKeyForAuthenticatedUser\"] },\n ],\n deleteGpgKeyForAuthenticatedUser: [\"DELETE /user/gpg_keys/{gpg_key_id}\"],\n deletePublicSshKeyForAuthenticated: [\n \"DELETE /user/keys/{key_id}\",\n {},\n { renamed: [\"users\", \"deletePublicSshKeyForAuthenticatedUser\"] },\n ],\n deletePublicSshKeyForAuthenticatedUser: [\"DELETE /user/keys/{key_id}\"],\n follow: [\"PUT /user/following/{username}\"],\n getAuthenticated: [\"GET /user\"],\n getByUsername: [\"GET /users/{username}\"],\n getContextForUser: [\"GET /users/{username}/hovercard\"],\n getGpgKeyForAuthenticated: [\n \"GET /user/gpg_keys/{gpg_key_id}\",\n {},\n { renamed: [\"users\", \"getGpgKeyForAuthenticatedUser\"] },\n ],\n getGpgKeyForAuthenticatedUser: [\"GET /user/gpg_keys/{gpg_key_id}\"],\n getPublicSshKeyForAuthenticated: [\n \"GET /user/keys/{key_id}\",\n {},\n { renamed: [\"users\", \"getPublicSshKeyForAuthenticatedUser\"] },\n ],\n getPublicSshKeyForAuthenticatedUser: [\"GET /user/keys/{key_id}\"],\n list: [\"GET /users\"],\n listBlockedByAuthenticated: [\n \"GET /user/blocks\",\n {},\n { renamed: [\"users\", \"listBlockedByAuthenticatedUser\"] },\n ],\n listBlockedByAuthenticatedUser: [\"GET /user/blocks\"],\n listEmailsForAuthenticated: [\n \"GET /user/emails\",\n {},\n { renamed: [\"users\", \"listEmailsForAuthenticatedUser\"] },\n ],\n listEmailsForAuthenticatedUser: [\"GET /user/emails\"],\n listFollowedByAuthenticated: [\n \"GET /user/following\",\n {},\n { renamed: [\"users\", \"listFollowedByAuthenticatedUser\"] },\n ],\n listFollowedByAuthenticatedUser: [\"GET /user/following\"],\n listFollowersForAuthenticatedUser: [\"GET /user/followers\"],\n listFollowersForUser: [\"GET /users/{username}/followers\"],\n listFollowingForUser: [\"GET /users/{username}/following\"],\n listGpgKeysForAuthenticated: [\n \"GET /user/gpg_keys\",\n {},\n { renamed: [\"users\", \"listGpgKeysForAuthenticatedUser\"] },\n ],\n listGpgKeysForAuthenticatedUser: [\"GET /user/gpg_keys\"],\n listGpgKeysForUser: [\"GET /users/{username}/gpg_keys\"],\n listPublicEmailsForAuthenticated: [\n \"GET /user/public_emails\",\n {},\n { renamed: [\"users\", \"listPublicEmailsForAuthenticatedUser\"] },\n ],\n listPublicEmailsForAuthenticatedUser: [\"GET /user/public_emails\"],\n listPublicKeysForUser: [\"GET /users/{username}/keys\"],\n listPublicSshKeysForAuthenticated: [\n \"GET /user/keys\",\n {},\n { renamed: [\"users\", \"listPublicSshKeysForAuthenticatedUser\"] },\n ],\n listPublicSshKeysForAuthenticatedUser: [\"GET /user/keys\"],\n setPrimaryEmailVisibilityForAuthenticated: [\n \"PATCH /user/email/visibility\",\n {},\n { renamed: [\"users\", \"setPrimaryEmailVisibilityForAuthenticatedUser\"] },\n ],\n setPrimaryEmailVisibilityForAuthenticatedUser: [\n \"PATCH /user/email/visibility\",\n ],\n unblock: [\"DELETE /user/blocks/{username}\"],\n unfollow: [\"DELETE /user/following/{username}\"],\n updateAuthenticated: [\"PATCH /user\"],\n },\n};\nexport default Endpoints;\n", "export const VERSION = \"5.16.2\";\n", "export function endpointsToMethods(octokit, endpointsMap) {\n const newMethods = {};\n for (const [scope, endpoints] of Object.entries(endpointsMap)) {\n for (const [methodName, endpoint] of Object.entries(endpoints)) {\n const [route, defaults, decorations] = endpoint;\n const [method, url] = route.split(/ /);\n const endpointDefaults = Object.assign({ method, url }, defaults);\n if (!newMethods[scope]) {\n newMethods[scope] = {};\n }\n const scopeMethods = newMethods[scope];\n if (decorations) {\n scopeMethods[methodName] = decorate(octokit, scope, methodName, endpointDefaults, decorations);\n continue;\n }\n scopeMethods[methodName] = octokit.request.defaults(endpointDefaults);\n }\n }\n return newMethods;\n}\nfunction decorate(octokit, scope, methodName, defaults, decorations) {\n const requestWithDefaults = octokit.request.defaults(defaults);\n /* istanbul ignore next */\n function withDecorations(...args) {\n // @ts-ignore https://github.com/microsoft/TypeScript/issues/25488\n let options = requestWithDefaults.endpoint.merge(...args);\n // There are currently no other decorations than `.mapToData`\n if (decorations.mapToData) {\n options = Object.assign({}, options, {\n data: options[decorations.mapToData],\n [decorations.mapToData]: undefined,\n });\n return requestWithDefaults(options);\n }\n if (decorations.renamed) {\n const [newScope, newMethodName] = decorations.renamed;\n octokit.log.warn(`octokit.${scope}.${methodName}() has been renamed to octokit.${newScope}.${newMethodName}()`);\n }\n if (decorations.deprecated) {\n octokit.log.warn(decorations.deprecated);\n }\n if (decorations.renamedParameters) {\n // @ts-ignore https://github.com/microsoft/TypeScript/issues/25488\n const options = requestWithDefaults.endpoint.merge(...args);\n for (const [name, alias] of Object.entries(decorations.renamedParameters)) {\n if (name in options) {\n octokit.log.warn(`\"${name}\" parameter is deprecated for \"octokit.${scope}.${methodName}()\". Use \"${alias}\" instead`);\n if (!(alias in options)) {\n options[alias] = options[name];\n }\n delete options[name];\n }\n }\n return requestWithDefaults(options);\n }\n // @ts-ignore https://github.com/microsoft/TypeScript/issues/25488\n return requestWithDefaults(...args);\n }\n return Object.assign(withDecorations, requestWithDefaults);\n}\n", "import ENDPOINTS from \"./generated/endpoints\";\nimport { VERSION } from \"./version\";\nimport { endpointsToMethods } from \"./endpoints-to-methods\";\nexport function restEndpointMethods(octokit) {\n const api = endpointsToMethods(octokit, ENDPOINTS);\n return {\n rest: api,\n };\n}\nrestEndpointMethods.VERSION = VERSION;\nexport function legacyRestEndpointMethods(octokit) {\n const api = endpointsToMethods(octokit, ENDPOINTS);\n return {\n ...api,\n rest: api,\n };\n}\nlegacyRestEndpointMethods.VERSION = VERSION;\n", "export const VERSION = \"2.21.3\";\n", "/**\n * Some \u201Clist\u201D response that can be paginated have a different response structure\n *\n * They have a `total_count` key in the response (search also has `incomplete_results`,\n * /installation/repositories also has `repository_selection`), as well as a key with\n * the list of the items which name varies from endpoint to endpoint.\n *\n * Octokit normalizes these responses so that paginated results are always returned following\n * the same structure. One challenge is that if the list response has only one page, no Link\n * header is provided, so this header alone is not sufficient to check wether a response is\n * paginated or not.\n *\n * We check if a \"total_count\" key is present in the response data, but also make sure that\n * a \"url\" property is not, as the \"Get the combined status for a specific ref\" endpoint would\n * otherwise match: https://developer.github.com/v3/repos/statuses/#get-the-combined-status-for-a-specific-ref\n */\nexport function normalizePaginatedListResponse(response) {\n // endpoints can respond with 204 if repository is empty\n if (!response.data) {\n return {\n ...response,\n data: [],\n };\n }\n const responseNeedsNormalization = \"total_count\" in response.data && !(\"url\" in response.data);\n if (!responseNeedsNormalization)\n return response;\n // keep the additional properties intact as there is currently no other way\n // to retrieve the same information.\n const incompleteResults = response.data.incomplete_results;\n const repositorySelection = response.data.repository_selection;\n const totalCount = response.data.total_count;\n delete response.data.incomplete_results;\n delete response.data.repository_selection;\n delete response.data.total_count;\n const namespaceKey = Object.keys(response.data)[0];\n const data = response.data[namespaceKey];\n response.data = data;\n if (typeof incompleteResults !== \"undefined\") {\n response.data.incomplete_results = incompleteResults;\n }\n if (typeof repositorySelection !== \"undefined\") {\n response.data.repository_selection = repositorySelection;\n }\n response.data.total_count = totalCount;\n return response;\n}\n", "import { normalizePaginatedListResponse } from \"./normalize-paginated-list-response\";\nexport function iterator(octokit, route, parameters) {\n const options = typeof route === \"function\"\n ? route.endpoint(parameters)\n : octokit.request.endpoint(route, parameters);\n const requestMethod = typeof route === \"function\" ? route : octokit.request;\n const method = options.method;\n const headers = options.headers;\n let url = options.url;\n return {\n [Symbol.asyncIterator]: () => ({\n async next() {\n if (!url)\n return { done: true };\n try {\n const response = await requestMethod({ method, url, headers });\n const normalizedResponse = normalizePaginatedListResponse(response);\n // `response.headers.link` format:\n // '; rel=\"next\", ; rel=\"last\"'\n // sets `url` to undefined if \"next\" URL is not present or `link` header is not set\n url = ((normalizedResponse.headers.link || \"\").match(/<([^>]+)>;\\s*rel=\"next\"/) || [])[1];\n return { value: normalizedResponse };\n }\n catch (error) {\n if (error.status !== 409)\n throw error;\n url = \"\";\n return {\n value: {\n status: 200,\n headers: {},\n data: [],\n },\n };\n }\n },\n }),\n };\n}\n", "import { iterator } from \"./iterator\";\nexport function paginate(octokit, route, parameters, mapFn) {\n if (typeof parameters === \"function\") {\n mapFn = parameters;\n parameters = undefined;\n }\n return gather(octokit, [], iterator(octokit, route, parameters)[Symbol.asyncIterator](), mapFn);\n}\nfunction gather(octokit, results, iterator, mapFn) {\n return iterator.next().then((result) => {\n if (result.done) {\n return results;\n }\n let earlyExit = false;\n function done() {\n earlyExit = true;\n }\n results = results.concat(mapFn ? mapFn(result.value, done) : result.value.data);\n if (earlyExit) {\n return results;\n }\n return gather(octokit, results, iterator, mapFn);\n });\n}\n", "import { paginate } from \"./paginate\";\nimport { iterator } from \"./iterator\";\nexport const composePaginateRest = Object.assign(paginate, {\n iterator,\n});\n", "export const paginatingEndpoints = [\n \"GET /app/hook/deliveries\",\n \"GET /app/installations\",\n \"GET /applications/grants\",\n \"GET /authorizations\",\n \"GET /enterprises/{enterprise}/actions/permissions/organizations\",\n \"GET /enterprises/{enterprise}/actions/runner-groups\",\n \"GET /enterprises/{enterprise}/actions/runner-groups/{runner_group_id}/organizations\",\n \"GET /enterprises/{enterprise}/actions/runner-groups/{runner_group_id}/runners\",\n \"GET /enterprises/{enterprise}/actions/runners\",\n \"GET /enterprises/{enterprise}/audit-log\",\n \"GET /enterprises/{enterprise}/secret-scanning/alerts\",\n \"GET /enterprises/{enterprise}/settings/billing/advanced-security\",\n \"GET /events\",\n \"GET /gists\",\n \"GET /gists/public\",\n \"GET /gists/starred\",\n \"GET /gists/{gist_id}/comments\",\n \"GET /gists/{gist_id}/commits\",\n \"GET /gists/{gist_id}/forks\",\n \"GET /installation/repositories\",\n \"GET /issues\",\n \"GET /licenses\",\n \"GET /marketplace_listing/plans\",\n \"GET /marketplace_listing/plans/{plan_id}/accounts\",\n \"GET /marketplace_listing/stubbed/plans\",\n \"GET /marketplace_listing/stubbed/plans/{plan_id}/accounts\",\n \"GET /networks/{owner}/{repo}/events\",\n \"GET /notifications\",\n \"GET /organizations\",\n \"GET /orgs/{org}/actions/cache/usage-by-repository\",\n \"GET /orgs/{org}/actions/permissions/repositories\",\n \"GET /orgs/{org}/actions/runner-groups\",\n \"GET /orgs/{org}/actions/runner-groups/{runner_group_id}/repositories\",\n \"GET /orgs/{org}/actions/runner-groups/{runner_group_id}/runners\",\n \"GET /orgs/{org}/actions/runners\",\n \"GET /orgs/{org}/actions/secrets\",\n \"GET /orgs/{org}/actions/secrets/{secret_name}/repositories\",\n \"GET /orgs/{org}/audit-log\",\n \"GET /orgs/{org}/blocks\",\n \"GET /orgs/{org}/code-scanning/alerts\",\n \"GET /orgs/{org}/codespaces\",\n \"GET /orgs/{org}/credential-authorizations\",\n \"GET /orgs/{org}/dependabot/secrets\",\n \"GET /orgs/{org}/dependabot/secrets/{secret_name}/repositories\",\n \"GET /orgs/{org}/events\",\n \"GET /orgs/{org}/external-groups\",\n \"GET /orgs/{org}/failed_invitations\",\n \"GET /orgs/{org}/hooks\",\n \"GET /orgs/{org}/hooks/{hook_id}/deliveries\",\n \"GET /orgs/{org}/installations\",\n \"GET /orgs/{org}/invitations\",\n \"GET /orgs/{org}/invitations/{invitation_id}/teams\",\n \"GET /orgs/{org}/issues\",\n \"GET /orgs/{org}/members\",\n \"GET /orgs/{org}/migrations\",\n \"GET /orgs/{org}/migrations/{migration_id}/repositories\",\n \"GET /orgs/{org}/outside_collaborators\",\n \"GET /orgs/{org}/packages\",\n \"GET /orgs/{org}/packages/{package_type}/{package_name}/versions\",\n \"GET /orgs/{org}/projects\",\n \"GET /orgs/{org}/public_members\",\n \"GET /orgs/{org}/repos\",\n \"GET /orgs/{org}/secret-scanning/alerts\",\n \"GET /orgs/{org}/settings/billing/advanced-security\",\n \"GET /orgs/{org}/team-sync/groups\",\n \"GET /orgs/{org}/teams\",\n \"GET /orgs/{org}/teams/{team_slug}/discussions\",\n \"GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments\",\n \"GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}/reactions\",\n \"GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/reactions\",\n \"GET /orgs/{org}/teams/{team_slug}/invitations\",\n \"GET /orgs/{org}/teams/{team_slug}/members\",\n \"GET /orgs/{org}/teams/{team_slug}/projects\",\n \"GET /orgs/{org}/teams/{team_slug}/repos\",\n \"GET /orgs/{org}/teams/{team_slug}/teams\",\n \"GET /projects/columns/{column_id}/cards\",\n \"GET /projects/{project_id}/collaborators\",\n \"GET /projects/{project_id}/columns\",\n \"GET /repos/{owner}/{repo}/actions/artifacts\",\n \"GET /repos/{owner}/{repo}/actions/caches\",\n \"GET /repos/{owner}/{repo}/actions/runners\",\n \"GET /repos/{owner}/{repo}/actions/runs\",\n \"GET /repos/{owner}/{repo}/actions/runs/{run_id}/artifacts\",\n \"GET /repos/{owner}/{repo}/actions/runs/{run_id}/attempts/{attempt_number}/jobs\",\n \"GET /repos/{owner}/{repo}/actions/runs/{run_id}/jobs\",\n \"GET /repos/{owner}/{repo}/actions/secrets\",\n \"GET /repos/{owner}/{repo}/actions/workflows\",\n \"GET /repos/{owner}/{repo}/actions/workflows/{workflow_id}/runs\",\n \"GET /repos/{owner}/{repo}/assignees\",\n \"GET /repos/{owner}/{repo}/branches\",\n \"GET /repos/{owner}/{repo}/check-runs/{check_run_id}/annotations\",\n \"GET /repos/{owner}/{repo}/check-suites/{check_suite_id}/check-runs\",\n \"GET /repos/{owner}/{repo}/code-scanning/alerts\",\n \"GET /repos/{owner}/{repo}/code-scanning/alerts/{alert_number}/instances\",\n \"GET /repos/{owner}/{repo}/code-scanning/analyses\",\n \"GET /repos/{owner}/{repo}/codespaces\",\n \"GET /repos/{owner}/{repo}/codespaces/devcontainers\",\n \"GET /repos/{owner}/{repo}/codespaces/secrets\",\n \"GET /repos/{owner}/{repo}/collaborators\",\n \"GET /repos/{owner}/{repo}/comments\",\n \"GET /repos/{owner}/{repo}/comments/{comment_id}/reactions\",\n \"GET /repos/{owner}/{repo}/commits\",\n \"GET /repos/{owner}/{repo}/commits/{commit_sha}/comments\",\n \"GET /repos/{owner}/{repo}/commits/{commit_sha}/pulls\",\n \"GET /repos/{owner}/{repo}/commits/{ref}/check-runs\",\n \"GET /repos/{owner}/{repo}/commits/{ref}/check-suites\",\n \"GET /repos/{owner}/{repo}/commits/{ref}/status\",\n \"GET /repos/{owner}/{repo}/commits/{ref}/statuses\",\n \"GET /repos/{owner}/{repo}/contributors\",\n \"GET /repos/{owner}/{repo}/dependabot/secrets\",\n \"GET /repos/{owner}/{repo}/deployments\",\n \"GET /repos/{owner}/{repo}/deployments/{deployment_id}/statuses\",\n \"GET /repos/{owner}/{repo}/environments\",\n \"GET /repos/{owner}/{repo}/events\",\n \"GET /repos/{owner}/{repo}/forks\",\n \"GET /repos/{owner}/{repo}/git/matching-refs/{ref}\",\n \"GET /repos/{owner}/{repo}/hooks\",\n \"GET /repos/{owner}/{repo}/hooks/{hook_id}/deliveries\",\n \"GET /repos/{owner}/{repo}/invitations\",\n \"GET /repos/{owner}/{repo}/issues\",\n \"GET /repos/{owner}/{repo}/issues/comments\",\n \"GET /repos/{owner}/{repo}/issues/comments/{comment_id}/reactions\",\n \"GET /repos/{owner}/{repo}/issues/events\",\n \"GET /repos/{owner}/{repo}/issues/{issue_number}/comments\",\n \"GET /repos/{owner}/{repo}/issues/{issue_number}/events\",\n \"GET /repos/{owner}/{repo}/issues/{issue_number}/labels\",\n \"GET /repos/{owner}/{repo}/issues/{issue_number}/reactions\",\n \"GET /repos/{owner}/{repo}/issues/{issue_number}/timeline\",\n \"GET /repos/{owner}/{repo}/keys\",\n \"GET /repos/{owner}/{repo}/labels\",\n \"GET /repos/{owner}/{repo}/milestones\",\n \"GET /repos/{owner}/{repo}/milestones/{milestone_number}/labels\",\n \"GET /repos/{owner}/{repo}/notifications\",\n \"GET /repos/{owner}/{repo}/pages/builds\",\n \"GET /repos/{owner}/{repo}/projects\",\n \"GET /repos/{owner}/{repo}/pulls\",\n \"GET /repos/{owner}/{repo}/pulls/comments\",\n \"GET /repos/{owner}/{repo}/pulls/comments/{comment_id}/reactions\",\n \"GET /repos/{owner}/{repo}/pulls/{pull_number}/comments\",\n \"GET /repos/{owner}/{repo}/pulls/{pull_number}/commits\",\n \"GET /repos/{owner}/{repo}/pulls/{pull_number}/files\",\n \"GET /repos/{owner}/{repo}/pulls/{pull_number}/requested_reviewers\",\n \"GET /repos/{owner}/{repo}/pulls/{pull_number}/reviews\",\n \"GET /repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}/comments\",\n \"GET /repos/{owner}/{repo}/releases\",\n \"GET /repos/{owner}/{repo}/releases/{release_id}/assets\",\n \"GET /repos/{owner}/{repo}/releases/{release_id}/reactions\",\n \"GET /repos/{owner}/{repo}/secret-scanning/alerts\",\n \"GET /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/locations\",\n \"GET /repos/{owner}/{repo}/stargazers\",\n \"GET /repos/{owner}/{repo}/subscribers\",\n \"GET /repos/{owner}/{repo}/tags\",\n \"GET /repos/{owner}/{repo}/teams\",\n \"GET /repos/{owner}/{repo}/topics\",\n \"GET /repositories\",\n \"GET /repositories/{repository_id}/environments/{environment_name}/secrets\",\n \"GET /search/code\",\n \"GET /search/commits\",\n \"GET /search/issues\",\n \"GET /search/labels\",\n \"GET /search/repositories\",\n \"GET /search/topics\",\n \"GET /search/users\",\n \"GET /teams/{team_id}/discussions\",\n \"GET /teams/{team_id}/discussions/{discussion_number}/comments\",\n \"GET /teams/{team_id}/discussions/{discussion_number}/comments/{comment_number}/reactions\",\n \"GET /teams/{team_id}/discussions/{discussion_number}/reactions\",\n \"GET /teams/{team_id}/invitations\",\n \"GET /teams/{team_id}/members\",\n \"GET /teams/{team_id}/projects\",\n \"GET /teams/{team_id}/repos\",\n \"GET /teams/{team_id}/teams\",\n \"GET /user/blocks\",\n \"GET /user/codespaces\",\n \"GET /user/codespaces/secrets\",\n \"GET /user/emails\",\n \"GET /user/followers\",\n \"GET /user/following\",\n \"GET /user/gpg_keys\",\n \"GET /user/installations\",\n \"GET /user/installations/{installation_id}/repositories\",\n \"GET /user/issues\",\n \"GET /user/keys\",\n \"GET /user/marketplace_purchases\",\n \"GET /user/marketplace_purchases/stubbed\",\n \"GET /user/memberships/orgs\",\n \"GET /user/migrations\",\n \"GET /user/migrations/{migration_id}/repositories\",\n \"GET /user/orgs\",\n \"GET /user/packages\",\n \"GET /user/packages/{package_type}/{package_name}/versions\",\n \"GET /user/public_emails\",\n \"GET /user/repos\",\n \"GET /user/repository_invitations\",\n \"GET /user/starred\",\n \"GET /user/subscriptions\",\n \"GET /user/teams\",\n \"GET /users\",\n \"GET /users/{username}/events\",\n \"GET /users/{username}/events/orgs/{org}\",\n \"GET /users/{username}/events/public\",\n \"GET /users/{username}/followers\",\n \"GET /users/{username}/following\",\n \"GET /users/{username}/gists\",\n \"GET /users/{username}/gpg_keys\",\n \"GET /users/{username}/keys\",\n \"GET /users/{username}/orgs\",\n \"GET /users/{username}/packages\",\n \"GET /users/{username}/projects\",\n \"GET /users/{username}/received_events\",\n \"GET /users/{username}/received_events/public\",\n \"GET /users/{username}/repos\",\n \"GET /users/{username}/starred\",\n \"GET /users/{username}/subscriptions\",\n];\n", "import { paginatingEndpoints, } from \"./generated/paginating-endpoints\";\nexport { paginatingEndpoints } from \"./generated/paginating-endpoints\";\nexport function isPaginatingEndpoint(arg) {\n if (typeof arg === \"string\") {\n return paginatingEndpoints.includes(arg);\n }\n else {\n return false;\n }\n}\n", "import { VERSION } from \"./version\";\nimport { paginate } from \"./paginate\";\nimport { iterator } from \"./iterator\";\nexport { composePaginateRest } from \"./compose-paginate\";\nexport { isPaginatingEndpoint, paginatingEndpoints, } from \"./paginating-endpoints\";\n/**\n * @param octokit Octokit instance\n * @param options Options passed to Octokit constructor\n */\nexport function paginateRest(octokit) {\n return {\n paginate: Object.assign(paginate.bind(null, octokit), {\n iterator: iterator.bind(null, octokit),\n }),\n };\n}\npaginateRest.VERSION = VERSION;\n", null, null, "/**\n * Checks if `value` is classified as an `Array` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array, else `false`.\n * @example\n *\n * _.isArray([1, 2, 3]);\n * // => true\n *\n * _.isArray(document.body.children);\n * // => false\n *\n * _.isArray('abc');\n * // => false\n *\n * _.isArray(_.noop);\n * // => false\n */\nvar isArray = Array.isArray;\n\nmodule.exports = isArray;\n", "/** Detect free variable `global` from Node.js. */\nvar freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\n\nmodule.exports = freeGlobal;\n", "var freeGlobal = require('./_freeGlobal');\n\n/** Detect free variable `self`. */\nvar freeSelf = typeof self == 'object' && self && self.Object === Object && self;\n\n/** Used as a reference to the global object. */\nvar root = freeGlobal || freeSelf || Function('return this')();\n\nmodule.exports = root;\n", "var root = require('./_root');\n\n/** Built-in value references. */\nvar Symbol = root.Symbol;\n\nmodule.exports = Symbol;\n", "var Symbol = require('./_Symbol');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the raw `toStringTag`.\n */\nfunction getRawTag(value) {\n var isOwn = hasOwnProperty.call(value, symToStringTag),\n tag = value[symToStringTag];\n\n try {\n value[symToStringTag] = undefined;\n var unmasked = true;\n } catch (e) {}\n\n var result = nativeObjectToString.call(value);\n if (unmasked) {\n if (isOwn) {\n value[symToStringTag] = tag;\n } else {\n delete value[symToStringTag];\n }\n }\n return result;\n}\n\nmodule.exports = getRawTag;\n", "/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/**\n * Converts `value` to a string using `Object.prototype.toString`.\n *\n * @private\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n */\nfunction objectToString(value) {\n return nativeObjectToString.call(value);\n}\n\nmodule.exports = objectToString;\n", "var Symbol = require('./_Symbol'),\n getRawTag = require('./_getRawTag'),\n objectToString = require('./_objectToString');\n\n/** `Object#toString` result references. */\nvar nullTag = '[object Null]',\n undefinedTag = '[object Undefined]';\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * The base implementation of `getTag` without fallbacks for buggy environments.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nfunction baseGetTag(value) {\n if (value == null) {\n return value === undefined ? undefinedTag : nullTag;\n }\n return (symToStringTag && symToStringTag in Object(value))\n ? getRawTag(value)\n : objectToString(value);\n}\n\nmodule.exports = baseGetTag;\n", "/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n return value != null && typeof value == 'object';\n}\n\nmodule.exports = isObjectLike;\n", "var baseGetTag = require('./_baseGetTag'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar symbolTag = '[object Symbol]';\n\n/**\n * Checks if `value` is classified as a `Symbol` primitive or object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.\n * @example\n *\n * _.isSymbol(Symbol.iterator);\n * // => true\n *\n * _.isSymbol('abc');\n * // => false\n */\nfunction isSymbol(value) {\n return typeof value == 'symbol' ||\n (isObjectLike(value) && baseGetTag(value) == symbolTag);\n}\n\nmodule.exports = isSymbol;\n", "var isArray = require('./isArray'),\n isSymbol = require('./isSymbol');\n\n/** Used to match property names within property paths. */\nvar reIsDeepProp = /\\.|\\[(?:[^[\\]]*|([\"'])(?:(?!\\1)[^\\\\]|\\\\.)*?\\1)\\]/,\n reIsPlainProp = /^\\w*$/;\n\n/**\n * Checks if `value` is a property name and not a property path.\n *\n * @private\n * @param {*} value The value to check.\n * @param {Object} [object] The object to query keys on.\n * @returns {boolean} Returns `true` if `value` is a property name, else `false`.\n */\nfunction isKey(value, object) {\n if (isArray(value)) {\n return false;\n }\n var type = typeof value;\n if (type == 'number' || type == 'symbol' || type == 'boolean' ||\n value == null || isSymbol(value)) {\n return true;\n }\n return reIsPlainProp.test(value) || !reIsDeepProp.test(value) ||\n (object != null && value in Object(object));\n}\n\nmodule.exports = isKey;\n", "/**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\nfunction isObject(value) {\n var type = typeof value;\n return value != null && (type == 'object' || type == 'function');\n}\n\nmodule.exports = isObject;\n", "var baseGetTag = require('./_baseGetTag'),\n isObject = require('./isObject');\n\n/** `Object#toString` result references. */\nvar asyncTag = '[object AsyncFunction]',\n funcTag = '[object Function]',\n genTag = '[object GeneratorFunction]',\n proxyTag = '[object Proxy]';\n\n/**\n * Checks if `value` is classified as a `Function` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a function, else `false`.\n * @example\n *\n * _.isFunction(_);\n * // => true\n *\n * _.isFunction(/abc/);\n * // => false\n */\nfunction isFunction(value) {\n if (!isObject(value)) {\n return false;\n }\n // The use of `Object#toString` avoids issues with the `typeof` operator\n // in Safari 9 which returns 'object' for typed arrays and other constructors.\n var tag = baseGetTag(value);\n return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;\n}\n\nmodule.exports = isFunction;\n", "var root = require('./_root');\n\n/** Used to detect overreaching core-js shims. */\nvar coreJsData = root['__core-js_shared__'];\n\nmodule.exports = coreJsData;\n", "var coreJsData = require('./_coreJsData');\n\n/** Used to detect methods masquerading as native. */\nvar maskSrcKey = (function() {\n var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');\n return uid ? ('Symbol(src)_1.' + uid) : '';\n}());\n\n/**\n * Checks if `func` has its source masked.\n *\n * @private\n * @param {Function} func The function to check.\n * @returns {boolean} Returns `true` if `func` is masked, else `false`.\n */\nfunction isMasked(func) {\n return !!maskSrcKey && (maskSrcKey in func);\n}\n\nmodule.exports = isMasked;\n", "/** Used for built-in method references. */\nvar funcProto = Function.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/**\n * Converts `func` to its source code.\n *\n * @private\n * @param {Function} func The function to convert.\n * @returns {string} Returns the source code.\n */\nfunction toSource(func) {\n if (func != null) {\n try {\n return funcToString.call(func);\n } catch (e) {}\n try {\n return (func + '');\n } catch (e) {}\n }\n return '';\n}\n\nmodule.exports = toSource;\n", "var isFunction = require('./isFunction'),\n isMasked = require('./_isMasked'),\n isObject = require('./isObject'),\n toSource = require('./_toSource');\n\n/**\n * Used to match `RegExp`\n * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).\n */\nvar reRegExpChar = /[\\\\^$.*+?()[\\]{}|]/g;\n\n/** Used to detect host constructors (Safari). */\nvar reIsHostCtor = /^\\[object .+?Constructor\\]$/;\n\n/** Used for built-in method references. */\nvar funcProto = Function.prototype,\n objectProto = Object.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Used to detect if a method is native. */\nvar reIsNative = RegExp('^' +\n funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\\\$&')\n .replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g, '$1.*?') + '$'\n);\n\n/**\n * The base implementation of `_.isNative` without bad shim checks.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a native function,\n * else `false`.\n */\nfunction baseIsNative(value) {\n if (!isObject(value) || isMasked(value)) {\n return false;\n }\n var pattern = isFunction(value) ? reIsNative : reIsHostCtor;\n return pattern.test(toSource(value));\n}\n\nmodule.exports = baseIsNative;\n", "/**\n * Gets the value at `key` of `object`.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\nfunction getValue(object, key) {\n return object == null ? undefined : object[key];\n}\n\nmodule.exports = getValue;\n", "var baseIsNative = require('./_baseIsNative'),\n getValue = require('./_getValue');\n\n/**\n * Gets the native function at `key` of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the method to get.\n * @returns {*} Returns the function if it's native, else `undefined`.\n */\nfunction getNative(object, key) {\n var value = getValue(object, key);\n return baseIsNative(value) ? value : undefined;\n}\n\nmodule.exports = getNative;\n", "var getNative = require('./_getNative');\n\n/* Built-in method references that are verified to be native. */\nvar nativeCreate = getNative(Object, 'create');\n\nmodule.exports = nativeCreate;\n", "var nativeCreate = require('./_nativeCreate');\n\n/**\n * Removes all key-value entries from the hash.\n *\n * @private\n * @name clear\n * @memberOf Hash\n */\nfunction hashClear() {\n this.__data__ = nativeCreate ? nativeCreate(null) : {};\n this.size = 0;\n}\n\nmodule.exports = hashClear;\n", "/**\n * Removes `key` and its value from the hash.\n *\n * @private\n * @name delete\n * @memberOf Hash\n * @param {Object} hash The hash to modify.\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction hashDelete(key) {\n var result = this.has(key) && delete this.__data__[key];\n this.size -= result ? 1 : 0;\n return result;\n}\n\nmodule.exports = hashDelete;\n", "var nativeCreate = require('./_nativeCreate');\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Gets the hash value for `key`.\n *\n * @private\n * @name get\n * @memberOf Hash\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction hashGet(key) {\n var data = this.__data__;\n if (nativeCreate) {\n var result = data[key];\n return result === HASH_UNDEFINED ? undefined : result;\n }\n return hasOwnProperty.call(data, key) ? data[key] : undefined;\n}\n\nmodule.exports = hashGet;\n", "var nativeCreate = require('./_nativeCreate');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Checks if a hash value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Hash\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction hashHas(key) {\n var data = this.__data__;\n return nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key);\n}\n\nmodule.exports = hashHas;\n", "var nativeCreate = require('./_nativeCreate');\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Sets the hash `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Hash\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the hash instance.\n */\nfunction hashSet(key, value) {\n var data = this.__data__;\n this.size += this.has(key) ? 0 : 1;\n data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;\n return this;\n}\n\nmodule.exports = hashSet;\n", "var hashClear = require('./_hashClear'),\n hashDelete = require('./_hashDelete'),\n hashGet = require('./_hashGet'),\n hashHas = require('./_hashHas'),\n hashSet = require('./_hashSet');\n\n/**\n * Creates a hash object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Hash(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `Hash`.\nHash.prototype.clear = hashClear;\nHash.prototype['delete'] = hashDelete;\nHash.prototype.get = hashGet;\nHash.prototype.has = hashHas;\nHash.prototype.set = hashSet;\n\nmodule.exports = Hash;\n", "/**\n * Removes all key-value entries from the list cache.\n *\n * @private\n * @name clear\n * @memberOf ListCache\n */\nfunction listCacheClear() {\n this.__data__ = [];\n this.size = 0;\n}\n\nmodule.exports = listCacheClear;\n", "/**\n * Performs a\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * comparison between two values to determine if they are equivalent.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.eq(object, object);\n * // => true\n *\n * _.eq(object, other);\n * // => false\n *\n * _.eq('a', 'a');\n * // => true\n *\n * _.eq('a', Object('a'));\n * // => false\n *\n * _.eq(NaN, NaN);\n * // => true\n */\nfunction eq(value, other) {\n return value === other || (value !== value && other !== other);\n}\n\nmodule.exports = eq;\n", "var eq = require('./eq');\n\n/**\n * Gets the index at which the `key` is found in `array` of key-value pairs.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} key The key to search for.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\nfunction assocIndexOf(array, key) {\n var length = array.length;\n while (length--) {\n if (eq(array[length][0], key)) {\n return length;\n }\n }\n return -1;\n}\n\nmodule.exports = assocIndexOf;\n", "var assocIndexOf = require('./_assocIndexOf');\n\n/** Used for built-in method references. */\nvar arrayProto = Array.prototype;\n\n/** Built-in value references. */\nvar splice = arrayProto.splice;\n\n/**\n * Removes `key` and its value from the list cache.\n *\n * @private\n * @name delete\n * @memberOf ListCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction listCacheDelete(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n return false;\n }\n var lastIndex = data.length - 1;\n if (index == lastIndex) {\n data.pop();\n } else {\n splice.call(data, index, 1);\n }\n --this.size;\n return true;\n}\n\nmodule.exports = listCacheDelete;\n", "var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Gets the list cache value for `key`.\n *\n * @private\n * @name get\n * @memberOf ListCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction listCacheGet(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n return index < 0 ? undefined : data[index][1];\n}\n\nmodule.exports = listCacheGet;\n", "var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Checks if a list cache value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf ListCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction listCacheHas(key) {\n return assocIndexOf(this.__data__, key) > -1;\n}\n\nmodule.exports = listCacheHas;\n", "var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Sets the list cache `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf ListCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the list cache instance.\n */\nfunction listCacheSet(key, value) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n ++this.size;\n data.push([key, value]);\n } else {\n data[index][1] = value;\n }\n return this;\n}\n\nmodule.exports = listCacheSet;\n", "var listCacheClear = require('./_listCacheClear'),\n listCacheDelete = require('./_listCacheDelete'),\n listCacheGet = require('./_listCacheGet'),\n listCacheHas = require('./_listCacheHas'),\n listCacheSet = require('./_listCacheSet');\n\n/**\n * Creates an list cache object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction ListCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `ListCache`.\nListCache.prototype.clear = listCacheClear;\nListCache.prototype['delete'] = listCacheDelete;\nListCache.prototype.get = listCacheGet;\nListCache.prototype.has = listCacheHas;\nListCache.prototype.set = listCacheSet;\n\nmodule.exports = ListCache;\n", "var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Map = getNative(root, 'Map');\n\nmodule.exports = Map;\n", "var Hash = require('./_Hash'),\n ListCache = require('./_ListCache'),\n Map = require('./_Map');\n\n/**\n * Removes all key-value entries from the map.\n *\n * @private\n * @name clear\n * @memberOf MapCache\n */\nfunction mapCacheClear() {\n this.size = 0;\n this.__data__ = {\n 'hash': new Hash,\n 'map': new (Map || ListCache),\n 'string': new Hash\n };\n}\n\nmodule.exports = mapCacheClear;\n", "/**\n * Checks if `value` is suitable for use as unique object key.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is suitable, else `false`.\n */\nfunction isKeyable(value) {\n var type = typeof value;\n return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')\n ? (value !== '__proto__')\n : (value === null);\n}\n\nmodule.exports = isKeyable;\n", "var isKeyable = require('./_isKeyable');\n\n/**\n * Gets the data for `map`.\n *\n * @private\n * @param {Object} map The map to query.\n * @param {string} key The reference key.\n * @returns {*} Returns the map data.\n */\nfunction getMapData(map, key) {\n var data = map.__data__;\n return isKeyable(key)\n ? data[typeof key == 'string' ? 'string' : 'hash']\n : data.map;\n}\n\nmodule.exports = getMapData;\n", "var getMapData = require('./_getMapData');\n\n/**\n * Removes `key` and its value from the map.\n *\n * @private\n * @name delete\n * @memberOf MapCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction mapCacheDelete(key) {\n var result = getMapData(this, key)['delete'](key);\n this.size -= result ? 1 : 0;\n return result;\n}\n\nmodule.exports = mapCacheDelete;\n", "var getMapData = require('./_getMapData');\n\n/**\n * Gets the map value for `key`.\n *\n * @private\n * @name get\n * @memberOf MapCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction mapCacheGet(key) {\n return getMapData(this, key).get(key);\n}\n\nmodule.exports = mapCacheGet;\n", "var getMapData = require('./_getMapData');\n\n/**\n * Checks if a map value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf MapCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction mapCacheHas(key) {\n return getMapData(this, key).has(key);\n}\n\nmodule.exports = mapCacheHas;\n", "var getMapData = require('./_getMapData');\n\n/**\n * Sets the map `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf MapCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the map cache instance.\n */\nfunction mapCacheSet(key, value) {\n var data = getMapData(this, key),\n size = data.size;\n\n data.set(key, value);\n this.size += data.size == size ? 0 : 1;\n return this;\n}\n\nmodule.exports = mapCacheSet;\n", "var mapCacheClear = require('./_mapCacheClear'),\n mapCacheDelete = require('./_mapCacheDelete'),\n mapCacheGet = require('./_mapCacheGet'),\n mapCacheHas = require('./_mapCacheHas'),\n mapCacheSet = require('./_mapCacheSet');\n\n/**\n * Creates a map cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction MapCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `MapCache`.\nMapCache.prototype.clear = mapCacheClear;\nMapCache.prototype['delete'] = mapCacheDelete;\nMapCache.prototype.get = mapCacheGet;\nMapCache.prototype.has = mapCacheHas;\nMapCache.prototype.set = mapCacheSet;\n\nmodule.exports = MapCache;\n", "var MapCache = require('./_MapCache');\n\n/** Error message constants. */\nvar FUNC_ERROR_TEXT = 'Expected a function';\n\n/**\n * Creates a function that memoizes the result of `func`. If `resolver` is\n * provided, it determines the cache key for storing the result based on the\n * arguments provided to the memoized function. By default, the first argument\n * provided to the memoized function is used as the map cache key. The `func`\n * is invoked with the `this` binding of the memoized function.\n *\n * **Note:** The cache is exposed as the `cache` property on the memoized\n * function. Its creation may be customized by replacing the `_.memoize.Cache`\n * constructor with one whose instances implement the\n * [`Map`](http://ecma-international.org/ecma-262/7.0/#sec-properties-of-the-map-prototype-object)\n * method interface of `clear`, `delete`, `get`, `has`, and `set`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to have its output memoized.\n * @param {Function} [resolver] The function to resolve the cache key.\n * @returns {Function} Returns the new memoized function.\n * @example\n *\n * var object = { 'a': 1, 'b': 2 };\n * var other = { 'c': 3, 'd': 4 };\n *\n * var values = _.memoize(_.values);\n * values(object);\n * // => [1, 2]\n *\n * values(other);\n * // => [3, 4]\n *\n * object.a = 2;\n * values(object);\n * // => [1, 2]\n *\n * // Modify the result cache.\n * values.cache.set(object, ['a', 'b']);\n * values(object);\n * // => ['a', 'b']\n *\n * // Replace `_.memoize.Cache`.\n * _.memoize.Cache = WeakMap;\n */\nfunction memoize(func, resolver) {\n if (typeof func != 'function' || (resolver != null && typeof resolver != 'function')) {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n var memoized = function() {\n var args = arguments,\n key = resolver ? resolver.apply(this, args) : args[0],\n cache = memoized.cache;\n\n if (cache.has(key)) {\n return cache.get(key);\n }\n var result = func.apply(this, args);\n memoized.cache = cache.set(key, result) || cache;\n return result;\n };\n memoized.cache = new (memoize.Cache || MapCache);\n return memoized;\n}\n\n// Expose `MapCache`.\nmemoize.Cache = MapCache;\n\nmodule.exports = memoize;\n", "var memoize = require('./memoize');\n\n/** Used as the maximum memoize cache size. */\nvar MAX_MEMOIZE_SIZE = 500;\n\n/**\n * A specialized version of `_.memoize` which clears the memoized function's\n * cache when it exceeds `MAX_MEMOIZE_SIZE`.\n *\n * @private\n * @param {Function} func The function to have its output memoized.\n * @returns {Function} Returns the new memoized function.\n */\nfunction memoizeCapped(func) {\n var result = memoize(func, function(key) {\n if (cache.size === MAX_MEMOIZE_SIZE) {\n cache.clear();\n }\n return key;\n });\n\n var cache = result.cache;\n return result;\n}\n\nmodule.exports = memoizeCapped;\n", "var memoizeCapped = require('./_memoizeCapped');\n\n/** Used to match property names within property paths. */\nvar rePropName = /[^.[\\]]+|\\[(?:(-?\\d+(?:\\.\\d+)?)|([\"'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2)\\]|(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|$))/g;\n\n/** Used to match backslashes in property paths. */\nvar reEscapeChar = /\\\\(\\\\)?/g;\n\n/**\n * Converts `string` to a property path array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the property path array.\n */\nvar stringToPath = memoizeCapped(function(string) {\n var result = [];\n if (string.charCodeAt(0) === 46 /* . */) {\n result.push('');\n }\n string.replace(rePropName, function(match, number, quote, subString) {\n result.push(quote ? subString.replace(reEscapeChar, '$1') : (number || match));\n });\n return result;\n});\n\nmodule.exports = stringToPath;\n", "/**\n * A specialized version of `_.map` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the new mapped array.\n */\nfunction arrayMap(array, iteratee) {\n var index = -1,\n length = array == null ? 0 : array.length,\n result = Array(length);\n\n while (++index < length) {\n result[index] = iteratee(array[index], index, array);\n }\n return result;\n}\n\nmodule.exports = arrayMap;\n", "var Symbol = require('./_Symbol'),\n arrayMap = require('./_arrayMap'),\n isArray = require('./isArray'),\n isSymbol = require('./isSymbol');\n\n/** Used as references for various `Number` constants. */\nvar INFINITY = 1 / 0;\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolToString = symbolProto ? symbolProto.toString : undefined;\n\n/**\n * The base implementation of `_.toString` which doesn't convert nullish\n * values to empty strings.\n *\n * @private\n * @param {*} value The value to process.\n * @returns {string} Returns the string.\n */\nfunction baseToString(value) {\n // Exit early for strings to avoid a performance hit in some environments.\n if (typeof value == 'string') {\n return value;\n }\n if (isArray(value)) {\n // Recursively convert values (susceptible to call stack limits).\n return arrayMap(value, baseToString) + '';\n }\n if (isSymbol(value)) {\n return symbolToString ? symbolToString.call(value) : '';\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n}\n\nmodule.exports = baseToString;\n", "var baseToString = require('./_baseToString');\n\n/**\n * Converts `value` to a string. An empty string is returned for `null`\n * and `undefined` values. The sign of `-0` is preserved.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n * @example\n *\n * _.toString(null);\n * // => ''\n *\n * _.toString(-0);\n * // => '-0'\n *\n * _.toString([1, 2, 3]);\n * // => '1,2,3'\n */\nfunction toString(value) {\n return value == null ? '' : baseToString(value);\n}\n\nmodule.exports = toString;\n", "var isArray = require('./isArray'),\n isKey = require('./_isKey'),\n stringToPath = require('./_stringToPath'),\n toString = require('./toString');\n\n/**\n * Casts `value` to a path array if it's not one.\n *\n * @private\n * @param {*} value The value to inspect.\n * @param {Object} [object] The object to query keys on.\n * @returns {Array} Returns the cast property path array.\n */\nfunction castPath(value, object) {\n if (isArray(value)) {\n return value;\n }\n return isKey(value, object) ? [value] : stringToPath(toString(value));\n}\n\nmodule.exports = castPath;\n", "var isSymbol = require('./isSymbol');\n\n/** Used as references for various `Number` constants. */\nvar INFINITY = 1 / 0;\n\n/**\n * Converts `value` to a string key if it's not a string or symbol.\n *\n * @private\n * @param {*} value The value to inspect.\n * @returns {string|symbol} Returns the key.\n */\nfunction toKey(value) {\n if (typeof value == 'string' || isSymbol(value)) {\n return value;\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n}\n\nmodule.exports = toKey;\n", "var castPath = require('./_castPath'),\n toKey = require('./_toKey');\n\n/**\n * The base implementation of `_.get` without support for default values.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @returns {*} Returns the resolved value.\n */\nfunction baseGet(object, path) {\n path = castPath(path, object);\n\n var index = 0,\n length = path.length;\n\n while (object != null && index < length) {\n object = object[toKey(path[index++])];\n }\n return (index && index == length) ? object : undefined;\n}\n\nmodule.exports = baseGet;\n", "var baseGet = require('./_baseGet');\n\n/**\n * Gets the value at `path` of `object`. If the resolved value is\n * `undefined`, the `defaultValue` is returned in its place.\n *\n * @static\n * @memberOf _\n * @since 3.7.0\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @param {*} [defaultValue] The value returned for `undefined` resolved values.\n * @returns {*} Returns the resolved value.\n * @example\n *\n * var object = { 'a': [{ 'b': { 'c': 3 } }] };\n *\n * _.get(object, 'a[0].b.c');\n * // => 3\n *\n * _.get(object, ['a', '0', 'b', 'c']);\n * // => 3\n *\n * _.get(object, 'a.b.c', 'default');\n * // => 'default'\n */\nfunction get(object, path, defaultValue) {\n var result = object == null ? undefined : baseGet(object, path);\n return result === undefined ? defaultValue : result;\n}\n\nmodule.exports = get;\n", "'use strict';\n\nmodule.exports = ({onlyFirst = false} = {}) => {\n\tconst pattern = [\n\t\t'[\\\\u001B\\\\u009B][[\\\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\\\d\\\\/#&.:=?%@~_]+)*|[a-zA-Z\\\\d]+(?:;[-a-zA-Z\\\\d\\\\/#&.:=?%@~_]*)*)?\\\\u0007)',\n\t\t'(?:(?:\\\\d{1,4}(?:;\\\\d{0,4})*)?[\\\\dA-PR-TZcf-ntqry=><~]))'\n\t].join('|');\n\n\treturn new RegExp(pattern, onlyFirst ? undefined : 'g');\n};\n", "'use strict';\nconst ansiRegex = require('ansi-regex');\n\nmodule.exports = string => typeof string === 'string' ? string.replace(ansiRegex(), '') : string;\n", "\"use strict\";function _createForOfIteratorHelper(o,allowArrayLike){var it=typeof Symbol!==\"undefined\"&&o[Symbol.iterator]||o[\"@@iterator\"];if(!it){if(Array.isArray(o)||(it=_unsupportedIterableToArray(o))||allowArrayLike&&o&&typeof o.length===\"number\"){if(it)o=it;var i=0;var F=function F(){};return{s:F,n:function n(){if(i>=o.length)return{done:true};return{done:false,value:o[i++]}},e:function e(_e2){throw _e2},f:F}}throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\")}var normalCompletion=true,didErr=false,err;return{s:function s(){it=it.call(o)},n:function n(){var step=it.next();normalCompletion=step.done;return step},e:function e(_e3){didErr=true;err=_e3},f:function f(){try{if(!normalCompletion&&it[\"return\"]!=null)it[\"return\"]()}finally{if(didErr)throw err}}}}function _defineProperty(obj,key,value){if(key in obj){Object.defineProperty(obj,key,{value:value,enumerable:true,configurable:true,writable:true})}else{obj[key]=value}return obj}function _slicedToArray(arr,i){return _arrayWithHoles(arr)||_iterableToArrayLimit(arr,i)||_unsupportedIterableToArray(arr,i)||_nonIterableRest()}function _nonIterableRest(){throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\")}function _unsupportedIterableToArray(o,minLen){if(!o)return;if(typeof o===\"string\")return _arrayLikeToArray(o,minLen);var n=Object.prototype.toString.call(o).slice(8,-1);if(n===\"Object\"&&o.constructor)n=o.constructor.name;if(n===\"Map\"||n===\"Set\")return Array.from(o);if(n===\"Arguments\"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return _arrayLikeToArray(o,minLen)}function _arrayLikeToArray(arr,len){if(len==null||len>arr.length)len=arr.length;for(var i=0,arr2=new Array(len);i -1 && value % 1 == 0 && value < length);\n}\n\nmodule.exports = isIndex;\n", "var assignValue = require('./_assignValue'),\n castPath = require('./_castPath'),\n isIndex = require('./_isIndex'),\n isObject = require('./isObject'),\n toKey = require('./_toKey');\n\n/**\n * The base implementation of `_.set`.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {Array|string} path The path of the property to set.\n * @param {*} value The value to set.\n * @param {Function} [customizer] The function to customize path creation.\n * @returns {Object} Returns `object`.\n */\nfunction baseSet(object, path, value, customizer) {\n if (!isObject(object)) {\n return object;\n }\n path = castPath(path, object);\n\n var index = -1,\n length = path.length,\n lastIndex = length - 1,\n nested = object;\n\n while (nested != null && ++index < length) {\n var key = toKey(path[index]),\n newValue = value;\n\n if (key === '__proto__' || key === 'constructor' || key === 'prototype') {\n return object;\n }\n\n if (index != lastIndex) {\n var objValue = nested[key];\n newValue = customizer ? customizer(objValue, key, nested) : undefined;\n if (newValue === undefined) {\n newValue = isObject(objValue)\n ? objValue\n : (isIndex(path[index + 1]) ? [] : {});\n }\n }\n assignValue(nested, key, newValue);\n nested = nested[key];\n }\n return object;\n}\n\nmodule.exports = baseSet;\n", "var baseGet = require('./_baseGet'),\n baseSet = require('./_baseSet'),\n castPath = require('./_castPath');\n\n/**\n * The base implementation of `_.pickBy` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The source object.\n * @param {string[]} paths The property paths to pick.\n * @param {Function} predicate The function invoked per property.\n * @returns {Object} Returns the new object.\n */\nfunction basePickBy(object, paths, predicate) {\n var index = -1,\n length = paths.length,\n result = {};\n\n while (++index < length) {\n var path = paths[index],\n value = baseGet(object, path);\n\n if (predicate(value, path)) {\n baseSet(result, castPath(path, object), value);\n }\n }\n return result;\n}\n\nmodule.exports = basePickBy;\n", "/**\n * The base implementation of `_.hasIn` without support for deep paths.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {Array|string} key The key to check.\n * @returns {boolean} Returns `true` if `key` exists, else `false`.\n */\nfunction baseHasIn(object, key) {\n return object != null && key in Object(object);\n}\n\nmodule.exports = baseHasIn;\n", "var baseGetTag = require('./_baseGetTag'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]';\n\n/**\n * The base implementation of `_.isArguments`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n */\nfunction baseIsArguments(value) {\n return isObjectLike(value) && baseGetTag(value) == argsTag;\n}\n\nmodule.exports = baseIsArguments;\n", "var baseIsArguments = require('./_baseIsArguments'),\n isObjectLike = require('./isObjectLike');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/**\n * Checks if `value` is likely an `arguments` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n * else `false`.\n * @example\n *\n * _.isArguments(function() { return arguments; }());\n * // => true\n *\n * _.isArguments([1, 2, 3]);\n * // => false\n */\nvar isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {\n return isObjectLike(value) && hasOwnProperty.call(value, 'callee') &&\n !propertyIsEnumerable.call(value, 'callee');\n};\n\nmodule.exports = isArguments;\n", "/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/**\n * Checks if `value` is a valid array-like length.\n *\n * **Note:** This method is loosely based on\n * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.\n * @example\n *\n * _.isLength(3);\n * // => true\n *\n * _.isLength(Number.MIN_VALUE);\n * // => false\n *\n * _.isLength(Infinity);\n * // => false\n *\n * _.isLength('3');\n * // => false\n */\nfunction isLength(value) {\n return typeof value == 'number' &&\n value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;\n}\n\nmodule.exports = isLength;\n", "var castPath = require('./_castPath'),\n isArguments = require('./isArguments'),\n isArray = require('./isArray'),\n isIndex = require('./_isIndex'),\n isLength = require('./isLength'),\n toKey = require('./_toKey');\n\n/**\n * Checks if `path` exists on `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @param {Function} hasFunc The function to check properties.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n */\nfunction hasPath(object, path, hasFunc) {\n path = castPath(path, object);\n\n var index = -1,\n length = path.length,\n result = false;\n\n while (++index < length) {\n var key = toKey(path[index]);\n if (!(result = object != null && hasFunc(object, key))) {\n break;\n }\n object = object[key];\n }\n if (result || ++index != length) {\n return result;\n }\n length = object == null ? 0 : object.length;\n return !!length && isLength(length) && isIndex(key, length) &&\n (isArray(object) || isArguments(object));\n}\n\nmodule.exports = hasPath;\n", "var baseHasIn = require('./_baseHasIn'),\n hasPath = require('./_hasPath');\n\n/**\n * Checks if `path` is a direct or inherited property of `object`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n * @example\n *\n * var object = _.create({ 'a': _.create({ 'b': 2 }) });\n *\n * _.hasIn(object, 'a');\n * // => true\n *\n * _.hasIn(object, 'a.b');\n * // => true\n *\n * _.hasIn(object, ['a', 'b']);\n * // => true\n *\n * _.hasIn(object, 'b');\n * // => false\n */\nfunction hasIn(object, path) {\n return object != null && hasPath(object, path, baseHasIn);\n}\n\nmodule.exports = hasIn;\n", "var basePickBy = require('./_basePickBy'),\n hasIn = require('./hasIn');\n\n/**\n * The base implementation of `_.pick` without support for individual\n * property identifiers.\n *\n * @private\n * @param {Object} object The source object.\n * @param {string[]} paths The property paths to pick.\n * @returns {Object} Returns the new object.\n */\nfunction basePick(object, paths) {\n return basePickBy(object, paths, function(value, path) {\n return hasIn(object, path);\n });\n}\n\nmodule.exports = basePick;\n", "/**\n * Appends the elements of `values` to `array`.\n *\n * @private\n * @param {Array} array The array to modify.\n * @param {Array} values The values to append.\n * @returns {Array} Returns `array`.\n */\nfunction arrayPush(array, values) {\n var index = -1,\n length = values.length,\n offset = array.length;\n\n while (++index < length) {\n array[offset + index] = values[index];\n }\n return array;\n}\n\nmodule.exports = arrayPush;\n", "var Symbol = require('./_Symbol'),\n isArguments = require('./isArguments'),\n isArray = require('./isArray');\n\n/** Built-in value references. */\nvar spreadableSymbol = Symbol ? Symbol.isConcatSpreadable : undefined;\n\n/**\n * Checks if `value` is a flattenable `arguments` object or array.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is flattenable, else `false`.\n */\nfunction isFlattenable(value) {\n return isArray(value) || isArguments(value) ||\n !!(spreadableSymbol && value && value[spreadableSymbol]);\n}\n\nmodule.exports = isFlattenable;\n", "var arrayPush = require('./_arrayPush'),\n isFlattenable = require('./_isFlattenable');\n\n/**\n * The base implementation of `_.flatten` with support for restricting flattening.\n *\n * @private\n * @param {Array} array The array to flatten.\n * @param {number} depth The maximum recursion depth.\n * @param {boolean} [predicate=isFlattenable] The function invoked per iteration.\n * @param {boolean} [isStrict] Restrict to values that pass `predicate` checks.\n * @param {Array} [result=[]] The initial result value.\n * @returns {Array} Returns the new flattened array.\n */\nfunction baseFlatten(array, depth, predicate, isStrict, result) {\n var index = -1,\n length = array.length;\n\n predicate || (predicate = isFlattenable);\n result || (result = []);\n\n while (++index < length) {\n var value = array[index];\n if (depth > 0 && predicate(value)) {\n if (depth > 1) {\n // Recursively flatten arrays (susceptible to call stack limits).\n baseFlatten(value, depth - 1, predicate, isStrict, result);\n } else {\n arrayPush(result, value);\n }\n } else if (!isStrict) {\n result[result.length] = value;\n }\n }\n return result;\n}\n\nmodule.exports = baseFlatten;\n", "var baseFlatten = require('./_baseFlatten');\n\n/**\n * Flattens `array` a single level deep.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Array\n * @param {Array} array The array to flatten.\n * @returns {Array} Returns the new flattened array.\n * @example\n *\n * _.flatten([1, [2, [3, [4]], 5]]);\n * // => [1, 2, [3, [4]], 5]\n */\nfunction flatten(array) {\n var length = array == null ? 0 : array.length;\n return length ? baseFlatten(array, 1) : [];\n}\n\nmodule.exports = flatten;\n", "/**\n * A faster alternative to `Function#apply`, this function invokes `func`\n * with the `this` binding of `thisArg` and the arguments of `args`.\n *\n * @private\n * @param {Function} func The function to invoke.\n * @param {*} thisArg The `this` binding of `func`.\n * @param {Array} args The arguments to invoke `func` with.\n * @returns {*} Returns the result of `func`.\n */\nfunction apply(func, thisArg, args) {\n switch (args.length) {\n case 0: return func.call(thisArg);\n case 1: return func.call(thisArg, args[0]);\n case 2: return func.call(thisArg, args[0], args[1]);\n case 3: return func.call(thisArg, args[0], args[1], args[2]);\n }\n return func.apply(thisArg, args);\n}\n\nmodule.exports = apply;\n", "var apply = require('./_apply');\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeMax = Math.max;\n\n/**\n * A specialized version of `baseRest` which transforms the rest array.\n *\n * @private\n * @param {Function} func The function to apply a rest parameter to.\n * @param {number} [start=func.length-1] The start position of the rest parameter.\n * @param {Function} transform The rest array transform.\n * @returns {Function} Returns the new function.\n */\nfunction overRest(func, start, transform) {\n start = nativeMax(start === undefined ? (func.length - 1) : start, 0);\n return function() {\n var args = arguments,\n index = -1,\n length = nativeMax(args.length - start, 0),\n array = Array(length);\n\n while (++index < length) {\n array[index] = args[start + index];\n }\n index = -1;\n var otherArgs = Array(start + 1);\n while (++index < start) {\n otherArgs[index] = args[index];\n }\n otherArgs[start] = transform(array);\n return apply(func, this, otherArgs);\n };\n}\n\nmodule.exports = overRest;\n", "/**\n * Creates a function that returns `value`.\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Util\n * @param {*} value The value to return from the new function.\n * @returns {Function} Returns the new constant function.\n * @example\n *\n * var objects = _.times(2, _.constant({ 'a': 1 }));\n *\n * console.log(objects);\n * // => [{ 'a': 1 }, { 'a': 1 }]\n *\n * console.log(objects[0] === objects[1]);\n * // => true\n */\nfunction constant(value) {\n return function() {\n return value;\n };\n}\n\nmodule.exports = constant;\n", "/**\n * This method returns the first argument it receives.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Util\n * @param {*} value Any value.\n * @returns {*} Returns `value`.\n * @example\n *\n * var object = { 'a': 1 };\n *\n * console.log(_.identity(object) === object);\n * // => true\n */\nfunction identity(value) {\n return value;\n}\n\nmodule.exports = identity;\n", "var constant = require('./constant'),\n defineProperty = require('./_defineProperty'),\n identity = require('./identity');\n\n/**\n * The base implementation of `setToString` without support for hot loop shorting.\n *\n * @private\n * @param {Function} func The function to modify.\n * @param {Function} string The `toString` result.\n * @returns {Function} Returns `func`.\n */\nvar baseSetToString = !defineProperty ? identity : function(func, string) {\n return defineProperty(func, 'toString', {\n 'configurable': true,\n 'enumerable': false,\n 'value': constant(string),\n 'writable': true\n });\n};\n\nmodule.exports = baseSetToString;\n", "/** Used to detect hot functions by number of calls within a span of milliseconds. */\nvar HOT_COUNT = 800,\n HOT_SPAN = 16;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeNow = Date.now;\n\n/**\n * Creates a function that'll short out and invoke `identity` instead\n * of `func` when it's called `HOT_COUNT` or more times in `HOT_SPAN`\n * milliseconds.\n *\n * @private\n * @param {Function} func The function to restrict.\n * @returns {Function} Returns the new shortable function.\n */\nfunction shortOut(func) {\n var count = 0,\n lastCalled = 0;\n\n return function() {\n var stamp = nativeNow(),\n remaining = HOT_SPAN - (stamp - lastCalled);\n\n lastCalled = stamp;\n if (remaining > 0) {\n if (++count >= HOT_COUNT) {\n return arguments[0];\n }\n } else {\n count = 0;\n }\n return func.apply(undefined, arguments);\n };\n}\n\nmodule.exports = shortOut;\n", "var baseSetToString = require('./_baseSetToString'),\n shortOut = require('./_shortOut');\n\n/**\n * Sets the `toString` method of `func` to return `string`.\n *\n * @private\n * @param {Function} func The function to modify.\n * @param {Function} string The `toString` result.\n * @returns {Function} Returns `func`.\n */\nvar setToString = shortOut(baseSetToString);\n\nmodule.exports = setToString;\n", "var flatten = require('./flatten'),\n overRest = require('./_overRest'),\n setToString = require('./_setToString');\n\n/**\n * A specialized version of `baseRest` which flattens the rest array.\n *\n * @private\n * @param {Function} func The function to apply a rest parameter to.\n * @returns {Function} Returns the new function.\n */\nfunction flatRest(func) {\n return setToString(overRest(func, undefined, flatten), func + '');\n}\n\nmodule.exports = flatRest;\n", "var basePick = require('./_basePick'),\n flatRest = require('./_flatRest');\n\n/**\n * Creates an object composed of the picked `object` properties.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The source object.\n * @param {...(string|string[])} [paths] The property paths to pick.\n * @returns {Object} Returns the new object.\n * @example\n *\n * var object = { 'a': 1, 'b': '2', 'c': 3 };\n *\n * _.pick(object, ['a', 'c']);\n * // => { 'a': 1, 'c': 3 }\n */\nvar pick = flatRest(function(object, paths) {\n return object == null ? {} : basePick(object, paths);\n});\n\nmodule.exports = pick;\n", "/**\n * Checks if `value` is `null` or `undefined`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is nullish, else `false`.\n * @example\n *\n * _.isNil(null);\n * // => true\n *\n * _.isNil(void 0);\n * // => true\n *\n * _.isNil(NaN);\n * // => false\n */\nfunction isNil(value) {\n return value == null;\n}\n\nmodule.exports = isNil;\n", "'use strict';\n\nexports.isInteger = num => {\n if (typeof num === 'number') {\n return Number.isInteger(num);\n }\n if (typeof num === 'string' && num.trim() !== '') {\n return Number.isInteger(Number(num));\n }\n return false;\n};\n\n/**\n * Find a node of the given type\n */\n\nexports.find = (node, type) => node.nodes.find(node => node.type === type);\n\n/**\n * Find a node of the given type\n */\n\nexports.exceedsLimit = (min, max, step = 1, limit) => {\n if (limit === false) return false;\n if (!exports.isInteger(min) || !exports.isInteger(max)) return false;\n return ((Number(max) - Number(min)) / Number(step)) >= limit;\n};\n\n/**\n * Escape the given node with '\\\\' before node.value\n */\n\nexports.escapeNode = (block, n = 0, type) => {\n let node = block.nodes[n];\n if (!node) return;\n\n if ((type && node.type === type) || node.type === 'open' || node.type === 'close') {\n if (node.escaped !== true) {\n node.value = '\\\\' + node.value;\n node.escaped = true;\n }\n }\n};\n\n/**\n * Returns true if the given brace node should be enclosed in literal braces\n */\n\nexports.encloseBrace = node => {\n if (node.type !== 'brace') return false;\n if ((node.commas >> 0 + node.ranges >> 0) === 0) {\n node.invalid = true;\n return true;\n }\n return false;\n};\n\n/**\n * Returns true if a brace node is invalid.\n */\n\nexports.isInvalidBrace = block => {\n if (block.type !== 'brace') return false;\n if (block.invalid === true || block.dollar) return true;\n if ((block.commas >> 0 + block.ranges >> 0) === 0) {\n block.invalid = true;\n return true;\n }\n if (block.open !== true || block.close !== true) {\n block.invalid = true;\n return true;\n }\n return false;\n};\n\n/**\n * Returns true if a node is an open or close node\n */\n\nexports.isOpenOrClose = node => {\n if (node.type === 'open' || node.type === 'close') {\n return true;\n }\n return node.open === true || node.close === true;\n};\n\n/**\n * Reduce an array of text nodes.\n */\n\nexports.reduce = nodes => nodes.reduce((acc, node) => {\n if (node.type === 'text') acc.push(node.value);\n if (node.type === 'range') node.type = 'text';\n return acc;\n}, []);\n\n/**\n * Flatten an array\n */\n\nexports.flatten = (...args) => {\n const result = [];\n const flat = arr => {\n for (let i = 0; i < arr.length; i++) {\n let ele = arr[i];\n Array.isArray(ele) ? flat(ele, result) : ele !== void 0 && result.push(ele);\n }\n return result;\n };\n flat(args);\n return result;\n};\n", "'use strict';\n\nconst utils = require('./utils');\n\nmodule.exports = (ast, options = {}) => {\n let stringify = (node, parent = {}) => {\n let invalidBlock = options.escapeInvalid && utils.isInvalidBrace(parent);\n let invalidNode = node.invalid === true && options.escapeInvalid === true;\n let output = '';\n\n if (node.value) {\n if ((invalidBlock || invalidNode) && utils.isOpenOrClose(node)) {\n return '\\\\' + node.value;\n }\n return node.value;\n }\n\n if (node.value) {\n return node.value;\n }\n\n if (node.nodes) {\n for (let child of node.nodes) {\n output += stringify(child);\n }\n }\n return output;\n };\n\n return stringify(ast);\n};\n\n", "/*!\n * is-number \n *\n * Copyright (c) 2014-present, Jon Schlinkert.\n * Released under the MIT License.\n */\n\n'use strict';\n\nmodule.exports = function(num) {\n if (typeof num === 'number') {\n return num - num === 0;\n }\n if (typeof num === 'string' && num.trim() !== '') {\n return Number.isFinite ? Number.isFinite(+num) : isFinite(+num);\n }\n return false;\n};\n", "/*!\n * to-regex-range \n *\n * Copyright (c) 2015-present, Jon Schlinkert.\n * Released under the MIT License.\n */\n\n'use strict';\n\nconst isNumber = require('is-number');\n\nconst toRegexRange = (min, max, options) => {\n if (isNumber(min) === false) {\n throw new TypeError('toRegexRange: expected the first argument to be a number');\n }\n\n if (max === void 0 || min === max) {\n return String(min);\n }\n\n if (isNumber(max) === false) {\n throw new TypeError('toRegexRange: expected the second argument to be a number.');\n }\n\n let opts = { relaxZeros: true, ...options };\n if (typeof opts.strictZeros === 'boolean') {\n opts.relaxZeros = opts.strictZeros === false;\n }\n\n let relax = String(opts.relaxZeros);\n let shorthand = String(opts.shorthand);\n let capture = String(opts.capture);\n let wrap = String(opts.wrap);\n let cacheKey = min + ':' + max + '=' + relax + shorthand + capture + wrap;\n\n if (toRegexRange.cache.hasOwnProperty(cacheKey)) {\n return toRegexRange.cache[cacheKey].result;\n }\n\n let a = Math.min(min, max);\n let b = Math.max(min, max);\n\n if (Math.abs(a - b) === 1) {\n let result = min + '|' + max;\n if (opts.capture) {\n return `(${result})`;\n }\n if (opts.wrap === false) {\n return result;\n }\n return `(?:${result})`;\n }\n\n let isPadded = hasPadding(min) || hasPadding(max);\n let state = { min, max, a, b };\n let positives = [];\n let negatives = [];\n\n if (isPadded) {\n state.isPadded = isPadded;\n state.maxLen = String(state.max).length;\n }\n\n if (a < 0) {\n let newMin = b < 0 ? Math.abs(b) : 1;\n negatives = splitToPatterns(newMin, Math.abs(a), state, opts);\n a = state.a = 0;\n }\n\n if (b >= 0) {\n positives = splitToPatterns(a, b, state, opts);\n }\n\n state.negatives = negatives;\n state.positives = positives;\n state.result = collatePatterns(negatives, positives, opts);\n\n if (opts.capture === true) {\n state.result = `(${state.result})`;\n } else if (opts.wrap !== false && (positives.length + negatives.length) > 1) {\n state.result = `(?:${state.result})`;\n }\n\n toRegexRange.cache[cacheKey] = state;\n return state.result;\n};\n\nfunction collatePatterns(neg, pos, options) {\n let onlyNegative = filterPatterns(neg, pos, '-', false, options) || [];\n let onlyPositive = filterPatterns(pos, neg, '', false, options) || [];\n let intersected = filterPatterns(neg, pos, '-?', true, options) || [];\n let subpatterns = onlyNegative.concat(intersected).concat(onlyPositive);\n return subpatterns.join('|');\n}\n\nfunction splitToRanges(min, max) {\n let nines = 1;\n let zeros = 1;\n\n let stop = countNines(min, nines);\n let stops = new Set([max]);\n\n while (min <= stop && stop <= max) {\n stops.add(stop);\n nines += 1;\n stop = countNines(min, nines);\n }\n\n stop = countZeros(max + 1, zeros) - 1;\n\n while (min < stop && stop <= max) {\n stops.add(stop);\n zeros += 1;\n stop = countZeros(max + 1, zeros) - 1;\n }\n\n stops = [...stops];\n stops.sort(compare);\n return stops;\n}\n\n/**\n * Convert a range to a regex pattern\n * @param {Number} `start`\n * @param {Number} `stop`\n * @return {String}\n */\n\nfunction rangeToPattern(start, stop, options) {\n if (start === stop) {\n return { pattern: start, count: [], digits: 0 };\n }\n\n let zipped = zip(start, stop);\n let digits = zipped.length;\n let pattern = '';\n let count = 0;\n\n for (let i = 0; i < digits; i++) {\n let [startDigit, stopDigit] = zipped[i];\n\n if (startDigit === stopDigit) {\n pattern += startDigit;\n\n } else if (startDigit !== '0' || stopDigit !== '9') {\n pattern += toCharacterClass(startDigit, stopDigit, options);\n\n } else {\n count++;\n }\n }\n\n if (count) {\n pattern += options.shorthand === true ? '\\\\d' : '[0-9]';\n }\n\n return { pattern, count: [count], digits };\n}\n\nfunction splitToPatterns(min, max, tok, options) {\n let ranges = splitToRanges(min, max);\n let tokens = [];\n let start = min;\n let prev;\n\n for (let i = 0; i < ranges.length; i++) {\n let max = ranges[i];\n let obj = rangeToPattern(String(start), String(max), options);\n let zeros = '';\n\n if (!tok.isPadded && prev && prev.pattern === obj.pattern) {\n if (prev.count.length > 1) {\n prev.count.pop();\n }\n\n prev.count.push(obj.count[0]);\n prev.string = prev.pattern + toQuantifier(prev.count);\n start = max + 1;\n continue;\n }\n\n if (tok.isPadded) {\n zeros = padZeros(max, tok, options);\n }\n\n obj.string = zeros + obj.pattern + toQuantifier(obj.count);\n tokens.push(obj);\n start = max + 1;\n prev = obj;\n }\n\n return tokens;\n}\n\nfunction filterPatterns(arr, comparison, prefix, intersection, options) {\n let result = [];\n\n for (let ele of arr) {\n let { string } = ele;\n\n // only push if _both_ are negative...\n if (!intersection && !contains(comparison, 'string', string)) {\n result.push(prefix + string);\n }\n\n // or _both_ are positive\n if (intersection && contains(comparison, 'string', string)) {\n result.push(prefix + string);\n }\n }\n return result;\n}\n\n/**\n * Zip strings\n */\n\nfunction zip(a, b) {\n let arr = [];\n for (let i = 0; i < a.length; i++) arr.push([a[i], b[i]]);\n return arr;\n}\n\nfunction compare(a, b) {\n return a > b ? 1 : b > a ? -1 : 0;\n}\n\nfunction contains(arr, key, val) {\n return arr.some(ele => ele[key] === val);\n}\n\nfunction countNines(min, len) {\n return Number(String(min).slice(0, -len) + '9'.repeat(len));\n}\n\nfunction countZeros(integer, zeros) {\n return integer - (integer % Math.pow(10, zeros));\n}\n\nfunction toQuantifier(digits) {\n let [start = 0, stop = ''] = digits;\n if (stop || start > 1) {\n return `{${start + (stop ? ',' + stop : '')}}`;\n }\n return '';\n}\n\nfunction toCharacterClass(a, b, options) {\n return `[${a}${(b - a === 1) ? '' : '-'}${b}]`;\n}\n\nfunction hasPadding(str) {\n return /^-?(0+)\\d/.test(str);\n}\n\nfunction padZeros(value, tok, options) {\n if (!tok.isPadded) {\n return value;\n }\n\n let diff = Math.abs(tok.maxLen - String(value).length);\n let relax = options.relaxZeros !== false;\n\n switch (diff) {\n case 0:\n return '';\n case 1:\n return relax ? '0?' : '0';\n case 2:\n return relax ? '0{0,2}' : '00';\n default: {\n return relax ? `0{0,${diff}}` : `0{${diff}}`;\n }\n }\n}\n\n/**\n * Cache\n */\n\ntoRegexRange.cache = {};\ntoRegexRange.clearCache = () => (toRegexRange.cache = {});\n\n/**\n * Expose `toRegexRange`\n */\n\nmodule.exports = toRegexRange;\n", "/*!\n * fill-range \n *\n * Copyright (c) 2014-present, Jon Schlinkert.\n * Licensed under the MIT License.\n */\n\n'use strict';\n\nconst util = require('util');\nconst toRegexRange = require('to-regex-range');\n\nconst isObject = val => val !== null && typeof val === 'object' && !Array.isArray(val);\n\nconst transform = toNumber => {\n return value => toNumber === true ? Number(value) : String(value);\n};\n\nconst isValidValue = value => {\n return typeof value === 'number' || (typeof value === 'string' && value !== '');\n};\n\nconst isNumber = num => Number.isInteger(+num);\n\nconst zeros = input => {\n let value = `${input}`;\n let index = -1;\n if (value[0] === '-') value = value.slice(1);\n if (value === '0') return false;\n while (value[++index] === '0');\n return index > 0;\n};\n\nconst stringify = (start, end, options) => {\n if (typeof start === 'string' || typeof end === 'string') {\n return true;\n }\n return options.stringify === true;\n};\n\nconst pad = (input, maxLength, toNumber) => {\n if (maxLength > 0) {\n let dash = input[0] === '-' ? '-' : '';\n if (dash) input = input.slice(1);\n input = (dash + input.padStart(dash ? maxLength - 1 : maxLength, '0'));\n }\n if (toNumber === false) {\n return String(input);\n }\n return input;\n};\n\nconst toMaxLen = (input, maxLength) => {\n let negative = input[0] === '-' ? '-' : '';\n if (negative) {\n input = input.slice(1);\n maxLength--;\n }\n while (input.length < maxLength) input = '0' + input;\n return negative ? ('-' + input) : input;\n};\n\nconst toSequence = (parts, options) => {\n parts.negatives.sort((a, b) => a < b ? -1 : a > b ? 1 : 0);\n parts.positives.sort((a, b) => a < b ? -1 : a > b ? 1 : 0);\n\n let prefix = options.capture ? '' : '?:';\n let positives = '';\n let negatives = '';\n let result;\n\n if (parts.positives.length) {\n positives = parts.positives.join('|');\n }\n\n if (parts.negatives.length) {\n negatives = `-(${prefix}${parts.negatives.join('|')})`;\n }\n\n if (positives && negatives) {\n result = `${positives}|${negatives}`;\n } else {\n result = positives || negatives;\n }\n\n if (options.wrap) {\n return `(${prefix}${result})`;\n }\n\n return result;\n};\n\nconst toRange = (a, b, isNumbers, options) => {\n if (isNumbers) {\n return toRegexRange(a, b, { wrap: false, ...options });\n }\n\n let start = String.fromCharCode(a);\n if (a === b) return start;\n\n let stop = String.fromCharCode(b);\n return `[${start}-${stop}]`;\n};\n\nconst toRegex = (start, end, options) => {\n if (Array.isArray(start)) {\n let wrap = options.wrap === true;\n let prefix = options.capture ? '' : '?:';\n return wrap ? `(${prefix}${start.join('|')})` : start.join('|');\n }\n return toRegexRange(start, end, options);\n};\n\nconst rangeError = (...args) => {\n return new RangeError('Invalid range arguments: ' + util.inspect(...args));\n};\n\nconst invalidRange = (start, end, options) => {\n if (options.strictRanges === true) throw rangeError([start, end]);\n return [];\n};\n\nconst invalidStep = (step, options) => {\n if (options.strictRanges === true) {\n throw new TypeError(`Expected step \"${step}\" to be a number`);\n }\n return [];\n};\n\nconst fillNumbers = (start, end, step = 1, options = {}) => {\n let a = Number(start);\n let b = Number(end);\n\n if (!Number.isInteger(a) || !Number.isInteger(b)) {\n if (options.strictRanges === true) throw rangeError([start, end]);\n return [];\n }\n\n // fix negative zero\n if (a === 0) a = 0;\n if (b === 0) b = 0;\n\n let descending = a > b;\n let startString = String(start);\n let endString = String(end);\n let stepString = String(step);\n step = Math.max(Math.abs(step), 1);\n\n let padded = zeros(startString) || zeros(endString) || zeros(stepString);\n let maxLen = padded ? Math.max(startString.length, endString.length, stepString.length) : 0;\n let toNumber = padded === false && stringify(start, end, options) === false;\n let format = options.transform || transform(toNumber);\n\n if (options.toRegex && step === 1) {\n return toRange(toMaxLen(start, maxLen), toMaxLen(end, maxLen), true, options);\n }\n\n let parts = { negatives: [], positives: [] };\n let push = num => parts[num < 0 ? 'negatives' : 'positives'].push(Math.abs(num));\n let range = [];\n let index = 0;\n\n while (descending ? a >= b : a <= b) {\n if (options.toRegex === true && step > 1) {\n push(a);\n } else {\n range.push(pad(format(a, index), maxLen, toNumber));\n }\n a = descending ? a - step : a + step;\n index++;\n }\n\n if (options.toRegex === true) {\n return step > 1\n ? toSequence(parts, options)\n : toRegex(range, null, { wrap: false, ...options });\n }\n\n return range;\n};\n\nconst fillLetters = (start, end, step = 1, options = {}) => {\n if ((!isNumber(start) && start.length > 1) || (!isNumber(end) && end.length > 1)) {\n return invalidRange(start, end, options);\n }\n\n\n let format = options.transform || (val => String.fromCharCode(val));\n let a = `${start}`.charCodeAt(0);\n let b = `${end}`.charCodeAt(0);\n\n let descending = a > b;\n let min = Math.min(a, b);\n let max = Math.max(a, b);\n\n if (options.toRegex && step === 1) {\n return toRange(min, max, false, options);\n }\n\n let range = [];\n let index = 0;\n\n while (descending ? a >= b : a <= b) {\n range.push(format(a, index));\n a = descending ? a - step : a + step;\n index++;\n }\n\n if (options.toRegex === true) {\n return toRegex(range, null, { wrap: false, options });\n }\n\n return range;\n};\n\nconst fill = (start, end, step, options = {}) => {\n if (end == null && isValidValue(start)) {\n return [start];\n }\n\n if (!isValidValue(start) || !isValidValue(end)) {\n return invalidRange(start, end, options);\n }\n\n if (typeof step === 'function') {\n return fill(start, end, 1, { transform: step });\n }\n\n if (isObject(step)) {\n return fill(start, end, 0, step);\n }\n\n let opts = { ...options };\n if (opts.capture === true) opts.wrap = true;\n step = step || opts.step || 1;\n\n if (!isNumber(step)) {\n if (step != null && !isObject(step)) return invalidStep(step, opts);\n return fill(start, end, 1, step);\n }\n\n if (isNumber(start) && isNumber(end)) {\n return fillNumbers(start, end, step, opts);\n }\n\n return fillLetters(start, end, Math.max(Math.abs(step), 1), opts);\n};\n\nmodule.exports = fill;\n", "'use strict';\n\nconst fill = require('fill-range');\nconst utils = require('./utils');\n\nconst compile = (ast, options = {}) => {\n let walk = (node, parent = {}) => {\n let invalidBlock = utils.isInvalidBrace(parent);\n let invalidNode = node.invalid === true && options.escapeInvalid === true;\n let invalid = invalidBlock === true || invalidNode === true;\n let prefix = options.escapeInvalid === true ? '\\\\' : '';\n let output = '';\n\n if (node.isOpen === true) {\n return prefix + node.value;\n }\n if (node.isClose === true) {\n return prefix + node.value;\n }\n\n if (node.type === 'open') {\n return invalid ? (prefix + node.value) : '(';\n }\n\n if (node.type === 'close') {\n return invalid ? (prefix + node.value) : ')';\n }\n\n if (node.type === 'comma') {\n return node.prev.type === 'comma' ? '' : (invalid ? node.value : '|');\n }\n\n if (node.value) {\n return node.value;\n }\n\n if (node.nodes && node.ranges > 0) {\n let args = utils.reduce(node.nodes);\n let range = fill(...args, { ...options, wrap: false, toRegex: true });\n\n if (range.length !== 0) {\n return args.length > 1 && range.length > 1 ? `(${range})` : range;\n }\n }\n\n if (node.nodes) {\n for (let child of node.nodes) {\n output += walk(child, node);\n }\n }\n return output;\n };\n\n return walk(ast);\n};\n\nmodule.exports = compile;\n", "'use strict';\n\nconst fill = require('fill-range');\nconst stringify = require('./stringify');\nconst utils = require('./utils');\n\nconst append = (queue = '', stash = '', enclose = false) => {\n let result = [];\n\n queue = [].concat(queue);\n stash = [].concat(stash);\n\n if (!stash.length) return queue;\n if (!queue.length) {\n return enclose ? utils.flatten(stash).map(ele => `{${ele}}`) : stash;\n }\n\n for (let item of queue) {\n if (Array.isArray(item)) {\n for (let value of item) {\n result.push(append(value, stash, enclose));\n }\n } else {\n for (let ele of stash) {\n if (enclose === true && typeof ele === 'string') ele = `{${ele}}`;\n result.push(Array.isArray(ele) ? append(item, ele, enclose) : (item + ele));\n }\n }\n }\n return utils.flatten(result);\n};\n\nconst expand = (ast, options = {}) => {\n let rangeLimit = options.rangeLimit === void 0 ? 1000 : options.rangeLimit;\n\n let walk = (node, parent = {}) => {\n node.queue = [];\n\n let p = parent;\n let q = parent.queue;\n\n while (p.type !== 'brace' && p.type !== 'root' && p.parent) {\n p = p.parent;\n q = p.queue;\n }\n\n if (node.invalid || node.dollar) {\n q.push(append(q.pop(), stringify(node, options)));\n return;\n }\n\n if (node.type === 'brace' && node.invalid !== true && node.nodes.length === 2) {\n q.push(append(q.pop(), ['{}']));\n return;\n }\n\n if (node.nodes && node.ranges > 0) {\n let args = utils.reduce(node.nodes);\n\n if (utils.exceedsLimit(...args, options.step, rangeLimit)) {\n throw new RangeError('expanded array length exceeds range limit. Use options.rangeLimit to increase or disable the limit.');\n }\n\n let range = fill(...args, options);\n if (range.length === 0) {\n range = stringify(node, options);\n }\n\n q.push(append(q.pop(), range));\n node.nodes = [];\n return;\n }\n\n let enclose = utils.encloseBrace(node);\n let queue = node.queue;\n let block = node;\n\n while (block.type !== 'brace' && block.type !== 'root' && block.parent) {\n block = block.parent;\n queue = block.queue;\n }\n\n for (let i = 0; i < node.nodes.length; i++) {\n let child = node.nodes[i];\n\n if (child.type === 'comma' && node.type === 'brace') {\n if (i === 1) queue.push('');\n queue.push('');\n continue;\n }\n\n if (child.type === 'close') {\n q.push(append(q.pop(), queue, enclose));\n continue;\n }\n\n if (child.value && child.type !== 'open') {\n queue.push(append(queue.pop(), child.value));\n continue;\n }\n\n if (child.nodes) {\n walk(child, node);\n }\n }\n\n return queue;\n };\n\n return utils.flatten(walk(ast));\n};\n\nmodule.exports = expand;\n", "'use strict';\n\nmodule.exports = {\n MAX_LENGTH: 1024 * 64,\n\n // Digits\n CHAR_0: '0', /* 0 */\n CHAR_9: '9', /* 9 */\n\n // Alphabet chars.\n CHAR_UPPERCASE_A: 'A', /* A */\n CHAR_LOWERCASE_A: 'a', /* a */\n CHAR_UPPERCASE_Z: 'Z', /* Z */\n CHAR_LOWERCASE_Z: 'z', /* z */\n\n CHAR_LEFT_PARENTHESES: '(', /* ( */\n CHAR_RIGHT_PARENTHESES: ')', /* ) */\n\n CHAR_ASTERISK: '*', /* * */\n\n // Non-alphabetic chars.\n CHAR_AMPERSAND: '&', /* & */\n CHAR_AT: '@', /* @ */\n CHAR_BACKSLASH: '\\\\', /* \\ */\n CHAR_BACKTICK: '`', /* ` */\n CHAR_CARRIAGE_RETURN: '\\r', /* \\r */\n CHAR_CIRCUMFLEX_ACCENT: '^', /* ^ */\n CHAR_COLON: ':', /* : */\n CHAR_COMMA: ',', /* , */\n CHAR_DOLLAR: '$', /* . */\n CHAR_DOT: '.', /* . */\n CHAR_DOUBLE_QUOTE: '\"', /* \" */\n CHAR_EQUAL: '=', /* = */\n CHAR_EXCLAMATION_MARK: '!', /* ! */\n CHAR_FORM_FEED: '\\f', /* \\f */\n CHAR_FORWARD_SLASH: '/', /* / */\n CHAR_HASH: '#', /* # */\n CHAR_HYPHEN_MINUS: '-', /* - */\n CHAR_LEFT_ANGLE_BRACKET: '<', /* < */\n CHAR_LEFT_CURLY_BRACE: '{', /* { */\n CHAR_LEFT_SQUARE_BRACKET: '[', /* [ */\n CHAR_LINE_FEED: '\\n', /* \\n */\n CHAR_NO_BREAK_SPACE: '\\u00A0', /* \\u00A0 */\n CHAR_PERCENT: '%', /* % */\n CHAR_PLUS: '+', /* + */\n CHAR_QUESTION_MARK: '?', /* ? */\n CHAR_RIGHT_ANGLE_BRACKET: '>', /* > */\n CHAR_RIGHT_CURLY_BRACE: '}', /* } */\n CHAR_RIGHT_SQUARE_BRACKET: ']', /* ] */\n CHAR_SEMICOLON: ';', /* ; */\n CHAR_SINGLE_QUOTE: '\\'', /* ' */\n CHAR_SPACE: ' ', /* */\n CHAR_TAB: '\\t', /* \\t */\n CHAR_UNDERSCORE: '_', /* _ */\n CHAR_VERTICAL_LINE: '|', /* | */\n CHAR_ZERO_WIDTH_NOBREAK_SPACE: '\\uFEFF' /* \\uFEFF */\n};\n", "'use strict';\n\nconst stringify = require('./stringify');\n\n/**\n * Constants\n */\n\nconst {\n MAX_LENGTH,\n CHAR_BACKSLASH, /* \\ */\n CHAR_BACKTICK, /* ` */\n CHAR_COMMA, /* , */\n CHAR_DOT, /* . */\n CHAR_LEFT_PARENTHESES, /* ( */\n CHAR_RIGHT_PARENTHESES, /* ) */\n CHAR_LEFT_CURLY_BRACE, /* { */\n CHAR_RIGHT_CURLY_BRACE, /* } */\n CHAR_LEFT_SQUARE_BRACKET, /* [ */\n CHAR_RIGHT_SQUARE_BRACKET, /* ] */\n CHAR_DOUBLE_QUOTE, /* \" */\n CHAR_SINGLE_QUOTE, /* ' */\n CHAR_NO_BREAK_SPACE,\n CHAR_ZERO_WIDTH_NOBREAK_SPACE\n} = require('./constants');\n\n/**\n * parse\n */\n\nconst parse = (input, options = {}) => {\n if (typeof input !== 'string') {\n throw new TypeError('Expected a string');\n }\n\n let opts = options || {};\n let max = typeof opts.maxLength === 'number' ? Math.min(MAX_LENGTH, opts.maxLength) : MAX_LENGTH;\n if (input.length > max) {\n throw new SyntaxError(`Input length (${input.length}), exceeds max characters (${max})`);\n }\n\n let ast = { type: 'root', input, nodes: [] };\n let stack = [ast];\n let block = ast;\n let prev = ast;\n let brackets = 0;\n let length = input.length;\n let index = 0;\n let depth = 0;\n let value;\n let memo = {};\n\n /**\n * Helpers\n */\n\n const advance = () => input[index++];\n const push = node => {\n if (node.type === 'text' && prev.type === 'dot') {\n prev.type = 'text';\n }\n\n if (prev && prev.type === 'text' && node.type === 'text') {\n prev.value += node.value;\n return;\n }\n\n block.nodes.push(node);\n node.parent = block;\n node.prev = prev;\n prev = node;\n return node;\n };\n\n push({ type: 'bos' });\n\n while (index < length) {\n block = stack[stack.length - 1];\n value = advance();\n\n /**\n * Invalid chars\n */\n\n if (value === CHAR_ZERO_WIDTH_NOBREAK_SPACE || value === CHAR_NO_BREAK_SPACE) {\n continue;\n }\n\n /**\n * Escaped chars\n */\n\n if (value === CHAR_BACKSLASH) {\n push({ type: 'text', value: (options.keepEscaping ? value : '') + advance() });\n continue;\n }\n\n /**\n * Right square bracket (literal): ']'\n */\n\n if (value === CHAR_RIGHT_SQUARE_BRACKET) {\n push({ type: 'text', value: '\\\\' + value });\n continue;\n }\n\n /**\n * Left square bracket: '['\n */\n\n if (value === CHAR_LEFT_SQUARE_BRACKET) {\n brackets++;\n\n let closed = true;\n let next;\n\n while (index < length && (next = advance())) {\n value += next;\n\n if (next === CHAR_LEFT_SQUARE_BRACKET) {\n brackets++;\n continue;\n }\n\n if (next === CHAR_BACKSLASH) {\n value += advance();\n continue;\n }\n\n if (next === CHAR_RIGHT_SQUARE_BRACKET) {\n brackets--;\n\n if (brackets === 0) {\n break;\n }\n }\n }\n\n push({ type: 'text', value });\n continue;\n }\n\n /**\n * Parentheses\n */\n\n if (value === CHAR_LEFT_PARENTHESES) {\n block = push({ type: 'paren', nodes: [] });\n stack.push(block);\n push({ type: 'text', value });\n continue;\n }\n\n if (value === CHAR_RIGHT_PARENTHESES) {\n if (block.type !== 'paren') {\n push({ type: 'text', value });\n continue;\n }\n block = stack.pop();\n push({ type: 'text', value });\n block = stack[stack.length - 1];\n continue;\n }\n\n /**\n * Quotes: '|\"|`\n */\n\n if (value === CHAR_DOUBLE_QUOTE || value === CHAR_SINGLE_QUOTE || value === CHAR_BACKTICK) {\n let open = value;\n let next;\n\n if (options.keepQuotes !== true) {\n value = '';\n }\n\n while (index < length && (next = advance())) {\n if (next === CHAR_BACKSLASH) {\n value += next + advance();\n continue;\n }\n\n if (next === open) {\n if (options.keepQuotes === true) value += next;\n break;\n }\n\n value += next;\n }\n\n push({ type: 'text', value });\n continue;\n }\n\n /**\n * Left curly brace: '{'\n */\n\n if (value === CHAR_LEFT_CURLY_BRACE) {\n depth++;\n\n let dollar = prev.value && prev.value.slice(-1) === '$' || block.dollar === true;\n let brace = {\n type: 'brace',\n open: true,\n close: false,\n dollar,\n depth,\n commas: 0,\n ranges: 0,\n nodes: []\n };\n\n block = push(brace);\n stack.push(block);\n push({ type: 'open', value });\n continue;\n }\n\n /**\n * Right curly brace: '}'\n */\n\n if (value === CHAR_RIGHT_CURLY_BRACE) {\n if (block.type !== 'brace') {\n push({ type: 'text', value });\n continue;\n }\n\n let type = 'close';\n block = stack.pop();\n block.close = true;\n\n push({ type, value });\n depth--;\n\n block = stack[stack.length - 1];\n continue;\n }\n\n /**\n * Comma: ','\n */\n\n if (value === CHAR_COMMA && depth > 0) {\n if (block.ranges > 0) {\n block.ranges = 0;\n let open = block.nodes.shift();\n block.nodes = [open, { type: 'text', value: stringify(block) }];\n }\n\n push({ type: 'comma', value });\n block.commas++;\n continue;\n }\n\n /**\n * Dot: '.'\n */\n\n if (value === CHAR_DOT && depth > 0 && block.commas === 0) {\n let siblings = block.nodes;\n\n if (depth === 0 || siblings.length === 0) {\n push({ type: 'text', value });\n continue;\n }\n\n if (prev.type === 'dot') {\n block.range = [];\n prev.value += value;\n prev.type = 'range';\n\n if (block.nodes.length !== 3 && block.nodes.length !== 5) {\n block.invalid = true;\n block.ranges = 0;\n prev.type = 'text';\n continue;\n }\n\n block.ranges++;\n block.args = [];\n continue;\n }\n\n if (prev.type === 'range') {\n siblings.pop();\n\n let before = siblings[siblings.length - 1];\n before.value += prev.value + value;\n prev = before;\n block.ranges--;\n continue;\n }\n\n push({ type: 'dot', value });\n continue;\n }\n\n /**\n * Text\n */\n\n push({ type: 'text', value });\n }\n\n // Mark imbalanced braces and brackets as invalid\n do {\n block = stack.pop();\n\n if (block.type !== 'root') {\n block.nodes.forEach(node => {\n if (!node.nodes) {\n if (node.type === 'open') node.isOpen = true;\n if (node.type === 'close') node.isClose = true;\n if (!node.nodes) node.type = 'text';\n node.invalid = true;\n }\n });\n\n // get the location of the block on parent.nodes (block's siblings)\n let parent = stack[stack.length - 1];\n let index = parent.nodes.indexOf(block);\n // replace the (invalid) block with it's nodes\n parent.nodes.splice(index, 1, ...block.nodes);\n }\n } while (stack.length > 0);\n\n push({ type: 'eos' });\n return ast;\n};\n\nmodule.exports = parse;\n", "'use strict';\n\nconst stringify = require('./lib/stringify');\nconst compile = require('./lib/compile');\nconst expand = require('./lib/expand');\nconst parse = require('./lib/parse');\n\n/**\n * Expand the given pattern or create a regex-compatible string.\n *\n * ```js\n * const braces = require('braces');\n * console.log(braces('{a,b,c}', { compile: true })); //=> ['(a|b|c)']\n * console.log(braces('{a,b,c}')); //=> ['a', 'b', 'c']\n * ```\n * @param {String} `str`\n * @param {Object} `options`\n * @return {String}\n * @api public\n */\n\nconst braces = (input, options = {}) => {\n let output = [];\n\n if (Array.isArray(input)) {\n for (let pattern of input) {\n let result = braces.create(pattern, options);\n if (Array.isArray(result)) {\n output.push(...result);\n } else {\n output.push(result);\n }\n }\n } else {\n output = [].concat(braces.create(input, options));\n }\n\n if (options && options.expand === true && options.nodupes === true) {\n output = [...new Set(output)];\n }\n return output;\n};\n\n/**\n * Parse the given `str` with the given `options`.\n *\n * ```js\n * // braces.parse(pattern, [, options]);\n * const ast = braces.parse('a/{b,c}/d');\n * console.log(ast);\n * ```\n * @param {String} pattern Brace pattern to parse\n * @param {Object} options\n * @return {Object} Returns an AST\n * @api public\n */\n\nbraces.parse = (input, options = {}) => parse(input, options);\n\n/**\n * Creates a braces string from an AST, or an AST node.\n *\n * ```js\n * const braces = require('braces');\n * let ast = braces.parse('foo/{a,b}/bar');\n * console.log(stringify(ast.nodes[2])); //=> '{a,b}'\n * ```\n * @param {String} `input` Brace pattern or AST.\n * @param {Object} `options`\n * @return {Array} Returns an array of expanded values.\n * @api public\n */\n\nbraces.stringify = (input, options = {}) => {\n if (typeof input === 'string') {\n return stringify(braces.parse(input, options), options);\n }\n return stringify(input, options);\n};\n\n/**\n * Compiles a brace pattern into a regex-compatible, optimized string.\n * This method is called by the main [braces](#braces) function by default.\n *\n * ```js\n * const braces = require('braces');\n * console.log(braces.compile('a/{b,c}/d'));\n * //=> ['a/(b|c)/d']\n * ```\n * @param {String} `input` Brace pattern or AST.\n * @param {Object} `options`\n * @return {Array} Returns an array of expanded values.\n * @api public\n */\n\nbraces.compile = (input, options = {}) => {\n if (typeof input === 'string') {\n input = braces.parse(input, options);\n }\n return compile(input, options);\n};\n\n/**\n * Expands a brace pattern into an array. This method is called by the\n * main [braces](#braces) function when `options.expand` is true. Before\n * using this method it's recommended that you read the [performance notes](#performance))\n * and advantages of using [.compile](#compile) instead.\n *\n * ```js\n * const braces = require('braces');\n * console.log(braces.expand('a/{b,c}/d'));\n * //=> ['a/b/d', 'a/c/d'];\n * ```\n * @param {String} `pattern` Brace pattern\n * @param {Object} `options`\n * @return {Array} Returns an array of expanded values.\n * @api public\n */\n\nbraces.expand = (input, options = {}) => {\n if (typeof input === 'string') {\n input = braces.parse(input, options);\n }\n\n let result = expand(input, options);\n\n // filter out empty strings if specified\n if (options.noempty === true) {\n result = result.filter(Boolean);\n }\n\n // filter out duplicates if specified\n if (options.nodupes === true) {\n result = [...new Set(result)];\n }\n\n return result;\n};\n\n/**\n * Processes a brace pattern and returns either an expanded array\n * (if `options.expand` is true), a highly optimized regex-compatible string.\n * This method is called by the main [braces](#braces) function.\n *\n * ```js\n * const braces = require('braces');\n * console.log(braces.create('user-{200..300}/project-{a,b,c}-{1..10}'))\n * //=> 'user-(20[0-9]|2[1-9][0-9]|300)/project-(a|b|c)-([1-9]|10)'\n * ```\n * @param {String} `pattern` Brace pattern\n * @param {Object} `options`\n * @return {Array} Returns an array of expanded values.\n * @api public\n */\n\nbraces.create = (input, options = {}) => {\n if (input === '' || input.length < 3) {\n return [input];\n }\n\n return options.expand !== true\n ? braces.compile(input, options)\n : braces.expand(input, options);\n};\n\n/**\n * Expose \"braces\"\n */\n\nmodule.exports = braces;\n", "'use strict';\n\nconst path = require('path');\nconst WIN_SLASH = '\\\\\\\\/';\nconst WIN_NO_SLASH = `[^${WIN_SLASH}]`;\n\n/**\n * Posix glob regex\n */\n\nconst DOT_LITERAL = '\\\\.';\nconst PLUS_LITERAL = '\\\\+';\nconst QMARK_LITERAL = '\\\\?';\nconst SLASH_LITERAL = '\\\\/';\nconst ONE_CHAR = '(?=.)';\nconst QMARK = '[^/]';\nconst END_ANCHOR = `(?:${SLASH_LITERAL}|$)`;\nconst START_ANCHOR = `(?:^|${SLASH_LITERAL})`;\nconst DOTS_SLASH = `${DOT_LITERAL}{1,2}${END_ANCHOR}`;\nconst NO_DOT = `(?!${DOT_LITERAL})`;\nconst NO_DOTS = `(?!${START_ANCHOR}${DOTS_SLASH})`;\nconst NO_DOT_SLASH = `(?!${DOT_LITERAL}{0,1}${END_ANCHOR})`;\nconst NO_DOTS_SLASH = `(?!${DOTS_SLASH})`;\nconst QMARK_NO_DOT = `[^.${SLASH_LITERAL}]`;\nconst STAR = `${QMARK}*?`;\n\nconst POSIX_CHARS = {\n DOT_LITERAL,\n PLUS_LITERAL,\n QMARK_LITERAL,\n SLASH_LITERAL,\n ONE_CHAR,\n QMARK,\n END_ANCHOR,\n DOTS_SLASH,\n NO_DOT,\n NO_DOTS,\n NO_DOT_SLASH,\n NO_DOTS_SLASH,\n QMARK_NO_DOT,\n STAR,\n START_ANCHOR\n};\n\n/**\n * Windows glob regex\n */\n\nconst WINDOWS_CHARS = {\n ...POSIX_CHARS,\n\n SLASH_LITERAL: `[${WIN_SLASH}]`,\n QMARK: WIN_NO_SLASH,\n STAR: `${WIN_NO_SLASH}*?`,\n DOTS_SLASH: `${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$)`,\n NO_DOT: `(?!${DOT_LITERAL})`,\n NO_DOTS: `(?!(?:^|[${WIN_SLASH}])${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$))`,\n NO_DOT_SLASH: `(?!${DOT_LITERAL}{0,1}(?:[${WIN_SLASH}]|$))`,\n NO_DOTS_SLASH: `(?!${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$))`,\n QMARK_NO_DOT: `[^.${WIN_SLASH}]`,\n START_ANCHOR: `(?:^|[${WIN_SLASH}])`,\n END_ANCHOR: `(?:[${WIN_SLASH}]|$)`\n};\n\n/**\n * POSIX Bracket Regex\n */\n\nconst POSIX_REGEX_SOURCE = {\n alnum: 'a-zA-Z0-9',\n alpha: 'a-zA-Z',\n ascii: '\\\\x00-\\\\x7F',\n blank: ' \\\\t',\n cntrl: '\\\\x00-\\\\x1F\\\\x7F',\n digit: '0-9',\n graph: '\\\\x21-\\\\x7E',\n lower: 'a-z',\n print: '\\\\x20-\\\\x7E ',\n punct: '\\\\-!\"#$%&\\'()\\\\*+,./:;<=>?@[\\\\]^_`{|}~',\n space: ' \\\\t\\\\r\\\\n\\\\v\\\\f',\n upper: 'A-Z',\n word: 'A-Za-z0-9_',\n xdigit: 'A-Fa-f0-9'\n};\n\nmodule.exports = {\n MAX_LENGTH: 1024 * 64,\n POSIX_REGEX_SOURCE,\n\n // regular expressions\n REGEX_BACKSLASH: /\\\\(?![*+?^${}(|)[\\]])/g,\n REGEX_NON_SPECIAL_CHARS: /^[^@![\\].,$*+?^{}()|\\\\/]+/,\n REGEX_SPECIAL_CHARS: /[-*+?.^${}(|)[\\]]/,\n REGEX_SPECIAL_CHARS_BACKREF: /(\\\\?)((\\W)(\\3*))/g,\n REGEX_SPECIAL_CHARS_GLOBAL: /([-*+?.^${}(|)[\\]])/g,\n REGEX_REMOVE_BACKSLASH: /(?:\\[.*?[^\\\\]\\]|\\\\(?=.))/g,\n\n // Replace globs with equivalent patterns to reduce parsing time.\n REPLACEMENTS: {\n '***': '*',\n '**/**': '**',\n '**/**/**': '**'\n },\n\n // Digits\n CHAR_0: 48, /* 0 */\n CHAR_9: 57, /* 9 */\n\n // Alphabet chars.\n CHAR_UPPERCASE_A: 65, /* A */\n CHAR_LOWERCASE_A: 97, /* a */\n CHAR_UPPERCASE_Z: 90, /* Z */\n CHAR_LOWERCASE_Z: 122, /* z */\n\n CHAR_LEFT_PARENTHESES: 40, /* ( */\n CHAR_RIGHT_PARENTHESES: 41, /* ) */\n\n CHAR_ASTERISK: 42, /* * */\n\n // Non-alphabetic chars.\n CHAR_AMPERSAND: 38, /* & */\n CHAR_AT: 64, /* @ */\n CHAR_BACKWARD_SLASH: 92, /* \\ */\n CHAR_CARRIAGE_RETURN: 13, /* \\r */\n CHAR_CIRCUMFLEX_ACCENT: 94, /* ^ */\n CHAR_COLON: 58, /* : */\n CHAR_COMMA: 44, /* , */\n CHAR_DOT: 46, /* . */\n CHAR_DOUBLE_QUOTE: 34, /* \" */\n CHAR_EQUAL: 61, /* = */\n CHAR_EXCLAMATION_MARK: 33, /* ! */\n CHAR_FORM_FEED: 12, /* \\f */\n CHAR_FORWARD_SLASH: 47, /* / */\n CHAR_GRAVE_ACCENT: 96, /* ` */\n CHAR_HASH: 35, /* # */\n CHAR_HYPHEN_MINUS: 45, /* - */\n CHAR_LEFT_ANGLE_BRACKET: 60, /* < */\n CHAR_LEFT_CURLY_BRACE: 123, /* { */\n CHAR_LEFT_SQUARE_BRACKET: 91, /* [ */\n CHAR_LINE_FEED: 10, /* \\n */\n CHAR_NO_BREAK_SPACE: 160, /* \\u00A0 */\n CHAR_PERCENT: 37, /* % */\n CHAR_PLUS: 43, /* + */\n CHAR_QUESTION_MARK: 63, /* ? */\n CHAR_RIGHT_ANGLE_BRACKET: 62, /* > */\n CHAR_RIGHT_CURLY_BRACE: 125, /* } */\n CHAR_RIGHT_SQUARE_BRACKET: 93, /* ] */\n CHAR_SEMICOLON: 59, /* ; */\n CHAR_SINGLE_QUOTE: 39, /* ' */\n CHAR_SPACE: 32, /* */\n CHAR_TAB: 9, /* \\t */\n CHAR_UNDERSCORE: 95, /* _ */\n CHAR_VERTICAL_LINE: 124, /* | */\n CHAR_ZERO_WIDTH_NOBREAK_SPACE: 65279, /* \\uFEFF */\n\n SEP: path.sep,\n\n /**\n * Create EXTGLOB_CHARS\n */\n\n extglobChars(chars) {\n return {\n '!': { type: 'negate', open: '(?:(?!(?:', close: `))${chars.STAR})` },\n '?': { type: 'qmark', open: '(?:', close: ')?' },\n '+': { type: 'plus', open: '(?:', close: ')+' },\n '*': { type: 'star', open: '(?:', close: ')*' },\n '@': { type: 'at', open: '(?:', close: ')' }\n };\n },\n\n /**\n * Create GLOB_CHARS\n */\n\n globChars(win32) {\n return win32 === true ? WINDOWS_CHARS : POSIX_CHARS;\n }\n};\n", "'use strict';\n\nconst path = require('path');\nconst win32 = process.platform === 'win32';\nconst {\n REGEX_BACKSLASH,\n REGEX_REMOVE_BACKSLASH,\n REGEX_SPECIAL_CHARS,\n REGEX_SPECIAL_CHARS_GLOBAL\n} = require('./constants');\n\nexports.isObject = val => val !== null && typeof val === 'object' && !Array.isArray(val);\nexports.hasRegexChars = str => REGEX_SPECIAL_CHARS.test(str);\nexports.isRegexChar = str => str.length === 1 && exports.hasRegexChars(str);\nexports.escapeRegex = str => str.replace(REGEX_SPECIAL_CHARS_GLOBAL, '\\\\$1');\nexports.toPosixSlashes = str => str.replace(REGEX_BACKSLASH, '/');\n\nexports.removeBackslashes = str => {\n return str.replace(REGEX_REMOVE_BACKSLASH, match => {\n return match === '\\\\' ? '' : match;\n });\n};\n\nexports.supportsLookbehinds = () => {\n const segs = process.version.slice(1).split('.').map(Number);\n if (segs.length === 3 && segs[0] >= 9 || (segs[0] === 8 && segs[1] >= 10)) {\n return true;\n }\n return false;\n};\n\nexports.isWindows = options => {\n if (options && typeof options.windows === 'boolean') {\n return options.windows;\n }\n return win32 === true || path.sep === '\\\\';\n};\n\nexports.escapeLast = (input, char, lastIdx) => {\n const idx = input.lastIndexOf(char, lastIdx);\n if (idx === -1) return input;\n if (input[idx - 1] === '\\\\') return exports.escapeLast(input, char, idx - 1);\n return `${input.slice(0, idx)}\\\\${input.slice(idx)}`;\n};\n\nexports.removePrefix = (input, state = {}) => {\n let output = input;\n if (output.startsWith('./')) {\n output = output.slice(2);\n state.prefix = './';\n }\n return output;\n};\n\nexports.wrapOutput = (input, state = {}, options = {}) => {\n const prepend = options.contains ? '' : '^';\n const append = options.contains ? '' : '$';\n\n let output = `${prepend}(?:${input})${append}`;\n if (state.negated === true) {\n output = `(?:^(?!${output}).*$)`;\n }\n return output;\n};\n", "'use strict';\n\nconst utils = require('./utils');\nconst {\n CHAR_ASTERISK, /* * */\n CHAR_AT, /* @ */\n CHAR_BACKWARD_SLASH, /* \\ */\n CHAR_COMMA, /* , */\n CHAR_DOT, /* . */\n CHAR_EXCLAMATION_MARK, /* ! */\n CHAR_FORWARD_SLASH, /* / */\n CHAR_LEFT_CURLY_BRACE, /* { */\n CHAR_LEFT_PARENTHESES, /* ( */\n CHAR_LEFT_SQUARE_BRACKET, /* [ */\n CHAR_PLUS, /* + */\n CHAR_QUESTION_MARK, /* ? */\n CHAR_RIGHT_CURLY_BRACE, /* } */\n CHAR_RIGHT_PARENTHESES, /* ) */\n CHAR_RIGHT_SQUARE_BRACKET /* ] */\n} = require('./constants');\n\nconst isPathSeparator = code => {\n return code === CHAR_FORWARD_SLASH || code === CHAR_BACKWARD_SLASH;\n};\n\nconst depth = token => {\n if (token.isPrefix !== true) {\n token.depth = token.isGlobstar ? Infinity : 1;\n }\n};\n\n/**\n * Quickly scans a glob pattern and returns an object with a handful of\n * useful properties, like `isGlob`, `path` (the leading non-glob, if it exists),\n * `glob` (the actual pattern), `negated` (true if the path starts with `!` but not\n * with `!(`) and `negatedExtglob` (true if the path starts with `!(`).\n *\n * ```js\n * const pm = require('picomatch');\n * console.log(pm.scan('foo/bar/*.js'));\n * { isGlob: true, input: 'foo/bar/*.js', base: 'foo/bar', glob: '*.js' }\n * ```\n * @param {String} `str`\n * @param {Object} `options`\n * @return {Object} Returns an object with tokens and regex source string.\n * @api public\n */\n\nconst scan = (input, options) => {\n const opts = options || {};\n\n const length = input.length - 1;\n const scanToEnd = opts.parts === true || opts.scanToEnd === true;\n const slashes = [];\n const tokens = [];\n const parts = [];\n\n let str = input;\n let index = -1;\n let start = 0;\n let lastIndex = 0;\n let isBrace = false;\n let isBracket = false;\n let isGlob = false;\n let isExtglob = false;\n let isGlobstar = false;\n let braceEscaped = false;\n let backslashes = false;\n let negated = false;\n let negatedExtglob = false;\n let finished = false;\n let braces = 0;\n let prev;\n let code;\n let token = { value: '', depth: 0, isGlob: false };\n\n const eos = () => index >= length;\n const peek = () => str.charCodeAt(index + 1);\n const advance = () => {\n prev = code;\n return str.charCodeAt(++index);\n };\n\n while (index < length) {\n code = advance();\n let next;\n\n if (code === CHAR_BACKWARD_SLASH) {\n backslashes = token.backslashes = true;\n code = advance();\n\n if (code === CHAR_LEFT_CURLY_BRACE) {\n braceEscaped = true;\n }\n continue;\n }\n\n if (braceEscaped === true || code === CHAR_LEFT_CURLY_BRACE) {\n braces++;\n\n while (eos() !== true && (code = advance())) {\n if (code === CHAR_BACKWARD_SLASH) {\n backslashes = token.backslashes = true;\n advance();\n continue;\n }\n\n if (code === CHAR_LEFT_CURLY_BRACE) {\n braces++;\n continue;\n }\n\n if (braceEscaped !== true && code === CHAR_DOT && (code = advance()) === CHAR_DOT) {\n isBrace = token.isBrace = true;\n isGlob = token.isGlob = true;\n finished = true;\n\n if (scanToEnd === true) {\n continue;\n }\n\n break;\n }\n\n if (braceEscaped !== true && code === CHAR_COMMA) {\n isBrace = token.isBrace = true;\n isGlob = token.isGlob = true;\n finished = true;\n\n if (scanToEnd === true) {\n continue;\n }\n\n break;\n }\n\n if (code === CHAR_RIGHT_CURLY_BRACE) {\n braces--;\n\n if (braces === 0) {\n braceEscaped = false;\n isBrace = token.isBrace = true;\n finished = true;\n break;\n }\n }\n }\n\n if (scanToEnd === true) {\n continue;\n }\n\n break;\n }\n\n if (code === CHAR_FORWARD_SLASH) {\n slashes.push(index);\n tokens.push(token);\n token = { value: '', depth: 0, isGlob: false };\n\n if (finished === true) continue;\n if (prev === CHAR_DOT && index === (start + 1)) {\n start += 2;\n continue;\n }\n\n lastIndex = index + 1;\n continue;\n }\n\n if (opts.noext !== true) {\n const isExtglobChar = code === CHAR_PLUS\n || code === CHAR_AT\n || code === CHAR_ASTERISK\n || code === CHAR_QUESTION_MARK\n || code === CHAR_EXCLAMATION_MARK;\n\n if (isExtglobChar === true && peek() === CHAR_LEFT_PARENTHESES) {\n isGlob = token.isGlob = true;\n isExtglob = token.isExtglob = true;\n finished = true;\n if (code === CHAR_EXCLAMATION_MARK && index === start) {\n negatedExtglob = true;\n }\n\n if (scanToEnd === true) {\n while (eos() !== true && (code = advance())) {\n if (code === CHAR_BACKWARD_SLASH) {\n backslashes = token.backslashes = true;\n code = advance();\n continue;\n }\n\n if (code === CHAR_RIGHT_PARENTHESES) {\n isGlob = token.isGlob = true;\n finished = true;\n break;\n }\n }\n continue;\n }\n break;\n }\n }\n\n if (code === CHAR_ASTERISK) {\n if (prev === CHAR_ASTERISK) isGlobstar = token.isGlobstar = true;\n isGlob = token.isGlob = true;\n finished = true;\n\n if (scanToEnd === true) {\n continue;\n }\n break;\n }\n\n if (code === CHAR_QUESTION_MARK) {\n isGlob = token.isGlob = true;\n finished = true;\n\n if (scanToEnd === true) {\n continue;\n }\n break;\n }\n\n if (code === CHAR_LEFT_SQUARE_BRACKET) {\n while (eos() !== true && (next = advance())) {\n if (next === CHAR_BACKWARD_SLASH) {\n backslashes = token.backslashes = true;\n advance();\n continue;\n }\n\n if (next === CHAR_RIGHT_SQUARE_BRACKET) {\n isBracket = token.isBracket = true;\n isGlob = token.isGlob = true;\n finished = true;\n break;\n }\n }\n\n if (scanToEnd === true) {\n continue;\n }\n\n break;\n }\n\n if (opts.nonegate !== true && code === CHAR_EXCLAMATION_MARK && index === start) {\n negated = token.negated = true;\n start++;\n continue;\n }\n\n if (opts.noparen !== true && code === CHAR_LEFT_PARENTHESES) {\n isGlob = token.isGlob = true;\n\n if (scanToEnd === true) {\n while (eos() !== true && (code = advance())) {\n if (code === CHAR_LEFT_PARENTHESES) {\n backslashes = token.backslashes = true;\n code = advance();\n continue;\n }\n\n if (code === CHAR_RIGHT_PARENTHESES) {\n finished = true;\n break;\n }\n }\n continue;\n }\n break;\n }\n\n if (isGlob === true) {\n finished = true;\n\n if (scanToEnd === true) {\n continue;\n }\n\n break;\n }\n }\n\n if (opts.noext === true) {\n isExtglob = false;\n isGlob = false;\n }\n\n let base = str;\n let prefix = '';\n let glob = '';\n\n if (start > 0) {\n prefix = str.slice(0, start);\n str = str.slice(start);\n lastIndex -= start;\n }\n\n if (base && isGlob === true && lastIndex > 0) {\n base = str.slice(0, lastIndex);\n glob = str.slice(lastIndex);\n } else if (isGlob === true) {\n base = '';\n glob = str;\n } else {\n base = str;\n }\n\n if (base && base !== '' && base !== '/' && base !== str) {\n if (isPathSeparator(base.charCodeAt(base.length - 1))) {\n base = base.slice(0, -1);\n }\n }\n\n if (opts.unescape === true) {\n if (glob) glob = utils.removeBackslashes(glob);\n\n if (base && backslashes === true) {\n base = utils.removeBackslashes(base);\n }\n }\n\n const state = {\n prefix,\n input,\n start,\n base,\n glob,\n isBrace,\n isBracket,\n isGlob,\n isExtglob,\n isGlobstar,\n negated,\n negatedExtglob\n };\n\n if (opts.tokens === true) {\n state.maxDepth = 0;\n if (!isPathSeparator(code)) {\n tokens.push(token);\n }\n state.tokens = tokens;\n }\n\n if (opts.parts === true || opts.tokens === true) {\n let prevIndex;\n\n for (let idx = 0; idx < slashes.length; idx++) {\n const n = prevIndex ? prevIndex + 1 : start;\n const i = slashes[idx];\n const value = input.slice(n, i);\n if (opts.tokens) {\n if (idx === 0 && start !== 0) {\n tokens[idx].isPrefix = true;\n tokens[idx].value = prefix;\n } else {\n tokens[idx].value = value;\n }\n depth(tokens[idx]);\n state.maxDepth += tokens[idx].depth;\n }\n if (idx !== 0 || value !== '') {\n parts.push(value);\n }\n prevIndex = i;\n }\n\n if (prevIndex && prevIndex + 1 < input.length) {\n const value = input.slice(prevIndex + 1);\n parts.push(value);\n\n if (opts.tokens) {\n tokens[tokens.length - 1].value = value;\n depth(tokens[tokens.length - 1]);\n state.maxDepth += tokens[tokens.length - 1].depth;\n }\n }\n\n state.slashes = slashes;\n state.parts = parts;\n }\n\n return state;\n};\n\nmodule.exports = scan;\n", "'use strict';\n\nconst constants = require('./constants');\nconst utils = require('./utils');\n\n/**\n * Constants\n */\n\nconst {\n MAX_LENGTH,\n POSIX_REGEX_SOURCE,\n REGEX_NON_SPECIAL_CHARS,\n REGEX_SPECIAL_CHARS_BACKREF,\n REPLACEMENTS\n} = constants;\n\n/**\n * Helpers\n */\n\nconst expandRange = (args, options) => {\n if (typeof options.expandRange === 'function') {\n return options.expandRange(...args, options);\n }\n\n args.sort();\n const value = `[${args.join('-')}]`;\n\n try {\n /* eslint-disable-next-line no-new */\n new RegExp(value);\n } catch (ex) {\n return args.map(v => utils.escapeRegex(v)).join('..');\n }\n\n return value;\n};\n\n/**\n * Create the message for a syntax error\n */\n\nconst syntaxError = (type, char) => {\n return `Missing ${type}: \"${char}\" - use \"\\\\\\\\${char}\" to match literal characters`;\n};\n\n/**\n * Parse the given input string.\n * @param {String} input\n * @param {Object} options\n * @return {Object}\n */\n\nconst parse = (input, options) => {\n if (typeof input !== 'string') {\n throw new TypeError('Expected a string');\n }\n\n input = REPLACEMENTS[input] || input;\n\n const opts = { ...options };\n const max = typeof opts.maxLength === 'number' ? Math.min(MAX_LENGTH, opts.maxLength) : MAX_LENGTH;\n\n let len = input.length;\n if (len > max) {\n throw new SyntaxError(`Input length: ${len}, exceeds maximum allowed length: ${max}`);\n }\n\n const bos = { type: 'bos', value: '', output: opts.prepend || '' };\n const tokens = [bos];\n\n const capture = opts.capture ? '' : '?:';\n const win32 = utils.isWindows(options);\n\n // create constants based on platform, for windows or posix\n const PLATFORM_CHARS = constants.globChars(win32);\n const EXTGLOB_CHARS = constants.extglobChars(PLATFORM_CHARS);\n\n const {\n DOT_LITERAL,\n PLUS_LITERAL,\n SLASH_LITERAL,\n ONE_CHAR,\n DOTS_SLASH,\n NO_DOT,\n NO_DOT_SLASH,\n NO_DOTS_SLASH,\n QMARK,\n QMARK_NO_DOT,\n STAR,\n START_ANCHOR\n } = PLATFORM_CHARS;\n\n const globstar = opts => {\n return `(${capture}(?:(?!${START_ANCHOR}${opts.dot ? DOTS_SLASH : DOT_LITERAL}).)*?)`;\n };\n\n const nodot = opts.dot ? '' : NO_DOT;\n const qmarkNoDot = opts.dot ? QMARK : QMARK_NO_DOT;\n let star = opts.bash === true ? globstar(opts) : STAR;\n\n if (opts.capture) {\n star = `(${star})`;\n }\n\n // minimatch options support\n if (typeof opts.noext === 'boolean') {\n opts.noextglob = opts.noext;\n }\n\n const state = {\n input,\n index: -1,\n start: 0,\n dot: opts.dot === true,\n consumed: '',\n output: '',\n prefix: '',\n backtrack: false,\n negated: false,\n brackets: 0,\n braces: 0,\n parens: 0,\n quotes: 0,\n globstar: false,\n tokens\n };\n\n input = utils.removePrefix(input, state);\n len = input.length;\n\n const extglobs = [];\n const braces = [];\n const stack = [];\n let prev = bos;\n let value;\n\n /**\n * Tokenizing helpers\n */\n\n const eos = () => state.index === len - 1;\n const peek = state.peek = (n = 1) => input[state.index + n];\n const advance = state.advance = () => input[++state.index] || '';\n const remaining = () => input.slice(state.index + 1);\n const consume = (value = '', num = 0) => {\n state.consumed += value;\n state.index += num;\n };\n\n const append = token => {\n state.output += token.output != null ? token.output : token.value;\n consume(token.value);\n };\n\n const negate = () => {\n let count = 1;\n\n while (peek() === '!' && (peek(2) !== '(' || peek(3) === '?')) {\n advance();\n state.start++;\n count++;\n }\n\n if (count % 2 === 0) {\n return false;\n }\n\n state.negated = true;\n state.start++;\n return true;\n };\n\n const increment = type => {\n state[type]++;\n stack.push(type);\n };\n\n const decrement = type => {\n state[type]--;\n stack.pop();\n };\n\n /**\n * Push tokens onto the tokens array. This helper speeds up\n * tokenizing by 1) helping us avoid backtracking as much as possible,\n * and 2) helping us avoid creating extra tokens when consecutive\n * characters are plain text. This improves performance and simplifies\n * lookbehinds.\n */\n\n const push = tok => {\n if (prev.type === 'globstar') {\n const isBrace = state.braces > 0 && (tok.type === 'comma' || tok.type === 'brace');\n const isExtglob = tok.extglob === true || (extglobs.length && (tok.type === 'pipe' || tok.type === 'paren'));\n\n if (tok.type !== 'slash' && tok.type !== 'paren' && !isBrace && !isExtglob) {\n state.output = state.output.slice(0, -prev.output.length);\n prev.type = 'star';\n prev.value = '*';\n prev.output = star;\n state.output += prev.output;\n }\n }\n\n if (extglobs.length && tok.type !== 'paren') {\n extglobs[extglobs.length - 1].inner += tok.value;\n }\n\n if (tok.value || tok.output) append(tok);\n if (prev && prev.type === 'text' && tok.type === 'text') {\n prev.value += tok.value;\n prev.output = (prev.output || '') + tok.value;\n return;\n }\n\n tok.prev = prev;\n tokens.push(tok);\n prev = tok;\n };\n\n const extglobOpen = (type, value) => {\n const token = { ...EXTGLOB_CHARS[value], conditions: 1, inner: '' };\n\n token.prev = prev;\n token.parens = state.parens;\n token.output = state.output;\n const output = (opts.capture ? '(' : '') + token.open;\n\n increment('parens');\n push({ type, value, output: state.output ? '' : ONE_CHAR });\n push({ type: 'paren', extglob: true, value: advance(), output });\n extglobs.push(token);\n };\n\n const extglobClose = token => {\n let output = token.close + (opts.capture ? ')' : '');\n let rest;\n\n if (token.type === 'negate') {\n let extglobStar = star;\n\n if (token.inner && token.inner.length > 1 && token.inner.includes('/')) {\n extglobStar = globstar(opts);\n }\n\n if (extglobStar !== star || eos() || /^\\)+$/.test(remaining())) {\n output = token.close = `)$))${extglobStar}`;\n }\n\n if (token.inner.includes('*') && (rest = remaining()) && /^\\.[^\\\\/.]+$/.test(rest)) {\n output = token.close = `)${rest})${extglobStar})`;\n }\n\n if (token.prev.type === 'bos') {\n state.negatedExtglob = true;\n }\n }\n\n push({ type: 'paren', extglob: true, value, output });\n decrement('parens');\n };\n\n /**\n * Fast paths\n */\n\n if (opts.fastpaths !== false && !/(^[*!]|[/()[\\]{}\"])/.test(input)) {\n let backslashes = false;\n\n let output = input.replace(REGEX_SPECIAL_CHARS_BACKREF, (m, esc, chars, first, rest, index) => {\n if (first === '\\\\') {\n backslashes = true;\n return m;\n }\n\n if (first === '?') {\n if (esc) {\n return esc + first + (rest ? QMARK.repeat(rest.length) : '');\n }\n if (index === 0) {\n return qmarkNoDot + (rest ? QMARK.repeat(rest.length) : '');\n }\n return QMARK.repeat(chars.length);\n }\n\n if (first === '.') {\n return DOT_LITERAL.repeat(chars.length);\n }\n\n if (first === '*') {\n if (esc) {\n return esc + first + (rest ? star : '');\n }\n return star;\n }\n return esc ? m : `\\\\${m}`;\n });\n\n if (backslashes === true) {\n if (opts.unescape === true) {\n output = output.replace(/\\\\/g, '');\n } else {\n output = output.replace(/\\\\+/g, m => {\n return m.length % 2 === 0 ? '\\\\\\\\' : (m ? '\\\\' : '');\n });\n }\n }\n\n if (output === input && opts.contains === true) {\n state.output = input;\n return state;\n }\n\n state.output = utils.wrapOutput(output, state, options);\n return state;\n }\n\n /**\n * Tokenize input until we reach end-of-string\n */\n\n while (!eos()) {\n value = advance();\n\n if (value === '\\u0000') {\n continue;\n }\n\n /**\n * Escaped characters\n */\n\n if (value === '\\\\') {\n const next = peek();\n\n if (next === '/' && opts.bash !== true) {\n continue;\n }\n\n if (next === '.' || next === ';') {\n continue;\n }\n\n if (!next) {\n value += '\\\\';\n push({ type: 'text', value });\n continue;\n }\n\n // collapse slashes to reduce potential for exploits\n const match = /^\\\\+/.exec(remaining());\n let slashes = 0;\n\n if (match && match[0].length > 2) {\n slashes = match[0].length;\n state.index += slashes;\n if (slashes % 2 !== 0) {\n value += '\\\\';\n }\n }\n\n if (opts.unescape === true) {\n value = advance();\n } else {\n value += advance();\n }\n\n if (state.brackets === 0) {\n push({ type: 'text', value });\n continue;\n }\n }\n\n /**\n * If we're inside a regex character class, continue\n * until we reach the closing bracket.\n */\n\n if (state.brackets > 0 && (value !== ']' || prev.value === '[' || prev.value === '[^')) {\n if (opts.posix !== false && value === ':') {\n const inner = prev.value.slice(1);\n if (inner.includes('[')) {\n prev.posix = true;\n\n if (inner.includes(':')) {\n const idx = prev.value.lastIndexOf('[');\n const pre = prev.value.slice(0, idx);\n const rest = prev.value.slice(idx + 2);\n const posix = POSIX_REGEX_SOURCE[rest];\n if (posix) {\n prev.value = pre + posix;\n state.backtrack = true;\n advance();\n\n if (!bos.output && tokens.indexOf(prev) === 1) {\n bos.output = ONE_CHAR;\n }\n continue;\n }\n }\n }\n }\n\n if ((value === '[' && peek() !== ':') || (value === '-' && peek() === ']')) {\n value = `\\\\${value}`;\n }\n\n if (value === ']' && (prev.value === '[' || prev.value === '[^')) {\n value = `\\\\${value}`;\n }\n\n if (opts.posix === true && value === '!' && prev.value === '[') {\n value = '^';\n }\n\n prev.value += value;\n append({ value });\n continue;\n }\n\n /**\n * If we're inside a quoted string, continue\n * until we reach the closing double quote.\n */\n\n if (state.quotes === 1 && value !== '\"') {\n value = utils.escapeRegex(value);\n prev.value += value;\n append({ value });\n continue;\n }\n\n /**\n * Double quotes\n */\n\n if (value === '\"') {\n state.quotes = state.quotes === 1 ? 0 : 1;\n if (opts.keepQuotes === true) {\n push({ type: 'text', value });\n }\n continue;\n }\n\n /**\n * Parentheses\n */\n\n if (value === '(') {\n increment('parens');\n push({ type: 'paren', value });\n continue;\n }\n\n if (value === ')') {\n if (state.parens === 0 && opts.strictBrackets === true) {\n throw new SyntaxError(syntaxError('opening', '('));\n }\n\n const extglob = extglobs[extglobs.length - 1];\n if (extglob && state.parens === extglob.parens + 1) {\n extglobClose(extglobs.pop());\n continue;\n }\n\n push({ type: 'paren', value, output: state.parens ? ')' : '\\\\)' });\n decrement('parens');\n continue;\n }\n\n /**\n * Square brackets\n */\n\n if (value === '[') {\n if (opts.nobracket === true || !remaining().includes(']')) {\n if (opts.nobracket !== true && opts.strictBrackets === true) {\n throw new SyntaxError(syntaxError('closing', ']'));\n }\n\n value = `\\\\${value}`;\n } else {\n increment('brackets');\n }\n\n push({ type: 'bracket', value });\n continue;\n }\n\n if (value === ']') {\n if (opts.nobracket === true || (prev && prev.type === 'bracket' && prev.value.length === 1)) {\n push({ type: 'text', value, output: `\\\\${value}` });\n continue;\n }\n\n if (state.brackets === 0) {\n if (opts.strictBrackets === true) {\n throw new SyntaxError(syntaxError('opening', '['));\n }\n\n push({ type: 'text', value, output: `\\\\${value}` });\n continue;\n }\n\n decrement('brackets');\n\n const prevValue = prev.value.slice(1);\n if (prev.posix !== true && prevValue[0] === '^' && !prevValue.includes('/')) {\n value = `/${value}`;\n }\n\n prev.value += value;\n append({ value });\n\n // when literal brackets are explicitly disabled\n // assume we should match with a regex character class\n if (opts.literalBrackets === false || utils.hasRegexChars(prevValue)) {\n continue;\n }\n\n const escaped = utils.escapeRegex(prev.value);\n state.output = state.output.slice(0, -prev.value.length);\n\n // when literal brackets are explicitly enabled\n // assume we should escape the brackets to match literal characters\n if (opts.literalBrackets === true) {\n state.output += escaped;\n prev.value = escaped;\n continue;\n }\n\n // when the user specifies nothing, try to match both\n prev.value = `(${capture}${escaped}|${prev.value})`;\n state.output += prev.value;\n continue;\n }\n\n /**\n * Braces\n */\n\n if (value === '{' && opts.nobrace !== true) {\n increment('braces');\n\n const open = {\n type: 'brace',\n value,\n output: '(',\n outputIndex: state.output.length,\n tokensIndex: state.tokens.length\n };\n\n braces.push(open);\n push(open);\n continue;\n }\n\n if (value === '}') {\n const brace = braces[braces.length - 1];\n\n if (opts.nobrace === true || !brace) {\n push({ type: 'text', value, output: value });\n continue;\n }\n\n let output = ')';\n\n if (brace.dots === true) {\n const arr = tokens.slice();\n const range = [];\n\n for (let i = arr.length - 1; i >= 0; i--) {\n tokens.pop();\n if (arr[i].type === 'brace') {\n break;\n }\n if (arr[i].type !== 'dots') {\n range.unshift(arr[i].value);\n }\n }\n\n output = expandRange(range, opts);\n state.backtrack = true;\n }\n\n if (brace.comma !== true && brace.dots !== true) {\n const out = state.output.slice(0, brace.outputIndex);\n const toks = state.tokens.slice(brace.tokensIndex);\n brace.value = brace.output = '\\\\{';\n value = output = '\\\\}';\n state.output = out;\n for (const t of toks) {\n state.output += (t.output || t.value);\n }\n }\n\n push({ type: 'brace', value, output });\n decrement('braces');\n braces.pop();\n continue;\n }\n\n /**\n * Pipes\n */\n\n if (value === '|') {\n if (extglobs.length > 0) {\n extglobs[extglobs.length - 1].conditions++;\n }\n push({ type: 'text', value });\n continue;\n }\n\n /**\n * Commas\n */\n\n if (value === ',') {\n let output = value;\n\n const brace = braces[braces.length - 1];\n if (brace && stack[stack.length - 1] === 'braces') {\n brace.comma = true;\n output = '|';\n }\n\n push({ type: 'comma', value, output });\n continue;\n }\n\n /**\n * Slashes\n */\n\n if (value === '/') {\n // if the beginning of the glob is \"./\", advance the start\n // to the current index, and don't add the \"./\" characters\n // to the state. This greatly simplifies lookbehinds when\n // checking for BOS characters like \"!\" and \".\" (not \"./\")\n if (prev.type === 'dot' && state.index === state.start + 1) {\n state.start = state.index + 1;\n state.consumed = '';\n state.output = '';\n tokens.pop();\n prev = bos; // reset \"prev\" to the first token\n continue;\n }\n\n push({ type: 'slash', value, output: SLASH_LITERAL });\n continue;\n }\n\n /**\n * Dots\n */\n\n if (value === '.') {\n if (state.braces > 0 && prev.type === 'dot') {\n if (prev.value === '.') prev.output = DOT_LITERAL;\n const brace = braces[braces.length - 1];\n prev.type = 'dots';\n prev.output += value;\n prev.value += value;\n brace.dots = true;\n continue;\n }\n\n if ((state.braces + state.parens) === 0 && prev.type !== 'bos' && prev.type !== 'slash') {\n push({ type: 'text', value, output: DOT_LITERAL });\n continue;\n }\n\n push({ type: 'dot', value, output: DOT_LITERAL });\n continue;\n }\n\n /**\n * Question marks\n */\n\n if (value === '?') {\n const isGroup = prev && prev.value === '(';\n if (!isGroup && opts.noextglob !== true && peek() === '(' && peek(2) !== '?') {\n extglobOpen('qmark', value);\n continue;\n }\n\n if (prev && prev.type === 'paren') {\n const next = peek();\n let output = value;\n\n if (next === '<' && !utils.supportsLookbehinds()) {\n throw new Error('Node.js v10 or higher is required for regex lookbehinds');\n }\n\n if ((prev.value === '(' && !/[!=<:]/.test(next)) || (next === '<' && !/<([!=]|\\w+>)/.test(remaining()))) {\n output = `\\\\${value}`;\n }\n\n push({ type: 'text', value, output });\n continue;\n }\n\n if (opts.dot !== true && (prev.type === 'slash' || prev.type === 'bos')) {\n push({ type: 'qmark', value, output: QMARK_NO_DOT });\n continue;\n }\n\n push({ type: 'qmark', value, output: QMARK });\n continue;\n }\n\n /**\n * Exclamation\n */\n\n if (value === '!') {\n if (opts.noextglob !== true && peek() === '(') {\n if (peek(2) !== '?' || !/[!=<:]/.test(peek(3))) {\n extglobOpen('negate', value);\n continue;\n }\n }\n\n if (opts.nonegate !== true && state.index === 0) {\n negate();\n continue;\n }\n }\n\n /**\n * Plus\n */\n\n if (value === '+') {\n if (opts.noextglob !== true && peek() === '(' && peek(2) !== '?') {\n extglobOpen('plus', value);\n continue;\n }\n\n if ((prev && prev.value === '(') || opts.regex === false) {\n push({ type: 'plus', value, output: PLUS_LITERAL });\n continue;\n }\n\n if ((prev && (prev.type === 'bracket' || prev.type === 'paren' || prev.type === 'brace')) || state.parens > 0) {\n push({ type: 'plus', value });\n continue;\n }\n\n push({ type: 'plus', value: PLUS_LITERAL });\n continue;\n }\n\n /**\n * Plain text\n */\n\n if (value === '@') {\n if (opts.noextglob !== true && peek() === '(' && peek(2) !== '?') {\n push({ type: 'at', extglob: true, value, output: '' });\n continue;\n }\n\n push({ type: 'text', value });\n continue;\n }\n\n /**\n * Plain text\n */\n\n if (value !== '*') {\n if (value === '$' || value === '^') {\n value = `\\\\${value}`;\n }\n\n const match = REGEX_NON_SPECIAL_CHARS.exec(remaining());\n if (match) {\n value += match[0];\n state.index += match[0].length;\n }\n\n push({ type: 'text', value });\n continue;\n }\n\n /**\n * Stars\n */\n\n if (prev && (prev.type === 'globstar' || prev.star === true)) {\n prev.type = 'star';\n prev.star = true;\n prev.value += value;\n prev.output = star;\n state.backtrack = true;\n state.globstar = true;\n consume(value);\n continue;\n }\n\n let rest = remaining();\n if (opts.noextglob !== true && /^\\([^?]/.test(rest)) {\n extglobOpen('star', value);\n continue;\n }\n\n if (prev.type === 'star') {\n if (opts.noglobstar === true) {\n consume(value);\n continue;\n }\n\n const prior = prev.prev;\n const before = prior.prev;\n const isStart = prior.type === 'slash' || prior.type === 'bos';\n const afterStar = before && (before.type === 'star' || before.type === 'globstar');\n\n if (opts.bash === true && (!isStart || (rest[0] && rest[0] !== '/'))) {\n push({ type: 'star', value, output: '' });\n continue;\n }\n\n const isBrace = state.braces > 0 && (prior.type === 'comma' || prior.type === 'brace');\n const isExtglob = extglobs.length && (prior.type === 'pipe' || prior.type === 'paren');\n if (!isStart && prior.type !== 'paren' && !isBrace && !isExtglob) {\n push({ type: 'star', value, output: '' });\n continue;\n }\n\n // strip consecutive `/**/`\n while (rest.slice(0, 3) === '/**') {\n const after = input[state.index + 4];\n if (after && after !== '/') {\n break;\n }\n rest = rest.slice(3);\n consume('/**', 3);\n }\n\n if (prior.type === 'bos' && eos()) {\n prev.type = 'globstar';\n prev.value += value;\n prev.output = globstar(opts);\n state.output = prev.output;\n state.globstar = true;\n consume(value);\n continue;\n }\n\n if (prior.type === 'slash' && prior.prev.type !== 'bos' && !afterStar && eos()) {\n state.output = state.output.slice(0, -(prior.output + prev.output).length);\n prior.output = `(?:${prior.output}`;\n\n prev.type = 'globstar';\n prev.output = globstar(opts) + (opts.strictSlashes ? ')' : '|$)');\n prev.value += value;\n state.globstar = true;\n state.output += prior.output + prev.output;\n consume(value);\n continue;\n }\n\n if (prior.type === 'slash' && prior.prev.type !== 'bos' && rest[0] === '/') {\n const end = rest[1] !== void 0 ? '|$' : '';\n\n state.output = state.output.slice(0, -(prior.output + prev.output).length);\n prior.output = `(?:${prior.output}`;\n\n prev.type = 'globstar';\n prev.output = `${globstar(opts)}${SLASH_LITERAL}|${SLASH_LITERAL}${end})`;\n prev.value += value;\n\n state.output += prior.output + prev.output;\n state.globstar = true;\n\n consume(value + advance());\n\n push({ type: 'slash', value: '/', output: '' });\n continue;\n }\n\n if (prior.type === 'bos' && rest[0] === '/') {\n prev.type = 'globstar';\n prev.value += value;\n prev.output = `(?:^|${SLASH_LITERAL}|${globstar(opts)}${SLASH_LITERAL})`;\n state.output = prev.output;\n state.globstar = true;\n consume(value + advance());\n push({ type: 'slash', value: '/', output: '' });\n continue;\n }\n\n // remove single star from output\n state.output = state.output.slice(0, -prev.output.length);\n\n // reset previous token to globstar\n prev.type = 'globstar';\n prev.output = globstar(opts);\n prev.value += value;\n\n // reset output with globstar\n state.output += prev.output;\n state.globstar = true;\n consume(value);\n continue;\n }\n\n const token = { type: 'star', value, output: star };\n\n if (opts.bash === true) {\n token.output = '.*?';\n if (prev.type === 'bos' || prev.type === 'slash') {\n token.output = nodot + token.output;\n }\n push(token);\n continue;\n }\n\n if (prev && (prev.type === 'bracket' || prev.type === 'paren') && opts.regex === true) {\n token.output = value;\n push(token);\n continue;\n }\n\n if (state.index === state.start || prev.type === 'slash' || prev.type === 'dot') {\n if (prev.type === 'dot') {\n state.output += NO_DOT_SLASH;\n prev.output += NO_DOT_SLASH;\n\n } else if (opts.dot === true) {\n state.output += NO_DOTS_SLASH;\n prev.output += NO_DOTS_SLASH;\n\n } else {\n state.output += nodot;\n prev.output += nodot;\n }\n\n if (peek() !== '*') {\n state.output += ONE_CHAR;\n prev.output += ONE_CHAR;\n }\n }\n\n push(token);\n }\n\n while (state.brackets > 0) {\n if (opts.strictBrackets === true) throw new SyntaxError(syntaxError('closing', ']'));\n state.output = utils.escapeLast(state.output, '[');\n decrement('brackets');\n }\n\n while (state.parens > 0) {\n if (opts.strictBrackets === true) throw new SyntaxError(syntaxError('closing', ')'));\n state.output = utils.escapeLast(state.output, '(');\n decrement('parens');\n }\n\n while (state.braces > 0) {\n if (opts.strictBrackets === true) throw new SyntaxError(syntaxError('closing', '}'));\n state.output = utils.escapeLast(state.output, '{');\n decrement('braces');\n }\n\n if (opts.strictSlashes !== true && (prev.type === 'star' || prev.type === 'bracket')) {\n push({ type: 'maybe_slash', value: '', output: `${SLASH_LITERAL}?` });\n }\n\n // rebuild the output if we had to backtrack at any point\n if (state.backtrack === true) {\n state.output = '';\n\n for (const token of state.tokens) {\n state.output += token.output != null ? token.output : token.value;\n\n if (token.suffix) {\n state.output += token.suffix;\n }\n }\n }\n\n return state;\n};\n\n/**\n * Fast paths for creating regular expressions for common glob patterns.\n * This can significantly speed up processing and has very little downside\n * impact when none of the fast paths match.\n */\n\nparse.fastpaths = (input, options) => {\n const opts = { ...options };\n const max = typeof opts.maxLength === 'number' ? Math.min(MAX_LENGTH, opts.maxLength) : MAX_LENGTH;\n const len = input.length;\n if (len > max) {\n throw new SyntaxError(`Input length: ${len}, exceeds maximum allowed length: ${max}`);\n }\n\n input = REPLACEMENTS[input] || input;\n const win32 = utils.isWindows(options);\n\n // create constants based on platform, for windows or posix\n const {\n DOT_LITERAL,\n SLASH_LITERAL,\n ONE_CHAR,\n DOTS_SLASH,\n NO_DOT,\n NO_DOTS,\n NO_DOTS_SLASH,\n STAR,\n START_ANCHOR\n } = constants.globChars(win32);\n\n const nodot = opts.dot ? NO_DOTS : NO_DOT;\n const slashDot = opts.dot ? NO_DOTS_SLASH : NO_DOT;\n const capture = opts.capture ? '' : '?:';\n const state = { negated: false, prefix: '' };\n let star = opts.bash === true ? '.*?' : STAR;\n\n if (opts.capture) {\n star = `(${star})`;\n }\n\n const globstar = opts => {\n if (opts.noglobstar === true) return star;\n return `(${capture}(?:(?!${START_ANCHOR}${opts.dot ? DOTS_SLASH : DOT_LITERAL}).)*?)`;\n };\n\n const create = str => {\n switch (str) {\n case '*':\n return `${nodot}${ONE_CHAR}${star}`;\n\n case '.*':\n return `${DOT_LITERAL}${ONE_CHAR}${star}`;\n\n case '*.*':\n return `${nodot}${star}${DOT_LITERAL}${ONE_CHAR}${star}`;\n\n case '*/*':\n return `${nodot}${star}${SLASH_LITERAL}${ONE_CHAR}${slashDot}${star}`;\n\n case '**':\n return nodot + globstar(opts);\n\n case '**/*':\n return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${slashDot}${ONE_CHAR}${star}`;\n\n case '**/*.*':\n return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${slashDot}${star}${DOT_LITERAL}${ONE_CHAR}${star}`;\n\n case '**/.*':\n return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${DOT_LITERAL}${ONE_CHAR}${star}`;\n\n default: {\n const match = /^(.*?)\\.(\\w+)$/.exec(str);\n if (!match) return;\n\n const source = create(match[1]);\n if (!source) return;\n\n return source + DOT_LITERAL + match[2];\n }\n }\n };\n\n const output = utils.removePrefix(input, state);\n let source = create(output);\n\n if (source && opts.strictSlashes !== true) {\n source += `${SLASH_LITERAL}?`;\n }\n\n return source;\n};\n\nmodule.exports = parse;\n", "'use strict';\n\nconst path = require('path');\nconst scan = require('./scan');\nconst parse = require('./parse');\nconst utils = require('./utils');\nconst constants = require('./constants');\nconst isObject = val => val && typeof val === 'object' && !Array.isArray(val);\n\n/**\n * Creates a matcher function from one or more glob patterns. The\n * returned function takes a string to match as its first argument,\n * and returns true if the string is a match. The returned matcher\n * function also takes a boolean as the second argument that, when true,\n * returns an object with additional information.\n *\n * ```js\n * const picomatch = require('picomatch');\n * // picomatch(glob[, options]);\n *\n * const isMatch = picomatch('*.!(*a)');\n * console.log(isMatch('a.a')); //=> false\n * console.log(isMatch('a.b')); //=> true\n * ```\n * @name picomatch\n * @param {String|Array} `globs` One or more glob patterns.\n * @param {Object=} `options`\n * @return {Function=} Returns a matcher function.\n * @api public\n */\n\nconst picomatch = (glob, options, returnState = false) => {\n if (Array.isArray(glob)) {\n const fns = glob.map(input => picomatch(input, options, returnState));\n const arrayMatcher = str => {\n for (const isMatch of fns) {\n const state = isMatch(str);\n if (state) return state;\n }\n return false;\n };\n return arrayMatcher;\n }\n\n const isState = isObject(glob) && glob.tokens && glob.input;\n\n if (glob === '' || (typeof glob !== 'string' && !isState)) {\n throw new TypeError('Expected pattern to be a non-empty string');\n }\n\n const opts = options || {};\n const posix = utils.isWindows(options);\n const regex = isState\n ? picomatch.compileRe(glob, options)\n : picomatch.makeRe(glob, options, false, true);\n\n const state = regex.state;\n delete regex.state;\n\n let isIgnored = () => false;\n if (opts.ignore) {\n const ignoreOpts = { ...options, ignore: null, onMatch: null, onResult: null };\n isIgnored = picomatch(opts.ignore, ignoreOpts, returnState);\n }\n\n const matcher = (input, returnObject = false) => {\n const { isMatch, match, output } = picomatch.test(input, regex, options, { glob, posix });\n const result = { glob, state, regex, posix, input, output, match, isMatch };\n\n if (typeof opts.onResult === 'function') {\n opts.onResult(result);\n }\n\n if (isMatch === false) {\n result.isMatch = false;\n return returnObject ? result : false;\n }\n\n if (isIgnored(input)) {\n if (typeof opts.onIgnore === 'function') {\n opts.onIgnore(result);\n }\n result.isMatch = false;\n return returnObject ? result : false;\n }\n\n if (typeof opts.onMatch === 'function') {\n opts.onMatch(result);\n }\n return returnObject ? result : true;\n };\n\n if (returnState) {\n matcher.state = state;\n }\n\n return matcher;\n};\n\n/**\n * Test `input` with the given `regex`. This is used by the main\n * `picomatch()` function to test the input string.\n *\n * ```js\n * const picomatch = require('picomatch');\n * // picomatch.test(input, regex[, options]);\n *\n * console.log(picomatch.test('foo/bar', /^(?:([^/]*?)\\/([^/]*?))$/));\n * // { isMatch: true, match: [ 'foo/', 'foo', 'bar' ], output: 'foo/bar' }\n * ```\n * @param {String} `input` String to test.\n * @param {RegExp} `regex`\n * @return {Object} Returns an object with matching info.\n * @api public\n */\n\npicomatch.test = (input, regex, options, { glob, posix } = {}) => {\n if (typeof input !== 'string') {\n throw new TypeError('Expected input to be a string');\n }\n\n if (input === '') {\n return { isMatch: false, output: '' };\n }\n\n const opts = options || {};\n const format = opts.format || (posix ? utils.toPosixSlashes : null);\n let match = input === glob;\n let output = (match && format) ? format(input) : input;\n\n if (match === false) {\n output = format ? format(input) : input;\n match = output === glob;\n }\n\n if (match === false || opts.capture === true) {\n if (opts.matchBase === true || opts.basename === true) {\n match = picomatch.matchBase(input, regex, options, posix);\n } else {\n match = regex.exec(output);\n }\n }\n\n return { isMatch: Boolean(match), match, output };\n};\n\n/**\n * Match the basename of a filepath.\n *\n * ```js\n * const picomatch = require('picomatch');\n * // picomatch.matchBase(input, glob[, options]);\n * console.log(picomatch.matchBase('foo/bar.js', '*.js'); // true\n * ```\n * @param {String} `input` String to test.\n * @param {RegExp|String} `glob` Glob pattern or regex created by [.makeRe](#makeRe).\n * @return {Boolean}\n * @api public\n */\n\npicomatch.matchBase = (input, glob, options, posix = utils.isWindows(options)) => {\n const regex = glob instanceof RegExp ? glob : picomatch.makeRe(glob, options);\n return regex.test(path.basename(input));\n};\n\n/**\n * Returns true if **any** of the given glob `patterns` match the specified `string`.\n *\n * ```js\n * const picomatch = require('picomatch');\n * // picomatch.isMatch(string, patterns[, options]);\n *\n * console.log(picomatch.isMatch('a.a', ['b.*', '*.a'])); //=> true\n * console.log(picomatch.isMatch('a.a', 'b.*')); //=> false\n * ```\n * @param {String|Array} str The string to test.\n * @param {String|Array} patterns One or more glob patterns to use for matching.\n * @param {Object} [options] See available [options](#options).\n * @return {Boolean} Returns true if any patterns match `str`\n * @api public\n */\n\npicomatch.isMatch = (str, patterns, options) => picomatch(patterns, options)(str);\n\n/**\n * Parse a glob pattern to create the source string for a regular\n * expression.\n *\n * ```js\n * const picomatch = require('picomatch');\n * const result = picomatch.parse(pattern[, options]);\n * ```\n * @param {String} `pattern`\n * @param {Object} `options`\n * @return {Object} Returns an object with useful properties and output to be used as a regex source string.\n * @api public\n */\n\npicomatch.parse = (pattern, options) => {\n if (Array.isArray(pattern)) return pattern.map(p => picomatch.parse(p, options));\n return parse(pattern, { ...options, fastpaths: false });\n};\n\n/**\n * Scan a glob pattern to separate the pattern into segments.\n *\n * ```js\n * const picomatch = require('picomatch');\n * // picomatch.scan(input[, options]);\n *\n * const result = picomatch.scan('!./foo/*.js');\n * console.log(result);\n * { prefix: '!./',\n * input: '!./foo/*.js',\n * start: 3,\n * base: 'foo',\n * glob: '*.js',\n * isBrace: false,\n * isBracket: false,\n * isGlob: true,\n * isExtglob: false,\n * isGlobstar: false,\n * negated: true }\n * ```\n * @param {String} `input` Glob pattern to scan.\n * @param {Object} `options`\n * @return {Object} Returns an object with\n * @api public\n */\n\npicomatch.scan = (input, options) => scan(input, options);\n\n/**\n * Compile a regular expression from the `state` object returned by the\n * [parse()](#parse) method.\n *\n * @param {Object} `state`\n * @param {Object} `options`\n * @param {Boolean} `returnOutput` Intended for implementors, this argument allows you to return the raw output from the parser.\n * @param {Boolean} `returnState` Adds the state to a `state` property on the returned regex. Useful for implementors and debugging.\n * @return {RegExp}\n * @api public\n */\n\npicomatch.compileRe = (state, options, returnOutput = false, returnState = false) => {\n if (returnOutput === true) {\n return state.output;\n }\n\n const opts = options || {};\n const prepend = opts.contains ? '' : '^';\n const append = opts.contains ? '' : '$';\n\n let source = `${prepend}(?:${state.output})${append}`;\n if (state && state.negated === true) {\n source = `^(?!${source}).*$`;\n }\n\n const regex = picomatch.toRegex(source, options);\n if (returnState === true) {\n regex.state = state;\n }\n\n return regex;\n};\n\n/**\n * Create a regular expression from a parsed glob pattern.\n *\n * ```js\n * const picomatch = require('picomatch');\n * const state = picomatch.parse('*.js');\n * // picomatch.compileRe(state[, options]);\n *\n * console.log(picomatch.compileRe(state));\n * //=> /^(?:(?!\\.)(?=.)[^/]*?\\.js)$/\n * ```\n * @param {String} `state` The object returned from the `.parse` method.\n * @param {Object} `options`\n * @param {Boolean} `returnOutput` Implementors may use this argument to return the compiled output, instead of a regular expression. This is not exposed on the options to prevent end-users from mutating the result.\n * @param {Boolean} `returnState` Implementors may use this argument to return the state from the parsed glob with the returned regular expression.\n * @return {RegExp} Returns a regex created from the given pattern.\n * @api public\n */\n\npicomatch.makeRe = (input, options = {}, returnOutput = false, returnState = false) => {\n if (!input || typeof input !== 'string') {\n throw new TypeError('Expected a non-empty string');\n }\n\n let parsed = { negated: false, fastpaths: true };\n\n if (options.fastpaths !== false && (input[0] === '.' || input[0] === '*')) {\n parsed.output = parse.fastpaths(input, options);\n }\n\n if (!parsed.output) {\n parsed = parse(input, options);\n }\n\n return picomatch.compileRe(parsed, options, returnOutput, returnState);\n};\n\n/**\n * Create a regular expression from the given regex source string.\n *\n * ```js\n * const picomatch = require('picomatch');\n * // picomatch.toRegex(source[, options]);\n *\n * const { output } = picomatch.parse('*.js');\n * console.log(picomatch.toRegex(output));\n * //=> /^(?:(?!\\.)(?=.)[^/]*?\\.js)$/\n * ```\n * @param {String} `source` Regular expression source string.\n * @param {Object} `options`\n * @return {RegExp}\n * @api public\n */\n\npicomatch.toRegex = (source, options) => {\n try {\n const opts = options || {};\n return new RegExp(source, opts.flags || (opts.nocase ? 'i' : ''));\n } catch (err) {\n if (options && options.debug === true) throw err;\n return /$^/;\n }\n};\n\n/**\n * Picomatch constants.\n * @return {Object}\n */\n\npicomatch.constants = constants;\n\n/**\n * Expose \"picomatch\"\n */\n\nmodule.exports = picomatch;\n", "'use strict';\n\nmodule.exports = require('./lib/picomatch');\n", "'use strict';\n\nconst util = require('util');\nconst braces = require('braces');\nconst picomatch = require('picomatch');\nconst utils = require('picomatch/lib/utils');\nconst isEmptyString = val => val === '' || val === './';\n\n/**\n * Returns an array of strings that match one or more glob patterns.\n *\n * ```js\n * const mm = require('micromatch');\n * // mm(list, patterns[, options]);\n *\n * console.log(mm(['a.js', 'a.txt'], ['*.js']));\n * //=> [ 'a.js' ]\n * ```\n * @param {String|Array} `list` List of strings to match.\n * @param {String|Array} `patterns` One or more glob patterns to use for matching.\n * @param {Object} `options` See available [options](#options)\n * @return {Array} Returns an array of matches\n * @summary false\n * @api public\n */\n\nconst micromatch = (list, patterns, options) => {\n patterns = [].concat(patterns);\n list = [].concat(list);\n\n let omit = new Set();\n let keep = new Set();\n let items = new Set();\n let negatives = 0;\n\n let onResult = state => {\n items.add(state.output);\n if (options && options.onResult) {\n options.onResult(state);\n }\n };\n\n for (let i = 0; i < patterns.length; i++) {\n let isMatch = picomatch(String(patterns[i]), { ...options, onResult }, true);\n let negated = isMatch.state.negated || isMatch.state.negatedExtglob;\n if (negated) negatives++;\n\n for (let item of list) {\n let matched = isMatch(item, true);\n\n let match = negated ? !matched.isMatch : matched.isMatch;\n if (!match) continue;\n\n if (negated) {\n omit.add(matched.output);\n } else {\n omit.delete(matched.output);\n keep.add(matched.output);\n }\n }\n }\n\n let result = negatives === patterns.length ? [...items] : [...keep];\n let matches = result.filter(item => !omit.has(item));\n\n if (options && matches.length === 0) {\n if (options.failglob === true) {\n throw new Error(`No matches found for \"${patterns.join(', ')}\"`);\n }\n\n if (options.nonull === true || options.nullglob === true) {\n return options.unescape ? patterns.map(p => p.replace(/\\\\/g, '')) : patterns;\n }\n }\n\n return matches;\n};\n\n/**\n * Backwards compatibility\n */\n\nmicromatch.match = micromatch;\n\n/**\n * Returns a matcher function from the given glob `pattern` and `options`.\n * The returned function takes a string to match as its only argument and returns\n * true if the string is a match.\n *\n * ```js\n * const mm = require('micromatch');\n * // mm.matcher(pattern[, options]);\n *\n * const isMatch = mm.matcher('*.!(*a)');\n * console.log(isMatch('a.a')); //=> false\n * console.log(isMatch('a.b')); //=> true\n * ```\n * @param {String} `pattern` Glob pattern\n * @param {Object} `options`\n * @return {Function} Returns a matcher function.\n * @api public\n */\n\nmicromatch.matcher = (pattern, options) => picomatch(pattern, options);\n\n/**\n * Returns true if **any** of the given glob `patterns` match the specified `string`.\n *\n * ```js\n * const mm = require('micromatch');\n * // mm.isMatch(string, patterns[, options]);\n *\n * console.log(mm.isMatch('a.a', ['b.*', '*.a'])); //=> true\n * console.log(mm.isMatch('a.a', 'b.*')); //=> false\n * ```\n * @param {String} `str` The string to test.\n * @param {String|Array} `patterns` One or more glob patterns to use for matching.\n * @param {Object} `[options]` See available [options](#options).\n * @return {Boolean} Returns true if any patterns match `str`\n * @api public\n */\n\nmicromatch.isMatch = (str, patterns, options) => picomatch(patterns, options)(str);\n\n/**\n * Backwards compatibility\n */\n\nmicromatch.any = micromatch.isMatch;\n\n/**\n * Returns a list of strings that _**do not match any**_ of the given `patterns`.\n *\n * ```js\n * const mm = require('micromatch');\n * // mm.not(list, patterns[, options]);\n *\n * console.log(mm.not(['a.a', 'b.b', 'c.c'], '*.a'));\n * //=> ['b.b', 'c.c']\n * ```\n * @param {Array} `list` Array of strings to match.\n * @param {String|Array} `patterns` One or more glob pattern to use for matching.\n * @param {Object} `options` See available [options](#options) for changing how matches are performed\n * @return {Array} Returns an array of strings that **do not match** the given patterns.\n * @api public\n */\n\nmicromatch.not = (list, patterns, options = {}) => {\n patterns = [].concat(patterns).map(String);\n let result = new Set();\n let items = [];\n\n let onResult = state => {\n if (options.onResult) options.onResult(state);\n items.push(state.output);\n };\n\n let matches = micromatch(list, patterns, { ...options, onResult });\n\n for (let item of items) {\n if (!matches.includes(item)) {\n result.add(item);\n }\n }\n return [...result];\n};\n\n/**\n * Returns true if the given `string` contains the given pattern. Similar\n * to [.isMatch](#isMatch) but the pattern can match any part of the string.\n *\n * ```js\n * var mm = require('micromatch');\n * // mm.contains(string, pattern[, options]);\n *\n * console.log(mm.contains('aa/bb/cc', '*b'));\n * //=> true\n * console.log(mm.contains('aa/bb/cc', '*d'));\n * //=> false\n * ```\n * @param {String} `str` The string to match.\n * @param {String|Array} `patterns` Glob pattern to use for matching.\n * @param {Object} `options` See available [options](#options) for changing how matches are performed\n * @return {Boolean} Returns true if any of the patterns matches any part of `str`.\n * @api public\n */\n\nmicromatch.contains = (str, pattern, options) => {\n if (typeof str !== 'string') {\n throw new TypeError(`Expected a string: \"${util.inspect(str)}\"`);\n }\n\n if (Array.isArray(pattern)) {\n return pattern.some(p => micromatch.contains(str, p, options));\n }\n\n if (typeof pattern === 'string') {\n if (isEmptyString(str) || isEmptyString(pattern)) {\n return false;\n }\n\n if (str.includes(pattern) || (str.startsWith('./') && str.slice(2).includes(pattern))) {\n return true;\n }\n }\n\n return micromatch.isMatch(str, pattern, { ...options, contains: true });\n};\n\n/**\n * Filter the keys of the given object with the given `glob` pattern\n * and `options`. Does not attempt to match nested keys. If you need this feature,\n * use [glob-object][] instead.\n *\n * ```js\n * const mm = require('micromatch');\n * // mm.matchKeys(object, patterns[, options]);\n *\n * const obj = { aa: 'a', ab: 'b', ac: 'c' };\n * console.log(mm.matchKeys(obj, '*b'));\n * //=> { ab: 'b' }\n * ```\n * @param {Object} `object` The object with keys to filter.\n * @param {String|Array} `patterns` One or more glob patterns to use for matching.\n * @param {Object} `options` See available [options](#options) for changing how matches are performed\n * @return {Object} Returns an object with only keys that match the given patterns.\n * @api public\n */\n\nmicromatch.matchKeys = (obj, patterns, options) => {\n if (!utils.isObject(obj)) {\n throw new TypeError('Expected the first argument to be an object');\n }\n let keys = micromatch(Object.keys(obj), patterns, options);\n let res = {};\n for (let key of keys) res[key] = obj[key];\n return res;\n};\n\n/**\n * Returns true if some of the strings in the given `list` match any of the given glob `patterns`.\n *\n * ```js\n * const mm = require('micromatch');\n * // mm.some(list, patterns[, options]);\n *\n * console.log(mm.some(['foo.js', 'bar.js'], ['*.js', '!foo.js']));\n * // true\n * console.log(mm.some(['foo.js'], ['*.js', '!foo.js']));\n * // false\n * ```\n * @param {String|Array} `list` The string or array of strings to test. Returns as soon as the first match is found.\n * @param {String|Array} `patterns` One or more glob patterns to use for matching.\n * @param {Object} `options` See available [options](#options) for changing how matches are performed\n * @return {Boolean} Returns true if any `patterns` matches any of the strings in `list`\n * @api public\n */\n\nmicromatch.some = (list, patterns, options) => {\n let items = [].concat(list);\n\n for (let pattern of [].concat(patterns)) {\n let isMatch = picomatch(String(pattern), options);\n if (items.some(item => isMatch(item))) {\n return true;\n }\n }\n return false;\n};\n\n/**\n * Returns true if every string in the given `list` matches\n * any of the given glob `patterns`.\n *\n * ```js\n * const mm = require('micromatch');\n * // mm.every(list, patterns[, options]);\n *\n * console.log(mm.every('foo.js', ['foo.js']));\n * // true\n * console.log(mm.every(['foo.js', 'bar.js'], ['*.js']));\n * // true\n * console.log(mm.every(['foo.js', 'bar.js'], ['*.js', '!foo.js']));\n * // false\n * console.log(mm.every(['foo.js'], ['*.js', '!foo.js']));\n * // false\n * ```\n * @param {String|Array} `list` The string or array of strings to test.\n * @param {String|Array} `patterns` One or more glob patterns to use for matching.\n * @param {Object} `options` See available [options](#options) for changing how matches are performed\n * @return {Boolean} Returns true if all `patterns` matches all of the strings in `list`\n * @api public\n */\n\nmicromatch.every = (list, patterns, options) => {\n let items = [].concat(list);\n\n for (let pattern of [].concat(patterns)) {\n let isMatch = picomatch(String(pattern), options);\n if (!items.every(item => isMatch(item))) {\n return false;\n }\n }\n return true;\n};\n\n/**\n * Returns true if **all** of the given `patterns` match\n * the specified string.\n *\n * ```js\n * const mm = require('micromatch');\n * // mm.all(string, patterns[, options]);\n *\n * console.log(mm.all('foo.js', ['foo.js']));\n * // true\n *\n * console.log(mm.all('foo.js', ['*.js', '!foo.js']));\n * // false\n *\n * console.log(mm.all('foo.js', ['*.js', 'foo.js']));\n * // true\n *\n * console.log(mm.all('foo.js', ['*.js', 'f*', '*o*', '*o.js']));\n * // true\n * ```\n * @param {String|Array} `str` The string to test.\n * @param {String|Array} `patterns` One or more glob patterns to use for matching.\n * @param {Object} `options` See available [options](#options) for changing how matches are performed\n * @return {Boolean} Returns true if any patterns match `str`\n * @api public\n */\n\nmicromatch.all = (str, patterns, options) => {\n if (typeof str !== 'string') {\n throw new TypeError(`Expected a string: \"${util.inspect(str)}\"`);\n }\n\n return [].concat(patterns).every(p => picomatch(p, options)(str));\n};\n\n/**\n * Returns an array of matches captured by `pattern` in `string, or `null` if the pattern did not match.\n *\n * ```js\n * const mm = require('micromatch');\n * // mm.capture(pattern, string[, options]);\n *\n * console.log(mm.capture('test/*.js', 'test/foo.js'));\n * //=> ['foo']\n * console.log(mm.capture('test/*.js', 'foo/bar.css'));\n * //=> null\n * ```\n * @param {String} `glob` Glob pattern to use for matching.\n * @param {String} `input` String to match\n * @param {Object} `options` See available [options](#options) for changing how matches are performed\n * @return {Array|null} Returns an array of captures if the input matches the glob pattern, otherwise `null`.\n * @api public\n */\n\nmicromatch.capture = (glob, input, options) => {\n let posix = utils.isWindows(options);\n let regex = picomatch.makeRe(String(glob), { ...options, capture: true });\n let match = regex.exec(posix ? utils.toPosixSlashes(input) : input);\n\n if (match) {\n return match.slice(1).map(v => v === void 0 ? '' : v);\n }\n};\n\n/**\n * Create a regular expression from the given glob `pattern`.\n *\n * ```js\n * const mm = require('micromatch');\n * // mm.makeRe(pattern[, options]);\n *\n * console.log(mm.makeRe('*.js'));\n * //=> /^(?:(\\.[\\\\\\/])?(?!\\.)(?=.)[^\\/]*?\\.js)$/\n * ```\n * @param {String} `pattern` A glob pattern to convert to regex.\n * @param {Object} `options`\n * @return {RegExp} Returns a regex created from the given pattern.\n * @api public\n */\n\nmicromatch.makeRe = (...args) => picomatch.makeRe(...args);\n\n/**\n * Scan a glob pattern to separate the pattern into segments. Used\n * by the [split](#split) method.\n *\n * ```js\n * const mm = require('micromatch');\n * const state = mm.scan(pattern[, options]);\n * ```\n * @param {String} `pattern`\n * @param {Object} `options`\n * @return {Object} Returns an object with\n * @api public\n */\n\nmicromatch.scan = (...args) => picomatch.scan(...args);\n\n/**\n * Parse a glob pattern to create the source string for a regular\n * expression.\n *\n * ```js\n * const mm = require('micromatch');\n * const state = mm(pattern[, options]);\n * ```\n * @param {String} `glob`\n * @param {Object} `options`\n * @return {Object} Returns an object with useful properties and output to be used as regex source string.\n * @api public\n */\n\nmicromatch.parse = (patterns, options) => {\n let res = [];\n for (let pattern of [].concat(patterns || [])) {\n for (let str of braces(String(pattern), options)) {\n res.push(picomatch.parse(str, options));\n }\n }\n return res;\n};\n\n/**\n * Process the given brace `pattern`.\n *\n * ```js\n * const { braces } = require('micromatch');\n * console.log(braces('foo/{a,b,c}/bar'));\n * //=> [ 'foo/(a|b|c)/bar' ]\n *\n * console.log(braces('foo/{a,b,c}/bar', { expand: true }));\n * //=> [ 'foo/a/bar', 'foo/b/bar', 'foo/c/bar' ]\n * ```\n * @param {String} `pattern` String with brace pattern to process.\n * @param {Object} `options` Any [options](#options) to change how expansion is performed. See the [braces][] library for all available options.\n * @return {Array}\n * @api public\n */\n\nmicromatch.braces = (pattern, options) => {\n if (typeof pattern !== 'string') throw new TypeError('Expected a string');\n if ((options && options.nobrace === true) || !/\\{.*\\}/.test(pattern)) {\n return [pattern];\n }\n return braces(pattern, options);\n};\n\n/**\n * Expand braces\n */\n\nmicromatch.braceExpand = (pattern, options) => {\n if (typeof pattern !== 'string') throw new TypeError('Expected a string');\n return micromatch.braces(pattern, { ...options, expand: true });\n};\n\n/**\n * Expose micromatch\n */\n\nmodule.exports = micromatch;\n", "/*!\n * repeat-string \n *\n * Copyright (c) 2014-2015, Jon Schlinkert.\n * Licensed under the MIT License.\n */\n\n'use strict';\n\n/**\n * Results cache\n */\n\nvar res = '';\nvar cache;\n\n/**\n * Expose `repeat`\n */\n\nmodule.exports = repeat;\n\n/**\n * Repeat the given `string` the specified `number`\n * of times.\n *\n * **Example:**\n *\n * ```js\n * var repeat = require('repeat-string');\n * repeat('A', 5);\n * //=> AAAAA\n * ```\n *\n * @param {String} `string` The string to repeat\n * @param {Number} `number` The number of times to repeat the string\n * @return {String} Repeated string\n * @api public\n */\n\nfunction repeat(str, num) {\n if (typeof str !== 'string') {\n throw new TypeError('expected a string');\n }\n\n // cover common, quick use cases\n if (num === 1) return str;\n if (num === 2) return str + str;\n\n var max = str.length * num;\n if (cache !== str || typeof cache === 'undefined') {\n cache = str;\n res = '';\n } else if (res.length >= max) {\n return res.substr(0, max);\n }\n\n while (max > res.length && num > 1) {\n if (num & 1) {\n res += str;\n }\n\n num >>= 1;\n str += str;\n }\n\n res += str;\n res = res.substr(0, max);\n return res;\n}\n", "'use strict'\n\nvar repeat = require('repeat-string')\n\nmodule.exports = markdownTable\n\nvar trailingWhitespace = / +$/\n\n// Characters.\nvar space = ' '\nvar lineFeed = '\\n'\nvar dash = '-'\nvar colon = ':'\nvar verticalBar = '|'\n\nvar x = 0\nvar C = 67\nvar L = 76\nvar R = 82\nvar c = 99\nvar l = 108\nvar r = 114\n\n// Create a table from a matrix of strings.\nfunction markdownTable(table, options) {\n var settings = options || {}\n var padding = settings.padding !== false\n var start = settings.delimiterStart !== false\n var end = settings.delimiterEnd !== false\n var align = (settings.align || []).concat()\n var alignDelimiters = settings.alignDelimiters !== false\n var alignments = []\n var stringLength = settings.stringLength || defaultStringLength\n var rowIndex = -1\n var rowLength = table.length\n var cellMatrix = []\n var sizeMatrix = []\n var row = []\n var sizes = []\n var longestCellByColumn = []\n var mostCellsPerRow = 0\n var cells\n var columnIndex\n var columnLength\n var largest\n var size\n var cell\n var lines\n var line\n var before\n var after\n var code\n\n // This is a superfluous loop if we don\u2019t align delimiters, but otherwise we\u2019d\n // do superfluous work when aligning, so optimize for aligning.\n while (++rowIndex < rowLength) {\n cells = table[rowIndex]\n columnIndex = -1\n columnLength = cells.length\n row = []\n sizes = []\n\n if (columnLength > mostCellsPerRow) {\n mostCellsPerRow = columnLength\n }\n\n while (++columnIndex < columnLength) {\n cell = serialize(cells[columnIndex])\n\n if (alignDelimiters === true) {\n size = stringLength(cell)\n sizes[columnIndex] = size\n\n largest = longestCellByColumn[columnIndex]\n\n if (largest === undefined || size > largest) {\n longestCellByColumn[columnIndex] = size\n }\n }\n\n row.push(cell)\n }\n\n cellMatrix[rowIndex] = row\n sizeMatrix[rowIndex] = sizes\n }\n\n // Figure out which alignments to use.\n columnIndex = -1\n columnLength = mostCellsPerRow\n\n if (typeof align === 'object' && 'length' in align) {\n while (++columnIndex < columnLength) {\n alignments[columnIndex] = toAlignment(align[columnIndex])\n }\n } else {\n code = toAlignment(align)\n\n while (++columnIndex < columnLength) {\n alignments[columnIndex] = code\n }\n }\n\n // Inject the alignment row.\n columnIndex = -1\n columnLength = mostCellsPerRow\n row = []\n sizes = []\n\n while (++columnIndex < columnLength) {\n code = alignments[columnIndex]\n before = ''\n after = ''\n\n if (code === l) {\n before = colon\n } else if (code === r) {\n after = colon\n } else if (code === c) {\n before = colon\n after = colon\n }\n\n // There *must* be at least one hyphen-minus in each alignment cell.\n size = alignDelimiters\n ? Math.max(\n 1,\n longestCellByColumn[columnIndex] - before.length - after.length\n )\n : 1\n\n cell = before + repeat(dash, size) + after\n\n if (alignDelimiters === true) {\n size = before.length + size + after.length\n\n if (size > longestCellByColumn[columnIndex]) {\n longestCellByColumn[columnIndex] = size\n }\n\n sizes[columnIndex] = size\n }\n\n row[columnIndex] = cell\n }\n\n // Inject the alignment row.\n cellMatrix.splice(1, 0, row)\n sizeMatrix.splice(1, 0, sizes)\n\n rowIndex = -1\n rowLength = cellMatrix.length\n lines = []\n\n while (++rowIndex < rowLength) {\n row = cellMatrix[rowIndex]\n sizes = sizeMatrix[rowIndex]\n columnIndex = -1\n columnLength = mostCellsPerRow\n line = []\n\n while (++columnIndex < columnLength) {\n cell = row[columnIndex] || ''\n before = ''\n after = ''\n\n if (alignDelimiters === true) {\n size = longestCellByColumn[columnIndex] - (sizes[columnIndex] || 0)\n code = alignments[columnIndex]\n\n if (code === r) {\n before = repeat(space, size)\n } else if (code === c) {\n if (size % 2 === 0) {\n before = repeat(space, size / 2)\n after = before\n } else {\n before = repeat(space, size / 2 + 0.5)\n after = repeat(space, size / 2 - 0.5)\n }\n } else {\n after = repeat(space, size)\n }\n }\n\n if (start === true && columnIndex === 0) {\n line.push(verticalBar)\n }\n\n if (\n padding === true &&\n // Don\u2019t add the opening space if we\u2019re not aligning and the cell is\n // empty: there will be a closing space.\n !(alignDelimiters === false && cell === '') &&\n (start === true || columnIndex !== 0)\n ) {\n line.push(space)\n }\n\n if (alignDelimiters === true) {\n line.push(before)\n }\n\n line.push(cell)\n\n if (alignDelimiters === true) {\n line.push(after)\n }\n\n if (padding === true) {\n line.push(space)\n }\n\n if (end === true || columnIndex !== columnLength - 1) {\n line.push(verticalBar)\n }\n }\n\n line = line.join('')\n\n if (end === false) {\n line = line.replace(trailingWhitespace, '')\n }\n\n lines.push(line)\n }\n\n return lines.join(lineFeed)\n}\n\nfunction serialize(value) {\n return value === null || value === undefined ? '' : String(value)\n}\n\nfunction defaultStringLength(value) {\n return value.length\n}\n\nfunction toAlignment(value) {\n var code = typeof value === 'string' ? value.charCodeAt(0) : x\n\n return code === L || code === l\n ? l\n : code === R || code === r\n ? r\n : code === C || code === c\n ? c\n : x\n}\n", "'use strict'\n\nexports.fromCallback = function (fn) {\n return Object.defineProperty(function (...args) {\n if (typeof args[args.length - 1] === 'function') fn.apply(this, args)\n else {\n return new Promise((resolve, reject) => {\n fn.call(\n this,\n ...args,\n (err, res) => (err != null) ? reject(err) : resolve(res)\n )\n })\n }\n }, 'name', { value: fn.name })\n}\n\nexports.fromPromise = function (fn) {\n return Object.defineProperty(function (...args) {\n const cb = args[args.length - 1]\n if (typeof cb !== 'function') return fn.apply(this, args)\n else fn.apply(this, args.slice(0, -1)).then(r => cb(null, r), cb)\n }, 'name', { value: fn.name })\n}\n", "var constants = require('constants')\n\nvar origCwd = process.cwd\nvar cwd = null\n\nvar platform = process.env.GRACEFUL_FS_PLATFORM || process.platform\n\nprocess.cwd = function() {\n if (!cwd)\n cwd = origCwd.call(process)\n return cwd\n}\ntry {\n process.cwd()\n} catch (er) {}\n\nvar chdir = process.chdir\nprocess.chdir = function(d) {\n cwd = null\n chdir.call(process, d)\n}\n\nmodule.exports = patch\n\nfunction patch (fs) {\n // (re-)implement some things that are known busted or missing.\n\n // lchmod, broken prior to 0.6.2\n // back-port the fix here.\n if (constants.hasOwnProperty('O_SYMLINK') &&\n process.version.match(/^v0\\.6\\.[0-2]|^v0\\.5\\./)) {\n patchLchmod(fs)\n }\n\n // lutimes implementation, or no-op\n if (!fs.lutimes) {\n patchLutimes(fs)\n }\n\n // https://github.com/isaacs/node-graceful-fs/issues/4\n // Chown should not fail on einval or eperm if non-root.\n // It should not fail on enosys ever, as this just indicates\n // that a fs doesn't support the intended operation.\n\n fs.chown = chownFix(fs.chown)\n fs.fchown = chownFix(fs.fchown)\n fs.lchown = chownFix(fs.lchown)\n\n fs.chmod = chmodFix(fs.chmod)\n fs.fchmod = chmodFix(fs.fchmod)\n fs.lchmod = chmodFix(fs.lchmod)\n\n fs.chownSync = chownFixSync(fs.chownSync)\n fs.fchownSync = chownFixSync(fs.fchownSync)\n fs.lchownSync = chownFixSync(fs.lchownSync)\n\n fs.chmodSync = chmodFixSync(fs.chmodSync)\n fs.fchmodSync = chmodFixSync(fs.fchmodSync)\n fs.lchmodSync = chmodFixSync(fs.lchmodSync)\n\n fs.stat = statFix(fs.stat)\n fs.fstat = statFix(fs.fstat)\n fs.lstat = statFix(fs.lstat)\n\n fs.statSync = statFixSync(fs.statSync)\n fs.fstatSync = statFixSync(fs.fstatSync)\n fs.lstatSync = statFixSync(fs.lstatSync)\n\n // if lchmod/lchown do not exist, then make them no-ops\n if (!fs.lchmod) {\n fs.lchmod = function (path, mode, cb) {\n if (cb) process.nextTick(cb)\n }\n fs.lchmodSync = function () {}\n }\n if (!fs.lchown) {\n fs.lchown = function (path, uid, gid, cb) {\n if (cb) process.nextTick(cb)\n }\n fs.lchownSync = function () {}\n }\n\n // on Windows, A/V software can lock the directory, causing this\n // to fail with an EACCES or EPERM if the directory contains newly\n // created files. Try again on failure, for up to 60 seconds.\n\n // Set the timeout this long because some Windows Anti-Virus, such as Parity\n // bit9, may lock files for up to a minute, causing npm package install\n // failures. Also, take care to yield the scheduler. Windows scheduling gives\n // CPU to a busy looping process, which can cause the program causing the lock\n // contention to be starved of CPU by node, so the contention doesn't resolve.\n if (platform === \"win32\") {\n fs.rename = (function (fs$rename) { return function (from, to, cb) {\n var start = Date.now()\n var backoff = 0;\n fs$rename(from, to, function CB (er) {\n if (er\n && (er.code === \"EACCES\" || er.code === \"EPERM\")\n && Date.now() - start < 60000) {\n setTimeout(function() {\n fs.stat(to, function (stater, st) {\n if (stater && stater.code === \"ENOENT\")\n fs$rename(from, to, CB);\n else\n cb(er)\n })\n }, backoff)\n if (backoff < 100)\n backoff += 10;\n return;\n }\n if (cb) cb(er)\n })\n }})(fs.rename)\n }\n\n // if read() returns EAGAIN, then just try it again.\n fs.read = (function (fs$read) {\n function read (fd, buffer, offset, length, position, callback_) {\n var callback\n if (callback_ && typeof callback_ === 'function') {\n var eagCounter = 0\n callback = function (er, _, __) {\n if (er && er.code === 'EAGAIN' && eagCounter < 10) {\n eagCounter ++\n return fs$read.call(fs, fd, buffer, offset, length, position, callback)\n }\n callback_.apply(this, arguments)\n }\n }\n return fs$read.call(fs, fd, buffer, offset, length, position, callback)\n }\n\n // This ensures `util.promisify` works as it does for native `fs.read`.\n read.__proto__ = fs$read\n return read\n })(fs.read)\n\n fs.readSync = (function (fs$readSync) { return function (fd, buffer, offset, length, position) {\n var eagCounter = 0\n while (true) {\n try {\n return fs$readSync.call(fs, fd, buffer, offset, length, position)\n } catch (er) {\n if (er.code === 'EAGAIN' && eagCounter < 10) {\n eagCounter ++\n continue\n }\n throw er\n }\n }\n }})(fs.readSync)\n\n function patchLchmod (fs) {\n fs.lchmod = function (path, mode, callback) {\n fs.open( path\n , constants.O_WRONLY | constants.O_SYMLINK\n , mode\n , function (err, fd) {\n if (err) {\n if (callback) callback(err)\n return\n }\n // prefer to return the chmod error, if one occurs,\n // but still try to close, and report closing errors if they occur.\n fs.fchmod(fd, mode, function (err) {\n fs.close(fd, function(err2) {\n if (callback) callback(err || err2)\n })\n })\n })\n }\n\n fs.lchmodSync = function (path, mode) {\n var fd = fs.openSync(path, constants.O_WRONLY | constants.O_SYMLINK, mode)\n\n // prefer to return the chmod error, if one occurs,\n // but still try to close, and report closing errors if they occur.\n var threw = true\n var ret\n try {\n ret = fs.fchmodSync(fd, mode)\n threw = false\n } finally {\n if (threw) {\n try {\n fs.closeSync(fd)\n } catch (er) {}\n } else {\n fs.closeSync(fd)\n }\n }\n return ret\n }\n }\n\n function patchLutimes (fs) {\n if (constants.hasOwnProperty(\"O_SYMLINK\")) {\n fs.lutimes = function (path, at, mt, cb) {\n fs.open(path, constants.O_SYMLINK, function (er, fd) {\n if (er) {\n if (cb) cb(er)\n return\n }\n fs.futimes(fd, at, mt, function (er) {\n fs.close(fd, function (er2) {\n if (cb) cb(er || er2)\n })\n })\n })\n }\n\n fs.lutimesSync = function (path, at, mt) {\n var fd = fs.openSync(path, constants.O_SYMLINK)\n var ret\n var threw = true\n try {\n ret = fs.futimesSync(fd, at, mt)\n threw = false\n } finally {\n if (threw) {\n try {\n fs.closeSync(fd)\n } catch (er) {}\n } else {\n fs.closeSync(fd)\n }\n }\n return ret\n }\n\n } else {\n fs.lutimes = function (_a, _b, _c, cb) { if (cb) process.nextTick(cb) }\n fs.lutimesSync = function () {}\n }\n }\n\n function chmodFix (orig) {\n if (!orig) return orig\n return function (target, mode, cb) {\n return orig.call(fs, target, mode, function (er) {\n if (chownErOk(er)) er = null\n if (cb) cb.apply(this, arguments)\n })\n }\n }\n\n function chmodFixSync (orig) {\n if (!orig) return orig\n return function (target, mode) {\n try {\n return orig.call(fs, target, mode)\n } catch (er) {\n if (!chownErOk(er)) throw er\n }\n }\n }\n\n\n function chownFix (orig) {\n if (!orig) return orig\n return function (target, uid, gid, cb) {\n return orig.call(fs, target, uid, gid, function (er) {\n if (chownErOk(er)) er = null\n if (cb) cb.apply(this, arguments)\n })\n }\n }\n\n function chownFixSync (orig) {\n if (!orig) return orig\n return function (target, uid, gid) {\n try {\n return orig.call(fs, target, uid, gid)\n } catch (er) {\n if (!chownErOk(er)) throw er\n }\n }\n }\n\n function statFix (orig) {\n if (!orig) return orig\n // Older versions of Node erroneously returned signed integers for\n // uid + gid.\n return function (target, options, cb) {\n if (typeof options === 'function') {\n cb = options\n options = null\n }\n function callback (er, stats) {\n if (stats) {\n if (stats.uid < 0) stats.uid += 0x100000000\n if (stats.gid < 0) stats.gid += 0x100000000\n }\n if (cb) cb.apply(this, arguments)\n }\n return options ? orig.call(fs, target, options, callback)\n : orig.call(fs, target, callback)\n }\n }\n\n function statFixSync (orig) {\n if (!orig) return orig\n // Older versions of Node erroneously returned signed integers for\n // uid + gid.\n return function (target, options) {\n var stats = options ? orig.call(fs, target, options)\n : orig.call(fs, target)\n if (stats.uid < 0) stats.uid += 0x100000000\n if (stats.gid < 0) stats.gid += 0x100000000\n return stats;\n }\n }\n\n // ENOSYS means that the fs doesn't support the op. Just ignore\n // that, because it doesn't matter.\n //\n // if there's no getuid, or if getuid() is something other\n // than 0, and the error is EINVAL or EPERM, then just ignore\n // it.\n //\n // This specific case is a silent failure in cp, install, tar,\n // and most other unix tools that manage permissions.\n //\n // When running as root, or if other types of errors are\n // encountered, then it's strict.\n function chownErOk (er) {\n if (!er)\n return true\n\n if (er.code === \"ENOSYS\")\n return true\n\n var nonroot = !process.getuid || process.getuid() !== 0\n if (nonroot) {\n if (er.code === \"EINVAL\" || er.code === \"EPERM\")\n return true\n }\n\n return false\n }\n}\n", "var Stream = require('stream').Stream\n\nmodule.exports = legacy\n\nfunction legacy (fs) {\n return {\n ReadStream: ReadStream,\n WriteStream: WriteStream\n }\n\n function ReadStream (path, options) {\n if (!(this instanceof ReadStream)) return new ReadStream(path, options);\n\n Stream.call(this);\n\n var self = this;\n\n this.path = path;\n this.fd = null;\n this.readable = true;\n this.paused = false;\n\n this.flags = 'r';\n this.mode = 438; /*=0666*/\n this.bufferSize = 64 * 1024;\n\n options = options || {};\n\n // Mixin options into this\n var keys = Object.keys(options);\n for (var index = 0, length = keys.length; index < length; index++) {\n var key = keys[index];\n this[key] = options[key];\n }\n\n if (this.encoding) this.setEncoding(this.encoding);\n\n if (this.start !== undefined) {\n if ('number' !== typeof this.start) {\n throw TypeError('start must be a Number');\n }\n if (this.end === undefined) {\n this.end = Infinity;\n } else if ('number' !== typeof this.end) {\n throw TypeError('end must be a Number');\n }\n\n if (this.start > this.end) {\n throw new Error('start must be <= end');\n }\n\n this.pos = this.start;\n }\n\n if (this.fd !== null) {\n process.nextTick(function() {\n self._read();\n });\n return;\n }\n\n fs.open(this.path, this.flags, this.mode, function (err, fd) {\n if (err) {\n self.emit('error', err);\n self.readable = false;\n return;\n }\n\n self.fd = fd;\n self.emit('open', fd);\n self._read();\n })\n }\n\n function WriteStream (path, options) {\n if (!(this instanceof WriteStream)) return new WriteStream(path, options);\n\n Stream.call(this);\n\n this.path = path;\n this.fd = null;\n this.writable = true;\n\n this.flags = 'w';\n this.encoding = 'binary';\n this.mode = 438; /*=0666*/\n this.bytesWritten = 0;\n\n options = options || {};\n\n // Mixin options into this\n var keys = Object.keys(options);\n for (var index = 0, length = keys.length; index < length; index++) {\n var key = keys[index];\n this[key] = options[key];\n }\n\n if (this.start !== undefined) {\n if ('number' !== typeof this.start) {\n throw TypeError('start must be a Number');\n }\n if (this.start < 0) {\n throw new Error('start must be >= zero');\n }\n\n this.pos = this.start;\n }\n\n this.busy = false;\n this._queue = [];\n\n if (this.fd === null) {\n this._open = fs.open;\n this._queue.push([this._open, this.path, this.flags, this.mode, undefined]);\n this.flush();\n }\n }\n}\n", "'use strict'\n\nmodule.exports = clone\n\nfunction clone (obj) {\n if (obj === null || typeof obj !== 'object')\n return obj\n\n if (obj instanceof Object)\n var copy = { __proto__: obj.__proto__ }\n else\n var copy = Object.create(null)\n\n Object.getOwnPropertyNames(obj).forEach(function (key) {\n Object.defineProperty(copy, key, Object.getOwnPropertyDescriptor(obj, key))\n })\n\n return copy\n}\n", "var fs = require('fs')\nvar polyfills = require('./polyfills.js')\nvar legacy = require('./legacy-streams.js')\nvar clone = require('./clone.js')\n\nvar util = require('util')\n\n/* istanbul ignore next - node 0.x polyfill */\nvar gracefulQueue\nvar previousSymbol\n\n/* istanbul ignore else - node 0.x polyfill */\nif (typeof Symbol === 'function' && typeof Symbol.for === 'function') {\n gracefulQueue = Symbol.for('graceful-fs.queue')\n // This is used in testing by future versions\n previousSymbol = Symbol.for('graceful-fs.previous')\n} else {\n gracefulQueue = '___graceful-fs.queue'\n previousSymbol = '___graceful-fs.previous'\n}\n\nfunction noop () {}\n\nfunction publishQueue(context, queue) {\n Object.defineProperty(context, gracefulQueue, {\n get: function() {\n return queue\n }\n })\n}\n\nvar debug = noop\nif (util.debuglog)\n debug = util.debuglog('gfs4')\nelse if (/\\bgfs4\\b/i.test(process.env.NODE_DEBUG || ''))\n debug = function() {\n var m = util.format.apply(util, arguments)\n m = 'GFS4: ' + m.split(/\\n/).join('\\nGFS4: ')\n console.error(m)\n }\n\n// Once time initialization\nif (!fs[gracefulQueue]) {\n // This queue can be shared by multiple loaded instances\n var queue = global[gracefulQueue] || []\n publishQueue(fs, queue)\n\n // Patch fs.close/closeSync to shared queue version, because we need\n // to retry() whenever a close happens *anywhere* in the program.\n // This is essential when multiple graceful-fs instances are\n // in play at the same time.\n fs.close = (function (fs$close) {\n function close (fd, cb) {\n return fs$close.call(fs, fd, function (err) {\n // This function uses the graceful-fs shared queue\n if (!err) {\n retry()\n }\n\n if (typeof cb === 'function')\n cb.apply(this, arguments)\n })\n }\n\n Object.defineProperty(close, previousSymbol, {\n value: fs$close\n })\n return close\n })(fs.close)\n\n fs.closeSync = (function (fs$closeSync) {\n function closeSync (fd) {\n // This function uses the graceful-fs shared queue\n fs$closeSync.apply(fs, arguments)\n retry()\n }\n\n Object.defineProperty(closeSync, previousSymbol, {\n value: fs$closeSync\n })\n return closeSync\n })(fs.closeSync)\n\n if (/\\bgfs4\\b/i.test(process.env.NODE_DEBUG || '')) {\n process.on('exit', function() {\n debug(fs[gracefulQueue])\n require('assert').equal(fs[gracefulQueue].length, 0)\n })\n }\n}\n\nif (!global[gracefulQueue]) {\n publishQueue(global, fs[gracefulQueue]);\n}\n\nmodule.exports = patch(clone(fs))\nif (process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH && !fs.__patched) {\n module.exports = patch(fs)\n fs.__patched = true;\n}\n\nfunction patch (fs) {\n // Everything that references the open() function needs to be in here\n polyfills(fs)\n fs.gracefulify = patch\n\n fs.createReadStream = createReadStream\n fs.createWriteStream = createWriteStream\n var fs$readFile = fs.readFile\n fs.readFile = readFile\n function readFile (path, options, cb) {\n if (typeof options === 'function')\n cb = options, options = null\n\n return go$readFile(path, options, cb)\n\n function go$readFile (path, options, cb) {\n return fs$readFile(path, options, function (err) {\n if (err && (err.code === 'EMFILE' || err.code === 'ENFILE'))\n enqueue([go$readFile, [path, options, cb]])\n else {\n if (typeof cb === 'function')\n cb.apply(this, arguments)\n retry()\n }\n })\n }\n }\n\n var fs$writeFile = fs.writeFile\n fs.writeFile = writeFile\n function writeFile (path, data, options, cb) {\n if (typeof options === 'function')\n cb = options, options = null\n\n return go$writeFile(path, data, options, cb)\n\n function go$writeFile (path, data, options, cb) {\n return fs$writeFile(path, data, options, function (err) {\n if (err && (err.code === 'EMFILE' || err.code === 'ENFILE'))\n enqueue([go$writeFile, [path, data, options, cb]])\n else {\n if (typeof cb === 'function')\n cb.apply(this, arguments)\n retry()\n }\n })\n }\n }\n\n var fs$appendFile = fs.appendFile\n if (fs$appendFile)\n fs.appendFile = appendFile\n function appendFile (path, data, options, cb) {\n if (typeof options === 'function')\n cb = options, options = null\n\n return go$appendFile(path, data, options, cb)\n\n function go$appendFile (path, data, options, cb) {\n return fs$appendFile(path, data, options, function (err) {\n if (err && (err.code === 'EMFILE' || err.code === 'ENFILE'))\n enqueue([go$appendFile, [path, data, options, cb]])\n else {\n if (typeof cb === 'function')\n cb.apply(this, arguments)\n retry()\n }\n })\n }\n }\n\n var fs$readdir = fs.readdir\n fs.readdir = readdir\n function readdir (path, options, cb) {\n var args = [path]\n if (typeof options !== 'function') {\n args.push(options)\n } else {\n cb = options\n }\n args.push(go$readdir$cb)\n\n return go$readdir(args)\n\n function go$readdir$cb (err, files) {\n if (files && files.sort)\n files.sort()\n\n if (err && (err.code === 'EMFILE' || err.code === 'ENFILE'))\n enqueue([go$readdir, [args]])\n\n else {\n if (typeof cb === 'function')\n cb.apply(this, arguments)\n retry()\n }\n }\n }\n\n function go$readdir (args) {\n return fs$readdir.apply(fs, args)\n }\n\n if (process.version.substr(0, 4) === 'v0.8') {\n var legStreams = legacy(fs)\n ReadStream = legStreams.ReadStream\n WriteStream = legStreams.WriteStream\n }\n\n var fs$ReadStream = fs.ReadStream\n if (fs$ReadStream) {\n ReadStream.prototype = Object.create(fs$ReadStream.prototype)\n ReadStream.prototype.open = ReadStream$open\n }\n\n var fs$WriteStream = fs.WriteStream\n if (fs$WriteStream) {\n WriteStream.prototype = Object.create(fs$WriteStream.prototype)\n WriteStream.prototype.open = WriteStream$open\n }\n\n Object.defineProperty(fs, 'ReadStream', {\n get: function () {\n return ReadStream\n },\n set: function (val) {\n ReadStream = val\n },\n enumerable: true,\n configurable: true\n })\n Object.defineProperty(fs, 'WriteStream', {\n get: function () {\n return WriteStream\n },\n set: function (val) {\n WriteStream = val\n },\n enumerable: true,\n configurable: true\n })\n\n // legacy names\n var FileReadStream = ReadStream\n Object.defineProperty(fs, 'FileReadStream', {\n get: function () {\n return FileReadStream\n },\n set: function (val) {\n FileReadStream = val\n },\n enumerable: true,\n configurable: true\n })\n var FileWriteStream = WriteStream\n Object.defineProperty(fs, 'FileWriteStream', {\n get: function () {\n return FileWriteStream\n },\n set: function (val) {\n FileWriteStream = val\n },\n enumerable: true,\n configurable: true\n })\n\n function ReadStream (path, options) {\n if (this instanceof ReadStream)\n return fs$ReadStream.apply(this, arguments), this\n else\n return ReadStream.apply(Object.create(ReadStream.prototype), arguments)\n }\n\n function ReadStream$open () {\n var that = this\n open(that.path, that.flags, that.mode, function (err, fd) {\n if (err) {\n if (that.autoClose)\n that.destroy()\n\n that.emit('error', err)\n } else {\n that.fd = fd\n that.emit('open', fd)\n that.read()\n }\n })\n }\n\n function WriteStream (path, options) {\n if (this instanceof WriteStream)\n return fs$WriteStream.apply(this, arguments), this\n else\n return WriteStream.apply(Object.create(WriteStream.prototype), arguments)\n }\n\n function WriteStream$open () {\n var that = this\n open(that.path, that.flags, that.mode, function (err, fd) {\n if (err) {\n that.destroy()\n that.emit('error', err)\n } else {\n that.fd = fd\n that.emit('open', fd)\n }\n })\n }\n\n function createReadStream (path, options) {\n return new fs.ReadStream(path, options)\n }\n\n function createWriteStream (path, options) {\n return new fs.WriteStream(path, options)\n }\n\n var fs$open = fs.open\n fs.open = open\n function open (path, flags, mode, cb) {\n if (typeof mode === 'function')\n cb = mode, mode = null\n\n return go$open(path, flags, mode, cb)\n\n function go$open (path, flags, mode, cb) {\n return fs$open(path, flags, mode, function (err, fd) {\n if (err && (err.code === 'EMFILE' || err.code === 'ENFILE'))\n enqueue([go$open, [path, flags, mode, cb]])\n else {\n if (typeof cb === 'function')\n cb.apply(this, arguments)\n retry()\n }\n })\n }\n }\n\n return fs\n}\n\nfunction enqueue (elem) {\n debug('ENQUEUE', elem[0].name, elem[1])\n fs[gracefulQueue].push(elem)\n}\n\nfunction retry () {\n var elem = fs[gracefulQueue].shift()\n if (elem) {\n debug('RETRY', elem[0].name, elem[1])\n elem[0].apply(null, elem[1])\n }\n}\n", "'use strict'\n// This is adapted from https://github.com/normalize/mz\n// Copyright (c) 2014-2016 Jonathan Ong me@jongleberry.com and Contributors\nconst u = require('universalify').fromCallback\nconst fs = require('graceful-fs')\n\nconst api = [\n 'access',\n 'appendFile',\n 'chmod',\n 'chown',\n 'close',\n 'copyFile',\n 'fchmod',\n 'fchown',\n 'fdatasync',\n 'fstat',\n 'fsync',\n 'ftruncate',\n 'futimes',\n 'lchmod',\n 'lchown',\n 'link',\n 'lstat',\n 'mkdir',\n 'mkdtemp',\n 'open',\n 'opendir',\n 'readdir',\n 'readFile',\n 'readlink',\n 'realpath',\n 'rename',\n 'rm',\n 'rmdir',\n 'stat',\n 'symlink',\n 'truncate',\n 'unlink',\n 'utimes',\n 'writeFile'\n].filter(key => {\n // Some commands are not available on some systems. Ex:\n // fs.opendir was added in Node.js v12.12.0\n // fs.rm was added in Node.js v14.14.0\n // fs.lchown is not available on at least some Linux\n return typeof fs[key] === 'function'\n})\n\n// Export cloned fs:\nObject.assign(exports, fs)\n\n// Universalify async methods:\napi.forEach(method => {\n exports[method] = u(fs[method])\n})\nexports.realpath.native = u(fs.realpath.native)\n\n// We differ from mz/fs in that we still ship the old, broken, fs.exists()\n// since we are a drop-in replacement for the native module\nexports.exists = function (filename, callback) {\n if (typeof callback === 'function') {\n return fs.exists(filename, callback)\n }\n return new Promise(resolve => {\n return fs.exists(filename, resolve)\n })\n}\n\n// fs.read(), fs.write(), & fs.writev() need special treatment due to multiple callback args\n\nexports.read = function (fd, buffer, offset, length, position, callback) {\n if (typeof callback === 'function') {\n return fs.read(fd, buffer, offset, length, position, callback)\n }\n return new Promise((resolve, reject) => {\n fs.read(fd, buffer, offset, length, position, (err, bytesRead, buffer) => {\n if (err) return reject(err)\n resolve({ bytesRead, buffer })\n })\n })\n}\n\n// Function signature can be\n// fs.write(fd, buffer[, offset[, length[, position]]], callback)\n// OR\n// fs.write(fd, string[, position[, encoding]], callback)\n// We need to handle both cases, so we use ...args\nexports.write = function (fd, buffer, ...args) {\n if (typeof args[args.length - 1] === 'function') {\n return fs.write(fd, buffer, ...args)\n }\n\n return new Promise((resolve, reject) => {\n fs.write(fd, buffer, ...args, (err, bytesWritten, buffer) => {\n if (err) return reject(err)\n resolve({ bytesWritten, buffer })\n })\n })\n}\n\n// fs.writev only available in Node v12.9.0+\nif (typeof fs.writev === 'function') {\n // Function signature is\n // s.writev(fd, buffers[, position], callback)\n // We need to handle the optional arg, so we use ...args\n exports.writev = function (fd, buffers, ...args) {\n if (typeof args[args.length - 1] === 'function') {\n return fs.writev(fd, buffers, ...args)\n }\n\n return new Promise((resolve, reject) => {\n fs.writev(fd, buffers, ...args, (err, bytesWritten, buffers) => {\n if (err) return reject(err)\n resolve({ bytesWritten, buffers })\n })\n })\n }\n}\n", "// Adapted from https://github.com/sindresorhus/make-dir\n// Copyright (c) Sindre Sorhus (sindresorhus.com)\n// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:\n// The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n'use strict'\nconst path = require('path')\n\n// https://github.com/nodejs/node/issues/8987\n// https://github.com/libuv/libuv/pull/1088\nmodule.exports.checkPath = function checkPath (pth) {\n if (process.platform === 'win32') {\n const pathHasInvalidWinCharacters = /[<>:\"|?*]/.test(pth.replace(path.parse(pth).root, ''))\n\n if (pathHasInvalidWinCharacters) {\n const error = new Error(`Path contains invalid characters: ${pth}`)\n error.code = 'EINVAL'\n throw error\n }\n }\n}\n", "'use strict'\nconst fs = require('../fs')\nconst { checkPath } = require('./utils')\n\nconst getMode = options => {\n const defaults = { mode: 0o777 }\n if (typeof options === 'number') return options\n return ({ ...defaults, ...options }).mode\n}\n\nmodule.exports.makeDir = async (dir, options) => {\n checkPath(dir)\n\n return fs.mkdir(dir, {\n mode: getMode(options),\n recursive: true\n })\n}\n\nmodule.exports.makeDirSync = (dir, options) => {\n checkPath(dir)\n\n return fs.mkdirSync(dir, {\n mode: getMode(options),\n recursive: true\n })\n}\n", "'use strict'\nconst u = require('universalify').fromPromise\nconst { makeDir: _makeDir, makeDirSync } = require('./make-dir')\nconst makeDir = u(_makeDir)\n\nmodule.exports = {\n mkdirs: makeDir,\n mkdirsSync: makeDirSync,\n // alias\n mkdirp: makeDir,\n mkdirpSync: makeDirSync,\n ensureDir: makeDir,\n ensureDirSync: makeDirSync\n}\n", "'use strict'\n\nconst fs = require('graceful-fs')\n\nfunction utimesMillis (path, atime, mtime, callback) {\n // if (!HAS_MILLIS_RES) return fs.utimes(path, atime, mtime, callback)\n fs.open(path, 'r+', (err, fd) => {\n if (err) return callback(err)\n fs.futimes(fd, atime, mtime, futimesErr => {\n fs.close(fd, closeErr => {\n if (callback) callback(futimesErr || closeErr)\n })\n })\n })\n}\n\nfunction utimesMillisSync (path, atime, mtime) {\n const fd = fs.openSync(path, 'r+')\n fs.futimesSync(fd, atime, mtime)\n return fs.closeSync(fd)\n}\n\nmodule.exports = {\n utimesMillis,\n utimesMillisSync\n}\n", "'use strict'\n\nconst fs = require('../fs')\nconst path = require('path')\nconst util = require('util')\n\nfunction getStats (src, dest, opts) {\n const statFunc = opts.dereference\n ? (file) => fs.stat(file, { bigint: true })\n : (file) => fs.lstat(file, { bigint: true })\n return Promise.all([\n statFunc(src),\n statFunc(dest).catch(err => {\n if (err.code === 'ENOENT') return null\n throw err\n })\n ]).then(([srcStat, destStat]) => ({ srcStat, destStat }))\n}\n\nfunction getStatsSync (src, dest, opts) {\n let destStat\n const statFunc = opts.dereference\n ? (file) => fs.statSync(file, { bigint: true })\n : (file) => fs.lstatSync(file, { bigint: true })\n const srcStat = statFunc(src)\n try {\n destStat = statFunc(dest)\n } catch (err) {\n if (err.code === 'ENOENT') return { srcStat, destStat: null }\n throw err\n }\n return { srcStat, destStat }\n}\n\nfunction checkPaths (src, dest, funcName, opts, cb) {\n util.callbackify(getStats)(src, dest, opts, (err, stats) => {\n if (err) return cb(err)\n const { srcStat, destStat } = stats\n\n if (destStat) {\n if (areIdentical(srcStat, destStat)) {\n const srcBaseName = path.basename(src)\n const destBaseName = path.basename(dest)\n if (funcName === 'move' &&\n srcBaseName !== destBaseName &&\n srcBaseName.toLowerCase() === destBaseName.toLowerCase()) {\n return cb(null, { srcStat, destStat, isChangingCase: true })\n }\n return cb(new Error('Source and destination must not be the same.'))\n }\n if (srcStat.isDirectory() && !destStat.isDirectory()) {\n return cb(new Error(`Cannot overwrite non-directory '${dest}' with directory '${src}'.`))\n }\n if (!srcStat.isDirectory() && destStat.isDirectory()) {\n return cb(new Error(`Cannot overwrite directory '${dest}' with non-directory '${src}'.`))\n }\n }\n\n if (srcStat.isDirectory() && isSrcSubdir(src, dest)) {\n return cb(new Error(errMsg(src, dest, funcName)))\n }\n return cb(null, { srcStat, destStat })\n })\n}\n\nfunction checkPathsSync (src, dest, funcName, opts) {\n const { srcStat, destStat } = getStatsSync(src, dest, opts)\n\n if (destStat) {\n if (areIdentical(srcStat, destStat)) {\n const srcBaseName = path.basename(src)\n const destBaseName = path.basename(dest)\n if (funcName === 'move' &&\n srcBaseName !== destBaseName &&\n srcBaseName.toLowerCase() === destBaseName.toLowerCase()) {\n return { srcStat, destStat, isChangingCase: true }\n }\n throw new Error('Source and destination must not be the same.')\n }\n if (srcStat.isDirectory() && !destStat.isDirectory()) {\n throw new Error(`Cannot overwrite non-directory '${dest}' with directory '${src}'.`)\n }\n if (!srcStat.isDirectory() && destStat.isDirectory()) {\n throw new Error(`Cannot overwrite directory '${dest}' with non-directory '${src}'.`)\n }\n }\n\n if (srcStat.isDirectory() && isSrcSubdir(src, dest)) {\n throw new Error(errMsg(src, dest, funcName))\n }\n return { srcStat, destStat }\n}\n\n// recursively check if dest parent is a subdirectory of src.\n// It works for all file types including symlinks since it\n// checks the src and dest inodes. It starts from the deepest\n// parent and stops once it reaches the src parent or the root path.\nfunction checkParentPaths (src, srcStat, dest, funcName, cb) {\n const srcParent = path.resolve(path.dirname(src))\n const destParent = path.resolve(path.dirname(dest))\n if (destParent === srcParent || destParent === path.parse(destParent).root) return cb()\n fs.stat(destParent, { bigint: true }, (err, destStat) => {\n if (err) {\n if (err.code === 'ENOENT') return cb()\n return cb(err)\n }\n if (areIdentical(srcStat, destStat)) {\n return cb(new Error(errMsg(src, dest, funcName)))\n }\n return checkParentPaths(src, srcStat, destParent, funcName, cb)\n })\n}\n\nfunction checkParentPathsSync (src, srcStat, dest, funcName) {\n const srcParent = path.resolve(path.dirname(src))\n const destParent = path.resolve(path.dirname(dest))\n if (destParent === srcParent || destParent === path.parse(destParent).root) return\n let destStat\n try {\n destStat = fs.statSync(destParent, { bigint: true })\n } catch (err) {\n if (err.code === 'ENOENT') return\n throw err\n }\n if (areIdentical(srcStat, destStat)) {\n throw new Error(errMsg(src, dest, funcName))\n }\n return checkParentPathsSync(src, srcStat, destParent, funcName)\n}\n\nfunction areIdentical (srcStat, destStat) {\n return destStat.ino && destStat.dev && destStat.ino === srcStat.ino && destStat.dev === srcStat.dev\n}\n\n// return true if dest is a subdir of src, otherwise false.\n// It only checks the path strings.\nfunction isSrcSubdir (src, dest) {\n const srcArr = path.resolve(src).split(path.sep).filter(i => i)\n const destArr = path.resolve(dest).split(path.sep).filter(i => i)\n return srcArr.reduce((acc, cur, i) => acc && destArr[i] === cur, true)\n}\n\nfunction errMsg (src, dest, funcName) {\n return `Cannot ${funcName} '${src}' to a subdirectory of itself, '${dest}'.`\n}\n\nmodule.exports = {\n checkPaths,\n checkPathsSync,\n checkParentPaths,\n checkParentPathsSync,\n isSrcSubdir,\n areIdentical\n}\n", "'use strict'\n\nconst fs = require('graceful-fs')\nconst path = require('path')\nconst mkdirsSync = require('../mkdirs').mkdirsSync\nconst utimesMillisSync = require('../util/utimes').utimesMillisSync\nconst stat = require('../util/stat')\n\nfunction copySync (src, dest, opts) {\n if (typeof opts === 'function') {\n opts = { filter: opts }\n }\n\n opts = opts || {}\n opts.clobber = 'clobber' in opts ? !!opts.clobber : true // default to true for now\n opts.overwrite = 'overwrite' in opts ? !!opts.overwrite : opts.clobber // overwrite falls back to clobber\n\n // Warn about using preserveTimestamps on 32-bit node\n if (opts.preserveTimestamps && process.arch === 'ia32') {\n console.warn(`fs-extra: Using the preserveTimestamps option in 32-bit node is not recommended;\\n\n see https://github.com/jprichardson/node-fs-extra/issues/269`)\n }\n\n const { srcStat, destStat } = stat.checkPathsSync(src, dest, 'copy', opts)\n stat.checkParentPathsSync(src, srcStat, dest, 'copy')\n return handleFilterAndCopy(destStat, src, dest, opts)\n}\n\nfunction handleFilterAndCopy (destStat, src, dest, opts) {\n if (opts.filter && !opts.filter(src, dest)) return\n const destParent = path.dirname(dest)\n if (!fs.existsSync(destParent)) mkdirsSync(destParent)\n return getStats(destStat, src, dest, opts)\n}\n\nfunction startCopy (destStat, src, dest, opts) {\n if (opts.filter && !opts.filter(src, dest)) return\n return getStats(destStat, src, dest, opts)\n}\n\nfunction getStats (destStat, src, dest, opts) {\n const statSync = opts.dereference ? fs.statSync : fs.lstatSync\n const srcStat = statSync(src)\n\n if (srcStat.isDirectory()) return onDir(srcStat, destStat, src, dest, opts)\n else if (srcStat.isFile() ||\n srcStat.isCharacterDevice() ||\n srcStat.isBlockDevice()) return onFile(srcStat, destStat, src, dest, opts)\n else if (srcStat.isSymbolicLink()) return onLink(destStat, src, dest, opts)\n else if (srcStat.isSocket()) throw new Error(`Cannot copy a socket file: ${src}`)\n else if (srcStat.isFIFO()) throw new Error(`Cannot copy a FIFO pipe: ${src}`)\n throw new Error(`Unknown file: ${src}`)\n}\n\nfunction onFile (srcStat, destStat, src, dest, opts) {\n if (!destStat) return copyFile(srcStat, src, dest, opts)\n return mayCopyFile(srcStat, src, dest, opts)\n}\n\nfunction mayCopyFile (srcStat, src, dest, opts) {\n if (opts.overwrite) {\n fs.unlinkSync(dest)\n return copyFile(srcStat, src, dest, opts)\n } else if (opts.errorOnExist) {\n throw new Error(`'${dest}' already exists`)\n }\n}\n\nfunction copyFile (srcStat, src, dest, opts) {\n fs.copyFileSync(src, dest)\n if (opts.preserveTimestamps) handleTimestamps(srcStat.mode, src, dest)\n return setDestMode(dest, srcStat.mode)\n}\n\nfunction handleTimestamps (srcMode, src, dest) {\n // Make sure the file is writable before setting the timestamp\n // otherwise open fails with EPERM when invoked with 'r+'\n // (through utimes call)\n if (fileIsNotWritable(srcMode)) makeFileWritable(dest, srcMode)\n return setDestTimestamps(src, dest)\n}\n\nfunction fileIsNotWritable (srcMode) {\n return (srcMode & 0o200) === 0\n}\n\nfunction makeFileWritable (dest, srcMode) {\n return setDestMode(dest, srcMode | 0o200)\n}\n\nfunction setDestMode (dest, srcMode) {\n return fs.chmodSync(dest, srcMode)\n}\n\nfunction setDestTimestamps (src, dest) {\n // The initial srcStat.atime cannot be trusted\n // because it is modified by the read(2) system call\n // (See https://nodejs.org/api/fs.html#fs_stat_time_values)\n const updatedSrcStat = fs.statSync(src)\n return utimesMillisSync(dest, updatedSrcStat.atime, updatedSrcStat.mtime)\n}\n\nfunction onDir (srcStat, destStat, src, dest, opts) {\n if (!destStat) return mkDirAndCopy(srcStat.mode, src, dest, opts)\n return copyDir(src, dest, opts)\n}\n\nfunction mkDirAndCopy (srcMode, src, dest, opts) {\n fs.mkdirSync(dest)\n copyDir(src, dest, opts)\n return setDestMode(dest, srcMode)\n}\n\nfunction copyDir (src, dest, opts) {\n fs.readdirSync(src).forEach(item => copyDirItem(item, src, dest, opts))\n}\n\nfunction copyDirItem (item, src, dest, opts) {\n const srcItem = path.join(src, item)\n const destItem = path.join(dest, item)\n const { destStat } = stat.checkPathsSync(srcItem, destItem, 'copy', opts)\n return startCopy(destStat, srcItem, destItem, opts)\n}\n\nfunction onLink (destStat, src, dest, opts) {\n let resolvedSrc = fs.readlinkSync(src)\n if (opts.dereference) {\n resolvedSrc = path.resolve(process.cwd(), resolvedSrc)\n }\n\n if (!destStat) {\n return fs.symlinkSync(resolvedSrc, dest)\n } else {\n let resolvedDest\n try {\n resolvedDest = fs.readlinkSync(dest)\n } catch (err) {\n // dest exists and is a regular file or directory,\n // Windows may throw UNKNOWN error. If dest already exists,\n // fs throws error anyway, so no need to guard against it here.\n if (err.code === 'EINVAL' || err.code === 'UNKNOWN') return fs.symlinkSync(resolvedSrc, dest)\n throw err\n }\n if (opts.dereference) {\n resolvedDest = path.resolve(process.cwd(), resolvedDest)\n }\n if (stat.isSrcSubdir(resolvedSrc, resolvedDest)) {\n throw new Error(`Cannot copy '${resolvedSrc}' to a subdirectory of itself, '${resolvedDest}'.`)\n }\n\n // prevent copy if src is a subdir of dest since unlinking\n // dest in this case would result in removing src contents\n // and therefore a broken symlink would be created.\n if (fs.statSync(dest).isDirectory() && stat.isSrcSubdir(resolvedDest, resolvedSrc)) {\n throw new Error(`Cannot overwrite '${resolvedDest}' with '${resolvedSrc}'.`)\n }\n return copyLink(resolvedSrc, dest)\n }\n}\n\nfunction copyLink (resolvedSrc, dest) {\n fs.unlinkSync(dest)\n return fs.symlinkSync(resolvedSrc, dest)\n}\n\nmodule.exports = copySync\n", "'use strict'\n\nmodule.exports = {\n copySync: require('./copy-sync')\n}\n", "'use strict'\nconst u = require('universalify').fromPromise\nconst fs = require('../fs')\n\nfunction pathExists (path) {\n return fs.access(path).then(() => true).catch(() => false)\n}\n\nmodule.exports = {\n pathExists: u(pathExists),\n pathExistsSync: fs.existsSync\n}\n", "'use strict'\n\nconst fs = require('graceful-fs')\nconst path = require('path')\nconst mkdirs = require('../mkdirs').mkdirs\nconst pathExists = require('../path-exists').pathExists\nconst utimesMillis = require('../util/utimes').utimesMillis\nconst stat = require('../util/stat')\n\nfunction copy (src, dest, opts, cb) {\n if (typeof opts === 'function' && !cb) {\n cb = opts\n opts = {}\n } else if (typeof opts === 'function') {\n opts = { filter: opts }\n }\n\n cb = cb || function () {}\n opts = opts || {}\n\n opts.clobber = 'clobber' in opts ? !!opts.clobber : true // default to true for now\n opts.overwrite = 'overwrite' in opts ? !!opts.overwrite : opts.clobber // overwrite falls back to clobber\n\n // Warn about using preserveTimestamps on 32-bit node\n if (opts.preserveTimestamps && process.arch === 'ia32') {\n console.warn(`fs-extra: Using the preserveTimestamps option in 32-bit node is not recommended;\\n\n see https://github.com/jprichardson/node-fs-extra/issues/269`)\n }\n\n stat.checkPaths(src, dest, 'copy', opts, (err, stats) => {\n if (err) return cb(err)\n const { srcStat, destStat } = stats\n stat.checkParentPaths(src, srcStat, dest, 'copy', err => {\n if (err) return cb(err)\n if (opts.filter) return handleFilter(checkParentDir, destStat, src, dest, opts, cb)\n return checkParentDir(destStat, src, dest, opts, cb)\n })\n })\n}\n\nfunction checkParentDir (destStat, src, dest, opts, cb) {\n const destParent = path.dirname(dest)\n pathExists(destParent, (err, dirExists) => {\n if (err) return cb(err)\n if (dirExists) return getStats(destStat, src, dest, opts, cb)\n mkdirs(destParent, err => {\n if (err) return cb(err)\n return getStats(destStat, src, dest, opts, cb)\n })\n })\n}\n\nfunction handleFilter (onInclude, destStat, src, dest, opts, cb) {\n Promise.resolve(opts.filter(src, dest)).then(include => {\n if (include) return onInclude(destStat, src, dest, opts, cb)\n return cb()\n }, error => cb(error))\n}\n\nfunction startCopy (destStat, src, dest, opts, cb) {\n if (opts.filter) return handleFilter(getStats, destStat, src, dest, opts, cb)\n return getStats(destStat, src, dest, opts, cb)\n}\n\nfunction getStats (destStat, src, dest, opts, cb) {\n const stat = opts.dereference ? fs.stat : fs.lstat\n stat(src, (err, srcStat) => {\n if (err) return cb(err)\n\n if (srcStat.isDirectory()) return onDir(srcStat, destStat, src, dest, opts, cb)\n else if (srcStat.isFile() ||\n srcStat.isCharacterDevice() ||\n srcStat.isBlockDevice()) return onFile(srcStat, destStat, src, dest, opts, cb)\n else if (srcStat.isSymbolicLink()) return onLink(destStat, src, dest, opts, cb)\n else if (srcStat.isSocket()) return cb(new Error(`Cannot copy a socket file: ${src}`))\n else if (srcStat.isFIFO()) return cb(new Error(`Cannot copy a FIFO pipe: ${src}`))\n return cb(new Error(`Unknown file: ${src}`))\n })\n}\n\nfunction onFile (srcStat, destStat, src, dest, opts, cb) {\n if (!destStat) return copyFile(srcStat, src, dest, opts, cb)\n return mayCopyFile(srcStat, src, dest, opts, cb)\n}\n\nfunction mayCopyFile (srcStat, src, dest, opts, cb) {\n if (opts.overwrite) {\n fs.unlink(dest, err => {\n if (err) return cb(err)\n return copyFile(srcStat, src, dest, opts, cb)\n })\n } else if (opts.errorOnExist) {\n return cb(new Error(`'${dest}' already exists`))\n } else return cb()\n}\n\nfunction copyFile (srcStat, src, dest, opts, cb) {\n fs.copyFile(src, dest, err => {\n if (err) return cb(err)\n if (opts.preserveTimestamps) return handleTimestampsAndMode(srcStat.mode, src, dest, cb)\n return setDestMode(dest, srcStat.mode, cb)\n })\n}\n\nfunction handleTimestampsAndMode (srcMode, src, dest, cb) {\n // Make sure the file is writable before setting the timestamp\n // otherwise open fails with EPERM when invoked with 'r+'\n // (through utimes call)\n if (fileIsNotWritable(srcMode)) {\n return makeFileWritable(dest, srcMode, err => {\n if (err) return cb(err)\n return setDestTimestampsAndMode(srcMode, src, dest, cb)\n })\n }\n return setDestTimestampsAndMode(srcMode, src, dest, cb)\n}\n\nfunction fileIsNotWritable (srcMode) {\n return (srcMode & 0o200) === 0\n}\n\nfunction makeFileWritable (dest, srcMode, cb) {\n return setDestMode(dest, srcMode | 0o200, cb)\n}\n\nfunction setDestTimestampsAndMode (srcMode, src, dest, cb) {\n setDestTimestamps(src, dest, err => {\n if (err) return cb(err)\n return setDestMode(dest, srcMode, cb)\n })\n}\n\nfunction setDestMode (dest, srcMode, cb) {\n return fs.chmod(dest, srcMode, cb)\n}\n\nfunction setDestTimestamps (src, dest, cb) {\n // The initial srcStat.atime cannot be trusted\n // because it is modified by the read(2) system call\n // (See https://nodejs.org/api/fs.html#fs_stat_time_values)\n fs.stat(src, (err, updatedSrcStat) => {\n if (err) return cb(err)\n return utimesMillis(dest, updatedSrcStat.atime, updatedSrcStat.mtime, cb)\n })\n}\n\nfunction onDir (srcStat, destStat, src, dest, opts, cb) {\n if (!destStat) return mkDirAndCopy(srcStat.mode, src, dest, opts, cb)\n return copyDir(src, dest, opts, cb)\n}\n\nfunction mkDirAndCopy (srcMode, src, dest, opts, cb) {\n fs.mkdir(dest, err => {\n if (err) return cb(err)\n copyDir(src, dest, opts, err => {\n if (err) return cb(err)\n return setDestMode(dest, srcMode, cb)\n })\n })\n}\n\nfunction copyDir (src, dest, opts, cb) {\n fs.readdir(src, (err, items) => {\n if (err) return cb(err)\n return copyDirItems(items, src, dest, opts, cb)\n })\n}\n\nfunction copyDirItems (items, src, dest, opts, cb) {\n const item = items.pop()\n if (!item) return cb()\n return copyDirItem(items, item, src, dest, opts, cb)\n}\n\nfunction copyDirItem (items, item, src, dest, opts, cb) {\n const srcItem = path.join(src, item)\n const destItem = path.join(dest, item)\n stat.checkPaths(srcItem, destItem, 'copy', opts, (err, stats) => {\n if (err) return cb(err)\n const { destStat } = stats\n startCopy(destStat, srcItem, destItem, opts, err => {\n if (err) return cb(err)\n return copyDirItems(items, src, dest, opts, cb)\n })\n })\n}\n\nfunction onLink (destStat, src, dest, opts, cb) {\n fs.readlink(src, (err, resolvedSrc) => {\n if (err) return cb(err)\n if (opts.dereference) {\n resolvedSrc = path.resolve(process.cwd(), resolvedSrc)\n }\n\n if (!destStat) {\n return fs.symlink(resolvedSrc, dest, cb)\n } else {\n fs.readlink(dest, (err, resolvedDest) => {\n if (err) {\n // dest exists and is a regular file or directory,\n // Windows may throw UNKNOWN error. If dest already exists,\n // fs throws error anyway, so no need to guard against it here.\n if (err.code === 'EINVAL' || err.code === 'UNKNOWN') return fs.symlink(resolvedSrc, dest, cb)\n return cb(err)\n }\n if (opts.dereference) {\n resolvedDest = path.resolve(process.cwd(), resolvedDest)\n }\n if (stat.isSrcSubdir(resolvedSrc, resolvedDest)) {\n return cb(new Error(`Cannot copy '${resolvedSrc}' to a subdirectory of itself, '${resolvedDest}'.`))\n }\n\n // do not copy if src is a subdir of dest since unlinking\n // dest in this case would result in removing src contents\n // and therefore a broken symlink would be created.\n if (destStat.isDirectory() && stat.isSrcSubdir(resolvedDest, resolvedSrc)) {\n return cb(new Error(`Cannot overwrite '${resolvedDest}' with '${resolvedSrc}'.`))\n }\n return copyLink(resolvedSrc, dest, cb)\n })\n }\n })\n}\n\nfunction copyLink (resolvedSrc, dest, cb) {\n fs.unlink(dest, err => {\n if (err) return cb(err)\n return fs.symlink(resolvedSrc, dest, cb)\n })\n}\n\nmodule.exports = copy\n", "'use strict'\n\nconst u = require('universalify').fromCallback\nmodule.exports = {\n copy: u(require('./copy'))\n}\n", "'use strict'\n\nconst fs = require('graceful-fs')\nconst path = require('path')\nconst assert = require('assert')\n\nconst isWindows = (process.platform === 'win32')\n\nfunction defaults (options) {\n const methods = [\n 'unlink',\n 'chmod',\n 'stat',\n 'lstat',\n 'rmdir',\n 'readdir'\n ]\n methods.forEach(m => {\n options[m] = options[m] || fs[m]\n m = m + 'Sync'\n options[m] = options[m] || fs[m]\n })\n\n options.maxBusyTries = options.maxBusyTries || 3\n}\n\nfunction rimraf (p, options, cb) {\n let busyTries = 0\n\n if (typeof options === 'function') {\n cb = options\n options = {}\n }\n\n assert(p, 'rimraf: missing path')\n assert.strictEqual(typeof p, 'string', 'rimraf: path should be a string')\n assert.strictEqual(typeof cb, 'function', 'rimraf: callback function required')\n assert(options, 'rimraf: invalid options argument provided')\n assert.strictEqual(typeof options, 'object', 'rimraf: options should be object')\n\n defaults(options)\n\n rimraf_(p, options, function CB (er) {\n if (er) {\n if ((er.code === 'EBUSY' || er.code === 'ENOTEMPTY' || er.code === 'EPERM') &&\n busyTries < options.maxBusyTries) {\n busyTries++\n const time = busyTries * 100\n // try again, with the same exact callback as this one.\n return setTimeout(() => rimraf_(p, options, CB), time)\n }\n\n // already gone\n if (er.code === 'ENOENT') er = null\n }\n\n cb(er)\n })\n}\n\n// Two possible strategies.\n// 1. Assume it's a file. unlink it, then do the dir stuff on EPERM or EISDIR\n// 2. Assume it's a directory. readdir, then do the file stuff on ENOTDIR\n//\n// Both result in an extra syscall when you guess wrong. However, there\n// are likely far more normal files in the world than directories. This\n// is based on the assumption that a the average number of files per\n// directory is >= 1.\n//\n// If anyone ever complains about this, then I guess the strategy could\n// be made configurable somehow. But until then, YAGNI.\nfunction rimraf_ (p, options, cb) {\n assert(p)\n assert(options)\n assert(typeof cb === 'function')\n\n // sunos lets the root user unlink directories, which is... weird.\n // so we have to lstat here and make sure it's not a dir.\n options.lstat(p, (er, st) => {\n if (er && er.code === 'ENOENT') {\n return cb(null)\n }\n\n // Windows can EPERM on stat. Life is suffering.\n if (er && er.code === 'EPERM' && isWindows) {\n return fixWinEPERM(p, options, er, cb)\n }\n\n if (st && st.isDirectory()) {\n return rmdir(p, options, er, cb)\n }\n\n options.unlink(p, er => {\n if (er) {\n if (er.code === 'ENOENT') {\n return cb(null)\n }\n if (er.code === 'EPERM') {\n return (isWindows)\n ? fixWinEPERM(p, options, er, cb)\n : rmdir(p, options, er, cb)\n }\n if (er.code === 'EISDIR') {\n return rmdir(p, options, er, cb)\n }\n }\n return cb(er)\n })\n })\n}\n\nfunction fixWinEPERM (p, options, er, cb) {\n assert(p)\n assert(options)\n assert(typeof cb === 'function')\n\n options.chmod(p, 0o666, er2 => {\n if (er2) {\n cb(er2.code === 'ENOENT' ? null : er)\n } else {\n options.stat(p, (er3, stats) => {\n if (er3) {\n cb(er3.code === 'ENOENT' ? null : er)\n } else if (stats.isDirectory()) {\n rmdir(p, options, er, cb)\n } else {\n options.unlink(p, cb)\n }\n })\n }\n })\n}\n\nfunction fixWinEPERMSync (p, options, er) {\n let stats\n\n assert(p)\n assert(options)\n\n try {\n options.chmodSync(p, 0o666)\n } catch (er2) {\n if (er2.code === 'ENOENT') {\n return\n } else {\n throw er\n }\n }\n\n try {\n stats = options.statSync(p)\n } catch (er3) {\n if (er3.code === 'ENOENT') {\n return\n } else {\n throw er\n }\n }\n\n if (stats.isDirectory()) {\n rmdirSync(p, options, er)\n } else {\n options.unlinkSync(p)\n }\n}\n\nfunction rmdir (p, options, originalEr, cb) {\n assert(p)\n assert(options)\n assert(typeof cb === 'function')\n\n // try to rmdir first, and only readdir on ENOTEMPTY or EEXIST (SunOS)\n // if we guessed wrong, and it's not a directory, then\n // raise the original error.\n options.rmdir(p, er => {\n if (er && (er.code === 'ENOTEMPTY' || er.code === 'EEXIST' || er.code === 'EPERM')) {\n rmkids(p, options, cb)\n } else if (er && er.code === 'ENOTDIR') {\n cb(originalEr)\n } else {\n cb(er)\n }\n })\n}\n\nfunction rmkids (p, options, cb) {\n assert(p)\n assert(options)\n assert(typeof cb === 'function')\n\n options.readdir(p, (er, files) => {\n if (er) return cb(er)\n\n let n = files.length\n let errState\n\n if (n === 0) return options.rmdir(p, cb)\n\n files.forEach(f => {\n rimraf(path.join(p, f), options, er => {\n if (errState) {\n return\n }\n if (er) return cb(errState = er)\n if (--n === 0) {\n options.rmdir(p, cb)\n }\n })\n })\n })\n}\n\n// this looks simpler, and is strictly *faster*, but will\n// tie up the JavaScript thread and fail on excessively\n// deep directory trees.\nfunction rimrafSync (p, options) {\n let st\n\n options = options || {}\n defaults(options)\n\n assert(p, 'rimraf: missing path')\n assert.strictEqual(typeof p, 'string', 'rimraf: path should be a string')\n assert(options, 'rimraf: missing options')\n assert.strictEqual(typeof options, 'object', 'rimraf: options should be object')\n\n try {\n st = options.lstatSync(p)\n } catch (er) {\n if (er.code === 'ENOENT') {\n return\n }\n\n // Windows can EPERM on stat. Life is suffering.\n if (er.code === 'EPERM' && isWindows) {\n fixWinEPERMSync(p, options, er)\n }\n }\n\n try {\n // sunos lets the root user unlink directories, which is... weird.\n if (st && st.isDirectory()) {\n rmdirSync(p, options, null)\n } else {\n options.unlinkSync(p)\n }\n } catch (er) {\n if (er.code === 'ENOENT') {\n return\n } else if (er.code === 'EPERM') {\n return isWindows ? fixWinEPERMSync(p, options, er) : rmdirSync(p, options, er)\n } else if (er.code !== 'EISDIR') {\n throw er\n }\n rmdirSync(p, options, er)\n }\n}\n\nfunction rmdirSync (p, options, originalEr) {\n assert(p)\n assert(options)\n\n try {\n options.rmdirSync(p)\n } catch (er) {\n if (er.code === 'ENOTDIR') {\n throw originalEr\n } else if (er.code === 'ENOTEMPTY' || er.code === 'EEXIST' || er.code === 'EPERM') {\n rmkidsSync(p, options)\n } else if (er.code !== 'ENOENT') {\n throw er\n }\n }\n}\n\nfunction rmkidsSync (p, options) {\n assert(p)\n assert(options)\n options.readdirSync(p).forEach(f => rimrafSync(path.join(p, f), options))\n\n if (isWindows) {\n // We only end up here once we got ENOTEMPTY at least once, and\n // at this point, we are guaranteed to have removed all the kids.\n // So, we know that it won't be ENOENT or ENOTDIR or anything else.\n // try really hard to delete stuff on windows, because it has a\n // PROFOUNDLY annoying habit of not closing handles promptly when\n // files are deleted, resulting in spurious ENOTEMPTY errors.\n const startTime = Date.now()\n do {\n try {\n const ret = options.rmdirSync(p, options)\n return ret\n } catch {}\n } while (Date.now() - startTime < 500) // give up after 500ms\n } else {\n const ret = options.rmdirSync(p, options)\n return ret\n }\n}\n\nmodule.exports = rimraf\nrimraf.sync = rimrafSync\n", "'use strict'\n\nconst fs = require('graceful-fs')\nconst u = require('universalify').fromCallback\nconst rimraf = require('./rimraf')\n\nfunction remove (path, callback) {\n // Node 14.14.0+\n if (fs.rm) return fs.rm(path, { recursive: true, force: true }, callback)\n rimraf(path, callback)\n}\n\nfunction removeSync (path) {\n // Node 14.14.0+\n if (fs.rmSync) return fs.rmSync(path, { recursive: true, force: true })\n rimraf.sync(path)\n}\n\nmodule.exports = {\n remove: u(remove),\n removeSync\n}\n", "'use strict'\n\nconst u = require('universalify').fromPromise\nconst fs = require('../fs')\nconst path = require('path')\nconst mkdir = require('../mkdirs')\nconst remove = require('../remove')\n\nconst emptyDir = u(async function emptyDir (dir) {\n let items\n try {\n items = await fs.readdir(dir)\n } catch {\n return mkdir.mkdirs(dir)\n }\n\n return Promise.all(items.map(item => remove.remove(path.join(dir, item))))\n})\n\nfunction emptyDirSync (dir) {\n let items\n try {\n items = fs.readdirSync(dir)\n } catch {\n return mkdir.mkdirsSync(dir)\n }\n\n items.forEach(item => {\n item = path.join(dir, item)\n remove.removeSync(item)\n })\n}\n\nmodule.exports = {\n emptyDirSync,\n emptydirSync: emptyDirSync,\n emptyDir,\n emptydir: emptyDir\n}\n", "'use strict'\n\nconst u = require('universalify').fromCallback\nconst path = require('path')\nconst fs = require('graceful-fs')\nconst mkdir = require('../mkdirs')\n\nfunction createFile (file, callback) {\n function makeFile () {\n fs.writeFile(file, '', err => {\n if (err) return callback(err)\n callback()\n })\n }\n\n fs.stat(file, (err, stats) => { // eslint-disable-line handle-callback-err\n if (!err && stats.isFile()) return callback()\n const dir = path.dirname(file)\n fs.stat(dir, (err, stats) => {\n if (err) {\n // if the directory doesn't exist, make it\n if (err.code === 'ENOENT') {\n return mkdir.mkdirs(dir, err => {\n if (err) return callback(err)\n makeFile()\n })\n }\n return callback(err)\n }\n\n if (stats.isDirectory()) makeFile()\n else {\n // parent is not a directory\n // This is just to cause an internal ENOTDIR error to be thrown\n fs.readdir(dir, err => {\n if (err) return callback(err)\n })\n }\n })\n })\n}\n\nfunction createFileSync (file) {\n let stats\n try {\n stats = fs.statSync(file)\n } catch {}\n if (stats && stats.isFile()) return\n\n const dir = path.dirname(file)\n try {\n if (!fs.statSync(dir).isDirectory()) {\n // parent is not a directory\n // This is just to cause an internal ENOTDIR error to be thrown\n fs.readdirSync(dir)\n }\n } catch (err) {\n // If the stat call above failed because the directory doesn't exist, create it\n if (err && err.code === 'ENOENT') mkdir.mkdirsSync(dir)\n else throw err\n }\n\n fs.writeFileSync(file, '')\n}\n\nmodule.exports = {\n createFile: u(createFile),\n createFileSync\n}\n", "'use strict'\n\nconst u = require('universalify').fromCallback\nconst path = require('path')\nconst fs = require('graceful-fs')\nconst mkdir = require('../mkdirs')\nconst pathExists = require('../path-exists').pathExists\nconst { areIdentical } = require('../util/stat')\n\nfunction createLink (srcpath, dstpath, callback) {\n function makeLink (srcpath, dstpath) {\n fs.link(srcpath, dstpath, err => {\n if (err) return callback(err)\n callback(null)\n })\n }\n\n fs.lstat(dstpath, (_, dstStat) => {\n fs.lstat(srcpath, (err, srcStat) => {\n if (err) {\n err.message = err.message.replace('lstat', 'ensureLink')\n return callback(err)\n }\n if (dstStat && areIdentical(srcStat, dstStat)) return callback(null)\n\n const dir = path.dirname(dstpath)\n pathExists(dir, (err, dirExists) => {\n if (err) return callback(err)\n if (dirExists) return makeLink(srcpath, dstpath)\n mkdir.mkdirs(dir, err => {\n if (err) return callback(err)\n makeLink(srcpath, dstpath)\n })\n })\n })\n })\n}\n\nfunction createLinkSync (srcpath, dstpath) {\n let dstStat\n try {\n dstStat = fs.lstatSync(dstpath)\n } catch {}\n\n try {\n const srcStat = fs.lstatSync(srcpath)\n if (dstStat && areIdentical(srcStat, dstStat)) return\n } catch (err) {\n err.message = err.message.replace('lstat', 'ensureLink')\n throw err\n }\n\n const dir = path.dirname(dstpath)\n const dirExists = fs.existsSync(dir)\n if (dirExists) return fs.linkSync(srcpath, dstpath)\n mkdir.mkdirsSync(dir)\n\n return fs.linkSync(srcpath, dstpath)\n}\n\nmodule.exports = {\n createLink: u(createLink),\n createLinkSync\n}\n", "'use strict'\n\nconst path = require('path')\nconst fs = require('graceful-fs')\nconst pathExists = require('../path-exists').pathExists\n\n/**\n * Function that returns two types of paths, one relative to symlink, and one\n * relative to the current working directory. Checks if path is absolute or\n * relative. If the path is relative, this function checks if the path is\n * relative to symlink or relative to current working directory. This is an\n * initiative to find a smarter `srcpath` to supply when building symlinks.\n * This allows you to determine which path to use out of one of three possible\n * types of source paths. The first is an absolute path. This is detected by\n * `path.isAbsolute()`. When an absolute path is provided, it is checked to\n * see if it exists. If it does it's used, if not an error is returned\n * (callback)/ thrown (sync). The other two options for `srcpath` are a\n * relative url. By default Node's `fs.symlink` works by creating a symlink\n * using `dstpath` and expects the `srcpath` to be relative to the newly\n * created symlink. If you provide a `srcpath` that does not exist on the file\n * system it results in a broken symlink. To minimize this, the function\n * checks to see if the 'relative to symlink' source file exists, and if it\n * does it will use it. If it does not, it checks if there's a file that\n * exists that is relative to the current working directory, if does its used.\n * This preserves the expectations of the original fs.symlink spec and adds\n * the ability to pass in `relative to current working direcotry` paths.\n */\n\nfunction symlinkPaths (srcpath, dstpath, callback) {\n if (path.isAbsolute(srcpath)) {\n return fs.lstat(srcpath, (err) => {\n if (err) {\n err.message = err.message.replace('lstat', 'ensureSymlink')\n return callback(err)\n }\n return callback(null, {\n toCwd: srcpath,\n toDst: srcpath\n })\n })\n } else {\n const dstdir = path.dirname(dstpath)\n const relativeToDst = path.join(dstdir, srcpath)\n return pathExists(relativeToDst, (err, exists) => {\n if (err) return callback(err)\n if (exists) {\n return callback(null, {\n toCwd: relativeToDst,\n toDst: srcpath\n })\n } else {\n return fs.lstat(srcpath, (err) => {\n if (err) {\n err.message = err.message.replace('lstat', 'ensureSymlink')\n return callback(err)\n }\n return callback(null, {\n toCwd: srcpath,\n toDst: path.relative(dstdir, srcpath)\n })\n })\n }\n })\n }\n}\n\nfunction symlinkPathsSync (srcpath, dstpath) {\n let exists\n if (path.isAbsolute(srcpath)) {\n exists = fs.existsSync(srcpath)\n if (!exists) throw new Error('absolute srcpath does not exist')\n return {\n toCwd: srcpath,\n toDst: srcpath\n }\n } else {\n const dstdir = path.dirname(dstpath)\n const relativeToDst = path.join(dstdir, srcpath)\n exists = fs.existsSync(relativeToDst)\n if (exists) {\n return {\n toCwd: relativeToDst,\n toDst: srcpath\n }\n } else {\n exists = fs.existsSync(srcpath)\n if (!exists) throw new Error('relative srcpath does not exist')\n return {\n toCwd: srcpath,\n toDst: path.relative(dstdir, srcpath)\n }\n }\n }\n}\n\nmodule.exports = {\n symlinkPaths,\n symlinkPathsSync\n}\n", "'use strict'\n\nconst fs = require('graceful-fs')\n\nfunction symlinkType (srcpath, type, callback) {\n callback = (typeof type === 'function') ? type : callback\n type = (typeof type === 'function') ? false : type\n if (type) return callback(null, type)\n fs.lstat(srcpath, (err, stats) => {\n if (err) return callback(null, 'file')\n type = (stats && stats.isDirectory()) ? 'dir' : 'file'\n callback(null, type)\n })\n}\n\nfunction symlinkTypeSync (srcpath, type) {\n let stats\n\n if (type) return type\n try {\n stats = fs.lstatSync(srcpath)\n } catch {\n return 'file'\n }\n return (stats && stats.isDirectory()) ? 'dir' : 'file'\n}\n\nmodule.exports = {\n symlinkType,\n symlinkTypeSync\n}\n", "'use strict'\n\nconst u = require('universalify').fromCallback\nconst path = require('path')\nconst fs = require('../fs')\nconst _mkdirs = require('../mkdirs')\nconst mkdirs = _mkdirs.mkdirs\nconst mkdirsSync = _mkdirs.mkdirsSync\n\nconst _symlinkPaths = require('./symlink-paths')\nconst symlinkPaths = _symlinkPaths.symlinkPaths\nconst symlinkPathsSync = _symlinkPaths.symlinkPathsSync\n\nconst _symlinkType = require('./symlink-type')\nconst symlinkType = _symlinkType.symlinkType\nconst symlinkTypeSync = _symlinkType.symlinkTypeSync\n\nconst pathExists = require('../path-exists').pathExists\n\nconst { areIdentical } = require('../util/stat')\n\nfunction createSymlink (srcpath, dstpath, type, callback) {\n callback = (typeof type === 'function') ? type : callback\n type = (typeof type === 'function') ? false : type\n\n fs.lstat(dstpath, (err, stats) => {\n if (!err && stats.isSymbolicLink()) {\n Promise.all([\n fs.stat(srcpath),\n fs.stat(dstpath)\n ]).then(([srcStat, dstStat]) => {\n if (areIdentical(srcStat, dstStat)) return callback(null)\n _createSymlink(srcpath, dstpath, type, callback)\n })\n } else _createSymlink(srcpath, dstpath, type, callback)\n })\n}\n\nfunction _createSymlink (srcpath, dstpath, type, callback) {\n symlinkPaths(srcpath, dstpath, (err, relative) => {\n if (err) return callback(err)\n srcpath = relative.toDst\n symlinkType(relative.toCwd, type, (err, type) => {\n if (err) return callback(err)\n const dir = path.dirname(dstpath)\n pathExists(dir, (err, dirExists) => {\n if (err) return callback(err)\n if (dirExists) return fs.symlink(srcpath, dstpath, type, callback)\n mkdirs(dir, err => {\n if (err) return callback(err)\n fs.symlink(srcpath, dstpath, type, callback)\n })\n })\n })\n })\n}\n\nfunction createSymlinkSync (srcpath, dstpath, type) {\n let stats\n try {\n stats = fs.lstatSync(dstpath)\n } catch {}\n if (stats && stats.isSymbolicLink()) {\n const srcStat = fs.statSync(srcpath)\n const dstStat = fs.statSync(dstpath)\n if (areIdentical(srcStat, dstStat)) return\n }\n\n const relative = symlinkPathsSync(srcpath, dstpath)\n srcpath = relative.toDst\n type = symlinkTypeSync(relative.toCwd, type)\n const dir = path.dirname(dstpath)\n const exists = fs.existsSync(dir)\n if (exists) return fs.symlinkSync(srcpath, dstpath, type)\n mkdirsSync(dir)\n return fs.symlinkSync(srcpath, dstpath, type)\n}\n\nmodule.exports = {\n createSymlink: u(createSymlink),\n createSymlinkSync\n}\n", "'use strict'\n\nconst file = require('./file')\nconst link = require('./link')\nconst symlink = require('./symlink')\n\nmodule.exports = {\n // file\n createFile: file.createFile,\n createFileSync: file.createFileSync,\n ensureFile: file.createFile,\n ensureFileSync: file.createFileSync,\n // link\n createLink: link.createLink,\n createLinkSync: link.createLinkSync,\n ensureLink: link.createLink,\n ensureLinkSync: link.createLinkSync,\n // symlink\n createSymlink: symlink.createSymlink,\n createSymlinkSync: symlink.createSymlinkSync,\n ensureSymlink: symlink.createSymlink,\n ensureSymlinkSync: symlink.createSymlinkSync\n}\n", "function stringify (obj, { EOL = '\\n', finalEOL = true, replacer = null, spaces } = {}) {\n const EOF = finalEOL ? EOL : ''\n const str = JSON.stringify(obj, replacer, spaces)\n\n return str.replace(/\\n/g, EOL) + EOF\n}\n\nfunction stripBom (content) {\n // we do this because JSON.parse would convert it to a utf8 string if encoding wasn't specified\n if (Buffer.isBuffer(content)) content = content.toString('utf8')\n return content.replace(/^\\uFEFF/, '')\n}\n\nmodule.exports = { stringify, stripBom }\n", "let _fs\ntry {\n _fs = require('graceful-fs')\n} catch (_) {\n _fs = require('fs')\n}\nconst universalify = require('universalify')\nconst { stringify, stripBom } = require('./utils')\n\nasync function _readFile (file, options = {}) {\n if (typeof options === 'string') {\n options = { encoding: options }\n }\n\n const fs = options.fs || _fs\n\n const shouldThrow = 'throws' in options ? options.throws : true\n\n let data = await universalify.fromCallback(fs.readFile)(file, options)\n\n data = stripBom(data)\n\n let obj\n try {\n obj = JSON.parse(data, options ? options.reviver : null)\n } catch (err) {\n if (shouldThrow) {\n err.message = `${file}: ${err.message}`\n throw err\n } else {\n return null\n }\n }\n\n return obj\n}\n\nconst readFile = universalify.fromPromise(_readFile)\n\nfunction readFileSync (file, options = {}) {\n if (typeof options === 'string') {\n options = { encoding: options }\n }\n\n const fs = options.fs || _fs\n\n const shouldThrow = 'throws' in options ? options.throws : true\n\n try {\n let content = fs.readFileSync(file, options)\n content = stripBom(content)\n return JSON.parse(content, options.reviver)\n } catch (err) {\n if (shouldThrow) {\n err.message = `${file}: ${err.message}`\n throw err\n } else {\n return null\n }\n }\n}\n\nasync function _writeFile (file, obj, options = {}) {\n const fs = options.fs || _fs\n\n const str = stringify(obj, options)\n\n await universalify.fromCallback(fs.writeFile)(file, str, options)\n}\n\nconst writeFile = universalify.fromPromise(_writeFile)\n\nfunction writeFileSync (file, obj, options = {}) {\n const fs = options.fs || _fs\n\n const str = stringify(obj, options)\n // not sure if fs.writeFileSync returns anything, but just in case\n return fs.writeFileSync(file, str, options)\n}\n\nconst jsonfile = {\n readFile,\n readFileSync,\n writeFile,\n writeFileSync\n}\n\nmodule.exports = jsonfile\n", "'use strict'\n\nconst jsonFile = require('jsonfile')\n\nmodule.exports = {\n // jsonfile exports\n readJson: jsonFile.readFile,\n readJsonSync: jsonFile.readFileSync,\n writeJson: jsonFile.writeFile,\n writeJsonSync: jsonFile.writeFileSync\n}\n", "'use strict'\n\nconst u = require('universalify').fromCallback\nconst fs = require('graceful-fs')\nconst path = require('path')\nconst mkdir = require('../mkdirs')\nconst pathExists = require('../path-exists').pathExists\n\nfunction outputFile (file, data, encoding, callback) {\n if (typeof encoding === 'function') {\n callback = encoding\n encoding = 'utf8'\n }\n\n const dir = path.dirname(file)\n pathExists(dir, (err, itDoes) => {\n if (err) return callback(err)\n if (itDoes) return fs.writeFile(file, data, encoding, callback)\n\n mkdir.mkdirs(dir, err => {\n if (err) return callback(err)\n\n fs.writeFile(file, data, encoding, callback)\n })\n })\n}\n\nfunction outputFileSync (file, ...args) {\n const dir = path.dirname(file)\n if (fs.existsSync(dir)) {\n return fs.writeFileSync(file, ...args)\n }\n mkdir.mkdirsSync(dir)\n fs.writeFileSync(file, ...args)\n}\n\nmodule.exports = {\n outputFile: u(outputFile),\n outputFileSync\n}\n", "'use strict'\n\nconst { stringify } = require('jsonfile/utils')\nconst { outputFile } = require('../output')\n\nasync function outputJson (file, data, options = {}) {\n const str = stringify(data, options)\n\n await outputFile(file, str, options)\n}\n\nmodule.exports = outputJson\n", "'use strict'\n\nconst { stringify } = require('jsonfile/utils')\nconst { outputFileSync } = require('../output')\n\nfunction outputJsonSync (file, data, options) {\n const str = stringify(data, options)\n\n outputFileSync(file, str, options)\n}\n\nmodule.exports = outputJsonSync\n", "'use strict'\n\nconst u = require('universalify').fromPromise\nconst jsonFile = require('./jsonfile')\n\njsonFile.outputJson = u(require('./output-json'))\njsonFile.outputJsonSync = require('./output-json-sync')\n// aliases\njsonFile.outputJSON = jsonFile.outputJson\njsonFile.outputJSONSync = jsonFile.outputJsonSync\njsonFile.writeJSON = jsonFile.writeJson\njsonFile.writeJSONSync = jsonFile.writeJsonSync\njsonFile.readJSON = jsonFile.readJson\njsonFile.readJSONSync = jsonFile.readJsonSync\n\nmodule.exports = jsonFile\n", "'use strict'\n\nconst fs = require('graceful-fs')\nconst path = require('path')\nconst copySync = require('../copy-sync').copySync\nconst removeSync = require('../remove').removeSync\nconst mkdirpSync = require('../mkdirs').mkdirpSync\nconst stat = require('../util/stat')\n\nfunction moveSync (src, dest, opts) {\n opts = opts || {}\n const overwrite = opts.overwrite || opts.clobber || false\n\n const { srcStat, isChangingCase = false } = stat.checkPathsSync(src, dest, 'move', opts)\n stat.checkParentPathsSync(src, srcStat, dest, 'move')\n if (!isParentRoot(dest)) mkdirpSync(path.dirname(dest))\n return doRename(src, dest, overwrite, isChangingCase)\n}\n\nfunction isParentRoot (dest) {\n const parent = path.dirname(dest)\n const parsedPath = path.parse(parent)\n return parsedPath.root === parent\n}\n\nfunction doRename (src, dest, overwrite, isChangingCase) {\n if (isChangingCase) return rename(src, dest, overwrite)\n if (overwrite) {\n removeSync(dest)\n return rename(src, dest, overwrite)\n }\n if (fs.existsSync(dest)) throw new Error('dest already exists.')\n return rename(src, dest, overwrite)\n}\n\nfunction rename (src, dest, overwrite) {\n try {\n fs.renameSync(src, dest)\n } catch (err) {\n if (err.code !== 'EXDEV') throw err\n return moveAcrossDevice(src, dest, overwrite)\n }\n}\n\nfunction moveAcrossDevice (src, dest, overwrite) {\n const opts = {\n overwrite,\n errorOnExist: true\n }\n copySync(src, dest, opts)\n return removeSync(src)\n}\n\nmodule.exports = moveSync\n", "'use strict'\n\nmodule.exports = {\n moveSync: require('./move-sync')\n}\n", "'use strict'\n\nconst fs = require('graceful-fs')\nconst path = require('path')\nconst copy = require('../copy').copy\nconst remove = require('../remove').remove\nconst mkdirp = require('../mkdirs').mkdirp\nconst pathExists = require('../path-exists').pathExists\nconst stat = require('../util/stat')\n\nfunction move (src, dest, opts, cb) {\n if (typeof opts === 'function') {\n cb = opts\n opts = {}\n }\n\n const overwrite = opts.overwrite || opts.clobber || false\n\n stat.checkPaths(src, dest, 'move', opts, (err, stats) => {\n if (err) return cb(err)\n const { srcStat, isChangingCase = false } = stats\n stat.checkParentPaths(src, srcStat, dest, 'move', err => {\n if (err) return cb(err)\n if (isParentRoot(dest)) return doRename(src, dest, overwrite, isChangingCase, cb)\n mkdirp(path.dirname(dest), err => {\n if (err) return cb(err)\n return doRename(src, dest, overwrite, isChangingCase, cb)\n })\n })\n })\n}\n\nfunction isParentRoot (dest) {\n const parent = path.dirname(dest)\n const parsedPath = path.parse(parent)\n return parsedPath.root === parent\n}\n\nfunction doRename (src, dest, overwrite, isChangingCase, cb) {\n if (isChangingCase) return rename(src, dest, overwrite, cb)\n if (overwrite) {\n return remove(dest, err => {\n if (err) return cb(err)\n return rename(src, dest, overwrite, cb)\n })\n }\n pathExists(dest, (err, destExists) => {\n if (err) return cb(err)\n if (destExists) return cb(new Error('dest already exists.'))\n return rename(src, dest, overwrite, cb)\n })\n}\n\nfunction rename (src, dest, overwrite, cb) {\n fs.rename(src, dest, err => {\n if (!err) return cb()\n if (err.code !== 'EXDEV') return cb(err)\n return moveAcrossDevice(src, dest, overwrite, cb)\n })\n}\n\nfunction moveAcrossDevice (src, dest, overwrite, cb) {\n const opts = {\n overwrite,\n errorOnExist: true\n }\n copy(src, dest, opts, err => {\n if (err) return cb(err)\n return remove(src, cb)\n })\n}\n\nmodule.exports = move\n", "'use strict'\n\nconst u = require('universalify').fromCallback\nmodule.exports = {\n move: u(require('./move'))\n}\n", "'use strict'\n\nmodule.exports = {\n // Export promiseified graceful-fs:\n ...require('./fs'),\n // Export extra methods:\n ...require('./copy-sync'),\n ...require('./copy'),\n ...require('./empty'),\n ...require('./ensure'),\n ...require('./json'),\n ...require('./mkdirs'),\n ...require('./move-sync'),\n ...require('./move'),\n ...require('./output'),\n ...require('./path-exists'),\n ...require('./remove')\n}\n", null, null, null, null, "// Note: this is the semver.org version of the spec that it implements\n// Not necessarily the package version of this code.\nconst SEMVER_SPEC_VERSION = '2.0.0'\n\nconst MAX_LENGTH = 256\nconst MAX_SAFE_INTEGER = Number.MAX_SAFE_INTEGER ||\n /* istanbul ignore next */ 9007199254740991\n\n// Max safe segment length for coercion.\nconst MAX_SAFE_COMPONENT_LENGTH = 16\n\nmodule.exports = {\n SEMVER_SPEC_VERSION,\n MAX_LENGTH,\n MAX_SAFE_INTEGER,\n MAX_SAFE_COMPONENT_LENGTH\n}\n", "const debug = (\n typeof process === 'object' &&\n process.env &&\n process.env.NODE_DEBUG &&\n /\\bsemver\\b/i.test(process.env.NODE_DEBUG)\n) ? (...args) => console.error('SEMVER', ...args)\n : () => {}\n\nmodule.exports = debug\n", "const { MAX_SAFE_COMPONENT_LENGTH } = require('./constants')\nconst debug = require('./debug')\nexports = module.exports = {}\n\n// The actual regexps go on exports.re\nconst re = exports.re = []\nconst src = exports.src = []\nconst t = exports.t = {}\nlet R = 0\n\nconst createToken = (name, value, isGlobal) => {\n const index = R++\n debug(index, value)\n t[name] = index\n src[index] = value\n re[index] = new RegExp(value, isGlobal ? 'g' : undefined)\n}\n\n// The following Regular Expressions can be used for tokenizing,\n// validating, and parsing SemVer version strings.\n\n// ## Numeric Identifier\n// A single `0`, or a non-zero digit followed by zero or more digits.\n\ncreateToken('NUMERICIDENTIFIER', '0|[1-9]\\\\d*')\ncreateToken('NUMERICIDENTIFIERLOOSE', '[0-9]+')\n\n// ## Non-numeric Identifier\n// Zero or more digits, followed by a letter or hyphen, and then zero or\n// more letters, digits, or hyphens.\n\ncreateToken('NONNUMERICIDENTIFIER', '\\\\d*[a-zA-Z-][a-zA-Z0-9-]*')\n\n// ## Main Version\n// Three dot-separated numeric identifiers.\n\ncreateToken('MAINVERSION', `(${src[t.NUMERICIDENTIFIER]})\\\\.` +\n `(${src[t.NUMERICIDENTIFIER]})\\\\.` +\n `(${src[t.NUMERICIDENTIFIER]})`)\n\ncreateToken('MAINVERSIONLOOSE', `(${src[t.NUMERICIDENTIFIERLOOSE]})\\\\.` +\n `(${src[t.NUMERICIDENTIFIERLOOSE]})\\\\.` +\n `(${src[t.NUMERICIDENTIFIERLOOSE]})`)\n\n// ## Pre-release Version Identifier\n// A numeric identifier, or a non-numeric identifier.\n\ncreateToken('PRERELEASEIDENTIFIER', `(?:${src[t.NUMERICIDENTIFIER]\n}|${src[t.NONNUMERICIDENTIFIER]})`)\n\ncreateToken('PRERELEASEIDENTIFIERLOOSE', `(?:${src[t.NUMERICIDENTIFIERLOOSE]\n}|${src[t.NONNUMERICIDENTIFIER]})`)\n\n// ## Pre-release Version\n// Hyphen, followed by one or more dot-separated pre-release version\n// identifiers.\n\ncreateToken('PRERELEASE', `(?:-(${src[t.PRERELEASEIDENTIFIER]\n}(?:\\\\.${src[t.PRERELEASEIDENTIFIER]})*))`)\n\ncreateToken('PRERELEASELOOSE', `(?:-?(${src[t.PRERELEASEIDENTIFIERLOOSE]\n}(?:\\\\.${src[t.PRERELEASEIDENTIFIERLOOSE]})*))`)\n\n// ## Build Metadata Identifier\n// Any combination of digits, letters, or hyphens.\n\ncreateToken('BUILDIDENTIFIER', '[0-9A-Za-z-]+')\n\n// ## Build Metadata\n// Plus sign, followed by one or more period-separated build metadata\n// identifiers.\n\ncreateToken('BUILD', `(?:\\\\+(${src[t.BUILDIDENTIFIER]\n}(?:\\\\.${src[t.BUILDIDENTIFIER]})*))`)\n\n// ## Full Version String\n// A main version, followed optionally by a pre-release version and\n// build metadata.\n\n// Note that the only major, minor, patch, and pre-release sections of\n// the version string are capturing groups. The build metadata is not a\n// capturing group, because it should not ever be used in version\n// comparison.\n\ncreateToken('FULLPLAIN', `v?${src[t.MAINVERSION]\n}${src[t.PRERELEASE]}?${\n src[t.BUILD]}?`)\n\ncreateToken('FULL', `^${src[t.FULLPLAIN]}$`)\n\n// like full, but allows v1.2.3 and =1.2.3, which people do sometimes.\n// also, 1.0.0alpha1 (prerelease without the hyphen) which is pretty\n// common in the npm registry.\ncreateToken('LOOSEPLAIN', `[v=\\\\s]*${src[t.MAINVERSIONLOOSE]\n}${src[t.PRERELEASELOOSE]}?${\n src[t.BUILD]}?`)\n\ncreateToken('LOOSE', `^${src[t.LOOSEPLAIN]}$`)\n\ncreateToken('GTLT', '((?:<|>)?=?)')\n\n// Something like \"2.*\" or \"1.2.x\".\n// Note that \"x.x\" is a valid xRange identifer, meaning \"any version\"\n// Only the first item is strictly required.\ncreateToken('XRANGEIDENTIFIERLOOSE', `${src[t.NUMERICIDENTIFIERLOOSE]}|x|X|\\\\*`)\ncreateToken('XRANGEIDENTIFIER', `${src[t.NUMERICIDENTIFIER]}|x|X|\\\\*`)\n\ncreateToken('XRANGEPLAIN', `[v=\\\\s]*(${src[t.XRANGEIDENTIFIER]})` +\n `(?:\\\\.(${src[t.XRANGEIDENTIFIER]})` +\n `(?:\\\\.(${src[t.XRANGEIDENTIFIER]})` +\n `(?:${src[t.PRERELEASE]})?${\n src[t.BUILD]}?` +\n `)?)?`)\n\ncreateToken('XRANGEPLAINLOOSE', `[v=\\\\s]*(${src[t.XRANGEIDENTIFIERLOOSE]})` +\n `(?:\\\\.(${src[t.XRANGEIDENTIFIERLOOSE]})` +\n `(?:\\\\.(${src[t.XRANGEIDENTIFIERLOOSE]})` +\n `(?:${src[t.PRERELEASELOOSE]})?${\n src[t.BUILD]}?` +\n `)?)?`)\n\ncreateToken('XRANGE', `^${src[t.GTLT]}\\\\s*${src[t.XRANGEPLAIN]}$`)\ncreateToken('XRANGELOOSE', `^${src[t.GTLT]}\\\\s*${src[t.XRANGEPLAINLOOSE]}$`)\n\n// Coercion.\n// Extract anything that could conceivably be a part of a valid semver\ncreateToken('COERCE', `${'(^|[^\\\\d])' +\n '(\\\\d{1,'}${MAX_SAFE_COMPONENT_LENGTH}})` +\n `(?:\\\\.(\\\\d{1,${MAX_SAFE_COMPONENT_LENGTH}}))?` +\n `(?:\\\\.(\\\\d{1,${MAX_SAFE_COMPONENT_LENGTH}}))?` +\n `(?:$|[^\\\\d])`)\ncreateToken('COERCERTL', src[t.COERCE], true)\n\n// Tilde ranges.\n// Meaning is \"reasonably at or greater than\"\ncreateToken('LONETILDE', '(?:~>?)')\n\ncreateToken('TILDETRIM', `(\\\\s*)${src[t.LONETILDE]}\\\\s+`, true)\nexports.tildeTrimReplace = '$1~'\n\ncreateToken('TILDE', `^${src[t.LONETILDE]}${src[t.XRANGEPLAIN]}$`)\ncreateToken('TILDELOOSE', `^${src[t.LONETILDE]}${src[t.XRANGEPLAINLOOSE]}$`)\n\n// Caret ranges.\n// Meaning is \"at least and backwards compatible with\"\ncreateToken('LONECARET', '(?:\\\\^)')\n\ncreateToken('CARETTRIM', `(\\\\s*)${src[t.LONECARET]}\\\\s+`, true)\nexports.caretTrimReplace = '$1^'\n\ncreateToken('CARET', `^${src[t.LONECARET]}${src[t.XRANGEPLAIN]}$`)\ncreateToken('CARETLOOSE', `^${src[t.LONECARET]}${src[t.XRANGEPLAINLOOSE]}$`)\n\n// A simple gt/lt/eq thing, or just \"\" to indicate \"any version\"\ncreateToken('COMPARATORLOOSE', `^${src[t.GTLT]}\\\\s*(${src[t.LOOSEPLAIN]})$|^$`)\ncreateToken('COMPARATOR', `^${src[t.GTLT]}\\\\s*(${src[t.FULLPLAIN]})$|^$`)\n\n// An expression to strip any whitespace between the gtlt and the thing\n// it modifies, so that `> 1.2.3` ==> `>1.2.3`\ncreateToken('COMPARATORTRIM', `(\\\\s*)${src[t.GTLT]\n}\\\\s*(${src[t.LOOSEPLAIN]}|${src[t.XRANGEPLAIN]})`, true)\nexports.comparatorTrimReplace = '$1$2$3'\n\n// Something like `1.2.3 - 1.2.4`\n// Note that these all use the loose form, because they'll be\n// checked against either the strict or loose comparator form\n// later.\ncreateToken('HYPHENRANGE', `^\\\\s*(${src[t.XRANGEPLAIN]})` +\n `\\\\s+-\\\\s+` +\n `(${src[t.XRANGEPLAIN]})` +\n `\\\\s*$`)\n\ncreateToken('HYPHENRANGELOOSE', `^\\\\s*(${src[t.XRANGEPLAINLOOSE]})` +\n `\\\\s+-\\\\s+` +\n `(${src[t.XRANGEPLAINLOOSE]})` +\n `\\\\s*$`)\n\n// Star ranges basically just allow anything at all.\ncreateToken('STAR', '(<|>)?=?\\\\s*\\\\*')\n// >=0.0.0 is like a star\ncreateToken('GTE0', '^\\\\s*>=\\\\s*0\\.0\\.0\\\\s*$')\ncreateToken('GTE0PRE', '^\\\\s*>=\\\\s*0\\.0\\.0-0\\\\s*$')\n", "// parse out just the options we care about so we always get a consistent\n// obj with keys in a consistent order.\nconst opts = ['includePrerelease', 'loose', 'rtl']\nconst parseOptions = options =>\n !options ? {}\n : typeof options !== 'object' ? { loose: true }\n : opts.filter(k => options[k]).reduce((options, k) => {\n options[k] = true\n return options\n }, {})\nmodule.exports = parseOptions\n", "const numeric = /^[0-9]+$/\nconst compareIdentifiers = (a, b) => {\n const anum = numeric.test(a)\n const bnum = numeric.test(b)\n\n if (anum && bnum) {\n a = +a\n b = +b\n }\n\n return a === b ? 0\n : (anum && !bnum) ? -1\n : (bnum && !anum) ? 1\n : a < b ? -1\n : 1\n}\n\nconst rcompareIdentifiers = (a, b) => compareIdentifiers(b, a)\n\nmodule.exports = {\n compareIdentifiers,\n rcompareIdentifiers\n}\n", "const debug = require('../internal/debug')\nconst { MAX_LENGTH, MAX_SAFE_INTEGER } = require('../internal/constants')\nconst { re, t } = require('../internal/re')\n\nconst parseOptions = require('../internal/parse-options')\nconst { compareIdentifiers } = require('../internal/identifiers')\nclass SemVer {\n constructor (version, options) {\n options = parseOptions(options)\n\n if (version instanceof SemVer) {\n if (version.loose === !!options.loose &&\n version.includePrerelease === !!options.includePrerelease) {\n return version\n } else {\n version = version.version\n }\n } else if (typeof version !== 'string') {\n throw new TypeError(`Invalid Version: ${version}`)\n }\n\n if (version.length > MAX_LENGTH) {\n throw new TypeError(\n `version is longer than ${MAX_LENGTH} characters`\n )\n }\n\n debug('SemVer', version, options)\n this.options = options\n this.loose = !!options.loose\n // this isn't actually relevant for versions, but keep it so that we\n // don't run into trouble passing this.options around.\n this.includePrerelease = !!options.includePrerelease\n\n const m = version.trim().match(options.loose ? re[t.LOOSE] : re[t.FULL])\n\n if (!m) {\n throw new TypeError(`Invalid Version: ${version}`)\n }\n\n this.raw = version\n\n // these are actually numbers\n this.major = +m[1]\n this.minor = +m[2]\n this.patch = +m[3]\n\n if (this.major > MAX_SAFE_INTEGER || this.major < 0) {\n throw new TypeError('Invalid major version')\n }\n\n if (this.minor > MAX_SAFE_INTEGER || this.minor < 0) {\n throw new TypeError('Invalid minor version')\n }\n\n if (this.patch > MAX_SAFE_INTEGER || this.patch < 0) {\n throw new TypeError('Invalid patch version')\n }\n\n // numberify any prerelease numeric ids\n if (!m[4]) {\n this.prerelease = []\n } else {\n this.prerelease = m[4].split('.').map((id) => {\n if (/^[0-9]+$/.test(id)) {\n const num = +id\n if (num >= 0 && num < MAX_SAFE_INTEGER) {\n return num\n }\n }\n return id\n })\n }\n\n this.build = m[5] ? m[5].split('.') : []\n this.format()\n }\n\n format () {\n this.version = `${this.major}.${this.minor}.${this.patch}`\n if (this.prerelease.length) {\n this.version += `-${this.prerelease.join('.')}`\n }\n return this.version\n }\n\n toString () {\n return this.version\n }\n\n compare (other) {\n debug('SemVer.compare', this.version, this.options, other)\n if (!(other instanceof SemVer)) {\n if (typeof other === 'string' && other === this.version) {\n return 0\n }\n other = new SemVer(other, this.options)\n }\n\n if (other.version === this.version) {\n return 0\n }\n\n return this.compareMain(other) || this.comparePre(other)\n }\n\n compareMain (other) {\n if (!(other instanceof SemVer)) {\n other = new SemVer(other, this.options)\n }\n\n return (\n compareIdentifiers(this.major, other.major) ||\n compareIdentifiers(this.minor, other.minor) ||\n compareIdentifiers(this.patch, other.patch)\n )\n }\n\n comparePre (other) {\n if (!(other instanceof SemVer)) {\n other = new SemVer(other, this.options)\n }\n\n // NOT having a prerelease is > having one\n if (this.prerelease.length && !other.prerelease.length) {\n return -1\n } else if (!this.prerelease.length && other.prerelease.length) {\n return 1\n } else if (!this.prerelease.length && !other.prerelease.length) {\n return 0\n }\n\n let i = 0\n do {\n const a = this.prerelease[i]\n const b = other.prerelease[i]\n debug('prerelease compare', i, a, b)\n if (a === undefined && b === undefined) {\n return 0\n } else if (b === undefined) {\n return 1\n } else if (a === undefined) {\n return -1\n } else if (a === b) {\n continue\n } else {\n return compareIdentifiers(a, b)\n }\n } while (++i)\n }\n\n compareBuild (other) {\n if (!(other instanceof SemVer)) {\n other = new SemVer(other, this.options)\n }\n\n let i = 0\n do {\n const a = this.build[i]\n const b = other.build[i]\n debug('prerelease compare', i, a, b)\n if (a === undefined && b === undefined) {\n return 0\n } else if (b === undefined) {\n return 1\n } else if (a === undefined) {\n return -1\n } else if (a === b) {\n continue\n } else {\n return compareIdentifiers(a, b)\n }\n } while (++i)\n }\n\n // preminor will bump the version up to the next minor release, and immediately\n // down to pre-release. premajor and prepatch work the same way.\n inc (release, identifier) {\n switch (release) {\n case 'premajor':\n this.prerelease.length = 0\n this.patch = 0\n this.minor = 0\n this.major++\n this.inc('pre', identifier)\n break\n case 'preminor':\n this.prerelease.length = 0\n this.patch = 0\n this.minor++\n this.inc('pre', identifier)\n break\n case 'prepatch':\n // If this is already a prerelease, it will bump to the next version\n // drop any prereleases that might already exist, since they are not\n // relevant at this point.\n this.prerelease.length = 0\n this.inc('patch', identifier)\n this.inc('pre', identifier)\n break\n // If the input is a non-prerelease version, this acts the same as\n // prepatch.\n case 'prerelease':\n if (this.prerelease.length === 0) {\n this.inc('patch', identifier)\n }\n this.inc('pre', identifier)\n break\n\n case 'major':\n // If this is a pre-major version, bump up to the same major version.\n // Otherwise increment major.\n // 1.0.0-5 bumps to 1.0.0\n // 1.1.0 bumps to 2.0.0\n if (\n this.minor !== 0 ||\n this.patch !== 0 ||\n this.prerelease.length === 0\n ) {\n this.major++\n }\n this.minor = 0\n this.patch = 0\n this.prerelease = []\n break\n case 'minor':\n // If this is a pre-minor version, bump up to the same minor version.\n // Otherwise increment minor.\n // 1.2.0-5 bumps to 1.2.0\n // 1.2.1 bumps to 1.3.0\n if (this.patch !== 0 || this.prerelease.length === 0) {\n this.minor++\n }\n this.patch = 0\n this.prerelease = []\n break\n case 'patch':\n // If this is not a pre-release version, it will increment the patch.\n // If it is a pre-release it will bump up to the same patch version.\n // 1.2.0-5 patches to 1.2.0\n // 1.2.0 patches to 1.2.1\n if (this.prerelease.length === 0) {\n this.patch++\n }\n this.prerelease = []\n break\n // This probably shouldn't be used publicly.\n // 1.0.0 'pre' would become 1.0.0-0 which is the wrong direction.\n case 'pre':\n if (this.prerelease.length === 0) {\n this.prerelease = [0]\n } else {\n let i = this.prerelease.length\n while (--i >= 0) {\n if (typeof this.prerelease[i] === 'number') {\n this.prerelease[i]++\n i = -2\n }\n }\n if (i === -1) {\n // didn't increment anything\n this.prerelease.push(0)\n }\n }\n if (identifier) {\n // 1.2.0-beta.1 bumps to 1.2.0-beta.2,\n // 1.2.0-beta.fooblz or 1.2.0-beta bumps to 1.2.0-beta.0\n if (this.prerelease[0] === identifier) {\n if (isNaN(this.prerelease[1])) {\n this.prerelease = [identifier, 0]\n }\n } else {\n this.prerelease = [identifier, 0]\n }\n }\n break\n\n default:\n throw new Error(`invalid increment argument: ${release}`)\n }\n this.format()\n this.raw = this.version\n return this\n }\n}\n\nmodule.exports = SemVer\n", "const {MAX_LENGTH} = require('../internal/constants')\nconst { re, t } = require('../internal/re')\nconst SemVer = require('../classes/semver')\n\nconst parseOptions = require('../internal/parse-options')\nconst parse = (version, options) => {\n options = parseOptions(options)\n\n if (version instanceof SemVer) {\n return version\n }\n\n if (typeof version !== 'string') {\n return null\n }\n\n if (version.length > MAX_LENGTH) {\n return null\n }\n\n const r = options.loose ? re[t.LOOSE] : re[t.FULL]\n if (!r.test(version)) {\n return null\n }\n\n try {\n return new SemVer(version, options)\n } catch (er) {\n return null\n }\n}\n\nmodule.exports = parse\n", "const parse = require('./parse')\nconst valid = (version, options) => {\n const v = parse(version, options)\n return v ? v.version : null\n}\nmodule.exports = valid\n", "const parse = require('./parse')\nconst clean = (version, options) => {\n const s = parse(version.trim().replace(/^[=v]+/, ''), options)\n return s ? s.version : null\n}\nmodule.exports = clean\n", "const SemVer = require('../classes/semver')\n\nconst inc = (version, release, options, identifier) => {\n if (typeof (options) === 'string') {\n identifier = options\n options = undefined\n }\n\n try {\n return new SemVer(version, options).inc(release, identifier).version\n } catch (er) {\n return null\n }\n}\nmodule.exports = inc\n", "const SemVer = require('../classes/semver')\nconst compare = (a, b, loose) =>\n new SemVer(a, loose).compare(new SemVer(b, loose))\n\nmodule.exports = compare\n", "const compare = require('./compare')\nconst eq = (a, b, loose) => compare(a, b, loose) === 0\nmodule.exports = eq\n", "const parse = require('./parse')\nconst eq = require('./eq')\n\nconst diff = (version1, version2) => {\n if (eq(version1, version2)) {\n return null\n } else {\n const v1 = parse(version1)\n const v2 = parse(version2)\n const hasPre = v1.prerelease.length || v2.prerelease.length\n const prefix = hasPre ? 'pre' : ''\n const defaultResult = hasPre ? 'prerelease' : ''\n for (const key in v1) {\n if (key === 'major' || key === 'minor' || key === 'patch') {\n if (v1[key] !== v2[key]) {\n return prefix + key\n }\n }\n }\n return defaultResult // may be undefined\n }\n}\nmodule.exports = diff\n", "const SemVer = require('../classes/semver')\nconst major = (a, loose) => new SemVer(a, loose).major\nmodule.exports = major\n", "const SemVer = require('../classes/semver')\nconst minor = (a, loose) => new SemVer(a, loose).minor\nmodule.exports = minor\n", "const SemVer = require('../classes/semver')\nconst patch = (a, loose) => new SemVer(a, loose).patch\nmodule.exports = patch\n", "const parse = require('./parse')\nconst prerelease = (version, options) => {\n const parsed = parse(version, options)\n return (parsed && parsed.prerelease.length) ? parsed.prerelease : null\n}\nmodule.exports = prerelease\n", "const compare = require('./compare')\nconst rcompare = (a, b, loose) => compare(b, a, loose)\nmodule.exports = rcompare\n", "const compare = require('./compare')\nconst compareLoose = (a, b) => compare(a, b, true)\nmodule.exports = compareLoose\n", "const SemVer = require('../classes/semver')\nconst compareBuild = (a, b, loose) => {\n const versionA = new SemVer(a, loose)\n const versionB = new SemVer(b, loose)\n return versionA.compare(versionB) || versionA.compareBuild(versionB)\n}\nmodule.exports = compareBuild\n", "const compareBuild = require('./compare-build')\nconst sort = (list, loose) => list.sort((a, b) => compareBuild(a, b, loose))\nmodule.exports = sort\n", "const compareBuild = require('./compare-build')\nconst rsort = (list, loose) => list.sort((a, b) => compareBuild(b, a, loose))\nmodule.exports = rsort\n", "const compare = require('./compare')\nconst gt = (a, b, loose) => compare(a, b, loose) > 0\nmodule.exports = gt\n", "const compare = require('./compare')\nconst lt = (a, b, loose) => compare(a, b, loose) < 0\nmodule.exports = lt\n", "const compare = require('./compare')\nconst neq = (a, b, loose) => compare(a, b, loose) !== 0\nmodule.exports = neq\n", "const compare = require('./compare')\nconst gte = (a, b, loose) => compare(a, b, loose) >= 0\nmodule.exports = gte\n", "const compare = require('./compare')\nconst lte = (a, b, loose) => compare(a, b, loose) <= 0\nmodule.exports = lte\n", "const eq = require('./eq')\nconst neq = require('./neq')\nconst gt = require('./gt')\nconst gte = require('./gte')\nconst lt = require('./lt')\nconst lte = require('./lte')\n\nconst cmp = (a, op, b, loose) => {\n switch (op) {\n case '===':\n if (typeof a === 'object')\n a = a.version\n if (typeof b === 'object')\n b = b.version\n return a === b\n\n case '!==':\n if (typeof a === 'object')\n a = a.version\n if (typeof b === 'object')\n b = b.version\n return a !== b\n\n case '':\n case '=':\n case '==':\n return eq(a, b, loose)\n\n case '!=':\n return neq(a, b, loose)\n\n case '>':\n return gt(a, b, loose)\n\n case '>=':\n return gte(a, b, loose)\n\n case '<':\n return lt(a, b, loose)\n\n case '<=':\n return lte(a, b, loose)\n\n default:\n throw new TypeError(`Invalid operator: ${op}`)\n }\n}\nmodule.exports = cmp\n", "const SemVer = require('../classes/semver')\nconst parse = require('./parse')\nconst {re, t} = require('../internal/re')\n\nconst coerce = (version, options) => {\n if (version instanceof SemVer) {\n return version\n }\n\n if (typeof version === 'number') {\n version = String(version)\n }\n\n if (typeof version !== 'string') {\n return null\n }\n\n options = options || {}\n\n let match = null\n if (!options.rtl) {\n match = version.match(re[t.COERCE])\n } else {\n // Find the right-most coercible string that does not share\n // a terminus with a more left-ward coercible string.\n // Eg, '1.2.3.4' wants to coerce '2.3.4', not '3.4' or '4'\n //\n // Walk through the string checking with a /g regexp\n // Manually set the index so as to pick up overlapping matches.\n // Stop when we get a match that ends at the string end, since no\n // coercible string can be more right-ward without the same terminus.\n let next\n while ((next = re[t.COERCERTL].exec(version)) &&\n (!match || match.index + match[0].length !== version.length)\n ) {\n if (!match ||\n next.index + next[0].length !== match.index + match[0].length) {\n match = next\n }\n re[t.COERCERTL].lastIndex = next.index + next[1].length + next[2].length\n }\n // leave it in a clean state\n re[t.COERCERTL].lastIndex = -1\n }\n\n if (match === null)\n return null\n\n return parse(`${match[2]}.${match[3] || '0'}.${match[4] || '0'}`, options)\n}\nmodule.exports = coerce\n", "'use strict'\nmodule.exports = function (Yallist) {\n Yallist.prototype[Symbol.iterator] = function* () {\n for (let walker = this.head; walker; walker = walker.next) {\n yield walker.value\n }\n }\n}\n", "'use strict'\nmodule.exports = Yallist\n\nYallist.Node = Node\nYallist.create = Yallist\n\nfunction Yallist (list) {\n var self = this\n if (!(self instanceof Yallist)) {\n self = new Yallist()\n }\n\n self.tail = null\n self.head = null\n self.length = 0\n\n if (list && typeof list.forEach === 'function') {\n list.forEach(function (item) {\n self.push(item)\n })\n } else if (arguments.length > 0) {\n for (var i = 0, l = arguments.length; i < l; i++) {\n self.push(arguments[i])\n }\n }\n\n return self\n}\n\nYallist.prototype.removeNode = function (node) {\n if (node.list !== this) {\n throw new Error('removing node which does not belong to this list')\n }\n\n var next = node.next\n var prev = node.prev\n\n if (next) {\n next.prev = prev\n }\n\n if (prev) {\n prev.next = next\n }\n\n if (node === this.head) {\n this.head = next\n }\n if (node === this.tail) {\n this.tail = prev\n }\n\n node.list.length--\n node.next = null\n node.prev = null\n node.list = null\n\n return next\n}\n\nYallist.prototype.unshiftNode = function (node) {\n if (node === this.head) {\n return\n }\n\n if (node.list) {\n node.list.removeNode(node)\n }\n\n var head = this.head\n node.list = this\n node.next = head\n if (head) {\n head.prev = node\n }\n\n this.head = node\n if (!this.tail) {\n this.tail = node\n }\n this.length++\n}\n\nYallist.prototype.pushNode = function (node) {\n if (node === this.tail) {\n return\n }\n\n if (node.list) {\n node.list.removeNode(node)\n }\n\n var tail = this.tail\n node.list = this\n node.prev = tail\n if (tail) {\n tail.next = node\n }\n\n this.tail = node\n if (!this.head) {\n this.head = node\n }\n this.length++\n}\n\nYallist.prototype.push = function () {\n for (var i = 0, l = arguments.length; i < l; i++) {\n push(this, arguments[i])\n }\n return this.length\n}\n\nYallist.prototype.unshift = function () {\n for (var i = 0, l = arguments.length; i < l; i++) {\n unshift(this, arguments[i])\n }\n return this.length\n}\n\nYallist.prototype.pop = function () {\n if (!this.tail) {\n return undefined\n }\n\n var res = this.tail.value\n this.tail = this.tail.prev\n if (this.tail) {\n this.tail.next = null\n } else {\n this.head = null\n }\n this.length--\n return res\n}\n\nYallist.prototype.shift = function () {\n if (!this.head) {\n return undefined\n }\n\n var res = this.head.value\n this.head = this.head.next\n if (this.head) {\n this.head.prev = null\n } else {\n this.tail = null\n }\n this.length--\n return res\n}\n\nYallist.prototype.forEach = function (fn, thisp) {\n thisp = thisp || this\n for (var walker = this.head, i = 0; walker !== null; i++) {\n fn.call(thisp, walker.value, i, this)\n walker = walker.next\n }\n}\n\nYallist.prototype.forEachReverse = function (fn, thisp) {\n thisp = thisp || this\n for (var walker = this.tail, i = this.length - 1; walker !== null; i--) {\n fn.call(thisp, walker.value, i, this)\n walker = walker.prev\n }\n}\n\nYallist.prototype.get = function (n) {\n for (var i = 0, walker = this.head; walker !== null && i < n; i++) {\n // abort out of the list early if we hit a cycle\n walker = walker.next\n }\n if (i === n && walker !== null) {\n return walker.value\n }\n}\n\nYallist.prototype.getReverse = function (n) {\n for (var i = 0, walker = this.tail; walker !== null && i < n; i++) {\n // abort out of the list early if we hit a cycle\n walker = walker.prev\n }\n if (i === n && walker !== null) {\n return walker.value\n }\n}\n\nYallist.prototype.map = function (fn, thisp) {\n thisp = thisp || this\n var res = new Yallist()\n for (var walker = this.head; walker !== null;) {\n res.push(fn.call(thisp, walker.value, this))\n walker = walker.next\n }\n return res\n}\n\nYallist.prototype.mapReverse = function (fn, thisp) {\n thisp = thisp || this\n var res = new Yallist()\n for (var walker = this.tail; walker !== null;) {\n res.push(fn.call(thisp, walker.value, this))\n walker = walker.prev\n }\n return res\n}\n\nYallist.prototype.reduce = function (fn, initial) {\n var acc\n var walker = this.head\n if (arguments.length > 1) {\n acc = initial\n } else if (this.head) {\n walker = this.head.next\n acc = this.head.value\n } else {\n throw new TypeError('Reduce of empty list with no initial value')\n }\n\n for (var i = 0; walker !== null; i++) {\n acc = fn(acc, walker.value, i)\n walker = walker.next\n }\n\n return acc\n}\n\nYallist.prototype.reduceReverse = function (fn, initial) {\n var acc\n var walker = this.tail\n if (arguments.length > 1) {\n acc = initial\n } else if (this.tail) {\n walker = this.tail.prev\n acc = this.tail.value\n } else {\n throw new TypeError('Reduce of empty list with no initial value')\n }\n\n for (var i = this.length - 1; walker !== null; i--) {\n acc = fn(acc, walker.value, i)\n walker = walker.prev\n }\n\n return acc\n}\n\nYallist.prototype.toArray = function () {\n var arr = new Array(this.length)\n for (var i = 0, walker = this.head; walker !== null; i++) {\n arr[i] = walker.value\n walker = walker.next\n }\n return arr\n}\n\nYallist.prototype.toArrayReverse = function () {\n var arr = new Array(this.length)\n for (var i = 0, walker = this.tail; walker !== null; i++) {\n arr[i] = walker.value\n walker = walker.prev\n }\n return arr\n}\n\nYallist.prototype.slice = function (from, to) {\n to = to || this.length\n if (to < 0) {\n to += this.length\n }\n from = from || 0\n if (from < 0) {\n from += this.length\n }\n var ret = new Yallist()\n if (to < from || to < 0) {\n return ret\n }\n if (from < 0) {\n from = 0\n }\n if (to > this.length) {\n to = this.length\n }\n for (var i = 0, walker = this.head; walker !== null && i < from; i++) {\n walker = walker.next\n }\n for (; walker !== null && i < to; i++, walker = walker.next) {\n ret.push(walker.value)\n }\n return ret\n}\n\nYallist.prototype.sliceReverse = function (from, to) {\n to = to || this.length\n if (to < 0) {\n to += this.length\n }\n from = from || 0\n if (from < 0) {\n from += this.length\n }\n var ret = new Yallist()\n if (to < from || to < 0) {\n return ret\n }\n if (from < 0) {\n from = 0\n }\n if (to > this.length) {\n to = this.length\n }\n for (var i = this.length, walker = this.tail; walker !== null && i > to; i--) {\n walker = walker.prev\n }\n for (; walker !== null && i > from; i--, walker = walker.prev) {\n ret.push(walker.value)\n }\n return ret\n}\n\nYallist.prototype.splice = function (start, deleteCount, ...nodes) {\n if (start > this.length) {\n start = this.length - 1\n }\n if (start < 0) {\n start = this.length + start;\n }\n\n for (var i = 0, walker = this.head; walker !== null && i < start; i++) {\n walker = walker.next\n }\n\n var ret = []\n for (var i = 0; walker && i < deleteCount; i++) {\n ret.push(walker.value)\n walker = this.removeNode(walker)\n }\n if (walker === null) {\n walker = this.tail\n }\n\n if (walker !== this.head && walker !== this.tail) {\n walker = walker.prev\n }\n\n for (var i = 0; i < nodes.length; i++) {\n walker = insert(this, walker, nodes[i])\n }\n return ret;\n}\n\nYallist.prototype.reverse = function () {\n var head = this.head\n var tail = this.tail\n for (var walker = head; walker !== null; walker = walker.prev) {\n var p = walker.prev\n walker.prev = walker.next\n walker.next = p\n }\n this.head = tail\n this.tail = head\n return this\n}\n\nfunction insert (self, node, value) {\n var inserted = node === self.head ?\n new Node(value, null, node, self) :\n new Node(value, node, node.next, self)\n\n if (inserted.next === null) {\n self.tail = inserted\n }\n if (inserted.prev === null) {\n self.head = inserted\n }\n\n self.length++\n\n return inserted\n}\n\nfunction push (self, item) {\n self.tail = new Node(item, self.tail, null, self)\n if (!self.head) {\n self.head = self.tail\n }\n self.length++\n}\n\nfunction unshift (self, item) {\n self.head = new Node(item, null, self.head, self)\n if (!self.tail) {\n self.tail = self.head\n }\n self.length++\n}\n\nfunction Node (value, prev, next, list) {\n if (!(this instanceof Node)) {\n return new Node(value, prev, next, list)\n }\n\n this.list = list\n this.value = value\n\n if (prev) {\n prev.next = this\n this.prev = prev\n } else {\n this.prev = null\n }\n\n if (next) {\n next.prev = this\n this.next = next\n } else {\n this.next = null\n }\n}\n\ntry {\n // add if support for Symbol.iterator is present\n require('./iterator.js')(Yallist)\n} catch (er) {}\n", "'use strict'\n\n// A linked list to keep track of recently-used-ness\nconst Yallist = require('yallist')\n\nconst MAX = Symbol('max')\nconst LENGTH = Symbol('length')\nconst LENGTH_CALCULATOR = Symbol('lengthCalculator')\nconst ALLOW_STALE = Symbol('allowStale')\nconst MAX_AGE = Symbol('maxAge')\nconst DISPOSE = Symbol('dispose')\nconst NO_DISPOSE_ON_SET = Symbol('noDisposeOnSet')\nconst LRU_LIST = Symbol('lruList')\nconst CACHE = Symbol('cache')\nconst UPDATE_AGE_ON_GET = Symbol('updateAgeOnGet')\n\nconst naiveLength = () => 1\n\n// lruList is a yallist where the head is the youngest\n// item, and the tail is the oldest. the list contains the Hit\n// objects as the entries.\n// Each Hit object has a reference to its Yallist.Node. This\n// never changes.\n//\n// cache is a Map (or PseudoMap) that matches the keys to\n// the Yallist.Node object.\nclass LRUCache {\n constructor (options) {\n if (typeof options === 'number')\n options = { max: options }\n\n if (!options)\n options = {}\n\n if (options.max && (typeof options.max !== 'number' || options.max < 0))\n throw new TypeError('max must be a non-negative number')\n // Kind of weird to have a default max of Infinity, but oh well.\n const max = this[MAX] = options.max || Infinity\n\n const lc = options.length || naiveLength\n this[LENGTH_CALCULATOR] = (typeof lc !== 'function') ? naiveLength : lc\n this[ALLOW_STALE] = options.stale || false\n if (options.maxAge && typeof options.maxAge !== 'number')\n throw new TypeError('maxAge must be a number')\n this[MAX_AGE] = options.maxAge || 0\n this[DISPOSE] = options.dispose\n this[NO_DISPOSE_ON_SET] = options.noDisposeOnSet || false\n this[UPDATE_AGE_ON_GET] = options.updateAgeOnGet || false\n this.reset()\n }\n\n // resize the cache when the max changes.\n set max (mL) {\n if (typeof mL !== 'number' || mL < 0)\n throw new TypeError('max must be a non-negative number')\n\n this[MAX] = mL || Infinity\n trim(this)\n }\n get max () {\n return this[MAX]\n }\n\n set allowStale (allowStale) {\n this[ALLOW_STALE] = !!allowStale\n }\n get allowStale () {\n return this[ALLOW_STALE]\n }\n\n set maxAge (mA) {\n if (typeof mA !== 'number')\n throw new TypeError('maxAge must be a non-negative number')\n\n this[MAX_AGE] = mA\n trim(this)\n }\n get maxAge () {\n return this[MAX_AGE]\n }\n\n // resize the cache when the lengthCalculator changes.\n set lengthCalculator (lC) {\n if (typeof lC !== 'function')\n lC = naiveLength\n\n if (lC !== this[LENGTH_CALCULATOR]) {\n this[LENGTH_CALCULATOR] = lC\n this[LENGTH] = 0\n this[LRU_LIST].forEach(hit => {\n hit.length = this[LENGTH_CALCULATOR](hit.value, hit.key)\n this[LENGTH] += hit.length\n })\n }\n trim(this)\n }\n get lengthCalculator () { return this[LENGTH_CALCULATOR] }\n\n get length () { return this[LENGTH] }\n get itemCount () { return this[LRU_LIST].length }\n\n rforEach (fn, thisp) {\n thisp = thisp || this\n for (let walker = this[LRU_LIST].tail; walker !== null;) {\n const prev = walker.prev\n forEachStep(this, fn, walker, thisp)\n walker = prev\n }\n }\n\n forEach (fn, thisp) {\n thisp = thisp || this\n for (let walker = this[LRU_LIST].head; walker !== null;) {\n const next = walker.next\n forEachStep(this, fn, walker, thisp)\n walker = next\n }\n }\n\n keys () {\n return this[LRU_LIST].toArray().map(k => k.key)\n }\n\n values () {\n return this[LRU_LIST].toArray().map(k => k.value)\n }\n\n reset () {\n if (this[DISPOSE] &&\n this[LRU_LIST] &&\n this[LRU_LIST].length) {\n this[LRU_LIST].forEach(hit => this[DISPOSE](hit.key, hit.value))\n }\n\n this[CACHE] = new Map() // hash of items by key\n this[LRU_LIST] = new Yallist() // list of items in order of use recency\n this[LENGTH] = 0 // length of items in the list\n }\n\n dump () {\n return this[LRU_LIST].map(hit =>\n isStale(this, hit) ? false : {\n k: hit.key,\n v: hit.value,\n e: hit.now + (hit.maxAge || 0)\n }).toArray().filter(h => h)\n }\n\n dumpLru () {\n return this[LRU_LIST]\n }\n\n set (key, value, maxAge) {\n maxAge = maxAge || this[MAX_AGE]\n\n if (maxAge && typeof maxAge !== 'number')\n throw new TypeError('maxAge must be a number')\n\n const now = maxAge ? Date.now() : 0\n const len = this[LENGTH_CALCULATOR](value, key)\n\n if (this[CACHE].has(key)) {\n if (len > this[MAX]) {\n del(this, this[CACHE].get(key))\n return false\n }\n\n const node = this[CACHE].get(key)\n const item = node.value\n\n // dispose of the old one before overwriting\n // split out into 2 ifs for better coverage tracking\n if (this[DISPOSE]) {\n if (!this[NO_DISPOSE_ON_SET])\n this[DISPOSE](key, item.value)\n }\n\n item.now = now\n item.maxAge = maxAge\n item.value = value\n this[LENGTH] += len - item.length\n item.length = len\n this.get(key)\n trim(this)\n return true\n }\n\n const hit = new Entry(key, value, len, now, maxAge)\n\n // oversized objects fall out of cache automatically.\n if (hit.length > this[MAX]) {\n if (this[DISPOSE])\n this[DISPOSE](key, value)\n\n return false\n }\n\n this[LENGTH] += hit.length\n this[LRU_LIST].unshift(hit)\n this[CACHE].set(key, this[LRU_LIST].head)\n trim(this)\n return true\n }\n\n has (key) {\n if (!this[CACHE].has(key)) return false\n const hit = this[CACHE].get(key).value\n return !isStale(this, hit)\n }\n\n get (key) {\n return get(this, key, true)\n }\n\n peek (key) {\n return get(this, key, false)\n }\n\n pop () {\n const node = this[LRU_LIST].tail\n if (!node)\n return null\n\n del(this, node)\n return node.value\n }\n\n del (key) {\n del(this, this[CACHE].get(key))\n }\n\n load (arr) {\n // reset the cache\n this.reset()\n\n const now = Date.now()\n // A previous serialized cache has the most recent items first\n for (let l = arr.length - 1; l >= 0; l--) {\n const hit = arr[l]\n const expiresAt = hit.e || 0\n if (expiresAt === 0)\n // the item was created without expiration in a non aged cache\n this.set(hit.k, hit.v)\n else {\n const maxAge = expiresAt - now\n // dont add already expired items\n if (maxAge > 0) {\n this.set(hit.k, hit.v, maxAge)\n }\n }\n }\n }\n\n prune () {\n this[CACHE].forEach((value, key) => get(this, key, false))\n }\n}\n\nconst get = (self, key, doUse) => {\n const node = self[CACHE].get(key)\n if (node) {\n const hit = node.value\n if (isStale(self, hit)) {\n del(self, node)\n if (!self[ALLOW_STALE])\n return undefined\n } else {\n if (doUse) {\n if (self[UPDATE_AGE_ON_GET])\n node.value.now = Date.now()\n self[LRU_LIST].unshiftNode(node)\n }\n }\n return hit.value\n }\n}\n\nconst isStale = (self, hit) => {\n if (!hit || (!hit.maxAge && !self[MAX_AGE]))\n return false\n\n const diff = Date.now() - hit.now\n return hit.maxAge ? diff > hit.maxAge\n : self[MAX_AGE] && (diff > self[MAX_AGE])\n}\n\nconst trim = self => {\n if (self[LENGTH] > self[MAX]) {\n for (let walker = self[LRU_LIST].tail;\n self[LENGTH] > self[MAX] && walker !== null;) {\n // We know that we're about to delete this one, and also\n // what the next least recently used key will be, so just\n // go ahead and set it now.\n const prev = walker.prev\n del(self, walker)\n walker = prev\n }\n }\n}\n\nconst del = (self, node) => {\n if (node) {\n const hit = node.value\n if (self[DISPOSE])\n self[DISPOSE](hit.key, hit.value)\n\n self[LENGTH] -= hit.length\n self[CACHE].delete(hit.key)\n self[LRU_LIST].removeNode(node)\n }\n}\n\nclass Entry {\n constructor (key, value, length, now, maxAge) {\n this.key = key\n this.value = value\n this.length = length\n this.now = now\n this.maxAge = maxAge || 0\n }\n}\n\nconst forEachStep = (self, fn, node, thisp) => {\n let hit = node.value\n if (isStale(self, hit)) {\n del(self, node)\n if (!self[ALLOW_STALE])\n hit = undefined\n }\n if (hit)\n fn.call(thisp, hit.value, hit.key, self)\n}\n\nmodule.exports = LRUCache\n", "// hoisted class for cyclic dependency\nclass Range {\n constructor (range, options) {\n options = parseOptions(options)\n\n if (range instanceof Range) {\n if (\n range.loose === !!options.loose &&\n range.includePrerelease === !!options.includePrerelease\n ) {\n return range\n } else {\n return new Range(range.raw, options)\n }\n }\n\n if (range instanceof Comparator) {\n // just put it in the set and return\n this.raw = range.value\n this.set = [[range]]\n this.format()\n return this\n }\n\n this.options = options\n this.loose = !!options.loose\n this.includePrerelease = !!options.includePrerelease\n\n // First, split based on boolean or ||\n this.raw = range\n this.set = range\n .split(/\\s*\\|\\|\\s*/)\n // map the range to a 2d array of comparators\n .map(range => this.parseRange(range.trim()))\n // throw out any comparator lists that are empty\n // this generally means that it was not a valid range, which is allowed\n // in loose mode, but will still throw if the WHOLE range is invalid.\n .filter(c => c.length)\n\n if (!this.set.length) {\n throw new TypeError(`Invalid SemVer Range: ${range}`)\n }\n\n // if we have any that are not the null set, throw out null sets.\n if (this.set.length > 1) {\n // keep the first one, in case they're all null sets\n const first = this.set[0]\n this.set = this.set.filter(c => !isNullSet(c[0]))\n if (this.set.length === 0)\n this.set = [first]\n else if (this.set.length > 1) {\n // if we have any that are *, then the range is just *\n for (const c of this.set) {\n if (c.length === 1 && isAny(c[0])) {\n this.set = [c]\n break\n }\n }\n }\n }\n\n this.format()\n }\n\n format () {\n this.range = this.set\n .map((comps) => {\n return comps.join(' ').trim()\n })\n .join('||')\n .trim()\n return this.range\n }\n\n toString () {\n return this.range\n }\n\n parseRange (range) {\n range = range.trim()\n\n // memoize range parsing for performance.\n // this is a very hot path, and fully deterministic.\n const memoOpts = Object.keys(this.options).join(',')\n const memoKey = `parseRange:${memoOpts}:${range}`\n const cached = cache.get(memoKey)\n if (cached)\n return cached\n\n const loose = this.options.loose\n // `1.2.3 - 1.2.4` => `>=1.2.3 <=1.2.4`\n const hr = loose ? re[t.HYPHENRANGELOOSE] : re[t.HYPHENRANGE]\n range = range.replace(hr, hyphenReplace(this.options.includePrerelease))\n debug('hyphen replace', range)\n // `> 1.2.3 < 1.2.5` => `>1.2.3 <1.2.5`\n range = range.replace(re[t.COMPARATORTRIM], comparatorTrimReplace)\n debug('comparator trim', range, re[t.COMPARATORTRIM])\n\n // `~ 1.2.3` => `~1.2.3`\n range = range.replace(re[t.TILDETRIM], tildeTrimReplace)\n\n // `^ 1.2.3` => `^1.2.3`\n range = range.replace(re[t.CARETTRIM], caretTrimReplace)\n\n // normalize spaces\n range = range.split(/\\s+/).join(' ')\n\n // At this point, the range is completely trimmed and\n // ready to be split into comparators.\n\n const compRe = loose ? re[t.COMPARATORLOOSE] : re[t.COMPARATOR]\n const rangeList = range\n .split(' ')\n .map(comp => parseComparator(comp, this.options))\n .join(' ')\n .split(/\\s+/)\n // >=0.0.0 is equivalent to *\n .map(comp => replaceGTE0(comp, this.options))\n // in loose mode, throw out any that are not valid comparators\n .filter(this.options.loose ? comp => !!comp.match(compRe) : () => true)\n .map(comp => new Comparator(comp, this.options))\n\n // if any comparators are the null set, then replace with JUST null set\n // if more than one comparator, remove any * comparators\n // also, don't include the same comparator more than once\n const l = rangeList.length\n const rangeMap = new Map()\n for (const comp of rangeList) {\n if (isNullSet(comp))\n return [comp]\n rangeMap.set(comp.value, comp)\n }\n if (rangeMap.size > 1 && rangeMap.has(''))\n rangeMap.delete('')\n\n const result = [...rangeMap.values()]\n cache.set(memoKey, result)\n return result\n }\n\n intersects (range, options) {\n if (!(range instanceof Range)) {\n throw new TypeError('a Range is required')\n }\n\n return this.set.some((thisComparators) => {\n return (\n isSatisfiable(thisComparators, options) &&\n range.set.some((rangeComparators) => {\n return (\n isSatisfiable(rangeComparators, options) &&\n thisComparators.every((thisComparator) => {\n return rangeComparators.every((rangeComparator) => {\n return thisComparator.intersects(rangeComparator, options)\n })\n })\n )\n })\n )\n })\n }\n\n // if ANY of the sets match ALL of its comparators, then pass\n test (version) {\n if (!version) {\n return false\n }\n\n if (typeof version === 'string') {\n try {\n version = new SemVer(version, this.options)\n } catch (er) {\n return false\n }\n }\n\n for (let i = 0; i < this.set.length; i++) {\n if (testSet(this.set[i], version, this.options)) {\n return true\n }\n }\n return false\n }\n}\nmodule.exports = Range\n\nconst LRU = require('lru-cache')\nconst cache = new LRU({ max: 1000 })\n\nconst parseOptions = require('../internal/parse-options')\nconst Comparator = require('./comparator')\nconst debug = require('../internal/debug')\nconst SemVer = require('./semver')\nconst {\n re,\n t,\n comparatorTrimReplace,\n tildeTrimReplace,\n caretTrimReplace\n} = require('../internal/re')\n\nconst isNullSet = c => c.value === '<0.0.0-0'\nconst isAny = c => c.value === ''\n\n// take a set of comparators and determine whether there\n// exists a version which can satisfy it\nconst isSatisfiable = (comparators, options) => {\n let result = true\n const remainingComparators = comparators.slice()\n let testComparator = remainingComparators.pop()\n\n while (result && remainingComparators.length) {\n result = remainingComparators.every((otherComparator) => {\n return testComparator.intersects(otherComparator, options)\n })\n\n testComparator = remainingComparators.pop()\n }\n\n return result\n}\n\n// comprised of xranges, tildes, stars, and gtlt's at this point.\n// already replaced the hyphen ranges\n// turn into a set of JUST comparators.\nconst parseComparator = (comp, options) => {\n debug('comp', comp, options)\n comp = replaceCarets(comp, options)\n debug('caret', comp)\n comp = replaceTildes(comp, options)\n debug('tildes', comp)\n comp = replaceXRanges(comp, options)\n debug('xrange', comp)\n comp = replaceStars(comp, options)\n debug('stars', comp)\n return comp\n}\n\nconst isX = id => !id || id.toLowerCase() === 'x' || id === '*'\n\n// ~, ~> --> * (any, kinda silly)\n// ~2, ~2.x, ~2.x.x, ~>2, ~>2.x ~>2.x.x --> >=2.0.0 <3.0.0-0\n// ~2.0, ~2.0.x, ~>2.0, ~>2.0.x --> >=2.0.0 <2.1.0-0\n// ~1.2, ~1.2.x, ~>1.2, ~>1.2.x --> >=1.2.0 <1.3.0-0\n// ~1.2.3, ~>1.2.3 --> >=1.2.3 <1.3.0-0\n// ~1.2.0, ~>1.2.0 --> >=1.2.0 <1.3.0-0\nconst replaceTildes = (comp, options) =>\n comp.trim().split(/\\s+/).map((comp) => {\n return replaceTilde(comp, options)\n }).join(' ')\n\nconst replaceTilde = (comp, options) => {\n const r = options.loose ? re[t.TILDELOOSE] : re[t.TILDE]\n return comp.replace(r, (_, M, m, p, pr) => {\n debug('tilde', comp, _, M, m, p, pr)\n let ret\n\n if (isX(M)) {\n ret = ''\n } else if (isX(m)) {\n ret = `>=${M}.0.0 <${+M + 1}.0.0-0`\n } else if (isX(p)) {\n // ~1.2 == >=1.2.0 <1.3.0-0\n ret = `>=${M}.${m}.0 <${M}.${+m + 1}.0-0`\n } else if (pr) {\n debug('replaceTilde pr', pr)\n ret = `>=${M}.${m}.${p}-${pr\n } <${M}.${+m + 1}.0-0`\n } else {\n // ~1.2.3 == >=1.2.3 <1.3.0-0\n ret = `>=${M}.${m}.${p\n } <${M}.${+m + 1}.0-0`\n }\n\n debug('tilde return', ret)\n return ret\n })\n}\n\n// ^ --> * (any, kinda silly)\n// ^2, ^2.x, ^2.x.x --> >=2.0.0 <3.0.0-0\n// ^2.0, ^2.0.x --> >=2.0.0 <3.0.0-0\n// ^1.2, ^1.2.x --> >=1.2.0 <2.0.0-0\n// ^1.2.3 --> >=1.2.3 <2.0.0-0\n// ^1.2.0 --> >=1.2.0 <2.0.0-0\nconst replaceCarets = (comp, options) =>\n comp.trim().split(/\\s+/).map((comp) => {\n return replaceCaret(comp, options)\n }).join(' ')\n\nconst replaceCaret = (comp, options) => {\n debug('caret', comp, options)\n const r = options.loose ? re[t.CARETLOOSE] : re[t.CARET]\n const z = options.includePrerelease ? '-0' : ''\n return comp.replace(r, (_, M, m, p, pr) => {\n debug('caret', comp, _, M, m, p, pr)\n let ret\n\n if (isX(M)) {\n ret = ''\n } else if (isX(m)) {\n ret = `>=${M}.0.0${z} <${+M + 1}.0.0-0`\n } else if (isX(p)) {\n if (M === '0') {\n ret = `>=${M}.${m}.0${z} <${M}.${+m + 1}.0-0`\n } else {\n ret = `>=${M}.${m}.0${z} <${+M + 1}.0.0-0`\n }\n } else if (pr) {\n debug('replaceCaret pr', pr)\n if (M === '0') {\n if (m === '0') {\n ret = `>=${M}.${m}.${p}-${pr\n } <${M}.${m}.${+p + 1}-0`\n } else {\n ret = `>=${M}.${m}.${p}-${pr\n } <${M}.${+m + 1}.0-0`\n }\n } else {\n ret = `>=${M}.${m}.${p}-${pr\n } <${+M + 1}.0.0-0`\n }\n } else {\n debug('no pr')\n if (M === '0') {\n if (m === '0') {\n ret = `>=${M}.${m}.${p\n }${z} <${M}.${m}.${+p + 1}-0`\n } else {\n ret = `>=${M}.${m}.${p\n }${z} <${M}.${+m + 1}.0-0`\n }\n } else {\n ret = `>=${M}.${m}.${p\n } <${+M + 1}.0.0-0`\n }\n }\n\n debug('caret return', ret)\n return ret\n })\n}\n\nconst replaceXRanges = (comp, options) => {\n debug('replaceXRanges', comp, options)\n return comp.split(/\\s+/).map((comp) => {\n return replaceXRange(comp, options)\n }).join(' ')\n}\n\nconst replaceXRange = (comp, options) => {\n comp = comp.trim()\n const r = options.loose ? re[t.XRANGELOOSE] : re[t.XRANGE]\n return comp.replace(r, (ret, gtlt, M, m, p, pr) => {\n debug('xRange', comp, ret, gtlt, M, m, p, pr)\n const xM = isX(M)\n const xm = xM || isX(m)\n const xp = xm || isX(p)\n const anyX = xp\n\n if (gtlt === '=' && anyX) {\n gtlt = ''\n }\n\n // if we're including prereleases in the match, then we need\n // to fix this to -0, the lowest possible prerelease value\n pr = options.includePrerelease ? '-0' : ''\n\n if (xM) {\n if (gtlt === '>' || gtlt === '<') {\n // nothing is allowed\n ret = '<0.0.0-0'\n } else {\n // nothing is forbidden\n ret = '*'\n }\n } else if (gtlt && anyX) {\n // we know patch is an x, because we have any x at all.\n // replace X with 0\n if (xm) {\n m = 0\n }\n p = 0\n\n if (gtlt === '>') {\n // >1 => >=2.0.0\n // >1.2 => >=1.3.0\n gtlt = '>='\n if (xm) {\n M = +M + 1\n m = 0\n p = 0\n } else {\n m = +m + 1\n p = 0\n }\n } else if (gtlt === '<=') {\n // <=0.7.x is actually <0.8.0, since any 0.7.x should\n // pass. Similarly, <=7.x is actually <8.0.0, etc.\n gtlt = '<'\n if (xm) {\n M = +M + 1\n } else {\n m = +m + 1\n }\n }\n\n if (gtlt === '<')\n pr = '-0'\n\n ret = `${gtlt + M}.${m}.${p}${pr}`\n } else if (xm) {\n ret = `>=${M}.0.0${pr} <${+M + 1}.0.0-0`\n } else if (xp) {\n ret = `>=${M}.${m}.0${pr\n } <${M}.${+m + 1}.0-0`\n }\n\n debug('xRange return', ret)\n\n return ret\n })\n}\n\n// Because * is AND-ed with everything else in the comparator,\n// and '' means \"any version\", just remove the *s entirely.\nconst replaceStars = (comp, options) => {\n debug('replaceStars', comp, options)\n // Looseness is ignored here. star is always as loose as it gets!\n return comp.trim().replace(re[t.STAR], '')\n}\n\nconst replaceGTE0 = (comp, options) => {\n debug('replaceGTE0', comp, options)\n return comp.trim()\n .replace(re[options.includePrerelease ? t.GTE0PRE : t.GTE0], '')\n}\n\n// This function is passed to string.replace(re[t.HYPHENRANGE])\n// M, m, patch, prerelease, build\n// 1.2 - 3.4.5 => >=1.2.0 <=3.4.5\n// 1.2.3 - 3.4 => >=1.2.0 <3.5.0-0 Any 3.4.x will do\n// 1.2 - 3.4 => >=1.2.0 <3.5.0-0\nconst hyphenReplace = incPr => ($0,\n from, fM, fm, fp, fpr, fb,\n to, tM, tm, tp, tpr, tb) => {\n if (isX(fM)) {\n from = ''\n } else if (isX(fm)) {\n from = `>=${fM}.0.0${incPr ? '-0' : ''}`\n } else if (isX(fp)) {\n from = `>=${fM}.${fm}.0${incPr ? '-0' : ''}`\n } else if (fpr) {\n from = `>=${from}`\n } else {\n from = `>=${from}${incPr ? '-0' : ''}`\n }\n\n if (isX(tM)) {\n to = ''\n } else if (isX(tm)) {\n to = `<${+tM + 1}.0.0-0`\n } else if (isX(tp)) {\n to = `<${tM}.${+tm + 1}.0-0`\n } else if (tpr) {\n to = `<=${tM}.${tm}.${tp}-${tpr}`\n } else if (incPr) {\n to = `<${tM}.${tm}.${+tp + 1}-0`\n } else {\n to = `<=${to}`\n }\n\n return (`${from} ${to}`).trim()\n}\n\nconst testSet = (set, version, options) => {\n for (let i = 0; i < set.length; i++) {\n if (!set[i].test(version)) {\n return false\n }\n }\n\n if (version.prerelease.length && !options.includePrerelease) {\n // Find the set of versions that are allowed to have prereleases\n // For example, ^1.2.3-pr.1 desugars to >=1.2.3-pr.1 <2.0.0\n // That should allow `1.2.3-pr.2` to pass.\n // However, `1.2.4-alpha.notready` should NOT be allowed,\n // even though it's within the range set by the comparators.\n for (let i = 0; i < set.length; i++) {\n debug(set[i].semver)\n if (set[i].semver === Comparator.ANY) {\n continue\n }\n\n if (set[i].semver.prerelease.length > 0) {\n const allowed = set[i].semver\n if (allowed.major === version.major &&\n allowed.minor === version.minor &&\n allowed.patch === version.patch) {\n return true\n }\n }\n }\n\n // Version has a -pre, but it's not one of the ones we like.\n return false\n }\n\n return true\n}\n", "const ANY = Symbol('SemVer ANY')\n// hoisted class for cyclic dependency\nclass Comparator {\n static get ANY () {\n return ANY\n }\n constructor (comp, options) {\n options = parseOptions(options)\n\n if (comp instanceof Comparator) {\n if (comp.loose === !!options.loose) {\n return comp\n } else {\n comp = comp.value\n }\n }\n\n debug('comparator', comp, options)\n this.options = options\n this.loose = !!options.loose\n this.parse(comp)\n\n if (this.semver === ANY) {\n this.value = ''\n } else {\n this.value = this.operator + this.semver.version\n }\n\n debug('comp', this)\n }\n\n parse (comp) {\n const r = this.options.loose ? re[t.COMPARATORLOOSE] : re[t.COMPARATOR]\n const m = comp.match(r)\n\n if (!m) {\n throw new TypeError(`Invalid comparator: ${comp}`)\n }\n\n this.operator = m[1] !== undefined ? m[1] : ''\n if (this.operator === '=') {\n this.operator = ''\n }\n\n // if it literally is just '>' or '' then allow anything.\n if (!m[2]) {\n this.semver = ANY\n } else {\n this.semver = new SemVer(m[2], this.options.loose)\n }\n }\n\n toString () {\n return this.value\n }\n\n test (version) {\n debug('Comparator.test', version, this.options.loose)\n\n if (this.semver === ANY || version === ANY) {\n return true\n }\n\n if (typeof version === 'string') {\n try {\n version = new SemVer(version, this.options)\n } catch (er) {\n return false\n }\n }\n\n return cmp(version, this.operator, this.semver, this.options)\n }\n\n intersects (comp, options) {\n if (!(comp instanceof Comparator)) {\n throw new TypeError('a Comparator is required')\n }\n\n if (!options || typeof options !== 'object') {\n options = {\n loose: !!options,\n includePrerelease: false\n }\n }\n\n if (this.operator === '') {\n if (this.value === '') {\n return true\n }\n return new Range(comp.value, options).test(this.value)\n } else if (comp.operator === '') {\n if (comp.value === '') {\n return true\n }\n return new Range(this.value, options).test(comp.semver)\n }\n\n const sameDirectionIncreasing =\n (this.operator === '>=' || this.operator === '>') &&\n (comp.operator === '>=' || comp.operator === '>')\n const sameDirectionDecreasing =\n (this.operator === '<=' || this.operator === '<') &&\n (comp.operator === '<=' || comp.operator === '<')\n const sameSemVer = this.semver.version === comp.semver.version\n const differentDirectionsInclusive =\n (this.operator === '>=' || this.operator === '<=') &&\n (comp.operator === '>=' || comp.operator === '<=')\n const oppositeDirectionsLessThan =\n cmp(this.semver, '<', comp.semver, options) &&\n (this.operator === '>=' || this.operator === '>') &&\n (comp.operator === '<=' || comp.operator === '<')\n const oppositeDirectionsGreaterThan =\n cmp(this.semver, '>', comp.semver, options) &&\n (this.operator === '<=' || this.operator === '<') &&\n (comp.operator === '>=' || comp.operator === '>')\n\n return (\n sameDirectionIncreasing ||\n sameDirectionDecreasing ||\n (sameSemVer && differentDirectionsInclusive) ||\n oppositeDirectionsLessThan ||\n oppositeDirectionsGreaterThan\n )\n }\n}\n\nmodule.exports = Comparator\n\nconst parseOptions = require('../internal/parse-options')\nconst {re, t} = require('../internal/re')\nconst cmp = require('../functions/cmp')\nconst debug = require('../internal/debug')\nconst SemVer = require('./semver')\nconst Range = require('./range')\n", "const Range = require('../classes/range')\nconst satisfies = (version, range, options) => {\n try {\n range = new Range(range, options)\n } catch (er) {\n return false\n }\n return range.test(version)\n}\nmodule.exports = satisfies\n", "const Range = require('../classes/range')\n\n// Mostly just for testing and legacy API reasons\nconst toComparators = (range, options) =>\n new Range(range, options).set\n .map(comp => comp.map(c => c.value).join(' ').trim().split(' '))\n\nmodule.exports = toComparators\n", "const SemVer = require('../classes/semver')\nconst Range = require('../classes/range')\n\nconst maxSatisfying = (versions, range, options) => {\n let max = null\n let maxSV = null\n let rangeObj = null\n try {\n rangeObj = new Range(range, options)\n } catch (er) {\n return null\n }\n versions.forEach((v) => {\n if (rangeObj.test(v)) {\n // satisfies(v, range, options)\n if (!max || maxSV.compare(v) === -1) {\n // compare(max, v, true)\n max = v\n maxSV = new SemVer(max, options)\n }\n }\n })\n return max\n}\nmodule.exports = maxSatisfying\n", "const SemVer = require('../classes/semver')\nconst Range = require('../classes/range')\nconst minSatisfying = (versions, range, options) => {\n let min = null\n let minSV = null\n let rangeObj = null\n try {\n rangeObj = new Range(range, options)\n } catch (er) {\n return null\n }\n versions.forEach((v) => {\n if (rangeObj.test(v)) {\n // satisfies(v, range, options)\n if (!min || minSV.compare(v) === 1) {\n // compare(min, v, true)\n min = v\n minSV = new SemVer(min, options)\n }\n }\n })\n return min\n}\nmodule.exports = minSatisfying\n", "const SemVer = require('../classes/semver')\nconst Range = require('../classes/range')\nconst gt = require('../functions/gt')\n\nconst minVersion = (range, loose) => {\n range = new Range(range, loose)\n\n let minver = new SemVer('0.0.0')\n if (range.test(minver)) {\n return minver\n }\n\n minver = new SemVer('0.0.0-0')\n if (range.test(minver)) {\n return minver\n }\n\n minver = null\n for (let i = 0; i < range.set.length; ++i) {\n const comparators = range.set[i]\n\n let setMin = null\n comparators.forEach((comparator) => {\n // Clone to avoid manipulating the comparator's semver object.\n const compver = new SemVer(comparator.semver.version)\n switch (comparator.operator) {\n case '>':\n if (compver.prerelease.length === 0) {\n compver.patch++\n } else {\n compver.prerelease.push(0)\n }\n compver.raw = compver.format()\n /* fallthrough */\n case '':\n case '>=':\n if (!setMin || gt(compver, setMin)) {\n setMin = compver\n }\n break\n case '<':\n case '<=':\n /* Ignore maximum versions */\n break\n /* istanbul ignore next */\n default:\n throw new Error(`Unexpected operation: ${comparator.operator}`)\n }\n })\n if (setMin && (!minver || gt(minver, setMin)))\n minver = setMin\n }\n\n if (minver && range.test(minver)) {\n return minver\n }\n\n return null\n}\nmodule.exports = minVersion\n", "const Range = require('../classes/range')\nconst validRange = (range, options) => {\n try {\n // Return '*' instead of '' so that truthiness works.\n // This will throw if it's invalid anyway\n return new Range(range, options).range || '*'\n } catch (er) {\n return null\n }\n}\nmodule.exports = validRange\n", "const SemVer = require('../classes/semver')\nconst Comparator = require('../classes/comparator')\nconst {ANY} = Comparator\nconst Range = require('../classes/range')\nconst satisfies = require('../functions/satisfies')\nconst gt = require('../functions/gt')\nconst lt = require('../functions/lt')\nconst lte = require('../functions/lte')\nconst gte = require('../functions/gte')\n\nconst outside = (version, range, hilo, options) => {\n version = new SemVer(version, options)\n range = new Range(range, options)\n\n let gtfn, ltefn, ltfn, comp, ecomp\n switch (hilo) {\n case '>':\n gtfn = gt\n ltefn = lte\n ltfn = lt\n comp = '>'\n ecomp = '>='\n break\n case '<':\n gtfn = lt\n ltefn = gte\n ltfn = gt\n comp = '<'\n ecomp = '<='\n break\n default:\n throw new TypeError('Must provide a hilo val of \"<\" or \">\"')\n }\n\n // If it satisfies the range it is not outside\n if (satisfies(version, range, options)) {\n return false\n }\n\n // From now on, variable terms are as if we're in \"gtr\" mode.\n // but note that everything is flipped for the \"ltr\" function.\n\n for (let i = 0; i < range.set.length; ++i) {\n const comparators = range.set[i]\n\n let high = null\n let low = null\n\n comparators.forEach((comparator) => {\n if (comparator.semver === ANY) {\n comparator = new Comparator('>=0.0.0')\n }\n high = high || comparator\n low = low || comparator\n if (gtfn(comparator.semver, high.semver, options)) {\n high = comparator\n } else if (ltfn(comparator.semver, low.semver, options)) {\n low = comparator\n }\n })\n\n // If the edge version comparator has a operator then our version\n // isn't outside it\n if (high.operator === comp || high.operator === ecomp) {\n return false\n }\n\n // If the lowest version comparator has an operator and our version\n // is less than it then it isn't higher than the range\n if ((!low.operator || low.operator === comp) &&\n ltefn(version, low.semver)) {\n return false\n } else if (low.operator === ecomp && ltfn(version, low.semver)) {\n return false\n }\n }\n return true\n}\n\nmodule.exports = outside\n", "// Determine if version is greater than all the versions possible in the range.\nconst outside = require('./outside')\nconst gtr = (version, range, options) => outside(version, range, '>', options)\nmodule.exports = gtr\n", "const outside = require('./outside')\n// Determine if version is less than all the versions possible in the range\nconst ltr = (version, range, options) => outside(version, range, '<', options)\nmodule.exports = ltr\n", "const Range = require('../classes/range')\nconst intersects = (r1, r2, options) => {\n r1 = new Range(r1, options)\n r2 = new Range(r2, options)\n return r1.intersects(r2)\n}\nmodule.exports = intersects\n", "// given a set of versions and a range, create a \"simplified\" range\n// that includes the same versions that the original range does\n// If the original range is shorter than the simplified one, return that.\nconst satisfies = require('../functions/satisfies.js')\nconst compare = require('../functions/compare.js')\nmodule.exports = (versions, range, options) => {\n const set = []\n let min = null\n let prev = null\n const v = versions.sort((a, b) => compare(a, b, options))\n for (const version of v) {\n const included = satisfies(version, range, options)\n if (included) {\n prev = version\n if (!min)\n min = version\n } else {\n if (prev) {\n set.push([min, prev])\n }\n prev = null\n min = null\n }\n }\n if (min)\n set.push([min, null])\n\n const ranges = []\n for (const [min, max] of set) {\n if (min === max)\n ranges.push(min)\n else if (!max && min === v[0])\n ranges.push('*')\n else if (!max)\n ranges.push(`>=${min}`)\n else if (min === v[0])\n ranges.push(`<=${max}`)\n else\n ranges.push(`${min} - ${max}`)\n }\n const simplified = ranges.join(' || ')\n const original = typeof range.raw === 'string' ? range.raw : String(range)\n return simplified.length < original.length ? simplified : range\n}\n", "const Range = require('../classes/range.js')\nconst Comparator = require('../classes/comparator.js')\nconst { ANY } = Comparator\nconst satisfies = require('../functions/satisfies.js')\nconst compare = require('../functions/compare.js')\n\n// Complex range `r1 || r2 || ...` is a subset of `R1 || R2 || ...` iff:\n// - Every simple range `r1, r2, ...` is a null set, OR\n// - Every simple range `r1, r2, ...` which is not a null set is a subset of\n// some `R1, R2, ...`\n//\n// Simple range `c1 c2 ...` is a subset of simple range `C1 C2 ...` iff:\n// - If c is only the ANY comparator\n// - If C is only the ANY comparator, return true\n// - Else if in prerelease mode, return false\n// - else replace c with `[>=0.0.0]`\n// - If C is only the ANY comparator\n// - if in prerelease mode, return true\n// - else replace C with `[>=0.0.0]`\n// - Let EQ be the set of = comparators in c\n// - If EQ is more than one, return true (null set)\n// - Let GT be the highest > or >= comparator in c\n// - Let LT be the lowest < or <= comparator in c\n// - If GT and LT, and GT.semver > LT.semver, return true (null set)\n// - If any C is a = range, and GT or LT are set, return false\n// - If EQ\n// - If GT, and EQ does not satisfy GT, return true (null set)\n// - If LT, and EQ does not satisfy LT, return true (null set)\n// - If EQ satisfies every C, return true\n// - Else return false\n// - If GT\n// - If GT.semver is lower than any > or >= comp in C, return false\n// - If GT is >=, and GT.semver does not satisfy every C, return false\n// - If GT.semver has a prerelease, and not in prerelease mode\n// - If no C has a prerelease and the GT.semver tuple, return false\n// - If LT\n// - If LT.semver is greater than any < or <= comp in C, return false\n// - If LT is <=, and LT.semver does not satisfy every C, return false\n// - If GT.semver has a prerelease, and not in prerelease mode\n// - If no C has a prerelease and the LT.semver tuple, return false\n// - Else return true\n\nconst subset = (sub, dom, options = {}) => {\n if (sub === dom)\n return true\n\n sub = new Range(sub, options)\n dom = new Range(dom, options)\n let sawNonNull = false\n\n OUTER: for (const simpleSub of sub.set) {\n for (const simpleDom of dom.set) {\n const isSub = simpleSubset(simpleSub, simpleDom, options)\n sawNonNull = sawNonNull || isSub !== null\n if (isSub)\n continue OUTER\n }\n // the null set is a subset of everything, but null simple ranges in\n // a complex range should be ignored. so if we saw a non-null range,\n // then we know this isn't a subset, but if EVERY simple range was null,\n // then it is a subset.\n if (sawNonNull)\n return false\n }\n return true\n}\n\nconst simpleSubset = (sub, dom, options) => {\n if (sub === dom)\n return true\n\n if (sub.length === 1 && sub[0].semver === ANY) {\n if (dom.length === 1 && dom[0].semver === ANY)\n return true\n else if (options.includePrerelease)\n sub = [ new Comparator('>=0.0.0-0') ]\n else\n sub = [ new Comparator('>=0.0.0') ]\n }\n\n if (dom.length === 1 && dom[0].semver === ANY) {\n if (options.includePrerelease)\n return true\n else\n dom = [ new Comparator('>=0.0.0') ]\n }\n\n const eqSet = new Set()\n let gt, lt\n for (const c of sub) {\n if (c.operator === '>' || c.operator === '>=')\n gt = higherGT(gt, c, options)\n else if (c.operator === '<' || c.operator === '<=')\n lt = lowerLT(lt, c, options)\n else\n eqSet.add(c.semver)\n }\n\n if (eqSet.size > 1)\n return null\n\n let gtltComp\n if (gt && lt) {\n gtltComp = compare(gt.semver, lt.semver, options)\n if (gtltComp > 0)\n return null\n else if (gtltComp === 0 && (gt.operator !== '>=' || lt.operator !== '<='))\n return null\n }\n\n // will iterate one or zero times\n for (const eq of eqSet) {\n if (gt && !satisfies(eq, String(gt), options))\n return null\n\n if (lt && !satisfies(eq, String(lt), options))\n return null\n\n for (const c of dom) {\n if (!satisfies(eq, String(c), options))\n return false\n }\n\n return true\n }\n\n let higher, lower\n let hasDomLT, hasDomGT\n // if the subset has a prerelease, we need a comparator in the superset\n // with the same tuple and a prerelease, or it's not a subset\n let needDomLTPre = lt &&\n !options.includePrerelease &&\n lt.semver.prerelease.length ? lt.semver : false\n let needDomGTPre = gt &&\n !options.includePrerelease &&\n gt.semver.prerelease.length ? gt.semver : false\n // exception: <1.2.3-0 is the same as <1.2.3\n if (needDomLTPre && needDomLTPre.prerelease.length === 1 &&\n lt.operator === '<' && needDomLTPre.prerelease[0] === 0) {\n needDomLTPre = false\n }\n\n for (const c of dom) {\n hasDomGT = hasDomGT || c.operator === '>' || c.operator === '>='\n hasDomLT = hasDomLT || c.operator === '<' || c.operator === '<='\n if (gt) {\n if (needDomGTPre) {\n if (c.semver.prerelease && c.semver.prerelease.length &&\n c.semver.major === needDomGTPre.major &&\n c.semver.minor === needDomGTPre.minor &&\n c.semver.patch === needDomGTPre.patch) {\n needDomGTPre = false\n }\n }\n if (c.operator === '>' || c.operator === '>=') {\n higher = higherGT(gt, c, options)\n if (higher === c && higher !== gt)\n return false\n } else if (gt.operator === '>=' && !satisfies(gt.semver, String(c), options))\n return false\n }\n if (lt) {\n if (needDomLTPre) {\n if (c.semver.prerelease && c.semver.prerelease.length &&\n c.semver.major === needDomLTPre.major &&\n c.semver.minor === needDomLTPre.minor &&\n c.semver.patch === needDomLTPre.patch) {\n needDomLTPre = false\n }\n }\n if (c.operator === '<' || c.operator === '<=') {\n lower = lowerLT(lt, c, options)\n if (lower === c && lower !== lt)\n return false\n } else if (lt.operator === '<=' && !satisfies(lt.semver, String(c), options))\n return false\n }\n if (!c.operator && (lt || gt) && gtltComp !== 0)\n return false\n }\n\n // if there was a < or >, and nothing in the dom, then must be false\n // UNLESS it was limited by another range in the other direction.\n // Eg, >1.0.0 <1.0.1 is still a subset of <2.0.0\n if (gt && hasDomLT && !lt && gtltComp !== 0)\n return false\n\n if (lt && hasDomGT && !gt && gtltComp !== 0)\n return false\n\n // we needed a prerelease range in a specific tuple, but didn't get one\n // then this isn't a subset. eg >=1.2.3-pre is not a subset of >=1.0.0,\n // because it includes prereleases in the 1.2.3 tuple\n if (needDomGTPre || needDomLTPre)\n return false\n\n return true\n}\n\n// >=1.2.3 is lower than >1.2.3\nconst higherGT = (a, b, options) => {\n if (!a)\n return b\n const comp = compare(a.semver, b.semver, options)\n return comp > 0 ? a\n : comp < 0 ? b\n : b.operator === '>' && a.operator === '>=' ? b\n : a\n}\n\n// <=1.2.3 is higher than <1.2.3\nconst lowerLT = (a, b, options) => {\n if (!a)\n return b\n const comp = compare(a.semver, b.semver, options)\n return comp < 0 ? a\n : comp > 0 ? b\n : b.operator === '<' && a.operator === '<=' ? b\n : a\n}\n\nmodule.exports = subset\n", "// just pre-load all the stuff that index.js lazily exports\nconst internalRe = require('./internal/re')\nmodule.exports = {\n re: internalRe.re,\n src: internalRe.src,\n tokens: internalRe.t,\n SEMVER_SPEC_VERSION: require('./internal/constants').SEMVER_SPEC_VERSION,\n SemVer: require('./classes/semver'),\n compareIdentifiers: require('./internal/identifiers').compareIdentifiers,\n rcompareIdentifiers: require('./internal/identifiers').rcompareIdentifiers,\n parse: require('./functions/parse'),\n valid: require('./functions/valid'),\n clean: require('./functions/clean'),\n inc: require('./functions/inc'),\n diff: require('./functions/diff'),\n major: require('./functions/major'),\n minor: require('./functions/minor'),\n patch: require('./functions/patch'),\n prerelease: require('./functions/prerelease'),\n compare: require('./functions/compare'),\n rcompare: require('./functions/rcompare'),\n compareLoose: require('./functions/compare-loose'),\n compareBuild: require('./functions/compare-build'),\n sort: require('./functions/sort'),\n rsort: require('./functions/rsort'),\n gt: require('./functions/gt'),\n lt: require('./functions/lt'),\n eq: require('./functions/eq'),\n neq: require('./functions/neq'),\n gte: require('./functions/gte'),\n lte: require('./functions/lte'),\n cmp: require('./functions/cmp'),\n coerce: require('./functions/coerce'),\n Comparator: require('./classes/comparator'),\n Range: require('./classes/range'),\n satisfies: require('./functions/satisfies'),\n toComparators: require('./ranges/to-comparators'),\n maxSatisfying: require('./ranges/max-satisfying'),\n minSatisfying: require('./ranges/min-satisfying'),\n minVersion: require('./ranges/min-version'),\n validRange: require('./ranges/valid'),\n outside: require('./ranges/outside'),\n gtr: require('./ranges/gtr'),\n ltr: require('./ranges/ltr'),\n intersects: require('./ranges/intersects'),\n simplifyRange: require('./ranges/simplify'),\n subset: require('./ranges/subset'),\n}\n", "'use strict';\n\n// ES6 Map\nvar map;\ntry {\n map = Map;\n} catch (_) { }\nvar set;\n\n// ES6 Set\ntry {\n set = Set;\n} catch (_) { }\n\nfunction baseClone (src, circulars, clones) {\n // Null/undefined/functions/etc\n if (!src || typeof src !== 'object' || typeof src === 'function') {\n return src\n }\n\n // DOM Node\n if (src.nodeType && 'cloneNode' in src) {\n return src.cloneNode(true)\n }\n\n // Date\n if (src instanceof Date) {\n return new Date(src.getTime())\n }\n\n // RegExp\n if (src instanceof RegExp) {\n return new RegExp(src)\n }\n\n // Arrays\n if (Array.isArray(src)) {\n return src.map(clone)\n }\n\n // ES6 Maps\n if (map && src instanceof map) {\n return new Map(Array.from(src.entries()))\n }\n\n // ES6 Sets\n if (set && src instanceof set) {\n return new Set(Array.from(src.values()))\n }\n\n // Object\n if (src instanceof Object) {\n circulars.push(src);\n var obj = Object.create(src);\n clones.push(obj);\n for (var key in src) {\n var idx = circulars.findIndex(function (i) {\n return i === src[key]\n });\n obj[key] = idx > -1 ? clones[idx] : baseClone(src[key], circulars, clones);\n }\n return obj\n }\n\n // ???\n return src\n}\n\nfunction clone (src) {\n return baseClone(src, [], [])\n}\n\nmodule.exports = clone;\n", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = printValue;\nconst toString = Object.prototype.toString;\nconst errorToString = Error.prototype.toString;\nconst regExpToString = RegExp.prototype.toString;\nconst symbolToString = typeof Symbol !== 'undefined' ? Symbol.prototype.toString : () => '';\nconst SYMBOL_REGEXP = /^Symbol\\((.*)\\)(.*)$/;\n\nfunction printNumber(val) {\n if (val != +val) return 'NaN';\n const isNegativeZero = val === 0 && 1 / val < 0;\n return isNegativeZero ? '-0' : '' + val;\n}\n\nfunction printSimpleValue(val, quoteStrings = false) {\n if (val == null || val === true || val === false) return '' + val;\n const typeOf = typeof val;\n if (typeOf === 'number') return printNumber(val);\n if (typeOf === 'string') return quoteStrings ? `\"${val}\"` : val;\n if (typeOf === 'function') return '[Function ' + (val.name || 'anonymous') + ']';\n if (typeOf === 'symbol') return symbolToString.call(val).replace(SYMBOL_REGEXP, 'Symbol($1)');\n const tag = toString.call(val).slice(8, -1);\n if (tag === 'Date') return isNaN(val.getTime()) ? '' + val : val.toISOString(val);\n if (tag === 'Error' || val instanceof Error) return '[' + errorToString.call(val) + ']';\n if (tag === 'RegExp') return regExpToString.call(val);\n return null;\n}\n\nfunction printValue(value, quoteStrings) {\n let result = printSimpleValue(value, quoteStrings);\n if (result !== null) return result;\n return JSON.stringify(value, function (key, value) {\n let result = printSimpleValue(this[key], quoteStrings);\n if (result !== null) return result;\n return value;\n }, 2);\n}", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = exports.array = exports.object = exports.boolean = exports.date = exports.number = exports.string = exports.mixed = void 0;\n\nvar _printValue = _interopRequireDefault(require(\"./util/printValue\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nlet mixed = {\n default: '${path} is invalid',\n required: '${path} is a required field',\n oneOf: '${path} must be one of the following values: ${values}',\n notOneOf: '${path} must not be one of the following values: ${values}',\n notType: ({\n path,\n type,\n value,\n originalValue\n }) => {\n let isCast = originalValue != null && originalValue !== value;\n let msg = `${path} must be a \\`${type}\\` type, ` + `but the final value was: \\`${(0, _printValue.default)(value, true)}\\`` + (isCast ? ` (cast from the value \\`${(0, _printValue.default)(originalValue, true)}\\`).` : '.');\n\n if (value === null) {\n msg += `\\n If \"null\" is intended as an empty value be sure to mark the schema as \\`.nullable()\\``;\n }\n\n return msg;\n },\n defined: '${path} must be defined'\n};\nexports.mixed = mixed;\nlet string = {\n length: '${path} must be exactly ${length} characters',\n min: '${path} must be at least ${min} characters',\n max: '${path} must be at most ${max} characters',\n matches: '${path} must match the following: \"${regex}\"',\n email: '${path} must be a valid email',\n url: '${path} must be a valid URL',\n uuid: '${path} must be a valid UUID',\n trim: '${path} must be a trimmed string',\n lowercase: '${path} must be a lowercase string',\n uppercase: '${path} must be a upper case string'\n};\nexports.string = string;\nlet number = {\n min: '${path} must be greater than or equal to ${min}',\n max: '${path} must be less than or equal to ${max}',\n lessThan: '${path} must be less than ${less}',\n moreThan: '${path} must be greater than ${more}',\n positive: '${path} must be a positive number',\n negative: '${path} must be a negative number',\n integer: '${path} must be an integer'\n};\nexports.number = number;\nlet date = {\n min: '${path} field must be later than ${min}',\n max: '${path} field must be at earlier than ${max}'\n};\nexports.date = date;\nlet boolean = {\n isValue: '${path} field must be ${value}'\n};\nexports.boolean = boolean;\nlet object = {\n noUnknown: '${path} field has unspecified keys: ${unknown}'\n};\nexports.object = object;\nlet array = {\n min: '${path} field must have at least ${min} items',\n max: '${path} field must have less than or equal to ${max} items',\n length: '${path} must be have ${length} items'\n};\nexports.array = array;\n\nvar _default = Object.assign(Object.create(null), {\n mixed,\n string,\n number,\n date,\n object,\n array,\n boolean\n});\n\nexports.default = _default;", "/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.has` without support for deep paths.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {Array|string} key The key to check.\n * @returns {boolean} Returns `true` if `key` exists, else `false`.\n */\nfunction baseHas(object, key) {\n return object != null && hasOwnProperty.call(object, key);\n}\n\nmodule.exports = baseHas;\n", "var baseHas = require('./_baseHas'),\n hasPath = require('./_hasPath');\n\n/**\n * Checks if `path` is a direct property of `object`.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n * @example\n *\n * var object = { 'a': { 'b': 2 } };\n * var other = _.create({ 'a': _.create({ 'b': 2 }) });\n *\n * _.has(object, 'a');\n * // => true\n *\n * _.has(object, 'a.b');\n * // => true\n *\n * _.has(object, ['a', 'b']);\n * // => true\n *\n * _.has(other, 'a');\n * // => false\n */\nfunction has(object, path) {\n return object != null && hasPath(object, path, baseHas);\n}\n\nmodule.exports = has;\n", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _default = obj => obj && obj.__isYupSchema__;\n\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _has = _interopRequireDefault(require(\"lodash/has\"));\n\nvar _isSchema = _interopRequireDefault(require(\"./util/isSchema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nclass Condition {\n constructor(refs, options) {\n this.refs = refs;\n this.refs = refs;\n\n if (typeof options === 'function') {\n this.fn = options;\n return;\n }\n\n if (!(0, _has.default)(options, 'is')) throw new TypeError('`is:` is required for `when()` conditions');\n if (!options.then && !options.otherwise) throw new TypeError('either `then:` or `otherwise:` is required for `when()` conditions');\n let {\n is,\n then,\n otherwise\n } = options;\n let check = typeof is === 'function' ? is : (...values) => values.every(value => value === is);\n\n this.fn = function (...args) {\n let options = args.pop();\n let schema = args.pop();\n let branch = check(...args) ? then : otherwise;\n if (!branch) return undefined;\n if (typeof branch === 'function') return branch(schema);\n return schema.concat(branch.resolve(options));\n };\n }\n\n resolve(base, options) {\n let values = this.refs.map(ref => ref.getValue(options == null ? void 0 : options.value, options == null ? void 0 : options.parent, options == null ? void 0 : options.context));\n let schema = this.fn.apply(base, values.concat(base, options));\n if (schema === undefined || schema === base) return base;\n if (!(0, _isSchema.default)(schema)) throw new TypeError('conditions must return a schema object');\n return schema.resolve(options);\n }\n\n}\n\nvar _default = Condition;\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = toArray;\n\nfunction toArray(value) {\n return value == null ? [] : [].concat(value);\n}", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _printValue = _interopRequireDefault(require(\"./util/printValue\"));\n\nvar _toArray = _interopRequireDefault(require(\"./util/toArray\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nlet strReg = /\\$\\{\\s*(\\w+)\\s*\\}/g;\n\nclass ValidationError extends Error {\n static formatError(message, params) {\n const path = params.label || params.path || 'this';\n if (path !== params.path) params = _extends({}, params, {\n path\n });\n if (typeof message === 'string') return message.replace(strReg, (_, key) => (0, _printValue.default)(params[key]));\n if (typeof message === 'function') return message(params);\n return message;\n }\n\n static isError(err) {\n return err && err.name === 'ValidationError';\n }\n\n constructor(errorOrErrors, value, field, type) {\n super();\n this.name = 'ValidationError';\n this.value = value;\n this.path = field;\n this.type = type;\n this.errors = [];\n this.inner = [];\n (0, _toArray.default)(errorOrErrors).forEach(err => {\n if (ValidationError.isError(err)) {\n this.errors.push(...err.errors);\n this.inner = this.inner.concat(err.inner.length ? err.inner : err);\n } else {\n this.errors.push(err);\n }\n });\n this.message = this.errors.length > 1 ? `${this.errors.length} errors occurred` : this.errors[0];\n if (Error.captureStackTrace) Error.captureStackTrace(this, ValidationError);\n }\n\n}\n\nexports.default = ValidationError;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = runTests;\n\nvar _ValidationError = _interopRequireDefault(require(\"../ValidationError\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nconst once = cb => {\n let fired = false;\n return (...args) => {\n if (fired) return;\n fired = true;\n cb(...args);\n };\n};\n\nfunction runTests(options, cb) {\n let {\n endEarly,\n tests,\n args,\n value,\n errors,\n sort,\n path\n } = options;\n let callback = once(cb);\n let count = tests.length;\n const nestedErrors = [];\n errors = errors ? errors : [];\n if (!count) return errors.length ? callback(new _ValidationError.default(errors, value, path)) : callback(null, value);\n\n for (let i = 0; i < tests.length; i++) {\n const test = tests[i];\n test(args, function finishTestRun(err) {\n if (err) {\n // always return early for non validation errors\n if (!_ValidationError.default.isError(err)) {\n return callback(err, value);\n }\n\n if (endEarly) {\n err.value = value;\n return callback(err, value);\n }\n\n nestedErrors.push(err);\n }\n\n if (--count <= 0) {\n if (nestedErrors.length) {\n if (sort) nestedErrors.sort(sort); //show parent errors after the nested ones: name.first, name\n\n if (errors.length) nestedErrors.push(...errors);\n errors = nestedErrors;\n }\n\n if (errors.length) {\n callback(new _ValidationError.default(errors, value, path), value);\n return;\n }\n\n callback(null, value);\n }\n });\n }\n}", "/**\n * Creates a base function for methods like `_.forIn` and `_.forOwn`.\n *\n * @private\n * @param {boolean} [fromRight] Specify iterating from right to left.\n * @returns {Function} Returns the new base function.\n */\nfunction createBaseFor(fromRight) {\n return function(object, iteratee, keysFunc) {\n var index = -1,\n iterable = Object(object),\n props = keysFunc(object),\n length = props.length;\n\n while (length--) {\n var key = props[fromRight ? length : ++index];\n if (iteratee(iterable[key], key, iterable) === false) {\n break;\n }\n }\n return object;\n };\n}\n\nmodule.exports = createBaseFor;\n", "var createBaseFor = require('./_createBaseFor');\n\n/**\n * The base implementation of `baseForOwn` which iterates over `object`\n * properties returned by `keysFunc` and invokes `iteratee` for each property.\n * Iteratee functions may exit iteration early by explicitly returning `false`.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @returns {Object} Returns `object`.\n */\nvar baseFor = createBaseFor();\n\nmodule.exports = baseFor;\n", "/**\n * The base implementation of `_.times` without support for iteratee shorthands\n * or max array length checks.\n *\n * @private\n * @param {number} n The number of times to invoke `iteratee`.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the array of results.\n */\nfunction baseTimes(n, iteratee) {\n var index = -1,\n result = Array(n);\n\n while (++index < n) {\n result[index] = iteratee(index);\n }\n return result;\n}\n\nmodule.exports = baseTimes;\n", "/**\n * This method returns `false`.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {boolean} Returns `false`.\n * @example\n *\n * _.times(2, _.stubFalse);\n * // => [false, false]\n */\nfunction stubFalse() {\n return false;\n}\n\nmodule.exports = stubFalse;\n", "var root = require('./_root'),\n stubFalse = require('./stubFalse');\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Built-in value references. */\nvar Buffer = moduleExports ? root.Buffer : undefined;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined;\n\n/**\n * Checks if `value` is a buffer.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.\n * @example\n *\n * _.isBuffer(new Buffer(2));\n * // => true\n *\n * _.isBuffer(new Uint8Array(2));\n * // => false\n */\nvar isBuffer = nativeIsBuffer || stubFalse;\n\nmodule.exports = isBuffer;\n", "var baseGetTag = require('./_baseGetTag'),\n isLength = require('./isLength'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n funcTag = '[object Function]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n objectTag = '[object Object]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n weakMapTag = '[object WeakMap]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]',\n float32Tag = '[object Float32Array]',\n float64Tag = '[object Float64Array]',\n int8Tag = '[object Int8Array]',\n int16Tag = '[object Int16Array]',\n int32Tag = '[object Int32Array]',\n uint8Tag = '[object Uint8Array]',\n uint8ClampedTag = '[object Uint8ClampedArray]',\n uint16Tag = '[object Uint16Array]',\n uint32Tag = '[object Uint32Array]';\n\n/** Used to identify `toStringTag` values of typed arrays. */\nvar typedArrayTags = {};\ntypedArrayTags[float32Tag] = typedArrayTags[float64Tag] =\ntypedArrayTags[int8Tag] = typedArrayTags[int16Tag] =\ntypedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =\ntypedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =\ntypedArrayTags[uint32Tag] = true;\ntypedArrayTags[argsTag] = typedArrayTags[arrayTag] =\ntypedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =\ntypedArrayTags[dataViewTag] = typedArrayTags[dateTag] =\ntypedArrayTags[errorTag] = typedArrayTags[funcTag] =\ntypedArrayTags[mapTag] = typedArrayTags[numberTag] =\ntypedArrayTags[objectTag] = typedArrayTags[regexpTag] =\ntypedArrayTags[setTag] = typedArrayTags[stringTag] =\ntypedArrayTags[weakMapTag] = false;\n\n/**\n * The base implementation of `_.isTypedArray` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n */\nfunction baseIsTypedArray(value) {\n return isObjectLike(value) &&\n isLength(value.length) && !!typedArrayTags[baseGetTag(value)];\n}\n\nmodule.exports = baseIsTypedArray;\n", "/**\n * The base implementation of `_.unary` without support for storing metadata.\n *\n * @private\n * @param {Function} func The function to cap arguments for.\n * @returns {Function} Returns the new capped function.\n */\nfunction baseUnary(func) {\n return function(value) {\n return func(value);\n };\n}\n\nmodule.exports = baseUnary;\n", "var freeGlobal = require('./_freeGlobal');\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Detect free variable `process` from Node.js. */\nvar freeProcess = moduleExports && freeGlobal.process;\n\n/** Used to access faster Node.js helpers. */\nvar nodeUtil = (function() {\n try {\n // Use `util.types` for Node.js 10+.\n var types = freeModule && freeModule.require && freeModule.require('util').types;\n\n if (types) {\n return types;\n }\n\n // Legacy `process.binding('util')` for Node.js < 10.\n return freeProcess && freeProcess.binding && freeProcess.binding('util');\n } catch (e) {}\n}());\n\nmodule.exports = nodeUtil;\n", "var baseIsTypedArray = require('./_baseIsTypedArray'),\n baseUnary = require('./_baseUnary'),\n nodeUtil = require('./_nodeUtil');\n\n/* Node.js helper references. */\nvar nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;\n\n/**\n * Checks if `value` is classified as a typed array.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n * @example\n *\n * _.isTypedArray(new Uint8Array);\n * // => true\n *\n * _.isTypedArray([]);\n * // => false\n */\nvar isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;\n\nmodule.exports = isTypedArray;\n", "var baseTimes = require('./_baseTimes'),\n isArguments = require('./isArguments'),\n isArray = require('./isArray'),\n isBuffer = require('./isBuffer'),\n isIndex = require('./_isIndex'),\n isTypedArray = require('./isTypedArray');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Creates an array of the enumerable property names of the array-like `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @param {boolean} inherited Specify returning inherited property names.\n * @returns {Array} Returns the array of property names.\n */\nfunction arrayLikeKeys(value, inherited) {\n var isArr = isArray(value),\n isArg = !isArr && isArguments(value),\n isBuff = !isArr && !isArg && isBuffer(value),\n isType = !isArr && !isArg && !isBuff && isTypedArray(value),\n skipIndexes = isArr || isArg || isBuff || isType,\n result = skipIndexes ? baseTimes(value.length, String) : [],\n length = result.length;\n\n for (var key in value) {\n if ((inherited || hasOwnProperty.call(value, key)) &&\n !(skipIndexes && (\n // Safari 9 has enumerable `arguments.length` in strict mode.\n key == 'length' ||\n // Node.js 0.10 has enumerable non-index properties on buffers.\n (isBuff && (key == 'offset' || key == 'parent')) ||\n // PhantomJS 2 has enumerable non-index properties on typed arrays.\n (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) ||\n // Skip index properties.\n isIndex(key, length)\n ))) {\n result.push(key);\n }\n }\n return result;\n}\n\nmodule.exports = arrayLikeKeys;\n", "/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Checks if `value` is likely a prototype object.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a prototype, else `false`.\n */\nfunction isPrototype(value) {\n var Ctor = value && value.constructor,\n proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto;\n\n return value === proto;\n}\n\nmodule.exports = isPrototype;\n", "/**\n * Creates a unary function that invokes `func` with its argument transformed.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {Function} transform The argument transform.\n * @returns {Function} Returns the new function.\n */\nfunction overArg(func, transform) {\n return function(arg) {\n return func(transform(arg));\n };\n}\n\nmodule.exports = overArg;\n", "var overArg = require('./_overArg');\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeKeys = overArg(Object.keys, Object);\n\nmodule.exports = nativeKeys;\n", "var isPrototype = require('./_isPrototype'),\n nativeKeys = require('./_nativeKeys');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.keys` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction baseKeys(object) {\n if (!isPrototype(object)) {\n return nativeKeys(object);\n }\n var result = [];\n for (var key in Object(object)) {\n if (hasOwnProperty.call(object, key) && key != 'constructor') {\n result.push(key);\n }\n }\n return result;\n}\n\nmodule.exports = baseKeys;\n", "var isFunction = require('./isFunction'),\n isLength = require('./isLength');\n\n/**\n * Checks if `value` is array-like. A value is considered array-like if it's\n * not a function and has a `value.length` that's an integer greater than or\n * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is array-like, else `false`.\n * @example\n *\n * _.isArrayLike([1, 2, 3]);\n * // => true\n *\n * _.isArrayLike(document.body.children);\n * // => true\n *\n * _.isArrayLike('abc');\n * // => true\n *\n * _.isArrayLike(_.noop);\n * // => false\n */\nfunction isArrayLike(value) {\n return value != null && isLength(value.length) && !isFunction(value);\n}\n\nmodule.exports = isArrayLike;\n", "var arrayLikeKeys = require('./_arrayLikeKeys'),\n baseKeys = require('./_baseKeys'),\n isArrayLike = require('./isArrayLike');\n\n/**\n * Creates an array of the own enumerable property names of `object`.\n *\n * **Note:** Non-object values are coerced to objects. See the\n * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\n * for more details.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.keys(new Foo);\n * // => ['a', 'b'] (iteration order is not guaranteed)\n *\n * _.keys('hi');\n * // => ['0', '1']\n */\nfunction keys(object) {\n return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);\n}\n\nmodule.exports = keys;\n", "var baseFor = require('./_baseFor'),\n keys = require('./keys');\n\n/**\n * The base implementation of `_.forOwn` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Object} Returns `object`.\n */\nfunction baseForOwn(object, iteratee) {\n return object && baseFor(object, iteratee, keys);\n}\n\nmodule.exports = baseForOwn;\n", "var ListCache = require('./_ListCache');\n\n/**\n * Removes all key-value entries from the stack.\n *\n * @private\n * @name clear\n * @memberOf Stack\n */\nfunction stackClear() {\n this.__data__ = new ListCache;\n this.size = 0;\n}\n\nmodule.exports = stackClear;\n", "/**\n * Removes `key` and its value from the stack.\n *\n * @private\n * @name delete\n * @memberOf Stack\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction stackDelete(key) {\n var data = this.__data__,\n result = data['delete'](key);\n\n this.size = data.size;\n return result;\n}\n\nmodule.exports = stackDelete;\n", "/**\n * Gets the stack value for `key`.\n *\n * @private\n * @name get\n * @memberOf Stack\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction stackGet(key) {\n return this.__data__.get(key);\n}\n\nmodule.exports = stackGet;\n", "/**\n * Checks if a stack value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Stack\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction stackHas(key) {\n return this.__data__.has(key);\n}\n\nmodule.exports = stackHas;\n", "var ListCache = require('./_ListCache'),\n Map = require('./_Map'),\n MapCache = require('./_MapCache');\n\n/** Used as the size to enable large array optimizations. */\nvar LARGE_ARRAY_SIZE = 200;\n\n/**\n * Sets the stack `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Stack\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the stack cache instance.\n */\nfunction stackSet(key, value) {\n var data = this.__data__;\n if (data instanceof ListCache) {\n var pairs = data.__data__;\n if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) {\n pairs.push([key, value]);\n this.size = ++data.size;\n return this;\n }\n data = this.__data__ = new MapCache(pairs);\n }\n data.set(key, value);\n this.size = data.size;\n return this;\n}\n\nmodule.exports = stackSet;\n", "var ListCache = require('./_ListCache'),\n stackClear = require('./_stackClear'),\n stackDelete = require('./_stackDelete'),\n stackGet = require('./_stackGet'),\n stackHas = require('./_stackHas'),\n stackSet = require('./_stackSet');\n\n/**\n * Creates a stack cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Stack(entries) {\n var data = this.__data__ = new ListCache(entries);\n this.size = data.size;\n}\n\n// Add methods to `Stack`.\nStack.prototype.clear = stackClear;\nStack.prototype['delete'] = stackDelete;\nStack.prototype.get = stackGet;\nStack.prototype.has = stackHas;\nStack.prototype.set = stackSet;\n\nmodule.exports = Stack;\n", "/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Adds `value` to the array cache.\n *\n * @private\n * @name add\n * @memberOf SetCache\n * @alias push\n * @param {*} value The value to cache.\n * @returns {Object} Returns the cache instance.\n */\nfunction setCacheAdd(value) {\n this.__data__.set(value, HASH_UNDEFINED);\n return this;\n}\n\nmodule.exports = setCacheAdd;\n", "/**\n * Checks if `value` is in the array cache.\n *\n * @private\n * @name has\n * @memberOf SetCache\n * @param {*} value The value to search for.\n * @returns {number} Returns `true` if `value` is found, else `false`.\n */\nfunction setCacheHas(value) {\n return this.__data__.has(value);\n}\n\nmodule.exports = setCacheHas;\n", "var MapCache = require('./_MapCache'),\n setCacheAdd = require('./_setCacheAdd'),\n setCacheHas = require('./_setCacheHas');\n\n/**\n *\n * Creates an array cache object to store unique values.\n *\n * @private\n * @constructor\n * @param {Array} [values] The values to cache.\n */\nfunction SetCache(values) {\n var index = -1,\n length = values == null ? 0 : values.length;\n\n this.__data__ = new MapCache;\n while (++index < length) {\n this.add(values[index]);\n }\n}\n\n// Add methods to `SetCache`.\nSetCache.prototype.add = SetCache.prototype.push = setCacheAdd;\nSetCache.prototype.has = setCacheHas;\n\nmodule.exports = SetCache;\n", "/**\n * A specialized version of `_.some` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {boolean} Returns `true` if any element passes the predicate check,\n * else `false`.\n */\nfunction arraySome(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n while (++index < length) {\n if (predicate(array[index], index, array)) {\n return true;\n }\n }\n return false;\n}\n\nmodule.exports = arraySome;\n", "/**\n * Checks if a `cache` value for `key` exists.\n *\n * @private\n * @param {Object} cache The cache to query.\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction cacheHas(cache, key) {\n return cache.has(key);\n}\n\nmodule.exports = cacheHas;\n", "var SetCache = require('./_SetCache'),\n arraySome = require('./_arraySome'),\n cacheHas = require('./_cacheHas');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * A specialized version of `baseIsEqualDeep` for arrays with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Array} array The array to compare.\n * @param {Array} other The other array to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `array` and `other` objects.\n * @returns {boolean} Returns `true` if the arrays are equivalent, else `false`.\n */\nfunction equalArrays(array, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n arrLength = array.length,\n othLength = other.length;\n\n if (arrLength != othLength && !(isPartial && othLength > arrLength)) {\n return false;\n }\n // Check that cyclic values are equal.\n var arrStacked = stack.get(array);\n var othStacked = stack.get(other);\n if (arrStacked && othStacked) {\n return arrStacked == other && othStacked == array;\n }\n var index = -1,\n result = true,\n seen = (bitmask & COMPARE_UNORDERED_FLAG) ? new SetCache : undefined;\n\n stack.set(array, other);\n stack.set(other, array);\n\n // Ignore non-index properties.\n while (++index < arrLength) {\n var arrValue = array[index],\n othValue = other[index];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, arrValue, index, other, array, stack)\n : customizer(arrValue, othValue, index, array, other, stack);\n }\n if (compared !== undefined) {\n if (compared) {\n continue;\n }\n result = false;\n break;\n }\n // Recursively compare arrays (susceptible to call stack limits).\n if (seen) {\n if (!arraySome(other, function(othValue, othIndex) {\n if (!cacheHas(seen, othIndex) &&\n (arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {\n return seen.push(othIndex);\n }\n })) {\n result = false;\n break;\n }\n } else if (!(\n arrValue === othValue ||\n equalFunc(arrValue, othValue, bitmask, customizer, stack)\n )) {\n result = false;\n break;\n }\n }\n stack['delete'](array);\n stack['delete'](other);\n return result;\n}\n\nmodule.exports = equalArrays;\n", "var root = require('./_root');\n\n/** Built-in value references. */\nvar Uint8Array = root.Uint8Array;\n\nmodule.exports = Uint8Array;\n", "/**\n * Converts `map` to its key-value pairs.\n *\n * @private\n * @param {Object} map The map to convert.\n * @returns {Array} Returns the key-value pairs.\n */\nfunction mapToArray(map) {\n var index = -1,\n result = Array(map.size);\n\n map.forEach(function(value, key) {\n result[++index] = [key, value];\n });\n return result;\n}\n\nmodule.exports = mapToArray;\n", "/**\n * Converts `set` to an array of its values.\n *\n * @private\n * @param {Object} set The set to convert.\n * @returns {Array} Returns the values.\n */\nfunction setToArray(set) {\n var index = -1,\n result = Array(set.size);\n\n set.forEach(function(value) {\n result[++index] = value;\n });\n return result;\n}\n\nmodule.exports = setToArray;\n", "var Symbol = require('./_Symbol'),\n Uint8Array = require('./_Uint8Array'),\n eq = require('./eq'),\n equalArrays = require('./_equalArrays'),\n mapToArray = require('./_mapToArray'),\n setToArray = require('./_setToArray');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/** `Object#toString` result references. */\nvar boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n symbolTag = '[object Symbol]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]';\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolValueOf = symbolProto ? symbolProto.valueOf : undefined;\n\n/**\n * A specialized version of `baseIsEqualDeep` for comparing objects of\n * the same `toStringTag`.\n *\n * **Note:** This function only supports comparing values with tags of\n * `Boolean`, `Date`, `Error`, `Number`, `RegExp`, or `String`.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {string} tag The `toStringTag` of the objects to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalByTag(object, other, tag, bitmask, customizer, equalFunc, stack) {\n switch (tag) {\n case dataViewTag:\n if ((object.byteLength != other.byteLength) ||\n (object.byteOffset != other.byteOffset)) {\n return false;\n }\n object = object.buffer;\n other = other.buffer;\n\n case arrayBufferTag:\n if ((object.byteLength != other.byteLength) ||\n !equalFunc(new Uint8Array(object), new Uint8Array(other))) {\n return false;\n }\n return true;\n\n case boolTag:\n case dateTag:\n case numberTag:\n // Coerce booleans to `1` or `0` and dates to milliseconds.\n // Invalid dates are coerced to `NaN`.\n return eq(+object, +other);\n\n case errorTag:\n return object.name == other.name && object.message == other.message;\n\n case regexpTag:\n case stringTag:\n // Coerce regexes to strings and treat strings, primitives and objects,\n // as equal. See http://www.ecma-international.org/ecma-262/7.0/#sec-regexp.prototype.tostring\n // for more details.\n return object == (other + '');\n\n case mapTag:\n var convert = mapToArray;\n\n case setTag:\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG;\n convert || (convert = setToArray);\n\n if (object.size != other.size && !isPartial) {\n return false;\n }\n // Assume cyclic values are equal.\n var stacked = stack.get(object);\n if (stacked) {\n return stacked == other;\n }\n bitmask |= COMPARE_UNORDERED_FLAG;\n\n // Recursively compare objects (susceptible to call stack limits).\n stack.set(object, other);\n var result = equalArrays(convert(object), convert(other), bitmask, customizer, equalFunc, stack);\n stack['delete'](object);\n return result;\n\n case symbolTag:\n if (symbolValueOf) {\n return symbolValueOf.call(object) == symbolValueOf.call(other);\n }\n }\n return false;\n}\n\nmodule.exports = equalByTag;\n", "var arrayPush = require('./_arrayPush'),\n isArray = require('./isArray');\n\n/**\n * The base implementation of `getAllKeys` and `getAllKeysIn` which uses\n * `keysFunc` and `symbolsFunc` to get the enumerable property names and\n * symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @param {Function} symbolsFunc The function to get the symbols of `object`.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction baseGetAllKeys(object, keysFunc, symbolsFunc) {\n var result = keysFunc(object);\n return isArray(object) ? result : arrayPush(result, symbolsFunc(object));\n}\n\nmodule.exports = baseGetAllKeys;\n", "/**\n * A specialized version of `_.filter` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {Array} Returns the new filtered array.\n */\nfunction arrayFilter(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length,\n resIndex = 0,\n result = [];\n\n while (++index < length) {\n var value = array[index];\n if (predicate(value, index, array)) {\n result[resIndex++] = value;\n }\n }\n return result;\n}\n\nmodule.exports = arrayFilter;\n", "/**\n * This method returns a new empty array.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {Array} Returns the new empty array.\n * @example\n *\n * var arrays = _.times(2, _.stubArray);\n *\n * console.log(arrays);\n * // => [[], []]\n *\n * console.log(arrays[0] === arrays[1]);\n * // => false\n */\nfunction stubArray() {\n return [];\n}\n\nmodule.exports = stubArray;\n", "var arrayFilter = require('./_arrayFilter'),\n stubArray = require('./stubArray');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeGetSymbols = Object.getOwnPropertySymbols;\n\n/**\n * Creates an array of the own enumerable symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of symbols.\n */\nvar getSymbols = !nativeGetSymbols ? stubArray : function(object) {\n if (object == null) {\n return [];\n }\n object = Object(object);\n return arrayFilter(nativeGetSymbols(object), function(symbol) {\n return propertyIsEnumerable.call(object, symbol);\n });\n};\n\nmodule.exports = getSymbols;\n", "var baseGetAllKeys = require('./_baseGetAllKeys'),\n getSymbols = require('./_getSymbols'),\n keys = require('./keys');\n\n/**\n * Creates an array of own enumerable property names and symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction getAllKeys(object) {\n return baseGetAllKeys(object, keys, getSymbols);\n}\n\nmodule.exports = getAllKeys;\n", "var getAllKeys = require('./_getAllKeys');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqualDeep` for objects with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalObjects(object, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n objProps = getAllKeys(object),\n objLength = objProps.length,\n othProps = getAllKeys(other),\n othLength = othProps.length;\n\n if (objLength != othLength && !isPartial) {\n return false;\n }\n var index = objLength;\n while (index--) {\n var key = objProps[index];\n if (!(isPartial ? key in other : hasOwnProperty.call(other, key))) {\n return false;\n }\n }\n // Check that cyclic values are equal.\n var objStacked = stack.get(object);\n var othStacked = stack.get(other);\n if (objStacked && othStacked) {\n return objStacked == other && othStacked == object;\n }\n var result = true;\n stack.set(object, other);\n stack.set(other, object);\n\n var skipCtor = isPartial;\n while (++index < objLength) {\n key = objProps[index];\n var objValue = object[key],\n othValue = other[key];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, objValue, key, other, object, stack)\n : customizer(objValue, othValue, key, object, other, stack);\n }\n // Recursively compare objects (susceptible to call stack limits).\n if (!(compared === undefined\n ? (objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack))\n : compared\n )) {\n result = false;\n break;\n }\n skipCtor || (skipCtor = key == 'constructor');\n }\n if (result && !skipCtor) {\n var objCtor = object.constructor,\n othCtor = other.constructor;\n\n // Non `Object` object instances with different constructors are not equal.\n if (objCtor != othCtor &&\n ('constructor' in object && 'constructor' in other) &&\n !(typeof objCtor == 'function' && objCtor instanceof objCtor &&\n typeof othCtor == 'function' && othCtor instanceof othCtor)) {\n result = false;\n }\n }\n stack['delete'](object);\n stack['delete'](other);\n return result;\n}\n\nmodule.exports = equalObjects;\n", "var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar DataView = getNative(root, 'DataView');\n\nmodule.exports = DataView;\n", "var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Promise = getNative(root, 'Promise');\n\nmodule.exports = Promise;\n", "var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Set = getNative(root, 'Set');\n\nmodule.exports = Set;\n", "var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar WeakMap = getNative(root, 'WeakMap');\n\nmodule.exports = WeakMap;\n", "var DataView = require('./_DataView'),\n Map = require('./_Map'),\n Promise = require('./_Promise'),\n Set = require('./_Set'),\n WeakMap = require('./_WeakMap'),\n baseGetTag = require('./_baseGetTag'),\n toSource = require('./_toSource');\n\n/** `Object#toString` result references. */\nvar mapTag = '[object Map]',\n objectTag = '[object Object]',\n promiseTag = '[object Promise]',\n setTag = '[object Set]',\n weakMapTag = '[object WeakMap]';\n\nvar dataViewTag = '[object DataView]';\n\n/** Used to detect maps, sets, and weakmaps. */\nvar dataViewCtorString = toSource(DataView),\n mapCtorString = toSource(Map),\n promiseCtorString = toSource(Promise),\n setCtorString = toSource(Set),\n weakMapCtorString = toSource(WeakMap);\n\n/**\n * Gets the `toStringTag` of `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nvar getTag = baseGetTag;\n\n// Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.\nif ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) ||\n (Map && getTag(new Map) != mapTag) ||\n (Promise && getTag(Promise.resolve()) != promiseTag) ||\n (Set && getTag(new Set) != setTag) ||\n (WeakMap && getTag(new WeakMap) != weakMapTag)) {\n getTag = function(value) {\n var result = baseGetTag(value),\n Ctor = result == objectTag ? value.constructor : undefined,\n ctorString = Ctor ? toSource(Ctor) : '';\n\n if (ctorString) {\n switch (ctorString) {\n case dataViewCtorString: return dataViewTag;\n case mapCtorString: return mapTag;\n case promiseCtorString: return promiseTag;\n case setCtorString: return setTag;\n case weakMapCtorString: return weakMapTag;\n }\n }\n return result;\n };\n}\n\nmodule.exports = getTag;\n", "var Stack = require('./_Stack'),\n equalArrays = require('./_equalArrays'),\n equalByTag = require('./_equalByTag'),\n equalObjects = require('./_equalObjects'),\n getTag = require('./_getTag'),\n isArray = require('./isArray'),\n isBuffer = require('./isBuffer'),\n isTypedArray = require('./isTypedArray');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n objectTag = '[object Object]';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqual` for arrays and objects which performs\n * deep comparisons and tracks traversed objects enabling objects with circular\n * references to be compared.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} [stack] Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction baseIsEqualDeep(object, other, bitmask, customizer, equalFunc, stack) {\n var objIsArr = isArray(object),\n othIsArr = isArray(other),\n objTag = objIsArr ? arrayTag : getTag(object),\n othTag = othIsArr ? arrayTag : getTag(other);\n\n objTag = objTag == argsTag ? objectTag : objTag;\n othTag = othTag == argsTag ? objectTag : othTag;\n\n var objIsObj = objTag == objectTag,\n othIsObj = othTag == objectTag,\n isSameTag = objTag == othTag;\n\n if (isSameTag && isBuffer(object)) {\n if (!isBuffer(other)) {\n return false;\n }\n objIsArr = true;\n objIsObj = false;\n }\n if (isSameTag && !objIsObj) {\n stack || (stack = new Stack);\n return (objIsArr || isTypedArray(object))\n ? equalArrays(object, other, bitmask, customizer, equalFunc, stack)\n : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);\n }\n if (!(bitmask & COMPARE_PARTIAL_FLAG)) {\n var objIsWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'),\n othIsWrapped = othIsObj && hasOwnProperty.call(other, '__wrapped__');\n\n if (objIsWrapped || othIsWrapped) {\n var objUnwrapped = objIsWrapped ? object.value() : object,\n othUnwrapped = othIsWrapped ? other.value() : other;\n\n stack || (stack = new Stack);\n return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);\n }\n }\n if (!isSameTag) {\n return false;\n }\n stack || (stack = new Stack);\n return equalObjects(object, other, bitmask, customizer, equalFunc, stack);\n}\n\nmodule.exports = baseIsEqualDeep;\n", "var baseIsEqualDeep = require('./_baseIsEqualDeep'),\n isObjectLike = require('./isObjectLike');\n\n/**\n * The base implementation of `_.isEqual` which supports partial comparisons\n * and tracks traversed objects.\n *\n * @private\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @param {boolean} bitmask The bitmask flags.\n * 1 - Unordered comparison\n * 2 - Partial comparison\n * @param {Function} [customizer] The function to customize comparisons.\n * @param {Object} [stack] Tracks traversed `value` and `other` objects.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n */\nfunction baseIsEqual(value, other, bitmask, customizer, stack) {\n if (value === other) {\n return true;\n }\n if (value == null || other == null || (!isObjectLike(value) && !isObjectLike(other))) {\n return value !== value && other !== other;\n }\n return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack);\n}\n\nmodule.exports = baseIsEqual;\n", "var Stack = require('./_Stack'),\n baseIsEqual = require('./_baseIsEqual');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * The base implementation of `_.isMatch` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The object to inspect.\n * @param {Object} source The object of property values to match.\n * @param {Array} matchData The property names, values, and compare flags to match.\n * @param {Function} [customizer] The function to customize comparisons.\n * @returns {boolean} Returns `true` if `object` is a match, else `false`.\n */\nfunction baseIsMatch(object, source, matchData, customizer) {\n var index = matchData.length,\n length = index,\n noCustomizer = !customizer;\n\n if (object == null) {\n return !length;\n }\n object = Object(object);\n while (index--) {\n var data = matchData[index];\n if ((noCustomizer && data[2])\n ? data[1] !== object[data[0]]\n : !(data[0] in object)\n ) {\n return false;\n }\n }\n while (++index < length) {\n data = matchData[index];\n var key = data[0],\n objValue = object[key],\n srcValue = data[1];\n\n if (noCustomizer && data[2]) {\n if (objValue === undefined && !(key in object)) {\n return false;\n }\n } else {\n var stack = new Stack;\n if (customizer) {\n var result = customizer(objValue, srcValue, key, object, source, stack);\n }\n if (!(result === undefined\n ? baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG, customizer, stack)\n : result\n )) {\n return false;\n }\n }\n }\n return true;\n}\n\nmodule.exports = baseIsMatch;\n", "var isObject = require('./isObject');\n\n/**\n * Checks if `value` is suitable for strict equality comparisons, i.e. `===`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` if suitable for strict\n * equality comparisons, else `false`.\n */\nfunction isStrictComparable(value) {\n return value === value && !isObject(value);\n}\n\nmodule.exports = isStrictComparable;\n", "var isStrictComparable = require('./_isStrictComparable'),\n keys = require('./keys');\n\n/**\n * Gets the property names, values, and compare flags of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the match data of `object`.\n */\nfunction getMatchData(object) {\n var result = keys(object),\n length = result.length;\n\n while (length--) {\n var key = result[length],\n value = object[key];\n\n result[length] = [key, value, isStrictComparable(value)];\n }\n return result;\n}\n\nmodule.exports = getMatchData;\n", "/**\n * A specialized version of `matchesProperty` for source values suitable\n * for strict equality comparisons, i.e. `===`.\n *\n * @private\n * @param {string} key The key of the property to get.\n * @param {*} srcValue The value to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction matchesStrictComparable(key, srcValue) {\n return function(object) {\n if (object == null) {\n return false;\n }\n return object[key] === srcValue &&\n (srcValue !== undefined || (key in Object(object)));\n };\n}\n\nmodule.exports = matchesStrictComparable;\n", "var baseIsMatch = require('./_baseIsMatch'),\n getMatchData = require('./_getMatchData'),\n matchesStrictComparable = require('./_matchesStrictComparable');\n\n/**\n * The base implementation of `_.matches` which doesn't clone `source`.\n *\n * @private\n * @param {Object} source The object of property values to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction baseMatches(source) {\n var matchData = getMatchData(source);\n if (matchData.length == 1 && matchData[0][2]) {\n return matchesStrictComparable(matchData[0][0], matchData[0][1]);\n }\n return function(object) {\n return object === source || baseIsMatch(object, source, matchData);\n };\n}\n\nmodule.exports = baseMatches;\n", "var baseIsEqual = require('./_baseIsEqual'),\n get = require('./get'),\n hasIn = require('./hasIn'),\n isKey = require('./_isKey'),\n isStrictComparable = require('./_isStrictComparable'),\n matchesStrictComparable = require('./_matchesStrictComparable'),\n toKey = require('./_toKey');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * The base implementation of `_.matchesProperty` which doesn't clone `srcValue`.\n *\n * @private\n * @param {string} path The path of the property to get.\n * @param {*} srcValue The value to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction baseMatchesProperty(path, srcValue) {\n if (isKey(path) && isStrictComparable(srcValue)) {\n return matchesStrictComparable(toKey(path), srcValue);\n }\n return function(object) {\n var objValue = get(object, path);\n return (objValue === undefined && objValue === srcValue)\n ? hasIn(object, path)\n : baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG);\n };\n}\n\nmodule.exports = baseMatchesProperty;\n", "/**\n * The base implementation of `_.property` without support for deep paths.\n *\n * @private\n * @param {string} key The key of the property to get.\n * @returns {Function} Returns the new accessor function.\n */\nfunction baseProperty(key) {\n return function(object) {\n return object == null ? undefined : object[key];\n };\n}\n\nmodule.exports = baseProperty;\n", "var baseGet = require('./_baseGet');\n\n/**\n * A specialized version of `baseProperty` which supports deep paths.\n *\n * @private\n * @param {Array|string} path The path of the property to get.\n * @returns {Function} Returns the new accessor function.\n */\nfunction basePropertyDeep(path) {\n return function(object) {\n return baseGet(object, path);\n };\n}\n\nmodule.exports = basePropertyDeep;\n", "var baseProperty = require('./_baseProperty'),\n basePropertyDeep = require('./_basePropertyDeep'),\n isKey = require('./_isKey'),\n toKey = require('./_toKey');\n\n/**\n * Creates a function that returns the value at `path` of a given object.\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Util\n * @param {Array|string} path The path of the property to get.\n * @returns {Function} Returns the new accessor function.\n * @example\n *\n * var objects = [\n * { 'a': { 'b': 2 } },\n * { 'a': { 'b': 1 } }\n * ];\n *\n * _.map(objects, _.property('a.b'));\n * // => [2, 1]\n *\n * _.map(_.sortBy(objects, _.property(['a', 'b'])), 'a.b');\n * // => [1, 2]\n */\nfunction property(path) {\n return isKey(path) ? baseProperty(toKey(path)) : basePropertyDeep(path);\n}\n\nmodule.exports = property;\n", "var baseMatches = require('./_baseMatches'),\n baseMatchesProperty = require('./_baseMatchesProperty'),\n identity = require('./identity'),\n isArray = require('./isArray'),\n property = require('./property');\n\n/**\n * The base implementation of `_.iteratee`.\n *\n * @private\n * @param {*} [value=_.identity] The value to convert to an iteratee.\n * @returns {Function} Returns the iteratee.\n */\nfunction baseIteratee(value) {\n // Don't store the `typeof` result in a variable to avoid a JIT bug in Safari 9.\n // See https://bugs.webkit.org/show_bug.cgi?id=156034 for more details.\n if (typeof value == 'function') {\n return value;\n }\n if (value == null) {\n return identity;\n }\n if (typeof value == 'object') {\n return isArray(value)\n ? baseMatchesProperty(value[0], value[1])\n : baseMatches(value);\n }\n return property(value);\n}\n\nmodule.exports = baseIteratee;\n", "var baseAssignValue = require('./_baseAssignValue'),\n baseForOwn = require('./_baseForOwn'),\n baseIteratee = require('./_baseIteratee');\n\n/**\n * Creates an object with the same keys as `object` and values generated\n * by running each own enumerable string keyed property of `object` thru\n * `iteratee`. The iteratee is invoked with three arguments:\n * (value, key, object).\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Object} Returns the new mapped object.\n * @see _.mapKeys\n * @example\n *\n * var users = {\n * 'fred': { 'user': 'fred', 'age': 40 },\n * 'pebbles': { 'user': 'pebbles', 'age': 1 }\n * };\n *\n * _.mapValues(users, function(o) { return o.age; });\n * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed)\n *\n * // The `_.property` iteratee shorthand.\n * _.mapValues(users, 'age');\n * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed)\n */\nfunction mapValues(object, iteratee) {\n var result = {};\n iteratee = baseIteratee(iteratee, 3);\n\n baseForOwn(object, function(value, key, object) {\n baseAssignValue(result, key, iteratee(value, key, object));\n });\n return result;\n}\n\nmodule.exports = mapValues;\n", "/**\n * Based on Kendo UI Core expression code \n */\n'use strict'\n\nfunction Cache(maxSize) {\n this._maxSize = maxSize\n this.clear()\n}\nCache.prototype.clear = function () {\n this._size = 0\n this._values = Object.create(null)\n}\nCache.prototype.get = function (key) {\n return this._values[key]\n}\nCache.prototype.set = function (key, value) {\n this._size >= this._maxSize && this.clear()\n if (!(key in this._values)) this._size++\n\n return (this._values[key] = value)\n}\n\nvar SPLIT_REGEX = /[^.^\\]^[]+|(?=\\[\\]|\\.\\.)/g,\n DIGIT_REGEX = /^\\d+$/,\n LEAD_DIGIT_REGEX = /^\\d/,\n SPEC_CHAR_REGEX = /[~`!#$%\\^&*+=\\-\\[\\]\\\\';,/{}|\\\\\":<>\\?]/g,\n CLEAN_QUOTES_REGEX = /^\\s*(['\"]?)(.*?)(\\1)\\s*$/,\n MAX_CACHE_SIZE = 512\n\nvar pathCache = new Cache(MAX_CACHE_SIZE),\n setCache = new Cache(MAX_CACHE_SIZE),\n getCache = new Cache(MAX_CACHE_SIZE)\n\nvar config\n\nmodule.exports = {\n Cache: Cache,\n\n split: split,\n\n normalizePath: normalizePath,\n\n setter: function (path) {\n var parts = normalizePath(path)\n\n return (\n setCache.get(path) ||\n setCache.set(path, function setter(obj, value) {\n var index = 0\n var len = parts.length\n var data = obj\n\n while (index < len - 1) {\n var part = parts[index]\n if (\n part === '__proto__' ||\n part === 'constructor' ||\n part === 'prototype'\n ) {\n return obj\n }\n\n data = data[parts[index++]]\n }\n data[parts[index]] = value\n })\n )\n },\n\n getter: function (path, safe) {\n var parts = normalizePath(path)\n return (\n getCache.get(path) ||\n getCache.set(path, function getter(data) {\n var index = 0,\n len = parts.length\n while (index < len) {\n if (data != null || !safe) data = data[parts[index++]]\n else return\n }\n return data\n })\n )\n },\n\n join: function (segments) {\n return segments.reduce(function (path, part) {\n return (\n path +\n (isQuoted(part) || DIGIT_REGEX.test(part)\n ? '[' + part + ']'\n : (path ? '.' : '') + part)\n )\n }, '')\n },\n\n forEach: function (path, cb, thisArg) {\n forEach(Array.isArray(path) ? path : split(path), cb, thisArg)\n },\n}\n\nfunction normalizePath(path) {\n return (\n pathCache.get(path) ||\n pathCache.set(\n path,\n split(path).map(function (part) {\n return part.replace(CLEAN_QUOTES_REGEX, '$2')\n })\n )\n )\n}\n\nfunction split(path) {\n return path.match(SPLIT_REGEX)\n}\n\nfunction forEach(parts, iter, thisArg) {\n var len = parts.length,\n part,\n idx,\n isArray,\n isBracket\n\n for (idx = 0; idx < len; idx++) {\n part = parts[idx]\n\n if (part) {\n if (shouldBeQuoted(part)) {\n part = '\"' + part + '\"'\n }\n\n isBracket = isQuoted(part)\n isArray = !isBracket && /^\\d+$/.test(part)\n\n iter.call(thisArg, part, isBracket, isArray, idx, parts)\n }\n }\n}\n\nfunction isQuoted(str) {\n return (\n typeof str === 'string' && str && [\"'\", '\"'].indexOf(str.charAt(0)) !== -1\n )\n}\n\nfunction hasLeadingNumber(part) {\n return part.match(LEAD_DIGIT_REGEX) && !part.match(DIGIT_REGEX)\n}\n\nfunction hasSpecialChars(part) {\n return SPEC_CHAR_REGEX.test(part)\n}\n\nfunction shouldBeQuoted(part) {\n return !isQuoted(part) && (hasLeadingNumber(part) || hasSpecialChars(part))\n}\n", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.create = create;\nexports.default = void 0;\n\nvar _propertyExpr = require(\"property-expr\");\n\nconst prefixes = {\n context: '$',\n value: '.'\n};\n\nfunction create(key, options) {\n return new Reference(key, options);\n}\n\nclass Reference {\n constructor(key, options = {}) {\n if (typeof key !== 'string') throw new TypeError('ref must be a string, got: ' + key);\n this.key = key.trim();\n if (key === '') throw new TypeError('ref must be a non-empty string');\n this.isContext = this.key[0] === prefixes.context;\n this.isValue = this.key[0] === prefixes.value;\n this.isSibling = !this.isContext && !this.isValue;\n let prefix = this.isContext ? prefixes.context : this.isValue ? prefixes.value : '';\n this.path = this.key.slice(prefix.length);\n this.getter = this.path && (0, _propertyExpr.getter)(this.path, true);\n this.map = options.map;\n }\n\n getValue(value, parent, context) {\n let result = this.isContext ? context : this.isValue ? value : parent;\n if (this.getter) result = this.getter(result || {});\n if (this.map) result = this.map(result);\n return result;\n }\n /**\n *\n * @param {*} value\n * @param {Object} options\n * @param {Object=} options.context\n * @param {Object=} options.parent\n */\n\n\n cast(value, options) {\n return this.getValue(value, options == null ? void 0 : options.parent, options == null ? void 0 : options.context);\n }\n\n resolve() {\n return this;\n }\n\n describe() {\n return {\n type: 'ref',\n key: this.key\n };\n }\n\n toString() {\n return `Ref(${this.key})`;\n }\n\n static isRef(value) {\n return value && value.__isYupRef;\n }\n\n} // @ts-ignore\n\n\nexports.default = Reference;\nReference.prototype.__isYupRef = true;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = createValidation;\n\nvar _mapValues = _interopRequireDefault(require(\"lodash/mapValues\"));\n\nvar _ValidationError = _interopRequireDefault(require(\"../ValidationError\"));\n\nvar _Reference = _interopRequireDefault(require(\"../Reference\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n\nfunction createValidation(config) {\n function validate(_ref, cb) {\n let {\n value,\n path = '',\n label,\n options,\n originalValue,\n sync\n } = _ref,\n rest = _objectWithoutPropertiesLoose(_ref, [\"value\", \"path\", \"label\", \"options\", \"originalValue\", \"sync\"]);\n\n const {\n name,\n test,\n params,\n message\n } = config;\n let {\n parent,\n context\n } = options;\n\n function resolve(item) {\n return _Reference.default.isRef(item) ? item.getValue(value, parent, context) : item;\n }\n\n function createError(overrides = {}) {\n const nextParams = (0, _mapValues.default)(_extends({\n value,\n originalValue,\n label,\n path: overrides.path || path\n }, params, overrides.params), resolve);\n const error = new _ValidationError.default(_ValidationError.default.formatError(overrides.message || message, nextParams), value, nextParams.path, overrides.type || name);\n error.params = nextParams;\n return error;\n }\n\n let ctx = _extends({\n path,\n parent,\n type: name,\n createError,\n resolve,\n options,\n originalValue\n }, rest);\n\n if (!sync) {\n try {\n Promise.resolve(test.call(ctx, value, ctx)).then(validOrError => {\n if (_ValidationError.default.isError(validOrError)) cb(validOrError);else if (!validOrError) cb(createError());else cb(null, validOrError);\n });\n } catch (err) {\n cb(err);\n }\n\n return;\n }\n\n let result;\n\n try {\n var _ref2;\n\n result = test.call(ctx, value, ctx);\n\n if (typeof ((_ref2 = result) == null ? void 0 : _ref2.then) === 'function') {\n throw new Error(`Validation test of type: \"${ctx.type}\" returned a Promise during a synchronous validate. ` + `This test will finish after the validate call has returned`);\n }\n } catch (err) {\n cb(err);\n return;\n }\n\n if (_ValidationError.default.isError(result)) cb(result);else if (!result) cb(createError());else cb(null, result);\n }\n\n validate.OPTIONS = config;\n return validate;\n}", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.getIn = getIn;\nexports.default = void 0;\n\nvar _propertyExpr = require(\"property-expr\");\n\nlet trim = part => part.substr(0, part.length - 1).substr(1);\n\nfunction getIn(schema, path, value, context = value) {\n let parent, lastPart, lastPartDebug; // root path: ''\n\n if (!path) return {\n parent,\n parentPath: path,\n schema\n };\n (0, _propertyExpr.forEach)(path, (_part, isBracket, isArray) => {\n let part = isBracket ? trim(_part) : _part;\n schema = schema.resolve({\n context,\n parent,\n value\n });\n\n if (schema.innerType) {\n let idx = isArray ? parseInt(part, 10) : 0;\n\n if (value && idx >= value.length) {\n throw new Error(`Yup.reach cannot resolve an array item at index: ${_part}, in the path: ${path}. ` + `because there is no value at that index. `);\n }\n\n parent = value;\n value = value && value[idx];\n schema = schema.innerType;\n } // sometimes the array index part of a path doesn't exist: \"nested.arr.child\"\n // in these cases the current part is the next schema and should be processed\n // in this iteration. For cases where the index signature is included this\n // check will fail and we'll handle the `child` part on the next iteration like normal\n\n\n if (!isArray) {\n if (!schema.fields || !schema.fields[part]) throw new Error(`The schema does not contain the path: ${path}. ` + `(failed at: ${lastPartDebug} which is a type: \"${schema._type}\")`);\n parent = value;\n value = value && value[part];\n schema = schema.fields[part];\n }\n\n lastPart = part;\n lastPartDebug = isBracket ? '[' + _part + ']' : '.' + _part;\n });\n return {\n schema,\n parent,\n parentPath: lastPart\n };\n}\n\nconst reach = (obj, path, value, context) => getIn(obj, path, value, context).schema;\n\nvar _default = reach;\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _Reference = _interopRequireDefault(require(\"../Reference\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nclass ReferenceSet {\n constructor() {\n this.list = new Set();\n this.refs = new Map();\n }\n\n get size() {\n return this.list.size + this.refs.size;\n }\n\n describe() {\n const description = [];\n\n for (const item of this.list) description.push(item);\n\n for (const [, ref] of this.refs) description.push(ref.describe());\n\n return description;\n }\n\n toArray() {\n return Array.from(this.list).concat(Array.from(this.refs.values()));\n }\n\n add(value) {\n _Reference.default.isRef(value) ? this.refs.set(value.key, value) : this.list.add(value);\n }\n\n delete(value) {\n _Reference.default.isRef(value) ? this.refs.delete(value.key) : this.list.delete(value);\n }\n\n has(value, resolve) {\n if (this.list.has(value)) return true;\n let item,\n values = this.refs.values();\n\n while (item = values.next(), !item.done) if (resolve(item.value) === value) return true;\n\n return false;\n }\n\n clone() {\n const next = new ReferenceSet();\n next.list = new Set(this.list);\n next.refs = new Map(this.refs);\n return next;\n }\n\n merge(newItems, removeItems) {\n const next = this.clone();\n newItems.list.forEach(value => next.add(value));\n newItems.refs.forEach(value => next.add(value));\n removeItems.list.forEach(value => next.delete(value));\n removeItems.refs.forEach(value => next.delete(value));\n return next;\n }\n\n}\n\nexports.default = ReferenceSet;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _nanoclone = _interopRequireDefault(require(\"nanoclone\"));\n\nvar _locale = require(\"./locale\");\n\nvar _Condition = _interopRequireDefault(require(\"./Condition\"));\n\nvar _runTests = _interopRequireDefault(require(\"./util/runTests\"));\n\nvar _createValidation = _interopRequireDefault(require(\"./util/createValidation\"));\n\nvar _printValue = _interopRequireDefault(require(\"./util/printValue\"));\n\nvar _Reference = _interopRequireDefault(require(\"./Reference\"));\n\nvar _reach = require(\"./util/reach\");\n\nvar _toArray = _interopRequireDefault(require(\"./util/toArray\"));\n\nvar _ValidationError = _interopRequireDefault(require(\"./ValidationError\"));\n\nvar _ReferenceSet = _interopRequireDefault(require(\"./util/ReferenceSet\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nclass BaseSchema {\n constructor(options) {\n this.deps = [];\n this.conditions = [];\n this._whitelist = new _ReferenceSet.default();\n this._blacklist = new _ReferenceSet.default();\n this.exclusiveTests = Object.create(null);\n this.tests = [];\n this.transforms = [];\n this.withMutation(() => {\n this.typeError(_locale.mixed.notType);\n });\n this.type = (options == null ? void 0 : options.type) || 'mixed';\n this.spec = _extends({\n strip: false,\n strict: false,\n abortEarly: true,\n recursive: true,\n nullable: false,\n presence: 'optional'\n }, options == null ? void 0 : options.spec);\n } // TODO: remove\n\n\n get _type() {\n return this.type;\n }\n\n _typeCheck(_value) {\n return true;\n }\n\n clone(spec) {\n if (this._mutate) {\n if (spec) Object.assign(this.spec, spec);\n return this;\n } // if the nested value is a schema we can skip cloning, since\n // they are already immutable\n\n\n const next = Object.create(Object.getPrototypeOf(this)); // @ts-expect-error this is readonly\n\n next.type = this.type;\n next._typeError = this._typeError;\n next._whitelistError = this._whitelistError;\n next._blacklistError = this._blacklistError;\n next._whitelist = this._whitelist.clone();\n next._blacklist = this._blacklist.clone();\n next.exclusiveTests = _extends({}, this.exclusiveTests); // @ts-expect-error this is readonly\n\n next.deps = [...this.deps];\n next.conditions = [...this.conditions];\n next.tests = [...this.tests];\n next.transforms = [...this.transforms];\n next.spec = (0, _nanoclone.default)(_extends({}, this.spec, spec));\n return next;\n }\n\n label(label) {\n var next = this.clone();\n next.spec.label = label;\n return next;\n }\n\n meta(...args) {\n if (args.length === 0) return this.spec.meta;\n let next = this.clone();\n next.spec.meta = Object.assign(next.spec.meta || {}, args[0]);\n return next;\n } // withContext(): BaseSchema<\n // TCast,\n // TContext,\n // TOutput\n // > {\n // return this as any;\n // }\n\n\n withMutation(fn) {\n let before = this._mutate;\n this._mutate = true;\n let result = fn(this);\n this._mutate = before;\n return result;\n }\n\n concat(schema) {\n if (!schema || schema === this) return this;\n if (schema.type !== this.type && this.type !== 'mixed') throw new TypeError(`You cannot \\`concat()\\` schema's of different types: ${this.type} and ${schema.type}`);\n let base = this;\n let combined = schema.clone();\n\n const mergedSpec = _extends({}, base.spec, combined.spec); // if (combined.spec.nullable === UNSET)\n // mergedSpec.nullable = base.spec.nullable;\n // if (combined.spec.presence === UNSET)\n // mergedSpec.presence = base.spec.presence;\n\n\n combined.spec = mergedSpec;\n combined._typeError || (combined._typeError = base._typeError);\n combined._whitelistError || (combined._whitelistError = base._whitelistError);\n combined._blacklistError || (combined._blacklistError = base._blacklistError); // manually merge the blacklist/whitelist (the other `schema` takes\n // precedence in case of conflicts)\n\n combined._whitelist = base._whitelist.merge(schema._whitelist, schema._blacklist);\n combined._blacklist = base._blacklist.merge(schema._blacklist, schema._whitelist); // start with the current tests\n\n combined.tests = base.tests;\n combined.exclusiveTests = base.exclusiveTests; // manually add the new tests to ensure\n // the deduping logic is consistent\n\n combined.withMutation(next => {\n schema.tests.forEach(fn => {\n next.test(fn.OPTIONS);\n });\n });\n return combined;\n }\n\n isType(v) {\n if (this.spec.nullable && v === null) return true;\n return this._typeCheck(v);\n }\n\n resolve(options) {\n let schema = this;\n\n if (schema.conditions.length) {\n let conditions = schema.conditions;\n schema = schema.clone();\n schema.conditions = [];\n schema = conditions.reduce((schema, condition) => condition.resolve(schema, options), schema);\n schema = schema.resolve(options);\n }\n\n return schema;\n }\n /**\n *\n * @param {*} value\n * @param {Object} options\n * @param {*=} options.parent\n * @param {*=} options.context\n */\n\n\n cast(value, options = {}) {\n let resolvedSchema = this.resolve(_extends({\n value\n }, options));\n\n let result = resolvedSchema._cast(value, options);\n\n if (value !== undefined && options.assert !== false && resolvedSchema.isType(result) !== true) {\n let formattedValue = (0, _printValue.default)(value);\n let formattedResult = (0, _printValue.default)(result);\n throw new TypeError(`The value of ${options.path || 'field'} could not be cast to a value ` + `that satisfies the schema type: \"${resolvedSchema._type}\". \\n\\n` + `attempted value: ${formattedValue} \\n` + (formattedResult !== formattedValue ? `result of cast: ${formattedResult}` : ''));\n }\n\n return result;\n }\n\n _cast(rawValue, _options) {\n let value = rawValue === undefined ? rawValue : this.transforms.reduce((value, fn) => fn.call(this, value, rawValue, this), rawValue);\n\n if (value === undefined) {\n value = this.getDefault();\n }\n\n return value;\n }\n\n _validate(_value, options = {}, cb) {\n let {\n sync,\n path,\n from = [],\n originalValue = _value,\n strict = this.spec.strict,\n abortEarly = this.spec.abortEarly\n } = options;\n let value = _value;\n\n if (!strict) {\n // this._validating = true;\n value = this._cast(value, _extends({\n assert: false\n }, options)); // this._validating = false;\n } // value is cast, we can check if it meets type requirements\n\n\n let args = {\n value,\n path,\n options,\n originalValue,\n schema: this,\n label: this.spec.label,\n sync,\n from\n };\n let initialTests = [];\n if (this._typeError) initialTests.push(this._typeError);\n if (this._whitelistError) initialTests.push(this._whitelistError);\n if (this._blacklistError) initialTests.push(this._blacklistError);\n (0, _runTests.default)({\n args,\n value,\n path,\n sync,\n tests: initialTests,\n endEarly: abortEarly\n }, err => {\n if (err) return void cb(err, value);\n (0, _runTests.default)({\n tests: this.tests,\n args,\n path,\n sync,\n value,\n endEarly: abortEarly\n }, cb);\n });\n }\n\n validate(value, options, maybeCb) {\n let schema = this.resolve(_extends({}, options, {\n value\n })); // callback case is for nested validations\n\n return typeof maybeCb === 'function' ? schema._validate(value, options, maybeCb) : new Promise((resolve, reject) => schema._validate(value, options, (err, value) => {\n if (err) reject(err);else resolve(value);\n }));\n }\n\n validateSync(value, options) {\n let schema = this.resolve(_extends({}, options, {\n value\n }));\n let result;\n\n schema._validate(value, _extends({}, options, {\n sync: true\n }), (err, value) => {\n if (err) throw err;\n result = value;\n });\n\n return result;\n }\n\n isValid(value, options) {\n return this.validate(value, options).then(() => true, err => {\n if (_ValidationError.default.isError(err)) return false;\n throw err;\n });\n }\n\n isValidSync(value, options) {\n try {\n this.validateSync(value, options);\n return true;\n } catch (err) {\n if (_ValidationError.default.isError(err)) return false;\n throw err;\n }\n }\n\n _getDefault() {\n let defaultValue = this.spec.default;\n\n if (defaultValue == null) {\n return defaultValue;\n }\n\n return typeof defaultValue === 'function' ? defaultValue.call(this) : (0, _nanoclone.default)(defaultValue);\n }\n\n getDefault(options) {\n let schema = this.resolve(options || {});\n return schema._getDefault();\n }\n\n default(def) {\n if (arguments.length === 0) {\n return this._getDefault();\n }\n\n let next = this.clone({\n default: def\n });\n return next;\n }\n\n strict(isStrict = true) {\n var next = this.clone();\n next.spec.strict = isStrict;\n return next;\n }\n\n _isPresent(value) {\n return value != null;\n }\n\n defined(message = _locale.mixed.defined) {\n return this.test({\n message,\n name: 'defined',\n exclusive: true,\n\n test(value) {\n return value !== undefined;\n }\n\n });\n }\n\n required(message = _locale.mixed.required) {\n return this.clone({\n presence: 'required'\n }).withMutation(s => s.test({\n message,\n name: 'required',\n exclusive: true,\n\n test(value) {\n return this.schema._isPresent(value);\n }\n\n }));\n }\n\n notRequired() {\n var next = this.clone({\n presence: 'optional'\n });\n next.tests = next.tests.filter(test => test.OPTIONS.name !== 'required');\n return next;\n }\n\n nullable(isNullable = true) {\n var next = this.clone({\n nullable: isNullable !== false\n });\n return next;\n }\n\n transform(fn) {\n var next = this.clone();\n next.transforms.push(fn);\n return next;\n }\n /**\n * Adds a test function to the schema's queue of tests.\n * tests can be exclusive or non-exclusive.\n *\n * - exclusive tests, will replace any existing tests of the same name.\n * - non-exclusive: can be stacked\n *\n * If a non-exclusive test is added to a schema with an exclusive test of the same name\n * the exclusive test is removed and further tests of the same name will be stacked.\n *\n * If an exclusive test is added to a schema with non-exclusive tests of the same name\n * the previous tests are removed and further tests of the same name will replace each other.\n */\n\n\n test(...args) {\n let opts;\n\n if (args.length === 1) {\n if (typeof args[0] === 'function') {\n opts = {\n test: args[0]\n };\n } else {\n opts = args[0];\n }\n } else if (args.length === 2) {\n opts = {\n name: args[0],\n test: args[1]\n };\n } else {\n opts = {\n name: args[0],\n message: args[1],\n test: args[2]\n };\n }\n\n if (opts.message === undefined) opts.message = _locale.mixed.default;\n if (typeof opts.test !== 'function') throw new TypeError('`test` is a required parameters');\n let next = this.clone();\n let validate = (0, _createValidation.default)(opts);\n let isExclusive = opts.exclusive || opts.name && next.exclusiveTests[opts.name] === true;\n\n if (opts.exclusive) {\n if (!opts.name) throw new TypeError('Exclusive tests must provide a unique `name` identifying the test');\n }\n\n if (opts.name) next.exclusiveTests[opts.name] = !!opts.exclusive;\n next.tests = next.tests.filter(fn => {\n if (fn.OPTIONS.name === opts.name) {\n if (isExclusive) return false;\n if (fn.OPTIONS.test === validate.OPTIONS.test) return false;\n }\n\n return true;\n });\n next.tests.push(validate);\n return next;\n }\n\n when(keys, options) {\n if (!Array.isArray(keys) && typeof keys !== 'string') {\n options = keys;\n keys = '.';\n }\n\n let next = this.clone();\n let deps = (0, _toArray.default)(keys).map(key => new _Reference.default(key));\n deps.forEach(dep => {\n // @ts-ignore\n if (dep.isSibling) next.deps.push(dep.key);\n });\n next.conditions.push(new _Condition.default(deps, options));\n return next;\n }\n\n typeError(message) {\n var next = this.clone();\n next._typeError = (0, _createValidation.default)({\n message,\n name: 'typeError',\n\n test(value) {\n if (value !== undefined && !this.schema.isType(value)) return this.createError({\n params: {\n type: this.schema._type\n }\n });\n return true;\n }\n\n });\n return next;\n }\n\n oneOf(enums, message = _locale.mixed.oneOf) {\n var next = this.clone();\n enums.forEach(val => {\n next._whitelist.add(val);\n\n next._blacklist.delete(val);\n });\n next._whitelistError = (0, _createValidation.default)({\n message,\n name: 'oneOf',\n\n test(value) {\n if (value === undefined) return true;\n let valids = this.schema._whitelist;\n return valids.has(value, this.resolve) ? true : this.createError({\n params: {\n values: valids.toArray().join(', ')\n }\n });\n }\n\n });\n return next;\n }\n\n notOneOf(enums, message = _locale.mixed.notOneOf) {\n var next = this.clone();\n enums.forEach(val => {\n next._blacklist.add(val);\n\n next._whitelist.delete(val);\n });\n next._blacklistError = (0, _createValidation.default)({\n message,\n name: 'notOneOf',\n\n test(value) {\n let invalids = this.schema._blacklist;\n if (invalids.has(value, this.resolve)) return this.createError({\n params: {\n values: invalids.toArray().join(', ')\n }\n });\n return true;\n }\n\n });\n return next;\n }\n\n strip(strip = true) {\n let next = this.clone();\n next.spec.strip = strip;\n return next;\n }\n\n describe() {\n const next = this.clone();\n const {\n label,\n meta\n } = next.spec;\n const description = {\n meta,\n label,\n type: next.type,\n oneOf: next._whitelist.describe(),\n notOneOf: next._blacklist.describe(),\n tests: next.tests.map(fn => ({\n name: fn.OPTIONS.name,\n params: fn.OPTIONS.params\n })).filter((n, idx, list) => list.findIndex(c => c.name === n.name) === idx)\n };\n return description;\n }\n\n}\n\nexports.default = BaseSchema;\n// @ts-expect-error\nBaseSchema.prototype.__isYupSchema__ = true;\n\nfor (const method of ['validate', 'validateSync']) BaseSchema.prototype[`${method}At`] = function (path, value, options = {}) {\n const {\n parent,\n parentPath,\n schema\n } = (0, _reach.getIn)(this, path, value, options.context);\n return schema[method](parent && parent[parentPath], _extends({}, options, {\n parent,\n path\n }));\n};\n\nfor (const alias of ['equals', 'is']) BaseSchema.prototype[alias] = BaseSchema.prototype.oneOf;\n\nfor (const alias of ['not', 'nope']) BaseSchema.prototype[alias] = BaseSchema.prototype.notOneOf;\n\nBaseSchema.prototype.optional = BaseSchema.prototype.notRequired;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.create = create;\nexports.default = void 0;\n\nvar _schema = _interopRequireDefault(require(\"./schema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nconst Mixed = _schema.default;\nvar _default = Mixed;\nexports.default = _default;\n\nfunction create() {\n return new Mixed();\n} // XXX: this is using the Base schema so that `addMethod(mixed)` works as a base class\n\n\ncreate.prototype = Mixed.prototype;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _default = value => value == null;\n\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.create = create;\nexports.default = void 0;\n\nvar _schema = _interopRequireDefault(require(\"./schema\"));\n\nvar _locale = require(\"./locale\");\n\nvar _isAbsent = _interopRequireDefault(require(\"./util/isAbsent\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction create() {\n return new BooleanSchema();\n}\n\nclass BooleanSchema extends _schema.default {\n constructor() {\n super({\n type: 'boolean'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n if (!this.isType(value)) {\n if (/^(true|1)$/i.test(String(value))) return true;\n if (/^(false|0)$/i.test(String(value))) return false;\n }\n\n return value;\n });\n });\n }\n\n _typeCheck(v) {\n if (v instanceof Boolean) v = v.valueOf();\n return typeof v === 'boolean';\n }\n\n isTrue(message = _locale.boolean.isValue) {\n return this.test({\n message,\n name: 'is-value',\n exclusive: true,\n params: {\n value: 'true'\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value === true;\n }\n\n });\n }\n\n isFalse(message = _locale.boolean.isValue) {\n return this.test({\n message,\n name: 'is-value',\n exclusive: true,\n params: {\n value: 'false'\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value === false;\n }\n\n });\n }\n\n}\n\nexports.default = BooleanSchema;\ncreate.prototype = BooleanSchema.prototype;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.create = create;\nexports.default = void 0;\n\nvar _locale = require(\"./locale\");\n\nvar _isAbsent = _interopRequireDefault(require(\"./util/isAbsent\"));\n\nvar _schema = _interopRequireDefault(require(\"./schema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\n// eslint-disable-next-line\nlet rEmail = /^((([a-z]|\\d|[!#\\$%&'\\*\\+\\-\\/=\\?\\^_`{\\|}~]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])+(\\.([a-z]|\\d|[!#\\$%&'\\*\\+\\-\\/=\\?\\^_`{\\|}~]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])+)*)|((\\x22)((((\\x20|\\x09)*(\\x0d\\x0a))?(\\x20|\\x09)+)?(([\\x01-\\x08\\x0b\\x0c\\x0e-\\x1f\\x7f]|\\x21|[\\x23-\\x5b]|[\\x5d-\\x7e]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(\\\\([\\x01-\\x09\\x0b\\x0c\\x0d-\\x7f]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]))))*(((\\x20|\\x09)*(\\x0d\\x0a))?(\\x20|\\x09)+)?(\\x22)))@((([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))\\.)+(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))$/i; // eslint-disable-next-line\n\nlet rUrl = /^((https?|ftp):)?\\/\\/(((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:)*@)?(((\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])\\.(\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])\\.(\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])\\.(\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5]))|((([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))\\.)+(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))\\.?)(:\\d*)?)(\\/((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)+(\\/(([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)*)*)?)?(\\?((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)|[\\uE000-\\uF8FF]|\\/|\\?)*)?(\\#((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)|\\/|\\?)*)?$/i; // eslint-disable-next-line\n\nlet rUUID = /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;\n\nlet isTrimmed = value => (0, _isAbsent.default)(value) || value === value.trim();\n\nlet objStringTag = {}.toString();\n\nfunction create() {\n return new StringSchema();\n}\n\nclass StringSchema extends _schema.default {\n constructor() {\n super({\n type: 'string'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n if (this.isType(value)) return value;\n if (Array.isArray(value)) return value;\n const strValue = value != null && value.toString ? value.toString() : value;\n if (strValue === objStringTag) return value;\n return strValue;\n });\n });\n }\n\n _typeCheck(value) {\n if (value instanceof String) value = value.valueOf();\n return typeof value === 'string';\n }\n\n _isPresent(value) {\n return super._isPresent(value) && !!value.length;\n }\n\n length(length, message = _locale.string.length) {\n return this.test({\n message,\n name: 'length',\n exclusive: true,\n params: {\n length\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value.length === this.resolve(length);\n }\n\n });\n }\n\n min(min, message = _locale.string.min) {\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value.length >= this.resolve(min);\n }\n\n });\n }\n\n max(max, message = _locale.string.max) {\n return this.test({\n name: 'max',\n exclusive: true,\n message,\n params: {\n max\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value.length <= this.resolve(max);\n }\n\n });\n }\n\n matches(regex, options) {\n let excludeEmptyString = false;\n let message;\n let name;\n\n if (options) {\n if (typeof options === 'object') {\n ({\n excludeEmptyString = false,\n message,\n name\n } = options);\n } else {\n message = options;\n }\n }\n\n return this.test({\n name: name || 'matches',\n message: message || _locale.string.matches,\n params: {\n regex\n },\n test: value => (0, _isAbsent.default)(value) || value === '' && excludeEmptyString || value.search(regex) !== -1\n });\n }\n\n email(message = _locale.string.email) {\n return this.matches(rEmail, {\n name: 'email',\n message,\n excludeEmptyString: true\n });\n }\n\n url(message = _locale.string.url) {\n return this.matches(rUrl, {\n name: 'url',\n message,\n excludeEmptyString: true\n });\n }\n\n uuid(message = _locale.string.uuid) {\n return this.matches(rUUID, {\n name: 'uuid',\n message,\n excludeEmptyString: false\n });\n } //-- transforms --\n\n\n ensure() {\n return this.default('').transform(val => val === null ? '' : val);\n }\n\n trim(message = _locale.string.trim) {\n return this.transform(val => val != null ? val.trim() : val).test({\n message,\n name: 'trim',\n test: isTrimmed\n });\n }\n\n lowercase(message = _locale.string.lowercase) {\n return this.transform(value => !(0, _isAbsent.default)(value) ? value.toLowerCase() : value).test({\n message,\n name: 'string_case',\n exclusive: true,\n test: value => (0, _isAbsent.default)(value) || value === value.toLowerCase()\n });\n }\n\n uppercase(message = _locale.string.uppercase) {\n return this.transform(value => !(0, _isAbsent.default)(value) ? value.toUpperCase() : value).test({\n message,\n name: 'string_case',\n exclusive: true,\n test: value => (0, _isAbsent.default)(value) || value === value.toUpperCase()\n });\n }\n\n}\n\nexports.default = StringSchema;\ncreate.prototype = StringSchema.prototype; //\n// String Interfaces\n//", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.create = create;\nexports.default = void 0;\n\nvar _locale = require(\"./locale\");\n\nvar _isAbsent = _interopRequireDefault(require(\"./util/isAbsent\"));\n\nvar _schema = _interopRequireDefault(require(\"./schema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nlet isNaN = value => value != +value;\n\nfunction create() {\n return new NumberSchema();\n}\n\nclass NumberSchema extends _schema.default {\n constructor() {\n super({\n type: 'number'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n let parsed = value;\n\n if (typeof parsed === 'string') {\n parsed = parsed.replace(/\\s/g, '');\n if (parsed === '') return NaN; // don't use parseFloat to avoid positives on alpha-numeric strings\n\n parsed = +parsed;\n }\n\n if (this.isType(parsed)) return parsed;\n return parseFloat(parsed);\n });\n });\n }\n\n _typeCheck(value) {\n if (value instanceof Number) value = value.valueOf();\n return typeof value === 'number' && !isNaN(value);\n }\n\n min(min, message = _locale.number.min) {\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value >= this.resolve(min);\n }\n\n });\n }\n\n max(max, message = _locale.number.max) {\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n max\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value <= this.resolve(max);\n }\n\n });\n }\n\n lessThan(less, message = _locale.number.lessThan) {\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n less\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value < this.resolve(less);\n }\n\n });\n }\n\n moreThan(more, message = _locale.number.moreThan) {\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n more\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value > this.resolve(more);\n }\n\n });\n }\n\n positive(msg = _locale.number.positive) {\n return this.moreThan(0, msg);\n }\n\n negative(msg = _locale.number.negative) {\n return this.lessThan(0, msg);\n }\n\n integer(message = _locale.number.integer) {\n return this.test({\n name: 'integer',\n message,\n test: val => (0, _isAbsent.default)(val) || Number.isInteger(val)\n });\n }\n\n truncate() {\n return this.transform(value => !(0, _isAbsent.default)(value) ? value | 0 : value);\n }\n\n round(method) {\n var _method;\n\n var avail = ['ceil', 'floor', 'round', 'trunc'];\n method = ((_method = method) == null ? void 0 : _method.toLowerCase()) || 'round'; // this exists for symemtry with the new Math.trunc\n\n if (method === 'trunc') return this.truncate();\n if (avail.indexOf(method.toLowerCase()) === -1) throw new TypeError('Only valid options for round() are: ' + avail.join(', '));\n return this.transform(value => !(0, _isAbsent.default)(value) ? Math[method](value) : value);\n }\n\n}\n\nexports.default = NumberSchema;\ncreate.prototype = NumberSchema.prototype; //\n// Number Interfaces\n//", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = parseIsoDate;\n\n/* eslint-disable */\n\n/**\n *\n * Date.parse with progressive enhancement for ISO 8601 \n * NON-CONFORMANT EDITION.\n * \u00A9 2011 Colin Snover \n * Released under MIT license.\n */\n// 1 YYYY 2 MM 3 DD 4 HH 5 mm 6 ss 7 msec 8 Z 9 \u00B1 10 tzHH 11 tzmm\nvar isoReg = /^(\\d{4}|[+\\-]\\d{6})(?:-?(\\d{2})(?:-?(\\d{2}))?)?(?:[ T]?(\\d{2}):?(\\d{2})(?::?(\\d{2})(?:[,\\.](\\d{1,}))?)?(?:(Z)|([+\\-])(\\d{2})(?::?(\\d{2}))?)?)?$/;\n\nfunction parseIsoDate(date) {\n var numericKeys = [1, 4, 5, 6, 7, 10, 11],\n minutesOffset = 0,\n timestamp,\n struct;\n\n if (struct = isoReg.exec(date)) {\n // avoid NaN timestamps caused by \u201Cundefined\u201D values being passed to Date.UTC\n for (var i = 0, k; k = numericKeys[i]; ++i) struct[k] = +struct[k] || 0; // allow undefined days and months\n\n\n struct[2] = (+struct[2] || 1) - 1;\n struct[3] = +struct[3] || 1; // allow arbitrary sub-second precision beyond milliseconds\n\n struct[7] = struct[7] ? String(struct[7]).substr(0, 3) : 0; // timestamps without timezone identifiers should be considered local time\n\n if ((struct[8] === undefined || struct[8] === '') && (struct[9] === undefined || struct[9] === '')) timestamp = +new Date(struct[1], struct[2], struct[3], struct[4], struct[5], struct[6], struct[7]);else {\n if (struct[8] !== 'Z' && struct[9] !== undefined) {\n minutesOffset = struct[10] * 60 + struct[11];\n if (struct[9] === '+') minutesOffset = 0 - minutesOffset;\n }\n\n timestamp = Date.UTC(struct[1], struct[2], struct[3], struct[4], struct[5] + minutesOffset, struct[6], struct[7]);\n }\n } else timestamp = Date.parse ? Date.parse(date) : NaN;\n\n return timestamp;\n}", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.create = create;\nexports.default = void 0;\n\nvar _isodate = _interopRequireDefault(require(\"./util/isodate\"));\n\nvar _locale = require(\"./locale\");\n\nvar _isAbsent = _interopRequireDefault(require(\"./util/isAbsent\"));\n\nvar _Reference = _interopRequireDefault(require(\"./Reference\"));\n\nvar _schema = _interopRequireDefault(require(\"./schema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\n// @ts-ignore\nlet invalidDate = new Date('');\n\nlet isDate = obj => Object.prototype.toString.call(obj) === '[object Date]';\n\nfunction create() {\n return new DateSchema();\n}\n\nclass DateSchema extends _schema.default {\n constructor() {\n super({\n type: 'date'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n if (this.isType(value)) return value;\n value = (0, _isodate.default)(value); // 0 is a valid timestamp equivalent to 1970-01-01T00:00:00Z(unix epoch) or before.\n\n return !isNaN(value) ? new Date(value) : invalidDate;\n });\n });\n }\n\n _typeCheck(v) {\n return isDate(v) && !isNaN(v.getTime());\n }\n\n prepareParam(ref, name) {\n let param;\n\n if (!_Reference.default.isRef(ref)) {\n let cast = this.cast(ref);\n if (!this._typeCheck(cast)) throw new TypeError(`\\`${name}\\` must be a Date or a value that can be \\`cast()\\` to a Date`);\n param = cast;\n } else {\n param = ref;\n }\n\n return param;\n }\n\n min(min, message = _locale.date.min) {\n let limit = this.prepareParam(min, 'min');\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value >= this.resolve(limit);\n }\n\n });\n }\n\n max(max, message = _locale.date.max) {\n var limit = this.prepareParam(max, 'max');\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n max\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value <= this.resolve(limit);\n }\n\n });\n }\n\n}\n\nexports.default = DateSchema;\nDateSchema.INVALID_DATE = invalidDate;\ncreate.prototype = DateSchema.prototype;\ncreate.INVALID_DATE = invalidDate;", "/**\n * A specialized version of `_.reduce` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {*} [accumulator] The initial value.\n * @param {boolean} [initAccum] Specify using the first element of `array` as\n * the initial value.\n * @returns {*} Returns the accumulated value.\n */\nfunction arrayReduce(array, iteratee, accumulator, initAccum) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n if (initAccum && length) {\n accumulator = array[++index];\n }\n while (++index < length) {\n accumulator = iteratee(accumulator, array[index], index, array);\n }\n return accumulator;\n}\n\nmodule.exports = arrayReduce;\n", "/**\n * The base implementation of `_.propertyOf` without support for deep paths.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Function} Returns the new accessor function.\n */\nfunction basePropertyOf(object) {\n return function(key) {\n return object == null ? undefined : object[key];\n };\n}\n\nmodule.exports = basePropertyOf;\n", "var basePropertyOf = require('./_basePropertyOf');\n\n/** Used to map Latin Unicode letters to basic Latin letters. */\nvar deburredLetters = {\n // Latin-1 Supplement block.\n '\\xc0': 'A', '\\xc1': 'A', '\\xc2': 'A', '\\xc3': 'A', '\\xc4': 'A', '\\xc5': 'A',\n '\\xe0': 'a', '\\xe1': 'a', '\\xe2': 'a', '\\xe3': 'a', '\\xe4': 'a', '\\xe5': 'a',\n '\\xc7': 'C', '\\xe7': 'c',\n '\\xd0': 'D', '\\xf0': 'd',\n '\\xc8': 'E', '\\xc9': 'E', '\\xca': 'E', '\\xcb': 'E',\n '\\xe8': 'e', '\\xe9': 'e', '\\xea': 'e', '\\xeb': 'e',\n '\\xcc': 'I', '\\xcd': 'I', '\\xce': 'I', '\\xcf': 'I',\n '\\xec': 'i', '\\xed': 'i', '\\xee': 'i', '\\xef': 'i',\n '\\xd1': 'N', '\\xf1': 'n',\n '\\xd2': 'O', '\\xd3': 'O', '\\xd4': 'O', '\\xd5': 'O', '\\xd6': 'O', '\\xd8': 'O',\n '\\xf2': 'o', '\\xf3': 'o', '\\xf4': 'o', '\\xf5': 'o', '\\xf6': 'o', '\\xf8': 'o',\n '\\xd9': 'U', '\\xda': 'U', '\\xdb': 'U', '\\xdc': 'U',\n '\\xf9': 'u', '\\xfa': 'u', '\\xfb': 'u', '\\xfc': 'u',\n '\\xdd': 'Y', '\\xfd': 'y', '\\xff': 'y',\n '\\xc6': 'Ae', '\\xe6': 'ae',\n '\\xde': 'Th', '\\xfe': 'th',\n '\\xdf': 'ss',\n // Latin Extended-A block.\n '\\u0100': 'A', '\\u0102': 'A', '\\u0104': 'A',\n '\\u0101': 'a', '\\u0103': 'a', '\\u0105': 'a',\n '\\u0106': 'C', '\\u0108': 'C', '\\u010a': 'C', '\\u010c': 'C',\n '\\u0107': 'c', '\\u0109': 'c', '\\u010b': 'c', '\\u010d': 'c',\n '\\u010e': 'D', '\\u0110': 'D', '\\u010f': 'd', '\\u0111': 'd',\n '\\u0112': 'E', '\\u0114': 'E', '\\u0116': 'E', '\\u0118': 'E', '\\u011a': 'E',\n '\\u0113': 'e', '\\u0115': 'e', '\\u0117': 'e', '\\u0119': 'e', '\\u011b': 'e',\n '\\u011c': 'G', '\\u011e': 'G', '\\u0120': 'G', '\\u0122': 'G',\n '\\u011d': 'g', '\\u011f': 'g', '\\u0121': 'g', '\\u0123': 'g',\n '\\u0124': 'H', '\\u0126': 'H', '\\u0125': 'h', '\\u0127': 'h',\n '\\u0128': 'I', '\\u012a': 'I', '\\u012c': 'I', '\\u012e': 'I', '\\u0130': 'I',\n '\\u0129': 'i', '\\u012b': 'i', '\\u012d': 'i', '\\u012f': 'i', '\\u0131': 'i',\n '\\u0134': 'J', '\\u0135': 'j',\n '\\u0136': 'K', '\\u0137': 'k', '\\u0138': 'k',\n '\\u0139': 'L', '\\u013b': 'L', '\\u013d': 'L', '\\u013f': 'L', '\\u0141': 'L',\n '\\u013a': 'l', '\\u013c': 'l', '\\u013e': 'l', '\\u0140': 'l', '\\u0142': 'l',\n '\\u0143': 'N', '\\u0145': 'N', '\\u0147': 'N', '\\u014a': 'N',\n '\\u0144': 'n', '\\u0146': 'n', '\\u0148': 'n', '\\u014b': 'n',\n '\\u014c': 'O', '\\u014e': 'O', '\\u0150': 'O',\n '\\u014d': 'o', '\\u014f': 'o', '\\u0151': 'o',\n '\\u0154': 'R', '\\u0156': 'R', '\\u0158': 'R',\n '\\u0155': 'r', '\\u0157': 'r', '\\u0159': 'r',\n '\\u015a': 'S', '\\u015c': 'S', '\\u015e': 'S', '\\u0160': 'S',\n '\\u015b': 's', '\\u015d': 's', '\\u015f': 's', '\\u0161': 's',\n '\\u0162': 'T', '\\u0164': 'T', '\\u0166': 'T',\n '\\u0163': 't', '\\u0165': 't', '\\u0167': 't',\n '\\u0168': 'U', '\\u016a': 'U', '\\u016c': 'U', '\\u016e': 'U', '\\u0170': 'U', '\\u0172': 'U',\n '\\u0169': 'u', '\\u016b': 'u', '\\u016d': 'u', '\\u016f': 'u', '\\u0171': 'u', '\\u0173': 'u',\n '\\u0174': 'W', '\\u0175': 'w',\n '\\u0176': 'Y', '\\u0177': 'y', '\\u0178': 'Y',\n '\\u0179': 'Z', '\\u017b': 'Z', '\\u017d': 'Z',\n '\\u017a': 'z', '\\u017c': 'z', '\\u017e': 'z',\n '\\u0132': 'IJ', '\\u0133': 'ij',\n '\\u0152': 'Oe', '\\u0153': 'oe',\n '\\u0149': \"'n\", '\\u017f': 's'\n};\n\n/**\n * Used by `_.deburr` to convert Latin-1 Supplement and Latin Extended-A\n * letters to basic Latin letters.\n *\n * @private\n * @param {string} letter The matched letter to deburr.\n * @returns {string} Returns the deburred letter.\n */\nvar deburrLetter = basePropertyOf(deburredLetters);\n\nmodule.exports = deburrLetter;\n", "var deburrLetter = require('./_deburrLetter'),\n toString = require('./toString');\n\n/** Used to match Latin Unicode letters (excluding mathematical operators). */\nvar reLatin = /[\\xc0-\\xd6\\xd8-\\xf6\\xf8-\\xff\\u0100-\\u017f]/g;\n\n/** Used to compose unicode character classes. */\nvar rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange;\n\n/** Used to compose unicode capture groups. */\nvar rsCombo = '[' + rsComboRange + ']';\n\n/**\n * Used to match [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks) and\n * [combining diacritical marks for symbols](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks_for_Symbols).\n */\nvar reComboMark = RegExp(rsCombo, 'g');\n\n/**\n * Deburrs `string` by converting\n * [Latin-1 Supplement](https://en.wikipedia.org/wiki/Latin-1_Supplement_(Unicode_block)#Character_table)\n * and [Latin Extended-A](https://en.wikipedia.org/wiki/Latin_Extended-A)\n * letters to basic Latin letters and removing\n * [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to deburr.\n * @returns {string} Returns the deburred string.\n * @example\n *\n * _.deburr('d\u00E9j\u00E0 vu');\n * // => 'deja vu'\n */\nfunction deburr(string) {\n string = toString(string);\n return string && string.replace(reLatin, deburrLetter).replace(reComboMark, '');\n}\n\nmodule.exports = deburr;\n", "/** Used to match words composed of alphanumeric characters. */\nvar reAsciiWord = /[^\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\x7f]+/g;\n\n/**\n * Splits an ASCII `string` into an array of its words.\n *\n * @private\n * @param {string} The string to inspect.\n * @returns {Array} Returns the words of `string`.\n */\nfunction asciiWords(string) {\n return string.match(reAsciiWord) || [];\n}\n\nmodule.exports = asciiWords;\n", "/** Used to detect strings that need a more robust regexp to match words. */\nvar reHasUnicodeWord = /[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;\n\n/**\n * Checks if `string` contains a word composed of Unicode symbols.\n *\n * @private\n * @param {string} string The string to inspect.\n * @returns {boolean} Returns `true` if a word is found, else `false`.\n */\nfunction hasUnicodeWord(string) {\n return reHasUnicodeWord.test(string);\n}\n\nmodule.exports = hasUnicodeWord;\n", "/** Used to compose unicode character classes. */\nvar rsAstralRange = '\\\\ud800-\\\\udfff',\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\n rsDingbatRange = '\\\\u2700-\\\\u27bf',\n rsLowerRange = 'a-z\\\\xdf-\\\\xf6\\\\xf8-\\\\xff',\n rsMathOpRange = '\\\\xac\\\\xb1\\\\xd7\\\\xf7',\n rsNonCharRange = '\\\\x00-\\\\x2f\\\\x3a-\\\\x40\\\\x5b-\\\\x60\\\\x7b-\\\\xbf',\n rsPunctuationRange = '\\\\u2000-\\\\u206f',\n rsSpaceRange = ' \\\\t\\\\x0b\\\\f\\\\xa0\\\\ufeff\\\\n\\\\r\\\\u2028\\\\u2029\\\\u1680\\\\u180e\\\\u2000\\\\u2001\\\\u2002\\\\u2003\\\\u2004\\\\u2005\\\\u2006\\\\u2007\\\\u2008\\\\u2009\\\\u200a\\\\u202f\\\\u205f\\\\u3000',\n rsUpperRange = 'A-Z\\\\xc0-\\\\xd6\\\\xd8-\\\\xde',\n rsVarRange = '\\\\ufe0e\\\\ufe0f',\n rsBreakRange = rsMathOpRange + rsNonCharRange + rsPunctuationRange + rsSpaceRange;\n\n/** Used to compose unicode capture groups. */\nvar rsApos = \"['\\u2019]\",\n rsBreak = '[' + rsBreakRange + ']',\n rsCombo = '[' + rsComboRange + ']',\n rsDigits = '\\\\d+',\n rsDingbat = '[' + rsDingbatRange + ']',\n rsLower = '[' + rsLowerRange + ']',\n rsMisc = '[^' + rsAstralRange + rsBreakRange + rsDigits + rsDingbatRange + rsLowerRange + rsUpperRange + ']',\n rsFitz = '\\\\ud83c[\\\\udffb-\\\\udfff]',\n rsModifier = '(?:' + rsCombo + '|' + rsFitz + ')',\n rsNonAstral = '[^' + rsAstralRange + ']',\n rsRegional = '(?:\\\\ud83c[\\\\udde6-\\\\uddff]){2}',\n rsSurrPair = '[\\\\ud800-\\\\udbff][\\\\udc00-\\\\udfff]',\n rsUpper = '[' + rsUpperRange + ']',\n rsZWJ = '\\\\u200d';\n\n/** Used to compose unicode regexes. */\nvar rsMiscLower = '(?:' + rsLower + '|' + rsMisc + ')',\n rsMiscUpper = '(?:' + rsUpper + '|' + rsMisc + ')',\n rsOptContrLower = '(?:' + rsApos + '(?:d|ll|m|re|s|t|ve))?',\n rsOptContrUpper = '(?:' + rsApos + '(?:D|LL|M|RE|S|T|VE))?',\n reOptMod = rsModifier + '?',\n rsOptVar = '[' + rsVarRange + ']?',\n rsOptJoin = '(?:' + rsZWJ + '(?:' + [rsNonAstral, rsRegional, rsSurrPair].join('|') + ')' + rsOptVar + reOptMod + ')*',\n rsOrdLower = '\\\\d*(?:1st|2nd|3rd|(?![123])\\\\dth)(?=\\\\b|[A-Z_])',\n rsOrdUpper = '\\\\d*(?:1ST|2ND|3RD|(?![123])\\\\dTH)(?=\\\\b|[a-z_])',\n rsSeq = rsOptVar + reOptMod + rsOptJoin,\n rsEmoji = '(?:' + [rsDingbat, rsRegional, rsSurrPair].join('|') + ')' + rsSeq;\n\n/** Used to match complex or compound words. */\nvar reUnicodeWord = RegExp([\n rsUpper + '?' + rsLower + '+' + rsOptContrLower + '(?=' + [rsBreak, rsUpper, '$'].join('|') + ')',\n rsMiscUpper + '+' + rsOptContrUpper + '(?=' + [rsBreak, rsUpper + rsMiscLower, '$'].join('|') + ')',\n rsUpper + '?' + rsMiscLower + '+' + rsOptContrLower,\n rsUpper + '+' + rsOptContrUpper,\n rsOrdUpper,\n rsOrdLower,\n rsDigits,\n rsEmoji\n].join('|'), 'g');\n\n/**\n * Splits a Unicode `string` into an array of its words.\n *\n * @private\n * @param {string} The string to inspect.\n * @returns {Array} Returns the words of `string`.\n */\nfunction unicodeWords(string) {\n return string.match(reUnicodeWord) || [];\n}\n\nmodule.exports = unicodeWords;\n", "var asciiWords = require('./_asciiWords'),\n hasUnicodeWord = require('./_hasUnicodeWord'),\n toString = require('./toString'),\n unicodeWords = require('./_unicodeWords');\n\n/**\n * Splits `string` into an array of its words.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to inspect.\n * @param {RegExp|string} [pattern] The pattern to match words.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {Array} Returns the words of `string`.\n * @example\n *\n * _.words('fred, barney, & pebbles');\n * // => ['fred', 'barney', 'pebbles']\n *\n * _.words('fred, barney, & pebbles', /[^, ]+/g);\n * // => ['fred', 'barney', '&', 'pebbles']\n */\nfunction words(string, pattern, guard) {\n string = toString(string);\n pattern = guard ? undefined : pattern;\n\n if (pattern === undefined) {\n return hasUnicodeWord(string) ? unicodeWords(string) : asciiWords(string);\n }\n return string.match(pattern) || [];\n}\n\nmodule.exports = words;\n", "var arrayReduce = require('./_arrayReduce'),\n deburr = require('./deburr'),\n words = require('./words');\n\n/** Used to compose unicode capture groups. */\nvar rsApos = \"['\\u2019]\";\n\n/** Used to match apostrophes. */\nvar reApos = RegExp(rsApos, 'g');\n\n/**\n * Creates a function like `_.camelCase`.\n *\n * @private\n * @param {Function} callback The function to combine each word.\n * @returns {Function} Returns the new compounder function.\n */\nfunction createCompounder(callback) {\n return function(string) {\n return arrayReduce(words(deburr(string).replace(reApos, '')), callback, '');\n };\n}\n\nmodule.exports = createCompounder;\n", "var createCompounder = require('./_createCompounder');\n\n/**\n * Converts `string` to\n * [snake case](https://en.wikipedia.org/wiki/Snake_case).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the snake cased string.\n * @example\n *\n * _.snakeCase('Foo Bar');\n * // => 'foo_bar'\n *\n * _.snakeCase('fooBar');\n * // => 'foo_bar'\n *\n * _.snakeCase('--FOO-BAR--');\n * // => 'foo_bar'\n */\nvar snakeCase = createCompounder(function(result, word, index) {\n return result + (index ? '_' : '') + word.toLowerCase();\n});\n\nmodule.exports = snakeCase;\n", "/**\n * The base implementation of `_.slice` without an iteratee call guard.\n *\n * @private\n * @param {Array} array The array to slice.\n * @param {number} [start=0] The start position.\n * @param {number} [end=array.length] The end position.\n * @returns {Array} Returns the slice of `array`.\n */\nfunction baseSlice(array, start, end) {\n var index = -1,\n length = array.length;\n\n if (start < 0) {\n start = -start > length ? 0 : (length + start);\n }\n end = end > length ? length : end;\n if (end < 0) {\n end += length;\n }\n length = start > end ? 0 : ((end - start) >>> 0);\n start >>>= 0;\n\n var result = Array(length);\n while (++index < length) {\n result[index] = array[index + start];\n }\n return result;\n}\n\nmodule.exports = baseSlice;\n", "var baseSlice = require('./_baseSlice');\n\n/**\n * Casts `array` to a slice if it's needed.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {number} start The start position.\n * @param {number} [end=array.length] The end position.\n * @returns {Array} Returns the cast slice.\n */\nfunction castSlice(array, start, end) {\n var length = array.length;\n end = end === undefined ? length : end;\n return (!start && end >= length) ? array : baseSlice(array, start, end);\n}\n\nmodule.exports = castSlice;\n", "/** Used to compose unicode character classes. */\nvar rsAstralRange = '\\\\ud800-\\\\udfff',\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\n rsVarRange = '\\\\ufe0e\\\\ufe0f';\n\n/** Used to compose unicode capture groups. */\nvar rsZWJ = '\\\\u200d';\n\n/** Used to detect strings with [zero-width joiners or code points from the astral planes](http://eev.ee/blog/2015/09/12/dark-corners-of-unicode/). */\nvar reHasUnicode = RegExp('[' + rsZWJ + rsAstralRange + rsComboRange + rsVarRange + ']');\n\n/**\n * Checks if `string` contains Unicode symbols.\n *\n * @private\n * @param {string} string The string to inspect.\n * @returns {boolean} Returns `true` if a symbol is found, else `false`.\n */\nfunction hasUnicode(string) {\n return reHasUnicode.test(string);\n}\n\nmodule.exports = hasUnicode;\n", "/**\n * Converts an ASCII `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\nfunction asciiToArray(string) {\n return string.split('');\n}\n\nmodule.exports = asciiToArray;\n", "/** Used to compose unicode character classes. */\nvar rsAstralRange = '\\\\ud800-\\\\udfff',\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\n rsVarRange = '\\\\ufe0e\\\\ufe0f';\n\n/** Used to compose unicode capture groups. */\nvar rsAstral = '[' + rsAstralRange + ']',\n rsCombo = '[' + rsComboRange + ']',\n rsFitz = '\\\\ud83c[\\\\udffb-\\\\udfff]',\n rsModifier = '(?:' + rsCombo + '|' + rsFitz + ')',\n rsNonAstral = '[^' + rsAstralRange + ']',\n rsRegional = '(?:\\\\ud83c[\\\\udde6-\\\\uddff]){2}',\n rsSurrPair = '[\\\\ud800-\\\\udbff][\\\\udc00-\\\\udfff]',\n rsZWJ = '\\\\u200d';\n\n/** Used to compose unicode regexes. */\nvar reOptMod = rsModifier + '?',\n rsOptVar = '[' + rsVarRange + ']?',\n rsOptJoin = '(?:' + rsZWJ + '(?:' + [rsNonAstral, rsRegional, rsSurrPair].join('|') + ')' + rsOptVar + reOptMod + ')*',\n rsSeq = rsOptVar + reOptMod + rsOptJoin,\n rsSymbol = '(?:' + [rsNonAstral + rsCombo + '?', rsCombo, rsRegional, rsSurrPair, rsAstral].join('|') + ')';\n\n/** Used to match [string symbols](https://mathiasbynens.be/notes/javascript-unicode). */\nvar reUnicode = RegExp(rsFitz + '(?=' + rsFitz + ')|' + rsSymbol + rsSeq, 'g');\n\n/**\n * Converts a Unicode `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\nfunction unicodeToArray(string) {\n return string.match(reUnicode) || [];\n}\n\nmodule.exports = unicodeToArray;\n", "var asciiToArray = require('./_asciiToArray'),\n hasUnicode = require('./_hasUnicode'),\n unicodeToArray = require('./_unicodeToArray');\n\n/**\n * Converts `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\nfunction stringToArray(string) {\n return hasUnicode(string)\n ? unicodeToArray(string)\n : asciiToArray(string);\n}\n\nmodule.exports = stringToArray;\n", "var castSlice = require('./_castSlice'),\n hasUnicode = require('./_hasUnicode'),\n stringToArray = require('./_stringToArray'),\n toString = require('./toString');\n\n/**\n * Creates a function like `_.lowerFirst`.\n *\n * @private\n * @param {string} methodName The name of the `String` case method to use.\n * @returns {Function} Returns the new case function.\n */\nfunction createCaseFirst(methodName) {\n return function(string) {\n string = toString(string);\n\n var strSymbols = hasUnicode(string)\n ? stringToArray(string)\n : undefined;\n\n var chr = strSymbols\n ? strSymbols[0]\n : string.charAt(0);\n\n var trailing = strSymbols\n ? castSlice(strSymbols, 1).join('')\n : string.slice(1);\n\n return chr[methodName]() + trailing;\n };\n}\n\nmodule.exports = createCaseFirst;\n", "var createCaseFirst = require('./_createCaseFirst');\n\n/**\n * Converts the first character of `string` to upper case.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the converted string.\n * @example\n *\n * _.upperFirst('fred');\n * // => 'Fred'\n *\n * _.upperFirst('FRED');\n * // => 'FRED'\n */\nvar upperFirst = createCaseFirst('toUpperCase');\n\nmodule.exports = upperFirst;\n", "var toString = require('./toString'),\n upperFirst = require('./upperFirst');\n\n/**\n * Converts the first character of `string` to upper case and the remaining\n * to lower case.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to capitalize.\n * @returns {string} Returns the capitalized string.\n * @example\n *\n * _.capitalize('FRED');\n * // => 'Fred'\n */\nfunction capitalize(string) {\n return upperFirst(toString(string).toLowerCase());\n}\n\nmodule.exports = capitalize;\n", "var capitalize = require('./capitalize'),\n createCompounder = require('./_createCompounder');\n\n/**\n * Converts `string` to [camel case](https://en.wikipedia.org/wiki/CamelCase).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the camel cased string.\n * @example\n *\n * _.camelCase('Foo Bar');\n * // => 'fooBar'\n *\n * _.camelCase('--foo-bar--');\n * // => 'fooBar'\n *\n * _.camelCase('__FOO_BAR__');\n * // => 'fooBar'\n */\nvar camelCase = createCompounder(function(result, word, index) {\n word = word.toLowerCase();\n return result + (index ? capitalize(word) : word);\n});\n\nmodule.exports = camelCase;\n", "var baseAssignValue = require('./_baseAssignValue'),\n baseForOwn = require('./_baseForOwn'),\n baseIteratee = require('./_baseIteratee');\n\n/**\n * The opposite of `_.mapValues`; this method creates an object with the\n * same values as `object` and keys generated by running each own enumerable\n * string keyed property of `object` thru `iteratee`. The iteratee is invoked\n * with three arguments: (value, key, object).\n *\n * @static\n * @memberOf _\n * @since 3.8.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Object} Returns the new mapped object.\n * @see _.mapValues\n * @example\n *\n * _.mapKeys({ 'a': 1, 'b': 2 }, function(value, key) {\n * return key + value;\n * });\n * // => { 'a1': 1, 'b2': 2 }\n */\nfunction mapKeys(object, iteratee) {\n var result = {};\n iteratee = baseIteratee(iteratee, 3);\n\n baseForOwn(object, function(value, key, object) {\n baseAssignValue(result, iteratee(value, key, object), value);\n });\n return result;\n}\n\nmodule.exports = mapKeys;\n", "\n/**\n * Topological sorting function\n *\n * @param {Array} edges\n * @returns {Array}\n */\n\nmodule.exports = function(edges) {\n return toposort(uniqueNodes(edges), edges)\n}\n\nmodule.exports.array = toposort\n\nfunction toposort(nodes, edges) {\n var cursor = nodes.length\n , sorted = new Array(cursor)\n , visited = {}\n , i = cursor\n // Better data structures make algorithm much faster.\n , outgoingEdges = makeOutgoingEdges(edges)\n , nodesHash = makeNodesHash(nodes)\n\n // check for unknown nodes\n edges.forEach(function(edge) {\n if (!nodesHash.has(edge[0]) || !nodesHash.has(edge[1])) {\n throw new Error('Unknown node. There is an unknown node in the supplied edges.')\n }\n })\n\n while (i--) {\n if (!visited[i]) visit(nodes[i], i, new Set())\n }\n\n return sorted\n\n function visit(node, i, predecessors) {\n if(predecessors.has(node)) {\n var nodeRep\n try {\n nodeRep = \", node was:\" + JSON.stringify(node)\n } catch(e) {\n nodeRep = \"\"\n }\n throw new Error('Cyclic dependency' + nodeRep)\n }\n\n if (!nodesHash.has(node)) {\n throw new Error('Found unknown node. Make sure to provided all involved nodes. Unknown node: '+JSON.stringify(node))\n }\n\n if (visited[i]) return;\n visited[i] = true\n\n var outgoing = outgoingEdges.get(node) || new Set()\n outgoing = Array.from(outgoing)\n\n if (i = outgoing.length) {\n predecessors.add(node)\n do {\n var child = outgoing[--i]\n visit(child, nodesHash.get(child), predecessors)\n } while (i)\n predecessors.delete(node)\n }\n\n sorted[--cursor] = node\n }\n}\n\nfunction uniqueNodes(arr){\n var res = new Set()\n for (var i = 0, len = arr.length; i < len; i++) {\n var edge = arr[i]\n res.add(edge[0])\n res.add(edge[1])\n }\n return Array.from(res)\n}\n\nfunction makeOutgoingEdges(arr){\n var edges = new Map()\n for (var i = 0, len = arr.length; i < len; i++) {\n var edge = arr[i]\n if (!edges.has(edge[0])) edges.set(edge[0], new Set())\n if (!edges.has(edge[1])) edges.set(edge[1], new Set())\n edges.get(edge[0]).add(edge[1])\n }\n return edges\n}\n\nfunction makeNodesHash(arr){\n var res = new Map()\n for (var i = 0, len = arr.length; i < len; i++) {\n res.set(arr[i], i)\n }\n return res\n}\n", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = sortFields;\n\nvar _has = _interopRequireDefault(require(\"lodash/has\"));\n\nvar _toposort = _interopRequireDefault(require(\"toposort\"));\n\nvar _propertyExpr = require(\"property-expr\");\n\nvar _Reference = _interopRequireDefault(require(\"../Reference\"));\n\nvar _isSchema = _interopRequireDefault(require(\"./isSchema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\n// @ts-expect-error\nfunction sortFields(fields, excludes = []) {\n let edges = [];\n let nodes = [];\n\n function addNode(depPath, key) {\n var node = (0, _propertyExpr.split)(depPath)[0];\n if (!~nodes.indexOf(node)) nodes.push(node);\n if (!~excludes.indexOf(`${key}-${node}`)) edges.push([key, node]);\n }\n\n for (const key in fields) if ((0, _has.default)(fields, key)) {\n let value = fields[key];\n if (!~nodes.indexOf(key)) nodes.push(key);\n if (_Reference.default.isRef(value) && value.isSibling) addNode(value.path, key);else if ((0, _isSchema.default)(value) && 'deps' in value) value.deps.forEach(path => addNode(path, key));\n }\n\n return _toposort.default.array(nodes, edges).reverse();\n}", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = sortByKeyOrder;\n\nfunction findIndex(arr, err) {\n let idx = Infinity;\n arr.some((key, ii) => {\n var _err$path;\n\n if (((_err$path = err.path) == null ? void 0 : _err$path.indexOf(key)) !== -1) {\n idx = ii;\n return true;\n }\n });\n return idx;\n}\n\nfunction sortByKeyOrder(keys) {\n return (a, b) => {\n return findIndex(keys, a) - findIndex(keys, b);\n };\n}", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.create = create;\nexports.default = void 0;\n\nvar _has = _interopRequireDefault(require(\"lodash/has\"));\n\nvar _snakeCase = _interopRequireDefault(require(\"lodash/snakeCase\"));\n\nvar _camelCase = _interopRequireDefault(require(\"lodash/camelCase\"));\n\nvar _mapKeys = _interopRequireDefault(require(\"lodash/mapKeys\"));\n\nvar _mapValues = _interopRequireDefault(require(\"lodash/mapValues\"));\n\nvar _propertyExpr = require(\"property-expr\");\n\nvar _locale = require(\"./locale\");\n\nvar _sortFields = _interopRequireDefault(require(\"./util/sortFields\"));\n\nvar _sortByKeyOrder = _interopRequireDefault(require(\"./util/sortByKeyOrder\"));\n\nvar _runTests = _interopRequireDefault(require(\"./util/runTests\"));\n\nvar _ValidationError = _interopRequireDefault(require(\"./ValidationError\"));\n\nvar _schema = _interopRequireDefault(require(\"./schema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nlet isObject = obj => Object.prototype.toString.call(obj) === '[object Object]';\n\nfunction unknown(ctx, value) {\n let known = Object.keys(ctx.fields);\n return Object.keys(value).filter(key => known.indexOf(key) === -1);\n}\n\nconst defaultSort = (0, _sortByKeyOrder.default)([]);\n\nclass ObjectSchema extends _schema.default {\n constructor(spec) {\n super({\n type: 'object'\n });\n this.fields = Object.create(null);\n this._sortErrors = defaultSort;\n this._nodes = [];\n this._excludedEdges = [];\n this.withMutation(() => {\n this.transform(function coerce(value) {\n if (typeof value === 'string') {\n try {\n value = JSON.parse(value);\n } catch (err) {\n value = null;\n }\n }\n\n if (this.isType(value)) return value;\n return null;\n });\n\n if (spec) {\n this.shape(spec);\n }\n });\n }\n\n _typeCheck(value) {\n return isObject(value) || typeof value === 'function';\n }\n\n _cast(_value, options = {}) {\n var _options$stripUnknown;\n\n let value = super._cast(_value, options); //should ignore nulls here\n\n\n if (value === undefined) return this.getDefault();\n if (!this._typeCheck(value)) return value;\n let fields = this.fields;\n let strip = (_options$stripUnknown = options.stripUnknown) != null ? _options$stripUnknown : this.spec.noUnknown;\n\n let props = this._nodes.concat(Object.keys(value).filter(v => this._nodes.indexOf(v) === -1));\n\n let intermediateValue = {}; // is filled during the transform below\n\n let innerOptions = _extends({}, options, {\n parent: intermediateValue,\n __validating: options.__validating || false\n });\n\n let isChanged = false;\n\n for (const prop of props) {\n let field = fields[prop];\n let exists = (0, _has.default)(value, prop);\n\n if (field) {\n let fieldValue;\n let inputValue = value[prop]; // safe to mutate since this is fired in sequence\n\n innerOptions.path = (options.path ? `${options.path}.` : '') + prop; // innerOptions.value = value[prop];\n\n field = field.resolve({\n value: inputValue,\n context: options.context,\n parent: intermediateValue\n });\n let fieldSpec = 'spec' in field ? field.spec : undefined;\n let strict = fieldSpec == null ? void 0 : fieldSpec.strict;\n\n if (fieldSpec == null ? void 0 : fieldSpec.strip) {\n isChanged = isChanged || prop in value;\n continue;\n }\n\n fieldValue = !options.__validating || !strict ? // TODO: use _cast, this is double resolving\n field.cast(value[prop], innerOptions) : value[prop];\n\n if (fieldValue !== undefined) {\n intermediateValue[prop] = fieldValue;\n }\n } else if (exists && !strip) {\n intermediateValue[prop] = value[prop];\n }\n\n if (intermediateValue[prop] !== value[prop]) {\n isChanged = true;\n }\n }\n\n return isChanged ? intermediateValue : value;\n }\n\n _validate(_value, opts = {}, callback) {\n let errors = [];\n let {\n sync,\n from = [],\n originalValue = _value,\n abortEarly = this.spec.abortEarly,\n recursive = this.spec.recursive\n } = opts;\n from = [{\n schema: this,\n value: originalValue\n }, ...from]; // this flag is needed for handling `strict` correctly in the context of\n // validation vs just casting. e.g strict() on a field is only used when validating\n\n opts.__validating = true;\n opts.originalValue = originalValue;\n opts.from = from;\n\n super._validate(_value, opts, (err, value) => {\n if (err) {\n if (!_ValidationError.default.isError(err) || abortEarly) {\n return void callback(err, value);\n }\n\n errors.push(err);\n }\n\n if (!recursive || !isObject(value)) {\n callback(errors[0] || null, value);\n return;\n }\n\n originalValue = originalValue || value;\n\n let tests = this._nodes.map(key => (_, cb) => {\n let path = key.indexOf('.') === -1 ? (opts.path ? `${opts.path}.` : '') + key : `${opts.path || ''}[\"${key}\"]`;\n let field = this.fields[key];\n\n if (field && 'validate' in field) {\n field.validate(value[key], _extends({}, opts, {\n // @ts-ignore\n path,\n from,\n // inner fields are always strict:\n // 1. this isn't strict so the casting will also have cast inner values\n // 2. this is strict in which case the nested values weren't cast either\n strict: true,\n parent: value,\n originalValue: originalValue[key]\n }), cb);\n return;\n }\n\n cb(null);\n });\n\n (0, _runTests.default)({\n sync,\n tests,\n value,\n errors,\n endEarly: abortEarly,\n sort: this._sortErrors,\n path: opts.path\n }, callback);\n });\n }\n\n clone(spec) {\n const next = super.clone(spec);\n next.fields = _extends({}, this.fields);\n next._nodes = this._nodes;\n next._excludedEdges = this._excludedEdges;\n next._sortErrors = this._sortErrors;\n return next;\n }\n\n concat(schema) {\n let next = super.concat(schema);\n let nextFields = next.fields;\n\n for (let [field, schemaOrRef] of Object.entries(this.fields)) {\n const target = nextFields[field];\n\n if (target === undefined) {\n nextFields[field] = schemaOrRef;\n } else if (target instanceof _schema.default && schemaOrRef instanceof _schema.default) {\n nextFields[field] = schemaOrRef.concat(target);\n }\n }\n\n return next.withMutation(() => next.shape(nextFields));\n }\n\n getDefaultFromShape() {\n let dft = {};\n\n this._nodes.forEach(key => {\n const field = this.fields[key];\n dft[key] = 'default' in field ? field.getDefault() : undefined;\n });\n\n return dft;\n }\n\n _getDefault() {\n if ('default' in this.spec) {\n return super._getDefault();\n } // if there is no default set invent one\n\n\n if (!this._nodes.length) {\n return undefined;\n }\n\n return this.getDefaultFromShape();\n }\n\n shape(additions, excludes = []) {\n let next = this.clone();\n let fields = Object.assign(next.fields, additions);\n next.fields = fields;\n next._sortErrors = (0, _sortByKeyOrder.default)(Object.keys(fields));\n\n if (excludes.length) {\n if (!Array.isArray(excludes[0])) excludes = [excludes];\n let keys = excludes.map(([first, second]) => `${first}-${second}`);\n next._excludedEdges = next._excludedEdges.concat(keys);\n }\n\n next._nodes = (0, _sortFields.default)(fields, next._excludedEdges);\n return next;\n }\n\n pick(keys) {\n const picked = {};\n\n for (const key of keys) {\n if (this.fields[key]) picked[key] = this.fields[key];\n }\n\n return this.clone().withMutation(next => {\n next.fields = {};\n return next.shape(picked);\n });\n }\n\n omit(keys) {\n const next = this.clone();\n const fields = next.fields;\n next.fields = {};\n\n for (const key of keys) {\n delete fields[key];\n }\n\n return next.withMutation(() => next.shape(fields));\n }\n\n from(from, to, alias) {\n let fromGetter = (0, _propertyExpr.getter)(from, true);\n return this.transform(obj => {\n if (obj == null) return obj;\n let newObj = obj;\n\n if ((0, _has.default)(obj, from)) {\n newObj = _extends({}, obj);\n if (!alias) delete newObj[from];\n newObj[to] = fromGetter(obj);\n }\n\n return newObj;\n });\n }\n\n noUnknown(noAllow = true, message = _locale.object.noUnknown) {\n if (typeof noAllow === 'string') {\n message = noAllow;\n noAllow = true;\n }\n\n let next = this.test({\n name: 'noUnknown',\n exclusive: true,\n message: message,\n\n test(value) {\n if (value == null) return true;\n const unknownKeys = unknown(this.schema, value);\n return !noAllow || unknownKeys.length === 0 || this.createError({\n params: {\n unknown: unknownKeys.join(', ')\n }\n });\n }\n\n });\n next.spec.noUnknown = noAllow;\n return next;\n }\n\n unknown(allow = true, message = _locale.object.noUnknown) {\n return this.noUnknown(!allow, message);\n }\n\n transformKeys(fn) {\n return this.transform(obj => obj && (0, _mapKeys.default)(obj, (_, key) => fn(key)));\n }\n\n camelCase() {\n return this.transformKeys(_camelCase.default);\n }\n\n snakeCase() {\n return this.transformKeys(_snakeCase.default);\n }\n\n constantCase() {\n return this.transformKeys(key => (0, _snakeCase.default)(key).toUpperCase());\n }\n\n describe() {\n let base = super.describe();\n base.fields = (0, _mapValues.default)(this.fields, value => value.describe());\n return base;\n }\n\n}\n\nexports.default = ObjectSchema;\n\nfunction create(spec) {\n return new ObjectSchema(spec);\n}\n\ncreate.prototype = ObjectSchema.prototype;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.create = create;\nexports.default = void 0;\n\nvar _isAbsent = _interopRequireDefault(require(\"./util/isAbsent\"));\n\nvar _isSchema = _interopRequireDefault(require(\"./util/isSchema\"));\n\nvar _printValue = _interopRequireDefault(require(\"./util/printValue\"));\n\nvar _locale = require(\"./locale\");\n\nvar _runTests = _interopRequireDefault(require(\"./util/runTests\"));\n\nvar _ValidationError = _interopRequireDefault(require(\"./ValidationError\"));\n\nvar _schema = _interopRequireDefault(require(\"./schema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nfunction create(type) {\n return new ArraySchema(type);\n}\n\nclass ArraySchema extends _schema.default {\n constructor(type) {\n super({\n type: 'array'\n }); // `undefined` specifically means uninitialized, as opposed to\n // \"no subtype\"\n\n this.innerType = type;\n this.withMutation(() => {\n this.transform(function (values) {\n if (typeof values === 'string') try {\n values = JSON.parse(values);\n } catch (err) {\n values = null;\n }\n return this.isType(values) ? values : null;\n });\n });\n }\n\n _typeCheck(v) {\n return Array.isArray(v);\n }\n\n get _subType() {\n return this.innerType;\n }\n\n _cast(_value, _opts) {\n const value = super._cast(_value, _opts); //should ignore nulls here\n\n\n if (!this._typeCheck(value) || !this.innerType) return value;\n let isChanged = false;\n const castArray = value.map((v, idx) => {\n const castElement = this.innerType.cast(v, _extends({}, _opts, {\n path: `${_opts.path || ''}[${idx}]`\n }));\n\n if (castElement !== v) {\n isChanged = true;\n }\n\n return castElement;\n });\n return isChanged ? castArray : value;\n }\n\n _validate(_value, options = {}, callback) {\n var _options$abortEarly, _options$recursive;\n\n let errors = [];\n let sync = options.sync;\n let path = options.path;\n let innerType = this.innerType;\n let endEarly = (_options$abortEarly = options.abortEarly) != null ? _options$abortEarly : this.spec.abortEarly;\n let recursive = (_options$recursive = options.recursive) != null ? _options$recursive : this.spec.recursive;\n let originalValue = options.originalValue != null ? options.originalValue : _value;\n\n super._validate(_value, options, (err, value) => {\n if (err) {\n if (!_ValidationError.default.isError(err) || endEarly) {\n return void callback(err, value);\n }\n\n errors.push(err);\n }\n\n if (!recursive || !innerType || !this._typeCheck(value)) {\n callback(errors[0] || null, value);\n return;\n }\n\n originalValue = originalValue || value; // #950 Ensure that sparse array empty slots are validated\n\n let tests = new Array(value.length);\n\n for (let idx = 0; idx < value.length; idx++) {\n let item = value[idx];\n let path = `${options.path || ''}[${idx}]`; // object._validate note for isStrict explanation\n\n let innerOptions = _extends({}, options, {\n path,\n strict: true,\n parent: value,\n index: idx,\n originalValue: originalValue[idx]\n });\n\n tests[idx] = (_, cb) => innerType.validate(item, innerOptions, cb);\n }\n\n (0, _runTests.default)({\n sync,\n path,\n value,\n errors,\n endEarly,\n tests\n }, callback);\n });\n }\n\n clone(spec) {\n const next = super.clone(spec);\n next.innerType = this.innerType;\n return next;\n }\n\n concat(schema) {\n let next = super.concat(schema);\n next.innerType = this.innerType;\n if (schema.innerType) next.innerType = next.innerType ? // @ts-expect-error Lazy doesn't have concat()\n next.innerType.concat(schema.innerType) : schema.innerType;\n return next;\n }\n\n of(schema) {\n // FIXME: this should return a new instance of array without the default to be\n let next = this.clone();\n if (!(0, _isSchema.default)(schema)) throw new TypeError('`array.of()` sub-schema must be a valid yup schema not: ' + (0, _printValue.default)(schema)); // FIXME(ts):\n\n next.innerType = schema;\n return next;\n }\n\n length(length, message = _locale.array.length) {\n return this.test({\n message,\n name: 'length',\n exclusive: true,\n params: {\n length\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value.length === this.resolve(length);\n }\n\n });\n }\n\n min(min, message) {\n message = message || _locale.array.min;\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n // FIXME(ts): Array\n test(value) {\n return (0, _isAbsent.default)(value) || value.length >= this.resolve(min);\n }\n\n });\n }\n\n max(max, message) {\n message = message || _locale.array.max;\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n max\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value.length <= this.resolve(max);\n }\n\n });\n }\n\n ensure() {\n return this.default(() => []).transform((val, original) => {\n // We don't want to return `null` for nullable schema\n if (this._typeCheck(val)) return val;\n return original == null ? [] : [].concat(original);\n });\n }\n\n compact(rejector) {\n let reject = !rejector ? v => !!v : (v, i, a) => !rejector(v, i, a);\n return this.transform(values => values != null ? values.filter(reject) : values);\n }\n\n describe() {\n let base = super.describe();\n if (this.innerType) base.innerType = this.innerType.describe();\n return base;\n }\n\n nullable(isNullable = true) {\n return super.nullable(isNullable);\n }\n\n defined() {\n return super.defined();\n }\n\n required(msg) {\n return super.required(msg);\n }\n\n}\n\nexports.default = ArraySchema;\ncreate.prototype = ArraySchema.prototype; //\n// Interfaces\n//", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.create = create;\nexports.default = void 0;\n\nvar _isSchema = _interopRequireDefault(require(\"./util/isSchema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction create(builder) {\n return new Lazy(builder);\n}\n\nclass Lazy {\n constructor(builder) {\n this.type = 'lazy';\n this.__isYupSchema__ = true;\n\n this._resolve = (value, options = {}) => {\n let schema = this.builder(value, options);\n if (!(0, _isSchema.default)(schema)) throw new TypeError('lazy() functions must return a valid schema');\n return schema.resolve(options);\n };\n\n this.builder = builder;\n }\n\n resolve(options) {\n return this._resolve(options.value, options);\n }\n\n cast(value, options) {\n return this._resolve(value, options).cast(value, options);\n }\n\n validate(value, options, maybeCb) {\n // @ts-expect-error missing public callback on type\n return this._resolve(value, options).validate(value, options, maybeCb);\n }\n\n validateSync(value, options) {\n return this._resolve(value, options).validateSync(value, options);\n }\n\n validateAt(path, value, options) {\n return this._resolve(value, options).validateAt(path, value, options);\n }\n\n validateSyncAt(path, value, options) {\n return this._resolve(value, options).validateSyncAt(path, value, options);\n }\n\n describe() {\n return null;\n }\n\n isValid(value, options) {\n return this._resolve(value, options).isValid(value, options);\n }\n\n isValidSync(value, options) {\n return this._resolve(value, options).isValidSync(value, options);\n }\n\n}\n\nvar _default = Lazy;\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = setLocale;\n\nvar _locale = _interopRequireDefault(require(\"./locale\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction setLocale(custom) {\n Object.keys(custom).forEach(type => {\n Object.keys(custom[type]).forEach(method => {\n _locale.default[type][method] = custom[type][method];\n });\n });\n}", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.addMethod = addMethod;\nObject.defineProperty(exports, \"MixedSchema\", {\n enumerable: true,\n get: function () {\n return _mixed.default;\n }\n});\nObject.defineProperty(exports, \"mixed\", {\n enumerable: true,\n get: function () {\n return _mixed.create;\n }\n});\nObject.defineProperty(exports, \"BooleanSchema\", {\n enumerable: true,\n get: function () {\n return _boolean.default;\n }\n});\nObject.defineProperty(exports, \"bool\", {\n enumerable: true,\n get: function () {\n return _boolean.create;\n }\n});\nObject.defineProperty(exports, \"boolean\", {\n enumerable: true,\n get: function () {\n return _boolean.create;\n }\n});\nObject.defineProperty(exports, \"StringSchema\", {\n enumerable: true,\n get: function () {\n return _string.default;\n }\n});\nObject.defineProperty(exports, \"string\", {\n enumerable: true,\n get: function () {\n return _string.create;\n }\n});\nObject.defineProperty(exports, \"NumberSchema\", {\n enumerable: true,\n get: function () {\n return _number.default;\n }\n});\nObject.defineProperty(exports, \"number\", {\n enumerable: true,\n get: function () {\n return _number.create;\n }\n});\nObject.defineProperty(exports, \"DateSchema\", {\n enumerable: true,\n get: function () {\n return _date.default;\n }\n});\nObject.defineProperty(exports, \"date\", {\n enumerable: true,\n get: function () {\n return _date.create;\n }\n});\nObject.defineProperty(exports, \"ObjectSchema\", {\n enumerable: true,\n get: function () {\n return _object.default;\n }\n});\nObject.defineProperty(exports, \"object\", {\n enumerable: true,\n get: function () {\n return _object.create;\n }\n});\nObject.defineProperty(exports, \"ArraySchema\", {\n enumerable: true,\n get: function () {\n return _array.default;\n }\n});\nObject.defineProperty(exports, \"array\", {\n enumerable: true,\n get: function () {\n return _array.create;\n }\n});\nObject.defineProperty(exports, \"ref\", {\n enumerable: true,\n get: function () {\n return _Reference.create;\n }\n});\nObject.defineProperty(exports, \"lazy\", {\n enumerable: true,\n get: function () {\n return _Lazy.create;\n }\n});\nObject.defineProperty(exports, \"ValidationError\", {\n enumerable: true,\n get: function () {\n return _ValidationError.default;\n }\n});\nObject.defineProperty(exports, \"reach\", {\n enumerable: true,\n get: function () {\n return _reach.default;\n }\n});\nObject.defineProperty(exports, \"isSchema\", {\n enumerable: true,\n get: function () {\n return _isSchema.default;\n }\n});\nObject.defineProperty(exports, \"setLocale\", {\n enumerable: true,\n get: function () {\n return _setLocale.default;\n }\n});\nObject.defineProperty(exports, \"BaseSchema\", {\n enumerable: true,\n get: function () {\n return _schema.default;\n }\n});\n\nvar _mixed = _interopRequireWildcard(require(\"./mixed\"));\n\nvar _boolean = _interopRequireWildcard(require(\"./boolean\"));\n\nvar _string = _interopRequireWildcard(require(\"./string\"));\n\nvar _number = _interopRequireWildcard(require(\"./number\"));\n\nvar _date = _interopRequireWildcard(require(\"./date\"));\n\nvar _object = _interopRequireWildcard(require(\"./object\"));\n\nvar _array = _interopRequireWildcard(require(\"./array\"));\n\nvar _Reference = require(\"./Reference\");\n\nvar _Lazy = require(\"./Lazy\");\n\nvar _ValidationError = _interopRequireDefault(require(\"./ValidationError\"));\n\nvar _reach = _interopRequireDefault(require(\"./util/reach\"));\n\nvar _isSchema = _interopRequireDefault(require(\"./util/isSchema\"));\n\nvar _setLocale = _interopRequireDefault(require(\"./setLocale\"));\n\nvar _schema = _interopRequireDefault(require(\"./schema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _getRequireWildcardCache() { if (typeof WeakMap !== \"function\") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }\n\nfunction _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== \"object\" && typeof obj !== \"function\") { return { default: obj }; } var cache = _getRequireWildcardCache(); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }\n\nfunction addMethod(schemaType, name, fn) {\n if (!schemaType || !(0, _isSchema.default)(schemaType.prototype)) throw new TypeError('You must provide a yup schema constructor function');\n if (typeof name !== 'string') throw new TypeError('A Method name must be provided');\n if (typeof fn !== 'function') throw new TypeError('Method function must be provided');\n schemaType.prototype[name] = fn;\n}", "const fs = require('fs')\nconst path = require('path')\nconst os = require('os')\nconst packageJson = require('../package.json')\n\nconst version = packageJson.version\n\nconst LINE = /(?:^|^)\\s*(?:export\\s+)?([\\w.-]+)(?:\\s*=\\s*?|:\\s+?)(\\s*'(?:\\\\'|[^'])*'|\\s*\"(?:\\\\\"|[^\"])*\"|\\s*`(?:\\\\`|[^`])*`|[^#\\r\\n]+)?\\s*(?:#.*)?(?:$|$)/mg\n\n// Parser src into an Object\nfunction parse (src) {\n const obj = {}\n\n // Convert buffer to string\n let lines = src.toString()\n\n // Convert line breaks to same format\n lines = lines.replace(/\\r\\n?/mg, '\\n')\n\n let match\n while ((match = LINE.exec(lines)) != null) {\n const key = match[1]\n\n // Default undefined or null to empty string\n let value = (match[2] || '')\n\n // Remove whitespace\n value = value.trim()\n\n // Check if double quoted\n const maybeQuote = value[0]\n\n // Remove surrounding quotes\n value = value.replace(/^(['\"`])([\\s\\S]*)\\1$/mg, '$2')\n\n // Expand newlines if double quoted\n if (maybeQuote === '\"') {\n value = value.replace(/\\\\n/g, '\\n')\n value = value.replace(/\\\\r/g, '\\r')\n }\n\n // Add to object\n obj[key] = value\n }\n\n return obj\n}\n\nfunction _log (message) {\n console.log(`[dotenv@${version}][DEBUG] ${message}`)\n}\n\nfunction _resolveHome (envPath) {\n return envPath[0] === '~' ? path.join(os.homedir(), envPath.slice(1)) : envPath\n}\n\n// Populates process.env from .env file\nfunction config (options) {\n let dotenvPath = path.resolve(process.cwd(), '.env')\n let encoding = 'utf8'\n const debug = Boolean(options && options.debug)\n const override = Boolean(options && options.override)\n\n if (options) {\n if (options.path != null) {\n dotenvPath = _resolveHome(options.path)\n }\n if (options.encoding != null) {\n encoding = options.encoding\n }\n }\n\n try {\n // Specifying an encoding returns a string instead of a buffer\n const parsed = DotenvModule.parse(fs.readFileSync(dotenvPath, { encoding }))\n\n Object.keys(parsed).forEach(function (key) {\n if (!Object.prototype.hasOwnProperty.call(process.env, key)) {\n process.env[key] = parsed[key]\n } else {\n if (override === true) {\n process.env[key] = parsed[key]\n }\n\n if (debug) {\n if (override === true) {\n _log(`\"${key}\" is already defined in \\`process.env\\` and WAS overwritten`)\n } else {\n _log(`\"${key}\" is already defined in \\`process.env\\` and was NOT overwritten`)\n }\n }\n }\n })\n\n return { parsed }\n } catch (e) {\n if (debug) {\n _log(`Failed to load ${dotenvPath} ${e.message}`)\n }\n\n return { error: e }\n }\n}\n\nconst DotenvModule = {\n config,\n parse\n}\n\nmodule.exports.config = DotenvModule.config\nmodule.exports.parse = DotenvModule.parse\nmodule.exports = DotenvModule\n", "(()=>{var __webpack_modules__={\"./node_modules/.pnpm/create-require@1.1.1/node_modules/create-require/create-require.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const nativeModule=__webpack_require__(\"module\"),path=__webpack_require__(\"path\"),fs=__webpack_require__(\"fs\");module.exports=function(filename){return filename||(filename=process.cwd()),function(path){try{return fs.lstatSync(path).isDirectory()}catch(e){return!1}}(filename)&&(filename=path.join(filename,\"index.js\")),nativeModule.createRequire?nativeModule.createRequire(filename):nativeModule.createRequireFromPath?nativeModule.createRequireFromPath(filename):function(filename){const mod=new nativeModule.Module(filename,null);return mod.filename=filename,mod.paths=nativeModule.Module._nodeModulePaths(path.dirname(filename)),mod._compile(\"module.exports = require;\",filename),mod.exports}(filename)}},\"./node_modules/.pnpm/lru-cache@6.0.0/node_modules/lru-cache/index.js\":(module,__unused_webpack_exports,__webpack_require__)=>{\"use strict\";const Yallist=__webpack_require__(\"./node_modules/.pnpm/yallist@4.0.0/node_modules/yallist/yallist.js\"),MAX=Symbol(\"max\"),LENGTH=Symbol(\"length\"),LENGTH_CALCULATOR=Symbol(\"lengthCalculator\"),ALLOW_STALE=Symbol(\"allowStale\"),MAX_AGE=Symbol(\"maxAge\"),DISPOSE=Symbol(\"dispose\"),NO_DISPOSE_ON_SET=Symbol(\"noDisposeOnSet\"),LRU_LIST=Symbol(\"lruList\"),CACHE=Symbol(\"cache\"),UPDATE_AGE_ON_GET=Symbol(\"updateAgeOnGet\"),naiveLength=()=>1;const get=(self,key,doUse)=>{const node=self[CACHE].get(key);if(node){const hit=node.value;if(isStale(self,hit)){if(del(self,node),!self[ALLOW_STALE])return}else doUse&&(self[UPDATE_AGE_ON_GET]&&(node.value.now=Date.now()),self[LRU_LIST].unshiftNode(node));return hit.value}},isStale=(self,hit)=>{if(!hit||!hit.maxAge&&!self[MAX_AGE])return!1;const diff=Date.now()-hit.now;return hit.maxAge?diff>hit.maxAge:self[MAX_AGE]&&diff>self[MAX_AGE]},trim=self=>{if(self[LENGTH]>self[MAX])for(let walker=self[LRU_LIST].tail;self[LENGTH]>self[MAX]&&null!==walker;){const prev=walker.prev;del(self,walker),walker=prev}},del=(self,node)=>{if(node){const hit=node.value;self[DISPOSE]&&self[DISPOSE](hit.key,hit.value),self[LENGTH]-=hit.length,self[CACHE].delete(hit.key),self[LRU_LIST].removeNode(node)}};class Entry{constructor(key,value,length,now,maxAge){this.key=key,this.value=value,this.length=length,this.now=now,this.maxAge=maxAge||0}}const forEachStep=(self,fn,node,thisp)=>{let hit=node.value;isStale(self,hit)&&(del(self,node),self[ALLOW_STALE]||(hit=void 0)),hit&&fn.call(thisp,hit.value,hit.key,self)};module.exports=class{constructor(options){if(\"number\"==typeof options&&(options={max:options}),options||(options={}),options.max&&(\"number\"!=typeof options.max||options.max<0))throw new TypeError(\"max must be a non-negative number\");this[MAX]=options.max||1/0;const lc=options.length||naiveLength;if(this[LENGTH_CALCULATOR]=\"function\"!=typeof lc?naiveLength:lc,this[ALLOW_STALE]=options.stale||!1,options.maxAge&&\"number\"!=typeof options.maxAge)throw new TypeError(\"maxAge must be a number\");this[MAX_AGE]=options.maxAge||0,this[DISPOSE]=options.dispose,this[NO_DISPOSE_ON_SET]=options.noDisposeOnSet||!1,this[UPDATE_AGE_ON_GET]=options.updateAgeOnGet||!1,this.reset()}set max(mL){if(\"number\"!=typeof mL||mL<0)throw new TypeError(\"max must be a non-negative number\");this[MAX]=mL||1/0,trim(this)}get max(){return this[MAX]}set allowStale(allowStale){this[ALLOW_STALE]=!!allowStale}get allowStale(){return this[ALLOW_STALE]}set maxAge(mA){if(\"number\"!=typeof mA)throw new TypeError(\"maxAge must be a non-negative number\");this[MAX_AGE]=mA,trim(this)}get maxAge(){return this[MAX_AGE]}set lengthCalculator(lC){\"function\"!=typeof lC&&(lC=naiveLength),lC!==this[LENGTH_CALCULATOR]&&(this[LENGTH_CALCULATOR]=lC,this[LENGTH]=0,this[LRU_LIST].forEach((hit=>{hit.length=this[LENGTH_CALCULATOR](hit.value,hit.key),this[LENGTH]+=hit.length}))),trim(this)}get lengthCalculator(){return this[LENGTH_CALCULATOR]}get length(){return this[LENGTH]}get itemCount(){return this[LRU_LIST].length}rforEach(fn,thisp){thisp=thisp||this;for(let walker=this[LRU_LIST].tail;null!==walker;){const prev=walker.prev;forEachStep(this,fn,walker,thisp),walker=prev}}forEach(fn,thisp){thisp=thisp||this;for(let walker=this[LRU_LIST].head;null!==walker;){const next=walker.next;forEachStep(this,fn,walker,thisp),walker=next}}keys(){return this[LRU_LIST].toArray().map((k=>k.key))}values(){return this[LRU_LIST].toArray().map((k=>k.value))}reset(){this[DISPOSE]&&this[LRU_LIST]&&this[LRU_LIST].length&&this[LRU_LIST].forEach((hit=>this[DISPOSE](hit.key,hit.value))),this[CACHE]=new Map,this[LRU_LIST]=new Yallist,this[LENGTH]=0}dump(){return this[LRU_LIST].map((hit=>!isStale(this,hit)&&{k:hit.key,v:hit.value,e:hit.now+(hit.maxAge||0)})).toArray().filter((h=>h))}dumpLru(){return this[LRU_LIST]}set(key,value,maxAge){if((maxAge=maxAge||this[MAX_AGE])&&\"number\"!=typeof maxAge)throw new TypeError(\"maxAge must be a number\");const now=maxAge?Date.now():0,len=this[LENGTH_CALCULATOR](value,key);if(this[CACHE].has(key)){if(len>this[MAX])return del(this,this[CACHE].get(key)),!1;const item=this[CACHE].get(key).value;return this[DISPOSE]&&(this[NO_DISPOSE_ON_SET]||this[DISPOSE](key,item.value)),item.now=now,item.maxAge=maxAge,item.value=value,this[LENGTH]+=len-item.length,item.length=len,this.get(key),trim(this),!0}const hit=new Entry(key,value,len,now,maxAge);return hit.length>this[MAX]?(this[DISPOSE]&&this[DISPOSE](key,value),!1):(this[LENGTH]+=hit.length,this[LRU_LIST].unshift(hit),this[CACHE].set(key,this[LRU_LIST].head),trim(this),!0)}has(key){if(!this[CACHE].has(key))return!1;const hit=this[CACHE].get(key).value;return!isStale(this,hit)}get(key){return get(this,key,!0)}peek(key){return get(this,key,!1)}pop(){const node=this[LRU_LIST].tail;return node?(del(this,node),node.value):null}del(key){del(this,this[CACHE].get(key))}load(arr){this.reset();const now=Date.now();for(let l=arr.length-1;l>=0;l--){const hit=arr[l],expiresAt=hit.e||0;if(0===expiresAt)this.set(hit.k,hit.v);else{const maxAge=expiresAt-now;maxAge>0&&this.set(hit.k,hit.v,maxAge)}}}prune(){this[CACHE].forEach(((value,key)=>get(this,key,!1)))}}},\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/index.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const optsArg=__webpack_require__(\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/opts-arg.js\"),pathArg=__webpack_require__(\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/path-arg.js\"),{mkdirpNative,mkdirpNativeSync}=__webpack_require__(\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/mkdirp-native.js\"),{mkdirpManual,mkdirpManualSync}=__webpack_require__(\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/mkdirp-manual.js\"),{useNative,useNativeSync}=__webpack_require__(\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/use-native.js\"),mkdirp=(path,opts)=>(path=pathArg(path),opts=optsArg(opts),useNative(opts)?mkdirpNative(path,opts):mkdirpManual(path,opts));mkdirp.sync=(path,opts)=>(path=pathArg(path),opts=optsArg(opts),useNativeSync(opts)?mkdirpNativeSync(path,opts):mkdirpManualSync(path,opts)),mkdirp.native=(path,opts)=>mkdirpNative(pathArg(path),optsArg(opts)),mkdirp.manual=(path,opts)=>mkdirpManual(pathArg(path),optsArg(opts)),mkdirp.nativeSync=(path,opts)=>mkdirpNativeSync(pathArg(path),optsArg(opts)),mkdirp.manualSync=(path,opts)=>mkdirpManualSync(pathArg(path),optsArg(opts)),module.exports=mkdirp},\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/find-made.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const{dirname}=__webpack_require__(\"path\"),findMade=(opts,parent,path)=>path===parent?Promise.resolve():opts.statAsync(parent).then((st=>st.isDirectory()?path:void 0),(er=>\"ENOENT\"===er.code?findMade(opts,dirname(parent),parent):void 0)),findMadeSync=(opts,parent,path)=>{if(path!==parent)try{return opts.statSync(parent).isDirectory()?path:void 0}catch(er){return\"ENOENT\"===er.code?findMadeSync(opts,dirname(parent),parent):void 0}};module.exports={findMade,findMadeSync}},\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/mkdirp-manual.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const{dirname}=__webpack_require__(\"path\"),mkdirpManual=(path,opts,made)=>{opts.recursive=!1;const parent=dirname(path);return parent===path?opts.mkdirAsync(path,opts).catch((er=>{if(\"EISDIR\"!==er.code)throw er})):opts.mkdirAsync(path,opts).then((()=>made||path),(er=>{if(\"ENOENT\"===er.code)return mkdirpManual(parent,opts).then((made=>mkdirpManual(path,opts,made)));if(\"EEXIST\"!==er.code&&\"EROFS\"!==er.code)throw er;return opts.statAsync(path).then((st=>{if(st.isDirectory())return made;throw er}),(()=>{throw er}))}))},mkdirpManualSync=(path,opts,made)=>{const parent=dirname(path);if(opts.recursive=!1,parent===path)try{return opts.mkdirSync(path,opts)}catch(er){if(\"EISDIR\"!==er.code)throw er;return}try{return opts.mkdirSync(path,opts),made||path}catch(er){if(\"ENOENT\"===er.code)return mkdirpManualSync(path,opts,mkdirpManualSync(parent,opts,made));if(\"EEXIST\"!==er.code&&\"EROFS\"!==er.code)throw er;try{if(!opts.statSync(path).isDirectory())throw er}catch(_){throw er}}};module.exports={mkdirpManual,mkdirpManualSync}},\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/mkdirp-native.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const{dirname}=__webpack_require__(\"path\"),{findMade,findMadeSync}=__webpack_require__(\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/find-made.js\"),{mkdirpManual,mkdirpManualSync}=__webpack_require__(\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/mkdirp-manual.js\");module.exports={mkdirpNative:(path,opts)=>{opts.recursive=!0;return dirname(path)===path?opts.mkdirAsync(path,opts):findMade(opts,path).then((made=>opts.mkdirAsync(path,opts).then((()=>made)).catch((er=>{if(\"ENOENT\"===er.code)return mkdirpManual(path,opts);throw er}))))},mkdirpNativeSync:(path,opts)=>{opts.recursive=!0;if(dirname(path)===path)return opts.mkdirSync(path,opts);const made=findMadeSync(opts,path);try{return opts.mkdirSync(path,opts),made}catch(er){if(\"ENOENT\"===er.code)return mkdirpManualSync(path,opts);throw er}}}},\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/opts-arg.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const{promisify}=__webpack_require__(\"util\"),fs=__webpack_require__(\"fs\");module.exports=opts=>{if(opts)if(\"object\"==typeof opts)opts={mode:511,fs,...opts};else if(\"number\"==typeof opts)opts={mode:opts,fs};else{if(\"string\"!=typeof opts)throw new TypeError(\"invalid options argument\");opts={mode:parseInt(opts,8),fs}}else opts={mode:511,fs};return opts.mkdir=opts.mkdir||opts.fs.mkdir||fs.mkdir,opts.mkdirAsync=promisify(opts.mkdir),opts.stat=opts.stat||opts.fs.stat||fs.stat,opts.statAsync=promisify(opts.stat),opts.statSync=opts.statSync||opts.fs.statSync||fs.statSync,opts.mkdirSync=opts.mkdirSync||opts.fs.mkdirSync||fs.mkdirSync,opts}},\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/path-arg.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const platform=process.env.__TESTING_MKDIRP_PLATFORM__||process.platform,{resolve,parse}=__webpack_require__(\"path\");module.exports=path=>{if(/\\0/.test(path))throw Object.assign(new TypeError(\"path must be a string without null bytes\"),{path,code:\"ERR_INVALID_ARG_VALUE\"});if(path=resolve(path),\"win32\"===platform){const badWinChars=/[*|\"<>?:]/,{root}=parse(path);if(badWinChars.test(path.substr(root.length)))throw Object.assign(new Error(\"Illegal characters in path.\"),{path,code:\"EINVAL\"})}return path}},\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/use-native.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const fs=__webpack_require__(\"fs\"),versArr=(process.env.__TESTING_MKDIRP_NODE_VERSION__||process.version).replace(/^v/,\"\").split(\".\"),hasNative=+versArr[0]>10||10==+versArr[0]&&+versArr[1]>=12,useNative=hasNative?opts=>opts.mkdir===fs.mkdir:()=>!1,useNativeSync=hasNative?opts=>opts.mkdirSync===fs.mkdirSync:()=>!1;module.exports={useNative,useNativeSync}},\"./node_modules/.pnpm/mlly@0.5.14/node_modules/mlly/dist lazy recursive\":module=>{function webpackEmptyAsyncContext(req){return Promise.resolve().then((()=>{var e=new Error(\"Cannot find module '\"+req+\"'\");throw e.code=\"MODULE_NOT_FOUND\",e}))}webpackEmptyAsyncContext.keys=()=>[],webpackEmptyAsyncContext.resolve=webpackEmptyAsyncContext,webpackEmptyAsyncContext.id=\"./node_modules/.pnpm/mlly@0.5.14/node_modules/mlly/dist lazy recursive\",module.exports=webpackEmptyAsyncContext},\"./node_modules/.pnpm/object-hash@3.0.0/node_modules/object-hash/index.js\":(module,exports,__webpack_require__)=>{\"use strict\";var crypto=__webpack_require__(\"crypto\");function objectHash(object,options){return function(object,options){var hashingStream;hashingStream=\"passthrough\"!==options.algorithm?crypto.createHash(options.algorithm):new PassThrough;void 0===hashingStream.write&&(hashingStream.write=hashingStream.update,hashingStream.end=hashingStream.update);typeHasher(options,hashingStream).dispatch(object),hashingStream.update||hashingStream.end(\"\");if(hashingStream.digest)return hashingStream.digest(\"buffer\"===options.encoding?void 0:options.encoding);var buf=hashingStream.read();if(\"buffer\"===options.encoding)return buf;return buf.toString(options.encoding)}(object,options=applyDefaults(object,options))}(exports=module.exports=objectHash).sha1=function(object){return objectHash(object)},exports.keys=function(object){return objectHash(object,{excludeValues:!0,algorithm:\"sha1\",encoding:\"hex\"})},exports.MD5=function(object){return objectHash(object,{algorithm:\"md5\",encoding:\"hex\"})},exports.keysMD5=function(object){return objectHash(object,{algorithm:\"md5\",encoding:\"hex\",excludeValues:!0})};var hashes=crypto.getHashes?crypto.getHashes().slice():[\"sha1\",\"md5\"];hashes.push(\"passthrough\");var encodings=[\"buffer\",\"hex\",\"binary\",\"base64\"];function applyDefaults(object,sourceOptions){sourceOptions=sourceOptions||{};var options={};if(options.algorithm=sourceOptions.algorithm||\"sha1\",options.encoding=sourceOptions.encoding||\"hex\",options.excludeValues=!!sourceOptions.excludeValues,options.algorithm=options.algorithm.toLowerCase(),options.encoding=options.encoding.toLowerCase(),options.ignoreUnknown=!0===sourceOptions.ignoreUnknown,options.respectType=!1!==sourceOptions.respectType,options.respectFunctionNames=!1!==sourceOptions.respectFunctionNames,options.respectFunctionProperties=!1!==sourceOptions.respectFunctionProperties,options.unorderedArrays=!0===sourceOptions.unorderedArrays,options.unorderedSets=!1!==sourceOptions.unorderedSets,options.unorderedObjects=!1!==sourceOptions.unorderedObjects,options.replacer=sourceOptions.replacer||void 0,options.excludeKeys=sourceOptions.excludeKeys||void 0,void 0===object)throw new Error(\"Object argument required.\");for(var i=0;i=0)return this.dispatch(\"[CIRCULAR:\"+objectNumber+\"]\");if(context.push(object),\"undefined\"!=typeof Buffer&&Buffer.isBuffer&&Buffer.isBuffer(object))return write(\"buffer:\"),write(object);if(\"object\"===objType||\"function\"===objType||\"asyncfunction\"===objType){var keys=Object.keys(object);options.unorderedObjects&&(keys=keys.sort()),!1===options.respectType||isNativeFunction(object)||keys.splice(0,0,\"prototype\",\"__proto__\",\"constructor\"),options.excludeKeys&&(keys=keys.filter((function(key){return!options.excludeKeys(key)}))),write(\"object:\"+keys.length+\":\");var self=this;return keys.forEach((function(key){self.dispatch(key),write(\":\"),options.excludeValues||self.dispatch(object[key]),write(\",\")}))}if(!this[\"_\"+objType]){if(options.ignoreUnknown)return write(\"[\"+objType+\"]\");throw new Error('Unknown object type \"'+objType+'\"')}this[\"_\"+objType](object)},_array:function(arr,unordered){unordered=void 0!==unordered?unordered:!1!==options.unorderedArrays;var self=this;if(write(\"array:\"+arr.length+\":\"),!unordered||arr.length<=1)return arr.forEach((function(entry){return self.dispatch(entry)}));var contextAdditions=[],entries=arr.map((function(entry){var strm=new PassThrough,localContext=context.slice();return typeHasher(options,strm,localContext).dispatch(entry),contextAdditions=contextAdditions.concat(localContext.slice(context.length)),strm.read().toString()}));return context=context.concat(contextAdditions),entries.sort(),this._array(entries,!1)},_date:function(date){return write(\"date:\"+date.toJSON())},_symbol:function(sym){return write(\"symbol:\"+sym.toString())},_error:function(err){return write(\"error:\"+err.toString())},_boolean:function(bool){return write(\"bool:\"+bool.toString())},_string:function(string){write(\"string:\"+string.length+\":\"),write(string.toString())},_function:function(fn){write(\"fn:\"),isNativeFunction(fn)?this.dispatch(\"[native]\"):this.dispatch(fn.toString()),!1!==options.respectFunctionNames&&this.dispatch(\"function-name:\"+String(fn.name)),options.respectFunctionProperties&&this._object(fn)},_number:function(number){return write(\"number:\"+number.toString())},_xml:function(xml){return write(\"xml:\"+xml.toString())},_null:function(){return write(\"Null\")},_undefined:function(){return write(\"Undefined\")},_regexp:function(regex){return write(\"regex:\"+regex.toString())},_uint8array:function(arr){return write(\"uint8array:\"),this.dispatch(Array.prototype.slice.call(arr))},_uint8clampedarray:function(arr){return write(\"uint8clampedarray:\"),this.dispatch(Array.prototype.slice.call(arr))},_int8array:function(arr){return write(\"int8array:\"),this.dispatch(Array.prototype.slice.call(arr))},_uint16array:function(arr){return write(\"uint16array:\"),this.dispatch(Array.prototype.slice.call(arr))},_int16array:function(arr){return write(\"int16array:\"),this.dispatch(Array.prototype.slice.call(arr))},_uint32array:function(arr){return write(\"uint32array:\"),this.dispatch(Array.prototype.slice.call(arr))},_int32array:function(arr){return write(\"int32array:\"),this.dispatch(Array.prototype.slice.call(arr))},_float32array:function(arr){return write(\"float32array:\"),this.dispatch(Array.prototype.slice.call(arr))},_float64array:function(arr){return write(\"float64array:\"),this.dispatch(Array.prototype.slice.call(arr))},_arraybuffer:function(arr){return write(\"arraybuffer:\"),this.dispatch(new Uint8Array(arr))},_url:function(url){return write(\"url:\"+url.toString())},_map:function(map){write(\"map:\");var arr=Array.from(map);return this._array(arr,!1!==options.unorderedSets)},_set:function(set){write(\"set:\");var arr=Array.from(set);return this._array(arr,!1!==options.unorderedSets)},_file:function(file){return write(\"file:\"),this.dispatch([file.name,file.size,file.type,file.lastModfied])},_blob:function(){if(options.ignoreUnknown)return write(\"[blob]\");throw Error('Hashing Blob objects is currently not supported\\n(see https://github.com/puleos/object-hash/issues/26)\\nUse \"options.replacer\" or \"options.ignoreUnknown\"\\n')},_domwindow:function(){return write(\"domwindow\")},_bigint:function(number){return write(\"bigint:\"+number.toString())},_process:function(){return write(\"process\")},_timer:function(){return write(\"timer\")},_pipe:function(){return write(\"pipe\")},_tcp:function(){return write(\"tcp\")},_udp:function(){return write(\"udp\")},_tty:function(){return write(\"tty\")},_statwatcher:function(){return write(\"statwatcher\")},_securecontext:function(){return write(\"securecontext\")},_connection:function(){return write(\"connection\")},_zlib:function(){return write(\"zlib\")},_context:function(){return write(\"context\")},_nodescript:function(){return write(\"nodescript\")},_httpparser:function(){return write(\"httpparser\")},_dataview:function(){return write(\"dataview\")},_signal:function(){return write(\"signal\")},_fsevent:function(){return write(\"fsevent\")},_tlswrap:function(){return write(\"tlswrap\")}}}function PassThrough(){return{buf:\"\",write:function(b){this.buf+=b},end:function(b){this.buf+=b},read:function(){return this.buf}}}exports.writeToStream=function(object,options,stream){return void 0===stream&&(stream=options,options={}),typeHasher(options=applyDefaults(object,options),stream).dispatch(object)}},\"./node_modules/.pnpm/pirates@4.0.5/node_modules/pirates/lib/index.js\":(module,exports,__webpack_require__)=>{\"use strict\";module=__webpack_require__.nmd(module),Object.defineProperty(exports,\"__esModule\",{value:!0}),exports.addHook=function(hook,opts={}){let reverted=!1;const loaders=[],oldLoaders=[];let exts;const originalJSLoader=Module._extensions[\".js\"],matcher=opts.matcher||null,ignoreNodeModules=!1!==opts.ignoreNodeModules;exts=opts.extensions||opts.exts||opts.extension||opts.ext||[\".js\"],Array.isArray(exts)||(exts=[exts]);return exts.forEach((ext=>{if(\"string\"!=typeof ext)throw new TypeError(`Invalid Extension: ${ext}`);const oldLoader=Module._extensions[ext]||originalJSLoader;oldLoaders[ext]=Module._extensions[ext],loaders[ext]=Module._extensions[ext]=function(mod,filename){let compile;reverted||function(filename,exts,matcher,ignoreNodeModules){if(\"string\"!=typeof filename)return!1;if(-1===exts.indexOf(_path.default.extname(filename)))return!1;const resolvedFilename=_path.default.resolve(filename);if(ignoreNodeModules&&nodeModulesRegex.test(resolvedFilename))return!1;if(matcher&&\"function\"==typeof matcher)return!!matcher(resolvedFilename);return!0}(filename,exts,matcher,ignoreNodeModules)&&(compile=mod._compile,mod._compile=function(code){mod._compile=compile;const newCode=hook(code,filename);if(\"string\"!=typeof newCode)throw new Error(\"[Pirates] A hook returned a non-string, or nothing at all! This is a violation of intergalactic law!\\n--------------------\\nIf you have no idea what this means or what Pirates is, let me explain: Pirates is a module that makes is easy to implement require hooks. One of the require hooks you're using uses it. One of these require hooks didn't return anything from it's handler, so we don't know what to do. You might want to debug this.\");return mod._compile(newCode,filename)}),oldLoader(mod,filename)}})),function(){reverted||(reverted=!0,exts.forEach((ext=>{Module._extensions[ext]===loaders[ext]&&(oldLoaders[ext]?Module._extensions[ext]=oldLoaders[ext]:delete Module._extensions[ext])})))}};var _module=_interopRequireDefault(__webpack_require__(\"module\")),_path=_interopRequireDefault(__webpack_require__(\"path\"));function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}const nodeModulesRegex=/^(?:.*[\\\\/])?node_modules(?:[\\\\/].*)?$/,Module=module.constructor.length>1?module.constructor:_module.default},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/comparator.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const ANY=Symbol(\"SemVer ANY\");class Comparator{static get ANY(){return ANY}constructor(comp,options){if(options=parseOptions(options),comp instanceof Comparator){if(comp.loose===!!options.loose)return comp;comp=comp.value}debug(\"comparator\",comp,options),this.options=options,this.loose=!!options.loose,this.parse(comp),this.semver===ANY?this.value=\"\":this.value=this.operator+this.semver.version,debug(\"comp\",this)}parse(comp){const r=this.options.loose?re[t.COMPARATORLOOSE]:re[t.COMPARATOR],m=comp.match(r);if(!m)throw new TypeError(`Invalid comparator: ${comp}`);this.operator=void 0!==m[1]?m[1]:\"\",\"=\"===this.operator&&(this.operator=\"\"),m[2]?this.semver=new SemVer(m[2],this.options.loose):this.semver=ANY}toString(){return this.value}test(version){if(debug(\"Comparator.test\",version,this.options.loose),this.semver===ANY||version===ANY)return!0;if(\"string\"==typeof version)try{version=new SemVer(version,this.options)}catch(er){return!1}return cmp(version,this.operator,this.semver,this.options)}intersects(comp,options){if(!(comp instanceof Comparator))throw new TypeError(\"a Comparator is required\");if(options&&\"object\"==typeof options||(options={loose:!!options,includePrerelease:!1}),\"\"===this.operator)return\"\"===this.value||new Range(comp.value,options).test(this.value);if(\"\"===comp.operator)return\"\"===comp.value||new Range(this.value,options).test(comp.semver);const sameDirectionIncreasing=!(\">=\"!==this.operator&&\">\"!==this.operator||\">=\"!==comp.operator&&\">\"!==comp.operator),sameDirectionDecreasing=!(\"<=\"!==this.operator&&\"<\"!==this.operator||\"<=\"!==comp.operator&&\"<\"!==comp.operator),sameSemVer=this.semver.version===comp.semver.version,differentDirectionsInclusive=!(\">=\"!==this.operator&&\"<=\"!==this.operator||\">=\"!==comp.operator&&\"<=\"!==comp.operator),oppositeDirectionsLessThan=cmp(this.semver,\"<\",comp.semver,options)&&(\">=\"===this.operator||\">\"===this.operator)&&(\"<=\"===comp.operator||\"<\"===comp.operator),oppositeDirectionsGreaterThan=cmp(this.semver,\">\",comp.semver,options)&&(\"<=\"===this.operator||\"<\"===this.operator)&&(\">=\"===comp.operator||\">\"===comp.operator);return sameDirectionIncreasing||sameDirectionDecreasing||sameSemVer&&differentDirectionsInclusive||oppositeDirectionsLessThan||oppositeDirectionsGreaterThan}}module.exports=Comparator;const parseOptions=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/parse-options.js\"),{re,t}=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/re.js\"),cmp=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/cmp.js\"),debug=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/debug.js\"),SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\"),Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\")},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\":(module,__unused_webpack_exports,__webpack_require__)=>{class Range{constructor(range,options){if(options=parseOptions(options),range instanceof Range)return range.loose===!!options.loose&&range.includePrerelease===!!options.includePrerelease?range:new Range(range.raw,options);if(range instanceof Comparator)return this.raw=range.value,this.set=[[range]],this.format(),this;if(this.options=options,this.loose=!!options.loose,this.includePrerelease=!!options.includePrerelease,this.raw=range,this.set=range.split(\"||\").map((r=>this.parseRange(r.trim()))).filter((c=>c.length)),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${range}`);if(this.set.length>1){const first=this.set[0];if(this.set=this.set.filter((c=>!isNullSet(c[0]))),0===this.set.length)this.set=[first];else if(this.set.length>1)for(const c of this.set)if(1===c.length&&isAny(c[0])){this.set=[c];break}}this.format()}format(){return this.range=this.set.map((comps=>comps.join(\" \").trim())).join(\"||\").trim(),this.range}toString(){return this.range}parseRange(range){range=range.trim();const memoKey=`parseRange:${Object.keys(this.options).join(\",\")}:${range}`,cached=cache.get(memoKey);if(cached)return cached;const loose=this.options.loose,hr=loose?re[t.HYPHENRANGELOOSE]:re[t.HYPHENRANGE];range=range.replace(hr,hyphenReplace(this.options.includePrerelease)),debug(\"hyphen replace\",range),range=range.replace(re[t.COMPARATORTRIM],comparatorTrimReplace),debug(\"comparator trim\",range);let rangeList=(range=(range=(range=range.replace(re[t.TILDETRIM],tildeTrimReplace)).replace(re[t.CARETTRIM],caretTrimReplace)).split(/\\s+/).join(\" \")).split(\" \").map((comp=>parseComparator(comp,this.options))).join(\" \").split(/\\s+/).map((comp=>replaceGTE0(comp,this.options)));loose&&(rangeList=rangeList.filter((comp=>(debug(\"loose invalid filter\",comp,this.options),!!comp.match(re[t.COMPARATORLOOSE]))))),debug(\"range list\",rangeList);const rangeMap=new Map,comparators=rangeList.map((comp=>new Comparator(comp,this.options)));for(const comp of comparators){if(isNullSet(comp))return[comp];rangeMap.set(comp.value,comp)}rangeMap.size>1&&rangeMap.has(\"\")&&rangeMap.delete(\"\");const result=[...rangeMap.values()];return cache.set(memoKey,result),result}intersects(range,options){if(!(range instanceof Range))throw new TypeError(\"a Range is required\");return this.set.some((thisComparators=>isSatisfiable(thisComparators,options)&&range.set.some((rangeComparators=>isSatisfiable(rangeComparators,options)&&thisComparators.every((thisComparator=>rangeComparators.every((rangeComparator=>thisComparator.intersects(rangeComparator,options)))))))))}test(version){if(!version)return!1;if(\"string\"==typeof version)try{version=new SemVer(version,this.options)}catch(er){return!1}for(let i=0;i\"<0.0.0-0\"===c.value,isAny=c=>\"\"===c.value,isSatisfiable=(comparators,options)=>{let result=!0;const remainingComparators=comparators.slice();let testComparator=remainingComparators.pop();for(;result&&remainingComparators.length;)result=remainingComparators.every((otherComparator=>testComparator.intersects(otherComparator,options))),testComparator=remainingComparators.pop();return result},parseComparator=(comp,options)=>(debug(\"comp\",comp,options),comp=replaceCarets(comp,options),debug(\"caret\",comp),comp=replaceTildes(comp,options),debug(\"tildes\",comp),comp=replaceXRanges(comp,options),debug(\"xrange\",comp),comp=replaceStars(comp,options),debug(\"stars\",comp),comp),isX=id=>!id||\"x\"===id.toLowerCase()||\"*\"===id,replaceTildes=(comp,options)=>comp.trim().split(/\\s+/).map((c=>replaceTilde(c,options))).join(\" \"),replaceTilde=(comp,options)=>{const r=options.loose?re[t.TILDELOOSE]:re[t.TILDE];return comp.replace(r,((_,M,m,p,pr)=>{let ret;return debug(\"tilde\",comp,_,M,m,p,pr),isX(M)?ret=\"\":isX(m)?ret=`>=${M}.0.0 <${+M+1}.0.0-0`:isX(p)?ret=`>=${M}.${m}.0 <${M}.${+m+1}.0-0`:pr?(debug(\"replaceTilde pr\",pr),ret=`>=${M}.${m}.${p}-${pr} <${M}.${+m+1}.0-0`):ret=`>=${M}.${m}.${p} <${M}.${+m+1}.0-0`,debug(\"tilde return\",ret),ret}))},replaceCarets=(comp,options)=>comp.trim().split(/\\s+/).map((c=>replaceCaret(c,options))).join(\" \"),replaceCaret=(comp,options)=>{debug(\"caret\",comp,options);const r=options.loose?re[t.CARETLOOSE]:re[t.CARET],z=options.includePrerelease?\"-0\":\"\";return comp.replace(r,((_,M,m,p,pr)=>{let ret;return debug(\"caret\",comp,_,M,m,p,pr),isX(M)?ret=\"\":isX(m)?ret=`>=${M}.0.0${z} <${+M+1}.0.0-0`:isX(p)?ret=\"0\"===M?`>=${M}.${m}.0${z} <${M}.${+m+1}.0-0`:`>=${M}.${m}.0${z} <${+M+1}.0.0-0`:pr?(debug(\"replaceCaret pr\",pr),ret=\"0\"===M?\"0\"===m?`>=${M}.${m}.${p}-${pr} <${M}.${m}.${+p+1}-0`:`>=${M}.${m}.${p}-${pr} <${M}.${+m+1}.0-0`:`>=${M}.${m}.${p}-${pr} <${+M+1}.0.0-0`):(debug(\"no pr\"),ret=\"0\"===M?\"0\"===m?`>=${M}.${m}.${p}${z} <${M}.${m}.${+p+1}-0`:`>=${M}.${m}.${p}${z} <${M}.${+m+1}.0-0`:`>=${M}.${m}.${p} <${+M+1}.0.0-0`),debug(\"caret return\",ret),ret}))},replaceXRanges=(comp,options)=>(debug(\"replaceXRanges\",comp,options),comp.split(/\\s+/).map((c=>replaceXRange(c,options))).join(\" \")),replaceXRange=(comp,options)=>{comp=comp.trim();const r=options.loose?re[t.XRANGELOOSE]:re[t.XRANGE];return comp.replace(r,((ret,gtlt,M,m,p,pr)=>{debug(\"xRange\",comp,ret,gtlt,M,m,p,pr);const xM=isX(M),xm=xM||isX(m),xp=xm||isX(p),anyX=xp;return\"=\"===gtlt&&anyX&&(gtlt=\"\"),pr=options.includePrerelease?\"-0\":\"\",xM?ret=\">\"===gtlt||\"<\"===gtlt?\"<0.0.0-0\":\"*\":gtlt&&anyX?(xm&&(m=0),p=0,\">\"===gtlt?(gtlt=\">=\",xm?(M=+M+1,m=0,p=0):(m=+m+1,p=0)):\"<=\"===gtlt&&(gtlt=\"<\",xm?M=+M+1:m=+m+1),\"<\"===gtlt&&(pr=\"-0\"),ret=`${gtlt+M}.${m}.${p}${pr}`):xm?ret=`>=${M}.0.0${pr} <${+M+1}.0.0-0`:xp&&(ret=`>=${M}.${m}.0${pr} <${M}.${+m+1}.0-0`),debug(\"xRange return\",ret),ret}))},replaceStars=(comp,options)=>(debug(\"replaceStars\",comp,options),comp.trim().replace(re[t.STAR],\"\")),replaceGTE0=(comp,options)=>(debug(\"replaceGTE0\",comp,options),comp.trim().replace(re[options.includePrerelease?t.GTE0PRE:t.GTE0],\"\")),hyphenReplace=incPr=>($0,from,fM,fm,fp,fpr,fb,to,tM,tm,tp,tpr,tb)=>`${from=isX(fM)?\"\":isX(fm)?`>=${fM}.0.0${incPr?\"-0\":\"\"}`:isX(fp)?`>=${fM}.${fm}.0${incPr?\"-0\":\"\"}`:fpr?`>=${from}`:`>=${from}${incPr?\"-0\":\"\"}`} ${to=isX(tM)?\"\":isX(tm)?`<${+tM+1}.0.0-0`:isX(tp)?`<${tM}.${+tm+1}.0-0`:tpr?`<=${tM}.${tm}.${tp}-${tpr}`:incPr?`<${tM}.${tm}.${+tp+1}-0`:`<=${to}`}`.trim(),testSet=(set,version,options)=>{for(let i=0;i0){const allowed=set[i].semver;if(allowed.major===version.major&&allowed.minor===version.minor&&allowed.patch===version.patch)return!0}return!1}return!0}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const debug=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/debug.js\"),{MAX_LENGTH,MAX_SAFE_INTEGER}=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/constants.js\"),{re,t}=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/re.js\"),parseOptions=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/parse-options.js\"),{compareIdentifiers}=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/identifiers.js\");class SemVer{constructor(version,options){if(options=parseOptions(options),version instanceof SemVer){if(version.loose===!!options.loose&&version.includePrerelease===!!options.includePrerelease)return version;version=version.version}else if(\"string\"!=typeof version)throw new TypeError(`Invalid Version: ${version}`);if(version.length>MAX_LENGTH)throw new TypeError(`version is longer than ${MAX_LENGTH} characters`);debug(\"SemVer\",version,options),this.options=options,this.loose=!!options.loose,this.includePrerelease=!!options.includePrerelease;const m=version.trim().match(options.loose?re[t.LOOSE]:re[t.FULL]);if(!m)throw new TypeError(`Invalid Version: ${version}`);if(this.raw=version,this.major=+m[1],this.minor=+m[2],this.patch=+m[3],this.major>MAX_SAFE_INTEGER||this.major<0)throw new TypeError(\"Invalid major version\");if(this.minor>MAX_SAFE_INTEGER||this.minor<0)throw new TypeError(\"Invalid minor version\");if(this.patch>MAX_SAFE_INTEGER||this.patch<0)throw new TypeError(\"Invalid patch version\");m[4]?this.prerelease=m[4].split(\".\").map((id=>{if(/^[0-9]+$/.test(id)){const num=+id;if(num>=0&&num=0;)\"number\"==typeof this.prerelease[i]&&(this.prerelease[i]++,i=-2);-1===i&&this.prerelease.push(0)}identifier&&(0===compareIdentifiers(this.prerelease[0],identifier)?isNaN(this.prerelease[1])&&(this.prerelease=[identifier,0]):this.prerelease=[identifier,0]);break;default:throw new Error(`invalid increment argument: ${release}`)}return this.format(),this.raw=this.version,this}}module.exports=SemVer},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/clean.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const parse=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/parse.js\");module.exports=(version,options)=>{const s=parse(version.trim().replace(/^[=v]+/,\"\"),options);return s?s.version:null}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/cmp.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const eq=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/eq.js\"),neq=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/neq.js\"),gt=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/gt.js\"),gte=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/gte.js\"),lt=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/lt.js\"),lte=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/lte.js\");module.exports=(a,op,b,loose)=>{switch(op){case\"===\":return\"object\"==typeof a&&(a=a.version),\"object\"==typeof b&&(b=b.version),a===b;case\"!==\":return\"object\"==typeof a&&(a=a.version),\"object\"==typeof b&&(b=b.version),a!==b;case\"\":case\"=\":case\"==\":return eq(a,b,loose);case\"!=\":return neq(a,b,loose);case\">\":return gt(a,b,loose);case\">=\":return gte(a,b,loose);case\"<\":return lt(a,b,loose);case\"<=\":return lte(a,b,loose);default:throw new TypeError(`Invalid operator: ${op}`)}}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/coerce.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\"),parse=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/parse.js\"),{re,t}=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/re.js\");module.exports=(version,options)=>{if(version instanceof SemVer)return version;if(\"number\"==typeof version&&(version=String(version)),\"string\"!=typeof version)return null;let match=null;if((options=options||{}).rtl){let next;for(;(next=re[t.COERCERTL].exec(version))&&(!match||match.index+match[0].length!==version.length);)match&&next.index+next[0].length===match.index+match[0].length||(match=next),re[t.COERCERTL].lastIndex=next.index+next[1].length+next[2].length;re[t.COERCERTL].lastIndex=-1}else match=version.match(re[t.COERCE]);return null===match?null:parse(`${match[2]}.${match[3]||\"0\"}.${match[4]||\"0\"}`,options)}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare-build.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\");module.exports=(a,b,loose)=>{const versionA=new SemVer(a,loose),versionB=new SemVer(b,loose);return versionA.compare(versionB)||versionA.compareBuild(versionB)}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare-loose.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\");module.exports=(a,b)=>compare(a,b,!0)},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\");module.exports=(a,b,loose)=>new SemVer(a,loose).compare(new SemVer(b,loose))},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/diff.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const parse=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/parse.js\"),eq=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/eq.js\");module.exports=(version1,version2)=>{if(eq(version1,version2))return null;{const v1=parse(version1),v2=parse(version2),hasPre=v1.prerelease.length||v2.prerelease.length,prefix=hasPre?\"pre\":\"\",defaultResult=hasPre?\"prerelease\":\"\";for(const key in v1)if((\"major\"===key||\"minor\"===key||\"patch\"===key)&&v1[key]!==v2[key])return prefix+key;return defaultResult}}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/eq.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\");module.exports=(a,b,loose)=>0===compare(a,b,loose)},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/gt.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\");module.exports=(a,b,loose)=>compare(a,b,loose)>0},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/gte.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\");module.exports=(a,b,loose)=>compare(a,b,loose)>=0},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/inc.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\");module.exports=(version,release,options,identifier)=>{\"string\"==typeof options&&(identifier=options,options=void 0);try{return new SemVer(version instanceof SemVer?version.version:version,options).inc(release,identifier).version}catch(er){return null}}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/lt.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\");module.exports=(a,b,loose)=>compare(a,b,loose)<0},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/lte.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\");module.exports=(a,b,loose)=>compare(a,b,loose)<=0},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/major.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\");module.exports=(a,loose)=>new SemVer(a,loose).major},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/minor.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\");module.exports=(a,loose)=>new SemVer(a,loose).minor},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/neq.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\");module.exports=(a,b,loose)=>0!==compare(a,b,loose)},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/parse.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const{MAX_LENGTH}=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/constants.js\"),{re,t}=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/re.js\"),SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\"),parseOptions=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/parse-options.js\");module.exports=(version,options)=>{if(options=parseOptions(options),version instanceof SemVer)return version;if(\"string\"!=typeof version)return null;if(version.length>MAX_LENGTH)return null;if(!(options.loose?re[t.LOOSE]:re[t.FULL]).test(version))return null;try{return new SemVer(version,options)}catch(er){return null}}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/patch.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\");module.exports=(a,loose)=>new SemVer(a,loose).patch},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/prerelease.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const parse=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/parse.js\");module.exports=(version,options)=>{const parsed=parse(version,options);return parsed&&parsed.prerelease.length?parsed.prerelease:null}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/rcompare.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\");module.exports=(a,b,loose)=>compare(b,a,loose)},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/rsort.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compareBuild=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare-build.js\");module.exports=(list,loose)=>list.sort(((a,b)=>compareBuild(b,a,loose)))},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/satisfies.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\");module.exports=(version,range,options)=>{try{range=new Range(range,options)}catch(er){return!1}return range.test(version)}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/sort.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compareBuild=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare-build.js\");module.exports=(list,loose)=>list.sort(((a,b)=>compareBuild(a,b,loose)))},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/valid.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const parse=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/parse.js\");module.exports=(version,options)=>{const v=parse(version,options);return v?v.version:null}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/index.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const internalRe=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/re.js\");module.exports={re:internalRe.re,src:internalRe.src,tokens:internalRe.t,SEMVER_SPEC_VERSION:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/constants.js\").SEMVER_SPEC_VERSION,SemVer:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\"),compareIdentifiers:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/identifiers.js\").compareIdentifiers,rcompareIdentifiers:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/identifiers.js\").rcompareIdentifiers,parse:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/parse.js\"),valid:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/valid.js\"),clean:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/clean.js\"),inc:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/inc.js\"),diff:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/diff.js\"),major:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/major.js\"),minor:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/minor.js\"),patch:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/patch.js\"),prerelease:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/prerelease.js\"),compare:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\"),rcompare:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/rcompare.js\"),compareLoose:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare-loose.js\"),compareBuild:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare-build.js\"),sort:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/sort.js\"),rsort:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/rsort.js\"),gt:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/gt.js\"),lt:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/lt.js\"),eq:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/eq.js\"),neq:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/neq.js\"),gte:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/gte.js\"),lte:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/lte.js\"),cmp:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/cmp.js\"),coerce:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/coerce.js\"),Comparator:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/comparator.js\"),Range:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\"),satisfies:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/satisfies.js\"),toComparators:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/to-comparators.js\"),maxSatisfying:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/max-satisfying.js\"),minSatisfying:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/min-satisfying.js\"),minVersion:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/min-version.js\"),validRange:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/valid.js\"),outside:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/outside.js\"),gtr:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/gtr.js\"),ltr:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/ltr.js\"),intersects:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/intersects.js\"),simplifyRange:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/simplify.js\"),subset:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/subset.js\")}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/constants.js\":module=>{const MAX_SAFE_INTEGER=Number.MAX_SAFE_INTEGER||9007199254740991;module.exports={SEMVER_SPEC_VERSION:\"2.0.0\",MAX_LENGTH:256,MAX_SAFE_INTEGER,MAX_SAFE_COMPONENT_LENGTH:16}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/debug.js\":module=>{const debug=\"object\"==typeof process&&process.env&&process.env.NODE_DEBUG&&/\\bsemver\\b/i.test(process.env.NODE_DEBUG)?(...args)=>console.error(\"SEMVER\",...args):()=>{};module.exports=debug},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/identifiers.js\":module=>{const numeric=/^[0-9]+$/,compareIdentifiers=(a,b)=>{const anum=numeric.test(a),bnum=numeric.test(b);return anum&&bnum&&(a=+a,b=+b),a===b?0:anum&&!bnum?-1:bnum&&!anum?1:acompareIdentifiers(b,a)}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/parse-options.js\":module=>{const opts=[\"includePrerelease\",\"loose\",\"rtl\"];module.exports=options=>options?\"object\"!=typeof options?{loose:!0}:opts.filter((k=>options[k])).reduce(((o,k)=>(o[k]=!0,o)),{}):{}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/re.js\":(module,exports,__webpack_require__)=>{const{MAX_SAFE_COMPONENT_LENGTH}=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/constants.js\"),debug=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/debug.js\"),re=(exports=module.exports={}).re=[],src=exports.src=[],t=exports.t={};let R=0;const createToken=(name,value,isGlobal)=>{const index=R++;debug(name,index,value),t[name]=index,src[index]=value,re[index]=new RegExp(value,isGlobal?\"g\":void 0)};createToken(\"NUMERICIDENTIFIER\",\"0|[1-9]\\\\d*\"),createToken(\"NUMERICIDENTIFIERLOOSE\",\"[0-9]+\"),createToken(\"NONNUMERICIDENTIFIER\",\"\\\\d*[a-zA-Z-][a-zA-Z0-9-]*\"),createToken(\"MAINVERSION\",`(${src[t.NUMERICIDENTIFIER]})\\\\.(${src[t.NUMERICIDENTIFIER]})\\\\.(${src[t.NUMERICIDENTIFIER]})`),createToken(\"MAINVERSIONLOOSE\",`(${src[t.NUMERICIDENTIFIERLOOSE]})\\\\.(${src[t.NUMERICIDENTIFIERLOOSE]})\\\\.(${src[t.NUMERICIDENTIFIERLOOSE]})`),createToken(\"PRERELEASEIDENTIFIER\",`(?:${src[t.NUMERICIDENTIFIER]}|${src[t.NONNUMERICIDENTIFIER]})`),createToken(\"PRERELEASEIDENTIFIERLOOSE\",`(?:${src[t.NUMERICIDENTIFIERLOOSE]}|${src[t.NONNUMERICIDENTIFIER]})`),createToken(\"PRERELEASE\",`(?:-(${src[t.PRERELEASEIDENTIFIER]}(?:\\\\.${src[t.PRERELEASEIDENTIFIER]})*))`),createToken(\"PRERELEASELOOSE\",`(?:-?(${src[t.PRERELEASEIDENTIFIERLOOSE]}(?:\\\\.${src[t.PRERELEASEIDENTIFIERLOOSE]})*))`),createToken(\"BUILDIDENTIFIER\",\"[0-9A-Za-z-]+\"),createToken(\"BUILD\",`(?:\\\\+(${src[t.BUILDIDENTIFIER]}(?:\\\\.${src[t.BUILDIDENTIFIER]})*))`),createToken(\"FULLPLAIN\",`v?${src[t.MAINVERSION]}${src[t.PRERELEASE]}?${src[t.BUILD]}?`),createToken(\"FULL\",`^${src[t.FULLPLAIN]}$`),createToken(\"LOOSEPLAIN\",`[v=\\\\s]*${src[t.MAINVERSIONLOOSE]}${src[t.PRERELEASELOOSE]}?${src[t.BUILD]}?`),createToken(\"LOOSE\",`^${src[t.LOOSEPLAIN]}$`),createToken(\"GTLT\",\"((?:<|>)?=?)\"),createToken(\"XRANGEIDENTIFIERLOOSE\",`${src[t.NUMERICIDENTIFIERLOOSE]}|x|X|\\\\*`),createToken(\"XRANGEIDENTIFIER\",`${src[t.NUMERICIDENTIFIER]}|x|X|\\\\*`),createToken(\"XRANGEPLAIN\",`[v=\\\\s]*(${src[t.XRANGEIDENTIFIER]})(?:\\\\.(${src[t.XRANGEIDENTIFIER]})(?:\\\\.(${src[t.XRANGEIDENTIFIER]})(?:${src[t.PRERELEASE]})?${src[t.BUILD]}?)?)?`),createToken(\"XRANGEPLAINLOOSE\",`[v=\\\\s]*(${src[t.XRANGEIDENTIFIERLOOSE]})(?:\\\\.(${src[t.XRANGEIDENTIFIERLOOSE]})(?:\\\\.(${src[t.XRANGEIDENTIFIERLOOSE]})(?:${src[t.PRERELEASELOOSE]})?${src[t.BUILD]}?)?)?`),createToken(\"XRANGE\",`^${src[t.GTLT]}\\\\s*${src[t.XRANGEPLAIN]}$`),createToken(\"XRANGELOOSE\",`^${src[t.GTLT]}\\\\s*${src[t.XRANGEPLAINLOOSE]}$`),createToken(\"COERCE\",`(^|[^\\\\d])(\\\\d{1,${MAX_SAFE_COMPONENT_LENGTH}})(?:\\\\.(\\\\d{1,${MAX_SAFE_COMPONENT_LENGTH}}))?(?:\\\\.(\\\\d{1,${MAX_SAFE_COMPONENT_LENGTH}}))?(?:$|[^\\\\d])`),createToken(\"COERCERTL\",src[t.COERCE],!0),createToken(\"LONETILDE\",\"(?:~>?)\"),createToken(\"TILDETRIM\",`(\\\\s*)${src[t.LONETILDE]}\\\\s+`,!0),exports.tildeTrimReplace=\"$1~\",createToken(\"TILDE\",`^${src[t.LONETILDE]}${src[t.XRANGEPLAIN]}$`),createToken(\"TILDELOOSE\",`^${src[t.LONETILDE]}${src[t.XRANGEPLAINLOOSE]}$`),createToken(\"LONECARET\",\"(?:\\\\^)\"),createToken(\"CARETTRIM\",`(\\\\s*)${src[t.LONECARET]}\\\\s+`,!0),exports.caretTrimReplace=\"$1^\",createToken(\"CARET\",`^${src[t.LONECARET]}${src[t.XRANGEPLAIN]}$`),createToken(\"CARETLOOSE\",`^${src[t.LONECARET]}${src[t.XRANGEPLAINLOOSE]}$`),createToken(\"COMPARATORLOOSE\",`^${src[t.GTLT]}\\\\s*(${src[t.LOOSEPLAIN]})$|^$`),createToken(\"COMPARATOR\",`^${src[t.GTLT]}\\\\s*(${src[t.FULLPLAIN]})$|^$`),createToken(\"COMPARATORTRIM\",`(\\\\s*)${src[t.GTLT]}\\\\s*(${src[t.LOOSEPLAIN]}|${src[t.XRANGEPLAIN]})`,!0),exports.comparatorTrimReplace=\"$1$2$3\",createToken(\"HYPHENRANGE\",`^\\\\s*(${src[t.XRANGEPLAIN]})\\\\s+-\\\\s+(${src[t.XRANGEPLAIN]})\\\\s*$`),createToken(\"HYPHENRANGELOOSE\",`^\\\\s*(${src[t.XRANGEPLAINLOOSE]})\\\\s+-\\\\s+(${src[t.XRANGEPLAINLOOSE]})\\\\s*$`),createToken(\"STAR\",\"(<|>)?=?\\\\s*\\\\*\"),createToken(\"GTE0\",\"^\\\\s*>=\\\\s*0\\\\.0\\\\.0\\\\s*$\"),createToken(\"GTE0PRE\",\"^\\\\s*>=\\\\s*0\\\\.0\\\\.0-0\\\\s*$\")},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/gtr.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const outside=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/outside.js\");module.exports=(version,range,options)=>outside(version,range,\">\",options)},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/intersects.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\");module.exports=(r1,r2,options)=>(r1=new Range(r1,options),r2=new Range(r2,options),r1.intersects(r2))},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/ltr.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const outside=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/outside.js\");module.exports=(version,range,options)=>outside(version,range,\"<\",options)},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/max-satisfying.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\"),Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\");module.exports=(versions,range,options)=>{let max=null,maxSV=null,rangeObj=null;try{rangeObj=new Range(range,options)}catch(er){return null}return versions.forEach((v=>{rangeObj.test(v)&&(max&&-1!==maxSV.compare(v)||(max=v,maxSV=new SemVer(max,options)))})),max}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/min-satisfying.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\"),Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\");module.exports=(versions,range,options)=>{let min=null,minSV=null,rangeObj=null;try{rangeObj=new Range(range,options)}catch(er){return null}return versions.forEach((v=>{rangeObj.test(v)&&(min&&1!==minSV.compare(v)||(min=v,minSV=new SemVer(min,options)))})),min}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/min-version.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\"),Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\"),gt=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/gt.js\");module.exports=(range,loose)=>{range=new Range(range,loose);let minver=new SemVer(\"0.0.0\");if(range.test(minver))return minver;if(minver=new SemVer(\"0.0.0-0\"),range.test(minver))return minver;minver=null;for(let i=0;i{const compver=new SemVer(comparator.semver.version);switch(comparator.operator){case\">\":0===compver.prerelease.length?compver.patch++:compver.prerelease.push(0),compver.raw=compver.format();case\"\":case\">=\":setMin&&!gt(compver,setMin)||(setMin=compver);break;case\"<\":case\"<=\":break;default:throw new Error(`Unexpected operation: ${comparator.operator}`)}})),!setMin||minver&&!gt(minver,setMin)||(minver=setMin)}return minver&&range.test(minver)?minver:null}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/outside.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\"),Comparator=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/comparator.js\"),{ANY}=Comparator,Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\"),satisfies=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/satisfies.js\"),gt=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/gt.js\"),lt=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/lt.js\"),lte=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/lte.js\"),gte=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/gte.js\");module.exports=(version,range,hilo,options)=>{let gtfn,ltefn,ltfn,comp,ecomp;switch(version=new SemVer(version,options),range=new Range(range,options),hilo){case\">\":gtfn=gt,ltefn=lte,ltfn=lt,comp=\">\",ecomp=\">=\";break;case\"<\":gtfn=lt,ltefn=gte,ltfn=gt,comp=\"<\",ecomp=\"<=\";break;default:throw new TypeError('Must provide a hilo val of \"<\" or \">\"')}if(satisfies(version,range,options))return!1;for(let i=0;i{comparator.semver===ANY&&(comparator=new Comparator(\">=0.0.0\")),high=high||comparator,low=low||comparator,gtfn(comparator.semver,high.semver,options)?high=comparator:ltfn(comparator.semver,low.semver,options)&&(low=comparator)})),high.operator===comp||high.operator===ecomp)return!1;if((!low.operator||low.operator===comp)&<efn(version,low.semver))return!1;if(low.operator===ecomp&<fn(version,low.semver))return!1}return!0}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/simplify.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const satisfies=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/satisfies.js\"),compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\");module.exports=(versions,range,options)=>{const set=[];let first=null,prev=null;const v=versions.sort(((a,b)=>compare(a,b,options)));for(const version of v){satisfies(version,range,options)?(prev=version,first||(first=version)):(prev&&set.push([first,prev]),prev=null,first=null)}first&&set.push([first,null]);const ranges=[];for(const[min,max]of set)min===max?ranges.push(min):max||min!==v[0]?max?min===v[0]?ranges.push(`<=${max}`):ranges.push(`${min} - ${max}`):ranges.push(`>=${min}`):ranges.push(\"*\");const simplified=ranges.join(\" || \"),original=\"string\"==typeof range.raw?range.raw:String(range);return simplified.length{const Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\"),Comparator=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/comparator.js\"),{ANY}=Comparator,satisfies=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/satisfies.js\"),compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\"),simpleSubset=(sub,dom,options)=>{if(sub===dom)return!0;if(1===sub.length&&sub[0].semver===ANY){if(1===dom.length&&dom[0].semver===ANY)return!0;sub=options.includePrerelease?[new Comparator(\">=0.0.0-0\")]:[new Comparator(\">=0.0.0\")]}if(1===dom.length&&dom[0].semver===ANY){if(options.includePrerelease)return!0;dom=[new Comparator(\">=0.0.0\")]}const eqSet=new Set;let gt,lt,gtltComp,higher,lower,hasDomLT,hasDomGT;for(const c of sub)\">\"===c.operator||\">=\"===c.operator?gt=higherGT(gt,c,options):\"<\"===c.operator||\"<=\"===c.operator?lt=lowerLT(lt,c,options):eqSet.add(c.semver);if(eqSet.size>1)return null;if(gt&<){if(gtltComp=compare(gt.semver,lt.semver,options),gtltComp>0)return null;if(0===gtltComp&&(\">=\"!==gt.operator||\"<=\"!==lt.operator))return null}for(const eq of eqSet){if(gt&&!satisfies(eq,String(gt),options))return null;if(lt&&!satisfies(eq,String(lt),options))return null;for(const c of dom)if(!satisfies(eq,String(c),options))return!1;return!0}let needDomLTPre=!(!lt||options.includePrerelease||!lt.semver.prerelease.length)&<.semver,needDomGTPre=!(!gt||options.includePrerelease||!gt.semver.prerelease.length)&>.semver;needDomLTPre&&1===needDomLTPre.prerelease.length&&\"<\"===lt.operator&&0===needDomLTPre.prerelease[0]&&(needDomLTPre=!1);for(const c of dom){if(hasDomGT=hasDomGT||\">\"===c.operator||\">=\"===c.operator,hasDomLT=hasDomLT||\"<\"===c.operator||\"<=\"===c.operator,gt)if(needDomGTPre&&c.semver.prerelease&&c.semver.prerelease.length&&c.semver.major===needDomGTPre.major&&c.semver.minor===needDomGTPre.minor&&c.semver.patch===needDomGTPre.patch&&(needDomGTPre=!1),\">\"===c.operator||\">=\"===c.operator){if(higher=higherGT(gt,c,options),higher===c&&higher!==gt)return!1}else if(\">=\"===gt.operator&&!satisfies(gt.semver,String(c),options))return!1;if(lt)if(needDomLTPre&&c.semver.prerelease&&c.semver.prerelease.length&&c.semver.major===needDomLTPre.major&&c.semver.minor===needDomLTPre.minor&&c.semver.patch===needDomLTPre.patch&&(needDomLTPre=!1),\"<\"===c.operator||\"<=\"===c.operator){if(lower=lowerLT(lt,c,options),lower===c&&lower!==lt)return!1}else if(\"<=\"===lt.operator&&!satisfies(lt.semver,String(c),options))return!1;if(!c.operator&&(lt||gt)&&0!==gtltComp)return!1}return!(gt&&hasDomLT&&!lt&&0!==gtltComp)&&(!(lt&&hasDomGT&&!gt&&0!==gtltComp)&&(!needDomGTPre&&!needDomLTPre))},higherGT=(a,b,options)=>{if(!a)return b;const comp=compare(a.semver,b.semver,options);return comp>0?a:comp<0||\">\"===b.operator&&\">=\"===a.operator?b:a},lowerLT=(a,b,options)=>{if(!a)return b;const comp=compare(a.semver,b.semver,options);return comp<0?a:comp>0||\"<\"===b.operator&&\"<=\"===a.operator?b:a};module.exports=(sub,dom,options={})=>{if(sub===dom)return!0;sub=new Range(sub,options),dom=new Range(dom,options);let sawNonNull=!1;OUTER:for(const simpleSub of sub.set){for(const simpleDom of dom.set){const isSub=simpleSubset(simpleSub,simpleDom,options);if(sawNonNull=sawNonNull||null!==isSub,isSub)continue OUTER}if(sawNonNull)return!1}return!0}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/to-comparators.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\");module.exports=(range,options)=>new Range(range,options).set.map((comp=>comp.map((c=>c.value)).join(\" \").trim().split(\" \")))},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/valid.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\");module.exports=(range,options)=>{try{return new Range(range,options).range||\"*\"}catch(er){return null}}},\"./node_modules/.pnpm/yallist@4.0.0/node_modules/yallist/iterator.js\":module=>{\"use strict\";module.exports=function(Yallist){Yallist.prototype[Symbol.iterator]=function*(){for(let walker=this.head;walker;walker=walker.next)yield walker.value}}},\"./node_modules/.pnpm/yallist@4.0.0/node_modules/yallist/yallist.js\":(module,__unused_webpack_exports,__webpack_require__)=>{\"use strict\";function Yallist(list){var self=this;if(self instanceof Yallist||(self=new Yallist),self.tail=null,self.head=null,self.length=0,list&&\"function\"==typeof list.forEach)list.forEach((function(item){self.push(item)}));else if(arguments.length>0)for(var i=0,l=arguments.length;i1)acc=initial;else{if(!this.head)throw new TypeError(\"Reduce of empty list with no initial value\");walker=this.head.next,acc=this.head.value}for(var i=0;null!==walker;i++)acc=fn(acc,walker.value,i),walker=walker.next;return acc},Yallist.prototype.reduceReverse=function(fn,initial){var acc,walker=this.tail;if(arguments.length>1)acc=initial;else{if(!this.tail)throw new TypeError(\"Reduce of empty list with no initial value\");walker=this.tail.prev,acc=this.tail.value}for(var i=this.length-1;null!==walker;i--)acc=fn(acc,walker.value,i),walker=walker.prev;return acc},Yallist.prototype.toArray=function(){for(var arr=new Array(this.length),i=0,walker=this.head;null!==walker;i++)arr[i]=walker.value,walker=walker.next;return arr},Yallist.prototype.toArrayReverse=function(){for(var arr=new Array(this.length),i=0,walker=this.tail;null!==walker;i++)arr[i]=walker.value,walker=walker.prev;return arr},Yallist.prototype.slice=function(from,to){(to=to||this.length)<0&&(to+=this.length),(from=from||0)<0&&(from+=this.length);var ret=new Yallist;if(tothis.length&&(to=this.length);for(var i=0,walker=this.head;null!==walker&&ithis.length&&(to=this.length);for(var i=this.length,walker=this.tail;null!==walker&&i>to;i--)walker=walker.prev;for(;null!==walker&&i>from;i--,walker=walker.prev)ret.push(walker.value);return ret},Yallist.prototype.splice=function(start,deleteCount,...nodes){start>this.length&&(start=this.length-1),start<0&&(start=this.length+start);for(var i=0,walker=this.head;null!==walker&&i{\"use strict\";module.exports=require(\"crypto\")},fs:module=>{\"use strict\";module.exports=require(\"fs\")},module:module=>{\"use strict\";module.exports=require(\"module\")},path:module=>{\"use strict\";module.exports=require(\"path\")},util:module=>{\"use strict\";module.exports=require(\"util\")}},__webpack_module_cache__={};function __webpack_require__(moduleId){var cachedModule=__webpack_module_cache__[moduleId];if(void 0!==cachedModule)return cachedModule.exports;var module=__webpack_module_cache__[moduleId]={id:moduleId,loaded:!1,exports:{}};return __webpack_modules__[moduleId](module,module.exports,__webpack_require__),module.loaded=!0,module.exports}__webpack_require__.n=module=>{var getter=module&&module.__esModule?()=>module.default:()=>module;return __webpack_require__.d(getter,{a:getter}),getter},__webpack_require__.d=(exports,definition)=>{for(var key in definition)__webpack_require__.o(definition,key)&&!__webpack_require__.o(exports,key)&&Object.defineProperty(exports,key,{enumerable:!0,get:definition[key]})},__webpack_require__.o=(obj,prop)=>Object.prototype.hasOwnProperty.call(obj,prop),__webpack_require__.nmd=module=>(module.paths=[],module.children||(module.children=[]),module);var __webpack_exports__={};(()=>{\"use strict\";__webpack_require__.d(__webpack_exports__,{default:()=>createJITI});var external_fs_=__webpack_require__(\"fs\"),external_module_=__webpack_require__(\"module\");const external_perf_hooks_namespaceObject=require(\"perf_hooks\"),external_os_namespaceObject=require(\"os\"),external_vm_namespaceObject=require(\"vm\");var external_vm_default=__webpack_require__.n(external_vm_namespaceObject);const external_url_namespaceObject=require(\"url\");function normalizeWindowsPath(input=\"\"){return input&&input.includes(\"\\\\\")?input.replace(/\\\\/g,\"/\"):input}const _UNC_REGEX=/^[\\\\/]{2}/,_IS_ABSOLUTE_RE=/^[\\\\/](?![\\\\/])|^[\\\\/]{2}(?!\\.)|^[a-zA-Z]:[\\\\/]/,_DRIVE_LETTER_RE=/^[a-zA-Z]:$/,join=function(...args){if(0===args.length)return\".\";let joined;for(let i=0;i0&&(void 0===joined?joined=arg:joined+=`/${arg}`)}return void 0===joined?\".\":function(path){if(0===path.length)return\".\";const isUNCPath=(path=normalizeWindowsPath(path)).match(_UNC_REGEX),isPathAbsolute=isAbsolute(path),trailingSeparator=\"/\"===path[path.length-1];return 0===(path=normalizeString(path,!isPathAbsolute)).length?isPathAbsolute?\"/\":trailingSeparator?\"./\":\".\":(trailingSeparator&&(path+=\"/\"),_DRIVE_LETTER_RE.test(path)&&(path+=\"/\"),isUNCPath?isPathAbsolute?`//${path}`:`//./${path}`:isPathAbsolute&&!isAbsolute(path)?`/${path}`:path)}(joined.replace(/\\/\\/+/g,\"/\"))};function normalizeString(path,allowAboveRoot){let res=\"\",lastSegmentLength=0,lastSlash=-1,dots=0,char=null;for(let i=0;i<=path.length;++i){if(i2){const lastSlashIndex=res.lastIndexOf(\"/\");-1===lastSlashIndex?(res=\"\",lastSegmentLength=0):(res=res.slice(0,lastSlashIndex),lastSegmentLength=res.length-1-res.lastIndexOf(\"/\")),lastSlash=i,dots=0;continue}if(0!==res.length){res=\"\",lastSegmentLength=0,lastSlash=i,dots=0;continue}}allowAboveRoot&&(res+=res.length>0?\"/..\":\"..\",lastSegmentLength=2)}else res.length>0?res+=`/${path.slice(lastSlash+1,i)}`:res=path.slice(lastSlash+1,i),lastSegmentLength=i-lastSlash-1;lastSlash=i,dots=0}else\".\"===char&&-1!==dots?++dots:dots=-1}return res}const isAbsolute=function(p){return _IS_ABSOLUTE_RE.test(p)},_EXTNAME_RE=/.(\\.[^/.]+)$/,pathe_f81973bb_extname=function(p){const match=_EXTNAME_RE.exec(normalizeWindowsPath(p));return match&&match[1]||\"\"},pathe_f81973bb_dirname=function(p){const segments=normalizeWindowsPath(p).replace(/\\/$/,\"\").split(\"/\").slice(0,-1);return 1===segments.length&&_DRIVE_LETTER_RE.test(segments[0])&&(segments[0]+=\"/\"),segments.join(\"/\")||(isAbsolute(p)?\"/\":\".\")},basename=function(p,ext){const lastSegment=normalizeWindowsPath(p).split(\"/\").pop();return ext&&lastSegment.endsWith(ext)?lastSegment.slice(0,-ext.length):lastSegment};var mkdirp=__webpack_require__(\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/index.js\");const suspectProtoRx=/\"(?:_|\\\\u005[Ff])(?:_|\\\\u005[Ff])(?:p|\\\\u0070)(?:r|\\\\u0072)(?:o|\\\\u006[Ff])(?:t|\\\\u0074)(?:o|\\\\u006[Ff])(?:_|\\\\u005[Ff])(?:_|\\\\u005[Ff])\"\\s*:/,suspectConstructorRx=/\"(?:c|\\\\u0063)(?:o|\\\\u006[Ff])(?:n|\\\\u006[Ee])(?:s|\\\\u0073)(?:t|\\\\u0074)(?:r|\\\\u0072)(?:u|\\\\u0075)(?:c|\\\\u0063)(?:t|\\\\u0074)(?:o|\\\\u006[Ff])(?:r|\\\\u0072)\"\\s*:/,JsonSigRx=/^[\"{[]|^-?[0-9][0-9.]{0,14}$/;function jsonParseTransform(key,value){if(\"__proto__\"!==key&&\"constructor\"!==key)return value}function destr(val){if(\"string\"!=typeof val)return val;const _lval=val.toLowerCase();if(\"true\"===_lval)return!0;if(\"false\"===_lval)return!1;if(\"null\"===_lval)return null;if(\"nan\"===_lval)return NaN;if(\"infinity\"===_lval)return 1/0;if(\"undefined\"!==_lval){if(!JsonSigRx.test(val))return val;try{return suspectProtoRx.test(val)||suspectConstructorRx.test(val)?JSON.parse(val,jsonParseTransform):JSON.parse(val)}catch(_e){return val}}}function escapeStringRegexp(string){if(\"string\"!=typeof string)throw new TypeError(\"Expected a string\");return string.replace(/[|\\\\{}()[\\]^$+*?.]/g,\"\\\\$&\").replace(/-/g,\"\\\\x2d\")}var create_require=__webpack_require__(\"./node_modules/.pnpm/create-require@1.1.1/node_modules/create-require/create-require.js\"),create_require_default=__webpack_require__.n(create_require),semver=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/index.js\");const pathSeparators=[\"/\",\"\\\\\",void 0],normalizedAliasSymbol=Symbol.for(\"pathe:normalizedAlias\");function normalizeAliases(_aliases){if(_aliases[normalizedAliasSymbol])return _aliases;const aliases=Object.fromEntries(Object.entries(_aliases).sort((([a],[b])=>function(a,b){return b.split(\"/\").length-a.split(\"/\").length}(a,b))));for(const key in aliases)for(const alias in aliases)alias===key||key.startsWith(alias)||aliases[key].startsWith(alias)&&pathSeparators.includes(aliases[key][alias.length])&&(aliases[key]=aliases[alias]+aliases[key].slice(alias.length));return Object.defineProperty(aliases,normalizedAliasSymbol,{value:!0,enumerable:!1}),aliases}var lib=__webpack_require__(\"./node_modules/.pnpm/pirates@4.0.5/node_modules/pirates/lib/index.js\"),object_hash=__webpack_require__(\"./node_modules/.pnpm/object-hash@3.0.0/node_modules/object-hash/index.js\"),object_hash_default=__webpack_require__.n(object_hash),astralIdentifierCodes=[509,0,227,0,150,4,294,9,1368,2,2,1,6,3,41,2,5,0,166,1,574,3,9,9,370,1,154,10,50,3,123,2,54,14,32,10,3,1,11,3,46,10,8,0,46,9,7,2,37,13,2,9,6,1,45,0,13,2,49,13,9,3,2,11,83,11,7,0,161,11,6,9,7,3,56,1,2,6,3,1,3,2,10,0,11,1,3,6,4,4,193,17,10,9,5,0,82,19,13,9,214,6,3,8,28,1,83,16,16,9,82,12,9,9,84,14,5,9,243,14,166,9,71,5,2,1,3,3,2,0,2,1,13,9,120,6,3,6,4,0,29,9,41,6,2,3,9,0,10,10,47,15,406,7,2,7,17,9,57,21,2,13,123,5,4,0,2,1,2,6,2,0,9,9,49,4,2,1,2,4,9,9,330,3,19306,9,87,9,39,4,60,6,26,9,1014,0,2,54,8,3,82,0,12,1,19628,1,4706,45,3,22,543,4,4,5,9,7,3,6,31,3,149,2,1418,49,513,54,5,49,9,0,15,0,23,4,2,14,1361,6,2,16,3,6,2,1,2,4,262,6,10,9,357,0,62,13,1495,6,110,6,6,9,4759,9,787719,239],astralIdentifierStartCodes=[0,11,2,25,2,18,2,1,2,14,3,13,35,122,70,52,268,28,4,48,48,31,14,29,6,37,11,29,3,35,5,7,2,4,43,157,19,35,5,35,5,39,9,51,13,10,2,14,2,6,2,1,2,10,2,14,2,6,2,1,68,310,10,21,11,7,25,5,2,41,2,8,70,5,3,0,2,43,2,1,4,0,3,22,11,22,10,30,66,18,2,1,11,21,11,25,71,55,7,1,65,0,16,3,2,2,2,28,43,28,4,28,36,7,2,27,28,53,11,21,11,18,14,17,111,72,56,50,14,50,14,35,349,41,7,1,79,28,11,0,9,21,43,17,47,20,28,22,13,52,58,1,3,0,14,44,33,24,27,35,30,0,3,0,9,34,4,0,13,47,15,3,22,0,2,0,36,17,2,24,85,6,2,0,2,3,2,14,2,9,8,46,39,7,3,1,3,21,2,6,2,1,2,4,4,0,19,0,13,4,159,52,19,3,21,2,31,47,21,1,2,0,185,46,42,3,37,47,21,0,60,42,14,0,72,26,38,6,186,43,117,63,32,7,3,0,3,7,2,1,2,23,16,0,2,0,95,7,3,38,17,0,2,0,29,0,11,39,8,0,22,0,12,45,20,0,19,72,264,8,2,36,18,0,50,29,113,6,2,1,2,37,22,0,26,5,2,1,2,31,15,0,328,18,190,0,80,921,103,110,18,195,2637,96,16,1070,4050,582,8634,568,8,30,18,78,18,29,19,47,17,3,32,20,6,18,689,63,129,74,6,0,67,12,65,1,2,0,29,6135,9,1237,43,8,8936,3,2,6,2,1,2,290,46,2,18,3,9,395,2309,106,6,12,4,8,8,9,5991,84,2,70,2,1,3,0,3,1,3,3,2,11,2,0,2,6,2,64,2,3,3,7,2,6,2,27,2,3,2,4,2,0,4,6,2,339,3,24,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,7,1845,30,482,44,11,6,17,0,322,29,19,43,1269,6,2,3,2,1,2,14,2,196,60,67,8,0,1205,3,2,26,2,1,2,0,3,0,2,9,2,3,2,0,2,0,7,0,5,0,2,0,2,0,2,2,2,1,2,0,3,0,2,0,2,0,2,0,2,0,2,1,2,0,3,3,2,6,2,3,2,3,2,0,2,9,2,16,6,2,2,4,2,16,4421,42719,33,4152,8,221,3,5761,15,7472,3104,541,1507,4938],nonASCIIidentifierStartChars=\"\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u05D0-\u05EA\u05EF-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u0870-\u0887\u0889-\u088E\u08A0-\u08C9\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D04-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u1711\u171F-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1878\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4C\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1C90-\u1CBA\u1CBD-\u1CBF\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5\u1CF6\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309B-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u31A0-\u31BF\u31F0-\u31FF\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7CA\uA7D0\uA7D1\uA7D3\uA7D5-\uA7D9\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA8FE\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB69\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC\",reservedWords={3:\"abstract boolean byte char class double enum export extends final float goto implements import int interface long native package private protected public short static super synchronized throws transient volatile\",5:\"class enum extends super const export import\",6:\"enum\",strict:\"implements interface let package private protected public static yield\",strictBind:\"eval arguments\"},ecma5AndLessKeywords=\"break case catch continue debugger default do else finally for function if return switch throw try var while with null true false instanceof typeof void delete new in this\",keywords$1={5:ecma5AndLessKeywords,\"5module\":ecma5AndLessKeywords+\" export import\",6:ecma5AndLessKeywords+\" const class extends export import super\"},keywordRelationalOperator=/^in(stanceof)?$/,nonASCIIidentifierStart=new RegExp(\"[\"+nonASCIIidentifierStartChars+\"]\"),nonASCIIidentifier=new RegExp(\"[\"+nonASCIIidentifierStartChars+\"\u200C\u200D\u00B7\u0300-\u036F\u0387\u0483-\u0487\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u0669\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u06F0-\u06F9\u0711\u0730-\u074A\u07A6-\u07B0\u07C0-\u07C9\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0898-\u089F\u08CA-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0966-\u096F\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u09E6-\u09EF\u09FE\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A66-\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0AE6-\u0AEF\u0AFA-\u0AFF\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B66-\u0B6F\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0BE6-\u0BEF\u0C00-\u0C04\u0C3C\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C66-\u0C6F\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0CE6-\u0CEF\u0D00-\u0D03\u0D3B\u0D3C\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D66-\u0D6F\u0D81-\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0E50-\u0E59\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECD\u0ED0-\u0ED9\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1040-\u1049\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F-\u109D\u135D-\u135F\u1369-\u1371\u1712-\u1715\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u17E0-\u17E9\u180B-\u180D\u180F-\u1819\u18A9\u1920-\u192B\u1930-\u193B\u1946-\u194F\u19D0-\u19DA\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AB0-\u1ABD\u1ABF-\u1ACE\u1B00-\u1B04\u1B34-\u1B44\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BB0-\u1BB9\u1BE6-\u1BF3\u1C24-\u1C37\u1C40-\u1C49\u1C50-\u1C59\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF4\u1CF7-\u1CF9\u1DC0-\u1DFF\u203F\u2040\u2054\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA620-\uA629\uA66F\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA82C\uA880\uA881\uA8B4-\uA8C5\uA8D0-\uA8D9\uA8E0-\uA8F1\uA8FF-\uA909\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9D0-\uA9D9\uA9E5\uA9F0-\uA9F9\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA50-\uAA59\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uABF0-\uABF9\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFF10-\uFF19\uFF3F]\");function isInAstralSet(code,set){for(var pos=65536,i=0;icode)return!1;if((pos+=set[i+1])>=code)return!0}}function isIdentifierStart(code,astral){return code<65?36===code:code<91||(code<97?95===code:code<123||(code<=65535?code>=170&&nonASCIIidentifierStart.test(String.fromCharCode(code)):!1!==astral&&isInAstralSet(code,astralIdentifierStartCodes)))}function isIdentifierChar(code,astral){return code<48?36===code:code<58||!(code<65)&&(code<91||(code<97?95===code:code<123||(code<=65535?code>=170&&nonASCIIidentifier.test(String.fromCharCode(code)):!1!==astral&&(isInAstralSet(code,astralIdentifierStartCodes)||isInAstralSet(code,astralIdentifierCodes)))))}var TokenType=function(label,conf){void 0===conf&&(conf={}),this.label=label,this.keyword=conf.keyword,this.beforeExpr=!!conf.beforeExpr,this.startsExpr=!!conf.startsExpr,this.isLoop=!!conf.isLoop,this.isAssign=!!conf.isAssign,this.prefix=!!conf.prefix,this.postfix=!!conf.postfix,this.binop=conf.binop||null,this.updateContext=null};function binop(name,prec){return new TokenType(name,{beforeExpr:!0,binop:prec})}var beforeExpr={beforeExpr:!0},startsExpr={startsExpr:!0},keywords={};function kw(name,options){return void 0===options&&(options={}),options.keyword=name,keywords[name]=new TokenType(name,options)}var types$1={num:new TokenType(\"num\",startsExpr),regexp:new TokenType(\"regexp\",startsExpr),string:new TokenType(\"string\",startsExpr),name:new TokenType(\"name\",startsExpr),privateId:new TokenType(\"privateId\",startsExpr),eof:new TokenType(\"eof\"),bracketL:new TokenType(\"[\",{beforeExpr:!0,startsExpr:!0}),bracketR:new TokenType(\"]\"),braceL:new TokenType(\"{\",{beforeExpr:!0,startsExpr:!0}),braceR:new TokenType(\"}\"),parenL:new TokenType(\"(\",{beforeExpr:!0,startsExpr:!0}),parenR:new TokenType(\")\"),comma:new TokenType(\",\",beforeExpr),semi:new TokenType(\";\",beforeExpr),colon:new TokenType(\":\",beforeExpr),dot:new TokenType(\".\"),question:new TokenType(\"?\",beforeExpr),questionDot:new TokenType(\"?.\"),arrow:new TokenType(\"=>\",beforeExpr),template:new TokenType(\"template\"),invalidTemplate:new TokenType(\"invalidTemplate\"),ellipsis:new TokenType(\"...\",beforeExpr),backQuote:new TokenType(\"`\",startsExpr),dollarBraceL:new TokenType(\"${\",{beforeExpr:!0,startsExpr:!0}),eq:new TokenType(\"=\",{beforeExpr:!0,isAssign:!0}),assign:new TokenType(\"_=\",{beforeExpr:!0,isAssign:!0}),incDec:new TokenType(\"++/--\",{prefix:!0,postfix:!0,startsExpr:!0}),prefix:new TokenType(\"!/~\",{beforeExpr:!0,prefix:!0,startsExpr:!0}),logicalOR:binop(\"||\",1),logicalAND:binop(\"&&\",2),bitwiseOR:binop(\"|\",3),bitwiseXOR:binop(\"^\",4),bitwiseAND:binop(\"&\",5),equality:binop(\"==/!=/===/!==\",6),relational:binop(\"/<=/>=\",7),bitShift:binop(\"<>/>>>\",8),plusMin:new TokenType(\"+/-\",{beforeExpr:!0,binop:9,prefix:!0,startsExpr:!0}),modulo:binop(\"%\",10),star:binop(\"*\",10),slash:binop(\"/\",10),starstar:new TokenType(\"**\",{beforeExpr:!0}),coalesce:binop(\"??\",1),_break:kw(\"break\"),_case:kw(\"case\",beforeExpr),_catch:kw(\"catch\"),_continue:kw(\"continue\"),_debugger:kw(\"debugger\"),_default:kw(\"default\",beforeExpr),_do:kw(\"do\",{isLoop:!0,beforeExpr:!0}),_else:kw(\"else\",beforeExpr),_finally:kw(\"finally\"),_for:kw(\"for\",{isLoop:!0}),_function:kw(\"function\",startsExpr),_if:kw(\"if\"),_return:kw(\"return\",beforeExpr),_switch:kw(\"switch\"),_throw:kw(\"throw\",beforeExpr),_try:kw(\"try\"),_var:kw(\"var\"),_const:kw(\"const\"),_while:kw(\"while\",{isLoop:!0}),_with:kw(\"with\"),_new:kw(\"new\",{beforeExpr:!0,startsExpr:!0}),_this:kw(\"this\",startsExpr),_super:kw(\"super\",startsExpr),_class:kw(\"class\",startsExpr),_extends:kw(\"extends\",beforeExpr),_export:kw(\"export\"),_import:kw(\"import\",startsExpr),_null:kw(\"null\",startsExpr),_true:kw(\"true\",startsExpr),_false:kw(\"false\",startsExpr),_in:kw(\"in\",{beforeExpr:!0,binop:7}),_instanceof:kw(\"instanceof\",{beforeExpr:!0,binop:7}),_typeof:kw(\"typeof\",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_void:kw(\"void\",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_delete:kw(\"delete\",{beforeExpr:!0,prefix:!0,startsExpr:!0})},lineBreak=/\\r\\n?|\\n|\\u2028|\\u2029/,lineBreakG=new RegExp(lineBreak.source,\"g\");function isNewLine(code){return 10===code||13===code||8232===code||8233===code}function nextLineBreak(code,from,end){void 0===end&&(end=code.length);for(var i=from;i>10),56320+(1023&code)))}var loneSurrogate=/(?:[\\uD800-\\uDBFF](?![\\uDC00-\\uDFFF])|(?:[^\\uD800-\\uDBFF]|^)[\\uDC00-\\uDFFF])/,Position=function(line,col){this.line=line,this.column=col};Position.prototype.offset=function(n){return new Position(this.line,this.column+n)};var SourceLocation=function(p,start,end){this.start=start,this.end=end,null!==p.sourceFile&&(this.source=p.sourceFile)};function getLineInfo(input,offset){for(var line=1,cur=0;;){var nextBreak=nextLineBreak(input,cur,offset);if(nextBreak<0)return new Position(line,offset-cur);++line,cur=nextBreak}}var defaultOptions={ecmaVersion:null,sourceType:\"script\",onInsertedSemicolon:null,onTrailingComma:null,allowReserved:null,allowReturnOutsideFunction:!1,allowImportExportEverywhere:!1,allowAwaitOutsideFunction:null,allowSuperOutsideMethod:null,allowHashBang:!1,locations:!1,onToken:null,onComment:null,ranges:!1,program:null,sourceFile:null,directSourceFile:null,preserveParens:!1},warnedAboutEcmaVersion=!1;function getOptions(opts){var options={};for(var opt in defaultOptions)options[opt]=opts&&hasOwn(opts,opt)?opts[opt]:defaultOptions[opt];if(\"latest\"===options.ecmaVersion?options.ecmaVersion=1e8:null==options.ecmaVersion?(!warnedAboutEcmaVersion&&\"object\"==typeof console&&console.warn&&(warnedAboutEcmaVersion=!0,console.warn(\"Since Acorn 8.0.0, options.ecmaVersion is required.\\nDefaulting to 2020, but this will stop working in the future.\")),options.ecmaVersion=11):options.ecmaVersion>=2015&&(options.ecmaVersion-=2009),null==options.allowReserved&&(options.allowReserved=options.ecmaVersion<5),null==opts.allowHashBang&&(options.allowHashBang=options.ecmaVersion>=14),isArray(options.onToken)){var tokens=options.onToken;options.onToken=function(token){return tokens.push(token)}}return isArray(options.onComment)&&(options.onComment=function(options,array){return function(block,text,start,end,startLoc,endLoc){var comment={type:block?\"Block\":\"Line\",value:text,start,end};options.locations&&(comment.loc=new SourceLocation(this,startLoc,endLoc)),options.ranges&&(comment.range=[start,end]),array.push(comment)}}(options,options.onComment)),options}function functionFlags(async,generator){return 2|(async?4:0)|(generator?8:0)}var Parser=function(options,input,startPos){this.options=options=getOptions(options),this.sourceFile=options.sourceFile,this.keywords=wordsRegexp(keywords$1[options.ecmaVersion>=6?6:\"module\"===options.sourceType?\"5module\":5]);var reserved=\"\";!0!==options.allowReserved&&(reserved=reservedWords[options.ecmaVersion>=6?6:5===options.ecmaVersion?5:3],\"module\"===options.sourceType&&(reserved+=\" await\")),this.reservedWords=wordsRegexp(reserved);var reservedStrict=(reserved?reserved+\" \":\"\")+reservedWords.strict;this.reservedWordsStrict=wordsRegexp(reservedStrict),this.reservedWordsStrictBind=wordsRegexp(reservedStrict+\" \"+reservedWords.strictBind),this.input=String(input),this.containsEsc=!1,startPos?(this.pos=startPos,this.lineStart=this.input.lastIndexOf(\"\\n\",startPos-1)+1,this.curLine=this.input.slice(0,this.lineStart).split(lineBreak).length):(this.pos=this.lineStart=0,this.curLine=1),this.type=types$1.eof,this.value=null,this.start=this.end=this.pos,this.startLoc=this.endLoc=this.curPosition(),this.lastTokEndLoc=this.lastTokStartLoc=null,this.lastTokStart=this.lastTokEnd=this.pos,this.context=this.initialContext(),this.exprAllowed=!0,this.inModule=\"module\"===options.sourceType,this.strict=this.inModule||this.strictDirective(this.pos),this.potentialArrowAt=-1,this.potentialArrowInForAwait=!1,this.yieldPos=this.awaitPos=this.awaitIdentPos=0,this.labels=[],this.undefinedExports=Object.create(null),0===this.pos&&options.allowHashBang&&\"#!\"===this.input.slice(0,2)&&this.skipLineComment(2),this.scopeStack=[],this.enterScope(1),this.regexpState=null,this.privateNameStack=[]},prototypeAccessors={inFunction:{configurable:!0},inGenerator:{configurable:!0},inAsync:{configurable:!0},canAwait:{configurable:!0},allowSuper:{configurable:!0},allowDirectSuper:{configurable:!0},treatFunctionsAsVar:{configurable:!0},allowNewDotTarget:{configurable:!0},inClassStaticBlock:{configurable:!0}};Parser.prototype.parse=function(){var node=this.options.program||this.startNode();return this.nextToken(),this.parseTopLevel(node)},prototypeAccessors.inFunction.get=function(){return(2&this.currentVarScope().flags)>0},prototypeAccessors.inGenerator.get=function(){return(8&this.currentVarScope().flags)>0&&!this.currentVarScope().inClassFieldInit},prototypeAccessors.inAsync.get=function(){return(4&this.currentVarScope().flags)>0&&!this.currentVarScope().inClassFieldInit},prototypeAccessors.canAwait.get=function(){for(var i=this.scopeStack.length-1;i>=0;i--){var scope=this.scopeStack[i];if(scope.inClassFieldInit||256&scope.flags)return!1;if(2&scope.flags)return(4&scope.flags)>0}return this.inModule&&this.options.ecmaVersion>=13||this.options.allowAwaitOutsideFunction},prototypeAccessors.allowSuper.get=function(){var ref=this.currentThisScope(),flags=ref.flags,inClassFieldInit=ref.inClassFieldInit;return(64&flags)>0||inClassFieldInit||this.options.allowSuperOutsideMethod},prototypeAccessors.allowDirectSuper.get=function(){return(128&this.currentThisScope().flags)>0},prototypeAccessors.treatFunctionsAsVar.get=function(){return this.treatFunctionsAsVarInScope(this.currentScope())},prototypeAccessors.allowNewDotTarget.get=function(){var ref=this.currentThisScope(),flags=ref.flags,inClassFieldInit=ref.inClassFieldInit;return(258&flags)>0||inClassFieldInit},prototypeAccessors.inClassStaticBlock.get=function(){return(256&this.currentVarScope().flags)>0},Parser.extend=function(){for(var plugins=[],len=arguments.length;len--;)plugins[len]=arguments[len];for(var cls=this,i=0;i=,?^&]/.test(next)||\"!\"===next&&\"=\"===this.input.charAt(end+1))}start+=match[0].length,skipWhiteSpace.lastIndex=start,start+=skipWhiteSpace.exec(this.input)[0].length,\";\"===this.input[start]&&start++}},pp$9.eat=function(type){return this.type===type&&(this.next(),!0)},pp$9.isContextual=function(name){return this.type===types$1.name&&this.value===name&&!this.containsEsc},pp$9.eatContextual=function(name){return!!this.isContextual(name)&&(this.next(),!0)},pp$9.expectContextual=function(name){this.eatContextual(name)||this.unexpected()},pp$9.canInsertSemicolon=function(){return this.type===types$1.eof||this.type===types$1.braceR||lineBreak.test(this.input.slice(this.lastTokEnd,this.start))},pp$9.insertSemicolon=function(){if(this.canInsertSemicolon())return this.options.onInsertedSemicolon&&this.options.onInsertedSemicolon(this.lastTokEnd,this.lastTokEndLoc),!0},pp$9.semicolon=function(){this.eat(types$1.semi)||this.insertSemicolon()||this.unexpected()},pp$9.afterTrailingComma=function(tokType,notNext){if(this.type===tokType)return this.options.onTrailingComma&&this.options.onTrailingComma(this.lastTokStart,this.lastTokStartLoc),notNext||this.next(),!0},pp$9.expect=function(type){this.eat(type)||this.unexpected()},pp$9.unexpected=function(pos){this.raise(null!=pos?pos:this.start,\"Unexpected token\")};var DestructuringErrors=function(){this.shorthandAssign=this.trailingComma=this.parenthesizedAssign=this.parenthesizedBind=this.doubleProto=-1};pp$9.checkPatternErrors=function(refDestructuringErrors,isAssign){if(refDestructuringErrors){refDestructuringErrors.trailingComma>-1&&this.raiseRecoverable(refDestructuringErrors.trailingComma,\"Comma is not permitted after the rest element\");var parens=isAssign?refDestructuringErrors.parenthesizedAssign:refDestructuringErrors.parenthesizedBind;parens>-1&&this.raiseRecoverable(parens,isAssign?\"Assigning to rvalue\":\"Parenthesized pattern\")}},pp$9.checkExpressionErrors=function(refDestructuringErrors,andThrow){if(!refDestructuringErrors)return!1;var shorthandAssign=refDestructuringErrors.shorthandAssign,doubleProto=refDestructuringErrors.doubleProto;if(!andThrow)return shorthandAssign>=0||doubleProto>=0;shorthandAssign>=0&&this.raise(shorthandAssign,\"Shorthand property assignments are valid only in destructuring patterns\"),doubleProto>=0&&this.raiseRecoverable(doubleProto,\"Redefinition of __proto__ property\")},pp$9.checkYieldAwaitInDefaultParams=function(){this.yieldPos&&(!this.awaitPos||this.yieldPos55295&&nextCh<56320)return!0;if(context)return!1;if(123===nextCh)return!0;if(isIdentifierStart(nextCh,!0)){for(var pos=next+1;isIdentifierChar(nextCh=this.input.charCodeAt(pos),!0);)++pos;if(92===nextCh||nextCh>55295&&nextCh<56320)return!0;var ident=this.input.slice(next,pos);if(!keywordRelationalOperator.test(ident))return!0}return!1},pp$8.isAsyncFunction=function(){if(this.options.ecmaVersion<8||!this.isContextual(\"async\"))return!1;skipWhiteSpace.lastIndex=this.pos;var after,skip=skipWhiteSpace.exec(this.input),next=this.pos+skip[0].length;return!(lineBreak.test(this.input.slice(this.pos,next))||\"function\"!==this.input.slice(next,next+8)||next+8!==this.input.length&&(isIdentifierChar(after=this.input.charCodeAt(next+8))||after>55295&&after<56320))},pp$8.parseStatement=function(context,topLevel,exports){var kind,starttype=this.type,node=this.startNode();switch(this.isLet(context)&&(starttype=types$1._var,kind=\"let\"),starttype){case types$1._break:case types$1._continue:return this.parseBreakContinueStatement(node,starttype.keyword);case types$1._debugger:return this.parseDebuggerStatement(node);case types$1._do:return this.parseDoStatement(node);case types$1._for:return this.parseForStatement(node);case types$1._function:return context&&(this.strict||\"if\"!==context&&\"label\"!==context)&&this.options.ecmaVersion>=6&&this.unexpected(),this.parseFunctionStatement(node,!1,!context);case types$1._class:return context&&this.unexpected(),this.parseClass(node,!0);case types$1._if:return this.parseIfStatement(node);case types$1._return:return this.parseReturnStatement(node);case types$1._switch:return this.parseSwitchStatement(node);case types$1._throw:return this.parseThrowStatement(node);case types$1._try:return this.parseTryStatement(node);case types$1._const:case types$1._var:return kind=kind||this.value,context&&\"var\"!==kind&&this.unexpected(),this.parseVarStatement(node,kind);case types$1._while:return this.parseWhileStatement(node);case types$1._with:return this.parseWithStatement(node);case types$1.braceL:return this.parseBlock(!0,node);case types$1.semi:return this.parseEmptyStatement(node);case types$1._export:case types$1._import:if(this.options.ecmaVersion>10&&starttype===types$1._import){skipWhiteSpace.lastIndex=this.pos;var skip=skipWhiteSpace.exec(this.input),next=this.pos+skip[0].length,nextCh=this.input.charCodeAt(next);if(40===nextCh||46===nextCh)return this.parseExpressionStatement(node,this.parseExpression())}return this.options.allowImportExportEverywhere||(topLevel||this.raise(this.start,\"'import' and 'export' may only appear at the top level\"),this.inModule||this.raise(this.start,\"'import' and 'export' may appear only with 'sourceType: module'\")),starttype===types$1._import?this.parseImport(node):this.parseExport(node,exports);default:if(this.isAsyncFunction())return context&&this.unexpected(),this.next(),this.parseFunctionStatement(node,!0,!context);var maybeName=this.value,expr=this.parseExpression();return starttype===types$1.name&&\"Identifier\"===expr.type&&this.eat(types$1.colon)?this.parseLabeledStatement(node,maybeName,expr,context):this.parseExpressionStatement(node,expr)}},pp$8.parseBreakContinueStatement=function(node,keyword){var isBreak=\"break\"===keyword;this.next(),this.eat(types$1.semi)||this.insertSemicolon()?node.label=null:this.type!==types$1.name?this.unexpected():(node.label=this.parseIdent(),this.semicolon());for(var i=0;i=6?this.eat(types$1.semi):this.semicolon(),this.finishNode(node,\"DoWhileStatement\")},pp$8.parseForStatement=function(node){this.next();var awaitAt=this.options.ecmaVersion>=9&&this.canAwait&&this.eatContextual(\"await\")?this.lastTokStart:-1;if(this.labels.push(loopLabel),this.enterScope(0),this.expect(types$1.parenL),this.type===types$1.semi)return awaitAt>-1&&this.unexpected(awaitAt),this.parseFor(node,null);var isLet=this.isLet();if(this.type===types$1._var||this.type===types$1._const||isLet){var init$1=this.startNode(),kind=isLet?\"let\":this.value;return this.next(),this.parseVar(init$1,!0,kind),this.finishNode(init$1,\"VariableDeclaration\"),(this.type===types$1._in||this.options.ecmaVersion>=6&&this.isContextual(\"of\"))&&1===init$1.declarations.length?(this.options.ecmaVersion>=9&&(this.type===types$1._in?awaitAt>-1&&this.unexpected(awaitAt):node.await=awaitAt>-1),this.parseForIn(node,init$1)):(awaitAt>-1&&this.unexpected(awaitAt),this.parseFor(node,init$1))}var startsWithLet=this.isContextual(\"let\"),isForOf=!1,refDestructuringErrors=new DestructuringErrors,init=this.parseExpression(!(awaitAt>-1)||\"await\",refDestructuringErrors);return this.type===types$1._in||(isForOf=this.options.ecmaVersion>=6&&this.isContextual(\"of\"))?(this.options.ecmaVersion>=9&&(this.type===types$1._in?awaitAt>-1&&this.unexpected(awaitAt):node.await=awaitAt>-1),startsWithLet&&isForOf&&this.raise(init.start,\"The left-hand side of a for-of loop may not start with 'let'.\"),this.toAssignable(init,!1,refDestructuringErrors),this.checkLValPattern(init),this.parseForIn(node,init)):(this.checkExpressionErrors(refDestructuringErrors,!0),awaitAt>-1&&this.unexpected(awaitAt),this.parseFor(node,init))},pp$8.parseFunctionStatement=function(node,isAsync,declarationPosition){return this.next(),this.parseFunction(node,FUNC_STATEMENT|(declarationPosition?0:FUNC_HANGING_STATEMENT),!1,isAsync)},pp$8.parseIfStatement=function(node){return this.next(),node.test=this.parseParenExpression(),node.consequent=this.parseStatement(\"if\"),node.alternate=this.eat(types$1._else)?this.parseStatement(\"if\"):null,this.finishNode(node,\"IfStatement\")},pp$8.parseReturnStatement=function(node){return this.inFunction||this.options.allowReturnOutsideFunction||this.raise(this.start,\"'return' outside of function\"),this.next(),this.eat(types$1.semi)||this.insertSemicolon()?node.argument=null:(node.argument=this.parseExpression(),this.semicolon()),this.finishNode(node,\"ReturnStatement\")},pp$8.parseSwitchStatement=function(node){var cur;this.next(),node.discriminant=this.parseParenExpression(),node.cases=[],this.expect(types$1.braceL),this.labels.push(switchLabel),this.enterScope(0);for(var sawDefault=!1;this.type!==types$1.braceR;)if(this.type===types$1._case||this.type===types$1._default){var isCase=this.type===types$1._case;cur&&this.finishNode(cur,\"SwitchCase\"),node.cases.push(cur=this.startNode()),cur.consequent=[],this.next(),isCase?cur.test=this.parseExpression():(sawDefault&&this.raiseRecoverable(this.lastTokStart,\"Multiple default clauses\"),sawDefault=!0,cur.test=null),this.expect(types$1.colon)}else cur||this.unexpected(),cur.consequent.push(this.parseStatement(null));return this.exitScope(),cur&&this.finishNode(cur,\"SwitchCase\"),this.next(),this.labels.pop(),this.finishNode(node,\"SwitchStatement\")},pp$8.parseThrowStatement=function(node){return this.next(),lineBreak.test(this.input.slice(this.lastTokEnd,this.start))&&this.raise(this.lastTokEnd,\"Illegal newline after throw\"),node.argument=this.parseExpression(),this.semicolon(),this.finishNode(node,\"ThrowStatement\")};var empty$1=[];pp$8.parseTryStatement=function(node){if(this.next(),node.block=this.parseBlock(),node.handler=null,this.type===types$1._catch){var clause=this.startNode();if(this.next(),this.eat(types$1.parenL)){clause.param=this.parseBindingAtom();var simple=\"Identifier\"===clause.param.type;this.enterScope(simple?32:0),this.checkLValPattern(clause.param,simple?4:2),this.expect(types$1.parenR)}else this.options.ecmaVersion<10&&this.unexpected(),clause.param=null,this.enterScope(0);clause.body=this.parseBlock(!1),this.exitScope(),node.handler=this.finishNode(clause,\"CatchClause\")}return node.finalizer=this.eat(types$1._finally)?this.parseBlock():null,node.handler||node.finalizer||this.raise(node.start,\"Missing catch or finally clause\"),this.finishNode(node,\"TryStatement\")},pp$8.parseVarStatement=function(node,kind){return this.next(),this.parseVar(node,!1,kind),this.semicolon(),this.finishNode(node,\"VariableDeclaration\")},pp$8.parseWhileStatement=function(node){return this.next(),node.test=this.parseParenExpression(),this.labels.push(loopLabel),node.body=this.parseStatement(\"while\"),this.labels.pop(),this.finishNode(node,\"WhileStatement\")},pp$8.parseWithStatement=function(node){return this.strict&&this.raise(this.start,\"'with' in strict mode\"),this.next(),node.object=this.parseParenExpression(),node.body=this.parseStatement(\"with\"),this.finishNode(node,\"WithStatement\")},pp$8.parseEmptyStatement=function(node){return this.next(),this.finishNode(node,\"EmptyStatement\")},pp$8.parseLabeledStatement=function(node,maybeName,expr,context){for(var i$1=0,list=this.labels;i$1=0;i--){var label$1=this.labels[i];if(label$1.statementStart!==node.start)break;label$1.statementStart=this.start,label$1.kind=kind}return this.labels.push({name:maybeName,kind,statementStart:this.start}),node.body=this.parseStatement(context?-1===context.indexOf(\"label\")?context+\"label\":context:\"label\"),this.labels.pop(),node.label=expr,this.finishNode(node,\"LabeledStatement\")},pp$8.parseExpressionStatement=function(node,expr){return node.expression=expr,this.semicolon(),this.finishNode(node,\"ExpressionStatement\")},pp$8.parseBlock=function(createNewLexicalScope,node,exitStrict){for(void 0===createNewLexicalScope&&(createNewLexicalScope=!0),void 0===node&&(node=this.startNode()),node.body=[],this.expect(types$1.braceL),createNewLexicalScope&&this.enterScope(0);this.type!==types$1.braceR;){var stmt=this.parseStatement(null);node.body.push(stmt)}return exitStrict&&(this.strict=!1),this.next(),createNewLexicalScope&&this.exitScope(),this.finishNode(node,\"BlockStatement\")},pp$8.parseFor=function(node,init){return node.init=init,this.expect(types$1.semi),node.test=this.type===types$1.semi?null:this.parseExpression(),this.expect(types$1.semi),node.update=this.type===types$1.parenR?null:this.parseExpression(),this.expect(types$1.parenR),node.body=this.parseStatement(\"for\"),this.exitScope(),this.labels.pop(),this.finishNode(node,\"ForStatement\")},pp$8.parseForIn=function(node,init){var isForIn=this.type===types$1._in;return this.next(),\"VariableDeclaration\"===init.type&&null!=init.declarations[0].init&&(!isForIn||this.options.ecmaVersion<8||this.strict||\"var\"!==init.kind||\"Identifier\"!==init.declarations[0].id.type)&&this.raise(init.start,(isForIn?\"for-in\":\"for-of\")+\" loop variable declaration may not have an initializer\"),node.left=init,node.right=isForIn?this.parseExpression():this.parseMaybeAssign(),this.expect(types$1.parenR),node.body=this.parseStatement(\"for\"),this.exitScope(),this.labels.pop(),this.finishNode(node,isForIn?\"ForInStatement\":\"ForOfStatement\")},pp$8.parseVar=function(node,isFor,kind){for(node.declarations=[],node.kind=kind;;){var decl=this.startNode();if(this.parseVarId(decl,kind),this.eat(types$1.eq)?decl.init=this.parseMaybeAssign(isFor):\"const\"!==kind||this.type===types$1._in||this.options.ecmaVersion>=6&&this.isContextual(\"of\")?\"Identifier\"===decl.id.type||isFor&&(this.type===types$1._in||this.isContextual(\"of\"))?decl.init=null:this.raise(this.lastTokEnd,\"Complex binding patterns require an initialization value\"):this.unexpected(),node.declarations.push(this.finishNode(decl,\"VariableDeclarator\")),!this.eat(types$1.comma))break}return node},pp$8.parseVarId=function(decl,kind){decl.id=this.parseBindingAtom(),this.checkLValPattern(decl.id,\"var\"===kind?1:2,!1)};var FUNC_STATEMENT=1,FUNC_HANGING_STATEMENT=2;function isPrivateNameConflicted(privateNameMap,element){var name=element.key.name,curr=privateNameMap[name],next=\"true\";return\"MethodDefinition\"!==element.type||\"get\"!==element.kind&&\"set\"!==element.kind||(next=(element.static?\"s\":\"i\")+element.kind),\"iget\"===curr&&\"iset\"===next||\"iset\"===curr&&\"iget\"===next||\"sget\"===curr&&\"sset\"===next||\"sset\"===curr&&\"sget\"===next?(privateNameMap[name]=\"true\",!1):!!curr||(privateNameMap[name]=next,!1)}function checkKeyName(node,name){var computed=node.computed,key=node.key;return!computed&&(\"Identifier\"===key.type&&key.name===name||\"Literal\"===key.type&&key.value===name)}pp$8.parseFunction=function(node,statement,allowExpressionBody,isAsync,forInit){this.initFunction(node),(this.options.ecmaVersion>=9||this.options.ecmaVersion>=6&&!isAsync)&&(this.type===types$1.star&&statement&FUNC_HANGING_STATEMENT&&this.unexpected(),node.generator=this.eat(types$1.star)),this.options.ecmaVersion>=8&&(node.async=!!isAsync),statement&FUNC_STATEMENT&&(node.id=4&statement&&this.type!==types$1.name?null:this.parseIdent(),!node.id||statement&FUNC_HANGING_STATEMENT||this.checkLValSimple(node.id,this.strict||node.generator||node.async?this.treatFunctionsAsVar?1:2:3));var oldYieldPos=this.yieldPos,oldAwaitPos=this.awaitPos,oldAwaitIdentPos=this.awaitIdentPos;return this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(functionFlags(node.async,node.generator)),statement&FUNC_STATEMENT||(node.id=this.type===types$1.name?this.parseIdent():null),this.parseFunctionParams(node),this.parseFunctionBody(node,allowExpressionBody,!1,forInit),this.yieldPos=oldYieldPos,this.awaitPos=oldAwaitPos,this.awaitIdentPos=oldAwaitIdentPos,this.finishNode(node,statement&FUNC_STATEMENT?\"FunctionDeclaration\":\"FunctionExpression\")},pp$8.parseFunctionParams=function(node){this.expect(types$1.parenL),node.params=this.parseBindingList(types$1.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams()},pp$8.parseClass=function(node,isStatement){this.next();var oldStrict=this.strict;this.strict=!0,this.parseClassId(node,isStatement),this.parseClassSuper(node);var privateNameMap=this.enterClassBody(),classBody=this.startNode(),hadConstructor=!1;for(classBody.body=[],this.expect(types$1.braceL);this.type!==types$1.braceR;){var element=this.parseClassElement(null!==node.superClass);element&&(classBody.body.push(element),\"MethodDefinition\"===element.type&&\"constructor\"===element.kind?(hadConstructor&&this.raise(element.start,\"Duplicate constructor in the same class\"),hadConstructor=!0):element.key&&\"PrivateIdentifier\"===element.key.type&&isPrivateNameConflicted(privateNameMap,element)&&this.raiseRecoverable(element.key.start,\"Identifier '#\"+element.key.name+\"' has already been declared\"))}return this.strict=oldStrict,this.next(),node.body=this.finishNode(classBody,\"ClassBody\"),this.exitClassBody(),this.finishNode(node,isStatement?\"ClassDeclaration\":\"ClassExpression\")},pp$8.parseClassElement=function(constructorAllowsSuper){if(this.eat(types$1.semi))return null;var ecmaVersion=this.options.ecmaVersion,node=this.startNode(),keyName=\"\",isGenerator=!1,isAsync=!1,kind=\"method\",isStatic=!1;if(this.eatContextual(\"static\")){if(ecmaVersion>=13&&this.eat(types$1.braceL))return this.parseClassStaticBlock(node),node;this.isClassElementNameStart()||this.type===types$1.star?isStatic=!0:keyName=\"static\"}if(node.static=isStatic,!keyName&&ecmaVersion>=8&&this.eatContextual(\"async\")&&(!this.isClassElementNameStart()&&this.type!==types$1.star||this.canInsertSemicolon()?keyName=\"async\":isAsync=!0),!keyName&&(ecmaVersion>=9||!isAsync)&&this.eat(types$1.star)&&(isGenerator=!0),!keyName&&!isAsync&&!isGenerator){var lastValue=this.value;(this.eatContextual(\"get\")||this.eatContextual(\"set\"))&&(this.isClassElementNameStart()?kind=lastValue:keyName=lastValue)}if(keyName?(node.computed=!1,node.key=this.startNodeAt(this.lastTokStart,this.lastTokStartLoc),node.key.name=keyName,this.finishNode(node.key,\"Identifier\")):this.parseClassElementName(node),ecmaVersion<13||this.type===types$1.parenL||\"method\"!==kind||isGenerator||isAsync){var isConstructor=!node.static&&checkKeyName(node,\"constructor\"),allowsDirectSuper=isConstructor&&constructorAllowsSuper;isConstructor&&\"method\"!==kind&&this.raise(node.key.start,\"Constructor can't have get/set modifier\"),node.kind=isConstructor?\"constructor\":kind,this.parseClassMethod(node,isGenerator,isAsync,allowsDirectSuper)}else this.parseClassField(node);return node},pp$8.isClassElementNameStart=function(){return this.type===types$1.name||this.type===types$1.privateId||this.type===types$1.num||this.type===types$1.string||this.type===types$1.bracketL||this.type.keyword},pp$8.parseClassElementName=function(element){this.type===types$1.privateId?(\"constructor\"===this.value&&this.raise(this.start,\"Classes can't have an element named '#constructor'\"),element.computed=!1,element.key=this.parsePrivateIdent()):this.parsePropertyName(element)},pp$8.parseClassMethod=function(method,isGenerator,isAsync,allowsDirectSuper){var key=method.key;\"constructor\"===method.kind?(isGenerator&&this.raise(key.start,\"Constructor can't be a generator\"),isAsync&&this.raise(key.start,\"Constructor can't be an async method\")):method.static&&checkKeyName(method,\"prototype\")&&this.raise(key.start,\"Classes may not have a static property named prototype\");var value=method.value=this.parseMethod(isGenerator,isAsync,allowsDirectSuper);return\"get\"===method.kind&&0!==value.params.length&&this.raiseRecoverable(value.start,\"getter should have no params\"),\"set\"===method.kind&&1!==value.params.length&&this.raiseRecoverable(value.start,\"setter should have exactly one param\"),\"set\"===method.kind&&\"RestElement\"===value.params[0].type&&this.raiseRecoverable(value.params[0].start,\"Setter cannot use rest params\"),this.finishNode(method,\"MethodDefinition\")},pp$8.parseClassField=function(field){if(checkKeyName(field,\"constructor\")?this.raise(field.key.start,\"Classes can't have a field named 'constructor'\"):field.static&&checkKeyName(field,\"prototype\")&&this.raise(field.key.start,\"Classes can't have a static field named 'prototype'\"),this.eat(types$1.eq)){var scope=this.currentThisScope(),inClassFieldInit=scope.inClassFieldInit;scope.inClassFieldInit=!0,field.value=this.parseMaybeAssign(),scope.inClassFieldInit=inClassFieldInit}else field.value=null;return this.semicolon(),this.finishNode(field,\"PropertyDefinition\")},pp$8.parseClassStaticBlock=function(node){node.body=[];var oldLabels=this.labels;for(this.labels=[],this.enterScope(320);this.type!==types$1.braceR;){var stmt=this.parseStatement(null);node.body.push(stmt)}return this.next(),this.exitScope(),this.labels=oldLabels,this.finishNode(node,\"StaticBlock\")},pp$8.parseClassId=function(node,isStatement){this.type===types$1.name?(node.id=this.parseIdent(),isStatement&&this.checkLValSimple(node.id,2,!1)):(!0===isStatement&&this.unexpected(),node.id=null)},pp$8.parseClassSuper=function(node){node.superClass=this.eat(types$1._extends)?this.parseExprSubscripts(!1):null},pp$8.enterClassBody=function(){var element={declared:Object.create(null),used:[]};return this.privateNameStack.push(element),element.declared},pp$8.exitClassBody=function(){for(var ref=this.privateNameStack.pop(),declared=ref.declared,used=ref.used,len=this.privateNameStack.length,parent=0===len?null:this.privateNameStack[len-1],i=0;i=11&&(this.eatContextual(\"as\")?(node.exported=this.parseModuleExportName(),this.checkExport(exports,node.exported,this.lastTokStart)):node.exported=null),this.expectContextual(\"from\"),this.type!==types$1.string&&this.unexpected(),node.source=this.parseExprAtom(),this.semicolon(),this.finishNode(node,\"ExportAllDeclaration\");if(this.eat(types$1._default)){var isAsync;if(this.checkExport(exports,\"default\",this.lastTokStart),this.type===types$1._function||(isAsync=this.isAsyncFunction())){var fNode=this.startNode();this.next(),isAsync&&this.next(),node.declaration=this.parseFunction(fNode,4|FUNC_STATEMENT,!1,isAsync)}else if(this.type===types$1._class){var cNode=this.startNode();node.declaration=this.parseClass(cNode,\"nullableID\")}else node.declaration=this.parseMaybeAssign(),this.semicolon();return this.finishNode(node,\"ExportDefaultDeclaration\")}if(this.shouldParseExportStatement())node.declaration=this.parseStatement(null),\"VariableDeclaration\"===node.declaration.type?this.checkVariableExport(exports,node.declaration.declarations):this.checkExport(exports,node.declaration.id,node.declaration.id.start),node.specifiers=[],node.source=null;else{if(node.declaration=null,node.specifiers=this.parseExportSpecifiers(exports),this.eatContextual(\"from\"))this.type!==types$1.string&&this.unexpected(),node.source=this.parseExprAtom();else{for(var i=0,list=node.specifiers;i=13&&this.type===types$1.string){var stringLiteral=this.parseLiteral(this.value);return loneSurrogate.test(stringLiteral.value)&&this.raise(stringLiteral.start,\"An export name cannot include a lone surrogate.\"),stringLiteral}return this.parseIdent(!0)},pp$8.adaptDirectivePrologue=function(statements){for(var i=0;i=5&&\"ExpressionStatement\"===statement.type&&\"Literal\"===statement.expression.type&&\"string\"==typeof statement.expression.value&&('\"'===this.input[statement.start]||\"'\"===this.input[statement.start])};var pp$7=Parser.prototype;pp$7.toAssignable=function(node,isBinding,refDestructuringErrors){if(this.options.ecmaVersion>=6&&node)switch(node.type){case\"Identifier\":this.inAsync&&\"await\"===node.name&&this.raise(node.start,\"Cannot use 'await' as identifier inside an async function\");break;case\"ObjectPattern\":case\"ArrayPattern\":case\"AssignmentPattern\":case\"RestElement\":break;case\"ObjectExpression\":node.type=\"ObjectPattern\",refDestructuringErrors&&this.checkPatternErrors(refDestructuringErrors,!0);for(var i=0,list=node.properties;i=8&&!containsEsc&&\"async\"===id.name&&!this.canInsertSemicolon()&&this.eat(types$1._function))return this.overrideContext(types.f_expr),this.parseFunction(this.startNodeAt(startPos,startLoc),0,!1,!0,forInit);if(canBeArrow&&!this.canInsertSemicolon()){if(this.eat(types$1.arrow))return this.parseArrowExpression(this.startNodeAt(startPos,startLoc),[id],!1,forInit);if(this.options.ecmaVersion>=8&&\"async\"===id.name&&this.type===types$1.name&&!containsEsc&&(!this.potentialArrowInForAwait||\"of\"!==this.value||this.containsEsc))return id=this.parseIdent(!1),!this.canInsertSemicolon()&&this.eat(types$1.arrow)||this.unexpected(),this.parseArrowExpression(this.startNodeAt(startPos,startLoc),[id],!0,forInit)}return id;case types$1.regexp:var value=this.value;return(node=this.parseLiteral(value.value)).regex={pattern:value.pattern,flags:value.flags},node;case types$1.num:case types$1.string:return this.parseLiteral(this.value);case types$1._null:case types$1._true:case types$1._false:return(node=this.startNode()).value=this.type===types$1._null?null:this.type===types$1._true,node.raw=this.type.keyword,this.next(),this.finishNode(node,\"Literal\");case types$1.parenL:var start=this.start,expr=this.parseParenAndDistinguishExpression(canBeArrow,forInit);return refDestructuringErrors&&(refDestructuringErrors.parenthesizedAssign<0&&!this.isSimpleAssignTarget(expr)&&(refDestructuringErrors.parenthesizedAssign=start),refDestructuringErrors.parenthesizedBind<0&&(refDestructuringErrors.parenthesizedBind=start)),expr;case types$1.bracketL:return node=this.startNode(),this.next(),node.elements=this.parseExprList(types$1.bracketR,!0,!0,refDestructuringErrors),this.finishNode(node,\"ArrayExpression\");case types$1.braceL:return this.overrideContext(types.b_expr),this.parseObj(!1,refDestructuringErrors);case types$1._function:return node=this.startNode(),this.next(),this.parseFunction(node,0);case types$1._class:return this.parseClass(this.startNode(),!1);case types$1._new:return this.parseNew();case types$1.backQuote:return this.parseTemplate();case types$1._import:return this.options.ecmaVersion>=11?this.parseExprImport():this.unexpected();default:this.unexpected()}},pp$5.parseExprImport=function(){var node=this.startNode();this.containsEsc&&this.raiseRecoverable(this.start,\"Escape sequence in keyword import\");var meta=this.parseIdent(!0);switch(this.type){case types$1.parenL:return this.parseDynamicImport(node);case types$1.dot:return node.meta=meta,this.parseImportMeta(node);default:this.unexpected()}},pp$5.parseDynamicImport=function(node){if(this.next(),node.source=this.parseMaybeAssign(),!this.eat(types$1.parenR)){var errorPos=this.start;this.eat(types$1.comma)&&this.eat(types$1.parenR)?this.raiseRecoverable(errorPos,\"Trailing comma is not allowed in import()\"):this.unexpected(errorPos)}return this.finishNode(node,\"ImportExpression\")},pp$5.parseImportMeta=function(node){this.next();var containsEsc=this.containsEsc;return node.property=this.parseIdent(!0),\"meta\"!==node.property.name&&this.raiseRecoverable(node.property.start,\"The only valid meta property for import is 'import.meta'\"),containsEsc&&this.raiseRecoverable(node.start,\"'import.meta' must not contain escaped characters\"),\"module\"===this.options.sourceType||this.options.allowImportExportEverywhere||this.raiseRecoverable(node.start,\"Cannot use 'import.meta' outside a module\"),this.finishNode(node,\"MetaProperty\")},pp$5.parseLiteral=function(value){var node=this.startNode();return node.value=value,node.raw=this.input.slice(this.start,this.end),110===node.raw.charCodeAt(node.raw.length-1)&&(node.bigint=node.raw.slice(0,-1).replace(/_/g,\"\")),this.next(),this.finishNode(node,\"Literal\")},pp$5.parseParenExpression=function(){this.expect(types$1.parenL);var val=this.parseExpression();return this.expect(types$1.parenR),val},pp$5.parseParenAndDistinguishExpression=function(canBeArrow,forInit){var val,startPos=this.start,startLoc=this.startLoc,allowTrailingComma=this.options.ecmaVersion>=8;if(this.options.ecmaVersion>=6){this.next();var spreadStart,innerStartPos=this.start,innerStartLoc=this.startLoc,exprList=[],first=!0,lastIsComma=!1,refDestructuringErrors=new DestructuringErrors,oldYieldPos=this.yieldPos,oldAwaitPos=this.awaitPos;for(this.yieldPos=0,this.awaitPos=0;this.type!==types$1.parenR;){if(first?first=!1:this.expect(types$1.comma),allowTrailingComma&&this.afterTrailingComma(types$1.parenR,!0)){lastIsComma=!0;break}if(this.type===types$1.ellipsis){spreadStart=this.start,exprList.push(this.parseParenItem(this.parseRestBinding())),this.type===types$1.comma&&this.raise(this.start,\"Comma is not permitted after the rest element\");break}exprList.push(this.parseMaybeAssign(!1,refDestructuringErrors,this.parseParenItem))}var innerEndPos=this.lastTokEnd,innerEndLoc=this.lastTokEndLoc;if(this.expect(types$1.parenR),canBeArrow&&!this.canInsertSemicolon()&&this.eat(types$1.arrow))return this.checkPatternErrors(refDestructuringErrors,!1),this.checkYieldAwaitInDefaultParams(),this.yieldPos=oldYieldPos,this.awaitPos=oldAwaitPos,this.parseParenArrowList(startPos,startLoc,exprList,forInit);exprList.length&&!lastIsComma||this.unexpected(this.lastTokStart),spreadStart&&this.unexpected(spreadStart),this.checkExpressionErrors(refDestructuringErrors,!0),this.yieldPos=oldYieldPos||this.yieldPos,this.awaitPos=oldAwaitPos||this.awaitPos,exprList.length>1?((val=this.startNodeAt(innerStartPos,innerStartLoc)).expressions=exprList,this.finishNodeAt(val,\"SequenceExpression\",innerEndPos,innerEndLoc)):val=exprList[0]}else val=this.parseParenExpression();if(this.options.preserveParens){var par=this.startNodeAt(startPos,startLoc);return par.expression=val,this.finishNode(par,\"ParenthesizedExpression\")}return val},pp$5.parseParenItem=function(item){return item},pp$5.parseParenArrowList=function(startPos,startLoc,exprList,forInit){return this.parseArrowExpression(this.startNodeAt(startPos,startLoc),exprList,!1,forInit)};var empty=[];pp$5.parseNew=function(){this.containsEsc&&this.raiseRecoverable(this.start,\"Escape sequence in keyword new\");var node=this.startNode(),meta=this.parseIdent(!0);if(this.options.ecmaVersion>=6&&this.eat(types$1.dot)){node.meta=meta;var containsEsc=this.containsEsc;return node.property=this.parseIdent(!0),\"target\"!==node.property.name&&this.raiseRecoverable(node.property.start,\"The only valid meta property for new is 'new.target'\"),containsEsc&&this.raiseRecoverable(node.start,\"'new.target' must not contain escaped characters\"),this.allowNewDotTarget||this.raiseRecoverable(node.start,\"'new.target' can only be used in functions and class static block\"),this.finishNode(node,\"MetaProperty\")}var startPos=this.start,startLoc=this.startLoc,isImport=this.type===types$1._import;return node.callee=this.parseSubscripts(this.parseExprAtom(),startPos,startLoc,!0,!1),isImport&&\"ImportExpression\"===node.callee.type&&this.raise(startPos,\"Cannot use new with import()\"),this.eat(types$1.parenL)?node.arguments=this.parseExprList(types$1.parenR,this.options.ecmaVersion>=8,!1):node.arguments=empty,this.finishNode(node,\"NewExpression\")},pp$5.parseTemplateElement=function(ref){var isTagged=ref.isTagged,elem=this.startNode();return this.type===types$1.invalidTemplate?(isTagged||this.raiseRecoverable(this.start,\"Bad escape sequence in untagged template literal\"),elem.value={raw:this.value,cooked:null}):elem.value={raw:this.input.slice(this.start,this.end).replace(/\\r\\n?/g,\"\\n\"),cooked:this.value},this.next(),elem.tail=this.type===types$1.backQuote,this.finishNode(elem,\"TemplateElement\")},pp$5.parseTemplate=function(ref){void 0===ref&&(ref={});var isTagged=ref.isTagged;void 0===isTagged&&(isTagged=!1);var node=this.startNode();this.next(),node.expressions=[];var curElt=this.parseTemplateElement({isTagged});for(node.quasis=[curElt];!curElt.tail;)this.type===types$1.eof&&this.raise(this.pos,\"Unterminated template literal\"),this.expect(types$1.dollarBraceL),node.expressions.push(this.parseExpression()),this.expect(types$1.braceR),node.quasis.push(curElt=this.parseTemplateElement({isTagged}));return this.next(),this.finishNode(node,\"TemplateLiteral\")},pp$5.isAsyncProp=function(prop){return!prop.computed&&\"Identifier\"===prop.key.type&&\"async\"===prop.key.name&&(this.type===types$1.name||this.type===types$1.num||this.type===types$1.string||this.type===types$1.bracketL||this.type.keyword||this.options.ecmaVersion>=9&&this.type===types$1.star)&&!lineBreak.test(this.input.slice(this.lastTokEnd,this.start))},pp$5.parseObj=function(isPattern,refDestructuringErrors){var node=this.startNode(),first=!0,propHash={};for(node.properties=[],this.next();!this.eat(types$1.braceR);){if(first)first=!1;else if(this.expect(types$1.comma),this.options.ecmaVersion>=5&&this.afterTrailingComma(types$1.braceR))break;var prop=this.parseProperty(isPattern,refDestructuringErrors);isPattern||this.checkPropClash(prop,propHash,refDestructuringErrors),node.properties.push(prop)}return this.finishNode(node,isPattern?\"ObjectPattern\":\"ObjectExpression\")},pp$5.parseProperty=function(isPattern,refDestructuringErrors){var isGenerator,isAsync,startPos,startLoc,prop=this.startNode();if(this.options.ecmaVersion>=9&&this.eat(types$1.ellipsis))return isPattern?(prop.argument=this.parseIdent(!1),this.type===types$1.comma&&this.raise(this.start,\"Comma is not permitted after the rest element\"),this.finishNode(prop,\"RestElement\")):(prop.argument=this.parseMaybeAssign(!1,refDestructuringErrors),this.type===types$1.comma&&refDestructuringErrors&&refDestructuringErrors.trailingComma<0&&(refDestructuringErrors.trailingComma=this.start),this.finishNode(prop,\"SpreadElement\"));this.options.ecmaVersion>=6&&(prop.method=!1,prop.shorthand=!1,(isPattern||refDestructuringErrors)&&(startPos=this.start,startLoc=this.startLoc),isPattern||(isGenerator=this.eat(types$1.star)));var containsEsc=this.containsEsc;return this.parsePropertyName(prop),!isPattern&&!containsEsc&&this.options.ecmaVersion>=8&&!isGenerator&&this.isAsyncProp(prop)?(isAsync=!0,isGenerator=this.options.ecmaVersion>=9&&this.eat(types$1.star),this.parsePropertyName(prop,refDestructuringErrors)):isAsync=!1,this.parsePropertyValue(prop,isPattern,isGenerator,isAsync,startPos,startLoc,refDestructuringErrors,containsEsc),this.finishNode(prop,\"Property\")},pp$5.parsePropertyValue=function(prop,isPattern,isGenerator,isAsync,startPos,startLoc,refDestructuringErrors,containsEsc){if((isGenerator||isAsync)&&this.type===types$1.colon&&this.unexpected(),this.eat(types$1.colon))prop.value=isPattern?this.parseMaybeDefault(this.start,this.startLoc):this.parseMaybeAssign(!1,refDestructuringErrors),prop.kind=\"init\";else if(this.options.ecmaVersion>=6&&this.type===types$1.parenL)isPattern&&this.unexpected(),prop.kind=\"init\",prop.method=!0,prop.value=this.parseMethod(isGenerator,isAsync);else if(isPattern||containsEsc||!(this.options.ecmaVersion>=5)||prop.computed||\"Identifier\"!==prop.key.type||\"get\"!==prop.key.name&&\"set\"!==prop.key.name||this.type===types$1.comma||this.type===types$1.braceR||this.type===types$1.eq)this.options.ecmaVersion>=6&&!prop.computed&&\"Identifier\"===prop.key.type?((isGenerator||isAsync)&&this.unexpected(),this.checkUnreserved(prop.key),\"await\"!==prop.key.name||this.awaitIdentPos||(this.awaitIdentPos=startPos),prop.kind=\"init\",isPattern?prop.value=this.parseMaybeDefault(startPos,startLoc,this.copyNode(prop.key)):this.type===types$1.eq&&refDestructuringErrors?(refDestructuringErrors.shorthandAssign<0&&(refDestructuringErrors.shorthandAssign=this.start),prop.value=this.parseMaybeDefault(startPos,startLoc,this.copyNode(prop.key))):prop.value=this.copyNode(prop.key),prop.shorthand=!0):this.unexpected();else{(isGenerator||isAsync)&&this.unexpected(),prop.kind=prop.key.name,this.parsePropertyName(prop),prop.value=this.parseMethod(!1);var paramCount=\"get\"===prop.kind?0:1;if(prop.value.params.length!==paramCount){var start=prop.value.start;\"get\"===prop.kind?this.raiseRecoverable(start,\"getter should have no params\"):this.raiseRecoverable(start,\"setter should have exactly one param\")}else\"set\"===prop.kind&&\"RestElement\"===prop.value.params[0].type&&this.raiseRecoverable(prop.value.params[0].start,\"Setter cannot use rest params\")}},pp$5.parsePropertyName=function(prop){if(this.options.ecmaVersion>=6){if(this.eat(types$1.bracketL))return prop.computed=!0,prop.key=this.parseMaybeAssign(),this.expect(types$1.bracketR),prop.key;prop.computed=!1}return prop.key=this.type===types$1.num||this.type===types$1.string?this.parseExprAtom():this.parseIdent(\"never\"!==this.options.allowReserved)},pp$5.initFunction=function(node){node.id=null,this.options.ecmaVersion>=6&&(node.generator=node.expression=!1),this.options.ecmaVersion>=8&&(node.async=!1)},pp$5.parseMethod=function(isGenerator,isAsync,allowDirectSuper){var node=this.startNode(),oldYieldPos=this.yieldPos,oldAwaitPos=this.awaitPos,oldAwaitIdentPos=this.awaitIdentPos;return this.initFunction(node),this.options.ecmaVersion>=6&&(node.generator=isGenerator),this.options.ecmaVersion>=8&&(node.async=!!isAsync),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(64|functionFlags(isAsync,node.generator)|(allowDirectSuper?128:0)),this.expect(types$1.parenL),node.params=this.parseBindingList(types$1.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams(),this.parseFunctionBody(node,!1,!0,!1),this.yieldPos=oldYieldPos,this.awaitPos=oldAwaitPos,this.awaitIdentPos=oldAwaitIdentPos,this.finishNode(node,\"FunctionExpression\")},pp$5.parseArrowExpression=function(node,params,isAsync,forInit){var oldYieldPos=this.yieldPos,oldAwaitPos=this.awaitPos,oldAwaitIdentPos=this.awaitIdentPos;return this.enterScope(16|functionFlags(isAsync,!1)),this.initFunction(node),this.options.ecmaVersion>=8&&(node.async=!!isAsync),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,node.params=this.toAssignableList(params,!0),this.parseFunctionBody(node,!0,!1,forInit),this.yieldPos=oldYieldPos,this.awaitPos=oldAwaitPos,this.awaitIdentPos=oldAwaitIdentPos,this.finishNode(node,\"ArrowFunctionExpression\")},pp$5.parseFunctionBody=function(node,isArrowFunction,isMethod,forInit){var isExpression=isArrowFunction&&this.type!==types$1.braceL,oldStrict=this.strict,useStrict=!1;if(isExpression)node.body=this.parseMaybeAssign(forInit),node.expression=!0,this.checkParams(node,!1);else{var nonSimple=this.options.ecmaVersion>=7&&!this.isSimpleParamList(node.params);oldStrict&&!nonSimple||(useStrict=this.strictDirective(this.end))&&nonSimple&&this.raiseRecoverable(node.start,\"Illegal 'use strict' directive in function with non-simple parameter list\");var oldLabels=this.labels;this.labels=[],useStrict&&(this.strict=!0),this.checkParams(node,!oldStrict&&!useStrict&&!isArrowFunction&&!isMethod&&this.isSimpleParamList(node.params)),this.strict&&node.id&&this.checkLValSimple(node.id,5),node.body=this.parseBlock(!1,void 0,useStrict&&!oldStrict),node.expression=!1,this.adaptDirectivePrologue(node.body.body),this.labels=oldLabels}this.exitScope()},pp$5.isSimpleParamList=function(params){for(var i=0,list=params;i-1||scope.functions.indexOf(name)>-1||scope.var.indexOf(name)>-1,scope.lexical.push(name),this.inModule&&1&scope.flags&&delete this.undefinedExports[name]}else if(4===bindingType){this.currentScope().lexical.push(name)}else if(3===bindingType){var scope$2=this.currentScope();redeclared=this.treatFunctionsAsVar?scope$2.lexical.indexOf(name)>-1:scope$2.lexical.indexOf(name)>-1||scope$2.var.indexOf(name)>-1,scope$2.functions.push(name)}else for(var i=this.scopeStack.length-1;i>=0;--i){var scope$3=this.scopeStack[i];if(scope$3.lexical.indexOf(name)>-1&&!(32&scope$3.flags&&scope$3.lexical[0]===name)||!this.treatFunctionsAsVarInScope(scope$3)&&scope$3.functions.indexOf(name)>-1){redeclared=!0;break}if(scope$3.var.push(name),this.inModule&&1&scope$3.flags&&delete this.undefinedExports[name],259&scope$3.flags)break}redeclared&&this.raiseRecoverable(pos,\"Identifier '\"+name+\"' has already been declared\")},pp$3.checkLocalExport=function(id){-1===this.scopeStack[0].lexical.indexOf(id.name)&&-1===this.scopeStack[0].var.indexOf(id.name)&&(this.undefinedExports[id.name]=id)},pp$3.currentScope=function(){return this.scopeStack[this.scopeStack.length-1]},pp$3.currentVarScope=function(){for(var i=this.scopeStack.length-1;;i--){var scope=this.scopeStack[i];if(259&scope.flags)return scope}},pp$3.currentThisScope=function(){for(var i=this.scopeStack.length-1;;i--){var scope=this.scopeStack[i];if(259&scope.flags&&!(16&scope.flags))return scope}};var Node=function(parser,pos,loc){this.type=\"\",this.start=pos,this.end=0,parser.options.locations&&(this.loc=new SourceLocation(parser,loc)),parser.options.directSourceFile&&(this.sourceFile=parser.options.directSourceFile),parser.options.ranges&&(this.range=[pos,0])},pp$2=Parser.prototype;function finishNodeAt(node,type,pos,loc){return node.type=type,node.end=pos,this.options.locations&&(node.loc.end=loc),this.options.ranges&&(node.range[1]=pos),node}pp$2.startNode=function(){return new Node(this,this.start,this.startLoc)},pp$2.startNodeAt=function(pos,loc){return new Node(this,pos,loc)},pp$2.finishNode=function(node,type){return finishNodeAt.call(this,node,type,this.lastTokEnd,this.lastTokEndLoc)},pp$2.finishNodeAt=function(node,type,pos,loc){return finishNodeAt.call(this,node,type,pos,loc)},pp$2.copyNode=function(node){var newNode=new Node(this,node.start,this.startLoc);for(var prop in node)newNode[prop]=node[prop];return newNode};var ecma9BinaryProperties=\"ASCII ASCII_Hex_Digit AHex Alphabetic Alpha Any Assigned Bidi_Control Bidi_C Bidi_Mirrored Bidi_M Case_Ignorable CI Cased Changes_When_Casefolded CWCF Changes_When_Casemapped CWCM Changes_When_Lowercased CWL Changes_When_NFKC_Casefolded CWKCF Changes_When_Titlecased CWT Changes_When_Uppercased CWU Dash Default_Ignorable_Code_Point DI Deprecated Dep Diacritic Dia Emoji Emoji_Component Emoji_Modifier Emoji_Modifier_Base Emoji_Presentation Extender Ext Grapheme_Base Gr_Base Grapheme_Extend Gr_Ext Hex_Digit Hex IDS_Binary_Operator IDSB IDS_Trinary_Operator IDST ID_Continue IDC ID_Start IDS Ideographic Ideo Join_Control Join_C Logical_Order_Exception LOE Lowercase Lower Math Noncharacter_Code_Point NChar Pattern_Syntax Pat_Syn Pattern_White_Space Pat_WS Quotation_Mark QMark Radical Regional_Indicator RI Sentence_Terminal STerm Soft_Dotted SD Terminal_Punctuation Term Unified_Ideograph UIdeo Uppercase Upper Variation_Selector VS White_Space space XID_Continue XIDC XID_Start XIDS\",ecma10BinaryProperties=ecma9BinaryProperties+\" Extended_Pictographic\",ecma12BinaryProperties=ecma10BinaryProperties+\" EBase EComp EMod EPres ExtPict\",unicodeBinaryProperties={9:ecma9BinaryProperties,10:ecma10BinaryProperties,11:ecma10BinaryProperties,12:ecma12BinaryProperties,13:\"ASCII ASCII_Hex_Digit AHex Alphabetic Alpha Any Assigned Bidi_Control Bidi_C Bidi_Mirrored Bidi_M Case_Ignorable CI Cased Changes_When_Casefolded CWCF Changes_When_Casemapped CWCM Changes_When_Lowercased CWL Changes_When_NFKC_Casefolded CWKCF Changes_When_Titlecased CWT Changes_When_Uppercased CWU Dash Default_Ignorable_Code_Point DI Deprecated Dep Diacritic Dia Emoji Emoji_Component Emoji_Modifier Emoji_Modifier_Base Emoji_Presentation Extender Ext Grapheme_Base Gr_Base Grapheme_Extend Gr_Ext Hex_Digit Hex IDS_Binary_Operator IDSB IDS_Trinary_Operator IDST ID_Continue IDC ID_Start IDS Ideographic Ideo Join_Control Join_C Logical_Order_Exception LOE Lowercase Lower Math Noncharacter_Code_Point NChar Pattern_Syntax Pat_Syn Pattern_White_Space Pat_WS Quotation_Mark QMark Radical Regional_Indicator RI Sentence_Terminal STerm Soft_Dotted SD Terminal_Punctuation Term Unified_Ideograph UIdeo Uppercase Upper Variation_Selector VS White_Space space XID_Continue XIDC XID_Start XIDS Extended_Pictographic EBase EComp EMod EPres ExtPict\"},unicodeGeneralCategoryValues=\"Cased_Letter LC Close_Punctuation Pe Connector_Punctuation Pc Control Cc cntrl Currency_Symbol Sc Dash_Punctuation Pd Decimal_Number Nd digit Enclosing_Mark Me Final_Punctuation Pf Format Cf Initial_Punctuation Pi Letter L Letter_Number Nl Line_Separator Zl Lowercase_Letter Ll Mark M Combining_Mark Math_Symbol Sm Modifier_Letter Lm Modifier_Symbol Sk Nonspacing_Mark Mn Number N Open_Punctuation Ps Other C Other_Letter Lo Other_Number No Other_Punctuation Po Other_Symbol So Paragraph_Separator Zp Private_Use Co Punctuation P punct Separator Z Space_Separator Zs Spacing_Mark Mc Surrogate Cs Symbol S Titlecase_Letter Lt Unassigned Cn Uppercase_Letter Lu\",ecma9ScriptValues=\"Adlam Adlm Ahom Anatolian_Hieroglyphs Hluw Arabic Arab Armenian Armn Avestan Avst Balinese Bali Bamum Bamu Bassa_Vah Bass Batak Batk Bengali Beng Bhaiksuki Bhks Bopomofo Bopo Brahmi Brah Braille Brai Buginese Bugi Buhid Buhd Canadian_Aboriginal Cans Carian Cari Caucasian_Albanian Aghb Chakma Cakm Cham Cham Cherokee Cher Common Zyyy Coptic Copt Qaac Cuneiform Xsux Cypriot Cprt Cyrillic Cyrl Deseret Dsrt Devanagari Deva Duployan Dupl Egyptian_Hieroglyphs Egyp Elbasan Elba Ethiopic Ethi Georgian Geor Glagolitic Glag Gothic Goth Grantha Gran Greek Grek Gujarati Gujr Gurmukhi Guru Han Hani Hangul Hang Hanunoo Hano Hatran Hatr Hebrew Hebr Hiragana Hira Imperial_Aramaic Armi Inherited Zinh Qaai Inscriptional_Pahlavi Phli Inscriptional_Parthian Prti Javanese Java Kaithi Kthi Kannada Knda Katakana Kana Kayah_Li Kali Kharoshthi Khar Khmer Khmr Khojki Khoj Khudawadi Sind Lao Laoo Latin Latn Lepcha Lepc Limbu Limb Linear_A Lina Linear_B Linb Lisu Lisu Lycian Lyci Lydian Lydi Mahajani Mahj Malayalam Mlym Mandaic Mand Manichaean Mani Marchen Marc Masaram_Gondi Gonm Meetei_Mayek Mtei Mende_Kikakui Mend Meroitic_Cursive Merc Meroitic_Hieroglyphs Mero Miao Plrd Modi Mongolian Mong Mro Mroo Multani Mult Myanmar Mymr Nabataean Nbat New_Tai_Lue Talu Newa Newa Nko Nkoo Nushu Nshu Ogham Ogam Ol_Chiki Olck Old_Hungarian Hung Old_Italic Ital Old_North_Arabian Narb Old_Permic Perm Old_Persian Xpeo Old_South_Arabian Sarb Old_Turkic Orkh Oriya Orya Osage Osge Osmanya Osma Pahawh_Hmong Hmng Palmyrene Palm Pau_Cin_Hau Pauc Phags_Pa Phag Phoenician Phnx Psalter_Pahlavi Phlp Rejang Rjng Runic Runr Samaritan Samr Saurashtra Saur Sharada Shrd Shavian Shaw Siddham Sidd SignWriting Sgnw Sinhala Sinh Sora_Sompeng Sora Soyombo Soyo Sundanese Sund Syloti_Nagri Sylo Syriac Syrc Tagalog Tglg Tagbanwa Tagb Tai_Le Tale Tai_Tham Lana Tai_Viet Tavt Takri Takr Tamil Taml Tangut Tang Telugu Telu Thaana Thaa Thai Thai Tibetan Tibt Tifinagh Tfng Tirhuta Tirh Ugaritic Ugar Vai Vaii Warang_Citi Wara Yi Yiii Zanabazar_Square Zanb\",ecma10ScriptValues=ecma9ScriptValues+\" Dogra Dogr Gunjala_Gondi Gong Hanifi_Rohingya Rohg Makasar Maka Medefaidrin Medf Old_Sogdian Sogo Sogdian Sogd\",ecma11ScriptValues=ecma10ScriptValues+\" Elymaic Elym Nandinagari Nand Nyiakeng_Puachue_Hmong Hmnp Wancho Wcho\",ecma12ScriptValues=ecma11ScriptValues+\" Chorasmian Chrs Diak Dives_Akuru Khitan_Small_Script Kits Yezi Yezidi\",unicodeScriptValues={9:ecma9ScriptValues,10:ecma10ScriptValues,11:ecma11ScriptValues,12:ecma12ScriptValues,13:\"Adlam Adlm Ahom Anatolian_Hieroglyphs Hluw Arabic Arab Armenian Armn Avestan Avst Balinese Bali Bamum Bamu Bassa_Vah Bass Batak Batk Bengali Beng Bhaiksuki Bhks Bopomofo Bopo Brahmi Brah Braille Brai Buginese Bugi Buhid Buhd Canadian_Aboriginal Cans Carian Cari Caucasian_Albanian Aghb Chakma Cakm Cham Cham Cherokee Cher Common Zyyy Coptic Copt Qaac Cuneiform Xsux Cypriot Cprt Cyrillic Cyrl Deseret Dsrt Devanagari Deva Duployan Dupl Egyptian_Hieroglyphs Egyp Elbasan Elba Ethiopic Ethi Georgian Geor Glagolitic Glag Gothic Goth Grantha Gran Greek Grek Gujarati Gujr Gurmukhi Guru Han Hani Hangul Hang Hanunoo Hano Hatran Hatr Hebrew Hebr Hiragana Hira Imperial_Aramaic Armi Inherited Zinh Qaai Inscriptional_Pahlavi Phli Inscriptional_Parthian Prti Javanese Java Kaithi Kthi Kannada Knda Katakana Kana Kayah_Li Kali Kharoshthi Khar Khmer Khmr Khojki Khoj Khudawadi Sind Lao Laoo Latin Latn Lepcha Lepc Limbu Limb Linear_A Lina Linear_B Linb Lisu Lisu Lycian Lyci Lydian Lydi Mahajani Mahj Malayalam Mlym Mandaic Mand Manichaean Mani Marchen Marc Masaram_Gondi Gonm Meetei_Mayek Mtei Mende_Kikakui Mend Meroitic_Cursive Merc Meroitic_Hieroglyphs Mero Miao Plrd Modi Mongolian Mong Mro Mroo Multani Mult Myanmar Mymr Nabataean Nbat New_Tai_Lue Talu Newa Newa Nko Nkoo Nushu Nshu Ogham Ogam Ol_Chiki Olck Old_Hungarian Hung Old_Italic Ital Old_North_Arabian Narb Old_Permic Perm Old_Persian Xpeo Old_South_Arabian Sarb Old_Turkic Orkh Oriya Orya Osage Osge Osmanya Osma Pahawh_Hmong Hmng Palmyrene Palm Pau_Cin_Hau Pauc Phags_Pa Phag Phoenician Phnx Psalter_Pahlavi Phlp Rejang Rjng Runic Runr Samaritan Samr Saurashtra Saur Sharada Shrd Shavian Shaw Siddham Sidd SignWriting Sgnw Sinhala Sinh Sora_Sompeng Sora Soyombo Soyo Sundanese Sund Syloti_Nagri Sylo Syriac Syrc Tagalog Tglg Tagbanwa Tagb Tai_Le Tale Tai_Tham Lana Tai_Viet Tavt Takri Takr Tamil Taml Tangut Tang Telugu Telu Thaana Thaa Thai Thai Tibetan Tibt Tifinagh Tfng Tirhuta Tirh Ugaritic Ugar Vai Vaii Warang_Citi Wara Yi Yiii Zanabazar_Square Zanb Dogra Dogr Gunjala_Gondi Gong Hanifi_Rohingya Rohg Makasar Maka Medefaidrin Medf Old_Sogdian Sogo Sogdian Sogd Elymaic Elym Nandinagari Nand Nyiakeng_Puachue_Hmong Hmnp Wancho Wcho Chorasmian Chrs Diak Dives_Akuru Khitan_Small_Script Kits Yezi Yezidi Cypro_Minoan Cpmn Old_Uyghur Ougr Tangsa Tnsa Toto Vithkuqi Vith\"},data={};function buildUnicodeData(ecmaVersion){var d=data[ecmaVersion]={binary:wordsRegexp(unicodeBinaryProperties[ecmaVersion]+\" \"+unicodeGeneralCategoryValues),nonBinary:{General_Category:wordsRegexp(unicodeGeneralCategoryValues),Script:wordsRegexp(unicodeScriptValues[ecmaVersion])}};d.nonBinary.Script_Extensions=d.nonBinary.Script,d.nonBinary.gc=d.nonBinary.General_Category,d.nonBinary.sc=d.nonBinary.Script,d.nonBinary.scx=d.nonBinary.Script_Extensions}for(var i=0,list=[9,10,11,12,13];i=6?\"uy\":\"\")+(parser.options.ecmaVersion>=9?\"s\":\"\")+(parser.options.ecmaVersion>=13?\"d\":\"\"),this.unicodeProperties=data[parser.options.ecmaVersion>=13?13:parser.options.ecmaVersion],this.source=\"\",this.flags=\"\",this.start=0,this.switchU=!1,this.switchN=!1,this.pos=0,this.lastIntValue=0,this.lastStringValue=\"\",this.lastAssertionIsQuantifiable=!1,this.numCapturingParens=0,this.maxBackReference=0,this.groupNames=[],this.backReferenceNames=[]};function isSyntaxCharacter(ch){return 36===ch||ch>=40&&ch<=43||46===ch||63===ch||ch>=91&&ch<=94||ch>=123&&ch<=125}function isControlLetter(ch){return ch>=65&&ch<=90||ch>=97&&ch<=122}function isUnicodePropertyNameCharacter(ch){return isControlLetter(ch)||95===ch}function isUnicodePropertyValueCharacter(ch){return isUnicodePropertyNameCharacter(ch)||isDecimalDigit(ch)}function isDecimalDigit(ch){return ch>=48&&ch<=57}function isHexDigit(ch){return ch>=48&&ch<=57||ch>=65&&ch<=70||ch>=97&&ch<=102}function hexToInt(ch){return ch>=65&&ch<=70?ch-65+10:ch>=97&&ch<=102?ch-97+10:ch-48}function isOctalDigit(ch){return ch>=48&&ch<=55}RegExpValidationState.prototype.reset=function(start,pattern,flags){var unicode=-1!==flags.indexOf(\"u\");this.start=0|start,this.source=pattern+\"\",this.flags=flags,this.switchU=unicode&&this.parser.options.ecmaVersion>=6,this.switchN=unicode&&this.parser.options.ecmaVersion>=9},RegExpValidationState.prototype.raise=function(message){this.parser.raiseRecoverable(this.start,\"Invalid regular expression: /\"+this.source+\"/: \"+message)},RegExpValidationState.prototype.at=function(i,forceU){void 0===forceU&&(forceU=!1);var s=this.source,l=s.length;if(i>=l)return-1;var c=s.charCodeAt(i);if(!forceU&&!this.switchU||c<=55295||c>=57344||i+1>=l)return c;var next=s.charCodeAt(i+1);return next>=56320&&next<=57343?(c<<10)+next-56613888:c},RegExpValidationState.prototype.nextIndex=function(i,forceU){void 0===forceU&&(forceU=!1);var s=this.source,l=s.length;if(i>=l)return l;var next,c=s.charCodeAt(i);return!forceU&&!this.switchU||c<=55295||c>=57344||i+1>=l||(next=s.charCodeAt(i+1))<56320||next>57343?i+1:i+2},RegExpValidationState.prototype.current=function(forceU){return void 0===forceU&&(forceU=!1),this.at(this.pos,forceU)},RegExpValidationState.prototype.lookahead=function(forceU){return void 0===forceU&&(forceU=!1),this.at(this.nextIndex(this.pos,forceU),forceU)},RegExpValidationState.prototype.advance=function(forceU){void 0===forceU&&(forceU=!1),this.pos=this.nextIndex(this.pos,forceU)},RegExpValidationState.prototype.eat=function(ch,forceU){return void 0===forceU&&(forceU=!1),this.current(forceU)===ch&&(this.advance(forceU),!0)},pp$1.validateRegExpFlags=function(state){for(var validFlags=state.validFlags,flags=state.flags,i=0;i-1&&this.raise(state.start,\"Duplicate regular expression flag\")}},pp$1.validateRegExpPattern=function(state){this.regexp_pattern(state),!state.switchN&&this.options.ecmaVersion>=9&&state.groupNames.length>0&&(state.switchN=!0,this.regexp_pattern(state))},pp$1.regexp_pattern=function(state){state.pos=0,state.lastIntValue=0,state.lastStringValue=\"\",state.lastAssertionIsQuantifiable=!1,state.numCapturingParens=0,state.maxBackReference=0,state.groupNames.length=0,state.backReferenceNames.length=0,this.regexp_disjunction(state),state.pos!==state.source.length&&(state.eat(41)&&state.raise(\"Unmatched ')'\"),(state.eat(93)||state.eat(125))&&state.raise(\"Lone quantifier brackets\")),state.maxBackReference>state.numCapturingParens&&state.raise(\"Invalid escape\");for(var i=0,list=state.backReferenceNames;i=9&&(lookbehind=state.eat(60)),state.eat(61)||state.eat(33))return this.regexp_disjunction(state),state.eat(41)||state.raise(\"Unterminated group\"),state.lastAssertionIsQuantifiable=!lookbehind,!0}return state.pos=start,!1},pp$1.regexp_eatQuantifier=function(state,noError){return void 0===noError&&(noError=!1),!!this.regexp_eatQuantifierPrefix(state,noError)&&(state.eat(63),!0)},pp$1.regexp_eatQuantifierPrefix=function(state,noError){return state.eat(42)||state.eat(43)||state.eat(63)||this.regexp_eatBracedQuantifier(state,noError)},pp$1.regexp_eatBracedQuantifier=function(state,noError){var start=state.pos;if(state.eat(123)){var min=0,max=-1;if(this.regexp_eatDecimalDigits(state)&&(min=state.lastIntValue,state.eat(44)&&this.regexp_eatDecimalDigits(state)&&(max=state.lastIntValue),state.eat(125)))return-1!==max&&max=9?this.regexp_groupSpecifier(state):63===state.current()&&state.raise(\"Invalid group\"),this.regexp_disjunction(state),state.eat(41))return state.numCapturingParens+=1,!0;state.raise(\"Unterminated group\")}return!1},pp$1.regexp_eatExtendedAtom=function(state){return state.eat(46)||this.regexp_eatReverseSolidusAtomEscape(state)||this.regexp_eatCharacterClass(state)||this.regexp_eatUncapturingGroup(state)||this.regexp_eatCapturingGroup(state)||this.regexp_eatInvalidBracedQuantifier(state)||this.regexp_eatExtendedPatternCharacter(state)},pp$1.regexp_eatInvalidBracedQuantifier=function(state){return this.regexp_eatBracedQuantifier(state,!0)&&state.raise(\"Nothing to repeat\"),!1},pp$1.regexp_eatSyntaxCharacter=function(state){var ch=state.current();return!!isSyntaxCharacter(ch)&&(state.lastIntValue=ch,state.advance(),!0)},pp$1.regexp_eatPatternCharacters=function(state){for(var start=state.pos,ch=0;-1!==(ch=state.current())&&!isSyntaxCharacter(ch);)state.advance();return state.pos!==start},pp$1.regexp_eatExtendedPatternCharacter=function(state){var ch=state.current();return!(-1===ch||36===ch||ch>=40&&ch<=43||46===ch||63===ch||91===ch||94===ch||124===ch)&&(state.advance(),!0)},pp$1.regexp_groupSpecifier=function(state){if(state.eat(63)){if(this.regexp_eatGroupName(state))return-1!==state.groupNames.indexOf(state.lastStringValue)&&state.raise(\"Duplicate capture group name\"),void state.groupNames.push(state.lastStringValue);state.raise(\"Invalid group\")}},pp$1.regexp_eatGroupName=function(state){if(state.lastStringValue=\"\",state.eat(60)){if(this.regexp_eatRegExpIdentifierName(state)&&state.eat(62))return!0;state.raise(\"Invalid capture group name\")}return!1},pp$1.regexp_eatRegExpIdentifierName=function(state){if(state.lastStringValue=\"\",this.regexp_eatRegExpIdentifierStart(state)){for(state.lastStringValue+=codePointToString(state.lastIntValue);this.regexp_eatRegExpIdentifierPart(state);)state.lastStringValue+=codePointToString(state.lastIntValue);return!0}return!1},pp$1.regexp_eatRegExpIdentifierStart=function(state){var start=state.pos,forceU=this.options.ecmaVersion>=11,ch=state.current(forceU);return state.advance(forceU),92===ch&&this.regexp_eatRegExpUnicodeEscapeSequence(state,forceU)&&(ch=state.lastIntValue),function(ch){return isIdentifierStart(ch,!0)||36===ch||95===ch}(ch)?(state.lastIntValue=ch,!0):(state.pos=start,!1)},pp$1.regexp_eatRegExpIdentifierPart=function(state){var start=state.pos,forceU=this.options.ecmaVersion>=11,ch=state.current(forceU);return state.advance(forceU),92===ch&&this.regexp_eatRegExpUnicodeEscapeSequence(state,forceU)&&(ch=state.lastIntValue),function(ch){return isIdentifierChar(ch,!0)||36===ch||95===ch||8204===ch||8205===ch}(ch)?(state.lastIntValue=ch,!0):(state.pos=start,!1)},pp$1.regexp_eatAtomEscape=function(state){return!!(this.regexp_eatBackReference(state)||this.regexp_eatCharacterClassEscape(state)||this.regexp_eatCharacterEscape(state)||state.switchN&&this.regexp_eatKGroupName(state))||(state.switchU&&(99===state.current()&&state.raise(\"Invalid unicode escape\"),state.raise(\"Invalid escape\")),!1)},pp$1.regexp_eatBackReference=function(state){var start=state.pos;if(this.regexp_eatDecimalEscape(state)){var n=state.lastIntValue;if(state.switchU)return n>state.maxBackReference&&(state.maxBackReference=n),!0;if(n<=state.numCapturingParens)return!0;state.pos=start}return!1},pp$1.regexp_eatKGroupName=function(state){if(state.eat(107)){if(this.regexp_eatGroupName(state))return state.backReferenceNames.push(state.lastStringValue),!0;state.raise(\"Invalid named reference\")}return!1},pp$1.regexp_eatCharacterEscape=function(state){return this.regexp_eatControlEscape(state)||this.regexp_eatCControlLetter(state)||this.regexp_eatZero(state)||this.regexp_eatHexEscapeSequence(state)||this.regexp_eatRegExpUnicodeEscapeSequence(state,!1)||!state.switchU&&this.regexp_eatLegacyOctalEscapeSequence(state)||this.regexp_eatIdentityEscape(state)},pp$1.regexp_eatCControlLetter=function(state){var start=state.pos;if(state.eat(99)){if(this.regexp_eatControlLetter(state))return!0;state.pos=start}return!1},pp$1.regexp_eatZero=function(state){return 48===state.current()&&!isDecimalDigit(state.lookahead())&&(state.lastIntValue=0,state.advance(),!0)},pp$1.regexp_eatControlEscape=function(state){var ch=state.current();return 116===ch?(state.lastIntValue=9,state.advance(),!0):110===ch?(state.lastIntValue=10,state.advance(),!0):118===ch?(state.lastIntValue=11,state.advance(),!0):102===ch?(state.lastIntValue=12,state.advance(),!0):114===ch&&(state.lastIntValue=13,state.advance(),!0)},pp$1.regexp_eatControlLetter=function(state){var ch=state.current();return!!isControlLetter(ch)&&(state.lastIntValue=ch%32,state.advance(),!0)},pp$1.regexp_eatRegExpUnicodeEscapeSequence=function(state,forceU){void 0===forceU&&(forceU=!1);var ch,start=state.pos,switchU=forceU||state.switchU;if(state.eat(117)){if(this.regexp_eatFixedHexDigits(state,4)){var lead=state.lastIntValue;if(switchU&&lead>=55296&&lead<=56319){var leadSurrogateEnd=state.pos;if(state.eat(92)&&state.eat(117)&&this.regexp_eatFixedHexDigits(state,4)){var trail=state.lastIntValue;if(trail>=56320&&trail<=57343)return state.lastIntValue=1024*(lead-55296)+(trail-56320)+65536,!0}state.pos=leadSurrogateEnd,state.lastIntValue=lead}return!0}if(switchU&&state.eat(123)&&this.regexp_eatHexDigits(state)&&state.eat(125)&&((ch=state.lastIntValue)>=0&&ch<=1114111))return!0;switchU&&state.raise(\"Invalid unicode escape\"),state.pos=start}return!1},pp$1.regexp_eatIdentityEscape=function(state){if(state.switchU)return!!this.regexp_eatSyntaxCharacter(state)||!!state.eat(47)&&(state.lastIntValue=47,!0);var ch=state.current();return!(99===ch||state.switchN&&107===ch)&&(state.lastIntValue=ch,state.advance(),!0)},pp$1.regexp_eatDecimalEscape=function(state){state.lastIntValue=0;var ch=state.current();if(ch>=49&&ch<=57){do{state.lastIntValue=10*state.lastIntValue+(ch-48),state.advance()}while((ch=state.current())>=48&&ch<=57);return!0}return!1},pp$1.regexp_eatCharacterClassEscape=function(state){var ch=state.current();if(function(ch){return 100===ch||68===ch||115===ch||83===ch||119===ch||87===ch}(ch))return state.lastIntValue=-1,state.advance(),!0;if(state.switchU&&this.options.ecmaVersion>=9&&(80===ch||112===ch)){if(state.lastIntValue=-1,state.advance(),state.eat(123)&&this.regexp_eatUnicodePropertyValueExpression(state)&&state.eat(125))return!0;state.raise(\"Invalid property name\")}return!1},pp$1.regexp_eatUnicodePropertyValueExpression=function(state){var start=state.pos;if(this.regexp_eatUnicodePropertyName(state)&&state.eat(61)){var name=state.lastStringValue;if(this.regexp_eatUnicodePropertyValue(state)){var value=state.lastStringValue;return this.regexp_validateUnicodePropertyNameAndValue(state,name,value),!0}}if(state.pos=start,this.regexp_eatLoneUnicodePropertyNameOrValue(state)){var nameOrValue=state.lastStringValue;return this.regexp_validateUnicodePropertyNameOrValue(state,nameOrValue),!0}return!1},pp$1.regexp_validateUnicodePropertyNameAndValue=function(state,name,value){hasOwn(state.unicodeProperties.nonBinary,name)||state.raise(\"Invalid property name\"),state.unicodeProperties.nonBinary[name].test(value)||state.raise(\"Invalid property value\")},pp$1.regexp_validateUnicodePropertyNameOrValue=function(state,nameOrValue){state.unicodeProperties.binary.test(nameOrValue)||state.raise(\"Invalid property name\")},pp$1.regexp_eatUnicodePropertyName=function(state){var ch=0;for(state.lastStringValue=\"\";isUnicodePropertyNameCharacter(ch=state.current());)state.lastStringValue+=codePointToString(ch),state.advance();return\"\"!==state.lastStringValue},pp$1.regexp_eatUnicodePropertyValue=function(state){var ch=0;for(state.lastStringValue=\"\";isUnicodePropertyValueCharacter(ch=state.current());)state.lastStringValue+=codePointToString(ch),state.advance();return\"\"!==state.lastStringValue},pp$1.regexp_eatLoneUnicodePropertyNameOrValue=function(state){return this.regexp_eatUnicodePropertyValue(state)},pp$1.regexp_eatCharacterClass=function(state){if(state.eat(91)){if(state.eat(94),this.regexp_classRanges(state),state.eat(93))return!0;state.raise(\"Unterminated character class\")}return!1},pp$1.regexp_classRanges=function(state){for(;this.regexp_eatClassAtom(state);){var left=state.lastIntValue;if(state.eat(45)&&this.regexp_eatClassAtom(state)){var right=state.lastIntValue;!state.switchU||-1!==left&&-1!==right||state.raise(\"Invalid character class\"),-1!==left&&-1!==right&&left>right&&state.raise(\"Range out of order in character class\")}}},pp$1.regexp_eatClassAtom=function(state){var start=state.pos;if(state.eat(92)){if(this.regexp_eatClassEscape(state))return!0;if(state.switchU){var ch$1=state.current();(99===ch$1||isOctalDigit(ch$1))&&state.raise(\"Invalid class escape\"),state.raise(\"Invalid escape\")}state.pos=start}var ch=state.current();return 93!==ch&&(state.lastIntValue=ch,state.advance(),!0)},pp$1.regexp_eatClassEscape=function(state){var start=state.pos;if(state.eat(98))return state.lastIntValue=8,!0;if(state.switchU&&state.eat(45))return state.lastIntValue=45,!0;if(!state.switchU&&state.eat(99)){if(this.regexp_eatClassControlLetter(state))return!0;state.pos=start}return this.regexp_eatCharacterClassEscape(state)||this.regexp_eatCharacterEscape(state)},pp$1.regexp_eatClassControlLetter=function(state){var ch=state.current();return!(!isDecimalDigit(ch)&&95!==ch)&&(state.lastIntValue=ch%32,state.advance(),!0)},pp$1.regexp_eatHexEscapeSequence=function(state){var start=state.pos;if(state.eat(120)){if(this.regexp_eatFixedHexDigits(state,2))return!0;state.switchU&&state.raise(\"Invalid escape\"),state.pos=start}return!1},pp$1.regexp_eatDecimalDigits=function(state){var start=state.pos,ch=0;for(state.lastIntValue=0;isDecimalDigit(ch=state.current());)state.lastIntValue=10*state.lastIntValue+(ch-48),state.advance();return state.pos!==start},pp$1.regexp_eatHexDigits=function(state){var start=state.pos,ch=0;for(state.lastIntValue=0;isHexDigit(ch=state.current());)state.lastIntValue=16*state.lastIntValue+hexToInt(ch),state.advance();return state.pos!==start},pp$1.regexp_eatLegacyOctalEscapeSequence=function(state){if(this.regexp_eatOctalDigit(state)){var n1=state.lastIntValue;if(this.regexp_eatOctalDigit(state)){var n2=state.lastIntValue;n1<=3&&this.regexp_eatOctalDigit(state)?state.lastIntValue=64*n1+8*n2+state.lastIntValue:state.lastIntValue=8*n1+n2}else state.lastIntValue=n1;return!0}return!1},pp$1.regexp_eatOctalDigit=function(state){var ch=state.current();return isOctalDigit(ch)?(state.lastIntValue=ch-48,state.advance(),!0):(state.lastIntValue=0,!1)},pp$1.regexp_eatFixedHexDigits=function(state,length){var start=state.pos;state.lastIntValue=0;for(var i=0;i=this.input.length?this.finishToken(types$1.eof):curContext.override?curContext.override(this):void this.readToken(this.fullCharCodeAtPos())},pp.readToken=function(code){return isIdentifierStart(code,this.options.ecmaVersion>=6)||92===code?this.readWord():this.getTokenFromCode(code)},pp.fullCharCodeAtPos=function(){var code=this.input.charCodeAt(this.pos);if(code<=55295||code>=56320)return code;var next=this.input.charCodeAt(this.pos+1);return next<=56319||next>=57344?code:(code<<10)+next-56613888},pp.skipBlockComment=function(){var startLoc=this.options.onComment&&this.curPosition(),start=this.pos,end=this.input.indexOf(\"*/\",this.pos+=2);if(-1===end&&this.raise(this.pos-2,\"Unterminated comment\"),this.pos=end+2,this.options.locations)for(var nextBreak=void 0,pos=start;(nextBreak=nextLineBreak(this.input,pos,this.pos))>-1;)++this.curLine,pos=this.lineStart=nextBreak;this.options.onComment&&this.options.onComment(!0,this.input.slice(start+2,end),start,this.pos,startLoc,this.curPosition())},pp.skipLineComment=function(startSkip){for(var start=this.pos,startLoc=this.options.onComment&&this.curPosition(),ch=this.input.charCodeAt(this.pos+=startSkip);this.pos8&&ch<14||ch>=5760&&nonASCIIwhitespace.test(String.fromCharCode(ch))))break loop;++this.pos}}},pp.finishToken=function(type,val){this.end=this.pos,this.options.locations&&(this.endLoc=this.curPosition());var prevType=this.type;this.type=type,this.value=val,this.updateContext(prevType)},pp.readToken_dot=function(){var next=this.input.charCodeAt(this.pos+1);if(next>=48&&next<=57)return this.readNumber(!0);var next2=this.input.charCodeAt(this.pos+2);return this.options.ecmaVersion>=6&&46===next&&46===next2?(this.pos+=3,this.finishToken(types$1.ellipsis)):(++this.pos,this.finishToken(types$1.dot))},pp.readToken_slash=function(){var next=this.input.charCodeAt(this.pos+1);return this.exprAllowed?(++this.pos,this.readRegexp()):61===next?this.finishOp(types$1.assign,2):this.finishOp(types$1.slash,1)},pp.readToken_mult_modulo_exp=function(code){var next=this.input.charCodeAt(this.pos+1),size=1,tokentype=42===code?types$1.star:types$1.modulo;return this.options.ecmaVersion>=7&&42===code&&42===next&&(++size,tokentype=types$1.starstar,next=this.input.charCodeAt(this.pos+2)),61===next?this.finishOp(types$1.assign,size+1):this.finishOp(tokentype,size)},pp.readToken_pipe_amp=function(code){var next=this.input.charCodeAt(this.pos+1);if(next===code){if(this.options.ecmaVersion>=12)if(61===this.input.charCodeAt(this.pos+2))return this.finishOp(types$1.assign,3);return this.finishOp(124===code?types$1.logicalOR:types$1.logicalAND,2)}return 61===next?this.finishOp(types$1.assign,2):this.finishOp(124===code?types$1.bitwiseOR:types$1.bitwiseAND,1)},pp.readToken_caret=function(){return 61===this.input.charCodeAt(this.pos+1)?this.finishOp(types$1.assign,2):this.finishOp(types$1.bitwiseXOR,1)},pp.readToken_plus_min=function(code){var next=this.input.charCodeAt(this.pos+1);return next===code?45!==next||this.inModule||62!==this.input.charCodeAt(this.pos+2)||0!==this.lastTokEnd&&!lineBreak.test(this.input.slice(this.lastTokEnd,this.pos))?this.finishOp(types$1.incDec,2):(this.skipLineComment(3),this.skipSpace(),this.nextToken()):61===next?this.finishOp(types$1.assign,2):this.finishOp(types$1.plusMin,1)},pp.readToken_lt_gt=function(code){var next=this.input.charCodeAt(this.pos+1),size=1;return next===code?(size=62===code&&62===this.input.charCodeAt(this.pos+2)?3:2,61===this.input.charCodeAt(this.pos+size)?this.finishOp(types$1.assign,size+1):this.finishOp(types$1.bitShift,size)):33!==next||60!==code||this.inModule||45!==this.input.charCodeAt(this.pos+2)||45!==this.input.charCodeAt(this.pos+3)?(61===next&&(size=2),this.finishOp(types$1.relational,size)):(this.skipLineComment(4),this.skipSpace(),this.nextToken())},pp.readToken_eq_excl=function(code){var next=this.input.charCodeAt(this.pos+1);return 61===next?this.finishOp(types$1.equality,61===this.input.charCodeAt(this.pos+2)?3:2):61===code&&62===next&&this.options.ecmaVersion>=6?(this.pos+=2,this.finishToken(types$1.arrow)):this.finishOp(61===code?types$1.eq:types$1.prefix,1)},pp.readToken_question=function(){var ecmaVersion=this.options.ecmaVersion;if(ecmaVersion>=11){var next=this.input.charCodeAt(this.pos+1);if(46===next){var next2=this.input.charCodeAt(this.pos+2);if(next2<48||next2>57)return this.finishOp(types$1.questionDot,2)}if(63===next){if(ecmaVersion>=12)if(61===this.input.charCodeAt(this.pos+2))return this.finishOp(types$1.assign,3);return this.finishOp(types$1.coalesce,2)}}return this.finishOp(types$1.question,1)},pp.readToken_numberSign=function(){var code=35;if(this.options.ecmaVersion>=13&&(++this.pos,isIdentifierStart(code=this.fullCharCodeAtPos(),!0)||92===code))return this.finishToken(types$1.privateId,this.readWord1());this.raise(this.pos,\"Unexpected character '\"+codePointToString(code)+\"'\")},pp.getTokenFromCode=function(code){switch(code){case 46:return this.readToken_dot();case 40:return++this.pos,this.finishToken(types$1.parenL);case 41:return++this.pos,this.finishToken(types$1.parenR);case 59:return++this.pos,this.finishToken(types$1.semi);case 44:return++this.pos,this.finishToken(types$1.comma);case 91:return++this.pos,this.finishToken(types$1.bracketL);case 93:return++this.pos,this.finishToken(types$1.bracketR);case 123:return++this.pos,this.finishToken(types$1.braceL);case 125:return++this.pos,this.finishToken(types$1.braceR);case 58:return++this.pos,this.finishToken(types$1.colon);case 96:if(this.options.ecmaVersion<6)break;return++this.pos,this.finishToken(types$1.backQuote);case 48:var next=this.input.charCodeAt(this.pos+1);if(120===next||88===next)return this.readRadixNumber(16);if(this.options.ecmaVersion>=6){if(111===next||79===next)return this.readRadixNumber(8);if(98===next||66===next)return this.readRadixNumber(2)}case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return this.readNumber(!1);case 34:case 39:return this.readString(code);case 47:return this.readToken_slash();case 37:case 42:return this.readToken_mult_modulo_exp(code);case 124:case 38:return this.readToken_pipe_amp(code);case 94:return this.readToken_caret();case 43:case 45:return this.readToken_plus_min(code);case 60:case 62:return this.readToken_lt_gt(code);case 61:case 33:return this.readToken_eq_excl(code);case 63:return this.readToken_question();case 126:return this.finishOp(types$1.prefix,1);case 35:return this.readToken_numberSign()}this.raise(this.pos,\"Unexpected character '\"+codePointToString(code)+\"'\")},pp.finishOp=function(type,size){var str=this.input.slice(this.pos,this.pos+size);return this.pos+=size,this.finishToken(type,str)},pp.readRegexp=function(){for(var escaped,inClass,start=this.pos;;){this.pos>=this.input.length&&this.raise(start,\"Unterminated regular expression\");var ch=this.input.charAt(this.pos);if(lineBreak.test(ch)&&this.raise(start,\"Unterminated regular expression\"),escaped)escaped=!1;else{if(\"[\"===ch)inClass=!0;else if(\"]\"===ch&&inClass)inClass=!1;else if(\"/\"===ch&&!inClass)break;escaped=\"\\\\\"===ch}++this.pos}var pattern=this.input.slice(start,this.pos);++this.pos;var flagsStart=this.pos,flags=this.readWord1();this.containsEsc&&this.unexpected(flagsStart);var state=this.regexpState||(this.regexpState=new RegExpValidationState(this));state.reset(start,pattern,flags),this.validateRegExpFlags(state),this.validateRegExpPattern(state);var value=null;try{value=new RegExp(pattern,flags)}catch(e){}return this.finishToken(types$1.regexp,{pattern,flags,value})},pp.readInt=function(radix,len,maybeLegacyOctalNumericLiteral){for(var allowSeparators=this.options.ecmaVersion>=12&&void 0===len,isLegacyOctalNumericLiteral=maybeLegacyOctalNumericLiteral&&48===this.input.charCodeAt(this.pos),start=this.pos,total=0,lastCode=0,i=0,e=null==len?1/0:len;i=97?code-97+10:code>=65?code-65+10:code>=48&&code<=57?code-48:1/0)>=radix)break;lastCode=code,total=total*radix+val}}return allowSeparators&&95===lastCode&&this.raiseRecoverable(this.pos-1,\"Numeric separator is not allowed at the last of digits\"),this.pos===start||null!=len&&this.pos-start!==len?null:total},pp.readRadixNumber=function(radix){var start=this.pos;this.pos+=2;var val=this.readInt(radix);return null==val&&this.raise(this.start+2,\"Expected number in radix \"+radix),this.options.ecmaVersion>=11&&110===this.input.charCodeAt(this.pos)?(val=stringToBigInt(this.input.slice(start,this.pos)),++this.pos):isIdentifierStart(this.fullCharCodeAtPos())&&this.raise(this.pos,\"Identifier directly after number\"),this.finishToken(types$1.num,val)},pp.readNumber=function(startsWithDot){var start=this.pos;startsWithDot||null!==this.readInt(10,void 0,!0)||this.raise(start,\"Invalid number\");var octal=this.pos-start>=2&&48===this.input.charCodeAt(start);octal&&this.strict&&this.raise(start,\"Invalid number\");var next=this.input.charCodeAt(this.pos);if(!octal&&!startsWithDot&&this.options.ecmaVersion>=11&&110===next){var val$1=stringToBigInt(this.input.slice(start,this.pos));return++this.pos,isIdentifierStart(this.fullCharCodeAtPos())&&this.raise(this.pos,\"Identifier directly after number\"),this.finishToken(types$1.num,val$1)}octal&&/[89]/.test(this.input.slice(start,this.pos))&&(octal=!1),46!==next||octal||(++this.pos,this.readInt(10),next=this.input.charCodeAt(this.pos)),69!==next&&101!==next||octal||(43!==(next=this.input.charCodeAt(++this.pos))&&45!==next||++this.pos,null===this.readInt(10)&&this.raise(start,\"Invalid number\")),isIdentifierStart(this.fullCharCodeAtPos())&&this.raise(this.pos,\"Identifier directly after number\");var str,val=(str=this.input.slice(start,this.pos),octal?parseInt(str,8):parseFloat(str.replace(/_/g,\"\")));return this.finishToken(types$1.num,val)},pp.readCodePoint=function(){var code;if(123===this.input.charCodeAt(this.pos)){this.options.ecmaVersion<6&&this.unexpected();var codePos=++this.pos;code=this.readHexChar(this.input.indexOf(\"}\",this.pos)-this.pos),++this.pos,code>1114111&&this.invalidStringToken(codePos,\"Code point out of bounds\")}else code=this.readHexChar(4);return code},pp.readString=function(quote){for(var out=\"\",chunkStart=++this.pos;;){this.pos>=this.input.length&&this.raise(this.start,\"Unterminated string constant\");var ch=this.input.charCodeAt(this.pos);if(ch===quote)break;92===ch?(out+=this.input.slice(chunkStart,this.pos),out+=this.readEscapedChar(!1),chunkStart=this.pos):8232===ch||8233===ch?(this.options.ecmaVersion<10&&this.raise(this.start,\"Unterminated string constant\"),++this.pos,this.options.locations&&(this.curLine++,this.lineStart=this.pos)):(isNewLine(ch)&&this.raise(this.start,\"Unterminated string constant\"),++this.pos)}return out+=this.input.slice(chunkStart,this.pos++),this.finishToken(types$1.string,out)};var INVALID_TEMPLATE_ESCAPE_ERROR={};pp.tryReadTemplateToken=function(){this.inTemplateElement=!0;try{this.readTmplToken()}catch(err){if(err!==INVALID_TEMPLATE_ESCAPE_ERROR)throw err;this.readInvalidTemplateToken()}this.inTemplateElement=!1},pp.invalidStringToken=function(position,message){if(this.inTemplateElement&&this.options.ecmaVersion>=9)throw INVALID_TEMPLATE_ESCAPE_ERROR;this.raise(position,message)},pp.readTmplToken=function(){for(var out=\"\",chunkStart=this.pos;;){this.pos>=this.input.length&&this.raise(this.start,\"Unterminated template\");var ch=this.input.charCodeAt(this.pos);if(96===ch||36===ch&&123===this.input.charCodeAt(this.pos+1))return this.pos!==this.start||this.type!==types$1.template&&this.type!==types$1.invalidTemplate?(out+=this.input.slice(chunkStart,this.pos),this.finishToken(types$1.template,out)):36===ch?(this.pos+=2,this.finishToken(types$1.dollarBraceL)):(++this.pos,this.finishToken(types$1.backQuote));if(92===ch)out+=this.input.slice(chunkStart,this.pos),out+=this.readEscapedChar(!0),chunkStart=this.pos;else if(isNewLine(ch)){switch(out+=this.input.slice(chunkStart,this.pos),++this.pos,ch){case 13:10===this.input.charCodeAt(this.pos)&&++this.pos;case 10:out+=\"\\n\";break;default:out+=String.fromCharCode(ch)}this.options.locations&&(++this.curLine,this.lineStart=this.pos),chunkStart=this.pos}else++this.pos}},pp.readInvalidTemplateToken=function(){for(;this.pos=48&&ch<=55){var octalStr=this.input.substr(this.pos-1,3).match(/^[0-7]+/)[0],octal=parseInt(octalStr,8);return octal>255&&(octalStr=octalStr.slice(0,-1),octal=parseInt(octalStr,8)),this.pos+=octalStr.length-1,ch=this.input.charCodeAt(this.pos),\"0\"===octalStr&&56!==ch&&57!==ch||!this.strict&&!inTemplate||this.invalidStringToken(this.pos-1-octalStr.length,inTemplate?\"Octal literal in template string\":\"Octal literal in strict mode\"),String.fromCharCode(octal)}return isNewLine(ch)?\"\":String.fromCharCode(ch)}},pp.readHexChar=function(len){var codePos=this.pos,n=this.readInt(16,len);return null===n&&this.invalidStringToken(codePos,\"Bad character escape sequence\"),n},pp.readWord1=function(){this.containsEsc=!1;for(var word=\"\",first=!0,chunkStart=this.pos,astral=this.options.ecmaVersion>=6;this.pos`Invalid module \"${request}\" ${reason}${base?` imported from ${base}`:\"\"}`),TypeError),codes.ERR_INVALID_PACKAGE_CONFIG=createError(\"ERR_INVALID_PACKAGE_CONFIG\",((path,base,message)=>`Invalid package config ${path}${base?` while importing ${base}`:\"\"}${message?`. ${message}`:\"\"}`),Error),codes.ERR_INVALID_PACKAGE_TARGET=createError(\"ERR_INVALID_PACKAGE_TARGET\",((pkgPath,key,target,isImport=!1,base)=>{const relError=\"string\"==typeof target&&!isImport&&target.length>0&&!target.startsWith(\"./\");return\".\"===key?(external_assert_namespaceObject(!1===isImport),`Invalid \"exports\" main target ${JSON.stringify(target)} defined in the package config ${pkgPath}package.json${base?` imported from ${base}`:\"\"}${relError?'; targets must start with \"./\"':\"\"}`):`Invalid \"${isImport?\"imports\":\"exports\"}\" target ${JSON.stringify(target)} defined for '${key}' in the package config ${pkgPath}package.json${base?` imported from ${base}`:\"\"}${relError?'; targets must start with \"./\"':\"\"}`}),Error),codes.ERR_MODULE_NOT_FOUND=createError(\"ERR_MODULE_NOT_FOUND\",((path,base,type=\"package\")=>`Cannot find ${type} '${path}' imported from ${base}`),Error),codes.ERR_PACKAGE_IMPORT_NOT_DEFINED=createError(\"ERR_PACKAGE_IMPORT_NOT_DEFINED\",((specifier,packagePath,base)=>`Package import specifier \"${specifier}\" is not defined${packagePath?` in package ${packagePath}package.json`:\"\"} imported from ${base}`),TypeError),codes.ERR_PACKAGE_PATH_NOT_EXPORTED=createError(\"ERR_PACKAGE_PATH_NOT_EXPORTED\",((pkgPath,subpath,base)=>\".\"===subpath?`No \"exports\" main defined in ${pkgPath}package.json${base?` imported from ${base}`:\"\"}`:`Package subpath '${subpath}' is not defined by \"exports\" in ${pkgPath}package.json${base?` imported from ${base}`:\"\"}`),Error),codes.ERR_UNSUPPORTED_DIR_IMPORT=createError(\"ERR_UNSUPPORTED_DIR_IMPORT\",\"Directory import '%s' is not supported resolving ES modules imported from %s\",Error),codes.ERR_UNKNOWN_FILE_EXTENSION=createError(\"ERR_UNKNOWN_FILE_EXTENSION\",'Unknown file extension \"%s\" for %s',TypeError),codes.ERR_INVALID_ARG_VALUE=createError(\"ERR_INVALID_ARG_VALUE\",((name,value,reason=\"is invalid\")=>{let inspected=(0,external_util_.inspect)(value);inspected.length>128&&(inspected=`${inspected.slice(0,128)}...`);return`The ${name.includes(\".\")?\"property\":\"argument\"} '${name}' ${reason}. Received ${inspected}`}),TypeError),codes.ERR_UNSUPPORTED_ESM_URL_SCHEME=createError(\"ERR_UNSUPPORTED_ESM_URL_SCHEME\",(url=>{let message=\"Only file and data URLs are supported by the default ESM loader\";return isWindows&&2===url.protocol.length&&(message+=\". On Windows, absolute paths must be valid file:// URLs\"),message+=`. Received protocol '${url.protocol}'`,message}),Error);const addCodeToName=hideStackFrames((function(error,name,code){(error=captureLargerStackTrace(error)).name=`${name} [${code}]`,error.stack,\"SystemError\"===name?Object.defineProperty(error,\"name\",{value:name,enumerable:!1,writable:!0,configurable:!0}):delete error.name}));function isErrorStackTraceLimitWritable(){const desc=Object.getOwnPropertyDescriptor(Error,\"stackTraceLimit\");return void 0===desc?Object.isExtensible(Error):own$1.call(desc,\"writable\")?desc.writable:void 0!==desc.set}function hideStackFrames(fn){const hidden=\"__node_internal_\"+fn.name;return Object.defineProperty(fn,\"name\",{value:hidden}),fn}const captureLargerStackTrace=hideStackFrames((function(error){const stackTraceLimitIsWritable=isErrorStackTraceLimitWritable();return stackTraceLimitIsWritable&&(userStackTraceLimit=Error.stackTraceLimit,Error.stackTraceLimit=Number.POSITIVE_INFINITY),Error.captureStackTrace(error),stackTraceLimitIsWritable&&(Error.stackTraceLimit=userStackTraceLimit),error}));const{ERR_UNKNOWN_FILE_EXTENSION}=codes,extensionFormatMap={__proto__:null,\".cjs\":\"commonjs\",\".js\":\"module\",\".mjs\":\"module\"};function defaultGetFormat(url){if(url.startsWith(\"node:\"))return{format:\"builtin\"};const parsed=new external_url_namespaceObject.URL(url);if(\"data:\"===parsed.protocol){const{1:mime}=/^([^/]+\\/[^;,]+)[^,]*?(;base64)?,/.exec(parsed.pathname)||[null,null];return{format:\"text/javascript\"===mime?\"module\":null}}if(\"file:\"===parsed.protocol){const ext=external_path_.extname(parsed.pathname);let format;if(format=\".js\"===ext?\"module\"===function(url){return getPackageScopeConfig(url).type}(parsed.href)?\"module\":\"commonjs\":extensionFormatMap[ext],!format)throw new ERR_UNKNOWN_FILE_EXTENSION(ext,(0,external_url_namespaceObject.fileURLToPath)(url));return{format:format||null}}return{format:null}}const{ERR_INVALID_MODULE_SPECIFIER,ERR_INVALID_PACKAGE_CONFIG,ERR_INVALID_PACKAGE_TARGET,ERR_MODULE_NOT_FOUND,ERR_PACKAGE_IMPORT_NOT_DEFINED,ERR_PACKAGE_PATH_NOT_EXPORTED,ERR_UNSUPPORTED_DIR_IMPORT,ERR_UNSUPPORTED_ESM_URL_SCHEME,ERR_INVALID_ARG_VALUE}=codes,own={}.hasOwnProperty;Object.freeze([\"node\",\"import\"]);const invalidSegmentRegEx=/(^|\\\\|\\/)(\\.\\.?|node_modules)(\\\\|\\/|$)/,patternRegEx=/\\*/g,encodedSepRegEx=/%2f|%2c/i,emittedPackageWarnings=new Set,packageJsonCache=new Map;function emitFolderMapDeprecation(match,pjsonUrl,isExports,base){const pjsonPath=(0,external_url_namespaceObject.fileURLToPath)(pjsonUrl);emittedPackageWarnings.has(pjsonPath+\"|\"+match)||(emittedPackageWarnings.add(pjsonPath+\"|\"+match),process.emitWarning(`Use of deprecated folder mapping \"${match}\" in the ${isExports?'\"exports\"':'\"imports\"'} field module resolution of the package at ${pjsonPath}${base?` imported from ${(0,external_url_namespaceObject.fileURLToPath)(base)}`:\"\"}.\\nUpdate this package.json to use a subpath pattern like \"${match}*\".`,\"DeprecationWarning\",\"DEP0148\"))}function emitLegacyIndexDeprecation(url,packageJsonUrl,base,main){const{format}=defaultGetFormat(url.href);if(\"module\"!==format)return;const path2=(0,external_url_namespaceObject.fileURLToPath)(url.href),pkgPath=(0,external_url_namespaceObject.fileURLToPath)(new URL(\".\",packageJsonUrl)),basePath=(0,external_url_namespaceObject.fileURLToPath)(base);main?process.emitWarning(`Package ${pkgPath} has a \"main\" field set to ${JSON.stringify(main)}, excluding the full filename and extension to the resolved file at \"${path2.slice(pkgPath.length)}\", imported from ${basePath}.\\n Automatic extension resolution of the \"main\" field isdeprecated for ES modules.`,\"DeprecationWarning\",\"DEP0151\"):process.emitWarning(`No \"main\" or \"exports\" field defined in the package.json for ${pkgPath} resolving the main entry point \"${path2.slice(pkgPath.length)}\", imported from ${basePath}.\\nDefault \"index\" lookups for the main are deprecated for ES modules.`,\"DeprecationWarning\",\"DEP0151\")}function tryStatSync(path2){try{return(0,external_fs_.statSync)(path2)}catch{return new external_fs_.Stats}}function getPackageConfig(path2,specifier,base){const existing=packageJsonCache.get(path2);if(void 0!==existing)return existing;const source=reader.read(path2).string;if(void 0===source){const packageConfig2={pjsonPath:path2,exists:!1,main:void 0,name:void 0,type:\"none\",exports:void 0,imports:void 0};return packageJsonCache.set(path2,packageConfig2),packageConfig2}let packageJson;try{packageJson=JSON.parse(source)}catch(error){throw new ERR_INVALID_PACKAGE_CONFIG(path2,(base?`\"${specifier}\" from `:\"\")+(0,external_url_namespaceObject.fileURLToPath)(base||specifier),error.message)}const{exports,imports,main,name,type}=packageJson,packageConfig={pjsonPath:path2,exists:!0,main:\"string\"==typeof main?main:void 0,name:\"string\"==typeof name?name:void 0,type:\"module\"===type||\"commonjs\"===type?type:\"none\",exports,imports:imports&&\"object\"==typeof imports?imports:void 0};return packageJsonCache.set(path2,packageConfig),packageConfig}function getPackageScopeConfig(resolved){let packageJsonUrl=new URL(\"./package.json\",resolved);for(;;){if(packageJsonUrl.pathname.endsWith(\"node_modules/package.json\"))break;const packageConfig2=getPackageConfig((0,external_url_namespaceObject.fileURLToPath)(packageJsonUrl),resolved);if(packageConfig2.exists)return packageConfig2;const lastPackageJsonUrl=packageJsonUrl;if(packageJsonUrl=new URL(\"../package.json\",packageJsonUrl),packageJsonUrl.pathname===lastPackageJsonUrl.pathname)break}const packageJsonPath=(0,external_url_namespaceObject.fileURLToPath)(packageJsonUrl),packageConfig={pjsonPath:packageJsonPath,exists:!1,main:void 0,name:void 0,type:\"none\",exports:void 0,imports:void 0};return packageJsonCache.set(packageJsonPath,packageConfig),packageConfig}function fileExists(url){return tryStatSync((0,external_url_namespaceObject.fileURLToPath)(url)).isFile()}function legacyMainResolve(packageJsonUrl,packageConfig,base){let guess;if(void 0!==packageConfig.main){if(guess=new URL(`./${packageConfig.main}`,packageJsonUrl),fileExists(guess))return guess;const tries2=[`./${packageConfig.main}.js`,`./${packageConfig.main}.json`,`./${packageConfig.main}.node`,`./${packageConfig.main}/index.js`,`./${packageConfig.main}/index.json`,`./${packageConfig.main}/index.node`];let i2=-1;for(;++i2=0&&keyNumber<4294967295)}function resolvePackageTarget(packageJsonUrl,target,subpath,packageSubpath,base,pattern,internal,conditions){if(\"string\"==typeof target)return resolvePackageTargetString(target,subpath,packageSubpath,packageJsonUrl,base,pattern,internal,conditions);if(Array.isArray(target)){const targetList=target;if(0===targetList.length)return null;let lastException,i=-1;for(;++i=key.length&&key.length>bestMatch.length||\"/\"===key[key.length-1]&&packageSubpath.startsWith(key)&&key.length>bestMatch.length)&&(bestMatch=key)}if(bestMatch){const target=exports[bestMatch],pattern=\"*\"===bestMatch[bestMatch.length-1],resolved=resolvePackageTarget(packageJsonUrl,target,packageSubpath.slice(bestMatch.length-(pattern?1:0)),bestMatch,base,pattern,!1,conditions);return null==resolved&&throwExportsNotFound(packageSubpath,packageJsonUrl,base),pattern||emitFolderMapDeprecation(bestMatch,packageJsonUrl,!0,base),{resolved,exact:pattern}}throwExportsNotFound(packageSubpath,packageJsonUrl,base)}function packageImportsResolve(name,base,conditions){if(\"#\"===name||name.startsWith(\"#/\")){throw new ERR_INVALID_MODULE_SPECIFIER(name,\"is not a valid internal imports specifier name\",(0,external_url_namespaceObject.fileURLToPath)(base))}let packageJsonUrl;const packageConfig=getPackageScopeConfig(base);if(packageConfig.exists){packageJsonUrl=(0,external_url_namespaceObject.pathToFileURL)(packageConfig.pjsonPath);const imports=packageConfig.imports;if(imports)if(own.call(imports,name)){const resolved=resolvePackageTarget(packageJsonUrl,imports[name],\"\",name,base,!1,!0,conditions);if(null!==resolved)return{resolved,exact:!0}}else{let bestMatch=\"\";const keys=Object.getOwnPropertyNames(imports);let i=-1;for(;++i=key.length&&key.length>bestMatch.length||\"/\"===key[key.length-1]&&name.startsWith(key)&&key.length>bestMatch.length)&&(bestMatch=key)}if(bestMatch){const target=imports[bestMatch],pattern=\"*\"===bestMatch[bestMatch.length-1],resolved=resolvePackageTarget(packageJsonUrl,target,name.slice(bestMatch.length-(pattern?1:0)),bestMatch,base,pattern,!0,conditions);if(null!==resolved)return pattern||emitFolderMapDeprecation(bestMatch,packageJsonUrl,!1,base),{resolved,exact:pattern}}}}!function(specifier,packageJsonUrl,base){throw new ERR_PACKAGE_IMPORT_NOT_DEFINED(specifier,packageJsonUrl&&(0,external_url_namespaceObject.fileURLToPath)(new URL(\".\",packageJsonUrl)),(0,external_url_namespaceObject.fileURLToPath)(base))}(name,packageJsonUrl,base)}function packageResolve(specifier,base,conditions){const{packageName,packageSubpath,isScoped}=function(specifier,base){let separatorIndex=specifier.indexOf(\"/\"),validPackageName=!0,isScoped=!1;\"@\"===specifier[0]&&(isScoped=!0,-1===separatorIndex||0===specifier.length?validPackageName=!1:separatorIndex=specifier.indexOf(\"/\",separatorIndex+1));const packageName=-1===separatorIndex?specifier:specifier.slice(0,separatorIndex);let i=-1;for(;++inew URL(function(id){return\"string\"!=typeof id&&(id=id.toString()),/(node|data|http|https|file):/.test(id)?id:BUILTIN_MODULES.has(id)?\"node:\"+id:\"file://\"+encodeURI(normalizeSlash(id))}(u.toString()))));_urls.length||_urls.push(DEFAULT_URL);const urls=[..._urls];for(const url of _urls)\"file:\"===url.protocol&&(urls.push(new URL(\"./\",url)),urls.push(new URL(joinURL(url.pathname,\"_index.js\"),url)),urls.push(new URL(\"./node_modules\",url)));let resolved;for(const url of urls){if(resolved=_tryModuleResolve(id,url,conditionsSet),resolved)break;for(const prefix of[\"\",\"/index\"]){for(const ext of opts.extensions||DEFAULT_EXTENSIONS)if(resolved=_tryModuleResolve(id+prefix+ext,url,conditionsSet),resolved)break;if(resolved)break}}if(!resolved){const err=new Error(`Cannot find module ${id} imported from ${urls.join(\", \")}`);throw err.code=\"ERR_MODULE_NOT_FOUND\",err}const realPath=(0,external_fs_.realpathSync)(fileURLToPath(resolved));return(0,external_url_namespaceObject.pathToFileURL)(realPath).toString()}function resolveSync(id,opts){return _resolve(id,opts)}function resolvePathSync(id,opts){return fileURLToPath(resolveSync(id,opts))}const ESM_RE=/([\\s;]|^)(import[\\w,{}\\s*]*from|import\\s*['\"*{]|export\\b\\s*(?:[*{]|default|class|type|function|const|var|let|async function)|import\\.meta\\b)/m;function hasESMSyntax(code){return ESM_RE.test(code)}var external_crypto_=__webpack_require__(\"crypto\");function md5(content,len=8){return(0,external_crypto_.createHash)(\"md5\").update(content).digest(\"hex\").slice(0,len)}const _EnvDebug=destr(process.env.JITI_DEBUG),_EnvCache=destr(process.env.JITI_CACHE),_EnvESMResolve=destr(process.env.JITI_ESM_RESOLVE),_EnvRequireCache=destr(process.env.JITI_REQUIRE_CACHE),_EnvSourceMaps=destr(process.env.JITI_SOURCE_MAPS),_EnvAlias=destr(process.env.JITI_ALIAS),_EnvTransform=destr(process.env.JITI_TRANSFORM_MODULES),_EnvNative=destr(process.env.JITI_NATIVE_MODULES),jiti_isWindows=\"win32\"===(0,external_os_namespaceObject.platform)(),defaults={debug:_EnvDebug,cache:void 0===_EnvCache||!!_EnvCache,requireCache:void 0===_EnvRequireCache||!!_EnvRequireCache,sourceMaps:void 0!==_EnvSourceMaps&&!!_EnvSourceMaps,interopDefault:!1,esmResolve:_EnvESMResolve||!1,cacheVersion:\"7\",legacy:(0,semver.lt)(process.version||\"0.0.0\",\"14.0.0\"),extensions:[\".js\",\".mjs\",\".cjs\",\".ts\"],alias:_EnvAlias,nativeModules:_EnvNative||[],transformModules:_EnvTransform||[]};function createJITI(_filename,opts={},parentModule){(opts=Object.assign(Object.assign({},defaults),opts)).legacy&&(opts.cacheVersion+=\"-legacy\"),opts.transformOptions&&(opts.cacheVersion+=\"-\"+object_hash_default()(opts.transformOptions));const alias=opts.alias&&Object.keys(opts.alias).length?normalizeAliases(opts.alias||{}):null,nativeModules=[\"typescript\",\"jiti\"].concat(opts.nativeModules||[]),transformModules=[].concat(opts.transformModules||[]),isNativeRe=new RegExp(`node_modules/(${nativeModules.map((m=>escapeStringRegexp(m))).join(\"|\")})/`),isTransformRe=new RegExp(`node_modules/(${transformModules.map((m=>escapeStringRegexp(m))).join(\"|\")})/`);function debug(...args){opts.debug&&console.log(\"[jiti]\",...args)}if(_filename||(_filename=process.cwd()),function(filename){try{return(0,external_fs_.lstatSync)(filename).isDirectory()}catch(e){return!1}}(_filename)&&(_filename=join(_filename,\"index.js\")),!0===opts.cache&&(opts.cache=join((0,external_os_namespaceObject.tmpdir)(),\"node-jiti\")),opts.cache)try{if((0,mkdirp.sync)(opts.cache),!function(filename){try{return(0,external_fs_.accessSync)(filename,external_fs_.constants.W_OK),!0}catch(e){return!1}}(opts.cache))throw new Error(\"directory is not writable\")}catch(err){debug(\"Error creating cache directory at \",opts.cache,err),opts.cache=!1}const nativeRequire=create_require_default()(jiti_isWindows?_filename.replace(/\\//g,\"\\\\\"):_filename),tryResolve=(id,options)=>{try{return nativeRequire.resolve(id,options)}catch(e){}},_url=(0,external_url_namespaceObject.pathToFileURL)(_filename),_additionalExts=[...opts.extensions].filter((ext=>\".js\"!==ext)),_resolve=(id,options)=>{let resolved,err;if(alias&&(id=function(path,aliases){const _path=normalizeWindowsPath(path);aliases=normalizeAliases(aliases);for(const alias in aliases)if(_path.startsWith(alias))return join(aliases[alias],_path.slice(alias.length));return _path}(id,alias)),opts.esmResolve){try{resolved=resolvePathSync(id,{url:_url,conditions:[\"node\",\"require\",\"import\"]})}catch(_err){err=_err}if(resolved)return resolved}if(opts.extensions.includes(pathe_f81973bb_extname(id)))return nativeRequire.resolve(id,options);try{return nativeRequire.resolve(id,options)}catch(_err){err=_err}for(const ext of _additionalExts)if(resolved=tryResolve(id+ext,options)||tryResolve(id+\"/index\"+ext,options),resolved)return resolved;throw err};function transform(topts){let code=function(filename,source,get){if(!opts.cache||!filename)return get();const sourceHash=` /* v${opts.cacheVersion}-${md5(source,16)} */`,filebase=basename(pathe_f81973bb_dirname(filename))+\"-\"+basename(filename),cacheFile=join(opts.cache,filebase+\".\"+md5(filename)+\".js\");if((0,external_fs_.existsSync)(cacheFile)){const cacheSource=(0,external_fs_.readFileSync)(cacheFile,\"utf-8\");if(cacheSource.endsWith(sourceHash))return debug(\"[cache hit]\",filename,\"~>\",cacheFile),cacheSource}debug(\"[cache miss]\",filename);const result=get();return result.includes(\"__JITI_ERROR__\")||(0,external_fs_.writeFileSync)(cacheFile,result+sourceHash,\"utf-8\"),result}(topts.filename,topts.source,(()=>{var _a;const res=opts.transform(Object.assign(Object.assign(Object.assign({legacy:opts.legacy},opts.transformOptions),{babel:Object.assign(Object.assign({},opts.sourceMaps?{sourceFileName:topts.filename,sourceMaps:\"inline\"}:{}),null===(_a=opts.transformOptions)||void 0===_a?void 0:_a.babel)}),topts));return res.error&&opts.debug&&debug(res.error),res.code}));return code.startsWith(\"#!\")&&(code=\"// \"+code),code}function _interopDefault(mod){return opts.interopDefault?function(sourceModule){if(null===(val=sourceModule)||\"object\"!=typeof val||!(\"default\"in sourceModule))return sourceModule;var val;const newModule=sourceModule.default;for(const key in sourceModule)if(\"default\"===key)try{key in newModule||Object.defineProperty(newModule,key,{enumerable:!1,configurable:!1,get:()=>newModule})}catch(_err){}else try{key in newModule||Object.defineProperty(newModule,key,{enumerable:!0,configurable:!0,get:()=>sourceModule[key]})}catch(_err){}return newModule}(mod):mod}function jiti(id){var _a,_b;if(id.startsWith(\"node:\")?id=id.substr(5):id.startsWith(\"file:\")&&(id=(0,external_url_namespaceObject.fileURLToPath)(id)),external_module_.builtinModules.includes(id)||\".pnp.js\"===id)return nativeRequire(id);const filename=_resolve(id),ext=pathe_f81973bb_extname(filename);if(ext&&!opts.extensions.includes(ext))return debug(\"[unknown]\",filename),nativeRequire(id);if(isNativeRe.test(filename))return debug(\"[native]\",filename),nativeRequire(id);if(opts.requireCache&&nativeRequire.cache[filename])return _interopDefault(null===(_a=nativeRequire.cache[filename])||void 0===_a?void 0:_a.exports);let source=(0,external_fs_.readFileSync)(filename,\"utf-8\");const isTypescript=\".ts\"===ext,isNativeModule=\".mjs\"===ext||\".js\"===ext&&\"module\"===(null===(_b=function(path){for(;path&&\".\"!==path&&\"/\"!==path;){path=join(path,\"..\");try{const pkg=(0,external_fs_.readFileSync)(join(path,\"package.json\"),\"utf-8\");try{return JSON.parse(pkg)}catch(_a){}break}catch(_b){}}}(filename))||void 0===_b?void 0:_b.type),needsTranspile=!(\".cjs\"===ext)&&(isTypescript||isNativeModule||isTransformRe.test(filename)||hasESMSyntax(source)||opts.legacy&&source.match(/\\?\\.|\\?\\?/));const start=external_perf_hooks_namespaceObject.performance.now();if(needsTranspile){source=transform({filename,source,ts:isTypescript});debug(\"[transpile]\"+(isNativeModule?\" [esm]\":\"\"),filename,`(${Math.round(1e3*(external_perf_hooks_namespaceObject.performance.now()-start))/1e3}ms)`)}else try{return debug(\"[native]\",filename),_interopDefault(nativeRequire(id))}catch(err){debug(\"Native require error:\",err),debug(\"[fallback]\",filename),source=transform({filename,source,ts:isTypescript})}const mod=new external_module_.Module(filename);let compiled;mod.filename=filename,parentModule&&(mod.parent=parentModule,Array.isArray(parentModule.children)&&!parentModule.children.includes(mod)&&parentModule.children.push(mod)),mod.require=createJITI(filename,opts,mod),mod.path=pathe_f81973bb_dirname(filename),mod.paths=external_module_.Module._nodeModulePaths(mod.path),opts.requireCache&&(nativeRequire.cache[filename]=mod);try{compiled=external_vm_default().runInThisContext(external_module_.Module.wrap(source),{filename,lineOffset:0,displayErrors:!1})}catch(err){opts.requireCache&&delete nativeRequire.cache[filename],opts.onError(err)}try{compiled(mod.exports,mod.require,mod,mod.filename,pathe_f81973bb_dirname(mod.filename))}catch(err){opts.requireCache&&delete nativeRequire.cache[filename],opts.onError(err)}if(mod.exports&&mod.exports.__JITI_ERROR__){const{filename,line,column,code,message}=mod.exports.__JITI_ERROR__,err=new Error(`${code}: ${message} \\n ${`${filename}:${line}:${column}`}`);Error.captureStackTrace(err,jiti),opts.onError(err)}mod.loaded=!0;return _interopDefault(mod.exports)}return _resolve.paths=nativeRequire.resolve.paths,jiti.resolve=_resolve,jiti.cache=opts.requireCache?nativeRequire.cache:{},jiti.extensions=nativeRequire.extensions,jiti.main=nativeRequire.main,jiti.transform=transform,jiti.register=function(){return(0,lib.addHook)(((source,filename)=>jiti.transform({source,filename,ts:!!filename.match(/\\.[cm]?ts$/)})),{exts:opts.extensions})},jiti}})(),module.exports=__webpack_exports__.default})();", "(()=>{var __webpack_modules__={\"./node_modules/.pnpm/@babel+core@7.19.1/node_modules/@babel/core/lib/config/files lazy recursive\":module=>{function webpackEmptyAsyncContext(req){return Promise.resolve().then((()=>{var e=new Error(\"Cannot find module '\"+req+\"'\");throw e.code=\"MODULE_NOT_FOUND\",e}))}webpackEmptyAsyncContext.keys=()=>[],webpackEmptyAsyncContext.resolve=webpackEmptyAsyncContext,webpackEmptyAsyncContext.id=\"./node_modules/.pnpm/@babel+core@7.19.1/node_modules/@babel/core/lib/config/files lazy recursive\",module.exports=webpackEmptyAsyncContext},\"./node_modules/.pnpm/@babel+core@7.19.1/node_modules/@babel/core/lib/config/files sync recursive\":module=>{function webpackEmptyContext(req){var e=new Error(\"Cannot find module '\"+req+\"'\");throw e.code=\"MODULE_NOT_FOUND\",e}webpackEmptyContext.keys=()=>[],webpackEmptyContext.resolve=webpackEmptyContext,webpackEmptyContext.id=\"./node_modules/.pnpm/@babel+core@7.19.1/node_modules/@babel/core/lib/config/files sync recursive\",module.exports=webpackEmptyContext},\"./node_modules/.pnpm/@babel+plugin-syntax-class-properties@7.12.13_@babel+core@7.19.1/node_modules/@babel/plugin-syntax-class-properties/lib/index.js\":(__unused_webpack_module,exports,__webpack_require__)=>{\"use strict\";Object.defineProperty(exports,\"__esModule\",{value:!0}),exports.default=void 0;var _default=(0,__webpack_require__(\"./node_modules/.pnpm/@babel+helper-plugin-utils@7.18.9/node_modules/@babel/helper-plugin-utils/lib/index.js\").declare)((api=>(api.assertVersion(7),{name:\"syntax-class-properties\",manipulateOptions(opts,parserOpts){parserOpts.plugins.push(\"classProperties\",\"classPrivateProperties\",\"classPrivateMethods\")}})));exports.default=_default},\"./node_modules/.pnpm/@babel+plugin-syntax-export-namespace-from@7.8.3_@babel+core@7.19.1/node_modules/@babel/plugin-syntax-export-namespace-from/lib/index.js\":(__unused_webpack_module,exports,__webpack_require__)=>{\"use strict\";Object.defineProperty(exports,\"__esModule\",{value:!0}),exports.default=void 0;var _default=(0,__webpack_require__(\"./node_modules/.pnpm/@babel+helper-plugin-utils@7.19.0/node_modules/@babel/helper-plugin-utils/lib/index.js\").declare)((api=>(api.assertVersion(7),{name:\"syntax-export-namespace-from\",manipulateOptions(opts,parserOpts){parserOpts.plugins.push(\"exportNamespaceFrom\")}})));exports.default=_default},\"./node_modules/.pnpm/@babel+plugin-syntax-nullish-coalescing-operator@7.8.3_@babel+core@7.19.1/node_modules/@babel/plugin-syntax-nullish-coalescing-operator/lib/index.js\":(__unused_webpack_module,exports,__webpack_require__)=>{\"use strict\";Object.defineProperty(exports,\"__esModule\",{value:!0}),exports.default=void 0;var _default=(0,__webpack_require__(\"./node_modules/.pnpm/@babel+helper-plugin-utils@7.19.0/node_modules/@babel/helper-plugin-utils/lib/index.js\").declare)((api=>(api.assertVersion(7),{name:\"syntax-nullish-coalescing-operator\",manipulateOptions(opts,parserOpts){parserOpts.plugins.push(\"nullishCoalescingOperator\")}})));exports.default=_default},\"./node_modules/.pnpm/@babel+plugin-syntax-optional-chaining@7.8.3_@babel+core@7.19.1/node_modules/@babel/plugin-syntax-optional-chaining/lib/index.js\":(__unused_webpack_module,exports,__webpack_require__)=>{\"use strict\";Object.defineProperty(exports,\"__esModule\",{value:!0}),exports.default=void 0;var _default=(0,__webpack_require__(\"./node_modules/.pnpm/@babel+helper-plugin-utils@7.19.0/node_modules/@babel/helper-plugin-utils/lib/index.js\").declare)((api=>(api.assertVersion(7),{name:\"syntax-optional-chaining\",manipulateOptions(opts,parserOpts){parserOpts.plugins.push(\"optionalChaining\")}})));exports.default=_default},\"./node_modules/.pnpm/@jridgewell+gen-mapping@0.3.2/node_modules/@jridgewell/gen-mapping/dist/gen-mapping.umd.js\":function(__unused_webpack_module,exports,__webpack_require__){!function(exports,setArray,sourcemapCodec,traceMapping){\"use strict\";const COLUMN=0,SOURCES_INDEX=1,SOURCE_LINE=2,SOURCE_COLUMN=3,NAMES_INDEX=4,NO_NAME=-1;let addSegmentInternal;exports.addSegment=void 0,exports.addMapping=void 0,exports.maybeAddSegment=void 0,exports.maybeAddMapping=void 0,exports.setSourceContent=void 0,exports.toDecodedMap=void 0,exports.toEncodedMap=void 0,exports.fromMap=void 0,exports.allMappings=void 0;class GenMapping{constructor({file,sourceRoot}={}){this._names=new setArray.SetArray,this._sources=new setArray.SetArray,this._sourcesContent=[],this._mappings=[],this.file=file,this.sourceRoot=sourceRoot}}function getLine(mappings,index){for(let i=mappings.length;i<=index;i++)mappings[i]=[];return mappings[index]}function getColumnIndex(line,genColumn){let index=line.length;for(let i=index-1;i>=0&&!(genColumn>=line[i][COLUMN]);index=i--);return index}function insert(array,index,value){for(let i=array.length;i>index;i--)array[i]=array[i-1];array[index]=value}function removeEmptyFinalLines(mappings){const{length}=mappings;let len=length;for(let i=len-1;i>=0&&!(mappings[i].length>0);len=i,i--);lenaddSegmentInternal(!1,map,genLine,genColumn,source,sourceLine,sourceColumn,name,content),exports.maybeAddSegment=(map,genLine,genColumn,source,sourceLine,sourceColumn,name,content)=>addSegmentInternal(!0,map,genLine,genColumn,source,sourceLine,sourceColumn,name,content),exports.addMapping=(map,mapping)=>addMappingInternal(!1,map,mapping),exports.maybeAddMapping=(map,mapping)=>addMappingInternal(!0,map,mapping),exports.setSourceContent=(map,source,content)=>{const{_sources:sources,_sourcesContent:sourcesContent}=map;sourcesContent[setArray.put(sources,source)]=content},exports.toDecodedMap=map=>{const{file,sourceRoot,_mappings:mappings,_sources:sources,_sourcesContent:sourcesContent,_names:names}=map;return removeEmptyFinalLines(mappings),{version:3,file:file||void 0,names:names.array,sourceRoot:sourceRoot||void 0,sources:sources.array,sourcesContent,mappings}},exports.toEncodedMap=map=>{const decoded=exports.toDecodedMap(map);return Object.assign(Object.assign({},decoded),{mappings:sourcemapCodec.encode(decoded.mappings)})},exports.allMappings=map=>{const out=[],{_mappings:mappings,_sources:sources,_names:names}=map;for(let i=0;i{const map=new traceMapping.TraceMap(input),gen=new GenMapping({file:map.file,sourceRoot:map.sourceRoot});return putAll(gen._names,map.names),putAll(gen._sources,map.sources),gen._sourcesContent=map.sourcesContent||map.sources.map((()=>null)),gen._mappings=traceMapping.decodedMappings(map),gen},addSegmentInternal=(skipable,map,genLine,genColumn,source,sourceLine,sourceColumn,name,content)=>{const{_mappings:mappings,_sources:sources,_sourcesContent:sourcesContent,_names:names}=map,line=getLine(mappings,genLine),index=getColumnIndex(line,genColumn);if(!source){if(skipable&&skipSourceless(line,index))return;return insert(line,index,[genColumn])}const sourcesIndex=setArray.put(sources,source),namesIndex=name?setArray.put(names,name):NO_NAME;if(sourcesIndex===sourcesContent.length&&(sourcesContent[sourcesIndex]=null!=content?content:null),!skipable||!skipSource(line,index,sourcesIndex,sourceLine,sourceColumn,namesIndex))return insert(line,index,name?[genColumn,sourcesIndex,sourceLine,sourceColumn,namesIndex]:[genColumn,sourcesIndex,sourceLine,sourceColumn])},exports.GenMapping=GenMapping,Object.defineProperty(exports,\"__esModule\",{value:!0})}(exports,__webpack_require__(\"./node_modules/.pnpm/@jridgewell+set-array@1.1.1/node_modules/@jridgewell/set-array/dist/set-array.umd.js\"),__webpack_require__(\"./node_modules/.pnpm/@jridgewell+sourcemap-codec@1.4.13/node_modules/@jridgewell/sourcemap-codec/dist/sourcemap-codec.umd.js\"),__webpack_require__(\"./node_modules/.pnpm/@jridgewell+trace-mapping@0.3.15/node_modules/@jridgewell/trace-mapping/dist/trace-mapping.umd.js\"))},\"./node_modules/.pnpm/@jridgewell+resolve-uri@3.0.7/node_modules/@jridgewell/resolve-uri/dist/resolve-uri.umd.js\":function(module){module.exports=function(){\"use strict\";const schemeRegex=/^[\\w+.-]+:\\/\\//,urlRegex=/^([\\w+.-]+:)\\/\\/([^@/#?]*@)?([^:/#?]*)(:\\d+)?(\\/[^#?]*)?/,fileRegex=/^file:(?:\\/\\/((?![a-z]:)[^/]*)?)?(\\/?.*)/i;function isAbsoluteUrl(input){return schemeRegex.test(input)}function isSchemeRelativeUrl(input){return input.startsWith(\"//\")}function isAbsolutePath(input){return input.startsWith(\"/\")}function isFileUrl(input){return input.startsWith(\"file:\")}function parseAbsoluteUrl(input){const match=urlRegex.exec(input);return makeUrl(match[1],match[2]||\"\",match[3],match[4]||\"\",match[5]||\"/\")}function parseFileUrl(input){const match=fileRegex.exec(input),path=match[2];return makeUrl(\"file:\",\"\",match[1]||\"\",\"\",isAbsolutePath(path)?path:\"/\"+path)}function makeUrl(scheme,user,host,port,path){return{scheme,user,host,port,path,relativePath:!1}}function parseUrl(input){if(isSchemeRelativeUrl(input)){const url=parseAbsoluteUrl(\"http:\"+input);return url.scheme=\"\",url}if(isAbsolutePath(input)){const url=parseAbsoluteUrl(\"http://foo.com\"+input);return url.scheme=\"\",url.host=\"\",url}if(isFileUrl(input))return parseFileUrl(input);if(isAbsoluteUrl(input))return parseAbsoluteUrl(input);const url=parseAbsoluteUrl(\"http://foo.com/\"+input);return url.scheme=\"\",url.host=\"\",url.relativePath=!0,url}function stripPathFilename(path){if(path.endsWith(\"/..\"))return path;const index=path.lastIndexOf(\"/\");return path.slice(0,index+1)}function mergePaths(url,base){url.relativePath&&(normalizePath(base),\"/\"===url.path?url.path=base.path:url.path=stripPathFilename(base.path)+url.path,url.relativePath=base.relativePath)}function normalizePath(url){const{relativePath}=url,pieces=url.path.split(\"/\");let pointer=1,positive=0,addTrailingSlash=!1;for(let i=1;istrarr._indexes[key],exports.put=(strarr,key)=>{const index=exports.get(strarr,key);if(void 0!==index)return index;const{array,_indexes:indexes}=strarr;return indexes[key]=array.push(key)-1},exports.pop=strarr=>{const{array,_indexes:indexes}=strarr;0!==array.length&&(indexes[array.pop()]=void 0)},exports.SetArray=SetArray,Object.defineProperty(exports,\"__esModule\",{value:!0})}(exports)},\"./node_modules/.pnpm/@jridgewell+sourcemap-codec@1.4.13/node_modules/@jridgewell/sourcemap-codec/dist/sourcemap-codec.umd.js\":function(__unused_webpack_module,exports){!function(exports){\"use strict\";const comma=\",\".charCodeAt(0),semicolon=\";\".charCodeAt(0),chars=\"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/\",intToChar=new Uint8Array(64),charToInt=new Uint8Array(128);for(let i=0;iBuffer.from(buf.buffer,buf.byteOffset,buf.byteLength).toString()}:{decode(buf){let out=\"\";for(let i=0;i>>=1,shouldNegate&&(value=-2147483648|-value),state[j]+=value,pos}function hasMoreVlq(mappings,i,length){return!(i>=length)&&mappings.charCodeAt(i)!==comma}function sort(line){line.sort(sortComparator)}function sortComparator(a,b){return a[0]-b[0]}function encode(decoded){const state=new Int32Array(5),bufLength=16384,subLength=bufLength-36,buf=new Uint8Array(bufLength),sub=buf.subarray(0,subLength);let pos=0,out=\"\";for(let i=0;i0&&(pos===bufLength&&(out+=td.decode(buf),pos=0),buf[pos++]=semicolon),0!==line.length){state[0]=0;for(let j=0;jsubLength&&(out+=td.decode(sub),buf.copyWithin(0,subLength,pos),pos-=subLength),j>0&&(buf[pos++]=comma),pos=encodeInteger(buf,pos,state,segment,0),1!==segment.length&&(pos=encodeInteger(buf,pos,state,segment,1),pos=encodeInteger(buf,pos,state,segment,2),pos=encodeInteger(buf,pos,state,segment,3),4!==segment.length&&(pos=encodeInteger(buf,pos,state,segment,4)))}}}return out+td.decode(buf.subarray(0,pos))}function encodeInteger(buf,pos,state,segment,j){const next=segment[j];let num=next-state[j];state[j]=next,num=num<0?-num<<1|1:num<<1;do{let clamped=31#num>>>=5,num>0&&(clamped|=32),buf[pos++]=intToChar[clamped]}while(num>0);return pos}exports.decode=decode,exports.encode=encode,Object.defineProperty(exports,\"__esModule\",{value:!0})}(exports)},\"./node_modules/.pnpm/@jridgewell+trace-mapping@0.3.15/node_modules/@jridgewell/trace-mapping/dist/trace-mapping.umd.js\":function(__unused_webpack_module,exports,__webpack_require__){!function(exports,sourcemapCodec,resolveUri){\"use strict\";function _interopDefaultLegacy(e){return e&&\"object\"==typeof e&&\"default\"in e?e:{default:e}}var resolveUri__default=_interopDefaultLegacy(resolveUri);function resolve(input,base){return base&&!base.endsWith(\"/\")&&(base+=\"/\"),resolveUri__default.default(input,base)}function stripFilename(path){if(!path)return\"\";const index=path.lastIndexOf(\"/\");return path.slice(0,index+1)}const COLUMN=0,SOURCES_INDEX=1,SOURCE_LINE=2,SOURCE_COLUMN=3,NAMES_INDEX=4,REV_GENERATED_LINE=1,REV_GENERATED_COLUMN=2;function maybeSort(mappings,owned){const unsortedIndex=nextUnsortedSegmentLine(mappings,0);if(unsortedIndex===mappings.length)return mappings;owned||(mappings=mappings.slice());for(let i=unsortedIndex;i>1),cmp=haystack[mid][COLUMN]-needle;if(0===cmp)return found=!0,mid;cmp<0?low=mid+1:high=mid-1}return found=!1,low-1}function upperBound(haystack,needle,index){for(let i=index+1;i=0&&haystack[i][COLUMN]===needle;index=i--);return index}function memoizedState(){return{lastKey:-1,lastNeedle:-1,lastIndex:-1}}function memoizedBinarySearch(haystack,needle,state,key){const{lastKey,lastNeedle,lastIndex}=state;let low=0,high=haystack.length-1;if(key===lastKey){if(needle===lastNeedle)return found=-1!==lastIndex&&haystack[lastIndex][COLUMN]===needle,lastIndex;needle>=lastNeedle?low=-1===lastIndex?0:lastIndex:high=lastIndex}return state.lastKey=key,state.lastNeedle=needle,state.lastIndex=binarySearch(haystack,needle,low,high)}function buildBySources(decoded,memos){const sources=memos.map(buildNullArray);for(let i=0;iindex;i--)array[i]=array[i-1];array[index]=value}function buildNullArray(){return{__proto__:null}}const AnyMap=function(map,mapUrl){const parsed=\"string\"==typeof map?JSON.parse(map):map;if(!(\"sections\"in parsed))return new TraceMap(parsed,mapUrl);const mappings=[],sources=[],sourcesContent=[],names=[];recurse(parsed,mapUrl,mappings,sources,sourcesContent,names,0,0,1/0,1/0);const joined={version:3,file:parsed.file,names,sources,sourcesContent,mappings};return exports.presortedDecodedMap(joined)};function recurse(input,mapUrl,mappings,sources,sourcesContent,names,lineOffset,columnOffset,stopLine,stopColumn){const{sections}=input;for(let i=0;istopLine)return;const out=getLine(mappings,lineI),cOffset=0===i?columnOffset:0,line=decoded[i];for(let j=0;j=stopColumn)return;if(1===seg.length){out.push([column]);continue}const sourcesIndex=sourcesOffset+seg[SOURCES_INDEX],sourceLine=seg[SOURCE_LINE],sourceColumn=seg[SOURCE_COLUMN];out.push(4===seg.length?[column,sourcesIndex,sourceLine,sourceColumn]:[column,sourcesIndex,sourceLine,sourceColumn,namesOffset+seg[NAMES_INDEX]])}}}function append(arr,other){for(let i=0;iresolve(s||\"\",from)));const{mappings}=parsed;\"string\"==typeof mappings?(this._encoded=mappings,this._decoded=void 0):(this._encoded=void 0,this._decoded=maybeSort(mappings,isString)),this._decodedMemo=memoizedState(),this._bySources=void 0,this._bySourceMemos=void 0}}function clone(map,mappings){return{version:map.version,file:map.file,names:map.names,sourceRoot:map.sourceRoot,sources:map.sources,sourcesContent:map.sourcesContent,mappings}}function OMapping(source,line,column,name){return{source,line,column,name}}function GMapping(line,column){return{line,column}}function traceSegmentInternal(segments,memo,line,column,bias){let index=memoizedBinarySearch(segments,column,memo,line);return found?index=(bias===LEAST_UPPER_BOUND?upperBound:lowerBound)(segments,column,index):bias===LEAST_UPPER_BOUND&&index++,-1===index||index===segments.length?null:segments[index]}exports.encodedMappings=map=>{var _a;return null!==(_a=map._encoded)&&void 0!==_a?_a:map._encoded=sourcemapCodec.encode(map._decoded)},exports.decodedMappings=map=>map._decoded||(map._decoded=sourcemapCodec.decode(map._encoded)),exports.traceSegment=(map,line,column)=>{const decoded=exports.decodedMappings(map);return line>=decoded.length?null:traceSegmentInternal(decoded[line],map._decodedMemo,line,column,GREATEST_LOWER_BOUND)},exports.originalPositionFor=(map,{line,column,bias})=>{if(--line<0)throw new Error(LINE_GTR_ZERO);if(column<0)throw new Error(COL_GTR_EQ_ZERO);const decoded=exports.decodedMappings(map);if(line>=decoded.length)return OMapping(null,null,null,null);const segment=traceSegmentInternal(decoded[line],map._decodedMemo,line,column,bias||GREATEST_LOWER_BOUND);if(null==segment)return OMapping(null,null,null,null);if(1==segment.length)return OMapping(null,null,null,null);const{names,resolvedSources}=map;return OMapping(resolvedSources[segment[SOURCES_INDEX]],segment[SOURCE_LINE]+1,segment[SOURCE_COLUMN],5===segment.length?names[segment[NAMES_INDEX]]:null)},exports.generatedPositionFor=(map,{source,line,column,bias})=>{if(--line<0)throw new Error(LINE_GTR_ZERO);if(column<0)throw new Error(COL_GTR_EQ_ZERO);const{sources,resolvedSources}=map;let sourceIndex=sources.indexOf(source);if(-1===sourceIndex&&(sourceIndex=resolvedSources.indexOf(source)),-1===sourceIndex)return GMapping(null,null);const generated=map._bySources||(map._bySources=buildBySources(exports.decodedMappings(map),map._bySourceMemos=sources.map(memoizedState))),memos=map._bySourceMemos,segments=generated[sourceIndex][line];if(null==segments)return GMapping(null,null);const segment=traceSegmentInternal(segments,memos[sourceIndex],line,column,bias||GREATEST_LOWER_BOUND);return null==segment?GMapping(null,null):GMapping(segment[REV_GENERATED_LINE]+1,segment[REV_GENERATED_COLUMN])},exports.eachMapping=(map,cb)=>{const decoded=exports.decodedMappings(map),{names,resolvedSources}=map;for(let i=0;i{const{sources,resolvedSources,sourcesContent}=map;if(null==sourcesContent)return null;let index=sources.indexOf(source);return-1===index&&(index=resolvedSources.indexOf(source)),-1===index?null:sourcesContent[index]},exports.presortedDecodedMap=(map,mapUrl)=>{const tracer=new TraceMap(clone(map,[]),mapUrl);return tracer._decoded=map.mappings,tracer},exports.decodedMap=map=>clone(map,exports.decodedMappings(map)),exports.encodedMap=map=>clone(map,exports.encodedMappings(map)),exports.AnyMap=AnyMap,exports.GREATEST_LOWER_BOUND=GREATEST_LOWER_BOUND,exports.LEAST_UPPER_BOUND=LEAST_UPPER_BOUND,exports.TraceMap=TraceMap,Object.defineProperty(exports,\"__esModule\",{value:!0})}(exports,__webpack_require__(\"./node_modules/.pnpm/@jridgewell+sourcemap-codec@1.4.13/node_modules/@jridgewell/sourcemap-codec/dist/sourcemap-codec.umd.js\"),__webpack_require__(\"./node_modules/.pnpm/@jridgewell+resolve-uri@3.0.7/node_modules/@jridgewell/resolve-uri/dist/resolve-uri.umd.js\"))},\"./node_modules/.pnpm/babel-plugin-dynamic-import-node@2.3.3/node_modules/babel-plugin-dynamic-import-node/lib/index.js\":(module,exports,__webpack_require__)=>{\"use strict\";Object.defineProperty(exports,\"__esModule\",{value:!0}),exports.default=function(api){var transformImport=(0,_utils.createDynamicImportTransform)(api);return{manipulateOptions:function(opts,parserOpts){parserOpts.plugins.push(\"dynamicImport\")},visitor:{Import:function(path){transformImport(this,path)}}}};var _utils=__webpack_require__(\"./node_modules/.pnpm/babel-plugin-dynamic-import-node@2.3.3/node_modules/babel-plugin-dynamic-import-node/lib/utils.js\");module.exports=exports.default},\"./node_modules/.pnpm/babel-plugin-dynamic-import-node@2.3.3/node_modules/babel-plugin-dynamic-import-node/lib/utils.js\":(__unused_webpack_module,exports)=>{\"use strict\";Object.defineProperty(exports,\"__esModule\",{value:!0});var _slicedToArray=function(arr,i){if(Array.isArray(arr))return arr;if(Symbol.iterator in Object(arr))return function(arr,i){var _arr=[],_n=!0,_d=!1,_e=void 0;try{for(var _s,_i=arr[Symbol.iterator]();!(_n=(_s=_i.next()).done)&&(_arr.push(_s.value),!i||_arr.length!==i);_n=!0);}catch(err){_d=!0,_e=err}finally{try{!_n&&_i.return&&_i.return()}finally{if(_d)throw _e}}return _arr}(arr,i);throw new TypeError(\"Invalid attempt to destructure non-iterable instance\")};function getImportSource(t,callNode){var importArguments=callNode.arguments,importPath=_slicedToArray(importArguments,1)[0];return t.isStringLiteral(importPath)||t.isTemplateLiteral(importPath)?(t.removeComments(importPath),importPath):t.templateLiteral([t.templateElement({raw:\"\",cooked:\"\"}),t.templateElement({raw:\"\",cooked:\"\"},!0)],importArguments)}exports.getImportSource=getImportSource,exports.createDynamicImportTransform=function(_ref){var template=_ref.template,t=_ref.types,builders={static:{interop:template(\"Promise.resolve().then(() => INTEROP(require(SOURCE)))\"),noInterop:template(\"Promise.resolve().then(() => require(SOURCE))\")},dynamic:{interop:template(\"Promise.resolve(SOURCE).then(s => INTEROP(require(s)))\"),noInterop:template(\"Promise.resolve(SOURCE).then(s => require(s))\")}},visited=\"function\"==typeof WeakSet&&new WeakSet;return function(context,path){if(visited){if(visited.has(path))return;visited.add(path)}var node,SOURCE=getImportSource(t,path.parent),builder=(node=SOURCE,t.isStringLiteral(node)||t.isTemplateLiteral(node)&&0===node.expressions.length?builders.static:builders.dynamic),newImport=context.opts.noInterop?builder.noInterop({SOURCE}):builder.interop({SOURCE,INTEROP:context.addHelper(\"interopRequireWildcard\")});path.parentPath.replaceWith(newImport)}}},\"./node_modules/.pnpm/babel-plugin-dynamic-import-node@2.3.3/node_modules/babel-plugin-dynamic-import-node/utils.js\":(module,__unused_webpack_exports,__webpack_require__)=>{module.exports=__webpack_require__(\"./node_modules/.pnpm/babel-plugin-dynamic-import-node@2.3.3/node_modules/babel-plugin-dynamic-import-node/lib/utils.js\")},\"./node_modules/.pnpm/babel-plugin-parameter-decorator@1.0.16/node_modules/babel-plugin-parameter-decorator/lib/index.js\":(module,__unused_webpack_exports,__webpack_require__)=>{\"use strict\";var _path=__webpack_require__(\"path\");function isInType(path){switch(path.parent.type){case\"TSTypeReference\":case\"TSQualifiedName\":case\"TSExpressionWithTypeArguments\":case\"TSTypeQuery\":return!0;default:return!1}}module.exports=function(_ref){var types=_ref.types,decoratorExpressionForConstructor=function(decorator,param){return function(className){var resultantDecorator=types.callExpression(decorator.expression,[types.Identifier(className),types.Identifier(\"undefined\"),types.NumericLiteral(param.key)]),resultantDecoratorWithFallback=types.logicalExpression(\"||\",resultantDecorator,types.Identifier(className)),assignment=types.assignmentExpression(\"=\",types.Identifier(className),resultantDecoratorWithFallback);return types.expressionStatement(assignment)}},decoratorExpressionForMethod=function(decorator,param){return function(className,functionName){var resultantDecorator=types.callExpression(decorator.expression,[types.Identifier(\"\".concat(className,\".prototype\")),types.StringLiteral(functionName),types.NumericLiteral(param.key)]);return types.expressionStatement(resultantDecorator)}};return{visitor:{Program:function(path,state){var extension=(0,_path.extname)(state.file.opts.filename);\".ts\"!==extension&&\".tsx\"!==extension||function(){var decorators=Object.create(null);path.node.body.filter((function(it){var type=it.type,declaration=it.declaration;switch(type){case\"ClassDeclaration\":return!0;case\"ExportNamedDeclaration\":case\"ExportDefaultDeclaration\":return declaration&&\"ClassDeclaration\"===declaration.type;default:return!1}})).map((function(it){return\"ClassDeclaration\"===it.type?it:it.declaration})).forEach((function(clazz){clazz.body.body.forEach((function(body){(body.params||[]).forEach((function(param){(param.decorators||[]).forEach((function(decorator){decorator.expression.callee?decorators[decorator.expression.callee.name]=decorator:decorators[decorator.expression.name]=decorator}))}))}))}));var _iteratorNormalCompletion=!0,_didIteratorError=!1,_iteratorError=void 0;try{for(var _step,_iterator=path.get(\"body\")[Symbol.iterator]();!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=!0){var stmt=_step.value;if(\"ImportDeclaration\"===stmt.node.type){if(0===stmt.node.specifiers.length)continue;var _iteratorNormalCompletion2=!0,_didIteratorError2=!1,_iteratorError2=void 0;try{for(var _step2,_loop=function(){var specifier=_step2.value,binding=stmt.scope.getBinding(specifier.local.name);binding.referencePaths.length?binding.referencePaths.reduce((function(prev,next){return prev||isInType(next)}),!1)&&Object.keys(decorators).forEach((function(k){var decorator=decorators[k];(decorator.expression.arguments||[]).forEach((function(arg){arg.name===specifier.local.name&&binding.referencePaths.push({parent:decorator.expression})}))})):decorators[specifier.local.name]&&binding.referencePaths.push({parent:decorators[specifier.local.name]})},_iterator2=stmt.node.specifiers[Symbol.iterator]();!(_iteratorNormalCompletion2=(_step2=_iterator2.next()).done);_iteratorNormalCompletion2=!0)_loop()}catch(err){_didIteratorError2=!0,_iteratorError2=err}finally{try{_iteratorNormalCompletion2||null==_iterator2.return||_iterator2.return()}finally{if(_didIteratorError2)throw _iteratorError2}}}}}catch(err){_didIteratorError=!0,_iteratorError=err}finally{try{_iteratorNormalCompletion||null==_iterator.return||_iterator.return()}finally{if(_didIteratorError)throw _iteratorError}}}()},Function:function(path){var functionName=\"\";path.node.id?functionName=path.node.id.name:path.node.key&&(functionName=path.node.key.name),(path.get(\"params\")||[]).slice().forEach((function(param){var decorators=param.node.decorators||[],transformable=decorators.length;if(decorators.slice().forEach((function(decorator){if(\"ClassMethod\"===path.type){var classIdentifier,parentNode=path.parentPath.parentPath,classDeclaration=path.findParent((function(p){return\"ClassDeclaration\"===p.type}));if(classDeclaration?classIdentifier=classDeclaration.node.id.name:(parentNode.insertAfter(null),classIdentifier=function(path){var assignment=path.findParent((function(p){return\"AssignmentExpression\"===p.node.type}));return\"SequenceExpression\"===assignment.node.right.type?assignment.node.right.expressions[1].name:\"ClassExpression\"===assignment.node.right.type?assignment.node.left.name:null}(path)),\"constructor\"===functionName){var expression=decoratorExpressionForConstructor(decorator,param)(classIdentifier);parentNode.insertAfter(expression)}else{var _expression=decoratorExpressionForMethod(decorator,param)(classIdentifier,functionName);parentNode.insertAfter(_expression)}}else{var className=path.findParent((function(p){return\"VariableDeclarator\"===p.node.type})).node.id.name;if(functionName===className){var _expression2=decoratorExpressionForConstructor(decorator,param)(className);if(\"body\"===path.parentKey)path.insertAfter(_expression2);else path.findParent((function(p){return\"body\"===p.parentKey})).insertAfter(_expression2)}else{var classParent=path.findParent((function(p){return\"CallExpression\"===p.node.type})),_expression3=decoratorExpressionForMethod(decorator,param)(className,functionName);classParent.insertAfter(_expression3)}}})),transformable){var replacement=function(path){switch(path.node.type){case\"ObjectPattern\":return types.ObjectPattern(path.node.properties);case\"AssignmentPattern\":return types.AssignmentPattern(path.node.left,path.node.right);case\"TSParameterProperty\":return types.Identifier(path.node.parameter.name);default:return types.Identifier(path.node.name)}}(param);param.replaceWith(replacement)}}))}}}}},\"./node_modules/.pnpm/convert-source-map@1.8.0/node_modules/convert-source-map/index.js\":(__unused_webpack_module,exports,__webpack_require__)=>{\"use strict\";var fs=__webpack_require__(\"fs\"),path=__webpack_require__(\"path\"),SafeBuffer=__webpack_require__(\"./node_modules/.pnpm/safe-buffer@5.1.2/node_modules/safe-buffer/index.js\");function Converter(sm,opts){var base64;(opts=opts||{}).isFileComment&&(sm=function(sm,dir){var r=exports.mapFileCommentRegex.exec(sm),filename=r[1]||r[2],filepath=path.resolve(dir,filename);try{return fs.readFileSync(filepath,\"utf8\")}catch(e){throw new Error(\"An error occurred while trying to read the map file at \"+filepath+\"\\n\"+e)}}(sm,opts.commentFileDir)),opts.hasComment&&(sm=function(sm){return sm.split(\",\").pop()}(sm)),opts.isEncoded&&(base64=sm,sm=(SafeBuffer.Buffer.from(base64,\"base64\")||\"\").toString()),(opts.isJSON||opts.isEncoded)&&(sm=JSON.parse(sm)),this.sourcemap=sm}Object.defineProperty(exports,\"commentRegex\",{get:function(){return/^\\s*\\/(?:\\/|\\*)[@#]\\s+sourceMappingURL=data:(?:application|text)\\/json;(?:charset[:=]\\S+?;)?base64,(?:.*)$/gm}}),Object.defineProperty(exports,\"mapFileCommentRegex\",{get:function(){return/(?:\\/\\/[@#][ \\t]+sourceMappingURL=([^\\s'\"`]+?)[ \\t]*$)|(?:\\/\\*[@#][ \\t]+sourceMappingURL=([^\\*]+?)[ \\t]*(?:\\*\\/){1}[ \\t]*$)/gm}}),Converter.prototype.toJSON=function(space){return JSON.stringify(this.sourcemap,null,space)},Converter.prototype.toBase64=function(){var json=this.toJSON();return(SafeBuffer.Buffer.from(json,\"utf8\")||\"\").toString(\"base64\")},Converter.prototype.toComment=function(options){var data=\"sourceMappingURL=data:application/json;charset=utf-8;base64,\"+this.toBase64();return options&&options.multiline?\"/*# \"+data+\" */\":\"//# \"+data},Converter.prototype.toObject=function(){return JSON.parse(this.toJSON())},Converter.prototype.addProperty=function(key,value){if(this.sourcemap.hasOwnProperty(key))throw new Error('property \"'+key+'\" already exists on the sourcemap, use set property instead');return this.setProperty(key,value)},Converter.prototype.setProperty=function(key,value){return this.sourcemap[key]=value,this},Converter.prototype.getProperty=function(key){return this.sourcemap[key]},exports.fromObject=function(obj){return new Converter(obj)},exports.fromJSON=function(json){return new Converter(json,{isJSON:!0})},exports.fromBase64=function(base64){return new Converter(base64,{isEncoded:!0})},exports.fromComment=function(comment){return new Converter(comment=comment.replace(/^\\/\\*/g,\"//\").replace(/\\*\\/$/g,\"\"),{isEncoded:!0,hasComment:!0})},exports.fromMapFileComment=function(comment,dir){return new Converter(comment,{commentFileDir:dir,isFileComment:!0,isJSON:!0})},exports.fromSource=function(content){var m=content.match(exports.commentRegex);return m?exports.fromComment(m.pop()):null},exports.fromMapFileSource=function(content,dir){var m=content.match(exports.mapFileCommentRegex);return m?exports.fromMapFileComment(m.pop(),dir):null},exports.removeComments=function(src){return src.replace(exports.commentRegex,\"\")},exports.removeMapFileComments=function(src){return src.replace(exports.mapFileCommentRegex,\"\")},exports.generateMapFileComment=function(file,options){var data=\"sourceMappingURL=\"+file;return options&&options.multiline?\"/*# \"+data+\" */\":\"//# \"+data}},\"./node_modules/.pnpm/debug@4.3.4/node_modules/debug/src/browser.js\":(module,exports,__webpack_require__)=>{exports.formatArgs=function(args){if(args[0]=(this.useColors?\"%c\":\"\")+this.namespace+(this.useColors?\" %c\":\" \")+args[0]+(this.useColors?\"%c \":\" \")+\"+\"+module.exports.humanize(this.diff),!this.useColors)return;const c=\"color: \"+this.color;args.splice(1,0,c,\"color: inherit\");let index=0,lastC=0;args[0].replace(/%[a-zA-Z%]/g,(match=>{\"%%\"!==match&&(index++,\"%c\"===match&&(lastC=index))})),args.splice(lastC,0,c)},exports.save=function(namespaces){try{namespaces?exports.storage.setItem(\"debug\",namespaces):exports.storage.removeItem(\"debug\")}catch(error){}},exports.load=function(){let r;try{r=exports.storage.getItem(\"debug\")}catch(error){}!r&&\"undefined\"!=typeof process&&\"env\"in process&&(r=process.env.DEBUG);return r},exports.useColors=function(){if(\"undefined\"!=typeof window&&window.process&&(\"renderer\"===window.process.type||window.process.__nwjs))return!0;if(\"undefined\"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\\/(\\d+)/))return!1;return\"undefined\"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||\"undefined\"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||\"undefined\"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\\/(\\d+)/)&&parseInt(RegExp.$1,10)>=31||\"undefined\"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\\/(\\d+)/)},exports.storage=function(){try{return localStorage}catch(error){}}(),exports.destroy=(()=>{let warned=!1;return()=>{warned||(warned=!0,console.warn(\"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.\"))}})(),exports.colors=[\"#0000CC\",\"#0000FF\",\"#0033CC\",\"#0033FF\",\"#0066CC\",\"#0066FF\",\"#0099CC\",\"#0099FF\",\"#00CC00\",\"#00CC33\",\"#00CC66\",\"#00CC99\",\"#00CCCC\",\"#00CCFF\",\"#3300CC\",\"#3300FF\",\"#3333CC\",\"#3333FF\",\"#3366CC\",\"#3366FF\",\"#3399CC\",\"#3399FF\",\"#33CC00\",\"#33CC33\",\"#33CC66\",\"#33CC99\",\"#33CCCC\",\"#33CCFF\",\"#6600CC\",\"#6600FF\",\"#6633CC\",\"#6633FF\",\"#66CC00\",\"#66CC33\",\"#9900CC\",\"#9900FF\",\"#9933CC\",\"#9933FF\",\"#99CC00\",\"#99CC33\",\"#CC0000\",\"#CC0033\",\"#CC0066\",\"#CC0099\",\"#CC00CC\",\"#CC00FF\",\"#CC3300\",\"#CC3333\",\"#CC3366\",\"#CC3399\",\"#CC33CC\",\"#CC33FF\",\"#CC6600\",\"#CC6633\",\"#CC9900\",\"#CC9933\",\"#CCCC00\",\"#CCCC33\",\"#FF0000\",\"#FF0033\",\"#FF0066\",\"#FF0099\",\"#FF00CC\",\"#FF00FF\",\"#FF3300\",\"#FF3333\",\"#FF3366\",\"#FF3399\",\"#FF33CC\",\"#FF33FF\",\"#FF6600\",\"#FF6633\",\"#FF9900\",\"#FF9933\",\"#FFCC00\",\"#FFCC33\"],exports.log=console.debug||console.log||(()=>{}),module.exports=__webpack_require__(\"./node_modules/.pnpm/debug@4.3.4/node_modules/debug/src/common.js\")(exports);const{formatters}=module.exports;formatters.j=function(v){try{return JSON.stringify(v)}catch(error){return\"[UnexpectedJSONParseError]: \"+error.message}}},\"./node_modules/.pnpm/debug@4.3.4/node_modules/debug/src/common.js\":(module,__unused_webpack_exports,__webpack_require__)=>{module.exports=function(env){function createDebug(namespace){let prevTime,namespacesCache,enabledCache,enableOverride=null;function debug(...args){if(!debug.enabled)return;const self=debug,curr=Number(new Date),ms=curr-(prevTime||curr);self.diff=ms,self.prev=prevTime,self.curr=curr,prevTime=curr,args[0]=createDebug.coerce(args[0]),\"string\"!=typeof args[0]&&args.unshift(\"%O\");let index=0;args[0]=args[0].replace(/%([a-zA-Z%])/g,((match,format)=>{if(\"%%\"===match)return\"%\";index++;const formatter=createDebug.formatters[format];if(\"function\"==typeof formatter){const val=args[index];match=formatter.call(self,val),args.splice(index,1),index--}return match})),createDebug.formatArgs.call(self,args);(self.log||createDebug.log).apply(self,args)}return debug.namespace=namespace,debug.useColors=createDebug.useColors(),debug.color=createDebug.selectColor(namespace),debug.extend=extend,debug.destroy=createDebug.destroy,Object.defineProperty(debug,\"enabled\",{enumerable:!0,configurable:!1,get:()=>null!==enableOverride?enableOverride:(namespacesCache!==createDebug.namespaces&&(namespacesCache=createDebug.namespaces,enabledCache=createDebug.enabled(namespace)),enabledCache),set:v=>{enableOverride=v}}),\"function\"==typeof createDebug.init&&createDebug.init(debug),debug}function extend(namespace,delimiter){const newDebug=createDebug(this.namespace+(void 0===delimiter?\":\":delimiter)+namespace);return newDebug.log=this.log,newDebug}function toNamespace(regexp){return regexp.toString().substring(2,regexp.toString().length-2).replace(/\\.\\*\\?$/,\"*\")}return createDebug.debug=createDebug,createDebug.default=createDebug,createDebug.coerce=function(val){if(val instanceof Error)return val.stack||val.message;return val},createDebug.disable=function(){const namespaces=[...createDebug.names.map(toNamespace),...createDebug.skips.map(toNamespace).map((namespace=>\"-\"+namespace))].join(\",\");return createDebug.enable(\"\"),namespaces},createDebug.enable=function(namespaces){let i;createDebug.save(namespaces),createDebug.namespaces=namespaces,createDebug.names=[],createDebug.skips=[];const split=(\"string\"==typeof namespaces?namespaces:\"\").split(/[\\s,]+/),len=split.length;for(i=0;i{createDebug[key]=env[key]})),createDebug.names=[],createDebug.skips=[],createDebug.formatters={},createDebug.selectColor=function(namespace){let hash=0;for(let i=0;i{\"undefined\"==typeof process||\"renderer\"===process.type||!0===process.browser||process.__nwjs?module.exports=__webpack_require__(\"./node_modules/.pnpm/debug@4.3.4/node_modules/debug/src/browser.js\"):module.exports=__webpack_require__(\"./node_modules/.pnpm/debug@4.3.4/node_modules/debug/src/node.js\")},\"./node_modules/.pnpm/debug@4.3.4/node_modules/debug/src/node.js\":(module,exports,__webpack_require__)=>{const tty=__webpack_require__(\"tty\"),util=__webpack_require__(\"util\");exports.init=function(debug){debug.inspectOpts={};const keys=Object.keys(exports.inspectOpts);for(let i=0;i{}),\"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.\"),exports.colors=[6,2,3,4,5,1];try{const supportsColor=__webpack_require__(\"./node_modules/.pnpm/supports-color@5.5.0/node_modules/supports-color/index.js\");supportsColor&&(supportsColor.stderr||supportsColor).level>=2&&(exports.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221])}catch(error){}exports.inspectOpts=Object.keys(process.env).filter((key=>/^debug_/i.test(key))).reduce(((obj,key)=>{const prop=key.substring(6).toLowerCase().replace(/_([a-z])/g,((_,k)=>k.toUpperCase()));let val=process.env[key];return val=!!/^(yes|on|true|enabled)$/i.test(val)||!/^(no|off|false|disabled)$/i.test(val)&&(\"null\"===val?null:Number(val)),obj[prop]=val,obj}),{}),module.exports=__webpack_require__(\"./node_modules/.pnpm/debug@4.3.4/node_modules/debug/src/common.js\")(exports);const{formatters}=module.exports;formatters.o=function(v){return this.inspectOpts.colors=this.useColors,util.inspect(v,this.inspectOpts).split(\"\\n\").map((str=>str.trim())).join(\" \")},formatters.O=function(v){return this.inspectOpts.colors=this.useColors,util.inspect(v,this.inspectOpts)}},\"./node_modules/.pnpm/gensync@1.0.0-beta.2/node_modules/gensync/index.js\":module=>{\"use strict\";const GENSYNC_START=Symbol.for(\"gensync:v1:start\"),GENSYNC_SUSPEND=Symbol.for(\"gensync:v1:suspend\");function assertTypeof(type,name,value,allowUndefined){if(typeof value===type||allowUndefined&&void 0===value)return;let msg;throw msg=allowUndefined?`Expected opts.${name} to be either a ${type}, or undefined.`:`Expected opts.${name} to be a ${type}.`,makeError(msg,\"GENSYNC_OPTIONS_ERROR\")}function makeError(msg,code){return Object.assign(new Error(msg),{code})}function buildOperation({name,arity,sync,async}){return setFunctionMetadata(name,arity,(function*(...args){const resume=yield GENSYNC_START;if(!resume){return sync.call(this,args)}let result;try{async.call(this,args,(value=>{result||(result={value},resume())}),(err=>{result||(result={err},resume())}))}catch(err){result={err},resume()}if(yield GENSYNC_SUSPEND,result.hasOwnProperty(\"err\"))throw result.err;return result.value}))}function evaluateSync(gen){let value;for(;!({value}=gen.next()).done;)assertStart(value,gen);return value}function evaluateAsync(gen,resolve,reject){!function step(){try{let value;for(;!({value}=gen.next()).done;){assertStart(value,gen);let sync=!0,didSyncResume=!1;const out=gen.next((()=>{sync?didSyncResume=!0:step()}));if(sync=!1,assertSuspend(out,gen),!didSyncResume)return}return resolve(value)}catch(err){return reject(err)}}()}function assertStart(value,gen){value!==GENSYNC_START&&throwError(gen,makeError(`Got unexpected yielded value in gensync generator: ${JSON.stringify(value)}. Did you perhaps mean to use 'yield*' instead of 'yield'?`,\"GENSYNC_EXPECTED_START\"))}function assertSuspend({value,done},gen){(done||value!==GENSYNC_SUSPEND)&&throwError(gen,makeError(done?\"Unexpected generator completion. If you get this, it is probably a gensync bug.\":`Expected GENSYNC_SUSPEND, got ${JSON.stringify(value)}. If you get this, it is probably a gensync bug.`,\"GENSYNC_EXPECTED_SUSPEND\"))}function throwError(gen,err){throw gen.throw&&gen.throw(err),err}function setFunctionMetadata(name,arity,fn){if(\"string\"==typeof name){const nameDesc=Object.getOwnPropertyDescriptor(fn,\"name\");nameDesc&&!nameDesc.configurable||Object.defineProperty(fn,\"name\",Object.assign(nameDesc||{},{configurable:!0,value:name}))}if(\"number\"==typeof arity){const lengthDesc=Object.getOwnPropertyDescriptor(fn,\"length\");lengthDesc&&!lengthDesc.configurable||Object.defineProperty(fn,\"length\",Object.assign(lengthDesc||{},{configurable:!0,value:arity}))}return fn}module.exports=Object.assign((function(optsOrFn){let genFn=optsOrFn;return genFn=\"function\"!=typeof optsOrFn?function({name,arity,sync,async,errback}){if(assertTypeof(\"string\",\"name\",name,!0),assertTypeof(\"number\",\"arity\",arity,!0),assertTypeof(\"function\",\"sync\",sync),assertTypeof(\"function\",\"async\",async,!0),assertTypeof(\"function\",\"errback\",errback,!0),async&&errback)throw makeError(\"Expected one of either opts.async or opts.errback, but got _both_.\",\"GENSYNC_OPTIONS_ERROR\");if(\"string\"!=typeof name){let fnName;errback&&errback.name&&\"errback\"!==errback.name&&(fnName=errback.name),async&&async.name&&\"async\"!==async.name&&(fnName=async.name.replace(/Async$/,\"\")),sync&&sync.name&&\"sync\"!==sync.name&&(fnName=sync.name.replace(/Sync$/,\"\")),\"string\"==typeof fnName&&(name=fnName)}\"number\"!=typeof arity&&(arity=sync.length);return buildOperation({name,arity,sync:function(args){return sync.apply(this,args)},async:function(args,resolve,reject){async?async.apply(this,args).then(resolve,reject):errback?errback.call(this,...args,((err,value)=>{null==err?resolve(value):reject(err)})):resolve(sync.apply(this,args))}})}(optsOrFn):function(genFn){return setFunctionMetadata(genFn.name,genFn.length,(function(...args){return genFn.apply(this,args)}))}(optsOrFn),Object.assign(genFn,function(genFn){return{sync:function(...args){return evaluateSync(genFn.apply(this,args))},async:function(...args){return new Promise(((resolve,reject)=>{evaluateAsync(genFn.apply(this,args),resolve,reject)}))},errback:function(...args){const cb=args.pop();if(\"function\"!=typeof cb)throw makeError(\"Asynchronous function called without callback\",\"GENSYNC_ERRBACK_NO_CALLBACK\");let gen;try{gen=genFn.apply(this,args)}catch(err){return void cb(err)}evaluateAsync(gen,(val=>cb(void 0,val)),(err=>cb(err)))}}}(genFn))}),{all:buildOperation({name:\"all\",arity:1,sync:function(args){return Array.from(args[0]).map((item=>evaluateSync(item)))},async:function(args,resolve,reject){const items=Array.from(args[0]);if(0===items.length)return void Promise.resolve().then((()=>resolve([])));let count=0;const results=items.map((()=>{}));items.forEach(((item,i)=>{evaluateAsync(item,(val=>{results[i]=val,count+=1,count===results.length&&resolve(results)}),reject)}))}}),race:buildOperation({name:\"race\",arity:1,sync:function(args){const items=Array.from(args[0]);if(0===items.length)throw makeError(\"Must race at least 1 item\",\"GENSYNC_RACE_NONEMPTY\");return evaluateSync(items[0])},async:function(args,resolve,reject){const items=Array.from(args[0]);if(0===items.length)throw makeError(\"Must race at least 1 item\",\"GENSYNC_RACE_NONEMPTY\");for(const item of items)evaluateAsync(item,resolve,reject)}})})},\"./node_modules/.pnpm/globals@11.12.0/node_modules/globals/index.js\":(module,__unused_webpack_exports,__webpack_require__)=>{\"use strict\";module.exports=__webpack_require__(\"./node_modules/.pnpm/globals@11.12.0/node_modules/globals/globals.json\")},\"./node_modules/.pnpm/has-flag@3.0.0/node_modules/has-flag/index.js\":module=>{\"use strict\";module.exports=(flag,argv)=>{argv=argv||process.argv;const prefix=flag.startsWith(\"-\")?\"\":1===flag.length?\"-\":\"--\",pos=argv.indexOf(prefix+flag),terminatorPos=argv.indexOf(\"--\");return-1!==pos&&(-1===terminatorPos||pos{\"use strict\";const object={},hasOwnProperty=object.hasOwnProperty,forOwn=(object,callback)=>{for(const key in object)hasOwnProperty.call(object,key)&&callback(key,object[key])},toString=object.toString,isArray=Array.isArray,isBuffer=Buffer.isBuffer,singleEscapes={'\"':'\\\\\"',\"'\":\"\\\\'\",\"\\\\\":\"\\\\\\\\\",\"\\b\":\"\\\\b\",\"\\f\":\"\\\\f\",\"\\n\":\"\\\\n\",\"\\r\":\"\\\\r\",\"\\t\":\"\\\\t\"},regexSingleEscape=/[\"'\\\\\\b\\f\\n\\r\\t]/,regexDigit=/[0-9]/,regexWhitelist=/[ !#-&\\(-\\[\\]-_a-~]/,jsesc=(argument,options)=>{const increaseIndentation=()=>{oldIndent=indent,++options.indentLevel,indent=options.indent.repeat(options.indentLevel)},defaults={escapeEverything:!1,minimal:!1,isScriptContext:!1,quotes:\"single\",wrap:!1,es6:!1,json:!1,compact:!0,lowercaseHex:!1,numbers:\"decimal\",indent:\"\\t\",indentLevel:0,__inline1__:!1,__inline2__:!1},json=options&&options.json;var destination,source;json&&(defaults.quotes=\"double\",defaults.wrap=!0),destination=defaults,options=(source=options)?(forOwn(source,((key,value)=>{destination[key]=value})),destination):destination,\"single\"!=options.quotes&&\"double\"!=options.quotes&&\"backtick\"!=options.quotes&&(options.quotes=\"single\");const quote=\"double\"==options.quotes?'\"':\"backtick\"==options.quotes?\"`\":\"'\",compact=options.compact,lowercaseHex=options.lowercaseHex;let indent=options.indent.repeat(options.indentLevel),oldIndent=\"\";const inline1=options.__inline1__,inline2=options.__inline2__,newLine=compact?\"\":\"\\n\";let result,isEmpty=!0;const useBinNumbers=\"binary\"==options.numbers,useOctNumbers=\"octal\"==options.numbers,useDecNumbers=\"decimal\"==options.numbers,useHexNumbers=\"hexadecimal\"==options.numbers;if(json&&argument&&\"function\"==typeof argument.toJSON&&(argument=argument.toJSON()),!(value=>\"string\"==typeof value||\"[object String]\"==toString.call(value))(argument)){if((value=>\"[object Map]\"==toString.call(value))(argument))return 0==argument.size?\"new Map()\":(compact||(options.__inline1__=!0,options.__inline2__=!1),\"new Map(\"+jsesc(Array.from(argument),options)+\")\");if((value=>\"[object Set]\"==toString.call(value))(argument))return 0==argument.size?\"new Set()\":\"new Set(\"+jsesc(Array.from(argument),options)+\")\";if(isBuffer(argument))return 0==argument.length?\"Buffer.from([])\":\"Buffer.from(\"+jsesc(Array.from(argument),options)+\")\";if(isArray(argument))return result=[],options.wrap=!0,inline1&&(options.__inline1__=!1,options.__inline2__=!0),inline2||increaseIndentation(),((array,callback)=>{const length=array.length;let index=-1;for(;++index{isEmpty=!1,inline2&&(options.__inline2__=!1),result.push((compact||inline2?\"\":indent)+jsesc(value,options))})),isEmpty?\"[]\":inline2?\"[\"+result.join(\", \")+\"]\":\"[\"+newLine+result.join(\",\"+newLine)+newLine+(compact?\"\":oldIndent)+\"]\";if(!(value=>\"number\"==typeof value||\"[object Number]\"==toString.call(value))(argument))return(value=>\"[object Object]\"==toString.call(value))(argument)?(result=[],options.wrap=!0,increaseIndentation(),forOwn(argument,((key,value)=>{isEmpty=!1,result.push((compact?\"\":indent)+jsesc(key,options)+\":\"+(compact?\"\":\" \")+jsesc(value,options))})),isEmpty?\"{}\":\"{\"+newLine+result.join(\",\"+newLine)+newLine+(compact?\"\":oldIndent)+\"}\"):json?JSON.stringify(argument)||\"null\":String(argument);if(json)return JSON.stringify(argument);if(useDecNumbers)return String(argument);if(useHexNumbers){let hexadecimal=argument.toString(16);return lowercaseHex||(hexadecimal=hexadecimal.toUpperCase()),\"0x\"+hexadecimal}if(useBinNumbers)return\"0b\"+argument.toString(2);if(useOctNumbers)return\"0o\"+argument.toString(8)}const string=argument;let index=-1;const length=string.length;for(result=\"\";++index=55296&&first<=56319&&length>index+1){const second=string.charCodeAt(index+1);if(second>=56320&&second<=57343){let hexadecimal=(1024*(first-55296)+second-56320+65536).toString(16);lowercaseHex||(hexadecimal=hexadecimal.toUpperCase()),result+=\"\\\\u{\"+hexadecimal+\"}\",++index;continue}}}if(!options.escapeEverything){if(regexWhitelist.test(character)){result+=character;continue}if('\"'==character){result+=quote==character?'\\\\\"':character;continue}if(\"`\"==character){result+=quote==character?\"\\\\`\":character;continue}if(\"'\"==character){result+=quote==character?\"\\\\'\":character;continue}}if(\"\\0\"==character&&!json&&!regexDigit.test(string.charAt(index+1))){result+=\"\\\\0\";continue}if(regexSingleEscape.test(character)){result+=singleEscapes[character];continue}const charCode=character.charCodeAt(0);if(options.minimal&&8232!=charCode&&8233!=charCode){result+=character;continue}let hexadecimal=charCode.toString(16);lowercaseHex||(hexadecimal=hexadecimal.toUpperCase());const longhand=hexadecimal.length>2||json,escaped=\"\\\\\"+(longhand?\"u\":\"x\")+(\"0000\"+hexadecimal).slice(longhand?-4:-2);result+=escaped}return options.wrap&&(result=quote+result+quote),\"`\"==quote&&(result=result.replace(/\\$\\{/g,\"\\\\${\")),options.isScriptContext?result.replace(/<\\/(script|style)/gi,\"<\\\\/$1\").replace(/`;\n};\n", "import { getOctokit } from '@actions/github';\n\nimport { getReportTag } from '../constants/getReportTag';\nimport { Options } from '../typings/Options';\n\nexport async function fetchPreviousReport(\n octokit: ReturnType,\n repo: { owner: string; repo: string },\n pr: { number: number },\n options: Options\n) {\n const commentList = await octokit.paginate(\n 'GET /repos/{owner}/{repo}/issues/{issue_number}/comments',\n {\n ...repo,\n issue_number: pr.number,\n }\n );\n\n const previousReport = commentList.find((comment) =>\n comment.body?.startsWith(getReportTag(options))\n );\n\n return !previousReport ? null : previousReport;\n}\n", "import { getOctokit } from '@actions/github';\n\nimport { fetchPreviousReport } from './fetchPreviousReport';\nimport { Options } from '../typings/Options';\n\nexport const generatePRReport = async (\n report: string,\n options: Options,\n repo: { owner: string; repo: string },\n pr: { number: number },\n octokit: ReturnType\n) => {\n const previousReport = await fetchPreviousReport(\n octokit,\n repo,\n pr,\n options\n );\n\n if (previousReport) {\n await octokit.rest.issues.updateComment({\n ...repo,\n body: report,\n comment_id: previousReport.id,\n });\n } else {\n await octokit.rest.issues.createComment({\n ...repo,\n body: report,\n issue_number: pr.number,\n });\n }\n};\n", "import { dirname } from 'path';\r\n\r\nimport isNil from 'lodash/isNil';\r\nimport micromatch from 'micromatch';\r\n\r\nimport { JestThreshold } from '../typings/JestThreshold';\r\nimport { JsonReport } from '../typings/JsonReport';\r\nimport { FailReason } from '../typings/Report';\r\nimport { ThresholdResult } from '../typings/ThresholdResult';\r\nimport { accumulateCoverageDetails } from '../utils/accumulateCoverageDetails';\r\nimport { checkSingleThreshold } from '../utils/checkSingleThreshold';\r\nimport { DataCollector } from '../utils/DataCollector';\r\nimport { getCoverageForDirectory } from '../utils/getCoverageForDirectory';\r\nimport { getFileCoverageMap } from '../utils/getFileCoverageMap';\r\nimport { joinPaths } from '../utils/joinPaths';\r\n\r\nexport const checkThreshold = (\r\n report: JsonReport,\r\n threshold: JestThreshold,\r\n workingDirectory: string | undefined,\r\n dataCollector: DataCollector\r\n) => {\r\n const cwd = joinPaths(process.cwd(), workingDirectory);\r\n // Maybe somehow take this from \"format\" stage?\r\n const coverageDetailMap = Object.fromEntries(\r\n Object.entries(getFileCoverageMap(report)).map(([key, value]) => [\r\n key.substring(cwd.length + 1),\r\n value,\r\n ])\r\n );\r\n\r\n const dirSet = new Set();\r\n\r\n Object.keys(coverageDetailMap)\r\n .filter((value) => value === 'global')\r\n .forEach((value) => {\r\n let directory = dirname(value);\r\n\r\n while (directory !== '.') {\r\n dirSet.add(directory);\r\n directory = dirname(directory);\r\n }\r\n });\r\n\r\n const directories = Array.from(dirSet);\r\n\r\n const totalResults: ThresholdResult[] = [];\r\n\r\n Object.entries(threshold).forEach(([pattern, threshold]) => {\r\n const selectedDirectories = micromatch(directories, pattern);\r\n\r\n const coverageOfDirectories = selectedDirectories.map((directory) =>\r\n getCoverageForDirectory(directory, coverageDetailMap)\r\n );\r\n\r\n const thresholdResults = coverageOfDirectories.map((coverage, index) =>\r\n checkSingleThreshold(\r\n threshold,\r\n coverage,\r\n selectedDirectories[index]\r\n )\r\n );\r\n\r\n totalResults.push(\r\n ...(thresholdResults.filter(\r\n (value) => value !== undefined\r\n ) as ThresholdResult[])\r\n );\r\n });\r\n\r\n const files = Object.keys(coverageDetailMap);\r\n Object.entries(threshold).forEach(([pattern, threshold]) => {\r\n const selectedFiles = micromatch(files, pattern);\r\n\r\n const thresholdResults = selectedFiles.map((filename) =>\r\n checkSingleThreshold(\r\n threshold,\r\n coverageDetailMap[filename],\r\n filename\r\n )\r\n );\r\n\r\n totalResults.push(\r\n ...(thresholdResults.filter(\r\n (value) => value !== undefined\r\n ) as ThresholdResult[])\r\n );\r\n });\r\n\r\n if (!isNil(threshold.global)) {\r\n const uncheckedFiles = micromatch.not(\r\n files,\r\n Object.keys(threshold).concat(\r\n micromatch(directories, Object.keys(threshold)).map(\r\n (value) => `${value}/**`\r\n )\r\n )\r\n );\r\n\r\n const uncheckedTotal = accumulateCoverageDetails(\r\n uncheckedFiles.map((filename) => coverageDetailMap[filename])\r\n );\r\n\r\n const globalResult = checkSingleThreshold(\r\n threshold.global,\r\n uncheckedTotal,\r\n 'global'\r\n );\r\n\r\n if (globalResult) {\r\n totalResults.push(globalResult);\r\n }\r\n }\r\n\r\n if (totalResults.length > 0) {\r\n dataCollector.add(FailReason.UNDER_THRESHOLD);\r\n }\r\n\r\n return totalResults;\r\n};\r\n", "export enum FailReason {\n TESTS_FAILED = 'testsFailed',\n INVALID_COVERAGE_FORMAT = 'invalidFormat',\n UNDER_THRESHOLD = 'underThreshold',\n UNKNOWN_ERROR = 'unknownError',\n REPORT_NOT_FOUND = 'reportNotFound',\n READING_COVERAGE_FILE_FAILED = 'readingCoverageFileFailed',\n FAILED_GETTING_COVERAGE = 'failedGettingCoverage',\n}\n\nexport type TestRunReport = {\n title: string;\n summary: string;\n failures?: string;\n};\n\nexport type SummaryReport = {\n text: string;\n runReport: TestRunReport;\n};\n", "import { DetailedFileCoverage } from './getFileCoverageMap';\r\n\r\nexport const accumulateCoverageDetails = (\r\n coverageDetails: DetailedFileCoverage[]\r\n): DetailedFileCoverage =>\r\n coverageDetails.reduce(\r\n (acc, current) => {\r\n acc.totalStatements += current.totalStatements;\r\n acc.coveredStatements += current.coveredStatements;\r\n acc.totalFunctions += current.totalFunctions;\r\n acc.coveredFunctions += current.coveredFunctions;\r\n acc.totalBranches += current.totalBranches;\r\n acc.coveredBranches += current.coveredBranches;\r\n acc.totalLines += current.totalLines;\r\n acc.coveredLines += current.coveredLines;\r\n\r\n return acc;\r\n },\r\n {\r\n totalStatements: 0,\r\n coveredStatements: 0,\r\n totalFunctions: 0,\r\n coveredFunctions: 0,\r\n totalBranches: 0,\r\n coveredBranches: 0,\r\n totalLines: 0,\r\n coveredLines: 0,\r\n }\r\n );\r\n", "import isNil from 'lodash/isNil';\r\n\r\nimport { DetailedFileCoverage } from './getFileCoverageMap';\r\nimport { getPercents } from '../format/getPercents';\r\nimport { SingleThreshold } from '../typings/JestThreshold';\r\nimport { ThresholdResult, ThresholdType } from '../typings/ThresholdResult';\r\n\r\nexport const checkSingleThreshold = (\r\n threshold: SingleThreshold,\r\n coverage: DetailedFileCoverage,\r\n path: string\r\n): ThresholdResult | undefined => {\r\n const queue = [\r\n {\r\n total: coverage.totalStatements,\r\n covered: coverage.coveredStatements,\r\n threshold: threshold.statements,\r\n type: ThresholdType.STATEMENTS,\r\n },\r\n {\r\n total: coverage.totalBranches,\r\n covered: coverage.coveredBranches,\r\n threshold: threshold.branches,\r\n type: ThresholdType.BRANCHES,\r\n },\r\n {\r\n total: coverage.totalFunctions,\r\n covered: coverage.coveredFunctions,\r\n threshold: threshold.functions,\r\n type: ThresholdType.FUNCTIONS,\r\n },\r\n {\r\n total: coverage.totalLines,\r\n covered: coverage.coveredLines,\r\n threshold: threshold.lines,\r\n type: ThresholdType.LINES,\r\n },\r\n ];\r\n\r\n for (const { total, covered, threshold, type } of queue) {\r\n const result = checkSingleStat(total, covered, threshold, type, path);\r\n\r\n if (result) {\r\n return result;\r\n }\r\n }\r\n\r\n return undefined;\r\n};\r\n\r\nconst checkSingleStat = (\r\n total: number,\r\n covered: number,\r\n threshold: number | undefined,\r\n type: ThresholdType,\r\n path: string\r\n): ThresholdResult | undefined => {\r\n if (isNil(threshold)) {\r\n return undefined;\r\n }\r\n\r\n if (threshold >= 0) {\r\n const percents = getPercents(covered, total);\r\n\r\n return percents >= threshold\r\n ? undefined\r\n : {\r\n expected: threshold,\r\n received: percents,\r\n type,\r\n path,\r\n };\r\n }\r\n\r\n return covered >= -threshold\r\n ? undefined\r\n : {\r\n expected: threshold,\r\n received: covered,\r\n type,\r\n path,\r\n };\r\n};\r\n", "export const getPercents = (covered: number, total: number): number => {\n if (total === 0) return 100;\n\n return (covered / total) * 100;\n};\n", "export enum ThresholdType {\r\n STATEMENTS = 'statements',\r\n FUNCTIONS = 'functions',\r\n BRANCHES = 'branches',\r\n LINES = 'lines',\r\n}\r\n\r\nexport type ThresholdResult = {\r\n path: string;\r\n expected: number;\r\n received: number;\r\n type: ThresholdType;\r\n};\r\n", "import micromatch from 'micromatch';\r\n\r\nimport { accumulateCoverageDetails } from './accumulateCoverageDetails';\r\nimport { DetailedFileCoverage, FileCoverageMap } from './getFileCoverageMap';\r\n\r\nexport const getCoverageForDirectory = (\r\n directory: string,\r\n details: FileCoverageMap\r\n): DetailedFileCoverage => {\r\n const children = micromatch(Object.keys(details), `${directory}/**`);\r\n\r\n return accumulateCoverageDetails(children.map((child) => details[child]));\r\n};\r\n", "import { FileCoverage } from '../typings/JsonReport';\n\nexport const standardTotalCounter = (key: keyof FileCoverage) => (\n value: FileCoverage\n) => Object.values(value[key]).length;\n\nexport const standardCoveredCounter = (key: keyof FileCoverage) => (\n value: FileCoverage\n) => Object.values(value[key]).filter((hits) => hits > 0).length;\n\nexport const totalBranchesCounter = (value: FileCoverage) =>\n Object.values(value.b).reduce((acc, branch) => acc + branch.length, 0);\n\nexport const coveredBranchesCounter = (value: FileCoverage) =>\n Object.values(value.b).reduce(\n (acc, branch) => acc + branch.filter((hits) => hits > 0).length,\n 0\n );\n\nexport const totalLinesCounter = (value: FileCoverage) => {\n const stats: Record = getLineCoverage(value);\n return Object.keys(stats).length;\n};\n\nexport const coveredLinesCounter = (value: FileCoverage) => {\n const stats: Record = getLineCoverage(value);\n return Object.values(stats).filter((v) => !!v).length;\n};\n\nconst getLineCoverage = (value: FileCoverage) => {\n const statementMap = value.statementMap;\n const statements = value.s;\n\n return Object.entries(statements).reduce((acc, [st, count]) => {\n const _st: number = parseInt(st);\n\n if (!statementMap[_st]) {\n return acc;\n }\n const { line } = statementMap[_st].start;\n const prevVal = acc[line];\n if (prevVal === undefined || prevVal < count) {\n acc[line] = count;\n }\n return acc;\n }, {} as Record);\n};\n", "import {\r\n coveredBranchesCounter,\r\n coveredLinesCounter,\r\n standardCoveredCounter,\r\n standardTotalCounter,\r\n totalBranchesCounter,\r\n totalLinesCounter,\r\n} from '../format/counters';\r\nimport { JsonReport } from '../typings/JsonReport';\r\n\r\nexport type DetailedFileCoverage = {\r\n totalStatements: number;\r\n coveredStatements: number;\r\n totalFunctions: number;\r\n coveredFunctions: number;\r\n totalBranches: number;\r\n coveredBranches: number;\r\n totalLines: number;\r\n coveredLines: number;\r\n};\r\n\r\nexport type FileCoverageMap = Record;\r\n\r\nexport const getFileCoverageMap = (jsonReport: JsonReport) =>\r\n Object.entries(jsonReport.coverageMap).reduce(\r\n (acc, [filename, fileCoverage]) => {\r\n acc[filename] = {\r\n totalStatements: standardTotalCounter('s')(fileCoverage),\r\n coveredStatements: standardCoveredCounter('s')(fileCoverage),\r\n totalFunctions: standardTotalCounter('f')(fileCoverage),\r\n coveredFunctions: standardCoveredCounter('f')(fileCoverage),\r\n totalBranches: totalBranchesCounter(fileCoverage),\r\n coveredBranches: coveredBranchesCounter(fileCoverage),\r\n totalLines: totalLinesCounter(fileCoverage),\r\n coveredLines: coveredLinesCounter(fileCoverage),\r\n };\r\n return acc;\r\n },\r\n {}\r\n );\r\n", "import { join } from 'path';\n\nexport const joinPaths = (...segments: Array) =>\n join(...(segments as string[]).filter((segment) => segment !== undefined));\n", "import { context } from '@actions/github';\n\nimport { getReportTag } from '../constants/getReportTag';\nimport { GITHUB_MESSAGE_SIZE_LIMIT } from '../constants/GITHUB_MESSAGE_SIZE_LIMIT';\nimport { formatCoverage } from '../format/formatCoverage';\nimport { formatErrors } from '../format/formatErrors';\nimport { formatRunReport } from '../format/formatRunReport';\nimport { formatThresholdResults } from '../format/formatThresholdResults';\nimport { getFailureDetails } from '../format/getFailureDetails';\nimport { getTestRunSummary } from '../format/summary/getTestRunSummary';\nimport template from '../format/template.md';\nimport { JsonReport } from '../typings/JsonReport';\nimport { Options } from '../typings/Options';\nimport { SummaryReport, TestRunReport } from '../typings/Report';\nimport { ThresholdResult } from '../typings/ThresholdResult';\nimport { DataCollector } from '../utils/DataCollector';\nimport { i18n } from '../utils/i18n';\nimport { insertArgs } from '../utils/insertArgs';\n\nexport const getSha = () =>\n context.payload.after ??\n context.payload.pull_request?.head.sha ??\n context.sha;\n\nexport const createReport = (\n dataCollector: DataCollector,\n options: Options,\n thresholdResults: ThresholdResult[]\n): SummaryReport => {\n const { workingDirectory, customTitle } = options;\n\n const { errors, data } = dataCollector.get();\n const [headReport, baseReport] = data;\n const formattedErrors = formatErrors(errors);\n\n const formattedThresholdResults = formatThresholdResults(thresholdResults);\n const coverage = formatCoverage(headReport, baseReport, undefined, false);\n const runReport: TestRunReport = {\n title: i18n(headReport.success ? 'testsSuccess' : 'testsFail'),\n summary: getTestRunSummary(headReport),\n failures: getFailureDetails(headReport),\n };\n const formattedReport = formatRunReport(runReport);\n\n let templateText = insertArgs(template, {\n body: [\n formattedErrors,\n formattedThresholdResults,\n coverage,\n formattedReport,\n ].join('\\n'),\n dir: workingDirectory || '',\n tag: getReportTag(options),\n title: insertArgs(customTitle || i18n('summaryTitle'), {\n dir: workingDirectory ? `for \\`${workingDirectory}\\`` : '',\n }),\n sha: getSha(),\n });\n\n if (templateText.length > GITHUB_MESSAGE_SIZE_LIMIT) {\n const reducedCoverage = formatCoverage(\n headReport,\n baseReport,\n undefined,\n true\n );\n\n templateText = insertArgs(template, {\n body: [\n formattedErrors,\n formattedThresholdResults,\n reducedCoverage,\n formattedReport,\n ].join('\\n'),\n dir: workingDirectory || '',\n tag: getReportTag(options),\n title: insertArgs(customTitle || i18n('summaryTitle'), {\n dir: workingDirectory ? `for \\`${workingDirectory}\\`` : '',\n }),\n sha: getSha(),\n });\n }\n\n return {\n text: templateText,\n runReport,\n };\n};\n", "export const GITHUB_MESSAGE_SIZE_LIMIT = 65535;\n", "import { dirname } from 'path';\n\n/**\n * Find a common path from a list of filepaths.\n */\nexport const findCommonPath = (filepaths: string[]): string => {\n let commonRoot = '';\n if (filepaths.length) {\n // If the paths are sorted, any prefix common to all paths will be common to the sorted first and last strings.\n const sortedPaths = [...filepaths].sort();\n const first = sortedPaths[0];\n const last = sortedPaths[sortedPaths.length - 1];\n\n const len = Math.min(first.length, last.length);\n for (let i = 0; i < len; i++) {\n const ch1 = first[i];\n const ch2 = last[i];\n if (ch1 == ch2) {\n commonRoot += ch1;\n } else {\n break;\n }\n }\n\n // If it doesn't appear to be a directory (partial filename), get the parent directory\n if (commonRoot.length && commonRoot[commonRoot.length - 1] !== '/') {\n commonRoot = dirname(commonRoot) + '/';\n }\n }\n return commonRoot;\n};\n", "import { findCommonPath } from './findCommonPath';\nimport { CoverageDetailsMap } from '../../typings/Coverage';\nimport { JsonReport } from '../../typings/JsonReport';\nimport { getFileCoverageMap } from '../../utils/getFileCoverageMap';\nimport { getPercents } from '../getPercents';\n\nexport const parseDetails = (jsonReport: JsonReport) => {\n // Find common root directory\n const filepaths = Object.keys(jsonReport.coverageMap);\n const trimPath = findCommonPath(filepaths).length;\n\n const fileCoverageMap = getFileCoverageMap(jsonReport);\n\n return Object.entries(fileCoverageMap).reduce(\n (acc, [filename, coverage]) => {\n const normalizedFilename = filename.substring(trimPath);\n\n acc[normalizedFilename] = {\n filename: normalizedFilename,\n statements: getPercents(\n coverage.coveredStatements,\n coverage.totalStatements\n ),\n branches: getPercents(\n coverage.coveredBranches,\n coverage.totalBranches\n ),\n functions: getPercents(\n coverage.coveredFunctions,\n coverage.totalFunctions\n ),\n lines: getPercents(coverage.coveredLines, coverage.totalLines),\n };\n\n return acc;\n },\n {}\n );\n};\n", "import { CoverageSummary } from '../../typings/Coverage';\nimport { CoverageMap, FileCoverage } from '../../typings/JsonReport';\nimport { getPercents } from '../getPercents';\n\nexport const getSummary = (\n map: CoverageMap,\n totalCounter: (value: FileCoverage) => number,\n coveredCounter: (value: FileCoverage) => number,\n title: string\n): CoverageSummary => {\n const total = Object.values(map).reduce(\n (acc, currValue) => acc + totalCounter(currValue),\n 0\n );\n\n const covered = Object.values(map).reduce(\n (acc, currValue) => acc + coveredCounter(currValue),\n 0\n );\n\n return {\n title,\n total,\n covered,\n percentage: getPercents(covered, total),\n };\n};\n", "import { getSummary } from './getSummary';\nimport { JsonReport } from '../../typings/JsonReport';\nimport { i18n } from '../../utils/i18n';\nimport {\n coveredBranchesCounter,\n coveredLinesCounter,\n standardCoveredCounter,\n standardTotalCounter,\n totalBranchesCounter,\n totalLinesCounter,\n} from '../counters';\n\nexport const parseSummary = (jsonReport: JsonReport) => {\n return [\n getSummary(\n jsonReport.coverageMap,\n standardTotalCounter('s'),\n standardCoveredCounter('s'),\n i18n('statements')\n ),\n getSummary(\n jsonReport.coverageMap,\n totalBranchesCounter,\n coveredBranchesCounter,\n i18n('branches')\n ),\n getSummary(\n jsonReport.coverageMap,\n standardTotalCounter('f'),\n standardCoveredCounter('f'),\n i18n('functions')\n ),\n getSummary(\n jsonReport.coverageMap,\n totalLinesCounter,\n coveredLinesCounter,\n i18n('lines')\n ),\n ];\n};\n", "import markdownTable from 'markdown-table';\n\nimport { getFileCoverageDetailRow } from './getFileCoverageDetailRow';\nimport { CoverageDetailsMap } from '../../typings/Coverage';\nimport { createMarkdownSpoiler } from '../../utils/createMarkdownSpoiler';\nimport { i18n } from '../../utils/i18n';\nimport { withExplanation } from '../../utils/withExplanation';\n\nexport const formatCoverageDetailsPart = (\n summary: string,\n headDetails: CoverageDetailsMap,\n baseDetails?: CoverageDetailsMap,\n threshold?: number\n): string | undefined => {\n const tableContent = Object.keys(headDetails).map((filename) =>\n getFileCoverageDetailRow(\n filename,\n headDetails[filename],\n baseDetails?.[filename],\n threshold\n )\n );\n\n if (tableContent.length > 0) {\n return createMarkdownSpoiler({\n body: markdownTable(\n [\n [\n withExplanation(\n i18n('status'),\n i18n('statusExplanation')\n ),\n i18n('filename'),\n i18n('statements'),\n i18n('branches'),\n i18n('functions'),\n i18n('lines'),\n ],\n ...tableContent,\n ],\n {\n align: ['c', 'l', 'l', 'l', 'l', 'l'],\n }\n ),\n summary,\n });\n }\n\n return undefined;\n};\n", "import { basename } from 'path';\n\n// if path is longer than LONG_PATH_LENGTH, it is assumed to be a long path\nconst LONG_PATH_LENGTH = 20;\n\nexport const shrinkLongPath = (filename: string) => {\n const base = basename(filename);\n\n if (filename.length >= LONG_PATH_LENGTH && base !== filename) {\n return `
\\`...\\` / ${base}
`;\n }\n\n return filename;\n};\n", "export const decimalToString = (n: number, digitsAfterDot = 2): string =>\n n.toFixed(digitsAfterDot).replace(/\\.?0+$/, '');\n", "import { decimalToString } from './decimalToString';\nimport { i18n } from './i18n';\n\nexport const formatPercentageDelta = (delta: number): string =>\n i18n(\n delta > 0\n ? `(+{{ delta }}% :arrow_up_small:)`\n : `({{ delta }}% :small_red_triangle_down:)`,\n {\n delta: decimalToString(delta),\n }\n );\n", "import { decimalToString } from './decimalToString';\nimport { formatPercentageDelta } from './formatPercentageDelta';\nimport { i18n } from './i18n';\n\nconst APPROXIMATION_THRESHOLD = 0;\n\nexport const formatPercentage = (\n headPercentage: number,\n basePercentage: number = headPercentage\n) => {\n const delta = headPercentage - basePercentage;\n\n const isDeltaValid = Math.abs(delta) > APPROXIMATION_THRESHOLD;\n\n return i18n(\n isDeltaValid\n ? '
{{ percentage }}% {{ delta }}
'\n : '{{ percentage }}%',\n {\n percentage: decimalToString(headPercentage),\n baseCoverage:\n i18n('baseCoverage') + decimalToString(basePercentage),\n delta: isDeltaValid ? formatPercentageDelta(delta) : '',\n }\n );\n};\n", "import { i18n } from './i18n';\n\nconst DEFAULT_STEP = 20;\n\nexport const getStatusOfPercents = (percentage: number, threshold = 60) => {\n let step = DEFAULT_STEP;\n\n if (threshold > 100 - DEFAULT_STEP * 2) {\n step = (100 - threshold) / 2;\n }\n\n if (percentage < threshold) {\n return i18n(':red_circle:');\n } else if (percentage < threshold + step) {\n return i18n(':yellow_circle:');\n } else {\n return i18n(':green_circle:');\n }\n};\n", "import { shrinkLongPath } from './shrinkLongPath';\nimport { CoverageDetail } from '../../typings/Coverage';\nimport { formatPercentage } from '../../utils/formatPercentage';\nimport { getStatusOfPercents } from '../../utils/getStatusOfPercents';\n\nexport const getFileCoverageDetailRow = (\n filename: string,\n headDetail: CoverageDetail,\n baseDetail?: CoverageDetail,\n threshold?: number\n): Array => [\n getStatusOfPercents(headDetail.lines, threshold),\n shrinkLongPath(filename),\n formatPercentage(headDetail.statements, baseDetail?.statements),\n formatPercentage(headDetail.branches, baseDetail?.branches),\n formatPercentage(headDetail.functions, baseDetail?.functions),\n formatPercentage(headDetail.lines, baseDetail?.lines),\n];\n", "export type SpoilerConfig = {\n body: string;\n summary: string;\n};\n\nexport const createMarkdownSpoiler = ({\n body,\n summary,\n}: SpoilerConfig): string => `\n
${summary}\n
\n\n${body}\n\n
\n`;\n", "export const withExplanation = (text: string, explanation: string) =>\n `
${text}:grey_question:
`;\n", "import { CoverageDetail, CoverageDetailsMap } from '../../typings/Coverage';\n\nconst coverageLessThan = (first: CoverageDetail, second: CoverageDetail) =>\n first.statements < second.statements ||\n first.branches < second.branches ||\n first.functions < second.functions;\n\nexport const getDecreasedCoverage = (\n headDetails: CoverageDetailsMap,\n baseDetails: CoverageDetailsMap | undefined\n) =>\n Object.keys(headDetails)\n .filter(\n (filename) =>\n headDetails[filename] &&\n baseDetails?.[filename] &&\n coverageLessThan(headDetails[filename], baseDetails[filename])\n )\n .reduce<{\n headDetails: CoverageDetailsMap;\n baseDetails: CoverageDetailsMap;\n }>(\n (acc, filename) => {\n acc.headDetails[filename] = headDetails[filename];\n acc.baseDetails[filename] = baseDetails![filename];\n return acc;\n },\n { headDetails: {}, baseDetails: {} }\n );\n", "import { CoverageDetailsMap } from '../../typings/Coverage';\n\nexport const getNewFilesCoverage = (\n headDetails: CoverageDetailsMap,\n baseDetails: CoverageDetailsMap | undefined\n): CoverageDetailsMap =>\n baseDetails\n ? Object.keys(headDetails)\n .filter((filename) => baseDetails[filename] === undefined)\n .reduce((acc, filename) => {\n acc[filename] = headDetails[filename];\n return acc;\n }, {})\n : {};\n", "import { formatCoverageDetailsPart } from './formatCoverageDetailsPart';\nimport { getDecreasedCoverage } from './getDecreasedCoverage';\nimport { getNewFilesCoverage } from './getNewFilesCoverage';\nimport { CoverageDetailsMap } from '../../typings/Coverage';\nimport { i18n } from '../../utils/i18n';\n\nexport const formatCoverageDetails = (\n headDetails: CoverageDetailsMap,\n baseDetails: CoverageDetailsMap | undefined,\n threshold: number | undefined\n): string => {\n const decreasedCoverage = getDecreasedCoverage(headDetails, baseDetails);\n\n return [\n formatCoverageDetailsPart(\n i18n('newFilesCoverage'),\n getNewFilesCoverage(headDetails, baseDetails),\n undefined,\n threshold\n ),\n formatCoverageDetailsPart(\n i18n('decreasedCoverageFiles'),\n decreasedCoverage.headDetails,\n decreasedCoverage.baseDetails,\n threshold\n ),\n ].join('\\n');\n};\n", "import table from 'markdown-table';\n\nimport { CoverageSummary } from '../../typings/Coverage';\nimport { formatPercentage } from '../../utils/formatPercentage';\nimport { getStatusOfPercents } from '../../utils/getStatusOfPercents';\nimport { i18n } from '../../utils/i18n';\nimport { withExplanation } from '../../utils/withExplanation';\n\nexport const formatCoverageSummary = (\n headSummary: Array,\n baseSummary: Array | undefined,\n threshold: number | undefined\n): string =>\n table(\n [\n [\n withExplanation(i18n('status'), i18n('statusExplanation')),\n i18n('category'),\n i18n('percentage'),\n i18n('ratio'),\n ],\n ...headSummary.map((currSummary, index) => [\n getStatusOfPercents(currSummary.percentage, threshold),\n currSummary.title,\n formatPercentage(\n currSummary.percentage,\n baseSummary?.[index].percentage\n ),\n `${currSummary.covered}/${currSummary.total}`,\n ]),\n ],\n { align: ['c', 'l', 'l', 'c'] }\n );\n", "import { formatCoverageDetails } from './details/formatCoverageDetails';\nimport { formatCoverageSummary } from './summary/formatCoverageSummary';\nimport { CoverageDetailsMap, CoverageSummary } from '../typings/Coverage';\nimport { i18n } from '../utils/i18n';\n\nexport const getFormattedCoverage = (\n headSummary: Array,\n baseSummary: Array | undefined,\n headDetails: CoverageDetailsMap,\n baseDetails: CoverageDetailsMap | undefined,\n threshold: number | undefined,\n hideDetails: boolean | undefined\n): string =>\n [\n formatCoverageSummary(headSummary, baseSummary, threshold),\n !hideDetails\n ? formatCoverageDetails(headDetails, baseDetails, threshold)\n : `> ${i18n('detailsHidden')}`,\n ]\n .filter(Boolean)\n .join('\\n');\n", "import { parseDetails } from './details/parseDetails';\nimport { parseSummary } from './summary/parseSummary';\nimport { getFormattedCoverage } from './getFormattedCoverage';\nimport { JsonReport } from '../typings/JsonReport';\n\nexport const formatCoverage = (\n headReport: JsonReport | undefined,\n baseReport: JsonReport | undefined,\n threshold: number | undefined,\n hideDetails: boolean | undefined\n): string => {\n if (headReport) {\n return getFormattedCoverage(\n parseSummary(headReport),\n baseReport ? parseSummary(baseReport) : undefined,\n parseDetails(headReport),\n baseReport ? parseDetails(baseReport) : undefined,\n threshold,\n hideDetails\n );\n }\n\n return '';\n};\n", "import { FailReason } from './Report';\nimport { i18n } from '../utils/i18n';\n\nexport class ActionError extends Error {\n public constructor(reason: FailReason, details?: T) {\n super(\n i18n(\n `errors.${reason}`,\n (details as unknown) as Record\n )\n );\n }\n\n public toString(): string {\n return this.message;\n }\n}\n", "import { context } from '@actions/github';\n\nexport const getConsoleLink = () => {\n const repositoryUrl =\n context.payload.repository?.html_url ??\n `https://github.com/${context.repo.owner}/${context.repo.repo}`;\n\n return `${repositoryUrl}/actions/runs/${context.runId}`;\n};\n", "import { ActionError } from '../typings/ActionError';\nimport { getConsoleLink } from '../utils/getConsoleLink';\nimport { i18n } from '../utils/i18n';\n\nconst getNumberWidth = (index: number) => Math.floor(Math.log10(index));\n\nexport const formatErrors = (errors: Array) => {\n if (errors.length === 0) {\n return '';\n }\n\n if (errors.length === 1) {\n const error = errors[0];\n\n if (error instanceof ActionError) {\n return i18n(':x: {{ error }}', { error: error.toString() });\n }\n\n return i18n(':x: {{ unexpectedError }} \\n```\\n{{ error }}\\n```', {\n error: error.toString(),\n unexpectedError: i18n('errors.unexpectedError', {\n consoleLink: getConsoleLink(),\n }),\n });\n }\n\n return (\n i18n('errors.multiple') +\n i18n('\\n```\\n{{ errors }}\\n```\\n', {\n errors: errors\n .map(\n (error, index) =>\n ` ${String(1 + index).padEnd(\n 1 + getNumberWidth(errors.length),\n ' '\n )} | ${error.toString()}`\n )\n .join('\\n'),\n })\n );\n};\n", "import { TestRunReport } from '../typings/Report';\nimport { createMarkdownSpoiler } from '../utils/createMarkdownSpoiler';\n\nexport const formatRunReport = (report: TestRunReport): string => {\n const parts = [`## ${report.title}`];\n if (report.failures) {\n parts.push(\n createMarkdownSpoiler({\n summary: report.summary,\n body: report.failures,\n })\n );\n } else {\n parts.push(report.summary);\n }\n return parts.join('\\n');\n};\n", "import { ThresholdResult } from '../typings/ThresholdResult';\r\nimport { i18n } from '../utils/i18n';\r\n\r\nexport const formatThresholdResults = (results: ThresholdResult[]): string => {\r\n return results\r\n .map(({ type, path, expected, received }) =>\r\n i18n(`thresholdFailures.${expected < 0 ? 'ones' : 'percents'}`, {\r\n path,\r\n type: i18n(type),\r\n ltype: i18n(type).toLowerCase(),\r\n expected: Math.abs(expected),\r\n coverage: received,\r\n })\r\n )\r\n .join('\\n');\r\n};\r\n", "import stripAnsi from 'strip-ansi';\n\nimport { JsonReport } from '../typings/JsonReport';\n\nexport const getFailureDetails = ({ testResults }: JsonReport): string => {\n if (\n !testResults ||\n !testResults.some(\n ({ message, status }) => message.length > 0 && status !== 'passed'\n )\n ) {\n return '';\n }\n const wrapCode = (code: string) => '```\\n' + code + '\\n```';\n const codeBlocks = testResults\n .filter(({ status }) => status !== 'passed')\n .map(({ message }) => {\n const stripped = stripAnsi(message);\n if (stripped.trim().length === 0) {\n return '';\n }\n return wrapCode(stripped);\n })\n .filter(({ length }) => length > 0);\n return codeBlocks.join('\\n---\\n');\n};\n", "import { JsonReport } from '../../typings/JsonReport';\nimport { i18n } from '../../utils/i18n';\n\nexport const getTestRunSummary = (jsonReport: JsonReport) =>\n jsonReport.success\n ? i18n('testsSuccessSummary', {\n numPassedTests: jsonReport.numPassedTests,\n numPassedTestSuites: jsonReport.numPassedTestSuites,\n ending: jsonReport.numPassedTestSuites > 1 ? 's' : '',\n })\n : i18n('testsFailSummary', {\n numFailedTests: jsonReport.numFailedTests,\n numTotalTests: jsonReport.numTotalTests,\n numFailedTestSuites: jsonReport.numFailedTestSuites,\n numTotalTestSuites: jsonReport.numTotalTestSuites,\n });\n", "import { readFile } from 'fs-extra';\n\nimport { REPORT_PATH } from '../constants/REPORT_PATH';\nimport { ActionError } from '../typings/ActionError';\nimport { FailReason } from '../typings/Report';\nimport { DataCollector } from '../utils/DataCollector';\nimport { i18n } from '../utils/i18n';\nimport { joinPaths } from '../utils/joinPaths';\n\nexport const collectCoverage = async (\n dataCollector: DataCollector,\n workingDirectory?: string,\n coverageFile?: string\n) => {\n const pathToCoverageFile = joinPaths(\n workingDirectory,\n coverageFile || REPORT_PATH\n );\n\n try {\n // Originally made by Jeremy Gillick (https://github.com/jgillick)\n // Modified after big refactor by Artiom Tretjakovas (https://github.com/ArtiomTr)\n // Load coverage from file\n\n dataCollector.info(\n i18n('loadingCoverageFromFile', {\n pathToCoverageFile,\n })\n );\n\n const outputBuffer = await readFile(pathToCoverageFile);\n\n return outputBuffer.toString();\n } catch (error) {\n if ((error as NodeJS.ErrnoException).code === 'ENOENT') {\n throw new ActionError(FailReason.REPORT_NOT_FOUND, {\n coveragePath: pathToCoverageFile,\n });\n }\n\n throw new ActionError(FailReason.READING_COVERAGE_FILE_FAILED, {\n error: (error as Error).toString(),\n });\n }\n};\n", "export const REPORT_PATH = 'report.json';\n", "import { exec } from '@actions/exec';\n\nimport { PackageManagerType } from '../typings/Options';\nimport { joinPaths } from '../utils/joinPaths';\nimport { removeDirectory } from '../utils/removeDirectory';\n\nexport const installDependencies = async (\n packageManager: PackageManagerType = 'npm',\n workingDirectory?: string\n) => {\n // NOTE: The `npm ci` command is not used. Because if your version of npm is old, the generated `package-lock.json` will also be old, and the latest version of `npm ci` will fail.\n await removeDirectory(joinPaths(workingDirectory, 'node_modules'));\n\n await exec(`${packageManager} install`, undefined, {\n cwd: workingDirectory,\n });\n};\n", "import { rm, rmdir } from 'fs-extra';\r\nimport { satisfies } from 'semver';\r\n\r\nexport const removeDirectory = (path: string) => {\r\n if (satisfies(process.version, '>=14.14.0')) {\r\n return rm(path, { force: true, recursive: true });\r\n } else {\r\n return rmdir(path, { recursive: true });\r\n }\r\n};\r\n", "import { ActionError } from '../typings/ActionError';\nimport { JsonReport } from '../typings/JsonReport';\nimport { FailReason } from '../typings/Report';\n\nexport const parseCoverage = (src: string): JsonReport => {\n try {\n return JSON.parse(src);\n } catch (err) {\n throw new ActionError(FailReason.INVALID_COVERAGE_FORMAT);\n }\n};\n", "import { exec } from '@actions/exec';\n\nimport { getTestCommand } from '../utils/getTestCommand';\n\nexport const runTest = async (\n testCommand: string,\n workingDirectory?: string\n) => {\n await exec(\n await getTestCommand(testCommand, 'report.json', workingDirectory),\n [],\n {\n cwd: workingDirectory,\n }\n );\n};\n", "import { join } from 'path';\n\nimport { readFile } from 'fs-extra';\n\nconst packageScriptRegex = /^(?:(?:npm|yarn|pnpm)\\s+(?:run\\s+)?([\\w:-]+))/;\n\nexport const isOldScript = async (\n command: string,\n workingDirectory: string | undefined\n) => {\n if (command.includes('report.json')) {\n return true;\n }\n\n const matchResult = command.match(packageScriptRegex);\n\n if (matchResult) {\n const [, scriptName] = matchResult;\n\n try {\n const packageJson = JSON.parse(\n (\n await readFile(\n join(\n ...([workingDirectory, 'package.json'].filter(\n Boolean\n ) as string[])\n )\n )\n ).toString()\n );\n\n const realScript = packageJson.scripts[scriptName];\n\n if (realScript.includes('report.json')) {\n return true;\n }\n } catch {\n /** ignore exceptions */\n }\n }\n\n return false;\n};\n", "import { isOldScript } from './isOldScript';\n\nexport const getTestCommand = async (\n command: string,\n outputFile: string,\n workingDirectory: string | undefined\n) => {\n if (await isOldScript(command, workingDirectory)) {\n // TODO: add warning here\n return command;\n }\n\n const isNpmStyle = command.startsWith('npm') || command.startsWith('pnpm');\n\n const hasDoubleHyhen = command.includes(' -- ');\n\n // building new command\n const newCommandBuilder: (string | boolean)[] = [\n command,\n // add two hypens if it is npm or pnpm package managers and two hyphens don't already exist\n isNpmStyle && !hasDoubleHyhen && '--',\n // argument which indicates that jest runs in CI environment\n '--ci',\n // telling jest that output should be in json format\n '--json',\n // force jest to collect coverage\n '--coverage',\n // argument which tells jest to include tests' locations in the generated json output\n '--testLocationInResults',\n // output file\n `--outputFile=\"${outputFile}\"`,\n ];\n\n return newCommandBuilder.filter(Boolean).join(' ');\n};\n", "import { getInput } from '@actions/core';\nimport { context, getOctokit } from '@actions/github';\nimport * as yup from 'yup';\n\nimport { icons } from '../format/strings.json';\n\nexport type IconType = keyof typeof icons;\n\nexport type AnnotationType = 'all' | 'none' | 'coverage' | 'failed-tests';\nexport type PackageManagerType = 'npm' | 'yarn' | 'pnpm';\nexport type SkipStepType = 'all' | 'none' | 'install';\nexport type OutputType = 'comment' | 'report-markdown';\nexport type PullRequest = {\n base: { ref: string };\n head: { ref: string; sha: string };\n number: number;\n};\nexport type Options = {\n token: string;\n testScript: string;\n iconType: IconType;\n annotations: AnnotationType;\n threshold?: number;\n workingDirectory?: string;\n packageManager: PackageManagerType;\n skipStep: SkipStepType;\n customTitle?: string;\n coverageFile?: string;\n baseCoverageFile?: string;\n prNumber: null | number;\n pullRequest: null | PullRequest;\n output: Array;\n};\n\nconst validAnnotationOptions: Array = [\n 'all',\n 'none',\n 'coverage',\n 'failed-tests',\n];\n\nconst packageManagerOptions: Array = [\n 'npm',\n 'yarn',\n 'pnpm',\n];\n\nconst validIconOptions = Object.keys(icons);\n\nconst validSkipStepOptions: Array = ['all', 'none', 'install'];\n\nconst validOutputTypeOptions: Array = [\n 'comment',\n 'report-markdown',\n];\n\nconst optionSchema = yup.object().shape({\n token: yup.string().required(),\n testScript: yup.string().required(),\n iconType: yup.string().required().oneOf(validIconOptions),\n annotations: yup.string().required().oneOf(validAnnotationOptions),\n threshold: yup\n .number()\n .transform((value) => (isNaN(value) ? undefined : value))\n .min(0)\n .max(100),\n workingDirectory: yup.string(),\n packageManager: yup.string().required().oneOf(packageManagerOptions),\n skipStep: yup.string().required().oneOf(validSkipStepOptions),\n customTitle: yup.string(),\n coverageFile: yup.string(),\n baseCoverageFile: yup.string(),\n prNumber: yup.number().nullable(),\n pullRequest: yup.object().nullable(),\n output: yup\n .array()\n .required()\n .transform((_, originalValue: string) => originalValue.split(', '))\n .of(yup.string().required().oneOf(validOutputTypeOptions)),\n});\n\nexport const shouldInstallDeps = (skipStep: SkipStepType): Boolean =>\n !['all', 'install'].includes(skipStep);\n\nexport const shouldRunTestScript = (skipStep: SkipStepType): Boolean =>\n !['all'].includes(skipStep);\n\nexport const getOptions = async (): Promise => {\n const token = getInput('github-token', {\n required: true,\n });\n const octokit = getOctokit(token);\n const testScript = getInput('test-script');\n const threshold = getInput('threshold');\n const workingDirectory = getInput('working-directory');\n const iconType = getInput('icons');\n const annotations = getInput('annotations');\n const packageManager = getInput('package-manager');\n const skipStep = getInput('skip-step');\n const customTitle = getInput('custom-title');\n const coverageFile = getInput('coverage-file');\n const baseCoverageFile = getInput('base-coverage-file');\n const prNumber: number | null = Number(\n getInput('prnumber') || context?.payload?.pull_request?.number\n );\n const output = getInput('output');\n let pullRequest = context?.payload?.pull_request || null;\n\n if (!pullRequest && !Number.isNaN(prNumber)) {\n const { data: pr } = await octokit.rest.pulls.get({\n owner: context.repo.owner,\n repo: context.repo.repo,\n pull_number: prNumber,\n });\n pullRequest = pr as PullRequest;\n }\n\n try {\n const options: Options = (await optionSchema.validate({\n token,\n testScript,\n threshold,\n workingDirectory,\n iconType,\n annotations,\n packageManager,\n skipStep,\n customTitle,\n coverageFile,\n baseCoverageFile,\n prNumber: prNumber || null,\n pullRequest,\n output,\n })) as Options;\n\n return options;\n } catch (err) {\n if (err instanceof yup.ValidationError) {\n throw new Error(\n [err.message, ...err.errors].filter(Boolean).join('\\n')\n );\n }\n\n throw err;\n }\n};\n", "import { DataCollector } from './DataCollector';\nimport { i18n } from './i18n';\n\nexport type SuccessfulStageResult = [success: true, output: T];\n\nexport type FailedStageResult = [success: false, output: undefined];\n\nexport type StageResult = SuccessfulStageResult | FailedStageResult;\n\nconst SKIP_SYMBOL = Symbol();\n\nexport const runStage = async (\n stage: string,\n dataCollector: DataCollector,\n action: (skip: () => never) => Promise | T\n): Promise> => {\n const stageKey = `stages.${stage}`;\n dataCollector.info(\n i18n('stages.defaults.begin', {\n stage: i18n(stageKey).toLowerCase(),\n })\n );\n\n const skip = () => {\n throw SKIP_SYMBOL;\n };\n\n try {\n const output = await action(skip);\n return [true, output];\n } catch (error) {\n if (error === SKIP_SYMBOL) {\n dataCollector.info(\n i18n('stages.defaults.skip', {\n stage: i18n(stageKey),\n })\n );\n } else {\n dataCollector.info(\n i18n('stages.defaults.fail', {\n stage: i18n(stageKey),\n })\n );\n dataCollector.error(error as Error);\n }\n\n return [false, undefined];\n } finally {\n dataCollector.info(\n i18n('stages.defaults.end', {\n stage: i18n(stageKey),\n })\n );\n }\n};\n", "import { collectCoverage } from './collectCoverage';\nimport { installDependencies } from './installDependencies';\nimport { parseCoverage } from './parseCoverage';\nimport { runTest } from './runTest';\nimport { ActionError } from '../typings/ActionError';\nimport { JsonReport } from '../typings/JsonReport';\nimport {\n Options,\n shouldInstallDeps,\n shouldRunTestScript,\n} from '../typings/Options';\nimport { FailReason } from '../typings/Report';\nimport { DataCollector } from '../utils/DataCollector';\nimport { runStage } from '../utils/runStage';\n\nexport const getCoverage = async (\n dataCollector: DataCollector,\n options: Options,\n runAll: boolean,\n coverageFilePath: string | undefined\n): Promise => {\n await runStage('install', dataCollector, async (skip) => {\n if (\n coverageFilePath ||\n (!runAll && !shouldInstallDeps(options.skipStep))\n ) {\n skip();\n }\n\n await installDependencies(\n options.packageManager,\n options.workingDirectory\n );\n });\n\n await runStage('runTest', dataCollector, async (skip) => {\n if (\n coverageFilePath ||\n (!runAll && !shouldRunTestScript(options.skipStep))\n ) {\n skip();\n }\n\n await runTest(options.testScript, options.workingDirectory);\n });\n\n const [isCoverageCollected, rawCoverage] = await runStage(\n 'collectCoverage',\n dataCollector,\n () =>\n collectCoverage(\n dataCollector as DataCollector,\n options.workingDirectory,\n coverageFilePath\n )\n );\n\n const [coverageParsed, jsonReport] = await runStage(\n 'parseCoverage',\n dataCollector,\n async (skip) => {\n if (!isCoverageCollected) {\n skip();\n }\n\n const jsonReport = parseCoverage(rawCoverage!);\n\n return jsonReport;\n }\n );\n\n if (!coverageParsed || !jsonReport) {\n throw new ActionError(FailReason.FAILED_GETTING_COVERAGE);\n }\n\n return jsonReport;\n};\n", "import { exec } from '@actions/exec';\n\nexport const switchBranch = async (branch: string) => {\n try {\n await exec(`git fetch --all --depth=1`);\n } catch (err) {\n console.warn('Error fetching git repository', err);\n }\n\n await exec(`git checkout -f ${branch}`);\n};\n\nexport const switchBack = async () => {\n try {\n await exec(`git checkout -`);\n } catch (err) {\n console.warn('Error checking to branches', err);\n }\n};\n", "import * as core from '@actions/core';\n\nexport const createDataCollector = (): DataCollector => {\n const errors: Array = [];\n const collectedData: Array = [];\n const messages: Array = [];\n\n const error = (error: Error) => {\n errors.push(error);\n core.error(\n error.toString().concat(error.stack ? `\\n${error.stack}` : '')\n );\n };\n\n const add = (data: T) => {\n collectedData.push(data);\n };\n\n const info = (message: string) => {\n messages.push(message);\n core.info(message);\n };\n\n const get = () => ({\n data: collectedData,\n errors,\n messages,\n });\n\n return {\n error,\n add,\n get,\n info,\n };\n};\n\nexport type CollectedData = {\n errors: Array;\n messages: Array;\n data: Array;\n};\n\nexport type DataCollector = {\n error: (error: Error) => void;\n info: (message: string) => void;\n add: (data: T) => void;\n get: () => CollectedData;\n};\n", "import isNil from 'lodash/isNil';\r\n\r\nimport { tryGetJestThreshold } from './tryGetJestThreshold';\r\nimport { JestThreshold } from '../typings/JestThreshold';\r\n\r\nexport const getNormalThreshold = async (\r\n workingDirectory: string,\r\n thresholdFromOptions: number | undefined\r\n): Promise => {\r\n const threshold = await tryGetJestThreshold(workingDirectory);\r\n\r\n // Should be removed in further versions\r\n if (isNil(threshold)) {\r\n return {\r\n global: {\r\n branches: thresholdFromOptions,\r\n functions: thresholdFromOptions,\r\n lines: thresholdFromOptions,\r\n statements: thresholdFromOptions,\r\n },\r\n };\r\n }\r\n\r\n return threshold;\r\n};\r\n", "import { existsSync, promises } from 'fs';\nimport { resolve, extname, dirname } from 'pathe';\nimport * as dotenv from 'dotenv';\nimport os from 'os';\nimport createJiti from 'jiti';\nimport * as rc9 from 'rc9';\nimport { defu } from 'defu';\nimport { findWorkspaceDir } from 'pkg-types';\n\nasync function setupDotenv(options) {\n const targetEnv = options.env ?? process.env;\n const env = await loadDotenv({\n cwd: options.cwd,\n fileName: options.fileName ?? \".env\",\n env: targetEnv,\n interpolate: options.interpolate ?? true\n });\n for (const key in env) {\n if (!key.startsWith(\"_\") && targetEnv[key] === void 0) {\n targetEnv[key] = env[key];\n }\n }\n return env;\n}\nasync function loadDotenv(opts) {\n const env = /* @__PURE__ */ Object.create(null);\n const dotenvFile = resolve(opts.cwd, opts.fileName);\n if (existsSync(dotenvFile)) {\n const parsed = dotenv.parse(await promises.readFile(dotenvFile, \"utf-8\"));\n Object.assign(env, parsed);\n }\n if (!opts.env._applied) {\n Object.assign(env, opts.env);\n env._applied = true;\n }\n if (opts.interpolate) {\n interpolate(env);\n }\n return env;\n}\nfunction interpolate(target, source = {}, parse = (v) => v) {\n function getValue(key) {\n return source[key] !== void 0 ? source[key] : target[key];\n }\n function interpolate2(value, parents = []) {\n if (typeof value !== \"string\") {\n return value;\n }\n const matches = value.match(/(.?\\${?(?:[a-zA-Z0-9_:]+)?}?)/g) || [];\n return parse(matches.reduce((newValue, match) => {\n const parts = /(.?)\\${?([a-zA-Z0-9_:]+)?}?/g.exec(match);\n const prefix = parts[1];\n let value2, replacePart;\n if (prefix === \"\\\\\") {\n replacePart = parts[0];\n value2 = replacePart.replace(\"\\\\$\", \"$\");\n } else {\n const key = parts[2];\n replacePart = parts[0].substring(prefix.length);\n if (parents.includes(key)) {\n console.warn(`Please avoid recursive environment variables ( loop: ${parents.join(\" > \")} > ${key} )`);\n return \"\";\n }\n value2 = getValue(key);\n value2 = interpolate2(value2, [...parents, key]);\n }\n return value2 !== void 0 ? newValue.replace(replacePart, value2) : newValue;\n }, value));\n }\n for (const key in target) {\n target[key] = interpolate2(getValue(key));\n }\n}\n\nasync function loadConfig(opts) {\n opts.cwd = resolve(process.cwd(), opts.cwd || \".\");\n opts.name = opts.name || \"config\";\n opts.configFile = opts.configFile ?? (opts.name !== \"config\" ? `${opts.name}.config` : \"config\");\n opts.rcFile = opts.rcFile ?? `.${opts.name}rc`;\n if (opts.extend !== false) {\n opts.extend = {\n extendKey: \"extends\",\n ...opts.extend\n };\n }\n opts.jiti = opts.jiti || createJiti(null, {\n interopDefault: true,\n requireCache: false,\n esmResolve: true,\n ...opts.jitiOptions\n });\n const r = {\n config: {},\n cwd: opts.cwd,\n configFile: resolve(opts.cwd, opts.configFile),\n layers: []\n };\n if (opts.dotenv) {\n await setupDotenv({\n cwd: opts.cwd,\n ...opts.dotenv === true ? {} : opts.dotenv\n });\n }\n const { config, configFile } = await resolveConfig(\".\", opts);\n if (configFile) {\n r.configFile = configFile;\n }\n const configRC = {};\n if (opts.rcFile) {\n if (opts.globalRc) {\n Object.assign(configRC, rc9.readUser({ name: opts.rcFile, dir: opts.cwd }));\n const workspaceDir = await findWorkspaceDir(opts.cwd).catch(() => null);\n if (workspaceDir) {\n Object.assign(configRC, rc9.read({ name: opts.rcFile, dir: workspaceDir }));\n }\n }\n Object.assign(configRC, rc9.read({ name: opts.rcFile, dir: opts.cwd }));\n }\n r.config = defu(\n opts.overrides,\n config,\n configRC,\n opts.defaultConfig\n );\n if (opts.extend) {\n await extendConfig(r.config, opts);\n r.layers = r.config._layers;\n delete r.config._layers;\n r.config = defu(\n r.config,\n ...r.layers.map((e) => e.config)\n );\n }\n const baseLayers = [\n opts.overrides && { config: opts.overrides, configFile: void 0, cwd: void 0 },\n { config, configFile: opts.configFile, cwd: opts.cwd },\n opts.rcFile && { config: configRC, configFile: opts.rcFile }\n ].filter((l) => l && l.config);\n r.layers = [\n ...baseLayers,\n ...r.layers\n ];\n if (opts.defaults) {\n r.config = defu(r.config, opts.defaults);\n }\n return r;\n}\nasync function extendConfig(config, opts) {\n config._layers = config._layers || [];\n if (!opts.extend) {\n return;\n }\n let keys = opts.extend.extendKey;\n if (typeof keys === \"string\") {\n keys = [keys];\n }\n const extendSources = [];\n for (const key of keys) {\n extendSources.push(...(Array.isArray(config[key]) ? config[key] : [config[key]]).filter(Boolean));\n delete config[key];\n }\n for (const extendSource of extendSources) {\n if (typeof extendSource !== \"string\") {\n console.warn(`Cannot extend config from \\`${JSON.stringify(extendSource)}\\` (which should be a string) in ${opts.cwd}`);\n continue;\n }\n const _config = await resolveConfig(extendSource, opts);\n if (!_config.config) {\n console.warn(`Cannot extend config from \\`${extendSource}\\` in ${opts.cwd}`);\n continue;\n }\n await extendConfig(_config.config, { ...opts, cwd: _config.cwd });\n config._layers.push(_config);\n if (_config.config._layers) {\n config._layers.push(..._config.config._layers);\n delete _config.config._layers;\n }\n }\n}\nconst GIT_PREFIXES = [\"github:\", \"gitlab:\", \"bitbucket:\", \"https://\"];\nconst NPM_PACKAGE_RE = /^(@[a-z0-9-~][a-z0-9-._~]*\\/)?[a-z0-9-~][a-z0-9-._~]*$/;\nasync function resolveConfig(source, opts) {\n if (opts.resolve) {\n const res2 = await opts.resolve(source, opts);\n if (res2) {\n return res2;\n }\n }\n if (GIT_PREFIXES.some((prefix) => source.startsWith(prefix))) {\n const url = new URL(source);\n const subPath = url.pathname.split(\"/\").slice(2).join(\"/\");\n const gitRepo = url.protocol + url.pathname.split(\"/\").slice(0, 2).join(\"/\");\n const tmpdir = resolve(os.tmpdir(), \"c12/\", gitRepo.replace(/[#:@/\\\\]/g, \"_\"));\n await promises.rm(tmpdir, { recursive: true }).catch(() => {\n });\n const gittar = await import('gittar').then((r) => r.default || r);\n const tarFile = await gittar.fetch(gitRepo);\n await gittar.extract(tarFile, tmpdir);\n source = resolve(tmpdir, subPath);\n }\n if (NPM_PACKAGE_RE.test(source)) {\n try {\n source = opts.jiti.resolve(source, { paths: [opts.cwd] });\n } catch (_err) {\n }\n }\n const isDir = !extname(source);\n const cwd = resolve(opts.cwd, isDir ? source : dirname(source));\n if (isDir) {\n source = opts.configFile;\n }\n const res = { config: null, cwd };\n try {\n res.configFile = opts.jiti.resolve(resolve(cwd, source), { paths: [cwd] });\n } catch (_err) {\n }\n if (!existsSync(res.configFile)) {\n return res;\n }\n res.config = opts.jiti(res.configFile);\n if (typeof res.config === \"function\") {\n res.config = await res.config();\n }\n return res;\n}\n\nexport { loadConfig, loadDotenv, setupDotenv };\n", "function normalizeWindowsPath(input = \"\") {\n if (!input || !input.includes(\"\\\\\")) {\n return input;\n }\n return input.replace(/\\\\/g, \"/\");\n}\n\nconst _UNC_REGEX = /^[\\\\/]{2}/;\nconst _IS_ABSOLUTE_RE = /^[\\\\/](?![\\\\/])|^[\\\\/]{2}(?!\\.)|^[a-zA-Z]:[\\\\/]/;\nconst _DRIVE_LETTER_RE = /^[a-zA-Z]:$/;\nconst sep = \"/\";\nconst delimiter = \":\";\nconst normalize = function(path) {\n if (path.length === 0) {\n return \".\";\n }\n path = normalizeWindowsPath(path);\n const isUNCPath = path.match(_UNC_REGEX);\n const isPathAbsolute = isAbsolute(path);\n const trailingSeparator = path[path.length - 1] === \"/\";\n path = normalizeString(path, !isPathAbsolute);\n if (path.length === 0) {\n if (isPathAbsolute) {\n return \"/\";\n }\n return trailingSeparator ? \"./\" : \".\";\n }\n if (trailingSeparator) {\n path += \"/\";\n }\n if (_DRIVE_LETTER_RE.test(path)) {\n path += \"/\";\n }\n if (isUNCPath) {\n if (!isPathAbsolute) {\n return `//./${path}`;\n }\n return `//${path}`;\n }\n return isPathAbsolute && !isAbsolute(path) ? `/${path}` : path;\n};\nconst join = function(...args) {\n if (args.length === 0) {\n return \".\";\n }\n let joined;\n for (let i = 0; i < args.length; ++i) {\n const arg = args[i];\n if (arg && arg.length > 0) {\n if (joined === void 0) {\n joined = arg;\n } else {\n joined += `/${arg}`;\n }\n }\n }\n if (joined === void 0) {\n return \".\";\n }\n return normalize(joined.replace(/\\/\\/+/g, \"/\"));\n};\nconst resolve = function(...args) {\n args = args.map((arg) => normalizeWindowsPath(arg));\n let resolvedPath = \"\";\n let resolvedAbsolute = false;\n for (let i = args.length - 1; i >= -1 && !resolvedAbsolute; i--) {\n const path = i >= 0 ? args[i] : process.cwd().replace(/\\\\/g, \"/\");\n if (!path || path.length === 0) {\n continue;\n }\n resolvedPath = `${path}/${resolvedPath}`;\n resolvedAbsolute = isAbsolute(path);\n }\n resolvedPath = normalizeString(resolvedPath, !resolvedAbsolute);\n if (resolvedAbsolute && !isAbsolute(resolvedPath)) {\n return `/${resolvedPath}`;\n }\n return resolvedPath.length > 0 ? resolvedPath : \".\";\n};\nfunction normalizeString(path, allowAboveRoot) {\n let res = \"\";\n let lastSegmentLength = 0;\n let lastSlash = -1;\n let dots = 0;\n let char = null;\n for (let i = 0; i <= path.length; ++i) {\n if (i < path.length) {\n char = path[i];\n } else if (char === \"/\") {\n break;\n } else {\n char = \"/\";\n }\n if (char === \"/\") {\n if (lastSlash === i - 1 || dots === 1) ; else if (dots === 2) {\n if (res.length < 2 || lastSegmentLength !== 2 || res[res.length - 1] !== \".\" || res[res.length - 2] !== \".\") {\n if (res.length > 2) {\n const lastSlashIndex = res.lastIndexOf(\"/\");\n if (lastSlashIndex === -1) {\n res = \"\";\n lastSegmentLength = 0;\n } else {\n res = res.slice(0, lastSlashIndex);\n lastSegmentLength = res.length - 1 - res.lastIndexOf(\"/\");\n }\n lastSlash = i;\n dots = 0;\n continue;\n } else if (res.length !== 0) {\n res = \"\";\n lastSegmentLength = 0;\n lastSlash = i;\n dots = 0;\n continue;\n }\n }\n if (allowAboveRoot) {\n res += res.length > 0 ? \"/..\" : \"..\";\n lastSegmentLength = 2;\n }\n } else {\n if (res.length > 0) {\n res += `/${path.slice(lastSlash + 1, i)}`;\n } else {\n res = path.slice(lastSlash + 1, i);\n }\n lastSegmentLength = i - lastSlash - 1;\n }\n lastSlash = i;\n dots = 0;\n } else if (char === \".\" && dots !== -1) {\n ++dots;\n } else {\n dots = -1;\n }\n }\n return res;\n}\nconst isAbsolute = function(p) {\n return _IS_ABSOLUTE_RE.test(p);\n};\nconst toNamespacedPath = function(p) {\n return normalizeWindowsPath(p);\n};\nconst _EXTNAME_RE = /.(\\.[^/.]+)$/;\nconst extname = function(p) {\n const match = _EXTNAME_RE.exec(normalizeWindowsPath(p));\n return match && match[1] || \"\";\n};\nconst relative = function(from, to) {\n const _from = resolve(from).split(\"/\");\n const _to = resolve(to).split(\"/\");\n for (const segment of [..._from]) {\n if (_to[0] !== segment) {\n break;\n }\n _from.shift();\n _to.shift();\n }\n return [..._from.map(() => \"..\"), ..._to].join(\"/\");\n};\nconst dirname = function(p) {\n const segments = normalizeWindowsPath(p).replace(/\\/$/, \"\").split(\"/\").slice(0, -1);\n if (segments.length === 1 && _DRIVE_LETTER_RE.test(segments[0])) {\n segments[0] += \"/\";\n }\n return segments.join(\"/\") || (isAbsolute(p) ? \"/\" : \".\");\n};\nconst format = function(p) {\n const segments = [p.root, p.dir, p.base ?? p.name + p.ext].filter(Boolean);\n return normalizeWindowsPath(p.root ? resolve(...segments) : segments.join(\"/\"));\n};\nconst basename = function(p, ext) {\n const lastSegment = normalizeWindowsPath(p).split(\"/\").pop();\n return ext && lastSegment.endsWith(ext) ? lastSegment.slice(0, -ext.length) : lastSegment;\n};\nconst parse = function(p) {\n const root = normalizeWindowsPath(p).split(\"/\").shift() || \"/\";\n const base = basename(p);\n const ext = extname(base);\n return {\n root,\n dir: dirname(p),\n base,\n ext,\n name: base.slice(0, base.length - ext.length)\n };\n};\n\nexport { normalizeString as a, relative as b, dirname as c, delimiter as d, extname as e, format as f, basename as g, normalizeWindowsPath as h, isAbsolute as i, join as j, normalize as n, parse as p, resolve as r, sep as s, toNamespacedPath as t };\n", "import { existsSync, readFileSync, writeFileSync } from 'fs';\nimport { resolve } from 'path';\nimport { homedir } from 'os';\nimport destr from 'destr';\nimport flat from 'flat';\nimport defu from 'defu';\n\nconst RE_KEY_VAL = /^\\s*([^=\\s]+)\\s*=\\s*(.*)?\\s*$/;\nconst RE_LINES = /\\n|\\r|\\r\\n/;\nconst defaults = {\n name: \".conf\",\n dir: process.cwd(),\n flat: false\n};\nfunction withDefaults(options) {\n if (typeof options === \"string\") {\n options = { name: options };\n }\n return { ...defaults, ...options };\n}\nfunction parse(contents, options = {}) {\n const config = {};\n const lines = contents.split(RE_LINES);\n for (const line of lines) {\n const match = line.match(RE_KEY_VAL);\n if (!match) {\n continue;\n }\n const key = match[1];\n if (!key || key === \"__proto__\" || key === \"constructor\") {\n continue;\n }\n const val = destr(match[2].trim());\n if (key.endsWith(\"[]\")) {\n const nkey = key.substr(0, key.length - 2);\n config[nkey] = (config[nkey] || []).concat(val);\n continue;\n }\n config[key] = val;\n }\n return options.flat ? config : flat.unflatten(config, { overwrite: true });\n}\nfunction parseFile(path, options) {\n if (!existsSync(path)) {\n return {};\n }\n return parse(readFileSync(path, \"utf-8\"), options);\n}\nfunction read(options) {\n options = withDefaults(options);\n return parseFile(resolve(options.dir, options.name), options);\n}\nfunction readUser(options) {\n options = withDefaults(options);\n options.dir = process.env.XDG_CONFIG_HOME || homedir();\n return read(options);\n}\nfunction serialize(config) {\n return Object.entries(flat.flatten(config)).map(([key, val]) => `${key}=${typeof val === \"string\" ? val : JSON.stringify(val)}`).join(\"\\n\");\n}\nfunction write(config, options) {\n options = withDefaults(options);\n writeFileSync(resolve(options.dir, options.name), serialize(config), {\n encoding: \"utf-8\"\n });\n}\nfunction writeUser(config, options) {\n options = withDefaults(options);\n options.dir = process.env.XDG_CONFIG_HOME || homedir();\n write(config, options);\n}\nfunction update(config, options) {\n options = withDefaults(options);\n if (!options.flat) {\n config = flat.unflatten(config, { overwrite: true });\n }\n const newConfig = defu(config, read(options));\n write(newConfig, options);\n return newConfig;\n}\nfunction updateUser(config, options) {\n options = withDefaults(options);\n options.dir = process.env.XDG_CONFIG_HOME || homedir();\n return update(config, options);\n}\n\nexport { defaults, parse, parseFile, read, readUser, serialize, update, updateUser, write, writeUser };\n", "const suspectProtoRx = /\"(?:_|\\\\u005[Ff])(?:_|\\\\u005[Ff])(?:p|\\\\u0070)(?:r|\\\\u0072)(?:o|\\\\u006[Ff])(?:t|\\\\u0074)(?:o|\\\\u006[Ff])(?:_|\\\\u005[Ff])(?:_|\\\\u005[Ff])\"\\s*:/;\nconst suspectConstructorRx = /\"(?:c|\\\\u0063)(?:o|\\\\u006[Ff])(?:n|\\\\u006[Ee])(?:s|\\\\u0073)(?:t|\\\\u0074)(?:r|\\\\u0072)(?:u|\\\\u0075)(?:c|\\\\u0063)(?:t|\\\\u0074)(?:o|\\\\u006[Ff])(?:r|\\\\u0072)\"\\s*:/;\nconst JsonSigRx = /^[\"{[]|^-?[0-9][0-9.]{0,14}$/;\nfunction jsonParseTransform(key, value) {\n if (key === \"__proto__\" || key === \"constructor\") {\n return;\n }\n return value;\n}\nfunction destr(val) {\n if (typeof val !== \"string\") {\n return val;\n }\n const _lval = val.toLowerCase();\n if (_lval === \"true\") {\n return true;\n }\n if (_lval === \"false\") {\n return false;\n }\n if (_lval === \"null\") {\n return null;\n }\n if (_lval === \"nan\") {\n return NaN;\n }\n if (_lval === \"infinity\") {\n return Infinity;\n }\n if (_lval === \"undefined\") {\n return void 0;\n }\n if (!JsonSigRx.test(val)) {\n return val;\n }\n try {\n if (suspectProtoRx.test(val) || suspectConstructorRx.test(val)) {\n return JSON.parse(val, jsonParseTransform);\n }\n return JSON.parse(val);\n } catch (_e) {\n return val;\n }\n}\n\nexport { destr as default };\n", "function isObject(val) {\n return val !== null && typeof val === \"object\";\n}\nfunction _defu(baseObj, defaults, namespace = \".\", merger) {\n if (!isObject(defaults)) {\n return _defu(baseObj, {}, namespace, merger);\n }\n const obj = Object.assign({}, defaults);\n for (const key in baseObj) {\n if (key === \"__proto__\" || key === \"constructor\") {\n continue;\n }\n const val = baseObj[key];\n if (val === null || val === void 0) {\n continue;\n }\n if (merger && merger(obj, key, val, namespace)) {\n continue;\n }\n if (Array.isArray(val) && Array.isArray(obj[key])) {\n obj[key] = val.concat(obj[key]);\n } else if (isObject(val) && isObject(obj[key])) {\n obj[key] = _defu(val, obj[key], (namespace ? `${namespace}.` : \"\") + key.toString(), merger);\n } else {\n obj[key] = val;\n }\n }\n return obj;\n}\nfunction createDefu(merger) {\n return (...args) => args.reduce((p, c) => _defu(p, c, \"\", merger), {});\n}\nconst defu = createDefu();\nconst defuFn = createDefu((obj, key, currentValue, _namespace) => {\n if (typeof obj[key] !== \"undefined\" && typeof currentValue === \"function\") {\n obj[key] = currentValue(obj[key]);\n return true;\n }\n});\nconst defuArrayFn = createDefu((obj, key, currentValue, _namespace) => {\n if (Array.isArray(obj[key]) && typeof currentValue === \"function\") {\n obj[key] = currentValue(obj[key]);\n return true;\n }\n});\n\nexport { createDefu, defu as default, defu, defuArrayFn, defuFn };\n", "import { statSync, promises } from 'fs';\nimport { resolve as resolve$1, dirname } from 'path';\nimport { resolvePath } from 'mlly';\nimport { resolve, join, isAbsolute } from 'pathe';\n\nconst defaultFindOptions = {\n startingFrom: \".\",\n rootPattern: /^node_modules$/,\n reverse: false,\n test: (filePath) => {\n try {\n if (statSync(filePath).isFile()) {\n return true;\n }\n } catch {\n }\n return null;\n }\n};\nasync function findFile(filename, _options = {}) {\n const options = { ...defaultFindOptions, ..._options };\n const basePath = resolve(options.startingFrom);\n const leadingSlash = basePath[0] === \"/\";\n const segments = basePath.split(\"/\").filter(Boolean);\n if (leadingSlash) {\n segments[0] = \"/\" + segments[0];\n }\n let root = segments.findIndex((r) => r.match(options.rootPattern));\n if (root === -1) {\n root = 0;\n }\n if (!options.reverse) {\n for (let i = segments.length; i > root; i--) {\n const filePath = join(...segments.slice(0, i), filename);\n if (await options.test(filePath)) {\n return filePath;\n }\n }\n } else {\n for (let i = root + 1; i <= segments.length; i++) {\n const filePath = join(...segments.slice(0, i), filename);\n if (await options.test(filePath)) {\n return filePath;\n }\n }\n }\n throw new Error(`Cannot find matching ${filename} in ${options.startingFrom} or parent directories`);\n}\nfunction findNearestFile(filename, _options = {}) {\n return findFile(filename, _options);\n}\nfunction findFarthestFile(filename, _options = {}) {\n return findFile(filename, { ..._options, reverse: true });\n}\n\nfunction definePackageJSON(pkg) {\n return pkg;\n}\nfunction defineTSConfig(tsconfig) {\n return tsconfig;\n}\nasync function readPackageJSON(id, opts = {}) {\n const resolvedPath = await resolvePackageJSON(id, opts);\n const blob = await promises.readFile(resolvedPath, \"utf-8\");\n return JSON.parse(blob);\n}\nasync function writePackageJSON(path, pkg) {\n await promises.writeFile(path, JSON.stringify(pkg, null, 2));\n}\nasync function readTSConfig(id, opts = {}) {\n const resolvedPath = await resolveTSConfig(id, opts);\n const blob = await promises.readFile(resolvedPath, \"utf-8\");\n const jsonc = await import('jsonc-parser');\n return jsonc.parse(blob);\n}\nasync function writeTSConfig(path, tsconfig) {\n await promises.writeFile(path, JSON.stringify(tsconfig, null, 2));\n}\nasync function resolvePackageJSON(id = process.cwd(), opts = {}) {\n const resolvedPath = isAbsolute(id) ? id : await resolvePath(id, opts);\n return findNearestFile(\"package.json\", { startingFrom: resolvedPath, ...opts });\n}\nasync function resolveTSConfig(id = process.cwd(), opts = {}) {\n const resolvedPath = isAbsolute(id) ? id : await resolvePath(id, opts);\n return findNearestFile(\"tsconfig.json\", { startingFrom: resolvedPath, ...opts });\n}\nconst lockFiles = [\"yarn.lock\", \"package-lock.json\", \"pnpm-lock.yaml\", \"npm-shrinkwrap.json\"];\nasync function resolveLockfile(id = process.cwd(), opts = {}) {\n const resolvedPath = isAbsolute(id) ? id : await resolvePath(id, opts);\n const _opts = { startingFrom: resolvedPath, ...opts };\n for (const lockFile of lockFiles) {\n try {\n return await findNearestFile(lockFile, _opts);\n } catch {\n }\n }\n throw new Error(\"No lockfile found from \" + id);\n}\nasync function findWorkspaceDir(id = process.cwd(), opts = {}) {\n const resolvedPath = isAbsolute(id) ? id : await resolvePath(id, opts);\n const _opts = { startingFrom: resolvedPath, ...opts };\n try {\n const r = await findNearestFile(\".git/config\", _opts);\n return resolve$1(r, \"../..\");\n } catch {\n }\n try {\n const r = await resolveLockfile(resolvedPath, { ..._opts, reverse: true });\n return dirname(r);\n } catch {\n }\n try {\n const r = await findFile(resolvedPath, _opts);\n return dirname(r);\n } catch {\n }\n throw new Error(\"Cannot detect workspace root from \" + id);\n}\n\nexport { definePackageJSON, defineTSConfig, findFarthestFile, findFile, findNearestFile, findWorkspaceDir, readPackageJSON, readTSConfig, resolveLockfile, resolvePackageJSON, resolveTSConfig, writePackageJSON, writeTSConfig };\n", "// This file was generated. Do not modify manually!\nvar astralIdentifierCodes = [509, 0, 227, 0, 150, 4, 294, 9, 1368, 2, 2, 1, 6, 3, 41, 2, 5, 0, 166, 1, 574, 3, 9, 9, 370, 1, 154, 10, 50, 3, 123, 2, 54, 14, 32, 10, 3, 1, 11, 3, 46, 10, 8, 0, 46, 9, 7, 2, 37, 13, 2, 9, 6, 1, 45, 0, 13, 2, 49, 13, 9, 3, 2, 11, 83, 11, 7, 0, 161, 11, 6, 9, 7, 3, 56, 1, 2, 6, 3, 1, 3, 2, 10, 0, 11, 1, 3, 6, 4, 4, 193, 17, 10, 9, 5, 0, 82, 19, 13, 9, 214, 6, 3, 8, 28, 1, 83, 16, 16, 9, 82, 12, 9, 9, 84, 14, 5, 9, 243, 14, 166, 9, 71, 5, 2, 1, 3, 3, 2, 0, 2, 1, 13, 9, 120, 6, 3, 6, 4, 0, 29, 9, 41, 6, 2, 3, 9, 0, 10, 10, 47, 15, 406, 7, 2, 7, 17, 9, 57, 21, 2, 13, 123, 5, 4, 0, 2, 1, 2, 6, 2, 0, 9, 9, 49, 4, 2, 1, 2, 4, 9, 9, 330, 3, 19306, 9, 87, 9, 39, 4, 60, 6, 26, 9, 1014, 0, 2, 54, 8, 3, 82, 0, 12, 1, 19628, 1, 4706, 45, 3, 22, 543, 4, 4, 5, 9, 7, 3, 6, 31, 3, 149, 2, 1418, 49, 513, 54, 5, 49, 9, 0, 15, 0, 23, 4, 2, 14, 1361, 6, 2, 16, 3, 6, 2, 1, 2, 4, 262, 6, 10, 9, 357, 0, 62, 13, 1495, 6, 110, 6, 6, 9, 4759, 9, 787719, 239];\n\n// This file was generated. Do not modify manually!\nvar astralIdentifierStartCodes = [0, 11, 2, 25, 2, 18, 2, 1, 2, 14, 3, 13, 35, 122, 70, 52, 268, 28, 4, 48, 48, 31, 14, 29, 6, 37, 11, 29, 3, 35, 5, 7, 2, 4, 43, 157, 19, 35, 5, 35, 5, 39, 9, 51, 13, 10, 2, 14, 2, 6, 2, 1, 2, 10, 2, 14, 2, 6, 2, 1, 68, 310, 10, 21, 11, 7, 25, 5, 2, 41, 2, 8, 70, 5, 3, 0, 2, 43, 2, 1, 4, 0, 3, 22, 11, 22, 10, 30, 66, 18, 2, 1, 11, 21, 11, 25, 71, 55, 7, 1, 65, 0, 16, 3, 2, 2, 2, 28, 43, 28, 4, 28, 36, 7, 2, 27, 28, 53, 11, 21, 11, 18, 14, 17, 111, 72, 56, 50, 14, 50, 14, 35, 349, 41, 7, 1, 79, 28, 11, 0, 9, 21, 43, 17, 47, 20, 28, 22, 13, 52, 58, 1, 3, 0, 14, 44, 33, 24, 27, 35, 30, 0, 3, 0, 9, 34, 4, 0, 13, 47, 15, 3, 22, 0, 2, 0, 36, 17, 2, 24, 85, 6, 2, 0, 2, 3, 2, 14, 2, 9, 8, 46, 39, 7, 3, 1, 3, 21, 2, 6, 2, 1, 2, 4, 4, 0, 19, 0, 13, 4, 159, 52, 19, 3, 21, 2, 31, 47, 21, 1, 2, 0, 185, 46, 42, 3, 37, 47, 21, 0, 60, 42, 14, 0, 72, 26, 38, 6, 186, 43, 117, 63, 32, 7, 3, 0, 3, 7, 2, 1, 2, 23, 16, 0, 2, 0, 95, 7, 3, 38, 17, 0, 2, 0, 29, 0, 11, 39, 8, 0, 22, 0, 12, 45, 20, 0, 19, 72, 264, 8, 2, 36, 18, 0, 50, 29, 113, 6, 2, 1, 2, 37, 22, 0, 26, 5, 2, 1, 2, 31, 15, 0, 328, 18, 190, 0, 80, 921, 103, 110, 18, 195, 2637, 96, 16, 1070, 4050, 582, 8634, 568, 8, 30, 18, 78, 18, 29, 19, 47, 17, 3, 32, 20, 6, 18, 689, 63, 129, 74, 6, 0, 67, 12, 65, 1, 2, 0, 29, 6135, 9, 1237, 43, 8, 8936, 3, 2, 6, 2, 1, 2, 290, 46, 2, 18, 3, 9, 395, 2309, 106, 6, 12, 4, 8, 8, 9, 5991, 84, 2, 70, 2, 1, 3, 0, 3, 1, 3, 3, 2, 11, 2, 0, 2, 6, 2, 64, 2, 3, 3, 7, 2, 6, 2, 27, 2, 3, 2, 4, 2, 0, 4, 6, 2, 339, 3, 24, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 7, 1845, 30, 482, 44, 11, 6, 17, 0, 322, 29, 19, 43, 1269, 6, 2, 3, 2, 1, 2, 14, 2, 196, 60, 67, 8, 0, 1205, 3, 2, 26, 2, 1, 2, 0, 3, 0, 2, 9, 2, 3, 2, 0, 2, 0, 7, 0, 5, 0, 2, 0, 2, 0, 2, 2, 2, 1, 2, 0, 3, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 3, 3, 2, 6, 2, 3, 2, 3, 2, 0, 2, 9, 2, 16, 6, 2, 2, 4, 2, 16, 4421, 42719, 33, 4152, 8, 221, 3, 5761, 15, 7472, 3104, 541, 1507, 4938];\n\n// This file was generated. Do not modify manually!\nvar nonASCIIidentifierChars = \"\\u200c\\u200d\\xb7\\u0300-\\u036f\\u0387\\u0483-\\u0487\\u0591-\\u05bd\\u05bf\\u05c1\\u05c2\\u05c4\\u05c5\\u05c7\\u0610-\\u061a\\u064b-\\u0669\\u0670\\u06d6-\\u06dc\\u06df-\\u06e4\\u06e7\\u06e8\\u06ea-\\u06ed\\u06f0-\\u06f9\\u0711\\u0730-\\u074a\\u07a6-\\u07b0\\u07c0-\\u07c9\\u07eb-\\u07f3\\u07fd\\u0816-\\u0819\\u081b-\\u0823\\u0825-\\u0827\\u0829-\\u082d\\u0859-\\u085b\\u0898-\\u089f\\u08ca-\\u08e1\\u08e3-\\u0903\\u093a-\\u093c\\u093e-\\u094f\\u0951-\\u0957\\u0962\\u0963\\u0966-\\u096f\\u0981-\\u0983\\u09bc\\u09be-\\u09c4\\u09c7\\u09c8\\u09cb-\\u09cd\\u09d7\\u09e2\\u09e3\\u09e6-\\u09ef\\u09fe\\u0a01-\\u0a03\\u0a3c\\u0a3e-\\u0a42\\u0a47\\u0a48\\u0a4b-\\u0a4d\\u0a51\\u0a66-\\u0a71\\u0a75\\u0a81-\\u0a83\\u0abc\\u0abe-\\u0ac5\\u0ac7-\\u0ac9\\u0acb-\\u0acd\\u0ae2\\u0ae3\\u0ae6-\\u0aef\\u0afa-\\u0aff\\u0b01-\\u0b03\\u0b3c\\u0b3e-\\u0b44\\u0b47\\u0b48\\u0b4b-\\u0b4d\\u0b55-\\u0b57\\u0b62\\u0b63\\u0b66-\\u0b6f\\u0b82\\u0bbe-\\u0bc2\\u0bc6-\\u0bc8\\u0bca-\\u0bcd\\u0bd7\\u0be6-\\u0bef\\u0c00-\\u0c04\\u0c3c\\u0c3e-\\u0c44\\u0c46-\\u0c48\\u0c4a-\\u0c4d\\u0c55\\u0c56\\u0c62\\u0c63\\u0c66-\\u0c6f\\u0c81-\\u0c83\\u0cbc\\u0cbe-\\u0cc4\\u0cc6-\\u0cc8\\u0cca-\\u0ccd\\u0cd5\\u0cd6\\u0ce2\\u0ce3\\u0ce6-\\u0cef\\u0d00-\\u0d03\\u0d3b\\u0d3c\\u0d3e-\\u0d44\\u0d46-\\u0d48\\u0d4a-\\u0d4d\\u0d57\\u0d62\\u0d63\\u0d66-\\u0d6f\\u0d81-\\u0d83\\u0dca\\u0dcf-\\u0dd4\\u0dd6\\u0dd8-\\u0ddf\\u0de6-\\u0def\\u0df2\\u0df3\\u0e31\\u0e34-\\u0e3a\\u0e47-\\u0e4e\\u0e50-\\u0e59\\u0eb1\\u0eb4-\\u0ebc\\u0ec8-\\u0ecd\\u0ed0-\\u0ed9\\u0f18\\u0f19\\u0f20-\\u0f29\\u0f35\\u0f37\\u0f39\\u0f3e\\u0f3f\\u0f71-\\u0f84\\u0f86\\u0f87\\u0f8d-\\u0f97\\u0f99-\\u0fbc\\u0fc6\\u102b-\\u103e\\u1040-\\u1049\\u1056-\\u1059\\u105e-\\u1060\\u1062-\\u1064\\u1067-\\u106d\\u1071-\\u1074\\u1082-\\u108d\\u108f-\\u109d\\u135d-\\u135f\\u1369-\\u1371\\u1712-\\u1715\\u1732-\\u1734\\u1752\\u1753\\u1772\\u1773\\u17b4-\\u17d3\\u17dd\\u17e0-\\u17e9\\u180b-\\u180d\\u180f-\\u1819\\u18a9\\u1920-\\u192b\\u1930-\\u193b\\u1946-\\u194f\\u19d0-\\u19da\\u1a17-\\u1a1b\\u1a55-\\u1a5e\\u1a60-\\u1a7c\\u1a7f-\\u1a89\\u1a90-\\u1a99\\u1ab0-\\u1abd\\u1abf-\\u1ace\\u1b00-\\u1b04\\u1b34-\\u1b44\\u1b50-\\u1b59\\u1b6b-\\u1b73\\u1b80-\\u1b82\\u1ba1-\\u1bad\\u1bb0-\\u1bb9\\u1be6-\\u1bf3\\u1c24-\\u1c37\\u1c40-\\u1c49\\u1c50-\\u1c59\\u1cd0-\\u1cd2\\u1cd4-\\u1ce8\\u1ced\\u1cf4\\u1cf7-\\u1cf9\\u1dc0-\\u1dff\\u203f\\u2040\\u2054\\u20d0-\\u20dc\\u20e1\\u20e5-\\u20f0\\u2cef-\\u2cf1\\u2d7f\\u2de0-\\u2dff\\u302a-\\u302f\\u3099\\u309a\\ua620-\\ua629\\ua66f\\ua674-\\ua67d\\ua69e\\ua69f\\ua6f0\\ua6f1\\ua802\\ua806\\ua80b\\ua823-\\ua827\\ua82c\\ua880\\ua881\\ua8b4-\\ua8c5\\ua8d0-\\ua8d9\\ua8e0-\\ua8f1\\ua8ff-\\ua909\\ua926-\\ua92d\\ua947-\\ua953\\ua980-\\ua983\\ua9b3-\\ua9c0\\ua9d0-\\ua9d9\\ua9e5\\ua9f0-\\ua9f9\\uaa29-\\uaa36\\uaa43\\uaa4c\\uaa4d\\uaa50-\\uaa59\\uaa7b-\\uaa7d\\uaab0\\uaab2-\\uaab4\\uaab7\\uaab8\\uaabe\\uaabf\\uaac1\\uaaeb-\\uaaef\\uaaf5\\uaaf6\\uabe3-\\uabea\\uabec\\uabed\\uabf0-\\uabf9\\ufb1e\\ufe00-\\ufe0f\\ufe20-\\ufe2f\\ufe33\\ufe34\\ufe4d-\\ufe4f\\uff10-\\uff19\\uff3f\";\n\n// This file was generated. Do not modify manually!\nvar nonASCIIidentifierStartChars = \"\\xaa\\xb5\\xba\\xc0-\\xd6\\xd8-\\xf6\\xf8-\\u02c1\\u02c6-\\u02d1\\u02e0-\\u02e4\\u02ec\\u02ee\\u0370-\\u0374\\u0376\\u0377\\u037a-\\u037d\\u037f\\u0386\\u0388-\\u038a\\u038c\\u038e-\\u03a1\\u03a3-\\u03f5\\u03f7-\\u0481\\u048a-\\u052f\\u0531-\\u0556\\u0559\\u0560-\\u0588\\u05d0-\\u05ea\\u05ef-\\u05f2\\u0620-\\u064a\\u066e\\u066f\\u0671-\\u06d3\\u06d5\\u06e5\\u06e6\\u06ee\\u06ef\\u06fa-\\u06fc\\u06ff\\u0710\\u0712-\\u072f\\u074d-\\u07a5\\u07b1\\u07ca-\\u07ea\\u07f4\\u07f5\\u07fa\\u0800-\\u0815\\u081a\\u0824\\u0828\\u0840-\\u0858\\u0860-\\u086a\\u0870-\\u0887\\u0889-\\u088e\\u08a0-\\u08c9\\u0904-\\u0939\\u093d\\u0950\\u0958-\\u0961\\u0971-\\u0980\\u0985-\\u098c\\u098f\\u0990\\u0993-\\u09a8\\u09aa-\\u09b0\\u09b2\\u09b6-\\u09b9\\u09bd\\u09ce\\u09dc\\u09dd\\u09df-\\u09e1\\u09f0\\u09f1\\u09fc\\u0a05-\\u0a0a\\u0a0f\\u0a10\\u0a13-\\u0a28\\u0a2a-\\u0a30\\u0a32\\u0a33\\u0a35\\u0a36\\u0a38\\u0a39\\u0a59-\\u0a5c\\u0a5e\\u0a72-\\u0a74\\u0a85-\\u0a8d\\u0a8f-\\u0a91\\u0a93-\\u0aa8\\u0aaa-\\u0ab0\\u0ab2\\u0ab3\\u0ab5-\\u0ab9\\u0abd\\u0ad0\\u0ae0\\u0ae1\\u0af9\\u0b05-\\u0b0c\\u0b0f\\u0b10\\u0b13-\\u0b28\\u0b2a-\\u0b30\\u0b32\\u0b33\\u0b35-\\u0b39\\u0b3d\\u0b5c\\u0b5d\\u0b5f-\\u0b61\\u0b71\\u0b83\\u0b85-\\u0b8a\\u0b8e-\\u0b90\\u0b92-\\u0b95\\u0b99\\u0b9a\\u0b9c\\u0b9e\\u0b9f\\u0ba3\\u0ba4\\u0ba8-\\u0baa\\u0bae-\\u0bb9\\u0bd0\\u0c05-\\u0c0c\\u0c0e-\\u0c10\\u0c12-\\u0c28\\u0c2a-\\u0c39\\u0c3d\\u0c58-\\u0c5a\\u0c5d\\u0c60\\u0c61\\u0c80\\u0c85-\\u0c8c\\u0c8e-\\u0c90\\u0c92-\\u0ca8\\u0caa-\\u0cb3\\u0cb5-\\u0cb9\\u0cbd\\u0cdd\\u0cde\\u0ce0\\u0ce1\\u0cf1\\u0cf2\\u0d04-\\u0d0c\\u0d0e-\\u0d10\\u0d12-\\u0d3a\\u0d3d\\u0d4e\\u0d54-\\u0d56\\u0d5f-\\u0d61\\u0d7a-\\u0d7f\\u0d85-\\u0d96\\u0d9a-\\u0db1\\u0db3-\\u0dbb\\u0dbd\\u0dc0-\\u0dc6\\u0e01-\\u0e30\\u0e32\\u0e33\\u0e40-\\u0e46\\u0e81\\u0e82\\u0e84\\u0e86-\\u0e8a\\u0e8c-\\u0ea3\\u0ea5\\u0ea7-\\u0eb0\\u0eb2\\u0eb3\\u0ebd\\u0ec0-\\u0ec4\\u0ec6\\u0edc-\\u0edf\\u0f00\\u0f40-\\u0f47\\u0f49-\\u0f6c\\u0f88-\\u0f8c\\u1000-\\u102a\\u103f\\u1050-\\u1055\\u105a-\\u105d\\u1061\\u1065\\u1066\\u106e-\\u1070\\u1075-\\u1081\\u108e\\u10a0-\\u10c5\\u10c7\\u10cd\\u10d0-\\u10fa\\u10fc-\\u1248\\u124a-\\u124d\\u1250-\\u1256\\u1258\\u125a-\\u125d\\u1260-\\u1288\\u128a-\\u128d\\u1290-\\u12b0\\u12b2-\\u12b5\\u12b8-\\u12be\\u12c0\\u12c2-\\u12c5\\u12c8-\\u12d6\\u12d8-\\u1310\\u1312-\\u1315\\u1318-\\u135a\\u1380-\\u138f\\u13a0-\\u13f5\\u13f8-\\u13fd\\u1401-\\u166c\\u166f-\\u167f\\u1681-\\u169a\\u16a0-\\u16ea\\u16ee-\\u16f8\\u1700-\\u1711\\u171f-\\u1731\\u1740-\\u1751\\u1760-\\u176c\\u176e-\\u1770\\u1780-\\u17b3\\u17d7\\u17dc\\u1820-\\u1878\\u1880-\\u18a8\\u18aa\\u18b0-\\u18f5\\u1900-\\u191e\\u1950-\\u196d\\u1970-\\u1974\\u1980-\\u19ab\\u19b0-\\u19c9\\u1a00-\\u1a16\\u1a20-\\u1a54\\u1aa7\\u1b05-\\u1b33\\u1b45-\\u1b4c\\u1b83-\\u1ba0\\u1bae\\u1baf\\u1bba-\\u1be5\\u1c00-\\u1c23\\u1c4d-\\u1c4f\\u1c5a-\\u1c7d\\u1c80-\\u1c88\\u1c90-\\u1cba\\u1cbd-\\u1cbf\\u1ce9-\\u1cec\\u1cee-\\u1cf3\\u1cf5\\u1cf6\\u1cfa\\u1d00-\\u1dbf\\u1e00-\\u1f15\\u1f18-\\u1f1d\\u1f20-\\u1f45\\u1f48-\\u1f4d\\u1f50-\\u1f57\\u1f59\\u1f5b\\u1f5d\\u1f5f-\\u1f7d\\u1f80-\\u1fb4\\u1fb6-\\u1fbc\\u1fbe\\u1fc2-\\u1fc4\\u1fc6-\\u1fcc\\u1fd0-\\u1fd3\\u1fd6-\\u1fdb\\u1fe0-\\u1fec\\u1ff2-\\u1ff4\\u1ff6-\\u1ffc\\u2071\\u207f\\u2090-\\u209c\\u2102\\u2107\\u210a-\\u2113\\u2115\\u2118-\\u211d\\u2124\\u2126\\u2128\\u212a-\\u2139\\u213c-\\u213f\\u2145-\\u2149\\u214e\\u2160-\\u2188\\u2c00-\\u2ce4\\u2ceb-\\u2cee\\u2cf2\\u2cf3\\u2d00-\\u2d25\\u2d27\\u2d2d\\u2d30-\\u2d67\\u2d6f\\u2d80-\\u2d96\\u2da0-\\u2da6\\u2da8-\\u2dae\\u2db0-\\u2db6\\u2db8-\\u2dbe\\u2dc0-\\u2dc6\\u2dc8-\\u2dce\\u2dd0-\\u2dd6\\u2dd8-\\u2dde\\u3005-\\u3007\\u3021-\\u3029\\u3031-\\u3035\\u3038-\\u303c\\u3041-\\u3096\\u309b-\\u309f\\u30a1-\\u30fa\\u30fc-\\u30ff\\u3105-\\u312f\\u3131-\\u318e\\u31a0-\\u31bf\\u31f0-\\u31ff\\u3400-\\u4dbf\\u4e00-\\ua48c\\ua4d0-\\ua4fd\\ua500-\\ua60c\\ua610-\\ua61f\\ua62a\\ua62b\\ua640-\\ua66e\\ua67f-\\ua69d\\ua6a0-\\ua6ef\\ua717-\\ua71f\\ua722-\\ua788\\ua78b-\\ua7ca\\ua7d0\\ua7d1\\ua7d3\\ua7d5-\\ua7d9\\ua7f2-\\ua801\\ua803-\\ua805\\ua807-\\ua80a\\ua80c-\\ua822\\ua840-\\ua873\\ua882-\\ua8b3\\ua8f2-\\ua8f7\\ua8fb\\ua8fd\\ua8fe\\ua90a-\\ua925\\ua930-\\ua946\\ua960-\\ua97c\\ua984-\\ua9b2\\ua9cf\\ua9e0-\\ua9e4\\ua9e6-\\ua9ef\\ua9fa-\\ua9fe\\uaa00-\\uaa28\\uaa40-\\uaa42\\uaa44-\\uaa4b\\uaa60-\\uaa76\\uaa7a\\uaa7e-\\uaaaf\\uaab1\\uaab5\\uaab6\\uaab9-\\uaabd\\uaac0\\uaac2\\uaadb-\\uaadd\\uaae0-\\uaaea\\uaaf2-\\uaaf4\\uab01-\\uab06\\uab09-\\uab0e\\uab11-\\uab16\\uab20-\\uab26\\uab28-\\uab2e\\uab30-\\uab5a\\uab5c-\\uab69\\uab70-\\uabe2\\uac00-\\ud7a3\\ud7b0-\\ud7c6\\ud7cb-\\ud7fb\\uf900-\\ufa6d\\ufa70-\\ufad9\\ufb00-\\ufb06\\ufb13-\\ufb17\\ufb1d\\ufb1f-\\ufb28\\ufb2a-\\ufb36\\ufb38-\\ufb3c\\ufb3e\\ufb40\\ufb41\\ufb43\\ufb44\\ufb46-\\ufbb1\\ufbd3-\\ufd3d\\ufd50-\\ufd8f\\ufd92-\\ufdc7\\ufdf0-\\ufdfb\\ufe70-\\ufe74\\ufe76-\\ufefc\\uff21-\\uff3a\\uff41-\\uff5a\\uff66-\\uffbe\\uffc2-\\uffc7\\uffca-\\uffcf\\uffd2-\\uffd7\\uffda-\\uffdc\";\n\n// These are a run-length and offset encoded representation of the\n\n// Reserved word lists for various dialects of the language\n\nvar reservedWords = {\n 3: \"abstract boolean byte char class double enum export extends final float goto implements import int interface long native package private protected public short static super synchronized throws transient volatile\",\n 5: \"class enum extends super const export import\",\n 6: \"enum\",\n strict: \"implements interface let package private protected public static yield\",\n strictBind: \"eval arguments\"\n};\n\n// And the keywords\n\nvar ecma5AndLessKeywords = \"break case catch continue debugger default do else finally for function if return switch throw try var while with null true false instanceof typeof void delete new in this\";\n\nvar keywords$1 = {\n 5: ecma5AndLessKeywords,\n \"5module\": ecma5AndLessKeywords + \" export import\",\n 6: ecma5AndLessKeywords + \" const class extends export import super\"\n};\n\nvar keywordRelationalOperator = /^in(stanceof)?$/;\n\n// ## Character categories\n\nvar nonASCIIidentifierStart = new RegExp(\"[\" + nonASCIIidentifierStartChars + \"]\");\nvar nonASCIIidentifier = new RegExp(\"[\" + nonASCIIidentifierStartChars + nonASCIIidentifierChars + \"]\");\n\n// This has a complexity linear to the value of the code. The\n// assumption is that looking up astral identifier characters is\n// rare.\nfunction isInAstralSet(code, set) {\n var pos = 0x10000;\n for (var i = 0; i < set.length; i += 2) {\n pos += set[i];\n if (pos > code) { return false }\n pos += set[i + 1];\n if (pos >= code) { return true }\n }\n}\n\n// Test whether a given character code starts an identifier.\n\nfunction isIdentifierStart(code, astral) {\n if (code < 65) { return code === 36 }\n if (code < 91) { return true }\n if (code < 97) { return code === 95 }\n if (code < 123) { return true }\n if (code <= 0xffff) { return code >= 0xaa && nonASCIIidentifierStart.test(String.fromCharCode(code)) }\n if (astral === false) { return false }\n return isInAstralSet(code, astralIdentifierStartCodes)\n}\n\n// Test whether a given character is part of an identifier.\n\nfunction isIdentifierChar(code, astral) {\n if (code < 48) { return code === 36 }\n if (code < 58) { return true }\n if (code < 65) { return false }\n if (code < 91) { return true }\n if (code < 97) { return code === 95 }\n if (code < 123) { return true }\n if (code <= 0xffff) { return code >= 0xaa && nonASCIIidentifier.test(String.fromCharCode(code)) }\n if (astral === false) { return false }\n return isInAstralSet(code, astralIdentifierStartCodes) || isInAstralSet(code, astralIdentifierCodes)\n}\n\n// ## Token types\n\n// The assignment of fine-grained, information-carrying type objects\n// allows the tokenizer to store the information it has about a\n// token in a way that is very cheap for the parser to look up.\n\n// All token type variables start with an underscore, to make them\n// easy to recognize.\n\n// The `beforeExpr` property is used to disambiguate between regular\n// expressions and divisions. It is set on all token types that can\n// be followed by an expression (thus, a slash after them would be a\n// regular expression).\n//\n// The `startsExpr` property is used to check if the token ends a\n// `yield` expression. It is set on all token types that either can\n// directly start an expression (like a quotation mark) or can\n// continue an expression (like the body of a string).\n//\n// `isLoop` marks a keyword as starting a loop, which is important\n// to know when parsing a label, in order to allow or disallow\n// continue jumps to that label.\n\nvar TokenType = function TokenType(label, conf) {\n if ( conf === void 0 ) conf = {};\n\n this.label = label;\n this.keyword = conf.keyword;\n this.beforeExpr = !!conf.beforeExpr;\n this.startsExpr = !!conf.startsExpr;\n this.isLoop = !!conf.isLoop;\n this.isAssign = !!conf.isAssign;\n this.prefix = !!conf.prefix;\n this.postfix = !!conf.postfix;\n this.binop = conf.binop || null;\n this.updateContext = null;\n};\n\nfunction binop(name, prec) {\n return new TokenType(name, {beforeExpr: true, binop: prec})\n}\nvar beforeExpr = {beforeExpr: true}, startsExpr = {startsExpr: true};\n\n// Map keyword names to token types.\n\nvar keywords = {};\n\n// Succinct definitions of keyword token types\nfunction kw(name, options) {\n if ( options === void 0 ) options = {};\n\n options.keyword = name;\n return keywords[name] = new TokenType(name, options)\n}\n\nvar types$1 = {\n num: new TokenType(\"num\", startsExpr),\n regexp: new TokenType(\"regexp\", startsExpr),\n string: new TokenType(\"string\", startsExpr),\n name: new TokenType(\"name\", startsExpr),\n privateId: new TokenType(\"privateId\", startsExpr),\n eof: new TokenType(\"eof\"),\n\n // Punctuation token types.\n bracketL: new TokenType(\"[\", {beforeExpr: true, startsExpr: true}),\n bracketR: new TokenType(\"]\"),\n braceL: new TokenType(\"{\", {beforeExpr: true, startsExpr: true}),\n braceR: new TokenType(\"}\"),\n parenL: new TokenType(\"(\", {beforeExpr: true, startsExpr: true}),\n parenR: new TokenType(\")\"),\n comma: new TokenType(\",\", beforeExpr),\n semi: new TokenType(\";\", beforeExpr),\n colon: new TokenType(\":\", beforeExpr),\n dot: new TokenType(\".\"),\n question: new TokenType(\"?\", beforeExpr),\n questionDot: new TokenType(\"?.\"),\n arrow: new TokenType(\"=>\", beforeExpr),\n template: new TokenType(\"template\"),\n invalidTemplate: new TokenType(\"invalidTemplate\"),\n ellipsis: new TokenType(\"...\", beforeExpr),\n backQuote: new TokenType(\"`\", startsExpr),\n dollarBraceL: new TokenType(\"${\", {beforeExpr: true, startsExpr: true}),\n\n // Operators. These carry several kinds of properties to help the\n // parser use them properly (the presence of these properties is\n // what categorizes them as operators).\n //\n // `binop`, when present, specifies that this operator is a binary\n // operator, and will refer to its precedence.\n //\n // `prefix` and `postfix` mark the operator as a prefix or postfix\n // unary operator.\n //\n // `isAssign` marks all of `=`, `+=`, `-=` etcetera, which act as\n // binary operators with a very low precedence, that should result\n // in AssignmentExpression nodes.\n\n eq: new TokenType(\"=\", {beforeExpr: true, isAssign: true}),\n assign: new TokenType(\"_=\", {beforeExpr: true, isAssign: true}),\n incDec: new TokenType(\"++/--\", {prefix: true, postfix: true, startsExpr: true}),\n prefix: new TokenType(\"!/~\", {beforeExpr: true, prefix: true, startsExpr: true}),\n logicalOR: binop(\"||\", 1),\n logicalAND: binop(\"&&\", 2),\n bitwiseOR: binop(\"|\", 3),\n bitwiseXOR: binop(\"^\", 4),\n bitwiseAND: binop(\"&\", 5),\n equality: binop(\"==/!=/===/!==\", 6),\n relational: binop(\"/<=/>=\", 7),\n bitShift: binop(\"<>/>>>\", 8),\n plusMin: new TokenType(\"+/-\", {beforeExpr: true, binop: 9, prefix: true, startsExpr: true}),\n modulo: binop(\"%\", 10),\n star: binop(\"*\", 10),\n slash: binop(\"/\", 10),\n starstar: new TokenType(\"**\", {beforeExpr: true}),\n coalesce: binop(\"??\", 1),\n\n // Keyword token types.\n _break: kw(\"break\"),\n _case: kw(\"case\", beforeExpr),\n _catch: kw(\"catch\"),\n _continue: kw(\"continue\"),\n _debugger: kw(\"debugger\"),\n _default: kw(\"default\", beforeExpr),\n _do: kw(\"do\", {isLoop: true, beforeExpr: true}),\n _else: kw(\"else\", beforeExpr),\n _finally: kw(\"finally\"),\n _for: kw(\"for\", {isLoop: true}),\n _function: kw(\"function\", startsExpr),\n _if: kw(\"if\"),\n _return: kw(\"return\", beforeExpr),\n _switch: kw(\"switch\"),\n _throw: kw(\"throw\", beforeExpr),\n _try: kw(\"try\"),\n _var: kw(\"var\"),\n _const: kw(\"const\"),\n _while: kw(\"while\", {isLoop: true}),\n _with: kw(\"with\"),\n _new: kw(\"new\", {beforeExpr: true, startsExpr: true}),\n _this: kw(\"this\", startsExpr),\n _super: kw(\"super\", startsExpr),\n _class: kw(\"class\", startsExpr),\n _extends: kw(\"extends\", beforeExpr),\n _export: kw(\"export\"),\n _import: kw(\"import\", startsExpr),\n _null: kw(\"null\", startsExpr),\n _true: kw(\"true\", startsExpr),\n _false: kw(\"false\", startsExpr),\n _in: kw(\"in\", {beforeExpr: true, binop: 7}),\n _instanceof: kw(\"instanceof\", {beforeExpr: true, binop: 7}),\n _typeof: kw(\"typeof\", {beforeExpr: true, prefix: true, startsExpr: true}),\n _void: kw(\"void\", {beforeExpr: true, prefix: true, startsExpr: true}),\n _delete: kw(\"delete\", {beforeExpr: true, prefix: true, startsExpr: true})\n};\n\n// Matches a whole line break (where CRLF is considered a single\n// line break). Used to count lines.\n\nvar lineBreak = /\\r\\n?|\\n|\\u2028|\\u2029/;\nvar lineBreakG = new RegExp(lineBreak.source, \"g\");\n\nfunction isNewLine(code) {\n return code === 10 || code === 13 || code === 0x2028 || code === 0x2029\n}\n\nfunction nextLineBreak(code, from, end) {\n if ( end === void 0 ) end = code.length;\n\n for (var i = from; i < end; i++) {\n var next = code.charCodeAt(i);\n if (isNewLine(next))\n { return i < end - 1 && next === 13 && code.charCodeAt(i + 1) === 10 ? i + 2 : i + 1 }\n }\n return -1\n}\n\nvar nonASCIIwhitespace = /[\\u1680\\u2000-\\u200a\\u202f\\u205f\\u3000\\ufeff]/;\n\nvar skipWhiteSpace = /(?:\\s|\\/\\/.*|\\/\\*[^]*?\\*\\/)*/g;\n\nvar ref = Object.prototype;\nvar hasOwnProperty = ref.hasOwnProperty;\nvar toString = ref.toString;\n\nvar hasOwn = Object.hasOwn || (function (obj, propName) { return (\n hasOwnProperty.call(obj, propName)\n); });\n\nvar isArray = Array.isArray || (function (obj) { return (\n toString.call(obj) === \"[object Array]\"\n); });\n\nfunction wordsRegexp(words) {\n return new RegExp(\"^(?:\" + words.replace(/ /g, \"|\") + \")$\")\n}\n\nfunction codePointToString(code) {\n // UTF-16 Decoding\n if (code <= 0xFFFF) { return String.fromCharCode(code) }\n code -= 0x10000;\n return String.fromCharCode((code >> 10) + 0xD800, (code & 1023) + 0xDC00)\n}\n\nvar loneSurrogate = /(?:[\\uD800-\\uDBFF](?![\\uDC00-\\uDFFF])|(?:[^\\uD800-\\uDBFF]|^)[\\uDC00-\\uDFFF])/;\n\n// These are used when `options.locations` is on, for the\n// `startLoc` and `endLoc` properties.\n\nvar Position = function Position(line, col) {\n this.line = line;\n this.column = col;\n};\n\nPosition.prototype.offset = function offset (n) {\n return new Position(this.line, this.column + n)\n};\n\nvar SourceLocation = function SourceLocation(p, start, end) {\n this.start = start;\n this.end = end;\n if (p.sourceFile !== null) { this.source = p.sourceFile; }\n};\n\n// The `getLineInfo` function is mostly useful when the\n// `locations` option is off (for performance reasons) and you\n// want to find the line/column position for a given character\n// offset. `input` should be the code string that the offset refers\n// into.\n\nfunction getLineInfo(input, offset) {\n for (var line = 1, cur = 0;;) {\n var nextBreak = nextLineBreak(input, cur, offset);\n if (nextBreak < 0) { return new Position(line, offset - cur) }\n ++line;\n cur = nextBreak;\n }\n}\n\n// A second argument must be given to configure the parser process.\n// These options are recognized (only `ecmaVersion` is required):\n\nvar defaultOptions = {\n // `ecmaVersion` indicates the ECMAScript version to parse. Must be\n // either 3, 5, 6 (or 2015), 7 (2016), 8 (2017), 9 (2018), 10\n // (2019), 11 (2020), 12 (2021), 13 (2022), 14 (2023), or `\"latest\"`\n // (the latest version the library supports). This influences\n // support for strict mode, the set of reserved words, and support\n // for new syntax features.\n ecmaVersion: null,\n // `sourceType` indicates the mode the code should be parsed in.\n // Can be either `\"script\"` or `\"module\"`. This influences global\n // strict mode and parsing of `import` and `export` declarations.\n sourceType: \"script\",\n // `onInsertedSemicolon` can be a callback that will be called\n // when a semicolon is automatically inserted. It will be passed\n // the position of the comma as an offset, and if `locations` is\n // enabled, it is given the location as a `{line, column}` object\n // as second argument.\n onInsertedSemicolon: null,\n // `onTrailingComma` is similar to `onInsertedSemicolon`, but for\n // trailing commas.\n onTrailingComma: null,\n // By default, reserved words are only enforced if ecmaVersion >= 5.\n // Set `allowReserved` to a boolean value to explicitly turn this on\n // an off. When this option has the value \"never\", reserved words\n // and keywords can also not be used as property names.\n allowReserved: null,\n // When enabled, a return at the top level is not considered an\n // error.\n allowReturnOutsideFunction: false,\n // When enabled, import/export statements are not constrained to\n // appearing at the top of the program, and an import.meta expression\n // in a script isn't considered an error.\n allowImportExportEverywhere: false,\n // By default, await identifiers are allowed to appear at the top-level scope only if ecmaVersion >= 2022.\n // When enabled, await identifiers are allowed to appear at the top-level scope,\n // but they are still not allowed in non-async functions.\n allowAwaitOutsideFunction: null,\n // When enabled, super identifiers are not constrained to\n // appearing in methods and do not raise an error when they appear elsewhere.\n allowSuperOutsideMethod: null,\n // When enabled, hashbang directive in the beginning of file is\n // allowed and treated as a line comment. Enabled by default when\n // `ecmaVersion` >= 2023.\n allowHashBang: false,\n // When `locations` is on, `loc` properties holding objects with\n // `start` and `end` properties in `{line, column}` form (with\n // line being 1-based and column 0-based) will be attached to the\n // nodes.\n locations: false,\n // A function can be passed as `onToken` option, which will\n // cause Acorn to call that function with object in the same\n // format as tokens returned from `tokenizer().getToken()`. Note\n // that you are not allowed to call the parser from the\n // callback\u2014that will corrupt its internal state.\n onToken: null,\n // A function can be passed as `onComment` option, which will\n // cause Acorn to call that function with `(block, text, start,\n // end)` parameters whenever a comment is skipped. `block` is a\n // boolean indicating whether this is a block (`/* */`) comment,\n // `text` is the content of the comment, and `start` and `end` are\n // character offsets that denote the start and end of the comment.\n // When the `locations` option is on, two more parameters are\n // passed, the full `{line, column}` locations of the start and\n // end of the comments. Note that you are not allowed to call the\n // parser from the callback\u2014that will corrupt its internal state.\n onComment: null,\n // Nodes have their start and end characters offsets recorded in\n // `start` and `end` properties (directly on the node, rather than\n // the `loc` object, which holds line/column data. To also add a\n // [semi-standardized][range] `range` property holding a `[start,\n // end]` array with the same numbers, set the `ranges` option to\n // `true`.\n //\n // [range]: https://bugzilla.mozilla.org/show_bug.cgi?id=745678\n ranges: false,\n // It is possible to parse multiple files into a single AST by\n // passing the tree produced by parsing the first file as\n // `program` option in subsequent parses. This will add the\n // toplevel forms of the parsed file to the `Program` (top) node\n // of an existing parse tree.\n program: null,\n // When `locations` is on, you can pass this to record the source\n // file in every node's `loc` object.\n sourceFile: null,\n // This value, if given, is stored in every node, whether\n // `locations` is on or off.\n directSourceFile: null,\n // When enabled, parenthesized expressions are represented by\n // (non-standard) ParenthesizedExpression nodes\n preserveParens: false\n};\n\n// Interpret and default an options object\n\nvar warnedAboutEcmaVersion = false;\n\nfunction getOptions(opts) {\n var options = {};\n\n for (var opt in defaultOptions)\n { options[opt] = opts && hasOwn(opts, opt) ? opts[opt] : defaultOptions[opt]; }\n\n if (options.ecmaVersion === \"latest\") {\n options.ecmaVersion = 1e8;\n } else if (options.ecmaVersion == null) {\n if (!warnedAboutEcmaVersion && typeof console === \"object\" && console.warn) {\n warnedAboutEcmaVersion = true;\n console.warn(\"Since Acorn 8.0.0, options.ecmaVersion is required.\\nDefaulting to 2020, but this will stop working in the future.\");\n }\n options.ecmaVersion = 11;\n } else if (options.ecmaVersion >= 2015) {\n options.ecmaVersion -= 2009;\n }\n\n if (options.allowReserved == null)\n { options.allowReserved = options.ecmaVersion < 5; }\n\n if (opts.allowHashBang == null)\n { options.allowHashBang = options.ecmaVersion >= 14; }\n\n if (isArray(options.onToken)) {\n var tokens = options.onToken;\n options.onToken = function (token) { return tokens.push(token); };\n }\n if (isArray(options.onComment))\n { options.onComment = pushComment(options, options.onComment); }\n\n return options\n}\n\nfunction pushComment(options, array) {\n return function(block, text, start, end, startLoc, endLoc) {\n var comment = {\n type: block ? \"Block\" : \"Line\",\n value: text,\n start: start,\n end: end\n };\n if (options.locations)\n { comment.loc = new SourceLocation(this, startLoc, endLoc); }\n if (options.ranges)\n { comment.range = [start, end]; }\n array.push(comment);\n }\n}\n\n// Each scope gets a bitset that may contain these flags\nvar\n SCOPE_TOP = 1,\n SCOPE_FUNCTION = 2,\n SCOPE_ASYNC = 4,\n SCOPE_GENERATOR = 8,\n SCOPE_ARROW = 16,\n SCOPE_SIMPLE_CATCH = 32,\n SCOPE_SUPER = 64,\n SCOPE_DIRECT_SUPER = 128,\n SCOPE_CLASS_STATIC_BLOCK = 256,\n SCOPE_VAR = SCOPE_TOP | SCOPE_FUNCTION | SCOPE_CLASS_STATIC_BLOCK;\n\nfunction functionFlags(async, generator) {\n return SCOPE_FUNCTION | (async ? SCOPE_ASYNC : 0) | (generator ? SCOPE_GENERATOR : 0)\n}\n\n// Used in checkLVal* and declareName to determine the type of a binding\nvar\n BIND_NONE = 0, // Not a binding\n BIND_VAR = 1, // Var-style binding\n BIND_LEXICAL = 2, // Let- or const-style binding\n BIND_FUNCTION = 3, // Function declaration\n BIND_SIMPLE_CATCH = 4, // Simple (identifier pattern) catch binding\n BIND_OUTSIDE = 5; // Special case for function names as bound inside the function\n\nvar Parser = function Parser(options, input, startPos) {\n this.options = options = getOptions(options);\n this.sourceFile = options.sourceFile;\n this.keywords = wordsRegexp(keywords$1[options.ecmaVersion >= 6 ? 6 : options.sourceType === \"module\" ? \"5module\" : 5]);\n var reserved = \"\";\n if (options.allowReserved !== true) {\n reserved = reservedWords[options.ecmaVersion >= 6 ? 6 : options.ecmaVersion === 5 ? 5 : 3];\n if (options.sourceType === \"module\") { reserved += \" await\"; }\n }\n this.reservedWords = wordsRegexp(reserved);\n var reservedStrict = (reserved ? reserved + \" \" : \"\") + reservedWords.strict;\n this.reservedWordsStrict = wordsRegexp(reservedStrict);\n this.reservedWordsStrictBind = wordsRegexp(reservedStrict + \" \" + reservedWords.strictBind);\n this.input = String(input);\n\n // Used to signal to callers of `readWord1` whether the word\n // contained any escape sequences. This is needed because words with\n // escape sequences must not be interpreted as keywords.\n this.containsEsc = false;\n\n // Set up token state\n\n // The current position of the tokenizer in the input.\n if (startPos) {\n this.pos = startPos;\n this.lineStart = this.input.lastIndexOf(\"\\n\", startPos - 1) + 1;\n this.curLine = this.input.slice(0, this.lineStart).split(lineBreak).length;\n } else {\n this.pos = this.lineStart = 0;\n this.curLine = 1;\n }\n\n // Properties of the current token:\n // Its type\n this.type = types$1.eof;\n // For tokens that include more information than their type, the value\n this.value = null;\n // Its start and end offset\n this.start = this.end = this.pos;\n // And, if locations are used, the {line, column} object\n // corresponding to those offsets\n this.startLoc = this.endLoc = this.curPosition();\n\n // Position information for the previous token\n this.lastTokEndLoc = this.lastTokStartLoc = null;\n this.lastTokStart = this.lastTokEnd = this.pos;\n\n // The context stack is used to superficially track syntactic\n // context to predict whether a regular expression is allowed in a\n // given position.\n this.context = this.initialContext();\n this.exprAllowed = true;\n\n // Figure out if it's a module code.\n this.inModule = options.sourceType === \"module\";\n this.strict = this.inModule || this.strictDirective(this.pos);\n\n // Used to signify the start of a potential arrow function\n this.potentialArrowAt = -1;\n this.potentialArrowInForAwait = false;\n\n // Positions to delayed-check that yield/await does not exist in default parameters.\n this.yieldPos = this.awaitPos = this.awaitIdentPos = 0;\n // Labels in scope.\n this.labels = [];\n // Thus-far undefined exports.\n this.undefinedExports = Object.create(null);\n\n // If enabled, skip leading hashbang line.\n if (this.pos === 0 && options.allowHashBang && this.input.slice(0, 2) === \"#!\")\n { this.skipLineComment(2); }\n\n // Scope tracking for duplicate variable names (see scope.js)\n this.scopeStack = [];\n this.enterScope(SCOPE_TOP);\n\n // For RegExp validation\n this.regexpState = null;\n\n // The stack of private names.\n // Each element has two properties: 'declared' and 'used'.\n // When it exited from the outermost class definition, all used private names must be declared.\n this.privateNameStack = [];\n};\n\nvar prototypeAccessors = { inFunction: { configurable: true },inGenerator: { configurable: true },inAsync: { configurable: true },canAwait: { configurable: true },allowSuper: { configurable: true },allowDirectSuper: { configurable: true },treatFunctionsAsVar: { configurable: true },allowNewDotTarget: { configurable: true },inClassStaticBlock: { configurable: true } };\n\nParser.prototype.parse = function parse () {\n var node = this.options.program || this.startNode();\n this.nextToken();\n return this.parseTopLevel(node)\n};\n\nprototypeAccessors.inFunction.get = function () { return (this.currentVarScope().flags & SCOPE_FUNCTION) > 0 };\n\nprototypeAccessors.inGenerator.get = function () { return (this.currentVarScope().flags & SCOPE_GENERATOR) > 0 && !this.currentVarScope().inClassFieldInit };\n\nprototypeAccessors.inAsync.get = function () { return (this.currentVarScope().flags & SCOPE_ASYNC) > 0 && !this.currentVarScope().inClassFieldInit };\n\nprototypeAccessors.canAwait.get = function () {\n for (var i = this.scopeStack.length - 1; i >= 0; i--) {\n var scope = this.scopeStack[i];\n if (scope.inClassFieldInit || scope.flags & SCOPE_CLASS_STATIC_BLOCK) { return false }\n if (scope.flags & SCOPE_FUNCTION) { return (scope.flags & SCOPE_ASYNC) > 0 }\n }\n return (this.inModule && this.options.ecmaVersion >= 13) || this.options.allowAwaitOutsideFunction\n};\n\nprototypeAccessors.allowSuper.get = function () {\n var ref = this.currentThisScope();\n var flags = ref.flags;\n var inClassFieldInit = ref.inClassFieldInit;\n return (flags & SCOPE_SUPER) > 0 || inClassFieldInit || this.options.allowSuperOutsideMethod\n};\n\nprototypeAccessors.allowDirectSuper.get = function () { return (this.currentThisScope().flags & SCOPE_DIRECT_SUPER) > 0 };\n\nprototypeAccessors.treatFunctionsAsVar.get = function () { return this.treatFunctionsAsVarInScope(this.currentScope()) };\n\nprototypeAccessors.allowNewDotTarget.get = function () {\n var ref = this.currentThisScope();\n var flags = ref.flags;\n var inClassFieldInit = ref.inClassFieldInit;\n return (flags & (SCOPE_FUNCTION | SCOPE_CLASS_STATIC_BLOCK)) > 0 || inClassFieldInit\n};\n\nprototypeAccessors.inClassStaticBlock.get = function () {\n return (this.currentVarScope().flags & SCOPE_CLASS_STATIC_BLOCK) > 0\n};\n\nParser.extend = function extend () {\n var plugins = [], len = arguments.length;\n while ( len-- ) plugins[ len ] = arguments[ len ];\n\n var cls = this;\n for (var i = 0; i < plugins.length; i++) { cls = plugins[i](cls); }\n return cls\n};\n\nParser.parse = function parse (input, options) {\n return new this(options, input).parse()\n};\n\nParser.parseExpressionAt = function parseExpressionAt (input, pos, options) {\n var parser = new this(options, input, pos);\n parser.nextToken();\n return parser.parseExpression()\n};\n\nParser.tokenizer = function tokenizer (input, options) {\n return new this(options, input)\n};\n\nObject.defineProperties( Parser.prototype, prototypeAccessors );\n\nvar pp$9 = Parser.prototype;\n\n// ## Parser utilities\n\nvar literal = /^(?:'((?:\\\\.|[^'\\\\])*?)'|\"((?:\\\\.|[^\"\\\\])*?)\")/;\npp$9.strictDirective = function(start) {\n if (this.options.ecmaVersion < 5) { return false }\n for (;;) {\n // Try to find string literal.\n skipWhiteSpace.lastIndex = start;\n start += skipWhiteSpace.exec(this.input)[0].length;\n var match = literal.exec(this.input.slice(start));\n if (!match) { return false }\n if ((match[1] || match[2]) === \"use strict\") {\n skipWhiteSpace.lastIndex = start + match[0].length;\n var spaceAfter = skipWhiteSpace.exec(this.input), end = spaceAfter.index + spaceAfter[0].length;\n var next = this.input.charAt(end);\n return next === \";\" || next === \"}\" ||\n (lineBreak.test(spaceAfter[0]) &&\n !(/[(`.[+\\-/*%<>=,?^&]/.test(next) || next === \"!\" && this.input.charAt(end + 1) === \"=\"))\n }\n start += match[0].length;\n\n // Skip semicolon, if any.\n skipWhiteSpace.lastIndex = start;\n start += skipWhiteSpace.exec(this.input)[0].length;\n if (this.input[start] === \";\")\n { start++; }\n }\n};\n\n// Predicate that tests whether the next token is of the given\n// type, and if yes, consumes it as a side effect.\n\npp$9.eat = function(type) {\n if (this.type === type) {\n this.next();\n return true\n } else {\n return false\n }\n};\n\n// Tests whether parsed token is a contextual keyword.\n\npp$9.isContextual = function(name) {\n return this.type === types$1.name && this.value === name && !this.containsEsc\n};\n\n// Consumes contextual keyword if possible.\n\npp$9.eatContextual = function(name) {\n if (!this.isContextual(name)) { return false }\n this.next();\n return true\n};\n\n// Asserts that following token is given contextual keyword.\n\npp$9.expectContextual = function(name) {\n if (!this.eatContextual(name)) { this.unexpected(); }\n};\n\n// Test whether a semicolon can be inserted at the current position.\n\npp$9.canInsertSemicolon = function() {\n return this.type === types$1.eof ||\n this.type === types$1.braceR ||\n lineBreak.test(this.input.slice(this.lastTokEnd, this.start))\n};\n\npp$9.insertSemicolon = function() {\n if (this.canInsertSemicolon()) {\n if (this.options.onInsertedSemicolon)\n { this.options.onInsertedSemicolon(this.lastTokEnd, this.lastTokEndLoc); }\n return true\n }\n};\n\n// Consume a semicolon, or, failing that, see if we are allowed to\n// pretend that there is a semicolon at this position.\n\npp$9.semicolon = function() {\n if (!this.eat(types$1.semi) && !this.insertSemicolon()) { this.unexpected(); }\n};\n\npp$9.afterTrailingComma = function(tokType, notNext) {\n if (this.type === tokType) {\n if (this.options.onTrailingComma)\n { this.options.onTrailingComma(this.lastTokStart, this.lastTokStartLoc); }\n if (!notNext)\n { this.next(); }\n return true\n }\n};\n\n// Expect a token of a given type. If found, consume it, otherwise,\n// raise an unexpected token error.\n\npp$9.expect = function(type) {\n this.eat(type) || this.unexpected();\n};\n\n// Raise an unexpected token error.\n\npp$9.unexpected = function(pos) {\n this.raise(pos != null ? pos : this.start, \"Unexpected token\");\n};\n\nvar DestructuringErrors = function DestructuringErrors() {\n this.shorthandAssign =\n this.trailingComma =\n this.parenthesizedAssign =\n this.parenthesizedBind =\n this.doubleProto =\n -1;\n};\n\npp$9.checkPatternErrors = function(refDestructuringErrors, isAssign) {\n if (!refDestructuringErrors) { return }\n if (refDestructuringErrors.trailingComma > -1)\n { this.raiseRecoverable(refDestructuringErrors.trailingComma, \"Comma is not permitted after the rest element\"); }\n var parens = isAssign ? refDestructuringErrors.parenthesizedAssign : refDestructuringErrors.parenthesizedBind;\n if (parens > -1) { this.raiseRecoverable(parens, isAssign ? \"Assigning to rvalue\" : \"Parenthesized pattern\"); }\n};\n\npp$9.checkExpressionErrors = function(refDestructuringErrors, andThrow) {\n if (!refDestructuringErrors) { return false }\n var shorthandAssign = refDestructuringErrors.shorthandAssign;\n var doubleProto = refDestructuringErrors.doubleProto;\n if (!andThrow) { return shorthandAssign >= 0 || doubleProto >= 0 }\n if (shorthandAssign >= 0)\n { this.raise(shorthandAssign, \"Shorthand property assignments are valid only in destructuring patterns\"); }\n if (doubleProto >= 0)\n { this.raiseRecoverable(doubleProto, \"Redefinition of __proto__ property\"); }\n};\n\npp$9.checkYieldAwaitInDefaultParams = function() {\n if (this.yieldPos && (!this.awaitPos || this.yieldPos < this.awaitPos))\n { this.raise(this.yieldPos, \"Yield expression cannot be a default value\"); }\n if (this.awaitPos)\n { this.raise(this.awaitPos, \"Await expression cannot be a default value\"); }\n};\n\npp$9.isSimpleAssignTarget = function(expr) {\n if (expr.type === \"ParenthesizedExpression\")\n { return this.isSimpleAssignTarget(expr.expression) }\n return expr.type === \"Identifier\" || expr.type === \"MemberExpression\"\n};\n\nvar pp$8 = Parser.prototype;\n\n// ### Statement parsing\n\n// Parse a program. Initializes the parser, reads any number of\n// statements, and wraps them in a Program node. Optionally takes a\n// `program` argument. If present, the statements will be appended\n// to its body instead of creating a new node.\n\npp$8.parseTopLevel = function(node) {\n var exports = Object.create(null);\n if (!node.body) { node.body = []; }\n while (this.type !== types$1.eof) {\n var stmt = this.parseStatement(null, true, exports);\n node.body.push(stmt);\n }\n if (this.inModule)\n { for (var i = 0, list = Object.keys(this.undefinedExports); i < list.length; i += 1)\n {\n var name = list[i];\n\n this.raiseRecoverable(this.undefinedExports[name].start, (\"Export '\" + name + \"' is not defined\"));\n } }\n this.adaptDirectivePrologue(node.body);\n this.next();\n node.sourceType = this.options.sourceType;\n return this.finishNode(node, \"Program\")\n};\n\nvar loopLabel = {kind: \"loop\"}, switchLabel = {kind: \"switch\"};\n\npp$8.isLet = function(context) {\n if (this.options.ecmaVersion < 6 || !this.isContextual(\"let\")) { return false }\n skipWhiteSpace.lastIndex = this.pos;\n var skip = skipWhiteSpace.exec(this.input);\n var next = this.pos + skip[0].length, nextCh = this.input.charCodeAt(next);\n // For ambiguous cases, determine if a LexicalDeclaration (or only a\n // Statement) is allowed here. If context is not empty then only a Statement\n // is allowed. However, `let [` is an explicit negative lookahead for\n // ExpressionStatement, so special-case it first.\n if (nextCh === 91 || nextCh === 92 || nextCh > 0xd7ff && nextCh < 0xdc00) { return true } // '[', '/', astral\n if (context) { return false }\n\n if (nextCh === 123) { return true } // '{'\n if (isIdentifierStart(nextCh, true)) {\n var pos = next + 1;\n while (isIdentifierChar(nextCh = this.input.charCodeAt(pos), true)) { ++pos; }\n if (nextCh === 92 || nextCh > 0xd7ff && nextCh < 0xdc00) { return true }\n var ident = this.input.slice(next, pos);\n if (!keywordRelationalOperator.test(ident)) { return true }\n }\n return false\n};\n\n// check 'async [no LineTerminator here] function'\n// - 'async /*foo*/ function' is OK.\n// - 'async /*\\n*/ function' is invalid.\npp$8.isAsyncFunction = function() {\n if (this.options.ecmaVersion < 8 || !this.isContextual(\"async\"))\n { return false }\n\n skipWhiteSpace.lastIndex = this.pos;\n var skip = skipWhiteSpace.exec(this.input);\n var next = this.pos + skip[0].length, after;\n return !lineBreak.test(this.input.slice(this.pos, next)) &&\n this.input.slice(next, next + 8) === \"function\" &&\n (next + 8 === this.input.length ||\n !(isIdentifierChar(after = this.input.charCodeAt(next + 8)) || after > 0xd7ff && after < 0xdc00))\n};\n\n// Parse a single statement.\n//\n// If expecting a statement and finding a slash operator, parse a\n// regular expression literal. This is to handle cases like\n// `if (foo) /blah/.exec(foo)`, where looking at the previous token\n// does not help.\n\npp$8.parseStatement = function(context, topLevel, exports) {\n var starttype = this.type, node = this.startNode(), kind;\n\n if (this.isLet(context)) {\n starttype = types$1._var;\n kind = \"let\";\n }\n\n // Most types of statements are recognized by the keyword they\n // start with. Many are trivial to parse, some require a bit of\n // complexity.\n\n switch (starttype) {\n case types$1._break: case types$1._continue: return this.parseBreakContinueStatement(node, starttype.keyword)\n case types$1._debugger: return this.parseDebuggerStatement(node)\n case types$1._do: return this.parseDoStatement(node)\n case types$1._for: return this.parseForStatement(node)\n case types$1._function:\n // Function as sole body of either an if statement or a labeled statement\n // works, but not when it is part of a labeled statement that is the sole\n // body of an if statement.\n if ((context && (this.strict || context !== \"if\" && context !== \"label\")) && this.options.ecmaVersion >= 6) { this.unexpected(); }\n return this.parseFunctionStatement(node, false, !context)\n case types$1._class:\n if (context) { this.unexpected(); }\n return this.parseClass(node, true)\n case types$1._if: return this.parseIfStatement(node)\n case types$1._return: return this.parseReturnStatement(node)\n case types$1._switch: return this.parseSwitchStatement(node)\n case types$1._throw: return this.parseThrowStatement(node)\n case types$1._try: return this.parseTryStatement(node)\n case types$1._const: case types$1._var:\n kind = kind || this.value;\n if (context && kind !== \"var\") { this.unexpected(); }\n return this.parseVarStatement(node, kind)\n case types$1._while: return this.parseWhileStatement(node)\n case types$1._with: return this.parseWithStatement(node)\n case types$1.braceL: return this.parseBlock(true, node)\n case types$1.semi: return this.parseEmptyStatement(node)\n case types$1._export:\n case types$1._import:\n if (this.options.ecmaVersion > 10 && starttype === types$1._import) {\n skipWhiteSpace.lastIndex = this.pos;\n var skip = skipWhiteSpace.exec(this.input);\n var next = this.pos + skip[0].length, nextCh = this.input.charCodeAt(next);\n if (nextCh === 40 || nextCh === 46) // '(' or '.'\n { return this.parseExpressionStatement(node, this.parseExpression()) }\n }\n\n if (!this.options.allowImportExportEverywhere) {\n if (!topLevel)\n { this.raise(this.start, \"'import' and 'export' may only appear at the top level\"); }\n if (!this.inModule)\n { this.raise(this.start, \"'import' and 'export' may appear only with 'sourceType: module'\"); }\n }\n return starttype === types$1._import ? this.parseImport(node) : this.parseExport(node, exports)\n\n // If the statement does not start with a statement keyword or a\n // brace, it's an ExpressionStatement or LabeledStatement. We\n // simply start parsing an expression, and afterwards, if the\n // next token is a colon and the expression was a simple\n // Identifier node, we switch to interpreting it as a label.\n default:\n if (this.isAsyncFunction()) {\n if (context) { this.unexpected(); }\n this.next();\n return this.parseFunctionStatement(node, true, !context)\n }\n\n var maybeName = this.value, expr = this.parseExpression();\n if (starttype === types$1.name && expr.type === \"Identifier\" && this.eat(types$1.colon))\n { return this.parseLabeledStatement(node, maybeName, expr, context) }\n else { return this.parseExpressionStatement(node, expr) }\n }\n};\n\npp$8.parseBreakContinueStatement = function(node, keyword) {\n var isBreak = keyword === \"break\";\n this.next();\n if (this.eat(types$1.semi) || this.insertSemicolon()) { node.label = null; }\n else if (this.type !== types$1.name) { this.unexpected(); }\n else {\n node.label = this.parseIdent();\n this.semicolon();\n }\n\n // Verify that there is an actual destination to break or\n // continue to.\n var i = 0;\n for (; i < this.labels.length; ++i) {\n var lab = this.labels[i];\n if (node.label == null || lab.name === node.label.name) {\n if (lab.kind != null && (isBreak || lab.kind === \"loop\")) { break }\n if (node.label && isBreak) { break }\n }\n }\n if (i === this.labels.length) { this.raise(node.start, \"Unsyntactic \" + keyword); }\n return this.finishNode(node, isBreak ? \"BreakStatement\" : \"ContinueStatement\")\n};\n\npp$8.parseDebuggerStatement = function(node) {\n this.next();\n this.semicolon();\n return this.finishNode(node, \"DebuggerStatement\")\n};\n\npp$8.parseDoStatement = function(node) {\n this.next();\n this.labels.push(loopLabel);\n node.body = this.parseStatement(\"do\");\n this.labels.pop();\n this.expect(types$1._while);\n node.test = this.parseParenExpression();\n if (this.options.ecmaVersion >= 6)\n { this.eat(types$1.semi); }\n else\n { this.semicolon(); }\n return this.finishNode(node, \"DoWhileStatement\")\n};\n\n// Disambiguating between a `for` and a `for`/`in` or `for`/`of`\n// loop is non-trivial. Basically, we have to parse the init `var`\n// statement or expression, disallowing the `in` operator (see\n// the second parameter to `parseExpression`), and then check\n// whether the next token is `in` or `of`. When there is no init\n// part (semicolon immediately after the opening parenthesis), it\n// is a regular `for` loop.\n\npp$8.parseForStatement = function(node) {\n this.next();\n var awaitAt = (this.options.ecmaVersion >= 9 && this.canAwait && this.eatContextual(\"await\")) ? this.lastTokStart : -1;\n this.labels.push(loopLabel);\n this.enterScope(0);\n this.expect(types$1.parenL);\n if (this.type === types$1.semi) {\n if (awaitAt > -1) { this.unexpected(awaitAt); }\n return this.parseFor(node, null)\n }\n var isLet = this.isLet();\n if (this.type === types$1._var || this.type === types$1._const || isLet) {\n var init$1 = this.startNode(), kind = isLet ? \"let\" : this.value;\n this.next();\n this.parseVar(init$1, true, kind);\n this.finishNode(init$1, \"VariableDeclaration\");\n if ((this.type === types$1._in || (this.options.ecmaVersion >= 6 && this.isContextual(\"of\"))) && init$1.declarations.length === 1) {\n if (this.options.ecmaVersion >= 9) {\n if (this.type === types$1._in) {\n if (awaitAt > -1) { this.unexpected(awaitAt); }\n } else { node.await = awaitAt > -1; }\n }\n return this.parseForIn(node, init$1)\n }\n if (awaitAt > -1) { this.unexpected(awaitAt); }\n return this.parseFor(node, init$1)\n }\n var startsWithLet = this.isContextual(\"let\"), isForOf = false;\n var refDestructuringErrors = new DestructuringErrors;\n var init = this.parseExpression(awaitAt > -1 ? \"await\" : true, refDestructuringErrors);\n if (this.type === types$1._in || (isForOf = this.options.ecmaVersion >= 6 && this.isContextual(\"of\"))) {\n if (this.options.ecmaVersion >= 9) {\n if (this.type === types$1._in) {\n if (awaitAt > -1) { this.unexpected(awaitAt); }\n } else { node.await = awaitAt > -1; }\n }\n if (startsWithLet && isForOf) { this.raise(init.start, \"The left-hand side of a for-of loop may not start with 'let'.\"); }\n this.toAssignable(init, false, refDestructuringErrors);\n this.checkLValPattern(init);\n return this.parseForIn(node, init)\n } else {\n this.checkExpressionErrors(refDestructuringErrors, true);\n }\n if (awaitAt > -1) { this.unexpected(awaitAt); }\n return this.parseFor(node, init)\n};\n\npp$8.parseFunctionStatement = function(node, isAsync, declarationPosition) {\n this.next();\n return this.parseFunction(node, FUNC_STATEMENT | (declarationPosition ? 0 : FUNC_HANGING_STATEMENT), false, isAsync)\n};\n\npp$8.parseIfStatement = function(node) {\n this.next();\n node.test = this.parseParenExpression();\n // allow function declarations in branches, but only in non-strict mode\n node.consequent = this.parseStatement(\"if\");\n node.alternate = this.eat(types$1._else) ? this.parseStatement(\"if\") : null;\n return this.finishNode(node, \"IfStatement\")\n};\n\npp$8.parseReturnStatement = function(node) {\n if (!this.inFunction && !this.options.allowReturnOutsideFunction)\n { this.raise(this.start, \"'return' outside of function\"); }\n this.next();\n\n // In `return` (and `break`/`continue`), the keywords with\n // optional arguments, we eagerly look for a semicolon or the\n // possibility to insert one.\n\n if (this.eat(types$1.semi) || this.insertSemicolon()) { node.argument = null; }\n else { node.argument = this.parseExpression(); this.semicolon(); }\n return this.finishNode(node, \"ReturnStatement\")\n};\n\npp$8.parseSwitchStatement = function(node) {\n this.next();\n node.discriminant = this.parseParenExpression();\n node.cases = [];\n this.expect(types$1.braceL);\n this.labels.push(switchLabel);\n this.enterScope(0);\n\n // Statements under must be grouped (by label) in SwitchCase\n // nodes. `cur` is used to keep the node that we are currently\n // adding statements to.\n\n var cur;\n for (var sawDefault = false; this.type !== types$1.braceR;) {\n if (this.type === types$1._case || this.type === types$1._default) {\n var isCase = this.type === types$1._case;\n if (cur) { this.finishNode(cur, \"SwitchCase\"); }\n node.cases.push(cur = this.startNode());\n cur.consequent = [];\n this.next();\n if (isCase) {\n cur.test = this.parseExpression();\n } else {\n if (sawDefault) { this.raiseRecoverable(this.lastTokStart, \"Multiple default clauses\"); }\n sawDefault = true;\n cur.test = null;\n }\n this.expect(types$1.colon);\n } else {\n if (!cur) { this.unexpected(); }\n cur.consequent.push(this.parseStatement(null));\n }\n }\n this.exitScope();\n if (cur) { this.finishNode(cur, \"SwitchCase\"); }\n this.next(); // Closing brace\n this.labels.pop();\n return this.finishNode(node, \"SwitchStatement\")\n};\n\npp$8.parseThrowStatement = function(node) {\n this.next();\n if (lineBreak.test(this.input.slice(this.lastTokEnd, this.start)))\n { this.raise(this.lastTokEnd, \"Illegal newline after throw\"); }\n node.argument = this.parseExpression();\n this.semicolon();\n return this.finishNode(node, \"ThrowStatement\")\n};\n\n// Reused empty array added for node fields that are always empty.\n\nvar empty$1 = [];\n\npp$8.parseTryStatement = function(node) {\n this.next();\n node.block = this.parseBlock();\n node.handler = null;\n if (this.type === types$1._catch) {\n var clause = this.startNode();\n this.next();\n if (this.eat(types$1.parenL)) {\n clause.param = this.parseBindingAtom();\n var simple = clause.param.type === \"Identifier\";\n this.enterScope(simple ? SCOPE_SIMPLE_CATCH : 0);\n this.checkLValPattern(clause.param, simple ? BIND_SIMPLE_CATCH : BIND_LEXICAL);\n this.expect(types$1.parenR);\n } else {\n if (this.options.ecmaVersion < 10) { this.unexpected(); }\n clause.param = null;\n this.enterScope(0);\n }\n clause.body = this.parseBlock(false);\n this.exitScope();\n node.handler = this.finishNode(clause, \"CatchClause\");\n }\n node.finalizer = this.eat(types$1._finally) ? this.parseBlock() : null;\n if (!node.handler && !node.finalizer)\n { this.raise(node.start, \"Missing catch or finally clause\"); }\n return this.finishNode(node, \"TryStatement\")\n};\n\npp$8.parseVarStatement = function(node, kind) {\n this.next();\n this.parseVar(node, false, kind);\n this.semicolon();\n return this.finishNode(node, \"VariableDeclaration\")\n};\n\npp$8.parseWhileStatement = function(node) {\n this.next();\n node.test = this.parseParenExpression();\n this.labels.push(loopLabel);\n node.body = this.parseStatement(\"while\");\n this.labels.pop();\n return this.finishNode(node, \"WhileStatement\")\n};\n\npp$8.parseWithStatement = function(node) {\n if (this.strict) { this.raise(this.start, \"'with' in strict mode\"); }\n this.next();\n node.object = this.parseParenExpression();\n node.body = this.parseStatement(\"with\");\n return this.finishNode(node, \"WithStatement\")\n};\n\npp$8.parseEmptyStatement = function(node) {\n this.next();\n return this.finishNode(node, \"EmptyStatement\")\n};\n\npp$8.parseLabeledStatement = function(node, maybeName, expr, context) {\n for (var i$1 = 0, list = this.labels; i$1 < list.length; i$1 += 1)\n {\n var label = list[i$1];\n\n if (label.name === maybeName)\n { this.raise(expr.start, \"Label '\" + maybeName + \"' is already declared\");\n } }\n var kind = this.type.isLoop ? \"loop\" : this.type === types$1._switch ? \"switch\" : null;\n for (var i = this.labels.length - 1; i >= 0; i--) {\n var label$1 = this.labels[i];\n if (label$1.statementStart === node.start) {\n // Update information about previous labels on this node\n label$1.statementStart = this.start;\n label$1.kind = kind;\n } else { break }\n }\n this.labels.push({name: maybeName, kind: kind, statementStart: this.start});\n node.body = this.parseStatement(context ? context.indexOf(\"label\") === -1 ? context + \"label\" : context : \"label\");\n this.labels.pop();\n node.label = expr;\n return this.finishNode(node, \"LabeledStatement\")\n};\n\npp$8.parseExpressionStatement = function(node, expr) {\n node.expression = expr;\n this.semicolon();\n return this.finishNode(node, \"ExpressionStatement\")\n};\n\n// Parse a semicolon-enclosed block of statements, handling `\"use\n// strict\"` declarations when `allowStrict` is true (used for\n// function bodies).\n\npp$8.parseBlock = function(createNewLexicalScope, node, exitStrict) {\n if ( createNewLexicalScope === void 0 ) createNewLexicalScope = true;\n if ( node === void 0 ) node = this.startNode();\n\n node.body = [];\n this.expect(types$1.braceL);\n if (createNewLexicalScope) { this.enterScope(0); }\n while (this.type !== types$1.braceR) {\n var stmt = this.parseStatement(null);\n node.body.push(stmt);\n }\n if (exitStrict) { this.strict = false; }\n this.next();\n if (createNewLexicalScope) { this.exitScope(); }\n return this.finishNode(node, \"BlockStatement\")\n};\n\n// Parse a regular `for` loop. The disambiguation code in\n// `parseStatement` will already have parsed the init statement or\n// expression.\n\npp$8.parseFor = function(node, init) {\n node.init = init;\n this.expect(types$1.semi);\n node.test = this.type === types$1.semi ? null : this.parseExpression();\n this.expect(types$1.semi);\n node.update = this.type === types$1.parenR ? null : this.parseExpression();\n this.expect(types$1.parenR);\n node.body = this.parseStatement(\"for\");\n this.exitScope();\n this.labels.pop();\n return this.finishNode(node, \"ForStatement\")\n};\n\n// Parse a `for`/`in` and `for`/`of` loop, which are almost\n// same from parser's perspective.\n\npp$8.parseForIn = function(node, init) {\n var isForIn = this.type === types$1._in;\n this.next();\n\n if (\n init.type === \"VariableDeclaration\" &&\n init.declarations[0].init != null &&\n (\n !isForIn ||\n this.options.ecmaVersion < 8 ||\n this.strict ||\n init.kind !== \"var\" ||\n init.declarations[0].id.type !== \"Identifier\"\n )\n ) {\n this.raise(\n init.start,\n ((isForIn ? \"for-in\" : \"for-of\") + \" loop variable declaration may not have an initializer\")\n );\n }\n node.left = init;\n node.right = isForIn ? this.parseExpression() : this.parseMaybeAssign();\n this.expect(types$1.parenR);\n node.body = this.parseStatement(\"for\");\n this.exitScope();\n this.labels.pop();\n return this.finishNode(node, isForIn ? \"ForInStatement\" : \"ForOfStatement\")\n};\n\n// Parse a list of variable declarations.\n\npp$8.parseVar = function(node, isFor, kind) {\n node.declarations = [];\n node.kind = kind;\n for (;;) {\n var decl = this.startNode();\n this.parseVarId(decl, kind);\n if (this.eat(types$1.eq)) {\n decl.init = this.parseMaybeAssign(isFor);\n } else if (kind === \"const\" && !(this.type === types$1._in || (this.options.ecmaVersion >= 6 && this.isContextual(\"of\")))) {\n this.unexpected();\n } else if (decl.id.type !== \"Identifier\" && !(isFor && (this.type === types$1._in || this.isContextual(\"of\")))) {\n this.raise(this.lastTokEnd, \"Complex binding patterns require an initialization value\");\n } else {\n decl.init = null;\n }\n node.declarations.push(this.finishNode(decl, \"VariableDeclarator\"));\n if (!this.eat(types$1.comma)) { break }\n }\n return node\n};\n\npp$8.parseVarId = function(decl, kind) {\n decl.id = this.parseBindingAtom();\n this.checkLValPattern(decl.id, kind === \"var\" ? BIND_VAR : BIND_LEXICAL, false);\n};\n\nvar FUNC_STATEMENT = 1, FUNC_HANGING_STATEMENT = 2, FUNC_NULLABLE_ID = 4;\n\n// Parse a function declaration or literal (depending on the\n// `statement & FUNC_STATEMENT`).\n\n// Remove `allowExpressionBody` for 7.0.0, as it is only called with false\npp$8.parseFunction = function(node, statement, allowExpressionBody, isAsync, forInit) {\n this.initFunction(node);\n if (this.options.ecmaVersion >= 9 || this.options.ecmaVersion >= 6 && !isAsync) {\n if (this.type === types$1.star && (statement & FUNC_HANGING_STATEMENT))\n { this.unexpected(); }\n node.generator = this.eat(types$1.star);\n }\n if (this.options.ecmaVersion >= 8)\n { node.async = !!isAsync; }\n\n if (statement & FUNC_STATEMENT) {\n node.id = (statement & FUNC_NULLABLE_ID) && this.type !== types$1.name ? null : this.parseIdent();\n if (node.id && !(statement & FUNC_HANGING_STATEMENT))\n // If it is a regular function declaration in sloppy mode, then it is\n // subject to Annex B semantics (BIND_FUNCTION). Otherwise, the binding\n // mode depends on properties of the current scope (see\n // treatFunctionsAsVar).\n { this.checkLValSimple(node.id, (this.strict || node.generator || node.async) ? this.treatFunctionsAsVar ? BIND_VAR : BIND_LEXICAL : BIND_FUNCTION); }\n }\n\n var oldYieldPos = this.yieldPos, oldAwaitPos = this.awaitPos, oldAwaitIdentPos = this.awaitIdentPos;\n this.yieldPos = 0;\n this.awaitPos = 0;\n this.awaitIdentPos = 0;\n this.enterScope(functionFlags(node.async, node.generator));\n\n if (!(statement & FUNC_STATEMENT))\n { node.id = this.type === types$1.name ? this.parseIdent() : null; }\n\n this.parseFunctionParams(node);\n this.parseFunctionBody(node, allowExpressionBody, false, forInit);\n\n this.yieldPos = oldYieldPos;\n this.awaitPos = oldAwaitPos;\n this.awaitIdentPos = oldAwaitIdentPos;\n return this.finishNode(node, (statement & FUNC_STATEMENT) ? \"FunctionDeclaration\" : \"FunctionExpression\")\n};\n\npp$8.parseFunctionParams = function(node) {\n this.expect(types$1.parenL);\n node.params = this.parseBindingList(types$1.parenR, false, this.options.ecmaVersion >= 8);\n this.checkYieldAwaitInDefaultParams();\n};\n\n// Parse a class declaration or literal (depending on the\n// `isStatement` parameter).\n\npp$8.parseClass = function(node, isStatement) {\n this.next();\n\n // ecma-262 14.6 Class Definitions\n // A class definition is always strict mode code.\n var oldStrict = this.strict;\n this.strict = true;\n\n this.parseClassId(node, isStatement);\n this.parseClassSuper(node);\n var privateNameMap = this.enterClassBody();\n var classBody = this.startNode();\n var hadConstructor = false;\n classBody.body = [];\n this.expect(types$1.braceL);\n while (this.type !== types$1.braceR) {\n var element = this.parseClassElement(node.superClass !== null);\n if (element) {\n classBody.body.push(element);\n if (element.type === \"MethodDefinition\" && element.kind === \"constructor\") {\n if (hadConstructor) { this.raise(element.start, \"Duplicate constructor in the same class\"); }\n hadConstructor = true;\n } else if (element.key && element.key.type === \"PrivateIdentifier\" && isPrivateNameConflicted(privateNameMap, element)) {\n this.raiseRecoverable(element.key.start, (\"Identifier '#\" + (element.key.name) + \"' has already been declared\"));\n }\n }\n }\n this.strict = oldStrict;\n this.next();\n node.body = this.finishNode(classBody, \"ClassBody\");\n this.exitClassBody();\n return this.finishNode(node, isStatement ? \"ClassDeclaration\" : \"ClassExpression\")\n};\n\npp$8.parseClassElement = function(constructorAllowsSuper) {\n if (this.eat(types$1.semi)) { return null }\n\n var ecmaVersion = this.options.ecmaVersion;\n var node = this.startNode();\n var keyName = \"\";\n var isGenerator = false;\n var isAsync = false;\n var kind = \"method\";\n var isStatic = false;\n\n if (this.eatContextual(\"static\")) {\n // Parse static init block\n if (ecmaVersion >= 13 && this.eat(types$1.braceL)) {\n this.parseClassStaticBlock(node);\n return node\n }\n if (this.isClassElementNameStart() || this.type === types$1.star) {\n isStatic = true;\n } else {\n keyName = \"static\";\n }\n }\n node.static = isStatic;\n if (!keyName && ecmaVersion >= 8 && this.eatContextual(\"async\")) {\n if ((this.isClassElementNameStart() || this.type === types$1.star) && !this.canInsertSemicolon()) {\n isAsync = true;\n } else {\n keyName = \"async\";\n }\n }\n if (!keyName && (ecmaVersion >= 9 || !isAsync) && this.eat(types$1.star)) {\n isGenerator = true;\n }\n if (!keyName && !isAsync && !isGenerator) {\n var lastValue = this.value;\n if (this.eatContextual(\"get\") || this.eatContextual(\"set\")) {\n if (this.isClassElementNameStart()) {\n kind = lastValue;\n } else {\n keyName = lastValue;\n }\n }\n }\n\n // Parse element name\n if (keyName) {\n // 'async', 'get', 'set', or 'static' were not a keyword contextually.\n // The last token is any of those. Make it the element name.\n node.computed = false;\n node.key = this.startNodeAt(this.lastTokStart, this.lastTokStartLoc);\n node.key.name = keyName;\n this.finishNode(node.key, \"Identifier\");\n } else {\n this.parseClassElementName(node);\n }\n\n // Parse element value\n if (ecmaVersion < 13 || this.type === types$1.parenL || kind !== \"method\" || isGenerator || isAsync) {\n var isConstructor = !node.static && checkKeyName(node, \"constructor\");\n var allowsDirectSuper = isConstructor && constructorAllowsSuper;\n // Couldn't move this check into the 'parseClassMethod' method for backward compatibility.\n if (isConstructor && kind !== \"method\") { this.raise(node.key.start, \"Constructor can't have get/set modifier\"); }\n node.kind = isConstructor ? \"constructor\" : kind;\n this.parseClassMethod(node, isGenerator, isAsync, allowsDirectSuper);\n } else {\n this.parseClassField(node);\n }\n\n return node\n};\n\npp$8.isClassElementNameStart = function() {\n return (\n this.type === types$1.name ||\n this.type === types$1.privateId ||\n this.type === types$1.num ||\n this.type === types$1.string ||\n this.type === types$1.bracketL ||\n this.type.keyword\n )\n};\n\npp$8.parseClassElementName = function(element) {\n if (this.type === types$1.privateId) {\n if (this.value === \"constructor\") {\n this.raise(this.start, \"Classes can't have an element named '#constructor'\");\n }\n element.computed = false;\n element.key = this.parsePrivateIdent();\n } else {\n this.parsePropertyName(element);\n }\n};\n\npp$8.parseClassMethod = function(method, isGenerator, isAsync, allowsDirectSuper) {\n // Check key and flags\n var key = method.key;\n if (method.kind === \"constructor\") {\n if (isGenerator) { this.raise(key.start, \"Constructor can't be a generator\"); }\n if (isAsync) { this.raise(key.start, \"Constructor can't be an async method\"); }\n } else if (method.static && checkKeyName(method, \"prototype\")) {\n this.raise(key.start, \"Classes may not have a static property named prototype\");\n }\n\n // Parse value\n var value = method.value = this.parseMethod(isGenerator, isAsync, allowsDirectSuper);\n\n // Check value\n if (method.kind === \"get\" && value.params.length !== 0)\n { this.raiseRecoverable(value.start, \"getter should have no params\"); }\n if (method.kind === \"set\" && value.params.length !== 1)\n { this.raiseRecoverable(value.start, \"setter should have exactly one param\"); }\n if (method.kind === \"set\" && value.params[0].type === \"RestElement\")\n { this.raiseRecoverable(value.params[0].start, \"Setter cannot use rest params\"); }\n\n return this.finishNode(method, \"MethodDefinition\")\n};\n\npp$8.parseClassField = function(field) {\n if (checkKeyName(field, \"constructor\")) {\n this.raise(field.key.start, \"Classes can't have a field named 'constructor'\");\n } else if (field.static && checkKeyName(field, \"prototype\")) {\n this.raise(field.key.start, \"Classes can't have a static field named 'prototype'\");\n }\n\n if (this.eat(types$1.eq)) {\n // To raise SyntaxError if 'arguments' exists in the initializer.\n var scope = this.currentThisScope();\n var inClassFieldInit = scope.inClassFieldInit;\n scope.inClassFieldInit = true;\n field.value = this.parseMaybeAssign();\n scope.inClassFieldInit = inClassFieldInit;\n } else {\n field.value = null;\n }\n this.semicolon();\n\n return this.finishNode(field, \"PropertyDefinition\")\n};\n\npp$8.parseClassStaticBlock = function(node) {\n node.body = [];\n\n var oldLabels = this.labels;\n this.labels = [];\n this.enterScope(SCOPE_CLASS_STATIC_BLOCK | SCOPE_SUPER);\n while (this.type !== types$1.braceR) {\n var stmt = this.parseStatement(null);\n node.body.push(stmt);\n }\n this.next();\n this.exitScope();\n this.labels = oldLabels;\n\n return this.finishNode(node, \"StaticBlock\")\n};\n\npp$8.parseClassId = function(node, isStatement) {\n if (this.type === types$1.name) {\n node.id = this.parseIdent();\n if (isStatement)\n { this.checkLValSimple(node.id, BIND_LEXICAL, false); }\n } else {\n if (isStatement === true)\n { this.unexpected(); }\n node.id = null;\n }\n};\n\npp$8.parseClassSuper = function(node) {\n node.superClass = this.eat(types$1._extends) ? this.parseExprSubscripts(false) : null;\n};\n\npp$8.enterClassBody = function() {\n var element = {declared: Object.create(null), used: []};\n this.privateNameStack.push(element);\n return element.declared\n};\n\npp$8.exitClassBody = function() {\n var ref = this.privateNameStack.pop();\n var declared = ref.declared;\n var used = ref.used;\n var len = this.privateNameStack.length;\n var parent = len === 0 ? null : this.privateNameStack[len - 1];\n for (var i = 0; i < used.length; ++i) {\n var id = used[i];\n if (!hasOwn(declared, id.name)) {\n if (parent) {\n parent.used.push(id);\n } else {\n this.raiseRecoverable(id.start, (\"Private field '#\" + (id.name) + \"' must be declared in an enclosing class\"));\n }\n }\n }\n};\n\nfunction isPrivateNameConflicted(privateNameMap, element) {\n var name = element.key.name;\n var curr = privateNameMap[name];\n\n var next = \"true\";\n if (element.type === \"MethodDefinition\" && (element.kind === \"get\" || element.kind === \"set\")) {\n next = (element.static ? \"s\" : \"i\") + element.kind;\n }\n\n // `class { get #a(){}; static set #a(_){} }` is also conflict.\n if (\n curr === \"iget\" && next === \"iset\" ||\n curr === \"iset\" && next === \"iget\" ||\n curr === \"sget\" && next === \"sset\" ||\n curr === \"sset\" && next === \"sget\"\n ) {\n privateNameMap[name] = \"true\";\n return false\n } else if (!curr) {\n privateNameMap[name] = next;\n return false\n } else {\n return true\n }\n}\n\nfunction checkKeyName(node, name) {\n var computed = node.computed;\n var key = node.key;\n return !computed && (\n key.type === \"Identifier\" && key.name === name ||\n key.type === \"Literal\" && key.value === name\n )\n}\n\n// Parses module export declaration.\n\npp$8.parseExport = function(node, exports) {\n this.next();\n // export * from '...'\n if (this.eat(types$1.star)) {\n if (this.options.ecmaVersion >= 11) {\n if (this.eatContextual(\"as\")) {\n node.exported = this.parseModuleExportName();\n this.checkExport(exports, node.exported, this.lastTokStart);\n } else {\n node.exported = null;\n }\n }\n this.expectContextual(\"from\");\n if (this.type !== types$1.string) { this.unexpected(); }\n node.source = this.parseExprAtom();\n this.semicolon();\n return this.finishNode(node, \"ExportAllDeclaration\")\n }\n if (this.eat(types$1._default)) { // export default ...\n this.checkExport(exports, \"default\", this.lastTokStart);\n var isAsync;\n if (this.type === types$1._function || (isAsync = this.isAsyncFunction())) {\n var fNode = this.startNode();\n this.next();\n if (isAsync) { this.next(); }\n node.declaration = this.parseFunction(fNode, FUNC_STATEMENT | FUNC_NULLABLE_ID, false, isAsync);\n } else if (this.type === types$1._class) {\n var cNode = this.startNode();\n node.declaration = this.parseClass(cNode, \"nullableID\");\n } else {\n node.declaration = this.parseMaybeAssign();\n this.semicolon();\n }\n return this.finishNode(node, \"ExportDefaultDeclaration\")\n }\n // export var|const|let|function|class ...\n if (this.shouldParseExportStatement()) {\n node.declaration = this.parseStatement(null);\n if (node.declaration.type === \"VariableDeclaration\")\n { this.checkVariableExport(exports, node.declaration.declarations); }\n else\n { this.checkExport(exports, node.declaration.id, node.declaration.id.start); }\n node.specifiers = [];\n node.source = null;\n } else { // export { x, y as z } [from '...']\n node.declaration = null;\n node.specifiers = this.parseExportSpecifiers(exports);\n if (this.eatContextual(\"from\")) {\n if (this.type !== types$1.string) { this.unexpected(); }\n node.source = this.parseExprAtom();\n } else {\n for (var i = 0, list = node.specifiers; i < list.length; i += 1) {\n // check for keywords used as local names\n var spec = list[i];\n\n this.checkUnreserved(spec.local);\n // check if export is defined\n this.checkLocalExport(spec.local);\n\n if (spec.local.type === \"Literal\") {\n this.raise(spec.local.start, \"A string literal cannot be used as an exported binding without `from`.\");\n }\n }\n\n node.source = null;\n }\n this.semicolon();\n }\n return this.finishNode(node, \"ExportNamedDeclaration\")\n};\n\npp$8.checkExport = function(exports, name, pos) {\n if (!exports) { return }\n if (typeof name !== \"string\")\n { name = name.type === \"Identifier\" ? name.name : name.value; }\n if (hasOwn(exports, name))\n { this.raiseRecoverable(pos, \"Duplicate export '\" + name + \"'\"); }\n exports[name] = true;\n};\n\npp$8.checkPatternExport = function(exports, pat) {\n var type = pat.type;\n if (type === \"Identifier\")\n { this.checkExport(exports, pat, pat.start); }\n else if (type === \"ObjectPattern\")\n { for (var i = 0, list = pat.properties; i < list.length; i += 1)\n {\n var prop = list[i];\n\n this.checkPatternExport(exports, prop);\n } }\n else if (type === \"ArrayPattern\")\n { for (var i$1 = 0, list$1 = pat.elements; i$1 < list$1.length; i$1 += 1) {\n var elt = list$1[i$1];\n\n if (elt) { this.checkPatternExport(exports, elt); }\n } }\n else if (type === \"Property\")\n { this.checkPatternExport(exports, pat.value); }\n else if (type === \"AssignmentPattern\")\n { this.checkPatternExport(exports, pat.left); }\n else if (type === \"RestElement\")\n { this.checkPatternExport(exports, pat.argument); }\n else if (type === \"ParenthesizedExpression\")\n { this.checkPatternExport(exports, pat.expression); }\n};\n\npp$8.checkVariableExport = function(exports, decls) {\n if (!exports) { return }\n for (var i = 0, list = decls; i < list.length; i += 1)\n {\n var decl = list[i];\n\n this.checkPatternExport(exports, decl.id);\n }\n};\n\npp$8.shouldParseExportStatement = function() {\n return this.type.keyword === \"var\" ||\n this.type.keyword === \"const\" ||\n this.type.keyword === \"class\" ||\n this.type.keyword === \"function\" ||\n this.isLet() ||\n this.isAsyncFunction()\n};\n\n// Parses a comma-separated list of module exports.\n\npp$8.parseExportSpecifiers = function(exports) {\n var nodes = [], first = true;\n // export { x, y as z } [from '...']\n this.expect(types$1.braceL);\n while (!this.eat(types$1.braceR)) {\n if (!first) {\n this.expect(types$1.comma);\n if (this.afterTrailingComma(types$1.braceR)) { break }\n } else { first = false; }\n\n var node = this.startNode();\n node.local = this.parseModuleExportName();\n node.exported = this.eatContextual(\"as\") ? this.parseModuleExportName() : node.local;\n this.checkExport(\n exports,\n node.exported,\n node.exported.start\n );\n nodes.push(this.finishNode(node, \"ExportSpecifier\"));\n }\n return nodes\n};\n\n// Parses import declaration.\n\npp$8.parseImport = function(node) {\n this.next();\n // import '...'\n if (this.type === types$1.string) {\n node.specifiers = empty$1;\n node.source = this.parseExprAtom();\n } else {\n node.specifiers = this.parseImportSpecifiers();\n this.expectContextual(\"from\");\n node.source = this.type === types$1.string ? this.parseExprAtom() : this.unexpected();\n }\n this.semicolon();\n return this.finishNode(node, \"ImportDeclaration\")\n};\n\n// Parses a comma-separated list of module imports.\n\npp$8.parseImportSpecifiers = function() {\n var nodes = [], first = true;\n if (this.type === types$1.name) {\n // import defaultObj, { x, y as z } from '...'\n var node = this.startNode();\n node.local = this.parseIdent();\n this.checkLValSimple(node.local, BIND_LEXICAL);\n nodes.push(this.finishNode(node, \"ImportDefaultSpecifier\"));\n if (!this.eat(types$1.comma)) { return nodes }\n }\n if (this.type === types$1.star) {\n var node$1 = this.startNode();\n this.next();\n this.expectContextual(\"as\");\n node$1.local = this.parseIdent();\n this.checkLValSimple(node$1.local, BIND_LEXICAL);\n nodes.push(this.finishNode(node$1, \"ImportNamespaceSpecifier\"));\n return nodes\n }\n this.expect(types$1.braceL);\n while (!this.eat(types$1.braceR)) {\n if (!first) {\n this.expect(types$1.comma);\n if (this.afterTrailingComma(types$1.braceR)) { break }\n } else { first = false; }\n\n var node$2 = this.startNode();\n node$2.imported = this.parseModuleExportName();\n if (this.eatContextual(\"as\")) {\n node$2.local = this.parseIdent();\n } else {\n this.checkUnreserved(node$2.imported);\n node$2.local = node$2.imported;\n }\n this.checkLValSimple(node$2.local, BIND_LEXICAL);\n nodes.push(this.finishNode(node$2, \"ImportSpecifier\"));\n }\n return nodes\n};\n\npp$8.parseModuleExportName = function() {\n if (this.options.ecmaVersion >= 13 && this.type === types$1.string) {\n var stringLiteral = this.parseLiteral(this.value);\n if (loneSurrogate.test(stringLiteral.value)) {\n this.raise(stringLiteral.start, \"An export name cannot include a lone surrogate.\");\n }\n return stringLiteral\n }\n return this.parseIdent(true)\n};\n\n// Set `ExpressionStatement#directive` property for directive prologues.\npp$8.adaptDirectivePrologue = function(statements) {\n for (var i = 0; i < statements.length && this.isDirectiveCandidate(statements[i]); ++i) {\n statements[i].directive = statements[i].expression.raw.slice(1, -1);\n }\n};\npp$8.isDirectiveCandidate = function(statement) {\n return (\n this.options.ecmaVersion >= 5 &&\n statement.type === \"ExpressionStatement\" &&\n statement.expression.type === \"Literal\" &&\n typeof statement.expression.value === \"string\" &&\n // Reject parenthesized strings.\n (this.input[statement.start] === \"\\\"\" || this.input[statement.start] === \"'\")\n )\n};\n\nvar pp$7 = Parser.prototype;\n\n// Convert existing expression atom to assignable pattern\n// if possible.\n\npp$7.toAssignable = function(node, isBinding, refDestructuringErrors) {\n if (this.options.ecmaVersion >= 6 && node) {\n switch (node.type) {\n case \"Identifier\":\n if (this.inAsync && node.name === \"await\")\n { this.raise(node.start, \"Cannot use 'await' as identifier inside an async function\"); }\n break\n\n case \"ObjectPattern\":\n case \"ArrayPattern\":\n case \"AssignmentPattern\":\n case \"RestElement\":\n break\n\n case \"ObjectExpression\":\n node.type = \"ObjectPattern\";\n if (refDestructuringErrors) { this.checkPatternErrors(refDestructuringErrors, true); }\n for (var i = 0, list = node.properties; i < list.length; i += 1) {\n var prop = list[i];\n\n this.toAssignable(prop, isBinding);\n // Early error:\n // AssignmentRestProperty[Yield, Await] :\n // `...` DestructuringAssignmentTarget[Yield, Await]\n //\n // It is a Syntax Error if |DestructuringAssignmentTarget| is an |ArrayLiteral| or an |ObjectLiteral|.\n if (\n prop.type === \"RestElement\" &&\n (prop.argument.type === \"ArrayPattern\" || prop.argument.type === \"ObjectPattern\")\n ) {\n this.raise(prop.argument.start, \"Unexpected token\");\n }\n }\n break\n\n case \"Property\":\n // AssignmentProperty has type === \"Property\"\n if (node.kind !== \"init\") { this.raise(node.key.start, \"Object pattern can't contain getter or setter\"); }\n this.toAssignable(node.value, isBinding);\n break\n\n case \"ArrayExpression\":\n node.type = \"ArrayPattern\";\n if (refDestructuringErrors) { this.checkPatternErrors(refDestructuringErrors, true); }\n this.toAssignableList(node.elements, isBinding);\n break\n\n case \"SpreadElement\":\n node.type = \"RestElement\";\n this.toAssignable(node.argument, isBinding);\n if (node.argument.type === \"AssignmentPattern\")\n { this.raise(node.argument.start, \"Rest elements cannot have a default value\"); }\n break\n\n case \"AssignmentExpression\":\n if (node.operator !== \"=\") { this.raise(node.left.end, \"Only '=' operator can be used for specifying default value.\"); }\n node.type = \"AssignmentPattern\";\n delete node.operator;\n this.toAssignable(node.left, isBinding);\n break\n\n case \"ParenthesizedExpression\":\n this.toAssignable(node.expression, isBinding, refDestructuringErrors);\n break\n\n case \"ChainExpression\":\n this.raiseRecoverable(node.start, \"Optional chaining cannot appear in left-hand side\");\n break\n\n case \"MemberExpression\":\n if (!isBinding) { break }\n\n default:\n this.raise(node.start, \"Assigning to rvalue\");\n }\n } else if (refDestructuringErrors) { this.checkPatternErrors(refDestructuringErrors, true); }\n return node\n};\n\n// Convert list of expression atoms to binding list.\n\npp$7.toAssignableList = function(exprList, isBinding) {\n var end = exprList.length;\n for (var i = 0; i < end; i++) {\n var elt = exprList[i];\n if (elt) { this.toAssignable(elt, isBinding); }\n }\n if (end) {\n var last = exprList[end - 1];\n if (this.options.ecmaVersion === 6 && isBinding && last && last.type === \"RestElement\" && last.argument.type !== \"Identifier\")\n { this.unexpected(last.argument.start); }\n }\n return exprList\n};\n\n// Parses spread element.\n\npp$7.parseSpread = function(refDestructuringErrors) {\n var node = this.startNode();\n this.next();\n node.argument = this.parseMaybeAssign(false, refDestructuringErrors);\n return this.finishNode(node, \"SpreadElement\")\n};\n\npp$7.parseRestBinding = function() {\n var node = this.startNode();\n this.next();\n\n // RestElement inside of a function parameter must be an identifier\n if (this.options.ecmaVersion === 6 && this.type !== types$1.name)\n { this.unexpected(); }\n\n node.argument = this.parseBindingAtom();\n\n return this.finishNode(node, \"RestElement\")\n};\n\n// Parses lvalue (assignable) atom.\n\npp$7.parseBindingAtom = function() {\n if (this.options.ecmaVersion >= 6) {\n switch (this.type) {\n case types$1.bracketL:\n var node = this.startNode();\n this.next();\n node.elements = this.parseBindingList(types$1.bracketR, true, true);\n return this.finishNode(node, \"ArrayPattern\")\n\n case types$1.braceL:\n return this.parseObj(true)\n }\n }\n return this.parseIdent()\n};\n\npp$7.parseBindingList = function(close, allowEmpty, allowTrailingComma) {\n var elts = [], first = true;\n while (!this.eat(close)) {\n if (first) { first = false; }\n else { this.expect(types$1.comma); }\n if (allowEmpty && this.type === types$1.comma) {\n elts.push(null);\n } else if (allowTrailingComma && this.afterTrailingComma(close)) {\n break\n } else if (this.type === types$1.ellipsis) {\n var rest = this.parseRestBinding();\n this.parseBindingListItem(rest);\n elts.push(rest);\n if (this.type === types$1.comma) { this.raise(this.start, \"Comma is not permitted after the rest element\"); }\n this.expect(close);\n break\n } else {\n var elem = this.parseMaybeDefault(this.start, this.startLoc);\n this.parseBindingListItem(elem);\n elts.push(elem);\n }\n }\n return elts\n};\n\npp$7.parseBindingListItem = function(param) {\n return param\n};\n\n// Parses assignment pattern around given atom if possible.\n\npp$7.parseMaybeDefault = function(startPos, startLoc, left) {\n left = left || this.parseBindingAtom();\n if (this.options.ecmaVersion < 6 || !this.eat(types$1.eq)) { return left }\n var node = this.startNodeAt(startPos, startLoc);\n node.left = left;\n node.right = this.parseMaybeAssign();\n return this.finishNode(node, \"AssignmentPattern\")\n};\n\n// The following three functions all verify that a node is an lvalue \u2014\n// something that can be bound, or assigned to. In order to do so, they perform\n// a variety of checks:\n//\n// - Check that none of the bound/assigned-to identifiers are reserved words.\n// - Record name declarations for bindings in the appropriate scope.\n// - Check duplicate argument names, if checkClashes is set.\n//\n// If a complex binding pattern is encountered (e.g., object and array\n// destructuring), the entire pattern is recursively checked.\n//\n// There are three versions of checkLVal*() appropriate for different\n// circumstances:\n//\n// - checkLValSimple() shall be used if the syntactic construct supports\n// nothing other than identifiers and member expressions. Parenthesized\n// expressions are also correctly handled. This is generally appropriate for\n// constructs for which the spec says\n//\n// > It is a Syntax Error if AssignmentTargetType of [the production] is not\n// > simple.\n//\n// It is also appropriate for checking if an identifier is valid and not\n// defined elsewhere, like import declarations or function/class identifiers.\n//\n// Examples where this is used include:\n// a += \u2026;\n// import a from '\u2026';\n// where a is the node to be checked.\n//\n// - checkLValPattern() shall be used if the syntactic construct supports\n// anything checkLValSimple() supports, as well as object and array\n// destructuring patterns. This is generally appropriate for constructs for\n// which the spec says\n//\n// > It is a Syntax Error if [the production] is neither an ObjectLiteral nor\n// > an ArrayLiteral and AssignmentTargetType of [the production] is not\n// > simple.\n//\n// Examples where this is used include:\n// (a = \u2026);\n// const a = \u2026;\n// try { \u2026 } catch (a) { \u2026 }\n// where a is the node to be checked.\n//\n// - checkLValInnerPattern() shall be used if the syntactic construct supports\n// anything checkLValPattern() supports, as well as default assignment\n// patterns, rest elements, and other constructs that may appear within an\n// object or array destructuring pattern.\n//\n// As a special case, function parameters also use checkLValInnerPattern(),\n// as they also support defaults and rest constructs.\n//\n// These functions deliberately support both assignment and binding constructs,\n// as the logic for both is exceedingly similar. If the node is the target of\n// an assignment, then bindingType should be set to BIND_NONE. Otherwise, it\n// should be set to the appropriate BIND_* constant, like BIND_VAR or\n// BIND_LEXICAL.\n//\n// If the function is called with a non-BIND_NONE bindingType, then\n// additionally a checkClashes object may be specified to allow checking for\n// duplicate argument names. checkClashes is ignored if the provided construct\n// is an assignment (i.e., bindingType is BIND_NONE).\n\npp$7.checkLValSimple = function(expr, bindingType, checkClashes) {\n if ( bindingType === void 0 ) bindingType = BIND_NONE;\n\n var isBind = bindingType !== BIND_NONE;\n\n switch (expr.type) {\n case \"Identifier\":\n if (this.strict && this.reservedWordsStrictBind.test(expr.name))\n { this.raiseRecoverable(expr.start, (isBind ? \"Binding \" : \"Assigning to \") + expr.name + \" in strict mode\"); }\n if (isBind) {\n if (bindingType === BIND_LEXICAL && expr.name === \"let\")\n { this.raiseRecoverable(expr.start, \"let is disallowed as a lexically bound name\"); }\n if (checkClashes) {\n if (hasOwn(checkClashes, expr.name))\n { this.raiseRecoverable(expr.start, \"Argument name clash\"); }\n checkClashes[expr.name] = true;\n }\n if (bindingType !== BIND_OUTSIDE) { this.declareName(expr.name, bindingType, expr.start); }\n }\n break\n\n case \"ChainExpression\":\n this.raiseRecoverable(expr.start, \"Optional chaining cannot appear in left-hand side\");\n break\n\n case \"MemberExpression\":\n if (isBind) { this.raiseRecoverable(expr.start, \"Binding member expression\"); }\n break\n\n case \"ParenthesizedExpression\":\n if (isBind) { this.raiseRecoverable(expr.start, \"Binding parenthesized expression\"); }\n return this.checkLValSimple(expr.expression, bindingType, checkClashes)\n\n default:\n this.raise(expr.start, (isBind ? \"Binding\" : \"Assigning to\") + \" rvalue\");\n }\n};\n\npp$7.checkLValPattern = function(expr, bindingType, checkClashes) {\n if ( bindingType === void 0 ) bindingType = BIND_NONE;\n\n switch (expr.type) {\n case \"ObjectPattern\":\n for (var i = 0, list = expr.properties; i < list.length; i += 1) {\n var prop = list[i];\n\n this.checkLValInnerPattern(prop, bindingType, checkClashes);\n }\n break\n\n case \"ArrayPattern\":\n for (var i$1 = 0, list$1 = expr.elements; i$1 < list$1.length; i$1 += 1) {\n var elem = list$1[i$1];\n\n if (elem) { this.checkLValInnerPattern(elem, bindingType, checkClashes); }\n }\n break\n\n default:\n this.checkLValSimple(expr, bindingType, checkClashes);\n }\n};\n\npp$7.checkLValInnerPattern = function(expr, bindingType, checkClashes) {\n if ( bindingType === void 0 ) bindingType = BIND_NONE;\n\n switch (expr.type) {\n case \"Property\":\n // AssignmentProperty has type === \"Property\"\n this.checkLValInnerPattern(expr.value, bindingType, checkClashes);\n break\n\n case \"AssignmentPattern\":\n this.checkLValPattern(expr.left, bindingType, checkClashes);\n break\n\n case \"RestElement\":\n this.checkLValPattern(expr.argument, bindingType, checkClashes);\n break\n\n default:\n this.checkLValPattern(expr, bindingType, checkClashes);\n }\n};\n\n// The algorithm used to determine whether a regexp can appear at a\n\nvar TokContext = function TokContext(token, isExpr, preserveSpace, override, generator) {\n this.token = token;\n this.isExpr = !!isExpr;\n this.preserveSpace = !!preserveSpace;\n this.override = override;\n this.generator = !!generator;\n};\n\nvar types = {\n b_stat: new TokContext(\"{\", false),\n b_expr: new TokContext(\"{\", true),\n b_tmpl: new TokContext(\"${\", false),\n p_stat: new TokContext(\"(\", false),\n p_expr: new TokContext(\"(\", true),\n q_tmpl: new TokContext(\"`\", true, true, function (p) { return p.tryReadTemplateToken(); }),\n f_stat: new TokContext(\"function\", false),\n f_expr: new TokContext(\"function\", true),\n f_expr_gen: new TokContext(\"function\", true, false, null, true),\n f_gen: new TokContext(\"function\", false, false, null, true)\n};\n\nvar pp$6 = Parser.prototype;\n\npp$6.initialContext = function() {\n return [types.b_stat]\n};\n\npp$6.curContext = function() {\n return this.context[this.context.length - 1]\n};\n\npp$6.braceIsBlock = function(prevType) {\n var parent = this.curContext();\n if (parent === types.f_expr || parent === types.f_stat)\n { return true }\n if (prevType === types$1.colon && (parent === types.b_stat || parent === types.b_expr))\n { return !parent.isExpr }\n\n // The check for `tt.name && exprAllowed` detects whether we are\n // after a `yield` or `of` construct. See the `updateContext` for\n // `tt.name`.\n if (prevType === types$1._return || prevType === types$1.name && this.exprAllowed)\n { return lineBreak.test(this.input.slice(this.lastTokEnd, this.start)) }\n if (prevType === types$1._else || prevType === types$1.semi || prevType === types$1.eof || prevType === types$1.parenR || prevType === types$1.arrow)\n { return true }\n if (prevType === types$1.braceL)\n { return parent === types.b_stat }\n if (prevType === types$1._var || prevType === types$1._const || prevType === types$1.name)\n { return false }\n return !this.exprAllowed\n};\n\npp$6.inGeneratorContext = function() {\n for (var i = this.context.length - 1; i >= 1; i--) {\n var context = this.context[i];\n if (context.token === \"function\")\n { return context.generator }\n }\n return false\n};\n\npp$6.updateContext = function(prevType) {\n var update, type = this.type;\n if (type.keyword && prevType === types$1.dot)\n { this.exprAllowed = false; }\n else if (update = type.updateContext)\n { update.call(this, prevType); }\n else\n { this.exprAllowed = type.beforeExpr; }\n};\n\n// Used to handle egde cases when token context could not be inferred correctly during tokenization phase\n\npp$6.overrideContext = function(tokenCtx) {\n if (this.curContext() !== tokenCtx) {\n this.context[this.context.length - 1] = tokenCtx;\n }\n};\n\n// Token-specific context update code\n\ntypes$1.parenR.updateContext = types$1.braceR.updateContext = function() {\n if (this.context.length === 1) {\n this.exprAllowed = true;\n return\n }\n var out = this.context.pop();\n if (out === types.b_stat && this.curContext().token === \"function\") {\n out = this.context.pop();\n }\n this.exprAllowed = !out.isExpr;\n};\n\ntypes$1.braceL.updateContext = function(prevType) {\n this.context.push(this.braceIsBlock(prevType) ? types.b_stat : types.b_expr);\n this.exprAllowed = true;\n};\n\ntypes$1.dollarBraceL.updateContext = function() {\n this.context.push(types.b_tmpl);\n this.exprAllowed = true;\n};\n\ntypes$1.parenL.updateContext = function(prevType) {\n var statementParens = prevType === types$1._if || prevType === types$1._for || prevType === types$1._with || prevType === types$1._while;\n this.context.push(statementParens ? types.p_stat : types.p_expr);\n this.exprAllowed = true;\n};\n\ntypes$1.incDec.updateContext = function() {\n // tokExprAllowed stays unchanged\n};\n\ntypes$1._function.updateContext = types$1._class.updateContext = function(prevType) {\n if (prevType.beforeExpr && prevType !== types$1._else &&\n !(prevType === types$1.semi && this.curContext() !== types.p_stat) &&\n !(prevType === types$1._return && lineBreak.test(this.input.slice(this.lastTokEnd, this.start))) &&\n !((prevType === types$1.colon || prevType === types$1.braceL) && this.curContext() === types.b_stat))\n { this.context.push(types.f_expr); }\n else\n { this.context.push(types.f_stat); }\n this.exprAllowed = false;\n};\n\ntypes$1.backQuote.updateContext = function() {\n if (this.curContext() === types.q_tmpl)\n { this.context.pop(); }\n else\n { this.context.push(types.q_tmpl); }\n this.exprAllowed = false;\n};\n\ntypes$1.star.updateContext = function(prevType) {\n if (prevType === types$1._function) {\n var index = this.context.length - 1;\n if (this.context[index] === types.f_expr)\n { this.context[index] = types.f_expr_gen; }\n else\n { this.context[index] = types.f_gen; }\n }\n this.exprAllowed = true;\n};\n\ntypes$1.name.updateContext = function(prevType) {\n var allowed = false;\n if (this.options.ecmaVersion >= 6 && prevType !== types$1.dot) {\n if (this.value === \"of\" && !this.exprAllowed ||\n this.value === \"yield\" && this.inGeneratorContext())\n { allowed = true; }\n }\n this.exprAllowed = allowed;\n};\n\n// A recursive descent parser operates by defining functions for all\n\nvar pp$5 = Parser.prototype;\n\n// Check if property name clashes with already added.\n// Object/class getters and setters are not allowed to clash \u2014\n// either with each other or with an init property \u2014 and in\n// strict mode, init properties are also not allowed to be repeated.\n\npp$5.checkPropClash = function(prop, propHash, refDestructuringErrors) {\n if (this.options.ecmaVersion >= 9 && prop.type === \"SpreadElement\")\n { return }\n if (this.options.ecmaVersion >= 6 && (prop.computed || prop.method || prop.shorthand))\n { return }\n var key = prop.key;\n var name;\n switch (key.type) {\n case \"Identifier\": name = key.name; break\n case \"Literal\": name = String(key.value); break\n default: return\n }\n var kind = prop.kind;\n if (this.options.ecmaVersion >= 6) {\n if (name === \"__proto__\" && kind === \"init\") {\n if (propHash.proto) {\n if (refDestructuringErrors) {\n if (refDestructuringErrors.doubleProto < 0) {\n refDestructuringErrors.doubleProto = key.start;\n }\n } else {\n this.raiseRecoverable(key.start, \"Redefinition of __proto__ property\");\n }\n }\n propHash.proto = true;\n }\n return\n }\n name = \"$\" + name;\n var other = propHash[name];\n if (other) {\n var redefinition;\n if (kind === \"init\") {\n redefinition = this.strict && other.init || other.get || other.set;\n } else {\n redefinition = other.init || other[kind];\n }\n if (redefinition)\n { this.raiseRecoverable(key.start, \"Redefinition of property\"); }\n } else {\n other = propHash[name] = {\n init: false,\n get: false,\n set: false\n };\n }\n other[kind] = true;\n};\n\n// ### Expression parsing\n\n// These nest, from the most general expression type at the top to\n// 'atomic', nondivisible expression types at the bottom. Most of\n// the functions will simply let the function(s) below them parse,\n// and, *if* the syntactic construct they handle is present, wrap\n// the AST node that the inner parser gave them in another node.\n\n// Parse a full expression. The optional arguments are used to\n// forbid the `in` operator (in for loops initalization expressions)\n// and provide reference for storing '=' operator inside shorthand\n// property assignment in contexts where both object expression\n// and object pattern might appear (so it's possible to raise\n// delayed syntax error at correct position).\n\npp$5.parseExpression = function(forInit, refDestructuringErrors) {\n var startPos = this.start, startLoc = this.startLoc;\n var expr = this.parseMaybeAssign(forInit, refDestructuringErrors);\n if (this.type === types$1.comma) {\n var node = this.startNodeAt(startPos, startLoc);\n node.expressions = [expr];\n while (this.eat(types$1.comma)) { node.expressions.push(this.parseMaybeAssign(forInit, refDestructuringErrors)); }\n return this.finishNode(node, \"SequenceExpression\")\n }\n return expr\n};\n\n// Parse an assignment expression. This includes applications of\n// operators like `+=`.\n\npp$5.parseMaybeAssign = function(forInit, refDestructuringErrors, afterLeftParse) {\n if (this.isContextual(\"yield\")) {\n if (this.inGenerator) { return this.parseYield(forInit) }\n // The tokenizer will assume an expression is allowed after\n // `yield`, but this isn't that kind of yield\n else { this.exprAllowed = false; }\n }\n\n var ownDestructuringErrors = false, oldParenAssign = -1, oldTrailingComma = -1, oldDoubleProto = -1;\n if (refDestructuringErrors) {\n oldParenAssign = refDestructuringErrors.parenthesizedAssign;\n oldTrailingComma = refDestructuringErrors.trailingComma;\n oldDoubleProto = refDestructuringErrors.doubleProto;\n refDestructuringErrors.parenthesizedAssign = refDestructuringErrors.trailingComma = -1;\n } else {\n refDestructuringErrors = new DestructuringErrors;\n ownDestructuringErrors = true;\n }\n\n var startPos = this.start, startLoc = this.startLoc;\n if (this.type === types$1.parenL || this.type === types$1.name) {\n this.potentialArrowAt = this.start;\n this.potentialArrowInForAwait = forInit === \"await\";\n }\n var left = this.parseMaybeConditional(forInit, refDestructuringErrors);\n if (afterLeftParse) { left = afterLeftParse.call(this, left, startPos, startLoc); }\n if (this.type.isAssign) {\n var node = this.startNodeAt(startPos, startLoc);\n node.operator = this.value;\n if (this.type === types$1.eq)\n { left = this.toAssignable(left, false, refDestructuringErrors); }\n if (!ownDestructuringErrors) {\n refDestructuringErrors.parenthesizedAssign = refDestructuringErrors.trailingComma = refDestructuringErrors.doubleProto = -1;\n }\n if (refDestructuringErrors.shorthandAssign >= left.start)\n { refDestructuringErrors.shorthandAssign = -1; } // reset because shorthand default was used correctly\n if (this.type === types$1.eq)\n { this.checkLValPattern(left); }\n else\n { this.checkLValSimple(left); }\n node.left = left;\n this.next();\n node.right = this.parseMaybeAssign(forInit);\n if (oldDoubleProto > -1) { refDestructuringErrors.doubleProto = oldDoubleProto; }\n return this.finishNode(node, \"AssignmentExpression\")\n } else {\n if (ownDestructuringErrors) { this.checkExpressionErrors(refDestructuringErrors, true); }\n }\n if (oldParenAssign > -1) { refDestructuringErrors.parenthesizedAssign = oldParenAssign; }\n if (oldTrailingComma > -1) { refDestructuringErrors.trailingComma = oldTrailingComma; }\n return left\n};\n\n// Parse a ternary conditional (`?:`) operator.\n\npp$5.parseMaybeConditional = function(forInit, refDestructuringErrors) {\n var startPos = this.start, startLoc = this.startLoc;\n var expr = this.parseExprOps(forInit, refDestructuringErrors);\n if (this.checkExpressionErrors(refDestructuringErrors)) { return expr }\n if (this.eat(types$1.question)) {\n var node = this.startNodeAt(startPos, startLoc);\n node.test = expr;\n node.consequent = this.parseMaybeAssign();\n this.expect(types$1.colon);\n node.alternate = this.parseMaybeAssign(forInit);\n return this.finishNode(node, \"ConditionalExpression\")\n }\n return expr\n};\n\n// Start the precedence parser.\n\npp$5.parseExprOps = function(forInit, refDestructuringErrors) {\n var startPos = this.start, startLoc = this.startLoc;\n var expr = this.parseMaybeUnary(refDestructuringErrors, false, false, forInit);\n if (this.checkExpressionErrors(refDestructuringErrors)) { return expr }\n return expr.start === startPos && expr.type === \"ArrowFunctionExpression\" ? expr : this.parseExprOp(expr, startPos, startLoc, -1, forInit)\n};\n\n// Parse binary operators with the operator precedence parsing\n// algorithm. `left` is the left-hand side of the operator.\n// `minPrec` provides context that allows the function to stop and\n// defer further parser to one of its callers when it encounters an\n// operator that has a lower precedence than the set it is parsing.\n\npp$5.parseExprOp = function(left, leftStartPos, leftStartLoc, minPrec, forInit) {\n var prec = this.type.binop;\n if (prec != null && (!forInit || this.type !== types$1._in)) {\n if (prec > minPrec) {\n var logical = this.type === types$1.logicalOR || this.type === types$1.logicalAND;\n var coalesce = this.type === types$1.coalesce;\n if (coalesce) {\n // Handle the precedence of `tt.coalesce` as equal to the range of logical expressions.\n // In other words, `node.right` shouldn't contain logical expressions in order to check the mixed error.\n prec = types$1.logicalAND.binop;\n }\n var op = this.value;\n this.next();\n var startPos = this.start, startLoc = this.startLoc;\n var right = this.parseExprOp(this.parseMaybeUnary(null, false, false, forInit), startPos, startLoc, prec, forInit);\n var node = this.buildBinary(leftStartPos, leftStartLoc, left, right, op, logical || coalesce);\n if ((logical && this.type === types$1.coalesce) || (coalesce && (this.type === types$1.logicalOR || this.type === types$1.logicalAND))) {\n this.raiseRecoverable(this.start, \"Logical expressions and coalesce expressions cannot be mixed. Wrap either by parentheses\");\n }\n return this.parseExprOp(node, leftStartPos, leftStartLoc, minPrec, forInit)\n }\n }\n return left\n};\n\npp$5.buildBinary = function(startPos, startLoc, left, right, op, logical) {\n if (right.type === \"PrivateIdentifier\") { this.raise(right.start, \"Private identifier can only be left side of binary expression\"); }\n var node = this.startNodeAt(startPos, startLoc);\n node.left = left;\n node.operator = op;\n node.right = right;\n return this.finishNode(node, logical ? \"LogicalExpression\" : \"BinaryExpression\")\n};\n\n// Parse unary operators, both prefix and postfix.\n\npp$5.parseMaybeUnary = function(refDestructuringErrors, sawUnary, incDec, forInit) {\n var startPos = this.start, startLoc = this.startLoc, expr;\n if (this.isContextual(\"await\") && this.canAwait) {\n expr = this.parseAwait(forInit);\n sawUnary = true;\n } else if (this.type.prefix) {\n var node = this.startNode(), update = this.type === types$1.incDec;\n node.operator = this.value;\n node.prefix = true;\n this.next();\n node.argument = this.parseMaybeUnary(null, true, update, forInit);\n this.checkExpressionErrors(refDestructuringErrors, true);\n if (update) { this.checkLValSimple(node.argument); }\n else if (this.strict && node.operator === \"delete\" &&\n node.argument.type === \"Identifier\")\n { this.raiseRecoverable(node.start, \"Deleting local variable in strict mode\"); }\n else if (node.operator === \"delete\" && isPrivateFieldAccess(node.argument))\n { this.raiseRecoverable(node.start, \"Private fields can not be deleted\"); }\n else { sawUnary = true; }\n expr = this.finishNode(node, update ? \"UpdateExpression\" : \"UnaryExpression\");\n } else if (!sawUnary && this.type === types$1.privateId) {\n if (forInit || this.privateNameStack.length === 0) { this.unexpected(); }\n expr = this.parsePrivateIdent();\n // only could be private fields in 'in', such as #x in obj\n if (this.type !== types$1._in) { this.unexpected(); }\n } else {\n expr = this.parseExprSubscripts(refDestructuringErrors, forInit);\n if (this.checkExpressionErrors(refDestructuringErrors)) { return expr }\n while (this.type.postfix && !this.canInsertSemicolon()) {\n var node$1 = this.startNodeAt(startPos, startLoc);\n node$1.operator = this.value;\n node$1.prefix = false;\n node$1.argument = expr;\n this.checkLValSimple(expr);\n this.next();\n expr = this.finishNode(node$1, \"UpdateExpression\");\n }\n }\n\n if (!incDec && this.eat(types$1.starstar)) {\n if (sawUnary)\n { this.unexpected(this.lastTokStart); }\n else\n { return this.buildBinary(startPos, startLoc, expr, this.parseMaybeUnary(null, false, false, forInit), \"**\", false) }\n } else {\n return expr\n }\n};\n\nfunction isPrivateFieldAccess(node) {\n return (\n node.type === \"MemberExpression\" && node.property.type === \"PrivateIdentifier\" ||\n node.type === \"ChainExpression\" && isPrivateFieldAccess(node.expression)\n )\n}\n\n// Parse call, dot, and `[]`-subscript expressions.\n\npp$5.parseExprSubscripts = function(refDestructuringErrors, forInit) {\n var startPos = this.start, startLoc = this.startLoc;\n var expr = this.parseExprAtom(refDestructuringErrors, forInit);\n if (expr.type === \"ArrowFunctionExpression\" && this.input.slice(this.lastTokStart, this.lastTokEnd) !== \")\")\n { return expr }\n var result = this.parseSubscripts(expr, startPos, startLoc, false, forInit);\n if (refDestructuringErrors && result.type === \"MemberExpression\") {\n if (refDestructuringErrors.parenthesizedAssign >= result.start) { refDestructuringErrors.parenthesizedAssign = -1; }\n if (refDestructuringErrors.parenthesizedBind >= result.start) { refDestructuringErrors.parenthesizedBind = -1; }\n if (refDestructuringErrors.trailingComma >= result.start) { refDestructuringErrors.trailingComma = -1; }\n }\n return result\n};\n\npp$5.parseSubscripts = function(base, startPos, startLoc, noCalls, forInit) {\n var maybeAsyncArrow = this.options.ecmaVersion >= 8 && base.type === \"Identifier\" && base.name === \"async\" &&\n this.lastTokEnd === base.end && !this.canInsertSemicolon() && base.end - base.start === 5 &&\n this.potentialArrowAt === base.start;\n var optionalChained = false;\n\n while (true) {\n var element = this.parseSubscript(base, startPos, startLoc, noCalls, maybeAsyncArrow, optionalChained, forInit);\n\n if (element.optional) { optionalChained = true; }\n if (element === base || element.type === \"ArrowFunctionExpression\") {\n if (optionalChained) {\n var chainNode = this.startNodeAt(startPos, startLoc);\n chainNode.expression = element;\n element = this.finishNode(chainNode, \"ChainExpression\");\n }\n return element\n }\n\n base = element;\n }\n};\n\npp$5.parseSubscript = function(base, startPos, startLoc, noCalls, maybeAsyncArrow, optionalChained, forInit) {\n var optionalSupported = this.options.ecmaVersion >= 11;\n var optional = optionalSupported && this.eat(types$1.questionDot);\n if (noCalls && optional) { this.raise(this.lastTokStart, \"Optional chaining cannot appear in the callee of new expressions\"); }\n\n var computed = this.eat(types$1.bracketL);\n if (computed || (optional && this.type !== types$1.parenL && this.type !== types$1.backQuote) || this.eat(types$1.dot)) {\n var node = this.startNodeAt(startPos, startLoc);\n node.object = base;\n if (computed) {\n node.property = this.parseExpression();\n this.expect(types$1.bracketR);\n } else if (this.type === types$1.privateId && base.type !== \"Super\") {\n node.property = this.parsePrivateIdent();\n } else {\n node.property = this.parseIdent(this.options.allowReserved !== \"never\");\n }\n node.computed = !!computed;\n if (optionalSupported) {\n node.optional = optional;\n }\n base = this.finishNode(node, \"MemberExpression\");\n } else if (!noCalls && this.eat(types$1.parenL)) {\n var refDestructuringErrors = new DestructuringErrors, oldYieldPos = this.yieldPos, oldAwaitPos = this.awaitPos, oldAwaitIdentPos = this.awaitIdentPos;\n this.yieldPos = 0;\n this.awaitPos = 0;\n this.awaitIdentPos = 0;\n var exprList = this.parseExprList(types$1.parenR, this.options.ecmaVersion >= 8, false, refDestructuringErrors);\n if (maybeAsyncArrow && !optional && !this.canInsertSemicolon() && this.eat(types$1.arrow)) {\n this.checkPatternErrors(refDestructuringErrors, false);\n this.checkYieldAwaitInDefaultParams();\n if (this.awaitIdentPos > 0)\n { this.raise(this.awaitIdentPos, \"Cannot use 'await' as identifier inside an async function\"); }\n this.yieldPos = oldYieldPos;\n this.awaitPos = oldAwaitPos;\n this.awaitIdentPos = oldAwaitIdentPos;\n return this.parseArrowExpression(this.startNodeAt(startPos, startLoc), exprList, true, forInit)\n }\n this.checkExpressionErrors(refDestructuringErrors, true);\n this.yieldPos = oldYieldPos || this.yieldPos;\n this.awaitPos = oldAwaitPos || this.awaitPos;\n this.awaitIdentPos = oldAwaitIdentPos || this.awaitIdentPos;\n var node$1 = this.startNodeAt(startPos, startLoc);\n node$1.callee = base;\n node$1.arguments = exprList;\n if (optionalSupported) {\n node$1.optional = optional;\n }\n base = this.finishNode(node$1, \"CallExpression\");\n } else if (this.type === types$1.backQuote) {\n if (optional || optionalChained) {\n this.raise(this.start, \"Optional chaining cannot appear in the tag of tagged template expressions\");\n }\n var node$2 = this.startNodeAt(startPos, startLoc);\n node$2.tag = base;\n node$2.quasi = this.parseTemplate({isTagged: true});\n base = this.finishNode(node$2, \"TaggedTemplateExpression\");\n }\n return base\n};\n\n// Parse an atomic expression \u2014 either a single token that is an\n// expression, an expression started by a keyword like `function` or\n// `new`, or an expression wrapped in punctuation like `()`, `[]`,\n// or `{}`.\n\npp$5.parseExprAtom = function(refDestructuringErrors, forInit) {\n // If a division operator appears in an expression position, the\n // tokenizer got confused, and we force it to read a regexp instead.\n if (this.type === types$1.slash) { this.readRegexp(); }\n\n var node, canBeArrow = this.potentialArrowAt === this.start;\n switch (this.type) {\n case types$1._super:\n if (!this.allowSuper)\n { this.raise(this.start, \"'super' keyword outside a method\"); }\n node = this.startNode();\n this.next();\n if (this.type === types$1.parenL && !this.allowDirectSuper)\n { this.raise(node.start, \"super() call outside constructor of a subclass\"); }\n // The `super` keyword can appear at below:\n // SuperProperty:\n // super [ Expression ]\n // super . IdentifierName\n // SuperCall:\n // super ( Arguments )\n if (this.type !== types$1.dot && this.type !== types$1.bracketL && this.type !== types$1.parenL)\n { this.unexpected(); }\n return this.finishNode(node, \"Super\")\n\n case types$1._this:\n node = this.startNode();\n this.next();\n return this.finishNode(node, \"ThisExpression\")\n\n case types$1.name:\n var startPos = this.start, startLoc = this.startLoc, containsEsc = this.containsEsc;\n var id = this.parseIdent(false);\n if (this.options.ecmaVersion >= 8 && !containsEsc && id.name === \"async\" && !this.canInsertSemicolon() && this.eat(types$1._function)) {\n this.overrideContext(types.f_expr);\n return this.parseFunction(this.startNodeAt(startPos, startLoc), 0, false, true, forInit)\n }\n if (canBeArrow && !this.canInsertSemicolon()) {\n if (this.eat(types$1.arrow))\n { return this.parseArrowExpression(this.startNodeAt(startPos, startLoc), [id], false, forInit) }\n if (this.options.ecmaVersion >= 8 && id.name === \"async\" && this.type === types$1.name && !containsEsc &&\n (!this.potentialArrowInForAwait || this.value !== \"of\" || this.containsEsc)) {\n id = this.parseIdent(false);\n if (this.canInsertSemicolon() || !this.eat(types$1.arrow))\n { this.unexpected(); }\n return this.parseArrowExpression(this.startNodeAt(startPos, startLoc), [id], true, forInit)\n }\n }\n return id\n\n case types$1.regexp:\n var value = this.value;\n node = this.parseLiteral(value.value);\n node.regex = {pattern: value.pattern, flags: value.flags};\n return node\n\n case types$1.num: case types$1.string:\n return this.parseLiteral(this.value)\n\n case types$1._null: case types$1._true: case types$1._false:\n node = this.startNode();\n node.value = this.type === types$1._null ? null : this.type === types$1._true;\n node.raw = this.type.keyword;\n this.next();\n return this.finishNode(node, \"Literal\")\n\n case types$1.parenL:\n var start = this.start, expr = this.parseParenAndDistinguishExpression(canBeArrow, forInit);\n if (refDestructuringErrors) {\n if (refDestructuringErrors.parenthesizedAssign < 0 && !this.isSimpleAssignTarget(expr))\n { refDestructuringErrors.parenthesizedAssign = start; }\n if (refDestructuringErrors.parenthesizedBind < 0)\n { refDestructuringErrors.parenthesizedBind = start; }\n }\n return expr\n\n case types$1.bracketL:\n node = this.startNode();\n this.next();\n node.elements = this.parseExprList(types$1.bracketR, true, true, refDestructuringErrors);\n return this.finishNode(node, \"ArrayExpression\")\n\n case types$1.braceL:\n this.overrideContext(types.b_expr);\n return this.parseObj(false, refDestructuringErrors)\n\n case types$1._function:\n node = this.startNode();\n this.next();\n return this.parseFunction(node, 0)\n\n case types$1._class:\n return this.parseClass(this.startNode(), false)\n\n case types$1._new:\n return this.parseNew()\n\n case types$1.backQuote:\n return this.parseTemplate()\n\n case types$1._import:\n if (this.options.ecmaVersion >= 11) {\n return this.parseExprImport()\n } else {\n return this.unexpected()\n }\n\n default:\n this.unexpected();\n }\n};\n\npp$5.parseExprImport = function() {\n var node = this.startNode();\n\n // Consume `import` as an identifier for `import.meta`.\n // Because `this.parseIdent(true)` doesn't check escape sequences, it needs the check of `this.containsEsc`.\n if (this.containsEsc) { this.raiseRecoverable(this.start, \"Escape sequence in keyword import\"); }\n var meta = this.parseIdent(true);\n\n switch (this.type) {\n case types$1.parenL:\n return this.parseDynamicImport(node)\n case types$1.dot:\n node.meta = meta;\n return this.parseImportMeta(node)\n default:\n this.unexpected();\n }\n};\n\npp$5.parseDynamicImport = function(node) {\n this.next(); // skip `(`\n\n // Parse node.source.\n node.source = this.parseMaybeAssign();\n\n // Verify ending.\n if (!this.eat(types$1.parenR)) {\n var errorPos = this.start;\n if (this.eat(types$1.comma) && this.eat(types$1.parenR)) {\n this.raiseRecoverable(errorPos, \"Trailing comma is not allowed in import()\");\n } else {\n this.unexpected(errorPos);\n }\n }\n\n return this.finishNode(node, \"ImportExpression\")\n};\n\npp$5.parseImportMeta = function(node) {\n this.next(); // skip `.`\n\n var containsEsc = this.containsEsc;\n node.property = this.parseIdent(true);\n\n if (node.property.name !== \"meta\")\n { this.raiseRecoverable(node.property.start, \"The only valid meta property for import is 'import.meta'\"); }\n if (containsEsc)\n { this.raiseRecoverable(node.start, \"'import.meta' must not contain escaped characters\"); }\n if (this.options.sourceType !== \"module\" && !this.options.allowImportExportEverywhere)\n { this.raiseRecoverable(node.start, \"Cannot use 'import.meta' outside a module\"); }\n\n return this.finishNode(node, \"MetaProperty\")\n};\n\npp$5.parseLiteral = function(value) {\n var node = this.startNode();\n node.value = value;\n node.raw = this.input.slice(this.start, this.end);\n if (node.raw.charCodeAt(node.raw.length - 1) === 110) { node.bigint = node.raw.slice(0, -1).replace(/_/g, \"\"); }\n this.next();\n return this.finishNode(node, \"Literal\")\n};\n\npp$5.parseParenExpression = function() {\n this.expect(types$1.parenL);\n var val = this.parseExpression();\n this.expect(types$1.parenR);\n return val\n};\n\npp$5.parseParenAndDistinguishExpression = function(canBeArrow, forInit) {\n var startPos = this.start, startLoc = this.startLoc, val, allowTrailingComma = this.options.ecmaVersion >= 8;\n if (this.options.ecmaVersion >= 6) {\n this.next();\n\n var innerStartPos = this.start, innerStartLoc = this.startLoc;\n var exprList = [], first = true, lastIsComma = false;\n var refDestructuringErrors = new DestructuringErrors, oldYieldPos = this.yieldPos, oldAwaitPos = this.awaitPos, spreadStart;\n this.yieldPos = 0;\n this.awaitPos = 0;\n // Do not save awaitIdentPos to allow checking awaits nested in parameters\n while (this.type !== types$1.parenR) {\n first ? first = false : this.expect(types$1.comma);\n if (allowTrailingComma && this.afterTrailingComma(types$1.parenR, true)) {\n lastIsComma = true;\n break\n } else if (this.type === types$1.ellipsis) {\n spreadStart = this.start;\n exprList.push(this.parseParenItem(this.parseRestBinding()));\n if (this.type === types$1.comma) { this.raise(this.start, \"Comma is not permitted after the rest element\"); }\n break\n } else {\n exprList.push(this.parseMaybeAssign(false, refDestructuringErrors, this.parseParenItem));\n }\n }\n var innerEndPos = this.lastTokEnd, innerEndLoc = this.lastTokEndLoc;\n this.expect(types$1.parenR);\n\n if (canBeArrow && !this.canInsertSemicolon() && this.eat(types$1.arrow)) {\n this.checkPatternErrors(refDestructuringErrors, false);\n this.checkYieldAwaitInDefaultParams();\n this.yieldPos = oldYieldPos;\n this.awaitPos = oldAwaitPos;\n return this.parseParenArrowList(startPos, startLoc, exprList, forInit)\n }\n\n if (!exprList.length || lastIsComma) { this.unexpected(this.lastTokStart); }\n if (spreadStart) { this.unexpected(spreadStart); }\n this.checkExpressionErrors(refDestructuringErrors, true);\n this.yieldPos = oldYieldPos || this.yieldPos;\n this.awaitPos = oldAwaitPos || this.awaitPos;\n\n if (exprList.length > 1) {\n val = this.startNodeAt(innerStartPos, innerStartLoc);\n val.expressions = exprList;\n this.finishNodeAt(val, \"SequenceExpression\", innerEndPos, innerEndLoc);\n } else {\n val = exprList[0];\n }\n } else {\n val = this.parseParenExpression();\n }\n\n if (this.options.preserveParens) {\n var par = this.startNodeAt(startPos, startLoc);\n par.expression = val;\n return this.finishNode(par, \"ParenthesizedExpression\")\n } else {\n return val\n }\n};\n\npp$5.parseParenItem = function(item) {\n return item\n};\n\npp$5.parseParenArrowList = function(startPos, startLoc, exprList, forInit) {\n return this.parseArrowExpression(this.startNodeAt(startPos, startLoc), exprList, false, forInit)\n};\n\n// New's precedence is slightly tricky. It must allow its argument to\n// be a `[]` or dot subscript expression, but not a call \u2014 at least,\n// not without wrapping it in parentheses. Thus, it uses the noCalls\n// argument to parseSubscripts to prevent it from consuming the\n// argument list.\n\nvar empty = [];\n\npp$5.parseNew = function() {\n if (this.containsEsc) { this.raiseRecoverable(this.start, \"Escape sequence in keyword new\"); }\n var node = this.startNode();\n var meta = this.parseIdent(true);\n if (this.options.ecmaVersion >= 6 && this.eat(types$1.dot)) {\n node.meta = meta;\n var containsEsc = this.containsEsc;\n node.property = this.parseIdent(true);\n if (node.property.name !== \"target\")\n { this.raiseRecoverable(node.property.start, \"The only valid meta property for new is 'new.target'\"); }\n if (containsEsc)\n { this.raiseRecoverable(node.start, \"'new.target' must not contain escaped characters\"); }\n if (!this.allowNewDotTarget)\n { this.raiseRecoverable(node.start, \"'new.target' can only be used in functions and class static block\"); }\n return this.finishNode(node, \"MetaProperty\")\n }\n var startPos = this.start, startLoc = this.startLoc, isImport = this.type === types$1._import;\n node.callee = this.parseSubscripts(this.parseExprAtom(), startPos, startLoc, true, false);\n if (isImport && node.callee.type === \"ImportExpression\") {\n this.raise(startPos, \"Cannot use new with import()\");\n }\n if (this.eat(types$1.parenL)) { node.arguments = this.parseExprList(types$1.parenR, this.options.ecmaVersion >= 8, false); }\n else { node.arguments = empty; }\n return this.finishNode(node, \"NewExpression\")\n};\n\n// Parse template expression.\n\npp$5.parseTemplateElement = function(ref) {\n var isTagged = ref.isTagged;\n\n var elem = this.startNode();\n if (this.type === types$1.invalidTemplate) {\n if (!isTagged) {\n this.raiseRecoverable(this.start, \"Bad escape sequence in untagged template literal\");\n }\n elem.value = {\n raw: this.value,\n cooked: null\n };\n } else {\n elem.value = {\n raw: this.input.slice(this.start, this.end).replace(/\\r\\n?/g, \"\\n\"),\n cooked: this.value\n };\n }\n this.next();\n elem.tail = this.type === types$1.backQuote;\n return this.finishNode(elem, \"TemplateElement\")\n};\n\npp$5.parseTemplate = function(ref) {\n if ( ref === void 0 ) ref = {};\n var isTagged = ref.isTagged; if ( isTagged === void 0 ) isTagged = false;\n\n var node = this.startNode();\n this.next();\n node.expressions = [];\n var curElt = this.parseTemplateElement({isTagged: isTagged});\n node.quasis = [curElt];\n while (!curElt.tail) {\n if (this.type === types$1.eof) { this.raise(this.pos, \"Unterminated template literal\"); }\n this.expect(types$1.dollarBraceL);\n node.expressions.push(this.parseExpression());\n this.expect(types$1.braceR);\n node.quasis.push(curElt = this.parseTemplateElement({isTagged: isTagged}));\n }\n this.next();\n return this.finishNode(node, \"TemplateLiteral\")\n};\n\npp$5.isAsyncProp = function(prop) {\n return !prop.computed && prop.key.type === \"Identifier\" && prop.key.name === \"async\" &&\n (this.type === types$1.name || this.type === types$1.num || this.type === types$1.string || this.type === types$1.bracketL || this.type.keyword || (this.options.ecmaVersion >= 9 && this.type === types$1.star)) &&\n !lineBreak.test(this.input.slice(this.lastTokEnd, this.start))\n};\n\n// Parse an object literal or binding pattern.\n\npp$5.parseObj = function(isPattern, refDestructuringErrors) {\n var node = this.startNode(), first = true, propHash = {};\n node.properties = [];\n this.next();\n while (!this.eat(types$1.braceR)) {\n if (!first) {\n this.expect(types$1.comma);\n if (this.options.ecmaVersion >= 5 && this.afterTrailingComma(types$1.braceR)) { break }\n } else { first = false; }\n\n var prop = this.parseProperty(isPattern, refDestructuringErrors);\n if (!isPattern) { this.checkPropClash(prop, propHash, refDestructuringErrors); }\n node.properties.push(prop);\n }\n return this.finishNode(node, isPattern ? \"ObjectPattern\" : \"ObjectExpression\")\n};\n\npp$5.parseProperty = function(isPattern, refDestructuringErrors) {\n var prop = this.startNode(), isGenerator, isAsync, startPos, startLoc;\n if (this.options.ecmaVersion >= 9 && this.eat(types$1.ellipsis)) {\n if (isPattern) {\n prop.argument = this.parseIdent(false);\n if (this.type === types$1.comma) {\n this.raise(this.start, \"Comma is not permitted after the rest element\");\n }\n return this.finishNode(prop, \"RestElement\")\n }\n // Parse argument.\n prop.argument = this.parseMaybeAssign(false, refDestructuringErrors);\n // To disallow trailing comma via `this.toAssignable()`.\n if (this.type === types$1.comma && refDestructuringErrors && refDestructuringErrors.trailingComma < 0) {\n refDestructuringErrors.trailingComma = this.start;\n }\n // Finish\n return this.finishNode(prop, \"SpreadElement\")\n }\n if (this.options.ecmaVersion >= 6) {\n prop.method = false;\n prop.shorthand = false;\n if (isPattern || refDestructuringErrors) {\n startPos = this.start;\n startLoc = this.startLoc;\n }\n if (!isPattern)\n { isGenerator = this.eat(types$1.star); }\n }\n var containsEsc = this.containsEsc;\n this.parsePropertyName(prop);\n if (!isPattern && !containsEsc && this.options.ecmaVersion >= 8 && !isGenerator && this.isAsyncProp(prop)) {\n isAsync = true;\n isGenerator = this.options.ecmaVersion >= 9 && this.eat(types$1.star);\n this.parsePropertyName(prop, refDestructuringErrors);\n } else {\n isAsync = false;\n }\n this.parsePropertyValue(prop, isPattern, isGenerator, isAsync, startPos, startLoc, refDestructuringErrors, containsEsc);\n return this.finishNode(prop, \"Property\")\n};\n\npp$5.parsePropertyValue = function(prop, isPattern, isGenerator, isAsync, startPos, startLoc, refDestructuringErrors, containsEsc) {\n if ((isGenerator || isAsync) && this.type === types$1.colon)\n { this.unexpected(); }\n\n if (this.eat(types$1.colon)) {\n prop.value = isPattern ? this.parseMaybeDefault(this.start, this.startLoc) : this.parseMaybeAssign(false, refDestructuringErrors);\n prop.kind = \"init\";\n } else if (this.options.ecmaVersion >= 6 && this.type === types$1.parenL) {\n if (isPattern) { this.unexpected(); }\n prop.kind = \"init\";\n prop.method = true;\n prop.value = this.parseMethod(isGenerator, isAsync);\n } else if (!isPattern && !containsEsc &&\n this.options.ecmaVersion >= 5 && !prop.computed && prop.key.type === \"Identifier\" &&\n (prop.key.name === \"get\" || prop.key.name === \"set\") &&\n (this.type !== types$1.comma && this.type !== types$1.braceR && this.type !== types$1.eq)) {\n if (isGenerator || isAsync) { this.unexpected(); }\n prop.kind = prop.key.name;\n this.parsePropertyName(prop);\n prop.value = this.parseMethod(false);\n var paramCount = prop.kind === \"get\" ? 0 : 1;\n if (prop.value.params.length !== paramCount) {\n var start = prop.value.start;\n if (prop.kind === \"get\")\n { this.raiseRecoverable(start, \"getter should have no params\"); }\n else\n { this.raiseRecoverable(start, \"setter should have exactly one param\"); }\n } else {\n if (prop.kind === \"set\" && prop.value.params[0].type === \"RestElement\")\n { this.raiseRecoverable(prop.value.params[0].start, \"Setter cannot use rest params\"); }\n }\n } else if (this.options.ecmaVersion >= 6 && !prop.computed && prop.key.type === \"Identifier\") {\n if (isGenerator || isAsync) { this.unexpected(); }\n this.checkUnreserved(prop.key);\n if (prop.key.name === \"await\" && !this.awaitIdentPos)\n { this.awaitIdentPos = startPos; }\n prop.kind = \"init\";\n if (isPattern) {\n prop.value = this.parseMaybeDefault(startPos, startLoc, this.copyNode(prop.key));\n } else if (this.type === types$1.eq && refDestructuringErrors) {\n if (refDestructuringErrors.shorthandAssign < 0)\n { refDestructuringErrors.shorthandAssign = this.start; }\n prop.value = this.parseMaybeDefault(startPos, startLoc, this.copyNode(prop.key));\n } else {\n prop.value = this.copyNode(prop.key);\n }\n prop.shorthand = true;\n } else { this.unexpected(); }\n};\n\npp$5.parsePropertyName = function(prop) {\n if (this.options.ecmaVersion >= 6) {\n if (this.eat(types$1.bracketL)) {\n prop.computed = true;\n prop.key = this.parseMaybeAssign();\n this.expect(types$1.bracketR);\n return prop.key\n } else {\n prop.computed = false;\n }\n }\n return prop.key = this.type === types$1.num || this.type === types$1.string ? this.parseExprAtom() : this.parseIdent(this.options.allowReserved !== \"never\")\n};\n\n// Initialize empty function node.\n\npp$5.initFunction = function(node) {\n node.id = null;\n if (this.options.ecmaVersion >= 6) { node.generator = node.expression = false; }\n if (this.options.ecmaVersion >= 8) { node.async = false; }\n};\n\n// Parse object or class method.\n\npp$5.parseMethod = function(isGenerator, isAsync, allowDirectSuper) {\n var node = this.startNode(), oldYieldPos = this.yieldPos, oldAwaitPos = this.awaitPos, oldAwaitIdentPos = this.awaitIdentPos;\n\n this.initFunction(node);\n if (this.options.ecmaVersion >= 6)\n { node.generator = isGenerator; }\n if (this.options.ecmaVersion >= 8)\n { node.async = !!isAsync; }\n\n this.yieldPos = 0;\n this.awaitPos = 0;\n this.awaitIdentPos = 0;\n this.enterScope(functionFlags(isAsync, node.generator) | SCOPE_SUPER | (allowDirectSuper ? SCOPE_DIRECT_SUPER : 0));\n\n this.expect(types$1.parenL);\n node.params = this.parseBindingList(types$1.parenR, false, this.options.ecmaVersion >= 8);\n this.checkYieldAwaitInDefaultParams();\n this.parseFunctionBody(node, false, true, false);\n\n this.yieldPos = oldYieldPos;\n this.awaitPos = oldAwaitPos;\n this.awaitIdentPos = oldAwaitIdentPos;\n return this.finishNode(node, \"FunctionExpression\")\n};\n\n// Parse arrow function expression with given parameters.\n\npp$5.parseArrowExpression = function(node, params, isAsync, forInit) {\n var oldYieldPos = this.yieldPos, oldAwaitPos = this.awaitPos, oldAwaitIdentPos = this.awaitIdentPos;\n\n this.enterScope(functionFlags(isAsync, false) | SCOPE_ARROW);\n this.initFunction(node);\n if (this.options.ecmaVersion >= 8) { node.async = !!isAsync; }\n\n this.yieldPos = 0;\n this.awaitPos = 0;\n this.awaitIdentPos = 0;\n\n node.params = this.toAssignableList(params, true);\n this.parseFunctionBody(node, true, false, forInit);\n\n this.yieldPos = oldYieldPos;\n this.awaitPos = oldAwaitPos;\n this.awaitIdentPos = oldAwaitIdentPos;\n return this.finishNode(node, \"ArrowFunctionExpression\")\n};\n\n// Parse function body and check parameters.\n\npp$5.parseFunctionBody = function(node, isArrowFunction, isMethod, forInit) {\n var isExpression = isArrowFunction && this.type !== types$1.braceL;\n var oldStrict = this.strict, useStrict = false;\n\n if (isExpression) {\n node.body = this.parseMaybeAssign(forInit);\n node.expression = true;\n this.checkParams(node, false);\n } else {\n var nonSimple = this.options.ecmaVersion >= 7 && !this.isSimpleParamList(node.params);\n if (!oldStrict || nonSimple) {\n useStrict = this.strictDirective(this.end);\n // If this is a strict mode function, verify that argument names\n // are not repeated, and it does not try to bind the words `eval`\n // or `arguments`.\n if (useStrict && nonSimple)\n { this.raiseRecoverable(node.start, \"Illegal 'use strict' directive in function with non-simple parameter list\"); }\n }\n // Start a new scope with regard to labels and the `inFunction`\n // flag (restore them to their old value afterwards).\n var oldLabels = this.labels;\n this.labels = [];\n if (useStrict) { this.strict = true; }\n\n // Add the params to varDeclaredNames to ensure that an error is thrown\n // if a let/const declaration in the function clashes with one of the params.\n this.checkParams(node, !oldStrict && !useStrict && !isArrowFunction && !isMethod && this.isSimpleParamList(node.params));\n // Ensure the function name isn't a forbidden identifier in strict mode, e.g. 'eval'\n if (this.strict && node.id) { this.checkLValSimple(node.id, BIND_OUTSIDE); }\n node.body = this.parseBlock(false, undefined, useStrict && !oldStrict);\n node.expression = false;\n this.adaptDirectivePrologue(node.body.body);\n this.labels = oldLabels;\n }\n this.exitScope();\n};\n\npp$5.isSimpleParamList = function(params) {\n for (var i = 0, list = params; i < list.length; i += 1)\n {\n var param = list[i];\n\n if (param.type !== \"Identifier\") { return false\n } }\n return true\n};\n\n// Checks function params for various disallowed patterns such as using \"eval\"\n// or \"arguments\" and duplicate parameters.\n\npp$5.checkParams = function(node, allowDuplicates) {\n var nameHash = Object.create(null);\n for (var i = 0, list = node.params; i < list.length; i += 1)\n {\n var param = list[i];\n\n this.checkLValInnerPattern(param, BIND_VAR, allowDuplicates ? null : nameHash);\n }\n};\n\n// Parses a comma-separated list of expressions, and returns them as\n// an array. `close` is the token type that ends the list, and\n// `allowEmpty` can be turned on to allow subsequent commas with\n// nothing in between them to be parsed as `null` (which is needed\n// for array literals).\n\npp$5.parseExprList = function(close, allowTrailingComma, allowEmpty, refDestructuringErrors) {\n var elts = [], first = true;\n while (!this.eat(close)) {\n if (!first) {\n this.expect(types$1.comma);\n if (allowTrailingComma && this.afterTrailingComma(close)) { break }\n } else { first = false; }\n\n var elt = (void 0);\n if (allowEmpty && this.type === types$1.comma)\n { elt = null; }\n else if (this.type === types$1.ellipsis) {\n elt = this.parseSpread(refDestructuringErrors);\n if (refDestructuringErrors && this.type === types$1.comma && refDestructuringErrors.trailingComma < 0)\n { refDestructuringErrors.trailingComma = this.start; }\n } else {\n elt = this.parseMaybeAssign(false, refDestructuringErrors);\n }\n elts.push(elt);\n }\n return elts\n};\n\npp$5.checkUnreserved = function(ref) {\n var start = ref.start;\n var end = ref.end;\n var name = ref.name;\n\n if (this.inGenerator && name === \"yield\")\n { this.raiseRecoverable(start, \"Cannot use 'yield' as identifier inside a generator\"); }\n if (this.inAsync && name === \"await\")\n { this.raiseRecoverable(start, \"Cannot use 'await' as identifier inside an async function\"); }\n if (this.currentThisScope().inClassFieldInit && name === \"arguments\")\n { this.raiseRecoverable(start, \"Cannot use 'arguments' in class field initializer\"); }\n if (this.inClassStaticBlock && (name === \"arguments\" || name === \"await\"))\n { this.raise(start, (\"Cannot use \" + name + \" in class static initialization block\")); }\n if (this.keywords.test(name))\n { this.raise(start, (\"Unexpected keyword '\" + name + \"'\")); }\n if (this.options.ecmaVersion < 6 &&\n this.input.slice(start, end).indexOf(\"\\\\\") !== -1) { return }\n var re = this.strict ? this.reservedWordsStrict : this.reservedWords;\n if (re.test(name)) {\n if (!this.inAsync && name === \"await\")\n { this.raiseRecoverable(start, \"Cannot use keyword 'await' outside an async function\"); }\n this.raiseRecoverable(start, (\"The keyword '\" + name + \"' is reserved\"));\n }\n};\n\n// Parse the next token as an identifier. If `liberal` is true (used\n// when parsing properties), it will also convert keywords into\n// identifiers.\n\npp$5.parseIdent = function(liberal, isBinding) {\n var node = this.startNode();\n if (this.type === types$1.name) {\n node.name = this.value;\n } else if (this.type.keyword) {\n node.name = this.type.keyword;\n\n // To fix https://github.com/acornjs/acorn/issues/575\n // `class` and `function` keywords push new context into this.context.\n // But there is no chance to pop the context if the keyword is consumed as an identifier such as a property name.\n // If the previous token is a dot, this does not apply because the context-managing code already ignored the keyword\n if ((node.name === \"class\" || node.name === \"function\") &&\n (this.lastTokEnd !== this.lastTokStart + 1 || this.input.charCodeAt(this.lastTokStart) !== 46)) {\n this.context.pop();\n }\n } else {\n this.unexpected();\n }\n this.next(!!liberal);\n this.finishNode(node, \"Identifier\");\n if (!liberal) {\n this.checkUnreserved(node);\n if (node.name === \"await\" && !this.awaitIdentPos)\n { this.awaitIdentPos = node.start; }\n }\n return node\n};\n\npp$5.parsePrivateIdent = function() {\n var node = this.startNode();\n if (this.type === types$1.privateId) {\n node.name = this.value;\n } else {\n this.unexpected();\n }\n this.next();\n this.finishNode(node, \"PrivateIdentifier\");\n\n // For validating existence\n if (this.privateNameStack.length === 0) {\n this.raise(node.start, (\"Private field '#\" + (node.name) + \"' must be declared in an enclosing class\"));\n } else {\n this.privateNameStack[this.privateNameStack.length - 1].used.push(node);\n }\n\n return node\n};\n\n// Parses yield expression inside generator.\n\npp$5.parseYield = function(forInit) {\n if (!this.yieldPos) { this.yieldPos = this.start; }\n\n var node = this.startNode();\n this.next();\n if (this.type === types$1.semi || this.canInsertSemicolon() || (this.type !== types$1.star && !this.type.startsExpr)) {\n node.delegate = false;\n node.argument = null;\n } else {\n node.delegate = this.eat(types$1.star);\n node.argument = this.parseMaybeAssign(forInit);\n }\n return this.finishNode(node, \"YieldExpression\")\n};\n\npp$5.parseAwait = function(forInit) {\n if (!this.awaitPos) { this.awaitPos = this.start; }\n\n var node = this.startNode();\n this.next();\n node.argument = this.parseMaybeUnary(null, true, false, forInit);\n return this.finishNode(node, \"AwaitExpression\")\n};\n\nvar pp$4 = Parser.prototype;\n\n// This function is used to raise exceptions on parse errors. It\n// takes an offset integer (into the current `input`) to indicate\n// the location of the error, attaches the position to the end\n// of the error message, and then raises a `SyntaxError` with that\n// message.\n\npp$4.raise = function(pos, message) {\n var loc = getLineInfo(this.input, pos);\n message += \" (\" + loc.line + \":\" + loc.column + \")\";\n var err = new SyntaxError(message);\n err.pos = pos; err.loc = loc; err.raisedAt = this.pos;\n throw err\n};\n\npp$4.raiseRecoverable = pp$4.raise;\n\npp$4.curPosition = function() {\n if (this.options.locations) {\n return new Position(this.curLine, this.pos - this.lineStart)\n }\n};\n\nvar pp$3 = Parser.prototype;\n\nvar Scope = function Scope(flags) {\n this.flags = flags;\n // A list of var-declared names in the current lexical scope\n this.var = [];\n // A list of lexically-declared names in the current lexical scope\n this.lexical = [];\n // A list of lexically-declared FunctionDeclaration names in the current lexical scope\n this.functions = [];\n // A switch to disallow the identifier reference 'arguments'\n this.inClassFieldInit = false;\n};\n\n// The functions in this module keep track of declared variables in the current scope in order to detect duplicate variable names.\n\npp$3.enterScope = function(flags) {\n this.scopeStack.push(new Scope(flags));\n};\n\npp$3.exitScope = function() {\n this.scopeStack.pop();\n};\n\n// The spec says:\n// > At the top level of a function, or script, function declarations are\n// > treated like var declarations rather than like lexical declarations.\npp$3.treatFunctionsAsVarInScope = function(scope) {\n return (scope.flags & SCOPE_FUNCTION) || !this.inModule && (scope.flags & SCOPE_TOP)\n};\n\npp$3.declareName = function(name, bindingType, pos) {\n var redeclared = false;\n if (bindingType === BIND_LEXICAL) {\n var scope = this.currentScope();\n redeclared = scope.lexical.indexOf(name) > -1 || scope.functions.indexOf(name) > -1 || scope.var.indexOf(name) > -1;\n scope.lexical.push(name);\n if (this.inModule && (scope.flags & SCOPE_TOP))\n { delete this.undefinedExports[name]; }\n } else if (bindingType === BIND_SIMPLE_CATCH) {\n var scope$1 = this.currentScope();\n scope$1.lexical.push(name);\n } else if (bindingType === BIND_FUNCTION) {\n var scope$2 = this.currentScope();\n if (this.treatFunctionsAsVar)\n { redeclared = scope$2.lexical.indexOf(name) > -1; }\n else\n { redeclared = scope$2.lexical.indexOf(name) > -1 || scope$2.var.indexOf(name) > -1; }\n scope$2.functions.push(name);\n } else {\n for (var i = this.scopeStack.length - 1; i >= 0; --i) {\n var scope$3 = this.scopeStack[i];\n if (scope$3.lexical.indexOf(name) > -1 && !((scope$3.flags & SCOPE_SIMPLE_CATCH) && scope$3.lexical[0] === name) ||\n !this.treatFunctionsAsVarInScope(scope$3) && scope$3.functions.indexOf(name) > -1) {\n redeclared = true;\n break\n }\n scope$3.var.push(name);\n if (this.inModule && (scope$3.flags & SCOPE_TOP))\n { delete this.undefinedExports[name]; }\n if (scope$3.flags & SCOPE_VAR) { break }\n }\n }\n if (redeclared) { this.raiseRecoverable(pos, (\"Identifier '\" + name + \"' has already been declared\")); }\n};\n\npp$3.checkLocalExport = function(id) {\n // scope.functions must be empty as Module code is always strict.\n if (this.scopeStack[0].lexical.indexOf(id.name) === -1 &&\n this.scopeStack[0].var.indexOf(id.name) === -1) {\n this.undefinedExports[id.name] = id;\n }\n};\n\npp$3.currentScope = function() {\n return this.scopeStack[this.scopeStack.length - 1]\n};\n\npp$3.currentVarScope = function() {\n for (var i = this.scopeStack.length - 1;; i--) {\n var scope = this.scopeStack[i];\n if (scope.flags & SCOPE_VAR) { return scope }\n }\n};\n\n// Could be useful for `this`, `new.target`, `super()`, `super.property`, and `super[property]`.\npp$3.currentThisScope = function() {\n for (var i = this.scopeStack.length - 1;; i--) {\n var scope = this.scopeStack[i];\n if (scope.flags & SCOPE_VAR && !(scope.flags & SCOPE_ARROW)) { return scope }\n }\n};\n\nvar Node = function Node(parser, pos, loc) {\n this.type = \"\";\n this.start = pos;\n this.end = 0;\n if (parser.options.locations)\n { this.loc = new SourceLocation(parser, loc); }\n if (parser.options.directSourceFile)\n { this.sourceFile = parser.options.directSourceFile; }\n if (parser.options.ranges)\n { this.range = [pos, 0]; }\n};\n\n// Start an AST node, attaching a start offset.\n\nvar pp$2 = Parser.prototype;\n\npp$2.startNode = function() {\n return new Node(this, this.start, this.startLoc)\n};\n\npp$2.startNodeAt = function(pos, loc) {\n return new Node(this, pos, loc)\n};\n\n// Finish an AST node, adding `type` and `end` properties.\n\nfunction finishNodeAt(node, type, pos, loc) {\n node.type = type;\n node.end = pos;\n if (this.options.locations)\n { node.loc.end = loc; }\n if (this.options.ranges)\n { node.range[1] = pos; }\n return node\n}\n\npp$2.finishNode = function(node, type) {\n return finishNodeAt.call(this, node, type, this.lastTokEnd, this.lastTokEndLoc)\n};\n\n// Finish node at given position\n\npp$2.finishNodeAt = function(node, type, pos, loc) {\n return finishNodeAt.call(this, node, type, pos, loc)\n};\n\npp$2.copyNode = function(node) {\n var newNode = new Node(this, node.start, this.startLoc);\n for (var prop in node) { newNode[prop] = node[prop]; }\n return newNode\n};\n\n// This file contains Unicode properties extracted from the ECMAScript\n// specification. The lists are extracted like so:\n// $$('#table-binary-unicode-properties > figure > table > tbody > tr > td:nth-child(1) code').map(el => el.innerText)\n\n// #table-binary-unicode-properties\nvar ecma9BinaryProperties = \"ASCII ASCII_Hex_Digit AHex Alphabetic Alpha Any Assigned Bidi_Control Bidi_C Bidi_Mirrored Bidi_M Case_Ignorable CI Cased Changes_When_Casefolded CWCF Changes_When_Casemapped CWCM Changes_When_Lowercased CWL Changes_When_NFKC_Casefolded CWKCF Changes_When_Titlecased CWT Changes_When_Uppercased CWU Dash Default_Ignorable_Code_Point DI Deprecated Dep Diacritic Dia Emoji Emoji_Component Emoji_Modifier Emoji_Modifier_Base Emoji_Presentation Extender Ext Grapheme_Base Gr_Base Grapheme_Extend Gr_Ext Hex_Digit Hex IDS_Binary_Operator IDSB IDS_Trinary_Operator IDST ID_Continue IDC ID_Start IDS Ideographic Ideo Join_Control Join_C Logical_Order_Exception LOE Lowercase Lower Math Noncharacter_Code_Point NChar Pattern_Syntax Pat_Syn Pattern_White_Space Pat_WS Quotation_Mark QMark Radical Regional_Indicator RI Sentence_Terminal STerm Soft_Dotted SD Terminal_Punctuation Term Unified_Ideograph UIdeo Uppercase Upper Variation_Selector VS White_Space space XID_Continue XIDC XID_Start XIDS\";\nvar ecma10BinaryProperties = ecma9BinaryProperties + \" Extended_Pictographic\";\nvar ecma11BinaryProperties = ecma10BinaryProperties;\nvar ecma12BinaryProperties = ecma11BinaryProperties + \" EBase EComp EMod EPres ExtPict\";\nvar ecma13BinaryProperties = ecma12BinaryProperties;\nvar unicodeBinaryProperties = {\n 9: ecma9BinaryProperties,\n 10: ecma10BinaryProperties,\n 11: ecma11BinaryProperties,\n 12: ecma12BinaryProperties,\n 13: ecma13BinaryProperties\n};\n\n// #table-unicode-general-category-values\nvar unicodeGeneralCategoryValues = \"Cased_Letter LC Close_Punctuation Pe Connector_Punctuation Pc Control Cc cntrl Currency_Symbol Sc Dash_Punctuation Pd Decimal_Number Nd digit Enclosing_Mark Me Final_Punctuation Pf Format Cf Initial_Punctuation Pi Letter L Letter_Number Nl Line_Separator Zl Lowercase_Letter Ll Mark M Combining_Mark Math_Symbol Sm Modifier_Letter Lm Modifier_Symbol Sk Nonspacing_Mark Mn Number N Open_Punctuation Ps Other C Other_Letter Lo Other_Number No Other_Punctuation Po Other_Symbol So Paragraph_Separator Zp Private_Use Co Punctuation P punct Separator Z Space_Separator Zs Spacing_Mark Mc Surrogate Cs Symbol S Titlecase_Letter Lt Unassigned Cn Uppercase_Letter Lu\";\n\n// #table-unicode-script-values\nvar ecma9ScriptValues = \"Adlam Adlm Ahom Anatolian_Hieroglyphs Hluw Arabic Arab Armenian Armn Avestan Avst Balinese Bali Bamum Bamu Bassa_Vah Bass Batak Batk Bengali Beng Bhaiksuki Bhks Bopomofo Bopo Brahmi Brah Braille Brai Buginese Bugi Buhid Buhd Canadian_Aboriginal Cans Carian Cari Caucasian_Albanian Aghb Chakma Cakm Cham Cham Cherokee Cher Common Zyyy Coptic Copt Qaac Cuneiform Xsux Cypriot Cprt Cyrillic Cyrl Deseret Dsrt Devanagari Deva Duployan Dupl Egyptian_Hieroglyphs Egyp Elbasan Elba Ethiopic Ethi Georgian Geor Glagolitic Glag Gothic Goth Grantha Gran Greek Grek Gujarati Gujr Gurmukhi Guru Han Hani Hangul Hang Hanunoo Hano Hatran Hatr Hebrew Hebr Hiragana Hira Imperial_Aramaic Armi Inherited Zinh Qaai Inscriptional_Pahlavi Phli Inscriptional_Parthian Prti Javanese Java Kaithi Kthi Kannada Knda Katakana Kana Kayah_Li Kali Kharoshthi Khar Khmer Khmr Khojki Khoj Khudawadi Sind Lao Laoo Latin Latn Lepcha Lepc Limbu Limb Linear_A Lina Linear_B Linb Lisu Lisu Lycian Lyci Lydian Lydi Mahajani Mahj Malayalam Mlym Mandaic Mand Manichaean Mani Marchen Marc Masaram_Gondi Gonm Meetei_Mayek Mtei Mende_Kikakui Mend Meroitic_Cursive Merc Meroitic_Hieroglyphs Mero Miao Plrd Modi Mongolian Mong Mro Mroo Multani Mult Myanmar Mymr Nabataean Nbat New_Tai_Lue Talu Newa Newa Nko Nkoo Nushu Nshu Ogham Ogam Ol_Chiki Olck Old_Hungarian Hung Old_Italic Ital Old_North_Arabian Narb Old_Permic Perm Old_Persian Xpeo Old_South_Arabian Sarb Old_Turkic Orkh Oriya Orya Osage Osge Osmanya Osma Pahawh_Hmong Hmng Palmyrene Palm Pau_Cin_Hau Pauc Phags_Pa Phag Phoenician Phnx Psalter_Pahlavi Phlp Rejang Rjng Runic Runr Samaritan Samr Saurashtra Saur Sharada Shrd Shavian Shaw Siddham Sidd SignWriting Sgnw Sinhala Sinh Sora_Sompeng Sora Soyombo Soyo Sundanese Sund Syloti_Nagri Sylo Syriac Syrc Tagalog Tglg Tagbanwa Tagb Tai_Le Tale Tai_Tham Lana Tai_Viet Tavt Takri Takr Tamil Taml Tangut Tang Telugu Telu Thaana Thaa Thai Thai Tibetan Tibt Tifinagh Tfng Tirhuta Tirh Ugaritic Ugar Vai Vaii Warang_Citi Wara Yi Yiii Zanabazar_Square Zanb\";\nvar ecma10ScriptValues = ecma9ScriptValues + \" Dogra Dogr Gunjala_Gondi Gong Hanifi_Rohingya Rohg Makasar Maka Medefaidrin Medf Old_Sogdian Sogo Sogdian Sogd\";\nvar ecma11ScriptValues = ecma10ScriptValues + \" Elymaic Elym Nandinagari Nand Nyiakeng_Puachue_Hmong Hmnp Wancho Wcho\";\nvar ecma12ScriptValues = ecma11ScriptValues + \" Chorasmian Chrs Diak Dives_Akuru Khitan_Small_Script Kits Yezi Yezidi\";\nvar ecma13ScriptValues = ecma12ScriptValues + \" Cypro_Minoan Cpmn Old_Uyghur Ougr Tangsa Tnsa Toto Vithkuqi Vith\";\nvar unicodeScriptValues = {\n 9: ecma9ScriptValues,\n 10: ecma10ScriptValues,\n 11: ecma11ScriptValues,\n 12: ecma12ScriptValues,\n 13: ecma13ScriptValues\n};\n\nvar data = {};\nfunction buildUnicodeData(ecmaVersion) {\n var d = data[ecmaVersion] = {\n binary: wordsRegexp(unicodeBinaryProperties[ecmaVersion] + \" \" + unicodeGeneralCategoryValues),\n nonBinary: {\n General_Category: wordsRegexp(unicodeGeneralCategoryValues),\n Script: wordsRegexp(unicodeScriptValues[ecmaVersion])\n }\n };\n d.nonBinary.Script_Extensions = d.nonBinary.Script;\n\n d.nonBinary.gc = d.nonBinary.General_Category;\n d.nonBinary.sc = d.nonBinary.Script;\n d.nonBinary.scx = d.nonBinary.Script_Extensions;\n}\n\nfor (var i = 0, list = [9, 10, 11, 12, 13]; i < list.length; i += 1) {\n var ecmaVersion = list[i];\n\n buildUnicodeData(ecmaVersion);\n}\n\nvar pp$1 = Parser.prototype;\n\nvar RegExpValidationState = function RegExpValidationState(parser) {\n this.parser = parser;\n this.validFlags = \"gim\" + (parser.options.ecmaVersion >= 6 ? \"uy\" : \"\") + (parser.options.ecmaVersion >= 9 ? \"s\" : \"\") + (parser.options.ecmaVersion >= 13 ? \"d\" : \"\");\n this.unicodeProperties = data[parser.options.ecmaVersion >= 13 ? 13 : parser.options.ecmaVersion];\n this.source = \"\";\n this.flags = \"\";\n this.start = 0;\n this.switchU = false;\n this.switchN = false;\n this.pos = 0;\n this.lastIntValue = 0;\n this.lastStringValue = \"\";\n this.lastAssertionIsQuantifiable = false;\n this.numCapturingParens = 0;\n this.maxBackReference = 0;\n this.groupNames = [];\n this.backReferenceNames = [];\n};\n\nRegExpValidationState.prototype.reset = function reset (start, pattern, flags) {\n var unicode = flags.indexOf(\"u\") !== -1;\n this.start = start | 0;\n this.source = pattern + \"\";\n this.flags = flags;\n this.switchU = unicode && this.parser.options.ecmaVersion >= 6;\n this.switchN = unicode && this.parser.options.ecmaVersion >= 9;\n};\n\nRegExpValidationState.prototype.raise = function raise (message) {\n this.parser.raiseRecoverable(this.start, (\"Invalid regular expression: /\" + (this.source) + \"/: \" + message));\n};\n\n// If u flag is given, this returns the code point at the index (it combines a surrogate pair).\n// Otherwise, this returns the code unit of the index (can be a part of a surrogate pair).\nRegExpValidationState.prototype.at = function at (i, forceU) {\n if ( forceU === void 0 ) forceU = false;\n\n var s = this.source;\n var l = s.length;\n if (i >= l) {\n return -1\n }\n var c = s.charCodeAt(i);\n if (!(forceU || this.switchU) || c <= 0xD7FF || c >= 0xE000 || i + 1 >= l) {\n return c\n }\n var next = s.charCodeAt(i + 1);\n return next >= 0xDC00 && next <= 0xDFFF ? (c << 10) + next - 0x35FDC00 : c\n};\n\nRegExpValidationState.prototype.nextIndex = function nextIndex (i, forceU) {\n if ( forceU === void 0 ) forceU = false;\n\n var s = this.source;\n var l = s.length;\n if (i >= l) {\n return l\n }\n var c = s.charCodeAt(i), next;\n if (!(forceU || this.switchU) || c <= 0xD7FF || c >= 0xE000 || i + 1 >= l ||\n (next = s.charCodeAt(i + 1)) < 0xDC00 || next > 0xDFFF) {\n return i + 1\n }\n return i + 2\n};\n\nRegExpValidationState.prototype.current = function current (forceU) {\n if ( forceU === void 0 ) forceU = false;\n\n return this.at(this.pos, forceU)\n};\n\nRegExpValidationState.prototype.lookahead = function lookahead (forceU) {\n if ( forceU === void 0 ) forceU = false;\n\n return this.at(this.nextIndex(this.pos, forceU), forceU)\n};\n\nRegExpValidationState.prototype.advance = function advance (forceU) {\n if ( forceU === void 0 ) forceU = false;\n\n this.pos = this.nextIndex(this.pos, forceU);\n};\n\nRegExpValidationState.prototype.eat = function eat (ch, forceU) {\n if ( forceU === void 0 ) forceU = false;\n\n if (this.current(forceU) === ch) {\n this.advance(forceU);\n return true\n }\n return false\n};\n\n/**\n * Validate the flags part of a given RegExpLiteral.\n *\n * @param {RegExpValidationState} state The state to validate RegExp.\n * @returns {void}\n */\npp$1.validateRegExpFlags = function(state) {\n var validFlags = state.validFlags;\n var flags = state.flags;\n\n for (var i = 0; i < flags.length; i++) {\n var flag = flags.charAt(i);\n if (validFlags.indexOf(flag) === -1) {\n this.raise(state.start, \"Invalid regular expression flag\");\n }\n if (flags.indexOf(flag, i + 1) > -1) {\n this.raise(state.start, \"Duplicate regular expression flag\");\n }\n }\n};\n\n/**\n * Validate the pattern part of a given RegExpLiteral.\n *\n * @param {RegExpValidationState} state The state to validate RegExp.\n * @returns {void}\n */\npp$1.validateRegExpPattern = function(state) {\n this.regexp_pattern(state);\n\n // The goal symbol for the parse is |Pattern[~U, ~N]|. If the result of\n // parsing contains a |GroupName|, reparse with the goal symbol\n // |Pattern[~U, +N]| and use this result instead. Throw a *SyntaxError*\n // exception if _P_ did not conform to the grammar, if any elements of _P_\n // were not matched by the parse, or if any Early Error conditions exist.\n if (!state.switchN && this.options.ecmaVersion >= 9 && state.groupNames.length > 0) {\n state.switchN = true;\n this.regexp_pattern(state);\n }\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-Pattern\npp$1.regexp_pattern = function(state) {\n state.pos = 0;\n state.lastIntValue = 0;\n state.lastStringValue = \"\";\n state.lastAssertionIsQuantifiable = false;\n state.numCapturingParens = 0;\n state.maxBackReference = 0;\n state.groupNames.length = 0;\n state.backReferenceNames.length = 0;\n\n this.regexp_disjunction(state);\n\n if (state.pos !== state.source.length) {\n // Make the same messages as V8.\n if (state.eat(0x29 /* ) */)) {\n state.raise(\"Unmatched ')'\");\n }\n if (state.eat(0x5D /* ] */) || state.eat(0x7D /* } */)) {\n state.raise(\"Lone quantifier brackets\");\n }\n }\n if (state.maxBackReference > state.numCapturingParens) {\n state.raise(\"Invalid escape\");\n }\n for (var i = 0, list = state.backReferenceNames; i < list.length; i += 1) {\n var name = list[i];\n\n if (state.groupNames.indexOf(name) === -1) {\n state.raise(\"Invalid named capture referenced\");\n }\n }\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-Disjunction\npp$1.regexp_disjunction = function(state) {\n this.regexp_alternative(state);\n while (state.eat(0x7C /* | */)) {\n this.regexp_alternative(state);\n }\n\n // Make the same message as V8.\n if (this.regexp_eatQuantifier(state, true)) {\n state.raise(\"Nothing to repeat\");\n }\n if (state.eat(0x7B /* { */)) {\n state.raise(\"Lone quantifier brackets\");\n }\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-Alternative\npp$1.regexp_alternative = function(state) {\n while (state.pos < state.source.length && this.regexp_eatTerm(state))\n { }\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-Term\npp$1.regexp_eatTerm = function(state) {\n if (this.regexp_eatAssertion(state)) {\n // Handle `QuantifiableAssertion Quantifier` alternative.\n // `state.lastAssertionIsQuantifiable` is true if the last eaten Assertion\n // is a QuantifiableAssertion.\n if (state.lastAssertionIsQuantifiable && this.regexp_eatQuantifier(state)) {\n // Make the same message as V8.\n if (state.switchU) {\n state.raise(\"Invalid quantifier\");\n }\n }\n return true\n }\n\n if (state.switchU ? this.regexp_eatAtom(state) : this.regexp_eatExtendedAtom(state)) {\n this.regexp_eatQuantifier(state);\n return true\n }\n\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-Assertion\npp$1.regexp_eatAssertion = function(state) {\n var start = state.pos;\n state.lastAssertionIsQuantifiable = false;\n\n // ^, $\n if (state.eat(0x5E /* ^ */) || state.eat(0x24 /* $ */)) {\n return true\n }\n\n // \\b \\B\n if (state.eat(0x5C /* \\ */)) {\n if (state.eat(0x42 /* B */) || state.eat(0x62 /* b */)) {\n return true\n }\n state.pos = start;\n }\n\n // Lookahead / Lookbehind\n if (state.eat(0x28 /* ( */) && state.eat(0x3F /* ? */)) {\n var lookbehind = false;\n if (this.options.ecmaVersion >= 9) {\n lookbehind = state.eat(0x3C /* < */);\n }\n if (state.eat(0x3D /* = */) || state.eat(0x21 /* ! */)) {\n this.regexp_disjunction(state);\n if (!state.eat(0x29 /* ) */)) {\n state.raise(\"Unterminated group\");\n }\n state.lastAssertionIsQuantifiable = !lookbehind;\n return true\n }\n }\n\n state.pos = start;\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-Quantifier\npp$1.regexp_eatQuantifier = function(state, noError) {\n if ( noError === void 0 ) noError = false;\n\n if (this.regexp_eatQuantifierPrefix(state, noError)) {\n state.eat(0x3F /* ? */);\n return true\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-QuantifierPrefix\npp$1.regexp_eatQuantifierPrefix = function(state, noError) {\n return (\n state.eat(0x2A /* * */) ||\n state.eat(0x2B /* + */) ||\n state.eat(0x3F /* ? */) ||\n this.regexp_eatBracedQuantifier(state, noError)\n )\n};\npp$1.regexp_eatBracedQuantifier = function(state, noError) {\n var start = state.pos;\n if (state.eat(0x7B /* { */)) {\n var min = 0, max = -1;\n if (this.regexp_eatDecimalDigits(state)) {\n min = state.lastIntValue;\n if (state.eat(0x2C /* , */) && this.regexp_eatDecimalDigits(state)) {\n max = state.lastIntValue;\n }\n if (state.eat(0x7D /* } */)) {\n // SyntaxError in https://www.ecma-international.org/ecma-262/8.0/#sec-term\n if (max !== -1 && max < min && !noError) {\n state.raise(\"numbers out of order in {} quantifier\");\n }\n return true\n }\n }\n if (state.switchU && !noError) {\n state.raise(\"Incomplete quantifier\");\n }\n state.pos = start;\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-Atom\npp$1.regexp_eatAtom = function(state) {\n return (\n this.regexp_eatPatternCharacters(state) ||\n state.eat(0x2E /* . */) ||\n this.regexp_eatReverseSolidusAtomEscape(state) ||\n this.regexp_eatCharacterClass(state) ||\n this.regexp_eatUncapturingGroup(state) ||\n this.regexp_eatCapturingGroup(state)\n )\n};\npp$1.regexp_eatReverseSolidusAtomEscape = function(state) {\n var start = state.pos;\n if (state.eat(0x5C /* \\ */)) {\n if (this.regexp_eatAtomEscape(state)) {\n return true\n }\n state.pos = start;\n }\n return false\n};\npp$1.regexp_eatUncapturingGroup = function(state) {\n var start = state.pos;\n if (state.eat(0x28 /* ( */)) {\n if (state.eat(0x3F /* ? */) && state.eat(0x3A /* : */)) {\n this.regexp_disjunction(state);\n if (state.eat(0x29 /* ) */)) {\n return true\n }\n state.raise(\"Unterminated group\");\n }\n state.pos = start;\n }\n return false\n};\npp$1.regexp_eatCapturingGroup = function(state) {\n if (state.eat(0x28 /* ( */)) {\n if (this.options.ecmaVersion >= 9) {\n this.regexp_groupSpecifier(state);\n } else if (state.current() === 0x3F /* ? */) {\n state.raise(\"Invalid group\");\n }\n this.regexp_disjunction(state);\n if (state.eat(0x29 /* ) */)) {\n state.numCapturingParens += 1;\n return true\n }\n state.raise(\"Unterminated group\");\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-ExtendedAtom\npp$1.regexp_eatExtendedAtom = function(state) {\n return (\n state.eat(0x2E /* . */) ||\n this.regexp_eatReverseSolidusAtomEscape(state) ||\n this.regexp_eatCharacterClass(state) ||\n this.regexp_eatUncapturingGroup(state) ||\n this.regexp_eatCapturingGroup(state) ||\n this.regexp_eatInvalidBracedQuantifier(state) ||\n this.regexp_eatExtendedPatternCharacter(state)\n )\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-InvalidBracedQuantifier\npp$1.regexp_eatInvalidBracedQuantifier = function(state) {\n if (this.regexp_eatBracedQuantifier(state, true)) {\n state.raise(\"Nothing to repeat\");\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-SyntaxCharacter\npp$1.regexp_eatSyntaxCharacter = function(state) {\n var ch = state.current();\n if (isSyntaxCharacter(ch)) {\n state.lastIntValue = ch;\n state.advance();\n return true\n }\n return false\n};\nfunction isSyntaxCharacter(ch) {\n return (\n ch === 0x24 /* $ */ ||\n ch >= 0x28 /* ( */ && ch <= 0x2B /* + */ ||\n ch === 0x2E /* . */ ||\n ch === 0x3F /* ? */ ||\n ch >= 0x5B /* [ */ && ch <= 0x5E /* ^ */ ||\n ch >= 0x7B /* { */ && ch <= 0x7D /* } */\n )\n}\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-PatternCharacter\n// But eat eager.\npp$1.regexp_eatPatternCharacters = function(state) {\n var start = state.pos;\n var ch = 0;\n while ((ch = state.current()) !== -1 && !isSyntaxCharacter(ch)) {\n state.advance();\n }\n return state.pos !== start\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-ExtendedPatternCharacter\npp$1.regexp_eatExtendedPatternCharacter = function(state) {\n var ch = state.current();\n if (\n ch !== -1 &&\n ch !== 0x24 /* $ */ &&\n !(ch >= 0x28 /* ( */ && ch <= 0x2B /* + */) &&\n ch !== 0x2E /* . */ &&\n ch !== 0x3F /* ? */ &&\n ch !== 0x5B /* [ */ &&\n ch !== 0x5E /* ^ */ &&\n ch !== 0x7C /* | */\n ) {\n state.advance();\n return true\n }\n return false\n};\n\n// GroupSpecifier ::\n// [empty]\n// `?` GroupName\npp$1.regexp_groupSpecifier = function(state) {\n if (state.eat(0x3F /* ? */)) {\n if (this.regexp_eatGroupName(state)) {\n if (state.groupNames.indexOf(state.lastStringValue) !== -1) {\n state.raise(\"Duplicate capture group name\");\n }\n state.groupNames.push(state.lastStringValue);\n return\n }\n state.raise(\"Invalid group\");\n }\n};\n\n// GroupName ::\n// `<` RegExpIdentifierName `>`\n// Note: this updates `state.lastStringValue` property with the eaten name.\npp$1.regexp_eatGroupName = function(state) {\n state.lastStringValue = \"\";\n if (state.eat(0x3C /* < */)) {\n if (this.regexp_eatRegExpIdentifierName(state) && state.eat(0x3E /* > */)) {\n return true\n }\n state.raise(\"Invalid capture group name\");\n }\n return false\n};\n\n// RegExpIdentifierName ::\n// RegExpIdentifierStart\n// RegExpIdentifierName RegExpIdentifierPart\n// Note: this updates `state.lastStringValue` property with the eaten name.\npp$1.regexp_eatRegExpIdentifierName = function(state) {\n state.lastStringValue = \"\";\n if (this.regexp_eatRegExpIdentifierStart(state)) {\n state.lastStringValue += codePointToString(state.lastIntValue);\n while (this.regexp_eatRegExpIdentifierPart(state)) {\n state.lastStringValue += codePointToString(state.lastIntValue);\n }\n return true\n }\n return false\n};\n\n// RegExpIdentifierStart ::\n// UnicodeIDStart\n// `$`\n// `_`\n// `\\` RegExpUnicodeEscapeSequence[+U]\npp$1.regexp_eatRegExpIdentifierStart = function(state) {\n var start = state.pos;\n var forceU = this.options.ecmaVersion >= 11;\n var ch = state.current(forceU);\n state.advance(forceU);\n\n if (ch === 0x5C /* \\ */ && this.regexp_eatRegExpUnicodeEscapeSequence(state, forceU)) {\n ch = state.lastIntValue;\n }\n if (isRegExpIdentifierStart(ch)) {\n state.lastIntValue = ch;\n return true\n }\n\n state.pos = start;\n return false\n};\nfunction isRegExpIdentifierStart(ch) {\n return isIdentifierStart(ch, true) || ch === 0x24 /* $ */ || ch === 0x5F /* _ */\n}\n\n// RegExpIdentifierPart ::\n// UnicodeIDContinue\n// `$`\n// `_`\n// `\\` RegExpUnicodeEscapeSequence[+U]\n// \n// \npp$1.regexp_eatRegExpIdentifierPart = function(state) {\n var start = state.pos;\n var forceU = this.options.ecmaVersion >= 11;\n var ch = state.current(forceU);\n state.advance(forceU);\n\n if (ch === 0x5C /* \\ */ && this.regexp_eatRegExpUnicodeEscapeSequence(state, forceU)) {\n ch = state.lastIntValue;\n }\n if (isRegExpIdentifierPart(ch)) {\n state.lastIntValue = ch;\n return true\n }\n\n state.pos = start;\n return false\n};\nfunction isRegExpIdentifierPart(ch) {\n return isIdentifierChar(ch, true) || ch === 0x24 /* $ */ || ch === 0x5F /* _ */ || ch === 0x200C /* */ || ch === 0x200D /* */\n}\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-AtomEscape\npp$1.regexp_eatAtomEscape = function(state) {\n if (\n this.regexp_eatBackReference(state) ||\n this.regexp_eatCharacterClassEscape(state) ||\n this.regexp_eatCharacterEscape(state) ||\n (state.switchN && this.regexp_eatKGroupName(state))\n ) {\n return true\n }\n if (state.switchU) {\n // Make the same message as V8.\n if (state.current() === 0x63 /* c */) {\n state.raise(\"Invalid unicode escape\");\n }\n state.raise(\"Invalid escape\");\n }\n return false\n};\npp$1.regexp_eatBackReference = function(state) {\n var start = state.pos;\n if (this.regexp_eatDecimalEscape(state)) {\n var n = state.lastIntValue;\n if (state.switchU) {\n // For SyntaxError in https://www.ecma-international.org/ecma-262/8.0/#sec-atomescape\n if (n > state.maxBackReference) {\n state.maxBackReference = n;\n }\n return true\n }\n if (n <= state.numCapturingParens) {\n return true\n }\n state.pos = start;\n }\n return false\n};\npp$1.regexp_eatKGroupName = function(state) {\n if (state.eat(0x6B /* k */)) {\n if (this.regexp_eatGroupName(state)) {\n state.backReferenceNames.push(state.lastStringValue);\n return true\n }\n state.raise(\"Invalid named reference\");\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-CharacterEscape\npp$1.regexp_eatCharacterEscape = function(state) {\n return (\n this.regexp_eatControlEscape(state) ||\n this.regexp_eatCControlLetter(state) ||\n this.regexp_eatZero(state) ||\n this.regexp_eatHexEscapeSequence(state) ||\n this.regexp_eatRegExpUnicodeEscapeSequence(state, false) ||\n (!state.switchU && this.regexp_eatLegacyOctalEscapeSequence(state)) ||\n this.regexp_eatIdentityEscape(state)\n )\n};\npp$1.regexp_eatCControlLetter = function(state) {\n var start = state.pos;\n if (state.eat(0x63 /* c */)) {\n if (this.regexp_eatControlLetter(state)) {\n return true\n }\n state.pos = start;\n }\n return false\n};\npp$1.regexp_eatZero = function(state) {\n if (state.current() === 0x30 /* 0 */ && !isDecimalDigit(state.lookahead())) {\n state.lastIntValue = 0;\n state.advance();\n return true\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-ControlEscape\npp$1.regexp_eatControlEscape = function(state) {\n var ch = state.current();\n if (ch === 0x74 /* t */) {\n state.lastIntValue = 0x09; /* \\t */\n state.advance();\n return true\n }\n if (ch === 0x6E /* n */) {\n state.lastIntValue = 0x0A; /* \\n */\n state.advance();\n return true\n }\n if (ch === 0x76 /* v */) {\n state.lastIntValue = 0x0B; /* \\v */\n state.advance();\n return true\n }\n if (ch === 0x66 /* f */) {\n state.lastIntValue = 0x0C; /* \\f */\n state.advance();\n return true\n }\n if (ch === 0x72 /* r */) {\n state.lastIntValue = 0x0D; /* \\r */\n state.advance();\n return true\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-ControlLetter\npp$1.regexp_eatControlLetter = function(state) {\n var ch = state.current();\n if (isControlLetter(ch)) {\n state.lastIntValue = ch % 0x20;\n state.advance();\n return true\n }\n return false\n};\nfunction isControlLetter(ch) {\n return (\n (ch >= 0x41 /* A */ && ch <= 0x5A /* Z */) ||\n (ch >= 0x61 /* a */ && ch <= 0x7A /* z */)\n )\n}\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-RegExpUnicodeEscapeSequence\npp$1.regexp_eatRegExpUnicodeEscapeSequence = function(state, forceU) {\n if ( forceU === void 0 ) forceU = false;\n\n var start = state.pos;\n var switchU = forceU || state.switchU;\n\n if (state.eat(0x75 /* u */)) {\n if (this.regexp_eatFixedHexDigits(state, 4)) {\n var lead = state.lastIntValue;\n if (switchU && lead >= 0xD800 && lead <= 0xDBFF) {\n var leadSurrogateEnd = state.pos;\n if (state.eat(0x5C /* \\ */) && state.eat(0x75 /* u */) && this.regexp_eatFixedHexDigits(state, 4)) {\n var trail = state.lastIntValue;\n if (trail >= 0xDC00 && trail <= 0xDFFF) {\n state.lastIntValue = (lead - 0xD800) * 0x400 + (trail - 0xDC00) + 0x10000;\n return true\n }\n }\n state.pos = leadSurrogateEnd;\n state.lastIntValue = lead;\n }\n return true\n }\n if (\n switchU &&\n state.eat(0x7B /* { */) &&\n this.regexp_eatHexDigits(state) &&\n state.eat(0x7D /* } */) &&\n isValidUnicode(state.lastIntValue)\n ) {\n return true\n }\n if (switchU) {\n state.raise(\"Invalid unicode escape\");\n }\n state.pos = start;\n }\n\n return false\n};\nfunction isValidUnicode(ch) {\n return ch >= 0 && ch <= 0x10FFFF\n}\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-IdentityEscape\npp$1.regexp_eatIdentityEscape = function(state) {\n if (state.switchU) {\n if (this.regexp_eatSyntaxCharacter(state)) {\n return true\n }\n if (state.eat(0x2F /* / */)) {\n state.lastIntValue = 0x2F; /* / */\n return true\n }\n return false\n }\n\n var ch = state.current();\n if (ch !== 0x63 /* c */ && (!state.switchN || ch !== 0x6B /* k */)) {\n state.lastIntValue = ch;\n state.advance();\n return true\n }\n\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-DecimalEscape\npp$1.regexp_eatDecimalEscape = function(state) {\n state.lastIntValue = 0;\n var ch = state.current();\n if (ch >= 0x31 /* 1 */ && ch <= 0x39 /* 9 */) {\n do {\n state.lastIntValue = 10 * state.lastIntValue + (ch - 0x30 /* 0 */);\n state.advance();\n } while ((ch = state.current()) >= 0x30 /* 0 */ && ch <= 0x39 /* 9 */)\n return true\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-CharacterClassEscape\npp$1.regexp_eatCharacterClassEscape = function(state) {\n var ch = state.current();\n\n if (isCharacterClassEscape(ch)) {\n state.lastIntValue = -1;\n state.advance();\n return true\n }\n\n if (\n state.switchU &&\n this.options.ecmaVersion >= 9 &&\n (ch === 0x50 /* P */ || ch === 0x70 /* p */)\n ) {\n state.lastIntValue = -1;\n state.advance();\n if (\n state.eat(0x7B /* { */) &&\n this.regexp_eatUnicodePropertyValueExpression(state) &&\n state.eat(0x7D /* } */)\n ) {\n return true\n }\n state.raise(\"Invalid property name\");\n }\n\n return false\n};\nfunction isCharacterClassEscape(ch) {\n return (\n ch === 0x64 /* d */ ||\n ch === 0x44 /* D */ ||\n ch === 0x73 /* s */ ||\n ch === 0x53 /* S */ ||\n ch === 0x77 /* w */ ||\n ch === 0x57 /* W */\n )\n}\n\n// UnicodePropertyValueExpression ::\n// UnicodePropertyName `=` UnicodePropertyValue\n// LoneUnicodePropertyNameOrValue\npp$1.regexp_eatUnicodePropertyValueExpression = function(state) {\n var start = state.pos;\n\n // UnicodePropertyName `=` UnicodePropertyValue\n if (this.regexp_eatUnicodePropertyName(state) && state.eat(0x3D /* = */)) {\n var name = state.lastStringValue;\n if (this.regexp_eatUnicodePropertyValue(state)) {\n var value = state.lastStringValue;\n this.regexp_validateUnicodePropertyNameAndValue(state, name, value);\n return true\n }\n }\n state.pos = start;\n\n // LoneUnicodePropertyNameOrValue\n if (this.regexp_eatLoneUnicodePropertyNameOrValue(state)) {\n var nameOrValue = state.lastStringValue;\n this.regexp_validateUnicodePropertyNameOrValue(state, nameOrValue);\n return true\n }\n return false\n};\npp$1.regexp_validateUnicodePropertyNameAndValue = function(state, name, value) {\n if (!hasOwn(state.unicodeProperties.nonBinary, name))\n { state.raise(\"Invalid property name\"); }\n if (!state.unicodeProperties.nonBinary[name].test(value))\n { state.raise(\"Invalid property value\"); }\n};\npp$1.regexp_validateUnicodePropertyNameOrValue = function(state, nameOrValue) {\n if (!state.unicodeProperties.binary.test(nameOrValue))\n { state.raise(\"Invalid property name\"); }\n};\n\n// UnicodePropertyName ::\n// UnicodePropertyNameCharacters\npp$1.regexp_eatUnicodePropertyName = function(state) {\n var ch = 0;\n state.lastStringValue = \"\";\n while (isUnicodePropertyNameCharacter(ch = state.current())) {\n state.lastStringValue += codePointToString(ch);\n state.advance();\n }\n return state.lastStringValue !== \"\"\n};\nfunction isUnicodePropertyNameCharacter(ch) {\n return isControlLetter(ch) || ch === 0x5F /* _ */\n}\n\n// UnicodePropertyValue ::\n// UnicodePropertyValueCharacters\npp$1.regexp_eatUnicodePropertyValue = function(state) {\n var ch = 0;\n state.lastStringValue = \"\";\n while (isUnicodePropertyValueCharacter(ch = state.current())) {\n state.lastStringValue += codePointToString(ch);\n state.advance();\n }\n return state.lastStringValue !== \"\"\n};\nfunction isUnicodePropertyValueCharacter(ch) {\n return isUnicodePropertyNameCharacter(ch) || isDecimalDigit(ch)\n}\n\n// LoneUnicodePropertyNameOrValue ::\n// UnicodePropertyValueCharacters\npp$1.regexp_eatLoneUnicodePropertyNameOrValue = function(state) {\n return this.regexp_eatUnicodePropertyValue(state)\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-CharacterClass\npp$1.regexp_eatCharacterClass = function(state) {\n if (state.eat(0x5B /* [ */)) {\n state.eat(0x5E /* ^ */);\n this.regexp_classRanges(state);\n if (state.eat(0x5D /* ] */)) {\n return true\n }\n // Unreachable since it threw \"unterminated regular expression\" error before.\n state.raise(\"Unterminated character class\");\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-ClassRanges\n// https://www.ecma-international.org/ecma-262/8.0/#prod-NonemptyClassRanges\n// https://www.ecma-international.org/ecma-262/8.0/#prod-NonemptyClassRangesNoDash\npp$1.regexp_classRanges = function(state) {\n while (this.regexp_eatClassAtom(state)) {\n var left = state.lastIntValue;\n if (state.eat(0x2D /* - */) && this.regexp_eatClassAtom(state)) {\n var right = state.lastIntValue;\n if (state.switchU && (left === -1 || right === -1)) {\n state.raise(\"Invalid character class\");\n }\n if (left !== -1 && right !== -1 && left > right) {\n state.raise(\"Range out of order in character class\");\n }\n }\n }\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-ClassAtom\n// https://www.ecma-international.org/ecma-262/8.0/#prod-ClassAtomNoDash\npp$1.regexp_eatClassAtom = function(state) {\n var start = state.pos;\n\n if (state.eat(0x5C /* \\ */)) {\n if (this.regexp_eatClassEscape(state)) {\n return true\n }\n if (state.switchU) {\n // Make the same message as V8.\n var ch$1 = state.current();\n if (ch$1 === 0x63 /* c */ || isOctalDigit(ch$1)) {\n state.raise(\"Invalid class escape\");\n }\n state.raise(\"Invalid escape\");\n }\n state.pos = start;\n }\n\n var ch = state.current();\n if (ch !== 0x5D /* ] */) {\n state.lastIntValue = ch;\n state.advance();\n return true\n }\n\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-ClassEscape\npp$1.regexp_eatClassEscape = function(state) {\n var start = state.pos;\n\n if (state.eat(0x62 /* b */)) {\n state.lastIntValue = 0x08; /* */\n return true\n }\n\n if (state.switchU && state.eat(0x2D /* - */)) {\n state.lastIntValue = 0x2D; /* - */\n return true\n }\n\n if (!state.switchU && state.eat(0x63 /* c */)) {\n if (this.regexp_eatClassControlLetter(state)) {\n return true\n }\n state.pos = start;\n }\n\n return (\n this.regexp_eatCharacterClassEscape(state) ||\n this.regexp_eatCharacterEscape(state)\n )\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-ClassControlLetter\npp$1.regexp_eatClassControlLetter = function(state) {\n var ch = state.current();\n if (isDecimalDigit(ch) || ch === 0x5F /* _ */) {\n state.lastIntValue = ch % 0x20;\n state.advance();\n return true\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-HexEscapeSequence\npp$1.regexp_eatHexEscapeSequence = function(state) {\n var start = state.pos;\n if (state.eat(0x78 /* x */)) {\n if (this.regexp_eatFixedHexDigits(state, 2)) {\n return true\n }\n if (state.switchU) {\n state.raise(\"Invalid escape\");\n }\n state.pos = start;\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-DecimalDigits\npp$1.regexp_eatDecimalDigits = function(state) {\n var start = state.pos;\n var ch = 0;\n state.lastIntValue = 0;\n while (isDecimalDigit(ch = state.current())) {\n state.lastIntValue = 10 * state.lastIntValue + (ch - 0x30 /* 0 */);\n state.advance();\n }\n return state.pos !== start\n};\nfunction isDecimalDigit(ch) {\n return ch >= 0x30 /* 0 */ && ch <= 0x39 /* 9 */\n}\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-HexDigits\npp$1.regexp_eatHexDigits = function(state) {\n var start = state.pos;\n var ch = 0;\n state.lastIntValue = 0;\n while (isHexDigit(ch = state.current())) {\n state.lastIntValue = 16 * state.lastIntValue + hexToInt(ch);\n state.advance();\n }\n return state.pos !== start\n};\nfunction isHexDigit(ch) {\n return (\n (ch >= 0x30 /* 0 */ && ch <= 0x39 /* 9 */) ||\n (ch >= 0x41 /* A */ && ch <= 0x46 /* F */) ||\n (ch >= 0x61 /* a */ && ch <= 0x66 /* f */)\n )\n}\nfunction hexToInt(ch) {\n if (ch >= 0x41 /* A */ && ch <= 0x46 /* F */) {\n return 10 + (ch - 0x41 /* A */)\n }\n if (ch >= 0x61 /* a */ && ch <= 0x66 /* f */) {\n return 10 + (ch - 0x61 /* a */)\n }\n return ch - 0x30 /* 0 */\n}\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-LegacyOctalEscapeSequence\n// Allows only 0-377(octal) i.e. 0-255(decimal).\npp$1.regexp_eatLegacyOctalEscapeSequence = function(state) {\n if (this.regexp_eatOctalDigit(state)) {\n var n1 = state.lastIntValue;\n if (this.regexp_eatOctalDigit(state)) {\n var n2 = state.lastIntValue;\n if (n1 <= 3 && this.regexp_eatOctalDigit(state)) {\n state.lastIntValue = n1 * 64 + n2 * 8 + state.lastIntValue;\n } else {\n state.lastIntValue = n1 * 8 + n2;\n }\n } else {\n state.lastIntValue = n1;\n }\n return true\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-OctalDigit\npp$1.regexp_eatOctalDigit = function(state) {\n var ch = state.current();\n if (isOctalDigit(ch)) {\n state.lastIntValue = ch - 0x30; /* 0 */\n state.advance();\n return true\n }\n state.lastIntValue = 0;\n return false\n};\nfunction isOctalDigit(ch) {\n return ch >= 0x30 /* 0 */ && ch <= 0x37 /* 7 */\n}\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-Hex4Digits\n// https://www.ecma-international.org/ecma-262/8.0/#prod-HexDigit\n// And HexDigit HexDigit in https://www.ecma-international.org/ecma-262/8.0/#prod-HexEscapeSequence\npp$1.regexp_eatFixedHexDigits = function(state, length) {\n var start = state.pos;\n state.lastIntValue = 0;\n for (var i = 0; i < length; ++i) {\n var ch = state.current();\n if (!isHexDigit(ch)) {\n state.pos = start;\n return false\n }\n state.lastIntValue = 16 * state.lastIntValue + hexToInt(ch);\n state.advance();\n }\n return true\n};\n\n// Object type used to represent tokens. Note that normally, tokens\n// simply exist as properties on the parser object. This is only\n// used for the onToken callback and the external tokenizer.\n\nvar Token = function Token(p) {\n this.type = p.type;\n this.value = p.value;\n this.start = p.start;\n this.end = p.end;\n if (p.options.locations)\n { this.loc = new SourceLocation(p, p.startLoc, p.endLoc); }\n if (p.options.ranges)\n { this.range = [p.start, p.end]; }\n};\n\n// ## Tokenizer\n\nvar pp = Parser.prototype;\n\n// Move to the next token\n\npp.next = function(ignoreEscapeSequenceInKeyword) {\n if (!ignoreEscapeSequenceInKeyword && this.type.keyword && this.containsEsc)\n { this.raiseRecoverable(this.start, \"Escape sequence in keyword \" + this.type.keyword); }\n if (this.options.onToken)\n { this.options.onToken(new Token(this)); }\n\n this.lastTokEnd = this.end;\n this.lastTokStart = this.start;\n this.lastTokEndLoc = this.endLoc;\n this.lastTokStartLoc = this.startLoc;\n this.nextToken();\n};\n\npp.getToken = function() {\n this.next();\n return new Token(this)\n};\n\n// If we're in an ES6 environment, make parsers iterable\nif (typeof Symbol !== \"undefined\")\n { pp[Symbol.iterator] = function() {\n var this$1$1 = this;\n\n return {\n next: function () {\n var token = this$1$1.getToken();\n return {\n done: token.type === types$1.eof,\n value: token\n }\n }\n }\n }; }\n\n// Toggle strict mode. Re-reads the next number or string to please\n// pedantic tests (`\"use strict\"; 010;` should fail).\n\n// Read a single token, updating the parser object's token-related\n// properties.\n\npp.nextToken = function() {\n var curContext = this.curContext();\n if (!curContext || !curContext.preserveSpace) { this.skipSpace(); }\n\n this.start = this.pos;\n if (this.options.locations) { this.startLoc = this.curPosition(); }\n if (this.pos >= this.input.length) { return this.finishToken(types$1.eof) }\n\n if (curContext.override) { return curContext.override(this) }\n else { this.readToken(this.fullCharCodeAtPos()); }\n};\n\npp.readToken = function(code) {\n // Identifier or keyword. '\\uXXXX' sequences are allowed in\n // identifiers, so '\\' also dispatches to that.\n if (isIdentifierStart(code, this.options.ecmaVersion >= 6) || code === 92 /* '\\' */)\n { return this.readWord() }\n\n return this.getTokenFromCode(code)\n};\n\npp.fullCharCodeAtPos = function() {\n var code = this.input.charCodeAt(this.pos);\n if (code <= 0xd7ff || code >= 0xdc00) { return code }\n var next = this.input.charCodeAt(this.pos + 1);\n return next <= 0xdbff || next >= 0xe000 ? code : (code << 10) + next - 0x35fdc00\n};\n\npp.skipBlockComment = function() {\n var startLoc = this.options.onComment && this.curPosition();\n var start = this.pos, end = this.input.indexOf(\"*/\", this.pos += 2);\n if (end === -1) { this.raise(this.pos - 2, \"Unterminated comment\"); }\n this.pos = end + 2;\n if (this.options.locations) {\n for (var nextBreak = (void 0), pos = start; (nextBreak = nextLineBreak(this.input, pos, this.pos)) > -1;) {\n ++this.curLine;\n pos = this.lineStart = nextBreak;\n }\n }\n if (this.options.onComment)\n { this.options.onComment(true, this.input.slice(start + 2, end), start, this.pos,\n startLoc, this.curPosition()); }\n};\n\npp.skipLineComment = function(startSkip) {\n var start = this.pos;\n var startLoc = this.options.onComment && this.curPosition();\n var ch = this.input.charCodeAt(this.pos += startSkip);\n while (this.pos < this.input.length && !isNewLine(ch)) {\n ch = this.input.charCodeAt(++this.pos);\n }\n if (this.options.onComment)\n { this.options.onComment(false, this.input.slice(start + startSkip, this.pos), start, this.pos,\n startLoc, this.curPosition()); }\n};\n\n// Called at the start of the parse and after every token. Skips\n// whitespace and comments, and.\n\npp.skipSpace = function() {\n loop: while (this.pos < this.input.length) {\n var ch = this.input.charCodeAt(this.pos);\n switch (ch) {\n case 32: case 160: // ' '\n ++this.pos;\n break\n case 13:\n if (this.input.charCodeAt(this.pos + 1) === 10) {\n ++this.pos;\n }\n case 10: case 8232: case 8233:\n ++this.pos;\n if (this.options.locations) {\n ++this.curLine;\n this.lineStart = this.pos;\n }\n break\n case 47: // '/'\n switch (this.input.charCodeAt(this.pos + 1)) {\n case 42: // '*'\n this.skipBlockComment();\n break\n case 47:\n this.skipLineComment(2);\n break\n default:\n break loop\n }\n break\n default:\n if (ch > 8 && ch < 14 || ch >= 5760 && nonASCIIwhitespace.test(String.fromCharCode(ch))) {\n ++this.pos;\n } else {\n break loop\n }\n }\n }\n};\n\n// Called at the end of every token. Sets `end`, `val`, and\n// maintains `context` and `exprAllowed`, and skips the space after\n// the token, so that the next one's `start` will point at the\n// right position.\n\npp.finishToken = function(type, val) {\n this.end = this.pos;\n if (this.options.locations) { this.endLoc = this.curPosition(); }\n var prevType = this.type;\n this.type = type;\n this.value = val;\n\n this.updateContext(prevType);\n};\n\n// ### Token reading\n\n// This is the function that is called to fetch the next token. It\n// is somewhat obscure, because it works in character codes rather\n// than characters, and because operator parsing has been inlined\n// into it.\n//\n// All in the name of speed.\n//\npp.readToken_dot = function() {\n var next = this.input.charCodeAt(this.pos + 1);\n if (next >= 48 && next <= 57) { return this.readNumber(true) }\n var next2 = this.input.charCodeAt(this.pos + 2);\n if (this.options.ecmaVersion >= 6 && next === 46 && next2 === 46) { // 46 = dot '.'\n this.pos += 3;\n return this.finishToken(types$1.ellipsis)\n } else {\n ++this.pos;\n return this.finishToken(types$1.dot)\n }\n};\n\npp.readToken_slash = function() { // '/'\n var next = this.input.charCodeAt(this.pos + 1);\n if (this.exprAllowed) { ++this.pos; return this.readRegexp() }\n if (next === 61) { return this.finishOp(types$1.assign, 2) }\n return this.finishOp(types$1.slash, 1)\n};\n\npp.readToken_mult_modulo_exp = function(code) { // '%*'\n var next = this.input.charCodeAt(this.pos + 1);\n var size = 1;\n var tokentype = code === 42 ? types$1.star : types$1.modulo;\n\n // exponentiation operator ** and **=\n if (this.options.ecmaVersion >= 7 && code === 42 && next === 42) {\n ++size;\n tokentype = types$1.starstar;\n next = this.input.charCodeAt(this.pos + 2);\n }\n\n if (next === 61) { return this.finishOp(types$1.assign, size + 1) }\n return this.finishOp(tokentype, size)\n};\n\npp.readToken_pipe_amp = function(code) { // '|&'\n var next = this.input.charCodeAt(this.pos + 1);\n if (next === code) {\n if (this.options.ecmaVersion >= 12) {\n var next2 = this.input.charCodeAt(this.pos + 2);\n if (next2 === 61) { return this.finishOp(types$1.assign, 3) }\n }\n return this.finishOp(code === 124 ? types$1.logicalOR : types$1.logicalAND, 2)\n }\n if (next === 61) { return this.finishOp(types$1.assign, 2) }\n return this.finishOp(code === 124 ? types$1.bitwiseOR : types$1.bitwiseAND, 1)\n};\n\npp.readToken_caret = function() { // '^'\n var next = this.input.charCodeAt(this.pos + 1);\n if (next === 61) { return this.finishOp(types$1.assign, 2) }\n return this.finishOp(types$1.bitwiseXOR, 1)\n};\n\npp.readToken_plus_min = function(code) { // '+-'\n var next = this.input.charCodeAt(this.pos + 1);\n if (next === code) {\n if (next === 45 && !this.inModule && this.input.charCodeAt(this.pos + 2) === 62 &&\n (this.lastTokEnd === 0 || lineBreak.test(this.input.slice(this.lastTokEnd, this.pos)))) {\n // A `-->` line comment\n this.skipLineComment(3);\n this.skipSpace();\n return this.nextToken()\n }\n return this.finishOp(types$1.incDec, 2)\n }\n if (next === 61) { return this.finishOp(types$1.assign, 2) }\n return this.finishOp(types$1.plusMin, 1)\n};\n\npp.readToken_lt_gt = function(code) { // '<>'\n var next = this.input.charCodeAt(this.pos + 1);\n var size = 1;\n if (next === code) {\n size = code === 62 && this.input.charCodeAt(this.pos + 2) === 62 ? 3 : 2;\n if (this.input.charCodeAt(this.pos + size) === 61) { return this.finishOp(types$1.assign, size + 1) }\n return this.finishOp(types$1.bitShift, size)\n }\n if (next === 33 && code === 60 && !this.inModule && this.input.charCodeAt(this.pos + 2) === 45 &&\n this.input.charCodeAt(this.pos + 3) === 45) {\n // ` * (any, kinda silly)\n// ~2, ~2.x, ~2.x.x, ~>2, ~>2.x ~>2.x.x --> >=2.0.0 <3.0.0-0\n// ~2.0, ~2.0.x, ~>2.0, ~>2.0.x --> >=2.0.0 <2.1.0-0\n// ~1.2, ~1.2.x, ~>1.2, ~>1.2.x --> >=1.2.0 <1.3.0-0\n// ~1.2.3, ~>1.2.3 --> >=1.2.3 <1.3.0-0\n// ~1.2.0, ~>1.2.0 --> >=1.2.0 <1.3.0-0\nconst replaceTildes = (comp, options) =>\n comp.trim().split(/\\s+/).map((comp) => {\n return replaceTilde(comp, options)\n }).join(' ')\n\nconst replaceTilde = (comp, options) => {\n const r = options.loose ? re[t.TILDELOOSE] : re[t.TILDE]\n return comp.replace(r, (_, M, m, p, pr) => {\n debug('tilde', comp, _, M, m, p, pr)\n let ret\n\n if (isX(M)) {\n ret = ''\n } else if (isX(m)) {\n ret = `>=${M}.0.0 <${+M + 1}.0.0-0`\n } else if (isX(p)) {\n // ~1.2 == >=1.2.0 <1.3.0-0\n ret = `>=${M}.${m}.0 <${M}.${+m + 1}.0-0`\n } else if (pr) {\n debug('replaceTilde pr', pr)\n ret = `>=${M}.${m}.${p}-${pr\n } <${M}.${+m + 1}.0-0`\n } else {\n // ~1.2.3 == >=1.2.3 <1.3.0-0\n ret = `>=${M}.${m}.${p\n } <${M}.${+m + 1}.0-0`\n }\n\n debug('tilde return', ret)\n return ret\n })\n}\n\n// ^ --> * (any, kinda silly)\n// ^2, ^2.x, ^2.x.x --> >=2.0.0 <3.0.0-0\n// ^2.0, ^2.0.x --> >=2.0.0 <3.0.0-0\n// ^1.2, ^1.2.x --> >=1.2.0 <2.0.0-0\n// ^1.2.3 --> >=1.2.3 <2.0.0-0\n// ^1.2.0 --> >=1.2.0 <2.0.0-0\nconst replaceCarets = (comp, options) =>\n comp.trim().split(/\\s+/).map((comp) => {\n return replaceCaret(comp, options)\n }).join(' ')\n\nconst replaceCaret = (comp, options) => {\n debug('caret', comp, options)\n const r = options.loose ? re[t.CARETLOOSE] : re[t.CARET]\n const z = options.includePrerelease ? '-0' : ''\n return comp.replace(r, (_, M, m, p, pr) => {\n debug('caret', comp, _, M, m, p, pr)\n let ret\n\n if (isX(M)) {\n ret = ''\n } else if (isX(m)) {\n ret = `>=${M}.0.0${z} <${+M + 1}.0.0-0`\n } else if (isX(p)) {\n if (M === '0') {\n ret = `>=${M}.${m}.0${z} <${M}.${+m + 1}.0-0`\n } else {\n ret = `>=${M}.${m}.0${z} <${+M + 1}.0.0-0`\n }\n } else if (pr) {\n debug('replaceCaret pr', pr)\n if (M === '0') {\n if (m === '0') {\n ret = `>=${M}.${m}.${p}-${pr\n } <${M}.${m}.${+p + 1}-0`\n } else {\n ret = `>=${M}.${m}.${p}-${pr\n } <${M}.${+m + 1}.0-0`\n }\n } else {\n ret = `>=${M}.${m}.${p}-${pr\n } <${+M + 1}.0.0-0`\n }\n } else {\n debug('no pr')\n if (M === '0') {\n if (m === '0') {\n ret = `>=${M}.${m}.${p\n }${z} <${M}.${m}.${+p + 1}-0`\n } else {\n ret = `>=${M}.${m}.${p\n }${z} <${M}.${+m + 1}.0-0`\n }\n } else {\n ret = `>=${M}.${m}.${p\n } <${+M + 1}.0.0-0`\n }\n }\n\n debug('caret return', ret)\n return ret\n })\n}\n\nconst replaceXRanges = (comp, options) => {\n debug('replaceXRanges', comp, options)\n return comp.split(/\\s+/).map((comp) => {\n return replaceXRange(comp, options)\n }).join(' ')\n}\n\nconst replaceXRange = (comp, options) => {\n comp = comp.trim()\n const r = options.loose ? re[t.XRANGELOOSE] : re[t.XRANGE]\n return comp.replace(r, (ret, gtlt, M, m, p, pr) => {\n debug('xRange', comp, ret, gtlt, M, m, p, pr)\n const xM = isX(M)\n const xm = xM || isX(m)\n const xp = xm || isX(p)\n const anyX = xp\n\n if (gtlt === '=' && anyX) {\n gtlt = ''\n }\n\n // if we're including prereleases in the match, then we need\n // to fix this to -0, the lowest possible prerelease value\n pr = options.includePrerelease ? '-0' : ''\n\n if (xM) {\n if (gtlt === '>' || gtlt === '<') {\n // nothing is allowed\n ret = '<0.0.0-0'\n } else {\n // nothing is forbidden\n ret = '*'\n }\n } else if (gtlt && anyX) {\n // we know patch is an x, because we have any x at all.\n // replace X with 0\n if (xm) {\n m = 0\n }\n p = 0\n\n if (gtlt === '>') {\n // >1 => >=2.0.0\n // >1.2 => >=1.3.0\n gtlt = '>='\n if (xm) {\n M = +M + 1\n m = 0\n p = 0\n } else {\n m = +m + 1\n p = 0\n }\n } else if (gtlt === '<=') {\n // <=0.7.x is actually <0.8.0, since any 0.7.x should\n // pass. Similarly, <=7.x is actually <8.0.0, etc.\n gtlt = '<'\n if (xm) {\n M = +M + 1\n } else {\n m = +m + 1\n }\n }\n\n if (gtlt === '<')\n pr = '-0'\n\n ret = `${gtlt + M}.${m}.${p}${pr}`\n } else if (xm) {\n ret = `>=${M}.0.0${pr} <${+M + 1}.0.0-0`\n } else if (xp) {\n ret = `>=${M}.${m}.0${pr\n } <${M}.${+m + 1}.0-0`\n }\n\n debug('xRange return', ret)\n\n return ret\n })\n}\n\n// Because * is AND-ed with everything else in the comparator,\n// and '' means \"any version\", just remove the *s entirely.\nconst replaceStars = (comp, options) => {\n debug('replaceStars', comp, options)\n // Looseness is ignored here. star is always as loose as it gets!\n return comp.trim().replace(re[t.STAR], '')\n}\n\nconst replaceGTE0 = (comp, options) => {\n debug('replaceGTE0', comp, options)\n return comp.trim()\n .replace(re[options.includePrerelease ? t.GTE0PRE : t.GTE0], '')\n}\n\n// This function is passed to string.replace(re[t.HYPHENRANGE])\n// M, m, patch, prerelease, build\n// 1.2 - 3.4.5 => >=1.2.0 <=3.4.5\n// 1.2.3 - 3.4 => >=1.2.0 <3.5.0-0 Any 3.4.x will do\n// 1.2 - 3.4 => >=1.2.0 <3.5.0-0\nconst hyphenReplace = incPr => ($0,\n from, fM, fm, fp, fpr, fb,\n to, tM, tm, tp, tpr, tb) => {\n if (isX(fM)) {\n from = ''\n } else if (isX(fm)) {\n from = `>=${fM}.0.0${incPr ? '-0' : ''}`\n } else if (isX(fp)) {\n from = `>=${fM}.${fm}.0${incPr ? '-0' : ''}`\n } else if (fpr) {\n from = `>=${from}`\n } else {\n from = `>=${from}${incPr ? '-0' : ''}`\n }\n\n if (isX(tM)) {\n to = ''\n } else if (isX(tm)) {\n to = `<${+tM + 1}.0.0-0`\n } else if (isX(tp)) {\n to = `<${tM}.${+tm + 1}.0-0`\n } else if (tpr) {\n to = `<=${tM}.${tm}.${tp}-${tpr}`\n } else if (incPr) {\n to = `<${tM}.${tm}.${+tp + 1}-0`\n } else {\n to = `<=${to}`\n }\n\n return (`${from} ${to}`).trim()\n}\n\nconst testSet = (set, version, options) => {\n for (let i = 0; i < set.length; i++) {\n if (!set[i].test(version)) {\n return false\n }\n }\n\n if (version.prerelease.length && !options.includePrerelease) {\n // Find the set of versions that are allowed to have prereleases\n // For example, ^1.2.3-pr.1 desugars to >=1.2.3-pr.1 <2.0.0\n // That should allow `1.2.3-pr.2` to pass.\n // However, `1.2.4-alpha.notready` should NOT be allowed,\n // even though it's within the range set by the comparators.\n for (let i = 0; i < set.length; i++) {\n debug(set[i].semver)\n if (set[i].semver === Comparator.ANY) {\n continue\n }\n\n if (set[i].semver.prerelease.length > 0) {\n const allowed = set[i].semver\n if (allowed.major === version.major &&\n allowed.minor === version.minor &&\n allowed.patch === version.patch) {\n return true\n }\n }\n }\n\n // Version has a -pre, but it's not one of the ones we like.\n return false\n }\n\n return true\n}\n", "const ANY = Symbol('SemVer ANY')\n// hoisted class for cyclic dependency\nclass Comparator {\n static get ANY () {\n return ANY\n }\n constructor (comp, options) {\n options = parseOptions(options)\n\n if (comp instanceof Comparator) {\n if (comp.loose === !!options.loose) {\n return comp\n } else {\n comp = comp.value\n }\n }\n\n debug('comparator', comp, options)\n this.options = options\n this.loose = !!options.loose\n this.parse(comp)\n\n if (this.semver === ANY) {\n this.value = ''\n } else {\n this.value = this.operator + this.semver.version\n }\n\n debug('comp', this)\n }\n\n parse (comp) {\n const r = this.options.loose ? re[t.COMPARATORLOOSE] : re[t.COMPARATOR]\n const m = comp.match(r)\n\n if (!m) {\n throw new TypeError(`Invalid comparator: ${comp}`)\n }\n\n this.operator = m[1] !== undefined ? m[1] : ''\n if (this.operator === '=') {\n this.operator = ''\n }\n\n // if it literally is just '>' or '' then allow anything.\n if (!m[2]) {\n this.semver = ANY\n } else {\n this.semver = new SemVer(m[2], this.options.loose)\n }\n }\n\n toString () {\n return this.value\n }\n\n test (version) {\n debug('Comparator.test', version, this.options.loose)\n\n if (this.semver === ANY || version === ANY) {\n return true\n }\n\n if (typeof version === 'string') {\n try {\n version = new SemVer(version, this.options)\n } catch (er) {\n return false\n }\n }\n\n return cmp(version, this.operator, this.semver, this.options)\n }\n\n intersects (comp, options) {\n if (!(comp instanceof Comparator)) {\n throw new TypeError('a Comparator is required')\n }\n\n if (!options || typeof options !== 'object') {\n options = {\n loose: !!options,\n includePrerelease: false\n }\n }\n\n if (this.operator === '') {\n if (this.value === '') {\n return true\n }\n return new Range(comp.value, options).test(this.value)\n } else if (comp.operator === '') {\n if (comp.value === '') {\n return true\n }\n return new Range(this.value, options).test(comp.semver)\n }\n\n const sameDirectionIncreasing =\n (this.operator === '>=' || this.operator === '>') &&\n (comp.operator === '>=' || comp.operator === '>')\n const sameDirectionDecreasing =\n (this.operator === '<=' || this.operator === '<') &&\n (comp.operator === '<=' || comp.operator === '<')\n const sameSemVer = this.semver.version === comp.semver.version\n const differentDirectionsInclusive =\n (this.operator === '>=' || this.operator === '<=') &&\n (comp.operator === '>=' || comp.operator === '<=')\n const oppositeDirectionsLessThan =\n cmp(this.semver, '<', comp.semver, options) &&\n (this.operator === '>=' || this.operator === '>') &&\n (comp.operator === '<=' || comp.operator === '<')\n const oppositeDirectionsGreaterThan =\n cmp(this.semver, '>', comp.semver, options) &&\n (this.operator === '<=' || this.operator === '<') &&\n (comp.operator === '>=' || comp.operator === '>')\n\n return (\n sameDirectionIncreasing ||\n sameDirectionDecreasing ||\n (sameSemVer && differentDirectionsInclusive) ||\n oppositeDirectionsLessThan ||\n oppositeDirectionsGreaterThan\n )\n }\n}\n\nmodule.exports = Comparator\n\nconst parseOptions = require('../internal/parse-options')\nconst {re, t} = require('../internal/re')\nconst cmp = require('../functions/cmp')\nconst debug = require('../internal/debug')\nconst SemVer = require('./semver')\nconst Range = require('./range')\n", "const Range = require('../classes/range')\nconst satisfies = (version, range, options) => {\n try {\n range = new Range(range, options)\n } catch (er) {\n return false\n }\n return range.test(version)\n}\nmodule.exports = satisfies\n", "const Range = require('../classes/range')\n\n// Mostly just for testing and legacy API reasons\nconst toComparators = (range, options) =>\n new Range(range, options).set\n .map(comp => comp.map(c => c.value).join(' ').trim().split(' '))\n\nmodule.exports = toComparators\n", "const SemVer = require('../classes/semver')\nconst Range = require('../classes/range')\n\nconst maxSatisfying = (versions, range, options) => {\n let max = null\n let maxSV = null\n let rangeObj = null\n try {\n rangeObj = new Range(range, options)\n } catch (er) {\n return null\n }\n versions.forEach((v) => {\n if (rangeObj.test(v)) {\n // satisfies(v, range, options)\n if (!max || maxSV.compare(v) === -1) {\n // compare(max, v, true)\n max = v\n maxSV = new SemVer(max, options)\n }\n }\n })\n return max\n}\nmodule.exports = maxSatisfying\n", "const SemVer = require('../classes/semver')\nconst Range = require('../classes/range')\nconst minSatisfying = (versions, range, options) => {\n let min = null\n let minSV = null\n let rangeObj = null\n try {\n rangeObj = new Range(range, options)\n } catch (er) {\n return null\n }\n versions.forEach((v) => {\n if (rangeObj.test(v)) {\n // satisfies(v, range, options)\n if (!min || minSV.compare(v) === 1) {\n // compare(min, v, true)\n min = v\n minSV = new SemVer(min, options)\n }\n }\n })\n return min\n}\nmodule.exports = minSatisfying\n", "const SemVer = require('../classes/semver')\nconst Range = require('../classes/range')\nconst gt = require('../functions/gt')\n\nconst minVersion = (range, loose) => {\n range = new Range(range, loose)\n\n let minver = new SemVer('0.0.0')\n if (range.test(minver)) {\n return minver\n }\n\n minver = new SemVer('0.0.0-0')\n if (range.test(minver)) {\n return minver\n }\n\n minver = null\n for (let i = 0; i < range.set.length; ++i) {\n const comparators = range.set[i]\n\n let setMin = null\n comparators.forEach((comparator) => {\n // Clone to avoid manipulating the comparator's semver object.\n const compver = new SemVer(comparator.semver.version)\n switch (comparator.operator) {\n case '>':\n if (compver.prerelease.length === 0) {\n compver.patch++\n } else {\n compver.prerelease.push(0)\n }\n compver.raw = compver.format()\n /* fallthrough */\n case '':\n case '>=':\n if (!setMin || gt(compver, setMin)) {\n setMin = compver\n }\n break\n case '<':\n case '<=':\n /* Ignore maximum versions */\n break\n /* istanbul ignore next */\n default:\n throw new Error(`Unexpected operation: ${comparator.operator}`)\n }\n })\n if (setMin && (!minver || gt(minver, setMin)))\n minver = setMin\n }\n\n if (minver && range.test(minver)) {\n return minver\n }\n\n return null\n}\nmodule.exports = minVersion\n", "const Range = require('../classes/range')\nconst validRange = (range, options) => {\n try {\n // Return '*' instead of '' so that truthiness works.\n // This will throw if it's invalid anyway\n return new Range(range, options).range || '*'\n } catch (er) {\n return null\n }\n}\nmodule.exports = validRange\n", "const SemVer = require('../classes/semver')\nconst Comparator = require('../classes/comparator')\nconst {ANY} = Comparator\nconst Range = require('../classes/range')\nconst satisfies = require('../functions/satisfies')\nconst gt = require('../functions/gt')\nconst lt = require('../functions/lt')\nconst lte = require('../functions/lte')\nconst gte = require('../functions/gte')\n\nconst outside = (version, range, hilo, options) => {\n version = new SemVer(version, options)\n range = new Range(range, options)\n\n let gtfn, ltefn, ltfn, comp, ecomp\n switch (hilo) {\n case '>':\n gtfn = gt\n ltefn = lte\n ltfn = lt\n comp = '>'\n ecomp = '>='\n break\n case '<':\n gtfn = lt\n ltefn = gte\n ltfn = gt\n comp = '<'\n ecomp = '<='\n break\n default:\n throw new TypeError('Must provide a hilo val of \"<\" or \">\"')\n }\n\n // If it satisfies the range it is not outside\n if (satisfies(version, range, options)) {\n return false\n }\n\n // From now on, variable terms are as if we're in \"gtr\" mode.\n // but note that everything is flipped for the \"ltr\" function.\n\n for (let i = 0; i < range.set.length; ++i) {\n const comparators = range.set[i]\n\n let high = null\n let low = null\n\n comparators.forEach((comparator) => {\n if (comparator.semver === ANY) {\n comparator = new Comparator('>=0.0.0')\n }\n high = high || comparator\n low = low || comparator\n if (gtfn(comparator.semver, high.semver, options)) {\n high = comparator\n } else if (ltfn(comparator.semver, low.semver, options)) {\n low = comparator\n }\n })\n\n // If the edge version comparator has a operator then our version\n // isn't outside it\n if (high.operator === comp || high.operator === ecomp) {\n return false\n }\n\n // If the lowest version comparator has an operator and our version\n // is less than it then it isn't higher than the range\n if ((!low.operator || low.operator === comp) &&\n ltefn(version, low.semver)) {\n return false\n } else if (low.operator === ecomp && ltfn(version, low.semver)) {\n return false\n }\n }\n return true\n}\n\nmodule.exports = outside\n", "// Determine if version is greater than all the versions possible in the range.\nconst outside = require('./outside')\nconst gtr = (version, range, options) => outside(version, range, '>', options)\nmodule.exports = gtr\n", "const outside = require('./outside')\n// Determine if version is less than all the versions possible in the range\nconst ltr = (version, range, options) => outside(version, range, '<', options)\nmodule.exports = ltr\n", "const Range = require('../classes/range')\nconst intersects = (r1, r2, options) => {\n r1 = new Range(r1, options)\n r2 = new Range(r2, options)\n return r1.intersects(r2)\n}\nmodule.exports = intersects\n", "// given a set of versions and a range, create a \"simplified\" range\n// that includes the same versions that the original range does\n// If the original range is shorter than the simplified one, return that.\nconst satisfies = require('../functions/satisfies.js')\nconst compare = require('../functions/compare.js')\nmodule.exports = (versions, range, options) => {\n const set = []\n let min = null\n let prev = null\n const v = versions.sort((a, b) => compare(a, b, options))\n for (const version of v) {\n const included = satisfies(version, range, options)\n if (included) {\n prev = version\n if (!min)\n min = version\n } else {\n if (prev) {\n set.push([min, prev])\n }\n prev = null\n min = null\n }\n }\n if (min)\n set.push([min, null])\n\n const ranges = []\n for (const [min, max] of set) {\n if (min === max)\n ranges.push(min)\n else if (!max && min === v[0])\n ranges.push('*')\n else if (!max)\n ranges.push(`>=${min}`)\n else if (min === v[0])\n ranges.push(`<=${max}`)\n else\n ranges.push(`${min} - ${max}`)\n }\n const simplified = ranges.join(' || ')\n const original = typeof range.raw === 'string' ? range.raw : String(range)\n return simplified.length < original.length ? simplified : range\n}\n", "const Range = require('../classes/range.js')\nconst Comparator = require('../classes/comparator.js')\nconst { ANY } = Comparator\nconst satisfies = require('../functions/satisfies.js')\nconst compare = require('../functions/compare.js')\n\n// Complex range `r1 || r2 || ...` is a subset of `R1 || R2 || ...` iff:\n// - Every simple range `r1, r2, ...` is a null set, OR\n// - Every simple range `r1, r2, ...` which is not a null set is a subset of\n// some `R1, R2, ...`\n//\n// Simple range `c1 c2 ...` is a subset of simple range `C1 C2 ...` iff:\n// - If c is only the ANY comparator\n// - If C is only the ANY comparator, return true\n// - Else if in prerelease mode, return false\n// - else replace c with `[>=0.0.0]`\n// - If C is only the ANY comparator\n// - if in prerelease mode, return true\n// - else replace C with `[>=0.0.0]`\n// - Let EQ be the set of = comparators in c\n// - If EQ is more than one, return true (null set)\n// - Let GT be the highest > or >= comparator in c\n// - Let LT be the lowest < or <= comparator in c\n// - If GT and LT, and GT.semver > LT.semver, return true (null set)\n// - If any C is a = range, and GT or LT are set, return false\n// - If EQ\n// - If GT, and EQ does not satisfy GT, return true (null set)\n// - If LT, and EQ does not satisfy LT, return true (null set)\n// - If EQ satisfies every C, return true\n// - Else return false\n// - If GT\n// - If GT.semver is lower than any > or >= comp in C, return false\n// - If GT is >=, and GT.semver does not satisfy every C, return false\n// - If GT.semver has a prerelease, and not in prerelease mode\n// - If no C has a prerelease and the GT.semver tuple, return false\n// - If LT\n// - If LT.semver is greater than any < or <= comp in C, return false\n// - If LT is <=, and LT.semver does not satisfy every C, return false\n// - If GT.semver has a prerelease, and not in prerelease mode\n// - If no C has a prerelease and the LT.semver tuple, return false\n// - Else return true\n\nconst subset = (sub, dom, options = {}) => {\n if (sub === dom)\n return true\n\n sub = new Range(sub, options)\n dom = new Range(dom, options)\n let sawNonNull = false\n\n OUTER: for (const simpleSub of sub.set) {\n for (const simpleDom of dom.set) {\n const isSub = simpleSubset(simpleSub, simpleDom, options)\n sawNonNull = sawNonNull || isSub !== null\n if (isSub)\n continue OUTER\n }\n // the null set is a subset of everything, but null simple ranges in\n // a complex range should be ignored. so if we saw a non-null range,\n // then we know this isn't a subset, but if EVERY simple range was null,\n // then it is a subset.\n if (sawNonNull)\n return false\n }\n return true\n}\n\nconst simpleSubset = (sub, dom, options) => {\n if (sub === dom)\n return true\n\n if (sub.length === 1 && sub[0].semver === ANY) {\n if (dom.length === 1 && dom[0].semver === ANY)\n return true\n else if (options.includePrerelease)\n sub = [ new Comparator('>=0.0.0-0') ]\n else\n sub = [ new Comparator('>=0.0.0') ]\n }\n\n if (dom.length === 1 && dom[0].semver === ANY) {\n if (options.includePrerelease)\n return true\n else\n dom = [ new Comparator('>=0.0.0') ]\n }\n\n const eqSet = new Set()\n let gt, lt\n for (const c of sub) {\n if (c.operator === '>' || c.operator === '>=')\n gt = higherGT(gt, c, options)\n else if (c.operator === '<' || c.operator === '<=')\n lt = lowerLT(lt, c, options)\n else\n eqSet.add(c.semver)\n }\n\n if (eqSet.size > 1)\n return null\n\n let gtltComp\n if (gt && lt) {\n gtltComp = compare(gt.semver, lt.semver, options)\n if (gtltComp > 0)\n return null\n else if (gtltComp === 0 && (gt.operator !== '>=' || lt.operator !== '<='))\n return null\n }\n\n // will iterate one or zero times\n for (const eq of eqSet) {\n if (gt && !satisfies(eq, String(gt), options))\n return null\n\n if (lt && !satisfies(eq, String(lt), options))\n return null\n\n for (const c of dom) {\n if (!satisfies(eq, String(c), options))\n return false\n }\n\n return true\n }\n\n let higher, lower\n let hasDomLT, hasDomGT\n // if the subset has a prerelease, we need a comparator in the superset\n // with the same tuple and a prerelease, or it's not a subset\n let needDomLTPre = lt &&\n !options.includePrerelease &&\n lt.semver.prerelease.length ? lt.semver : false\n let needDomGTPre = gt &&\n !options.includePrerelease &&\n gt.semver.prerelease.length ? gt.semver : false\n // exception: <1.2.3-0 is the same as <1.2.3\n if (needDomLTPre && needDomLTPre.prerelease.length === 1 &&\n lt.operator === '<' && needDomLTPre.prerelease[0] === 0) {\n needDomLTPre = false\n }\n\n for (const c of dom) {\n hasDomGT = hasDomGT || c.operator === '>' || c.operator === '>='\n hasDomLT = hasDomLT || c.operator === '<' || c.operator === '<='\n if (gt) {\n if (needDomGTPre) {\n if (c.semver.prerelease && c.semver.prerelease.length &&\n c.semver.major === needDomGTPre.major &&\n c.semver.minor === needDomGTPre.minor &&\n c.semver.patch === needDomGTPre.patch) {\n needDomGTPre = false\n }\n }\n if (c.operator === '>' || c.operator === '>=') {\n higher = higherGT(gt, c, options)\n if (higher === c && higher !== gt)\n return false\n } else if (gt.operator === '>=' && !satisfies(gt.semver, String(c), options))\n return false\n }\n if (lt) {\n if (needDomLTPre) {\n if (c.semver.prerelease && c.semver.prerelease.length &&\n c.semver.major === needDomLTPre.major &&\n c.semver.minor === needDomLTPre.minor &&\n c.semver.patch === needDomLTPre.patch) {\n needDomLTPre = false\n }\n }\n if (c.operator === '<' || c.operator === '<=') {\n lower = lowerLT(lt, c, options)\n if (lower === c && lower !== lt)\n return false\n } else if (lt.operator === '<=' && !satisfies(lt.semver, String(c), options))\n return false\n }\n if (!c.operator && (lt || gt) && gtltComp !== 0)\n return false\n }\n\n // if there was a < or >, and nothing in the dom, then must be false\n // UNLESS it was limited by another range in the other direction.\n // Eg, >1.0.0 <1.0.1 is still a subset of <2.0.0\n if (gt && hasDomLT && !lt && gtltComp !== 0)\n return false\n\n if (lt && hasDomGT && !gt && gtltComp !== 0)\n return false\n\n // we needed a prerelease range in a specific tuple, but didn't get one\n // then this isn't a subset. eg >=1.2.3-pre is not a subset of >=1.0.0,\n // because it includes prereleases in the 1.2.3 tuple\n if (needDomGTPre || needDomLTPre)\n return false\n\n return true\n}\n\n// >=1.2.3 is lower than >1.2.3\nconst higherGT = (a, b, options) => {\n if (!a)\n return b\n const comp = compare(a.semver, b.semver, options)\n return comp > 0 ? a\n : comp < 0 ? b\n : b.operator === '>' && a.operator === '>=' ? b\n : a\n}\n\n// <=1.2.3 is higher than <1.2.3\nconst lowerLT = (a, b, options) => {\n if (!a)\n return b\n const comp = compare(a.semver, b.semver, options)\n return comp < 0 ? a\n : comp > 0 ? b\n : b.operator === '<' && a.operator === '<=' ? b\n : a\n}\n\nmodule.exports = subset\n", "// just pre-load all the stuff that index.js lazily exports\nconst internalRe = require('./internal/re')\nmodule.exports = {\n re: internalRe.re,\n src: internalRe.src,\n tokens: internalRe.t,\n SEMVER_SPEC_VERSION: require('./internal/constants').SEMVER_SPEC_VERSION,\n SemVer: require('./classes/semver'),\n compareIdentifiers: require('./internal/identifiers').compareIdentifiers,\n rcompareIdentifiers: require('./internal/identifiers').rcompareIdentifiers,\n parse: require('./functions/parse'),\n valid: require('./functions/valid'),\n clean: require('./functions/clean'),\n inc: require('./functions/inc'),\n diff: require('./functions/diff'),\n major: require('./functions/major'),\n minor: require('./functions/minor'),\n patch: require('./functions/patch'),\n prerelease: require('./functions/prerelease'),\n compare: require('./functions/compare'),\n rcompare: require('./functions/rcompare'),\n compareLoose: require('./functions/compare-loose'),\n compareBuild: require('./functions/compare-build'),\n sort: require('./functions/sort'),\n rsort: require('./functions/rsort'),\n gt: require('./functions/gt'),\n lt: require('./functions/lt'),\n eq: require('./functions/eq'),\n neq: require('./functions/neq'),\n gte: require('./functions/gte'),\n lte: require('./functions/lte'),\n cmp: require('./functions/cmp'),\n coerce: require('./functions/coerce'),\n Comparator: require('./classes/comparator'),\n Range: require('./classes/range'),\n satisfies: require('./functions/satisfies'),\n toComparators: require('./ranges/to-comparators'),\n maxSatisfying: require('./ranges/max-satisfying'),\n minSatisfying: require('./ranges/min-satisfying'),\n minVersion: require('./ranges/min-version'),\n validRange: require('./ranges/valid'),\n outside: require('./ranges/outside'),\n gtr: require('./ranges/gtr'),\n ltr: require('./ranges/ltr'),\n intersects: require('./ranges/intersects'),\n simplifyRange: require('./ranges/simplify'),\n subset: require('./ranges/subset'),\n}\n", "'use strict';\n\n// ES6 Map\nvar map;\ntry {\n map = Map;\n} catch (_) { }\nvar set;\n\n// ES6 Set\ntry {\n set = Set;\n} catch (_) { }\n\nfunction baseClone (src, circulars, clones) {\n // Null/undefined/functions/etc\n if (!src || typeof src !== 'object' || typeof src === 'function') {\n return src\n }\n\n // DOM Node\n if (src.nodeType && 'cloneNode' in src) {\n return src.cloneNode(true)\n }\n\n // Date\n if (src instanceof Date) {\n return new Date(src.getTime())\n }\n\n // RegExp\n if (src instanceof RegExp) {\n return new RegExp(src)\n }\n\n // Arrays\n if (Array.isArray(src)) {\n return src.map(clone)\n }\n\n // ES6 Maps\n if (map && src instanceof map) {\n return new Map(Array.from(src.entries()))\n }\n\n // ES6 Sets\n if (set && src instanceof set) {\n return new Set(Array.from(src.values()))\n }\n\n // Object\n if (src instanceof Object) {\n circulars.push(src);\n var obj = Object.create(src);\n clones.push(obj);\n for (var key in src) {\n var idx = circulars.findIndex(function (i) {\n return i === src[key]\n });\n obj[key] = idx > -1 ? clones[idx] : baseClone(src[key], circulars, clones);\n }\n return obj\n }\n\n // ???\n return src\n}\n\nfunction clone (src) {\n return baseClone(src, [], [])\n}\n\nmodule.exports = clone;\n", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = printValue;\nconst toString = Object.prototype.toString;\nconst errorToString = Error.prototype.toString;\nconst regExpToString = RegExp.prototype.toString;\nconst symbolToString = typeof Symbol !== 'undefined' ? Symbol.prototype.toString : () => '';\nconst SYMBOL_REGEXP = /^Symbol\\((.*)\\)(.*)$/;\n\nfunction printNumber(val) {\n if (val != +val) return 'NaN';\n const isNegativeZero = val === 0 && 1 / val < 0;\n return isNegativeZero ? '-0' : '' + val;\n}\n\nfunction printSimpleValue(val, quoteStrings = false) {\n if (val == null || val === true || val === false) return '' + val;\n const typeOf = typeof val;\n if (typeOf === 'number') return printNumber(val);\n if (typeOf === 'string') return quoteStrings ? `\"${val}\"` : val;\n if (typeOf === 'function') return '[Function ' + (val.name || 'anonymous') + ']';\n if (typeOf === 'symbol') return symbolToString.call(val).replace(SYMBOL_REGEXP, 'Symbol($1)');\n const tag = toString.call(val).slice(8, -1);\n if (tag === 'Date') return isNaN(val.getTime()) ? '' + val : val.toISOString(val);\n if (tag === 'Error' || val instanceof Error) return '[' + errorToString.call(val) + ']';\n if (tag === 'RegExp') return regExpToString.call(val);\n return null;\n}\n\nfunction printValue(value, quoteStrings) {\n let result = printSimpleValue(value, quoteStrings);\n if (result !== null) return result;\n return JSON.stringify(value, function (key, value) {\n let result = printSimpleValue(this[key], quoteStrings);\n if (result !== null) return result;\n return value;\n }, 2);\n}", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = exports.array = exports.object = exports.boolean = exports.date = exports.number = exports.string = exports.mixed = void 0;\n\nvar _printValue = _interopRequireDefault(require(\"./util/printValue\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nlet mixed = {\n default: '${path} is invalid',\n required: '${path} is a required field',\n oneOf: '${path} must be one of the following values: ${values}',\n notOneOf: '${path} must not be one of the following values: ${values}',\n notType: ({\n path,\n type,\n value,\n originalValue\n }) => {\n let isCast = originalValue != null && originalValue !== value;\n let msg = `${path} must be a \\`${type}\\` type, ` + `but the final value was: \\`${(0, _printValue.default)(value, true)}\\`` + (isCast ? ` (cast from the value \\`${(0, _printValue.default)(originalValue, true)}\\`).` : '.');\n\n if (value === null) {\n msg += `\\n If \"null\" is intended as an empty value be sure to mark the schema as \\`.nullable()\\``;\n }\n\n return msg;\n },\n defined: '${path} must be defined'\n};\nexports.mixed = mixed;\nlet string = {\n length: '${path} must be exactly ${length} characters',\n min: '${path} must be at least ${min} characters',\n max: '${path} must be at most ${max} characters',\n matches: '${path} must match the following: \"${regex}\"',\n email: '${path} must be a valid email',\n url: '${path} must be a valid URL',\n uuid: '${path} must be a valid UUID',\n trim: '${path} must be a trimmed string',\n lowercase: '${path} must be a lowercase string',\n uppercase: '${path} must be a upper case string'\n};\nexports.string = string;\nlet number = {\n min: '${path} must be greater than or equal to ${min}',\n max: '${path} must be less than or equal to ${max}',\n lessThan: '${path} must be less than ${less}',\n moreThan: '${path} must be greater than ${more}',\n positive: '${path} must be a positive number',\n negative: '${path} must be a negative number',\n integer: '${path} must be an integer'\n};\nexports.number = number;\nlet date = {\n min: '${path} field must be later than ${min}',\n max: '${path} field must be at earlier than ${max}'\n};\nexports.date = date;\nlet boolean = {\n isValue: '${path} field must be ${value}'\n};\nexports.boolean = boolean;\nlet object = {\n noUnknown: '${path} field has unspecified keys: ${unknown}'\n};\nexports.object = object;\nlet array = {\n min: '${path} field must have at least ${min} items',\n max: '${path} field must have less than or equal to ${max} items',\n length: '${path} must be have ${length} items'\n};\nexports.array = array;\n\nvar _default = Object.assign(Object.create(null), {\n mixed,\n string,\n number,\n date,\n object,\n array,\n boolean\n});\n\nexports.default = _default;", "/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.has` without support for deep paths.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {Array|string} key The key to check.\n * @returns {boolean} Returns `true` if `key` exists, else `false`.\n */\nfunction baseHas(object, key) {\n return object != null && hasOwnProperty.call(object, key);\n}\n\nmodule.exports = baseHas;\n", "var baseHas = require('./_baseHas'),\n hasPath = require('./_hasPath');\n\n/**\n * Checks if `path` is a direct property of `object`.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n * @example\n *\n * var object = { 'a': { 'b': 2 } };\n * var other = _.create({ 'a': _.create({ 'b': 2 }) });\n *\n * _.has(object, 'a');\n * // => true\n *\n * _.has(object, 'a.b');\n * // => true\n *\n * _.has(object, ['a', 'b']);\n * // => true\n *\n * _.has(other, 'a');\n * // => false\n */\nfunction has(object, path) {\n return object != null && hasPath(object, path, baseHas);\n}\n\nmodule.exports = has;\n", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _default = obj => obj && obj.__isYupSchema__;\n\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _has = _interopRequireDefault(require(\"lodash/has\"));\n\nvar _isSchema = _interopRequireDefault(require(\"./util/isSchema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nclass Condition {\n constructor(refs, options) {\n this.refs = refs;\n this.refs = refs;\n\n if (typeof options === 'function') {\n this.fn = options;\n return;\n }\n\n if (!(0, _has.default)(options, 'is')) throw new TypeError('`is:` is required for `when()` conditions');\n if (!options.then && !options.otherwise) throw new TypeError('either `then:` or `otherwise:` is required for `when()` conditions');\n let {\n is,\n then,\n otherwise\n } = options;\n let check = typeof is === 'function' ? is : (...values) => values.every(value => value === is);\n\n this.fn = function (...args) {\n let options = args.pop();\n let schema = args.pop();\n let branch = check(...args) ? then : otherwise;\n if (!branch) return undefined;\n if (typeof branch === 'function') return branch(schema);\n return schema.concat(branch.resolve(options));\n };\n }\n\n resolve(base, options) {\n let values = this.refs.map(ref => ref.getValue(options == null ? void 0 : options.value, options == null ? void 0 : options.parent, options == null ? void 0 : options.context));\n let schema = this.fn.apply(base, values.concat(base, options));\n if (schema === undefined || schema === base) return base;\n if (!(0, _isSchema.default)(schema)) throw new TypeError('conditions must return a schema object');\n return schema.resolve(options);\n }\n\n}\n\nvar _default = Condition;\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = toArray;\n\nfunction toArray(value) {\n return value == null ? [] : [].concat(value);\n}", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _printValue = _interopRequireDefault(require(\"./util/printValue\"));\n\nvar _toArray = _interopRequireDefault(require(\"./util/toArray\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nlet strReg = /\\$\\{\\s*(\\w+)\\s*\\}/g;\n\nclass ValidationError extends Error {\n static formatError(message, params) {\n const path = params.label || params.path || 'this';\n if (path !== params.path) params = _extends({}, params, {\n path\n });\n if (typeof message === 'string') return message.replace(strReg, (_, key) => (0, _printValue.default)(params[key]));\n if (typeof message === 'function') return message(params);\n return message;\n }\n\n static isError(err) {\n return err && err.name === 'ValidationError';\n }\n\n constructor(errorOrErrors, value, field, type) {\n super();\n this.name = 'ValidationError';\n this.value = value;\n this.path = field;\n this.type = type;\n this.errors = [];\n this.inner = [];\n (0, _toArray.default)(errorOrErrors).forEach(err => {\n if (ValidationError.isError(err)) {\n this.errors.push(...err.errors);\n this.inner = this.inner.concat(err.inner.length ? err.inner : err);\n } else {\n this.errors.push(err);\n }\n });\n this.message = this.errors.length > 1 ? `${this.errors.length} errors occurred` : this.errors[0];\n if (Error.captureStackTrace) Error.captureStackTrace(this, ValidationError);\n }\n\n}\n\nexports.default = ValidationError;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = runTests;\n\nvar _ValidationError = _interopRequireDefault(require(\"../ValidationError\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nconst once = cb => {\n let fired = false;\n return (...args) => {\n if (fired) return;\n fired = true;\n cb(...args);\n };\n};\n\nfunction runTests(options, cb) {\n let {\n endEarly,\n tests,\n args,\n value,\n errors,\n sort,\n path\n } = options;\n let callback = once(cb);\n let count = tests.length;\n const nestedErrors = [];\n errors = errors ? errors : [];\n if (!count) return errors.length ? callback(new _ValidationError.default(errors, value, path)) : callback(null, value);\n\n for (let i = 0; i < tests.length; i++) {\n const test = tests[i];\n test(args, function finishTestRun(err) {\n if (err) {\n // always return early for non validation errors\n if (!_ValidationError.default.isError(err)) {\n return callback(err, value);\n }\n\n if (endEarly) {\n err.value = value;\n return callback(err, value);\n }\n\n nestedErrors.push(err);\n }\n\n if (--count <= 0) {\n if (nestedErrors.length) {\n if (sort) nestedErrors.sort(sort); //show parent errors after the nested ones: name.first, name\n\n if (errors.length) nestedErrors.push(...errors);\n errors = nestedErrors;\n }\n\n if (errors.length) {\n callback(new _ValidationError.default(errors, value, path), value);\n return;\n }\n\n callback(null, value);\n }\n });\n }\n}", "/**\n * Creates a base function for methods like `_.forIn` and `_.forOwn`.\n *\n * @private\n * @param {boolean} [fromRight] Specify iterating from right to left.\n * @returns {Function} Returns the new base function.\n */\nfunction createBaseFor(fromRight) {\n return function(object, iteratee, keysFunc) {\n var index = -1,\n iterable = Object(object),\n props = keysFunc(object),\n length = props.length;\n\n while (length--) {\n var key = props[fromRight ? length : ++index];\n if (iteratee(iterable[key], key, iterable) === false) {\n break;\n }\n }\n return object;\n };\n}\n\nmodule.exports = createBaseFor;\n", "var createBaseFor = require('./_createBaseFor');\n\n/**\n * The base implementation of `baseForOwn` which iterates over `object`\n * properties returned by `keysFunc` and invokes `iteratee` for each property.\n * Iteratee functions may exit iteration early by explicitly returning `false`.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @returns {Object} Returns `object`.\n */\nvar baseFor = createBaseFor();\n\nmodule.exports = baseFor;\n", "/**\n * The base implementation of `_.times` without support for iteratee shorthands\n * or max array length checks.\n *\n * @private\n * @param {number} n The number of times to invoke `iteratee`.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the array of results.\n */\nfunction baseTimes(n, iteratee) {\n var index = -1,\n result = Array(n);\n\n while (++index < n) {\n result[index] = iteratee(index);\n }\n return result;\n}\n\nmodule.exports = baseTimes;\n", "/**\n * This method returns `false`.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {boolean} Returns `false`.\n * @example\n *\n * _.times(2, _.stubFalse);\n * // => [false, false]\n */\nfunction stubFalse() {\n return false;\n}\n\nmodule.exports = stubFalse;\n", "var root = require('./_root'),\n stubFalse = require('./stubFalse');\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Built-in value references. */\nvar Buffer = moduleExports ? root.Buffer : undefined;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined;\n\n/**\n * Checks if `value` is a buffer.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.\n * @example\n *\n * _.isBuffer(new Buffer(2));\n * // => true\n *\n * _.isBuffer(new Uint8Array(2));\n * // => false\n */\nvar isBuffer = nativeIsBuffer || stubFalse;\n\nmodule.exports = isBuffer;\n", "var baseGetTag = require('./_baseGetTag'),\n isLength = require('./isLength'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n funcTag = '[object Function]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n objectTag = '[object Object]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n weakMapTag = '[object WeakMap]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]',\n float32Tag = '[object Float32Array]',\n float64Tag = '[object Float64Array]',\n int8Tag = '[object Int8Array]',\n int16Tag = '[object Int16Array]',\n int32Tag = '[object Int32Array]',\n uint8Tag = '[object Uint8Array]',\n uint8ClampedTag = '[object Uint8ClampedArray]',\n uint16Tag = '[object Uint16Array]',\n uint32Tag = '[object Uint32Array]';\n\n/** Used to identify `toStringTag` values of typed arrays. */\nvar typedArrayTags = {};\ntypedArrayTags[float32Tag] = typedArrayTags[float64Tag] =\ntypedArrayTags[int8Tag] = typedArrayTags[int16Tag] =\ntypedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =\ntypedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =\ntypedArrayTags[uint32Tag] = true;\ntypedArrayTags[argsTag] = typedArrayTags[arrayTag] =\ntypedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =\ntypedArrayTags[dataViewTag] = typedArrayTags[dateTag] =\ntypedArrayTags[errorTag] = typedArrayTags[funcTag] =\ntypedArrayTags[mapTag] = typedArrayTags[numberTag] =\ntypedArrayTags[objectTag] = typedArrayTags[regexpTag] =\ntypedArrayTags[setTag] = typedArrayTags[stringTag] =\ntypedArrayTags[weakMapTag] = false;\n\n/**\n * The base implementation of `_.isTypedArray` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n */\nfunction baseIsTypedArray(value) {\n return isObjectLike(value) &&\n isLength(value.length) && !!typedArrayTags[baseGetTag(value)];\n}\n\nmodule.exports = baseIsTypedArray;\n", "/**\n * The base implementation of `_.unary` without support for storing metadata.\n *\n * @private\n * @param {Function} func The function to cap arguments for.\n * @returns {Function} Returns the new capped function.\n */\nfunction baseUnary(func) {\n return function(value) {\n return func(value);\n };\n}\n\nmodule.exports = baseUnary;\n", "var freeGlobal = require('./_freeGlobal');\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Detect free variable `process` from Node.js. */\nvar freeProcess = moduleExports && freeGlobal.process;\n\n/** Used to access faster Node.js helpers. */\nvar nodeUtil = (function() {\n try {\n // Use `util.types` for Node.js 10+.\n var types = freeModule && freeModule.require && freeModule.require('util').types;\n\n if (types) {\n return types;\n }\n\n // Legacy `process.binding('util')` for Node.js < 10.\n return freeProcess && freeProcess.binding && freeProcess.binding('util');\n } catch (e) {}\n}());\n\nmodule.exports = nodeUtil;\n", "var baseIsTypedArray = require('./_baseIsTypedArray'),\n baseUnary = require('./_baseUnary'),\n nodeUtil = require('./_nodeUtil');\n\n/* Node.js helper references. */\nvar nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;\n\n/**\n * Checks if `value` is classified as a typed array.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n * @example\n *\n * _.isTypedArray(new Uint8Array);\n * // => true\n *\n * _.isTypedArray([]);\n * // => false\n */\nvar isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;\n\nmodule.exports = isTypedArray;\n", "var baseTimes = require('./_baseTimes'),\n isArguments = require('./isArguments'),\n isArray = require('./isArray'),\n isBuffer = require('./isBuffer'),\n isIndex = require('./_isIndex'),\n isTypedArray = require('./isTypedArray');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Creates an array of the enumerable property names of the array-like `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @param {boolean} inherited Specify returning inherited property names.\n * @returns {Array} Returns the array of property names.\n */\nfunction arrayLikeKeys(value, inherited) {\n var isArr = isArray(value),\n isArg = !isArr && isArguments(value),\n isBuff = !isArr && !isArg && isBuffer(value),\n isType = !isArr && !isArg && !isBuff && isTypedArray(value),\n skipIndexes = isArr || isArg || isBuff || isType,\n result = skipIndexes ? baseTimes(value.length, String) : [],\n length = result.length;\n\n for (var key in value) {\n if ((inherited || hasOwnProperty.call(value, key)) &&\n !(skipIndexes && (\n // Safari 9 has enumerable `arguments.length` in strict mode.\n key == 'length' ||\n // Node.js 0.10 has enumerable non-index properties on buffers.\n (isBuff && (key == 'offset' || key == 'parent')) ||\n // PhantomJS 2 has enumerable non-index properties on typed arrays.\n (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) ||\n // Skip index properties.\n isIndex(key, length)\n ))) {\n result.push(key);\n }\n }\n return result;\n}\n\nmodule.exports = arrayLikeKeys;\n", "/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Checks if `value` is likely a prototype object.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a prototype, else `false`.\n */\nfunction isPrototype(value) {\n var Ctor = value && value.constructor,\n proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto;\n\n return value === proto;\n}\n\nmodule.exports = isPrototype;\n", "/**\n * Creates a unary function that invokes `func` with its argument transformed.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {Function} transform The argument transform.\n * @returns {Function} Returns the new function.\n */\nfunction overArg(func, transform) {\n return function(arg) {\n return func(transform(arg));\n };\n}\n\nmodule.exports = overArg;\n", "var overArg = require('./_overArg');\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeKeys = overArg(Object.keys, Object);\n\nmodule.exports = nativeKeys;\n", "var isPrototype = require('./_isPrototype'),\n nativeKeys = require('./_nativeKeys');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.keys` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction baseKeys(object) {\n if (!isPrototype(object)) {\n return nativeKeys(object);\n }\n var result = [];\n for (var key in Object(object)) {\n if (hasOwnProperty.call(object, key) && key != 'constructor') {\n result.push(key);\n }\n }\n return result;\n}\n\nmodule.exports = baseKeys;\n", "var isFunction = require('./isFunction'),\n isLength = require('./isLength');\n\n/**\n * Checks if `value` is array-like. A value is considered array-like if it's\n * not a function and has a `value.length` that's an integer greater than or\n * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is array-like, else `false`.\n * @example\n *\n * _.isArrayLike([1, 2, 3]);\n * // => true\n *\n * _.isArrayLike(document.body.children);\n * // => true\n *\n * _.isArrayLike('abc');\n * // => true\n *\n * _.isArrayLike(_.noop);\n * // => false\n */\nfunction isArrayLike(value) {\n return value != null && isLength(value.length) && !isFunction(value);\n}\n\nmodule.exports = isArrayLike;\n", "var arrayLikeKeys = require('./_arrayLikeKeys'),\n baseKeys = require('./_baseKeys'),\n isArrayLike = require('./isArrayLike');\n\n/**\n * Creates an array of the own enumerable property names of `object`.\n *\n * **Note:** Non-object values are coerced to objects. See the\n * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\n * for more details.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.keys(new Foo);\n * // => ['a', 'b'] (iteration order is not guaranteed)\n *\n * _.keys('hi');\n * // => ['0', '1']\n */\nfunction keys(object) {\n return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);\n}\n\nmodule.exports = keys;\n", "var baseFor = require('./_baseFor'),\n keys = require('./keys');\n\n/**\n * The base implementation of `_.forOwn` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Object} Returns `object`.\n */\nfunction baseForOwn(object, iteratee) {\n return object && baseFor(object, iteratee, keys);\n}\n\nmodule.exports = baseForOwn;\n", "var ListCache = require('./_ListCache');\n\n/**\n * Removes all key-value entries from the stack.\n *\n * @private\n * @name clear\n * @memberOf Stack\n */\nfunction stackClear() {\n this.__data__ = new ListCache;\n this.size = 0;\n}\n\nmodule.exports = stackClear;\n", "/**\n * Removes `key` and its value from the stack.\n *\n * @private\n * @name delete\n * @memberOf Stack\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction stackDelete(key) {\n var data = this.__data__,\n result = data['delete'](key);\n\n this.size = data.size;\n return result;\n}\n\nmodule.exports = stackDelete;\n", "/**\n * Gets the stack value for `key`.\n *\n * @private\n * @name get\n * @memberOf Stack\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction stackGet(key) {\n return this.__data__.get(key);\n}\n\nmodule.exports = stackGet;\n", "/**\n * Checks if a stack value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Stack\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction stackHas(key) {\n return this.__data__.has(key);\n}\n\nmodule.exports = stackHas;\n", "var ListCache = require('./_ListCache'),\n Map = require('./_Map'),\n MapCache = require('./_MapCache');\n\n/** Used as the size to enable large array optimizations. */\nvar LARGE_ARRAY_SIZE = 200;\n\n/**\n * Sets the stack `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Stack\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the stack cache instance.\n */\nfunction stackSet(key, value) {\n var data = this.__data__;\n if (data instanceof ListCache) {\n var pairs = data.__data__;\n if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) {\n pairs.push([key, value]);\n this.size = ++data.size;\n return this;\n }\n data = this.__data__ = new MapCache(pairs);\n }\n data.set(key, value);\n this.size = data.size;\n return this;\n}\n\nmodule.exports = stackSet;\n", "var ListCache = require('./_ListCache'),\n stackClear = require('./_stackClear'),\n stackDelete = require('./_stackDelete'),\n stackGet = require('./_stackGet'),\n stackHas = require('./_stackHas'),\n stackSet = require('./_stackSet');\n\n/**\n * Creates a stack cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Stack(entries) {\n var data = this.__data__ = new ListCache(entries);\n this.size = data.size;\n}\n\n// Add methods to `Stack`.\nStack.prototype.clear = stackClear;\nStack.prototype['delete'] = stackDelete;\nStack.prototype.get = stackGet;\nStack.prototype.has = stackHas;\nStack.prototype.set = stackSet;\n\nmodule.exports = Stack;\n", "/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Adds `value` to the array cache.\n *\n * @private\n * @name add\n * @memberOf SetCache\n * @alias push\n * @param {*} value The value to cache.\n * @returns {Object} Returns the cache instance.\n */\nfunction setCacheAdd(value) {\n this.__data__.set(value, HASH_UNDEFINED);\n return this;\n}\n\nmodule.exports = setCacheAdd;\n", "/**\n * Checks if `value` is in the array cache.\n *\n * @private\n * @name has\n * @memberOf SetCache\n * @param {*} value The value to search for.\n * @returns {number} Returns `true` if `value` is found, else `false`.\n */\nfunction setCacheHas(value) {\n return this.__data__.has(value);\n}\n\nmodule.exports = setCacheHas;\n", "var MapCache = require('./_MapCache'),\n setCacheAdd = require('./_setCacheAdd'),\n setCacheHas = require('./_setCacheHas');\n\n/**\n *\n * Creates an array cache object to store unique values.\n *\n * @private\n * @constructor\n * @param {Array} [values] The values to cache.\n */\nfunction SetCache(values) {\n var index = -1,\n length = values == null ? 0 : values.length;\n\n this.__data__ = new MapCache;\n while (++index < length) {\n this.add(values[index]);\n }\n}\n\n// Add methods to `SetCache`.\nSetCache.prototype.add = SetCache.prototype.push = setCacheAdd;\nSetCache.prototype.has = setCacheHas;\n\nmodule.exports = SetCache;\n", "/**\n * A specialized version of `_.some` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {boolean} Returns `true` if any element passes the predicate check,\n * else `false`.\n */\nfunction arraySome(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n while (++index < length) {\n if (predicate(array[index], index, array)) {\n return true;\n }\n }\n return false;\n}\n\nmodule.exports = arraySome;\n", "/**\n * Checks if a `cache` value for `key` exists.\n *\n * @private\n * @param {Object} cache The cache to query.\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction cacheHas(cache, key) {\n return cache.has(key);\n}\n\nmodule.exports = cacheHas;\n", "var SetCache = require('./_SetCache'),\n arraySome = require('./_arraySome'),\n cacheHas = require('./_cacheHas');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * A specialized version of `baseIsEqualDeep` for arrays with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Array} array The array to compare.\n * @param {Array} other The other array to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `array` and `other` objects.\n * @returns {boolean} Returns `true` if the arrays are equivalent, else `false`.\n */\nfunction equalArrays(array, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n arrLength = array.length,\n othLength = other.length;\n\n if (arrLength != othLength && !(isPartial && othLength > arrLength)) {\n return false;\n }\n // Check that cyclic values are equal.\n var arrStacked = stack.get(array);\n var othStacked = stack.get(other);\n if (arrStacked && othStacked) {\n return arrStacked == other && othStacked == array;\n }\n var index = -1,\n result = true,\n seen = (bitmask & COMPARE_UNORDERED_FLAG) ? new SetCache : undefined;\n\n stack.set(array, other);\n stack.set(other, array);\n\n // Ignore non-index properties.\n while (++index < arrLength) {\n var arrValue = array[index],\n othValue = other[index];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, arrValue, index, other, array, stack)\n : customizer(arrValue, othValue, index, array, other, stack);\n }\n if (compared !== undefined) {\n if (compared) {\n continue;\n }\n result = false;\n break;\n }\n // Recursively compare arrays (susceptible to call stack limits).\n if (seen) {\n if (!arraySome(other, function(othValue, othIndex) {\n if (!cacheHas(seen, othIndex) &&\n (arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {\n return seen.push(othIndex);\n }\n })) {\n result = false;\n break;\n }\n } else if (!(\n arrValue === othValue ||\n equalFunc(arrValue, othValue, bitmask, customizer, stack)\n )) {\n result = false;\n break;\n }\n }\n stack['delete'](array);\n stack['delete'](other);\n return result;\n}\n\nmodule.exports = equalArrays;\n", "var root = require('./_root');\n\n/** Built-in value references. */\nvar Uint8Array = root.Uint8Array;\n\nmodule.exports = Uint8Array;\n", "/**\n * Converts `map` to its key-value pairs.\n *\n * @private\n * @param {Object} map The map to convert.\n * @returns {Array} Returns the key-value pairs.\n */\nfunction mapToArray(map) {\n var index = -1,\n result = Array(map.size);\n\n map.forEach(function(value, key) {\n result[++index] = [key, value];\n });\n return result;\n}\n\nmodule.exports = mapToArray;\n", "/**\n * Converts `set` to an array of its values.\n *\n * @private\n * @param {Object} set The set to convert.\n * @returns {Array} Returns the values.\n */\nfunction setToArray(set) {\n var index = -1,\n result = Array(set.size);\n\n set.forEach(function(value) {\n result[++index] = value;\n });\n return result;\n}\n\nmodule.exports = setToArray;\n", "var Symbol = require('./_Symbol'),\n Uint8Array = require('./_Uint8Array'),\n eq = require('./eq'),\n equalArrays = require('./_equalArrays'),\n mapToArray = require('./_mapToArray'),\n setToArray = require('./_setToArray');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/** `Object#toString` result references. */\nvar boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n symbolTag = '[object Symbol]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]';\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolValueOf = symbolProto ? symbolProto.valueOf : undefined;\n\n/**\n * A specialized version of `baseIsEqualDeep` for comparing objects of\n * the same `toStringTag`.\n *\n * **Note:** This function only supports comparing values with tags of\n * `Boolean`, `Date`, `Error`, `Number`, `RegExp`, or `String`.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {string} tag The `toStringTag` of the objects to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalByTag(object, other, tag, bitmask, customizer, equalFunc, stack) {\n switch (tag) {\n case dataViewTag:\n if ((object.byteLength != other.byteLength) ||\n (object.byteOffset != other.byteOffset)) {\n return false;\n }\n object = object.buffer;\n other = other.buffer;\n\n case arrayBufferTag:\n if ((object.byteLength != other.byteLength) ||\n !equalFunc(new Uint8Array(object), new Uint8Array(other))) {\n return false;\n }\n return true;\n\n case boolTag:\n case dateTag:\n case numberTag:\n // Coerce booleans to `1` or `0` and dates to milliseconds.\n // Invalid dates are coerced to `NaN`.\n return eq(+object, +other);\n\n case errorTag:\n return object.name == other.name && object.message == other.message;\n\n case regexpTag:\n case stringTag:\n // Coerce regexes to strings and treat strings, primitives and objects,\n // as equal. See http://www.ecma-international.org/ecma-262/7.0/#sec-regexp.prototype.tostring\n // for more details.\n return object == (other + '');\n\n case mapTag:\n var convert = mapToArray;\n\n case setTag:\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG;\n convert || (convert = setToArray);\n\n if (object.size != other.size && !isPartial) {\n return false;\n }\n // Assume cyclic values are equal.\n var stacked = stack.get(object);\n if (stacked) {\n return stacked == other;\n }\n bitmask |= COMPARE_UNORDERED_FLAG;\n\n // Recursively compare objects (susceptible to call stack limits).\n stack.set(object, other);\n var result = equalArrays(convert(object), convert(other), bitmask, customizer, equalFunc, stack);\n stack['delete'](object);\n return result;\n\n case symbolTag:\n if (symbolValueOf) {\n return symbolValueOf.call(object) == symbolValueOf.call(other);\n }\n }\n return false;\n}\n\nmodule.exports = equalByTag;\n", "var arrayPush = require('./_arrayPush'),\n isArray = require('./isArray');\n\n/**\n * The base implementation of `getAllKeys` and `getAllKeysIn` which uses\n * `keysFunc` and `symbolsFunc` to get the enumerable property names and\n * symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @param {Function} symbolsFunc The function to get the symbols of `object`.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction baseGetAllKeys(object, keysFunc, symbolsFunc) {\n var result = keysFunc(object);\n return isArray(object) ? result : arrayPush(result, symbolsFunc(object));\n}\n\nmodule.exports = baseGetAllKeys;\n", "/**\n * A specialized version of `_.filter` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {Array} Returns the new filtered array.\n */\nfunction arrayFilter(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length,\n resIndex = 0,\n result = [];\n\n while (++index < length) {\n var value = array[index];\n if (predicate(value, index, array)) {\n result[resIndex++] = value;\n }\n }\n return result;\n}\n\nmodule.exports = arrayFilter;\n", "/**\n * This method returns a new empty array.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {Array} Returns the new empty array.\n * @example\n *\n * var arrays = _.times(2, _.stubArray);\n *\n * console.log(arrays);\n * // => [[], []]\n *\n * console.log(arrays[0] === arrays[1]);\n * // => false\n */\nfunction stubArray() {\n return [];\n}\n\nmodule.exports = stubArray;\n", "var arrayFilter = require('./_arrayFilter'),\n stubArray = require('./stubArray');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeGetSymbols = Object.getOwnPropertySymbols;\n\n/**\n * Creates an array of the own enumerable symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of symbols.\n */\nvar getSymbols = !nativeGetSymbols ? stubArray : function(object) {\n if (object == null) {\n return [];\n }\n object = Object(object);\n return arrayFilter(nativeGetSymbols(object), function(symbol) {\n return propertyIsEnumerable.call(object, symbol);\n });\n};\n\nmodule.exports = getSymbols;\n", "var baseGetAllKeys = require('./_baseGetAllKeys'),\n getSymbols = require('./_getSymbols'),\n keys = require('./keys');\n\n/**\n * Creates an array of own enumerable property names and symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction getAllKeys(object) {\n return baseGetAllKeys(object, keys, getSymbols);\n}\n\nmodule.exports = getAllKeys;\n", "var getAllKeys = require('./_getAllKeys');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqualDeep` for objects with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalObjects(object, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n objProps = getAllKeys(object),\n objLength = objProps.length,\n othProps = getAllKeys(other),\n othLength = othProps.length;\n\n if (objLength != othLength && !isPartial) {\n return false;\n }\n var index = objLength;\n while (index--) {\n var key = objProps[index];\n if (!(isPartial ? key in other : hasOwnProperty.call(other, key))) {\n return false;\n }\n }\n // Check that cyclic values are equal.\n var objStacked = stack.get(object);\n var othStacked = stack.get(other);\n if (objStacked && othStacked) {\n return objStacked == other && othStacked == object;\n }\n var result = true;\n stack.set(object, other);\n stack.set(other, object);\n\n var skipCtor = isPartial;\n while (++index < objLength) {\n key = objProps[index];\n var objValue = object[key],\n othValue = other[key];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, objValue, key, other, object, stack)\n : customizer(objValue, othValue, key, object, other, stack);\n }\n // Recursively compare objects (susceptible to call stack limits).\n if (!(compared === undefined\n ? (objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack))\n : compared\n )) {\n result = false;\n break;\n }\n skipCtor || (skipCtor = key == 'constructor');\n }\n if (result && !skipCtor) {\n var objCtor = object.constructor,\n othCtor = other.constructor;\n\n // Non `Object` object instances with different constructors are not equal.\n if (objCtor != othCtor &&\n ('constructor' in object && 'constructor' in other) &&\n !(typeof objCtor == 'function' && objCtor instanceof objCtor &&\n typeof othCtor == 'function' && othCtor instanceof othCtor)) {\n result = false;\n }\n }\n stack['delete'](object);\n stack['delete'](other);\n return result;\n}\n\nmodule.exports = equalObjects;\n", "var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar DataView = getNative(root, 'DataView');\n\nmodule.exports = DataView;\n", "var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Promise = getNative(root, 'Promise');\n\nmodule.exports = Promise;\n", "var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Set = getNative(root, 'Set');\n\nmodule.exports = Set;\n", "var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar WeakMap = getNative(root, 'WeakMap');\n\nmodule.exports = WeakMap;\n", "var DataView = require('./_DataView'),\n Map = require('./_Map'),\n Promise = require('./_Promise'),\n Set = require('./_Set'),\n WeakMap = require('./_WeakMap'),\n baseGetTag = require('./_baseGetTag'),\n toSource = require('./_toSource');\n\n/** `Object#toString` result references. */\nvar mapTag = '[object Map]',\n objectTag = '[object Object]',\n promiseTag = '[object Promise]',\n setTag = '[object Set]',\n weakMapTag = '[object WeakMap]';\n\nvar dataViewTag = '[object DataView]';\n\n/** Used to detect maps, sets, and weakmaps. */\nvar dataViewCtorString = toSource(DataView),\n mapCtorString = toSource(Map),\n promiseCtorString = toSource(Promise),\n setCtorString = toSource(Set),\n weakMapCtorString = toSource(WeakMap);\n\n/**\n * Gets the `toStringTag` of `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nvar getTag = baseGetTag;\n\n// Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.\nif ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) ||\n (Map && getTag(new Map) != mapTag) ||\n (Promise && getTag(Promise.resolve()) != promiseTag) ||\n (Set && getTag(new Set) != setTag) ||\n (WeakMap && getTag(new WeakMap) != weakMapTag)) {\n getTag = function(value) {\n var result = baseGetTag(value),\n Ctor = result == objectTag ? value.constructor : undefined,\n ctorString = Ctor ? toSource(Ctor) : '';\n\n if (ctorString) {\n switch (ctorString) {\n case dataViewCtorString: return dataViewTag;\n case mapCtorString: return mapTag;\n case promiseCtorString: return promiseTag;\n case setCtorString: return setTag;\n case weakMapCtorString: return weakMapTag;\n }\n }\n return result;\n };\n}\n\nmodule.exports = getTag;\n", "var Stack = require('./_Stack'),\n equalArrays = require('./_equalArrays'),\n equalByTag = require('./_equalByTag'),\n equalObjects = require('./_equalObjects'),\n getTag = require('./_getTag'),\n isArray = require('./isArray'),\n isBuffer = require('./isBuffer'),\n isTypedArray = require('./isTypedArray');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n objectTag = '[object Object]';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqual` for arrays and objects which performs\n * deep comparisons and tracks traversed objects enabling objects with circular\n * references to be compared.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} [stack] Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction baseIsEqualDeep(object, other, bitmask, customizer, equalFunc, stack) {\n var objIsArr = isArray(object),\n othIsArr = isArray(other),\n objTag = objIsArr ? arrayTag : getTag(object),\n othTag = othIsArr ? arrayTag : getTag(other);\n\n objTag = objTag == argsTag ? objectTag : objTag;\n othTag = othTag == argsTag ? objectTag : othTag;\n\n var objIsObj = objTag == objectTag,\n othIsObj = othTag == objectTag,\n isSameTag = objTag == othTag;\n\n if (isSameTag && isBuffer(object)) {\n if (!isBuffer(other)) {\n return false;\n }\n objIsArr = true;\n objIsObj = false;\n }\n if (isSameTag && !objIsObj) {\n stack || (stack = new Stack);\n return (objIsArr || isTypedArray(object))\n ? equalArrays(object, other, bitmask, customizer, equalFunc, stack)\n : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);\n }\n if (!(bitmask & COMPARE_PARTIAL_FLAG)) {\n var objIsWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'),\n othIsWrapped = othIsObj && hasOwnProperty.call(other, '__wrapped__');\n\n if (objIsWrapped || othIsWrapped) {\n var objUnwrapped = objIsWrapped ? object.value() : object,\n othUnwrapped = othIsWrapped ? other.value() : other;\n\n stack || (stack = new Stack);\n return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);\n }\n }\n if (!isSameTag) {\n return false;\n }\n stack || (stack = new Stack);\n return equalObjects(object, other, bitmask, customizer, equalFunc, stack);\n}\n\nmodule.exports = baseIsEqualDeep;\n", "var baseIsEqualDeep = require('./_baseIsEqualDeep'),\n isObjectLike = require('./isObjectLike');\n\n/**\n * The base implementation of `_.isEqual` which supports partial comparisons\n * and tracks traversed objects.\n *\n * @private\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @param {boolean} bitmask The bitmask flags.\n * 1 - Unordered comparison\n * 2 - Partial comparison\n * @param {Function} [customizer] The function to customize comparisons.\n * @param {Object} [stack] Tracks traversed `value` and `other` objects.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n */\nfunction baseIsEqual(value, other, bitmask, customizer, stack) {\n if (value === other) {\n return true;\n }\n if (value == null || other == null || (!isObjectLike(value) && !isObjectLike(other))) {\n return value !== value && other !== other;\n }\n return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack);\n}\n\nmodule.exports = baseIsEqual;\n", "var Stack = require('./_Stack'),\n baseIsEqual = require('./_baseIsEqual');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * The base implementation of `_.isMatch` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The object to inspect.\n * @param {Object} source The object of property values to match.\n * @param {Array} matchData The property names, values, and compare flags to match.\n * @param {Function} [customizer] The function to customize comparisons.\n * @returns {boolean} Returns `true` if `object` is a match, else `false`.\n */\nfunction baseIsMatch(object, source, matchData, customizer) {\n var index = matchData.length,\n length = index,\n noCustomizer = !customizer;\n\n if (object == null) {\n return !length;\n }\n object = Object(object);\n while (index--) {\n var data = matchData[index];\n if ((noCustomizer && data[2])\n ? data[1] !== object[data[0]]\n : !(data[0] in object)\n ) {\n return false;\n }\n }\n while (++index < length) {\n data = matchData[index];\n var key = data[0],\n objValue = object[key],\n srcValue = data[1];\n\n if (noCustomizer && data[2]) {\n if (objValue === undefined && !(key in object)) {\n return false;\n }\n } else {\n var stack = new Stack;\n if (customizer) {\n var result = customizer(objValue, srcValue, key, object, source, stack);\n }\n if (!(result === undefined\n ? baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG, customizer, stack)\n : result\n )) {\n return false;\n }\n }\n }\n return true;\n}\n\nmodule.exports = baseIsMatch;\n", "var isObject = require('./isObject');\n\n/**\n * Checks if `value` is suitable for strict equality comparisons, i.e. `===`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` if suitable for strict\n * equality comparisons, else `false`.\n */\nfunction isStrictComparable(value) {\n return value === value && !isObject(value);\n}\n\nmodule.exports = isStrictComparable;\n", "var isStrictComparable = require('./_isStrictComparable'),\n keys = require('./keys');\n\n/**\n * Gets the property names, values, and compare flags of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the match data of `object`.\n */\nfunction getMatchData(object) {\n var result = keys(object),\n length = result.length;\n\n while (length--) {\n var key = result[length],\n value = object[key];\n\n result[length] = [key, value, isStrictComparable(value)];\n }\n return result;\n}\n\nmodule.exports = getMatchData;\n", "/**\n * A specialized version of `matchesProperty` for source values suitable\n * for strict equality comparisons, i.e. `===`.\n *\n * @private\n * @param {string} key The key of the property to get.\n * @param {*} srcValue The value to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction matchesStrictComparable(key, srcValue) {\n return function(object) {\n if (object == null) {\n return false;\n }\n return object[key] === srcValue &&\n (srcValue !== undefined || (key in Object(object)));\n };\n}\n\nmodule.exports = matchesStrictComparable;\n", "var baseIsMatch = require('./_baseIsMatch'),\n getMatchData = require('./_getMatchData'),\n matchesStrictComparable = require('./_matchesStrictComparable');\n\n/**\n * The base implementation of `_.matches` which doesn't clone `source`.\n *\n * @private\n * @param {Object} source The object of property values to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction baseMatches(source) {\n var matchData = getMatchData(source);\n if (matchData.length == 1 && matchData[0][2]) {\n return matchesStrictComparable(matchData[0][0], matchData[0][1]);\n }\n return function(object) {\n return object === source || baseIsMatch(object, source, matchData);\n };\n}\n\nmodule.exports = baseMatches;\n", "var baseIsEqual = require('./_baseIsEqual'),\n get = require('./get'),\n hasIn = require('./hasIn'),\n isKey = require('./_isKey'),\n isStrictComparable = require('./_isStrictComparable'),\n matchesStrictComparable = require('./_matchesStrictComparable'),\n toKey = require('./_toKey');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * The base implementation of `_.matchesProperty` which doesn't clone `srcValue`.\n *\n * @private\n * @param {string} path The path of the property to get.\n * @param {*} srcValue The value to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction baseMatchesProperty(path, srcValue) {\n if (isKey(path) && isStrictComparable(srcValue)) {\n return matchesStrictComparable(toKey(path), srcValue);\n }\n return function(object) {\n var objValue = get(object, path);\n return (objValue === undefined && objValue === srcValue)\n ? hasIn(object, path)\n : baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG);\n };\n}\n\nmodule.exports = baseMatchesProperty;\n", "/**\n * The base implementation of `_.property` without support for deep paths.\n *\n * @private\n * @param {string} key The key of the property to get.\n * @returns {Function} Returns the new accessor function.\n */\nfunction baseProperty(key) {\n return function(object) {\n return object == null ? undefined : object[key];\n };\n}\n\nmodule.exports = baseProperty;\n", "var baseGet = require('./_baseGet');\n\n/**\n * A specialized version of `baseProperty` which supports deep paths.\n *\n * @private\n * @param {Array|string} path The path of the property to get.\n * @returns {Function} Returns the new accessor function.\n */\nfunction basePropertyDeep(path) {\n return function(object) {\n return baseGet(object, path);\n };\n}\n\nmodule.exports = basePropertyDeep;\n", "var baseProperty = require('./_baseProperty'),\n basePropertyDeep = require('./_basePropertyDeep'),\n isKey = require('./_isKey'),\n toKey = require('./_toKey');\n\n/**\n * Creates a function that returns the value at `path` of a given object.\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Util\n * @param {Array|string} path The path of the property to get.\n * @returns {Function} Returns the new accessor function.\n * @example\n *\n * var objects = [\n * { 'a': { 'b': 2 } },\n * { 'a': { 'b': 1 } }\n * ];\n *\n * _.map(objects, _.property('a.b'));\n * // => [2, 1]\n *\n * _.map(_.sortBy(objects, _.property(['a', 'b'])), 'a.b');\n * // => [1, 2]\n */\nfunction property(path) {\n return isKey(path) ? baseProperty(toKey(path)) : basePropertyDeep(path);\n}\n\nmodule.exports = property;\n", "var baseMatches = require('./_baseMatches'),\n baseMatchesProperty = require('./_baseMatchesProperty'),\n identity = require('./identity'),\n isArray = require('./isArray'),\n property = require('./property');\n\n/**\n * The base implementation of `_.iteratee`.\n *\n * @private\n * @param {*} [value=_.identity] The value to convert to an iteratee.\n * @returns {Function} Returns the iteratee.\n */\nfunction baseIteratee(value) {\n // Don't store the `typeof` result in a variable to avoid a JIT bug in Safari 9.\n // See https://bugs.webkit.org/show_bug.cgi?id=156034 for more details.\n if (typeof value == 'function') {\n return value;\n }\n if (value == null) {\n return identity;\n }\n if (typeof value == 'object') {\n return isArray(value)\n ? baseMatchesProperty(value[0], value[1])\n : baseMatches(value);\n }\n return property(value);\n}\n\nmodule.exports = baseIteratee;\n", "var baseAssignValue = require('./_baseAssignValue'),\n baseForOwn = require('./_baseForOwn'),\n baseIteratee = require('./_baseIteratee');\n\n/**\n * Creates an object with the same keys as `object` and values generated\n * by running each own enumerable string keyed property of `object` thru\n * `iteratee`. The iteratee is invoked with three arguments:\n * (value, key, object).\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Object} Returns the new mapped object.\n * @see _.mapKeys\n * @example\n *\n * var users = {\n * 'fred': { 'user': 'fred', 'age': 40 },\n * 'pebbles': { 'user': 'pebbles', 'age': 1 }\n * };\n *\n * _.mapValues(users, function(o) { return o.age; });\n * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed)\n *\n * // The `_.property` iteratee shorthand.\n * _.mapValues(users, 'age');\n * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed)\n */\nfunction mapValues(object, iteratee) {\n var result = {};\n iteratee = baseIteratee(iteratee, 3);\n\n baseForOwn(object, function(value, key, object) {\n baseAssignValue(result, key, iteratee(value, key, object));\n });\n return result;\n}\n\nmodule.exports = mapValues;\n", "/**\n * Based on Kendo UI Core expression code \n */\n'use strict'\n\nfunction Cache(maxSize) {\n this._maxSize = maxSize\n this.clear()\n}\nCache.prototype.clear = function () {\n this._size = 0\n this._values = Object.create(null)\n}\nCache.prototype.get = function (key) {\n return this._values[key]\n}\nCache.prototype.set = function (key, value) {\n this._size >= this._maxSize && this.clear()\n if (!(key in this._values)) this._size++\n\n return (this._values[key] = value)\n}\n\nvar SPLIT_REGEX = /[^.^\\]^[]+|(?=\\[\\]|\\.\\.)/g,\n DIGIT_REGEX = /^\\d+$/,\n LEAD_DIGIT_REGEX = /^\\d/,\n SPEC_CHAR_REGEX = /[~`!#$%\\^&*+=\\-\\[\\]\\\\';,/{}|\\\\\":<>\\?]/g,\n CLEAN_QUOTES_REGEX = /^\\s*(['\"]?)(.*?)(\\1)\\s*$/,\n MAX_CACHE_SIZE = 512\n\nvar pathCache = new Cache(MAX_CACHE_SIZE),\n setCache = new Cache(MAX_CACHE_SIZE),\n getCache = new Cache(MAX_CACHE_SIZE)\n\nvar config\n\nmodule.exports = {\n Cache: Cache,\n\n split: split,\n\n normalizePath: normalizePath,\n\n setter: function (path) {\n var parts = normalizePath(path)\n\n return (\n setCache.get(path) ||\n setCache.set(path, function setter(obj, value) {\n var index = 0\n var len = parts.length\n var data = obj\n\n while (index < len - 1) {\n var part = parts[index]\n if (\n part === '__proto__' ||\n part === 'constructor' ||\n part === 'prototype'\n ) {\n return obj\n }\n\n data = data[parts[index++]]\n }\n data[parts[index]] = value\n })\n )\n },\n\n getter: function (path, safe) {\n var parts = normalizePath(path)\n return (\n getCache.get(path) ||\n getCache.set(path, function getter(data) {\n var index = 0,\n len = parts.length\n while (index < len) {\n if (data != null || !safe) data = data[parts[index++]]\n else return\n }\n return data\n })\n )\n },\n\n join: function (segments) {\n return segments.reduce(function (path, part) {\n return (\n path +\n (isQuoted(part) || DIGIT_REGEX.test(part)\n ? '[' + part + ']'\n : (path ? '.' : '') + part)\n )\n }, '')\n },\n\n forEach: function (path, cb, thisArg) {\n forEach(Array.isArray(path) ? path : split(path), cb, thisArg)\n },\n}\n\nfunction normalizePath(path) {\n return (\n pathCache.get(path) ||\n pathCache.set(\n path,\n split(path).map(function (part) {\n return part.replace(CLEAN_QUOTES_REGEX, '$2')\n })\n )\n )\n}\n\nfunction split(path) {\n return path.match(SPLIT_REGEX)\n}\n\nfunction forEach(parts, iter, thisArg) {\n var len = parts.length,\n part,\n idx,\n isArray,\n isBracket\n\n for (idx = 0; idx < len; idx++) {\n part = parts[idx]\n\n if (part) {\n if (shouldBeQuoted(part)) {\n part = '\"' + part + '\"'\n }\n\n isBracket = isQuoted(part)\n isArray = !isBracket && /^\\d+$/.test(part)\n\n iter.call(thisArg, part, isBracket, isArray, idx, parts)\n }\n }\n}\n\nfunction isQuoted(str) {\n return (\n typeof str === 'string' && str && [\"'\", '\"'].indexOf(str.charAt(0)) !== -1\n )\n}\n\nfunction hasLeadingNumber(part) {\n return part.match(LEAD_DIGIT_REGEX) && !part.match(DIGIT_REGEX)\n}\n\nfunction hasSpecialChars(part) {\n return SPEC_CHAR_REGEX.test(part)\n}\n\nfunction shouldBeQuoted(part) {\n return !isQuoted(part) && (hasLeadingNumber(part) || hasSpecialChars(part))\n}\n", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.create = create;\nexports.default = void 0;\n\nvar _propertyExpr = require(\"property-expr\");\n\nconst prefixes = {\n context: '$',\n value: '.'\n};\n\nfunction create(key, options) {\n return new Reference(key, options);\n}\n\nclass Reference {\n constructor(key, options = {}) {\n if (typeof key !== 'string') throw new TypeError('ref must be a string, got: ' + key);\n this.key = key.trim();\n if (key === '') throw new TypeError('ref must be a non-empty string');\n this.isContext = this.key[0] === prefixes.context;\n this.isValue = this.key[0] === prefixes.value;\n this.isSibling = !this.isContext && !this.isValue;\n let prefix = this.isContext ? prefixes.context : this.isValue ? prefixes.value : '';\n this.path = this.key.slice(prefix.length);\n this.getter = this.path && (0, _propertyExpr.getter)(this.path, true);\n this.map = options.map;\n }\n\n getValue(value, parent, context) {\n let result = this.isContext ? context : this.isValue ? value : parent;\n if (this.getter) result = this.getter(result || {});\n if (this.map) result = this.map(result);\n return result;\n }\n /**\n *\n * @param {*} value\n * @param {Object} options\n * @param {Object=} options.context\n * @param {Object=} options.parent\n */\n\n\n cast(value, options) {\n return this.getValue(value, options == null ? void 0 : options.parent, options == null ? void 0 : options.context);\n }\n\n resolve() {\n return this;\n }\n\n describe() {\n return {\n type: 'ref',\n key: this.key\n };\n }\n\n toString() {\n return `Ref(${this.key})`;\n }\n\n static isRef(value) {\n return value && value.__isYupRef;\n }\n\n} // @ts-ignore\n\n\nexports.default = Reference;\nReference.prototype.__isYupRef = true;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = createValidation;\n\nvar _mapValues = _interopRequireDefault(require(\"lodash/mapValues\"));\n\nvar _ValidationError = _interopRequireDefault(require(\"../ValidationError\"));\n\nvar _Reference = _interopRequireDefault(require(\"../Reference\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n\nfunction createValidation(config) {\n function validate(_ref, cb) {\n let {\n value,\n path = '',\n label,\n options,\n originalValue,\n sync\n } = _ref,\n rest = _objectWithoutPropertiesLoose(_ref, [\"value\", \"path\", \"label\", \"options\", \"originalValue\", \"sync\"]);\n\n const {\n name,\n test,\n params,\n message\n } = config;\n let {\n parent,\n context\n } = options;\n\n function resolve(item) {\n return _Reference.default.isRef(item) ? item.getValue(value, parent, context) : item;\n }\n\n function createError(overrides = {}) {\n const nextParams = (0, _mapValues.default)(_extends({\n value,\n originalValue,\n label,\n path: overrides.path || path\n }, params, overrides.params), resolve);\n const error = new _ValidationError.default(_ValidationError.default.formatError(overrides.message || message, nextParams), value, nextParams.path, overrides.type || name);\n error.params = nextParams;\n return error;\n }\n\n let ctx = _extends({\n path,\n parent,\n type: name,\n createError,\n resolve,\n options,\n originalValue\n }, rest);\n\n if (!sync) {\n try {\n Promise.resolve(test.call(ctx, value, ctx)).then(validOrError => {\n if (_ValidationError.default.isError(validOrError)) cb(validOrError);else if (!validOrError) cb(createError());else cb(null, validOrError);\n });\n } catch (err) {\n cb(err);\n }\n\n return;\n }\n\n let result;\n\n try {\n var _ref2;\n\n result = test.call(ctx, value, ctx);\n\n if (typeof ((_ref2 = result) == null ? void 0 : _ref2.then) === 'function') {\n throw new Error(`Validation test of type: \"${ctx.type}\" returned a Promise during a synchronous validate. ` + `This test will finish after the validate call has returned`);\n }\n } catch (err) {\n cb(err);\n return;\n }\n\n if (_ValidationError.default.isError(result)) cb(result);else if (!result) cb(createError());else cb(null, result);\n }\n\n validate.OPTIONS = config;\n return validate;\n}", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.getIn = getIn;\nexports.default = void 0;\n\nvar _propertyExpr = require(\"property-expr\");\n\nlet trim = part => part.substr(0, part.length - 1).substr(1);\n\nfunction getIn(schema, path, value, context = value) {\n let parent, lastPart, lastPartDebug; // root path: ''\n\n if (!path) return {\n parent,\n parentPath: path,\n schema\n };\n (0, _propertyExpr.forEach)(path, (_part, isBracket, isArray) => {\n let part = isBracket ? trim(_part) : _part;\n schema = schema.resolve({\n context,\n parent,\n value\n });\n\n if (schema.innerType) {\n let idx = isArray ? parseInt(part, 10) : 0;\n\n if (value && idx >= value.length) {\n throw new Error(`Yup.reach cannot resolve an array item at index: ${_part}, in the path: ${path}. ` + `because there is no value at that index. `);\n }\n\n parent = value;\n value = value && value[idx];\n schema = schema.innerType;\n } // sometimes the array index part of a path doesn't exist: \"nested.arr.child\"\n // in these cases the current part is the next schema and should be processed\n // in this iteration. For cases where the index signature is included this\n // check will fail and we'll handle the `child` part on the next iteration like normal\n\n\n if (!isArray) {\n if (!schema.fields || !schema.fields[part]) throw new Error(`The schema does not contain the path: ${path}. ` + `(failed at: ${lastPartDebug} which is a type: \"${schema._type}\")`);\n parent = value;\n value = value && value[part];\n schema = schema.fields[part];\n }\n\n lastPart = part;\n lastPartDebug = isBracket ? '[' + _part + ']' : '.' + _part;\n });\n return {\n schema,\n parent,\n parentPath: lastPart\n };\n}\n\nconst reach = (obj, path, value, context) => getIn(obj, path, value, context).schema;\n\nvar _default = reach;\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _Reference = _interopRequireDefault(require(\"../Reference\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nclass ReferenceSet {\n constructor() {\n this.list = new Set();\n this.refs = new Map();\n }\n\n get size() {\n return this.list.size + this.refs.size;\n }\n\n describe() {\n const description = [];\n\n for (const item of this.list) description.push(item);\n\n for (const [, ref] of this.refs) description.push(ref.describe());\n\n return description;\n }\n\n toArray() {\n return Array.from(this.list).concat(Array.from(this.refs.values()));\n }\n\n add(value) {\n _Reference.default.isRef(value) ? this.refs.set(value.key, value) : this.list.add(value);\n }\n\n delete(value) {\n _Reference.default.isRef(value) ? this.refs.delete(value.key) : this.list.delete(value);\n }\n\n has(value, resolve) {\n if (this.list.has(value)) return true;\n let item,\n values = this.refs.values();\n\n while (item = values.next(), !item.done) if (resolve(item.value) === value) return true;\n\n return false;\n }\n\n clone() {\n const next = new ReferenceSet();\n next.list = new Set(this.list);\n next.refs = new Map(this.refs);\n return next;\n }\n\n merge(newItems, removeItems) {\n const next = this.clone();\n newItems.list.forEach(value => next.add(value));\n newItems.refs.forEach(value => next.add(value));\n removeItems.list.forEach(value => next.delete(value));\n removeItems.refs.forEach(value => next.delete(value));\n return next;\n }\n\n}\n\nexports.default = ReferenceSet;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _nanoclone = _interopRequireDefault(require(\"nanoclone\"));\n\nvar _locale = require(\"./locale\");\n\nvar _Condition = _interopRequireDefault(require(\"./Condition\"));\n\nvar _runTests = _interopRequireDefault(require(\"./util/runTests\"));\n\nvar _createValidation = _interopRequireDefault(require(\"./util/createValidation\"));\n\nvar _printValue = _interopRequireDefault(require(\"./util/printValue\"));\n\nvar _Reference = _interopRequireDefault(require(\"./Reference\"));\n\nvar _reach = require(\"./util/reach\");\n\nvar _toArray = _interopRequireDefault(require(\"./util/toArray\"));\n\nvar _ValidationError = _interopRequireDefault(require(\"./ValidationError\"));\n\nvar _ReferenceSet = _interopRequireDefault(require(\"./util/ReferenceSet\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nclass BaseSchema {\n constructor(options) {\n this.deps = [];\n this.conditions = [];\n this._whitelist = new _ReferenceSet.default();\n this._blacklist = new _ReferenceSet.default();\n this.exclusiveTests = Object.create(null);\n this.tests = [];\n this.transforms = [];\n this.withMutation(() => {\n this.typeError(_locale.mixed.notType);\n });\n this.type = (options == null ? void 0 : options.type) || 'mixed';\n this.spec = _extends({\n strip: false,\n strict: false,\n abortEarly: true,\n recursive: true,\n nullable: false,\n presence: 'optional'\n }, options == null ? void 0 : options.spec);\n } // TODO: remove\n\n\n get _type() {\n return this.type;\n }\n\n _typeCheck(_value) {\n return true;\n }\n\n clone(spec) {\n if (this._mutate) {\n if (spec) Object.assign(this.spec, spec);\n return this;\n } // if the nested value is a schema we can skip cloning, since\n // they are already immutable\n\n\n const next = Object.create(Object.getPrototypeOf(this)); // @ts-expect-error this is readonly\n\n next.type = this.type;\n next._typeError = this._typeError;\n next._whitelistError = this._whitelistError;\n next._blacklistError = this._blacklistError;\n next._whitelist = this._whitelist.clone();\n next._blacklist = this._blacklist.clone();\n next.exclusiveTests = _extends({}, this.exclusiveTests); // @ts-expect-error this is readonly\n\n next.deps = [...this.deps];\n next.conditions = [...this.conditions];\n next.tests = [...this.tests];\n next.transforms = [...this.transforms];\n next.spec = (0, _nanoclone.default)(_extends({}, this.spec, spec));\n return next;\n }\n\n label(label) {\n var next = this.clone();\n next.spec.label = label;\n return next;\n }\n\n meta(...args) {\n if (args.length === 0) return this.spec.meta;\n let next = this.clone();\n next.spec.meta = Object.assign(next.spec.meta || {}, args[0]);\n return next;\n } // withContext(): BaseSchema<\n // TCast,\n // TContext,\n // TOutput\n // > {\n // return this as any;\n // }\n\n\n withMutation(fn) {\n let before = this._mutate;\n this._mutate = true;\n let result = fn(this);\n this._mutate = before;\n return result;\n }\n\n concat(schema) {\n if (!schema || schema === this) return this;\n if (schema.type !== this.type && this.type !== 'mixed') throw new TypeError(`You cannot \\`concat()\\` schema's of different types: ${this.type} and ${schema.type}`);\n let base = this;\n let combined = schema.clone();\n\n const mergedSpec = _extends({}, base.spec, combined.spec); // if (combined.spec.nullable === UNSET)\n // mergedSpec.nullable = base.spec.nullable;\n // if (combined.spec.presence === UNSET)\n // mergedSpec.presence = base.spec.presence;\n\n\n combined.spec = mergedSpec;\n combined._typeError || (combined._typeError = base._typeError);\n combined._whitelistError || (combined._whitelistError = base._whitelistError);\n combined._blacklistError || (combined._blacklistError = base._blacklistError); // manually merge the blacklist/whitelist (the other `schema` takes\n // precedence in case of conflicts)\n\n combined._whitelist = base._whitelist.merge(schema._whitelist, schema._blacklist);\n combined._blacklist = base._blacklist.merge(schema._blacklist, schema._whitelist); // start with the current tests\n\n combined.tests = base.tests;\n combined.exclusiveTests = base.exclusiveTests; // manually add the new tests to ensure\n // the deduping logic is consistent\n\n combined.withMutation(next => {\n schema.tests.forEach(fn => {\n next.test(fn.OPTIONS);\n });\n });\n return combined;\n }\n\n isType(v) {\n if (this.spec.nullable && v === null) return true;\n return this._typeCheck(v);\n }\n\n resolve(options) {\n let schema = this;\n\n if (schema.conditions.length) {\n let conditions = schema.conditions;\n schema = schema.clone();\n schema.conditions = [];\n schema = conditions.reduce((schema, condition) => condition.resolve(schema, options), schema);\n schema = schema.resolve(options);\n }\n\n return schema;\n }\n /**\n *\n * @param {*} value\n * @param {Object} options\n * @param {*=} options.parent\n * @param {*=} options.context\n */\n\n\n cast(value, options = {}) {\n let resolvedSchema = this.resolve(_extends({\n value\n }, options));\n\n let result = resolvedSchema._cast(value, options);\n\n if (value !== undefined && options.assert !== false && resolvedSchema.isType(result) !== true) {\n let formattedValue = (0, _printValue.default)(value);\n let formattedResult = (0, _printValue.default)(result);\n throw new TypeError(`The value of ${options.path || 'field'} could not be cast to a value ` + `that satisfies the schema type: \"${resolvedSchema._type}\". \\n\\n` + `attempted value: ${formattedValue} \\n` + (formattedResult !== formattedValue ? `result of cast: ${formattedResult}` : ''));\n }\n\n return result;\n }\n\n _cast(rawValue, _options) {\n let value = rawValue === undefined ? rawValue : this.transforms.reduce((value, fn) => fn.call(this, value, rawValue, this), rawValue);\n\n if (value === undefined) {\n value = this.getDefault();\n }\n\n return value;\n }\n\n _validate(_value, options = {}, cb) {\n let {\n sync,\n path,\n from = [],\n originalValue = _value,\n strict = this.spec.strict,\n abortEarly = this.spec.abortEarly\n } = options;\n let value = _value;\n\n if (!strict) {\n // this._validating = true;\n value = this._cast(value, _extends({\n assert: false\n }, options)); // this._validating = false;\n } // value is cast, we can check if it meets type requirements\n\n\n let args = {\n value,\n path,\n options,\n originalValue,\n schema: this,\n label: this.spec.label,\n sync,\n from\n };\n let initialTests = [];\n if (this._typeError) initialTests.push(this._typeError);\n if (this._whitelistError) initialTests.push(this._whitelistError);\n if (this._blacklistError) initialTests.push(this._blacklistError);\n (0, _runTests.default)({\n args,\n value,\n path,\n sync,\n tests: initialTests,\n endEarly: abortEarly\n }, err => {\n if (err) return void cb(err, value);\n (0, _runTests.default)({\n tests: this.tests,\n args,\n path,\n sync,\n value,\n endEarly: abortEarly\n }, cb);\n });\n }\n\n validate(value, options, maybeCb) {\n let schema = this.resolve(_extends({}, options, {\n value\n })); // callback case is for nested validations\n\n return typeof maybeCb === 'function' ? schema._validate(value, options, maybeCb) : new Promise((resolve, reject) => schema._validate(value, options, (err, value) => {\n if (err) reject(err);else resolve(value);\n }));\n }\n\n validateSync(value, options) {\n let schema = this.resolve(_extends({}, options, {\n value\n }));\n let result;\n\n schema._validate(value, _extends({}, options, {\n sync: true\n }), (err, value) => {\n if (err) throw err;\n result = value;\n });\n\n return result;\n }\n\n isValid(value, options) {\n return this.validate(value, options).then(() => true, err => {\n if (_ValidationError.default.isError(err)) return false;\n throw err;\n });\n }\n\n isValidSync(value, options) {\n try {\n this.validateSync(value, options);\n return true;\n } catch (err) {\n if (_ValidationError.default.isError(err)) return false;\n throw err;\n }\n }\n\n _getDefault() {\n let defaultValue = this.spec.default;\n\n if (defaultValue == null) {\n return defaultValue;\n }\n\n return typeof defaultValue === 'function' ? defaultValue.call(this) : (0, _nanoclone.default)(defaultValue);\n }\n\n getDefault(options) {\n let schema = this.resolve(options || {});\n return schema._getDefault();\n }\n\n default(def) {\n if (arguments.length === 0) {\n return this._getDefault();\n }\n\n let next = this.clone({\n default: def\n });\n return next;\n }\n\n strict(isStrict = true) {\n var next = this.clone();\n next.spec.strict = isStrict;\n return next;\n }\n\n _isPresent(value) {\n return value != null;\n }\n\n defined(message = _locale.mixed.defined) {\n return this.test({\n message,\n name: 'defined',\n exclusive: true,\n\n test(value) {\n return value !== undefined;\n }\n\n });\n }\n\n required(message = _locale.mixed.required) {\n return this.clone({\n presence: 'required'\n }).withMutation(s => s.test({\n message,\n name: 'required',\n exclusive: true,\n\n test(value) {\n return this.schema._isPresent(value);\n }\n\n }));\n }\n\n notRequired() {\n var next = this.clone({\n presence: 'optional'\n });\n next.tests = next.tests.filter(test => test.OPTIONS.name !== 'required');\n return next;\n }\n\n nullable(isNullable = true) {\n var next = this.clone({\n nullable: isNullable !== false\n });\n return next;\n }\n\n transform(fn) {\n var next = this.clone();\n next.transforms.push(fn);\n return next;\n }\n /**\n * Adds a test function to the schema's queue of tests.\n * tests can be exclusive or non-exclusive.\n *\n * - exclusive tests, will replace any existing tests of the same name.\n * - non-exclusive: can be stacked\n *\n * If a non-exclusive test is added to a schema with an exclusive test of the same name\n * the exclusive test is removed and further tests of the same name will be stacked.\n *\n * If an exclusive test is added to a schema with non-exclusive tests of the same name\n * the previous tests are removed and further tests of the same name will replace each other.\n */\n\n\n test(...args) {\n let opts;\n\n if (args.length === 1) {\n if (typeof args[0] === 'function') {\n opts = {\n test: args[0]\n };\n } else {\n opts = args[0];\n }\n } else if (args.length === 2) {\n opts = {\n name: args[0],\n test: args[1]\n };\n } else {\n opts = {\n name: args[0],\n message: args[1],\n test: args[2]\n };\n }\n\n if (opts.message === undefined) opts.message = _locale.mixed.default;\n if (typeof opts.test !== 'function') throw new TypeError('`test` is a required parameters');\n let next = this.clone();\n let validate = (0, _createValidation.default)(opts);\n let isExclusive = opts.exclusive || opts.name && next.exclusiveTests[opts.name] === true;\n\n if (opts.exclusive) {\n if (!opts.name) throw new TypeError('Exclusive tests must provide a unique `name` identifying the test');\n }\n\n if (opts.name) next.exclusiveTests[opts.name] = !!opts.exclusive;\n next.tests = next.tests.filter(fn => {\n if (fn.OPTIONS.name === opts.name) {\n if (isExclusive) return false;\n if (fn.OPTIONS.test === validate.OPTIONS.test) return false;\n }\n\n return true;\n });\n next.tests.push(validate);\n return next;\n }\n\n when(keys, options) {\n if (!Array.isArray(keys) && typeof keys !== 'string') {\n options = keys;\n keys = '.';\n }\n\n let next = this.clone();\n let deps = (0, _toArray.default)(keys).map(key => new _Reference.default(key));\n deps.forEach(dep => {\n // @ts-ignore\n if (dep.isSibling) next.deps.push(dep.key);\n });\n next.conditions.push(new _Condition.default(deps, options));\n return next;\n }\n\n typeError(message) {\n var next = this.clone();\n next._typeError = (0, _createValidation.default)({\n message,\n name: 'typeError',\n\n test(value) {\n if (value !== undefined && !this.schema.isType(value)) return this.createError({\n params: {\n type: this.schema._type\n }\n });\n return true;\n }\n\n });\n return next;\n }\n\n oneOf(enums, message = _locale.mixed.oneOf) {\n var next = this.clone();\n enums.forEach(val => {\n next._whitelist.add(val);\n\n next._blacklist.delete(val);\n });\n next._whitelistError = (0, _createValidation.default)({\n message,\n name: 'oneOf',\n\n test(value) {\n if (value === undefined) return true;\n let valids = this.schema._whitelist;\n return valids.has(value, this.resolve) ? true : this.createError({\n params: {\n values: valids.toArray().join(', ')\n }\n });\n }\n\n });\n return next;\n }\n\n notOneOf(enums, message = _locale.mixed.notOneOf) {\n var next = this.clone();\n enums.forEach(val => {\n next._blacklist.add(val);\n\n next._whitelist.delete(val);\n });\n next._blacklistError = (0, _createValidation.default)({\n message,\n name: 'notOneOf',\n\n test(value) {\n let invalids = this.schema._blacklist;\n if (invalids.has(value, this.resolve)) return this.createError({\n params: {\n values: invalids.toArray().join(', ')\n }\n });\n return true;\n }\n\n });\n return next;\n }\n\n strip(strip = true) {\n let next = this.clone();\n next.spec.strip = strip;\n return next;\n }\n\n describe() {\n const next = this.clone();\n const {\n label,\n meta\n } = next.spec;\n const description = {\n meta,\n label,\n type: next.type,\n oneOf: next._whitelist.describe(),\n notOneOf: next._blacklist.describe(),\n tests: next.tests.map(fn => ({\n name: fn.OPTIONS.name,\n params: fn.OPTIONS.params\n })).filter((n, idx, list) => list.findIndex(c => c.name === n.name) === idx)\n };\n return description;\n }\n\n}\n\nexports.default = BaseSchema;\n// @ts-expect-error\nBaseSchema.prototype.__isYupSchema__ = true;\n\nfor (const method of ['validate', 'validateSync']) BaseSchema.prototype[`${method}At`] = function (path, value, options = {}) {\n const {\n parent,\n parentPath,\n schema\n } = (0, _reach.getIn)(this, path, value, options.context);\n return schema[method](parent && parent[parentPath], _extends({}, options, {\n parent,\n path\n }));\n};\n\nfor (const alias of ['equals', 'is']) BaseSchema.prototype[alias] = BaseSchema.prototype.oneOf;\n\nfor (const alias of ['not', 'nope']) BaseSchema.prototype[alias] = BaseSchema.prototype.notOneOf;\n\nBaseSchema.prototype.optional = BaseSchema.prototype.notRequired;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.create = create;\nexports.default = void 0;\n\nvar _schema = _interopRequireDefault(require(\"./schema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nconst Mixed = _schema.default;\nvar _default = Mixed;\nexports.default = _default;\n\nfunction create() {\n return new Mixed();\n} // XXX: this is using the Base schema so that `addMethod(mixed)` works as a base class\n\n\ncreate.prototype = Mixed.prototype;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _default = value => value == null;\n\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.create = create;\nexports.default = void 0;\n\nvar _schema = _interopRequireDefault(require(\"./schema\"));\n\nvar _locale = require(\"./locale\");\n\nvar _isAbsent = _interopRequireDefault(require(\"./util/isAbsent\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction create() {\n return new BooleanSchema();\n}\n\nclass BooleanSchema extends _schema.default {\n constructor() {\n super({\n type: 'boolean'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n if (!this.isType(value)) {\n if (/^(true|1)$/i.test(String(value))) return true;\n if (/^(false|0)$/i.test(String(value))) return false;\n }\n\n return value;\n });\n });\n }\n\n _typeCheck(v) {\n if (v instanceof Boolean) v = v.valueOf();\n return typeof v === 'boolean';\n }\n\n isTrue(message = _locale.boolean.isValue) {\n return this.test({\n message,\n name: 'is-value',\n exclusive: true,\n params: {\n value: 'true'\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value === true;\n }\n\n });\n }\n\n isFalse(message = _locale.boolean.isValue) {\n return this.test({\n message,\n name: 'is-value',\n exclusive: true,\n params: {\n value: 'false'\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value === false;\n }\n\n });\n }\n\n}\n\nexports.default = BooleanSchema;\ncreate.prototype = BooleanSchema.prototype;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.create = create;\nexports.default = void 0;\n\nvar _locale = require(\"./locale\");\n\nvar _isAbsent = _interopRequireDefault(require(\"./util/isAbsent\"));\n\nvar _schema = _interopRequireDefault(require(\"./schema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\n// eslint-disable-next-line\nlet rEmail = /^((([a-z]|\\d|[!#\\$%&'\\*\\+\\-\\/=\\?\\^_`{\\|}~]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])+(\\.([a-z]|\\d|[!#\\$%&'\\*\\+\\-\\/=\\?\\^_`{\\|}~]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])+)*)|((\\x22)((((\\x20|\\x09)*(\\x0d\\x0a))?(\\x20|\\x09)+)?(([\\x01-\\x08\\x0b\\x0c\\x0e-\\x1f\\x7f]|\\x21|[\\x23-\\x5b]|[\\x5d-\\x7e]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(\\\\([\\x01-\\x09\\x0b\\x0c\\x0d-\\x7f]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]))))*(((\\x20|\\x09)*(\\x0d\\x0a))?(\\x20|\\x09)+)?(\\x22)))@((([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))\\.)+(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))$/i; // eslint-disable-next-line\n\nlet rUrl = /^((https?|ftp):)?\\/\\/(((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:)*@)?(((\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])\\.(\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])\\.(\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])\\.(\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5]))|((([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))\\.)+(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))\\.?)(:\\d*)?)(\\/((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)+(\\/(([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)*)*)?)?(\\?((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)|[\\uE000-\\uF8FF]|\\/|\\?)*)?(\\#((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)|\\/|\\?)*)?$/i; // eslint-disable-next-line\n\nlet rUUID = /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;\n\nlet isTrimmed = value => (0, _isAbsent.default)(value) || value === value.trim();\n\nlet objStringTag = {}.toString();\n\nfunction create() {\n return new StringSchema();\n}\n\nclass StringSchema extends _schema.default {\n constructor() {\n super({\n type: 'string'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n if (this.isType(value)) return value;\n if (Array.isArray(value)) return value;\n const strValue = value != null && value.toString ? value.toString() : value;\n if (strValue === objStringTag) return value;\n return strValue;\n });\n });\n }\n\n _typeCheck(value) {\n if (value instanceof String) value = value.valueOf();\n return typeof value === 'string';\n }\n\n _isPresent(value) {\n return super._isPresent(value) && !!value.length;\n }\n\n length(length, message = _locale.string.length) {\n return this.test({\n message,\n name: 'length',\n exclusive: true,\n params: {\n length\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value.length === this.resolve(length);\n }\n\n });\n }\n\n min(min, message = _locale.string.min) {\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value.length >= this.resolve(min);\n }\n\n });\n }\n\n max(max, message = _locale.string.max) {\n return this.test({\n name: 'max',\n exclusive: true,\n message,\n params: {\n max\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value.length <= this.resolve(max);\n }\n\n });\n }\n\n matches(regex, options) {\n let excludeEmptyString = false;\n let message;\n let name;\n\n if (options) {\n if (typeof options === 'object') {\n ({\n excludeEmptyString = false,\n message,\n name\n } = options);\n } else {\n message = options;\n }\n }\n\n return this.test({\n name: name || 'matches',\n message: message || _locale.string.matches,\n params: {\n regex\n },\n test: value => (0, _isAbsent.default)(value) || value === '' && excludeEmptyString || value.search(regex) !== -1\n });\n }\n\n email(message = _locale.string.email) {\n return this.matches(rEmail, {\n name: 'email',\n message,\n excludeEmptyString: true\n });\n }\n\n url(message = _locale.string.url) {\n return this.matches(rUrl, {\n name: 'url',\n message,\n excludeEmptyString: true\n });\n }\n\n uuid(message = _locale.string.uuid) {\n return this.matches(rUUID, {\n name: 'uuid',\n message,\n excludeEmptyString: false\n });\n } //-- transforms --\n\n\n ensure() {\n return this.default('').transform(val => val === null ? '' : val);\n }\n\n trim(message = _locale.string.trim) {\n return this.transform(val => val != null ? val.trim() : val).test({\n message,\n name: 'trim',\n test: isTrimmed\n });\n }\n\n lowercase(message = _locale.string.lowercase) {\n return this.transform(value => !(0, _isAbsent.default)(value) ? value.toLowerCase() : value).test({\n message,\n name: 'string_case',\n exclusive: true,\n test: value => (0, _isAbsent.default)(value) || value === value.toLowerCase()\n });\n }\n\n uppercase(message = _locale.string.uppercase) {\n return this.transform(value => !(0, _isAbsent.default)(value) ? value.toUpperCase() : value).test({\n message,\n name: 'string_case',\n exclusive: true,\n test: value => (0, _isAbsent.default)(value) || value === value.toUpperCase()\n });\n }\n\n}\n\nexports.default = StringSchema;\ncreate.prototype = StringSchema.prototype; //\n// String Interfaces\n//", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.create = create;\nexports.default = void 0;\n\nvar _locale = require(\"./locale\");\n\nvar _isAbsent = _interopRequireDefault(require(\"./util/isAbsent\"));\n\nvar _schema = _interopRequireDefault(require(\"./schema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nlet isNaN = value => value != +value;\n\nfunction create() {\n return new NumberSchema();\n}\n\nclass NumberSchema extends _schema.default {\n constructor() {\n super({\n type: 'number'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n let parsed = value;\n\n if (typeof parsed === 'string') {\n parsed = parsed.replace(/\\s/g, '');\n if (parsed === '') return NaN; // don't use parseFloat to avoid positives on alpha-numeric strings\n\n parsed = +parsed;\n }\n\n if (this.isType(parsed)) return parsed;\n return parseFloat(parsed);\n });\n });\n }\n\n _typeCheck(value) {\n if (value instanceof Number) value = value.valueOf();\n return typeof value === 'number' && !isNaN(value);\n }\n\n min(min, message = _locale.number.min) {\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value >= this.resolve(min);\n }\n\n });\n }\n\n max(max, message = _locale.number.max) {\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n max\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value <= this.resolve(max);\n }\n\n });\n }\n\n lessThan(less, message = _locale.number.lessThan) {\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n less\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value < this.resolve(less);\n }\n\n });\n }\n\n moreThan(more, message = _locale.number.moreThan) {\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n more\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value > this.resolve(more);\n }\n\n });\n }\n\n positive(msg = _locale.number.positive) {\n return this.moreThan(0, msg);\n }\n\n negative(msg = _locale.number.negative) {\n return this.lessThan(0, msg);\n }\n\n integer(message = _locale.number.integer) {\n return this.test({\n name: 'integer',\n message,\n test: val => (0, _isAbsent.default)(val) || Number.isInteger(val)\n });\n }\n\n truncate() {\n return this.transform(value => !(0, _isAbsent.default)(value) ? value | 0 : value);\n }\n\n round(method) {\n var _method;\n\n var avail = ['ceil', 'floor', 'round', 'trunc'];\n method = ((_method = method) == null ? void 0 : _method.toLowerCase()) || 'round'; // this exists for symemtry with the new Math.trunc\n\n if (method === 'trunc') return this.truncate();\n if (avail.indexOf(method.toLowerCase()) === -1) throw new TypeError('Only valid options for round() are: ' + avail.join(', '));\n return this.transform(value => !(0, _isAbsent.default)(value) ? Math[method](value) : value);\n }\n\n}\n\nexports.default = NumberSchema;\ncreate.prototype = NumberSchema.prototype; //\n// Number Interfaces\n//", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = parseIsoDate;\n\n/* eslint-disable */\n\n/**\n *\n * Date.parse with progressive enhancement for ISO 8601 \n * NON-CONFORMANT EDITION.\n * \u00A9 2011 Colin Snover \n * Released under MIT license.\n */\n// 1 YYYY 2 MM 3 DD 4 HH 5 mm 6 ss 7 msec 8 Z 9 \u00B1 10 tzHH 11 tzmm\nvar isoReg = /^(\\d{4}|[+\\-]\\d{6})(?:-?(\\d{2})(?:-?(\\d{2}))?)?(?:[ T]?(\\d{2}):?(\\d{2})(?::?(\\d{2})(?:[,\\.](\\d{1,}))?)?(?:(Z)|([+\\-])(\\d{2})(?::?(\\d{2}))?)?)?$/;\n\nfunction parseIsoDate(date) {\n var numericKeys = [1, 4, 5, 6, 7, 10, 11],\n minutesOffset = 0,\n timestamp,\n struct;\n\n if (struct = isoReg.exec(date)) {\n // avoid NaN timestamps caused by \u201Cundefined\u201D values being passed to Date.UTC\n for (var i = 0, k; k = numericKeys[i]; ++i) struct[k] = +struct[k] || 0; // allow undefined days and months\n\n\n struct[2] = (+struct[2] || 1) - 1;\n struct[3] = +struct[3] || 1; // allow arbitrary sub-second precision beyond milliseconds\n\n struct[7] = struct[7] ? String(struct[7]).substr(0, 3) : 0; // timestamps without timezone identifiers should be considered local time\n\n if ((struct[8] === undefined || struct[8] === '') && (struct[9] === undefined || struct[9] === '')) timestamp = +new Date(struct[1], struct[2], struct[3], struct[4], struct[5], struct[6], struct[7]);else {\n if (struct[8] !== 'Z' && struct[9] !== undefined) {\n minutesOffset = struct[10] * 60 + struct[11];\n if (struct[9] === '+') minutesOffset = 0 - minutesOffset;\n }\n\n timestamp = Date.UTC(struct[1], struct[2], struct[3], struct[4], struct[5] + minutesOffset, struct[6], struct[7]);\n }\n } else timestamp = Date.parse ? Date.parse(date) : NaN;\n\n return timestamp;\n}", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.create = create;\nexports.default = void 0;\n\nvar _isodate = _interopRequireDefault(require(\"./util/isodate\"));\n\nvar _locale = require(\"./locale\");\n\nvar _isAbsent = _interopRequireDefault(require(\"./util/isAbsent\"));\n\nvar _Reference = _interopRequireDefault(require(\"./Reference\"));\n\nvar _schema = _interopRequireDefault(require(\"./schema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\n// @ts-ignore\nlet invalidDate = new Date('');\n\nlet isDate = obj => Object.prototype.toString.call(obj) === '[object Date]';\n\nfunction create() {\n return new DateSchema();\n}\n\nclass DateSchema extends _schema.default {\n constructor() {\n super({\n type: 'date'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n if (this.isType(value)) return value;\n value = (0, _isodate.default)(value); // 0 is a valid timestamp equivalent to 1970-01-01T00:00:00Z(unix epoch) or before.\n\n return !isNaN(value) ? new Date(value) : invalidDate;\n });\n });\n }\n\n _typeCheck(v) {\n return isDate(v) && !isNaN(v.getTime());\n }\n\n prepareParam(ref, name) {\n let param;\n\n if (!_Reference.default.isRef(ref)) {\n let cast = this.cast(ref);\n if (!this._typeCheck(cast)) throw new TypeError(`\\`${name}\\` must be a Date or a value that can be \\`cast()\\` to a Date`);\n param = cast;\n } else {\n param = ref;\n }\n\n return param;\n }\n\n min(min, message = _locale.date.min) {\n let limit = this.prepareParam(min, 'min');\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value >= this.resolve(limit);\n }\n\n });\n }\n\n max(max, message = _locale.date.max) {\n var limit = this.prepareParam(max, 'max');\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n max\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value <= this.resolve(limit);\n }\n\n });\n }\n\n}\n\nexports.default = DateSchema;\nDateSchema.INVALID_DATE = invalidDate;\ncreate.prototype = DateSchema.prototype;\ncreate.INVALID_DATE = invalidDate;", "/**\n * A specialized version of `_.reduce` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {*} [accumulator] The initial value.\n * @param {boolean} [initAccum] Specify using the first element of `array` as\n * the initial value.\n * @returns {*} Returns the accumulated value.\n */\nfunction arrayReduce(array, iteratee, accumulator, initAccum) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n if (initAccum && length) {\n accumulator = array[++index];\n }\n while (++index < length) {\n accumulator = iteratee(accumulator, array[index], index, array);\n }\n return accumulator;\n}\n\nmodule.exports = arrayReduce;\n", "/**\n * The base implementation of `_.propertyOf` without support for deep paths.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Function} Returns the new accessor function.\n */\nfunction basePropertyOf(object) {\n return function(key) {\n return object == null ? undefined : object[key];\n };\n}\n\nmodule.exports = basePropertyOf;\n", "var basePropertyOf = require('./_basePropertyOf');\n\n/** Used to map Latin Unicode letters to basic Latin letters. */\nvar deburredLetters = {\n // Latin-1 Supplement block.\n '\\xc0': 'A', '\\xc1': 'A', '\\xc2': 'A', '\\xc3': 'A', '\\xc4': 'A', '\\xc5': 'A',\n '\\xe0': 'a', '\\xe1': 'a', '\\xe2': 'a', '\\xe3': 'a', '\\xe4': 'a', '\\xe5': 'a',\n '\\xc7': 'C', '\\xe7': 'c',\n '\\xd0': 'D', '\\xf0': 'd',\n '\\xc8': 'E', '\\xc9': 'E', '\\xca': 'E', '\\xcb': 'E',\n '\\xe8': 'e', '\\xe9': 'e', '\\xea': 'e', '\\xeb': 'e',\n '\\xcc': 'I', '\\xcd': 'I', '\\xce': 'I', '\\xcf': 'I',\n '\\xec': 'i', '\\xed': 'i', '\\xee': 'i', '\\xef': 'i',\n '\\xd1': 'N', '\\xf1': 'n',\n '\\xd2': 'O', '\\xd3': 'O', '\\xd4': 'O', '\\xd5': 'O', '\\xd6': 'O', '\\xd8': 'O',\n '\\xf2': 'o', '\\xf3': 'o', '\\xf4': 'o', '\\xf5': 'o', '\\xf6': 'o', '\\xf8': 'o',\n '\\xd9': 'U', '\\xda': 'U', '\\xdb': 'U', '\\xdc': 'U',\n '\\xf9': 'u', '\\xfa': 'u', '\\xfb': 'u', '\\xfc': 'u',\n '\\xdd': 'Y', '\\xfd': 'y', '\\xff': 'y',\n '\\xc6': 'Ae', '\\xe6': 'ae',\n '\\xde': 'Th', '\\xfe': 'th',\n '\\xdf': 'ss',\n // Latin Extended-A block.\n '\\u0100': 'A', '\\u0102': 'A', '\\u0104': 'A',\n '\\u0101': 'a', '\\u0103': 'a', '\\u0105': 'a',\n '\\u0106': 'C', '\\u0108': 'C', '\\u010a': 'C', '\\u010c': 'C',\n '\\u0107': 'c', '\\u0109': 'c', '\\u010b': 'c', '\\u010d': 'c',\n '\\u010e': 'D', '\\u0110': 'D', '\\u010f': 'd', '\\u0111': 'd',\n '\\u0112': 'E', '\\u0114': 'E', '\\u0116': 'E', '\\u0118': 'E', '\\u011a': 'E',\n '\\u0113': 'e', '\\u0115': 'e', '\\u0117': 'e', '\\u0119': 'e', '\\u011b': 'e',\n '\\u011c': 'G', '\\u011e': 'G', '\\u0120': 'G', '\\u0122': 'G',\n '\\u011d': 'g', '\\u011f': 'g', '\\u0121': 'g', '\\u0123': 'g',\n '\\u0124': 'H', '\\u0126': 'H', '\\u0125': 'h', '\\u0127': 'h',\n '\\u0128': 'I', '\\u012a': 'I', '\\u012c': 'I', '\\u012e': 'I', '\\u0130': 'I',\n '\\u0129': 'i', '\\u012b': 'i', '\\u012d': 'i', '\\u012f': 'i', '\\u0131': 'i',\n '\\u0134': 'J', '\\u0135': 'j',\n '\\u0136': 'K', '\\u0137': 'k', '\\u0138': 'k',\n '\\u0139': 'L', '\\u013b': 'L', '\\u013d': 'L', '\\u013f': 'L', '\\u0141': 'L',\n '\\u013a': 'l', '\\u013c': 'l', '\\u013e': 'l', '\\u0140': 'l', '\\u0142': 'l',\n '\\u0143': 'N', '\\u0145': 'N', '\\u0147': 'N', '\\u014a': 'N',\n '\\u0144': 'n', '\\u0146': 'n', '\\u0148': 'n', '\\u014b': 'n',\n '\\u014c': 'O', '\\u014e': 'O', '\\u0150': 'O',\n '\\u014d': 'o', '\\u014f': 'o', '\\u0151': 'o',\n '\\u0154': 'R', '\\u0156': 'R', '\\u0158': 'R',\n '\\u0155': 'r', '\\u0157': 'r', '\\u0159': 'r',\n '\\u015a': 'S', '\\u015c': 'S', '\\u015e': 'S', '\\u0160': 'S',\n '\\u015b': 's', '\\u015d': 's', '\\u015f': 's', '\\u0161': 's',\n '\\u0162': 'T', '\\u0164': 'T', '\\u0166': 'T',\n '\\u0163': 't', '\\u0165': 't', '\\u0167': 't',\n '\\u0168': 'U', '\\u016a': 'U', '\\u016c': 'U', '\\u016e': 'U', '\\u0170': 'U', '\\u0172': 'U',\n '\\u0169': 'u', '\\u016b': 'u', '\\u016d': 'u', '\\u016f': 'u', '\\u0171': 'u', '\\u0173': 'u',\n '\\u0174': 'W', '\\u0175': 'w',\n '\\u0176': 'Y', '\\u0177': 'y', '\\u0178': 'Y',\n '\\u0179': 'Z', '\\u017b': 'Z', '\\u017d': 'Z',\n '\\u017a': 'z', '\\u017c': 'z', '\\u017e': 'z',\n '\\u0132': 'IJ', '\\u0133': 'ij',\n '\\u0152': 'Oe', '\\u0153': 'oe',\n '\\u0149': \"'n\", '\\u017f': 's'\n};\n\n/**\n * Used by `_.deburr` to convert Latin-1 Supplement and Latin Extended-A\n * letters to basic Latin letters.\n *\n * @private\n * @param {string} letter The matched letter to deburr.\n * @returns {string} Returns the deburred letter.\n */\nvar deburrLetter = basePropertyOf(deburredLetters);\n\nmodule.exports = deburrLetter;\n", "var deburrLetter = require('./_deburrLetter'),\n toString = require('./toString');\n\n/** Used to match Latin Unicode letters (excluding mathematical operators). */\nvar reLatin = /[\\xc0-\\xd6\\xd8-\\xf6\\xf8-\\xff\\u0100-\\u017f]/g;\n\n/** Used to compose unicode character classes. */\nvar rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange;\n\n/** Used to compose unicode capture groups. */\nvar rsCombo = '[' + rsComboRange + ']';\n\n/**\n * Used to match [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks) and\n * [combining diacritical marks for symbols](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks_for_Symbols).\n */\nvar reComboMark = RegExp(rsCombo, 'g');\n\n/**\n * Deburrs `string` by converting\n * [Latin-1 Supplement](https://en.wikipedia.org/wiki/Latin-1_Supplement_(Unicode_block)#Character_table)\n * and [Latin Extended-A](https://en.wikipedia.org/wiki/Latin_Extended-A)\n * letters to basic Latin letters and removing\n * [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to deburr.\n * @returns {string} Returns the deburred string.\n * @example\n *\n * _.deburr('d\u00E9j\u00E0 vu');\n * // => 'deja vu'\n */\nfunction deburr(string) {\n string = toString(string);\n return string && string.replace(reLatin, deburrLetter).replace(reComboMark, '');\n}\n\nmodule.exports = deburr;\n", "/** Used to match words composed of alphanumeric characters. */\nvar reAsciiWord = /[^\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\x7f]+/g;\n\n/**\n * Splits an ASCII `string` into an array of its words.\n *\n * @private\n * @param {string} The string to inspect.\n * @returns {Array} Returns the words of `string`.\n */\nfunction asciiWords(string) {\n return string.match(reAsciiWord) || [];\n}\n\nmodule.exports = asciiWords;\n", "/** Used to detect strings that need a more robust regexp to match words. */\nvar reHasUnicodeWord = /[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;\n\n/**\n * Checks if `string` contains a word composed of Unicode symbols.\n *\n * @private\n * @param {string} string The string to inspect.\n * @returns {boolean} Returns `true` if a word is found, else `false`.\n */\nfunction hasUnicodeWord(string) {\n return reHasUnicodeWord.test(string);\n}\n\nmodule.exports = hasUnicodeWord;\n", "/** Used to compose unicode character classes. */\nvar rsAstralRange = '\\\\ud800-\\\\udfff',\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\n rsDingbatRange = '\\\\u2700-\\\\u27bf',\n rsLowerRange = 'a-z\\\\xdf-\\\\xf6\\\\xf8-\\\\xff',\n rsMathOpRange = '\\\\xac\\\\xb1\\\\xd7\\\\xf7',\n rsNonCharRange = '\\\\x00-\\\\x2f\\\\x3a-\\\\x40\\\\x5b-\\\\x60\\\\x7b-\\\\xbf',\n rsPunctuationRange = '\\\\u2000-\\\\u206f',\n rsSpaceRange = ' \\\\t\\\\x0b\\\\f\\\\xa0\\\\ufeff\\\\n\\\\r\\\\u2028\\\\u2029\\\\u1680\\\\u180e\\\\u2000\\\\u2001\\\\u2002\\\\u2003\\\\u2004\\\\u2005\\\\u2006\\\\u2007\\\\u2008\\\\u2009\\\\u200a\\\\u202f\\\\u205f\\\\u3000',\n rsUpperRange = 'A-Z\\\\xc0-\\\\xd6\\\\xd8-\\\\xde',\n rsVarRange = '\\\\ufe0e\\\\ufe0f',\n rsBreakRange = rsMathOpRange + rsNonCharRange + rsPunctuationRange + rsSpaceRange;\n\n/** Used to compose unicode capture groups. */\nvar rsApos = \"['\\u2019]\",\n rsBreak = '[' + rsBreakRange + ']',\n rsCombo = '[' + rsComboRange + ']',\n rsDigits = '\\\\d+',\n rsDingbat = '[' + rsDingbatRange + ']',\n rsLower = '[' + rsLowerRange + ']',\n rsMisc = '[^' + rsAstralRange + rsBreakRange + rsDigits + rsDingbatRange + rsLowerRange + rsUpperRange + ']',\n rsFitz = '\\\\ud83c[\\\\udffb-\\\\udfff]',\n rsModifier = '(?:' + rsCombo + '|' + rsFitz + ')',\n rsNonAstral = '[^' + rsAstralRange + ']',\n rsRegional = '(?:\\\\ud83c[\\\\udde6-\\\\uddff]){2}',\n rsSurrPair = '[\\\\ud800-\\\\udbff][\\\\udc00-\\\\udfff]',\n rsUpper = '[' + rsUpperRange + ']',\n rsZWJ = '\\\\u200d';\n\n/** Used to compose unicode regexes. */\nvar rsMiscLower = '(?:' + rsLower + '|' + rsMisc + ')',\n rsMiscUpper = '(?:' + rsUpper + '|' + rsMisc + ')',\n rsOptContrLower = '(?:' + rsApos + '(?:d|ll|m|re|s|t|ve))?',\n rsOptContrUpper = '(?:' + rsApos + '(?:D|LL|M|RE|S|T|VE))?',\n reOptMod = rsModifier + '?',\n rsOptVar = '[' + rsVarRange + ']?',\n rsOptJoin = '(?:' + rsZWJ + '(?:' + [rsNonAstral, rsRegional, rsSurrPair].join('|') + ')' + rsOptVar + reOptMod + ')*',\n rsOrdLower = '\\\\d*(?:1st|2nd|3rd|(?![123])\\\\dth)(?=\\\\b|[A-Z_])',\n rsOrdUpper = '\\\\d*(?:1ST|2ND|3RD|(?![123])\\\\dTH)(?=\\\\b|[a-z_])',\n rsSeq = rsOptVar + reOptMod + rsOptJoin,\n rsEmoji = '(?:' + [rsDingbat, rsRegional, rsSurrPair].join('|') + ')' + rsSeq;\n\n/** Used to match complex or compound words. */\nvar reUnicodeWord = RegExp([\n rsUpper + '?' + rsLower + '+' + rsOptContrLower + '(?=' + [rsBreak, rsUpper, '$'].join('|') + ')',\n rsMiscUpper + '+' + rsOptContrUpper + '(?=' + [rsBreak, rsUpper + rsMiscLower, '$'].join('|') + ')',\n rsUpper + '?' + rsMiscLower + '+' + rsOptContrLower,\n rsUpper + '+' + rsOptContrUpper,\n rsOrdUpper,\n rsOrdLower,\n rsDigits,\n rsEmoji\n].join('|'), 'g');\n\n/**\n * Splits a Unicode `string` into an array of its words.\n *\n * @private\n * @param {string} The string to inspect.\n * @returns {Array} Returns the words of `string`.\n */\nfunction unicodeWords(string) {\n return string.match(reUnicodeWord) || [];\n}\n\nmodule.exports = unicodeWords;\n", "var asciiWords = require('./_asciiWords'),\n hasUnicodeWord = require('./_hasUnicodeWord'),\n toString = require('./toString'),\n unicodeWords = require('./_unicodeWords');\n\n/**\n * Splits `string` into an array of its words.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to inspect.\n * @param {RegExp|string} [pattern] The pattern to match words.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {Array} Returns the words of `string`.\n * @example\n *\n * _.words('fred, barney, & pebbles');\n * // => ['fred', 'barney', 'pebbles']\n *\n * _.words('fred, barney, & pebbles', /[^, ]+/g);\n * // => ['fred', 'barney', '&', 'pebbles']\n */\nfunction words(string, pattern, guard) {\n string = toString(string);\n pattern = guard ? undefined : pattern;\n\n if (pattern === undefined) {\n return hasUnicodeWord(string) ? unicodeWords(string) : asciiWords(string);\n }\n return string.match(pattern) || [];\n}\n\nmodule.exports = words;\n", "var arrayReduce = require('./_arrayReduce'),\n deburr = require('./deburr'),\n words = require('./words');\n\n/** Used to compose unicode capture groups. */\nvar rsApos = \"['\\u2019]\";\n\n/** Used to match apostrophes. */\nvar reApos = RegExp(rsApos, 'g');\n\n/**\n * Creates a function like `_.camelCase`.\n *\n * @private\n * @param {Function} callback The function to combine each word.\n * @returns {Function} Returns the new compounder function.\n */\nfunction createCompounder(callback) {\n return function(string) {\n return arrayReduce(words(deburr(string).replace(reApos, '')), callback, '');\n };\n}\n\nmodule.exports = createCompounder;\n", "var createCompounder = require('./_createCompounder');\n\n/**\n * Converts `string` to\n * [snake case](https://en.wikipedia.org/wiki/Snake_case).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the snake cased string.\n * @example\n *\n * _.snakeCase('Foo Bar');\n * // => 'foo_bar'\n *\n * _.snakeCase('fooBar');\n * // => 'foo_bar'\n *\n * _.snakeCase('--FOO-BAR--');\n * // => 'foo_bar'\n */\nvar snakeCase = createCompounder(function(result, word, index) {\n return result + (index ? '_' : '') + word.toLowerCase();\n});\n\nmodule.exports = snakeCase;\n", "/**\n * The base implementation of `_.slice` without an iteratee call guard.\n *\n * @private\n * @param {Array} array The array to slice.\n * @param {number} [start=0] The start position.\n * @param {number} [end=array.length] The end position.\n * @returns {Array} Returns the slice of `array`.\n */\nfunction baseSlice(array, start, end) {\n var index = -1,\n length = array.length;\n\n if (start < 0) {\n start = -start > length ? 0 : (length + start);\n }\n end = end > length ? length : end;\n if (end < 0) {\n end += length;\n }\n length = start > end ? 0 : ((end - start) >>> 0);\n start >>>= 0;\n\n var result = Array(length);\n while (++index < length) {\n result[index] = array[index + start];\n }\n return result;\n}\n\nmodule.exports = baseSlice;\n", "var baseSlice = require('./_baseSlice');\n\n/**\n * Casts `array` to a slice if it's needed.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {number} start The start position.\n * @param {number} [end=array.length] The end position.\n * @returns {Array} Returns the cast slice.\n */\nfunction castSlice(array, start, end) {\n var length = array.length;\n end = end === undefined ? length : end;\n return (!start && end >= length) ? array : baseSlice(array, start, end);\n}\n\nmodule.exports = castSlice;\n", "/** Used to compose unicode character classes. */\nvar rsAstralRange = '\\\\ud800-\\\\udfff',\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\n rsVarRange = '\\\\ufe0e\\\\ufe0f';\n\n/** Used to compose unicode capture groups. */\nvar rsZWJ = '\\\\u200d';\n\n/** Used to detect strings with [zero-width joiners or code points from the astral planes](http://eev.ee/blog/2015/09/12/dark-corners-of-unicode/). */\nvar reHasUnicode = RegExp('[' + rsZWJ + rsAstralRange + rsComboRange + rsVarRange + ']');\n\n/**\n * Checks if `string` contains Unicode symbols.\n *\n * @private\n * @param {string} string The string to inspect.\n * @returns {boolean} Returns `true` if a symbol is found, else `false`.\n */\nfunction hasUnicode(string) {\n return reHasUnicode.test(string);\n}\n\nmodule.exports = hasUnicode;\n", "/**\n * Converts an ASCII `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\nfunction asciiToArray(string) {\n return string.split('');\n}\n\nmodule.exports = asciiToArray;\n", "/** Used to compose unicode character classes. */\nvar rsAstralRange = '\\\\ud800-\\\\udfff',\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\n rsVarRange = '\\\\ufe0e\\\\ufe0f';\n\n/** Used to compose unicode capture groups. */\nvar rsAstral = '[' + rsAstralRange + ']',\n rsCombo = '[' + rsComboRange + ']',\n rsFitz = '\\\\ud83c[\\\\udffb-\\\\udfff]',\n rsModifier = '(?:' + rsCombo + '|' + rsFitz + ')',\n rsNonAstral = '[^' + rsAstralRange + ']',\n rsRegional = '(?:\\\\ud83c[\\\\udde6-\\\\uddff]){2}',\n rsSurrPair = '[\\\\ud800-\\\\udbff][\\\\udc00-\\\\udfff]',\n rsZWJ = '\\\\u200d';\n\n/** Used to compose unicode regexes. */\nvar reOptMod = rsModifier + '?',\n rsOptVar = '[' + rsVarRange + ']?',\n rsOptJoin = '(?:' + rsZWJ + '(?:' + [rsNonAstral, rsRegional, rsSurrPair].join('|') + ')' + rsOptVar + reOptMod + ')*',\n rsSeq = rsOptVar + reOptMod + rsOptJoin,\n rsSymbol = '(?:' + [rsNonAstral + rsCombo + '?', rsCombo, rsRegional, rsSurrPair, rsAstral].join('|') + ')';\n\n/** Used to match [string symbols](https://mathiasbynens.be/notes/javascript-unicode). */\nvar reUnicode = RegExp(rsFitz + '(?=' + rsFitz + ')|' + rsSymbol + rsSeq, 'g');\n\n/**\n * Converts a Unicode `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\nfunction unicodeToArray(string) {\n return string.match(reUnicode) || [];\n}\n\nmodule.exports = unicodeToArray;\n", "var asciiToArray = require('./_asciiToArray'),\n hasUnicode = require('./_hasUnicode'),\n unicodeToArray = require('./_unicodeToArray');\n\n/**\n * Converts `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\nfunction stringToArray(string) {\n return hasUnicode(string)\n ? unicodeToArray(string)\n : asciiToArray(string);\n}\n\nmodule.exports = stringToArray;\n", "var castSlice = require('./_castSlice'),\n hasUnicode = require('./_hasUnicode'),\n stringToArray = require('./_stringToArray'),\n toString = require('./toString');\n\n/**\n * Creates a function like `_.lowerFirst`.\n *\n * @private\n * @param {string} methodName The name of the `String` case method to use.\n * @returns {Function} Returns the new case function.\n */\nfunction createCaseFirst(methodName) {\n return function(string) {\n string = toString(string);\n\n var strSymbols = hasUnicode(string)\n ? stringToArray(string)\n : undefined;\n\n var chr = strSymbols\n ? strSymbols[0]\n : string.charAt(0);\n\n var trailing = strSymbols\n ? castSlice(strSymbols, 1).join('')\n : string.slice(1);\n\n return chr[methodName]() + trailing;\n };\n}\n\nmodule.exports = createCaseFirst;\n", "var createCaseFirst = require('./_createCaseFirst');\n\n/**\n * Converts the first character of `string` to upper case.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the converted string.\n * @example\n *\n * _.upperFirst('fred');\n * // => 'Fred'\n *\n * _.upperFirst('FRED');\n * // => 'FRED'\n */\nvar upperFirst = createCaseFirst('toUpperCase');\n\nmodule.exports = upperFirst;\n", "var toString = require('./toString'),\n upperFirst = require('./upperFirst');\n\n/**\n * Converts the first character of `string` to upper case and the remaining\n * to lower case.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to capitalize.\n * @returns {string} Returns the capitalized string.\n * @example\n *\n * _.capitalize('FRED');\n * // => 'Fred'\n */\nfunction capitalize(string) {\n return upperFirst(toString(string).toLowerCase());\n}\n\nmodule.exports = capitalize;\n", "var capitalize = require('./capitalize'),\n createCompounder = require('./_createCompounder');\n\n/**\n * Converts `string` to [camel case](https://en.wikipedia.org/wiki/CamelCase).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the camel cased string.\n * @example\n *\n * _.camelCase('Foo Bar');\n * // => 'fooBar'\n *\n * _.camelCase('--foo-bar--');\n * // => 'fooBar'\n *\n * _.camelCase('__FOO_BAR__');\n * // => 'fooBar'\n */\nvar camelCase = createCompounder(function(result, word, index) {\n word = word.toLowerCase();\n return result + (index ? capitalize(word) : word);\n});\n\nmodule.exports = camelCase;\n", "var baseAssignValue = require('./_baseAssignValue'),\n baseForOwn = require('./_baseForOwn'),\n baseIteratee = require('./_baseIteratee');\n\n/**\n * The opposite of `_.mapValues`; this method creates an object with the\n * same values as `object` and keys generated by running each own enumerable\n * string keyed property of `object` thru `iteratee`. The iteratee is invoked\n * with three arguments: (value, key, object).\n *\n * @static\n * @memberOf _\n * @since 3.8.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Object} Returns the new mapped object.\n * @see _.mapValues\n * @example\n *\n * _.mapKeys({ 'a': 1, 'b': 2 }, function(value, key) {\n * return key + value;\n * });\n * // => { 'a1': 1, 'b2': 2 }\n */\nfunction mapKeys(object, iteratee) {\n var result = {};\n iteratee = baseIteratee(iteratee, 3);\n\n baseForOwn(object, function(value, key, object) {\n baseAssignValue(result, iteratee(value, key, object), value);\n });\n return result;\n}\n\nmodule.exports = mapKeys;\n", "\n/**\n * Topological sorting function\n *\n * @param {Array} edges\n * @returns {Array}\n */\n\nmodule.exports = function(edges) {\n return toposort(uniqueNodes(edges), edges)\n}\n\nmodule.exports.array = toposort\n\nfunction toposort(nodes, edges) {\n var cursor = nodes.length\n , sorted = new Array(cursor)\n , visited = {}\n , i = cursor\n // Better data structures make algorithm much faster.\n , outgoingEdges = makeOutgoingEdges(edges)\n , nodesHash = makeNodesHash(nodes)\n\n // check for unknown nodes\n edges.forEach(function(edge) {\n if (!nodesHash.has(edge[0]) || !nodesHash.has(edge[1])) {\n throw new Error('Unknown node. There is an unknown node in the supplied edges.')\n }\n })\n\n while (i--) {\n if (!visited[i]) visit(nodes[i], i, new Set())\n }\n\n return sorted\n\n function visit(node, i, predecessors) {\n if(predecessors.has(node)) {\n var nodeRep\n try {\n nodeRep = \", node was:\" + JSON.stringify(node)\n } catch(e) {\n nodeRep = \"\"\n }\n throw new Error('Cyclic dependency' + nodeRep)\n }\n\n if (!nodesHash.has(node)) {\n throw new Error('Found unknown node. Make sure to provided all involved nodes. Unknown node: '+JSON.stringify(node))\n }\n\n if (visited[i]) return;\n visited[i] = true\n\n var outgoing = outgoingEdges.get(node) || new Set()\n outgoing = Array.from(outgoing)\n\n if (i = outgoing.length) {\n predecessors.add(node)\n do {\n var child = outgoing[--i]\n visit(child, nodesHash.get(child), predecessors)\n } while (i)\n predecessors.delete(node)\n }\n\n sorted[--cursor] = node\n }\n}\n\nfunction uniqueNodes(arr){\n var res = new Set()\n for (var i = 0, len = arr.length; i < len; i++) {\n var edge = arr[i]\n res.add(edge[0])\n res.add(edge[1])\n }\n return Array.from(res)\n}\n\nfunction makeOutgoingEdges(arr){\n var edges = new Map()\n for (var i = 0, len = arr.length; i < len; i++) {\n var edge = arr[i]\n if (!edges.has(edge[0])) edges.set(edge[0], new Set())\n if (!edges.has(edge[1])) edges.set(edge[1], new Set())\n edges.get(edge[0]).add(edge[1])\n }\n return edges\n}\n\nfunction makeNodesHash(arr){\n var res = new Map()\n for (var i = 0, len = arr.length; i < len; i++) {\n res.set(arr[i], i)\n }\n return res\n}\n", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = sortFields;\n\nvar _has = _interopRequireDefault(require(\"lodash/has\"));\n\nvar _toposort = _interopRequireDefault(require(\"toposort\"));\n\nvar _propertyExpr = require(\"property-expr\");\n\nvar _Reference = _interopRequireDefault(require(\"../Reference\"));\n\nvar _isSchema = _interopRequireDefault(require(\"./isSchema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\n// @ts-expect-error\nfunction sortFields(fields, excludes = []) {\n let edges = [];\n let nodes = [];\n\n function addNode(depPath, key) {\n var node = (0, _propertyExpr.split)(depPath)[0];\n if (!~nodes.indexOf(node)) nodes.push(node);\n if (!~excludes.indexOf(`${key}-${node}`)) edges.push([key, node]);\n }\n\n for (const key in fields) if ((0, _has.default)(fields, key)) {\n let value = fields[key];\n if (!~nodes.indexOf(key)) nodes.push(key);\n if (_Reference.default.isRef(value) && value.isSibling) addNode(value.path, key);else if ((0, _isSchema.default)(value) && 'deps' in value) value.deps.forEach(path => addNode(path, key));\n }\n\n return _toposort.default.array(nodes, edges).reverse();\n}", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = sortByKeyOrder;\n\nfunction findIndex(arr, err) {\n let idx = Infinity;\n arr.some((key, ii) => {\n var _err$path;\n\n if (((_err$path = err.path) == null ? void 0 : _err$path.indexOf(key)) !== -1) {\n idx = ii;\n return true;\n }\n });\n return idx;\n}\n\nfunction sortByKeyOrder(keys) {\n return (a, b) => {\n return findIndex(keys, a) - findIndex(keys, b);\n };\n}", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.create = create;\nexports.default = void 0;\n\nvar _has = _interopRequireDefault(require(\"lodash/has\"));\n\nvar _snakeCase = _interopRequireDefault(require(\"lodash/snakeCase\"));\n\nvar _camelCase = _interopRequireDefault(require(\"lodash/camelCase\"));\n\nvar _mapKeys = _interopRequireDefault(require(\"lodash/mapKeys\"));\n\nvar _mapValues = _interopRequireDefault(require(\"lodash/mapValues\"));\n\nvar _propertyExpr = require(\"property-expr\");\n\nvar _locale = require(\"./locale\");\n\nvar _sortFields = _interopRequireDefault(require(\"./util/sortFields\"));\n\nvar _sortByKeyOrder = _interopRequireDefault(require(\"./util/sortByKeyOrder\"));\n\nvar _runTests = _interopRequireDefault(require(\"./util/runTests\"));\n\nvar _ValidationError = _interopRequireDefault(require(\"./ValidationError\"));\n\nvar _schema = _interopRequireDefault(require(\"./schema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nlet isObject = obj => Object.prototype.toString.call(obj) === '[object Object]';\n\nfunction unknown(ctx, value) {\n let known = Object.keys(ctx.fields);\n return Object.keys(value).filter(key => known.indexOf(key) === -1);\n}\n\nconst defaultSort = (0, _sortByKeyOrder.default)([]);\n\nclass ObjectSchema extends _schema.default {\n constructor(spec) {\n super({\n type: 'object'\n });\n this.fields = Object.create(null);\n this._sortErrors = defaultSort;\n this._nodes = [];\n this._excludedEdges = [];\n this.withMutation(() => {\n this.transform(function coerce(value) {\n if (typeof value === 'string') {\n try {\n value = JSON.parse(value);\n } catch (err) {\n value = null;\n }\n }\n\n if (this.isType(value)) return value;\n return null;\n });\n\n if (spec) {\n this.shape(spec);\n }\n });\n }\n\n _typeCheck(value) {\n return isObject(value) || typeof value === 'function';\n }\n\n _cast(_value, options = {}) {\n var _options$stripUnknown;\n\n let value = super._cast(_value, options); //should ignore nulls here\n\n\n if (value === undefined) return this.getDefault();\n if (!this._typeCheck(value)) return value;\n let fields = this.fields;\n let strip = (_options$stripUnknown = options.stripUnknown) != null ? _options$stripUnknown : this.spec.noUnknown;\n\n let props = this._nodes.concat(Object.keys(value).filter(v => this._nodes.indexOf(v) === -1));\n\n let intermediateValue = {}; // is filled during the transform below\n\n let innerOptions = _extends({}, options, {\n parent: intermediateValue,\n __validating: options.__validating || false\n });\n\n let isChanged = false;\n\n for (const prop of props) {\n let field = fields[prop];\n let exists = (0, _has.default)(value, prop);\n\n if (field) {\n let fieldValue;\n let inputValue = value[prop]; // safe to mutate since this is fired in sequence\n\n innerOptions.path = (options.path ? `${options.path}.` : '') + prop; // innerOptions.value = value[prop];\n\n field = field.resolve({\n value: inputValue,\n context: options.context,\n parent: intermediateValue\n });\n let fieldSpec = 'spec' in field ? field.spec : undefined;\n let strict = fieldSpec == null ? void 0 : fieldSpec.strict;\n\n if (fieldSpec == null ? void 0 : fieldSpec.strip) {\n isChanged = isChanged || prop in value;\n continue;\n }\n\n fieldValue = !options.__validating || !strict ? // TODO: use _cast, this is double resolving\n field.cast(value[prop], innerOptions) : value[prop];\n\n if (fieldValue !== undefined) {\n intermediateValue[prop] = fieldValue;\n }\n } else if (exists && !strip) {\n intermediateValue[prop] = value[prop];\n }\n\n if (intermediateValue[prop] !== value[prop]) {\n isChanged = true;\n }\n }\n\n return isChanged ? intermediateValue : value;\n }\n\n _validate(_value, opts = {}, callback) {\n let errors = [];\n let {\n sync,\n from = [],\n originalValue = _value,\n abortEarly = this.spec.abortEarly,\n recursive = this.spec.recursive\n } = opts;\n from = [{\n schema: this,\n value: originalValue\n }, ...from]; // this flag is needed for handling `strict` correctly in the context of\n // validation vs just casting. e.g strict() on a field is only used when validating\n\n opts.__validating = true;\n opts.originalValue = originalValue;\n opts.from = from;\n\n super._validate(_value, opts, (err, value) => {\n if (err) {\n if (!_ValidationError.default.isError(err) || abortEarly) {\n return void callback(err, value);\n }\n\n errors.push(err);\n }\n\n if (!recursive || !isObject(value)) {\n callback(errors[0] || null, value);\n return;\n }\n\n originalValue = originalValue || value;\n\n let tests = this._nodes.map(key => (_, cb) => {\n let path = key.indexOf('.') === -1 ? (opts.path ? `${opts.path}.` : '') + key : `${opts.path || ''}[\"${key}\"]`;\n let field = this.fields[key];\n\n if (field && 'validate' in field) {\n field.validate(value[key], _extends({}, opts, {\n // @ts-ignore\n path,\n from,\n // inner fields are always strict:\n // 1. this isn't strict so the casting will also have cast inner values\n // 2. this is strict in which case the nested values weren't cast either\n strict: true,\n parent: value,\n originalValue: originalValue[key]\n }), cb);\n return;\n }\n\n cb(null);\n });\n\n (0, _runTests.default)({\n sync,\n tests,\n value,\n errors,\n endEarly: abortEarly,\n sort: this._sortErrors,\n path: opts.path\n }, callback);\n });\n }\n\n clone(spec) {\n const next = super.clone(spec);\n next.fields = _extends({}, this.fields);\n next._nodes = this._nodes;\n next._excludedEdges = this._excludedEdges;\n next._sortErrors = this._sortErrors;\n return next;\n }\n\n concat(schema) {\n let next = super.concat(schema);\n let nextFields = next.fields;\n\n for (let [field, schemaOrRef] of Object.entries(this.fields)) {\n const target = nextFields[field];\n\n if (target === undefined) {\n nextFields[field] = schemaOrRef;\n } else if (target instanceof _schema.default && schemaOrRef instanceof _schema.default) {\n nextFields[field] = schemaOrRef.concat(target);\n }\n }\n\n return next.withMutation(() => next.shape(nextFields));\n }\n\n getDefaultFromShape() {\n let dft = {};\n\n this._nodes.forEach(key => {\n const field = this.fields[key];\n dft[key] = 'default' in field ? field.getDefault() : undefined;\n });\n\n return dft;\n }\n\n _getDefault() {\n if ('default' in this.spec) {\n return super._getDefault();\n } // if there is no default set invent one\n\n\n if (!this._nodes.length) {\n return undefined;\n }\n\n return this.getDefaultFromShape();\n }\n\n shape(additions, excludes = []) {\n let next = this.clone();\n let fields = Object.assign(next.fields, additions);\n next.fields = fields;\n next._sortErrors = (0, _sortByKeyOrder.default)(Object.keys(fields));\n\n if (excludes.length) {\n if (!Array.isArray(excludes[0])) excludes = [excludes];\n let keys = excludes.map(([first, second]) => `${first}-${second}`);\n next._excludedEdges = next._excludedEdges.concat(keys);\n }\n\n next._nodes = (0, _sortFields.default)(fields, next._excludedEdges);\n return next;\n }\n\n pick(keys) {\n const picked = {};\n\n for (const key of keys) {\n if (this.fields[key]) picked[key] = this.fields[key];\n }\n\n return this.clone().withMutation(next => {\n next.fields = {};\n return next.shape(picked);\n });\n }\n\n omit(keys) {\n const next = this.clone();\n const fields = next.fields;\n next.fields = {};\n\n for (const key of keys) {\n delete fields[key];\n }\n\n return next.withMutation(() => next.shape(fields));\n }\n\n from(from, to, alias) {\n let fromGetter = (0, _propertyExpr.getter)(from, true);\n return this.transform(obj => {\n if (obj == null) return obj;\n let newObj = obj;\n\n if ((0, _has.default)(obj, from)) {\n newObj = _extends({}, obj);\n if (!alias) delete newObj[from];\n newObj[to] = fromGetter(obj);\n }\n\n return newObj;\n });\n }\n\n noUnknown(noAllow = true, message = _locale.object.noUnknown) {\n if (typeof noAllow === 'string') {\n message = noAllow;\n noAllow = true;\n }\n\n let next = this.test({\n name: 'noUnknown',\n exclusive: true,\n message: message,\n\n test(value) {\n if (value == null) return true;\n const unknownKeys = unknown(this.schema, value);\n return !noAllow || unknownKeys.length === 0 || this.createError({\n params: {\n unknown: unknownKeys.join(', ')\n }\n });\n }\n\n });\n next.spec.noUnknown = noAllow;\n return next;\n }\n\n unknown(allow = true, message = _locale.object.noUnknown) {\n return this.noUnknown(!allow, message);\n }\n\n transformKeys(fn) {\n return this.transform(obj => obj && (0, _mapKeys.default)(obj, (_, key) => fn(key)));\n }\n\n camelCase() {\n return this.transformKeys(_camelCase.default);\n }\n\n snakeCase() {\n return this.transformKeys(_snakeCase.default);\n }\n\n constantCase() {\n return this.transformKeys(key => (0, _snakeCase.default)(key).toUpperCase());\n }\n\n describe() {\n let base = super.describe();\n base.fields = (0, _mapValues.default)(this.fields, value => value.describe());\n return base;\n }\n\n}\n\nexports.default = ObjectSchema;\n\nfunction create(spec) {\n return new ObjectSchema(spec);\n}\n\ncreate.prototype = ObjectSchema.prototype;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.create = create;\nexports.default = void 0;\n\nvar _isAbsent = _interopRequireDefault(require(\"./util/isAbsent\"));\n\nvar _isSchema = _interopRequireDefault(require(\"./util/isSchema\"));\n\nvar _printValue = _interopRequireDefault(require(\"./util/printValue\"));\n\nvar _locale = require(\"./locale\");\n\nvar _runTests = _interopRequireDefault(require(\"./util/runTests\"));\n\nvar _ValidationError = _interopRequireDefault(require(\"./ValidationError\"));\n\nvar _schema = _interopRequireDefault(require(\"./schema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nfunction create(type) {\n return new ArraySchema(type);\n}\n\nclass ArraySchema extends _schema.default {\n constructor(type) {\n super({\n type: 'array'\n }); // `undefined` specifically means uninitialized, as opposed to\n // \"no subtype\"\n\n this.innerType = type;\n this.withMutation(() => {\n this.transform(function (values) {\n if (typeof values === 'string') try {\n values = JSON.parse(values);\n } catch (err) {\n values = null;\n }\n return this.isType(values) ? values : null;\n });\n });\n }\n\n _typeCheck(v) {\n return Array.isArray(v);\n }\n\n get _subType() {\n return this.innerType;\n }\n\n _cast(_value, _opts) {\n const value = super._cast(_value, _opts); //should ignore nulls here\n\n\n if (!this._typeCheck(value) || !this.innerType) return value;\n let isChanged = false;\n const castArray = value.map((v, idx) => {\n const castElement = this.innerType.cast(v, _extends({}, _opts, {\n path: `${_opts.path || ''}[${idx}]`\n }));\n\n if (castElement !== v) {\n isChanged = true;\n }\n\n return castElement;\n });\n return isChanged ? castArray : value;\n }\n\n _validate(_value, options = {}, callback) {\n var _options$abortEarly, _options$recursive;\n\n let errors = [];\n let sync = options.sync;\n let path = options.path;\n let innerType = this.innerType;\n let endEarly = (_options$abortEarly = options.abortEarly) != null ? _options$abortEarly : this.spec.abortEarly;\n let recursive = (_options$recursive = options.recursive) != null ? _options$recursive : this.spec.recursive;\n let originalValue = options.originalValue != null ? options.originalValue : _value;\n\n super._validate(_value, options, (err, value) => {\n if (err) {\n if (!_ValidationError.default.isError(err) || endEarly) {\n return void callback(err, value);\n }\n\n errors.push(err);\n }\n\n if (!recursive || !innerType || !this._typeCheck(value)) {\n callback(errors[0] || null, value);\n return;\n }\n\n originalValue = originalValue || value; // #950 Ensure that sparse array empty slots are validated\n\n let tests = new Array(value.length);\n\n for (let idx = 0; idx < value.length; idx++) {\n let item = value[idx];\n let path = `${options.path || ''}[${idx}]`; // object._validate note for isStrict explanation\n\n let innerOptions = _extends({}, options, {\n path,\n strict: true,\n parent: value,\n index: idx,\n originalValue: originalValue[idx]\n });\n\n tests[idx] = (_, cb) => innerType.validate(item, innerOptions, cb);\n }\n\n (0, _runTests.default)({\n sync,\n path,\n value,\n errors,\n endEarly,\n tests\n }, callback);\n });\n }\n\n clone(spec) {\n const next = super.clone(spec);\n next.innerType = this.innerType;\n return next;\n }\n\n concat(schema) {\n let next = super.concat(schema);\n next.innerType = this.innerType;\n if (schema.innerType) next.innerType = next.innerType ? // @ts-expect-error Lazy doesn't have concat()\n next.innerType.concat(schema.innerType) : schema.innerType;\n return next;\n }\n\n of(schema) {\n // FIXME: this should return a new instance of array without the default to be\n let next = this.clone();\n if (!(0, _isSchema.default)(schema)) throw new TypeError('`array.of()` sub-schema must be a valid yup schema not: ' + (0, _printValue.default)(schema)); // FIXME(ts):\n\n next.innerType = schema;\n return next;\n }\n\n length(length, message = _locale.array.length) {\n return this.test({\n message,\n name: 'length',\n exclusive: true,\n params: {\n length\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value.length === this.resolve(length);\n }\n\n });\n }\n\n min(min, message) {\n message = message || _locale.array.min;\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n // FIXME(ts): Array\n test(value) {\n return (0, _isAbsent.default)(value) || value.length >= this.resolve(min);\n }\n\n });\n }\n\n max(max, message) {\n message = message || _locale.array.max;\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n max\n },\n\n test(value) {\n return (0, _isAbsent.default)(value) || value.length <= this.resolve(max);\n }\n\n });\n }\n\n ensure() {\n return this.default(() => []).transform((val, original) => {\n // We don't want to return `null` for nullable schema\n if (this._typeCheck(val)) return val;\n return original == null ? [] : [].concat(original);\n });\n }\n\n compact(rejector) {\n let reject = !rejector ? v => !!v : (v, i, a) => !rejector(v, i, a);\n return this.transform(values => values != null ? values.filter(reject) : values);\n }\n\n describe() {\n let base = super.describe();\n if (this.innerType) base.innerType = this.innerType.describe();\n return base;\n }\n\n nullable(isNullable = true) {\n return super.nullable(isNullable);\n }\n\n defined() {\n return super.defined();\n }\n\n required(msg) {\n return super.required(msg);\n }\n\n}\n\nexports.default = ArraySchema;\ncreate.prototype = ArraySchema.prototype; //\n// Interfaces\n//", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.create = create;\nexports.default = void 0;\n\nvar _isSchema = _interopRequireDefault(require(\"./util/isSchema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction create(builder) {\n return new Lazy(builder);\n}\n\nclass Lazy {\n constructor(builder) {\n this.type = 'lazy';\n this.__isYupSchema__ = true;\n\n this._resolve = (value, options = {}) => {\n let schema = this.builder(value, options);\n if (!(0, _isSchema.default)(schema)) throw new TypeError('lazy() functions must return a valid schema');\n return schema.resolve(options);\n };\n\n this.builder = builder;\n }\n\n resolve(options) {\n return this._resolve(options.value, options);\n }\n\n cast(value, options) {\n return this._resolve(value, options).cast(value, options);\n }\n\n validate(value, options, maybeCb) {\n // @ts-expect-error missing public callback on type\n return this._resolve(value, options).validate(value, options, maybeCb);\n }\n\n validateSync(value, options) {\n return this._resolve(value, options).validateSync(value, options);\n }\n\n validateAt(path, value, options) {\n return this._resolve(value, options).validateAt(path, value, options);\n }\n\n validateSyncAt(path, value, options) {\n return this._resolve(value, options).validateSyncAt(path, value, options);\n }\n\n describe() {\n return null;\n }\n\n isValid(value, options) {\n return this._resolve(value, options).isValid(value, options);\n }\n\n isValidSync(value, options) {\n return this._resolve(value, options).isValidSync(value, options);\n }\n\n}\n\nvar _default = Lazy;\nexports.default = _default;", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = setLocale;\n\nvar _locale = _interopRequireDefault(require(\"./locale\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction setLocale(custom) {\n Object.keys(custom).forEach(type => {\n Object.keys(custom[type]).forEach(method => {\n _locale.default[type][method] = custom[type][method];\n });\n });\n}", "\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.addMethod = addMethod;\nObject.defineProperty(exports, \"MixedSchema\", {\n enumerable: true,\n get: function () {\n return _mixed.default;\n }\n});\nObject.defineProperty(exports, \"mixed\", {\n enumerable: true,\n get: function () {\n return _mixed.create;\n }\n});\nObject.defineProperty(exports, \"BooleanSchema\", {\n enumerable: true,\n get: function () {\n return _boolean.default;\n }\n});\nObject.defineProperty(exports, \"bool\", {\n enumerable: true,\n get: function () {\n return _boolean.create;\n }\n});\nObject.defineProperty(exports, \"boolean\", {\n enumerable: true,\n get: function () {\n return _boolean.create;\n }\n});\nObject.defineProperty(exports, \"StringSchema\", {\n enumerable: true,\n get: function () {\n return _string.default;\n }\n});\nObject.defineProperty(exports, \"string\", {\n enumerable: true,\n get: function () {\n return _string.create;\n }\n});\nObject.defineProperty(exports, \"NumberSchema\", {\n enumerable: true,\n get: function () {\n return _number.default;\n }\n});\nObject.defineProperty(exports, \"number\", {\n enumerable: true,\n get: function () {\n return _number.create;\n }\n});\nObject.defineProperty(exports, \"DateSchema\", {\n enumerable: true,\n get: function () {\n return _date.default;\n }\n});\nObject.defineProperty(exports, \"date\", {\n enumerable: true,\n get: function () {\n return _date.create;\n }\n});\nObject.defineProperty(exports, \"ObjectSchema\", {\n enumerable: true,\n get: function () {\n return _object.default;\n }\n});\nObject.defineProperty(exports, \"object\", {\n enumerable: true,\n get: function () {\n return _object.create;\n }\n});\nObject.defineProperty(exports, \"ArraySchema\", {\n enumerable: true,\n get: function () {\n return _array.default;\n }\n});\nObject.defineProperty(exports, \"array\", {\n enumerable: true,\n get: function () {\n return _array.create;\n }\n});\nObject.defineProperty(exports, \"ref\", {\n enumerable: true,\n get: function () {\n return _Reference.create;\n }\n});\nObject.defineProperty(exports, \"lazy\", {\n enumerable: true,\n get: function () {\n return _Lazy.create;\n }\n});\nObject.defineProperty(exports, \"ValidationError\", {\n enumerable: true,\n get: function () {\n return _ValidationError.default;\n }\n});\nObject.defineProperty(exports, \"reach\", {\n enumerable: true,\n get: function () {\n return _reach.default;\n }\n});\nObject.defineProperty(exports, \"isSchema\", {\n enumerable: true,\n get: function () {\n return _isSchema.default;\n }\n});\nObject.defineProperty(exports, \"setLocale\", {\n enumerable: true,\n get: function () {\n return _setLocale.default;\n }\n});\nObject.defineProperty(exports, \"BaseSchema\", {\n enumerable: true,\n get: function () {\n return _schema.default;\n }\n});\n\nvar _mixed = _interopRequireWildcard(require(\"./mixed\"));\n\nvar _boolean = _interopRequireWildcard(require(\"./boolean\"));\n\nvar _string = _interopRequireWildcard(require(\"./string\"));\n\nvar _number = _interopRequireWildcard(require(\"./number\"));\n\nvar _date = _interopRequireWildcard(require(\"./date\"));\n\nvar _object = _interopRequireWildcard(require(\"./object\"));\n\nvar _array = _interopRequireWildcard(require(\"./array\"));\n\nvar _Reference = require(\"./Reference\");\n\nvar _Lazy = require(\"./Lazy\");\n\nvar _ValidationError = _interopRequireDefault(require(\"./ValidationError\"));\n\nvar _reach = _interopRequireDefault(require(\"./util/reach\"));\n\nvar _isSchema = _interopRequireDefault(require(\"./util/isSchema\"));\n\nvar _setLocale = _interopRequireDefault(require(\"./setLocale\"));\n\nvar _schema = _interopRequireDefault(require(\"./schema\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _getRequireWildcardCache() { if (typeof WeakMap !== \"function\") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }\n\nfunction _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== \"object\" && typeof obj !== \"function\") { return { default: obj }; } var cache = _getRequireWildcardCache(); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }\n\nfunction addMethod(schemaType, name, fn) {\n if (!schemaType || !(0, _isSchema.default)(schemaType.prototype)) throw new TypeError('You must provide a yup schema constructor function');\n if (typeof name !== 'string') throw new TypeError('A Method name must be provided');\n if (typeof fn !== 'function') throw new TypeError('Method function must be provided');\n schemaType.prototype[name] = fn;\n}", "const fs = require('fs')\nconst path = require('path')\nconst os = require('os')\nconst packageJson = require('../package.json')\n\nconst version = packageJson.version\n\nconst LINE = /(?:^|^)\\s*(?:export\\s+)?([\\w.-]+)(?:\\s*=\\s*?|:\\s+?)(\\s*'(?:\\\\'|[^'])*'|\\s*\"(?:\\\\\"|[^\"])*\"|\\s*`(?:\\\\`|[^`])*`|[^#\\r\\n]+)?\\s*(?:#.*)?(?:$|$)/mg\n\n// Parser src into an Object\nfunction parse (src) {\n const obj = {}\n\n // Convert buffer to string\n let lines = src.toString()\n\n // Convert line breaks to same format\n lines = lines.replace(/\\r\\n?/mg, '\\n')\n\n let match\n while ((match = LINE.exec(lines)) != null) {\n const key = match[1]\n\n // Default undefined or null to empty string\n let value = (match[2] || '')\n\n // Remove whitespace\n value = value.trim()\n\n // Check if double quoted\n const maybeQuote = value[0]\n\n // Remove surrounding quotes\n value = value.replace(/^(['\"`])([\\s\\S]*)\\1$/mg, '$2')\n\n // Expand newlines if double quoted\n if (maybeQuote === '\"') {\n value = value.replace(/\\\\n/g, '\\n')\n value = value.replace(/\\\\r/g, '\\r')\n }\n\n // Add to object\n obj[key] = value\n }\n\n return obj\n}\n\nfunction _log (message) {\n console.log(`[dotenv@${version}][DEBUG] ${message}`)\n}\n\nfunction _resolveHome (envPath) {\n return envPath[0] === '~' ? path.join(os.homedir(), envPath.slice(1)) : envPath\n}\n\n// Populates process.env from .env file\nfunction config (options) {\n let dotenvPath = path.resolve(process.cwd(), '.env')\n let encoding = 'utf8'\n const debug = Boolean(options && options.debug)\n const override = Boolean(options && options.override)\n\n if (options) {\n if (options.path != null) {\n dotenvPath = _resolveHome(options.path)\n }\n if (options.encoding != null) {\n encoding = options.encoding\n }\n }\n\n try {\n // Specifying an encoding returns a string instead of a buffer\n const parsed = DotenvModule.parse(fs.readFileSync(dotenvPath, { encoding }))\n\n Object.keys(parsed).forEach(function (key) {\n if (!Object.prototype.hasOwnProperty.call(process.env, key)) {\n process.env[key] = parsed[key]\n } else {\n if (override === true) {\n process.env[key] = parsed[key]\n }\n\n if (debug) {\n if (override === true) {\n _log(`\"${key}\" is already defined in \\`process.env\\` and WAS overwritten`)\n } else {\n _log(`\"${key}\" is already defined in \\`process.env\\` and was NOT overwritten`)\n }\n }\n }\n })\n\n return { parsed }\n } catch (e) {\n if (debug) {\n _log(`Failed to load ${dotenvPath} ${e.message}`)\n }\n\n return { error: e }\n }\n}\n\nconst DotenvModule = {\n config,\n parse\n}\n\nmodule.exports.config = DotenvModule.config\nmodule.exports.parse = DotenvModule.parse\nmodule.exports = DotenvModule\n", "(()=>{var __webpack_modules__={\"./node_modules/.pnpm/create-require@1.1.1/node_modules/create-require/create-require.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const nativeModule=__webpack_require__(\"module\"),path=__webpack_require__(\"path\"),fs=__webpack_require__(\"fs\");module.exports=function(filename){return filename||(filename=process.cwd()),function(path){try{return fs.lstatSync(path).isDirectory()}catch(e){return!1}}(filename)&&(filename=path.join(filename,\"index.js\")),nativeModule.createRequire?nativeModule.createRequire(filename):nativeModule.createRequireFromPath?nativeModule.createRequireFromPath(filename):function(filename){const mod=new nativeModule.Module(filename,null);return mod.filename=filename,mod.paths=nativeModule.Module._nodeModulePaths(path.dirname(filename)),mod._compile(\"module.exports = require;\",filename),mod.exports}(filename)}},\"./node_modules/.pnpm/lru-cache@6.0.0/node_modules/lru-cache/index.js\":(module,__unused_webpack_exports,__webpack_require__)=>{\"use strict\";const Yallist=__webpack_require__(\"./node_modules/.pnpm/yallist@4.0.0/node_modules/yallist/yallist.js\"),MAX=Symbol(\"max\"),LENGTH=Symbol(\"length\"),LENGTH_CALCULATOR=Symbol(\"lengthCalculator\"),ALLOW_STALE=Symbol(\"allowStale\"),MAX_AGE=Symbol(\"maxAge\"),DISPOSE=Symbol(\"dispose\"),NO_DISPOSE_ON_SET=Symbol(\"noDisposeOnSet\"),LRU_LIST=Symbol(\"lruList\"),CACHE=Symbol(\"cache\"),UPDATE_AGE_ON_GET=Symbol(\"updateAgeOnGet\"),naiveLength=()=>1;const get=(self,key,doUse)=>{const node=self[CACHE].get(key);if(node){const hit=node.value;if(isStale(self,hit)){if(del(self,node),!self[ALLOW_STALE])return}else doUse&&(self[UPDATE_AGE_ON_GET]&&(node.value.now=Date.now()),self[LRU_LIST].unshiftNode(node));return hit.value}},isStale=(self,hit)=>{if(!hit||!hit.maxAge&&!self[MAX_AGE])return!1;const diff=Date.now()-hit.now;return hit.maxAge?diff>hit.maxAge:self[MAX_AGE]&&diff>self[MAX_AGE]},trim=self=>{if(self[LENGTH]>self[MAX])for(let walker=self[LRU_LIST].tail;self[LENGTH]>self[MAX]&&null!==walker;){const prev=walker.prev;del(self,walker),walker=prev}},del=(self,node)=>{if(node){const hit=node.value;self[DISPOSE]&&self[DISPOSE](hit.key,hit.value),self[LENGTH]-=hit.length,self[CACHE].delete(hit.key),self[LRU_LIST].removeNode(node)}};class Entry{constructor(key,value,length,now,maxAge){this.key=key,this.value=value,this.length=length,this.now=now,this.maxAge=maxAge||0}}const forEachStep=(self,fn,node,thisp)=>{let hit=node.value;isStale(self,hit)&&(del(self,node),self[ALLOW_STALE]||(hit=void 0)),hit&&fn.call(thisp,hit.value,hit.key,self)};module.exports=class{constructor(options){if(\"number\"==typeof options&&(options={max:options}),options||(options={}),options.max&&(\"number\"!=typeof options.max||options.max<0))throw new TypeError(\"max must be a non-negative number\");this[MAX]=options.max||1/0;const lc=options.length||naiveLength;if(this[LENGTH_CALCULATOR]=\"function\"!=typeof lc?naiveLength:lc,this[ALLOW_STALE]=options.stale||!1,options.maxAge&&\"number\"!=typeof options.maxAge)throw new TypeError(\"maxAge must be a number\");this[MAX_AGE]=options.maxAge||0,this[DISPOSE]=options.dispose,this[NO_DISPOSE_ON_SET]=options.noDisposeOnSet||!1,this[UPDATE_AGE_ON_GET]=options.updateAgeOnGet||!1,this.reset()}set max(mL){if(\"number\"!=typeof mL||mL<0)throw new TypeError(\"max must be a non-negative number\");this[MAX]=mL||1/0,trim(this)}get max(){return this[MAX]}set allowStale(allowStale){this[ALLOW_STALE]=!!allowStale}get allowStale(){return this[ALLOW_STALE]}set maxAge(mA){if(\"number\"!=typeof mA)throw new TypeError(\"maxAge must be a non-negative number\");this[MAX_AGE]=mA,trim(this)}get maxAge(){return this[MAX_AGE]}set lengthCalculator(lC){\"function\"!=typeof lC&&(lC=naiveLength),lC!==this[LENGTH_CALCULATOR]&&(this[LENGTH_CALCULATOR]=lC,this[LENGTH]=0,this[LRU_LIST].forEach((hit=>{hit.length=this[LENGTH_CALCULATOR](hit.value,hit.key),this[LENGTH]+=hit.length}))),trim(this)}get lengthCalculator(){return this[LENGTH_CALCULATOR]}get length(){return this[LENGTH]}get itemCount(){return this[LRU_LIST].length}rforEach(fn,thisp){thisp=thisp||this;for(let walker=this[LRU_LIST].tail;null!==walker;){const prev=walker.prev;forEachStep(this,fn,walker,thisp),walker=prev}}forEach(fn,thisp){thisp=thisp||this;for(let walker=this[LRU_LIST].head;null!==walker;){const next=walker.next;forEachStep(this,fn,walker,thisp),walker=next}}keys(){return this[LRU_LIST].toArray().map((k=>k.key))}values(){return this[LRU_LIST].toArray().map((k=>k.value))}reset(){this[DISPOSE]&&this[LRU_LIST]&&this[LRU_LIST].length&&this[LRU_LIST].forEach((hit=>this[DISPOSE](hit.key,hit.value))),this[CACHE]=new Map,this[LRU_LIST]=new Yallist,this[LENGTH]=0}dump(){return this[LRU_LIST].map((hit=>!isStale(this,hit)&&{k:hit.key,v:hit.value,e:hit.now+(hit.maxAge||0)})).toArray().filter((h=>h))}dumpLru(){return this[LRU_LIST]}set(key,value,maxAge){if((maxAge=maxAge||this[MAX_AGE])&&\"number\"!=typeof maxAge)throw new TypeError(\"maxAge must be a number\");const now=maxAge?Date.now():0,len=this[LENGTH_CALCULATOR](value,key);if(this[CACHE].has(key)){if(len>this[MAX])return del(this,this[CACHE].get(key)),!1;const item=this[CACHE].get(key).value;return this[DISPOSE]&&(this[NO_DISPOSE_ON_SET]||this[DISPOSE](key,item.value)),item.now=now,item.maxAge=maxAge,item.value=value,this[LENGTH]+=len-item.length,item.length=len,this.get(key),trim(this),!0}const hit=new Entry(key,value,len,now,maxAge);return hit.length>this[MAX]?(this[DISPOSE]&&this[DISPOSE](key,value),!1):(this[LENGTH]+=hit.length,this[LRU_LIST].unshift(hit),this[CACHE].set(key,this[LRU_LIST].head),trim(this),!0)}has(key){if(!this[CACHE].has(key))return!1;const hit=this[CACHE].get(key).value;return!isStale(this,hit)}get(key){return get(this,key,!0)}peek(key){return get(this,key,!1)}pop(){const node=this[LRU_LIST].tail;return node?(del(this,node),node.value):null}del(key){del(this,this[CACHE].get(key))}load(arr){this.reset();const now=Date.now();for(let l=arr.length-1;l>=0;l--){const hit=arr[l],expiresAt=hit.e||0;if(0===expiresAt)this.set(hit.k,hit.v);else{const maxAge=expiresAt-now;maxAge>0&&this.set(hit.k,hit.v,maxAge)}}}prune(){this[CACHE].forEach(((value,key)=>get(this,key,!1)))}}},\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/index.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const optsArg=__webpack_require__(\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/opts-arg.js\"),pathArg=__webpack_require__(\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/path-arg.js\"),{mkdirpNative,mkdirpNativeSync}=__webpack_require__(\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/mkdirp-native.js\"),{mkdirpManual,mkdirpManualSync}=__webpack_require__(\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/mkdirp-manual.js\"),{useNative,useNativeSync}=__webpack_require__(\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/use-native.js\"),mkdirp=(path,opts)=>(path=pathArg(path),opts=optsArg(opts),useNative(opts)?mkdirpNative(path,opts):mkdirpManual(path,opts));mkdirp.sync=(path,opts)=>(path=pathArg(path),opts=optsArg(opts),useNativeSync(opts)?mkdirpNativeSync(path,opts):mkdirpManualSync(path,opts)),mkdirp.native=(path,opts)=>mkdirpNative(pathArg(path),optsArg(opts)),mkdirp.manual=(path,opts)=>mkdirpManual(pathArg(path),optsArg(opts)),mkdirp.nativeSync=(path,opts)=>mkdirpNativeSync(pathArg(path),optsArg(opts)),mkdirp.manualSync=(path,opts)=>mkdirpManualSync(pathArg(path),optsArg(opts)),module.exports=mkdirp},\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/find-made.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const{dirname}=__webpack_require__(\"path\"),findMade=(opts,parent,path)=>path===parent?Promise.resolve():opts.statAsync(parent).then((st=>st.isDirectory()?path:void 0),(er=>\"ENOENT\"===er.code?findMade(opts,dirname(parent),parent):void 0)),findMadeSync=(opts,parent,path)=>{if(path!==parent)try{return opts.statSync(parent).isDirectory()?path:void 0}catch(er){return\"ENOENT\"===er.code?findMadeSync(opts,dirname(parent),parent):void 0}};module.exports={findMade,findMadeSync}},\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/mkdirp-manual.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const{dirname}=__webpack_require__(\"path\"),mkdirpManual=(path,opts,made)=>{opts.recursive=!1;const parent=dirname(path);return parent===path?opts.mkdirAsync(path,opts).catch((er=>{if(\"EISDIR\"!==er.code)throw er})):opts.mkdirAsync(path,opts).then((()=>made||path),(er=>{if(\"ENOENT\"===er.code)return mkdirpManual(parent,opts).then((made=>mkdirpManual(path,opts,made)));if(\"EEXIST\"!==er.code&&\"EROFS\"!==er.code)throw er;return opts.statAsync(path).then((st=>{if(st.isDirectory())return made;throw er}),(()=>{throw er}))}))},mkdirpManualSync=(path,opts,made)=>{const parent=dirname(path);if(opts.recursive=!1,parent===path)try{return opts.mkdirSync(path,opts)}catch(er){if(\"EISDIR\"!==er.code)throw er;return}try{return opts.mkdirSync(path,opts),made||path}catch(er){if(\"ENOENT\"===er.code)return mkdirpManualSync(path,opts,mkdirpManualSync(parent,opts,made));if(\"EEXIST\"!==er.code&&\"EROFS\"!==er.code)throw er;try{if(!opts.statSync(path).isDirectory())throw er}catch(_){throw er}}};module.exports={mkdirpManual,mkdirpManualSync}},\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/mkdirp-native.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const{dirname}=__webpack_require__(\"path\"),{findMade,findMadeSync}=__webpack_require__(\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/find-made.js\"),{mkdirpManual,mkdirpManualSync}=__webpack_require__(\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/mkdirp-manual.js\");module.exports={mkdirpNative:(path,opts)=>{opts.recursive=!0;return dirname(path)===path?opts.mkdirAsync(path,opts):findMade(opts,path).then((made=>opts.mkdirAsync(path,opts).then((()=>made)).catch((er=>{if(\"ENOENT\"===er.code)return mkdirpManual(path,opts);throw er}))))},mkdirpNativeSync:(path,opts)=>{opts.recursive=!0;if(dirname(path)===path)return opts.mkdirSync(path,opts);const made=findMadeSync(opts,path);try{return opts.mkdirSync(path,opts),made}catch(er){if(\"ENOENT\"===er.code)return mkdirpManualSync(path,opts);throw er}}}},\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/opts-arg.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const{promisify}=__webpack_require__(\"util\"),fs=__webpack_require__(\"fs\");module.exports=opts=>{if(opts)if(\"object\"==typeof opts)opts={mode:511,fs,...opts};else if(\"number\"==typeof opts)opts={mode:opts,fs};else{if(\"string\"!=typeof opts)throw new TypeError(\"invalid options argument\");opts={mode:parseInt(opts,8),fs}}else opts={mode:511,fs};return opts.mkdir=opts.mkdir||opts.fs.mkdir||fs.mkdir,opts.mkdirAsync=promisify(opts.mkdir),opts.stat=opts.stat||opts.fs.stat||fs.stat,opts.statAsync=promisify(opts.stat),opts.statSync=opts.statSync||opts.fs.statSync||fs.statSync,opts.mkdirSync=opts.mkdirSync||opts.fs.mkdirSync||fs.mkdirSync,opts}},\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/path-arg.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const platform=process.env.__TESTING_MKDIRP_PLATFORM__||process.platform,{resolve,parse}=__webpack_require__(\"path\");module.exports=path=>{if(/\\0/.test(path))throw Object.assign(new TypeError(\"path must be a string without null bytes\"),{path,code:\"ERR_INVALID_ARG_VALUE\"});if(path=resolve(path),\"win32\"===platform){const badWinChars=/[*|\"<>?:]/,{root}=parse(path);if(badWinChars.test(path.substr(root.length)))throw Object.assign(new Error(\"Illegal characters in path.\"),{path,code:\"EINVAL\"})}return path}},\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/lib/use-native.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const fs=__webpack_require__(\"fs\"),versArr=(process.env.__TESTING_MKDIRP_NODE_VERSION__||process.version).replace(/^v/,\"\").split(\".\"),hasNative=+versArr[0]>10||10==+versArr[0]&&+versArr[1]>=12,useNative=hasNative?opts=>opts.mkdir===fs.mkdir:()=>!1,useNativeSync=hasNative?opts=>opts.mkdirSync===fs.mkdirSync:()=>!1;module.exports={useNative,useNativeSync}},\"./node_modules/.pnpm/mlly@0.5.14/node_modules/mlly/dist lazy recursive\":module=>{function webpackEmptyAsyncContext(req){return Promise.resolve().then((()=>{var e=new Error(\"Cannot find module '\"+req+\"'\");throw e.code=\"MODULE_NOT_FOUND\",e}))}webpackEmptyAsyncContext.keys=()=>[],webpackEmptyAsyncContext.resolve=webpackEmptyAsyncContext,webpackEmptyAsyncContext.id=\"./node_modules/.pnpm/mlly@0.5.14/node_modules/mlly/dist lazy recursive\",module.exports=webpackEmptyAsyncContext},\"./node_modules/.pnpm/object-hash@3.0.0/node_modules/object-hash/index.js\":(module,exports,__webpack_require__)=>{\"use strict\";var crypto=__webpack_require__(\"crypto\");function objectHash(object,options){return function(object,options){var hashingStream;hashingStream=\"passthrough\"!==options.algorithm?crypto.createHash(options.algorithm):new PassThrough;void 0===hashingStream.write&&(hashingStream.write=hashingStream.update,hashingStream.end=hashingStream.update);typeHasher(options,hashingStream).dispatch(object),hashingStream.update||hashingStream.end(\"\");if(hashingStream.digest)return hashingStream.digest(\"buffer\"===options.encoding?void 0:options.encoding);var buf=hashingStream.read();if(\"buffer\"===options.encoding)return buf;return buf.toString(options.encoding)}(object,options=applyDefaults(object,options))}(exports=module.exports=objectHash).sha1=function(object){return objectHash(object)},exports.keys=function(object){return objectHash(object,{excludeValues:!0,algorithm:\"sha1\",encoding:\"hex\"})},exports.MD5=function(object){return objectHash(object,{algorithm:\"md5\",encoding:\"hex\"})},exports.keysMD5=function(object){return objectHash(object,{algorithm:\"md5\",encoding:\"hex\",excludeValues:!0})};var hashes=crypto.getHashes?crypto.getHashes().slice():[\"sha1\",\"md5\"];hashes.push(\"passthrough\");var encodings=[\"buffer\",\"hex\",\"binary\",\"base64\"];function applyDefaults(object,sourceOptions){sourceOptions=sourceOptions||{};var options={};if(options.algorithm=sourceOptions.algorithm||\"sha1\",options.encoding=sourceOptions.encoding||\"hex\",options.excludeValues=!!sourceOptions.excludeValues,options.algorithm=options.algorithm.toLowerCase(),options.encoding=options.encoding.toLowerCase(),options.ignoreUnknown=!0===sourceOptions.ignoreUnknown,options.respectType=!1!==sourceOptions.respectType,options.respectFunctionNames=!1!==sourceOptions.respectFunctionNames,options.respectFunctionProperties=!1!==sourceOptions.respectFunctionProperties,options.unorderedArrays=!0===sourceOptions.unorderedArrays,options.unorderedSets=!1!==sourceOptions.unorderedSets,options.unorderedObjects=!1!==sourceOptions.unorderedObjects,options.replacer=sourceOptions.replacer||void 0,options.excludeKeys=sourceOptions.excludeKeys||void 0,void 0===object)throw new Error(\"Object argument required.\");for(var i=0;i=0)return this.dispatch(\"[CIRCULAR:\"+objectNumber+\"]\");if(context.push(object),\"undefined\"!=typeof Buffer&&Buffer.isBuffer&&Buffer.isBuffer(object))return write(\"buffer:\"),write(object);if(\"object\"===objType||\"function\"===objType||\"asyncfunction\"===objType){var keys=Object.keys(object);options.unorderedObjects&&(keys=keys.sort()),!1===options.respectType||isNativeFunction(object)||keys.splice(0,0,\"prototype\",\"__proto__\",\"constructor\"),options.excludeKeys&&(keys=keys.filter((function(key){return!options.excludeKeys(key)}))),write(\"object:\"+keys.length+\":\");var self=this;return keys.forEach((function(key){self.dispatch(key),write(\":\"),options.excludeValues||self.dispatch(object[key]),write(\",\")}))}if(!this[\"_\"+objType]){if(options.ignoreUnknown)return write(\"[\"+objType+\"]\");throw new Error('Unknown object type \"'+objType+'\"')}this[\"_\"+objType](object)},_array:function(arr,unordered){unordered=void 0!==unordered?unordered:!1!==options.unorderedArrays;var self=this;if(write(\"array:\"+arr.length+\":\"),!unordered||arr.length<=1)return arr.forEach((function(entry){return self.dispatch(entry)}));var contextAdditions=[],entries=arr.map((function(entry){var strm=new PassThrough,localContext=context.slice();return typeHasher(options,strm,localContext).dispatch(entry),contextAdditions=contextAdditions.concat(localContext.slice(context.length)),strm.read().toString()}));return context=context.concat(contextAdditions),entries.sort(),this._array(entries,!1)},_date:function(date){return write(\"date:\"+date.toJSON())},_symbol:function(sym){return write(\"symbol:\"+sym.toString())},_error:function(err){return write(\"error:\"+err.toString())},_boolean:function(bool){return write(\"bool:\"+bool.toString())},_string:function(string){write(\"string:\"+string.length+\":\"),write(string.toString())},_function:function(fn){write(\"fn:\"),isNativeFunction(fn)?this.dispatch(\"[native]\"):this.dispatch(fn.toString()),!1!==options.respectFunctionNames&&this.dispatch(\"function-name:\"+String(fn.name)),options.respectFunctionProperties&&this._object(fn)},_number:function(number){return write(\"number:\"+number.toString())},_xml:function(xml){return write(\"xml:\"+xml.toString())},_null:function(){return write(\"Null\")},_undefined:function(){return write(\"Undefined\")},_regexp:function(regex){return write(\"regex:\"+regex.toString())},_uint8array:function(arr){return write(\"uint8array:\"),this.dispatch(Array.prototype.slice.call(arr))},_uint8clampedarray:function(arr){return write(\"uint8clampedarray:\"),this.dispatch(Array.prototype.slice.call(arr))},_int8array:function(arr){return write(\"int8array:\"),this.dispatch(Array.prototype.slice.call(arr))},_uint16array:function(arr){return write(\"uint16array:\"),this.dispatch(Array.prototype.slice.call(arr))},_int16array:function(arr){return write(\"int16array:\"),this.dispatch(Array.prototype.slice.call(arr))},_uint32array:function(arr){return write(\"uint32array:\"),this.dispatch(Array.prototype.slice.call(arr))},_int32array:function(arr){return write(\"int32array:\"),this.dispatch(Array.prototype.slice.call(arr))},_float32array:function(arr){return write(\"float32array:\"),this.dispatch(Array.prototype.slice.call(arr))},_float64array:function(arr){return write(\"float64array:\"),this.dispatch(Array.prototype.slice.call(arr))},_arraybuffer:function(arr){return write(\"arraybuffer:\"),this.dispatch(new Uint8Array(arr))},_url:function(url){return write(\"url:\"+url.toString())},_map:function(map){write(\"map:\");var arr=Array.from(map);return this._array(arr,!1!==options.unorderedSets)},_set:function(set){write(\"set:\");var arr=Array.from(set);return this._array(arr,!1!==options.unorderedSets)},_file:function(file){return write(\"file:\"),this.dispatch([file.name,file.size,file.type,file.lastModfied])},_blob:function(){if(options.ignoreUnknown)return write(\"[blob]\");throw Error('Hashing Blob objects is currently not supported\\n(see https://github.com/puleos/object-hash/issues/26)\\nUse \"options.replacer\" or \"options.ignoreUnknown\"\\n')},_domwindow:function(){return write(\"domwindow\")},_bigint:function(number){return write(\"bigint:\"+number.toString())},_process:function(){return write(\"process\")},_timer:function(){return write(\"timer\")},_pipe:function(){return write(\"pipe\")},_tcp:function(){return write(\"tcp\")},_udp:function(){return write(\"udp\")},_tty:function(){return write(\"tty\")},_statwatcher:function(){return write(\"statwatcher\")},_securecontext:function(){return write(\"securecontext\")},_connection:function(){return write(\"connection\")},_zlib:function(){return write(\"zlib\")},_context:function(){return write(\"context\")},_nodescript:function(){return write(\"nodescript\")},_httpparser:function(){return write(\"httpparser\")},_dataview:function(){return write(\"dataview\")},_signal:function(){return write(\"signal\")},_fsevent:function(){return write(\"fsevent\")},_tlswrap:function(){return write(\"tlswrap\")}}}function PassThrough(){return{buf:\"\",write:function(b){this.buf+=b},end:function(b){this.buf+=b},read:function(){return this.buf}}}exports.writeToStream=function(object,options,stream){return void 0===stream&&(stream=options,options={}),typeHasher(options=applyDefaults(object,options),stream).dispatch(object)}},\"./node_modules/.pnpm/pirates@4.0.5/node_modules/pirates/lib/index.js\":(module,exports,__webpack_require__)=>{\"use strict\";module=__webpack_require__.nmd(module),Object.defineProperty(exports,\"__esModule\",{value:!0}),exports.addHook=function(hook,opts={}){let reverted=!1;const loaders=[],oldLoaders=[];let exts;const originalJSLoader=Module._extensions[\".js\"],matcher=opts.matcher||null,ignoreNodeModules=!1!==opts.ignoreNodeModules;exts=opts.extensions||opts.exts||opts.extension||opts.ext||[\".js\"],Array.isArray(exts)||(exts=[exts]);return exts.forEach((ext=>{if(\"string\"!=typeof ext)throw new TypeError(`Invalid Extension: ${ext}`);const oldLoader=Module._extensions[ext]||originalJSLoader;oldLoaders[ext]=Module._extensions[ext],loaders[ext]=Module._extensions[ext]=function(mod,filename){let compile;reverted||function(filename,exts,matcher,ignoreNodeModules){if(\"string\"!=typeof filename)return!1;if(-1===exts.indexOf(_path.default.extname(filename)))return!1;const resolvedFilename=_path.default.resolve(filename);if(ignoreNodeModules&&nodeModulesRegex.test(resolvedFilename))return!1;if(matcher&&\"function\"==typeof matcher)return!!matcher(resolvedFilename);return!0}(filename,exts,matcher,ignoreNodeModules)&&(compile=mod._compile,mod._compile=function(code){mod._compile=compile;const newCode=hook(code,filename);if(\"string\"!=typeof newCode)throw new Error(\"[Pirates] A hook returned a non-string, or nothing at all! This is a violation of intergalactic law!\\n--------------------\\nIf you have no idea what this means or what Pirates is, let me explain: Pirates is a module that makes is easy to implement require hooks. One of the require hooks you're using uses it. One of these require hooks didn't return anything from it's handler, so we don't know what to do. You might want to debug this.\");return mod._compile(newCode,filename)}),oldLoader(mod,filename)}})),function(){reverted||(reverted=!0,exts.forEach((ext=>{Module._extensions[ext]===loaders[ext]&&(oldLoaders[ext]?Module._extensions[ext]=oldLoaders[ext]:delete Module._extensions[ext])})))}};var _module=_interopRequireDefault(__webpack_require__(\"module\")),_path=_interopRequireDefault(__webpack_require__(\"path\"));function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}const nodeModulesRegex=/^(?:.*[\\\\/])?node_modules(?:[\\\\/].*)?$/,Module=module.constructor.length>1?module.constructor:_module.default},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/comparator.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const ANY=Symbol(\"SemVer ANY\");class Comparator{static get ANY(){return ANY}constructor(comp,options){if(options=parseOptions(options),comp instanceof Comparator){if(comp.loose===!!options.loose)return comp;comp=comp.value}debug(\"comparator\",comp,options),this.options=options,this.loose=!!options.loose,this.parse(comp),this.semver===ANY?this.value=\"\":this.value=this.operator+this.semver.version,debug(\"comp\",this)}parse(comp){const r=this.options.loose?re[t.COMPARATORLOOSE]:re[t.COMPARATOR],m=comp.match(r);if(!m)throw new TypeError(`Invalid comparator: ${comp}`);this.operator=void 0!==m[1]?m[1]:\"\",\"=\"===this.operator&&(this.operator=\"\"),m[2]?this.semver=new SemVer(m[2],this.options.loose):this.semver=ANY}toString(){return this.value}test(version){if(debug(\"Comparator.test\",version,this.options.loose),this.semver===ANY||version===ANY)return!0;if(\"string\"==typeof version)try{version=new SemVer(version,this.options)}catch(er){return!1}return cmp(version,this.operator,this.semver,this.options)}intersects(comp,options){if(!(comp instanceof Comparator))throw new TypeError(\"a Comparator is required\");if(options&&\"object\"==typeof options||(options={loose:!!options,includePrerelease:!1}),\"\"===this.operator)return\"\"===this.value||new Range(comp.value,options).test(this.value);if(\"\"===comp.operator)return\"\"===comp.value||new Range(this.value,options).test(comp.semver);const sameDirectionIncreasing=!(\">=\"!==this.operator&&\">\"!==this.operator||\">=\"!==comp.operator&&\">\"!==comp.operator),sameDirectionDecreasing=!(\"<=\"!==this.operator&&\"<\"!==this.operator||\"<=\"!==comp.operator&&\"<\"!==comp.operator),sameSemVer=this.semver.version===comp.semver.version,differentDirectionsInclusive=!(\">=\"!==this.operator&&\"<=\"!==this.operator||\">=\"!==comp.operator&&\"<=\"!==comp.operator),oppositeDirectionsLessThan=cmp(this.semver,\"<\",comp.semver,options)&&(\">=\"===this.operator||\">\"===this.operator)&&(\"<=\"===comp.operator||\"<\"===comp.operator),oppositeDirectionsGreaterThan=cmp(this.semver,\">\",comp.semver,options)&&(\"<=\"===this.operator||\"<\"===this.operator)&&(\">=\"===comp.operator||\">\"===comp.operator);return sameDirectionIncreasing||sameDirectionDecreasing||sameSemVer&&differentDirectionsInclusive||oppositeDirectionsLessThan||oppositeDirectionsGreaterThan}}module.exports=Comparator;const parseOptions=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/parse-options.js\"),{re,t}=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/re.js\"),cmp=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/cmp.js\"),debug=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/debug.js\"),SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\"),Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\")},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\":(module,__unused_webpack_exports,__webpack_require__)=>{class Range{constructor(range,options){if(options=parseOptions(options),range instanceof Range)return range.loose===!!options.loose&&range.includePrerelease===!!options.includePrerelease?range:new Range(range.raw,options);if(range instanceof Comparator)return this.raw=range.value,this.set=[[range]],this.format(),this;if(this.options=options,this.loose=!!options.loose,this.includePrerelease=!!options.includePrerelease,this.raw=range,this.set=range.split(\"||\").map((r=>this.parseRange(r.trim()))).filter((c=>c.length)),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${range}`);if(this.set.length>1){const first=this.set[0];if(this.set=this.set.filter((c=>!isNullSet(c[0]))),0===this.set.length)this.set=[first];else if(this.set.length>1)for(const c of this.set)if(1===c.length&&isAny(c[0])){this.set=[c];break}}this.format()}format(){return this.range=this.set.map((comps=>comps.join(\" \").trim())).join(\"||\").trim(),this.range}toString(){return this.range}parseRange(range){range=range.trim();const memoKey=`parseRange:${Object.keys(this.options).join(\",\")}:${range}`,cached=cache.get(memoKey);if(cached)return cached;const loose=this.options.loose,hr=loose?re[t.HYPHENRANGELOOSE]:re[t.HYPHENRANGE];range=range.replace(hr,hyphenReplace(this.options.includePrerelease)),debug(\"hyphen replace\",range),range=range.replace(re[t.COMPARATORTRIM],comparatorTrimReplace),debug(\"comparator trim\",range);let rangeList=(range=(range=(range=range.replace(re[t.TILDETRIM],tildeTrimReplace)).replace(re[t.CARETTRIM],caretTrimReplace)).split(/\\s+/).join(\" \")).split(\" \").map((comp=>parseComparator(comp,this.options))).join(\" \").split(/\\s+/).map((comp=>replaceGTE0(comp,this.options)));loose&&(rangeList=rangeList.filter((comp=>(debug(\"loose invalid filter\",comp,this.options),!!comp.match(re[t.COMPARATORLOOSE]))))),debug(\"range list\",rangeList);const rangeMap=new Map,comparators=rangeList.map((comp=>new Comparator(comp,this.options)));for(const comp of comparators){if(isNullSet(comp))return[comp];rangeMap.set(comp.value,comp)}rangeMap.size>1&&rangeMap.has(\"\")&&rangeMap.delete(\"\");const result=[...rangeMap.values()];return cache.set(memoKey,result),result}intersects(range,options){if(!(range instanceof Range))throw new TypeError(\"a Range is required\");return this.set.some((thisComparators=>isSatisfiable(thisComparators,options)&&range.set.some((rangeComparators=>isSatisfiable(rangeComparators,options)&&thisComparators.every((thisComparator=>rangeComparators.every((rangeComparator=>thisComparator.intersects(rangeComparator,options)))))))))}test(version){if(!version)return!1;if(\"string\"==typeof version)try{version=new SemVer(version,this.options)}catch(er){return!1}for(let i=0;i\"<0.0.0-0\"===c.value,isAny=c=>\"\"===c.value,isSatisfiable=(comparators,options)=>{let result=!0;const remainingComparators=comparators.slice();let testComparator=remainingComparators.pop();for(;result&&remainingComparators.length;)result=remainingComparators.every((otherComparator=>testComparator.intersects(otherComparator,options))),testComparator=remainingComparators.pop();return result},parseComparator=(comp,options)=>(debug(\"comp\",comp,options),comp=replaceCarets(comp,options),debug(\"caret\",comp),comp=replaceTildes(comp,options),debug(\"tildes\",comp),comp=replaceXRanges(comp,options),debug(\"xrange\",comp),comp=replaceStars(comp,options),debug(\"stars\",comp),comp),isX=id=>!id||\"x\"===id.toLowerCase()||\"*\"===id,replaceTildes=(comp,options)=>comp.trim().split(/\\s+/).map((c=>replaceTilde(c,options))).join(\" \"),replaceTilde=(comp,options)=>{const r=options.loose?re[t.TILDELOOSE]:re[t.TILDE];return comp.replace(r,((_,M,m,p,pr)=>{let ret;return debug(\"tilde\",comp,_,M,m,p,pr),isX(M)?ret=\"\":isX(m)?ret=`>=${M}.0.0 <${+M+1}.0.0-0`:isX(p)?ret=`>=${M}.${m}.0 <${M}.${+m+1}.0-0`:pr?(debug(\"replaceTilde pr\",pr),ret=`>=${M}.${m}.${p}-${pr} <${M}.${+m+1}.0-0`):ret=`>=${M}.${m}.${p} <${M}.${+m+1}.0-0`,debug(\"tilde return\",ret),ret}))},replaceCarets=(comp,options)=>comp.trim().split(/\\s+/).map((c=>replaceCaret(c,options))).join(\" \"),replaceCaret=(comp,options)=>{debug(\"caret\",comp,options);const r=options.loose?re[t.CARETLOOSE]:re[t.CARET],z=options.includePrerelease?\"-0\":\"\";return comp.replace(r,((_,M,m,p,pr)=>{let ret;return debug(\"caret\",comp,_,M,m,p,pr),isX(M)?ret=\"\":isX(m)?ret=`>=${M}.0.0${z} <${+M+1}.0.0-0`:isX(p)?ret=\"0\"===M?`>=${M}.${m}.0${z} <${M}.${+m+1}.0-0`:`>=${M}.${m}.0${z} <${+M+1}.0.0-0`:pr?(debug(\"replaceCaret pr\",pr),ret=\"0\"===M?\"0\"===m?`>=${M}.${m}.${p}-${pr} <${M}.${m}.${+p+1}-0`:`>=${M}.${m}.${p}-${pr} <${M}.${+m+1}.0-0`:`>=${M}.${m}.${p}-${pr} <${+M+1}.0.0-0`):(debug(\"no pr\"),ret=\"0\"===M?\"0\"===m?`>=${M}.${m}.${p}${z} <${M}.${m}.${+p+1}-0`:`>=${M}.${m}.${p}${z} <${M}.${+m+1}.0-0`:`>=${M}.${m}.${p} <${+M+1}.0.0-0`),debug(\"caret return\",ret),ret}))},replaceXRanges=(comp,options)=>(debug(\"replaceXRanges\",comp,options),comp.split(/\\s+/).map((c=>replaceXRange(c,options))).join(\" \")),replaceXRange=(comp,options)=>{comp=comp.trim();const r=options.loose?re[t.XRANGELOOSE]:re[t.XRANGE];return comp.replace(r,((ret,gtlt,M,m,p,pr)=>{debug(\"xRange\",comp,ret,gtlt,M,m,p,pr);const xM=isX(M),xm=xM||isX(m),xp=xm||isX(p),anyX=xp;return\"=\"===gtlt&&anyX&&(gtlt=\"\"),pr=options.includePrerelease?\"-0\":\"\",xM?ret=\">\"===gtlt||\"<\"===gtlt?\"<0.0.0-0\":\"*\":gtlt&&anyX?(xm&&(m=0),p=0,\">\"===gtlt?(gtlt=\">=\",xm?(M=+M+1,m=0,p=0):(m=+m+1,p=0)):\"<=\"===gtlt&&(gtlt=\"<\",xm?M=+M+1:m=+m+1),\"<\"===gtlt&&(pr=\"-0\"),ret=`${gtlt+M}.${m}.${p}${pr}`):xm?ret=`>=${M}.0.0${pr} <${+M+1}.0.0-0`:xp&&(ret=`>=${M}.${m}.0${pr} <${M}.${+m+1}.0-0`),debug(\"xRange return\",ret),ret}))},replaceStars=(comp,options)=>(debug(\"replaceStars\",comp,options),comp.trim().replace(re[t.STAR],\"\")),replaceGTE0=(comp,options)=>(debug(\"replaceGTE0\",comp,options),comp.trim().replace(re[options.includePrerelease?t.GTE0PRE:t.GTE0],\"\")),hyphenReplace=incPr=>($0,from,fM,fm,fp,fpr,fb,to,tM,tm,tp,tpr,tb)=>`${from=isX(fM)?\"\":isX(fm)?`>=${fM}.0.0${incPr?\"-0\":\"\"}`:isX(fp)?`>=${fM}.${fm}.0${incPr?\"-0\":\"\"}`:fpr?`>=${from}`:`>=${from}${incPr?\"-0\":\"\"}`} ${to=isX(tM)?\"\":isX(tm)?`<${+tM+1}.0.0-0`:isX(tp)?`<${tM}.${+tm+1}.0-0`:tpr?`<=${tM}.${tm}.${tp}-${tpr}`:incPr?`<${tM}.${tm}.${+tp+1}-0`:`<=${to}`}`.trim(),testSet=(set,version,options)=>{for(let i=0;i0){const allowed=set[i].semver;if(allowed.major===version.major&&allowed.minor===version.minor&&allowed.patch===version.patch)return!0}return!1}return!0}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const debug=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/debug.js\"),{MAX_LENGTH,MAX_SAFE_INTEGER}=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/constants.js\"),{re,t}=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/re.js\"),parseOptions=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/parse-options.js\"),{compareIdentifiers}=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/identifiers.js\");class SemVer{constructor(version,options){if(options=parseOptions(options),version instanceof SemVer){if(version.loose===!!options.loose&&version.includePrerelease===!!options.includePrerelease)return version;version=version.version}else if(\"string\"!=typeof version)throw new TypeError(`Invalid Version: ${version}`);if(version.length>MAX_LENGTH)throw new TypeError(`version is longer than ${MAX_LENGTH} characters`);debug(\"SemVer\",version,options),this.options=options,this.loose=!!options.loose,this.includePrerelease=!!options.includePrerelease;const m=version.trim().match(options.loose?re[t.LOOSE]:re[t.FULL]);if(!m)throw new TypeError(`Invalid Version: ${version}`);if(this.raw=version,this.major=+m[1],this.minor=+m[2],this.patch=+m[3],this.major>MAX_SAFE_INTEGER||this.major<0)throw new TypeError(\"Invalid major version\");if(this.minor>MAX_SAFE_INTEGER||this.minor<0)throw new TypeError(\"Invalid minor version\");if(this.patch>MAX_SAFE_INTEGER||this.patch<0)throw new TypeError(\"Invalid patch version\");m[4]?this.prerelease=m[4].split(\".\").map((id=>{if(/^[0-9]+$/.test(id)){const num=+id;if(num>=0&&num=0;)\"number\"==typeof this.prerelease[i]&&(this.prerelease[i]++,i=-2);-1===i&&this.prerelease.push(0)}identifier&&(0===compareIdentifiers(this.prerelease[0],identifier)?isNaN(this.prerelease[1])&&(this.prerelease=[identifier,0]):this.prerelease=[identifier,0]);break;default:throw new Error(`invalid increment argument: ${release}`)}return this.format(),this.raw=this.version,this}}module.exports=SemVer},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/clean.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const parse=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/parse.js\");module.exports=(version,options)=>{const s=parse(version.trim().replace(/^[=v]+/,\"\"),options);return s?s.version:null}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/cmp.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const eq=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/eq.js\"),neq=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/neq.js\"),gt=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/gt.js\"),gte=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/gte.js\"),lt=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/lt.js\"),lte=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/lte.js\");module.exports=(a,op,b,loose)=>{switch(op){case\"===\":return\"object\"==typeof a&&(a=a.version),\"object\"==typeof b&&(b=b.version),a===b;case\"!==\":return\"object\"==typeof a&&(a=a.version),\"object\"==typeof b&&(b=b.version),a!==b;case\"\":case\"=\":case\"==\":return eq(a,b,loose);case\"!=\":return neq(a,b,loose);case\">\":return gt(a,b,loose);case\">=\":return gte(a,b,loose);case\"<\":return lt(a,b,loose);case\"<=\":return lte(a,b,loose);default:throw new TypeError(`Invalid operator: ${op}`)}}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/coerce.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\"),parse=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/parse.js\"),{re,t}=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/re.js\");module.exports=(version,options)=>{if(version instanceof SemVer)return version;if(\"number\"==typeof version&&(version=String(version)),\"string\"!=typeof version)return null;let match=null;if((options=options||{}).rtl){let next;for(;(next=re[t.COERCERTL].exec(version))&&(!match||match.index+match[0].length!==version.length);)match&&next.index+next[0].length===match.index+match[0].length||(match=next),re[t.COERCERTL].lastIndex=next.index+next[1].length+next[2].length;re[t.COERCERTL].lastIndex=-1}else match=version.match(re[t.COERCE]);return null===match?null:parse(`${match[2]}.${match[3]||\"0\"}.${match[4]||\"0\"}`,options)}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare-build.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\");module.exports=(a,b,loose)=>{const versionA=new SemVer(a,loose),versionB=new SemVer(b,loose);return versionA.compare(versionB)||versionA.compareBuild(versionB)}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare-loose.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\");module.exports=(a,b)=>compare(a,b,!0)},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\");module.exports=(a,b,loose)=>new SemVer(a,loose).compare(new SemVer(b,loose))},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/diff.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const parse=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/parse.js\"),eq=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/eq.js\");module.exports=(version1,version2)=>{if(eq(version1,version2))return null;{const v1=parse(version1),v2=parse(version2),hasPre=v1.prerelease.length||v2.prerelease.length,prefix=hasPre?\"pre\":\"\",defaultResult=hasPre?\"prerelease\":\"\";for(const key in v1)if((\"major\"===key||\"minor\"===key||\"patch\"===key)&&v1[key]!==v2[key])return prefix+key;return defaultResult}}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/eq.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\");module.exports=(a,b,loose)=>0===compare(a,b,loose)},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/gt.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\");module.exports=(a,b,loose)=>compare(a,b,loose)>0},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/gte.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\");module.exports=(a,b,loose)=>compare(a,b,loose)>=0},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/inc.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\");module.exports=(version,release,options,identifier)=>{\"string\"==typeof options&&(identifier=options,options=void 0);try{return new SemVer(version instanceof SemVer?version.version:version,options).inc(release,identifier).version}catch(er){return null}}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/lt.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\");module.exports=(a,b,loose)=>compare(a,b,loose)<0},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/lte.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\");module.exports=(a,b,loose)=>compare(a,b,loose)<=0},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/major.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\");module.exports=(a,loose)=>new SemVer(a,loose).major},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/minor.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\");module.exports=(a,loose)=>new SemVer(a,loose).minor},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/neq.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\");module.exports=(a,b,loose)=>0!==compare(a,b,loose)},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/parse.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const{MAX_LENGTH}=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/constants.js\"),{re,t}=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/re.js\"),SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\"),parseOptions=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/parse-options.js\");module.exports=(version,options)=>{if(options=parseOptions(options),version instanceof SemVer)return version;if(\"string\"!=typeof version)return null;if(version.length>MAX_LENGTH)return null;if(!(options.loose?re[t.LOOSE]:re[t.FULL]).test(version))return null;try{return new SemVer(version,options)}catch(er){return null}}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/patch.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\");module.exports=(a,loose)=>new SemVer(a,loose).patch},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/prerelease.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const parse=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/parse.js\");module.exports=(version,options)=>{const parsed=parse(version,options);return parsed&&parsed.prerelease.length?parsed.prerelease:null}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/rcompare.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\");module.exports=(a,b,loose)=>compare(b,a,loose)},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/rsort.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compareBuild=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare-build.js\");module.exports=(list,loose)=>list.sort(((a,b)=>compareBuild(b,a,loose)))},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/satisfies.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\");module.exports=(version,range,options)=>{try{range=new Range(range,options)}catch(er){return!1}return range.test(version)}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/sort.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const compareBuild=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare-build.js\");module.exports=(list,loose)=>list.sort(((a,b)=>compareBuild(a,b,loose)))},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/valid.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const parse=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/parse.js\");module.exports=(version,options)=>{const v=parse(version,options);return v?v.version:null}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/index.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const internalRe=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/re.js\");module.exports={re:internalRe.re,src:internalRe.src,tokens:internalRe.t,SEMVER_SPEC_VERSION:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/constants.js\").SEMVER_SPEC_VERSION,SemVer:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\"),compareIdentifiers:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/identifiers.js\").compareIdentifiers,rcompareIdentifiers:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/identifiers.js\").rcompareIdentifiers,parse:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/parse.js\"),valid:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/valid.js\"),clean:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/clean.js\"),inc:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/inc.js\"),diff:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/diff.js\"),major:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/major.js\"),minor:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/minor.js\"),patch:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/patch.js\"),prerelease:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/prerelease.js\"),compare:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\"),rcompare:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/rcompare.js\"),compareLoose:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare-loose.js\"),compareBuild:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare-build.js\"),sort:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/sort.js\"),rsort:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/rsort.js\"),gt:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/gt.js\"),lt:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/lt.js\"),eq:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/eq.js\"),neq:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/neq.js\"),gte:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/gte.js\"),lte:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/lte.js\"),cmp:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/cmp.js\"),coerce:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/coerce.js\"),Comparator:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/comparator.js\"),Range:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\"),satisfies:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/satisfies.js\"),toComparators:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/to-comparators.js\"),maxSatisfying:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/max-satisfying.js\"),minSatisfying:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/min-satisfying.js\"),minVersion:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/min-version.js\"),validRange:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/valid.js\"),outside:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/outside.js\"),gtr:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/gtr.js\"),ltr:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/ltr.js\"),intersects:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/intersects.js\"),simplifyRange:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/simplify.js\"),subset:__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/subset.js\")}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/constants.js\":module=>{const MAX_SAFE_INTEGER=Number.MAX_SAFE_INTEGER||9007199254740991;module.exports={SEMVER_SPEC_VERSION:\"2.0.0\",MAX_LENGTH:256,MAX_SAFE_INTEGER,MAX_SAFE_COMPONENT_LENGTH:16}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/debug.js\":module=>{const debug=\"object\"==typeof process&&process.env&&process.env.NODE_DEBUG&&/\\bsemver\\b/i.test(process.env.NODE_DEBUG)?(...args)=>console.error(\"SEMVER\",...args):()=>{};module.exports=debug},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/identifiers.js\":module=>{const numeric=/^[0-9]+$/,compareIdentifiers=(a,b)=>{const anum=numeric.test(a),bnum=numeric.test(b);return anum&&bnum&&(a=+a,b=+b),a===b?0:anum&&!bnum?-1:bnum&&!anum?1:acompareIdentifiers(b,a)}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/parse-options.js\":module=>{const opts=[\"includePrerelease\",\"loose\",\"rtl\"];module.exports=options=>options?\"object\"!=typeof options?{loose:!0}:opts.filter((k=>options[k])).reduce(((o,k)=>(o[k]=!0,o)),{}):{}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/re.js\":(module,exports,__webpack_require__)=>{const{MAX_SAFE_COMPONENT_LENGTH}=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/constants.js\"),debug=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/internal/debug.js\"),re=(exports=module.exports={}).re=[],src=exports.src=[],t=exports.t={};let R=0;const createToken=(name,value,isGlobal)=>{const index=R++;debug(name,index,value),t[name]=index,src[index]=value,re[index]=new RegExp(value,isGlobal?\"g\":void 0)};createToken(\"NUMERICIDENTIFIER\",\"0|[1-9]\\\\d*\"),createToken(\"NUMERICIDENTIFIERLOOSE\",\"[0-9]+\"),createToken(\"NONNUMERICIDENTIFIER\",\"\\\\d*[a-zA-Z-][a-zA-Z0-9-]*\"),createToken(\"MAINVERSION\",`(${src[t.NUMERICIDENTIFIER]})\\\\.(${src[t.NUMERICIDENTIFIER]})\\\\.(${src[t.NUMERICIDENTIFIER]})`),createToken(\"MAINVERSIONLOOSE\",`(${src[t.NUMERICIDENTIFIERLOOSE]})\\\\.(${src[t.NUMERICIDENTIFIERLOOSE]})\\\\.(${src[t.NUMERICIDENTIFIERLOOSE]})`),createToken(\"PRERELEASEIDENTIFIER\",`(?:${src[t.NUMERICIDENTIFIER]}|${src[t.NONNUMERICIDENTIFIER]})`),createToken(\"PRERELEASEIDENTIFIERLOOSE\",`(?:${src[t.NUMERICIDENTIFIERLOOSE]}|${src[t.NONNUMERICIDENTIFIER]})`),createToken(\"PRERELEASE\",`(?:-(${src[t.PRERELEASEIDENTIFIER]}(?:\\\\.${src[t.PRERELEASEIDENTIFIER]})*))`),createToken(\"PRERELEASELOOSE\",`(?:-?(${src[t.PRERELEASEIDENTIFIERLOOSE]}(?:\\\\.${src[t.PRERELEASEIDENTIFIERLOOSE]})*))`),createToken(\"BUILDIDENTIFIER\",\"[0-9A-Za-z-]+\"),createToken(\"BUILD\",`(?:\\\\+(${src[t.BUILDIDENTIFIER]}(?:\\\\.${src[t.BUILDIDENTIFIER]})*))`),createToken(\"FULLPLAIN\",`v?${src[t.MAINVERSION]}${src[t.PRERELEASE]}?${src[t.BUILD]}?`),createToken(\"FULL\",`^${src[t.FULLPLAIN]}$`),createToken(\"LOOSEPLAIN\",`[v=\\\\s]*${src[t.MAINVERSIONLOOSE]}${src[t.PRERELEASELOOSE]}?${src[t.BUILD]}?`),createToken(\"LOOSE\",`^${src[t.LOOSEPLAIN]}$`),createToken(\"GTLT\",\"((?:<|>)?=?)\"),createToken(\"XRANGEIDENTIFIERLOOSE\",`${src[t.NUMERICIDENTIFIERLOOSE]}|x|X|\\\\*`),createToken(\"XRANGEIDENTIFIER\",`${src[t.NUMERICIDENTIFIER]}|x|X|\\\\*`),createToken(\"XRANGEPLAIN\",`[v=\\\\s]*(${src[t.XRANGEIDENTIFIER]})(?:\\\\.(${src[t.XRANGEIDENTIFIER]})(?:\\\\.(${src[t.XRANGEIDENTIFIER]})(?:${src[t.PRERELEASE]})?${src[t.BUILD]}?)?)?`),createToken(\"XRANGEPLAINLOOSE\",`[v=\\\\s]*(${src[t.XRANGEIDENTIFIERLOOSE]})(?:\\\\.(${src[t.XRANGEIDENTIFIERLOOSE]})(?:\\\\.(${src[t.XRANGEIDENTIFIERLOOSE]})(?:${src[t.PRERELEASELOOSE]})?${src[t.BUILD]}?)?)?`),createToken(\"XRANGE\",`^${src[t.GTLT]}\\\\s*${src[t.XRANGEPLAIN]}$`),createToken(\"XRANGELOOSE\",`^${src[t.GTLT]}\\\\s*${src[t.XRANGEPLAINLOOSE]}$`),createToken(\"COERCE\",`(^|[^\\\\d])(\\\\d{1,${MAX_SAFE_COMPONENT_LENGTH}})(?:\\\\.(\\\\d{1,${MAX_SAFE_COMPONENT_LENGTH}}))?(?:\\\\.(\\\\d{1,${MAX_SAFE_COMPONENT_LENGTH}}))?(?:$|[^\\\\d])`),createToken(\"COERCERTL\",src[t.COERCE],!0),createToken(\"LONETILDE\",\"(?:~>?)\"),createToken(\"TILDETRIM\",`(\\\\s*)${src[t.LONETILDE]}\\\\s+`,!0),exports.tildeTrimReplace=\"$1~\",createToken(\"TILDE\",`^${src[t.LONETILDE]}${src[t.XRANGEPLAIN]}$`),createToken(\"TILDELOOSE\",`^${src[t.LONETILDE]}${src[t.XRANGEPLAINLOOSE]}$`),createToken(\"LONECARET\",\"(?:\\\\^)\"),createToken(\"CARETTRIM\",`(\\\\s*)${src[t.LONECARET]}\\\\s+`,!0),exports.caretTrimReplace=\"$1^\",createToken(\"CARET\",`^${src[t.LONECARET]}${src[t.XRANGEPLAIN]}$`),createToken(\"CARETLOOSE\",`^${src[t.LONECARET]}${src[t.XRANGEPLAINLOOSE]}$`),createToken(\"COMPARATORLOOSE\",`^${src[t.GTLT]}\\\\s*(${src[t.LOOSEPLAIN]})$|^$`),createToken(\"COMPARATOR\",`^${src[t.GTLT]}\\\\s*(${src[t.FULLPLAIN]})$|^$`),createToken(\"COMPARATORTRIM\",`(\\\\s*)${src[t.GTLT]}\\\\s*(${src[t.LOOSEPLAIN]}|${src[t.XRANGEPLAIN]})`,!0),exports.comparatorTrimReplace=\"$1$2$3\",createToken(\"HYPHENRANGE\",`^\\\\s*(${src[t.XRANGEPLAIN]})\\\\s+-\\\\s+(${src[t.XRANGEPLAIN]})\\\\s*$`),createToken(\"HYPHENRANGELOOSE\",`^\\\\s*(${src[t.XRANGEPLAINLOOSE]})\\\\s+-\\\\s+(${src[t.XRANGEPLAINLOOSE]})\\\\s*$`),createToken(\"STAR\",\"(<|>)?=?\\\\s*\\\\*\"),createToken(\"GTE0\",\"^\\\\s*>=\\\\s*0\\\\.0\\\\.0\\\\s*$\"),createToken(\"GTE0PRE\",\"^\\\\s*>=\\\\s*0\\\\.0\\\\.0-0\\\\s*$\")},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/gtr.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const outside=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/outside.js\");module.exports=(version,range,options)=>outside(version,range,\">\",options)},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/intersects.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\");module.exports=(r1,r2,options)=>(r1=new Range(r1,options),r2=new Range(r2,options),r1.intersects(r2))},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/ltr.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const outside=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/outside.js\");module.exports=(version,range,options)=>outside(version,range,\"<\",options)},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/max-satisfying.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\"),Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\");module.exports=(versions,range,options)=>{let max=null,maxSV=null,rangeObj=null;try{rangeObj=new Range(range,options)}catch(er){return null}return versions.forEach((v=>{rangeObj.test(v)&&(max&&-1!==maxSV.compare(v)||(max=v,maxSV=new SemVer(max,options)))})),max}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/min-satisfying.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\"),Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\");module.exports=(versions,range,options)=>{let min=null,minSV=null,rangeObj=null;try{rangeObj=new Range(range,options)}catch(er){return null}return versions.forEach((v=>{rangeObj.test(v)&&(min&&1!==minSV.compare(v)||(min=v,minSV=new SemVer(min,options)))})),min}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/min-version.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\"),Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\"),gt=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/gt.js\");module.exports=(range,loose)=>{range=new Range(range,loose);let minver=new SemVer(\"0.0.0\");if(range.test(minver))return minver;if(minver=new SemVer(\"0.0.0-0\"),range.test(minver))return minver;minver=null;for(let i=0;i{const compver=new SemVer(comparator.semver.version);switch(comparator.operator){case\">\":0===compver.prerelease.length?compver.patch++:compver.prerelease.push(0),compver.raw=compver.format();case\"\":case\">=\":setMin&&!gt(compver,setMin)||(setMin=compver);break;case\"<\":case\"<=\":break;default:throw new Error(`Unexpected operation: ${comparator.operator}`)}})),!setMin||minver&&!gt(minver,setMin)||(minver=setMin)}return minver&&range.test(minver)?minver:null}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/outside.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const SemVer=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/semver.js\"),Comparator=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/comparator.js\"),{ANY}=Comparator,Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\"),satisfies=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/satisfies.js\"),gt=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/gt.js\"),lt=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/lt.js\"),lte=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/lte.js\"),gte=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/gte.js\");module.exports=(version,range,hilo,options)=>{let gtfn,ltefn,ltfn,comp,ecomp;switch(version=new SemVer(version,options),range=new Range(range,options),hilo){case\">\":gtfn=gt,ltefn=lte,ltfn=lt,comp=\">\",ecomp=\">=\";break;case\"<\":gtfn=lt,ltefn=gte,ltfn=gt,comp=\"<\",ecomp=\"<=\";break;default:throw new TypeError('Must provide a hilo val of \"<\" or \">\"')}if(satisfies(version,range,options))return!1;for(let i=0;i{comparator.semver===ANY&&(comparator=new Comparator(\">=0.0.0\")),high=high||comparator,low=low||comparator,gtfn(comparator.semver,high.semver,options)?high=comparator:ltfn(comparator.semver,low.semver,options)&&(low=comparator)})),high.operator===comp||high.operator===ecomp)return!1;if((!low.operator||low.operator===comp)&<efn(version,low.semver))return!1;if(low.operator===ecomp&<fn(version,low.semver))return!1}return!0}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/simplify.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const satisfies=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/satisfies.js\"),compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\");module.exports=(versions,range,options)=>{const set=[];let first=null,prev=null;const v=versions.sort(((a,b)=>compare(a,b,options)));for(const version of v){satisfies(version,range,options)?(prev=version,first||(first=version)):(prev&&set.push([first,prev]),prev=null,first=null)}first&&set.push([first,null]);const ranges=[];for(const[min,max]of set)min===max?ranges.push(min):max||min!==v[0]?max?min===v[0]?ranges.push(`<=${max}`):ranges.push(`${min} - ${max}`):ranges.push(`>=${min}`):ranges.push(\"*\");const simplified=ranges.join(\" || \"),original=\"string\"==typeof range.raw?range.raw:String(range);return simplified.length{const Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\"),Comparator=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/comparator.js\"),{ANY}=Comparator,satisfies=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/satisfies.js\"),compare=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/functions/compare.js\"),simpleSubset=(sub,dom,options)=>{if(sub===dom)return!0;if(1===sub.length&&sub[0].semver===ANY){if(1===dom.length&&dom[0].semver===ANY)return!0;sub=options.includePrerelease?[new Comparator(\">=0.0.0-0\")]:[new Comparator(\">=0.0.0\")]}if(1===dom.length&&dom[0].semver===ANY){if(options.includePrerelease)return!0;dom=[new Comparator(\">=0.0.0\")]}const eqSet=new Set;let gt,lt,gtltComp,higher,lower,hasDomLT,hasDomGT;for(const c of sub)\">\"===c.operator||\">=\"===c.operator?gt=higherGT(gt,c,options):\"<\"===c.operator||\"<=\"===c.operator?lt=lowerLT(lt,c,options):eqSet.add(c.semver);if(eqSet.size>1)return null;if(gt&<){if(gtltComp=compare(gt.semver,lt.semver,options),gtltComp>0)return null;if(0===gtltComp&&(\">=\"!==gt.operator||\"<=\"!==lt.operator))return null}for(const eq of eqSet){if(gt&&!satisfies(eq,String(gt),options))return null;if(lt&&!satisfies(eq,String(lt),options))return null;for(const c of dom)if(!satisfies(eq,String(c),options))return!1;return!0}let needDomLTPre=!(!lt||options.includePrerelease||!lt.semver.prerelease.length)&<.semver,needDomGTPre=!(!gt||options.includePrerelease||!gt.semver.prerelease.length)&>.semver;needDomLTPre&&1===needDomLTPre.prerelease.length&&\"<\"===lt.operator&&0===needDomLTPre.prerelease[0]&&(needDomLTPre=!1);for(const c of dom){if(hasDomGT=hasDomGT||\">\"===c.operator||\">=\"===c.operator,hasDomLT=hasDomLT||\"<\"===c.operator||\"<=\"===c.operator,gt)if(needDomGTPre&&c.semver.prerelease&&c.semver.prerelease.length&&c.semver.major===needDomGTPre.major&&c.semver.minor===needDomGTPre.minor&&c.semver.patch===needDomGTPre.patch&&(needDomGTPre=!1),\">\"===c.operator||\">=\"===c.operator){if(higher=higherGT(gt,c,options),higher===c&&higher!==gt)return!1}else if(\">=\"===gt.operator&&!satisfies(gt.semver,String(c),options))return!1;if(lt)if(needDomLTPre&&c.semver.prerelease&&c.semver.prerelease.length&&c.semver.major===needDomLTPre.major&&c.semver.minor===needDomLTPre.minor&&c.semver.patch===needDomLTPre.patch&&(needDomLTPre=!1),\"<\"===c.operator||\"<=\"===c.operator){if(lower=lowerLT(lt,c,options),lower===c&&lower!==lt)return!1}else if(\"<=\"===lt.operator&&!satisfies(lt.semver,String(c),options))return!1;if(!c.operator&&(lt||gt)&&0!==gtltComp)return!1}return!(gt&&hasDomLT&&!lt&&0!==gtltComp)&&(!(lt&&hasDomGT&&!gt&&0!==gtltComp)&&(!needDomGTPre&&!needDomLTPre))},higherGT=(a,b,options)=>{if(!a)return b;const comp=compare(a.semver,b.semver,options);return comp>0?a:comp<0||\">\"===b.operator&&\">=\"===a.operator?b:a},lowerLT=(a,b,options)=>{if(!a)return b;const comp=compare(a.semver,b.semver,options);return comp<0?a:comp>0||\"<\"===b.operator&&\"<=\"===a.operator?b:a};module.exports=(sub,dom,options={})=>{if(sub===dom)return!0;sub=new Range(sub,options),dom=new Range(dom,options);let sawNonNull=!1;OUTER:for(const simpleSub of sub.set){for(const simpleDom of dom.set){const isSub=simpleSubset(simpleSub,simpleDom,options);if(sawNonNull=sawNonNull||null!==isSub,isSub)continue OUTER}if(sawNonNull)return!1}return!0}},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/to-comparators.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\");module.exports=(range,options)=>new Range(range,options).set.map((comp=>comp.map((c=>c.value)).join(\" \").trim().split(\" \")))},\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/ranges/valid.js\":(module,__unused_webpack_exports,__webpack_require__)=>{const Range=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/classes/range.js\");module.exports=(range,options)=>{try{return new Range(range,options).range||\"*\"}catch(er){return null}}},\"./node_modules/.pnpm/yallist@4.0.0/node_modules/yallist/iterator.js\":module=>{\"use strict\";module.exports=function(Yallist){Yallist.prototype[Symbol.iterator]=function*(){for(let walker=this.head;walker;walker=walker.next)yield walker.value}}},\"./node_modules/.pnpm/yallist@4.0.0/node_modules/yallist/yallist.js\":(module,__unused_webpack_exports,__webpack_require__)=>{\"use strict\";function Yallist(list){var self=this;if(self instanceof Yallist||(self=new Yallist),self.tail=null,self.head=null,self.length=0,list&&\"function\"==typeof list.forEach)list.forEach((function(item){self.push(item)}));else if(arguments.length>0)for(var i=0,l=arguments.length;i1)acc=initial;else{if(!this.head)throw new TypeError(\"Reduce of empty list with no initial value\");walker=this.head.next,acc=this.head.value}for(var i=0;null!==walker;i++)acc=fn(acc,walker.value,i),walker=walker.next;return acc},Yallist.prototype.reduceReverse=function(fn,initial){var acc,walker=this.tail;if(arguments.length>1)acc=initial;else{if(!this.tail)throw new TypeError(\"Reduce of empty list with no initial value\");walker=this.tail.prev,acc=this.tail.value}for(var i=this.length-1;null!==walker;i--)acc=fn(acc,walker.value,i),walker=walker.prev;return acc},Yallist.prototype.toArray=function(){for(var arr=new Array(this.length),i=0,walker=this.head;null!==walker;i++)arr[i]=walker.value,walker=walker.next;return arr},Yallist.prototype.toArrayReverse=function(){for(var arr=new Array(this.length),i=0,walker=this.tail;null!==walker;i++)arr[i]=walker.value,walker=walker.prev;return arr},Yallist.prototype.slice=function(from,to){(to=to||this.length)<0&&(to+=this.length),(from=from||0)<0&&(from+=this.length);var ret=new Yallist;if(tothis.length&&(to=this.length);for(var i=0,walker=this.head;null!==walker&&ithis.length&&(to=this.length);for(var i=this.length,walker=this.tail;null!==walker&&i>to;i--)walker=walker.prev;for(;null!==walker&&i>from;i--,walker=walker.prev)ret.push(walker.value);return ret},Yallist.prototype.splice=function(start,deleteCount,...nodes){start>this.length&&(start=this.length-1),start<0&&(start=this.length+start);for(var i=0,walker=this.head;null!==walker&&i{\"use strict\";module.exports=require(\"crypto\")},fs:module=>{\"use strict\";module.exports=require(\"fs\")},module:module=>{\"use strict\";module.exports=require(\"module\")},path:module=>{\"use strict\";module.exports=require(\"path\")},util:module=>{\"use strict\";module.exports=require(\"util\")}},__webpack_module_cache__={};function __webpack_require__(moduleId){var cachedModule=__webpack_module_cache__[moduleId];if(void 0!==cachedModule)return cachedModule.exports;var module=__webpack_module_cache__[moduleId]={id:moduleId,loaded:!1,exports:{}};return __webpack_modules__[moduleId](module,module.exports,__webpack_require__),module.loaded=!0,module.exports}__webpack_require__.n=module=>{var getter=module&&module.__esModule?()=>module.default:()=>module;return __webpack_require__.d(getter,{a:getter}),getter},__webpack_require__.d=(exports,definition)=>{for(var key in definition)__webpack_require__.o(definition,key)&&!__webpack_require__.o(exports,key)&&Object.defineProperty(exports,key,{enumerable:!0,get:definition[key]})},__webpack_require__.o=(obj,prop)=>Object.prototype.hasOwnProperty.call(obj,prop),__webpack_require__.nmd=module=>(module.paths=[],module.children||(module.children=[]),module);var __webpack_exports__={};(()=>{\"use strict\";__webpack_require__.d(__webpack_exports__,{default:()=>createJITI});var external_fs_=__webpack_require__(\"fs\"),external_module_=__webpack_require__(\"module\");const external_perf_hooks_namespaceObject=require(\"perf_hooks\"),external_os_namespaceObject=require(\"os\"),external_vm_namespaceObject=require(\"vm\");var external_vm_default=__webpack_require__.n(external_vm_namespaceObject);const external_url_namespaceObject=require(\"url\");function normalizeWindowsPath(input=\"\"){return input&&input.includes(\"\\\\\")?input.replace(/\\\\/g,\"/\"):input}const _UNC_REGEX=/^[\\\\/]{2}/,_IS_ABSOLUTE_RE=/^[\\\\/](?![\\\\/])|^[\\\\/]{2}(?!\\.)|^[a-zA-Z]:[\\\\/]/,_DRIVE_LETTER_RE=/^[a-zA-Z]:$/,join=function(...args){if(0===args.length)return\".\";let joined;for(let i=0;i0&&(void 0===joined?joined=arg:joined+=`/${arg}`)}return void 0===joined?\".\":function(path){if(0===path.length)return\".\";const isUNCPath=(path=normalizeWindowsPath(path)).match(_UNC_REGEX),isPathAbsolute=isAbsolute(path),trailingSeparator=\"/\"===path[path.length-1];return 0===(path=normalizeString(path,!isPathAbsolute)).length?isPathAbsolute?\"/\":trailingSeparator?\"./\":\".\":(trailingSeparator&&(path+=\"/\"),_DRIVE_LETTER_RE.test(path)&&(path+=\"/\"),isUNCPath?isPathAbsolute?`//${path}`:`//./${path}`:isPathAbsolute&&!isAbsolute(path)?`/${path}`:path)}(joined.replace(/\\/\\/+/g,\"/\"))};function normalizeString(path,allowAboveRoot){let res=\"\",lastSegmentLength=0,lastSlash=-1,dots=0,char=null;for(let i=0;i<=path.length;++i){if(i2){const lastSlashIndex=res.lastIndexOf(\"/\");-1===lastSlashIndex?(res=\"\",lastSegmentLength=0):(res=res.slice(0,lastSlashIndex),lastSegmentLength=res.length-1-res.lastIndexOf(\"/\")),lastSlash=i,dots=0;continue}if(0!==res.length){res=\"\",lastSegmentLength=0,lastSlash=i,dots=0;continue}}allowAboveRoot&&(res+=res.length>0?\"/..\":\"..\",lastSegmentLength=2)}else res.length>0?res+=`/${path.slice(lastSlash+1,i)}`:res=path.slice(lastSlash+1,i),lastSegmentLength=i-lastSlash-1;lastSlash=i,dots=0}else\".\"===char&&-1!==dots?++dots:dots=-1}return res}const isAbsolute=function(p){return _IS_ABSOLUTE_RE.test(p)},_EXTNAME_RE=/.(\\.[^/.]+)$/,pathe_f81973bb_extname=function(p){const match=_EXTNAME_RE.exec(normalizeWindowsPath(p));return match&&match[1]||\"\"},pathe_f81973bb_dirname=function(p){const segments=normalizeWindowsPath(p).replace(/\\/$/,\"\").split(\"/\").slice(0,-1);return 1===segments.length&&_DRIVE_LETTER_RE.test(segments[0])&&(segments[0]+=\"/\"),segments.join(\"/\")||(isAbsolute(p)?\"/\":\".\")},basename=function(p,ext){const lastSegment=normalizeWindowsPath(p).split(\"/\").pop();return ext&&lastSegment.endsWith(ext)?lastSegment.slice(0,-ext.length):lastSegment};var mkdirp=__webpack_require__(\"./node_modules/.pnpm/mkdirp@1.0.4/node_modules/mkdirp/index.js\");const suspectProtoRx=/\"(?:_|\\\\u005[Ff])(?:_|\\\\u005[Ff])(?:p|\\\\u0070)(?:r|\\\\u0072)(?:o|\\\\u006[Ff])(?:t|\\\\u0074)(?:o|\\\\u006[Ff])(?:_|\\\\u005[Ff])(?:_|\\\\u005[Ff])\"\\s*:/,suspectConstructorRx=/\"(?:c|\\\\u0063)(?:o|\\\\u006[Ff])(?:n|\\\\u006[Ee])(?:s|\\\\u0073)(?:t|\\\\u0074)(?:r|\\\\u0072)(?:u|\\\\u0075)(?:c|\\\\u0063)(?:t|\\\\u0074)(?:o|\\\\u006[Ff])(?:r|\\\\u0072)\"\\s*:/,JsonSigRx=/^[\"{[]|^-?[0-9][0-9.]{0,14}$/;function jsonParseTransform(key,value){if(\"__proto__\"!==key&&\"constructor\"!==key)return value}function destr(val){if(\"string\"!=typeof val)return val;const _lval=val.toLowerCase();if(\"true\"===_lval)return!0;if(\"false\"===_lval)return!1;if(\"null\"===_lval)return null;if(\"nan\"===_lval)return NaN;if(\"infinity\"===_lval)return 1/0;if(\"undefined\"!==_lval){if(!JsonSigRx.test(val))return val;try{return suspectProtoRx.test(val)||suspectConstructorRx.test(val)?JSON.parse(val,jsonParseTransform):JSON.parse(val)}catch(_e){return val}}}function escapeStringRegexp(string){if(\"string\"!=typeof string)throw new TypeError(\"Expected a string\");return string.replace(/[|\\\\{}()[\\]^$+*?.]/g,\"\\\\$&\").replace(/-/g,\"\\\\x2d\")}var create_require=__webpack_require__(\"./node_modules/.pnpm/create-require@1.1.1/node_modules/create-require/create-require.js\"),create_require_default=__webpack_require__.n(create_require),semver=__webpack_require__(\"./node_modules/.pnpm/semver@7.3.7/node_modules/semver/index.js\");const pathSeparators=[\"/\",\"\\\\\",void 0],normalizedAliasSymbol=Symbol.for(\"pathe:normalizedAlias\");function normalizeAliases(_aliases){if(_aliases[normalizedAliasSymbol])return _aliases;const aliases=Object.fromEntries(Object.entries(_aliases).sort((([a],[b])=>function(a,b){return b.split(\"/\").length-a.split(\"/\").length}(a,b))));for(const key in aliases)for(const alias in aliases)alias===key||key.startsWith(alias)||aliases[key].startsWith(alias)&&pathSeparators.includes(aliases[key][alias.length])&&(aliases[key]=aliases[alias]+aliases[key].slice(alias.length));return Object.defineProperty(aliases,normalizedAliasSymbol,{value:!0,enumerable:!1}),aliases}var lib=__webpack_require__(\"./node_modules/.pnpm/pirates@4.0.5/node_modules/pirates/lib/index.js\"),object_hash=__webpack_require__(\"./node_modules/.pnpm/object-hash@3.0.0/node_modules/object-hash/index.js\"),object_hash_default=__webpack_require__.n(object_hash),astralIdentifierCodes=[509,0,227,0,150,4,294,9,1368,2,2,1,6,3,41,2,5,0,166,1,574,3,9,9,370,1,154,10,50,3,123,2,54,14,32,10,3,1,11,3,46,10,8,0,46,9,7,2,37,13,2,9,6,1,45,0,13,2,49,13,9,3,2,11,83,11,7,0,161,11,6,9,7,3,56,1,2,6,3,1,3,2,10,0,11,1,3,6,4,4,193,17,10,9,5,0,82,19,13,9,214,6,3,8,28,1,83,16,16,9,82,12,9,9,84,14,5,9,243,14,166,9,71,5,2,1,3,3,2,0,2,1,13,9,120,6,3,6,4,0,29,9,41,6,2,3,9,0,10,10,47,15,406,7,2,7,17,9,57,21,2,13,123,5,4,0,2,1,2,6,2,0,9,9,49,4,2,1,2,4,9,9,330,3,19306,9,87,9,39,4,60,6,26,9,1014,0,2,54,8,3,82,0,12,1,19628,1,4706,45,3,22,543,4,4,5,9,7,3,6,31,3,149,2,1418,49,513,54,5,49,9,0,15,0,23,4,2,14,1361,6,2,16,3,6,2,1,2,4,262,6,10,9,357,0,62,13,1495,6,110,6,6,9,4759,9,787719,239],astralIdentifierStartCodes=[0,11,2,25,2,18,2,1,2,14,3,13,35,122,70,52,268,28,4,48,48,31,14,29,6,37,11,29,3,35,5,7,2,4,43,157,19,35,5,35,5,39,9,51,13,10,2,14,2,6,2,1,2,10,2,14,2,6,2,1,68,310,10,21,11,7,25,5,2,41,2,8,70,5,3,0,2,43,2,1,4,0,3,22,11,22,10,30,66,18,2,1,11,21,11,25,71,55,7,1,65,0,16,3,2,2,2,28,43,28,4,28,36,7,2,27,28,53,11,21,11,18,14,17,111,72,56,50,14,50,14,35,349,41,7,1,79,28,11,0,9,21,43,17,47,20,28,22,13,52,58,1,3,0,14,44,33,24,27,35,30,0,3,0,9,34,4,0,13,47,15,3,22,0,2,0,36,17,2,24,85,6,2,0,2,3,2,14,2,9,8,46,39,7,3,1,3,21,2,6,2,1,2,4,4,0,19,0,13,4,159,52,19,3,21,2,31,47,21,1,2,0,185,46,42,3,37,47,21,0,60,42,14,0,72,26,38,6,186,43,117,63,32,7,3,0,3,7,2,1,2,23,16,0,2,0,95,7,3,38,17,0,2,0,29,0,11,39,8,0,22,0,12,45,20,0,19,72,264,8,2,36,18,0,50,29,113,6,2,1,2,37,22,0,26,5,2,1,2,31,15,0,328,18,190,0,80,921,103,110,18,195,2637,96,16,1070,4050,582,8634,568,8,30,18,78,18,29,19,47,17,3,32,20,6,18,689,63,129,74,6,0,67,12,65,1,2,0,29,6135,9,1237,43,8,8936,3,2,6,2,1,2,290,46,2,18,3,9,395,2309,106,6,12,4,8,8,9,5991,84,2,70,2,1,3,0,3,1,3,3,2,11,2,0,2,6,2,64,2,3,3,7,2,6,2,27,2,3,2,4,2,0,4,6,2,339,3,24,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,7,1845,30,482,44,11,6,17,0,322,29,19,43,1269,6,2,3,2,1,2,14,2,196,60,67,8,0,1205,3,2,26,2,1,2,0,3,0,2,9,2,3,2,0,2,0,7,0,5,0,2,0,2,0,2,2,2,1,2,0,3,0,2,0,2,0,2,0,2,0,2,1,2,0,3,3,2,6,2,3,2,3,2,0,2,9,2,16,6,2,2,4,2,16,4421,42719,33,4152,8,221,3,5761,15,7472,3104,541,1507,4938],nonASCIIidentifierStartChars=\"\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u05D0-\u05EA\u05EF-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u0870-\u0887\u0889-\u088E\u08A0-\u08C9\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D04-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u1711\u171F-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1878\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4C\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1C90-\u1CBA\u1CBD-\u1CBF\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5\u1CF6\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309B-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u31A0-\u31BF\u31F0-\u31FF\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7CA\uA7D0\uA7D1\uA7D3\uA7D5-\uA7D9\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA8FE\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB69\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC\",reservedWords={3:\"abstract boolean byte char class double enum export extends final float goto implements import int interface long native package private protected public short static super synchronized throws transient volatile\",5:\"class enum extends super const export import\",6:\"enum\",strict:\"implements interface let package private protected public static yield\",strictBind:\"eval arguments\"},ecma5AndLessKeywords=\"break case catch continue debugger default do else finally for function if return switch throw try var while with null true false instanceof typeof void delete new in this\",keywords$1={5:ecma5AndLessKeywords,\"5module\":ecma5AndLessKeywords+\" export import\",6:ecma5AndLessKeywords+\" const class extends export import super\"},keywordRelationalOperator=/^in(stanceof)?$/,nonASCIIidentifierStart=new RegExp(\"[\"+nonASCIIidentifierStartChars+\"]\"),nonASCIIidentifier=new RegExp(\"[\"+nonASCIIidentifierStartChars+\"\u200C\u200D\u00B7\u0300-\u036F\u0387\u0483-\u0487\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u0669\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u06F0-\u06F9\u0711\u0730-\u074A\u07A6-\u07B0\u07C0-\u07C9\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0898-\u089F\u08CA-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0966-\u096F\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u09E6-\u09EF\u09FE\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A66-\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0AE6-\u0AEF\u0AFA-\u0AFF\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B66-\u0B6F\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0BE6-\u0BEF\u0C00-\u0C04\u0C3C\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C66-\u0C6F\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0CE6-\u0CEF\u0D00-\u0D03\u0D3B\u0D3C\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D66-\u0D6F\u0D81-\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0E50-\u0E59\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECD\u0ED0-\u0ED9\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1040-\u1049\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F-\u109D\u135D-\u135F\u1369-\u1371\u1712-\u1715\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u17E0-\u17E9\u180B-\u180D\u180F-\u1819\u18A9\u1920-\u192B\u1930-\u193B\u1946-\u194F\u19D0-\u19DA\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AB0-\u1ABD\u1ABF-\u1ACE\u1B00-\u1B04\u1B34-\u1B44\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BB0-\u1BB9\u1BE6-\u1BF3\u1C24-\u1C37\u1C40-\u1C49\u1C50-\u1C59\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF4\u1CF7-\u1CF9\u1DC0-\u1DFF\u203F\u2040\u2054\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA620-\uA629\uA66F\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA82C\uA880\uA881\uA8B4-\uA8C5\uA8D0-\uA8D9\uA8E0-\uA8F1\uA8FF-\uA909\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9D0-\uA9D9\uA9E5\uA9F0-\uA9F9\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA50-\uAA59\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uABF0-\uABF9\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFF10-\uFF19\uFF3F]\");function isInAstralSet(code,set){for(var pos=65536,i=0;icode)return!1;if((pos+=set[i+1])>=code)return!0}}function isIdentifierStart(code,astral){return code<65?36===code:code<91||(code<97?95===code:code<123||(code<=65535?code>=170&&nonASCIIidentifierStart.test(String.fromCharCode(code)):!1!==astral&&isInAstralSet(code,astralIdentifierStartCodes)))}function isIdentifierChar(code,astral){return code<48?36===code:code<58||!(code<65)&&(code<91||(code<97?95===code:code<123||(code<=65535?code>=170&&nonASCIIidentifier.test(String.fromCharCode(code)):!1!==astral&&(isInAstralSet(code,astralIdentifierStartCodes)||isInAstralSet(code,astralIdentifierCodes)))))}var TokenType=function(label,conf){void 0===conf&&(conf={}),this.label=label,this.keyword=conf.keyword,this.beforeExpr=!!conf.beforeExpr,this.startsExpr=!!conf.startsExpr,this.isLoop=!!conf.isLoop,this.isAssign=!!conf.isAssign,this.prefix=!!conf.prefix,this.postfix=!!conf.postfix,this.binop=conf.binop||null,this.updateContext=null};function binop(name,prec){return new TokenType(name,{beforeExpr:!0,binop:prec})}var beforeExpr={beforeExpr:!0},startsExpr={startsExpr:!0},keywords={};function kw(name,options){return void 0===options&&(options={}),options.keyword=name,keywords[name]=new TokenType(name,options)}var types$1={num:new TokenType(\"num\",startsExpr),regexp:new TokenType(\"regexp\",startsExpr),string:new TokenType(\"string\",startsExpr),name:new TokenType(\"name\",startsExpr),privateId:new TokenType(\"privateId\",startsExpr),eof:new TokenType(\"eof\"),bracketL:new TokenType(\"[\",{beforeExpr:!0,startsExpr:!0}),bracketR:new TokenType(\"]\"),braceL:new TokenType(\"{\",{beforeExpr:!0,startsExpr:!0}),braceR:new TokenType(\"}\"),parenL:new TokenType(\"(\",{beforeExpr:!0,startsExpr:!0}),parenR:new TokenType(\")\"),comma:new TokenType(\",\",beforeExpr),semi:new TokenType(\";\",beforeExpr),colon:new TokenType(\":\",beforeExpr),dot:new TokenType(\".\"),question:new TokenType(\"?\",beforeExpr),questionDot:new TokenType(\"?.\"),arrow:new TokenType(\"=>\",beforeExpr),template:new TokenType(\"template\"),invalidTemplate:new TokenType(\"invalidTemplate\"),ellipsis:new TokenType(\"...\",beforeExpr),backQuote:new TokenType(\"`\",startsExpr),dollarBraceL:new TokenType(\"${\",{beforeExpr:!0,startsExpr:!0}),eq:new TokenType(\"=\",{beforeExpr:!0,isAssign:!0}),assign:new TokenType(\"_=\",{beforeExpr:!0,isAssign:!0}),incDec:new TokenType(\"++/--\",{prefix:!0,postfix:!0,startsExpr:!0}),prefix:new TokenType(\"!/~\",{beforeExpr:!0,prefix:!0,startsExpr:!0}),logicalOR:binop(\"||\",1),logicalAND:binop(\"&&\",2),bitwiseOR:binop(\"|\",3),bitwiseXOR:binop(\"^\",4),bitwiseAND:binop(\"&\",5),equality:binop(\"==/!=/===/!==\",6),relational:binop(\"/<=/>=\",7),bitShift:binop(\"<>/>>>\",8),plusMin:new TokenType(\"+/-\",{beforeExpr:!0,binop:9,prefix:!0,startsExpr:!0}),modulo:binop(\"%\",10),star:binop(\"*\",10),slash:binop(\"/\",10),starstar:new TokenType(\"**\",{beforeExpr:!0}),coalesce:binop(\"??\",1),_break:kw(\"break\"),_case:kw(\"case\",beforeExpr),_catch:kw(\"catch\"),_continue:kw(\"continue\"),_debugger:kw(\"debugger\"),_default:kw(\"default\",beforeExpr),_do:kw(\"do\",{isLoop:!0,beforeExpr:!0}),_else:kw(\"else\",beforeExpr),_finally:kw(\"finally\"),_for:kw(\"for\",{isLoop:!0}),_function:kw(\"function\",startsExpr),_if:kw(\"if\"),_return:kw(\"return\",beforeExpr),_switch:kw(\"switch\"),_throw:kw(\"throw\",beforeExpr),_try:kw(\"try\"),_var:kw(\"var\"),_const:kw(\"const\"),_while:kw(\"while\",{isLoop:!0}),_with:kw(\"with\"),_new:kw(\"new\",{beforeExpr:!0,startsExpr:!0}),_this:kw(\"this\",startsExpr),_super:kw(\"super\",startsExpr),_class:kw(\"class\",startsExpr),_extends:kw(\"extends\",beforeExpr),_export:kw(\"export\"),_import:kw(\"import\",startsExpr),_null:kw(\"null\",startsExpr),_true:kw(\"true\",startsExpr),_false:kw(\"false\",startsExpr),_in:kw(\"in\",{beforeExpr:!0,binop:7}),_instanceof:kw(\"instanceof\",{beforeExpr:!0,binop:7}),_typeof:kw(\"typeof\",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_void:kw(\"void\",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_delete:kw(\"delete\",{beforeExpr:!0,prefix:!0,startsExpr:!0})},lineBreak=/\\r\\n?|\\n|\\u2028|\\u2029/,lineBreakG=new RegExp(lineBreak.source,\"g\");function isNewLine(code){return 10===code||13===code||8232===code||8233===code}function nextLineBreak(code,from,end){void 0===end&&(end=code.length);for(var i=from;i>10),56320+(1023&code)))}var loneSurrogate=/(?:[\\uD800-\\uDBFF](?![\\uDC00-\\uDFFF])|(?:[^\\uD800-\\uDBFF]|^)[\\uDC00-\\uDFFF])/,Position=function(line,col){this.line=line,this.column=col};Position.prototype.offset=function(n){return new Position(this.line,this.column+n)};var SourceLocation=function(p,start,end){this.start=start,this.end=end,null!==p.sourceFile&&(this.source=p.sourceFile)};function getLineInfo(input,offset){for(var line=1,cur=0;;){var nextBreak=nextLineBreak(input,cur,offset);if(nextBreak<0)return new Position(line,offset-cur);++line,cur=nextBreak}}var defaultOptions={ecmaVersion:null,sourceType:\"script\",onInsertedSemicolon:null,onTrailingComma:null,allowReserved:null,allowReturnOutsideFunction:!1,allowImportExportEverywhere:!1,allowAwaitOutsideFunction:null,allowSuperOutsideMethod:null,allowHashBang:!1,locations:!1,onToken:null,onComment:null,ranges:!1,program:null,sourceFile:null,directSourceFile:null,preserveParens:!1},warnedAboutEcmaVersion=!1;function getOptions(opts){var options={};for(var opt in defaultOptions)options[opt]=opts&&hasOwn(opts,opt)?opts[opt]:defaultOptions[opt];if(\"latest\"===options.ecmaVersion?options.ecmaVersion=1e8:null==options.ecmaVersion?(!warnedAboutEcmaVersion&&\"object\"==typeof console&&console.warn&&(warnedAboutEcmaVersion=!0,console.warn(\"Since Acorn 8.0.0, options.ecmaVersion is required.\\nDefaulting to 2020, but this will stop working in the future.\")),options.ecmaVersion=11):options.ecmaVersion>=2015&&(options.ecmaVersion-=2009),null==options.allowReserved&&(options.allowReserved=options.ecmaVersion<5),null==opts.allowHashBang&&(options.allowHashBang=options.ecmaVersion>=14),isArray(options.onToken)){var tokens=options.onToken;options.onToken=function(token){return tokens.push(token)}}return isArray(options.onComment)&&(options.onComment=function(options,array){return function(block,text,start,end,startLoc,endLoc){var comment={type:block?\"Block\":\"Line\",value:text,start,end};options.locations&&(comment.loc=new SourceLocation(this,startLoc,endLoc)),options.ranges&&(comment.range=[start,end]),array.push(comment)}}(options,options.onComment)),options}function functionFlags(async,generator){return 2|(async?4:0)|(generator?8:0)}var Parser=function(options,input,startPos){this.options=options=getOptions(options),this.sourceFile=options.sourceFile,this.keywords=wordsRegexp(keywords$1[options.ecmaVersion>=6?6:\"module\"===options.sourceType?\"5module\":5]);var reserved=\"\";!0!==options.allowReserved&&(reserved=reservedWords[options.ecmaVersion>=6?6:5===options.ecmaVersion?5:3],\"module\"===options.sourceType&&(reserved+=\" await\")),this.reservedWords=wordsRegexp(reserved);var reservedStrict=(reserved?reserved+\" \":\"\")+reservedWords.strict;this.reservedWordsStrict=wordsRegexp(reservedStrict),this.reservedWordsStrictBind=wordsRegexp(reservedStrict+\" \"+reservedWords.strictBind),this.input=String(input),this.containsEsc=!1,startPos?(this.pos=startPos,this.lineStart=this.input.lastIndexOf(\"\\n\",startPos-1)+1,this.curLine=this.input.slice(0,this.lineStart).split(lineBreak).length):(this.pos=this.lineStart=0,this.curLine=1),this.type=types$1.eof,this.value=null,this.start=this.end=this.pos,this.startLoc=this.endLoc=this.curPosition(),this.lastTokEndLoc=this.lastTokStartLoc=null,this.lastTokStart=this.lastTokEnd=this.pos,this.context=this.initialContext(),this.exprAllowed=!0,this.inModule=\"module\"===options.sourceType,this.strict=this.inModule||this.strictDirective(this.pos),this.potentialArrowAt=-1,this.potentialArrowInForAwait=!1,this.yieldPos=this.awaitPos=this.awaitIdentPos=0,this.labels=[],this.undefinedExports=Object.create(null),0===this.pos&&options.allowHashBang&&\"#!\"===this.input.slice(0,2)&&this.skipLineComment(2),this.scopeStack=[],this.enterScope(1),this.regexpState=null,this.privateNameStack=[]},prototypeAccessors={inFunction:{configurable:!0},inGenerator:{configurable:!0},inAsync:{configurable:!0},canAwait:{configurable:!0},allowSuper:{configurable:!0},allowDirectSuper:{configurable:!0},treatFunctionsAsVar:{configurable:!0},allowNewDotTarget:{configurable:!0},inClassStaticBlock:{configurable:!0}};Parser.prototype.parse=function(){var node=this.options.program||this.startNode();return this.nextToken(),this.parseTopLevel(node)},prototypeAccessors.inFunction.get=function(){return(2&this.currentVarScope().flags)>0},prototypeAccessors.inGenerator.get=function(){return(8&this.currentVarScope().flags)>0&&!this.currentVarScope().inClassFieldInit},prototypeAccessors.inAsync.get=function(){return(4&this.currentVarScope().flags)>0&&!this.currentVarScope().inClassFieldInit},prototypeAccessors.canAwait.get=function(){for(var i=this.scopeStack.length-1;i>=0;i--){var scope=this.scopeStack[i];if(scope.inClassFieldInit||256&scope.flags)return!1;if(2&scope.flags)return(4&scope.flags)>0}return this.inModule&&this.options.ecmaVersion>=13||this.options.allowAwaitOutsideFunction},prototypeAccessors.allowSuper.get=function(){var ref=this.currentThisScope(),flags=ref.flags,inClassFieldInit=ref.inClassFieldInit;return(64&flags)>0||inClassFieldInit||this.options.allowSuperOutsideMethod},prototypeAccessors.allowDirectSuper.get=function(){return(128&this.currentThisScope().flags)>0},prototypeAccessors.treatFunctionsAsVar.get=function(){return this.treatFunctionsAsVarInScope(this.currentScope())},prototypeAccessors.allowNewDotTarget.get=function(){var ref=this.currentThisScope(),flags=ref.flags,inClassFieldInit=ref.inClassFieldInit;return(258&flags)>0||inClassFieldInit},prototypeAccessors.inClassStaticBlock.get=function(){return(256&this.currentVarScope().flags)>0},Parser.extend=function(){for(var plugins=[],len=arguments.length;len--;)plugins[len]=arguments[len];for(var cls=this,i=0;i=,?^&]/.test(next)||\"!\"===next&&\"=\"===this.input.charAt(end+1))}start+=match[0].length,skipWhiteSpace.lastIndex=start,start+=skipWhiteSpace.exec(this.input)[0].length,\";\"===this.input[start]&&start++}},pp$9.eat=function(type){return this.type===type&&(this.next(),!0)},pp$9.isContextual=function(name){return this.type===types$1.name&&this.value===name&&!this.containsEsc},pp$9.eatContextual=function(name){return!!this.isContextual(name)&&(this.next(),!0)},pp$9.expectContextual=function(name){this.eatContextual(name)||this.unexpected()},pp$9.canInsertSemicolon=function(){return this.type===types$1.eof||this.type===types$1.braceR||lineBreak.test(this.input.slice(this.lastTokEnd,this.start))},pp$9.insertSemicolon=function(){if(this.canInsertSemicolon())return this.options.onInsertedSemicolon&&this.options.onInsertedSemicolon(this.lastTokEnd,this.lastTokEndLoc),!0},pp$9.semicolon=function(){this.eat(types$1.semi)||this.insertSemicolon()||this.unexpected()},pp$9.afterTrailingComma=function(tokType,notNext){if(this.type===tokType)return this.options.onTrailingComma&&this.options.onTrailingComma(this.lastTokStart,this.lastTokStartLoc),notNext||this.next(),!0},pp$9.expect=function(type){this.eat(type)||this.unexpected()},pp$9.unexpected=function(pos){this.raise(null!=pos?pos:this.start,\"Unexpected token\")};var DestructuringErrors=function(){this.shorthandAssign=this.trailingComma=this.parenthesizedAssign=this.parenthesizedBind=this.doubleProto=-1};pp$9.checkPatternErrors=function(refDestructuringErrors,isAssign){if(refDestructuringErrors){refDestructuringErrors.trailingComma>-1&&this.raiseRecoverable(refDestructuringErrors.trailingComma,\"Comma is not permitted after the rest element\");var parens=isAssign?refDestructuringErrors.parenthesizedAssign:refDestructuringErrors.parenthesizedBind;parens>-1&&this.raiseRecoverable(parens,isAssign?\"Assigning to rvalue\":\"Parenthesized pattern\")}},pp$9.checkExpressionErrors=function(refDestructuringErrors,andThrow){if(!refDestructuringErrors)return!1;var shorthandAssign=refDestructuringErrors.shorthandAssign,doubleProto=refDestructuringErrors.doubleProto;if(!andThrow)return shorthandAssign>=0||doubleProto>=0;shorthandAssign>=0&&this.raise(shorthandAssign,\"Shorthand property assignments are valid only in destructuring patterns\"),doubleProto>=0&&this.raiseRecoverable(doubleProto,\"Redefinition of __proto__ property\")},pp$9.checkYieldAwaitInDefaultParams=function(){this.yieldPos&&(!this.awaitPos||this.yieldPos55295&&nextCh<56320)return!0;if(context)return!1;if(123===nextCh)return!0;if(isIdentifierStart(nextCh,!0)){for(var pos=next+1;isIdentifierChar(nextCh=this.input.charCodeAt(pos),!0);)++pos;if(92===nextCh||nextCh>55295&&nextCh<56320)return!0;var ident=this.input.slice(next,pos);if(!keywordRelationalOperator.test(ident))return!0}return!1},pp$8.isAsyncFunction=function(){if(this.options.ecmaVersion<8||!this.isContextual(\"async\"))return!1;skipWhiteSpace.lastIndex=this.pos;var after,skip=skipWhiteSpace.exec(this.input),next=this.pos+skip[0].length;return!(lineBreak.test(this.input.slice(this.pos,next))||\"function\"!==this.input.slice(next,next+8)||next+8!==this.input.length&&(isIdentifierChar(after=this.input.charCodeAt(next+8))||after>55295&&after<56320))},pp$8.parseStatement=function(context,topLevel,exports){var kind,starttype=this.type,node=this.startNode();switch(this.isLet(context)&&(starttype=types$1._var,kind=\"let\"),starttype){case types$1._break:case types$1._continue:return this.parseBreakContinueStatement(node,starttype.keyword);case types$1._debugger:return this.parseDebuggerStatement(node);case types$1._do:return this.parseDoStatement(node);case types$1._for:return this.parseForStatement(node);case types$1._function:return context&&(this.strict||\"if\"!==context&&\"label\"!==context)&&this.options.ecmaVersion>=6&&this.unexpected(),this.parseFunctionStatement(node,!1,!context);case types$1._class:return context&&this.unexpected(),this.parseClass(node,!0);case types$1._if:return this.parseIfStatement(node);case types$1._return:return this.parseReturnStatement(node);case types$1._switch:return this.parseSwitchStatement(node);case types$1._throw:return this.parseThrowStatement(node);case types$1._try:return this.parseTryStatement(node);case types$1._const:case types$1._var:return kind=kind||this.value,context&&\"var\"!==kind&&this.unexpected(),this.parseVarStatement(node,kind);case types$1._while:return this.parseWhileStatement(node);case types$1._with:return this.parseWithStatement(node);case types$1.braceL:return this.parseBlock(!0,node);case types$1.semi:return this.parseEmptyStatement(node);case types$1._export:case types$1._import:if(this.options.ecmaVersion>10&&starttype===types$1._import){skipWhiteSpace.lastIndex=this.pos;var skip=skipWhiteSpace.exec(this.input),next=this.pos+skip[0].length,nextCh=this.input.charCodeAt(next);if(40===nextCh||46===nextCh)return this.parseExpressionStatement(node,this.parseExpression())}return this.options.allowImportExportEverywhere||(topLevel||this.raise(this.start,\"'import' and 'export' may only appear at the top level\"),this.inModule||this.raise(this.start,\"'import' and 'export' may appear only with 'sourceType: module'\")),starttype===types$1._import?this.parseImport(node):this.parseExport(node,exports);default:if(this.isAsyncFunction())return context&&this.unexpected(),this.next(),this.parseFunctionStatement(node,!0,!context);var maybeName=this.value,expr=this.parseExpression();return starttype===types$1.name&&\"Identifier\"===expr.type&&this.eat(types$1.colon)?this.parseLabeledStatement(node,maybeName,expr,context):this.parseExpressionStatement(node,expr)}},pp$8.parseBreakContinueStatement=function(node,keyword){var isBreak=\"break\"===keyword;this.next(),this.eat(types$1.semi)||this.insertSemicolon()?node.label=null:this.type!==types$1.name?this.unexpected():(node.label=this.parseIdent(),this.semicolon());for(var i=0;i=6?this.eat(types$1.semi):this.semicolon(),this.finishNode(node,\"DoWhileStatement\")},pp$8.parseForStatement=function(node){this.next();var awaitAt=this.options.ecmaVersion>=9&&this.canAwait&&this.eatContextual(\"await\")?this.lastTokStart:-1;if(this.labels.push(loopLabel),this.enterScope(0),this.expect(types$1.parenL),this.type===types$1.semi)return awaitAt>-1&&this.unexpected(awaitAt),this.parseFor(node,null);var isLet=this.isLet();if(this.type===types$1._var||this.type===types$1._const||isLet){var init$1=this.startNode(),kind=isLet?\"let\":this.value;return this.next(),this.parseVar(init$1,!0,kind),this.finishNode(init$1,\"VariableDeclaration\"),(this.type===types$1._in||this.options.ecmaVersion>=6&&this.isContextual(\"of\"))&&1===init$1.declarations.length?(this.options.ecmaVersion>=9&&(this.type===types$1._in?awaitAt>-1&&this.unexpected(awaitAt):node.await=awaitAt>-1),this.parseForIn(node,init$1)):(awaitAt>-1&&this.unexpected(awaitAt),this.parseFor(node,init$1))}var startsWithLet=this.isContextual(\"let\"),isForOf=!1,refDestructuringErrors=new DestructuringErrors,init=this.parseExpression(!(awaitAt>-1)||\"await\",refDestructuringErrors);return this.type===types$1._in||(isForOf=this.options.ecmaVersion>=6&&this.isContextual(\"of\"))?(this.options.ecmaVersion>=9&&(this.type===types$1._in?awaitAt>-1&&this.unexpected(awaitAt):node.await=awaitAt>-1),startsWithLet&&isForOf&&this.raise(init.start,\"The left-hand side of a for-of loop may not start with 'let'.\"),this.toAssignable(init,!1,refDestructuringErrors),this.checkLValPattern(init),this.parseForIn(node,init)):(this.checkExpressionErrors(refDestructuringErrors,!0),awaitAt>-1&&this.unexpected(awaitAt),this.parseFor(node,init))},pp$8.parseFunctionStatement=function(node,isAsync,declarationPosition){return this.next(),this.parseFunction(node,FUNC_STATEMENT|(declarationPosition?0:FUNC_HANGING_STATEMENT),!1,isAsync)},pp$8.parseIfStatement=function(node){return this.next(),node.test=this.parseParenExpression(),node.consequent=this.parseStatement(\"if\"),node.alternate=this.eat(types$1._else)?this.parseStatement(\"if\"):null,this.finishNode(node,\"IfStatement\")},pp$8.parseReturnStatement=function(node){return this.inFunction||this.options.allowReturnOutsideFunction||this.raise(this.start,\"'return' outside of function\"),this.next(),this.eat(types$1.semi)||this.insertSemicolon()?node.argument=null:(node.argument=this.parseExpression(),this.semicolon()),this.finishNode(node,\"ReturnStatement\")},pp$8.parseSwitchStatement=function(node){var cur;this.next(),node.discriminant=this.parseParenExpression(),node.cases=[],this.expect(types$1.braceL),this.labels.push(switchLabel),this.enterScope(0);for(var sawDefault=!1;this.type!==types$1.braceR;)if(this.type===types$1._case||this.type===types$1._default){var isCase=this.type===types$1._case;cur&&this.finishNode(cur,\"SwitchCase\"),node.cases.push(cur=this.startNode()),cur.consequent=[],this.next(),isCase?cur.test=this.parseExpression():(sawDefault&&this.raiseRecoverable(this.lastTokStart,\"Multiple default clauses\"),sawDefault=!0,cur.test=null),this.expect(types$1.colon)}else cur||this.unexpected(),cur.consequent.push(this.parseStatement(null));return this.exitScope(),cur&&this.finishNode(cur,\"SwitchCase\"),this.next(),this.labels.pop(),this.finishNode(node,\"SwitchStatement\")},pp$8.parseThrowStatement=function(node){return this.next(),lineBreak.test(this.input.slice(this.lastTokEnd,this.start))&&this.raise(this.lastTokEnd,\"Illegal newline after throw\"),node.argument=this.parseExpression(),this.semicolon(),this.finishNode(node,\"ThrowStatement\")};var empty$1=[];pp$8.parseTryStatement=function(node){if(this.next(),node.block=this.parseBlock(),node.handler=null,this.type===types$1._catch){var clause=this.startNode();if(this.next(),this.eat(types$1.parenL)){clause.param=this.parseBindingAtom();var simple=\"Identifier\"===clause.param.type;this.enterScope(simple?32:0),this.checkLValPattern(clause.param,simple?4:2),this.expect(types$1.parenR)}else this.options.ecmaVersion<10&&this.unexpected(),clause.param=null,this.enterScope(0);clause.body=this.parseBlock(!1),this.exitScope(),node.handler=this.finishNode(clause,\"CatchClause\")}return node.finalizer=this.eat(types$1._finally)?this.parseBlock():null,node.handler||node.finalizer||this.raise(node.start,\"Missing catch or finally clause\"),this.finishNode(node,\"TryStatement\")},pp$8.parseVarStatement=function(node,kind){return this.next(),this.parseVar(node,!1,kind),this.semicolon(),this.finishNode(node,\"VariableDeclaration\")},pp$8.parseWhileStatement=function(node){return this.next(),node.test=this.parseParenExpression(),this.labels.push(loopLabel),node.body=this.parseStatement(\"while\"),this.labels.pop(),this.finishNode(node,\"WhileStatement\")},pp$8.parseWithStatement=function(node){return this.strict&&this.raise(this.start,\"'with' in strict mode\"),this.next(),node.object=this.parseParenExpression(),node.body=this.parseStatement(\"with\"),this.finishNode(node,\"WithStatement\")},pp$8.parseEmptyStatement=function(node){return this.next(),this.finishNode(node,\"EmptyStatement\")},pp$8.parseLabeledStatement=function(node,maybeName,expr,context){for(var i$1=0,list=this.labels;i$1=0;i--){var label$1=this.labels[i];if(label$1.statementStart!==node.start)break;label$1.statementStart=this.start,label$1.kind=kind}return this.labels.push({name:maybeName,kind,statementStart:this.start}),node.body=this.parseStatement(context?-1===context.indexOf(\"label\")?context+\"label\":context:\"label\"),this.labels.pop(),node.label=expr,this.finishNode(node,\"LabeledStatement\")},pp$8.parseExpressionStatement=function(node,expr){return node.expression=expr,this.semicolon(),this.finishNode(node,\"ExpressionStatement\")},pp$8.parseBlock=function(createNewLexicalScope,node,exitStrict){for(void 0===createNewLexicalScope&&(createNewLexicalScope=!0),void 0===node&&(node=this.startNode()),node.body=[],this.expect(types$1.braceL),createNewLexicalScope&&this.enterScope(0);this.type!==types$1.braceR;){var stmt=this.parseStatement(null);node.body.push(stmt)}return exitStrict&&(this.strict=!1),this.next(),createNewLexicalScope&&this.exitScope(),this.finishNode(node,\"BlockStatement\")},pp$8.parseFor=function(node,init){return node.init=init,this.expect(types$1.semi),node.test=this.type===types$1.semi?null:this.parseExpression(),this.expect(types$1.semi),node.update=this.type===types$1.parenR?null:this.parseExpression(),this.expect(types$1.parenR),node.body=this.parseStatement(\"for\"),this.exitScope(),this.labels.pop(),this.finishNode(node,\"ForStatement\")},pp$8.parseForIn=function(node,init){var isForIn=this.type===types$1._in;return this.next(),\"VariableDeclaration\"===init.type&&null!=init.declarations[0].init&&(!isForIn||this.options.ecmaVersion<8||this.strict||\"var\"!==init.kind||\"Identifier\"!==init.declarations[0].id.type)&&this.raise(init.start,(isForIn?\"for-in\":\"for-of\")+\" loop variable declaration may not have an initializer\"),node.left=init,node.right=isForIn?this.parseExpression():this.parseMaybeAssign(),this.expect(types$1.parenR),node.body=this.parseStatement(\"for\"),this.exitScope(),this.labels.pop(),this.finishNode(node,isForIn?\"ForInStatement\":\"ForOfStatement\")},pp$8.parseVar=function(node,isFor,kind){for(node.declarations=[],node.kind=kind;;){var decl=this.startNode();if(this.parseVarId(decl,kind),this.eat(types$1.eq)?decl.init=this.parseMaybeAssign(isFor):\"const\"!==kind||this.type===types$1._in||this.options.ecmaVersion>=6&&this.isContextual(\"of\")?\"Identifier\"===decl.id.type||isFor&&(this.type===types$1._in||this.isContextual(\"of\"))?decl.init=null:this.raise(this.lastTokEnd,\"Complex binding patterns require an initialization value\"):this.unexpected(),node.declarations.push(this.finishNode(decl,\"VariableDeclarator\")),!this.eat(types$1.comma))break}return node},pp$8.parseVarId=function(decl,kind){decl.id=this.parseBindingAtom(),this.checkLValPattern(decl.id,\"var\"===kind?1:2,!1)};var FUNC_STATEMENT=1,FUNC_HANGING_STATEMENT=2;function isPrivateNameConflicted(privateNameMap,element){var name=element.key.name,curr=privateNameMap[name],next=\"true\";return\"MethodDefinition\"!==element.type||\"get\"!==element.kind&&\"set\"!==element.kind||(next=(element.static?\"s\":\"i\")+element.kind),\"iget\"===curr&&\"iset\"===next||\"iset\"===curr&&\"iget\"===next||\"sget\"===curr&&\"sset\"===next||\"sset\"===curr&&\"sget\"===next?(privateNameMap[name]=\"true\",!1):!!curr||(privateNameMap[name]=next,!1)}function checkKeyName(node,name){var computed=node.computed,key=node.key;return!computed&&(\"Identifier\"===key.type&&key.name===name||\"Literal\"===key.type&&key.value===name)}pp$8.parseFunction=function(node,statement,allowExpressionBody,isAsync,forInit){this.initFunction(node),(this.options.ecmaVersion>=9||this.options.ecmaVersion>=6&&!isAsync)&&(this.type===types$1.star&&statement&FUNC_HANGING_STATEMENT&&this.unexpected(),node.generator=this.eat(types$1.star)),this.options.ecmaVersion>=8&&(node.async=!!isAsync),statement&FUNC_STATEMENT&&(node.id=4&statement&&this.type!==types$1.name?null:this.parseIdent(),!node.id||statement&FUNC_HANGING_STATEMENT||this.checkLValSimple(node.id,this.strict||node.generator||node.async?this.treatFunctionsAsVar?1:2:3));var oldYieldPos=this.yieldPos,oldAwaitPos=this.awaitPos,oldAwaitIdentPos=this.awaitIdentPos;return this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(functionFlags(node.async,node.generator)),statement&FUNC_STATEMENT||(node.id=this.type===types$1.name?this.parseIdent():null),this.parseFunctionParams(node),this.parseFunctionBody(node,allowExpressionBody,!1,forInit),this.yieldPos=oldYieldPos,this.awaitPos=oldAwaitPos,this.awaitIdentPos=oldAwaitIdentPos,this.finishNode(node,statement&FUNC_STATEMENT?\"FunctionDeclaration\":\"FunctionExpression\")},pp$8.parseFunctionParams=function(node){this.expect(types$1.parenL),node.params=this.parseBindingList(types$1.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams()},pp$8.parseClass=function(node,isStatement){this.next();var oldStrict=this.strict;this.strict=!0,this.parseClassId(node,isStatement),this.parseClassSuper(node);var privateNameMap=this.enterClassBody(),classBody=this.startNode(),hadConstructor=!1;for(classBody.body=[],this.expect(types$1.braceL);this.type!==types$1.braceR;){var element=this.parseClassElement(null!==node.superClass);element&&(classBody.body.push(element),\"MethodDefinition\"===element.type&&\"constructor\"===element.kind?(hadConstructor&&this.raise(element.start,\"Duplicate constructor in the same class\"),hadConstructor=!0):element.key&&\"PrivateIdentifier\"===element.key.type&&isPrivateNameConflicted(privateNameMap,element)&&this.raiseRecoverable(element.key.start,\"Identifier '#\"+element.key.name+\"' has already been declared\"))}return this.strict=oldStrict,this.next(),node.body=this.finishNode(classBody,\"ClassBody\"),this.exitClassBody(),this.finishNode(node,isStatement?\"ClassDeclaration\":\"ClassExpression\")},pp$8.parseClassElement=function(constructorAllowsSuper){if(this.eat(types$1.semi))return null;var ecmaVersion=this.options.ecmaVersion,node=this.startNode(),keyName=\"\",isGenerator=!1,isAsync=!1,kind=\"method\",isStatic=!1;if(this.eatContextual(\"static\")){if(ecmaVersion>=13&&this.eat(types$1.braceL))return this.parseClassStaticBlock(node),node;this.isClassElementNameStart()||this.type===types$1.star?isStatic=!0:keyName=\"static\"}if(node.static=isStatic,!keyName&&ecmaVersion>=8&&this.eatContextual(\"async\")&&(!this.isClassElementNameStart()&&this.type!==types$1.star||this.canInsertSemicolon()?keyName=\"async\":isAsync=!0),!keyName&&(ecmaVersion>=9||!isAsync)&&this.eat(types$1.star)&&(isGenerator=!0),!keyName&&!isAsync&&!isGenerator){var lastValue=this.value;(this.eatContextual(\"get\")||this.eatContextual(\"set\"))&&(this.isClassElementNameStart()?kind=lastValue:keyName=lastValue)}if(keyName?(node.computed=!1,node.key=this.startNodeAt(this.lastTokStart,this.lastTokStartLoc),node.key.name=keyName,this.finishNode(node.key,\"Identifier\")):this.parseClassElementName(node),ecmaVersion<13||this.type===types$1.parenL||\"method\"!==kind||isGenerator||isAsync){var isConstructor=!node.static&&checkKeyName(node,\"constructor\"),allowsDirectSuper=isConstructor&&constructorAllowsSuper;isConstructor&&\"method\"!==kind&&this.raise(node.key.start,\"Constructor can't have get/set modifier\"),node.kind=isConstructor?\"constructor\":kind,this.parseClassMethod(node,isGenerator,isAsync,allowsDirectSuper)}else this.parseClassField(node);return node},pp$8.isClassElementNameStart=function(){return this.type===types$1.name||this.type===types$1.privateId||this.type===types$1.num||this.type===types$1.string||this.type===types$1.bracketL||this.type.keyword},pp$8.parseClassElementName=function(element){this.type===types$1.privateId?(\"constructor\"===this.value&&this.raise(this.start,\"Classes can't have an element named '#constructor'\"),element.computed=!1,element.key=this.parsePrivateIdent()):this.parsePropertyName(element)},pp$8.parseClassMethod=function(method,isGenerator,isAsync,allowsDirectSuper){var key=method.key;\"constructor\"===method.kind?(isGenerator&&this.raise(key.start,\"Constructor can't be a generator\"),isAsync&&this.raise(key.start,\"Constructor can't be an async method\")):method.static&&checkKeyName(method,\"prototype\")&&this.raise(key.start,\"Classes may not have a static property named prototype\");var value=method.value=this.parseMethod(isGenerator,isAsync,allowsDirectSuper);return\"get\"===method.kind&&0!==value.params.length&&this.raiseRecoverable(value.start,\"getter should have no params\"),\"set\"===method.kind&&1!==value.params.length&&this.raiseRecoverable(value.start,\"setter should have exactly one param\"),\"set\"===method.kind&&\"RestElement\"===value.params[0].type&&this.raiseRecoverable(value.params[0].start,\"Setter cannot use rest params\"),this.finishNode(method,\"MethodDefinition\")},pp$8.parseClassField=function(field){if(checkKeyName(field,\"constructor\")?this.raise(field.key.start,\"Classes can't have a field named 'constructor'\"):field.static&&checkKeyName(field,\"prototype\")&&this.raise(field.key.start,\"Classes can't have a static field named 'prototype'\"),this.eat(types$1.eq)){var scope=this.currentThisScope(),inClassFieldInit=scope.inClassFieldInit;scope.inClassFieldInit=!0,field.value=this.parseMaybeAssign(),scope.inClassFieldInit=inClassFieldInit}else field.value=null;return this.semicolon(),this.finishNode(field,\"PropertyDefinition\")},pp$8.parseClassStaticBlock=function(node){node.body=[];var oldLabels=this.labels;for(this.labels=[],this.enterScope(320);this.type!==types$1.braceR;){var stmt=this.parseStatement(null);node.body.push(stmt)}return this.next(),this.exitScope(),this.labels=oldLabels,this.finishNode(node,\"StaticBlock\")},pp$8.parseClassId=function(node,isStatement){this.type===types$1.name?(node.id=this.parseIdent(),isStatement&&this.checkLValSimple(node.id,2,!1)):(!0===isStatement&&this.unexpected(),node.id=null)},pp$8.parseClassSuper=function(node){node.superClass=this.eat(types$1._extends)?this.parseExprSubscripts(!1):null},pp$8.enterClassBody=function(){var element={declared:Object.create(null),used:[]};return this.privateNameStack.push(element),element.declared},pp$8.exitClassBody=function(){for(var ref=this.privateNameStack.pop(),declared=ref.declared,used=ref.used,len=this.privateNameStack.length,parent=0===len?null:this.privateNameStack[len-1],i=0;i=11&&(this.eatContextual(\"as\")?(node.exported=this.parseModuleExportName(),this.checkExport(exports,node.exported,this.lastTokStart)):node.exported=null),this.expectContextual(\"from\"),this.type!==types$1.string&&this.unexpected(),node.source=this.parseExprAtom(),this.semicolon(),this.finishNode(node,\"ExportAllDeclaration\");if(this.eat(types$1._default)){var isAsync;if(this.checkExport(exports,\"default\",this.lastTokStart),this.type===types$1._function||(isAsync=this.isAsyncFunction())){var fNode=this.startNode();this.next(),isAsync&&this.next(),node.declaration=this.parseFunction(fNode,4|FUNC_STATEMENT,!1,isAsync)}else if(this.type===types$1._class){var cNode=this.startNode();node.declaration=this.parseClass(cNode,\"nullableID\")}else node.declaration=this.parseMaybeAssign(),this.semicolon();return this.finishNode(node,\"ExportDefaultDeclaration\")}if(this.shouldParseExportStatement())node.declaration=this.parseStatement(null),\"VariableDeclaration\"===node.declaration.type?this.checkVariableExport(exports,node.declaration.declarations):this.checkExport(exports,node.declaration.id,node.declaration.id.start),node.specifiers=[],node.source=null;else{if(node.declaration=null,node.specifiers=this.parseExportSpecifiers(exports),this.eatContextual(\"from\"))this.type!==types$1.string&&this.unexpected(),node.source=this.parseExprAtom();else{for(var i=0,list=node.specifiers;i=13&&this.type===types$1.string){var stringLiteral=this.parseLiteral(this.value);return loneSurrogate.test(stringLiteral.value)&&this.raise(stringLiteral.start,\"An export name cannot include a lone surrogate.\"),stringLiteral}return this.parseIdent(!0)},pp$8.adaptDirectivePrologue=function(statements){for(var i=0;i=5&&\"ExpressionStatement\"===statement.type&&\"Literal\"===statement.expression.type&&\"string\"==typeof statement.expression.value&&('\"'===this.input[statement.start]||\"'\"===this.input[statement.start])};var pp$7=Parser.prototype;pp$7.toAssignable=function(node,isBinding,refDestructuringErrors){if(this.options.ecmaVersion>=6&&node)switch(node.type){case\"Identifier\":this.inAsync&&\"await\"===node.name&&this.raise(node.start,\"Cannot use 'await' as identifier inside an async function\");break;case\"ObjectPattern\":case\"ArrayPattern\":case\"AssignmentPattern\":case\"RestElement\":break;case\"ObjectExpression\":node.type=\"ObjectPattern\",refDestructuringErrors&&this.checkPatternErrors(refDestructuringErrors,!0);for(var i=0,list=node.properties;i=8&&!containsEsc&&\"async\"===id.name&&!this.canInsertSemicolon()&&this.eat(types$1._function))return this.overrideContext(types.f_expr),this.parseFunction(this.startNodeAt(startPos,startLoc),0,!1,!0,forInit);if(canBeArrow&&!this.canInsertSemicolon()){if(this.eat(types$1.arrow))return this.parseArrowExpression(this.startNodeAt(startPos,startLoc),[id],!1,forInit);if(this.options.ecmaVersion>=8&&\"async\"===id.name&&this.type===types$1.name&&!containsEsc&&(!this.potentialArrowInForAwait||\"of\"!==this.value||this.containsEsc))return id=this.parseIdent(!1),!this.canInsertSemicolon()&&this.eat(types$1.arrow)||this.unexpected(),this.parseArrowExpression(this.startNodeAt(startPos,startLoc),[id],!0,forInit)}return id;case types$1.regexp:var value=this.value;return(node=this.parseLiteral(value.value)).regex={pattern:value.pattern,flags:value.flags},node;case types$1.num:case types$1.string:return this.parseLiteral(this.value);case types$1._null:case types$1._true:case types$1._false:return(node=this.startNode()).value=this.type===types$1._null?null:this.type===types$1._true,node.raw=this.type.keyword,this.next(),this.finishNode(node,\"Literal\");case types$1.parenL:var start=this.start,expr=this.parseParenAndDistinguishExpression(canBeArrow,forInit);return refDestructuringErrors&&(refDestructuringErrors.parenthesizedAssign<0&&!this.isSimpleAssignTarget(expr)&&(refDestructuringErrors.parenthesizedAssign=start),refDestructuringErrors.parenthesizedBind<0&&(refDestructuringErrors.parenthesizedBind=start)),expr;case types$1.bracketL:return node=this.startNode(),this.next(),node.elements=this.parseExprList(types$1.bracketR,!0,!0,refDestructuringErrors),this.finishNode(node,\"ArrayExpression\");case types$1.braceL:return this.overrideContext(types.b_expr),this.parseObj(!1,refDestructuringErrors);case types$1._function:return node=this.startNode(),this.next(),this.parseFunction(node,0);case types$1._class:return this.parseClass(this.startNode(),!1);case types$1._new:return this.parseNew();case types$1.backQuote:return this.parseTemplate();case types$1._import:return this.options.ecmaVersion>=11?this.parseExprImport():this.unexpected();default:this.unexpected()}},pp$5.parseExprImport=function(){var node=this.startNode();this.containsEsc&&this.raiseRecoverable(this.start,\"Escape sequence in keyword import\");var meta=this.parseIdent(!0);switch(this.type){case types$1.parenL:return this.parseDynamicImport(node);case types$1.dot:return node.meta=meta,this.parseImportMeta(node);default:this.unexpected()}},pp$5.parseDynamicImport=function(node){if(this.next(),node.source=this.parseMaybeAssign(),!this.eat(types$1.parenR)){var errorPos=this.start;this.eat(types$1.comma)&&this.eat(types$1.parenR)?this.raiseRecoverable(errorPos,\"Trailing comma is not allowed in import()\"):this.unexpected(errorPos)}return this.finishNode(node,\"ImportExpression\")},pp$5.parseImportMeta=function(node){this.next();var containsEsc=this.containsEsc;return node.property=this.parseIdent(!0),\"meta\"!==node.property.name&&this.raiseRecoverable(node.property.start,\"The only valid meta property for import is 'import.meta'\"),containsEsc&&this.raiseRecoverable(node.start,\"'import.meta' must not contain escaped characters\"),\"module\"===this.options.sourceType||this.options.allowImportExportEverywhere||this.raiseRecoverable(node.start,\"Cannot use 'import.meta' outside a module\"),this.finishNode(node,\"MetaProperty\")},pp$5.parseLiteral=function(value){var node=this.startNode();return node.value=value,node.raw=this.input.slice(this.start,this.end),110===node.raw.charCodeAt(node.raw.length-1)&&(node.bigint=node.raw.slice(0,-1).replace(/_/g,\"\")),this.next(),this.finishNode(node,\"Literal\")},pp$5.parseParenExpression=function(){this.expect(types$1.parenL);var val=this.parseExpression();return this.expect(types$1.parenR),val},pp$5.parseParenAndDistinguishExpression=function(canBeArrow,forInit){var val,startPos=this.start,startLoc=this.startLoc,allowTrailingComma=this.options.ecmaVersion>=8;if(this.options.ecmaVersion>=6){this.next();var spreadStart,innerStartPos=this.start,innerStartLoc=this.startLoc,exprList=[],first=!0,lastIsComma=!1,refDestructuringErrors=new DestructuringErrors,oldYieldPos=this.yieldPos,oldAwaitPos=this.awaitPos;for(this.yieldPos=0,this.awaitPos=0;this.type!==types$1.parenR;){if(first?first=!1:this.expect(types$1.comma),allowTrailingComma&&this.afterTrailingComma(types$1.parenR,!0)){lastIsComma=!0;break}if(this.type===types$1.ellipsis){spreadStart=this.start,exprList.push(this.parseParenItem(this.parseRestBinding())),this.type===types$1.comma&&this.raise(this.start,\"Comma is not permitted after the rest element\");break}exprList.push(this.parseMaybeAssign(!1,refDestructuringErrors,this.parseParenItem))}var innerEndPos=this.lastTokEnd,innerEndLoc=this.lastTokEndLoc;if(this.expect(types$1.parenR),canBeArrow&&!this.canInsertSemicolon()&&this.eat(types$1.arrow))return this.checkPatternErrors(refDestructuringErrors,!1),this.checkYieldAwaitInDefaultParams(),this.yieldPos=oldYieldPos,this.awaitPos=oldAwaitPos,this.parseParenArrowList(startPos,startLoc,exprList,forInit);exprList.length&&!lastIsComma||this.unexpected(this.lastTokStart),spreadStart&&this.unexpected(spreadStart),this.checkExpressionErrors(refDestructuringErrors,!0),this.yieldPos=oldYieldPos||this.yieldPos,this.awaitPos=oldAwaitPos||this.awaitPos,exprList.length>1?((val=this.startNodeAt(innerStartPos,innerStartLoc)).expressions=exprList,this.finishNodeAt(val,\"SequenceExpression\",innerEndPos,innerEndLoc)):val=exprList[0]}else val=this.parseParenExpression();if(this.options.preserveParens){var par=this.startNodeAt(startPos,startLoc);return par.expression=val,this.finishNode(par,\"ParenthesizedExpression\")}return val},pp$5.parseParenItem=function(item){return item},pp$5.parseParenArrowList=function(startPos,startLoc,exprList,forInit){return this.parseArrowExpression(this.startNodeAt(startPos,startLoc),exprList,!1,forInit)};var empty=[];pp$5.parseNew=function(){this.containsEsc&&this.raiseRecoverable(this.start,\"Escape sequence in keyword new\");var node=this.startNode(),meta=this.parseIdent(!0);if(this.options.ecmaVersion>=6&&this.eat(types$1.dot)){node.meta=meta;var containsEsc=this.containsEsc;return node.property=this.parseIdent(!0),\"target\"!==node.property.name&&this.raiseRecoverable(node.property.start,\"The only valid meta property for new is 'new.target'\"),containsEsc&&this.raiseRecoverable(node.start,\"'new.target' must not contain escaped characters\"),this.allowNewDotTarget||this.raiseRecoverable(node.start,\"'new.target' can only be used in functions and class static block\"),this.finishNode(node,\"MetaProperty\")}var startPos=this.start,startLoc=this.startLoc,isImport=this.type===types$1._import;return node.callee=this.parseSubscripts(this.parseExprAtom(),startPos,startLoc,!0,!1),isImport&&\"ImportExpression\"===node.callee.type&&this.raise(startPos,\"Cannot use new with import()\"),this.eat(types$1.parenL)?node.arguments=this.parseExprList(types$1.parenR,this.options.ecmaVersion>=8,!1):node.arguments=empty,this.finishNode(node,\"NewExpression\")},pp$5.parseTemplateElement=function(ref){var isTagged=ref.isTagged,elem=this.startNode();return this.type===types$1.invalidTemplate?(isTagged||this.raiseRecoverable(this.start,\"Bad escape sequence in untagged template literal\"),elem.value={raw:this.value,cooked:null}):elem.value={raw:this.input.slice(this.start,this.end).replace(/\\r\\n?/g,\"\\n\"),cooked:this.value},this.next(),elem.tail=this.type===types$1.backQuote,this.finishNode(elem,\"TemplateElement\")},pp$5.parseTemplate=function(ref){void 0===ref&&(ref={});var isTagged=ref.isTagged;void 0===isTagged&&(isTagged=!1);var node=this.startNode();this.next(),node.expressions=[];var curElt=this.parseTemplateElement({isTagged});for(node.quasis=[curElt];!curElt.tail;)this.type===types$1.eof&&this.raise(this.pos,\"Unterminated template literal\"),this.expect(types$1.dollarBraceL),node.expressions.push(this.parseExpression()),this.expect(types$1.braceR),node.quasis.push(curElt=this.parseTemplateElement({isTagged}));return this.next(),this.finishNode(node,\"TemplateLiteral\")},pp$5.isAsyncProp=function(prop){return!prop.computed&&\"Identifier\"===prop.key.type&&\"async\"===prop.key.name&&(this.type===types$1.name||this.type===types$1.num||this.type===types$1.string||this.type===types$1.bracketL||this.type.keyword||this.options.ecmaVersion>=9&&this.type===types$1.star)&&!lineBreak.test(this.input.slice(this.lastTokEnd,this.start))},pp$5.parseObj=function(isPattern,refDestructuringErrors){var node=this.startNode(),first=!0,propHash={};for(node.properties=[],this.next();!this.eat(types$1.braceR);){if(first)first=!1;else if(this.expect(types$1.comma),this.options.ecmaVersion>=5&&this.afterTrailingComma(types$1.braceR))break;var prop=this.parseProperty(isPattern,refDestructuringErrors);isPattern||this.checkPropClash(prop,propHash,refDestructuringErrors),node.properties.push(prop)}return this.finishNode(node,isPattern?\"ObjectPattern\":\"ObjectExpression\")},pp$5.parseProperty=function(isPattern,refDestructuringErrors){var isGenerator,isAsync,startPos,startLoc,prop=this.startNode();if(this.options.ecmaVersion>=9&&this.eat(types$1.ellipsis))return isPattern?(prop.argument=this.parseIdent(!1),this.type===types$1.comma&&this.raise(this.start,\"Comma is not permitted after the rest element\"),this.finishNode(prop,\"RestElement\")):(prop.argument=this.parseMaybeAssign(!1,refDestructuringErrors),this.type===types$1.comma&&refDestructuringErrors&&refDestructuringErrors.trailingComma<0&&(refDestructuringErrors.trailingComma=this.start),this.finishNode(prop,\"SpreadElement\"));this.options.ecmaVersion>=6&&(prop.method=!1,prop.shorthand=!1,(isPattern||refDestructuringErrors)&&(startPos=this.start,startLoc=this.startLoc),isPattern||(isGenerator=this.eat(types$1.star)));var containsEsc=this.containsEsc;return this.parsePropertyName(prop),!isPattern&&!containsEsc&&this.options.ecmaVersion>=8&&!isGenerator&&this.isAsyncProp(prop)?(isAsync=!0,isGenerator=this.options.ecmaVersion>=9&&this.eat(types$1.star),this.parsePropertyName(prop,refDestructuringErrors)):isAsync=!1,this.parsePropertyValue(prop,isPattern,isGenerator,isAsync,startPos,startLoc,refDestructuringErrors,containsEsc),this.finishNode(prop,\"Property\")},pp$5.parsePropertyValue=function(prop,isPattern,isGenerator,isAsync,startPos,startLoc,refDestructuringErrors,containsEsc){if((isGenerator||isAsync)&&this.type===types$1.colon&&this.unexpected(),this.eat(types$1.colon))prop.value=isPattern?this.parseMaybeDefault(this.start,this.startLoc):this.parseMaybeAssign(!1,refDestructuringErrors),prop.kind=\"init\";else if(this.options.ecmaVersion>=6&&this.type===types$1.parenL)isPattern&&this.unexpected(),prop.kind=\"init\",prop.method=!0,prop.value=this.parseMethod(isGenerator,isAsync);else if(isPattern||containsEsc||!(this.options.ecmaVersion>=5)||prop.computed||\"Identifier\"!==prop.key.type||\"get\"!==prop.key.name&&\"set\"!==prop.key.name||this.type===types$1.comma||this.type===types$1.braceR||this.type===types$1.eq)this.options.ecmaVersion>=6&&!prop.computed&&\"Identifier\"===prop.key.type?((isGenerator||isAsync)&&this.unexpected(),this.checkUnreserved(prop.key),\"await\"!==prop.key.name||this.awaitIdentPos||(this.awaitIdentPos=startPos),prop.kind=\"init\",isPattern?prop.value=this.parseMaybeDefault(startPos,startLoc,this.copyNode(prop.key)):this.type===types$1.eq&&refDestructuringErrors?(refDestructuringErrors.shorthandAssign<0&&(refDestructuringErrors.shorthandAssign=this.start),prop.value=this.parseMaybeDefault(startPos,startLoc,this.copyNode(prop.key))):prop.value=this.copyNode(prop.key),prop.shorthand=!0):this.unexpected();else{(isGenerator||isAsync)&&this.unexpected(),prop.kind=prop.key.name,this.parsePropertyName(prop),prop.value=this.parseMethod(!1);var paramCount=\"get\"===prop.kind?0:1;if(prop.value.params.length!==paramCount){var start=prop.value.start;\"get\"===prop.kind?this.raiseRecoverable(start,\"getter should have no params\"):this.raiseRecoverable(start,\"setter should have exactly one param\")}else\"set\"===prop.kind&&\"RestElement\"===prop.value.params[0].type&&this.raiseRecoverable(prop.value.params[0].start,\"Setter cannot use rest params\")}},pp$5.parsePropertyName=function(prop){if(this.options.ecmaVersion>=6){if(this.eat(types$1.bracketL))return prop.computed=!0,prop.key=this.parseMaybeAssign(),this.expect(types$1.bracketR),prop.key;prop.computed=!1}return prop.key=this.type===types$1.num||this.type===types$1.string?this.parseExprAtom():this.parseIdent(\"never\"!==this.options.allowReserved)},pp$5.initFunction=function(node){node.id=null,this.options.ecmaVersion>=6&&(node.generator=node.expression=!1),this.options.ecmaVersion>=8&&(node.async=!1)},pp$5.parseMethod=function(isGenerator,isAsync,allowDirectSuper){var node=this.startNode(),oldYieldPos=this.yieldPos,oldAwaitPos=this.awaitPos,oldAwaitIdentPos=this.awaitIdentPos;return this.initFunction(node),this.options.ecmaVersion>=6&&(node.generator=isGenerator),this.options.ecmaVersion>=8&&(node.async=!!isAsync),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(64|functionFlags(isAsync,node.generator)|(allowDirectSuper?128:0)),this.expect(types$1.parenL),node.params=this.parseBindingList(types$1.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams(),this.parseFunctionBody(node,!1,!0,!1),this.yieldPos=oldYieldPos,this.awaitPos=oldAwaitPos,this.awaitIdentPos=oldAwaitIdentPos,this.finishNode(node,\"FunctionExpression\")},pp$5.parseArrowExpression=function(node,params,isAsync,forInit){var oldYieldPos=this.yieldPos,oldAwaitPos=this.awaitPos,oldAwaitIdentPos=this.awaitIdentPos;return this.enterScope(16|functionFlags(isAsync,!1)),this.initFunction(node),this.options.ecmaVersion>=8&&(node.async=!!isAsync),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,node.params=this.toAssignableList(params,!0),this.parseFunctionBody(node,!0,!1,forInit),this.yieldPos=oldYieldPos,this.awaitPos=oldAwaitPos,this.awaitIdentPos=oldAwaitIdentPos,this.finishNode(node,\"ArrowFunctionExpression\")},pp$5.parseFunctionBody=function(node,isArrowFunction,isMethod,forInit){var isExpression=isArrowFunction&&this.type!==types$1.braceL,oldStrict=this.strict,useStrict=!1;if(isExpression)node.body=this.parseMaybeAssign(forInit),node.expression=!0,this.checkParams(node,!1);else{var nonSimple=this.options.ecmaVersion>=7&&!this.isSimpleParamList(node.params);oldStrict&&!nonSimple||(useStrict=this.strictDirective(this.end))&&nonSimple&&this.raiseRecoverable(node.start,\"Illegal 'use strict' directive in function with non-simple parameter list\");var oldLabels=this.labels;this.labels=[],useStrict&&(this.strict=!0),this.checkParams(node,!oldStrict&&!useStrict&&!isArrowFunction&&!isMethod&&this.isSimpleParamList(node.params)),this.strict&&node.id&&this.checkLValSimple(node.id,5),node.body=this.parseBlock(!1,void 0,useStrict&&!oldStrict),node.expression=!1,this.adaptDirectivePrologue(node.body.body),this.labels=oldLabels}this.exitScope()},pp$5.isSimpleParamList=function(params){for(var i=0,list=params;i-1||scope.functions.indexOf(name)>-1||scope.var.indexOf(name)>-1,scope.lexical.push(name),this.inModule&&1&scope.flags&&delete this.undefinedExports[name]}else if(4===bindingType){this.currentScope().lexical.push(name)}else if(3===bindingType){var scope$2=this.currentScope();redeclared=this.treatFunctionsAsVar?scope$2.lexical.indexOf(name)>-1:scope$2.lexical.indexOf(name)>-1||scope$2.var.indexOf(name)>-1,scope$2.functions.push(name)}else for(var i=this.scopeStack.length-1;i>=0;--i){var scope$3=this.scopeStack[i];if(scope$3.lexical.indexOf(name)>-1&&!(32&scope$3.flags&&scope$3.lexical[0]===name)||!this.treatFunctionsAsVarInScope(scope$3)&&scope$3.functions.indexOf(name)>-1){redeclared=!0;break}if(scope$3.var.push(name),this.inModule&&1&scope$3.flags&&delete this.undefinedExports[name],259&scope$3.flags)break}redeclared&&this.raiseRecoverable(pos,\"Identifier '\"+name+\"' has already been declared\")},pp$3.checkLocalExport=function(id){-1===this.scopeStack[0].lexical.indexOf(id.name)&&-1===this.scopeStack[0].var.indexOf(id.name)&&(this.undefinedExports[id.name]=id)},pp$3.currentScope=function(){return this.scopeStack[this.scopeStack.length-1]},pp$3.currentVarScope=function(){for(var i=this.scopeStack.length-1;;i--){var scope=this.scopeStack[i];if(259&scope.flags)return scope}},pp$3.currentThisScope=function(){for(var i=this.scopeStack.length-1;;i--){var scope=this.scopeStack[i];if(259&scope.flags&&!(16&scope.flags))return scope}};var Node=function(parser,pos,loc){this.type=\"\",this.start=pos,this.end=0,parser.options.locations&&(this.loc=new SourceLocation(parser,loc)),parser.options.directSourceFile&&(this.sourceFile=parser.options.directSourceFile),parser.options.ranges&&(this.range=[pos,0])},pp$2=Parser.prototype;function finishNodeAt(node,type,pos,loc){return node.type=type,node.end=pos,this.options.locations&&(node.loc.end=loc),this.options.ranges&&(node.range[1]=pos),node}pp$2.startNode=function(){return new Node(this,this.start,this.startLoc)},pp$2.startNodeAt=function(pos,loc){return new Node(this,pos,loc)},pp$2.finishNode=function(node,type){return finishNodeAt.call(this,node,type,this.lastTokEnd,this.lastTokEndLoc)},pp$2.finishNodeAt=function(node,type,pos,loc){return finishNodeAt.call(this,node,type,pos,loc)},pp$2.copyNode=function(node){var newNode=new Node(this,node.start,this.startLoc);for(var prop in node)newNode[prop]=node[prop];return newNode};var ecma9BinaryProperties=\"ASCII ASCII_Hex_Digit AHex Alphabetic Alpha Any Assigned Bidi_Control Bidi_C Bidi_Mirrored Bidi_M Case_Ignorable CI Cased Changes_When_Casefolded CWCF Changes_When_Casemapped CWCM Changes_When_Lowercased CWL Changes_When_NFKC_Casefolded CWKCF Changes_When_Titlecased CWT Changes_When_Uppercased CWU Dash Default_Ignorable_Code_Point DI Deprecated Dep Diacritic Dia Emoji Emoji_Component Emoji_Modifier Emoji_Modifier_Base Emoji_Presentation Extender Ext Grapheme_Base Gr_Base Grapheme_Extend Gr_Ext Hex_Digit Hex IDS_Binary_Operator IDSB IDS_Trinary_Operator IDST ID_Continue IDC ID_Start IDS Ideographic Ideo Join_Control Join_C Logical_Order_Exception LOE Lowercase Lower Math Noncharacter_Code_Point NChar Pattern_Syntax Pat_Syn Pattern_White_Space Pat_WS Quotation_Mark QMark Radical Regional_Indicator RI Sentence_Terminal STerm Soft_Dotted SD Terminal_Punctuation Term Unified_Ideograph UIdeo Uppercase Upper Variation_Selector VS White_Space space XID_Continue XIDC XID_Start XIDS\",ecma10BinaryProperties=ecma9BinaryProperties+\" Extended_Pictographic\",ecma12BinaryProperties=ecma10BinaryProperties+\" EBase EComp EMod EPres ExtPict\",unicodeBinaryProperties={9:ecma9BinaryProperties,10:ecma10BinaryProperties,11:ecma10BinaryProperties,12:ecma12BinaryProperties,13:\"ASCII ASCII_Hex_Digit AHex Alphabetic Alpha Any Assigned Bidi_Control Bidi_C Bidi_Mirrored Bidi_M Case_Ignorable CI Cased Changes_When_Casefolded CWCF Changes_When_Casemapped CWCM Changes_When_Lowercased CWL Changes_When_NFKC_Casefolded CWKCF Changes_When_Titlecased CWT Changes_When_Uppercased CWU Dash Default_Ignorable_Code_Point DI Deprecated Dep Diacritic Dia Emoji Emoji_Component Emoji_Modifier Emoji_Modifier_Base Emoji_Presentation Extender Ext Grapheme_Base Gr_Base Grapheme_Extend Gr_Ext Hex_Digit Hex IDS_Binary_Operator IDSB IDS_Trinary_Operator IDST ID_Continue IDC ID_Start IDS Ideographic Ideo Join_Control Join_C Logical_Order_Exception LOE Lowercase Lower Math Noncharacter_Code_Point NChar Pattern_Syntax Pat_Syn Pattern_White_Space Pat_WS Quotation_Mark QMark Radical Regional_Indicator RI Sentence_Terminal STerm Soft_Dotted SD Terminal_Punctuation Term Unified_Ideograph UIdeo Uppercase Upper Variation_Selector VS White_Space space XID_Continue XIDC XID_Start XIDS Extended_Pictographic EBase EComp EMod EPres ExtPict\"},unicodeGeneralCategoryValues=\"Cased_Letter LC Close_Punctuation Pe Connector_Punctuation Pc Control Cc cntrl Currency_Symbol Sc Dash_Punctuation Pd Decimal_Number Nd digit Enclosing_Mark Me Final_Punctuation Pf Format Cf Initial_Punctuation Pi Letter L Letter_Number Nl Line_Separator Zl Lowercase_Letter Ll Mark M Combining_Mark Math_Symbol Sm Modifier_Letter Lm Modifier_Symbol Sk Nonspacing_Mark Mn Number N Open_Punctuation Ps Other C Other_Letter Lo Other_Number No Other_Punctuation Po Other_Symbol So Paragraph_Separator Zp Private_Use Co Punctuation P punct Separator Z Space_Separator Zs Spacing_Mark Mc Surrogate Cs Symbol S Titlecase_Letter Lt Unassigned Cn Uppercase_Letter Lu\",ecma9ScriptValues=\"Adlam Adlm Ahom Anatolian_Hieroglyphs Hluw Arabic Arab Armenian Armn Avestan Avst Balinese Bali Bamum Bamu Bassa_Vah Bass Batak Batk Bengali Beng Bhaiksuki Bhks Bopomofo Bopo Brahmi Brah Braille Brai Buginese Bugi Buhid Buhd Canadian_Aboriginal Cans Carian Cari Caucasian_Albanian Aghb Chakma Cakm Cham Cham Cherokee Cher Common Zyyy Coptic Copt Qaac Cuneiform Xsux Cypriot Cprt Cyrillic Cyrl Deseret Dsrt Devanagari Deva Duployan Dupl Egyptian_Hieroglyphs Egyp Elbasan Elba Ethiopic Ethi Georgian Geor Glagolitic Glag Gothic Goth Grantha Gran Greek Grek Gujarati Gujr Gurmukhi Guru Han Hani Hangul Hang Hanunoo Hano Hatran Hatr Hebrew Hebr Hiragana Hira Imperial_Aramaic Armi Inherited Zinh Qaai Inscriptional_Pahlavi Phli Inscriptional_Parthian Prti Javanese Java Kaithi Kthi Kannada Knda Katakana Kana Kayah_Li Kali Kharoshthi Khar Khmer Khmr Khojki Khoj Khudawadi Sind Lao Laoo Latin Latn Lepcha Lepc Limbu Limb Linear_A Lina Linear_B Linb Lisu Lisu Lycian Lyci Lydian Lydi Mahajani Mahj Malayalam Mlym Mandaic Mand Manichaean Mani Marchen Marc Masaram_Gondi Gonm Meetei_Mayek Mtei Mende_Kikakui Mend Meroitic_Cursive Merc Meroitic_Hieroglyphs Mero Miao Plrd Modi Mongolian Mong Mro Mroo Multani Mult Myanmar Mymr Nabataean Nbat New_Tai_Lue Talu Newa Newa Nko Nkoo Nushu Nshu Ogham Ogam Ol_Chiki Olck Old_Hungarian Hung Old_Italic Ital Old_North_Arabian Narb Old_Permic Perm Old_Persian Xpeo Old_South_Arabian Sarb Old_Turkic Orkh Oriya Orya Osage Osge Osmanya Osma Pahawh_Hmong Hmng Palmyrene Palm Pau_Cin_Hau Pauc Phags_Pa Phag Phoenician Phnx Psalter_Pahlavi Phlp Rejang Rjng Runic Runr Samaritan Samr Saurashtra Saur Sharada Shrd Shavian Shaw Siddham Sidd SignWriting Sgnw Sinhala Sinh Sora_Sompeng Sora Soyombo Soyo Sundanese Sund Syloti_Nagri Sylo Syriac Syrc Tagalog Tglg Tagbanwa Tagb Tai_Le Tale Tai_Tham Lana Tai_Viet Tavt Takri Takr Tamil Taml Tangut Tang Telugu Telu Thaana Thaa Thai Thai Tibetan Tibt Tifinagh Tfng Tirhuta Tirh Ugaritic Ugar Vai Vaii Warang_Citi Wara Yi Yiii Zanabazar_Square Zanb\",ecma10ScriptValues=ecma9ScriptValues+\" Dogra Dogr Gunjala_Gondi Gong Hanifi_Rohingya Rohg Makasar Maka Medefaidrin Medf Old_Sogdian Sogo Sogdian Sogd\",ecma11ScriptValues=ecma10ScriptValues+\" Elymaic Elym Nandinagari Nand Nyiakeng_Puachue_Hmong Hmnp Wancho Wcho\",ecma12ScriptValues=ecma11ScriptValues+\" Chorasmian Chrs Diak Dives_Akuru Khitan_Small_Script Kits Yezi Yezidi\",unicodeScriptValues={9:ecma9ScriptValues,10:ecma10ScriptValues,11:ecma11ScriptValues,12:ecma12ScriptValues,13:\"Adlam Adlm Ahom Anatolian_Hieroglyphs Hluw Arabic Arab Armenian Armn Avestan Avst Balinese Bali Bamum Bamu Bassa_Vah Bass Batak Batk Bengali Beng Bhaiksuki Bhks Bopomofo Bopo Brahmi Brah Braille Brai Buginese Bugi Buhid Buhd Canadian_Aboriginal Cans Carian Cari Caucasian_Albanian Aghb Chakma Cakm Cham Cham Cherokee Cher Common Zyyy Coptic Copt Qaac Cuneiform Xsux Cypriot Cprt Cyrillic Cyrl Deseret Dsrt Devanagari Deva Duployan Dupl Egyptian_Hieroglyphs Egyp Elbasan Elba Ethiopic Ethi Georgian Geor Glagolitic Glag Gothic Goth Grantha Gran Greek Grek Gujarati Gujr Gurmukhi Guru Han Hani Hangul Hang Hanunoo Hano Hatran Hatr Hebrew Hebr Hiragana Hira Imperial_Aramaic Armi Inherited Zinh Qaai Inscriptional_Pahlavi Phli Inscriptional_Parthian Prti Javanese Java Kaithi Kthi Kannada Knda Katakana Kana Kayah_Li Kali Kharoshthi Khar Khmer Khmr Khojki Khoj Khudawadi Sind Lao Laoo Latin Latn Lepcha Lepc Limbu Limb Linear_A Lina Linear_B Linb Lisu Lisu Lycian Lyci Lydian Lydi Mahajani Mahj Malayalam Mlym Mandaic Mand Manichaean Mani Marchen Marc Masaram_Gondi Gonm Meetei_Mayek Mtei Mende_Kikakui Mend Meroitic_Cursive Merc Meroitic_Hieroglyphs Mero Miao Plrd Modi Mongolian Mong Mro Mroo Multani Mult Myanmar Mymr Nabataean Nbat New_Tai_Lue Talu Newa Newa Nko Nkoo Nushu Nshu Ogham Ogam Ol_Chiki Olck Old_Hungarian Hung Old_Italic Ital Old_North_Arabian Narb Old_Permic Perm Old_Persian Xpeo Old_South_Arabian Sarb Old_Turkic Orkh Oriya Orya Osage Osge Osmanya Osma Pahawh_Hmong Hmng Palmyrene Palm Pau_Cin_Hau Pauc Phags_Pa Phag Phoenician Phnx Psalter_Pahlavi Phlp Rejang Rjng Runic Runr Samaritan Samr Saurashtra Saur Sharada Shrd Shavian Shaw Siddham Sidd SignWriting Sgnw Sinhala Sinh Sora_Sompeng Sora Soyombo Soyo Sundanese Sund Syloti_Nagri Sylo Syriac Syrc Tagalog Tglg Tagbanwa Tagb Tai_Le Tale Tai_Tham Lana Tai_Viet Tavt Takri Takr Tamil Taml Tangut Tang Telugu Telu Thaana Thaa Thai Thai Tibetan Tibt Tifinagh Tfng Tirhuta Tirh Ugaritic Ugar Vai Vaii Warang_Citi Wara Yi Yiii Zanabazar_Square Zanb Dogra Dogr Gunjala_Gondi Gong Hanifi_Rohingya Rohg Makasar Maka Medefaidrin Medf Old_Sogdian Sogo Sogdian Sogd Elymaic Elym Nandinagari Nand Nyiakeng_Puachue_Hmong Hmnp Wancho Wcho Chorasmian Chrs Diak Dives_Akuru Khitan_Small_Script Kits Yezi Yezidi Cypro_Minoan Cpmn Old_Uyghur Ougr Tangsa Tnsa Toto Vithkuqi Vith\"},data={};function buildUnicodeData(ecmaVersion){var d=data[ecmaVersion]={binary:wordsRegexp(unicodeBinaryProperties[ecmaVersion]+\" \"+unicodeGeneralCategoryValues),nonBinary:{General_Category:wordsRegexp(unicodeGeneralCategoryValues),Script:wordsRegexp(unicodeScriptValues[ecmaVersion])}};d.nonBinary.Script_Extensions=d.nonBinary.Script,d.nonBinary.gc=d.nonBinary.General_Category,d.nonBinary.sc=d.nonBinary.Script,d.nonBinary.scx=d.nonBinary.Script_Extensions}for(var i=0,list=[9,10,11,12,13];i=6?\"uy\":\"\")+(parser.options.ecmaVersion>=9?\"s\":\"\")+(parser.options.ecmaVersion>=13?\"d\":\"\"),this.unicodeProperties=data[parser.options.ecmaVersion>=13?13:parser.options.ecmaVersion],this.source=\"\",this.flags=\"\",this.start=0,this.switchU=!1,this.switchN=!1,this.pos=0,this.lastIntValue=0,this.lastStringValue=\"\",this.lastAssertionIsQuantifiable=!1,this.numCapturingParens=0,this.maxBackReference=0,this.groupNames=[],this.backReferenceNames=[]};function isSyntaxCharacter(ch){return 36===ch||ch>=40&&ch<=43||46===ch||63===ch||ch>=91&&ch<=94||ch>=123&&ch<=125}function isControlLetter(ch){return ch>=65&&ch<=90||ch>=97&&ch<=122}function isUnicodePropertyNameCharacter(ch){return isControlLetter(ch)||95===ch}function isUnicodePropertyValueCharacter(ch){return isUnicodePropertyNameCharacter(ch)||isDecimalDigit(ch)}function isDecimalDigit(ch){return ch>=48&&ch<=57}function isHexDigit(ch){return ch>=48&&ch<=57||ch>=65&&ch<=70||ch>=97&&ch<=102}function hexToInt(ch){return ch>=65&&ch<=70?ch-65+10:ch>=97&&ch<=102?ch-97+10:ch-48}function isOctalDigit(ch){return ch>=48&&ch<=55}RegExpValidationState.prototype.reset=function(start,pattern,flags){var unicode=-1!==flags.indexOf(\"u\");this.start=0|start,this.source=pattern+\"\",this.flags=flags,this.switchU=unicode&&this.parser.options.ecmaVersion>=6,this.switchN=unicode&&this.parser.options.ecmaVersion>=9},RegExpValidationState.prototype.raise=function(message){this.parser.raiseRecoverable(this.start,\"Invalid regular expression: /\"+this.source+\"/: \"+message)},RegExpValidationState.prototype.at=function(i,forceU){void 0===forceU&&(forceU=!1);var s=this.source,l=s.length;if(i>=l)return-1;var c=s.charCodeAt(i);if(!forceU&&!this.switchU||c<=55295||c>=57344||i+1>=l)return c;var next=s.charCodeAt(i+1);return next>=56320&&next<=57343?(c<<10)+next-56613888:c},RegExpValidationState.prototype.nextIndex=function(i,forceU){void 0===forceU&&(forceU=!1);var s=this.source,l=s.length;if(i>=l)return l;var next,c=s.charCodeAt(i);return!forceU&&!this.switchU||c<=55295||c>=57344||i+1>=l||(next=s.charCodeAt(i+1))<56320||next>57343?i+1:i+2},RegExpValidationState.prototype.current=function(forceU){return void 0===forceU&&(forceU=!1),this.at(this.pos,forceU)},RegExpValidationState.prototype.lookahead=function(forceU){return void 0===forceU&&(forceU=!1),this.at(this.nextIndex(this.pos,forceU),forceU)},RegExpValidationState.prototype.advance=function(forceU){void 0===forceU&&(forceU=!1),this.pos=this.nextIndex(this.pos,forceU)},RegExpValidationState.prototype.eat=function(ch,forceU){return void 0===forceU&&(forceU=!1),this.current(forceU)===ch&&(this.advance(forceU),!0)},pp$1.validateRegExpFlags=function(state){for(var validFlags=state.validFlags,flags=state.flags,i=0;i-1&&this.raise(state.start,\"Duplicate regular expression flag\")}},pp$1.validateRegExpPattern=function(state){this.regexp_pattern(state),!state.switchN&&this.options.ecmaVersion>=9&&state.groupNames.length>0&&(state.switchN=!0,this.regexp_pattern(state))},pp$1.regexp_pattern=function(state){state.pos=0,state.lastIntValue=0,state.lastStringValue=\"\",state.lastAssertionIsQuantifiable=!1,state.numCapturingParens=0,state.maxBackReference=0,state.groupNames.length=0,state.backReferenceNames.length=0,this.regexp_disjunction(state),state.pos!==state.source.length&&(state.eat(41)&&state.raise(\"Unmatched ')'\"),(state.eat(93)||state.eat(125))&&state.raise(\"Lone quantifier brackets\")),state.maxBackReference>state.numCapturingParens&&state.raise(\"Invalid escape\");for(var i=0,list=state.backReferenceNames;i=9&&(lookbehind=state.eat(60)),state.eat(61)||state.eat(33))return this.regexp_disjunction(state),state.eat(41)||state.raise(\"Unterminated group\"),state.lastAssertionIsQuantifiable=!lookbehind,!0}return state.pos=start,!1},pp$1.regexp_eatQuantifier=function(state,noError){return void 0===noError&&(noError=!1),!!this.regexp_eatQuantifierPrefix(state,noError)&&(state.eat(63),!0)},pp$1.regexp_eatQuantifierPrefix=function(state,noError){return state.eat(42)||state.eat(43)||state.eat(63)||this.regexp_eatBracedQuantifier(state,noError)},pp$1.regexp_eatBracedQuantifier=function(state,noError){var start=state.pos;if(state.eat(123)){var min=0,max=-1;if(this.regexp_eatDecimalDigits(state)&&(min=state.lastIntValue,state.eat(44)&&this.regexp_eatDecimalDigits(state)&&(max=state.lastIntValue),state.eat(125)))return-1!==max&&max=9?this.regexp_groupSpecifier(state):63===state.current()&&state.raise(\"Invalid group\"),this.regexp_disjunction(state),state.eat(41))return state.numCapturingParens+=1,!0;state.raise(\"Unterminated group\")}return!1},pp$1.regexp_eatExtendedAtom=function(state){return state.eat(46)||this.regexp_eatReverseSolidusAtomEscape(state)||this.regexp_eatCharacterClass(state)||this.regexp_eatUncapturingGroup(state)||this.regexp_eatCapturingGroup(state)||this.regexp_eatInvalidBracedQuantifier(state)||this.regexp_eatExtendedPatternCharacter(state)},pp$1.regexp_eatInvalidBracedQuantifier=function(state){return this.regexp_eatBracedQuantifier(state,!0)&&state.raise(\"Nothing to repeat\"),!1},pp$1.regexp_eatSyntaxCharacter=function(state){var ch=state.current();return!!isSyntaxCharacter(ch)&&(state.lastIntValue=ch,state.advance(),!0)},pp$1.regexp_eatPatternCharacters=function(state){for(var start=state.pos,ch=0;-1!==(ch=state.current())&&!isSyntaxCharacter(ch);)state.advance();return state.pos!==start},pp$1.regexp_eatExtendedPatternCharacter=function(state){var ch=state.current();return!(-1===ch||36===ch||ch>=40&&ch<=43||46===ch||63===ch||91===ch||94===ch||124===ch)&&(state.advance(),!0)},pp$1.regexp_groupSpecifier=function(state){if(state.eat(63)){if(this.regexp_eatGroupName(state))return-1!==state.groupNames.indexOf(state.lastStringValue)&&state.raise(\"Duplicate capture group name\"),void state.groupNames.push(state.lastStringValue);state.raise(\"Invalid group\")}},pp$1.regexp_eatGroupName=function(state){if(state.lastStringValue=\"\",state.eat(60)){if(this.regexp_eatRegExpIdentifierName(state)&&state.eat(62))return!0;state.raise(\"Invalid capture group name\")}return!1},pp$1.regexp_eatRegExpIdentifierName=function(state){if(state.lastStringValue=\"\",this.regexp_eatRegExpIdentifierStart(state)){for(state.lastStringValue+=codePointToString(state.lastIntValue);this.regexp_eatRegExpIdentifierPart(state);)state.lastStringValue+=codePointToString(state.lastIntValue);return!0}return!1},pp$1.regexp_eatRegExpIdentifierStart=function(state){var start=state.pos,forceU=this.options.ecmaVersion>=11,ch=state.current(forceU);return state.advance(forceU),92===ch&&this.regexp_eatRegExpUnicodeEscapeSequence(state,forceU)&&(ch=state.lastIntValue),function(ch){return isIdentifierStart(ch,!0)||36===ch||95===ch}(ch)?(state.lastIntValue=ch,!0):(state.pos=start,!1)},pp$1.regexp_eatRegExpIdentifierPart=function(state){var start=state.pos,forceU=this.options.ecmaVersion>=11,ch=state.current(forceU);return state.advance(forceU),92===ch&&this.regexp_eatRegExpUnicodeEscapeSequence(state,forceU)&&(ch=state.lastIntValue),function(ch){return isIdentifierChar(ch,!0)||36===ch||95===ch||8204===ch||8205===ch}(ch)?(state.lastIntValue=ch,!0):(state.pos=start,!1)},pp$1.regexp_eatAtomEscape=function(state){return!!(this.regexp_eatBackReference(state)||this.regexp_eatCharacterClassEscape(state)||this.regexp_eatCharacterEscape(state)||state.switchN&&this.regexp_eatKGroupName(state))||(state.switchU&&(99===state.current()&&state.raise(\"Invalid unicode escape\"),state.raise(\"Invalid escape\")),!1)},pp$1.regexp_eatBackReference=function(state){var start=state.pos;if(this.regexp_eatDecimalEscape(state)){var n=state.lastIntValue;if(state.switchU)return n>state.maxBackReference&&(state.maxBackReference=n),!0;if(n<=state.numCapturingParens)return!0;state.pos=start}return!1},pp$1.regexp_eatKGroupName=function(state){if(state.eat(107)){if(this.regexp_eatGroupName(state))return state.backReferenceNames.push(state.lastStringValue),!0;state.raise(\"Invalid named reference\")}return!1},pp$1.regexp_eatCharacterEscape=function(state){return this.regexp_eatControlEscape(state)||this.regexp_eatCControlLetter(state)||this.regexp_eatZero(state)||this.regexp_eatHexEscapeSequence(state)||this.regexp_eatRegExpUnicodeEscapeSequence(state,!1)||!state.switchU&&this.regexp_eatLegacyOctalEscapeSequence(state)||this.regexp_eatIdentityEscape(state)},pp$1.regexp_eatCControlLetter=function(state){var start=state.pos;if(state.eat(99)){if(this.regexp_eatControlLetter(state))return!0;state.pos=start}return!1},pp$1.regexp_eatZero=function(state){return 48===state.current()&&!isDecimalDigit(state.lookahead())&&(state.lastIntValue=0,state.advance(),!0)},pp$1.regexp_eatControlEscape=function(state){var ch=state.current();return 116===ch?(state.lastIntValue=9,state.advance(),!0):110===ch?(state.lastIntValue=10,state.advance(),!0):118===ch?(state.lastIntValue=11,state.advance(),!0):102===ch?(state.lastIntValue=12,state.advance(),!0):114===ch&&(state.lastIntValue=13,state.advance(),!0)},pp$1.regexp_eatControlLetter=function(state){var ch=state.current();return!!isControlLetter(ch)&&(state.lastIntValue=ch%32,state.advance(),!0)},pp$1.regexp_eatRegExpUnicodeEscapeSequence=function(state,forceU){void 0===forceU&&(forceU=!1);var ch,start=state.pos,switchU=forceU||state.switchU;if(state.eat(117)){if(this.regexp_eatFixedHexDigits(state,4)){var lead=state.lastIntValue;if(switchU&&lead>=55296&&lead<=56319){var leadSurrogateEnd=state.pos;if(state.eat(92)&&state.eat(117)&&this.regexp_eatFixedHexDigits(state,4)){var trail=state.lastIntValue;if(trail>=56320&&trail<=57343)return state.lastIntValue=1024*(lead-55296)+(trail-56320)+65536,!0}state.pos=leadSurrogateEnd,state.lastIntValue=lead}return!0}if(switchU&&state.eat(123)&&this.regexp_eatHexDigits(state)&&state.eat(125)&&((ch=state.lastIntValue)>=0&&ch<=1114111))return!0;switchU&&state.raise(\"Invalid unicode escape\"),state.pos=start}return!1},pp$1.regexp_eatIdentityEscape=function(state){if(state.switchU)return!!this.regexp_eatSyntaxCharacter(state)||!!state.eat(47)&&(state.lastIntValue=47,!0);var ch=state.current();return!(99===ch||state.switchN&&107===ch)&&(state.lastIntValue=ch,state.advance(),!0)},pp$1.regexp_eatDecimalEscape=function(state){state.lastIntValue=0;var ch=state.current();if(ch>=49&&ch<=57){do{state.lastIntValue=10*state.lastIntValue+(ch-48),state.advance()}while((ch=state.current())>=48&&ch<=57);return!0}return!1},pp$1.regexp_eatCharacterClassEscape=function(state){var ch=state.current();if(function(ch){return 100===ch||68===ch||115===ch||83===ch||119===ch||87===ch}(ch))return state.lastIntValue=-1,state.advance(),!0;if(state.switchU&&this.options.ecmaVersion>=9&&(80===ch||112===ch)){if(state.lastIntValue=-1,state.advance(),state.eat(123)&&this.regexp_eatUnicodePropertyValueExpression(state)&&state.eat(125))return!0;state.raise(\"Invalid property name\")}return!1},pp$1.regexp_eatUnicodePropertyValueExpression=function(state){var start=state.pos;if(this.regexp_eatUnicodePropertyName(state)&&state.eat(61)){var name=state.lastStringValue;if(this.regexp_eatUnicodePropertyValue(state)){var value=state.lastStringValue;return this.regexp_validateUnicodePropertyNameAndValue(state,name,value),!0}}if(state.pos=start,this.regexp_eatLoneUnicodePropertyNameOrValue(state)){var nameOrValue=state.lastStringValue;return this.regexp_validateUnicodePropertyNameOrValue(state,nameOrValue),!0}return!1},pp$1.regexp_validateUnicodePropertyNameAndValue=function(state,name,value){hasOwn(state.unicodeProperties.nonBinary,name)||state.raise(\"Invalid property name\"),state.unicodeProperties.nonBinary[name].test(value)||state.raise(\"Invalid property value\")},pp$1.regexp_validateUnicodePropertyNameOrValue=function(state,nameOrValue){state.unicodeProperties.binary.test(nameOrValue)||state.raise(\"Invalid property name\")},pp$1.regexp_eatUnicodePropertyName=function(state){var ch=0;for(state.lastStringValue=\"\";isUnicodePropertyNameCharacter(ch=state.current());)state.lastStringValue+=codePointToString(ch),state.advance();return\"\"!==state.lastStringValue},pp$1.regexp_eatUnicodePropertyValue=function(state){var ch=0;for(state.lastStringValue=\"\";isUnicodePropertyValueCharacter(ch=state.current());)state.lastStringValue+=codePointToString(ch),state.advance();return\"\"!==state.lastStringValue},pp$1.regexp_eatLoneUnicodePropertyNameOrValue=function(state){return this.regexp_eatUnicodePropertyValue(state)},pp$1.regexp_eatCharacterClass=function(state){if(state.eat(91)){if(state.eat(94),this.regexp_classRanges(state),state.eat(93))return!0;state.raise(\"Unterminated character class\")}return!1},pp$1.regexp_classRanges=function(state){for(;this.regexp_eatClassAtom(state);){var left=state.lastIntValue;if(state.eat(45)&&this.regexp_eatClassAtom(state)){var right=state.lastIntValue;!state.switchU||-1!==left&&-1!==right||state.raise(\"Invalid character class\"),-1!==left&&-1!==right&&left>right&&state.raise(\"Range out of order in character class\")}}},pp$1.regexp_eatClassAtom=function(state){var start=state.pos;if(state.eat(92)){if(this.regexp_eatClassEscape(state))return!0;if(state.switchU){var ch$1=state.current();(99===ch$1||isOctalDigit(ch$1))&&state.raise(\"Invalid class escape\"),state.raise(\"Invalid escape\")}state.pos=start}var ch=state.current();return 93!==ch&&(state.lastIntValue=ch,state.advance(),!0)},pp$1.regexp_eatClassEscape=function(state){var start=state.pos;if(state.eat(98))return state.lastIntValue=8,!0;if(state.switchU&&state.eat(45))return state.lastIntValue=45,!0;if(!state.switchU&&state.eat(99)){if(this.regexp_eatClassControlLetter(state))return!0;state.pos=start}return this.regexp_eatCharacterClassEscape(state)||this.regexp_eatCharacterEscape(state)},pp$1.regexp_eatClassControlLetter=function(state){var ch=state.current();return!(!isDecimalDigit(ch)&&95!==ch)&&(state.lastIntValue=ch%32,state.advance(),!0)},pp$1.regexp_eatHexEscapeSequence=function(state){var start=state.pos;if(state.eat(120)){if(this.regexp_eatFixedHexDigits(state,2))return!0;state.switchU&&state.raise(\"Invalid escape\"),state.pos=start}return!1},pp$1.regexp_eatDecimalDigits=function(state){var start=state.pos,ch=0;for(state.lastIntValue=0;isDecimalDigit(ch=state.current());)state.lastIntValue=10*state.lastIntValue+(ch-48),state.advance();return state.pos!==start},pp$1.regexp_eatHexDigits=function(state){var start=state.pos,ch=0;for(state.lastIntValue=0;isHexDigit(ch=state.current());)state.lastIntValue=16*state.lastIntValue+hexToInt(ch),state.advance();return state.pos!==start},pp$1.regexp_eatLegacyOctalEscapeSequence=function(state){if(this.regexp_eatOctalDigit(state)){var n1=state.lastIntValue;if(this.regexp_eatOctalDigit(state)){var n2=state.lastIntValue;n1<=3&&this.regexp_eatOctalDigit(state)?state.lastIntValue=64*n1+8*n2+state.lastIntValue:state.lastIntValue=8*n1+n2}else state.lastIntValue=n1;return!0}return!1},pp$1.regexp_eatOctalDigit=function(state){var ch=state.current();return isOctalDigit(ch)?(state.lastIntValue=ch-48,state.advance(),!0):(state.lastIntValue=0,!1)},pp$1.regexp_eatFixedHexDigits=function(state,length){var start=state.pos;state.lastIntValue=0;for(var i=0;i=this.input.length?this.finishToken(types$1.eof):curContext.override?curContext.override(this):void this.readToken(this.fullCharCodeAtPos())},pp.readToken=function(code){return isIdentifierStart(code,this.options.ecmaVersion>=6)||92===code?this.readWord():this.getTokenFromCode(code)},pp.fullCharCodeAtPos=function(){var code=this.input.charCodeAt(this.pos);if(code<=55295||code>=56320)return code;var next=this.input.charCodeAt(this.pos+1);return next<=56319||next>=57344?code:(code<<10)+next-56613888},pp.skipBlockComment=function(){var startLoc=this.options.onComment&&this.curPosition(),start=this.pos,end=this.input.indexOf(\"*/\",this.pos+=2);if(-1===end&&this.raise(this.pos-2,\"Unterminated comment\"),this.pos=end+2,this.options.locations)for(var nextBreak=void 0,pos=start;(nextBreak=nextLineBreak(this.input,pos,this.pos))>-1;)++this.curLine,pos=this.lineStart=nextBreak;this.options.onComment&&this.options.onComment(!0,this.input.slice(start+2,end),start,this.pos,startLoc,this.curPosition())},pp.skipLineComment=function(startSkip){for(var start=this.pos,startLoc=this.options.onComment&&this.curPosition(),ch=this.input.charCodeAt(this.pos+=startSkip);this.pos8&&ch<14||ch>=5760&&nonASCIIwhitespace.test(String.fromCharCode(ch))))break loop;++this.pos}}},pp.finishToken=function(type,val){this.end=this.pos,this.options.locations&&(this.endLoc=this.curPosition());var prevType=this.type;this.type=type,this.value=val,this.updateContext(prevType)},pp.readToken_dot=function(){var next=this.input.charCodeAt(this.pos+1);if(next>=48&&next<=57)return this.readNumber(!0);var next2=this.input.charCodeAt(this.pos+2);return this.options.ecmaVersion>=6&&46===next&&46===next2?(this.pos+=3,this.finishToken(types$1.ellipsis)):(++this.pos,this.finishToken(types$1.dot))},pp.readToken_slash=function(){var next=this.input.charCodeAt(this.pos+1);return this.exprAllowed?(++this.pos,this.readRegexp()):61===next?this.finishOp(types$1.assign,2):this.finishOp(types$1.slash,1)},pp.readToken_mult_modulo_exp=function(code){var next=this.input.charCodeAt(this.pos+1),size=1,tokentype=42===code?types$1.star:types$1.modulo;return this.options.ecmaVersion>=7&&42===code&&42===next&&(++size,tokentype=types$1.starstar,next=this.input.charCodeAt(this.pos+2)),61===next?this.finishOp(types$1.assign,size+1):this.finishOp(tokentype,size)},pp.readToken_pipe_amp=function(code){var next=this.input.charCodeAt(this.pos+1);if(next===code){if(this.options.ecmaVersion>=12)if(61===this.input.charCodeAt(this.pos+2))return this.finishOp(types$1.assign,3);return this.finishOp(124===code?types$1.logicalOR:types$1.logicalAND,2)}return 61===next?this.finishOp(types$1.assign,2):this.finishOp(124===code?types$1.bitwiseOR:types$1.bitwiseAND,1)},pp.readToken_caret=function(){return 61===this.input.charCodeAt(this.pos+1)?this.finishOp(types$1.assign,2):this.finishOp(types$1.bitwiseXOR,1)},pp.readToken_plus_min=function(code){var next=this.input.charCodeAt(this.pos+1);return next===code?45!==next||this.inModule||62!==this.input.charCodeAt(this.pos+2)||0!==this.lastTokEnd&&!lineBreak.test(this.input.slice(this.lastTokEnd,this.pos))?this.finishOp(types$1.incDec,2):(this.skipLineComment(3),this.skipSpace(),this.nextToken()):61===next?this.finishOp(types$1.assign,2):this.finishOp(types$1.plusMin,1)},pp.readToken_lt_gt=function(code){var next=this.input.charCodeAt(this.pos+1),size=1;return next===code?(size=62===code&&62===this.input.charCodeAt(this.pos+2)?3:2,61===this.input.charCodeAt(this.pos+size)?this.finishOp(types$1.assign,size+1):this.finishOp(types$1.bitShift,size)):33!==next||60!==code||this.inModule||45!==this.input.charCodeAt(this.pos+2)||45!==this.input.charCodeAt(this.pos+3)?(61===next&&(size=2),this.finishOp(types$1.relational,size)):(this.skipLineComment(4),this.skipSpace(),this.nextToken())},pp.readToken_eq_excl=function(code){var next=this.input.charCodeAt(this.pos+1);return 61===next?this.finishOp(types$1.equality,61===this.input.charCodeAt(this.pos+2)?3:2):61===code&&62===next&&this.options.ecmaVersion>=6?(this.pos+=2,this.finishToken(types$1.arrow)):this.finishOp(61===code?types$1.eq:types$1.prefix,1)},pp.readToken_question=function(){var ecmaVersion=this.options.ecmaVersion;if(ecmaVersion>=11){var next=this.input.charCodeAt(this.pos+1);if(46===next){var next2=this.input.charCodeAt(this.pos+2);if(next2<48||next2>57)return this.finishOp(types$1.questionDot,2)}if(63===next){if(ecmaVersion>=12)if(61===this.input.charCodeAt(this.pos+2))return this.finishOp(types$1.assign,3);return this.finishOp(types$1.coalesce,2)}}return this.finishOp(types$1.question,1)},pp.readToken_numberSign=function(){var code=35;if(this.options.ecmaVersion>=13&&(++this.pos,isIdentifierStart(code=this.fullCharCodeAtPos(),!0)||92===code))return this.finishToken(types$1.privateId,this.readWord1());this.raise(this.pos,\"Unexpected character '\"+codePointToString(code)+\"'\")},pp.getTokenFromCode=function(code){switch(code){case 46:return this.readToken_dot();case 40:return++this.pos,this.finishToken(types$1.parenL);case 41:return++this.pos,this.finishToken(types$1.parenR);case 59:return++this.pos,this.finishToken(types$1.semi);case 44:return++this.pos,this.finishToken(types$1.comma);case 91:return++this.pos,this.finishToken(types$1.bracketL);case 93:return++this.pos,this.finishToken(types$1.bracketR);case 123:return++this.pos,this.finishToken(types$1.braceL);case 125:return++this.pos,this.finishToken(types$1.braceR);case 58:return++this.pos,this.finishToken(types$1.colon);case 96:if(this.options.ecmaVersion<6)break;return++this.pos,this.finishToken(types$1.backQuote);case 48:var next=this.input.charCodeAt(this.pos+1);if(120===next||88===next)return this.readRadixNumber(16);if(this.options.ecmaVersion>=6){if(111===next||79===next)return this.readRadixNumber(8);if(98===next||66===next)return this.readRadixNumber(2)}case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return this.readNumber(!1);case 34:case 39:return this.readString(code);case 47:return this.readToken_slash();case 37:case 42:return this.readToken_mult_modulo_exp(code);case 124:case 38:return this.readToken_pipe_amp(code);case 94:return this.readToken_caret();case 43:case 45:return this.readToken_plus_min(code);case 60:case 62:return this.readToken_lt_gt(code);case 61:case 33:return this.readToken_eq_excl(code);case 63:return this.readToken_question();case 126:return this.finishOp(types$1.prefix,1);case 35:return this.readToken_numberSign()}this.raise(this.pos,\"Unexpected character '\"+codePointToString(code)+\"'\")},pp.finishOp=function(type,size){var str=this.input.slice(this.pos,this.pos+size);return this.pos+=size,this.finishToken(type,str)},pp.readRegexp=function(){for(var escaped,inClass,start=this.pos;;){this.pos>=this.input.length&&this.raise(start,\"Unterminated regular expression\");var ch=this.input.charAt(this.pos);if(lineBreak.test(ch)&&this.raise(start,\"Unterminated regular expression\"),escaped)escaped=!1;else{if(\"[\"===ch)inClass=!0;else if(\"]\"===ch&&inClass)inClass=!1;else if(\"/\"===ch&&!inClass)break;escaped=\"\\\\\"===ch}++this.pos}var pattern=this.input.slice(start,this.pos);++this.pos;var flagsStart=this.pos,flags=this.readWord1();this.containsEsc&&this.unexpected(flagsStart);var state=this.regexpState||(this.regexpState=new RegExpValidationState(this));state.reset(start,pattern,flags),this.validateRegExpFlags(state),this.validateRegExpPattern(state);var value=null;try{value=new RegExp(pattern,flags)}catch(e){}return this.finishToken(types$1.regexp,{pattern,flags,value})},pp.readInt=function(radix,len,maybeLegacyOctalNumericLiteral){for(var allowSeparators=this.options.ecmaVersion>=12&&void 0===len,isLegacyOctalNumericLiteral=maybeLegacyOctalNumericLiteral&&48===this.input.charCodeAt(this.pos),start=this.pos,total=0,lastCode=0,i=0,e=null==len?1/0:len;i=97?code-97+10:code>=65?code-65+10:code>=48&&code<=57?code-48:1/0)>=radix)break;lastCode=code,total=total*radix+val}}return allowSeparators&&95===lastCode&&this.raiseRecoverable(this.pos-1,\"Numeric separator is not allowed at the last of digits\"),this.pos===start||null!=len&&this.pos-start!==len?null:total},pp.readRadixNumber=function(radix){var start=this.pos;this.pos+=2;var val=this.readInt(radix);return null==val&&this.raise(this.start+2,\"Expected number in radix \"+radix),this.options.ecmaVersion>=11&&110===this.input.charCodeAt(this.pos)?(val=stringToBigInt(this.input.slice(start,this.pos)),++this.pos):isIdentifierStart(this.fullCharCodeAtPos())&&this.raise(this.pos,\"Identifier directly after number\"),this.finishToken(types$1.num,val)},pp.readNumber=function(startsWithDot){var start=this.pos;startsWithDot||null!==this.readInt(10,void 0,!0)||this.raise(start,\"Invalid number\");var octal=this.pos-start>=2&&48===this.input.charCodeAt(start);octal&&this.strict&&this.raise(start,\"Invalid number\");var next=this.input.charCodeAt(this.pos);if(!octal&&!startsWithDot&&this.options.ecmaVersion>=11&&110===next){var val$1=stringToBigInt(this.input.slice(start,this.pos));return++this.pos,isIdentifierStart(this.fullCharCodeAtPos())&&this.raise(this.pos,\"Identifier directly after number\"),this.finishToken(types$1.num,val$1)}octal&&/[89]/.test(this.input.slice(start,this.pos))&&(octal=!1),46!==next||octal||(++this.pos,this.readInt(10),next=this.input.charCodeAt(this.pos)),69!==next&&101!==next||octal||(43!==(next=this.input.charCodeAt(++this.pos))&&45!==next||++this.pos,null===this.readInt(10)&&this.raise(start,\"Invalid number\")),isIdentifierStart(this.fullCharCodeAtPos())&&this.raise(this.pos,\"Identifier directly after number\");var str,val=(str=this.input.slice(start,this.pos),octal?parseInt(str,8):parseFloat(str.replace(/_/g,\"\")));return this.finishToken(types$1.num,val)},pp.readCodePoint=function(){var code;if(123===this.input.charCodeAt(this.pos)){this.options.ecmaVersion<6&&this.unexpected();var codePos=++this.pos;code=this.readHexChar(this.input.indexOf(\"}\",this.pos)-this.pos),++this.pos,code>1114111&&this.invalidStringToken(codePos,\"Code point out of bounds\")}else code=this.readHexChar(4);return code},pp.readString=function(quote){for(var out=\"\",chunkStart=++this.pos;;){this.pos>=this.input.length&&this.raise(this.start,\"Unterminated string constant\");var ch=this.input.charCodeAt(this.pos);if(ch===quote)break;92===ch?(out+=this.input.slice(chunkStart,this.pos),out+=this.readEscapedChar(!1),chunkStart=this.pos):8232===ch||8233===ch?(this.options.ecmaVersion<10&&this.raise(this.start,\"Unterminated string constant\"),++this.pos,this.options.locations&&(this.curLine++,this.lineStart=this.pos)):(isNewLine(ch)&&this.raise(this.start,\"Unterminated string constant\"),++this.pos)}return out+=this.input.slice(chunkStart,this.pos++),this.finishToken(types$1.string,out)};var INVALID_TEMPLATE_ESCAPE_ERROR={};pp.tryReadTemplateToken=function(){this.inTemplateElement=!0;try{this.readTmplToken()}catch(err){if(err!==INVALID_TEMPLATE_ESCAPE_ERROR)throw err;this.readInvalidTemplateToken()}this.inTemplateElement=!1},pp.invalidStringToken=function(position,message){if(this.inTemplateElement&&this.options.ecmaVersion>=9)throw INVALID_TEMPLATE_ESCAPE_ERROR;this.raise(position,message)},pp.readTmplToken=function(){for(var out=\"\",chunkStart=this.pos;;){this.pos>=this.input.length&&this.raise(this.start,\"Unterminated template\");var ch=this.input.charCodeAt(this.pos);if(96===ch||36===ch&&123===this.input.charCodeAt(this.pos+1))return this.pos!==this.start||this.type!==types$1.template&&this.type!==types$1.invalidTemplate?(out+=this.input.slice(chunkStart,this.pos),this.finishToken(types$1.template,out)):36===ch?(this.pos+=2,this.finishToken(types$1.dollarBraceL)):(++this.pos,this.finishToken(types$1.backQuote));if(92===ch)out+=this.input.slice(chunkStart,this.pos),out+=this.readEscapedChar(!0),chunkStart=this.pos;else if(isNewLine(ch)){switch(out+=this.input.slice(chunkStart,this.pos),++this.pos,ch){case 13:10===this.input.charCodeAt(this.pos)&&++this.pos;case 10:out+=\"\\n\";break;default:out+=String.fromCharCode(ch)}this.options.locations&&(++this.curLine,this.lineStart=this.pos),chunkStart=this.pos}else++this.pos}},pp.readInvalidTemplateToken=function(){for(;this.pos=48&&ch<=55){var octalStr=this.input.substr(this.pos-1,3).match(/^[0-7]+/)[0],octal=parseInt(octalStr,8);return octal>255&&(octalStr=octalStr.slice(0,-1),octal=parseInt(octalStr,8)),this.pos+=octalStr.length-1,ch=this.input.charCodeAt(this.pos),\"0\"===octalStr&&56!==ch&&57!==ch||!this.strict&&!inTemplate||this.invalidStringToken(this.pos-1-octalStr.length,inTemplate?\"Octal literal in template string\":\"Octal literal in strict mode\"),String.fromCharCode(octal)}return isNewLine(ch)?\"\":String.fromCharCode(ch)}},pp.readHexChar=function(len){var codePos=this.pos,n=this.readInt(16,len);return null===n&&this.invalidStringToken(codePos,\"Bad character escape sequence\"),n},pp.readWord1=function(){this.containsEsc=!1;for(var word=\"\",first=!0,chunkStart=this.pos,astral=this.options.ecmaVersion>=6;this.pos`Invalid module \"${request}\" ${reason}${base?` imported from ${base}`:\"\"}`),TypeError),codes.ERR_INVALID_PACKAGE_CONFIG=createError(\"ERR_INVALID_PACKAGE_CONFIG\",((path,base,message)=>`Invalid package config ${path}${base?` while importing ${base}`:\"\"}${message?`. ${message}`:\"\"}`),Error),codes.ERR_INVALID_PACKAGE_TARGET=createError(\"ERR_INVALID_PACKAGE_TARGET\",((pkgPath,key,target,isImport=!1,base)=>{const relError=\"string\"==typeof target&&!isImport&&target.length>0&&!target.startsWith(\"./\");return\".\"===key?(external_assert_namespaceObject(!1===isImport),`Invalid \"exports\" main target ${JSON.stringify(target)} defined in the package config ${pkgPath}package.json${base?` imported from ${base}`:\"\"}${relError?'; targets must start with \"./\"':\"\"}`):`Invalid \"${isImport?\"imports\":\"exports\"}\" target ${JSON.stringify(target)} defined for '${key}' in the package config ${pkgPath}package.json${base?` imported from ${base}`:\"\"}${relError?'; targets must start with \"./\"':\"\"}`}),Error),codes.ERR_MODULE_NOT_FOUND=createError(\"ERR_MODULE_NOT_FOUND\",((path,base,type=\"package\")=>`Cannot find ${type} '${path}' imported from ${base}`),Error),codes.ERR_PACKAGE_IMPORT_NOT_DEFINED=createError(\"ERR_PACKAGE_IMPORT_NOT_DEFINED\",((specifier,packagePath,base)=>`Package import specifier \"${specifier}\" is not defined${packagePath?` in package ${packagePath}package.json`:\"\"} imported from ${base}`),TypeError),codes.ERR_PACKAGE_PATH_NOT_EXPORTED=createError(\"ERR_PACKAGE_PATH_NOT_EXPORTED\",((pkgPath,subpath,base)=>\".\"===subpath?`No \"exports\" main defined in ${pkgPath}package.json${base?` imported from ${base}`:\"\"}`:`Package subpath '${subpath}' is not defined by \"exports\" in ${pkgPath}package.json${base?` imported from ${base}`:\"\"}`),Error),codes.ERR_UNSUPPORTED_DIR_IMPORT=createError(\"ERR_UNSUPPORTED_DIR_IMPORT\",\"Directory import '%s' is not supported resolving ES modules imported from %s\",Error),codes.ERR_UNKNOWN_FILE_EXTENSION=createError(\"ERR_UNKNOWN_FILE_EXTENSION\",'Unknown file extension \"%s\" for %s',TypeError),codes.ERR_INVALID_ARG_VALUE=createError(\"ERR_INVALID_ARG_VALUE\",((name,value,reason=\"is invalid\")=>{let inspected=(0,external_util_.inspect)(value);inspected.length>128&&(inspected=`${inspected.slice(0,128)}...`);return`The ${name.includes(\".\")?\"property\":\"argument\"} '${name}' ${reason}. Received ${inspected}`}),TypeError),codes.ERR_UNSUPPORTED_ESM_URL_SCHEME=createError(\"ERR_UNSUPPORTED_ESM_URL_SCHEME\",(url=>{let message=\"Only file and data URLs are supported by the default ESM loader\";return isWindows&&2===url.protocol.length&&(message+=\". On Windows, absolute paths must be valid file:// URLs\"),message+=`. Received protocol '${url.protocol}'`,message}),Error);const addCodeToName=hideStackFrames((function(error,name,code){(error=captureLargerStackTrace(error)).name=`${name} [${code}]`,error.stack,\"SystemError\"===name?Object.defineProperty(error,\"name\",{value:name,enumerable:!1,writable:!0,configurable:!0}):delete error.name}));function isErrorStackTraceLimitWritable(){const desc=Object.getOwnPropertyDescriptor(Error,\"stackTraceLimit\");return void 0===desc?Object.isExtensible(Error):own$1.call(desc,\"writable\")?desc.writable:void 0!==desc.set}function hideStackFrames(fn){const hidden=\"__node_internal_\"+fn.name;return Object.defineProperty(fn,\"name\",{value:hidden}),fn}const captureLargerStackTrace=hideStackFrames((function(error){const stackTraceLimitIsWritable=isErrorStackTraceLimitWritable();return stackTraceLimitIsWritable&&(userStackTraceLimit=Error.stackTraceLimit,Error.stackTraceLimit=Number.POSITIVE_INFINITY),Error.captureStackTrace(error),stackTraceLimitIsWritable&&(Error.stackTraceLimit=userStackTraceLimit),error}));const{ERR_UNKNOWN_FILE_EXTENSION}=codes,extensionFormatMap={__proto__:null,\".cjs\":\"commonjs\",\".js\":\"module\",\".mjs\":\"module\"};function defaultGetFormat(url){if(url.startsWith(\"node:\"))return{format:\"builtin\"};const parsed=new external_url_namespaceObject.URL(url);if(\"data:\"===parsed.protocol){const{1:mime}=/^([^/]+\\/[^;,]+)[^,]*?(;base64)?,/.exec(parsed.pathname)||[null,null];return{format:\"text/javascript\"===mime?\"module\":null}}if(\"file:\"===parsed.protocol){const ext=external_path_.extname(parsed.pathname);let format;if(format=\".js\"===ext?\"module\"===function(url){return getPackageScopeConfig(url).type}(parsed.href)?\"module\":\"commonjs\":extensionFormatMap[ext],!format)throw new ERR_UNKNOWN_FILE_EXTENSION(ext,(0,external_url_namespaceObject.fileURLToPath)(url));return{format:format||null}}return{format:null}}const{ERR_INVALID_MODULE_SPECIFIER,ERR_INVALID_PACKAGE_CONFIG,ERR_INVALID_PACKAGE_TARGET,ERR_MODULE_NOT_FOUND,ERR_PACKAGE_IMPORT_NOT_DEFINED,ERR_PACKAGE_PATH_NOT_EXPORTED,ERR_UNSUPPORTED_DIR_IMPORT,ERR_UNSUPPORTED_ESM_URL_SCHEME,ERR_INVALID_ARG_VALUE}=codes,own={}.hasOwnProperty;Object.freeze([\"node\",\"import\"]);const invalidSegmentRegEx=/(^|\\\\|\\/)(\\.\\.?|node_modules)(\\\\|\\/|$)/,patternRegEx=/\\*/g,encodedSepRegEx=/%2f|%2c/i,emittedPackageWarnings=new Set,packageJsonCache=new Map;function emitFolderMapDeprecation(match,pjsonUrl,isExports,base){const pjsonPath=(0,external_url_namespaceObject.fileURLToPath)(pjsonUrl);emittedPackageWarnings.has(pjsonPath+\"|\"+match)||(emittedPackageWarnings.add(pjsonPath+\"|\"+match),process.emitWarning(`Use of deprecated folder mapping \"${match}\" in the ${isExports?'\"exports\"':'\"imports\"'} field module resolution of the package at ${pjsonPath}${base?` imported from ${(0,external_url_namespaceObject.fileURLToPath)(base)}`:\"\"}.\\nUpdate this package.json to use a subpath pattern like \"${match}*\".`,\"DeprecationWarning\",\"DEP0148\"))}function emitLegacyIndexDeprecation(url,packageJsonUrl,base,main){const{format}=defaultGetFormat(url.href);if(\"module\"!==format)return;const path2=(0,external_url_namespaceObject.fileURLToPath)(url.href),pkgPath=(0,external_url_namespaceObject.fileURLToPath)(new URL(\".\",packageJsonUrl)),basePath=(0,external_url_namespaceObject.fileURLToPath)(base);main?process.emitWarning(`Package ${pkgPath} has a \"main\" field set to ${JSON.stringify(main)}, excluding the full filename and extension to the resolved file at \"${path2.slice(pkgPath.length)}\", imported from ${basePath}.\\n Automatic extension resolution of the \"main\" field isdeprecated for ES modules.`,\"DeprecationWarning\",\"DEP0151\"):process.emitWarning(`No \"main\" or \"exports\" field defined in the package.json for ${pkgPath} resolving the main entry point \"${path2.slice(pkgPath.length)}\", imported from ${basePath}.\\nDefault \"index\" lookups for the main are deprecated for ES modules.`,\"DeprecationWarning\",\"DEP0151\")}function tryStatSync(path2){try{return(0,external_fs_.statSync)(path2)}catch{return new external_fs_.Stats}}function getPackageConfig(path2,specifier,base){const existing=packageJsonCache.get(path2);if(void 0!==existing)return existing;const source=reader.read(path2).string;if(void 0===source){const packageConfig2={pjsonPath:path2,exists:!1,main:void 0,name:void 0,type:\"none\",exports:void 0,imports:void 0};return packageJsonCache.set(path2,packageConfig2),packageConfig2}let packageJson;try{packageJson=JSON.parse(source)}catch(error){throw new ERR_INVALID_PACKAGE_CONFIG(path2,(base?`\"${specifier}\" from `:\"\")+(0,external_url_namespaceObject.fileURLToPath)(base||specifier),error.message)}const{exports,imports,main,name,type}=packageJson,packageConfig={pjsonPath:path2,exists:!0,main:\"string\"==typeof main?main:void 0,name:\"string\"==typeof name?name:void 0,type:\"module\"===type||\"commonjs\"===type?type:\"none\",exports,imports:imports&&\"object\"==typeof imports?imports:void 0};return packageJsonCache.set(path2,packageConfig),packageConfig}function getPackageScopeConfig(resolved){let packageJsonUrl=new URL(\"./package.json\",resolved);for(;;){if(packageJsonUrl.pathname.endsWith(\"node_modules/package.json\"))break;const packageConfig2=getPackageConfig((0,external_url_namespaceObject.fileURLToPath)(packageJsonUrl),resolved);if(packageConfig2.exists)return packageConfig2;const lastPackageJsonUrl=packageJsonUrl;if(packageJsonUrl=new URL(\"../package.json\",packageJsonUrl),packageJsonUrl.pathname===lastPackageJsonUrl.pathname)break}const packageJsonPath=(0,external_url_namespaceObject.fileURLToPath)(packageJsonUrl),packageConfig={pjsonPath:packageJsonPath,exists:!1,main:void 0,name:void 0,type:\"none\",exports:void 0,imports:void 0};return packageJsonCache.set(packageJsonPath,packageConfig),packageConfig}function fileExists(url){return tryStatSync((0,external_url_namespaceObject.fileURLToPath)(url)).isFile()}function legacyMainResolve(packageJsonUrl,packageConfig,base){let guess;if(void 0!==packageConfig.main){if(guess=new URL(`./${packageConfig.main}`,packageJsonUrl),fileExists(guess))return guess;const tries2=[`./${packageConfig.main}.js`,`./${packageConfig.main}.json`,`./${packageConfig.main}.node`,`./${packageConfig.main}/index.js`,`./${packageConfig.main}/index.json`,`./${packageConfig.main}/index.node`];let i2=-1;for(;++i2=0&&keyNumber<4294967295)}function resolvePackageTarget(packageJsonUrl,target,subpath,packageSubpath,base,pattern,internal,conditions){if(\"string\"==typeof target)return resolvePackageTargetString(target,subpath,packageSubpath,packageJsonUrl,base,pattern,internal,conditions);if(Array.isArray(target)){const targetList=target;if(0===targetList.length)return null;let lastException,i=-1;for(;++i=key.length&&key.length>bestMatch.length||\"/\"===key[key.length-1]&&packageSubpath.startsWith(key)&&key.length>bestMatch.length)&&(bestMatch=key)}if(bestMatch){const target=exports[bestMatch],pattern=\"*\"===bestMatch[bestMatch.length-1],resolved=resolvePackageTarget(packageJsonUrl,target,packageSubpath.slice(bestMatch.length-(pattern?1:0)),bestMatch,base,pattern,!1,conditions);return null==resolved&&throwExportsNotFound(packageSubpath,packageJsonUrl,base),pattern||emitFolderMapDeprecation(bestMatch,packageJsonUrl,!0,base),{resolved,exact:pattern}}throwExportsNotFound(packageSubpath,packageJsonUrl,base)}function packageImportsResolve(name,base,conditions){if(\"#\"===name||name.startsWith(\"#/\")){throw new ERR_INVALID_MODULE_SPECIFIER(name,\"is not a valid internal imports specifier name\",(0,external_url_namespaceObject.fileURLToPath)(base))}let packageJsonUrl;const packageConfig=getPackageScopeConfig(base);if(packageConfig.exists){packageJsonUrl=(0,external_url_namespaceObject.pathToFileURL)(packageConfig.pjsonPath);const imports=packageConfig.imports;if(imports)if(own.call(imports,name)){const resolved=resolvePackageTarget(packageJsonUrl,imports[name],\"\",name,base,!1,!0,conditions);if(null!==resolved)return{resolved,exact:!0}}else{let bestMatch=\"\";const keys=Object.getOwnPropertyNames(imports);let i=-1;for(;++i=key.length&&key.length>bestMatch.length||\"/\"===key[key.length-1]&&name.startsWith(key)&&key.length>bestMatch.length)&&(bestMatch=key)}if(bestMatch){const target=imports[bestMatch],pattern=\"*\"===bestMatch[bestMatch.length-1],resolved=resolvePackageTarget(packageJsonUrl,target,name.slice(bestMatch.length-(pattern?1:0)),bestMatch,base,pattern,!0,conditions);if(null!==resolved)return pattern||emitFolderMapDeprecation(bestMatch,packageJsonUrl,!1,base),{resolved,exact:pattern}}}}!function(specifier,packageJsonUrl,base){throw new ERR_PACKAGE_IMPORT_NOT_DEFINED(specifier,packageJsonUrl&&(0,external_url_namespaceObject.fileURLToPath)(new URL(\".\",packageJsonUrl)),(0,external_url_namespaceObject.fileURLToPath)(base))}(name,packageJsonUrl,base)}function packageResolve(specifier,base,conditions){const{packageName,packageSubpath,isScoped}=function(specifier,base){let separatorIndex=specifier.indexOf(\"/\"),validPackageName=!0,isScoped=!1;\"@\"===specifier[0]&&(isScoped=!0,-1===separatorIndex||0===specifier.length?validPackageName=!1:separatorIndex=specifier.indexOf(\"/\",separatorIndex+1));const packageName=-1===separatorIndex?specifier:specifier.slice(0,separatorIndex);let i=-1;for(;++inew URL(function(id){return\"string\"!=typeof id&&(id=id.toString()),/(node|data|http|https|file):/.test(id)?id:BUILTIN_MODULES.has(id)?\"node:\"+id:\"file://\"+encodeURI(normalizeSlash(id))}(u.toString()))));_urls.length||_urls.push(DEFAULT_URL);const urls=[..._urls];for(const url of _urls)\"file:\"===url.protocol&&(urls.push(new URL(\"./\",url)),urls.push(new URL(joinURL(url.pathname,\"_index.js\"),url)),urls.push(new URL(\"./node_modules\",url)));let resolved;for(const url of urls){if(resolved=_tryModuleResolve(id,url,conditionsSet),resolved)break;for(const prefix of[\"\",\"/index\"]){for(const ext of opts.extensions||DEFAULT_EXTENSIONS)if(resolved=_tryModuleResolve(id+prefix+ext,url,conditionsSet),resolved)break;if(resolved)break}}if(!resolved){const err=new Error(`Cannot find module ${id} imported from ${urls.join(\", \")}`);throw err.code=\"ERR_MODULE_NOT_FOUND\",err}const realPath=(0,external_fs_.realpathSync)(fileURLToPath(resolved));return(0,external_url_namespaceObject.pathToFileURL)(realPath).toString()}function resolveSync(id,opts){return _resolve(id,opts)}function resolvePathSync(id,opts){return fileURLToPath(resolveSync(id,opts))}const ESM_RE=/([\\s;]|^)(import[\\w,{}\\s*]*from|import\\s*['\"*{]|export\\b\\s*(?:[*{]|default|class|type|function|const|var|let|async function)|import\\.meta\\b)/m;function hasESMSyntax(code){return ESM_RE.test(code)}var external_crypto_=__webpack_require__(\"crypto\");function md5(content,len=8){return(0,external_crypto_.createHash)(\"md5\").update(content).digest(\"hex\").slice(0,len)}const _EnvDebug=destr(process.env.JITI_DEBUG),_EnvCache=destr(process.env.JITI_CACHE),_EnvESMResolve=destr(process.env.JITI_ESM_RESOLVE),_EnvRequireCache=destr(process.env.JITI_REQUIRE_CACHE),_EnvSourceMaps=destr(process.env.JITI_SOURCE_MAPS),_EnvAlias=destr(process.env.JITI_ALIAS),_EnvTransform=destr(process.env.JITI_TRANSFORM_MODULES),_EnvNative=destr(process.env.JITI_NATIVE_MODULES),jiti_isWindows=\"win32\"===(0,external_os_namespaceObject.platform)(),defaults={debug:_EnvDebug,cache:void 0===_EnvCache||!!_EnvCache,requireCache:void 0===_EnvRequireCache||!!_EnvRequireCache,sourceMaps:void 0!==_EnvSourceMaps&&!!_EnvSourceMaps,interopDefault:!1,esmResolve:_EnvESMResolve||!1,cacheVersion:\"7\",legacy:(0,semver.lt)(process.version||\"0.0.0\",\"14.0.0\"),extensions:[\".js\",\".mjs\",\".cjs\",\".ts\"],alias:_EnvAlias,nativeModules:_EnvNative||[],transformModules:_EnvTransform||[]};function createJITI(_filename,opts={},parentModule){(opts=Object.assign(Object.assign({},defaults),opts)).legacy&&(opts.cacheVersion+=\"-legacy\"),opts.transformOptions&&(opts.cacheVersion+=\"-\"+object_hash_default()(opts.transformOptions));const alias=opts.alias&&Object.keys(opts.alias).length?normalizeAliases(opts.alias||{}):null,nativeModules=[\"typescript\",\"jiti\"].concat(opts.nativeModules||[]),transformModules=[].concat(opts.transformModules||[]),isNativeRe=new RegExp(`node_modules/(${nativeModules.map((m=>escapeStringRegexp(m))).join(\"|\")})/`),isTransformRe=new RegExp(`node_modules/(${transformModules.map((m=>escapeStringRegexp(m))).join(\"|\")})/`);function debug(...args){opts.debug&&console.log(\"[jiti]\",...args)}if(_filename||(_filename=process.cwd()),function(filename){try{return(0,external_fs_.lstatSync)(filename).isDirectory()}catch(e){return!1}}(_filename)&&(_filename=join(_filename,\"index.js\")),!0===opts.cache&&(opts.cache=join((0,external_os_namespaceObject.tmpdir)(),\"node-jiti\")),opts.cache)try{if((0,mkdirp.sync)(opts.cache),!function(filename){try{return(0,external_fs_.accessSync)(filename,external_fs_.constants.W_OK),!0}catch(e){return!1}}(opts.cache))throw new Error(\"directory is not writable\")}catch(err){debug(\"Error creating cache directory at \",opts.cache,err),opts.cache=!1}const nativeRequire=create_require_default()(jiti_isWindows?_filename.replace(/\\//g,\"\\\\\"):_filename),tryResolve=(id,options)=>{try{return nativeRequire.resolve(id,options)}catch(e){}},_url=(0,external_url_namespaceObject.pathToFileURL)(_filename),_additionalExts=[...opts.extensions].filter((ext=>\".js\"!==ext)),_resolve=(id,options)=>{let resolved,err;if(alias&&(id=function(path,aliases){const _path=normalizeWindowsPath(path);aliases=normalizeAliases(aliases);for(const alias in aliases)if(_path.startsWith(alias))return join(aliases[alias],_path.slice(alias.length));return _path}(id,alias)),opts.esmResolve){try{resolved=resolvePathSync(id,{url:_url,conditions:[\"node\",\"require\",\"import\"]})}catch(_err){err=_err}if(resolved)return resolved}if(opts.extensions.includes(pathe_f81973bb_extname(id)))return nativeRequire.resolve(id,options);try{return nativeRequire.resolve(id,options)}catch(_err){err=_err}for(const ext of _additionalExts)if(resolved=tryResolve(id+ext,options)||tryResolve(id+\"/index\"+ext,options),resolved)return resolved;throw err};function transform(topts){let code=function(filename,source,get){if(!opts.cache||!filename)return get();const sourceHash=` /* v${opts.cacheVersion}-${md5(source,16)} */`,filebase=basename(pathe_f81973bb_dirname(filename))+\"-\"+basename(filename),cacheFile=join(opts.cache,filebase+\".\"+md5(filename)+\".js\");if((0,external_fs_.existsSync)(cacheFile)){const cacheSource=(0,external_fs_.readFileSync)(cacheFile,\"utf-8\");if(cacheSource.endsWith(sourceHash))return debug(\"[cache hit]\",filename,\"~>\",cacheFile),cacheSource}debug(\"[cache miss]\",filename);const result=get();return result.includes(\"__JITI_ERROR__\")||(0,external_fs_.writeFileSync)(cacheFile,result+sourceHash,\"utf-8\"),result}(topts.filename,topts.source,(()=>{var _a;const res=opts.transform(Object.assign(Object.assign(Object.assign({legacy:opts.legacy},opts.transformOptions),{babel:Object.assign(Object.assign({},opts.sourceMaps?{sourceFileName:topts.filename,sourceMaps:\"inline\"}:{}),null===(_a=opts.transformOptions)||void 0===_a?void 0:_a.babel)}),topts));return res.error&&opts.debug&&debug(res.error),res.code}));return code.startsWith(\"#!\")&&(code=\"// \"+code),code}function _interopDefault(mod){return opts.interopDefault?function(sourceModule){if(null===(val=sourceModule)||\"object\"!=typeof val||!(\"default\"in sourceModule))return sourceModule;var val;const newModule=sourceModule.default;for(const key in sourceModule)if(\"default\"===key)try{key in newModule||Object.defineProperty(newModule,key,{enumerable:!1,configurable:!1,get:()=>newModule})}catch(_err){}else try{key in newModule||Object.defineProperty(newModule,key,{enumerable:!0,configurable:!0,get:()=>sourceModule[key]})}catch(_err){}return newModule}(mod):mod}function jiti(id){var _a,_b;if(id.startsWith(\"node:\")?id=id.substr(5):id.startsWith(\"file:\")&&(id=(0,external_url_namespaceObject.fileURLToPath)(id)),external_module_.builtinModules.includes(id)||\".pnp.js\"===id)return nativeRequire(id);const filename=_resolve(id),ext=pathe_f81973bb_extname(filename);if(ext&&!opts.extensions.includes(ext))return debug(\"[unknown]\",filename),nativeRequire(id);if(isNativeRe.test(filename))return debug(\"[native]\",filename),nativeRequire(id);if(opts.requireCache&&nativeRequire.cache[filename])return _interopDefault(null===(_a=nativeRequire.cache[filename])||void 0===_a?void 0:_a.exports);let source=(0,external_fs_.readFileSync)(filename,\"utf-8\");const isTypescript=\".ts\"===ext,isNativeModule=\".mjs\"===ext||\".js\"===ext&&\"module\"===(null===(_b=function(path){for(;path&&\".\"!==path&&\"/\"!==path;){path=join(path,\"..\");try{const pkg=(0,external_fs_.readFileSync)(join(path,\"package.json\"),\"utf-8\");try{return JSON.parse(pkg)}catch(_a){}break}catch(_b){}}}(filename))||void 0===_b?void 0:_b.type),needsTranspile=!(\".cjs\"===ext)&&(isTypescript||isNativeModule||isTransformRe.test(filename)||hasESMSyntax(source)||opts.legacy&&source.match(/\\?\\.|\\?\\?/));const start=external_perf_hooks_namespaceObject.performance.now();if(needsTranspile){source=transform({filename,source,ts:isTypescript});debug(\"[transpile]\"+(isNativeModule?\" [esm]\":\"\"),filename,`(${Math.round(1e3*(external_perf_hooks_namespaceObject.performance.now()-start))/1e3}ms)`)}else try{return debug(\"[native]\",filename),_interopDefault(nativeRequire(id))}catch(err){debug(\"Native require error:\",err),debug(\"[fallback]\",filename),source=transform({filename,source,ts:isTypescript})}const mod=new external_module_.Module(filename);let compiled;mod.filename=filename,parentModule&&(mod.parent=parentModule,Array.isArray(parentModule.children)&&!parentModule.children.includes(mod)&&parentModule.children.push(mod)),mod.require=createJITI(filename,opts,mod),mod.path=pathe_f81973bb_dirname(filename),mod.paths=external_module_.Module._nodeModulePaths(mod.path),opts.requireCache&&(nativeRequire.cache[filename]=mod);try{compiled=external_vm_default().runInThisContext(external_module_.Module.wrap(source),{filename,lineOffset:0,displayErrors:!1})}catch(err){opts.requireCache&&delete nativeRequire.cache[filename],opts.onError(err)}try{compiled(mod.exports,mod.require,mod,mod.filename,pathe_f81973bb_dirname(mod.filename))}catch(err){opts.requireCache&&delete nativeRequire.cache[filename],opts.onError(err)}if(mod.exports&&mod.exports.__JITI_ERROR__){const{filename,line,column,code,message}=mod.exports.__JITI_ERROR__,err=new Error(`${code}: ${message} \\n ${`${filename}:${line}:${column}`}`);Error.captureStackTrace(err,jiti),opts.onError(err)}mod.loaded=!0;return _interopDefault(mod.exports)}return _resolve.paths=nativeRequire.resolve.paths,jiti.resolve=_resolve,jiti.cache=opts.requireCache?nativeRequire.cache:{},jiti.extensions=nativeRequire.extensions,jiti.main=nativeRequire.main,jiti.transform=transform,jiti.register=function(){return(0,lib.addHook)(((source,filename)=>jiti.transform({source,filename,ts:!!filename.match(/\\.[cm]?ts$/)})),{exts:opts.extensions})},jiti}})(),module.exports=__webpack_exports__.default})();", "(()=>{var __webpack_modules__={\"./node_modules/.pnpm/@babel+core@7.19.1/node_modules/@babel/core/lib/config/files lazy recursive\":module=>{function webpackEmptyAsyncContext(req){return Promise.resolve().then((()=>{var e=new Error(\"Cannot find module '\"+req+\"'\");throw e.code=\"MODULE_NOT_FOUND\",e}))}webpackEmptyAsyncContext.keys=()=>[],webpackEmptyAsyncContext.resolve=webpackEmptyAsyncContext,webpackEmptyAsyncContext.id=\"./node_modules/.pnpm/@babel+core@7.19.1/node_modules/@babel/core/lib/config/files lazy recursive\",module.exports=webpackEmptyAsyncContext},\"./node_modules/.pnpm/@babel+core@7.19.1/node_modules/@babel/core/lib/config/files sync recursive\":module=>{function webpackEmptyContext(req){var e=new Error(\"Cannot find module '\"+req+\"'\");throw e.code=\"MODULE_NOT_FOUND\",e}webpackEmptyContext.keys=()=>[],webpackEmptyContext.resolve=webpackEmptyContext,webpackEmptyContext.id=\"./node_modules/.pnpm/@babel+core@7.19.1/node_modules/@babel/core/lib/config/files sync recursive\",module.exports=webpackEmptyContext},\"./node_modules/.pnpm/@babel+plugin-syntax-class-properties@7.12.13_@babel+core@7.19.1/node_modules/@babel/plugin-syntax-class-properties/lib/index.js\":(__unused_webpack_module,exports,__webpack_require__)=>{\"use strict\";Object.defineProperty(exports,\"__esModule\",{value:!0}),exports.default=void 0;var _default=(0,__webpack_require__(\"./node_modules/.pnpm/@babel+helper-plugin-utils@7.18.9/node_modules/@babel/helper-plugin-utils/lib/index.js\").declare)((api=>(api.assertVersion(7),{name:\"syntax-class-properties\",manipulateOptions(opts,parserOpts){parserOpts.plugins.push(\"classProperties\",\"classPrivateProperties\",\"classPrivateMethods\")}})));exports.default=_default},\"./node_modules/.pnpm/@babel+plugin-syntax-export-namespace-from@7.8.3_@babel+core@7.19.1/node_modules/@babel/plugin-syntax-export-namespace-from/lib/index.js\":(__unused_webpack_module,exports,__webpack_require__)=>{\"use strict\";Object.defineProperty(exports,\"__esModule\",{value:!0}),exports.default=void 0;var _default=(0,__webpack_require__(\"./node_modules/.pnpm/@babel+helper-plugin-utils@7.19.0/node_modules/@babel/helper-plugin-utils/lib/index.js\").declare)((api=>(api.assertVersion(7),{name:\"syntax-export-namespace-from\",manipulateOptions(opts,parserOpts){parserOpts.plugins.push(\"exportNamespaceFrom\")}})));exports.default=_default},\"./node_modules/.pnpm/@babel+plugin-syntax-nullish-coalescing-operator@7.8.3_@babel+core@7.19.1/node_modules/@babel/plugin-syntax-nullish-coalescing-operator/lib/index.js\":(__unused_webpack_module,exports,__webpack_require__)=>{\"use strict\";Object.defineProperty(exports,\"__esModule\",{value:!0}),exports.default=void 0;var _default=(0,__webpack_require__(\"./node_modules/.pnpm/@babel+helper-plugin-utils@7.19.0/node_modules/@babel/helper-plugin-utils/lib/index.js\").declare)((api=>(api.assertVersion(7),{name:\"syntax-nullish-coalescing-operator\",manipulateOptions(opts,parserOpts){parserOpts.plugins.push(\"nullishCoalescingOperator\")}})));exports.default=_default},\"./node_modules/.pnpm/@babel+plugin-syntax-optional-chaining@7.8.3_@babel+core@7.19.1/node_modules/@babel/plugin-syntax-optional-chaining/lib/index.js\":(__unused_webpack_module,exports,__webpack_require__)=>{\"use strict\";Object.defineProperty(exports,\"__esModule\",{value:!0}),exports.default=void 0;var _default=(0,__webpack_require__(\"./node_modules/.pnpm/@babel+helper-plugin-utils@7.19.0/node_modules/@babel/helper-plugin-utils/lib/index.js\").declare)((api=>(api.assertVersion(7),{name:\"syntax-optional-chaining\",manipulateOptions(opts,parserOpts){parserOpts.plugins.push(\"optionalChaining\")}})));exports.default=_default},\"./node_modules/.pnpm/@jridgewell+gen-mapping@0.3.2/node_modules/@jridgewell/gen-mapping/dist/gen-mapping.umd.js\":function(__unused_webpack_module,exports,__webpack_require__){!function(exports,setArray,sourcemapCodec,traceMapping){\"use strict\";const COLUMN=0,SOURCES_INDEX=1,SOURCE_LINE=2,SOURCE_COLUMN=3,NAMES_INDEX=4,NO_NAME=-1;let addSegmentInternal;exports.addSegment=void 0,exports.addMapping=void 0,exports.maybeAddSegment=void 0,exports.maybeAddMapping=void 0,exports.setSourceContent=void 0,exports.toDecodedMap=void 0,exports.toEncodedMap=void 0,exports.fromMap=void 0,exports.allMappings=void 0;class GenMapping{constructor({file,sourceRoot}={}){this._names=new setArray.SetArray,this._sources=new setArray.SetArray,this._sourcesContent=[],this._mappings=[],this.file=file,this.sourceRoot=sourceRoot}}function getLine(mappings,index){for(let i=mappings.length;i<=index;i++)mappings[i]=[];return mappings[index]}function getColumnIndex(line,genColumn){let index=line.length;for(let i=index-1;i>=0&&!(genColumn>=line[i][COLUMN]);index=i--);return index}function insert(array,index,value){for(let i=array.length;i>index;i--)array[i]=array[i-1];array[index]=value}function removeEmptyFinalLines(mappings){const{length}=mappings;let len=length;for(let i=len-1;i>=0&&!(mappings[i].length>0);len=i,i--);lenaddSegmentInternal(!1,map,genLine,genColumn,source,sourceLine,sourceColumn,name,content),exports.maybeAddSegment=(map,genLine,genColumn,source,sourceLine,sourceColumn,name,content)=>addSegmentInternal(!0,map,genLine,genColumn,source,sourceLine,sourceColumn,name,content),exports.addMapping=(map,mapping)=>addMappingInternal(!1,map,mapping),exports.maybeAddMapping=(map,mapping)=>addMappingInternal(!0,map,mapping),exports.setSourceContent=(map,source,content)=>{const{_sources:sources,_sourcesContent:sourcesContent}=map;sourcesContent[setArray.put(sources,source)]=content},exports.toDecodedMap=map=>{const{file,sourceRoot,_mappings:mappings,_sources:sources,_sourcesContent:sourcesContent,_names:names}=map;return removeEmptyFinalLines(mappings),{version:3,file:file||void 0,names:names.array,sourceRoot:sourceRoot||void 0,sources:sources.array,sourcesContent,mappings}},exports.toEncodedMap=map=>{const decoded=exports.toDecodedMap(map);return Object.assign(Object.assign({},decoded),{mappings:sourcemapCodec.encode(decoded.mappings)})},exports.allMappings=map=>{const out=[],{_mappings:mappings,_sources:sources,_names:names}=map;for(let i=0;i{const map=new traceMapping.TraceMap(input),gen=new GenMapping({file:map.file,sourceRoot:map.sourceRoot});return putAll(gen._names,map.names),putAll(gen._sources,map.sources),gen._sourcesContent=map.sourcesContent||map.sources.map((()=>null)),gen._mappings=traceMapping.decodedMappings(map),gen},addSegmentInternal=(skipable,map,genLine,genColumn,source,sourceLine,sourceColumn,name,content)=>{const{_mappings:mappings,_sources:sources,_sourcesContent:sourcesContent,_names:names}=map,line=getLine(mappings,genLine),index=getColumnIndex(line,genColumn);if(!source){if(skipable&&skipSourceless(line,index))return;return insert(line,index,[genColumn])}const sourcesIndex=setArray.put(sources,source),namesIndex=name?setArray.put(names,name):NO_NAME;if(sourcesIndex===sourcesContent.length&&(sourcesContent[sourcesIndex]=null!=content?content:null),!skipable||!skipSource(line,index,sourcesIndex,sourceLine,sourceColumn,namesIndex))return insert(line,index,name?[genColumn,sourcesIndex,sourceLine,sourceColumn,namesIndex]:[genColumn,sourcesIndex,sourceLine,sourceColumn])},exports.GenMapping=GenMapping,Object.defineProperty(exports,\"__esModule\",{value:!0})}(exports,__webpack_require__(\"./node_modules/.pnpm/@jridgewell+set-array@1.1.1/node_modules/@jridgewell/set-array/dist/set-array.umd.js\"),__webpack_require__(\"./node_modules/.pnpm/@jridgewell+sourcemap-codec@1.4.13/node_modules/@jridgewell/sourcemap-codec/dist/sourcemap-codec.umd.js\"),__webpack_require__(\"./node_modules/.pnpm/@jridgewell+trace-mapping@0.3.15/node_modules/@jridgewell/trace-mapping/dist/trace-mapping.umd.js\"))},\"./node_modules/.pnpm/@jridgewell+resolve-uri@3.0.7/node_modules/@jridgewell/resolve-uri/dist/resolve-uri.umd.js\":function(module){module.exports=function(){\"use strict\";const schemeRegex=/^[\\w+.-]+:\\/\\//,urlRegex=/^([\\w+.-]+:)\\/\\/([^@/#?]*@)?([^:/#?]*)(:\\d+)?(\\/[^#?]*)?/,fileRegex=/^file:(?:\\/\\/((?![a-z]:)[^/]*)?)?(\\/?.*)/i;function isAbsoluteUrl(input){return schemeRegex.test(input)}function isSchemeRelativeUrl(input){return input.startsWith(\"//\")}function isAbsolutePath(input){return input.startsWith(\"/\")}function isFileUrl(input){return input.startsWith(\"file:\")}function parseAbsoluteUrl(input){const match=urlRegex.exec(input);return makeUrl(match[1],match[2]||\"\",match[3],match[4]||\"\",match[5]||\"/\")}function parseFileUrl(input){const match=fileRegex.exec(input),path=match[2];return makeUrl(\"file:\",\"\",match[1]||\"\",\"\",isAbsolutePath(path)?path:\"/\"+path)}function makeUrl(scheme,user,host,port,path){return{scheme,user,host,port,path,relativePath:!1}}function parseUrl(input){if(isSchemeRelativeUrl(input)){const url=parseAbsoluteUrl(\"http:\"+input);return url.scheme=\"\",url}if(isAbsolutePath(input)){const url=parseAbsoluteUrl(\"http://foo.com\"+input);return url.scheme=\"\",url.host=\"\",url}if(isFileUrl(input))return parseFileUrl(input);if(isAbsoluteUrl(input))return parseAbsoluteUrl(input);const url=parseAbsoluteUrl(\"http://foo.com/\"+input);return url.scheme=\"\",url.host=\"\",url.relativePath=!0,url}function stripPathFilename(path){if(path.endsWith(\"/..\"))return path;const index=path.lastIndexOf(\"/\");return path.slice(0,index+1)}function mergePaths(url,base){url.relativePath&&(normalizePath(base),\"/\"===url.path?url.path=base.path:url.path=stripPathFilename(base.path)+url.path,url.relativePath=base.relativePath)}function normalizePath(url){const{relativePath}=url,pieces=url.path.split(\"/\");let pointer=1,positive=0,addTrailingSlash=!1;for(let i=1;istrarr._indexes[key],exports.put=(strarr,key)=>{const index=exports.get(strarr,key);if(void 0!==index)return index;const{array,_indexes:indexes}=strarr;return indexes[key]=array.push(key)-1},exports.pop=strarr=>{const{array,_indexes:indexes}=strarr;0!==array.length&&(indexes[array.pop()]=void 0)},exports.SetArray=SetArray,Object.defineProperty(exports,\"__esModule\",{value:!0})}(exports)},\"./node_modules/.pnpm/@jridgewell+sourcemap-codec@1.4.13/node_modules/@jridgewell/sourcemap-codec/dist/sourcemap-codec.umd.js\":function(__unused_webpack_module,exports){!function(exports){\"use strict\";const comma=\",\".charCodeAt(0),semicolon=\";\".charCodeAt(0),chars=\"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/\",intToChar=new Uint8Array(64),charToInt=new Uint8Array(128);for(let i=0;iBuffer.from(buf.buffer,buf.byteOffset,buf.byteLength).toString()}:{decode(buf){let out=\"\";for(let i=0;i>>=1,shouldNegate&&(value=-2147483648|-value),state[j]+=value,pos}function hasMoreVlq(mappings,i,length){return!(i>=length)&&mappings.charCodeAt(i)!==comma}function sort(line){line.sort(sortComparator)}function sortComparator(a,b){return a[0]-b[0]}function encode(decoded){const state=new Int32Array(5),bufLength=16384,subLength=bufLength-36,buf=new Uint8Array(bufLength),sub=buf.subarray(0,subLength);let pos=0,out=\"\";for(let i=0;i0&&(pos===bufLength&&(out+=td.decode(buf),pos=0),buf[pos++]=semicolon),0!==line.length){state[0]=0;for(let j=0;jsubLength&&(out+=td.decode(sub),buf.copyWithin(0,subLength,pos),pos-=subLength),j>0&&(buf[pos++]=comma),pos=encodeInteger(buf,pos,state,segment,0),1!==segment.length&&(pos=encodeInteger(buf,pos,state,segment,1),pos=encodeInteger(buf,pos,state,segment,2),pos=encodeInteger(buf,pos,state,segment,3),4!==segment.length&&(pos=encodeInteger(buf,pos,state,segment,4)))}}}return out+td.decode(buf.subarray(0,pos))}function encodeInteger(buf,pos,state,segment,j){const next=segment[j];let num=next-state[j];state[j]=next,num=num<0?-num<<1|1:num<<1;do{let clamped=31#num>>>=5,num>0&&(clamped|=32),buf[pos++]=intToChar[clamped]}while(num>0);return pos}exports.decode=decode,exports.encode=encode,Object.defineProperty(exports,\"__esModule\",{value:!0})}(exports)},\"./node_modules/.pnpm/@jridgewell+trace-mapping@0.3.15/node_modules/@jridgewell/trace-mapping/dist/trace-mapping.umd.js\":function(__unused_webpack_module,exports,__webpack_require__){!function(exports,sourcemapCodec,resolveUri){\"use strict\";function _interopDefaultLegacy(e){return e&&\"object\"==typeof e&&\"default\"in e?e:{default:e}}var resolveUri__default=_interopDefaultLegacy(resolveUri);function resolve(input,base){return base&&!base.endsWith(\"/\")&&(base+=\"/\"),resolveUri__default.default(input,base)}function stripFilename(path){if(!path)return\"\";const index=path.lastIndexOf(\"/\");return path.slice(0,index+1)}const COLUMN=0,SOURCES_INDEX=1,SOURCE_LINE=2,SOURCE_COLUMN=3,NAMES_INDEX=4,REV_GENERATED_LINE=1,REV_GENERATED_COLUMN=2;function maybeSort(mappings,owned){const unsortedIndex=nextUnsortedSegmentLine(mappings,0);if(unsortedIndex===mappings.length)return mappings;owned||(mappings=mappings.slice());for(let i=unsortedIndex;i>1),cmp=haystack[mid][COLUMN]-needle;if(0===cmp)return found=!0,mid;cmp<0?low=mid+1:high=mid-1}return found=!1,low-1}function upperBound(haystack,needle,index){for(let i=index+1;i=0&&haystack[i][COLUMN]===needle;index=i--);return index}function memoizedState(){return{lastKey:-1,lastNeedle:-1,lastIndex:-1}}function memoizedBinarySearch(haystack,needle,state,key){const{lastKey,lastNeedle,lastIndex}=state;let low=0,high=haystack.length-1;if(key===lastKey){if(needle===lastNeedle)return found=-1!==lastIndex&&haystack[lastIndex][COLUMN]===needle,lastIndex;needle>=lastNeedle?low=-1===lastIndex?0:lastIndex:high=lastIndex}return state.lastKey=key,state.lastNeedle=needle,state.lastIndex=binarySearch(haystack,needle,low,high)}function buildBySources(decoded,memos){const sources=memos.map(buildNullArray);for(let i=0;iindex;i--)array[i]=array[i-1];array[index]=value}function buildNullArray(){return{__proto__:null}}const AnyMap=function(map,mapUrl){const parsed=\"string\"==typeof map?JSON.parse(map):map;if(!(\"sections\"in parsed))return new TraceMap(parsed,mapUrl);const mappings=[],sources=[],sourcesContent=[],names=[];recurse(parsed,mapUrl,mappings,sources,sourcesContent,names,0,0,1/0,1/0);const joined={version:3,file:parsed.file,names,sources,sourcesContent,mappings};return exports.presortedDecodedMap(joined)};function recurse(input,mapUrl,mappings,sources,sourcesContent,names,lineOffset,columnOffset,stopLine,stopColumn){const{sections}=input;for(let i=0;istopLine)return;const out=getLine(mappings,lineI),cOffset=0===i?columnOffset:0,line=decoded[i];for(let j=0;j=stopColumn)return;if(1===seg.length){out.push([column]);continue}const sourcesIndex=sourcesOffset+seg[SOURCES_INDEX],sourceLine=seg[SOURCE_LINE],sourceColumn=seg[SOURCE_COLUMN];out.push(4===seg.length?[column,sourcesIndex,sourceLine,sourceColumn]:[column,sourcesIndex,sourceLine,sourceColumn,namesOffset+seg[NAMES_INDEX]])}}}function append(arr,other){for(let i=0;iresolve(s||\"\",from)));const{mappings}=parsed;\"string\"==typeof mappings?(this._encoded=mappings,this._decoded=void 0):(this._encoded=void 0,this._decoded=maybeSort(mappings,isString)),this._decodedMemo=memoizedState(),this._bySources=void 0,this._bySourceMemos=void 0}}function clone(map,mappings){return{version:map.version,file:map.file,names:map.names,sourceRoot:map.sourceRoot,sources:map.sources,sourcesContent:map.sourcesContent,mappings}}function OMapping(source,line,column,name){return{source,line,column,name}}function GMapping(line,column){return{line,column}}function traceSegmentInternal(segments,memo,line,column,bias){let index=memoizedBinarySearch(segments,column,memo,line);return found?index=(bias===LEAST_UPPER_BOUND?upperBound:lowerBound)(segments,column,index):bias===LEAST_UPPER_BOUND&&index++,-1===index||index===segments.length?null:segments[index]}exports.encodedMappings=map=>{var _a;return null!==(_a=map._encoded)&&void 0!==_a?_a:map._encoded=sourcemapCodec.encode(map._decoded)},exports.decodedMappings=map=>map._decoded||(map._decoded=sourcemapCodec.decode(map._encoded)),exports.traceSegment=(map,line,column)=>{const decoded=exports.decodedMappings(map);return line>=decoded.length?null:traceSegmentInternal(decoded[line],map._decodedMemo,line,column,GREATEST_LOWER_BOUND)},exports.originalPositionFor=(map,{line,column,bias})=>{if(--line<0)throw new Error(LINE_GTR_ZERO);if(column<0)throw new Error(COL_GTR_EQ_ZERO);const decoded=exports.decodedMappings(map);if(line>=decoded.length)return OMapping(null,null,null,null);const segment=traceSegmentInternal(decoded[line],map._decodedMemo,line,column,bias||GREATEST_LOWER_BOUND);if(null==segment)return OMapping(null,null,null,null);if(1==segment.length)return OMapping(null,null,null,null);const{names,resolvedSources}=map;return OMapping(resolvedSources[segment[SOURCES_INDEX]],segment[SOURCE_LINE]+1,segment[SOURCE_COLUMN],5===segment.length?names[segment[NAMES_INDEX]]:null)},exports.generatedPositionFor=(map,{source,line,column,bias})=>{if(--line<0)throw new Error(LINE_GTR_ZERO);if(column<0)throw new Error(COL_GTR_EQ_ZERO);const{sources,resolvedSources}=map;let sourceIndex=sources.indexOf(source);if(-1===sourceIndex&&(sourceIndex=resolvedSources.indexOf(source)),-1===sourceIndex)return GMapping(null,null);const generated=map._bySources||(map._bySources=buildBySources(exports.decodedMappings(map),map._bySourceMemos=sources.map(memoizedState))),memos=map._bySourceMemos,segments=generated[sourceIndex][line];if(null==segments)return GMapping(null,null);const segment=traceSegmentInternal(segments,memos[sourceIndex],line,column,bias||GREATEST_LOWER_BOUND);return null==segment?GMapping(null,null):GMapping(segment[REV_GENERATED_LINE]+1,segment[REV_GENERATED_COLUMN])},exports.eachMapping=(map,cb)=>{const decoded=exports.decodedMappings(map),{names,resolvedSources}=map;for(let i=0;i{const{sources,resolvedSources,sourcesContent}=map;if(null==sourcesContent)return null;let index=sources.indexOf(source);return-1===index&&(index=resolvedSources.indexOf(source)),-1===index?null:sourcesContent[index]},exports.presortedDecodedMap=(map,mapUrl)=>{const tracer=new TraceMap(clone(map,[]),mapUrl);return tracer._decoded=map.mappings,tracer},exports.decodedMap=map=>clone(map,exports.decodedMappings(map)),exports.encodedMap=map=>clone(map,exports.encodedMappings(map)),exports.AnyMap=AnyMap,exports.GREATEST_LOWER_BOUND=GREATEST_LOWER_BOUND,exports.LEAST_UPPER_BOUND=LEAST_UPPER_BOUND,exports.TraceMap=TraceMap,Object.defineProperty(exports,\"__esModule\",{value:!0})}(exports,__webpack_require__(\"./node_modules/.pnpm/@jridgewell+sourcemap-codec@1.4.13/node_modules/@jridgewell/sourcemap-codec/dist/sourcemap-codec.umd.js\"),__webpack_require__(\"./node_modules/.pnpm/@jridgewell+resolve-uri@3.0.7/node_modules/@jridgewell/resolve-uri/dist/resolve-uri.umd.js\"))},\"./node_modules/.pnpm/babel-plugin-dynamic-import-node@2.3.3/node_modules/babel-plugin-dynamic-import-node/lib/index.js\":(module,exports,__webpack_require__)=>{\"use strict\";Object.defineProperty(exports,\"__esModule\",{value:!0}),exports.default=function(api){var transformImport=(0,_utils.createDynamicImportTransform)(api);return{manipulateOptions:function(opts,parserOpts){parserOpts.plugins.push(\"dynamicImport\")},visitor:{Import:function(path){transformImport(this,path)}}}};var _utils=__webpack_require__(\"./node_modules/.pnpm/babel-plugin-dynamic-import-node@2.3.3/node_modules/babel-plugin-dynamic-import-node/lib/utils.js\");module.exports=exports.default},\"./node_modules/.pnpm/babel-plugin-dynamic-import-node@2.3.3/node_modules/babel-plugin-dynamic-import-node/lib/utils.js\":(__unused_webpack_module,exports)=>{\"use strict\";Object.defineProperty(exports,\"__esModule\",{value:!0});var _slicedToArray=function(arr,i){if(Array.isArray(arr))return arr;if(Symbol.iterator in Object(arr))return function(arr,i){var _arr=[],_n=!0,_d=!1,_e=void 0;try{for(var _s,_i=arr[Symbol.iterator]();!(_n=(_s=_i.next()).done)&&(_arr.push(_s.value),!i||_arr.length!==i);_n=!0);}catch(err){_d=!0,_e=err}finally{try{!_n&&_i.return&&_i.return()}finally{if(_d)throw _e}}return _arr}(arr,i);throw new TypeError(\"Invalid attempt to destructure non-iterable instance\")};function getImportSource(t,callNode){var importArguments=callNode.arguments,importPath=_slicedToArray(importArguments,1)[0];return t.isStringLiteral(importPath)||t.isTemplateLiteral(importPath)?(t.removeComments(importPath),importPath):t.templateLiteral([t.templateElement({raw:\"\",cooked:\"\"}),t.templateElement({raw:\"\",cooked:\"\"},!0)],importArguments)}exports.getImportSource=getImportSource,exports.createDynamicImportTransform=function(_ref){var template=_ref.template,t=_ref.types,builders={static:{interop:template(\"Promise.resolve().then(() => INTEROP(require(SOURCE)))\"),noInterop:template(\"Promise.resolve().then(() => require(SOURCE))\")},dynamic:{interop:template(\"Promise.resolve(SOURCE).then(s => INTEROP(require(s)))\"),noInterop:template(\"Promise.resolve(SOURCE).then(s => require(s))\")}},visited=\"function\"==typeof WeakSet&&new WeakSet;return function(context,path){if(visited){if(visited.has(path))return;visited.add(path)}var node,SOURCE=getImportSource(t,path.parent),builder=(node=SOURCE,t.isStringLiteral(node)||t.isTemplateLiteral(node)&&0===node.expressions.length?builders.static:builders.dynamic),newImport=context.opts.noInterop?builder.noInterop({SOURCE}):builder.interop({SOURCE,INTEROP:context.addHelper(\"interopRequireWildcard\")});path.parentPath.replaceWith(newImport)}}},\"./node_modules/.pnpm/babel-plugin-dynamic-import-node@2.3.3/node_modules/babel-plugin-dynamic-import-node/utils.js\":(module,__unused_webpack_exports,__webpack_require__)=>{module.exports=__webpack_require__(\"./node_modules/.pnpm/babel-plugin-dynamic-import-node@2.3.3/node_modules/babel-plugin-dynamic-import-node/lib/utils.js\")},\"./node_modules/.pnpm/babel-plugin-parameter-decorator@1.0.16/node_modules/babel-plugin-parameter-decorator/lib/index.js\":(module,__unused_webpack_exports,__webpack_require__)=>{\"use strict\";var _path=__webpack_require__(\"path\");function isInType(path){switch(path.parent.type){case\"TSTypeReference\":case\"TSQualifiedName\":case\"TSExpressionWithTypeArguments\":case\"TSTypeQuery\":return!0;default:return!1}}module.exports=function(_ref){var types=_ref.types,decoratorExpressionForConstructor=function(decorator,param){return function(className){var resultantDecorator=types.callExpression(decorator.expression,[types.Identifier(className),types.Identifier(\"undefined\"),types.NumericLiteral(param.key)]),resultantDecoratorWithFallback=types.logicalExpression(\"||\",resultantDecorator,types.Identifier(className)),assignment=types.assignmentExpression(\"=\",types.Identifier(className),resultantDecoratorWithFallback);return types.expressionStatement(assignment)}},decoratorExpressionForMethod=function(decorator,param){return function(className,functionName){var resultantDecorator=types.callExpression(decorator.expression,[types.Identifier(\"\".concat(className,\".prototype\")),types.StringLiteral(functionName),types.NumericLiteral(param.key)]);return types.expressionStatement(resultantDecorator)}};return{visitor:{Program:function(path,state){var extension=(0,_path.extname)(state.file.opts.filename);\".ts\"!==extension&&\".tsx\"!==extension||function(){var decorators=Object.create(null);path.node.body.filter((function(it){var type=it.type,declaration=it.declaration;switch(type){case\"ClassDeclaration\":return!0;case\"ExportNamedDeclaration\":case\"ExportDefaultDeclaration\":return declaration&&\"ClassDeclaration\"===declaration.type;default:return!1}})).map((function(it){return\"ClassDeclaration\"===it.type?it:it.declaration})).forEach((function(clazz){clazz.body.body.forEach((function(body){(body.params||[]).forEach((function(param){(param.decorators||[]).forEach((function(decorator){decorator.expression.callee?decorators[decorator.expression.callee.name]=decorator:decorators[decorator.expression.name]=decorator}))}))}))}));var _iteratorNormalCompletion=!0,_didIteratorError=!1,_iteratorError=void 0;try{for(var _step,_iterator=path.get(\"body\")[Symbol.iterator]();!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=!0){var stmt=_step.value;if(\"ImportDeclaration\"===stmt.node.type){if(0===stmt.node.specifiers.length)continue;var _iteratorNormalCompletion2=!0,_didIteratorError2=!1,_iteratorError2=void 0;try{for(var _step2,_loop=function(){var specifier=_step2.value,binding=stmt.scope.getBinding(specifier.local.name);binding.referencePaths.length?binding.referencePaths.reduce((function(prev,next){return prev||isInType(next)}),!1)&&Object.keys(decorators).forEach((function(k){var decorator=decorators[k];(decorator.expression.arguments||[]).forEach((function(arg){arg.name===specifier.local.name&&binding.referencePaths.push({parent:decorator.expression})}))})):decorators[specifier.local.name]&&binding.referencePaths.push({parent:decorators[specifier.local.name]})},_iterator2=stmt.node.specifiers[Symbol.iterator]();!(_iteratorNormalCompletion2=(_step2=_iterator2.next()).done);_iteratorNormalCompletion2=!0)_loop()}catch(err){_didIteratorError2=!0,_iteratorError2=err}finally{try{_iteratorNormalCompletion2||null==_iterator2.return||_iterator2.return()}finally{if(_didIteratorError2)throw _iteratorError2}}}}}catch(err){_didIteratorError=!0,_iteratorError=err}finally{try{_iteratorNormalCompletion||null==_iterator.return||_iterator.return()}finally{if(_didIteratorError)throw _iteratorError}}}()},Function:function(path){var functionName=\"\";path.node.id?functionName=path.node.id.name:path.node.key&&(functionName=path.node.key.name),(path.get(\"params\")||[]).slice().forEach((function(param){var decorators=param.node.decorators||[],transformable=decorators.length;if(decorators.slice().forEach((function(decorator){if(\"ClassMethod\"===path.type){var classIdentifier,parentNode=path.parentPath.parentPath,classDeclaration=path.findParent((function(p){return\"ClassDeclaration\"===p.type}));if(classDeclaration?classIdentifier=classDeclaration.node.id.name:(parentNode.insertAfter(null),classIdentifier=function(path){var assignment=path.findParent((function(p){return\"AssignmentExpression\"===p.node.type}));return\"SequenceExpression\"===assignment.node.right.type?assignment.node.right.expressions[1].name:\"ClassExpression\"===assignment.node.right.type?assignment.node.left.name:null}(path)),\"constructor\"===functionName){var expression=decoratorExpressionForConstructor(decorator,param)(classIdentifier);parentNode.insertAfter(expression)}else{var _expression=decoratorExpressionForMethod(decorator,param)(classIdentifier,functionName);parentNode.insertAfter(_expression)}}else{var className=path.findParent((function(p){return\"VariableDeclarator\"===p.node.type})).node.id.name;if(functionName===className){var _expression2=decoratorExpressionForConstructor(decorator,param)(className);if(\"body\"===path.parentKey)path.insertAfter(_expression2);else path.findParent((function(p){return\"body\"===p.parentKey})).insertAfter(_expression2)}else{var classParent=path.findParent((function(p){return\"CallExpression\"===p.node.type})),_expression3=decoratorExpressionForMethod(decorator,param)(className,functionName);classParent.insertAfter(_expression3)}}})),transformable){var replacement=function(path){switch(path.node.type){case\"ObjectPattern\":return types.ObjectPattern(path.node.properties);case\"AssignmentPattern\":return types.AssignmentPattern(path.node.left,path.node.right);case\"TSParameterProperty\":return types.Identifier(path.node.parameter.name);default:return types.Identifier(path.node.name)}}(param);param.replaceWith(replacement)}}))}}}}},\"./node_modules/.pnpm/convert-source-map@1.8.0/node_modules/convert-source-map/index.js\":(__unused_webpack_module,exports,__webpack_require__)=>{\"use strict\";var fs=__webpack_require__(\"fs\"),path=__webpack_require__(\"path\"),SafeBuffer=__webpack_require__(\"./node_modules/.pnpm/safe-buffer@5.1.2/node_modules/safe-buffer/index.js\");function Converter(sm,opts){var base64;(opts=opts||{}).isFileComment&&(sm=function(sm,dir){var r=exports.mapFileCommentRegex.exec(sm),filename=r[1]||r[2],filepath=path.resolve(dir,filename);try{return fs.readFileSync(filepath,\"utf8\")}catch(e){throw new Error(\"An error occurred while trying to read the map file at \"+filepath+\"\\n\"+e)}}(sm,opts.commentFileDir)),opts.hasComment&&(sm=function(sm){return sm.split(\",\").pop()}(sm)),opts.isEncoded&&(base64=sm,sm=(SafeBuffer.Buffer.from(base64,\"base64\")||\"\").toString()),(opts.isJSON||opts.isEncoded)&&(sm=JSON.parse(sm)),this.sourcemap=sm}Object.defineProperty(exports,\"commentRegex\",{get:function(){return/^\\s*\\/(?:\\/|\\*)[@#]\\s+sourceMappingURL=data:(?:application|text)\\/json;(?:charset[:=]\\S+?;)?base64,(?:.*)$/gm}}),Object.defineProperty(exports,\"mapFileCommentRegex\",{get:function(){return/(?:\\/\\/[@#][ \\t]+sourceMappingURL=([^\\s'\"`]+?)[ \\t]*$)|(?:\\/\\*[@#][ \\t]+sourceMappingURL=([^\\*]+?)[ \\t]*(?:\\*\\/){1}[ \\t]*$)/gm}}),Converter.prototype.toJSON=function(space){return JSON.stringify(this.sourcemap,null,space)},Converter.prototype.toBase64=function(){var json=this.toJSON();return(SafeBuffer.Buffer.from(json,\"utf8\")||\"\").toString(\"base64\")},Converter.prototype.toComment=function(options){var data=\"sourceMappingURL=data:application/json;charset=utf-8;base64,\"+this.toBase64();return options&&options.multiline?\"/*# \"+data+\" */\":\"//# \"+data},Converter.prototype.toObject=function(){return JSON.parse(this.toJSON())},Converter.prototype.addProperty=function(key,value){if(this.sourcemap.hasOwnProperty(key))throw new Error('property \"'+key+'\" already exists on the sourcemap, use set property instead');return this.setProperty(key,value)},Converter.prototype.setProperty=function(key,value){return this.sourcemap[key]=value,this},Converter.prototype.getProperty=function(key){return this.sourcemap[key]},exports.fromObject=function(obj){return new Converter(obj)},exports.fromJSON=function(json){return new Converter(json,{isJSON:!0})},exports.fromBase64=function(base64){return new Converter(base64,{isEncoded:!0})},exports.fromComment=function(comment){return new Converter(comment=comment.replace(/^\\/\\*/g,\"//\").replace(/\\*\\/$/g,\"\"),{isEncoded:!0,hasComment:!0})},exports.fromMapFileComment=function(comment,dir){return new Converter(comment,{commentFileDir:dir,isFileComment:!0,isJSON:!0})},exports.fromSource=function(content){var m=content.match(exports.commentRegex);return m?exports.fromComment(m.pop()):null},exports.fromMapFileSource=function(content,dir){var m=content.match(exports.mapFileCommentRegex);return m?exports.fromMapFileComment(m.pop(),dir):null},exports.removeComments=function(src){return src.replace(exports.commentRegex,\"\")},exports.removeMapFileComments=function(src){return src.replace(exports.mapFileCommentRegex,\"\")},exports.generateMapFileComment=function(file,options){var data=\"sourceMappingURL=\"+file;return options&&options.multiline?\"/*# \"+data+\" */\":\"//# \"+data}},\"./node_modules/.pnpm/debug@4.3.4/node_modules/debug/src/browser.js\":(module,exports,__webpack_require__)=>{exports.formatArgs=function(args){if(args[0]=(this.useColors?\"%c\":\"\")+this.namespace+(this.useColors?\" %c\":\" \")+args[0]+(this.useColors?\"%c \":\" \")+\"+\"+module.exports.humanize(this.diff),!this.useColors)return;const c=\"color: \"+this.color;args.splice(1,0,c,\"color: inherit\");let index=0,lastC=0;args[0].replace(/%[a-zA-Z%]/g,(match=>{\"%%\"!==match&&(index++,\"%c\"===match&&(lastC=index))})),args.splice(lastC,0,c)},exports.save=function(namespaces){try{namespaces?exports.storage.setItem(\"debug\",namespaces):exports.storage.removeItem(\"debug\")}catch(error){}},exports.load=function(){let r;try{r=exports.storage.getItem(\"debug\")}catch(error){}!r&&\"undefined\"!=typeof process&&\"env\"in process&&(r=process.env.DEBUG);return r},exports.useColors=function(){if(\"undefined\"!=typeof window&&window.process&&(\"renderer\"===window.process.type||window.process.__nwjs))return!0;if(\"undefined\"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\\/(\\d+)/))return!1;return\"undefined\"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||\"undefined\"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||\"undefined\"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\\/(\\d+)/)&&parseInt(RegExp.$1,10)>=31||\"undefined\"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\\/(\\d+)/)},exports.storage=function(){try{return localStorage}catch(error){}}(),exports.destroy=(()=>{let warned=!1;return()=>{warned||(warned=!0,console.warn(\"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.\"))}})(),exports.colors=[\"#0000CC\",\"#0000FF\",\"#0033CC\",\"#0033FF\",\"#0066CC\",\"#0066FF\",\"#0099CC\",\"#0099FF\",\"#00CC00\",\"#00CC33\",\"#00CC66\",\"#00CC99\",\"#00CCCC\",\"#00CCFF\",\"#3300CC\",\"#3300FF\",\"#3333CC\",\"#3333FF\",\"#3366CC\",\"#3366FF\",\"#3399CC\",\"#3399FF\",\"#33CC00\",\"#33CC33\",\"#33CC66\",\"#33CC99\",\"#33CCCC\",\"#33CCFF\",\"#6600CC\",\"#6600FF\",\"#6633CC\",\"#6633FF\",\"#66CC00\",\"#66CC33\",\"#9900CC\",\"#9900FF\",\"#9933CC\",\"#9933FF\",\"#99CC00\",\"#99CC33\",\"#CC0000\",\"#CC0033\",\"#CC0066\",\"#CC0099\",\"#CC00CC\",\"#CC00FF\",\"#CC3300\",\"#CC3333\",\"#CC3366\",\"#CC3399\",\"#CC33CC\",\"#CC33FF\",\"#CC6600\",\"#CC6633\",\"#CC9900\",\"#CC9933\",\"#CCCC00\",\"#CCCC33\",\"#FF0000\",\"#FF0033\",\"#FF0066\",\"#FF0099\",\"#FF00CC\",\"#FF00FF\",\"#FF3300\",\"#FF3333\",\"#FF3366\",\"#FF3399\",\"#FF33CC\",\"#FF33FF\",\"#FF6600\",\"#FF6633\",\"#FF9900\",\"#FF9933\",\"#FFCC00\",\"#FFCC33\"],exports.log=console.debug||console.log||(()=>{}),module.exports=__webpack_require__(\"./node_modules/.pnpm/debug@4.3.4/node_modules/debug/src/common.js\")(exports);const{formatters}=module.exports;formatters.j=function(v){try{return JSON.stringify(v)}catch(error){return\"[UnexpectedJSONParseError]: \"+error.message}}},\"./node_modules/.pnpm/debug@4.3.4/node_modules/debug/src/common.js\":(module,__unused_webpack_exports,__webpack_require__)=>{module.exports=function(env){function createDebug(namespace){let prevTime,namespacesCache,enabledCache,enableOverride=null;function debug(...args){if(!debug.enabled)return;const self=debug,curr=Number(new Date),ms=curr-(prevTime||curr);self.diff=ms,self.prev=prevTime,self.curr=curr,prevTime=curr,args[0]=createDebug.coerce(args[0]),\"string\"!=typeof args[0]&&args.unshift(\"%O\");let index=0;args[0]=args[0].replace(/%([a-zA-Z%])/g,((match,format)=>{if(\"%%\"===match)return\"%\";index++;const formatter=createDebug.formatters[format];if(\"function\"==typeof formatter){const val=args[index];match=formatter.call(self,val),args.splice(index,1),index--}return match})),createDebug.formatArgs.call(self,args);(self.log||createDebug.log).apply(self,args)}return debug.namespace=namespace,debug.useColors=createDebug.useColors(),debug.color=createDebug.selectColor(namespace),debug.extend=extend,debug.destroy=createDebug.destroy,Object.defineProperty(debug,\"enabled\",{enumerable:!0,configurable:!1,get:()=>null!==enableOverride?enableOverride:(namespacesCache!==createDebug.namespaces&&(namespacesCache=createDebug.namespaces,enabledCache=createDebug.enabled(namespace)),enabledCache),set:v=>{enableOverride=v}}),\"function\"==typeof createDebug.init&&createDebug.init(debug),debug}function extend(namespace,delimiter){const newDebug=createDebug(this.namespace+(void 0===delimiter?\":\":delimiter)+namespace);return newDebug.log=this.log,newDebug}function toNamespace(regexp){return regexp.toString().substring(2,regexp.toString().length-2).replace(/\\.\\*\\?$/,\"*\")}return createDebug.debug=createDebug,createDebug.default=createDebug,createDebug.coerce=function(val){if(val instanceof Error)return val.stack||val.message;return val},createDebug.disable=function(){const namespaces=[...createDebug.names.map(toNamespace),...createDebug.skips.map(toNamespace).map((namespace=>\"-\"+namespace))].join(\",\");return createDebug.enable(\"\"),namespaces},createDebug.enable=function(namespaces){let i;createDebug.save(namespaces),createDebug.namespaces=namespaces,createDebug.names=[],createDebug.skips=[];const split=(\"string\"==typeof namespaces?namespaces:\"\").split(/[\\s,]+/),len=split.length;for(i=0;i{createDebug[key]=env[key]})),createDebug.names=[],createDebug.skips=[],createDebug.formatters={},createDebug.selectColor=function(namespace){let hash=0;for(let i=0;i{\"undefined\"==typeof process||\"renderer\"===process.type||!0===process.browser||process.__nwjs?module.exports=__webpack_require__(\"./node_modules/.pnpm/debug@4.3.4/node_modules/debug/src/browser.js\"):module.exports=__webpack_require__(\"./node_modules/.pnpm/debug@4.3.4/node_modules/debug/src/node.js\")},\"./node_modules/.pnpm/debug@4.3.4/node_modules/debug/src/node.js\":(module,exports,__webpack_require__)=>{const tty=__webpack_require__(\"tty\"),util=__webpack_require__(\"util\");exports.init=function(debug){debug.inspectOpts={};const keys=Object.keys(exports.inspectOpts);for(let i=0;i{}),\"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.\"),exports.colors=[6,2,3,4,5,1];try{const supportsColor=__webpack_require__(\"./node_modules/.pnpm/supports-color@5.5.0/node_modules/supports-color/index.js\");supportsColor&&(supportsColor.stderr||supportsColor).level>=2&&(exports.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221])}catch(error){}exports.inspectOpts=Object.keys(process.env).filter((key=>/^debug_/i.test(key))).reduce(((obj,key)=>{const prop=key.substring(6).toLowerCase().replace(/_([a-z])/g,((_,k)=>k.toUpperCase()));let val=process.env[key];return val=!!/^(yes|on|true|enabled)$/i.test(val)||!/^(no|off|false|disabled)$/i.test(val)&&(\"null\"===val?null:Number(val)),obj[prop]=val,obj}),{}),module.exports=__webpack_require__(\"./node_modules/.pnpm/debug@4.3.4/node_modules/debug/src/common.js\")(exports);const{formatters}=module.exports;formatters.o=function(v){return this.inspectOpts.colors=this.useColors,util.inspect(v,this.inspectOpts).split(\"\\n\").map((str=>str.trim())).join(\" \")},formatters.O=function(v){return this.inspectOpts.colors=this.useColors,util.inspect(v,this.inspectOpts)}},\"./node_modules/.pnpm/gensync@1.0.0-beta.2/node_modules/gensync/index.js\":module=>{\"use strict\";const GENSYNC_START=Symbol.for(\"gensync:v1:start\"),GENSYNC_SUSPEND=Symbol.for(\"gensync:v1:suspend\");function assertTypeof(type,name,value,allowUndefined){if(typeof value===type||allowUndefined&&void 0===value)return;let msg;throw msg=allowUndefined?`Expected opts.${name} to be either a ${type}, or undefined.`:`Expected opts.${name} to be a ${type}.`,makeError(msg,\"GENSYNC_OPTIONS_ERROR\")}function makeError(msg,code){return Object.assign(new Error(msg),{code})}function buildOperation({name,arity,sync,async}){return setFunctionMetadata(name,arity,(function*(...args){const resume=yield GENSYNC_START;if(!resume){return sync.call(this,args)}let result;try{async.call(this,args,(value=>{result||(result={value},resume())}),(err=>{result||(result={err},resume())}))}catch(err){result={err},resume()}if(yield GENSYNC_SUSPEND,result.hasOwnProperty(\"err\"))throw result.err;return result.value}))}function evaluateSync(gen){let value;for(;!({value}=gen.next()).done;)assertStart(value,gen);return value}function evaluateAsync(gen,resolve,reject){!function step(){try{let value;for(;!({value}=gen.next()).done;){assertStart(value,gen);let sync=!0,didSyncResume=!1;const out=gen.next((()=>{sync?didSyncResume=!0:step()}));if(sync=!1,assertSuspend(out,gen),!didSyncResume)return}return resolve(value)}catch(err){return reject(err)}}()}function assertStart(value,gen){value!==GENSYNC_START&&throwError(gen,makeError(`Got unexpected yielded value in gensync generator: ${JSON.stringify(value)}. Did you perhaps mean to use 'yield*' instead of 'yield'?`,\"GENSYNC_EXPECTED_START\"))}function assertSuspend({value,done},gen){(done||value!==GENSYNC_SUSPEND)&&throwError(gen,makeError(done?\"Unexpected generator completion. If you get this, it is probably a gensync bug.\":`Expected GENSYNC_SUSPEND, got ${JSON.stringify(value)}. If you get this, it is probably a gensync bug.`,\"GENSYNC_EXPECTED_SUSPEND\"))}function throwError(gen,err){throw gen.throw&&gen.throw(err),err}function setFunctionMetadata(name,arity,fn){if(\"string\"==typeof name){const nameDesc=Object.getOwnPropertyDescriptor(fn,\"name\");nameDesc&&!nameDesc.configurable||Object.defineProperty(fn,\"name\",Object.assign(nameDesc||{},{configurable:!0,value:name}))}if(\"number\"==typeof arity){const lengthDesc=Object.getOwnPropertyDescriptor(fn,\"length\");lengthDesc&&!lengthDesc.configurable||Object.defineProperty(fn,\"length\",Object.assign(lengthDesc||{},{configurable:!0,value:arity}))}return fn}module.exports=Object.assign((function(optsOrFn){let genFn=optsOrFn;return genFn=\"function\"!=typeof optsOrFn?function({name,arity,sync,async,errback}){if(assertTypeof(\"string\",\"name\",name,!0),assertTypeof(\"number\",\"arity\",arity,!0),assertTypeof(\"function\",\"sync\",sync),assertTypeof(\"function\",\"async\",async,!0),assertTypeof(\"function\",\"errback\",errback,!0),async&&errback)throw makeError(\"Expected one of either opts.async or opts.errback, but got _both_.\",\"GENSYNC_OPTIONS_ERROR\");if(\"string\"!=typeof name){let fnName;errback&&errback.name&&\"errback\"!==errback.name&&(fnName=errback.name),async&&async.name&&\"async\"!==async.name&&(fnName=async.name.replace(/Async$/,\"\")),sync&&sync.name&&\"sync\"!==sync.name&&(fnName=sync.name.replace(/Sync$/,\"\")),\"string\"==typeof fnName&&(name=fnName)}\"number\"!=typeof arity&&(arity=sync.length);return buildOperation({name,arity,sync:function(args){return sync.apply(this,args)},async:function(args,resolve,reject){async?async.apply(this,args).then(resolve,reject):errback?errback.call(this,...args,((err,value)=>{null==err?resolve(value):reject(err)})):resolve(sync.apply(this,args))}})}(optsOrFn):function(genFn){return setFunctionMetadata(genFn.name,genFn.length,(function(...args){return genFn.apply(this,args)}))}(optsOrFn),Object.assign(genFn,function(genFn){return{sync:function(...args){return evaluateSync(genFn.apply(this,args))},async:function(...args){return new Promise(((resolve,reject)=>{evaluateAsync(genFn.apply(this,args),resolve,reject)}))},errback:function(...args){const cb=args.pop();if(\"function\"!=typeof cb)throw makeError(\"Asynchronous function called without callback\",\"GENSYNC_ERRBACK_NO_CALLBACK\");let gen;try{gen=genFn.apply(this,args)}catch(err){return void cb(err)}evaluateAsync(gen,(val=>cb(void 0,val)),(err=>cb(err)))}}}(genFn))}),{all:buildOperation({name:\"all\",arity:1,sync:function(args){return Array.from(args[0]).map((item=>evaluateSync(item)))},async:function(args,resolve,reject){const items=Array.from(args[0]);if(0===items.length)return void Promise.resolve().then((()=>resolve([])));let count=0;const results=items.map((()=>{}));items.forEach(((item,i)=>{evaluateAsync(item,(val=>{results[i]=val,count+=1,count===results.length&&resolve(results)}),reject)}))}}),race:buildOperation({name:\"race\",arity:1,sync:function(args){const items=Array.from(args[0]);if(0===items.length)throw makeError(\"Must race at least 1 item\",\"GENSYNC_RACE_NONEMPTY\");return evaluateSync(items[0])},async:function(args,resolve,reject){const items=Array.from(args[0]);if(0===items.length)throw makeError(\"Must race at least 1 item\",\"GENSYNC_RACE_NONEMPTY\");for(const item of items)evaluateAsync(item,resolve,reject)}})})},\"./node_modules/.pnpm/globals@11.12.0/node_modules/globals/index.js\":(module,__unused_webpack_exports,__webpack_require__)=>{\"use strict\";module.exports=__webpack_require__(\"./node_modules/.pnpm/globals@11.12.0/node_modules/globals/globals.json\")},\"./node_modules/.pnpm/has-flag@3.0.0/node_modules/has-flag/index.js\":module=>{\"use strict\";module.exports=(flag,argv)=>{argv=argv||process.argv;const prefix=flag.startsWith(\"-\")?\"\":1===flag.length?\"-\":\"--\",pos=argv.indexOf(prefix+flag),terminatorPos=argv.indexOf(\"--\");return-1!==pos&&(-1===terminatorPos||pos{\"use strict\";const object={},hasOwnProperty=object.hasOwnProperty,forOwn=(object,callback)=>{for(const key in object)hasOwnProperty.call(object,key)&&callback(key,object[key])},toString=object.toString,isArray=Array.isArray,isBuffer=Buffer.isBuffer,singleEscapes={'\"':'\\\\\"',\"'\":\"\\\\'\",\"\\\\\":\"\\\\\\\\\",\"\\b\":\"\\\\b\",\"\\f\":\"\\\\f\",\"\\n\":\"\\\\n\",\"\\r\":\"\\\\r\",\"\\t\":\"\\\\t\"},regexSingleEscape=/[\"'\\\\\\b\\f\\n\\r\\t]/,regexDigit=/[0-9]/,regexWhitelist=/[ !#-&\\(-\\[\\]-_a-~]/,jsesc=(argument,options)=>{const increaseIndentation=()=>{oldIndent=indent,++options.indentLevel,indent=options.indent.repeat(options.indentLevel)},defaults={escapeEverything:!1,minimal:!1,isScriptContext:!1,quotes:\"single\",wrap:!1,es6:!1,json:!1,compact:!0,lowercaseHex:!1,numbers:\"decimal\",indent:\"\\t\",indentLevel:0,__inline1__:!1,__inline2__:!1},json=options&&options.json;var destination,source;json&&(defaults.quotes=\"double\",defaults.wrap=!0),destination=defaults,options=(source=options)?(forOwn(source,((key,value)=>{destination[key]=value})),destination):destination,\"single\"!=options.quotes&&\"double\"!=options.quotes&&\"backtick\"!=options.quotes&&(options.quotes=\"single\");const quote=\"double\"==options.quotes?'\"':\"backtick\"==options.quotes?\"`\":\"'\",compact=options.compact,lowercaseHex=options.lowercaseHex;let indent=options.indent.repeat(options.indentLevel),oldIndent=\"\";const inline1=options.__inline1__,inline2=options.__inline2__,newLine=compact?\"\":\"\\n\";let result,isEmpty=!0;const useBinNumbers=\"binary\"==options.numbers,useOctNumbers=\"octal\"==options.numbers,useDecNumbers=\"decimal\"==options.numbers,useHexNumbers=\"hexadecimal\"==options.numbers;if(json&&argument&&\"function\"==typeof argument.toJSON&&(argument=argument.toJSON()),!(value=>\"string\"==typeof value||\"[object String]\"==toString.call(value))(argument)){if((value=>\"[object Map]\"==toString.call(value))(argument))return 0==argument.size?\"new Map()\":(compact||(options.__inline1__=!0,options.__inline2__=!1),\"new Map(\"+jsesc(Array.from(argument),options)+\")\");if((value=>\"[object Set]\"==toString.call(value))(argument))return 0==argument.size?\"new Set()\":\"new Set(\"+jsesc(Array.from(argument),options)+\")\";if(isBuffer(argument))return 0==argument.length?\"Buffer.from([])\":\"Buffer.from(\"+jsesc(Array.from(argument),options)+\")\";if(isArray(argument))return result=[],options.wrap=!0,inline1&&(options.__inline1__=!1,options.__inline2__=!0),inline2||increaseIndentation(),((array,callback)=>{const length=array.length;let index=-1;for(;++index{isEmpty=!1,inline2&&(options.__inline2__=!1),result.push((compact||inline2?\"\":indent)+jsesc(value,options))})),isEmpty?\"[]\":inline2?\"[\"+result.join(\", \")+\"]\":\"[\"+newLine+result.join(\",\"+newLine)+newLine+(compact?\"\":oldIndent)+\"]\";if(!(value=>\"number\"==typeof value||\"[object Number]\"==toString.call(value))(argument))return(value=>\"[object Object]\"==toString.call(value))(argument)?(result=[],options.wrap=!0,increaseIndentation(),forOwn(argument,((key,value)=>{isEmpty=!1,result.push((compact?\"\":indent)+jsesc(key,options)+\":\"+(compact?\"\":\" \")+jsesc(value,options))})),isEmpty?\"{}\":\"{\"+newLine+result.join(\",\"+newLine)+newLine+(compact?\"\":oldIndent)+\"}\"):json?JSON.stringify(argument)||\"null\":String(argument);if(json)return JSON.stringify(argument);if(useDecNumbers)return String(argument);if(useHexNumbers){let hexadecimal=argument.toString(16);return lowercaseHex||(hexadecimal=hexadecimal.toUpperCase()),\"0x\"+hexadecimal}if(useBinNumbers)return\"0b\"+argument.toString(2);if(useOctNumbers)return\"0o\"+argument.toString(8)}const string=argument;let index=-1;const length=string.length;for(result=\"\";++index=55296&&first<=56319&&length>index+1){const second=string.charCodeAt(index+1);if(second>=56320&&second<=57343){let hexadecimal=(1024*(first-55296)+second-56320+65536).toString(16);lowercaseHex||(hexadecimal=hexadecimal.toUpperCase()),result+=\"\\\\u{\"+hexadecimal+\"}\",++index;continue}}}if(!options.escapeEverything){if(regexWhitelist.test(character)){result+=character;continue}if('\"'==character){result+=quote==character?'\\\\\"':character;continue}if(\"`\"==character){result+=quote==character?\"\\\\`\":character;continue}if(\"'\"==character){result+=quote==character?\"\\\\'\":character;continue}}if(\"\\0\"==character&&!json&&!regexDigit.test(string.charAt(index+1))){result+=\"\\\\0\";continue}if(regexSingleEscape.test(character)){result+=singleEscapes[character];continue}const charCode=character.charCodeAt(0);if(options.minimal&&8232!=charCode&&8233!=charCode){result+=character;continue}let hexadecimal=charCode.toString(16);lowercaseHex||(hexadecimal=hexadecimal.toUpperCase());const longhand=hexadecimal.length>2||json,escaped=\"\\\\\"+(longhand?\"u\":\"x\")+(\"0000\"+hexadecimal).slice(longhand?-4:-2);result+=escaped}return options.wrap&&(result=quote+result+quote),\"`\"==quote&&(result=result.replace(/\\$\\{/g,\"\\\\${\")),options.isScriptContext?result.replace(/<\\/(script|style)/gi,\"<\\\\/$1\").replace(/`;\n};\n", "import { getOctokit } from '@actions/github';\n\nimport { getReportTag } from '../constants/getReportTag';\nimport { Options } from '../typings/Options';\n\nexport async function fetchPreviousReport(\n octokit: ReturnType,\n repo: { owner: string; repo: string },\n pr: { number: number },\n options: Options\n) {\n const commentList = await octokit.paginate(\n 'GET /repos/{owner}/{repo}/issues/{issue_number}/comments',\n {\n ...repo,\n issue_number: pr.number,\n }\n );\n\n const previousReport = commentList.find((comment) =>\n comment.body?.startsWith(getReportTag(options))\n );\n\n return !previousReport ? null : previousReport;\n}\n", "import { getOctokit } from '@actions/github';\n\nimport { fetchPreviousReport } from './fetchPreviousReport';\nimport { Options } from '../typings/Options';\n\nexport const generatePRReport = async (\n report: string,\n options: Options,\n repo: { owner: string; repo: string },\n pr: { number: number },\n octokit: ReturnType\n) => {\n const previousReport = await fetchPreviousReport(\n octokit,\n repo,\n pr,\n options\n );\n\n if (previousReport) {\n await octokit.rest.issues.updateComment({\n ...repo,\n body: report,\n comment_id: previousReport.id,\n });\n } else {\n await octokit.rest.issues.createComment({\n ...repo,\n body: report,\n issue_number: pr.number,\n });\n }\n};\n", "import { dirname } from 'path';\r\n\r\nimport isNil from 'lodash/isNil';\r\nimport micromatch from 'micromatch';\r\n\r\nimport { JestThreshold } from '../typings/JestThreshold';\r\nimport { JsonReport } from '../typings/JsonReport';\r\nimport { FailReason } from '../typings/Report';\r\nimport { ThresholdResult } from '../typings/ThresholdResult';\r\nimport { accumulateCoverageDetails } from '../utils/accumulateCoverageDetails';\r\nimport { checkSingleThreshold } from '../utils/checkSingleThreshold';\r\nimport { DataCollector } from '../utils/DataCollector';\r\nimport { getCoverageForDirectory } from '../utils/getCoverageForDirectory';\r\nimport { getFileCoverageMap } from '../utils/getFileCoverageMap';\r\nimport { joinPaths } from '../utils/joinPaths';\r\n\r\nexport const checkThreshold = (\r\n report: JsonReport,\r\n threshold: JestThreshold,\r\n workingDirectory: string | undefined,\r\n dataCollector: DataCollector\r\n) => {\r\n const cwd = joinPaths(process.cwd(), workingDirectory);\r\n // Maybe somehow take this from \"format\" stage?\r\n const coverageDetailMap = Object.fromEntries(\r\n Object.entries(getFileCoverageMap(report)).map(([key, value]) => [\r\n key.substring(cwd.length + 1),\r\n value,\r\n ])\r\n );\r\n\r\n const dirSet = new Set();\r\n\r\n Object.keys(coverageDetailMap)\r\n .filter((value) => value === 'global')\r\n .forEach((value) => {\r\n let directory = dirname(value);\r\n\r\n while (directory !== '.') {\r\n dirSet.add(directory);\r\n directory = dirname(directory);\r\n }\r\n });\r\n\r\n const directories = Array.from(dirSet);\r\n\r\n const totalResults: ThresholdResult[] = [];\r\n\r\n Object.entries(threshold).forEach(([pattern, threshold]) => {\r\n const selectedDirectories = micromatch(directories, pattern);\r\n\r\n const coverageOfDirectories = selectedDirectories.map((directory) =>\r\n getCoverageForDirectory(directory, coverageDetailMap)\r\n );\r\n\r\n const thresholdResults = coverageOfDirectories.map((coverage, index) =>\r\n checkSingleThreshold(\r\n threshold,\r\n coverage,\r\n selectedDirectories[index]\r\n )\r\n );\r\n\r\n totalResults.push(\r\n ...(thresholdResults.filter(\r\n (value) => value !== undefined\r\n ) as ThresholdResult[])\r\n );\r\n });\r\n\r\n const files = Object.keys(coverageDetailMap);\r\n Object.entries(threshold).forEach(([pattern, threshold]) => {\r\n const selectedFiles = micromatch(files, pattern);\r\n\r\n const thresholdResults = selectedFiles.map((filename) =>\r\n checkSingleThreshold(\r\n threshold,\r\n coverageDetailMap[filename],\r\n filename\r\n )\r\n );\r\n\r\n totalResults.push(\r\n ...(thresholdResults.filter(\r\n (value) => value !== undefined\r\n ) as ThresholdResult[])\r\n );\r\n });\r\n\r\n if (!isNil(threshold.global)) {\r\n const uncheckedFiles = micromatch.not(\r\n files,\r\n Object.keys(threshold).concat(\r\n micromatch(directories, Object.keys(threshold)).map(\r\n (value) => `${value}/**`\r\n )\r\n )\r\n );\r\n\r\n const uncheckedTotal = accumulateCoverageDetails(\r\n uncheckedFiles.map((filename) => coverageDetailMap[filename])\r\n );\r\n\r\n const globalResult = checkSingleThreshold(\r\n threshold.global,\r\n uncheckedTotal,\r\n 'global'\r\n );\r\n\r\n if (globalResult) {\r\n totalResults.push(globalResult);\r\n }\r\n }\r\n\r\n if (totalResults.length > 0) {\r\n dataCollector.add(FailReason.UNDER_THRESHOLD);\r\n }\r\n\r\n return totalResults;\r\n};\r\n", "export enum FailReason {\n TESTS_FAILED = 'testsFailed',\n INVALID_COVERAGE_FORMAT = 'invalidFormat',\n UNDER_THRESHOLD = 'underThreshold',\n UNKNOWN_ERROR = 'unknownError',\n REPORT_NOT_FOUND = 'reportNotFound',\n READING_COVERAGE_FILE_FAILED = 'readingCoverageFileFailed',\n FAILED_GETTING_COVERAGE = 'failedGettingCoverage',\n}\n\nexport type TestRunReport = {\n title: string;\n summary: string;\n failures?: string;\n};\n\nexport type SummaryReport = {\n text: string;\n runReport: TestRunReport;\n};\n", "import { DetailedFileCoverage } from './getFileCoverageMap';\r\n\r\nexport const accumulateCoverageDetails = (\r\n coverageDetails: DetailedFileCoverage[]\r\n): DetailedFileCoverage =>\r\n coverageDetails.reduce(\r\n (acc, current) => {\r\n acc.totalStatements += current.totalStatements;\r\n acc.coveredStatements += current.coveredStatements;\r\n acc.totalFunctions += current.totalFunctions;\r\n acc.coveredFunctions += current.coveredFunctions;\r\n acc.totalBranches += current.totalBranches;\r\n acc.coveredBranches += current.coveredBranches;\r\n acc.totalLines += current.totalLines;\r\n acc.coveredLines += current.coveredLines;\r\n\r\n return acc;\r\n },\r\n {\r\n totalStatements: 0,\r\n coveredStatements: 0,\r\n totalFunctions: 0,\r\n coveredFunctions: 0,\r\n totalBranches: 0,\r\n coveredBranches: 0,\r\n totalLines: 0,\r\n coveredLines: 0,\r\n }\r\n );\r\n", "import isNil from 'lodash/isNil';\r\n\r\nimport { DetailedFileCoverage } from './getFileCoverageMap';\r\nimport { getPercents } from '../format/getPercents';\r\nimport { SingleThreshold } from '../typings/JestThreshold';\r\nimport { ThresholdResult, ThresholdType } from '../typings/ThresholdResult';\r\n\r\nexport const checkSingleThreshold = (\r\n threshold: SingleThreshold,\r\n coverage: DetailedFileCoverage,\r\n path: string\r\n): ThresholdResult | undefined => {\r\n const queue = [\r\n {\r\n total: coverage.totalStatements,\r\n covered: coverage.coveredStatements,\r\n threshold: threshold.statements,\r\n type: ThresholdType.STATEMENTS,\r\n },\r\n {\r\n total: coverage.totalBranches,\r\n covered: coverage.coveredBranches,\r\n threshold: threshold.branches,\r\n type: ThresholdType.BRANCHES,\r\n },\r\n {\r\n total: coverage.totalFunctions,\r\n covered: coverage.coveredFunctions,\r\n threshold: threshold.functions,\r\n type: ThresholdType.FUNCTIONS,\r\n },\r\n {\r\n total: coverage.totalLines,\r\n covered: coverage.coveredLines,\r\n threshold: threshold.lines,\r\n type: ThresholdType.LINES,\r\n },\r\n ];\r\n\r\n for (const { total, covered, threshold, type } of queue) {\r\n const result = checkSingleStat(total, covered, threshold, type, path);\r\n\r\n if (result) {\r\n return result;\r\n }\r\n }\r\n\r\n return undefined;\r\n};\r\n\r\nconst checkSingleStat = (\r\n total: number,\r\n covered: number,\r\n threshold: number | undefined,\r\n type: ThresholdType,\r\n path: string\r\n): ThresholdResult | undefined => {\r\n if (isNil(threshold)) {\r\n return undefined;\r\n }\r\n\r\n if (threshold >= 0) {\r\n const percents = getPercents(covered, total);\r\n\r\n return percents >= threshold\r\n ? undefined\r\n : {\r\n expected: threshold,\r\n received: percents,\r\n type,\r\n path,\r\n };\r\n }\r\n\r\n return covered >= -threshold\r\n ? undefined\r\n : {\r\n expected: threshold,\r\n received: covered,\r\n type,\r\n path,\r\n };\r\n};\r\n", "export const getPercents = (covered: number, total: number): number => {\n if (total === 0) return 100;\n\n return (covered / total) * 100;\n};\n", "export enum ThresholdType {\r\n STATEMENTS = 'statements',\r\n FUNCTIONS = 'functions',\r\n BRANCHES = 'branches',\r\n LINES = 'lines',\r\n}\r\n\r\nexport type ThresholdResult = {\r\n path: string;\r\n expected: number;\r\n received: number;\r\n type: ThresholdType;\r\n};\r\n", "import micromatch from 'micromatch';\r\n\r\nimport { accumulateCoverageDetails } from './accumulateCoverageDetails';\r\nimport { DetailedFileCoverage, FileCoverageMap } from './getFileCoverageMap';\r\n\r\nexport const getCoverageForDirectory = (\r\n directory: string,\r\n details: FileCoverageMap\r\n): DetailedFileCoverage => {\r\n const children = micromatch(Object.keys(details), `${directory}/**`);\r\n\r\n return accumulateCoverageDetails(children.map((child) => details[child]));\r\n};\r\n", "import { FileCoverage } from '../typings/JsonReport';\n\nexport const standardTotalCounter = (key: keyof FileCoverage) => (\n value: FileCoverage\n) => Object.values(value[key]).length;\n\nexport const standardCoveredCounter = (key: keyof FileCoverage) => (\n value: FileCoverage\n) => Object.values(value[key]).filter((hits) => hits > 0).length;\n\nexport const totalBranchesCounter = (value: FileCoverage) =>\n Object.values(value.b).reduce((acc, branch) => acc + branch.length, 0);\n\nexport const coveredBranchesCounter = (value: FileCoverage) =>\n Object.values(value.b).reduce(\n (acc, branch) => acc + branch.filter((hits) => hits > 0).length,\n 0\n );\n\nexport const totalLinesCounter = (value: FileCoverage) => {\n const stats: Record = getLineCoverage(value);\n return Object.keys(stats).length;\n};\n\nexport const coveredLinesCounter = (value: FileCoverage) => {\n const stats: Record = getLineCoverage(value);\n return Object.values(stats).filter((v) => !!v).length;\n};\n\nconst getLineCoverage = (value: FileCoverage) => {\n const statementMap = value.statementMap;\n const statements = value.s;\n\n return Object.entries(statements).reduce((acc, [st, count]) => {\n const _st: number = parseInt(st);\n\n if (!statementMap[_st]) {\n return acc;\n }\n const { line } = statementMap[_st].start;\n const prevVal = acc[line];\n if (prevVal === undefined || prevVal < count) {\n acc[line] = count;\n }\n return acc;\n }, {} as Record);\n};\n", "import {\r\n coveredBranchesCounter,\r\n coveredLinesCounter,\r\n standardCoveredCounter,\r\n standardTotalCounter,\r\n totalBranchesCounter,\r\n totalLinesCounter,\r\n} from '../format/counters';\r\nimport { JsonReport } from '../typings/JsonReport';\r\n\r\nexport type DetailedFileCoverage = {\r\n totalStatements: number;\r\n coveredStatements: number;\r\n totalFunctions: number;\r\n coveredFunctions: number;\r\n totalBranches: number;\r\n coveredBranches: number;\r\n totalLines: number;\r\n coveredLines: number;\r\n};\r\n\r\nexport type FileCoverageMap = Record;\r\n\r\nexport const getFileCoverageMap = (jsonReport: JsonReport) =>\r\n Object.entries(jsonReport.coverageMap).reduce(\r\n (acc, [filename, fileCoverage]) => {\r\n acc[filename] = {\r\n totalStatements: standardTotalCounter('s')(fileCoverage),\r\n coveredStatements: standardCoveredCounter('s')(fileCoverage),\r\n totalFunctions: standardTotalCounter('f')(fileCoverage),\r\n coveredFunctions: standardCoveredCounter('f')(fileCoverage),\r\n totalBranches: totalBranchesCounter(fileCoverage),\r\n coveredBranches: coveredBranchesCounter(fileCoverage),\r\n totalLines: totalLinesCounter(fileCoverage),\r\n coveredLines: coveredLinesCounter(fileCoverage),\r\n };\r\n return acc;\r\n },\r\n {}\r\n );\r\n", "import { join } from 'path';\n\nexport const joinPaths = (...segments: Array) =>\n join(...(segments as string[]).filter((segment) => segment !== undefined));\n", "import { context } from '@actions/github';\n\nimport { getReportTag } from '../constants/getReportTag';\nimport { GITHUB_MESSAGE_SIZE_LIMIT } from '../constants/GITHUB_MESSAGE_SIZE_LIMIT';\nimport { formatCoverage } from '../format/formatCoverage';\nimport { formatErrors } from '../format/formatErrors';\nimport { formatRunReport } from '../format/formatRunReport';\nimport { formatThresholdResults } from '../format/formatThresholdResults';\nimport { getFailureDetails } from '../format/getFailureDetails';\nimport { getTestRunSummary } from '../format/summary/getTestRunSummary';\nimport template from '../format/template.md';\nimport { JsonReport } from '../typings/JsonReport';\nimport { Options } from '../typings/Options';\nimport { SummaryReport, TestRunReport } from '../typings/Report';\nimport { ThresholdResult } from '../typings/ThresholdResult';\nimport { DataCollector } from '../utils/DataCollector';\nimport { i18n } from '../utils/i18n';\nimport { insertArgs } from '../utils/insertArgs';\n\nexport const getSha = () =>\n context.payload.after ??\n context.payload.pull_request?.head.sha ??\n context.sha;\n\nexport const createReport = (\n dataCollector: DataCollector,\n options: Options,\n thresholdResults: ThresholdResult[]\n): SummaryReport => {\n const { workingDirectory, customTitle } = options;\n\n const { errors, data } = dataCollector.get();\n const [headReport, baseReport] = data;\n const formattedErrors = formatErrors(errors);\n\n const formattedThresholdResults = formatThresholdResults(thresholdResults);\n const coverage = formatCoverage(headReport, baseReport, undefined, false);\n const runReport: TestRunReport = {\n title: i18n(headReport.success ? 'testsSuccess' : 'testsFail'),\n summary: getTestRunSummary(headReport),\n failures: getFailureDetails(headReport),\n };\n const formattedReport = formatRunReport(runReport);\n\n let templateText = insertArgs(template, {\n body: [\n formattedErrors,\n formattedThresholdResults,\n coverage,\n formattedReport,\n ].join('\\n'),\n dir: workingDirectory || '',\n tag: getReportTag(options),\n title: insertArgs(customTitle || i18n('summaryTitle'), {\n dir: workingDirectory ? `for \\`${workingDirectory}\\`` : '',\n }),\n sha: getSha(),\n });\n\n if (templateText.length > GITHUB_MESSAGE_SIZE_LIMIT) {\n const reducedCoverage = formatCoverage(\n headReport,\n baseReport,\n undefined,\n true\n );\n\n templateText = insertArgs(template, {\n body: [\n formattedErrors,\n formattedThresholdResults,\n reducedCoverage,\n formattedReport,\n ].join('\\n'),\n dir: workingDirectory || '',\n tag: getReportTag(options),\n title: insertArgs(customTitle || i18n('summaryTitle'), {\n dir: workingDirectory ? `for \\`${workingDirectory}\\`` : '',\n }),\n sha: getSha(),\n });\n }\n\n return {\n text: templateText,\n runReport,\n };\n};\n", "export const GITHUB_MESSAGE_SIZE_LIMIT = 65535;\n", "import { dirname } from 'path';\n\n/**\n * Find a common path from a list of filepaths.\n */\nexport const findCommonPath = (filepaths: string[]): string => {\n let commonRoot = '';\n if (filepaths.length) {\n // If the paths are sorted, any prefix common to all paths will be common to the sorted first and last strings.\n const sortedPaths = [...filepaths].sort();\n const first = sortedPaths[0];\n const last = sortedPaths[sortedPaths.length - 1];\n\n const len = Math.min(first.length, last.length);\n for (let i = 0; i < len; i++) {\n const ch1 = first[i];\n const ch2 = last[i];\n if (ch1 == ch2) {\n commonRoot += ch1;\n } else {\n break;\n }\n }\n\n // If it doesn't appear to be a directory (partial filename), get the parent directory\n if (commonRoot.length && commonRoot[commonRoot.length - 1] !== '/') {\n commonRoot = dirname(commonRoot) + '/';\n }\n }\n return commonRoot;\n};\n", "import { findCommonPath } from './findCommonPath';\nimport { CoverageDetailsMap } from '../../typings/Coverage';\nimport { JsonReport } from '../../typings/JsonReport';\nimport { getFileCoverageMap } from '../../utils/getFileCoverageMap';\nimport { getPercents } from '../getPercents';\n\nexport const parseDetails = (jsonReport: JsonReport) => {\n // Find common root directory\n const filepaths = Object.keys(jsonReport.coverageMap);\n const trimPath = findCommonPath(filepaths).length;\n\n const fileCoverageMap = getFileCoverageMap(jsonReport);\n\n return Object.entries(fileCoverageMap).reduce(\n (acc, [filename, coverage]) => {\n const normalizedFilename = filename.substring(trimPath);\n\n acc[normalizedFilename] = {\n filename: normalizedFilename,\n statements: getPercents(\n coverage.coveredStatements,\n coverage.totalStatements\n ),\n branches: getPercents(\n coverage.coveredBranches,\n coverage.totalBranches\n ),\n functions: getPercents(\n coverage.coveredFunctions,\n coverage.totalFunctions\n ),\n lines: getPercents(coverage.coveredLines, coverage.totalLines),\n };\n\n return acc;\n },\n {}\n );\n};\n", "import { CoverageSummary } from '../../typings/Coverage';\nimport { CoverageMap, FileCoverage } from '../../typings/JsonReport';\nimport { getPercents } from '../getPercents';\n\nexport const getSummary = (\n map: CoverageMap,\n totalCounter: (value: FileCoverage) => number,\n coveredCounter: (value: FileCoverage) => number,\n title: string\n): CoverageSummary => {\n const total = Object.values(map).reduce(\n (acc, currValue) => acc + totalCounter(currValue),\n 0\n );\n\n const covered = Object.values(map).reduce(\n (acc, currValue) => acc + coveredCounter(currValue),\n 0\n );\n\n return {\n title,\n total,\n covered,\n percentage: getPercents(covered, total),\n };\n};\n", "import { getSummary } from './getSummary';\nimport { JsonReport } from '../../typings/JsonReport';\nimport { i18n } from '../../utils/i18n';\nimport {\n coveredBranchesCounter,\n coveredLinesCounter,\n standardCoveredCounter,\n standardTotalCounter,\n totalBranchesCounter,\n totalLinesCounter,\n} from '../counters';\n\nexport const parseSummary = (jsonReport: JsonReport) => {\n return [\n getSummary(\n jsonReport.coverageMap,\n standardTotalCounter('s'),\n standardCoveredCounter('s'),\n i18n('statements')\n ),\n getSummary(\n jsonReport.coverageMap,\n totalBranchesCounter,\n coveredBranchesCounter,\n i18n('branches')\n ),\n getSummary(\n jsonReport.coverageMap,\n standardTotalCounter('f'),\n standardCoveredCounter('f'),\n i18n('functions')\n ),\n getSummary(\n jsonReport.coverageMap,\n totalLinesCounter,\n coveredLinesCounter,\n i18n('lines')\n ),\n ];\n};\n", "import markdownTable from 'markdown-table';\n\nimport { getFileCoverageDetailRow } from './getFileCoverageDetailRow';\nimport { CoverageDetailsMap } from '../../typings/Coverage';\nimport { createMarkdownSpoiler } from '../../utils/createMarkdownSpoiler';\nimport { i18n } from '../../utils/i18n';\nimport { withExplanation } from '../../utils/withExplanation';\n\nexport const formatCoverageDetailsPart = (\n summary: string,\n headDetails: CoverageDetailsMap,\n baseDetails?: CoverageDetailsMap,\n threshold?: number\n): string | undefined => {\n const tableContent = Object.keys(headDetails).map((filename) =>\n getFileCoverageDetailRow(\n filename,\n headDetails[filename],\n baseDetails?.[filename],\n threshold\n )\n );\n\n if (tableContent.length > 0) {\n return createMarkdownSpoiler({\n body: markdownTable(\n [\n [\n withExplanation(\n i18n('status'),\n i18n('statusExplanation')\n ),\n i18n('filename'),\n i18n('statements'),\n i18n('branches'),\n i18n('functions'),\n i18n('lines'),\n ],\n ...tableContent,\n ],\n {\n align: ['c', 'l', 'l', 'l', 'l', 'l'],\n }\n ),\n summary,\n });\n }\n\n return undefined;\n};\n", "import { basename } from 'path';\n\n// if path is longer than LONG_PATH_LENGTH, it is assumed to be a long path\nconst LONG_PATH_LENGTH = 20;\n\nexport const shrinkLongPath = (filename: string) => {\n const base = basename(filename);\n\n if (filename.length >= LONG_PATH_LENGTH && base !== filename) {\n return `
\\`...\\` / ${base}
`;\n }\n\n return filename;\n};\n", "export const decimalToString = (n: number, digitsAfterDot = 2): string =>\n n.toFixed(digitsAfterDot).replace(/\\.?0+$/, '');\n", "import { decimalToString } from './decimalToString';\nimport { i18n } from './i18n';\n\nexport const formatPercentageDelta = (delta: number): string =>\n i18n(\n delta > 0\n ? `(+{{ delta }}% :arrow_up_small:)`\n : `({{ delta }}% :small_red_triangle_down:)`,\n {\n delta: decimalToString(delta),\n }\n );\n", "import { decimalToString } from './decimalToString';\nimport { formatPercentageDelta } from './formatPercentageDelta';\nimport { i18n } from './i18n';\n\nconst APPROXIMATION_THRESHOLD = 0;\n\nexport const formatPercentage = (\n headPercentage: number,\n basePercentage: number = headPercentage\n) => {\n const delta = headPercentage - basePercentage;\n\n const isDeltaValid = Math.abs(delta) > APPROXIMATION_THRESHOLD;\n\n return i18n(\n isDeltaValid\n ? '
{{ percentage }}% {{ delta }}
'\n : '{{ percentage }}%',\n {\n percentage: decimalToString(headPercentage),\n baseCoverage:\n i18n('baseCoverage') + decimalToString(basePercentage),\n delta: isDeltaValid ? formatPercentageDelta(delta) : '',\n }\n );\n};\n", "import { i18n } from './i18n';\n\nconst DEFAULT_STEP = 20;\n\nexport const getStatusOfPercents = (percentage: number, threshold = 60) => {\n let step = DEFAULT_STEP;\n\n if (threshold > 100 - DEFAULT_STEP * 2) {\n step = (100 - threshold) / 2;\n }\n\n if (percentage < threshold) {\n return i18n(':red_circle:');\n } else if (percentage < threshold + step) {\n return i18n(':yellow_circle:');\n } else {\n return i18n(':green_circle:');\n }\n};\n", "import { shrinkLongPath } from './shrinkLongPath';\nimport { CoverageDetail } from '../../typings/Coverage';\nimport { formatPercentage } from '../../utils/formatPercentage';\nimport { getStatusOfPercents } from '../../utils/getStatusOfPercents';\n\nexport const getFileCoverageDetailRow = (\n filename: string,\n headDetail: CoverageDetail,\n baseDetail?: CoverageDetail,\n threshold?: number\n): Array => [\n getStatusOfPercents(headDetail.lines, threshold),\n shrinkLongPath(filename),\n formatPercentage(headDetail.statements, baseDetail?.statements),\n formatPercentage(headDetail.branches, baseDetail?.branches),\n formatPercentage(headDetail.functions, baseDetail?.functions),\n formatPercentage(headDetail.lines, baseDetail?.lines),\n];\n", "export type SpoilerConfig = {\n body: string;\n summary: string;\n};\n\nexport const createMarkdownSpoiler = ({\n body,\n summary,\n}: SpoilerConfig): string => `\n
${summary}\n
\n\n${body}\n\n
\n`;\n", "export const withExplanation = (text: string, explanation: string) =>\n `
${text}:grey_question:
`;\n", "import { CoverageDetail, CoverageDetailsMap } from '../../typings/Coverage';\n\nconst coverageLessThan = (first: CoverageDetail, second: CoverageDetail) =>\n first.statements < second.statements ||\n first.branches < second.branches ||\n first.functions < second.functions;\n\nexport const getDecreasedCoverage = (\n headDetails: CoverageDetailsMap,\n baseDetails: CoverageDetailsMap | undefined\n) =>\n Object.keys(headDetails)\n .filter(\n (filename) =>\n headDetails[filename] &&\n baseDetails?.[filename] &&\n coverageLessThan(headDetails[filename], baseDetails[filename])\n )\n .reduce<{\n headDetails: CoverageDetailsMap;\n baseDetails: CoverageDetailsMap;\n }>(\n (acc, filename) => {\n acc.headDetails[filename] = headDetails[filename];\n acc.baseDetails[filename] = baseDetails![filename];\n return acc;\n },\n { headDetails: {}, baseDetails: {} }\n );\n", "import { CoverageDetailsMap } from '../../typings/Coverage';\n\nexport const getNewFilesCoverage = (\n headDetails: CoverageDetailsMap,\n baseDetails: CoverageDetailsMap | undefined\n): CoverageDetailsMap =>\n baseDetails\n ? Object.keys(headDetails)\n .filter((filename) => baseDetails[filename] === undefined)\n .reduce((acc, filename) => {\n acc[filename] = headDetails[filename];\n return acc;\n }, {})\n : {};\n", "import { formatCoverageDetailsPart } from './formatCoverageDetailsPart';\nimport { getDecreasedCoverage } from './getDecreasedCoverage';\nimport { getNewFilesCoverage } from './getNewFilesCoverage';\nimport { CoverageDetailsMap } from '../../typings/Coverage';\nimport { i18n } from '../../utils/i18n';\n\nexport const formatCoverageDetails = (\n headDetails: CoverageDetailsMap,\n baseDetails: CoverageDetailsMap | undefined,\n threshold: number | undefined\n): string => {\n const decreasedCoverage = getDecreasedCoverage(headDetails, baseDetails);\n\n return [\n formatCoverageDetailsPart(\n i18n('newFilesCoverage'),\n getNewFilesCoverage(headDetails, baseDetails),\n undefined,\n threshold\n ),\n formatCoverageDetailsPart(\n i18n('decreasedCoverageFiles'),\n decreasedCoverage.headDetails,\n decreasedCoverage.baseDetails,\n threshold\n ),\n ].join('\\n');\n};\n", "import table from 'markdown-table';\n\nimport { CoverageSummary } from '../../typings/Coverage';\nimport { formatPercentage } from '../../utils/formatPercentage';\nimport { getStatusOfPercents } from '../../utils/getStatusOfPercents';\nimport { i18n } from '../../utils/i18n';\nimport { withExplanation } from '../../utils/withExplanation';\n\nexport const formatCoverageSummary = (\n headSummary: Array,\n baseSummary: Array | undefined,\n threshold: number | undefined\n): string =>\n table(\n [\n [\n withExplanation(i18n('status'), i18n('statusExplanation')),\n i18n('category'),\n i18n('percentage'),\n i18n('ratio'),\n ],\n ...headSummary.map((currSummary, index) => [\n getStatusOfPercents(currSummary.percentage, threshold),\n currSummary.title,\n formatPercentage(\n currSummary.percentage,\n baseSummary?.[index].percentage\n ),\n `${currSummary.covered}/${currSummary.total}`,\n ]),\n ],\n { align: ['c', 'l', 'l', 'c'] }\n );\n", "import { formatCoverageDetails } from './details/formatCoverageDetails';\nimport { formatCoverageSummary } from './summary/formatCoverageSummary';\nimport { CoverageDetailsMap, CoverageSummary } from '../typings/Coverage';\nimport { i18n } from '../utils/i18n';\n\nexport const getFormattedCoverage = (\n headSummary: Array,\n baseSummary: Array | undefined,\n headDetails: CoverageDetailsMap,\n baseDetails: CoverageDetailsMap | undefined,\n threshold: number | undefined,\n hideDetails: boolean | undefined\n): string =>\n [\n formatCoverageSummary(headSummary, baseSummary, threshold),\n !hideDetails\n ? formatCoverageDetails(headDetails, baseDetails, threshold)\n : `> ${i18n('detailsHidden')}`,\n ]\n .filter(Boolean)\n .join('\\n');\n", "import { parseDetails } from './details/parseDetails';\nimport { parseSummary } from './summary/parseSummary';\nimport { getFormattedCoverage } from './getFormattedCoverage';\nimport { JsonReport } from '../typings/JsonReport';\n\nexport const formatCoverage = (\n headReport: JsonReport | undefined,\n baseReport: JsonReport | undefined,\n threshold: number | undefined,\n hideDetails: boolean | undefined\n): string => {\n if (headReport) {\n return getFormattedCoverage(\n parseSummary(headReport),\n baseReport ? parseSummary(baseReport) : undefined,\n parseDetails(headReport),\n baseReport ? parseDetails(baseReport) : undefined,\n threshold,\n hideDetails\n );\n }\n\n return '';\n};\n", "import { FailReason } from './Report';\nimport { i18n } from '../utils/i18n';\n\nexport class ActionError extends Error {\n public constructor(reason: FailReason, details?: T) {\n super(\n i18n(\n `errors.${reason}`,\n (details as unknown) as Record\n )\n );\n }\n\n public toString(): string {\n return this.message;\n }\n}\n", "import { context } from '@actions/github';\n\nexport const getConsoleLink = () => {\n const repositoryUrl =\n context.payload.repository?.html_url ??\n `https://github.com/${context.repo.owner}/${context.repo.repo}`;\n\n return `${repositoryUrl}/actions/runs/${context.runId}`;\n};\n", "import { ActionError } from '../typings/ActionError';\nimport { getConsoleLink } from '../utils/getConsoleLink';\nimport { i18n } from '../utils/i18n';\n\nconst getNumberWidth = (index: number) => Math.floor(Math.log10(index));\n\nexport const formatErrors = (errors: Array) => {\n if (errors.length === 0) {\n return '';\n }\n\n if (errors.length === 1) {\n const error = errors[0];\n\n if (error instanceof ActionError) {\n return i18n(':x: {{ error }}', { error: error.toString() });\n }\n\n return i18n(':x: {{ unexpectedError }} \\n```\\n{{ error }}\\n```', {\n error: error.toString(),\n unexpectedError: i18n('errors.unexpectedError', {\n consoleLink: getConsoleLink(),\n }),\n });\n }\n\n return (\n i18n('errors.multiple') +\n i18n('\\n```\\n{{ errors }}\\n```\\n', {\n errors: errors\n .map(\n (error, index) =>\n ` ${String(1 + index).padEnd(\n 1 + getNumberWidth(errors.length),\n ' '\n )} | ${error.toString()}`\n )\n .join('\\n'),\n })\n );\n};\n", "import { TestRunReport } from '../typings/Report';\nimport { createMarkdownSpoiler } from '../utils/createMarkdownSpoiler';\n\nexport const formatRunReport = (report: TestRunReport): string => {\n const parts = [`## ${report.title}`];\n if (report.failures) {\n parts.push(\n createMarkdownSpoiler({\n summary: report.summary,\n body: report.failures,\n })\n );\n } else {\n parts.push(report.summary);\n }\n return parts.join('\\n');\n};\n", "import { ThresholdResult } from '../typings/ThresholdResult';\r\nimport { i18n } from '../utils/i18n';\r\n\r\nexport const formatThresholdResults = (results: ThresholdResult[]): string => {\r\n return results\r\n .map(({ type, path, expected, received }) =>\r\n i18n(`thresholdFailures.${expected < 0 ? 'ones' : 'percents'}`, {\r\n path,\r\n type: i18n(type),\r\n ltype: i18n(type).toLowerCase(),\r\n expected: Math.abs(expected),\r\n coverage: received,\r\n })\r\n )\r\n .join('\\n');\r\n};\r\n", "import stripAnsi from 'strip-ansi';\n\nimport { JsonReport } from '../typings/JsonReport';\n\nexport const getFailureDetails = ({ testResults }: JsonReport): string => {\n if (\n !testResults ||\n !testResults.some(\n ({ message, status }) => message.length > 0 && status !== 'passed'\n )\n ) {\n return '';\n }\n const wrapCode = (code: string) => '```\\n' + code + '\\n```';\n const codeBlocks = testResults\n .filter(({ status }) => status !== 'passed')\n .map(({ message }) => {\n const stripped = stripAnsi(message);\n if (stripped.trim().length === 0) {\n return '';\n }\n return wrapCode(stripped);\n })\n .filter(({ length }) => length > 0);\n return codeBlocks.join('\\n---\\n');\n};\n", "import { JsonReport } from '../../typings/JsonReport';\nimport { i18n } from '../../utils/i18n';\n\nexport const getTestRunSummary = (jsonReport: JsonReport) =>\n jsonReport.success\n ? i18n('testsSuccessSummary', {\n numPassedTests: jsonReport.numPassedTests,\n numPassedTestSuites: jsonReport.numPassedTestSuites,\n ending: jsonReport.numPassedTestSuites > 1 ? 's' : '',\n })\n : i18n('testsFailSummary', {\n numFailedTests: jsonReport.numFailedTests,\n numTotalTests: jsonReport.numTotalTests,\n numFailedTestSuites: jsonReport.numFailedTestSuites,\n numTotalTestSuites: jsonReport.numTotalTestSuites,\n });\n", "import { readFile } from 'fs-extra';\n\nimport { REPORT_PATH } from '../constants/REPORT_PATH';\nimport { ActionError } from '../typings/ActionError';\nimport { FailReason } from '../typings/Report';\nimport { DataCollector } from '../utils/DataCollector';\nimport { i18n } from '../utils/i18n';\nimport { joinPaths } from '../utils/joinPaths';\n\nexport const collectCoverage = async (\n dataCollector: DataCollector,\n workingDirectory?: string,\n coverageFile?: string\n) => {\n const pathToCoverageFile = joinPaths(\n workingDirectory,\n coverageFile || REPORT_PATH\n );\n\n try {\n // Originally made by Jeremy Gillick (https://github.com/jgillick)\n // Modified after big refactor by Artiom Tretjakovas (https://github.com/ArtiomTr)\n // Load coverage from file\n\n dataCollector.info(\n i18n('loadingCoverageFromFile', {\n pathToCoverageFile,\n })\n );\n\n const outputBuffer = await readFile(pathToCoverageFile);\n\n return outputBuffer.toString();\n } catch (error) {\n if ((error as NodeJS.ErrnoException).code === 'ENOENT') {\n throw new ActionError(FailReason.REPORT_NOT_FOUND, {\n coveragePath: pathToCoverageFile,\n });\n }\n\n throw new ActionError(FailReason.READING_COVERAGE_FILE_FAILED, {\n error: (error as Error).toString(),\n });\n }\n};\n", "export const REPORT_PATH = 'report.json';\n", "import { exec } from '@actions/exec';\n\nimport { PackageManagerType } from '../typings/Options';\nimport { joinPaths } from '../utils/joinPaths';\nimport { removeDirectory } from '../utils/removeDirectory';\n\nexport const installDependencies = async (\n packageManager: PackageManagerType = 'npm',\n workingDirectory?: string\n) => {\n // NOTE: The `npm ci` command is not used. Because if your version of npm is old, the generated `package-lock.json` will also be old, and the latest version of `npm ci` will fail.\n await removeDirectory(joinPaths(workingDirectory, 'node_modules'));\n\n await exec(`${packageManager} install`, undefined, {\n cwd: workingDirectory,\n });\n};\n", "import { rm, rmdir } from 'fs-extra';\r\nimport { satisfies } from 'semver';\r\n\r\nexport const removeDirectory = (path: string) => {\r\n if (satisfies(process.version, '>=14.14.0')) {\r\n return rm(path, { force: true, recursive: true });\r\n } else {\r\n return rmdir(path, { recursive: true });\r\n }\r\n};\r\n", "import { ActionError } from '../typings/ActionError';\nimport { JsonReport } from '../typings/JsonReport';\nimport { FailReason } from '../typings/Report';\n\nexport const parseCoverage = (src: string): JsonReport => {\n try {\n return JSON.parse(src);\n } catch (err) {\n throw new ActionError(FailReason.INVALID_COVERAGE_FORMAT);\n }\n};\n", "import { exec } from '@actions/exec';\n\nimport { getTestCommand } from '../utils/getTestCommand';\n\nexport const runTest = async (\n testCommand: string,\n workingDirectory?: string\n) => {\n await exec(\n await getTestCommand(testCommand, 'report.json', workingDirectory),\n [],\n {\n cwd: workingDirectory,\n }\n );\n};\n", "import { join } from 'path';\n\nimport { readFile } from 'fs-extra';\n\nconst packageScriptRegex = /^(?:(?:npm|yarn|pnpm)\\s+(?:run\\s+)?([\\w:-]+))/;\n\nexport const isOldScript = async (\n command: string,\n workingDirectory: string | undefined\n) => {\n if (command.includes('report.json')) {\n return true;\n }\n\n const matchResult = command.match(packageScriptRegex);\n\n if (matchResult) {\n const [, scriptName] = matchResult;\n\n try {\n const packageJson = JSON.parse(\n (\n await readFile(\n join(\n ...([workingDirectory, 'package.json'].filter(\n Boolean\n ) as string[])\n )\n )\n ).toString()\n );\n\n const realScript = packageJson.scripts[scriptName];\n\n if (realScript.includes('report.json')) {\n return true;\n }\n } catch {\n /** ignore exceptions */\n }\n }\n\n return false;\n};\n", "import { isOldScript } from './isOldScript';\n\nexport const getTestCommand = async (\n command: string,\n outputFile: string,\n workingDirectory: string | undefined\n) => {\n if (await isOldScript(command, workingDirectory)) {\n // TODO: add warning here\n return command;\n }\n\n const isNpmStyle = command.startsWith('npm') || command.startsWith('pnpm');\n\n const hasDoubleHyhen = command.includes(' -- ');\n\n // building new command\n const newCommandBuilder: (string | boolean)[] = [\n command,\n // add two hypens if it is npm or pnpm package managers and two hyphens don't already exist\n isNpmStyle && !hasDoubleHyhen && '--',\n // argument which indicates that jest runs in CI environment\n '--ci',\n // telling jest that output should be in json format\n '--json',\n // force jest to collect coverage\n '--coverage',\n // argument which tells jest to include tests' locations in the generated json output\n '--testLocationInResults',\n // output file\n `--outputFile=\"${outputFile}\"`,\n ];\n\n return newCommandBuilder.filter(Boolean).join(' ');\n};\n", "import { getInput } from '@actions/core';\nimport { context, getOctokit } from '@actions/github';\nimport * as yup from 'yup';\n\nimport { icons } from '../format/strings.json';\n\nexport type IconType = keyof typeof icons;\n\nexport type AnnotationType = 'all' | 'none' | 'coverage' | 'failed-tests';\nexport type PackageManagerType = 'npm' | 'yarn' | 'pnpm';\nexport type SkipStepType = 'all' | 'none' | 'install';\nexport type OutputType = 'comment' | 'report-markdown';\nexport type PullRequest = {\n base: { ref: string };\n head: { ref: string; sha: string };\n number: number;\n};\nexport type Options = {\n token: string;\n testScript: string;\n iconType: IconType;\n annotations: AnnotationType;\n threshold?: number;\n workingDirectory?: string;\n packageManager: PackageManagerType;\n skipStep: SkipStepType;\n customTitle?: string;\n coverageFile?: string;\n baseCoverageFile?: string;\n prNumber: null | number;\n pullRequest: null | PullRequest;\n output: Array;\n};\n\nconst validAnnotationOptions: Array = [\n 'all',\n 'none',\n 'coverage',\n 'failed-tests',\n];\n\nconst packageManagerOptions: Array = [\n 'npm',\n 'yarn',\n 'pnpm',\n];\n\nconst validIconOptions = Object.keys(icons);\n\nconst validSkipStepOptions: Array = ['all', 'none', 'install'];\n\nconst validOutputTypeOptions: Array = [\n 'comment',\n 'report-markdown',\n];\n\nconst optionSchema = yup.object().shape({\n token: yup.string().required(),\n testScript: yup.string().required(),\n iconType: yup.string().required().oneOf(validIconOptions),\n annotations: yup.string().required().oneOf(validAnnotationOptions),\n threshold: yup\n .number()\n .transform((value) => (isNaN(value) ? undefined : value))\n .min(0)\n .max(100),\n workingDirectory: yup.string(),\n packageManager: yup.string().required().oneOf(packageManagerOptions),\n skipStep: yup.string().required().oneOf(validSkipStepOptions),\n customTitle: yup.string(),\n coverageFile: yup.string(),\n baseCoverageFile: yup.string(),\n prNumber: yup.number().nullable(),\n pullRequest: yup.object().nullable(),\n output: yup\n .array()\n .required()\n .transform((_, originalValue: string) => originalValue.split(', '))\n .of(yup.string().required().oneOf(validOutputTypeOptions)),\n});\n\nexport const shouldInstallDeps = (skipStep: SkipStepType): Boolean =>\n !['all', 'install'].includes(skipStep);\n\nexport const shouldRunTestScript = (skipStep: SkipStepType): Boolean =>\n !['all'].includes(skipStep);\n\nexport const getOptions = async (): Promise => {\n const token = getInput('github-token', {\n required: true,\n });\n const octokit = getOctokit(token);\n const testScript = getInput('test-script');\n const threshold = getInput('threshold');\n const workingDirectory = getInput('working-directory');\n const iconType = getInput('icons');\n const annotations = getInput('annotations');\n const packageManager = getInput('package-manager');\n const skipStep = getInput('skip-step');\n const customTitle = getInput('custom-title');\n const coverageFile = getInput('coverage-file');\n const baseCoverageFile = getInput('base-coverage-file');\n const prNumber: number | null = Number(\n getInput('prnumber') || context?.payload?.pull_request?.number\n );\n const output = getInput('output');\n let pullRequest = context?.payload?.pull_request || null;\n\n if (!pullRequest && !Number.isNaN(prNumber)) {\n const { data: pr } = await octokit.rest.pulls.get({\n owner: context.repo.owner,\n repo: context.repo.repo,\n pull_number: prNumber,\n });\n pullRequest = pr as PullRequest;\n }\n\n try {\n const options: Options = (await optionSchema.validate({\n token,\n testScript,\n threshold,\n workingDirectory,\n iconType,\n annotations,\n packageManager,\n skipStep,\n customTitle,\n coverageFile,\n baseCoverageFile,\n prNumber: prNumber || null,\n pullRequest,\n output,\n })) as Options;\n\n return options;\n } catch (err) {\n if (err instanceof yup.ValidationError) {\n throw new Error(\n [err.message, ...err.errors].filter(Boolean).join('\\n')\n );\n }\n\n throw err;\n }\n};\n", "import { DataCollector } from './DataCollector';\nimport { i18n } from './i18n';\n\nexport type SuccessfulStageResult = [success: true, output: T];\n\nexport type FailedStageResult = [success: false, output: undefined];\n\nexport type StageResult = SuccessfulStageResult | FailedStageResult;\n\nconst SKIP_SYMBOL = Symbol();\n\nexport const runStage = async (\n stage: string,\n dataCollector: DataCollector,\n action: (skip: () => never) => Promise | T\n): Promise> => {\n const stageKey = `stages.${stage}`;\n dataCollector.info(\n i18n('stages.defaults.begin', {\n stage: i18n(stageKey).toLowerCase(),\n })\n );\n\n const skip = () => {\n throw SKIP_SYMBOL;\n };\n\n try {\n const output = await action(skip);\n return [true, output];\n } catch (error) {\n if (error === SKIP_SYMBOL) {\n dataCollector.info(\n i18n('stages.defaults.skip', {\n stage: i18n(stageKey),\n })\n );\n } else {\n dataCollector.info(\n i18n('stages.defaults.fail', {\n stage: i18n(stageKey),\n })\n );\n dataCollector.error(error as Error);\n }\n\n return [false, undefined];\n } finally {\n dataCollector.info(\n i18n('stages.defaults.end', {\n stage: i18n(stageKey),\n })\n );\n }\n};\n", "import { collectCoverage } from './collectCoverage';\nimport { installDependencies } from './installDependencies';\nimport { parseCoverage } from './parseCoverage';\nimport { runTest } from './runTest';\nimport { ActionError } from '../typings/ActionError';\nimport { JsonReport } from '../typings/JsonReport';\nimport {\n Options,\n shouldInstallDeps,\n shouldRunTestScript,\n} from '../typings/Options';\nimport { FailReason } from '../typings/Report';\nimport { DataCollector } from '../utils/DataCollector';\nimport { runStage } from '../utils/runStage';\n\nexport const getCoverage = async (\n dataCollector: DataCollector,\n options: Options,\n runAll: boolean,\n coverageFilePath: string | undefined\n): Promise => {\n await runStage('install', dataCollector, async (skip) => {\n if (\n coverageFilePath ||\n (!runAll && !shouldInstallDeps(options.skipStep))\n ) {\n skip();\n }\n\n await installDependencies(\n options.packageManager,\n options.workingDirectory\n );\n });\n\n await runStage('runTest', dataCollector, async (skip) => {\n if (\n coverageFilePath ||\n (!runAll && !shouldRunTestScript(options.skipStep))\n ) {\n skip();\n }\n\n await runTest(options.testScript, options.workingDirectory);\n });\n\n const [isCoverageCollected, rawCoverage] = await runStage(\n 'collectCoverage',\n dataCollector,\n () =>\n collectCoverage(\n dataCollector as DataCollector,\n options.workingDirectory,\n coverageFilePath\n )\n );\n\n const [coverageParsed, jsonReport] = await runStage(\n 'parseCoverage',\n dataCollector,\n async (skip) => {\n if (!isCoverageCollected) {\n skip();\n }\n\n const jsonReport = parseCoverage(rawCoverage!);\n\n return jsonReport;\n }\n );\n\n if (!coverageParsed || !jsonReport) {\n throw new ActionError(FailReason.FAILED_GETTING_COVERAGE);\n }\n\n return jsonReport;\n};\n", "import { exec } from '@actions/exec';\n\nexport const switchBranch = async (branch: string) => {\n try {\n await exec(`git fetch --all --depth=1`);\n } catch (err) {\n console.warn('Error fetching git repository', err);\n }\n\n await exec(`git checkout -f ${branch}`);\n};\n\nexport const switchBack = async () => {\n try {\n await exec(`git checkout -`);\n } catch (err) {\n console.warn('Error checking to branches', err);\n }\n};\n", "import * as core from '@actions/core';\n\nexport const createDataCollector = (): DataCollector => {\n const errors: Array = [];\n const collectedData: Array = [];\n const messages: Array = [];\n\n const error = (error: Error) => {\n errors.push(error);\n core.error(\n error.toString().concat(error.stack ? `\\n${error.stack}` : '')\n );\n };\n\n const add = (data: T) => {\n collectedData.push(data);\n };\n\n const info = (message: string) => {\n messages.push(message);\n core.info(message);\n };\n\n const get = () => ({\n data: collectedData,\n errors,\n messages,\n });\n\n return {\n error,\n add,\n get,\n info,\n };\n};\n\nexport type CollectedData = {\n errors: Array;\n messages: Array;\n data: Array;\n};\n\nexport type DataCollector = {\n error: (error: Error) => void;\n info: (message: string) => void;\n add: (data: T) => void;\n get: () => CollectedData;\n};\n", "import isNil from 'lodash/isNil';\r\n\r\nimport { tryGetJestThreshold } from './tryGetJestThreshold';\r\nimport { JestThreshold } from '../typings/JestThreshold';\r\n\r\nexport const getNormalThreshold = async (\r\n workingDirectory: string,\r\n thresholdFromOptions: number | undefined\r\n): Promise => {\r\n const threshold = await tryGetJestThreshold(workingDirectory);\r\n\r\n // Should be removed in further versions\r\n if (isNil(threshold)) {\r\n return {\r\n global: {\r\n branches: thresholdFromOptions,\r\n functions: thresholdFromOptions,\r\n lines: thresholdFromOptions,\r\n statements: thresholdFromOptions,\r\n },\r\n };\r\n }\r\n\r\n return threshold;\r\n};\r\n", "import { existsSync, promises } from 'fs';\nimport { resolve, extname, dirname } from 'pathe';\nimport * as dotenv from 'dotenv';\nimport os from 'os';\nimport createJiti from 'jiti';\nimport * as rc9 from 'rc9';\nimport { defu } from 'defu';\nimport { findWorkspaceDir } from 'pkg-types';\n\nasync function setupDotenv(options) {\n const targetEnv = options.env ?? process.env;\n const env = await loadDotenv({\n cwd: options.cwd,\n fileName: options.fileName ?? \".env\",\n env: targetEnv,\n interpolate: options.interpolate ?? true\n });\n for (const key in env) {\n if (!key.startsWith(\"_\") && targetEnv[key] === void 0) {\n targetEnv[key] = env[key];\n }\n }\n return env;\n}\nasync function loadDotenv(opts) {\n const env = /* @__PURE__ */ Object.create(null);\n const dotenvFile = resolve(opts.cwd, opts.fileName);\n if (existsSync(dotenvFile)) {\n const parsed = dotenv.parse(await promises.readFile(dotenvFile, \"utf-8\"));\n Object.assign(env, parsed);\n }\n if (!opts.env._applied) {\n Object.assign(env, opts.env);\n env._applied = true;\n }\n if (opts.interpolate) {\n interpolate(env);\n }\n return env;\n}\nfunction interpolate(target, source = {}, parse = (v) => v) {\n function getValue(key) {\n return source[key] !== void 0 ? source[key] : target[key];\n }\n function interpolate2(value, parents = []) {\n if (typeof value !== \"string\") {\n return value;\n }\n const matches = value.match(/(.?\\${?(?:[a-zA-Z0-9_:]+)?}?)/g) || [];\n return parse(matches.reduce((newValue, match) => {\n const parts = /(.?)\\${?([a-zA-Z0-9_:]+)?}?/g.exec(match);\n const prefix = parts[1];\n let value2, replacePart;\n if (prefix === \"\\\\\") {\n replacePart = parts[0];\n value2 = replacePart.replace(\"\\\\$\", \"$\");\n } else {\n const key = parts[2];\n replacePart = parts[0].substring(prefix.length);\n if (parents.includes(key)) {\n console.warn(`Please avoid recursive environment variables ( loop: ${parents.join(\" > \")} > ${key} )`);\n return \"\";\n }\n value2 = getValue(key);\n value2 = interpolate2(value2, [...parents, key]);\n }\n return value2 !== void 0 ? newValue.replace(replacePart, value2) : newValue;\n }, value));\n }\n for (const key in target) {\n target[key] = interpolate2(getValue(key));\n }\n}\n\nasync function loadConfig(opts) {\n opts.cwd = resolve(process.cwd(), opts.cwd || \".\");\n opts.name = opts.name || \"config\";\n opts.configFile = opts.configFile ?? (opts.name !== \"config\" ? `${opts.name}.config` : \"config\");\n opts.rcFile = opts.rcFile ?? `.${opts.name}rc`;\n if (opts.extend !== false) {\n opts.extend = {\n extendKey: \"extends\",\n ...opts.extend\n };\n }\n opts.jiti = opts.jiti || createJiti(null, {\n interopDefault: true,\n requireCache: false,\n esmResolve: true,\n ...opts.jitiOptions\n });\n const r = {\n config: {},\n cwd: opts.cwd,\n configFile: resolve(opts.cwd, opts.configFile),\n layers: []\n };\n if (opts.dotenv) {\n await setupDotenv({\n cwd: opts.cwd,\n ...opts.dotenv === true ? {} : opts.dotenv\n });\n }\n const { config, configFile } = await resolveConfig(\".\", opts);\n if (configFile) {\n r.configFile = configFile;\n }\n const configRC = {};\n if (opts.rcFile) {\n if (opts.globalRc) {\n Object.assign(configRC, rc9.readUser({ name: opts.rcFile, dir: opts.cwd }));\n const workspaceDir = await findWorkspaceDir(opts.cwd).catch(() => null);\n if (workspaceDir) {\n Object.assign(configRC, rc9.read({ name: opts.rcFile, dir: workspaceDir }));\n }\n }\n Object.assign(configRC, rc9.read({ name: opts.rcFile, dir: opts.cwd }));\n }\n r.config = defu(\n opts.overrides,\n config,\n configRC,\n opts.defaultConfig\n );\n if (opts.extend) {\n await extendConfig(r.config, opts);\n r.layers = r.config._layers;\n delete r.config._layers;\n r.config = defu(\n r.config,\n ...r.layers.map((e) => e.config)\n );\n }\n const baseLayers = [\n opts.overrides && { config: opts.overrides, configFile: void 0, cwd: void 0 },\n { config, configFile: opts.configFile, cwd: opts.cwd },\n opts.rcFile && { config: configRC, configFile: opts.rcFile }\n ].filter((l) => l && l.config);\n r.layers = [\n ...baseLayers,\n ...r.layers\n ];\n if (opts.defaults) {\n r.config = defu(r.config, opts.defaults);\n }\n return r;\n}\nasync function extendConfig(config, opts) {\n config._layers = config._layers || [];\n if (!opts.extend) {\n return;\n }\n let keys = opts.extend.extendKey;\n if (typeof keys === \"string\") {\n keys = [keys];\n }\n const extendSources = [];\n for (const key of keys) {\n extendSources.push(...(Array.isArray(config[key]) ? config[key] : [config[key]]).filter(Boolean));\n delete config[key];\n }\n for (const extendSource of extendSources) {\n if (typeof extendSource !== \"string\") {\n console.warn(`Cannot extend config from \\`${JSON.stringify(extendSource)}\\` (which should be a string) in ${opts.cwd}`);\n continue;\n }\n const _config = await resolveConfig(extendSource, opts);\n if (!_config.config) {\n console.warn(`Cannot extend config from \\`${extendSource}\\` in ${opts.cwd}`);\n continue;\n }\n await extendConfig(_config.config, { ...opts, cwd: _config.cwd });\n config._layers.push(_config);\n if (_config.config._layers) {\n config._layers.push(..._config.config._layers);\n delete _config.config._layers;\n }\n }\n}\nconst GIT_PREFIXES = [\"github:\", \"gitlab:\", \"bitbucket:\", \"https://\"];\nconst NPM_PACKAGE_RE = /^(@[a-z0-9-~][a-z0-9-._~]*\\/)?[a-z0-9-~][a-z0-9-._~]*$/;\nasync function resolveConfig(source, opts) {\n if (opts.resolve) {\n const res2 = await opts.resolve(source, opts);\n if (res2) {\n return res2;\n }\n }\n if (GIT_PREFIXES.some((prefix) => source.startsWith(prefix))) {\n const url = new URL(source);\n const subPath = url.pathname.split(\"/\").slice(2).join(\"/\");\n const gitRepo = url.protocol + url.pathname.split(\"/\").slice(0, 2).join(\"/\");\n const tmpdir = resolve(os.tmpdir(), \"c12/\", gitRepo.replace(/[#:@/\\\\]/g, \"_\"));\n await promises.rm(tmpdir, { recursive: true }).catch(() => {\n });\n const gittar = await import('gittar').then((r) => r.default || r);\n const tarFile = await gittar.fetch(gitRepo);\n await gittar.extract(tarFile, tmpdir);\n source = resolve(tmpdir, subPath);\n }\n if (NPM_PACKAGE_RE.test(source)) {\n try {\n source = opts.jiti.resolve(source, { paths: [opts.cwd] });\n } catch (_err) {\n }\n }\n const isDir = !extname(source);\n const cwd = resolve(opts.cwd, isDir ? source : dirname(source));\n if (isDir) {\n source = opts.configFile;\n }\n const res = { config: null, cwd };\n try {\n res.configFile = opts.jiti.resolve(resolve(cwd, source), { paths: [cwd] });\n } catch (_err) {\n }\n if (!existsSync(res.configFile)) {\n return res;\n }\n res.config = opts.jiti(res.configFile);\n if (typeof res.config === \"function\") {\n res.config = await res.config();\n }\n return res;\n}\n\nexport { loadConfig, loadDotenv, setupDotenv };\n", "function normalizeWindowsPath(input = \"\") {\n if (!input || !input.includes(\"\\\\\")) {\n return input;\n }\n return input.replace(/\\\\/g, \"/\");\n}\n\nconst _UNC_REGEX = /^[\\\\/]{2}/;\nconst _IS_ABSOLUTE_RE = /^[\\\\/](?![\\\\/])|^[\\\\/]{2}(?!\\.)|^[a-zA-Z]:[\\\\/]/;\nconst _DRIVE_LETTER_RE = /^[a-zA-Z]:$/;\nconst sep = \"/\";\nconst delimiter = \":\";\nconst normalize = function(path) {\n if (path.length === 0) {\n return \".\";\n }\n path = normalizeWindowsPath(path);\n const isUNCPath = path.match(_UNC_REGEX);\n const isPathAbsolute = isAbsolute(path);\n const trailingSeparator = path[path.length - 1] === \"/\";\n path = normalizeString(path, !isPathAbsolute);\n if (path.length === 0) {\n if (isPathAbsolute) {\n return \"/\";\n }\n return trailingSeparator ? \"./\" : \".\";\n }\n if (trailingSeparator) {\n path += \"/\";\n }\n if (_DRIVE_LETTER_RE.test(path)) {\n path += \"/\";\n }\n if (isUNCPath) {\n if (!isPathAbsolute) {\n return `//./${path}`;\n }\n return `//${path}`;\n }\n return isPathAbsolute && !isAbsolute(path) ? `/${path}` : path;\n};\nconst join = function(...args) {\n if (args.length === 0) {\n return \".\";\n }\n let joined;\n for (let i = 0; i < args.length; ++i) {\n const arg = args[i];\n if (arg && arg.length > 0) {\n if (joined === void 0) {\n joined = arg;\n } else {\n joined += `/${arg}`;\n }\n }\n }\n if (joined === void 0) {\n return \".\";\n }\n return normalize(joined.replace(/\\/\\/+/g, \"/\"));\n};\nconst resolve = function(...args) {\n args = args.map((arg) => normalizeWindowsPath(arg));\n let resolvedPath = \"\";\n let resolvedAbsolute = false;\n for (let i = args.length - 1; i >= -1 && !resolvedAbsolute; i--) {\n const path = i >= 0 ? args[i] : process.cwd().replace(/\\\\/g, \"/\");\n if (!path || path.length === 0) {\n continue;\n }\n resolvedPath = `${path}/${resolvedPath}`;\n resolvedAbsolute = isAbsolute(path);\n }\n resolvedPath = normalizeString(resolvedPath, !resolvedAbsolute);\n if (resolvedAbsolute && !isAbsolute(resolvedPath)) {\n return `/${resolvedPath}`;\n }\n return resolvedPath.length > 0 ? resolvedPath : \".\";\n};\nfunction normalizeString(path, allowAboveRoot) {\n let res = \"\";\n let lastSegmentLength = 0;\n let lastSlash = -1;\n let dots = 0;\n let char = null;\n for (let i = 0; i <= path.length; ++i) {\n if (i < path.length) {\n char = path[i];\n } else if (char === \"/\") {\n break;\n } else {\n char = \"/\";\n }\n if (char === \"/\") {\n if (lastSlash === i - 1 || dots === 1) ; else if (dots === 2) {\n if (res.length < 2 || lastSegmentLength !== 2 || res[res.length - 1] !== \".\" || res[res.length - 2] !== \".\") {\n if (res.length > 2) {\n const lastSlashIndex = res.lastIndexOf(\"/\");\n if (lastSlashIndex === -1) {\n res = \"\";\n lastSegmentLength = 0;\n } else {\n res = res.slice(0, lastSlashIndex);\n lastSegmentLength = res.length - 1 - res.lastIndexOf(\"/\");\n }\n lastSlash = i;\n dots = 0;\n continue;\n } else if (res.length !== 0) {\n res = \"\";\n lastSegmentLength = 0;\n lastSlash = i;\n dots = 0;\n continue;\n }\n }\n if (allowAboveRoot) {\n res += res.length > 0 ? \"/..\" : \"..\";\n lastSegmentLength = 2;\n }\n } else {\n if (res.length > 0) {\n res += `/${path.slice(lastSlash + 1, i)}`;\n } else {\n res = path.slice(lastSlash + 1, i);\n }\n lastSegmentLength = i - lastSlash - 1;\n }\n lastSlash = i;\n dots = 0;\n } else if (char === \".\" && dots !== -1) {\n ++dots;\n } else {\n dots = -1;\n }\n }\n return res;\n}\nconst isAbsolute = function(p) {\n return _IS_ABSOLUTE_RE.test(p);\n};\nconst toNamespacedPath = function(p) {\n return normalizeWindowsPath(p);\n};\nconst _EXTNAME_RE = /.(\\.[^/.]+)$/;\nconst extname = function(p) {\n const match = _EXTNAME_RE.exec(normalizeWindowsPath(p));\n return match && match[1] || \"\";\n};\nconst relative = function(from, to) {\n const _from = resolve(from).split(\"/\");\n const _to = resolve(to).split(\"/\");\n for (const segment of [..._from]) {\n if (_to[0] !== segment) {\n break;\n }\n _from.shift();\n _to.shift();\n }\n return [..._from.map(() => \"..\"), ..._to].join(\"/\");\n};\nconst dirname = function(p) {\n const segments = normalizeWindowsPath(p).replace(/\\/$/, \"\").split(\"/\").slice(0, -1);\n if (segments.length === 1 && _DRIVE_LETTER_RE.test(segments[0])) {\n segments[0] += \"/\";\n }\n return segments.join(\"/\") || (isAbsolute(p) ? \"/\" : \".\");\n};\nconst format = function(p) {\n const segments = [p.root, p.dir, p.base ?? p.name + p.ext].filter(Boolean);\n return normalizeWindowsPath(p.root ? resolve(...segments) : segments.join(\"/\"));\n};\nconst basename = function(p, ext) {\n const lastSegment = normalizeWindowsPath(p).split(\"/\").pop();\n return ext && lastSegment.endsWith(ext) ? lastSegment.slice(0, -ext.length) : lastSegment;\n};\nconst parse = function(p) {\n const root = normalizeWindowsPath(p).split(\"/\").shift() || \"/\";\n const base = basename(p);\n const ext = extname(base);\n return {\n root,\n dir: dirname(p),\n base,\n ext,\n name: base.slice(0, base.length - ext.length)\n };\n};\n\nexport { normalizeString as a, relative as b, dirname as c, delimiter as d, extname as e, format as f, basename as g, normalizeWindowsPath as h, isAbsolute as i, join as j, normalize as n, parse as p, resolve as r, sep as s, toNamespacedPath as t };\n", "import { existsSync, readFileSync, writeFileSync } from 'fs';\nimport { resolve } from 'path';\nimport { homedir } from 'os';\nimport destr from 'destr';\nimport flat from 'flat';\nimport defu from 'defu';\n\nconst RE_KEY_VAL = /^\\s*([^=\\s]+)\\s*=\\s*(.*)?\\s*$/;\nconst RE_LINES = /\\n|\\r|\\r\\n/;\nconst defaults = {\n name: \".conf\",\n dir: process.cwd(),\n flat: false\n};\nfunction withDefaults(options) {\n if (typeof options === \"string\") {\n options = { name: options };\n }\n return { ...defaults, ...options };\n}\nfunction parse(contents, options = {}) {\n const config = {};\n const lines = contents.split(RE_LINES);\n for (const line of lines) {\n const match = line.match(RE_KEY_VAL);\n if (!match) {\n continue;\n }\n const key = match[1];\n if (!key || key === \"__proto__\" || key === \"constructor\") {\n continue;\n }\n const val = destr(match[2].trim());\n if (key.endsWith(\"[]\")) {\n const nkey = key.substr(0, key.length - 2);\n config[nkey] = (config[nkey] || []).concat(val);\n continue;\n }\n config[key] = val;\n }\n return options.flat ? config : flat.unflatten(config, { overwrite: true });\n}\nfunction parseFile(path, options) {\n if (!existsSync(path)) {\n return {};\n }\n return parse(readFileSync(path, \"utf-8\"), options);\n}\nfunction read(options) {\n options = withDefaults(options);\n return parseFile(resolve(options.dir, options.name), options);\n}\nfunction readUser(options) {\n options = withDefaults(options);\n options.dir = process.env.XDG_CONFIG_HOME || homedir();\n return read(options);\n}\nfunction serialize(config) {\n return Object.entries(flat.flatten(config)).map(([key, val]) => `${key}=${typeof val === \"string\" ? val : JSON.stringify(val)}`).join(\"\\n\");\n}\nfunction write(config, options) {\n options = withDefaults(options);\n writeFileSync(resolve(options.dir, options.name), serialize(config), {\n encoding: \"utf-8\"\n });\n}\nfunction writeUser(config, options) {\n options = withDefaults(options);\n options.dir = process.env.XDG_CONFIG_HOME || homedir();\n write(config, options);\n}\nfunction update(config, options) {\n options = withDefaults(options);\n if (!options.flat) {\n config = flat.unflatten(config, { overwrite: true });\n }\n const newConfig = defu(config, read(options));\n write(newConfig, options);\n return newConfig;\n}\nfunction updateUser(config, options) {\n options = withDefaults(options);\n options.dir = process.env.XDG_CONFIG_HOME || homedir();\n return update(config, options);\n}\n\nexport { defaults, parse, parseFile, read, readUser, serialize, update, updateUser, write, writeUser };\n", "const suspectProtoRx = /\"(?:_|\\\\u005[Ff])(?:_|\\\\u005[Ff])(?:p|\\\\u0070)(?:r|\\\\u0072)(?:o|\\\\u006[Ff])(?:t|\\\\u0074)(?:o|\\\\u006[Ff])(?:_|\\\\u005[Ff])(?:_|\\\\u005[Ff])\"\\s*:/;\nconst suspectConstructorRx = /\"(?:c|\\\\u0063)(?:o|\\\\u006[Ff])(?:n|\\\\u006[Ee])(?:s|\\\\u0073)(?:t|\\\\u0074)(?:r|\\\\u0072)(?:u|\\\\u0075)(?:c|\\\\u0063)(?:t|\\\\u0074)(?:o|\\\\u006[Ff])(?:r|\\\\u0072)\"\\s*:/;\nconst JsonSigRx = /^[\"{[]|^-?[0-9][0-9.]{0,14}$/;\nfunction jsonParseTransform(key, value) {\n if (key === \"__proto__\" || key === \"constructor\") {\n return;\n }\n return value;\n}\nfunction destr(val) {\n if (typeof val !== \"string\") {\n return val;\n }\n const _lval = val.toLowerCase();\n if (_lval === \"true\") {\n return true;\n }\n if (_lval === \"false\") {\n return false;\n }\n if (_lval === \"null\") {\n return null;\n }\n if (_lval === \"nan\") {\n return NaN;\n }\n if (_lval === \"infinity\") {\n return Infinity;\n }\n if (_lval === \"undefined\") {\n return void 0;\n }\n if (!JsonSigRx.test(val)) {\n return val;\n }\n try {\n if (suspectProtoRx.test(val) || suspectConstructorRx.test(val)) {\n return JSON.parse(val, jsonParseTransform);\n }\n return JSON.parse(val);\n } catch (_e) {\n return val;\n }\n}\n\nexport { destr as default };\n", "function isObject(val) {\n return val !== null && typeof val === \"object\";\n}\nfunction _defu(baseObj, defaults, namespace = \".\", merger) {\n if (!isObject(defaults)) {\n return _defu(baseObj, {}, namespace, merger);\n }\n const obj = Object.assign({}, defaults);\n for (const key in baseObj) {\n if (key === \"__proto__\" || key === \"constructor\") {\n continue;\n }\n const val = baseObj[key];\n if (val === null || val === void 0) {\n continue;\n }\n if (merger && merger(obj, key, val, namespace)) {\n continue;\n }\n if (Array.isArray(val) && Array.isArray(obj[key])) {\n obj[key] = val.concat(obj[key]);\n } else if (isObject(val) && isObject(obj[key])) {\n obj[key] = _defu(val, obj[key], (namespace ? `${namespace}.` : \"\") + key.toString(), merger);\n } else {\n obj[key] = val;\n }\n }\n return obj;\n}\nfunction createDefu(merger) {\n return (...args) => args.reduce((p, c) => _defu(p, c, \"\", merger), {});\n}\nconst defu = createDefu();\nconst defuFn = createDefu((obj, key, currentValue, _namespace) => {\n if (typeof obj[key] !== \"undefined\" && typeof currentValue === \"function\") {\n obj[key] = currentValue(obj[key]);\n return true;\n }\n});\nconst defuArrayFn = createDefu((obj, key, currentValue, _namespace) => {\n if (Array.isArray(obj[key]) && typeof currentValue === \"function\") {\n obj[key] = currentValue(obj[key]);\n return true;\n }\n});\n\nexport { createDefu, defu as default, defu, defuArrayFn, defuFn };\n", "import { statSync, promises } from 'fs';\nimport { resolve as resolve$1, dirname } from 'path';\nimport { resolvePath } from 'mlly';\nimport { resolve, join, isAbsolute } from 'pathe';\n\nconst defaultFindOptions = {\n startingFrom: \".\",\n rootPattern: /^node_modules$/,\n reverse: false,\n test: (filePath) => {\n try {\n if (statSync(filePath).isFile()) {\n return true;\n }\n } catch {\n }\n return null;\n }\n};\nasync function findFile(filename, _options = {}) {\n const options = { ...defaultFindOptions, ..._options };\n const basePath = resolve(options.startingFrom);\n const leadingSlash = basePath[0] === \"/\";\n const segments = basePath.split(\"/\").filter(Boolean);\n if (leadingSlash) {\n segments[0] = \"/\" + segments[0];\n }\n let root = segments.findIndex((r) => r.match(options.rootPattern));\n if (root === -1) {\n root = 0;\n }\n if (!options.reverse) {\n for (let i = segments.length; i > root; i--) {\n const filePath = join(...segments.slice(0, i), filename);\n if (await options.test(filePath)) {\n return filePath;\n }\n }\n } else {\n for (let i = root + 1; i <= segments.length; i++) {\n const filePath = join(...segments.slice(0, i), filename);\n if (await options.test(filePath)) {\n return filePath;\n }\n }\n }\n throw new Error(`Cannot find matching ${filename} in ${options.startingFrom} or parent directories`);\n}\nfunction findNearestFile(filename, _options = {}) {\n return findFile(filename, _options);\n}\nfunction findFarthestFile(filename, _options = {}) {\n return findFile(filename, { ..._options, reverse: true });\n}\n\nfunction definePackageJSON(pkg) {\n return pkg;\n}\nfunction defineTSConfig(tsconfig) {\n return tsconfig;\n}\nasync function readPackageJSON(id, opts = {}) {\n const resolvedPath = await resolvePackageJSON(id, opts);\n const blob = await promises.readFile(resolvedPath, \"utf-8\");\n return JSON.parse(blob);\n}\nasync function writePackageJSON(path, pkg) {\n await promises.writeFile(path, JSON.stringify(pkg, null, 2));\n}\nasync function readTSConfig(id, opts = {}) {\n const resolvedPath = await resolveTSConfig(id, opts);\n const blob = await promises.readFile(resolvedPath, \"utf-8\");\n const jsonc = await import('jsonc-parser');\n return jsonc.parse(blob);\n}\nasync function writeTSConfig(path, tsconfig) {\n await promises.writeFile(path, JSON.stringify(tsconfig, null, 2));\n}\nasync function resolvePackageJSON(id = process.cwd(), opts = {}) {\n const resolvedPath = isAbsolute(id) ? id : await resolvePath(id, opts);\n return findNearestFile(\"package.json\", { startingFrom: resolvedPath, ...opts });\n}\nasync function resolveTSConfig(id = process.cwd(), opts = {}) {\n const resolvedPath = isAbsolute(id) ? id : await resolvePath(id, opts);\n return findNearestFile(\"tsconfig.json\", { startingFrom: resolvedPath, ...opts });\n}\nconst lockFiles = [\"yarn.lock\", \"package-lock.json\", \"pnpm-lock.yaml\", \"npm-shrinkwrap.json\"];\nasync function resolveLockfile(id = process.cwd(), opts = {}) {\n const resolvedPath = isAbsolute(id) ? id : await resolvePath(id, opts);\n const _opts = { startingFrom: resolvedPath, ...opts };\n for (const lockFile of lockFiles) {\n try {\n return await findNearestFile(lockFile, _opts);\n } catch {\n }\n }\n throw new Error(\"No lockfile found from \" + id);\n}\nasync function findWorkspaceDir(id = process.cwd(), opts = {}) {\n const resolvedPath = isAbsolute(id) ? id : await resolvePath(id, opts);\n const _opts = { startingFrom: resolvedPath, ...opts };\n try {\n const r = await findNearestFile(\".git/config\", _opts);\n return resolve$1(r, \"../..\");\n } catch {\n }\n try {\n const r = await resolveLockfile(resolvedPath, { ..._opts, reverse: true });\n return dirname(r);\n } catch {\n }\n try {\n const r = await findFile(resolvedPath, _opts);\n return dirname(r);\n } catch {\n }\n throw new Error(\"Cannot detect workspace root from \" + id);\n}\n\nexport { definePackageJSON, defineTSConfig, findFarthestFile, findFile, findNearestFile, findWorkspaceDir, readPackageJSON, readTSConfig, resolveLockfile, resolvePackageJSON, resolveTSConfig, writePackageJSON, writeTSConfig };\n", "// This file was generated. Do not modify manually!\nvar astralIdentifierCodes = [509, 0, 227, 0, 150, 4, 294, 9, 1368, 2, 2, 1, 6, 3, 41, 2, 5, 0, 166, 1, 574, 3, 9, 9, 370, 1, 154, 10, 50, 3, 123, 2, 54, 14, 32, 10, 3, 1, 11, 3, 46, 10, 8, 0, 46, 9, 7, 2, 37, 13, 2, 9, 6, 1, 45, 0, 13, 2, 49, 13, 9, 3, 2, 11, 83, 11, 7, 0, 161, 11, 6, 9, 7, 3, 56, 1, 2, 6, 3, 1, 3, 2, 10, 0, 11, 1, 3, 6, 4, 4, 193, 17, 10, 9, 5, 0, 82, 19, 13, 9, 214, 6, 3, 8, 28, 1, 83, 16, 16, 9, 82, 12, 9, 9, 84, 14, 5, 9, 243, 14, 166, 9, 71, 5, 2, 1, 3, 3, 2, 0, 2, 1, 13, 9, 120, 6, 3, 6, 4, 0, 29, 9, 41, 6, 2, 3, 9, 0, 10, 10, 47, 15, 406, 7, 2, 7, 17, 9, 57, 21, 2, 13, 123, 5, 4, 0, 2, 1, 2, 6, 2, 0, 9, 9, 49, 4, 2, 1, 2, 4, 9, 9, 330, 3, 19306, 9, 87, 9, 39, 4, 60, 6, 26, 9, 1014, 0, 2, 54, 8, 3, 82, 0, 12, 1, 19628, 1, 4706, 45, 3, 22, 543, 4, 4, 5, 9, 7, 3, 6, 31, 3, 149, 2, 1418, 49, 513, 54, 5, 49, 9, 0, 15, 0, 23, 4, 2, 14, 1361, 6, 2, 16, 3, 6, 2, 1, 2, 4, 262, 6, 10, 9, 357, 0, 62, 13, 1495, 6, 110, 6, 6, 9, 4759, 9, 787719, 239];\n\n// This file was generated. Do not modify manually!\nvar astralIdentifierStartCodes = [0, 11, 2, 25, 2, 18, 2, 1, 2, 14, 3, 13, 35, 122, 70, 52, 268, 28, 4, 48, 48, 31, 14, 29, 6, 37, 11, 29, 3, 35, 5, 7, 2, 4, 43, 157, 19, 35, 5, 35, 5, 39, 9, 51, 13, 10, 2, 14, 2, 6, 2, 1, 2, 10, 2, 14, 2, 6, 2, 1, 68, 310, 10, 21, 11, 7, 25, 5, 2, 41, 2, 8, 70, 5, 3, 0, 2, 43, 2, 1, 4, 0, 3, 22, 11, 22, 10, 30, 66, 18, 2, 1, 11, 21, 11, 25, 71, 55, 7, 1, 65, 0, 16, 3, 2, 2, 2, 28, 43, 28, 4, 28, 36, 7, 2, 27, 28, 53, 11, 21, 11, 18, 14, 17, 111, 72, 56, 50, 14, 50, 14, 35, 349, 41, 7, 1, 79, 28, 11, 0, 9, 21, 43, 17, 47, 20, 28, 22, 13, 52, 58, 1, 3, 0, 14, 44, 33, 24, 27, 35, 30, 0, 3, 0, 9, 34, 4, 0, 13, 47, 15, 3, 22, 0, 2, 0, 36, 17, 2, 24, 85, 6, 2, 0, 2, 3, 2, 14, 2, 9, 8, 46, 39, 7, 3, 1, 3, 21, 2, 6, 2, 1, 2, 4, 4, 0, 19, 0, 13, 4, 159, 52, 19, 3, 21, 2, 31, 47, 21, 1, 2, 0, 185, 46, 42, 3, 37, 47, 21, 0, 60, 42, 14, 0, 72, 26, 38, 6, 186, 43, 117, 63, 32, 7, 3, 0, 3, 7, 2, 1, 2, 23, 16, 0, 2, 0, 95, 7, 3, 38, 17, 0, 2, 0, 29, 0, 11, 39, 8, 0, 22, 0, 12, 45, 20, 0, 19, 72, 264, 8, 2, 36, 18, 0, 50, 29, 113, 6, 2, 1, 2, 37, 22, 0, 26, 5, 2, 1, 2, 31, 15, 0, 328, 18, 190, 0, 80, 921, 103, 110, 18, 195, 2637, 96, 16, 1070, 4050, 582, 8634, 568, 8, 30, 18, 78, 18, 29, 19, 47, 17, 3, 32, 20, 6, 18, 689, 63, 129, 74, 6, 0, 67, 12, 65, 1, 2, 0, 29, 6135, 9, 1237, 43, 8, 8936, 3, 2, 6, 2, 1, 2, 290, 46, 2, 18, 3, 9, 395, 2309, 106, 6, 12, 4, 8, 8, 9, 5991, 84, 2, 70, 2, 1, 3, 0, 3, 1, 3, 3, 2, 11, 2, 0, 2, 6, 2, 64, 2, 3, 3, 7, 2, 6, 2, 27, 2, 3, 2, 4, 2, 0, 4, 6, 2, 339, 3, 24, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 7, 1845, 30, 482, 44, 11, 6, 17, 0, 322, 29, 19, 43, 1269, 6, 2, 3, 2, 1, 2, 14, 2, 196, 60, 67, 8, 0, 1205, 3, 2, 26, 2, 1, 2, 0, 3, 0, 2, 9, 2, 3, 2, 0, 2, 0, 7, 0, 5, 0, 2, 0, 2, 0, 2, 2, 2, 1, 2, 0, 3, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 3, 3, 2, 6, 2, 3, 2, 3, 2, 0, 2, 9, 2, 16, 6, 2, 2, 4, 2, 16, 4421, 42719, 33, 4152, 8, 221, 3, 5761, 15, 7472, 3104, 541, 1507, 4938];\n\n// This file was generated. Do not modify manually!\nvar nonASCIIidentifierChars = \"\\u200c\\u200d\\xb7\\u0300-\\u036f\\u0387\\u0483-\\u0487\\u0591-\\u05bd\\u05bf\\u05c1\\u05c2\\u05c4\\u05c5\\u05c7\\u0610-\\u061a\\u064b-\\u0669\\u0670\\u06d6-\\u06dc\\u06df-\\u06e4\\u06e7\\u06e8\\u06ea-\\u06ed\\u06f0-\\u06f9\\u0711\\u0730-\\u074a\\u07a6-\\u07b0\\u07c0-\\u07c9\\u07eb-\\u07f3\\u07fd\\u0816-\\u0819\\u081b-\\u0823\\u0825-\\u0827\\u0829-\\u082d\\u0859-\\u085b\\u0898-\\u089f\\u08ca-\\u08e1\\u08e3-\\u0903\\u093a-\\u093c\\u093e-\\u094f\\u0951-\\u0957\\u0962\\u0963\\u0966-\\u096f\\u0981-\\u0983\\u09bc\\u09be-\\u09c4\\u09c7\\u09c8\\u09cb-\\u09cd\\u09d7\\u09e2\\u09e3\\u09e6-\\u09ef\\u09fe\\u0a01-\\u0a03\\u0a3c\\u0a3e-\\u0a42\\u0a47\\u0a48\\u0a4b-\\u0a4d\\u0a51\\u0a66-\\u0a71\\u0a75\\u0a81-\\u0a83\\u0abc\\u0abe-\\u0ac5\\u0ac7-\\u0ac9\\u0acb-\\u0acd\\u0ae2\\u0ae3\\u0ae6-\\u0aef\\u0afa-\\u0aff\\u0b01-\\u0b03\\u0b3c\\u0b3e-\\u0b44\\u0b47\\u0b48\\u0b4b-\\u0b4d\\u0b55-\\u0b57\\u0b62\\u0b63\\u0b66-\\u0b6f\\u0b82\\u0bbe-\\u0bc2\\u0bc6-\\u0bc8\\u0bca-\\u0bcd\\u0bd7\\u0be6-\\u0bef\\u0c00-\\u0c04\\u0c3c\\u0c3e-\\u0c44\\u0c46-\\u0c48\\u0c4a-\\u0c4d\\u0c55\\u0c56\\u0c62\\u0c63\\u0c66-\\u0c6f\\u0c81-\\u0c83\\u0cbc\\u0cbe-\\u0cc4\\u0cc6-\\u0cc8\\u0cca-\\u0ccd\\u0cd5\\u0cd6\\u0ce2\\u0ce3\\u0ce6-\\u0cef\\u0d00-\\u0d03\\u0d3b\\u0d3c\\u0d3e-\\u0d44\\u0d46-\\u0d48\\u0d4a-\\u0d4d\\u0d57\\u0d62\\u0d63\\u0d66-\\u0d6f\\u0d81-\\u0d83\\u0dca\\u0dcf-\\u0dd4\\u0dd6\\u0dd8-\\u0ddf\\u0de6-\\u0def\\u0df2\\u0df3\\u0e31\\u0e34-\\u0e3a\\u0e47-\\u0e4e\\u0e50-\\u0e59\\u0eb1\\u0eb4-\\u0ebc\\u0ec8-\\u0ecd\\u0ed0-\\u0ed9\\u0f18\\u0f19\\u0f20-\\u0f29\\u0f35\\u0f37\\u0f39\\u0f3e\\u0f3f\\u0f71-\\u0f84\\u0f86\\u0f87\\u0f8d-\\u0f97\\u0f99-\\u0fbc\\u0fc6\\u102b-\\u103e\\u1040-\\u1049\\u1056-\\u1059\\u105e-\\u1060\\u1062-\\u1064\\u1067-\\u106d\\u1071-\\u1074\\u1082-\\u108d\\u108f-\\u109d\\u135d-\\u135f\\u1369-\\u1371\\u1712-\\u1715\\u1732-\\u1734\\u1752\\u1753\\u1772\\u1773\\u17b4-\\u17d3\\u17dd\\u17e0-\\u17e9\\u180b-\\u180d\\u180f-\\u1819\\u18a9\\u1920-\\u192b\\u1930-\\u193b\\u1946-\\u194f\\u19d0-\\u19da\\u1a17-\\u1a1b\\u1a55-\\u1a5e\\u1a60-\\u1a7c\\u1a7f-\\u1a89\\u1a90-\\u1a99\\u1ab0-\\u1abd\\u1abf-\\u1ace\\u1b00-\\u1b04\\u1b34-\\u1b44\\u1b50-\\u1b59\\u1b6b-\\u1b73\\u1b80-\\u1b82\\u1ba1-\\u1bad\\u1bb0-\\u1bb9\\u1be6-\\u1bf3\\u1c24-\\u1c37\\u1c40-\\u1c49\\u1c50-\\u1c59\\u1cd0-\\u1cd2\\u1cd4-\\u1ce8\\u1ced\\u1cf4\\u1cf7-\\u1cf9\\u1dc0-\\u1dff\\u203f\\u2040\\u2054\\u20d0-\\u20dc\\u20e1\\u20e5-\\u20f0\\u2cef-\\u2cf1\\u2d7f\\u2de0-\\u2dff\\u302a-\\u302f\\u3099\\u309a\\ua620-\\ua629\\ua66f\\ua674-\\ua67d\\ua69e\\ua69f\\ua6f0\\ua6f1\\ua802\\ua806\\ua80b\\ua823-\\ua827\\ua82c\\ua880\\ua881\\ua8b4-\\ua8c5\\ua8d0-\\ua8d9\\ua8e0-\\ua8f1\\ua8ff-\\ua909\\ua926-\\ua92d\\ua947-\\ua953\\ua980-\\ua983\\ua9b3-\\ua9c0\\ua9d0-\\ua9d9\\ua9e5\\ua9f0-\\ua9f9\\uaa29-\\uaa36\\uaa43\\uaa4c\\uaa4d\\uaa50-\\uaa59\\uaa7b-\\uaa7d\\uaab0\\uaab2-\\uaab4\\uaab7\\uaab8\\uaabe\\uaabf\\uaac1\\uaaeb-\\uaaef\\uaaf5\\uaaf6\\uabe3-\\uabea\\uabec\\uabed\\uabf0-\\uabf9\\ufb1e\\ufe00-\\ufe0f\\ufe20-\\ufe2f\\ufe33\\ufe34\\ufe4d-\\ufe4f\\uff10-\\uff19\\uff3f\";\n\n// This file was generated. Do not modify manually!\nvar nonASCIIidentifierStartChars = \"\\xaa\\xb5\\xba\\xc0-\\xd6\\xd8-\\xf6\\xf8-\\u02c1\\u02c6-\\u02d1\\u02e0-\\u02e4\\u02ec\\u02ee\\u0370-\\u0374\\u0376\\u0377\\u037a-\\u037d\\u037f\\u0386\\u0388-\\u038a\\u038c\\u038e-\\u03a1\\u03a3-\\u03f5\\u03f7-\\u0481\\u048a-\\u052f\\u0531-\\u0556\\u0559\\u0560-\\u0588\\u05d0-\\u05ea\\u05ef-\\u05f2\\u0620-\\u064a\\u066e\\u066f\\u0671-\\u06d3\\u06d5\\u06e5\\u06e6\\u06ee\\u06ef\\u06fa-\\u06fc\\u06ff\\u0710\\u0712-\\u072f\\u074d-\\u07a5\\u07b1\\u07ca-\\u07ea\\u07f4\\u07f5\\u07fa\\u0800-\\u0815\\u081a\\u0824\\u0828\\u0840-\\u0858\\u0860-\\u086a\\u0870-\\u0887\\u0889-\\u088e\\u08a0-\\u08c9\\u0904-\\u0939\\u093d\\u0950\\u0958-\\u0961\\u0971-\\u0980\\u0985-\\u098c\\u098f\\u0990\\u0993-\\u09a8\\u09aa-\\u09b0\\u09b2\\u09b6-\\u09b9\\u09bd\\u09ce\\u09dc\\u09dd\\u09df-\\u09e1\\u09f0\\u09f1\\u09fc\\u0a05-\\u0a0a\\u0a0f\\u0a10\\u0a13-\\u0a28\\u0a2a-\\u0a30\\u0a32\\u0a33\\u0a35\\u0a36\\u0a38\\u0a39\\u0a59-\\u0a5c\\u0a5e\\u0a72-\\u0a74\\u0a85-\\u0a8d\\u0a8f-\\u0a91\\u0a93-\\u0aa8\\u0aaa-\\u0ab0\\u0ab2\\u0ab3\\u0ab5-\\u0ab9\\u0abd\\u0ad0\\u0ae0\\u0ae1\\u0af9\\u0b05-\\u0b0c\\u0b0f\\u0b10\\u0b13-\\u0b28\\u0b2a-\\u0b30\\u0b32\\u0b33\\u0b35-\\u0b39\\u0b3d\\u0b5c\\u0b5d\\u0b5f-\\u0b61\\u0b71\\u0b83\\u0b85-\\u0b8a\\u0b8e-\\u0b90\\u0b92-\\u0b95\\u0b99\\u0b9a\\u0b9c\\u0b9e\\u0b9f\\u0ba3\\u0ba4\\u0ba8-\\u0baa\\u0bae-\\u0bb9\\u0bd0\\u0c05-\\u0c0c\\u0c0e-\\u0c10\\u0c12-\\u0c28\\u0c2a-\\u0c39\\u0c3d\\u0c58-\\u0c5a\\u0c5d\\u0c60\\u0c61\\u0c80\\u0c85-\\u0c8c\\u0c8e-\\u0c90\\u0c92-\\u0ca8\\u0caa-\\u0cb3\\u0cb5-\\u0cb9\\u0cbd\\u0cdd\\u0cde\\u0ce0\\u0ce1\\u0cf1\\u0cf2\\u0d04-\\u0d0c\\u0d0e-\\u0d10\\u0d12-\\u0d3a\\u0d3d\\u0d4e\\u0d54-\\u0d56\\u0d5f-\\u0d61\\u0d7a-\\u0d7f\\u0d85-\\u0d96\\u0d9a-\\u0db1\\u0db3-\\u0dbb\\u0dbd\\u0dc0-\\u0dc6\\u0e01-\\u0e30\\u0e32\\u0e33\\u0e40-\\u0e46\\u0e81\\u0e82\\u0e84\\u0e86-\\u0e8a\\u0e8c-\\u0ea3\\u0ea5\\u0ea7-\\u0eb0\\u0eb2\\u0eb3\\u0ebd\\u0ec0-\\u0ec4\\u0ec6\\u0edc-\\u0edf\\u0f00\\u0f40-\\u0f47\\u0f49-\\u0f6c\\u0f88-\\u0f8c\\u1000-\\u102a\\u103f\\u1050-\\u1055\\u105a-\\u105d\\u1061\\u1065\\u1066\\u106e-\\u1070\\u1075-\\u1081\\u108e\\u10a0-\\u10c5\\u10c7\\u10cd\\u10d0-\\u10fa\\u10fc-\\u1248\\u124a-\\u124d\\u1250-\\u1256\\u1258\\u125a-\\u125d\\u1260-\\u1288\\u128a-\\u128d\\u1290-\\u12b0\\u12b2-\\u12b5\\u12b8-\\u12be\\u12c0\\u12c2-\\u12c5\\u12c8-\\u12d6\\u12d8-\\u1310\\u1312-\\u1315\\u1318-\\u135a\\u1380-\\u138f\\u13a0-\\u13f5\\u13f8-\\u13fd\\u1401-\\u166c\\u166f-\\u167f\\u1681-\\u169a\\u16a0-\\u16ea\\u16ee-\\u16f8\\u1700-\\u1711\\u171f-\\u1731\\u1740-\\u1751\\u1760-\\u176c\\u176e-\\u1770\\u1780-\\u17b3\\u17d7\\u17dc\\u1820-\\u1878\\u1880-\\u18a8\\u18aa\\u18b0-\\u18f5\\u1900-\\u191e\\u1950-\\u196d\\u1970-\\u1974\\u1980-\\u19ab\\u19b0-\\u19c9\\u1a00-\\u1a16\\u1a20-\\u1a54\\u1aa7\\u1b05-\\u1b33\\u1b45-\\u1b4c\\u1b83-\\u1ba0\\u1bae\\u1baf\\u1bba-\\u1be5\\u1c00-\\u1c23\\u1c4d-\\u1c4f\\u1c5a-\\u1c7d\\u1c80-\\u1c88\\u1c90-\\u1cba\\u1cbd-\\u1cbf\\u1ce9-\\u1cec\\u1cee-\\u1cf3\\u1cf5\\u1cf6\\u1cfa\\u1d00-\\u1dbf\\u1e00-\\u1f15\\u1f18-\\u1f1d\\u1f20-\\u1f45\\u1f48-\\u1f4d\\u1f50-\\u1f57\\u1f59\\u1f5b\\u1f5d\\u1f5f-\\u1f7d\\u1f80-\\u1fb4\\u1fb6-\\u1fbc\\u1fbe\\u1fc2-\\u1fc4\\u1fc6-\\u1fcc\\u1fd0-\\u1fd3\\u1fd6-\\u1fdb\\u1fe0-\\u1fec\\u1ff2-\\u1ff4\\u1ff6-\\u1ffc\\u2071\\u207f\\u2090-\\u209c\\u2102\\u2107\\u210a-\\u2113\\u2115\\u2118-\\u211d\\u2124\\u2126\\u2128\\u212a-\\u2139\\u213c-\\u213f\\u2145-\\u2149\\u214e\\u2160-\\u2188\\u2c00-\\u2ce4\\u2ceb-\\u2cee\\u2cf2\\u2cf3\\u2d00-\\u2d25\\u2d27\\u2d2d\\u2d30-\\u2d67\\u2d6f\\u2d80-\\u2d96\\u2da0-\\u2da6\\u2da8-\\u2dae\\u2db0-\\u2db6\\u2db8-\\u2dbe\\u2dc0-\\u2dc6\\u2dc8-\\u2dce\\u2dd0-\\u2dd6\\u2dd8-\\u2dde\\u3005-\\u3007\\u3021-\\u3029\\u3031-\\u3035\\u3038-\\u303c\\u3041-\\u3096\\u309b-\\u309f\\u30a1-\\u30fa\\u30fc-\\u30ff\\u3105-\\u312f\\u3131-\\u318e\\u31a0-\\u31bf\\u31f0-\\u31ff\\u3400-\\u4dbf\\u4e00-\\ua48c\\ua4d0-\\ua4fd\\ua500-\\ua60c\\ua610-\\ua61f\\ua62a\\ua62b\\ua640-\\ua66e\\ua67f-\\ua69d\\ua6a0-\\ua6ef\\ua717-\\ua71f\\ua722-\\ua788\\ua78b-\\ua7ca\\ua7d0\\ua7d1\\ua7d3\\ua7d5-\\ua7d9\\ua7f2-\\ua801\\ua803-\\ua805\\ua807-\\ua80a\\ua80c-\\ua822\\ua840-\\ua873\\ua882-\\ua8b3\\ua8f2-\\ua8f7\\ua8fb\\ua8fd\\ua8fe\\ua90a-\\ua925\\ua930-\\ua946\\ua960-\\ua97c\\ua984-\\ua9b2\\ua9cf\\ua9e0-\\ua9e4\\ua9e6-\\ua9ef\\ua9fa-\\ua9fe\\uaa00-\\uaa28\\uaa40-\\uaa42\\uaa44-\\uaa4b\\uaa60-\\uaa76\\uaa7a\\uaa7e-\\uaaaf\\uaab1\\uaab5\\uaab6\\uaab9-\\uaabd\\uaac0\\uaac2\\uaadb-\\uaadd\\uaae0-\\uaaea\\uaaf2-\\uaaf4\\uab01-\\uab06\\uab09-\\uab0e\\uab11-\\uab16\\uab20-\\uab26\\uab28-\\uab2e\\uab30-\\uab5a\\uab5c-\\uab69\\uab70-\\uabe2\\uac00-\\ud7a3\\ud7b0-\\ud7c6\\ud7cb-\\ud7fb\\uf900-\\ufa6d\\ufa70-\\ufad9\\ufb00-\\ufb06\\ufb13-\\ufb17\\ufb1d\\ufb1f-\\ufb28\\ufb2a-\\ufb36\\ufb38-\\ufb3c\\ufb3e\\ufb40\\ufb41\\ufb43\\ufb44\\ufb46-\\ufbb1\\ufbd3-\\ufd3d\\ufd50-\\ufd8f\\ufd92-\\ufdc7\\ufdf0-\\ufdfb\\ufe70-\\ufe74\\ufe76-\\ufefc\\uff21-\\uff3a\\uff41-\\uff5a\\uff66-\\uffbe\\uffc2-\\uffc7\\uffca-\\uffcf\\uffd2-\\uffd7\\uffda-\\uffdc\";\n\n// These are a run-length and offset encoded representation of the\n\n// Reserved word lists for various dialects of the language\n\nvar reservedWords = {\n 3: \"abstract boolean byte char class double enum export extends final float goto implements import int interface long native package private protected public short static super synchronized throws transient volatile\",\n 5: \"class enum extends super const export import\",\n 6: \"enum\",\n strict: \"implements interface let package private protected public static yield\",\n strictBind: \"eval arguments\"\n};\n\n// And the keywords\n\nvar ecma5AndLessKeywords = \"break case catch continue debugger default do else finally for function if return switch throw try var while with null true false instanceof typeof void delete new in this\";\n\nvar keywords$1 = {\n 5: ecma5AndLessKeywords,\n \"5module\": ecma5AndLessKeywords + \" export import\",\n 6: ecma5AndLessKeywords + \" const class extends export import super\"\n};\n\nvar keywordRelationalOperator = /^in(stanceof)?$/;\n\n// ## Character categories\n\nvar nonASCIIidentifierStart = new RegExp(\"[\" + nonASCIIidentifierStartChars + \"]\");\nvar nonASCIIidentifier = new RegExp(\"[\" + nonASCIIidentifierStartChars + nonASCIIidentifierChars + \"]\");\n\n// This has a complexity linear to the value of the code. The\n// assumption is that looking up astral identifier characters is\n// rare.\nfunction isInAstralSet(code, set) {\n var pos = 0x10000;\n for (var i = 0; i < set.length; i += 2) {\n pos += set[i];\n if (pos > code) { return false }\n pos += set[i + 1];\n if (pos >= code) { return true }\n }\n}\n\n// Test whether a given character code starts an identifier.\n\nfunction isIdentifierStart(code, astral) {\n if (code < 65) { return code === 36 }\n if (code < 91) { return true }\n if (code < 97) { return code === 95 }\n if (code < 123) { return true }\n if (code <= 0xffff) { return code >= 0xaa && nonASCIIidentifierStart.test(String.fromCharCode(code)) }\n if (astral === false) { return false }\n return isInAstralSet(code, astralIdentifierStartCodes)\n}\n\n// Test whether a given character is part of an identifier.\n\nfunction isIdentifierChar(code, astral) {\n if (code < 48) { return code === 36 }\n if (code < 58) { return true }\n if (code < 65) { return false }\n if (code < 91) { return true }\n if (code < 97) { return code === 95 }\n if (code < 123) { return true }\n if (code <= 0xffff) { return code >= 0xaa && nonASCIIidentifier.test(String.fromCharCode(code)) }\n if (astral === false) { return false }\n return isInAstralSet(code, astralIdentifierStartCodes) || isInAstralSet(code, astralIdentifierCodes)\n}\n\n// ## Token types\n\n// The assignment of fine-grained, information-carrying type objects\n// allows the tokenizer to store the information it has about a\n// token in a way that is very cheap for the parser to look up.\n\n// All token type variables start with an underscore, to make them\n// easy to recognize.\n\n// The `beforeExpr` property is used to disambiguate between regular\n// expressions and divisions. It is set on all token types that can\n// be followed by an expression (thus, a slash after them would be a\n// regular expression).\n//\n// The `startsExpr` property is used to check if the token ends a\n// `yield` expression. It is set on all token types that either can\n// directly start an expression (like a quotation mark) or can\n// continue an expression (like the body of a string).\n//\n// `isLoop` marks a keyword as starting a loop, which is important\n// to know when parsing a label, in order to allow or disallow\n// continue jumps to that label.\n\nvar TokenType = function TokenType(label, conf) {\n if ( conf === void 0 ) conf = {};\n\n this.label = label;\n this.keyword = conf.keyword;\n this.beforeExpr = !!conf.beforeExpr;\n this.startsExpr = !!conf.startsExpr;\n this.isLoop = !!conf.isLoop;\n this.isAssign = !!conf.isAssign;\n this.prefix = !!conf.prefix;\n this.postfix = !!conf.postfix;\n this.binop = conf.binop || null;\n this.updateContext = null;\n};\n\nfunction binop(name, prec) {\n return new TokenType(name, {beforeExpr: true, binop: prec})\n}\nvar beforeExpr = {beforeExpr: true}, startsExpr = {startsExpr: true};\n\n// Map keyword names to token types.\n\nvar keywords = {};\n\n// Succinct definitions of keyword token types\nfunction kw(name, options) {\n if ( options === void 0 ) options = {};\n\n options.keyword = name;\n return keywords[name] = new TokenType(name, options)\n}\n\nvar types$1 = {\n num: new TokenType(\"num\", startsExpr),\n regexp: new TokenType(\"regexp\", startsExpr),\n string: new TokenType(\"string\", startsExpr),\n name: new TokenType(\"name\", startsExpr),\n privateId: new TokenType(\"privateId\", startsExpr),\n eof: new TokenType(\"eof\"),\n\n // Punctuation token types.\n bracketL: new TokenType(\"[\", {beforeExpr: true, startsExpr: true}),\n bracketR: new TokenType(\"]\"),\n braceL: new TokenType(\"{\", {beforeExpr: true, startsExpr: true}),\n braceR: new TokenType(\"}\"),\n parenL: new TokenType(\"(\", {beforeExpr: true, startsExpr: true}),\n parenR: new TokenType(\")\"),\n comma: new TokenType(\",\", beforeExpr),\n semi: new TokenType(\";\", beforeExpr),\n colon: new TokenType(\":\", beforeExpr),\n dot: new TokenType(\".\"),\n question: new TokenType(\"?\", beforeExpr),\n questionDot: new TokenType(\"?.\"),\n arrow: new TokenType(\"=>\", beforeExpr),\n template: new TokenType(\"template\"),\n invalidTemplate: new TokenType(\"invalidTemplate\"),\n ellipsis: new TokenType(\"...\", beforeExpr),\n backQuote: new TokenType(\"`\", startsExpr),\n dollarBraceL: new TokenType(\"${\", {beforeExpr: true, startsExpr: true}),\n\n // Operators. These carry several kinds of properties to help the\n // parser use them properly (the presence of these properties is\n // what categorizes them as operators).\n //\n // `binop`, when present, specifies that this operator is a binary\n // operator, and will refer to its precedence.\n //\n // `prefix` and `postfix` mark the operator as a prefix or postfix\n // unary operator.\n //\n // `isAssign` marks all of `=`, `+=`, `-=` etcetera, which act as\n // binary operators with a very low precedence, that should result\n // in AssignmentExpression nodes.\n\n eq: new TokenType(\"=\", {beforeExpr: true, isAssign: true}),\n assign: new TokenType(\"_=\", {beforeExpr: true, isAssign: true}),\n incDec: new TokenType(\"++/--\", {prefix: true, postfix: true, startsExpr: true}),\n prefix: new TokenType(\"!/~\", {beforeExpr: true, prefix: true, startsExpr: true}),\n logicalOR: binop(\"||\", 1),\n logicalAND: binop(\"&&\", 2),\n bitwiseOR: binop(\"|\", 3),\n bitwiseXOR: binop(\"^\", 4),\n bitwiseAND: binop(\"&\", 5),\n equality: binop(\"==/!=/===/!==\", 6),\n relational: binop(\"/<=/>=\", 7),\n bitShift: binop(\"<>/>>>\", 8),\n plusMin: new TokenType(\"+/-\", {beforeExpr: true, binop: 9, prefix: true, startsExpr: true}),\n modulo: binop(\"%\", 10),\n star: binop(\"*\", 10),\n slash: binop(\"/\", 10),\n starstar: new TokenType(\"**\", {beforeExpr: true}),\n coalesce: binop(\"??\", 1),\n\n // Keyword token types.\n _break: kw(\"break\"),\n _case: kw(\"case\", beforeExpr),\n _catch: kw(\"catch\"),\n _continue: kw(\"continue\"),\n _debugger: kw(\"debugger\"),\n _default: kw(\"default\", beforeExpr),\n _do: kw(\"do\", {isLoop: true, beforeExpr: true}),\n _else: kw(\"else\", beforeExpr),\n _finally: kw(\"finally\"),\n _for: kw(\"for\", {isLoop: true}),\n _function: kw(\"function\", startsExpr),\n _if: kw(\"if\"),\n _return: kw(\"return\", beforeExpr),\n _switch: kw(\"switch\"),\n _throw: kw(\"throw\", beforeExpr),\n _try: kw(\"try\"),\n _var: kw(\"var\"),\n _const: kw(\"const\"),\n _while: kw(\"while\", {isLoop: true}),\n _with: kw(\"with\"),\n _new: kw(\"new\", {beforeExpr: true, startsExpr: true}),\n _this: kw(\"this\", startsExpr),\n _super: kw(\"super\", startsExpr),\n _class: kw(\"class\", startsExpr),\n _extends: kw(\"extends\", beforeExpr),\n _export: kw(\"export\"),\n _import: kw(\"import\", startsExpr),\n _null: kw(\"null\", startsExpr),\n _true: kw(\"true\", startsExpr),\n _false: kw(\"false\", startsExpr),\n _in: kw(\"in\", {beforeExpr: true, binop: 7}),\n _instanceof: kw(\"instanceof\", {beforeExpr: true, binop: 7}),\n _typeof: kw(\"typeof\", {beforeExpr: true, prefix: true, startsExpr: true}),\n _void: kw(\"void\", {beforeExpr: true, prefix: true, startsExpr: true}),\n _delete: kw(\"delete\", {beforeExpr: true, prefix: true, startsExpr: true})\n};\n\n// Matches a whole line break (where CRLF is considered a single\n// line break). Used to count lines.\n\nvar lineBreak = /\\r\\n?|\\n|\\u2028|\\u2029/;\nvar lineBreakG = new RegExp(lineBreak.source, \"g\");\n\nfunction isNewLine(code) {\n return code === 10 || code === 13 || code === 0x2028 || code === 0x2029\n}\n\nfunction nextLineBreak(code, from, end) {\n if ( end === void 0 ) end = code.length;\n\n for (var i = from; i < end; i++) {\n var next = code.charCodeAt(i);\n if (isNewLine(next))\n { return i < end - 1 && next === 13 && code.charCodeAt(i + 1) === 10 ? i + 2 : i + 1 }\n }\n return -1\n}\n\nvar nonASCIIwhitespace = /[\\u1680\\u2000-\\u200a\\u202f\\u205f\\u3000\\ufeff]/;\n\nvar skipWhiteSpace = /(?:\\s|\\/\\/.*|\\/\\*[^]*?\\*\\/)*/g;\n\nvar ref = Object.prototype;\nvar hasOwnProperty = ref.hasOwnProperty;\nvar toString = ref.toString;\n\nvar hasOwn = Object.hasOwn || (function (obj, propName) { return (\n hasOwnProperty.call(obj, propName)\n); });\n\nvar isArray = Array.isArray || (function (obj) { return (\n toString.call(obj) === \"[object Array]\"\n); });\n\nfunction wordsRegexp(words) {\n return new RegExp(\"^(?:\" + words.replace(/ /g, \"|\") + \")$\")\n}\n\nfunction codePointToString(code) {\n // UTF-16 Decoding\n if (code <= 0xFFFF) { return String.fromCharCode(code) }\n code -= 0x10000;\n return String.fromCharCode((code >> 10) + 0xD800, (code & 1023) + 0xDC00)\n}\n\nvar loneSurrogate = /(?:[\\uD800-\\uDBFF](?![\\uDC00-\\uDFFF])|(?:[^\\uD800-\\uDBFF]|^)[\\uDC00-\\uDFFF])/;\n\n// These are used when `options.locations` is on, for the\n// `startLoc` and `endLoc` properties.\n\nvar Position = function Position(line, col) {\n this.line = line;\n this.column = col;\n};\n\nPosition.prototype.offset = function offset (n) {\n return new Position(this.line, this.column + n)\n};\n\nvar SourceLocation = function SourceLocation(p, start, end) {\n this.start = start;\n this.end = end;\n if (p.sourceFile !== null) { this.source = p.sourceFile; }\n};\n\n// The `getLineInfo` function is mostly useful when the\n// `locations` option is off (for performance reasons) and you\n// want to find the line/column position for a given character\n// offset. `input` should be the code string that the offset refers\n// into.\n\nfunction getLineInfo(input, offset) {\n for (var line = 1, cur = 0;;) {\n var nextBreak = nextLineBreak(input, cur, offset);\n if (nextBreak < 0) { return new Position(line, offset - cur) }\n ++line;\n cur = nextBreak;\n }\n}\n\n// A second argument must be given to configure the parser process.\n// These options are recognized (only `ecmaVersion` is required):\n\nvar defaultOptions = {\n // `ecmaVersion` indicates the ECMAScript version to parse. Must be\n // either 3, 5, 6 (or 2015), 7 (2016), 8 (2017), 9 (2018), 10\n // (2019), 11 (2020), 12 (2021), 13 (2022), 14 (2023), or `\"latest\"`\n // (the latest version the library supports). This influences\n // support for strict mode, the set of reserved words, and support\n // for new syntax features.\n ecmaVersion: null,\n // `sourceType` indicates the mode the code should be parsed in.\n // Can be either `\"script\"` or `\"module\"`. This influences global\n // strict mode and parsing of `import` and `export` declarations.\n sourceType: \"script\",\n // `onInsertedSemicolon` can be a callback that will be called\n // when a semicolon is automatically inserted. It will be passed\n // the position of the comma as an offset, and if `locations` is\n // enabled, it is given the location as a `{line, column}` object\n // as second argument.\n onInsertedSemicolon: null,\n // `onTrailingComma` is similar to `onInsertedSemicolon`, but for\n // trailing commas.\n onTrailingComma: null,\n // By default, reserved words are only enforced if ecmaVersion >= 5.\n // Set `allowReserved` to a boolean value to explicitly turn this on\n // an off. When this option has the value \"never\", reserved words\n // and keywords can also not be used as property names.\n allowReserved: null,\n // When enabled, a return at the top level is not considered an\n // error.\n allowReturnOutsideFunction: false,\n // When enabled, import/export statements are not constrained to\n // appearing at the top of the program, and an import.meta expression\n // in a script isn't considered an error.\n allowImportExportEverywhere: false,\n // By default, await identifiers are allowed to appear at the top-level scope only if ecmaVersion >= 2022.\n // When enabled, await identifiers are allowed to appear at the top-level scope,\n // but they are still not allowed in non-async functions.\n allowAwaitOutsideFunction: null,\n // When enabled, super identifiers are not constrained to\n // appearing in methods and do not raise an error when they appear elsewhere.\n allowSuperOutsideMethod: null,\n // When enabled, hashbang directive in the beginning of file is\n // allowed and treated as a line comment. Enabled by default when\n // `ecmaVersion` >= 2023.\n allowHashBang: false,\n // When `locations` is on, `loc` properties holding objects with\n // `start` and `end` properties in `{line, column}` form (with\n // line being 1-based and column 0-based) will be attached to the\n // nodes.\n locations: false,\n // A function can be passed as `onToken` option, which will\n // cause Acorn to call that function with object in the same\n // format as tokens returned from `tokenizer().getToken()`. Note\n // that you are not allowed to call the parser from the\n // callback\u2014that will corrupt its internal state.\n onToken: null,\n // A function can be passed as `onComment` option, which will\n // cause Acorn to call that function with `(block, text, start,\n // end)` parameters whenever a comment is skipped. `block` is a\n // boolean indicating whether this is a block (`/* */`) comment,\n // `text` is the content of the comment, and `start` and `end` are\n // character offsets that denote the start and end of the comment.\n // When the `locations` option is on, two more parameters are\n // passed, the full `{line, column}` locations of the start and\n // end of the comments. Note that you are not allowed to call the\n // parser from the callback\u2014that will corrupt its internal state.\n onComment: null,\n // Nodes have their start and end characters offsets recorded in\n // `start` and `end` properties (directly on the node, rather than\n // the `loc` object, which holds line/column data. To also add a\n // [semi-standardized][range] `range` property holding a `[start,\n // end]` array with the same numbers, set the `ranges` option to\n // `true`.\n //\n // [range]: https://bugzilla.mozilla.org/show_bug.cgi?id=745678\n ranges: false,\n // It is possible to parse multiple files into a single AST by\n // passing the tree produced by parsing the first file as\n // `program` option in subsequent parses. This will add the\n // toplevel forms of the parsed file to the `Program` (top) node\n // of an existing parse tree.\n program: null,\n // When `locations` is on, you can pass this to record the source\n // file in every node's `loc` object.\n sourceFile: null,\n // This value, if given, is stored in every node, whether\n // `locations` is on or off.\n directSourceFile: null,\n // When enabled, parenthesized expressions are represented by\n // (non-standard) ParenthesizedExpression nodes\n preserveParens: false\n};\n\n// Interpret and default an options object\n\nvar warnedAboutEcmaVersion = false;\n\nfunction getOptions(opts) {\n var options = {};\n\n for (var opt in defaultOptions)\n { options[opt] = opts && hasOwn(opts, opt) ? opts[opt] : defaultOptions[opt]; }\n\n if (options.ecmaVersion === \"latest\") {\n options.ecmaVersion = 1e8;\n } else if (options.ecmaVersion == null) {\n if (!warnedAboutEcmaVersion && typeof console === \"object\" && console.warn) {\n warnedAboutEcmaVersion = true;\n console.warn(\"Since Acorn 8.0.0, options.ecmaVersion is required.\\nDefaulting to 2020, but this will stop working in the future.\");\n }\n options.ecmaVersion = 11;\n } else if (options.ecmaVersion >= 2015) {\n options.ecmaVersion -= 2009;\n }\n\n if (options.allowReserved == null)\n { options.allowReserved = options.ecmaVersion < 5; }\n\n if (opts.allowHashBang == null)\n { options.allowHashBang = options.ecmaVersion >= 14; }\n\n if (isArray(options.onToken)) {\n var tokens = options.onToken;\n options.onToken = function (token) { return tokens.push(token); };\n }\n if (isArray(options.onComment))\n { options.onComment = pushComment(options, options.onComment); }\n\n return options\n}\n\nfunction pushComment(options, array) {\n return function(block, text, start, end, startLoc, endLoc) {\n var comment = {\n type: block ? \"Block\" : \"Line\",\n value: text,\n start: start,\n end: end\n };\n if (options.locations)\n { comment.loc = new SourceLocation(this, startLoc, endLoc); }\n if (options.ranges)\n { comment.range = [start, end]; }\n array.push(comment);\n }\n}\n\n// Each scope gets a bitset that may contain these flags\nvar\n SCOPE_TOP = 1,\n SCOPE_FUNCTION = 2,\n SCOPE_ASYNC = 4,\n SCOPE_GENERATOR = 8,\n SCOPE_ARROW = 16,\n SCOPE_SIMPLE_CATCH = 32,\n SCOPE_SUPER = 64,\n SCOPE_DIRECT_SUPER = 128,\n SCOPE_CLASS_STATIC_BLOCK = 256,\n SCOPE_VAR = SCOPE_TOP | SCOPE_FUNCTION | SCOPE_CLASS_STATIC_BLOCK;\n\nfunction functionFlags(async, generator) {\n return SCOPE_FUNCTION | (async ? SCOPE_ASYNC : 0) | (generator ? SCOPE_GENERATOR : 0)\n}\n\n// Used in checkLVal* and declareName to determine the type of a binding\nvar\n BIND_NONE = 0, // Not a binding\n BIND_VAR = 1, // Var-style binding\n BIND_LEXICAL = 2, // Let- or const-style binding\n BIND_FUNCTION = 3, // Function declaration\n BIND_SIMPLE_CATCH = 4, // Simple (identifier pattern) catch binding\n BIND_OUTSIDE = 5; // Special case for function names as bound inside the function\n\nvar Parser = function Parser(options, input, startPos) {\n this.options = options = getOptions(options);\n this.sourceFile = options.sourceFile;\n this.keywords = wordsRegexp(keywords$1[options.ecmaVersion >= 6 ? 6 : options.sourceType === \"module\" ? \"5module\" : 5]);\n var reserved = \"\";\n if (options.allowReserved !== true) {\n reserved = reservedWords[options.ecmaVersion >= 6 ? 6 : options.ecmaVersion === 5 ? 5 : 3];\n if (options.sourceType === \"module\") { reserved += \" await\"; }\n }\n this.reservedWords = wordsRegexp(reserved);\n var reservedStrict = (reserved ? reserved + \" \" : \"\") + reservedWords.strict;\n this.reservedWordsStrict = wordsRegexp(reservedStrict);\n this.reservedWordsStrictBind = wordsRegexp(reservedStrict + \" \" + reservedWords.strictBind);\n this.input = String(input);\n\n // Used to signal to callers of `readWord1` whether the word\n // contained any escape sequences. This is needed because words with\n // escape sequences must not be interpreted as keywords.\n this.containsEsc = false;\n\n // Set up token state\n\n // The current position of the tokenizer in the input.\n if (startPos) {\n this.pos = startPos;\n this.lineStart = this.input.lastIndexOf(\"\\n\", startPos - 1) + 1;\n this.curLine = this.input.slice(0, this.lineStart).split(lineBreak).length;\n } else {\n this.pos = this.lineStart = 0;\n this.curLine = 1;\n }\n\n // Properties of the current token:\n // Its type\n this.type = types$1.eof;\n // For tokens that include more information than their type, the value\n this.value = null;\n // Its start and end offset\n this.start = this.end = this.pos;\n // And, if locations are used, the {line, column} object\n // corresponding to those offsets\n this.startLoc = this.endLoc = this.curPosition();\n\n // Position information for the previous token\n this.lastTokEndLoc = this.lastTokStartLoc = null;\n this.lastTokStart = this.lastTokEnd = this.pos;\n\n // The context stack is used to superficially track syntactic\n // context to predict whether a regular expression is allowed in a\n // given position.\n this.context = this.initialContext();\n this.exprAllowed = true;\n\n // Figure out if it's a module code.\n this.inModule = options.sourceType === \"module\";\n this.strict = this.inModule || this.strictDirective(this.pos);\n\n // Used to signify the start of a potential arrow function\n this.potentialArrowAt = -1;\n this.potentialArrowInForAwait = false;\n\n // Positions to delayed-check that yield/await does not exist in default parameters.\n this.yieldPos = this.awaitPos = this.awaitIdentPos = 0;\n // Labels in scope.\n this.labels = [];\n // Thus-far undefined exports.\n this.undefinedExports = Object.create(null);\n\n // If enabled, skip leading hashbang line.\n if (this.pos === 0 && options.allowHashBang && this.input.slice(0, 2) === \"#!\")\n { this.skipLineComment(2); }\n\n // Scope tracking for duplicate variable names (see scope.js)\n this.scopeStack = [];\n this.enterScope(SCOPE_TOP);\n\n // For RegExp validation\n this.regexpState = null;\n\n // The stack of private names.\n // Each element has two properties: 'declared' and 'used'.\n // When it exited from the outermost class definition, all used private names must be declared.\n this.privateNameStack = [];\n};\n\nvar prototypeAccessors = { inFunction: { configurable: true },inGenerator: { configurable: true },inAsync: { configurable: true },canAwait: { configurable: true },allowSuper: { configurable: true },allowDirectSuper: { configurable: true },treatFunctionsAsVar: { configurable: true },allowNewDotTarget: { configurable: true },inClassStaticBlock: { configurable: true } };\n\nParser.prototype.parse = function parse () {\n var node = this.options.program || this.startNode();\n this.nextToken();\n return this.parseTopLevel(node)\n};\n\nprototypeAccessors.inFunction.get = function () { return (this.currentVarScope().flags & SCOPE_FUNCTION) > 0 };\n\nprototypeAccessors.inGenerator.get = function () { return (this.currentVarScope().flags & SCOPE_GENERATOR) > 0 && !this.currentVarScope().inClassFieldInit };\n\nprototypeAccessors.inAsync.get = function () { return (this.currentVarScope().flags & SCOPE_ASYNC) > 0 && !this.currentVarScope().inClassFieldInit };\n\nprototypeAccessors.canAwait.get = function () {\n for (var i = this.scopeStack.length - 1; i >= 0; i--) {\n var scope = this.scopeStack[i];\n if (scope.inClassFieldInit || scope.flags & SCOPE_CLASS_STATIC_BLOCK) { return false }\n if (scope.flags & SCOPE_FUNCTION) { return (scope.flags & SCOPE_ASYNC) > 0 }\n }\n return (this.inModule && this.options.ecmaVersion >= 13) || this.options.allowAwaitOutsideFunction\n};\n\nprototypeAccessors.allowSuper.get = function () {\n var ref = this.currentThisScope();\n var flags = ref.flags;\n var inClassFieldInit = ref.inClassFieldInit;\n return (flags & SCOPE_SUPER) > 0 || inClassFieldInit || this.options.allowSuperOutsideMethod\n};\n\nprototypeAccessors.allowDirectSuper.get = function () { return (this.currentThisScope().flags & SCOPE_DIRECT_SUPER) > 0 };\n\nprototypeAccessors.treatFunctionsAsVar.get = function () { return this.treatFunctionsAsVarInScope(this.currentScope()) };\n\nprototypeAccessors.allowNewDotTarget.get = function () {\n var ref = this.currentThisScope();\n var flags = ref.flags;\n var inClassFieldInit = ref.inClassFieldInit;\n return (flags & (SCOPE_FUNCTION | SCOPE_CLASS_STATIC_BLOCK)) > 0 || inClassFieldInit\n};\n\nprototypeAccessors.inClassStaticBlock.get = function () {\n return (this.currentVarScope().flags & SCOPE_CLASS_STATIC_BLOCK) > 0\n};\n\nParser.extend = function extend () {\n var plugins = [], len = arguments.length;\n while ( len-- ) plugins[ len ] = arguments[ len ];\n\n var cls = this;\n for (var i = 0; i < plugins.length; i++) { cls = plugins[i](cls); }\n return cls\n};\n\nParser.parse = function parse (input, options) {\n return new this(options, input).parse()\n};\n\nParser.parseExpressionAt = function parseExpressionAt (input, pos, options) {\n var parser = new this(options, input, pos);\n parser.nextToken();\n return parser.parseExpression()\n};\n\nParser.tokenizer = function tokenizer (input, options) {\n return new this(options, input)\n};\n\nObject.defineProperties( Parser.prototype, prototypeAccessors );\n\nvar pp$9 = Parser.prototype;\n\n// ## Parser utilities\n\nvar literal = /^(?:'((?:\\\\.|[^'\\\\])*?)'|\"((?:\\\\.|[^\"\\\\])*?)\")/;\npp$9.strictDirective = function(start) {\n if (this.options.ecmaVersion < 5) { return false }\n for (;;) {\n // Try to find string literal.\n skipWhiteSpace.lastIndex = start;\n start += skipWhiteSpace.exec(this.input)[0].length;\n var match = literal.exec(this.input.slice(start));\n if (!match) { return false }\n if ((match[1] || match[2]) === \"use strict\") {\n skipWhiteSpace.lastIndex = start + match[0].length;\n var spaceAfter = skipWhiteSpace.exec(this.input), end = spaceAfter.index + spaceAfter[0].length;\n var next = this.input.charAt(end);\n return next === \";\" || next === \"}\" ||\n (lineBreak.test(spaceAfter[0]) &&\n !(/[(`.[+\\-/*%<>=,?^&]/.test(next) || next === \"!\" && this.input.charAt(end + 1) === \"=\"))\n }\n start += match[0].length;\n\n // Skip semicolon, if any.\n skipWhiteSpace.lastIndex = start;\n start += skipWhiteSpace.exec(this.input)[0].length;\n if (this.input[start] === \";\")\n { start++; }\n }\n};\n\n// Predicate that tests whether the next token is of the given\n// type, and if yes, consumes it as a side effect.\n\npp$9.eat = function(type) {\n if (this.type === type) {\n this.next();\n return true\n } else {\n return false\n }\n};\n\n// Tests whether parsed token is a contextual keyword.\n\npp$9.isContextual = function(name) {\n return this.type === types$1.name && this.value === name && !this.containsEsc\n};\n\n// Consumes contextual keyword if possible.\n\npp$9.eatContextual = function(name) {\n if (!this.isContextual(name)) { return false }\n this.next();\n return true\n};\n\n// Asserts that following token is given contextual keyword.\n\npp$9.expectContextual = function(name) {\n if (!this.eatContextual(name)) { this.unexpected(); }\n};\n\n// Test whether a semicolon can be inserted at the current position.\n\npp$9.canInsertSemicolon = function() {\n return this.type === types$1.eof ||\n this.type === types$1.braceR ||\n lineBreak.test(this.input.slice(this.lastTokEnd, this.start))\n};\n\npp$9.insertSemicolon = function() {\n if (this.canInsertSemicolon()) {\n if (this.options.onInsertedSemicolon)\n { this.options.onInsertedSemicolon(this.lastTokEnd, this.lastTokEndLoc); }\n return true\n }\n};\n\n// Consume a semicolon, or, failing that, see if we are allowed to\n// pretend that there is a semicolon at this position.\n\npp$9.semicolon = function() {\n if (!this.eat(types$1.semi) && !this.insertSemicolon()) { this.unexpected(); }\n};\n\npp$9.afterTrailingComma = function(tokType, notNext) {\n if (this.type === tokType) {\n if (this.options.onTrailingComma)\n { this.options.onTrailingComma(this.lastTokStart, this.lastTokStartLoc); }\n if (!notNext)\n { this.next(); }\n return true\n }\n};\n\n// Expect a token of a given type. If found, consume it, otherwise,\n// raise an unexpected token error.\n\npp$9.expect = function(type) {\n this.eat(type) || this.unexpected();\n};\n\n// Raise an unexpected token error.\n\npp$9.unexpected = function(pos) {\n this.raise(pos != null ? pos : this.start, \"Unexpected token\");\n};\n\nvar DestructuringErrors = function DestructuringErrors() {\n this.shorthandAssign =\n this.trailingComma =\n this.parenthesizedAssign =\n this.parenthesizedBind =\n this.doubleProto =\n -1;\n};\n\npp$9.checkPatternErrors = function(refDestructuringErrors, isAssign) {\n if (!refDestructuringErrors) { return }\n if (refDestructuringErrors.trailingComma > -1)\n { this.raiseRecoverable(refDestructuringErrors.trailingComma, \"Comma is not permitted after the rest element\"); }\n var parens = isAssign ? refDestructuringErrors.parenthesizedAssign : refDestructuringErrors.parenthesizedBind;\n if (parens > -1) { this.raiseRecoverable(parens, isAssign ? \"Assigning to rvalue\" : \"Parenthesized pattern\"); }\n};\n\npp$9.checkExpressionErrors = function(refDestructuringErrors, andThrow) {\n if (!refDestructuringErrors) { return false }\n var shorthandAssign = refDestructuringErrors.shorthandAssign;\n var doubleProto = refDestructuringErrors.doubleProto;\n if (!andThrow) { return shorthandAssign >= 0 || doubleProto >= 0 }\n if (shorthandAssign >= 0)\n { this.raise(shorthandAssign, \"Shorthand property assignments are valid only in destructuring patterns\"); }\n if (doubleProto >= 0)\n { this.raiseRecoverable(doubleProto, \"Redefinition of __proto__ property\"); }\n};\n\npp$9.checkYieldAwaitInDefaultParams = function() {\n if (this.yieldPos && (!this.awaitPos || this.yieldPos < this.awaitPos))\n { this.raise(this.yieldPos, \"Yield expression cannot be a default value\"); }\n if (this.awaitPos)\n { this.raise(this.awaitPos, \"Await expression cannot be a default value\"); }\n};\n\npp$9.isSimpleAssignTarget = function(expr) {\n if (expr.type === \"ParenthesizedExpression\")\n { return this.isSimpleAssignTarget(expr.expression) }\n return expr.type === \"Identifier\" || expr.type === \"MemberExpression\"\n};\n\nvar pp$8 = Parser.prototype;\n\n// ### Statement parsing\n\n// Parse a program. Initializes the parser, reads any number of\n// statements, and wraps them in a Program node. Optionally takes a\n// `program` argument. If present, the statements will be appended\n// to its body instead of creating a new node.\n\npp$8.parseTopLevel = function(node) {\n var exports = Object.create(null);\n if (!node.body) { node.body = []; }\n while (this.type !== types$1.eof) {\n var stmt = this.parseStatement(null, true, exports);\n node.body.push(stmt);\n }\n if (this.inModule)\n { for (var i = 0, list = Object.keys(this.undefinedExports); i < list.length; i += 1)\n {\n var name = list[i];\n\n this.raiseRecoverable(this.undefinedExports[name].start, (\"Export '\" + name + \"' is not defined\"));\n } }\n this.adaptDirectivePrologue(node.body);\n this.next();\n node.sourceType = this.options.sourceType;\n return this.finishNode(node, \"Program\")\n};\n\nvar loopLabel = {kind: \"loop\"}, switchLabel = {kind: \"switch\"};\n\npp$8.isLet = function(context) {\n if (this.options.ecmaVersion < 6 || !this.isContextual(\"let\")) { return false }\n skipWhiteSpace.lastIndex = this.pos;\n var skip = skipWhiteSpace.exec(this.input);\n var next = this.pos + skip[0].length, nextCh = this.input.charCodeAt(next);\n // For ambiguous cases, determine if a LexicalDeclaration (or only a\n // Statement) is allowed here. If context is not empty then only a Statement\n // is allowed. However, `let [` is an explicit negative lookahead for\n // ExpressionStatement, so special-case it first.\n if (nextCh === 91 || nextCh === 92 || nextCh > 0xd7ff && nextCh < 0xdc00) { return true } // '[', '/', astral\n if (context) { return false }\n\n if (nextCh === 123) { return true } // '{'\n if (isIdentifierStart(nextCh, true)) {\n var pos = next + 1;\n while (isIdentifierChar(nextCh = this.input.charCodeAt(pos), true)) { ++pos; }\n if (nextCh === 92 || nextCh > 0xd7ff && nextCh < 0xdc00) { return true }\n var ident = this.input.slice(next, pos);\n if (!keywordRelationalOperator.test(ident)) { return true }\n }\n return false\n};\n\n// check 'async [no LineTerminator here] function'\n// - 'async /*foo*/ function' is OK.\n// - 'async /*\\n*/ function' is invalid.\npp$8.isAsyncFunction = function() {\n if (this.options.ecmaVersion < 8 || !this.isContextual(\"async\"))\n { return false }\n\n skipWhiteSpace.lastIndex = this.pos;\n var skip = skipWhiteSpace.exec(this.input);\n var next = this.pos + skip[0].length, after;\n return !lineBreak.test(this.input.slice(this.pos, next)) &&\n this.input.slice(next, next + 8) === \"function\" &&\n (next + 8 === this.input.length ||\n !(isIdentifierChar(after = this.input.charCodeAt(next + 8)) || after > 0xd7ff && after < 0xdc00))\n};\n\n// Parse a single statement.\n//\n// If expecting a statement and finding a slash operator, parse a\n// regular expression literal. This is to handle cases like\n// `if (foo) /blah/.exec(foo)`, where looking at the previous token\n// does not help.\n\npp$8.parseStatement = function(context, topLevel, exports) {\n var starttype = this.type, node = this.startNode(), kind;\n\n if (this.isLet(context)) {\n starttype = types$1._var;\n kind = \"let\";\n }\n\n // Most types of statements are recognized by the keyword they\n // start with. Many are trivial to parse, some require a bit of\n // complexity.\n\n switch (starttype) {\n case types$1._break: case types$1._continue: return this.parseBreakContinueStatement(node, starttype.keyword)\n case types$1._debugger: return this.parseDebuggerStatement(node)\n case types$1._do: return this.parseDoStatement(node)\n case types$1._for: return this.parseForStatement(node)\n case types$1._function:\n // Function as sole body of either an if statement or a labeled statement\n // works, but not when it is part of a labeled statement that is the sole\n // body of an if statement.\n if ((context && (this.strict || context !== \"if\" && context !== \"label\")) && this.options.ecmaVersion >= 6) { this.unexpected(); }\n return this.parseFunctionStatement(node, false, !context)\n case types$1._class:\n if (context) { this.unexpected(); }\n return this.parseClass(node, true)\n case types$1._if: return this.parseIfStatement(node)\n case types$1._return: return this.parseReturnStatement(node)\n case types$1._switch: return this.parseSwitchStatement(node)\n case types$1._throw: return this.parseThrowStatement(node)\n case types$1._try: return this.parseTryStatement(node)\n case types$1._const: case types$1._var:\n kind = kind || this.value;\n if (context && kind !== \"var\") { this.unexpected(); }\n return this.parseVarStatement(node, kind)\n case types$1._while: return this.parseWhileStatement(node)\n case types$1._with: return this.parseWithStatement(node)\n case types$1.braceL: return this.parseBlock(true, node)\n case types$1.semi: return this.parseEmptyStatement(node)\n case types$1._export:\n case types$1._import:\n if (this.options.ecmaVersion > 10 && starttype === types$1._import) {\n skipWhiteSpace.lastIndex = this.pos;\n var skip = skipWhiteSpace.exec(this.input);\n var next = this.pos + skip[0].length, nextCh = this.input.charCodeAt(next);\n if (nextCh === 40 || nextCh === 46) // '(' or '.'\n { return this.parseExpressionStatement(node, this.parseExpression()) }\n }\n\n if (!this.options.allowImportExportEverywhere) {\n if (!topLevel)\n { this.raise(this.start, \"'import' and 'export' may only appear at the top level\"); }\n if (!this.inModule)\n { this.raise(this.start, \"'import' and 'export' may appear only with 'sourceType: module'\"); }\n }\n return starttype === types$1._import ? this.parseImport(node) : this.parseExport(node, exports)\n\n // If the statement does not start with a statement keyword or a\n // brace, it's an ExpressionStatement or LabeledStatement. We\n // simply start parsing an expression, and afterwards, if the\n // next token is a colon and the expression was a simple\n // Identifier node, we switch to interpreting it as a label.\n default:\n if (this.isAsyncFunction()) {\n if (context) { this.unexpected(); }\n this.next();\n return this.parseFunctionStatement(node, true, !context)\n }\n\n var maybeName = this.value, expr = this.parseExpression();\n if (starttype === types$1.name && expr.type === \"Identifier\" && this.eat(types$1.colon))\n { return this.parseLabeledStatement(node, maybeName, expr, context) }\n else { return this.parseExpressionStatement(node, expr) }\n }\n};\n\npp$8.parseBreakContinueStatement = function(node, keyword) {\n var isBreak = keyword === \"break\";\n this.next();\n if (this.eat(types$1.semi) || this.insertSemicolon()) { node.label = null; }\n else if (this.type !== types$1.name) { this.unexpected(); }\n else {\n node.label = this.parseIdent();\n this.semicolon();\n }\n\n // Verify that there is an actual destination to break or\n // continue to.\n var i = 0;\n for (; i < this.labels.length; ++i) {\n var lab = this.labels[i];\n if (node.label == null || lab.name === node.label.name) {\n if (lab.kind != null && (isBreak || lab.kind === \"loop\")) { break }\n if (node.label && isBreak) { break }\n }\n }\n if (i === this.labels.length) { this.raise(node.start, \"Unsyntactic \" + keyword); }\n return this.finishNode(node, isBreak ? \"BreakStatement\" : \"ContinueStatement\")\n};\n\npp$8.parseDebuggerStatement = function(node) {\n this.next();\n this.semicolon();\n return this.finishNode(node, \"DebuggerStatement\")\n};\n\npp$8.parseDoStatement = function(node) {\n this.next();\n this.labels.push(loopLabel);\n node.body = this.parseStatement(\"do\");\n this.labels.pop();\n this.expect(types$1._while);\n node.test = this.parseParenExpression();\n if (this.options.ecmaVersion >= 6)\n { this.eat(types$1.semi); }\n else\n { this.semicolon(); }\n return this.finishNode(node, \"DoWhileStatement\")\n};\n\n// Disambiguating between a `for` and a `for`/`in` or `for`/`of`\n// loop is non-trivial. Basically, we have to parse the init `var`\n// statement or expression, disallowing the `in` operator (see\n// the second parameter to `parseExpression`), and then check\n// whether the next token is `in` or `of`. When there is no init\n// part (semicolon immediately after the opening parenthesis), it\n// is a regular `for` loop.\n\npp$8.parseForStatement = function(node) {\n this.next();\n var awaitAt = (this.options.ecmaVersion >= 9 && this.canAwait && this.eatContextual(\"await\")) ? this.lastTokStart : -1;\n this.labels.push(loopLabel);\n this.enterScope(0);\n this.expect(types$1.parenL);\n if (this.type === types$1.semi) {\n if (awaitAt > -1) { this.unexpected(awaitAt); }\n return this.parseFor(node, null)\n }\n var isLet = this.isLet();\n if (this.type === types$1._var || this.type === types$1._const || isLet) {\n var init$1 = this.startNode(), kind = isLet ? \"let\" : this.value;\n this.next();\n this.parseVar(init$1, true, kind);\n this.finishNode(init$1, \"VariableDeclaration\");\n if ((this.type === types$1._in || (this.options.ecmaVersion >= 6 && this.isContextual(\"of\"))) && init$1.declarations.length === 1) {\n if (this.options.ecmaVersion >= 9) {\n if (this.type === types$1._in) {\n if (awaitAt > -1) { this.unexpected(awaitAt); }\n } else { node.await = awaitAt > -1; }\n }\n return this.parseForIn(node, init$1)\n }\n if (awaitAt > -1) { this.unexpected(awaitAt); }\n return this.parseFor(node, init$1)\n }\n var startsWithLet = this.isContextual(\"let\"), isForOf = false;\n var refDestructuringErrors = new DestructuringErrors;\n var init = this.parseExpression(awaitAt > -1 ? \"await\" : true, refDestructuringErrors);\n if (this.type === types$1._in || (isForOf = this.options.ecmaVersion >= 6 && this.isContextual(\"of\"))) {\n if (this.options.ecmaVersion >= 9) {\n if (this.type === types$1._in) {\n if (awaitAt > -1) { this.unexpected(awaitAt); }\n } else { node.await = awaitAt > -1; }\n }\n if (startsWithLet && isForOf) { this.raise(init.start, \"The left-hand side of a for-of loop may not start with 'let'.\"); }\n this.toAssignable(init, false, refDestructuringErrors);\n this.checkLValPattern(init);\n return this.parseForIn(node, init)\n } else {\n this.checkExpressionErrors(refDestructuringErrors, true);\n }\n if (awaitAt > -1) { this.unexpected(awaitAt); }\n return this.parseFor(node, init)\n};\n\npp$8.parseFunctionStatement = function(node, isAsync, declarationPosition) {\n this.next();\n return this.parseFunction(node, FUNC_STATEMENT | (declarationPosition ? 0 : FUNC_HANGING_STATEMENT), false, isAsync)\n};\n\npp$8.parseIfStatement = function(node) {\n this.next();\n node.test = this.parseParenExpression();\n // allow function declarations in branches, but only in non-strict mode\n node.consequent = this.parseStatement(\"if\");\n node.alternate = this.eat(types$1._else) ? this.parseStatement(\"if\") : null;\n return this.finishNode(node, \"IfStatement\")\n};\n\npp$8.parseReturnStatement = function(node) {\n if (!this.inFunction && !this.options.allowReturnOutsideFunction)\n { this.raise(this.start, \"'return' outside of function\"); }\n this.next();\n\n // In `return` (and `break`/`continue`), the keywords with\n // optional arguments, we eagerly look for a semicolon or the\n // possibility to insert one.\n\n if (this.eat(types$1.semi) || this.insertSemicolon()) { node.argument = null; }\n else { node.argument = this.parseExpression(); this.semicolon(); }\n return this.finishNode(node, \"ReturnStatement\")\n};\n\npp$8.parseSwitchStatement = function(node) {\n this.next();\n node.discriminant = this.parseParenExpression();\n node.cases = [];\n this.expect(types$1.braceL);\n this.labels.push(switchLabel);\n this.enterScope(0);\n\n // Statements under must be grouped (by label) in SwitchCase\n // nodes. `cur` is used to keep the node that we are currently\n // adding statements to.\n\n var cur;\n for (var sawDefault = false; this.type !== types$1.braceR;) {\n if (this.type === types$1._case || this.type === types$1._default) {\n var isCase = this.type === types$1._case;\n if (cur) { this.finishNode(cur, \"SwitchCase\"); }\n node.cases.push(cur = this.startNode());\n cur.consequent = [];\n this.next();\n if (isCase) {\n cur.test = this.parseExpression();\n } else {\n if (sawDefault) { this.raiseRecoverable(this.lastTokStart, \"Multiple default clauses\"); }\n sawDefault = true;\n cur.test = null;\n }\n this.expect(types$1.colon);\n } else {\n if (!cur) { this.unexpected(); }\n cur.consequent.push(this.parseStatement(null));\n }\n }\n this.exitScope();\n if (cur) { this.finishNode(cur, \"SwitchCase\"); }\n this.next(); // Closing brace\n this.labels.pop();\n return this.finishNode(node, \"SwitchStatement\")\n};\n\npp$8.parseThrowStatement = function(node) {\n this.next();\n if (lineBreak.test(this.input.slice(this.lastTokEnd, this.start)))\n { this.raise(this.lastTokEnd, \"Illegal newline after throw\"); }\n node.argument = this.parseExpression();\n this.semicolon();\n return this.finishNode(node, \"ThrowStatement\")\n};\n\n// Reused empty array added for node fields that are always empty.\n\nvar empty$1 = [];\n\npp$8.parseTryStatement = function(node) {\n this.next();\n node.block = this.parseBlock();\n node.handler = null;\n if (this.type === types$1._catch) {\n var clause = this.startNode();\n this.next();\n if (this.eat(types$1.parenL)) {\n clause.param = this.parseBindingAtom();\n var simple = clause.param.type === \"Identifier\";\n this.enterScope(simple ? SCOPE_SIMPLE_CATCH : 0);\n this.checkLValPattern(clause.param, simple ? BIND_SIMPLE_CATCH : BIND_LEXICAL);\n this.expect(types$1.parenR);\n } else {\n if (this.options.ecmaVersion < 10) { this.unexpected(); }\n clause.param = null;\n this.enterScope(0);\n }\n clause.body = this.parseBlock(false);\n this.exitScope();\n node.handler = this.finishNode(clause, \"CatchClause\");\n }\n node.finalizer = this.eat(types$1._finally) ? this.parseBlock() : null;\n if (!node.handler && !node.finalizer)\n { this.raise(node.start, \"Missing catch or finally clause\"); }\n return this.finishNode(node, \"TryStatement\")\n};\n\npp$8.parseVarStatement = function(node, kind) {\n this.next();\n this.parseVar(node, false, kind);\n this.semicolon();\n return this.finishNode(node, \"VariableDeclaration\")\n};\n\npp$8.parseWhileStatement = function(node) {\n this.next();\n node.test = this.parseParenExpression();\n this.labels.push(loopLabel);\n node.body = this.parseStatement(\"while\");\n this.labels.pop();\n return this.finishNode(node, \"WhileStatement\")\n};\n\npp$8.parseWithStatement = function(node) {\n if (this.strict) { this.raise(this.start, \"'with' in strict mode\"); }\n this.next();\n node.object = this.parseParenExpression();\n node.body = this.parseStatement(\"with\");\n return this.finishNode(node, \"WithStatement\")\n};\n\npp$8.parseEmptyStatement = function(node) {\n this.next();\n return this.finishNode(node, \"EmptyStatement\")\n};\n\npp$8.parseLabeledStatement = function(node, maybeName, expr, context) {\n for (var i$1 = 0, list = this.labels; i$1 < list.length; i$1 += 1)\n {\n var label = list[i$1];\n\n if (label.name === maybeName)\n { this.raise(expr.start, \"Label '\" + maybeName + \"' is already declared\");\n } }\n var kind = this.type.isLoop ? \"loop\" : this.type === types$1._switch ? \"switch\" : null;\n for (var i = this.labels.length - 1; i >= 0; i--) {\n var label$1 = this.labels[i];\n if (label$1.statementStart === node.start) {\n // Update information about previous labels on this node\n label$1.statementStart = this.start;\n label$1.kind = kind;\n } else { break }\n }\n this.labels.push({name: maybeName, kind: kind, statementStart: this.start});\n node.body = this.parseStatement(context ? context.indexOf(\"label\") === -1 ? context + \"label\" : context : \"label\");\n this.labels.pop();\n node.label = expr;\n return this.finishNode(node, \"LabeledStatement\")\n};\n\npp$8.parseExpressionStatement = function(node, expr) {\n node.expression = expr;\n this.semicolon();\n return this.finishNode(node, \"ExpressionStatement\")\n};\n\n// Parse a semicolon-enclosed block of statements, handling `\"use\n// strict\"` declarations when `allowStrict` is true (used for\n// function bodies).\n\npp$8.parseBlock = function(createNewLexicalScope, node, exitStrict) {\n if ( createNewLexicalScope === void 0 ) createNewLexicalScope = true;\n if ( node === void 0 ) node = this.startNode();\n\n node.body = [];\n this.expect(types$1.braceL);\n if (createNewLexicalScope) { this.enterScope(0); }\n while (this.type !== types$1.braceR) {\n var stmt = this.parseStatement(null);\n node.body.push(stmt);\n }\n if (exitStrict) { this.strict = false; }\n this.next();\n if (createNewLexicalScope) { this.exitScope(); }\n return this.finishNode(node, \"BlockStatement\")\n};\n\n// Parse a regular `for` loop. The disambiguation code in\n// `parseStatement` will already have parsed the init statement or\n// expression.\n\npp$8.parseFor = function(node, init) {\n node.init = init;\n this.expect(types$1.semi);\n node.test = this.type === types$1.semi ? null : this.parseExpression();\n this.expect(types$1.semi);\n node.update = this.type === types$1.parenR ? null : this.parseExpression();\n this.expect(types$1.parenR);\n node.body = this.parseStatement(\"for\");\n this.exitScope();\n this.labels.pop();\n return this.finishNode(node, \"ForStatement\")\n};\n\n// Parse a `for`/`in` and `for`/`of` loop, which are almost\n// same from parser's perspective.\n\npp$8.parseForIn = function(node, init) {\n var isForIn = this.type === types$1._in;\n this.next();\n\n if (\n init.type === \"VariableDeclaration\" &&\n init.declarations[0].init != null &&\n (\n !isForIn ||\n this.options.ecmaVersion < 8 ||\n this.strict ||\n init.kind !== \"var\" ||\n init.declarations[0].id.type !== \"Identifier\"\n )\n ) {\n this.raise(\n init.start,\n ((isForIn ? \"for-in\" : \"for-of\") + \" loop variable declaration may not have an initializer\")\n );\n }\n node.left = init;\n node.right = isForIn ? this.parseExpression() : this.parseMaybeAssign();\n this.expect(types$1.parenR);\n node.body = this.parseStatement(\"for\");\n this.exitScope();\n this.labels.pop();\n return this.finishNode(node, isForIn ? \"ForInStatement\" : \"ForOfStatement\")\n};\n\n// Parse a list of variable declarations.\n\npp$8.parseVar = function(node, isFor, kind) {\n node.declarations = [];\n node.kind = kind;\n for (;;) {\n var decl = this.startNode();\n this.parseVarId(decl, kind);\n if (this.eat(types$1.eq)) {\n decl.init = this.parseMaybeAssign(isFor);\n } else if (kind === \"const\" && !(this.type === types$1._in || (this.options.ecmaVersion >= 6 && this.isContextual(\"of\")))) {\n this.unexpected();\n } else if (decl.id.type !== \"Identifier\" && !(isFor && (this.type === types$1._in || this.isContextual(\"of\")))) {\n this.raise(this.lastTokEnd, \"Complex binding patterns require an initialization value\");\n } else {\n decl.init = null;\n }\n node.declarations.push(this.finishNode(decl, \"VariableDeclarator\"));\n if (!this.eat(types$1.comma)) { break }\n }\n return node\n};\n\npp$8.parseVarId = function(decl, kind) {\n decl.id = this.parseBindingAtom();\n this.checkLValPattern(decl.id, kind === \"var\" ? BIND_VAR : BIND_LEXICAL, false);\n};\n\nvar FUNC_STATEMENT = 1, FUNC_HANGING_STATEMENT = 2, FUNC_NULLABLE_ID = 4;\n\n// Parse a function declaration or literal (depending on the\n// `statement & FUNC_STATEMENT`).\n\n// Remove `allowExpressionBody` for 7.0.0, as it is only called with false\npp$8.parseFunction = function(node, statement, allowExpressionBody, isAsync, forInit) {\n this.initFunction(node);\n if (this.options.ecmaVersion >= 9 || this.options.ecmaVersion >= 6 && !isAsync) {\n if (this.type === types$1.star && (statement & FUNC_HANGING_STATEMENT))\n { this.unexpected(); }\n node.generator = this.eat(types$1.star);\n }\n if (this.options.ecmaVersion >= 8)\n { node.async = !!isAsync; }\n\n if (statement & FUNC_STATEMENT) {\n node.id = (statement & FUNC_NULLABLE_ID) && this.type !== types$1.name ? null : this.parseIdent();\n if (node.id && !(statement & FUNC_HANGING_STATEMENT))\n // If it is a regular function declaration in sloppy mode, then it is\n // subject to Annex B semantics (BIND_FUNCTION). Otherwise, the binding\n // mode depends on properties of the current scope (see\n // treatFunctionsAsVar).\n { this.checkLValSimple(node.id, (this.strict || node.generator || node.async) ? this.treatFunctionsAsVar ? BIND_VAR : BIND_LEXICAL : BIND_FUNCTION); }\n }\n\n var oldYieldPos = this.yieldPos, oldAwaitPos = this.awaitPos, oldAwaitIdentPos = this.awaitIdentPos;\n this.yieldPos = 0;\n this.awaitPos = 0;\n this.awaitIdentPos = 0;\n this.enterScope(functionFlags(node.async, node.generator));\n\n if (!(statement & FUNC_STATEMENT))\n { node.id = this.type === types$1.name ? this.parseIdent() : null; }\n\n this.parseFunctionParams(node);\n this.parseFunctionBody(node, allowExpressionBody, false, forInit);\n\n this.yieldPos = oldYieldPos;\n this.awaitPos = oldAwaitPos;\n this.awaitIdentPos = oldAwaitIdentPos;\n return this.finishNode(node, (statement & FUNC_STATEMENT) ? \"FunctionDeclaration\" : \"FunctionExpression\")\n};\n\npp$8.parseFunctionParams = function(node) {\n this.expect(types$1.parenL);\n node.params = this.parseBindingList(types$1.parenR, false, this.options.ecmaVersion >= 8);\n this.checkYieldAwaitInDefaultParams();\n};\n\n// Parse a class declaration or literal (depending on the\n// `isStatement` parameter).\n\npp$8.parseClass = function(node, isStatement) {\n this.next();\n\n // ecma-262 14.6 Class Definitions\n // A class definition is always strict mode code.\n var oldStrict = this.strict;\n this.strict = true;\n\n this.parseClassId(node, isStatement);\n this.parseClassSuper(node);\n var privateNameMap = this.enterClassBody();\n var classBody = this.startNode();\n var hadConstructor = false;\n classBody.body = [];\n this.expect(types$1.braceL);\n while (this.type !== types$1.braceR) {\n var element = this.parseClassElement(node.superClass !== null);\n if (element) {\n classBody.body.push(element);\n if (element.type === \"MethodDefinition\" && element.kind === \"constructor\") {\n if (hadConstructor) { this.raise(element.start, \"Duplicate constructor in the same class\"); }\n hadConstructor = true;\n } else if (element.key && element.key.type === \"PrivateIdentifier\" && isPrivateNameConflicted(privateNameMap, element)) {\n this.raiseRecoverable(element.key.start, (\"Identifier '#\" + (element.key.name) + \"' has already been declared\"));\n }\n }\n }\n this.strict = oldStrict;\n this.next();\n node.body = this.finishNode(classBody, \"ClassBody\");\n this.exitClassBody();\n return this.finishNode(node, isStatement ? \"ClassDeclaration\" : \"ClassExpression\")\n};\n\npp$8.parseClassElement = function(constructorAllowsSuper) {\n if (this.eat(types$1.semi)) { return null }\n\n var ecmaVersion = this.options.ecmaVersion;\n var node = this.startNode();\n var keyName = \"\";\n var isGenerator = false;\n var isAsync = false;\n var kind = \"method\";\n var isStatic = false;\n\n if (this.eatContextual(\"static\")) {\n // Parse static init block\n if (ecmaVersion >= 13 && this.eat(types$1.braceL)) {\n this.parseClassStaticBlock(node);\n return node\n }\n if (this.isClassElementNameStart() || this.type === types$1.star) {\n isStatic = true;\n } else {\n keyName = \"static\";\n }\n }\n node.static = isStatic;\n if (!keyName && ecmaVersion >= 8 && this.eatContextual(\"async\")) {\n if ((this.isClassElementNameStart() || this.type === types$1.star) && !this.canInsertSemicolon()) {\n isAsync = true;\n } else {\n keyName = \"async\";\n }\n }\n if (!keyName && (ecmaVersion >= 9 || !isAsync) && this.eat(types$1.star)) {\n isGenerator = true;\n }\n if (!keyName && !isAsync && !isGenerator) {\n var lastValue = this.value;\n if (this.eatContextual(\"get\") || this.eatContextual(\"set\")) {\n if (this.isClassElementNameStart()) {\n kind = lastValue;\n } else {\n keyName = lastValue;\n }\n }\n }\n\n // Parse element name\n if (keyName) {\n // 'async', 'get', 'set', or 'static' were not a keyword contextually.\n // The last token is any of those. Make it the element name.\n node.computed = false;\n node.key = this.startNodeAt(this.lastTokStart, this.lastTokStartLoc);\n node.key.name = keyName;\n this.finishNode(node.key, \"Identifier\");\n } else {\n this.parseClassElementName(node);\n }\n\n // Parse element value\n if (ecmaVersion < 13 || this.type === types$1.parenL || kind !== \"method\" || isGenerator || isAsync) {\n var isConstructor = !node.static && checkKeyName(node, \"constructor\");\n var allowsDirectSuper = isConstructor && constructorAllowsSuper;\n // Couldn't move this check into the 'parseClassMethod' method for backward compatibility.\n if (isConstructor && kind !== \"method\") { this.raise(node.key.start, \"Constructor can't have get/set modifier\"); }\n node.kind = isConstructor ? \"constructor\" : kind;\n this.parseClassMethod(node, isGenerator, isAsync, allowsDirectSuper);\n } else {\n this.parseClassField(node);\n }\n\n return node\n};\n\npp$8.isClassElementNameStart = function() {\n return (\n this.type === types$1.name ||\n this.type === types$1.privateId ||\n this.type === types$1.num ||\n this.type === types$1.string ||\n this.type === types$1.bracketL ||\n this.type.keyword\n )\n};\n\npp$8.parseClassElementName = function(element) {\n if (this.type === types$1.privateId) {\n if (this.value === \"constructor\") {\n this.raise(this.start, \"Classes can't have an element named '#constructor'\");\n }\n element.computed = false;\n element.key = this.parsePrivateIdent();\n } else {\n this.parsePropertyName(element);\n }\n};\n\npp$8.parseClassMethod = function(method, isGenerator, isAsync, allowsDirectSuper) {\n // Check key and flags\n var key = method.key;\n if (method.kind === \"constructor\") {\n if (isGenerator) { this.raise(key.start, \"Constructor can't be a generator\"); }\n if (isAsync) { this.raise(key.start, \"Constructor can't be an async method\"); }\n } else if (method.static && checkKeyName(method, \"prototype\")) {\n this.raise(key.start, \"Classes may not have a static property named prototype\");\n }\n\n // Parse value\n var value = method.value = this.parseMethod(isGenerator, isAsync, allowsDirectSuper);\n\n // Check value\n if (method.kind === \"get\" && value.params.length !== 0)\n { this.raiseRecoverable(value.start, \"getter should have no params\"); }\n if (method.kind === \"set\" && value.params.length !== 1)\n { this.raiseRecoverable(value.start, \"setter should have exactly one param\"); }\n if (method.kind === \"set\" && value.params[0].type === \"RestElement\")\n { this.raiseRecoverable(value.params[0].start, \"Setter cannot use rest params\"); }\n\n return this.finishNode(method, \"MethodDefinition\")\n};\n\npp$8.parseClassField = function(field) {\n if (checkKeyName(field, \"constructor\")) {\n this.raise(field.key.start, \"Classes can't have a field named 'constructor'\");\n } else if (field.static && checkKeyName(field, \"prototype\")) {\n this.raise(field.key.start, \"Classes can't have a static field named 'prototype'\");\n }\n\n if (this.eat(types$1.eq)) {\n // To raise SyntaxError if 'arguments' exists in the initializer.\n var scope = this.currentThisScope();\n var inClassFieldInit = scope.inClassFieldInit;\n scope.inClassFieldInit = true;\n field.value = this.parseMaybeAssign();\n scope.inClassFieldInit = inClassFieldInit;\n } else {\n field.value = null;\n }\n this.semicolon();\n\n return this.finishNode(field, \"PropertyDefinition\")\n};\n\npp$8.parseClassStaticBlock = function(node) {\n node.body = [];\n\n var oldLabels = this.labels;\n this.labels = [];\n this.enterScope(SCOPE_CLASS_STATIC_BLOCK | SCOPE_SUPER);\n while (this.type !== types$1.braceR) {\n var stmt = this.parseStatement(null);\n node.body.push(stmt);\n }\n this.next();\n this.exitScope();\n this.labels = oldLabels;\n\n return this.finishNode(node, \"StaticBlock\")\n};\n\npp$8.parseClassId = function(node, isStatement) {\n if (this.type === types$1.name) {\n node.id = this.parseIdent();\n if (isStatement)\n { this.checkLValSimple(node.id, BIND_LEXICAL, false); }\n } else {\n if (isStatement === true)\n { this.unexpected(); }\n node.id = null;\n }\n};\n\npp$8.parseClassSuper = function(node) {\n node.superClass = this.eat(types$1._extends) ? this.parseExprSubscripts(false) : null;\n};\n\npp$8.enterClassBody = function() {\n var element = {declared: Object.create(null), used: []};\n this.privateNameStack.push(element);\n return element.declared\n};\n\npp$8.exitClassBody = function() {\n var ref = this.privateNameStack.pop();\n var declared = ref.declared;\n var used = ref.used;\n var len = this.privateNameStack.length;\n var parent = len === 0 ? null : this.privateNameStack[len - 1];\n for (var i = 0; i < used.length; ++i) {\n var id = used[i];\n if (!hasOwn(declared, id.name)) {\n if (parent) {\n parent.used.push(id);\n } else {\n this.raiseRecoverable(id.start, (\"Private field '#\" + (id.name) + \"' must be declared in an enclosing class\"));\n }\n }\n }\n};\n\nfunction isPrivateNameConflicted(privateNameMap, element) {\n var name = element.key.name;\n var curr = privateNameMap[name];\n\n var next = \"true\";\n if (element.type === \"MethodDefinition\" && (element.kind === \"get\" || element.kind === \"set\")) {\n next = (element.static ? \"s\" : \"i\") + element.kind;\n }\n\n // `class { get #a(){}; static set #a(_){} }` is also conflict.\n if (\n curr === \"iget\" && next === \"iset\" ||\n curr === \"iset\" && next === \"iget\" ||\n curr === \"sget\" && next === \"sset\" ||\n curr === \"sset\" && next === \"sget\"\n ) {\n privateNameMap[name] = \"true\";\n return false\n } else if (!curr) {\n privateNameMap[name] = next;\n return false\n } else {\n return true\n }\n}\n\nfunction checkKeyName(node, name) {\n var computed = node.computed;\n var key = node.key;\n return !computed && (\n key.type === \"Identifier\" && key.name === name ||\n key.type === \"Literal\" && key.value === name\n )\n}\n\n// Parses module export declaration.\n\npp$8.parseExport = function(node, exports) {\n this.next();\n // export * from '...'\n if (this.eat(types$1.star)) {\n if (this.options.ecmaVersion >= 11) {\n if (this.eatContextual(\"as\")) {\n node.exported = this.parseModuleExportName();\n this.checkExport(exports, node.exported, this.lastTokStart);\n } else {\n node.exported = null;\n }\n }\n this.expectContextual(\"from\");\n if (this.type !== types$1.string) { this.unexpected(); }\n node.source = this.parseExprAtom();\n this.semicolon();\n return this.finishNode(node, \"ExportAllDeclaration\")\n }\n if (this.eat(types$1._default)) { // export default ...\n this.checkExport(exports, \"default\", this.lastTokStart);\n var isAsync;\n if (this.type === types$1._function || (isAsync = this.isAsyncFunction())) {\n var fNode = this.startNode();\n this.next();\n if (isAsync) { this.next(); }\n node.declaration = this.parseFunction(fNode, FUNC_STATEMENT | FUNC_NULLABLE_ID, false, isAsync);\n } else if (this.type === types$1._class) {\n var cNode = this.startNode();\n node.declaration = this.parseClass(cNode, \"nullableID\");\n } else {\n node.declaration = this.parseMaybeAssign();\n this.semicolon();\n }\n return this.finishNode(node, \"ExportDefaultDeclaration\")\n }\n // export var|const|let|function|class ...\n if (this.shouldParseExportStatement()) {\n node.declaration = this.parseStatement(null);\n if (node.declaration.type === \"VariableDeclaration\")\n { this.checkVariableExport(exports, node.declaration.declarations); }\n else\n { this.checkExport(exports, node.declaration.id, node.declaration.id.start); }\n node.specifiers = [];\n node.source = null;\n } else { // export { x, y as z } [from '...']\n node.declaration = null;\n node.specifiers = this.parseExportSpecifiers(exports);\n if (this.eatContextual(\"from\")) {\n if (this.type !== types$1.string) { this.unexpected(); }\n node.source = this.parseExprAtom();\n } else {\n for (var i = 0, list = node.specifiers; i < list.length; i += 1) {\n // check for keywords used as local names\n var spec = list[i];\n\n this.checkUnreserved(spec.local);\n // check if export is defined\n this.checkLocalExport(spec.local);\n\n if (spec.local.type === \"Literal\") {\n this.raise(spec.local.start, \"A string literal cannot be used as an exported binding without `from`.\");\n }\n }\n\n node.source = null;\n }\n this.semicolon();\n }\n return this.finishNode(node, \"ExportNamedDeclaration\")\n};\n\npp$8.checkExport = function(exports, name, pos) {\n if (!exports) { return }\n if (typeof name !== \"string\")\n { name = name.type === \"Identifier\" ? name.name : name.value; }\n if (hasOwn(exports, name))\n { this.raiseRecoverable(pos, \"Duplicate export '\" + name + \"'\"); }\n exports[name] = true;\n};\n\npp$8.checkPatternExport = function(exports, pat) {\n var type = pat.type;\n if (type === \"Identifier\")\n { this.checkExport(exports, pat, pat.start); }\n else if (type === \"ObjectPattern\")\n { for (var i = 0, list = pat.properties; i < list.length; i += 1)\n {\n var prop = list[i];\n\n this.checkPatternExport(exports, prop);\n } }\n else if (type === \"ArrayPattern\")\n { for (var i$1 = 0, list$1 = pat.elements; i$1 < list$1.length; i$1 += 1) {\n var elt = list$1[i$1];\n\n if (elt) { this.checkPatternExport(exports, elt); }\n } }\n else if (type === \"Property\")\n { this.checkPatternExport(exports, pat.value); }\n else if (type === \"AssignmentPattern\")\n { this.checkPatternExport(exports, pat.left); }\n else if (type === \"RestElement\")\n { this.checkPatternExport(exports, pat.argument); }\n else if (type === \"ParenthesizedExpression\")\n { this.checkPatternExport(exports, pat.expression); }\n};\n\npp$8.checkVariableExport = function(exports, decls) {\n if (!exports) { return }\n for (var i = 0, list = decls; i < list.length; i += 1)\n {\n var decl = list[i];\n\n this.checkPatternExport(exports, decl.id);\n }\n};\n\npp$8.shouldParseExportStatement = function() {\n return this.type.keyword === \"var\" ||\n this.type.keyword === \"const\" ||\n this.type.keyword === \"class\" ||\n this.type.keyword === \"function\" ||\n this.isLet() ||\n this.isAsyncFunction()\n};\n\n// Parses a comma-separated list of module exports.\n\npp$8.parseExportSpecifiers = function(exports) {\n var nodes = [], first = true;\n // export { x, y as z } [from '...']\n this.expect(types$1.braceL);\n while (!this.eat(types$1.braceR)) {\n if (!first) {\n this.expect(types$1.comma);\n if (this.afterTrailingComma(types$1.braceR)) { break }\n } else { first = false; }\n\n var node = this.startNode();\n node.local = this.parseModuleExportName();\n node.exported = this.eatContextual(\"as\") ? this.parseModuleExportName() : node.local;\n this.checkExport(\n exports,\n node.exported,\n node.exported.start\n );\n nodes.push(this.finishNode(node, \"ExportSpecifier\"));\n }\n return nodes\n};\n\n// Parses import declaration.\n\npp$8.parseImport = function(node) {\n this.next();\n // import '...'\n if (this.type === types$1.string) {\n node.specifiers = empty$1;\n node.source = this.parseExprAtom();\n } else {\n node.specifiers = this.parseImportSpecifiers();\n this.expectContextual(\"from\");\n node.source = this.type === types$1.string ? this.parseExprAtom() : this.unexpected();\n }\n this.semicolon();\n return this.finishNode(node, \"ImportDeclaration\")\n};\n\n// Parses a comma-separated list of module imports.\n\npp$8.parseImportSpecifiers = function() {\n var nodes = [], first = true;\n if (this.type === types$1.name) {\n // import defaultObj, { x, y as z } from '...'\n var node = this.startNode();\n node.local = this.parseIdent();\n this.checkLValSimple(node.local, BIND_LEXICAL);\n nodes.push(this.finishNode(node, \"ImportDefaultSpecifier\"));\n if (!this.eat(types$1.comma)) { return nodes }\n }\n if (this.type === types$1.star) {\n var node$1 = this.startNode();\n this.next();\n this.expectContextual(\"as\");\n node$1.local = this.parseIdent();\n this.checkLValSimple(node$1.local, BIND_LEXICAL);\n nodes.push(this.finishNode(node$1, \"ImportNamespaceSpecifier\"));\n return nodes\n }\n this.expect(types$1.braceL);\n while (!this.eat(types$1.braceR)) {\n if (!first) {\n this.expect(types$1.comma);\n if (this.afterTrailingComma(types$1.braceR)) { break }\n } else { first = false; }\n\n var node$2 = this.startNode();\n node$2.imported = this.parseModuleExportName();\n if (this.eatContextual(\"as\")) {\n node$2.local = this.parseIdent();\n } else {\n this.checkUnreserved(node$2.imported);\n node$2.local = node$2.imported;\n }\n this.checkLValSimple(node$2.local, BIND_LEXICAL);\n nodes.push(this.finishNode(node$2, \"ImportSpecifier\"));\n }\n return nodes\n};\n\npp$8.parseModuleExportName = function() {\n if (this.options.ecmaVersion >= 13 && this.type === types$1.string) {\n var stringLiteral = this.parseLiteral(this.value);\n if (loneSurrogate.test(stringLiteral.value)) {\n this.raise(stringLiteral.start, \"An export name cannot include a lone surrogate.\");\n }\n return stringLiteral\n }\n return this.parseIdent(true)\n};\n\n// Set `ExpressionStatement#directive` property for directive prologues.\npp$8.adaptDirectivePrologue = function(statements) {\n for (var i = 0; i < statements.length && this.isDirectiveCandidate(statements[i]); ++i) {\n statements[i].directive = statements[i].expression.raw.slice(1, -1);\n }\n};\npp$8.isDirectiveCandidate = function(statement) {\n return (\n this.options.ecmaVersion >= 5 &&\n statement.type === \"ExpressionStatement\" &&\n statement.expression.type === \"Literal\" &&\n typeof statement.expression.value === \"string\" &&\n // Reject parenthesized strings.\n (this.input[statement.start] === \"\\\"\" || this.input[statement.start] === \"'\")\n )\n};\n\nvar pp$7 = Parser.prototype;\n\n// Convert existing expression atom to assignable pattern\n// if possible.\n\npp$7.toAssignable = function(node, isBinding, refDestructuringErrors) {\n if (this.options.ecmaVersion >= 6 && node) {\n switch (node.type) {\n case \"Identifier\":\n if (this.inAsync && node.name === \"await\")\n { this.raise(node.start, \"Cannot use 'await' as identifier inside an async function\"); }\n break\n\n case \"ObjectPattern\":\n case \"ArrayPattern\":\n case \"AssignmentPattern\":\n case \"RestElement\":\n break\n\n case \"ObjectExpression\":\n node.type = \"ObjectPattern\";\n if (refDestructuringErrors) { this.checkPatternErrors(refDestructuringErrors, true); }\n for (var i = 0, list = node.properties; i < list.length; i += 1) {\n var prop = list[i];\n\n this.toAssignable(prop, isBinding);\n // Early error:\n // AssignmentRestProperty[Yield, Await] :\n // `...` DestructuringAssignmentTarget[Yield, Await]\n //\n // It is a Syntax Error if |DestructuringAssignmentTarget| is an |ArrayLiteral| or an |ObjectLiteral|.\n if (\n prop.type === \"RestElement\" &&\n (prop.argument.type === \"ArrayPattern\" || prop.argument.type === \"ObjectPattern\")\n ) {\n this.raise(prop.argument.start, \"Unexpected token\");\n }\n }\n break\n\n case \"Property\":\n // AssignmentProperty has type === \"Property\"\n if (node.kind !== \"init\") { this.raise(node.key.start, \"Object pattern can't contain getter or setter\"); }\n this.toAssignable(node.value, isBinding);\n break\n\n case \"ArrayExpression\":\n node.type = \"ArrayPattern\";\n if (refDestructuringErrors) { this.checkPatternErrors(refDestructuringErrors, true); }\n this.toAssignableList(node.elements, isBinding);\n break\n\n case \"SpreadElement\":\n node.type = \"RestElement\";\n this.toAssignable(node.argument, isBinding);\n if (node.argument.type === \"AssignmentPattern\")\n { this.raise(node.argument.start, \"Rest elements cannot have a default value\"); }\n break\n\n case \"AssignmentExpression\":\n if (node.operator !== \"=\") { this.raise(node.left.end, \"Only '=' operator can be used for specifying default value.\"); }\n node.type = \"AssignmentPattern\";\n delete node.operator;\n this.toAssignable(node.left, isBinding);\n break\n\n case \"ParenthesizedExpression\":\n this.toAssignable(node.expression, isBinding, refDestructuringErrors);\n break\n\n case \"ChainExpression\":\n this.raiseRecoverable(node.start, \"Optional chaining cannot appear in left-hand side\");\n break\n\n case \"MemberExpression\":\n if (!isBinding) { break }\n\n default:\n this.raise(node.start, \"Assigning to rvalue\");\n }\n } else if (refDestructuringErrors) { this.checkPatternErrors(refDestructuringErrors, true); }\n return node\n};\n\n// Convert list of expression atoms to binding list.\n\npp$7.toAssignableList = function(exprList, isBinding) {\n var end = exprList.length;\n for (var i = 0; i < end; i++) {\n var elt = exprList[i];\n if (elt) { this.toAssignable(elt, isBinding); }\n }\n if (end) {\n var last = exprList[end - 1];\n if (this.options.ecmaVersion === 6 && isBinding && last && last.type === \"RestElement\" && last.argument.type !== \"Identifier\")\n { this.unexpected(last.argument.start); }\n }\n return exprList\n};\n\n// Parses spread element.\n\npp$7.parseSpread = function(refDestructuringErrors) {\n var node = this.startNode();\n this.next();\n node.argument = this.parseMaybeAssign(false, refDestructuringErrors);\n return this.finishNode(node, \"SpreadElement\")\n};\n\npp$7.parseRestBinding = function() {\n var node = this.startNode();\n this.next();\n\n // RestElement inside of a function parameter must be an identifier\n if (this.options.ecmaVersion === 6 && this.type !== types$1.name)\n { this.unexpected(); }\n\n node.argument = this.parseBindingAtom();\n\n return this.finishNode(node, \"RestElement\")\n};\n\n// Parses lvalue (assignable) atom.\n\npp$7.parseBindingAtom = function() {\n if (this.options.ecmaVersion >= 6) {\n switch (this.type) {\n case types$1.bracketL:\n var node = this.startNode();\n this.next();\n node.elements = this.parseBindingList(types$1.bracketR, true, true);\n return this.finishNode(node, \"ArrayPattern\")\n\n case types$1.braceL:\n return this.parseObj(true)\n }\n }\n return this.parseIdent()\n};\n\npp$7.parseBindingList = function(close, allowEmpty, allowTrailingComma) {\n var elts = [], first = true;\n while (!this.eat(close)) {\n if (first) { first = false; }\n else { this.expect(types$1.comma); }\n if (allowEmpty && this.type === types$1.comma) {\n elts.push(null);\n } else if (allowTrailingComma && this.afterTrailingComma(close)) {\n break\n } else if (this.type === types$1.ellipsis) {\n var rest = this.parseRestBinding();\n this.parseBindingListItem(rest);\n elts.push(rest);\n if (this.type === types$1.comma) { this.raise(this.start, \"Comma is not permitted after the rest element\"); }\n this.expect(close);\n break\n } else {\n var elem = this.parseMaybeDefault(this.start, this.startLoc);\n this.parseBindingListItem(elem);\n elts.push(elem);\n }\n }\n return elts\n};\n\npp$7.parseBindingListItem = function(param) {\n return param\n};\n\n// Parses assignment pattern around given atom if possible.\n\npp$7.parseMaybeDefault = function(startPos, startLoc, left) {\n left = left || this.parseBindingAtom();\n if (this.options.ecmaVersion < 6 || !this.eat(types$1.eq)) { return left }\n var node = this.startNodeAt(startPos, startLoc);\n node.left = left;\n node.right = this.parseMaybeAssign();\n return this.finishNode(node, \"AssignmentPattern\")\n};\n\n// The following three functions all verify that a node is an lvalue \u2014\n// something that can be bound, or assigned to. In order to do so, they perform\n// a variety of checks:\n//\n// - Check that none of the bound/assigned-to identifiers are reserved words.\n// - Record name declarations for bindings in the appropriate scope.\n// - Check duplicate argument names, if checkClashes is set.\n//\n// If a complex binding pattern is encountered (e.g., object and array\n// destructuring), the entire pattern is recursively checked.\n//\n// There are three versions of checkLVal*() appropriate for different\n// circumstances:\n//\n// - checkLValSimple() shall be used if the syntactic construct supports\n// nothing other than identifiers and member expressions. Parenthesized\n// expressions are also correctly handled. This is generally appropriate for\n// constructs for which the spec says\n//\n// > It is a Syntax Error if AssignmentTargetType of [the production] is not\n// > simple.\n//\n// It is also appropriate for checking if an identifier is valid and not\n// defined elsewhere, like import declarations or function/class identifiers.\n//\n// Examples where this is used include:\n// a += \u2026;\n// import a from '\u2026';\n// where a is the node to be checked.\n//\n// - checkLValPattern() shall be used if the syntactic construct supports\n// anything checkLValSimple() supports, as well as object and array\n// destructuring patterns. This is generally appropriate for constructs for\n// which the spec says\n//\n// > It is a Syntax Error if [the production] is neither an ObjectLiteral nor\n// > an ArrayLiteral and AssignmentTargetType of [the production] is not\n// > simple.\n//\n// Examples where this is used include:\n// (a = \u2026);\n// const a = \u2026;\n// try { \u2026 } catch (a) { \u2026 }\n// where a is the node to be checked.\n//\n// - checkLValInnerPattern() shall be used if the syntactic construct supports\n// anything checkLValPattern() supports, as well as default assignment\n// patterns, rest elements, and other constructs that may appear within an\n// object or array destructuring pattern.\n//\n// As a special case, function parameters also use checkLValInnerPattern(),\n// as they also support defaults and rest constructs.\n//\n// These functions deliberately support both assignment and binding constructs,\n// as the logic for both is exceedingly similar. If the node is the target of\n// an assignment, then bindingType should be set to BIND_NONE. Otherwise, it\n// should be set to the appropriate BIND_* constant, like BIND_VAR or\n// BIND_LEXICAL.\n//\n// If the function is called with a non-BIND_NONE bindingType, then\n// additionally a checkClashes object may be specified to allow checking for\n// duplicate argument names. checkClashes is ignored if the provided construct\n// is an assignment (i.e., bindingType is BIND_NONE).\n\npp$7.checkLValSimple = function(expr, bindingType, checkClashes) {\n if ( bindingType === void 0 ) bindingType = BIND_NONE;\n\n var isBind = bindingType !== BIND_NONE;\n\n switch (expr.type) {\n case \"Identifier\":\n if (this.strict && this.reservedWordsStrictBind.test(expr.name))\n { this.raiseRecoverable(expr.start, (isBind ? \"Binding \" : \"Assigning to \") + expr.name + \" in strict mode\"); }\n if (isBind) {\n if (bindingType === BIND_LEXICAL && expr.name === \"let\")\n { this.raiseRecoverable(expr.start, \"let is disallowed as a lexically bound name\"); }\n if (checkClashes) {\n if (hasOwn(checkClashes, expr.name))\n { this.raiseRecoverable(expr.start, \"Argument name clash\"); }\n checkClashes[expr.name] = true;\n }\n if (bindingType !== BIND_OUTSIDE) { this.declareName(expr.name, bindingType, expr.start); }\n }\n break\n\n case \"ChainExpression\":\n this.raiseRecoverable(expr.start, \"Optional chaining cannot appear in left-hand side\");\n break\n\n case \"MemberExpression\":\n if (isBind) { this.raiseRecoverable(expr.start, \"Binding member expression\"); }\n break\n\n case \"ParenthesizedExpression\":\n if (isBind) { this.raiseRecoverable(expr.start, \"Binding parenthesized expression\"); }\n return this.checkLValSimple(expr.expression, bindingType, checkClashes)\n\n default:\n this.raise(expr.start, (isBind ? \"Binding\" : \"Assigning to\") + \" rvalue\");\n }\n};\n\npp$7.checkLValPattern = function(expr, bindingType, checkClashes) {\n if ( bindingType === void 0 ) bindingType = BIND_NONE;\n\n switch (expr.type) {\n case \"ObjectPattern\":\n for (var i = 0, list = expr.properties; i < list.length; i += 1) {\n var prop = list[i];\n\n this.checkLValInnerPattern(prop, bindingType, checkClashes);\n }\n break\n\n case \"ArrayPattern\":\n for (var i$1 = 0, list$1 = expr.elements; i$1 < list$1.length; i$1 += 1) {\n var elem = list$1[i$1];\n\n if (elem) { this.checkLValInnerPattern(elem, bindingType, checkClashes); }\n }\n break\n\n default:\n this.checkLValSimple(expr, bindingType, checkClashes);\n }\n};\n\npp$7.checkLValInnerPattern = function(expr, bindingType, checkClashes) {\n if ( bindingType === void 0 ) bindingType = BIND_NONE;\n\n switch (expr.type) {\n case \"Property\":\n // AssignmentProperty has type === \"Property\"\n this.checkLValInnerPattern(expr.value, bindingType, checkClashes);\n break\n\n case \"AssignmentPattern\":\n this.checkLValPattern(expr.left, bindingType, checkClashes);\n break\n\n case \"RestElement\":\n this.checkLValPattern(expr.argument, bindingType, checkClashes);\n break\n\n default:\n this.checkLValPattern(expr, bindingType, checkClashes);\n }\n};\n\n// The algorithm used to determine whether a regexp can appear at a\n\nvar TokContext = function TokContext(token, isExpr, preserveSpace, override, generator) {\n this.token = token;\n this.isExpr = !!isExpr;\n this.preserveSpace = !!preserveSpace;\n this.override = override;\n this.generator = !!generator;\n};\n\nvar types = {\n b_stat: new TokContext(\"{\", false),\n b_expr: new TokContext(\"{\", true),\n b_tmpl: new TokContext(\"${\", false),\n p_stat: new TokContext(\"(\", false),\n p_expr: new TokContext(\"(\", true),\n q_tmpl: new TokContext(\"`\", true, true, function (p) { return p.tryReadTemplateToken(); }),\n f_stat: new TokContext(\"function\", false),\n f_expr: new TokContext(\"function\", true),\n f_expr_gen: new TokContext(\"function\", true, false, null, true),\n f_gen: new TokContext(\"function\", false, false, null, true)\n};\n\nvar pp$6 = Parser.prototype;\n\npp$6.initialContext = function() {\n return [types.b_stat]\n};\n\npp$6.curContext = function() {\n return this.context[this.context.length - 1]\n};\n\npp$6.braceIsBlock = function(prevType) {\n var parent = this.curContext();\n if (parent === types.f_expr || parent === types.f_stat)\n { return true }\n if (prevType === types$1.colon && (parent === types.b_stat || parent === types.b_expr))\n { return !parent.isExpr }\n\n // The check for `tt.name && exprAllowed` detects whether we are\n // after a `yield` or `of` construct. See the `updateContext` for\n // `tt.name`.\n if (prevType === types$1._return || prevType === types$1.name && this.exprAllowed)\n { return lineBreak.test(this.input.slice(this.lastTokEnd, this.start)) }\n if (prevType === types$1._else || prevType === types$1.semi || prevType === types$1.eof || prevType === types$1.parenR || prevType === types$1.arrow)\n { return true }\n if (prevType === types$1.braceL)\n { return parent === types.b_stat }\n if (prevType === types$1._var || prevType === types$1._const || prevType === types$1.name)\n { return false }\n return !this.exprAllowed\n};\n\npp$6.inGeneratorContext = function() {\n for (var i = this.context.length - 1; i >= 1; i--) {\n var context = this.context[i];\n if (context.token === \"function\")\n { return context.generator }\n }\n return false\n};\n\npp$6.updateContext = function(prevType) {\n var update, type = this.type;\n if (type.keyword && prevType === types$1.dot)\n { this.exprAllowed = false; }\n else if (update = type.updateContext)\n { update.call(this, prevType); }\n else\n { this.exprAllowed = type.beforeExpr; }\n};\n\n// Used to handle egde cases when token context could not be inferred correctly during tokenization phase\n\npp$6.overrideContext = function(tokenCtx) {\n if (this.curContext() !== tokenCtx) {\n this.context[this.context.length - 1] = tokenCtx;\n }\n};\n\n// Token-specific context update code\n\ntypes$1.parenR.updateContext = types$1.braceR.updateContext = function() {\n if (this.context.length === 1) {\n this.exprAllowed = true;\n return\n }\n var out = this.context.pop();\n if (out === types.b_stat && this.curContext().token === \"function\") {\n out = this.context.pop();\n }\n this.exprAllowed = !out.isExpr;\n};\n\ntypes$1.braceL.updateContext = function(prevType) {\n this.context.push(this.braceIsBlock(prevType) ? types.b_stat : types.b_expr);\n this.exprAllowed = true;\n};\n\ntypes$1.dollarBraceL.updateContext = function() {\n this.context.push(types.b_tmpl);\n this.exprAllowed = true;\n};\n\ntypes$1.parenL.updateContext = function(prevType) {\n var statementParens = prevType === types$1._if || prevType === types$1._for || prevType === types$1._with || prevType === types$1._while;\n this.context.push(statementParens ? types.p_stat : types.p_expr);\n this.exprAllowed = true;\n};\n\ntypes$1.incDec.updateContext = function() {\n // tokExprAllowed stays unchanged\n};\n\ntypes$1._function.updateContext = types$1._class.updateContext = function(prevType) {\n if (prevType.beforeExpr && prevType !== types$1._else &&\n !(prevType === types$1.semi && this.curContext() !== types.p_stat) &&\n !(prevType === types$1._return && lineBreak.test(this.input.slice(this.lastTokEnd, this.start))) &&\n !((prevType === types$1.colon || prevType === types$1.braceL) && this.curContext() === types.b_stat))\n { this.context.push(types.f_expr); }\n else\n { this.context.push(types.f_stat); }\n this.exprAllowed = false;\n};\n\ntypes$1.backQuote.updateContext = function() {\n if (this.curContext() === types.q_tmpl)\n { this.context.pop(); }\n else\n { this.context.push(types.q_tmpl); }\n this.exprAllowed = false;\n};\n\ntypes$1.star.updateContext = function(prevType) {\n if (prevType === types$1._function) {\n var index = this.context.length - 1;\n if (this.context[index] === types.f_expr)\n { this.context[index] = types.f_expr_gen; }\n else\n { this.context[index] = types.f_gen; }\n }\n this.exprAllowed = true;\n};\n\ntypes$1.name.updateContext = function(prevType) {\n var allowed = false;\n if (this.options.ecmaVersion >= 6 && prevType !== types$1.dot) {\n if (this.value === \"of\" && !this.exprAllowed ||\n this.value === \"yield\" && this.inGeneratorContext())\n { allowed = true; }\n }\n this.exprAllowed = allowed;\n};\n\n// A recursive descent parser operates by defining functions for all\n\nvar pp$5 = Parser.prototype;\n\n// Check if property name clashes with already added.\n// Object/class getters and setters are not allowed to clash \u2014\n// either with each other or with an init property \u2014 and in\n// strict mode, init properties are also not allowed to be repeated.\n\npp$5.checkPropClash = function(prop, propHash, refDestructuringErrors) {\n if (this.options.ecmaVersion >= 9 && prop.type === \"SpreadElement\")\n { return }\n if (this.options.ecmaVersion >= 6 && (prop.computed || prop.method || prop.shorthand))\n { return }\n var key = prop.key;\n var name;\n switch (key.type) {\n case \"Identifier\": name = key.name; break\n case \"Literal\": name = String(key.value); break\n default: return\n }\n var kind = prop.kind;\n if (this.options.ecmaVersion >= 6) {\n if (name === \"__proto__\" && kind === \"init\") {\n if (propHash.proto) {\n if (refDestructuringErrors) {\n if (refDestructuringErrors.doubleProto < 0) {\n refDestructuringErrors.doubleProto = key.start;\n }\n } else {\n this.raiseRecoverable(key.start, \"Redefinition of __proto__ property\");\n }\n }\n propHash.proto = true;\n }\n return\n }\n name = \"$\" + name;\n var other = propHash[name];\n if (other) {\n var redefinition;\n if (kind === \"init\") {\n redefinition = this.strict && other.init || other.get || other.set;\n } else {\n redefinition = other.init || other[kind];\n }\n if (redefinition)\n { this.raiseRecoverable(key.start, \"Redefinition of property\"); }\n } else {\n other = propHash[name] = {\n init: false,\n get: false,\n set: false\n };\n }\n other[kind] = true;\n};\n\n// ### Expression parsing\n\n// These nest, from the most general expression type at the top to\n// 'atomic', nondivisible expression types at the bottom. Most of\n// the functions will simply let the function(s) below them parse,\n// and, *if* the syntactic construct they handle is present, wrap\n// the AST node that the inner parser gave them in another node.\n\n// Parse a full expression. The optional arguments are used to\n// forbid the `in` operator (in for loops initalization expressions)\n// and provide reference for storing '=' operator inside shorthand\n// property assignment in contexts where both object expression\n// and object pattern might appear (so it's possible to raise\n// delayed syntax error at correct position).\n\npp$5.parseExpression = function(forInit, refDestructuringErrors) {\n var startPos = this.start, startLoc = this.startLoc;\n var expr = this.parseMaybeAssign(forInit, refDestructuringErrors);\n if (this.type === types$1.comma) {\n var node = this.startNodeAt(startPos, startLoc);\n node.expressions = [expr];\n while (this.eat(types$1.comma)) { node.expressions.push(this.parseMaybeAssign(forInit, refDestructuringErrors)); }\n return this.finishNode(node, \"SequenceExpression\")\n }\n return expr\n};\n\n// Parse an assignment expression. This includes applications of\n// operators like `+=`.\n\npp$5.parseMaybeAssign = function(forInit, refDestructuringErrors, afterLeftParse) {\n if (this.isContextual(\"yield\")) {\n if (this.inGenerator) { return this.parseYield(forInit) }\n // The tokenizer will assume an expression is allowed after\n // `yield`, but this isn't that kind of yield\n else { this.exprAllowed = false; }\n }\n\n var ownDestructuringErrors = false, oldParenAssign = -1, oldTrailingComma = -1, oldDoubleProto = -1;\n if (refDestructuringErrors) {\n oldParenAssign = refDestructuringErrors.parenthesizedAssign;\n oldTrailingComma = refDestructuringErrors.trailingComma;\n oldDoubleProto = refDestructuringErrors.doubleProto;\n refDestructuringErrors.parenthesizedAssign = refDestructuringErrors.trailingComma = -1;\n } else {\n refDestructuringErrors = new DestructuringErrors;\n ownDestructuringErrors = true;\n }\n\n var startPos = this.start, startLoc = this.startLoc;\n if (this.type === types$1.parenL || this.type === types$1.name) {\n this.potentialArrowAt = this.start;\n this.potentialArrowInForAwait = forInit === \"await\";\n }\n var left = this.parseMaybeConditional(forInit, refDestructuringErrors);\n if (afterLeftParse) { left = afterLeftParse.call(this, left, startPos, startLoc); }\n if (this.type.isAssign) {\n var node = this.startNodeAt(startPos, startLoc);\n node.operator = this.value;\n if (this.type === types$1.eq)\n { left = this.toAssignable(left, false, refDestructuringErrors); }\n if (!ownDestructuringErrors) {\n refDestructuringErrors.parenthesizedAssign = refDestructuringErrors.trailingComma = refDestructuringErrors.doubleProto = -1;\n }\n if (refDestructuringErrors.shorthandAssign >= left.start)\n { refDestructuringErrors.shorthandAssign = -1; } // reset because shorthand default was used correctly\n if (this.type === types$1.eq)\n { this.checkLValPattern(left); }\n else\n { this.checkLValSimple(left); }\n node.left = left;\n this.next();\n node.right = this.parseMaybeAssign(forInit);\n if (oldDoubleProto > -1) { refDestructuringErrors.doubleProto = oldDoubleProto; }\n return this.finishNode(node, \"AssignmentExpression\")\n } else {\n if (ownDestructuringErrors) { this.checkExpressionErrors(refDestructuringErrors, true); }\n }\n if (oldParenAssign > -1) { refDestructuringErrors.parenthesizedAssign = oldParenAssign; }\n if (oldTrailingComma > -1) { refDestructuringErrors.trailingComma = oldTrailingComma; }\n return left\n};\n\n// Parse a ternary conditional (`?:`) operator.\n\npp$5.parseMaybeConditional = function(forInit, refDestructuringErrors) {\n var startPos = this.start, startLoc = this.startLoc;\n var expr = this.parseExprOps(forInit, refDestructuringErrors);\n if (this.checkExpressionErrors(refDestructuringErrors)) { return expr }\n if (this.eat(types$1.question)) {\n var node = this.startNodeAt(startPos, startLoc);\n node.test = expr;\n node.consequent = this.parseMaybeAssign();\n this.expect(types$1.colon);\n node.alternate = this.parseMaybeAssign(forInit);\n return this.finishNode(node, \"ConditionalExpression\")\n }\n return expr\n};\n\n// Start the precedence parser.\n\npp$5.parseExprOps = function(forInit, refDestructuringErrors) {\n var startPos = this.start, startLoc = this.startLoc;\n var expr = this.parseMaybeUnary(refDestructuringErrors, false, false, forInit);\n if (this.checkExpressionErrors(refDestructuringErrors)) { return expr }\n return expr.start === startPos && expr.type === \"ArrowFunctionExpression\" ? expr : this.parseExprOp(expr, startPos, startLoc, -1, forInit)\n};\n\n// Parse binary operators with the operator precedence parsing\n// algorithm. `left` is the left-hand side of the operator.\n// `minPrec` provides context that allows the function to stop and\n// defer further parser to one of its callers when it encounters an\n// operator that has a lower precedence than the set it is parsing.\n\npp$5.parseExprOp = function(left, leftStartPos, leftStartLoc, minPrec, forInit) {\n var prec = this.type.binop;\n if (prec != null && (!forInit || this.type !== types$1._in)) {\n if (prec > minPrec) {\n var logical = this.type === types$1.logicalOR || this.type === types$1.logicalAND;\n var coalesce = this.type === types$1.coalesce;\n if (coalesce) {\n // Handle the precedence of `tt.coalesce` as equal to the range of logical expressions.\n // In other words, `node.right` shouldn't contain logical expressions in order to check the mixed error.\n prec = types$1.logicalAND.binop;\n }\n var op = this.value;\n this.next();\n var startPos = this.start, startLoc = this.startLoc;\n var right = this.parseExprOp(this.parseMaybeUnary(null, false, false, forInit), startPos, startLoc, prec, forInit);\n var node = this.buildBinary(leftStartPos, leftStartLoc, left, right, op, logical || coalesce);\n if ((logical && this.type === types$1.coalesce) || (coalesce && (this.type === types$1.logicalOR || this.type === types$1.logicalAND))) {\n this.raiseRecoverable(this.start, \"Logical expressions and coalesce expressions cannot be mixed. Wrap either by parentheses\");\n }\n return this.parseExprOp(node, leftStartPos, leftStartLoc, minPrec, forInit)\n }\n }\n return left\n};\n\npp$5.buildBinary = function(startPos, startLoc, left, right, op, logical) {\n if (right.type === \"PrivateIdentifier\") { this.raise(right.start, \"Private identifier can only be left side of binary expression\"); }\n var node = this.startNodeAt(startPos, startLoc);\n node.left = left;\n node.operator = op;\n node.right = right;\n return this.finishNode(node, logical ? \"LogicalExpression\" : \"BinaryExpression\")\n};\n\n// Parse unary operators, both prefix and postfix.\n\npp$5.parseMaybeUnary = function(refDestructuringErrors, sawUnary, incDec, forInit) {\n var startPos = this.start, startLoc = this.startLoc, expr;\n if (this.isContextual(\"await\") && this.canAwait) {\n expr = this.parseAwait(forInit);\n sawUnary = true;\n } else if (this.type.prefix) {\n var node = this.startNode(), update = this.type === types$1.incDec;\n node.operator = this.value;\n node.prefix = true;\n this.next();\n node.argument = this.parseMaybeUnary(null, true, update, forInit);\n this.checkExpressionErrors(refDestructuringErrors, true);\n if (update) { this.checkLValSimple(node.argument); }\n else if (this.strict && node.operator === \"delete\" &&\n node.argument.type === \"Identifier\")\n { this.raiseRecoverable(node.start, \"Deleting local variable in strict mode\"); }\n else if (node.operator === \"delete\" && isPrivateFieldAccess(node.argument))\n { this.raiseRecoverable(node.start, \"Private fields can not be deleted\"); }\n else { sawUnary = true; }\n expr = this.finishNode(node, update ? \"UpdateExpression\" : \"UnaryExpression\");\n } else if (!sawUnary && this.type === types$1.privateId) {\n if (forInit || this.privateNameStack.length === 0) { this.unexpected(); }\n expr = this.parsePrivateIdent();\n // only could be private fields in 'in', such as #x in obj\n if (this.type !== types$1._in) { this.unexpected(); }\n } else {\n expr = this.parseExprSubscripts(refDestructuringErrors, forInit);\n if (this.checkExpressionErrors(refDestructuringErrors)) { return expr }\n while (this.type.postfix && !this.canInsertSemicolon()) {\n var node$1 = this.startNodeAt(startPos, startLoc);\n node$1.operator = this.value;\n node$1.prefix = false;\n node$1.argument = expr;\n this.checkLValSimple(expr);\n this.next();\n expr = this.finishNode(node$1, \"UpdateExpression\");\n }\n }\n\n if (!incDec && this.eat(types$1.starstar)) {\n if (sawUnary)\n { this.unexpected(this.lastTokStart); }\n else\n { return this.buildBinary(startPos, startLoc, expr, this.parseMaybeUnary(null, false, false, forInit), \"**\", false) }\n } else {\n return expr\n }\n};\n\nfunction isPrivateFieldAccess(node) {\n return (\n node.type === \"MemberExpression\" && node.property.type === \"PrivateIdentifier\" ||\n node.type === \"ChainExpression\" && isPrivateFieldAccess(node.expression)\n )\n}\n\n// Parse call, dot, and `[]`-subscript expressions.\n\npp$5.parseExprSubscripts = function(refDestructuringErrors, forInit) {\n var startPos = this.start, startLoc = this.startLoc;\n var expr = this.parseExprAtom(refDestructuringErrors, forInit);\n if (expr.type === \"ArrowFunctionExpression\" && this.input.slice(this.lastTokStart, this.lastTokEnd) !== \")\")\n { return expr }\n var result = this.parseSubscripts(expr, startPos, startLoc, false, forInit);\n if (refDestructuringErrors && result.type === \"MemberExpression\") {\n if (refDestructuringErrors.parenthesizedAssign >= result.start) { refDestructuringErrors.parenthesizedAssign = -1; }\n if (refDestructuringErrors.parenthesizedBind >= result.start) { refDestructuringErrors.parenthesizedBind = -1; }\n if (refDestructuringErrors.trailingComma >= result.start) { refDestructuringErrors.trailingComma = -1; }\n }\n return result\n};\n\npp$5.parseSubscripts = function(base, startPos, startLoc, noCalls, forInit) {\n var maybeAsyncArrow = this.options.ecmaVersion >= 8 && base.type === \"Identifier\" && base.name === \"async\" &&\n this.lastTokEnd === base.end && !this.canInsertSemicolon() && base.end - base.start === 5 &&\n this.potentialArrowAt === base.start;\n var optionalChained = false;\n\n while (true) {\n var element = this.parseSubscript(base, startPos, startLoc, noCalls, maybeAsyncArrow, optionalChained, forInit);\n\n if (element.optional) { optionalChained = true; }\n if (element === base || element.type === \"ArrowFunctionExpression\") {\n if (optionalChained) {\n var chainNode = this.startNodeAt(startPos, startLoc);\n chainNode.expression = element;\n element = this.finishNode(chainNode, \"ChainExpression\");\n }\n return element\n }\n\n base = element;\n }\n};\n\npp$5.parseSubscript = function(base, startPos, startLoc, noCalls, maybeAsyncArrow, optionalChained, forInit) {\n var optionalSupported = this.options.ecmaVersion >= 11;\n var optional = optionalSupported && this.eat(types$1.questionDot);\n if (noCalls && optional) { this.raise(this.lastTokStart, \"Optional chaining cannot appear in the callee of new expressions\"); }\n\n var computed = this.eat(types$1.bracketL);\n if (computed || (optional && this.type !== types$1.parenL && this.type !== types$1.backQuote) || this.eat(types$1.dot)) {\n var node = this.startNodeAt(startPos, startLoc);\n node.object = base;\n if (computed) {\n node.property = this.parseExpression();\n this.expect(types$1.bracketR);\n } else if (this.type === types$1.privateId && base.type !== \"Super\") {\n node.property = this.parsePrivateIdent();\n } else {\n node.property = this.parseIdent(this.options.allowReserved !== \"never\");\n }\n node.computed = !!computed;\n if (optionalSupported) {\n node.optional = optional;\n }\n base = this.finishNode(node, \"MemberExpression\");\n } else if (!noCalls && this.eat(types$1.parenL)) {\n var refDestructuringErrors = new DestructuringErrors, oldYieldPos = this.yieldPos, oldAwaitPos = this.awaitPos, oldAwaitIdentPos = this.awaitIdentPos;\n this.yieldPos = 0;\n this.awaitPos = 0;\n this.awaitIdentPos = 0;\n var exprList = this.parseExprList(types$1.parenR, this.options.ecmaVersion >= 8, false, refDestructuringErrors);\n if (maybeAsyncArrow && !optional && !this.canInsertSemicolon() && this.eat(types$1.arrow)) {\n this.checkPatternErrors(refDestructuringErrors, false);\n this.checkYieldAwaitInDefaultParams();\n if (this.awaitIdentPos > 0)\n { this.raise(this.awaitIdentPos, \"Cannot use 'await' as identifier inside an async function\"); }\n this.yieldPos = oldYieldPos;\n this.awaitPos = oldAwaitPos;\n this.awaitIdentPos = oldAwaitIdentPos;\n return this.parseArrowExpression(this.startNodeAt(startPos, startLoc), exprList, true, forInit)\n }\n this.checkExpressionErrors(refDestructuringErrors, true);\n this.yieldPos = oldYieldPos || this.yieldPos;\n this.awaitPos = oldAwaitPos || this.awaitPos;\n this.awaitIdentPos = oldAwaitIdentPos || this.awaitIdentPos;\n var node$1 = this.startNodeAt(startPos, startLoc);\n node$1.callee = base;\n node$1.arguments = exprList;\n if (optionalSupported) {\n node$1.optional = optional;\n }\n base = this.finishNode(node$1, \"CallExpression\");\n } else if (this.type === types$1.backQuote) {\n if (optional || optionalChained) {\n this.raise(this.start, \"Optional chaining cannot appear in the tag of tagged template expressions\");\n }\n var node$2 = this.startNodeAt(startPos, startLoc);\n node$2.tag = base;\n node$2.quasi = this.parseTemplate({isTagged: true});\n base = this.finishNode(node$2, \"TaggedTemplateExpression\");\n }\n return base\n};\n\n// Parse an atomic expression \u2014 either a single token that is an\n// expression, an expression started by a keyword like `function` or\n// `new`, or an expression wrapped in punctuation like `()`, `[]`,\n// or `{}`.\n\npp$5.parseExprAtom = function(refDestructuringErrors, forInit) {\n // If a division operator appears in an expression position, the\n // tokenizer got confused, and we force it to read a regexp instead.\n if (this.type === types$1.slash) { this.readRegexp(); }\n\n var node, canBeArrow = this.potentialArrowAt === this.start;\n switch (this.type) {\n case types$1._super:\n if (!this.allowSuper)\n { this.raise(this.start, \"'super' keyword outside a method\"); }\n node = this.startNode();\n this.next();\n if (this.type === types$1.parenL && !this.allowDirectSuper)\n { this.raise(node.start, \"super() call outside constructor of a subclass\"); }\n // The `super` keyword can appear at below:\n // SuperProperty:\n // super [ Expression ]\n // super . IdentifierName\n // SuperCall:\n // super ( Arguments )\n if (this.type !== types$1.dot && this.type !== types$1.bracketL && this.type !== types$1.parenL)\n { this.unexpected(); }\n return this.finishNode(node, \"Super\")\n\n case types$1._this:\n node = this.startNode();\n this.next();\n return this.finishNode(node, \"ThisExpression\")\n\n case types$1.name:\n var startPos = this.start, startLoc = this.startLoc, containsEsc = this.containsEsc;\n var id = this.parseIdent(false);\n if (this.options.ecmaVersion >= 8 && !containsEsc && id.name === \"async\" && !this.canInsertSemicolon() && this.eat(types$1._function)) {\n this.overrideContext(types.f_expr);\n return this.parseFunction(this.startNodeAt(startPos, startLoc), 0, false, true, forInit)\n }\n if (canBeArrow && !this.canInsertSemicolon()) {\n if (this.eat(types$1.arrow))\n { return this.parseArrowExpression(this.startNodeAt(startPos, startLoc), [id], false, forInit) }\n if (this.options.ecmaVersion >= 8 && id.name === \"async\" && this.type === types$1.name && !containsEsc &&\n (!this.potentialArrowInForAwait || this.value !== \"of\" || this.containsEsc)) {\n id = this.parseIdent(false);\n if (this.canInsertSemicolon() || !this.eat(types$1.arrow))\n { this.unexpected(); }\n return this.parseArrowExpression(this.startNodeAt(startPos, startLoc), [id], true, forInit)\n }\n }\n return id\n\n case types$1.regexp:\n var value = this.value;\n node = this.parseLiteral(value.value);\n node.regex = {pattern: value.pattern, flags: value.flags};\n return node\n\n case types$1.num: case types$1.string:\n return this.parseLiteral(this.value)\n\n case types$1._null: case types$1._true: case types$1._false:\n node = this.startNode();\n node.value = this.type === types$1._null ? null : this.type === types$1._true;\n node.raw = this.type.keyword;\n this.next();\n return this.finishNode(node, \"Literal\")\n\n case types$1.parenL:\n var start = this.start, expr = this.parseParenAndDistinguishExpression(canBeArrow, forInit);\n if (refDestructuringErrors) {\n if (refDestructuringErrors.parenthesizedAssign < 0 && !this.isSimpleAssignTarget(expr))\n { refDestructuringErrors.parenthesizedAssign = start; }\n if (refDestructuringErrors.parenthesizedBind < 0)\n { refDestructuringErrors.parenthesizedBind = start; }\n }\n return expr\n\n case types$1.bracketL:\n node = this.startNode();\n this.next();\n node.elements = this.parseExprList(types$1.bracketR, true, true, refDestructuringErrors);\n return this.finishNode(node, \"ArrayExpression\")\n\n case types$1.braceL:\n this.overrideContext(types.b_expr);\n return this.parseObj(false, refDestructuringErrors)\n\n case types$1._function:\n node = this.startNode();\n this.next();\n return this.parseFunction(node, 0)\n\n case types$1._class:\n return this.parseClass(this.startNode(), false)\n\n case types$1._new:\n return this.parseNew()\n\n case types$1.backQuote:\n return this.parseTemplate()\n\n case types$1._import:\n if (this.options.ecmaVersion >= 11) {\n return this.parseExprImport()\n } else {\n return this.unexpected()\n }\n\n default:\n this.unexpected();\n }\n};\n\npp$5.parseExprImport = function() {\n var node = this.startNode();\n\n // Consume `import` as an identifier for `import.meta`.\n // Because `this.parseIdent(true)` doesn't check escape sequences, it needs the check of `this.containsEsc`.\n if (this.containsEsc) { this.raiseRecoverable(this.start, \"Escape sequence in keyword import\"); }\n var meta = this.parseIdent(true);\n\n switch (this.type) {\n case types$1.parenL:\n return this.parseDynamicImport(node)\n case types$1.dot:\n node.meta = meta;\n return this.parseImportMeta(node)\n default:\n this.unexpected();\n }\n};\n\npp$5.parseDynamicImport = function(node) {\n this.next(); // skip `(`\n\n // Parse node.source.\n node.source = this.parseMaybeAssign();\n\n // Verify ending.\n if (!this.eat(types$1.parenR)) {\n var errorPos = this.start;\n if (this.eat(types$1.comma) && this.eat(types$1.parenR)) {\n this.raiseRecoverable(errorPos, \"Trailing comma is not allowed in import()\");\n } else {\n this.unexpected(errorPos);\n }\n }\n\n return this.finishNode(node, \"ImportExpression\")\n};\n\npp$5.parseImportMeta = function(node) {\n this.next(); // skip `.`\n\n var containsEsc = this.containsEsc;\n node.property = this.parseIdent(true);\n\n if (node.property.name !== \"meta\")\n { this.raiseRecoverable(node.property.start, \"The only valid meta property for import is 'import.meta'\"); }\n if (containsEsc)\n { this.raiseRecoverable(node.start, \"'import.meta' must not contain escaped characters\"); }\n if (this.options.sourceType !== \"module\" && !this.options.allowImportExportEverywhere)\n { this.raiseRecoverable(node.start, \"Cannot use 'import.meta' outside a module\"); }\n\n return this.finishNode(node, \"MetaProperty\")\n};\n\npp$5.parseLiteral = function(value) {\n var node = this.startNode();\n node.value = value;\n node.raw = this.input.slice(this.start, this.end);\n if (node.raw.charCodeAt(node.raw.length - 1) === 110) { node.bigint = node.raw.slice(0, -1).replace(/_/g, \"\"); }\n this.next();\n return this.finishNode(node, \"Literal\")\n};\n\npp$5.parseParenExpression = function() {\n this.expect(types$1.parenL);\n var val = this.parseExpression();\n this.expect(types$1.parenR);\n return val\n};\n\npp$5.parseParenAndDistinguishExpression = function(canBeArrow, forInit) {\n var startPos = this.start, startLoc = this.startLoc, val, allowTrailingComma = this.options.ecmaVersion >= 8;\n if (this.options.ecmaVersion >= 6) {\n this.next();\n\n var innerStartPos = this.start, innerStartLoc = this.startLoc;\n var exprList = [], first = true, lastIsComma = false;\n var refDestructuringErrors = new DestructuringErrors, oldYieldPos = this.yieldPos, oldAwaitPos = this.awaitPos, spreadStart;\n this.yieldPos = 0;\n this.awaitPos = 0;\n // Do not save awaitIdentPos to allow checking awaits nested in parameters\n while (this.type !== types$1.parenR) {\n first ? first = false : this.expect(types$1.comma);\n if (allowTrailingComma && this.afterTrailingComma(types$1.parenR, true)) {\n lastIsComma = true;\n break\n } else if (this.type === types$1.ellipsis) {\n spreadStart = this.start;\n exprList.push(this.parseParenItem(this.parseRestBinding()));\n if (this.type === types$1.comma) { this.raise(this.start, \"Comma is not permitted after the rest element\"); }\n break\n } else {\n exprList.push(this.parseMaybeAssign(false, refDestructuringErrors, this.parseParenItem));\n }\n }\n var innerEndPos = this.lastTokEnd, innerEndLoc = this.lastTokEndLoc;\n this.expect(types$1.parenR);\n\n if (canBeArrow && !this.canInsertSemicolon() && this.eat(types$1.arrow)) {\n this.checkPatternErrors(refDestructuringErrors, false);\n this.checkYieldAwaitInDefaultParams();\n this.yieldPos = oldYieldPos;\n this.awaitPos = oldAwaitPos;\n return this.parseParenArrowList(startPos, startLoc, exprList, forInit)\n }\n\n if (!exprList.length || lastIsComma) { this.unexpected(this.lastTokStart); }\n if (spreadStart) { this.unexpected(spreadStart); }\n this.checkExpressionErrors(refDestructuringErrors, true);\n this.yieldPos = oldYieldPos || this.yieldPos;\n this.awaitPos = oldAwaitPos || this.awaitPos;\n\n if (exprList.length > 1) {\n val = this.startNodeAt(innerStartPos, innerStartLoc);\n val.expressions = exprList;\n this.finishNodeAt(val, \"SequenceExpression\", innerEndPos, innerEndLoc);\n } else {\n val = exprList[0];\n }\n } else {\n val = this.parseParenExpression();\n }\n\n if (this.options.preserveParens) {\n var par = this.startNodeAt(startPos, startLoc);\n par.expression = val;\n return this.finishNode(par, \"ParenthesizedExpression\")\n } else {\n return val\n }\n};\n\npp$5.parseParenItem = function(item) {\n return item\n};\n\npp$5.parseParenArrowList = function(startPos, startLoc, exprList, forInit) {\n return this.parseArrowExpression(this.startNodeAt(startPos, startLoc), exprList, false, forInit)\n};\n\n// New's precedence is slightly tricky. It must allow its argument to\n// be a `[]` or dot subscript expression, but not a call \u2014 at least,\n// not without wrapping it in parentheses. Thus, it uses the noCalls\n// argument to parseSubscripts to prevent it from consuming the\n// argument list.\n\nvar empty = [];\n\npp$5.parseNew = function() {\n if (this.containsEsc) { this.raiseRecoverable(this.start, \"Escape sequence in keyword new\"); }\n var node = this.startNode();\n var meta = this.parseIdent(true);\n if (this.options.ecmaVersion >= 6 && this.eat(types$1.dot)) {\n node.meta = meta;\n var containsEsc = this.containsEsc;\n node.property = this.parseIdent(true);\n if (node.property.name !== \"target\")\n { this.raiseRecoverable(node.property.start, \"The only valid meta property for new is 'new.target'\"); }\n if (containsEsc)\n { this.raiseRecoverable(node.start, \"'new.target' must not contain escaped characters\"); }\n if (!this.allowNewDotTarget)\n { this.raiseRecoverable(node.start, \"'new.target' can only be used in functions and class static block\"); }\n return this.finishNode(node, \"MetaProperty\")\n }\n var startPos = this.start, startLoc = this.startLoc, isImport = this.type === types$1._import;\n node.callee = this.parseSubscripts(this.parseExprAtom(), startPos, startLoc, true, false);\n if (isImport && node.callee.type === \"ImportExpression\") {\n this.raise(startPos, \"Cannot use new with import()\");\n }\n if (this.eat(types$1.parenL)) { node.arguments = this.parseExprList(types$1.parenR, this.options.ecmaVersion >= 8, false); }\n else { node.arguments = empty; }\n return this.finishNode(node, \"NewExpression\")\n};\n\n// Parse template expression.\n\npp$5.parseTemplateElement = function(ref) {\n var isTagged = ref.isTagged;\n\n var elem = this.startNode();\n if (this.type === types$1.invalidTemplate) {\n if (!isTagged) {\n this.raiseRecoverable(this.start, \"Bad escape sequence in untagged template literal\");\n }\n elem.value = {\n raw: this.value,\n cooked: null\n };\n } else {\n elem.value = {\n raw: this.input.slice(this.start, this.end).replace(/\\r\\n?/g, \"\\n\"),\n cooked: this.value\n };\n }\n this.next();\n elem.tail = this.type === types$1.backQuote;\n return this.finishNode(elem, \"TemplateElement\")\n};\n\npp$5.parseTemplate = function(ref) {\n if ( ref === void 0 ) ref = {};\n var isTagged = ref.isTagged; if ( isTagged === void 0 ) isTagged = false;\n\n var node = this.startNode();\n this.next();\n node.expressions = [];\n var curElt = this.parseTemplateElement({isTagged: isTagged});\n node.quasis = [curElt];\n while (!curElt.tail) {\n if (this.type === types$1.eof) { this.raise(this.pos, \"Unterminated template literal\"); }\n this.expect(types$1.dollarBraceL);\n node.expressions.push(this.parseExpression());\n this.expect(types$1.braceR);\n node.quasis.push(curElt = this.parseTemplateElement({isTagged: isTagged}));\n }\n this.next();\n return this.finishNode(node, \"TemplateLiteral\")\n};\n\npp$5.isAsyncProp = function(prop) {\n return !prop.computed && prop.key.type === \"Identifier\" && prop.key.name === \"async\" &&\n (this.type === types$1.name || this.type === types$1.num || this.type === types$1.string || this.type === types$1.bracketL || this.type.keyword || (this.options.ecmaVersion >= 9 && this.type === types$1.star)) &&\n !lineBreak.test(this.input.slice(this.lastTokEnd, this.start))\n};\n\n// Parse an object literal or binding pattern.\n\npp$5.parseObj = function(isPattern, refDestructuringErrors) {\n var node = this.startNode(), first = true, propHash = {};\n node.properties = [];\n this.next();\n while (!this.eat(types$1.braceR)) {\n if (!first) {\n this.expect(types$1.comma);\n if (this.options.ecmaVersion >= 5 && this.afterTrailingComma(types$1.braceR)) { break }\n } else { first = false; }\n\n var prop = this.parseProperty(isPattern, refDestructuringErrors);\n if (!isPattern) { this.checkPropClash(prop, propHash, refDestructuringErrors); }\n node.properties.push(prop);\n }\n return this.finishNode(node, isPattern ? \"ObjectPattern\" : \"ObjectExpression\")\n};\n\npp$5.parseProperty = function(isPattern, refDestructuringErrors) {\n var prop = this.startNode(), isGenerator, isAsync, startPos, startLoc;\n if (this.options.ecmaVersion >= 9 && this.eat(types$1.ellipsis)) {\n if (isPattern) {\n prop.argument = this.parseIdent(false);\n if (this.type === types$1.comma) {\n this.raise(this.start, \"Comma is not permitted after the rest element\");\n }\n return this.finishNode(prop, \"RestElement\")\n }\n // Parse argument.\n prop.argument = this.parseMaybeAssign(false, refDestructuringErrors);\n // To disallow trailing comma via `this.toAssignable()`.\n if (this.type === types$1.comma && refDestructuringErrors && refDestructuringErrors.trailingComma < 0) {\n refDestructuringErrors.trailingComma = this.start;\n }\n // Finish\n return this.finishNode(prop, \"SpreadElement\")\n }\n if (this.options.ecmaVersion >= 6) {\n prop.method = false;\n prop.shorthand = false;\n if (isPattern || refDestructuringErrors) {\n startPos = this.start;\n startLoc = this.startLoc;\n }\n if (!isPattern)\n { isGenerator = this.eat(types$1.star); }\n }\n var containsEsc = this.containsEsc;\n this.parsePropertyName(prop);\n if (!isPattern && !containsEsc && this.options.ecmaVersion >= 8 && !isGenerator && this.isAsyncProp(prop)) {\n isAsync = true;\n isGenerator = this.options.ecmaVersion >= 9 && this.eat(types$1.star);\n this.parsePropertyName(prop, refDestructuringErrors);\n } else {\n isAsync = false;\n }\n this.parsePropertyValue(prop, isPattern, isGenerator, isAsync, startPos, startLoc, refDestructuringErrors, containsEsc);\n return this.finishNode(prop, \"Property\")\n};\n\npp$5.parsePropertyValue = function(prop, isPattern, isGenerator, isAsync, startPos, startLoc, refDestructuringErrors, containsEsc) {\n if ((isGenerator || isAsync) && this.type === types$1.colon)\n { this.unexpected(); }\n\n if (this.eat(types$1.colon)) {\n prop.value = isPattern ? this.parseMaybeDefault(this.start, this.startLoc) : this.parseMaybeAssign(false, refDestructuringErrors);\n prop.kind = \"init\";\n } else if (this.options.ecmaVersion >= 6 && this.type === types$1.parenL) {\n if (isPattern) { this.unexpected(); }\n prop.kind = \"init\";\n prop.method = true;\n prop.value = this.parseMethod(isGenerator, isAsync);\n } else if (!isPattern && !containsEsc &&\n this.options.ecmaVersion >= 5 && !prop.computed && prop.key.type === \"Identifier\" &&\n (prop.key.name === \"get\" || prop.key.name === \"set\") &&\n (this.type !== types$1.comma && this.type !== types$1.braceR && this.type !== types$1.eq)) {\n if (isGenerator || isAsync) { this.unexpected(); }\n prop.kind = prop.key.name;\n this.parsePropertyName(prop);\n prop.value = this.parseMethod(false);\n var paramCount = prop.kind === \"get\" ? 0 : 1;\n if (prop.value.params.length !== paramCount) {\n var start = prop.value.start;\n if (prop.kind === \"get\")\n { this.raiseRecoverable(start, \"getter should have no params\"); }\n else\n { this.raiseRecoverable(start, \"setter should have exactly one param\"); }\n } else {\n if (prop.kind === \"set\" && prop.value.params[0].type === \"RestElement\")\n { this.raiseRecoverable(prop.value.params[0].start, \"Setter cannot use rest params\"); }\n }\n } else if (this.options.ecmaVersion >= 6 && !prop.computed && prop.key.type === \"Identifier\") {\n if (isGenerator || isAsync) { this.unexpected(); }\n this.checkUnreserved(prop.key);\n if (prop.key.name === \"await\" && !this.awaitIdentPos)\n { this.awaitIdentPos = startPos; }\n prop.kind = \"init\";\n if (isPattern) {\n prop.value = this.parseMaybeDefault(startPos, startLoc, this.copyNode(prop.key));\n } else if (this.type === types$1.eq && refDestructuringErrors) {\n if (refDestructuringErrors.shorthandAssign < 0)\n { refDestructuringErrors.shorthandAssign = this.start; }\n prop.value = this.parseMaybeDefault(startPos, startLoc, this.copyNode(prop.key));\n } else {\n prop.value = this.copyNode(prop.key);\n }\n prop.shorthand = true;\n } else { this.unexpected(); }\n};\n\npp$5.parsePropertyName = function(prop) {\n if (this.options.ecmaVersion >= 6) {\n if (this.eat(types$1.bracketL)) {\n prop.computed = true;\n prop.key = this.parseMaybeAssign();\n this.expect(types$1.bracketR);\n return prop.key\n } else {\n prop.computed = false;\n }\n }\n return prop.key = this.type === types$1.num || this.type === types$1.string ? this.parseExprAtom() : this.parseIdent(this.options.allowReserved !== \"never\")\n};\n\n// Initialize empty function node.\n\npp$5.initFunction = function(node) {\n node.id = null;\n if (this.options.ecmaVersion >= 6) { node.generator = node.expression = false; }\n if (this.options.ecmaVersion >= 8) { node.async = false; }\n};\n\n// Parse object or class method.\n\npp$5.parseMethod = function(isGenerator, isAsync, allowDirectSuper) {\n var node = this.startNode(), oldYieldPos = this.yieldPos, oldAwaitPos = this.awaitPos, oldAwaitIdentPos = this.awaitIdentPos;\n\n this.initFunction(node);\n if (this.options.ecmaVersion >= 6)\n { node.generator = isGenerator; }\n if (this.options.ecmaVersion >= 8)\n { node.async = !!isAsync; }\n\n this.yieldPos = 0;\n this.awaitPos = 0;\n this.awaitIdentPos = 0;\n this.enterScope(functionFlags(isAsync, node.generator) | SCOPE_SUPER | (allowDirectSuper ? SCOPE_DIRECT_SUPER : 0));\n\n this.expect(types$1.parenL);\n node.params = this.parseBindingList(types$1.parenR, false, this.options.ecmaVersion >= 8);\n this.checkYieldAwaitInDefaultParams();\n this.parseFunctionBody(node, false, true, false);\n\n this.yieldPos = oldYieldPos;\n this.awaitPos = oldAwaitPos;\n this.awaitIdentPos = oldAwaitIdentPos;\n return this.finishNode(node, \"FunctionExpression\")\n};\n\n// Parse arrow function expression with given parameters.\n\npp$5.parseArrowExpression = function(node, params, isAsync, forInit) {\n var oldYieldPos = this.yieldPos, oldAwaitPos = this.awaitPos, oldAwaitIdentPos = this.awaitIdentPos;\n\n this.enterScope(functionFlags(isAsync, false) | SCOPE_ARROW);\n this.initFunction(node);\n if (this.options.ecmaVersion >= 8) { node.async = !!isAsync; }\n\n this.yieldPos = 0;\n this.awaitPos = 0;\n this.awaitIdentPos = 0;\n\n node.params = this.toAssignableList(params, true);\n this.parseFunctionBody(node, true, false, forInit);\n\n this.yieldPos = oldYieldPos;\n this.awaitPos = oldAwaitPos;\n this.awaitIdentPos = oldAwaitIdentPos;\n return this.finishNode(node, \"ArrowFunctionExpression\")\n};\n\n// Parse function body and check parameters.\n\npp$5.parseFunctionBody = function(node, isArrowFunction, isMethod, forInit) {\n var isExpression = isArrowFunction && this.type !== types$1.braceL;\n var oldStrict = this.strict, useStrict = false;\n\n if (isExpression) {\n node.body = this.parseMaybeAssign(forInit);\n node.expression = true;\n this.checkParams(node, false);\n } else {\n var nonSimple = this.options.ecmaVersion >= 7 && !this.isSimpleParamList(node.params);\n if (!oldStrict || nonSimple) {\n useStrict = this.strictDirective(this.end);\n // If this is a strict mode function, verify that argument names\n // are not repeated, and it does not try to bind the words `eval`\n // or `arguments`.\n if (useStrict && nonSimple)\n { this.raiseRecoverable(node.start, \"Illegal 'use strict' directive in function with non-simple parameter list\"); }\n }\n // Start a new scope with regard to labels and the `inFunction`\n // flag (restore them to their old value afterwards).\n var oldLabels = this.labels;\n this.labels = [];\n if (useStrict) { this.strict = true; }\n\n // Add the params to varDeclaredNames to ensure that an error is thrown\n // if a let/const declaration in the function clashes with one of the params.\n this.checkParams(node, !oldStrict && !useStrict && !isArrowFunction && !isMethod && this.isSimpleParamList(node.params));\n // Ensure the function name isn't a forbidden identifier in strict mode, e.g. 'eval'\n if (this.strict && node.id) { this.checkLValSimple(node.id, BIND_OUTSIDE); }\n node.body = this.parseBlock(false, undefined, useStrict && !oldStrict);\n node.expression = false;\n this.adaptDirectivePrologue(node.body.body);\n this.labels = oldLabels;\n }\n this.exitScope();\n};\n\npp$5.isSimpleParamList = function(params) {\n for (var i = 0, list = params; i < list.length; i += 1)\n {\n var param = list[i];\n\n if (param.type !== \"Identifier\") { return false\n } }\n return true\n};\n\n// Checks function params for various disallowed patterns such as using \"eval\"\n// or \"arguments\" and duplicate parameters.\n\npp$5.checkParams = function(node, allowDuplicates) {\n var nameHash = Object.create(null);\n for (var i = 0, list = node.params; i < list.length; i += 1)\n {\n var param = list[i];\n\n this.checkLValInnerPattern(param, BIND_VAR, allowDuplicates ? null : nameHash);\n }\n};\n\n// Parses a comma-separated list of expressions, and returns them as\n// an array. `close` is the token type that ends the list, and\n// `allowEmpty` can be turned on to allow subsequent commas with\n// nothing in between them to be parsed as `null` (which is needed\n// for array literals).\n\npp$5.parseExprList = function(close, allowTrailingComma, allowEmpty, refDestructuringErrors) {\n var elts = [], first = true;\n while (!this.eat(close)) {\n if (!first) {\n this.expect(types$1.comma);\n if (allowTrailingComma && this.afterTrailingComma(close)) { break }\n } else { first = false; }\n\n var elt = (void 0);\n if (allowEmpty && this.type === types$1.comma)\n { elt = null; }\n else if (this.type === types$1.ellipsis) {\n elt = this.parseSpread(refDestructuringErrors);\n if (refDestructuringErrors && this.type === types$1.comma && refDestructuringErrors.trailingComma < 0)\n { refDestructuringErrors.trailingComma = this.start; }\n } else {\n elt = this.parseMaybeAssign(false, refDestructuringErrors);\n }\n elts.push(elt);\n }\n return elts\n};\n\npp$5.checkUnreserved = function(ref) {\n var start = ref.start;\n var end = ref.end;\n var name = ref.name;\n\n if (this.inGenerator && name === \"yield\")\n { this.raiseRecoverable(start, \"Cannot use 'yield' as identifier inside a generator\"); }\n if (this.inAsync && name === \"await\")\n { this.raiseRecoverable(start, \"Cannot use 'await' as identifier inside an async function\"); }\n if (this.currentThisScope().inClassFieldInit && name === \"arguments\")\n { this.raiseRecoverable(start, \"Cannot use 'arguments' in class field initializer\"); }\n if (this.inClassStaticBlock && (name === \"arguments\" || name === \"await\"))\n { this.raise(start, (\"Cannot use \" + name + \" in class static initialization block\")); }\n if (this.keywords.test(name))\n { this.raise(start, (\"Unexpected keyword '\" + name + \"'\")); }\n if (this.options.ecmaVersion < 6 &&\n this.input.slice(start, end).indexOf(\"\\\\\") !== -1) { return }\n var re = this.strict ? this.reservedWordsStrict : this.reservedWords;\n if (re.test(name)) {\n if (!this.inAsync && name === \"await\")\n { this.raiseRecoverable(start, \"Cannot use keyword 'await' outside an async function\"); }\n this.raiseRecoverable(start, (\"The keyword '\" + name + \"' is reserved\"));\n }\n};\n\n// Parse the next token as an identifier. If `liberal` is true (used\n// when parsing properties), it will also convert keywords into\n// identifiers.\n\npp$5.parseIdent = function(liberal, isBinding) {\n var node = this.startNode();\n if (this.type === types$1.name) {\n node.name = this.value;\n } else if (this.type.keyword) {\n node.name = this.type.keyword;\n\n // To fix https://github.com/acornjs/acorn/issues/575\n // `class` and `function` keywords push new context into this.context.\n // But there is no chance to pop the context if the keyword is consumed as an identifier such as a property name.\n // If the previous token is a dot, this does not apply because the context-managing code already ignored the keyword\n if ((node.name === \"class\" || node.name === \"function\") &&\n (this.lastTokEnd !== this.lastTokStart + 1 || this.input.charCodeAt(this.lastTokStart) !== 46)) {\n this.context.pop();\n }\n } else {\n this.unexpected();\n }\n this.next(!!liberal);\n this.finishNode(node, \"Identifier\");\n if (!liberal) {\n this.checkUnreserved(node);\n if (node.name === \"await\" && !this.awaitIdentPos)\n { this.awaitIdentPos = node.start; }\n }\n return node\n};\n\npp$5.parsePrivateIdent = function() {\n var node = this.startNode();\n if (this.type === types$1.privateId) {\n node.name = this.value;\n } else {\n this.unexpected();\n }\n this.next();\n this.finishNode(node, \"PrivateIdentifier\");\n\n // For validating existence\n if (this.privateNameStack.length === 0) {\n this.raise(node.start, (\"Private field '#\" + (node.name) + \"' must be declared in an enclosing class\"));\n } else {\n this.privateNameStack[this.privateNameStack.length - 1].used.push(node);\n }\n\n return node\n};\n\n// Parses yield expression inside generator.\n\npp$5.parseYield = function(forInit) {\n if (!this.yieldPos) { this.yieldPos = this.start; }\n\n var node = this.startNode();\n this.next();\n if (this.type === types$1.semi || this.canInsertSemicolon() || (this.type !== types$1.star && !this.type.startsExpr)) {\n node.delegate = false;\n node.argument = null;\n } else {\n node.delegate = this.eat(types$1.star);\n node.argument = this.parseMaybeAssign(forInit);\n }\n return this.finishNode(node, \"YieldExpression\")\n};\n\npp$5.parseAwait = function(forInit) {\n if (!this.awaitPos) { this.awaitPos = this.start; }\n\n var node = this.startNode();\n this.next();\n node.argument = this.parseMaybeUnary(null, true, false, forInit);\n return this.finishNode(node, \"AwaitExpression\")\n};\n\nvar pp$4 = Parser.prototype;\n\n// This function is used to raise exceptions on parse errors. It\n// takes an offset integer (into the current `input`) to indicate\n// the location of the error, attaches the position to the end\n// of the error message, and then raises a `SyntaxError` with that\n// message.\n\npp$4.raise = function(pos, message) {\n var loc = getLineInfo(this.input, pos);\n message += \" (\" + loc.line + \":\" + loc.column + \")\";\n var err = new SyntaxError(message);\n err.pos = pos; err.loc = loc; err.raisedAt = this.pos;\n throw err\n};\n\npp$4.raiseRecoverable = pp$4.raise;\n\npp$4.curPosition = function() {\n if (this.options.locations) {\n return new Position(this.curLine, this.pos - this.lineStart)\n }\n};\n\nvar pp$3 = Parser.prototype;\n\nvar Scope = function Scope(flags) {\n this.flags = flags;\n // A list of var-declared names in the current lexical scope\n this.var = [];\n // A list of lexically-declared names in the current lexical scope\n this.lexical = [];\n // A list of lexically-declared FunctionDeclaration names in the current lexical scope\n this.functions = [];\n // A switch to disallow the identifier reference 'arguments'\n this.inClassFieldInit = false;\n};\n\n// The functions in this module keep track of declared variables in the current scope in order to detect duplicate variable names.\n\npp$3.enterScope = function(flags) {\n this.scopeStack.push(new Scope(flags));\n};\n\npp$3.exitScope = function() {\n this.scopeStack.pop();\n};\n\n// The spec says:\n// > At the top level of a function, or script, function declarations are\n// > treated like var declarations rather than like lexical declarations.\npp$3.treatFunctionsAsVarInScope = function(scope) {\n return (scope.flags & SCOPE_FUNCTION) || !this.inModule && (scope.flags & SCOPE_TOP)\n};\n\npp$3.declareName = function(name, bindingType, pos) {\n var redeclared = false;\n if (bindingType === BIND_LEXICAL) {\n var scope = this.currentScope();\n redeclared = scope.lexical.indexOf(name) > -1 || scope.functions.indexOf(name) > -1 || scope.var.indexOf(name) > -1;\n scope.lexical.push(name);\n if (this.inModule && (scope.flags & SCOPE_TOP))\n { delete this.undefinedExports[name]; }\n } else if (bindingType === BIND_SIMPLE_CATCH) {\n var scope$1 = this.currentScope();\n scope$1.lexical.push(name);\n } else if (bindingType === BIND_FUNCTION) {\n var scope$2 = this.currentScope();\n if (this.treatFunctionsAsVar)\n { redeclared = scope$2.lexical.indexOf(name) > -1; }\n else\n { redeclared = scope$2.lexical.indexOf(name) > -1 || scope$2.var.indexOf(name) > -1; }\n scope$2.functions.push(name);\n } else {\n for (var i = this.scopeStack.length - 1; i >= 0; --i) {\n var scope$3 = this.scopeStack[i];\n if (scope$3.lexical.indexOf(name) > -1 && !((scope$3.flags & SCOPE_SIMPLE_CATCH) && scope$3.lexical[0] === name) ||\n !this.treatFunctionsAsVarInScope(scope$3) && scope$3.functions.indexOf(name) > -1) {\n redeclared = true;\n break\n }\n scope$3.var.push(name);\n if (this.inModule && (scope$3.flags & SCOPE_TOP))\n { delete this.undefinedExports[name]; }\n if (scope$3.flags & SCOPE_VAR) { break }\n }\n }\n if (redeclared) { this.raiseRecoverable(pos, (\"Identifier '\" + name + \"' has already been declared\")); }\n};\n\npp$3.checkLocalExport = function(id) {\n // scope.functions must be empty as Module code is always strict.\n if (this.scopeStack[0].lexical.indexOf(id.name) === -1 &&\n this.scopeStack[0].var.indexOf(id.name) === -1) {\n this.undefinedExports[id.name] = id;\n }\n};\n\npp$3.currentScope = function() {\n return this.scopeStack[this.scopeStack.length - 1]\n};\n\npp$3.currentVarScope = function() {\n for (var i = this.scopeStack.length - 1;; i--) {\n var scope = this.scopeStack[i];\n if (scope.flags & SCOPE_VAR) { return scope }\n }\n};\n\n// Could be useful for `this`, `new.target`, `super()`, `super.property`, and `super[property]`.\npp$3.currentThisScope = function() {\n for (var i = this.scopeStack.length - 1;; i--) {\n var scope = this.scopeStack[i];\n if (scope.flags & SCOPE_VAR && !(scope.flags & SCOPE_ARROW)) { return scope }\n }\n};\n\nvar Node = function Node(parser, pos, loc) {\n this.type = \"\";\n this.start = pos;\n this.end = 0;\n if (parser.options.locations)\n { this.loc = new SourceLocation(parser, loc); }\n if (parser.options.directSourceFile)\n { this.sourceFile = parser.options.directSourceFile; }\n if (parser.options.ranges)\n { this.range = [pos, 0]; }\n};\n\n// Start an AST node, attaching a start offset.\n\nvar pp$2 = Parser.prototype;\n\npp$2.startNode = function() {\n return new Node(this, this.start, this.startLoc)\n};\n\npp$2.startNodeAt = function(pos, loc) {\n return new Node(this, pos, loc)\n};\n\n// Finish an AST node, adding `type` and `end` properties.\n\nfunction finishNodeAt(node, type, pos, loc) {\n node.type = type;\n node.end = pos;\n if (this.options.locations)\n { node.loc.end = loc; }\n if (this.options.ranges)\n { node.range[1] = pos; }\n return node\n}\n\npp$2.finishNode = function(node, type) {\n return finishNodeAt.call(this, node, type, this.lastTokEnd, this.lastTokEndLoc)\n};\n\n// Finish node at given position\n\npp$2.finishNodeAt = function(node, type, pos, loc) {\n return finishNodeAt.call(this, node, type, pos, loc)\n};\n\npp$2.copyNode = function(node) {\n var newNode = new Node(this, node.start, this.startLoc);\n for (var prop in node) { newNode[prop] = node[prop]; }\n return newNode\n};\n\n// This file contains Unicode properties extracted from the ECMAScript\n// specification. The lists are extracted like so:\n// $$('#table-binary-unicode-properties > figure > table > tbody > tr > td:nth-child(1) code').map(el => el.innerText)\n\n// #table-binary-unicode-properties\nvar ecma9BinaryProperties = \"ASCII ASCII_Hex_Digit AHex Alphabetic Alpha Any Assigned Bidi_Control Bidi_C Bidi_Mirrored Bidi_M Case_Ignorable CI Cased Changes_When_Casefolded CWCF Changes_When_Casemapped CWCM Changes_When_Lowercased CWL Changes_When_NFKC_Casefolded CWKCF Changes_When_Titlecased CWT Changes_When_Uppercased CWU Dash Default_Ignorable_Code_Point DI Deprecated Dep Diacritic Dia Emoji Emoji_Component Emoji_Modifier Emoji_Modifier_Base Emoji_Presentation Extender Ext Grapheme_Base Gr_Base Grapheme_Extend Gr_Ext Hex_Digit Hex IDS_Binary_Operator IDSB IDS_Trinary_Operator IDST ID_Continue IDC ID_Start IDS Ideographic Ideo Join_Control Join_C Logical_Order_Exception LOE Lowercase Lower Math Noncharacter_Code_Point NChar Pattern_Syntax Pat_Syn Pattern_White_Space Pat_WS Quotation_Mark QMark Radical Regional_Indicator RI Sentence_Terminal STerm Soft_Dotted SD Terminal_Punctuation Term Unified_Ideograph UIdeo Uppercase Upper Variation_Selector VS White_Space space XID_Continue XIDC XID_Start XIDS\";\nvar ecma10BinaryProperties = ecma9BinaryProperties + \" Extended_Pictographic\";\nvar ecma11BinaryProperties = ecma10BinaryProperties;\nvar ecma12BinaryProperties = ecma11BinaryProperties + \" EBase EComp EMod EPres ExtPict\";\nvar ecma13BinaryProperties = ecma12BinaryProperties;\nvar unicodeBinaryProperties = {\n 9: ecma9BinaryProperties,\n 10: ecma10BinaryProperties,\n 11: ecma11BinaryProperties,\n 12: ecma12BinaryProperties,\n 13: ecma13BinaryProperties\n};\n\n// #table-unicode-general-category-values\nvar unicodeGeneralCategoryValues = \"Cased_Letter LC Close_Punctuation Pe Connector_Punctuation Pc Control Cc cntrl Currency_Symbol Sc Dash_Punctuation Pd Decimal_Number Nd digit Enclosing_Mark Me Final_Punctuation Pf Format Cf Initial_Punctuation Pi Letter L Letter_Number Nl Line_Separator Zl Lowercase_Letter Ll Mark M Combining_Mark Math_Symbol Sm Modifier_Letter Lm Modifier_Symbol Sk Nonspacing_Mark Mn Number N Open_Punctuation Ps Other C Other_Letter Lo Other_Number No Other_Punctuation Po Other_Symbol So Paragraph_Separator Zp Private_Use Co Punctuation P punct Separator Z Space_Separator Zs Spacing_Mark Mc Surrogate Cs Symbol S Titlecase_Letter Lt Unassigned Cn Uppercase_Letter Lu\";\n\n// #table-unicode-script-values\nvar ecma9ScriptValues = \"Adlam Adlm Ahom Anatolian_Hieroglyphs Hluw Arabic Arab Armenian Armn Avestan Avst Balinese Bali Bamum Bamu Bassa_Vah Bass Batak Batk Bengali Beng Bhaiksuki Bhks Bopomofo Bopo Brahmi Brah Braille Brai Buginese Bugi Buhid Buhd Canadian_Aboriginal Cans Carian Cari Caucasian_Albanian Aghb Chakma Cakm Cham Cham Cherokee Cher Common Zyyy Coptic Copt Qaac Cuneiform Xsux Cypriot Cprt Cyrillic Cyrl Deseret Dsrt Devanagari Deva Duployan Dupl Egyptian_Hieroglyphs Egyp Elbasan Elba Ethiopic Ethi Georgian Geor Glagolitic Glag Gothic Goth Grantha Gran Greek Grek Gujarati Gujr Gurmukhi Guru Han Hani Hangul Hang Hanunoo Hano Hatran Hatr Hebrew Hebr Hiragana Hira Imperial_Aramaic Armi Inherited Zinh Qaai Inscriptional_Pahlavi Phli Inscriptional_Parthian Prti Javanese Java Kaithi Kthi Kannada Knda Katakana Kana Kayah_Li Kali Kharoshthi Khar Khmer Khmr Khojki Khoj Khudawadi Sind Lao Laoo Latin Latn Lepcha Lepc Limbu Limb Linear_A Lina Linear_B Linb Lisu Lisu Lycian Lyci Lydian Lydi Mahajani Mahj Malayalam Mlym Mandaic Mand Manichaean Mani Marchen Marc Masaram_Gondi Gonm Meetei_Mayek Mtei Mende_Kikakui Mend Meroitic_Cursive Merc Meroitic_Hieroglyphs Mero Miao Plrd Modi Mongolian Mong Mro Mroo Multani Mult Myanmar Mymr Nabataean Nbat New_Tai_Lue Talu Newa Newa Nko Nkoo Nushu Nshu Ogham Ogam Ol_Chiki Olck Old_Hungarian Hung Old_Italic Ital Old_North_Arabian Narb Old_Permic Perm Old_Persian Xpeo Old_South_Arabian Sarb Old_Turkic Orkh Oriya Orya Osage Osge Osmanya Osma Pahawh_Hmong Hmng Palmyrene Palm Pau_Cin_Hau Pauc Phags_Pa Phag Phoenician Phnx Psalter_Pahlavi Phlp Rejang Rjng Runic Runr Samaritan Samr Saurashtra Saur Sharada Shrd Shavian Shaw Siddham Sidd SignWriting Sgnw Sinhala Sinh Sora_Sompeng Sora Soyombo Soyo Sundanese Sund Syloti_Nagri Sylo Syriac Syrc Tagalog Tglg Tagbanwa Tagb Tai_Le Tale Tai_Tham Lana Tai_Viet Tavt Takri Takr Tamil Taml Tangut Tang Telugu Telu Thaana Thaa Thai Thai Tibetan Tibt Tifinagh Tfng Tirhuta Tirh Ugaritic Ugar Vai Vaii Warang_Citi Wara Yi Yiii Zanabazar_Square Zanb\";\nvar ecma10ScriptValues = ecma9ScriptValues + \" Dogra Dogr Gunjala_Gondi Gong Hanifi_Rohingya Rohg Makasar Maka Medefaidrin Medf Old_Sogdian Sogo Sogdian Sogd\";\nvar ecma11ScriptValues = ecma10ScriptValues + \" Elymaic Elym Nandinagari Nand Nyiakeng_Puachue_Hmong Hmnp Wancho Wcho\";\nvar ecma12ScriptValues = ecma11ScriptValues + \" Chorasmian Chrs Diak Dives_Akuru Khitan_Small_Script Kits Yezi Yezidi\";\nvar ecma13ScriptValues = ecma12ScriptValues + \" Cypro_Minoan Cpmn Old_Uyghur Ougr Tangsa Tnsa Toto Vithkuqi Vith\";\nvar unicodeScriptValues = {\n 9: ecma9ScriptValues,\n 10: ecma10ScriptValues,\n 11: ecma11ScriptValues,\n 12: ecma12ScriptValues,\n 13: ecma13ScriptValues\n};\n\nvar data = {};\nfunction buildUnicodeData(ecmaVersion) {\n var d = data[ecmaVersion] = {\n binary: wordsRegexp(unicodeBinaryProperties[ecmaVersion] + \" \" + unicodeGeneralCategoryValues),\n nonBinary: {\n General_Category: wordsRegexp(unicodeGeneralCategoryValues),\n Script: wordsRegexp(unicodeScriptValues[ecmaVersion])\n }\n };\n d.nonBinary.Script_Extensions = d.nonBinary.Script;\n\n d.nonBinary.gc = d.nonBinary.General_Category;\n d.nonBinary.sc = d.nonBinary.Script;\n d.nonBinary.scx = d.nonBinary.Script_Extensions;\n}\n\nfor (var i = 0, list = [9, 10, 11, 12, 13]; i < list.length; i += 1) {\n var ecmaVersion = list[i];\n\n buildUnicodeData(ecmaVersion);\n}\n\nvar pp$1 = Parser.prototype;\n\nvar RegExpValidationState = function RegExpValidationState(parser) {\n this.parser = parser;\n this.validFlags = \"gim\" + (parser.options.ecmaVersion >= 6 ? \"uy\" : \"\") + (parser.options.ecmaVersion >= 9 ? \"s\" : \"\") + (parser.options.ecmaVersion >= 13 ? \"d\" : \"\");\n this.unicodeProperties = data[parser.options.ecmaVersion >= 13 ? 13 : parser.options.ecmaVersion];\n this.source = \"\";\n this.flags = \"\";\n this.start = 0;\n this.switchU = false;\n this.switchN = false;\n this.pos = 0;\n this.lastIntValue = 0;\n this.lastStringValue = \"\";\n this.lastAssertionIsQuantifiable = false;\n this.numCapturingParens = 0;\n this.maxBackReference = 0;\n this.groupNames = [];\n this.backReferenceNames = [];\n};\n\nRegExpValidationState.prototype.reset = function reset (start, pattern, flags) {\n var unicode = flags.indexOf(\"u\") !== -1;\n this.start = start | 0;\n this.source = pattern + \"\";\n this.flags = flags;\n this.switchU = unicode && this.parser.options.ecmaVersion >= 6;\n this.switchN = unicode && this.parser.options.ecmaVersion >= 9;\n};\n\nRegExpValidationState.prototype.raise = function raise (message) {\n this.parser.raiseRecoverable(this.start, (\"Invalid regular expression: /\" + (this.source) + \"/: \" + message));\n};\n\n// If u flag is given, this returns the code point at the index (it combines a surrogate pair).\n// Otherwise, this returns the code unit of the index (can be a part of a surrogate pair).\nRegExpValidationState.prototype.at = function at (i, forceU) {\n if ( forceU === void 0 ) forceU = false;\n\n var s = this.source;\n var l = s.length;\n if (i >= l) {\n return -1\n }\n var c = s.charCodeAt(i);\n if (!(forceU || this.switchU) || c <= 0xD7FF || c >= 0xE000 || i + 1 >= l) {\n return c\n }\n var next = s.charCodeAt(i + 1);\n return next >= 0xDC00 && next <= 0xDFFF ? (c << 10) + next - 0x35FDC00 : c\n};\n\nRegExpValidationState.prototype.nextIndex = function nextIndex (i, forceU) {\n if ( forceU === void 0 ) forceU = false;\n\n var s = this.source;\n var l = s.length;\n if (i >= l) {\n return l\n }\n var c = s.charCodeAt(i), next;\n if (!(forceU || this.switchU) || c <= 0xD7FF || c >= 0xE000 || i + 1 >= l ||\n (next = s.charCodeAt(i + 1)) < 0xDC00 || next > 0xDFFF) {\n return i + 1\n }\n return i + 2\n};\n\nRegExpValidationState.prototype.current = function current (forceU) {\n if ( forceU === void 0 ) forceU = false;\n\n return this.at(this.pos, forceU)\n};\n\nRegExpValidationState.prototype.lookahead = function lookahead (forceU) {\n if ( forceU === void 0 ) forceU = false;\n\n return this.at(this.nextIndex(this.pos, forceU), forceU)\n};\n\nRegExpValidationState.prototype.advance = function advance (forceU) {\n if ( forceU === void 0 ) forceU = false;\n\n this.pos = this.nextIndex(this.pos, forceU);\n};\n\nRegExpValidationState.prototype.eat = function eat (ch, forceU) {\n if ( forceU === void 0 ) forceU = false;\n\n if (this.current(forceU) === ch) {\n this.advance(forceU);\n return true\n }\n return false\n};\n\n/**\n * Validate the flags part of a given RegExpLiteral.\n *\n * @param {RegExpValidationState} state The state to validate RegExp.\n * @returns {void}\n */\npp$1.validateRegExpFlags = function(state) {\n var validFlags = state.validFlags;\n var flags = state.flags;\n\n for (var i = 0; i < flags.length; i++) {\n var flag = flags.charAt(i);\n if (validFlags.indexOf(flag) === -1) {\n this.raise(state.start, \"Invalid regular expression flag\");\n }\n if (flags.indexOf(flag, i + 1) > -1) {\n this.raise(state.start, \"Duplicate regular expression flag\");\n }\n }\n};\n\n/**\n * Validate the pattern part of a given RegExpLiteral.\n *\n * @param {RegExpValidationState} state The state to validate RegExp.\n * @returns {void}\n */\npp$1.validateRegExpPattern = function(state) {\n this.regexp_pattern(state);\n\n // The goal symbol for the parse is |Pattern[~U, ~N]|. If the result of\n // parsing contains a |GroupName|, reparse with the goal symbol\n // |Pattern[~U, +N]| and use this result instead. Throw a *SyntaxError*\n // exception if _P_ did not conform to the grammar, if any elements of _P_\n // were not matched by the parse, or if any Early Error conditions exist.\n if (!state.switchN && this.options.ecmaVersion >= 9 && state.groupNames.length > 0) {\n state.switchN = true;\n this.regexp_pattern(state);\n }\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-Pattern\npp$1.regexp_pattern = function(state) {\n state.pos = 0;\n state.lastIntValue = 0;\n state.lastStringValue = \"\";\n state.lastAssertionIsQuantifiable = false;\n state.numCapturingParens = 0;\n state.maxBackReference = 0;\n state.groupNames.length = 0;\n state.backReferenceNames.length = 0;\n\n this.regexp_disjunction(state);\n\n if (state.pos !== state.source.length) {\n // Make the same messages as V8.\n if (state.eat(0x29 /* ) */)) {\n state.raise(\"Unmatched ')'\");\n }\n if (state.eat(0x5D /* ] */) || state.eat(0x7D /* } */)) {\n state.raise(\"Lone quantifier brackets\");\n }\n }\n if (state.maxBackReference > state.numCapturingParens) {\n state.raise(\"Invalid escape\");\n }\n for (var i = 0, list = state.backReferenceNames; i < list.length; i += 1) {\n var name = list[i];\n\n if (state.groupNames.indexOf(name) === -1) {\n state.raise(\"Invalid named capture referenced\");\n }\n }\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-Disjunction\npp$1.regexp_disjunction = function(state) {\n this.regexp_alternative(state);\n while (state.eat(0x7C /* | */)) {\n this.regexp_alternative(state);\n }\n\n // Make the same message as V8.\n if (this.regexp_eatQuantifier(state, true)) {\n state.raise(\"Nothing to repeat\");\n }\n if (state.eat(0x7B /* { */)) {\n state.raise(\"Lone quantifier brackets\");\n }\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-Alternative\npp$1.regexp_alternative = function(state) {\n while (state.pos < state.source.length && this.regexp_eatTerm(state))\n { }\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-Term\npp$1.regexp_eatTerm = function(state) {\n if (this.regexp_eatAssertion(state)) {\n // Handle `QuantifiableAssertion Quantifier` alternative.\n // `state.lastAssertionIsQuantifiable` is true if the last eaten Assertion\n // is a QuantifiableAssertion.\n if (state.lastAssertionIsQuantifiable && this.regexp_eatQuantifier(state)) {\n // Make the same message as V8.\n if (state.switchU) {\n state.raise(\"Invalid quantifier\");\n }\n }\n return true\n }\n\n if (state.switchU ? this.regexp_eatAtom(state) : this.regexp_eatExtendedAtom(state)) {\n this.regexp_eatQuantifier(state);\n return true\n }\n\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-Assertion\npp$1.regexp_eatAssertion = function(state) {\n var start = state.pos;\n state.lastAssertionIsQuantifiable = false;\n\n // ^, $\n if (state.eat(0x5E /* ^ */) || state.eat(0x24 /* $ */)) {\n return true\n }\n\n // \\b \\B\n if (state.eat(0x5C /* \\ */)) {\n if (state.eat(0x42 /* B */) || state.eat(0x62 /* b */)) {\n return true\n }\n state.pos = start;\n }\n\n // Lookahead / Lookbehind\n if (state.eat(0x28 /* ( */) && state.eat(0x3F /* ? */)) {\n var lookbehind = false;\n if (this.options.ecmaVersion >= 9) {\n lookbehind = state.eat(0x3C /* < */);\n }\n if (state.eat(0x3D /* = */) || state.eat(0x21 /* ! */)) {\n this.regexp_disjunction(state);\n if (!state.eat(0x29 /* ) */)) {\n state.raise(\"Unterminated group\");\n }\n state.lastAssertionIsQuantifiable = !lookbehind;\n return true\n }\n }\n\n state.pos = start;\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-Quantifier\npp$1.regexp_eatQuantifier = function(state, noError) {\n if ( noError === void 0 ) noError = false;\n\n if (this.regexp_eatQuantifierPrefix(state, noError)) {\n state.eat(0x3F /* ? */);\n return true\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-QuantifierPrefix\npp$1.regexp_eatQuantifierPrefix = function(state, noError) {\n return (\n state.eat(0x2A /* * */) ||\n state.eat(0x2B /* + */) ||\n state.eat(0x3F /* ? */) ||\n this.regexp_eatBracedQuantifier(state, noError)\n )\n};\npp$1.regexp_eatBracedQuantifier = function(state, noError) {\n var start = state.pos;\n if (state.eat(0x7B /* { */)) {\n var min = 0, max = -1;\n if (this.regexp_eatDecimalDigits(state)) {\n min = state.lastIntValue;\n if (state.eat(0x2C /* , */) && this.regexp_eatDecimalDigits(state)) {\n max = state.lastIntValue;\n }\n if (state.eat(0x7D /* } */)) {\n // SyntaxError in https://www.ecma-international.org/ecma-262/8.0/#sec-term\n if (max !== -1 && max < min && !noError) {\n state.raise(\"numbers out of order in {} quantifier\");\n }\n return true\n }\n }\n if (state.switchU && !noError) {\n state.raise(\"Incomplete quantifier\");\n }\n state.pos = start;\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-Atom\npp$1.regexp_eatAtom = function(state) {\n return (\n this.regexp_eatPatternCharacters(state) ||\n state.eat(0x2E /* . */) ||\n this.regexp_eatReverseSolidusAtomEscape(state) ||\n this.regexp_eatCharacterClass(state) ||\n this.regexp_eatUncapturingGroup(state) ||\n this.regexp_eatCapturingGroup(state)\n )\n};\npp$1.regexp_eatReverseSolidusAtomEscape = function(state) {\n var start = state.pos;\n if (state.eat(0x5C /* \\ */)) {\n if (this.regexp_eatAtomEscape(state)) {\n return true\n }\n state.pos = start;\n }\n return false\n};\npp$1.regexp_eatUncapturingGroup = function(state) {\n var start = state.pos;\n if (state.eat(0x28 /* ( */)) {\n if (state.eat(0x3F /* ? */) && state.eat(0x3A /* : */)) {\n this.regexp_disjunction(state);\n if (state.eat(0x29 /* ) */)) {\n return true\n }\n state.raise(\"Unterminated group\");\n }\n state.pos = start;\n }\n return false\n};\npp$1.regexp_eatCapturingGroup = function(state) {\n if (state.eat(0x28 /* ( */)) {\n if (this.options.ecmaVersion >= 9) {\n this.regexp_groupSpecifier(state);\n } else if (state.current() === 0x3F /* ? */) {\n state.raise(\"Invalid group\");\n }\n this.regexp_disjunction(state);\n if (state.eat(0x29 /* ) */)) {\n state.numCapturingParens += 1;\n return true\n }\n state.raise(\"Unterminated group\");\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-ExtendedAtom\npp$1.regexp_eatExtendedAtom = function(state) {\n return (\n state.eat(0x2E /* . */) ||\n this.regexp_eatReverseSolidusAtomEscape(state) ||\n this.regexp_eatCharacterClass(state) ||\n this.regexp_eatUncapturingGroup(state) ||\n this.regexp_eatCapturingGroup(state) ||\n this.regexp_eatInvalidBracedQuantifier(state) ||\n this.regexp_eatExtendedPatternCharacter(state)\n )\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-InvalidBracedQuantifier\npp$1.regexp_eatInvalidBracedQuantifier = function(state) {\n if (this.regexp_eatBracedQuantifier(state, true)) {\n state.raise(\"Nothing to repeat\");\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-SyntaxCharacter\npp$1.regexp_eatSyntaxCharacter = function(state) {\n var ch = state.current();\n if (isSyntaxCharacter(ch)) {\n state.lastIntValue = ch;\n state.advance();\n return true\n }\n return false\n};\nfunction isSyntaxCharacter(ch) {\n return (\n ch === 0x24 /* $ */ ||\n ch >= 0x28 /* ( */ && ch <= 0x2B /* + */ ||\n ch === 0x2E /* . */ ||\n ch === 0x3F /* ? */ ||\n ch >= 0x5B /* [ */ && ch <= 0x5E /* ^ */ ||\n ch >= 0x7B /* { */ && ch <= 0x7D /* } */\n )\n}\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-PatternCharacter\n// But eat eager.\npp$1.regexp_eatPatternCharacters = function(state) {\n var start = state.pos;\n var ch = 0;\n while ((ch = state.current()) !== -1 && !isSyntaxCharacter(ch)) {\n state.advance();\n }\n return state.pos !== start\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-ExtendedPatternCharacter\npp$1.regexp_eatExtendedPatternCharacter = function(state) {\n var ch = state.current();\n if (\n ch !== -1 &&\n ch !== 0x24 /* $ */ &&\n !(ch >= 0x28 /* ( */ && ch <= 0x2B /* + */) &&\n ch !== 0x2E /* . */ &&\n ch !== 0x3F /* ? */ &&\n ch !== 0x5B /* [ */ &&\n ch !== 0x5E /* ^ */ &&\n ch !== 0x7C /* | */\n ) {\n state.advance();\n return true\n }\n return false\n};\n\n// GroupSpecifier ::\n// [empty]\n// `?` GroupName\npp$1.regexp_groupSpecifier = function(state) {\n if (state.eat(0x3F /* ? */)) {\n if (this.regexp_eatGroupName(state)) {\n if (state.groupNames.indexOf(state.lastStringValue) !== -1) {\n state.raise(\"Duplicate capture group name\");\n }\n state.groupNames.push(state.lastStringValue);\n return\n }\n state.raise(\"Invalid group\");\n }\n};\n\n// GroupName ::\n// `<` RegExpIdentifierName `>`\n// Note: this updates `state.lastStringValue` property with the eaten name.\npp$1.regexp_eatGroupName = function(state) {\n state.lastStringValue = \"\";\n if (state.eat(0x3C /* < */)) {\n if (this.regexp_eatRegExpIdentifierName(state) && state.eat(0x3E /* > */)) {\n return true\n }\n state.raise(\"Invalid capture group name\");\n }\n return false\n};\n\n// RegExpIdentifierName ::\n// RegExpIdentifierStart\n// RegExpIdentifierName RegExpIdentifierPart\n// Note: this updates `state.lastStringValue` property with the eaten name.\npp$1.regexp_eatRegExpIdentifierName = function(state) {\n state.lastStringValue = \"\";\n if (this.regexp_eatRegExpIdentifierStart(state)) {\n state.lastStringValue += codePointToString(state.lastIntValue);\n while (this.regexp_eatRegExpIdentifierPart(state)) {\n state.lastStringValue += codePointToString(state.lastIntValue);\n }\n return true\n }\n return false\n};\n\n// RegExpIdentifierStart ::\n// UnicodeIDStart\n// `$`\n// `_`\n// `\\` RegExpUnicodeEscapeSequence[+U]\npp$1.regexp_eatRegExpIdentifierStart = function(state) {\n var start = state.pos;\n var forceU = this.options.ecmaVersion >= 11;\n var ch = state.current(forceU);\n state.advance(forceU);\n\n if (ch === 0x5C /* \\ */ && this.regexp_eatRegExpUnicodeEscapeSequence(state, forceU)) {\n ch = state.lastIntValue;\n }\n if (isRegExpIdentifierStart(ch)) {\n state.lastIntValue = ch;\n return true\n }\n\n state.pos = start;\n return false\n};\nfunction isRegExpIdentifierStart(ch) {\n return isIdentifierStart(ch, true) || ch === 0x24 /* $ */ || ch === 0x5F /* _ */\n}\n\n// RegExpIdentifierPart ::\n// UnicodeIDContinue\n// `$`\n// `_`\n// `\\` RegExpUnicodeEscapeSequence[+U]\n// \n// \npp$1.regexp_eatRegExpIdentifierPart = function(state) {\n var start = state.pos;\n var forceU = this.options.ecmaVersion >= 11;\n var ch = state.current(forceU);\n state.advance(forceU);\n\n if (ch === 0x5C /* \\ */ && this.regexp_eatRegExpUnicodeEscapeSequence(state, forceU)) {\n ch = state.lastIntValue;\n }\n if (isRegExpIdentifierPart(ch)) {\n state.lastIntValue = ch;\n return true\n }\n\n state.pos = start;\n return false\n};\nfunction isRegExpIdentifierPart(ch) {\n return isIdentifierChar(ch, true) || ch === 0x24 /* $ */ || ch === 0x5F /* _ */ || ch === 0x200C /* */ || ch === 0x200D /* */\n}\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-AtomEscape\npp$1.regexp_eatAtomEscape = function(state) {\n if (\n this.regexp_eatBackReference(state) ||\n this.regexp_eatCharacterClassEscape(state) ||\n this.regexp_eatCharacterEscape(state) ||\n (state.switchN && this.regexp_eatKGroupName(state))\n ) {\n return true\n }\n if (state.switchU) {\n // Make the same message as V8.\n if (state.current() === 0x63 /* c */) {\n state.raise(\"Invalid unicode escape\");\n }\n state.raise(\"Invalid escape\");\n }\n return false\n};\npp$1.regexp_eatBackReference = function(state) {\n var start = state.pos;\n if (this.regexp_eatDecimalEscape(state)) {\n var n = state.lastIntValue;\n if (state.switchU) {\n // For SyntaxError in https://www.ecma-international.org/ecma-262/8.0/#sec-atomescape\n if (n > state.maxBackReference) {\n state.maxBackReference = n;\n }\n return true\n }\n if (n <= state.numCapturingParens) {\n return true\n }\n state.pos = start;\n }\n return false\n};\npp$1.regexp_eatKGroupName = function(state) {\n if (state.eat(0x6B /* k */)) {\n if (this.regexp_eatGroupName(state)) {\n state.backReferenceNames.push(state.lastStringValue);\n return true\n }\n state.raise(\"Invalid named reference\");\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-CharacterEscape\npp$1.regexp_eatCharacterEscape = function(state) {\n return (\n this.regexp_eatControlEscape(state) ||\n this.regexp_eatCControlLetter(state) ||\n this.regexp_eatZero(state) ||\n this.regexp_eatHexEscapeSequence(state) ||\n this.regexp_eatRegExpUnicodeEscapeSequence(state, false) ||\n (!state.switchU && this.regexp_eatLegacyOctalEscapeSequence(state)) ||\n this.regexp_eatIdentityEscape(state)\n )\n};\npp$1.regexp_eatCControlLetter = function(state) {\n var start = state.pos;\n if (state.eat(0x63 /* c */)) {\n if (this.regexp_eatControlLetter(state)) {\n return true\n }\n state.pos = start;\n }\n return false\n};\npp$1.regexp_eatZero = function(state) {\n if (state.current() === 0x30 /* 0 */ && !isDecimalDigit(state.lookahead())) {\n state.lastIntValue = 0;\n state.advance();\n return true\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-ControlEscape\npp$1.regexp_eatControlEscape = function(state) {\n var ch = state.current();\n if (ch === 0x74 /* t */) {\n state.lastIntValue = 0x09; /* \\t */\n state.advance();\n return true\n }\n if (ch === 0x6E /* n */) {\n state.lastIntValue = 0x0A; /* \\n */\n state.advance();\n return true\n }\n if (ch === 0x76 /* v */) {\n state.lastIntValue = 0x0B; /* \\v */\n state.advance();\n return true\n }\n if (ch === 0x66 /* f */) {\n state.lastIntValue = 0x0C; /* \\f */\n state.advance();\n return true\n }\n if (ch === 0x72 /* r */) {\n state.lastIntValue = 0x0D; /* \\r */\n state.advance();\n return true\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-ControlLetter\npp$1.regexp_eatControlLetter = function(state) {\n var ch = state.current();\n if (isControlLetter(ch)) {\n state.lastIntValue = ch % 0x20;\n state.advance();\n return true\n }\n return false\n};\nfunction isControlLetter(ch) {\n return (\n (ch >= 0x41 /* A */ && ch <= 0x5A /* Z */) ||\n (ch >= 0x61 /* a */ && ch <= 0x7A /* z */)\n )\n}\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-RegExpUnicodeEscapeSequence\npp$1.regexp_eatRegExpUnicodeEscapeSequence = function(state, forceU) {\n if ( forceU === void 0 ) forceU = false;\n\n var start = state.pos;\n var switchU = forceU || state.switchU;\n\n if (state.eat(0x75 /* u */)) {\n if (this.regexp_eatFixedHexDigits(state, 4)) {\n var lead = state.lastIntValue;\n if (switchU && lead >= 0xD800 && lead <= 0xDBFF) {\n var leadSurrogateEnd = state.pos;\n if (state.eat(0x5C /* \\ */) && state.eat(0x75 /* u */) && this.regexp_eatFixedHexDigits(state, 4)) {\n var trail = state.lastIntValue;\n if (trail >= 0xDC00 && trail <= 0xDFFF) {\n state.lastIntValue = (lead - 0xD800) * 0x400 + (trail - 0xDC00) + 0x10000;\n return true\n }\n }\n state.pos = leadSurrogateEnd;\n state.lastIntValue = lead;\n }\n return true\n }\n if (\n switchU &&\n state.eat(0x7B /* { */) &&\n this.regexp_eatHexDigits(state) &&\n state.eat(0x7D /* } */) &&\n isValidUnicode(state.lastIntValue)\n ) {\n return true\n }\n if (switchU) {\n state.raise(\"Invalid unicode escape\");\n }\n state.pos = start;\n }\n\n return false\n};\nfunction isValidUnicode(ch) {\n return ch >= 0 && ch <= 0x10FFFF\n}\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-IdentityEscape\npp$1.regexp_eatIdentityEscape = function(state) {\n if (state.switchU) {\n if (this.regexp_eatSyntaxCharacter(state)) {\n return true\n }\n if (state.eat(0x2F /* / */)) {\n state.lastIntValue = 0x2F; /* / */\n return true\n }\n return false\n }\n\n var ch = state.current();\n if (ch !== 0x63 /* c */ && (!state.switchN || ch !== 0x6B /* k */)) {\n state.lastIntValue = ch;\n state.advance();\n return true\n }\n\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-DecimalEscape\npp$1.regexp_eatDecimalEscape = function(state) {\n state.lastIntValue = 0;\n var ch = state.current();\n if (ch >= 0x31 /* 1 */ && ch <= 0x39 /* 9 */) {\n do {\n state.lastIntValue = 10 * state.lastIntValue + (ch - 0x30 /* 0 */);\n state.advance();\n } while ((ch = state.current()) >= 0x30 /* 0 */ && ch <= 0x39 /* 9 */)\n return true\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-CharacterClassEscape\npp$1.regexp_eatCharacterClassEscape = function(state) {\n var ch = state.current();\n\n if (isCharacterClassEscape(ch)) {\n state.lastIntValue = -1;\n state.advance();\n return true\n }\n\n if (\n state.switchU &&\n this.options.ecmaVersion >= 9 &&\n (ch === 0x50 /* P */ || ch === 0x70 /* p */)\n ) {\n state.lastIntValue = -1;\n state.advance();\n if (\n state.eat(0x7B /* { */) &&\n this.regexp_eatUnicodePropertyValueExpression(state) &&\n state.eat(0x7D /* } */)\n ) {\n return true\n }\n state.raise(\"Invalid property name\");\n }\n\n return false\n};\nfunction isCharacterClassEscape(ch) {\n return (\n ch === 0x64 /* d */ ||\n ch === 0x44 /* D */ ||\n ch === 0x73 /* s */ ||\n ch === 0x53 /* S */ ||\n ch === 0x77 /* w */ ||\n ch === 0x57 /* W */\n )\n}\n\n// UnicodePropertyValueExpression ::\n// UnicodePropertyName `=` UnicodePropertyValue\n// LoneUnicodePropertyNameOrValue\npp$1.regexp_eatUnicodePropertyValueExpression = function(state) {\n var start = state.pos;\n\n // UnicodePropertyName `=` UnicodePropertyValue\n if (this.regexp_eatUnicodePropertyName(state) && state.eat(0x3D /* = */)) {\n var name = state.lastStringValue;\n if (this.regexp_eatUnicodePropertyValue(state)) {\n var value = state.lastStringValue;\n this.regexp_validateUnicodePropertyNameAndValue(state, name, value);\n return true\n }\n }\n state.pos = start;\n\n // LoneUnicodePropertyNameOrValue\n if (this.regexp_eatLoneUnicodePropertyNameOrValue(state)) {\n var nameOrValue = state.lastStringValue;\n this.regexp_validateUnicodePropertyNameOrValue(state, nameOrValue);\n return true\n }\n return false\n};\npp$1.regexp_validateUnicodePropertyNameAndValue = function(state, name, value) {\n if (!hasOwn(state.unicodeProperties.nonBinary, name))\n { state.raise(\"Invalid property name\"); }\n if (!state.unicodeProperties.nonBinary[name].test(value))\n { state.raise(\"Invalid property value\"); }\n};\npp$1.regexp_validateUnicodePropertyNameOrValue = function(state, nameOrValue) {\n if (!state.unicodeProperties.binary.test(nameOrValue))\n { state.raise(\"Invalid property name\"); }\n};\n\n// UnicodePropertyName ::\n// UnicodePropertyNameCharacters\npp$1.regexp_eatUnicodePropertyName = function(state) {\n var ch = 0;\n state.lastStringValue = \"\";\n while (isUnicodePropertyNameCharacter(ch = state.current())) {\n state.lastStringValue += codePointToString(ch);\n state.advance();\n }\n return state.lastStringValue !== \"\"\n};\nfunction isUnicodePropertyNameCharacter(ch) {\n return isControlLetter(ch) || ch === 0x5F /* _ */\n}\n\n// UnicodePropertyValue ::\n// UnicodePropertyValueCharacters\npp$1.regexp_eatUnicodePropertyValue = function(state) {\n var ch = 0;\n state.lastStringValue = \"\";\n while (isUnicodePropertyValueCharacter(ch = state.current())) {\n state.lastStringValue += codePointToString(ch);\n state.advance();\n }\n return state.lastStringValue !== \"\"\n};\nfunction isUnicodePropertyValueCharacter(ch) {\n return isUnicodePropertyNameCharacter(ch) || isDecimalDigit(ch)\n}\n\n// LoneUnicodePropertyNameOrValue ::\n// UnicodePropertyValueCharacters\npp$1.regexp_eatLoneUnicodePropertyNameOrValue = function(state) {\n return this.regexp_eatUnicodePropertyValue(state)\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-CharacterClass\npp$1.regexp_eatCharacterClass = function(state) {\n if (state.eat(0x5B /* [ */)) {\n state.eat(0x5E /* ^ */);\n this.regexp_classRanges(state);\n if (state.eat(0x5D /* ] */)) {\n return true\n }\n // Unreachable since it threw \"unterminated regular expression\" error before.\n state.raise(\"Unterminated character class\");\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-ClassRanges\n// https://www.ecma-international.org/ecma-262/8.0/#prod-NonemptyClassRanges\n// https://www.ecma-international.org/ecma-262/8.0/#prod-NonemptyClassRangesNoDash\npp$1.regexp_classRanges = function(state) {\n while (this.regexp_eatClassAtom(state)) {\n var left = state.lastIntValue;\n if (state.eat(0x2D /* - */) && this.regexp_eatClassAtom(state)) {\n var right = state.lastIntValue;\n if (state.switchU && (left === -1 || right === -1)) {\n state.raise(\"Invalid character class\");\n }\n if (left !== -1 && right !== -1 && left > right) {\n state.raise(\"Range out of order in character class\");\n }\n }\n }\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-ClassAtom\n// https://www.ecma-international.org/ecma-262/8.0/#prod-ClassAtomNoDash\npp$1.regexp_eatClassAtom = function(state) {\n var start = state.pos;\n\n if (state.eat(0x5C /* \\ */)) {\n if (this.regexp_eatClassEscape(state)) {\n return true\n }\n if (state.switchU) {\n // Make the same message as V8.\n var ch$1 = state.current();\n if (ch$1 === 0x63 /* c */ || isOctalDigit(ch$1)) {\n state.raise(\"Invalid class escape\");\n }\n state.raise(\"Invalid escape\");\n }\n state.pos = start;\n }\n\n var ch = state.current();\n if (ch !== 0x5D /* ] */) {\n state.lastIntValue = ch;\n state.advance();\n return true\n }\n\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-ClassEscape\npp$1.regexp_eatClassEscape = function(state) {\n var start = state.pos;\n\n if (state.eat(0x62 /* b */)) {\n state.lastIntValue = 0x08; /* */\n return true\n }\n\n if (state.switchU && state.eat(0x2D /* - */)) {\n state.lastIntValue = 0x2D; /* - */\n return true\n }\n\n if (!state.switchU && state.eat(0x63 /* c */)) {\n if (this.regexp_eatClassControlLetter(state)) {\n return true\n }\n state.pos = start;\n }\n\n return (\n this.regexp_eatCharacterClassEscape(state) ||\n this.regexp_eatCharacterEscape(state)\n )\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-ClassControlLetter\npp$1.regexp_eatClassControlLetter = function(state) {\n var ch = state.current();\n if (isDecimalDigit(ch) || ch === 0x5F /* _ */) {\n state.lastIntValue = ch % 0x20;\n state.advance();\n return true\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-HexEscapeSequence\npp$1.regexp_eatHexEscapeSequence = function(state) {\n var start = state.pos;\n if (state.eat(0x78 /* x */)) {\n if (this.regexp_eatFixedHexDigits(state, 2)) {\n return true\n }\n if (state.switchU) {\n state.raise(\"Invalid escape\");\n }\n state.pos = start;\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-DecimalDigits\npp$1.regexp_eatDecimalDigits = function(state) {\n var start = state.pos;\n var ch = 0;\n state.lastIntValue = 0;\n while (isDecimalDigit(ch = state.current())) {\n state.lastIntValue = 10 * state.lastIntValue + (ch - 0x30 /* 0 */);\n state.advance();\n }\n return state.pos !== start\n};\nfunction isDecimalDigit(ch) {\n return ch >= 0x30 /* 0 */ && ch <= 0x39 /* 9 */\n}\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-HexDigits\npp$1.regexp_eatHexDigits = function(state) {\n var start = state.pos;\n var ch = 0;\n state.lastIntValue = 0;\n while (isHexDigit(ch = state.current())) {\n state.lastIntValue = 16 * state.lastIntValue + hexToInt(ch);\n state.advance();\n }\n return state.pos !== start\n};\nfunction isHexDigit(ch) {\n return (\n (ch >= 0x30 /* 0 */ && ch <= 0x39 /* 9 */) ||\n (ch >= 0x41 /* A */ && ch <= 0x46 /* F */) ||\n (ch >= 0x61 /* a */ && ch <= 0x66 /* f */)\n )\n}\nfunction hexToInt(ch) {\n if (ch >= 0x41 /* A */ && ch <= 0x46 /* F */) {\n return 10 + (ch - 0x41 /* A */)\n }\n if (ch >= 0x61 /* a */ && ch <= 0x66 /* f */) {\n return 10 + (ch - 0x61 /* a */)\n }\n return ch - 0x30 /* 0 */\n}\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-annexB-LegacyOctalEscapeSequence\n// Allows only 0-377(octal) i.e. 0-255(decimal).\npp$1.regexp_eatLegacyOctalEscapeSequence = function(state) {\n if (this.regexp_eatOctalDigit(state)) {\n var n1 = state.lastIntValue;\n if (this.regexp_eatOctalDigit(state)) {\n var n2 = state.lastIntValue;\n if (n1 <= 3 && this.regexp_eatOctalDigit(state)) {\n state.lastIntValue = n1 * 64 + n2 * 8 + state.lastIntValue;\n } else {\n state.lastIntValue = n1 * 8 + n2;\n }\n } else {\n state.lastIntValue = n1;\n }\n return true\n }\n return false\n};\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-OctalDigit\npp$1.regexp_eatOctalDigit = function(state) {\n var ch = state.current();\n if (isOctalDigit(ch)) {\n state.lastIntValue = ch - 0x30; /* 0 */\n state.advance();\n return true\n }\n state.lastIntValue = 0;\n return false\n};\nfunction isOctalDigit(ch) {\n return ch >= 0x30 /* 0 */ && ch <= 0x37 /* 7 */\n}\n\n// https://www.ecma-international.org/ecma-262/8.0/#prod-Hex4Digits\n// https://www.ecma-international.org/ecma-262/8.0/#prod-HexDigit\n// And HexDigit HexDigit in https://www.ecma-international.org/ecma-262/8.0/#prod-HexEscapeSequence\npp$1.regexp_eatFixedHexDigits = function(state, length) {\n var start = state.pos;\n state.lastIntValue = 0;\n for (var i = 0; i < length; ++i) {\n var ch = state.current();\n if (!isHexDigit(ch)) {\n state.pos = start;\n return false\n }\n state.lastIntValue = 16 * state.lastIntValue + hexToInt(ch);\n state.advance();\n }\n return true\n};\n\n// Object type used to represent tokens. Note that normally, tokens\n// simply exist as properties on the parser object. This is only\n// used for the onToken callback and the external tokenizer.\n\nvar Token = function Token(p) {\n this.type = p.type;\n this.value = p.value;\n this.start = p.start;\n this.end = p.end;\n if (p.options.locations)\n { this.loc = new SourceLocation(p, p.startLoc, p.endLoc); }\n if (p.options.ranges)\n { this.range = [p.start, p.end]; }\n};\n\n// ## Tokenizer\n\nvar pp = Parser.prototype;\n\n// Move to the next token\n\npp.next = function(ignoreEscapeSequenceInKeyword) {\n if (!ignoreEscapeSequenceInKeyword && this.type.keyword && this.containsEsc)\n { this.raiseRecoverable(this.start, \"Escape sequence in keyword \" + this.type.keyword); }\n if (this.options.onToken)\n { this.options.onToken(new Token(this)); }\n\n this.lastTokEnd = this.end;\n this.lastTokStart = this.start;\n this.lastTokEndLoc = this.endLoc;\n this.lastTokStartLoc = this.startLoc;\n this.nextToken();\n};\n\npp.getToken = function() {\n this.next();\n return new Token(this)\n};\n\n// If we're in an ES6 environment, make parsers iterable\nif (typeof Symbol !== \"undefined\")\n { pp[Symbol.iterator] = function() {\n var this$1$1 = this;\n\n return {\n next: function () {\n var token = this$1$1.getToken();\n return {\n done: token.type === types$1.eof,\n value: token\n }\n }\n }\n }; }\n\n// Toggle strict mode. Re-reads the next number or string to please\n// pedantic tests (`\"use strict\"; 010;` should fail).\n\n// Read a single token, updating the parser object's token-related\n// properties.\n\npp.nextToken = function() {\n var curContext = this.curContext();\n if (!curContext || !curContext.preserveSpace) { this.skipSpace(); }\n\n this.start = this.pos;\n if (this.options.locations) { this.startLoc = this.curPosition(); }\n if (this.pos >= this.input.length) { return this.finishToken(types$1.eof) }\n\n if (curContext.override) { return curContext.override(this) }\n else { this.readToken(this.fullCharCodeAtPos()); }\n};\n\npp.readToken = function(code) {\n // Identifier or keyword. '\\uXXXX' sequences are allowed in\n // identifiers, so '\\' also dispatches to that.\n if (isIdentifierStart(code, this.options.ecmaVersion >= 6) || code === 92 /* '\\' */)\n { return this.readWord() }\n\n return this.getTokenFromCode(code)\n};\n\npp.fullCharCodeAtPos = function() {\n var code = this.input.charCodeAt(this.pos);\n if (code <= 0xd7ff || code >= 0xdc00) { return code }\n var next = this.input.charCodeAt(this.pos + 1);\n return next <= 0xdbff || next >= 0xe000 ? code : (code << 10) + next - 0x35fdc00\n};\n\npp.skipBlockComment = function() {\n var startLoc = this.options.onComment && this.curPosition();\n var start = this.pos, end = this.input.indexOf(\"*/\", this.pos += 2);\n if (end === -1) { this.raise(this.pos - 2, \"Unterminated comment\"); }\n this.pos = end + 2;\n if (this.options.locations) {\n for (var nextBreak = (void 0), pos = start; (nextBreak = nextLineBreak(this.input, pos, this.pos)) > -1;) {\n ++this.curLine;\n pos = this.lineStart = nextBreak;\n }\n }\n if (this.options.onComment)\n { this.options.onComment(true, this.input.slice(start + 2, end), start, this.pos,\n startLoc, this.curPosition()); }\n};\n\npp.skipLineComment = function(startSkip) {\n var start = this.pos;\n var startLoc = this.options.onComment && this.curPosition();\n var ch = this.input.charCodeAt(this.pos += startSkip);\n while (this.pos < this.input.length && !isNewLine(ch)) {\n ch = this.input.charCodeAt(++this.pos);\n }\n if (this.options.onComment)\n { this.options.onComment(false, this.input.slice(start + startSkip, this.pos), start, this.pos,\n startLoc, this.curPosition()); }\n};\n\n// Called at the start of the parse and after every token. Skips\n// whitespace and comments, and.\n\npp.skipSpace = function() {\n loop: while (this.pos < this.input.length) {\n var ch = this.input.charCodeAt(this.pos);\n switch (ch) {\n case 32: case 160: // ' '\n ++this.pos;\n break\n case 13:\n if (this.input.charCodeAt(this.pos + 1) === 10) {\n ++this.pos;\n }\n case 10: case 8232: case 8233:\n ++this.pos;\n if (this.options.locations) {\n ++this.curLine;\n this.lineStart = this.pos;\n }\n break\n case 47: // '/'\n switch (this.input.charCodeAt(this.pos + 1)) {\n case 42: // '*'\n this.skipBlockComment();\n break\n case 47:\n this.skipLineComment(2);\n break\n default:\n break loop\n }\n break\n default:\n if (ch > 8 && ch < 14 || ch >= 5760 && nonASCIIwhitespace.test(String.fromCharCode(ch))) {\n ++this.pos;\n } else {\n break loop\n }\n }\n }\n};\n\n// Called at the end of every token. Sets `end`, `val`, and\n// maintains `context` and `exprAllowed`, and skips the space after\n// the token, so that the next one's `start` will point at the\n// right position.\n\npp.finishToken = function(type, val) {\n this.end = this.pos;\n if (this.options.locations) { this.endLoc = this.curPosition(); }\n var prevType = this.type;\n this.type = type;\n this.value = val;\n\n this.updateContext(prevType);\n};\n\n// ### Token reading\n\n// This is the function that is called to fetch the next token. It\n// is somewhat obscure, because it works in character codes rather\n// than characters, and because operator parsing has been inlined\n// into it.\n//\n// All in the name of speed.\n//\npp.readToken_dot = function() {\n var next = this.input.charCodeAt(this.pos + 1);\n if (next >= 48 && next <= 57) { return this.readNumber(true) }\n var next2 = this.input.charCodeAt(this.pos + 2);\n if (this.options.ecmaVersion >= 6 && next === 46 && next2 === 46) { // 46 = dot '.'\n this.pos += 3;\n return this.finishToken(types$1.ellipsis)\n } else {\n ++this.pos;\n return this.finishToken(types$1.dot)\n }\n};\n\npp.readToken_slash = function() { // '/'\n var next = this.input.charCodeAt(this.pos + 1);\n if (this.exprAllowed) { ++this.pos; return this.readRegexp() }\n if (next === 61) { return this.finishOp(types$1.assign, 2) }\n return this.finishOp(types$1.slash, 1)\n};\n\npp.readToken_mult_modulo_exp = function(code) { // '%*'\n var next = this.input.charCodeAt(this.pos + 1);\n var size = 1;\n var tokentype = code === 42 ? types$1.star : types$1.modulo;\n\n // exponentiation operator ** and **=\n if (this.options.ecmaVersion >= 7 && code === 42 && next === 42) {\n ++size;\n tokentype = types$1.starstar;\n next = this.input.charCodeAt(this.pos + 2);\n }\n\n if (next === 61) { return this.finishOp(types$1.assign, size + 1) }\n return this.finishOp(tokentype, size)\n};\n\npp.readToken_pipe_amp = function(code) { // '|&'\n var next = this.input.charCodeAt(this.pos + 1);\n if (next === code) {\n if (this.options.ecmaVersion >= 12) {\n var next2 = this.input.charCodeAt(this.pos + 2);\n if (next2 === 61) { return this.finishOp(types$1.assign, 3) }\n }\n return this.finishOp(code === 124 ? types$1.logicalOR : types$1.logicalAND, 2)\n }\n if (next === 61) { return this.finishOp(types$1.assign, 2) }\n return this.finishOp(code === 124 ? types$1.bitwiseOR : types$1.bitwiseAND, 1)\n};\n\npp.readToken_caret = function() { // '^'\n var next = this.input.charCodeAt(this.pos + 1);\n if (next === 61) { return this.finishOp(types$1.assign, 2) }\n return this.finishOp(types$1.bitwiseXOR, 1)\n};\n\npp.readToken_plus_min = function(code) { // '+-'\n var next = this.input.charCodeAt(this.pos + 1);\n if (next === code) {\n if (next === 45 && !this.inModule && this.input.charCodeAt(this.pos + 2) === 62 &&\n (this.lastTokEnd === 0 || lineBreak.test(this.input.slice(this.lastTokEnd, this.pos)))) {\n // A `-->` line comment\n this.skipLineComment(3);\n this.skipSpace();\n return this.nextToken()\n }\n return this.finishOp(types$1.incDec, 2)\n }\n if (next === 61) { return this.finishOp(types$1.assign, 2) }\n return this.finishOp(types$1.plusMin, 1)\n};\n\npp.readToken_lt_gt = function(code) { // '<>'\n var next = this.input.charCodeAt(this.pos + 1);\n var size = 1;\n if (next === code) {\n size = code === 62 && this.input.charCodeAt(this.pos + 2) === 62 ? 3 : 2;\n if (this.input.charCodeAt(this.pos + size) === 61) { return this.finishOp(types$1.assign, size + 1) }\n return this.finishOp(types$1.bitShift, size)\n }\n if (next === 33 && code === 60 && !this.inModule && this.input.charCodeAt(this.pos + 2) === 45 &&\n this.input.charCodeAt(this.pos + 3) === 45) {\n // `