@serverless-devs/s 2.1.7 → 2.1.8-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/clean/index.js +19 -33
- package/lib/cli/index.js +21 -35
- package/lib/component/index.js +33 -47
- package/lib/config/add/index.js +28 -42
- package/lib/config/delete/index.js +22 -36
- package/lib/config/get/index.js +30 -44
- package/lib/config/index.js +70 -21
- package/lib/config/rename/index.js +22 -36
- package/lib/edit/index.js +26 -40
- package/lib/error/human-error.js +1 -1
- package/lib/error/index.js +1 -1
- package/lib/help/index.js +1 -1
- package/lib/index.js +238 -103
- package/lib/init/index.js +48 -62
- package/lib/init/init-config.js +1 -1
- package/lib/init/init-manager.js +4 -4
- package/lib/onboarding/index.js +1 -1
- package/lib/set/analysis/index.js +24 -38
- package/lib/set/index.js +61 -22
- package/lib/set/locale/index.js +24 -38
- package/lib/set/proxy/index.js +27 -41
- package/lib/set/registry/index.js +28 -42
- package/lib/set/workspace/index.js +24 -38
- package/lib/special-commad/index.js +1 -1
- package/lib/update-notifier/index.js +1 -1
- package/lib/utils/common.js +1 -1
- package/lib/utils/handler-set-config.js +1 -1
- package/lib/verify/index.js +28 -42
- package/package.json +6 -4
- package/s-2.1.8-beta.2-linux +0 -0
- package/s-2.1.8-beta.2-linux.zip +0 -0
- package/s-2.1.8-beta.2-macos +0 -0
- package/s-2.1.8-beta.2-macos.zip +0 -0
- package/s-2.1.8-beta.2-win.exe +0 -0
- package/s-2.1.8-beta.2-win.exe.zip +0 -0
- package/{shell → script}/postbuild.sh +0 -0
- package/bin/s-clean +0 -2
- package/bin/s-cli +0 -2
- package/bin/s-component +0 -2
- package/bin/s-config +0 -2
- package/bin/s-config-add +0 -2
- package/bin/s-config-delete +0 -2
- package/bin/s-config-get +0 -2
- package/bin/s-config-rename +0 -2
- package/bin/s-edit +0 -2
- package/bin/s-init +0 -2
- package/bin/s-set +0 -2
- package/bin/s-set-analysis +0 -2
- package/bin/s-set-proxy +0 -2
- package/bin/s-set-registry +0 -2
- package/bin/s-set-workspace +0 -2
- package/bin/s-verify +0 -2
package/lib/verify/index.js
CHANGED
|
@@ -1,56 +1,42 @@
|
|
|
1
|
-
"use strict";var _=(r,e)=>()=>(e||r((e={exports:{}}).exports,e),e.exports);var ko=_((Lt,jo)=>{var ph=require("events").EventEmitter,Gs=require("child_process").spawn,xt=require("path"),zs=require("fs"),Br=class{constructor(e,t){this.flags=e,this.required=e.includes("<"),this.optional=e.includes("["),this.variadic=/\w\.\.\.[>\]]$/.test(e),this.mandatory=!1;let n=Do(e);this.short=n.shortFlag,this.long=n.longFlag,this.negate=!1,this.long&&(this.negate=this.long.startsWith("--no-")),this.description=t||"",this.defaultValue=void 0}name(){return this.long?this.long.replace(/^--/,""):this.short.replace(/^-/,"")}attributeName(){return mh(this.name().replace(/^no-/,""))}is(e){return this.short===e||this.long===e}},fr=class extends Error{constructor(e,t,n){super(n),Error.captureStackTrace(this,this.constructor),this.name=this.constructor.name,this.code=t,this.exitCode=e,this.nestedError=void 0}},dr=class extends ph{constructor(e){super(),this.commands=[],this.options=[],this.parent=null,this._allowUnknownOption=!1,this._args=[],this.rawArgs=null,this._scriptPath=null,this._name=e||"",this._optionValues={},this._storeOptionsAsProperties=!0,this._storeOptionsAsPropertiesCalled=!1,this._passCommandToAction=!0,this._actionResults=[],this._actionHandler=null,this._executableHandler=!1,this._executableFile=null,this._defaultCommandName=null,this._exitCallback=null,this._aliases=[],this._combineFlagAndOptionalValue=!0,this._hidden=!1,this._hasHelpOption=!0,this._helpFlags="-h, --help",this._helpDescription="display help for command",this._helpShortFlag="-h",this._helpLongFlag="--help",this._hasImplicitHelpCommand=void 0,this._helpCommandName="help",this._helpCommandnameAndArgs="help [command]",this._helpCommandDescription="display help for command"}command(e,t,n){let s=t,i=n;typeof s=="object"&&s!==null&&(i=s,s=null),i=i||{};let a=e.split(/ +/),c=this.createCommand(a.shift());return s&&(c.description(s),c._executableHandler=!0),i.isDefault&&(this._defaultCommandName=c._name),c._hidden=!!(i.noHelp||i.hidden),c._hasHelpOption=this._hasHelpOption,c._helpFlags=this._helpFlags,c._helpDescription=this._helpDescription,c._helpShortFlag=this._helpShortFlag,c._helpLongFlag=this._helpLongFlag,c._helpCommandName=this._helpCommandName,c._helpCommandnameAndArgs=this._helpCommandnameAndArgs,c._helpCommandDescription=this._helpCommandDescription,c._exitCallback=this._exitCallback,c._storeOptionsAsProperties=this._storeOptionsAsProperties,c._passCommandToAction=this._passCommandToAction,c._combineFlagAndOptionalValue=this._combineFlagAndOptionalValue,c._executableFile=i.executableFile||null,this.commands.push(c),c._parseExpectedArgs(a),c.parent=this,s?this:c}createCommand(e){return new dr(e)}addCommand(e,t){if(!e._name)throw new Error("Command passed to .addCommand() must have a name");function n(s){s.forEach(i=>{if(i._executableHandler&&!i._executableFile)throw new Error(`Must specify executableFile for deeply nested executable: ${i.name()}`);n(i.commands)})}return n(e.commands),t=t||{},t.isDefault&&(this._defaultCommandName=e._name),(t.noHelp||t.hidden)&&(e._hidden=!0),this.commands.push(e),e.parent=this,this}arguments(e){return this._parseExpectedArgs(e.split(/ +/))}addHelpCommand(e,t){return e===!1?this._hasImplicitHelpCommand=!1:(this._hasImplicitHelpCommand=!0,typeof e=="string"&&(this._helpCommandName=e.split(" ")[0],this._helpCommandnameAndArgs=e),this._helpCommandDescription=t||this._helpCommandDescription),this}_lazyHasImplicitHelpCommand(){return this._hasImplicitHelpCommand===void 0&&(this._hasImplicitHelpCommand=this.commands.length&&!this._actionHandler&&!this._findCommand("help")),this._hasImplicitHelpCommand}_parseExpectedArgs(e){if(!!e.length)return e.forEach(t=>{let n={required:!1,name:"",variadic:!1};switch(t[0]){case"<":n.required=!0,n.name=t.slice(1,-1);break;case"[":n.name=t.slice(1,-1);break}n.name.length>3&&n.name.slice(-3)==="..."&&(n.variadic=!0,n.name=n.name.slice(0,-3)),n.name&&this._args.push(n)}),this._args.forEach((t,n)=>{if(t.variadic&&n<this._args.length-1)throw new Error(`only the last argument can be variadic '${t.name}'`)}),this}exitOverride(e){return e?this._exitCallback=e:this._exitCallback=t=>{if(t.code!=="commander.executeSubCommandAsync")throw t},this}_exit(e,t,n){this._exitCallback&&this._exitCallback(new fr(e,t,n)),process.exit(e)}action(e){let t=n=>{let s=this._args.length,i=n.slice(0,s);this._passCommandToAction?i[s]=this:i[s]=this.opts(),n.length>s&&i.push(n.slice(s));let a=e.apply(this,i),c=this;for(;c.parent;)c=c.parent;c._actionResults.push(a)};return this._actionHandler=t,this}_checkForOptionNameClash(e){if(!this._storeOptionsAsProperties||this._storeOptionsAsPropertiesCalled||e.name()==="help"||this._getOptionValue(e.attributeName())===void 0)return;let n=!0;if(e.negate){let s=e.long.replace(/^--no-/,"--");n=!this._findOption(s)}else if(e.long){let s=e.long.replace(/^--/,"--no-");n=!this._findOption(s)}if(n)throw new Error(`option '${e.name()}' clashes with existing property '${e.attributeName()}' on Command
|
|
2
|
-
- call storeOptionsAsProperties(false) to store option values safely,
|
|
3
|
-
- or call storeOptionsAsProperties(true) to suppress this check,
|
|
4
|
-
- or change option name
|
|
5
|
-
|
|
6
|
-
Read more on https://git.io/JJc0W`)}_optionEx(e,t,n,s,i){let a=new Br(t,n),c=a.name(),u=a.attributeName();if(a.mandatory=!!e.mandatory,this._checkForOptionNameClash(a),typeof s!="function")if(s instanceof RegExp){let o=s;s=(l,d)=>{let y=o.exec(l);return y?y[0]:d}}else i=s,s=null;if(a.negate||a.optional||a.required||typeof i=="boolean"){if(a.negate){let o=a.long.replace(/^--no-/,"--");i=this._findOption(o)?this._getOptionValue(u):!0}i!==void 0&&(this._setOptionValue(u,i),a.defaultValue=i)}return this.options.push(a),this.on("option:"+c,o=>{let l=this._getOptionValue(u);o!==null&&s?o=s(o,l===void 0?i:l):o!==null&&a.variadic&&(l===i||!Array.isArray(l)?o=[o]:o=l.concat(o)),typeof l=="boolean"||typeof l>"u"?o==null?this._setOptionValue(u,a.negate?!1:i||!0):this._setOptionValue(u,o):o!==null&&this._setOptionValue(u,a.negate?!1:o)}),this}option(e,t,n,s){return this._optionEx({},e,t,n,s)}requiredOption(e,t,n,s){return this._optionEx({mandatory:!0},e,t,n,s)}combineFlagAndOptionalValue(e){return this._combineFlagAndOptionalValue=e===void 0||e,this}allowUnknownOption(e){return this._allowUnknownOption=e===void 0||e,this}storeOptionsAsProperties(e){if(this._storeOptionsAsPropertiesCalled=!0,this._storeOptionsAsProperties=e===void 0||e,this.options.length)throw new Error("call .storeOptionsAsProperties() before adding options");return this}passCommandToAction(e){return this._passCommandToAction=e===void 0||e,this}_setOptionValue(e,t){this._storeOptionsAsProperties?this[e]=t:this._optionValues[e]=t}_getOptionValue(e){return this._storeOptionsAsProperties?this[e]:this._optionValues[e]}parse(e,t){if(e!==void 0&&!Array.isArray(e))throw new Error("first parameter to parse must be array or undefined");t=t||{},e===void 0&&(e=process.argv,process.versions&&process.versions.electron&&(t.from="electron")),this.rawArgs=e.slice();let n;switch(t.from){case void 0:case"node":this._scriptPath=e[1],n=e.slice(2);break;case"electron":process.defaultApp?(this._scriptPath=e[1],n=e.slice(2)):n=e.slice(1);break;case"user":n=e.slice(0);break;default:throw new Error(`unexpected parse option { from: '${t.from}' }`)}return!this._scriptPath&&process.mainModule&&(this._scriptPath=process.mainModule.filename),this._name=this._name||this._scriptPath&&xt.basename(this._scriptPath,xt.extname(this._scriptPath)),this._parseCommand([],n),this}parseAsync(e,t){return this.parse(e,t),Promise.all(this._actionResults).then(()=>this)}_executeSubCommand(e,t){t=t.slice();let n=!1,s=[".js",".ts",".tsx",".mjs"];this._checkForMissingMandatoryOptions();let i=this._scriptPath;!i&&process.mainModule&&(i=process.mainModule.filename);let a;try{let y=zs.realpathSync(i);a=xt.dirname(y)}catch{a="."}let c=xt.basename(i,xt.extname(i))+"-"+e._name;e._executableFile&&(c=e._executableFile);let u=xt.join(a,c);zs.existsSync(u)?c=u:s.forEach(y=>{zs.existsSync(`${u}${y}`)&&(c=`${u}${y}`)}),n=s.includes(xt.extname(c));let o;process.platform!=="win32"?n?(t.unshift(c),t=Ao(process.execArgv).concat(t),o=Gs(process.argv[0],t,{stdio:"inherit"})):o=Gs(c,t,{stdio:"inherit"}):(t.unshift(c),t=Ao(process.execArgv).concat(t),o=Gs(process.execPath,t,{stdio:"inherit"})),["SIGUSR1","SIGUSR2","SIGTERM","SIGINT","SIGHUP"].forEach(y=>{process.on(y,()=>{o.killed===!1&&o.exitCode===null&&o.kill(y)})});let d=this._exitCallback;d?o.on("close",()=>{d(new fr(process.exitCode||0,"commander.executeSubCommandAsync","(close)"))}):o.on("close",process.exit.bind(process)),o.on("error",y=>{if(y.code==="ENOENT"){let m=`'${c}' does not exist
|
|
7
|
-
- if '${e._name}' is not meant to be an executable command, remove description parameter from '.command()' and use '.description()' instead
|
|
8
|
-
- if the default executable name is not suitable, use the executableFile option to supply a custom name`;throw new Error(m)}else if(y.code==="EACCES")throw new Error(`'${c}' not executable`);if(!d)process.exit(1);else{let m=new fr(1,"commander.executeSubCommandAsync","(error)");m.nestedError=y,d(m)}}),this.runningCommand=o}_dispatchSubcommand(e,t,n){let s=this._findCommand(e);s||this._helpAndError(),s._executableHandler?this._executeSubCommand(s,t.concat(n)):s._parseCommand(t,n)}_parseCommand(e,t){let n=this.parseOptions(t);if(e=e.concat(n.operands),t=n.unknown,this.args=e.concat(t),e&&this._findCommand(e[0]))this._dispatchSubcommand(e[0],e.slice(1),t);else if(this._lazyHasImplicitHelpCommand()&&e[0]===this._helpCommandName)e.length===1?this.help():this._dispatchSubcommand(e[1],[],[this._helpLongFlag]);else if(this._defaultCommandName)Io(this,t),this._dispatchSubcommand(this._defaultCommandName,e,t);else if(this.commands.length&&this.args.length===0&&!this._actionHandler&&!this._defaultCommandName&&this._helpAndError(),Io(this,n.unknown),this._checkForMissingMandatoryOptions(),n.unknown.length>0&&this.unknownOption(n.unknown[0]),this._actionHandler){let s=this.args.slice();this._args.forEach((i,a)=>{i.required&&s[a]==null?this.missingArgument(i.name):i.variadic&&(s[a]=s.splice(a))}),this._actionHandler(s),this.emit("command:"+this.name(),e,t)}else e.length?this._findCommand("*")?this._dispatchSubcommand("*",e,t):this.listenerCount("command:*")?this.emit("command:*",e,t):this.commands.length&&this.unknownCommand():this.commands.length&&this._helpAndError()}_findCommand(e){if(!!e)return this.commands.find(t=>t._name===e||t._aliases.includes(e))}_findOption(e){return this.options.find(t=>t.is(e))}_checkForMissingMandatoryOptions(){for(let e=this;e;e=e.parent)e.options.forEach(t=>{t.mandatory&&e._getOptionValue(t.attributeName())===void 0&&e.missingMandatoryOptionValue(t)})}parseOptions(e){let t=[],n=[],s=t,i=e.slice();function a(u){return u.length>1&&u[0]==="-"}let c=null;for(;i.length;){let u=i.shift();if(u==="--"){s===n&&s.push(u),s.push(...i);break}if(c&&!a(u)){this.emit(`option:${c.name()}`,u);continue}if(c=null,a(u)){let o=this._findOption(u);if(o){if(o.required){let l=i.shift();l===void 0&&this.optionMissingArgument(o),this.emit(`option:${o.name()}`,l)}else if(o.optional){let l=null;i.length>0&&!a(i[0])&&(l=i.shift()),this.emit(`option:${o.name()}`,l)}else this.emit(`option:${o.name()}`);c=o.variadic?o:null;continue}}if(u.length>2&&u[0]==="-"&&u[1]!=="-"){let o=this._findOption(`-${u[1]}`);if(o){o.required||o.optional&&this._combineFlagAndOptionalValue?this.emit(`option:${o.name()}`,u.slice(2)):(this.emit(`option:${o.name()}`),i.unshift(`-${u.slice(2)}`));continue}}if(/^--[^=]+=/.test(u)){let o=u.indexOf("="),l=this._findOption(u.slice(0,o));if(l&&(l.required||l.optional)){this.emit(`option:${l.name()}`,u.slice(o+1));continue}}u.length>1&&u[0]==="-"&&(s=n),s.push(u)}return{operands:t,unknown:n}}opts(){if(this._storeOptionsAsProperties){let e={},t=this.options.length;for(let n=0;n<t;n++){let s=this.options[n].attributeName();e[s]=s===this._versionOptionName?this._version:this[s]}return e}return this._optionValues}missingArgument(e){let t=`error: missing required argument '${e}'`;console.error(t),this._exit(1,"commander.missingArgument",t)}optionMissingArgument(e,t){let n;t?n=`error: option '${e.flags}' argument missing, got '${t}'`:n=`error: option '${e.flags}' argument missing`,console.error(n),this._exit(1,"commander.optionMissingArgument",n)}missingMandatoryOptionValue(e){let t=`error: required option '${e.flags}' not specified`;console.error(t),this._exit(1,"commander.missingMandatoryOptionValue",t)}unknownOption(e){if(this._allowUnknownOption)return;let t=`error: unknown option '${e}'`;console.error(t),this._exit(1,"commander.unknownOption",t)}unknownCommand(){let e=[this.name()];for(let s=this.parent;s;s=s.parent)e.unshift(s.name());let t=e.join(" "),n=`error: unknown command '${this.args[0]}'.`+(this._hasHelpOption?` See '${t} ${this._helpLongFlag}'.`:"");console.error(n),this._exit(1,"commander.unknownCommand",n)}version(e,t,n){if(e===void 0)return this._version;this._version=e,t=t||"-V, --version",n=n||"output the version number";let s=new Br(t,n);return this._versionOptionName=s.attributeName(),this.options.push(s),this.on("option:"+s.name(),()=>{process.stdout.write(e+`
|
|
9
|
-
`),this._exit(0,"commander.version",e)}),this}description(e,t){return e===void 0&&t===void 0?this._description:(this._description=e,this._argsDescription=t,this)}alias(e){if(e===void 0)return this._aliases[0];let t=this;if(this.commands.length!==0&&this.commands[this.commands.length-1]._executableHandler&&(t=this.commands[this.commands.length-1]),e===t._name)throw new Error("Command alias can't be the same as its name");return t._aliases.push(e),this}aliases(e){return e===void 0?this._aliases:(e.forEach(t=>this.alias(t)),this)}usage(e){if(e===void 0){if(this._usage)return this._usage;let t=this._args.map(n=>To(n));return[].concat(this.options.length||this._hasHelpOption?"[options]":[],this.commands.length?"[command]":[],this._args.length?t:[]).join(" ")}return this._usage=e,this}name(e){return e===void 0?this._name:(this._name=e,this)}prepareCommands(){let e=this.commands.filter(t=>!t._hidden).map(t=>{let n=t._args.map(s=>To(s)).join(" ");return[t._name+(t._aliases[0]?"|"+t._aliases[0]:"")+(t.options.length?" [options]":"")+(n?" "+n:""),t._description]});return this._lazyHasImplicitHelpCommand()&&e.push([this._helpCommandnameAndArgs,this._helpCommandDescription]),e}largestCommandLength(){return this.prepareCommands().reduce((t,n)=>Math.max(t,n[0].length),0)}largestOptionLength(){let e=[].slice.call(this.options);return e.push({flags:this._helpFlags}),e.reduce((t,n)=>Math.max(t,n.flags.length),0)}largestArgLength(){return this._args.reduce((e,t)=>Math.max(e,t.name.length),0)}padWidth(){let e=this.largestOptionLength();return this._argsDescription&&this._args.length&&this.largestArgLength()>e&&(e=this.largestArgLength()),this.commands&&this.commands.length&&this.largestCommandLength()>e&&(e=this.largestCommandLength()),e}optionHelp(){let e=this.padWidth(),n=(process.stdout.columns||80)-e-4;function s(u,o){return Ks(u,e)+" "+No(o,n,e+2)}let i=this.options.map(u=>{let o=u.description+(!u.negate&&u.defaultValue!==void 0?" (default: "+JSON.stringify(u.defaultValue)+")":"");return s(u.flags,o)}),a=this._hasHelpOption&&this._helpShortFlag&&!this._findOption(this._helpShortFlag),c=this._hasHelpOption&&!this._findOption(this._helpLongFlag);if(a||c){let u=this._helpFlags;a?c||(u=this._helpShortFlag):u=this._helpLongFlag,i.push(s(u,this._helpDescription))}return i.join(`
|
|
10
|
-
`)}commandHelp(){if(!this.commands.length&&!this._lazyHasImplicitHelpCommand())return"";let e=this.prepareCommands(),t=this.padWidth(),s=(process.stdout.columns||80)-t-4;return["Commands:",e.map(i=>{let a=i[1]?" "+i[1]:"";return(a?Ks(i[0],t):i[0])+No(a,s,t+2)}).join(`
|
|
11
|
-
`).replace(/^/gm," "),""].join(`
|
|
12
|
-
`)}helpInformation(){if(this._name==="s")return"";let e=[];if(this._description){e=[this._description,""];let u=this._argsDescription;if(u&&this._args.length){let o=this.padWidth(),d=(process.stdout.columns||80)-o-5;e.push("Arguments:"),this._args.forEach(y=>{e.push(" "+Ks(y.name,o)+" "+qo(u[y.name]||"",d,o+4))}),e.push("")}}let t=this._name;this._aliases[0]&&(t=t+"|"+this._aliases[0]);let n="";for(let u=this.parent;u;u=u.parent)n=u.name()+" "+n;let s=["Usage: "+n+t+" "+this.usage(),""],i=[],a=this.commandHelp();a&&(i=[a]);let c=[];return(this._hasHelpOption||this.options.length>0)&&(c=["Options:",""+this.optionHelp().replace(/^/gm," "),""]),s.concat(e).concat(c).concat(i).join(`
|
|
13
|
-
`)}outputHelp(e){e||(e=n=>n);let t=e(this.helpInformation());if(typeof t!="string"&&!Buffer.isBuffer(t))throw new Error("outputHelp callback must return a string or a Buffer");process.stdout.write(t),this.emit(this._helpLongFlag)}helpOption(e,t){if(typeof e=="boolean")return this._hasHelpOption=e,this;this._helpFlags=e||this._helpFlags,this._helpDescription=t||this._helpDescription;let n=Do(this._helpFlags);return this._helpShortFlag=n.shortFlag,this._helpLongFlag=n.longFlag,this}help(e){this.outputHelp(e),this._exit(process.exitCode||0,"commander.help","(outputHelp)")}_helpAndError(){this.outputHelp(),this._exit(1,"commander.help","(outputHelp)")}};Lt=jo.exports=new dr;Lt.program=Lt;Lt.Command=dr;Lt.Option=Br;Lt.CommanderError=fr;function mh(r){return r.split("-").reduce((e,t)=>e+t[0].toUpperCase()+t.slice(1))}function Ks(r,e){let t=Math.max(0,e-r.length);return r+Array(t+1).join(" ")}function qo(r,e,t){let n=new RegExp(".{1,"+(e-1)+"}([\\s\u200B]|$)|[^\\s\u200B]+?([\\s\u200B]|$)","g");return(r.match(n)||[]).map((i,a)=>(i.slice(-1)===`
|
|
14
|
-
`&&(i=i.slice(0,i.length-1)),(a>0&&t?Array(t+1).join(" "):"")+i.trimRight())).join(`
|
|
15
|
-
`)}function No(r,e,t){return r.match(/[\n]\s+/)||e<40?r:qo(r,e,t)}function Io(r,e){r._hasHelpOption&&e.find(n=>n===r._helpLongFlag||n===r._helpShortFlag)&&(r.outputHelp(),r._exit(0,"commander.helpDisplayed","(outputHelp)"))}function To(r){let e=r.name+(r.variadic===!0?"...":"");return r.required?"<"+e+">":"["+e+"]"}function Do(r){let e,t,n=r.split(/[ |,]+/);return n.length>1&&!/^[[<]/.test(n[1])&&(e=n.shift()),t=n.shift(),!e&&/^-[^-]$/.test(t)&&(e=t,t=void 0),{shortFlag:e,longFlag:t}}function Ao(r){return r.map(e=>{if(!e.startsWith("--inspect"))return e;let t,n="127.0.0.1",s="9229",i;return(i=e.match(/^(--inspect(-brk)?)$/))!==null?t=i[1]:(i=e.match(/^(--inspect(-brk|-port)?)=([^:]+)$/))!==null?(t=i[1],/^\d+$/.test(i[3])?s=i[3]:n=i[3]):(i=e.match(/^(--inspect(-brk|-port)?)=([^:]+):(\d+)$/))!==null&&(t=i[1],n=i[3],s=i[4]),t&&s!=="0"?`${t}=${n}:${parseInt(s)+1}`:e})}});var Jr=_((mw,xo)=>{var gh="2.0.0",vh=Number.MAX_SAFE_INTEGER||9007199254740991,_h=16;xo.exports={SEMVER_SPEC_VERSION:gh,MAX_LENGTH:256,MAX_SAFE_INTEGER:vh,MAX_SAFE_COMPONENT_LENGTH:_h}});var Yr=_((gw,Lo)=>{var yh=typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...r)=>console.error("SEMVER",...r):()=>{};Lo.exports=yh});var Mt=_((St,Mo)=>{var{MAX_SAFE_COMPONENT_LENGTH:Xs}=Jr(),$h=Yr();St=Mo.exports={};var Eh=St.re=[],O=St.src=[],P=St.t={},wh=0,j=(r,e,t)=>{let n=wh++;$h(r,n,e),P[r]=n,O[n]=e,Eh[n]=new RegExp(e,t?"g":void 0)};j("NUMERICIDENTIFIER","0|[1-9]\\d*");j("NUMERICIDENTIFIERLOOSE","[0-9]+");j("NONNUMERICIDENTIFIER","\\d*[a-zA-Z-][a-zA-Z0-9-]*");j("MAINVERSION",`(${O[P.NUMERICIDENTIFIER]})\\.(${O[P.NUMERICIDENTIFIER]})\\.(${O[P.NUMERICIDENTIFIER]})`);j("MAINVERSIONLOOSE",`(${O[P.NUMERICIDENTIFIERLOOSE]})\\.(${O[P.NUMERICIDENTIFIERLOOSE]})\\.(${O[P.NUMERICIDENTIFIERLOOSE]})`);j("PRERELEASEIDENTIFIER",`(?:${O[P.NUMERICIDENTIFIER]}|${O[P.NONNUMERICIDENTIFIER]})`);j("PRERELEASEIDENTIFIERLOOSE",`(?:${O[P.NUMERICIDENTIFIERLOOSE]}|${O[P.NONNUMERICIDENTIFIER]})`);j("PRERELEASE",`(?:-(${O[P.PRERELEASEIDENTIFIER]}(?:\\.${O[P.PRERELEASEIDENTIFIER]})*))`);j("PRERELEASELOOSE",`(?:-?(${O[P.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${O[P.PRERELEASEIDENTIFIERLOOSE]})*))`);j("BUILDIDENTIFIER","[0-9A-Za-z-]+");j("BUILD",`(?:\\+(${O[P.BUILDIDENTIFIER]}(?:\\.${O[P.BUILDIDENTIFIER]})*))`);j("FULLPLAIN",`v?${O[P.MAINVERSION]}${O[P.PRERELEASE]}?${O[P.BUILD]}?`);j("FULL",`^${O[P.FULLPLAIN]}$`);j("LOOSEPLAIN",`[v=\\s]*${O[P.MAINVERSIONLOOSE]}${O[P.PRERELEASELOOSE]}?${O[P.BUILD]}?`);j("LOOSE",`^${O[P.LOOSEPLAIN]}$`);j("GTLT","((?:<|>)?=?)");j("XRANGEIDENTIFIERLOOSE",`${O[P.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);j("XRANGEIDENTIFIER",`${O[P.NUMERICIDENTIFIER]}|x|X|\\*`);j("XRANGEPLAIN",`[v=\\s]*(${O[P.XRANGEIDENTIFIER]})(?:\\.(${O[P.XRANGEIDENTIFIER]})(?:\\.(${O[P.XRANGEIDENTIFIER]})(?:${O[P.PRERELEASE]})?${O[P.BUILD]}?)?)?`);j("XRANGEPLAINLOOSE",`[v=\\s]*(${O[P.XRANGEIDENTIFIERLOOSE]})(?:\\.(${O[P.XRANGEIDENTIFIERLOOSE]})(?:\\.(${O[P.XRANGEIDENTIFIERLOOSE]})(?:${O[P.PRERELEASELOOSE]})?${O[P.BUILD]}?)?)?`);j("XRANGE",`^${O[P.GTLT]}\\s*${O[P.XRANGEPLAIN]}$`);j("XRANGELOOSE",`^${O[P.GTLT]}\\s*${O[P.XRANGEPLAINLOOSE]}$`);j("COERCE",`(^|[^\\d])(\\d{1,${Xs}})(?:\\.(\\d{1,${Xs}}))?(?:\\.(\\d{1,${Xs}}))?(?:$|[^\\d])`);j("COERCERTL",O[P.COERCE],!0);j("LONETILDE","(?:~>?)");j("TILDETRIM",`(\\s*)${O[P.LONETILDE]}\\s+`,!0);St.tildeTrimReplace="$1~";j("TILDE",`^${O[P.LONETILDE]}${O[P.XRANGEPLAIN]}$`);j("TILDELOOSE",`^${O[P.LONETILDE]}${O[P.XRANGEPLAINLOOSE]}$`);j("LONECARET","(?:\\^)");j("CARETTRIM",`(\\s*)${O[P.LONECARET]}\\s+`,!0);St.caretTrimReplace="$1^";j("CARET",`^${O[P.LONECARET]}${O[P.XRANGEPLAIN]}$`);j("CARETLOOSE",`^${O[P.LONECARET]}${O[P.XRANGEPLAINLOOSE]}$`);j("COMPARATORLOOSE",`^${O[P.GTLT]}\\s*(${O[P.LOOSEPLAIN]})$|^$`);j("COMPARATOR",`^${O[P.GTLT]}\\s*(${O[P.FULLPLAIN]})$|^$`);j("COMPARATORTRIM",`(\\s*)${O[P.GTLT]}\\s*(${O[P.LOOSEPLAIN]}|${O[P.XRANGEPLAIN]})`,!0);St.comparatorTrimReplace="$1$2$3";j("HYPHENRANGE",`^\\s*(${O[P.XRANGEPLAIN]})\\s+-\\s+(${O[P.XRANGEPLAIN]})\\s*$`);j("HYPHENRANGELOOSE",`^\\s*(${O[P.XRANGEPLAINLOOSE]})\\s+-\\s+(${O[P.XRANGEPLAINLOOSE]})\\s*$`);j("STAR","(<|>)?=?\\s*\\*");j("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$");j("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")});var Zr=_((vw,Fo)=>{var bh=["includePrerelease","loose","rtl"],Sh=r=>r?typeof r!="object"?{loose:!0}:bh.filter(e=>r[e]).reduce((e,t)=>(e[t]=!0,e),{}):{};Fo.exports=Sh});var Ws=_((_w,Uo)=>{var Vo=/^[0-9]+$/,Ho=(r,e)=>{let t=Vo.test(r),n=Vo.test(e);return t&&n&&(r=+r,e=+e),r===e?0:t&&!n?-1:n&&!t?1:r<e?-1:1},Oh=(r,e)=>Ho(e,r);Uo.exports={compareIdentifiers:Ho,rcompareIdentifiers:Oh}});var ge=_((yw,Xo)=>{var zn=Yr(),{MAX_LENGTH:Go,MAX_SAFE_INTEGER:Kn}=Jr(),{re:zo,t:Ko}=Mt(),Ph=Zr(),{compareIdentifiers:hr}=Ws(),De=class{constructor(e,t){if(t=Ph(t),e instanceof De){if(e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease)return e;e=e.version}else if(typeof e!="string")throw new TypeError(`Invalid Version: ${e}`);if(e.length>Go)throw new TypeError(`version is longer than ${Go} characters`);zn("SemVer",e,t),this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease;let n=e.trim().match(t.loose?zo[Ko.LOOSE]:zo[Ko.FULL]);if(!n)throw new TypeError(`Invalid Version: ${e}`);if(this.raw=e,this.major=+n[1],this.minor=+n[2],this.patch=+n[3],this.major>Kn||this.major<0)throw new TypeError("Invalid major version");if(this.minor>Kn||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>Kn||this.patch<0)throw new TypeError("Invalid patch version");n[4]?this.prerelease=n[4].split(".").map(s=>{if(/^[0-9]+$/.test(s)){let i=+s;if(i>=0&&i<Kn)return i}return s}):this.prerelease=[],this.build=n[5]?n[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(e){if(zn("SemVer.compare",this.version,this.options,e),!(e instanceof De)){if(typeof e=="string"&&e===this.version)return 0;e=new De(e,this.options)}return e.version===this.version?0:this.compareMain(e)||this.comparePre(e)}compareMain(e){return e instanceof De||(e=new De(e,this.options)),hr(this.major,e.major)||hr(this.minor,e.minor)||hr(this.patch,e.patch)}comparePre(e){if(e instanceof De||(e=new De(e,this.options)),this.prerelease.length&&!e.prerelease.length)return-1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;let t=0;do{let n=this.prerelease[t],s=e.prerelease[t];if(zn("prerelease compare",t,n,s),n===void 0&&s===void 0)return 0;if(s===void 0)return 1;if(n===void 0)return-1;if(n===s)continue;return hr(n,s)}while(++t)}compareBuild(e){e instanceof De||(e=new De(e,this.options));let t=0;do{let n=this.build[t],s=e.build[t];if(zn("prerelease compare",t,n,s),n===void 0&&s===void 0)return 0;if(s===void 0)return 1;if(n===void 0)return-1;if(n===s)continue;return hr(n,s)}while(++t)}inc(e,t){switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",t);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",t);break;case"prepatch":this.prerelease.length=0,this.inc("patch",t),this.inc("pre",t);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",t),this.inc("pre",t);break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":if(this.prerelease.length===0)this.prerelease=[0];else{let n=this.prerelease.length;for(;--n>=0;)typeof this.prerelease[n]=="number"&&(this.prerelease[n]++,n=-2);n===-1&&this.prerelease.push(0)}t&&(hr(this.prerelease[0],t)===0?isNaN(this.prerelease[1])&&(this.prerelease=[t,0]):this.prerelease=[t,0]);break;default:throw new Error(`invalid increment argument: ${e}`)}return this.format(),this.raw=this.version,this}};Xo.exports=De});var Ft=_(($w,Yo)=>{var{MAX_LENGTH:Rh}=Jr(),{re:Wo,t:Bo}=Mt(),Jo=ge(),Ch=Zr(),Nh=(r,e)=>{if(e=Ch(e),r instanceof Jo)return r;if(typeof r!="string"||r.length>Rh||!(e.loose?Wo[Bo.LOOSE]:Wo[Bo.FULL]).test(r))return null;try{return new Jo(r,e)}catch{return null}};Yo.exports=Nh});var Qo=_((Ew,Zo)=>{var Ih=Ft(),Th=(r,e)=>{let t=Ih(r,e);return t?t.version:null};Zo.exports=Th});var tc=_((ww,ec)=>{var Ah=Ft(),qh=(r,e)=>{let t=Ah(r.trim().replace(/^[=v]+/,""),e);return t?t.version:null};ec.exports=qh});var sc=_((bw,nc)=>{var rc=ge(),Dh=(r,e,t,n)=>{typeof t=="string"&&(n=t,t=void 0);try{return new rc(r instanceof rc?r.version:r,t).inc(e,n).version}catch{return null}};nc.exports=Dh});var He=_((Sw,ac)=>{var ic=ge(),jh=(r,e,t)=>new ic(r,t).compare(new ic(e,t));ac.exports=jh});var Xn=_((Ow,oc)=>{var kh=He(),xh=(r,e,t)=>kh(r,e,t)===0;oc.exports=xh});var lc=_((Pw,uc)=>{var cc=Ft(),Lh=Xn(),Mh=(r,e)=>{if(Lh(r,e))return null;{let t=cc(r),n=cc(e),s=t.prerelease.length||n.prerelease.length,i=s?"pre":"",a=s?"prerelease":"";for(let c in t)if((c==="major"||c==="minor"||c==="patch")&&t[c]!==n[c])return i+c;return a}};uc.exports=Mh});var dc=_((Rw,fc)=>{var Fh=ge(),Vh=(r,e)=>new Fh(r,e).major;fc.exports=Vh});var pc=_((Cw,hc)=>{var Hh=ge(),Uh=(r,e)=>new Hh(r,e).minor;hc.exports=Uh});var gc=_((Nw,mc)=>{var Gh=ge(),zh=(r,e)=>new Gh(r,e).patch;mc.exports=zh});var _c=_((Iw,vc)=>{var Kh=Ft(),Xh=(r,e)=>{let t=Kh(r,e);return t&&t.prerelease.length?t.prerelease:null};vc.exports=Xh});var $c=_((Tw,yc)=>{var Wh=He(),Bh=(r,e,t)=>Wh(e,r,t);yc.exports=Bh});var wc=_((Aw,Ec)=>{var Jh=He(),Yh=(r,e)=>Jh(r,e,!0);Ec.exports=Yh});var Wn=_((qw,Sc)=>{var bc=ge(),Zh=(r,e,t)=>{let n=new bc(r,t),s=new bc(e,t);return n.compare(s)||n.compareBuild(s)};Sc.exports=Zh});var Pc=_((Dw,Oc)=>{var Qh=Wn(),ep=(r,e)=>r.sort((t,n)=>Qh(t,n,e));Oc.exports=ep});var Cc=_((jw,Rc)=>{var tp=Wn(),rp=(r,e)=>r.sort((t,n)=>tp(n,t,e));Rc.exports=rp});var Qr=_((kw,Nc)=>{var np=He(),sp=(r,e,t)=>np(r,e,t)>0;Nc.exports=sp});var Bn=_((xw,Ic)=>{var ip=He(),ap=(r,e,t)=>ip(r,e,t)<0;Ic.exports=ap});var Bs=_((Lw,Tc)=>{var op=He(),cp=(r,e,t)=>op(r,e,t)!==0;Tc.exports=cp});var Jn=_((Mw,Ac)=>{var up=He(),lp=(r,e,t)=>up(r,e,t)>=0;Ac.exports=lp});var Yn=_((Fw,qc)=>{var fp=He(),dp=(r,e,t)=>fp(r,e,t)<=0;qc.exports=dp});var Js=_((Vw,Dc)=>{var hp=Xn(),pp=Bs(),mp=Qr(),gp=Jn(),vp=Bn(),_p=Yn(),yp=(r,e,t,n)=>{switch(e){case"===":return typeof r=="object"&&(r=r.version),typeof t=="object"&&(t=t.version),r===t;case"!==":return typeof r=="object"&&(r=r.version),typeof t=="object"&&(t=t.version),r!==t;case"":case"=":case"==":return hp(r,t,n);case"!=":return pp(r,t,n);case">":return mp(r,t,n);case">=":return gp(r,t,n);case"<":return vp(r,t,n);case"<=":return _p(r,t,n);default:throw new TypeError(`Invalid operator: ${e}`)}};Dc.exports=yp});var kc=_((Hw,jc)=>{var $p=ge(),Ep=Ft(),{re:Zn,t:Qn}=Mt(),wp=(r,e)=>{if(r instanceof $p)return r;if(typeof r=="number"&&(r=String(r)),typeof r!="string")return null;e=e||{};let t=null;if(!e.rtl)t=r.match(Zn[Qn.COERCE]);else{let n;for(;(n=Zn[Qn.COERCERTL].exec(r))&&(!t||t.index+t[0].length!==r.length);)(!t||n.index+n[0].length!==t.index+t[0].length)&&(t=n),Zn[Qn.COERCERTL].lastIndex=n.index+n[1].length+n[2].length;Zn[Qn.COERCERTL].lastIndex=-1}return t===null?null:Ep(`${t[2]}.${t[3]||"0"}.${t[4]||"0"}`,e)};jc.exports=wp});var Lc=_((Uw,xc)=>{"use strict";xc.exports=function(r){r.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}});var Fc=_((Gw,Mc)=>{"use strict";Mc.exports=X;X.Node=Vt;X.create=X;function X(r){var e=this;if(e instanceof X||(e=new X),e.tail=null,e.head=null,e.length=0,r&&typeof r.forEach=="function")r.forEach(function(s){e.push(s)});else if(arguments.length>0)for(var t=0,n=arguments.length;t<n;t++)e.push(arguments[t]);return e}X.prototype.removeNode=function(r){if(r.list!==this)throw new Error("removing node which does not belong to this list");var e=r.next,t=r.prev;return e&&(e.prev=t),t&&(t.next=e),r===this.head&&(this.head=e),r===this.tail&&(this.tail=t),r.list.length--,r.next=null,r.prev=null,r.list=null,e};X.prototype.unshiftNode=function(r){if(r!==this.head){r.list&&r.list.removeNode(r);var e=this.head;r.list=this,r.next=e,e&&(e.prev=r),this.head=r,this.tail||(this.tail=r),this.length++}};X.prototype.pushNode=function(r){if(r!==this.tail){r.list&&r.list.removeNode(r);var e=this.tail;r.list=this,r.prev=e,e&&(e.next=r),this.tail=r,this.head||(this.head=r),this.length++}};X.prototype.push=function(){for(var r=0,e=arguments.length;r<e;r++)Sp(this,arguments[r]);return this.length};X.prototype.unshift=function(){for(var r=0,e=arguments.length;r<e;r++)Op(this,arguments[r]);return this.length};X.prototype.pop=function(){if(!!this.tail){var r=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,r}};X.prototype.shift=function(){if(!!this.head){var r=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,r}};X.prototype.forEach=function(r,e){e=e||this;for(var t=this.head,n=0;t!==null;n++)r.call(e,t.value,n,this),t=t.next};X.prototype.forEachReverse=function(r,e){e=e||this;for(var t=this.tail,n=this.length-1;t!==null;n--)r.call(e,t.value,n,this),t=t.prev};X.prototype.get=function(r){for(var e=0,t=this.head;t!==null&&e<r;e++)t=t.next;if(e===r&&t!==null)return t.value};X.prototype.getReverse=function(r){for(var e=0,t=this.tail;t!==null&&e<r;e++)t=t.prev;if(e===r&&t!==null)return t.value};X.prototype.map=function(r,e){e=e||this;for(var t=new X,n=this.head;n!==null;)t.push(r.call(e,n.value,this)),n=n.next;return t};X.prototype.mapReverse=function(r,e){e=e||this;for(var t=new X,n=this.tail;n!==null;)t.push(r.call(e,n.value,this)),n=n.prev;return t};X.prototype.reduce=function(r,e){var t,n=this.head;if(arguments.length>1)t=e;else if(this.head)n=this.head.next,t=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var s=0;n!==null;s++)t=r(t,n.value,s),n=n.next;return t};X.prototype.reduceReverse=function(r,e){var t,n=this.tail;if(arguments.length>1)t=e;else if(this.tail)n=this.tail.prev,t=this.tail.value;else throw new TypeError("Reduce of empty list with no initial value");for(var s=this.length-1;n!==null;s--)t=r(t,n.value,s),n=n.prev;return t};X.prototype.toArray=function(){for(var r=new Array(this.length),e=0,t=this.head;t!==null;e++)r[e]=t.value,t=t.next;return r};X.prototype.toArrayReverse=function(){for(var r=new Array(this.length),e=0,t=this.tail;t!==null;e++)r[e]=t.value,t=t.prev;return r};X.prototype.slice=function(r,e){e=e||this.length,e<0&&(e+=this.length),r=r||0,r<0&&(r+=this.length);var t=new X;if(e<r||e<0)return t;r<0&&(r=0),e>this.length&&(e=this.length);for(var n=0,s=this.head;s!==null&&n<r;n++)s=s.next;for(;s!==null&&n<e;n++,s=s.next)t.push(s.value);return t};X.prototype.sliceReverse=function(r,e){e=e||this.length,e<0&&(e+=this.length),r=r||0,r<0&&(r+=this.length);var t=new X;if(e<r||e<0)return t;r<0&&(r=0),e>this.length&&(e=this.length);for(var n=this.length,s=this.tail;s!==null&&n>e;n--)s=s.prev;for(;s!==null&&n>r;n--,s=s.prev)t.push(s.value);return t};X.prototype.splice=function(r,e,...t){r>this.length&&(r=this.length-1),r<0&&(r=this.length+r);for(var n=0,s=this.head;s!==null&&n<r;n++)s=s.next;for(var i=[],n=0;s&&n<e;n++)i.push(s.value),s=this.removeNode(s);s===null&&(s=this.tail),s!==this.head&&s!==this.tail&&(s=s.prev);for(var n=0;n<t.length;n++)s=bp(this,s,t[n]);return i};X.prototype.reverse=function(){for(var r=this.head,e=this.tail,t=r;t!==null;t=t.prev){var n=t.prev;t.prev=t.next,t.next=n}return this.head=e,this.tail=r,this};function bp(r,e,t){var n=e===r.head?new Vt(t,null,e,r):new Vt(t,e,e.next,r);return n.next===null&&(r.tail=n),n.prev===null&&(r.head=n),r.length++,n}function Sp(r,e){r.tail=new Vt(e,r.tail,null,r),r.head||(r.head=r.tail),r.length++}function Op(r,e){r.head=new Vt(e,null,r.head,r),r.tail||(r.tail=r.head),r.length++}function Vt(r,e,t,n){if(!(this instanceof Vt))return new Vt(r,e,t,n);this.list=n,this.value=r,e?(e.next=this,this.prev=e):this.prev=null,t?(t.prev=this,this.next=t):this.next=null}try{Lc()(X)}catch{}});var zc=_((zw,Gc)=>{"use strict";var Pp=Fc(),Ht=Symbol("max"),gt=Symbol("length"),pr=Symbol("lengthCalculator"),tn=Symbol("allowStale"),Ut=Symbol("maxAge"),mt=Symbol("dispose"),Vc=Symbol("noDisposeOnSet"),fe=Symbol("lruList"),We=Symbol("cache"),Uc=Symbol("updateAgeOnGet"),Ys=()=>1,Qs=class{constructor(e){if(typeof e=="number"&&(e={max:e}),e||(e={}),e.max&&(typeof e.max!="number"||e.max<0))throw new TypeError("max must be a non-negative number");let t=this[Ht]=e.max||1/0,n=e.length||Ys;if(this[pr]=typeof n!="function"?Ys:n,this[tn]=e.stale||!1,e.maxAge&&typeof e.maxAge!="number")throw new TypeError("maxAge must be a number");this[Ut]=e.maxAge||0,this[mt]=e.dispose,this[Vc]=e.noDisposeOnSet||!1,this[Uc]=e.updateAgeOnGet||!1,this.reset()}set max(e){if(typeof e!="number"||e<0)throw new TypeError("max must be a non-negative number");this[Ht]=e||1/0,en(this)}get max(){return this[Ht]}set allowStale(e){this[tn]=!!e}get allowStale(){return this[tn]}set maxAge(e){if(typeof e!="number")throw new TypeError("maxAge must be a non-negative number");this[Ut]=e,en(this)}get maxAge(){return this[Ut]}set lengthCalculator(e){typeof e!="function"&&(e=Ys),e!==this[pr]&&(this[pr]=e,this[gt]=0,this[fe].forEach(t=>{t.length=this[pr](t.value,t.key),this[gt]+=t.length})),en(this)}get lengthCalculator(){return this[pr]}get length(){return this[gt]}get itemCount(){return this[fe].length}rforEach(e,t){t=t||this;for(let n=this[fe].tail;n!==null;){let s=n.prev;Hc(this,e,n,t),n=s}}forEach(e,t){t=t||this;for(let n=this[fe].head;n!==null;){let s=n.next;Hc(this,e,n,t),n=s}}keys(){return this[fe].toArray().map(e=>e.key)}values(){return this[fe].toArray().map(e=>e.value)}reset(){this[mt]&&this[fe]&&this[fe].length&&this[fe].forEach(e=>this[mt](e.key,e.value)),this[We]=new Map,this[fe]=new Pp,this[gt]=0}dump(){return this[fe].map(e=>es(this,e)?!1:{k:e.key,v:e.value,e:e.now+(e.maxAge||0)}).toArray().filter(e=>e)}dumpLru(){return this[fe]}set(e,t,n){if(n=n||this[Ut],n&&typeof n!="number")throw new TypeError("maxAge must be a number");let s=n?Date.now():0,i=this[pr](t,e);if(this[We].has(e)){if(i>this[Ht])return mr(this,this[We].get(e)),!1;let u=this[We].get(e).value;return this[mt]&&(this[Vc]||this[mt](e,u.value)),u.now=s,u.maxAge=n,u.value=t,this[gt]+=i-u.length,u.length=i,this.get(e),en(this),!0}let a=new ei(e,t,i,s,n);return a.length>this[Ht]?(this[mt]&&this[mt](e,t),!1):(this[gt]+=a.length,this[fe].unshift(a),this[We].set(e,this[fe].head),en(this),!0)}has(e){if(!this[We].has(e))return!1;let t=this[We].get(e).value;return!es(this,t)}get(e){return Zs(this,e,!0)}peek(e){return Zs(this,e,!1)}pop(){let e=this[fe].tail;return e?(mr(this,e),e.value):null}del(e){mr(this,this[We].get(e))}load(e){this.reset();let t=Date.now();for(let n=e.length-1;n>=0;n--){let s=e[n],i=s.e||0;if(i===0)this.set(s.k,s.v);else{let a=i-t;a>0&&this.set(s.k,s.v,a)}}}prune(){this[We].forEach((e,t)=>Zs(this,t,!1))}},Zs=(r,e,t)=>{let n=r[We].get(e);if(n){let s=n.value;if(es(r,s)){if(mr(r,n),!r[tn])return}else t&&(r[Uc]&&(n.value.now=Date.now()),r[fe].unshiftNode(n));return s.value}},es=(r,e)=>{if(!e||!e.maxAge&&!r[Ut])return!1;let t=Date.now()-e.now;return e.maxAge?t>e.maxAge:r[Ut]&&t>r[Ut]},en=r=>{if(r[gt]>r[Ht])for(let e=r[fe].tail;r[gt]>r[Ht]&&e!==null;){let t=e.prev;mr(r,e),e=t}},mr=(r,e)=>{if(e){let t=e.value;r[mt]&&r[mt](t.key,t.value),r[gt]-=t.length,r[We].delete(t.key),r[fe].removeNode(e)}},ei=class{constructor(e,t,n,s,i){this.key=e,this.value=t,this.length=n,this.now=s,this.maxAge=i||0}},Hc=(r,e,t,n)=>{let s=t.value;es(r,s)&&(mr(r,t),r[tn]||(s=void 0)),s&&e.call(n,s.value,s.key,r)};Gc.exports=Qs});var Ue=_((Kw,Bc)=>{var Gt=class{constructor(e,t){if(t=Cp(t),e instanceof Gt)return e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease?e:new Gt(e.raw,t);if(e instanceof ti)return this.raw=e.value,this.set=[[e]],this.format(),this;if(this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease,this.raw=e,this.set=e.split("||").map(n=>this.parseRange(n.trim())).filter(n=>n.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${e}`);if(this.set.length>1){let n=this.set[0];if(this.set=this.set.filter(s=>!Xc(s[0])),this.set.length===0)this.set=[n];else if(this.set.length>1){for(let s of this.set)if(s.length===1&&qp(s[0])){this.set=[s];break}}}this.format()}format(){return this.range=this.set.map(e=>e.join(" ").trim()).join("||").trim(),this.range}toString(){return this.range}parseRange(e){e=e.trim();let n=`parseRange:${Object.keys(this.options).join(",")}:${e}`,s=Kc.get(n);if(s)return s;let i=this.options.loose,a=i?Pe[$e.HYPHENRANGELOOSE]:Pe[$e.HYPHENRANGE];e=e.replace(a,Up(this.options.includePrerelease)),ae("hyphen replace",e),e=e.replace(Pe[$e.COMPARATORTRIM],Ip),ae("comparator trim",e),e=e.replace(Pe[$e.TILDETRIM],Tp),e=e.replace(Pe[$e.CARETTRIM],Ap),e=e.split(/\s+/).join(" ");let c=e.split(" ").map(d=>Dp(d,this.options)).join(" ").split(/\s+/).map(d=>Hp(d,this.options));i&&(c=c.filter(d=>(ae("loose invalid filter",d,this.options),!!d.match(Pe[$e.COMPARATORLOOSE])))),ae("range list",c);let u=new Map,o=c.map(d=>new ti(d,this.options));for(let d of o){if(Xc(d))return[d];u.set(d.value,d)}u.size>1&&u.has("")&&u.delete("");let l=[...u.values()];return Kc.set(n,l),l}intersects(e,t){if(!(e instanceof Gt))throw new TypeError("a Range is required");return this.set.some(n=>Wc(n,t)&&e.set.some(s=>Wc(s,t)&&n.every(i=>s.every(a=>i.intersects(a,t)))))}test(e){if(!e)return!1;if(typeof e=="string")try{e=new Np(e,this.options)}catch{return!1}for(let t=0;t<this.set.length;t++)if(Gp(this.set[t],e,this.options))return!0;return!1}};Bc.exports=Gt;var Rp=zc(),Kc=new Rp({max:1e3}),Cp=Zr(),ti=rn(),ae=Yr(),Np=ge(),{re:Pe,t:$e,comparatorTrimReplace:Ip,tildeTrimReplace:Tp,caretTrimReplace:Ap}=Mt(),Xc=r=>r.value==="<0.0.0-0",qp=r=>r.value==="",Wc=(r,e)=>{let t=!0,n=r.slice(),s=n.pop();for(;t&&n.length;)t=n.every(i=>s.intersects(i,e)),s=n.pop();return t},Dp=(r,e)=>(ae("comp",r,e),r=xp(r,e),ae("caret",r),r=jp(r,e),ae("tildes",r),r=Mp(r,e),ae("xrange",r),r=Vp(r,e),ae("stars",r),r),Ee=r=>!r||r.toLowerCase()==="x"||r==="*",jp=(r,e)=>r.trim().split(/\s+/).map(t=>kp(t,e)).join(" "),kp=(r,e)=>{let t=e.loose?Pe[$e.TILDELOOSE]:Pe[$e.TILDE];return r.replace(t,(n,s,i,a,c)=>{ae("tilde",r,n,s,i,a,c);let u;return Ee(s)?u="":Ee(i)?u=`>=${s}.0.0 <${+s+1}.0.0-0`:Ee(a)?u=`>=${s}.${i}.0 <${s}.${+i+1}.0-0`:c?(ae("replaceTilde pr",c),u=`>=${s}.${i}.${a}-${c} <${s}.${+i+1}.0-0`):u=`>=${s}.${i}.${a} <${s}.${+i+1}.0-0`,ae("tilde return",u),u})},xp=(r,e)=>r.trim().split(/\s+/).map(t=>Lp(t,e)).join(" "),Lp=(r,e)=>{ae("caret",r,e);let t=e.loose?Pe[$e.CARETLOOSE]:Pe[$e.CARET],n=e.includePrerelease?"-0":"";return r.replace(t,(s,i,a,c,u)=>{ae("caret",r,s,i,a,c,u);let o;return Ee(i)?o="":Ee(a)?o=`>=${i}.0.0${n} <${+i+1}.0.0-0`:Ee(c)?i==="0"?o=`>=${i}.${a}.0${n} <${i}.${+a+1}.0-0`:o=`>=${i}.${a}.0${n} <${+i+1}.0.0-0`:u?(ae("replaceCaret pr",u),i==="0"?a==="0"?o=`>=${i}.${a}.${c}-${u} <${i}.${a}.${+c+1}-0`:o=`>=${i}.${a}.${c}-${u} <${i}.${+a+1}.0-0`:o=`>=${i}.${a}.${c}-${u} <${+i+1}.0.0-0`):(ae("no pr"),i==="0"?a==="0"?o=`>=${i}.${a}.${c}${n} <${i}.${a}.${+c+1}-0`:o=`>=${i}.${a}.${c}${n} <${i}.${+a+1}.0-0`:o=`>=${i}.${a}.${c} <${+i+1}.0.0-0`),ae("caret return",o),o})},Mp=(r,e)=>(ae("replaceXRanges",r,e),r.split(/\s+/).map(t=>Fp(t,e)).join(" ")),Fp=(r,e)=>{r=r.trim();let t=e.loose?Pe[$e.XRANGELOOSE]:Pe[$e.XRANGE];return r.replace(t,(n,s,i,a,c,u)=>{ae("xRange",r,n,s,i,a,c,u);let o=Ee(i),l=o||Ee(a),d=l||Ee(c),y=d;return s==="="&&y&&(s=""),u=e.includePrerelease?"-0":"",o?s===">"||s==="<"?n="<0.0.0-0":n="*":s&&y?(l&&(a=0),c=0,s===">"?(s=">=",l?(i=+i+1,a=0,c=0):(a=+a+1,c=0)):s==="<="&&(s="<",l?i=+i+1:a=+a+1),s==="<"&&(u="-0"),n=`${s+i}.${a}.${c}${u}`):l?n=`>=${i}.0.0${u} <${+i+1}.0.0-0`:d&&(n=`>=${i}.${a}.0${u} <${i}.${+a+1}.0-0`),ae("xRange return",n),n})},Vp=(r,e)=>(ae("replaceStars",r,e),r.trim().replace(Pe[$e.STAR],"")),Hp=(r,e)=>(ae("replaceGTE0",r,e),r.trim().replace(Pe[e.includePrerelease?$e.GTE0PRE:$e.GTE0],"")),Up=r=>(e,t,n,s,i,a,c,u,o,l,d,y,m)=>(Ee(n)?t="":Ee(s)?t=`>=${n}.0.0${r?"-0":""}`:Ee(i)?t=`>=${n}.${s}.0${r?"-0":""}`:a?t=`>=${t}`:t=`>=${t}${r?"-0":""}`,Ee(o)?u="":Ee(l)?u=`<${+o+1}.0.0-0`:Ee(d)?u=`<${o}.${+l+1}.0-0`:y?u=`<=${o}.${l}.${d}-${y}`:r?u=`<${o}.${l}.${+d+1}-0`:u=`<=${u}`,`${t} ${u}`.trim()),Gp=(r,e,t)=>{for(let n=0;n<r.length;n++)if(!r[n].test(e))return!1;if(e.prerelease.length&&!t.includePrerelease){for(let n=0;n<r.length;n++)if(ae(r[n].semver),r[n].semver!==ti.ANY&&r[n].semver.prerelease.length>0){let s=r[n].semver;if(s.major===e.major&&s.minor===e.minor&&s.patch===e.patch)return!0}return!1}return!0}});var rn=_((Xw,eu)=>{var nn=Symbol("SemVer ANY"),gr=class{static get ANY(){return nn}constructor(e,t){if(t=zp(t),e instanceof gr){if(e.loose===!!t.loose)return e;e=e.value}ni("comparator",e,t),this.options=t,this.loose=!!t.loose,this.parse(e),this.semver===nn?this.value="":this.value=this.operator+this.semver.version,ni("comp",this)}parse(e){let t=this.options.loose?Jc[Yc.COMPARATORLOOSE]:Jc[Yc.COMPARATOR],n=e.match(t);if(!n)throw new TypeError(`Invalid comparator: ${e}`);this.operator=n[1]!==void 0?n[1]:"",this.operator==="="&&(this.operator=""),n[2]?this.semver=new Zc(n[2],this.options.loose):this.semver=nn}toString(){return this.value}test(e){if(ni("Comparator.test",e,this.options.loose),this.semver===nn||e===nn)return!0;if(typeof e=="string")try{e=new Zc(e,this.options)}catch{return!1}return ri(e,this.operator,this.semver,this.options)}intersects(e,t){if(!(e instanceof gr))throw new TypeError("a Comparator is required");if((!t||typeof t!="object")&&(t={loose:!!t,includePrerelease:!1}),this.operator==="")return this.value===""?!0:new Qc(e.value,t).test(this.value);if(e.operator==="")return e.value===""?!0:new Qc(this.value,t).test(e.semver);let n=(this.operator===">="||this.operator===">")&&(e.operator===">="||e.operator===">"),s=(this.operator==="<="||this.operator==="<")&&(e.operator==="<="||e.operator==="<"),i=this.semver.version===e.semver.version,a=(this.operator===">="||this.operator==="<=")&&(e.operator===">="||e.operator==="<="),c=ri(this.semver,"<",e.semver,t)&&(this.operator===">="||this.operator===">")&&(e.operator==="<="||e.operator==="<"),u=ri(this.semver,">",e.semver,t)&&(this.operator==="<="||this.operator==="<")&&(e.operator===">="||e.operator===">");return n||s||i&&a||c||u}};eu.exports=gr;var zp=Zr(),{re:Jc,t:Yc}=Mt(),ri=Js(),ni=Yr(),Zc=ge(),Qc=Ue()});var sn=_((Ww,tu)=>{var Kp=Ue(),Xp=(r,e,t)=>{try{e=new Kp(e,t)}catch{return!1}return e.test(r)};tu.exports=Xp});var nu=_((Bw,ru)=>{var Wp=Ue(),Bp=(r,e)=>new Wp(r,e).set.map(t=>t.map(n=>n.value).join(" ").trim().split(" "));ru.exports=Bp});var iu=_((Jw,su)=>{var Jp=ge(),Yp=Ue(),Zp=(r,e,t)=>{let n=null,s=null,i=null;try{i=new Yp(e,t)}catch{return null}return r.forEach(a=>{i.test(a)&&(!n||s.compare(a)===-1)&&(n=a,s=new Jp(n,t))}),n};su.exports=Zp});var ou=_((Yw,au)=>{var Qp=ge(),em=Ue(),tm=(r,e,t)=>{let n=null,s=null,i=null;try{i=new em(e,t)}catch{return null}return r.forEach(a=>{i.test(a)&&(!n||s.compare(a)===1)&&(n=a,s=new Qp(n,t))}),n};au.exports=tm});var lu=_((Zw,uu)=>{var si=ge(),rm=Ue(),cu=Qr(),nm=(r,e)=>{r=new rm(r,e);let t=new si("0.0.0");if(r.test(t)||(t=new si("0.0.0-0"),r.test(t)))return t;t=null;for(let n=0;n<r.set.length;++n){let s=r.set[n],i=null;s.forEach(a=>{let c=new si(a.semver.version);switch(a.operator){case">":c.prerelease.length===0?c.patch++:c.prerelease.push(0),c.raw=c.format();case"":case">=":(!i||cu(c,i))&&(i=c);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${a.operator}`)}}),i&&(!t||cu(t,i))&&(t=i)}return t&&r.test(t)?t:null};uu.exports=nm});var du=_((Qw,fu)=>{var sm=Ue(),im=(r,e)=>{try{return new sm(r,e).range||"*"}catch{return null}};fu.exports=im});var ts=_((eb,gu)=>{var am=ge(),mu=rn(),{ANY:om}=mu,cm=Ue(),um=sn(),hu=Qr(),pu=Bn(),lm=Yn(),fm=Jn(),dm=(r,e,t,n)=>{r=new am(r,n),e=new cm(e,n);let s,i,a,c,u;switch(t){case">":s=hu,i=lm,a=pu,c=">",u=">=";break;case"<":s=pu,i=fm,a=hu,c="<",u="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(um(r,e,n))return!1;for(let o=0;o<e.set.length;++o){let l=e.set[o],d=null,y=null;if(l.forEach(m=>{m.semver===om&&(m=new mu(">=0.0.0")),d=d||m,y=y||m,s(m.semver,d.semver,n)?d=m:a(m.semver,y.semver,n)&&(y=m)}),d.operator===c||d.operator===u||(!y.operator||y.operator===c)&&i(r,y.semver))return!1;if(y.operator===u&&a(r,y.semver))return!1}return!0};gu.exports=dm});var _u=_((tb,vu)=>{var hm=ts(),pm=(r,e,t)=>hm(r,e,">",t);vu.exports=pm});var $u=_((rb,yu)=>{var mm=ts(),gm=(r,e,t)=>mm(r,e,"<",t);yu.exports=gm});var bu=_((nb,wu)=>{var Eu=Ue(),vm=(r,e,t)=>(r=new Eu(r,t),e=new Eu(e,t),r.intersects(e));wu.exports=vm});var Ou=_((sb,Su)=>{var _m=sn(),ym=He();Su.exports=(r,e,t)=>{let n=[],s=null,i=null,a=r.sort((l,d)=>ym(l,d,t));for(let l of a)_m(l,e,t)?(i=l,s||(s=l)):(i&&n.push([s,i]),i=null,s=null);s&&n.push([s,null]);let c=[];for(let[l,d]of n)l===d?c.push(l):!d&&l===a[0]?c.push("*"):d?l===a[0]?c.push(`<=${d}`):c.push(`${l} - ${d}`):c.push(`>=${l}`);let u=c.join(" || "),o=typeof e.raw=="string"?e.raw:String(e);return u.length<o.length?u:e}});var Iu=_((ib,Nu)=>{var Pu=Ue(),rs=rn(),{ANY:ii}=rs,an=sn(),ai=He(),$m=(r,e,t={})=>{if(r===e)return!0;r=new Pu(r,t),e=new Pu(e,t);let n=!1;e:for(let s of r.set){for(let i of e.set){let a=Em(s,i,t);if(n=n||a!==null,a)continue e}if(n)return!1}return!0},Em=(r,e,t)=>{if(r===e)return!0;if(r.length===1&&r[0].semver===ii){if(e.length===1&&e[0].semver===ii)return!0;t.includePrerelease?r=[new rs(">=0.0.0-0")]:r=[new rs(">=0.0.0")]}if(e.length===1&&e[0].semver===ii){if(t.includePrerelease)return!0;e=[new rs(">=0.0.0")]}let n=new Set,s,i;for(let m of r)m.operator===">"||m.operator===">="?s=Ru(s,m,t):m.operator==="<"||m.operator==="<="?i=Cu(i,m,t):n.add(m.semver);if(n.size>1)return null;let a;if(s&&i){if(a=ai(s.semver,i.semver,t),a>0)return null;if(a===0&&(s.operator!==">="||i.operator!=="<="))return null}for(let m of n){if(s&&!an(m,String(s),t)||i&&!an(m,String(i),t))return null;for(let $ of e)if(!an(m,String($),t))return!1;return!0}let c,u,o,l,d=i&&!t.includePrerelease&&i.semver.prerelease.length?i.semver:!1,y=s&&!t.includePrerelease&&s.semver.prerelease.length?s.semver:!1;d&&d.prerelease.length===1&&i.operator==="<"&&d.prerelease[0]===0&&(d=!1);for(let m of e){if(l=l||m.operator===">"||m.operator===">=",o=o||m.operator==="<"||m.operator==="<=",s){if(y&&m.semver.prerelease&&m.semver.prerelease.length&&m.semver.major===y.major&&m.semver.minor===y.minor&&m.semver.patch===y.patch&&(y=!1),m.operator===">"||m.operator===">="){if(c=Ru(s,m,t),c===m&&c!==s)return!1}else if(s.operator===">="&&!an(s.semver,String(m),t))return!1}if(i){if(d&&m.semver.prerelease&&m.semver.prerelease.length&&m.semver.major===d.major&&m.semver.minor===d.minor&&m.semver.patch===d.patch&&(d=!1),m.operator==="<"||m.operator==="<="){if(u=Cu(i,m,t),u===m&&u!==i)return!1}else if(i.operator==="<="&&!an(i.semver,String(m),t))return!1}if(!m.operator&&(i||s)&&a!==0)return!1}return!(s&&o&&!i&&a!==0||i&&l&&!s&&a!==0||y||d)},Ru=(r,e,t)=>{if(!r)return e;let n=ai(r.semver,e.semver,t);return n>0?r:n<0||e.operator===">"&&r.operator===">="?e:r},Cu=(r,e,t)=>{if(!r)return e;let n=ai(r.semver,e.semver,t);return n<0?r:n>0||e.operator==="<"&&r.operator==="<="?e:r};Nu.exports=$m});var qu=_((ab,Au)=>{var oi=Mt(),wm=Jr(),bm=ge(),Tu=Ws(),Sm=Ft(),Om=Qo(),Pm=tc(),Rm=sc(),Cm=lc(),Nm=dc(),Im=pc(),Tm=gc(),Am=_c(),qm=He(),Dm=$c(),jm=wc(),km=Wn(),xm=Pc(),Lm=Cc(),Mm=Qr(),Fm=Bn(),Vm=Xn(),Hm=Bs(),Um=Jn(),Gm=Yn(),zm=Js(),Km=kc(),Xm=rn(),Wm=Ue(),Bm=sn(),Jm=nu(),Ym=iu(),Zm=ou(),Qm=lu(),eg=du(),tg=ts(),rg=_u(),ng=$u(),sg=bu(),ig=Ou(),ag=Iu();Au.exports={parse:Sm,valid:Om,clean:Pm,inc:Rm,diff:Cm,major:Nm,minor:Im,patch:Tm,prerelease:Am,compare:qm,rcompare:Dm,compareLoose:jm,compareBuild:km,sort:xm,rsort:Lm,gt:Mm,lt:Fm,eq:Vm,neq:Hm,gte:Um,lte:Gm,cmp:zm,coerce:Km,Comparator:Xm,Range:Wm,satisfies:Bm,toComparators:Jm,maxSatisfying:Ym,minSatisfying:Zm,minVersion:Qm,validRange:eg,outside:tg,gtr:rg,ltr:ng,intersects:sg,simplifyRange:ig,subset:ag,SemVer:bm,re:oi.re,src:oi.src,tokens:oi.t,SEMVER_SPEC_VERSION:wm.SEMVER_SPEC_VERSION,compareIdentifiers:Tu.compareIdentifiers,rcompareIdentifiers:Tu.rcompareIdentifiers}});var vt=_(je=>{"use strict";var og=je&&je.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t);var s=Object.getOwnPropertyDescriptor(e,t);(!s||("get"in s?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return e[t]}}),Object.defineProperty(r,n,s)}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),cg=je&&je.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),ug=je&&je.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&og(e,r,t);return cg(e,r),e},Du=je&&je.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(je,"__esModule",{value:!0});je.getCoreVersion=void 0;var ju=Du(require("path")),ku=Du(require("fs")),ci=ug(require("@serverless-devs/core")),lg=qu(),xu=ju.default.join(ci.getRootHome(),"cache","core"),ui=ju.default.join(xu,"package.json");function fg(){if(ku.default.existsSync(ui)){var r=require("@serverless-devs/core/package.json").version,e=Lu();return lg.gt(e,r)?require(xu):ci}return ci}function Lu(){return ku.default.existsSync(ui)?require(ui).version:void 0}je.getCoreVersion=Lu;je.default=fg()});var di=_(Re=>{"use strict";var dg=Re&&Re.__awaiter||function(r,e,t,n){function s(i){return i instanceof t?i:new t(function(a){a(i)})}return new(t||(t=Promise))(function(i,a){function c(l){try{o(n.next(l))}catch(d){a(d)}}function u(l){try{o(n.throw(l))}catch(d){a(d)}}function o(l){l.done?i(l.value):s(l.value).then(c,u)}o((n=n.apply(r,e||[])).next())})},hg=Re&&Re.__generator||function(r,e){var t={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,s,i,a;return a={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function c(o){return function(l){return u([o,l])}}function u(o){if(n)throw new TypeError("Generator is already executing.");for(;t;)try{if(n=1,s&&(i=o[0]&2?s.return:o[0]?s.throw||((i=s.return)&&i.call(s),0):s.next)&&!(i=i.call(s,o[1])).done)return i;switch(s=0,i&&(o=[o[0]&2,i.value]),o[0]){case 0:case 1:i=o;break;case 4:return t.label++,{value:o[1],done:!1};case 5:t.label++,s=o[1],o=[0];continue;case 7:o=t.ops.pop(),t.trys.pop();continue;default:if(i=t.trys,!(i=i.length>0&&i[i.length-1])&&(o[0]===6||o[0]===2)){t=0;continue}if(o[0]===3&&(!i||o[1]>i[0]&&o[1]<i[3])){t.label=o[1];break}if(o[0]===6&&t.label<i[1]){t.label=i[1],i=o;break}if(i&&t.label<i[2]){t.label=i[2],t.ops.push(o);break}i[2]&&t.ops.pop(),t.trys.pop();continue}o=e.call(r,t)}catch(l){o=[6,l],s=0}finally{n=i=0}if(o[0]&5)throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}},Mu=Re&&Re.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Re,"__esModule",{value:!0});Re.handlerProfileFile=Re.getConfig=Re.setConfig=void 0;var Fu=Mu(require("path")),fi=Mu(vt()),it=fi.default.fse,ns=fi.default.jsyaml,li=fi.default.getRootHome;function pg(r){var e=Hu();it.writeFileSync(e,ns.dump(r))}function Vu(){var r=Hu();if(!it.existsSync(r))return{};try{var e=ns.load(it.readFileSync(r,"utf8"))||{};return e}catch(t){throw t}}function Hu(){var r=Fu.default.join(li(),"set-config.yml");return it.existsSync(r)||it.createFileSync(r),r}function mg(r,e){var t=Vu();t[r]=e,pg(t)}Re.setConfig=mg;function gg(r,e){var t=Vu();return t[r]||e}Re.getConfig=gg;function vg(r){return dg(this,void 0,void 0,function(){var e,t,n,s,i,a,c;return hg(this,function(u){switch(u.label){case 0:if(e=r.filePath||"set-config.yml",t=Fu.default.join(li(),e),n=it.existsSync(t),s={},n)return[3,5];i=li(),u.label=1;case 1:return u.trys.push([1,2,,4]),it.statSync(i),[3,4];case 2:return a=u.sent(),[4,it.mkdirSync(i)];case 3:return u.sent(),[3,4];case 4:return[3,6];case 5:try{s=ns.load(it.readFileSync(t,"utf8"))||{}}catch(o){throw o}u.label=6;case 6:return r.read?[2,s]:(c=r.configKey||"",s[c]=r.data,[4,it.writeFileSync(t,ns.dump(s))]);case 7:return u.sent(),[2,s]}})})}Re.handlerProfileFile=vg});var ss=_(on=>{"use strict";var _g=on&&on.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(on,"__esModule",{value:!0});var yg=_g(vt()),$g=yg.default.Logger,hi=new $g("S-CLI");hi.success=function(r){return hi.log(r,"green")};on.default=hi});var Uu=_((lb,Eg)=>{Eg.exports={name:"@serverless-devs/s",version:"2.1.7",description:"Serverless devs tool, serverless developer tool, supports Alibaba cloud, AWS, azure, baidu cloud, Huawei cloud, Google cloud and Tencent cloud.",homepage:"https://www.serverless-devs.com",keywords:["serverless","alibaba","tencent","azure","baidu","huawei","google","function","faas","serverless-devs"],publishConfig:{access:"public",registry:"https://registry.npmjs.org"},license:"Apache 2.0",repository:{type:"git",url:"https://github.com/Serverless-Devs/Serverless-Devs"},bugs:{url:"https://github.com/Serverless-Devs/Serverless-Devs/issues"},scripts:{start:"npm run watch",prewatch:"rm -rf lib/* && cp -r ./src/daemon ./lib",watch:"tsc -w",test:"jest test/special-command.test",prebuild:"rm -rf lib/*",build:"tsc && cp -r ./src/daemon ./lib",postbuild:"./shell/postbuild.sh","test:cov":"jest --coverage",lint:"npm run typecheck && f2elint scan -i src",fix:"f2elint fix",typecheck:"npx tsc -p tsconfig.json --noEmit",update:"rm -rf yarn.lock && rm -rf package-lock.json && rm -rf node_modules && yarn",beta:"npm publish --tag=beta"},main:"./lib/index.js",bin:{s:"bin/s"},devDependencies:{"@serverless-devs/commander":"^6.0.0","@types/jest":"^27.4.0","@types/node":"^14.0.23","@typescript-eslint/eslint-plugin":"^4.14.1","@typescript-eslint/parser":"^4.14.1",ajv:"^8.10.0","babel-eslint":"^10.1.0",boxen:"^5.0.0",dotenv:"^10.0.0",esbuild:"^0.14.0",eslint:"^7.7.0","eslint-config-prettier":"^7.2.0","eslint-plugin-import":"^2.20.1","eslint-plugin-prettier":"^3.1.2","global-agent":"^3.0.0",husky:"^4.2.3",inquirer:"8.2.0","inquirer-autocomplete-prompt":"^1.3.0",jest:"^27.4.7","latest-version":"^5.1.0","lint-staged":"^10.0.8",open:"^8.4.0","os-locale":"5.0.0",prettier:"^2.2.1",semver:"^7.3.5","semver-diff":"^3.1.1","ts-jest":"^27.1.3","ts-node":"^9.1.1",typescript:"^4.1.3"},"lint-staged":{"**/*.{js,jsx,ts}":"f2elint exec eslint"},dependencies:{"@serverless-devs/core":"latest","@serverless-devs/ui":"latest"}}});var mi=_(N=>{"use strict";var wg=N&&N.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t);var s=Object.getOwnPropertyDescriptor(e,t);(!s||("get"in s?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return e[t]}}),Object.defineProperty(r,n,s)}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),bg=N&&N.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),Sg=N&&N.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&wg(e,r,t);return bg(e,r),e},_r=N&&N.__awaiter||function(r,e,t,n){function s(i){return i instanceof t?i:new t(function(a){a(i)})}return new(t||(t=Promise))(function(i,a){function c(l){try{o(n.next(l))}catch(d){a(d)}}function u(l){try{o(n.throw(l))}catch(d){a(d)}}function o(l){l.done?i(l.value):s(l.value).then(c,u)}o((n=n.apply(r,e||[])).next())})},yr=N&&N.__generator||function(r,e){var t={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,s,i,a;return a={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function c(o){return function(l){return u([o,l])}}function u(o){if(n)throw new TypeError("Generator is already executing.");for(;t;)try{if(n=1,s&&(i=o[0]&2?s.return:o[0]?s.throw||((i=s.return)&&i.call(s),0):s.next)&&!(i=i.call(s,o[1])).done)return i;switch(s=0,i&&(o=[o[0]&2,i.value]),o[0]){case 0:case 1:i=o;break;case 4:return t.label++,{value:o[1],done:!1};case 5:t.label++,s=o[1],o=[0];continue;case 7:o=t.ops.pop(),t.trys.pop();continue;default:if(i=t.trys,!(i=i.length>0&&i[i.length-1])&&(o[0]===6||o[0]===2)){t=0;continue}if(o[0]===3&&(!i||o[1]>i[0]&&o[1]<i[3])){t.label=o[1];break}if(o[0]===6&&t.label<i[1]){t.label=i[1],i=o;break}if(i&&t.label<i[2]){t.label=i[2],t.ops.push(o);break}i[2]&&t.ops.pop(),t.trys.pop();continue}o=e.call(r,t)}catch(l){o=[6,l],s=0}finally{n=i=0}if(o[0]&5)throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}},is=N&&N.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(N,"__esModule",{value:!0});N.specifyServiceHelp=N.getTempCommandStr=N.emoji=N.mark=N.replaceTemplate=N.replaceFun=N.getLang=N.printn=N.getFolderSize=N.getVersion=N.aiRequest=N.getCredentialWithAll=N.getCredentialWithExisted=N.getProcessArgv=N.bgRed=N.yellow=N.red=void 0;var Og=is(require("path")),cn=is(require("fs")),Pg=is(require("os")),we=Sg(vt()),Rg=di(),vr=is(ss()),Gu=Uu(),$r=we.default.colors,Cg=we.default.got,Ng=we.default.isDocker,Ig=we.default.isCiCdEnv,Ot=we.default.lodash,zu=we.default.publishHelp,Tg=Ot.get,Ag=Ot.trim,qg=Ot.assign,Dg=Ot.filter,Ku=Ot.includes,jg=Ot.omit,kg=Ot.isPlainObject,xg=Ot.isEmpty,Lg=$r.underline,Mg=$r.bold;N.red=$r.hex("#fd5750");N.yellow=$r.hex("#F3F99D");N.bgRed=$r.hex("#000").bgHex("#fd5750");var Fg=function(){var r=process.env.serverless_devs_temp_argv;try{var e=JSON.parse(r),t=we.default.getGlobalArgs(e);return process.argv=process.argv.slice(0,2).concat(t._argsObj),qg({},t,{noHelpArgv:process.argv.slice(0,2).concat(Dg(t._argsObj,function(n){return!Ku(["-h","--help"],n)}))})}catch{return{}}};N.getProcessArgv=Fg;var Vg=function(r){return _r(void 0,void 0,void 0,function(){var e,t;return yr(this,function(n){switch(n.label){case 0:return[4,we.default.getCredentialAliasList()];case 1:return e=n.sent(),Ku(e,r)?[4,we.default.getCredential(r)]:[3,3];case 2:return t=n.sent(),[2,t];case 3:return[2]}})})};N.getCredentialWithExisted=Vg;var Hg=function(){return _r(void 0,void 0,void 0,function(){var r,e,t,n,s,i;return yr(this,function(a){switch(a.label){case 0:return[4,we.default.getCredentialAliasList()];case 1:if(r=a.sent(),!(r.length>0))return[3,6];e={},t=0,n=r,a.label=2;case 2:return t<n.length?(s=n[t],[4,we.default.getCredential(s)]):[3,5];case 3:i=a.sent(),e[i.Alias]=jg(i,"Alias"),a.label=4;case 4:return t++,[3,2];case 5:return[2,e];case 6:return[2]}})})};N.getCredentialWithAll=Hg;var Ug=function(r,e){return e===void 0&&(e="unknow"),_r(void 0,void 0,void 0,function(){var t,n,s,i;return yr(this,function(a){switch(a.label){case 0:return a.trys.push([0,2,,3]),t=(0,Rg.getConfig)("analysis"),t!=="enable"?[2]:Ng()||Ig()?[2]:[4,Cg("http://qaapis.devsapp.cn/apis/v1/search?category=".concat(e,"&code=TypeError&s=").concat(r),{timeout:2e3,json:!0})];case 1:return n=a.sent(),s=Tg(n.body,"shorturl"),s&&vr.default.log(`AI Tips:
|
|
1
|
+
"use strict";var y=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var Br=y((ZE,wo)=>{var Zd="2.0.0",Qd=Number.MAX_SAFE_INTEGER||9007199254740991,eh=16;wo.exports={SEMVER_SPEC_VERSION:Zd,MAX_LENGTH:256,MAX_SAFE_INTEGER:Qd,MAX_SAFE_COMPONENT_LENGTH:eh}});var Wr=y((QE,bo)=>{var th=typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...t)=>console.error("SEMVER",...t):()=>{};bo.exports=th});var Ft=y((Ot,So)=>{var{MAX_SAFE_COMPONENT_LENGTH:Gs}=Br(),rh=Wr();Ot=So.exports={};var nh=Ot.re=[],P=Ot.src=[],O=Ot.t={},sh=0,A=(t,e,r)=>{let n=sh++;rh(t,n,e),O[t]=n,P[n]=e,nh[n]=new RegExp(e,r?"g":void 0)};A("NUMERICIDENTIFIER","0|[1-9]\\d*");A("NUMERICIDENTIFIERLOOSE","[0-9]+");A("NONNUMERICIDENTIFIER","\\d*[a-zA-Z-][a-zA-Z0-9-]*");A("MAINVERSION",`(${P[O.NUMERICIDENTIFIER]})\\.(${P[O.NUMERICIDENTIFIER]})\\.(${P[O.NUMERICIDENTIFIER]})`);A("MAINVERSIONLOOSE",`(${P[O.NUMERICIDENTIFIERLOOSE]})\\.(${P[O.NUMERICIDENTIFIERLOOSE]})\\.(${P[O.NUMERICIDENTIFIERLOOSE]})`);A("PRERELEASEIDENTIFIER",`(?:${P[O.NUMERICIDENTIFIER]}|${P[O.NONNUMERICIDENTIFIER]})`);A("PRERELEASEIDENTIFIERLOOSE",`(?:${P[O.NUMERICIDENTIFIERLOOSE]}|${P[O.NONNUMERICIDENTIFIER]})`);A("PRERELEASE",`(?:-(${P[O.PRERELEASEIDENTIFIER]}(?:\\.${P[O.PRERELEASEIDENTIFIER]})*))`);A("PRERELEASELOOSE",`(?:-?(${P[O.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${P[O.PRERELEASEIDENTIFIERLOOSE]})*))`);A("BUILDIDENTIFIER","[0-9A-Za-z-]+");A("BUILD",`(?:\\+(${P[O.BUILDIDENTIFIER]}(?:\\.${P[O.BUILDIDENTIFIER]})*))`);A("FULLPLAIN",`v?${P[O.MAINVERSION]}${P[O.PRERELEASE]}?${P[O.BUILD]}?`);A("FULL",`^${P[O.FULLPLAIN]}$`);A("LOOSEPLAIN",`[v=\\s]*${P[O.MAINVERSIONLOOSE]}${P[O.PRERELEASELOOSE]}?${P[O.BUILD]}?`);A("LOOSE",`^${P[O.LOOSEPLAIN]}$`);A("GTLT","((?:<|>)?=?)");A("XRANGEIDENTIFIERLOOSE",`${P[O.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);A("XRANGEIDENTIFIER",`${P[O.NUMERICIDENTIFIER]}|x|X|\\*`);A("XRANGEPLAIN",`[v=\\s]*(${P[O.XRANGEIDENTIFIER]})(?:\\.(${P[O.XRANGEIDENTIFIER]})(?:\\.(${P[O.XRANGEIDENTIFIER]})(?:${P[O.PRERELEASE]})?${P[O.BUILD]}?)?)?`);A("XRANGEPLAINLOOSE",`[v=\\s]*(${P[O.XRANGEIDENTIFIERLOOSE]})(?:\\.(${P[O.XRANGEIDENTIFIERLOOSE]})(?:\\.(${P[O.XRANGEIDENTIFIERLOOSE]})(?:${P[O.PRERELEASELOOSE]})?${P[O.BUILD]}?)?)?`);A("XRANGE",`^${P[O.GTLT]}\\s*${P[O.XRANGEPLAIN]}$`);A("XRANGELOOSE",`^${P[O.GTLT]}\\s*${P[O.XRANGEPLAINLOOSE]}$`);A("COERCE",`(^|[^\\d])(\\d{1,${Gs}})(?:\\.(\\d{1,${Gs}}))?(?:\\.(\\d{1,${Gs}}))?(?:$|[^\\d])`);A("COERCERTL",P[O.COERCE],!0);A("LONETILDE","(?:~>?)");A("TILDETRIM",`(\\s*)${P[O.LONETILDE]}\\s+`,!0);Ot.tildeTrimReplace="$1~";A("TILDE",`^${P[O.LONETILDE]}${P[O.XRANGEPLAIN]}$`);A("TILDELOOSE",`^${P[O.LONETILDE]}${P[O.XRANGEPLAINLOOSE]}$`);A("LONECARET","(?:\\^)");A("CARETTRIM",`(\\s*)${P[O.LONECARET]}\\s+`,!0);Ot.caretTrimReplace="$1^";A("CARET",`^${P[O.LONECARET]}${P[O.XRANGEPLAIN]}$`);A("CARETLOOSE",`^${P[O.LONECARET]}${P[O.XRANGEPLAINLOOSE]}$`);A("COMPARATORLOOSE",`^${P[O.GTLT]}\\s*(${P[O.LOOSEPLAIN]})$|^$`);A("COMPARATOR",`^${P[O.GTLT]}\\s*(${P[O.FULLPLAIN]})$|^$`);A("COMPARATORTRIM",`(\\s*)${P[O.GTLT]}\\s*(${P[O.LOOSEPLAIN]}|${P[O.XRANGEPLAIN]})`,!0);Ot.comparatorTrimReplace="$1$2$3";A("HYPHENRANGE",`^\\s*(${P[O.XRANGEPLAIN]})\\s+-\\s+(${P[O.XRANGEPLAIN]})\\s*$`);A("HYPHENRANGELOOSE",`^\\s*(${P[O.XRANGEPLAINLOOSE]})\\s+-\\s+(${P[O.XRANGEPLAINLOOSE]})\\s*$`);A("STAR","(<|>)?=?\\s*\\*");A("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$");A("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")});var Yr=y((ew,Po)=>{var ih=["includePrerelease","loose","rtl"],ah=t=>t?typeof t!="object"?{loose:!0}:ih.filter(e=>t[e]).reduce((e,r)=>(e[r]=!0,e),{}):{};Po.exports=ah});var Hs=y((tw,No)=>{var Oo=/^[0-9]+$/,Ro=(t,e)=>{let r=Oo.test(t),n=Oo.test(e);return r&&n&&(t=+t,e=+e),t===e?0:r&&!n?-1:n&&!r?1:t<e?-1:1},oh=(t,e)=>Ro(e,t);No.exports={compareIdentifiers:Ro,rcompareIdentifiers:oh}});var ve=y((rw,Co)=>{var Vn=Wr(),{MAX_LENGTH:Io,MAX_SAFE_INTEGER:Un}=Br(),{re:To,t:qo}=Ft(),ch=Yr(),{compareIdentifiers:hr}=Hs(),Ae=class{constructor(e,r){if(r=ch(r),e instanceof Ae){if(e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease)return e;e=e.version}else if(typeof e!="string")throw new TypeError(`Invalid Version: ${e}`);if(e.length>Io)throw new TypeError(`version is longer than ${Io} characters`);Vn("SemVer",e,r),this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease;let n=e.trim().match(r.loose?To[qo.LOOSE]:To[qo.FULL]);if(!n)throw new TypeError(`Invalid Version: ${e}`);if(this.raw=e,this.major=+n[1],this.minor=+n[2],this.patch=+n[3],this.major>Un||this.major<0)throw new TypeError("Invalid major version");if(this.minor>Un||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>Un||this.patch<0)throw new TypeError("Invalid patch version");n[4]?this.prerelease=n[4].split(".").map(s=>{if(/^[0-9]+$/.test(s)){let i=+s;if(i>=0&&i<Un)return i}return s}):this.prerelease=[],this.build=n[5]?n[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(e){if(Vn("SemVer.compare",this.version,this.options,e),!(e instanceof Ae)){if(typeof e=="string"&&e===this.version)return 0;e=new Ae(e,this.options)}return e.version===this.version?0:this.compareMain(e)||this.comparePre(e)}compareMain(e){return e instanceof Ae||(e=new Ae(e,this.options)),hr(this.major,e.major)||hr(this.minor,e.minor)||hr(this.patch,e.patch)}comparePre(e){if(e instanceof Ae||(e=new Ae(e,this.options)),this.prerelease.length&&!e.prerelease.length)return-1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;let r=0;do{let n=this.prerelease[r],s=e.prerelease[r];if(Vn("prerelease compare",r,n,s),n===void 0&&s===void 0)return 0;if(s===void 0)return 1;if(n===void 0)return-1;if(n===s)continue;return hr(n,s)}while(++r)}compareBuild(e){e instanceof Ae||(e=new Ae(e,this.options));let r=0;do{let n=this.build[r],s=e.build[r];if(Vn("prerelease compare",r,n,s),n===void 0&&s===void 0)return 0;if(s===void 0)return 1;if(n===void 0)return-1;if(n===s)continue;return hr(n,s)}while(++r)}inc(e,r){switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",r);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",r);break;case"prepatch":this.prerelease.length=0,this.inc("patch",r),this.inc("pre",r);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",r),this.inc("pre",r);break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":if(this.prerelease.length===0)this.prerelease=[0];else{let n=this.prerelease.length;for(;--n>=0;)typeof this.prerelease[n]=="number"&&(this.prerelease[n]++,n=-2);n===-1&&this.prerelease.push(0)}r&&(hr(this.prerelease[0],r)===0?isNaN(this.prerelease[1])&&(this.prerelease=[r,0]):this.prerelease=[r,0]);break;default:throw new Error(`invalid increment argument: ${e}`)}return this.format(),this.raw=this.version,this}};Co.exports=Ae});var Vt=y((nw,ko)=>{var{MAX_LENGTH:uh}=Br(),{re:jo,t:Do}=Ft(),Ao=ve(),lh=Yr(),fh=(t,e)=>{if(e=lh(e),t instanceof Ao)return t;if(typeof t!="string"||t.length>uh||!(e.loose?jo[Do.LOOSE]:jo[Do.FULL]).test(t))return null;try{return new Ao(t,e)}catch{return null}};ko.exports=fh});var Mo=y((sw,Lo)=>{var dh=Vt(),hh=(t,e)=>{let r=dh(t,e);return r?r.version:null};Lo.exports=hh});var Fo=y((iw,xo)=>{var ph=Vt(),mh=(t,e)=>{let r=ph(t.trim().replace(/^[=v]+/,""),e);return r?r.version:null};xo.exports=mh});var Go=y((aw,Uo)=>{var Vo=ve(),vh=(t,e,r,n)=>{typeof r=="string"&&(n=r,r=void 0);try{return new Vo(t instanceof Vo?t.version:t,r).inc(e,n).version}catch{return null}};Uo.exports=vh});var Fe=y((ow,zo)=>{var Ho=ve(),gh=(t,e,r)=>new Ho(t,r).compare(new Ho(e,r));zo.exports=gh});var Gn=y((cw,Ko)=>{var yh=Fe(),_h=(t,e,r)=>yh(t,e,r)===0;Ko.exports=_h});var Wo=y((uw,Bo)=>{var Xo=Vt(),$h=Gn(),Eh=(t,e)=>{if($h(t,e))return null;{let r=Xo(t),n=Xo(e),s=r.prerelease.length||n.prerelease.length,i=s?"pre":"",a=s?"prerelease":"";for(let c in r)if((c==="major"||c==="minor"||c==="patch")&&r[c]!==n[c])return i+c;return a}};Bo.exports=Eh});var Jo=y((lw,Yo)=>{var wh=ve(),bh=(t,e)=>new wh(t,e).major;Yo.exports=bh});var Qo=y((fw,Zo)=>{var Sh=ve(),Ph=(t,e)=>new Sh(t,e).minor;Zo.exports=Ph});var tc=y((dw,ec)=>{var Oh=ve(),Rh=(t,e)=>new Oh(t,e).patch;ec.exports=Rh});var nc=y((hw,rc)=>{var Nh=Vt(),Ih=(t,e)=>{let r=Nh(t,e);return r&&r.prerelease.length?r.prerelease:null};rc.exports=Ih});var ic=y((pw,sc)=>{var Th=Fe(),qh=(t,e,r)=>Th(e,t,r);sc.exports=qh});var oc=y((mw,ac)=>{var Ch=Fe(),jh=(t,e)=>Ch(t,e,!0);ac.exports=jh});var Hn=y((vw,uc)=>{var cc=ve(),Dh=(t,e,r)=>{let n=new cc(t,r),s=new cc(e,r);return n.compare(s)||n.compareBuild(s)};uc.exports=Dh});var fc=y((gw,lc)=>{var Ah=Hn(),kh=(t,e)=>t.sort((r,n)=>Ah(r,n,e));lc.exports=kh});var hc=y((yw,dc)=>{var Lh=Hn(),Mh=(t,e)=>t.sort((r,n)=>Lh(n,r,e));dc.exports=Mh});var Jr=y((_w,pc)=>{var xh=Fe(),Fh=(t,e,r)=>xh(t,e,r)>0;pc.exports=Fh});var zn=y(($w,mc)=>{var Vh=Fe(),Uh=(t,e,r)=>Vh(t,e,r)<0;mc.exports=Uh});var zs=y((Ew,vc)=>{var Gh=Fe(),Hh=(t,e,r)=>Gh(t,e,r)!==0;vc.exports=Hh});var Kn=y((ww,gc)=>{var zh=Fe(),Kh=(t,e,r)=>zh(t,e,r)>=0;gc.exports=Kh});var Xn=y((bw,yc)=>{var Xh=Fe(),Bh=(t,e,r)=>Xh(t,e,r)<=0;yc.exports=Bh});var Ks=y((Sw,_c)=>{var Wh=Gn(),Yh=zs(),Jh=Jr(),Zh=Kn(),Qh=zn(),ep=Xn(),tp=(t,e,r,n)=>{switch(e){case"===":return typeof t=="object"&&(t=t.version),typeof r=="object"&&(r=r.version),t===r;case"!==":return typeof t=="object"&&(t=t.version),typeof r=="object"&&(r=r.version),t!==r;case"":case"=":case"==":return Wh(t,r,n);case"!=":return Yh(t,r,n);case">":return Jh(t,r,n);case">=":return Zh(t,r,n);case"<":return Qh(t,r,n);case"<=":return ep(t,r,n);default:throw new TypeError(`Invalid operator: ${e}`)}};_c.exports=tp});var Ec=y((Pw,$c)=>{var rp=ve(),np=Vt(),{re:Bn,t:Wn}=Ft(),sp=(t,e)=>{if(t instanceof rp)return t;if(typeof t=="number"&&(t=String(t)),typeof t!="string")return null;e=e||{};let r=null;if(!e.rtl)r=t.match(Bn[Wn.COERCE]);else{let n;for(;(n=Bn[Wn.COERCERTL].exec(t))&&(!r||r.index+r[0].length!==t.length);)(!r||n.index+n[0].length!==r.index+r[0].length)&&(r=n),Bn[Wn.COERCERTL].lastIndex=n.index+n[1].length+n[2].length;Bn[Wn.COERCERTL].lastIndex=-1}return r===null?null:np(`${r[2]}.${r[3]||"0"}.${r[4]||"0"}`,e)};$c.exports=sp});var bc=y((Ow,wc)=>{"use strict";wc.exports=function(t){t.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}});var Pc=y((Rw,Sc)=>{"use strict";Sc.exports=X;X.Node=Ut;X.create=X;function X(t){var e=this;if(e instanceof X||(e=new X),e.tail=null,e.head=null,e.length=0,t&&typeof t.forEach=="function")t.forEach(function(s){e.push(s)});else if(arguments.length>0)for(var r=0,n=arguments.length;r<n;r++)e.push(arguments[r]);return e}X.prototype.removeNode=function(t){if(t.list!==this)throw new Error("removing node which does not belong to this list");var e=t.next,r=t.prev;return e&&(e.prev=r),r&&(r.next=e),t===this.head&&(this.head=e),t===this.tail&&(this.tail=r),t.list.length--,t.next=null,t.prev=null,t.list=null,e};X.prototype.unshiftNode=function(t){if(t!==this.head){t.list&&t.list.removeNode(t);var e=this.head;t.list=this,t.next=e,e&&(e.prev=t),this.head=t,this.tail||(this.tail=t),this.length++}};X.prototype.pushNode=function(t){if(t!==this.tail){t.list&&t.list.removeNode(t);var e=this.tail;t.list=this,t.prev=e,e&&(e.next=t),this.tail=t,this.head||(this.head=t),this.length++}};X.prototype.push=function(){for(var t=0,e=arguments.length;t<e;t++)ap(this,arguments[t]);return this.length};X.prototype.unshift=function(){for(var t=0,e=arguments.length;t<e;t++)op(this,arguments[t]);return this.length};X.prototype.pop=function(){if(!!this.tail){var t=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,t}};X.prototype.shift=function(){if(!!this.head){var t=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,t}};X.prototype.forEach=function(t,e){e=e||this;for(var r=this.head,n=0;r!==null;n++)t.call(e,r.value,n,this),r=r.next};X.prototype.forEachReverse=function(t,e){e=e||this;for(var r=this.tail,n=this.length-1;r!==null;n--)t.call(e,r.value,n,this),r=r.prev};X.prototype.get=function(t){for(var e=0,r=this.head;r!==null&&e<t;e++)r=r.next;if(e===t&&r!==null)return r.value};X.prototype.getReverse=function(t){for(var e=0,r=this.tail;r!==null&&e<t;e++)r=r.prev;if(e===t&&r!==null)return r.value};X.prototype.map=function(t,e){e=e||this;for(var r=new X,n=this.head;n!==null;)r.push(t.call(e,n.value,this)),n=n.next;return r};X.prototype.mapReverse=function(t,e){e=e||this;for(var r=new X,n=this.tail;n!==null;)r.push(t.call(e,n.value,this)),n=n.prev;return r};X.prototype.reduce=function(t,e){var r,n=this.head;if(arguments.length>1)r=e;else if(this.head)n=this.head.next,r=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var s=0;n!==null;s++)r=t(r,n.value,s),n=n.next;return r};X.prototype.reduceReverse=function(t,e){var r,n=this.tail;if(arguments.length>1)r=e;else if(this.tail)n=this.tail.prev,r=this.tail.value;else throw new TypeError("Reduce of empty list with no initial value");for(var s=this.length-1;n!==null;s--)r=t(r,n.value,s),n=n.prev;return r};X.prototype.toArray=function(){for(var t=new Array(this.length),e=0,r=this.head;r!==null;e++)t[e]=r.value,r=r.next;return t};X.prototype.toArrayReverse=function(){for(var t=new Array(this.length),e=0,r=this.tail;r!==null;e++)t[e]=r.value,r=r.prev;return t};X.prototype.slice=function(t,e){e=e||this.length,e<0&&(e+=this.length),t=t||0,t<0&&(t+=this.length);var r=new X;if(e<t||e<0)return r;t<0&&(t=0),e>this.length&&(e=this.length);for(var n=0,s=this.head;s!==null&&n<t;n++)s=s.next;for(;s!==null&&n<e;n++,s=s.next)r.push(s.value);return r};X.prototype.sliceReverse=function(t,e){e=e||this.length,e<0&&(e+=this.length),t=t||0,t<0&&(t+=this.length);var r=new X;if(e<t||e<0)return r;t<0&&(t=0),e>this.length&&(e=this.length);for(var n=this.length,s=this.tail;s!==null&&n>e;n--)s=s.prev;for(;s!==null&&n>t;n--,s=s.prev)r.push(s.value);return r};X.prototype.splice=function(t,e,...r){t>this.length&&(t=this.length-1),t<0&&(t=this.length+t);for(var n=0,s=this.head;s!==null&&n<t;n++)s=s.next;for(var i=[],n=0;s&&n<e;n++)i.push(s.value),s=this.removeNode(s);s===null&&(s=this.tail),s!==this.head&&s!==this.tail&&(s=s.prev);for(var n=0;n<r.length;n++)s=ip(this,s,r[n]);return i};X.prototype.reverse=function(){for(var t=this.head,e=this.tail,r=t;r!==null;r=r.prev){var n=r.prev;r.prev=r.next,r.next=n}return this.head=e,this.tail=t,this};function ip(t,e,r){var n=e===t.head?new Ut(r,null,e,t):new Ut(r,e,e.next,t);return n.next===null&&(t.tail=n),n.prev===null&&(t.head=n),t.length++,n}function ap(t,e){t.tail=new Ut(e,t.tail,null,t),t.head||(t.head=t.tail),t.length++}function op(t,e){t.head=new Ut(e,null,t.head,t),t.tail||(t.tail=t.head),t.length++}function Ut(t,e,r,n){if(!(this instanceof Ut))return new Ut(t,e,r,n);this.list=n,this.value=t,e?(e.next=this,this.prev=e):this.prev=null,r?(r.prev=this,this.next=r):this.next=null}try{bc()(X)}catch{}});var Tc=y((Nw,Ic)=>{"use strict";var cp=Pc(),Gt=Symbol("max"),$t=Symbol("length"),pr=Symbol("lengthCalculator"),Qr=Symbol("allowStale"),Ht=Symbol("maxAge"),_t=Symbol("dispose"),Oc=Symbol("noDisposeOnSet"),fe=Symbol("lruList"),Be=Symbol("cache"),Nc=Symbol("updateAgeOnGet"),Xs=()=>1,Ws=class{constructor(e){if(typeof e=="number"&&(e={max:e}),e||(e={}),e.max&&(typeof e.max!="number"||e.max<0))throw new TypeError("max must be a non-negative number");let r=this[Gt]=e.max||1/0,n=e.length||Xs;if(this[pr]=typeof n!="function"?Xs:n,this[Qr]=e.stale||!1,e.maxAge&&typeof e.maxAge!="number")throw new TypeError("maxAge must be a number");this[Ht]=e.maxAge||0,this[_t]=e.dispose,this[Oc]=e.noDisposeOnSet||!1,this[Nc]=e.updateAgeOnGet||!1,this.reset()}set max(e){if(typeof e!="number"||e<0)throw new TypeError("max must be a non-negative number");this[Gt]=e||1/0,Zr(this)}get max(){return this[Gt]}set allowStale(e){this[Qr]=!!e}get allowStale(){return this[Qr]}set maxAge(e){if(typeof e!="number")throw new TypeError("maxAge must be a non-negative number");this[Ht]=e,Zr(this)}get maxAge(){return this[Ht]}set lengthCalculator(e){typeof e!="function"&&(e=Xs),e!==this[pr]&&(this[pr]=e,this[$t]=0,this[fe].forEach(r=>{r.length=this[pr](r.value,r.key),this[$t]+=r.length})),Zr(this)}get lengthCalculator(){return this[pr]}get length(){return this[$t]}get itemCount(){return this[fe].length}rforEach(e,r){r=r||this;for(let n=this[fe].tail;n!==null;){let s=n.prev;Rc(this,e,n,r),n=s}}forEach(e,r){r=r||this;for(let n=this[fe].head;n!==null;){let s=n.next;Rc(this,e,n,r),n=s}}keys(){return this[fe].toArray().map(e=>e.key)}values(){return this[fe].toArray().map(e=>e.value)}reset(){this[_t]&&this[fe]&&this[fe].length&&this[fe].forEach(e=>this[_t](e.key,e.value)),this[Be]=new Map,this[fe]=new cp,this[$t]=0}dump(){return this[fe].map(e=>Yn(this,e)?!1:{k:e.key,v:e.value,e:e.now+(e.maxAge||0)}).toArray().filter(e=>e)}dumpLru(){return this[fe]}set(e,r,n){if(n=n||this[Ht],n&&typeof n!="number")throw new TypeError("maxAge must be a number");let s=n?Date.now():0,i=this[pr](r,e);if(this[Be].has(e)){if(i>this[Gt])return mr(this,this[Be].get(e)),!1;let l=this[Be].get(e).value;return this[_t]&&(this[Oc]||this[_t](e,l.value)),l.now=s,l.maxAge=n,l.value=r,this[$t]+=i-l.length,l.length=i,this.get(e),Zr(this),!0}let a=new Ys(e,r,i,s,n);return a.length>this[Gt]?(this[_t]&&this[_t](e,r),!1):(this[$t]+=a.length,this[fe].unshift(a),this[Be].set(e,this[fe].head),Zr(this),!0)}has(e){if(!this[Be].has(e))return!1;let r=this[Be].get(e).value;return!Yn(this,r)}get(e){return Bs(this,e,!0)}peek(e){return Bs(this,e,!1)}pop(){let e=this[fe].tail;return e?(mr(this,e),e.value):null}del(e){mr(this,this[Be].get(e))}load(e){this.reset();let r=Date.now();for(let n=e.length-1;n>=0;n--){let s=e[n],i=s.e||0;if(i===0)this.set(s.k,s.v);else{let a=i-r;a>0&&this.set(s.k,s.v,a)}}}prune(){this[Be].forEach((e,r)=>Bs(this,r,!1))}},Bs=(t,e,r)=>{let n=t[Be].get(e);if(n){let s=n.value;if(Yn(t,s)){if(mr(t,n),!t[Qr])return}else r&&(t[Nc]&&(n.value.now=Date.now()),t[fe].unshiftNode(n));return s.value}},Yn=(t,e)=>{if(!e||!e.maxAge&&!t[Ht])return!1;let r=Date.now()-e.now;return e.maxAge?r>e.maxAge:t[Ht]&&r>t[Ht]},Zr=t=>{if(t[$t]>t[Gt])for(let e=t[fe].tail;t[$t]>t[Gt]&&e!==null;){let r=e.prev;mr(t,e),e=r}},mr=(t,e)=>{if(e){let r=e.value;t[_t]&&t[_t](r.key,r.value),t[$t]-=r.length,t[Be].delete(r.key),t[fe].removeNode(e)}},Ys=class{constructor(e,r,n,s,i){this.key=e,this.value=r,this.length=n,this.now=s,this.maxAge=i||0}},Rc=(t,e,r,n)=>{let s=r.value;Yn(t,s)&&(mr(t,r),t[Qr]||(s=void 0)),s&&e.call(n,s.value,s.key,t)};Ic.exports=Ws});var Ve=y((Iw,Dc)=>{var zt=class{constructor(e,r){if(r=lp(r),e instanceof zt)return e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease?e:new zt(e.raw,r);if(e instanceof Js)return this.raw=e.value,this.set=[[e]],this.format(),this;if(this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease,this.raw=e,this.set=e.split("||").map(n=>this.parseRange(n.trim())).filter(n=>n.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${e}`);if(this.set.length>1){let n=this.set[0];if(this.set=this.set.filter(s=>!Cc(s[0])),this.set.length===0)this.set=[n];else if(this.set.length>1){for(let s of this.set)if(s.length===1&&mp(s[0])){this.set=[s];break}}}this.format()}format(){return this.range=this.set.map(e=>e.join(" ").trim()).join("||").trim(),this.range}toString(){return this.range}parseRange(e){e=e.trim();let n=`parseRange:${Object.keys(this.options).join(",")}:${e}`,s=qc.get(n);if(s)return s;let i=this.options.loose,a=i?Re[$e.HYPHENRANGELOOSE]:Re[$e.HYPHENRANGE];e=e.replace(a,Pp(this.options.includePrerelease)),ie("hyphen replace",e),e=e.replace(Re[$e.COMPARATORTRIM],dp),ie("comparator trim",e),e=e.replace(Re[$e.TILDETRIM],hp),e=e.replace(Re[$e.CARETTRIM],pp),e=e.split(/\s+/).join(" ");let c=e.split(" ").map(h=>vp(h,this.options)).join(" ").split(/\s+/).map(h=>Sp(h,this.options));i&&(c=c.filter(h=>(ie("loose invalid filter",h,this.options),!!h.match(Re[$e.COMPARATORLOOSE])))),ie("range list",c);let l=new Map,o=c.map(h=>new Js(h,this.options));for(let h of o){if(Cc(h))return[h];l.set(h.value,h)}l.size>1&&l.has("")&&l.delete("");let f=[...l.values()];return qc.set(n,f),f}intersects(e,r){if(!(e instanceof zt))throw new TypeError("a Range is required");return this.set.some(n=>jc(n,r)&&e.set.some(s=>jc(s,r)&&n.every(i=>s.every(a=>i.intersects(a,r)))))}test(e){if(!e)return!1;if(typeof e=="string")try{e=new fp(e,this.options)}catch{return!1}for(let r=0;r<this.set.length;r++)if(Op(this.set[r],e,this.options))return!0;return!1}};Dc.exports=zt;var up=Tc(),qc=new up({max:1e3}),lp=Yr(),Js=en(),ie=Wr(),fp=ve(),{re:Re,t:$e,comparatorTrimReplace:dp,tildeTrimReplace:hp,caretTrimReplace:pp}=Ft(),Cc=t=>t.value==="<0.0.0-0",mp=t=>t.value==="",jc=(t,e)=>{let r=!0,n=t.slice(),s=n.pop();for(;r&&n.length;)r=n.every(i=>s.intersects(i,e)),s=n.pop();return r},vp=(t,e)=>(ie("comp",t,e),t=_p(t,e),ie("caret",t),t=gp(t,e),ie("tildes",t),t=Ep(t,e),ie("xrange",t),t=bp(t,e),ie("stars",t),t),Ee=t=>!t||t.toLowerCase()==="x"||t==="*",gp=(t,e)=>t.trim().split(/\s+/).map(r=>yp(r,e)).join(" "),yp=(t,e)=>{let r=e.loose?Re[$e.TILDELOOSE]:Re[$e.TILDE];return t.replace(r,(n,s,i,a,c)=>{ie("tilde",t,n,s,i,a,c);let l;return Ee(s)?l="":Ee(i)?l=`>=${s}.0.0 <${+s+1}.0.0-0`:Ee(a)?l=`>=${s}.${i}.0 <${s}.${+i+1}.0-0`:c?(ie("replaceTilde pr",c),l=`>=${s}.${i}.${a}-${c} <${s}.${+i+1}.0-0`):l=`>=${s}.${i}.${a} <${s}.${+i+1}.0-0`,ie("tilde return",l),l})},_p=(t,e)=>t.trim().split(/\s+/).map(r=>$p(r,e)).join(" "),$p=(t,e)=>{ie("caret",t,e);let r=e.loose?Re[$e.CARETLOOSE]:Re[$e.CARET],n=e.includePrerelease?"-0":"";return t.replace(r,(s,i,a,c,l)=>{ie("caret",t,s,i,a,c,l);let o;return Ee(i)?o="":Ee(a)?o=`>=${i}.0.0${n} <${+i+1}.0.0-0`:Ee(c)?i==="0"?o=`>=${i}.${a}.0${n} <${i}.${+a+1}.0-0`:o=`>=${i}.${a}.0${n} <${+i+1}.0.0-0`:l?(ie("replaceCaret pr",l),i==="0"?a==="0"?o=`>=${i}.${a}.${c}-${l} <${i}.${a}.${+c+1}-0`:o=`>=${i}.${a}.${c}-${l} <${i}.${+a+1}.0-0`:o=`>=${i}.${a}.${c}-${l} <${+i+1}.0.0-0`):(ie("no pr"),i==="0"?a==="0"?o=`>=${i}.${a}.${c}${n} <${i}.${a}.${+c+1}-0`:o=`>=${i}.${a}.${c}${n} <${i}.${+a+1}.0-0`:o=`>=${i}.${a}.${c} <${+i+1}.0.0-0`),ie("caret return",o),o})},Ep=(t,e)=>(ie("replaceXRanges",t,e),t.split(/\s+/).map(r=>wp(r,e)).join(" ")),wp=(t,e)=>{t=t.trim();let r=e.loose?Re[$e.XRANGELOOSE]:Re[$e.XRANGE];return t.replace(r,(n,s,i,a,c,l)=>{ie("xRange",t,n,s,i,a,c,l);let o=Ee(i),f=o||Ee(a),h=f||Ee(c),_=h;return s==="="&&_&&(s=""),l=e.includePrerelease?"-0":"",o?s===">"||s==="<"?n="<0.0.0-0":n="*":s&&_?(f&&(a=0),c=0,s===">"?(s=">=",f?(i=+i+1,a=0,c=0):(a=+a+1,c=0)):s==="<="&&(s="<",f?i=+i+1:a=+a+1),s==="<"&&(l="-0"),n=`${s+i}.${a}.${c}${l}`):f?n=`>=${i}.0.0${l} <${+i+1}.0.0-0`:h&&(n=`>=${i}.${a}.0${l} <${i}.${+a+1}.0-0`),ie("xRange return",n),n})},bp=(t,e)=>(ie("replaceStars",t,e),t.trim().replace(Re[$e.STAR],"")),Sp=(t,e)=>(ie("replaceGTE0",t,e),t.trim().replace(Re[e.includePrerelease?$e.GTE0PRE:$e.GTE0],"")),Pp=t=>(e,r,n,s,i,a,c,l,o,f,h,_,v)=>(Ee(n)?r="":Ee(s)?r=`>=${n}.0.0${t?"-0":""}`:Ee(i)?r=`>=${n}.${s}.0${t?"-0":""}`:a?r=`>=${r}`:r=`>=${r}${t?"-0":""}`,Ee(o)?l="":Ee(f)?l=`<${+o+1}.0.0-0`:Ee(h)?l=`<${o}.${+f+1}.0-0`:_?l=`<=${o}.${f}.${h}-${_}`:t?l=`<${o}.${f}.${+h+1}-0`:l=`<=${l}`,`${r} ${l}`.trim()),Op=(t,e,r)=>{for(let n=0;n<t.length;n++)if(!t[n].test(e))return!1;if(e.prerelease.length&&!r.includePrerelease){for(let n=0;n<t.length;n++)if(ie(t[n].semver),t[n].semver!==Js.ANY&&t[n].semver.prerelease.length>0){let s=t[n].semver;if(s.major===e.major&&s.minor===e.minor&&s.patch===e.patch)return!0}return!1}return!0}});var en=y((Tw,xc)=>{var tn=Symbol("SemVer ANY"),vr=class{static get ANY(){return tn}constructor(e,r){if(r=Rp(r),e instanceof vr){if(e.loose===!!r.loose)return e;e=e.value}Qs("comparator",e,r),this.options=r,this.loose=!!r.loose,this.parse(e),this.semver===tn?this.value="":this.value=this.operator+this.semver.version,Qs("comp",this)}parse(e){let r=this.options.loose?Ac[kc.COMPARATORLOOSE]:Ac[kc.COMPARATOR],n=e.match(r);if(!n)throw new TypeError(`Invalid comparator: ${e}`);this.operator=n[1]!==void 0?n[1]:"",this.operator==="="&&(this.operator=""),n[2]?this.semver=new Lc(n[2],this.options.loose):this.semver=tn}toString(){return this.value}test(e){if(Qs("Comparator.test",e,this.options.loose),this.semver===tn||e===tn)return!0;if(typeof e=="string")try{e=new Lc(e,this.options)}catch{return!1}return Zs(e,this.operator,this.semver,this.options)}intersects(e,r){if(!(e instanceof vr))throw new TypeError("a Comparator is required");if((!r||typeof r!="object")&&(r={loose:!!r,includePrerelease:!1}),this.operator==="")return this.value===""?!0:new Mc(e.value,r).test(this.value);if(e.operator==="")return e.value===""?!0:new Mc(this.value,r).test(e.semver);let n=(this.operator===">="||this.operator===">")&&(e.operator===">="||e.operator===">"),s=(this.operator==="<="||this.operator==="<")&&(e.operator==="<="||e.operator==="<"),i=this.semver.version===e.semver.version,a=(this.operator===">="||this.operator==="<=")&&(e.operator===">="||e.operator==="<="),c=Zs(this.semver,"<",e.semver,r)&&(this.operator===">="||this.operator===">")&&(e.operator==="<="||e.operator==="<"),l=Zs(this.semver,">",e.semver,r)&&(this.operator==="<="||this.operator==="<")&&(e.operator===">="||e.operator===">");return n||s||i&&a||c||l}};xc.exports=vr;var Rp=Yr(),{re:Ac,t:kc}=Ft(),Zs=Ks(),Qs=Wr(),Lc=ve(),Mc=Ve()});var rn=y((qw,Fc)=>{var Np=Ve(),Ip=(t,e,r)=>{try{e=new Np(e,r)}catch{return!1}return e.test(t)};Fc.exports=Ip});var Uc=y((Cw,Vc)=>{var Tp=Ve(),qp=(t,e)=>new Tp(t,e).set.map(r=>r.map(n=>n.value).join(" ").trim().split(" "));Vc.exports=qp});var Hc=y((jw,Gc)=>{var Cp=ve(),jp=Ve(),Dp=(t,e,r)=>{let n=null,s=null,i=null;try{i=new jp(e,r)}catch{return null}return t.forEach(a=>{i.test(a)&&(!n||s.compare(a)===-1)&&(n=a,s=new Cp(n,r))}),n};Gc.exports=Dp});var Kc=y((Dw,zc)=>{var Ap=ve(),kp=Ve(),Lp=(t,e,r)=>{let n=null,s=null,i=null;try{i=new kp(e,r)}catch{return null}return t.forEach(a=>{i.test(a)&&(!n||s.compare(a)===1)&&(n=a,s=new Ap(n,r))}),n};zc.exports=Lp});var Wc=y((Aw,Bc)=>{var ei=ve(),Mp=Ve(),Xc=Jr(),xp=(t,e)=>{t=new Mp(t,e);let r=new ei("0.0.0");if(t.test(r)||(r=new ei("0.0.0-0"),t.test(r)))return r;r=null;for(let n=0;n<t.set.length;++n){let s=t.set[n],i=null;s.forEach(a=>{let c=new ei(a.semver.version);switch(a.operator){case">":c.prerelease.length===0?c.patch++:c.prerelease.push(0),c.raw=c.format();case"":case">=":(!i||Xc(c,i))&&(i=c);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${a.operator}`)}}),i&&(!r||Xc(r,i))&&(r=i)}return r&&t.test(r)?r:null};Bc.exports=xp});var Jc=y((kw,Yc)=>{var Fp=Ve(),Vp=(t,e)=>{try{return new Fp(t,e).range||"*"}catch{return null}};Yc.exports=Vp});var Jn=y((Lw,tu)=>{var Up=ve(),eu=en(),{ANY:Gp}=eu,Hp=Ve(),zp=rn(),Zc=Jr(),Qc=zn(),Kp=Xn(),Xp=Kn(),Bp=(t,e,r,n)=>{t=new Up(t,n),e=new Hp(e,n);let s,i,a,c,l;switch(r){case">":s=Zc,i=Kp,a=Qc,c=">",l=">=";break;case"<":s=Qc,i=Xp,a=Zc,c="<",l="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(zp(t,e,n))return!1;for(let o=0;o<e.set.length;++o){let f=e.set[o],h=null,_=null;if(f.forEach(v=>{v.semver===Gp&&(v=new eu(">=0.0.0")),h=h||v,_=_||v,s(v.semver,h.semver,n)?h=v:a(v.semver,_.semver,n)&&(_=v)}),h.operator===c||h.operator===l||(!_.operator||_.operator===c)&&i(t,_.semver))return!1;if(_.operator===l&&a(t,_.semver))return!1}return!0};tu.exports=Bp});var nu=y((Mw,ru)=>{var Wp=Jn(),Yp=(t,e,r)=>Wp(t,e,">",r);ru.exports=Yp});var iu=y((xw,su)=>{var Jp=Jn(),Zp=(t,e,r)=>Jp(t,e,"<",r);su.exports=Zp});var cu=y((Fw,ou)=>{var au=Ve(),Qp=(t,e,r)=>(t=new au(t,r),e=new au(e,r),t.intersects(e));ou.exports=Qp});var lu=y((Vw,uu)=>{var em=rn(),tm=Fe();uu.exports=(t,e,r)=>{let n=[],s=null,i=null,a=t.sort((f,h)=>tm(f,h,r));for(let f of a)em(f,e,r)?(i=f,s||(s=f)):(i&&n.push([s,i]),i=null,s=null);s&&n.push([s,null]);let c=[];for(let[f,h]of n)f===h?c.push(f):!h&&f===a[0]?c.push("*"):h?f===a[0]?c.push(`<=${h}`):c.push(`${f} - ${h}`):c.push(`>=${f}`);let l=c.join(" || "),o=typeof e.raw=="string"?e.raw:String(e);return l.length<o.length?l:e}});var mu=y((Uw,pu)=>{var fu=Ve(),Zn=en(),{ANY:ti}=Zn,nn=rn(),ri=Fe(),rm=(t,e,r={})=>{if(t===e)return!0;t=new fu(t,r),e=new fu(e,r);let n=!1;e:for(let s of t.set){for(let i of e.set){let a=nm(s,i,r);if(n=n||a!==null,a)continue e}if(n)return!1}return!0},nm=(t,e,r)=>{if(t===e)return!0;if(t.length===1&&t[0].semver===ti){if(e.length===1&&e[0].semver===ti)return!0;r.includePrerelease?t=[new Zn(">=0.0.0-0")]:t=[new Zn(">=0.0.0")]}if(e.length===1&&e[0].semver===ti){if(r.includePrerelease)return!0;e=[new Zn(">=0.0.0")]}let n=new Set,s,i;for(let v of t)v.operator===">"||v.operator===">="?s=du(s,v,r):v.operator==="<"||v.operator==="<="?i=hu(i,v,r):n.add(v.semver);if(n.size>1)return null;let a;if(s&&i){if(a=ri(s.semver,i.semver,r),a>0)return null;if(a===0&&(s.operator!==">="||i.operator!=="<="))return null}for(let v of n){if(s&&!nn(v,String(s),r)||i&&!nn(v,String(i),r))return null;for(let E of e)if(!nn(v,String(E),r))return!1;return!0}let c,l,o,f,h=i&&!r.includePrerelease&&i.semver.prerelease.length?i.semver:!1,_=s&&!r.includePrerelease&&s.semver.prerelease.length?s.semver:!1;h&&h.prerelease.length===1&&i.operator==="<"&&h.prerelease[0]===0&&(h=!1);for(let v of e){if(f=f||v.operator===">"||v.operator===">=",o=o||v.operator==="<"||v.operator==="<=",s){if(_&&v.semver.prerelease&&v.semver.prerelease.length&&v.semver.major===_.major&&v.semver.minor===_.minor&&v.semver.patch===_.patch&&(_=!1),v.operator===">"||v.operator===">="){if(c=du(s,v,r),c===v&&c!==s)return!1}else if(s.operator===">="&&!nn(s.semver,String(v),r))return!1}if(i){if(h&&v.semver.prerelease&&v.semver.prerelease.length&&v.semver.major===h.major&&v.semver.minor===h.minor&&v.semver.patch===h.patch&&(h=!1),v.operator==="<"||v.operator==="<="){if(l=hu(i,v,r),l===v&&l!==i)return!1}else if(i.operator==="<="&&!nn(i.semver,String(v),r))return!1}if(!v.operator&&(i||s)&&a!==0)return!1}return!(s&&o&&!i&&a!==0||i&&f&&!s&&a!==0||_||h)},du=(t,e,r)=>{if(!t)return e;let n=ri(t.semver,e.semver,r);return n>0?t:n<0||e.operator===">"&&t.operator===">="?e:t},hu=(t,e,r)=>{if(!t)return e;let n=ri(t.semver,e.semver,r);return n<0?t:n>0||e.operator==="<"&&t.operator==="<="?e:t};pu.exports=rm});var yu=y((Gw,gu)=>{var ni=Ft(),sm=Br(),im=ve(),vu=Hs(),am=Vt(),om=Mo(),cm=Fo(),um=Go(),lm=Wo(),fm=Jo(),dm=Qo(),hm=tc(),pm=nc(),mm=Fe(),vm=ic(),gm=oc(),ym=Hn(),_m=fc(),$m=hc(),Em=Jr(),wm=zn(),bm=Gn(),Sm=zs(),Pm=Kn(),Om=Xn(),Rm=Ks(),Nm=Ec(),Im=en(),Tm=Ve(),qm=rn(),Cm=Uc(),jm=Hc(),Dm=Kc(),Am=Wc(),km=Jc(),Lm=Jn(),Mm=nu(),xm=iu(),Fm=cu(),Vm=lu(),Um=mu();gu.exports={parse:am,valid:om,clean:cm,inc:um,diff:lm,major:fm,minor:dm,patch:hm,prerelease:pm,compare:mm,rcompare:vm,compareLoose:gm,compareBuild:ym,sort:_m,rsort:$m,gt:Em,lt:wm,eq:bm,neq:Sm,gte:Pm,lte:Om,cmp:Rm,coerce:Nm,Comparator:Im,Range:Tm,satisfies:qm,toComparators:Cm,maxSatisfying:jm,minSatisfying:Dm,minVersion:Am,validRange:km,outside:Lm,gtr:Mm,ltr:xm,intersects:Fm,simplifyRange:Vm,subset:Um,SemVer:im,re:ni.re,src:ni.src,tokens:ni.t,SEMVER_SPEC_VERSION:sm.SEMVER_SPEC_VERSION,compareIdentifiers:vu.compareIdentifiers,rcompareIdentifiers:vu.rcompareIdentifiers}});var Et=y(ke=>{"use strict";var Gm=ke&&ke.__createBinding||(Object.create?function(t,e,r,n){n===void 0&&(n=r);var s=Object.getOwnPropertyDescriptor(e,r);(!s||("get"in s?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,s)}:function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]}),Hm=ke&&ke.__setModuleDefault||(Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e}),zm=ke&&ke.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&Gm(e,t,r);return Hm(e,t),e},_u=ke&&ke.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(ke,"__esModule",{value:!0});ke.getCoreVersion=void 0;var $u=_u(require("path")),Eu=_u(require("fs")),si=zm(require("@serverless-devs/core")),Km=yu(),wu=$u.default.join(si.getRootHome(),"cache","core"),ii=$u.default.join(wu,"package.json");function Xm(){if(Eu.default.existsSync(ii)){var t=require("@serverless-devs/core/package.json").version,e=bu();return Km.gt(e,t)?require(wu):si}return si}function bu(){return Eu.default.existsSync(ii)?require(ii).version:void 0}ke.getCoreVersion=bu;ke.default=Xm()});var ci=y(Ne=>{"use strict";var Bm=Ne&&Ne.__awaiter||function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(a){a(i)})}return new(r||(r=Promise))(function(i,a){function c(f){try{o(n.next(f))}catch(h){a(h)}}function l(f){try{o(n.throw(f))}catch(h){a(h)}}function o(f){f.done?i(f.value):s(f.value).then(c,l)}o((n=n.apply(t,e||[])).next())})},Wm=Ne&&Ne.__generator||function(t,e){var r={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,s,i,a;return a={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function c(o){return function(f){return l([o,f])}}function l(o){if(n)throw new TypeError("Generator is already executing.");for(;a&&(a=0,o[0]&&(r=0)),r;)try{if(n=1,s&&(i=o[0]&2?s.return:o[0]?s.throw||((i=s.return)&&i.call(s),0):s.next)&&!(i=i.call(s,o[1])).done)return i;switch(s=0,i&&(o=[o[0]&2,i.value]),o[0]){case 0:case 1:i=o;break;case 4:return r.label++,{value:o[1],done:!1};case 5:r.label++,s=o[1],o=[0];continue;case 7:o=r.ops.pop(),r.trys.pop();continue;default:if(i=r.trys,!(i=i.length>0&&i[i.length-1])&&(o[0]===6||o[0]===2)){r=0;continue}if(o[0]===3&&(!i||o[1]>i[0]&&o[1]<i[3])){r.label=o[1];break}if(o[0]===6&&r.label<i[1]){r.label=i[1],i=o;break}if(i&&r.label<i[2]){r.label=i[2],r.ops.push(o);break}i[2]&&r.ops.pop(),r.trys.pop();continue}o=e.call(t,r)}catch(f){o=[6,f],s=0}finally{n=i=0}if(o[0]&5)throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}},Su=Ne&&Ne.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(Ne,"__esModule",{value:!0});Ne.handlerProfileFile=Ne.getConfig=Ne.setConfig=void 0;var Pu=Su(require("path")),oi=Su(Et()),at=oi.default.fse,Qn=oi.default.jsyaml,ai=oi.default.getRootHome;function Ym(t){var e=Ru();at.writeFileSync(e,Qn.dump(t))}function Ou(){var t=Ru();if(!at.existsSync(t))return{};try{var e=Qn.load(at.readFileSync(t,"utf8"))||{};return e}catch(r){throw r}}function Ru(){var t=Pu.default.join(ai(),"set-config.yml");return at.existsSync(t)||at.createFileSync(t),t}function Jm(t,e){var r=Ou();r[t]=e,Ym(r)}Ne.setConfig=Jm;function Zm(t,e){var r=Ou();return r[t]||e}Ne.getConfig=Zm;function Qm(t){return Bm(this,void 0,void 0,function(){var e,r,n,s,i,a,c;return Wm(this,function(l){switch(l.label){case 0:if(e=t.filePath||"set-config.yml",r=Pu.default.join(ai(),e),n=at.existsSync(r),s={},n)return[3,5];i=ai(),l.label=1;case 1:return l.trys.push([1,2,,4]),at.statSync(i),[3,4];case 2:return a=l.sent(),[4,at.mkdirSync(i)];case 3:return l.sent(),[3,4];case 4:return[3,6];case 5:try{s=Qn.load(at.readFileSync(r,"utf8"))||{}}catch(o){throw o}l.label=6;case 6:return t.read?[2,s]:(c=t.configKey||"",s[c]=t.data,[4,at.writeFileSync(r,Qn.dump(s))]);case 7:return l.sent(),[2,s]}})})}Ne.handlerProfileFile=Qm});var es=y(sn=>{"use strict";var ev=sn&&sn.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(sn,"__esModule",{value:!0});var tv=ev(Et()),rv=tv.default.Logger,ui=new rv("S-CLI");ui.success=function(t){return ui.log(t,"green")};sn.default=ui});var Nu=y((Xw,nv)=>{nv.exports={name:"@serverless-devs/s",version:"2.1.8-beta.2",description:"Serverless devs tool, serverless developer tool, supports Alibaba cloud, AWS, azure, baidu cloud, Huawei cloud, Google cloud and Tencent cloud.",homepage:"https://www.serverless-devs.com",keywords:["serverless","alibaba","tencent","azure","baidu","huawei","google","function","faas","serverless-devs"],publishConfig:{access:"public",registry:"https://registry.npmjs.org"},license:"Apache 2.0",repository:{type:"git",url:"https://github.com/Serverless-Devs/Serverless-Devs"},bugs:{url:"https://github.com/Serverless-Devs/Serverless-Devs/issues"},scripts:{start:"npm run watch",prewatch:"rm -rf lib/* && cp -r ./src/daemon ./lib",watch:"tsc -w",test:"jest test/special-command.test",prebuild:"rm -rf lib/*",build:"tsc && cp -r ./src/daemon ./lib",postbuild:"./script/postbuild.sh","test:cov":"jest --coverage",lint:"npm run typecheck && f2elint scan -i src",fix:"f2elint fix",typecheck:"npx tsc -p tsconfig.json --noEmit",update:"rm -rf yarn.lock && rm -rf package-lock.json && rm -rf node_modules && yarn",beta:"npm publish --tag=beta",pkg:"tsc && pkg bin/s"},main:"./lib/index.js",bin:{s:"bin/s"},devDependencies:{"@serverless-devs/commander":"^6.2.6","@types/jest":"^27.4.0","@types/node":"^14.0.23","@typescript-eslint/eslint-plugin":"^4.14.1","@typescript-eslint/parser":"^4.14.1",ajv:"^8.10.0","babel-eslint":"^10.1.0",boxen:"^5.0.0",dotenv:"^10.0.0",esbuild:"^0.14.0",eslint:"^7.7.0","eslint-config-prettier":"^7.2.0","eslint-plugin-import":"^2.20.1","eslint-plugin-prettier":"^3.1.2","global-agent":"^3.0.0",husky:"^4.2.3",inquirer:"8.2.0","inquirer-autocomplete-prompt":"^1.3.0",jest:"^27.4.7","latest-version":"^5.1.0","lint-staged":"^10.0.8",open:"^8.4.0","os-locale":"5.0.0",pkg:"^5.8.0",prettier:"^2.2.1",semver:"^7.3.5","semver-diff":"^3.1.1","ts-jest":"^27.1.3","ts-node":"^9.1.1",typescript:"^4.1.3"},"lint-staged":{"**/*.{js,jsx,ts}":"f2elint exec eslint"},dependencies:{"@serverless-devs/core":"latest","@serverless-devs/ui":"latest"}}});var fi=y(I=>{"use strict";var sv=I&&I.__createBinding||(Object.create?function(t,e,r,n){n===void 0&&(n=r);var s=Object.getOwnPropertyDescriptor(e,r);(!s||("get"in s?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,s)}:function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]}),iv=I&&I.__setModuleDefault||(Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e}),av=I&&I.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&sv(e,t,r);return iv(e,t),e},yr=I&&I.__awaiter||function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(a){a(i)})}return new(r||(r=Promise))(function(i,a){function c(f){try{o(n.next(f))}catch(h){a(h)}}function l(f){try{o(n.throw(f))}catch(h){a(h)}}function o(f){f.done?i(f.value):s(f.value).then(c,l)}o((n=n.apply(t,e||[])).next())})},_r=I&&I.__generator||function(t,e){var r={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,s,i,a;return a={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function c(o){return function(f){return l([o,f])}}function l(o){if(n)throw new TypeError("Generator is already executing.");for(;a&&(a=0,o[0]&&(r=0)),r;)try{if(n=1,s&&(i=o[0]&2?s.return:o[0]?s.throw||((i=s.return)&&i.call(s),0):s.next)&&!(i=i.call(s,o[1])).done)return i;switch(s=0,i&&(o=[o[0]&2,i.value]),o[0]){case 0:case 1:i=o;break;case 4:return r.label++,{value:o[1],done:!1};case 5:r.label++,s=o[1],o=[0];continue;case 7:o=r.ops.pop(),r.trys.pop();continue;default:if(i=r.trys,!(i=i.length>0&&i[i.length-1])&&(o[0]===6||o[0]===2)){r=0;continue}if(o[0]===3&&(!i||o[1]>i[0]&&o[1]<i[3])){r.label=o[1];break}if(o[0]===6&&r.label<i[1]){r.label=i[1],i=o;break}if(i&&r.label<i[2]){r.label=i[2],r.ops.push(o);break}i[2]&&r.ops.pop(),r.trys.pop();continue}o=e.call(t,r)}catch(f){o=[6,f],s=0}finally{n=i=0}if(o[0]&5)throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}},ts=I&&I.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(I,"__esModule",{value:!0});I.specifyServiceHelp=I.getTempCommandStr=I.emoji=I.mark=I.replaceTemplate=I.replaceFun=I.getLang=I.printn=I.getFolderSize=I.getVersion=I.aiRequest=I.getCredentialWithAll=I.getCredentialWithExisted=I.getProcessArgv=I.bgRed=I.yellow=I.red=void 0;var ov=ts(require("path")),an=ts(require("fs")),cv=ts(require("os")),we=av(Et()),uv=ci(),gr=ts(es()),Iu=Nu(),$r=we.default.colors,lv=we.default.got,fv=we.default.isDocker,dv=we.default.isCiCdEnv,Rt=we.default.lodash,Tu=we.default.publishHelp,hv=Rt.get,pv=Rt.trim,mv=Rt.assign,vv=Rt.filter,qu=Rt.includes,gv=Rt.omit,yv=Rt.isPlainObject,_v=Rt.isEmpty,$v=$r.underline,Ev=$r.bold;I.red=$r.hex("#fd5750");I.yellow=$r.hex("#F3F99D");I.bgRed=$r.hex("#000").bgHex("#fd5750");var wv=function(){var t=process.env.serverless_devs_temp_argv;try{var e=JSON.parse(t),r=we.default.getGlobalArgs(e);return process.argv=process.argv.slice(0,2).concat(r._argsObj),mv({},r,{noHelpArgv:process.argv.slice(0,2).concat(vv(r._argsObj,function(n){return!qu(["-h","--help"],n)}))})}catch{return{}}};I.getProcessArgv=wv;var bv=function(t){return yr(void 0,void 0,void 0,function(){var e,r;return _r(this,function(n){switch(n.label){case 0:return[4,we.default.getCredentialAliasList()];case 1:return e=n.sent(),qu(e,t)?[4,we.default.getCredential(t)]:[3,3];case 2:return r=n.sent(),[2,r];case 3:return[2]}})})};I.getCredentialWithExisted=bv;var Sv=function(){return yr(void 0,void 0,void 0,function(){var t,e,r,n,s,i;return _r(this,function(a){switch(a.label){case 0:return[4,we.default.getCredentialAliasList()];case 1:if(t=a.sent(),!(t.length>0))return[3,6];e={},r=0,n=t,a.label=2;case 2:return r<n.length?(s=n[r],[4,we.default.getCredential(s)]):[3,5];case 3:i=a.sent(),e[i.Alias]=gv(i,"Alias"),a.label=4;case 4:return r++,[3,2];case 5:return[2,e];case 6:return[2]}})})};I.getCredentialWithAll=Sv;var Pv=function(t,e){return e===void 0&&(e="unknow"),yr(void 0,void 0,void 0,function(){var r,n,s,i;return _r(this,function(a){switch(a.label){case 0:return a.trys.push([0,2,,3]),r=(0,uv.getConfig)("analysis"),r!=="enable"?[2]:fv()||dv()?[2]:[4,lv("http://qaapis.devsapp.cn/apis/v1/search?category=".concat(e,"&code=TypeError&s=").concat(t),{timeout:2e3,json:!0})];case 1:return n=a.sent(),s=hv(n.body,"shorturl"),s&&gr.default.log(`AI Tips:
|
|
16
2
|
You can try to solve the problem through: `.concat($r.underline(s),`
|
|
17
|
-
`)),[3,3];case 2:return i=a.sent(),[3,3];case 3:return[2]}})})};
|
|
18
|
-
`.concat(
|
|
19
|
-
`)),
|
|
20
|
-
`)),!
|
|
21
|
-
`:"")}return[2]}})})}N.specifyServiceHelp=Jg});var Bu=_(gi=>{"use strict";Object.defineProperty(gi,"__esModule",{value:!0});gi.default={clean_up_the_environment:"\u6E05\u7406\u73AF\u5883",display_help_for_command:"\u663E\u793A\u547D\u4EE4\u5E2E\u52A9",remove_components:"\u5220\u9664\u7EC4\u4EF6",delete_the_file_under_the_cache:"\u5220\u9664\u7F13\u5B58\u91CC\u7684\u7684<dirname>\u6587\u4EF6",record_your_log_information:"\u662F\u5426\u8BB0\u5F55\u60A8\u7684\u65E5\u5FD7\u4FE1\u606F\uFF1F",init_pproject_deploy_tip:"\u662F\u5426\u7ACB\u5373\u90E8\u7F72\u8BE5\u9879\u76EE\uFF1F",tip_for_a_serverless_project:"\u68C0\u6D4B\u5230\u5F53\u524D\u76EE\u5F55\u4E0B\u5DF2\u5B58\u5728\u4E00\u4E2AServerless-Devs\u9879\u76EE\uFF0C\u8BF7\u901A\u8FC7 's deploy' \u8FDB\u884C\u90E8\u7F72\u6216\u901A\u8FC7 's -h' \u83B7\u53D6\u66F4\u591A\u4FE1\u606F",create_a_new_project:"\u672A\u68C0\u6D4B\u5230 Serverless-Devs \u9879\u76EE\uFF0C\u662F\u5426\u65B0\u5EFA\u4E00\u4E2A\u9879\u76EE\uFF1F",en:"English (en)",zh:"\u4E2D\u6587 (zh)",select_current_language:"\u8BF7\u9009\u62E9\u5F53\u524D\u8BED\u8A00","app-tip":"\u8BF7\u9009\u62E9\u60A8\u5E0C\u671B\u521B\u5EFA\u7684 Serverless-Devs \u5E94\u7528","template-tip":"\u8BF7\u9009\u62E9\u60A8\u559C\u6B22\u7684\u6A21\u7248","fc-runtime-starter":"fc-runtime-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A FC \u51FD\u6570","fc-custom-container-stater":"fc-custom-container-stater - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A custom-container \u5E94\u7528",web:"web-framework-stater - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A Web \u6846\u67B6","static-site":"static-website-stater - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u9759\u6001\u7F51\u7AD9","best-practice":"serverless-best-practice - \u5FEB\u901F\u4F53\u9A8C Serverless \u6700\u4F73\u5B9E\u8DF5","devs-template":"Serverless Devs \u5F00\u53D1\u6A21\u677F","fc-http-nodejs":"fc-http-nodejs - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A nodejs12 \u51FD\u6570","fc-http-python":"fc-http-python - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A python3 \u51FD\u6570","fc-http-java":"fc-http-java - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A java8 \u51FD\u6570","fc-custom-container-event-python3":"fc-custom-container-event-python3 - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7\u4E8B\u4EF6\u89E6\u53D1\u7684 python3 \u5E94\u7528","fc-custom-container-event-cpp":"fc-custom-container-event-cpp - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7\u4E8B\u4EF6\u89E6\u53D1\u7684 cpp \u5E94\u7528","fc-custom-container-http-springboot":"fc-custom-container-http-springboot - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7 HTTP \u8BF7\u6C42\u89E6\u53D1\u7684 springboot \u5E94\u7528","fc-custom-container-http-aspdotnetcore":"fc-custom-container-http-aspdotnetcore - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7 HTTP \u8BF7\u6C42\u89E6\u53D1\u7684 aspdotnetcore \u5E94\u7528","express-starter":"express-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A express \u57FA\u7840\u5E94\u7528","koa-starter":"koa-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A koa \u57FA\u7840\u5E94\u7528","nuxtjs-starter":"nuxtjs-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A nuxtjs \u57FA\u7840\u5E94\u7528","eggjs-starter":"eggjs-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A eggjs \u57FA\u7840\u5E94\u7528","flask-starter":"flask-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A flask \u57FA\u7840\u5E94\u7528","SpringBoot-starter":"SpringBoot-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A SpringBoot \u57FA\u7840\u5E94\u7528","Zblog-starter":"Zblog-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A Zblog \u57FA\u7840\u5E94\u7528","website-starter":"website-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u9759\u6001\u7F51\u7AD9","react-starter":"react-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A React.js \u5E94\u7528","vue-starter":"vue-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A Vue.js \u5E94\u7528",puppeteer:"puppeteer - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u57FA\u4E8E puppeteer \u622A\u56FE\u7684 Web \u5E94\u7528",ffmpeg:"ffmpeg - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u57FA\u4E8E ffmpeg \u5B9E\u73B0\u97F3\u89C6\u9891\u5904\u7406\u5E94\u7528",pdf2Img:"pdf2Img - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A pdf \u8F6C\u56FE\u7247\u5E94\u7528",tensorflow:"tensorflow - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A tensorflow \u5E94\u7528",todoList:"todoList - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u57FA\u4E8E nodejs \u7684\u7F51\u9875 TodoList \u5E94\u7528"}});var Ju=_(vi=>{"use strict";Object.defineProperty(vi,"__esModule",{value:!0});vi.default={clean_up_the_environment:"Clean up the environment",display_help_for_command:"Display help for command",remove_components:"Remove component (like: fc, fc@0.0.1)",delete_the_file_under_the_cache:"Delete the <dirname> file in the cache",record_your_log_information:"Do you record your log information?",init_pproject_deploy_tip:"Do you want to deploy the project immediately?",tip_for_a_serverless_project:"A Serverless-Devs project is detected in the current directory, please deploy via 's deploy' or get more information via 's -h'",create_a_new_project:"No Serverless-Devs project is currently detected. Do you want to create a new project?",en:"English (en)",zh:"Chinese (zh)",select_current_language:"Please select current language","app-tip":"Hello, serverlesser. Which template do you like?","template-tip":"Which template do you like?","fc-runtime-starter":"fc-runtime-starter - Deploy FC function in 5 minutes","fc-custom-container-stater":"fc-custom-container-stater - Deploy FC function with custom-container",web:"web-framework-stater-Quickly deploy a web framework","static-site":"static-website-stater-Quickly deploy a static website","best-practice":"serverless-best-practice-Quickly experience serverless best practices","devs-template":"Serverless Develop scaffold","fc-http-nodejs":"fc-http-nodejs - Deploy FC nodejs12 runtime function","fc-http-python":"fc-http-python - Deploy FC python3 runtime function","fc-http-java":"fc-http-java - Deploy FC java8 runtime function","fc-custom-container-event-python3":"fc-custom-container-event-python3 - Deploy python3 event-triggered application","fc-custom-container-event-cpp":"fc-custom-container-event-cpp - Deploy cpp event-triggered application","fc-custom-container-http-springboot":"fc-custom-container-http-springboot - Deploy springboot HTTP Request-triggered application","fc-custom-container-http-aspdotnetcore":"fc-custom-container-http-aspdotnetcore - Deploy dotnetcore HTTP Request-triggered application","express-starter":"express-starter - Deploy express application","koa-starter":"koa-starter - Deploy koa application","nuxtjs-starter":"nuxtjs-starter - Deploy nuxtjs application","eggjs-starter":"eggjs-starter - Deploy eggjs application","flask-starter":"flask-starter - Deploy flask application","SpringBoot-starter":"SpringBoot-starter - Deploy SpringBoot application","Zblog-starter":"Zblog-starter - Deploy Zblog application","website-starter":"website-starter - Deploy static website","react-starter":"react-starter - Deploy React.js application","vue-starter":"vue-starter - Deploy Vue.js application",puppeteer:"puppeteer - Deploy screenshot application base on puppeteer + fc",ffmpeg:"ffmpeg - Deploy audio and video processing application base on ffmpeg + fc",pdf2Img:"pdf2Img - Deploy pdf to images application",tensorflow:"tensorflow - Deploy tensorflow application",todoList:"todoList - Deploy todoList application"}});var yi=_(un=>{"use strict";var Yu=un&&un.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(un,"__esModule",{value:!0});var Yg=mi(),Zg=Yu(Bu()),Qg=Yu(Ju()),_i={en:Qg.default,zh:Zg.default},ev=function(r){var e=(0,Yg.getLang)(),t=_i[e]?_i[e][r]:_i.en[r];return t||r};un.default=ev});var ln=_(ve=>{"use strict";var tv=ve&&ve.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t);var s=Object.getOwnPropertyDescriptor(e,t);(!s||("get"in s?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return e[t]}}),Object.defineProperty(r,n,s)}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),Zu=ve&&ve.__exportStar||function(r,e){for(var t in r)t!=="default"&&!Object.prototype.hasOwnProperty.call(e,t)&&tv(e,r,t)},$i=ve&&ve.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ve,"__esModule",{value:!0});ve.registerCommandChecker=ve.i18n=ve.logger=void 0;var rv=$i(ss());Zu(mi(),ve);Zu(di(),ve);var nv=ss();Object.defineProperty(ve,"logger",{enumerable:!0,get:function(){return $i(nv).default}});var sv=yi();Object.defineProperty(ve,"i18n",{enumerable:!0,get:function(){return $i(sv).default}});function iv(r){r.on("command:*",function(e){var t=r.commands.map(function(n){return n.name()});t.includes(e[0])||(rv.default.error(" error: unknown command ".concat(e[0])),r.help())})}ve.registerCommandChecker=iv});var hn=_(U=>{"use strict";Object.defineProperty(U,"__esModule",{value:!0});U.regexpCode=U.getEsmExportName=U.getProperty=U.safeStringify=U.stringify=U.strConcat=U.addCodeArg=U.str=U._=U.nil=U._Code=U.Name=U.IDENTIFIER=U._CodeOrName=void 0;var fn=class{};U._CodeOrName=fn;U.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var zt=class extends fn{constructor(e){if(super(),!U.IDENTIFIER.test(e))throw new Error("CodeGen: name must be a valid identifier");this.str=e}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}};U.Name=zt;var Ge=class extends fn{constructor(e){super(),this._items=typeof e=="string"?[e]:e}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;let e=this._items[0];return e===""||e==='""'}get str(){var e;return(e=this._str)!==null&&e!==void 0?e:this._str=this._items.reduce((t,n)=>`${t}${n}`,"")}get names(){var e;return(e=this._names)!==null&&e!==void 0?e:this._names=this._items.reduce((t,n)=>(n instanceof zt&&(t[n.str]=(t[n.str]||0)+1),t),{})}};U._Code=Ge;U.nil=new Ge("");function Qu(r,...e){let t=[r[0]],n=0;for(;n<e.length;)wi(t,e[n]),t.push(r[++n]);return new Ge(t)}U._=Qu;var Ei=new Ge("+");function el(r,...e){let t=[dn(r[0])],n=0;for(;n<e.length;)t.push(Ei),wi(t,e[n]),t.push(Ei,dn(r[++n]));return av(t),new Ge(t)}U.str=el;function wi(r,e){e instanceof Ge?r.push(...e._items):e instanceof zt?r.push(e):r.push(uv(e))}U.addCodeArg=wi;function av(r){let e=1;for(;e<r.length-1;){if(r[e]===Ei){let t=ov(r[e-1],r[e+1]);if(t!==void 0){r.splice(e-1,3,t);continue}r[e++]="+"}e++}}function ov(r,e){if(e==='""')return r;if(r==='""')return e;if(typeof r=="string")return e instanceof zt||r[r.length-1]!=='"'?void 0:typeof e!="string"?`${r.slice(0,-1)}${e}"`:e[0]==='"'?r.slice(0,-1)+e.slice(1):void 0;if(typeof e=="string"&&e[0]==='"'&&!(r instanceof zt))return`"${r}${e.slice(1)}`}function cv(r,e){return e.emptyStr()?r:r.emptyStr()?e:el`${r}${e}`}U.strConcat=cv;function uv(r){return typeof r=="number"||typeof r=="boolean"||r===null?r:dn(Array.isArray(r)?r.join(","):r)}function lv(r){return new Ge(dn(r))}U.stringify=lv;function dn(r){return JSON.stringify(r).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}U.safeStringify=dn;function fv(r){return typeof r=="string"&&U.IDENTIFIER.test(r)?new Ge(`.${r}`):Qu`[${r}]`}U.getProperty=fv;function dv(r){if(typeof r=="string"&&U.IDENTIFIER.test(r))return new Ge(`${r}`);throw new Error(`CodeGen: invalid export name: ${r}, use explicit $id name mapping`)}U.getEsmExportName=dv;function hv(r){return new Ge(r.toString())}U.regexpCode=hv});var Pi=_(be=>{"use strict";Object.defineProperty(be,"__esModule",{value:!0});be.ValueScope=be.ValueScopeName=be.Scope=be.varKinds=be.UsedValueState=void 0;var Ce=hn(),bi=class extends Error{constructor(e){super(`CodeGen: "code" for ${e} not defined`),this.value=e.value}},Si;(function(r){r[r.Started=0]="Started",r[r.Completed=1]="Completed"})(Si=be.UsedValueState||(be.UsedValueState={}));be.varKinds={const:new Ce.Name("const"),let:new Ce.Name("let"),var:new Ce.Name("var")};var as=class{constructor({prefixes:e,parent:t}={}){this._names={},this._prefixes=e,this._parent=t}toName(e){return e instanceof Ce.Name?e:this.name(e)}name(e){return new Ce.Name(this._newName(e))}_newName(e){let t=this._names[e]||this._nameGroup(e);return`${e}${t.index++}`}_nameGroup(e){var t,n;if(((n=(t=this._parent)===null||t===void 0?void 0:t._prefixes)===null||n===void 0?void 0:n.has(e))||this._prefixes&&!this._prefixes.has(e))throw new Error(`CodeGen: prefix "${e}" is not allowed in this scope`);return this._names[e]={prefix:e,index:0}}};be.Scope=as;var os=class extends Ce.Name{constructor(e,t){super(t),this.prefix=e}setValue(e,{property:t,itemIndex:n}){this.value=e,this.scopePath=(0,Ce._)`.${new Ce.Name(t)}[${n}]`}};be.ValueScopeName=os;var pv=(0,Ce._)`\n`,Oi=class extends as{constructor(e){super(e),this._values={},this._scope=e.scope,this.opts={...e,_n:e.lines?pv:Ce.nil}}get(){return this._scope}name(e){return new os(e,this._newName(e))}value(e,t){var n;if(t.ref===void 0)throw new Error("CodeGen: ref must be passed in value");let s=this.toName(e),{prefix:i}=s,a=(n=t.key)!==null&&n!==void 0?n:t.ref,c=this._values[i];if(c){let l=c.get(a);if(l)return l}else c=this._values[i]=new Map;c.set(a,s);let u=this._scope[i]||(this._scope[i]=[]),o=u.length;return u[o]=t.ref,s.setValue(t,{property:i,itemIndex:o}),s}getValue(e,t){let n=this._values[e];if(!!n)return n.get(t)}scopeRefs(e,t=this._values){return this._reduceValues(t,n=>{if(n.scopePath===void 0)throw new Error(`CodeGen: name "${n}" has no value`);return(0,Ce._)`${e}${n.scopePath}`})}scopeCode(e=this._values,t,n){return this._reduceValues(e,s=>{if(s.value===void 0)throw new Error(`CodeGen: name "${s}" has no value`);return s.value.code},t,n)}_reduceValues(e,t,n={},s){let i=Ce.nil;for(let a in e){let c=e[a];if(!c)continue;let u=n[a]=n[a]||new Map;c.forEach(o=>{if(u.has(o))return;u.set(o,Si.Started);let l=t(o);if(l){let d=this.opts.es5?be.varKinds.var:be.varKinds.const;i=(0,Ce._)`${i}${d} ${o} = ${l};${this.opts._n}`}else if(l=s==null?void 0:s(o))i=(0,Ce._)`${i}${l}${this.opts._n}`;else throw new bi(o);u.set(o,Si.Completed)})}return i}};be.ValueScope=Oi});var L=_(k=>{"use strict";Object.defineProperty(k,"__esModule",{value:!0});k.or=k.and=k.not=k.CodeGen=k.operators=k.varKinds=k.ValueScopeName=k.ValueScope=k.Scope=k.Name=k.regexpCode=k.stringify=k.getProperty=k.nil=k.strConcat=k.str=k._=void 0;var M=hn(),Be=Pi(),Pt=hn();Object.defineProperty(k,"_",{enumerable:!0,get:function(){return Pt._}});Object.defineProperty(k,"str",{enumerable:!0,get:function(){return Pt.str}});Object.defineProperty(k,"strConcat",{enumerable:!0,get:function(){return Pt.strConcat}});Object.defineProperty(k,"nil",{enumerable:!0,get:function(){return Pt.nil}});Object.defineProperty(k,"getProperty",{enumerable:!0,get:function(){return Pt.getProperty}});Object.defineProperty(k,"stringify",{enumerable:!0,get:function(){return Pt.stringify}});Object.defineProperty(k,"regexpCode",{enumerable:!0,get:function(){return Pt.regexpCode}});Object.defineProperty(k,"Name",{enumerable:!0,get:function(){return Pt.Name}});var fs=Pi();Object.defineProperty(k,"Scope",{enumerable:!0,get:function(){return fs.Scope}});Object.defineProperty(k,"ValueScope",{enumerable:!0,get:function(){return fs.ValueScope}});Object.defineProperty(k,"ValueScopeName",{enumerable:!0,get:function(){return fs.ValueScopeName}});Object.defineProperty(k,"varKinds",{enumerable:!0,get:function(){return fs.varKinds}});k.operators={GT:new M._Code(">"),GTE:new M._Code(">="),LT:new M._Code("<"),LTE:new M._Code("<="),EQ:new M._Code("==="),NEQ:new M._Code("!=="),NOT:new M._Code("!"),OR:new M._Code("||"),AND:new M._Code("&&"),ADD:new M._Code("+")};var _t=class{optimizeNodes(){return this}optimizeNames(e,t){return this}},Ri=class extends _t{constructor(e,t,n){super(),this.varKind=e,this.name=t,this.rhs=n}render({es5:e,_n:t}){let n=e?Be.varKinds.var:this.varKind,s=this.rhs===void 0?"":` = ${this.rhs}`;return`${n} ${this.name}${s};`+t}optimizeNames(e,t){if(!!e[this.name.str])return this.rhs&&(this.rhs=wr(this.rhs,e,t)),this}get names(){return this.rhs instanceof M._CodeOrName?this.rhs.names:{}}},cs=class extends _t{constructor(e,t,n){super(),this.lhs=e,this.rhs=t,this.sideEffects=n}render({_n:e}){return`${this.lhs} = ${this.rhs};`+e}optimizeNames(e,t){if(!(this.lhs instanceof M.Name&&!e[this.lhs.str]&&!this.sideEffects))return this.rhs=wr(this.rhs,e,t),this}get names(){let e=this.lhs instanceof M.Name?{}:{...this.lhs.names};return ls(e,this.rhs)}},Ci=class extends cs{constructor(e,t,n,s){super(e,n,s),this.op=t}render({_n:e}){return`${this.lhs} ${this.op}= ${this.rhs};`+e}},Ni=class extends _t{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){return`${this.label}:`+e}},Ii=class extends _t{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){return`break${this.label?` ${this.label}`:""};`+e}},Ti=class extends _t{constructor(e){super(),this.error=e}render({_n:e}){return`throw ${this.error};`+e}get names(){return this.error.names}},Ai=class extends _t{constructor(e){super(),this.code=e}render({_n:e}){return`${this.code};`+e}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(e,t){return this.code=wr(this.code,e,t),this}get names(){return this.code instanceof M._CodeOrName?this.code.names:{}}},pn=class extends _t{constructor(e=[]){super(),this.nodes=e}render(e){return this.nodes.reduce((t,n)=>t+n.render(e),"")}optimizeNodes(){let{nodes:e}=this,t=e.length;for(;t--;){let n=e[t].optimizeNodes();Array.isArray(n)?e.splice(t,1,...n):n?e[t]=n:e.splice(t,1)}return e.length>0?this:void 0}optimizeNames(e,t){let{nodes:n}=this,s=n.length;for(;s--;){let i=n[s];i.optimizeNames(e,t)||(mv(e,i.names),n.splice(s,1))}return n.length>0?this:void 0}get names(){return this.nodes.reduce((e,t)=>Xt(e,t.names),{})}},yt=class extends pn{render(e){return"{"+e._n+super.render(e)+"}"+e._n}},qi=class extends pn{},Er=class extends yt{};Er.kind="else";var Je=class extends yt{constructor(e,t){super(t),this.condition=e}render(e){let t=`if(${this.condition})`+super.render(e);return this.else&&(t+="else "+this.else.render(e)),t}optimizeNodes(){super.optimizeNodes();let e=this.condition;if(e===!0)return this.nodes;let t=this.else;if(t){let n=t.optimizeNodes();t=this.else=Array.isArray(n)?new Er(n):n}if(t)return e===!1?t instanceof Je?t:t.nodes:this.nodes.length?this:new Je(tl(e),t instanceof Je?[t]:t.nodes);if(!(e===!1||!this.nodes.length))return this}optimizeNames(e,t){var n;if(this.else=(n=this.else)===null||n===void 0?void 0:n.optimizeNames(e,t),!!(super.optimizeNames(e,t)||this.else))return this.condition=wr(this.condition,e,t),this}get names(){let e=super.names;return ls(e,this.condition),this.else&&Xt(e,this.else.names),e}};Je.kind="if";var Kt=class extends yt{};Kt.kind="for";var Di=class extends Kt{constructor(e){super(),this.iteration=e}render(e){return`for(${this.iteration})`+super.render(e)}optimizeNames(e,t){if(!!super.optimizeNames(e,t))return this.iteration=wr(this.iteration,e,t),this}get names(){return Xt(super.names,this.iteration.names)}},ji=class extends Kt{constructor(e,t,n,s){super(),this.varKind=e,this.name=t,this.from=n,this.to=s}render(e){let t=e.es5?Be.varKinds.var:this.varKind,{name:n,from:s,to:i}=this;return`for(${t} ${n}=${s}; ${n}<${i}; ${n}++)`+super.render(e)}get names(){let e=ls(super.names,this.from);return ls(e,this.to)}},us=class extends Kt{constructor(e,t,n,s){super(),this.loop=e,this.varKind=t,this.name=n,this.iterable=s}render(e){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(e)}optimizeNames(e,t){if(!!super.optimizeNames(e,t))return this.iterable=wr(this.iterable,e,t),this}get names(){return Xt(super.names,this.iterable.names)}},mn=class extends yt{constructor(e,t,n){super(),this.name=e,this.args=t,this.async=n}render(e){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(e)}};mn.kind="func";var gn=class extends pn{render(e){return"return "+super.render(e)}};gn.kind="return";var ki=class extends yt{render(e){let t="try"+super.render(e);return this.catch&&(t+=this.catch.render(e)),this.finally&&(t+=this.finally.render(e)),t}optimizeNodes(){var e,t;return super.optimizeNodes(),(e=this.catch)===null||e===void 0||e.optimizeNodes(),(t=this.finally)===null||t===void 0||t.optimizeNodes(),this}optimizeNames(e,t){var n,s;return super.optimizeNames(e,t),(n=this.catch)===null||n===void 0||n.optimizeNames(e,t),(s=this.finally)===null||s===void 0||s.optimizeNames(e,t),this}get names(){let e=super.names;return this.catch&&Xt(e,this.catch.names),this.finally&&Xt(e,this.finally.names),e}},vn=class extends yt{constructor(e){super(),this.error=e}render(e){return`catch(${this.error})`+super.render(e)}};vn.kind="catch";var _n=class extends yt{render(e){return"finally"+super.render(e)}};_n.kind="finally";var xi=class{constructor(e,t={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...t,_n:t.lines?`
|
|
22
|
-
`:""},this._extScope=e,this._scope=new Be.Scope({parent:e}),this._nodes=[new qi]}toString(){return this._root.render(this.opts)}name(e){return this._scope.name(e)}scopeName(e){return this._extScope.name(e)}scopeValue(e,t){let n=this._extScope.value(e,t);return(this._values[n.prefix]||(this._values[n.prefix]=new Set)).add(n),n}getScopeValue(e,t){return this._extScope.getValue(e,t)}scopeRefs(e){return this._extScope.scopeRefs(e,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(e,t,n,s){let i=this._scope.toName(t);return n!==void 0&&s&&(this._constants[i.str]=n),this._leafNode(new Ri(e,i,n)),i}const(e,t,n){return this._def(Be.varKinds.const,e,t,n)}let(e,t,n){return this._def(Be.varKinds.let,e,t,n)}var(e,t,n){return this._def(Be.varKinds.var,e,t,n)}assign(e,t,n){return this._leafNode(new cs(e,t,n))}add(e,t){return this._leafNode(new Ci(e,k.operators.ADD,t))}code(e){return typeof e=="function"?e():e!==M.nil&&this._leafNode(new Ai(e)),this}object(...e){let t=["{"];for(let[n,s]of e)t.length>1&&t.push(","),t.push(n),(n!==s||this.opts.es5)&&(t.push(":"),(0,M.addCodeArg)(t,s));return t.push("}"),new M._Code(t)}if(e,t,n){if(this._blockNode(new Je(e)),t&&n)this.code(t).else().code(n).endIf();else if(t)this.code(t).endIf();else if(n)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(e){return this._elseNode(new Je(e))}else(){return this._elseNode(new Er)}endIf(){return this._endBlockNode(Je,Er)}_for(e,t){return this._blockNode(e),t&&this.code(t).endFor(),this}for(e,t){return this._for(new Di(e),t)}forRange(e,t,n,s,i=this.opts.es5?Be.varKinds.var:Be.varKinds.let){let a=this._scope.toName(e);return this._for(new ji(i,a,t,n),()=>s(a))}forOf(e,t,n,s=Be.varKinds.const){let i=this._scope.toName(e);if(this.opts.es5){let a=t instanceof M.Name?t:this.var("_arr",t);return this.forRange("_i",0,(0,M._)`${a}.length`,c=>{this.var(i,(0,M._)`${a}[${c}]`),n(i)})}return this._for(new us("of",s,i,t),()=>n(i))}forIn(e,t,n,s=this.opts.es5?Be.varKinds.var:Be.varKinds.const){if(this.opts.ownProperties)return this.forOf(e,(0,M._)`Object.keys(${t})`,n);let i=this._scope.toName(e);return this._for(new us("in",s,i,t),()=>n(i))}endFor(){return this._endBlockNode(Kt)}label(e){return this._leafNode(new Ni(e))}break(e){return this._leafNode(new Ii(e))}return(e){let t=new gn;if(this._blockNode(t),this.code(e),t.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(gn)}try(e,t,n){if(!t&&!n)throw new Error('CodeGen: "try" without "catch" and "finally"');let s=new ki;if(this._blockNode(s),this.code(e),t){let i=this.name("e");this._currNode=s.catch=new vn(i),t(i)}return n&&(this._currNode=s.finally=new _n,this.code(n)),this._endBlockNode(vn,_n)}throw(e){return this._leafNode(new Ti(e))}block(e,t){return this._blockStarts.push(this._nodes.length),e&&this.code(e).endBlock(t),this}endBlock(e){let t=this._blockStarts.pop();if(t===void 0)throw new Error("CodeGen: not in self-balancing block");let n=this._nodes.length-t;if(n<0||e!==void 0&&n!==e)throw new Error(`CodeGen: wrong number of nodes: ${n} vs ${e} expected`);return this._nodes.length=t,this}func(e,t=M.nil,n,s){return this._blockNode(new mn(e,t,n)),s&&this.code(s).endFunc(),this}endFunc(){return this._endBlockNode(mn)}optimize(e=1){for(;e-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(e){return this._currNode.nodes.push(e),this}_blockNode(e){this._currNode.nodes.push(e),this._nodes.push(e)}_endBlockNode(e,t){let n=this._currNode;if(n instanceof e||t&&n instanceof t)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${t?`${e.kind}/${t.kind}`:e.kind}"`)}_elseNode(e){let t=this._currNode;if(!(t instanceof Je))throw new Error('CodeGen: "else" without "if"');return this._currNode=t.else=e,this}get _root(){return this._nodes[0]}get _currNode(){let e=this._nodes;return e[e.length-1]}set _currNode(e){let t=this._nodes;t[t.length-1]=e}};k.CodeGen=xi;function Xt(r,e){for(let t in e)r[t]=(r[t]||0)+(e[t]||0);return r}function ls(r,e){return e instanceof M._CodeOrName?Xt(r,e.names):r}function wr(r,e,t){if(r instanceof M.Name)return n(r);if(!s(r))return r;return new M._Code(r._items.reduce((i,a)=>(a instanceof M.Name&&(a=n(a)),a instanceof M._Code?i.push(...a._items):i.push(a),i),[]));function n(i){let a=t[i.str];return a===void 0||e[i.str]!==1?i:(delete e[i.str],a)}function s(i){return i instanceof M._Code&&i._items.some(a=>a instanceof M.Name&&e[a.str]===1&&t[a.str]!==void 0)}}function mv(r,e){for(let t in e)r[t]=(r[t]||0)-(e[t]||0)}function tl(r){return typeof r=="boolean"||typeof r=="number"||r===null?!r:(0,M._)`!${Li(r)}`}k.not=tl;var gv=rl(k.operators.AND);function vv(...r){return r.reduce(gv)}k.and=vv;var _v=rl(k.operators.OR);function yv(...r){return r.reduce(_v)}k.or=yv;function rl(r){return(e,t)=>e===M.nil?t:t===M.nil?e:(0,M._)`${Li(e)} ${r} ${Li(t)}`}function Li(r){return r instanceof M.Name?r:(0,M._)`(${r})`}});var G=_(x=>{"use strict";Object.defineProperty(x,"__esModule",{value:!0});x.checkStrictMode=x.getErrorPath=x.Type=x.useFunc=x.setEvaluated=x.evaluatedPropsToName=x.mergeEvaluated=x.eachItem=x.unescapeJsonPointer=x.escapeJsonPointer=x.escapeFragment=x.unescapeFragment=x.schemaRefOrVal=x.schemaHasRulesButRef=x.schemaHasRules=x.checkUnknownRules=x.alwaysValidSchema=x.toHash=void 0;var Z=L(),$v=hn();function Ev(r){let e={};for(let t of r)e[t]=!0;return e}x.toHash=Ev;function wv(r,e){return typeof e=="boolean"?e:Object.keys(e).length===0?!0:(il(r,e),!al(e,r.self.RULES.all))}x.alwaysValidSchema=wv;function il(r,e=r.schema){let{opts:t,self:n}=r;if(!t.strictSchema||typeof e=="boolean")return;let s=n.RULES.keywords;for(let i in e)s[i]||ll(r,`unknown keyword: "${i}"`)}x.checkUnknownRules=il;function al(r,e){if(typeof r=="boolean")return!r;for(let t in r)if(e[t])return!0;return!1}x.schemaHasRules=al;function bv(r,e){if(typeof r=="boolean")return!r;for(let t in r)if(t!=="$ref"&&e.all[t])return!0;return!1}x.schemaHasRulesButRef=bv;function Sv({topSchemaRef:r,schemaPath:e},t,n,s){if(!s){if(typeof t=="number"||typeof t=="boolean")return t;if(typeof t=="string")return(0,Z._)`${t}`}return(0,Z._)`${r}${e}${(0,Z.getProperty)(n)}`}x.schemaRefOrVal=Sv;function Ov(r){return ol(decodeURIComponent(r))}x.unescapeFragment=Ov;function Pv(r){return encodeURIComponent(Mi(r))}x.escapeFragment=Pv;function Mi(r){return typeof r=="number"?`${r}`:r.replace(/~/g,"~0").replace(/\//g,"~1")}x.escapeJsonPointer=Mi;function ol(r){return r.replace(/~1/g,"/").replace(/~0/g,"~")}x.unescapeJsonPointer=ol;function Rv(r,e){if(Array.isArray(r))for(let t of r)e(t);else e(r)}x.eachItem=Rv;function nl({mergeNames:r,mergeToName:e,mergeValues:t,resultToName:n}){return(s,i,a,c)=>{let u=a===void 0?i:a instanceof Z.Name?(i instanceof Z.Name?r(s,i,a):e(s,i,a),a):i instanceof Z.Name?(e(s,a,i),i):t(i,a);return c===Z.Name&&!(u instanceof Z.Name)?n(s,u):u}}x.mergeEvaluated={props:nl({mergeNames:(r,e,t)=>r.if((0,Z._)`${t} !== true && ${e} !== undefined`,()=>{r.if((0,Z._)`${e} === true`,()=>r.assign(t,!0),()=>r.assign(t,(0,Z._)`${t} || {}`).code((0,Z._)`Object.assign(${t}, ${e})`))}),mergeToName:(r,e,t)=>r.if((0,Z._)`${t} !== true`,()=>{e===!0?r.assign(t,!0):(r.assign(t,(0,Z._)`${t} || {}`),Fi(r,t,e))}),mergeValues:(r,e)=>r===!0?!0:{...r,...e},resultToName:cl}),items:nl({mergeNames:(r,e,t)=>r.if((0,Z._)`${t} !== true && ${e} !== undefined`,()=>r.assign(t,(0,Z._)`${e} === true ? true : ${t} > ${e} ? ${t} : ${e}`)),mergeToName:(r,e,t)=>r.if((0,Z._)`${t} !== true`,()=>r.assign(t,e===!0?!0:(0,Z._)`${t} > ${e} ? ${t} : ${e}`)),mergeValues:(r,e)=>r===!0?!0:Math.max(r,e),resultToName:(r,e)=>r.var("items",e)})};function cl(r,e){if(e===!0)return r.var("props",!0);let t=r.var("props",(0,Z._)`{}`);return e!==void 0&&Fi(r,t,e),t}x.evaluatedPropsToName=cl;function Fi(r,e,t){Object.keys(t).forEach(n=>r.assign((0,Z._)`${e}${(0,Z.getProperty)(n)}`,!0))}x.setEvaluated=Fi;var sl={};function Cv(r,e){return r.scopeValue("func",{ref:e,code:sl[e.code]||(sl[e.code]=new $v._Code(e.code))})}x.useFunc=Cv;var ul;(function(r){r[r.Num=0]="Num",r[r.Str=1]="Str"})(ul=x.Type||(x.Type={}));function Nv(r,e,t){if(r instanceof Z.Name){let n=e===ul.Num;return t?n?(0,Z._)`"[" + ${r} + "]"`:(0,Z._)`"['" + ${r} + "']"`:n?(0,Z._)`"/" + ${r}`:(0,Z._)`"/" + ${r}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return t?(0,Z.getProperty)(r).toString():"/"+Mi(r)}x.getErrorPath=Nv;function ll(r,e,t=r.opts.strictSchema){if(!!t){if(e=`strict mode: ${e}`,t===!0)throw new Error(e);r.self.logger.warn(e)}}x.checkStrictMode=ll});var $t=_(Vi=>{"use strict";Object.defineProperty(Vi,"__esModule",{value:!0});var _e=L(),Iv={data:new _e.Name("data"),valCxt:new _e.Name("valCxt"),instancePath:new _e.Name("instancePath"),parentData:new _e.Name("parentData"),parentDataProperty:new _e.Name("parentDataProperty"),rootData:new _e.Name("rootData"),dynamicAnchors:new _e.Name("dynamicAnchors"),vErrors:new _e.Name("vErrors"),errors:new _e.Name("errors"),this:new _e.Name("this"),self:new _e.Name("self"),scope:new _e.Name("scope"),json:new _e.Name("json"),jsonPos:new _e.Name("jsonPos"),jsonLen:new _e.Name("jsonLen"),jsonPart:new _e.Name("jsonPart")};Vi.default=Iv});var yn=_(ye=>{"use strict";Object.defineProperty(ye,"__esModule",{value:!0});ye.extendErrors=ye.resetErrorsCount=ye.reportExtraError=ye.reportError=ye.keyword$DataError=ye.keywordError=void 0;var V=L(),ds=G(),Se=$t();ye.keywordError={message:({keyword:r})=>(0,V.str)`must pass "${r}" keyword validation`};ye.keyword$DataError={message:({keyword:r,schemaType:e})=>e?(0,V.str)`"${r}" keyword must be ${e} ($data)`:(0,V.str)`"${r}" keyword is invalid ($data)`};function Tv(r,e=ye.keywordError,t,n){let{it:s}=r,{gen:i,compositeRule:a,allErrors:c}=s,u=hl(r,e,t);(n!=null?n:a||c)?fl(i,u):dl(s,(0,V._)`[${u}]`)}ye.reportError=Tv;function Av(r,e=ye.keywordError,t){let{it:n}=r,{gen:s,compositeRule:i,allErrors:a}=n,c=hl(r,e,t);fl(s,c),i||a||dl(n,Se.default.vErrors)}ye.reportExtraError=Av;function qv(r,e){r.assign(Se.default.errors,e),r.if((0,V._)`${Se.default.vErrors} !== null`,()=>r.if(e,()=>r.assign((0,V._)`${Se.default.vErrors}.length`,e),()=>r.assign(Se.default.vErrors,null)))}ye.resetErrorsCount=qv;function Dv({gen:r,keyword:e,schemaValue:t,data:n,errsCount:s,it:i}){if(s===void 0)throw new Error("ajv implementation error");let a=r.name("err");r.forRange("i",s,Se.default.errors,c=>{r.const(a,(0,V._)`${Se.default.vErrors}[${c}]`),r.if((0,V._)`${a}.instancePath === undefined`,()=>r.assign((0,V._)`${a}.instancePath`,(0,V.strConcat)(Se.default.instancePath,i.errorPath))),r.assign((0,V._)`${a}.schemaPath`,(0,V.str)`${i.errSchemaPath}/${e}`),i.opts.verbose&&(r.assign((0,V._)`${a}.schema`,t),r.assign((0,V._)`${a}.data`,n))})}ye.extendErrors=Dv;function fl(r,e){let t=r.const("err",e);r.if((0,V._)`${Se.default.vErrors} === null`,()=>r.assign(Se.default.vErrors,(0,V._)`[${t}]`),(0,V._)`${Se.default.vErrors}.push(${t})`),r.code((0,V._)`${Se.default.errors}++`)}function dl(r,e){let{gen:t,validateName:n,schemaEnv:s}=r;s.$async?t.throw((0,V._)`new ${r.ValidationError}(${e})`):(t.assign((0,V._)`${n}.errors`,e),t.return(!1))}var Wt={keyword:new V.Name("keyword"),schemaPath:new V.Name("schemaPath"),params:new V.Name("params"),propertyName:new V.Name("propertyName"),message:new V.Name("message"),schema:new V.Name("schema"),parentSchema:new V.Name("parentSchema")};function hl(r,e,t){let{createErrors:n}=r.it;return n===!1?(0,V._)`{}`:jv(r,e,t)}function jv(r,e,t={}){let{gen:n,it:s}=r,i=[kv(s,t),xv(r,t)];return Lv(r,e,i),n.object(...i)}function kv({errorPath:r},{instancePath:e}){let t=e?(0,V.str)`${r}${(0,ds.getErrorPath)(e,ds.Type.Str)}`:r;return[Se.default.instancePath,(0,V.strConcat)(Se.default.instancePath,t)]}function xv({keyword:r,it:{errSchemaPath:e}},{schemaPath:t,parentSchema:n}){let s=n?e:(0,V.str)`${e}/${r}`;return t&&(s=(0,V.str)`${s}${(0,ds.getErrorPath)(t,ds.Type.Str)}`),[Wt.schemaPath,s]}function Lv(r,{params:e,message:t},n){let{keyword:s,data:i,schemaValue:a,it:c}=r,{opts:u,propertyName:o,topSchemaRef:l,schemaPath:d}=c;n.push([Wt.keyword,s],[Wt.params,typeof e=="function"?e(r):e||(0,V._)`{}`]),u.messages&&n.push([Wt.message,typeof t=="function"?t(r):t]),u.verbose&&n.push([Wt.schema,a],[Wt.parentSchema,(0,V._)`${l}${d}`],[Se.default.data,i]),o&&n.push([Wt.propertyName,o])}});var ml=_(br=>{"use strict";Object.defineProperty(br,"__esModule",{value:!0});br.boolOrEmptySchema=br.topBoolOrEmptySchema=void 0;var Mv=yn(),Fv=L(),Vv=$t(),Hv={message:"boolean schema is false"};function Uv(r){let{gen:e,schema:t,validateName:n}=r;t===!1?pl(r,!1):typeof t=="object"&&t.$async===!0?e.return(Vv.default.data):(e.assign((0,Fv._)`${n}.errors`,null),e.return(!0))}br.topBoolOrEmptySchema=Uv;function Gv(r,e){let{gen:t,schema:n}=r;n===!1?(t.var(e,!1),pl(r)):t.var(e,!0)}br.boolOrEmptySchema=Gv;function pl(r,e){let{gen:t,data:n}=r,s={gen:t,keyword:"false schema",data:n,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:r};(0,Mv.reportError)(s,Hv,void 0,e)}});var Hi=_(Sr=>{"use strict";Object.defineProperty(Sr,"__esModule",{value:!0});Sr.getRules=Sr.isJSONType=void 0;var zv=["string","number","integer","boolean","null","object","array"],Kv=new Set(zv);function Xv(r){return typeof r=="string"&&Kv.has(r)}Sr.isJSONType=Xv;function Wv(){let r={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...r,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},r.number,r.string,r.array,r.object],post:{rules:[]},all:{},keywords:{}}}Sr.getRules=Wv});var Ui=_(Rt=>{"use strict";Object.defineProperty(Rt,"__esModule",{value:!0});Rt.shouldUseRule=Rt.shouldUseGroup=Rt.schemaHasRulesForType=void 0;function Bv({schema:r,self:e},t){let n=e.RULES.types[t];return n&&n!==!0&&gl(r,n)}Rt.schemaHasRulesForType=Bv;function gl(r,e){return e.rules.some(t=>vl(r,t))}Rt.shouldUseGroup=gl;function vl(r,e){var t;return r[e.keyword]!==void 0||((t=e.definition.implements)===null||t===void 0?void 0:t.some(n=>r[n]!==void 0))}Rt.shouldUseRule=vl});var En=_(de=>{"use strict";Object.defineProperty(de,"__esModule",{value:!0});de.reportTypeError=de.checkDataTypes=de.checkDataType=de.coerceAndCheckDataType=de.getJSONTypes=de.getSchemaTypes=de.DataType=void 0;var Jv=Hi(),Yv=Ui(),Zv=yn(),q=L(),_l=G(),$n;(function(r){r[r.Correct=0]="Correct",r[r.Wrong=1]="Wrong"})($n=de.DataType||(de.DataType={}));function Qv(r){let e=yl(r.type);if(e.includes("null")){if(r.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!e.length&&r.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');r.nullable===!0&&e.push("null")}return e}de.getSchemaTypes=Qv;function yl(r){let e=Array.isArray(r)?r:r?[r]:[];if(e.every(Jv.isJSONType))return e;throw new Error("type must be JSONType or JSONType[]: "+e.join(","))}de.getJSONTypes=yl;function e_(r,e){let{gen:t,data:n,opts:s}=r,i=t_(e,s.coerceTypes),a=e.length>0&&!(i.length===0&&e.length===1&&(0,Yv.schemaHasRulesForType)(r,e[0]));if(a){let c=zi(e,n,s.strictNumbers,$n.Wrong);t.if(c,()=>{i.length?r_(r,e,i):Ki(r)})}return a}de.coerceAndCheckDataType=e_;var $l=new Set(["string","number","integer","boolean","null"]);function t_(r,e){return e?r.filter(t=>$l.has(t)||e==="array"&&t==="array"):[]}function r_(r,e,t){let{gen:n,data:s,opts:i}=r,a=n.let("dataType",(0,q._)`typeof ${s}`),c=n.let("coerced",(0,q._)`undefined`);i.coerceTypes==="array"&&n.if((0,q._)`${a} == 'object' && Array.isArray(${s}) && ${s}.length == 1`,()=>n.assign(s,(0,q._)`${s}[0]`).assign(a,(0,q._)`typeof ${s}`).if(zi(e,s,i.strictNumbers),()=>n.assign(c,s))),n.if((0,q._)`${c} !== undefined`);for(let o of t)($l.has(o)||o==="array"&&i.coerceTypes==="array")&&u(o);n.else(),Ki(r),n.endIf(),n.if((0,q._)`${c} !== undefined`,()=>{n.assign(s,c),n_(r,c)});function u(o){switch(o){case"string":n.elseIf((0,q._)`${a} == "number" || ${a} == "boolean"`).assign(c,(0,q._)`"" + ${s}`).elseIf((0,q._)`${s} === null`).assign(c,(0,q._)`""`);return;case"number":n.elseIf((0,q._)`${a} == "boolean" || ${s} === null
|
|
23
|
-
|| (${a} == "string" && ${s} && ${s} == +${s})`).assign(c,(0,
|
|
24
|
-
|| (${a} === "string" && ${s} && ${s} == +${s} && !(${s} % 1))`).assign(c,(0,
|
|
25
|
-
|| ${a} === "boolean" || ${s} === null`).assign(c,(0,q._)`[${s}]`)}}}function n_({gen:r,parentData:e,parentDataProperty:t},n){r.if((0,q._)`${e} !== undefined`,()=>r.assign((0,q._)`${e}[${t}]`,n))}function Gi(r,e,t,n=$n.Correct){let s=n===$n.Correct?q.operators.EQ:q.operators.NEQ,i;switch(r){case"null":return(0,q._)`${e} ${s} null`;case"array":i=(0,q._)`Array.isArray(${e})`;break;case"object":i=(0,q._)`${e} && typeof ${e} == "object" && !Array.isArray(${e})`;break;case"integer":i=a((0,q._)`!(${e} % 1) && !isNaN(${e})`);break;case"number":i=a();break;default:return(0,q._)`typeof ${e} ${s} ${r}`}return n===$n.Correct?i:(0,q.not)(i);function a(c=q.nil){return(0,q.and)((0,q._)`typeof ${e} == "number"`,c,t?(0,q._)`isFinite(${e})`:q.nil)}}de.checkDataType=Gi;function zi(r,e,t,n){if(r.length===1)return Gi(r[0],e,t,n);let s,i=(0,_l.toHash)(r);if(i.array&&i.object){let a=(0,q._)`typeof ${e} != "object"`;s=i.null?a:(0,q._)`!${e} || ${a}`,delete i.null,delete i.array,delete i.object}else s=q.nil;i.number&&delete i.integer;for(let a in i)s=(0,q.and)(s,Gi(a,e,t,n));return s}de.checkDataTypes=zi;var s_={message:({schema:r})=>`must be ${r}`,params:({schema:r,schemaValue:e})=>typeof r=="string"?(0,q._)`{type: ${r}}`:(0,q._)`{type: ${e}}`};function Ki(r){let e=i_(r);(0,Zv.reportError)(e,s_)}de.reportTypeError=Ki;function i_(r){let{gen:e,data:t,schema:n}=r,s=(0,_l.schemaRefOrVal)(r,n,"type");return{gen:e,keyword:"type",data:t,schema:n.type,schemaCode:s,schemaValue:s,parentSchema:n,params:{},it:r}}});var wl=_(hs=>{"use strict";Object.defineProperty(hs,"__esModule",{value:!0});hs.assignDefaults=void 0;var Or=L(),a_=G();function o_(r,e){let{properties:t,items:n}=r.schema;if(e==="object"&&t)for(let s in t)El(r,s,t[s].default);else e==="array"&&Array.isArray(n)&&n.forEach((s,i)=>El(r,i,s.default))}hs.assignDefaults=o_;function El(r,e,t){let{gen:n,compositeRule:s,data:i,opts:a}=r;if(t===void 0)return;let c=(0,Or._)`${i}${(0,Or.getProperty)(e)}`;if(s){(0,a_.checkStrictMode)(r,`default is ignored for: ${c}`);return}let u=(0,Or._)`${c} === undefined`;a.useDefaults==="empty"&&(u=(0,Or._)`${u} || ${c} === null || ${c} === ""`),n.if(u,(0,Or._)`${c} = ${(0,Or.stringify)(t)}`)}});var ze=_(J=>{"use strict";Object.defineProperty(J,"__esModule",{value:!0});J.validateUnion=J.validateArray=J.usePattern=J.callValidateCode=J.schemaProperties=J.allSchemaProperties=J.noPropertyInData=J.propertyInData=J.isOwnProperty=J.hasPropFunc=J.reportMissingProp=J.checkMissingProp=J.checkReportMissingProp=void 0;var te=L(),Xi=G(),Ct=$t(),c_=G();function u_(r,e){let{gen:t,data:n,it:s}=r;t.if(Bi(t,n,e,s.opts.ownProperties),()=>{r.setParams({missingProperty:(0,te._)`${e}`},!0),r.error()})}J.checkReportMissingProp=u_;function l_({gen:r,data:e,it:{opts:t}},n,s){return(0,te.or)(...n.map(i=>(0,te.and)(Bi(r,e,i,t.ownProperties),(0,te._)`${s} = ${i}`)))}J.checkMissingProp=l_;function f_(r,e){r.setParams({missingProperty:e},!0),r.error()}J.reportMissingProp=f_;function bl(r){return r.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,te._)`Object.prototype.hasOwnProperty`})}J.hasPropFunc=bl;function Wi(r,e,t){return(0,te._)`${bl(r)}.call(${e}, ${t})`}J.isOwnProperty=Wi;function d_(r,e,t,n){let s=(0,te._)`${e}${(0,te.getProperty)(t)} !== undefined`;return n?(0,te._)`${s} && ${Wi(r,e,t)}`:s}J.propertyInData=d_;function Bi(r,e,t,n){let s=(0,te._)`${e}${(0,te.getProperty)(t)} === undefined`;return n?(0,te.or)(s,(0,te.not)(Wi(r,e,t))):s}J.noPropertyInData=Bi;function Sl(r){return r?Object.keys(r).filter(e=>e!=="__proto__"):[]}J.allSchemaProperties=Sl;function h_(r,e){return Sl(e).filter(t=>!(0,Xi.alwaysValidSchema)(r,e[t]))}J.schemaProperties=h_;function p_({schemaCode:r,data:e,it:{gen:t,topSchemaRef:n,schemaPath:s,errorPath:i},it:a},c,u,o){let l=o?(0,te._)`${r}, ${e}, ${n}${s}`:e,d=[[Ct.default.instancePath,(0,te.strConcat)(Ct.default.instancePath,i)],[Ct.default.parentData,a.parentData],[Ct.default.parentDataProperty,a.parentDataProperty],[Ct.default.rootData,Ct.default.rootData]];a.opts.dynamicRef&&d.push([Ct.default.dynamicAnchors,Ct.default.dynamicAnchors]);let y=(0,te._)`${l}, ${t.object(...d)}`;return u!==te.nil?(0,te._)`${c}.call(${u}, ${y})`:(0,te._)`${c}(${y})`}J.callValidateCode=p_;var m_=(0,te._)`new RegExp`;function g_({gen:r,it:{opts:e}},t){let n=e.unicodeRegExp?"u":"",{regExp:s}=e.code,i=s(t,n);return r.scopeValue("pattern",{key:i.toString(),ref:i,code:(0,te._)`${s.code==="new RegExp"?m_:(0,c_.useFunc)(r,s)}(${t}, ${n})`})}J.usePattern=g_;function v_(r){let{gen:e,data:t,keyword:n,it:s}=r,i=e.name("valid");if(s.allErrors){let c=e.let("valid",!0);return a(()=>e.assign(c,!1)),c}return e.var(i,!0),a(()=>e.break()),i;function a(c){let u=e.const("len",(0,te._)`${t}.length`);e.forRange("i",0,u,o=>{r.subschema({keyword:n,dataProp:o,dataPropType:Xi.Type.Num},i),e.if((0,te.not)(i),c)})}}J.validateArray=v_;function __(r){let{gen:e,schema:t,keyword:n,it:s}=r;if(!Array.isArray(t))throw new Error("ajv implementation error");if(t.some(u=>(0,Xi.alwaysValidSchema)(s,u))&&!s.opts.unevaluated)return;let a=e.let("valid",!1),c=e.name("_valid");e.block(()=>t.forEach((u,o)=>{let l=r.subschema({keyword:n,schemaProp:o,compositeRule:!0},c);e.assign(a,(0,te._)`${a} || ${c}`),r.mergeValidEvaluated(l,c)||e.if((0,te.not)(a))})),r.result(a,()=>r.reset(),()=>r.error(!0))}J.validateUnion=__});var Rl=_(at=>{"use strict";Object.defineProperty(at,"__esModule",{value:!0});at.validateKeywordUsage=at.validSchemaType=at.funcKeywordCode=at.macroKeywordCode=void 0;var Oe=L(),Bt=$t(),y_=ze(),$_=yn();function E_(r,e){let{gen:t,keyword:n,schema:s,parentSchema:i,it:a}=r,c=e.macro.call(a.self,s,i,a),u=Pl(t,n,c);a.opts.validateSchema!==!1&&a.self.validateSchema(c,!0);let o=t.name("valid");r.subschema({schema:c,schemaPath:Oe.nil,errSchemaPath:`${a.errSchemaPath}/${n}`,topSchemaRef:u,compositeRule:!0},o),r.pass(o,()=>r.error(!0))}at.macroKeywordCode=E_;function w_(r,e){var t;let{gen:n,keyword:s,schema:i,parentSchema:a,$data:c,it:u}=r;S_(u,e);let o=!c&&e.compile?e.compile.call(u.self,i,a,u):e.validate,l=Pl(n,s,o),d=n.let("valid");r.block$data(d,y),r.ok((t=e.valid)!==null&&t!==void 0?t:d);function y(){if(e.errors===!1)E(),e.modifying&&Ol(r),w(()=>r.error());else{let b=e.async?m():$();e.modifying&&Ol(r),w(()=>b_(r,b))}}function m(){let b=n.let("ruleErrs",null);return n.try(()=>E((0,Oe._)`await `),D=>n.assign(d,!1).if((0,Oe._)`${D} instanceof ${u.ValidationError}`,()=>n.assign(b,(0,Oe._)`${D}.errors`),()=>n.throw(D))),b}function $(){let b=(0,Oe._)`${l}.errors`;return n.assign(b,null),E(Oe.nil),b}function E(b=e.async?(0,Oe._)`await `:Oe.nil){let D=u.opts.passContext?Bt.default.this:Bt.default.self,T=!("compile"in e&&!c||e.schema===!1);n.assign(d,(0,Oe._)`${b}${(0,y_.callValidateCode)(r,l,D,T)}`,e.modifying)}function w(b){var D;n.if((0,Oe.not)((D=e.valid)!==null&&D!==void 0?D:d),b)}}at.funcKeywordCode=w_;function Ol(r){let{gen:e,data:t,it:n}=r;e.if(n.parentData,()=>e.assign(t,(0,Oe._)`${n.parentData}[${n.parentDataProperty}]`))}function b_(r,e){let{gen:t}=r;t.if((0,Oe._)`Array.isArray(${e})`,()=>{t.assign(Bt.default.vErrors,(0,Oe._)`${Bt.default.vErrors} === null ? ${e} : ${Bt.default.vErrors}.concat(${e})`).assign(Bt.default.errors,(0,Oe._)`${Bt.default.vErrors}.length`),(0,$_.extendErrors)(r)},()=>r.error())}function S_({schemaEnv:r},e){if(e.async&&!r.$async)throw new Error("async keyword in sync schema")}function Pl(r,e,t){if(t===void 0)throw new Error(`keyword "${e}" failed to compile`);return r.scopeValue("keyword",typeof t=="function"?{ref:t}:{ref:t,code:(0,Oe.stringify)(t)})}function O_(r,e,t=!1){return!e.length||e.some(n=>n==="array"?Array.isArray(r):n==="object"?r&&typeof r=="object"&&!Array.isArray(r):typeof r==n||t&&typeof r>"u")}at.validSchemaType=O_;function P_({schema:r,opts:e,self:t,errSchemaPath:n},s,i){if(Array.isArray(s.keyword)?!s.keyword.includes(i):s.keyword!==i)throw new Error("ajv implementation error");let a=s.dependencies;if(a!=null&&a.some(c=>!Object.prototype.hasOwnProperty.call(r,c)))throw new Error(`parent schema must have dependencies of ${i}: ${a.join(",")}`);if(s.validateSchema&&!s.validateSchema(r[i])){let u=`keyword "${i}" value is invalid at path "${n}": `+t.errorsText(s.validateSchema.errors);if(e.validateSchema==="log")t.logger.error(u);else throw new Error(u)}}at.validateKeywordUsage=P_});var Nl=_(Nt=>{"use strict";Object.defineProperty(Nt,"__esModule",{value:!0});Nt.extendSubschemaMode=Nt.extendSubschemaData=Nt.getSubschema=void 0;var ot=L(),Cl=G();function R_(r,{keyword:e,schemaProp:t,schema:n,schemaPath:s,errSchemaPath:i,topSchemaRef:a}){if(e!==void 0&&n!==void 0)throw new Error('both "keyword" and "schema" passed, only one allowed');if(e!==void 0){let c=r.schema[e];return t===void 0?{schema:c,schemaPath:(0,ot._)`${r.schemaPath}${(0,ot.getProperty)(e)}`,errSchemaPath:`${r.errSchemaPath}/${e}`}:{schema:c[t],schemaPath:(0,ot._)`${r.schemaPath}${(0,ot.getProperty)(e)}${(0,ot.getProperty)(t)}`,errSchemaPath:`${r.errSchemaPath}/${e}/${(0,Cl.escapeFragment)(t)}`}}if(n!==void 0){if(s===void 0||i===void 0||a===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:n,schemaPath:s,topSchemaRef:a,errSchemaPath:i}}throw new Error('either "keyword" or "schema" must be passed')}Nt.getSubschema=R_;function C_(r,e,{dataProp:t,dataPropType:n,data:s,dataTypes:i,propertyName:a}){if(s!==void 0&&t!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');let{gen:c}=e;if(t!==void 0){let{errorPath:o,dataPathArr:l,opts:d}=e,y=c.let("data",(0,ot._)`${e.data}${(0,ot.getProperty)(t)}`,!0);u(y),r.errorPath=(0,ot.str)`${o}${(0,Cl.getErrorPath)(t,n,d.jsPropertySyntax)}`,r.parentDataProperty=(0,ot._)`${t}`,r.dataPathArr=[...l,r.parentDataProperty]}if(s!==void 0){let o=s instanceof ot.Name?s:c.let("data",s,!0);u(o),a!==void 0&&(r.propertyName=a)}i&&(r.dataTypes=i);function u(o){r.data=o,r.dataLevel=e.dataLevel+1,r.dataTypes=[],e.definedProperties=new Set,r.parentData=e.data,r.dataNames=[...e.dataNames,o]}}Nt.extendSubschemaData=C_;function N_(r,{jtdDiscriminator:e,jtdMetadata:t,compositeRule:n,createErrors:s,allErrors:i}){n!==void 0&&(r.compositeRule=n),s!==void 0&&(r.createErrors=s),i!==void 0&&(r.allErrors=i),r.jtdDiscriminator=e,r.jtdMetadata=t}Nt.extendSubschemaMode=N_});var Ji=_((Ib,Il)=>{"use strict";Il.exports=function r(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var n,s,i;if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(s=n;s--!==0;)if(!r(e[s],t[s]))return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(s=n;s--!==0;)if(!Object.prototype.hasOwnProperty.call(t,i[s]))return!1;for(s=n;s--!==0;){var a=i[s];if(!r(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}});var Al=_((Tb,Tl)=>{"use strict";var It=Tl.exports=function(r,e,t){typeof e=="function"&&(t=e,e={}),t=e.cb||t;var n=typeof t=="function"?t:t.pre||function(){},s=t.post||function(){};ps(e,n,s,r,"",r)};It.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};It.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};It.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};It.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function ps(r,e,t,n,s,i,a,c,u,o){if(n&&typeof n=="object"&&!Array.isArray(n)){e(n,s,i,a,c,u,o);for(var l in n){var d=n[l];if(Array.isArray(d)){if(l in It.arrayKeywords)for(var y=0;y<d.length;y++)ps(r,e,t,d[y],s+"/"+l+"/"+y,i,s,l,n,y)}else if(l in It.propsKeywords){if(d&&typeof d=="object")for(var m in d)ps(r,e,t,d[m],s+"/"+l+"/"+I_(m),i,s,l,n,m)}else(l in It.keywords||r.allKeys&&!(l in It.skipKeywords))&&ps(r,e,t,d,s+"/"+l,i,s,l,n)}t(n,s,i,a,c,u,o)}}function I_(r){return r.replace(/~/g,"~0").replace(/\//g,"~1")}});var wn=_(Ne=>{"use strict";Object.defineProperty(Ne,"__esModule",{value:!0});Ne.getSchemaRefs=Ne.resolveUrl=Ne.normalizeId=Ne._getFullPath=Ne.getFullPath=Ne.inlineRef=void 0;var T_=G(),A_=Ji(),q_=Al(),D_=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function j_(r,e=!0){return typeof r=="boolean"?!0:e===!0?!Yi(r):e?ql(r)<=e:!1}Ne.inlineRef=j_;var k_=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function Yi(r){for(let e in r){if(k_.has(e))return!0;let t=r[e];if(Array.isArray(t)&&t.some(Yi)||typeof t=="object"&&Yi(t))return!0}return!1}function ql(r){let e=0;for(let t in r){if(t==="$ref")return 1/0;if(e++,!D_.has(t)&&(typeof r[t]=="object"&&(0,T_.eachItem)(r[t],n=>e+=ql(n)),e===1/0))return 1/0}return e}function Dl(r,e="",t){t!==!1&&(e=Pr(e));let n=r.parse(e);return jl(r,n)}Ne.getFullPath=Dl;function jl(r,e){return r.serialize(e).split("#")[0]+"#"}Ne._getFullPath=jl;var x_=/#\/?$/;function Pr(r){return r?r.replace(x_,""):""}Ne.normalizeId=Pr;function L_(r,e,t){return t=Pr(t),r.resolve(e,t)}Ne.resolveUrl=L_;var M_=/^[a-z_][-a-z0-9._]*$/i;function F_(r,e){if(typeof r=="boolean")return{};let{schemaId:t,uriResolver:n}=this.opts,s=Pr(r[t]||e),i={"":s},a=Dl(n,s,!1),c={},u=new Set;return q_(r,{allKeys:!0},(d,y,m,$)=>{if($===void 0)return;let E=a+y,w=i[$];typeof d[t]=="string"&&(w=b.call(this,d[t])),D.call(this,d.$anchor),D.call(this,d.$dynamicAnchor),i[y]=w;function b(T){let z=this.opts.uriResolver.resolve;if(T=Pr(w?z(w,T):T),u.has(T))throw l(T);u.add(T);let C=this.refs[T];return typeof C=="string"&&(C=this.refs[C]),typeof C=="object"?o(d,C.schema,T):T!==Pr(E)&&(T[0]==="#"?(o(d,c[T],T),c[T]=d):this.refs[T]=E),T}function D(T){if(typeof T=="string"){if(!M_.test(T))throw new Error(`invalid anchor "${T}"`);b.call(this,`#${T}`)}}}),c;function o(d,y,m){if(y!==void 0&&!A_(d,y))throw l(m)}function l(d){return new Error(`reference "${d}" resolves to more than one schema`)}}Ne.getSchemaRefs=F_});var On=_(Tt=>{"use strict";Object.defineProperty(Tt,"__esModule",{value:!0});Tt.getData=Tt.KeywordCxt=Tt.validateFunctionCode=void 0;var Vl=ml(),kl=En(),Qi=Ui(),ms=En(),V_=wl(),Sn=Rl(),Zi=Nl(),R=L(),I=$t(),H_=wn(),Et=G(),bn=yn();function U_(r){if(Gl(r)&&(zl(r),Ul(r))){K_(r);return}Hl(r,()=>(0,Vl.topBoolOrEmptySchema)(r))}Tt.validateFunctionCode=U_;function Hl({gen:r,validateName:e,schema:t,schemaEnv:n,opts:s},i){s.code.es5?r.func(e,(0,R._)`${I.default.data}, ${I.default.valCxt}`,n.$async,()=>{r.code((0,R._)`"use strict"; ${xl(t,s)}`),z_(r,s),r.code(i)}):r.func(e,(0,R._)`${I.default.data}, ${G_(s)}`,n.$async,()=>r.code(xl(t,s)).code(i))}function G_(r){return(0,R._)`{${I.default.instancePath}="", ${I.default.parentData}, ${I.default.parentDataProperty}, ${I.default.rootData}=${I.default.data}${r.dynamicRef?(0,R._)`, ${I.default.dynamicAnchors}={}`:R.nil}}={}`}function z_(r,e){r.if(I.default.valCxt,()=>{r.var(I.default.instancePath,(0,R._)`${I.default.valCxt}.${I.default.instancePath}`),r.var(I.default.parentData,(0,R._)`${I.default.valCxt}.${I.default.parentData}`),r.var(I.default.parentDataProperty,(0,R._)`${I.default.valCxt}.${I.default.parentDataProperty}`),r.var(I.default.rootData,(0,R._)`${I.default.valCxt}.${I.default.rootData}`),e.dynamicRef&&r.var(I.default.dynamicAnchors,(0,R._)`${I.default.valCxt}.${I.default.dynamicAnchors}`)},()=>{r.var(I.default.instancePath,(0,R._)`""`),r.var(I.default.parentData,(0,R._)`undefined`),r.var(I.default.parentDataProperty,(0,R._)`undefined`),r.var(I.default.rootData,I.default.data),e.dynamicRef&&r.var(I.default.dynamicAnchors,(0,R._)`{}`)})}function K_(r){let{schema:e,opts:t,gen:n}=r;Hl(r,()=>{t.$comment&&e.$comment&&Xl(r),Y_(r),n.let(I.default.vErrors,null),n.let(I.default.errors,0),t.unevaluated&&X_(r),Kl(r),ey(r)})}function X_(r){let{gen:e,validateName:t}=r;r.evaluated=e.const("evaluated",(0,R._)`${t}.evaluated`),e.if((0,R._)`${r.evaluated}.dynamicProps`,()=>e.assign((0,R._)`${r.evaluated}.props`,(0,R._)`undefined`)),e.if((0,R._)`${r.evaluated}.dynamicItems`,()=>e.assign((0,R._)`${r.evaluated}.items`,(0,R._)`undefined`))}function xl(r,e){let t=typeof r=="object"&&r[e.schemaId];return t&&(e.code.source||e.code.process)?(0,R._)`/*# sourceURL=${t} */`:R.nil}function W_(r,e){if(Gl(r)&&(zl(r),Ul(r))){B_(r,e);return}(0,Vl.boolOrEmptySchema)(r,e)}function Ul({schema:r,self:e}){if(typeof r=="boolean")return!r;for(let t in r)if(e.RULES.all[t])return!0;return!1}function Gl(r){return typeof r.schema!="boolean"}function B_(r,e){let{schema:t,gen:n,opts:s}=r;s.$comment&&t.$comment&&Xl(r),Z_(r),Q_(r);let i=n.const("_errs",I.default.errors);Kl(r,i),n.var(e,(0,R._)`${i} === ${I.default.errors}`)}function zl(r){(0,Et.checkUnknownRules)(r),J_(r)}function Kl(r,e){if(r.opts.jtd)return Ll(r,[],!1,e);let t=(0,kl.getSchemaTypes)(r.schema),n=(0,kl.coerceAndCheckDataType)(r,t);Ll(r,t,!n,e)}function J_(r){let{schema:e,errSchemaPath:t,opts:n,self:s}=r;e.$ref&&n.ignoreKeywordsWithRef&&(0,Et.schemaHasRulesButRef)(e,s.RULES)&&s.logger.warn(`$ref: keywords ignored in schema at path "${t}"`)}function Y_(r){let{schema:e,opts:t}=r;e.default!==void 0&&t.useDefaults&&t.strictSchema&&(0,Et.checkStrictMode)(r,"default is ignored in the schema root")}function Z_(r){let e=r.schema[r.opts.schemaId];e&&(r.baseId=(0,H_.resolveUrl)(r.opts.uriResolver,r.baseId,e))}function Q_(r){if(r.schema.$async&&!r.schemaEnv.$async)throw new Error("async schema in sync schema")}function Xl({gen:r,schemaEnv:e,schema:t,errSchemaPath:n,opts:s}){let i=t.$comment;if(s.$comment===!0)r.code((0,R._)`${I.default.self}.logger.log(${i})`);else if(typeof s.$comment=="function"){let a=(0,R.str)`${n}/$comment`,c=r.scopeValue("root",{ref:e.root});r.code((0,R._)`${I.default.self}.opts.$comment(${i}, ${a}, ${c}.schema)`)}}function ey(r){let{gen:e,schemaEnv:t,validateName:n,ValidationError:s,opts:i}=r;t.$async?e.if((0,R._)`${I.default.errors} === 0`,()=>e.return(I.default.data),()=>e.throw((0,R._)`new ${s}(${I.default.vErrors})`)):(e.assign((0,R._)`${n}.errors`,I.default.vErrors),i.unevaluated&&ty(r),e.return((0,R._)`${I.default.errors} === 0`))}function ty({gen:r,evaluated:e,props:t,items:n}){t instanceof R.Name&&r.assign((0,R._)`${e}.props`,t),n instanceof R.Name&&r.assign((0,R._)`${e}.items`,n)}function Ll(r,e,t,n){let{gen:s,schema:i,data:a,allErrors:c,opts:u,self:o}=r,{RULES:l}=o;if(i.$ref&&(u.ignoreKeywordsWithRef||!(0,Et.schemaHasRulesButRef)(i,l))){s.block(()=>Wl(r,"$ref",l.all.$ref.definition));return}u.jtd||ry(r,e),s.block(()=>{for(let y of l.rules)d(y);d(l.post)});function d(y){!(0,Qi.shouldUseGroup)(i,y)||(y.type?(s.if((0,ms.checkDataType)(y.type,a,u.strictNumbers)),Ml(r,y),e.length===1&&e[0]===y.type&&t&&(s.else(),(0,ms.reportTypeError)(r)),s.endIf()):Ml(r,y),c||s.if((0,R._)`${I.default.errors} === ${n||0}`))}}function Ml(r,e){let{gen:t,schema:n,opts:{useDefaults:s}}=r;s&&(0,V_.assignDefaults)(r,e.type),t.block(()=>{for(let i of e.rules)(0,Qi.shouldUseRule)(n,i)&&Wl(r,i.keyword,i.definition,e.type)})}function ry(r,e){r.schemaEnv.meta||!r.opts.strictTypes||(ny(r,e),r.opts.allowUnionTypes||sy(r,e),iy(r,r.dataTypes))}function ny(r,e){if(!!e.length){if(!r.dataTypes.length){r.dataTypes=e;return}e.forEach(t=>{Fl(r.dataTypes,t)||ea(r,`type "${t}" not allowed by context "${r.dataTypes.join(",")}"`)}),r.dataTypes=r.dataTypes.filter(t=>Fl(e,t))}}function sy(r,e){e.length>1&&!(e.length===2&&e.includes("null"))&&ea(r,"use allowUnionTypes to allow union type keyword")}function iy(r,e){let t=r.self.RULES.all;for(let n in t){let s=t[n];if(typeof s=="object"&&(0,Qi.shouldUseRule)(r.schema,s)){let{type:i}=s.definition;i.length&&!i.some(a=>ay(e,a))&&ea(r,`missing type "${i.join(",")}" for keyword "${n}"`)}}}function ay(r,e){return r.includes(e)||e==="number"&&r.includes("integer")}function Fl(r,e){return r.includes(e)||e==="integer"&&r.includes("number")}function ea(r,e){e+=` at "${r.schemaEnv.baseId+r.errSchemaPath}" (strictTypes)`,(0,Et.checkStrictMode)(r,e,r.opts.strictTypes)}var gs=class{constructor(e,t,n){if((0,Sn.validateKeywordUsage)(e,t,n),this.gen=e.gen,this.allErrors=e.allErrors,this.keyword=n,this.data=e.data,this.schema=e.schema[n],this.$data=t.$data&&e.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,Et.schemaRefOrVal)(e,this.schema,n,this.$data),this.schemaType=t.schemaType,this.parentSchema=e.schema,this.params={},this.it=e,this.def=t,this.$data)this.schemaCode=e.gen.const("vSchema",Bl(this.$data,e));else if(this.schemaCode=this.schemaValue,!(0,Sn.validSchemaType)(this.schema,t.schemaType,t.allowUndefined))throw new Error(`${n} value must be ${JSON.stringify(t.schemaType)}`);("code"in t?t.trackErrors:t.errors!==!1)&&(this.errsCount=e.gen.const("_errs",I.default.errors))}result(e,t,n){this.failResult((0,R.not)(e),t,n)}failResult(e,t,n){this.gen.if(e),n?n():this.error(),t?(this.gen.else(),t(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(e,t){this.failResult((0,R.not)(e),void 0,t)}fail(e){if(e===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(e),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(e){if(!this.$data)return this.fail(e);let{schemaCode:t}=this;this.fail((0,R._)`${t} !== undefined && (${(0,R.or)(this.invalid$data(),e)})`)}error(e,t,n){if(t){this.setParams(t),this._error(e,n),this.setParams({});return}this._error(e,n)}_error(e,t){(e?bn.reportExtraError:bn.reportError)(this,this.def.error,t)}$dataError(){(0,bn.reportError)(this,this.def.$dataError||bn.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,bn.resetErrorsCount)(this.gen,this.errsCount)}ok(e){this.allErrors||this.gen.if(e)}setParams(e,t){t?Object.assign(this.params,e):this.params=e}block$data(e,t,n=R.nil){this.gen.block(()=>{this.check$data(e,n),t()})}check$data(e=R.nil,t=R.nil){if(!this.$data)return;let{gen:n,schemaCode:s,schemaType:i,def:a}=this;n.if((0,R.or)((0,R._)`${s} === undefined`,t)),e!==R.nil&&n.assign(e,!0),(i.length||a.validateSchema)&&(n.elseIf(this.invalid$data()),this.$dataError(),e!==R.nil&&n.assign(e,!1)),n.else()}invalid$data(){let{gen:e,schemaCode:t,schemaType:n,def:s,it:i}=this;return(0,R.or)(a(),c());function a(){if(n.length){if(!(t instanceof R.Name))throw new Error("ajv implementation error");let u=Array.isArray(n)?n:[n];return(0,R._)`${(0,ms.checkDataTypes)(u,t,i.opts.strictNumbers,ms.DataType.Wrong)}`}return R.nil}function c(){if(s.validateSchema){let u=e.scopeValue("validate$data",{ref:s.validateSchema});return(0,R._)`!${u}(${t})`}return R.nil}}subschema(e,t){let n=(0,Zi.getSubschema)(this.it,e);(0,Zi.extendSubschemaData)(n,this.it,e),(0,Zi.extendSubschemaMode)(n,e);let s={...this.it,...n,items:void 0,props:void 0};return W_(s,t),s}mergeEvaluated(e,t){let{it:n,gen:s}=this;!n.opts.unevaluated||(n.props!==!0&&e.props!==void 0&&(n.props=Et.mergeEvaluated.props(s,e.props,n.props,t)),n.items!==!0&&e.items!==void 0&&(n.items=Et.mergeEvaluated.items(s,e.items,n.items,t)))}mergeValidEvaluated(e,t){let{it:n,gen:s}=this;if(n.opts.unevaluated&&(n.props!==!0||n.items!==!0))return s.if(t,()=>this.mergeEvaluated(e,R.Name)),!0}};Tt.KeywordCxt=gs;function Wl(r,e,t,n){let s=new gs(r,t,e);"code"in t?t.code(s,n):s.$data&&t.validate?(0,Sn.funcKeywordCode)(s,t):"macro"in t?(0,Sn.macroKeywordCode)(s,t):(t.compile||t.validate)&&(0,Sn.funcKeywordCode)(s,t)}var oy=/^\/(?:[^~]|~0|~1)*$/,cy=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function Bl(r,{dataLevel:e,dataNames:t,dataPathArr:n}){let s,i;if(r==="")return I.default.rootData;if(r[0]==="/"){if(!oy.test(r))throw new Error(`Invalid JSON-pointer: ${r}`);s=r,i=I.default.rootData}else{let o=cy.exec(r);if(!o)throw new Error(`Invalid JSON-pointer: ${r}`);let l=+o[1];if(s=o[2],s==="#"){if(l>=e)throw new Error(u("property/index",l));return n[e-l]}if(l>e)throw new Error(u("data",l));if(i=t[e-l],!s)return i}let a=i,c=s.split("/");for(let o of c)o&&(i=(0,R._)`${i}${(0,R.getProperty)((0,Et.unescapeJsonPointer)(o))}`,a=(0,R._)`${a} && ${i}`);return a;function u(o,l){return`Cannot access ${o} ${l} levels up, current level is ${e}`}}Tt.getData=Bl});var na=_(ra=>{"use strict";Object.defineProperty(ra,"__esModule",{value:!0});var ta=class extends Error{constructor(e){super("validation failed"),this.errors=e,this.ajv=this.validation=!0}};ra.default=ta});var oa=_(aa=>{"use strict";Object.defineProperty(aa,"__esModule",{value:!0});var sa=wn(),ia=class extends Error{constructor(e,t,n,s){super(s||`can't resolve reference ${n} from id ${t}`),this.missingRef=(0,sa.resolveUrl)(e,t,n),this.missingSchema=(0,sa.normalizeId)((0,sa.getFullPath)(e,this.missingRef))}};aa.default=ia});var _s=_(Ke=>{"use strict";Object.defineProperty(Ke,"__esModule",{value:!0});Ke.resolveSchema=Ke.getCompilingSchema=Ke.resolveRef=Ke.compileSchema=Ke.SchemaEnv=void 0;var Ye=L(),uy=na(),Jt=$t(),Ze=wn(),Jl=G(),ly=On(),Rr=class{constructor(e){var t;this.refs={},this.dynamicAnchors={};let n;typeof e.schema=="object"&&(n=e.schema),this.schema=e.schema,this.schemaId=e.schemaId,this.root=e.root||this,this.baseId=(t=e.baseId)!==null&&t!==void 0?t:(0,Ze.normalizeId)(n==null?void 0:n[e.schemaId||"$id"]),this.schemaPath=e.schemaPath,this.localRefs=e.localRefs,this.meta=e.meta,this.$async=n==null?void 0:n.$async,this.refs={}}};Ke.SchemaEnv=Rr;function ua(r){let e=Yl.call(this,r);if(e)return e;let t=(0,Ze.getFullPath)(this.opts.uriResolver,r.root.baseId),{es5:n,lines:s}=this.opts.code,{ownProperties:i}=this.opts,a=new Ye.CodeGen(this.scope,{es5:n,lines:s,ownProperties:i}),c;r.$async&&(c=a.scopeValue("Error",{ref:uy.default,code:(0,Ye._)`require("ajv/dist/runtime/validation_error").default`}));let u=a.scopeName("validate");r.validateName=u;let o={gen:a,allErrors:this.opts.allErrors,data:Jt.default.data,parentData:Jt.default.parentData,parentDataProperty:Jt.default.parentDataProperty,dataNames:[Jt.default.data],dataPathArr:[Ye.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:a.scopeValue("schema",this.opts.code.source===!0?{ref:r.schema,code:(0,Ye.stringify)(r.schema)}:{ref:r.schema}),validateName:u,ValidationError:c,schema:r.schema,schemaEnv:r,rootId:t,baseId:r.baseId||t,schemaPath:Ye.nil,errSchemaPath:r.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,Ye._)`""`,opts:this.opts,self:this},l;try{this._compilations.add(r),(0,ly.validateFunctionCode)(o),a.optimize(this.opts.code.optimize);let d=a.toString();l=`${a.scopeRefs(Jt.default.scope)}return ${d}`,this.opts.code.process&&(l=this.opts.code.process(l,r));let m=new Function(`${Jt.default.self}`,`${Jt.default.scope}`,l)(this,this.scope.get());if(this.scope.value(u,{ref:m}),m.errors=null,m.schema=r.schema,m.schemaEnv=r,r.$async&&(m.$async=!0),this.opts.code.source===!0&&(m.source={validateName:u,validateCode:d,scopeValues:a._values}),this.opts.unevaluated){let{props:$,items:E}=o;m.evaluated={props:$ instanceof Ye.Name?void 0:$,items:E instanceof Ye.Name?void 0:E,dynamicProps:$ instanceof Ye.Name,dynamicItems:E instanceof Ye.Name},m.source&&(m.source.evaluated=(0,Ye.stringify)(m.evaluated))}return r.validate=m,r}catch(d){throw delete r.validate,delete r.validateName,l&&this.logger.error("Error compiling schema, function code:",l),d}finally{this._compilations.delete(r)}}Ke.compileSchema=ua;function fy(r,e,t){var n;t=(0,Ze.resolveUrl)(this.opts.uriResolver,e,t);let s=r.refs[t];if(s)return s;let i=py.call(this,r,t);if(i===void 0){let a=(n=r.localRefs)===null||n===void 0?void 0:n[t],{schemaId:c}=this.opts;a&&(i=new Rr({schema:a,schemaId:c,root:r,baseId:e}))}if(i!==void 0)return r.refs[t]=dy.call(this,i)}Ke.resolveRef=fy;function dy(r){return(0,Ze.inlineRef)(r.schema,this.opts.inlineRefs)?r.schema:r.validate?r:ua.call(this,r)}function Yl(r){for(let e of this._compilations)if(hy(e,r))return e}Ke.getCompilingSchema=Yl;function hy(r,e){return r.schema===e.schema&&r.root===e.root&&r.baseId===e.baseId}function py(r,e){let t;for(;typeof(t=this.refs[e])=="string";)e=t;return t||this.schemas[e]||vs.call(this,r,e)}function vs(r,e){let t=this.opts.uriResolver.parse(e),n=(0,Ze._getFullPath)(this.opts.uriResolver,t),s=(0,Ze.getFullPath)(this.opts.uriResolver,r.baseId,void 0);if(Object.keys(r.schema).length>0&&n===s)return ca.call(this,t,r);let i=(0,Ze.normalizeId)(n),a=this.refs[i]||this.schemas[i];if(typeof a=="string"){let c=vs.call(this,r,a);return typeof(c==null?void 0:c.schema)!="object"?void 0:ca.call(this,t,c)}if(typeof(a==null?void 0:a.schema)=="object"){if(a.validate||ua.call(this,a),i===(0,Ze.normalizeId)(e)){let{schema:c}=a,{schemaId:u}=this.opts,o=c[u];return o&&(s=(0,Ze.resolveUrl)(this.opts.uriResolver,s,o)),new Rr({schema:c,schemaId:u,root:r,baseId:s})}return ca.call(this,t,a)}}Ke.resolveSchema=vs;var my=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function ca(r,{baseId:e,schema:t,root:n}){var s;if(((s=r.fragment)===null||s===void 0?void 0:s[0])!=="/")return;for(let c of r.fragment.slice(1).split("/")){if(typeof t=="boolean")return;let u=t[(0,Jl.unescapeFragment)(c)];if(u===void 0)return;t=u;let o=typeof t=="object"&&t[this.opts.schemaId];!my.has(c)&&o&&(e=(0,Ze.resolveUrl)(this.opts.uriResolver,e,o))}let i;if(typeof t!="boolean"&&t.$ref&&!(0,Jl.schemaHasRulesButRef)(t,this.RULES)){let c=(0,Ze.resolveUrl)(this.opts.uriResolver,e,t.$ref);i=vs.call(this,n,c)}let{schemaId:a}=this.opts;if(i=i||new Rr({schema:t,schemaId:a,root:n,baseId:e}),i.schema!==i.root.schema)return i}});var Zl=_((xb,gy)=>{gy.exports={$id:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",description:"Meta-schema for $data reference (JSON AnySchema extension proposal)",type:"object",required:["$data"],properties:{$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},additionalProperties:!1}});var ef=_((ys,Ql)=>{(function(r,e){typeof ys=="object"&&typeof Ql<"u"?e(ys):typeof define=="function"&&define.amd?define(["exports"],e):e(r.URI=r.URI||{})})(ys,function(r){"use strict";function e(){for(var h=arguments.length,f=Array(h),p=0;p<h;p++)f[p]=arguments[p];if(f.length>1){f[0]=f[0].slice(0,-1);for(var g=f.length-1,v=1;v<g;++v)f[v]=f[v].slice(1,-1);return f[g]=f[g].slice(1),f.join("")}else return f[0]}function t(h){return"(?:"+h+")"}function n(h){return h===void 0?"undefined":h===null?"null":Object.prototype.toString.call(h).split(" ").pop().split("]").shift().toLowerCase()}function s(h){return h.toUpperCase()}function i(h){return h!=null?h instanceof Array?h:typeof h.length!="number"||h.split||h.setInterval||h.call?[h]:Array.prototype.slice.call(h):[]}function a(h,f){var p=h;if(f)for(var g in f)p[g]=f[g];return p}function c(h){var f="[A-Za-z]",p="[\\x0D]",g="[0-9]",v="[\\x22]",S=e(g,"[A-Fa-f]"),A="[\\x0A]",H="[\\x20]",W=t(t("%[EFef]"+S+"%"+S+S+"%"+S+S)+"|"+t("%[89A-Fa-f]"+S+"%"+S+S)+"|"+t("%"+S+S)),ce="[\\:\\/\\?\\#\\[\\]\\@]",F="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",se=e(ce,F),ue=h?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]",ne=h?"[\\uE000-\\uF8FF]":"[]",K=e(f,g,"[\\-\\.\\_\\~]",ue),ie=t(f+e(f,g,"[\\+\\-\\.]")+"*"),B=t(t(W+"|"+e(K,F,"[\\:]"))+"*"),Dt=t(t("25[0-5]")+"|"+t("2[0-4]"+g)+"|"+t("1"+g+g)+"|"+t("[1-9]"+g)+"|"+g),Ae=t(t("25[0-5]")+"|"+t("2[0-4]"+g)+"|"+t("1"+g+g)+"|"+t("0?[1-9]"+g)+"|0?0?"+g),Fe=t(Ae+"\\."+Ae+"\\."+Ae+"\\."+Ae),Y=t(S+"{1,4}"),qe=t(t(Y+"\\:"+Y)+"|"+Fe),Ve=t(t(Y+"\\:")+"{6}"+qe),st=t("\\:\\:"+t(Y+"\\:")+"{5}"+qe),jt=t(t(Y)+"?\\:\\:"+t(Y+"\\:")+"{4}"+qe),dt=t(t(t(Y+"\\:")+"{0,1}"+Y)+"?\\:\\:"+t(Y+"\\:")+"{3}"+qe),Gr=t(t(t(Y+"\\:")+"{0,2}"+Y)+"?\\:\\:"+t(Y+"\\:")+"{2}"+qe),Hn=t(t(t(Y+"\\:")+"{0,3}"+Y)+"?\\:\\:"+Y+"\\:"+qe),Un=t(t(t(Y+"\\:")+"{0,4}"+Y)+"?\\:\\:"+qe),ir=t(t(t(Y+"\\:")+"{0,5}"+Y)+"?\\:\\:"+Y),ar=t(t(t(Y+"\\:")+"{0,6}"+Y)+"?\\:\\:"),ht=t([Ve,st,jt,dt,Gr,Hn,Un,ir,ar].join("|")),or=t(t(K+"|"+W)+"+"),Hs=t(ht+"\\%25"+or),kt=t(ht+t("\\%25|\\%(?!"+S+"{2})")+or),oh=t("[vV]"+S+"+\\."+e(K,F,"[\\:]")+"+"),ch=t("\\["+t(kt+"|"+ht+"|"+oh)+"\\]"),Oo=t(t(W+"|"+e(K,F))+"*"),zr=t(ch+"|"+Fe+"(?!"+Oo+")|"+Oo),Kr=t(g+"*"),Po=t(t(B+"@")+"?"+zr+t("\\:"+Kr)+"?"),Xr=t(W+"|"+e(K,F,"[\\:\\@]")),uh=t(Xr+"*"),Ro=t(Xr+"+"),lh=t(t(W+"|"+e(K,F,"[\\@]"))+"+"),pt=t(t("\\/"+uh)+"*"),cr=t("\\/"+t(Ro+pt)+"?"),Us=t(lh+pt),Gn=t(Ro+pt),ur="(?!"+Xr+")",aw=t(pt+"|"+cr+"|"+Us+"|"+Gn+"|"+ur),lr=t(t(Xr+"|"+e("[\\/\\?]",ne))+"*"),Wr=t(t(Xr+"|[\\/\\?]")+"*"),Co=t(t("\\/\\/"+Po+pt)+"|"+cr+"|"+Gn+"|"+ur),fh=t(ie+"\\:"+Co+t("\\?"+lr)+"?"+t("\\#"+Wr)+"?"),dh=t(t("\\/\\/"+Po+pt)+"|"+cr+"|"+Us+"|"+ur),hh=t(dh+t("\\?"+lr)+"?"+t("\\#"+Wr)+"?"),ow=t(fh+"|"+hh),cw=t(ie+"\\:"+Co+t("\\?"+lr)+"?"),uw="^("+ie+")\\:"+t(t("\\/\\/("+t("("+B+")@")+"?("+zr+")"+t("\\:("+Kr+")")+"?)")+"?("+pt+"|"+cr+"|"+Gn+"|"+ur+")")+t("\\?("+lr+")")+"?"+t("\\#("+Wr+")")+"?$",lw="^(){0}"+t(t("\\/\\/("+t("("+B+")@")+"?("+zr+")"+t("\\:("+Kr+")")+"?)")+"?("+pt+"|"+cr+"|"+Us+"|"+ur+")")+t("\\?("+lr+")")+"?"+t("\\#("+Wr+")")+"?$",fw="^("+ie+")\\:"+t(t("\\/\\/("+t("("+B+")@")+"?("+zr+")"+t("\\:("+Kr+")")+"?)")+"?("+pt+"|"+cr+"|"+Gn+"|"+ur+")")+t("\\?("+lr+")")+"?$",dw="^"+t("\\#("+Wr+")")+"?$",hw="^"+t("("+B+")@")+"?("+zr+")"+t("\\:("+Kr+")")+"?$";return{NOT_SCHEME:new RegExp(e("[^]",f,g,"[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(e("[^\\%\\:]",K,F),"g"),NOT_HOST:new RegExp(e("[^\\%\\[\\]\\:]",K,F),"g"),NOT_PATH:new RegExp(e("[^\\%\\/\\:\\@]",K,F),"g"),NOT_PATH_NOSCHEME:new RegExp(e("[^\\%\\/\\@]",K,F),"g"),NOT_QUERY:new RegExp(e("[^\\%]",K,F,"[\\:\\@\\/\\?]",ne),"g"),NOT_FRAGMENT:new RegExp(e("[^\\%]",K,F,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(e("[^]",K,F),"g"),UNRESERVED:new RegExp(K,"g"),OTHER_CHARS:new RegExp(e("[^\\%]",K,se),"g"),PCT_ENCODED:new RegExp(W,"g"),IPV4ADDRESS:new RegExp("^("+Fe+")$"),IPV6ADDRESS:new RegExp("^\\[?("+ht+")"+t(t("\\%25|\\%(?!"+S+"{2})")+"("+or+")")+"?\\]?$")}}var u=c(!1),o=c(!0),l=function(){function h(f,p){var g=[],v=!0,S=!1,A=void 0;try{for(var H=f[Symbol.iterator](),W;!(v=(W=H.next()).done)&&(g.push(W.value),!(p&&g.length===p));v=!0);}catch(ce){S=!0,A=ce}finally{try{!v&&H.return&&H.return()}finally{if(S)throw A}}return g}return function(f,p){if(Array.isArray(f))return f;if(Symbol.iterator in Object(f))return h(f,p);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),d=function(h){if(Array.isArray(h)){for(var f=0,p=Array(h.length);f<h.length;f++)p[f]=h[f];return p}else return Array.from(h)},y=2147483647,m=36,$=1,E=26,w=38,b=700,D=72,T=128,z="-",C=/^xn--/,me=/[^\0-\x7E]/,ke=/[\x2E\u3002\uFF0E\uFF61]/g,bt={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},xe=m-$,re=Math.floor,Le=String.fromCharCode;function et(h){throw new RangeError(bt[h])}function Fn(h,f){for(var p=[],g=h.length;g--;)p[g]=f(h[g]);return p}function Vn(h,f){var p=h.split("@"),g="";p.length>1&&(g=p[0]+"@",h=p[1]),h=h.replace(ke,".");var v=h.split("."),S=Fn(v,f).join(".");return g+S}function ao(h){for(var f=[],p=0,g=h.length;p<g;){var v=h.charCodeAt(p++);if(v>=55296&&v<=56319&&p<g){var S=h.charCodeAt(p++);(S&64512)==56320?f.push(((v&1023)<<10)+(S&1023)+65536):(f.push(v),p--)}else f.push(v)}return f}var xd=function(f){return String.fromCodePoint.apply(String,d(f))},Ld=function(f){return f-48<10?f-22:f-65<26?f-65:f-97<26?f-97:m},oo=function(f,p){return f+22+75*(f<26)-((p!=0)<<5)},co=function(f,p,g){var v=0;for(f=g?re(f/b):f>>1,f+=re(f/p);f>xe*E>>1;v+=m)f=re(f/xe);return re(v+(xe+1)*f/(f+w))},uo=function(f){var p=[],g=f.length,v=0,S=T,A=D,H=f.lastIndexOf(z);H<0&&(H=0);for(var W=0;W<H;++W)f.charCodeAt(W)>=128&&et("not-basic"),p.push(f.charCodeAt(W));for(var ce=H>0?H+1:0;ce<g;){for(var F=v,se=1,ue=m;;ue+=m){ce>=g&&et("invalid-input");var ne=Ld(f.charCodeAt(ce++));(ne>=m||ne>re((y-v)/se))&&et("overflow"),v+=ne*se;var K=ue<=A?$:ue>=A+E?E:ue-A;if(ne<K)break;var ie=m-K;se>re(y/ie)&&et("overflow"),se*=ie}var B=p.length+1;A=co(v-F,B,F==0),re(v/B)>y-S&&et("overflow"),S+=re(v/B),v%=B,p.splice(v++,0,S)}return String.fromCodePoint.apply(String,p)},lo=function(f){var p=[];f=ao(f);var g=f.length,v=T,S=0,A=D,H=!0,W=!1,ce=void 0;try{for(var F=f[Symbol.iterator](),se;!(H=(se=F.next()).done);H=!0){var ue=se.value;ue<128&&p.push(Le(ue))}}catch(kt){W=!0,ce=kt}finally{try{!H&&F.return&&F.return()}finally{if(W)throw ce}}var ne=p.length,K=ne;for(ne&&p.push(z);K<g;){var ie=y,B=!0,Dt=!1,Ae=void 0;try{for(var Fe=f[Symbol.iterator](),Y;!(B=(Y=Fe.next()).done);B=!0){var qe=Y.value;qe>=v&&qe<ie&&(ie=qe)}}catch(kt){Dt=!0,Ae=kt}finally{try{!B&&Fe.return&&Fe.return()}finally{if(Dt)throw Ae}}var Ve=K+1;ie-v>re((y-S)/Ve)&&et("overflow"),S+=(ie-v)*Ve,v=ie;var st=!0,jt=!1,dt=void 0;try{for(var Gr=f[Symbol.iterator](),Hn;!(st=(Hn=Gr.next()).done);st=!0){var Un=Hn.value;if(Un<v&&++S>y&&et("overflow"),Un==v){for(var ir=S,ar=m;;ar+=m){var ht=ar<=A?$:ar>=A+E?E:ar-A;if(ir<ht)break;var or=ir-ht,Hs=m-ht;p.push(Le(oo(ht+or%Hs,0))),ir=re(or/Hs)}p.push(Le(oo(ir,0))),A=co(S,Ve,K==ne),S=0,++K}}}catch(kt){jt=!0,dt=kt}finally{try{!st&&Gr.return&&Gr.return()}finally{if(jt)throw dt}}++S,++v}return p.join("")},Md=function(f){return Vn(f,function(p){return C.test(p)?uo(p.slice(4).toLowerCase()):p})},Fd=function(f){return Vn(f,function(p){return me.test(p)?"xn--"+lo(p):p})},tr={version:"2.1.0",ucs2:{decode:ao,encode:xd},decode:uo,encode:lo,toASCII:Fd,toUnicode:Md},Me={};function tt(h){var f=h.charCodeAt(0),p=void 0;return f<16?p="%0"+f.toString(16).toUpperCase():f<128?p="%"+f.toString(16).toUpperCase():f<2048?p="%"+(f>>6|192).toString(16).toUpperCase()+"%"+(f&63|128).toString(16).toUpperCase():p="%"+(f>>12|224).toString(16).toUpperCase()+"%"+(f>>6&63|128).toString(16).toUpperCase()+"%"+(f&63|128).toString(16).toUpperCase(),p}function rr(h){for(var f="",p=0,g=h.length;p<g;){var v=parseInt(h.substr(p+1,2),16);if(v<128)f+=String.fromCharCode(v),p+=3;else if(v>=194&&v<224){if(g-p>=6){var S=parseInt(h.substr(p+4,2),16);f+=String.fromCharCode((v&31)<<6|S&63)}else f+=h.substr(p,6);p+=6}else if(v>=224){if(g-p>=9){var A=parseInt(h.substr(p+4,2),16),H=parseInt(h.substr(p+7,2),16);f+=String.fromCharCode((v&15)<<12|(A&63)<<6|H&63)}else f+=h.substr(p,9);p+=9}else f+=h.substr(p,3),p+=3}return f}function Ls(h,f){function p(g){var v=rr(g);return v.match(f.UNRESERVED)?v:g}return h.scheme&&(h.scheme=String(h.scheme).replace(f.PCT_ENCODED,p).toLowerCase().replace(f.NOT_SCHEME,"")),h.userinfo!==void 0&&(h.userinfo=String(h.userinfo).replace(f.PCT_ENCODED,p).replace(f.NOT_USERINFO,tt).replace(f.PCT_ENCODED,s)),h.host!==void 0&&(h.host=String(h.host).replace(f.PCT_ENCODED,p).toLowerCase().replace(f.NOT_HOST,tt).replace(f.PCT_ENCODED,s)),h.path!==void 0&&(h.path=String(h.path).replace(f.PCT_ENCODED,p).replace(h.scheme?f.NOT_PATH:f.NOT_PATH_NOSCHEME,tt).replace(f.PCT_ENCODED,s)),h.query!==void 0&&(h.query=String(h.query).replace(f.PCT_ENCODED,p).replace(f.NOT_QUERY,tt).replace(f.PCT_ENCODED,s)),h.fragment!==void 0&&(h.fragment=String(h.fragment).replace(f.PCT_ENCODED,p).replace(f.NOT_FRAGMENT,tt).replace(f.PCT_ENCODED,s)),h}function Ms(h){return h.replace(/^0*(.*)/,"$1")||"0"}function Fs(h,f){var p=h.match(f.IPV4ADDRESS)||[],g=l(p,2),v=g[1];return v?v.split(".").map(Ms).join("."):h}function fo(h,f){var p=h.match(f.IPV6ADDRESS)||[],g=l(p,3),v=g[1],S=g[2];if(v){for(var A=v.toLowerCase().split("::").reverse(),H=l(A,2),W=H[0],ce=H[1],F=ce?ce.split(":").map(Ms):[],se=W.split(":").map(Ms),ue=f.IPV4ADDRESS.test(se[se.length-1]),ne=ue?7:8,K=se.length-ne,ie=Array(ne),B=0;B<ne;++B)ie[B]=F[B]||se[K+B]||"";ue&&(ie[ne-1]=Fs(ie[ne-1],f));var Dt=ie.reduce(function(Ve,st,jt){if(!st||st==="0"){var dt=Ve[Ve.length-1];dt&&dt.index+dt.length===jt?dt.length++:Ve.push({index:jt,length:1})}return Ve},[]),Ae=Dt.sort(function(Ve,st){return st.length-Ve.length})[0],Fe=void 0;if(Ae&&Ae.length>1){var Y=ie.slice(0,Ae.index),qe=ie.slice(Ae.index+Ae.length);Fe=Y.join(":")+"::"+qe.join(":")}else Fe=ie.join(":");return S&&(Fe+="%"+S),Fe}else return h}var Vd=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?(\[[^\/?#\]]+\]|[^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n|\r)*))?/i,Hd="".match(/(){0}/)[1]===void 0;function lt(h){var f=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},p={},g=f.iri!==!1?o:u;f.reference==="suffix"&&(h=(f.scheme?f.scheme+":":"")+"//"+h);var v=h.match(Vd);if(v){Hd?(p.scheme=v[1],p.userinfo=v[3],p.host=v[4],p.port=parseInt(v[5],10),p.path=v[6]||"",p.query=v[7],p.fragment=v[8],isNaN(p.port)&&(p.port=v[5])):(p.scheme=v[1]||void 0,p.userinfo=h.indexOf("@")!==-1?v[3]:void 0,p.host=h.indexOf("//")!==-1?v[4]:void 0,p.port=parseInt(v[5],10),p.path=v[6]||"",p.query=h.indexOf("?")!==-1?v[7]:void 0,p.fragment=h.indexOf("#")!==-1?v[8]:void 0,isNaN(p.port)&&(p.port=h.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?v[4]:void 0)),p.host&&(p.host=fo(Fs(p.host,g),g)),p.scheme===void 0&&p.userinfo===void 0&&p.host===void 0&&p.port===void 0&&!p.path&&p.query===void 0?p.reference="same-document":p.scheme===void 0?p.reference="relative":p.fragment===void 0?p.reference="absolute":p.reference="uri",f.reference&&f.reference!=="suffix"&&f.reference!==p.reference&&(p.error=p.error||"URI is not a "+f.reference+" reference.");var S=Me[(f.scheme||p.scheme||"").toLowerCase()];if(!f.unicodeSupport&&(!S||!S.unicodeSupport)){if(p.host&&(f.domainHost||S&&S.domainHost))try{p.host=tr.toASCII(p.host.replace(g.PCT_ENCODED,rr).toLowerCase())}catch(A){p.error=p.error||"Host's domain name can not be converted to ASCII via punycode: "+A}Ls(p,u)}else Ls(p,g);S&&S.parse&&S.parse(p,f)}else p.error=p.error||"URI can not be parsed.";return p}function Ud(h,f){var p=f.iri!==!1?o:u,g=[];return h.userinfo!==void 0&&(g.push(h.userinfo),g.push("@")),h.host!==void 0&&g.push(fo(Fs(String(h.host),p),p).replace(p.IPV6ADDRESS,function(v,S,A){return"["+S+(A?"%25"+A:"")+"]"})),(typeof h.port=="number"||typeof h.port=="string")&&(g.push(":"),g.push(String(h.port))),g.length?g.join(""):void 0}var ho=/^\.\.?\//,po=/^\/\.(\/|$)/,mo=/^\/\.\.(\/|$)/,Gd=/^\/?(?:.|\n)*?(?=\/|$)/;function nr(h){for(var f=[];h.length;)if(h.match(ho))h=h.replace(ho,"");else if(h.match(po))h=h.replace(po,"/");else if(h.match(mo))h=h.replace(mo,"/"),f.pop();else if(h==="."||h==="..")h="";else{var p=h.match(Gd);if(p){var g=p[0];h=h.slice(g.length),f.push(g)}else throw new Error("Unexpected dot segment condition")}return f.join("")}function rt(h){var f=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},p=f.iri?o:u,g=[],v=Me[(f.scheme||h.scheme||"").toLowerCase()];if(v&&v.serialize&&v.serialize(h,f),h.host&&!p.IPV6ADDRESS.test(h.host)){if(f.domainHost||v&&v.domainHost)try{h.host=f.iri?tr.toUnicode(h.host):tr.toASCII(h.host.replace(p.PCT_ENCODED,rr).toLowerCase())}catch(H){h.error=h.error||"Host's domain name can not be converted to "+(f.iri?"Unicode":"ASCII")+" via punycode: "+H}}Ls(h,p),f.reference!=="suffix"&&h.scheme&&(g.push(h.scheme),g.push(":"));var S=Ud(h,f);if(S!==void 0&&(f.reference!=="suffix"&&g.push("//"),g.push(S),h.path&&h.path.charAt(0)!=="/"&&g.push("/")),h.path!==void 0){var A=h.path;!f.absolutePath&&(!v||!v.absolutePath)&&(A=nr(A)),S===void 0&&(A=A.replace(/^\/\//,"/%2F")),g.push(A)}return h.query!==void 0&&(g.push("?"),g.push(h.query)),h.fragment!==void 0&&(g.push("#"),g.push(h.fragment)),g.join("")}function go(h,f){var p=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},g=arguments[3],v={};return g||(h=lt(rt(h,p),p),f=lt(rt(f,p),p)),p=p||{},!p.tolerant&&f.scheme?(v.scheme=f.scheme,v.userinfo=f.userinfo,v.host=f.host,v.port=f.port,v.path=nr(f.path||""),v.query=f.query):(f.userinfo!==void 0||f.host!==void 0||f.port!==void 0?(v.userinfo=f.userinfo,v.host=f.host,v.port=f.port,v.path=nr(f.path||""),v.query=f.query):(f.path?(f.path.charAt(0)==="/"?v.path=nr(f.path):((h.userinfo!==void 0||h.host!==void 0||h.port!==void 0)&&!h.path?v.path="/"+f.path:h.path?v.path=h.path.slice(0,h.path.lastIndexOf("/")+1)+f.path:v.path=f.path,v.path=nr(v.path)),v.query=f.query):(v.path=h.path,f.query!==void 0?v.query=f.query:v.query=h.query),v.userinfo=h.userinfo,v.host=h.host,v.port=h.port),v.scheme=h.scheme),v.fragment=f.fragment,v}function zd(h,f,p){var g=a({scheme:"null"},p);return rt(go(lt(h,g),lt(f,g),g,!0),g)}function Kd(h,f){return typeof h=="string"?h=rt(lt(h,f),f):n(h)==="object"&&(h=lt(rt(h,f),f)),h}function Xd(h,f,p){return typeof h=="string"?h=rt(lt(h,p),p):n(h)==="object"&&(h=rt(h,p)),typeof f=="string"?f=rt(lt(f,p),p):n(f)==="object"&&(f=rt(f,p)),h===f}function Wd(h,f){return h&&h.toString().replace(!f||!f.iri?u.ESCAPE:o.ESCAPE,tt)}function ft(h,f){return h&&h.toString().replace(!f||!f.iri?u.PCT_ENCODED:o.PCT_ENCODED,rr)}var Hr={scheme:"http",domainHost:!0,parse:function(f,p){return f.host||(f.error=f.error||"HTTP URIs must have a host."),f},serialize:function(f,p){var g=String(f.scheme).toLowerCase()==="https";return(f.port===(g?443:80)||f.port==="")&&(f.port=void 0),f.path||(f.path="/"),f}},vo={scheme:"https",domainHost:Hr.domainHost,parse:Hr.parse,serialize:Hr.serialize};function _o(h){return typeof h.secure=="boolean"?h.secure:String(h.scheme).toLowerCase()==="wss"}var Ur={scheme:"ws",domainHost:!0,parse:function(f,p){var g=f;return g.secure=_o(g),g.resourceName=(g.path||"/")+(g.query?"?"+g.query:""),g.path=void 0,g.query=void 0,g},serialize:function(f,p){if((f.port===(_o(f)?443:80)||f.port==="")&&(f.port=void 0),typeof f.secure=="boolean"&&(f.scheme=f.secure?"wss":"ws",f.secure=void 0),f.resourceName){var g=f.resourceName.split("?"),v=l(g,2),S=v[0],A=v[1];f.path=S&&S!=="/"?S:void 0,f.query=A,f.resourceName=void 0}return f.fragment=void 0,f}},yo={scheme:"wss",domainHost:Ur.domainHost,parse:Ur.parse,serialize:Ur.serialize},Bd={},Jd=!0,$o="[A-Za-z0-9\\-\\.\\_\\~"+(Jd?"\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF":"")+"]",nt="[0-9A-Fa-f]",Yd=t(t("%[EFef]"+nt+"%"+nt+nt+"%"+nt+nt)+"|"+t("%[89A-Fa-f]"+nt+"%"+nt+nt)+"|"+t("%"+nt+nt)),Zd="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",Qd="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",eh=e(Qd,'[\\"\\\\]'),th="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",rh=new RegExp($o,"g"),sr=new RegExp(Yd,"g"),nh=new RegExp(e("[^]",Zd,"[\\.]",'[\\"]',eh),"g"),Eo=new RegExp(e("[^]",$o,th),"g"),sh=Eo;function Vs(h){var f=rr(h);return f.match(rh)?f:h}var wo={scheme:"mailto",parse:function(f,p){var g=f,v=g.to=g.path?g.path.split(","):[];if(g.path=void 0,g.query){for(var S=!1,A={},H=g.query.split("&"),W=0,ce=H.length;W<ce;++W){var F=H[W].split("=");switch(F[0]){case"to":for(var se=F[1].split(","),ue=0,ne=se.length;ue<ne;++ue)v.push(se[ue]);break;case"subject":g.subject=ft(F[1],p);break;case"body":g.body=ft(F[1],p);break;default:S=!0,A[ft(F[0],p)]=ft(F[1],p);break}}S&&(g.headers=A)}g.query=void 0;for(var K=0,ie=v.length;K<ie;++K){var B=v[K].split("@");if(B[0]=ft(B[0]),p.unicodeSupport)B[1]=ft(B[1],p).toLowerCase();else try{B[1]=tr.toASCII(ft(B[1],p).toLowerCase())}catch(Dt){g.error=g.error||"Email address's domain name can not be converted to ASCII via punycode: "+Dt}v[K]=B.join("@")}return g},serialize:function(f,p){var g=f,v=i(f.to);if(v){for(var S=0,A=v.length;S<A;++S){var H=String(v[S]),W=H.lastIndexOf("@"),ce=H.slice(0,W).replace(sr,Vs).replace(sr,s).replace(nh,tt),F=H.slice(W+1);try{F=p.iri?tr.toUnicode(F):tr.toASCII(ft(F,p).toLowerCase())}catch(K){g.error=g.error||"Email address's domain name can not be converted to "+(p.iri?"Unicode":"ASCII")+" via punycode: "+K}v[S]=ce+"@"+F}g.path=v.join(",")}var se=f.headers=f.headers||{};f.subject&&(se.subject=f.subject),f.body&&(se.body=f.body);var ue=[];for(var ne in se)se[ne]!==Bd[ne]&&ue.push(ne.replace(sr,Vs).replace(sr,s).replace(Eo,tt)+"="+se[ne].replace(sr,Vs).replace(sr,s).replace(sh,tt));return ue.length&&(g.query=ue.join("&")),g}},ih=/^([^\:]+)\:(.*)/,bo={scheme:"urn",parse:function(f,p){var g=f.path&&f.path.match(ih),v=f;if(g){var S=p.scheme||v.scheme||"urn",A=g[1].toLowerCase(),H=g[2],W=S+":"+(p.nid||A),ce=Me[W];v.nid=A,v.nss=H,v.path=void 0,ce&&(v=ce.parse(v,p))}else v.error=v.error||"URN can not be parsed.";return v},serialize:function(f,p){var g=p.scheme||f.scheme||"urn",v=f.nid,S=g+":"+(p.nid||v),A=Me[S];A&&(f=A.serialize(f,p));var H=f,W=f.nss;return H.path=(v||p.nid)+":"+W,H}},ah=/^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/,So={scheme:"urn:uuid",parse:function(f,p){var g=f;return g.uuid=g.nss,g.nss=void 0,!p.tolerant&&(!g.uuid||!g.uuid.match(ah))&&(g.error=g.error||"UUID is not valid."),g},serialize:function(f,p){var g=f;return g.nss=(f.uuid||"").toLowerCase(),g}};Me[Hr.scheme]=Hr,Me[vo.scheme]=vo,Me[Ur.scheme]=Ur,Me[yo.scheme]=yo,Me[wo.scheme]=wo,Me[bo.scheme]=bo,Me[So.scheme]=So,r.SCHEMES=Me,r.pctEncChar=tt,r.pctDecChars=rr,r.parse=lt,r.removeDotSegments=nr,r.serialize=rt,r.resolveComponents=go,r.resolve=zd,r.normalize=Kd,r.equal=Xd,r.escapeComponent=Wd,r.unescapeComponent=ft,Object.defineProperty(r,"__esModule",{value:!0})})});var rf=_(la=>{"use strict";Object.defineProperty(la,"__esModule",{value:!0});var tf=ef();tf.code='require("ajv/dist/runtime/uri").default';la.default=tf});var ff=_(he=>{"use strict";Object.defineProperty(he,"__esModule",{value:!0});he.CodeGen=he.Name=he.nil=he.stringify=he.str=he._=he.KeywordCxt=void 0;var vy=On();Object.defineProperty(he,"KeywordCxt",{enumerable:!0,get:function(){return vy.KeywordCxt}});var Cr=L();Object.defineProperty(he,"_",{enumerable:!0,get:function(){return Cr._}});Object.defineProperty(he,"str",{enumerable:!0,get:function(){return Cr.str}});Object.defineProperty(he,"stringify",{enumerable:!0,get:function(){return Cr.stringify}});Object.defineProperty(he,"nil",{enumerable:!0,get:function(){return Cr.nil}});Object.defineProperty(he,"Name",{enumerable:!0,get:function(){return Cr.Name}});Object.defineProperty(he,"CodeGen",{enumerable:!0,get:function(){return Cr.CodeGen}});var _y=na(),cf=oa(),yy=Hi(),Pn=_s(),$y=L(),Rn=wn(),$s=En(),da=G(),nf=Zl(),Ey=rf(),uf=(r,e)=>new RegExp(r,e);uf.code="new RegExp";var wy=["removeAdditional","useDefaults","coerceTypes"],by=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),Sy={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},Oy={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},sf=200;function Py(r){var e,t,n,s,i,a,c,u,o,l,d,y,m,$,E,w,b,D,T,z,C,me,ke,bt,xe;let re=r.strict,Le=(e=r.code)===null||e===void 0?void 0:e.optimize,et=Le===!0||Le===void 0?1:Le||0,Fn=(n=(t=r.code)===null||t===void 0?void 0:t.regExp)!==null&&n!==void 0?n:uf,Vn=(s=r.uriResolver)!==null&&s!==void 0?s:Ey.default;return{strictSchema:(a=(i=r.strictSchema)!==null&&i!==void 0?i:re)!==null&&a!==void 0?a:!0,strictNumbers:(u=(c=r.strictNumbers)!==null&&c!==void 0?c:re)!==null&&u!==void 0?u:!0,strictTypes:(l=(o=r.strictTypes)!==null&&o!==void 0?o:re)!==null&&l!==void 0?l:"log",strictTuples:(y=(d=r.strictTuples)!==null&&d!==void 0?d:re)!==null&&y!==void 0?y:"log",strictRequired:($=(m=r.strictRequired)!==null&&m!==void 0?m:re)!==null&&$!==void 0?$:!1,code:r.code?{...r.code,optimize:et,regExp:Fn}:{optimize:et,regExp:Fn},loopRequired:(E=r.loopRequired)!==null&&E!==void 0?E:sf,loopEnum:(w=r.loopEnum)!==null&&w!==void 0?w:sf,meta:(b=r.meta)!==null&&b!==void 0?b:!0,messages:(D=r.messages)!==null&&D!==void 0?D:!0,inlineRefs:(T=r.inlineRefs)!==null&&T!==void 0?T:!0,schemaId:(z=r.schemaId)!==null&&z!==void 0?z:"$id",addUsedSchema:(C=r.addUsedSchema)!==null&&C!==void 0?C:!0,validateSchema:(me=r.validateSchema)!==null&&me!==void 0?me:!0,validateFormats:(ke=r.validateFormats)!==null&&ke!==void 0?ke:!0,unicodeRegExp:(bt=r.unicodeRegExp)!==null&&bt!==void 0?bt:!0,int32range:(xe=r.int32range)!==null&&xe!==void 0?xe:!0,uriResolver:Vn}}var Cn=class{constructor(e={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,e=this.opts={...e,...Py(e)};let{es5:t,lines:n}=this.opts.code;this.scope=new $y.ValueScope({scope:{},prefixes:by,es5:t,lines:n}),this.logger=Ay(e.logger);let s=e.validateFormats;e.validateFormats=!1,this.RULES=(0,yy.getRules)(),af.call(this,Sy,e,"NOT SUPPORTED"),af.call(this,Oy,e,"DEPRECATED","warn"),this._metaOpts=Iy.call(this),e.formats&&Cy.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),e.keywords&&Ny.call(this,e.keywords),typeof e.meta=="object"&&this.addMetaSchema(e.meta),Ry.call(this),e.validateFormats=s}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){let{$data:e,meta:t,schemaId:n}=this.opts,s=nf;n==="id"&&(s={...nf},s.id=s.$id,delete s.$id),t&&e&&this.addMetaSchema(s,s[n],!1)}defaultMeta(){let{meta:e,schemaId:t}=this.opts;return this.opts.defaultMeta=typeof e=="object"?e[t]||e:void 0}validate(e,t){let n;if(typeof e=="string"){if(n=this.getSchema(e),!n)throw new Error(`no schema with key or ref "${e}"`)}else n=this.compile(e);let s=n(t);return"$async"in n||(this.errors=n.errors),s}compile(e,t){let n=this._addSchema(e,t);return n.validate||this._compileSchemaEnv(n)}compileAsync(e,t){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");let{loadSchema:n}=this.opts;return s.call(this,e,t);async function s(l,d){await i.call(this,l.$schema);let y=this._addSchema(l,d);return y.validate||a.call(this,y)}async function i(l){l&&!this.getSchema(l)&&await s.call(this,{$ref:l},!0)}async function a(l){try{return this._compileSchemaEnv(l)}catch(d){if(!(d instanceof cf.default))throw d;return c.call(this,d),await u.call(this,d.missingSchema),a.call(this,l)}}function c({missingSchema:l,missingRef:d}){if(this.refs[l])throw new Error(`AnySchema ${l} is loaded but ${d} cannot be resolved`)}async function u(l){let d=await o.call(this,l);this.refs[l]||await i.call(this,d.$schema),this.refs[l]||this.addSchema(d,l,t)}async function o(l){let d=this._loading[l];if(d)return d;try{return await(this._loading[l]=n(l))}finally{delete this._loading[l]}}}addSchema(e,t,n,s=this.opts.validateSchema){if(Array.isArray(e)){for(let a of e)this.addSchema(a,void 0,n,s);return this}let i;if(typeof e=="object"){let{schemaId:a}=this.opts;if(i=e[a],i!==void 0&&typeof i!="string")throw new Error(`schema ${a} must be string`)}return t=(0,Rn.normalizeId)(t||i),this._checkUnique(t),this.schemas[t]=this._addSchema(e,n,t,s,!0),this}addMetaSchema(e,t,n=this.opts.validateSchema){return this.addSchema(e,t,!0,n),this}validateSchema(e,t){if(typeof e=="boolean")return!0;let n;if(n=e.$schema,n!==void 0&&typeof n!="string")throw new Error("$schema must be a string");if(n=n||this.opts.defaultMeta||this.defaultMeta(),!n)return this.logger.warn("meta-schema not available"),this.errors=null,!0;let s=this.validate(n,e);if(!s&&t){let i="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(i);else throw new Error(i)}return s}getSchema(e){let t;for(;typeof(t=of.call(this,e))=="string";)e=t;if(t===void 0){let{schemaId:n}=this.opts,s=new Pn.SchemaEnv({schema:{},schemaId:n});if(t=Pn.resolveSchema.call(this,s,e),!t)return;this.refs[e]=t}return t.validate||this._compileSchemaEnv(t)}removeSchema(e){if(e instanceof RegExp)return this._removeAllSchemas(this.schemas,e),this._removeAllSchemas(this.refs,e),this;switch(typeof e){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{let t=of.call(this,e);return typeof t=="object"&&this._cache.delete(t.schema),delete this.schemas[e],delete this.refs[e],this}case"object":{let t=e;this._cache.delete(t);let n=e[this.opts.schemaId];return n&&(n=(0,Rn.normalizeId)(n),delete this.schemas[n],delete this.refs[n]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(e){for(let t of e)this.addKeyword(t);return this}addKeyword(e,t){let n;if(typeof e=="string")n=e,typeof t=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),t.keyword=n);else if(typeof e=="object"&&t===void 0){if(t=e,n=t.keyword,Array.isArray(n)&&!n.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if(Dy.call(this,n,t),!t)return(0,da.eachItem)(n,i=>fa.call(this,i)),this;ky.call(this,t);let s={...t,type:(0,$s.getJSONTypes)(t.type),schemaType:(0,$s.getJSONTypes)(t.schemaType)};return(0,da.eachItem)(n,s.type.length===0?i=>fa.call(this,i,s):i=>s.type.forEach(a=>fa.call(this,i,s,a))),this}getKeyword(e){let t=this.RULES.all[e];return typeof t=="object"?t.definition:!!t}removeKeyword(e){let{RULES:t}=this;delete t.keywords[e],delete t.all[e];for(let n of t.rules){let s=n.rules.findIndex(i=>i.keyword===e);s>=0&&n.rules.splice(s,1)}return this}addFormat(e,t){return typeof t=="string"&&(t=new RegExp(t)),this.formats[e]=t,this}errorsText(e=this.errors,{separator:t=", ",dataVar:n="data"}={}){return!e||e.length===0?"No errors":e.map(s=>`${n}${s.instancePath} ${s.message}`).reduce((s,i)=>s+t+i)}$dataMetaSchema(e,t){let n=this.RULES.all;e=JSON.parse(JSON.stringify(e));for(let s of t){let i=s.split("/").slice(1),a=e;for(let c of i)a=a[c];for(let c in n){let u=n[c];if(typeof u!="object")continue;let{$data:o}=u.definition,l=a[c];o&&l&&(a[c]=lf(l))}}return e}_removeAllSchemas(e,t){for(let n in e){let s=e[n];(!t||t.test(n))&&(typeof s=="string"?delete e[n]:s&&!s.meta&&(this._cache.delete(s.schema),delete e[n]))}}_addSchema(e,t,n,s=this.opts.validateSchema,i=this.opts.addUsedSchema){let a,{schemaId:c}=this.opts;if(typeof e=="object")a=e[c];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof e!="boolean")throw new Error("schema must be object or boolean")}let u=this._cache.get(e);if(u!==void 0)return u;n=(0,Rn.normalizeId)(a||n);let o=Rn.getSchemaRefs.call(this,e,n);return u=new Pn.SchemaEnv({schema:e,schemaId:c,meta:t,baseId:n,localRefs:o}),this._cache.set(u.schema,u),i&&!n.startsWith("#")&&(n&&this._checkUnique(n),this.refs[n]=u),s&&this.validateSchema(e,!0),u}_checkUnique(e){if(this.schemas[e]||this.refs[e])throw new Error(`schema with key or id "${e}" already exists`)}_compileSchemaEnv(e){if(e.meta?this._compileMetaSchema(e):Pn.compileSchema.call(this,e),!e.validate)throw new Error("ajv implementation error");return e.validate}_compileMetaSchema(e){let t=this.opts;this.opts=this._metaOpts;try{Pn.compileSchema.call(this,e)}finally{this.opts=t}}};he.default=Cn;Cn.ValidationError=_y.default;Cn.MissingRefError=cf.default;function af(r,e,t,n="error"){for(let s in r){let i=s;i in e&&this.logger[n](`${t}: option ${s}. ${r[i]}`)}}function of(r){return r=(0,Rn.normalizeId)(r),this.schemas[r]||this.refs[r]}function Ry(){let r=this.opts.schemas;if(!!r)if(Array.isArray(r))this.addSchema(r);else for(let e in r)this.addSchema(r[e],e)}function Cy(){for(let r in this.opts.formats){let e=this.opts.formats[r];e&&this.addFormat(r,e)}}function Ny(r){if(Array.isArray(r)){this.addVocabulary(r);return}this.logger.warn("keywords option as map is deprecated, pass array");for(let e in r){let t=r[e];t.keyword||(t.keyword=e),this.addKeyword(t)}}function Iy(){let r={...this.opts};for(let e of wy)delete r[e];return r}var Ty={log(){},warn(){},error(){}};function Ay(r){if(r===!1)return Ty;if(r===void 0)return console;if(r.log&&r.warn&&r.error)return r;throw new Error("logger must implement log, warn and error methods")}var qy=/^[a-z_$][a-z0-9_$:-]*$/i;function Dy(r,e){let{RULES:t}=this;if((0,da.eachItem)(r,n=>{if(t.keywords[n])throw new Error(`Keyword ${n} is already defined`);if(!qy.test(n))throw new Error(`Keyword ${n} has invalid name`)}),!!e&&e.$data&&!("code"in e||"validate"in e))throw new Error('$data keyword must have "code" or "validate" function')}function fa(r,e,t){var n;let s=e==null?void 0:e.post;if(t&&s)throw new Error('keyword with "post" flag cannot have "type"');let{RULES:i}=this,a=s?i.post:i.rules.find(({type:u})=>u===t);if(a||(a={type:t,rules:[]},i.rules.push(a)),i.keywords[r]=!0,!e)return;let c={keyword:r,definition:{...e,type:(0,$s.getJSONTypes)(e.type),schemaType:(0,$s.getJSONTypes)(e.schemaType)}};e.before?jy.call(this,a,c,e.before):a.rules.push(c),i.all[r]=c,(n=e.implements)===null||n===void 0||n.forEach(u=>this.addKeyword(u))}function jy(r,e,t){let n=r.rules.findIndex(s=>s.keyword===t);n>=0?r.rules.splice(n,0,e):(r.rules.push(e),this.logger.warn(`rule ${t} is not defined`))}function ky(r){let{metaSchema:e}=r;e!==void 0&&(r.$data&&this.opts.$data&&(e=lf(e)),r.validateSchema=this.compile(e,!0))}var xy={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function lf(r){return{anyOf:[r,xy]}}});var df=_(ha=>{"use strict";Object.defineProperty(ha,"__esModule",{value:!0});var Ly={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};ha.default=Ly});var gf=_(Yt=>{"use strict";Object.defineProperty(Yt,"__esModule",{value:!0});Yt.callRef=Yt.getValidate=void 0;var My=oa(),hf=ze(),Ie=L(),Nr=$t(),pf=_s(),Es=G(),Fy={keyword:"$ref",schemaType:"string",code(r){let{gen:e,schema:t,it:n}=r,{baseId:s,schemaEnv:i,validateName:a,opts:c,self:u}=n,{root:o}=i;if((t==="#"||t==="#/")&&s===o.baseId)return d();let l=pf.resolveRef.call(u,o,s,t);if(l===void 0)throw new My.default(n.opts.uriResolver,s,t);if(l instanceof pf.SchemaEnv)return y(l);return m(l);function d(){if(i===o)return ws(r,a,i,i.$async);let $=e.scopeValue("root",{ref:o});return ws(r,(0,Ie._)`${$}.validate`,o,o.$async)}function y($){let E=mf(r,$);ws(r,E,$,$.$async)}function m($){let E=e.scopeValue("schema",c.code.source===!0?{ref:$,code:(0,Ie.stringify)($)}:{ref:$}),w=e.name("valid"),b=r.subschema({schema:$,dataTypes:[],schemaPath:Ie.nil,topSchemaRef:E,errSchemaPath:t},w);r.mergeEvaluated(b),r.ok(w)}}};function mf(r,e){let{gen:t}=r;return e.validate?t.scopeValue("validate",{ref:e.validate}):(0,Ie._)`${t.scopeValue("wrapper",{ref:e})}.validate`}Yt.getValidate=mf;function ws(r,e,t,n){let{gen:s,it:i}=r,{allErrors:a,schemaEnv:c,opts:u}=i,o=u.passContext?Nr.default.this:Ie.nil;n?l():d();function l(){if(!c.$async)throw new Error("async schema referenced by sync schema");let $=s.let("valid");s.try(()=>{s.code((0,Ie._)`await ${(0,hf.callValidateCode)(r,e,o)}`),m(e),a||s.assign($,!0)},E=>{s.if((0,Ie._)`!(${E} instanceof ${i.ValidationError})`,()=>s.throw(E)),y(E),a||s.assign($,!1)}),r.ok($)}function d(){r.result((0,hf.callValidateCode)(r,e,o),()=>m(e),()=>y(e))}function y($){let E=(0,Ie._)`${$}.errors`;s.assign(Nr.default.vErrors,(0,Ie._)`${Nr.default.vErrors} === null ? ${E} : ${Nr.default.vErrors}.concat(${E})`),s.assign(Nr.default.errors,(0,Ie._)`${Nr.default.vErrors}.length`)}function m($){var E;if(!i.opts.unevaluated)return;let w=(E=t==null?void 0:t.validate)===null||E===void 0?void 0:E.evaluated;if(i.props!==!0)if(w&&!w.dynamicProps)w.props!==void 0&&(i.props=Es.mergeEvaluated.props(s,w.props,i.props));else{let b=s.var("props",(0,Ie._)`${$}.evaluated.props`);i.props=Es.mergeEvaluated.props(s,b,i.props,Ie.Name)}if(i.items!==!0)if(w&&!w.dynamicItems)w.items!==void 0&&(i.items=Es.mergeEvaluated.items(s,w.items,i.items));else{let b=s.var("items",(0,Ie._)`${$}.evaluated.items`);i.items=Es.mergeEvaluated.items(s,b,i.items,Ie.Name)}}}Yt.callRef=ws;Yt.default=Fy});var vf=_(pa=>{"use strict";Object.defineProperty(pa,"__esModule",{value:!0});var Vy=df(),Hy=gf(),Uy=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",Vy.default,Hy.default];pa.default=Uy});var _f=_(ma=>{"use strict";Object.defineProperty(ma,"__esModule",{value:!0});var bs=L(),At=bs.operators,Ss={maximum:{okStr:"<=",ok:At.LTE,fail:At.GT},minimum:{okStr:">=",ok:At.GTE,fail:At.LT},exclusiveMaximum:{okStr:"<",ok:At.LT,fail:At.GTE},exclusiveMinimum:{okStr:">",ok:At.GT,fail:At.LTE}},Gy={message:({keyword:r,schemaCode:e})=>(0,bs.str)`must be ${Ss[r].okStr} ${e}`,params:({keyword:r,schemaCode:e})=>(0,bs._)`{comparison: ${Ss[r].okStr}, limit: ${e}}`},zy={keyword:Object.keys(Ss),type:"number",schemaType:"number",$data:!0,error:Gy,code(r){let{keyword:e,data:t,schemaCode:n}=r;r.fail$data((0,bs._)`${t} ${Ss[e].fail} ${n} || isNaN(${t})`)}};ma.default=zy});var yf=_(ga=>{"use strict";Object.defineProperty(ga,"__esModule",{value:!0});var Nn=L(),Ky={message:({schemaCode:r})=>(0,Nn.str)`must be multiple of ${r}`,params:({schemaCode:r})=>(0,Nn._)`{multipleOf: ${r}}`},Xy={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:Ky,code(r){let{gen:e,data:t,schemaCode:n,it:s}=r,i=s.opts.multipleOfPrecision,a=e.let("res"),c=i?(0,Nn._)`Math.abs(Math.round(${a}) - ${a}) > 1e-${i}`:(0,Nn._)`${a} !== parseInt(${a})`;r.fail$data((0,Nn._)`(${n} === 0 || (${a} = ${t}/${n}, ${c}))`)}};ga.default=Xy});var Ef=_(va=>{"use strict";Object.defineProperty(va,"__esModule",{value:!0});function $f(r){let e=r.length,t=0,n=0,s;for(;n<e;)t++,s=r.charCodeAt(n++),s>=55296&&s<=56319&&n<e&&(s=r.charCodeAt(n),(s&64512)===56320&&n++);return t}va.default=$f;$f.code='require("ajv/dist/runtime/ucs2length").default'});var wf=_(_a=>{"use strict";Object.defineProperty(_a,"__esModule",{value:!0});var Zt=L(),Wy=G(),By=Ef(),Jy={message({keyword:r,schemaCode:e}){let t=r==="maxLength"?"more":"fewer";return(0,Zt.str)`must NOT have ${t} than ${e} characters`},params:({schemaCode:r})=>(0,Zt._)`{limit: ${r}}`},Yy={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:Jy,code(r){let{keyword:e,data:t,schemaCode:n,it:s}=r,i=e==="maxLength"?Zt.operators.GT:Zt.operators.LT,a=s.opts.unicode===!1?(0,Zt._)`${t}.length`:(0,Zt._)`${(0,Wy.useFunc)(r.gen,By.default)}(${t})`;r.fail$data((0,Zt._)`${a} ${i} ${n}`)}};_a.default=Yy});var bf=_(ya=>{"use strict";Object.defineProperty(ya,"__esModule",{value:!0});var Zy=ze(),Os=L(),Qy={message:({schemaCode:r})=>(0,Os.str)`must match pattern "${r}"`,params:({schemaCode:r})=>(0,Os._)`{pattern: ${r}}`},e0={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:Qy,code(r){let{data:e,$data:t,schema:n,schemaCode:s,it:i}=r,a=i.opts.unicodeRegExp?"u":"",c=t?(0,Os._)`(new RegExp(${s}, ${a}))`:(0,Zy.usePattern)(r,n);r.fail$data((0,Os._)`!${c}.test(${e})`)}};ya.default=e0});var Sf=_($a=>{"use strict";Object.defineProperty($a,"__esModule",{value:!0});var In=L(),t0={message({keyword:r,schemaCode:e}){let t=r==="maxProperties"?"more":"fewer";return(0,In.str)`must NOT have ${t} than ${e} properties`},params:({schemaCode:r})=>(0,In._)`{limit: ${r}}`},r0={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:t0,code(r){let{keyword:e,data:t,schemaCode:n}=r,s=e==="maxProperties"?In.operators.GT:In.operators.LT;r.fail$data((0,In._)`Object.keys(${t}).length ${s} ${n}`)}};$a.default=r0});var Of=_(Ea=>{"use strict";Object.defineProperty(Ea,"__esModule",{value:!0});var Tn=ze(),An=L(),n0=G(),s0={message:({params:{missingProperty:r}})=>(0,An.str)`must have required property '${r}'`,params:({params:{missingProperty:r}})=>(0,An._)`{missingProperty: ${r}}`},i0={keyword:"required",type:"object",schemaType:"array",$data:!0,error:s0,code(r){let{gen:e,schema:t,schemaCode:n,data:s,$data:i,it:a}=r,{opts:c}=a;if(!i&&t.length===0)return;let u=t.length>=c.loopRequired;if(a.allErrors?o():l(),c.strictRequired){let m=r.parentSchema.properties,{definedProperties:$}=r.it;for(let E of t)if((m==null?void 0:m[E])===void 0&&!$.has(E)){let w=a.schemaEnv.baseId+a.errSchemaPath,b=`required property "${E}" is not defined at "${w}" (strictRequired)`;(0,n0.checkStrictMode)(a,b,a.opts.strictRequired)}}function o(){if(u||i)r.block$data(An.nil,d);else for(let m of t)(0,Tn.checkReportMissingProp)(r,m)}function l(){let m=e.let("missing");if(u||i){let $=e.let("valid",!0);r.block$data($,()=>y(m,$)),r.ok($)}else e.if((0,Tn.checkMissingProp)(r,t,m)),(0,Tn.reportMissingProp)(r,m),e.else()}function d(){e.forOf("prop",n,m=>{r.setParams({missingProperty:m}),e.if((0,Tn.noPropertyInData)(e,s,m,c.ownProperties),()=>r.error())})}function y(m,$){r.setParams({missingProperty:m}),e.forOf(m,n,()=>{e.assign($,(0,Tn.propertyInData)(e,s,m,c.ownProperties)),e.if((0,An.not)($),()=>{r.error(),e.break()})},An.nil)}}};Ea.default=i0});var Pf=_(wa=>{"use strict";Object.defineProperty(wa,"__esModule",{value:!0});var qn=L(),a0={message({keyword:r,schemaCode:e}){let t=r==="maxItems"?"more":"fewer";return(0,qn.str)`must NOT have ${t} than ${e} items`},params:({schemaCode:r})=>(0,qn._)`{limit: ${r}}`},o0={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:a0,code(r){let{keyword:e,data:t,schemaCode:n}=r,s=e==="maxItems"?qn.operators.GT:qn.operators.LT;r.fail$data((0,qn._)`${t}.length ${s} ${n}`)}};wa.default=o0});var Ps=_(ba=>{"use strict";Object.defineProperty(ba,"__esModule",{value:!0});var Rf=Ji();Rf.code='require("ajv/dist/runtime/equal").default';ba.default=Rf});var Cf=_(Oa=>{"use strict";Object.defineProperty(Oa,"__esModule",{value:!0});var Sa=En(),pe=L(),c0=G(),u0=Ps(),l0={message:({params:{i:r,j:e}})=>(0,pe.str)`must NOT have duplicate items (items ## ${e} and ${r} are identical)`,params:({params:{i:r,j:e}})=>(0,pe._)`{i: ${r}, j: ${e}}`},f0={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:l0,code(r){let{gen:e,data:t,$data:n,schema:s,parentSchema:i,schemaCode:a,it:c}=r;if(!n&&!s)return;let u=e.let("valid"),o=i.items?(0,Sa.getSchemaTypes)(i.items):[];r.block$data(u,l,(0,pe._)`${a} === false`),r.ok(u);function l(){let $=e.let("i",(0,pe._)`${t}.length`),E=e.let("j");r.setParams({i:$,j:E}),e.assign(u,!0),e.if((0,pe._)`${$} > 1`,()=>(d()?y:m)($,E))}function d(){return o.length>0&&!o.some($=>$==="object"||$==="array")}function y($,E){let w=e.name("item"),b=(0,Sa.checkDataTypes)(o,w,c.opts.strictNumbers,Sa.DataType.Wrong),D=e.const("indices",(0,pe._)`{}`);e.for((0,pe._)`;${$}--;`,()=>{e.let(w,(0,pe._)`${t}[${$}]`),e.if(b,(0,pe._)`continue`),o.length>1&&e.if((0,pe._)`typeof ${w} == "string"`,(0,pe._)`${w} += "_"`),e.if((0,pe._)`typeof ${D}[${w}] == "number"`,()=>{e.assign(E,(0,pe._)`${D}[${w}]`),r.error(),e.assign(u,!1).break()}).code((0,pe._)`${D}[${w}] = ${$}`)})}function m($,E){let w=(0,c0.useFunc)(e,u0.default),b=e.name("outer");e.label(b).for((0,pe._)`;${$}--;`,()=>e.for((0,pe._)`${E} = ${$}; ${E}--;`,()=>e.if((0,pe._)`${w}(${t}[${$}], ${t}[${E}])`,()=>{r.error(),e.assign(u,!1).break(b)})))}}};Oa.default=f0});var Nf=_(Ra=>{"use strict";Object.defineProperty(Ra,"__esModule",{value:!0});var Pa=L(),d0=G(),h0=Ps(),p0={message:"must be equal to constant",params:({schemaCode:r})=>(0,Pa._)`{allowedValue: ${r}}`},m0={keyword:"const",$data:!0,error:p0,code(r){let{gen:e,data:t,$data:n,schemaCode:s,schema:i}=r;n||i&&typeof i=="object"?r.fail$data((0,Pa._)`!${(0,d0.useFunc)(e,h0.default)}(${t}, ${s})`):r.fail((0,Pa._)`${i} !== ${t}`)}};Ra.default=m0});var If=_(Ca=>{"use strict";Object.defineProperty(Ca,"__esModule",{value:!0});var Dn=L(),g0=G(),v0=Ps(),_0={message:"must be equal to one of the allowed values",params:({schemaCode:r})=>(0,Dn._)`{allowedValues: ${r}}`},y0={keyword:"enum",schemaType:"array",$data:!0,error:_0,code(r){let{gen:e,data:t,$data:n,schema:s,schemaCode:i,it:a}=r;if(!n&&s.length===0)throw new Error("enum must have non-empty array");let c=s.length>=a.opts.loopEnum,u,o=()=>u!=null?u:u=(0,g0.useFunc)(e,v0.default),l;if(c||n)l=e.let("valid"),r.block$data(l,d);else{if(!Array.isArray(s))throw new Error("ajv implementation error");let m=e.const("vSchema",i);l=(0,Dn.or)(...s.map(($,E)=>y(m,E)))}r.pass(l);function d(){e.assign(l,!1),e.forOf("v",i,m=>e.if((0,Dn._)`${o()}(${t}, ${m})`,()=>e.assign(l,!0).break()))}function y(m,$){let E=s[$];return typeof E=="object"&&E!==null?(0,Dn._)`${o()}(${t}, ${m}[${$}])`:(0,Dn._)`${t} === ${E}`}}};Ca.default=y0});var Tf=_(Na=>{"use strict";Object.defineProperty(Na,"__esModule",{value:!0});var $0=_f(),E0=yf(),w0=wf(),b0=bf(),S0=Sf(),O0=Of(),P0=Pf(),R0=Cf(),C0=Nf(),N0=If(),I0=[$0.default,E0.default,w0.default,b0.default,S0.default,O0.default,P0.default,R0.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},C0.default,N0.default];Na.default=I0});var Ta=_(jn=>{"use strict";Object.defineProperty(jn,"__esModule",{value:!0});jn.validateAdditionalItems=void 0;var Qt=L(),Ia=G(),T0={message:({params:{len:r}})=>(0,Qt.str)`must NOT have more than ${r} items`,params:({params:{len:r}})=>(0,Qt._)`{limit: ${r}}`},A0={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:T0,code(r){let{parentSchema:e,it:t}=r,{items:n}=e;if(!Array.isArray(n)){(0,Ia.checkStrictMode)(t,'"additionalItems" is ignored when "items" is not an array of schemas');return}Af(r,n)}};function Af(r,e){let{gen:t,schema:n,data:s,keyword:i,it:a}=r;a.items=!0;let c=t.const("len",(0,Qt._)`${s}.length`);if(n===!1)r.setParams({len:e.length}),r.pass((0,Qt._)`${c} <= ${e.length}`);else if(typeof n=="object"&&!(0,Ia.alwaysValidSchema)(a,n)){let o=t.var("valid",(0,Qt._)`${c} <= ${e.length}`);t.if((0,Qt.not)(o),()=>u(o)),r.ok(o)}function u(o){t.forRange("i",e.length,c,l=>{r.subschema({keyword:i,dataProp:l,dataPropType:Ia.Type.Num},o),a.allErrors||t.if((0,Qt.not)(o),()=>t.break())})}}jn.validateAdditionalItems=Af;jn.default=A0});var Aa=_(kn=>{"use strict";Object.defineProperty(kn,"__esModule",{value:!0});kn.validateTuple=void 0;var qf=L(),Rs=G(),q0=ze(),D0={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(r){let{schema:e,it:t}=r;if(Array.isArray(e))return Df(r,"additionalItems",e);t.items=!0,!(0,Rs.alwaysValidSchema)(t,e)&&r.ok((0,q0.validateArray)(r))}};function Df(r,e,t=r.schema){let{gen:n,parentSchema:s,data:i,keyword:a,it:c}=r;l(s),c.opts.unevaluated&&t.length&&c.items!==!0&&(c.items=Rs.mergeEvaluated.items(n,t.length,c.items));let u=n.name("valid"),o=n.const("len",(0,qf._)`${i}.length`);t.forEach((d,y)=>{(0,Rs.alwaysValidSchema)(c,d)||(n.if((0,qf._)`${o} > ${y}`,()=>r.subschema({keyword:a,schemaProp:y,dataProp:y},u)),r.ok(u))});function l(d){let{opts:y,errSchemaPath:m}=c,$=t.length,E=$===d.minItems&&($===d.maxItems||d[e]===!1);if(y.strictTuples&&!E){let w=`"${a}" is ${$}-tuple, but minItems or maxItems/${e} are not specified or different at path "${m}"`;(0,Rs.checkStrictMode)(c,w,y.strictTuples)}}}kn.validateTuple=Df;kn.default=D0});var jf=_(qa=>{"use strict";Object.defineProperty(qa,"__esModule",{value:!0});var j0=Aa(),k0={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:r=>(0,j0.validateTuple)(r,"items")};qa.default=k0});var xf=_(Da=>{"use strict";Object.defineProperty(Da,"__esModule",{value:!0});var kf=L(),x0=G(),L0=ze(),M0=Ta(),F0={message:({params:{len:r}})=>(0,kf.str)`must NOT have more than ${r} items`,params:({params:{len:r}})=>(0,kf._)`{limit: ${r}}`},V0={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:F0,code(r){let{schema:e,parentSchema:t,it:n}=r,{prefixItems:s}=t;n.items=!0,!(0,x0.alwaysValidSchema)(n,e)&&(s?(0,M0.validateAdditionalItems)(r,s):r.ok((0,L0.validateArray)(r)))}};Da.default=V0});var Lf=_(ja=>{"use strict";Object.defineProperty(ja,"__esModule",{value:!0});var Xe=L(),Cs=G(),H0={message:({params:{min:r,max:e}})=>e===void 0?(0,Xe.str)`must contain at least ${r} valid item(s)`:(0,Xe.str)`must contain at least ${r} and no more than ${e} valid item(s)`,params:({params:{min:r,max:e}})=>e===void 0?(0,Xe._)`{minContains: ${r}}`:(0,Xe._)`{minContains: ${r}, maxContains: ${e}}`},U0={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:H0,code(r){let{gen:e,schema:t,parentSchema:n,data:s,it:i}=r,a,c,{minContains:u,maxContains:o}=n;i.opts.next?(a=u===void 0?1:u,c=o):a=1;let l=e.const("len",(0,Xe._)`${s}.length`);if(r.setParams({min:a,max:c}),c===void 0&&a===0){(0,Cs.checkStrictMode)(i,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(c!==void 0&&a>c){(0,Cs.checkStrictMode)(i,'"minContains" > "maxContains" is always invalid'),r.fail();return}if((0,Cs.alwaysValidSchema)(i,t)){let E=(0,Xe._)`${l} >= ${a}`;c!==void 0&&(E=(0,Xe._)`${E} && ${l} <= ${c}`),r.pass(E);return}i.items=!0;let d=e.name("valid");c===void 0&&a===1?m(d,()=>e.if(d,()=>e.break())):a===0?(e.let(d,!0),c!==void 0&&e.if((0,Xe._)`${s}.length > 0`,y)):(e.let(d,!1),y()),r.result(d,()=>r.reset());function y(){let E=e.name("_valid"),w=e.let("count",0);m(E,()=>e.if(E,()=>$(w)))}function m(E,w){e.forRange("i",0,l,b=>{r.subschema({keyword:"contains",dataProp:b,dataPropType:Cs.Type.Num,compositeRule:!0},E),w()})}function $(E){e.code((0,Xe._)`${E}++`),c===void 0?e.if((0,Xe._)`${E} >= ${a}`,()=>e.assign(d,!0).break()):(e.if((0,Xe._)`${E} > ${c}`,()=>e.assign(d,!1).break()),a===1?e.assign(d,!0):e.if((0,Xe._)`${E} >= ${a}`,()=>e.assign(d,!0)))}}};ja.default=U0});var Vf=_(ct=>{"use strict";Object.defineProperty(ct,"__esModule",{value:!0});ct.validateSchemaDeps=ct.validatePropertyDeps=ct.error=void 0;var ka=L(),G0=G(),xn=ze();ct.error={message:({params:{property:r,depsCount:e,deps:t}})=>{let n=e===1?"property":"properties";return(0,ka.str)`must have ${n} ${t} when property ${r} is present`},params:({params:{property:r,depsCount:e,deps:t,missingProperty:n}})=>(0,ka._)`{property: ${r},
|
|
3
|
+
`)),[3,3];case 2:return i=a.sent(),[3,3];case 3:return[2]}})})};I.aiRequest=Pv;function Ov(){var t=(0,we.getCoreVersion)(),e=["".concat(Iu.name,": ").concat(Iu.version),t?"core: ".concat(t):void 0,"s-home: ".concat(we.default.getRootHome()),"".concat(process.platform,"-").concat(process.arch),"node-".concat(process.version)];return e.filter(function(r){return r}).join(", ")}I.getVersion=Ov;function Rv(t){return yr(this,void 0,void 0,function(){function e(s){return yr(this,void 0,void 0,function(){var i,a;return _r(this,function(c){switch(c.label){case 0:return i=an.default.lstatSync(s),typeof i!="object"?[2]:(r.set(i.ino,i.size),i.isDirectory()?(a=an.default.readdirSync(s),typeof a!="object"?[2]:[4,Promise.all(a.map(function(l){return e(ov.default.join(s,l))}))]):[3,2]);case 1:c.sent(),c.label=2;case 2:return[2]}})})}var r,n;return _r(this,function(s){switch(s.label){case 0:return r=new Map,[4,e(t)];case 1:return s.sent(),n=Array.from(r.values()).reduce(function(i,a){return i+a},0),[2,n]}})})}I.getFolderSize=Rv;function Nv(t,e){e===void 0&&(e=" ");for(var r="",n=0;n<t;n++)r=r+e;return r}I.printn=Nv;function Iv(){return"en"}I.getLang=Iv;function Cu(t,e){var r=/\{\{(.*?)\}\}/g,n=t.match(r);if(n)for(var s=0;s<n.length;s++){var i=n[s].replace(/{{|}}/g,""),a=pv(i.split("|")[0]);e[a]&&(t=t.replace(n[s],e[a]))}return t}I.replaceFun=Cu;function Tv(t,e){t.forEach(function(r){if(an.default.existsSync(r)){var n=an.default.readFileSync(r,"utf-8"),s=Cu(n,e);an.default.writeFileSync(r,s,"utf-8")}})}I.replaceTemplate=Tv;function qv(t){if(!t)return t;var e=t.slice(-4);return"***********".concat(e)}I.mark=qv;function li(t,e){return cv.default.platform()==="win32"?e||"\u25C6":"".concat(t," ")}I.emoji=li;function ju(t,e){var r=t.length,n=new Array(e-r).fill(" ");return"".concat(t).concat(n.join("")," : ")}I.getTempCommandStr=ju;function Cv(t){return yr(this,void 0,void 0,function(){var e,r,n,s,i,c,a,c;return _r(this,function(l){switch(l.label){case 0:return[4,we.default.getYamlContent(t)];case 1:if(e=l.sent(),gr.default.log(`
|
|
4
|
+
`.concat(li("\u{1F680}")," ").concat(e.Name,"@").concat(e.Version,": ").concat(e.Description,`
|
|
5
|
+
`)),r=e.Commands,r){n=Tu.maxLen(r),s=[],i={};for(c in r)a=r[c],yv(a)?s.push(Tu.helpInfo(a,$v(Ev(c)),n,4)):i[c]=a;if(s.length>0&&gr.default.log(s.join(`
|
|
6
|
+
`)),!_v(i)){for(c in i)gr.default.log(" ".concat(ju(c,n)," ").concat(i[c]));gr.default.log("")}gr.default.log(e.HomePage?" ".concat(li("\u{1F9ED}")," ").concat(we.default.makeUnderLine("More information: "+e.HomePage)," ")+`
|
|
7
|
+
`:"")}return[2]}})})}I.specifyServiceHelp=Cv});var Du=y(di=>{"use strict";Object.defineProperty(di,"__esModule",{value:!0});di.default={clean_up_the_environment:"\u6E05\u7406\u73AF\u5883",display_help_for_command:"\u663E\u793A\u547D\u4EE4\u5E2E\u52A9",remove_components:"\u5220\u9664\u7EC4\u4EF6",delete_the_file_under_the_cache:"\u5220\u9664\u7F13\u5B58\u91CC\u7684\u7684<dirname>\u6587\u4EF6",record_your_log_information:"\u662F\u5426\u8BB0\u5F55\u60A8\u7684\u65E5\u5FD7\u4FE1\u606F\uFF1F",init_pproject_deploy_tip:"\u662F\u5426\u7ACB\u5373\u90E8\u7F72\u8BE5\u9879\u76EE\uFF1F",tip_for_a_serverless_project:"\u68C0\u6D4B\u5230\u5F53\u524D\u76EE\u5F55\u4E0B\u5DF2\u5B58\u5728\u4E00\u4E2AServerless-Devs\u9879\u76EE\uFF0C\u8BF7\u901A\u8FC7 's deploy' \u8FDB\u884C\u90E8\u7F72\u6216\u901A\u8FC7 's -h' \u83B7\u53D6\u66F4\u591A\u4FE1\u606F",create_a_new_project:"\u672A\u68C0\u6D4B\u5230 Serverless-Devs \u9879\u76EE\uFF0C\u662F\u5426\u65B0\u5EFA\u4E00\u4E2A\u9879\u76EE\uFF1F",en:"English (en)",zh:"\u4E2D\u6587 (zh)",select_current_language:"\u8BF7\u9009\u62E9\u5F53\u524D\u8BED\u8A00","app-tip":"\u8BF7\u9009\u62E9\u60A8\u5E0C\u671B\u521B\u5EFA\u7684 Serverless-Devs \u5E94\u7528","template-tip":"\u8BF7\u9009\u62E9\u60A8\u559C\u6B22\u7684\u6A21\u7248","fc-runtime-starter":"fc-runtime-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A FC \u51FD\u6570","fc-custom-container-stater":"fc-custom-container-stater - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A custom-container \u5E94\u7528",web:"web-framework-stater - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A Web \u6846\u67B6","static-site":"static-website-stater - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u9759\u6001\u7F51\u7AD9","best-practice":"serverless-best-practice - \u5FEB\u901F\u4F53\u9A8C Serverless \u6700\u4F73\u5B9E\u8DF5","devs-template":"Serverless Devs \u5F00\u53D1\u6A21\u677F","fc-http-nodejs":"fc-http-nodejs - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A nodejs12 \u51FD\u6570","fc-http-python":"fc-http-python - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A python3 \u51FD\u6570","fc-http-java":"fc-http-java - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A java8 \u51FD\u6570","fc-custom-container-event-python3":"fc-custom-container-event-python3 - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7\u4E8B\u4EF6\u89E6\u53D1\u7684 python3 \u5E94\u7528","fc-custom-container-event-cpp":"fc-custom-container-event-cpp - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7\u4E8B\u4EF6\u89E6\u53D1\u7684 cpp \u5E94\u7528","fc-custom-container-http-springboot":"fc-custom-container-http-springboot - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7 HTTP \u8BF7\u6C42\u89E6\u53D1\u7684 springboot \u5E94\u7528","fc-custom-container-http-aspdotnetcore":"fc-custom-container-http-aspdotnetcore - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u901A\u8FC7 HTTP \u8BF7\u6C42\u89E6\u53D1\u7684 aspdotnetcore \u5E94\u7528","express-starter":"express-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A express \u57FA\u7840\u5E94\u7528","koa-starter":"koa-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A koa \u57FA\u7840\u5E94\u7528","nuxtjs-starter":"nuxtjs-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A nuxtjs \u57FA\u7840\u5E94\u7528","eggjs-starter":"eggjs-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A eggjs \u57FA\u7840\u5E94\u7528","flask-starter":"flask-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A flask \u57FA\u7840\u5E94\u7528","SpringBoot-starter":"SpringBoot-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A SpringBoot \u57FA\u7840\u5E94\u7528","Zblog-starter":"Zblog-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A Zblog \u57FA\u7840\u5E94\u7528","website-starter":"website-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u9759\u6001\u7F51\u7AD9","react-starter":"react-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A React.js \u5E94\u7528","vue-starter":"vue-starter - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A Vue.js \u5E94\u7528",puppeteer:"puppeteer - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u57FA\u4E8E puppeteer \u622A\u56FE\u7684 Web \u5E94\u7528",ffmpeg:"ffmpeg - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u57FA\u4E8E ffmpeg \u5B9E\u73B0\u97F3\u89C6\u9891\u5904\u7406\u5E94\u7528",pdf2Img:"pdf2Img - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A pdf \u8F6C\u56FE\u7247\u5E94\u7528",tensorflow:"tensorflow - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A tensorflow \u5E94\u7528",todoList:"todoList - \u5FEB\u901F\u90E8\u7F72\u4E00\u4E2A\u57FA\u4E8E nodejs \u7684\u7F51\u9875 TodoList \u5E94\u7528"}});var Au=y(hi=>{"use strict";Object.defineProperty(hi,"__esModule",{value:!0});hi.default={clean_up_the_environment:"Clean up the environment",display_help_for_command:"Display help for command",remove_components:"Remove component (like: fc, fc@0.0.1)",delete_the_file_under_the_cache:"Delete the <dirname> file in the cache",record_your_log_information:"Do you record your log information?",init_pproject_deploy_tip:"Do you want to deploy the project immediately?",tip_for_a_serverless_project:"A Serverless-Devs project is detected in the current directory, please deploy via 's deploy' or get more information via 's -h'",create_a_new_project:"No Serverless-Devs project is currently detected. Do you want to create a new project?",en:"English (en)",zh:"Chinese (zh)",select_current_language:"Please select current language","app-tip":"Hello, serverlesser. Which template do you like?","template-tip":"Which template do you like?","fc-runtime-starter":"fc-runtime-starter - Deploy FC function in 5 minutes","fc-custom-container-stater":"fc-custom-container-stater - Deploy FC function with custom-container",web:"web-framework-stater-Quickly deploy a web framework","static-site":"static-website-stater-Quickly deploy a static website","best-practice":"serverless-best-practice-Quickly experience serverless best practices","devs-template":"Serverless Develop scaffold","fc-http-nodejs":"fc-http-nodejs - Deploy FC nodejs12 runtime function","fc-http-python":"fc-http-python - Deploy FC python3 runtime function","fc-http-java":"fc-http-java - Deploy FC java8 runtime function","fc-custom-container-event-python3":"fc-custom-container-event-python3 - Deploy python3 event-triggered application","fc-custom-container-event-cpp":"fc-custom-container-event-cpp - Deploy cpp event-triggered application","fc-custom-container-http-springboot":"fc-custom-container-http-springboot - Deploy springboot HTTP Request-triggered application","fc-custom-container-http-aspdotnetcore":"fc-custom-container-http-aspdotnetcore - Deploy dotnetcore HTTP Request-triggered application","express-starter":"express-starter - Deploy express application","koa-starter":"koa-starter - Deploy koa application","nuxtjs-starter":"nuxtjs-starter - Deploy nuxtjs application","eggjs-starter":"eggjs-starter - Deploy eggjs application","flask-starter":"flask-starter - Deploy flask application","SpringBoot-starter":"SpringBoot-starter - Deploy SpringBoot application","Zblog-starter":"Zblog-starter - Deploy Zblog application","website-starter":"website-starter - Deploy static website","react-starter":"react-starter - Deploy React.js application","vue-starter":"vue-starter - Deploy Vue.js application",puppeteer:"puppeteer - Deploy screenshot application base on puppeteer + fc",ffmpeg:"ffmpeg - Deploy audio and video processing application base on ffmpeg + fc",pdf2Img:"pdf2Img - Deploy pdf to images application",tensorflow:"tensorflow - Deploy tensorflow application",todoList:"todoList - Deploy todoList application"}});var mi=y(on=>{"use strict";var ku=on&&on.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(on,"__esModule",{value:!0});var jv=fi(),Dv=ku(Du()),Av=ku(Au()),pi={en:Av.default,zh:Dv.default},kv=function(t){var e=(0,jv.getLang)(),r=pi[e]?pi[e][t]:pi.en[t];return r||t};on.default=kv});var cn=y(ge=>{"use strict";var Lv=ge&&ge.__createBinding||(Object.create?function(t,e,r,n){n===void 0&&(n=r);var s=Object.getOwnPropertyDescriptor(e,r);(!s||("get"in s?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,s)}:function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]}),Lu=ge&&ge.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&Lv(e,t,r)},vi=ge&&ge.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(ge,"__esModule",{value:!0});ge.registerCommandChecker=ge.i18n=ge.logger=void 0;var Mv=vi(es());Lu(fi(),ge);Lu(ci(),ge);var xv=es();Object.defineProperty(ge,"logger",{enumerable:!0,get:function(){return vi(xv).default}});var Fv=mi();Object.defineProperty(ge,"i18n",{enumerable:!0,get:function(){return vi(Fv).default}});function Vv(t){t.on("command:*",function(e){var r=t.commands.map(function(n){return n.name()});r.includes(e[0])||(Mv.default.error(" error: unknown command ".concat(e[0])),t.help())})}ge.registerCommandChecker=Vv});var fn=y(G=>{"use strict";Object.defineProperty(G,"__esModule",{value:!0});G.regexpCode=G.getEsmExportName=G.getProperty=G.safeStringify=G.stringify=G.strConcat=G.addCodeArg=G.str=G._=G.nil=G._Code=G.Name=G.IDENTIFIER=G._CodeOrName=void 0;var un=class{};G._CodeOrName=un;G.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var Kt=class extends un{constructor(e){if(super(),!G.IDENTIFIER.test(e))throw new Error("CodeGen: name must be a valid identifier");this.str=e}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}};G.Name=Kt;var Ue=class extends un{constructor(e){super(),this._items=typeof e=="string"?[e]:e}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;let e=this._items[0];return e===""||e==='""'}get str(){var e;return(e=this._str)!==null&&e!==void 0?e:this._str=this._items.reduce((r,n)=>`${r}${n}`,"")}get names(){var e;return(e=this._names)!==null&&e!==void 0?e:this._names=this._items.reduce((r,n)=>(n instanceof Kt&&(r[n.str]=(r[n.str]||0)+1),r),{})}};G._Code=Ue;G.nil=new Ue("");function Mu(t,...e){let r=[t[0]],n=0;for(;n<e.length;)yi(r,e[n]),r.push(t[++n]);return new Ue(r)}G._=Mu;var gi=new Ue("+");function xu(t,...e){let r=[ln(t[0])],n=0;for(;n<e.length;)r.push(gi),yi(r,e[n]),r.push(gi,ln(t[++n]));return Uv(r),new Ue(r)}G.str=xu;function yi(t,e){e instanceof Ue?t.push(...e._items):e instanceof Kt?t.push(e):t.push(zv(e))}G.addCodeArg=yi;function Uv(t){let e=1;for(;e<t.length-1;){if(t[e]===gi){let r=Gv(t[e-1],t[e+1]);if(r!==void 0){t.splice(e-1,3,r);continue}t[e++]="+"}e++}}function Gv(t,e){if(e==='""')return t;if(t==='""')return e;if(typeof t=="string")return e instanceof Kt||t[t.length-1]!=='"'?void 0:typeof e!="string"?`${t.slice(0,-1)}${e}"`:e[0]==='"'?t.slice(0,-1)+e.slice(1):void 0;if(typeof e=="string"&&e[0]==='"'&&!(t instanceof Kt))return`"${t}${e.slice(1)}`}function Hv(t,e){return e.emptyStr()?t:t.emptyStr()?e:xu`${t}${e}`}G.strConcat=Hv;function zv(t){return typeof t=="number"||typeof t=="boolean"||t===null?t:ln(Array.isArray(t)?t.join(","):t)}function Kv(t){return new Ue(ln(t))}G.stringify=Kv;function ln(t){return JSON.stringify(t).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}G.safeStringify=ln;function Xv(t){return typeof t=="string"&&G.IDENTIFIER.test(t)?new Ue(`.${t}`):Mu`[${t}]`}G.getProperty=Xv;function Bv(t){if(typeof t=="string"&&G.IDENTIFIER.test(t))return new Ue(`${t}`);throw new Error(`CodeGen: invalid export name: ${t}, use explicit $id name mapping`)}G.getEsmExportName=Bv;function Wv(t){return new Ue(t.toString())}G.regexpCode=Wv});var wi=y(be=>{"use strict";Object.defineProperty(be,"__esModule",{value:!0});be.ValueScope=be.ValueScopeName=be.Scope=be.varKinds=be.UsedValueState=void 0;var Ie=fn(),_i=class extends Error{constructor(e){super(`CodeGen: "code" for ${e} not defined`),this.value=e.value}},$i;(function(t){t[t.Started=0]="Started",t[t.Completed=1]="Completed"})($i=be.UsedValueState||(be.UsedValueState={}));be.varKinds={const:new Ie.Name("const"),let:new Ie.Name("let"),var:new Ie.Name("var")};var rs=class{constructor({prefixes:e,parent:r}={}){this._names={},this._prefixes=e,this._parent=r}toName(e){return e instanceof Ie.Name?e:this.name(e)}name(e){return new Ie.Name(this._newName(e))}_newName(e){let r=this._names[e]||this._nameGroup(e);return`${e}${r.index++}`}_nameGroup(e){var r,n;if(((n=(r=this._parent)===null||r===void 0?void 0:r._prefixes)===null||n===void 0?void 0:n.has(e))||this._prefixes&&!this._prefixes.has(e))throw new Error(`CodeGen: prefix "${e}" is not allowed in this scope`);return this._names[e]={prefix:e,index:0}}};be.Scope=rs;var ns=class extends Ie.Name{constructor(e,r){super(r),this.prefix=e}setValue(e,{property:r,itemIndex:n}){this.value=e,this.scopePath=(0,Ie._)`.${new Ie.Name(r)}[${n}]`}};be.ValueScopeName=ns;var Yv=(0,Ie._)`\n`,Ei=class extends rs{constructor(e){super(e),this._values={},this._scope=e.scope,this.opts={...e,_n:e.lines?Yv:Ie.nil}}get(){return this._scope}name(e){return new ns(e,this._newName(e))}value(e,r){var n;if(r.ref===void 0)throw new Error("CodeGen: ref must be passed in value");let s=this.toName(e),{prefix:i}=s,a=(n=r.key)!==null&&n!==void 0?n:r.ref,c=this._values[i];if(c){let f=c.get(a);if(f)return f}else c=this._values[i]=new Map;c.set(a,s);let l=this._scope[i]||(this._scope[i]=[]),o=l.length;return l[o]=r.ref,s.setValue(r,{property:i,itemIndex:o}),s}getValue(e,r){let n=this._values[e];if(!!n)return n.get(r)}scopeRefs(e,r=this._values){return this._reduceValues(r,n=>{if(n.scopePath===void 0)throw new Error(`CodeGen: name "${n}" has no value`);return(0,Ie._)`${e}${n.scopePath}`})}scopeCode(e=this._values,r,n){return this._reduceValues(e,s=>{if(s.value===void 0)throw new Error(`CodeGen: name "${s}" has no value`);return s.value.code},r,n)}_reduceValues(e,r,n={},s){let i=Ie.nil;for(let a in e){let c=e[a];if(!c)continue;let l=n[a]=n[a]||new Map;c.forEach(o=>{if(l.has(o))return;l.set(o,$i.Started);let f=r(o);if(f){let h=this.opts.es5?be.varKinds.var:be.varKinds.const;i=(0,Ie._)`${i}${h} ${o} = ${f};${this.opts._n}`}else if(f=s==null?void 0:s(o))i=(0,Ie._)`${i}${f}${this.opts._n}`;else throw new _i(o);l.set(o,$i.Completed)})}return i}};be.ValueScope=Ei});var M=y(k=>{"use strict";Object.defineProperty(k,"__esModule",{value:!0});k.or=k.and=k.not=k.CodeGen=k.operators=k.varKinds=k.ValueScopeName=k.ValueScope=k.Scope=k.Name=k.regexpCode=k.stringify=k.getProperty=k.nil=k.strConcat=k.str=k._=void 0;var x=fn(),We=wi(),Nt=fn();Object.defineProperty(k,"_",{enumerable:!0,get:function(){return Nt._}});Object.defineProperty(k,"str",{enumerable:!0,get:function(){return Nt.str}});Object.defineProperty(k,"strConcat",{enumerable:!0,get:function(){return Nt.strConcat}});Object.defineProperty(k,"nil",{enumerable:!0,get:function(){return Nt.nil}});Object.defineProperty(k,"getProperty",{enumerable:!0,get:function(){return Nt.getProperty}});Object.defineProperty(k,"stringify",{enumerable:!0,get:function(){return Nt.stringify}});Object.defineProperty(k,"regexpCode",{enumerable:!0,get:function(){return Nt.regexpCode}});Object.defineProperty(k,"Name",{enumerable:!0,get:function(){return Nt.Name}});var os=wi();Object.defineProperty(k,"Scope",{enumerable:!0,get:function(){return os.Scope}});Object.defineProperty(k,"ValueScope",{enumerable:!0,get:function(){return os.ValueScope}});Object.defineProperty(k,"ValueScopeName",{enumerable:!0,get:function(){return os.ValueScopeName}});Object.defineProperty(k,"varKinds",{enumerable:!0,get:function(){return os.varKinds}});k.operators={GT:new x._Code(">"),GTE:new x._Code(">="),LT:new x._Code("<"),LTE:new x._Code("<="),EQ:new x._Code("==="),NEQ:new x._Code("!=="),NOT:new x._Code("!"),OR:new x._Code("||"),AND:new x._Code("&&"),ADD:new x._Code("+")};var wt=class{optimizeNodes(){return this}optimizeNames(e,r){return this}},bi=class extends wt{constructor(e,r,n){super(),this.varKind=e,this.name=r,this.rhs=n}render({es5:e,_n:r}){let n=e?We.varKinds.var:this.varKind,s=this.rhs===void 0?"":` = ${this.rhs}`;return`${n} ${this.name}${s};`+r}optimizeNames(e,r){if(!!e[this.name.str])return this.rhs&&(this.rhs=wr(this.rhs,e,r)),this}get names(){return this.rhs instanceof x._CodeOrName?this.rhs.names:{}}},ss=class extends wt{constructor(e,r,n){super(),this.lhs=e,this.rhs=r,this.sideEffects=n}render({_n:e}){return`${this.lhs} = ${this.rhs};`+e}optimizeNames(e,r){if(!(this.lhs instanceof x.Name&&!e[this.lhs.str]&&!this.sideEffects))return this.rhs=wr(this.rhs,e,r),this}get names(){let e=this.lhs instanceof x.Name?{}:{...this.lhs.names};return as(e,this.rhs)}},Si=class extends ss{constructor(e,r,n,s){super(e,n,s),this.op=r}render({_n:e}){return`${this.lhs} ${this.op}= ${this.rhs};`+e}},Pi=class extends wt{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){return`${this.label}:`+e}},Oi=class extends wt{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){return`break${this.label?` ${this.label}`:""};`+e}},Ri=class extends wt{constructor(e){super(),this.error=e}render({_n:e}){return`throw ${this.error};`+e}get names(){return this.error.names}},Ni=class extends wt{constructor(e){super(),this.code=e}render({_n:e}){return`${this.code};`+e}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(e,r){return this.code=wr(this.code,e,r),this}get names(){return this.code instanceof x._CodeOrName?this.code.names:{}}},dn=class extends wt{constructor(e=[]){super(),this.nodes=e}render(e){return this.nodes.reduce((r,n)=>r+n.render(e),"")}optimizeNodes(){let{nodes:e}=this,r=e.length;for(;r--;){let n=e[r].optimizeNodes();Array.isArray(n)?e.splice(r,1,...n):n?e[r]=n:e.splice(r,1)}return e.length>0?this:void 0}optimizeNames(e,r){let{nodes:n}=this,s=n.length;for(;s--;){let i=n[s];i.optimizeNames(e,r)||(Jv(e,i.names),n.splice(s,1))}return n.length>0?this:void 0}get names(){return this.nodes.reduce((e,r)=>Bt(e,r.names),{})}},bt=class extends dn{render(e){return"{"+e._n+super.render(e)+"}"+e._n}},Ii=class extends dn{},Er=class extends bt{};Er.kind="else";var Ye=class extends bt{constructor(e,r){super(r),this.condition=e}render(e){let r=`if(${this.condition})`+super.render(e);return this.else&&(r+="else "+this.else.render(e)),r}optimizeNodes(){super.optimizeNodes();let e=this.condition;if(e===!0)return this.nodes;let r=this.else;if(r){let n=r.optimizeNodes();r=this.else=Array.isArray(n)?new Er(n):n}if(r)return e===!1?r instanceof Ye?r:r.nodes:this.nodes.length?this:new Ye(Fu(e),r instanceof Ye?[r]:r.nodes);if(!(e===!1||!this.nodes.length))return this}optimizeNames(e,r){var n;if(this.else=(n=this.else)===null||n===void 0?void 0:n.optimizeNames(e,r),!!(super.optimizeNames(e,r)||this.else))return this.condition=wr(this.condition,e,r),this}get names(){let e=super.names;return as(e,this.condition),this.else&&Bt(e,this.else.names),e}};Ye.kind="if";var Xt=class extends bt{};Xt.kind="for";var Ti=class extends Xt{constructor(e){super(),this.iteration=e}render(e){return`for(${this.iteration})`+super.render(e)}optimizeNames(e,r){if(!!super.optimizeNames(e,r))return this.iteration=wr(this.iteration,e,r),this}get names(){return Bt(super.names,this.iteration.names)}},qi=class extends Xt{constructor(e,r,n,s){super(),this.varKind=e,this.name=r,this.from=n,this.to=s}render(e){let r=e.es5?We.varKinds.var:this.varKind,{name:n,from:s,to:i}=this;return`for(${r} ${n}=${s}; ${n}<${i}; ${n}++)`+super.render(e)}get names(){let e=as(super.names,this.from);return as(e,this.to)}},is=class extends Xt{constructor(e,r,n,s){super(),this.loop=e,this.varKind=r,this.name=n,this.iterable=s}render(e){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(e)}optimizeNames(e,r){if(!!super.optimizeNames(e,r))return this.iterable=wr(this.iterable,e,r),this}get names(){return Bt(super.names,this.iterable.names)}},hn=class extends bt{constructor(e,r,n){super(),this.name=e,this.args=r,this.async=n}render(e){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(e)}};hn.kind="func";var pn=class extends dn{render(e){return"return "+super.render(e)}};pn.kind="return";var Ci=class extends bt{render(e){let r="try"+super.render(e);return this.catch&&(r+=this.catch.render(e)),this.finally&&(r+=this.finally.render(e)),r}optimizeNodes(){var e,r;return super.optimizeNodes(),(e=this.catch)===null||e===void 0||e.optimizeNodes(),(r=this.finally)===null||r===void 0||r.optimizeNodes(),this}optimizeNames(e,r){var n,s;return super.optimizeNames(e,r),(n=this.catch)===null||n===void 0||n.optimizeNames(e,r),(s=this.finally)===null||s===void 0||s.optimizeNames(e,r),this}get names(){let e=super.names;return this.catch&&Bt(e,this.catch.names),this.finally&&Bt(e,this.finally.names),e}},mn=class extends bt{constructor(e){super(),this.error=e}render(e){return`catch(${this.error})`+super.render(e)}};mn.kind="catch";var vn=class extends bt{render(e){return"finally"+super.render(e)}};vn.kind="finally";var ji=class{constructor(e,r={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...r,_n:r.lines?`
|
|
8
|
+
`:""},this._extScope=e,this._scope=new We.Scope({parent:e}),this._nodes=[new Ii]}toString(){return this._root.render(this.opts)}name(e){return this._scope.name(e)}scopeName(e){return this._extScope.name(e)}scopeValue(e,r){let n=this._extScope.value(e,r);return(this._values[n.prefix]||(this._values[n.prefix]=new Set)).add(n),n}getScopeValue(e,r){return this._extScope.getValue(e,r)}scopeRefs(e){return this._extScope.scopeRefs(e,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(e,r,n,s){let i=this._scope.toName(r);return n!==void 0&&s&&(this._constants[i.str]=n),this._leafNode(new bi(e,i,n)),i}const(e,r,n){return this._def(We.varKinds.const,e,r,n)}let(e,r,n){return this._def(We.varKinds.let,e,r,n)}var(e,r,n){return this._def(We.varKinds.var,e,r,n)}assign(e,r,n){return this._leafNode(new ss(e,r,n))}add(e,r){return this._leafNode(new Si(e,k.operators.ADD,r))}code(e){return typeof e=="function"?e():e!==x.nil&&this._leafNode(new Ni(e)),this}object(...e){let r=["{"];for(let[n,s]of e)r.length>1&&r.push(","),r.push(n),(n!==s||this.opts.es5)&&(r.push(":"),(0,x.addCodeArg)(r,s));return r.push("}"),new x._Code(r)}if(e,r,n){if(this._blockNode(new Ye(e)),r&&n)this.code(r).else().code(n).endIf();else if(r)this.code(r).endIf();else if(n)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(e){return this._elseNode(new Ye(e))}else(){return this._elseNode(new Er)}endIf(){return this._endBlockNode(Ye,Er)}_for(e,r){return this._blockNode(e),r&&this.code(r).endFor(),this}for(e,r){return this._for(new Ti(e),r)}forRange(e,r,n,s,i=this.opts.es5?We.varKinds.var:We.varKinds.let){let a=this._scope.toName(e);return this._for(new qi(i,a,r,n),()=>s(a))}forOf(e,r,n,s=We.varKinds.const){let i=this._scope.toName(e);if(this.opts.es5){let a=r instanceof x.Name?r:this.var("_arr",r);return this.forRange("_i",0,(0,x._)`${a}.length`,c=>{this.var(i,(0,x._)`${a}[${c}]`),n(i)})}return this._for(new is("of",s,i,r),()=>n(i))}forIn(e,r,n,s=this.opts.es5?We.varKinds.var:We.varKinds.const){if(this.opts.ownProperties)return this.forOf(e,(0,x._)`Object.keys(${r})`,n);let i=this._scope.toName(e);return this._for(new is("in",s,i,r),()=>n(i))}endFor(){return this._endBlockNode(Xt)}label(e){return this._leafNode(new Pi(e))}break(e){return this._leafNode(new Oi(e))}return(e){let r=new pn;if(this._blockNode(r),this.code(e),r.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(pn)}try(e,r,n){if(!r&&!n)throw new Error('CodeGen: "try" without "catch" and "finally"');let s=new Ci;if(this._blockNode(s),this.code(e),r){let i=this.name("e");this._currNode=s.catch=new mn(i),r(i)}return n&&(this._currNode=s.finally=new vn,this.code(n)),this._endBlockNode(mn,vn)}throw(e){return this._leafNode(new Ri(e))}block(e,r){return this._blockStarts.push(this._nodes.length),e&&this.code(e).endBlock(r),this}endBlock(e){let r=this._blockStarts.pop();if(r===void 0)throw new Error("CodeGen: not in self-balancing block");let n=this._nodes.length-r;if(n<0||e!==void 0&&n!==e)throw new Error(`CodeGen: wrong number of nodes: ${n} vs ${e} expected`);return this._nodes.length=r,this}func(e,r=x.nil,n,s){return this._blockNode(new hn(e,r,n)),s&&this.code(s).endFunc(),this}endFunc(){return this._endBlockNode(hn)}optimize(e=1){for(;e-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(e){return this._currNode.nodes.push(e),this}_blockNode(e){this._currNode.nodes.push(e),this._nodes.push(e)}_endBlockNode(e,r){let n=this._currNode;if(n instanceof e||r&&n instanceof r)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${r?`${e.kind}/${r.kind}`:e.kind}"`)}_elseNode(e){let r=this._currNode;if(!(r instanceof Ye))throw new Error('CodeGen: "else" without "if"');return this._currNode=r.else=e,this}get _root(){return this._nodes[0]}get _currNode(){let e=this._nodes;return e[e.length-1]}set _currNode(e){let r=this._nodes;r[r.length-1]=e}};k.CodeGen=ji;function Bt(t,e){for(let r in e)t[r]=(t[r]||0)+(e[r]||0);return t}function as(t,e){return e instanceof x._CodeOrName?Bt(t,e.names):t}function wr(t,e,r){if(t instanceof x.Name)return n(t);if(!s(t))return t;return new x._Code(t._items.reduce((i,a)=>(a instanceof x.Name&&(a=n(a)),a instanceof x._Code?i.push(...a._items):i.push(a),i),[]));function n(i){let a=r[i.str];return a===void 0||e[i.str]!==1?i:(delete e[i.str],a)}function s(i){return i instanceof x._Code&&i._items.some(a=>a instanceof x.Name&&e[a.str]===1&&r[a.str]!==void 0)}}function Jv(t,e){for(let r in e)t[r]=(t[r]||0)-(e[r]||0)}function Fu(t){return typeof t=="boolean"||typeof t=="number"||t===null?!t:(0,x._)`!${Di(t)}`}k.not=Fu;var Zv=Vu(k.operators.AND);function Qv(...t){return t.reduce(Zv)}k.and=Qv;var eg=Vu(k.operators.OR);function tg(...t){return t.reduce(eg)}k.or=tg;function Vu(t){return(e,r)=>e===x.nil?r:r===x.nil?e:(0,x._)`${Di(e)} ${t} ${Di(r)}`}function Di(t){return t instanceof x.Name?t:(0,x._)`(${t})`}});var H=y(L=>{"use strict";Object.defineProperty(L,"__esModule",{value:!0});L.checkStrictMode=L.getErrorPath=L.Type=L.useFunc=L.setEvaluated=L.evaluatedPropsToName=L.mergeEvaluated=L.eachItem=L.unescapeJsonPointer=L.escapeJsonPointer=L.escapeFragment=L.unescapeFragment=L.schemaRefOrVal=L.schemaHasRulesButRef=L.schemaHasRules=L.checkUnknownRules=L.alwaysValidSchema=L.toHash=void 0;var Z=M(),rg=fn();function ng(t){let e={};for(let r of t)e[r]=!0;return e}L.toHash=ng;function sg(t,e){return typeof e=="boolean"?e:Object.keys(e).length===0?!0:(Hu(t,e),!zu(e,t.self.RULES.all))}L.alwaysValidSchema=sg;function Hu(t,e=t.schema){let{opts:r,self:n}=t;if(!r.strictSchema||typeof e=="boolean")return;let s=n.RULES.keywords;for(let i in e)s[i]||Wu(t,`unknown keyword: "${i}"`)}L.checkUnknownRules=Hu;function zu(t,e){if(typeof t=="boolean")return!t;for(let r in t)if(e[r])return!0;return!1}L.schemaHasRules=zu;function ig(t,e){if(typeof t=="boolean")return!t;for(let r in t)if(r!=="$ref"&&e.all[r])return!0;return!1}L.schemaHasRulesButRef=ig;function ag({topSchemaRef:t,schemaPath:e},r,n,s){if(!s){if(typeof r=="number"||typeof r=="boolean")return r;if(typeof r=="string")return(0,Z._)`${r}`}return(0,Z._)`${t}${e}${(0,Z.getProperty)(n)}`}L.schemaRefOrVal=ag;function og(t){return Ku(decodeURIComponent(t))}L.unescapeFragment=og;function cg(t){return encodeURIComponent(Ai(t))}L.escapeFragment=cg;function Ai(t){return typeof t=="number"?`${t}`:t.replace(/~/g,"~0").replace(/\//g,"~1")}L.escapeJsonPointer=Ai;function Ku(t){return t.replace(/~1/g,"/").replace(/~0/g,"~")}L.unescapeJsonPointer=Ku;function ug(t,e){if(Array.isArray(t))for(let r of t)e(r);else e(t)}L.eachItem=ug;function Uu({mergeNames:t,mergeToName:e,mergeValues:r,resultToName:n}){return(s,i,a,c)=>{let l=a===void 0?i:a instanceof Z.Name?(i instanceof Z.Name?t(s,i,a):e(s,i,a),a):i instanceof Z.Name?(e(s,a,i),i):r(i,a);return c===Z.Name&&!(l instanceof Z.Name)?n(s,l):l}}L.mergeEvaluated={props:Uu({mergeNames:(t,e,r)=>t.if((0,Z._)`${r} !== true && ${e} !== undefined`,()=>{t.if((0,Z._)`${e} === true`,()=>t.assign(r,!0),()=>t.assign(r,(0,Z._)`${r} || {}`).code((0,Z._)`Object.assign(${r}, ${e})`))}),mergeToName:(t,e,r)=>t.if((0,Z._)`${r} !== true`,()=>{e===!0?t.assign(r,!0):(t.assign(r,(0,Z._)`${r} || {}`),ki(t,r,e))}),mergeValues:(t,e)=>t===!0?!0:{...t,...e},resultToName:Xu}),items:Uu({mergeNames:(t,e,r)=>t.if((0,Z._)`${r} !== true && ${e} !== undefined`,()=>t.assign(r,(0,Z._)`${e} === true ? true : ${r} > ${e} ? ${r} : ${e}`)),mergeToName:(t,e,r)=>t.if((0,Z._)`${r} !== true`,()=>t.assign(r,e===!0?!0:(0,Z._)`${r} > ${e} ? ${r} : ${e}`)),mergeValues:(t,e)=>t===!0?!0:Math.max(t,e),resultToName:(t,e)=>t.var("items",e)})};function Xu(t,e){if(e===!0)return t.var("props",!0);let r=t.var("props",(0,Z._)`{}`);return e!==void 0&&ki(t,r,e),r}L.evaluatedPropsToName=Xu;function ki(t,e,r){Object.keys(r).forEach(n=>t.assign((0,Z._)`${e}${(0,Z.getProperty)(n)}`,!0))}L.setEvaluated=ki;var Gu={};function lg(t,e){return t.scopeValue("func",{ref:e,code:Gu[e.code]||(Gu[e.code]=new rg._Code(e.code))})}L.useFunc=lg;var Bu;(function(t){t[t.Num=0]="Num",t[t.Str=1]="Str"})(Bu=L.Type||(L.Type={}));function fg(t,e,r){if(t instanceof Z.Name){let n=e===Bu.Num;return r?n?(0,Z._)`"[" + ${t} + "]"`:(0,Z._)`"['" + ${t} + "']"`:n?(0,Z._)`"/" + ${t}`:(0,Z._)`"/" + ${t}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return r?(0,Z.getProperty)(t).toString():"/"+Ai(t)}L.getErrorPath=fg;function Wu(t,e,r=t.opts.strictSchema){if(!!r){if(e=`strict mode: ${e}`,r===!0)throw new Error(e);t.self.logger.warn(e)}}L.checkStrictMode=Wu});var St=y(Li=>{"use strict";Object.defineProperty(Li,"__esModule",{value:!0});var ye=M(),dg={data:new ye.Name("data"),valCxt:new ye.Name("valCxt"),instancePath:new ye.Name("instancePath"),parentData:new ye.Name("parentData"),parentDataProperty:new ye.Name("parentDataProperty"),rootData:new ye.Name("rootData"),dynamicAnchors:new ye.Name("dynamicAnchors"),vErrors:new ye.Name("vErrors"),errors:new ye.Name("errors"),this:new ye.Name("this"),self:new ye.Name("self"),scope:new ye.Name("scope"),json:new ye.Name("json"),jsonPos:new ye.Name("jsonPos"),jsonLen:new ye.Name("jsonLen"),jsonPart:new ye.Name("jsonPart")};Li.default=dg});var gn=y(_e=>{"use strict";Object.defineProperty(_e,"__esModule",{value:!0});_e.extendErrors=_e.resetErrorsCount=_e.reportExtraError=_e.reportError=_e.keyword$DataError=_e.keywordError=void 0;var V=M(),cs=H(),Se=St();_e.keywordError={message:({keyword:t})=>(0,V.str)`must pass "${t}" keyword validation`};_e.keyword$DataError={message:({keyword:t,schemaType:e})=>e?(0,V.str)`"${t}" keyword must be ${e} ($data)`:(0,V.str)`"${t}" keyword is invalid ($data)`};function hg(t,e=_e.keywordError,r,n){let{it:s}=t,{gen:i,compositeRule:a,allErrors:c}=s,l=Zu(t,e,r);(n!=null?n:a||c)?Yu(i,l):Ju(s,(0,V._)`[${l}]`)}_e.reportError=hg;function pg(t,e=_e.keywordError,r){let{it:n}=t,{gen:s,compositeRule:i,allErrors:a}=n,c=Zu(t,e,r);Yu(s,c),i||a||Ju(n,Se.default.vErrors)}_e.reportExtraError=pg;function mg(t,e){t.assign(Se.default.errors,e),t.if((0,V._)`${Se.default.vErrors} !== null`,()=>t.if(e,()=>t.assign((0,V._)`${Se.default.vErrors}.length`,e),()=>t.assign(Se.default.vErrors,null)))}_e.resetErrorsCount=mg;function vg({gen:t,keyword:e,schemaValue:r,data:n,errsCount:s,it:i}){if(s===void 0)throw new Error("ajv implementation error");let a=t.name("err");t.forRange("i",s,Se.default.errors,c=>{t.const(a,(0,V._)`${Se.default.vErrors}[${c}]`),t.if((0,V._)`${a}.instancePath === undefined`,()=>t.assign((0,V._)`${a}.instancePath`,(0,V.strConcat)(Se.default.instancePath,i.errorPath))),t.assign((0,V._)`${a}.schemaPath`,(0,V.str)`${i.errSchemaPath}/${e}`),i.opts.verbose&&(t.assign((0,V._)`${a}.schema`,r),t.assign((0,V._)`${a}.data`,n))})}_e.extendErrors=vg;function Yu(t,e){let r=t.const("err",e);t.if((0,V._)`${Se.default.vErrors} === null`,()=>t.assign(Se.default.vErrors,(0,V._)`[${r}]`),(0,V._)`${Se.default.vErrors}.push(${r})`),t.code((0,V._)`${Se.default.errors}++`)}function Ju(t,e){let{gen:r,validateName:n,schemaEnv:s}=t;s.$async?r.throw((0,V._)`new ${t.ValidationError}(${e})`):(r.assign((0,V._)`${n}.errors`,e),r.return(!1))}var Wt={keyword:new V.Name("keyword"),schemaPath:new V.Name("schemaPath"),params:new V.Name("params"),propertyName:new V.Name("propertyName"),message:new V.Name("message"),schema:new V.Name("schema"),parentSchema:new V.Name("parentSchema")};function Zu(t,e,r){let{createErrors:n}=t.it;return n===!1?(0,V._)`{}`:gg(t,e,r)}function gg(t,e,r={}){let{gen:n,it:s}=t,i=[yg(s,r),_g(t,r)];return $g(t,e,i),n.object(...i)}function yg({errorPath:t},{instancePath:e}){let r=e?(0,V.str)`${t}${(0,cs.getErrorPath)(e,cs.Type.Str)}`:t;return[Se.default.instancePath,(0,V.strConcat)(Se.default.instancePath,r)]}function _g({keyword:t,it:{errSchemaPath:e}},{schemaPath:r,parentSchema:n}){let s=n?e:(0,V.str)`${e}/${t}`;return r&&(s=(0,V.str)`${s}${(0,cs.getErrorPath)(r,cs.Type.Str)}`),[Wt.schemaPath,s]}function $g(t,{params:e,message:r},n){let{keyword:s,data:i,schemaValue:a,it:c}=t,{opts:l,propertyName:o,topSchemaRef:f,schemaPath:h}=c;n.push([Wt.keyword,s],[Wt.params,typeof e=="function"?e(t):e||(0,V._)`{}`]),l.messages&&n.push([Wt.message,typeof r=="function"?r(t):r]),l.verbose&&n.push([Wt.schema,a],[Wt.parentSchema,(0,V._)`${f}${h}`],[Se.default.data,i]),o&&n.push([Wt.propertyName,o])}});var el=y(br=>{"use strict";Object.defineProperty(br,"__esModule",{value:!0});br.boolOrEmptySchema=br.topBoolOrEmptySchema=void 0;var Eg=gn(),wg=M(),bg=St(),Sg={message:"boolean schema is false"};function Pg(t){let{gen:e,schema:r,validateName:n}=t;r===!1?Qu(t,!1):typeof r=="object"&&r.$async===!0?e.return(bg.default.data):(e.assign((0,wg._)`${n}.errors`,null),e.return(!0))}br.topBoolOrEmptySchema=Pg;function Og(t,e){let{gen:r,schema:n}=t;n===!1?(r.var(e,!1),Qu(t)):r.var(e,!0)}br.boolOrEmptySchema=Og;function Qu(t,e){let{gen:r,data:n}=t,s={gen:r,keyword:"false schema",data:n,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:t};(0,Eg.reportError)(s,Sg,void 0,e)}});var Mi=y(Sr=>{"use strict";Object.defineProperty(Sr,"__esModule",{value:!0});Sr.getRules=Sr.isJSONType=void 0;var Rg=["string","number","integer","boolean","null","object","array"],Ng=new Set(Rg);function Ig(t){return typeof t=="string"&&Ng.has(t)}Sr.isJSONType=Ig;function Tg(){let t={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...t,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},t.number,t.string,t.array,t.object],post:{rules:[]},all:{},keywords:{}}}Sr.getRules=Tg});var xi=y(It=>{"use strict";Object.defineProperty(It,"__esModule",{value:!0});It.shouldUseRule=It.shouldUseGroup=It.schemaHasRulesForType=void 0;function qg({schema:t,self:e},r){let n=e.RULES.types[r];return n&&n!==!0&&tl(t,n)}It.schemaHasRulesForType=qg;function tl(t,e){return e.rules.some(r=>rl(t,r))}It.shouldUseGroup=tl;function rl(t,e){var r;return t[e.keyword]!==void 0||((r=e.definition.implements)===null||r===void 0?void 0:r.some(n=>t[n]!==void 0))}It.shouldUseRule=rl});var _n=y(de=>{"use strict";Object.defineProperty(de,"__esModule",{value:!0});de.reportTypeError=de.checkDataTypes=de.checkDataType=de.coerceAndCheckDataType=de.getJSONTypes=de.getSchemaTypes=de.DataType=void 0;var Cg=Mi(),jg=xi(),Dg=gn(),D=M(),nl=H(),yn;(function(t){t[t.Correct=0]="Correct",t[t.Wrong=1]="Wrong"})(yn=de.DataType||(de.DataType={}));function Ag(t){let e=sl(t.type);if(e.includes("null")){if(t.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!e.length&&t.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');t.nullable===!0&&e.push("null")}return e}de.getSchemaTypes=Ag;function sl(t){let e=Array.isArray(t)?t:t?[t]:[];if(e.every(Cg.isJSONType))return e;throw new Error("type must be JSONType or JSONType[]: "+e.join(","))}de.getJSONTypes=sl;function kg(t,e){let{gen:r,data:n,opts:s}=t,i=Lg(e,s.coerceTypes),a=e.length>0&&!(i.length===0&&e.length===1&&(0,jg.schemaHasRulesForType)(t,e[0]));if(a){let c=Vi(e,n,s.strictNumbers,yn.Wrong);r.if(c,()=>{i.length?Mg(t,e,i):Ui(t)})}return a}de.coerceAndCheckDataType=kg;var il=new Set(["string","number","integer","boolean","null"]);function Lg(t,e){return e?t.filter(r=>il.has(r)||e==="array"&&r==="array"):[]}function Mg(t,e,r){let{gen:n,data:s,opts:i}=t,a=n.let("dataType",(0,D._)`typeof ${s}`),c=n.let("coerced",(0,D._)`undefined`);i.coerceTypes==="array"&&n.if((0,D._)`${a} == 'object' && Array.isArray(${s}) && ${s}.length == 1`,()=>n.assign(s,(0,D._)`${s}[0]`).assign(a,(0,D._)`typeof ${s}`).if(Vi(e,s,i.strictNumbers),()=>n.assign(c,s))),n.if((0,D._)`${c} !== undefined`);for(let o of r)(il.has(o)||o==="array"&&i.coerceTypes==="array")&&l(o);n.else(),Ui(t),n.endIf(),n.if((0,D._)`${c} !== undefined`,()=>{n.assign(s,c),xg(t,c)});function l(o){switch(o){case"string":n.elseIf((0,D._)`${a} == "number" || ${a} == "boolean"`).assign(c,(0,D._)`"" + ${s}`).elseIf((0,D._)`${s} === null`).assign(c,(0,D._)`""`);return;case"number":n.elseIf((0,D._)`${a} == "boolean" || ${s} === null
|
|
9
|
+
|| (${a} == "string" && ${s} && ${s} == +${s})`).assign(c,(0,D._)`+${s}`);return;case"integer":n.elseIf((0,D._)`${a} === "boolean" || ${s} === null
|
|
10
|
+
|| (${a} === "string" && ${s} && ${s} == +${s} && !(${s} % 1))`).assign(c,(0,D._)`+${s}`);return;case"boolean":n.elseIf((0,D._)`${s} === "false" || ${s} === 0 || ${s} === null`).assign(c,!1).elseIf((0,D._)`${s} === "true" || ${s} === 1`).assign(c,!0);return;case"null":n.elseIf((0,D._)`${s} === "" || ${s} === 0 || ${s} === false`),n.assign(c,null);return;case"array":n.elseIf((0,D._)`${a} === "string" || ${a} === "number"
|
|
11
|
+
|| ${a} === "boolean" || ${s} === null`).assign(c,(0,D._)`[${s}]`)}}}function xg({gen:t,parentData:e,parentDataProperty:r},n){t.if((0,D._)`${e} !== undefined`,()=>t.assign((0,D._)`${e}[${r}]`,n))}function Fi(t,e,r,n=yn.Correct){let s=n===yn.Correct?D.operators.EQ:D.operators.NEQ,i;switch(t){case"null":return(0,D._)`${e} ${s} null`;case"array":i=(0,D._)`Array.isArray(${e})`;break;case"object":i=(0,D._)`${e} && typeof ${e} == "object" && !Array.isArray(${e})`;break;case"integer":i=a((0,D._)`!(${e} % 1) && !isNaN(${e})`);break;case"number":i=a();break;default:return(0,D._)`typeof ${e} ${s} ${t}`}return n===yn.Correct?i:(0,D.not)(i);function a(c=D.nil){return(0,D.and)((0,D._)`typeof ${e} == "number"`,c,r?(0,D._)`isFinite(${e})`:D.nil)}}de.checkDataType=Fi;function Vi(t,e,r,n){if(t.length===1)return Fi(t[0],e,r,n);let s,i=(0,nl.toHash)(t);if(i.array&&i.object){let a=(0,D._)`typeof ${e} != "object"`;s=i.null?a:(0,D._)`!${e} || ${a}`,delete i.null,delete i.array,delete i.object}else s=D.nil;i.number&&delete i.integer;for(let a in i)s=(0,D.and)(s,Fi(a,e,r,n));return s}de.checkDataTypes=Vi;var Fg={message:({schema:t})=>`must be ${t}`,params:({schema:t,schemaValue:e})=>typeof t=="string"?(0,D._)`{type: ${t}}`:(0,D._)`{type: ${e}}`};function Ui(t){let e=Vg(t);(0,Dg.reportError)(e,Fg)}de.reportTypeError=Ui;function Vg(t){let{gen:e,data:r,schema:n}=t,s=(0,nl.schemaRefOrVal)(t,n,"type");return{gen:e,keyword:"type",data:r,schema:n.type,schemaCode:s,schemaValue:s,parentSchema:n,params:{},it:t}}});var ol=y(us=>{"use strict";Object.defineProperty(us,"__esModule",{value:!0});us.assignDefaults=void 0;var Pr=M(),Ug=H();function Gg(t,e){let{properties:r,items:n}=t.schema;if(e==="object"&&r)for(let s in r)al(t,s,r[s].default);else e==="array"&&Array.isArray(n)&&n.forEach((s,i)=>al(t,i,s.default))}us.assignDefaults=Gg;function al(t,e,r){let{gen:n,compositeRule:s,data:i,opts:a}=t;if(r===void 0)return;let c=(0,Pr._)`${i}${(0,Pr.getProperty)(e)}`;if(s){(0,Ug.checkStrictMode)(t,`default is ignored for: ${c}`);return}let l=(0,Pr._)`${c} === undefined`;a.useDefaults==="empty"&&(l=(0,Pr._)`${l} || ${c} === null || ${c} === ""`),n.if(l,(0,Pr._)`${c} = ${(0,Pr.stringify)(r)}`)}});var Ge=y(Y=>{"use strict";Object.defineProperty(Y,"__esModule",{value:!0});Y.validateUnion=Y.validateArray=Y.usePattern=Y.callValidateCode=Y.schemaProperties=Y.allSchemaProperties=Y.noPropertyInData=Y.propertyInData=Y.isOwnProperty=Y.hasPropFunc=Y.reportMissingProp=Y.checkMissingProp=Y.checkReportMissingProp=void 0;var te=M(),Gi=H(),Tt=St(),Hg=H();function zg(t,e){let{gen:r,data:n,it:s}=t;r.if(zi(r,n,e,s.opts.ownProperties),()=>{t.setParams({missingProperty:(0,te._)`${e}`},!0),t.error()})}Y.checkReportMissingProp=zg;function Kg({gen:t,data:e,it:{opts:r}},n,s){return(0,te.or)(...n.map(i=>(0,te.and)(zi(t,e,i,r.ownProperties),(0,te._)`${s} = ${i}`)))}Y.checkMissingProp=Kg;function Xg(t,e){t.setParams({missingProperty:e},!0),t.error()}Y.reportMissingProp=Xg;function cl(t){return t.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,te._)`Object.prototype.hasOwnProperty`})}Y.hasPropFunc=cl;function Hi(t,e,r){return(0,te._)`${cl(t)}.call(${e}, ${r})`}Y.isOwnProperty=Hi;function Bg(t,e,r,n){let s=(0,te._)`${e}${(0,te.getProperty)(r)} !== undefined`;return n?(0,te._)`${s} && ${Hi(t,e,r)}`:s}Y.propertyInData=Bg;function zi(t,e,r,n){let s=(0,te._)`${e}${(0,te.getProperty)(r)} === undefined`;return n?(0,te.or)(s,(0,te.not)(Hi(t,e,r))):s}Y.noPropertyInData=zi;function ul(t){return t?Object.keys(t).filter(e=>e!=="__proto__"):[]}Y.allSchemaProperties=ul;function Wg(t,e){return ul(e).filter(r=>!(0,Gi.alwaysValidSchema)(t,e[r]))}Y.schemaProperties=Wg;function Yg({schemaCode:t,data:e,it:{gen:r,topSchemaRef:n,schemaPath:s,errorPath:i},it:a},c,l,o){let f=o?(0,te._)`${t}, ${e}, ${n}${s}`:e,h=[[Tt.default.instancePath,(0,te.strConcat)(Tt.default.instancePath,i)],[Tt.default.parentData,a.parentData],[Tt.default.parentDataProperty,a.parentDataProperty],[Tt.default.rootData,Tt.default.rootData]];a.opts.dynamicRef&&h.push([Tt.default.dynamicAnchors,Tt.default.dynamicAnchors]);let _=(0,te._)`${f}, ${r.object(...h)}`;return l!==te.nil?(0,te._)`${c}.call(${l}, ${_})`:(0,te._)`${c}(${_})`}Y.callValidateCode=Yg;var Jg=(0,te._)`new RegExp`;function Zg({gen:t,it:{opts:e}},r){let n=e.unicodeRegExp?"u":"",{regExp:s}=e.code,i=s(r,n);return t.scopeValue("pattern",{key:i.toString(),ref:i,code:(0,te._)`${s.code==="new RegExp"?Jg:(0,Hg.useFunc)(t,s)}(${r}, ${n})`})}Y.usePattern=Zg;function Qg(t){let{gen:e,data:r,keyword:n,it:s}=t,i=e.name("valid");if(s.allErrors){let c=e.let("valid",!0);return a(()=>e.assign(c,!1)),c}return e.var(i,!0),a(()=>e.break()),i;function a(c){let l=e.const("len",(0,te._)`${r}.length`);e.forRange("i",0,l,o=>{t.subschema({keyword:n,dataProp:o,dataPropType:Gi.Type.Num},i),e.if((0,te.not)(i),c)})}}Y.validateArray=Qg;function ey(t){let{gen:e,schema:r,keyword:n,it:s}=t;if(!Array.isArray(r))throw new Error("ajv implementation error");if(r.some(l=>(0,Gi.alwaysValidSchema)(s,l))&&!s.opts.unevaluated)return;let a=e.let("valid",!1),c=e.name("_valid");e.block(()=>r.forEach((l,o)=>{let f=t.subschema({keyword:n,schemaProp:o,compositeRule:!0},c);e.assign(a,(0,te._)`${a} || ${c}`),t.mergeValidEvaluated(f,c)||e.if((0,te.not)(a))})),t.result(a,()=>t.reset(),()=>t.error(!0))}Y.validateUnion=ey});var dl=y(ot=>{"use strict";Object.defineProperty(ot,"__esModule",{value:!0});ot.validateKeywordUsage=ot.validSchemaType=ot.funcKeywordCode=ot.macroKeywordCode=void 0;var Pe=M(),Yt=St(),ty=Ge(),ry=gn();function ny(t,e){let{gen:r,keyword:n,schema:s,parentSchema:i,it:a}=t,c=e.macro.call(a.self,s,i,a),l=fl(r,n,c);a.opts.validateSchema!==!1&&a.self.validateSchema(c,!0);let o=r.name("valid");t.subschema({schema:c,schemaPath:Pe.nil,errSchemaPath:`${a.errSchemaPath}/${n}`,topSchemaRef:l,compositeRule:!0},o),t.pass(o,()=>t.error(!0))}ot.macroKeywordCode=ny;function sy(t,e){var r;let{gen:n,keyword:s,schema:i,parentSchema:a,$data:c,it:l}=t;ay(l,e);let o=!c&&e.compile?e.compile.call(l.self,i,a,l):e.validate,f=fl(n,s,o),h=n.let("valid");t.block$data(h,_),t.ok((r=e.valid)!==null&&r!==void 0?r:h);function _(){if(e.errors===!1)$(),e.modifying&&ll(t),w(()=>t.error());else{let b=e.async?v():E();e.modifying&&ll(t),w(()=>iy(t,b))}}function v(){let b=n.let("ruleErrs",null);return n.try(()=>$((0,Pe._)`await `),C=>n.assign(h,!1).if((0,Pe._)`${C} instanceof ${l.ValidationError}`,()=>n.assign(b,(0,Pe._)`${C}.errors`),()=>n.throw(C))),b}function E(){let b=(0,Pe._)`${f}.errors`;return n.assign(b,null),$(Pe.nil),b}function $(b=e.async?(0,Pe._)`await `:Pe.nil){let C=l.opts.passContext?Yt.default.this:Yt.default.self,q=!("compile"in e&&!c||e.schema===!1);n.assign(h,(0,Pe._)`${b}${(0,ty.callValidateCode)(t,f,C,q)}`,e.modifying)}function w(b){var C;n.if((0,Pe.not)((C=e.valid)!==null&&C!==void 0?C:h),b)}}ot.funcKeywordCode=sy;function ll(t){let{gen:e,data:r,it:n}=t;e.if(n.parentData,()=>e.assign(r,(0,Pe._)`${n.parentData}[${n.parentDataProperty}]`))}function iy(t,e){let{gen:r}=t;r.if((0,Pe._)`Array.isArray(${e})`,()=>{r.assign(Yt.default.vErrors,(0,Pe._)`${Yt.default.vErrors} === null ? ${e} : ${Yt.default.vErrors}.concat(${e})`).assign(Yt.default.errors,(0,Pe._)`${Yt.default.vErrors}.length`),(0,ry.extendErrors)(t)},()=>t.error())}function ay({schemaEnv:t},e){if(e.async&&!t.$async)throw new Error("async keyword in sync schema")}function fl(t,e,r){if(r===void 0)throw new Error(`keyword "${e}" failed to compile`);return t.scopeValue("keyword",typeof r=="function"?{ref:r}:{ref:r,code:(0,Pe.stringify)(r)})}function oy(t,e,r=!1){return!e.length||e.some(n=>n==="array"?Array.isArray(t):n==="object"?t&&typeof t=="object"&&!Array.isArray(t):typeof t==n||r&&typeof t>"u")}ot.validSchemaType=oy;function cy({schema:t,opts:e,self:r,errSchemaPath:n},s,i){if(Array.isArray(s.keyword)?!s.keyword.includes(i):s.keyword!==i)throw new Error("ajv implementation error");let a=s.dependencies;if(a!=null&&a.some(c=>!Object.prototype.hasOwnProperty.call(t,c)))throw new Error(`parent schema must have dependencies of ${i}: ${a.join(",")}`);if(s.validateSchema&&!s.validateSchema(t[i])){let l=`keyword "${i}" value is invalid at path "${n}": `+r.errorsText(s.validateSchema.errors);if(e.validateSchema==="log")r.logger.error(l);else throw new Error(l)}}ot.validateKeywordUsage=cy});var pl=y(qt=>{"use strict";Object.defineProperty(qt,"__esModule",{value:!0});qt.extendSubschemaMode=qt.extendSubschemaData=qt.getSubschema=void 0;var ct=M(),hl=H();function uy(t,{keyword:e,schemaProp:r,schema:n,schemaPath:s,errSchemaPath:i,topSchemaRef:a}){if(e!==void 0&&n!==void 0)throw new Error('both "keyword" and "schema" passed, only one allowed');if(e!==void 0){let c=t.schema[e];return r===void 0?{schema:c,schemaPath:(0,ct._)`${t.schemaPath}${(0,ct.getProperty)(e)}`,errSchemaPath:`${t.errSchemaPath}/${e}`}:{schema:c[r],schemaPath:(0,ct._)`${t.schemaPath}${(0,ct.getProperty)(e)}${(0,ct.getProperty)(r)}`,errSchemaPath:`${t.errSchemaPath}/${e}/${(0,hl.escapeFragment)(r)}`}}if(n!==void 0){if(s===void 0||i===void 0||a===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:n,schemaPath:s,topSchemaRef:a,errSchemaPath:i}}throw new Error('either "keyword" or "schema" must be passed')}qt.getSubschema=uy;function ly(t,e,{dataProp:r,dataPropType:n,data:s,dataTypes:i,propertyName:a}){if(s!==void 0&&r!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');let{gen:c}=e;if(r!==void 0){let{errorPath:o,dataPathArr:f,opts:h}=e,_=c.let("data",(0,ct._)`${e.data}${(0,ct.getProperty)(r)}`,!0);l(_),t.errorPath=(0,ct.str)`${o}${(0,hl.getErrorPath)(r,n,h.jsPropertySyntax)}`,t.parentDataProperty=(0,ct._)`${r}`,t.dataPathArr=[...f,t.parentDataProperty]}if(s!==void 0){let o=s instanceof ct.Name?s:c.let("data",s,!0);l(o),a!==void 0&&(t.propertyName=a)}i&&(t.dataTypes=i);function l(o){t.data=o,t.dataLevel=e.dataLevel+1,t.dataTypes=[],e.definedProperties=new Set,t.parentData=e.data,t.dataNames=[...e.dataNames,o]}}qt.extendSubschemaData=ly;function fy(t,{jtdDiscriminator:e,jtdMetadata:r,compositeRule:n,createErrors:s,allErrors:i}){n!==void 0&&(t.compositeRule=n),s!==void 0&&(t.createErrors=s),i!==void 0&&(t.allErrors=i),t.jtdDiscriminator=e,t.jtdMetadata=r}qt.extendSubschemaMode=fy});var Ki=y((hb,ml)=>{"use strict";ml.exports=function t(e,r){if(e===r)return!0;if(e&&r&&typeof e=="object"&&typeof r=="object"){if(e.constructor!==r.constructor)return!1;var n,s,i;if(Array.isArray(e)){if(n=e.length,n!=r.length)return!1;for(s=n;s--!==0;)if(!t(e[s],r[s]))return!1;return!0}if(e.constructor===RegExp)return e.source===r.source&&e.flags===r.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===r.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===r.toString();if(i=Object.keys(e),n=i.length,n!==Object.keys(r).length)return!1;for(s=n;s--!==0;)if(!Object.prototype.hasOwnProperty.call(r,i[s]))return!1;for(s=n;s--!==0;){var a=i[s];if(!t(e[a],r[a]))return!1}return!0}return e!==e&&r!==r}});var gl=y((pb,vl)=>{"use strict";var Ct=vl.exports=function(t,e,r){typeof e=="function"&&(r=e,e={}),r=e.cb||r;var n=typeof r=="function"?r:r.pre||function(){},s=r.post||function(){};ls(e,n,s,t,"",t)};Ct.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};Ct.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};Ct.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};Ct.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function ls(t,e,r,n,s,i,a,c,l,o){if(n&&typeof n=="object"&&!Array.isArray(n)){e(n,s,i,a,c,l,o);for(var f in n){var h=n[f];if(Array.isArray(h)){if(f in Ct.arrayKeywords)for(var _=0;_<h.length;_++)ls(t,e,r,h[_],s+"/"+f+"/"+_,i,s,f,n,_)}else if(f in Ct.propsKeywords){if(h&&typeof h=="object")for(var v in h)ls(t,e,r,h[v],s+"/"+f+"/"+dy(v),i,s,f,n,v)}else(f in Ct.keywords||t.allKeys&&!(f in Ct.skipKeywords))&&ls(t,e,r,h,s+"/"+f,i,s,f,n)}r(n,s,i,a,c,l,o)}}function dy(t){return t.replace(/~/g,"~0").replace(/\//g,"~1")}});var $n=y(Te=>{"use strict";Object.defineProperty(Te,"__esModule",{value:!0});Te.getSchemaRefs=Te.resolveUrl=Te.normalizeId=Te._getFullPath=Te.getFullPath=Te.inlineRef=void 0;var hy=H(),py=Ki(),my=gl(),vy=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function gy(t,e=!0){return typeof t=="boolean"?!0:e===!0?!Xi(t):e?yl(t)<=e:!1}Te.inlineRef=gy;var yy=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function Xi(t){for(let e in t){if(yy.has(e))return!0;let r=t[e];if(Array.isArray(r)&&r.some(Xi)||typeof r=="object"&&Xi(r))return!0}return!1}function yl(t){let e=0;for(let r in t){if(r==="$ref")return 1/0;if(e++,!vy.has(r)&&(typeof t[r]=="object"&&(0,hy.eachItem)(t[r],n=>e+=yl(n)),e===1/0))return 1/0}return e}function _l(t,e="",r){r!==!1&&(e=Or(e));let n=t.parse(e);return $l(t,n)}Te.getFullPath=_l;function $l(t,e){return t.serialize(e).split("#")[0]+"#"}Te._getFullPath=$l;var _y=/#\/?$/;function Or(t){return t?t.replace(_y,""):""}Te.normalizeId=Or;function $y(t,e,r){return r=Or(r),t.resolve(e,r)}Te.resolveUrl=$y;var Ey=/^[a-z_][-a-z0-9._]*$/i;function wy(t,e){if(typeof t=="boolean")return{};let{schemaId:r,uriResolver:n}=this.opts,s=Or(t[r]||e),i={"":s},a=_l(n,s,!1),c={},l=new Set;return my(t,{allKeys:!0},(h,_,v,E)=>{if(E===void 0)return;let $=a+_,w=i[E];typeof h[r]=="string"&&(w=b.call(this,h[r])),C.call(this,h.$anchor),C.call(this,h.$dynamicAnchor),i[_]=w;function b(q){let z=this.opts.uriResolver.resolve;if(q=Or(w?z(w,q):q),l.has(q))throw f(q);l.add(q);let N=this.refs[q];return typeof N=="string"&&(N=this.refs[N]),typeof N=="object"?o(h,N.schema,q):q!==Or($)&&(q[0]==="#"?(o(h,c[q],q),c[q]=h):this.refs[q]=$),q}function C(q){if(typeof q=="string"){if(!Ey.test(q))throw new Error(`invalid anchor "${q}"`);b.call(this,`#${q}`)}}}),c;function o(h,_,v){if(_!==void 0&&!py(h,_))throw f(v)}function f(h){return new Error(`reference "${h}" resolves to more than one schema`)}}Te.getSchemaRefs=wy});var bn=y(jt=>{"use strict";Object.defineProperty(jt,"__esModule",{value:!0});jt.getData=jt.KeywordCxt=jt.validateFunctionCode=void 0;var Ol=el(),El=_n(),Wi=xi(),fs=_n(),by=ol(),wn=dl(),Bi=pl(),R=M(),T=St(),Sy=$n(),Pt=H(),En=gn();function Py(t){if(Il(t)&&(Tl(t),Nl(t))){Ny(t);return}Rl(t,()=>(0,Ol.topBoolOrEmptySchema)(t))}jt.validateFunctionCode=Py;function Rl({gen:t,validateName:e,schema:r,schemaEnv:n,opts:s},i){s.code.es5?t.func(e,(0,R._)`${T.default.data}, ${T.default.valCxt}`,n.$async,()=>{t.code((0,R._)`"use strict"; ${wl(r,s)}`),Ry(t,s),t.code(i)}):t.func(e,(0,R._)`${T.default.data}, ${Oy(s)}`,n.$async,()=>t.code(wl(r,s)).code(i))}function Oy(t){return(0,R._)`{${T.default.instancePath}="", ${T.default.parentData}, ${T.default.parentDataProperty}, ${T.default.rootData}=${T.default.data}${t.dynamicRef?(0,R._)`, ${T.default.dynamicAnchors}={}`:R.nil}}={}`}function Ry(t,e){t.if(T.default.valCxt,()=>{t.var(T.default.instancePath,(0,R._)`${T.default.valCxt}.${T.default.instancePath}`),t.var(T.default.parentData,(0,R._)`${T.default.valCxt}.${T.default.parentData}`),t.var(T.default.parentDataProperty,(0,R._)`${T.default.valCxt}.${T.default.parentDataProperty}`),t.var(T.default.rootData,(0,R._)`${T.default.valCxt}.${T.default.rootData}`),e.dynamicRef&&t.var(T.default.dynamicAnchors,(0,R._)`${T.default.valCxt}.${T.default.dynamicAnchors}`)},()=>{t.var(T.default.instancePath,(0,R._)`""`),t.var(T.default.parentData,(0,R._)`undefined`),t.var(T.default.parentDataProperty,(0,R._)`undefined`),t.var(T.default.rootData,T.default.data),e.dynamicRef&&t.var(T.default.dynamicAnchors,(0,R._)`{}`)})}function Ny(t){let{schema:e,opts:r,gen:n}=t;Rl(t,()=>{r.$comment&&e.$comment&&Cl(t),jy(t),n.let(T.default.vErrors,null),n.let(T.default.errors,0),r.unevaluated&&Iy(t),ql(t),ky(t)})}function Iy(t){let{gen:e,validateName:r}=t;t.evaluated=e.const("evaluated",(0,R._)`${r}.evaluated`),e.if((0,R._)`${t.evaluated}.dynamicProps`,()=>e.assign((0,R._)`${t.evaluated}.props`,(0,R._)`undefined`)),e.if((0,R._)`${t.evaluated}.dynamicItems`,()=>e.assign((0,R._)`${t.evaluated}.items`,(0,R._)`undefined`))}function wl(t,e){let r=typeof t=="object"&&t[e.schemaId];return r&&(e.code.source||e.code.process)?(0,R._)`/*# sourceURL=${r} */`:R.nil}function Ty(t,e){if(Il(t)&&(Tl(t),Nl(t))){qy(t,e);return}(0,Ol.boolOrEmptySchema)(t,e)}function Nl({schema:t,self:e}){if(typeof t=="boolean")return!t;for(let r in t)if(e.RULES.all[r])return!0;return!1}function Il(t){return typeof t.schema!="boolean"}function qy(t,e){let{schema:r,gen:n,opts:s}=t;s.$comment&&r.$comment&&Cl(t),Dy(t),Ay(t);let i=n.const("_errs",T.default.errors);ql(t,i),n.var(e,(0,R._)`${i} === ${T.default.errors}`)}function Tl(t){(0,Pt.checkUnknownRules)(t),Cy(t)}function ql(t,e){if(t.opts.jtd)return bl(t,[],!1,e);let r=(0,El.getSchemaTypes)(t.schema),n=(0,El.coerceAndCheckDataType)(t,r);bl(t,r,!n,e)}function Cy(t){let{schema:e,errSchemaPath:r,opts:n,self:s}=t;e.$ref&&n.ignoreKeywordsWithRef&&(0,Pt.schemaHasRulesButRef)(e,s.RULES)&&s.logger.warn(`$ref: keywords ignored in schema at path "${r}"`)}function jy(t){let{schema:e,opts:r}=t;e.default!==void 0&&r.useDefaults&&r.strictSchema&&(0,Pt.checkStrictMode)(t,"default is ignored in the schema root")}function Dy(t){let e=t.schema[t.opts.schemaId];e&&(t.baseId=(0,Sy.resolveUrl)(t.opts.uriResolver,t.baseId,e))}function Ay(t){if(t.schema.$async&&!t.schemaEnv.$async)throw new Error("async schema in sync schema")}function Cl({gen:t,schemaEnv:e,schema:r,errSchemaPath:n,opts:s}){let i=r.$comment;if(s.$comment===!0)t.code((0,R._)`${T.default.self}.logger.log(${i})`);else if(typeof s.$comment=="function"){let a=(0,R.str)`${n}/$comment`,c=t.scopeValue("root",{ref:e.root});t.code((0,R._)`${T.default.self}.opts.$comment(${i}, ${a}, ${c}.schema)`)}}function ky(t){let{gen:e,schemaEnv:r,validateName:n,ValidationError:s,opts:i}=t;r.$async?e.if((0,R._)`${T.default.errors} === 0`,()=>e.return(T.default.data),()=>e.throw((0,R._)`new ${s}(${T.default.vErrors})`)):(e.assign((0,R._)`${n}.errors`,T.default.vErrors),i.unevaluated&&Ly(t),e.return((0,R._)`${T.default.errors} === 0`))}function Ly({gen:t,evaluated:e,props:r,items:n}){r instanceof R.Name&&t.assign((0,R._)`${e}.props`,r),n instanceof R.Name&&t.assign((0,R._)`${e}.items`,n)}function bl(t,e,r,n){let{gen:s,schema:i,data:a,allErrors:c,opts:l,self:o}=t,{RULES:f}=o;if(i.$ref&&(l.ignoreKeywordsWithRef||!(0,Pt.schemaHasRulesButRef)(i,f))){s.block(()=>jl(t,"$ref",f.all.$ref.definition));return}l.jtd||My(t,e),s.block(()=>{for(let _ of f.rules)h(_);h(f.post)});function h(_){!(0,Wi.shouldUseGroup)(i,_)||(_.type?(s.if((0,fs.checkDataType)(_.type,a,l.strictNumbers)),Sl(t,_),e.length===1&&e[0]===_.type&&r&&(s.else(),(0,fs.reportTypeError)(t)),s.endIf()):Sl(t,_),c||s.if((0,R._)`${T.default.errors} === ${n||0}`))}}function Sl(t,e){let{gen:r,schema:n,opts:{useDefaults:s}}=t;s&&(0,by.assignDefaults)(t,e.type),r.block(()=>{for(let i of e.rules)(0,Wi.shouldUseRule)(n,i)&&jl(t,i.keyword,i.definition,e.type)})}function My(t,e){t.schemaEnv.meta||!t.opts.strictTypes||(xy(t,e),t.opts.allowUnionTypes||Fy(t,e),Vy(t,t.dataTypes))}function xy(t,e){if(!!e.length){if(!t.dataTypes.length){t.dataTypes=e;return}e.forEach(r=>{Pl(t.dataTypes,r)||Yi(t,`type "${r}" not allowed by context "${t.dataTypes.join(",")}"`)}),t.dataTypes=t.dataTypes.filter(r=>Pl(e,r))}}function Fy(t,e){e.length>1&&!(e.length===2&&e.includes("null"))&&Yi(t,"use allowUnionTypes to allow union type keyword")}function Vy(t,e){let r=t.self.RULES.all;for(let n in r){let s=r[n];if(typeof s=="object"&&(0,Wi.shouldUseRule)(t.schema,s)){let{type:i}=s.definition;i.length&&!i.some(a=>Uy(e,a))&&Yi(t,`missing type "${i.join(",")}" for keyword "${n}"`)}}}function Uy(t,e){return t.includes(e)||e==="number"&&t.includes("integer")}function Pl(t,e){return t.includes(e)||e==="integer"&&t.includes("number")}function Yi(t,e){e+=` at "${t.schemaEnv.baseId+t.errSchemaPath}" (strictTypes)`,(0,Pt.checkStrictMode)(t,e,t.opts.strictTypes)}var ds=class{constructor(e,r,n){if((0,wn.validateKeywordUsage)(e,r,n),this.gen=e.gen,this.allErrors=e.allErrors,this.keyword=n,this.data=e.data,this.schema=e.schema[n],this.$data=r.$data&&e.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,Pt.schemaRefOrVal)(e,this.schema,n,this.$data),this.schemaType=r.schemaType,this.parentSchema=e.schema,this.params={},this.it=e,this.def=r,this.$data)this.schemaCode=e.gen.const("vSchema",Dl(this.$data,e));else if(this.schemaCode=this.schemaValue,!(0,wn.validSchemaType)(this.schema,r.schemaType,r.allowUndefined))throw new Error(`${n} value must be ${JSON.stringify(r.schemaType)}`);("code"in r?r.trackErrors:r.errors!==!1)&&(this.errsCount=e.gen.const("_errs",T.default.errors))}result(e,r,n){this.failResult((0,R.not)(e),r,n)}failResult(e,r,n){this.gen.if(e),n?n():this.error(),r?(this.gen.else(),r(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(e,r){this.failResult((0,R.not)(e),void 0,r)}fail(e){if(e===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(e),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(e){if(!this.$data)return this.fail(e);let{schemaCode:r}=this;this.fail((0,R._)`${r} !== undefined && (${(0,R.or)(this.invalid$data(),e)})`)}error(e,r,n){if(r){this.setParams(r),this._error(e,n),this.setParams({});return}this._error(e,n)}_error(e,r){(e?En.reportExtraError:En.reportError)(this,this.def.error,r)}$dataError(){(0,En.reportError)(this,this.def.$dataError||En.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,En.resetErrorsCount)(this.gen,this.errsCount)}ok(e){this.allErrors||this.gen.if(e)}setParams(e,r){r?Object.assign(this.params,e):this.params=e}block$data(e,r,n=R.nil){this.gen.block(()=>{this.check$data(e,n),r()})}check$data(e=R.nil,r=R.nil){if(!this.$data)return;let{gen:n,schemaCode:s,schemaType:i,def:a}=this;n.if((0,R.or)((0,R._)`${s} === undefined`,r)),e!==R.nil&&n.assign(e,!0),(i.length||a.validateSchema)&&(n.elseIf(this.invalid$data()),this.$dataError(),e!==R.nil&&n.assign(e,!1)),n.else()}invalid$data(){let{gen:e,schemaCode:r,schemaType:n,def:s,it:i}=this;return(0,R.or)(a(),c());function a(){if(n.length){if(!(r instanceof R.Name))throw new Error("ajv implementation error");let l=Array.isArray(n)?n:[n];return(0,R._)`${(0,fs.checkDataTypes)(l,r,i.opts.strictNumbers,fs.DataType.Wrong)}`}return R.nil}function c(){if(s.validateSchema){let l=e.scopeValue("validate$data",{ref:s.validateSchema});return(0,R._)`!${l}(${r})`}return R.nil}}subschema(e,r){let n=(0,Bi.getSubschema)(this.it,e);(0,Bi.extendSubschemaData)(n,this.it,e),(0,Bi.extendSubschemaMode)(n,e);let s={...this.it,...n,items:void 0,props:void 0};return Ty(s,r),s}mergeEvaluated(e,r){let{it:n,gen:s}=this;!n.opts.unevaluated||(n.props!==!0&&e.props!==void 0&&(n.props=Pt.mergeEvaluated.props(s,e.props,n.props,r)),n.items!==!0&&e.items!==void 0&&(n.items=Pt.mergeEvaluated.items(s,e.items,n.items,r)))}mergeValidEvaluated(e,r){let{it:n,gen:s}=this;if(n.opts.unevaluated&&(n.props!==!0||n.items!==!0))return s.if(r,()=>this.mergeEvaluated(e,R.Name)),!0}};jt.KeywordCxt=ds;function jl(t,e,r,n){let s=new ds(t,r,e);"code"in r?r.code(s,n):s.$data&&r.validate?(0,wn.funcKeywordCode)(s,r):"macro"in r?(0,wn.macroKeywordCode)(s,r):(r.compile||r.validate)&&(0,wn.funcKeywordCode)(s,r)}var Gy=/^\/(?:[^~]|~0|~1)*$/,Hy=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function Dl(t,{dataLevel:e,dataNames:r,dataPathArr:n}){let s,i;if(t==="")return T.default.rootData;if(t[0]==="/"){if(!Gy.test(t))throw new Error(`Invalid JSON-pointer: ${t}`);s=t,i=T.default.rootData}else{let o=Hy.exec(t);if(!o)throw new Error(`Invalid JSON-pointer: ${t}`);let f=+o[1];if(s=o[2],s==="#"){if(f>=e)throw new Error(l("property/index",f));return n[e-f]}if(f>e)throw new Error(l("data",f));if(i=r[e-f],!s)return i}let a=i,c=s.split("/");for(let o of c)o&&(i=(0,R._)`${i}${(0,R.getProperty)((0,Pt.unescapeJsonPointer)(o))}`,a=(0,R._)`${a} && ${i}`);return a;function l(o,f){return`Cannot access ${o} ${f} levels up, current level is ${e}`}}jt.getData=Dl});var hs=y(Zi=>{"use strict";Object.defineProperty(Zi,"__esModule",{value:!0});var Ji=class extends Error{constructor(e){super("validation failed"),this.errors=e,this.ajv=this.validation=!0}};Zi.default=Ji});var ps=y(ta=>{"use strict";Object.defineProperty(ta,"__esModule",{value:!0});var Qi=$n(),ea=class extends Error{constructor(e,r,n,s){super(s||`can't resolve reference ${n} from id ${r}`),this.missingRef=(0,Qi.resolveUrl)(e,r,n),this.missingSchema=(0,Qi.normalizeId)((0,Qi.getFullPath)(e,this.missingRef))}};ta.default=ea});var vs=y(He=>{"use strict";Object.defineProperty(He,"__esModule",{value:!0});He.resolveSchema=He.getCompilingSchema=He.resolveRef=He.compileSchema=He.SchemaEnv=void 0;var Je=M(),zy=hs(),Jt=St(),Ze=$n(),Al=H(),Ky=bn(),Rr=class{constructor(e){var r;this.refs={},this.dynamicAnchors={};let n;typeof e.schema=="object"&&(n=e.schema),this.schema=e.schema,this.schemaId=e.schemaId,this.root=e.root||this,this.baseId=(r=e.baseId)!==null&&r!==void 0?r:(0,Ze.normalizeId)(n==null?void 0:n[e.schemaId||"$id"]),this.schemaPath=e.schemaPath,this.localRefs=e.localRefs,this.meta=e.meta,this.$async=n==null?void 0:n.$async,this.refs={}}};He.SchemaEnv=Rr;function na(t){let e=kl.call(this,t);if(e)return e;let r=(0,Ze.getFullPath)(this.opts.uriResolver,t.root.baseId),{es5:n,lines:s}=this.opts.code,{ownProperties:i}=this.opts,a=new Je.CodeGen(this.scope,{es5:n,lines:s,ownProperties:i}),c;t.$async&&(c=a.scopeValue("Error",{ref:zy.default,code:(0,Je._)`require("ajv/dist/runtime/validation_error").default`}));let l=a.scopeName("validate");t.validateName=l;let o={gen:a,allErrors:this.opts.allErrors,data:Jt.default.data,parentData:Jt.default.parentData,parentDataProperty:Jt.default.parentDataProperty,dataNames:[Jt.default.data],dataPathArr:[Je.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:a.scopeValue("schema",this.opts.code.source===!0?{ref:t.schema,code:(0,Je.stringify)(t.schema)}:{ref:t.schema}),validateName:l,ValidationError:c,schema:t.schema,schemaEnv:t,rootId:r,baseId:t.baseId||r,schemaPath:Je.nil,errSchemaPath:t.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,Je._)`""`,opts:this.opts,self:this},f;try{this._compilations.add(t),(0,Ky.validateFunctionCode)(o),a.optimize(this.opts.code.optimize);let h=a.toString();f=`${a.scopeRefs(Jt.default.scope)}return ${h}`,this.opts.code.process&&(f=this.opts.code.process(f,t));let v=new Function(`${Jt.default.self}`,`${Jt.default.scope}`,f)(this,this.scope.get());if(this.scope.value(l,{ref:v}),v.errors=null,v.schema=t.schema,v.schemaEnv=t,t.$async&&(v.$async=!0),this.opts.code.source===!0&&(v.source={validateName:l,validateCode:h,scopeValues:a._values}),this.opts.unevaluated){let{props:E,items:$}=o;v.evaluated={props:E instanceof Je.Name?void 0:E,items:$ instanceof Je.Name?void 0:$,dynamicProps:E instanceof Je.Name,dynamicItems:$ instanceof Je.Name},v.source&&(v.source.evaluated=(0,Je.stringify)(v.evaluated))}return t.validate=v,t}catch(h){throw delete t.validate,delete t.validateName,f&&this.logger.error("Error compiling schema, function code:",f),h}finally{this._compilations.delete(t)}}He.compileSchema=na;function Xy(t,e,r){var n;r=(0,Ze.resolveUrl)(this.opts.uriResolver,e,r);let s=t.refs[r];if(s)return s;let i=Yy.call(this,t,r);if(i===void 0){let a=(n=t.localRefs)===null||n===void 0?void 0:n[r],{schemaId:c}=this.opts;a&&(i=new Rr({schema:a,schemaId:c,root:t,baseId:e}))}if(i!==void 0)return t.refs[r]=By.call(this,i)}He.resolveRef=Xy;function By(t){return(0,Ze.inlineRef)(t.schema,this.opts.inlineRefs)?t.schema:t.validate?t:na.call(this,t)}function kl(t){for(let e of this._compilations)if(Wy(e,t))return e}He.getCompilingSchema=kl;function Wy(t,e){return t.schema===e.schema&&t.root===e.root&&t.baseId===e.baseId}function Yy(t,e){let r;for(;typeof(r=this.refs[e])=="string";)e=r;return r||this.schemas[e]||ms.call(this,t,e)}function ms(t,e){let r=this.opts.uriResolver.parse(e),n=(0,Ze._getFullPath)(this.opts.uriResolver,r),s=(0,Ze.getFullPath)(this.opts.uriResolver,t.baseId,void 0);if(Object.keys(t.schema).length>0&&n===s)return ra.call(this,r,t);let i=(0,Ze.normalizeId)(n),a=this.refs[i]||this.schemas[i];if(typeof a=="string"){let c=ms.call(this,t,a);return typeof(c==null?void 0:c.schema)!="object"?void 0:ra.call(this,r,c)}if(typeof(a==null?void 0:a.schema)=="object"){if(a.validate||na.call(this,a),i===(0,Ze.normalizeId)(e)){let{schema:c}=a,{schemaId:l}=this.opts,o=c[l];return o&&(s=(0,Ze.resolveUrl)(this.opts.uriResolver,s,o)),new Rr({schema:c,schemaId:l,root:t,baseId:s})}return ra.call(this,r,a)}}He.resolveSchema=ms;var Jy=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function ra(t,{baseId:e,schema:r,root:n}){var s;if(((s=t.fragment)===null||s===void 0?void 0:s[0])!=="/")return;for(let c of t.fragment.slice(1).split("/")){if(typeof r=="boolean")return;let l=r[(0,Al.unescapeFragment)(c)];if(l===void 0)return;r=l;let o=typeof r=="object"&&r[this.opts.schemaId];!Jy.has(c)&&o&&(e=(0,Ze.resolveUrl)(this.opts.uriResolver,e,o))}let i;if(typeof r!="boolean"&&r.$ref&&!(0,Al.schemaHasRulesButRef)(r,this.RULES)){let c=(0,Ze.resolveUrl)(this.opts.uriResolver,e,r.$ref);i=ms.call(this,n,c)}let{schemaId:a}=this.opts;if(i=i||new Rr({schema:r,schemaId:a,root:n,baseId:e}),i.schema!==i.root.schema)return i}});var Ll=y(($b,Zy)=>{Zy.exports={$id:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",description:"Meta-schema for $data reference (JSON AnySchema extension proposal)",type:"object",required:["$data"],properties:{$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},additionalProperties:!1}});var xl=y((gs,Ml)=>{(function(t,e){typeof gs=="object"&&typeof Ml<"u"?e(gs):typeof define=="function"&&define.amd?define(["exports"],e):e(t.URI=t.URI||{})})(gs,function(t){"use strict";function e(){for(var d=arguments.length,u=Array(d),p=0;p<d;p++)u[p]=arguments[p];if(u.length>1){u[0]=u[0].slice(0,-1);for(var m=u.length-1,g=1;g<m;++g)u[g]=u[g].slice(1,-1);return u[m]=u[m].slice(1),u.join("")}else return u[0]}function r(d){return"(?:"+d+")"}function n(d){return d===void 0?"undefined":d===null?"null":Object.prototype.toString.call(d).split(" ").pop().split("]").shift().toLowerCase()}function s(d){return d.toUpperCase()}function i(d){return d!=null?d instanceof Array?d:typeof d.length!="number"||d.split||d.setInterval||d.call?[d]:Array.prototype.slice.call(d):[]}function a(d,u){var p=d;if(u)for(var m in u)p[m]=u[m];return p}function c(d){var u="[A-Za-z]",p="[\\x0D]",m="[0-9]",g="[\\x22]",S=e(m,"[A-Fa-f]"),j="[\\x0A]",U="[\\x20]",B=r(r("%[EFef]"+S+"%"+S+S+"%"+S+S)+"|"+r("%[89A-Fa-f]"+S+"%"+S+S)+"|"+r("%"+S+S)),ce="[\\:\\/\\?\\#\\[\\]\\@]",F="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",ne=e(ce,F),ue=d?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]",re=d?"[\\uE000-\\uF8FF]":"[]",K=e(u,m,"[\\-\\.\\_\\~]",ue),se=r(u+e(u,m,"[\\+\\-\\.]")+"*"),W=r(r(B+"|"+e(K,F,"[\\:]"))+"*"),Lt=r(r("25[0-5]")+"|"+r("2[0-4]"+m)+"|"+r("1"+m+m)+"|"+r("[1-9]"+m)+"|"+m),je=r(r("25[0-5]")+"|"+r("2[0-4]"+m)+"|"+r("1"+m+m)+"|"+r("0?[1-9]"+m)+"|0?0?"+m),Me=r(je+"\\."+je+"\\."+je+"\\."+je),J=r(S+"{1,4}"),De=r(r(J+"\\:"+J)+"|"+Me),xe=r(r(J+"\\:")+"{6}"+De),it=r("\\:\\:"+r(J+"\\:")+"{5}"+De),Mt=r(r(J)+"?\\:\\:"+r(J+"\\:")+"{4}"+De),vt=r(r(r(J+"\\:")+"{0,1}"+J)+"?\\:\\:"+r(J+"\\:")+"{3}"+De),Gr=r(r(r(J+"\\:")+"{0,2}"+J)+"?\\:\\:"+r(J+"\\:")+"{2}"+De),Mn=r(r(r(J+"\\:")+"{0,3}"+J)+"?\\:\\:"+J+"\\:"+De),xn=r(r(r(J+"\\:")+"{0,4}"+J)+"?\\:\\:"+De),or=r(r(r(J+"\\:")+"{0,5}"+J)+"?\\:\\:"+J),cr=r(r(r(J+"\\:")+"{0,6}"+J)+"?\\:\\:"),gt=r([xe,it,Mt,vt,Gr,Mn,xn,or,cr].join("|")),ur=r(r(K+"|"+B)+"+"),Vs=r(gt+"\\%25"+ur),xt=r(gt+r("\\%25|\\%(?!"+S+"{2})")+ur),zd=r("[vV]"+S+"+\\."+e(K,F,"[\\:]")+"+"),Kd=r("\\["+r(xt+"|"+gt+"|"+zd)+"\\]"),yo=r(r(B+"|"+e(K,F))+"*"),Hr=r(Kd+"|"+Me+"(?!"+yo+")|"+yo),zr=r(m+"*"),_o=r(r(W+"@")+"?"+Hr+r("\\:"+zr)+"?"),Kr=r(B+"|"+e(K,F,"[\\:\\@]")),Xd=r(Kr+"*"),$o=r(Kr+"+"),Bd=r(r(B+"|"+e(K,F,"[\\@]"))+"+"),yt=r(r("\\/"+Xd)+"*"),lr=r("\\/"+r($o+yt)+"?"),Us=r(Bd+yt),Fn=r($o+yt),fr="(?!"+Kr+")",GE=r(yt+"|"+lr+"|"+Us+"|"+Fn+"|"+fr),dr=r(r(Kr+"|"+e("[\\/\\?]",re))+"*"),Xr=r(r(Kr+"|[\\/\\?]")+"*"),Eo=r(r("\\/\\/"+_o+yt)+"|"+lr+"|"+Fn+"|"+fr),Wd=r(se+"\\:"+Eo+r("\\?"+dr)+"?"+r("\\#"+Xr)+"?"),Yd=r(r("\\/\\/"+_o+yt)+"|"+lr+"|"+Us+"|"+fr),Jd=r(Yd+r("\\?"+dr)+"?"+r("\\#"+Xr)+"?"),HE=r(Wd+"|"+Jd),zE=r(se+"\\:"+Eo+r("\\?"+dr)+"?"),KE="^("+se+")\\:"+r(r("\\/\\/("+r("("+W+")@")+"?("+Hr+")"+r("\\:("+zr+")")+"?)")+"?("+yt+"|"+lr+"|"+Fn+"|"+fr+")")+r("\\?("+dr+")")+"?"+r("\\#("+Xr+")")+"?$",XE="^(){0}"+r(r("\\/\\/("+r("("+W+")@")+"?("+Hr+")"+r("\\:("+zr+")")+"?)")+"?("+yt+"|"+lr+"|"+Us+"|"+fr+")")+r("\\?("+dr+")")+"?"+r("\\#("+Xr+")")+"?$",BE="^("+se+")\\:"+r(r("\\/\\/("+r("("+W+")@")+"?("+Hr+")"+r("\\:("+zr+")")+"?)")+"?("+yt+"|"+lr+"|"+Fn+"|"+fr+")")+r("\\?("+dr+")")+"?$",WE="^"+r("\\#("+Xr+")")+"?$",YE="^"+r("("+W+")@")+"?("+Hr+")"+r("\\:("+zr+")")+"?$";return{NOT_SCHEME:new RegExp(e("[^]",u,m,"[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(e("[^\\%\\:]",K,F),"g"),NOT_HOST:new RegExp(e("[^\\%\\[\\]\\:]",K,F),"g"),NOT_PATH:new RegExp(e("[^\\%\\/\\:\\@]",K,F),"g"),NOT_PATH_NOSCHEME:new RegExp(e("[^\\%\\/\\@]",K,F),"g"),NOT_QUERY:new RegExp(e("[^\\%]",K,F,"[\\:\\@\\/\\?]",re),"g"),NOT_FRAGMENT:new RegExp(e("[^\\%]",K,F,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(e("[^]",K,F),"g"),UNRESERVED:new RegExp(K,"g"),OTHER_CHARS:new RegExp(e("[^\\%]",K,ne),"g"),PCT_ENCODED:new RegExp(B,"g"),IPV4ADDRESS:new RegExp("^("+Me+")$"),IPV6ADDRESS:new RegExp("^\\[?("+gt+")"+r(r("\\%25|\\%(?!"+S+"{2})")+"("+ur+")")+"?\\]?$")}}var l=c(!1),o=c(!0),f=function(){function d(u,p){var m=[],g=!0,S=!1,j=void 0;try{for(var U=u[Symbol.iterator](),B;!(g=(B=U.next()).done)&&(m.push(B.value),!(p&&m.length===p));g=!0);}catch(ce){S=!0,j=ce}finally{try{!g&&U.return&&U.return()}finally{if(S)throw j}}return m}return function(u,p){if(Array.isArray(u))return u;if(Symbol.iterator in Object(u))return d(u,p);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),h=function(d){if(Array.isArray(d)){for(var u=0,p=Array(d.length);u<d.length;u++)p[u]=d[u];return p}else return Array.from(d)},_=2147483647,v=36,E=1,$=26,w=38,b=700,C=72,q=128,z="-",N=/^xn--/,me=/[^\0-\x7E]/,Ke=/[\x2E\u3002\uFF0E\uFF61]/g,dt={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},et=v-E,le=Math.floor,Xe=String.fromCharCode;function Oe(d){throw new RangeError(dt[d])}function kt(d,u){for(var p=[],m=d.length;m--;)p[m]=u(d[m]);return p}function ht(d,u){var p=d.split("@"),m="";p.length>1&&(m=p[0]+"@",d=p[1]),d=d.replace(Ke,".");var g=d.split("."),S=kt(g,u).join(".");return m+S}function tt(d){for(var u=[],p=0,m=d.length;p<m;){var g=d.charCodeAt(p++);if(g>=55296&&g<=56319&&p<m){var S=d.charCodeAt(p++);(S&64512)==56320?u.push(((g&1023)<<10)+(S&1023)+65536):(u.push(g),p--)}else u.push(g)}return u}var rr=function(u){return String.fromCodePoint.apply(String,h(u))},wd=function(u){return u-48<10?u-22:u-65<26?u-65:u-97<26?u-97:v},eo=function(u,p){return u+22+75*(u<26)-((p!=0)<<5)},to=function(u,p,m){var g=0;for(u=m?le(u/b):u>>1,u+=le(u/p);u>et*$>>1;g+=v)u=le(u/et);return le(g+(et+1)*u/(u+w))},ro=function(u){var p=[],m=u.length,g=0,S=q,j=C,U=u.lastIndexOf(z);U<0&&(U=0);for(var B=0;B<U;++B)u.charCodeAt(B)>=128&&Oe("not-basic"),p.push(u.charCodeAt(B));for(var ce=U>0?U+1:0;ce<m;){for(var F=g,ne=1,ue=v;;ue+=v){ce>=m&&Oe("invalid-input");var re=wd(u.charCodeAt(ce++));(re>=v||re>le((_-g)/ne))&&Oe("overflow"),g+=re*ne;var K=ue<=j?E:ue>=j+$?$:ue-j;if(re<K)break;var se=v-K;ne>le(_/se)&&Oe("overflow"),ne*=se}var W=p.length+1;j=to(g-F,W,F==0),le(g/W)>_-S&&Oe("overflow"),S+=le(g/W),g%=W,p.splice(g++,0,S)}return String.fromCodePoint.apply(String,p)},no=function(u){var p=[];u=tt(u);var m=u.length,g=q,S=0,j=C,U=!0,B=!1,ce=void 0;try{for(var F=u[Symbol.iterator](),ne;!(U=(ne=F.next()).done);U=!0){var ue=ne.value;ue<128&&p.push(Xe(ue))}}catch(xt){B=!0,ce=xt}finally{try{!U&&F.return&&F.return()}finally{if(B)throw ce}}var re=p.length,K=re;for(re&&p.push(z);K<m;){var se=_,W=!0,Lt=!1,je=void 0;try{for(var Me=u[Symbol.iterator](),J;!(W=(J=Me.next()).done);W=!0){var De=J.value;De>=g&&De<se&&(se=De)}}catch(xt){Lt=!0,je=xt}finally{try{!W&&Me.return&&Me.return()}finally{if(Lt)throw je}}var xe=K+1;se-g>le((_-S)/xe)&&Oe("overflow"),S+=(se-g)*xe,g=se;var it=!0,Mt=!1,vt=void 0;try{for(var Gr=u[Symbol.iterator](),Mn;!(it=(Mn=Gr.next()).done);it=!0){var xn=Mn.value;if(xn<g&&++S>_&&Oe("overflow"),xn==g){for(var or=S,cr=v;;cr+=v){var gt=cr<=j?E:cr>=j+$?$:cr-j;if(or<gt)break;var ur=or-gt,Vs=v-gt;p.push(Xe(eo(gt+ur%Vs,0))),or=le(ur/Vs)}p.push(Xe(eo(or,0))),j=to(S,xe,K==re),S=0,++K}}}catch(xt){Mt=!0,vt=xt}finally{try{!it&&Gr.return&&Gr.return()}finally{if(Mt)throw vt}}++S,++g}return p.join("")},bd=function(u){return ht(u,function(p){return N.test(p)?ro(p.slice(4).toLowerCase()):p})},Sd=function(u){return ht(u,function(p){return me.test(p)?"xn--"+no(p):p})},nr={version:"2.1.0",ucs2:{decode:tt,encode:rr},decode:ro,encode:no,toASCII:Sd,toUnicode:bd},Le={};function rt(d){var u=d.charCodeAt(0),p=void 0;return u<16?p="%0"+u.toString(16).toUpperCase():u<128?p="%"+u.toString(16).toUpperCase():u<2048?p="%"+(u>>6|192).toString(16).toUpperCase()+"%"+(u&63|128).toString(16).toUpperCase():p="%"+(u>>12|224).toString(16).toUpperCase()+"%"+(u>>6&63|128).toString(16).toUpperCase()+"%"+(u&63|128).toString(16).toUpperCase(),p}function sr(d){for(var u="",p=0,m=d.length;p<m;){var g=parseInt(d.substr(p+1,2),16);if(g<128)u+=String.fromCharCode(g),p+=3;else if(g>=194&&g<224){if(m-p>=6){var S=parseInt(d.substr(p+4,2),16);u+=String.fromCharCode((g&31)<<6|S&63)}else u+=d.substr(p,6);p+=6}else if(g>=224){if(m-p>=9){var j=parseInt(d.substr(p+4,2),16),U=parseInt(d.substr(p+7,2),16);u+=String.fromCharCode((g&15)<<12|(j&63)<<6|U&63)}else u+=d.substr(p,9);p+=9}else u+=d.substr(p,3),p+=3}return u}function Ls(d,u){function p(m){var g=sr(m);return g.match(u.UNRESERVED)?g:m}return d.scheme&&(d.scheme=String(d.scheme).replace(u.PCT_ENCODED,p).toLowerCase().replace(u.NOT_SCHEME,"")),d.userinfo!==void 0&&(d.userinfo=String(d.userinfo).replace(u.PCT_ENCODED,p).replace(u.NOT_USERINFO,rt).replace(u.PCT_ENCODED,s)),d.host!==void 0&&(d.host=String(d.host).replace(u.PCT_ENCODED,p).toLowerCase().replace(u.NOT_HOST,rt).replace(u.PCT_ENCODED,s)),d.path!==void 0&&(d.path=String(d.path).replace(u.PCT_ENCODED,p).replace(d.scheme?u.NOT_PATH:u.NOT_PATH_NOSCHEME,rt).replace(u.PCT_ENCODED,s)),d.query!==void 0&&(d.query=String(d.query).replace(u.PCT_ENCODED,p).replace(u.NOT_QUERY,rt).replace(u.PCT_ENCODED,s)),d.fragment!==void 0&&(d.fragment=String(d.fragment).replace(u.PCT_ENCODED,p).replace(u.NOT_FRAGMENT,rt).replace(u.PCT_ENCODED,s)),d}function Ms(d){return d.replace(/^0*(.*)/,"$1")||"0"}function xs(d,u){var p=d.match(u.IPV4ADDRESS)||[],m=f(p,2),g=m[1];return g?g.split(".").map(Ms).join("."):d}function so(d,u){var p=d.match(u.IPV6ADDRESS)||[],m=f(p,3),g=m[1],S=m[2];if(g){for(var j=g.toLowerCase().split("::").reverse(),U=f(j,2),B=U[0],ce=U[1],F=ce?ce.split(":").map(Ms):[],ne=B.split(":").map(Ms),ue=u.IPV4ADDRESS.test(ne[ne.length-1]),re=ue?7:8,K=ne.length-re,se=Array(re),W=0;W<re;++W)se[W]=F[W]||ne[K+W]||"";ue&&(se[re-1]=xs(se[re-1],u));var Lt=se.reduce(function(xe,it,Mt){if(!it||it==="0"){var vt=xe[xe.length-1];vt&&vt.index+vt.length===Mt?vt.length++:xe.push({index:Mt,length:1})}return xe},[]),je=Lt.sort(function(xe,it){return it.length-xe.length})[0],Me=void 0;if(je&&je.length>1){var J=se.slice(0,je.index),De=se.slice(je.index+je.length);Me=J.join(":")+"::"+De.join(":")}else Me=se.join(":");return S&&(Me+="%"+S),Me}else return d}var Pd=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?(\[[^\/?#\]]+\]|[^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n|\r)*))?/i,Od="".match(/(){0}/)[1]===void 0;function pt(d){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},p={},m=u.iri!==!1?o:l;u.reference==="suffix"&&(d=(u.scheme?u.scheme+":":"")+"//"+d);var g=d.match(Pd);if(g){Od?(p.scheme=g[1],p.userinfo=g[3],p.host=g[4],p.port=parseInt(g[5],10),p.path=g[6]||"",p.query=g[7],p.fragment=g[8],isNaN(p.port)&&(p.port=g[5])):(p.scheme=g[1]||void 0,p.userinfo=d.indexOf("@")!==-1?g[3]:void 0,p.host=d.indexOf("//")!==-1?g[4]:void 0,p.port=parseInt(g[5],10),p.path=g[6]||"",p.query=d.indexOf("?")!==-1?g[7]:void 0,p.fragment=d.indexOf("#")!==-1?g[8]:void 0,isNaN(p.port)&&(p.port=d.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?g[4]:void 0)),p.host&&(p.host=so(xs(p.host,m),m)),p.scheme===void 0&&p.userinfo===void 0&&p.host===void 0&&p.port===void 0&&!p.path&&p.query===void 0?p.reference="same-document":p.scheme===void 0?p.reference="relative":p.fragment===void 0?p.reference="absolute":p.reference="uri",u.reference&&u.reference!=="suffix"&&u.reference!==p.reference&&(p.error=p.error||"URI is not a "+u.reference+" reference.");var S=Le[(u.scheme||p.scheme||"").toLowerCase()];if(!u.unicodeSupport&&(!S||!S.unicodeSupport)){if(p.host&&(u.domainHost||S&&S.domainHost))try{p.host=nr.toASCII(p.host.replace(m.PCT_ENCODED,sr).toLowerCase())}catch(j){p.error=p.error||"Host's domain name can not be converted to ASCII via punycode: "+j}Ls(p,l)}else Ls(p,m);S&&S.parse&&S.parse(p,u)}else p.error=p.error||"URI can not be parsed.";return p}function Rd(d,u){var p=u.iri!==!1?o:l,m=[];return d.userinfo!==void 0&&(m.push(d.userinfo),m.push("@")),d.host!==void 0&&m.push(so(xs(String(d.host),p),p).replace(p.IPV6ADDRESS,function(g,S,j){return"["+S+(j?"%25"+j:"")+"]"})),(typeof d.port=="number"||typeof d.port=="string")&&(m.push(":"),m.push(String(d.port))),m.length?m.join(""):void 0}var io=/^\.\.?\//,ao=/^\/\.(\/|$)/,oo=/^\/\.\.(\/|$)/,Nd=/^\/?(?:.|\n)*?(?=\/|$)/;function ir(d){for(var u=[];d.length;)if(d.match(io))d=d.replace(io,"");else if(d.match(ao))d=d.replace(ao,"/");else if(d.match(oo))d=d.replace(oo,"/"),u.pop();else if(d==="."||d==="..")d="";else{var p=d.match(Nd);if(p){var m=p[0];d=d.slice(m.length),u.push(m)}else throw new Error("Unexpected dot segment condition")}return u.join("")}function nt(d){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},p=u.iri?o:l,m=[],g=Le[(u.scheme||d.scheme||"").toLowerCase()];if(g&&g.serialize&&g.serialize(d,u),d.host&&!p.IPV6ADDRESS.test(d.host)){if(u.domainHost||g&&g.domainHost)try{d.host=u.iri?nr.toUnicode(d.host):nr.toASCII(d.host.replace(p.PCT_ENCODED,sr).toLowerCase())}catch(U){d.error=d.error||"Host's domain name can not be converted to "+(u.iri?"Unicode":"ASCII")+" via punycode: "+U}}Ls(d,p),u.reference!=="suffix"&&d.scheme&&(m.push(d.scheme),m.push(":"));var S=Rd(d,u);if(S!==void 0&&(u.reference!=="suffix"&&m.push("//"),m.push(S),d.path&&d.path.charAt(0)!=="/"&&m.push("/")),d.path!==void 0){var j=d.path;!u.absolutePath&&(!g||!g.absolutePath)&&(j=ir(j)),S===void 0&&(j=j.replace(/^\/\//,"/%2F")),m.push(j)}return d.query!==void 0&&(m.push("?"),m.push(d.query)),d.fragment!==void 0&&(m.push("#"),m.push(d.fragment)),m.join("")}function co(d,u){var p=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},m=arguments[3],g={};return m||(d=pt(nt(d,p),p),u=pt(nt(u,p),p)),p=p||{},!p.tolerant&&u.scheme?(g.scheme=u.scheme,g.userinfo=u.userinfo,g.host=u.host,g.port=u.port,g.path=ir(u.path||""),g.query=u.query):(u.userinfo!==void 0||u.host!==void 0||u.port!==void 0?(g.userinfo=u.userinfo,g.host=u.host,g.port=u.port,g.path=ir(u.path||""),g.query=u.query):(u.path?(u.path.charAt(0)==="/"?g.path=ir(u.path):((d.userinfo!==void 0||d.host!==void 0||d.port!==void 0)&&!d.path?g.path="/"+u.path:d.path?g.path=d.path.slice(0,d.path.lastIndexOf("/")+1)+u.path:g.path=u.path,g.path=ir(g.path)),g.query=u.query):(g.path=d.path,u.query!==void 0?g.query=u.query:g.query=d.query),g.userinfo=d.userinfo,g.host=d.host,g.port=d.port),g.scheme=d.scheme),g.fragment=u.fragment,g}function Id(d,u,p){var m=a({scheme:"null"},p);return nt(co(pt(d,m),pt(u,m),m,!0),m)}function Td(d,u){return typeof d=="string"?d=nt(pt(d,u),u):n(d)==="object"&&(d=pt(nt(d,u),u)),d}function qd(d,u,p){return typeof d=="string"?d=nt(pt(d,p),p):n(d)==="object"&&(d=nt(d,p)),typeof u=="string"?u=nt(pt(u,p),p):n(u)==="object"&&(u=nt(u,p)),d===u}function Cd(d,u){return d&&d.toString().replace(!u||!u.iri?l.ESCAPE:o.ESCAPE,rt)}function mt(d,u){return d&&d.toString().replace(!u||!u.iri?l.PCT_ENCODED:o.PCT_ENCODED,sr)}var Vr={scheme:"http",domainHost:!0,parse:function(u,p){return u.host||(u.error=u.error||"HTTP URIs must have a host."),u},serialize:function(u,p){var m=String(u.scheme).toLowerCase()==="https";return(u.port===(m?443:80)||u.port==="")&&(u.port=void 0),u.path||(u.path="/"),u}},uo={scheme:"https",domainHost:Vr.domainHost,parse:Vr.parse,serialize:Vr.serialize};function lo(d){return typeof d.secure=="boolean"?d.secure:String(d.scheme).toLowerCase()==="wss"}var Ur={scheme:"ws",domainHost:!0,parse:function(u,p){var m=u;return m.secure=lo(m),m.resourceName=(m.path||"/")+(m.query?"?"+m.query:""),m.path=void 0,m.query=void 0,m},serialize:function(u,p){if((u.port===(lo(u)?443:80)||u.port==="")&&(u.port=void 0),typeof u.secure=="boolean"&&(u.scheme=u.secure?"wss":"ws",u.secure=void 0),u.resourceName){var m=u.resourceName.split("?"),g=f(m,2),S=g[0],j=g[1];u.path=S&&S!=="/"?S:void 0,u.query=j,u.resourceName=void 0}return u.fragment=void 0,u}},fo={scheme:"wss",domainHost:Ur.domainHost,parse:Ur.parse,serialize:Ur.serialize},jd={},Dd=!0,ho="[A-Za-z0-9\\-\\.\\_\\~"+(Dd?"\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF":"")+"]",st="[0-9A-Fa-f]",Ad=r(r("%[EFef]"+st+"%"+st+st+"%"+st+st)+"|"+r("%[89A-Fa-f]"+st+"%"+st+st)+"|"+r("%"+st+st)),kd="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",Ld="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",Md=e(Ld,'[\\"\\\\]'),xd="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",Fd=new RegExp(ho,"g"),ar=new RegExp(Ad,"g"),Vd=new RegExp(e("[^]",kd,"[\\.]",'[\\"]',Md),"g"),po=new RegExp(e("[^]",ho,xd),"g"),Ud=po;function Fs(d){var u=sr(d);return u.match(Fd)?u:d}var mo={scheme:"mailto",parse:function(u,p){var m=u,g=m.to=m.path?m.path.split(","):[];if(m.path=void 0,m.query){for(var S=!1,j={},U=m.query.split("&"),B=0,ce=U.length;B<ce;++B){var F=U[B].split("=");switch(F[0]){case"to":for(var ne=F[1].split(","),ue=0,re=ne.length;ue<re;++ue)g.push(ne[ue]);break;case"subject":m.subject=mt(F[1],p);break;case"body":m.body=mt(F[1],p);break;default:S=!0,j[mt(F[0],p)]=mt(F[1],p);break}}S&&(m.headers=j)}m.query=void 0;for(var K=0,se=g.length;K<se;++K){var W=g[K].split("@");if(W[0]=mt(W[0]),p.unicodeSupport)W[1]=mt(W[1],p).toLowerCase();else try{W[1]=nr.toASCII(mt(W[1],p).toLowerCase())}catch(Lt){m.error=m.error||"Email address's domain name can not be converted to ASCII via punycode: "+Lt}g[K]=W.join("@")}return m},serialize:function(u,p){var m=u,g=i(u.to);if(g){for(var S=0,j=g.length;S<j;++S){var U=String(g[S]),B=U.lastIndexOf("@"),ce=U.slice(0,B).replace(ar,Fs).replace(ar,s).replace(Vd,rt),F=U.slice(B+1);try{F=p.iri?nr.toUnicode(F):nr.toASCII(mt(F,p).toLowerCase())}catch(K){m.error=m.error||"Email address's domain name can not be converted to "+(p.iri?"Unicode":"ASCII")+" via punycode: "+K}g[S]=ce+"@"+F}m.path=g.join(",")}var ne=u.headers=u.headers||{};u.subject&&(ne.subject=u.subject),u.body&&(ne.body=u.body);var ue=[];for(var re in ne)ne[re]!==jd[re]&&ue.push(re.replace(ar,Fs).replace(ar,s).replace(po,rt)+"="+ne[re].replace(ar,Fs).replace(ar,s).replace(Ud,rt));return ue.length&&(m.query=ue.join("&")),m}},Gd=/^([^\:]+)\:(.*)/,vo={scheme:"urn",parse:function(u,p){var m=u.path&&u.path.match(Gd),g=u;if(m){var S=p.scheme||g.scheme||"urn",j=m[1].toLowerCase(),U=m[2],B=S+":"+(p.nid||j),ce=Le[B];g.nid=j,g.nss=U,g.path=void 0,ce&&(g=ce.parse(g,p))}else g.error=g.error||"URN can not be parsed.";return g},serialize:function(u,p){var m=p.scheme||u.scheme||"urn",g=u.nid,S=m+":"+(p.nid||g),j=Le[S];j&&(u=j.serialize(u,p));var U=u,B=u.nss;return U.path=(g||p.nid)+":"+B,U}},Hd=/^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/,go={scheme:"urn:uuid",parse:function(u,p){var m=u;return m.uuid=m.nss,m.nss=void 0,!p.tolerant&&(!m.uuid||!m.uuid.match(Hd))&&(m.error=m.error||"UUID is not valid."),m},serialize:function(u,p){var m=u;return m.nss=(u.uuid||"").toLowerCase(),m}};Le[Vr.scheme]=Vr,Le[uo.scheme]=uo,Le[Ur.scheme]=Ur,Le[fo.scheme]=fo,Le[mo.scheme]=mo,Le[vo.scheme]=vo,Le[go.scheme]=go,t.SCHEMES=Le,t.pctEncChar=rt,t.pctDecChars=sr,t.parse=pt,t.removeDotSegments=ir,t.serialize=nt,t.resolveComponents=co,t.resolve=Id,t.normalize=Td,t.equal=qd,t.escapeComponent=Cd,t.unescapeComponent=mt,Object.defineProperty(t,"__esModule",{value:!0})})});var Vl=y(sa=>{"use strict";Object.defineProperty(sa,"__esModule",{value:!0});var Fl=xl();Fl.code='require("ajv/dist/runtime/uri").default';sa.default=Fl});var Wl=y(he=>{"use strict";Object.defineProperty(he,"__esModule",{value:!0});he.CodeGen=he.Name=he.nil=he.stringify=he.str=he._=he.KeywordCxt=void 0;var Qy=bn();Object.defineProperty(he,"KeywordCxt",{enumerable:!0,get:function(){return Qy.KeywordCxt}});var Nr=M();Object.defineProperty(he,"_",{enumerable:!0,get:function(){return Nr._}});Object.defineProperty(he,"str",{enumerable:!0,get:function(){return Nr.str}});Object.defineProperty(he,"stringify",{enumerable:!0,get:function(){return Nr.stringify}});Object.defineProperty(he,"nil",{enumerable:!0,get:function(){return Nr.nil}});Object.defineProperty(he,"Name",{enumerable:!0,get:function(){return Nr.Name}});Object.defineProperty(he,"CodeGen",{enumerable:!0,get:function(){return Nr.CodeGen}});var e0=hs(),Kl=ps(),t0=Mi(),Sn=vs(),r0=M(),Pn=$n(),ys=_n(),aa=H(),Ul=Ll(),n0=Vl(),Xl=(t,e)=>new RegExp(t,e);Xl.code="new RegExp";var s0=["removeAdditional","useDefaults","coerceTypes"],i0=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),a0={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},o0={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},Gl=200;function c0(t){var e,r,n,s,i,a,c,l,o,f,h,_,v,E,$,w,b,C,q,z,N,me,Ke,dt,et;let le=t.strict,Xe=(e=t.code)===null||e===void 0?void 0:e.optimize,Oe=Xe===!0||Xe===void 0?1:Xe||0,kt=(n=(r=t.code)===null||r===void 0?void 0:r.regExp)!==null&&n!==void 0?n:Xl,ht=(s=t.uriResolver)!==null&&s!==void 0?s:n0.default;return{strictSchema:(a=(i=t.strictSchema)!==null&&i!==void 0?i:le)!==null&&a!==void 0?a:!0,strictNumbers:(l=(c=t.strictNumbers)!==null&&c!==void 0?c:le)!==null&&l!==void 0?l:!0,strictTypes:(f=(o=t.strictTypes)!==null&&o!==void 0?o:le)!==null&&f!==void 0?f:"log",strictTuples:(_=(h=t.strictTuples)!==null&&h!==void 0?h:le)!==null&&_!==void 0?_:"log",strictRequired:(E=(v=t.strictRequired)!==null&&v!==void 0?v:le)!==null&&E!==void 0?E:!1,code:t.code?{...t.code,optimize:Oe,regExp:kt}:{optimize:Oe,regExp:kt},loopRequired:($=t.loopRequired)!==null&&$!==void 0?$:Gl,loopEnum:(w=t.loopEnum)!==null&&w!==void 0?w:Gl,meta:(b=t.meta)!==null&&b!==void 0?b:!0,messages:(C=t.messages)!==null&&C!==void 0?C:!0,inlineRefs:(q=t.inlineRefs)!==null&&q!==void 0?q:!0,schemaId:(z=t.schemaId)!==null&&z!==void 0?z:"$id",addUsedSchema:(N=t.addUsedSchema)!==null&&N!==void 0?N:!0,validateSchema:(me=t.validateSchema)!==null&&me!==void 0?me:!0,validateFormats:(Ke=t.validateFormats)!==null&&Ke!==void 0?Ke:!0,unicodeRegExp:(dt=t.unicodeRegExp)!==null&&dt!==void 0?dt:!0,int32range:(et=t.int32range)!==null&&et!==void 0?et:!0,uriResolver:ht}}var On=class{constructor(e={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,e=this.opts={...e,...c0(e)};let{es5:r,lines:n}=this.opts.code;this.scope=new r0.ValueScope({scope:{},prefixes:i0,es5:r,lines:n}),this.logger=p0(e.logger);let s=e.validateFormats;e.validateFormats=!1,this.RULES=(0,t0.getRules)(),Hl.call(this,a0,e,"NOT SUPPORTED"),Hl.call(this,o0,e,"DEPRECATED","warn"),this._metaOpts=d0.call(this),e.formats&&l0.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),e.keywords&&f0.call(this,e.keywords),typeof e.meta=="object"&&this.addMetaSchema(e.meta),u0.call(this),e.validateFormats=s}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){let{$data:e,meta:r,schemaId:n}=this.opts,s=Ul;n==="id"&&(s={...Ul},s.id=s.$id,delete s.$id),r&&e&&this.addMetaSchema(s,s[n],!1)}defaultMeta(){let{meta:e,schemaId:r}=this.opts;return this.opts.defaultMeta=typeof e=="object"?e[r]||e:void 0}validate(e,r){let n;if(typeof e=="string"){if(n=this.getSchema(e),!n)throw new Error(`no schema with key or ref "${e}"`)}else n=this.compile(e);let s=n(r);return"$async"in n||(this.errors=n.errors),s}compile(e,r){let n=this._addSchema(e,r);return n.validate||this._compileSchemaEnv(n)}compileAsync(e,r){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");let{loadSchema:n}=this.opts;return s.call(this,e,r);async function s(f,h){await i.call(this,f.$schema);let _=this._addSchema(f,h);return _.validate||a.call(this,_)}async function i(f){f&&!this.getSchema(f)&&await s.call(this,{$ref:f},!0)}async function a(f){try{return this._compileSchemaEnv(f)}catch(h){if(!(h instanceof Kl.default))throw h;return c.call(this,h),await l.call(this,h.missingSchema),a.call(this,f)}}function c({missingSchema:f,missingRef:h}){if(this.refs[f])throw new Error(`AnySchema ${f} is loaded but ${h} cannot be resolved`)}async function l(f){let h=await o.call(this,f);this.refs[f]||await i.call(this,h.$schema),this.refs[f]||this.addSchema(h,f,r)}async function o(f){let h=this._loading[f];if(h)return h;try{return await(this._loading[f]=n(f))}finally{delete this._loading[f]}}}addSchema(e,r,n,s=this.opts.validateSchema){if(Array.isArray(e)){for(let a of e)this.addSchema(a,void 0,n,s);return this}let i;if(typeof e=="object"){let{schemaId:a}=this.opts;if(i=e[a],i!==void 0&&typeof i!="string")throw new Error(`schema ${a} must be string`)}return r=(0,Pn.normalizeId)(r||i),this._checkUnique(r),this.schemas[r]=this._addSchema(e,n,r,s,!0),this}addMetaSchema(e,r,n=this.opts.validateSchema){return this.addSchema(e,r,!0,n),this}validateSchema(e,r){if(typeof e=="boolean")return!0;let n;if(n=e.$schema,n!==void 0&&typeof n!="string")throw new Error("$schema must be a string");if(n=n||this.opts.defaultMeta||this.defaultMeta(),!n)return this.logger.warn("meta-schema not available"),this.errors=null,!0;let s=this.validate(n,e);if(!s&&r){let i="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(i);else throw new Error(i)}return s}getSchema(e){let r;for(;typeof(r=zl.call(this,e))=="string";)e=r;if(r===void 0){let{schemaId:n}=this.opts,s=new Sn.SchemaEnv({schema:{},schemaId:n});if(r=Sn.resolveSchema.call(this,s,e),!r)return;this.refs[e]=r}return r.validate||this._compileSchemaEnv(r)}removeSchema(e){if(e instanceof RegExp)return this._removeAllSchemas(this.schemas,e),this._removeAllSchemas(this.refs,e),this;switch(typeof e){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{let r=zl.call(this,e);return typeof r=="object"&&this._cache.delete(r.schema),delete this.schemas[e],delete this.refs[e],this}case"object":{let r=e;this._cache.delete(r);let n=e[this.opts.schemaId];return n&&(n=(0,Pn.normalizeId)(n),delete this.schemas[n],delete this.refs[n]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(e){for(let r of e)this.addKeyword(r);return this}addKeyword(e,r){let n;if(typeof e=="string")n=e,typeof r=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),r.keyword=n);else if(typeof e=="object"&&r===void 0){if(r=e,n=r.keyword,Array.isArray(n)&&!n.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if(v0.call(this,n,r),!r)return(0,aa.eachItem)(n,i=>ia.call(this,i)),this;y0.call(this,r);let s={...r,type:(0,ys.getJSONTypes)(r.type),schemaType:(0,ys.getJSONTypes)(r.schemaType)};return(0,aa.eachItem)(n,s.type.length===0?i=>ia.call(this,i,s):i=>s.type.forEach(a=>ia.call(this,i,s,a))),this}getKeyword(e){let r=this.RULES.all[e];return typeof r=="object"?r.definition:!!r}removeKeyword(e){let{RULES:r}=this;delete r.keywords[e],delete r.all[e];for(let n of r.rules){let s=n.rules.findIndex(i=>i.keyword===e);s>=0&&n.rules.splice(s,1)}return this}addFormat(e,r){return typeof r=="string"&&(r=new RegExp(r)),this.formats[e]=r,this}errorsText(e=this.errors,{separator:r=", ",dataVar:n="data"}={}){return!e||e.length===0?"No errors":e.map(s=>`${n}${s.instancePath} ${s.message}`).reduce((s,i)=>s+r+i)}$dataMetaSchema(e,r){let n=this.RULES.all;e=JSON.parse(JSON.stringify(e));for(let s of r){let i=s.split("/").slice(1),a=e;for(let c of i)a=a[c];for(let c in n){let l=n[c];if(typeof l!="object")continue;let{$data:o}=l.definition,f=a[c];o&&f&&(a[c]=Bl(f))}}return e}_removeAllSchemas(e,r){for(let n in e){let s=e[n];(!r||r.test(n))&&(typeof s=="string"?delete e[n]:s&&!s.meta&&(this._cache.delete(s.schema),delete e[n]))}}_addSchema(e,r,n,s=this.opts.validateSchema,i=this.opts.addUsedSchema){let a,{schemaId:c}=this.opts;if(typeof e=="object")a=e[c];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof e!="boolean")throw new Error("schema must be object or boolean")}let l=this._cache.get(e);if(l!==void 0)return l;n=(0,Pn.normalizeId)(a||n);let o=Pn.getSchemaRefs.call(this,e,n);return l=new Sn.SchemaEnv({schema:e,schemaId:c,meta:r,baseId:n,localRefs:o}),this._cache.set(l.schema,l),i&&!n.startsWith("#")&&(n&&this._checkUnique(n),this.refs[n]=l),s&&this.validateSchema(e,!0),l}_checkUnique(e){if(this.schemas[e]||this.refs[e])throw new Error(`schema with key or id "${e}" already exists`)}_compileSchemaEnv(e){if(e.meta?this._compileMetaSchema(e):Sn.compileSchema.call(this,e),!e.validate)throw new Error("ajv implementation error");return e.validate}_compileMetaSchema(e){let r=this.opts;this.opts=this._metaOpts;try{Sn.compileSchema.call(this,e)}finally{this.opts=r}}};he.default=On;On.ValidationError=e0.default;On.MissingRefError=Kl.default;function Hl(t,e,r,n="error"){for(let s in t){let i=s;i in e&&this.logger[n](`${r}: option ${s}. ${t[i]}`)}}function zl(t){return t=(0,Pn.normalizeId)(t),this.schemas[t]||this.refs[t]}function u0(){let t=this.opts.schemas;if(!!t)if(Array.isArray(t))this.addSchema(t);else for(let e in t)this.addSchema(t[e],e)}function l0(){for(let t in this.opts.formats){let e=this.opts.formats[t];e&&this.addFormat(t,e)}}function f0(t){if(Array.isArray(t)){this.addVocabulary(t);return}this.logger.warn("keywords option as map is deprecated, pass array");for(let e in t){let r=t[e];r.keyword||(r.keyword=e),this.addKeyword(r)}}function d0(){let t={...this.opts};for(let e of s0)delete t[e];return t}var h0={log(){},warn(){},error(){}};function p0(t){if(t===!1)return h0;if(t===void 0)return console;if(t.log&&t.warn&&t.error)return t;throw new Error("logger must implement log, warn and error methods")}var m0=/^[a-z_$][a-z0-9_$:-]*$/i;function v0(t,e){let{RULES:r}=this;if((0,aa.eachItem)(t,n=>{if(r.keywords[n])throw new Error(`Keyword ${n} is already defined`);if(!m0.test(n))throw new Error(`Keyword ${n} has invalid name`)}),!!e&&e.$data&&!("code"in e||"validate"in e))throw new Error('$data keyword must have "code" or "validate" function')}function ia(t,e,r){var n;let s=e==null?void 0:e.post;if(r&&s)throw new Error('keyword with "post" flag cannot have "type"');let{RULES:i}=this,a=s?i.post:i.rules.find(({type:l})=>l===r);if(a||(a={type:r,rules:[]},i.rules.push(a)),i.keywords[t]=!0,!e)return;let c={keyword:t,definition:{...e,type:(0,ys.getJSONTypes)(e.type),schemaType:(0,ys.getJSONTypes)(e.schemaType)}};e.before?g0.call(this,a,c,e.before):a.rules.push(c),i.all[t]=c,(n=e.implements)===null||n===void 0||n.forEach(l=>this.addKeyword(l))}function g0(t,e,r){let n=t.rules.findIndex(s=>s.keyword===r);n>=0?t.rules.splice(n,0,e):(t.rules.push(e),this.logger.warn(`rule ${r} is not defined`))}function y0(t){let{metaSchema:e}=t;e!==void 0&&(t.$data&&this.opts.$data&&(e=Bl(e)),t.validateSchema=this.compile(e,!0))}var _0={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function Bl(t){return{anyOf:[t,_0]}}});var Yl=y(oa=>{"use strict";Object.defineProperty(oa,"__esModule",{value:!0});var $0={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};oa.default=$0});var ef=y(Zt=>{"use strict";Object.defineProperty(Zt,"__esModule",{value:!0});Zt.callRef=Zt.getValidate=void 0;var E0=ps(),Jl=Ge(),qe=M(),Ir=St(),Zl=vs(),_s=H(),w0={keyword:"$ref",schemaType:"string",code(t){let{gen:e,schema:r,it:n}=t,{baseId:s,schemaEnv:i,validateName:a,opts:c,self:l}=n,{root:o}=i;if((r==="#"||r==="#/")&&s===o.baseId)return h();let f=Zl.resolveRef.call(l,o,s,r);if(f===void 0)throw new E0.default(n.opts.uriResolver,s,r);if(f instanceof Zl.SchemaEnv)return _(f);return v(f);function h(){if(i===o)return $s(t,a,i,i.$async);let E=e.scopeValue("root",{ref:o});return $s(t,(0,qe._)`${E}.validate`,o,o.$async)}function _(E){let $=Ql(t,E);$s(t,$,E,E.$async)}function v(E){let $=e.scopeValue("schema",c.code.source===!0?{ref:E,code:(0,qe.stringify)(E)}:{ref:E}),w=e.name("valid"),b=t.subschema({schema:E,dataTypes:[],schemaPath:qe.nil,topSchemaRef:$,errSchemaPath:r},w);t.mergeEvaluated(b),t.ok(w)}}};function Ql(t,e){let{gen:r}=t;return e.validate?r.scopeValue("validate",{ref:e.validate}):(0,qe._)`${r.scopeValue("wrapper",{ref:e})}.validate`}Zt.getValidate=Ql;function $s(t,e,r,n){let{gen:s,it:i}=t,{allErrors:a,schemaEnv:c,opts:l}=i,o=l.passContext?Ir.default.this:qe.nil;n?f():h();function f(){if(!c.$async)throw new Error("async schema referenced by sync schema");let E=s.let("valid");s.try(()=>{s.code((0,qe._)`await ${(0,Jl.callValidateCode)(t,e,o)}`),v(e),a||s.assign(E,!0)},$=>{s.if((0,qe._)`!(${$} instanceof ${i.ValidationError})`,()=>s.throw($)),_($),a||s.assign(E,!1)}),t.ok(E)}function h(){t.result((0,Jl.callValidateCode)(t,e,o),()=>v(e),()=>_(e))}function _(E){let $=(0,qe._)`${E}.errors`;s.assign(Ir.default.vErrors,(0,qe._)`${Ir.default.vErrors} === null ? ${$} : ${Ir.default.vErrors}.concat(${$})`),s.assign(Ir.default.errors,(0,qe._)`${Ir.default.vErrors}.length`)}function v(E){var $;if(!i.opts.unevaluated)return;let w=($=r==null?void 0:r.validate)===null||$===void 0?void 0:$.evaluated;if(i.props!==!0)if(w&&!w.dynamicProps)w.props!==void 0&&(i.props=_s.mergeEvaluated.props(s,w.props,i.props));else{let b=s.var("props",(0,qe._)`${E}.evaluated.props`);i.props=_s.mergeEvaluated.props(s,b,i.props,qe.Name)}if(i.items!==!0)if(w&&!w.dynamicItems)w.items!==void 0&&(i.items=_s.mergeEvaluated.items(s,w.items,i.items));else{let b=s.var("items",(0,qe._)`${E}.evaluated.items`);i.items=_s.mergeEvaluated.items(s,b,i.items,qe.Name)}}}Zt.callRef=$s;Zt.default=w0});var tf=y(ca=>{"use strict";Object.defineProperty(ca,"__esModule",{value:!0});var b0=Yl(),S0=ef(),P0=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",b0.default,S0.default];ca.default=P0});var rf=y(ua=>{"use strict";Object.defineProperty(ua,"__esModule",{value:!0});var Es=M(),Dt=Es.operators,ws={maximum:{okStr:"<=",ok:Dt.LTE,fail:Dt.GT},minimum:{okStr:">=",ok:Dt.GTE,fail:Dt.LT},exclusiveMaximum:{okStr:"<",ok:Dt.LT,fail:Dt.GTE},exclusiveMinimum:{okStr:">",ok:Dt.GT,fail:Dt.LTE}},O0={message:({keyword:t,schemaCode:e})=>(0,Es.str)`must be ${ws[t].okStr} ${e}`,params:({keyword:t,schemaCode:e})=>(0,Es._)`{comparison: ${ws[t].okStr}, limit: ${e}}`},R0={keyword:Object.keys(ws),type:"number",schemaType:"number",$data:!0,error:O0,code(t){let{keyword:e,data:r,schemaCode:n}=t;t.fail$data((0,Es._)`${r} ${ws[e].fail} ${n} || isNaN(${r})`)}};ua.default=R0});var nf=y(la=>{"use strict";Object.defineProperty(la,"__esModule",{value:!0});var Rn=M(),N0={message:({schemaCode:t})=>(0,Rn.str)`must be multiple of ${t}`,params:({schemaCode:t})=>(0,Rn._)`{multipleOf: ${t}}`},I0={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:N0,code(t){let{gen:e,data:r,schemaCode:n,it:s}=t,i=s.opts.multipleOfPrecision,a=e.let("res"),c=i?(0,Rn._)`Math.abs(Math.round(${a}) - ${a}) > 1e-${i}`:(0,Rn._)`${a} !== parseInt(${a})`;t.fail$data((0,Rn._)`(${n} === 0 || (${a} = ${r}/${n}, ${c}))`)}};la.default=I0});var af=y(fa=>{"use strict";Object.defineProperty(fa,"__esModule",{value:!0});function sf(t){let e=t.length,r=0,n=0,s;for(;n<e;)r++,s=t.charCodeAt(n++),s>=55296&&s<=56319&&n<e&&(s=t.charCodeAt(n),(s&64512)===56320&&n++);return r}fa.default=sf;sf.code='require("ajv/dist/runtime/ucs2length").default'});var of=y(da=>{"use strict";Object.defineProperty(da,"__esModule",{value:!0});var Qt=M(),T0=H(),q0=af(),C0={message({keyword:t,schemaCode:e}){let r=t==="maxLength"?"more":"fewer";return(0,Qt.str)`must NOT have ${r} than ${e} characters`},params:({schemaCode:t})=>(0,Qt._)`{limit: ${t}}`},j0={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:C0,code(t){let{keyword:e,data:r,schemaCode:n,it:s}=t,i=e==="maxLength"?Qt.operators.GT:Qt.operators.LT,a=s.opts.unicode===!1?(0,Qt._)`${r}.length`:(0,Qt._)`${(0,T0.useFunc)(t.gen,q0.default)}(${r})`;t.fail$data((0,Qt._)`${a} ${i} ${n}`)}};da.default=j0});var cf=y(ha=>{"use strict";Object.defineProperty(ha,"__esModule",{value:!0});var D0=Ge(),bs=M(),A0={message:({schemaCode:t})=>(0,bs.str)`must match pattern "${t}"`,params:({schemaCode:t})=>(0,bs._)`{pattern: ${t}}`},k0={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:A0,code(t){let{data:e,$data:r,schema:n,schemaCode:s,it:i}=t,a=i.opts.unicodeRegExp?"u":"",c=r?(0,bs._)`(new RegExp(${s}, ${a}))`:(0,D0.usePattern)(t,n);t.fail$data((0,bs._)`!${c}.test(${e})`)}};ha.default=k0});var uf=y(pa=>{"use strict";Object.defineProperty(pa,"__esModule",{value:!0});var Nn=M(),L0={message({keyword:t,schemaCode:e}){let r=t==="maxProperties"?"more":"fewer";return(0,Nn.str)`must NOT have ${r} than ${e} properties`},params:({schemaCode:t})=>(0,Nn._)`{limit: ${t}}`},M0={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:L0,code(t){let{keyword:e,data:r,schemaCode:n}=t,s=e==="maxProperties"?Nn.operators.GT:Nn.operators.LT;t.fail$data((0,Nn._)`Object.keys(${r}).length ${s} ${n}`)}};pa.default=M0});var lf=y(ma=>{"use strict";Object.defineProperty(ma,"__esModule",{value:!0});var In=Ge(),Tn=M(),x0=H(),F0={message:({params:{missingProperty:t}})=>(0,Tn.str)`must have required property '${t}'`,params:({params:{missingProperty:t}})=>(0,Tn._)`{missingProperty: ${t}}`},V0={keyword:"required",type:"object",schemaType:"array",$data:!0,error:F0,code(t){let{gen:e,schema:r,schemaCode:n,data:s,$data:i,it:a}=t,{opts:c}=a;if(!i&&r.length===0)return;let l=r.length>=c.loopRequired;if(a.allErrors?o():f(),c.strictRequired){let v=t.parentSchema.properties,{definedProperties:E}=t.it;for(let $ of r)if((v==null?void 0:v[$])===void 0&&!E.has($)){let w=a.schemaEnv.baseId+a.errSchemaPath,b=`required property "${$}" is not defined at "${w}" (strictRequired)`;(0,x0.checkStrictMode)(a,b,a.opts.strictRequired)}}function o(){if(l||i)t.block$data(Tn.nil,h);else for(let v of r)(0,In.checkReportMissingProp)(t,v)}function f(){let v=e.let("missing");if(l||i){let E=e.let("valid",!0);t.block$data(E,()=>_(v,E)),t.ok(E)}else e.if((0,In.checkMissingProp)(t,r,v)),(0,In.reportMissingProp)(t,v),e.else()}function h(){e.forOf("prop",n,v=>{t.setParams({missingProperty:v}),e.if((0,In.noPropertyInData)(e,s,v,c.ownProperties),()=>t.error())})}function _(v,E){t.setParams({missingProperty:v}),e.forOf(v,n,()=>{e.assign(E,(0,In.propertyInData)(e,s,v,c.ownProperties)),e.if((0,Tn.not)(E),()=>{t.error(),e.break()})},Tn.nil)}}};ma.default=V0});var ff=y(va=>{"use strict";Object.defineProperty(va,"__esModule",{value:!0});var qn=M(),U0={message({keyword:t,schemaCode:e}){let r=t==="maxItems"?"more":"fewer";return(0,qn.str)`must NOT have ${r} than ${e} items`},params:({schemaCode:t})=>(0,qn._)`{limit: ${t}}`},G0={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:U0,code(t){let{keyword:e,data:r,schemaCode:n}=t,s=e==="maxItems"?qn.operators.GT:qn.operators.LT;t.fail$data((0,qn._)`${r}.length ${s} ${n}`)}};va.default=G0});var Ss=y(ga=>{"use strict";Object.defineProperty(ga,"__esModule",{value:!0});var df=Ki();df.code='require("ajv/dist/runtime/equal").default';ga.default=df});var hf=y(_a=>{"use strict";Object.defineProperty(_a,"__esModule",{value:!0});var ya=_n(),pe=M(),H0=H(),z0=Ss(),K0={message:({params:{i:t,j:e}})=>(0,pe.str)`must NOT have duplicate items (items ## ${e} and ${t} are identical)`,params:({params:{i:t,j:e}})=>(0,pe._)`{i: ${t}, j: ${e}}`},X0={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:K0,code(t){let{gen:e,data:r,$data:n,schema:s,parentSchema:i,schemaCode:a,it:c}=t;if(!n&&!s)return;let l=e.let("valid"),o=i.items?(0,ya.getSchemaTypes)(i.items):[];t.block$data(l,f,(0,pe._)`${a} === false`),t.ok(l);function f(){let E=e.let("i",(0,pe._)`${r}.length`),$=e.let("j");t.setParams({i:E,j:$}),e.assign(l,!0),e.if((0,pe._)`${E} > 1`,()=>(h()?_:v)(E,$))}function h(){return o.length>0&&!o.some(E=>E==="object"||E==="array")}function _(E,$){let w=e.name("item"),b=(0,ya.checkDataTypes)(o,w,c.opts.strictNumbers,ya.DataType.Wrong),C=e.const("indices",(0,pe._)`{}`);e.for((0,pe._)`;${E}--;`,()=>{e.let(w,(0,pe._)`${r}[${E}]`),e.if(b,(0,pe._)`continue`),o.length>1&&e.if((0,pe._)`typeof ${w} == "string"`,(0,pe._)`${w} += "_"`),e.if((0,pe._)`typeof ${C}[${w}] == "number"`,()=>{e.assign($,(0,pe._)`${C}[${w}]`),t.error(),e.assign(l,!1).break()}).code((0,pe._)`${C}[${w}] = ${E}`)})}function v(E,$){let w=(0,H0.useFunc)(e,z0.default),b=e.name("outer");e.label(b).for((0,pe._)`;${E}--;`,()=>e.for((0,pe._)`${$} = ${E}; ${$}--;`,()=>e.if((0,pe._)`${w}(${r}[${E}], ${r}[${$}])`,()=>{t.error(),e.assign(l,!1).break(b)})))}}};_a.default=X0});var pf=y(Ea=>{"use strict";Object.defineProperty(Ea,"__esModule",{value:!0});var $a=M(),B0=H(),W0=Ss(),Y0={message:"must be equal to constant",params:({schemaCode:t})=>(0,$a._)`{allowedValue: ${t}}`},J0={keyword:"const",$data:!0,error:Y0,code(t){let{gen:e,data:r,$data:n,schemaCode:s,schema:i}=t;n||i&&typeof i=="object"?t.fail$data((0,$a._)`!${(0,B0.useFunc)(e,W0.default)}(${r}, ${s})`):t.fail((0,$a._)`${i} !== ${r}`)}};Ea.default=J0});var mf=y(wa=>{"use strict";Object.defineProperty(wa,"__esModule",{value:!0});var Cn=M(),Z0=H(),Q0=Ss(),e_={message:"must be equal to one of the allowed values",params:({schemaCode:t})=>(0,Cn._)`{allowedValues: ${t}}`},t_={keyword:"enum",schemaType:"array",$data:!0,error:e_,code(t){let{gen:e,data:r,$data:n,schema:s,schemaCode:i,it:a}=t;if(!n&&s.length===0)throw new Error("enum must have non-empty array");let c=s.length>=a.opts.loopEnum,l,o=()=>l!=null?l:l=(0,Z0.useFunc)(e,Q0.default),f;if(c||n)f=e.let("valid"),t.block$data(f,h);else{if(!Array.isArray(s))throw new Error("ajv implementation error");let v=e.const("vSchema",i);f=(0,Cn.or)(...s.map((E,$)=>_(v,$)))}t.pass(f);function h(){e.assign(f,!1),e.forOf("v",i,v=>e.if((0,Cn._)`${o()}(${r}, ${v})`,()=>e.assign(f,!0).break()))}function _(v,E){let $=s[E];return typeof $=="object"&&$!==null?(0,Cn._)`${o()}(${r}, ${v}[${E}])`:(0,Cn._)`${r} === ${$}`}}};wa.default=t_});var vf=y(ba=>{"use strict";Object.defineProperty(ba,"__esModule",{value:!0});var r_=rf(),n_=nf(),s_=of(),i_=cf(),a_=uf(),o_=lf(),c_=ff(),u_=hf(),l_=pf(),f_=mf(),d_=[r_.default,n_.default,s_.default,i_.default,a_.default,o_.default,c_.default,u_.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},l_.default,f_.default];ba.default=d_});var Pa=y(jn=>{"use strict";Object.defineProperty(jn,"__esModule",{value:!0});jn.validateAdditionalItems=void 0;var er=M(),Sa=H(),h_={message:({params:{len:t}})=>(0,er.str)`must NOT have more than ${t} items`,params:({params:{len:t}})=>(0,er._)`{limit: ${t}}`},p_={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:h_,code(t){let{parentSchema:e,it:r}=t,{items:n}=e;if(!Array.isArray(n)){(0,Sa.checkStrictMode)(r,'"additionalItems" is ignored when "items" is not an array of schemas');return}gf(t,n)}};function gf(t,e){let{gen:r,schema:n,data:s,keyword:i,it:a}=t;a.items=!0;let c=r.const("len",(0,er._)`${s}.length`);if(n===!1)t.setParams({len:e.length}),t.pass((0,er._)`${c} <= ${e.length}`);else if(typeof n=="object"&&!(0,Sa.alwaysValidSchema)(a,n)){let o=r.var("valid",(0,er._)`${c} <= ${e.length}`);r.if((0,er.not)(o),()=>l(o)),t.ok(o)}function l(o){r.forRange("i",e.length,c,f=>{t.subschema({keyword:i,dataProp:f,dataPropType:Sa.Type.Num},o),a.allErrors||r.if((0,er.not)(o),()=>r.break())})}}jn.validateAdditionalItems=gf;jn.default=p_});var Oa=y(Dn=>{"use strict";Object.defineProperty(Dn,"__esModule",{value:!0});Dn.validateTuple=void 0;var yf=M(),Ps=H(),m_=Ge(),v_={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(t){let{schema:e,it:r}=t;if(Array.isArray(e))return _f(t,"additionalItems",e);r.items=!0,!(0,Ps.alwaysValidSchema)(r,e)&&t.ok((0,m_.validateArray)(t))}};function _f(t,e,r=t.schema){let{gen:n,parentSchema:s,data:i,keyword:a,it:c}=t;f(s),c.opts.unevaluated&&r.length&&c.items!==!0&&(c.items=Ps.mergeEvaluated.items(n,r.length,c.items));let l=n.name("valid"),o=n.const("len",(0,yf._)`${i}.length`);r.forEach((h,_)=>{(0,Ps.alwaysValidSchema)(c,h)||(n.if((0,yf._)`${o} > ${_}`,()=>t.subschema({keyword:a,schemaProp:_,dataProp:_},l)),t.ok(l))});function f(h){let{opts:_,errSchemaPath:v}=c,E=r.length,$=E===h.minItems&&(E===h.maxItems||h[e]===!1);if(_.strictTuples&&!$){let w=`"${a}" is ${E}-tuple, but minItems or maxItems/${e} are not specified or different at path "${v}"`;(0,Ps.checkStrictMode)(c,w,_.strictTuples)}}}Dn.validateTuple=_f;Dn.default=v_});var $f=y(Ra=>{"use strict";Object.defineProperty(Ra,"__esModule",{value:!0});var g_=Oa(),y_={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:t=>(0,g_.validateTuple)(t,"items")};Ra.default=y_});var wf=y(Na=>{"use strict";Object.defineProperty(Na,"__esModule",{value:!0});var Ef=M(),__=H(),$_=Ge(),E_=Pa(),w_={message:({params:{len:t}})=>(0,Ef.str)`must NOT have more than ${t} items`,params:({params:{len:t}})=>(0,Ef._)`{limit: ${t}}`},b_={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:w_,code(t){let{schema:e,parentSchema:r,it:n}=t,{prefixItems:s}=r;n.items=!0,!(0,__.alwaysValidSchema)(n,e)&&(s?(0,E_.validateAdditionalItems)(t,s):t.ok((0,$_.validateArray)(t)))}};Na.default=b_});var bf=y(Ia=>{"use strict";Object.defineProperty(Ia,"__esModule",{value:!0});var ze=M(),Os=H(),S_={message:({params:{min:t,max:e}})=>e===void 0?(0,ze.str)`must contain at least ${t} valid item(s)`:(0,ze.str)`must contain at least ${t} and no more than ${e} valid item(s)`,params:({params:{min:t,max:e}})=>e===void 0?(0,ze._)`{minContains: ${t}}`:(0,ze._)`{minContains: ${t}, maxContains: ${e}}`},P_={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:S_,code(t){let{gen:e,schema:r,parentSchema:n,data:s,it:i}=t,a,c,{minContains:l,maxContains:o}=n;i.opts.next?(a=l===void 0?1:l,c=o):a=1;let f=e.const("len",(0,ze._)`${s}.length`);if(t.setParams({min:a,max:c}),c===void 0&&a===0){(0,Os.checkStrictMode)(i,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(c!==void 0&&a>c){(0,Os.checkStrictMode)(i,'"minContains" > "maxContains" is always invalid'),t.fail();return}if((0,Os.alwaysValidSchema)(i,r)){let $=(0,ze._)`${f} >= ${a}`;c!==void 0&&($=(0,ze._)`${$} && ${f} <= ${c}`),t.pass($);return}i.items=!0;let h=e.name("valid");c===void 0&&a===1?v(h,()=>e.if(h,()=>e.break())):a===0?(e.let(h,!0),c!==void 0&&e.if((0,ze._)`${s}.length > 0`,_)):(e.let(h,!1),_()),t.result(h,()=>t.reset());function _(){let $=e.name("_valid"),w=e.let("count",0);v($,()=>e.if($,()=>E(w)))}function v($,w){e.forRange("i",0,f,b=>{t.subschema({keyword:"contains",dataProp:b,dataPropType:Os.Type.Num,compositeRule:!0},$),w()})}function E($){e.code((0,ze._)`${$}++`),c===void 0?e.if((0,ze._)`${$} >= ${a}`,()=>e.assign(h,!0).break()):(e.if((0,ze._)`${$} > ${c}`,()=>e.assign(h,!1).break()),a===1?e.assign(h,!0):e.if((0,ze._)`${$} >= ${a}`,()=>e.assign(h,!0)))}}};Ia.default=P_});var Of=y(ut=>{"use strict";Object.defineProperty(ut,"__esModule",{value:!0});ut.validateSchemaDeps=ut.validatePropertyDeps=ut.error=void 0;var Ta=M(),O_=H(),An=Ge();ut.error={message:({params:{property:t,depsCount:e,deps:r}})=>{let n=e===1?"property":"properties";return(0,Ta.str)`must have ${n} ${r} when property ${t} is present`},params:({params:{property:t,depsCount:e,deps:r,missingProperty:n}})=>(0,Ta._)`{property: ${t},
|
|
26
12
|
missingProperty: ${n},
|
|
27
13
|
depsCount: ${e},
|
|
28
|
-
deps: ${t}}`};var z0={keyword:"dependencies",type:"object",schemaType:"object",error:ct.error,code(r){let[e,t]=K0(r);Mf(r,e),Ff(r,t)}};function K0({schema:r}){let e={},t={};for(let n in r){if(n==="__proto__")continue;let s=Array.isArray(r[n])?e:t;s[n]=r[n]}return[e,t]}function Mf(r,e=r.schema){let{gen:t,data:n,it:s}=r;if(Object.keys(e).length===0)return;let i=t.let("missing");for(let a in e){let c=e[a];if(c.length===0)continue;let u=(0,xn.propertyInData)(t,n,a,s.opts.ownProperties);r.setParams({property:a,depsCount:c.length,deps:c.join(", ")}),s.allErrors?t.if(u,()=>{for(let o of c)(0,xn.checkReportMissingProp)(r,o)}):(t.if((0,ka._)`${u} && (${(0,xn.checkMissingProp)(r,c,i)})`),(0,xn.reportMissingProp)(r,i),t.else())}}ct.validatePropertyDeps=Mf;function Ff(r,e=r.schema){let{gen:t,data:n,keyword:s,it:i}=r,a=t.name("valid");for(let c in e)(0,G0.alwaysValidSchema)(i,e[c])||(t.if((0,xn.propertyInData)(t,n,c,i.opts.ownProperties),()=>{let u=r.subschema({keyword:s,schemaProp:c},a);r.mergeValidEvaluated(u,a)},()=>t.var(a,!0)),r.ok(a))}ct.validateSchemaDeps=Ff;ct.default=z0});var Uf=_(xa=>{"use strict";Object.defineProperty(xa,"__esModule",{value:!0});var Hf=L(),X0=G(),W0={message:"property name must be valid",params:({params:r})=>(0,Hf._)`{propertyName: ${r.propertyName}}`},B0={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:W0,code(r){let{gen:e,schema:t,data:n,it:s}=r;if((0,X0.alwaysValidSchema)(s,t))return;let i=e.name("valid");e.forIn("key",n,a=>{r.setParams({propertyName:a}),r.subschema({keyword:"propertyNames",data:a,dataTypes:["string"],propertyName:a,compositeRule:!0},i),e.if((0,Hf.not)(i),()=>{r.error(!0),s.allErrors||e.break()})}),r.ok(i)}};xa.default=B0});var Ma=_(La=>{"use strict";Object.defineProperty(La,"__esModule",{value:!0});var Ns=ze(),Qe=L(),J0=$t(),Is=G(),Y0={message:"must NOT have additional properties",params:({params:r})=>(0,Qe._)`{additionalProperty: ${r.additionalProperty}}`},Z0={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:Y0,code(r){let{gen:e,schema:t,parentSchema:n,data:s,errsCount:i,it:a}=r;if(!i)throw new Error("ajv implementation error");let{allErrors:c,opts:u}=a;if(a.props=!0,u.removeAdditional!=="all"&&(0,Is.alwaysValidSchema)(a,t))return;let o=(0,Ns.allSchemaProperties)(n.properties),l=(0,Ns.allSchemaProperties)(n.patternProperties);d(),r.ok((0,Qe._)`${i} === ${J0.default.errors}`);function d(){e.forIn("key",s,w=>{!o.length&&!l.length?$(w):e.if(y(w),()=>$(w))})}function y(w){let b;if(o.length>8){let D=(0,Is.schemaRefOrVal)(a,n.properties,"properties");b=(0,Ns.isOwnProperty)(e,D,w)}else o.length?b=(0,Qe.or)(...o.map(D=>(0,Qe._)`${w} === ${D}`)):b=Qe.nil;return l.length&&(b=(0,Qe.or)(b,...l.map(D=>(0,Qe._)`${(0,Ns.usePattern)(r,D)}.test(${w})`))),(0,Qe.not)(b)}function m(w){e.code((0,Qe._)`delete ${s}[${w}]`)}function $(w){if(u.removeAdditional==="all"||u.removeAdditional&&t===!1){m(w);return}if(t===!1){r.setParams({additionalProperty:w}),r.error(),c||e.break();return}if(typeof t=="object"&&!(0,Is.alwaysValidSchema)(a,t)){let b=e.name("valid");u.removeAdditional==="failing"?(E(w,b,!1),e.if((0,Qe.not)(b),()=>{r.reset(),m(w)})):(E(w,b),c||e.if((0,Qe.not)(b),()=>e.break()))}}function E(w,b,D){let T={keyword:"additionalProperties",dataProp:w,dataPropType:Is.Type.Str};D===!1&&Object.assign(T,{compositeRule:!0,createErrors:!1,allErrors:!1}),r.subschema(T,b)}}};La.default=Z0});var Kf=_(Va=>{"use strict";Object.defineProperty(Va,"__esModule",{value:!0});var Q0=On(),Gf=ze(),Fa=G(),zf=Ma(),e$={keyword:"properties",type:"object",schemaType:"object",code(r){let{gen:e,schema:t,parentSchema:n,data:s,it:i}=r;i.opts.removeAdditional==="all"&&n.additionalProperties===void 0&&zf.default.code(new Q0.KeywordCxt(i,zf.default,"additionalProperties"));let a=(0,Gf.allSchemaProperties)(t);for(let d of a)i.definedProperties.add(d);i.opts.unevaluated&&a.length&&i.props!==!0&&(i.props=Fa.mergeEvaluated.props(e,(0,Fa.toHash)(a),i.props));let c=a.filter(d=>!(0,Fa.alwaysValidSchema)(i,t[d]));if(c.length===0)return;let u=e.name("valid");for(let d of c)o(d)?l(d):(e.if((0,Gf.propertyInData)(e,s,d,i.opts.ownProperties)),l(d),i.allErrors||e.else().var(u,!0),e.endIf()),r.it.definedProperties.add(d),r.ok(u);function o(d){return i.opts.useDefaults&&!i.compositeRule&&t[d].default!==void 0}function l(d){r.subschema({keyword:"properties",schemaProp:d,dataProp:d},u)}}};Va.default=e$});var Jf=_(Ha=>{"use strict";Object.defineProperty(Ha,"__esModule",{value:!0});var Xf=ze(),Ts=L(),Wf=G(),Bf=G(),t$={keyword:"patternProperties",type:"object",schemaType:"object",code(r){let{gen:e,schema:t,data:n,parentSchema:s,it:i}=r,{opts:a}=i,c=(0,Xf.allSchemaProperties)(t),u=c.filter(E=>(0,Wf.alwaysValidSchema)(i,t[E]));if(c.length===0||u.length===c.length&&(!i.opts.unevaluated||i.props===!0))return;let o=a.strictSchema&&!a.allowMatchingProperties&&s.properties,l=e.name("valid");i.props!==!0&&!(i.props instanceof Ts.Name)&&(i.props=(0,Bf.evaluatedPropsToName)(e,i.props));let{props:d}=i;y();function y(){for(let E of c)o&&m(E),i.allErrors?$(E):(e.var(l,!0),$(E),e.if(l))}function m(E){for(let w in o)new RegExp(E).test(w)&&(0,Wf.checkStrictMode)(i,`property ${w} matches pattern ${E} (use allowMatchingProperties)`)}function $(E){e.forIn("key",n,w=>{e.if((0,Ts._)`${(0,Xf.usePattern)(r,E)}.test(${w})`,()=>{let b=u.includes(E);b||r.subschema({keyword:"patternProperties",schemaProp:E,dataProp:w,dataPropType:Bf.Type.Str},l),i.opts.unevaluated&&d!==!0?e.assign((0,Ts._)`${d}[${w}]`,!0):!b&&!i.allErrors&&e.if((0,Ts.not)(l),()=>e.break())})})}}};Ha.default=t$});var Yf=_(Ua=>{"use strict";Object.defineProperty(Ua,"__esModule",{value:!0});var r$=G(),n$={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(r){let{gen:e,schema:t,it:n}=r;if((0,r$.alwaysValidSchema)(n,t)){r.fail();return}let s=e.name("valid");r.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},s),r.failResult(s,()=>r.reset(),()=>r.error())},error:{message:"must NOT be valid"}};Ua.default=n$});var Zf=_(Ga=>{"use strict";Object.defineProperty(Ga,"__esModule",{value:!0});var s$=ze(),i$={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:s$.validateUnion,error:{message:"must match a schema in anyOf"}};Ga.default=i$});var Qf=_(za=>{"use strict";Object.defineProperty(za,"__esModule",{value:!0});var As=L(),a$=G(),o$={message:"must match exactly one schema in oneOf",params:({params:r})=>(0,As._)`{passingSchemas: ${r.passing}}`},c$={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:o$,code(r){let{gen:e,schema:t,parentSchema:n,it:s}=r;if(!Array.isArray(t))throw new Error("ajv implementation error");if(s.opts.discriminator&&n.discriminator)return;let i=t,a=e.let("valid",!1),c=e.let("passing",null),u=e.name("_valid");r.setParams({passing:c}),e.block(o),r.result(a,()=>r.reset(),()=>r.error(!0));function o(){i.forEach((l,d)=>{let y;(0,a$.alwaysValidSchema)(s,l)?e.var(u,!0):y=r.subschema({keyword:"oneOf",schemaProp:d,compositeRule:!0},u),d>0&&e.if((0,As._)`${u} && ${a}`).assign(a,!1).assign(c,(0,As._)`[${c}, ${d}]`).else(),e.if(u,()=>{e.assign(a,!0),e.assign(c,d),y&&r.mergeEvaluated(y,As.Name)})})}}};za.default=c$});var ed=_(Ka=>{"use strict";Object.defineProperty(Ka,"__esModule",{value:!0});var u$=G(),l$={keyword:"allOf",schemaType:"array",code(r){let{gen:e,schema:t,it:n}=r;if(!Array.isArray(t))throw new Error("ajv implementation error");let s=e.name("valid");t.forEach((i,a)=>{if((0,u$.alwaysValidSchema)(n,i))return;let c=r.subschema({keyword:"allOf",schemaProp:a},s);r.ok(s),r.mergeEvaluated(c)})}};Ka.default=l$});var nd=_(Xa=>{"use strict";Object.defineProperty(Xa,"__esModule",{value:!0});var qs=L(),rd=G(),f$={message:({params:r})=>(0,qs.str)`must match "${r.ifClause}" schema`,params:({params:r})=>(0,qs._)`{failingKeyword: ${r.ifClause}}`},d$={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:f$,code(r){let{gen:e,parentSchema:t,it:n}=r;t.then===void 0&&t.else===void 0&&(0,rd.checkStrictMode)(n,'"if" without "then" and "else" is ignored');let s=td(n,"then"),i=td(n,"else");if(!s&&!i)return;let a=e.let("valid",!0),c=e.name("_valid");if(u(),r.reset(),s&&i){let l=e.let("ifClause");r.setParams({ifClause:l}),e.if(c,o("then",l),o("else",l))}else s?e.if(c,o("then")):e.if((0,qs.not)(c),o("else"));r.pass(a,()=>r.error(!0));function u(){let l=r.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},c);r.mergeEvaluated(l)}function o(l,d){return()=>{let y=r.subschema({keyword:l},c);e.assign(a,c),r.mergeValidEvaluated(y,a),d?e.assign(d,(0,qs._)`${l}`):r.setParams({ifClause:l})}}}};function td(r,e){let t=r.schema[e];return t!==void 0&&!(0,rd.alwaysValidSchema)(r,t)}Xa.default=d$});var sd=_(Wa=>{"use strict";Object.defineProperty(Wa,"__esModule",{value:!0});var h$=G(),p$={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:r,parentSchema:e,it:t}){e.if===void 0&&(0,h$.checkStrictMode)(t,`"${r}" without "if" is ignored`)}};Wa.default=p$});var id=_(Ba=>{"use strict";Object.defineProperty(Ba,"__esModule",{value:!0});var m$=Ta(),g$=jf(),v$=Aa(),_$=xf(),y$=Lf(),$$=Vf(),E$=Uf(),w$=Ma(),b$=Kf(),S$=Jf(),O$=Yf(),P$=Zf(),R$=Qf(),C$=ed(),N$=nd(),I$=sd();function T$(r=!1){let e=[O$.default,P$.default,R$.default,C$.default,N$.default,I$.default,E$.default,w$.default,$$.default,b$.default,S$.default];return r?e.push(g$.default,_$.default):e.push(m$.default,v$.default),e.push(y$.default),e}Ba.default=T$});var ad=_(Ja=>{"use strict";Object.defineProperty(Ja,"__esModule",{value:!0});var oe=L(),A$={message:({schemaCode:r})=>(0,oe.str)`must match format "${r}"`,params:({schemaCode:r})=>(0,oe._)`{format: ${r}}`},q$={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:A$,code(r,e){let{gen:t,data:n,$data:s,schema:i,schemaCode:a,it:c}=r,{opts:u,errSchemaPath:o,schemaEnv:l,self:d}=c;if(!u.validateFormats)return;s?y():m();function y(){let $=t.scopeValue("formats",{ref:d.formats,code:u.code.formats}),E=t.const("fDef",(0,oe._)`${$}[${a}]`),w=t.let("fType"),b=t.let("format");t.if((0,oe._)`typeof ${E} == "object" && !(${E} instanceof RegExp)`,()=>t.assign(w,(0,oe._)`${E}.type || "string"`).assign(b,(0,oe._)`${E}.validate`),()=>t.assign(w,(0,oe._)`"string"`).assign(b,E)),r.fail$data((0,oe.or)(D(),T()));function D(){return u.strictSchema===!1?oe.nil:(0,oe._)`${a} && !${b}`}function T(){let z=l.$async?(0,oe._)`(${E}.async ? await ${b}(${n}) : ${b}(${n}))`:(0,oe._)`${b}(${n})`,C=(0,oe._)`(typeof ${b} == "function" ? ${z} : ${b}.test(${n}))`;return(0,oe._)`${b} && ${b} !== true && ${w} === ${e} && !${C}`}}function m(){let $=d.formats[i];if(!$){D();return}if($===!0)return;let[E,w,b]=T($);E===e&&r.pass(z());function D(){if(u.strictSchema===!1){d.logger.warn(C());return}throw new Error(C());function C(){return`unknown format "${i}" ignored in schema at path "${o}"`}}function T(C){let me=C instanceof RegExp?(0,oe.regexpCode)(C):u.code.formats?(0,oe._)`${u.code.formats}${(0,oe.getProperty)(i)}`:void 0,ke=t.scopeValue("formats",{key:i,ref:C,code:me});return typeof C=="object"&&!(C instanceof RegExp)?[C.type||"string",C.validate,(0,oe._)`${ke}.validate`]:["string",C,ke]}function z(){if(typeof $=="object"&&!($ instanceof RegExp)&&$.async){if(!l.$async)throw new Error("async format in sync schema");return(0,oe._)`await ${b}(${n})`}return typeof w=="function"?(0,oe._)`${b}(${n})`:(0,oe._)`${b}.test(${n})`}}}};Ja.default=q$});var od=_(Ya=>{"use strict";Object.defineProperty(Ya,"__esModule",{value:!0});var D$=ad(),j$=[D$.default];Ya.default=j$});var cd=_(Ir=>{"use strict";Object.defineProperty(Ir,"__esModule",{value:!0});Ir.contentVocabulary=Ir.metadataVocabulary=void 0;Ir.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];Ir.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]});var ld=_(Za=>{"use strict";Object.defineProperty(Za,"__esModule",{value:!0});var k$=vf(),x$=Tf(),L$=id(),M$=od(),ud=cd(),F$=[k$.default,x$.default,(0,L$.default)(),M$.default,ud.metadataVocabulary,ud.contentVocabulary];Za.default=F$});var fd=_(Ln=>{"use strict";Object.defineProperty(Ln,"__esModule",{value:!0});Ln.DiscrError=void 0;var V$;(function(r){r.Tag="tag",r.Mapping="mapping"})(V$=Ln.DiscrError||(Ln.DiscrError={}))});var hd=_(eo=>{"use strict";Object.defineProperty(eo,"__esModule",{value:!0});var Tr=L(),Qa=fd(),dd=_s(),H$=G(),U$={message:({params:{discrError:r,tagName:e}})=>r===Qa.DiscrError.Tag?`tag "${e}" must be string`:`value of tag "${e}" must be in oneOf`,params:({params:{discrError:r,tag:e,tagName:t}})=>(0,Tr._)`{error: ${r}, tag: ${t}, tagValue: ${e}}`},G$={keyword:"discriminator",type:"object",schemaType:"object",error:U$,code(r){let{gen:e,data:t,schema:n,parentSchema:s,it:i}=r,{oneOf:a}=s;if(!i.opts.discriminator)throw new Error("discriminator: requires discriminator option");let c=n.propertyName;if(typeof c!="string")throw new Error("discriminator: requires propertyName");if(n.mapping)throw new Error("discriminator: mapping is not supported");if(!a)throw new Error("discriminator: requires oneOf keyword");let u=e.let("valid",!1),o=e.const("tag",(0,Tr._)`${t}${(0,Tr.getProperty)(c)}`);e.if((0,Tr._)`typeof ${o} == "string"`,()=>l(),()=>r.error(!1,{discrError:Qa.DiscrError.Tag,tag:o,tagName:c})),r.ok(u);function l(){let m=y();e.if(!1);for(let $ in m)e.elseIf((0,Tr._)`${o} === ${$}`),e.assign(u,d(m[$]));e.else(),r.error(!1,{discrError:Qa.DiscrError.Mapping,tag:o,tagName:c}),e.endIf()}function d(m){let $=e.name("valid"),E=r.subschema({keyword:"oneOf",schemaProp:m},$);return r.mergeEvaluated(E,Tr.Name),$}function y(){var m;let $={},E=b(s),w=!0;for(let z=0;z<a.length;z++){let C=a[z];(C==null?void 0:C.$ref)&&!(0,H$.schemaHasRulesButRef)(C,i.self.RULES)&&(C=dd.resolveRef.call(i.self,i.schemaEnv.root,i.baseId,C==null?void 0:C.$ref),C instanceof dd.SchemaEnv&&(C=C.schema));let me=(m=C==null?void 0:C.properties)===null||m===void 0?void 0:m[c];if(typeof me!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${c}"`);w=w&&(E||b(C)),D(me,z)}if(!w)throw new Error(`discriminator: "${c}" must be required`);return $;function b({required:z}){return Array.isArray(z)&&z.includes(c)}function D(z,C){if(z.const)T(z.const,C);else if(z.enum)for(let me of z.enum)T(me,C);else throw new Error(`discriminator: "properties/${c}" must have "const" or "enum"`)}function T(z,C){if(typeof z!="string"||z in $)throw new Error(`discriminator: "${c}" values must be unique strings`);$[z]=C}}}};eo.default=G$});var pd=_((OS,z$)=>{z$.exports={$schema:"http://json-schema.org/draft-07/schema#",$id:"http://json-schema.org/draft-07/schema#",title:"Core schema meta-schema",definitions:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},type:["object","boolean"],properties:{$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},default:!0}});var vd=_((le,gd)=>{"use strict";Object.defineProperty(le,"__esModule",{value:!0});le.CodeGen=le.Name=le.nil=le.stringify=le.str=le._=le.KeywordCxt=void 0;var K$=ff(),X$=ld(),W$=hd(),md=pd(),B$=["/properties"],Ds="http://json-schema.org/draft-07/schema",js=class extends K$.default{_addVocabularies(){super._addVocabularies(),X$.default.forEach(e=>this.addVocabulary(e)),this.opts.discriminator&&this.addKeyword(W$.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;let e=this.opts.$data?this.$dataMetaSchema(md,B$):md;this.addMetaSchema(e,Ds,!1),this.refs["http://json-schema.org/schema"]=Ds}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(Ds)?Ds:void 0)}};gd.exports=le=js;Object.defineProperty(le,"__esModule",{value:!0});le.default=js;var J$=On();Object.defineProperty(le,"KeywordCxt",{enumerable:!0,get:function(){return J$.KeywordCxt}});var Ar=L();Object.defineProperty(le,"_",{enumerable:!0,get:function(){return Ar._}});Object.defineProperty(le,"str",{enumerable:!0,get:function(){return Ar.str}});Object.defineProperty(le,"stringify",{enumerable:!0,get:function(){return Ar.stringify}});Object.defineProperty(le,"nil",{enumerable:!0,get:function(){return Ar.nil}});Object.defineProperty(le,"Name",{enumerable:!0,get:function(){return Ar.Name}});Object.defineProperty(le,"CodeGen",{enumerable:!0,get:function(){return Ar.CodeGen}})});var er=_(qr=>{"use strict";var Y$=qr&&qr.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(qr,"__esModule",{value:!0});qr.ServerlessError=void 0;var Z$=Y$(vt()),Q$=Z$.default.Logger,eE=new Q$("S-CLI-ERROR"),tE=function(){function r(e,t,n){eE.error(e+": "+t,n),process.exit(1)}return r}();qr.ServerlessError=tE});var _d=_(Dr=>{"use strict";var rE=Dr&&Dr.__extends||function(){var r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,s){n.__proto__=s}||function(n,s){for(var i in s)Object.prototype.hasOwnProperty.call(s,i)&&(n[i]=s[i])},r(e,t)};return function(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");r(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}}();Object.defineProperty(Dr,"__esModule",{value:!0});Dr.CommandError=void 0;var nE=er(),sE=function(r){rE(e,r);function e(t,n){return r.call(this,"Error",t,n)||this}return e}(nE.ServerlessError);Dr.CommandError=sE});var yd=_(jr=>{"use strict";var iE=jr&&jr.__extends||function(){var r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,s){n.__proto__=s}||function(n,s){for(var i in s)Object.prototype.hasOwnProperty.call(s,i)&&(n[i]=s[i])},r(e,t)};return function(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");r(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}}();Object.defineProperty(jr,"__esModule",{value:!0});jr.ConfigDeleteError=void 0;var aE=er(),oE=function(r){iE(e,r);function e(t,n){return r.call(this,"Deletion failed",t,n)||this}return e}(aE.ServerlessError);jr.ConfigDeleteError=oE});var $d=_(kr=>{"use strict";var cE=kr&&kr.__extends||function(){var r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,s){n.__proto__=s}||function(n,s){for(var i in s)Object.prototype.hasOwnProperty.call(s,i)&&(n[i]=s[i])},r(e,t)};return function(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");r(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}}();Object.defineProperty(kr,"__esModule",{value:!0});kr.ConfigError=void 0;var uE=er(),lE=function(r){cE(e,r);function e(t,n){return r.call(this,"Config failed",t,n)||this}return e}(uE.ServerlessError);kr.ConfigError=lE});var Ed=_(xr=>{"use strict";var fE=xr&&xr.__extends||function(){var r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,s){n.__proto__=s}||function(n,s){for(var i in s)Object.prototype.hasOwnProperty.call(s,i)&&(n[i]=s[i])},r(e,t)};return function(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");r(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}}();Object.defineProperty(xr,"__esModule",{value:!0});xr.ConfigGetError=void 0;var dE=er(),hE=function(r){fE(e,r);function e(t,n){return r.call(this,"Get failed",t,n)||this}return e}(dE.ServerlessError);xr.ConfigGetError=hE});var wd=_(Lr=>{"use strict";var pE=Lr&&Lr.__extends||function(){var r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,s){n.__proto__=s}||function(n,s){for(var i in s)Object.prototype.hasOwnProperty.call(s,i)&&(n[i]=s[i])},r(e,t)};return function(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");r(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}}();Object.defineProperty(Lr,"__esModule",{value:!0});Lr.InitError=void 0;var mE=er(),gE=function(r){pE(e,r);function e(t,n){return r.call(this,"Initialization failed",t,n)||this}return e}(mE.ServerlessError);Lr.InitError=gE});var Sd=_(ut=>{"use strict";var vE=ut&&ut.__awaiter||function(r,e,t,n){function s(i){return i instanceof t?i:new t(function(a){a(i)})}return new(t||(t=Promise))(function(i,a){function c(l){try{o(n.next(l))}catch(d){a(d)}}function u(l){try{o(n.throw(l))}catch(d){a(d)}}function o(l){l.done?i(l.value):s(l.value).then(c,u)}o((n=n.apply(r,e||[])).next())})},_E=ut&&ut.__generator||function(r,e){var t={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,s,i,a;return a={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function c(o){return function(l){return u([o,l])}}function u(o){if(n)throw new TypeError("Generator is already executing.");for(;t;)try{if(n=1,s&&(i=o[0]&2?s.return:o[0]?s.throw||((i=s.return)&&i.call(s),0):s.next)&&!(i=i.call(s,o[1])).done)return i;switch(s=0,i&&(o=[o[0]&2,i.value]),o[0]){case 0:case 1:i=o;break;case 4:return t.label++,{value:o[1],done:!1};case 5:t.label++,s=o[1],o=[0];continue;case 7:o=t.ops.pop(),t.trys.pop();continue;default:if(i=t.trys,!(i=i.length>0&&i[i.length-1])&&(o[0]===6||o[0]===2)){t=0;continue}if(o[0]===3&&(!i||o[1]>i[0]&&o[1]<i[3])){t.label=o[1];break}if(o[0]===6&&t.label<i[1]){t.label=i[1],i=o;break}if(i&&t.label<i[2]){t.label=i[2],t.ops.push(o);break}i[2]&&t.ops.pop(),t.trys.pop();continue}o=e.call(r,t)}catch(l){o=[6,l],s=0}finally{n=i=0}if(o[0]&5)throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}},yE=ut&&ut.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ut,"__esModule",{value:!0});ut.HumanError=void 0;var bd=yE(vt()),ks=ln(),$E=bd.default.colors,EE=function(){function r(e){var t=e.errorMessage,n=e.tips;this.errorMessage=t,ks.logger.log(`
|
|
29
|
-
`.concat((0,
|
|
30
|
-
`)),n&&
|
|
31
|
-
`))}return
|
|
32
|
-
`.concat(
|
|
33
|
-
`)),n&&
|
|
34
|
-
`))}return
|
|
35
|
-
`):"",
|
|
14
|
+
deps: ${r}}`};var R_={keyword:"dependencies",type:"object",schemaType:"object",error:ut.error,code(t){let[e,r]=N_(t);Sf(t,e),Pf(t,r)}};function N_({schema:t}){let e={},r={};for(let n in t){if(n==="__proto__")continue;let s=Array.isArray(t[n])?e:r;s[n]=t[n]}return[e,r]}function Sf(t,e=t.schema){let{gen:r,data:n,it:s}=t;if(Object.keys(e).length===0)return;let i=r.let("missing");for(let a in e){let c=e[a];if(c.length===0)continue;let l=(0,An.propertyInData)(r,n,a,s.opts.ownProperties);t.setParams({property:a,depsCount:c.length,deps:c.join(", ")}),s.allErrors?r.if(l,()=>{for(let o of c)(0,An.checkReportMissingProp)(t,o)}):(r.if((0,Ta._)`${l} && (${(0,An.checkMissingProp)(t,c,i)})`),(0,An.reportMissingProp)(t,i),r.else())}}ut.validatePropertyDeps=Sf;function Pf(t,e=t.schema){let{gen:r,data:n,keyword:s,it:i}=t,a=r.name("valid");for(let c in e)(0,O_.alwaysValidSchema)(i,e[c])||(r.if((0,An.propertyInData)(r,n,c,i.opts.ownProperties),()=>{let l=t.subschema({keyword:s,schemaProp:c},a);t.mergeValidEvaluated(l,a)},()=>r.var(a,!0)),t.ok(a))}ut.validateSchemaDeps=Pf;ut.default=R_});var Nf=y(qa=>{"use strict";Object.defineProperty(qa,"__esModule",{value:!0});var Rf=M(),I_=H(),T_={message:"property name must be valid",params:({params:t})=>(0,Rf._)`{propertyName: ${t.propertyName}}`},q_={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:T_,code(t){let{gen:e,schema:r,data:n,it:s}=t;if((0,I_.alwaysValidSchema)(s,r))return;let i=e.name("valid");e.forIn("key",n,a=>{t.setParams({propertyName:a}),t.subschema({keyword:"propertyNames",data:a,dataTypes:["string"],propertyName:a,compositeRule:!0},i),e.if((0,Rf.not)(i),()=>{t.error(!0),s.allErrors||e.break()})}),t.ok(i)}};qa.default=q_});var ja=y(Ca=>{"use strict";Object.defineProperty(Ca,"__esModule",{value:!0});var Rs=Ge(),Qe=M(),C_=St(),Ns=H(),j_={message:"must NOT have additional properties",params:({params:t})=>(0,Qe._)`{additionalProperty: ${t.additionalProperty}}`},D_={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:j_,code(t){let{gen:e,schema:r,parentSchema:n,data:s,errsCount:i,it:a}=t;if(!i)throw new Error("ajv implementation error");let{allErrors:c,opts:l}=a;if(a.props=!0,l.removeAdditional!=="all"&&(0,Ns.alwaysValidSchema)(a,r))return;let o=(0,Rs.allSchemaProperties)(n.properties),f=(0,Rs.allSchemaProperties)(n.patternProperties);h(),t.ok((0,Qe._)`${i} === ${C_.default.errors}`);function h(){e.forIn("key",s,w=>{!o.length&&!f.length?E(w):e.if(_(w),()=>E(w))})}function _(w){let b;if(o.length>8){let C=(0,Ns.schemaRefOrVal)(a,n.properties,"properties");b=(0,Rs.isOwnProperty)(e,C,w)}else o.length?b=(0,Qe.or)(...o.map(C=>(0,Qe._)`${w} === ${C}`)):b=Qe.nil;return f.length&&(b=(0,Qe.or)(b,...f.map(C=>(0,Qe._)`${(0,Rs.usePattern)(t,C)}.test(${w})`))),(0,Qe.not)(b)}function v(w){e.code((0,Qe._)`delete ${s}[${w}]`)}function E(w){if(l.removeAdditional==="all"||l.removeAdditional&&r===!1){v(w);return}if(r===!1){t.setParams({additionalProperty:w}),t.error(),c||e.break();return}if(typeof r=="object"&&!(0,Ns.alwaysValidSchema)(a,r)){let b=e.name("valid");l.removeAdditional==="failing"?($(w,b,!1),e.if((0,Qe.not)(b),()=>{t.reset(),v(w)})):($(w,b),c||e.if((0,Qe.not)(b),()=>e.break()))}}function $(w,b,C){let q={keyword:"additionalProperties",dataProp:w,dataPropType:Ns.Type.Str};C===!1&&Object.assign(q,{compositeRule:!0,createErrors:!1,allErrors:!1}),t.subschema(q,b)}}};Ca.default=D_});var qf=y(Aa=>{"use strict";Object.defineProperty(Aa,"__esModule",{value:!0});var A_=bn(),If=Ge(),Da=H(),Tf=ja(),k_={keyword:"properties",type:"object",schemaType:"object",code(t){let{gen:e,schema:r,parentSchema:n,data:s,it:i}=t;i.opts.removeAdditional==="all"&&n.additionalProperties===void 0&&Tf.default.code(new A_.KeywordCxt(i,Tf.default,"additionalProperties"));let a=(0,If.allSchemaProperties)(r);for(let h of a)i.definedProperties.add(h);i.opts.unevaluated&&a.length&&i.props!==!0&&(i.props=Da.mergeEvaluated.props(e,(0,Da.toHash)(a),i.props));let c=a.filter(h=>!(0,Da.alwaysValidSchema)(i,r[h]));if(c.length===0)return;let l=e.name("valid");for(let h of c)o(h)?f(h):(e.if((0,If.propertyInData)(e,s,h,i.opts.ownProperties)),f(h),i.allErrors||e.else().var(l,!0),e.endIf()),t.it.definedProperties.add(h),t.ok(l);function o(h){return i.opts.useDefaults&&!i.compositeRule&&r[h].default!==void 0}function f(h){t.subschema({keyword:"properties",schemaProp:h,dataProp:h},l)}}};Aa.default=k_});var Af=y(ka=>{"use strict";Object.defineProperty(ka,"__esModule",{value:!0});var Cf=Ge(),Is=M(),jf=H(),Df=H(),L_={keyword:"patternProperties",type:"object",schemaType:"object",code(t){let{gen:e,schema:r,data:n,parentSchema:s,it:i}=t,{opts:a}=i,c=(0,Cf.allSchemaProperties)(r),l=c.filter($=>(0,jf.alwaysValidSchema)(i,r[$]));if(c.length===0||l.length===c.length&&(!i.opts.unevaluated||i.props===!0))return;let o=a.strictSchema&&!a.allowMatchingProperties&&s.properties,f=e.name("valid");i.props!==!0&&!(i.props instanceof Is.Name)&&(i.props=(0,Df.evaluatedPropsToName)(e,i.props));let{props:h}=i;_();function _(){for(let $ of c)o&&v($),i.allErrors?E($):(e.var(f,!0),E($),e.if(f))}function v($){for(let w in o)new RegExp($).test(w)&&(0,jf.checkStrictMode)(i,`property ${w} matches pattern ${$} (use allowMatchingProperties)`)}function E($){e.forIn("key",n,w=>{e.if((0,Is._)`${(0,Cf.usePattern)(t,$)}.test(${w})`,()=>{let b=l.includes($);b||t.subschema({keyword:"patternProperties",schemaProp:$,dataProp:w,dataPropType:Df.Type.Str},f),i.opts.unevaluated&&h!==!0?e.assign((0,Is._)`${h}[${w}]`,!0):!b&&!i.allErrors&&e.if((0,Is.not)(f),()=>e.break())})})}}};ka.default=L_});var kf=y(La=>{"use strict";Object.defineProperty(La,"__esModule",{value:!0});var M_=H(),x_={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(t){let{gen:e,schema:r,it:n}=t;if((0,M_.alwaysValidSchema)(n,r)){t.fail();return}let s=e.name("valid");t.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},s),t.failResult(s,()=>t.reset(),()=>t.error())},error:{message:"must NOT be valid"}};La.default=x_});var Lf=y(Ma=>{"use strict";Object.defineProperty(Ma,"__esModule",{value:!0});var F_=Ge(),V_={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:F_.validateUnion,error:{message:"must match a schema in anyOf"}};Ma.default=V_});var Mf=y(xa=>{"use strict";Object.defineProperty(xa,"__esModule",{value:!0});var Ts=M(),U_=H(),G_={message:"must match exactly one schema in oneOf",params:({params:t})=>(0,Ts._)`{passingSchemas: ${t.passing}}`},H_={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:G_,code(t){let{gen:e,schema:r,parentSchema:n,it:s}=t;if(!Array.isArray(r))throw new Error("ajv implementation error");if(s.opts.discriminator&&n.discriminator)return;let i=r,a=e.let("valid",!1),c=e.let("passing",null),l=e.name("_valid");t.setParams({passing:c}),e.block(o),t.result(a,()=>t.reset(),()=>t.error(!0));function o(){i.forEach((f,h)=>{let _;(0,U_.alwaysValidSchema)(s,f)?e.var(l,!0):_=t.subschema({keyword:"oneOf",schemaProp:h,compositeRule:!0},l),h>0&&e.if((0,Ts._)`${l} && ${a}`).assign(a,!1).assign(c,(0,Ts._)`[${c}, ${h}]`).else(),e.if(l,()=>{e.assign(a,!0),e.assign(c,h),_&&t.mergeEvaluated(_,Ts.Name)})})}}};xa.default=H_});var xf=y(Fa=>{"use strict";Object.defineProperty(Fa,"__esModule",{value:!0});var z_=H(),K_={keyword:"allOf",schemaType:"array",code(t){let{gen:e,schema:r,it:n}=t;if(!Array.isArray(r))throw new Error("ajv implementation error");let s=e.name("valid");r.forEach((i,a)=>{if((0,z_.alwaysValidSchema)(n,i))return;let c=t.subschema({keyword:"allOf",schemaProp:a},s);t.ok(s),t.mergeEvaluated(c)})}};Fa.default=K_});var Uf=y(Va=>{"use strict";Object.defineProperty(Va,"__esModule",{value:!0});var qs=M(),Vf=H(),X_={message:({params:t})=>(0,qs.str)`must match "${t.ifClause}" schema`,params:({params:t})=>(0,qs._)`{failingKeyword: ${t.ifClause}}`},B_={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:X_,code(t){let{gen:e,parentSchema:r,it:n}=t;r.then===void 0&&r.else===void 0&&(0,Vf.checkStrictMode)(n,'"if" without "then" and "else" is ignored');let s=Ff(n,"then"),i=Ff(n,"else");if(!s&&!i)return;let a=e.let("valid",!0),c=e.name("_valid");if(l(),t.reset(),s&&i){let f=e.let("ifClause");t.setParams({ifClause:f}),e.if(c,o("then",f),o("else",f))}else s?e.if(c,o("then")):e.if((0,qs.not)(c),o("else"));t.pass(a,()=>t.error(!0));function l(){let f=t.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},c);t.mergeEvaluated(f)}function o(f,h){return()=>{let _=t.subschema({keyword:f},c);e.assign(a,c),t.mergeValidEvaluated(_,a),h?e.assign(h,(0,qs._)`${f}`):t.setParams({ifClause:f})}}}};function Ff(t,e){let r=t.schema[e];return r!==void 0&&!(0,Vf.alwaysValidSchema)(t,r)}Va.default=B_});var Gf=y(Ua=>{"use strict";Object.defineProperty(Ua,"__esModule",{value:!0});var W_=H(),Y_={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:t,parentSchema:e,it:r}){e.if===void 0&&(0,W_.checkStrictMode)(r,`"${t}" without "if" is ignored`)}};Ua.default=Y_});var Hf=y(Ga=>{"use strict";Object.defineProperty(Ga,"__esModule",{value:!0});var J_=Pa(),Z_=$f(),Q_=Oa(),e$=wf(),t$=bf(),r$=Of(),n$=Nf(),s$=ja(),i$=qf(),a$=Af(),o$=kf(),c$=Lf(),u$=Mf(),l$=xf(),f$=Uf(),d$=Gf();function h$(t=!1){let e=[o$.default,c$.default,u$.default,l$.default,f$.default,d$.default,n$.default,s$.default,r$.default,i$.default,a$.default];return t?e.push(Z_.default,e$.default):e.push(J_.default,Q_.default),e.push(t$.default),e}Ga.default=h$});var zf=y(Ha=>{"use strict";Object.defineProperty(Ha,"__esModule",{value:!0});var oe=M(),p$={message:({schemaCode:t})=>(0,oe.str)`must match format "${t}"`,params:({schemaCode:t})=>(0,oe._)`{format: ${t}}`},m$={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:p$,code(t,e){let{gen:r,data:n,$data:s,schema:i,schemaCode:a,it:c}=t,{opts:l,errSchemaPath:o,schemaEnv:f,self:h}=c;if(!l.validateFormats)return;s?_():v();function _(){let E=r.scopeValue("formats",{ref:h.formats,code:l.code.formats}),$=r.const("fDef",(0,oe._)`${E}[${a}]`),w=r.let("fType"),b=r.let("format");r.if((0,oe._)`typeof ${$} == "object" && !(${$} instanceof RegExp)`,()=>r.assign(w,(0,oe._)`${$}.type || "string"`).assign(b,(0,oe._)`${$}.validate`),()=>r.assign(w,(0,oe._)`"string"`).assign(b,$)),t.fail$data((0,oe.or)(C(),q()));function C(){return l.strictSchema===!1?oe.nil:(0,oe._)`${a} && !${b}`}function q(){let z=f.$async?(0,oe._)`(${$}.async ? await ${b}(${n}) : ${b}(${n}))`:(0,oe._)`${b}(${n})`,N=(0,oe._)`(typeof ${b} == "function" ? ${z} : ${b}.test(${n}))`;return(0,oe._)`${b} && ${b} !== true && ${w} === ${e} && !${N}`}}function v(){let E=h.formats[i];if(!E){C();return}if(E===!0)return;let[$,w,b]=q(E);$===e&&t.pass(z());function C(){if(l.strictSchema===!1){h.logger.warn(N());return}throw new Error(N());function N(){return`unknown format "${i}" ignored in schema at path "${o}"`}}function q(N){let me=N instanceof RegExp?(0,oe.regexpCode)(N):l.code.formats?(0,oe._)`${l.code.formats}${(0,oe.getProperty)(i)}`:void 0,Ke=r.scopeValue("formats",{key:i,ref:N,code:me});return typeof N=="object"&&!(N instanceof RegExp)?[N.type||"string",N.validate,(0,oe._)`${Ke}.validate`]:["string",N,Ke]}function z(){if(typeof E=="object"&&!(E instanceof RegExp)&&E.async){if(!f.$async)throw new Error("async format in sync schema");return(0,oe._)`await ${b}(${n})`}return typeof w=="function"?(0,oe._)`${b}(${n})`:(0,oe._)`${b}.test(${n})`}}}};Ha.default=m$});var Kf=y(za=>{"use strict";Object.defineProperty(za,"__esModule",{value:!0});var v$=zf(),g$=[v$.default];za.default=g$});var Xf=y(Tr=>{"use strict";Object.defineProperty(Tr,"__esModule",{value:!0});Tr.contentVocabulary=Tr.metadataVocabulary=void 0;Tr.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];Tr.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]});var Wf=y(Ka=>{"use strict";Object.defineProperty(Ka,"__esModule",{value:!0});var y$=tf(),_$=vf(),$$=Hf(),E$=Kf(),Bf=Xf(),w$=[y$.default,_$.default,(0,$$.default)(),E$.default,Bf.metadataVocabulary,Bf.contentVocabulary];Ka.default=w$});var Yf=y(kn=>{"use strict";Object.defineProperty(kn,"__esModule",{value:!0});kn.DiscrError=void 0;var b$;(function(t){t.Tag="tag",t.Mapping="mapping"})(b$=kn.DiscrError||(kn.DiscrError={}))});var Zf=y(Ba=>{"use strict";Object.defineProperty(Ba,"__esModule",{value:!0});var qr=M(),Xa=Yf(),Jf=vs(),S$=H(),P$={message:({params:{discrError:t,tagName:e}})=>t===Xa.DiscrError.Tag?`tag "${e}" must be string`:`value of tag "${e}" must be in oneOf`,params:({params:{discrError:t,tag:e,tagName:r}})=>(0,qr._)`{error: ${t}, tag: ${r}, tagValue: ${e}}`},O$={keyword:"discriminator",type:"object",schemaType:"object",error:P$,code(t){let{gen:e,data:r,schema:n,parentSchema:s,it:i}=t,{oneOf:a}=s;if(!i.opts.discriminator)throw new Error("discriminator: requires discriminator option");let c=n.propertyName;if(typeof c!="string")throw new Error("discriminator: requires propertyName");if(n.mapping)throw new Error("discriminator: mapping is not supported");if(!a)throw new Error("discriminator: requires oneOf keyword");let l=e.let("valid",!1),o=e.const("tag",(0,qr._)`${r}${(0,qr.getProperty)(c)}`);e.if((0,qr._)`typeof ${o} == "string"`,()=>f(),()=>t.error(!1,{discrError:Xa.DiscrError.Tag,tag:o,tagName:c})),t.ok(l);function f(){let v=_();e.if(!1);for(let E in v)e.elseIf((0,qr._)`${o} === ${E}`),e.assign(l,h(v[E]));e.else(),t.error(!1,{discrError:Xa.DiscrError.Mapping,tag:o,tagName:c}),e.endIf()}function h(v){let E=e.name("valid"),$=t.subschema({keyword:"oneOf",schemaProp:v},E);return t.mergeEvaluated($,qr.Name),E}function _(){var v;let E={},$=b(s),w=!0;for(let z=0;z<a.length;z++){let N=a[z];(N==null?void 0:N.$ref)&&!(0,S$.schemaHasRulesButRef)(N,i.self.RULES)&&(N=Jf.resolveRef.call(i.self,i.schemaEnv.root,i.baseId,N==null?void 0:N.$ref),N instanceof Jf.SchemaEnv&&(N=N.schema));let me=(v=N==null?void 0:N.properties)===null||v===void 0?void 0:v[c];if(typeof me!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${c}"`);w=w&&($||b(N)),C(me,z)}if(!w)throw new Error(`discriminator: "${c}" must be required`);return E;function b({required:z}){return Array.isArray(z)&&z.includes(c)}function C(z,N){if(z.const)q(z.const,N);else if(z.enum)for(let me of z.enum)q(me,N);else throw new Error(`discriminator: "properties/${c}" must have "const" or "enum"`)}function q(z,N){if(typeof z!="string"||z in E)throw new Error(`discriminator: "${c}" values must be unique strings`);E[z]=N}}}};Ba.default=O$});var Qf=y((cS,R$)=>{R$.exports={$schema:"http://json-schema.org/draft-07/schema#",$id:"http://json-schema.org/draft-07/schema#",title:"Core schema meta-schema",definitions:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},type:["object","boolean"],properties:{$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},default:!0}});var rd=y((ae,td)=>{"use strict";Object.defineProperty(ae,"__esModule",{value:!0});ae.MissingRefError=ae.ValidationError=ae.CodeGen=ae.Name=ae.nil=ae.stringify=ae.str=ae._=ae.KeywordCxt=void 0;var N$=Wl(),I$=Wf(),T$=Zf(),ed=Qf(),q$=["/properties"],Cs="http://json-schema.org/draft-07/schema",js=class extends N$.default{_addVocabularies(){super._addVocabularies(),I$.default.forEach(e=>this.addVocabulary(e)),this.opts.discriminator&&this.addKeyword(T$.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;let e=this.opts.$data?this.$dataMetaSchema(ed,q$):ed;this.addMetaSchema(e,Cs,!1),this.refs["http://json-schema.org/schema"]=Cs}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(Cs)?Cs:void 0)}};td.exports=ae=js;Object.defineProperty(ae,"__esModule",{value:!0});ae.default=js;var C$=bn();Object.defineProperty(ae,"KeywordCxt",{enumerable:!0,get:function(){return C$.KeywordCxt}});var Cr=M();Object.defineProperty(ae,"_",{enumerable:!0,get:function(){return Cr._}});Object.defineProperty(ae,"str",{enumerable:!0,get:function(){return Cr.str}});Object.defineProperty(ae,"stringify",{enumerable:!0,get:function(){return Cr.stringify}});Object.defineProperty(ae,"nil",{enumerable:!0,get:function(){return Cr.nil}});Object.defineProperty(ae,"Name",{enumerable:!0,get:function(){return Cr.Name}});Object.defineProperty(ae,"CodeGen",{enumerable:!0,get:function(){return Cr.CodeGen}});var j$=hs();Object.defineProperty(ae,"ValidationError",{enumerable:!0,get:function(){return j$.default}});var D$=ps();Object.defineProperty(ae,"MissingRefError",{enumerable:!0,get:function(){return D$.default}})});var tr=y(jr=>{"use strict";var A$=jr&&jr.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(jr,"__esModule",{value:!0});jr.ServerlessError=void 0;var k$=A$(Et()),L$=k$.default.Logger,M$=new L$("S-CLI-ERROR"),x$=function(){function t(e,r,n){M$.error(e+": "+r,n),process.exit(1)}return t}();jr.ServerlessError=x$});var nd=y(Dr=>{"use strict";var F$=Dr&&Dr.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,s){n.__proto__=s}||function(n,s){for(var i in s)Object.prototype.hasOwnProperty.call(s,i)&&(n[i]=s[i])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}}();Object.defineProperty(Dr,"__esModule",{value:!0});Dr.CommandError=void 0;var V$=tr(),U$=function(t){F$(e,t);function e(r,n){return t.call(this,"Error",r,n)||this}return e}(V$.ServerlessError);Dr.CommandError=U$});var sd=y(Ar=>{"use strict";var G$=Ar&&Ar.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,s){n.__proto__=s}||function(n,s){for(var i in s)Object.prototype.hasOwnProperty.call(s,i)&&(n[i]=s[i])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}}();Object.defineProperty(Ar,"__esModule",{value:!0});Ar.ConfigDeleteError=void 0;var H$=tr(),z$=function(t){G$(e,t);function e(r,n){return t.call(this,"Deletion failed",r,n)||this}return e}(H$.ServerlessError);Ar.ConfigDeleteError=z$});var id=y(kr=>{"use strict";var K$=kr&&kr.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,s){n.__proto__=s}||function(n,s){for(var i in s)Object.prototype.hasOwnProperty.call(s,i)&&(n[i]=s[i])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}}();Object.defineProperty(kr,"__esModule",{value:!0});kr.ConfigError=void 0;var X$=tr(),B$=function(t){K$(e,t);function e(r,n){return t.call(this,"Config failed",r,n)||this}return e}(X$.ServerlessError);kr.ConfigError=B$});var ad=y(Lr=>{"use strict";var W$=Lr&&Lr.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,s){n.__proto__=s}||function(n,s){for(var i in s)Object.prototype.hasOwnProperty.call(s,i)&&(n[i]=s[i])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}}();Object.defineProperty(Lr,"__esModule",{value:!0});Lr.ConfigGetError=void 0;var Y$=tr(),J$=function(t){W$(e,t);function e(r,n){return t.call(this,"Get failed",r,n)||this}return e}(Y$.ServerlessError);Lr.ConfigGetError=J$});var od=y(Mr=>{"use strict";var Z$=Mr&&Mr.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,s){n.__proto__=s}||function(n,s){for(var i in s)Object.prototype.hasOwnProperty.call(s,i)&&(n[i]=s[i])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}}();Object.defineProperty(Mr,"__esModule",{value:!0});Mr.InitError=void 0;var Q$=tr(),eE=function(t){Z$(e,t);function e(r,n){return t.call(this,"Initialization failed",r,n)||this}return e}(Q$.ServerlessError);Mr.InitError=eE});var ud=y(lt=>{"use strict";var tE=lt&<.__awaiter||function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(a){a(i)})}return new(r||(r=Promise))(function(i,a){function c(f){try{o(n.next(f))}catch(h){a(h)}}function l(f){try{o(n.throw(f))}catch(h){a(h)}}function o(f){f.done?i(f.value):s(f.value).then(c,l)}o((n=n.apply(t,e||[])).next())})},rE=lt&<.__generator||function(t,e){var r={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,s,i,a;return a={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function c(o){return function(f){return l([o,f])}}function l(o){if(n)throw new TypeError("Generator is already executing.");for(;a&&(a=0,o[0]&&(r=0)),r;)try{if(n=1,s&&(i=o[0]&2?s.return:o[0]?s.throw||((i=s.return)&&i.call(s),0):s.next)&&!(i=i.call(s,o[1])).done)return i;switch(s=0,i&&(o=[o[0]&2,i.value]),o[0]){case 0:case 1:i=o;break;case 4:return r.label++,{value:o[1],done:!1};case 5:r.label++,s=o[1],o=[0];continue;case 7:o=r.ops.pop(),r.trys.pop();continue;default:if(i=r.trys,!(i=i.length>0&&i[i.length-1])&&(o[0]===6||o[0]===2)){r=0;continue}if(o[0]===3&&(!i||o[1]>i[0]&&o[1]<i[3])){r.label=o[1];break}if(o[0]===6&&r.label<i[1]){r.label=i[1],i=o;break}if(i&&r.label<i[2]){r.label=i[2],r.ops.push(o);break}i[2]&&r.ops.pop(),r.trys.pop();continue}o=e.call(t,r)}catch(f){o=[6,f],s=0}finally{n=i=0}if(o[0]&5)throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}},nE=lt&<.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(lt,"__esModule",{value:!0});lt.HumanError=void 0;var cd=nE(Et()),Ds=cn(),sE=cd.default.colors,iE=function(){function t(e){var r=e.errorMessage,n=e.tips;this.errorMessage=r,Ds.logger.log(`
|
|
15
|
+
`.concat((0,Ds.bgRed)("ERROR:"))),Ds.logger.log("TypeError: ".concat(r,`
|
|
16
|
+
`)),n&&Ds.logger.log("".concat(sE.gray(n),`
|
|
17
|
+
`))}return t.prototype.report=function(e){return tE(this,void 0,void 0,function(){var r;return rE(this,function(n){switch(n.label){case 0:return r=e.error,[4,cd.default.report({type:"jsError",errorMessage:this.errorMessage,errorStack:r.stack})];case 1:return n.sent(),[2]}})})},t}();lt.HumanError=iE});var fd=y(xr=>{"use strict";var aE=xr&&xr.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(xr,"__esModule",{value:!0});xr.HumanWarning=void 0;var oE=aE(Et()),Wa=cn(),ld=oE.default.colors,cE=function(){function t(e){var r=e.warningMessage,n=e.tips;Wa.logger.log(`
|
|
18
|
+
`.concat(ld.hex("#000").bgYellow("WARNING:"))),Wa.logger.log("".concat(r,`
|
|
19
|
+
`)),n&&Wa.logger.log("".concat(ld.gray(n),`
|
|
20
|
+
`))}return t}();xr.HumanWarning=cE});var hd=y(ee=>{"use strict";var uE=ee&&ee.__awaiter||function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(a){a(i)})}return new(r||(r=Promise))(function(i,a){function c(f){try{o(n.next(f))}catch(h){a(h)}}function l(f){try{o(n.throw(f))}catch(h){a(h)}}function o(f){f.done?i(f.value):s(f.value).then(c,l)}o((n=n.apply(t,e||[])).next())})},lE=ee&&ee.__generator||function(t,e){var r={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,s,i,a;return a={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function c(o){return function(f){return l([o,f])}}function l(o){if(n)throw new TypeError("Generator is already executing.");for(;a&&(a=0,o[0]&&(r=0)),r;)try{if(n=1,s&&(i=o[0]&2?s.return:o[0]?s.throw||((i=s.return)&&i.call(s),0):s.next)&&!(i=i.call(s,o[1])).done)return i;switch(s=0,i&&(o=[o[0]&2,i.value]),o[0]){case 0:case 1:i=o;break;case 4:return r.label++,{value:o[1],done:!1};case 5:r.label++,s=o[1],o=[0];continue;case 7:o=r.ops.pop(),r.trys.pop();continue;default:if(i=r.trys,!(i=i.length>0&&i[i.length-1])&&(o[0]===6||o[0]===2)){r=0;continue}if(o[0]===3&&(!i||o[1]>i[0]&&o[1]<i[3])){r.label=o[1];break}if(o[0]===6&&r.label<i[1]){r.label=i[1],i=o;break}if(i&&r.label<i[2]){r.label=i[2],r.ops.push(o);break}i[2]&&r.ops.pop(),r.trys.pop();continue}o=e.call(t,r)}catch(f){o=[6,f],s=0}finally{n=i=0}if(o[0]&5)throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}},dd=ee&&ee.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(ee,"__esModule",{value:!0});ee.HandleError=ee.HumanWarning=ee.HumanError=ee.ServerlessError=ee.InitError=ee.ConfigGetError=ee.ConfigError=ee.ConfigDeleteError=ee.CommandError=void 0;var Q=cn(),fE=dd(require("path")),Fr=dd(Et()),At=Fr.default.colors,dE=Fr.default.report,Ya=Fr.default.isDebugMode,hE=Fr.default.makeUnderLine,Ja=Fr.default.isDocker,pE=nd();Object.defineProperty(ee,"CommandError",{enumerable:!0,get:function(){return pE.CommandError}});var mE=sd();Object.defineProperty(ee,"ConfigDeleteError",{enumerable:!0,get:function(){return mE.ConfigDeleteError}});var vE=id();Object.defineProperty(ee,"ConfigError",{enumerable:!0,get:function(){return vE.ConfigError}});var gE=ad();Object.defineProperty(ee,"ConfigGetError",{enumerable:!0,get:function(){return gE.ConfigGetError}});var yE=od();Object.defineProperty(ee,"InitError",{enumerable:!0,get:function(){return yE.InitError}});var _E=tr();Object.defineProperty(ee,"ServerlessError",{enumerable:!0,get:function(){return _E.ServerlessError}});var $E=ud();Object.defineProperty(ee,"HumanError",{enumerable:!0,get:function(){return $E.HumanError}});var EE=fd();Object.defineProperty(ee,"HumanWarning",{enumerable:!0,get:function(){return EE.HumanWarning}});function As(t,e){return"".concat(At.gray(t)).concat(At.gray.underline(e))}var wE=function(t){return uE(void 0,void 0,void 0,function(){var e,r,n,s,i,a,c,l;return lE(this,function(o){switch(o.label){case 0:e="Message:",r={traceId:"",catchableError:!1},n=t,s=(0,Q.getConfig)("analysis"),s!=="disable"&&(r.traceId=process.env.serverless_devs_trace_id),i=t.message?t.message:"";try{a=JSON.parse(i)}catch{}return a&&a.tips?(c=a.message?"Message: ".concat(a.message,`
|
|
21
|
+
`):"",l=a.tips?"* ".concat(hE(a.tips.replace(/\n/,`
|
|
36
22
|
* `))):"",Q.logger.log(`
|
|
37
|
-
`.concat(
|
|
23
|
+
`.concat(At.hex("#000").bgYellow("WARNING:"),`
|
|
38
24
|
======================
|
|
39
|
-
`).concat(
|
|
40
|
-
`),"yellow"),
|
|
25
|
+
`).concat(l,`
|
|
26
|
+
`),"yellow"),Ya()?Q.logger.log(t.stack):Q.logger.log(At.grey(c)),r.catchableError=!0,n=a,[3,5]):[3,1];case 1:return a&&a.code?(Q.logger.log((0,Q.red)("\u2716 ".concat(a.prefix||e,`
|
|
41
27
|
`))),Q.logger.log("".concat((0,Q.bgRed)("ERROR:"),`
|
|
42
|
-
`)),
|
|
28
|
+
`)),Ya()?Q.logger.log("".concat(a.stack,`
|
|
43
29
|
`)):Q.logger.log("".concat(a.message,`
|
|
44
30
|
`)),[4,(0,Q.aiRequest)(a.message)]):[3,3];case 2:return o.sent(),n=a,[3,5];case 3:return Q.logger.log((0,Q.red)("\u2716 ".concat(e,`
|
|
45
31
|
`))),Q.logger.log("".concat((0,Q.bgRed)("ERROR:"),`
|
|
46
|
-
`)),Q.logger.log(
|
|
47
|
-
`)),[4,(0,Q.aiRequest)(i)];case 4:o.sent(),o.label=5;case 5:return
|
|
48
|
-
`)),
|
|
49
|
-
`)))),!
|
|
32
|
+
`)),Q.logger.log(Ya()||Ja()?t.stack:"".concat(i,`
|
|
33
|
+
`)),[4,(0,Q.aiRequest)(i)];case 4:o.sent(),o.label=5;case 5:return r.catchableError||(r.traceId&&Q.logger.log(At.gray("TraceId: ".concat(r.traceId))),Ja()||(Q.logger.log(At.gray("Environment: ".concat((0,Q.getVersion)()))),Q.logger.log(As("Documents: ","https://www.serverless-devs.com")),Q.logger.log(As("Discussions: ","https://github.com/Serverless-Devs/Serverless-Devs/discussions")),Q.logger.log(As("Issues: ","https://github.com/Serverless-Devs/Serverless-Devs/issues")),Q.logger.log(As("Regsitry: ",`https://registry.serverless-devs.com
|
|
34
|
+
`)),r.traceId&&Q.logger.log(At.gray("Please copy traceId: ".concat(r.traceId," and join Dingding group: 33947367 for consultation."))),process.env.serverless_devs_trace_id&&Q.logger.log("A complete log of this run can be found in: ".concat(fE.default.join(Fr.default.getRootHome(),"logs","".concat(process.env.serverless_devs_trace_id,".log")),`
|
|
35
|
+
`)))),!Ja()&&Q.logger.log(At.gray("You can run 's clean --all' to clean Serverless devs.")),r.traceId&&!r.catchableError?[4,dE({type:"jsError",errorMessage:n.message,errorStack:n.stack,traceId:r.traceId})]:[3,7];case 6:o.sent(),o.label=7;case 7:return process.exit(n.code||1),[2]}})})};ee.HandleError=wE});var pd=exports&&exports.__awaiter||function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(a){a(i)})}return new(r||(r=Promise))(function(i,a){function c(f){try{o(n.next(f))}catch(h){a(h)}}function l(f){try{o(n.throw(f))}catch(h){a(h)}}function o(f){f.done?i(f.value):s(f.value).then(c,l)}o((n=n.apply(t,e||[])).next())})},md=exports&&exports.__generator||function(t,e){var r={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,s,i,a;return a={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function c(o){return function(f){return l([o,f])}}function l(o){if(n)throw new TypeError("Generator is already executing.");for(;a&&(a=0,o[0]&&(r=0)),r;)try{if(n=1,s&&(i=o[0]&2?s.return:o[0]?s.throw||((i=s.return)&&i.call(s),0):s.next)&&!(i=i.call(s,o[1])).done)return i;switch(s=0,i&&(o=[o[0]&2,i.value]),o[0]){case 0:case 1:i=o;break;case 4:return r.label++,{value:o[1],done:!1};case 5:r.label++,s=o[1],o=[0];continue;case 7:o=r.ops.pop(),r.trys.pop();continue;default:if(i=r.trys,!(i=i.length>0&&i[i.length-1])&&(o[0]===6||o[0]===2)){r=0;continue}if(o[0]===3&&(!i||o[1]>i[0]&&o[1]<i[3])){r.label=o[1];break}if(o[0]===6&&r.label<i[1]){r.label=i[1],i=o;break}if(i&&r.label<i[2]){r.label=i[2],r.ops.push(o);break}i[2]&&r.ops.pop(),r.trys.pop();continue}o=e.call(t,r)}catch(f){o=[6,f],s=0}finally{n=i=0}if(o[0]&5)throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}},ks=exports&&exports.__importDefault||function(t){return t&&t.__esModule?t:{default:t}},ft=ks(Et()),bE=ks(mi()),Ln=cn(),SE=ks(require("path")),PE=ks(rd()),OE=hd(),Za=ft.default.colors,RE=ft.default.getYamlContent,Ce=ft.default.lodash,NE=ft.default.loadComponent,IE=ft.default.fse,TE=ft.default.parseYaml,qE=ft.default.spinner,vd=Ce.get,CE=Ce.keys,jE=Ce.omit,DE=Ce.isEmpty,AE=Ce.replace,gd=Ce.isPlainObject,Qa=Ce.isArray,yd=Ce.each,kE=Ce.last,LE=Ce.split,ME=Ce.uniq,_d=Ce.map,xE=Ce.concat,$d=Ce.filter,FE=`Application verification.
|
|
50
36
|
|
|
51
37
|
Example:
|
|
52
38
|
$ s verify
|
|
53
39
|
|
|
54
|
-
`.concat((0,
|
|
55
|
-
`))),
|
|
40
|
+
`.concat((0,Ln.emoji)("\u{1F4D6}")," Document: ").concat(Za.underline("https://github.com/Serverless-Devs/Serverless-Devs/tree/master/docs/zh/command/verify.md"));function Ed(t){var e=Qa(t)?[]:{};if(typeof t=="object"){var r=CE(t).filter(function(i){return i.startsWith("x-")}),n=jE(t,r);for(var s in n)e[s]=typeof t[s]=="object"?Ed(t[s]):t[s]}else e=t;return e}function VE(t){var e=Ed(t),r=[];function n(i,a){if(a===void 0&&(a=""),gd(i)){if(i.required===!0){var c=LE(a,"."),l=c.slice(0,c.length-2).join(".");r.push({key:l,name:kE(c)})}typeof i.required=="boolean"&&delete i.required,a!==""&&(a="".concat(a,"."));for(var o in i)n(i[o],"".concat(a).concat(o))}Qa(i)&&yd(i,function(f,h){n(f,"".concat(a,"[").concat(h,"]"))})}function s(i,a){if(a===void 0&&(a=""),gd(i)){var c=$d(r,function(f){return f.key===a});if(c.length>0){var l=_d(c,function(f){return f.name});i.required=i.required?ME(xE(i.required,l)):l}a!==""&&(a="".concat(a,"."));for(var o in i)s(i[o],"".concat(a).concat(o))}Qa(i)&&yd(i,function(f,h){s(f,"".concat(a,"[").concat(h,"]"))})}return n(e),s(e),e}function UE(t){var e=this,r=t.command("verify").usage("[options]").option("-t, --template [templatePath]","Specify the template file").helpOption("-h, --help",(0,bE.default)("display_help_for_command")).description(FE).addHelpCommand(!1).action(function(){return pd(e,void 0,void 0,function(){var s;return md(this,function(i){switch(i.label){case 0:return i.trys.push([0,2,,4]),[4,n()];case 1:return i.sent(),[3,4];case 2:return s=i.sent(),[4,(0,OE.HandleError)(s)];case 3:return i.sent(),[3,4];case 4:return[2]}})})}),n=function(){return pd(e,void 0,void 0,function(){var s,i,a,c,l,o,f,h,_,v,E,$,w,b,C,q,z,N,me,Ke,dt,et,le,Xe,Oe,kt,ht;return md(this,function(tt){switch(tt.label){case 0:return s=process.argv.splice(2),i=ft.default.getGlobalArgs(s),a=i.help,c=i.template,a&&r.help(),[4,ft.default.getTemplatePath(c)];case 1:return l=tt.sent(),[4,ft.default.transforYamlPath(l)];case 2:o=tt.sent(),f=IE.readFileSync(o,"utf8"),h=TE(f),_=h.services,v=[];for(E in _)$=_[E],v.push({component:$.component,props:$.props,service:E});w=[],b=0,C=v,tt.label=3;case 3:return b<C.length?(q=C[b],[4,NE(q.component)]):[3,7];case 4:return z=tt.sent(),[4,RE(SE.default.join(z.__path,"publish.yaml"))];case 5:if(N=tt.sent(),me=vd(N,"Properties",{}),DE(me.properties))return[3,6];if(Ke=new PE.default({strict:!1}),dt=Ke.compile(VE(me)),et=dt(q.props),!et)return w.push(!0),le=dt.errors,Xe=$d(le,function(rr){return rr.keyword!=="oneOf"}),Ln.logger.log("".concat((0,Ln.red)("\u2716")," Format verification failed.")),Oe=vd(Xe,"[0].instancePath"),Oe&&(kt=AE(Oe.slice(1),/\//g,"."),Ln.logger.log("The ".concat(Za.yellow(kt)," field in ").concat(Za.yellow(q.service),` service is incorrect.
|
|
41
|
+
`))),ht=_d(Xe,function(rr){return{message:rr.message,params:rr.params}}),Ln.logger.output(ht.length>1?ht:ht[0]),[3,7];tt.label=6;case 6:return b++,[3,3];case 7:return w.length===0&&qE("Format verification passed.").succeed(),[2]}})})}}module.exports=UE;
|
|
56
42
|
/** @license URI.js v4.4.1 (c) 2011 Gary Court. License: http://github.com/garycourt/uri-js */
|