@serverless-devs/s 2.0.101-beta.1 → 2.0.101

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.
@@ -1,51 +1,55 @@
1
- "use strict";var fh=Object.defineProperty,dh=Object.defineProperties;var hh=Object.getOwnPropertyDescriptors;var co=Object.getOwnPropertySymbols;var ph=Object.prototype.hasOwnProperty,mh=Object.prototype.propertyIsEnumerable;var uo=(r,e,t)=>e in r?fh(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,ie=(r,e)=>{for(var t in e||(e={}))ph.call(e,t)&&uo(r,t,e[t]);if(co)for(var t of co(e))mh.call(e,t)&&uo(r,t,e[t]);return r},Fe=(r,e)=>dh(r,hh(e));var y=(r,e)=>()=>(e||r((e={exports:{}}).exports,e),e.exports);var _o=y((Mt,vo)=>{var gh=require("events").EventEmitter,ks=require("child_process").spawn,Lt=require("path"),xs=require("fs"),jn=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=go(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 vh(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}},Vr=class extends gh{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 Vr(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
1
+ "use strict";var dh=Object.defineProperty,hh=Object.defineProperties;var ph=Object.getOwnPropertyDescriptors;var uo=Object.getOwnPropertySymbols;var mh=Object.prototype.hasOwnProperty,gh=Object.prototype.propertyIsEnumerable;var lo=(r,e,t)=>e in r?dh(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,ie=(r,e)=>{for(var t in e||(e={}))mh.call(e,t)&&lo(r,t,e[t]);if(uo)for(var t of uo(e))gh.call(e,t)&&lo(r,t,e[t]);return r},Ve=(r,e)=>hh(r,ph(e));var y=(r,e)=>()=>(e||r((e={exports:{}}).exports,e),e.exports);var yo=y((Ft,_o)=>{var vh=require("events").EventEmitter,ks=require("child_process").spawn,Mt=require("path"),xs=require("fs"),kn=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=vo(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 _h(this.name().replace(/^no-/,""))}is(e){return this.short===e||this.long===e}},Ur=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}},Gr=class extends vh{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 Gr(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 Ur(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
2
  - call storeOptionsAsProperties(false) to store option values safely,
3
3
  - or call storeOptionsAsProperties(true) to suppress this check,
4
4
  - or change option name
5
5
 
6
- Read more on https://git.io/JJc0W`)}_optionEx(e,t,n,s,i){let a=new jn(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,h)=>{let g=o.exec(l);return g?g[0]:h}}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&&Lt.basename(this._scriptPath,Lt.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 g=xs.realpathSync(i);a=Lt.dirname(g)}catch{a="."}let c=Lt.basename(i,Lt.extname(i))+"-"+e._name;e._executableFile&&(c=e._executableFile);let u=Lt.join(a,c);xs.existsSync(u)?c=u:s.forEach(g=>{xs.existsSync(`${u}${g}`)&&(c=`${u}${g}`)}),n=s.includes(Lt.extname(c));let o;process.platform!=="win32"?n?(t.unshift(c),t=po(process.execArgv).concat(t),o=ks(process.argv[0],t,{stdio:"inherit"})):o=ks(c,t,{stdio:"inherit"}):(t.unshift(c),t=po(process.execArgv).concat(t),o=ks(process.execPath,t,{stdio:"inherit"})),["SIGUSR1","SIGUSR2","SIGTERM","SIGINT","SIGHUP"].forEach(g=>{process.on(g,()=>{o.killed===!1&&o.exitCode===null&&o.kill(g)})});let h=this._exitCallback;h?o.on("close",()=>{h(new Fr(process.exitCode||0,"commander.executeSubCommandAsync","(close)"))}):o.on("close",process.exit.bind(process)),o.on("error",g=>{if(g.code==="ENOENT"){let v=`'${c}' does not exist
6
+ Read more on https://git.io/JJc0W`)}_optionEx(e,t,n,s,i){let a=new kn(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,h)=>{let g=o.exec(l);return g?g[0]:h}}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&&Mt.basename(this._scriptPath,Mt.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 g=xs.realpathSync(i);a=Mt.dirname(g)}catch{a="."}let c=Mt.basename(i,Mt.extname(i))+"-"+e._name;e._executableFile&&(c=e._executableFile);let u=Mt.join(a,c);xs.existsSync(u)?c=u:s.forEach(g=>{xs.existsSync(`${u}${g}`)&&(c=`${u}${g}`)}),n=s.includes(Mt.extname(c));let o;process.platform!=="win32"?n?(t.unshift(c),t=mo(process.execArgv).concat(t),o=ks(process.argv[0],t,{stdio:"inherit"})):o=ks(c,t,{stdio:"inherit"}):(t.unshift(c),t=mo(process.execArgv).concat(t),o=ks(process.execPath,t,{stdio:"inherit"})),["SIGUSR1","SIGUSR2","SIGTERM","SIGINT","SIGHUP"].forEach(g=>{process.on(g,()=>{o.killed===!1&&o.exitCode===null&&o.kill(g)})});let h=this._exitCallback;h?o.on("close",()=>{h(new Ur(process.exitCode||0,"commander.executeSubCommandAsync","(close)"))}):o.on("close",process.exit.bind(process)),o.on("error",g=>{if(g.code==="ENOENT"){let v=`'${c}' does not exist
7
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(v)}else if(g.code==="EACCES")throw new Error(`'${c}' not executable`);if(!h)process.exit(1);else{let v=new Fr(1,"commander.executeSubCommandAsync","(error)");v.nestedError=g,h(v)}}),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)fo(this,t),this._dispatchSubcommand(this._defaultCommandName,e,t);else if(this.commands.length&&this.args.length===0&&!this._actionHandler&&!this._defaultCommandName&&this._helpAndError(),fo(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 jn(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=>ho(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=>ho(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 Ls(u,e)+" "+lo(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?Ls(i[0],t):i[0])+lo(a,s,t+2)}).join(`
8
+ - if the default executable name is not suitable, use the executableFile option to supply a custom name`;throw new Error(v)}else if(g.code==="EACCES")throw new Error(`'${c}' not executable`);if(!h)process.exit(1);else{let v=new Ur(1,"commander.executeSubCommandAsync","(error)");v.nestedError=g,h(v)}}),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)ho(this,t),this._dispatchSubcommand(this._defaultCommandName,e,t);else if(this.commands.length&&this.args.length===0&&!this._actionHandler&&!this._defaultCommandName&&this._helpAndError(),ho(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 kn(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=>po(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=>po(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 Ls(u,e)+" "+fo(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?Ls(i[0],t):i[0])+fo(a,s,t+2)}).join(`
11
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(),h=(process.stdout.columns||80)-o-5;e.push("Arguments:"),this._args.forEach(g=>{e.push(" "+Ls(g.name,o)+" "+mo(u[g.name]||"",h,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=go(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)")}};Mt=vo.exports=new Vr;Mt.program=Mt;Mt.Command=Vr;Mt.Option=jn;Mt.CommanderError=Fr;function vh(r){return r.split("-").reduce((e,t)=>e+t[0].toUpperCase()+t.slice(1))}function Ls(r,e){let t=Math.max(0,e-r.length);return r+Array(t+1).join(" ")}function mo(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)===`
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(),h=(process.stdout.columns||80)-o-5;e.push("Arguments:"),this._args.forEach(g=>{e.push(" "+Ls(g.name,o)+" "+go(u[g.name]||"",h,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=vo(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)")}};Ft=_o.exports=new Gr;Ft.program=Ft;Ft.Command=Gr;Ft.Option=kn;Ft.CommanderError=Ur;function _h(r){return r.split("-").reduce((e,t)=>e+t[0].toUpperCase()+t.slice(1))}function Ls(r,e){let t=Math.max(0,e-r.length);return r+Array(t+1).join(" ")}function go(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
14
  `&&(i=i.slice(0,i.length-1)),(a>0&&t?Array(t+1).join(" "):"")+i.trimRight())).join(`
15
- `)}function lo(r,e,t){return r.match(/[\n]\s+/)||e<40?r:mo(r,e,t)}function fo(r,e){r._hasHelpOption&&e.find(n=>n===r._helpLongFlag||n===r._helpShortFlag)&&(r.outputHelp(),r._exit(0,"commander.helpDisplayed","(outputHelp)"))}function ho(r){let e=r.name+(r.variadic===!0?"...":"");return r.required?"<"+e+">":"["+e+"]"}function go(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 po(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 Ur=y((TE,yo)=>{var _h="2.0.0",yh=Number.MAX_SAFE_INTEGER||9007199254740991,$h=16;yo.exports={SEMVER_SPEC_VERSION:_h,MAX_LENGTH:256,MAX_SAFE_INTEGER:yh,MAX_SAFE_COMPONENT_LENGTH:$h}});var Hr=y((qE,$o)=>{var Eh=typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...r)=>console.error("SEMVER",...r):()=>{};$o.exports=Eh});var Ft=y((St,Eo)=>{var{MAX_SAFE_COMPONENT_LENGTH:Ms}=Ur(),wh=Hr();St=Eo.exports={};var bh=St.re=[],O=St.src=[],P=St.t={},Sh=0,j=(r,e,t)=>{let n=Sh++;wh(n,e),P[r]=n,O[n]=e,bh[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,${Ms}})(?:\\.(\\d{1,${Ms}}))?(?:\\.(\\d{1,${Ms}}))?(?:$|[^\\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 Gr=y((DE,wo)=>{var Oh=["includePrerelease","loose","rtl"],Ph=r=>r?typeof r!="object"?{loose:!0}:Oh.filter(e=>r[e]).reduce((e,t)=>(e[t]=!0,e),{}):{};wo.exports=Ph});var kn=y((jE,Oo)=>{var bo=/^[0-9]+$/,So=(r,e)=>{let t=bo.test(r),n=bo.test(e);return t&&n&&(r=+r,e=+e),r===e?0:t&&!n?-1:n&&!t?1:r<e?-1:1},Rh=(r,e)=>So(e,r);Oo.exports={compareIdentifiers:So,rcompareIdentifiers:Rh}});var ve=y((kE,No)=>{var xn=Hr(),{MAX_LENGTH:Po,MAX_SAFE_INTEGER:Ln}=Ur(),{re:Ro,t:Co}=Ft(),Ch=Gr(),{compareIdentifiers:zr}=kn(),Ve=class{constructor(e,t){if(t=Ch(t),e instanceof Ve){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>Po)throw new TypeError(`version is longer than ${Po} characters`);xn("SemVer",e,t),this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease;let n=e.trim().match(t.loose?Ro[Co.LOOSE]:Ro[Co.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>Ln||this.major<0)throw new TypeError("Invalid major version");if(this.minor>Ln||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>Ln||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<Ln)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(xn("SemVer.compare",this.version,this.options,e),!(e instanceof Ve)){if(typeof e=="string"&&e===this.version)return 0;e=new Ve(e,this.options)}return e.version===this.version?0:this.compareMain(e)||this.comparePre(e)}compareMain(e){return e instanceof Ve||(e=new Ve(e,this.options)),zr(this.major,e.major)||zr(this.minor,e.minor)||zr(this.patch,e.patch)}comparePre(e){if(e instanceof Ve||(e=new Ve(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(xn("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 zr(n,s)}while(++t)}compareBuild(e){e instanceof Ve||(e=new Ve(e,this.options));let t=0;do{let n=this.build[t],s=e.build[t];if(xn("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 zr(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&&(this.prerelease[0]===t?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}};No.exports=Ve});var Vt=y((xE,qo)=>{var{MAX_LENGTH:Nh}=Ur(),{re:Io,t:Ao}=Ft(),To=ve(),Ih=Gr(),Ah=(r,e)=>{if(e=Ih(e),r instanceof To)return r;if(typeof r!="string"||r.length>Nh||!(e.loose?Io[Ao.LOOSE]:Io[Ao.FULL]).test(r))return null;try{return new To(r,e)}catch{return null}};qo.exports=Ah});var jo=y((LE,Do)=>{var Th=Vt(),qh=(r,e)=>{let t=Th(r,e);return t?t.version:null};Do.exports=qh});var xo=y((ME,ko)=>{var Dh=Vt(),jh=(r,e)=>{let t=Dh(r.trim().replace(/^[=v]+/,""),e);return t?t.version:null};ko.exports=jh});var Mo=y((FE,Lo)=>{var kh=ve(),xh=(r,e,t,n)=>{typeof t=="string"&&(n=t,t=void 0);try{return new kh(r,t).inc(e,n).version}catch{return null}};Lo.exports=xh});var Ue=y((VE,Vo)=>{var Fo=ve(),Lh=(r,e,t)=>new Fo(r,t).compare(new Fo(e,t));Vo.exports=Lh});var Mn=y((UE,Uo)=>{var Mh=Ue(),Fh=(r,e,t)=>Mh(r,e,t)===0;Uo.exports=Fh});var zo=y((HE,Go)=>{var Ho=Vt(),Vh=Mn(),Uh=(r,e)=>{if(Vh(r,e))return null;{let t=Ho(r),n=Ho(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}};Go.exports=Uh});var Xo=y((GE,Ko)=>{var Hh=ve(),Gh=(r,e)=>new Hh(r,e).major;Ko.exports=Gh});var Wo=y((zE,Bo)=>{var zh=ve(),Kh=(r,e)=>new zh(r,e).minor;Bo.exports=Kh});var Yo=y((KE,Jo)=>{var Xh=ve(),Bh=(r,e)=>new Xh(r,e).patch;Jo.exports=Bh});var Qo=y((XE,Zo)=>{var Wh=Vt(),Jh=(r,e)=>{let t=Wh(r,e);return t&&t.prerelease.length?t.prerelease:null};Zo.exports=Jh});var tc=y((BE,ec)=>{var Yh=Ue(),Zh=(r,e,t)=>Yh(e,r,t);ec.exports=Zh});var nc=y((WE,rc)=>{var Qh=Ue(),ep=(r,e)=>Qh(r,e,!0);rc.exports=ep});var Fn=y((JE,ic)=>{var sc=ve(),tp=(r,e,t)=>{let n=new sc(r,t),s=new sc(e,t);return n.compare(s)||n.compareBuild(s)};ic.exports=tp});var oc=y((YE,ac)=>{var rp=Fn(),np=(r,e)=>r.sort((t,n)=>rp(t,n,e));ac.exports=np});var uc=y((ZE,cc)=>{var sp=Fn(),ip=(r,e)=>r.sort((t,n)=>sp(n,t,e));cc.exports=ip});var Kr=y((QE,lc)=>{var ap=Ue(),op=(r,e,t)=>ap(r,e,t)>0;lc.exports=op});var Vn=y((ew,fc)=>{var cp=Ue(),up=(r,e,t)=>cp(r,e,t)<0;fc.exports=up});var Fs=y((tw,dc)=>{var lp=Ue(),fp=(r,e,t)=>lp(r,e,t)!==0;dc.exports=fp});var Un=y((rw,hc)=>{var dp=Ue(),hp=(r,e,t)=>dp(r,e,t)>=0;hc.exports=hp});var Hn=y((nw,pc)=>{var pp=Ue(),mp=(r,e,t)=>pp(r,e,t)<=0;pc.exports=mp});var Vs=y((sw,mc)=>{var gp=Mn(),vp=Fs(),_p=Kr(),yp=Un(),$p=Vn(),Ep=Hn(),wp=(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 gp(r,t,n);case"!=":return vp(r,t,n);case">":return _p(r,t,n);case">=":return yp(r,t,n);case"<":return $p(r,t,n);case"<=":return Ep(r,t,n);default:throw new TypeError(`Invalid operator: ${e}`)}};mc.exports=wp});var vc=y((iw,gc)=>{var bp=ve(),Sp=Vt(),{re:Gn,t:zn}=Ft(),Op=(r,e)=>{if(r instanceof bp)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(Gn[zn.COERCE]);else{let n;for(;(n=Gn[zn.COERCERTL].exec(r))&&(!t||t.index+t[0].length!==r.length);)(!t||n.index+n[0].length!==t.index+t[0].length)&&(t=n),Gn[zn.COERCERTL].lastIndex=n.index+n[1].length+n[2].length;Gn[zn.COERCERTL].lastIndex=-1}return t===null?null:Sp(`${t[2]}.${t[3]||"0"}.${t[4]||"0"}`,e)};gc.exports=Op});var yc=y((aw,_c)=>{"use strict";_c.exports=function(r){r.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}});var Ec=y((ow,$c)=>{"use strict";$c.exports=X;X.Node=Ut;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++)Rp(this,arguments[r]);return this.length};X.prototype.unshift=function(){for(var r=0,e=arguments.length;r<e;r++)Cp(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=Pp(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 Pp(r,e,t){var n=e===r.head?new Ut(t,null,e,r):new Ut(t,e,e.next,r);return n.next===null&&(r.tail=n),n.prev===null&&(r.head=n),r.length++,n}function Rp(r,e){r.tail=new Ut(e,r.tail,null,r),r.head||(r.head=r.tail),r.length++}function Cp(r,e){r.head=new Ut(e,null,r.head,r),r.tail||(r.tail=r.head),r.length++}function Ut(r,e,t,n){if(!(this instanceof Ut))return new Ut(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{yc()(X)}catch{}});var Cc=y((cw,Rc)=>{"use strict";var Np=Ec(),Ht=Symbol("max"),_t=Symbol("length"),ur=Symbol("lengthCalculator"),Br=Symbol("allowStale"),Gt=Symbol("maxAge"),vt=Symbol("dispose"),wc=Symbol("noDisposeOnSet"),fe=Symbol("lruList"),Xe=Symbol("cache"),Sc=Symbol("updateAgeOnGet"),Us=()=>1,Oc=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||Us;if(this[ur]=typeof n!="function"?Us:n,this[Br]=e.stale||!1,e.maxAge&&typeof e.maxAge!="number")throw new TypeError("maxAge must be a number");this[Gt]=e.maxAge||0,this[vt]=e.dispose,this[wc]=e.noDisposeOnSet||!1,this[Sc]=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,Xr(this)}get max(){return this[Ht]}set allowStale(e){this[Br]=!!e}get allowStale(){return this[Br]}set maxAge(e){if(typeof e!="number")throw new TypeError("maxAge must be a non-negative number");this[Gt]=e,Xr(this)}get maxAge(){return this[Gt]}set lengthCalculator(e){typeof e!="function"&&(e=Us),e!==this[ur]&&(this[ur]=e,this[_t]=0,this[fe].forEach(t=>{t.length=this[ur](t.value,t.key),this[_t]+=t.length})),Xr(this)}get lengthCalculator(){return this[ur]}get length(){return this[_t]}get itemCount(){return this[fe].length}rforEach(e,t){t=t||this;for(let n=this[fe].tail;n!==null;){let s=n.prev;bc(this,e,n,t),n=s}}forEach(e,t){t=t||this;for(let n=this[fe].head;n!==null;){let s=n.next;bc(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[vt]&&this[fe]&&this[fe].length&&this[fe].forEach(e=>this[vt](e.key,e.value)),this[Xe]=new Map,this[fe]=new Np,this[_t]=0}dump(){return this[fe].map(e=>Kn(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[Gt],n&&typeof n!="number")throw new TypeError("maxAge must be a number");let s=n?Date.now():0,i=this[ur](t,e);if(this[Xe].has(e)){if(i>this[Ht])return lr(this,this[Xe].get(e)),!1;let u=this[Xe].get(e).value;return this[vt]&&(this[wc]||this[vt](e,u.value)),u.now=s,u.maxAge=n,u.value=t,this[_t]+=i-u.length,u.length=i,this.get(e),Xr(this),!0}let a=new Pc(e,t,i,s,n);return a.length>this[Ht]?(this[vt]&&this[vt](e,t),!1):(this[_t]+=a.length,this[fe].unshift(a),this[Xe].set(e,this[fe].head),Xr(this),!0)}has(e){if(!this[Xe].has(e))return!1;let t=this[Xe].get(e).value;return!Kn(this,t)}get(e){return Hs(this,e,!0)}peek(e){return Hs(this,e,!1)}pop(){let e=this[fe].tail;return e?(lr(this,e),e.value):null}del(e){lr(this,this[Xe].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[Xe].forEach((e,t)=>Hs(this,t,!1))}},Hs=(r,e,t)=>{let n=r[Xe].get(e);if(n){let s=n.value;if(Kn(r,s)){if(lr(r,n),!r[Br])return}else t&&(r[Sc]&&(n.value.now=Date.now()),r[fe].unshiftNode(n));return s.value}},Kn=(r,e)=>{if(!e||!e.maxAge&&!r[Gt])return!1;let t=Date.now()-e.now;return e.maxAge?t>e.maxAge:r[Gt]&&t>r[Gt]},Xr=r=>{if(r[_t]>r[Ht])for(let e=r[fe].tail;r[_t]>r[Ht]&&e!==null;){let t=e.prev;lr(r,e),e=t}},lr=(r,e)=>{if(e){let t=e.value;r[vt]&&r[vt](t.key,t.value),r[_t]-=t.length,r[Xe].delete(t.key),r[fe].removeNode(e)}},Pc=class{constructor(e,t,n,s,i){this.key=e,this.value=t,this.length=n,this.now=s,this.maxAge=i||0}},bc=(r,e,t,n)=>{let s=t.value;Kn(r,s)&&(lr(r,t),r[Br]||(s=void 0)),s&&e.call(n,s.value,s.key,r)};Rc.exports=Oc});var He=y((uw,Tc)=>{var fr=class{constructor(e,t){if(t=Ap(t),e instanceof fr)return e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease?e:new fr(e.raw,t);if(e instanceof Gs)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(/\s*\|\|\s*/).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=>!Ic(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&&kp(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=Nc.get(n);if(s)return s;let i=this.options.loose,a=i?_e[de.HYPHENRANGELOOSE]:_e[de.HYPHENRANGE];e=e.replace(a,Kp(this.options.includePrerelease)),ae("hyphen replace",e),e=e.replace(_e[de.COMPARATORTRIM],qp),ae("comparator trim",e,_e[de.COMPARATORTRIM]),e=e.replace(_e[de.TILDETRIM],Dp),e=e.replace(_e[de.CARETTRIM],jp),e=e.split(/\s+/).join(" ");let c=i?_e[de.COMPARATORLOOSE]:_e[de.COMPARATOR],u=e.split(" ").map(g=>xp(g,this.options)).join(" ").split(/\s+/).map(g=>zp(g,this.options)).filter(this.options.loose?g=>!!g.match(c):()=>!0).map(g=>new Gs(g,this.options)),o=u.length,l=new Map;for(let g of u){if(Ic(g))return[g];l.set(g.value,g)}l.size>1&&l.has("")&&l.delete("");let h=[...l.values()];return Nc.set(n,h),h}intersects(e,t){if(!(e instanceof fr))throw new TypeError("a Range is required");return this.set.some(n=>Ac(n,t)&&e.set.some(s=>Ac(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 Tp(e,this.options)}catch{return!1}for(let t=0;t<this.set.length;t++)if(Xp(this.set[t],e,this.options))return!0;return!1}};Tc.exports=fr;var Ip=Cc(),Nc=new Ip({max:1e3}),Ap=Gr(),Gs=Wr(),ae=Hr(),Tp=ve(),{re:_e,t:de,comparatorTrimReplace:qp,tildeTrimReplace:Dp,caretTrimReplace:jp}=Ft(),Ic=r=>r.value==="<0.0.0-0",kp=r=>r.value==="",Ac=(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},xp=(r,e)=>(ae("comp",r,e),r=Fp(r,e),ae("caret",r),r=Lp(r,e),ae("tildes",r),r=Up(r,e),ae("xrange",r),r=Gp(r,e),ae("stars",r),r),we=r=>!r||r.toLowerCase()==="x"||r==="*",Lp=(r,e)=>r.trim().split(/\s+/).map(t=>Mp(t,e)).join(" "),Mp=(r,e)=>{let t=e.loose?_e[de.TILDELOOSE]:_e[de.TILDE];return r.replace(t,(n,s,i,a,c)=>{ae("tilde",r,n,s,i,a,c);let u;return we(s)?u="":we(i)?u=`>=${s}.0.0 <${+s+1}.0.0-0`:we(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})},Fp=(r,e)=>r.trim().split(/\s+/).map(t=>Vp(t,e)).join(" "),Vp=(r,e)=>{ae("caret",r,e);let t=e.loose?_e[de.CARETLOOSE]:_e[de.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 we(i)?o="":we(a)?o=`>=${i}.0.0${n} <${+i+1}.0.0-0`:we(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})},Up=(r,e)=>(ae("replaceXRanges",r,e),r.split(/\s+/).map(t=>Hp(t,e)).join(" ")),Hp=(r,e)=>{r=r.trim();let t=e.loose?_e[de.XRANGELOOSE]:_e[de.XRANGE];return r.replace(t,(n,s,i,a,c,u)=>{ae("xRange",r,n,s,i,a,c,u);let o=we(i),l=o||we(a),h=l||we(c),g=h;return s==="="&&g&&(s=""),u=e.includePrerelease?"-0":"",o?s===">"||s==="<"?n="<0.0.0-0":n="*":s&&g?(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`:h&&(n=`>=${i}.${a}.0${u} <${i}.${+a+1}.0-0`),ae("xRange return",n),n})},Gp=(r,e)=>(ae("replaceStars",r,e),r.trim().replace(_e[de.STAR],"")),zp=(r,e)=>(ae("replaceGTE0",r,e),r.trim().replace(_e[e.includePrerelease?de.GTE0PRE:de.GTE0],"")),Kp=r=>(e,t,n,s,i,a,c,u,o,l,h,g,v)=>(we(n)?t="":we(s)?t=`>=${n}.0.0${r?"-0":""}`:we(i)?t=`>=${n}.${s}.0${r?"-0":""}`:a?t=`>=${t}`:t=`>=${t}${r?"-0":""}`,we(o)?u="":we(l)?u=`<${+o+1}.0.0-0`:we(h)?u=`<${o}.${+l+1}.0-0`:g?u=`<=${o}.${l}.${h}-${g}`:r?u=`<${o}.${l}.${+h+1}-0`:u=`<=${u}`,`${t} ${u}`.trim()),Xp=(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!==Gs.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 Wr=y((lw,xc)=>{var Jr=Symbol("SemVer ANY"),Yr=class{static get ANY(){return Jr}constructor(e,t){if(t=Bp(t),e instanceof Yr){if(e.loose===!!t.loose)return e;e=e.value}Ks("comparator",e,t),this.options=t,this.loose=!!t.loose,this.parse(e),this.semver===Jr?this.value="":this.value=this.operator+this.semver.version,Ks("comp",this)}parse(e){let t=this.options.loose?qc[Dc.COMPARATORLOOSE]:qc[Dc.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 jc(n[2],this.options.loose):this.semver=Jr}toString(){return this.value}test(e){if(Ks("Comparator.test",e,this.options.loose),this.semver===Jr||e===Jr)return!0;if(typeof e=="string")try{e=new jc(e,this.options)}catch{return!1}return zs(e,this.operator,this.semver,this.options)}intersects(e,t){if(!(e instanceof Yr))throw new TypeError("a Comparator is required");if((!t||typeof t!="object")&&(t={loose:!!t,includePrerelease:!1}),this.operator==="")return this.value===""?!0:new kc(e.value,t).test(this.value);if(e.operator==="")return e.value===""?!0:new kc(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=zs(this.semver,"<",e.semver,t)&&(this.operator===">="||this.operator===">")&&(e.operator==="<="||e.operator==="<"),u=zs(this.semver,">",e.semver,t)&&(this.operator==="<="||this.operator==="<")&&(e.operator===">="||e.operator===">");return n||s||i&&a||c||u}};xc.exports=Yr;var Bp=Gr(),{re:qc,t:Dc}=Ft(),zs=Vs(),Ks=Hr(),jc=ve(),kc=He()});var Zr=y((fw,Lc)=>{var Wp=He(),Jp=(r,e,t)=>{try{e=new Wp(e,t)}catch{return!1}return e.test(r)};Lc.exports=Jp});var Fc=y((dw,Mc)=>{var Yp=He(),Zp=(r,e)=>new Yp(r,e).set.map(t=>t.map(n=>n.value).join(" ").trim().split(" "));Mc.exports=Zp});var Uc=y((hw,Vc)=>{var Qp=ve(),em=He(),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};Vc.exports=tm});var Gc=y((pw,Hc)=>{var rm=ve(),nm=He(),sm=(r,e,t)=>{let n=null,s=null,i=null;try{i=new nm(e,t)}catch{return null}return r.forEach(a=>{i.test(a)&&(!n||s.compare(a)===1)&&(n=a,s=new rm(n,t))}),n};Hc.exports=sm});var Xc=y((mw,Kc)=>{var Xs=ve(),im=He(),zc=Kr(),am=(r,e)=>{r=new im(r,e);let t=new Xs("0.0.0");if(r.test(t)||(t=new Xs("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 Xs(a.semver.version);switch(a.operator){case">":c.prerelease.length===0?c.patch++:c.prerelease.push(0),c.raw=c.format();case"":case">=":(!i||zc(c,i))&&(i=c);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${a.operator}`)}}),i&&(!t||zc(t,i))&&(t=i)}return t&&r.test(t)?t:null};Kc.exports=am});var Wc=y((gw,Bc)=>{var om=He(),cm=(r,e)=>{try{return new om(r,e).range||"*"}catch{return null}};Bc.exports=cm});var Xn=y((vw,Qc)=>{var um=ve(),Zc=Wr(),{ANY:lm}=Zc,fm=He(),dm=Zr(),Jc=Kr(),Yc=Vn(),hm=Hn(),pm=Un(),mm=(r,e,t,n)=>{r=new um(r,n),e=new fm(e,n);let s,i,a,c,u;switch(t){case">":s=Jc,i=hm,a=Yc,c=">",u=">=";break;case"<":s=Yc,i=pm,a=Jc,c="<",u="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(dm(r,e,n))return!1;for(let o=0;o<e.set.length;++o){let l=e.set[o],h=null,g=null;if(l.forEach(v=>{v.semver===lm&&(v=new Zc(">=0.0.0")),h=h||v,g=g||v,s(v.semver,h.semver,n)?h=v:a(v.semver,g.semver,n)&&(g=v)}),h.operator===c||h.operator===u||(!g.operator||g.operator===c)&&i(r,g.semver))return!1;if(g.operator===u&&a(r,g.semver))return!1}return!0};Qc.exports=mm});var tu=y((_w,eu)=>{var gm=Xn(),vm=(r,e,t)=>gm(r,e,">",t);eu.exports=vm});var nu=y((yw,ru)=>{var _m=Xn(),ym=(r,e,t)=>_m(r,e,"<",t);ru.exports=ym});var au=y(($w,iu)=>{var su=He(),$m=(r,e,t)=>(r=new su(r,t),e=new su(e,t),r.intersects(e));iu.exports=$m});var cu=y((Ew,ou)=>{var Em=Zr(),wm=Ue();ou.exports=(r,e,t)=>{let n=[],s=null,i=null,a=r.sort((l,h)=>wm(l,h,t));for(let l of a)Em(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,h]of n)l===h?c.push(l):!h&&l===a[0]?c.push("*"):h?l===a[0]?c.push(`<=${h}`):c.push(`${l} - ${h}`):c.push(`>=${l}`);let u=c.join(" || "),o=typeof e.raw=="string"?e.raw:String(e);return u.length<o.length?u:e}});var hu=y((ww,du)=>{var uu=He(),Bn=Wr(),{ANY:Bs}=Bn,Qr=Zr(),Ws=Ue(),bm=(r,e,t={})=>{if(r===e)return!0;r=new uu(r,t),e=new uu(e,t);let n=!1;e:for(let s of r.set){for(let i of e.set){let a=Sm(s,i,t);if(n=n||a!==null,a)continue e}if(n)return!1}return!0},Sm=(r,e,t)=>{if(r===e)return!0;if(r.length===1&&r[0].semver===Bs){if(e.length===1&&e[0].semver===Bs)return!0;t.includePrerelease?r=[new Bn(">=0.0.0-0")]:r=[new Bn(">=0.0.0")]}if(e.length===1&&e[0].semver===Bs){if(t.includePrerelease)return!0;e=[new Bn(">=0.0.0")]}let n=new Set,s,i;for(let v of r)v.operator===">"||v.operator===">="?s=lu(s,v,t):v.operator==="<"||v.operator==="<="?i=fu(i,v,t):n.add(v.semver);if(n.size>1)return null;let a;if(s&&i){if(a=Ws(s.semver,i.semver,t),a>0)return null;if(a===0&&(s.operator!==">="||i.operator!=="<="))return null}for(let v of n){if(s&&!Qr(v,String(s),t)||i&&!Qr(v,String(i),t))return null;for(let $ of e)if(!Qr(v,String($),t))return!1;return!0}let c,u,o,l,h=i&&!t.includePrerelease&&i.semver.prerelease.length?i.semver:!1,g=s&&!t.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(l=l||v.operator===">"||v.operator===">=",o=o||v.operator==="<"||v.operator==="<=",s){if(g&&v.semver.prerelease&&v.semver.prerelease.length&&v.semver.major===g.major&&v.semver.minor===g.minor&&v.semver.patch===g.patch&&(g=!1),v.operator===">"||v.operator===">="){if(c=lu(s,v,t),c===v&&c!==s)return!1}else if(s.operator===">="&&!Qr(s.semver,String(v),t))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(u=fu(i,v,t),u===v&&u!==i)return!1}else if(i.operator==="<="&&!Qr(i.semver,String(v),t))return!1}if(!v.operator&&(i||s)&&a!==0)return!1}return!(s&&o&&!i&&a!==0||i&&l&&!s&&a!==0||g||h)},lu=(r,e,t)=>{if(!r)return e;let n=Ws(r.semver,e.semver,t);return n>0?r:n<0||e.operator===">"&&r.operator===">="?e:r},fu=(r,e,t)=>{if(!r)return e;let n=Ws(r.semver,e.semver,t);return n<0?r:n>0||e.operator==="<"&&r.operator==="<="?e:r};du.exports=bm});var mu=y((bw,pu)=>{var Js=Ft();pu.exports={re:Js.re,src:Js.src,tokens:Js.t,SEMVER_SPEC_VERSION:Ur().SEMVER_SPEC_VERSION,SemVer:ve(),compareIdentifiers:kn().compareIdentifiers,rcompareIdentifiers:kn().rcompareIdentifiers,parse:Vt(),valid:jo(),clean:xo(),inc:Mo(),diff:zo(),major:Xo(),minor:Wo(),patch:Yo(),prerelease:Qo(),compare:Ue(),rcompare:tc(),compareLoose:nc(),compareBuild:Fn(),sort:oc(),rsort:uc(),gt:Kr(),lt:Vn(),eq:Mn(),neq:Fs(),gte:Un(),lte:Hn(),cmp:Vs(),coerce:vc(),Comparator:Wr(),Range:He(),satisfies:Zr(),toComparators:Fc(),maxSatisfying:Uc(),minSatisfying:Gc(),minVersion:Xc(),validRange:Wc(),outside:Xn(),gtr:tu(),ltr:nu(),intersects:au(),simplifyRange:cu(),subset:hu()}});var yt=y(qe=>{"use strict";var Om=qe&&qe.__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]}),Pm=qe&&qe.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),Rm=qe&&qe.__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)&&Om(e,r,t);return Pm(e,r),e},gu=qe&&qe.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(qe,"__esModule",{value:!0});qe.getCoreVersion=void 0;var vu=gu(require("path")),_u=gu(require("fs")),Ys=Rm(require("@serverless-devs/core")),Cm=mu(),yu=vu.default.join(Ys.getRootHome(),"cache","core"),Zs=vu.default.join(yu,"package.json");function Nm(){if(_u.default.existsSync(Zs)){var r=require("@serverless-devs/core/package.json").version,e=$u();return Cm.gt(e,r)?require(yu):Ys}return Ys}function $u(){return _u.default.existsSync(Zs)?require(Zs).version:void 0}qe.getCoreVersion=$u;qe.default=Nm()});var ti=y(Pe=>{"use strict";var Im=Pe&&Pe.__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(h){a(h)}}function u(l){try{o(n.throw(l))}catch(h){a(h)}}function o(l){l.done?i(l.value):s(l.value).then(c,u)}o((n=n.apply(r,e||[])).next())})},Am=Pe&&Pe.__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}}},Eu=Pe&&Pe.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Pe,"__esModule",{value:!0});Pe.handlerProfileFile=Pe.getConfig=Pe.setConfig=void 0;var wu=Eu(require("path")),ei=Eu(yt()),it=ei.default.fse,Wn=ei.default.jsyaml,Qs=ei.default.getRootHome;function Tm(r){var e=Su();it.writeFileSync(e,Wn.dump(r))}function bu(){var r=Su();if(!it.existsSync(r))return{};try{var e=Wn.load(it.readFileSync(r,"utf8"))||{};return e}catch(t){throw t}}function Su(){var r=wu.default.join(Qs(),"set-config.yml");return it.existsSync(r)||it.createFileSync(r),r}function qm(r,e){var t=bu();t[r]=e,Tm(t)}Pe.setConfig=qm;function Dm(r,e){var t=bu();return t[r]||e}Pe.getConfig=Dm;function jm(r){return Im(this,void 0,void 0,function(){var e,t,n,s,i,a,c;return Am(this,function(u){switch(u.label){case 0:if(e=r.filePath||"set-config.yml",t=wu.default.join(Qs(),e),n=it.existsSync(t),s={},n)return[3,5];i=Qs(),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=Wn.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,Wn.dump(s))]);case 7:return u.sent(),[2,s]}})})}Pe.handlerProfileFile=jm});var Ou=y((Pw,km)=>{km.exports={name:"@serverless-devs/s",version:"2.0.101-beta.1",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:"MIT",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",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","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":"beta"}}});var Yn=y(N=>{"use strict";var xm=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]}),Lm=N&&N.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),Mm=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)&&xm(e,r,t);return Lm(e,r),e},tn=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(h){a(h)}}function u(l){try{o(n.throw(l))}catch(h){a(h)}}function o(l){l.done?i(l.value):s(l.value).then(c,u)}o((n=n.apply(r,e||[])).next())})},rn=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}}},ri=N&&N.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(N,"__esModule",{value:!0});N.emoji=N.mark=N.replaceTemplate=N.replaceFun=N.getLang=N.printn=N.getFolderSize=N.getVersion=N.getPid=N.aiRequest=N.getCredentialWithAll=N.getCredentialWithExisted=N.getProcessArgv=N.bgRed=N.yellow=N.red=void 0;var Fm=ri(require("path")),en=ri(require("fs")),Vm=ri(require("os")),Be=Mm(yt()),Um=ti(),Pu=Ou(),Jn=Be.default.colors,Hm=Be.default.got,Gm=Be.default.getMAC,zm=Be.default.isDocker,Km=Be.default.isCiCdEnv,Xm=Be.default.getGlobalArgs,Ru=Be.default.getCredential,Cu=Be.default.getCredentialAliasList,dr=Be.default.lodash,Bm=dr.get,Wm=dr.trim,Jm=dr.assign,Ym=dr.filter,Nu=dr.includes,Iu=dr.omit;N.red=Jn.hex("#fd5750");N.yellow=Jn.hex("#F3F99D");N.bgRed=Jn.hex("#000").bgHex("#fd5750");var Zm=function(){var r=process.env.serverless_devs_temp_argv;try{var e=JSON.parse(r),t=Xm(e);return process.argv=process.argv.slice(0,2).concat(t._argsObj),Jm({},t,{noHelpArgv:process.argv.slice(0,2).concat(Ym(t._argsObj,function(n){return!Nu(["-h","--help"],n)}))})}catch{return{}}};N.getProcessArgv=Zm;var Qm=function(r){return tn(void 0,void 0,void 0,function(){var e,t;return rn(this,function(n){switch(n.label){case 0:return[4,Cu()];case 1:return e=n.sent(),Nu(e,r)?[4,Ru(r)]:[3,3];case 2:return t=n.sent(),[2,Iu(t,"Alias")];case 3:return[2]}})})};N.getCredentialWithExisted=Qm;var eg=function(){return tn(void 0,void 0,void 0,function(){var r,e,t,n,s,i;return rn(this,function(a){switch(a.label){case 0:return[4,Cu()];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,Ru(s)]):[3,5];case 3:i=a.sent(),e[i.Alias]=Iu(i,"Alias"),a.label=4;case 4:return t++,[3,2];case 5:return[2,e];case 6:return[2]}})})};N.getCredentialWithAll=eg;var tg=function(r,e){return e===void 0&&(e="unknow"),tn(void 0,void 0,void 0,function(){var t,n,s,i;return rn(this,function(a){switch(a.label){case 0:return a.trys.push([0,2,,3]),t=(0,Um.getConfig)("analysis"),t!=="enable"?[2]:zm()||Km()?[2]:[4,Hm("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=Bm(n.body,"shorturl"),s&&console.log(`AI Tips:
16
- You can try to solve the problem through: `.concat(Jn.underline(s),`
17
- `)),[3,3];case 2:return i=a.sent(),[3,3];case 3:return[2]}})})};N.aiRequest=tg;var rg=function(){try{return Gm().replace(/:/g,"")}catch{return"unknown"}};N.getPid=rg;function ng(){var r=(0,Be.getCoreVersion)(),e=["".concat(Pu.name,": ").concat(Pu.version),r?"core: ".concat(r):void 0,"s-home: ".concat(Be.default.getRootHome()),"".concat(process.platform,"-").concat(process.arch),"node-".concat(process.version)];return e.filter(function(t){return t}).join(", ")}N.getVersion=ng;function sg(r){return tn(this,void 0,void 0,function(){function e(s){return tn(this,void 0,void 0,function(){var i,a;return rn(this,function(c){switch(c.label){case 0:return i=en.default.lstatSync(s),typeof i!="object"?[2]:(t.set(i.ino,i.size),i.isDirectory()?(a=en.default.readdirSync(s),typeof a!="object"?[2]:[4,Promise.all(a.map(function(u){return e(Fm.default.join(s,u))}))]):[3,2]);case 1:c.sent(),c.label=2;case 2:return[2]}})})}var t,n;return rn(this,function(s){switch(s.label){case 0:return t=new Map,[4,e(r)];case 1:return s.sent(),n=Array.from(t.values()).reduce(function(i,a){return i+a},0),[2,n]}})})}N.getFolderSize=sg;function ig(r,e){e===void 0&&(e=" ");for(var t="",n=0;n<r;n++)t=t+e;return t}N.printn=ig;function ag(){return"en"}N.getLang=ag;function Au(r,e){var t=/\{\{(.*?)\}\}/g,n=r.match(t);if(n)for(var s=0;s<n.length;s++){var i=n[s].replace(/{{|}}/g,""),a=Wm(i.split("|")[0]);e[a]&&(r=r.replace(n[s],e[a]))}return r}N.replaceFun=Au;function og(r,e){r.forEach(function(t){if(en.default.existsSync(t)){var n=en.default.readFileSync(t,"utf-8"),s=Au(n,e);en.default.writeFileSync(t,s,"utf-8")}})}N.replaceTemplate=og;function cg(r){if(!r)return r;var e=r.slice(-4);return"***********".concat(e)}N.mark=cg;function ug(r,e){return Vm.default.platform()==="win32"?e||"\u25C6":"".concat(r," ")}N.emoji=ug});var Tu=y(ni=>{"use strict";Object.defineProperty(ni,"__esModule",{value:!0});ni.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 qu=y(si=>{"use strict";Object.defineProperty(si,"__esModule",{value:!0});si.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 ai=y(nn=>{"use strict";var Du=nn&&nn.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(nn,"__esModule",{value:!0});var lg=Yn(),fg=Du(Tu()),dg=Du(qu()),ii={en:dg.default,zh:fg.default},hg=function(r){var e=(0,lg.getLang)(),t=ii[e]?ii[e][r]:ii.en[r];return t||r};nn.default=hg});var ci=y(sn=>{"use strict";var pg=sn&&sn.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(sn,"__esModule",{value:!0});var mg=pg(yt()),gg=mg.default.Logger,oi=new gg("S-CLI");oi.success=function(r){return oi.log(r,"green")};sn.default=oi});var li=y(ye=>{"use strict";var vg=ye&&ye.__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]}),ju=ye&&ye.__exportStar||function(r,e){for(var t in r)t!=="default"&&!Object.prototype.hasOwnProperty.call(e,t)&&vg(e,r,t)},ui=ye&&ye.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ye,"__esModule",{value:!0});ye.registerCommandChecker=ye.i18n=ye.logger=void 0;var _g=ui(ci());ju(Yn(),ye);ju(ti(),ye);var yg=ci();Object.defineProperty(ye,"logger",{enumerable:!0,get:function(){return ui(yg).default}});var $g=ai();Object.defineProperty(ye,"i18n",{enumerable:!0,get:function(){return ui($g).default}});function Eg(r){r.on("command:*",function(e){var t=r.commands.map(function(n){return n.name()});t.includes(e[0])||(_g.default.error(" error: unknown command ".concat(e[0])),r.help())})}ye.registerCommandChecker=Eg});var on=y(H=>{"use strict";Object.defineProperty(H,"__esModule",{value:!0});H.regexpCode=H.getEsmExportName=H.getProperty=H.safeStringify=H.stringify=H.strConcat=H.addCodeArg=H.str=H._=H.nil=H._Code=H.Name=H.IDENTIFIER=H._CodeOrName=void 0;var Zn=class{};H._CodeOrName=Zn;H.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var hr=class extends Zn{constructor(e){super();if(!H.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}}};H.Name=hr;var We=class extends Zn{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 hr&&(t[n.str]=(t[n.str]||0)+1),t),{})}};H._Code=We;H.nil=new We("");function ku(r,...e){let t=[r[0]],n=0;for(;n<e.length;)di(t,e[n]),t.push(r[++n]);return new We(t)}H._=ku;var fi=new We("+");function xu(r,...e){let t=[an(r[0])],n=0;for(;n<e.length;)t.push(fi),di(t,e[n]),t.push(fi,an(r[++n]));return wg(t),new We(t)}H.str=xu;function di(r,e){e instanceof We?r.push(...e._items):e instanceof hr?r.push(e):r.push(Og(e))}H.addCodeArg=di;function wg(r){let e=1;for(;e<r.length-1;){if(r[e]===fi){let t=bg(r[e-1],r[e+1]);if(t!==void 0){r.splice(e-1,3,t);continue}r[e++]="+"}e++}}function bg(r,e){if(e==='""')return r;if(r==='""')return e;if(typeof r=="string")return e instanceof hr||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 hr))return`"${r}${e.slice(1)}`}function Sg(r,e){return e.emptyStr()?r:r.emptyStr()?e:xu`${r}${e}`}H.strConcat=Sg;function Og(r){return typeof r=="number"||typeof r=="boolean"||r===null?r:an(Array.isArray(r)?r.join(","):r)}function Pg(r){return new We(an(r))}H.stringify=Pg;function an(r){return JSON.stringify(r).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}H.safeStringify=an;function Rg(r){return typeof r=="string"&&H.IDENTIFIER.test(r)?new We(`.${r}`):ku`[${r}]`}H.getProperty=Rg;function Cg(r){if(typeof r=="string"&&H.IDENTIFIER.test(r))return new We(`${r}`);throw new Error(`CodeGen: invalid export name: ${r}, use explicit $id name mapping`)}H.getEsmExportName=Cg;function Ng(r){return new We(r.toString())}H.regexpCode=Ng});var gi=y(be=>{"use strict";Object.defineProperty(be,"__esModule",{value:!0});be.ValueScope=be.ValueScopeName=be.Scope=be.varKinds=be.UsedValueState=void 0;var Re=on(),Lu=class extends Error{constructor(e){super(`CodeGen: "code" for ${e} not defined`);this.value=e.value}},hi;(function(r){r[r.Started=0]="Started",r[r.Completed=1]="Completed"})(hi=be.UsedValueState||(be.UsedValueState={}));be.varKinds={const:new Re.Name("const"),let:new Re.Name("let"),var:new Re.Name("var")};var pi=class{constructor({prefixes:e,parent:t}={}){this._names={},this._prefixes=e,this._parent=t}toName(e){return e instanceof Re.Name?e:this.name(e)}name(e){return new Re.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=pi;var mi=class extends Re.Name{constructor(e,t){super(t);this.prefix=e}setValue(e,{property:t,itemIndex:n}){this.value=e,this.scopePath=(0,Re._)`.${new Re.Name(t)}[${n}]`}};be.ValueScopeName=mi;var Ig=(0,Re._)`\n`,Mu=class extends pi{constructor(e){super(e);this._values={},this._scope=e.scope,this.opts=Fe(ie({},e),{_n:e.lines?Ig:Re.nil})}get(){return this._scope}name(e){return new mi(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,Re._)`${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=Re.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,hi.Started);let l=t(o);if(l){let h=this.opts.es5?be.varKinds.var:be.varKinds.const;i=(0,Re._)`${i}${h} ${o} = ${l};${this.opts._n}`}else if(l=s==null?void 0:s(o))i=(0,Re._)`${i}${l}${this.opts._n}`;else throw new Lu(o);u.set(o,hi.Completed)})}return i}};be.ValueScope=Mu});var L=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 M=on(),Je=gi(),Ot=on();Object.defineProperty(k,"_",{enumerable:!0,get:function(){return Ot._}});Object.defineProperty(k,"str",{enumerable:!0,get:function(){return Ot.str}});Object.defineProperty(k,"strConcat",{enumerable:!0,get:function(){return Ot.strConcat}});Object.defineProperty(k,"nil",{enumerable:!0,get:function(){return Ot.nil}});Object.defineProperty(k,"getProperty",{enumerable:!0,get:function(){return Ot.getProperty}});Object.defineProperty(k,"stringify",{enumerable:!0,get:function(){return Ot.stringify}});Object.defineProperty(k,"regexpCode",{enumerable:!0,get:function(){return Ot.regexpCode}});Object.defineProperty(k,"Name",{enumerable:!0,get:function(){return Ot.Name}});var ss=gi();Object.defineProperty(k,"Scope",{enumerable:!0,get:function(){return ss.Scope}});Object.defineProperty(k,"ValueScope",{enumerable:!0,get:function(){return ss.ValueScope}});Object.defineProperty(k,"ValueScopeName",{enumerable:!0,get:function(){return ss.ValueScopeName}});Object.defineProperty(k,"varKinds",{enumerable:!0,get:function(){return ss.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 Pt=class{optimizeNodes(){return this}optimizeNames(e,t){return this}},Fu=class extends Pt{constructor(e,t,n){super();this.varKind=e,this.name=t,this.rhs=n}render({es5:e,_n:t}){let n=e?Je.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=mr(this.rhs,e,t)),this}get names(){return this.rhs instanceof M._CodeOrName?this.rhs.names:{}}},yi=class extends Pt{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=mr(this.rhs,e,t),this}get names(){let e=this.lhs instanceof M.Name?{}:ie({},this.lhs.names);return ns(e,this.rhs)}},Vu=class extends yi{constructor(e,t,n,s){super(e,n,s);this.op=t}render({_n:e}){return`${this.lhs} ${this.op}= ${this.rhs};`+e}},Uu=class extends Pt{constructor(e){super();this.label=e,this.names={}}render({_n:e}){return`${this.label}:`+e}},Hu=class extends Pt{constructor(e){super();this.label=e,this.names={}}render({_n:e}){return`break${this.label?` ${this.label}`:""};`+e}},Gu=class extends Pt{constructor(e){super();this.error=e}render({_n:e}){return`throw ${this.error};`+e}get names(){return this.error.names}},zu=class extends Pt{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=mr(this.code,e,t),this}get names(){return this.code instanceof M._CodeOrName?this.code.names:{}}},is=class extends Pt{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)||(Ag(e,i.names),n.splice(s,1))}return n.length>0?this:void 0}get names(){return this.nodes.reduce((e,t)=>zt(e,t.names),{})}},Rt=class extends is{render(e){return"{"+e._n+super.render(e)+"}"+e._n}},Ku=class extends is{},cn=class extends Rt{};cn.kind="else";var at=class extends Rt{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 cn(n):n}if(t)return e===!1?t instanceof at?t:t.nodes:this.nodes.length?this:new at(Yu(e),t instanceof at?[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=mr(this.condition,e,t),this}get names(){let e=super.names;return ns(e,this.condition),this.else&&zt(e,this.else.names),e}};at.kind="if";var pr=class extends Rt{};pr.kind="for";var Xu=class extends pr{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=mr(this.iteration,e,t),this}get names(){return zt(super.names,this.iteration.names)}},Bu=class extends pr{constructor(e,t,n,s){super();this.varKind=e,this.name=t,this.from=n,this.to=s}render(e){let t=e.es5?Je.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=ns(super.names,this.from);return ns(e,this.to)}},vi=class extends pr{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=mr(this.iterable,e,t),this}get names(){return zt(super.names,this.iterable.names)}},Qn=class extends Rt{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)}};Qn.kind="func";var es=class extends is{render(e){return"return "+super.render(e)}};es.kind="return";var Wu=class extends Rt{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&&zt(e,this.catch.names),this.finally&&zt(e,this.finally.names),e}},ts=class extends Rt{constructor(e){super();this.error=e}render(e){return`catch(${this.error})`+super.render(e)}};ts.kind="catch";var rs=class extends Rt{render(e){return"finally"+super.render(e)}};rs.kind="finally";var Ju=class{constructor(e,t={}){this._values={},this._blockStarts=[],this._constants={},this.opts=Fe(ie({},t),{_n:t.lines?`
18
- `:""}),this._extScope=e,this._scope=new Je.Scope({parent:e}),this._nodes=[new Ku]}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 Fu(e,i,n)),i}const(e,t,n){return this._def(Je.varKinds.const,e,t,n)}let(e,t,n){return this._def(Je.varKinds.let,e,t,n)}var(e,t,n){return this._def(Je.varKinds.var,e,t,n)}assign(e,t,n){return this._leafNode(new yi(e,t,n))}add(e,t){return this._leafNode(new Vu(e,k.operators.ADD,t))}code(e){return typeof e=="function"?e():e!==M.nil&&this._leafNode(new zu(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 at(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 at(e))}else(){return this._elseNode(new cn)}endIf(){return this._endBlockNode(at,cn)}_for(e,t){return this._blockNode(e),t&&this.code(t).endFor(),this}for(e,t){return this._for(new Xu(e),t)}forRange(e,t,n,s,i=this.opts.es5?Je.varKinds.var:Je.varKinds.let){let a=this._scope.toName(e);return this._for(new Bu(i,a,t,n),()=>s(a))}forOf(e,t,n,s=Je.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 vi("of",s,i,t),()=>n(i))}forIn(e,t,n,s=this.opts.es5?Je.varKinds.var:Je.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 vi("in",s,i,t),()=>n(i))}endFor(){return this._endBlockNode(pr)}label(e){return this._leafNode(new Uu(e))}break(e){return this._leafNode(new Hu(e))}return(e){let t=new es;if(this._blockNode(t),this.code(e),t.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(es)}try(e,t,n){if(!t&&!n)throw new Error('CodeGen: "try" without "catch" and "finally"');let s=new Wu;if(this._blockNode(s),this.code(e),t){let i=this.name("e");this._currNode=s.catch=new ts(i),t(i)}return n&&(this._currNode=s.finally=new rs,this.code(n)),this._endBlockNode(ts,rs)}throw(e){return this._leafNode(new Gu(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 Qn(e,t,n)),s&&this.code(s).endFunc(),this}endFunc(){return this._endBlockNode(Qn)}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 at))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=Ju;function zt(r,e){for(let t in e)r[t]=(r[t]||0)+(e[t]||0);return r}function ns(r,e){return e instanceof M._CodeOrName?zt(r,e.names):r}function mr(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 Ag(r,e){for(let t in e)r[t]=(r[t]||0)-(e[t]||0)}function Yu(r){return typeof r=="boolean"||typeof r=="number"||r===null?!r:(0,M._)`!${_i(r)}`}k.not=Yu;var Tg=Zu(k.operators.AND);function qg(...r){return r.reduce(Tg)}k.and=qg;var Dg=Zu(k.operators.OR);function jg(...r){return r.reduce(Dg)}k.or=jg;function Zu(r){return(e,t)=>e===M.nil?t:t===M.nil?e:(0,M._)`${_i(e)} ${r} ${_i(t)}`}function _i(r){return r instanceof M.Name?r:(0,M._)`(${r})`}});var G=y(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(),kg=on();function xg(r){let e={};for(let t of r)e[t]=!0;return e}x.toHash=xg;function Lg(r,e){return typeof e=="boolean"?e:Object.keys(e).length===0?!0:(tl(r,e),!rl(e,r.self.RULES.all))}x.alwaysValidSchema=Lg;function tl(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]||al(r,`unknown keyword: "${i}"`)}x.checkUnknownRules=tl;function rl(r,e){if(typeof r=="boolean")return!r;for(let t in r)if(e[t])return!0;return!1}x.schemaHasRules=rl;function Mg(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=Mg;function Fg({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=Fg;function Vg(r){return nl(decodeURIComponent(r))}x.unescapeFragment=Vg;function Ug(r){return encodeURIComponent($i(r))}x.escapeFragment=Ug;function $i(r){return typeof r=="number"?`${r}`:r.replace(/~/g,"~0").replace(/\//g,"~1")}x.escapeJsonPointer=$i;function nl(r){return r.replace(/~1/g,"/").replace(/~0/g,"~")}x.unescapeJsonPointer=nl;function Hg(r,e){if(Array.isArray(r))for(let t of r)e(t);else e(r)}x.eachItem=Hg;function Qu({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:Qu({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} || {}`),Ei(r,t,e))}),mergeValues:(r,e)=>r===!0?!0:ie(ie({},r),e),resultToName:sl}),items:Qu({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 sl(r,e){if(e===!0)return r.var("props",!0);let t=r.var("props",(0,Z._)`{}`);return e!==void 0&&Ei(r,t,e),t}x.evaluatedPropsToName=sl;function Ei(r,e,t){Object.keys(t).forEach(n=>r.assign((0,Z._)`${e}${(0,Z.getProperty)(n)}`,!0))}x.setEvaluated=Ei;var el={};function Gg(r,e){return r.scopeValue("func",{ref:e,code:el[e.code]||(el[e.code]=new kg._Code(e.code))})}x.useFunc=Gg;var il;(function(r){r[r.Num=0]="Num",r[r.Str=1]="Str"})(il=x.Type||(x.Type={}));function zg(r,e,t){if(r instanceof Z.Name){let n=e===il.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():"/"+$i(r)}x.getErrorPath=zg;function al(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=al});var $t=y(wi=>{"use strict";Object.defineProperty(wi,"__esModule",{value:!0});var $e=L(),Kg={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")};wi.default=Kg});var un=y(Ee=>{"use strict";Object.defineProperty(Ee,"__esModule",{value:!0});Ee.extendErrors=Ee.resetErrorsCount=Ee.reportExtraError=Ee.reportError=Ee.keyword$DataError=Ee.keywordError=void 0;var V=L(),as=G(),Se=$t();Ee.keywordError={message:({keyword:r})=>(0,V.str)`must pass "${r}" keyword validation`};Ee.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 Xg(r,e=Ee.keywordError,t,n){let{it:s}=r,{gen:i,compositeRule:a,allErrors:c}=s,u=ul(r,e,t);(n!=null?n:a||c)?ol(i,u):cl(s,(0,V._)`[${u}]`)}Ee.reportError=Xg;function Bg(r,e=Ee.keywordError,t){let{it:n}=r,{gen:s,compositeRule:i,allErrors:a}=n,c=ul(r,e,t);ol(s,c),i||a||cl(n,Se.default.vErrors)}Ee.reportExtraError=Bg;function Wg(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)))}Ee.resetErrorsCount=Wg;function Jg({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))})}Ee.extendErrors=Jg;function ol(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 cl(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 Kt={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 ul(r,e,t){let{createErrors:n}=r.it;return n===!1?(0,V._)`{}`:Yg(r,e,t)}function Yg(r,e,t={}){let{gen:n,it:s}=r,i=[Zg(s,t),Qg(r,t)];return ev(r,e,i),n.object(...i)}function Zg({errorPath:r},{instancePath:e}){let t=e?(0,V.str)`${r}${(0,as.getErrorPath)(e,as.Type.Str)}`:r;return[Se.default.instancePath,(0,V.strConcat)(Se.default.instancePath,t)]}function Qg({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,as.getErrorPath)(t,as.Type.Str)}`),[Kt.schemaPath,s]}function ev(r,{params:e,message:t},n){let{keyword:s,data:i,schemaValue:a,it:c}=r,{opts:u,propertyName:o,topSchemaRef:l,schemaPath:h}=c;n.push([Kt.keyword,s],[Kt.params,typeof e=="function"?e(r):e||(0,V._)`{}`]),u.messages&&n.push([Kt.message,typeof t=="function"?t(r):t]),u.verbose&&n.push([Kt.schema,a],[Kt.parentSchema,(0,V._)`${l}${h}`],[Se.default.data,i]),o&&n.push([Kt.propertyName,o])}});var fl=y(gr=>{"use strict";Object.defineProperty(gr,"__esModule",{value:!0});gr.boolOrEmptySchema=gr.topBoolOrEmptySchema=void 0;var tv=un(),rv=L(),nv=$t(),sv={message:"boolean schema is false"};function iv(r){let{gen:e,schema:t,validateName:n}=r;t===!1?ll(r,!1):typeof t=="object"&&t.$async===!0?e.return(nv.default.data):(e.assign((0,rv._)`${n}.errors`,null),e.return(!0))}gr.topBoolOrEmptySchema=iv;function av(r,e){let{gen:t,schema:n}=r;n===!1?(t.var(e,!1),ll(r)):t.var(e,!0)}gr.boolOrEmptySchema=av;function ll(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,tv.reportError)(s,sv,void 0,e)}});var bi=y(vr=>{"use strict";Object.defineProperty(vr,"__esModule",{value:!0});vr.getRules=vr.isJSONType=void 0;var ov=["string","number","integer","boolean","null","object","array"],cv=new Set(ov);function uv(r){return typeof r=="string"&&cv.has(r)}vr.isJSONType=uv;function lv(){let r={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:Fe(ie({},r),{integer:!0,boolean:!0,null:!0}),rules:[{rules:[]},r.number,r.string,r.array,r.object],post:{rules:[]},all:{},keywords:{}}}vr.getRules=lv});var Si=y(Ct=>{"use strict";Object.defineProperty(Ct,"__esModule",{value:!0});Ct.shouldUseRule=Ct.shouldUseGroup=Ct.schemaHasRulesForType=void 0;function fv({schema:r,self:e},t){let n=e.RULES.types[t];return n&&n!==!0&&dl(r,n)}Ct.schemaHasRulesForType=fv;function dl(r,e){return e.rules.some(t=>hl(r,t))}Ct.shouldUseGroup=dl;function hl(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))}Ct.shouldUseRule=hl});var fn=y(he=>{"use strict";Object.defineProperty(he,"__esModule",{value:!0});he.reportTypeError=he.checkDataTypes=he.checkDataType=he.coerceAndCheckDataType=he.getJSONTypes=he.getSchemaTypes=he.DataType=void 0;var dv=bi(),hv=Si(),pv=un(),q=L(),pl=G(),ln;(function(r){r[r.Correct=0]="Correct",r[r.Wrong=1]="Wrong"})(ln=he.DataType||(he.DataType={}));function mv(r){let e=ml(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}he.getSchemaTypes=mv;function ml(r){let e=Array.isArray(r)?r:r?[r]:[];if(e.every(dv.isJSONType))return e;throw new Error("type must be JSONType or JSONType[]: "+e.join(","))}he.getJSONTypes=ml;function gv(r,e){let{gen:t,data:n,opts:s}=r,i=vv(e,s.coerceTypes),a=e.length>0&&!(i.length===0&&e.length===1&&(0,hv.schemaHasRulesForType)(r,e[0]));if(a){let c=Pi(e,n,s.strictNumbers,ln.Wrong);t.if(c,()=>{i.length?_v(r,e,i):Ri(r)})}return a}he.coerceAndCheckDataType=gv;var gl=new Set(["string","number","integer","boolean","null"]);function vv(r,e){return e?r.filter(t=>gl.has(t)||e==="array"&&t==="array"):[]}function _v(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(Pi(e,s,i.strictNumbers),()=>n.assign(c,s))),n.if((0,q._)`${c} !== undefined`);for(let o of t)(gl.has(o)||o==="array"&&i.coerceTypes==="array")&&u(o);n.else(),Ri(r),n.endIf(),n.if((0,q._)`${c} !== undefined`,()=>{n.assign(s,c),yv(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
15
+ `)}function fo(r,e,t){return r.match(/[\n]\s+/)||e<40?r:go(r,e,t)}function ho(r,e){r._hasHelpOption&&e.find(n=>n===r._helpLongFlag||n===r._helpShortFlag)&&(r.outputHelp(),r._exit(0,"commander.helpDisplayed","(outputHelp)"))}function po(r){let e=r.name+(r.variadic===!0?"...":"");return r.required?"<"+e+">":"["+e+"]"}function vo(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 mo(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 zr=y((kE,$o)=>{var yh="2.0.0",$h=Number.MAX_SAFE_INTEGER||9007199254740991,Eh=16;$o.exports={SEMVER_SPEC_VERSION:yh,MAX_LENGTH:256,MAX_SAFE_INTEGER:$h,MAX_SAFE_COMPONENT_LENGTH:Eh}});var Kr=y((xE,Eo)=>{var wh=typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...r)=>console.error("SEMVER",...r):()=>{};Eo.exports=wh});var Vt=y((St,wo)=>{var{MAX_SAFE_COMPONENT_LENGTH:Ms}=zr(),bh=Kr();St=wo.exports={};var Sh=St.re=[],O=St.src=[],P=St.t={},Oh=0,j=(r,e,t)=>{let n=Oh++;bh(n,e),P[r]=n,O[n]=e,Sh[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,${Ms}})(?:\\.(\\d{1,${Ms}}))?(?:\\.(\\d{1,${Ms}}))?(?:$|[^\\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 Xr=y((LE,bo)=>{var Ph=["includePrerelease","loose","rtl"],Rh=r=>r?typeof r!="object"?{loose:!0}:Ph.filter(e=>r[e]).reduce((e,t)=>(e[t]=!0,e),{}):{};bo.exports=Rh});var xn=y((ME,Po)=>{var So=/^[0-9]+$/,Oo=(r,e)=>{let t=So.test(r),n=So.test(e);return t&&n&&(r=+r,e=+e),r===e?0:t&&!n?-1:n&&!t?1:r<e?-1:1},Ch=(r,e)=>Oo(e,r);Po.exports={compareIdentifiers:Oo,rcompareIdentifiers:Ch}});var ve=y((FE,Io)=>{var Ln=Kr(),{MAX_LENGTH:Ro,MAX_SAFE_INTEGER:Mn}=zr(),{re:Co,t:No}=Vt(),Nh=Xr(),{compareIdentifiers:Br}=xn(),He=class{constructor(e,t){if(t=Nh(t),e instanceof He){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>Ro)throw new TypeError(`version is longer than ${Ro} characters`);Ln("SemVer",e,t),this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease;let n=e.trim().match(t.loose?Co[No.LOOSE]:Co[No.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>Mn||this.major<0)throw new TypeError("Invalid major version");if(this.minor>Mn||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>Mn||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<Mn)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(Ln("SemVer.compare",this.version,this.options,e),!(e instanceof He)){if(typeof e=="string"&&e===this.version)return 0;e=new He(e,this.options)}return e.version===this.version?0:this.compareMain(e)||this.comparePre(e)}compareMain(e){return e instanceof He||(e=new He(e,this.options)),Br(this.major,e.major)||Br(this.minor,e.minor)||Br(this.patch,e.patch)}comparePre(e){if(e instanceof He||(e=new He(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(Ln("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 Br(n,s)}while(++t)}compareBuild(e){e instanceof He||(e=new He(e,this.options));let t=0;do{let n=this.build[t],s=e.build[t];if(Ln("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 Br(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&&(this.prerelease[0]===t?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}};Io.exports=He});var Ht=y((VE,Do)=>{var{MAX_LENGTH:Ih}=zr(),{re:To,t:Ao}=Vt(),qo=ve(),Th=Xr(),Ah=(r,e)=>{if(e=Th(e),r instanceof qo)return r;if(typeof r!="string"||r.length>Ih||!(e.loose?To[Ao.LOOSE]:To[Ao.FULL]).test(r))return null;try{return new qo(r,e)}catch{return null}};Do.exports=Ah});var ko=y((HE,jo)=>{var qh=Ht(),Dh=(r,e)=>{let t=qh(r,e);return t?t.version:null};jo.exports=Dh});var Lo=y((UE,xo)=>{var jh=Ht(),kh=(r,e)=>{let t=jh(r.trim().replace(/^[=v]+/,""),e);return t?t.version:null};xo.exports=kh});var Fo=y((GE,Mo)=>{var xh=ve(),Lh=(r,e,t,n)=>{typeof t=="string"&&(n=t,t=void 0);try{return new xh(r,t).inc(e,n).version}catch{return null}};Mo.exports=Lh});var Ue=y((zE,Ho)=>{var Vo=ve(),Mh=(r,e,t)=>new Vo(r,t).compare(new Vo(e,t));Ho.exports=Mh});var Fn=y((KE,Uo)=>{var Fh=Ue(),Vh=(r,e,t)=>Fh(r,e,t)===0;Uo.exports=Vh});var Ko=y((XE,zo)=>{var Go=Ht(),Hh=Fn(),Uh=(r,e)=>{if(Hh(r,e))return null;{let t=Go(r),n=Go(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}};zo.exports=Uh});var Bo=y((BE,Xo)=>{var Gh=ve(),zh=(r,e)=>new Gh(r,e).major;Xo.exports=zh});var Jo=y((WE,Wo)=>{var Kh=ve(),Xh=(r,e)=>new Kh(r,e).minor;Wo.exports=Xh});var Zo=y((JE,Yo)=>{var Bh=ve(),Wh=(r,e)=>new Bh(r,e).patch;Yo.exports=Wh});var ec=y((YE,Qo)=>{var Jh=Ht(),Yh=(r,e)=>{let t=Jh(r,e);return t&&t.prerelease.length?t.prerelease:null};Qo.exports=Yh});var rc=y((ZE,tc)=>{var Zh=Ue(),Qh=(r,e,t)=>Zh(e,r,t);tc.exports=Qh});var sc=y((QE,nc)=>{var ep=Ue(),tp=(r,e)=>ep(r,e,!0);nc.exports=tp});var Vn=y((ew,ac)=>{var ic=ve(),rp=(r,e,t)=>{let n=new ic(r,t),s=new ic(e,t);return n.compare(s)||n.compareBuild(s)};ac.exports=rp});var cc=y((tw,oc)=>{var np=Vn(),sp=(r,e)=>r.sort((t,n)=>np(t,n,e));oc.exports=sp});var lc=y((rw,uc)=>{var ip=Vn(),ap=(r,e)=>r.sort((t,n)=>ip(n,t,e));uc.exports=ap});var Wr=y((nw,fc)=>{var op=Ue(),cp=(r,e,t)=>op(r,e,t)>0;fc.exports=cp});var Hn=y((sw,dc)=>{var up=Ue(),lp=(r,e,t)=>up(r,e,t)<0;dc.exports=lp});var Fs=y((iw,hc)=>{var fp=Ue(),dp=(r,e,t)=>fp(r,e,t)!==0;hc.exports=dp});var Un=y((aw,pc)=>{var hp=Ue(),pp=(r,e,t)=>hp(r,e,t)>=0;pc.exports=pp});var Gn=y((ow,mc)=>{var mp=Ue(),gp=(r,e,t)=>mp(r,e,t)<=0;mc.exports=gp});var Vs=y((cw,gc)=>{var vp=Fn(),_p=Fs(),yp=Wr(),$p=Un(),Ep=Hn(),wp=Gn(),bp=(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 vp(r,t,n);case"!=":return _p(r,t,n);case">":return yp(r,t,n);case">=":return $p(r,t,n);case"<":return Ep(r,t,n);case"<=":return wp(r,t,n);default:throw new TypeError(`Invalid operator: ${e}`)}};gc.exports=bp});var _c=y((uw,vc)=>{var Sp=ve(),Op=Ht(),{re:zn,t:Kn}=Vt(),Pp=(r,e)=>{if(r instanceof Sp)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[Kn.COERCE]);else{let n;for(;(n=zn[Kn.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[Kn.COERCERTL].lastIndex=n.index+n[1].length+n[2].length;zn[Kn.COERCERTL].lastIndex=-1}return t===null?null:Op(`${t[2]}.${t[3]||"0"}.${t[4]||"0"}`,e)};vc.exports=Pp});var $c=y((lw,yc)=>{"use strict";yc.exports=function(r){r.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}});var wc=y((fw,Ec)=>{"use strict";Ec.exports=X;X.Node=Ut;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++)Cp(this,arguments[r]);return this.length};X.prototype.unshift=function(){for(var r=0,e=arguments.length;r<e;r++)Np(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=Rp(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 Rp(r,e,t){var n=e===r.head?new Ut(t,null,e,r):new Ut(t,e,e.next,r);return n.next===null&&(r.tail=n),n.prev===null&&(r.head=n),r.length++,n}function Cp(r,e){r.tail=new Ut(e,r.tail,null,r),r.head||(r.head=r.tail),r.length++}function Np(r,e){r.head=new Ut(e,null,r.head,r),r.tail||(r.tail=r.head),r.length++}function Ut(r,e,t,n){if(!(this instanceof Ut))return new Ut(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{$c()(X)}catch{}});var Nc=y((dw,Cc)=>{"use strict";var Ip=wc(),Gt=Symbol("max"),_t=Symbol("length"),lr=Symbol("lengthCalculator"),Yr=Symbol("allowStale"),zt=Symbol("maxAge"),vt=Symbol("dispose"),bc=Symbol("noDisposeOnSet"),fe=Symbol("lruList"),Be=Symbol("cache"),Oc=Symbol("updateAgeOnGet"),Hs=()=>1,Pc=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[Gt]=e.max||1/0,n=e.length||Hs;if(this[lr]=typeof n!="function"?Hs:n,this[Yr]=e.stale||!1,e.maxAge&&typeof e.maxAge!="number")throw new TypeError("maxAge must be a number");this[zt]=e.maxAge||0,this[vt]=e.dispose,this[bc]=e.noDisposeOnSet||!1,this[Oc]=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,Jr(this)}get max(){return this[Gt]}set allowStale(e){this[Yr]=!!e}get allowStale(){return this[Yr]}set maxAge(e){if(typeof e!="number")throw new TypeError("maxAge must be a non-negative number");this[zt]=e,Jr(this)}get maxAge(){return this[zt]}set lengthCalculator(e){typeof e!="function"&&(e=Hs),e!==this[lr]&&(this[lr]=e,this[_t]=0,this[fe].forEach(t=>{t.length=this[lr](t.value,t.key),this[_t]+=t.length})),Jr(this)}get lengthCalculator(){return this[lr]}get length(){return this[_t]}get itemCount(){return this[fe].length}rforEach(e,t){t=t||this;for(let n=this[fe].tail;n!==null;){let s=n.prev;Sc(this,e,n,t),n=s}}forEach(e,t){t=t||this;for(let n=this[fe].head;n!==null;){let s=n.next;Sc(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[vt]&&this[fe]&&this[fe].length&&this[fe].forEach(e=>this[vt](e.key,e.value)),this[Be]=new Map,this[fe]=new Ip,this[_t]=0}dump(){return this[fe].map(e=>Xn(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[zt],n&&typeof n!="number")throw new TypeError("maxAge must be a number");let s=n?Date.now():0,i=this[lr](t,e);if(this[Be].has(e)){if(i>this[Gt])return fr(this,this[Be].get(e)),!1;let u=this[Be].get(e).value;return this[vt]&&(this[bc]||this[vt](e,u.value)),u.now=s,u.maxAge=n,u.value=t,this[_t]+=i-u.length,u.length=i,this.get(e),Jr(this),!0}let a=new Rc(e,t,i,s,n);return a.length>this[Gt]?(this[vt]&&this[vt](e,t),!1):(this[_t]+=a.length,this[fe].unshift(a),this[Be].set(e,this[fe].head),Jr(this),!0)}has(e){if(!this[Be].has(e))return!1;let t=this[Be].get(e).value;return!Xn(this,t)}get(e){return Us(this,e,!0)}peek(e){return Us(this,e,!1)}pop(){let e=this[fe].tail;return e?(fr(this,e),e.value):null}del(e){fr(this,this[Be].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[Be].forEach((e,t)=>Us(this,t,!1))}},Us=(r,e,t)=>{let n=r[Be].get(e);if(n){let s=n.value;if(Xn(r,s)){if(fr(r,n),!r[Yr])return}else t&&(r[Oc]&&(n.value.now=Date.now()),r[fe].unshiftNode(n));return s.value}},Xn=(r,e)=>{if(!e||!e.maxAge&&!r[zt])return!1;let t=Date.now()-e.now;return e.maxAge?t>e.maxAge:r[zt]&&t>r[zt]},Jr=r=>{if(r[_t]>r[Gt])for(let e=r[fe].tail;r[_t]>r[Gt]&&e!==null;){let t=e.prev;fr(r,e),e=t}},fr=(r,e)=>{if(e){let t=e.value;r[vt]&&r[vt](t.key,t.value),r[_t]-=t.length,r[Be].delete(t.key),r[fe].removeNode(e)}},Rc=class{constructor(e,t,n,s,i){this.key=e,this.value=t,this.length=n,this.now=s,this.maxAge=i||0}},Sc=(r,e,t,n)=>{let s=t.value;Xn(r,s)&&(fr(r,t),r[Yr]||(s=void 0)),s&&e.call(n,s.value,s.key,r)};Cc.exports=Pc});var Ge=y((hw,qc)=>{var dr=class{constructor(e,t){if(t=Ap(t),e instanceof dr)return e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease?e:new dr(e.raw,t);if(e instanceof Gs)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(/\s*\|\|\s*/).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=>!Tc(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&&xp(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=Ic.get(n);if(s)return s;let i=this.options.loose,a=i?_e[de.HYPHENRANGELOOSE]:_e[de.HYPHENRANGE];e=e.replace(a,Xp(this.options.includePrerelease)),ae("hyphen replace",e),e=e.replace(_e[de.COMPARATORTRIM],Dp),ae("comparator trim",e,_e[de.COMPARATORTRIM]),e=e.replace(_e[de.TILDETRIM],jp),e=e.replace(_e[de.CARETTRIM],kp),e=e.split(/\s+/).join(" ");let c=i?_e[de.COMPARATORLOOSE]:_e[de.COMPARATOR],u=e.split(" ").map(g=>Lp(g,this.options)).join(" ").split(/\s+/).map(g=>Kp(g,this.options)).filter(this.options.loose?g=>!!g.match(c):()=>!0).map(g=>new Gs(g,this.options)),o=u.length,l=new Map;for(let g of u){if(Tc(g))return[g];l.set(g.value,g)}l.size>1&&l.has("")&&l.delete("");let h=[...l.values()];return Ic.set(n,h),h}intersects(e,t){if(!(e instanceof dr))throw new TypeError("a Range is required");return this.set.some(n=>Ac(n,t)&&e.set.some(s=>Ac(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 qp(e,this.options)}catch{return!1}for(let t=0;t<this.set.length;t++)if(Bp(this.set[t],e,this.options))return!0;return!1}};qc.exports=dr;var Tp=Nc(),Ic=new Tp({max:1e3}),Ap=Xr(),Gs=Zr(),ae=Kr(),qp=ve(),{re:_e,t:de,comparatorTrimReplace:Dp,tildeTrimReplace:jp,caretTrimReplace:kp}=Vt(),Tc=r=>r.value==="<0.0.0-0",xp=r=>r.value==="",Ac=(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},Lp=(r,e)=>(ae("comp",r,e),r=Vp(r,e),ae("caret",r),r=Mp(r,e),ae("tildes",r),r=Up(r,e),ae("xrange",r),r=zp(r,e),ae("stars",r),r),be=r=>!r||r.toLowerCase()==="x"||r==="*",Mp=(r,e)=>r.trim().split(/\s+/).map(t=>Fp(t,e)).join(" "),Fp=(r,e)=>{let t=e.loose?_e[de.TILDELOOSE]:_e[de.TILDE];return r.replace(t,(n,s,i,a,c)=>{ae("tilde",r,n,s,i,a,c);let u;return be(s)?u="":be(i)?u=`>=${s}.0.0 <${+s+1}.0.0-0`:be(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})},Vp=(r,e)=>r.trim().split(/\s+/).map(t=>Hp(t,e)).join(" "),Hp=(r,e)=>{ae("caret",r,e);let t=e.loose?_e[de.CARETLOOSE]:_e[de.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 be(i)?o="":be(a)?o=`>=${i}.0.0${n} <${+i+1}.0.0-0`:be(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})},Up=(r,e)=>(ae("replaceXRanges",r,e),r.split(/\s+/).map(t=>Gp(t,e)).join(" ")),Gp=(r,e)=>{r=r.trim();let t=e.loose?_e[de.XRANGELOOSE]:_e[de.XRANGE];return r.replace(t,(n,s,i,a,c,u)=>{ae("xRange",r,n,s,i,a,c,u);let o=be(i),l=o||be(a),h=l||be(c),g=h;return s==="="&&g&&(s=""),u=e.includePrerelease?"-0":"",o?s===">"||s==="<"?n="<0.0.0-0":n="*":s&&g?(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`:h&&(n=`>=${i}.${a}.0${u} <${i}.${+a+1}.0-0`),ae("xRange return",n),n})},zp=(r,e)=>(ae("replaceStars",r,e),r.trim().replace(_e[de.STAR],"")),Kp=(r,e)=>(ae("replaceGTE0",r,e),r.trim().replace(_e[e.includePrerelease?de.GTE0PRE:de.GTE0],"")),Xp=r=>(e,t,n,s,i,a,c,u,o,l,h,g,v)=>(be(n)?t="":be(s)?t=`>=${n}.0.0${r?"-0":""}`:be(i)?t=`>=${n}.${s}.0${r?"-0":""}`:a?t=`>=${t}`:t=`>=${t}${r?"-0":""}`,be(o)?u="":be(l)?u=`<${+o+1}.0.0-0`:be(h)?u=`<${o}.${+l+1}.0-0`:g?u=`<=${o}.${l}.${h}-${g}`:r?u=`<${o}.${l}.${+h+1}-0`:u=`<=${u}`,`${t} ${u}`.trim()),Bp=(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!==Gs.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 Zr=y((pw,Lc)=>{var Qr=Symbol("SemVer ANY"),en=class{static get ANY(){return Qr}constructor(e,t){if(t=Wp(t),e instanceof en){if(e.loose===!!t.loose)return e;e=e.value}Ks("comparator",e,t),this.options=t,this.loose=!!t.loose,this.parse(e),this.semver===Qr?this.value="":this.value=this.operator+this.semver.version,Ks("comp",this)}parse(e){let t=this.options.loose?Dc[jc.COMPARATORLOOSE]:Dc[jc.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 kc(n[2],this.options.loose):this.semver=Qr}toString(){return this.value}test(e){if(Ks("Comparator.test",e,this.options.loose),this.semver===Qr||e===Qr)return!0;if(typeof e=="string")try{e=new kc(e,this.options)}catch{return!1}return zs(e,this.operator,this.semver,this.options)}intersects(e,t){if(!(e instanceof en))throw new TypeError("a Comparator is required");if((!t||typeof t!="object")&&(t={loose:!!t,includePrerelease:!1}),this.operator==="")return this.value===""?!0:new xc(e.value,t).test(this.value);if(e.operator==="")return e.value===""?!0:new xc(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=zs(this.semver,"<",e.semver,t)&&(this.operator===">="||this.operator===">")&&(e.operator==="<="||e.operator==="<"),u=zs(this.semver,">",e.semver,t)&&(this.operator==="<="||this.operator==="<")&&(e.operator===">="||e.operator===">");return n||s||i&&a||c||u}};Lc.exports=en;var Wp=Xr(),{re:Dc,t:jc}=Vt(),zs=Vs(),Ks=Kr(),kc=ve(),xc=Ge()});var tn=y((mw,Mc)=>{var Jp=Ge(),Yp=(r,e,t)=>{try{e=new Jp(e,t)}catch{return!1}return e.test(r)};Mc.exports=Yp});var Vc=y((gw,Fc)=>{var Zp=Ge(),Qp=(r,e)=>new Zp(r,e).set.map(t=>t.map(n=>n.value).join(" ").trim().split(" "));Fc.exports=Qp});var Uc=y((vw,Hc)=>{var em=ve(),tm=Ge(),rm=(r,e,t)=>{let n=null,s=null,i=null;try{i=new tm(e,t)}catch{return null}return r.forEach(a=>{i.test(a)&&(!n||s.compare(a)===-1)&&(n=a,s=new em(n,t))}),n};Hc.exports=rm});var zc=y((_w,Gc)=>{var nm=ve(),sm=Ge(),im=(r,e,t)=>{let n=null,s=null,i=null;try{i=new sm(e,t)}catch{return null}return r.forEach(a=>{i.test(a)&&(!n||s.compare(a)===1)&&(n=a,s=new nm(n,t))}),n};Gc.exports=im});var Bc=y((yw,Xc)=>{var Xs=ve(),am=Ge(),Kc=Wr(),om=(r,e)=>{r=new am(r,e);let t=new Xs("0.0.0");if(r.test(t)||(t=new Xs("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 Xs(a.semver.version);switch(a.operator){case">":c.prerelease.length===0?c.patch++:c.prerelease.push(0),c.raw=c.format();case"":case">=":(!i||Kc(c,i))&&(i=c);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${a.operator}`)}}),i&&(!t||Kc(t,i))&&(t=i)}return t&&r.test(t)?t:null};Xc.exports=om});var Jc=y(($w,Wc)=>{var cm=Ge(),um=(r,e)=>{try{return new cm(r,e).range||"*"}catch{return null}};Wc.exports=um});var Bn=y((Ew,eu)=>{var lm=ve(),Qc=Zr(),{ANY:fm}=Qc,dm=Ge(),hm=tn(),Yc=Wr(),Zc=Hn(),pm=Gn(),mm=Un(),gm=(r,e,t,n)=>{r=new lm(r,n),e=new dm(e,n);let s,i,a,c,u;switch(t){case">":s=Yc,i=pm,a=Zc,c=">",u=">=";break;case"<":s=Zc,i=mm,a=Yc,c="<",u="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(hm(r,e,n))return!1;for(let o=0;o<e.set.length;++o){let l=e.set[o],h=null,g=null;if(l.forEach(v=>{v.semver===fm&&(v=new Qc(">=0.0.0")),h=h||v,g=g||v,s(v.semver,h.semver,n)?h=v:a(v.semver,g.semver,n)&&(g=v)}),h.operator===c||h.operator===u||(!g.operator||g.operator===c)&&i(r,g.semver))return!1;if(g.operator===u&&a(r,g.semver))return!1}return!0};eu.exports=gm});var ru=y((ww,tu)=>{var vm=Bn(),_m=(r,e,t)=>vm(r,e,">",t);tu.exports=_m});var su=y((bw,nu)=>{var ym=Bn(),$m=(r,e,t)=>ym(r,e,"<",t);nu.exports=$m});var ou=y((Sw,au)=>{var iu=Ge(),Em=(r,e,t)=>(r=new iu(r,t),e=new iu(e,t),r.intersects(e));au.exports=Em});var uu=y((Ow,cu)=>{var wm=tn(),bm=Ue();cu.exports=(r,e,t)=>{let n=[],s=null,i=null,a=r.sort((l,h)=>bm(l,h,t));for(let l of a)wm(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,h]of n)l===h?c.push(l):!h&&l===a[0]?c.push("*"):h?l===a[0]?c.push(`<=${h}`):c.push(`${l} - ${h}`):c.push(`>=${l}`);let u=c.join(" || "),o=typeof e.raw=="string"?e.raw:String(e);return u.length<o.length?u:e}});var pu=y((Pw,hu)=>{var lu=Ge(),Wn=Zr(),{ANY:Bs}=Wn,rn=tn(),Ws=Ue(),Sm=(r,e,t={})=>{if(r===e)return!0;r=new lu(r,t),e=new lu(e,t);let n=!1;e:for(let s of r.set){for(let i of e.set){let a=Om(s,i,t);if(n=n||a!==null,a)continue e}if(n)return!1}return!0},Om=(r,e,t)=>{if(r===e)return!0;if(r.length===1&&r[0].semver===Bs){if(e.length===1&&e[0].semver===Bs)return!0;t.includePrerelease?r=[new Wn(">=0.0.0-0")]:r=[new Wn(">=0.0.0")]}if(e.length===1&&e[0].semver===Bs){if(t.includePrerelease)return!0;e=[new Wn(">=0.0.0")]}let n=new Set,s,i;for(let v of r)v.operator===">"||v.operator===">="?s=fu(s,v,t):v.operator==="<"||v.operator==="<="?i=du(i,v,t):n.add(v.semver);if(n.size>1)return null;let a;if(s&&i){if(a=Ws(s.semver,i.semver,t),a>0)return null;if(a===0&&(s.operator!==">="||i.operator!=="<="))return null}for(let v of n){if(s&&!rn(v,String(s),t)||i&&!rn(v,String(i),t))return null;for(let $ of e)if(!rn(v,String($),t))return!1;return!0}let c,u,o,l,h=i&&!t.includePrerelease&&i.semver.prerelease.length?i.semver:!1,g=s&&!t.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(l=l||v.operator===">"||v.operator===">=",o=o||v.operator==="<"||v.operator==="<=",s){if(g&&v.semver.prerelease&&v.semver.prerelease.length&&v.semver.major===g.major&&v.semver.minor===g.minor&&v.semver.patch===g.patch&&(g=!1),v.operator===">"||v.operator===">="){if(c=fu(s,v,t),c===v&&c!==s)return!1}else if(s.operator===">="&&!rn(s.semver,String(v),t))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(u=du(i,v,t),u===v&&u!==i)return!1}else if(i.operator==="<="&&!rn(i.semver,String(v),t))return!1}if(!v.operator&&(i||s)&&a!==0)return!1}return!(s&&o&&!i&&a!==0||i&&l&&!s&&a!==0||g||h)},fu=(r,e,t)=>{if(!r)return e;let n=Ws(r.semver,e.semver,t);return n>0?r:n<0||e.operator===">"&&r.operator===">="?e:r},du=(r,e,t)=>{if(!r)return e;let n=Ws(r.semver,e.semver,t);return n<0?r:n>0||e.operator==="<"&&r.operator==="<="?e:r};hu.exports=Sm});var gu=y((Rw,mu)=>{var Js=Vt();mu.exports={re:Js.re,src:Js.src,tokens:Js.t,SEMVER_SPEC_VERSION:zr().SEMVER_SPEC_VERSION,SemVer:ve(),compareIdentifiers:xn().compareIdentifiers,rcompareIdentifiers:xn().rcompareIdentifiers,parse:Ht(),valid:ko(),clean:Lo(),inc:Fo(),diff:Ko(),major:Bo(),minor:Jo(),patch:Zo(),prerelease:ec(),compare:Ue(),rcompare:rc(),compareLoose:sc(),compareBuild:Vn(),sort:cc(),rsort:lc(),gt:Wr(),lt:Hn(),eq:Fn(),neq:Fs(),gte:Un(),lte:Gn(),cmp:Vs(),coerce:_c(),Comparator:Zr(),Range:Ge(),satisfies:tn(),toComparators:Vc(),maxSatisfying:Uc(),minSatisfying:zc(),minVersion:Bc(),validRange:Jc(),outside:Bn(),gtr:ru(),ltr:su(),intersects:ou(),simplifyRange:uu(),subset:pu()}});var yt=y(De=>{"use strict";var Pm=De&&De.__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]}),Rm=De&&De.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),Cm=De&&De.__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)&&Pm(e,r,t);return Rm(e,r),e},vu=De&&De.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(De,"__esModule",{value:!0});De.getCoreVersion=void 0;var _u=vu(require("path")),yu=vu(require("fs")),Ys=Cm(require("@serverless-devs/core")),Nm=gu(),$u=_u.default.join(Ys.getRootHome(),"cache","core"),Zs=_u.default.join($u,"package.json");function Im(){if(yu.default.existsSync(Zs)){var r=require("@serverless-devs/core/package.json").version,e=Eu();return Nm.gt(e,r)?require($u):Ys}return Ys}function Eu(){return yu.default.existsSync(Zs)?require(Zs).version:void 0}De.getCoreVersion=Eu;De.default=Im()});var ti=y(Re=>{"use strict";var Tm=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(h){a(h)}}function u(l){try{o(n.throw(l))}catch(h){a(h)}}function o(l){l.done?i(l.value):s(l.value).then(c,u)}o((n=n.apply(r,e||[])).next())})},Am=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}}},wu=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 bu=wu(require("path")),ei=wu(yt()),it=ei.default.fse,Jn=ei.default.jsyaml,Qs=ei.default.getRootHome;function qm(r){var e=Ou();it.writeFileSync(e,Jn.dump(r))}function Su(){var r=Ou();if(!it.existsSync(r))return{};try{var e=Jn.load(it.readFileSync(r,"utf8"))||{};return e}catch(t){throw t}}function Ou(){var r=bu.default.join(Qs(),"set-config.yml");return it.existsSync(r)||it.createFileSync(r),r}function Dm(r,e){var t=Su();t[r]=e,qm(t)}Re.setConfig=Dm;function jm(r,e){var t=Su();return t[r]||e}Re.getConfig=jm;function km(r){return Tm(this,void 0,void 0,function(){var e,t,n,s,i,a,c;return Am(this,function(u){switch(u.label){case 0:if(e=r.filePath||"set-config.yml",t=bu.default.join(Qs(),e),n=it.existsSync(t),s={},n)return[3,5];i=Qs(),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=Jn.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,Jn.dump(s))]);case 7:return u.sent(),[2,s]}})})}Re.handlerProfileFile=km});var Pu=y((Iw,xm)=>{xm.exports={name:"@serverless-devs/s",version:"2.0.101",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:"MIT",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",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","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"}}});var Yn=y(C=>{"use strict";var Lm=C&&C.__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]}),Mm=C&&C.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),Fm=C&&C.__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)&&Lm(e,r,t);return Mm(e,r),e},hr=C&&C.__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(h){a(h)}}function u(l){try{o(n.throw(l))}catch(h){a(h)}}function o(l){l.done?i(l.value):s(l.value).then(c,u)}o((n=n.apply(r,e||[])).next())})},pr=C&&C.__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}}},ni=C&&C.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(C,"__esModule",{value:!0});C.specifyServiceHelp=C.getTempCommandStr=C.emoji=C.mark=C.replaceTemplate=C.replaceFun=C.getLang=C.printn=C.getFolderSize=C.getVersion=C.getPid=C.aiRequest=C.getCredentialWithAll=C.getCredentialWithExisted=C.getProcessArgv=C.bgRed=C.yellow=C.red=void 0;var Vm=ni(require("path")),nn=ni(require("fs")),Hm=ni(require("os")),ye=Fm(yt()),Um=ti(),Ru=Pu(),mr=ye.default.colors,Gm=ye.default.got,zm=ye.default.getMAC,Km=ye.default.isDocker,Xm=ye.default.isCiCdEnv,Ot=ye.default.lodash,Cu=ye.default.publishHelp,Bm=Ot.get,Wm=Ot.trim,Jm=Ot.assign,Ym=Ot.filter,Nu=Ot.includes,Iu=Ot.omit,Zm=Ot.isPlainObject,Qm=Ot.isEmpty,eg=mr.underline,tg=mr.bold;C.red=mr.hex("#fd5750");C.yellow=mr.hex("#F3F99D");C.bgRed=mr.hex("#000").bgHex("#fd5750");var rg=function(){var r=process.env.serverless_devs_temp_argv;try{var e=JSON.parse(r),t=ye.default.getGlobalArgs(e);return process.argv=process.argv.slice(0,2).concat(t._argsObj),Jm({},t,{noHelpArgv:process.argv.slice(0,2).concat(Ym(t._argsObj,function(n){return!Nu(["-h","--help"],n)}))})}catch{return{}}};C.getProcessArgv=rg;var ng=function(r){return hr(void 0,void 0,void 0,function(){var e,t;return pr(this,function(n){switch(n.label){case 0:return[4,ye.default.getCredentialAliasList()];case 1:return e=n.sent(),Nu(e,r)?[4,ye.default.getCredential(r)]:[3,3];case 2:return t=n.sent(),[2,Iu(t,"Alias")];case 3:return[2]}})})};C.getCredentialWithExisted=ng;var sg=function(){return hr(void 0,void 0,void 0,function(){var r,e,t,n,s,i;return pr(this,function(a){switch(a.label){case 0:return[4,ye.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,ye.default.getCredential(s)]):[3,5];case 3:i=a.sent(),e[i.Alias]=Iu(i,"Alias"),a.label=4;case 4:return t++,[3,2];case 5:return[2,e];case 6:return[2]}})})};C.getCredentialWithAll=sg;var ig=function(r,e){return e===void 0&&(e="unknow"),hr(void 0,void 0,void 0,function(){var t,n,s,i;return pr(this,function(a){switch(a.label){case 0:return a.trys.push([0,2,,3]),t=(0,Um.getConfig)("analysis"),t!=="enable"?[2]:Km()||Xm()?[2]:[4,Gm("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=Bm(n.body,"shorturl"),s&&console.log(`AI Tips:
16
+ You can try to solve the problem through: `.concat(mr.underline(s),`
17
+ `)),[3,3];case 2:return i=a.sent(),[3,3];case 3:return[2]}})})};C.aiRequest=ig;var ag=function(){try{return zm().replace(/:/g,"")}catch{return"unknown"}};C.getPid=ag;function og(){var r=(0,ye.getCoreVersion)(),e=["".concat(Ru.name,": ").concat(Ru.version),r?"core: ".concat(r):void 0,"s-home: ".concat(ye.default.getRootHome()),"".concat(process.platform,"-").concat(process.arch),"node-".concat(process.version)];return e.filter(function(t){return t}).join(", ")}C.getVersion=og;function cg(r){return hr(this,void 0,void 0,function(){function e(s){return hr(this,void 0,void 0,function(){var i,a;return pr(this,function(c){switch(c.label){case 0:return i=nn.default.lstatSync(s),typeof i!="object"?[2]:(t.set(i.ino,i.size),i.isDirectory()?(a=nn.default.readdirSync(s),typeof a!="object"?[2]:[4,Promise.all(a.map(function(u){return e(Vm.default.join(s,u))}))]):[3,2]);case 1:c.sent(),c.label=2;case 2:return[2]}})})}var t,n;return pr(this,function(s){switch(s.label){case 0:return t=new Map,[4,e(r)];case 1:return s.sent(),n=Array.from(t.values()).reduce(function(i,a){return i+a},0),[2,n]}})})}C.getFolderSize=cg;function ug(r,e){e===void 0&&(e=" ");for(var t="",n=0;n<r;n++)t=t+e;return t}C.printn=ug;function lg(){return"en"}C.getLang=lg;function Tu(r,e){var t=/\{\{(.*?)\}\}/g,n=r.match(t);if(n)for(var s=0;s<n.length;s++){var i=n[s].replace(/{{|}}/g,""),a=Wm(i.split("|")[0]);e[a]&&(r=r.replace(n[s],e[a]))}return r}C.replaceFun=Tu;function fg(r,e){r.forEach(function(t){if(nn.default.existsSync(t)){var n=nn.default.readFileSync(t,"utf-8"),s=Tu(n,e);nn.default.writeFileSync(t,s,"utf-8")}})}C.replaceTemplate=fg;function dg(r){if(!r)return r;var e=r.slice(-4);return"***********".concat(e)}C.mark=dg;function ri(r,e){return Hm.default.platform()==="win32"?e||"\u25C6":"".concat(r," ")}C.emoji=ri;function Au(r,e){var t=r.length,n=new Array(e-t).fill(" ");return"".concat(r).concat(n.join("")," : ")}C.getTempCommandStr=Au;function hg(r){return hr(this,void 0,void 0,function(){var e,t,n,s,i,c,a,c;return pr(this,function(u){switch(u.label){case 0:return[4,ye.default.getYamlContent(r)];case 1:if(e=u.sent(),console.log(`
18
+ `.concat(ri("\u{1F680}")," ").concat(e.Name,"@").concat(e.Version,": ").concat(e.Description,`
19
+ `)),t=e.Commands,t){n=Cu.maxLen(t),s=[],i={};for(c in t)a=t[c],Zm(a)?s.push(Cu.helpInfo(a,eg(tg(c)),n,4)):i[c]=a;if(s.length>0&&console.log(s.join(`
20
+ `)),!Qm(i)){for(c in i)console.log(" ".concat(Au(c,n)," ").concat(i[c]));console.log("")}console.log(e.HomePage?" ".concat(ri("\u{1F9ED}")," ").concat(ye.default.makeUnderLine("More information: "+e.HomePage)," ")+`
21
+ `:"")}return[2]}})})}C.specifyServiceHelp=hg});var qu=y(si=>{"use strict";Object.defineProperty(si,"__esModule",{value:!0});si.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 Du=y(ii=>{"use strict";Object.defineProperty(ii,"__esModule",{value:!0});ii.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 oi=y(sn=>{"use strict";var ju=sn&&sn.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(sn,"__esModule",{value:!0});var pg=Yn(),mg=ju(qu()),gg=ju(Du()),ai={en:gg.default,zh:mg.default},vg=function(r){var e=(0,pg.getLang)(),t=ai[e]?ai[e][r]:ai.en[r];return t||r};sn.default=vg});var ui=y(an=>{"use strict";var _g=an&&an.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(an,"__esModule",{value:!0});var yg=_g(yt()),$g=yg.default.Logger,ci=new $g("S-CLI");ci.success=function(r){return ci.log(r,"green")};an.default=ci});var fi=y($e=>{"use strict";var Eg=$e&&$e.__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]}),ku=$e&&$e.__exportStar||function(r,e){for(var t in r)t!=="default"&&!Object.prototype.hasOwnProperty.call(e,t)&&Eg(e,r,t)},li=$e&&$e.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty($e,"__esModule",{value:!0});$e.registerCommandChecker=$e.i18n=$e.logger=void 0;var wg=li(ui());ku(Yn(),$e);ku(ti(),$e);var bg=ui();Object.defineProperty($e,"logger",{enumerable:!0,get:function(){return li(bg).default}});var Sg=oi();Object.defineProperty($e,"i18n",{enumerable:!0,get:function(){return li(Sg).default}});function Og(r){r.on("command:*",function(e){var t=r.commands.map(function(n){return n.name()});t.includes(e[0])||(wg.default.error(" error: unknown command ".concat(e[0])),r.help())})}$e.registerCommandChecker=Og});var cn=y(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 Zn=class{};U._CodeOrName=Zn;U.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var gr=class extends Zn{constructor(e){super();if(!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=gr;var We=class extends Zn{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 gr&&(t[n.str]=(t[n.str]||0)+1),t),{})}};U._Code=We;U.nil=new We("");function xu(r,...e){let t=[r[0]],n=0;for(;n<e.length;)hi(t,e[n]),t.push(r[++n]);return new We(t)}U._=xu;var di=new We("+");function Lu(r,...e){let t=[on(r[0])],n=0;for(;n<e.length;)t.push(di),hi(t,e[n]),t.push(di,on(r[++n]));return Pg(t),new We(t)}U.str=Lu;function hi(r,e){e instanceof We?r.push(...e._items):e instanceof gr?r.push(e):r.push(Ng(e))}U.addCodeArg=hi;function Pg(r){let e=1;for(;e<r.length-1;){if(r[e]===di){let t=Rg(r[e-1],r[e+1]);if(t!==void 0){r.splice(e-1,3,t);continue}r[e++]="+"}e++}}function Rg(r,e){if(e==='""')return r;if(r==='""')return e;if(typeof r=="string")return e instanceof gr||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 gr))return`"${r}${e.slice(1)}`}function Cg(r,e){return e.emptyStr()?r:r.emptyStr()?e:Lu`${r}${e}`}U.strConcat=Cg;function Ng(r){return typeof r=="number"||typeof r=="boolean"||r===null?r:on(Array.isArray(r)?r.join(","):r)}function Ig(r){return new We(on(r))}U.stringify=Ig;function on(r){return JSON.stringify(r).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}U.safeStringify=on;function Tg(r){return typeof r=="string"&&U.IDENTIFIER.test(r)?new We(`.${r}`):xu`[${r}]`}U.getProperty=Tg;function Ag(r){if(typeof r=="string"&&U.IDENTIFIER.test(r))return new We(`${r}`);throw new Error(`CodeGen: invalid export name: ${r}, use explicit $id name mapping`)}U.getEsmExportName=Ag;function qg(r){return new We(r.toString())}U.regexpCode=qg});var vi=y(Se=>{"use strict";Object.defineProperty(Se,"__esModule",{value:!0});Se.ValueScope=Se.ValueScopeName=Se.Scope=Se.varKinds=Se.UsedValueState=void 0;var Ce=cn(),Mu=class extends Error{constructor(e){super(`CodeGen: "code" for ${e} not defined`);this.value=e.value}},pi;(function(r){r[r.Started=0]="Started",r[r.Completed=1]="Completed"})(pi=Se.UsedValueState||(Se.UsedValueState={}));Se.varKinds={const:new Ce.Name("const"),let:new Ce.Name("let"),var:new Ce.Name("var")};var mi=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}}};Se.Scope=mi;var gi=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}]`}};Se.ValueScopeName=gi;var Dg=(0,Ce._)`\n`,Fu=class extends mi{constructor(e){super(e);this._values={},this._scope=e.scope,this.opts=Ve(ie({},e),{_n:e.lines?Dg:Ce.nil})}get(){return this._scope}name(e){return new gi(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,pi.Started);let l=t(o);if(l){let h=this.opts.es5?Se.varKinds.var:Se.varKinds.const;i=(0,Ce._)`${i}${h} ${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 Mu(o);u.set(o,pi.Completed)})}return i}};Se.ValueScope=Fu});var L=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 M=cn(),Je=vi(),Pt=cn();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 ss=vi();Object.defineProperty(k,"Scope",{enumerable:!0,get:function(){return ss.Scope}});Object.defineProperty(k,"ValueScope",{enumerable:!0,get:function(){return ss.ValueScope}});Object.defineProperty(k,"ValueScopeName",{enumerable:!0,get:function(){return ss.ValueScopeName}});Object.defineProperty(k,"varKinds",{enumerable:!0,get:function(){return ss.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 Rt=class{optimizeNodes(){return this}optimizeNames(e,t){return this}},Vu=class extends Rt{constructor(e,t,n){super();this.varKind=e,this.name=t,this.rhs=n}render({es5:e,_n:t}){let n=e?Je.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=_r(this.rhs,e,t)),this}get names(){return this.rhs instanceof M._CodeOrName?this.rhs.names:{}}},$i=class extends Rt{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=_r(this.rhs,e,t),this}get names(){let e=this.lhs instanceof M.Name?{}:ie({},this.lhs.names);return ns(e,this.rhs)}},Hu=class extends $i{constructor(e,t,n,s){super(e,n,s);this.op=t}render({_n:e}){return`${this.lhs} ${this.op}= ${this.rhs};`+e}},Uu=class extends Rt{constructor(e){super();this.label=e,this.names={}}render({_n:e}){return`${this.label}:`+e}},Gu=class extends Rt{constructor(e){super();this.label=e,this.names={}}render({_n:e}){return`break${this.label?` ${this.label}`:""};`+e}},zu=class extends Rt{constructor(e){super();this.error=e}render({_n:e}){return`throw ${this.error};`+e}get names(){return this.error.names}},Ku=class extends Rt{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=_r(this.code,e,t),this}get names(){return this.code instanceof M._CodeOrName?this.code.names:{}}},is=class extends Rt{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)||(jg(e,i.names),n.splice(s,1))}return n.length>0?this:void 0}get names(){return this.nodes.reduce((e,t)=>Kt(e,t.names),{})}},Ct=class extends is{render(e){return"{"+e._n+super.render(e)+"}"+e._n}},Xu=class extends is{},un=class extends Ct{};un.kind="else";var at=class extends Ct{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 un(n):n}if(t)return e===!1?t instanceof at?t:t.nodes:this.nodes.length?this:new at(Zu(e),t instanceof at?[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=_r(this.condition,e,t),this}get names(){let e=super.names;return ns(e,this.condition),this.else&&Kt(e,this.else.names),e}};at.kind="if";var vr=class extends Ct{};vr.kind="for";var Bu=class extends vr{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=_r(this.iteration,e,t),this}get names(){return Kt(super.names,this.iteration.names)}},Wu=class extends vr{constructor(e,t,n,s){super();this.varKind=e,this.name=t,this.from=n,this.to=s}render(e){let t=e.es5?Je.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=ns(super.names,this.from);return ns(e,this.to)}},_i=class extends vr{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=_r(this.iterable,e,t),this}get names(){return Kt(super.names,this.iterable.names)}},Qn=class extends Ct{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)}};Qn.kind="func";var es=class extends is{render(e){return"return "+super.render(e)}};es.kind="return";var Ju=class extends Ct{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&&Kt(e,this.catch.names),this.finally&&Kt(e,this.finally.names),e}},ts=class extends Ct{constructor(e){super();this.error=e}render(e){return`catch(${this.error})`+super.render(e)}};ts.kind="catch";var rs=class extends Ct{render(e){return"finally"+super.render(e)}};rs.kind="finally";var Yu=class{constructor(e,t={}){this._values={},this._blockStarts=[],this._constants={},this.opts=Ve(ie({},t),{_n:t.lines?`
22
+ `:""}),this._extScope=e,this._scope=new Je.Scope({parent:e}),this._nodes=[new Xu]}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 Vu(e,i,n)),i}const(e,t,n){return this._def(Je.varKinds.const,e,t,n)}let(e,t,n){return this._def(Je.varKinds.let,e,t,n)}var(e,t,n){return this._def(Je.varKinds.var,e,t,n)}assign(e,t,n){return this._leafNode(new $i(e,t,n))}add(e,t){return this._leafNode(new Hu(e,k.operators.ADD,t))}code(e){return typeof e=="function"?e():e!==M.nil&&this._leafNode(new Ku(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 at(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 at(e))}else(){return this._elseNode(new un)}endIf(){return this._endBlockNode(at,un)}_for(e,t){return this._blockNode(e),t&&this.code(t).endFor(),this}for(e,t){return this._for(new Bu(e),t)}forRange(e,t,n,s,i=this.opts.es5?Je.varKinds.var:Je.varKinds.let){let a=this._scope.toName(e);return this._for(new Wu(i,a,t,n),()=>s(a))}forOf(e,t,n,s=Je.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 _i("of",s,i,t),()=>n(i))}forIn(e,t,n,s=this.opts.es5?Je.varKinds.var:Je.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 _i("in",s,i,t),()=>n(i))}endFor(){return this._endBlockNode(vr)}label(e){return this._leafNode(new Uu(e))}break(e){return this._leafNode(new Gu(e))}return(e){let t=new es;if(this._blockNode(t),this.code(e),t.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(es)}try(e,t,n){if(!t&&!n)throw new Error('CodeGen: "try" without "catch" and "finally"');let s=new Ju;if(this._blockNode(s),this.code(e),t){let i=this.name("e");this._currNode=s.catch=new ts(i),t(i)}return n&&(this._currNode=s.finally=new rs,this.code(n)),this._endBlockNode(ts,rs)}throw(e){return this._leafNode(new zu(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 Qn(e,t,n)),s&&this.code(s).endFunc(),this}endFunc(){return this._endBlockNode(Qn)}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 at))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=Yu;function Kt(r,e){for(let t in e)r[t]=(r[t]||0)+(e[t]||0);return r}function ns(r,e){return e instanceof M._CodeOrName?Kt(r,e.names):r}function _r(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 jg(r,e){for(let t in e)r[t]=(r[t]||0)-(e[t]||0)}function Zu(r){return typeof r=="boolean"||typeof r=="number"||r===null?!r:(0,M._)`!${yi(r)}`}k.not=Zu;var kg=Qu(k.operators.AND);function xg(...r){return r.reduce(kg)}k.and=xg;var Lg=Qu(k.operators.OR);function Mg(...r){return r.reduce(Lg)}k.or=Mg;function Qu(r){return(e,t)=>e===M.nil?t:t===M.nil?e:(0,M._)`${yi(e)} ${r} ${yi(t)}`}function yi(r){return r instanceof M.Name?r:(0,M._)`(${r})`}});var G=y(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(),Fg=cn();function Vg(r){let e={};for(let t of r)e[t]=!0;return e}x.toHash=Vg;function Hg(r,e){return typeof e=="boolean"?e:Object.keys(e).length===0?!0:(rl(r,e),!nl(e,r.self.RULES.all))}x.alwaysValidSchema=Hg;function rl(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]||ol(r,`unknown keyword: "${i}"`)}x.checkUnknownRules=rl;function nl(r,e){if(typeof r=="boolean")return!r;for(let t in r)if(e[t])return!0;return!1}x.schemaHasRules=nl;function Ug(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=Ug;function Gg({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=Gg;function zg(r){return sl(decodeURIComponent(r))}x.unescapeFragment=zg;function Kg(r){return encodeURIComponent(Ei(r))}x.escapeFragment=Kg;function Ei(r){return typeof r=="number"?`${r}`:r.replace(/~/g,"~0").replace(/\//g,"~1")}x.escapeJsonPointer=Ei;function sl(r){return r.replace(/~1/g,"/").replace(/~0/g,"~")}x.unescapeJsonPointer=sl;function Xg(r,e){if(Array.isArray(r))for(let t of r)e(t);else e(r)}x.eachItem=Xg;function el({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:el({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} || {}`),wi(r,t,e))}),mergeValues:(r,e)=>r===!0?!0:ie(ie({},r),e),resultToName:il}),items:el({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 il(r,e){if(e===!0)return r.var("props",!0);let t=r.var("props",(0,Z._)`{}`);return e!==void 0&&wi(r,t,e),t}x.evaluatedPropsToName=il;function wi(r,e,t){Object.keys(t).forEach(n=>r.assign((0,Z._)`${e}${(0,Z.getProperty)(n)}`,!0))}x.setEvaluated=wi;var tl={};function Bg(r,e){return r.scopeValue("func",{ref:e,code:tl[e.code]||(tl[e.code]=new Fg._Code(e.code))})}x.useFunc=Bg;var al;(function(r){r[r.Num=0]="Num",r[r.Str=1]="Str"})(al=x.Type||(x.Type={}));function Wg(r,e,t){if(r instanceof Z.Name){let n=e===al.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():"/"+Ei(r)}x.getErrorPath=Wg;function ol(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=ol});var $t=y(bi=>{"use strict";Object.defineProperty(bi,"__esModule",{value:!0});var Ee=L(),Jg={data:new Ee.Name("data"),valCxt:new Ee.Name("valCxt"),instancePath:new Ee.Name("instancePath"),parentData:new Ee.Name("parentData"),parentDataProperty:new Ee.Name("parentDataProperty"),rootData:new Ee.Name("rootData"),dynamicAnchors:new Ee.Name("dynamicAnchors"),vErrors:new Ee.Name("vErrors"),errors:new Ee.Name("errors"),this:new Ee.Name("this"),self:new Ee.Name("self"),scope:new Ee.Name("scope"),json:new Ee.Name("json"),jsonPos:new Ee.Name("jsonPos"),jsonLen:new Ee.Name("jsonLen"),jsonPart:new Ee.Name("jsonPart")};bi.default=Jg});var ln=y(we=>{"use strict";Object.defineProperty(we,"__esModule",{value:!0});we.extendErrors=we.resetErrorsCount=we.reportExtraError=we.reportError=we.keyword$DataError=we.keywordError=void 0;var V=L(),as=G(),Oe=$t();we.keywordError={message:({keyword:r})=>(0,V.str)`must pass "${r}" keyword validation`};we.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 Yg(r,e=we.keywordError,t,n){let{it:s}=r,{gen:i,compositeRule:a,allErrors:c}=s,u=ll(r,e,t);(n!=null?n:a||c)?cl(i,u):ul(s,(0,V._)`[${u}]`)}we.reportError=Yg;function Zg(r,e=we.keywordError,t){let{it:n}=r,{gen:s,compositeRule:i,allErrors:a}=n,c=ll(r,e,t);cl(s,c),i||a||ul(n,Oe.default.vErrors)}we.reportExtraError=Zg;function Qg(r,e){r.assign(Oe.default.errors,e),r.if((0,V._)`${Oe.default.vErrors} !== null`,()=>r.if(e,()=>r.assign((0,V._)`${Oe.default.vErrors}.length`,e),()=>r.assign(Oe.default.vErrors,null)))}we.resetErrorsCount=Qg;function ev({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,Oe.default.errors,c=>{r.const(a,(0,V._)`${Oe.default.vErrors}[${c}]`),r.if((0,V._)`${a}.instancePath === undefined`,()=>r.assign((0,V._)`${a}.instancePath`,(0,V.strConcat)(Oe.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))})}we.extendErrors=ev;function cl(r,e){let t=r.const("err",e);r.if((0,V._)`${Oe.default.vErrors} === null`,()=>r.assign(Oe.default.vErrors,(0,V._)`[${t}]`),(0,V._)`${Oe.default.vErrors}.push(${t})`),r.code((0,V._)`${Oe.default.errors}++`)}function ul(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 Xt={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 ll(r,e,t){let{createErrors:n}=r.it;return n===!1?(0,V._)`{}`:tv(r,e,t)}function tv(r,e,t={}){let{gen:n,it:s}=r,i=[rv(s,t),nv(r,t)];return sv(r,e,i),n.object(...i)}function rv({errorPath:r},{instancePath:e}){let t=e?(0,V.str)`${r}${(0,as.getErrorPath)(e,as.Type.Str)}`:r;return[Oe.default.instancePath,(0,V.strConcat)(Oe.default.instancePath,t)]}function nv({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,as.getErrorPath)(t,as.Type.Str)}`),[Xt.schemaPath,s]}function sv(r,{params:e,message:t},n){let{keyword:s,data:i,schemaValue:a,it:c}=r,{opts:u,propertyName:o,topSchemaRef:l,schemaPath:h}=c;n.push([Xt.keyword,s],[Xt.params,typeof e=="function"?e(r):e||(0,V._)`{}`]),u.messages&&n.push([Xt.message,typeof t=="function"?t(r):t]),u.verbose&&n.push([Xt.schema,a],[Xt.parentSchema,(0,V._)`${l}${h}`],[Oe.default.data,i]),o&&n.push([Xt.propertyName,o])}});var dl=y(yr=>{"use strict";Object.defineProperty(yr,"__esModule",{value:!0});yr.boolOrEmptySchema=yr.topBoolOrEmptySchema=void 0;var iv=ln(),av=L(),ov=$t(),cv={message:"boolean schema is false"};function uv(r){let{gen:e,schema:t,validateName:n}=r;t===!1?fl(r,!1):typeof t=="object"&&t.$async===!0?e.return(ov.default.data):(e.assign((0,av._)`${n}.errors`,null),e.return(!0))}yr.topBoolOrEmptySchema=uv;function lv(r,e){let{gen:t,schema:n}=r;n===!1?(t.var(e,!1),fl(r)):t.var(e,!0)}yr.boolOrEmptySchema=lv;function fl(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,iv.reportError)(s,cv,void 0,e)}});var Si=y($r=>{"use strict";Object.defineProperty($r,"__esModule",{value:!0});$r.getRules=$r.isJSONType=void 0;var fv=["string","number","integer","boolean","null","object","array"],dv=new Set(fv);function hv(r){return typeof r=="string"&&dv.has(r)}$r.isJSONType=hv;function pv(){let r={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:Ve(ie({},r),{integer:!0,boolean:!0,null:!0}),rules:[{rules:[]},r.number,r.string,r.array,r.object],post:{rules:[]},all:{},keywords:{}}}$r.getRules=pv});var Oi=y(Nt=>{"use strict";Object.defineProperty(Nt,"__esModule",{value:!0});Nt.shouldUseRule=Nt.shouldUseGroup=Nt.schemaHasRulesForType=void 0;function mv({schema:r,self:e},t){let n=e.RULES.types[t];return n&&n!==!0&&hl(r,n)}Nt.schemaHasRulesForType=mv;function hl(r,e){return e.rules.some(t=>pl(r,t))}Nt.shouldUseGroup=hl;function pl(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))}Nt.shouldUseRule=pl});var dn=y(he=>{"use strict";Object.defineProperty(he,"__esModule",{value:!0});he.reportTypeError=he.checkDataTypes=he.checkDataType=he.coerceAndCheckDataType=he.getJSONTypes=he.getSchemaTypes=he.DataType=void 0;var gv=Si(),vv=Oi(),_v=ln(),q=L(),ml=G(),fn;(function(r){r[r.Correct=0]="Correct",r[r.Wrong=1]="Wrong"})(fn=he.DataType||(he.DataType={}));function yv(r){let e=gl(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}he.getSchemaTypes=yv;function gl(r){let e=Array.isArray(r)?r:r?[r]:[];if(e.every(gv.isJSONType))return e;throw new Error("type must be JSONType or JSONType[]: "+e.join(","))}he.getJSONTypes=gl;function $v(r,e){let{gen:t,data:n,opts:s}=r,i=Ev(e,s.coerceTypes),a=e.length>0&&!(i.length===0&&e.length===1&&(0,vv.schemaHasRulesForType)(r,e[0]));if(a){let c=Ri(e,n,s.strictNumbers,fn.Wrong);t.if(c,()=>{i.length?wv(r,e,i):Ci(r)})}return a}he.coerceAndCheckDataType=$v;var vl=new Set(["string","number","integer","boolean","null"]);function Ev(r,e){return e?r.filter(t=>vl.has(t)||e==="array"&&t==="array"):[]}function wv(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(Ri(e,s,i.strictNumbers),()=>n.assign(c,s))),n.if((0,q._)`${c} !== undefined`);for(let o of t)(vl.has(o)||o==="array"&&i.coerceTypes==="array")&&u(o);n.else(),Ci(r),n.endIf(),n.if((0,q._)`${c} !== undefined`,()=>{n.assign(s,c),bv(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
19
23
  || (${a} == "string" && ${s} && ${s} == +${s})`).assign(c,(0,q._)`+${s}`);return;case"integer":n.elseIf((0,q._)`${a} === "boolean" || ${s} === null
20
24
  || (${a} === "string" && ${s} && ${s} == +${s} && !(${s} % 1))`).assign(c,(0,q._)`+${s}`);return;case"boolean":n.elseIf((0,q._)`${s} === "false" || ${s} === 0 || ${s} === null`).assign(c,!1).elseIf((0,q._)`${s} === "true" || ${s} === 1`).assign(c,!0);return;case"null":n.elseIf((0,q._)`${s} === "" || ${s} === 0 || ${s} === false`),n.assign(c,null);return;case"array":n.elseIf((0,q._)`${a} === "string" || ${a} === "number"
21
- || ${a} === "boolean" || ${s} === null`).assign(c,(0,q._)`[${s}]`)}}}function yv({gen:r,parentData:e,parentDataProperty:t},n){r.if((0,q._)`${e} !== undefined`,()=>r.assign((0,q._)`${e}[${t}]`,n))}function Oi(r,e,t,n=ln.Correct){let s=n===ln.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===ln.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)}}he.checkDataType=Oi;function Pi(r,e,t,n){if(r.length===1)return Oi(r[0],e,t,n);let s,i=(0,pl.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,Oi(a,e,t,n));return s}he.checkDataTypes=Pi;var $v={message:({schema:r})=>`must be ${r}`,params:({schema:r,schemaValue:e})=>typeof r=="string"?(0,q._)`{type: ${r}}`:(0,q._)`{type: ${e}}`};function Ri(r){let e=Ev(r);(0,pv.reportError)(e,$v)}he.reportTypeError=Ri;function Ev(r){let{gen:e,data:t,schema:n}=r,s=(0,pl.schemaRefOrVal)(r,n,"type");return{gen:e,keyword:"type",data:t,schema:n.type,schemaCode:s,schemaValue:s,parentSchema:n,params:{},it:r}}});var _l=y(os=>{"use strict";Object.defineProperty(os,"__esModule",{value:!0});os.assignDefaults=void 0;var _r=L(),wv=G();function bv(r,e){let{properties:t,items:n}=r.schema;if(e==="object"&&t)for(let s in t)vl(r,s,t[s].default);else e==="array"&&Array.isArray(n)&&n.forEach((s,i)=>vl(r,i,s.default))}os.assignDefaults=bv;function vl(r,e,t){let{gen:n,compositeRule:s,data:i,opts:a}=r;if(t===void 0)return;let c=(0,_r._)`${i}${(0,_r.getProperty)(e)}`;if(s){(0,wv.checkStrictMode)(r,`default is ignored for: ${c}`);return}let u=(0,_r._)`${c} === undefined`;a.useDefaults==="empty"&&(u=(0,_r._)`${u} || ${c} === null || ${c} === ""`),n.if(u,(0,_r._)`${c} = ${(0,_r.stringify)(t)}`)}});var Ge=y(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 ee=L(),Ci=G(),Nt=$t(),Sv=G();function Ov(r,e){let{gen:t,data:n,it:s}=r;t.if(Ii(t,n,e,s.opts.ownProperties),()=>{r.setParams({missingProperty:(0,ee._)`${e}`},!0),r.error()})}J.checkReportMissingProp=Ov;function Pv({gen:r,data:e,it:{opts:t}},n,s){return(0,ee.or)(...n.map(i=>(0,ee.and)(Ii(r,e,i,t.ownProperties),(0,ee._)`${s} = ${i}`)))}J.checkMissingProp=Pv;function Rv(r,e){r.setParams({missingProperty:e},!0),r.error()}J.reportMissingProp=Rv;function yl(r){return r.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,ee._)`Object.prototype.hasOwnProperty`})}J.hasPropFunc=yl;function Ni(r,e,t){return(0,ee._)`${yl(r)}.call(${e}, ${t})`}J.isOwnProperty=Ni;function Cv(r,e,t,n){let s=(0,ee._)`${e}${(0,ee.getProperty)(t)} !== undefined`;return n?(0,ee._)`${s} && ${Ni(r,e,t)}`:s}J.propertyInData=Cv;function Ii(r,e,t,n){let s=(0,ee._)`${e}${(0,ee.getProperty)(t)} === undefined`;return n?(0,ee.or)(s,(0,ee.not)(Ni(r,e,t))):s}J.noPropertyInData=Ii;function $l(r){return r?Object.keys(r).filter(e=>e!=="__proto__"):[]}J.allSchemaProperties=$l;function Nv(r,e){return $l(e).filter(t=>!(0,Ci.alwaysValidSchema)(r,e[t]))}J.schemaProperties=Nv;function Iv({schemaCode:r,data:e,it:{gen:t,topSchemaRef:n,schemaPath:s,errorPath:i},it:a},c,u,o){let l=o?(0,ee._)`${r}, ${e}, ${n}${s}`:e,h=[[Nt.default.instancePath,(0,ee.strConcat)(Nt.default.instancePath,i)],[Nt.default.parentData,a.parentData],[Nt.default.parentDataProperty,a.parentDataProperty],[Nt.default.rootData,Nt.default.rootData]];a.opts.dynamicRef&&h.push([Nt.default.dynamicAnchors,Nt.default.dynamicAnchors]);let g=(0,ee._)`${l}, ${t.object(...h)}`;return u!==ee.nil?(0,ee._)`${c}.call(${u}, ${g})`:(0,ee._)`${c}(${g})`}J.callValidateCode=Iv;var Av=(0,ee._)`new RegExp`;function Tv({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,ee._)`${s.code==="new RegExp"?Av:(0,Sv.useFunc)(r,s)}(${t}, ${n})`})}J.usePattern=Tv;function qv(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,ee._)`${t}.length`);e.forRange("i",0,u,o=>{r.subschema({keyword:n,dataProp:o,dataPropType:Ci.Type.Num},i),e.if((0,ee.not)(i),c)})}}J.validateArray=qv;function Dv(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,Ci.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,ee._)`${a} || ${c}`),r.mergeValidEvaluated(l,c)||e.if((0,ee.not)(a))})),r.result(a,()=>r.reset(),()=>r.error(!0))}J.validateUnion=Dv});var bl=y(ot=>{"use strict";Object.defineProperty(ot,"__esModule",{value:!0});ot.validateKeywordUsage=ot.validSchemaType=ot.funcKeywordCode=ot.macroKeywordCode=void 0;var Oe=L(),Xt=$t(),jv=Ge(),kv=un();function xv(r,e){let{gen:t,keyword:n,schema:s,parentSchema:i,it:a}=r,c=e.macro.call(a.self,s,i,a),u=wl(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))}ot.macroKeywordCode=xv;function Lv(r,e){var t;let{gen:n,keyword:s,schema:i,parentSchema:a,$data:c,it:u}=r;Fv(u,e);let o=!c&&e.compile?e.compile.call(u.self,i,a,u):e.validate,l=wl(n,s,o),h=n.let("valid");r.block$data(h,g),r.ok((t=e.valid)!==null&&t!==void 0?t:h);function g(){if(e.errors===!1)E(),e.modifying&&El(r),w(()=>r.error());else{let b=e.async?v():$();e.modifying&&El(r),w(()=>Mv(r,b))}}function v(){let b=n.let("ruleErrs",null);return n.try(()=>E((0,Oe._)`await `),D=>n.assign(h,!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?Xt.default.this:Xt.default.self,A=!("compile"in e&&!c||e.schema===!1);n.assign(h,(0,Oe._)`${b}${(0,jv.callValidateCode)(r,l,D,A)}`,e.modifying)}function w(b){var D;n.if((0,Oe.not)((D=e.valid)!==null&&D!==void 0?D:h),b)}}ot.funcKeywordCode=Lv;function El(r){let{gen:e,data:t,it:n}=r;e.if(n.parentData,()=>e.assign(t,(0,Oe._)`${n.parentData}[${n.parentDataProperty}]`))}function Mv(r,e){let{gen:t}=r;t.if((0,Oe._)`Array.isArray(${e})`,()=>{t.assign(Xt.default.vErrors,(0,Oe._)`${Xt.default.vErrors} === null ? ${e} : ${Xt.default.vErrors}.concat(${e})`).assign(Xt.default.errors,(0,Oe._)`${Xt.default.vErrors}.length`),(0,kv.extendErrors)(r)},()=>r.error())}function Fv({schemaEnv:r},e){if(e.async&&!r.$async)throw new Error("async keyword in sync schema")}function wl(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 Vv(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")}ot.validSchemaType=Vv;function Uv({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)}}ot.validateKeywordUsage=Uv});var Ol=y(It=>{"use strict";Object.defineProperty(It,"__esModule",{value:!0});It.extendSubschemaMode=It.extendSubschemaData=It.getSubschema=void 0;var ct=L(),Sl=G();function Hv(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,ct._)`${r.schemaPath}${(0,ct.getProperty)(e)}`,errSchemaPath:`${r.errSchemaPath}/${e}`}:{schema:c[t],schemaPath:(0,ct._)`${r.schemaPath}${(0,ct.getProperty)(e)}${(0,ct.getProperty)(t)}`,errSchemaPath:`${r.errSchemaPath}/${e}/${(0,Sl.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')}It.getSubschema=Hv;function Gv(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:h}=e,g=c.let("data",(0,ct._)`${e.data}${(0,ct.getProperty)(t)}`,!0);u(g),r.errorPath=(0,ct.str)`${o}${(0,Sl.getErrorPath)(t,n,h.jsPropertySyntax)}`,r.parentDataProperty=(0,ct._)`${t}`,r.dataPathArr=[...l,r.parentDataProperty]}if(s!==void 0){let o=s instanceof ct.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]}}It.extendSubschemaData=Gv;function zv(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}It.extendSubschemaMode=zv});var Ai=y((Xw,Pl)=>{"use strict";Pl.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 Cl=y((Bw,Rl)=>{"use strict";var At=Rl.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(){};cs(e,n,s,r,"",r)};At.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};At.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};At.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};At.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 cs(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 h=n[l];if(Array.isArray(h)){if(l in At.arrayKeywords)for(var g=0;g<h.length;g++)cs(r,e,t,h[g],s+"/"+l+"/"+g,i,s,l,n,g)}else if(l in At.propsKeywords){if(h&&typeof h=="object")for(var v in h)cs(r,e,t,h[v],s+"/"+l+"/"+Kv(v),i,s,l,n,v)}else(l in At.keywords||r.allKeys&&!(l in At.skipKeywords))&&cs(r,e,t,h,s+"/"+l,i,s,l,n)}t(n,s,i,a,c,u,o)}}function Kv(r){return r.replace(/~/g,"~0").replace(/\//g,"~1")}});var dn=y(Ce=>{"use strict";Object.defineProperty(Ce,"__esModule",{value:!0});Ce.getSchemaRefs=Ce.resolveUrl=Ce.normalizeId=Ce._getFullPath=Ce.getFullPath=Ce.inlineRef=void 0;var Xv=G(),Bv=Ai(),Wv=Cl(),Jv=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function Yv(r,e=!0){return typeof r=="boolean"?!0:e===!0?!Ti(r):e?Nl(r)<=e:!1}Ce.inlineRef=Yv;var Zv=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function Ti(r){for(let e in r){if(Zv.has(e))return!0;let t=r[e];if(Array.isArray(t)&&t.some(Ti)||typeof t=="object"&&Ti(t))return!0}return!1}function Nl(r){let e=0;for(let t in r){if(t==="$ref")return 1/0;if(e++,!Jv.has(t)&&(typeof r[t]=="object"&&(0,Xv.eachItem)(r[t],n=>e+=Nl(n)),e===1/0))return 1/0}return e}function Il(r,e="",t){t!==!1&&(e=yr(e));let n=r.parse(e);return Al(r,n)}Ce.getFullPath=Il;function Al(r,e){return r.serialize(e).split("#")[0]+"#"}Ce._getFullPath=Al;var Qv=/#\/?$/;function yr(r){return r?r.replace(Qv,""):""}Ce.normalizeId=yr;function e_(r,e,t){return t=yr(t),r.resolve(e,t)}Ce.resolveUrl=e_;var t_=/^[a-z_][-a-z0-9._]*$/i;function r_(r,e){if(typeof r=="boolean")return{};let{schemaId:t,uriResolver:n}=this.opts,s=yr(r[t]||e),i={"":s},a=Il(n,s,!1),c={},u=new Set;return Wv(r,{allKeys:!0},(h,g,v,$)=>{if($===void 0)return;let E=a+g,w=i[$];typeof h[t]=="string"&&(w=b.call(this,h[t])),D.call(this,h.$anchor),D.call(this,h.$dynamicAnchor),i[g]=w;function b(A){let z=this.opts.uriResolver.resolve;if(A=yr(w?z(w,A):A),u.has(A))throw l(A);u.add(A);let C=this.refs[A];return typeof C=="string"&&(C=this.refs[C]),typeof C=="object"?o(h,C.schema,A):A!==yr(E)&&(A[0]==="#"?(o(h,c[A],A),c[A]=h):this.refs[A]=E),A}function D(A){if(typeof A=="string"){if(!t_.test(A))throw new Error(`invalid anchor "${A}"`);b.call(this,`#${A}`)}}}),c;function o(h,g,v){if(g!==void 0&&!Bv(h,g))throw l(v)}function l(h){return new Error(`reference "${h}" resolves to more than one schema`)}}Ce.getSchemaRefs=r_});var mn=y(Tt=>{"use strict";Object.defineProperty(Tt,"__esModule",{value:!0});Tt.getData=Tt.KeywordCxt=Tt.validateFunctionCode=void 0;var xl=fl(),Tl=fn(),Di=Si(),us=fn(),n_=_l(),pn=bl(),qi=Ol(),R=L(),I=$t(),s_=dn(),Et=G(),hn=un();function i_(r){if(Fl(r)&&(Vl(r),Ml(r))){c_(r);return}Ll(r,()=>(0,xl.topBoolOrEmptySchema)(r))}Tt.validateFunctionCode=i_;function Ll({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"; ${ql(t,s)}`),o_(r,s),r.code(i)}):r.func(e,(0,R._)`${I.default.data}, ${a_(s)}`,n.$async,()=>r.code(ql(t,s)).code(i))}function a_(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 o_(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 c_(r){let{schema:e,opts:t,gen:n}=r;Ll(r,()=>{t.$comment&&e.$comment&&Hl(r),h_(r),n.let(I.default.vErrors,null),n.let(I.default.errors,0),t.unevaluated&&u_(r),Ul(r),g_(r)})}function u_(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 ql(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 l_(r,e){if(Fl(r)&&(Vl(r),Ml(r))){f_(r,e);return}(0,xl.boolOrEmptySchema)(r,e)}function Ml({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 Fl(r){return typeof r.schema!="boolean"}function f_(r,e){let{schema:t,gen:n,opts:s}=r;s.$comment&&t.$comment&&Hl(r),p_(r),m_(r);let i=n.const("_errs",I.default.errors);Ul(r,i),n.var(e,(0,R._)`${i} === ${I.default.errors}`)}function Vl(r){(0,Et.checkUnknownRules)(r),d_(r)}function Ul(r,e){if(r.opts.jtd)return Dl(r,[],!1,e);let t=(0,Tl.getSchemaTypes)(r.schema),n=(0,Tl.coerceAndCheckDataType)(r,t);Dl(r,t,!n,e)}function d_(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 h_(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 p_(r){let e=r.schema[r.opts.schemaId];e&&(r.baseId=(0,s_.resolveUrl)(r.opts.uriResolver,r.baseId,e))}function m_(r){if(r.schema.$async&&!r.schemaEnv.$async)throw new Error("async schema in sync schema")}function Hl({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 g_(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&&v_(r),e.return((0,R._)`${I.default.errors} === 0`))}function v_({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 Dl(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(()=>Gl(r,"$ref",l.all.$ref.definition));return}u.jtd||__(r,e),s.block(()=>{for(let g of l.rules)h(g);h(l.post)});function h(g){!(0,Di.shouldUseGroup)(i,g)||(g.type?(s.if((0,us.checkDataType)(g.type,a,u.strictNumbers)),jl(r,g),e.length===1&&e[0]===g.type&&t&&(s.else(),(0,us.reportTypeError)(r)),s.endIf()):jl(r,g),c||s.if((0,R._)`${I.default.errors} === ${n||0}`))}}function jl(r,e){let{gen:t,schema:n,opts:{useDefaults:s}}=r;s&&(0,n_.assignDefaults)(r,e.type),t.block(()=>{for(let i of e.rules)(0,Di.shouldUseRule)(n,i)&&Gl(r,i.keyword,i.definition,e.type)})}function __(r,e){r.schemaEnv.meta||!r.opts.strictTypes||(y_(r,e),r.opts.allowUnionTypes||$_(r,e),E_(r,r.dataTypes))}function y_(r,e){if(!!e.length){if(!r.dataTypes.length){r.dataTypes=e;return}e.forEach(t=>{kl(r.dataTypes,t)||ji(r,`type "${t}" not allowed by context "${r.dataTypes.join(",")}"`)}),r.dataTypes=r.dataTypes.filter(t=>kl(e,t))}}function $_(r,e){e.length>1&&!(e.length===2&&e.includes("null"))&&ji(r,"use allowUnionTypes to allow union type keyword")}function E_(r,e){let t=r.self.RULES.all;for(let n in t){let s=t[n];if(typeof s=="object"&&(0,Di.shouldUseRule)(r.schema,s)){let{type:i}=s.definition;i.length&&!i.some(a=>w_(e,a))&&ji(r,`missing type "${i.join(",")}" for keyword "${n}"`)}}}function w_(r,e){return r.includes(e)||e==="number"&&r.includes("integer")}function kl(r,e){return r.includes(e)||e==="integer"&&r.includes("number")}function ji(r,e){e+=` at "${r.schemaEnv.baseId+r.errSchemaPath}" (strictTypes)`,(0,Et.checkStrictMode)(r,e,r.opts.strictTypes)}var ki=class{constructor(e,t,n){if((0,pn.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",zl(this.$data,e));else if(this.schemaCode=this.schemaValue,!(0,pn.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?hn.reportExtraError:hn.reportError)(this,this.def.error,t)}$dataError(){(0,hn.reportError)(this,this.def.$dataError||hn.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,hn.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,us.checkDataTypes)(u,t,i.opts.strictNumbers,us.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,qi.getSubschema)(this.it,e);(0,qi.extendSubschemaData)(n,this.it,e),(0,qi.extendSubschemaMode)(n,e);let s=Fe(ie(ie({},this.it),n),{items:void 0,props:void 0});return l_(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=ki;function Gl(r,e,t,n){let s=new ki(r,t,e);"code"in t?t.code(s,n):s.$data&&t.validate?(0,pn.funcKeywordCode)(s,t):"macro"in t?(0,pn.macroKeywordCode)(s,t):(t.compile||t.validate)&&(0,pn.funcKeywordCode)(s,t)}var b_=/^\/(?:[^~]|~0|~1)*$/,S_=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function zl(r,{dataLevel:e,dataNames:t,dataPathArr:n}){let s,i;if(r==="")return I.default.rootData;if(r[0]==="/"){if(!b_.test(r))throw new Error(`Invalid JSON-pointer: ${r}`);s=r,i=I.default.rootData}else{let o=S_.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=zl});var Li=y(xi=>{"use strict";Object.defineProperty(xi,"__esModule",{value:!0});var Kl=class extends Error{constructor(e){super("validation failed");this.errors=e,this.ajv=this.validation=!0}};xi.default=Kl});var Vi=y(Fi=>{"use strict";Object.defineProperty(Fi,"__esModule",{value:!0});var Mi=dn(),Xl=class extends Error{constructor(e,t,n,s){super(s||`can't resolve reference ${n} from id ${t}`);this.missingRef=(0,Mi.resolveUrl)(e,t,n),this.missingSchema=(0,Mi.normalizeId)((0,Mi.getFullPath)(e,this.missingRef))}};Fi.default=Xl});var fs=y(ze=>{"use strict";Object.defineProperty(ze,"__esModule",{value:!0});ze.resolveSchema=ze.getCompilingSchema=ze.resolveRef=ze.compileSchema=ze.SchemaEnv=void 0;var Ye=L(),O_=Li(),Bt=$t(),Ze=dn(),Bl=G(),P_=mn(),gn=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={}}};ze.SchemaEnv=gn;function Hi(r){let e=Wl.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:O_.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:Bt.default.data,parentData:Bt.default.parentData,parentDataProperty:Bt.default.parentDataProperty,dataNames:[Bt.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,P_.validateFunctionCode)(o),a.optimize(this.opts.code.optimize);let h=a.toString();l=`${a.scopeRefs(Bt.default.scope)}return ${h}`,this.opts.code.process&&(l=this.opts.code.process(l,r));let v=new Function(`${Bt.default.self}`,`${Bt.default.scope}`,l)(this,this.scope.get());if(this.scope.value(u,{ref:v}),v.errors=null,v.schema=r.schema,v.schemaEnv=r,r.$async&&(v.$async=!0),this.opts.code.source===!0&&(v.source={validateName:u,validateCode:h,scopeValues:a._values}),this.opts.unevaluated){let{props:$,items:E}=o;v.evaluated={props:$ instanceof Ye.Name?void 0:$,items:E instanceof Ye.Name?void 0:E,dynamicProps:$ instanceof Ye.Name,dynamicItems:E instanceof Ye.Name},v.source&&(v.source.evaluated=(0,Ye.stringify)(v.evaluated))}return r.validate=v,r}catch(h){throw delete r.validate,delete r.validateName,l&&this.logger.error("Error compiling schema, function code:",l),h}finally{this._compilations.delete(r)}}ze.compileSchema=Hi;function R_(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=I_.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 gn({schema:a,schemaId:c,root:r,baseId:e}))}if(i!==void 0)return r.refs[t]=C_.call(this,i)}ze.resolveRef=R_;function C_(r){return(0,Ze.inlineRef)(r.schema,this.opts.inlineRefs)?r.schema:r.validate?r:Hi.call(this,r)}function Wl(r){for(let e of this._compilations)if(N_(e,r))return e}ze.getCompilingSchema=Wl;function N_(r,e){return r.schema===e.schema&&r.root===e.root&&r.baseId===e.baseId}function I_(r,e){let t;for(;typeof(t=this.refs[e])=="string";)e=t;return t||this.schemas[e]||ls.call(this,r,e)}function ls(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 Ui.call(this,t,r);let i=(0,Ze.normalizeId)(n),a=this.refs[i]||this.schemas[i];if(typeof a=="string"){let c=ls.call(this,r,a);return typeof(c==null?void 0:c.schema)!="object"?void 0:Ui.call(this,t,c)}if(typeof(a==null?void 0:a.schema)=="object"){if(a.validate||Hi.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 gn({schema:c,schemaId:u,root:r,baseId:s})}return Ui.call(this,t,a)}}ze.resolveSchema=ls;var A_=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function Ui(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,Bl.unescapeFragment)(c)];if(u===void 0)return;t=u;let o=typeof t=="object"&&t[this.opts.schemaId];!A_.has(c)&&o&&(e=(0,Ze.resolveUrl)(this.opts.uriResolver,e,o))}let i;if(typeof t!="boolean"&&t.$ref&&!(0,Bl.schemaHasRulesButRef)(t,this.RULES)){let c=(0,Ze.resolveUrl)(this.opts.uriResolver,e,t.$ref);i=ls.call(this,n,c)}let{schemaId:a}=this.opts;if(i=i||new gn({schema:t,schemaId:a,root:n,baseId:e}),i.schema!==i.root.schema)return i}});var Jl=y((eb,T_)=>{T_.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 Zl=y((ds,Yl)=>{(function(r,e){typeof ds=="object"&&typeof Yl<"u"?e(ds):typeof define=="function"&&define.amd?define(["exports"],e):e(r.URI=r.URI||{})})(ds,function(r){"use strict";function e(){for(var d=arguments.length,f=Array(d),p=0;p<d;p++)f[p]=arguments[p];if(f.length>1){f[0]=f[0].slice(0,-1);for(var m=f.length-1,_=1;_<m;++_)f[_]=f[_].slice(1,-1);return f[m]=f[m].slice(1),f.join("")}else return f[0]}function t(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,f){var p=d;if(f)for(var m in f)p[m]=f[m];return p}function c(d){var f="[A-Za-z]",p="[\\x0D]",m="[0-9]",_="[\\x22]",S=e(m,"[A-Fa-f]"),T="[\\x0A]",U="[\\x20]",B=t(t("%[EFef]"+S+"%"+S+S+"%"+S+S)+"|"+t("%[89A-Fa-f]"+S+"%"+S+S)+"|"+t("%"+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(f,m,"[\\-\\.\\_\\~]",ue),se=t(f+e(f,m,"[\\+\\-\\.]")+"*"),W=t(t(B+"|"+e(K,F,"[\\:]"))+"*"),jt=t(t("25[0-5]")+"|"+t("2[0-4]"+m)+"|"+t("1"+m+m)+"|"+t("[1-9]"+m)+"|"+m),Ae=t(t("25[0-5]")+"|"+t("2[0-4]"+m)+"|"+t("1"+m+m)+"|"+t("0?[1-9]"+m)+"|0?0?"+m),Le=t(Ae+"\\."+Ae+"\\."+Ae+"\\."+Ae),Y=t(S+"{1,4}"),Te=t(t(Y+"\\:"+Y)+"|"+Le),Me=t(t(Y+"\\:")+"{6}"+Te),st=t("\\:\\:"+t(Y+"\\:")+"{5}"+Te),kt=t(t(Y)+"?\\:\\:"+t(Y+"\\:")+"{4}"+Te),pt=t(t(t(Y+"\\:")+"{0,1}"+Y)+"?\\:\\:"+t(Y+"\\:")+"{3}"+Te),jr=t(t(t(Y+"\\:")+"{0,2}"+Y)+"?\\:\\:"+t(Y+"\\:")+"{2}"+Te),Tn=t(t(t(Y+"\\:")+"{0,3}"+Y)+"?\\:\\:"+Y+"\\:"+Te),qn=t(t(t(Y+"\\:")+"{0,4}"+Y)+"?\\:\\:"+Te),nr=t(t(t(Y+"\\:")+"{0,5}"+Y)+"?\\:\\:"+Y),sr=t(t(t(Y+"\\:")+"{0,6}"+Y)+"?\\:\\:"),mt=t([Me,st,kt,pt,jr,Tn,qn,nr,sr].join("|")),ir=t(t(K+"|"+B)+"+"),Ds=t(mt+"\\%25"+ir),xt=t(mt+t("\\%25|\\%(?!"+S+"{2})")+ir),sh=t("[vV]"+S+"+\\."+e(K,F,"[\\:]")+"+"),ih=t("\\["+t(xt+"|"+mt+"|"+sh)+"\\]"),so=t(t(B+"|"+e(K,F))+"*"),kr=t(ih+"|"+Le+"(?!"+so+")|"+so),xr=t(m+"*"),io=t(t(W+"@")+"?"+kr+t("\\:"+xr)+"?"),Lr=t(B+"|"+e(K,F,"[\\:\\@]")),ah=t(Lr+"*"),ao=t(Lr+"+"),oh=t(t(B+"|"+e(K,F,"[\\@]"))+"+"),gt=t(t("\\/"+ah)+"*"),ar=t("\\/"+t(ao+gt)+"?"),js=t(oh+gt),Dn=t(ao+gt),or="(?!"+Lr+")",bE=t(gt+"|"+ar+"|"+js+"|"+Dn+"|"+or),cr=t(t(Lr+"|"+e("[\\/\\?]",re))+"*"),Mr=t(t(Lr+"|[\\/\\?]")+"*"),oo=t(t("\\/\\/"+io+gt)+"|"+ar+"|"+Dn+"|"+or),ch=t(se+"\\:"+oo+t("\\?"+cr)+"?"+t("\\#"+Mr)+"?"),uh=t(t("\\/\\/"+io+gt)+"|"+ar+"|"+js+"|"+or),lh=t(uh+t("\\?"+cr)+"?"+t("\\#"+Mr)+"?"),SE=t(ch+"|"+lh),OE=t(se+"\\:"+oo+t("\\?"+cr)+"?"),PE="^("+se+")\\:"+t(t("\\/\\/("+t("("+W+")@")+"?("+kr+")"+t("\\:("+xr+")")+"?)")+"?("+gt+"|"+ar+"|"+Dn+"|"+or+")")+t("\\?("+cr+")")+"?"+t("\\#("+Mr+")")+"?$",RE="^(){0}"+t(t("\\/\\/("+t("("+W+")@")+"?("+kr+")"+t("\\:("+xr+")")+"?)")+"?("+gt+"|"+ar+"|"+js+"|"+or+")")+t("\\?("+cr+")")+"?"+t("\\#("+Mr+")")+"?$",CE="^("+se+")\\:"+t(t("\\/\\/("+t("("+W+")@")+"?("+kr+")"+t("\\:("+xr+")")+"?)")+"?("+gt+"|"+ar+"|"+Dn+"|"+or+")")+t("\\?("+cr+")")+"?$",NE="^"+t("\\#("+Mr+")")+"?$",IE="^"+t("("+W+")@")+"?("+kr+")"+t("\\:("+xr+")")+"?$";return{NOT_SCHEME:new RegExp(e("[^]",f,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("^("+Le+")$"),IPV6ADDRESS:new RegExp("^\\[?("+mt+")"+t(t("\\%25|\\%(?!"+S+"{2})")+"("+ir+")")+"?\\]?$")}}var u=c(!1),o=c(!0),l=function(){function d(f,p){var m=[],_=!0,S=!1,T=void 0;try{for(var U=f[Symbol.iterator](),B;!(_=(B=U.next()).done)&&(m.push(B.value),!(p&&m.length===p));_=!0);}catch(ce){S=!0,T=ce}finally{try{!_&&U.return&&U.return()}finally{if(S)throw T}}return m}return function(f,p){if(Array.isArray(f))return f;if(Symbol.iterator in Object(f))return d(f,p);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),h=function(d){if(Array.isArray(d)){for(var f=0,p=Array(d.length);f<d.length;f++)p[f]=d[f];return p}else return Array.from(d)},g=2147483647,v=36,$=1,E=26,w=38,b=700,D=72,A=128,z="-",C=/^xn--/,ge=/[^\0-\x7E]/,De=/[\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"},je=v-$,te=Math.floor,ke=String.fromCharCode;function et(d){throw new RangeError(bt[d])}function In(d,f){for(var p=[],m=d.length;m--;)p[m]=f(d[m]);return p}function An(d,f){var p=d.split("@"),m="";p.length>1&&(m=p[0]+"@",d=p[1]),d=d.replace(De,".");var _=d.split("."),S=In(_,f).join(".");return m+S}function Fa(d){for(var f=[],p=0,m=d.length;p<m;){var _=d.charCodeAt(p++);if(_>=55296&&_<=56319&&p<m){var S=d.charCodeAt(p++);(S&64512)==56320?f.push(((_&1023)<<10)+(S&1023)+65536):(f.push(_),p--)}else f.push(_)}return f}var Dd=function(f){return String.fromCodePoint.apply(String,h(f))},jd=function(f){return f-48<10?f-22:f-65<26?f-65:f-97<26?f-97:v},Va=function(f,p){return f+22+75*(f<26)-((p!=0)<<5)},Ua=function(f,p,m){var _=0;for(f=m?te(f/b):f>>1,f+=te(f/p);f>je*E>>1;_+=v)f=te(f/je);return te(_+(je+1)*f/(f+w))},Ha=function(f){var p=[],m=f.length,_=0,S=A,T=D,U=f.lastIndexOf(z);U<0&&(U=0);for(var B=0;B<U;++B)f.charCodeAt(B)>=128&&et("not-basic"),p.push(f.charCodeAt(B));for(var ce=U>0?U+1:0;ce<m;){for(var F=_,ne=1,ue=v;;ue+=v){ce>=m&&et("invalid-input");var re=jd(f.charCodeAt(ce++));(re>=v||re>te((g-_)/ne))&&et("overflow"),_+=re*ne;var K=ue<=T?$:ue>=T+E?E:ue-T;if(re<K)break;var se=v-K;ne>te(g/se)&&et("overflow"),ne*=se}var W=p.length+1;T=Ua(_-F,W,F==0),te(_/W)>g-S&&et("overflow"),S+=te(_/W),_%=W,p.splice(_++,0,S)}return String.fromCodePoint.apply(String,p)},Ga=function(f){var p=[];f=Fa(f);var m=f.length,_=A,S=0,T=D,U=!0,B=!1,ce=void 0;try{for(var F=f[Symbol.iterator](),ne;!(U=(ne=F.next()).done);U=!0){var ue=ne.value;ue<128&&p.push(ke(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=g,W=!0,jt=!1,Ae=void 0;try{for(var Le=f[Symbol.iterator](),Y;!(W=(Y=Le.next()).done);W=!0){var Te=Y.value;Te>=_&&Te<se&&(se=Te)}}catch(xt){jt=!0,Ae=xt}finally{try{!W&&Le.return&&Le.return()}finally{if(jt)throw Ae}}var Me=K+1;se-_>te((g-S)/Me)&&et("overflow"),S+=(se-_)*Me,_=se;var st=!0,kt=!1,pt=void 0;try{for(var jr=f[Symbol.iterator](),Tn;!(st=(Tn=jr.next()).done);st=!0){var qn=Tn.value;if(qn<_&&++S>g&&et("overflow"),qn==_){for(var nr=S,sr=v;;sr+=v){var mt=sr<=T?$:sr>=T+E?E:sr-T;if(nr<mt)break;var ir=nr-mt,Ds=v-mt;p.push(ke(Va(mt+ir%Ds,0))),nr=te(ir/Ds)}p.push(ke(Va(nr,0))),T=Ua(S,Me,K==re),S=0,++K}}}catch(xt){kt=!0,pt=xt}finally{try{!st&&jr.return&&jr.return()}finally{if(kt)throw pt}}++S,++_}return p.join("")},kd=function(f){return An(f,function(p){return C.test(p)?Ha(p.slice(4).toLowerCase()):p})},xd=function(f){return An(f,function(p){return ge.test(p)?"xn--"+Ga(p):p})},Qt={version:"2.1.0",ucs2:{decode:Fa,encode:Dd},decode:Ha,encode:Ga,toASCII:xd,toUnicode:kd},xe={};function tt(d){var f=d.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 er(d){for(var f="",p=0,m=d.length;p<m;){var _=parseInt(d.substr(p+1,2),16);if(_<128)f+=String.fromCharCode(_),p+=3;else if(_>=194&&_<224){if(m-p>=6){var S=parseInt(d.substr(p+4,2),16);f+=String.fromCharCode((_&31)<<6|S&63)}else f+=d.substr(p,6);p+=6}else if(_>=224){if(m-p>=9){var T=parseInt(d.substr(p+4,2),16),U=parseInt(d.substr(p+7,2),16);f+=String.fromCharCode((_&15)<<12|(T&63)<<6|U&63)}else f+=d.substr(p,9);p+=9}else f+=d.substr(p,3),p+=3}return f}function Is(d,f){function p(m){var _=er(m);return _.match(f.UNRESERVED)?_:m}return d.scheme&&(d.scheme=String(d.scheme).replace(f.PCT_ENCODED,p).toLowerCase().replace(f.NOT_SCHEME,"")),d.userinfo!==void 0&&(d.userinfo=String(d.userinfo).replace(f.PCT_ENCODED,p).replace(f.NOT_USERINFO,tt).replace(f.PCT_ENCODED,s)),d.host!==void 0&&(d.host=String(d.host).replace(f.PCT_ENCODED,p).toLowerCase().replace(f.NOT_HOST,tt).replace(f.PCT_ENCODED,s)),d.path!==void 0&&(d.path=String(d.path).replace(f.PCT_ENCODED,p).replace(d.scheme?f.NOT_PATH:f.NOT_PATH_NOSCHEME,tt).replace(f.PCT_ENCODED,s)),d.query!==void 0&&(d.query=String(d.query).replace(f.PCT_ENCODED,p).replace(f.NOT_QUERY,tt).replace(f.PCT_ENCODED,s)),d.fragment!==void 0&&(d.fragment=String(d.fragment).replace(f.PCT_ENCODED,p).replace(f.NOT_FRAGMENT,tt).replace(f.PCT_ENCODED,s)),d}function As(d){return d.replace(/^0*(.*)/,"$1")||"0"}function Ts(d,f){var p=d.match(f.IPV4ADDRESS)||[],m=l(p,2),_=m[1];return _?_.split(".").map(As).join("."):d}function za(d,f){var p=d.match(f.IPV6ADDRESS)||[],m=l(p,3),_=m[1],S=m[2];if(_){for(var T=_.toLowerCase().split("::").reverse(),U=l(T,2),B=U[0],ce=U[1],F=ce?ce.split(":").map(As):[],ne=B.split(":").map(As),ue=f.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]=Ts(se[re-1],f));var jt=se.reduce(function(Me,st,kt){if(!st||st==="0"){var pt=Me[Me.length-1];pt&&pt.index+pt.length===kt?pt.length++:Me.push({index:kt,length:1})}return Me},[]),Ae=jt.sort(function(Me,st){return st.length-Me.length})[0],Le=void 0;if(Ae&&Ae.length>1){var Y=se.slice(0,Ae.index),Te=se.slice(Ae.index+Ae.length);Le=Y.join(":")+"::"+Te.join(":")}else Le=se.join(":");return S&&(Le+="%"+S),Le}else return d}var Ld=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?(\[[^\/?#\]]+\]|[^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n|\r)*))?/i,Md="".match(/(){0}/)[1]===void 0;function dt(d){var f=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},p={},m=f.iri!==!1?o:u;f.reference==="suffix"&&(d=(f.scheme?f.scheme+":":"")+"//"+d);var _=d.match(Ld);if(_){Md?(p.scheme=_[1],p.userinfo=_[3],p.host=_[4],p.port=parseInt(_[5],10),p.path=_[6]||"",p.query=_[7],p.fragment=_[8],isNaN(p.port)&&(p.port=_[5])):(p.scheme=_[1]||void 0,p.userinfo=d.indexOf("@")!==-1?_[3]:void 0,p.host=d.indexOf("//")!==-1?_[4]:void 0,p.port=parseInt(_[5],10),p.path=_[6]||"",p.query=d.indexOf("?")!==-1?_[7]:void 0,p.fragment=d.indexOf("#")!==-1?_[8]:void 0,isNaN(p.port)&&(p.port=d.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?_[4]:void 0)),p.host&&(p.host=za(Ts(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",f.reference&&f.reference!=="suffix"&&f.reference!==p.reference&&(p.error=p.error||"URI is not a "+f.reference+" reference.");var S=xe[(f.scheme||p.scheme||"").toLowerCase()];if(!f.unicodeSupport&&(!S||!S.unicodeSupport)){if(p.host&&(f.domainHost||S&&S.domainHost))try{p.host=Qt.toASCII(p.host.replace(m.PCT_ENCODED,er).toLowerCase())}catch(T){p.error=p.error||"Host's domain name can not be converted to ASCII via punycode: "+T}Is(p,u)}else Is(p,m);S&&S.parse&&S.parse(p,f)}else p.error=p.error||"URI can not be parsed.";return p}function Fd(d,f){var p=f.iri!==!1?o:u,m=[];return d.userinfo!==void 0&&(m.push(d.userinfo),m.push("@")),d.host!==void 0&&m.push(za(Ts(String(d.host),p),p).replace(p.IPV6ADDRESS,function(_,S,T){return"["+S+(T?"%25"+T:"")+"]"})),(typeof d.port=="number"||typeof d.port=="string")&&(m.push(":"),m.push(String(d.port))),m.length?m.join(""):void 0}var Ka=/^\.\.?\//,Xa=/^\/\.(\/|$)/,Ba=/^\/\.\.(\/|$)/,Vd=/^\/?(?:.|\n)*?(?=\/|$)/;function tr(d){for(var f=[];d.length;)if(d.match(Ka))d=d.replace(Ka,"");else if(d.match(Xa))d=d.replace(Xa,"/");else if(d.match(Ba))d=d.replace(Ba,"/"),f.pop();else if(d==="."||d==="..")d="";else{var p=d.match(Vd);if(p){var m=p[0];d=d.slice(m.length),f.push(m)}else throw new Error("Unexpected dot segment condition")}return f.join("")}function rt(d){var f=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},p=f.iri?o:u,m=[],_=xe[(f.scheme||d.scheme||"").toLowerCase()];if(_&&_.serialize&&_.serialize(d,f),d.host&&!p.IPV6ADDRESS.test(d.host)){if(f.domainHost||_&&_.domainHost)try{d.host=f.iri?Qt.toUnicode(d.host):Qt.toASCII(d.host.replace(p.PCT_ENCODED,er).toLowerCase())}catch(U){d.error=d.error||"Host's domain name can not be converted to "+(f.iri?"Unicode":"ASCII")+" via punycode: "+U}}Is(d,p),f.reference!=="suffix"&&d.scheme&&(m.push(d.scheme),m.push(":"));var S=Fd(d,f);if(S!==void 0&&(f.reference!=="suffix"&&m.push("//"),m.push(S),d.path&&d.path.charAt(0)!=="/"&&m.push("/")),d.path!==void 0){var T=d.path;!f.absolutePath&&(!_||!_.absolutePath)&&(T=tr(T)),S===void 0&&(T=T.replace(/^\/\//,"/%2F")),m.push(T)}return d.query!==void 0&&(m.push("?"),m.push(d.query)),d.fragment!==void 0&&(m.push("#"),m.push(d.fragment)),m.join("")}function Wa(d,f){var p=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},m=arguments[3],_={};return m||(d=dt(rt(d,p),p),f=dt(rt(f,p),p)),p=p||{},!p.tolerant&&f.scheme?(_.scheme=f.scheme,_.userinfo=f.userinfo,_.host=f.host,_.port=f.port,_.path=tr(f.path||""),_.query=f.query):(f.userinfo!==void 0||f.host!==void 0||f.port!==void 0?(_.userinfo=f.userinfo,_.host=f.host,_.port=f.port,_.path=tr(f.path||""),_.query=f.query):(f.path?(f.path.charAt(0)==="/"?_.path=tr(f.path):((d.userinfo!==void 0||d.host!==void 0||d.port!==void 0)&&!d.path?_.path="/"+f.path:d.path?_.path=d.path.slice(0,d.path.lastIndexOf("/")+1)+f.path:_.path=f.path,_.path=tr(_.path)),_.query=f.query):(_.path=d.path,f.query!==void 0?_.query=f.query:_.query=d.query),_.userinfo=d.userinfo,_.host=d.host,_.port=d.port),_.scheme=d.scheme),_.fragment=f.fragment,_}function Ud(d,f,p){var m=a({scheme:"null"},p);return rt(Wa(dt(d,m),dt(f,m),m,!0),m)}function Hd(d,f){return typeof d=="string"?d=rt(dt(d,f),f):n(d)==="object"&&(d=dt(rt(d,f),f)),d}function Gd(d,f,p){return typeof d=="string"?d=rt(dt(d,p),p):n(d)==="object"&&(d=rt(d,p)),typeof f=="string"?f=rt(dt(f,p),p):n(f)==="object"&&(f=rt(f,p)),d===f}function zd(d,f){return d&&d.toString().replace(!f||!f.iri?u.ESCAPE:o.ESCAPE,tt)}function ht(d,f){return d&&d.toString().replace(!f||!f.iri?u.PCT_ENCODED:o.PCT_ENCODED,er)}var qr={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 m=String(f.scheme).toLowerCase()==="https";return(f.port===(m?443:80)||f.port==="")&&(f.port=void 0),f.path||(f.path="/"),f}},Ja={scheme:"https",domainHost:qr.domainHost,parse:qr.parse,serialize:qr.serialize};function Ya(d){return typeof d.secure=="boolean"?d.secure:String(d.scheme).toLowerCase()==="wss"}var Dr={scheme:"ws",domainHost:!0,parse:function(f,p){var m=f;return m.secure=Ya(m),m.resourceName=(m.path||"/")+(m.query?"?"+m.query:""),m.path=void 0,m.query=void 0,m},serialize:function(f,p){if((f.port===(Ya(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 m=f.resourceName.split("?"),_=l(m,2),S=_[0],T=_[1];f.path=S&&S!=="/"?S:void 0,f.query=T,f.resourceName=void 0}return f.fragment=void 0,f}},Za={scheme:"wss",domainHost:Dr.domainHost,parse:Dr.parse,serialize:Dr.serialize},Kd={},Xd=!0,Qa="[A-Za-z0-9\\-\\.\\_\\~"+(Xd?"\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF":"")+"]",nt="[0-9A-Fa-f]",Bd=t(t("%[EFef]"+nt+"%"+nt+nt+"%"+nt+nt)+"|"+t("%[89A-Fa-f]"+nt+"%"+nt+nt)+"|"+t("%"+nt+nt)),Wd="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",Jd="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",Yd=e(Jd,'[\\"\\\\]'),Zd="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",Qd=new RegExp(Qa,"g"),rr=new RegExp(Bd,"g"),eh=new RegExp(e("[^]",Wd,"[\\.]",'[\\"]',Yd),"g"),eo=new RegExp(e("[^]",Qa,Zd),"g"),th=eo;function qs(d){var f=er(d);return f.match(Qd)?f:d}var to={scheme:"mailto",parse:function(f,p){var m=f,_=m.to=m.path?m.path.split(","):[];if(m.path=void 0,m.query){for(var S=!1,T={},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)_.push(ne[ue]);break;case"subject":m.subject=ht(F[1],p);break;case"body":m.body=ht(F[1],p);break;default:S=!0,T[ht(F[0],p)]=ht(F[1],p);break}}S&&(m.headers=T)}m.query=void 0;for(var K=0,se=_.length;K<se;++K){var W=_[K].split("@");if(W[0]=ht(W[0]),p.unicodeSupport)W[1]=ht(W[1],p).toLowerCase();else try{W[1]=Qt.toASCII(ht(W[1],p).toLowerCase())}catch(jt){m.error=m.error||"Email address's domain name can not be converted to ASCII via punycode: "+jt}_[K]=W.join("@")}return m},serialize:function(f,p){var m=f,_=i(f.to);if(_){for(var S=0,T=_.length;S<T;++S){var U=String(_[S]),B=U.lastIndexOf("@"),ce=U.slice(0,B).replace(rr,qs).replace(rr,s).replace(eh,tt),F=U.slice(B+1);try{F=p.iri?Qt.toUnicode(F):Qt.toASCII(ht(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}_[S]=ce+"@"+F}m.path=_.join(",")}var ne=f.headers=f.headers||{};f.subject&&(ne.subject=f.subject),f.body&&(ne.body=f.body);var ue=[];for(var re in ne)ne[re]!==Kd[re]&&ue.push(re.replace(rr,qs).replace(rr,s).replace(eo,tt)+"="+ne[re].replace(rr,qs).replace(rr,s).replace(th,tt));return ue.length&&(m.query=ue.join("&")),m}},rh=/^([^\:]+)\:(.*)/,ro={scheme:"urn",parse:function(f,p){var m=f.path&&f.path.match(rh),_=f;if(m){var S=p.scheme||_.scheme||"urn",T=m[1].toLowerCase(),U=m[2],B=S+":"+(p.nid||T),ce=xe[B];_.nid=T,_.nss=U,_.path=void 0,ce&&(_=ce.parse(_,p))}else _.error=_.error||"URN can not be parsed.";return _},serialize:function(f,p){var m=p.scheme||f.scheme||"urn",_=f.nid,S=m+":"+(p.nid||_),T=xe[S];T&&(f=T.serialize(f,p));var U=f,B=f.nss;return U.path=(_||p.nid)+":"+B,U}},nh=/^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/,no={scheme:"urn:uuid",parse:function(f,p){var m=f;return m.uuid=m.nss,m.nss=void 0,!p.tolerant&&(!m.uuid||!m.uuid.match(nh))&&(m.error=m.error||"UUID is not valid."),m},serialize:function(f,p){var m=f;return m.nss=(f.uuid||"").toLowerCase(),m}};xe[qr.scheme]=qr,xe[Ja.scheme]=Ja,xe[Dr.scheme]=Dr,xe[Za.scheme]=Za,xe[to.scheme]=to,xe[ro.scheme]=ro,xe[no.scheme]=no,r.SCHEMES=xe,r.pctEncChar=tt,r.pctDecChars=er,r.parse=dt,r.removeDotSegments=tr,r.serialize=rt,r.resolveComponents=Wa,r.resolve=Ud,r.normalize=Hd,r.equal=Gd,r.escapeComponent=zd,r.unescapeComponent=ht,Object.defineProperty(r,"__esModule",{value:!0})})});var ef=y(Gi=>{"use strict";Object.defineProperty(Gi,"__esModule",{value:!0});var Ql=Zl();Ql.code='require("ajv/dist/runtime/uri").default';Gi.default=Ql});var uf=y(pe=>{"use strict";Object.defineProperty(pe,"__esModule",{value:!0});pe.CodeGen=pe.Name=pe.nil=pe.stringify=pe.str=pe._=pe.KeywordCxt=void 0;var q_=mn();Object.defineProperty(pe,"KeywordCxt",{enumerable:!0,get:function(){return q_.KeywordCxt}});var $r=L();Object.defineProperty(pe,"_",{enumerable:!0,get:function(){return $r._}});Object.defineProperty(pe,"str",{enumerable:!0,get:function(){return $r.str}});Object.defineProperty(pe,"stringify",{enumerable:!0,get:function(){return $r.stringify}});Object.defineProperty(pe,"nil",{enumerable:!0,get:function(){return $r.nil}});Object.defineProperty(pe,"Name",{enumerable:!0,get:function(){return $r.Name}});Object.defineProperty(pe,"CodeGen",{enumerable:!0,get:function(){return $r.CodeGen}});var D_=Li(),af=Vi(),j_=bi(),vn=fs(),k_=L(),_n=dn(),hs=fn(),Ki=G(),tf=Jl(),x_=ef(),of=(r,e)=>new RegExp(r,e);of.code="new RegExp";var L_=["removeAdditional","useDefaults","coerceTypes"],M_=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),F_={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."},V_={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},rf=200;function U_(r){var e,t,n,s,i,a,c,u,o,l,h,g,v,$,E,w,b,D,A,z,C,ge,De,bt,je;let te=r.strict,ke=(e=r.code)===null||e===void 0?void 0:e.optimize,et=ke===!0||ke===void 0?1:ke||0,In=(n=(t=r.code)===null||t===void 0?void 0:t.regExp)!==null&&n!==void 0?n:of,An=(s=r.uriResolver)!==null&&s!==void 0?s:x_.default;return{strictSchema:(a=(i=r.strictSchema)!==null&&i!==void 0?i:te)!==null&&a!==void 0?a:!0,strictNumbers:(u=(c=r.strictNumbers)!==null&&c!==void 0?c:te)!==null&&u!==void 0?u:!0,strictTypes:(l=(o=r.strictTypes)!==null&&o!==void 0?o:te)!==null&&l!==void 0?l:"log",strictTuples:(g=(h=r.strictTuples)!==null&&h!==void 0?h:te)!==null&&g!==void 0?g:"log",strictRequired:($=(v=r.strictRequired)!==null&&v!==void 0?v:te)!==null&&$!==void 0?$:!1,code:r.code?Fe(ie({},r.code),{optimize:et,regExp:In}):{optimize:et,regExp:In},loopRequired:(E=r.loopRequired)!==null&&E!==void 0?E:rf,loopEnum:(w=r.loopEnum)!==null&&w!==void 0?w:rf,meta:(b=r.meta)!==null&&b!==void 0?b:!0,messages:(D=r.messages)!==null&&D!==void 0?D:!0,inlineRefs:(A=r.inlineRefs)!==null&&A!==void 0?A:!0,schemaId:(z=r.schemaId)!==null&&z!==void 0?z:"$id",addUsedSchema:(C=r.addUsedSchema)!==null&&C!==void 0?C:!0,validateSchema:(ge=r.validateSchema)!==null&&ge!==void 0?ge:!0,validateFormats:(De=r.validateFormats)!==null&&De!==void 0?De:!0,unicodeRegExp:(bt=r.unicodeRegExp)!==null&&bt!==void 0?bt:!0,int32range:(je=r.int32range)!==null&&je!==void 0?je:!0,uriResolver:An}}var ps=class{constructor(e={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,e=this.opts=ie(ie({},e),U_(e));let{es5:t,lines:n}=this.opts.code;this.scope=new k_.ValueScope({scope:{},prefixes:M_,es5:t,lines:n}),this.logger=B_(e.logger);let s=e.validateFormats;e.validateFormats=!1,this.RULES=(0,j_.getRules)(),nf.call(this,F_,e,"NOT SUPPORTED"),nf.call(this,V_,e,"DEPRECATED","warn"),this._metaOpts=K_.call(this),e.formats&&G_.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),e.keywords&&z_.call(this,e.keywords),typeof e.meta=="object"&&this.addMetaSchema(e.meta),H_.call(this),e.validateFormats=s}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){let{$data:e,meta:t,schemaId:n}=this.opts,s=tf;n==="id"&&(s=ie({},tf),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,h){await i.call(this,l.$schema);let g=this._addSchema(l,h);return g.validate||a.call(this,g)}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(h){if(!(h instanceof af.default))throw h;return c.call(this,h),await u.call(this,h.missingSchema),a.call(this,l)}}function c({missingSchema:l,missingRef:h}){if(this.refs[l])throw new Error(`AnySchema ${l} is loaded but ${h} cannot be resolved`)}async function u(l){let h=await o.call(this,l);this.refs[l]||await i.call(this,h.$schema),this.refs[l]||this.addSchema(h,l,t)}async function o(l){let h=this._loading[l];if(h)return h;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,_n.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=sf.call(this,e))=="string";)e=t;if(t===void 0){let{schemaId:n}=this.opts,s=new vn.SchemaEnv({schema:{},schemaId:n});if(t=vn.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=sf.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,_n.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(J_.call(this,n,t),!t)return(0,Ki.eachItem)(n,i=>zi.call(this,i)),this;Z_.call(this,t);let s=Fe(ie({},t),{type:(0,hs.getJSONTypes)(t.type),schemaType:(0,hs.getJSONTypes)(t.schemaType)});return(0,Ki.eachItem)(n,s.type.length===0?i=>zi.call(this,i,s):i=>s.type.forEach(a=>zi.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]=cf(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,_n.normalizeId)(a||n);let o=_n.getSchemaRefs.call(this,e,n);return u=new vn.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):vn.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{vn.compileSchema.call(this,e)}finally{this.opts=t}}};pe.default=ps;ps.ValidationError=D_.default;ps.MissingRefError=af.default;function nf(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 sf(r){return r=(0,_n.normalizeId)(r),this.schemas[r]||this.refs[r]}function H_(){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 G_(){for(let r in this.opts.formats){let e=this.opts.formats[r];e&&this.addFormat(r,e)}}function z_(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 K_(){let r=ie({},this.opts);for(let e of L_)delete r[e];return r}var X_={log(){},warn(){},error(){}};function B_(r){if(r===!1)return X_;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 W_=/^[a-z_$][a-z0-9_$:-]*$/i;function J_(r,e){let{RULES:t}=this;if((0,Ki.eachItem)(r,n=>{if(t.keywords[n])throw new Error(`Keyword ${n} is already defined`);if(!W_.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 zi(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:Fe(ie({},e),{type:(0,hs.getJSONTypes)(e.type),schemaType:(0,hs.getJSONTypes)(e.schemaType)})};e.before?Y_.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 Y_(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 Z_(r){let{metaSchema:e}=r;e!==void 0&&(r.$data&&this.opts.$data&&(e=cf(e)),r.validateSchema=this.compile(e,!0))}var Q_={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function cf(r){return{anyOf:[r,Q_]}}});var lf=y(Xi=>{"use strict";Object.defineProperty(Xi,"__esModule",{value:!0});var ey={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};Xi.default=ey});var pf=y(Wt=>{"use strict";Object.defineProperty(Wt,"__esModule",{value:!0});Wt.callRef=Wt.getValidate=void 0;var ty=Vi(),ff=Ge(),Ne=L(),Er=$t(),df=fs(),ms=G(),ry={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 h();let l=df.resolveRef.call(u,o,s,t);if(l===void 0)throw new ty.default(n.opts.uriResolver,s,t);if(l instanceof df.SchemaEnv)return g(l);return v(l);function h(){if(i===o)return gs(r,a,i,i.$async);let $=e.scopeValue("root",{ref:o});return gs(r,(0,Ne._)`${$}.validate`,o,o.$async)}function g($){let E=hf(r,$);gs(r,E,$,$.$async)}function v($){let E=e.scopeValue("schema",c.code.source===!0?{ref:$,code:(0,Ne.stringify)($)}:{ref:$}),w=e.name("valid"),b=r.subschema({schema:$,dataTypes:[],schemaPath:Ne.nil,topSchemaRef:E,errSchemaPath:t},w);r.mergeEvaluated(b),r.ok(w)}}};function hf(r,e){let{gen:t}=r;return e.validate?t.scopeValue("validate",{ref:e.validate}):(0,Ne._)`${t.scopeValue("wrapper",{ref:e})}.validate`}Wt.getValidate=hf;function gs(r,e,t,n){let{gen:s,it:i}=r,{allErrors:a,schemaEnv:c,opts:u}=i,o=u.passContext?Er.default.this:Ne.nil;n?l():h();function l(){if(!c.$async)throw new Error("async schema referenced by sync schema");let $=s.let("valid");s.try(()=>{s.code((0,Ne._)`await ${(0,ff.callValidateCode)(r,e,o)}`),v(e),a||s.assign($,!0)},E=>{s.if((0,Ne._)`!(${E} instanceof ${i.ValidationError})`,()=>s.throw(E)),g(E),a||s.assign($,!1)}),r.ok($)}function h(){r.result((0,ff.callValidateCode)(r,e,o),()=>v(e),()=>g(e))}function g($){let E=(0,Ne._)`${$}.errors`;s.assign(Er.default.vErrors,(0,Ne._)`${Er.default.vErrors} === null ? ${E} : ${Er.default.vErrors}.concat(${E})`),s.assign(Er.default.errors,(0,Ne._)`${Er.default.vErrors}.length`)}function v($){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=ms.mergeEvaluated.props(s,w.props,i.props));else{let b=s.var("props",(0,Ne._)`${$}.evaluated.props`);i.props=ms.mergeEvaluated.props(s,b,i.props,Ne.Name)}if(i.items!==!0)if(w&&!w.dynamicItems)w.items!==void 0&&(i.items=ms.mergeEvaluated.items(s,w.items,i.items));else{let b=s.var("items",(0,Ne._)`${$}.evaluated.items`);i.items=ms.mergeEvaluated.items(s,b,i.items,Ne.Name)}}}Wt.callRef=gs;Wt.default=ry});var mf=y(Bi=>{"use strict";Object.defineProperty(Bi,"__esModule",{value:!0});var ny=lf(),sy=pf(),iy=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",ny.default,sy.default];Bi.default=iy});var gf=y(Wi=>{"use strict";Object.defineProperty(Wi,"__esModule",{value:!0});var vs=L(),qt=vs.operators,_s={maximum:{okStr:"<=",ok:qt.LTE,fail:qt.GT},minimum:{okStr:">=",ok:qt.GTE,fail:qt.LT},exclusiveMaximum:{okStr:"<",ok:qt.LT,fail:qt.GTE},exclusiveMinimum:{okStr:">",ok:qt.GT,fail:qt.LTE}},ay={message:({keyword:r,schemaCode:e})=>(0,vs.str)`must be ${_s[r].okStr} ${e}`,params:({keyword:r,schemaCode:e})=>(0,vs._)`{comparison: ${_s[r].okStr}, limit: ${e}}`},oy={keyword:Object.keys(_s),type:"number",schemaType:"number",$data:!0,error:ay,code(r){let{keyword:e,data:t,schemaCode:n}=r;r.fail$data((0,vs._)`${t} ${_s[e].fail} ${n} || isNaN(${t})`)}};Wi.default=oy});var vf=y(Ji=>{"use strict";Object.defineProperty(Ji,"__esModule",{value:!0});var yn=L(),cy={message:({schemaCode:r})=>(0,yn.str)`must be multiple of ${r}`,params:({schemaCode:r})=>(0,yn._)`{multipleOf: ${r}}`},uy={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:cy,code(r){let{gen:e,data:t,schemaCode:n,it:s}=r,i=s.opts.multipleOfPrecision,a=e.let("res"),c=i?(0,yn._)`Math.abs(Math.round(${a}) - ${a}) > 1e-${i}`:(0,yn._)`${a} !== parseInt(${a})`;r.fail$data((0,yn._)`(${n} === 0 || (${a} = ${t}/${n}, ${c}))`)}};Ji.default=uy});var yf=y(Yi=>{"use strict";Object.defineProperty(Yi,"__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}Yi.default=_f;_f.code='require("ajv/dist/runtime/ucs2length").default'});var $f=y(Zi=>{"use strict";Object.defineProperty(Zi,"__esModule",{value:!0});var Jt=L(),ly=G(),fy=yf(),dy={message({keyword:r,schemaCode:e}){let t=r==="maxLength"?"more":"fewer";return(0,Jt.str)`must NOT have ${t} than ${e} characters`},params:({schemaCode:r})=>(0,Jt._)`{limit: ${r}}`},hy={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:dy,code(r){let{keyword:e,data:t,schemaCode:n,it:s}=r,i=e==="maxLength"?Jt.operators.GT:Jt.operators.LT,a=s.opts.unicode===!1?(0,Jt._)`${t}.length`:(0,Jt._)`${(0,ly.useFunc)(r.gen,fy.default)}(${t})`;r.fail$data((0,Jt._)`${a} ${i} ${n}`)}};Zi.default=hy});var Ef=y(Qi=>{"use strict";Object.defineProperty(Qi,"__esModule",{value:!0});var py=Ge(),ys=L(),my={message:({schemaCode:r})=>(0,ys.str)`must match pattern "${r}"`,params:({schemaCode:r})=>(0,ys._)`{pattern: ${r}}`},gy={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:my,code(r){let{data:e,$data:t,schema:n,schemaCode:s,it:i}=r,a=i.opts.unicodeRegExp?"u":"",c=t?(0,ys._)`(new RegExp(${s}, ${a}))`:(0,py.usePattern)(r,n);r.fail$data((0,ys._)`!${c}.test(${e})`)}};Qi.default=gy});var wf=y(ea=>{"use strict";Object.defineProperty(ea,"__esModule",{value:!0});var $n=L(),vy={message({keyword:r,schemaCode:e}){let t=r==="maxProperties"?"more":"fewer";return(0,$n.str)`must NOT have ${t} than ${e} items`},params:({schemaCode:r})=>(0,$n._)`{limit: ${r}}`},_y={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:vy,code(r){let{keyword:e,data:t,schemaCode:n}=r,s=e==="maxProperties"?$n.operators.GT:$n.operators.LT;r.fail$data((0,$n._)`Object.keys(${t}).length ${s} ${n}`)}};ea.default=_y});var bf=y(ta=>{"use strict";Object.defineProperty(ta,"__esModule",{value:!0});var En=Ge(),wn=L(),yy=G(),$y={message:({params:{missingProperty:r}})=>(0,wn.str)`must have required property '${r}'`,params:({params:{missingProperty:r}})=>(0,wn._)`{missingProperty: ${r}}`},Ey={keyword:"required",type:"object",schemaType:"array",$data:!0,error:$y,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 v=r.parentSchema.properties,{definedProperties:$}=r.it;for(let E of t)if((v==null?void 0:v[E])===void 0&&!$.has(E)){let w=a.schemaEnv.baseId+a.errSchemaPath,b=`required property "${E}" is not defined at "${w}" (strictRequired)`;(0,yy.checkStrictMode)(a,b,a.opts.strictRequired)}}function o(){if(u||i)r.block$data(wn.nil,h);else for(let v of t)(0,En.checkReportMissingProp)(r,v)}function l(){let v=e.let("missing");if(u||i){let $=e.let("valid",!0);r.block$data($,()=>g(v,$)),r.ok($)}else e.if((0,En.checkMissingProp)(r,t,v)),(0,En.reportMissingProp)(r,v),e.else()}function h(){e.forOf("prop",n,v=>{r.setParams({missingProperty:v}),e.if((0,En.noPropertyInData)(e,s,v,c.ownProperties),()=>r.error())})}function g(v,$){r.setParams({missingProperty:v}),e.forOf(v,n,()=>{e.assign($,(0,En.propertyInData)(e,s,v,c.ownProperties)),e.if((0,wn.not)($),()=>{r.error(),e.break()})},wn.nil)}}};ta.default=Ey});var Sf=y(ra=>{"use strict";Object.defineProperty(ra,"__esModule",{value:!0});var bn=L(),wy={message({keyword:r,schemaCode:e}){let t=r==="maxItems"?"more":"fewer";return(0,bn.str)`must NOT have ${t} than ${e} items`},params:({schemaCode:r})=>(0,bn._)`{limit: ${r}}`},by={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:wy,code(r){let{keyword:e,data:t,schemaCode:n}=r,s=e==="maxItems"?bn.operators.GT:bn.operators.LT;r.fail$data((0,bn._)`${t}.length ${s} ${n}`)}};ra.default=by});var $s=y(na=>{"use strict";Object.defineProperty(na,"__esModule",{value:!0});var Of=Ai();Of.code='require("ajv/dist/runtime/equal").default';na.default=Of});var Pf=y(ia=>{"use strict";Object.defineProperty(ia,"__esModule",{value:!0});var sa=fn(),me=L(),Sy=G(),Oy=$s(),Py={message:({params:{i:r,j:e}})=>(0,me.str)`must NOT have duplicate items (items ## ${e} and ${r} are identical)`,params:({params:{i:r,j:e}})=>(0,me._)`{i: ${r}, j: ${e}}`},Ry={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:Py,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,me._)`${a} === false`),r.ok(u);function l(){let $=e.let("i",(0,me._)`${t}.length`),E=e.let("j");r.setParams({i:$,j:E}),e.assign(u,!0),e.if((0,me._)`${$} > 1`,()=>(h()?g:v)($,E))}function h(){return o.length>0&&!o.some($=>$==="object"||$==="array")}function g($,E){let w=e.name("item"),b=(0,sa.checkDataTypes)(o,w,c.opts.strictNumbers,sa.DataType.Wrong),D=e.const("indices",(0,me._)`{}`);e.for((0,me._)`;${$}--;`,()=>{e.let(w,(0,me._)`${t}[${$}]`),e.if(b,(0,me._)`continue`),o.length>1&&e.if((0,me._)`typeof ${w} == "string"`,(0,me._)`${w} += "_"`),e.if((0,me._)`typeof ${D}[${w}] == "number"`,()=>{e.assign(E,(0,me._)`${D}[${w}]`),r.error(),e.assign(u,!1).break()}).code((0,me._)`${D}[${w}] = ${$}`)})}function v($,E){let w=(0,Sy.useFunc)(e,Oy.default),b=e.name("outer");e.label(b).for((0,me._)`;${$}--;`,()=>e.for((0,me._)`${E} = ${$}; ${E}--;`,()=>e.if((0,me._)`${w}(${t}[${$}], ${t}[${E}])`,()=>{r.error(),e.assign(u,!1).break(b)})))}}};ia.default=Ry});var Rf=y(oa=>{"use strict";Object.defineProperty(oa,"__esModule",{value:!0});var aa=L(),Cy=G(),Ny=$s(),Iy={message:"must be equal to constant",params:({schemaCode:r})=>(0,aa._)`{allowedValue: ${r}}`},Ay={keyword:"const",$data:!0,error:Iy,code(r){let{gen:e,data:t,$data:n,schemaCode:s,schema:i}=r;n||i&&typeof i=="object"?r.fail$data((0,aa._)`!${(0,Cy.useFunc)(e,Ny.default)}(${t}, ${s})`):r.fail((0,aa._)`${i} !== ${t}`)}};oa.default=Ay});var Cf=y(ca=>{"use strict";Object.defineProperty(ca,"__esModule",{value:!0});var Sn=L(),Ty=G(),qy=$s(),Dy={message:"must be equal to one of the allowed values",params:({schemaCode:r})=>(0,Sn._)`{allowedValues: ${r}}`},jy={keyword:"enum",schemaType:"array",$data:!0,error:Dy,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=(0,Ty.useFunc)(e,qy.default),o;if(c||n)o=e.let("valid"),r.block$data(o,l);else{if(!Array.isArray(s))throw new Error("ajv implementation error");let g=e.const("vSchema",i);o=(0,Sn.or)(...s.map((v,$)=>h(g,$)))}r.pass(o);function l(){e.assign(o,!1),e.forOf("v",i,g=>e.if((0,Sn._)`${u}(${t}, ${g})`,()=>e.assign(o,!0).break()))}function h(g,v){let $=s[v];return typeof $=="object"&&$!==null?(0,Sn._)`${u}(${t}, ${g}[${v}])`:(0,Sn._)`${t} === ${$}`}}};ca.default=jy});var Nf=y(ua=>{"use strict";Object.defineProperty(ua,"__esModule",{value:!0});var ky=gf(),xy=vf(),Ly=$f(),My=Ef(),Fy=wf(),Vy=bf(),Uy=Sf(),Hy=Pf(),Gy=Rf(),zy=Cf(),Ky=[ky.default,xy.default,Ly.default,My.default,Fy.default,Vy.default,Uy.default,Hy.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},Gy.default,zy.default];ua.default=Ky});var fa=y(On=>{"use strict";Object.defineProperty(On,"__esModule",{value:!0});On.validateAdditionalItems=void 0;var Yt=L(),la=G(),Xy={message:({params:{len:r}})=>(0,Yt.str)`must NOT have more than ${r} items`,params:({params:{len:r}})=>(0,Yt._)`{limit: ${r}}`},By={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:Xy,code(r){let{parentSchema:e,it:t}=r,{items:n}=e;if(!Array.isArray(n)){(0,la.checkStrictMode)(t,'"additionalItems" is ignored when "items" is not an array of schemas');return}If(r,n)}};function If(r,e){let{gen:t,schema:n,data:s,keyword:i,it:a}=r;a.items=!0;let c=t.const("len",(0,Yt._)`${s}.length`);if(n===!1)r.setParams({len:e.length}),r.pass((0,Yt._)`${c} <= ${e.length}`);else if(typeof n=="object"&&!(0,la.alwaysValidSchema)(a,n)){let o=t.var("valid",(0,Yt._)`${c} <= ${e.length}`);t.if((0,Yt.not)(o),()=>u(o)),r.ok(o)}function u(o){t.forRange("i",e.length,c,l=>{r.subschema({keyword:i,dataProp:l,dataPropType:la.Type.Num},o),a.allErrors||t.if((0,Yt.not)(o),()=>t.break())})}}On.validateAdditionalItems=If;On.default=By});var da=y(Pn=>{"use strict";Object.defineProperty(Pn,"__esModule",{value:!0});Pn.validateTuple=void 0;var Af=L(),Es=G(),Wy=Ge(),Jy={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(r){let{schema:e,it:t}=r;if(Array.isArray(e))return Tf(r,"additionalItems",e);t.items=!0,!(0,Es.alwaysValidSchema)(t,e)&&r.ok((0,Wy.validateArray)(r))}};function Tf(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=Es.mergeEvaluated.items(n,t.length,c.items));let u=n.name("valid"),o=n.const("len",(0,Af._)`${i}.length`);t.forEach((h,g)=>{(0,Es.alwaysValidSchema)(c,h)||(n.if((0,Af._)`${o} > ${g}`,()=>r.subschema({keyword:a,schemaProp:g,dataProp:g},u)),r.ok(u))});function l(h){let{opts:g,errSchemaPath:v}=c,$=t.length,E=$===h.minItems&&($===h.maxItems||h[e]===!1);if(g.strictTuples&&!E){let w=`"${a}" is ${$}-tuple, but minItems or maxItems/${e} are not specified or different at path "${v}"`;(0,Es.checkStrictMode)(c,w,g.strictTuples)}}}Pn.validateTuple=Tf;Pn.default=Jy});var qf=y(ha=>{"use strict";Object.defineProperty(ha,"__esModule",{value:!0});var Yy=da(),Zy={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:r=>(0,Yy.validateTuple)(r,"items")};ha.default=Zy});var jf=y(pa=>{"use strict";Object.defineProperty(pa,"__esModule",{value:!0});var Df=L(),Qy=G(),e0=Ge(),t0=fa(),r0={message:({params:{len:r}})=>(0,Df.str)`must NOT have more than ${r} items`,params:({params:{len:r}})=>(0,Df._)`{limit: ${r}}`},n0={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:r0,code(r){let{schema:e,parentSchema:t,it:n}=r,{prefixItems:s}=t;n.items=!0,!(0,Qy.alwaysValidSchema)(n,e)&&(s?(0,t0.validateAdditionalItems)(r,s):r.ok((0,e0.validateArray)(r)))}};pa.default=n0});var kf=y(ma=>{"use strict";Object.defineProperty(ma,"__esModule",{value:!0});var Ke=L(),ws=G(),s0={message:({params:{min:r,max:e}})=>e===void 0?(0,Ke.str)`must contain at least ${r} valid item(s)`:(0,Ke.str)`must contain at least ${r} and no more than ${e} valid item(s)`,params:({params:{min:r,max:e}})=>e===void 0?(0,Ke._)`{minContains: ${r}}`:(0,Ke._)`{minContains: ${r}, maxContains: ${e}}`},i0={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:s0,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,Ke._)`${s}.length`);if(r.setParams({min:a,max:c}),c===void 0&&a===0){(0,ws.checkStrictMode)(i,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(c!==void 0&&a>c){(0,ws.checkStrictMode)(i,'"minContains" > "maxContains" is always invalid'),r.fail();return}if((0,ws.alwaysValidSchema)(i,t)){let E=(0,Ke._)`${l} >= ${a}`;c!==void 0&&(E=(0,Ke._)`${E} && ${l} <= ${c}`),r.pass(E);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,Ke._)`${s}.length > 0`,g)):(e.let(h,!1),g()),r.result(h,()=>r.reset());function g(){let E=e.name("_valid"),w=e.let("count",0);v(E,()=>e.if(E,()=>$(w)))}function v(E,w){e.forRange("i",0,l,b=>{r.subschema({keyword:"contains",dataProp:b,dataPropType:ws.Type.Num,compositeRule:!0},E),w()})}function $(E){e.code((0,Ke._)`${E}++`),c===void 0?e.if((0,Ke._)`${E} >= ${a}`,()=>e.assign(h,!0).break()):(e.if((0,Ke._)`${E} > ${c}`,()=>e.assign(h,!1).break()),a===1?e.assign(h,!0):e.if((0,Ke._)`${E} >= ${a}`,()=>e.assign(h,!0)))}}};ma.default=i0});var Mf=y(ut=>{"use strict";Object.defineProperty(ut,"__esModule",{value:!0});ut.validateSchemaDeps=ut.validatePropertyDeps=ut.error=void 0;var ga=L(),a0=G(),Rn=Ge();ut.error={message:({params:{property:r,depsCount:e,deps:t}})=>{let n=e===1?"property":"properties";return(0,ga.str)`must have ${n} ${t} when property ${r} is present`},params:({params:{property:r,depsCount:e,deps:t,missingProperty:n}})=>(0,ga._)`{property: ${r},
25
+ || ${a} === "boolean" || ${s} === null`).assign(c,(0,q._)`[${s}]`)}}}function bv({gen:r,parentData:e,parentDataProperty:t},n){r.if((0,q._)`${e} !== undefined`,()=>r.assign((0,q._)`${e}[${t}]`,n))}function Pi(r,e,t,n=fn.Correct){let s=n===fn.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===fn.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)}}he.checkDataType=Pi;function Ri(r,e,t,n){if(r.length===1)return Pi(r[0],e,t,n);let s,i=(0,ml.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,Pi(a,e,t,n));return s}he.checkDataTypes=Ri;var Sv={message:({schema:r})=>`must be ${r}`,params:({schema:r,schemaValue:e})=>typeof r=="string"?(0,q._)`{type: ${r}}`:(0,q._)`{type: ${e}}`};function Ci(r){let e=Ov(r);(0,_v.reportError)(e,Sv)}he.reportTypeError=Ci;function Ov(r){let{gen:e,data:t,schema:n}=r,s=(0,ml.schemaRefOrVal)(r,n,"type");return{gen:e,keyword:"type",data:t,schema:n.type,schemaCode:s,schemaValue:s,parentSchema:n,params:{},it:r}}});var yl=y(os=>{"use strict";Object.defineProperty(os,"__esModule",{value:!0});os.assignDefaults=void 0;var Er=L(),Pv=G();function Rv(r,e){let{properties:t,items:n}=r.schema;if(e==="object"&&t)for(let s in t)_l(r,s,t[s].default);else e==="array"&&Array.isArray(n)&&n.forEach((s,i)=>_l(r,i,s.default))}os.assignDefaults=Rv;function _l(r,e,t){let{gen:n,compositeRule:s,data:i,opts:a}=r;if(t===void 0)return;let c=(0,Er._)`${i}${(0,Er.getProperty)(e)}`;if(s){(0,Pv.checkStrictMode)(r,`default is ignored for: ${c}`);return}let u=(0,Er._)`${c} === undefined`;a.useDefaults==="empty"&&(u=(0,Er._)`${u} || ${c} === null || ${c} === ""`),n.if(u,(0,Er._)`${c} = ${(0,Er.stringify)(t)}`)}});var ze=y(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 ee=L(),Ni=G(),It=$t(),Cv=G();function Nv(r,e){let{gen:t,data:n,it:s}=r;t.if(Ti(t,n,e,s.opts.ownProperties),()=>{r.setParams({missingProperty:(0,ee._)`${e}`},!0),r.error()})}J.checkReportMissingProp=Nv;function Iv({gen:r,data:e,it:{opts:t}},n,s){return(0,ee.or)(...n.map(i=>(0,ee.and)(Ti(r,e,i,t.ownProperties),(0,ee._)`${s} = ${i}`)))}J.checkMissingProp=Iv;function Tv(r,e){r.setParams({missingProperty:e},!0),r.error()}J.reportMissingProp=Tv;function $l(r){return r.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,ee._)`Object.prototype.hasOwnProperty`})}J.hasPropFunc=$l;function Ii(r,e,t){return(0,ee._)`${$l(r)}.call(${e}, ${t})`}J.isOwnProperty=Ii;function Av(r,e,t,n){let s=(0,ee._)`${e}${(0,ee.getProperty)(t)} !== undefined`;return n?(0,ee._)`${s} && ${Ii(r,e,t)}`:s}J.propertyInData=Av;function Ti(r,e,t,n){let s=(0,ee._)`${e}${(0,ee.getProperty)(t)} === undefined`;return n?(0,ee.or)(s,(0,ee.not)(Ii(r,e,t))):s}J.noPropertyInData=Ti;function El(r){return r?Object.keys(r).filter(e=>e!=="__proto__"):[]}J.allSchemaProperties=El;function qv(r,e){return El(e).filter(t=>!(0,Ni.alwaysValidSchema)(r,e[t]))}J.schemaProperties=qv;function Dv({schemaCode:r,data:e,it:{gen:t,topSchemaRef:n,schemaPath:s,errorPath:i},it:a},c,u,o){let l=o?(0,ee._)`${r}, ${e}, ${n}${s}`:e,h=[[It.default.instancePath,(0,ee.strConcat)(It.default.instancePath,i)],[It.default.parentData,a.parentData],[It.default.parentDataProperty,a.parentDataProperty],[It.default.rootData,It.default.rootData]];a.opts.dynamicRef&&h.push([It.default.dynamicAnchors,It.default.dynamicAnchors]);let g=(0,ee._)`${l}, ${t.object(...h)}`;return u!==ee.nil?(0,ee._)`${c}.call(${u}, ${g})`:(0,ee._)`${c}(${g})`}J.callValidateCode=Dv;var jv=(0,ee._)`new RegExp`;function kv({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,ee._)`${s.code==="new RegExp"?jv:(0,Cv.useFunc)(r,s)}(${t}, ${n})`})}J.usePattern=kv;function xv(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,ee._)`${t}.length`);e.forRange("i",0,u,o=>{r.subschema({keyword:n,dataProp:o,dataPropType:Ni.Type.Num},i),e.if((0,ee.not)(i),c)})}}J.validateArray=xv;function Lv(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,Ni.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,ee._)`${a} || ${c}`),r.mergeValidEvaluated(l,c)||e.if((0,ee.not)(a))})),r.result(a,()=>r.reset(),()=>r.error(!0))}J.validateUnion=Lv});var Sl=y(ot=>{"use strict";Object.defineProperty(ot,"__esModule",{value:!0});ot.validateKeywordUsage=ot.validSchemaType=ot.funcKeywordCode=ot.macroKeywordCode=void 0;var Pe=L(),Bt=$t(),Mv=ze(),Fv=ln();function Vv(r,e){let{gen:t,keyword:n,schema:s,parentSchema:i,it:a}=r,c=e.macro.call(a.self,s,i,a),u=bl(t,n,c);a.opts.validateSchema!==!1&&a.self.validateSchema(c,!0);let o=t.name("valid");r.subschema({schema:c,schemaPath:Pe.nil,errSchemaPath:`${a.errSchemaPath}/${n}`,topSchemaRef:u,compositeRule:!0},o),r.pass(o,()=>r.error(!0))}ot.macroKeywordCode=Vv;function Hv(r,e){var t;let{gen:n,keyword:s,schema:i,parentSchema:a,$data:c,it:u}=r;Gv(u,e);let o=!c&&e.compile?e.compile.call(u.self,i,a,u):e.validate,l=bl(n,s,o),h=n.let("valid");r.block$data(h,g),r.ok((t=e.valid)!==null&&t!==void 0?t:h);function g(){if(e.errors===!1)E(),e.modifying&&wl(r),w(()=>r.error());else{let b=e.async?v():$();e.modifying&&wl(r),w(()=>Uv(r,b))}}function v(){let b=n.let("ruleErrs",null);return n.try(()=>E((0,Pe._)`await `),D=>n.assign(h,!1).if((0,Pe._)`${D} instanceof ${u.ValidationError}`,()=>n.assign(b,(0,Pe._)`${D}.errors`),()=>n.throw(D))),b}function $(){let b=(0,Pe._)`${l}.errors`;return n.assign(b,null),E(Pe.nil),b}function E(b=e.async?(0,Pe._)`await `:Pe.nil){let D=u.opts.passContext?Bt.default.this:Bt.default.self,T=!("compile"in e&&!c||e.schema===!1);n.assign(h,(0,Pe._)`${b}${(0,Mv.callValidateCode)(r,l,D,T)}`,e.modifying)}function w(b){var D;n.if((0,Pe.not)((D=e.valid)!==null&&D!==void 0?D:h),b)}}ot.funcKeywordCode=Hv;function wl(r){let{gen:e,data:t,it:n}=r;e.if(n.parentData,()=>e.assign(t,(0,Pe._)`${n.parentData}[${n.parentDataProperty}]`))}function Uv(r,e){let{gen:t}=r;t.if((0,Pe._)`Array.isArray(${e})`,()=>{t.assign(Bt.default.vErrors,(0,Pe._)`${Bt.default.vErrors} === null ? ${e} : ${Bt.default.vErrors}.concat(${e})`).assign(Bt.default.errors,(0,Pe._)`${Bt.default.vErrors}.length`),(0,Fv.extendErrors)(r)},()=>r.error())}function Gv({schemaEnv:r},e){if(e.async&&!r.$async)throw new Error("async keyword in sync schema")}function bl(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,Pe.stringify)(t)})}function zv(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")}ot.validSchemaType=zv;function Kv({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)}}ot.validateKeywordUsage=Kv});var Pl=y(Tt=>{"use strict";Object.defineProperty(Tt,"__esModule",{value:!0});Tt.extendSubschemaMode=Tt.extendSubschemaData=Tt.getSubschema=void 0;var ct=L(),Ol=G();function Xv(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,ct._)`${r.schemaPath}${(0,ct.getProperty)(e)}`,errSchemaPath:`${r.errSchemaPath}/${e}`}:{schema:c[t],schemaPath:(0,ct._)`${r.schemaPath}${(0,ct.getProperty)(e)}${(0,ct.getProperty)(t)}`,errSchemaPath:`${r.errSchemaPath}/${e}/${(0,Ol.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')}Tt.getSubschema=Xv;function Bv(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:h}=e,g=c.let("data",(0,ct._)`${e.data}${(0,ct.getProperty)(t)}`,!0);u(g),r.errorPath=(0,ct.str)`${o}${(0,Ol.getErrorPath)(t,n,h.jsPropertySyntax)}`,r.parentDataProperty=(0,ct._)`${t}`,r.dataPathArr=[...l,r.parentDataProperty]}if(s!==void 0){let o=s instanceof ct.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]}}Tt.extendSubschemaData=Bv;function Wv(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}Tt.extendSubschemaMode=Wv});var Ai=y((Yw,Rl)=>{"use strict";Rl.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 Nl=y((Zw,Cl)=>{"use strict";var At=Cl.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(){};cs(e,n,s,r,"",r)};At.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};At.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};At.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};At.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 cs(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 h=n[l];if(Array.isArray(h)){if(l in At.arrayKeywords)for(var g=0;g<h.length;g++)cs(r,e,t,h[g],s+"/"+l+"/"+g,i,s,l,n,g)}else if(l in At.propsKeywords){if(h&&typeof h=="object")for(var v in h)cs(r,e,t,h[v],s+"/"+l+"/"+Jv(v),i,s,l,n,v)}else(l in At.keywords||r.allKeys&&!(l in At.skipKeywords))&&cs(r,e,t,h,s+"/"+l,i,s,l,n)}t(n,s,i,a,c,u,o)}}function Jv(r){return r.replace(/~/g,"~0").replace(/\//g,"~1")}});var hn=y(Ne=>{"use strict";Object.defineProperty(Ne,"__esModule",{value:!0});Ne.getSchemaRefs=Ne.resolveUrl=Ne.normalizeId=Ne._getFullPath=Ne.getFullPath=Ne.inlineRef=void 0;var Yv=G(),Zv=Ai(),Qv=Nl(),e_=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function t_(r,e=!0){return typeof r=="boolean"?!0:e===!0?!qi(r):e?Il(r)<=e:!1}Ne.inlineRef=t_;var r_=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function qi(r){for(let e in r){if(r_.has(e))return!0;let t=r[e];if(Array.isArray(t)&&t.some(qi)||typeof t=="object"&&qi(t))return!0}return!1}function Il(r){let e=0;for(let t in r){if(t==="$ref")return 1/0;if(e++,!e_.has(t)&&(typeof r[t]=="object"&&(0,Yv.eachItem)(r[t],n=>e+=Il(n)),e===1/0))return 1/0}return e}function Tl(r,e="",t){t!==!1&&(e=wr(e));let n=r.parse(e);return Al(r,n)}Ne.getFullPath=Tl;function Al(r,e){return r.serialize(e).split("#")[0]+"#"}Ne._getFullPath=Al;var n_=/#\/?$/;function wr(r){return r?r.replace(n_,""):""}Ne.normalizeId=wr;function s_(r,e,t){return t=wr(t),r.resolve(e,t)}Ne.resolveUrl=s_;var i_=/^[a-z_][-a-z0-9._]*$/i;function a_(r,e){if(typeof r=="boolean")return{};let{schemaId:t,uriResolver:n}=this.opts,s=wr(r[t]||e),i={"":s},a=Tl(n,s,!1),c={},u=new Set;return Qv(r,{allKeys:!0},(h,g,v,$)=>{if($===void 0)return;let E=a+g,w=i[$];typeof h[t]=="string"&&(w=b.call(this,h[t])),D.call(this,h.$anchor),D.call(this,h.$dynamicAnchor),i[g]=w;function b(T){let z=this.opts.uriResolver.resolve;if(T=wr(w?z(w,T):T),u.has(T))throw l(T);u.add(T);let N=this.refs[T];return typeof N=="string"&&(N=this.refs[N]),typeof N=="object"?o(h,N.schema,T):T!==wr(E)&&(T[0]==="#"?(o(h,c[T],T),c[T]=h):this.refs[T]=E),T}function D(T){if(typeof T=="string"){if(!i_.test(T))throw new Error(`invalid anchor "${T}"`);b.call(this,`#${T}`)}}}),c;function o(h,g,v){if(g!==void 0&&!Zv(h,g))throw l(v)}function l(h){return new Error(`reference "${h}" resolves to more than one schema`)}}Ne.getSchemaRefs=a_});var gn=y(qt=>{"use strict";Object.defineProperty(qt,"__esModule",{value:!0});qt.getData=qt.KeywordCxt=qt.validateFunctionCode=void 0;var Ll=dl(),ql=dn(),ji=Oi(),us=dn(),o_=yl(),mn=Sl(),Di=Pl(),R=L(),I=$t(),c_=hn(),Et=G(),pn=ln();function u_(r){if(Vl(r)&&(Hl(r),Fl(r))){d_(r);return}Ml(r,()=>(0,Ll.topBoolOrEmptySchema)(r))}qt.validateFunctionCode=u_;function Ml({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"; ${Dl(t,s)}`),f_(r,s),r.code(i)}):r.func(e,(0,R._)`${I.default.data}, ${l_(s)}`,n.$async,()=>r.code(Dl(t,s)).code(i))}function l_(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 f_(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 d_(r){let{schema:e,opts:t,gen:n}=r;Ml(r,()=>{t.$comment&&e.$comment&&Gl(r),v_(r),n.let(I.default.vErrors,null),n.let(I.default.errors,0),t.unevaluated&&h_(r),Ul(r),$_(r)})}function h_(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 Dl(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 p_(r,e){if(Vl(r)&&(Hl(r),Fl(r))){m_(r,e);return}(0,Ll.boolOrEmptySchema)(r,e)}function Fl({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 Vl(r){return typeof r.schema!="boolean"}function m_(r,e){let{schema:t,gen:n,opts:s}=r;s.$comment&&t.$comment&&Gl(r),__(r),y_(r);let i=n.const("_errs",I.default.errors);Ul(r,i),n.var(e,(0,R._)`${i} === ${I.default.errors}`)}function Hl(r){(0,Et.checkUnknownRules)(r),g_(r)}function Ul(r,e){if(r.opts.jtd)return jl(r,[],!1,e);let t=(0,ql.getSchemaTypes)(r.schema),n=(0,ql.coerceAndCheckDataType)(r,t);jl(r,t,!n,e)}function g_(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 v_(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 __(r){let e=r.schema[r.opts.schemaId];e&&(r.baseId=(0,c_.resolveUrl)(r.opts.uriResolver,r.baseId,e))}function y_(r){if(r.schema.$async&&!r.schemaEnv.$async)throw new Error("async schema in sync schema")}function Gl({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 $_(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&&E_(r),e.return((0,R._)`${I.default.errors} === 0`))}function E_({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 jl(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(()=>zl(r,"$ref",l.all.$ref.definition));return}u.jtd||w_(r,e),s.block(()=>{for(let g of l.rules)h(g);h(l.post)});function h(g){!(0,ji.shouldUseGroup)(i,g)||(g.type?(s.if((0,us.checkDataType)(g.type,a,u.strictNumbers)),kl(r,g),e.length===1&&e[0]===g.type&&t&&(s.else(),(0,us.reportTypeError)(r)),s.endIf()):kl(r,g),c||s.if((0,R._)`${I.default.errors} === ${n||0}`))}}function kl(r,e){let{gen:t,schema:n,opts:{useDefaults:s}}=r;s&&(0,o_.assignDefaults)(r,e.type),t.block(()=>{for(let i of e.rules)(0,ji.shouldUseRule)(n,i)&&zl(r,i.keyword,i.definition,e.type)})}function w_(r,e){r.schemaEnv.meta||!r.opts.strictTypes||(b_(r,e),r.opts.allowUnionTypes||S_(r,e),O_(r,r.dataTypes))}function b_(r,e){if(!!e.length){if(!r.dataTypes.length){r.dataTypes=e;return}e.forEach(t=>{xl(r.dataTypes,t)||ki(r,`type "${t}" not allowed by context "${r.dataTypes.join(",")}"`)}),r.dataTypes=r.dataTypes.filter(t=>xl(e,t))}}function S_(r,e){e.length>1&&!(e.length===2&&e.includes("null"))&&ki(r,"use allowUnionTypes to allow union type keyword")}function O_(r,e){let t=r.self.RULES.all;for(let n in t){let s=t[n];if(typeof s=="object"&&(0,ji.shouldUseRule)(r.schema,s)){let{type:i}=s.definition;i.length&&!i.some(a=>P_(e,a))&&ki(r,`missing type "${i.join(",")}" for keyword "${n}"`)}}}function P_(r,e){return r.includes(e)||e==="number"&&r.includes("integer")}function xl(r,e){return r.includes(e)||e==="integer"&&r.includes("number")}function ki(r,e){e+=` at "${r.schemaEnv.baseId+r.errSchemaPath}" (strictTypes)`,(0,Et.checkStrictMode)(r,e,r.opts.strictTypes)}var xi=class{constructor(e,t,n){if((0,mn.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",Kl(this.$data,e));else if(this.schemaCode=this.schemaValue,!(0,mn.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?pn.reportExtraError:pn.reportError)(this,this.def.error,t)}$dataError(){(0,pn.reportError)(this,this.def.$dataError||pn.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,pn.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,us.checkDataTypes)(u,t,i.opts.strictNumbers,us.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,Di.getSubschema)(this.it,e);(0,Di.extendSubschemaData)(n,this.it,e),(0,Di.extendSubschemaMode)(n,e);let s=Ve(ie(ie({},this.it),n),{items:void 0,props:void 0});return p_(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}};qt.KeywordCxt=xi;function zl(r,e,t,n){let s=new xi(r,t,e);"code"in t?t.code(s,n):s.$data&&t.validate?(0,mn.funcKeywordCode)(s,t):"macro"in t?(0,mn.macroKeywordCode)(s,t):(t.compile||t.validate)&&(0,mn.funcKeywordCode)(s,t)}var R_=/^\/(?:[^~]|~0|~1)*$/,C_=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function Kl(r,{dataLevel:e,dataNames:t,dataPathArr:n}){let s,i;if(r==="")return I.default.rootData;if(r[0]==="/"){if(!R_.test(r))throw new Error(`Invalid JSON-pointer: ${r}`);s=r,i=I.default.rootData}else{let o=C_.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}`}}qt.getData=Kl});var Mi=y(Li=>{"use strict";Object.defineProperty(Li,"__esModule",{value:!0});var Xl=class extends Error{constructor(e){super("validation failed");this.errors=e,this.ajv=this.validation=!0}};Li.default=Xl});var Hi=y(Vi=>{"use strict";Object.defineProperty(Vi,"__esModule",{value:!0});var Fi=hn(),Bl=class extends Error{constructor(e,t,n,s){super(s||`can't resolve reference ${n} from id ${t}`);this.missingRef=(0,Fi.resolveUrl)(e,t,n),this.missingSchema=(0,Fi.normalizeId)((0,Fi.getFullPath)(e,this.missingRef))}};Vi.default=Bl});var fs=y(Ke=>{"use strict";Object.defineProperty(Ke,"__esModule",{value:!0});Ke.resolveSchema=Ke.getCompilingSchema=Ke.resolveRef=Ke.compileSchema=Ke.SchemaEnv=void 0;var Ye=L(),N_=Mi(),Wt=$t(),Ze=hn(),Wl=G(),I_=gn(),vn=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=vn;function Gi(r){let e=Jl.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:N_.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:Wt.default.data,parentData:Wt.default.parentData,parentDataProperty:Wt.default.parentDataProperty,dataNames:[Wt.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,I_.validateFunctionCode)(o),a.optimize(this.opts.code.optimize);let h=a.toString();l=`${a.scopeRefs(Wt.default.scope)}return ${h}`,this.opts.code.process&&(l=this.opts.code.process(l,r));let v=new Function(`${Wt.default.self}`,`${Wt.default.scope}`,l)(this,this.scope.get());if(this.scope.value(u,{ref:v}),v.errors=null,v.schema=r.schema,v.schemaEnv=r,r.$async&&(v.$async=!0),this.opts.code.source===!0&&(v.source={validateName:u,validateCode:h,scopeValues:a._values}),this.opts.unevaluated){let{props:$,items:E}=o;v.evaluated={props:$ instanceof Ye.Name?void 0:$,items:E instanceof Ye.Name?void 0:E,dynamicProps:$ instanceof Ye.Name,dynamicItems:E instanceof Ye.Name},v.source&&(v.source.evaluated=(0,Ye.stringify)(v.evaluated))}return r.validate=v,r}catch(h){throw delete r.validate,delete r.validateName,l&&this.logger.error("Error compiling schema, function code:",l),h}finally{this._compilations.delete(r)}}Ke.compileSchema=Gi;function T_(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=D_.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 vn({schema:a,schemaId:c,root:r,baseId:e}))}if(i!==void 0)return r.refs[t]=A_.call(this,i)}Ke.resolveRef=T_;function A_(r){return(0,Ze.inlineRef)(r.schema,this.opts.inlineRefs)?r.schema:r.validate?r:Gi.call(this,r)}function Jl(r){for(let e of this._compilations)if(q_(e,r))return e}Ke.getCompilingSchema=Jl;function q_(r,e){return r.schema===e.schema&&r.root===e.root&&r.baseId===e.baseId}function D_(r,e){let t;for(;typeof(t=this.refs[e])=="string";)e=t;return t||this.schemas[e]||ls.call(this,r,e)}function ls(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 Ui.call(this,t,r);let i=(0,Ze.normalizeId)(n),a=this.refs[i]||this.schemas[i];if(typeof a=="string"){let c=ls.call(this,r,a);return typeof(c==null?void 0:c.schema)!="object"?void 0:Ui.call(this,t,c)}if(typeof(a==null?void 0:a.schema)=="object"){if(a.validate||Gi.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 vn({schema:c,schemaId:u,root:r,baseId:s})}return Ui.call(this,t,a)}}Ke.resolveSchema=ls;var j_=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function Ui(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,Wl.unescapeFragment)(c)];if(u===void 0)return;t=u;let o=typeof t=="object"&&t[this.opts.schemaId];!j_.has(c)&&o&&(e=(0,Ze.resolveUrl)(this.opts.uriResolver,e,o))}let i;if(typeof t!="boolean"&&t.$ref&&!(0,Wl.schemaHasRulesButRef)(t,this.RULES)){let c=(0,Ze.resolveUrl)(this.opts.uriResolver,e,t.$ref);i=ls.call(this,n,c)}let{schemaId:a}=this.opts;if(i=i||new vn({schema:t,schemaId:a,root:n,baseId:e}),i.schema!==i.root.schema)return i}});var Yl=y((sb,k_)=>{k_.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 Ql=y((ds,Zl)=>{(function(r,e){typeof ds=="object"&&typeof Zl<"u"?e(ds):typeof define=="function"&&define.amd?define(["exports"],e):e(r.URI=r.URI||{})})(ds,function(r){"use strict";function e(){for(var d=arguments.length,f=Array(d),p=0;p<d;p++)f[p]=arguments[p];if(f.length>1){f[0]=f[0].slice(0,-1);for(var m=f.length-1,_=1;_<m;++_)f[_]=f[_].slice(1,-1);return f[m]=f[m].slice(1),f.join("")}else return f[0]}function t(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,f){var p=d;if(f)for(var m in f)p[m]=f[m];return p}function c(d){var f="[A-Za-z]",p="[\\x0D]",m="[0-9]",_="[\\x22]",S=e(m,"[A-Fa-f]"),A="[\\x0A]",H="[\\x20]",B=t(t("%[EFef]"+S+"%"+S+S+"%"+S+S)+"|"+t("%[89A-Fa-f]"+S+"%"+S+S)+"|"+t("%"+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(f,m,"[\\-\\.\\_\\~]",ue),se=t(f+e(f,m,"[\\+\\-\\.]")+"*"),W=t(t(B+"|"+e(K,F,"[\\:]"))+"*"),kt=t(t("25[0-5]")+"|"+t("2[0-4]"+m)+"|"+t("1"+m+m)+"|"+t("[1-9]"+m)+"|"+m),Ae=t(t("25[0-5]")+"|"+t("2[0-4]"+m)+"|"+t("1"+m+m)+"|"+t("0?[1-9]"+m)+"|0?0?"+m),Me=t(Ae+"\\."+Ae+"\\."+Ae+"\\."+Ae),Y=t(S+"{1,4}"),qe=t(t(Y+"\\:"+Y)+"|"+Me),Fe=t(t(Y+"\\:")+"{6}"+qe),st=t("\\:\\:"+t(Y+"\\:")+"{5}"+qe),xt=t(t(Y)+"?\\:\\:"+t(Y+"\\:")+"{4}"+qe),pt=t(t(t(Y+"\\:")+"{0,1}"+Y)+"?\\:\\:"+t(Y+"\\:")+"{3}"+qe),Lr=t(t(t(Y+"\\:")+"{0,2}"+Y)+"?\\:\\:"+t(Y+"\\:")+"{2}"+qe),qn=t(t(t(Y+"\\:")+"{0,3}"+Y)+"?\\:\\:"+Y+"\\:"+qe),Dn=t(t(t(Y+"\\:")+"{0,4}"+Y)+"?\\:\\:"+qe),sr=t(t(t(Y+"\\:")+"{0,5}"+Y)+"?\\:\\:"+Y),ir=t(t(t(Y+"\\:")+"{0,6}"+Y)+"?\\:\\:"),mt=t([Fe,st,xt,pt,Lr,qn,Dn,sr,ir].join("|")),ar=t(t(K+"|"+B)+"+"),Ds=t(mt+"\\%25"+ar),Lt=t(mt+t("\\%25|\\%(?!"+S+"{2})")+ar),ih=t("[vV]"+S+"+\\."+e(K,F,"[\\:]")+"+"),ah=t("\\["+t(Lt+"|"+mt+"|"+ih)+"\\]"),io=t(t(B+"|"+e(K,F))+"*"),Mr=t(ah+"|"+Me+"(?!"+io+")|"+io),Fr=t(m+"*"),ao=t(t(W+"@")+"?"+Mr+t("\\:"+Fr)+"?"),Vr=t(B+"|"+e(K,F,"[\\:\\@]")),oh=t(Vr+"*"),oo=t(Vr+"+"),ch=t(t(B+"|"+e(K,F,"[\\@]"))+"+"),gt=t(t("\\/"+oh)+"*"),or=t("\\/"+t(oo+gt)+"?"),js=t(ch+gt),jn=t(oo+gt),cr="(?!"+Vr+")",RE=t(gt+"|"+or+"|"+js+"|"+jn+"|"+cr),ur=t(t(Vr+"|"+e("[\\/\\?]",re))+"*"),Hr=t(t(Vr+"|[\\/\\?]")+"*"),co=t(t("\\/\\/"+ao+gt)+"|"+or+"|"+jn+"|"+cr),uh=t(se+"\\:"+co+t("\\?"+ur)+"?"+t("\\#"+Hr)+"?"),lh=t(t("\\/\\/"+ao+gt)+"|"+or+"|"+js+"|"+cr),fh=t(lh+t("\\?"+ur)+"?"+t("\\#"+Hr)+"?"),CE=t(uh+"|"+fh),NE=t(se+"\\:"+co+t("\\?"+ur)+"?"),IE="^("+se+")\\:"+t(t("\\/\\/("+t("("+W+")@")+"?("+Mr+")"+t("\\:("+Fr+")")+"?)")+"?("+gt+"|"+or+"|"+jn+"|"+cr+")")+t("\\?("+ur+")")+"?"+t("\\#("+Hr+")")+"?$",TE="^(){0}"+t(t("\\/\\/("+t("("+W+")@")+"?("+Mr+")"+t("\\:("+Fr+")")+"?)")+"?("+gt+"|"+or+"|"+js+"|"+cr+")")+t("\\?("+ur+")")+"?"+t("\\#("+Hr+")")+"?$",AE="^("+se+")\\:"+t(t("\\/\\/("+t("("+W+")@")+"?("+Mr+")"+t("\\:("+Fr+")")+"?)")+"?("+gt+"|"+or+"|"+jn+"|"+cr+")")+t("\\?("+ur+")")+"?$",qE="^"+t("\\#("+Hr+")")+"?$",DE="^"+t("("+W+")@")+"?("+Mr+")"+t("\\:("+Fr+")")+"?$";return{NOT_SCHEME:new RegExp(e("[^]",f,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("^\\[?("+mt+")"+t(t("\\%25|\\%(?!"+S+"{2})")+"("+ar+")")+"?\\]?$")}}var u=c(!1),o=c(!0),l=function(){function d(f,p){var m=[],_=!0,S=!1,A=void 0;try{for(var H=f[Symbol.iterator](),B;!(_=(B=H.next()).done)&&(m.push(B.value),!(p&&m.length===p));_=!0);}catch(ce){S=!0,A=ce}finally{try{!_&&H.return&&H.return()}finally{if(S)throw A}}return m}return function(f,p){if(Array.isArray(f))return f;if(Symbol.iterator in Object(f))return d(f,p);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),h=function(d){if(Array.isArray(d)){for(var f=0,p=Array(d.length);f<d.length;f++)p[f]=d[f];return p}else return Array.from(d)},g=2147483647,v=36,$=1,E=26,w=38,b=700,D=72,T=128,z="-",N=/^xn--/,ge=/[^\0-\x7E]/,je=/[\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"},ke=v-$,te=Math.floor,xe=String.fromCharCode;function et(d){throw new RangeError(bt[d])}function Tn(d,f){for(var p=[],m=d.length;m--;)p[m]=f(d[m]);return p}function An(d,f){var p=d.split("@"),m="";p.length>1&&(m=p[0]+"@",d=p[1]),d=d.replace(je,".");var _=d.split("."),S=Tn(_,f).join(".");return m+S}function Va(d){for(var f=[],p=0,m=d.length;p<m;){var _=d.charCodeAt(p++);if(_>=55296&&_<=56319&&p<m){var S=d.charCodeAt(p++);(S&64512)==56320?f.push(((_&1023)<<10)+(S&1023)+65536):(f.push(_),p--)}else f.push(_)}return f}var jd=function(f){return String.fromCodePoint.apply(String,h(f))},kd=function(f){return f-48<10?f-22:f-65<26?f-65:f-97<26?f-97:v},Ha=function(f,p){return f+22+75*(f<26)-((p!=0)<<5)},Ua=function(f,p,m){var _=0;for(f=m?te(f/b):f>>1,f+=te(f/p);f>ke*E>>1;_+=v)f=te(f/ke);return te(_+(ke+1)*f/(f+w))},Ga=function(f){var p=[],m=f.length,_=0,S=T,A=D,H=f.lastIndexOf(z);H<0&&(H=0);for(var B=0;B<H;++B)f.charCodeAt(B)>=128&&et("not-basic"),p.push(f.charCodeAt(B));for(var ce=H>0?H+1:0;ce<m;){for(var F=_,ne=1,ue=v;;ue+=v){ce>=m&&et("invalid-input");var re=kd(f.charCodeAt(ce++));(re>=v||re>te((g-_)/ne))&&et("overflow"),_+=re*ne;var K=ue<=A?$:ue>=A+E?E:ue-A;if(re<K)break;var se=v-K;ne>te(g/se)&&et("overflow"),ne*=se}var W=p.length+1;A=Ua(_-F,W,F==0),te(_/W)>g-S&&et("overflow"),S+=te(_/W),_%=W,p.splice(_++,0,S)}return String.fromCodePoint.apply(String,p)},za=function(f){var p=[];f=Va(f);var m=f.length,_=T,S=0,A=D,H=!0,B=!1,ce=void 0;try{for(var F=f[Symbol.iterator](),ne;!(H=(ne=F.next()).done);H=!0){var ue=ne.value;ue<128&&p.push(xe(ue))}}catch(Lt){B=!0,ce=Lt}finally{try{!H&&F.return&&F.return()}finally{if(B)throw ce}}var re=p.length,K=re;for(re&&p.push(z);K<m;){var se=g,W=!0,kt=!1,Ae=void 0;try{for(var Me=f[Symbol.iterator](),Y;!(W=(Y=Me.next()).done);W=!0){var qe=Y.value;qe>=_&&qe<se&&(se=qe)}}catch(Lt){kt=!0,Ae=Lt}finally{try{!W&&Me.return&&Me.return()}finally{if(kt)throw Ae}}var Fe=K+1;se-_>te((g-S)/Fe)&&et("overflow"),S+=(se-_)*Fe,_=se;var st=!0,xt=!1,pt=void 0;try{for(var Lr=f[Symbol.iterator](),qn;!(st=(qn=Lr.next()).done);st=!0){var Dn=qn.value;if(Dn<_&&++S>g&&et("overflow"),Dn==_){for(var sr=S,ir=v;;ir+=v){var mt=ir<=A?$:ir>=A+E?E:ir-A;if(sr<mt)break;var ar=sr-mt,Ds=v-mt;p.push(xe(Ha(mt+ar%Ds,0))),sr=te(ar/Ds)}p.push(xe(Ha(sr,0))),A=Ua(S,Fe,K==re),S=0,++K}}}catch(Lt){xt=!0,pt=Lt}finally{try{!st&&Lr.return&&Lr.return()}finally{if(xt)throw pt}}++S,++_}return p.join("")},xd=function(f){return An(f,function(p){return N.test(p)?Ga(p.slice(4).toLowerCase()):p})},Ld=function(f){return An(f,function(p){return ge.test(p)?"xn--"+za(p):p})},er={version:"2.1.0",ucs2:{decode:Va,encode:jd},decode:Ga,encode:za,toASCII:Ld,toUnicode:xd},Le={};function tt(d){var f=d.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 tr(d){for(var f="",p=0,m=d.length;p<m;){var _=parseInt(d.substr(p+1,2),16);if(_<128)f+=String.fromCharCode(_),p+=3;else if(_>=194&&_<224){if(m-p>=6){var S=parseInt(d.substr(p+4,2),16);f+=String.fromCharCode((_&31)<<6|S&63)}else f+=d.substr(p,6);p+=6}else if(_>=224){if(m-p>=9){var A=parseInt(d.substr(p+4,2),16),H=parseInt(d.substr(p+7,2),16);f+=String.fromCharCode((_&15)<<12|(A&63)<<6|H&63)}else f+=d.substr(p,9);p+=9}else f+=d.substr(p,3),p+=3}return f}function Is(d,f){function p(m){var _=tr(m);return _.match(f.UNRESERVED)?_:m}return d.scheme&&(d.scheme=String(d.scheme).replace(f.PCT_ENCODED,p).toLowerCase().replace(f.NOT_SCHEME,"")),d.userinfo!==void 0&&(d.userinfo=String(d.userinfo).replace(f.PCT_ENCODED,p).replace(f.NOT_USERINFO,tt).replace(f.PCT_ENCODED,s)),d.host!==void 0&&(d.host=String(d.host).replace(f.PCT_ENCODED,p).toLowerCase().replace(f.NOT_HOST,tt).replace(f.PCT_ENCODED,s)),d.path!==void 0&&(d.path=String(d.path).replace(f.PCT_ENCODED,p).replace(d.scheme?f.NOT_PATH:f.NOT_PATH_NOSCHEME,tt).replace(f.PCT_ENCODED,s)),d.query!==void 0&&(d.query=String(d.query).replace(f.PCT_ENCODED,p).replace(f.NOT_QUERY,tt).replace(f.PCT_ENCODED,s)),d.fragment!==void 0&&(d.fragment=String(d.fragment).replace(f.PCT_ENCODED,p).replace(f.NOT_FRAGMENT,tt).replace(f.PCT_ENCODED,s)),d}function Ts(d){return d.replace(/^0*(.*)/,"$1")||"0"}function As(d,f){var p=d.match(f.IPV4ADDRESS)||[],m=l(p,2),_=m[1];return _?_.split(".").map(Ts).join("."):d}function Ka(d,f){var p=d.match(f.IPV6ADDRESS)||[],m=l(p,3),_=m[1],S=m[2];if(_){for(var A=_.toLowerCase().split("::").reverse(),H=l(A,2),B=H[0],ce=H[1],F=ce?ce.split(":").map(Ts):[],ne=B.split(":").map(Ts),ue=f.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]=As(se[re-1],f));var kt=se.reduce(function(Fe,st,xt){if(!st||st==="0"){var pt=Fe[Fe.length-1];pt&&pt.index+pt.length===xt?pt.length++:Fe.push({index:xt,length:1})}return Fe},[]),Ae=kt.sort(function(Fe,st){return st.length-Fe.length})[0],Me=void 0;if(Ae&&Ae.length>1){var Y=se.slice(0,Ae.index),qe=se.slice(Ae.index+Ae.length);Me=Y.join(":")+"::"+qe.join(":")}else Me=se.join(":");return S&&(Me+="%"+S),Me}else return d}var Md=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?(\[[^\/?#\]]+\]|[^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n|\r)*))?/i,Fd="".match(/(){0}/)[1]===void 0;function dt(d){var f=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},p={},m=f.iri!==!1?o:u;f.reference==="suffix"&&(d=(f.scheme?f.scheme+":":"")+"//"+d);var _=d.match(Md);if(_){Fd?(p.scheme=_[1],p.userinfo=_[3],p.host=_[4],p.port=parseInt(_[5],10),p.path=_[6]||"",p.query=_[7],p.fragment=_[8],isNaN(p.port)&&(p.port=_[5])):(p.scheme=_[1]||void 0,p.userinfo=d.indexOf("@")!==-1?_[3]:void 0,p.host=d.indexOf("//")!==-1?_[4]:void 0,p.port=parseInt(_[5],10),p.path=_[6]||"",p.query=d.indexOf("?")!==-1?_[7]:void 0,p.fragment=d.indexOf("#")!==-1?_[8]:void 0,isNaN(p.port)&&(p.port=d.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?_[4]:void 0)),p.host&&(p.host=Ka(As(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",f.reference&&f.reference!=="suffix"&&f.reference!==p.reference&&(p.error=p.error||"URI is not a "+f.reference+" reference.");var S=Le[(f.scheme||p.scheme||"").toLowerCase()];if(!f.unicodeSupport&&(!S||!S.unicodeSupport)){if(p.host&&(f.domainHost||S&&S.domainHost))try{p.host=er.toASCII(p.host.replace(m.PCT_ENCODED,tr).toLowerCase())}catch(A){p.error=p.error||"Host's domain name can not be converted to ASCII via punycode: "+A}Is(p,u)}else Is(p,m);S&&S.parse&&S.parse(p,f)}else p.error=p.error||"URI can not be parsed.";return p}function Vd(d,f){var p=f.iri!==!1?o:u,m=[];return d.userinfo!==void 0&&(m.push(d.userinfo),m.push("@")),d.host!==void 0&&m.push(Ka(As(String(d.host),p),p).replace(p.IPV6ADDRESS,function(_,S,A){return"["+S+(A?"%25"+A:"")+"]"})),(typeof d.port=="number"||typeof d.port=="string")&&(m.push(":"),m.push(String(d.port))),m.length?m.join(""):void 0}var Xa=/^\.\.?\//,Ba=/^\/\.(\/|$)/,Wa=/^\/\.\.(\/|$)/,Hd=/^\/?(?:.|\n)*?(?=\/|$)/;function rr(d){for(var f=[];d.length;)if(d.match(Xa))d=d.replace(Xa,"");else if(d.match(Ba))d=d.replace(Ba,"/");else if(d.match(Wa))d=d.replace(Wa,"/"),f.pop();else if(d==="."||d==="..")d="";else{var p=d.match(Hd);if(p){var m=p[0];d=d.slice(m.length),f.push(m)}else throw new Error("Unexpected dot segment condition")}return f.join("")}function rt(d){var f=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},p=f.iri?o:u,m=[],_=Le[(f.scheme||d.scheme||"").toLowerCase()];if(_&&_.serialize&&_.serialize(d,f),d.host&&!p.IPV6ADDRESS.test(d.host)){if(f.domainHost||_&&_.domainHost)try{d.host=f.iri?er.toUnicode(d.host):er.toASCII(d.host.replace(p.PCT_ENCODED,tr).toLowerCase())}catch(H){d.error=d.error||"Host's domain name can not be converted to "+(f.iri?"Unicode":"ASCII")+" via punycode: "+H}}Is(d,p),f.reference!=="suffix"&&d.scheme&&(m.push(d.scheme),m.push(":"));var S=Vd(d,f);if(S!==void 0&&(f.reference!=="suffix"&&m.push("//"),m.push(S),d.path&&d.path.charAt(0)!=="/"&&m.push("/")),d.path!==void 0){var A=d.path;!f.absolutePath&&(!_||!_.absolutePath)&&(A=rr(A)),S===void 0&&(A=A.replace(/^\/\//,"/%2F")),m.push(A)}return d.query!==void 0&&(m.push("?"),m.push(d.query)),d.fragment!==void 0&&(m.push("#"),m.push(d.fragment)),m.join("")}function Ja(d,f){var p=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},m=arguments[3],_={};return m||(d=dt(rt(d,p),p),f=dt(rt(f,p),p)),p=p||{},!p.tolerant&&f.scheme?(_.scheme=f.scheme,_.userinfo=f.userinfo,_.host=f.host,_.port=f.port,_.path=rr(f.path||""),_.query=f.query):(f.userinfo!==void 0||f.host!==void 0||f.port!==void 0?(_.userinfo=f.userinfo,_.host=f.host,_.port=f.port,_.path=rr(f.path||""),_.query=f.query):(f.path?(f.path.charAt(0)==="/"?_.path=rr(f.path):((d.userinfo!==void 0||d.host!==void 0||d.port!==void 0)&&!d.path?_.path="/"+f.path:d.path?_.path=d.path.slice(0,d.path.lastIndexOf("/")+1)+f.path:_.path=f.path,_.path=rr(_.path)),_.query=f.query):(_.path=d.path,f.query!==void 0?_.query=f.query:_.query=d.query),_.userinfo=d.userinfo,_.host=d.host,_.port=d.port),_.scheme=d.scheme),_.fragment=f.fragment,_}function Ud(d,f,p){var m=a({scheme:"null"},p);return rt(Ja(dt(d,m),dt(f,m),m,!0),m)}function Gd(d,f){return typeof d=="string"?d=rt(dt(d,f),f):n(d)==="object"&&(d=dt(rt(d,f),f)),d}function zd(d,f,p){return typeof d=="string"?d=rt(dt(d,p),p):n(d)==="object"&&(d=rt(d,p)),typeof f=="string"?f=rt(dt(f,p),p):n(f)==="object"&&(f=rt(f,p)),d===f}function Kd(d,f){return d&&d.toString().replace(!f||!f.iri?u.ESCAPE:o.ESCAPE,tt)}function ht(d,f){return d&&d.toString().replace(!f||!f.iri?u.PCT_ENCODED:o.PCT_ENCODED,tr)}var kr={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 m=String(f.scheme).toLowerCase()==="https";return(f.port===(m?443:80)||f.port==="")&&(f.port=void 0),f.path||(f.path="/"),f}},Ya={scheme:"https",domainHost:kr.domainHost,parse:kr.parse,serialize:kr.serialize};function Za(d){return typeof d.secure=="boolean"?d.secure:String(d.scheme).toLowerCase()==="wss"}var xr={scheme:"ws",domainHost:!0,parse:function(f,p){var m=f;return m.secure=Za(m),m.resourceName=(m.path||"/")+(m.query?"?"+m.query:""),m.path=void 0,m.query=void 0,m},serialize:function(f,p){if((f.port===(Za(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 m=f.resourceName.split("?"),_=l(m,2),S=_[0],A=_[1];f.path=S&&S!=="/"?S:void 0,f.query=A,f.resourceName=void 0}return f.fragment=void 0,f}},Qa={scheme:"wss",domainHost:xr.domainHost,parse:xr.parse,serialize:xr.serialize},Xd={},Bd=!0,eo="[A-Za-z0-9\\-\\.\\_\\~"+(Bd?"\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF":"")+"]",nt="[0-9A-Fa-f]",Wd=t(t("%[EFef]"+nt+"%"+nt+nt+"%"+nt+nt)+"|"+t("%[89A-Fa-f]"+nt+"%"+nt+nt)+"|"+t("%"+nt+nt)),Jd="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",Yd="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",Zd=e(Yd,'[\\"\\\\]'),Qd="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",eh=new RegExp(eo,"g"),nr=new RegExp(Wd,"g"),th=new RegExp(e("[^]",Jd,"[\\.]",'[\\"]',Zd),"g"),to=new RegExp(e("[^]",eo,Qd),"g"),rh=to;function qs(d){var f=tr(d);return f.match(eh)?f:d}var ro={scheme:"mailto",parse:function(f,p){var m=f,_=m.to=m.path?m.path.split(","):[];if(m.path=void 0,m.query){for(var S=!1,A={},H=m.query.split("&"),B=0,ce=H.length;B<ce;++B){var F=H[B].split("=");switch(F[0]){case"to":for(var ne=F[1].split(","),ue=0,re=ne.length;ue<re;++ue)_.push(ne[ue]);break;case"subject":m.subject=ht(F[1],p);break;case"body":m.body=ht(F[1],p);break;default:S=!0,A[ht(F[0],p)]=ht(F[1],p);break}}S&&(m.headers=A)}m.query=void 0;for(var K=0,se=_.length;K<se;++K){var W=_[K].split("@");if(W[0]=ht(W[0]),p.unicodeSupport)W[1]=ht(W[1],p).toLowerCase();else try{W[1]=er.toASCII(ht(W[1],p).toLowerCase())}catch(kt){m.error=m.error||"Email address's domain name can not be converted to ASCII via punycode: "+kt}_[K]=W.join("@")}return m},serialize:function(f,p){var m=f,_=i(f.to);if(_){for(var S=0,A=_.length;S<A;++S){var H=String(_[S]),B=H.lastIndexOf("@"),ce=H.slice(0,B).replace(nr,qs).replace(nr,s).replace(th,tt),F=H.slice(B+1);try{F=p.iri?er.toUnicode(F):er.toASCII(ht(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}_[S]=ce+"@"+F}m.path=_.join(",")}var ne=f.headers=f.headers||{};f.subject&&(ne.subject=f.subject),f.body&&(ne.body=f.body);var ue=[];for(var re in ne)ne[re]!==Xd[re]&&ue.push(re.replace(nr,qs).replace(nr,s).replace(to,tt)+"="+ne[re].replace(nr,qs).replace(nr,s).replace(rh,tt));return ue.length&&(m.query=ue.join("&")),m}},nh=/^([^\:]+)\:(.*)/,no={scheme:"urn",parse:function(f,p){var m=f.path&&f.path.match(nh),_=f;if(m){var S=p.scheme||_.scheme||"urn",A=m[1].toLowerCase(),H=m[2],B=S+":"+(p.nid||A),ce=Le[B];_.nid=A,_.nss=H,_.path=void 0,ce&&(_=ce.parse(_,p))}else _.error=_.error||"URN can not be parsed.";return _},serialize:function(f,p){var m=p.scheme||f.scheme||"urn",_=f.nid,S=m+":"+(p.nid||_),A=Le[S];A&&(f=A.serialize(f,p));var H=f,B=f.nss;return H.path=(_||p.nid)+":"+B,H}},sh=/^[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 m=f;return m.uuid=m.nss,m.nss=void 0,!p.tolerant&&(!m.uuid||!m.uuid.match(sh))&&(m.error=m.error||"UUID is not valid."),m},serialize:function(f,p){var m=f;return m.nss=(f.uuid||"").toLowerCase(),m}};Le[kr.scheme]=kr,Le[Ya.scheme]=Ya,Le[xr.scheme]=xr,Le[Qa.scheme]=Qa,Le[ro.scheme]=ro,Le[no.scheme]=no,Le[so.scheme]=so,r.SCHEMES=Le,r.pctEncChar=tt,r.pctDecChars=tr,r.parse=dt,r.removeDotSegments=rr,r.serialize=rt,r.resolveComponents=Ja,r.resolve=Ud,r.normalize=Gd,r.equal=zd,r.escapeComponent=Kd,r.unescapeComponent=ht,Object.defineProperty(r,"__esModule",{value:!0})})});var tf=y(zi=>{"use strict";Object.defineProperty(zi,"__esModule",{value:!0});var ef=Ql();ef.code='require("ajv/dist/runtime/uri").default';zi.default=ef});var lf=y(pe=>{"use strict";Object.defineProperty(pe,"__esModule",{value:!0});pe.CodeGen=pe.Name=pe.nil=pe.stringify=pe.str=pe._=pe.KeywordCxt=void 0;var x_=gn();Object.defineProperty(pe,"KeywordCxt",{enumerable:!0,get:function(){return x_.KeywordCxt}});var br=L();Object.defineProperty(pe,"_",{enumerable:!0,get:function(){return br._}});Object.defineProperty(pe,"str",{enumerable:!0,get:function(){return br.str}});Object.defineProperty(pe,"stringify",{enumerable:!0,get:function(){return br.stringify}});Object.defineProperty(pe,"nil",{enumerable:!0,get:function(){return br.nil}});Object.defineProperty(pe,"Name",{enumerable:!0,get:function(){return br.Name}});Object.defineProperty(pe,"CodeGen",{enumerable:!0,get:function(){return br.CodeGen}});var L_=Mi(),of=Hi(),M_=Si(),_n=fs(),F_=L(),yn=hn(),hs=dn(),Xi=G(),rf=Yl(),V_=tf(),cf=(r,e)=>new RegExp(r,e);cf.code="new RegExp";var H_=["removeAdditional","useDefaults","coerceTypes"],U_=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),G_={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."},z_={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},nf=200;function K_(r){var e,t,n,s,i,a,c,u,o,l,h,g,v,$,E,w,b,D,T,z,N,ge,je,bt,ke;let te=r.strict,xe=(e=r.code)===null||e===void 0?void 0:e.optimize,et=xe===!0||xe===void 0?1:xe||0,Tn=(n=(t=r.code)===null||t===void 0?void 0:t.regExp)!==null&&n!==void 0?n:cf,An=(s=r.uriResolver)!==null&&s!==void 0?s:V_.default;return{strictSchema:(a=(i=r.strictSchema)!==null&&i!==void 0?i:te)!==null&&a!==void 0?a:!0,strictNumbers:(u=(c=r.strictNumbers)!==null&&c!==void 0?c:te)!==null&&u!==void 0?u:!0,strictTypes:(l=(o=r.strictTypes)!==null&&o!==void 0?o:te)!==null&&l!==void 0?l:"log",strictTuples:(g=(h=r.strictTuples)!==null&&h!==void 0?h:te)!==null&&g!==void 0?g:"log",strictRequired:($=(v=r.strictRequired)!==null&&v!==void 0?v:te)!==null&&$!==void 0?$:!1,code:r.code?Ve(ie({},r.code),{optimize:et,regExp:Tn}):{optimize:et,regExp:Tn},loopRequired:(E=r.loopRequired)!==null&&E!==void 0?E:nf,loopEnum:(w=r.loopEnum)!==null&&w!==void 0?w:nf,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:(N=r.addUsedSchema)!==null&&N!==void 0?N:!0,validateSchema:(ge=r.validateSchema)!==null&&ge!==void 0?ge:!0,validateFormats:(je=r.validateFormats)!==null&&je!==void 0?je:!0,unicodeRegExp:(bt=r.unicodeRegExp)!==null&&bt!==void 0?bt:!0,int32range:(ke=r.int32range)!==null&&ke!==void 0?ke:!0,uriResolver:An}}var ps=class{constructor(e={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,e=this.opts=ie(ie({},e),K_(e));let{es5:t,lines:n}=this.opts.code;this.scope=new F_.ValueScope({scope:{},prefixes:U_,es5:t,lines:n}),this.logger=Z_(e.logger);let s=e.validateFormats;e.validateFormats=!1,this.RULES=(0,M_.getRules)(),sf.call(this,G_,e,"NOT SUPPORTED"),sf.call(this,z_,e,"DEPRECATED","warn"),this._metaOpts=J_.call(this),e.formats&&B_.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),e.keywords&&W_.call(this,e.keywords),typeof e.meta=="object"&&this.addMetaSchema(e.meta),X_.call(this),e.validateFormats=s}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){let{$data:e,meta:t,schemaId:n}=this.opts,s=rf;n==="id"&&(s=ie({},rf),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,h){await i.call(this,l.$schema);let g=this._addSchema(l,h);return g.validate||a.call(this,g)}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(h){if(!(h instanceof of.default))throw h;return c.call(this,h),await u.call(this,h.missingSchema),a.call(this,l)}}function c({missingSchema:l,missingRef:h}){if(this.refs[l])throw new Error(`AnySchema ${l} is loaded but ${h} cannot be resolved`)}async function u(l){let h=await o.call(this,l);this.refs[l]||await i.call(this,h.$schema),this.refs[l]||this.addSchema(h,l,t)}async function o(l){let h=this._loading[l];if(h)return h;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,yn.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=af.call(this,e))=="string";)e=t;if(t===void 0){let{schemaId:n}=this.opts,s=new _n.SchemaEnv({schema:{},schemaId:n});if(t=_n.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=af.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,yn.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(ey.call(this,n,t),!t)return(0,Xi.eachItem)(n,i=>Ki.call(this,i)),this;ry.call(this,t);let s=Ve(ie({},t),{type:(0,hs.getJSONTypes)(t.type),schemaType:(0,hs.getJSONTypes)(t.schemaType)});return(0,Xi.eachItem)(n,s.type.length===0?i=>Ki.call(this,i,s):i=>s.type.forEach(a=>Ki.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]=uf(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,yn.normalizeId)(a||n);let o=yn.getSchemaRefs.call(this,e,n);return u=new _n.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):_n.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{_n.compileSchema.call(this,e)}finally{this.opts=t}}};pe.default=ps;ps.ValidationError=L_.default;ps.MissingRefError=of.default;function sf(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 af(r){return r=(0,yn.normalizeId)(r),this.schemas[r]||this.refs[r]}function X_(){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 B_(){for(let r in this.opts.formats){let e=this.opts.formats[r];e&&this.addFormat(r,e)}}function W_(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 J_(){let r=ie({},this.opts);for(let e of H_)delete r[e];return r}var Y_={log(){},warn(){},error(){}};function Z_(r){if(r===!1)return Y_;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 Q_=/^[a-z_$][a-z0-9_$:-]*$/i;function ey(r,e){let{RULES:t}=this;if((0,Xi.eachItem)(r,n=>{if(t.keywords[n])throw new Error(`Keyword ${n} is already defined`);if(!Q_.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 Ki(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:Ve(ie({},e),{type:(0,hs.getJSONTypes)(e.type),schemaType:(0,hs.getJSONTypes)(e.schemaType)})};e.before?ty.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 ty(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 ry(r){let{metaSchema:e}=r;e!==void 0&&(r.$data&&this.opts.$data&&(e=uf(e)),r.validateSchema=this.compile(e,!0))}var ny={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function uf(r){return{anyOf:[r,ny]}}});var ff=y(Bi=>{"use strict";Object.defineProperty(Bi,"__esModule",{value:!0});var sy={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};Bi.default=sy});var mf=y(Jt=>{"use strict";Object.defineProperty(Jt,"__esModule",{value:!0});Jt.callRef=Jt.getValidate=void 0;var iy=Hi(),df=ze(),Ie=L(),Sr=$t(),hf=fs(),ms=G(),ay={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 h();let l=hf.resolveRef.call(u,o,s,t);if(l===void 0)throw new iy.default(n.opts.uriResolver,s,t);if(l instanceof hf.SchemaEnv)return g(l);return v(l);function h(){if(i===o)return gs(r,a,i,i.$async);let $=e.scopeValue("root",{ref:o});return gs(r,(0,Ie._)`${$}.validate`,o,o.$async)}function g($){let E=pf(r,$);gs(r,E,$,$.$async)}function v($){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 pf(r,e){let{gen:t}=r;return e.validate?t.scopeValue("validate",{ref:e.validate}):(0,Ie._)`${t.scopeValue("wrapper",{ref:e})}.validate`}Jt.getValidate=pf;function gs(r,e,t,n){let{gen:s,it:i}=r,{allErrors:a,schemaEnv:c,opts:u}=i,o=u.passContext?Sr.default.this:Ie.nil;n?l():h();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,df.callValidateCode)(r,e,o)}`),v(e),a||s.assign($,!0)},E=>{s.if((0,Ie._)`!(${E} instanceof ${i.ValidationError})`,()=>s.throw(E)),g(E),a||s.assign($,!1)}),r.ok($)}function h(){r.result((0,df.callValidateCode)(r,e,o),()=>v(e),()=>g(e))}function g($){let E=(0,Ie._)`${$}.errors`;s.assign(Sr.default.vErrors,(0,Ie._)`${Sr.default.vErrors} === null ? ${E} : ${Sr.default.vErrors}.concat(${E})`),s.assign(Sr.default.errors,(0,Ie._)`${Sr.default.vErrors}.length`)}function v($){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=ms.mergeEvaluated.props(s,w.props,i.props));else{let b=s.var("props",(0,Ie._)`${$}.evaluated.props`);i.props=ms.mergeEvaluated.props(s,b,i.props,Ie.Name)}if(i.items!==!0)if(w&&!w.dynamicItems)w.items!==void 0&&(i.items=ms.mergeEvaluated.items(s,w.items,i.items));else{let b=s.var("items",(0,Ie._)`${$}.evaluated.items`);i.items=ms.mergeEvaluated.items(s,b,i.items,Ie.Name)}}}Jt.callRef=gs;Jt.default=ay});var gf=y(Wi=>{"use strict";Object.defineProperty(Wi,"__esModule",{value:!0});var oy=ff(),cy=mf(),uy=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",oy.default,cy.default];Wi.default=uy});var vf=y(Ji=>{"use strict";Object.defineProperty(Ji,"__esModule",{value:!0});var vs=L(),Dt=vs.operators,_s={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}},ly={message:({keyword:r,schemaCode:e})=>(0,vs.str)`must be ${_s[r].okStr} ${e}`,params:({keyword:r,schemaCode:e})=>(0,vs._)`{comparison: ${_s[r].okStr}, limit: ${e}}`},fy={keyword:Object.keys(_s),type:"number",schemaType:"number",$data:!0,error:ly,code(r){let{keyword:e,data:t,schemaCode:n}=r;r.fail$data((0,vs._)`${t} ${_s[e].fail} ${n} || isNaN(${t})`)}};Ji.default=fy});var _f=y(Yi=>{"use strict";Object.defineProperty(Yi,"__esModule",{value:!0});var $n=L(),dy={message:({schemaCode:r})=>(0,$n.str)`must be multiple of ${r}`,params:({schemaCode:r})=>(0,$n._)`{multipleOf: ${r}}`},hy={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:dy,code(r){let{gen:e,data:t,schemaCode:n,it:s}=r,i=s.opts.multipleOfPrecision,a=e.let("res"),c=i?(0,$n._)`Math.abs(Math.round(${a}) - ${a}) > 1e-${i}`:(0,$n._)`${a} !== parseInt(${a})`;r.fail$data((0,$n._)`(${n} === 0 || (${a} = ${t}/${n}, ${c}))`)}};Yi.default=hy});var $f=y(Zi=>{"use strict";Object.defineProperty(Zi,"__esModule",{value:!0});function yf(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}Zi.default=yf;yf.code='require("ajv/dist/runtime/ucs2length").default'});var Ef=y(Qi=>{"use strict";Object.defineProperty(Qi,"__esModule",{value:!0});var Yt=L(),py=G(),my=$f(),gy={message({keyword:r,schemaCode:e}){let t=r==="maxLength"?"more":"fewer";return(0,Yt.str)`must NOT have ${t} than ${e} characters`},params:({schemaCode:r})=>(0,Yt._)`{limit: ${r}}`},vy={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:gy,code(r){let{keyword:e,data:t,schemaCode:n,it:s}=r,i=e==="maxLength"?Yt.operators.GT:Yt.operators.LT,a=s.opts.unicode===!1?(0,Yt._)`${t}.length`:(0,Yt._)`${(0,py.useFunc)(r.gen,my.default)}(${t})`;r.fail$data((0,Yt._)`${a} ${i} ${n}`)}};Qi.default=vy});var wf=y(ea=>{"use strict";Object.defineProperty(ea,"__esModule",{value:!0});var _y=ze(),ys=L(),yy={message:({schemaCode:r})=>(0,ys.str)`must match pattern "${r}"`,params:({schemaCode:r})=>(0,ys._)`{pattern: ${r}}`},$y={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:yy,code(r){let{data:e,$data:t,schema:n,schemaCode:s,it:i}=r,a=i.opts.unicodeRegExp?"u":"",c=t?(0,ys._)`(new RegExp(${s}, ${a}))`:(0,_y.usePattern)(r,n);r.fail$data((0,ys._)`!${c}.test(${e})`)}};ea.default=$y});var bf=y(ta=>{"use strict";Object.defineProperty(ta,"__esModule",{value:!0});var En=L(),Ey={message({keyword:r,schemaCode:e}){let t=r==="maxProperties"?"more":"fewer";return(0,En.str)`must NOT have ${t} than ${e} items`},params:({schemaCode:r})=>(0,En._)`{limit: ${r}}`},wy={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:Ey,code(r){let{keyword:e,data:t,schemaCode:n}=r,s=e==="maxProperties"?En.operators.GT:En.operators.LT;r.fail$data((0,En._)`Object.keys(${t}).length ${s} ${n}`)}};ta.default=wy});var Sf=y(ra=>{"use strict";Object.defineProperty(ra,"__esModule",{value:!0});var wn=ze(),bn=L(),by=G(),Sy={message:({params:{missingProperty:r}})=>(0,bn.str)`must have required property '${r}'`,params:({params:{missingProperty:r}})=>(0,bn._)`{missingProperty: ${r}}`},Oy={keyword:"required",type:"object",schemaType:"array",$data:!0,error:Sy,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 v=r.parentSchema.properties,{definedProperties:$}=r.it;for(let E of t)if((v==null?void 0:v[E])===void 0&&!$.has(E)){let w=a.schemaEnv.baseId+a.errSchemaPath,b=`required property "${E}" is not defined at "${w}" (strictRequired)`;(0,by.checkStrictMode)(a,b,a.opts.strictRequired)}}function o(){if(u||i)r.block$data(bn.nil,h);else for(let v of t)(0,wn.checkReportMissingProp)(r,v)}function l(){let v=e.let("missing");if(u||i){let $=e.let("valid",!0);r.block$data($,()=>g(v,$)),r.ok($)}else e.if((0,wn.checkMissingProp)(r,t,v)),(0,wn.reportMissingProp)(r,v),e.else()}function h(){e.forOf("prop",n,v=>{r.setParams({missingProperty:v}),e.if((0,wn.noPropertyInData)(e,s,v,c.ownProperties),()=>r.error())})}function g(v,$){r.setParams({missingProperty:v}),e.forOf(v,n,()=>{e.assign($,(0,wn.propertyInData)(e,s,v,c.ownProperties)),e.if((0,bn.not)($),()=>{r.error(),e.break()})},bn.nil)}}};ra.default=Oy});var Of=y(na=>{"use strict";Object.defineProperty(na,"__esModule",{value:!0});var Sn=L(),Py={message({keyword:r,schemaCode:e}){let t=r==="maxItems"?"more":"fewer";return(0,Sn.str)`must NOT have ${t} than ${e} items`},params:({schemaCode:r})=>(0,Sn._)`{limit: ${r}}`},Ry={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:Py,code(r){let{keyword:e,data:t,schemaCode:n}=r,s=e==="maxItems"?Sn.operators.GT:Sn.operators.LT;r.fail$data((0,Sn._)`${t}.length ${s} ${n}`)}};na.default=Ry});var $s=y(sa=>{"use strict";Object.defineProperty(sa,"__esModule",{value:!0});var Pf=Ai();Pf.code='require("ajv/dist/runtime/equal").default';sa.default=Pf});var Rf=y(aa=>{"use strict";Object.defineProperty(aa,"__esModule",{value:!0});var ia=dn(),me=L(),Cy=G(),Ny=$s(),Iy={message:({params:{i:r,j:e}})=>(0,me.str)`must NOT have duplicate items (items ## ${e} and ${r} are identical)`,params:({params:{i:r,j:e}})=>(0,me._)`{i: ${r}, j: ${e}}`},Ty={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:Iy,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,ia.getSchemaTypes)(i.items):[];r.block$data(u,l,(0,me._)`${a} === false`),r.ok(u);function l(){let $=e.let("i",(0,me._)`${t}.length`),E=e.let("j");r.setParams({i:$,j:E}),e.assign(u,!0),e.if((0,me._)`${$} > 1`,()=>(h()?g:v)($,E))}function h(){return o.length>0&&!o.some($=>$==="object"||$==="array")}function g($,E){let w=e.name("item"),b=(0,ia.checkDataTypes)(o,w,c.opts.strictNumbers,ia.DataType.Wrong),D=e.const("indices",(0,me._)`{}`);e.for((0,me._)`;${$}--;`,()=>{e.let(w,(0,me._)`${t}[${$}]`),e.if(b,(0,me._)`continue`),o.length>1&&e.if((0,me._)`typeof ${w} == "string"`,(0,me._)`${w} += "_"`),e.if((0,me._)`typeof ${D}[${w}] == "number"`,()=>{e.assign(E,(0,me._)`${D}[${w}]`),r.error(),e.assign(u,!1).break()}).code((0,me._)`${D}[${w}] = ${$}`)})}function v($,E){let w=(0,Cy.useFunc)(e,Ny.default),b=e.name("outer");e.label(b).for((0,me._)`;${$}--;`,()=>e.for((0,me._)`${E} = ${$}; ${E}--;`,()=>e.if((0,me._)`${w}(${t}[${$}], ${t}[${E}])`,()=>{r.error(),e.assign(u,!1).break(b)})))}}};aa.default=Ty});var Cf=y(ca=>{"use strict";Object.defineProperty(ca,"__esModule",{value:!0});var oa=L(),Ay=G(),qy=$s(),Dy={message:"must be equal to constant",params:({schemaCode:r})=>(0,oa._)`{allowedValue: ${r}}`},jy={keyword:"const",$data:!0,error:Dy,code(r){let{gen:e,data:t,$data:n,schemaCode:s,schema:i}=r;n||i&&typeof i=="object"?r.fail$data((0,oa._)`!${(0,Ay.useFunc)(e,qy.default)}(${t}, ${s})`):r.fail((0,oa._)`${i} !== ${t}`)}};ca.default=jy});var Nf=y(ua=>{"use strict";Object.defineProperty(ua,"__esModule",{value:!0});var On=L(),ky=G(),xy=$s(),Ly={message:"must be equal to one of the allowed values",params:({schemaCode:r})=>(0,On._)`{allowedValues: ${r}}`},My={keyword:"enum",schemaType:"array",$data:!0,error:Ly,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=(0,ky.useFunc)(e,xy.default),o;if(c||n)o=e.let("valid"),r.block$data(o,l);else{if(!Array.isArray(s))throw new Error("ajv implementation error");let g=e.const("vSchema",i);o=(0,On.or)(...s.map((v,$)=>h(g,$)))}r.pass(o);function l(){e.assign(o,!1),e.forOf("v",i,g=>e.if((0,On._)`${u}(${t}, ${g})`,()=>e.assign(o,!0).break()))}function h(g,v){let $=s[v];return typeof $=="object"&&$!==null?(0,On._)`${u}(${t}, ${g}[${v}])`:(0,On._)`${t} === ${$}`}}};ua.default=My});var If=y(la=>{"use strict";Object.defineProperty(la,"__esModule",{value:!0});var Fy=vf(),Vy=_f(),Hy=Ef(),Uy=wf(),Gy=bf(),zy=Sf(),Ky=Of(),Xy=Rf(),By=Cf(),Wy=Nf(),Jy=[Fy.default,Vy.default,Hy.default,Uy.default,Gy.default,zy.default,Ky.default,Xy.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},By.default,Wy.default];la.default=Jy});var da=y(Pn=>{"use strict";Object.defineProperty(Pn,"__esModule",{value:!0});Pn.validateAdditionalItems=void 0;var Zt=L(),fa=G(),Yy={message:({params:{len:r}})=>(0,Zt.str)`must NOT have more than ${r} items`,params:({params:{len:r}})=>(0,Zt._)`{limit: ${r}}`},Zy={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:Yy,code(r){let{parentSchema:e,it:t}=r,{items:n}=e;if(!Array.isArray(n)){(0,fa.checkStrictMode)(t,'"additionalItems" is ignored when "items" is not an array of schemas');return}Tf(r,n)}};function Tf(r,e){let{gen:t,schema:n,data:s,keyword:i,it:a}=r;a.items=!0;let c=t.const("len",(0,Zt._)`${s}.length`);if(n===!1)r.setParams({len:e.length}),r.pass((0,Zt._)`${c} <= ${e.length}`);else if(typeof n=="object"&&!(0,fa.alwaysValidSchema)(a,n)){let o=t.var("valid",(0,Zt._)`${c} <= ${e.length}`);t.if((0,Zt.not)(o),()=>u(o)),r.ok(o)}function u(o){t.forRange("i",e.length,c,l=>{r.subschema({keyword:i,dataProp:l,dataPropType:fa.Type.Num},o),a.allErrors||t.if((0,Zt.not)(o),()=>t.break())})}}Pn.validateAdditionalItems=Tf;Pn.default=Zy});var ha=y(Rn=>{"use strict";Object.defineProperty(Rn,"__esModule",{value:!0});Rn.validateTuple=void 0;var Af=L(),Es=G(),Qy=ze(),e0={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(r){let{schema:e,it:t}=r;if(Array.isArray(e))return qf(r,"additionalItems",e);t.items=!0,!(0,Es.alwaysValidSchema)(t,e)&&r.ok((0,Qy.validateArray)(r))}};function qf(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=Es.mergeEvaluated.items(n,t.length,c.items));let u=n.name("valid"),o=n.const("len",(0,Af._)`${i}.length`);t.forEach((h,g)=>{(0,Es.alwaysValidSchema)(c,h)||(n.if((0,Af._)`${o} > ${g}`,()=>r.subschema({keyword:a,schemaProp:g,dataProp:g},u)),r.ok(u))});function l(h){let{opts:g,errSchemaPath:v}=c,$=t.length,E=$===h.minItems&&($===h.maxItems||h[e]===!1);if(g.strictTuples&&!E){let w=`"${a}" is ${$}-tuple, but minItems or maxItems/${e} are not specified or different at path "${v}"`;(0,Es.checkStrictMode)(c,w,g.strictTuples)}}}Rn.validateTuple=qf;Rn.default=e0});var Df=y(pa=>{"use strict";Object.defineProperty(pa,"__esModule",{value:!0});var t0=ha(),r0={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:r=>(0,t0.validateTuple)(r,"items")};pa.default=r0});var kf=y(ma=>{"use strict";Object.defineProperty(ma,"__esModule",{value:!0});var jf=L(),n0=G(),s0=ze(),i0=da(),a0={message:({params:{len:r}})=>(0,jf.str)`must NOT have more than ${r} items`,params:({params:{len:r}})=>(0,jf._)`{limit: ${r}}`},o0={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:a0,code(r){let{schema:e,parentSchema:t,it:n}=r,{prefixItems:s}=t;n.items=!0,!(0,n0.alwaysValidSchema)(n,e)&&(s?(0,i0.validateAdditionalItems)(r,s):r.ok((0,s0.validateArray)(r)))}};ma.default=o0});var xf=y(ga=>{"use strict";Object.defineProperty(ga,"__esModule",{value:!0});var Xe=L(),ws=G(),c0={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:c0,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,ws.checkStrictMode)(i,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(c!==void 0&&a>c){(0,ws.checkStrictMode)(i,'"minContains" > "maxContains" is always invalid'),r.fail();return}if((0,ws.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 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,Xe._)`${s}.length > 0`,g)):(e.let(h,!1),g()),r.result(h,()=>r.reset());function g(){let E=e.name("_valid"),w=e.let("count",0);v(E,()=>e.if(E,()=>$(w)))}function v(E,w){e.forRange("i",0,l,b=>{r.subschema({keyword:"contains",dataProp:b,dataPropType:ws.Type.Num,compositeRule:!0},E),w()})}function $(E){e.code((0,Xe._)`${E}++`),c===void 0?e.if((0,Xe._)`${E} >= ${a}`,()=>e.assign(h,!0).break()):(e.if((0,Xe._)`${E} > ${c}`,()=>e.assign(h,!1).break()),a===1?e.assign(h,!0):e.if((0,Xe._)`${E} >= ${a}`,()=>e.assign(h,!0)))}}};ga.default=u0});var Ff=y(ut=>{"use strict";Object.defineProperty(ut,"__esModule",{value:!0});ut.validateSchemaDeps=ut.validatePropertyDeps=ut.error=void 0;var va=L(),l0=G(),Cn=ze();ut.error={message:({params:{property:r,depsCount:e,deps:t}})=>{let n=e===1?"property":"properties";return(0,va.str)`must have ${n} ${t} when property ${r} is present`},params:({params:{property:r,depsCount:e,deps:t,missingProperty:n}})=>(0,va._)`{property: ${r},
22
26
  missingProperty: ${n},
23
27
  depsCount: ${e},
24
- deps: ${t}}`};var o0={keyword:"dependencies",type:"object",schemaType:"object",error:ut.error,code(r){let[e,t]=c0(r);xf(r,e),Lf(r,t)}};function c0({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 xf(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,Rn.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,Rn.checkReportMissingProp)(r,o)}):(t.if((0,ga._)`${u} && (${(0,Rn.checkMissingProp)(r,c,i)})`),(0,Rn.reportMissingProp)(r,i),t.else())}}ut.validatePropertyDeps=xf;function Lf(r,e=r.schema){let{gen:t,data:n,keyword:s,it:i}=r,a=t.name("valid");for(let c in e)(0,a0.alwaysValidSchema)(i,e[c])||(t.if((0,Rn.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))}ut.validateSchemaDeps=Lf;ut.default=o0});var Vf=y(va=>{"use strict";Object.defineProperty(va,"__esModule",{value:!0});var Ff=L(),u0=G(),l0={message:"property name must be valid",params:({params:r})=>(0,Ff._)`{propertyName: ${r.propertyName}}`},f0={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:l0,code(r){let{gen:e,schema:t,data:n,it:s}=r;if((0,u0.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,Ff.not)(i),()=>{r.error(!0),s.allErrors||e.break()})}),r.ok(i)}};va.default=f0});var ya=y(_a=>{"use strict";Object.defineProperty(_a,"__esModule",{value:!0});var bs=Ge(),Qe=L(),d0=$t(),Ss=G(),h0={message:"must NOT have additional properties",params:({params:r})=>(0,Qe._)`{additionalProperty: ${r.additionalProperty}}`},p0={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:h0,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,Ss.alwaysValidSchema)(a,t))return;let o=(0,bs.allSchemaProperties)(n.properties),l=(0,bs.allSchemaProperties)(n.patternProperties);h(),r.ok((0,Qe._)`${i} === ${d0.default.errors}`);function h(){e.forIn("key",s,w=>{!o.length&&!l.length?$(w):e.if(g(w),()=>$(w))})}function g(w){let b;if(o.length>8){let D=(0,Ss.schemaRefOrVal)(a,n.properties,"properties");b=(0,bs.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,bs.usePattern)(r,D)}.test(${w})`))),(0,Qe.not)(b)}function v(w){e.code((0,Qe._)`delete ${s}[${w}]`)}function $(w){if(u.removeAdditional==="all"||u.removeAdditional&&t===!1){v(w);return}if(t===!1){r.setParams({additionalProperty:w}),r.error(),c||e.break();return}if(typeof t=="object"&&!(0,Ss.alwaysValidSchema)(a,t)){let b=e.name("valid");u.removeAdditional==="failing"?(E(w,b,!1),e.if((0,Qe.not)(b),()=>{r.reset(),v(w)})):(E(w,b),c||e.if((0,Qe.not)(b),()=>e.break()))}}function E(w,b,D){let A={keyword:"additionalProperties",dataProp:w,dataPropType:Ss.Type.Str};D===!1&&Object.assign(A,{compositeRule:!0,createErrors:!1,allErrors:!1}),r.subschema(A,b)}}};_a.default=p0});var Gf=y(Ea=>{"use strict";Object.defineProperty(Ea,"__esModule",{value:!0});var m0=mn(),Uf=Ge(),$a=G(),Hf=ya(),g0={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&&Hf.default.code(new m0.KeywordCxt(i,Hf.default,"additionalProperties"));let a=(0,Uf.allSchemaProperties)(t);for(let h of a)i.definedProperties.add(h);i.opts.unevaluated&&a.length&&i.props!==!0&&(i.props=$a.mergeEvaluated.props(e,(0,$a.toHash)(a),i.props));let c=a.filter(h=>!(0,$a.alwaysValidSchema)(i,t[h]));if(c.length===0)return;let u=e.name("valid");for(let h of c)o(h)?l(h):(e.if((0,Uf.propertyInData)(e,s,h,i.opts.ownProperties)),l(h),i.allErrors||e.else().var(u,!0),e.endIf()),r.it.definedProperties.add(h),r.ok(u);function o(h){return i.opts.useDefaults&&!i.compositeRule&&t[h].default!==void 0}function l(h){r.subschema({keyword:"properties",schemaProp:h,dataProp:h},u)}}};Ea.default=g0});var Bf=y(wa=>{"use strict";Object.defineProperty(wa,"__esModule",{value:!0});var zf=Ge(),Os=L(),Kf=G(),Xf=G(),v0={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,zf.allSchemaProperties)(t),u=c.filter(E=>(0,Kf.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 Os.Name)&&(i.props=(0,Xf.evaluatedPropsToName)(e,i.props));let{props:h}=i;g();function g(){for(let E of c)o&&v(E),i.allErrors?$(E):(e.var(l,!0),$(E),e.if(l))}function v(E){for(let w in o)new RegExp(E).test(w)&&(0,Kf.checkStrictMode)(i,`property ${w} matches pattern ${E} (use allowMatchingProperties)`)}function $(E){e.forIn("key",n,w=>{e.if((0,Os._)`${(0,zf.usePattern)(r,E)}.test(${w})`,()=>{let b=u.includes(E);b||r.subschema({keyword:"patternProperties",schemaProp:E,dataProp:w,dataPropType:Xf.Type.Str},l),i.opts.unevaluated&&h!==!0?e.assign((0,Os._)`${h}[${w}]`,!0):!b&&!i.allErrors&&e.if((0,Os.not)(l),()=>e.break())})})}}};wa.default=v0});var Wf=y(ba=>{"use strict";Object.defineProperty(ba,"__esModule",{value:!0});var _0=G(),y0={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(r){let{gen:e,schema:t,it:n}=r;if((0,_0.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"}};ba.default=y0});var Jf=y(Sa=>{"use strict";Object.defineProperty(Sa,"__esModule",{value:!0});var $0=Ge(),E0={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:$0.validateUnion,error:{message:"must match a schema in anyOf"}};Sa.default=E0});var Yf=y(Oa=>{"use strict";Object.defineProperty(Oa,"__esModule",{value:!0});var Ps=L(),w0=G(),b0={message:"must match exactly one schema in oneOf",params:({params:r})=>(0,Ps._)`{passingSchemas: ${r.passing}}`},S0={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:b0,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,h)=>{let g;(0,w0.alwaysValidSchema)(s,l)?e.var(u,!0):g=r.subschema({keyword:"oneOf",schemaProp:h,compositeRule:!0},u),h>0&&e.if((0,Ps._)`${u} && ${a}`).assign(a,!1).assign(c,(0,Ps._)`[${c}, ${h}]`).else(),e.if(u,()=>{e.assign(a,!0),e.assign(c,h),g&&r.mergeEvaluated(g,Ps.Name)})})}}};Oa.default=S0});var Zf=y(Pa=>{"use strict";Object.defineProperty(Pa,"__esModule",{value:!0});var O0=G(),P0={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,O0.alwaysValidSchema)(n,i))return;let c=r.subschema({keyword:"allOf",schemaProp:a},s);r.ok(s),r.mergeEvaluated(c)})}};Pa.default=P0});var td=y(Ra=>{"use strict";Object.defineProperty(Ra,"__esModule",{value:!0});var Rs=L(),ed=G(),R0={message:({params:r})=>(0,Rs.str)`must match "${r.ifClause}" schema`,params:({params:r})=>(0,Rs._)`{failingKeyword: ${r.ifClause}}`},C0={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:R0,code(r){let{gen:e,parentSchema:t,it:n}=r;t.then===void 0&&t.else===void 0&&(0,ed.checkStrictMode)(n,'"if" without "then" and "else" is ignored');let s=Qf(n,"then"),i=Qf(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,Rs.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,h){return()=>{let g=r.subschema({keyword:l},c);e.assign(a,c),r.mergeValidEvaluated(g,a),h?e.assign(h,(0,Rs._)`${l}`):r.setParams({ifClause:l})}}}};function Qf(r,e){let t=r.schema[e];return t!==void 0&&!(0,ed.alwaysValidSchema)(r,t)}Ra.default=C0});var rd=y(Ca=>{"use strict";Object.defineProperty(Ca,"__esModule",{value:!0});var N0=G(),I0={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:r,parentSchema:e,it:t}){e.if===void 0&&(0,N0.checkStrictMode)(t,`"${r}" without "if" is ignored`)}};Ca.default=I0});var nd=y(Na=>{"use strict";Object.defineProperty(Na,"__esModule",{value:!0});var A0=fa(),T0=qf(),q0=da(),D0=jf(),j0=kf(),k0=Mf(),x0=Vf(),L0=ya(),M0=Gf(),F0=Bf(),V0=Wf(),U0=Jf(),H0=Yf(),G0=Zf(),z0=td(),K0=rd();function X0(r=!1){let e=[V0.default,U0.default,H0.default,G0.default,z0.default,K0.default,x0.default,L0.default,k0.default,M0.default,F0.default];return r?e.push(T0.default,D0.default):e.push(A0.default,q0.default),e.push(j0.default),e}Na.default=X0});var sd=y(Ia=>{"use strict";Object.defineProperty(Ia,"__esModule",{value:!0});var oe=L(),B0={message:({schemaCode:r})=>(0,oe.str)`must match format "${r}"`,params:({schemaCode:r})=>(0,oe._)`{format: ${r}}`},W0={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:B0,code(r,e){let{gen:t,data:n,$data:s,schema:i,schemaCode:a,it:c}=r,{opts:u,errSchemaPath:o,schemaEnv:l,self:h}=c;if(!u.validateFormats)return;s?g():v();function g(){let $=t.scopeValue("formats",{ref:h.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(),A()));function D(){return u.strictSchema===!1?oe.nil:(0,oe._)`${a} && !${b}`}function A(){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 v(){let $=h.formats[i];if(!$){D();return}if($===!0)return;let[E,w,b]=A($);E===e&&r.pass(z());function D(){if(u.strictSchema===!1){h.logger.warn(C());return}throw new Error(C());function C(){return`unknown format "${i}" ignored in schema at path "${o}"`}}function A(C){let ge=C instanceof RegExp?(0,oe.regexpCode)(C):u.code.formats?(0,oe._)`${u.code.formats}${(0,oe.getProperty)(i)}`:void 0,De=t.scopeValue("formats",{key:i,ref:C,code:ge});return typeof C=="object"&&!(C instanceof RegExp)?[C.type||"string",C.validate,(0,oe._)`${De}.validate`]:["string",C,De]}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})`}}}};Ia.default=W0});var id=y(Aa=>{"use strict";Object.defineProperty(Aa,"__esModule",{value:!0});var J0=sd(),Y0=[J0.default];Aa.default=Y0});var ad=y(wr=>{"use strict";Object.defineProperty(wr,"__esModule",{value:!0});wr.contentVocabulary=wr.metadataVocabulary=void 0;wr.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];wr.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]});var cd=y(Ta=>{"use strict";Object.defineProperty(Ta,"__esModule",{value:!0});var Z0=mf(),Q0=Nf(),e$=nd(),t$=id(),od=ad(),r$=[Z0.default,Q0.default,(0,e$.default)(),t$.default,od.metadataVocabulary,od.contentVocabulary];Ta.default=r$});var ud=y(Cn=>{"use strict";Object.defineProperty(Cn,"__esModule",{value:!0});Cn.DiscrError=void 0;var n$;(function(r){r.Tag="tag",r.Mapping="mapping"})(n$=Cn.DiscrError||(Cn.DiscrError={}))});var fd=y(Da=>{"use strict";Object.defineProperty(Da,"__esModule",{value:!0});var br=L(),qa=ud(),ld=fs(),s$=G(),i$={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,br._)`{error: ${r}, tag: ${t}, tagValue: ${e}}`},a$={keyword:"discriminator",type:"object",schemaType:"object",error:i$,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,br._)`${t}${(0,br.getProperty)(c)}`);e.if((0,br._)`typeof ${o} == "string"`,()=>l(),()=>r.error(!1,{discrError:qa.DiscrError.Tag,tag:o,tagName:c})),r.ok(u);function l(){let v=g();e.if(!1);for(let $ in v)e.elseIf((0,br._)`${o} === ${$}`),e.assign(u,h(v[$]));e.else(),r.error(!1,{discrError:qa.DiscrError.Mapping,tag:o,tagName:c}),e.endIf()}function h(v){let $=e.name("valid"),E=r.subschema({keyword:"oneOf",schemaProp:v},$);return r.mergeEvaluated(E,br.Name),$}function g(){var v;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,s$.schemaHasRulesButRef)(C,i.self.RULES)&&(C=ld.resolveRef.call(i.self,i.schemaEnv,i.baseId,C==null?void 0:C.$ref),C instanceof ld.SchemaEnv&&(C=C.schema));let ge=(v=C==null?void 0:C.properties)===null||v===void 0?void 0:v[c];if(typeof ge!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${c}"`);w=w&&(E||b(C)),D(ge,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)A(z.const,C);else if(z.enum)for(let ge of z.enum)A(ge,C);else throw new Error(`discriminator: "properties/${c}" must have "const" or "enum"`)}function A(z,C){if(typeof z!="string"||z in $)throw new Error(`discriminator: "${c}" values must be unique strings`);$[z]=C}}}};Da.default=a$});var dd=y((Ub,o$)=>{o$.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 md=y((le,pd)=>{"use strict";Object.defineProperty(le,"__esModule",{value:!0});le.CodeGen=le.Name=le.nil=le.stringify=le.str=le._=le.KeywordCxt=void 0;var c$=uf(),u$=cd(),l$=fd(),hd=dd(),f$=["/properties"],Cs="http://json-schema.org/draft-07/schema",ja=class extends c$.default{_addVocabularies(){super._addVocabularies(),u$.default.forEach(e=>this.addVocabulary(e)),this.opts.discriminator&&this.addKeyword(l$.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;let e=this.opts.$data?this.$dataMetaSchema(hd,f$):hd;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)}};pd.exports=le=ja;Object.defineProperty(le,"__esModule",{value:!0});le.default=ja;var d$=mn();Object.defineProperty(le,"KeywordCxt",{enumerable:!0,get:function(){return d$.KeywordCxt}});var Sr=L();Object.defineProperty(le,"_",{enumerable:!0,get:function(){return Sr._}});Object.defineProperty(le,"str",{enumerable:!0,get:function(){return Sr.str}});Object.defineProperty(le,"stringify",{enumerable:!0,get:function(){return Sr.stringify}});Object.defineProperty(le,"nil",{enumerable:!0,get:function(){return Sr.nil}});Object.defineProperty(le,"Name",{enumerable:!0,get:function(){return Sr.Name}});Object.defineProperty(le,"CodeGen",{enumerable:!0,get:function(){return Sr.CodeGen}})});var Zt=y(Or=>{"use strict";var h$=Or&&Or.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Or,"__esModule",{value:!0});Or.ServerlessError=void 0;var p$=h$(yt()),m$=p$.default.Logger,g$=new m$("S-CLI-ERROR"),v$=function(){function r(e,t,n){g$.error(e+": "+t,n),process.exit(1)}return r}();Or.ServerlessError=v$});var gd=y(Pr=>{"use strict";var _$=Pr&&Pr.__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(Pr,"__esModule",{value:!0});Pr.CommandError=void 0;var y$=Zt(),$$=function(r){_$(e,r);function e(t,n){return r.call(this,"Error",t,n)||this}return e}(y$.ServerlessError);Pr.CommandError=$$});var vd=y(Rr=>{"use strict";var E$=Rr&&Rr.__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(Rr,"__esModule",{value:!0});Rr.ConfigDeleteError=void 0;var w$=Zt(),b$=function(r){E$(e,r);function e(t,n){return r.call(this,"Deletion failed",t,n)||this}return e}(w$.ServerlessError);Rr.ConfigDeleteError=b$});var _d=y(Cr=>{"use strict";var S$=Cr&&Cr.__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(Cr,"__esModule",{value:!0});Cr.ConfigError=void 0;var O$=Zt(),P$=function(r){S$(e,r);function e(t,n){return r.call(this,"Config failed",t,n)||this}return e}(O$.ServerlessError);Cr.ConfigError=P$});var yd=y(Nr=>{"use strict";var R$=Nr&&Nr.__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(Nr,"__esModule",{value:!0});Nr.ConfigGetError=void 0;var C$=Zt(),N$=function(r){R$(e,r);function e(t,n){return r.call(this,"Get failed",t,n)||this}return e}(C$.ServerlessError);Nr.ConfigGetError=N$});var $d=y(Ir=>{"use strict";var I$=Ir&&Ir.__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(Ir,"__esModule",{value:!0});Ir.InitError=void 0;var A$=Zt(),T$=function(r){I$(e,r);function e(t,n){return r.call(this,"Initialization failed",t,n)||this}return e}(A$.ServerlessError);Ir.InitError=T$});var wd=y(lt=>{"use strict";var q$=lt&&lt.__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(h){a(h)}}function u(l){try{o(n.throw(l))}catch(h){a(h)}}function o(l){l.done?i(l.value):s(l.value).then(c,u)}o((n=n.apply(r,e||[])).next())})},D$=lt&&lt.__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}}},j$=lt&&lt.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(lt,"__esModule",{value:!0});lt.HumanError=void 0;var Ed=j$(yt()),k$=Yn(),x$=Ed.default.colors,L$=function(){function r(e){var t=e.errorMessage,n=e.tips;this.errorMessage=t,console.log(`
25
- `.concat((0,k$.bgRed)("ERROR:"))),console.log("TypeError: ".concat(t,`
26
- `)),n&&console.log("".concat(x$.gray(n),`
27
- `))}return r.prototype.report=function(e){return q$(this,void 0,void 0,function(){var t;return D$(this,function(n){switch(n.label){case 0:return t=e.error,[4,Ed.default.report({type:"jsError",content:"".concat(this.errorMessage,"||").concat(t.stack)})];case 1:return n.sent(),[2]}})})},r}();lt.HumanError=L$});var Sd=y(Ar=>{"use strict";var M$=Ar&&Ar.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Ar,"__esModule",{value:!0});Ar.HumanWarning=void 0;var F$=M$(yt()),bd=F$.default.colors,V$=function(){function r(e){var t=e.warningMessage,n=e.tips;console.log(`
28
- `.concat(bd.hex("#000").bgYellow("WARNING:"))),console.log("".concat(t,`
29
- `)),n&&console.log("".concat(bd.gray(n),`
30
- `))}return r}();Ar.HumanWarning=V$});var Od=y(Q=>{"use strict";var U$=Q&&Q.__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(h){a(h)}}function u(l){try{o(n.throw(l))}catch(h){a(h)}}function o(l){l.done?i(l.value):s(l.value).then(c,u)}o((n=n.apply(r,e||[])).next())})},H$=Q&&Q.__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}}},G$=Q&&Q.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Q,"__esModule",{value:!0});Q.HandleError=Q.HumanWarning=Q.HumanError=Q.ServerlessError=Q.InitError=Q.ConfigGetError=Q.ConfigError=Q.ConfigDeleteError=Q.CommandError=void 0;var ft=li(),Ns=G$(yt()),Dt=Ns.default.colors,z$=Ns.default.report,ka=Ns.default.isDebugMode,K$=Ns.default.makeUnderLine,X$=gd();Object.defineProperty(Q,"CommandError",{enumerable:!0,get:function(){return X$.CommandError}});var B$=vd();Object.defineProperty(Q,"ConfigDeleteError",{enumerable:!0,get:function(){return B$.ConfigDeleteError}});var W$=_d();Object.defineProperty(Q,"ConfigError",{enumerable:!0,get:function(){return W$.ConfigError}});var J$=yd();Object.defineProperty(Q,"ConfigGetError",{enumerable:!0,get:function(){return J$.ConfigGetError}});var Y$=$d();Object.defineProperty(Q,"InitError",{enumerable:!0,get:function(){return Y$.InitError}});var Z$=Zt();Object.defineProperty(Q,"ServerlessError",{enumerable:!0,get:function(){return Z$.ServerlessError}});var Q$=wd();Object.defineProperty(Q,"HumanError",{enumerable:!0,get:function(){return Q$.HumanError}});var eE=Sd();Object.defineProperty(Q,"HumanWarning",{enumerable:!0,get:function(){return eE.HumanWarning}});function xa(r,e){return"".concat(Dt.gray(r)).concat(Dt.gray.underline(e))}var tE=function(r){return U$(void 0,void 0,void 0,function(){var e,t,n,s,i,a,c,u;return H$(this,function(o){switch(o.label){case 0:e="Message:",t={traceId:"",catchableError:!1},n=r,s=(0,ft.getConfig)("analysis"),s!=="disable"&&(t.traceId="".concat((0,ft.getPid)()).concat(Date.now())),i=r.message?r.message:"";try{a=JSON.parse(i)}catch{}return a&&a.tips?(c=a.message?"Message: ".concat(a.message,`
31
- `):"",u=a.tips?"* ".concat(K$(a.tips.replace(/\n/,`
28
+ deps: ${t}}`};var f0={keyword:"dependencies",type:"object",schemaType:"object",error:ut.error,code(r){let[e,t]=d0(r);Lf(r,e),Mf(r,t)}};function d0({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 Lf(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,Cn.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,Cn.checkReportMissingProp)(r,o)}):(t.if((0,va._)`${u} && (${(0,Cn.checkMissingProp)(r,c,i)})`),(0,Cn.reportMissingProp)(r,i),t.else())}}ut.validatePropertyDeps=Lf;function Mf(r,e=r.schema){let{gen:t,data:n,keyword:s,it:i}=r,a=t.name("valid");for(let c in e)(0,l0.alwaysValidSchema)(i,e[c])||(t.if((0,Cn.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))}ut.validateSchemaDeps=Mf;ut.default=f0});var Hf=y(_a=>{"use strict";Object.defineProperty(_a,"__esModule",{value:!0});var Vf=L(),h0=G(),p0={message:"property name must be valid",params:({params:r})=>(0,Vf._)`{propertyName: ${r.propertyName}}`},m0={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:p0,code(r){let{gen:e,schema:t,data:n,it:s}=r;if((0,h0.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,Vf.not)(i),()=>{r.error(!0),s.allErrors||e.break()})}),r.ok(i)}};_a.default=m0});var $a=y(ya=>{"use strict";Object.defineProperty(ya,"__esModule",{value:!0});var bs=ze(),Qe=L(),g0=$t(),Ss=G(),v0={message:"must NOT have additional properties",params:({params:r})=>(0,Qe._)`{additionalProperty: ${r.additionalProperty}}`},_0={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:v0,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,Ss.alwaysValidSchema)(a,t))return;let o=(0,bs.allSchemaProperties)(n.properties),l=(0,bs.allSchemaProperties)(n.patternProperties);h(),r.ok((0,Qe._)`${i} === ${g0.default.errors}`);function h(){e.forIn("key",s,w=>{!o.length&&!l.length?$(w):e.if(g(w),()=>$(w))})}function g(w){let b;if(o.length>8){let D=(0,Ss.schemaRefOrVal)(a,n.properties,"properties");b=(0,bs.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,bs.usePattern)(r,D)}.test(${w})`))),(0,Qe.not)(b)}function v(w){e.code((0,Qe._)`delete ${s}[${w}]`)}function $(w){if(u.removeAdditional==="all"||u.removeAdditional&&t===!1){v(w);return}if(t===!1){r.setParams({additionalProperty:w}),r.error(),c||e.break();return}if(typeof t=="object"&&!(0,Ss.alwaysValidSchema)(a,t)){let b=e.name("valid");u.removeAdditional==="failing"?(E(w,b,!1),e.if((0,Qe.not)(b),()=>{r.reset(),v(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:Ss.Type.Str};D===!1&&Object.assign(T,{compositeRule:!0,createErrors:!1,allErrors:!1}),r.subschema(T,b)}}};ya.default=_0});var zf=y(wa=>{"use strict";Object.defineProperty(wa,"__esModule",{value:!0});var y0=gn(),Uf=ze(),Ea=G(),Gf=$a(),$0={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&&Gf.default.code(new y0.KeywordCxt(i,Gf.default,"additionalProperties"));let a=(0,Uf.allSchemaProperties)(t);for(let h of a)i.definedProperties.add(h);i.opts.unevaluated&&a.length&&i.props!==!0&&(i.props=Ea.mergeEvaluated.props(e,(0,Ea.toHash)(a),i.props));let c=a.filter(h=>!(0,Ea.alwaysValidSchema)(i,t[h]));if(c.length===0)return;let u=e.name("valid");for(let h of c)o(h)?l(h):(e.if((0,Uf.propertyInData)(e,s,h,i.opts.ownProperties)),l(h),i.allErrors||e.else().var(u,!0),e.endIf()),r.it.definedProperties.add(h),r.ok(u);function o(h){return i.opts.useDefaults&&!i.compositeRule&&t[h].default!==void 0}function l(h){r.subschema({keyword:"properties",schemaProp:h,dataProp:h},u)}}};wa.default=$0});var Wf=y(ba=>{"use strict";Object.defineProperty(ba,"__esModule",{value:!0});var Kf=ze(),Os=L(),Xf=G(),Bf=G(),E0={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,Kf.allSchemaProperties)(t),u=c.filter(E=>(0,Xf.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 Os.Name)&&(i.props=(0,Bf.evaluatedPropsToName)(e,i.props));let{props:h}=i;g();function g(){for(let E of c)o&&v(E),i.allErrors?$(E):(e.var(l,!0),$(E),e.if(l))}function v(E){for(let w in o)new RegExp(E).test(w)&&(0,Xf.checkStrictMode)(i,`property ${w} matches pattern ${E} (use allowMatchingProperties)`)}function $(E){e.forIn("key",n,w=>{e.if((0,Os._)`${(0,Kf.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&&h!==!0?e.assign((0,Os._)`${h}[${w}]`,!0):!b&&!i.allErrors&&e.if((0,Os.not)(l),()=>e.break())})})}}};ba.default=E0});var Jf=y(Sa=>{"use strict";Object.defineProperty(Sa,"__esModule",{value:!0});var w0=G(),b0={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(r){let{gen:e,schema:t,it:n}=r;if((0,w0.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"}};Sa.default=b0});var Yf=y(Oa=>{"use strict";Object.defineProperty(Oa,"__esModule",{value:!0});var S0=ze(),O0={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:S0.validateUnion,error:{message:"must match a schema in anyOf"}};Oa.default=O0});var Zf=y(Pa=>{"use strict";Object.defineProperty(Pa,"__esModule",{value:!0});var Ps=L(),P0=G(),R0={message:"must match exactly one schema in oneOf",params:({params:r})=>(0,Ps._)`{passingSchemas: ${r.passing}}`},C0={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:R0,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,h)=>{let g;(0,P0.alwaysValidSchema)(s,l)?e.var(u,!0):g=r.subschema({keyword:"oneOf",schemaProp:h,compositeRule:!0},u),h>0&&e.if((0,Ps._)`${u} && ${a}`).assign(a,!1).assign(c,(0,Ps._)`[${c}, ${h}]`).else(),e.if(u,()=>{e.assign(a,!0),e.assign(c,h),g&&r.mergeEvaluated(g,Ps.Name)})})}}};Pa.default=C0});var Qf=y(Ra=>{"use strict";Object.defineProperty(Ra,"__esModule",{value:!0});var N0=G(),I0={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,N0.alwaysValidSchema)(n,i))return;let c=r.subschema({keyword:"allOf",schemaProp:a},s);r.ok(s),r.mergeEvaluated(c)})}};Ra.default=I0});var rd=y(Ca=>{"use strict";Object.defineProperty(Ca,"__esModule",{value:!0});var Rs=L(),td=G(),T0={message:({params:r})=>(0,Rs.str)`must match "${r.ifClause}" schema`,params:({params:r})=>(0,Rs._)`{failingKeyword: ${r.ifClause}}`},A0={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:T0,code(r){let{gen:e,parentSchema:t,it:n}=r;t.then===void 0&&t.else===void 0&&(0,td.checkStrictMode)(n,'"if" without "then" and "else" is ignored');let s=ed(n,"then"),i=ed(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,Rs.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,h){return()=>{let g=r.subschema({keyword:l},c);e.assign(a,c),r.mergeValidEvaluated(g,a),h?e.assign(h,(0,Rs._)`${l}`):r.setParams({ifClause:l})}}}};function ed(r,e){let t=r.schema[e];return t!==void 0&&!(0,td.alwaysValidSchema)(r,t)}Ca.default=A0});var nd=y(Na=>{"use strict";Object.defineProperty(Na,"__esModule",{value:!0});var q0=G(),D0={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:r,parentSchema:e,it:t}){e.if===void 0&&(0,q0.checkStrictMode)(t,`"${r}" without "if" is ignored`)}};Na.default=D0});var sd=y(Ia=>{"use strict";Object.defineProperty(Ia,"__esModule",{value:!0});var j0=da(),k0=Df(),x0=ha(),L0=kf(),M0=xf(),F0=Ff(),V0=Hf(),H0=$a(),U0=zf(),G0=Wf(),z0=Jf(),K0=Yf(),X0=Zf(),B0=Qf(),W0=rd(),J0=nd();function Y0(r=!1){let e=[z0.default,K0.default,X0.default,B0.default,W0.default,J0.default,V0.default,H0.default,F0.default,U0.default,G0.default];return r?e.push(k0.default,L0.default):e.push(j0.default,x0.default),e.push(M0.default),e}Ia.default=Y0});var id=y(Ta=>{"use strict";Object.defineProperty(Ta,"__esModule",{value:!0});var oe=L(),Z0={message:({schemaCode:r})=>(0,oe.str)`must match format "${r}"`,params:({schemaCode:r})=>(0,oe._)`{format: ${r}}`},Q0={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:Z0,code(r,e){let{gen:t,data:n,$data:s,schema:i,schemaCode:a,it:c}=r,{opts:u,errSchemaPath:o,schemaEnv:l,self:h}=c;if(!u.validateFormats)return;s?g():v();function g(){let $=t.scopeValue("formats",{ref:h.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})`,N=(0,oe._)`(typeof ${b} == "function" ? ${z} : ${b}.test(${n}))`;return(0,oe._)`${b} && ${b} !== true && ${w} === ${e} && !${N}`}}function v(){let $=h.formats[i];if(!$){D();return}if($===!0)return;let[E,w,b]=T($);E===e&&r.pass(z());function D(){if(u.strictSchema===!1){h.logger.warn(N());return}throw new Error(N());function N(){return`unknown format "${i}" ignored in schema at path "${o}"`}}function T(N){let ge=N instanceof RegExp?(0,oe.regexpCode)(N):u.code.formats?(0,oe._)`${u.code.formats}${(0,oe.getProperty)(i)}`:void 0,je=t.scopeValue("formats",{key:i,ref:N,code:ge});return typeof N=="object"&&!(N instanceof RegExp)?[N.type||"string",N.validate,(0,oe._)`${je}.validate`]:["string",N,je]}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})`}}}};Ta.default=Q0});var ad=y(Aa=>{"use strict";Object.defineProperty(Aa,"__esModule",{value:!0});var e$=id(),t$=[e$.default];Aa.default=t$});var od=y(Or=>{"use strict";Object.defineProperty(Or,"__esModule",{value:!0});Or.contentVocabulary=Or.metadataVocabulary=void 0;Or.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];Or.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]});var ud=y(qa=>{"use strict";Object.defineProperty(qa,"__esModule",{value:!0});var r$=gf(),n$=If(),s$=sd(),i$=ad(),cd=od(),a$=[r$.default,n$.default,(0,s$.default)(),i$.default,cd.metadataVocabulary,cd.contentVocabulary];qa.default=a$});var ld=y(Nn=>{"use strict";Object.defineProperty(Nn,"__esModule",{value:!0});Nn.DiscrError=void 0;var o$;(function(r){r.Tag="tag",r.Mapping="mapping"})(o$=Nn.DiscrError||(Nn.DiscrError={}))});var dd=y(ja=>{"use strict";Object.defineProperty(ja,"__esModule",{value:!0});var Pr=L(),Da=ld(),fd=fs(),c$=G(),u$={message:({params:{discrError:r,tagName:e}})=>r===Da.DiscrError.Tag?`tag "${e}" must be string`:`value of tag "${e}" must be in oneOf`,params:({params:{discrError:r,tag:e,tagName:t}})=>(0,Pr._)`{error: ${r}, tag: ${t}, tagValue: ${e}}`},l$={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,Pr._)`${t}${(0,Pr.getProperty)(c)}`);e.if((0,Pr._)`typeof ${o} == "string"`,()=>l(),()=>r.error(!1,{discrError:Da.DiscrError.Tag,tag:o,tagName:c})),r.ok(u);function l(){let v=g();e.if(!1);for(let $ in v)e.elseIf((0,Pr._)`${o} === ${$}`),e.assign(u,h(v[$]));e.else(),r.error(!1,{discrError:Da.DiscrError.Mapping,tag:o,tagName:c}),e.endIf()}function h(v){let $=e.name("valid"),E=r.subschema({keyword:"oneOf",schemaProp:v},$);return r.mergeEvaluated(E,Pr.Name),$}function g(){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,c$.schemaHasRulesButRef)(N,i.self.RULES)&&(N=fd.resolveRef.call(i.self,i.schemaEnv,i.baseId,N==null?void 0:N.$ref),N instanceof fd.SchemaEnv&&(N=N.schema));let ge=(v=N==null?void 0:N.properties)===null||v===void 0?void 0:v[c];if(typeof ge!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${c}"`);w=w&&(E||b(N)),D(ge,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,N){if(z.const)T(z.const,N);else if(z.enum)for(let ge of z.enum)T(ge,N);else throw new Error(`discriminator: "properties/${c}" must have "const" or "enum"`)}function T(z,N){if(typeof z!="string"||z in $)throw new Error(`discriminator: "${c}" values must be unique strings`);$[z]=N}}}};ja.default=l$});var hd=y((Kb,f$)=>{f$.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 gd=y((le,md)=>{"use strict";Object.defineProperty(le,"__esModule",{value:!0});le.CodeGen=le.Name=le.nil=le.stringify=le.str=le._=le.KeywordCxt=void 0;var d$=lf(),h$=ud(),p$=dd(),pd=hd(),m$=["/properties"],Cs="http://json-schema.org/draft-07/schema",ka=class extends d$.default{_addVocabularies(){super._addVocabularies(),h$.default.forEach(e=>this.addVocabulary(e)),this.opts.discriminator&&this.addKeyword(p$.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;let e=this.opts.$data?this.$dataMetaSchema(pd,m$):pd;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)}};md.exports=le=ka;Object.defineProperty(le,"__esModule",{value:!0});le.default=ka;var g$=gn();Object.defineProperty(le,"KeywordCxt",{enumerable:!0,get:function(){return g$.KeywordCxt}});var Rr=L();Object.defineProperty(le,"_",{enumerable:!0,get:function(){return Rr._}});Object.defineProperty(le,"str",{enumerable:!0,get:function(){return Rr.str}});Object.defineProperty(le,"stringify",{enumerable:!0,get:function(){return Rr.stringify}});Object.defineProperty(le,"nil",{enumerable:!0,get:function(){return Rr.nil}});Object.defineProperty(le,"Name",{enumerable:!0,get:function(){return Rr.Name}});Object.defineProperty(le,"CodeGen",{enumerable:!0,get:function(){return Rr.CodeGen}})});var Qt=y(Cr=>{"use strict";var v$=Cr&&Cr.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Cr,"__esModule",{value:!0});Cr.ServerlessError=void 0;var _$=v$(yt()),y$=_$.default.Logger,$$=new y$("S-CLI-ERROR"),E$=function(){function r(e,t,n){$$.error(e+": "+t,n),process.exit(1)}return r}();Cr.ServerlessError=E$});var vd=y(Nr=>{"use strict";var w$=Nr&&Nr.__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(Nr,"__esModule",{value:!0});Nr.CommandError=void 0;var b$=Qt(),S$=function(r){w$(e,r);function e(t,n){return r.call(this,"Error",t,n)||this}return e}(b$.ServerlessError);Nr.CommandError=S$});var _d=y(Ir=>{"use strict";var O$=Ir&&Ir.__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(Ir,"__esModule",{value:!0});Ir.ConfigDeleteError=void 0;var P$=Qt(),R$=function(r){O$(e,r);function e(t,n){return r.call(this,"Deletion failed",t,n)||this}return e}(P$.ServerlessError);Ir.ConfigDeleteError=R$});var yd=y(Tr=>{"use strict";var C$=Tr&&Tr.__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(Tr,"__esModule",{value:!0});Tr.ConfigError=void 0;var N$=Qt(),I$=function(r){C$(e,r);function e(t,n){return r.call(this,"Config failed",t,n)||this}return e}(N$.ServerlessError);Tr.ConfigError=I$});var $d=y(Ar=>{"use strict";var T$=Ar&&Ar.__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(Ar,"__esModule",{value:!0});Ar.ConfigGetError=void 0;var A$=Qt(),q$=function(r){T$(e,r);function e(t,n){return r.call(this,"Get failed",t,n)||this}return e}(A$.ServerlessError);Ar.ConfigGetError=q$});var Ed=y(qr=>{"use strict";var D$=qr&&qr.__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(qr,"__esModule",{value:!0});qr.InitError=void 0;var j$=Qt(),k$=function(r){D$(e,r);function e(t,n){return r.call(this,"Initialization failed",t,n)||this}return e}(j$.ServerlessError);qr.InitError=k$});var bd=y(lt=>{"use strict";var x$=lt&&lt.__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(h){a(h)}}function u(l){try{o(n.throw(l))}catch(h){a(h)}}function o(l){l.done?i(l.value):s(l.value).then(c,u)}o((n=n.apply(r,e||[])).next())})},L$=lt&&lt.__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}}},M$=lt&&lt.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(lt,"__esModule",{value:!0});lt.HumanError=void 0;var wd=M$(yt()),F$=Yn(),V$=wd.default.colors,H$=function(){function r(e){var t=e.errorMessage,n=e.tips;this.errorMessage=t,console.log(`
29
+ `.concat((0,F$.bgRed)("ERROR:"))),console.log("TypeError: ".concat(t,`
30
+ `)),n&&console.log("".concat(V$.gray(n),`
31
+ `))}return r.prototype.report=function(e){return x$(this,void 0,void 0,function(){var t;return L$(this,function(n){switch(n.label){case 0:return t=e.error,[4,wd.default.report({type:"jsError",content:"".concat(this.errorMessage,"||").concat(t.stack)})];case 1:return n.sent(),[2]}})})},r}();lt.HumanError=H$});var Od=y(Dr=>{"use strict";var U$=Dr&&Dr.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Dr,"__esModule",{value:!0});Dr.HumanWarning=void 0;var G$=U$(yt()),Sd=G$.default.colors,z$=function(){function r(e){var t=e.warningMessage,n=e.tips;console.log(`
32
+ `.concat(Sd.hex("#000").bgYellow("WARNING:"))),console.log("".concat(t,`
33
+ `)),n&&console.log("".concat(Sd.gray(n),`
34
+ `))}return r}();Dr.HumanWarning=z$});var Pd=y(Q=>{"use strict";var K$=Q&&Q.__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(h){a(h)}}function u(l){try{o(n.throw(l))}catch(h){a(h)}}function o(l){l.done?i(l.value):s(l.value).then(c,u)}o((n=n.apply(r,e||[])).next())})},X$=Q&&Q.__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}}},B$=Q&&Q.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Q,"__esModule",{value:!0});Q.HandleError=Q.HumanWarning=Q.HumanError=Q.ServerlessError=Q.InitError=Q.ConfigGetError=Q.ConfigError=Q.ConfigDeleteError=Q.CommandError=void 0;var ft=fi(),Ns=B$(yt()),jt=Ns.default.colors,W$=Ns.default.report,xa=Ns.default.isDebugMode,J$=Ns.default.makeUnderLine,Y$=vd();Object.defineProperty(Q,"CommandError",{enumerable:!0,get:function(){return Y$.CommandError}});var Z$=_d();Object.defineProperty(Q,"ConfigDeleteError",{enumerable:!0,get:function(){return Z$.ConfigDeleteError}});var Q$=yd();Object.defineProperty(Q,"ConfigError",{enumerable:!0,get:function(){return Q$.ConfigError}});var eE=$d();Object.defineProperty(Q,"ConfigGetError",{enumerable:!0,get:function(){return eE.ConfigGetError}});var tE=Ed();Object.defineProperty(Q,"InitError",{enumerable:!0,get:function(){return tE.InitError}});var rE=Qt();Object.defineProperty(Q,"ServerlessError",{enumerable:!0,get:function(){return rE.ServerlessError}});var nE=bd();Object.defineProperty(Q,"HumanError",{enumerable:!0,get:function(){return nE.HumanError}});var sE=Od();Object.defineProperty(Q,"HumanWarning",{enumerable:!0,get:function(){return sE.HumanWarning}});function La(r,e){return"".concat(jt.gray(r)).concat(jt.gray.underline(e))}var iE=function(r){return K$(void 0,void 0,void 0,function(){var e,t,n,s,i,a,c,u;return X$(this,function(o){switch(o.label){case 0:e="Message:",t={traceId:"",catchableError:!1},n=r,s=(0,ft.getConfig)("analysis"),s!=="disable"&&(t.traceId="".concat((0,ft.getPid)()).concat(Date.now())),i=r.message?r.message:"";try{a=JSON.parse(i)}catch{}return a&&a.tips?(c=a.message?"Message: ".concat(a.message,`
35
+ `):"",u=a.tips?"* ".concat(J$(a.tips.replace(/\n/,`
32
36
  * `))):"",ft.logger.log(`
33
- `.concat(Dt.hex("#000").bgYellow("WARNING:"),`
37
+ `.concat(jt.hex("#000").bgYellow("WARNING:"),`
34
38
  ======================
35
39
  `).concat(u,`
36
- `),"yellow"),ka()?console.log(r.stack):console.log(Dt.grey(c)),t.catchableError=!0,n=a,[3,5]):[3,1];case 1:return a&&a.code?(console.log((0,ft.red)("\u2716 ".concat(a.prefix||e,`
40
+ `),"yellow"),xa()?console.log(r.stack):console.log(jt.grey(c)),t.catchableError=!0,n=a,[3,5]):[3,1];case 1:return a&&a.code?(console.log((0,ft.red)("\u2716 ".concat(a.prefix||e,`
37
41
  `))),console.log("".concat((0,ft.bgRed)("ERROR:"),`
38
- `)),ka()?console.log("".concat(a.stack,`
42
+ `)),xa()?console.log("".concat(a.stack,`
39
43
  `)):console.log("".concat(a.message,`
40
44
  `)),[4,(0,ft.aiRequest)(a.message)]):[3,3];case 2:return o.sent(),n=a,[3,5];case 3:return console.log((0,ft.red)("\u2716 ".concat(e,`
41
45
  `))),console.log("".concat((0,ft.bgRed)("ERROR:"),`
42
- `)),console.log(ka()?r.stack:"".concat(i,`
43
- `)),[4,(0,ft.aiRequest)(i)];case 4:o.sent(),o.label=5;case 5:return t.catchableError||(t.traceId&&console.log(Dt.gray("TraceId: ".concat(t.traceId))),console.log(Dt.gray("Environment: ".concat((0,ft.getVersion)()))),console.log(xa("Documents: ","https://www.serverless-devs.com")),console.log(xa("Discussions: ","https://github.com/Serverless-Devs/Serverless-Devs/discussions")),console.log(xa("Issues: ",`https://github.com/Serverless-Devs/Serverless-Devs/issues
44
- `)),t.traceId&&console.log(Dt.gray("Please copy traceId: ".concat(t.traceId," and join Dingding group: 33947367 for consultation.")))),console.log(Dt.gray("You can run 's clean --all' to clean Serverless devs.")),t.traceId&&!t.catchableError?[4,z$({type:"jsError",content:"".concat(n.message,"||").concat(n.stack),traceId:t.traceId})]:[3,7];case 6:o.sent(),o.label=7;case 7:return process.exit(n.code||1),[2]}})})};Q.HandleError=tE});var Pd=exports&&exports.__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(h){a(h)}}function u(l){try{o(n.throw(l))}catch(h){a(h)}}function o(l){l.done?i(l.value):s(l.value).then(c,u)}o((n=n.apply(r,e||[])).next())})},Rd=exports&&exports.__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}}},Nn=exports&&exports.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(exports,"__esModule",{value:!0});var rE=Nn(_o()),wt=Nn(yt()),nE=Nn(ai()),Tr=li(),sE=Nn(require("path")),iE=Nn(md()),aE=Od(),La=wt.default.colors,oE=wt.default.getYamlContent,Ie=wt.default.lodash,cE=wt.default.loadComponent,uE=wt.default.fse,lE=wt.default.parseYaml,fE=wt.default.spinner,Cd=Ie.get,dE=Ie.keys,hE=Ie.omit,pE=Ie.isEmpty,mE=Ie.replace,Nd=Ie.isPlainObject,Ma=Ie.isArray,Id=Ie.each,gE=Ie.last,vE=Ie.split,_E=Ie.uniq,Ad=Ie.map,yE=Ie.concat,Td=Ie.filter,$E=`Application verification.
46
+ `)),console.log(xa()?r.stack:"".concat(i,`
47
+ `)),[4,(0,ft.aiRequest)(i)];case 4:o.sent(),o.label=5;case 5:return t.catchableError||(t.traceId&&console.log(jt.gray("TraceId: ".concat(t.traceId))),console.log(jt.gray("Environment: ".concat((0,ft.getVersion)()))),console.log(La("Documents: ","https://www.serverless-devs.com")),console.log(La("Discussions: ","https://github.com/Serverless-Devs/Serverless-Devs/discussions")),console.log(La("Issues: ",`https://github.com/Serverless-Devs/Serverless-Devs/issues
48
+ `)),t.traceId&&console.log(jt.gray("Please copy traceId: ".concat(t.traceId," and join Dingding group: 33947367 for consultation.")))),console.log(jt.gray("You can run 's clean --all' to clean Serverless devs.")),t.traceId&&!t.catchableError?[4,W$({type:"jsError",content:"".concat(n.message,"||").concat(n.stack),traceId:t.traceId})]:[3,7];case 6:o.sent(),o.label=7;case 7:return process.exit(n.code||1),[2]}})})};Q.HandleError=iE});var Rd=exports&&exports.__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(h){a(h)}}function u(l){try{o(n.throw(l))}catch(h){a(h)}}function o(l){l.done?i(l.value):s(l.value).then(c,u)}o((n=n.apply(r,e||[])).next())})},Cd=exports&&exports.__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}}},In=exports&&exports.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(exports,"__esModule",{value:!0});var aE=In(yo()),wt=In(yt()),oE=In(oi()),jr=fi(),cE=In(require("path")),uE=In(gd()),lE=Pd(),Ma=wt.default.colors,fE=wt.default.getYamlContent,Te=wt.default.lodash,dE=wt.default.loadComponent,hE=wt.default.fse,pE=wt.default.parseYaml,mE=wt.default.spinner,Nd=Te.get,gE=Te.keys,vE=Te.omit,_E=Te.isEmpty,yE=Te.replace,Id=Te.isPlainObject,Fa=Te.isArray,Td=Te.each,$E=Te.last,EE=Te.split,wE=Te.uniq,Ad=Te.map,bE=Te.concat,qd=Te.filter,SE=`Application verification.
45
49
 
46
50
  Example:
47
51
  $ s verify
48
52
 
49
- `.concat((0,Tr.emoji)("\u{1F4D6}")," Document: ").concat(La.underline("https://github.com/Serverless-Devs/Serverless-Devs/tree/master/docs/zh/command/verify.md")),EE=rE.default.name("s verify").usage("[options]").option("-t, --template [templatePath]","Specify the template file").helpOption("-h, --help",(0,nE.default)("display_help_for_command")).description($E).addHelpCommand(!1).parse(process.argv);function qd(r){var e=Ma(r)?[]:{};if(typeof r=="object"){var t=dE(r).filter(function(i){return i.startsWith("x-")}),n=hE(r,t);for(var s in n)e[s]=typeof r[s]=="object"?qd(r[s]):r[s]}else e=r;return e}function wE(r){var e=qd(r),t=[];function n(i,a){if(a===void 0&&(a=""),Nd(i)){if(i.required===!0){var c=vE(a,"."),u=c.slice(0,c.length-2).join(".");t.push({key:u,name:gE(c)})}typeof i.required=="boolean"&&delete i.required,a!==""&&(a="".concat(a,"."));for(var o in i)n(i[o],"".concat(a).concat(o))}Ma(i)&&Id(i,function(l,h){n(l,"".concat(a,"[").concat(h,"]"))})}function s(i,a){if(a===void 0&&(a=""),Nd(i)){var c=Td(t,function(l){return l.key===a});if(c.length>0){var u=Ad(c,function(l){return l.name});i.required=i.required?_E(yE(i.required,u)):u}a!==""&&(a="".concat(a,"."));for(var o in i)s(i[o],"".concat(a).concat(o))}Ma(i)&&Id(i,function(l,h){s(l,"".concat(a,"[").concat(h,"]"))})}return n(e),s(e),e}(function(){return Pd(void 0,void 0,void 0,function(){var r,e,t,n,s,i,a,c,u,o,l,h,g,v,$,E,w,b,D,A,z,C,ge,De,bt,je;return Rd(this,function(te){switch(te.label){case 0:return r=(0,Tr.getProcessArgv)(),e=r.help,t=r.template,e&&EE.help(),[4,wt.default.getTemplatePath(t)];case 1:return n=te.sent(),[4,wt.default.transforYamlPath(n)];case 2:s=te.sent(),i=uE.readFileSync(s,"utf8"),a=lE(i),c=a.services,u=[];for(o in c)l=c[o],u.push({component:l.component,props:l.props,service:o});h=[],g=0,v=u,te.label=3;case 3:return g<v.length?($=v[g],[4,cE($.component)]):[3,7];case 4:return E=te.sent(),[4,oE(sE.default.join(E.__path,"publish.yaml"))];case 5:if(w=te.sent(),b=Cd(w,"Properties",{}),pE(b.properties))return[3,6];if(D=new iE.default({strict:!1}),A=D.compile(wE(b)),z=A($.props),!z)return h.push(!0),C=A.errors,ge=Td(C,function(ke){return ke.keyword!=="oneOf"}),Tr.logger.log("".concat((0,Tr.red)("\u2716")," Format verification failed.")),De=Cd(ge,"[0].instancePath"),De&&(bt=mE(De.slice(1),/\//g,"."),Tr.logger.log("The ".concat(La.yellow(bt)," field under ").concat(La.yellow($.service),` service is incorrect.
50
- `))),je=Ad(ge,function(ke){return{message:ke.message,params:ke.params}}),Tr.logger.output(je.length>1?je:je[0]),[3,7];te.label=6;case 6:return g++,[3,3];case 7:return h.length===0&&fE("Format verification passed.").succeed(),[2]}})})})().catch(function(r){return Pd(void 0,void 0,void 0,function(){return Rd(this,function(e){switch(e.label){case 0:return[4,(0,aE.HandleError)(r)];case 1:return e.sent(),[2]}})})});
53
+ `.concat((0,jr.emoji)("\u{1F4D6}")," Document: ").concat(Ma.underline("https://github.com/Serverless-Devs/Serverless-Devs/tree/master/docs/zh/command/verify.md")),OE=aE.default.name("s verify").usage("[options]").option("-t, --template [templatePath]","Specify the template file").helpOption("-h, --help",(0,oE.default)("display_help_for_command")).description(SE).addHelpCommand(!1).parse(process.argv);function Dd(r){var e=Fa(r)?[]:{};if(typeof r=="object"){var t=gE(r).filter(function(i){return i.startsWith("x-")}),n=vE(r,t);for(var s in n)e[s]=typeof r[s]=="object"?Dd(r[s]):r[s]}else e=r;return e}function PE(r){var e=Dd(r),t=[];function n(i,a){if(a===void 0&&(a=""),Id(i)){if(i.required===!0){var c=EE(a,"."),u=c.slice(0,c.length-2).join(".");t.push({key:u,name:$E(c)})}typeof i.required=="boolean"&&delete i.required,a!==""&&(a="".concat(a,"."));for(var o in i)n(i[o],"".concat(a).concat(o))}Fa(i)&&Td(i,function(l,h){n(l,"".concat(a,"[").concat(h,"]"))})}function s(i,a){if(a===void 0&&(a=""),Id(i)){var c=qd(t,function(l){return l.key===a});if(c.length>0){var u=Ad(c,function(l){return l.name});i.required=i.required?wE(bE(i.required,u)):u}a!==""&&(a="".concat(a,"."));for(var o in i)s(i[o],"".concat(a).concat(o))}Fa(i)&&Td(i,function(l,h){s(l,"".concat(a,"[").concat(h,"]"))})}return n(e),s(e),e}(function(){return Rd(void 0,void 0,void 0,function(){var r,e,t,n,s,i,a,c,u,o,l,h,g,v,$,E,w,b,D,T,z,N,ge,je,bt,ke;return Cd(this,function(te){switch(te.label){case 0:return r=(0,jr.getProcessArgv)(),e=r.help,t=r.template,e&&OE.help(),[4,wt.default.getTemplatePath(t)];case 1:return n=te.sent(),[4,wt.default.transforYamlPath(n)];case 2:s=te.sent(),i=hE.readFileSync(s,"utf8"),a=pE(i),c=a.services,u=[];for(o in c)l=c[o],u.push({component:l.component,props:l.props,service:o});h=[],g=0,v=u,te.label=3;case 3:return g<v.length?($=v[g],[4,dE($.component)]):[3,7];case 4:return E=te.sent(),[4,fE(cE.default.join(E.__path,"publish.yaml"))];case 5:if(w=te.sent(),b=Nd(w,"Properties",{}),_E(b.properties))return[3,6];if(D=new uE.default({strict:!1}),T=D.compile(PE(b)),z=T($.props),!z)return h.push(!0),N=T.errors,ge=qd(N,function(xe){return xe.keyword!=="oneOf"}),jr.logger.log("".concat((0,jr.red)("\u2716")," Format verification failed.")),je=Nd(ge,"[0].instancePath"),je&&(bt=yE(je.slice(1),/\//g,"."),jr.logger.log("The ".concat(Ma.yellow(bt)," field under ").concat(Ma.yellow($.service),` service is incorrect.
54
+ `))),ke=Ad(ge,function(xe){return{message:xe.message,params:xe.params}}),jr.logger.output(ke.length>1?ke:ke[0]),[3,7];te.label=6;case 6:return g++,[3,3];case 7:return h.length===0&&mE("Format verification passed.").succeed(),[2]}})})})().catch(function(r){return Rd(void 0,void 0,void 0,function(){return Cd(this,function(e){switch(e.label){case 0:return[4,(0,lE.HandleError)(r)];case 1:return e.sent(),[2]}})})});
51
55
  /** @license URI.js v4.4.1 (c) 2011 Gary Court. License: http://github.com/garycourt/uri-js */