@techdocs/cli 1.11.5-next.1 → 1.11.5-next.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (37) hide show
  1. package/CHANGELOG.md +9 -0
  2. package/dist/embedded-app/.config-schema.json +46 -46
  3. package/dist/embedded-app/index.html +1 -1
  4. package/dist/embedded-app/index.html.tmpl +1 -1
  5. package/dist/embedded-app/static/{123.449f4a83fd2b.chunk.js → 123.580aa7a9bfda.chunk.js} +2 -2
  6. package/dist/embedded-app/static/{123.449f4a83fd2b.chunk.js.map → 123.580aa7a9bfda.chunk.js.map} +1 -1
  7. package/dist/embedded-app/static/{1659.41bf35e59592.chunk.js → 1659.4dc5ef343178.chunk.js} +2 -2
  8. package/dist/embedded-app/static/{1659.41bf35e59592.chunk.js.map → 1659.4dc5ef343178.chunk.js.map} +1 -1
  9. package/dist/embedded-app/static/{1749.75c83d8a41f6.chunk.js → 1749.fcf12bbab446.chunk.js} +2 -2
  10. package/dist/embedded-app/static/{1749.75c83d8a41f6.chunk.js.map → 1749.fcf12bbab446.chunk.js.map} +1 -1
  11. package/dist/embedded-app/static/{1994.78042a47b6c6.chunk.js → 1994.9de2967d46a1.chunk.js} +2 -2
  12. package/dist/embedded-app/static/{1994.78042a47b6c6.chunk.js.map → 1994.9de2967d46a1.chunk.js.map} +1 -1
  13. package/dist/embedded-app/static/{2055.fd3ccf91ac47.chunk.js → 2055.d938e6121e5f.chunk.js} +4 -4
  14. package/dist/embedded-app/static/2055.d938e6121e5f.chunk.js.map +1 -0
  15. package/dist/embedded-app/static/{2295.e8be8ba6c18d.chunk.js → 2295.0f797d8c2780.chunk.js} +3 -3
  16. package/dist/embedded-app/static/{2295.e8be8ba6c18d.chunk.js.map → 2295.0f797d8c2780.chunk.js.map} +1 -1
  17. package/dist/embedded-app/static/{2360.82e9c38bff17.chunk.js → 2360.c56e85f47e34.chunk.js} +2 -2
  18. package/dist/embedded-app/static/{2360.82e9c38bff17.chunk.js.map → 2360.c56e85f47e34.chunk.js.map} +1 -1
  19. package/dist/embedded-app/static/{4648.c047b78345c6.chunk.js → 4648.8a54a9ce4e70.chunk.js} +2 -2
  20. package/dist/embedded-app/static/{4648.c047b78345c6.chunk.js.map → 4648.8a54a9ce4e70.chunk.js.map} +1 -1
  21. package/dist/embedded-app/static/{7203.6e3ffa800885.chunk.js → 6138.a55572f5ecc5.chunk.js} +2 -2
  22. package/dist/embedded-app/static/{6138.113ed7a1d8cd.chunk.js.map → 6138.a55572f5ecc5.chunk.js.map} +1 -1
  23. package/dist/embedded-app/static/{6138.113ed7a1d8cd.chunk.js → 7203.16b8799346fa.chunk.js} +2 -2
  24. package/dist/embedded-app/static/{9050.0c0d51ee0fd8.chunk.js.map → 7203.16b8799346fa.chunk.js.map} +1 -1
  25. package/dist/embedded-app/static/{9050.0c0d51ee0fd8.chunk.js → 9050.093f683d75b8.chunk.js} +2 -2
  26. package/dist/embedded-app/static/{7203.6e3ffa800885.chunk.js.map → 9050.093f683d75b8.chunk.js.map} +1 -1
  27. package/dist/embedded-app/static/{9230.ba752de28896.chunk.js → 9230.1a571175884d.chunk.js} +2 -2
  28. package/dist/embedded-app/static/{9230.ba752de28896.chunk.js.map → 9230.1a571175884d.chunk.js.map} +1 -1
  29. package/dist/embedded-app/static/main.3b7e5948ec11.js +2 -0
  30. package/dist/embedded-app/static/main.3b7e5948ec11.js.map +1 -0
  31. package/dist/embedded-app/static/{runtime.c8854f4ed6f8.js → runtime.304ce6fa8de1.js} +2 -2
  32. package/dist/embedded-app/static/{runtime.c8854f4ed6f8.js.map → runtime.304ce6fa8de1.js.map} +1 -1
  33. package/dist/package.json.cjs.js +1 -1
  34. package/package.json +5 -5
  35. package/dist/embedded-app/static/2055.fd3ccf91ac47.chunk.js.map +0 -1
  36. package/dist/embedded-app/static/main.82ddbc06e504.js +0 -2
  37. package/dist/embedded-app/static/main.82ddbc06e504.js.map +0 -1
@@ -1,8 +1,8 @@
1
- "use strict";(self.webpackChunktechdocs_cli_embedded_app=self.webpackChunktechdocs_cli_embedded_app||[]).push([["2055"],{67156(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(11601),s=r(17898),i=r(83277),n=r(96223),o=r(49409),l=r(63036),d="errorMessage",u=new a.Name("emUsed"),c={required:"missingProperty",dependencies:"property",dependentRequired:"property"},h=/\$\{[^}]+\}/,p=/\$\{([^}]+)\}/g,f=/^""\s*\+\s*|\s*\+\s*""$/g,m=(e,t={})=>{if(!e.opts.allErrors)throw Error("ajv-errors: Ajv option allErrors must be true");if(e.opts.jsPropertySyntax)throw Error("ajv-errors: ajv option jsPropertySyntax is not supported");return e.addKeyword({keyword:d,schemaType:["string","object"],post:!0,code(e){let{gen:r,data:m,schema:y,schemaValue:g,it:v}=e;if(!1===v.createErrors)return;let _=s.strConcat(l.default.instancePath,v.errorPath);function $(e,t){return s.and(a._`${e}.keyword !== ${d}`,a._`!${e}.${u}`,a._`${e}.instancePath === ${_}`,a._`${e}.keyword in ${t}`,a._`${e}.schemaPath.indexOf(${v.errSchemaPath}) === 0`,a._`/^\\/[^\\/]*$/.test(${e}.schemaPath.slice(${v.errSchemaPath.length}))`)}function b(e,t){let s=[];for(let r in e){var i;let e=t[r];h.test(e)&&s.push([r,(i=e,a._`function(){return ${w(i)}}`)])}return r.object(...s)}function w(e){return h.test(e)?new i._Code(i.safeStringify(e).replace(p,(e,t)=>`" + JSON.stringify(${n.getData(t,v)}) + "`).replace(f,"")):a.stringify(e)}r.if(a._`${l.default.errors} > 0`,()=>{var i;let n,h;if("object"==typeof y){let[i,n]=function(e){let t,r;for(let a in e){if("properties"===a||"items"===a)continue;let s=e[a];if("object"==typeof s){t||(t={});let e=t[a]={};for(let t in s)e[t]=[]}else r||(r={}),r[a]=[]}return[t,r]}(y);n&&function(s){let i=r.const("emErrors",a.stringify(s)),n=r.const("templates",b(s,y));r.forOf("err",l.default.vErrors,e=>r.if($(e,i),()=>r.code(a._`${i}[${e}.keyword].push(${e})`).assign(a._`${e}.${u}`,!0)));let{singleError:d}=t;if(d){let t=r.let("message",a._`""`),s=r.let("paramsErrors",a._`[]`);c(e=>{r.if(t,()=>r.code(a._`${t} += ${"string"==typeof d?d:";"}`)),r.code(a._`${t} += ${h(e)}`),r.assign(s,a._`${s}.concat(${i}[${e}])`)}),o.reportError(e,{message:t,params:a._`{errors: ${s}}`})}else c(t=>o.reportError(e,{message:h(t),params:a._`{errors: ${i}[${t}]}`}));function c(e){r.forIn("key",i,t=>r.if(a._`${i}[${t}].length`,()=>e(t)))}function h(e){return a._`${e} in ${n} ? ${n}[${e}]() : ${g}[${e}]`}}(n),i&&function(t){let s=r.const("emErrors",a.stringify(t)),i=[];for(let e in t)i.push([e,b(t[e],y[e])]);let n=r.const("templates",r.object(...i)),d=r.scopeValue("obj",{ref:c,code:a.stringify(c)}),h=r.let("emPropParams"),p=r.let("emParamsErrors");r.forOf("err",l.default.vErrors,e=>r.if($(e,s),()=>{r.assign(h,a._`${d}[${e}.keyword]`),r.assign(p,a._`${s}[${e}.keyword][${e}.params[${h}]]`),r.if(p,()=>r.code(a._`${p}.push(${e})`).assign(a._`${e}.${u}`,!0))})),r.forIn("key",s,t=>r.forIn("keyProp",a._`${s}[${t}]`,i=>{r.assign(p,a._`${s}[${t}][${i}]`),r.if(a._`${p}.length`,()=>{let s=r.const("tmpl",a._`${n}[${t}] && ${n}[${t}][${i}]`);o.reportError(e,{message:a._`${s} ? ${s}() : ${g}[${t}][${i}]`,params:a._`{errors: ${p}}`})})}))}(i),function(t){let i,n,{props:c,items:h}=t;if(!c&&!h)return;let p=a._`typeof ${m} == "object"`,f=a._`Array.isArray(${m})`,v=r.let("emErrors"),$=r.let("templates");function w(e,t){r.assign(v,a.stringify(e)),r.assign($,b(e,t))}c&&h?(i=r.let("emChildKwd"),r.if(p),r.if(f,()=>{w(h,y.items),r.assign(i,a.str`items`)},()=>{w(c,y.properties),r.assign(i,a.str`properties`)}),n=a._`[${i}]`):h?(r.if(f),w(h,y.items),n=a._`.items`):c&&(r.if(s.and(p,s.not(f))),w(c,y.properties),n=a._`.properties`),r.forOf("err",l.default.vErrors,e=>{var t,i,n;return t=e,i=v,n=t=>r.code(a._`${v}[${t}].push(${e})`).assign(a._`${e}.${u}`,!0),void r.if(s.and(a._`${t}.keyword !== ${d}`,a._`!${t}.${u}`,a._`${t}.instancePath.indexOf(${_}) === 0`),()=>{let e=r.scopeValue("pattern",{ref:/^\/([^/]*)(?:\/|$)/,code:a._`new RegExp("^\\\/([^/]*)(?:\\\/|$)")`}),s=r.const("emMatches",a._`${e}.exec(${t}.instancePath.slice(${_}.length))`),o=r.const("emChild",a._`${s} && ${s}[1].replace(/~1/g, "/").replace(/~0/g, "~")`);r.if(a._`${o} !== undefined && ${o} in ${i}`,()=>n(o))})}),r.forIn("key",v,t=>r.if(a._`${v}[${t}].length`,()=>{o.reportError(e,{message:a._`${t} in ${$} ? ${$}[${t}]() : ${g}${n}[${t}]`,params:a._`{errors: ${v}[${t}]}`}),r.assign(a._`${l.default.vErrors}[${l.default.errors}-1].instancePath`,a._`${_} + "/" + ${t}.replace(/~/g, "~0").replace(/\\//g, "~1")`)})),r.endIf()}(function({properties:e,items:t}){let r={};if(e)for(let t in r.props={},e)r.props[t]=[];if(t){r.items={};for(let e=0;e<t.length;e++)r.items[e]=[]}return r}(y))}let p="string"==typeof y?y:y._;p&&(i=p,n=r.const("emErrs",a._`[]`),r.forOf("err",l.default.vErrors,e=>{var t;return r.if((t=e,s.and(a._`${t}.keyword !== ${d}`,a._`!${t}.${u}`,s.or(a._`${t}.instancePath === ${_}`,s.and(a._`${t}.instancePath.indexOf(${_}) === 0`,a._`${t}.instancePath[${_}.length] === "/"`)),a._`${t}.schemaPath.indexOf(${v.errSchemaPath}) === 0`,a._`${t}.schemaPath[${v.errSchemaPath}.length] === "/"`)),()=>r.code(a._`${n}.push(${e})`).assign(a._`${e}.${u}`,!0))}),r.if(a._`${n}.length`,()=>o.reportError(e,{message:w(i),params:a._`{errors: ${n}}`}))),t.keepErrors||(h=r.const("emErrs",a._`[]`),r.forOf("err",l.default.vErrors,e=>r.if(a._`!${e}.${u}`,()=>r.code(a._`${h}.push(${e})`))),r.assign(l.default.vErrors,h).assign(l.default.errors,a._`${h}.length`))})},metaSchema:{anyOf:[{type:"string"},{type:"object",properties:{properties:{$ref:"#/$defs/stringMap"},items:{$ref:"#/$defs/stringList"},required:{$ref:"#/$defs/stringOrMap"},dependencies:{$ref:"#/$defs/stringOrMap"}},additionalProperties:{type:"string"}}],$defs:{stringMap:{type:"object",additionalProperties:{type:"string"}},stringOrMap:{anyOf:[{type:"string"},{$ref:"#/$defs/stringMap"}]},stringList:{type:"array",items:{type:"string"}}}}})};t.default=m,e.exports=m,e.exports.default=m},11601(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.MissingRefError=t.ValidationError=t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=t.Ajv=void 0;let a=r(65319),s=r(2431),i=r(11672),n=r(33928),o=["/properties"],l="http://json-schema.org/draft-07/schema";class d extends a.default{_addVocabularies(){super._addVocabularies(),s.default.forEach(e=>this.addVocabulary(e)),this.opts.discriminator&&this.addKeyword(i.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;let e=this.opts.$data?this.$dataMetaSchema(n,o):n;this.addMetaSchema(e,l,!1),this.refs["http://json-schema.org/schema"]=l}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(l)?l:void 0)}}t.Ajv=d,e.exports=t=d,e.exports.Ajv=d,Object.defineProperty(t,"__esModule",{value:!0}),t.default=d;var u=r(96223);Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return u.KeywordCxt}});var c=r(17898);Object.defineProperty(t,"_",{enumerable:!0,get:function(){return c._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return c.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return c.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return c.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return c.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return c.CodeGen}});var h=r(95031);Object.defineProperty(t,"ValidationError",{enumerable:!0,get:function(){return h.default}});var p=r(85748);Object.defineProperty(t,"MissingRefError",{enumerable:!0,get:function(){return p.default}})},83277(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.regexpCode=t.getEsmExportName=t.getProperty=t.safeStringify=t.stringify=t.strConcat=t.addCodeArg=t.str=t._=t.nil=t._Code=t.Name=t.IDENTIFIER=t._CodeOrName=void 0;class r{}t._CodeOrName=r,t.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;class a extends r{constructor(e){if(super(),!t.IDENTIFIER.test(e))throw Error("CodeGen: name must be a valid identifier");this.str=e}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}}t.Name=a;class s extends r{constructor(e){super(),this._items="string"==typeof e?[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 null!=(e=this._str)?e:this._str=this._items.reduce((e,t)=>`${e}${t}`,"")}get names(){var e;return null!=(e=this._names)?e:this._names=this._items.reduce((e,t)=>(t instanceof a&&(e[t.str]=(e[t.str]||0)+1),e),{})}}function i(e,...t){let r=[e[0]],a=0;for(;a<t.length;)l(r,t[a]),r.push(e[++a]);return new s(r)}t._Code=s,t.nil=new s(""),t._=i;let n=new s("+");function o(e,...t){let r=[d(e[0])],i=0;for(;i<t.length;)r.push(n),l(r,t[i]),r.push(n,d(e[++i]));return function(e){let t=1;for(;t<e.length-1;){if(e[t]===n){var r,s;let i=(r=e[t-1],'""'===(s=e[t+1])?r:'""'===r?s:"string"==typeof r?s instanceof a||'"'!==r[r.length-1]?void 0:"string"!=typeof s?`${r.slice(0,-1)}${s}"`:'"'===s[0]?r.slice(0,-1)+s.slice(1):void 0:"string"!=typeof s||'"'!==s[0]||r instanceof a?void 0:`"${r}${s.slice(1)}`);if(void 0!==i){e.splice(t-1,3,i);continue}e[t++]="+"}t++}}(r),new s(r)}function l(e,t){var r;t instanceof s?e.push(...t._items):t instanceof a?e.push(t):e.push("number"==typeof(r=t)||"boolean"==typeof r||null===r?r:d(Array.isArray(r)?r.join(","):r))}function d(e){return JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}t.str=o,t.addCodeArg=l,t.strConcat=function(e,t){return t.emptyStr()?e:e.emptyStr()?t:o`${e}${t}`},t.stringify=function(e){return new s(d(e))},t.safeStringify=d,t.getProperty=function(e){return"string"==typeof e&&t.IDENTIFIER.test(e)?new s(`.${e}`):i`[${e}]`},t.getEsmExportName=function(e){if("string"==typeof e&&t.IDENTIFIER.test(e))return new s(`${e}`);throw Error(`CodeGen: invalid export name: ${e}, use explicit $id name mapping`)},t.regexpCode=function(e){return new s(e.toString())}},17898(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.or=t.and=t.not=t.CodeGen=t.operators=t.varKinds=t.ValueScopeName=t.ValueScope=t.Scope=t.Name=t.regexpCode=t.stringify=t.getProperty=t.nil=t.strConcat=t.str=t._=void 0;let a=r(83277),s=r(76930);var i=r(83277);Object.defineProperty(t,"_",{enumerable:!0,get:function(){return i._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return i.str}}),Object.defineProperty(t,"strConcat",{enumerable:!0,get:function(){return i.strConcat}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return i.nil}}),Object.defineProperty(t,"getProperty",{enumerable:!0,get:function(){return i.getProperty}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return i.stringify}}),Object.defineProperty(t,"regexpCode",{enumerable:!0,get:function(){return i.regexpCode}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return i.Name}});var n=r(76930);Object.defineProperty(t,"Scope",{enumerable:!0,get:function(){return n.Scope}}),Object.defineProperty(t,"ValueScope",{enumerable:!0,get:function(){return n.ValueScope}}),Object.defineProperty(t,"ValueScopeName",{enumerable:!0,get:function(){return n.ValueScopeName}}),Object.defineProperty(t,"varKinds",{enumerable:!0,get:function(){return n.varKinds}}),t.operators={GT:new a._Code(">"),GTE:new a._Code(">="),LT:new a._Code("<"),LTE:new a._Code("<="),EQ:new a._Code("==="),NEQ:new a._Code("!=="),NOT:new a._Code("!"),OR:new a._Code("||"),AND:new a._Code("&&"),ADD:new a._Code("+")};class o{optimizeNodes(){return this}optimizeNames(e,t){return this}}class l extends o{constructor(e,t,r){super(),this.varKind=e,this.name=t,this.rhs=r}render({es5:e,_n:t}){let r=e?s.varKinds.var:this.varKind,a=void 0===this.rhs?"":` = ${this.rhs}`;return`${r} ${this.name}${a};`+t}optimizeNames(e,t){if(e[this.name.str])return this.rhs&&(this.rhs=T(this.rhs,e,t)),this}get names(){return this.rhs instanceof a._CodeOrName?this.rhs.names:{}}}class d extends o{constructor(e,t,r){super(),this.lhs=e,this.rhs=t,this.sideEffects=r}render({_n:e}){return`${this.lhs} = ${this.rhs};`+e}optimizeNames(e,t){if(!(this.lhs instanceof a.Name)||e[this.lhs.str]||this.sideEffects)return this.rhs=T(this.rhs,e,t),this}get names(){return O(this.lhs instanceof a.Name?{}:{...this.lhs.names},this.rhs)}}class u extends d{constructor(e,t,r,a){super(e,r,a),this.op=t}render({_n:e}){return`${this.lhs} ${this.op}= ${this.rhs};`+e}}class c extends o{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){return`${this.label}:`+e}}class h extends o{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){let t=this.label?` ${this.label}`:"";return`break${t};`+e}}class p extends o{constructor(e){super(),this.error=e}render({_n:e}){return`throw ${this.error};`+e}get names(){return this.error.names}}class f extends o{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=T(this.code,e,t),this}get names(){return this.code instanceof a._CodeOrName?this.code.names:{}}}class m extends o{constructor(e=[]){super(),this.nodes=e}render(e){return this.nodes.reduce((t,r)=>t+r.render(e),"")}optimizeNodes(){let{nodes:e}=this,t=e.length;for(;t--;){let r=e[t].optimizeNodes();Array.isArray(r)?e.splice(t,1,...r):r?e[t]=r:e.splice(t,1)}return e.length>0?this:void 0}optimizeNames(e,t){let{nodes:r}=this,a=r.length;for(;a--;){let s=r[a];s.optimizeNames(e,t)||(function(e,t){for(let r in t)e[r]=(e[r]||0)-(t[r]||0)}(e,s.names),r.splice(a,1))}return r.length>0?this:void 0}get names(){return this.nodes.reduce((e,t)=>N(e,t.names),{})}}class y extends m{render(e){return"{"+e._n+super.render(e)+"}"+e._n}}class g extends m{}class v extends y{}v.kind="else";class _ extends y{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(!0===e)return this.nodes;let t=this.else;if(t){let e=t.optimizeNodes();t=this.else=Array.isArray(e)?new v(e):e}return t?!1===e?t instanceof _?t:t.nodes:this.nodes.length?this:new _(C(e),t instanceof _?[t]:t.nodes):!1!==e&&this.nodes.length?this:void 0}optimizeNames(e,t){var r;if(this.else=null==(r=this.else)?void 0:r.optimizeNames(e,t),super.optimizeNames(e,t)||this.else)return this.condition=T(this.condition,e,t),this}get names(){let e=super.names;return O(e,this.condition),this.else&&N(e,this.else.names),e}}_.kind="if";class $ extends y{}$.kind="for";class b extends ${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=T(this.iteration,e,t),this}get names(){return N(super.names,this.iteration.names)}}class w extends ${constructor(e,t,r,a){super(),this.varKind=e,this.name=t,this.from=r,this.to=a}render(e){let t=e.es5?s.varKinds.var:this.varKind,{name:r,from:a,to:i}=this;return`for(${t} ${r}=${a}; ${r}<${i}; ${r}++)`+super.render(e)}get names(){let e=O(super.names,this.from);return O(e,this.to)}}class k extends ${constructor(e,t,r,a){super(),this.loop=e,this.varKind=t,this.name=r,this.iterable=a}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=T(this.iterable,e,t),this}get names(){return N(super.names,this.iterable.names)}}class x extends y{constructor(e,t,r){super(),this.name=e,this.args=t,this.async=r}render(e){let t=this.async?"async ":"";return`${t}function ${this.name}(${this.args})`+super.render(e)}}x.kind="func";class P extends m{render(e){return"return "+super.render(e)}}P.kind="return";class S extends y{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(),null==(e=this.catch)||e.optimizeNodes(),null==(t=this.finally)||t.optimizeNodes(),this}optimizeNames(e,t){var r,a;return super.optimizeNames(e,t),null==(r=this.catch)||r.optimizeNames(e,t),null==(a=this.finally)||a.optimizeNames(e,t),this}get names(){let e=super.names;return this.catch&&N(e,this.catch.names),this.finally&&N(e,this.finally.names),e}}class E extends y{constructor(e){super(),this.error=e}render(e){return`catch(${this.error})`+super.render(e)}}E.kind="catch";class j extends y{render(e){return"finally"+super.render(e)}}function N(e,t){for(let r in t)e[r]=(e[r]||0)+(t[r]||0);return e}function O(e,t){return t instanceof a._CodeOrName?N(e,t.names):e}function T(e,t,r){var s;if(e instanceof a.Name)return i(e);if(!((s=e)instanceof a._Code&&s._items.some(e=>e instanceof a.Name&&1===t[e.str]&&void 0!==r[e.str])))return e;return new a._Code(e._items.reduce((e,t)=>(t instanceof a.Name&&(t=i(t)),t instanceof a._Code?e.push(...t._items):e.push(t),e),[]));function i(e){let a=r[e.str];return void 0===a||1!==t[e.str]?e:(delete t[e.str],a)}}function C(e){return"boolean"==typeof e||"number"==typeof e||null===e?!e:(0,a._)`!${Z(e)}`}j.kind="finally",t.CodeGen=class{constructor(e,t={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...t,_n:t.lines?"\n":""},this._extScope=e,this._scope=new s.Scope({parent:e}),this._nodes=[new g]}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 r=this._extScope.value(e,t);return(this._values[r.prefix]||(this._values[r.prefix]=new Set)).add(r),r}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,r,a){let s=this._scope.toName(t);return void 0!==r&&a&&(this._constants[s.str]=r),this._leafNode(new l(e,s,r)),s}const(e,t,r){return this._def(s.varKinds.const,e,t,r)}let(e,t,r){return this._def(s.varKinds.let,e,t,r)}var(e,t,r){return this._def(s.varKinds.var,e,t,r)}assign(e,t,r){return this._leafNode(new d(e,t,r))}add(e,r){return this._leafNode(new u(e,t.operators.ADD,r))}code(e){return"function"==typeof e?e():e!==a.nil&&this._leafNode(new f(e)),this}object(...e){let t=["{"];for(let[r,s]of e)t.length>1&&t.push(","),t.push(r),(r!==s||this.opts.es5)&&(t.push(":"),(0,a.addCodeArg)(t,s));return t.push("}"),new a._Code(t)}if(e,t,r){if(this._blockNode(new _(e)),t&&r)this.code(t).else().code(r).endIf();else if(t)this.code(t).endIf();else if(r)throw Error('CodeGen: "else" body without "then" body');return this}elseIf(e){return this._elseNode(new _(e))}else(){return this._elseNode(new v)}endIf(){return this._endBlockNode(_,v)}_for(e,t){return this._blockNode(e),t&&this.code(t).endFor(),this}for(e,t){return this._for(new b(e),t)}forRange(e,t,r,a,i=this.opts.es5?s.varKinds.var:s.varKinds.let){let n=this._scope.toName(e);return this._for(new w(i,n,t,r),()=>a(n))}forOf(e,t,r,i=s.varKinds.const){let n=this._scope.toName(e);if(this.opts.es5){let e=t instanceof a.Name?t:this.var("_arr",t);return this.forRange("_i",0,(0,a._)`${e}.length`,t=>{this.var(n,(0,a._)`${e}[${t}]`),r(n)})}return this._for(new k("of",i,n,t),()=>r(n))}forIn(e,t,r,i=this.opts.es5?s.varKinds.var:s.varKinds.const){if(this.opts.ownProperties)return this.forOf(e,(0,a._)`Object.keys(${t})`,r);let n=this._scope.toName(e);return this._for(new k("in",i,n,t),()=>r(n))}endFor(){return this._endBlockNode($)}label(e){return this._leafNode(new c(e))}break(e){return this._leafNode(new h(e))}return(e){let t=new P;if(this._blockNode(t),this.code(e),1!==t.nodes.length)throw Error('CodeGen: "return" should have one node');return this._endBlockNode(P)}try(e,t,r){if(!t&&!r)throw Error('CodeGen: "try" without "catch" and "finally"');let a=new S;if(this._blockNode(a),this.code(e),t){let e=this.name("e");this._currNode=a.catch=new E(e),t(e)}return r&&(this._currNode=a.finally=new j,this.code(r)),this._endBlockNode(E,j)}throw(e){return this._leafNode(new p(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(void 0===t)throw Error("CodeGen: not in self-balancing block");let r=this._nodes.length-t;if(r<0||void 0!==e&&r!==e)throw Error(`CodeGen: wrong number of nodes: ${r} vs ${e} expected`);return this._nodes.length=t,this}func(e,t=a.nil,r,s){return this._blockNode(new x(e,t,r)),s&&this.code(s).endFunc(),this}endFunc(){return this._endBlockNode(x)}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 r=this._currNode;if(r instanceof e||t&&r instanceof t)return this._nodes.pop(),this;throw Error(`CodeGen: not in block "${t?`${e.kind}/${t.kind}`:e.kind}"`)}_elseNode(e){let t=this._currNode;if(!(t instanceof _))throw 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}},t.not=C;let R=A(t.operators.AND);t.and=function(...e){return e.reduce(R)};let I=A(t.operators.OR);function A(e){return(t,r)=>t===a.nil?r:r===a.nil?t:(0,a._)`${Z(t)} ${e} ${Z(r)}`}function Z(e){return e instanceof a.Name?e:(0,a._)`(${e})`}t.or=function(...e){return e.reduce(I)}},76930(e,t,r){var a,s;Object.defineProperty(t,"__esModule",{value:!0}),t.ValueScope=t.ValueScopeName=t.Scope=t.varKinds=t.UsedValueState=void 0;let i=r(83277);class n extends Error{constructor(e){super(`CodeGen: "code" for ${e} not defined`),this.value=e.value}}(s=a||(t.UsedValueState=a={}))[s.Started=0]="Started",s[s.Completed=1]="Completed",t.varKinds={const:new i.Name("const"),let:new i.Name("let"),var:new i.Name("var")};class o{constructor({prefixes:e,parent:t}={}){this._names={},this._prefixes=e,this._parent=t}toName(e){return e instanceof i.Name?e:this.name(e)}name(e){return new i.Name(this._newName(e))}_newName(e){let t=this._names[e]||this._nameGroup(e);return`${e}${t.index++}`}_nameGroup(e){var t,r;if((null==(r=null==(t=this._parent)?void 0:t._prefixes)?void 0:r.has(e))||this._prefixes&&!this._prefixes.has(e))throw Error(`CodeGen: prefix "${e}" is not allowed in this scope`);return this._names[e]={prefix:e,index:0}}}t.Scope=o;class l extends i.Name{constructor(e,t){super(t),this.prefix=e}setValue(e,{property:t,itemIndex:r}){this.value=e,this.scopePath=(0,i._)`.${new i.Name(t)}[${r}]`}}t.ValueScopeName=l;let d=(0,i._)`\n`;t.ValueScope=class extends o{constructor(e){super(e),this._values={},this._scope=e.scope,this.opts={...e,_n:e.lines?d:i.nil}}get(){return this._scope}name(e){return new l(e,this._newName(e))}value(e,t){var r;if(void 0===t.ref)throw Error("CodeGen: ref must be passed in value");let a=this.toName(e),{prefix:s}=a,i=null!=(r=t.key)?r:t.ref,n=this._values[s];if(n){let e=n.get(i);if(e)return e}else n=this._values[s]=new Map;n.set(i,a);let o=this._scope[s]||(this._scope[s]=[]),l=o.length;return o[l]=t.ref,a.setValue(t,{property:s,itemIndex:l}),a}getValue(e,t){let r=this._values[e];if(r)return r.get(t)}scopeRefs(e,t=this._values){return this._reduceValues(t,t=>{if(void 0===t.scopePath)throw Error(`CodeGen: name "${t}" has no value`);return(0,i._)`${e}${t.scopePath}`})}scopeCode(e=this._values,t,r){return this._reduceValues(e,e=>{if(void 0===e.value)throw Error(`CodeGen: name "${e}" has no value`);return e.value.code},t,r)}_reduceValues(e,r,s={},o){let l=i.nil;for(let d in e){let u=e[d];if(!u)continue;let c=s[d]=s[d]||new Map;u.forEach(e=>{if(c.has(e))return;c.set(e,a.Started);let s=r(e);if(s){let r=this.opts.es5?t.varKinds.var:t.varKinds.const;l=(0,i._)`${l}${r} ${e} = ${s};${this.opts._n}`}else if(s=null==o?void 0:o(e))l=(0,i._)`${l}${s}${this.opts._n}`;else throw new n(e);c.set(e,a.Completed)})}return l}}},49409(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.extendErrors=t.resetErrorsCount=t.reportExtraError=t.reportError=t.keyword$DataError=t.keywordError=void 0;let a=r(17898),s=r(50458),i=r(63036);function n(e,t){let r=e.const("err",t);e.if((0,a._)`${i.default.vErrors} === null`,()=>e.assign(i.default.vErrors,(0,a._)`[${r}]`),(0,a._)`${i.default.vErrors}.push(${r})`),e.code((0,a._)`${i.default.errors}++`)}function o(e,t){let{gen:r,validateName:s,schemaEnv:i}=e;i.$async?r.throw((0,a._)`new ${e.ValidationError}(${t})`):(r.assign((0,a._)`${s}.errors`,t),r.return(!1))}t.keywordError={message:({keyword:e})=>(0,a.str)`must pass "${e}" keyword validation`},t.keyword$DataError={message:({keyword:e,schemaType:t})=>t?(0,a.str)`"${e}" keyword must be ${t} ($data)`:(0,a.str)`"${e}" keyword is invalid ($data)`},t.reportError=function(e,r=t.keywordError,s,i){let{it:l}=e,{gen:u,compositeRule:c,allErrors:h}=l,p=d(e,r,s);(null!=i?i:c||h)?n(u,p):o(l,(0,a._)`[${p}]`)},t.reportExtraError=function(e,r=t.keywordError,a){let{it:s}=e,{gen:l,compositeRule:u,allErrors:c}=s;n(l,d(e,r,a)),u||c||o(s,i.default.vErrors)},t.resetErrorsCount=function(e,t){e.assign(i.default.errors,t),e.if((0,a._)`${i.default.vErrors} !== null`,()=>e.if(t,()=>e.assign((0,a._)`${i.default.vErrors}.length`,t),()=>e.assign(i.default.vErrors,null)))},t.extendErrors=function({gen:e,keyword:t,schemaValue:r,data:s,errsCount:n,it:o}){if(void 0===n)throw Error("ajv implementation error");let l=e.name("err");e.forRange("i",n,i.default.errors,n=>{e.const(l,(0,a._)`${i.default.vErrors}[${n}]`),e.if((0,a._)`${l}.instancePath === undefined`,()=>e.assign((0,a._)`${l}.instancePath`,(0,a.strConcat)(i.default.instancePath,o.errorPath))),e.assign((0,a._)`${l}.schemaPath`,(0,a.str)`${o.errSchemaPath}/${t}`),o.opts.verbose&&(e.assign((0,a._)`${l}.schema`,r),e.assign((0,a._)`${l}.data`,s))})};let l={keyword:new a.Name("keyword"),schemaPath:new a.Name("schemaPath"),params:new a.Name("params"),propertyName:new a.Name("propertyName"),message:new a.Name("message"),schema:new a.Name("schema"),parentSchema:new a.Name("parentSchema")};function d(e,t,r){let{createErrors:n}=e.it;return!1===n?(0,a._)`{}`:function(e,t,r={}){let{gen:n,it:o}=e,d=[function({errorPath:e},{instancePath:t}){let r=t?(0,a.str)`${e}${(0,s.getErrorPath)(t,s.Type.Str)}`:e;return[i.default.instancePath,(0,a.strConcat)(i.default.instancePath,r)]}(o,r),function({keyword:e,it:{errSchemaPath:t}},{schemaPath:r,parentSchema:i}){let n=i?t:(0,a.str)`${t}/${e}`;return r&&(n=(0,a.str)`${n}${(0,s.getErrorPath)(r,s.Type.Str)}`),[l.schemaPath,n]}(e,r)];return function(e,{params:t,message:r},s){let{keyword:n,data:o,schemaValue:d,it:u}=e,{opts:c,propertyName:h,topSchemaRef:p,schemaPath:f}=u;s.push([l.keyword,n],[l.params,"function"==typeof t?t(e):t||(0,a._)`{}`]),c.messages&&s.push([l.message,"function"==typeof r?r(e):r]),c.verbose&&s.push([l.schema,d],[l.parentSchema,(0,a._)`${p}${f}`],[i.default.data,o]),h&&s.push([l.propertyName,h])}(e,t,d),n.object(...d)}(e,t,r)}},49392(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.resolveSchema=t.getCompilingSchema=t.resolveRef=t.compileSchema=t.SchemaEnv=void 0;let a=r(17898),s=r(95031),i=r(63036),n=r(14856),o=r(50458),l=r(96223);class d{constructor(e){var t;let r;this.refs={},this.dynamicAnchors={},"object"==typeof e.schema&&(r=e.schema),this.schema=e.schema,this.schemaId=e.schemaId,this.root=e.root||this,this.baseId=null!=(t=e.baseId)?t:(0,n.normalizeId)(null==r?void 0:r[e.schemaId||"$id"]),this.schemaPath=e.schemaPath,this.localRefs=e.localRefs,this.meta=e.meta,this.$async=null==r?void 0:r.$async,this.refs={}}}function u(e){let t,r,o=h.call(this,e);if(o)return o;let d=(0,n.getFullPath)(this.opts.uriResolver,e.root.baseId),{es5:u,lines:c}=this.opts.code,{ownProperties:p}=this.opts,f=new a.CodeGen(this.scope,{es5:u,lines:c,ownProperties:p});e.$async&&(t=f.scopeValue("Error",{ref:s.default,code:(0,a._)`require("ajv/dist/runtime/validation_error").default`}));let m=f.scopeName("validate");e.validateName=m;let y={gen:f,allErrors:this.opts.allErrors,data:i.default.data,parentData:i.default.parentData,parentDataProperty:i.default.parentDataProperty,dataNames:[i.default.data],dataPathArr:[a.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:f.scopeValue("schema",!0===this.opts.code.source?{ref:e.schema,code:(0,a.stringify)(e.schema)}:{ref:e.schema}),validateName:m,ValidationError:t,schema:e.schema,schemaEnv:e,rootId:d,baseId:e.baseId||d,schemaPath:a.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,a._)`""`,opts:this.opts,self:this};try{this._compilations.add(e),(0,l.validateFunctionCode)(y),f.optimize(this.opts.code.optimize);let t=f.toString();r=`${f.scopeRefs(i.default.scope)}return ${t}`,this.opts.code.process&&(r=this.opts.code.process(r,e));let s=Function(`${i.default.self}`,`${i.default.scope}`,r)(this,this.scope.get());if(this.scope.value(m,{ref:s}),s.errors=null,s.schema=e.schema,s.schemaEnv=e,e.$async&&(s.$async=!0),!0===this.opts.code.source&&(s.source={validateName:m,validateCode:t,scopeValues:f._values}),this.opts.unevaluated){let{props:e,items:t}=y;s.evaluated={props:e instanceof a.Name?void 0:e,items:t instanceof a.Name?void 0:t,dynamicProps:e instanceof a.Name,dynamicItems:t instanceof a.Name},s.source&&(s.source.evaluated=(0,a.stringify)(s.evaluated))}return e.validate=s,e}catch(t){throw delete e.validate,delete e.validateName,r&&this.logger.error("Error compiling schema, function code:",r),t}finally{this._compilations.delete(e)}}function c(e){return(0,n.inlineRef)(e.schema,this.opts.inlineRefs)?e.schema:e.validate?e:u.call(this,e)}function h(e){for(let a of this._compilations){var t,r;if(t=a,r=e,t.schema===r.schema&&t.root===r.root&&t.baseId===r.baseId)return a}}function p(e,t){let r;for(;"string"==typeof(r=this.refs[t]);)t=r;return r||this.schemas[t]||f.call(this,e,t)}function f(e,t){let r=this.opts.uriResolver.parse(t),a=(0,n._getFullPath)(this.opts.uriResolver,r),s=(0,n.getFullPath)(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&a===s)return y.call(this,r,e);let i=(0,n.normalizeId)(a),o=this.refs[i]||this.schemas[i];if("string"==typeof o){let t=f.call(this,e,o);if("object"!=typeof(null==t?void 0:t.schema))return;return y.call(this,r,t)}if("object"==typeof(null==o?void 0:o.schema)){if(o.validate||u.call(this,o),i===(0,n.normalizeId)(t)){let{schema:t}=o,{schemaId:r}=this.opts,a=t[r];return a&&(s=(0,n.resolveUrl)(this.opts.uriResolver,s,a)),new d({schema:t,schemaId:r,root:e,baseId:s})}return y.call(this,r,o)}}t.SchemaEnv=d,t.compileSchema=u,t.resolveRef=function(e,t,r){var a;r=(0,n.resolveUrl)(this.opts.uriResolver,t,r);let s=e.refs[r];if(s)return s;let i=p.call(this,e,r);if(void 0===i){let s=null==(a=e.localRefs)?void 0:a[r],{schemaId:n}=this.opts;s&&(i=new d({schema:s,schemaId:n,root:e,baseId:t}))}if(void 0!==i)return e.refs[r]=c.call(this,i)},t.getCompilingSchema=h,t.resolveSchema=f;let m=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function y(e,{baseId:t,schema:r,root:a}){var s;let i;if((null==(s=e.fragment)?void 0:s[0])!=="/")return;for(let a of e.fragment.slice(1).split("/")){if("boolean"==typeof r)return;let e=r[(0,o.unescapeFragment)(a)];if(void 0===e)return;let s="object"==typeof(r=e)&&r[this.opts.schemaId];!m.has(a)&&s&&(t=(0,n.resolveUrl)(this.opts.uriResolver,t,s))}if("boolean"!=typeof r&&r.$ref&&!(0,o.schemaHasRulesButRef)(r,this.RULES)){let e=(0,n.resolveUrl)(this.opts.uriResolver,t,r.$ref);i=f.call(this,a,e)}let{schemaId:l}=this.opts;if((i=i||new d({schema:r,schemaId:l,root:a,baseId:t})).schema!==i.root.schema)return i}},63036(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898);t.default={data:new a.Name("data"),valCxt:new a.Name("valCxt"),instancePath:new a.Name("instancePath"),parentData:new a.Name("parentData"),parentDataProperty:new a.Name("parentDataProperty"),rootData:new a.Name("rootData"),dynamicAnchors:new a.Name("dynamicAnchors"),vErrors:new a.Name("vErrors"),errors:new a.Name("errors"),this:new a.Name("this"),self:new a.Name("self"),scope:new a.Name("scope"),json:new a.Name("json"),jsonPos:new a.Name("jsonPos"),jsonLen:new a.Name("jsonLen"),jsonPart:new a.Name("jsonPart")}},85748(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(14856);t.default=class extends Error{constructor(e,t,r,s){super(s||`can't resolve reference ${r} from id ${t}`),this.missingRef=(0,a.resolveUrl)(e,t,r),this.missingSchema=(0,a.normalizeId)((0,a.getFullPath)(e,this.missingRef))}}},14856(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.getSchemaRefs=t.resolveUrl=t.normalizeId=t._getFullPath=t.getFullPath=t.inlineRef=void 0;let a=r(50458),s=r(38792),i=r(1645),n=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);t.inlineRef=function(e,t=!0){return"boolean"==typeof e||(!0===t?!function e(t){for(let r in t){if(o.has(r))return!0;let a=t[r];if(Array.isArray(a)&&a.some(e)||"object"==typeof a&&e(a))return!0}return!1}(e):!!t&&function e(t){let r=0;for(let s in t)if("$ref"===s||(r++,!n.has(s)&&("object"==typeof t[s]&&(0,a.eachItem)(t[s],t=>r+=e(t)),r===1/0)))return 1/0;return r}(e)<=t)};let o=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function l(e,t="",r){!1!==r&&(t=c(t));let a=e.parse(t);return d(e,a)}function d(e,t){return e.serialize(t).split("#")[0]+"#"}t.getFullPath=l,t._getFullPath=d;let u=/#\/?$/;function c(e){return e?e.replace(u,""):""}t.normalizeId=c,t.resolveUrl=function(e,t,r){return r=c(r),e.resolve(t,r)};let h=/^[a-z_][-a-z0-9._]*$/i;t.getSchemaRefs=function(e,t){if("boolean"==typeof e)return{};let{schemaId:r,uriResolver:a}=this.opts,n=c(e[r]||t),o={"":n},d=l(a,n,!1),u={},p=new Set;return i(e,{allKeys:!0},(e,t,a,s)=>{if(void 0===s)return;let i=d+t,n=o[s];function l(t){let r=this.opts.uriResolver.resolve;if(t=c(n?r(n,t):t),p.has(t))throw m(t);p.add(t);let a=this.refs[t];return"string"==typeof a&&(a=this.refs[a]),"object"==typeof a?f(e,a.schema,t):t!==c(i)&&("#"===t[0]?(f(e,u[t],t),u[t]=e):this.refs[t]=i),t}function y(e){if("string"==typeof e){if(!h.test(e))throw Error(`invalid anchor "${e}"`);l.call(this,`#${e}`)}}"string"==typeof e[r]&&(n=l.call(this,e[r])),y.call(this,e.$anchor),y.call(this,e.$dynamicAnchor),o[t]=n}),u;function f(e,t,r){if(void 0!==t&&!s(e,t))throw m(r)}function m(e){return Error(`reference "${e}" resolves to more than one schema`)}}},90383(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.getRules=t.isJSONType=void 0;let r=new Set(["string","number","integer","boolean","null","object","array"]);t.isJSONType=function(e){return"string"==typeof e&&r.has(e)},t.getRules=function(){let e={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...e,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},e.number,e.string,e.array,e.object],post:{rules:[]},all:{},keywords:{}}}},50458(e,t,r){var a,s;Object.defineProperty(t,"__esModule",{value:!0}),t.checkStrictMode=t.getErrorPath=t.Type=t.useFunc=t.setEvaluated=t.evaluatedPropsToName=t.mergeEvaluated=t.eachItem=t.unescapeJsonPointer=t.escapeJsonPointer=t.escapeFragment=t.unescapeFragment=t.schemaRefOrVal=t.schemaHasRulesButRef=t.schemaHasRules=t.checkUnknownRules=t.alwaysValidSchema=t.toHash=void 0;let i=r(17898),n=r(83277);function o(e,t=e.schema){let{opts:r,self:a}=e;if(!r.strictSchema||"boolean"==typeof t)return;let s=a.RULES.keywords;for(let r in t)s[r]||m(e,`unknown keyword: "${r}"`)}function l(e,t){if("boolean"==typeof e)return!e;for(let r in e)if(t[r])return!0;return!1}function d(e){return"number"==typeof e?`${e}`:e.replace(/~/g,"~0").replace(/\//g,"~1")}function u(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}function c({mergeNames:e,mergeToName:t,mergeValues:r,resultToName:a}){return(s,n,o,l)=>{let d=void 0===o?n:o instanceof i.Name?(n instanceof i.Name?e(s,n,o):t(s,n,o),o):n instanceof i.Name?(t(s,o,n),n):r(n,o);return l!==i.Name||d instanceof i.Name?d:a(s,d)}}function h(e,t){if(!0===t)return e.var("props",!0);let r=e.var("props",(0,i._)`{}`);return void 0!==t&&p(e,r,t),r}function p(e,t,r){Object.keys(r).forEach(r=>e.assign((0,i._)`${t}${(0,i.getProperty)(r)}`,!0))}t.toHash=function(e){let t={};for(let r of e)t[r]=!0;return t},t.alwaysValidSchema=function(e,t){return"boolean"==typeof t?t:0===Object.keys(t).length||(o(e,t),!l(t,e.self.RULES.all))},t.checkUnknownRules=o,t.schemaHasRules=l,t.schemaHasRulesButRef=function(e,t){if("boolean"==typeof e)return!e;for(let r in e)if("$ref"!==r&&t.all[r])return!0;return!1},t.schemaRefOrVal=function({topSchemaRef:e,schemaPath:t},r,a,s){if(!s){if("number"==typeof r||"boolean"==typeof r)return r;if("string"==typeof r)return(0,i._)`${r}`}return(0,i._)`${e}${t}${(0,i.getProperty)(a)}`},t.unescapeFragment=function(e){return u(decodeURIComponent(e))},t.escapeFragment=function(e){return encodeURIComponent(d(e))},t.escapeJsonPointer=d,t.unescapeJsonPointer=u,t.eachItem=function(e,t){if(Array.isArray(e))for(let r of e)t(r);else t(e)},t.mergeEvaluated={props:c({mergeNames:(e,t,r)=>e.if((0,i._)`${r} !== true && ${t} !== undefined`,()=>{e.if((0,i._)`${t} === true`,()=>e.assign(r,!0),()=>e.assign(r,(0,i._)`${r} || {}`).code((0,i._)`Object.assign(${r}, ${t})`))}),mergeToName:(e,t,r)=>e.if((0,i._)`${r} !== true`,()=>{!0===t?e.assign(r,!0):(e.assign(r,(0,i._)`${r} || {}`),p(e,r,t))}),mergeValues:(e,t)=>!0===e||{...e,...t},resultToName:h}),items:c({mergeNames:(e,t,r)=>e.if((0,i._)`${r} !== true && ${t} !== undefined`,()=>e.assign(r,(0,i._)`${t} === true ? true : ${r} > ${t} ? ${r} : ${t}`)),mergeToName:(e,t,r)=>e.if((0,i._)`${r} !== true`,()=>e.assign(r,!0===t||(0,i._)`${r} > ${t} ? ${r} : ${t}`)),mergeValues:(e,t)=>!0===e||Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})},t.evaluatedPropsToName=h,t.setEvaluated=p;let f={};function m(e,t,r=e.opts.strictSchema){if(r){if(t=`strict mode: ${t}`,!0===r)throw Error(t);e.self.logger.warn(t)}}t.useFunc=function(e,t){return e.scopeValue("func",{ref:t,code:f[t.code]||(f[t.code]=new n._Code(t.code))})},(s=a||(t.Type=a={}))[s.Num=0]="Num",s[s.Str=1]="Str",t.getErrorPath=function(e,t,r){if(e instanceof i.Name){let s=t===a.Num;return r?s?(0,i._)`"[" + ${e} + "]"`:(0,i._)`"['" + ${e} + "']"`:s?(0,i._)`"/" + ${e}`:(0,i._)`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return r?(0,i.getProperty)(e).toString():"/"+d(e)},t.checkStrictMode=m},74758(e,t){function r(e,t){return t.rules.some(t=>a(e,t))}function a(e,t){var r;return void 0!==e[t.keyword]||(null==(r=t.definition.implements)?void 0:r.some(t=>void 0!==e[t]))}Object.defineProperty(t,"__esModule",{value:!0}),t.shouldUseRule=t.shouldUseGroup=t.schemaHasRulesForType=void 0,t.schemaHasRulesForType=function({schema:e,self:t},a){let s=t.RULES.types[a];return s&&!0!==s&&r(e,s)},t.shouldUseGroup=r,t.shouldUseRule=a},15948(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.boolOrEmptySchema=t.topBoolOrEmptySchema=void 0;let a=r(49409),s=r(17898),i=r(63036),n={message:"boolean schema is false"};function o(e,t){let{gen:r,data:s}=e;(0,a.reportError)({gen:r,keyword:"false schema",data:s,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e},n,void 0,t)}t.topBoolOrEmptySchema=function(e){let{gen:t,schema:r,validateName:a}=e;!1===r?o(e,!1):"object"==typeof r&&!0===r.$async?t.return(i.default.data):(t.assign((0,s._)`${a}.errors`,null),t.return(!0))},t.boolOrEmptySchema=function(e,t){let{gen:r,schema:a}=e;!1===a?(r.var(t,!1),o(e)):r.var(t,!0)}},69003(e,t,r){var a,s;Object.defineProperty(t,"__esModule",{value:!0}),t.reportTypeError=t.checkDataTypes=t.checkDataType=t.coerceAndCheckDataType=t.getJSONTypes=t.getSchemaTypes=t.DataType=void 0;let i=r(90383),n=r(74758),o=r(49409),l=r(17898),d=r(50458);function u(e){let t=Array.isArray(e)?e:e?[e]:[];if(t.every(i.isJSONType))return t;throw Error("type must be JSONType or JSONType[]: "+t.join(","))}(s=a||(t.DataType=a={}))[s.Correct=0]="Correct",s[s.Wrong=1]="Wrong",t.getSchemaTypes=function(e){let t=u(e.type);if(t.includes("null")){if(!1===e.nullable)throw Error("type: null contradicts nullable: false")}else{if(!t.length&&void 0!==e.nullable)throw Error('"nullable" cannot be used without "type"');!0===e.nullable&&t.push("null")}return t},t.getJSONTypes=u,t.coerceAndCheckDataType=function(e,t){var r,s;let{gen:i,data:o,opts:d}=e,u=(r=t,(s=d.coerceTypes)?r.filter(e=>c.has(e)||"array"===s&&"array"===e):[]),h=t.length>0&&!(0===u.length&&1===t.length&&(0,n.schemaHasRulesForType)(e,t[0]));if(h){let r=p(t,o,d.strictNumbers,a.Wrong);i.if(r,()=>{u.length?function(e,t,r){let{gen:a,data:s,opts:i}=e,n=a.let("dataType",(0,l._)`typeof ${s}`),o=a.let("coerced",(0,l._)`undefined`);for(let e of("array"===i.coerceTypes&&a.if((0,l._)`${n} == 'object' && Array.isArray(${s}) && ${s}.length == 1`,()=>a.assign(s,(0,l._)`${s}[0]`).assign(n,(0,l._)`typeof ${s}`).if(p(t,s,i.strictNumbers),()=>a.assign(o,s))),a.if((0,l._)`${o} !== undefined`),r))(c.has(e)||"array"===e&&"array"===i.coerceTypes)&&function(e){switch(e){case"string":a.elseIf((0,l._)`${n} == "number" || ${n} == "boolean"`).assign(o,(0,l._)`"" + ${s}`).elseIf((0,l._)`${s} === null`).assign(o,(0,l._)`""`);return;case"number":a.elseIf((0,l._)`${n} == "boolean" || ${s} === null
1
+ "use strict";(self.webpackChunktechdocs_cli_embedded_app=self.webpackChunktechdocs_cli_embedded_app||[]).push([["2055"],{67156(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(11601),s=r(17898),i=r(83277),n=r(96223),o=r(49409),l=r(63036),d="errorMessage",u=new a.Name("emUsed"),c={required:"missingProperty",dependencies:"property",dependentRequired:"property"},h=/\$\{[^}]+\}/,f=/\$\{([^}]+)\}/g,p=/^""\s*\+\s*|\s*\+\s*""$/g,m=(e,t={})=>{if(!e.opts.allErrors)throw Error("ajv-errors: Ajv option allErrors must be true");if(e.opts.jsPropertySyntax)throw Error("ajv-errors: ajv option jsPropertySyntax is not supported");return e.addKeyword({keyword:d,schemaType:["string","object"],post:!0,code(e){let{gen:r,data:m,schema:y,schemaValue:g,it:v}=e;if(!1===v.createErrors)return;let _=s.strConcat(l.default.instancePath,v.errorPath);function $(e,t){return s.and(a._`${e}.keyword !== ${d}`,a._`!${e}.${u}`,a._`${e}.instancePath === ${_}`,a._`${e}.keyword in ${t}`,a._`${e}.schemaPath.indexOf(${v.errSchemaPath}) === 0`,a._`/^\\/[^\\/]*$/.test(${e}.schemaPath.slice(${v.errSchemaPath.length}))`)}function b(e,t){let s=[];for(let r in e){var i;let e=t[r];h.test(e)&&s.push([r,(i=e,a._`function(){return ${w(i)}}`)])}return r.object(...s)}function w(e){return h.test(e)?new i._Code(i.safeStringify(e).replace(f,(e,t)=>`" + JSON.stringify(${n.getData(t,v)}) + "`).replace(p,"")):a.stringify(e)}r.if(a._`${l.default.errors} > 0`,()=>{var i;let n,h;if("object"==typeof y){let[i,n]=function(e){let t,r;for(let a in e){if("properties"===a||"items"===a)continue;let s=e[a];if("object"==typeof s){t||(t={});let e=t[a]={};for(let t in s)e[t]=[]}else r||(r={}),r[a]=[]}return[t,r]}(y);n&&function(s){let i=r.const("emErrors",a.stringify(s)),n=r.const("templates",b(s,y));r.forOf("err",l.default.vErrors,e=>r.if($(e,i),()=>r.code(a._`${i}[${e}.keyword].push(${e})`).assign(a._`${e}.${u}`,!0)));let{singleError:d}=t;if(d){let t=r.let("message",a._`""`),s=r.let("paramsErrors",a._`[]`);c(e=>{r.if(t,()=>r.code(a._`${t} += ${"string"==typeof d?d:";"}`)),r.code(a._`${t} += ${h(e)}`),r.assign(s,a._`${s}.concat(${i}[${e}])`)}),o.reportError(e,{message:t,params:a._`{errors: ${s}}`})}else c(t=>o.reportError(e,{message:h(t),params:a._`{errors: ${i}[${t}]}`}));function c(e){r.forIn("key",i,t=>r.if(a._`${i}[${t}].length`,()=>e(t)))}function h(e){return a._`${e} in ${n} ? ${n}[${e}]() : ${g}[${e}]`}}(n),i&&function(t){let s=r.const("emErrors",a.stringify(t)),i=[];for(let e in t)i.push([e,b(t[e],y[e])]);let n=r.const("templates",r.object(...i)),d=r.scopeValue("obj",{ref:c,code:a.stringify(c)}),h=r.let("emPropParams"),f=r.let("emParamsErrors");r.forOf("err",l.default.vErrors,e=>r.if($(e,s),()=>{r.assign(h,a._`${d}[${e}.keyword]`),r.assign(f,a._`${s}[${e}.keyword][${e}.params[${h}]]`),r.if(f,()=>r.code(a._`${f}.push(${e})`).assign(a._`${e}.${u}`,!0))})),r.forIn("key",s,t=>r.forIn("keyProp",a._`${s}[${t}]`,i=>{r.assign(f,a._`${s}[${t}][${i}]`),r.if(a._`${f}.length`,()=>{let s=r.const("tmpl",a._`${n}[${t}] && ${n}[${t}][${i}]`);o.reportError(e,{message:a._`${s} ? ${s}() : ${g}[${t}][${i}]`,params:a._`{errors: ${f}}`})})}))}(i),function(t){let i,n,{props:c,items:h}=t;if(!c&&!h)return;let f=a._`typeof ${m} == "object"`,p=a._`Array.isArray(${m})`,v=r.let("emErrors"),$=r.let("templates");function w(e,t){r.assign(v,a.stringify(e)),r.assign($,b(e,t))}c&&h?(i=r.let("emChildKwd"),r.if(f),r.if(p,()=>{w(h,y.items),r.assign(i,a.str`items`)},()=>{w(c,y.properties),r.assign(i,a.str`properties`)}),n=a._`[${i}]`):h?(r.if(p),w(h,y.items),n=a._`.items`):c&&(r.if(s.and(f,s.not(p))),w(c,y.properties),n=a._`.properties`),r.forOf("err",l.default.vErrors,e=>{var t,i,n;return t=e,i=v,n=t=>r.code(a._`${v}[${t}].push(${e})`).assign(a._`${e}.${u}`,!0),void r.if(s.and(a._`${t}.keyword !== ${d}`,a._`!${t}.${u}`,a._`${t}.instancePath.indexOf(${_}) === 0`),()=>{let e=r.scopeValue("pattern",{ref:/^\/([^/]*)(?:\/|$)/,code:a._`new RegExp("^\\\/([^/]*)(?:\\\/|$)")`}),s=r.const("emMatches",a._`${e}.exec(${t}.instancePath.slice(${_}.length))`),o=r.const("emChild",a._`${s} && ${s}[1].replace(/~1/g, "/").replace(/~0/g, "~")`);r.if(a._`${o} !== undefined && ${o} in ${i}`,()=>n(o))})}),r.forIn("key",v,t=>r.if(a._`${v}[${t}].length`,()=>{o.reportError(e,{message:a._`${t} in ${$} ? ${$}[${t}]() : ${g}${n}[${t}]`,params:a._`{errors: ${v}[${t}]}`}),r.assign(a._`${l.default.vErrors}[${l.default.errors}-1].instancePath`,a._`${_} + "/" + ${t}.replace(/~/g, "~0").replace(/\\//g, "~1")`)})),r.endIf()}(function({properties:e,items:t}){let r={};if(e)for(let t in r.props={},e)r.props[t]=[];if(t){r.items={};for(let e=0;e<t.length;e++)r.items[e]=[]}return r}(y))}let f="string"==typeof y?y:y._;f&&(i=f,n=r.const("emErrs",a._`[]`),r.forOf("err",l.default.vErrors,e=>{var t;return r.if((t=e,s.and(a._`${t}.keyword !== ${d}`,a._`!${t}.${u}`,s.or(a._`${t}.instancePath === ${_}`,s.and(a._`${t}.instancePath.indexOf(${_}) === 0`,a._`${t}.instancePath[${_}.length] === "/"`)),a._`${t}.schemaPath.indexOf(${v.errSchemaPath}) === 0`,a._`${t}.schemaPath[${v.errSchemaPath}.length] === "/"`)),()=>r.code(a._`${n}.push(${e})`).assign(a._`${e}.${u}`,!0))}),r.if(a._`${n}.length`,()=>o.reportError(e,{message:w(i),params:a._`{errors: ${n}}`}))),t.keepErrors||(h=r.const("emErrs",a._`[]`),r.forOf("err",l.default.vErrors,e=>r.if(a._`!${e}.${u}`,()=>r.code(a._`${h}.push(${e})`))),r.assign(l.default.vErrors,h).assign(l.default.errors,a._`${h}.length`))})},metaSchema:{anyOf:[{type:"string"},{type:"object",properties:{properties:{$ref:"#/$defs/stringMap"},items:{$ref:"#/$defs/stringList"},required:{$ref:"#/$defs/stringOrMap"},dependencies:{$ref:"#/$defs/stringOrMap"}},additionalProperties:{type:"string"}}],$defs:{stringMap:{type:"object",additionalProperties:{type:"string"}},stringOrMap:{anyOf:[{type:"string"},{$ref:"#/$defs/stringMap"}]},stringList:{type:"array",items:{type:"string"}}}}})};t.default=m,e.exports=m,e.exports.default=m},11601(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.MissingRefError=t.ValidationError=t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=t.Ajv=void 0;let a=r(65319),s=r(2431),i=r(11672),n=r(33928),o=["/properties"],l="http://json-schema.org/draft-07/schema";class d extends a.default{_addVocabularies(){super._addVocabularies(),s.default.forEach(e=>this.addVocabulary(e)),this.opts.discriminator&&this.addKeyword(i.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;let e=this.opts.$data?this.$dataMetaSchema(n,o):n;this.addMetaSchema(e,l,!1),this.refs["http://json-schema.org/schema"]=l}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(l)?l:void 0)}}t.Ajv=d,e.exports=t=d,e.exports.Ajv=d,Object.defineProperty(t,"__esModule",{value:!0}),t.default=d;var u=r(96223);Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return u.KeywordCxt}});var c=r(17898);Object.defineProperty(t,"_",{enumerable:!0,get:function(){return c._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return c.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return c.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return c.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return c.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return c.CodeGen}});var h=r(95031);Object.defineProperty(t,"ValidationError",{enumerable:!0,get:function(){return h.default}});var f=r(85748);Object.defineProperty(t,"MissingRefError",{enumerable:!0,get:function(){return f.default}})},83277(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.regexpCode=t.getEsmExportName=t.getProperty=t.safeStringify=t.stringify=t.strConcat=t.addCodeArg=t.str=t._=t.nil=t._Code=t.Name=t.IDENTIFIER=t._CodeOrName=void 0;class r{}t._CodeOrName=r,t.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;class a extends r{constructor(e){if(super(),!t.IDENTIFIER.test(e))throw Error("CodeGen: name must be a valid identifier");this.str=e}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}}t.Name=a;class s extends r{constructor(e){super(),this._items="string"==typeof e?[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 null!=(e=this._str)?e:this._str=this._items.reduce((e,t)=>`${e}${t}`,"")}get names(){var e;return null!=(e=this._names)?e:this._names=this._items.reduce((e,t)=>(t instanceof a&&(e[t.str]=(e[t.str]||0)+1),e),{})}}function i(e,...t){let r=[e[0]],a=0;for(;a<t.length;)l(r,t[a]),r.push(e[++a]);return new s(r)}t._Code=s,t.nil=new s(""),t._=i;let n=new s("+");function o(e,...t){let r=[d(e[0])],i=0;for(;i<t.length;)r.push(n),l(r,t[i]),r.push(n,d(e[++i]));return function(e){let t=1;for(;t<e.length-1;){if(e[t]===n){var r,s;let i=(r=e[t-1],'""'===(s=e[t+1])?r:'""'===r?s:"string"==typeof r?s instanceof a||'"'!==r[r.length-1]?void 0:"string"!=typeof s?`${r.slice(0,-1)}${s}"`:'"'===s[0]?r.slice(0,-1)+s.slice(1):void 0:"string"!=typeof s||'"'!==s[0]||r instanceof a?void 0:`"${r}${s.slice(1)}`);if(void 0!==i){e.splice(t-1,3,i);continue}e[t++]="+"}t++}}(r),new s(r)}function l(e,t){var r;t instanceof s?e.push(...t._items):t instanceof a?e.push(t):e.push("number"==typeof(r=t)||"boolean"==typeof r||null===r?r:d(Array.isArray(r)?r.join(","):r))}function d(e){return JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}t.str=o,t.addCodeArg=l,t.strConcat=function(e,t){return t.emptyStr()?e:e.emptyStr()?t:o`${e}${t}`},t.stringify=function(e){return new s(d(e))},t.safeStringify=d,t.getProperty=function(e){return"string"==typeof e&&t.IDENTIFIER.test(e)?new s(`.${e}`):i`[${e}]`},t.getEsmExportName=function(e){if("string"==typeof e&&t.IDENTIFIER.test(e))return new s(`${e}`);throw Error(`CodeGen: invalid export name: ${e}, use explicit $id name mapping`)},t.regexpCode=function(e){return new s(e.toString())}},17898(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.or=t.and=t.not=t.CodeGen=t.operators=t.varKinds=t.ValueScopeName=t.ValueScope=t.Scope=t.Name=t.regexpCode=t.stringify=t.getProperty=t.nil=t.strConcat=t.str=t._=void 0;let a=r(83277),s=r(76930);var i=r(83277);Object.defineProperty(t,"_",{enumerable:!0,get:function(){return i._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return i.str}}),Object.defineProperty(t,"strConcat",{enumerable:!0,get:function(){return i.strConcat}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return i.nil}}),Object.defineProperty(t,"getProperty",{enumerable:!0,get:function(){return i.getProperty}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return i.stringify}}),Object.defineProperty(t,"regexpCode",{enumerable:!0,get:function(){return i.regexpCode}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return i.Name}});var n=r(76930);Object.defineProperty(t,"Scope",{enumerable:!0,get:function(){return n.Scope}}),Object.defineProperty(t,"ValueScope",{enumerable:!0,get:function(){return n.ValueScope}}),Object.defineProperty(t,"ValueScopeName",{enumerable:!0,get:function(){return n.ValueScopeName}}),Object.defineProperty(t,"varKinds",{enumerable:!0,get:function(){return n.varKinds}}),t.operators={GT:new a._Code(">"),GTE:new a._Code(">="),LT:new a._Code("<"),LTE:new a._Code("<="),EQ:new a._Code("==="),NEQ:new a._Code("!=="),NOT:new a._Code("!"),OR:new a._Code("||"),AND:new a._Code("&&"),ADD:new a._Code("+")};class o{optimizeNodes(){return this}optimizeNames(e,t){return this}}class l extends o{constructor(e,t,r){super(),this.varKind=e,this.name=t,this.rhs=r}render({es5:e,_n:t}){let r=e?s.varKinds.var:this.varKind,a=void 0===this.rhs?"":` = ${this.rhs}`;return`${r} ${this.name}${a};`+t}optimizeNames(e,t){if(e[this.name.str])return this.rhs&&(this.rhs=T(this.rhs,e,t)),this}get names(){return this.rhs instanceof a._CodeOrName?this.rhs.names:{}}}class d extends o{constructor(e,t,r){super(),this.lhs=e,this.rhs=t,this.sideEffects=r}render({_n:e}){return`${this.lhs} = ${this.rhs};`+e}optimizeNames(e,t){if(!(this.lhs instanceof a.Name)||e[this.lhs.str]||this.sideEffects)return this.rhs=T(this.rhs,e,t),this}get names(){return O(this.lhs instanceof a.Name?{}:{...this.lhs.names},this.rhs)}}class u extends d{constructor(e,t,r,a){super(e,r,a),this.op=t}render({_n:e}){return`${this.lhs} ${this.op}= ${this.rhs};`+e}}class c extends o{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){return`${this.label}:`+e}}class h extends o{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){let t=this.label?` ${this.label}`:"";return`break${t};`+e}}class f extends o{constructor(e){super(),this.error=e}render({_n:e}){return`throw ${this.error};`+e}get names(){return this.error.names}}class p extends o{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=T(this.code,e,t),this}get names(){return this.code instanceof a._CodeOrName?this.code.names:{}}}class m extends o{constructor(e=[]){super(),this.nodes=e}render(e){return this.nodes.reduce((t,r)=>t+r.render(e),"")}optimizeNodes(){let{nodes:e}=this,t=e.length;for(;t--;){let r=e[t].optimizeNodes();Array.isArray(r)?e.splice(t,1,...r):r?e[t]=r:e.splice(t,1)}return e.length>0?this:void 0}optimizeNames(e,t){let{nodes:r}=this,a=r.length;for(;a--;){let s=r[a];s.optimizeNames(e,t)||(function(e,t){for(let r in t)e[r]=(e[r]||0)-(t[r]||0)}(e,s.names),r.splice(a,1))}return r.length>0?this:void 0}get names(){return this.nodes.reduce((e,t)=>N(e,t.names),{})}}class y extends m{render(e){return"{"+e._n+super.render(e)+"}"+e._n}}class g extends m{}class v extends y{}v.kind="else";class _ extends y{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(!0===e)return this.nodes;let t=this.else;if(t){let e=t.optimizeNodes();t=this.else=Array.isArray(e)?new v(e):e}return t?!1===e?t instanceof _?t:t.nodes:this.nodes.length?this:new _(C(e),t instanceof _?[t]:t.nodes):!1!==e&&this.nodes.length?this:void 0}optimizeNames(e,t){var r;if(this.else=null==(r=this.else)?void 0:r.optimizeNames(e,t),super.optimizeNames(e,t)||this.else)return this.condition=T(this.condition,e,t),this}get names(){let e=super.names;return O(e,this.condition),this.else&&N(e,this.else.names),e}}_.kind="if";class $ extends y{}$.kind="for";class b extends ${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=T(this.iteration,e,t),this}get names(){return N(super.names,this.iteration.names)}}class w extends ${constructor(e,t,r,a){super(),this.varKind=e,this.name=t,this.from=r,this.to=a}render(e){let t=e.es5?s.varKinds.var:this.varKind,{name:r,from:a,to:i}=this;return`for(${t} ${r}=${a}; ${r}<${i}; ${r}++)`+super.render(e)}get names(){let e=O(super.names,this.from);return O(e,this.to)}}class k extends ${constructor(e,t,r,a){super(),this.loop=e,this.varKind=t,this.name=r,this.iterable=a}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=T(this.iterable,e,t),this}get names(){return N(super.names,this.iterable.names)}}class x extends y{constructor(e,t,r){super(),this.name=e,this.args=t,this.async=r}render(e){let t=this.async?"async ":"";return`${t}function ${this.name}(${this.args})`+super.render(e)}}x.kind="func";class P extends m{render(e){return"return "+super.render(e)}}P.kind="return";class S extends y{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(),null==(e=this.catch)||e.optimizeNodes(),null==(t=this.finally)||t.optimizeNodes(),this}optimizeNames(e,t){var r,a;return super.optimizeNames(e,t),null==(r=this.catch)||r.optimizeNames(e,t),null==(a=this.finally)||a.optimizeNames(e,t),this}get names(){let e=super.names;return this.catch&&N(e,this.catch.names),this.finally&&N(e,this.finally.names),e}}class E extends y{constructor(e){super(),this.error=e}render(e){return`catch(${this.error})`+super.render(e)}}E.kind="catch";class j extends y{render(e){return"finally"+super.render(e)}}function N(e,t){for(let r in t)e[r]=(e[r]||0)+(t[r]||0);return e}function O(e,t){return t instanceof a._CodeOrName?N(e,t.names):e}function T(e,t,r){var s;if(e instanceof a.Name)return i(e);if(!((s=e)instanceof a._Code&&s._items.some(e=>e instanceof a.Name&&1===t[e.str]&&void 0!==r[e.str])))return e;return new a._Code(e._items.reduce((e,t)=>(t instanceof a.Name&&(t=i(t)),t instanceof a._Code?e.push(...t._items):e.push(t),e),[]));function i(e){let a=r[e.str];return void 0===a||1!==t[e.str]?e:(delete t[e.str],a)}}function C(e){return"boolean"==typeof e||"number"==typeof e||null===e?!e:(0,a._)`!${Z(e)}`}j.kind="finally",t.CodeGen=class{constructor(e,t={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...t,_n:t.lines?"\n":""},this._extScope=e,this._scope=new s.Scope({parent:e}),this._nodes=[new g]}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 r=this._extScope.value(e,t);return(this._values[r.prefix]||(this._values[r.prefix]=new Set)).add(r),r}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,r,a){let s=this._scope.toName(t);return void 0!==r&&a&&(this._constants[s.str]=r),this._leafNode(new l(e,s,r)),s}const(e,t,r){return this._def(s.varKinds.const,e,t,r)}let(e,t,r){return this._def(s.varKinds.let,e,t,r)}var(e,t,r){return this._def(s.varKinds.var,e,t,r)}assign(e,t,r){return this._leafNode(new d(e,t,r))}add(e,r){return this._leafNode(new u(e,t.operators.ADD,r))}code(e){return"function"==typeof e?e():e!==a.nil&&this._leafNode(new p(e)),this}object(...e){let t=["{"];for(let[r,s]of e)t.length>1&&t.push(","),t.push(r),(r!==s||this.opts.es5)&&(t.push(":"),(0,a.addCodeArg)(t,s));return t.push("}"),new a._Code(t)}if(e,t,r){if(this._blockNode(new _(e)),t&&r)this.code(t).else().code(r).endIf();else if(t)this.code(t).endIf();else if(r)throw Error('CodeGen: "else" body without "then" body');return this}elseIf(e){return this._elseNode(new _(e))}else(){return this._elseNode(new v)}endIf(){return this._endBlockNode(_,v)}_for(e,t){return this._blockNode(e),t&&this.code(t).endFor(),this}for(e,t){return this._for(new b(e),t)}forRange(e,t,r,a,i=this.opts.es5?s.varKinds.var:s.varKinds.let){let n=this._scope.toName(e);return this._for(new w(i,n,t,r),()=>a(n))}forOf(e,t,r,i=s.varKinds.const){let n=this._scope.toName(e);if(this.opts.es5){let e=t instanceof a.Name?t:this.var("_arr",t);return this.forRange("_i",0,(0,a._)`${e}.length`,t=>{this.var(n,(0,a._)`${e}[${t}]`),r(n)})}return this._for(new k("of",i,n,t),()=>r(n))}forIn(e,t,r,i=this.opts.es5?s.varKinds.var:s.varKinds.const){if(this.opts.ownProperties)return this.forOf(e,(0,a._)`Object.keys(${t})`,r);let n=this._scope.toName(e);return this._for(new k("in",i,n,t),()=>r(n))}endFor(){return this._endBlockNode($)}label(e){return this._leafNode(new c(e))}break(e){return this._leafNode(new h(e))}return(e){let t=new P;if(this._blockNode(t),this.code(e),1!==t.nodes.length)throw Error('CodeGen: "return" should have one node');return this._endBlockNode(P)}try(e,t,r){if(!t&&!r)throw Error('CodeGen: "try" without "catch" and "finally"');let a=new S;if(this._blockNode(a),this.code(e),t){let e=this.name("e");this._currNode=a.catch=new E(e),t(e)}return r&&(this._currNode=a.finally=new j,this.code(r)),this._endBlockNode(E,j)}throw(e){return this._leafNode(new f(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(void 0===t)throw Error("CodeGen: not in self-balancing block");let r=this._nodes.length-t;if(r<0||void 0!==e&&r!==e)throw Error(`CodeGen: wrong number of nodes: ${r} vs ${e} expected`);return this._nodes.length=t,this}func(e,t=a.nil,r,s){return this._blockNode(new x(e,t,r)),s&&this.code(s).endFunc(),this}endFunc(){return this._endBlockNode(x)}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 r=this._currNode;if(r instanceof e||t&&r instanceof t)return this._nodes.pop(),this;throw Error(`CodeGen: not in block "${t?`${e.kind}/${t.kind}`:e.kind}"`)}_elseNode(e){let t=this._currNode;if(!(t instanceof _))throw 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}},t.not=C;let I=A(t.operators.AND);t.and=function(...e){return e.reduce(I)};let R=A(t.operators.OR);function A(e){return(t,r)=>t===a.nil?r:r===a.nil?t:(0,a._)`${Z(t)} ${e} ${Z(r)}`}function Z(e){return e instanceof a.Name?e:(0,a._)`(${e})`}t.or=function(...e){return e.reduce(R)}},76930(e,t,r){var a,s;Object.defineProperty(t,"__esModule",{value:!0}),t.ValueScope=t.ValueScopeName=t.Scope=t.varKinds=t.UsedValueState=void 0;let i=r(83277);class n extends Error{constructor(e){super(`CodeGen: "code" for ${e} not defined`),this.value=e.value}}(s=a||(t.UsedValueState=a={}))[s.Started=0]="Started",s[s.Completed=1]="Completed",t.varKinds={const:new i.Name("const"),let:new i.Name("let"),var:new i.Name("var")};class o{constructor({prefixes:e,parent:t}={}){this._names={},this._prefixes=e,this._parent=t}toName(e){return e instanceof i.Name?e:this.name(e)}name(e){return new i.Name(this._newName(e))}_newName(e){let t=this._names[e]||this._nameGroup(e);return`${e}${t.index++}`}_nameGroup(e){var t,r;if((null==(r=null==(t=this._parent)?void 0:t._prefixes)?void 0:r.has(e))||this._prefixes&&!this._prefixes.has(e))throw Error(`CodeGen: prefix "${e}" is not allowed in this scope`);return this._names[e]={prefix:e,index:0}}}t.Scope=o;class l extends i.Name{constructor(e,t){super(t),this.prefix=e}setValue(e,{property:t,itemIndex:r}){this.value=e,this.scopePath=(0,i._)`.${new i.Name(t)}[${r}]`}}t.ValueScopeName=l;let d=(0,i._)`\n`;t.ValueScope=class extends o{constructor(e){super(e),this._values={},this._scope=e.scope,this.opts={...e,_n:e.lines?d:i.nil}}get(){return this._scope}name(e){return new l(e,this._newName(e))}value(e,t){var r;if(void 0===t.ref)throw Error("CodeGen: ref must be passed in value");let a=this.toName(e),{prefix:s}=a,i=null!=(r=t.key)?r:t.ref,n=this._values[s];if(n){let e=n.get(i);if(e)return e}else n=this._values[s]=new Map;n.set(i,a);let o=this._scope[s]||(this._scope[s]=[]),l=o.length;return o[l]=t.ref,a.setValue(t,{property:s,itemIndex:l}),a}getValue(e,t){let r=this._values[e];if(r)return r.get(t)}scopeRefs(e,t=this._values){return this._reduceValues(t,t=>{if(void 0===t.scopePath)throw Error(`CodeGen: name "${t}" has no value`);return(0,i._)`${e}${t.scopePath}`})}scopeCode(e=this._values,t,r){return this._reduceValues(e,e=>{if(void 0===e.value)throw Error(`CodeGen: name "${e}" has no value`);return e.value.code},t,r)}_reduceValues(e,r,s={},o){let l=i.nil;for(let d in e){let u=e[d];if(!u)continue;let c=s[d]=s[d]||new Map;u.forEach(e=>{if(c.has(e))return;c.set(e,a.Started);let s=r(e);if(s){let r=this.opts.es5?t.varKinds.var:t.varKinds.const;l=(0,i._)`${l}${r} ${e} = ${s};${this.opts._n}`}else if(s=null==o?void 0:o(e))l=(0,i._)`${l}${s}${this.opts._n}`;else throw new n(e);c.set(e,a.Completed)})}return l}}},49409(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.extendErrors=t.resetErrorsCount=t.reportExtraError=t.reportError=t.keyword$DataError=t.keywordError=void 0;let a=r(17898),s=r(50458),i=r(63036);function n(e,t){let r=e.const("err",t);e.if((0,a._)`${i.default.vErrors} === null`,()=>e.assign(i.default.vErrors,(0,a._)`[${r}]`),(0,a._)`${i.default.vErrors}.push(${r})`),e.code((0,a._)`${i.default.errors}++`)}function o(e,t){let{gen:r,validateName:s,schemaEnv:i}=e;i.$async?r.throw((0,a._)`new ${e.ValidationError}(${t})`):(r.assign((0,a._)`${s}.errors`,t),r.return(!1))}t.keywordError={message:({keyword:e})=>(0,a.str)`must pass "${e}" keyword validation`},t.keyword$DataError={message:({keyword:e,schemaType:t})=>t?(0,a.str)`"${e}" keyword must be ${t} ($data)`:(0,a.str)`"${e}" keyword is invalid ($data)`},t.reportError=function(e,r=t.keywordError,s,i){let{it:l}=e,{gen:u,compositeRule:c,allErrors:h}=l,f=d(e,r,s);(null!=i?i:c||h)?n(u,f):o(l,(0,a._)`[${f}]`)},t.reportExtraError=function(e,r=t.keywordError,a){let{it:s}=e,{gen:l,compositeRule:u,allErrors:c}=s;n(l,d(e,r,a)),u||c||o(s,i.default.vErrors)},t.resetErrorsCount=function(e,t){e.assign(i.default.errors,t),e.if((0,a._)`${i.default.vErrors} !== null`,()=>e.if(t,()=>e.assign((0,a._)`${i.default.vErrors}.length`,t),()=>e.assign(i.default.vErrors,null)))},t.extendErrors=function({gen:e,keyword:t,schemaValue:r,data:s,errsCount:n,it:o}){if(void 0===n)throw Error("ajv implementation error");let l=e.name("err");e.forRange("i",n,i.default.errors,n=>{e.const(l,(0,a._)`${i.default.vErrors}[${n}]`),e.if((0,a._)`${l}.instancePath === undefined`,()=>e.assign((0,a._)`${l}.instancePath`,(0,a.strConcat)(i.default.instancePath,o.errorPath))),e.assign((0,a._)`${l}.schemaPath`,(0,a.str)`${o.errSchemaPath}/${t}`),o.opts.verbose&&(e.assign((0,a._)`${l}.schema`,r),e.assign((0,a._)`${l}.data`,s))})};let l={keyword:new a.Name("keyword"),schemaPath:new a.Name("schemaPath"),params:new a.Name("params"),propertyName:new a.Name("propertyName"),message:new a.Name("message"),schema:new a.Name("schema"),parentSchema:new a.Name("parentSchema")};function d(e,t,r){let{createErrors:n}=e.it;return!1===n?(0,a._)`{}`:function(e,t,r={}){let{gen:n,it:o}=e,d=[function({errorPath:e},{instancePath:t}){let r=t?(0,a.str)`${e}${(0,s.getErrorPath)(t,s.Type.Str)}`:e;return[i.default.instancePath,(0,a.strConcat)(i.default.instancePath,r)]}(o,r),function({keyword:e,it:{errSchemaPath:t}},{schemaPath:r,parentSchema:i}){let n=i?t:(0,a.str)`${t}/${e}`;return r&&(n=(0,a.str)`${n}${(0,s.getErrorPath)(r,s.Type.Str)}`),[l.schemaPath,n]}(e,r)];return function(e,{params:t,message:r},s){let{keyword:n,data:o,schemaValue:d,it:u}=e,{opts:c,propertyName:h,topSchemaRef:f,schemaPath:p}=u;s.push([l.keyword,n],[l.params,"function"==typeof t?t(e):t||(0,a._)`{}`]),c.messages&&s.push([l.message,"function"==typeof r?r(e):r]),c.verbose&&s.push([l.schema,d],[l.parentSchema,(0,a._)`${f}${p}`],[i.default.data,o]),h&&s.push([l.propertyName,h])}(e,t,d),n.object(...d)}(e,t,r)}},49392(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.resolveSchema=t.getCompilingSchema=t.resolveRef=t.compileSchema=t.SchemaEnv=void 0;let a=r(17898),s=r(95031),i=r(63036),n=r(14856),o=r(50458),l=r(96223);class d{constructor(e){var t;let r;this.refs={},this.dynamicAnchors={},"object"==typeof e.schema&&(r=e.schema),this.schema=e.schema,this.schemaId=e.schemaId,this.root=e.root||this,this.baseId=null!=(t=e.baseId)?t:(0,n.normalizeId)(null==r?void 0:r[e.schemaId||"$id"]),this.schemaPath=e.schemaPath,this.localRefs=e.localRefs,this.meta=e.meta,this.$async=null==r?void 0:r.$async,this.refs={}}}function u(e){let t,r,o=h.call(this,e);if(o)return o;let d=(0,n.getFullPath)(this.opts.uriResolver,e.root.baseId),{es5:u,lines:c}=this.opts.code,{ownProperties:f}=this.opts,p=new a.CodeGen(this.scope,{es5:u,lines:c,ownProperties:f});e.$async&&(t=p.scopeValue("Error",{ref:s.default,code:(0,a._)`require("ajv/dist/runtime/validation_error").default`}));let m=p.scopeName("validate");e.validateName=m;let y={gen:p,allErrors:this.opts.allErrors,data:i.default.data,parentData:i.default.parentData,parentDataProperty:i.default.parentDataProperty,dataNames:[i.default.data],dataPathArr:[a.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:p.scopeValue("schema",!0===this.opts.code.source?{ref:e.schema,code:(0,a.stringify)(e.schema)}:{ref:e.schema}),validateName:m,ValidationError:t,schema:e.schema,schemaEnv:e,rootId:d,baseId:e.baseId||d,schemaPath:a.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,a._)`""`,opts:this.opts,self:this};try{this._compilations.add(e),(0,l.validateFunctionCode)(y),p.optimize(this.opts.code.optimize);let t=p.toString();r=`${p.scopeRefs(i.default.scope)}return ${t}`,this.opts.code.process&&(r=this.opts.code.process(r,e));let s=Function(`${i.default.self}`,`${i.default.scope}`,r)(this,this.scope.get());if(this.scope.value(m,{ref:s}),s.errors=null,s.schema=e.schema,s.schemaEnv=e,e.$async&&(s.$async=!0),!0===this.opts.code.source&&(s.source={validateName:m,validateCode:t,scopeValues:p._values}),this.opts.unevaluated){let{props:e,items:t}=y;s.evaluated={props:e instanceof a.Name?void 0:e,items:t instanceof a.Name?void 0:t,dynamicProps:e instanceof a.Name,dynamicItems:t instanceof a.Name},s.source&&(s.source.evaluated=(0,a.stringify)(s.evaluated))}return e.validate=s,e}catch(t){throw delete e.validate,delete e.validateName,r&&this.logger.error("Error compiling schema, function code:",r),t}finally{this._compilations.delete(e)}}function c(e){return(0,n.inlineRef)(e.schema,this.opts.inlineRefs)?e.schema:e.validate?e:u.call(this,e)}function h(e){for(let a of this._compilations){var t,r;if(t=a,r=e,t.schema===r.schema&&t.root===r.root&&t.baseId===r.baseId)return a}}function f(e,t){let r;for(;"string"==typeof(r=this.refs[t]);)t=r;return r||this.schemas[t]||p.call(this,e,t)}function p(e,t){let r=this.opts.uriResolver.parse(t),a=(0,n._getFullPath)(this.opts.uriResolver,r),s=(0,n.getFullPath)(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&a===s)return y.call(this,r,e);let i=(0,n.normalizeId)(a),o=this.refs[i]||this.schemas[i];if("string"==typeof o){let t=p.call(this,e,o);if("object"!=typeof(null==t?void 0:t.schema))return;return y.call(this,r,t)}if("object"==typeof(null==o?void 0:o.schema)){if(o.validate||u.call(this,o),i===(0,n.normalizeId)(t)){let{schema:t}=o,{schemaId:r}=this.opts,a=t[r];return a&&(s=(0,n.resolveUrl)(this.opts.uriResolver,s,a)),new d({schema:t,schemaId:r,root:e,baseId:s})}return y.call(this,r,o)}}t.SchemaEnv=d,t.compileSchema=u,t.resolveRef=function(e,t,r){var a;r=(0,n.resolveUrl)(this.opts.uriResolver,t,r);let s=e.refs[r];if(s)return s;let i=f.call(this,e,r);if(void 0===i){let s=null==(a=e.localRefs)?void 0:a[r],{schemaId:n}=this.opts;s&&(i=new d({schema:s,schemaId:n,root:e,baseId:t}))}if(void 0!==i)return e.refs[r]=c.call(this,i)},t.getCompilingSchema=h,t.resolveSchema=p;let m=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function y(e,{baseId:t,schema:r,root:a}){var s;let i;if((null==(s=e.fragment)?void 0:s[0])!=="/")return;for(let a of e.fragment.slice(1).split("/")){if("boolean"==typeof r)return;let e=r[(0,o.unescapeFragment)(a)];if(void 0===e)return;let s="object"==typeof(r=e)&&r[this.opts.schemaId];!m.has(a)&&s&&(t=(0,n.resolveUrl)(this.opts.uriResolver,t,s))}if("boolean"!=typeof r&&r.$ref&&!(0,o.schemaHasRulesButRef)(r,this.RULES)){let e=(0,n.resolveUrl)(this.opts.uriResolver,t,r.$ref);i=p.call(this,a,e)}let{schemaId:l}=this.opts;if((i=i||new d({schema:r,schemaId:l,root:a,baseId:t})).schema!==i.root.schema)return i}},63036(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898);t.default={data:new a.Name("data"),valCxt:new a.Name("valCxt"),instancePath:new a.Name("instancePath"),parentData:new a.Name("parentData"),parentDataProperty:new a.Name("parentDataProperty"),rootData:new a.Name("rootData"),dynamicAnchors:new a.Name("dynamicAnchors"),vErrors:new a.Name("vErrors"),errors:new a.Name("errors"),this:new a.Name("this"),self:new a.Name("self"),scope:new a.Name("scope"),json:new a.Name("json"),jsonPos:new a.Name("jsonPos"),jsonLen:new a.Name("jsonLen"),jsonPart:new a.Name("jsonPart")}},85748(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(14856);t.default=class extends Error{constructor(e,t,r,s){super(s||`can't resolve reference ${r} from id ${t}`),this.missingRef=(0,a.resolveUrl)(e,t,r),this.missingSchema=(0,a.normalizeId)((0,a.getFullPath)(e,this.missingRef))}}},14856(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.getSchemaRefs=t.resolveUrl=t.normalizeId=t._getFullPath=t.getFullPath=t.inlineRef=void 0;let a=r(50458),s=r(38792),i=r(1645),n=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);t.inlineRef=function(e,t=!0){return"boolean"==typeof e||(!0===t?!function e(t){for(let r in t){if(o.has(r))return!0;let a=t[r];if(Array.isArray(a)&&a.some(e)||"object"==typeof a&&e(a))return!0}return!1}(e):!!t&&function e(t){let r=0;for(let s in t)if("$ref"===s||(r++,!n.has(s)&&("object"==typeof t[s]&&(0,a.eachItem)(t[s],t=>r+=e(t)),r===1/0)))return 1/0;return r}(e)<=t)};let o=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function l(e,t="",r){!1!==r&&(t=c(t));let a=e.parse(t);return d(e,a)}function d(e,t){return e.serialize(t).split("#")[0]+"#"}t.getFullPath=l,t._getFullPath=d;let u=/#\/?$/;function c(e){return e?e.replace(u,""):""}t.normalizeId=c,t.resolveUrl=function(e,t,r){return r=c(r),e.resolve(t,r)};let h=/^[a-z_][-a-z0-9._]*$/i;t.getSchemaRefs=function(e,t){if("boolean"==typeof e)return{};let{schemaId:r,uriResolver:a}=this.opts,n=c(e[r]||t),o={"":n},d=l(a,n,!1),u={},f=new Set;return i(e,{allKeys:!0},(e,t,a,s)=>{if(void 0===s)return;let i=d+t,n=o[s];function l(t){let r=this.opts.uriResolver.resolve;if(t=c(n?r(n,t):t),f.has(t))throw m(t);f.add(t);let a=this.refs[t];return"string"==typeof a&&(a=this.refs[a]),"object"==typeof a?p(e,a.schema,t):t!==c(i)&&("#"===t[0]?(p(e,u[t],t),u[t]=e):this.refs[t]=i),t}function y(e){if("string"==typeof e){if(!h.test(e))throw Error(`invalid anchor "${e}"`);l.call(this,`#${e}`)}}"string"==typeof e[r]&&(n=l.call(this,e[r])),y.call(this,e.$anchor),y.call(this,e.$dynamicAnchor),o[t]=n}),u;function p(e,t,r){if(void 0!==t&&!s(e,t))throw m(r)}function m(e){return Error(`reference "${e}" resolves to more than one schema`)}}},90383(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.getRules=t.isJSONType=void 0;let r=new Set(["string","number","integer","boolean","null","object","array"]);t.isJSONType=function(e){return"string"==typeof e&&r.has(e)},t.getRules=function(){let e={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...e,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},e.number,e.string,e.array,e.object],post:{rules:[]},all:{},keywords:{}}}},50458(e,t,r){var a,s;Object.defineProperty(t,"__esModule",{value:!0}),t.checkStrictMode=t.getErrorPath=t.Type=t.useFunc=t.setEvaluated=t.evaluatedPropsToName=t.mergeEvaluated=t.eachItem=t.unescapeJsonPointer=t.escapeJsonPointer=t.escapeFragment=t.unescapeFragment=t.schemaRefOrVal=t.schemaHasRulesButRef=t.schemaHasRules=t.checkUnknownRules=t.alwaysValidSchema=t.toHash=void 0;let i=r(17898),n=r(83277);function o(e,t=e.schema){let{opts:r,self:a}=e;if(!r.strictSchema||"boolean"==typeof t)return;let s=a.RULES.keywords;for(let r in t)s[r]||m(e,`unknown keyword: "${r}"`)}function l(e,t){if("boolean"==typeof e)return!e;for(let r in e)if(t[r])return!0;return!1}function d(e){return"number"==typeof e?`${e}`:e.replace(/~/g,"~0").replace(/\//g,"~1")}function u(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}function c({mergeNames:e,mergeToName:t,mergeValues:r,resultToName:a}){return(s,n,o,l)=>{let d=void 0===o?n:o instanceof i.Name?(n instanceof i.Name?e(s,n,o):t(s,n,o),o):n instanceof i.Name?(t(s,o,n),n):r(n,o);return l!==i.Name||d instanceof i.Name?d:a(s,d)}}function h(e,t){if(!0===t)return e.var("props",!0);let r=e.var("props",(0,i._)`{}`);return void 0!==t&&f(e,r,t),r}function f(e,t,r){Object.keys(r).forEach(r=>e.assign((0,i._)`${t}${(0,i.getProperty)(r)}`,!0))}t.toHash=function(e){let t={};for(let r of e)t[r]=!0;return t},t.alwaysValidSchema=function(e,t){return"boolean"==typeof t?t:0===Object.keys(t).length||(o(e,t),!l(t,e.self.RULES.all))},t.checkUnknownRules=o,t.schemaHasRules=l,t.schemaHasRulesButRef=function(e,t){if("boolean"==typeof e)return!e;for(let r in e)if("$ref"!==r&&t.all[r])return!0;return!1},t.schemaRefOrVal=function({topSchemaRef:e,schemaPath:t},r,a,s){if(!s){if("number"==typeof r||"boolean"==typeof r)return r;if("string"==typeof r)return(0,i._)`${r}`}return(0,i._)`${e}${t}${(0,i.getProperty)(a)}`},t.unescapeFragment=function(e){return u(decodeURIComponent(e))},t.escapeFragment=function(e){return encodeURIComponent(d(e))},t.escapeJsonPointer=d,t.unescapeJsonPointer=u,t.eachItem=function(e,t){if(Array.isArray(e))for(let r of e)t(r);else t(e)},t.mergeEvaluated={props:c({mergeNames:(e,t,r)=>e.if((0,i._)`${r} !== true && ${t} !== undefined`,()=>{e.if((0,i._)`${t} === true`,()=>e.assign(r,!0),()=>e.assign(r,(0,i._)`${r} || {}`).code((0,i._)`Object.assign(${r}, ${t})`))}),mergeToName:(e,t,r)=>e.if((0,i._)`${r} !== true`,()=>{!0===t?e.assign(r,!0):(e.assign(r,(0,i._)`${r} || {}`),f(e,r,t))}),mergeValues:(e,t)=>!0===e||{...e,...t},resultToName:h}),items:c({mergeNames:(e,t,r)=>e.if((0,i._)`${r} !== true && ${t} !== undefined`,()=>e.assign(r,(0,i._)`${t} === true ? true : ${r} > ${t} ? ${r} : ${t}`)),mergeToName:(e,t,r)=>e.if((0,i._)`${r} !== true`,()=>e.assign(r,!0===t||(0,i._)`${r} > ${t} ? ${r} : ${t}`)),mergeValues:(e,t)=>!0===e||Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})},t.evaluatedPropsToName=h,t.setEvaluated=f;let p={};function m(e,t,r=e.opts.strictSchema){if(r){if(t=`strict mode: ${t}`,!0===r)throw Error(t);e.self.logger.warn(t)}}t.useFunc=function(e,t){return e.scopeValue("func",{ref:t,code:p[t.code]||(p[t.code]=new n._Code(t.code))})},(s=a||(t.Type=a={}))[s.Num=0]="Num",s[s.Str=1]="Str",t.getErrorPath=function(e,t,r){if(e instanceof i.Name){let s=t===a.Num;return r?s?(0,i._)`"[" + ${e} + "]"`:(0,i._)`"['" + ${e} + "']"`:s?(0,i._)`"/" + ${e}`:(0,i._)`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return r?(0,i.getProperty)(e).toString():"/"+d(e)},t.checkStrictMode=m},74758(e,t){function r(e,t){return t.rules.some(t=>a(e,t))}function a(e,t){var r;return void 0!==e[t.keyword]||(null==(r=t.definition.implements)?void 0:r.some(t=>void 0!==e[t]))}Object.defineProperty(t,"__esModule",{value:!0}),t.shouldUseRule=t.shouldUseGroup=t.schemaHasRulesForType=void 0,t.schemaHasRulesForType=function({schema:e,self:t},a){let s=t.RULES.types[a];return s&&!0!==s&&r(e,s)},t.shouldUseGroup=r,t.shouldUseRule=a},15948(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.boolOrEmptySchema=t.topBoolOrEmptySchema=void 0;let a=r(49409),s=r(17898),i=r(63036),n={message:"boolean schema is false"};function o(e,t){let{gen:r,data:s}=e;(0,a.reportError)({gen:r,keyword:"false schema",data:s,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e},n,void 0,t)}t.topBoolOrEmptySchema=function(e){let{gen:t,schema:r,validateName:a}=e;!1===r?o(e,!1):"object"==typeof r&&!0===r.$async?t.return(i.default.data):(t.assign((0,s._)`${a}.errors`,null),t.return(!0))},t.boolOrEmptySchema=function(e,t){let{gen:r,schema:a}=e;!1===a?(r.var(t,!1),o(e)):r.var(t,!0)}},69003(e,t,r){var a,s;Object.defineProperty(t,"__esModule",{value:!0}),t.reportTypeError=t.checkDataTypes=t.checkDataType=t.coerceAndCheckDataType=t.getJSONTypes=t.getSchemaTypes=t.DataType=void 0;let i=r(90383),n=r(74758),o=r(49409),l=r(17898),d=r(50458);function u(e){let t=Array.isArray(e)?e:e?[e]:[];if(t.every(i.isJSONType))return t;throw Error("type must be JSONType or JSONType[]: "+t.join(","))}(s=a||(t.DataType=a={}))[s.Correct=0]="Correct",s[s.Wrong=1]="Wrong",t.getSchemaTypes=function(e){let t=u(e.type);if(t.includes("null")){if(!1===e.nullable)throw Error("type: null contradicts nullable: false")}else{if(!t.length&&void 0!==e.nullable)throw Error('"nullable" cannot be used without "type"');!0===e.nullable&&t.push("null")}return t},t.getJSONTypes=u,t.coerceAndCheckDataType=function(e,t){var r,s;let{gen:i,data:o,opts:d}=e,u=(r=t,(s=d.coerceTypes)?r.filter(e=>c.has(e)||"array"===s&&"array"===e):[]),h=t.length>0&&!(0===u.length&&1===t.length&&(0,n.schemaHasRulesForType)(e,t[0]));if(h){let r=f(t,o,d.strictNumbers,a.Wrong);i.if(r,()=>{u.length?function(e,t,r){let{gen:a,data:s,opts:i}=e,n=a.let("dataType",(0,l._)`typeof ${s}`),o=a.let("coerced",(0,l._)`undefined`);for(let e of("array"===i.coerceTypes&&a.if((0,l._)`${n} == 'object' && Array.isArray(${s}) && ${s}.length == 1`,()=>a.assign(s,(0,l._)`${s}[0]`).assign(n,(0,l._)`typeof ${s}`).if(f(t,s,i.strictNumbers),()=>a.assign(o,s))),a.if((0,l._)`${o} !== undefined`),r))(c.has(e)||"array"===e&&"array"===i.coerceTypes)&&function(e){switch(e){case"string":a.elseIf((0,l._)`${n} == "number" || ${n} == "boolean"`).assign(o,(0,l._)`"" + ${s}`).elseIf((0,l._)`${s} === null`).assign(o,(0,l._)`""`);return;case"number":a.elseIf((0,l._)`${n} == "boolean" || ${s} === null
2
2
  || (${n} == "string" && ${s} && ${s} == +${s})`).assign(o,(0,l._)`+${s}`);return;case"integer":a.elseIf((0,l._)`${n} === "boolean" || ${s} === null
3
3
  || (${n} === "string" && ${s} && ${s} == +${s} && !(${s} % 1))`).assign(o,(0,l._)`+${s}`);return;case"boolean":a.elseIf((0,l._)`${s} === "false" || ${s} === 0 || ${s} === null`).assign(o,!1).elseIf((0,l._)`${s} === "true" || ${s} === 1`).assign(o,!0);return;case"null":a.elseIf((0,l._)`${s} === "" || ${s} === 0 || ${s} === false`),a.assign(o,null);return;case"array":a.elseIf((0,l._)`${n} === "string" || ${n} === "number"
4
- || ${n} === "boolean" || ${s} === null`).assign(o,(0,l._)`[${s}]`)}}(e);a.else(),m(e),a.endIf(),a.if((0,l._)`${o} !== undefined`,()=>{a.assign(s,o),function({gen:e,parentData:t,parentDataProperty:r},a){e.if((0,l._)`${t} !== undefined`,()=>e.assign((0,l._)`${t}[${r}]`,a))}(e,o)})}(e,t,u):m(e)})}return h};let c=new Set(["string","number","integer","boolean","null"]);function h(e,t,r,s=a.Correct){let i,n=s===a.Correct?l.operators.EQ:l.operators.NEQ;switch(e){case"null":return(0,l._)`${t} ${n} null`;case"array":i=(0,l._)`Array.isArray(${t})`;break;case"object":i=(0,l._)`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;break;case"integer":i=o((0,l._)`!(${t} % 1) && !isNaN(${t})`);break;case"number":i=o();break;default:return(0,l._)`typeof ${t} ${n} ${e}`}return s===a.Correct?i:(0,l.not)(i);function o(e=l.nil){return(0,l.and)((0,l._)`typeof ${t} == "number"`,e,r?(0,l._)`isFinite(${t})`:l.nil)}}function p(e,t,r,a){let s;if(1===e.length)return h(e[0],t,r,a);let i=(0,d.toHash)(e);if(i.array&&i.object){let e=(0,l._)`typeof ${t} != "object"`;s=i.null?e:(0,l._)`!${t} || ${e}`,delete i.null,delete i.array,delete i.object}else s=l.nil;for(let e in i.number&&delete i.integer,i)s=(0,l.and)(s,h(e,t,r,a));return s}t.checkDataType=h,t.checkDataTypes=p;let f={message:({schema:e})=>`must be ${e}`,params:({schema:e,schemaValue:t})=>"string"==typeof e?(0,l._)`{type: ${e}}`:(0,l._)`{type: ${t}}`};function m(e){let t=function(e){let{gen:t,data:r,schema:a}=e,s=(0,d.schemaRefOrVal)(e,a,"type");return{gen:t,keyword:"type",data:r,schema:a.type,schemaCode:s,schemaValue:s,parentSchema:a,params:{},it:e}}(e);(0,o.reportError)(t,f)}t.reportTypeError=m},96841(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.assignDefaults=void 0;let a=r(17898),s=r(50458);function i(e,t,r){let{gen:i,compositeRule:n,data:o,opts:l}=e;if(void 0===r)return;let d=(0,a._)`${o}${(0,a.getProperty)(t)}`;if(n)return void(0,s.checkStrictMode)(e,`default is ignored for: ${d}`);let u=(0,a._)`${d} === undefined`;"empty"===l.useDefaults&&(u=(0,a._)`${u} || ${d} === null || ${d} === ""`),i.if(u,(0,a._)`${d} = ${(0,a.stringify)(r)}`)}t.assignDefaults=function(e,t){let{properties:r,items:a}=e.schema;if("object"===t&&r)for(let t in r)i(e,t,r[t].default);else"array"===t&&Array.isArray(a)&&a.forEach((t,r)=>i(e,r,t.default))}},96223(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.getData=t.KeywordCxt=t.validateFunctionCode=void 0;let a=r(15948),s=r(69003),i=r(74758),n=r(69003),o=r(96841),l=r(49348),d=r(53322),u=r(17898),c=r(63036),h=r(14856),p=r(50458),f=r(49409);function m({gen:e,validateName:t,schema:r,schemaEnv:a,opts:s},i){var n;s.code.es5?e.func(t,(0,u._)`${c.default.data}, ${c.default.valCxt}`,a.$async,()=>{var t,a;e.code((0,u._)`"use strict"; ${y(r,s)}`),t=e,a=s,t.if(c.default.valCxt,()=>{t.var(c.default.instancePath,(0,u._)`${c.default.valCxt}.${c.default.instancePath}`),t.var(c.default.parentData,(0,u._)`${c.default.valCxt}.${c.default.parentData}`),t.var(c.default.parentDataProperty,(0,u._)`${c.default.valCxt}.${c.default.parentDataProperty}`),t.var(c.default.rootData,(0,u._)`${c.default.valCxt}.${c.default.rootData}`),a.dynamicRef&&t.var(c.default.dynamicAnchors,(0,u._)`${c.default.valCxt}.${c.default.dynamicAnchors}`)},()=>{t.var(c.default.instancePath,(0,u._)`""`),t.var(c.default.parentData,(0,u._)`undefined`),t.var(c.default.parentDataProperty,(0,u._)`undefined`),t.var(c.default.rootData,c.default.data),a.dynamicRef&&t.var(c.default.dynamicAnchors,(0,u._)`{}`)}),e.code(i)}):e.func(t,(0,u._)`${c.default.data}, ${(n=s,(0,u._)`{${c.default.instancePath}="", ${c.default.parentData}, ${c.default.parentDataProperty}, ${c.default.rootData}=${c.default.data}${n.dynamicRef?(0,u._)`, ${c.default.dynamicAnchors}={}`:u.nil}}={}`)}`,a.$async,()=>e.code(y(r,s)).code(i))}function y(e,t){let r="object"==typeof e&&e[t.schemaId];return r&&(t.code.source||t.code.process)?(0,u._)`/*# sourceURL=${r} */`:u.nil}function g({schema:e,self:t}){if("boolean"==typeof e)return!e;for(let r in e)if(t.RULES.all[r])return!0;return!1}function v(e){return"boolean"!=typeof e.schema}function _(e){(0,p.checkUnknownRules)(e),function(e){let{schema:t,errSchemaPath:r,opts:a,self:s}=e;t.$ref&&a.ignoreKeywordsWithRef&&(0,p.schemaHasRulesButRef)(t,s.RULES)&&s.logger.warn(`$ref: keywords ignored in schema at path "${r}"`)}(e)}function $(e,t){if(e.opts.jtd)return w(e,[],!1,t);let r=(0,s.getSchemaTypes)(e.schema),a=(0,s.coerceAndCheckDataType)(e,r);w(e,r,!a,t)}function b({gen:e,schemaEnv:t,schema:r,errSchemaPath:a,opts:s}){let i=r.$comment;if(!0===s.$comment)e.code((0,u._)`${c.default.self}.logger.log(${i})`);else if("function"==typeof s.$comment){let r=(0,u.str)`${a}/$comment`,s=e.scopeValue("root",{ref:t.root});e.code((0,u._)`${c.default.self}.opts.$comment(${i}, ${r}, ${s}.schema)`)}}function w(e,t,r,a){var s,o,l,d;let{gen:h,schema:f,data:m,allErrors:y,opts:g,self:v}=e,{RULES:_}=v;if(f.$ref&&(g.ignoreKeywordsWithRef||!(0,p.schemaHasRulesButRef)(f,_)))return void h.block(()=>E(e,"$ref",_.all.$ref.definition));function $(s){(0,i.shouldUseGroup)(f,s)&&(s.type?(h.if((0,n.checkDataType)(s.type,m,g.strictNumbers)),k(e,s),1===t.length&&t[0]===s.type&&r&&(h.else(),(0,n.reportTypeError)(e)),h.endIf()):k(e,s),y||h.if((0,u._)`${c.default.errors} === ${a||0}`))}g.jtd||(s=e,o=t,!s.schemaEnv.meta&&s.opts.strictTypes&&(function(e,t){if(t.length){if(!e.dataTypes.length){e.dataTypes=t;return}t.forEach(t=>{x(e.dataTypes,t)||P(e,`type "${t}" not allowed by context "${e.dataTypes.join(",")}"`)}),function(e,t){let r=[];for(let a of e.dataTypes)x(t,a)?r.push(a):t.includes("integer")&&"number"===a&&r.push("integer");e.dataTypes=r}(e,t)}}(s,o),s.opts.allowUnionTypes||(l=s,(d=o).length>1&&!(2===d.length&&d.includes("null"))&&P(l,"use allowUnionTypes to allow union type keyword")),function(e,t){let r=e.self.RULES.all;for(let a in r){let s=r[a];if("object"==typeof s&&(0,i.shouldUseRule)(e.schema,s)){let{type:r}=s.definition;r.length&&!r.some(e=>{var r,a;return r=t,a=e,r.includes(a)||"number"===a&&r.includes("integer")})&&P(e,`missing type "${r.join(",")}" for keyword "${a}"`)}}}(s,s.dataTypes))),h.block(()=>{for(let e of _.rules)$(e);$(_.post)})}function k(e,t){let{gen:r,schema:a,opts:{useDefaults:s}}=e;s&&(0,o.assignDefaults)(e,t.type),r.block(()=>{for(let r of t.rules)(0,i.shouldUseRule)(a,r)&&E(e,r.keyword,r.definition,t.type)})}function x(e,t){return e.includes(t)||"integer"===t&&e.includes("number")}function P(e,t){let r=e.schemaEnv.baseId+e.errSchemaPath;t+=` at "${r}" (strictTypes)`,(0,p.checkStrictMode)(e,t,e.opts.strictTypes)}t.validateFunctionCode=function(e){v(e)&&(_(e),g(e))?function(e){let{schema:t,opts:r,gen:a}=e;m(e,()=>{r.$comment&&t.$comment&&b(e),function(e){let{schema:t,opts:r}=e;void 0!==t.default&&r.useDefaults&&r.strictSchema&&(0,p.checkStrictMode)(e,"default is ignored in the schema root")}(e),a.let(c.default.vErrors,null),a.let(c.default.errors,0),r.unevaluated&&function(e){let{gen:t,validateName:r}=e;e.evaluated=t.const("evaluated",(0,u._)`${r}.evaluated`),t.if((0,u._)`${e.evaluated}.dynamicProps`,()=>t.assign((0,u._)`${e.evaluated}.props`,(0,u._)`undefined`)),t.if((0,u._)`${e.evaluated}.dynamicItems`,()=>t.assign((0,u._)`${e.evaluated}.items`,(0,u._)`undefined`))}(e),$(e),function(e){let{gen:t,schemaEnv:r,validateName:a,ValidationError:s,opts:i}=e;r.$async?t.if((0,u._)`${c.default.errors} === 0`,()=>t.return(c.default.data),()=>t.throw((0,u._)`new ${s}(${c.default.vErrors})`)):(t.assign((0,u._)`${a}.errors`,c.default.vErrors),i.unevaluated&&function({gen:e,evaluated:t,props:r,items:a}){r instanceof u.Name&&e.assign((0,u._)`${t}.props`,r),a instanceof u.Name&&e.assign((0,u._)`${t}.items`,a)}(e),t.return((0,u._)`${c.default.errors} === 0`))}(e)})}(e):m(e,()=>(0,a.topBoolOrEmptySchema)(e))};class S{constructor(e,t,r){if((0,l.validateKeywordUsage)(e,t,r),this.gen=e.gen,this.allErrors=e.allErrors,this.keyword=r,this.data=e.data,this.schema=e.schema[r],this.$data=t.$data&&e.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,p.schemaRefOrVal)(e,this.schema,r,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",O(this.$data,e));else if(this.schemaCode=this.schemaValue,!(0,l.validSchemaType)(this.schema,t.schemaType,t.allowUndefined))throw Error(`${r} value must be ${JSON.stringify(t.schemaType)}`);("code"in t?t.trackErrors:!1!==t.errors)&&(this.errsCount=e.gen.const("_errs",c.default.errors))}result(e,t,r){this.failResult((0,u.not)(e),t,r)}failResult(e,t,r){this.gen.if(e),r?r():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,u.not)(e),void 0,t)}fail(e){if(void 0===e){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,u._)`${t} !== undefined && (${(0,u.or)(this.invalid$data(),e)})`)}error(e,t,r){if(t){this.setParams(t),this._error(e,r),this.setParams({});return}this._error(e,r)}_error(e,t){(e?f.reportExtraError:f.reportError)(this,this.def.error,t)}$dataError(){(0,f.reportError)(this,this.def.$dataError||f.keyword$DataError)}reset(){if(void 0===this.errsCount)throw Error('add "trackErrors" to keyword definition');(0,f.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,r=u.nil){this.gen.block(()=>{this.check$data(e,r),t()})}check$data(e=u.nil,t=u.nil){if(!this.$data)return;let{gen:r,schemaCode:a,schemaType:s,def:i}=this;r.if((0,u.or)((0,u._)`${a} === undefined`,t)),e!==u.nil&&r.assign(e,!0),(s.length||i.validateSchema)&&(r.elseIf(this.invalid$data()),this.$dataError(),e!==u.nil&&r.assign(e,!1)),r.else()}invalid$data(){let{gen:e,schemaCode:t,schemaType:r,def:a,it:s}=this;return(0,u.or)(function(){if(r.length){if(!(t instanceof u.Name))throw Error("ajv implementation error");let e=Array.isArray(r)?r:[r];return(0,u._)`${(0,n.checkDataTypes)(e,t,s.opts.strictNumbers,n.DataType.Wrong)}`}return u.nil}(),function(){if(a.validateSchema){let r=e.scopeValue("validate$data",{ref:a.validateSchema});return(0,u._)`!${r}(${t})`}return u.nil}())}subschema(e,t){let r=(0,d.getSubschema)(this.it,e);(0,d.extendSubschemaData)(r,this.it,e),(0,d.extendSubschemaMode)(r,e);let s={...this.it,...r,items:void 0,props:void 0};return!function(e,t){if(v(e)&&(_(e),g(e)))return function(e,t){var r;let a,{schema:s,gen:i,opts:n}=e;n.$comment&&s.$comment&&b(e),(a=(r=e).schema[r.opts.schemaId])&&(r.baseId=(0,h.resolveUrl)(r.opts.uriResolver,r.baseId,a)),function(e){if(e.schema.$async&&!e.schemaEnv.$async)throw Error("async schema in sync schema")}(e);let o=i.const("_errs",c.default.errors);$(e,o),i.var(t,(0,u._)`${o} === ${c.default.errors}`)}(e,t);(0,a.boolOrEmptySchema)(e,t)}(s,t),s}mergeEvaluated(e,t){let{it:r,gen:a}=this;r.opts.unevaluated&&(!0!==r.props&&void 0!==e.props&&(r.props=p.mergeEvaluated.props(a,e.props,r.props,t)),!0!==r.items&&void 0!==e.items&&(r.items=p.mergeEvaluated.items(a,e.items,r.items,t)))}mergeValidEvaluated(e,t){let{it:r,gen:a}=this;if(r.opts.unevaluated&&(!0!==r.props||!0!==r.items))return a.if(t,()=>this.mergeEvaluated(e,u.Name)),!0}}function E(e,t,r,a){let s=new S(e,r,t);"code"in r?r.code(s,a):s.$data&&r.validate?(0,l.funcKeywordCode)(s,r):"macro"in r?(0,l.macroKeywordCode)(s,r):(r.compile||r.validate)&&(0,l.funcKeywordCode)(s,r)}t.KeywordCxt=S;let j=/^\/(?:[^~]|~0|~1)*$/,N=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function O(e,{dataLevel:t,dataNames:r,dataPathArr:a}){let s,i;if(""===e)return c.default.rootData;if("/"===e[0]){if(!j.test(e))throw Error(`Invalid JSON-pointer: ${e}`);s=e,i=c.default.rootData}else{let n=N.exec(e);if(!n)throw Error(`Invalid JSON-pointer: ${e}`);let l=+n[1];if("#"===(s=n[2])){if(l>=t)throw Error(o("property/index",l));return a[t-l]}if(l>t)throw Error(o("data",l));if(i=r[t-l],!s)return i}let n=i;for(let e of s.split("/"))e&&(i=(0,u._)`${i}${(0,u.getProperty)((0,p.unescapeJsonPointer)(e))}`,n=(0,u._)`${n} && ${i}`);return n;function o(e,r){return`Cannot access ${e} ${r} levels up, current level is ${t}`}}t.getData=O},49348(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateKeywordUsage=t.validSchemaType=t.funcKeywordCode=t.macroKeywordCode=void 0;let a=r(17898),s=r(63036),i=r(94450),n=r(49409);function o(e){let{gen:t,data:r,it:s}=e;t.if(s.parentData,()=>t.assign(r,(0,a._)`${s.parentData}[${s.parentDataProperty}]`))}function l(e,t,r){if(void 0===r)throw Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword","function"==typeof r?{ref:r}:{ref:r,code:(0,a.stringify)(r)})}t.macroKeywordCode=function(e,t){let{gen:r,keyword:s,schema:i,parentSchema:n,it:o}=e,d=t.macro.call(o.self,i,n,o),u=l(r,s,d);!1!==o.opts.validateSchema&&o.self.validateSchema(d,!0);let c=r.name("valid");e.subschema({schema:d,schemaPath:a.nil,errSchemaPath:`${o.errSchemaPath}/${s}`,topSchemaRef:u,compositeRule:!0},c),e.pass(c,()=>e.error(!0))},t.funcKeywordCode=function(e,t){var r;let{gen:d,keyword:u,schema:c,parentSchema:h,$data:p,it:f}=e;!function({schemaEnv:e},t){if(t.async&&!e.$async)throw Error("async keyword in sync schema")}(f,t);let m=l(d,u,!p&&t.compile?t.compile.call(f.self,c,h,f):t.validate),y=d.let("valid");function g(r=t.async?(0,a._)`await `:a.nil){let n=f.opts.passContext?s.default.this:s.default.self,o=!("compile"in t&&!p||!1===t.schema);d.assign(y,(0,a._)`${r}${(0,i.callValidateCode)(e,m,n,o)}`,t.modifying)}function v(e){var r;d.if((0,a.not)(null!=(r=t.valid)?r:y),e)}e.block$data(y,function(){if(!1===t.errors)g(),t.modifying&&o(e),v(()=>e.error());else{let r,i,l=t.async?(r=d.let("ruleErrs",null),d.try(()=>g((0,a._)`await `),e=>d.assign(y,!1).if((0,a._)`${e} instanceof ${f.ValidationError}`,()=>d.assign(r,(0,a._)`${e}.errors`),()=>d.throw(e))),r):(i=(0,a._)`${m}.errors`,d.assign(i,null),g(a.nil),i);t.modifying&&o(e),v(()=>(function(e,t){let{gen:r}=e;r.if((0,a._)`Array.isArray(${t})`,()=>{r.assign(s.default.vErrors,(0,a._)`${s.default.vErrors} === null ? ${t} : ${s.default.vErrors}.concat(${t})`).assign(s.default.errors,(0,a._)`${s.default.vErrors}.length`),(0,n.extendErrors)(e)},()=>e.error())})(e,l))}}),e.ok(null!=(r=t.valid)?r:y)},t.validSchemaType=function(e,t,r=!1){return!t.length||t.some(t=>"array"===t?Array.isArray(e):"object"===t?e&&"object"==typeof e&&!Array.isArray(e):typeof e==t||r&&void 0===e)},t.validateKeywordUsage=function({schema:e,opts:t,self:r,errSchemaPath:a},s,i){if(Array.isArray(s.keyword)?!s.keyword.includes(i):s.keyword!==i)throw Error("ajv implementation error");let n=s.dependencies;if(null==n?void 0:n.some(t=>!Object.prototype.hasOwnProperty.call(e,t)))throw Error(`parent schema must have dependencies of ${i}: ${n.join(",")}`);if(s.validateSchema&&!s.validateSchema(e[i])){let e=`keyword "${i}" value is invalid at path "${a}": `+r.errorsText(s.validateSchema.errors);if("log"===t.validateSchema)r.logger.error(e);else throw Error(e)}}},53322(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.extendSubschemaMode=t.extendSubschemaData=t.getSubschema=void 0;let a=r(17898),s=r(50458);t.getSubschema=function(e,{keyword:t,schemaProp:r,schema:i,schemaPath:n,errSchemaPath:o,topSchemaRef:l}){if(void 0!==t&&void 0!==i)throw Error('both "keyword" and "schema" passed, only one allowed');if(void 0!==t){let i=e.schema[t];return void 0===r?{schema:i,schemaPath:(0,a._)`${e.schemaPath}${(0,a.getProperty)(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:i[r],schemaPath:(0,a._)`${e.schemaPath}${(0,a.getProperty)(t)}${(0,a.getProperty)(r)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${(0,s.escapeFragment)(r)}`}}if(void 0!==i){if(void 0===n||void 0===o||void 0===l)throw Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:i,schemaPath:n,topSchemaRef:l,errSchemaPath:o}}throw Error('either "keyword" or "schema" must be passed')},t.extendSubschemaData=function(e,t,{dataProp:r,dataPropType:i,data:n,dataTypes:o,propertyName:l}){if(void 0!==n&&void 0!==r)throw Error('both "data" and "dataProp" passed, only one allowed');let{gen:d}=t;if(void 0!==r){let{errorPath:n,dataPathArr:o,opts:l}=t;u(d.let("data",(0,a._)`${t.data}${(0,a.getProperty)(r)}`,!0)),e.errorPath=(0,a.str)`${n}${(0,s.getErrorPath)(r,i,l.jsPropertySyntax)}`,e.parentDataProperty=(0,a._)`${r}`,e.dataPathArr=[...o,e.parentDataProperty]}function u(r){e.data=r,e.dataLevel=t.dataLevel+1,e.dataTypes=[],t.definedProperties=new Set,e.parentData=t.data,e.dataNames=[...t.dataNames,r]}void 0!==n&&(u(n instanceof a.Name?n:d.let("data",n,!0)),void 0!==l&&(e.propertyName=l)),o&&(e.dataTypes=o)},t.extendSubschemaMode=function(e,{jtdDiscriminator:t,jtdMetadata:r,compositeRule:a,createErrors:s,allErrors:i}){void 0!==a&&(e.compositeRule=a),void 0!==s&&(e.createErrors=s),void 0!==i&&(e.allErrors=i),e.jtdDiscriminator=t,e.jtdMetadata=r}},65319(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=void 0;var a=r(96223);Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return a.KeywordCxt}});var s=r(17898);Object.defineProperty(t,"_",{enumerable:!0,get:function(){return s._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return s.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return s.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return s.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return s.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return s.CodeGen}});let i=r(95031),n=r(85748),o=r(90383),l=r(49392),d=r(17898),u=r(14856),c=r(69003),h=r(50458),p=r(93770),f=r(7903),m=(e,t)=>new RegExp(e,t);m.code="new RegExp";let y=["removeAdditional","useDefaults","coerceTypes"],g=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),v={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."},_={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'};class ${constructor(e={}){this.schemas={},this.refs={},this.formats=Object.create(null),this._compilations=new Set,this._loading={},this._cache=new Map,e=this.opts={...e,...function(e){var t,r,a,s,i,n,o,l,d,u,c,h,p,y,g,v,_,$,b,w,k,x,P,S,E;let j=e.strict,N=null==(t=e.code)?void 0:t.optimize,O=!0===N||void 0===N?1:N||0,T=null!=(a=null==(r=e.code)?void 0:r.regExp)?a:m,C=null!=(s=e.uriResolver)?s:f.default;return{strictSchema:null==(n=null!=(i=e.strictSchema)?i:j)||n,strictNumbers:null==(l=null!=(o=e.strictNumbers)?o:j)||l,strictTypes:null!=(u=null!=(d=e.strictTypes)?d:j)?u:"log",strictTuples:null!=(h=null!=(c=e.strictTuples)?c:j)?h:"log",strictRequired:null!=(y=null!=(p=e.strictRequired)?p:j)&&y,code:e.code?{...e.code,optimize:O,regExp:T}:{optimize:O,regExp:T},loopRequired:null!=(g=e.loopRequired)?g:200,loopEnum:null!=(v=e.loopEnum)?v:200,meta:null==(_=e.meta)||_,messages:null==($=e.messages)||$,inlineRefs:null==(b=e.inlineRefs)||b,schemaId:null!=(w=e.schemaId)?w:"$id",addUsedSchema:null==(k=e.addUsedSchema)||k,validateSchema:null==(x=e.validateSchema)||x,validateFormats:null==(P=e.validateFormats)||P,unicodeRegExp:null==(S=e.unicodeRegExp)||S,int32range:null==(E=e.int32range)||E,uriResolver:C}}(e)};const{es5:t,lines:r}=this.opts.code;this.scope=new d.ValueScope({scope:{},prefixes:g,es5:t,lines:r}),this.logger=function(e){if(!1===e)return E;if(void 0===e)return console;if(e.log&&e.warn&&e.error)return e;throw Error("logger must implement log, warn and error methods")}(e.logger);const a=e.validateFormats;e.validateFormats=!1,this.RULES=(0,o.getRules)(),b.call(this,v,e,"NOT SUPPORTED"),b.call(this,_,e,"DEPRECATED","warn"),this._metaOpts=S.call(this),e.formats&&x.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),e.keywords&&P.call(this,e.keywords),"object"==typeof e.meta&&this.addMetaSchema(e.meta),k.call(this),e.validateFormats=a}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){let{$data:e,meta:t,schemaId:r}=this.opts,a=p;"id"===r&&((a={...p}).id=a.$id,delete a.$id),t&&e&&this.addMetaSchema(a,a[r],!1)}defaultMeta(){let{meta:e,schemaId:t}=this.opts;return this.opts.defaultMeta="object"==typeof e?e[t]||e:void 0}validate(e,t){let r;if("string"==typeof e){if(!(r=this.getSchema(e)))throw Error(`no schema with key or ref "${e}"`)}else r=this.compile(e);let a=r(t);return"$async"in r||(this.errors=r.errors),a}compile(e,t){let r=this._addSchema(e,t);return r.validate||this._compileSchemaEnv(r)}compileAsync(e,t){if("function"!=typeof this.opts.loadSchema)throw Error("options.loadSchema should be a function");let{loadSchema:r}=this.opts;return a.call(this,e,t);async function a(e,t){await s.call(this,e.$schema);let r=this._addSchema(e,t);return r.validate||i.call(this,r)}async function s(e){e&&!this.getSchema(e)&&await a.call(this,{$ref:e},!0)}async function i(e){try{return this._compileSchemaEnv(e)}catch(t){if(!(t instanceof n.default))throw t;return o.call(this,t),await l.call(this,t.missingSchema),i.call(this,e)}}function o({missingSchema:e,missingRef:t}){if(this.refs[e])throw Error(`AnySchema ${e} is loaded but ${t} cannot be resolved`)}async function l(e){let r=await d.call(this,e);this.refs[e]||await s.call(this,r.$schema),this.refs[e]||this.addSchema(r,e,t)}async function d(e){let t=this._loading[e];if(t)return t;try{return await (this._loading[e]=r(e))}finally{delete this._loading[e]}}}addSchema(e,t,r,a=this.opts.validateSchema){let s;if(Array.isArray(e)){for(let t of e)this.addSchema(t,void 0,r,a);return this}if("object"==typeof e){let{schemaId:t}=this.opts;if(void 0!==(s=e[t])&&"string"!=typeof s)throw Error(`schema ${t} must be string`)}return t=(0,u.normalizeId)(t||s),this._checkUnique(t),this.schemas[t]=this._addSchema(e,r,t,a,!0),this}addMetaSchema(e,t,r=this.opts.validateSchema){return this.addSchema(e,t,!0,r),this}validateSchema(e,t){let r;if("boolean"==typeof e)return!0;if(void 0!==(r=e.$schema)&&"string"!=typeof r)throw Error("$schema must be a string");if(!(r=r||this.opts.defaultMeta||this.defaultMeta()))return this.logger.warn("meta-schema not available"),this.errors=null,!0;let a=this.validate(r,e);if(!a&&t){let e="schema is invalid: "+this.errorsText();if("log"===this.opts.validateSchema)this.logger.error(e);else throw Error(e)}return a}getSchema(e){let t;for(;"string"==typeof(t=w.call(this,e));)e=t;if(void 0===t){let{schemaId:r}=this.opts,a=new l.SchemaEnv({schema:{},schemaId:r});if(!(t=l.resolveSchema.call(this,a,e)))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=w.call(this,e);return"object"==typeof t&&this._cache.delete(t.schema),delete this.schemas[e],delete this.refs[e],this}case"object":{this._cache.delete(e);let t=e[this.opts.schemaId];return t&&(t=(0,u.normalizeId)(t),delete this.schemas[t],delete this.refs[t]),this}default:throw Error("ajv.removeSchema: invalid parameter")}}addVocabulary(e){for(let t of e)this.addKeyword(t);return this}addKeyword(e,t){let r;if("string"==typeof e)r=e,"object"==typeof t&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),t.keyword=r);else if("object"==typeof e&&void 0===t){if(Array.isArray(r=(t=e).keyword)&&!r.length)throw Error("addKeywords: keyword must be string or non-empty array")}else throw Error("invalid addKeywords parameters");if(N.call(this,r,t),!t)return(0,h.eachItem)(r,e=>O.call(this,e)),this;C.call(this,t);let a={...t,type:(0,c.getJSONTypes)(t.type),schemaType:(0,c.getJSONTypes)(t.schemaType)};return(0,h.eachItem)(r,0===a.type.length?e=>O.call(this,e,a):e=>a.type.forEach(t=>O.call(this,e,a,t))),this}getKeyword(e){let t=this.RULES.all[e];return"object"==typeof t?t.definition:!!t}removeKeyword(e){let{RULES:t}=this;for(let r of(delete t.keywords[e],delete t.all[e],t.rules)){let t=r.rules.findIndex(t=>t.keyword===e);t>=0&&r.rules.splice(t,1)}return this}addFormat(e,t){return"string"==typeof t&&(t=new RegExp(t)),this.formats[e]=t,this}errorsText(e=this.errors,{separator:t=", ",dataVar:r="data"}={}){return e&&0!==e.length?e.map(e=>`${r}${e.instancePath} ${e.message}`).reduce((e,r)=>e+t+r):"No errors"}$dataMetaSchema(e,t){let r=this.RULES.all;for(let a of(e=JSON.parse(JSON.stringify(e)),t)){let t=a.split("/").slice(1),s=e;for(let e of t)s=s[e];for(let e in r){let t=r[e];if("object"!=typeof t)continue;let{$data:a}=t.definition,i=s[e];a&&i&&(s[e]=I(i))}}return e}_removeAllSchemas(e,t){for(let r in e){let a=e[r];(!t||t.test(r))&&("string"==typeof a?delete e[r]:a&&!a.meta&&(this._cache.delete(a.schema),delete e[r]))}}_addSchema(e,t,r,a=this.opts.validateSchema,s=this.opts.addUsedSchema){let i,{schemaId:n}=this.opts;if("object"==typeof e)i=e[n];else if(this.opts.jtd)throw Error("schema must be object");else if("boolean"!=typeof e)throw Error("schema must be object or boolean");let o=this._cache.get(e);if(void 0!==o)return o;r=(0,u.normalizeId)(i||r);let d=u.getSchemaRefs.call(this,e,r);return o=new l.SchemaEnv({schema:e,schemaId:n,meta:t,baseId:r,localRefs:d}),this._cache.set(o.schema,o),s&&!r.startsWith("#")&&(r&&this._checkUnique(r),this.refs[r]=o),a&&this.validateSchema(e,!0),o}_checkUnique(e){if(this.schemas[e]||this.refs[e])throw Error(`schema with key or id "${e}" already exists`)}_compileSchemaEnv(e){if(e.meta?this._compileMetaSchema(e):l.compileSchema.call(this,e),!e.validate)throw Error("ajv implementation error");return e.validate}_compileMetaSchema(e){let t=this.opts;this.opts=this._metaOpts;try{l.compileSchema.call(this,e)}finally{this.opts=t}}}function b(e,t,r,a="error"){for(let s in e)s in t&&this.logger[a](`${r}: option ${s}. ${e[s]}`)}function w(e){return e=(0,u.normalizeId)(e),this.schemas[e]||this.refs[e]}function k(){let e=this.opts.schemas;if(e)if(Array.isArray(e))this.addSchema(e);else for(let t in e)this.addSchema(e[t],t)}function x(){for(let e in this.opts.formats){let t=this.opts.formats[e];t&&this.addFormat(e,t)}}function P(e){if(Array.isArray(e))return void this.addVocabulary(e);for(let t in this.logger.warn("keywords option as map is deprecated, pass array"),e){let r=e[t];r.keyword||(r.keyword=t),this.addKeyword(r)}}function S(){let e={...this.opts};for(let t of y)delete e[t];return e}$.ValidationError=i.default,$.MissingRefError=n.default,t.default=$;let E={log(){},warn(){},error(){}},j=/^[a-z_$][a-z0-9_$:-]*$/i;function N(e,t){let{RULES:r}=this;if((0,h.eachItem)(e,e=>{if(r.keywords[e])throw Error(`Keyword ${e} is already defined`);if(!j.test(e))throw Error(`Keyword ${e} has invalid name`)}),t&&t.$data&&!("code"in t||"validate"in t))throw Error('$data keyword must have "code" or "validate" function')}function O(e,t,r){var a;let s=null==t?void 0:t.post;if(r&&s)throw Error('keyword with "post" flag cannot have "type"');let{RULES:i}=this,n=s?i.post:i.rules.find(({type:e})=>e===r);if(n||(n={type:r,rules:[]},i.rules.push(n)),i.keywords[e]=!0,!t)return;let o={keyword:e,definition:{...t,type:(0,c.getJSONTypes)(t.type),schemaType:(0,c.getJSONTypes)(t.schemaType)}};t.before?T.call(this,n,o,t.before):n.rules.push(o),i.all[e]=o,null==(a=t.implements)||a.forEach(e=>this.addKeyword(e))}function T(e,t,r){let a=e.rules.findIndex(e=>e.keyword===r);a>=0?e.rules.splice(a,0,t):(e.rules.push(t),this.logger.warn(`rule ${r} is not defined`))}function C(e){let{metaSchema:t}=e;void 0!==t&&(e.$data&&this.opts.$data&&(t=I(t)),e.validateSchema=this.compile(t,!0))}let R={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function I(e){return{anyOf:[e,R]}}},72725(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(38792);a.code='require("ajv/dist/runtime/equal").default',t.default=a},26308(e,t){function r(e){let t,r=e.length,a=0,s=0;for(;s<r;)a++,(t=e.charCodeAt(s++))>=55296&&t<=56319&&s<r&&(64512&(t=e.charCodeAt(s)))==56320&&s++;return a}Object.defineProperty(t,"__esModule",{value:!0}),t.default=r,r.code='require("ajv/dist/runtime/ucs2length").default'},7903(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(84800);a.code='require("ajv/dist/runtime/uri").default',t.default=a},95031(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=class extends Error{constructor(e){super("validation failed"),this.errors=e,this.ajv=this.validation=!0}}},93426(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateAdditionalItems=void 0;let a=r(17898),s=r(50458);function i(e,t){let{gen:r,schema:i,data:n,keyword:o,it:l}=e;l.items=!0;let d=r.const("len",(0,a._)`${n}.length`);if(!1===i)e.setParams({len:t.length}),e.pass((0,a._)`${d} <= ${t.length}`);else if("object"==typeof i&&!(0,s.alwaysValidSchema)(l,i)){let i=r.var("valid",(0,a._)`${d} <= ${t.length}`);r.if((0,a.not)(i),()=>{var n;return n=i,void r.forRange("i",t.length,d,t=>{e.subschema({keyword:o,dataProp:t,dataPropType:s.Type.Num},n),l.allErrors||r.if((0,a.not)(n),()=>r.break())})}),e.ok(i)}}t.validateAdditionalItems=i,t.default={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:{message:({params:{len:e}})=>(0,a.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,a._)`{limit: ${e}}`},code(e){let{parentSchema:t,it:r}=e,{items:a}=t;Array.isArray(a)?i(e,a):(0,s.checkStrictMode)(r,'"additionalItems" is ignored when "items" is not an array of schemas')}}},92697(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(94450),s=r(17898),i=r(63036),n=r(50458);t.default={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:{message:"must NOT have additional properties",params:({params:e})=>(0,s._)`{additionalProperty: ${e.additionalProperty}}`},code(e){let{gen:t,schema:r,parentSchema:o,data:l,errsCount:d,it:u}=e;if(!d)throw Error("ajv implementation error");let{allErrors:c,opts:h}=u;if(u.props=!0,"all"!==h.removeAdditional&&(0,n.alwaysValidSchema)(u,r))return;let p=(0,a.allSchemaProperties)(o.properties),f=(0,a.allSchemaProperties)(o.patternProperties);function m(e){t.code((0,s._)`delete ${l}[${e}]`)}function y(a){if("all"===h.removeAdditional||h.removeAdditional&&!1===r)return void m(a);if(!1===r){e.setParams({additionalProperty:a}),e.error(),c||t.break();return}if("object"==typeof r&&!(0,n.alwaysValidSchema)(u,r)){let r=t.name("valid");"failing"===h.removeAdditional?(g(a,r,!1),t.if((0,s.not)(r),()=>{e.reset(),m(a)})):(g(a,r),c||t.if((0,s.not)(r),()=>t.break()))}}function g(t,r,a){let s={keyword:"additionalProperties",dataProp:t,dataPropType:n.Type.Str};!1===a&&Object.assign(s,{compositeRule:!0,createErrors:!1,allErrors:!1}),e.subschema(s,r)}t.forIn("key",l,r=>{p.length||f.length?t.if(function(r){let i;if(p.length>8){let e=(0,n.schemaRefOrVal)(u,o.properties,"properties");i=(0,a.isOwnProperty)(t,e,r)}else i=p.length?(0,s.or)(...p.map(e=>(0,s._)`${r} === ${e}`)):s.nil;return f.length&&(i=(0,s.or)(i,...f.map(t=>(0,s._)`${(0,a.usePattern)(e,t)}.test(${r})`))),(0,s.not)(i)}(r),()=>y(r)):y(r)}),e.ok((0,s._)`${d} === ${i.default.errors}`)}}},79355(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(50458);t.default={keyword:"allOf",schemaType:"array",code(e){let{gen:t,schema:r,it:s}=e;if(!Array.isArray(r))throw Error("ajv implementation error");let i=t.name("valid");r.forEach((t,r)=>{if((0,a.alwaysValidSchema)(s,t))return;let n=e.subschema({keyword:"allOf",schemaProp:r},i);e.ok(i),e.mergeEvaluated(n)})}}},19430(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.default={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:r(94450).validateUnion,error:{message:"must match a schema in anyOf"}}},35724(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=r(50458);t.default={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:{message:({params:{min:e,max:t}})=>void 0===t?(0,a.str)`must contain at least ${e} valid item(s)`:(0,a.str)`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>void 0===t?(0,a._)`{minContains: ${e}}`:(0,a._)`{minContains: ${e}, maxContains: ${t}}`},code(e){let t,r,{gen:i,schema:n,parentSchema:o,data:l,it:d}=e,{minContains:u,maxContains:c}=o;d.opts.next?(t=void 0===u?1:u,r=c):t=1;let h=i.const("len",(0,a._)`${l}.length`);if(e.setParams({min:t,max:r}),void 0===r&&0===t)return void(0,s.checkStrictMode)(d,'"minContains" == 0 without "maxContains": "contains" keyword ignored');if(void 0!==r&&t>r){(0,s.checkStrictMode)(d,'"minContains" > "maxContains" is always invalid'),e.fail();return}if((0,s.alwaysValidSchema)(d,n)){let s=(0,a._)`${h} >= ${t}`;void 0!==r&&(s=(0,a._)`${s} && ${h} <= ${r}`),e.pass(s);return}d.items=!0;let p=i.name("valid");function f(){let e=i.name("_valid"),s=i.let("count",0);m(e,()=>i.if(e,()=>{var e;return e=s,void(i.code((0,a._)`${e}++`),void 0===r?i.if((0,a._)`${e} >= ${t}`,()=>i.assign(p,!0).break()):(i.if((0,a._)`${e} > ${r}`,()=>i.assign(p,!1).break()),1===t?i.assign(p,!0):i.if((0,a._)`${e} >= ${t}`,()=>i.assign(p,!0))))}))}function m(t,r){i.forRange("i",0,h,a=>{e.subschema({keyword:"contains",dataProp:a,dataPropType:s.Type.Num,compositeRule:!0},t),r()})}void 0===r&&1===t?m(p,()=>i.if(p,()=>i.break())):0===t?(i.let(p,!0),void 0!==r&&i.if((0,a._)`${l}.length > 0`,f)):(i.let(p,!1),f()),e.result(p,()=>e.reset())}}},99868(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateSchemaDeps=t.validatePropertyDeps=t.error=void 0;let a=r(17898),s=r(50458),i=r(94450);t.error={message:({params:{property:e,depsCount:t,deps:r}})=>(0,a.str)`must have ${1===t?"property":"properties"} ${r} when property ${e} is present`,params:({params:{property:e,depsCount:t,deps:r,missingProperty:s}})=>(0,a._)`{property: ${e},
4
+ || ${n} === "boolean" || ${s} === null`).assign(o,(0,l._)`[${s}]`)}}(e);a.else(),m(e),a.endIf(),a.if((0,l._)`${o} !== undefined`,()=>{a.assign(s,o),function({gen:e,parentData:t,parentDataProperty:r},a){e.if((0,l._)`${t} !== undefined`,()=>e.assign((0,l._)`${t}[${r}]`,a))}(e,o)})}(e,t,u):m(e)})}return h};let c=new Set(["string","number","integer","boolean","null"]);function h(e,t,r,s=a.Correct){let i,n=s===a.Correct?l.operators.EQ:l.operators.NEQ;switch(e){case"null":return(0,l._)`${t} ${n} null`;case"array":i=(0,l._)`Array.isArray(${t})`;break;case"object":i=(0,l._)`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;break;case"integer":i=o((0,l._)`!(${t} % 1) && !isNaN(${t})`);break;case"number":i=o();break;default:return(0,l._)`typeof ${t} ${n} ${e}`}return s===a.Correct?i:(0,l.not)(i);function o(e=l.nil){return(0,l.and)((0,l._)`typeof ${t} == "number"`,e,r?(0,l._)`isFinite(${t})`:l.nil)}}function f(e,t,r,a){let s;if(1===e.length)return h(e[0],t,r,a);let i=(0,d.toHash)(e);if(i.array&&i.object){let e=(0,l._)`typeof ${t} != "object"`;s=i.null?e:(0,l._)`!${t} || ${e}`,delete i.null,delete i.array,delete i.object}else s=l.nil;for(let e in i.number&&delete i.integer,i)s=(0,l.and)(s,h(e,t,r,a));return s}t.checkDataType=h,t.checkDataTypes=f;let p={message:({schema:e})=>`must be ${e}`,params:({schema:e,schemaValue:t})=>"string"==typeof e?(0,l._)`{type: ${e}}`:(0,l._)`{type: ${t}}`};function m(e){let t=function(e){let{gen:t,data:r,schema:a}=e,s=(0,d.schemaRefOrVal)(e,a,"type");return{gen:t,keyword:"type",data:r,schema:a.type,schemaCode:s,schemaValue:s,parentSchema:a,params:{},it:e}}(e);(0,o.reportError)(t,p)}t.reportTypeError=m},96841(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.assignDefaults=void 0;let a=r(17898),s=r(50458);function i(e,t,r){let{gen:i,compositeRule:n,data:o,opts:l}=e;if(void 0===r)return;let d=(0,a._)`${o}${(0,a.getProperty)(t)}`;if(n)return void(0,s.checkStrictMode)(e,`default is ignored for: ${d}`);let u=(0,a._)`${d} === undefined`;"empty"===l.useDefaults&&(u=(0,a._)`${u} || ${d} === null || ${d} === ""`),i.if(u,(0,a._)`${d} = ${(0,a.stringify)(r)}`)}t.assignDefaults=function(e,t){let{properties:r,items:a}=e.schema;if("object"===t&&r)for(let t in r)i(e,t,r[t].default);else"array"===t&&Array.isArray(a)&&a.forEach((t,r)=>i(e,r,t.default))}},96223(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.getData=t.KeywordCxt=t.validateFunctionCode=void 0;let a=r(15948),s=r(69003),i=r(74758),n=r(69003),o=r(96841),l=r(49348),d=r(53322),u=r(17898),c=r(63036),h=r(14856),f=r(50458),p=r(49409);function m({gen:e,validateName:t,schema:r,schemaEnv:a,opts:s},i){var n;s.code.es5?e.func(t,(0,u._)`${c.default.data}, ${c.default.valCxt}`,a.$async,()=>{var t,a;e.code((0,u._)`"use strict"; ${y(r,s)}`),t=e,a=s,t.if(c.default.valCxt,()=>{t.var(c.default.instancePath,(0,u._)`${c.default.valCxt}.${c.default.instancePath}`),t.var(c.default.parentData,(0,u._)`${c.default.valCxt}.${c.default.parentData}`),t.var(c.default.parentDataProperty,(0,u._)`${c.default.valCxt}.${c.default.parentDataProperty}`),t.var(c.default.rootData,(0,u._)`${c.default.valCxt}.${c.default.rootData}`),a.dynamicRef&&t.var(c.default.dynamicAnchors,(0,u._)`${c.default.valCxt}.${c.default.dynamicAnchors}`)},()=>{t.var(c.default.instancePath,(0,u._)`""`),t.var(c.default.parentData,(0,u._)`undefined`),t.var(c.default.parentDataProperty,(0,u._)`undefined`),t.var(c.default.rootData,c.default.data),a.dynamicRef&&t.var(c.default.dynamicAnchors,(0,u._)`{}`)}),e.code(i)}):e.func(t,(0,u._)`${c.default.data}, ${(n=s,(0,u._)`{${c.default.instancePath}="", ${c.default.parentData}, ${c.default.parentDataProperty}, ${c.default.rootData}=${c.default.data}${n.dynamicRef?(0,u._)`, ${c.default.dynamicAnchors}={}`:u.nil}}={}`)}`,a.$async,()=>e.code(y(r,s)).code(i))}function y(e,t){let r="object"==typeof e&&e[t.schemaId];return r&&(t.code.source||t.code.process)?(0,u._)`/*# sourceURL=${r} */`:u.nil}function g({schema:e,self:t}){if("boolean"==typeof e)return!e;for(let r in e)if(t.RULES.all[r])return!0;return!1}function v(e){return"boolean"!=typeof e.schema}function _(e){(0,f.checkUnknownRules)(e),function(e){let{schema:t,errSchemaPath:r,opts:a,self:s}=e;t.$ref&&a.ignoreKeywordsWithRef&&(0,f.schemaHasRulesButRef)(t,s.RULES)&&s.logger.warn(`$ref: keywords ignored in schema at path "${r}"`)}(e)}function $(e,t){if(e.opts.jtd)return w(e,[],!1,t);let r=(0,s.getSchemaTypes)(e.schema),a=(0,s.coerceAndCheckDataType)(e,r);w(e,r,!a,t)}function b({gen:e,schemaEnv:t,schema:r,errSchemaPath:a,opts:s}){let i=r.$comment;if(!0===s.$comment)e.code((0,u._)`${c.default.self}.logger.log(${i})`);else if("function"==typeof s.$comment){let r=(0,u.str)`${a}/$comment`,s=e.scopeValue("root",{ref:t.root});e.code((0,u._)`${c.default.self}.opts.$comment(${i}, ${r}, ${s}.schema)`)}}function w(e,t,r,a){var s,o,l,d;let{gen:h,schema:p,data:m,allErrors:y,opts:g,self:v}=e,{RULES:_}=v;if(p.$ref&&(g.ignoreKeywordsWithRef||!(0,f.schemaHasRulesButRef)(p,_)))return void h.block(()=>E(e,"$ref",_.all.$ref.definition));function $(s){(0,i.shouldUseGroup)(p,s)&&(s.type?(h.if((0,n.checkDataType)(s.type,m,g.strictNumbers)),k(e,s),1===t.length&&t[0]===s.type&&r&&(h.else(),(0,n.reportTypeError)(e)),h.endIf()):k(e,s),y||h.if((0,u._)`${c.default.errors} === ${a||0}`))}g.jtd||(s=e,o=t,!s.schemaEnv.meta&&s.opts.strictTypes&&(function(e,t){if(t.length){if(!e.dataTypes.length){e.dataTypes=t;return}t.forEach(t=>{x(e.dataTypes,t)||P(e,`type "${t}" not allowed by context "${e.dataTypes.join(",")}"`)}),function(e,t){let r=[];for(let a of e.dataTypes)x(t,a)?r.push(a):t.includes("integer")&&"number"===a&&r.push("integer");e.dataTypes=r}(e,t)}}(s,o),s.opts.allowUnionTypes||(l=s,(d=o).length>1&&!(2===d.length&&d.includes("null"))&&P(l,"use allowUnionTypes to allow union type keyword")),function(e,t){let r=e.self.RULES.all;for(let a in r){let s=r[a];if("object"==typeof s&&(0,i.shouldUseRule)(e.schema,s)){let{type:r}=s.definition;r.length&&!r.some(e=>{var r,a;return r=t,a=e,r.includes(a)||"number"===a&&r.includes("integer")})&&P(e,`missing type "${r.join(",")}" for keyword "${a}"`)}}}(s,s.dataTypes))),h.block(()=>{for(let e of _.rules)$(e);$(_.post)})}function k(e,t){let{gen:r,schema:a,opts:{useDefaults:s}}=e;s&&(0,o.assignDefaults)(e,t.type),r.block(()=>{for(let r of t.rules)(0,i.shouldUseRule)(a,r)&&E(e,r.keyword,r.definition,t.type)})}function x(e,t){return e.includes(t)||"integer"===t&&e.includes("number")}function P(e,t){let r=e.schemaEnv.baseId+e.errSchemaPath;t+=` at "${r}" (strictTypes)`,(0,f.checkStrictMode)(e,t,e.opts.strictTypes)}t.validateFunctionCode=function(e){v(e)&&(_(e),g(e))?function(e){let{schema:t,opts:r,gen:a}=e;m(e,()=>{r.$comment&&t.$comment&&b(e),function(e){let{schema:t,opts:r}=e;void 0!==t.default&&r.useDefaults&&r.strictSchema&&(0,f.checkStrictMode)(e,"default is ignored in the schema root")}(e),a.let(c.default.vErrors,null),a.let(c.default.errors,0),r.unevaluated&&function(e){let{gen:t,validateName:r}=e;e.evaluated=t.const("evaluated",(0,u._)`${r}.evaluated`),t.if((0,u._)`${e.evaluated}.dynamicProps`,()=>t.assign((0,u._)`${e.evaluated}.props`,(0,u._)`undefined`)),t.if((0,u._)`${e.evaluated}.dynamicItems`,()=>t.assign((0,u._)`${e.evaluated}.items`,(0,u._)`undefined`))}(e),$(e),function(e){let{gen:t,schemaEnv:r,validateName:a,ValidationError:s,opts:i}=e;r.$async?t.if((0,u._)`${c.default.errors} === 0`,()=>t.return(c.default.data),()=>t.throw((0,u._)`new ${s}(${c.default.vErrors})`)):(t.assign((0,u._)`${a}.errors`,c.default.vErrors),i.unevaluated&&function({gen:e,evaluated:t,props:r,items:a}){r instanceof u.Name&&e.assign((0,u._)`${t}.props`,r),a instanceof u.Name&&e.assign((0,u._)`${t}.items`,a)}(e),t.return((0,u._)`${c.default.errors} === 0`))}(e)})}(e):m(e,()=>(0,a.topBoolOrEmptySchema)(e))};class S{constructor(e,t,r){if((0,l.validateKeywordUsage)(e,t,r),this.gen=e.gen,this.allErrors=e.allErrors,this.keyword=r,this.data=e.data,this.schema=e.schema[r],this.$data=t.$data&&e.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,f.schemaRefOrVal)(e,this.schema,r,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",O(this.$data,e));else if(this.schemaCode=this.schemaValue,!(0,l.validSchemaType)(this.schema,t.schemaType,t.allowUndefined))throw Error(`${r} value must be ${JSON.stringify(t.schemaType)}`);("code"in t?t.trackErrors:!1!==t.errors)&&(this.errsCount=e.gen.const("_errs",c.default.errors))}result(e,t,r){this.failResult((0,u.not)(e),t,r)}failResult(e,t,r){this.gen.if(e),r?r():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,u.not)(e),void 0,t)}fail(e){if(void 0===e){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,u._)`${t} !== undefined && (${(0,u.or)(this.invalid$data(),e)})`)}error(e,t,r){if(t){this.setParams(t),this._error(e,r),this.setParams({});return}this._error(e,r)}_error(e,t){(e?p.reportExtraError:p.reportError)(this,this.def.error,t)}$dataError(){(0,p.reportError)(this,this.def.$dataError||p.keyword$DataError)}reset(){if(void 0===this.errsCount)throw Error('add "trackErrors" to keyword definition');(0,p.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,r=u.nil){this.gen.block(()=>{this.check$data(e,r),t()})}check$data(e=u.nil,t=u.nil){if(!this.$data)return;let{gen:r,schemaCode:a,schemaType:s,def:i}=this;r.if((0,u.or)((0,u._)`${a} === undefined`,t)),e!==u.nil&&r.assign(e,!0),(s.length||i.validateSchema)&&(r.elseIf(this.invalid$data()),this.$dataError(),e!==u.nil&&r.assign(e,!1)),r.else()}invalid$data(){let{gen:e,schemaCode:t,schemaType:r,def:a,it:s}=this;return(0,u.or)(function(){if(r.length){if(!(t instanceof u.Name))throw Error("ajv implementation error");let e=Array.isArray(r)?r:[r];return(0,u._)`${(0,n.checkDataTypes)(e,t,s.opts.strictNumbers,n.DataType.Wrong)}`}return u.nil}(),function(){if(a.validateSchema){let r=e.scopeValue("validate$data",{ref:a.validateSchema});return(0,u._)`!${r}(${t})`}return u.nil}())}subschema(e,t){let r=(0,d.getSubschema)(this.it,e);(0,d.extendSubschemaData)(r,this.it,e),(0,d.extendSubschemaMode)(r,e);let s={...this.it,...r,items:void 0,props:void 0};return!function(e,t){if(v(e)&&(_(e),g(e)))return function(e,t){var r;let a,{schema:s,gen:i,opts:n}=e;n.$comment&&s.$comment&&b(e),(a=(r=e).schema[r.opts.schemaId])&&(r.baseId=(0,h.resolveUrl)(r.opts.uriResolver,r.baseId,a)),function(e){if(e.schema.$async&&!e.schemaEnv.$async)throw Error("async schema in sync schema")}(e);let o=i.const("_errs",c.default.errors);$(e,o),i.var(t,(0,u._)`${o} === ${c.default.errors}`)}(e,t);(0,a.boolOrEmptySchema)(e,t)}(s,t),s}mergeEvaluated(e,t){let{it:r,gen:a}=this;r.opts.unevaluated&&(!0!==r.props&&void 0!==e.props&&(r.props=f.mergeEvaluated.props(a,e.props,r.props,t)),!0!==r.items&&void 0!==e.items&&(r.items=f.mergeEvaluated.items(a,e.items,r.items,t)))}mergeValidEvaluated(e,t){let{it:r,gen:a}=this;if(r.opts.unevaluated&&(!0!==r.props||!0!==r.items))return a.if(t,()=>this.mergeEvaluated(e,u.Name)),!0}}function E(e,t,r,a){let s=new S(e,r,t);"code"in r?r.code(s,a):s.$data&&r.validate?(0,l.funcKeywordCode)(s,r):"macro"in r?(0,l.macroKeywordCode)(s,r):(r.compile||r.validate)&&(0,l.funcKeywordCode)(s,r)}t.KeywordCxt=S;let j=/^\/(?:[^~]|~0|~1)*$/,N=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function O(e,{dataLevel:t,dataNames:r,dataPathArr:a}){let s,i;if(""===e)return c.default.rootData;if("/"===e[0]){if(!j.test(e))throw Error(`Invalid JSON-pointer: ${e}`);s=e,i=c.default.rootData}else{let n=N.exec(e);if(!n)throw Error(`Invalid JSON-pointer: ${e}`);let l=+n[1];if("#"===(s=n[2])){if(l>=t)throw Error(o("property/index",l));return a[t-l]}if(l>t)throw Error(o("data",l));if(i=r[t-l],!s)return i}let n=i;for(let e of s.split("/"))e&&(i=(0,u._)`${i}${(0,u.getProperty)((0,f.unescapeJsonPointer)(e))}`,n=(0,u._)`${n} && ${i}`);return n;function o(e,r){return`Cannot access ${e} ${r} levels up, current level is ${t}`}}t.getData=O},49348(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateKeywordUsage=t.validSchemaType=t.funcKeywordCode=t.macroKeywordCode=void 0;let a=r(17898),s=r(63036),i=r(94450),n=r(49409);function o(e){let{gen:t,data:r,it:s}=e;t.if(s.parentData,()=>t.assign(r,(0,a._)`${s.parentData}[${s.parentDataProperty}]`))}function l(e,t,r){if(void 0===r)throw Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword","function"==typeof r?{ref:r}:{ref:r,code:(0,a.stringify)(r)})}t.macroKeywordCode=function(e,t){let{gen:r,keyword:s,schema:i,parentSchema:n,it:o}=e,d=t.macro.call(o.self,i,n,o),u=l(r,s,d);!1!==o.opts.validateSchema&&o.self.validateSchema(d,!0);let c=r.name("valid");e.subschema({schema:d,schemaPath:a.nil,errSchemaPath:`${o.errSchemaPath}/${s}`,topSchemaRef:u,compositeRule:!0},c),e.pass(c,()=>e.error(!0))},t.funcKeywordCode=function(e,t){var r;let{gen:d,keyword:u,schema:c,parentSchema:h,$data:f,it:p}=e;!function({schemaEnv:e},t){if(t.async&&!e.$async)throw Error("async keyword in sync schema")}(p,t);let m=l(d,u,!f&&t.compile?t.compile.call(p.self,c,h,p):t.validate),y=d.let("valid");function g(r=t.async?(0,a._)`await `:a.nil){let n=p.opts.passContext?s.default.this:s.default.self,o=!("compile"in t&&!f||!1===t.schema);d.assign(y,(0,a._)`${r}${(0,i.callValidateCode)(e,m,n,o)}`,t.modifying)}function v(e){var r;d.if((0,a.not)(null!=(r=t.valid)?r:y),e)}e.block$data(y,function(){if(!1===t.errors)g(),t.modifying&&o(e),v(()=>e.error());else{let r,i,l=t.async?(r=d.let("ruleErrs",null),d.try(()=>g((0,a._)`await `),e=>d.assign(y,!1).if((0,a._)`${e} instanceof ${p.ValidationError}`,()=>d.assign(r,(0,a._)`${e}.errors`),()=>d.throw(e))),r):(i=(0,a._)`${m}.errors`,d.assign(i,null),g(a.nil),i);t.modifying&&o(e),v(()=>(function(e,t){let{gen:r}=e;r.if((0,a._)`Array.isArray(${t})`,()=>{r.assign(s.default.vErrors,(0,a._)`${s.default.vErrors} === null ? ${t} : ${s.default.vErrors}.concat(${t})`).assign(s.default.errors,(0,a._)`${s.default.vErrors}.length`),(0,n.extendErrors)(e)},()=>e.error())})(e,l))}}),e.ok(null!=(r=t.valid)?r:y)},t.validSchemaType=function(e,t,r=!1){return!t.length||t.some(t=>"array"===t?Array.isArray(e):"object"===t?e&&"object"==typeof e&&!Array.isArray(e):typeof e==t||r&&void 0===e)},t.validateKeywordUsage=function({schema:e,opts:t,self:r,errSchemaPath:a},s,i){if(Array.isArray(s.keyword)?!s.keyword.includes(i):s.keyword!==i)throw Error("ajv implementation error");let n=s.dependencies;if(null==n?void 0:n.some(t=>!Object.prototype.hasOwnProperty.call(e,t)))throw Error(`parent schema must have dependencies of ${i}: ${n.join(",")}`);if(s.validateSchema&&!s.validateSchema(e[i])){let e=`keyword "${i}" value is invalid at path "${a}": `+r.errorsText(s.validateSchema.errors);if("log"===t.validateSchema)r.logger.error(e);else throw Error(e)}}},53322(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.extendSubschemaMode=t.extendSubschemaData=t.getSubschema=void 0;let a=r(17898),s=r(50458);t.getSubschema=function(e,{keyword:t,schemaProp:r,schema:i,schemaPath:n,errSchemaPath:o,topSchemaRef:l}){if(void 0!==t&&void 0!==i)throw Error('both "keyword" and "schema" passed, only one allowed');if(void 0!==t){let i=e.schema[t];return void 0===r?{schema:i,schemaPath:(0,a._)`${e.schemaPath}${(0,a.getProperty)(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:i[r],schemaPath:(0,a._)`${e.schemaPath}${(0,a.getProperty)(t)}${(0,a.getProperty)(r)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${(0,s.escapeFragment)(r)}`}}if(void 0!==i){if(void 0===n||void 0===o||void 0===l)throw Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:i,schemaPath:n,topSchemaRef:l,errSchemaPath:o}}throw Error('either "keyword" or "schema" must be passed')},t.extendSubschemaData=function(e,t,{dataProp:r,dataPropType:i,data:n,dataTypes:o,propertyName:l}){if(void 0!==n&&void 0!==r)throw Error('both "data" and "dataProp" passed, only one allowed');let{gen:d}=t;if(void 0!==r){let{errorPath:n,dataPathArr:o,opts:l}=t;u(d.let("data",(0,a._)`${t.data}${(0,a.getProperty)(r)}`,!0)),e.errorPath=(0,a.str)`${n}${(0,s.getErrorPath)(r,i,l.jsPropertySyntax)}`,e.parentDataProperty=(0,a._)`${r}`,e.dataPathArr=[...o,e.parentDataProperty]}function u(r){e.data=r,e.dataLevel=t.dataLevel+1,e.dataTypes=[],t.definedProperties=new Set,e.parentData=t.data,e.dataNames=[...t.dataNames,r]}void 0!==n&&(u(n instanceof a.Name?n:d.let("data",n,!0)),void 0!==l&&(e.propertyName=l)),o&&(e.dataTypes=o)},t.extendSubschemaMode=function(e,{jtdDiscriminator:t,jtdMetadata:r,compositeRule:a,createErrors:s,allErrors:i}){void 0!==a&&(e.compositeRule=a),void 0!==s&&(e.createErrors=s),void 0!==i&&(e.allErrors=i),e.jtdDiscriminator=t,e.jtdMetadata=r}},65319(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=void 0;var a=r(96223);Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return a.KeywordCxt}});var s=r(17898);Object.defineProperty(t,"_",{enumerable:!0,get:function(){return s._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return s.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return s.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return s.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return s.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return s.CodeGen}});let i=r(95031),n=r(85748),o=r(90383),l=r(49392),d=r(17898),u=r(14856),c=r(69003),h=r(50458),f=r(93770),p=r(7903),m=(e,t)=>new RegExp(e,t);m.code="new RegExp";let y=["removeAdditional","useDefaults","coerceTypes"],g=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),v={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."},_={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'};class ${constructor(e={}){this.schemas={},this.refs={},this.formats=Object.create(null),this._compilations=new Set,this._loading={},this._cache=new Map,e=this.opts={...e,...function(e){var t,r,a,s,i,n,o,l,d,u,c,h,f,y,g,v,_,$,b,w,k,x,P,S,E;let j=e.strict,N=null==(t=e.code)?void 0:t.optimize,O=!0===N||void 0===N?1:N||0,T=null!=(a=null==(r=e.code)?void 0:r.regExp)?a:m,C=null!=(s=e.uriResolver)?s:p.default;return{strictSchema:null==(n=null!=(i=e.strictSchema)?i:j)||n,strictNumbers:null==(l=null!=(o=e.strictNumbers)?o:j)||l,strictTypes:null!=(u=null!=(d=e.strictTypes)?d:j)?u:"log",strictTuples:null!=(h=null!=(c=e.strictTuples)?c:j)?h:"log",strictRequired:null!=(y=null!=(f=e.strictRequired)?f:j)&&y,code:e.code?{...e.code,optimize:O,regExp:T}:{optimize:O,regExp:T},loopRequired:null!=(g=e.loopRequired)?g:200,loopEnum:null!=(v=e.loopEnum)?v:200,meta:null==(_=e.meta)||_,messages:null==($=e.messages)||$,inlineRefs:null==(b=e.inlineRefs)||b,schemaId:null!=(w=e.schemaId)?w:"$id",addUsedSchema:null==(k=e.addUsedSchema)||k,validateSchema:null==(x=e.validateSchema)||x,validateFormats:null==(P=e.validateFormats)||P,unicodeRegExp:null==(S=e.unicodeRegExp)||S,int32range:null==(E=e.int32range)||E,uriResolver:C}}(e)};const{es5:t,lines:r}=this.opts.code;this.scope=new d.ValueScope({scope:{},prefixes:g,es5:t,lines:r}),this.logger=function(e){if(!1===e)return E;if(void 0===e)return console;if(e.log&&e.warn&&e.error)return e;throw Error("logger must implement log, warn and error methods")}(e.logger);const a=e.validateFormats;e.validateFormats=!1,this.RULES=(0,o.getRules)(),b.call(this,v,e,"NOT SUPPORTED"),b.call(this,_,e,"DEPRECATED","warn"),this._metaOpts=S.call(this),e.formats&&x.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),e.keywords&&P.call(this,e.keywords),"object"==typeof e.meta&&this.addMetaSchema(e.meta),k.call(this),e.validateFormats=a}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){let{$data:e,meta:t,schemaId:r}=this.opts,a=f;"id"===r&&((a={...f}).id=a.$id,delete a.$id),t&&e&&this.addMetaSchema(a,a[r],!1)}defaultMeta(){let{meta:e,schemaId:t}=this.opts;return this.opts.defaultMeta="object"==typeof e?e[t]||e:void 0}validate(e,t){let r;if("string"==typeof e){if(!(r=this.getSchema(e)))throw Error(`no schema with key or ref "${e}"`)}else r=this.compile(e);let a=r(t);return"$async"in r||(this.errors=r.errors),a}compile(e,t){let r=this._addSchema(e,t);return r.validate||this._compileSchemaEnv(r)}compileAsync(e,t){if("function"!=typeof this.opts.loadSchema)throw Error("options.loadSchema should be a function");let{loadSchema:r}=this.opts;return a.call(this,e,t);async function a(e,t){await s.call(this,e.$schema);let r=this._addSchema(e,t);return r.validate||i.call(this,r)}async function s(e){e&&!this.getSchema(e)&&await a.call(this,{$ref:e},!0)}async function i(e){try{return this._compileSchemaEnv(e)}catch(t){if(!(t instanceof n.default))throw t;return o.call(this,t),await l.call(this,t.missingSchema),i.call(this,e)}}function o({missingSchema:e,missingRef:t}){if(this.refs[e])throw Error(`AnySchema ${e} is loaded but ${t} cannot be resolved`)}async function l(e){let r=await d.call(this,e);this.refs[e]||await s.call(this,r.$schema),this.refs[e]||this.addSchema(r,e,t)}async function d(e){let t=this._loading[e];if(t)return t;try{return await (this._loading[e]=r(e))}finally{delete this._loading[e]}}}addSchema(e,t,r,a=this.opts.validateSchema){let s;if(Array.isArray(e)){for(let t of e)this.addSchema(t,void 0,r,a);return this}if("object"==typeof e){let{schemaId:t}=this.opts;if(void 0!==(s=e[t])&&"string"!=typeof s)throw Error(`schema ${t} must be string`)}return t=(0,u.normalizeId)(t||s),this._checkUnique(t),this.schemas[t]=this._addSchema(e,r,t,a,!0),this}addMetaSchema(e,t,r=this.opts.validateSchema){return this.addSchema(e,t,!0,r),this}validateSchema(e,t){let r;if("boolean"==typeof e)return!0;if(void 0!==(r=e.$schema)&&"string"!=typeof r)throw Error("$schema must be a string");if(!(r=r||this.opts.defaultMeta||this.defaultMeta()))return this.logger.warn("meta-schema not available"),this.errors=null,!0;let a=this.validate(r,e);if(!a&&t){let e="schema is invalid: "+this.errorsText();if("log"===this.opts.validateSchema)this.logger.error(e);else throw Error(e)}return a}getSchema(e){let t;for(;"string"==typeof(t=w.call(this,e));)e=t;if(void 0===t){let{schemaId:r}=this.opts,a=new l.SchemaEnv({schema:{},schemaId:r});if(!(t=l.resolveSchema.call(this,a,e)))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=w.call(this,e);return"object"==typeof t&&this._cache.delete(t.schema),delete this.schemas[e],delete this.refs[e],this}case"object":{this._cache.delete(e);let t=e[this.opts.schemaId];return t&&(t=(0,u.normalizeId)(t),delete this.schemas[t],delete this.refs[t]),this}default:throw Error("ajv.removeSchema: invalid parameter")}}addVocabulary(e){for(let t of e)this.addKeyword(t);return this}addKeyword(e,t){let r;if("string"==typeof e)r=e,"object"==typeof t&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),t.keyword=r);else if("object"==typeof e&&void 0===t){if(Array.isArray(r=(t=e).keyword)&&!r.length)throw Error("addKeywords: keyword must be string or non-empty array")}else throw Error("invalid addKeywords parameters");if(N.call(this,r,t),!t)return(0,h.eachItem)(r,e=>O.call(this,e)),this;C.call(this,t);let a={...t,type:(0,c.getJSONTypes)(t.type),schemaType:(0,c.getJSONTypes)(t.schemaType)};return(0,h.eachItem)(r,0===a.type.length?e=>O.call(this,e,a):e=>a.type.forEach(t=>O.call(this,e,a,t))),this}getKeyword(e){let t=this.RULES.all[e];return"object"==typeof t?t.definition:!!t}removeKeyword(e){let{RULES:t}=this;for(let r of(delete t.keywords[e],delete t.all[e],t.rules)){let t=r.rules.findIndex(t=>t.keyword===e);t>=0&&r.rules.splice(t,1)}return this}addFormat(e,t){return"string"==typeof t&&(t=new RegExp(t)),this.formats[e]=t,this}errorsText(e=this.errors,{separator:t=", ",dataVar:r="data"}={}){return e&&0!==e.length?e.map(e=>`${r}${e.instancePath} ${e.message}`).reduce((e,r)=>e+t+r):"No errors"}$dataMetaSchema(e,t){let r=this.RULES.all;for(let a of(e=JSON.parse(JSON.stringify(e)),t)){let t=a.split("/").slice(1),s=e;for(let e of t)s=s[e];for(let e in r){let t=r[e];if("object"!=typeof t)continue;let{$data:a}=t.definition,i=s[e];a&&i&&(s[e]=R(i))}}return e}_removeAllSchemas(e,t){for(let r in e){let a=e[r];(!t||t.test(r))&&("string"==typeof a?delete e[r]:a&&!a.meta&&(this._cache.delete(a.schema),delete e[r]))}}_addSchema(e,t,r,a=this.opts.validateSchema,s=this.opts.addUsedSchema){let i,{schemaId:n}=this.opts;if("object"==typeof e)i=e[n];else if(this.opts.jtd)throw Error("schema must be object");else if("boolean"!=typeof e)throw Error("schema must be object or boolean");let o=this._cache.get(e);if(void 0!==o)return o;r=(0,u.normalizeId)(i||r);let d=u.getSchemaRefs.call(this,e,r);return o=new l.SchemaEnv({schema:e,schemaId:n,meta:t,baseId:r,localRefs:d}),this._cache.set(o.schema,o),s&&!r.startsWith("#")&&(r&&this._checkUnique(r),this.refs[r]=o),a&&this.validateSchema(e,!0),o}_checkUnique(e){if(this.schemas[e]||this.refs[e])throw Error(`schema with key or id "${e}" already exists`)}_compileSchemaEnv(e){if(e.meta?this._compileMetaSchema(e):l.compileSchema.call(this,e),!e.validate)throw Error("ajv implementation error");return e.validate}_compileMetaSchema(e){let t=this.opts;this.opts=this._metaOpts;try{l.compileSchema.call(this,e)}finally{this.opts=t}}}function b(e,t,r,a="error"){for(let s in e)s in t&&this.logger[a](`${r}: option ${s}. ${e[s]}`)}function w(e){return e=(0,u.normalizeId)(e),this.schemas[e]||this.refs[e]}function k(){let e=this.opts.schemas;if(e)if(Array.isArray(e))this.addSchema(e);else for(let t in e)this.addSchema(e[t],t)}function x(){for(let e in this.opts.formats){let t=this.opts.formats[e];t&&this.addFormat(e,t)}}function P(e){if(Array.isArray(e))return void this.addVocabulary(e);for(let t in this.logger.warn("keywords option as map is deprecated, pass array"),e){let r=e[t];r.keyword||(r.keyword=t),this.addKeyword(r)}}function S(){let e={...this.opts};for(let t of y)delete e[t];return e}$.ValidationError=i.default,$.MissingRefError=n.default,t.default=$;let E={log(){},warn(){},error(){}},j=/^[a-z_$][a-z0-9_$:-]*$/i;function N(e,t){let{RULES:r}=this;if((0,h.eachItem)(e,e=>{if(r.keywords[e])throw Error(`Keyword ${e} is already defined`);if(!j.test(e))throw Error(`Keyword ${e} has invalid name`)}),t&&t.$data&&!("code"in t||"validate"in t))throw Error('$data keyword must have "code" or "validate" function')}function O(e,t,r){var a;let s=null==t?void 0:t.post;if(r&&s)throw Error('keyword with "post" flag cannot have "type"');let{RULES:i}=this,n=s?i.post:i.rules.find(({type:e})=>e===r);if(n||(n={type:r,rules:[]},i.rules.push(n)),i.keywords[e]=!0,!t)return;let o={keyword:e,definition:{...t,type:(0,c.getJSONTypes)(t.type),schemaType:(0,c.getJSONTypes)(t.schemaType)}};t.before?T.call(this,n,o,t.before):n.rules.push(o),i.all[e]=o,null==(a=t.implements)||a.forEach(e=>this.addKeyword(e))}function T(e,t,r){let a=e.rules.findIndex(e=>e.keyword===r);a>=0?e.rules.splice(a,0,t):(e.rules.push(t),this.logger.warn(`rule ${r} is not defined`))}function C(e){let{metaSchema:t}=e;void 0!==t&&(e.$data&&this.opts.$data&&(t=R(t)),e.validateSchema=this.compile(t,!0))}let I={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function R(e){return{anyOf:[e,I]}}},72725(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(38792);a.code='require("ajv/dist/runtime/equal").default',t.default=a},26308(e,t){function r(e){let t,r=e.length,a=0,s=0;for(;s<r;)a++,(t=e.charCodeAt(s++))>=55296&&t<=56319&&s<r&&(64512&(t=e.charCodeAt(s)))==56320&&s++;return a}Object.defineProperty(t,"__esModule",{value:!0}),t.default=r,r.code='require("ajv/dist/runtime/ucs2length").default'},7903(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(84800);a.code='require("ajv/dist/runtime/uri").default',t.default=a},95031(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=class extends Error{constructor(e){super("validation failed"),this.errors=e,this.ajv=this.validation=!0}}},93426(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateAdditionalItems=void 0;let a=r(17898),s=r(50458);function i(e,t){let{gen:r,schema:i,data:n,keyword:o,it:l}=e;l.items=!0;let d=r.const("len",(0,a._)`${n}.length`);if(!1===i)e.setParams({len:t.length}),e.pass((0,a._)`${d} <= ${t.length}`);else if("object"==typeof i&&!(0,s.alwaysValidSchema)(l,i)){let i=r.var("valid",(0,a._)`${d} <= ${t.length}`);r.if((0,a.not)(i),()=>{var n;return n=i,void r.forRange("i",t.length,d,t=>{e.subschema({keyword:o,dataProp:t,dataPropType:s.Type.Num},n),l.allErrors||r.if((0,a.not)(n),()=>r.break())})}),e.ok(i)}}t.validateAdditionalItems=i,t.default={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:{message:({params:{len:e}})=>(0,a.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,a._)`{limit: ${e}}`},code(e){let{parentSchema:t,it:r}=e,{items:a}=t;Array.isArray(a)?i(e,a):(0,s.checkStrictMode)(r,'"additionalItems" is ignored when "items" is not an array of schemas')}}},92697(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(94450),s=r(17898),i=r(63036),n=r(50458);t.default={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:{message:"must NOT have additional properties",params:({params:e})=>(0,s._)`{additionalProperty: ${e.additionalProperty}}`},code(e){let{gen:t,schema:r,parentSchema:o,data:l,errsCount:d,it:u}=e;if(!d)throw Error("ajv implementation error");let{allErrors:c,opts:h}=u;if(u.props=!0,"all"!==h.removeAdditional&&(0,n.alwaysValidSchema)(u,r))return;let f=(0,a.allSchemaProperties)(o.properties),p=(0,a.allSchemaProperties)(o.patternProperties);function m(e){t.code((0,s._)`delete ${l}[${e}]`)}function y(a){if("all"===h.removeAdditional||h.removeAdditional&&!1===r)return void m(a);if(!1===r){e.setParams({additionalProperty:a}),e.error(),c||t.break();return}if("object"==typeof r&&!(0,n.alwaysValidSchema)(u,r)){let r=t.name("valid");"failing"===h.removeAdditional?(g(a,r,!1),t.if((0,s.not)(r),()=>{e.reset(),m(a)})):(g(a,r),c||t.if((0,s.not)(r),()=>t.break()))}}function g(t,r,a){let s={keyword:"additionalProperties",dataProp:t,dataPropType:n.Type.Str};!1===a&&Object.assign(s,{compositeRule:!0,createErrors:!1,allErrors:!1}),e.subschema(s,r)}t.forIn("key",l,r=>{f.length||p.length?t.if(function(r){let i;if(f.length>8){let e=(0,n.schemaRefOrVal)(u,o.properties,"properties");i=(0,a.isOwnProperty)(t,e,r)}else i=f.length?(0,s.or)(...f.map(e=>(0,s._)`${r} === ${e}`)):s.nil;return p.length&&(i=(0,s.or)(i,...p.map(t=>(0,s._)`${(0,a.usePattern)(e,t)}.test(${r})`))),(0,s.not)(i)}(r),()=>y(r)):y(r)}),e.ok((0,s._)`${d} === ${i.default.errors}`)}}},79355(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(50458);t.default={keyword:"allOf",schemaType:"array",code(e){let{gen:t,schema:r,it:s}=e;if(!Array.isArray(r))throw Error("ajv implementation error");let i=t.name("valid");r.forEach((t,r)=>{if((0,a.alwaysValidSchema)(s,t))return;let n=e.subschema({keyword:"allOf",schemaProp:r},i);e.ok(i),e.mergeEvaluated(n)})}}},19430(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.default={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:r(94450).validateUnion,error:{message:"must match a schema in anyOf"}}},35724(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=r(50458);t.default={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:{message:({params:{min:e,max:t}})=>void 0===t?(0,a.str)`must contain at least ${e} valid item(s)`:(0,a.str)`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>void 0===t?(0,a._)`{minContains: ${e}}`:(0,a._)`{minContains: ${e}, maxContains: ${t}}`},code(e){let t,r,{gen:i,schema:n,parentSchema:o,data:l,it:d}=e,{minContains:u,maxContains:c}=o;d.opts.next?(t=void 0===u?1:u,r=c):t=1;let h=i.const("len",(0,a._)`${l}.length`);if(e.setParams({min:t,max:r}),void 0===r&&0===t)return void(0,s.checkStrictMode)(d,'"minContains" == 0 without "maxContains": "contains" keyword ignored');if(void 0!==r&&t>r){(0,s.checkStrictMode)(d,'"minContains" > "maxContains" is always invalid'),e.fail();return}if((0,s.alwaysValidSchema)(d,n)){let s=(0,a._)`${h} >= ${t}`;void 0!==r&&(s=(0,a._)`${s} && ${h} <= ${r}`),e.pass(s);return}d.items=!0;let f=i.name("valid");function p(){let e=i.name("_valid"),s=i.let("count",0);m(e,()=>i.if(e,()=>{var e;return e=s,void(i.code((0,a._)`${e}++`),void 0===r?i.if((0,a._)`${e} >= ${t}`,()=>i.assign(f,!0).break()):(i.if((0,a._)`${e} > ${r}`,()=>i.assign(f,!1).break()),1===t?i.assign(f,!0):i.if((0,a._)`${e} >= ${t}`,()=>i.assign(f,!0))))}))}function m(t,r){i.forRange("i",0,h,a=>{e.subschema({keyword:"contains",dataProp:a,dataPropType:s.Type.Num,compositeRule:!0},t),r()})}void 0===r&&1===t?m(f,()=>i.if(f,()=>i.break())):0===t?(i.let(f,!0),void 0!==r&&i.if((0,a._)`${l}.length > 0`,p)):(i.let(f,!1),p()),e.result(f,()=>e.reset())}}},99868(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateSchemaDeps=t.validatePropertyDeps=t.error=void 0;let a=r(17898),s=r(50458),i=r(94450);t.error={message:({params:{property:e,depsCount:t,deps:r}})=>(0,a.str)`must have ${1===t?"property":"properties"} ${r} when property ${e} is present`,params:({params:{property:e,depsCount:t,deps:r,missingProperty:s}})=>(0,a._)`{property: ${e},
5
5
  missingProperty: ${s},
6
6
  depsCount: ${t},
7
- deps: ${r}}`};let n={keyword:"dependencies",type:"object",schemaType:"object",error:t.error,code(e){let[t,r]=function({schema:e}){let t={},r={};for(let a in e)"__proto__"!==a&&((Array.isArray(e[a])?t:r)[a]=e[a]);return[t,r]}(e);o(e,t),l(e,r)}};function o(e,t=e.schema){let{gen:r,data:s,it:n}=e;if(0===Object.keys(t).length)return;let l=r.let("missing");for(let o in t){let d=t[o];if(0===d.length)continue;let u=(0,i.propertyInData)(r,s,o,n.opts.ownProperties);e.setParams({property:o,depsCount:d.length,deps:d.join(", ")}),n.allErrors?r.if(u,()=>{for(let t of d)(0,i.checkReportMissingProp)(e,t)}):(r.if((0,a._)`${u} && (${(0,i.checkMissingProp)(e,d,l)})`),(0,i.reportMissingProp)(e,l),r.else())}}function l(e,t=e.schema){let{gen:r,data:a,keyword:n,it:o}=e,d=r.name("valid");for(let l in t)(0,s.alwaysValidSchema)(o,t[l])||(r.if((0,i.propertyInData)(r,a,l,o.opts.ownProperties),()=>{let t=e.subschema({keyword:n,schemaProp:l},d);e.mergeValidEvaluated(t,d)},()=>r.var(d,!0)),e.ok(d))}t.validatePropertyDeps=o,t.validateSchemaDeps=l,t.default=n},70510(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=r(50458);function i(e,t){let r=e.schema[t];return void 0!==r&&!(0,s.alwaysValidSchema)(e,r)}t.default={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:{message:({params:e})=>(0,a.str)`must match "${e.ifClause}" schema`,params:({params:e})=>(0,a._)`{failingKeyword: ${e.ifClause}}`},code(e){let t,{gen:r,parentSchema:n,it:o}=e;void 0===n.then&&void 0===n.else&&(0,s.checkStrictMode)(o,'"if" without "then" and "else" is ignored');let l=i(o,"then"),d=i(o,"else");if(!l&&!d)return;let u=r.let("valid",!0),c=r.name("_valid");if(t=e.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},c),e.mergeEvaluated(t),e.reset(),l&&d){let t=r.let("ifClause");e.setParams({ifClause:t}),r.if(c,h("then",t),h("else",t))}else l?r.if(c,h("then")):r.if((0,a.not)(c),h("else"));function h(t,s){return()=>{let i=e.subschema({keyword:t},c);r.assign(u,c),e.mergeValidEvaluated(i,u),s?r.assign(s,(0,a._)`${t}`):e.setParams({ifClause:t})}}e.pass(u,()=>e.error(!0))}}},18225(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(93426),s=r(61349),i=r(44153),n=r(19753),o=r(35724),l=r(99868),d=r(67486),u=r(92697),c=r(19660),h=r(98422),p=r(65532),f=r(19430),m=r(98768),y=r(79355),g=r(70510),v=r(45255);t.default=function(e=!1){let t=[p.default,f.default,m.default,y.default,g.default,v.default,d.default,u.default,l.default,c.default,h.default];return e?t.push(s.default,n.default):t.push(a.default,i.default),t.push(o.default),t}},44153(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateTuple=void 0;let a=r(17898),s=r(50458),i=r(94450);function n(e,t,r=e.schema){let{gen:i,parentSchema:o,data:l,keyword:d,it:u}=e;(function(e){let{opts:a,errSchemaPath:i}=u,n=r.length,o=n===e.minItems&&(n===e.maxItems||!1===e[t]);if(a.strictTuples&&!o){let e=`"${d}" is ${n}-tuple, but minItems or maxItems/${t} are not specified or different at path "${i}"`;(0,s.checkStrictMode)(u,e,a.strictTuples)}})(o),u.opts.unevaluated&&r.length&&!0!==u.items&&(u.items=s.mergeEvaluated.items(i,r.length,u.items));let c=i.name("valid"),h=i.const("len",(0,a._)`${l}.length`);r.forEach((t,r)=>{(0,s.alwaysValidSchema)(u,t)||(i.if((0,a._)`${h} > ${r}`,()=>e.subschema({keyword:d,schemaProp:r,dataProp:r},c)),e.ok(c))})}t.validateTuple=n,t.default={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){let{schema:t,it:r}=e;if(Array.isArray(t))return n(e,"additionalItems",t);r.items=!0,(0,s.alwaysValidSchema)(r,t)||e.ok((0,i.validateArray)(e))}}},19753(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=r(50458),i=r(94450),n=r(93426);t.default={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:{message:({params:{len:e}})=>(0,a.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,a._)`{limit: ${e}}`},code(e){let{schema:t,parentSchema:r,it:a}=e,{prefixItems:o}=r;a.items=!0,(0,s.alwaysValidSchema)(a,t)||(o?(0,n.validateAdditionalItems)(e,o):e.ok((0,i.validateArray)(e)))}}},65532(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(50458);t.default={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){let{gen:t,schema:r,it:s}=e;if((0,a.alwaysValidSchema)(s,r))return void e.fail();let i=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},i),e.failResult(i,()=>e.reset(),()=>e.error())},error:{message:"must NOT be valid"}}},98768(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=r(50458);t.default={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:{message:"must match exactly one schema in oneOf",params:({params:e})=>(0,a._)`{passingSchemas: ${e.passing}}`},code(e){let{gen:t,schema:r,parentSchema:i,it:n}=e;if(!Array.isArray(r))throw Error("ajv implementation error");if(n.opts.discriminator&&i.discriminator)return;let o=t.let("valid",!1),l=t.let("passing",null),d=t.name("_valid");e.setParams({passing:l}),t.block(function(){r.forEach((r,i)=>{let u;(0,s.alwaysValidSchema)(n,r)?t.var(d,!0):u=e.subschema({keyword:"oneOf",schemaProp:i,compositeRule:!0},d),i>0&&t.if((0,a._)`${d} && ${o}`).assign(o,!1).assign(l,(0,a._)`[${l}, ${i}]`).else(),t.if(d,()=>{t.assign(o,!0),t.assign(l,i),u&&e.mergeEvaluated(u,a.Name)})})}),e.result(o,()=>e.reset(),()=>e.error(!0))}}},98422(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(94450),s=r(17898),i=r(50458),n=r(50458);t.default={keyword:"patternProperties",type:"object",schemaType:"object",code(e){let{gen:t,schema:r,data:o,parentSchema:l,it:d}=e,{opts:u}=d,c=(0,a.allSchemaProperties)(r),h=c.filter(e=>(0,i.alwaysValidSchema)(d,r[e]));if(0===c.length||h.length===c.length&&(!d.opts.unevaluated||!0===d.props))return;let p=u.strictSchema&&!u.allowMatchingProperties&&l.properties,f=t.name("valid");!0===d.props||d.props instanceof s.Name||(d.props=(0,n.evaluatedPropsToName)(t,d.props));let{props:m}=d;for(let e of c)p&&function(e){for(let t in p)new RegExp(e).test(t)&&(0,i.checkStrictMode)(d,`property ${t} matches pattern ${e} (use allowMatchingProperties)`)}(e),d.allErrors?y(e):(t.var(f,!0),y(e),t.if(f));function y(r){t.forIn("key",o,i=>{t.if((0,s._)`${(0,a.usePattern)(e,r)}.test(${i})`,()=>{let a=h.includes(r);a||e.subschema({keyword:"patternProperties",schemaProp:r,dataProp:i,dataPropType:n.Type.Str},f),d.opts.unevaluated&&!0!==m?t.assign((0,s._)`${m}[${i}]`,!0):a||d.allErrors||t.if((0,s.not)(f),()=>t.break())})})}}}},61349(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(44153);t.default={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:e=>(0,a.validateTuple)(e,"items")}},19660(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(96223),s=r(94450),i=r(50458),n=r(92697);t.default={keyword:"properties",type:"object",schemaType:"object",code(e){let{gen:t,schema:r,parentSchema:o,data:l,it:d}=e;"all"===d.opts.removeAdditional&&void 0===o.additionalProperties&&n.default.code(new a.KeywordCxt(d,n.default,"additionalProperties"));let u=(0,s.allSchemaProperties)(r);for(let e of u)d.definedProperties.add(e);d.opts.unevaluated&&u.length&&!0!==d.props&&(d.props=i.mergeEvaluated.props(t,(0,i.toHash)(u),d.props));let c=u.filter(e=>!(0,i.alwaysValidSchema)(d,r[e]));if(0===c.length)return;let h=t.name("valid");for(let a of c){var p;(p=a,d.opts.useDefaults&&!d.compositeRule&&void 0!==r[p].default)?f(a):(t.if((0,s.propertyInData)(t,l,a,d.opts.ownProperties)),f(a),d.allErrors||t.else().var(h,!0),t.endIf()),e.it.definedProperties.add(a),e.ok(h)}function f(t){e.subschema({keyword:"properties",schemaProp:t,dataProp:t},h)}}}},67486(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=r(50458);t.default={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:{message:"property name must be valid",params:({params:e})=>(0,a._)`{propertyName: ${e.propertyName}}`},code(e){let{gen:t,schema:r,data:i,it:n}=e;if((0,s.alwaysValidSchema)(n,r))return;let o=t.name("valid");t.forIn("key",i,r=>{e.setParams({propertyName:r}),e.subschema({keyword:"propertyNames",data:r,dataTypes:["string"],propertyName:r,compositeRule:!0},o),t.if((0,a.not)(o),()=>{e.error(!0),n.allErrors||t.break()})}),e.ok(o)}}},45255(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(50458);t.default={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:r}){void 0===t.if&&(0,a.checkStrictMode)(r,`"${e}" without "if" is ignored`)}}},94450(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateUnion=t.validateArray=t.usePattern=t.callValidateCode=t.schemaProperties=t.allSchemaProperties=t.noPropertyInData=t.propertyInData=t.isOwnProperty=t.hasPropFunc=t.reportMissingProp=t.checkMissingProp=t.checkReportMissingProp=void 0;let a=r(17898),s=r(50458),i=r(63036),n=r(50458);function o(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,a._)`Object.prototype.hasOwnProperty`})}function l(e,t,r){return(0,a._)`${o(e)}.call(${t}, ${r})`}function d(e,t,r,s){let i=(0,a._)`${t}${(0,a.getProperty)(r)} === undefined`;return s?(0,a.or)(i,(0,a.not)(l(e,t,r))):i}function u(e){return e?Object.keys(e).filter(e=>"__proto__"!==e):[]}t.checkReportMissingProp=function(e,t){let{gen:r,data:s,it:i}=e;r.if(d(r,s,t,i.opts.ownProperties),()=>{e.setParams({missingProperty:(0,a._)`${t}`},!0),e.error()})},t.checkMissingProp=function({gen:e,data:t,it:{opts:r}},s,i){return(0,a.or)(...s.map(s=>(0,a.and)(d(e,t,s,r.ownProperties),(0,a._)`${i} = ${s}`)))},t.reportMissingProp=function(e,t){e.setParams({missingProperty:t},!0),e.error()},t.hasPropFunc=o,t.isOwnProperty=l,t.propertyInData=function(e,t,r,s){let i=(0,a._)`${t}${(0,a.getProperty)(r)} !== undefined`;return s?(0,a._)`${i} && ${l(e,t,r)}`:i},t.noPropertyInData=d,t.allSchemaProperties=u,t.schemaProperties=function(e,t){return u(t).filter(r=>!(0,s.alwaysValidSchema)(e,t[r]))},t.callValidateCode=function({schemaCode:e,data:t,it:{gen:r,topSchemaRef:s,schemaPath:n,errorPath:o},it:l},d,u,c){let h=c?(0,a._)`${e}, ${t}, ${s}${n}`:t,p=[[i.default.instancePath,(0,a.strConcat)(i.default.instancePath,o)],[i.default.parentData,l.parentData],[i.default.parentDataProperty,l.parentDataProperty],[i.default.rootData,i.default.rootData]];l.opts.dynamicRef&&p.push([i.default.dynamicAnchors,i.default.dynamicAnchors]);let f=(0,a._)`${h}, ${r.object(...p)}`;return u!==a.nil?(0,a._)`${d}.call(${u}, ${f})`:(0,a._)`${d}(${f})`};let c=(0,a._)`new RegExp`;t.usePattern=function({gen:e,it:{opts:t}},r){let s=t.unicodeRegExp?"u":"",{regExp:i}=t.code,o=i(r,s);return e.scopeValue("pattern",{key:o.toString(),ref:o,code:(0,a._)`${"new RegExp"===i.code?c:(0,n.useFunc)(e,i)}(${r}, ${s})`})},t.validateArray=function(e){let{gen:t,data:r,keyword:i,it:n}=e,o=t.name("valid");if(n.allErrors){let e=t.let("valid",!0);return l(()=>t.assign(e,!1)),e}return t.var(o,!0),l(()=>t.break()),o;function l(n){let l=t.const("len",(0,a._)`${r}.length`);t.forRange("i",0,l,r=>{e.subschema({keyword:i,dataProp:r,dataPropType:s.Type.Num},o),t.if((0,a.not)(o),n)})}},t.validateUnion=function(e){let{gen:t,schema:r,keyword:i,it:n}=e;if(!Array.isArray(r))throw Error("ajv implementation error");if(r.some(e=>(0,s.alwaysValidSchema)(n,e))&&!n.opts.unevaluated)return;let o=t.let("valid",!1),l=t.name("_valid");t.block(()=>r.forEach((r,s)=>{let n=e.subschema({keyword:i,schemaProp:s,compositeRule:!0},l);t.assign(o,(0,a._)`${o} || ${l}`),e.mergeValidEvaluated(n,l)||t.if((0,a.not)(o))})),e.result(o,()=>e.reset(),()=>e.error(!0))}},73946(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default={keyword:"id",code(){throw Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}}},3839(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(73946),s=r(26138);t.default=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",a.default,s.default]},26138(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.callRef=t.getValidate=void 0;let a=r(85748),s=r(94450),i=r(17898),n=r(63036),o=r(49392),l=r(50458);function d(e,t){let{gen:r}=e;return t.validate?r.scopeValue("validate",{ref:t.validate}):(0,i._)`${r.scopeValue("wrapper",{ref:t})}.validate`}function u(e,t,r,a){let{gen:o,it:d}=e,{allErrors:u,schemaEnv:c,opts:h}=d,p=h.passContext?n.default.this:i.nil;function f(e){let t=(0,i._)`${e}.errors`;o.assign(n.default.vErrors,(0,i._)`${n.default.vErrors} === null ? ${t} : ${n.default.vErrors}.concat(${t})`),o.assign(n.default.errors,(0,i._)`${n.default.vErrors}.length`)}function m(e){var t;if(!d.opts.unevaluated)return;let a=null==(t=null==r?void 0:r.validate)?void 0:t.evaluated;if(!0!==d.props)if(a&&!a.dynamicProps)void 0!==a.props&&(d.props=l.mergeEvaluated.props(o,a.props,d.props));else{let t=o.var("props",(0,i._)`${e}.evaluated.props`);d.props=l.mergeEvaluated.props(o,t,d.props,i.Name)}if(!0!==d.items)if(a&&!a.dynamicItems)void 0!==a.items&&(d.items=l.mergeEvaluated.items(o,a.items,d.items));else{let t=o.var("items",(0,i._)`${e}.evaluated.items`);d.items=l.mergeEvaluated.items(o,t,d.items,i.Name)}}a?function(){if(!c.$async)throw Error("async schema referenced by sync schema");let r=o.let("valid");o.try(()=>{o.code((0,i._)`await ${(0,s.callValidateCode)(e,t,p)}`),m(t),u||o.assign(r,!0)},e=>{o.if((0,i._)`!(${e} instanceof ${d.ValidationError})`,()=>o.throw(e)),f(e),u||o.assign(r,!1)}),e.ok(r)}():e.result((0,s.callValidateCode)(e,t,p),()=>m(t),()=>f(t))}t.getValidate=d,t.callRef=u,t.default={keyword:"$ref",schemaType:"string",code(e){var t,r;let s,n,l,c,{gen:h,schema:p,it:f}=e,{baseId:m,schemaEnv:y,validateName:g,opts:v,self:_}=f,{root:$}=y;if(("#"===p||"#/"===p)&&m===$.baseId){if(y===$)return u(e,g,y,y.$async);let t=h.scopeValue("root",{ref:$});return u(e,(0,i._)`${t}.validate`,$,$.$async)}let b=o.resolveRef.call(_,$,m,p);if(void 0===b)throw new a.default(f.opts.uriResolver,m,p);return b instanceof o.SchemaEnv?(s=d(e,t=b),void u(e,s,t,t.$async)):(r=b,n=h.scopeValue("schema",!0===v.code.source?{ref:r,code:(0,i.stringify)(r)}:{ref:r}),l=h.name("valid"),c=e.subschema({schema:r,dataTypes:[],schemaPath:i.nil,topSchemaRef:n,errSchemaPath:p},l),void(e.mergeEvaluated(c),e.ok(l)))}}},11672(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=r(88925),i=r(49392),n=r(85748),o=r(50458);t.default={keyword:"discriminator",type:"object",schemaType:"object",error:{message:({params:{discrError:e,tagName:t}})=>e===s.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:r}})=>(0,a._)`{error: ${e}, tag: ${r}, tagValue: ${t}}`},code(e){let{gen:t,data:r,schema:l,parentSchema:d,it:u}=e,{oneOf:c}=d;if(!u.opts.discriminator)throw Error("discriminator: requires discriminator option");let h=l.propertyName;if("string"!=typeof h)throw Error("discriminator: requires propertyName");if(l.mapping)throw Error("discriminator: mapping is not supported");if(!c)throw Error("discriminator: requires oneOf keyword");let p=t.let("valid",!1),f=t.const("tag",(0,a._)`${r}${(0,a.getProperty)(h)}`);t.if((0,a._)`typeof ${f} == "string"`,()=>(function(){let r=function(){var e;let t={},r=s(d),a=!0;for(let t=0;t<c.length;t++){let d=c[t];if((null==d?void 0:d.$ref)&&!(0,o.schemaHasRulesButRef)(d,u.self.RULES)){let e=d.$ref;if((d=i.resolveRef.call(u.self,u.schemaEnv.root,u.baseId,e))instanceof i.SchemaEnv&&(d=d.schema),void 0===d)throw new n.default(u.opts.uriResolver,u.baseId,e)}let p=null==(e=null==d?void 0:d.properties)?void 0:e[h];if("object"!=typeof p)throw Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${h}"`);a=a&&(r||s(d)),function(e,t){if(e.const)l(e.const,t);else if(e.enum)for(let r of e.enum)l(r,t);else throw Error(`discriminator: "properties/${h}" must have "const" or "enum"`)}(p,t)}if(!a)throw Error(`discriminator: "${h}" must be required`);return t;function s({required:e}){return Array.isArray(e)&&e.includes(h)}function l(e,r){if("string"!=typeof e||e in t)throw Error(`discriminator: "${h}" values must be unique strings`);t[e]=r}}();for(let s in t.if(!1),r)t.elseIf((0,a._)`${f} === ${s}`),t.assign(p,function(r){let s=t.name("valid"),i=e.subschema({keyword:"oneOf",schemaProp:r},s);return e.mergeEvaluated(i,a.Name),s}(r[s]));t.else(),e.error(!1,{discrError:s.DiscrError.Mapping,tag:f,tagName:h}),t.endIf()})(),()=>e.error(!1,{discrError:s.DiscrError.Tag,tag:f,tagName:h})),e.ok(p)}}},88925(e,t){var r,a;Object.defineProperty(t,"__esModule",{value:!0}),t.DiscrError=void 0,(a=r||(t.DiscrError=r={})).Tag="tag",a.Mapping="mapping"},2431(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(3839),s=r(17851),i=r(18225),n=r(26699),o=r(34882);t.default=[a.default,s.default,(0,i.default)(),n.default,o.metadataVocabulary,o.contentVocabulary]},37072(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898);t.default={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:{message:({schemaCode:e})=>(0,a.str)`must match format "${e}"`,params:({schemaCode:e})=>(0,a._)`{format: ${e}}`},code(e,t){let r,s,i,n,o,l,{gen:d,data:u,$data:c,schema:h,schemaCode:p,it:f}=e,{opts:m,errSchemaPath:y,schemaEnv:g,self:v}=f;m.validateFormats&&(c?(r=d.scopeValue("formats",{ref:v.formats,code:m.code.formats}),s=d.const("fDef",(0,a._)`${r}[${p}]`),i=d.let("fType"),n=d.let("format"),d.if((0,a._)`typeof ${s} == "object" && !(${s} instanceof RegExp)`,()=>d.assign(i,(0,a._)`${s}.type || "string"`).assign(n,(0,a._)`${s}.validate`),()=>d.assign(i,(0,a._)`"string"`).assign(n,s)),e.fail$data((0,a.or)(!1===m.strictSchema?a.nil:(0,a._)`${p} && !${n}`,(o=g.$async?(0,a._)`(${s}.async ? await ${n}(${u}) : ${n}(${u}))`:(0,a._)`${n}(${u})`,l=(0,a._)`(typeof ${n} == "function" ? ${o} : ${n}.test(${u}))`,(0,a._)`${n} && ${n} !== true && ${i} === ${t} && !${l}`)))):function(){var r;let s,i,n=v.formats[h];if(!n){if(!1===m.strictSchema)return v.logger.warn(o());throw Error(o());function o(){return`unknown format "${h}" ignored in schema at path "${y}"`}}if(!0===n)return;let[l,c,p]=(s=(r=n)instanceof RegExp?(0,a.regexpCode)(r):m.code.formats?(0,a._)`${m.code.formats}${(0,a.getProperty)(h)}`:void 0,i=d.scopeValue("formats",{key:h,ref:r,code:s}),"object"!=typeof r||r instanceof RegExp?["string",r,i]:[r.type||"string",r.validate,(0,a._)`${i}.validate`]);l===t&&e.pass(function(){if("object"==typeof n&&!(n instanceof RegExp)&&n.async){if(!g.$async)throw Error("async format in sync schema");return(0,a._)`await ${p}(${u})`}return"function"==typeof c?(0,a._)`${p}(${u})`:(0,a._)`${p}.test(${u})`}())}())}}},26699(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.default=[r(37072).default]},34882(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.contentVocabulary=t.metadataVocabulary=void 0,t.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"],t.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]},79520(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=r(50458),i=r(72725);t.default={keyword:"const",$data:!0,error:{message:"must be equal to constant",params:({schemaCode:e})=>(0,a._)`{allowedValue: ${e}}`},code(e){let{gen:t,data:r,$data:n,schemaCode:o,schema:l}=e;n||l&&"object"==typeof l?e.fail$data((0,a._)`!${(0,s.useFunc)(t,i.default)}(${r}, ${o})`):e.fail((0,a._)`${l} !== ${r}`)}}},36742(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=r(50458),i=r(72725);t.default={keyword:"enum",schemaType:"array",$data:!0,error:{message:"must be equal to one of the allowed values",params:({schemaCode:e})=>(0,a._)`{allowedValues: ${e}}`},code(e){let t,r,{gen:n,data:o,$data:l,schema:d,schemaCode:u,it:c}=e;if(!l&&0===d.length)throw Error("enum must have non-empty array");let h=d.length>=c.opts.loopEnum,p=()=>null!=t?t:t=(0,s.useFunc)(n,i.default);if(h||l)r=n.let("valid"),e.block$data(r,function(){n.assign(r,!1),n.forOf("v",u,e=>n.if((0,a._)`${p()}(${o}, ${e})`,()=>n.assign(r,!0).break()))});else{if(!Array.isArray(d))throw Error("ajv implementation error");let e=n.const("vSchema",u);r=(0,a.or)(...d.map((t,r)=>{var s,i;let n;return s=e,"object"==typeof(n=d[i=r])&&null!==n?(0,a._)`${p()}(${o}, ${s}[${i}])`:(0,a._)`${o} === ${n}`}))}e.pass(r)}}},17851(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(72333),s=r(21230),i=r(3936),n=r(81005),o=r(71589),l=r(29594),d=r(38558),u=r(44058),c=r(79520),h=r(36742);t.default=[a.default,s.default,i.default,n.default,o.default,l.default,d.default,u.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},c.default,h.default]},38558(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898);t.default={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:{message:({keyword:e,schemaCode:t})=>(0,a.str)`must NOT have ${"maxItems"===e?"more":"fewer"} than ${t} items`,params:({schemaCode:e})=>(0,a._)`{limit: ${e}}`},code(e){let{keyword:t,data:r,schemaCode:s}=e,i="maxItems"===t?a.operators.GT:a.operators.LT;e.fail$data((0,a._)`${r}.length ${i} ${s}`)}}},3936(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=r(50458),i=r(26308);t.default={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:{message:({keyword:e,schemaCode:t})=>(0,a.str)`must NOT have ${"maxLength"===e?"more":"fewer"} than ${t} characters`,params:({schemaCode:e})=>(0,a._)`{limit: ${e}}`},code(e){let{keyword:t,data:r,schemaCode:n,it:o}=e,l="maxLength"===t?a.operators.GT:a.operators.LT,d=!1===o.opts.unicode?(0,a._)`${r}.length`:(0,a._)`${(0,s.useFunc)(e.gen,i.default)}(${r})`;e.fail$data((0,a._)`${d} ${l} ${n}`)}}},72333(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=a.operators,i={maximum:{okStr:"<=",ok:s.LTE,fail:s.GT},minimum:{okStr:">=",ok:s.GTE,fail:s.LT},exclusiveMaximum:{okStr:"<",ok:s.LT,fail:s.GTE},exclusiveMinimum:{okStr:">",ok:s.GT,fail:s.LTE}};t.default={keyword:Object.keys(i),type:"number",schemaType:"number",$data:!0,error:{message:({keyword:e,schemaCode:t})=>(0,a.str)`must be ${i[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>(0,a._)`{comparison: ${i[e].okStr}, limit: ${t}}`},code(e){let{keyword:t,data:r,schemaCode:s}=e;e.fail$data((0,a._)`${r} ${i[t].fail} ${s} || isNaN(${r})`)}}},71589(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898);t.default={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:{message:({keyword:e,schemaCode:t})=>(0,a.str)`must NOT have ${"maxProperties"===e?"more":"fewer"} than ${t} properties`,params:({schemaCode:e})=>(0,a._)`{limit: ${e}}`},code(e){let{keyword:t,data:r,schemaCode:s}=e,i="maxProperties"===t?a.operators.GT:a.operators.LT;e.fail$data((0,a._)`Object.keys(${r}).length ${i} ${s}`)}}},21230(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898);t.default={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:{message:({schemaCode:e})=>(0,a.str)`must be multiple of ${e}`,params:({schemaCode:e})=>(0,a._)`{multipleOf: ${e}}`},code(e){let{gen:t,data:r,schemaCode:s,it:i}=e,n=i.opts.multipleOfPrecision,o=t.let("res"),l=n?(0,a._)`Math.abs(Math.round(${o}) - ${o}) > 1e-${n}`:(0,a._)`${o} !== parseInt(${o})`;e.fail$data((0,a._)`(${s} === 0 || (${o} = ${r}/${s}, ${l}))`)}}},81005(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(94450),s=r(50458),i=r(17898);t.default={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:{message:({schemaCode:e})=>(0,i.str)`must match pattern "${e}"`,params:({schemaCode:e})=>(0,i._)`{pattern: ${e}}`},code(e){let{gen:t,data:r,$data:n,schema:o,schemaCode:l,it:d}=e,u=d.opts.unicodeRegExp?"u":"";if(n){let{regExp:a}=d.opts.code,n="new RegExp"===a.code?(0,i._)`new RegExp`:(0,s.useFunc)(t,a),o=t.let("valid");t.try(()=>t.assign(o,(0,i._)`${n}(${l}, ${u}).test(${r})`),()=>t.assign(o,!1)),e.fail$data((0,i._)`!${o}`)}else{let t=(0,a.usePattern)(e,o);e.fail$data((0,i._)`!${t}.test(${r})`)}}}},29594(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(94450),s=r(17898),i=r(50458);t.default={keyword:"required",type:"object",schemaType:"array",$data:!0,error:{message:({params:{missingProperty:e}})=>(0,s.str)`must have required property '${e}'`,params:({params:{missingProperty:e}})=>(0,s._)`{missingProperty: ${e}}`},code(e){let{gen:t,schema:r,schemaCode:n,data:o,$data:l,it:d}=e,{opts:u}=d;if(!l&&0===r.length)return;let c=r.length>=u.loopRequired;if(d.allErrors?function(){if(c||l)e.block$data(s.nil,h);else for(let t of r)(0,a.checkReportMissingProp)(e,t)}():function(){let i=t.let("missing");if(c||l){let r=t.let("valid",!0);e.block$data(r,()=>{var l,d;return l=i,d=r,void(e.setParams({missingProperty:l}),t.forOf(l,n,()=>{t.assign(d,(0,a.propertyInData)(t,o,l,u.ownProperties)),t.if((0,s.not)(d),()=>{e.error(),t.break()})},s.nil))}),e.ok(r)}else t.if((0,a.checkMissingProp)(e,r,i)),(0,a.reportMissingProp)(e,i),t.else()}(),u.strictRequired){let t=e.parentSchema.properties,{definedProperties:a}=e.it;for(let e of r)if((null==t?void 0:t[e])===void 0&&!a.has(e)){let t=d.schemaEnv.baseId+d.errSchemaPath,r=`required property "${e}" is not defined at "${t}" (strictRequired)`;(0,i.checkStrictMode)(d,r,d.opts.strictRequired)}}function h(){t.forOf("prop",n,r=>{e.setParams({missingProperty:r}),t.if((0,a.noPropertyInData)(t,o,r,u.ownProperties),()=>e.error())})}}}},44058(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(69003),s=r(17898),i=r(50458),n=r(72725);t.default={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:{message:({params:{i:e,j:t}})=>(0,s.str)`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>(0,s._)`{i: ${e}, j: ${t}}`},code(e){let{gen:t,data:r,$data:o,schema:l,parentSchema:d,schemaCode:u,it:c}=e;if(!o&&!l)return;let h=t.let("valid"),p=d.items?(0,a.getSchemaTypes)(d.items):[];e.block$data(h,function(){let o=t.let("i",(0,s._)`${r}.length`),l=t.let("j");e.setParams({i:o,j:l}),t.assign(h,!0),t.if((0,s._)`${o} > 1`,()=>(p.length>0&&!p.some(e=>"object"===e||"array"===e)?function(i,n){let o=t.name("item"),l=(0,a.checkDataTypes)(p,o,c.opts.strictNumbers,a.DataType.Wrong),d=t.const("indices",(0,s._)`{}`);t.for((0,s._)`;${i}--;`,()=>{t.let(o,(0,s._)`${r}[${i}]`),t.if(l,(0,s._)`continue`),p.length>1&&t.if((0,s._)`typeof ${o} == "string"`,(0,s._)`${o} += "_"`),t.if((0,s._)`typeof ${d}[${o}] == "number"`,()=>{t.assign(n,(0,s._)`${d}[${o}]`),e.error(),t.assign(h,!1).break()}).code((0,s._)`${d}[${o}] = ${i}`)})}:function(a,o){let l=(0,i.useFunc)(t,n.default),d=t.name("outer");t.label(d).for((0,s._)`;${a}--;`,()=>t.for((0,s._)`${o} = ${a}; ${o}--;`,()=>t.if((0,s._)`${l}(${r}[${a}], ${r}[${o}])`,()=>{e.error(),t.assign(h,!1).break(d)})))})(o,l))},(0,s._)`${u} === false`),e.ok(h)}}},38792(e){e.exports=function e(t,r){if(t===r)return!0;if(t&&r&&"object"==typeof t&&"object"==typeof r){if(t.constructor!==r.constructor)return!1;if(Array.isArray(t)){if((a=t.length)!=r.length)return!1;for(s=a;0!=s--;)if(!e(t[s],r[s]))return!1;return!0}if(t.constructor===RegExp)return t.source===r.source&&t.flags===r.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===r.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===r.toString();if((a=(i=Object.keys(t)).length)!==Object.keys(r).length)return!1;for(s=a;0!=s--;)if(!Object.prototype.hasOwnProperty.call(r,i[s]))return!1;for(s=a;0!=s--;){var a,s,i,n=i[s];if(!e(t[n],r[n]))return!1}return!0}return t!=t&&r!=r}},1645(e){var t=e.exports=function(e,r,a){"function"==typeof r&&(a=r,r={});var s="function"==typeof(a=r.cb||a)?a:a.pre||function(){};!function e(r,a,s,i,n,o,l,d,u,c){if(i&&"object"==typeof i&&!Array.isArray(i)){for(var h in a(i,n,o,l,d,u,c),i){var p=i[h];if(Array.isArray(p)){if(h in t.arrayKeywords)for(var f=0;f<p.length;f++)e(r,a,s,p[f],n+"/"+h+"/"+f,o,n,h,i,f)}else if(h in t.propsKeywords){if(p&&"object"==typeof p)for(var m in p)e(r,a,s,p[m],n+"/"+h+"/"+m.replace(/~/g,"~0").replace(/\//g,"~1"),o,n,h,i,m)}else(h in t.keywords||r.allKeys&&!(h in t.skipKeywords))&&e(r,a,s,p,n+"/"+h,o,n,h,i)}s(i,n,o,l,d,u,c)}}(r,s,a.post||function(){},e,"",e)};t.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0},t.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0},t.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0},t.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}},84800(e,t,r){let{normalizeIPv6:a,removeDotSegments:s,recomposeAuthority:i,normalizePercentEncoding:n,normalizePathEncoding:o,escapePreservingEscapes:l,reescapeHostDelimiters:d,isIPv4:u,nonSimpleDomain:c}=r(75365),{SCHEMES:h,getSchemeHandler:p}=r(13956);function f(e,t,r,a){let i={};return a||(e=_(m(e,r),r),t=_(m(t,r),r)),!(r=r||{}).tolerant&&t.scheme?(i.scheme=t.scheme,i.userinfo=t.userinfo,i.host=t.host,i.port=t.port,i.path=s(t.path||""),i.query=t.query):(void 0!==t.userinfo||void 0!==t.host||void 0!==t.port?(i.userinfo=t.userinfo,i.host=t.host,i.port=t.port,i.path=s(t.path||""),i.query=t.query):(t.path?("/"===t.path[0]?i.path=s(t.path):(void 0===e.userinfo&&void 0===e.host&&void 0===e.port||e.path?e.path?i.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:i.path=t.path:i.path="/"+t.path,i.path=s(i.path)),i.query=t.query):(i.path=e.path,void 0!==t.query?i.query=t.query:i.query=e.query),i.userinfo=e.userinfo,i.host=e.host,i.port=e.port),i.scheme=e.scheme),i.fragment=t.fragment,i}function m(e,t){let r={host:e.host,scheme:e.scheme,userinfo:e.userinfo,port:e.port,path:e.path,query:e.query,nid:e.nid,nss:e.nss,uuid:e.uuid,fragment:e.fragment,reference:e.reference,resourceName:e.resourceName,secure:e.secure,error:""},a=Object.assign({},t),o=[],d=p(a.scheme||r.scheme);d&&d.serialize&&d.serialize(r,a),void 0!==r.path&&(a.skipEscape?r.path=n(r.path):(r.path=l(r.path),void 0!==r.scheme&&(r.path=r.path.split("%3A").join(":")))),"suffix"!==a.reference&&r.scheme&&o.push(r.scheme,":");let u=i(r);if(void 0!==u&&("suffix"!==a.reference&&o.push("//"),o.push(u),r.path&&"/"!==r.path[0]&&o.push("/")),void 0!==r.path){let e=r.path;a.absolutePath||d&&d.absolutePath||(e=s(e)),void 0===u&&"/"===e[0]&&"/"===e[1]&&(e="/%2F"+e.slice(2)),o.push(e)}return void 0!==r.query&&o.push("?",r.query),void 0!==r.fragment&&o.push("#",r.fragment),o.join("")}let y=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u,g=/^(?:[^#/:?]+:)?\/\/([^/?#]*)/;function v(e,t){let r=Object.assign({},t),s={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0},i=!1,n=!1;"suffix"===r.reference&&(e=r.scheme?r.scheme+":"+e:"//"+e);let l=e.match(g);null!==l&&-1!==l[1].indexOf("\\")&&(s.error="URI authority must not contain a literal backslash.",i=!0);let h=e.match(y);if(h){s.scheme=h[1],s.userinfo=h[3],s.host=h[4],s.port=parseInt(h[5],10),s.path=h[6]||"",s.query=h[7],s.fragment=h[8],isNaN(s.port)&&(s.port=h[5]);let t=void 0!==h[2]&&s.path&&"/"!==s.path[0]?'URI path must start with "/" when authority is present.':"number"==typeof s.port&&(s.port<0||s.port>65535)?"URI port is malformed.":void 0;if(void 0!==t&&(s.error=s.error||t,i=!0),s.host)if(!1===u(s.host)){let e=a(s.host);s.host=e.host.toLowerCase(),n=e.isIPV6}else n=!0;void 0!==s.scheme||void 0!==s.userinfo||void 0!==s.host||void 0!==s.port||void 0!==s.query||s.path?void 0===s.scheme?s.reference="relative":void 0===s.fragment?s.reference="absolute":s.reference="uri":s.reference="same-document",r.reference&&"suffix"!==r.reference&&r.reference!==s.reference&&(s.error=s.error||"URI is not a "+r.reference+" reference.");let l=p(r.scheme||s.scheme);if(!r.unicodeSupport&&(!l||!l.unicodeSupport)&&s.host&&(r.domainHost||l&&l.domainHost)&&!1===n&&c(s.host))try{s.host=new URL("http://"+s.host).hostname}catch(e){s.error=s.error||"Host's domain name can not be converted to ASCII: "+e}if((!l||l&&!l.skipNormalize)&&(-1!==e.indexOf("%")&&(void 0!==s.scheme&&(s.scheme=unescape(s.scheme)),void 0!==s.host&&(s.host=d(unescape(s.host),n))),s.path&&(s.path=o(s.path)),s.fragment))try{s.fragment=encodeURI(decodeURIComponent(s.fragment))}catch{s.error=s.error||"URI malformed"}l&&l.parse&&l.parse(s,r)}else s.error=s.error||"URI can not be parsed.";return{parsed:s,malformedAuthorityOrPort:i}}function _(e,t){return v(e,t).parsed}function $(e,t){let{parsed:r,malformedAuthorityOrPort:a}=v(e,t);return{normalized:a?e:m(r,t),malformedAuthorityOrPort:a}}function b(e,t){if("string"==typeof e){let{normalized:r,malformedAuthorityOrPort:a}=$(e,t);return a?void 0:r}if("object"==typeof e)return m(e,t)}let w={SCHEMES:h,normalize:function(e,t){return"string"==typeof e?e=$(e,t).normalized:"object"==typeof e&&(e=_(m(e,t),t)),e},resolve:function(e,t,r){let a=r?Object.assign({scheme:"null"},r):{scheme:"null"},s=f(_(e,a),_(t,a),a,!0);return a.skipEscape=!0,m(s,a)},resolveComponent:f,equal:function(e,t,r){let a=b(e,r),s=b(t,r);return void 0!==a&&void 0!==s&&a.toLowerCase()===s.toLowerCase()},serialize:m,parse:_};e.exports=w,e.exports.default=w,e.exports.fastUri=w},13956(e,t,r){let{isUUID:a}=r(75365),s=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu,i=["http","https","ws","wss","urn","urn:uuid"];function n(e){return!0===e.secure||!1!==e.secure&&!!e.scheme&&3===e.scheme.length&&("w"===e.scheme[0]||"W"===e.scheme[0])&&("s"===e.scheme[1]||"S"===e.scheme[1])&&("s"===e.scheme[2]||"S"===e.scheme[2])}function o(e){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e}function l(e){let t="https"===String(e.scheme).toLowerCase();return(e.port===(t?443:80)||""===e.port)&&(e.port=void 0),e.path||(e.path="/"),e}let d={scheme:"http",domainHost:!0,parse:o,serialize:l},u={scheme:"https",domainHost:d.domainHost,parse:o,serialize:l},c={scheme:"ws",domainHost:!0,parse:function(e){return e.secure=n(e),e.resourceName=(e.path||"/")+(e.query?"?"+e.query:""),e.path=void 0,e.query=void 0,e},serialize:function(e){if((e.port===(n(e)?443:80)||""===e.port)&&(e.port=void 0),"boolean"==typeof e.secure&&(e.scheme=e.secure?"wss":"ws",e.secure=void 0),e.resourceName){let[t,r]=e.resourceName.split("?");e.path=t&&"/"!==t?t:void 0,e.query=r,e.resourceName=void 0}return e.fragment=void 0,e}},h={scheme:"wss",domainHost:c.domainHost,parse:c.parse,serialize:c.serialize},p={http:d,https:u,ws:c,wss:h,urn:{scheme:"urn",parse:function(e,t){if(!e.path)return e.error="URN can not be parsed",e;let r=e.path.match(s);if(r){let a=t.scheme||e.scheme||"urn";e.nid=r[1].toLowerCase(),e.nss=r[2];let s=f(`${a}:${t.nid||e.nid}`);e.path=void 0,s&&(e=s.parse(e,t))}else e.error=e.error||"URN can not be parsed.";return e},serialize:function(e,t){if(void 0===e.nid)throw Error("URN without nid cannot be serialized");let r=t.scheme||e.scheme||"urn",a=e.nid.toLowerCase(),s=f(`${r}:${t.nid||a}`);s&&(e=s.serialize(e,t));let i=e,n=e.nss;return i.path=`${a||t.nid}:${n}`,t.skipEscape=!0,i},skipNormalize:!0},"urn:uuid":{scheme:"urn:uuid",parse:function(e,t){return e.uuid=e.nss,e.nss=void 0,t.tolerant||e.uuid&&a(e.uuid)||(e.error=e.error||"UUID is not valid."),e},serialize:function(e){return e.nss=(e.uuid||"").toLowerCase(),e},skipNormalize:!0}};function f(e){return e&&(p[e]||p[e.toLowerCase()])||void 0}Object.setPrototypeOf(p,null),e.exports={wsIsSecure:n,SCHEMES:p,isValidSchemeName:function(e){return -1!==i.indexOf(e)},getSchemeHandler:f}},75365(e){let t=RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu),r=RegExp.prototype.test.bind(/^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u),a=RegExp.prototype.test.bind(/^[\da-f]{2}$/iu),s=RegExp.prototype.test.bind(/^[\da-z\-._~]$/iu),i=RegExp.prototype.test.bind(/^[\da-z\-._~!$&'()*+,;=:@/]$/iu);function n(e){let t="",r=0,a=0;for(a=0;a<e.length;a++)if(48!==(r=e[a].charCodeAt(0))){if(!(r>=48&&r<=57||r>=65&&r<=70||r>=97&&r<=102))return"";t+=e[a];break}for(a+=1;a<e.length;a++){if(!((r=e[a].charCodeAt(0))>=48&&r<=57||r>=65&&r<=70||r>=97&&r<=102))return"";t+=e[a]}return t}let o=RegExp.prototype.test.bind(/[^!"$&'()*+,\-.;=_`a-z{}~]/u);function l(e){return e.length=0,!0}function d(e,t,r){if(e.length){let a=n(e);if(""===a)return r.error=!0,!1;t.push(a),e.length=0}return!0}function u(e){if(2>function(e){let t=0;for(let r=0;r<e.length;r++)":"===e[r]&&t++;return t}(e))return{host:e,isIPV6:!1};let t=function(e){let t=0,r={error:!1,address:"",zone:""},a=[],s=[],i=!1,o=!1,u=d;for(let n=0;n<e.length;n++){let d=e[n];if("["!==d&&"]"!==d)if(":"===d){if(!0===i&&(o=!0),!u(s,a,r))break;if(++t>7){r.error=!0;break}n>0&&":"===e[n-1]&&(i=!0),a.push(":");continue}else if("%"===d){if(!u(s,a,r))break;u=l}else{s.push(d);continue}}return s.length&&(u===l?r.zone=s.join(""):o?a.push(s.join("")):a.push(n(s))),r.address=a.join(""),r}(e);if(t.error)return{host:e,isIPV6:!1};{let e=t.address,r=t.address;return t.zone&&(e+="%"+t.zone,r+="%25"+t.zone),{host:e,isIPV6:!0,escapedHost:r}}}let c={"@":"%40","/":"%2F","?":"%3F","#":"%23",":":"%3A"},h=/[@/?#:]/g,p=/[@/?#]/g;function f(e,t){let r=t?p:h;return r.lastIndex=0,e.replace(r,e=>c[e])}e.exports={nonSimpleDomain:o,recomposeAuthority:function(e){let t=[];if(void 0!==e.userinfo&&(t.push(e.userinfo),t.push("@")),void 0!==e.host){let a=unescape(e.host);if(!r(a)){let e=u(a);a=!0===e.isIPV6?`[${e.escapedHost}]`:f(a,!1)}t.push(a)}return("number"==typeof e.port||"string"==typeof e.port)&&(t.push(":"),t.push(String(e.port))),t.length?t.join(""):void 0},reescapeHostDelimiters:f,normalizePercentEncoding:function(e,t=!1){if(-1===e.indexOf("%"))return e;let r="";for(let i=0;i<e.length;i++){if("%"===e[i]&&i+2<e.length){let n=e.slice(i+1,i+3);if(a(n)){let e=n.toUpperCase(),a=String.fromCharCode(parseInt(e,16));t&&s(a)?r+=a:r+="%"+e,i+=2;continue}}r+=e[i]}return r},normalizePathEncoding:function(e){let t="";for(let r=0;r<e.length;r++){if("%"===e[r]&&r+2<e.length){let i=e.slice(r+1,r+3);if(a(i)){let e=i.toUpperCase(),a=String.fromCharCode(parseInt(e,16));"."!==a&&s(a)?t+=a:t+="%"+e,r+=2;continue}}i(e[r])?t+=e[r]:t+=escape(e[r])}return t},escapePreservingEscapes:function(e){let t="";for(let r=0;r<e.length;r++){if("%"===e[r]&&r+2<e.length){let s=e.slice(r+1,r+3);if(a(s)){t+="%"+s.toUpperCase(),r+=2;continue}}t+=escape(e[r])}return t},removeDotSegments:function(e){let t=e,r=[],a=-1,s=0;for(;s=t.length;){if(1===s)if("."===t)break;else if("/"===t){r.push("/");break}else{r.push(t);break}if(2===s){if("."===t[0]){if("."===t[1])break;else if("/"===t[1]){t=t.slice(2);continue}}else if("/"===t[0]&&("."===t[1]||"/"===t[1])){r.push("/");break}}else if(3===s&&"/.."===t){0!==r.length&&r.pop(),r.push("/");break}if("."===t[0]){if("."===t[1]){if("/"===t[2]){t=t.slice(3);continue}}else if("/"===t[1]){t=t.slice(2);continue}}else if("/"===t[0]&&"."===t[1]){if("/"===t[2]){t=t.slice(2);continue}else if("."===t[2]&&"/"===t[3]){t=t.slice(3),0!==r.length&&r.pop();continue}}if(-1===(a=t.indexOf("/",1))){r.push(t);break}r.push(t.slice(0,a)),t=t.slice(a)}return r.join("")},isIPv4:r,isUUID:t,normalizeIPv6:u,stringArrayToHexStripped:n}},22654(e,t,r){r.d(t,{G:()=>i,eq:()=>s});var a=r(62741);let s=a.ZS.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]);class i extends Error{get errors(){return this.issues}constructor(e){super(),this.issues=[],this.addIssue=e=>{this.issues=[...this.issues,e]},this.addIssues=(e=[])=>{this.issues=[...this.issues,...e]};const t=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,t):this.__proto__=t,this.name="ZodError",this.issues=e}format(e){let t=e||function(e){return e.message},r={_errors:[]},a=e=>{for(let s of e.issues)if("invalid_union"===s.code)s.unionErrors.map(a);else if("invalid_return_type"===s.code)a(s.returnTypeError);else if("invalid_arguments"===s.code)a(s.argumentsError);else if(0===s.path.length)r._errors.push(t(s));else{let e=r,a=0;for(;a<s.path.length;){let r=s.path[a];a===s.path.length-1?(e[r]=e[r]||{_errors:[]},e[r]._errors.push(t(s))):e[r]=e[r]||{_errors:[]},e=e[r],a++}}};return a(this),r}static assert(e){if(!(e instanceof i))throw Error(`Not a ZodError: ${e}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,a.ZS.jsonStringifyReplacer,2)}get isEmpty(){return 0===this.issues.length}flatten(e=e=>e.message){let t={},r=[];for(let a of this.issues)if(a.path.length>0){let r=a.path[0];t[r]=t[r]||[],t[r].push(e(a))}else r.push(e(a));return{formErrors:r,fieldErrors:t}}get formErrors(){return this.flatten()}}i.create=e=>new i(e)},62741(e,t,r){var a,s,i;r.d(t,{CR:()=>o,ZS:()=>a,Zp:()=>n}),(i=a||(a={})).assertEqual=e=>{},i.assertIs=function(e){},i.assertNever=function(e){throw Error()},i.arrayToEnum=e=>{let t={};for(let r of e)t[r]=r;return t},i.getValidEnumValues=e=>{let t=i.objectKeys(e).filter(t=>"number"!=typeof e[e[t]]),r={};for(let a of t)r[a]=e[a];return i.objectValues(r)},i.objectValues=e=>i.objectKeys(e).map(function(t){return e[t]}),i.objectKeys="function"==typeof Object.keys?e=>Object.keys(e):e=>{let t=[];for(let r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.push(r);return t},i.find=(e,t)=>{for(let r of e)if(t(r))return r},i.isInteger="function"==typeof Number.isInteger?e=>Number.isInteger(e):e=>"number"==typeof e&&Number.isFinite(e)&&Math.floor(e)===e,i.joinValues=function(e,t=" | "){return e.map(e=>"string"==typeof e?`'${e}'`:e).join(t)},i.jsonStringifyReplacer=(e,t)=>"bigint"==typeof t?t.toString():t,(s||(s={})).mergeShapes=(e,t)=>({...e,...t});let n=a.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),o=e=>{switch(typeof e){case"undefined":return n.undefined;case"string":return n.string;case"number":return Number.isNaN(e)?n.nan:n.number;case"boolean":return n.boolean;case"function":return n.function;case"bigint":return n.bigint;case"symbol":return n.symbol;case"object":if(Array.isArray(e))return n.array;if(null===e)return n.null;if(e.then&&"function"==typeof e.then&&e.catch&&"function"==typeof e.catch)return n.promise;if("u">typeof Map&&e instanceof Map)return n.map;if("u">typeof Set&&e instanceof Set)return n.set;if("u">typeof Date&&e instanceof Date)return n.date;return n.object;default:return n.unknown}}},71291(e,t,r){let a;r.d(t,{k5:()=>eT,L5:()=>ex,g1:()=>eN,re:()=>eE,Ik:()=>eS,YO:()=>eP,Yj:()=>ek,eu:()=>eO,PV:()=>ej});var s,i,n,o,l=r(22654),d=r(62741);let u=(e,t)=>{let r;switch(e.code){case l.eq.invalid_type:r=e.received===d.Zp.undefined?"Required":`Expected ${e.expected}, received ${e.received}`;break;case l.eq.invalid_literal:r=`Invalid literal value, expected ${JSON.stringify(e.expected,d.ZS.jsonStringifyReplacer)}`;break;case l.eq.unrecognized_keys:r=`Unrecognized key(s) in object: ${d.ZS.joinValues(e.keys,", ")}`;break;case l.eq.invalid_union:r="Invalid input";break;case l.eq.invalid_union_discriminator:r=`Invalid discriminator value. Expected ${d.ZS.joinValues(e.options)}`;break;case l.eq.invalid_enum_value:r=`Invalid enum value. Expected ${d.ZS.joinValues(e.options)}, received '${e.received}'`;break;case l.eq.invalid_arguments:r="Invalid function arguments";break;case l.eq.invalid_return_type:r="Invalid function return type";break;case l.eq.invalid_date:r="Invalid date";break;case l.eq.invalid_string:"object"==typeof e.validation?"includes"in e.validation?(r=`Invalid input: must include "${e.validation.includes}"`,"number"==typeof e.validation.position&&(r=`${r} at one or more positions greater than or equal to ${e.validation.position}`)):"startsWith"in e.validation?r=`Invalid input: must start with "${e.validation.startsWith}"`:"endsWith"in e.validation?r=`Invalid input: must end with "${e.validation.endsWith}"`:d.ZS.assertNever(e.validation):r="regex"!==e.validation?`Invalid ${e.validation}`:"Invalid";break;case l.eq.too_small:r="array"===e.type?`Array must contain ${e.exact?"exactly":e.inclusive?"at least":"more than"} ${e.minimum} element(s)`:"string"===e.type?`String must contain ${e.exact?"exactly":e.inclusive?"at least":"over"} ${e.minimum} character(s)`:"number"===e.type||"bigint"===e.type?`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:"date"===e.type?`Date must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(e.minimum))}`:"Invalid input";break;case l.eq.too_big:r="array"===e.type?`Array must contain ${e.exact?"exactly":e.inclusive?"at most":"less than"} ${e.maximum} element(s)`:"string"===e.type?`String must contain ${e.exact?"exactly":e.inclusive?"at most":"under"} ${e.maximum} character(s)`:"number"===e.type?`Number must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:"bigint"===e.type?`BigInt must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:"date"===e.type?`Date must be ${e.exact?"exactly":e.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(e.maximum))}`:"Invalid input";break;case l.eq.custom:r="Invalid input";break;case l.eq.invalid_intersection_types:r="Intersection results could not be merged";break;case l.eq.not_multiple_of:r=`Number must be a multiple of ${e.multipleOf}`;break;case l.eq.not_finite:r="Number must be finite";break;default:r=t.defaultError,d.ZS.assertNever(e)}return{message:r}};(s=n||(n={})).errToObj=e=>"string"==typeof e?{message:e}:e||{},s.toString=e=>"string"==typeof e?e:e?.message;let c=e=>{let{data:t,path:r,errorMaps:a,issueData:s}=e,i=[...r,...s.path||[]],n={...s,path:i};if(void 0!==s.message)return{...s,path:i,message:s.message};let o="";for(let e of a.filter(e=>!!e).slice().reverse())o=e(n,{data:t,defaultError:o}).message;return{...s,path:i,message:o}};function h(e,t){let r=c({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,u,void 0].filter(e=>!!e)});e.common.issues.push(r)}class p{constructor(){this.value="valid"}dirty(){"valid"===this.value&&(this.value="dirty")}abort(){"aborted"!==this.value&&(this.value="aborted")}static mergeArray(e,t){let r=[];for(let a of t){if("aborted"===a.status)return f;"dirty"===a.status&&e.dirty(),r.push(a.value)}return{status:e.value,value:r}}static async mergeObjectAsync(e,t){let r=[];for(let e of t){let t=await e.key,a=await e.value;r.push({key:t,value:a})}return p.mergeObjectSync(e,r)}static mergeObjectSync(e,t){let r={};for(let a of t){let{key:t,value:s}=a;if("aborted"===t.status||"aborted"===s.status)return f;"dirty"===t.status&&e.dirty(),"dirty"===s.status&&e.dirty(),"__proto__"!==t.value&&(void 0!==s.value||a.alwaysSet)&&(r[t.value]=s.value)}return{status:e.value,value:r}}}let f=Object.freeze({status:"aborted"}),m=e=>({status:"dirty",value:e}),y=e=>({status:"valid",value:e}),g=e=>"u">typeof Promise&&e instanceof Promise;class v{constructor(e,t,r,a){this._cachedPath=[],this.parent=e,this.data=t,this._path=r,this._key=a}get path(){return this._cachedPath.length||(Array.isArray(this._key)?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}let _=(e,t)=>{if("valid"===t.status)return{success:!0,data:t.value};if(!e.common.issues.length)throw Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;let t=new l.G(e.common.issues);return this._error=t,this._error}}};function $(e){if(!e)return{};let{errorMap:t,invalid_type_error:r,required_error:a,description:s}=e;if(t&&(r||a))throw Error('Can\'t use "invalid_type_error" or "required_error" in conjunction with custom error map.');return t?{errorMap:t,description:s}:{errorMap:(t,s)=>{let{message:i}=e;return"invalid_enum_value"===t.code?{message:i??s.defaultError}:void 0===s.data?{message:i??a??s.defaultError}:"invalid_type"!==t.code?{message:s.defaultError}:{message:i??r??s.defaultError}},description:s}}class b{get description(){return this._def.description}_getType(e){return(0,d.CR)(e.data)}_getOrReturnCtx(e,t){return t||{common:e.parent.common,data:e.data,parsedType:(0,d.CR)(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new p,ctx:{common:e.parent.common,data:e.data,parsedType:(0,d.CR)(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){let t=this._parse(e);if(g(t))throw Error("Synchronous parse encountered promise.");return t}_parseAsync(e){return Promise.resolve(this._parse(e))}parse(e,t){let r=this.safeParse(e,t);if(r.success)return r.data;throw r.error}safeParse(e,t){let r={common:{issues:[],async:t?.async??!1,contextualErrorMap:t?.errorMap},path:t?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:(0,d.CR)(e)},a=this._parseSync({data:e,path:r.path,parent:r});return _(r,a)}"~validate"(e){let t={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:(0,d.CR)(e)};if(!this["~standard"].async)try{let r=this._parseSync({data:e,path:[],parent:t});return"valid"===r.status?{value:r.value}:{issues:t.common.issues}}catch(e){e?.message?.toLowerCase()?.includes("encountered")&&(this["~standard"].async=!0),t.common={issues:[],async:!0}}return this._parseAsync({data:e,path:[],parent:t}).then(e=>"valid"===e.status?{value:e.value}:{issues:t.common.issues})}async parseAsync(e,t){let r=await this.safeParseAsync(e,t);if(r.success)return r.data;throw r.error}async safeParseAsync(e,t){let r={common:{issues:[],contextualErrorMap:t?.errorMap,async:!0},path:t?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:(0,d.CR)(e)},a=this._parse({data:e,path:r.path,parent:r});return _(r,await (g(a)?a:Promise.resolve(a)))}refine(e,t){return this._refinement((r,a)=>{let s=e(r),i=()=>a.addIssue({code:l.eq.custom,..."string"==typeof t||void 0===t?{message:t}:"function"==typeof t?t(r):t});return"u">typeof Promise&&s instanceof Promise?s.then(e=>!!e||(i(),!1)):!!s||(i(),!1)})}refinement(e,t){return this._refinement((r,a)=>!!e(r)||(a.addIssue("function"==typeof t?t(r,a):t),!1))}_refinement(e){return new ef({schema:this,typeName:o.ZodEffects,effect:{type:"refinement",refinement:e}})}superRefine(e){return this._refinement(e)}constructor(e){this.spa=this.safeParseAsync,this._def=e,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:e=>this["~validate"](e)}}optional(){return em.create(this,this._def)}nullable(){return ey.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return Y.create(this)}promise(){return ep.create(this,this._def)}or(e){return X.create([this,e],this._def)}and(e){return er.create(this,e,this._def)}transform(e){return new ef({...$(this._def),schema:this,typeName:o.ZodEffects,effect:{type:"transform",transform:e}})}default(e){return new eg({...$(this._def),innerType:this,defaultValue:"function"==typeof e?e:()=>e,typeName:o.ZodDefault})}brand(){return new e$({typeName:o.ZodBranded,type:this,...$(this._def)})}catch(e){return new ev({...$(this._def),innerType:this,catchValue:"function"==typeof e?e:()=>e,typeName:o.ZodCatch})}describe(e){return new this.constructor({...this._def,description:e})}pipe(e){return eb.create(this,e)}readonly(){return ew.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}let w=/^c[^\s-]{8,}$/i,k=/^[0-9a-z]+$/,x=/^[0-9A-HJKMNP-TV-Z]{26}$/i,P=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,S=/^[a-z0-9_-]{21}$/i,E=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,j=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,N=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,O=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,T=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,C=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,R=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,I=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,A=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,Z="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",M=RegExp(`^${Z}$`);function q(e){let t="[0-5]\\d";e.precision?t=`${t}\\.\\d{${e.precision}}`:null==e.precision&&(t=`${t}(\\.\\d+)?`);let r=e.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${t})${r}`}class D extends b{_parse(e){var t,r,s,i;let n;if(this._def.coerce&&(e.data=String(e.data)),this._getType(e)!==d.Zp.string){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.string,received:t.parsedType}),f}let o=new p;for(let u of this._def.checks)if("min"===u.kind)e.data.length<u.value&&(h(n=this._getOrReturnCtx(e,n),{code:l.eq.too_small,minimum:u.value,type:"string",inclusive:!0,exact:!1,message:u.message}),o.dirty());else if("max"===u.kind)e.data.length>u.value&&(h(n=this._getOrReturnCtx(e,n),{code:l.eq.too_big,maximum:u.value,type:"string",inclusive:!0,exact:!1,message:u.message}),o.dirty());else if("length"===u.kind){let t=e.data.length>u.value,r=e.data.length<u.value;(t||r)&&(n=this._getOrReturnCtx(e,n),t?h(n,{code:l.eq.too_big,maximum:u.value,type:"string",inclusive:!0,exact:!0,message:u.message}):r&&h(n,{code:l.eq.too_small,minimum:u.value,type:"string",inclusive:!0,exact:!0,message:u.message}),o.dirty())}else if("email"===u.kind)N.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"email",code:l.eq.invalid_string,message:u.message}),o.dirty());else if("emoji"===u.kind)a||(a=RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u")),a.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"emoji",code:l.eq.invalid_string,message:u.message}),o.dirty());else if("uuid"===u.kind)P.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"uuid",code:l.eq.invalid_string,message:u.message}),o.dirty());else if("nanoid"===u.kind)S.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"nanoid",code:l.eq.invalid_string,message:u.message}),o.dirty());else if("cuid"===u.kind)w.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"cuid",code:l.eq.invalid_string,message:u.message}),o.dirty());else if("cuid2"===u.kind)k.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"cuid2",code:l.eq.invalid_string,message:u.message}),o.dirty());else if("ulid"===u.kind)x.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"ulid",code:l.eq.invalid_string,message:u.message}),o.dirty());else if("url"===u.kind)try{new URL(e.data)}catch{h(n=this._getOrReturnCtx(e,n),{validation:"url",code:l.eq.invalid_string,message:u.message}),o.dirty()}else"regex"===u.kind?(u.regex.lastIndex=0,u.regex.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"regex",code:l.eq.invalid_string,message:u.message}),o.dirty())):"trim"===u.kind?e.data=e.data.trim():"includes"===u.kind?e.data.includes(u.value,u.position)||(h(n=this._getOrReturnCtx(e,n),{code:l.eq.invalid_string,validation:{includes:u.value,position:u.position},message:u.message}),o.dirty()):"toLowerCase"===u.kind?e.data=e.data.toLowerCase():"toUpperCase"===u.kind?e.data=e.data.toUpperCase():"startsWith"===u.kind?e.data.startsWith(u.value)||(h(n=this._getOrReturnCtx(e,n),{code:l.eq.invalid_string,validation:{startsWith:u.value},message:u.message}),o.dirty()):"endsWith"===u.kind?e.data.endsWith(u.value)||(h(n=this._getOrReturnCtx(e,n),{code:l.eq.invalid_string,validation:{endsWith:u.value},message:u.message}),o.dirty()):"datetime"===u.kind?(function(e){let t=`${Z}T${q(e)}`,r=[];return r.push(e.local?"Z?":"Z"),e.offset&&r.push("([+-]\\d{2}:?\\d{2})"),t=`${t}(${r.join("|")})`,RegExp(`^${t}$`)})(u).test(e.data)||(h(n=this._getOrReturnCtx(e,n),{code:l.eq.invalid_string,validation:"datetime",message:u.message}),o.dirty()):"date"===u.kind?M.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{code:l.eq.invalid_string,validation:"date",message:u.message}),o.dirty()):"time"===u.kind?RegExp(`^${q(u)}$`).test(e.data)||(h(n=this._getOrReturnCtx(e,n),{code:l.eq.invalid_string,validation:"time",message:u.message}),o.dirty()):"duration"===u.kind?j.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"duration",code:l.eq.invalid_string,message:u.message}),o.dirty()):"ip"===u.kind?(t=e.data,!(("v4"===(r=u.version)||!r)&&O.test(t)||("v6"===r||!r)&&C.test(t))&&1&&(h(n=this._getOrReturnCtx(e,n),{validation:"ip",code:l.eq.invalid_string,message:u.message}),o.dirty())):"jwt"===u.kind?!function(e,t){if(!E.test(e))return!1;try{let[r]=e.split(".");if(!r)return!1;let a=r.replace(/-/g,"+").replace(/_/g,"/").padEnd(r.length+(4-r.length%4)%4,"="),s=JSON.parse(atob(a));if("object"!=typeof s||null===s||"typ"in s&&s?.typ!=="JWT"||!s.alg||t&&s.alg!==t)return!1;return!0}catch{return!1}}(e.data,u.alg)&&(h(n=this._getOrReturnCtx(e,n),{validation:"jwt",code:l.eq.invalid_string,message:u.message}),o.dirty()):"cidr"===u.kind?(s=e.data,!(("v4"===(i=u.version)||!i)&&T.test(s)||("v6"===i||!i)&&R.test(s))&&1&&(h(n=this._getOrReturnCtx(e,n),{validation:"cidr",code:l.eq.invalid_string,message:u.message}),o.dirty())):"base64"===u.kind?I.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"base64",code:l.eq.invalid_string,message:u.message}),o.dirty()):"base64url"===u.kind?A.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"base64url",code:l.eq.invalid_string,message:u.message}),o.dirty()):d.ZS.assertNever(u);return{status:o.value,value:e.data}}_regex(e,t,r){return this.refinement(t=>e.test(t),{validation:t,code:l.eq.invalid_string,...n.errToObj(r)})}_addCheck(e){return new D({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...n.errToObj(e)})}url(e){return this._addCheck({kind:"url",...n.errToObj(e)})}emoji(e){return this._addCheck({kind:"emoji",...n.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...n.errToObj(e)})}nanoid(e){return this._addCheck({kind:"nanoid",...n.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...n.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...n.errToObj(e)})}ulid(e){return this._addCheck({kind:"ulid",...n.errToObj(e)})}base64(e){return this._addCheck({kind:"base64",...n.errToObj(e)})}base64url(e){return this._addCheck({kind:"base64url",...n.errToObj(e)})}jwt(e){return this._addCheck({kind:"jwt",...n.errToObj(e)})}ip(e){return this._addCheck({kind:"ip",...n.errToObj(e)})}cidr(e){return this._addCheck({kind:"cidr",...n.errToObj(e)})}datetime(e){return"string"==typeof e?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:e}):this._addCheck({kind:"datetime",precision:void 0===e?.precision?null:e?.precision,offset:e?.offset??!1,local:e?.local??!1,...n.errToObj(e?.message)})}date(e){return this._addCheck({kind:"date",message:e})}time(e){return"string"==typeof e?this._addCheck({kind:"time",precision:null,message:e}):this._addCheck({kind:"time",precision:void 0===e?.precision?null:e?.precision,...n.errToObj(e?.message)})}duration(e){return this._addCheck({kind:"duration",...n.errToObj(e)})}regex(e,t){return this._addCheck({kind:"regex",regex:e,...n.errToObj(t)})}includes(e,t){return this._addCheck({kind:"includes",value:e,position:t?.position,...n.errToObj(t?.message)})}startsWith(e,t){return this._addCheck({kind:"startsWith",value:e,...n.errToObj(t)})}endsWith(e,t){return this._addCheck({kind:"endsWith",value:e,...n.errToObj(t)})}min(e,t){return this._addCheck({kind:"min",value:e,...n.errToObj(t)})}max(e,t){return this._addCheck({kind:"max",value:e,...n.errToObj(t)})}length(e,t){return this._addCheck({kind:"length",value:e,...n.errToObj(t)})}nonempty(e){return this.min(1,n.errToObj(e))}trim(){return new D({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new D({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new D({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(e=>"datetime"===e.kind)}get isDate(){return!!this._def.checks.find(e=>"date"===e.kind)}get isTime(){return!!this._def.checks.find(e=>"time"===e.kind)}get isDuration(){return!!this._def.checks.find(e=>"duration"===e.kind)}get isEmail(){return!!this._def.checks.find(e=>"email"===e.kind)}get isURL(){return!!this._def.checks.find(e=>"url"===e.kind)}get isEmoji(){return!!this._def.checks.find(e=>"emoji"===e.kind)}get isUUID(){return!!this._def.checks.find(e=>"uuid"===e.kind)}get isNANOID(){return!!this._def.checks.find(e=>"nanoid"===e.kind)}get isCUID(){return!!this._def.checks.find(e=>"cuid"===e.kind)}get isCUID2(){return!!this._def.checks.find(e=>"cuid2"===e.kind)}get isULID(){return!!this._def.checks.find(e=>"ulid"===e.kind)}get isIP(){return!!this._def.checks.find(e=>"ip"===e.kind)}get isCIDR(){return!!this._def.checks.find(e=>"cidr"===e.kind)}get isBase64(){return!!this._def.checks.find(e=>"base64"===e.kind)}get isBase64url(){return!!this._def.checks.find(e=>"base64url"===e.kind)}get minLength(){let e=null;for(let t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxLength(){let e=null;for(let t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}}D.create=e=>new D({checks:[],typeName:o.ZodString,coerce:e?.coerce??!1,...$(e)});class V extends b{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){let t;if(this._def.coerce&&(e.data=Number(e.data)),this._getType(e)!==d.Zp.number){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.number,received:t.parsedType}),f}let r=new p;for(let a of this._def.checks)"int"===a.kind?d.ZS.isInteger(e.data)||(h(t=this._getOrReturnCtx(e,t),{code:l.eq.invalid_type,expected:"integer",received:"float",message:a.message}),r.dirty()):"min"===a.kind?(a.inclusive?e.data<a.value:e.data<=a.value)&&(h(t=this._getOrReturnCtx(e,t),{code:l.eq.too_small,minimum:a.value,type:"number",inclusive:a.inclusive,exact:!1,message:a.message}),r.dirty()):"max"===a.kind?(a.inclusive?e.data>a.value:e.data>=a.value)&&(h(t=this._getOrReturnCtx(e,t),{code:l.eq.too_big,maximum:a.value,type:"number",inclusive:a.inclusive,exact:!1,message:a.message}),r.dirty()):"multipleOf"===a.kind?0!==function(e,t){let r=(e.toString().split(".")[1]||"").length,a=(t.toString().split(".")[1]||"").length,s=r>a?r:a;return Number.parseInt(e.toFixed(s).replace(".",""))%Number.parseInt(t.toFixed(s).replace(".",""))/10**s}(e.data,a.value)&&(h(t=this._getOrReturnCtx(e,t),{code:l.eq.not_multiple_of,multipleOf:a.value,message:a.message}),r.dirty()):"finite"===a.kind?Number.isFinite(e.data)||(h(t=this._getOrReturnCtx(e,t),{code:l.eq.not_finite,message:a.message}),r.dirty()):d.ZS.assertNever(a);return{status:r.value,value:e.data}}gte(e,t){return this.setLimit("min",e,!0,n.toString(t))}gt(e,t){return this.setLimit("min",e,!1,n.toString(t))}lte(e,t){return this.setLimit("max",e,!0,n.toString(t))}lt(e,t){return this.setLimit("max",e,!1,n.toString(t))}setLimit(e,t,r,a){return new V({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:r,message:n.toString(a)}]})}_addCheck(e){return new V({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:n.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:n.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:n.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:n.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:n.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:n.toString(t)})}finite(e){return this._addCheck({kind:"finite",message:n.toString(e)})}safe(e){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:n.toString(e)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:n.toString(e)})}get minValue(){let e=null;for(let t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(let t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}get isInt(){return!!this._def.checks.find(e=>"int"===e.kind||"multipleOf"===e.kind&&d.ZS.isInteger(e.value))}get isFinite(){let e=null,t=null;for(let r of this._def.checks)if("finite"===r.kind||"int"===r.kind||"multipleOf"===r.kind)return!0;else"min"===r.kind?(null===t||r.value>t)&&(t=r.value):"max"===r.kind&&(null===e||r.value<e)&&(e=r.value);return Number.isFinite(t)&&Number.isFinite(e)}}V.create=e=>new V({checks:[],typeName:o.ZodNumber,coerce:e?.coerce||!1,...$(e)});class z extends b{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(e){let t;if(this._def.coerce)try{e.data=BigInt(e.data)}catch{return this._getInvalidInput(e)}if(this._getType(e)!==d.Zp.bigint)return this._getInvalidInput(e);let r=new p;for(let a of this._def.checks)"min"===a.kind?(a.inclusive?e.data<a.value:e.data<=a.value)&&(h(t=this._getOrReturnCtx(e,t),{code:l.eq.too_small,type:"bigint",minimum:a.value,inclusive:a.inclusive,message:a.message}),r.dirty()):"max"===a.kind?(a.inclusive?e.data>a.value:e.data>=a.value)&&(h(t=this._getOrReturnCtx(e,t),{code:l.eq.too_big,type:"bigint",maximum:a.value,inclusive:a.inclusive,message:a.message}),r.dirty()):"multipleOf"===a.kind?e.data%a.value!==BigInt(0)&&(h(t=this._getOrReturnCtx(e,t),{code:l.eq.not_multiple_of,multipleOf:a.value,message:a.message}),r.dirty()):d.ZS.assertNever(a);return{status:r.value,value:e.data}}_getInvalidInput(e){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.bigint,received:t.parsedType}),f}gte(e,t){return this.setLimit("min",e,!0,n.toString(t))}gt(e,t){return this.setLimit("min",e,!1,n.toString(t))}lte(e,t){return this.setLimit("max",e,!0,n.toString(t))}lt(e,t){return this.setLimit("max",e,!1,n.toString(t))}setLimit(e,t,r,a){return new z({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:r,message:n.toString(a)}]})}_addCheck(e){return new z({...this._def,checks:[...this._def.checks,e]})}positive(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:n.toString(e)})}negative(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:n.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:n.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:n.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:n.toString(t)})}get minValue(){let e=null;for(let t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(let t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}}z.create=e=>new z({checks:[],typeName:o.ZodBigInt,coerce:e?.coerce??!1,...$(e)});class F extends b{_parse(e){if(this._def.coerce&&(e.data=!!e.data),this._getType(e)!==d.Zp.boolean){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.boolean,received:t.parsedType}),f}return y(e.data)}}F.create=e=>new F({typeName:o.ZodBoolean,coerce:e?.coerce||!1,...$(e)});class U extends b{_parse(e){let t;if(this._def.coerce&&(e.data=new Date(e.data)),this._getType(e)!==d.Zp.date){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.date,received:t.parsedType}),f}if(Number.isNaN(e.data.getTime()))return h(this._getOrReturnCtx(e),{code:l.eq.invalid_date}),f;let r=new p;for(let a of this._def.checks)"min"===a.kind?e.data.getTime()<a.value&&(h(t=this._getOrReturnCtx(e,t),{code:l.eq.too_small,message:a.message,inclusive:!0,exact:!1,minimum:a.value,type:"date"}),r.dirty()):"max"===a.kind?e.data.getTime()>a.value&&(h(t=this._getOrReturnCtx(e,t),{code:l.eq.too_big,message:a.message,inclusive:!0,exact:!1,maximum:a.value,type:"date"}),r.dirty()):d.ZS.assertNever(a);return{status:r.value,value:new Date(e.data.getTime())}}_addCheck(e){return new U({...this._def,checks:[...this._def.checks,e]})}min(e,t){return this._addCheck({kind:"min",value:e.getTime(),message:n.toString(t)})}max(e,t){return this._addCheck({kind:"max",value:e.getTime(),message:n.toString(t)})}get minDate(){let e=null;for(let t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return null!=e?new Date(e):null}get maxDate(){let e=null;for(let t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return null!=e?new Date(e):null}}U.create=e=>new U({checks:[],coerce:e?.coerce||!1,typeName:o.ZodDate,...$(e)});class L extends b{_parse(e){if(this._getType(e)!==d.Zp.symbol){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.symbol,received:t.parsedType}),f}return y(e.data)}}L.create=e=>new L({typeName:o.ZodSymbol,...$(e)});class K extends b{_parse(e){if(this._getType(e)!==d.Zp.undefined){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.undefined,received:t.parsedType}),f}return y(e.data)}}K.create=e=>new K({typeName:o.ZodUndefined,...$(e)});class G extends b{_parse(e){if(this._getType(e)!==d.Zp.null){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.null,received:t.parsedType}),f}return y(e.data)}}G.create=e=>new G({typeName:o.ZodNull,...$(e)});class B extends b{constructor(){super(...arguments),this._any=!0}_parse(e){return y(e.data)}}B.create=e=>new B({typeName:o.ZodAny,...$(e)});class J extends b{constructor(){super(...arguments),this._unknown=!0}_parse(e){return y(e.data)}}J.create=e=>new J({typeName:o.ZodUnknown,...$(e)});class W extends b{_parse(e){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.never,received:t.parsedType}),f}}W.create=e=>new W({typeName:o.ZodNever,...$(e)});class H extends b{_parse(e){if(this._getType(e)!==d.Zp.undefined){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.void,received:t.parsedType}),f}return y(e.data)}}H.create=e=>new H({typeName:o.ZodVoid,...$(e)});class Y extends b{_parse(e){let{ctx:t,status:r}=this._processInputParams(e),a=this._def;if(t.parsedType!==d.Zp.array)return h(t,{code:l.eq.invalid_type,expected:d.Zp.array,received:t.parsedType}),f;if(null!==a.exactLength){let e=t.data.length>a.exactLength.value,s=t.data.length<a.exactLength.value;(e||s)&&(h(t,{code:e?l.eq.too_big:l.eq.too_small,minimum:s?a.exactLength.value:void 0,maximum:e?a.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:a.exactLength.message}),r.dirty())}if(null!==a.minLength&&t.data.length<a.minLength.value&&(h(t,{code:l.eq.too_small,minimum:a.minLength.value,type:"array",inclusive:!0,exact:!1,message:a.minLength.message}),r.dirty()),null!==a.maxLength&&t.data.length>a.maxLength.value&&(h(t,{code:l.eq.too_big,maximum:a.maxLength.value,type:"array",inclusive:!0,exact:!1,message:a.maxLength.message}),r.dirty()),t.common.async)return Promise.all([...t.data].map((e,r)=>a.type._parseAsync(new v(t,e,t.path,r)))).then(e=>p.mergeArray(r,e));let s=[...t.data].map((e,r)=>a.type._parseSync(new v(t,e,t.path,r)));return p.mergeArray(r,s)}get element(){return this._def.type}min(e,t){return new Y({...this._def,minLength:{value:e,message:n.toString(t)}})}max(e,t){return new Y({...this._def,maxLength:{value:e,message:n.toString(t)}})}length(e,t){return new Y({...this._def,exactLength:{value:e,message:n.toString(t)}})}nonempty(e){return this.min(1,e)}}Y.create=(e,t)=>new Y({type:e,minLength:null,maxLength:null,exactLength:null,typeName:o.ZodArray,...$(t)});class Q extends b{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(null!==this._cached)return this._cached;let e=this._def.shape(),t=d.ZS.objectKeys(e);return this._cached={shape:e,keys:t},this._cached}_parse(e){if(this._getType(e)!==d.Zp.object){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.object,received:t.parsedType}),f}let{status:t,ctx:r}=this._processInputParams(e),{shape:a,keys:s}=this._getCached(),i=[];if(!(this._def.catchall instanceof W&&"strip"===this._def.unknownKeys))for(let e in r.data)s.includes(e)||i.push(e);let n=[];for(let e of s){let t=a[e],s=r.data[e];n.push({key:{status:"valid",value:e},value:t._parse(new v(r,s,r.path,e)),alwaysSet:e in r.data})}if(this._def.catchall instanceof W){let e=this._def.unknownKeys;if("passthrough"===e)for(let e of i)n.push({key:{status:"valid",value:e},value:{status:"valid",value:r.data[e]}});else if("strict"===e)i.length>0&&(h(r,{code:l.eq.unrecognized_keys,keys:i}),t.dirty());else if("strip"===e);else throw Error("Internal ZodObject error: invalid unknownKeys value.")}else{let e=this._def.catchall;for(let t of i){let a=r.data[t];n.push({key:{status:"valid",value:t},value:e._parse(new v(r,a,r.path,t)),alwaysSet:t in r.data})}}return r.common.async?Promise.resolve().then(async()=>{let e=[];for(let t of n){let r=await t.key,a=await t.value;e.push({key:r,value:a,alwaysSet:t.alwaysSet})}return e}).then(e=>p.mergeObjectSync(t,e)):p.mergeObjectSync(t,n)}get shape(){return this._def.shape()}strict(e){return n.errToObj,new Q({...this._def,unknownKeys:"strict",...void 0!==e?{errorMap:(t,r)=>{let a=this._def.errorMap?.(t,r).message??r.defaultError;return"unrecognized_keys"===t.code?{message:n.errToObj(e).message??a}:{message:a}}}:{}})}strip(){return new Q({...this._def,unknownKeys:"strip"})}passthrough(){return new Q({...this._def,unknownKeys:"passthrough"})}extend(e){return new Q({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new Q({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>({...this._def.shape(),...e._def.shape()}),typeName:o.ZodObject})}setKey(e,t){return this.augment({[e]:t})}catchall(e){return new Q({...this._def,catchall:e})}pick(e){let t={};for(let r of d.ZS.objectKeys(e))e[r]&&this.shape[r]&&(t[r]=this.shape[r]);return new Q({...this._def,shape:()=>t})}omit(e){let t={};for(let r of d.ZS.objectKeys(this.shape))e[r]||(t[r]=this.shape[r]);return new Q({...this._def,shape:()=>t})}deepPartial(){return function e(t){if(t instanceof Q){let r={};for(let a in t.shape){let s=t.shape[a];r[a]=em.create(e(s))}return new Q({...t._def,shape:()=>r})}if(t instanceof Y)return new Y({...t._def,type:e(t.element)});if(t instanceof em)return em.create(e(t.unwrap()));if(t instanceof ey)return ey.create(e(t.unwrap()));if(t instanceof ea)return ea.create(t.items.map(t=>e(t)));else return t}(this)}partial(e){let t={};for(let r of d.ZS.objectKeys(this.shape)){let a=this.shape[r];e&&!e[r]?t[r]=a:t[r]=a.optional()}return new Q({...this._def,shape:()=>t})}required(e){let t={};for(let r of d.ZS.objectKeys(this.shape))if(e&&!e[r])t[r]=this.shape[r];else{let e=this.shape[r];for(;e instanceof em;)e=e._def.innerType;t[r]=e}return new Q({...this._def,shape:()=>t})}keyof(){return eu(d.ZS.objectKeys(this.shape))}}Q.create=(e,t)=>new Q({shape:()=>e,unknownKeys:"strip",catchall:W.create(),typeName:o.ZodObject,...$(t)}),Q.strictCreate=(e,t)=>new Q({shape:()=>e,unknownKeys:"strict",catchall:W.create(),typeName:o.ZodObject,...$(t)}),Q.lazycreate=(e,t)=>new Q({shape:e,unknownKeys:"strip",catchall:W.create(),typeName:o.ZodObject,...$(t)});class X extends b{_parse(e){let{ctx:t}=this._processInputParams(e),r=this._def.options;if(t.common.async)return Promise.all(r.map(async e=>{let r={...t,common:{...t.common,issues:[]},parent:null};return{result:await e._parseAsync({data:t.data,path:t.path,parent:r}),ctx:r}})).then(function(e){for(let t of e)if("valid"===t.result.status)return t.result;for(let r of e)if("dirty"===r.result.status)return t.common.issues.push(...r.ctx.common.issues),r.result;let r=e.map(e=>new l.G(e.ctx.common.issues));return h(t,{code:l.eq.invalid_union,unionErrors:r}),f});{let e,a=[];for(let s of r){let r={...t,common:{...t.common,issues:[]},parent:null},i=s._parseSync({data:t.data,path:t.path,parent:r});if("valid"===i.status)return i;"dirty"!==i.status||e||(e={result:i,ctx:r}),r.common.issues.length&&a.push(r.common.issues)}if(e)return t.common.issues.push(...e.ctx.common.issues),e.result;let s=a.map(e=>new l.G(e));return h(t,{code:l.eq.invalid_union,unionErrors:s}),f}}get options(){return this._def.options}}X.create=(e,t)=>new X({options:e,typeName:o.ZodUnion,...$(t)});let ee=e=>{if(e instanceof el)return ee(e.schema);if(e instanceof ef)return ee(e.innerType());if(e instanceof ed)return[e.value];if(e instanceof ec)return e.options;if(e instanceof eh)return d.ZS.objectValues(e.enum);else if(e instanceof eg)return ee(e._def.innerType);else if(e instanceof K)return[void 0];else if(e instanceof G)return[null];else if(e instanceof em)return[void 0,...ee(e.unwrap())];else if(e instanceof ey)return[null,...ee(e.unwrap())];else if(e instanceof e$)return ee(e.unwrap());else if(e instanceof ew)return ee(e.unwrap());else if(e instanceof ev)return ee(e._def.innerType);else return[]};class et extends b{_parse(e){let{ctx:t}=this._processInputParams(e);if(t.parsedType!==d.Zp.object)return h(t,{code:l.eq.invalid_type,expected:d.Zp.object,received:t.parsedType}),f;let r=this.discriminator,a=t.data[r],s=this.optionsMap.get(a);return s?t.common.async?s._parseAsync({data:t.data,path:t.path,parent:t}):s._parseSync({data:t.data,path:t.path,parent:t}):(h(t,{code:l.eq.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[r]}),f)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(e,t,r){let a=new Map;for(let r of t){let t=ee(r.shape[e]);if(!t.length)throw Error(`A discriminator value for key \`${e}\` could not be extracted from all schema options`);for(let s of t){if(a.has(s))throw Error(`Discriminator property ${String(e)} has duplicate value ${String(s)}`);a.set(s,r)}}return new et({typeName:o.ZodDiscriminatedUnion,discriminator:e,options:t,optionsMap:a,...$(r)})}}class er extends b{_parse(e){let{status:t,ctx:r}=this._processInputParams(e),a=(e,a)=>{if("aborted"===e.status||"aborted"===a.status)return f;let s=function e(t,r){let a=(0,d.CR)(t),s=(0,d.CR)(r);if(t===r)return{valid:!0,data:t};if(a===d.Zp.object&&s===d.Zp.object){let a=d.ZS.objectKeys(r),s=d.ZS.objectKeys(t).filter(e=>-1!==a.indexOf(e)),i={...t,...r};for(let a of s){let s=e(t[a],r[a]);if(!s.valid)return{valid:!1};i[a]=s.data}return{valid:!0,data:i}}if(a===d.Zp.array&&s===d.Zp.array){if(t.length!==r.length)return{valid:!1};let a=[];for(let s=0;s<t.length;s++){let i=e(t[s],r[s]);if(!i.valid)return{valid:!1};a.push(i.data)}return{valid:!0,data:a}}if(a===d.Zp.date&&s===d.Zp.date&&+t==+r)return{valid:!0,data:t};return{valid:!1}}(e.value,a.value);return s.valid?(("dirty"===e.status||"dirty"===a.status)&&t.dirty(),{status:t.value,value:s.data}):(h(r,{code:l.eq.invalid_intersection_types}),f)};return r.common.async?Promise.all([this._def.left._parseAsync({data:r.data,path:r.path,parent:r}),this._def.right._parseAsync({data:r.data,path:r.path,parent:r})]).then(([e,t])=>a(e,t)):a(this._def.left._parseSync({data:r.data,path:r.path,parent:r}),this._def.right._parseSync({data:r.data,path:r.path,parent:r}))}}er.create=(e,t,r)=>new er({left:e,right:t,typeName:o.ZodIntersection,...$(r)});class ea extends b{_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.parsedType!==d.Zp.array)return h(r,{code:l.eq.invalid_type,expected:d.Zp.array,received:r.parsedType}),f;if(r.data.length<this._def.items.length)return h(r,{code:l.eq.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),f;!this._def.rest&&r.data.length>this._def.items.length&&(h(r,{code:l.eq.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),t.dirty());let a=[...r.data].map((e,t)=>{let a=this._def.items[t]||this._def.rest;return a?a._parse(new v(r,e,r.path,t)):null}).filter(e=>!!e);return r.common.async?Promise.all(a).then(e=>p.mergeArray(t,e)):p.mergeArray(t,a)}get items(){return this._def.items}rest(e){return new ea({...this._def,rest:e})}}ea.create=(e,t)=>{if(!Array.isArray(e))throw Error("You must pass an array of schemas to z.tuple([ ... ])");return new ea({items:e,typeName:o.ZodTuple,rest:null,...$(t)})};class es extends b{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.parsedType!==d.Zp.object)return h(r,{code:l.eq.invalid_type,expected:d.Zp.object,received:r.parsedType}),f;let a=[],s=this._def.keyType,i=this._def.valueType;for(let e in r.data)a.push({key:s._parse(new v(r,e,r.path,e)),value:i._parse(new v(r,r.data[e],r.path,e)),alwaysSet:e in r.data});return r.common.async?p.mergeObjectAsync(t,a):p.mergeObjectSync(t,a)}get element(){return this._def.valueType}static create(e,t,r){return new es(t instanceof b?{keyType:e,valueType:t,typeName:o.ZodRecord,...$(r)}:{keyType:D.create(),valueType:e,typeName:o.ZodRecord,...$(t)})}}class ei extends b{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.parsedType!==d.Zp.map)return h(r,{code:l.eq.invalid_type,expected:d.Zp.map,received:r.parsedType}),f;let a=this._def.keyType,s=this._def.valueType,i=[...r.data.entries()].map(([e,t],i)=>({key:a._parse(new v(r,e,r.path,[i,"key"])),value:s._parse(new v(r,t,r.path,[i,"value"]))}));if(r.common.async){let e=new Map;return Promise.resolve().then(async()=>{for(let r of i){let a=await r.key,s=await r.value;if("aborted"===a.status||"aborted"===s.status)return f;("dirty"===a.status||"dirty"===s.status)&&t.dirty(),e.set(a.value,s.value)}return{status:t.value,value:e}})}{let e=new Map;for(let r of i){let a=r.key,s=r.value;if("aborted"===a.status||"aborted"===s.status)return f;("dirty"===a.status||"dirty"===s.status)&&t.dirty(),e.set(a.value,s.value)}return{status:t.value,value:e}}}}ei.create=(e,t,r)=>new ei({valueType:t,keyType:e,typeName:o.ZodMap,...$(r)});class en extends b{_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.parsedType!==d.Zp.set)return h(r,{code:l.eq.invalid_type,expected:d.Zp.set,received:r.parsedType}),f;let a=this._def;null!==a.minSize&&r.data.size<a.minSize.value&&(h(r,{code:l.eq.too_small,minimum:a.minSize.value,type:"set",inclusive:!0,exact:!1,message:a.minSize.message}),t.dirty()),null!==a.maxSize&&r.data.size>a.maxSize.value&&(h(r,{code:l.eq.too_big,maximum:a.maxSize.value,type:"set",inclusive:!0,exact:!1,message:a.maxSize.message}),t.dirty());let s=this._def.valueType;function i(e){let r=new Set;for(let a of e){if("aborted"===a.status)return f;"dirty"===a.status&&t.dirty(),r.add(a.value)}return{status:t.value,value:r}}let n=[...r.data.values()].map((e,t)=>s._parse(new v(r,e,r.path,t)));return r.common.async?Promise.all(n).then(e=>i(e)):i(n)}min(e,t){return new en({...this._def,minSize:{value:e,message:n.toString(t)}})}max(e,t){return new en({...this._def,maxSize:{value:e,message:n.toString(t)}})}size(e,t){return this.min(e,t).max(e,t)}nonempty(e){return this.min(1,e)}}en.create=(e,t)=>new en({valueType:e,minSize:null,maxSize:null,typeName:o.ZodSet,...$(t)});class eo extends b{constructor(){super(...arguments),this.validate=this.implement}_parse(e){let{ctx:t}=this._processInputParams(e);if(t.parsedType!==d.Zp.function)return h(t,{code:l.eq.invalid_type,expected:d.Zp.function,received:t.parsedType}),f;function r(e,r){return c({data:e,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,u,u].filter(e=>!!e),issueData:{code:l.eq.invalid_arguments,argumentsError:r}})}function a(e,r){return c({data:e,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,u,u].filter(e=>!!e),issueData:{code:l.eq.invalid_return_type,returnTypeError:r}})}let s={errorMap:t.common.contextualErrorMap},i=t.data;if(this._def.returns instanceof ep){let e=this;return y(async function(...t){let n=new l.G([]),o=await e._def.args.parseAsync(t,s).catch(e=>{throw n.addIssue(r(t,e)),n}),d=await Reflect.apply(i,this,o);return await e._def.returns._def.type.parseAsync(d,s).catch(e=>{throw n.addIssue(a(d,e)),n})})}{let e=this;return y(function(...t){let n=e._def.args.safeParse(t,s);if(!n.success)throw new l.G([r(t,n.error)]);let o=Reflect.apply(i,this,n.data),d=e._def.returns.safeParse(o,s);if(!d.success)throw new l.G([a(o,d.error)]);return d.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...e){return new eo({...this._def,args:ea.create(e).rest(J.create())})}returns(e){return new eo({...this._def,returns:e})}implement(e){return this.parse(e)}strictImplement(e){return this.parse(e)}static create(e,t,r){return new eo({args:e||ea.create([]).rest(J.create()),returns:t||J.create(),typeName:o.ZodFunction,...$(r)})}}class el extends b{get schema(){return this._def.getter()}_parse(e){let{ctx:t}=this._processInputParams(e);return this._def.getter()._parse({data:t.data,path:t.path,parent:t})}}el.create=(e,t)=>new el({getter:e,typeName:o.ZodLazy,...$(t)});class ed extends b{_parse(e){if(e.data!==this._def.value){let t=this._getOrReturnCtx(e);return h(t,{received:t.data,code:l.eq.invalid_literal,expected:this._def.value}),f}return{status:"valid",value:e.data}}get value(){return this._def.value}}function eu(e,t){return new ec({values:e,typeName:o.ZodEnum,...$(t)})}ed.create=(e,t)=>new ed({value:e,typeName:o.ZodLiteral,...$(t)});class ec extends b{_parse(e){if("string"!=typeof e.data){let t=this._getOrReturnCtx(e),r=this._def.values;return h(t,{expected:d.ZS.joinValues(r),received:t.parsedType,code:l.eq.invalid_type}),f}if(this._cache||(this._cache=new Set(this._def.values)),!this._cache.has(e.data)){let t=this._getOrReturnCtx(e),r=this._def.values;return h(t,{received:t.data,code:l.eq.invalid_enum_value,options:r}),f}return y(e.data)}get options(){return this._def.values}get enum(){let e={};for(let t of this._def.values)e[t]=t;return e}get Values(){let e={};for(let t of this._def.values)e[t]=t;return e}get Enum(){let e={};for(let t of this._def.values)e[t]=t;return e}extract(e,t=this._def){return ec.create(e,{...this._def,...t})}exclude(e,t=this._def){return ec.create(this.options.filter(t=>!e.includes(t)),{...this._def,...t})}}ec.create=eu;class eh extends b{_parse(e){let t=d.ZS.getValidEnumValues(this._def.values),r=this._getOrReturnCtx(e);if(r.parsedType!==d.Zp.string&&r.parsedType!==d.Zp.number){let e=d.ZS.objectValues(t);return h(r,{expected:d.ZS.joinValues(e),received:r.parsedType,code:l.eq.invalid_type}),f}if(this._cache||(this._cache=new Set(d.ZS.getValidEnumValues(this._def.values))),!this._cache.has(e.data)){let e=d.ZS.objectValues(t);return h(r,{received:r.data,code:l.eq.invalid_enum_value,options:e}),f}return y(e.data)}get enum(){return this._def.values}}eh.create=(e,t)=>new eh({values:e,typeName:o.ZodNativeEnum,...$(t)});class ep extends b{unwrap(){return this._def.type}_parse(e){let{ctx:t}=this._processInputParams(e);return t.parsedType!==d.Zp.promise&&!1===t.common.async?(h(t,{code:l.eq.invalid_type,expected:d.Zp.promise,received:t.parsedType}),f):y((t.parsedType===d.Zp.promise?t.data:Promise.resolve(t.data)).then(e=>this._def.type.parseAsync(e,{path:t.path,errorMap:t.common.contextualErrorMap})))}}ep.create=(e,t)=>new ep({type:e,typeName:o.ZodPromise,...$(t)});class ef extends b{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===o.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){let{status:t,ctx:r}=this._processInputParams(e),a=this._def.effect||null,s={addIssue:e=>{h(r,e),e.fatal?t.abort():t.dirty()},get path(){return r.path}};if(s.addIssue=s.addIssue.bind(s),"preprocess"===a.type){let e=a.transform(r.data,s);if(r.common.async)return Promise.resolve(e).then(async e=>{if("aborted"===t.value)return f;let a=await this._def.schema._parseAsync({data:e,path:r.path,parent:r});return"aborted"===a.status?f:"dirty"===a.status||"dirty"===t.value?m(a.value):a});{if("aborted"===t.value)return f;let a=this._def.schema._parseSync({data:e,path:r.path,parent:r});return"aborted"===a.status?f:"dirty"===a.status||"dirty"===t.value?m(a.value):a}}if("refinement"===a.type){let e=e=>{let t=a.refinement(e,s);if(r.common.async)return Promise.resolve(t);if(t instanceof Promise)throw Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return e};if(!1!==r.common.async)return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(r=>"aborted"===r.status?f:("dirty"===r.status&&t.dirty(),e(r.value).then(()=>({status:t.value,value:r.value}))));{let a=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});return"aborted"===a.status?f:("dirty"===a.status&&t.dirty(),e(a.value),{status:t.value,value:a.value})}}if("transform"===a.type)if(!1!==r.common.async)return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(e=>"valid"!==e.status?f:Promise.resolve(a.transform(e.value,s)).then(e=>({status:t.value,value:e})));else{let e=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});if("valid"!==e.status)return f;let i=a.transform(e.value,s);if(i instanceof Promise)throw Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:t.value,value:i}}d.ZS.assertNever(a)}}ef.create=(e,t,r)=>new ef({schema:e,typeName:o.ZodEffects,effect:t,...$(r)}),ef.createWithPreprocess=(e,t,r)=>new ef({schema:t,effect:{type:"preprocess",transform:e},typeName:o.ZodEffects,...$(r)});class em extends b{_parse(e){return this._getType(e)===d.Zp.undefined?y(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}em.create=(e,t)=>new em({innerType:e,typeName:o.ZodOptional,...$(t)});class ey extends b{_parse(e){return this._getType(e)===d.Zp.null?y(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}ey.create=(e,t)=>new ey({innerType:e,typeName:o.ZodNullable,...$(t)});class eg extends b{_parse(e){let{ctx:t}=this._processInputParams(e),r=t.data;return t.parsedType===d.Zp.undefined&&(r=this._def.defaultValue()),this._def.innerType._parse({data:r,path:t.path,parent:t})}removeDefault(){return this._def.innerType}}eg.create=(e,t)=>new eg({innerType:e,typeName:o.ZodDefault,defaultValue:"function"==typeof t.default?t.default:()=>t.default,...$(t)});class ev extends b{_parse(e){let{ctx:t}=this._processInputParams(e),r={...t,common:{...t.common,issues:[]}},a=this._def.innerType._parse({data:r.data,path:r.path,parent:{...r}});return g(a)?a.then(e=>({status:"valid",value:"valid"===e.status?e.value:this._def.catchValue({get error(){return new l.G(r.common.issues)},input:r.data})})):{status:"valid",value:"valid"===a.status?a.value:this._def.catchValue({get error(){return new l.G(r.common.issues)},input:r.data})}}removeCatch(){return this._def.innerType}}ev.create=(e,t)=>new ev({innerType:e,typeName:o.ZodCatch,catchValue:"function"==typeof t.catch?t.catch:()=>t.catch,...$(t)});class e_ extends b{_parse(e){if(this._getType(e)!==d.Zp.nan){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.nan,received:t.parsedType}),f}return{status:"valid",value:e.data}}}e_.create=e=>new e_({typeName:o.ZodNaN,...$(e)}),Symbol("zod_brand");class e$ extends b{_parse(e){let{ctx:t}=this._processInputParams(e),r=t.data;return this._def.type._parse({data:r,path:t.path,parent:t})}unwrap(){return this._def.type}}class eb extends b{_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.common.async)return(async()=>{let e=await this._def.in._parseAsync({data:r.data,path:r.path,parent:r});return"aborted"===e.status?f:"dirty"===e.status?(t.dirty(),m(e.value)):this._def.out._parseAsync({data:e.value,path:r.path,parent:r})})();{let e=this._def.in._parseSync({data:r.data,path:r.path,parent:r});return"aborted"===e.status?f:"dirty"===e.status?(t.dirty(),{status:"dirty",value:e.value}):this._def.out._parseSync({data:e.value,path:r.path,parent:r})}}static create(e,t){return new eb({in:e,out:t,typeName:o.ZodPipeline})}}class ew extends b{_parse(e){let t=this._def.innerType._parse(e),r=e=>("valid"===e.status&&(e.value=Object.freeze(e.value)),e);return g(t)?t.then(e=>r(e)):r(t)}unwrap(){return this._def.innerType}}ew.create=(e,t)=>new ew({innerType:e,typeName:o.ZodReadonly,...$(t)}),Q.lazycreate,(i=o||(o={})).ZodString="ZodString",i.ZodNumber="ZodNumber",i.ZodNaN="ZodNaN",i.ZodBigInt="ZodBigInt",i.ZodBoolean="ZodBoolean",i.ZodDate="ZodDate",i.ZodSymbol="ZodSymbol",i.ZodUndefined="ZodUndefined",i.ZodNull="ZodNull",i.ZodAny="ZodAny",i.ZodUnknown="ZodUnknown",i.ZodNever="ZodNever",i.ZodVoid="ZodVoid",i.ZodArray="ZodArray",i.ZodObject="ZodObject",i.ZodUnion="ZodUnion",i.ZodDiscriminatedUnion="ZodDiscriminatedUnion",i.ZodIntersection="ZodIntersection",i.ZodTuple="ZodTuple",i.ZodRecord="ZodRecord",i.ZodMap="ZodMap",i.ZodSet="ZodSet",i.ZodFunction="ZodFunction",i.ZodLazy="ZodLazy",i.ZodLiteral="ZodLiteral",i.ZodEnum="ZodEnum",i.ZodEffects="ZodEffects",i.ZodNativeEnum="ZodNativeEnum",i.ZodOptional="ZodOptional",i.ZodNullable="ZodNullable",i.ZodDefault="ZodDefault",i.ZodCatch="ZodCatch",i.ZodPromise="ZodPromise",i.ZodBranded="ZodBranded",i.ZodPipeline="ZodPipeline",i.ZodReadonly="ZodReadonly";let ek=D.create;V.create,e_.create,z.create,F.create,U.create,L.create,K.create,G.create,B.create;let ex=J.create;W.create,H.create;let eP=Y.create,eS=Q.create,eE=Q.strictCreate;X.create,et.create,er.create;let ej=ea.create,eN=es.create;ei.create,en.create,eo.create,el.create;let eO=ed.create,eT=ec.create;eh.create,ep.create,ef.create,em.create,ey.create,ef.createWithPreprocess,eb.create},93770(e){e.exports=JSON.parse('{"$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":false}')},33928(e){e.exports=JSON.parse('{"$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":true,"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":true,"readOnly":{"type":"boolean","default":false},"examples":{"type":"array","items":true},"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":true},"maxItems":{"$ref":"#/definitions/nonNegativeInteger"},"minItems":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"uniqueItems":{"type":"boolean","default":false},"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":true,"enum":{"type":"array","items":true,"minItems":1,"uniqueItems":true},"type":{"anyOf":[{"$ref":"#/definitions/simpleTypes"},{"type":"array","items":{"$ref":"#/definitions/simpleTypes"},"minItems":1,"uniqueItems":true}]},"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":true}')}}]);
8
- //# sourceMappingURL=2055.fd3ccf91ac47.chunk.js.map
7
+ deps: ${r}}`};let n={keyword:"dependencies",type:"object",schemaType:"object",error:t.error,code(e){let[t,r]=function({schema:e}){let t={},r={};for(let a in e)"__proto__"!==a&&((Array.isArray(e[a])?t:r)[a]=e[a]);return[t,r]}(e);o(e,t),l(e,r)}};function o(e,t=e.schema){let{gen:r,data:s,it:n}=e;if(0===Object.keys(t).length)return;let l=r.let("missing");for(let o in t){let d=t[o];if(0===d.length)continue;let u=(0,i.propertyInData)(r,s,o,n.opts.ownProperties);e.setParams({property:o,depsCount:d.length,deps:d.join(", ")}),n.allErrors?r.if(u,()=>{for(let t of d)(0,i.checkReportMissingProp)(e,t)}):(r.if((0,a._)`${u} && (${(0,i.checkMissingProp)(e,d,l)})`),(0,i.reportMissingProp)(e,l),r.else())}}function l(e,t=e.schema){let{gen:r,data:a,keyword:n,it:o}=e,d=r.name("valid");for(let l in t)(0,s.alwaysValidSchema)(o,t[l])||(r.if((0,i.propertyInData)(r,a,l,o.opts.ownProperties),()=>{let t=e.subschema({keyword:n,schemaProp:l},d);e.mergeValidEvaluated(t,d)},()=>r.var(d,!0)),e.ok(d))}t.validatePropertyDeps=o,t.validateSchemaDeps=l,t.default=n},70510(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=r(50458);function i(e,t){let r=e.schema[t];return void 0!==r&&!(0,s.alwaysValidSchema)(e,r)}t.default={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:{message:({params:e})=>(0,a.str)`must match "${e.ifClause}" schema`,params:({params:e})=>(0,a._)`{failingKeyword: ${e.ifClause}}`},code(e){let t,{gen:r,parentSchema:n,it:o}=e;void 0===n.then&&void 0===n.else&&(0,s.checkStrictMode)(o,'"if" without "then" and "else" is ignored');let l=i(o,"then"),d=i(o,"else");if(!l&&!d)return;let u=r.let("valid",!0),c=r.name("_valid");if(t=e.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},c),e.mergeEvaluated(t),e.reset(),l&&d){let t=r.let("ifClause");e.setParams({ifClause:t}),r.if(c,h("then",t),h("else",t))}else l?r.if(c,h("then")):r.if((0,a.not)(c),h("else"));function h(t,s){return()=>{let i=e.subschema({keyword:t},c);r.assign(u,c),e.mergeValidEvaluated(i,u),s?r.assign(s,(0,a._)`${t}`):e.setParams({ifClause:t})}}e.pass(u,()=>e.error(!0))}}},18225(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(93426),s=r(61349),i=r(44153),n=r(19753),o=r(35724),l=r(99868),d=r(67486),u=r(92697),c=r(19660),h=r(98422),f=r(65532),p=r(19430),m=r(98768),y=r(79355),g=r(70510),v=r(45255);t.default=function(e=!1){let t=[f.default,p.default,m.default,y.default,g.default,v.default,d.default,u.default,l.default,c.default,h.default];return e?t.push(s.default,n.default):t.push(a.default,i.default),t.push(o.default),t}},44153(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateTuple=void 0;let a=r(17898),s=r(50458),i=r(94450);function n(e,t,r=e.schema){let{gen:i,parentSchema:o,data:l,keyword:d,it:u}=e;(function(e){let{opts:a,errSchemaPath:i}=u,n=r.length,o=n===e.minItems&&(n===e.maxItems||!1===e[t]);if(a.strictTuples&&!o){let e=`"${d}" is ${n}-tuple, but minItems or maxItems/${t} are not specified or different at path "${i}"`;(0,s.checkStrictMode)(u,e,a.strictTuples)}})(o),u.opts.unevaluated&&r.length&&!0!==u.items&&(u.items=s.mergeEvaluated.items(i,r.length,u.items));let c=i.name("valid"),h=i.const("len",(0,a._)`${l}.length`);r.forEach((t,r)=>{(0,s.alwaysValidSchema)(u,t)||(i.if((0,a._)`${h} > ${r}`,()=>e.subschema({keyword:d,schemaProp:r,dataProp:r},c)),e.ok(c))})}t.validateTuple=n,t.default={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){let{schema:t,it:r}=e;if(Array.isArray(t))return n(e,"additionalItems",t);r.items=!0,(0,s.alwaysValidSchema)(r,t)||e.ok((0,i.validateArray)(e))}}},19753(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=r(50458),i=r(94450),n=r(93426);t.default={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:{message:({params:{len:e}})=>(0,a.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,a._)`{limit: ${e}}`},code(e){let{schema:t,parentSchema:r,it:a}=e,{prefixItems:o}=r;a.items=!0,(0,s.alwaysValidSchema)(a,t)||(o?(0,n.validateAdditionalItems)(e,o):e.ok((0,i.validateArray)(e)))}}},65532(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(50458);t.default={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){let{gen:t,schema:r,it:s}=e;if((0,a.alwaysValidSchema)(s,r))return void e.fail();let i=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},i),e.failResult(i,()=>e.reset(),()=>e.error())},error:{message:"must NOT be valid"}}},98768(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=r(50458);t.default={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:{message:"must match exactly one schema in oneOf",params:({params:e})=>(0,a._)`{passingSchemas: ${e.passing}}`},code(e){let{gen:t,schema:r,parentSchema:i,it:n}=e;if(!Array.isArray(r))throw Error("ajv implementation error");if(n.opts.discriminator&&i.discriminator)return;let o=t.let("valid",!1),l=t.let("passing",null),d=t.name("_valid");e.setParams({passing:l}),t.block(function(){r.forEach((r,i)=>{let u;(0,s.alwaysValidSchema)(n,r)?t.var(d,!0):u=e.subschema({keyword:"oneOf",schemaProp:i,compositeRule:!0},d),i>0&&t.if((0,a._)`${d} && ${o}`).assign(o,!1).assign(l,(0,a._)`[${l}, ${i}]`).else(),t.if(d,()=>{t.assign(o,!0),t.assign(l,i),u&&e.mergeEvaluated(u,a.Name)})})}),e.result(o,()=>e.reset(),()=>e.error(!0))}}},98422(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(94450),s=r(17898),i=r(50458),n=r(50458);t.default={keyword:"patternProperties",type:"object",schemaType:"object",code(e){let{gen:t,schema:r,data:o,parentSchema:l,it:d}=e,{opts:u}=d,c=(0,a.allSchemaProperties)(r),h=c.filter(e=>(0,i.alwaysValidSchema)(d,r[e]));if(0===c.length||h.length===c.length&&(!d.opts.unevaluated||!0===d.props))return;let f=u.strictSchema&&!u.allowMatchingProperties&&l.properties,p=t.name("valid");!0===d.props||d.props instanceof s.Name||(d.props=(0,n.evaluatedPropsToName)(t,d.props));let{props:m}=d;for(let e of c)f&&function(e){for(let t in f)new RegExp(e).test(t)&&(0,i.checkStrictMode)(d,`property ${t} matches pattern ${e} (use allowMatchingProperties)`)}(e),d.allErrors?y(e):(t.var(p,!0),y(e),t.if(p));function y(r){t.forIn("key",o,i=>{t.if((0,s._)`${(0,a.usePattern)(e,r)}.test(${i})`,()=>{let a=h.includes(r);a||e.subschema({keyword:"patternProperties",schemaProp:r,dataProp:i,dataPropType:n.Type.Str},p),d.opts.unevaluated&&!0!==m?t.assign((0,s._)`${m}[${i}]`,!0):a||d.allErrors||t.if((0,s.not)(p),()=>t.break())})})}}}},61349(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(44153);t.default={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:e=>(0,a.validateTuple)(e,"items")}},19660(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(96223),s=r(94450),i=r(50458),n=r(92697);t.default={keyword:"properties",type:"object",schemaType:"object",code(e){let{gen:t,schema:r,parentSchema:o,data:l,it:d}=e;"all"===d.opts.removeAdditional&&void 0===o.additionalProperties&&n.default.code(new a.KeywordCxt(d,n.default,"additionalProperties"));let u=(0,s.allSchemaProperties)(r);for(let e of u)d.definedProperties.add(e);d.opts.unevaluated&&u.length&&!0!==d.props&&(d.props=i.mergeEvaluated.props(t,(0,i.toHash)(u),d.props));let c=u.filter(e=>!(0,i.alwaysValidSchema)(d,r[e]));if(0===c.length)return;let h=t.name("valid");for(let a of c){var f;(f=a,d.opts.useDefaults&&!d.compositeRule&&void 0!==r[f].default)?p(a):(t.if((0,s.propertyInData)(t,l,a,d.opts.ownProperties)),p(a),d.allErrors||t.else().var(h,!0),t.endIf()),e.it.definedProperties.add(a),e.ok(h)}function p(t){e.subschema({keyword:"properties",schemaProp:t,dataProp:t},h)}}}},67486(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=r(50458);t.default={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:{message:"property name must be valid",params:({params:e})=>(0,a._)`{propertyName: ${e.propertyName}}`},code(e){let{gen:t,schema:r,data:i,it:n}=e;if((0,s.alwaysValidSchema)(n,r))return;let o=t.name("valid");t.forIn("key",i,r=>{e.setParams({propertyName:r}),e.subschema({keyword:"propertyNames",data:r,dataTypes:["string"],propertyName:r,compositeRule:!0},o),t.if((0,a.not)(o),()=>{e.error(!0),n.allErrors||t.break()})}),e.ok(o)}}},45255(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(50458);t.default={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:r}){void 0===t.if&&(0,a.checkStrictMode)(r,`"${e}" without "if" is ignored`)}}},94450(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateUnion=t.validateArray=t.usePattern=t.callValidateCode=t.schemaProperties=t.allSchemaProperties=t.noPropertyInData=t.propertyInData=t.isOwnProperty=t.hasPropFunc=t.reportMissingProp=t.checkMissingProp=t.checkReportMissingProp=void 0;let a=r(17898),s=r(50458),i=r(63036),n=r(50458);function o(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,a._)`Object.prototype.hasOwnProperty`})}function l(e,t,r){return(0,a._)`${o(e)}.call(${t}, ${r})`}function d(e,t,r,s){let i=(0,a._)`${t}${(0,a.getProperty)(r)} === undefined`;return s?(0,a.or)(i,(0,a.not)(l(e,t,r))):i}function u(e){return e?Object.keys(e).filter(e=>"__proto__"!==e):[]}t.checkReportMissingProp=function(e,t){let{gen:r,data:s,it:i}=e;r.if(d(r,s,t,i.opts.ownProperties),()=>{e.setParams({missingProperty:(0,a._)`${t}`},!0),e.error()})},t.checkMissingProp=function({gen:e,data:t,it:{opts:r}},s,i){return(0,a.or)(...s.map(s=>(0,a.and)(d(e,t,s,r.ownProperties),(0,a._)`${i} = ${s}`)))},t.reportMissingProp=function(e,t){e.setParams({missingProperty:t},!0),e.error()},t.hasPropFunc=o,t.isOwnProperty=l,t.propertyInData=function(e,t,r,s){let i=(0,a._)`${t}${(0,a.getProperty)(r)} !== undefined`;return s?(0,a._)`${i} && ${l(e,t,r)}`:i},t.noPropertyInData=d,t.allSchemaProperties=u,t.schemaProperties=function(e,t){return u(t).filter(r=>!(0,s.alwaysValidSchema)(e,t[r]))},t.callValidateCode=function({schemaCode:e,data:t,it:{gen:r,topSchemaRef:s,schemaPath:n,errorPath:o},it:l},d,u,c){let h=c?(0,a._)`${e}, ${t}, ${s}${n}`:t,f=[[i.default.instancePath,(0,a.strConcat)(i.default.instancePath,o)],[i.default.parentData,l.parentData],[i.default.parentDataProperty,l.parentDataProperty],[i.default.rootData,i.default.rootData]];l.opts.dynamicRef&&f.push([i.default.dynamicAnchors,i.default.dynamicAnchors]);let p=(0,a._)`${h}, ${r.object(...f)}`;return u!==a.nil?(0,a._)`${d}.call(${u}, ${p})`:(0,a._)`${d}(${p})`};let c=(0,a._)`new RegExp`;t.usePattern=function({gen:e,it:{opts:t}},r){let s=t.unicodeRegExp?"u":"",{regExp:i}=t.code,o=i(r,s);return e.scopeValue("pattern",{key:o.toString(),ref:o,code:(0,a._)`${"new RegExp"===i.code?c:(0,n.useFunc)(e,i)}(${r}, ${s})`})},t.validateArray=function(e){let{gen:t,data:r,keyword:i,it:n}=e,o=t.name("valid");if(n.allErrors){let e=t.let("valid",!0);return l(()=>t.assign(e,!1)),e}return t.var(o,!0),l(()=>t.break()),o;function l(n){let l=t.const("len",(0,a._)`${r}.length`);t.forRange("i",0,l,r=>{e.subschema({keyword:i,dataProp:r,dataPropType:s.Type.Num},o),t.if((0,a.not)(o),n)})}},t.validateUnion=function(e){let{gen:t,schema:r,keyword:i,it:n}=e;if(!Array.isArray(r))throw Error("ajv implementation error");if(r.some(e=>(0,s.alwaysValidSchema)(n,e))&&!n.opts.unevaluated)return;let o=t.let("valid",!1),l=t.name("_valid");t.block(()=>r.forEach((r,s)=>{let n=e.subschema({keyword:i,schemaProp:s,compositeRule:!0},l);t.assign(o,(0,a._)`${o} || ${l}`),e.mergeValidEvaluated(n,l)||t.if((0,a.not)(o))})),e.result(o,()=>e.reset(),()=>e.error(!0))}},73946(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default={keyword:"id",code(){throw Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}}},3839(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(73946),s=r(26138);t.default=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",a.default,s.default]},26138(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.callRef=t.getValidate=void 0;let a=r(85748),s=r(94450),i=r(17898),n=r(63036),o=r(49392),l=r(50458);function d(e,t){let{gen:r}=e;return t.validate?r.scopeValue("validate",{ref:t.validate}):(0,i._)`${r.scopeValue("wrapper",{ref:t})}.validate`}function u(e,t,r,a){let{gen:o,it:d}=e,{allErrors:u,schemaEnv:c,opts:h}=d,f=h.passContext?n.default.this:i.nil;function p(e){let t=(0,i._)`${e}.errors`;o.assign(n.default.vErrors,(0,i._)`${n.default.vErrors} === null ? ${t} : ${n.default.vErrors}.concat(${t})`),o.assign(n.default.errors,(0,i._)`${n.default.vErrors}.length`)}function m(e){var t;if(!d.opts.unevaluated)return;let a=null==(t=null==r?void 0:r.validate)?void 0:t.evaluated;if(!0!==d.props)if(a&&!a.dynamicProps)void 0!==a.props&&(d.props=l.mergeEvaluated.props(o,a.props,d.props));else{let t=o.var("props",(0,i._)`${e}.evaluated.props`);d.props=l.mergeEvaluated.props(o,t,d.props,i.Name)}if(!0!==d.items)if(a&&!a.dynamicItems)void 0!==a.items&&(d.items=l.mergeEvaluated.items(o,a.items,d.items));else{let t=o.var("items",(0,i._)`${e}.evaluated.items`);d.items=l.mergeEvaluated.items(o,t,d.items,i.Name)}}a?function(){if(!c.$async)throw Error("async schema referenced by sync schema");let r=o.let("valid");o.try(()=>{o.code((0,i._)`await ${(0,s.callValidateCode)(e,t,f)}`),m(t),u||o.assign(r,!0)},e=>{o.if((0,i._)`!(${e} instanceof ${d.ValidationError})`,()=>o.throw(e)),p(e),u||o.assign(r,!1)}),e.ok(r)}():e.result((0,s.callValidateCode)(e,t,f),()=>m(t),()=>p(t))}t.getValidate=d,t.callRef=u,t.default={keyword:"$ref",schemaType:"string",code(e){var t,r;let s,n,l,c,{gen:h,schema:f,it:p}=e,{baseId:m,schemaEnv:y,validateName:g,opts:v,self:_}=p,{root:$}=y;if(("#"===f||"#/"===f)&&m===$.baseId){if(y===$)return u(e,g,y,y.$async);let t=h.scopeValue("root",{ref:$});return u(e,(0,i._)`${t}.validate`,$,$.$async)}let b=o.resolveRef.call(_,$,m,f);if(void 0===b)throw new a.default(p.opts.uriResolver,m,f);return b instanceof o.SchemaEnv?(s=d(e,t=b),void u(e,s,t,t.$async)):(r=b,n=h.scopeValue("schema",!0===v.code.source?{ref:r,code:(0,i.stringify)(r)}:{ref:r}),l=h.name("valid"),c=e.subschema({schema:r,dataTypes:[],schemaPath:i.nil,topSchemaRef:n,errSchemaPath:f},l),void(e.mergeEvaluated(c),e.ok(l)))}}},11672(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=r(88925),i=r(49392),n=r(85748),o=r(50458);t.default={keyword:"discriminator",type:"object",schemaType:"object",error:{message:({params:{discrError:e,tagName:t}})=>e===s.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:r}})=>(0,a._)`{error: ${e}, tag: ${r}, tagValue: ${t}}`},code(e){let{gen:t,data:r,schema:l,parentSchema:d,it:u}=e,{oneOf:c}=d;if(!u.opts.discriminator)throw Error("discriminator: requires discriminator option");let h=l.propertyName;if("string"!=typeof h)throw Error("discriminator: requires propertyName");if(l.mapping)throw Error("discriminator: mapping is not supported");if(!c)throw Error("discriminator: requires oneOf keyword");let f=t.let("valid",!1),p=t.const("tag",(0,a._)`${r}${(0,a.getProperty)(h)}`);t.if((0,a._)`typeof ${p} == "string"`,()=>(function(){let r=function(){var e;let t={},r=s(d),a=!0;for(let t=0;t<c.length;t++){let d=c[t];if((null==d?void 0:d.$ref)&&!(0,o.schemaHasRulesButRef)(d,u.self.RULES)){let e=d.$ref;if((d=i.resolveRef.call(u.self,u.schemaEnv.root,u.baseId,e))instanceof i.SchemaEnv&&(d=d.schema),void 0===d)throw new n.default(u.opts.uriResolver,u.baseId,e)}let f=null==(e=null==d?void 0:d.properties)?void 0:e[h];if("object"!=typeof f)throw Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${h}"`);a=a&&(r||s(d)),function(e,t){if(e.const)l(e.const,t);else if(e.enum)for(let r of e.enum)l(r,t);else throw Error(`discriminator: "properties/${h}" must have "const" or "enum"`)}(f,t)}if(!a)throw Error(`discriminator: "${h}" must be required`);return t;function s({required:e}){return Array.isArray(e)&&e.includes(h)}function l(e,r){if("string"!=typeof e||e in t)throw Error(`discriminator: "${h}" values must be unique strings`);t[e]=r}}();for(let s in t.if(!1),r)t.elseIf((0,a._)`${p} === ${s}`),t.assign(f,function(r){let s=t.name("valid"),i=e.subschema({keyword:"oneOf",schemaProp:r},s);return e.mergeEvaluated(i,a.Name),s}(r[s]));t.else(),e.error(!1,{discrError:s.DiscrError.Mapping,tag:p,tagName:h}),t.endIf()})(),()=>e.error(!1,{discrError:s.DiscrError.Tag,tag:p,tagName:h})),e.ok(f)}}},88925(e,t){var r,a;Object.defineProperty(t,"__esModule",{value:!0}),t.DiscrError=void 0,(a=r||(t.DiscrError=r={})).Tag="tag",a.Mapping="mapping"},2431(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(3839),s=r(17851),i=r(18225),n=r(26699),o=r(34882);t.default=[a.default,s.default,(0,i.default)(),n.default,o.metadataVocabulary,o.contentVocabulary]},37072(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898);t.default={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:{message:({schemaCode:e})=>(0,a.str)`must match format "${e}"`,params:({schemaCode:e})=>(0,a._)`{format: ${e}}`},code(e,t){let r,s,i,n,o,l,{gen:d,data:u,$data:c,schema:h,schemaCode:f,it:p}=e,{opts:m,errSchemaPath:y,schemaEnv:g,self:v}=p;m.validateFormats&&(c?(r=d.scopeValue("formats",{ref:v.formats,code:m.code.formats}),s=d.const("fDef",(0,a._)`${r}[${f}]`),i=d.let("fType"),n=d.let("format"),d.if((0,a._)`typeof ${s} == "object" && !(${s} instanceof RegExp)`,()=>d.assign(i,(0,a._)`${s}.type || "string"`).assign(n,(0,a._)`${s}.validate`),()=>d.assign(i,(0,a._)`"string"`).assign(n,s)),e.fail$data((0,a.or)(!1===m.strictSchema?a.nil:(0,a._)`${f} && !${n}`,(o=g.$async?(0,a._)`(${s}.async ? await ${n}(${u}) : ${n}(${u}))`:(0,a._)`${n}(${u})`,l=(0,a._)`(typeof ${n} == "function" ? ${o} : ${n}.test(${u}))`,(0,a._)`${n} && ${n} !== true && ${i} === ${t} && !${l}`)))):function(){var r;let s,i,n=v.formats[h];if(!n){if(!1===m.strictSchema)return v.logger.warn(o());throw Error(o());function o(){return`unknown format "${h}" ignored in schema at path "${y}"`}}if(!0===n)return;let[l,c,f]=(s=(r=n)instanceof RegExp?(0,a.regexpCode)(r):m.code.formats?(0,a._)`${m.code.formats}${(0,a.getProperty)(h)}`:void 0,i=d.scopeValue("formats",{key:h,ref:r,code:s}),"object"!=typeof r||r instanceof RegExp?["string",r,i]:[r.type||"string",r.validate,(0,a._)`${i}.validate`]);l===t&&e.pass(function(){if("object"==typeof n&&!(n instanceof RegExp)&&n.async){if(!g.$async)throw Error("async format in sync schema");return(0,a._)`await ${f}(${u})`}return"function"==typeof c?(0,a._)`${f}(${u})`:(0,a._)`${f}.test(${u})`}())}())}}},26699(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.default=[r(37072).default]},34882(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.contentVocabulary=t.metadataVocabulary=void 0,t.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"],t.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]},79520(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=r(50458),i=r(72725);t.default={keyword:"const",$data:!0,error:{message:"must be equal to constant",params:({schemaCode:e})=>(0,a._)`{allowedValue: ${e}}`},code(e){let{gen:t,data:r,$data:n,schemaCode:o,schema:l}=e;n||l&&"object"==typeof l?e.fail$data((0,a._)`!${(0,s.useFunc)(t,i.default)}(${r}, ${o})`):e.fail((0,a._)`${l} !== ${r}`)}}},36742(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=r(50458),i=r(72725);t.default={keyword:"enum",schemaType:"array",$data:!0,error:{message:"must be equal to one of the allowed values",params:({schemaCode:e})=>(0,a._)`{allowedValues: ${e}}`},code(e){let t,r,{gen:n,data:o,$data:l,schema:d,schemaCode:u,it:c}=e;if(!l&&0===d.length)throw Error("enum must have non-empty array");let h=d.length>=c.opts.loopEnum,f=()=>null!=t?t:t=(0,s.useFunc)(n,i.default);if(h||l)r=n.let("valid"),e.block$data(r,function(){n.assign(r,!1),n.forOf("v",u,e=>n.if((0,a._)`${f()}(${o}, ${e})`,()=>n.assign(r,!0).break()))});else{if(!Array.isArray(d))throw Error("ajv implementation error");let e=n.const("vSchema",u);r=(0,a.or)(...d.map((t,r)=>{var s,i;let n;return s=e,"object"==typeof(n=d[i=r])&&null!==n?(0,a._)`${f()}(${o}, ${s}[${i}])`:(0,a._)`${o} === ${n}`}))}e.pass(r)}}},17851(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(72333),s=r(21230),i=r(3936),n=r(81005),o=r(71589),l=r(29594),d=r(38558),u=r(44058),c=r(79520),h=r(36742);t.default=[a.default,s.default,i.default,n.default,o.default,l.default,d.default,u.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},c.default,h.default]},38558(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898);t.default={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:{message:({keyword:e,schemaCode:t})=>(0,a.str)`must NOT have ${"maxItems"===e?"more":"fewer"} than ${t} items`,params:({schemaCode:e})=>(0,a._)`{limit: ${e}}`},code(e){let{keyword:t,data:r,schemaCode:s}=e,i="maxItems"===t?a.operators.GT:a.operators.LT;e.fail$data((0,a._)`${r}.length ${i} ${s}`)}}},3936(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=r(50458),i=r(26308);t.default={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:{message:({keyword:e,schemaCode:t})=>(0,a.str)`must NOT have ${"maxLength"===e?"more":"fewer"} than ${t} characters`,params:({schemaCode:e})=>(0,a._)`{limit: ${e}}`},code(e){let{keyword:t,data:r,schemaCode:n,it:o}=e,l="maxLength"===t?a.operators.GT:a.operators.LT,d=!1===o.opts.unicode?(0,a._)`${r}.length`:(0,a._)`${(0,s.useFunc)(e.gen,i.default)}(${r})`;e.fail$data((0,a._)`${d} ${l} ${n}`)}}},72333(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898),s=a.operators,i={maximum:{okStr:"<=",ok:s.LTE,fail:s.GT},minimum:{okStr:">=",ok:s.GTE,fail:s.LT},exclusiveMaximum:{okStr:"<",ok:s.LT,fail:s.GTE},exclusiveMinimum:{okStr:">",ok:s.GT,fail:s.LTE}};t.default={keyword:Object.keys(i),type:"number",schemaType:"number",$data:!0,error:{message:({keyword:e,schemaCode:t})=>(0,a.str)`must be ${i[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>(0,a._)`{comparison: ${i[e].okStr}, limit: ${t}}`},code(e){let{keyword:t,data:r,schemaCode:s}=e;e.fail$data((0,a._)`${r} ${i[t].fail} ${s} || isNaN(${r})`)}}},71589(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898);t.default={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:{message:({keyword:e,schemaCode:t})=>(0,a.str)`must NOT have ${"maxProperties"===e?"more":"fewer"} than ${t} properties`,params:({schemaCode:e})=>(0,a._)`{limit: ${e}}`},code(e){let{keyword:t,data:r,schemaCode:s}=e,i="maxProperties"===t?a.operators.GT:a.operators.LT;e.fail$data((0,a._)`Object.keys(${r}).length ${i} ${s}`)}}},21230(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(17898);t.default={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:{message:({schemaCode:e})=>(0,a.str)`must be multiple of ${e}`,params:({schemaCode:e})=>(0,a._)`{multipleOf: ${e}}`},code(e){let{gen:t,data:r,schemaCode:s,it:i}=e,n=i.opts.multipleOfPrecision,o=t.let("res"),l=n?(0,a._)`Math.abs(Math.round(${o}) - ${o}) > 1e-${n}`:(0,a._)`${o} !== parseInt(${o})`;e.fail$data((0,a._)`(${s} === 0 || (${o} = ${r}/${s}, ${l}))`)}}},81005(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(94450),s=r(50458),i=r(17898);t.default={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:{message:({schemaCode:e})=>(0,i.str)`must match pattern "${e}"`,params:({schemaCode:e})=>(0,i._)`{pattern: ${e}}`},code(e){let{gen:t,data:r,$data:n,schema:o,schemaCode:l,it:d}=e,u=d.opts.unicodeRegExp?"u":"";if(n){let{regExp:a}=d.opts.code,n="new RegExp"===a.code?(0,i._)`new RegExp`:(0,s.useFunc)(t,a),o=t.let("valid");t.try(()=>t.assign(o,(0,i._)`${n}(${l}, ${u}).test(${r})`),()=>t.assign(o,!1)),e.fail$data((0,i._)`!${o}`)}else{let t=(0,a.usePattern)(e,o);e.fail$data((0,i._)`!${t}.test(${r})`)}}}},29594(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(94450),s=r(17898),i=r(50458);t.default={keyword:"required",type:"object",schemaType:"array",$data:!0,error:{message:({params:{missingProperty:e}})=>(0,s.str)`must have required property '${e}'`,params:({params:{missingProperty:e}})=>(0,s._)`{missingProperty: ${e}}`},code(e){let{gen:t,schema:r,schemaCode:n,data:o,$data:l,it:d}=e,{opts:u}=d;if(!l&&0===r.length)return;let c=r.length>=u.loopRequired;if(d.allErrors?function(){if(c||l)e.block$data(s.nil,h);else for(let t of r)(0,a.checkReportMissingProp)(e,t)}():function(){let i=t.let("missing");if(c||l){let r=t.let("valid",!0);e.block$data(r,()=>{var l,d;return l=i,d=r,void(e.setParams({missingProperty:l}),t.forOf(l,n,()=>{t.assign(d,(0,a.propertyInData)(t,o,l,u.ownProperties)),t.if((0,s.not)(d),()=>{e.error(),t.break()})},s.nil))}),e.ok(r)}else t.if((0,a.checkMissingProp)(e,r,i)),(0,a.reportMissingProp)(e,i),t.else()}(),u.strictRequired){let t=e.parentSchema.properties,{definedProperties:a}=e.it;for(let e of r)if((null==t?void 0:t[e])===void 0&&!a.has(e)){let t=d.schemaEnv.baseId+d.errSchemaPath,r=`required property "${e}" is not defined at "${t}" (strictRequired)`;(0,i.checkStrictMode)(d,r,d.opts.strictRequired)}}function h(){t.forOf("prop",n,r=>{e.setParams({missingProperty:r}),t.if((0,a.noPropertyInData)(t,o,r,u.ownProperties),()=>e.error())})}}}},44058(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});let a=r(69003),s=r(17898),i=r(50458),n=r(72725);t.default={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:{message:({params:{i:e,j:t}})=>(0,s.str)`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>(0,s._)`{i: ${e}, j: ${t}}`},code(e){let{gen:t,data:r,$data:o,schema:l,parentSchema:d,schemaCode:u,it:c}=e;if(!o&&!l)return;let h=t.let("valid"),f=d.items?(0,a.getSchemaTypes)(d.items):[];e.block$data(h,function(){let o=t.let("i",(0,s._)`${r}.length`),l=t.let("j");e.setParams({i:o,j:l}),t.assign(h,!0),t.if((0,s._)`${o} > 1`,()=>(f.length>0&&!f.some(e=>"object"===e||"array"===e)?function(i,n){let o=t.name("item"),l=(0,a.checkDataTypes)(f,o,c.opts.strictNumbers,a.DataType.Wrong),d=t.const("indices",(0,s._)`{}`);t.for((0,s._)`;${i}--;`,()=>{t.let(o,(0,s._)`${r}[${i}]`),t.if(l,(0,s._)`continue`),f.length>1&&t.if((0,s._)`typeof ${o} == "string"`,(0,s._)`${o} += "_"`),t.if((0,s._)`typeof ${d}[${o}] == "number"`,()=>{t.assign(n,(0,s._)`${d}[${o}]`),e.error(),t.assign(h,!1).break()}).code((0,s._)`${d}[${o}] = ${i}`)})}:function(a,o){let l=(0,i.useFunc)(t,n.default),d=t.name("outer");t.label(d).for((0,s._)`;${a}--;`,()=>t.for((0,s._)`${o} = ${a}; ${o}--;`,()=>t.if((0,s._)`${l}(${r}[${a}], ${r}[${o}])`,()=>{e.error(),t.assign(h,!1).break(d)})))})(o,l))},(0,s._)`${u} === false`),e.ok(h)}}},38792(e){e.exports=function e(t,r){if(t===r)return!0;if(t&&r&&"object"==typeof t&&"object"==typeof r){if(t.constructor!==r.constructor)return!1;if(Array.isArray(t)){if((a=t.length)!=r.length)return!1;for(s=a;0!=s--;)if(!e(t[s],r[s]))return!1;return!0}if(t.constructor===RegExp)return t.source===r.source&&t.flags===r.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===r.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===r.toString();if((a=(i=Object.keys(t)).length)!==Object.keys(r).length)return!1;for(s=a;0!=s--;)if(!Object.prototype.hasOwnProperty.call(r,i[s]))return!1;for(s=a;0!=s--;){var a,s,i,n=i[s];if(!e(t[n],r[n]))return!1}return!0}return t!=t&&r!=r}},1645(e){var t=e.exports=function(e,r,a){"function"==typeof r&&(a=r,r={});var s="function"==typeof(a=r.cb||a)?a:a.pre||function(){};!function e(r,a,s,i,n,o,l,d,u,c){if(i&&"object"==typeof i&&!Array.isArray(i)){for(var h in a(i,n,o,l,d,u,c),i){var f=i[h];if(Array.isArray(f)){if(h in t.arrayKeywords)for(var p=0;p<f.length;p++)e(r,a,s,f[p],n+"/"+h+"/"+p,o,n,h,i,p)}else if(h in t.propsKeywords){if(f&&"object"==typeof f)for(var m in f)e(r,a,s,f[m],n+"/"+h+"/"+m.replace(/~/g,"~0").replace(/\//g,"~1"),o,n,h,i,m)}else(h in t.keywords||r.allKeys&&!(h in t.skipKeywords))&&e(r,a,s,f,n+"/"+h,o,n,h,i)}s(i,n,o,l,d,u,c)}}(r,s,a.post||function(){},e,"",e)};t.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0},t.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0},t.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0},t.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}},84800(e,t,r){let{normalizeIPv6:a,removeDotSegments:s,recomposeAuthority:i,normalizePercentEncoding:n,normalizePathEncoding:o,serializePathEncoding:l,normalizeQueryFragmentEncoding:d,encodeQuery:u,encodeFragment:c,reescapeHostDelimiters:h,isIPv4:f,nonSimpleDomain:p}=r(75365),{SCHEMES:m,getSchemeHandler:y}=r(13956),g=/^[A-Za-z][A-Za-z0-9+.-]*$/u,v="URI scheme is malformed.";function _(e){let t=unescape(String(e));if(!g.test(t))throw TypeError(v);return t}function $(e,t,r,a){let i={};return a||(e=N(b(e,r),r),t=N(b(t,r),r)),!(r=r||{}).tolerant&&t.scheme?(i.scheme=t.scheme,i.userinfo=t.userinfo,i.host=t.host,i.port=t.port,i.path=s(t.path||""),i.query=t.query):(void 0!==t.userinfo||void 0!==t.host||void 0!==t.port?(i.userinfo=t.userinfo,i.host=t.host,i.port=t.port,i.path=s(t.path||""),i.query=t.query):(t.path?("/"===t.path[0]?i.path=s(t.path):(void 0===e.userinfo&&void 0===e.host&&void 0===e.port||e.path?e.path?i.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:i.path=t.path:i.path="/"+t.path,i.path=s(i.path)),i.query=t.query):(i.path=e.path,void 0!==t.query?i.query=t.query:i.query=e.query),i.userinfo=e.userinfo,i.host=e.host,i.port=e.port),i.scheme=e.scheme),i.fragment=t.fragment,i}function b(e,t){let r={host:e.host,scheme:e.scheme,userinfo:e.userinfo,port:e.port,path:e.path,query:e.query,nid:e.nid,nss:e.nss,uuid:e.uuid,fragment:e.fragment,reference:e.reference,resourceName:e.resourceName,secure:e.secure,error:""},a=Object.assign({},t),o=[];r.scheme&&(r.scheme=_(r.scheme));let d=y(a.scheme||r.scheme);d&&d.serialize&&d.serialize(r,a);let h=void 0!==r.userinfo||void 0!==r.host||void 0!==r.port,f=!a.skipEscape&&void 0===r.scheme&&!h;void 0!==r.path&&(a.skipEscape?r.path=n(r.path):r.path=l(r.path,f)),"suffix"!==a.reference&&r.scheme&&(r.scheme=_(r.scheme),o.push(r.scheme,":"));let p=i(r);if(void 0!==p&&("suffix"!==a.reference&&o.push("//"),o.push(p),r.path&&"/"!==r.path[0]&&o.push("/")),void 0!==r.path){let e=r.path;a.absolutePath||d&&d.absolutePath||(e=s(e)),f&&(e=l(e,!0)),void 0===p&&"/"===e[0]&&"/"===e[1]&&(e="/%2F"+e.slice(2)),o.push(e)}return void 0!==r.query&&o.push("?",u(r.query)),void 0!==r.fragment&&o.push("#",c(r.fragment)),o.join("")}let w=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u,k=/^(?:[^#/:?]+:)?\/\/([^/?#]*)/,x=/^(?:[^#/:?]+:)?([/\\\t\n\r]*)/;function P(e){if(void 0===e)return!1;let t=e.indexOf("%");for(;-1!==t;){if(t+2>=e.length||!/^[\da-f]{2}$/iu.test(e.slice(t+1,t+3)))return!0;t=e.indexOf("%",t+3)}return!1}function S(e){return"["===e[0]&&"]"===e[e.length-1]}function E(e,t,r,a){if(!t.unicodeSupport&&(!r||!r.unicodeSupport)&&e.host&&!S(e.host)&&(t.domainHost||r&&r.domainHost)&&!1===a&&p(e.host))try{e.host=new URL("http://"+e.host).hostname}catch(t){return e.error=e.error||"Host's domain name can not be converted to ASCII: "+t,!0}return!1}function j(e,t){let r=Object.assign({},t),s={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0},i=!1,l=!1,u=!1,c=!1,p=!1,_=!1,$=!1;"suffix"===r.reference&&(e=r.scheme?r.scheme+":"+e:"//"+e);let b=e.match(k);null!==b&&-1!==b[1].indexOf("\\")&&(s.error="URI authority must not contain a literal backslash.",i=!0);let j=e.match(x);if(null!==j){let e=j[1],t=e.replace(/[\t\n\r]/g,"");t.length>=2&&("//"!==t.slice(0,2)?(s.error=s.error||"URI authority must not contain a literal backslash.",i=!0):e.length!==t.length&&(s.error=s.error||"URI authority introducer must not contain whitespace.",i=!0))}let N=e.match(w);if(N){let t;if(s.scheme=N[1],s.userinfo=N[3],s.host=N[4],s.port=parseInt(N[5],10),s.path=N[6]||"",s.query=N[7],s.fragment=N[8],void 0!==s.scheme){let e=unescape(s.scheme);g.test(e)?s.scheme=e.toLowerCase():(s.error=s.error||v,_=!0)}t=N[4],(l=P(N[3])||void 0!==t&&!S(t)&&P(t)||P(N[6])||P(N[7])||P(N[8]))&&(s.error=s.error||"URI contains malformed percent-encoding."),isNaN(s.port)&&(s.port=N[5]);let b=void 0!==N[2]&&s.path&&"/"!==s.path[0]?'URI path must start with "/" when authority is present.':"number"==typeof s.port&&(s.port<0||s.port>65535)?"URI port is malformed.":void 0;if(void 0!==b&&(s.error=s.error||b,i=!0),s.host)if(!1===f(s.host)){let e=S(s.host),t=-1!==s.host.indexOf("[")||-1!==s.host.indexOf("]"),r=a(s.host);$=r.isIPV6||!0===r.isIPVFuture,p=t&&(!e||!0===r.error),s.host=$?r.host:r.host.toLowerCase(),p&&(s.error=s.error||"URI host is malformed.",i=!0)}else $=!0;void 0!==s.scheme||void 0!==s.userinfo||void 0!==s.host||void 0!==s.port||void 0!==s.query||s.path?void 0===s.scheme?s.reference="relative":void 0===s.fragment?s.reference="absolute":s.reference="uri":s.reference="same-document",r.reference&&"suffix"!==r.reference&&r.reference!==s.reference&&(s.error=s.error||"URI is not a "+r.reference+" reference.");let w=y(r.scheme||s.scheme);if(p||(c=E(s,r,w,$)),!w||w&&!w.skipNormalize){if(-1!==e.indexOf("%")&&void 0!==s.host&&!p){let e=$?s.host:n(s.host,!0);s.host=h(e,$)}s.path&&(s.path=o(s.path)),s.query&&(s.query=d(s.query)),s.fragment&&(s.fragment=d(s.fragment))}w&&w.parse&&(w.parse(s,r),w===m.urn&&void 0===s.nid&&(u=!0))}else s.error=s.error||"URI can not be parsed.";return{parsed:s,malformedAuthorityOrPort:i,malformedPercentEncoding:l,malformedSchemeSpecific:u,malformedHost:c,malformedScheme:_}}function N(e,t){return j(e,t).parsed}function O(e,t){let{parsed:r,malformedAuthorityOrPort:a,malformedPercentEncoding:s,malformedSchemeSpecific:i,malformedHost:n,malformedScheme:o}=j(e,t);return{normalized:a||s||i||n||o?e:b(r,t),malformedAuthorityOrPort:a,malformedPercentEncoding:s,malformedSchemeSpecific:i,malformedHost:n,malformedScheme:o}}function T(e,t){let r;if("string"!=typeof e&&"object"!=typeof e)return;try{r="string"==typeof e?e:b(e,t)}catch{return}let{normalized:a,malformedAuthorityOrPort:s,malformedPercentEncoding:i,malformedSchemeSpecific:n,malformedHost:o,malformedScheme:l}=O(r,t);return s||i||n||o||l?void 0:a}let C={SCHEMES:m,normalize:function(e,t){return"string"==typeof e?e=O(e,t).normalized:"object"==typeof e&&(e=N(b(e,t),t)),e},resolve:function(e,t,r){let s=r?Object.assign({scheme:"null"},r):{scheme:"null"},{parsed:i,malformedAuthorityOrPort:n,malformedPercentEncoding:o,malformedSchemeSpecific:l,malformedHost:d,malformedScheme:u}=j(e,s),{parsed:c,malformedAuthorityOrPort:h,malformedPercentEncoding:p,malformedSchemeSpecific:m,malformedHost:g,malformedScheme:v}=j(t,s);if(n||h||o||p||l||m||d||g||u||v)throw Error(i.error||c.error||"URI is malformed.");let _=$(i,c,s,!0),w=y(r&&r.scheme||_.scheme),k=_.host;E(_,r||{},w,void 0!==k&&""!==k&&(f(k)||a(k).isIPV6));let x=k&&-1!==k.indexOf("%")&&!/\P{ASCII}/u.test(k);if(_.error&&!x)throw Error(_.error);return s.skipEscape=!0,b(_,s)},resolveComponent:$,equal:function(e,t,r){let a=T(e,r),s=T(t,r);return void 0!==a&&void 0!==s&&a===s},serialize:b,parse:N};e.exports=C,e.exports.default=C,e.exports.fastUri=C},13956(e,t,r){let{isUUID:a}=r(75365),s=/^([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-./:;=@]|%[\da-f]{2})+)$/iu,i=["http","https","ws","wss","urn","urn:uuid"];function n(e){return!0===e.secure||!1!==e.secure&&!!e.scheme&&3===e.scheme.length&&("w"===e.scheme[0]||"W"===e.scheme[0])&&("s"===e.scheme[1]||"S"===e.scheme[1])&&("s"===e.scheme[2]||"S"===e.scheme[2])}function o(e){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e}function l(e){let t="https"===String(e.scheme).toLowerCase();return(e.port===(t?443:80)||""===e.port)&&(e.port=void 0),e.path||(e.path="/"),e}let d={scheme:"http",domainHost:!0,parse:o,serialize:l},u={scheme:"https",domainHost:d.domainHost,parse:o,serialize:l},c={scheme:"ws",domainHost:!0,parse:function(e){return e.secure=n(e),e.resourceName=(e.path||"/")+(e.query?"?"+e.query:""),e.path=void 0,e.query=void 0,e},serialize:function(e){if((e.port===(n(e)?443:80)||""===e.port)&&(e.port=void 0),"boolean"==typeof e.secure&&(e.scheme=e.secure?"wss":"ws",e.secure=void 0),e.resourceName){let t=e.resourceName.indexOf("?"),r=-1===t?e.resourceName:e.resourceName.slice(0,t);e.path=r&&"/"!==r?r:void 0,e.query=-1===t?void 0:e.resourceName.slice(t+1),e.resourceName=void 0}return e.fragment=void 0,e}},h={scheme:"wss",domainHost:c.domainHost,parse:c.parse,serialize:c.serialize},f={http:d,https:u,ws:c,wss:h,urn:{scheme:"urn",parse:function(e,t){if(!e.path)return e.error="URN can not be parsed",e;let r=e.path.match(s);if(r&&r[0]===e.path){let a=t.scheme||e.scheme||"urn";e.nid=r[1].toLowerCase(),e.nss=r[2];let s=p(`${a}:${t.nid||e.nid}`);e.path=void 0,s&&(e=s.parse(e,t))}else e.error=e.error||"URN can not be parsed.";return e},serialize:function(e,t){if(void 0===e.nid)throw Error("URN without nid cannot be serialized");let r=t.scheme||e.scheme||"urn",a=e.nid.toLowerCase(),s=p(`${r}:${t.nid||a}`);s&&(e=s.serialize(e,t));let i=e,n=e.nss;return i.path=`${a||t.nid}:${n}`,t.skipEscape=!0,i},skipNormalize:!0},"urn:uuid":{scheme:"urn:uuid",parse:function(e,t){return e.uuid=e.nss,e.nss=void 0,t.tolerant||e.uuid&&a(e.uuid)||(e.error=e.error||"UUID is not valid."),e},serialize:function(e){return e.nss=(e.uuid||"").toLowerCase(),e},skipNormalize:!0}};function p(e){return e&&(f[e]||f[e.toLowerCase()])||void 0}Object.setPrototypeOf(f,null),e.exports={wsIsSecure:n,SCHEMES:f,isValidSchemeName:function(e){return -1!==i.indexOf(e)},getSchemeHandler:p}},75365(e){let t=RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu),r=RegExp.prototype.test.bind(/^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u),a=RegExp.prototype.test.bind(/^\d*$/u),s=RegExp.prototype.test.bind(/^[\da-f]{2}$/iu),i=RegExp.prototype.test.bind(/^[\da-z\-._~]$/iu),n=RegExp.prototype.test.bind(/^[A-Za-z0-9\-._~!$&'()*+,;=:@/]$/u),o=RegExp.prototype.test.bind(/^[A-Za-z0-9\-._~!$&'()*+,;=:@/?]$/u),l=RegExp.prototype.test.bind(/^[A-Za-z0-9\-._~!$&'()*+,;=:]$/u),d=Array(256);{let e="0123456789ABCDEF";for(let t=0;t<256;t++)d[t]="%"+e[t>>4]+e[15&t]}function u(e){return e<2048?d[192|e>>6]+d[128|63&e]:e<65536?d[224|e>>12]+d[128|e>>6&63]+d[128|63&e]:d[240|e>>18]+d[128|e>>12&63]+d[128|e>>6&63]+d[128|63&e]}let c=RegExp.prototype.test.bind(/^[\dA-Fa-f]{1,4}$/),h=RegExp.prototype.test.bind(/^[vV][\dA-Fa-f]+\.[A-Za-z\d\-._~!$&'()*+,;=:]+$/),f=RegExp.prototype.test.bind(/^[A-Za-z\d\-._~]$/),p=RegExp.prototype.test.bind(/[^!"$&'()*+,\-.;=_`a-z{}~]/u);function m(e){let t=-1,r=0,a=-1,s=0;for(let i=0;i<e.length;i++)"0"===e[i]?(-1===a&&(a=i),++s>r&&(r=s,t=a)):(a=-1,s=0);return r<2?e.join(":"):e.slice(0,t).join(":")+"::"+e.slice(t+r).join(":")}function y(e){let t="["===e[0]&&"]"===e[e.length-1];if(("["===e[0]||"]"===e[e.length-1])&&!t)return{host:e,isIPV6:!1,error:!0};let a=t?e.slice(1,-1):e;if(t&&h(a))return a=a.toLowerCase(),{host:`[${a}]`,escapedHost:a,isIPV6:!1,isIPVFuture:!0};if(2>function(e){let t=0;for(let r=0;r<e.length;r++)":"===e[r]&&t++;return t}(a))return{host:e,isIPV6:!1,error:t};let i="",n=a.indexOf("%");if(-1!==n){let t="%25"===a.slice(n,n+3).toLowerCase()?3:1;if(!function(e){if(0===e.length)return!1;for(let t=0;t<e.length;t++)if(!f(e[t])){if("%"===e[t]&&t+2<e.length&&s(e.slice(t+1,t+3))){t+=2;continue}return!1}return!0}(i=a.slice(n+t)))return{host:e,isIPV6:!1,error:!0};a=a.slice(0,n)}let o=function(e){let t=e.indexOf("::");if(-1!==t&&-1!==e.indexOf("::",t+1))return;let a=-1===t?e.split(":"):e.slice(0,t).split(":"),s=-1===t?[]:e.slice(t+2).split(":");-1!==t&&(1===a.length&&""===a[0]&&(a.length=0),1===s.length&&""===s[0]&&(s.length=0));let i=a.concat(s),n=0;for(let e=0;e<i.length;e++){let a=i[e];if(""===a)return;if(-1!==a.indexOf(".")){if(e!==i.length-1||-1!==t&&0===s.length||!r(a))return;n+=2;continue}if(!c(a))return;i[e]=parseInt(a,16).toString(16),n++}if(-1===t){if(8!==n)return;return m(i)}if(n>=8)return;let o=i.slice(0,a.length);for(let e=n;e<8;e++)o.push("0");for(let e=a.length;e<i.length;e++)o.push(i[e]);return m(o)}(a);return void 0===o?{host:e,isIPV6:!1,error:!0}:{host:o+(i?"%"+i:""),escapedHost:o+(i?"%25"+i:""),isIPV6:!0}}let g={"@":"%40","/":"%2F","?":"%3F","#":"%23",":":"%3A"},v=/[@/?#:]/g,_=/[@/?#]/g;function $(e,t){let r=t?_:v;return r.lastIndex=0,e.replace(r,e=>g[e])}function b(e,t=!1){if(-1===e.indexOf("%"))return e;let r="";for(let a=0;a<e.length;a++){if("%"===e[a]&&a+2<e.length){let n=e.slice(a+1,a+3);if(s(n)){let e=n.toUpperCase(),s=String.fromCharCode(parseInt(e,16));t&&i(s)?r+=s:r+="%"+e,a+=2;continue}}r+=e[a]}return r}function w(e,t){let r="";for(let a=0;a<e.length;a++){let i=e[a];if("%"===i&&a+2<e.length){let t=e.slice(a+1,a+3);if(s(t)){r+="%"+t.toUpperCase(),a+=2;continue}}if(t(i))r+=i;else{let t=e.charCodeAt(a);if(t<128)r+=d[t];else if(t<55296||t>57343)r+=u(t);else if(t<=56319&&a+1<e.length){let s=e.charCodeAt(a+1);s>=56320&&s<=57343?(r+=u(65536+(t-55296<<10)+(s-56320)),a++):r+=u(65533)}else r+=u(65533)}}return r}function k(e){return w(e,l)}function x(e){return e>=48&&e<=57||e>=65&&e<=90||e>=97&&e<=122||42===e||43===e||45===e||46===e||47===e||64===e||95===e}e.exports={nonSimpleDomain:p,recomposeAuthority:function(e){let t=[];if(void 0!==e.userinfo&&(t.push(k(e.userinfo)),t.push("@")),void 0!==e.host){let a=e.host;if(!r(a)){let e=y(a);!0!==e.isIPV6&&!0!==e.isIPVFuture&&(e=y(a=b(a,!0))),a=!0===e.isIPV6||!0===e.isIPVFuture?`[${e.escapedHost}]`:$(a,!1)}t.push(a)}if("number"==typeof e.port||"string"==typeof e.port){let r=String(e.port);if(!a(r))throw TypeError("URI port is malformed.");t.push(":"),t.push(r)}return t.length?t.join(""):void 0},reescapeHostDelimiters:$,normalizePercentEncoding:b,normalizePathEncoding:function(e){let t="";for(let r=0;r<e.length;r++){let a=e[r];if("%"===a&&r+2<e.length){let a=e.slice(r+1,r+3);if(s(a)){let e=a.toUpperCase(),s=String.fromCharCode(parseInt(e,16));"."!==s&&i(s)?t+=s:t+="%"+e,r+=2;continue}}if(n(a))t+=a;else{let s=e.charCodeAt(r);if(s<128)t+=x(s)?a:d[s];else if(s<55296||s>57343)t+=u(s);else if(s<=56319&&r+1<e.length){let a=e.charCodeAt(r+1);a>=56320&&a<=57343?(t+=u(65536+(s-55296<<10)+(a-56320)),r++):t+=u(65533)}else t+=u(65533)}}return t},serializePathEncoding:function(e,t=!1){let r="",a=t&&"/"!==e[0];for(let t=0;t<e.length;t++){let i=e[t];if("%"===i&&t+2<e.length){let a=e.slice(t+1,t+3);if(s(a)){r+="%"+a.toUpperCase(),t+=2;continue}}if("/"===i&&(a=!1),n(i)&&(":"!==i||!a))r+=i;else{let a=e.charCodeAt(t);if(a<128)r+=d[a];else if(a<55296||a>57343)r+=u(a);else if(a<=56319&&t+1<e.length){let s=e.charCodeAt(t+1);s>=56320&&s<=57343?(r+=u(65536+(a-55296<<10)+(s-56320)),t++):r+=u(65533)}else r+=u(65533)}}return r},normalizeQueryFragmentEncoding:function(e){let t="";for(let r=0;r<e.length;r++){let a=e[r];if("%"===a&&r+2<e.length){let a=e.slice(r+1,r+3);if(s(a)){let e=a.toUpperCase(),s=String.fromCharCode(parseInt(e,16));i(s)?t+=s:t+="%"+e,r+=2;continue}}if(o(a))t+=a;else{let s=e.charCodeAt(r);if(s<128)t+=x(s)?a:d[s];else if(s<55296||s>57343)t+=u(s);else if(s<=56319&&r+1<e.length){let a=e.charCodeAt(r+1);a>=56320&&a<=57343?(t+=u(65536+(s-55296<<10)+(a-56320)),r++):t+=u(65533)}else t+=u(65533)}}return t},encodeUserinfo:k,encodeQuery:function(e){return w(e,o)},encodeFragment:function(e){return w(e,o)},escapePreservingEscapes:function(e){let t="";for(let r=0;r<e.length;r++){if("%"===e[r]&&r+2<e.length){let a=e.slice(r+1,r+3);if(s(a)){t+="%"+a.toUpperCase(),r+=2;continue}}t+=escape(e[r])}return t},removeDotSegments:function(e){let t=e,r=[],a=-1,s=0;for(;s=t.length;){if(1===s)if("."===t)break;else if("/"===t){r.push("/");break}else{r.push(t);break}if(2===s){if("."===t[0]){if("."===t[1])break;else if("/"===t[1]){t=t.slice(2);continue}}else if("/"===t[0]&&("."===t[1]||"/"===t[1])){r.push("/");break}}else if(3===s&&"/.."===t){0!==r.length&&r.pop(),r.push("/");break}if("."===t[0]){if("."===t[1]){if("/"===t[2]){t=t.slice(3);continue}}else if("/"===t[1]){t=t.slice(2);continue}}else if("/"===t[0]&&"."===t[1]){if("/"===t[2]){t=t.slice(2);continue}else if("."===t[2]&&"/"===t[3]){t=t.slice(3),0!==r.length&&r.pop();continue}}if(-1===(a=t.indexOf("/",1))){r.push(t);break}r.push(t.slice(0,a)),t=t.slice(a)}return r.join("")},isIPv4:r,isUUID:t,normalizeIPv6:y,stringArrayToHexStripped:function(e){let t="",r=0,a=0;for(a=0;a<e.length;a++)if(48!==(r=e[a].charCodeAt(0))){if(!(r>=48&&r<=57||r>=65&&r<=70||r>=97&&r<=102))return"";t+=e[a];break}for(a+=1;a<e.length;a++){if(!((r=e[a].charCodeAt(0))>=48&&r<=57||r>=65&&r<=70||r>=97&&r<=102))return"";t+=e[a]}return t}}},22654(e,t,r){r.d(t,{G:()=>i,eq:()=>s});var a=r(62741);let s=a.ZS.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]);class i extends Error{get errors(){return this.issues}constructor(e){super(),this.issues=[],this.addIssue=e=>{this.issues=[...this.issues,e]},this.addIssues=(e=[])=>{this.issues=[...this.issues,...e]};const t=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,t):this.__proto__=t,this.name="ZodError",this.issues=e}format(e){let t=e||function(e){return e.message},r={_errors:[]},a=e=>{for(let s of e.issues)if("invalid_union"===s.code)s.unionErrors.map(a);else if("invalid_return_type"===s.code)a(s.returnTypeError);else if("invalid_arguments"===s.code)a(s.argumentsError);else if(0===s.path.length)r._errors.push(t(s));else{let e=r,a=0;for(;a<s.path.length;){let r=s.path[a];a===s.path.length-1?(e[r]=e[r]||{_errors:[]},e[r]._errors.push(t(s))):e[r]=e[r]||{_errors:[]},e=e[r],a++}}};return a(this),r}static assert(e){if(!(e instanceof i))throw Error(`Not a ZodError: ${e}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,a.ZS.jsonStringifyReplacer,2)}get isEmpty(){return 0===this.issues.length}flatten(e=e=>e.message){let t={},r=[];for(let a of this.issues)if(a.path.length>0){let r=a.path[0];t[r]=t[r]||[],t[r].push(e(a))}else r.push(e(a));return{formErrors:r,fieldErrors:t}}get formErrors(){return this.flatten()}}i.create=e=>new i(e)},62741(e,t,r){var a,s,i;r.d(t,{CR:()=>o,ZS:()=>a,Zp:()=>n}),(i=a||(a={})).assertEqual=e=>{},i.assertIs=function(e){},i.assertNever=function(e){throw Error()},i.arrayToEnum=e=>{let t={};for(let r of e)t[r]=r;return t},i.getValidEnumValues=e=>{let t=i.objectKeys(e).filter(t=>"number"!=typeof e[e[t]]),r={};for(let a of t)r[a]=e[a];return i.objectValues(r)},i.objectValues=e=>i.objectKeys(e).map(function(t){return e[t]}),i.objectKeys="function"==typeof Object.keys?e=>Object.keys(e):e=>{let t=[];for(let r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.push(r);return t},i.find=(e,t)=>{for(let r of e)if(t(r))return r},i.isInteger="function"==typeof Number.isInteger?e=>Number.isInteger(e):e=>"number"==typeof e&&Number.isFinite(e)&&Math.floor(e)===e,i.joinValues=function(e,t=" | "){return e.map(e=>"string"==typeof e?`'${e}'`:e).join(t)},i.jsonStringifyReplacer=(e,t)=>"bigint"==typeof t?t.toString():t,(s||(s={})).mergeShapes=(e,t)=>({...e,...t});let n=a.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),o=e=>{switch(typeof e){case"undefined":return n.undefined;case"string":return n.string;case"number":return Number.isNaN(e)?n.nan:n.number;case"boolean":return n.boolean;case"function":return n.function;case"bigint":return n.bigint;case"symbol":return n.symbol;case"object":if(Array.isArray(e))return n.array;if(null===e)return n.null;if(e.then&&"function"==typeof e.then&&e.catch&&"function"==typeof e.catch)return n.promise;if("u">typeof Map&&e instanceof Map)return n.map;if("u">typeof Set&&e instanceof Set)return n.set;if("u">typeof Date&&e instanceof Date)return n.date;return n.object;default:return n.unknown}}},71291(e,t,r){let a;r.d(t,{k5:()=>eT,L5:()=>ex,g1:()=>eN,re:()=>eE,Ik:()=>eS,YO:()=>eP,Yj:()=>ek,eu:()=>eO,PV:()=>ej});var s,i,n,o,l=r(22654),d=r(62741);let u=(e,t)=>{let r;switch(e.code){case l.eq.invalid_type:r=e.received===d.Zp.undefined?"Required":`Expected ${e.expected}, received ${e.received}`;break;case l.eq.invalid_literal:r=`Invalid literal value, expected ${JSON.stringify(e.expected,d.ZS.jsonStringifyReplacer)}`;break;case l.eq.unrecognized_keys:r=`Unrecognized key(s) in object: ${d.ZS.joinValues(e.keys,", ")}`;break;case l.eq.invalid_union:r="Invalid input";break;case l.eq.invalid_union_discriminator:r=`Invalid discriminator value. Expected ${d.ZS.joinValues(e.options)}`;break;case l.eq.invalid_enum_value:r=`Invalid enum value. Expected ${d.ZS.joinValues(e.options)}, received '${e.received}'`;break;case l.eq.invalid_arguments:r="Invalid function arguments";break;case l.eq.invalid_return_type:r="Invalid function return type";break;case l.eq.invalid_date:r="Invalid date";break;case l.eq.invalid_string:"object"==typeof e.validation?"includes"in e.validation?(r=`Invalid input: must include "${e.validation.includes}"`,"number"==typeof e.validation.position&&(r=`${r} at one or more positions greater than or equal to ${e.validation.position}`)):"startsWith"in e.validation?r=`Invalid input: must start with "${e.validation.startsWith}"`:"endsWith"in e.validation?r=`Invalid input: must end with "${e.validation.endsWith}"`:d.ZS.assertNever(e.validation):r="regex"!==e.validation?`Invalid ${e.validation}`:"Invalid";break;case l.eq.too_small:r="array"===e.type?`Array must contain ${e.exact?"exactly":e.inclusive?"at least":"more than"} ${e.minimum} element(s)`:"string"===e.type?`String must contain ${e.exact?"exactly":e.inclusive?"at least":"over"} ${e.minimum} character(s)`:"number"===e.type||"bigint"===e.type?`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:"date"===e.type?`Date must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(e.minimum))}`:"Invalid input";break;case l.eq.too_big:r="array"===e.type?`Array must contain ${e.exact?"exactly":e.inclusive?"at most":"less than"} ${e.maximum} element(s)`:"string"===e.type?`String must contain ${e.exact?"exactly":e.inclusive?"at most":"under"} ${e.maximum} character(s)`:"number"===e.type?`Number must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:"bigint"===e.type?`BigInt must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:"date"===e.type?`Date must be ${e.exact?"exactly":e.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(e.maximum))}`:"Invalid input";break;case l.eq.custom:r="Invalid input";break;case l.eq.invalid_intersection_types:r="Intersection results could not be merged";break;case l.eq.not_multiple_of:r=`Number must be a multiple of ${e.multipleOf}`;break;case l.eq.not_finite:r="Number must be finite";break;default:r=t.defaultError,d.ZS.assertNever(e)}return{message:r}};(s=n||(n={})).errToObj=e=>"string"==typeof e?{message:e}:e||{},s.toString=e=>"string"==typeof e?e:e?.message;let c=e=>{let{data:t,path:r,errorMaps:a,issueData:s}=e,i=[...r,...s.path||[]],n={...s,path:i};if(void 0!==s.message)return{...s,path:i,message:s.message};let o="";for(let e of a.filter(e=>!!e).slice().reverse())o=e(n,{data:t,defaultError:o}).message;return{...s,path:i,message:o}};function h(e,t){let r=c({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,u,void 0].filter(e=>!!e)});e.common.issues.push(r)}class f{constructor(){this.value="valid"}dirty(){"valid"===this.value&&(this.value="dirty")}abort(){"aborted"!==this.value&&(this.value="aborted")}static mergeArray(e,t){let r=[];for(let a of t){if("aborted"===a.status)return p;"dirty"===a.status&&e.dirty(),r.push(a.value)}return{status:e.value,value:r}}static async mergeObjectAsync(e,t){let r=[];for(let e of t){let t=await e.key,a=await e.value;r.push({key:t,value:a})}return f.mergeObjectSync(e,r)}static mergeObjectSync(e,t){let r={};for(let a of t){let{key:t,value:s}=a;if("aborted"===t.status||"aborted"===s.status)return p;"dirty"===t.status&&e.dirty(),"dirty"===s.status&&e.dirty(),"__proto__"!==t.value&&(void 0!==s.value||a.alwaysSet)&&(r[t.value]=s.value)}return{status:e.value,value:r}}}let p=Object.freeze({status:"aborted"}),m=e=>({status:"dirty",value:e}),y=e=>({status:"valid",value:e}),g=e=>"u">typeof Promise&&e instanceof Promise;class v{constructor(e,t,r,a){this._cachedPath=[],this.parent=e,this.data=t,this._path=r,this._key=a}get path(){return this._cachedPath.length||(Array.isArray(this._key)?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}let _=(e,t)=>{if("valid"===t.status)return{success:!0,data:t.value};if(!e.common.issues.length)throw Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;let t=new l.G(e.common.issues);return this._error=t,this._error}}};function $(e){if(!e)return{};let{errorMap:t,invalid_type_error:r,required_error:a,description:s}=e;if(t&&(r||a))throw Error('Can\'t use "invalid_type_error" or "required_error" in conjunction with custom error map.');return t?{errorMap:t,description:s}:{errorMap:(t,s)=>{let{message:i}=e;return"invalid_enum_value"===t.code?{message:i??s.defaultError}:void 0===s.data?{message:i??a??s.defaultError}:"invalid_type"!==t.code?{message:s.defaultError}:{message:i??r??s.defaultError}},description:s}}class b{get description(){return this._def.description}_getType(e){return(0,d.CR)(e.data)}_getOrReturnCtx(e,t){return t||{common:e.parent.common,data:e.data,parsedType:(0,d.CR)(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new f,ctx:{common:e.parent.common,data:e.data,parsedType:(0,d.CR)(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){let t=this._parse(e);if(g(t))throw Error("Synchronous parse encountered promise.");return t}_parseAsync(e){return Promise.resolve(this._parse(e))}parse(e,t){let r=this.safeParse(e,t);if(r.success)return r.data;throw r.error}safeParse(e,t){let r={common:{issues:[],async:t?.async??!1,contextualErrorMap:t?.errorMap},path:t?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:(0,d.CR)(e)},a=this._parseSync({data:e,path:r.path,parent:r});return _(r,a)}"~validate"(e){let t={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:(0,d.CR)(e)};if(!this["~standard"].async)try{let r=this._parseSync({data:e,path:[],parent:t});return"valid"===r.status?{value:r.value}:{issues:t.common.issues}}catch(e){e?.message?.toLowerCase()?.includes("encountered")&&(this["~standard"].async=!0),t.common={issues:[],async:!0}}return this._parseAsync({data:e,path:[],parent:t}).then(e=>"valid"===e.status?{value:e.value}:{issues:t.common.issues})}async parseAsync(e,t){let r=await this.safeParseAsync(e,t);if(r.success)return r.data;throw r.error}async safeParseAsync(e,t){let r={common:{issues:[],contextualErrorMap:t?.errorMap,async:!0},path:t?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:(0,d.CR)(e)},a=this._parse({data:e,path:r.path,parent:r});return _(r,await (g(a)?a:Promise.resolve(a)))}refine(e,t){return this._refinement((r,a)=>{let s=e(r),i=()=>a.addIssue({code:l.eq.custom,..."string"==typeof t||void 0===t?{message:t}:"function"==typeof t?t(r):t});return"u">typeof Promise&&s instanceof Promise?s.then(e=>!!e||(i(),!1)):!!s||(i(),!1)})}refinement(e,t){return this._refinement((r,a)=>!!e(r)||(a.addIssue("function"==typeof t?t(r,a):t),!1))}_refinement(e){return new ep({schema:this,typeName:o.ZodEffects,effect:{type:"refinement",refinement:e}})}superRefine(e){return this._refinement(e)}constructor(e){this.spa=this.safeParseAsync,this._def=e,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:e=>this["~validate"](e)}}optional(){return em.create(this,this._def)}nullable(){return ey.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return Q.create(this)}promise(){return ef.create(this,this._def)}or(e){return X.create([this,e],this._def)}and(e){return er.create(this,e,this._def)}transform(e){return new ep({...$(this._def),schema:this,typeName:o.ZodEffects,effect:{type:"transform",transform:e}})}default(e){return new eg({...$(this._def),innerType:this,defaultValue:"function"==typeof e?e:()=>e,typeName:o.ZodDefault})}brand(){return new e$({typeName:o.ZodBranded,type:this,...$(this._def)})}catch(e){return new ev({...$(this._def),innerType:this,catchValue:"function"==typeof e?e:()=>e,typeName:o.ZodCatch})}describe(e){return new this.constructor({...this._def,description:e})}pipe(e){return eb.create(this,e)}readonly(){return ew.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}let w=/^c[^\s-]{8,}$/i,k=/^[0-9a-z]+$/,x=/^[0-9A-HJKMNP-TV-Z]{26}$/i,P=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,S=/^[a-z0-9_-]{21}$/i,E=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,j=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,N=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,O=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,T=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,C=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,I=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,R=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,A=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,Z="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",M=RegExp(`^${Z}$`);function q(e){let t="[0-5]\\d";e.precision?t=`${t}\\.\\d{${e.precision}}`:null==e.precision&&(t=`${t}(\\.\\d+)?`);let r=e.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${t})${r}`}class D extends b{_parse(e){var t,r,s,i;let n;if(this._def.coerce&&(e.data=String(e.data)),this._getType(e)!==d.Zp.string){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.string,received:t.parsedType}),p}let o=new f;for(let u of this._def.checks)if("min"===u.kind)e.data.length<u.value&&(h(n=this._getOrReturnCtx(e,n),{code:l.eq.too_small,minimum:u.value,type:"string",inclusive:!0,exact:!1,message:u.message}),o.dirty());else if("max"===u.kind)e.data.length>u.value&&(h(n=this._getOrReturnCtx(e,n),{code:l.eq.too_big,maximum:u.value,type:"string",inclusive:!0,exact:!1,message:u.message}),o.dirty());else if("length"===u.kind){let t=e.data.length>u.value,r=e.data.length<u.value;(t||r)&&(n=this._getOrReturnCtx(e,n),t?h(n,{code:l.eq.too_big,maximum:u.value,type:"string",inclusive:!0,exact:!0,message:u.message}):r&&h(n,{code:l.eq.too_small,minimum:u.value,type:"string",inclusive:!0,exact:!0,message:u.message}),o.dirty())}else if("email"===u.kind)N.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"email",code:l.eq.invalid_string,message:u.message}),o.dirty());else if("emoji"===u.kind)a||(a=RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u")),a.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"emoji",code:l.eq.invalid_string,message:u.message}),o.dirty());else if("uuid"===u.kind)P.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"uuid",code:l.eq.invalid_string,message:u.message}),o.dirty());else if("nanoid"===u.kind)S.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"nanoid",code:l.eq.invalid_string,message:u.message}),o.dirty());else if("cuid"===u.kind)w.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"cuid",code:l.eq.invalid_string,message:u.message}),o.dirty());else if("cuid2"===u.kind)k.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"cuid2",code:l.eq.invalid_string,message:u.message}),o.dirty());else if("ulid"===u.kind)x.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"ulid",code:l.eq.invalid_string,message:u.message}),o.dirty());else if("url"===u.kind)try{new URL(e.data)}catch{h(n=this._getOrReturnCtx(e,n),{validation:"url",code:l.eq.invalid_string,message:u.message}),o.dirty()}else"regex"===u.kind?(u.regex.lastIndex=0,u.regex.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"regex",code:l.eq.invalid_string,message:u.message}),o.dirty())):"trim"===u.kind?e.data=e.data.trim():"includes"===u.kind?e.data.includes(u.value,u.position)||(h(n=this._getOrReturnCtx(e,n),{code:l.eq.invalid_string,validation:{includes:u.value,position:u.position},message:u.message}),o.dirty()):"toLowerCase"===u.kind?e.data=e.data.toLowerCase():"toUpperCase"===u.kind?e.data=e.data.toUpperCase():"startsWith"===u.kind?e.data.startsWith(u.value)||(h(n=this._getOrReturnCtx(e,n),{code:l.eq.invalid_string,validation:{startsWith:u.value},message:u.message}),o.dirty()):"endsWith"===u.kind?e.data.endsWith(u.value)||(h(n=this._getOrReturnCtx(e,n),{code:l.eq.invalid_string,validation:{endsWith:u.value},message:u.message}),o.dirty()):"datetime"===u.kind?(function(e){let t=`${Z}T${q(e)}`,r=[];return r.push(e.local?"Z?":"Z"),e.offset&&r.push("([+-]\\d{2}:?\\d{2})"),t=`${t}(${r.join("|")})`,RegExp(`^${t}$`)})(u).test(e.data)||(h(n=this._getOrReturnCtx(e,n),{code:l.eq.invalid_string,validation:"datetime",message:u.message}),o.dirty()):"date"===u.kind?M.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{code:l.eq.invalid_string,validation:"date",message:u.message}),o.dirty()):"time"===u.kind?RegExp(`^${q(u)}$`).test(e.data)||(h(n=this._getOrReturnCtx(e,n),{code:l.eq.invalid_string,validation:"time",message:u.message}),o.dirty()):"duration"===u.kind?j.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"duration",code:l.eq.invalid_string,message:u.message}),o.dirty()):"ip"===u.kind?(t=e.data,!(("v4"===(r=u.version)||!r)&&O.test(t)||("v6"===r||!r)&&C.test(t))&&1&&(h(n=this._getOrReturnCtx(e,n),{validation:"ip",code:l.eq.invalid_string,message:u.message}),o.dirty())):"jwt"===u.kind?!function(e,t){if(!E.test(e))return!1;try{let[r]=e.split(".");if(!r)return!1;let a=r.replace(/-/g,"+").replace(/_/g,"/").padEnd(r.length+(4-r.length%4)%4,"="),s=JSON.parse(atob(a));if("object"!=typeof s||null===s||"typ"in s&&s?.typ!=="JWT"||!s.alg||t&&s.alg!==t)return!1;return!0}catch{return!1}}(e.data,u.alg)&&(h(n=this._getOrReturnCtx(e,n),{validation:"jwt",code:l.eq.invalid_string,message:u.message}),o.dirty()):"cidr"===u.kind?(s=e.data,!(("v4"===(i=u.version)||!i)&&T.test(s)||("v6"===i||!i)&&I.test(s))&&1&&(h(n=this._getOrReturnCtx(e,n),{validation:"cidr",code:l.eq.invalid_string,message:u.message}),o.dirty())):"base64"===u.kind?R.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"base64",code:l.eq.invalid_string,message:u.message}),o.dirty()):"base64url"===u.kind?A.test(e.data)||(h(n=this._getOrReturnCtx(e,n),{validation:"base64url",code:l.eq.invalid_string,message:u.message}),o.dirty()):d.ZS.assertNever(u);return{status:o.value,value:e.data}}_regex(e,t,r){return this.refinement(t=>e.test(t),{validation:t,code:l.eq.invalid_string,...n.errToObj(r)})}_addCheck(e){return new D({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...n.errToObj(e)})}url(e){return this._addCheck({kind:"url",...n.errToObj(e)})}emoji(e){return this._addCheck({kind:"emoji",...n.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...n.errToObj(e)})}nanoid(e){return this._addCheck({kind:"nanoid",...n.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...n.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...n.errToObj(e)})}ulid(e){return this._addCheck({kind:"ulid",...n.errToObj(e)})}base64(e){return this._addCheck({kind:"base64",...n.errToObj(e)})}base64url(e){return this._addCheck({kind:"base64url",...n.errToObj(e)})}jwt(e){return this._addCheck({kind:"jwt",...n.errToObj(e)})}ip(e){return this._addCheck({kind:"ip",...n.errToObj(e)})}cidr(e){return this._addCheck({kind:"cidr",...n.errToObj(e)})}datetime(e){return"string"==typeof e?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:e}):this._addCheck({kind:"datetime",precision:void 0===e?.precision?null:e?.precision,offset:e?.offset??!1,local:e?.local??!1,...n.errToObj(e?.message)})}date(e){return this._addCheck({kind:"date",message:e})}time(e){return"string"==typeof e?this._addCheck({kind:"time",precision:null,message:e}):this._addCheck({kind:"time",precision:void 0===e?.precision?null:e?.precision,...n.errToObj(e?.message)})}duration(e){return this._addCheck({kind:"duration",...n.errToObj(e)})}regex(e,t){return this._addCheck({kind:"regex",regex:e,...n.errToObj(t)})}includes(e,t){return this._addCheck({kind:"includes",value:e,position:t?.position,...n.errToObj(t?.message)})}startsWith(e,t){return this._addCheck({kind:"startsWith",value:e,...n.errToObj(t)})}endsWith(e,t){return this._addCheck({kind:"endsWith",value:e,...n.errToObj(t)})}min(e,t){return this._addCheck({kind:"min",value:e,...n.errToObj(t)})}max(e,t){return this._addCheck({kind:"max",value:e,...n.errToObj(t)})}length(e,t){return this._addCheck({kind:"length",value:e,...n.errToObj(t)})}nonempty(e){return this.min(1,n.errToObj(e))}trim(){return new D({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new D({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new D({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(e=>"datetime"===e.kind)}get isDate(){return!!this._def.checks.find(e=>"date"===e.kind)}get isTime(){return!!this._def.checks.find(e=>"time"===e.kind)}get isDuration(){return!!this._def.checks.find(e=>"duration"===e.kind)}get isEmail(){return!!this._def.checks.find(e=>"email"===e.kind)}get isURL(){return!!this._def.checks.find(e=>"url"===e.kind)}get isEmoji(){return!!this._def.checks.find(e=>"emoji"===e.kind)}get isUUID(){return!!this._def.checks.find(e=>"uuid"===e.kind)}get isNANOID(){return!!this._def.checks.find(e=>"nanoid"===e.kind)}get isCUID(){return!!this._def.checks.find(e=>"cuid"===e.kind)}get isCUID2(){return!!this._def.checks.find(e=>"cuid2"===e.kind)}get isULID(){return!!this._def.checks.find(e=>"ulid"===e.kind)}get isIP(){return!!this._def.checks.find(e=>"ip"===e.kind)}get isCIDR(){return!!this._def.checks.find(e=>"cidr"===e.kind)}get isBase64(){return!!this._def.checks.find(e=>"base64"===e.kind)}get isBase64url(){return!!this._def.checks.find(e=>"base64url"===e.kind)}get minLength(){let e=null;for(let t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxLength(){let e=null;for(let t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}}D.create=e=>new D({checks:[],typeName:o.ZodString,coerce:e?.coerce??!1,...$(e)});class V extends b{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){let t;if(this._def.coerce&&(e.data=Number(e.data)),this._getType(e)!==d.Zp.number){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.number,received:t.parsedType}),p}let r=new f;for(let a of this._def.checks)"int"===a.kind?d.ZS.isInteger(e.data)||(h(t=this._getOrReturnCtx(e,t),{code:l.eq.invalid_type,expected:"integer",received:"float",message:a.message}),r.dirty()):"min"===a.kind?(a.inclusive?e.data<a.value:e.data<=a.value)&&(h(t=this._getOrReturnCtx(e,t),{code:l.eq.too_small,minimum:a.value,type:"number",inclusive:a.inclusive,exact:!1,message:a.message}),r.dirty()):"max"===a.kind?(a.inclusive?e.data>a.value:e.data>=a.value)&&(h(t=this._getOrReturnCtx(e,t),{code:l.eq.too_big,maximum:a.value,type:"number",inclusive:a.inclusive,exact:!1,message:a.message}),r.dirty()):"multipleOf"===a.kind?0!==function(e,t){let r=(e.toString().split(".")[1]||"").length,a=(t.toString().split(".")[1]||"").length,s=r>a?r:a;return Number.parseInt(e.toFixed(s).replace(".",""))%Number.parseInt(t.toFixed(s).replace(".",""))/10**s}(e.data,a.value)&&(h(t=this._getOrReturnCtx(e,t),{code:l.eq.not_multiple_of,multipleOf:a.value,message:a.message}),r.dirty()):"finite"===a.kind?Number.isFinite(e.data)||(h(t=this._getOrReturnCtx(e,t),{code:l.eq.not_finite,message:a.message}),r.dirty()):d.ZS.assertNever(a);return{status:r.value,value:e.data}}gte(e,t){return this.setLimit("min",e,!0,n.toString(t))}gt(e,t){return this.setLimit("min",e,!1,n.toString(t))}lte(e,t){return this.setLimit("max",e,!0,n.toString(t))}lt(e,t){return this.setLimit("max",e,!1,n.toString(t))}setLimit(e,t,r,a){return new V({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:r,message:n.toString(a)}]})}_addCheck(e){return new V({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:n.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:n.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:n.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:n.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:n.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:n.toString(t)})}finite(e){return this._addCheck({kind:"finite",message:n.toString(e)})}safe(e){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:n.toString(e)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:n.toString(e)})}get minValue(){let e=null;for(let t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(let t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}get isInt(){return!!this._def.checks.find(e=>"int"===e.kind||"multipleOf"===e.kind&&d.ZS.isInteger(e.value))}get isFinite(){let e=null,t=null;for(let r of this._def.checks)if("finite"===r.kind||"int"===r.kind||"multipleOf"===r.kind)return!0;else"min"===r.kind?(null===t||r.value>t)&&(t=r.value):"max"===r.kind&&(null===e||r.value<e)&&(e=r.value);return Number.isFinite(t)&&Number.isFinite(e)}}V.create=e=>new V({checks:[],typeName:o.ZodNumber,coerce:e?.coerce||!1,...$(e)});class z extends b{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(e){let t;if(this._def.coerce)try{e.data=BigInt(e.data)}catch{return this._getInvalidInput(e)}if(this._getType(e)!==d.Zp.bigint)return this._getInvalidInput(e);let r=new f;for(let a of this._def.checks)"min"===a.kind?(a.inclusive?e.data<a.value:e.data<=a.value)&&(h(t=this._getOrReturnCtx(e,t),{code:l.eq.too_small,type:"bigint",minimum:a.value,inclusive:a.inclusive,message:a.message}),r.dirty()):"max"===a.kind?(a.inclusive?e.data>a.value:e.data>=a.value)&&(h(t=this._getOrReturnCtx(e,t),{code:l.eq.too_big,type:"bigint",maximum:a.value,inclusive:a.inclusive,message:a.message}),r.dirty()):"multipleOf"===a.kind?e.data%a.value!==BigInt(0)&&(h(t=this._getOrReturnCtx(e,t),{code:l.eq.not_multiple_of,multipleOf:a.value,message:a.message}),r.dirty()):d.ZS.assertNever(a);return{status:r.value,value:e.data}}_getInvalidInput(e){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.bigint,received:t.parsedType}),p}gte(e,t){return this.setLimit("min",e,!0,n.toString(t))}gt(e,t){return this.setLimit("min",e,!1,n.toString(t))}lte(e,t){return this.setLimit("max",e,!0,n.toString(t))}lt(e,t){return this.setLimit("max",e,!1,n.toString(t))}setLimit(e,t,r,a){return new z({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:r,message:n.toString(a)}]})}_addCheck(e){return new z({...this._def,checks:[...this._def.checks,e]})}positive(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:n.toString(e)})}negative(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:n.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:n.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:n.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:n.toString(t)})}get minValue(){let e=null;for(let t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(let t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}}z.create=e=>new z({checks:[],typeName:o.ZodBigInt,coerce:e?.coerce??!1,...$(e)});class F extends b{_parse(e){if(this._def.coerce&&(e.data=!!e.data),this._getType(e)!==d.Zp.boolean){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.boolean,received:t.parsedType}),p}return y(e.data)}}F.create=e=>new F({typeName:o.ZodBoolean,coerce:e?.coerce||!1,...$(e)});class U extends b{_parse(e){let t;if(this._def.coerce&&(e.data=new Date(e.data)),this._getType(e)!==d.Zp.date){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.date,received:t.parsedType}),p}if(Number.isNaN(e.data.getTime()))return h(this._getOrReturnCtx(e),{code:l.eq.invalid_date}),p;let r=new f;for(let a of this._def.checks)"min"===a.kind?e.data.getTime()<a.value&&(h(t=this._getOrReturnCtx(e,t),{code:l.eq.too_small,message:a.message,inclusive:!0,exact:!1,minimum:a.value,type:"date"}),r.dirty()):"max"===a.kind?e.data.getTime()>a.value&&(h(t=this._getOrReturnCtx(e,t),{code:l.eq.too_big,message:a.message,inclusive:!0,exact:!1,maximum:a.value,type:"date"}),r.dirty()):d.ZS.assertNever(a);return{status:r.value,value:new Date(e.data.getTime())}}_addCheck(e){return new U({...this._def,checks:[...this._def.checks,e]})}min(e,t){return this._addCheck({kind:"min",value:e.getTime(),message:n.toString(t)})}max(e,t){return this._addCheck({kind:"max",value:e.getTime(),message:n.toString(t)})}get minDate(){let e=null;for(let t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return null!=e?new Date(e):null}get maxDate(){let e=null;for(let t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return null!=e?new Date(e):null}}U.create=e=>new U({checks:[],coerce:e?.coerce||!1,typeName:o.ZodDate,...$(e)});class L extends b{_parse(e){if(this._getType(e)!==d.Zp.symbol){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.symbol,received:t.parsedType}),p}return y(e.data)}}L.create=e=>new L({typeName:o.ZodSymbol,...$(e)});class K extends b{_parse(e){if(this._getType(e)!==d.Zp.undefined){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.undefined,received:t.parsedType}),p}return y(e.data)}}K.create=e=>new K({typeName:o.ZodUndefined,...$(e)});class G extends b{_parse(e){if(this._getType(e)!==d.Zp.null){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.null,received:t.parsedType}),p}return y(e.data)}}G.create=e=>new G({typeName:o.ZodNull,...$(e)});class B extends b{constructor(){super(...arguments),this._any=!0}_parse(e){return y(e.data)}}B.create=e=>new B({typeName:o.ZodAny,...$(e)});class H extends b{constructor(){super(...arguments),this._unknown=!0}_parse(e){return y(e.data)}}H.create=e=>new H({typeName:o.ZodUnknown,...$(e)});class J extends b{_parse(e){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.never,received:t.parsedType}),p}}J.create=e=>new J({typeName:o.ZodNever,...$(e)});class W extends b{_parse(e){if(this._getType(e)!==d.Zp.undefined){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.void,received:t.parsedType}),p}return y(e.data)}}W.create=e=>new W({typeName:o.ZodVoid,...$(e)});class Q extends b{_parse(e){let{ctx:t,status:r}=this._processInputParams(e),a=this._def;if(t.parsedType!==d.Zp.array)return h(t,{code:l.eq.invalid_type,expected:d.Zp.array,received:t.parsedType}),p;if(null!==a.exactLength){let e=t.data.length>a.exactLength.value,s=t.data.length<a.exactLength.value;(e||s)&&(h(t,{code:e?l.eq.too_big:l.eq.too_small,minimum:s?a.exactLength.value:void 0,maximum:e?a.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:a.exactLength.message}),r.dirty())}if(null!==a.minLength&&t.data.length<a.minLength.value&&(h(t,{code:l.eq.too_small,minimum:a.minLength.value,type:"array",inclusive:!0,exact:!1,message:a.minLength.message}),r.dirty()),null!==a.maxLength&&t.data.length>a.maxLength.value&&(h(t,{code:l.eq.too_big,maximum:a.maxLength.value,type:"array",inclusive:!0,exact:!1,message:a.maxLength.message}),r.dirty()),t.common.async)return Promise.all([...t.data].map((e,r)=>a.type._parseAsync(new v(t,e,t.path,r)))).then(e=>f.mergeArray(r,e));let s=[...t.data].map((e,r)=>a.type._parseSync(new v(t,e,t.path,r)));return f.mergeArray(r,s)}get element(){return this._def.type}min(e,t){return new Q({...this._def,minLength:{value:e,message:n.toString(t)}})}max(e,t){return new Q({...this._def,maxLength:{value:e,message:n.toString(t)}})}length(e,t){return new Q({...this._def,exactLength:{value:e,message:n.toString(t)}})}nonempty(e){return this.min(1,e)}}Q.create=(e,t)=>new Q({type:e,minLength:null,maxLength:null,exactLength:null,typeName:o.ZodArray,...$(t)});class Y extends b{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(null!==this._cached)return this._cached;let e=this._def.shape(),t=d.ZS.objectKeys(e);return this._cached={shape:e,keys:t},this._cached}_parse(e){if(this._getType(e)!==d.Zp.object){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.object,received:t.parsedType}),p}let{status:t,ctx:r}=this._processInputParams(e),{shape:a,keys:s}=this._getCached(),i=[];if(!(this._def.catchall instanceof J&&"strip"===this._def.unknownKeys))for(let e in r.data)s.includes(e)||i.push(e);let n=[];for(let e of s){let t=a[e],s=r.data[e];n.push({key:{status:"valid",value:e},value:t._parse(new v(r,s,r.path,e)),alwaysSet:e in r.data})}if(this._def.catchall instanceof J){let e=this._def.unknownKeys;if("passthrough"===e)for(let e of i)n.push({key:{status:"valid",value:e},value:{status:"valid",value:r.data[e]}});else if("strict"===e)i.length>0&&(h(r,{code:l.eq.unrecognized_keys,keys:i}),t.dirty());else if("strip"===e);else throw Error("Internal ZodObject error: invalid unknownKeys value.")}else{let e=this._def.catchall;for(let t of i){let a=r.data[t];n.push({key:{status:"valid",value:t},value:e._parse(new v(r,a,r.path,t)),alwaysSet:t in r.data})}}return r.common.async?Promise.resolve().then(async()=>{let e=[];for(let t of n){let r=await t.key,a=await t.value;e.push({key:r,value:a,alwaysSet:t.alwaysSet})}return e}).then(e=>f.mergeObjectSync(t,e)):f.mergeObjectSync(t,n)}get shape(){return this._def.shape()}strict(e){return n.errToObj,new Y({...this._def,unknownKeys:"strict",...void 0!==e?{errorMap:(t,r)=>{let a=this._def.errorMap?.(t,r).message??r.defaultError;return"unrecognized_keys"===t.code?{message:n.errToObj(e).message??a}:{message:a}}}:{}})}strip(){return new Y({...this._def,unknownKeys:"strip"})}passthrough(){return new Y({...this._def,unknownKeys:"passthrough"})}extend(e){return new Y({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new Y({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>({...this._def.shape(),...e._def.shape()}),typeName:o.ZodObject})}setKey(e,t){return this.augment({[e]:t})}catchall(e){return new Y({...this._def,catchall:e})}pick(e){let t={};for(let r of d.ZS.objectKeys(e))e[r]&&this.shape[r]&&(t[r]=this.shape[r]);return new Y({...this._def,shape:()=>t})}omit(e){let t={};for(let r of d.ZS.objectKeys(this.shape))e[r]||(t[r]=this.shape[r]);return new Y({...this._def,shape:()=>t})}deepPartial(){return function e(t){if(t instanceof Y){let r={};for(let a in t.shape){let s=t.shape[a];r[a]=em.create(e(s))}return new Y({...t._def,shape:()=>r})}if(t instanceof Q)return new Q({...t._def,type:e(t.element)});if(t instanceof em)return em.create(e(t.unwrap()));if(t instanceof ey)return ey.create(e(t.unwrap()));if(t instanceof ea)return ea.create(t.items.map(t=>e(t)));else return t}(this)}partial(e){let t={};for(let r of d.ZS.objectKeys(this.shape)){let a=this.shape[r];e&&!e[r]?t[r]=a:t[r]=a.optional()}return new Y({...this._def,shape:()=>t})}required(e){let t={};for(let r of d.ZS.objectKeys(this.shape))if(e&&!e[r])t[r]=this.shape[r];else{let e=this.shape[r];for(;e instanceof em;)e=e._def.innerType;t[r]=e}return new Y({...this._def,shape:()=>t})}keyof(){return eu(d.ZS.objectKeys(this.shape))}}Y.create=(e,t)=>new Y({shape:()=>e,unknownKeys:"strip",catchall:J.create(),typeName:o.ZodObject,...$(t)}),Y.strictCreate=(e,t)=>new Y({shape:()=>e,unknownKeys:"strict",catchall:J.create(),typeName:o.ZodObject,...$(t)}),Y.lazycreate=(e,t)=>new Y({shape:e,unknownKeys:"strip",catchall:J.create(),typeName:o.ZodObject,...$(t)});class X extends b{_parse(e){let{ctx:t}=this._processInputParams(e),r=this._def.options;if(t.common.async)return Promise.all(r.map(async e=>{let r={...t,common:{...t.common,issues:[]},parent:null};return{result:await e._parseAsync({data:t.data,path:t.path,parent:r}),ctx:r}})).then(function(e){for(let t of e)if("valid"===t.result.status)return t.result;for(let r of e)if("dirty"===r.result.status)return t.common.issues.push(...r.ctx.common.issues),r.result;let r=e.map(e=>new l.G(e.ctx.common.issues));return h(t,{code:l.eq.invalid_union,unionErrors:r}),p});{let e,a=[];for(let s of r){let r={...t,common:{...t.common,issues:[]},parent:null},i=s._parseSync({data:t.data,path:t.path,parent:r});if("valid"===i.status)return i;"dirty"!==i.status||e||(e={result:i,ctx:r}),r.common.issues.length&&a.push(r.common.issues)}if(e)return t.common.issues.push(...e.ctx.common.issues),e.result;let s=a.map(e=>new l.G(e));return h(t,{code:l.eq.invalid_union,unionErrors:s}),p}}get options(){return this._def.options}}X.create=(e,t)=>new X({options:e,typeName:o.ZodUnion,...$(t)});let ee=e=>{if(e instanceof el)return ee(e.schema);if(e instanceof ep)return ee(e.innerType());if(e instanceof ed)return[e.value];if(e instanceof ec)return e.options;if(e instanceof eh)return d.ZS.objectValues(e.enum);else if(e instanceof eg)return ee(e._def.innerType);else if(e instanceof K)return[void 0];else if(e instanceof G)return[null];else if(e instanceof em)return[void 0,...ee(e.unwrap())];else if(e instanceof ey)return[null,...ee(e.unwrap())];else if(e instanceof e$)return ee(e.unwrap());else if(e instanceof ew)return ee(e.unwrap());else if(e instanceof ev)return ee(e._def.innerType);else return[]};class et extends b{_parse(e){let{ctx:t}=this._processInputParams(e);if(t.parsedType!==d.Zp.object)return h(t,{code:l.eq.invalid_type,expected:d.Zp.object,received:t.parsedType}),p;let r=this.discriminator,a=t.data[r],s=this.optionsMap.get(a);return s?t.common.async?s._parseAsync({data:t.data,path:t.path,parent:t}):s._parseSync({data:t.data,path:t.path,parent:t}):(h(t,{code:l.eq.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[r]}),p)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(e,t,r){let a=new Map;for(let r of t){let t=ee(r.shape[e]);if(!t.length)throw Error(`A discriminator value for key \`${e}\` could not be extracted from all schema options`);for(let s of t){if(a.has(s))throw Error(`Discriminator property ${String(e)} has duplicate value ${String(s)}`);a.set(s,r)}}return new et({typeName:o.ZodDiscriminatedUnion,discriminator:e,options:t,optionsMap:a,...$(r)})}}class er extends b{_parse(e){let{status:t,ctx:r}=this._processInputParams(e),a=(e,a)=>{if("aborted"===e.status||"aborted"===a.status)return p;let s=function e(t,r){let a=(0,d.CR)(t),s=(0,d.CR)(r);if(t===r)return{valid:!0,data:t};if(a===d.Zp.object&&s===d.Zp.object){let a=d.ZS.objectKeys(r),s=d.ZS.objectKeys(t).filter(e=>-1!==a.indexOf(e)),i={...t,...r};for(let a of s){let s=e(t[a],r[a]);if(!s.valid)return{valid:!1};i[a]=s.data}return{valid:!0,data:i}}if(a===d.Zp.array&&s===d.Zp.array){if(t.length!==r.length)return{valid:!1};let a=[];for(let s=0;s<t.length;s++){let i=e(t[s],r[s]);if(!i.valid)return{valid:!1};a.push(i.data)}return{valid:!0,data:a}}if(a===d.Zp.date&&s===d.Zp.date&&+t==+r)return{valid:!0,data:t};return{valid:!1}}(e.value,a.value);return s.valid?(("dirty"===e.status||"dirty"===a.status)&&t.dirty(),{status:t.value,value:s.data}):(h(r,{code:l.eq.invalid_intersection_types}),p)};return r.common.async?Promise.all([this._def.left._parseAsync({data:r.data,path:r.path,parent:r}),this._def.right._parseAsync({data:r.data,path:r.path,parent:r})]).then(([e,t])=>a(e,t)):a(this._def.left._parseSync({data:r.data,path:r.path,parent:r}),this._def.right._parseSync({data:r.data,path:r.path,parent:r}))}}er.create=(e,t,r)=>new er({left:e,right:t,typeName:o.ZodIntersection,...$(r)});class ea extends b{_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.parsedType!==d.Zp.array)return h(r,{code:l.eq.invalid_type,expected:d.Zp.array,received:r.parsedType}),p;if(r.data.length<this._def.items.length)return h(r,{code:l.eq.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),p;!this._def.rest&&r.data.length>this._def.items.length&&(h(r,{code:l.eq.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),t.dirty());let a=[...r.data].map((e,t)=>{let a=this._def.items[t]||this._def.rest;return a?a._parse(new v(r,e,r.path,t)):null}).filter(e=>!!e);return r.common.async?Promise.all(a).then(e=>f.mergeArray(t,e)):f.mergeArray(t,a)}get items(){return this._def.items}rest(e){return new ea({...this._def,rest:e})}}ea.create=(e,t)=>{if(!Array.isArray(e))throw Error("You must pass an array of schemas to z.tuple([ ... ])");return new ea({items:e,typeName:o.ZodTuple,rest:null,...$(t)})};class es extends b{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.parsedType!==d.Zp.object)return h(r,{code:l.eq.invalid_type,expected:d.Zp.object,received:r.parsedType}),p;let a=[],s=this._def.keyType,i=this._def.valueType;for(let e in r.data)a.push({key:s._parse(new v(r,e,r.path,e)),value:i._parse(new v(r,r.data[e],r.path,e)),alwaysSet:e in r.data});return r.common.async?f.mergeObjectAsync(t,a):f.mergeObjectSync(t,a)}get element(){return this._def.valueType}static create(e,t,r){return new es(t instanceof b?{keyType:e,valueType:t,typeName:o.ZodRecord,...$(r)}:{keyType:D.create(),valueType:e,typeName:o.ZodRecord,...$(t)})}}class ei extends b{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.parsedType!==d.Zp.map)return h(r,{code:l.eq.invalid_type,expected:d.Zp.map,received:r.parsedType}),p;let a=this._def.keyType,s=this._def.valueType,i=[...r.data.entries()].map(([e,t],i)=>({key:a._parse(new v(r,e,r.path,[i,"key"])),value:s._parse(new v(r,t,r.path,[i,"value"]))}));if(r.common.async){let e=new Map;return Promise.resolve().then(async()=>{for(let r of i){let a=await r.key,s=await r.value;if("aborted"===a.status||"aborted"===s.status)return p;("dirty"===a.status||"dirty"===s.status)&&t.dirty(),e.set(a.value,s.value)}return{status:t.value,value:e}})}{let e=new Map;for(let r of i){let a=r.key,s=r.value;if("aborted"===a.status||"aborted"===s.status)return p;("dirty"===a.status||"dirty"===s.status)&&t.dirty(),e.set(a.value,s.value)}return{status:t.value,value:e}}}}ei.create=(e,t,r)=>new ei({valueType:t,keyType:e,typeName:o.ZodMap,...$(r)});class en extends b{_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.parsedType!==d.Zp.set)return h(r,{code:l.eq.invalid_type,expected:d.Zp.set,received:r.parsedType}),p;let a=this._def;null!==a.minSize&&r.data.size<a.minSize.value&&(h(r,{code:l.eq.too_small,minimum:a.minSize.value,type:"set",inclusive:!0,exact:!1,message:a.minSize.message}),t.dirty()),null!==a.maxSize&&r.data.size>a.maxSize.value&&(h(r,{code:l.eq.too_big,maximum:a.maxSize.value,type:"set",inclusive:!0,exact:!1,message:a.maxSize.message}),t.dirty());let s=this._def.valueType;function i(e){let r=new Set;for(let a of e){if("aborted"===a.status)return p;"dirty"===a.status&&t.dirty(),r.add(a.value)}return{status:t.value,value:r}}let n=[...r.data.values()].map((e,t)=>s._parse(new v(r,e,r.path,t)));return r.common.async?Promise.all(n).then(e=>i(e)):i(n)}min(e,t){return new en({...this._def,minSize:{value:e,message:n.toString(t)}})}max(e,t){return new en({...this._def,maxSize:{value:e,message:n.toString(t)}})}size(e,t){return this.min(e,t).max(e,t)}nonempty(e){return this.min(1,e)}}en.create=(e,t)=>new en({valueType:e,minSize:null,maxSize:null,typeName:o.ZodSet,...$(t)});class eo extends b{constructor(){super(...arguments),this.validate=this.implement}_parse(e){let{ctx:t}=this._processInputParams(e);if(t.parsedType!==d.Zp.function)return h(t,{code:l.eq.invalid_type,expected:d.Zp.function,received:t.parsedType}),p;function r(e,r){return c({data:e,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,u,u].filter(e=>!!e),issueData:{code:l.eq.invalid_arguments,argumentsError:r}})}function a(e,r){return c({data:e,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,u,u].filter(e=>!!e),issueData:{code:l.eq.invalid_return_type,returnTypeError:r}})}let s={errorMap:t.common.contextualErrorMap},i=t.data;if(this._def.returns instanceof ef){let e=this;return y(async function(...t){let n=new l.G([]),o=await e._def.args.parseAsync(t,s).catch(e=>{throw n.addIssue(r(t,e)),n}),d=await Reflect.apply(i,this,o);return await e._def.returns._def.type.parseAsync(d,s).catch(e=>{throw n.addIssue(a(d,e)),n})})}{let e=this;return y(function(...t){let n=e._def.args.safeParse(t,s);if(!n.success)throw new l.G([r(t,n.error)]);let o=Reflect.apply(i,this,n.data),d=e._def.returns.safeParse(o,s);if(!d.success)throw new l.G([a(o,d.error)]);return d.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...e){return new eo({...this._def,args:ea.create(e).rest(H.create())})}returns(e){return new eo({...this._def,returns:e})}implement(e){return this.parse(e)}strictImplement(e){return this.parse(e)}static create(e,t,r){return new eo({args:e||ea.create([]).rest(H.create()),returns:t||H.create(),typeName:o.ZodFunction,...$(r)})}}class el extends b{get schema(){return this._def.getter()}_parse(e){let{ctx:t}=this._processInputParams(e);return this._def.getter()._parse({data:t.data,path:t.path,parent:t})}}el.create=(e,t)=>new el({getter:e,typeName:o.ZodLazy,...$(t)});class ed extends b{_parse(e){if(e.data!==this._def.value){let t=this._getOrReturnCtx(e);return h(t,{received:t.data,code:l.eq.invalid_literal,expected:this._def.value}),p}return{status:"valid",value:e.data}}get value(){return this._def.value}}function eu(e,t){return new ec({values:e,typeName:o.ZodEnum,...$(t)})}ed.create=(e,t)=>new ed({value:e,typeName:o.ZodLiteral,...$(t)});class ec extends b{_parse(e){if("string"!=typeof e.data){let t=this._getOrReturnCtx(e),r=this._def.values;return h(t,{expected:d.ZS.joinValues(r),received:t.parsedType,code:l.eq.invalid_type}),p}if(this._cache||(this._cache=new Set(this._def.values)),!this._cache.has(e.data)){let t=this._getOrReturnCtx(e),r=this._def.values;return h(t,{received:t.data,code:l.eq.invalid_enum_value,options:r}),p}return y(e.data)}get options(){return this._def.values}get enum(){let e={};for(let t of this._def.values)e[t]=t;return e}get Values(){let e={};for(let t of this._def.values)e[t]=t;return e}get Enum(){let e={};for(let t of this._def.values)e[t]=t;return e}extract(e,t=this._def){return ec.create(e,{...this._def,...t})}exclude(e,t=this._def){return ec.create(this.options.filter(t=>!e.includes(t)),{...this._def,...t})}}ec.create=eu;class eh extends b{_parse(e){let t=d.ZS.getValidEnumValues(this._def.values),r=this._getOrReturnCtx(e);if(r.parsedType!==d.Zp.string&&r.parsedType!==d.Zp.number){let e=d.ZS.objectValues(t);return h(r,{expected:d.ZS.joinValues(e),received:r.parsedType,code:l.eq.invalid_type}),p}if(this._cache||(this._cache=new Set(d.ZS.getValidEnumValues(this._def.values))),!this._cache.has(e.data)){let e=d.ZS.objectValues(t);return h(r,{received:r.data,code:l.eq.invalid_enum_value,options:e}),p}return y(e.data)}get enum(){return this._def.values}}eh.create=(e,t)=>new eh({values:e,typeName:o.ZodNativeEnum,...$(t)});class ef extends b{unwrap(){return this._def.type}_parse(e){let{ctx:t}=this._processInputParams(e);return t.parsedType!==d.Zp.promise&&!1===t.common.async?(h(t,{code:l.eq.invalid_type,expected:d.Zp.promise,received:t.parsedType}),p):y((t.parsedType===d.Zp.promise?t.data:Promise.resolve(t.data)).then(e=>this._def.type.parseAsync(e,{path:t.path,errorMap:t.common.contextualErrorMap})))}}ef.create=(e,t)=>new ef({type:e,typeName:o.ZodPromise,...$(t)});class ep extends b{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===o.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){let{status:t,ctx:r}=this._processInputParams(e),a=this._def.effect||null,s={addIssue:e=>{h(r,e),e.fatal?t.abort():t.dirty()},get path(){return r.path}};if(s.addIssue=s.addIssue.bind(s),"preprocess"===a.type){let e=a.transform(r.data,s);if(r.common.async)return Promise.resolve(e).then(async e=>{if("aborted"===t.value)return p;let a=await this._def.schema._parseAsync({data:e,path:r.path,parent:r});return"aborted"===a.status?p:"dirty"===a.status||"dirty"===t.value?m(a.value):a});{if("aborted"===t.value)return p;let a=this._def.schema._parseSync({data:e,path:r.path,parent:r});return"aborted"===a.status?p:"dirty"===a.status||"dirty"===t.value?m(a.value):a}}if("refinement"===a.type){let e=e=>{let t=a.refinement(e,s);if(r.common.async)return Promise.resolve(t);if(t instanceof Promise)throw Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return e};if(!1!==r.common.async)return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(r=>"aborted"===r.status?p:("dirty"===r.status&&t.dirty(),e(r.value).then(()=>({status:t.value,value:r.value}))));{let a=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});return"aborted"===a.status?p:("dirty"===a.status&&t.dirty(),e(a.value),{status:t.value,value:a.value})}}if("transform"===a.type)if(!1!==r.common.async)return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(e=>"valid"!==e.status?p:Promise.resolve(a.transform(e.value,s)).then(e=>({status:t.value,value:e})));else{let e=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});if("valid"!==e.status)return p;let i=a.transform(e.value,s);if(i instanceof Promise)throw Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:t.value,value:i}}d.ZS.assertNever(a)}}ep.create=(e,t,r)=>new ep({schema:e,typeName:o.ZodEffects,effect:t,...$(r)}),ep.createWithPreprocess=(e,t,r)=>new ep({schema:t,effect:{type:"preprocess",transform:e},typeName:o.ZodEffects,...$(r)});class em extends b{_parse(e){return this._getType(e)===d.Zp.undefined?y(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}em.create=(e,t)=>new em({innerType:e,typeName:o.ZodOptional,...$(t)});class ey extends b{_parse(e){return this._getType(e)===d.Zp.null?y(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}ey.create=(e,t)=>new ey({innerType:e,typeName:o.ZodNullable,...$(t)});class eg extends b{_parse(e){let{ctx:t}=this._processInputParams(e),r=t.data;return t.parsedType===d.Zp.undefined&&(r=this._def.defaultValue()),this._def.innerType._parse({data:r,path:t.path,parent:t})}removeDefault(){return this._def.innerType}}eg.create=(e,t)=>new eg({innerType:e,typeName:o.ZodDefault,defaultValue:"function"==typeof t.default?t.default:()=>t.default,...$(t)});class ev extends b{_parse(e){let{ctx:t}=this._processInputParams(e),r={...t,common:{...t.common,issues:[]}},a=this._def.innerType._parse({data:r.data,path:r.path,parent:{...r}});return g(a)?a.then(e=>({status:"valid",value:"valid"===e.status?e.value:this._def.catchValue({get error(){return new l.G(r.common.issues)},input:r.data})})):{status:"valid",value:"valid"===a.status?a.value:this._def.catchValue({get error(){return new l.G(r.common.issues)},input:r.data})}}removeCatch(){return this._def.innerType}}ev.create=(e,t)=>new ev({innerType:e,typeName:o.ZodCatch,catchValue:"function"==typeof t.catch?t.catch:()=>t.catch,...$(t)});class e_ extends b{_parse(e){if(this._getType(e)!==d.Zp.nan){let t=this._getOrReturnCtx(e);return h(t,{code:l.eq.invalid_type,expected:d.Zp.nan,received:t.parsedType}),p}return{status:"valid",value:e.data}}}e_.create=e=>new e_({typeName:o.ZodNaN,...$(e)}),Symbol("zod_brand");class e$ extends b{_parse(e){let{ctx:t}=this._processInputParams(e),r=t.data;return this._def.type._parse({data:r,path:t.path,parent:t})}unwrap(){return this._def.type}}class eb extends b{_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.common.async)return(async()=>{let e=await this._def.in._parseAsync({data:r.data,path:r.path,parent:r});return"aborted"===e.status?p:"dirty"===e.status?(t.dirty(),m(e.value)):this._def.out._parseAsync({data:e.value,path:r.path,parent:r})})();{let e=this._def.in._parseSync({data:r.data,path:r.path,parent:r});return"aborted"===e.status?p:"dirty"===e.status?(t.dirty(),{status:"dirty",value:e.value}):this._def.out._parseSync({data:e.value,path:r.path,parent:r})}}static create(e,t){return new eb({in:e,out:t,typeName:o.ZodPipeline})}}class ew extends b{_parse(e){let t=this._def.innerType._parse(e),r=e=>("valid"===e.status&&(e.value=Object.freeze(e.value)),e);return g(t)?t.then(e=>r(e)):r(t)}unwrap(){return this._def.innerType}}ew.create=(e,t)=>new ew({innerType:e,typeName:o.ZodReadonly,...$(t)}),Y.lazycreate,(i=o||(o={})).ZodString="ZodString",i.ZodNumber="ZodNumber",i.ZodNaN="ZodNaN",i.ZodBigInt="ZodBigInt",i.ZodBoolean="ZodBoolean",i.ZodDate="ZodDate",i.ZodSymbol="ZodSymbol",i.ZodUndefined="ZodUndefined",i.ZodNull="ZodNull",i.ZodAny="ZodAny",i.ZodUnknown="ZodUnknown",i.ZodNever="ZodNever",i.ZodVoid="ZodVoid",i.ZodArray="ZodArray",i.ZodObject="ZodObject",i.ZodUnion="ZodUnion",i.ZodDiscriminatedUnion="ZodDiscriminatedUnion",i.ZodIntersection="ZodIntersection",i.ZodTuple="ZodTuple",i.ZodRecord="ZodRecord",i.ZodMap="ZodMap",i.ZodSet="ZodSet",i.ZodFunction="ZodFunction",i.ZodLazy="ZodLazy",i.ZodLiteral="ZodLiteral",i.ZodEnum="ZodEnum",i.ZodEffects="ZodEffects",i.ZodNativeEnum="ZodNativeEnum",i.ZodOptional="ZodOptional",i.ZodNullable="ZodNullable",i.ZodDefault="ZodDefault",i.ZodCatch="ZodCatch",i.ZodPromise="ZodPromise",i.ZodBranded="ZodBranded",i.ZodPipeline="ZodPipeline",i.ZodReadonly="ZodReadonly";let ek=D.create;V.create,e_.create,z.create,F.create,U.create,L.create,K.create,G.create,B.create;let ex=H.create;J.create,W.create;let eP=Q.create,eS=Y.create,eE=Y.strictCreate;X.create,et.create,er.create;let ej=ea.create,eN=es.create;ei.create,en.create,eo.create,el.create;let eO=ed.create,eT=ec.create;eh.create,ef.create,ep.create,em.create,ey.create,ep.createWithPreprocess,eb.create},93770(e){e.exports=JSON.parse('{"$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":false}')},33928(e){e.exports=JSON.parse('{"$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":true,"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":true,"readOnly":{"type":"boolean","default":false},"examples":{"type":"array","items":true},"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":true},"maxItems":{"$ref":"#/definitions/nonNegativeInteger"},"minItems":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"uniqueItems":{"type":"boolean","default":false},"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":true,"enum":{"type":"array","items":true,"minItems":1,"uniqueItems":true},"type":{"anyOf":[{"$ref":"#/definitions/simpleTypes"},{"type":"array","items":{"$ref":"#/definitions/simpleTypes"},"minItems":1,"uniqueItems":true}]},"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":true}')}}]);
8
+ //# sourceMappingURL=2055.d938e6121e5f.chunk.js.map