aso-cli 0.3.0 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +0 -13
- package/cli/dist/cli.js +204 -341
- package/cli/dist/cli.js.map +4 -4
- package/cli/dist/dashboard-public/assets/index-B11FooR-.js +23 -0
- package/cli/dist/dashboard-public/index.html +1 -1
- package/cli/dist/mcp.js +49 -39
- package/cli/dist/mcp.js.map +4 -4
- package/package.json +2 -1
- package/cli/dist/dashboard-public/assets/index-EguovmUL.js +0 -23
package/cli/dist/mcp.js
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
"use strict";var
|
|
3
|
-
`);let o;for(;(o=
|
|
4
|
-
`),i=i.replace(/\\r/g,"\r")),t[r]=i}return t}function LS(e){e=e||{};let t=Mg(e);e.path=t;let n=Oe.configDotenv(e);if(!n.parsed){let a=new Error(`MISSING_DATA: Cannot parse ${t} for an unknown reason`);throw a.code="MISSING_DATA",a}let o=Zg(e).split(","),r=o.length,i;for(let a=0;a<r;a++)try{let s=o[a].trim(),c=VS(n,s);i=Oe.decrypt(c.ciphertext,c.key);break}catch(s){if(a+1>=r)throw s}return Oe.parse(i)}function qS(e){console.log(`[dotenv@${$d}][WARN] ${e}`)}function Zo(e){console.log(`[dotenv@${$d}][DEBUG] ${e}`)}function Ug(e){console.log(`[dotenv@${$d}] ${e}`)}function Zg(e){return e&&e.DOTENV_KEY&&e.DOTENV_KEY.length>0?e.DOTENV_KEY:process.env.DOTENV_KEY&&process.env.DOTENV_KEY.length>0?process.env.DOTENV_KEY:""}function VS(e,t){let n;try{n=new URL(t)}catch(s){if(s.code==="ERR_INVALID_URL"){let c=new Error("INVALID_DOTENV_KEY: Wrong format. Must be in valid uri format like dotenv://:key_1234@dotenvx.com/vault/.env.vault?environment=development");throw c.code="INVALID_DOTENV_KEY",c}throw s}let o=n.password;if(!o){let s=new Error("INVALID_DOTENV_KEY: Missing key part");throw s.code="INVALID_DOTENV_KEY",s}let r=n.searchParams.get("environment");if(!r){let s=new Error("INVALID_DOTENV_KEY: Missing environment part");throw s.code="INVALID_DOTENV_KEY",s}let i=`DOTENV_VAULT_${r.toUpperCase()}`,a=e.parsed[i];if(!a){let s=new Error(`NOT_FOUND_DOTENV_ENVIRONMENT: Cannot locate environment ${i} in your .env.vault file.`);throw s.code="NOT_FOUND_DOTENV_ENVIRONMENT",s}return{ciphertext:a,key:o}}function Mg(e){let t=null;if(e&&e.path&&e.path.length>0)if(Array.isArray(e.path))for(let n of e.path)bd.existsSync(n)&&(t=n.endsWith(".vault")?n:`${n}.vault`);else t=e.path.endsWith(".vault")?e.path:`${e.path}.vault`;else t=Ga.resolve(process.cwd(),".env.vault");return bd.existsSync(t)?t:null}function Cg(e){return e[0]==="~"?Ga.join(DS.homedir(),e.slice(1)):e}function FS(e){let t=!!(e&&e.debug),n=e&&"quiet"in e?e.quiet:!0;(t||!n)&&Ug("Loading env from encrypted .env.vault");let o=Oe._parseVault(e),r=process.env;return e&&e.processEnv!=null&&(r=e.processEnv),Oe.populate(r,o,e),{parsed:o}}function BS(e){let t=Ga.resolve(process.cwd(),".env"),n="utf8",o=!!(e&&e.debug),r=e&&"quiet"in e?e.quiet:!0;e&&e.encoding?n=e.encoding:o&&Zo("No encoding is specified. UTF-8 is used by default");let i=[t];if(e&&e.path)if(!Array.isArray(e.path))i=[Cg(e.path)];else{i=[];for(let l of e.path)i.push(Cg(l))}let a,s={};for(let l of i)try{let d=Oe.parse(bd.readFileSync(l,{encoding:n}));Oe.populate(s,d,e)}catch(d){o&&Zo(`Failed to load ${l} ${d.message}`),a=d}let c=process.env;if(e&&e.processEnv!=null&&(c=e.processEnv),Oe.populate(c,s,e),o||!r){let l=Object.keys(s).length,d=[];for(let f of i)try{let _=Ga.relative(process.cwd(),f);d.push(_)}catch(_){o&&Zo(`Failed to load ${f} ${_.message}`),a=_}Ug(`injecting env (${l}) from ${d.join(",")}`)}return a?{parsed:s,error:a}:{parsed:s}}function KS(e){if(Zg(e).length===0)return Oe.configDotenv(e);let t=Mg(e);return t?Oe._configVault(e):(qS(`You set DOTENV_KEY but you are missing a .env.vault file at ${t}. Did you forget to build it?`),Oe.configDotenv(e))}function HS(e,t){let n=Buffer.from(t.slice(-64),"hex"),o=Buffer.from(e,"base64"),r=o.subarray(0,12),i=o.subarray(-16);o=o.subarray(12,-16);try{let a=CS.createDecipheriv("aes-256-gcm",n,r);return a.setAuthTag(i),`${a.update(o)}${a.final()}`}catch(a){let s=a instanceof RangeError,c=a.message==="Invalid key length",l=a.message==="Unsupported state or unable to authenticate data";if(s||c){let d=new Error("INVALID_DOTENV_KEY: It must be 64 characters long (or more)");throw d.code="INVALID_DOTENV_KEY",d}else if(l){let d=new Error("DECRYPTION_FAILED: Please check your DOTENV_KEY");throw d.code="DECRYPTION_FAILED",d}else throw a}}function JS(e,t,n={}){let o=!!(n&&n.debug),r=!!(n&&n.override);if(typeof t!="object"){let i=new Error("OBJECT_REQUIRED: Please check the processEnv argument being passed to populate");throw i.code="OBJECT_REQUIRED",i}for(let i of Object.keys(t))Object.prototype.hasOwnProperty.call(e,i)?(r===!0&&(e[i]=t[i]),o&&Zo(r===!0?`"${i}" is already defined and WAS overwritten`:`"${i}" is already defined and was NOT overwritten`)):e[i]=t[i]}var Oe={configDotenv:BS,_configVault:FS,_parseVault:LS,config:KS,decrypt:HS,parse:MS,populate:JS};Wt.exports.configDotenv=Oe.configDotenv;Wt.exports._configVault=Oe._configVault;Wt.exports._parseVault=Oe._parseVault;Wt.exports.config=Oe.config;Wt.exports.decrypt=Oe.decrypt;Wt.exports.parse=Oe.parse;Wt.exports.populate=Oe.populate;Wt.exports=Oe});var aa=A(me=>{"use strict";Object.defineProperty(me,"__esModule",{value:!0});me.regexpCode=me.getEsmExportName=me.getProperty=me.safeStringify=me.stringify=me.strConcat=me.addCodeArg=me.str=me._=me.nil=me._Code=me.Name=me.IDENTIFIER=me._CodeOrName=void 0;var oa=class{};me._CodeOrName=oa;me.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var rn=class extends oa{constructor(t){if(super(),!me.IDENTIFIER.test(t))throw new Error("CodeGen: name must be a valid identifier");this.str=t}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}};me.Name=rn;var bt=class extends oa{constructor(t){super(),this._items=typeof t=="string"?[t]:t}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;let t=this._items[0];return t===""||t==='""'}get str(){var t;return(t=this._str)!==null&&t!==void 0?t:this._str=this._items.reduce((n,o)=>`${n}${o}`,"")}get names(){var t;return(t=this._names)!==null&&t!==void 0?t:this._names=this._items.reduce((n,o)=>(o instanceof rn&&(n[o.str]=(n[o.str]||0)+1),n),{})}};me._Code=bt;me.nil=new bt("");function cb(e,...t){let n=[e[0]],o=0;for(;o<t.length;)rm(n,t[o]),n.push(e[++o]);return new bt(n)}me._=cb;var tm=new bt("+");function ub(e,...t){let n=[ia(e[0])],o=0;for(;o<t.length;)n.push(tm),rm(n,t[o]),n.push(tm,ia(e[++o]));return LP(n),new bt(n)}me.str=ub;function rm(e,t){t instanceof bt?e.push(...t._items):t instanceof rn?e.push(t):e.push(FP(t))}me.addCodeArg=rm;function LP(e){let t=1;for(;t<e.length-1;){if(e[t]===tm){let n=qP(e[t-1],e[t+1]);if(n!==void 0){e.splice(t-1,3,n);continue}e[t++]="+"}t++}}function qP(e,t){if(t==='""')return e;if(e==='""')return t;if(typeof e=="string")return t instanceof rn||e[e.length-1]!=='"'?void 0:typeof t!="string"?`${e.slice(0,-1)}${t}"`:t[0]==='"'?e.slice(0,-1)+t.slice(1):void 0;if(typeof t=="string"&&t[0]==='"'&&!(e instanceof rn))return`"${e}${t.slice(1)}`}function VP(e,t){return t.emptyStr()?e:e.emptyStr()?t:ub`${e}${t}`}me.strConcat=VP;function FP(e){return typeof e=="number"||typeof e=="boolean"||e===null?e:ia(Array.isArray(e)?e.join(","):e)}function BP(e){return new bt(ia(e))}me.stringify=BP;function ia(e){return JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}me.safeStringify=ia;function KP(e){return typeof e=="string"&&me.IDENTIFIER.test(e)?new bt(`.${e}`):cb`[${e}]`}me.getProperty=KP;function HP(e){if(typeof e=="string"&&me.IDENTIFIER.test(e))return new bt(`${e}`);throw new Error(`CodeGen: invalid export name: ${e}, use explicit $id name mapping`)}me.getEsmExportName=HP;function JP(e){return new bt(e.toString())}me.regexpCode=JP});var im=A(it=>{"use strict";Object.defineProperty(it,"__esModule",{value:!0});it.ValueScope=it.ValueScopeName=it.Scope=it.varKinds=it.UsedValueState=void 0;var ot=aa(),nm=class extends Error{constructor(t){super(`CodeGen: "code" for ${t} not defined`),this.value=t.value}},il;(function(e){e[e.Started=0]="Started",e[e.Completed=1]="Completed"})(il||(it.UsedValueState=il={}));it.varKinds={const:new ot.Name("const"),let:new ot.Name("let"),var:new ot.Name("var")};var al=class{constructor({prefixes:t,parent:n}={}){this._names={},this._prefixes=t,this._parent=n}toName(t){return t instanceof ot.Name?t:this.name(t)}name(t){return new ot.Name(this._newName(t))}_newName(t){let n=this._names[t]||this._nameGroup(t);return`${t}${n.index++}`}_nameGroup(t){var n,o;if(!((o=(n=this._parent)===null||n===void 0?void 0:n._prefixes)===null||o===void 0)&&o.has(t)||this._prefixes&&!this._prefixes.has(t))throw new Error(`CodeGen: prefix "${t}" is not allowed in this scope`);return this._names[t]={prefix:t,index:0}}};it.Scope=al;var sl=class extends ot.Name{constructor(t,n){super(n),this.prefix=t}setValue(t,{property:n,itemIndex:o}){this.value=t,this.scopePath=(0,ot._)`.${new ot.Name(n)}[${o}]`}};it.ValueScopeName=sl;var GP=(0,ot._)`\n`,om=class extends al{constructor(t){super(t),this._values={},this._scope=t.scope,this.opts={...t,_n:t.lines?GP:ot.nil}}get(){return this._scope}name(t){return new sl(t,this._newName(t))}value(t,n){var o;if(n.ref===void 0)throw new Error("CodeGen: ref must be passed in value");let r=this.toName(t),{prefix:i}=r,a=(o=n.key)!==null&&o!==void 0?o:n.ref,s=this._values[i];if(s){let d=s.get(a);if(d)return d}else s=this._values[i]=new Map;s.set(a,r);let c=this._scope[i]||(this._scope[i]=[]),l=c.length;return c[l]=n.ref,r.setValue(n,{property:i,itemIndex:l}),r}getValue(t,n){let o=this._values[t];if(o)return o.get(n)}scopeRefs(t,n=this._values){return this._reduceValues(n,o=>{if(o.scopePath===void 0)throw new Error(`CodeGen: name "${o}" has no value`);return(0,ot._)`${t}${o.scopePath}`})}scopeCode(t=this._values,n,o){return this._reduceValues(t,r=>{if(r.value===void 0)throw new Error(`CodeGen: name "${r}" has no value`);return r.value.code},n,o)}_reduceValues(t,n,o={},r){let i=ot.nil;for(let a in t){let s=t[a];if(!s)continue;let c=o[a]=o[a]||new Map;s.forEach(l=>{if(c.has(l))return;c.set(l,il.Started);let d=n(l);if(d){let f=this.opts.es5?it.varKinds.var:it.varKinds.const;i=(0,ot._)`${i}${f} ${l} = ${d};${this.opts._n}`}else if(d=r?.(l))i=(0,ot._)`${i}${d}${this.opts._n}`;else throw new nm(l);c.set(l,il.Completed)})}return i}};it.ValueScope=om});var re=A(oe=>{"use strict";Object.defineProperty(oe,"__esModule",{value:!0});oe.or=oe.and=oe.not=oe.CodeGen=oe.operators=oe.varKinds=oe.ValueScopeName=oe.ValueScope=oe.Scope=oe.Name=oe.regexpCode=oe.stringify=oe.getProperty=oe.nil=oe.strConcat=oe.str=oe._=void 0;var le=aa(),jt=im(),Or=aa();Object.defineProperty(oe,"_",{enumerable:!0,get:function(){return Or._}});Object.defineProperty(oe,"str",{enumerable:!0,get:function(){return Or.str}});Object.defineProperty(oe,"strConcat",{enumerable:!0,get:function(){return Or.strConcat}});Object.defineProperty(oe,"nil",{enumerable:!0,get:function(){return Or.nil}});Object.defineProperty(oe,"getProperty",{enumerable:!0,get:function(){return Or.getProperty}});Object.defineProperty(oe,"stringify",{enumerable:!0,get:function(){return Or.stringify}});Object.defineProperty(oe,"regexpCode",{enumerable:!0,get:function(){return Or.regexpCode}});Object.defineProperty(oe,"Name",{enumerable:!0,get:function(){return Or.Name}});var dl=im();Object.defineProperty(oe,"Scope",{enumerable:!0,get:function(){return dl.Scope}});Object.defineProperty(oe,"ValueScope",{enumerable:!0,get:function(){return dl.ValueScope}});Object.defineProperty(oe,"ValueScopeName",{enumerable:!0,get:function(){return dl.ValueScopeName}});Object.defineProperty(oe,"varKinds",{enumerable:!0,get:function(){return dl.varKinds}});oe.operators={GT:new le._Code(">"),GTE:new le._Code(">="),LT:new le._Code("<"),LTE:new le._Code("<="),EQ:new le._Code("==="),NEQ:new le._Code("!=="),NOT:new le._Code("!"),OR:new le._Code("||"),AND:new le._Code("&&"),ADD:new le._Code("+")};var nr=class{optimizeNodes(){return this}optimizeNames(t,n){return this}},am=class extends nr{constructor(t,n,o){super(),this.varKind=t,this.name=n,this.rhs=o}render({es5:t,_n:n}){let o=t?jt.varKinds.var:this.varKind,r=this.rhs===void 0?"":` = ${this.rhs}`;return`${o} ${this.name}${r};`+n}optimizeNames(t,n){if(t[this.name.str])return this.rhs&&(this.rhs=_o(this.rhs,t,n)),this}get names(){return this.rhs instanceof le._CodeOrName?this.rhs.names:{}}},cl=class extends nr{constructor(t,n,o){super(),this.lhs=t,this.rhs=n,this.sideEffects=o}render({_n:t}){return`${this.lhs} = ${this.rhs};`+t}optimizeNames(t,n){if(!(this.lhs instanceof le.Name&&!t[this.lhs.str]&&!this.sideEffects))return this.rhs=_o(this.rhs,t,n),this}get names(){let t=this.lhs instanceof le.Name?{}:{...this.lhs.names};return ll(t,this.rhs)}},sm=class extends cl{constructor(t,n,o,r){super(t,o,r),this.op=n}render({_n:t}){return`${this.lhs} ${this.op}= ${this.rhs};`+t}},cm=class extends nr{constructor(t){super(),this.label=t,this.names={}}render({_n:t}){return`${this.label}:`+t}},um=class extends nr{constructor(t){super(),this.label=t,this.names={}}render({_n:t}){return`break${this.label?` ${this.label}`:""};`+t}},lm=class extends nr{constructor(t){super(),this.error=t}render({_n:t}){return`throw ${this.error};`+t}get names(){return this.error.names}},dm=class extends nr{constructor(t){super(),this.code=t}render({_n:t}){return`${this.code};`+t}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(t,n){return this.code=_o(this.code,t,n),this}get names(){return this.code instanceof le._CodeOrName?this.code.names:{}}},sa=class extends nr{constructor(t=[]){super(),this.nodes=t}render(t){return this.nodes.reduce((n,o)=>n+o.render(t),"")}optimizeNodes(){let{nodes:t}=this,n=t.length;for(;n--;){let o=t[n].optimizeNodes();Array.isArray(o)?t.splice(n,1,...o):o?t[n]=o:t.splice(n,1)}return t.length>0?this:void 0}optimizeNames(t,n){let{nodes:o}=this,r=o.length;for(;r--;){let i=o[r];i.optimizeNames(t,n)||(WP(t,i.names),o.splice(r,1))}return o.length>0?this:void 0}get names(){return this.nodes.reduce((t,n)=>an(t,n.names),{})}},or=class extends sa{render(t){return"{"+t._n+super.render(t)+"}"+t._n}},fm=class extends sa{},vo=class extends or{};vo.kind="else";var nn=class e extends or{constructor(t,n){super(n),this.condition=t}render(t){let n=`if(${this.condition})`+super.render(t);return this.else&&(n+="else "+this.else.render(t)),n}optimizeNodes(){super.optimizeNodes();let t=this.condition;if(t===!0)return this.nodes;let n=this.else;if(n){let o=n.optimizeNodes();n=this.else=Array.isArray(o)?new vo(o):o}if(n)return t===!1?n instanceof e?n:n.nodes:this.nodes.length?this:new e(lb(t),n instanceof e?[n]:n.nodes);if(!(t===!1||!this.nodes.length))return this}optimizeNames(t,n){var o;if(this.else=(o=this.else)===null||o===void 0?void 0:o.optimizeNames(t,n),!!(super.optimizeNames(t,n)||this.else))return this.condition=_o(this.condition,t,n),this}get names(){let t=super.names;return ll(t,this.condition),this.else&&an(t,this.else.names),t}};nn.kind="if";var on=class extends or{};on.kind="for";var pm=class extends on{constructor(t){super(),this.iteration=t}render(t){return`for(${this.iteration})`+super.render(t)}optimizeNames(t,n){if(super.optimizeNames(t,n))return this.iteration=_o(this.iteration,t,n),this}get names(){return an(super.names,this.iteration.names)}},mm=class extends on{constructor(t,n,o,r){super(),this.varKind=t,this.name=n,this.from=o,this.to=r}render(t){let n=t.es5?jt.varKinds.var:this.varKind,{name:o,from:r,to:i}=this;return`for(${n} ${o}=${r}; ${o}<${i}; ${o}++)`+super.render(t)}get names(){let t=ll(super.names,this.from);return ll(t,this.to)}},ul=class extends on{constructor(t,n,o,r){super(),this.loop=t,this.varKind=n,this.name=o,this.iterable=r}render(t){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(t)}optimizeNames(t,n){if(super.optimizeNames(t,n))return this.iterable=_o(this.iterable,t,n),this}get names(){return an(super.names,this.iterable.names)}},ca=class extends or{constructor(t,n,o){super(),this.name=t,this.args=n,this.async=o}render(t){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(t)}};ca.kind="func";var ua=class extends sa{render(t){return"return "+super.render(t)}};ua.kind="return";var hm=class extends or{render(t){let n="try"+super.render(t);return this.catch&&(n+=this.catch.render(t)),this.finally&&(n+=this.finally.render(t)),n}optimizeNodes(){var t,n;return super.optimizeNodes(),(t=this.catch)===null||t===void 0||t.optimizeNodes(),(n=this.finally)===null||n===void 0||n.optimizeNodes(),this}optimizeNames(t,n){var o,r;return super.optimizeNames(t,n),(o=this.catch)===null||o===void 0||o.optimizeNames(t,n),(r=this.finally)===null||r===void 0||r.optimizeNames(t,n),this}get names(){let t=super.names;return this.catch&&an(t,this.catch.names),this.finally&&an(t,this.finally.names),t}},la=class extends or{constructor(t){super(),this.error=t}render(t){return`catch(${this.error})`+super.render(t)}};la.kind="catch";var da=class extends or{render(t){return"finally"+super.render(t)}};da.kind="finally";var gm=class{constructor(t,n={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...n,_n:n.lines?`
|
|
5
|
-
`:""},this._extScope=t,this._scope=new jt.Scope({parent:t}),this._nodes=[new fm]}toString(){return this._root.render(this.opts)}name(t){return this._scope.name(t)}scopeName(t){return this._extScope.name(t)}scopeValue(t,n){let o=this._extScope.value(t,n);return(this._values[o.prefix]||(this._values[o.prefix]=new Set)).add(o),o}getScopeValue(t,n){return this._extScope.getValue(t,n)}scopeRefs(t){return this._extScope.scopeRefs(t,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(t,n,o,r){let i=this._scope.toName(n);return o!==void 0&&r&&(this._constants[i.str]=o),this._leafNode(new am(t,i,o)),i}const(t,n,o){return this._def(jt.varKinds.const,t,n,o)}let(t,n,o){return this._def(jt.varKinds.let,t,n,o)}var(t,n,o){return this._def(jt.varKinds.var,t,n,o)}assign(t,n,o){return this._leafNode(new cl(t,n,o))}add(t,n){return this._leafNode(new sm(t,oe.operators.ADD,n))}code(t){return typeof t=="function"?t():t!==le.nil&&this._leafNode(new dm(t)),this}object(...t){let n=["{"];for(let[o,r]of t)n.length>1&&n.push(","),n.push(o),(o!==r||this.opts.es5)&&(n.push(":"),(0,le.addCodeArg)(n,r));return n.push("}"),new le._Code(n)}if(t,n,o){if(this._blockNode(new nn(t)),n&&o)this.code(n).else().code(o).endIf();else if(n)this.code(n).endIf();else if(o)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(t){return this._elseNode(new nn(t))}else(){return this._elseNode(new vo)}endIf(){return this._endBlockNode(nn,vo)}_for(t,n){return this._blockNode(t),n&&this.code(n).endFor(),this}for(t,n){return this._for(new pm(t),n)}forRange(t,n,o,r,i=this.opts.es5?jt.varKinds.var:jt.varKinds.let){let a=this._scope.toName(t);return this._for(new mm(i,a,n,o),()=>r(a))}forOf(t,n,o,r=jt.varKinds.const){let i=this._scope.toName(t);if(this.opts.es5){let a=n instanceof le.Name?n:this.var("_arr",n);return this.forRange("_i",0,(0,le._)`${a}.length`,s=>{this.var(i,(0,le._)`${a}[${s}]`),o(i)})}return this._for(new ul("of",r,i,n),()=>o(i))}forIn(t,n,o,r=this.opts.es5?jt.varKinds.var:jt.varKinds.const){if(this.opts.ownProperties)return this.forOf(t,(0,le._)`Object.keys(${n})`,o);let i=this._scope.toName(t);return this._for(new ul("in",r,i,n),()=>o(i))}endFor(){return this._endBlockNode(on)}label(t){return this._leafNode(new cm(t))}break(t){return this._leafNode(new um(t))}return(t){let n=new ua;if(this._blockNode(n),this.code(t),n.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(ua)}try(t,n,o){if(!n&&!o)throw new Error('CodeGen: "try" without "catch" and "finally"');let r=new hm;if(this._blockNode(r),this.code(t),n){let i=this.name("e");this._currNode=r.catch=new la(i),n(i)}return o&&(this._currNode=r.finally=new da,this.code(o)),this._endBlockNode(la,da)}throw(t){return this._leafNode(new lm(t))}block(t,n){return this._blockStarts.push(this._nodes.length),t&&this.code(t).endBlock(n),this}endBlock(t){let n=this._blockStarts.pop();if(n===void 0)throw new Error("CodeGen: not in self-balancing block");let o=this._nodes.length-n;if(o<0||t!==void 0&&o!==t)throw new Error(`CodeGen: wrong number of nodes: ${o} vs ${t} expected`);return this._nodes.length=n,this}func(t,n=le.nil,o,r){return this._blockNode(new ca(t,n,o)),r&&this.code(r).endFunc(),this}endFunc(){return this._endBlockNode(ca)}optimize(t=1){for(;t-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(t){return this._currNode.nodes.push(t),this}_blockNode(t){this._currNode.nodes.push(t),this._nodes.push(t)}_endBlockNode(t,n){let o=this._currNode;if(o instanceof t||n&&o instanceof n)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${n?`${t.kind}/${n.kind}`:t.kind}"`)}_elseNode(t){let n=this._currNode;if(!(n instanceof nn))throw new Error('CodeGen: "else" without "if"');return this._currNode=n.else=t,this}get _root(){return this._nodes[0]}get _currNode(){let t=this._nodes;return t[t.length-1]}set _currNode(t){let n=this._nodes;n[n.length-1]=t}};oe.CodeGen=gm;function an(e,t){for(let n in t)e[n]=(e[n]||0)+(t[n]||0);return e}function ll(e,t){return t instanceof le._CodeOrName?an(e,t.names):e}function _o(e,t,n){if(e instanceof le.Name)return o(e);if(!r(e))return e;return new le._Code(e._items.reduce((i,a)=>(a instanceof le.Name&&(a=o(a)),a instanceof le._Code?i.push(...a._items):i.push(a),i),[]));function o(i){let a=n[i.str];return a===void 0||t[i.str]!==1?i:(delete t[i.str],a)}function r(i){return i instanceof le._Code&&i._items.some(a=>a instanceof le.Name&&t[a.str]===1&&n[a.str]!==void 0)}}function WP(e,t){for(let n in t)e[n]=(e[n]||0)-(t[n]||0)}function lb(e){return typeof e=="boolean"||typeof e=="number"||e===null?!e:(0,le._)`!${vm(e)}`}oe.not=lb;var XP=db(oe.operators.AND);function YP(...e){return e.reduce(XP)}oe.and=YP;var QP=db(oe.operators.OR);function eO(...e){return e.reduce(QP)}oe.or=eO;function db(e){return(t,n)=>t===le.nil?n:n===le.nil?t:(0,le._)`${vm(t)} ${e} ${vm(n)}`}function vm(e){return e instanceof le.Name?e:(0,le._)`(${e})`}});var fe=A(ae=>{"use strict";Object.defineProperty(ae,"__esModule",{value:!0});ae.checkStrictMode=ae.getErrorPath=ae.Type=ae.useFunc=ae.setEvaluated=ae.evaluatedPropsToName=ae.mergeEvaluated=ae.eachItem=ae.unescapeJsonPointer=ae.escapeJsonPointer=ae.escapeFragment=ae.unescapeFragment=ae.schemaRefOrVal=ae.schemaHasRulesButRef=ae.schemaHasRules=ae.checkUnknownRules=ae.alwaysValidSchema=ae.toHash=void 0;var be=re(),tO=aa();function rO(e){let t={};for(let n of e)t[n]=!0;return t}ae.toHash=rO;function nO(e,t){return typeof t=="boolean"?t:Object.keys(t).length===0?!0:(mb(e,t),!hb(t,e.self.RULES.all))}ae.alwaysValidSchema=nO;function mb(e,t=e.schema){let{opts:n,self:o}=e;if(!n.strictSchema||typeof t=="boolean")return;let r=o.RULES.keywords;for(let i in t)r[i]||_b(e,`unknown keyword: "${i}"`)}ae.checkUnknownRules=mb;function hb(e,t){if(typeof e=="boolean")return!e;for(let n in e)if(t[n])return!0;return!1}ae.schemaHasRules=hb;function oO(e,t){if(typeof e=="boolean")return!e;for(let n in e)if(n!=="$ref"&&t.all[n])return!0;return!1}ae.schemaHasRulesButRef=oO;function iO({topSchemaRef:e,schemaPath:t},n,o,r){if(!r){if(typeof n=="number"||typeof n=="boolean")return n;if(typeof n=="string")return(0,be._)`${n}`}return(0,be._)`${e}${t}${(0,be.getProperty)(o)}`}ae.schemaRefOrVal=iO;function aO(e){return gb(decodeURIComponent(e))}ae.unescapeFragment=aO;function sO(e){return encodeURIComponent(ym(e))}ae.escapeFragment=sO;function ym(e){return typeof e=="number"?`${e}`:e.replace(/~/g,"~0").replace(/\//g,"~1")}ae.escapeJsonPointer=ym;function gb(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}ae.unescapeJsonPointer=gb;function cO(e,t){if(Array.isArray(e))for(let n of e)t(n);else t(e)}ae.eachItem=cO;function fb({mergeNames:e,mergeToName:t,mergeValues:n,resultToName:o}){return(r,i,a,s)=>{let c=a===void 0?i:a instanceof be.Name?(i instanceof be.Name?e(r,i,a):t(r,i,a),a):i instanceof be.Name?(t(r,a,i),i):n(i,a);return s===be.Name&&!(c instanceof be.Name)?o(r,c):c}}ae.mergeEvaluated={props:fb({mergeNames:(e,t,n)=>e.if((0,be._)`${n} !== true && ${t} !== undefined`,()=>{e.if((0,be._)`${t} === true`,()=>e.assign(n,!0),()=>e.assign(n,(0,be._)`${n} || {}`).code((0,be._)`Object.assign(${n}, ${t})`))}),mergeToName:(e,t,n)=>e.if((0,be._)`${n} !== true`,()=>{t===!0?e.assign(n,!0):(e.assign(n,(0,be._)`${n} || {}`),bm(e,n,t))}),mergeValues:(e,t)=>e===!0?!0:{...e,...t},resultToName:vb}),items:fb({mergeNames:(e,t,n)=>e.if((0,be._)`${n} !== true && ${t} !== undefined`,()=>e.assign(n,(0,be._)`${t} === true ? true : ${n} > ${t} ? ${n} : ${t}`)),mergeToName:(e,t,n)=>e.if((0,be._)`${n} !== true`,()=>e.assign(n,t===!0?!0:(0,be._)`${n} > ${t} ? ${n} : ${t}`)),mergeValues:(e,t)=>e===!0?!0:Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})};function vb(e,t){if(t===!0)return e.var("props",!0);let n=e.var("props",(0,be._)`{}`);return t!==void 0&&bm(e,n,t),n}ae.evaluatedPropsToName=vb;function bm(e,t,n){Object.keys(n).forEach(o=>e.assign((0,be._)`${t}${(0,be.getProperty)(o)}`,!0))}ae.setEvaluated=bm;var pb={};function uO(e,t){return e.scopeValue("func",{ref:t,code:pb[t.code]||(pb[t.code]=new tO._Code(t.code))})}ae.useFunc=uO;var _m;(function(e){e[e.Num=0]="Num",e[e.Str=1]="Str"})(_m||(ae.Type=_m={}));function lO(e,t,n){if(e instanceof be.Name){let o=t===_m.Num;return n?o?(0,be._)`"[" + ${e} + "]"`:(0,be._)`"['" + ${e} + "']"`:o?(0,be._)`"/" + ${e}`:(0,be._)`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return n?(0,be.getProperty)(e).toString():"/"+ym(e)}ae.getErrorPath=lO;function _b(e,t,n=e.opts.strictSchema){if(n){if(t=`strict mode: ${t}`,n===!0)throw new Error(t);e.self.logger.warn(t)}}ae.checkStrictMode=_b});var ir=A($m=>{"use strict";Object.defineProperty($m,"__esModule",{value:!0});var Ke=re(),dO={data:new Ke.Name("data"),valCxt:new Ke.Name("valCxt"),instancePath:new Ke.Name("instancePath"),parentData:new Ke.Name("parentData"),parentDataProperty:new Ke.Name("parentDataProperty"),rootData:new Ke.Name("rootData"),dynamicAnchors:new Ke.Name("dynamicAnchors"),vErrors:new Ke.Name("vErrors"),errors:new Ke.Name("errors"),this:new Ke.Name("this"),self:new Ke.Name("self"),scope:new Ke.Name("scope"),json:new Ke.Name("json"),jsonPos:new Ke.Name("jsonPos"),jsonLen:new Ke.Name("jsonLen"),jsonPart:new Ke.Name("jsonPart")};$m.default=dO});var fa=A(He=>{"use strict";Object.defineProperty(He,"__esModule",{value:!0});He.extendErrors=He.resetErrorsCount=He.reportExtraError=He.reportError=He.keyword$DataError=He.keywordError=void 0;var pe=re(),fl=fe(),Xe=ir();He.keywordError={message:({keyword:e})=>(0,pe.str)`must pass "${e}" keyword validation`};He.keyword$DataError={message:({keyword:e,schemaType:t})=>t?(0,pe.str)`"${e}" keyword must be ${t} ($data)`:(0,pe.str)`"${e}" keyword is invalid ($data)`};function fO(e,t=He.keywordError,n,o){let{it:r}=e,{gen:i,compositeRule:a,allErrors:s}=r,c=$b(e,t,n);o??(a||s)?yb(i,c):bb(r,(0,pe._)`[${c}]`)}He.reportError=fO;function pO(e,t=He.keywordError,n){let{it:o}=e,{gen:r,compositeRule:i,allErrors:a}=o,s=$b(e,t,n);yb(r,s),i||a||bb(o,Xe.default.vErrors)}He.reportExtraError=pO;function mO(e,t){e.assign(Xe.default.errors,t),e.if((0,pe._)`${Xe.default.vErrors} !== null`,()=>e.if(t,()=>e.assign((0,pe._)`${Xe.default.vErrors}.length`,t),()=>e.assign(Xe.default.vErrors,null)))}He.resetErrorsCount=mO;function hO({gen:e,keyword:t,schemaValue:n,data:o,errsCount:r,it:i}){if(r===void 0)throw new Error("ajv implementation error");let a=e.name("err");e.forRange("i",r,Xe.default.errors,s=>{e.const(a,(0,pe._)`${Xe.default.vErrors}[${s}]`),e.if((0,pe._)`${a}.instancePath === undefined`,()=>e.assign((0,pe._)`${a}.instancePath`,(0,pe.strConcat)(Xe.default.instancePath,i.errorPath))),e.assign((0,pe._)`${a}.schemaPath`,(0,pe.str)`${i.errSchemaPath}/${t}`),i.opts.verbose&&(e.assign((0,pe._)`${a}.schema`,n),e.assign((0,pe._)`${a}.data`,o))})}He.extendErrors=hO;function yb(e,t){let n=e.const("err",t);e.if((0,pe._)`${Xe.default.vErrors} === null`,()=>e.assign(Xe.default.vErrors,(0,pe._)`[${n}]`),(0,pe._)`${Xe.default.vErrors}.push(${n})`),e.code((0,pe._)`${Xe.default.errors}++`)}function bb(e,t){let{gen:n,validateName:o,schemaEnv:r}=e;r.$async?n.throw((0,pe._)`new ${e.ValidationError}(${t})`):(n.assign((0,pe._)`${o}.errors`,t),n.return(!1))}var sn={keyword:new pe.Name("keyword"),schemaPath:new pe.Name("schemaPath"),params:new pe.Name("params"),propertyName:new pe.Name("propertyName"),message:new pe.Name("message"),schema:new pe.Name("schema"),parentSchema:new pe.Name("parentSchema")};function $b(e,t,n){let{createErrors:o}=e.it;return o===!1?(0,pe._)`{}`:gO(e,t,n)}function gO(e,t,n={}){let{gen:o,it:r}=e,i=[vO(r,n),_O(e,n)];return yO(e,t,i),o.object(...i)}function vO({errorPath:e},{instancePath:t}){let n=t?(0,pe.str)`${e}${(0,fl.getErrorPath)(t,fl.Type.Str)}`:e;return[Xe.default.instancePath,(0,pe.strConcat)(Xe.default.instancePath,n)]}function _O({keyword:e,it:{errSchemaPath:t}},{schemaPath:n,parentSchema:o}){let r=o?t:(0,pe.str)`${t}/${e}`;return n&&(r=(0,pe.str)`${r}${(0,fl.getErrorPath)(n,fl.Type.Str)}`),[sn.schemaPath,r]}function yO(e,{params:t,message:n},o){let{keyword:r,data:i,schemaValue:a,it:s}=e,{opts:c,propertyName:l,topSchemaRef:d,schemaPath:f}=s;o.push([sn.keyword,r],[sn.params,typeof t=="function"?t(e):t||(0,pe._)`{}`]),c.messages&&o.push([sn.message,typeof n=="function"?n(e):n]),c.verbose&&o.push([sn.schema,a],[sn.parentSchema,(0,pe._)`${d}${f}`],[Xe.default.data,i]),l&&o.push([sn.propertyName,l])}});var wb=A(yo=>{"use strict";Object.defineProperty(yo,"__esModule",{value:!0});yo.boolOrEmptySchema=yo.topBoolOrEmptySchema=void 0;var bO=fa(),$O=re(),xO=ir(),wO={message:"boolean schema is false"};function kO(e){let{gen:t,schema:n,validateName:o}=e;n===!1?xb(e,!1):typeof n=="object"&&n.$async===!0?t.return(xO.default.data):(t.assign((0,$O._)`${o}.errors`,null),t.return(!0))}yo.topBoolOrEmptySchema=kO;function SO(e,t){let{gen:n,schema:o}=e;o===!1?(n.var(t,!1),xb(e)):n.var(t,!0)}yo.boolOrEmptySchema=SO;function xb(e,t){let{gen:n,data:o}=e,r={gen:n,keyword:"false schema",data:o,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e};(0,bO.reportError)(r,wO,void 0,t)}});var xm=A(bo=>{"use strict";Object.defineProperty(bo,"__esModule",{value:!0});bo.getRules=bo.isJSONType=void 0;var zO=["string","number","integer","boolean","null","object","array"],IO=new Set(zO);function EO(e){return typeof e=="string"&&IO.has(e)}bo.isJSONType=EO;function TO(){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:{}}}bo.getRules=TO});var wm=A(jr=>{"use strict";Object.defineProperty(jr,"__esModule",{value:!0});jr.shouldUseRule=jr.shouldUseGroup=jr.schemaHasRulesForType=void 0;function PO({schema:e,self:t},n){let o=t.RULES.types[n];return o&&o!==!0&&kb(e,o)}jr.schemaHasRulesForType=PO;function kb(e,t){return t.rules.some(n=>Sb(e,n))}jr.shouldUseGroup=kb;function Sb(e,t){var n;return e[t.keyword]!==void 0||((n=t.definition.implements)===null||n===void 0?void 0:n.some(o=>e[o]!==void 0))}jr.shouldUseRule=Sb});var pa=A(Je=>{"use strict";Object.defineProperty(Je,"__esModule",{value:!0});Je.reportTypeError=Je.checkDataTypes=Je.checkDataType=Je.coerceAndCheckDataType=Je.getJSONTypes=Je.getSchemaTypes=Je.DataType=void 0;var OO=xm(),jO=wm(),NO=fa(),ee=re(),zb=fe(),$o;(function(e){e[e.Correct=0]="Correct",e[e.Wrong=1]="Wrong"})($o||(Je.DataType=$o={}));function RO(e){let t=Ib(e.type);if(t.includes("null")){if(e.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!t.length&&e.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');e.nullable===!0&&t.push("null")}return t}Je.getSchemaTypes=RO;function Ib(e){let t=Array.isArray(e)?e:e?[e]:[];if(t.every(OO.isJSONType))return t;throw new Error("type must be JSONType or JSONType[]: "+t.join(","))}Je.getJSONTypes=Ib;function AO(e,t){let{gen:n,data:o,opts:r}=e,i=DO(t,r.coerceTypes),a=t.length>0&&!(i.length===0&&t.length===1&&(0,jO.schemaHasRulesForType)(e,t[0]));if(a){let s=Sm(t,o,r.strictNumbers,$o.Wrong);n.if(s,()=>{i.length?CO(e,t,i):zm(e)})}return a}Je.coerceAndCheckDataType=AO;var Eb=new Set(["string","number","integer","boolean","null"]);function DO(e,t){return t?e.filter(n=>Eb.has(n)||t==="array"&&n==="array"):[]}function CO(e,t,n){let{gen:o,data:r,opts:i}=e,a=o.let("dataType",(0,ee._)`typeof ${r}`),s=o.let("coerced",(0,ee._)`undefined`);i.coerceTypes==="array"&&o.if((0,ee._)`${a} == 'object' && Array.isArray(${r}) && ${r}.length == 1`,()=>o.assign(r,(0,ee._)`${r}[0]`).assign(a,(0,ee._)`typeof ${r}`).if(Sm(t,r,i.strictNumbers),()=>o.assign(s,r))),o.if((0,ee._)`${s} !== undefined`);for(let l of n)(Eb.has(l)||l==="array"&&i.coerceTypes==="array")&&c(l);o.else(),zm(e),o.endIf(),o.if((0,ee._)`${s} !== undefined`,()=>{o.assign(r,s),UO(e,s)});function c(l){switch(l){case"string":o.elseIf((0,ee._)`${a} == "number" || ${a} == "boolean"`).assign(s,(0,ee._)`"" + ${r}`).elseIf((0,ee._)`${r} === null`).assign(s,(0,ee._)`""`);return;case"number":o.elseIf((0,ee._)`${a} == "boolean" || ${r} === null
|
|
2
|
+
"use strict";var CS=Object.create;var $d=Object.defineProperty;var US=Object.getOwnPropertyDescriptor;var ZS=Object.getOwnPropertyNames;var MS=Object.getPrototypeOf,LS=Object.prototype.hasOwnProperty;var A=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Fr=(e,t)=>{for(var n in t)$d(e,n,{get:t[n],enumerable:!0})},qS=(e,t,n,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of ZS(t))!LS.call(e,r)&&r!==n&&$d(e,r,{get:()=>t[r],enumerable:!(o=US(t,r))||o.enumerable});return e};var ht=(e,t,n)=>(n=e!=null?CS(MS(e)):{},qS(t||!e||!e.__esModule?$d(n,"default",{value:e,enumerable:!0}):n,e));var Zg=A((uD,VS)=>{VS.exports={name:"dotenv",version:"16.6.1",description:"Loads environment variables from .env file",main:"lib/main.js",types:"lib/main.d.ts",exports:{".":{types:"./lib/main.d.ts",require:"./lib/main.js",default:"./lib/main.js"},"./config":"./config.js","./config.js":"./config.js","./lib/env-options":"./lib/env-options.js","./lib/env-options.js":"./lib/env-options.js","./lib/cli-options":"./lib/cli-options.js","./lib/cli-options.js":"./lib/cli-options.js","./package.json":"./package.json"},scripts:{"dts-check":"tsc --project tests/types/tsconfig.json",lint:"standard",pretest:"npm run lint && npm run dts-check",test:"tap run --allow-empty-coverage --disable-coverage --timeout=60000","test:coverage":"tap run --show-full-coverage --timeout=60000 --coverage-report=text --coverage-report=lcov",prerelease:"npm test",release:"standard-version"},repository:{type:"git",url:"git://github.com/motdotla/dotenv.git"},homepage:"https://github.com/motdotla/dotenv#readme",funding:"https://dotenvx.com",keywords:["dotenv","env",".env","environment","variables","config","settings"],readmeFilename:"README.md",license:"BSD-2-Clause",devDependencies:{"@types/node":"^18.11.3",decache:"^4.6.2",sinon:"^14.0.1",standard:"^17.0.0","standard-version":"^9.5.0",tap:"^19.2.0",typescript:"^4.8.4"},engines:{node:">=12"},browser:{fs:!1}}});var Fg=A((lD,Wt)=>{var xd=require("fs"),Wa=require("path"),FS=require("os"),BS=require("crypto"),KS=Zg(),wd=KS.version,HS=/(?:^|^)\s*(?:export\s+)?([\w.-]+)(?:\s*=\s*?|:\s+?)(\s*'(?:\\'|[^'])*'|\s*"(?:\\"|[^"])*"|\s*`(?:\\`|[^`])*`|[^#\r\n]+)?\s*(?:#.*)?(?:$|$)/mg;function JS(e){let t={},n=e.toString();n=n.replace(/\r\n?/mg,`
|
|
3
|
+
`);let o;for(;(o=HS.exec(n))!=null;){let r=o[1],i=o[2]||"";i=i.trim();let a=i[0];i=i.replace(/^(['"`])([\s\S]*)\1$/mg,"$2"),a==='"'&&(i=i.replace(/\\n/g,`
|
|
4
|
+
`),i=i.replace(/\\r/g,"\r")),t[r]=i}return t}function GS(e){e=e||{};let t=Vg(e);e.path=t;let n=Pe.configDotenv(e);if(!n.parsed){let a=new Error(`MISSING_DATA: Cannot parse ${t} for an unknown reason`);throw a.code="MISSING_DATA",a}let o=qg(e).split(","),r=o.length,i;for(let a=0;a<r;a++)try{let s=o[a].trim(),c=XS(n,s);i=Pe.decrypt(c.ciphertext,c.key);break}catch(s){if(a+1>=r)throw s}return Pe.parse(i)}function WS(e){console.log(`[dotenv@${wd}][WARN] ${e}`)}function Zo(e){console.log(`[dotenv@${wd}][DEBUG] ${e}`)}function Lg(e){console.log(`[dotenv@${wd}] ${e}`)}function qg(e){return e&&e.DOTENV_KEY&&e.DOTENV_KEY.length>0?e.DOTENV_KEY:process.env.DOTENV_KEY&&process.env.DOTENV_KEY.length>0?process.env.DOTENV_KEY:""}function XS(e,t){let n;try{n=new URL(t)}catch(s){if(s.code==="ERR_INVALID_URL"){let c=new Error("INVALID_DOTENV_KEY: Wrong format. Must be in valid uri format like dotenv://:key_1234@dotenvx.com/vault/.env.vault?environment=development");throw c.code="INVALID_DOTENV_KEY",c}throw s}let o=n.password;if(!o){let s=new Error("INVALID_DOTENV_KEY: Missing key part");throw s.code="INVALID_DOTENV_KEY",s}let r=n.searchParams.get("environment");if(!r){let s=new Error("INVALID_DOTENV_KEY: Missing environment part");throw s.code="INVALID_DOTENV_KEY",s}let i=`DOTENV_VAULT_${r.toUpperCase()}`,a=e.parsed[i];if(!a){let s=new Error(`NOT_FOUND_DOTENV_ENVIRONMENT: Cannot locate environment ${i} in your .env.vault file.`);throw s.code="NOT_FOUND_DOTENV_ENVIRONMENT",s}return{ciphertext:a,key:o}}function Vg(e){let t=null;if(e&&e.path&&e.path.length>0)if(Array.isArray(e.path))for(let n of e.path)xd.existsSync(n)&&(t=n.endsWith(".vault")?n:`${n}.vault`);else t=e.path.endsWith(".vault")?e.path:`${e.path}.vault`;else t=Wa.resolve(process.cwd(),".env.vault");return xd.existsSync(t)?t:null}function Mg(e){return e[0]==="~"?Wa.join(FS.homedir(),e.slice(1)):e}function YS(e){let t=!!(e&&e.debug),n=e&&"quiet"in e?e.quiet:!0;(t||!n)&&Lg("Loading env from encrypted .env.vault");let o=Pe._parseVault(e),r=process.env;return e&&e.processEnv!=null&&(r=e.processEnv),Pe.populate(r,o,e),{parsed:o}}function QS(e){let t=Wa.resolve(process.cwd(),".env"),n="utf8",o=!!(e&&e.debug),r=e&&"quiet"in e?e.quiet:!0;e&&e.encoding?n=e.encoding:o&&Zo("No encoding is specified. UTF-8 is used by default");let i=[t];if(e&&e.path)if(!Array.isArray(e.path))i=[Mg(e.path)];else{i=[];for(let l of e.path)i.push(Mg(l))}let a,s={};for(let l of i)try{let d=Pe.parse(xd.readFileSync(l,{encoding:n}));Pe.populate(s,d,e)}catch(d){o&&Zo(`Failed to load ${l} ${d.message}`),a=d}let c=process.env;if(e&&e.processEnv!=null&&(c=e.processEnv),Pe.populate(c,s,e),o||!r){let l=Object.keys(s).length,d=[];for(let f of i)try{let _=Wa.relative(process.cwd(),f);d.push(_)}catch(_){o&&Zo(`Failed to load ${f} ${_.message}`),a=_}Lg(`injecting env (${l}) from ${d.join(",")}`)}return a?{parsed:s,error:a}:{parsed:s}}function e0(e){if(qg(e).length===0)return Pe.configDotenv(e);let t=Vg(e);return t?Pe._configVault(e):(WS(`You set DOTENV_KEY but you are missing a .env.vault file at ${t}. Did you forget to build it?`),Pe.configDotenv(e))}function t0(e,t){let n=Buffer.from(t.slice(-64),"hex"),o=Buffer.from(e,"base64"),r=o.subarray(0,12),i=o.subarray(-16);o=o.subarray(12,-16);try{let a=BS.createDecipheriv("aes-256-gcm",n,r);return a.setAuthTag(i),`${a.update(o)}${a.final()}`}catch(a){let s=a instanceof RangeError,c=a.message==="Invalid key length",l=a.message==="Unsupported state or unable to authenticate data";if(s||c){let d=new Error("INVALID_DOTENV_KEY: It must be 64 characters long (or more)");throw d.code="INVALID_DOTENV_KEY",d}else if(l){let d=new Error("DECRYPTION_FAILED: Please check your DOTENV_KEY");throw d.code="DECRYPTION_FAILED",d}else throw a}}function r0(e,t,n={}){let o=!!(n&&n.debug),r=!!(n&&n.override);if(typeof t!="object"){let i=new Error("OBJECT_REQUIRED: Please check the processEnv argument being passed to populate");throw i.code="OBJECT_REQUIRED",i}for(let i of Object.keys(t))Object.prototype.hasOwnProperty.call(e,i)?(r===!0&&(e[i]=t[i]),o&&Zo(r===!0?`"${i}" is already defined and WAS overwritten`:`"${i}" is already defined and was NOT overwritten`)):e[i]=t[i]}var Pe={configDotenv:QS,_configVault:YS,_parseVault:GS,config:e0,decrypt:t0,parse:JS,populate:r0};Wt.exports.configDotenv=Pe.configDotenv;Wt.exports._configVault=Pe._configVault;Wt.exports._parseVault=Pe._parseVault;Wt.exports.config=Pe.config;Wt.exports.decrypt=Pe.decrypt;Wt.exports.parse=Pe.parse;Wt.exports.populate=Pe.populate;Wt.exports=Pe});var aa=A(me=>{"use strict";Object.defineProperty(me,"__esModule",{value:!0});me.regexpCode=me.getEsmExportName=me.getProperty=me.safeStringify=me.stringify=me.strConcat=me.addCodeArg=me.str=me._=me.nil=me._Code=me.Name=me.IDENTIFIER=me._CodeOrName=void 0;var oa=class{};me._CodeOrName=oa;me.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var rn=class extends oa{constructor(t){if(super(),!me.IDENTIFIER.test(t))throw new Error("CodeGen: name must be a valid identifier");this.str=t}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}};me.Name=rn;var bt=class extends oa{constructor(t){super(),this._items=typeof t=="string"?[t]:t}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;let t=this._items[0];return t===""||t==='""'}get str(){var t;return(t=this._str)!==null&&t!==void 0?t:this._str=this._items.reduce((n,o)=>`${n}${o}`,"")}get names(){var t;return(t=this._names)!==null&&t!==void 0?t:this._names=this._items.reduce((n,o)=>(o instanceof rn&&(n[o.str]=(n[o.str]||0)+1),n),{})}};me._Code=bt;me.nil=new bt("");function db(e,...t){let n=[e[0]],o=0;for(;o<t.length;)om(n,t[o]),n.push(e[++o]);return new bt(n)}me._=db;var nm=new bt("+");function fb(e,...t){let n=[ia(e[0])],o=0;for(;o<t.length;)n.push(nm),om(n,t[o]),n.push(nm,ia(e[++o]));return GO(n),new bt(n)}me.str=fb;function om(e,t){t instanceof bt?e.push(...t._items):t instanceof rn?e.push(t):e.push(YO(t))}me.addCodeArg=om;function GO(e){let t=1;for(;t<e.length-1;){if(e[t]===nm){let n=WO(e[t-1],e[t+1]);if(n!==void 0){e.splice(t-1,3,n);continue}e[t++]="+"}t++}}function WO(e,t){if(t==='""')return e;if(e==='""')return t;if(typeof e=="string")return t instanceof rn||e[e.length-1]!=='"'?void 0:typeof t!="string"?`${e.slice(0,-1)}${t}"`:t[0]==='"'?e.slice(0,-1)+t.slice(1):void 0;if(typeof t=="string"&&t[0]==='"'&&!(e instanceof rn))return`"${e}${t.slice(1)}`}function XO(e,t){return t.emptyStr()?e:e.emptyStr()?t:fb`${e}${t}`}me.strConcat=XO;function YO(e){return typeof e=="number"||typeof e=="boolean"||e===null?e:ia(Array.isArray(e)?e.join(","):e)}function QO(e){return new bt(ia(e))}me.stringify=QO;function ia(e){return JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}me.safeStringify=ia;function eP(e){return typeof e=="string"&&me.IDENTIFIER.test(e)?new bt(`.${e}`):db`[${e}]`}me.getProperty=eP;function tP(e){if(typeof e=="string"&&me.IDENTIFIER.test(e))return new bt(`${e}`);throw new Error(`CodeGen: invalid export name: ${e}, use explicit $id name mapping`)}me.getEsmExportName=tP;function rP(e){return new bt(e.toString())}me.regexpCode=rP});var sm=A(it=>{"use strict";Object.defineProperty(it,"__esModule",{value:!0});it.ValueScope=it.ValueScopeName=it.Scope=it.varKinds=it.UsedValueState=void 0;var ot=aa(),im=class extends Error{constructor(t){super(`CodeGen: "code" for ${t} not defined`),this.value=t.value}},al;(function(e){e[e.Started=0]="Started",e[e.Completed=1]="Completed"})(al||(it.UsedValueState=al={}));it.varKinds={const:new ot.Name("const"),let:new ot.Name("let"),var:new ot.Name("var")};var sl=class{constructor({prefixes:t,parent:n}={}){this._names={},this._prefixes=t,this._parent=n}toName(t){return t instanceof ot.Name?t:this.name(t)}name(t){return new ot.Name(this._newName(t))}_newName(t){let n=this._names[t]||this._nameGroup(t);return`${t}${n.index++}`}_nameGroup(t){var n,o;if(!((o=(n=this._parent)===null||n===void 0?void 0:n._prefixes)===null||o===void 0)&&o.has(t)||this._prefixes&&!this._prefixes.has(t))throw new Error(`CodeGen: prefix "${t}" is not allowed in this scope`);return this._names[t]={prefix:t,index:0}}};it.Scope=sl;var cl=class extends ot.Name{constructor(t,n){super(n),this.prefix=t}setValue(t,{property:n,itemIndex:o}){this.value=t,this.scopePath=(0,ot._)`.${new ot.Name(n)}[${o}]`}};it.ValueScopeName=cl;var nP=(0,ot._)`\n`,am=class extends sl{constructor(t){super(t),this._values={},this._scope=t.scope,this.opts={...t,_n:t.lines?nP:ot.nil}}get(){return this._scope}name(t){return new cl(t,this._newName(t))}value(t,n){var o;if(n.ref===void 0)throw new Error("CodeGen: ref must be passed in value");let r=this.toName(t),{prefix:i}=r,a=(o=n.key)!==null&&o!==void 0?o:n.ref,s=this._values[i];if(s){let d=s.get(a);if(d)return d}else s=this._values[i]=new Map;s.set(a,r);let c=this._scope[i]||(this._scope[i]=[]),l=c.length;return c[l]=n.ref,r.setValue(n,{property:i,itemIndex:l}),r}getValue(t,n){let o=this._values[t];if(o)return o.get(n)}scopeRefs(t,n=this._values){return this._reduceValues(n,o=>{if(o.scopePath===void 0)throw new Error(`CodeGen: name "${o}" has no value`);return(0,ot._)`${t}${o.scopePath}`})}scopeCode(t=this._values,n,o){return this._reduceValues(t,r=>{if(r.value===void 0)throw new Error(`CodeGen: name "${r}" has no value`);return r.value.code},n,o)}_reduceValues(t,n,o={},r){let i=ot.nil;for(let a in t){let s=t[a];if(!s)continue;let c=o[a]=o[a]||new Map;s.forEach(l=>{if(c.has(l))return;c.set(l,al.Started);let d=n(l);if(d){let f=this.opts.es5?it.varKinds.var:it.varKinds.const;i=(0,ot._)`${i}${f} ${l} = ${d};${this.opts._n}`}else if(d=r?.(l))i=(0,ot._)`${i}${d}${this.opts._n}`;else throw new im(l);c.set(l,al.Completed)})}return i}};it.ValueScope=am});var re=A(oe=>{"use strict";Object.defineProperty(oe,"__esModule",{value:!0});oe.or=oe.and=oe.not=oe.CodeGen=oe.operators=oe.varKinds=oe.ValueScopeName=oe.ValueScope=oe.Scope=oe.Name=oe.regexpCode=oe.stringify=oe.getProperty=oe.nil=oe.strConcat=oe.str=oe._=void 0;var le=aa(),jt=sm(),Pr=aa();Object.defineProperty(oe,"_",{enumerable:!0,get:function(){return Pr._}});Object.defineProperty(oe,"str",{enumerable:!0,get:function(){return Pr.str}});Object.defineProperty(oe,"strConcat",{enumerable:!0,get:function(){return Pr.strConcat}});Object.defineProperty(oe,"nil",{enumerable:!0,get:function(){return Pr.nil}});Object.defineProperty(oe,"getProperty",{enumerable:!0,get:function(){return Pr.getProperty}});Object.defineProperty(oe,"stringify",{enumerable:!0,get:function(){return Pr.stringify}});Object.defineProperty(oe,"regexpCode",{enumerable:!0,get:function(){return Pr.regexpCode}});Object.defineProperty(oe,"Name",{enumerable:!0,get:function(){return Pr.Name}});var fl=sm();Object.defineProperty(oe,"Scope",{enumerable:!0,get:function(){return fl.Scope}});Object.defineProperty(oe,"ValueScope",{enumerable:!0,get:function(){return fl.ValueScope}});Object.defineProperty(oe,"ValueScopeName",{enumerable:!0,get:function(){return fl.ValueScopeName}});Object.defineProperty(oe,"varKinds",{enumerable:!0,get:function(){return fl.varKinds}});oe.operators={GT:new le._Code(">"),GTE:new le._Code(">="),LT:new le._Code("<"),LTE:new le._Code("<="),EQ:new le._Code("==="),NEQ:new le._Code("!=="),NOT:new le._Code("!"),OR:new le._Code("||"),AND:new le._Code("&&"),ADD:new le._Code("+")};var nr=class{optimizeNodes(){return this}optimizeNames(t,n){return this}},cm=class extends nr{constructor(t,n,o){super(),this.varKind=t,this.name=n,this.rhs=o}render({es5:t,_n:n}){let o=t?jt.varKinds.var:this.varKind,r=this.rhs===void 0?"":` = ${this.rhs}`;return`${o} ${this.name}${r};`+n}optimizeNames(t,n){if(t[this.name.str])return this.rhs&&(this.rhs=_o(this.rhs,t,n)),this}get names(){return this.rhs instanceof le._CodeOrName?this.rhs.names:{}}},ul=class extends nr{constructor(t,n,o){super(),this.lhs=t,this.rhs=n,this.sideEffects=o}render({_n:t}){return`${this.lhs} = ${this.rhs};`+t}optimizeNames(t,n){if(!(this.lhs instanceof le.Name&&!t[this.lhs.str]&&!this.sideEffects))return this.rhs=_o(this.rhs,t,n),this}get names(){let t=this.lhs instanceof le.Name?{}:{...this.lhs.names};return dl(t,this.rhs)}},um=class extends ul{constructor(t,n,o,r){super(t,o,r),this.op=n}render({_n:t}){return`${this.lhs} ${this.op}= ${this.rhs};`+t}},lm=class extends nr{constructor(t){super(),this.label=t,this.names={}}render({_n:t}){return`${this.label}:`+t}},dm=class extends nr{constructor(t){super(),this.label=t,this.names={}}render({_n:t}){return`break${this.label?` ${this.label}`:""};`+t}},fm=class extends nr{constructor(t){super(),this.error=t}render({_n:t}){return`throw ${this.error};`+t}get names(){return this.error.names}},pm=class extends nr{constructor(t){super(),this.code=t}render({_n:t}){return`${this.code};`+t}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(t,n){return this.code=_o(this.code,t,n),this}get names(){return this.code instanceof le._CodeOrName?this.code.names:{}}},sa=class extends nr{constructor(t=[]){super(),this.nodes=t}render(t){return this.nodes.reduce((n,o)=>n+o.render(t),"")}optimizeNodes(){let{nodes:t}=this,n=t.length;for(;n--;){let o=t[n].optimizeNodes();Array.isArray(o)?t.splice(n,1,...o):o?t[n]=o:t.splice(n,1)}return t.length>0?this:void 0}optimizeNames(t,n){let{nodes:o}=this,r=o.length;for(;r--;){let i=o[r];i.optimizeNames(t,n)||(oP(t,i.names),o.splice(r,1))}return o.length>0?this:void 0}get names(){return this.nodes.reduce((t,n)=>an(t,n.names),{})}},or=class extends sa{render(t){return"{"+t._n+super.render(t)+"}"+t._n}},mm=class extends sa{},vo=class extends or{};vo.kind="else";var nn=class e extends or{constructor(t,n){super(n),this.condition=t}render(t){let n=`if(${this.condition})`+super.render(t);return this.else&&(n+="else "+this.else.render(t)),n}optimizeNodes(){super.optimizeNodes();let t=this.condition;if(t===!0)return this.nodes;let n=this.else;if(n){let o=n.optimizeNodes();n=this.else=Array.isArray(o)?new vo(o):o}if(n)return t===!1?n instanceof e?n:n.nodes:this.nodes.length?this:new e(pb(t),n instanceof e?[n]:n.nodes);if(!(t===!1||!this.nodes.length))return this}optimizeNames(t,n){var o;if(this.else=(o=this.else)===null||o===void 0?void 0:o.optimizeNames(t,n),!!(super.optimizeNames(t,n)||this.else))return this.condition=_o(this.condition,t,n),this}get names(){let t=super.names;return dl(t,this.condition),this.else&&an(t,this.else.names),t}};nn.kind="if";var on=class extends or{};on.kind="for";var hm=class extends on{constructor(t){super(),this.iteration=t}render(t){return`for(${this.iteration})`+super.render(t)}optimizeNames(t,n){if(super.optimizeNames(t,n))return this.iteration=_o(this.iteration,t,n),this}get names(){return an(super.names,this.iteration.names)}},gm=class extends on{constructor(t,n,o,r){super(),this.varKind=t,this.name=n,this.from=o,this.to=r}render(t){let n=t.es5?jt.varKinds.var:this.varKind,{name:o,from:r,to:i}=this;return`for(${n} ${o}=${r}; ${o}<${i}; ${o}++)`+super.render(t)}get names(){let t=dl(super.names,this.from);return dl(t,this.to)}},ll=class extends on{constructor(t,n,o,r){super(),this.loop=t,this.varKind=n,this.name=o,this.iterable=r}render(t){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(t)}optimizeNames(t,n){if(super.optimizeNames(t,n))return this.iterable=_o(this.iterable,t,n),this}get names(){return an(super.names,this.iterable.names)}},ca=class extends or{constructor(t,n,o){super(),this.name=t,this.args=n,this.async=o}render(t){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(t)}};ca.kind="func";var ua=class extends sa{render(t){return"return "+super.render(t)}};ua.kind="return";var vm=class extends or{render(t){let n="try"+super.render(t);return this.catch&&(n+=this.catch.render(t)),this.finally&&(n+=this.finally.render(t)),n}optimizeNodes(){var t,n;return super.optimizeNodes(),(t=this.catch)===null||t===void 0||t.optimizeNodes(),(n=this.finally)===null||n===void 0||n.optimizeNodes(),this}optimizeNames(t,n){var o,r;return super.optimizeNames(t,n),(o=this.catch)===null||o===void 0||o.optimizeNames(t,n),(r=this.finally)===null||r===void 0||r.optimizeNames(t,n),this}get names(){let t=super.names;return this.catch&&an(t,this.catch.names),this.finally&&an(t,this.finally.names),t}},la=class extends or{constructor(t){super(),this.error=t}render(t){return`catch(${this.error})`+super.render(t)}};la.kind="catch";var da=class extends or{render(t){return"finally"+super.render(t)}};da.kind="finally";var _m=class{constructor(t,n={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...n,_n:n.lines?`
|
|
5
|
+
`:""},this._extScope=t,this._scope=new jt.Scope({parent:t}),this._nodes=[new mm]}toString(){return this._root.render(this.opts)}name(t){return this._scope.name(t)}scopeName(t){return this._extScope.name(t)}scopeValue(t,n){let o=this._extScope.value(t,n);return(this._values[o.prefix]||(this._values[o.prefix]=new Set)).add(o),o}getScopeValue(t,n){return this._extScope.getValue(t,n)}scopeRefs(t){return this._extScope.scopeRefs(t,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(t,n,o,r){let i=this._scope.toName(n);return o!==void 0&&r&&(this._constants[i.str]=o),this._leafNode(new cm(t,i,o)),i}const(t,n,o){return this._def(jt.varKinds.const,t,n,o)}let(t,n,o){return this._def(jt.varKinds.let,t,n,o)}var(t,n,o){return this._def(jt.varKinds.var,t,n,o)}assign(t,n,o){return this._leafNode(new ul(t,n,o))}add(t,n){return this._leafNode(new um(t,oe.operators.ADD,n))}code(t){return typeof t=="function"?t():t!==le.nil&&this._leafNode(new pm(t)),this}object(...t){let n=["{"];for(let[o,r]of t)n.length>1&&n.push(","),n.push(o),(o!==r||this.opts.es5)&&(n.push(":"),(0,le.addCodeArg)(n,r));return n.push("}"),new le._Code(n)}if(t,n,o){if(this._blockNode(new nn(t)),n&&o)this.code(n).else().code(o).endIf();else if(n)this.code(n).endIf();else if(o)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(t){return this._elseNode(new nn(t))}else(){return this._elseNode(new vo)}endIf(){return this._endBlockNode(nn,vo)}_for(t,n){return this._blockNode(t),n&&this.code(n).endFor(),this}for(t,n){return this._for(new hm(t),n)}forRange(t,n,o,r,i=this.opts.es5?jt.varKinds.var:jt.varKinds.let){let a=this._scope.toName(t);return this._for(new gm(i,a,n,o),()=>r(a))}forOf(t,n,o,r=jt.varKinds.const){let i=this._scope.toName(t);if(this.opts.es5){let a=n instanceof le.Name?n:this.var("_arr",n);return this.forRange("_i",0,(0,le._)`${a}.length`,s=>{this.var(i,(0,le._)`${a}[${s}]`),o(i)})}return this._for(new ll("of",r,i,n),()=>o(i))}forIn(t,n,o,r=this.opts.es5?jt.varKinds.var:jt.varKinds.const){if(this.opts.ownProperties)return this.forOf(t,(0,le._)`Object.keys(${n})`,o);let i=this._scope.toName(t);return this._for(new ll("in",r,i,n),()=>o(i))}endFor(){return this._endBlockNode(on)}label(t){return this._leafNode(new lm(t))}break(t){return this._leafNode(new dm(t))}return(t){let n=new ua;if(this._blockNode(n),this.code(t),n.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(ua)}try(t,n,o){if(!n&&!o)throw new Error('CodeGen: "try" without "catch" and "finally"');let r=new vm;if(this._blockNode(r),this.code(t),n){let i=this.name("e");this._currNode=r.catch=new la(i),n(i)}return o&&(this._currNode=r.finally=new da,this.code(o)),this._endBlockNode(la,da)}throw(t){return this._leafNode(new fm(t))}block(t,n){return this._blockStarts.push(this._nodes.length),t&&this.code(t).endBlock(n),this}endBlock(t){let n=this._blockStarts.pop();if(n===void 0)throw new Error("CodeGen: not in self-balancing block");let o=this._nodes.length-n;if(o<0||t!==void 0&&o!==t)throw new Error(`CodeGen: wrong number of nodes: ${o} vs ${t} expected`);return this._nodes.length=n,this}func(t,n=le.nil,o,r){return this._blockNode(new ca(t,n,o)),r&&this.code(r).endFunc(),this}endFunc(){return this._endBlockNode(ca)}optimize(t=1){for(;t-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(t){return this._currNode.nodes.push(t),this}_blockNode(t){this._currNode.nodes.push(t),this._nodes.push(t)}_endBlockNode(t,n){let o=this._currNode;if(o instanceof t||n&&o instanceof n)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${n?`${t.kind}/${n.kind}`:t.kind}"`)}_elseNode(t){let n=this._currNode;if(!(n instanceof nn))throw new Error('CodeGen: "else" without "if"');return this._currNode=n.else=t,this}get _root(){return this._nodes[0]}get _currNode(){let t=this._nodes;return t[t.length-1]}set _currNode(t){let n=this._nodes;n[n.length-1]=t}};oe.CodeGen=_m;function an(e,t){for(let n in t)e[n]=(e[n]||0)+(t[n]||0);return e}function dl(e,t){return t instanceof le._CodeOrName?an(e,t.names):e}function _o(e,t,n){if(e instanceof le.Name)return o(e);if(!r(e))return e;return new le._Code(e._items.reduce((i,a)=>(a instanceof le.Name&&(a=o(a)),a instanceof le._Code?i.push(...a._items):i.push(a),i),[]));function o(i){let a=n[i.str];return a===void 0||t[i.str]!==1?i:(delete t[i.str],a)}function r(i){return i instanceof le._Code&&i._items.some(a=>a instanceof le.Name&&t[a.str]===1&&n[a.str]!==void 0)}}function oP(e,t){for(let n in t)e[n]=(e[n]||0)-(t[n]||0)}function pb(e){return typeof e=="boolean"||typeof e=="number"||e===null?!e:(0,le._)`!${ym(e)}`}oe.not=pb;var iP=mb(oe.operators.AND);function aP(...e){return e.reduce(iP)}oe.and=aP;var sP=mb(oe.operators.OR);function cP(...e){return e.reduce(sP)}oe.or=cP;function mb(e){return(t,n)=>t===le.nil?n:n===le.nil?t:(0,le._)`${ym(t)} ${e} ${ym(n)}`}function ym(e){return e instanceof le.Name?e:(0,le._)`(${e})`}});var fe=A(ae=>{"use strict";Object.defineProperty(ae,"__esModule",{value:!0});ae.checkStrictMode=ae.getErrorPath=ae.Type=ae.useFunc=ae.setEvaluated=ae.evaluatedPropsToName=ae.mergeEvaluated=ae.eachItem=ae.unescapeJsonPointer=ae.escapeJsonPointer=ae.escapeFragment=ae.unescapeFragment=ae.schemaRefOrVal=ae.schemaHasRulesButRef=ae.schemaHasRules=ae.checkUnknownRules=ae.alwaysValidSchema=ae.toHash=void 0;var be=re(),uP=aa();function lP(e){let t={};for(let n of e)t[n]=!0;return t}ae.toHash=lP;function dP(e,t){return typeof t=="boolean"?t:Object.keys(t).length===0?!0:(vb(e,t),!_b(t,e.self.RULES.all))}ae.alwaysValidSchema=dP;function vb(e,t=e.schema){let{opts:n,self:o}=e;if(!n.strictSchema||typeof t=="boolean")return;let r=o.RULES.keywords;for(let i in t)r[i]||$b(e,`unknown keyword: "${i}"`)}ae.checkUnknownRules=vb;function _b(e,t){if(typeof e=="boolean")return!e;for(let n in e)if(t[n])return!0;return!1}ae.schemaHasRules=_b;function fP(e,t){if(typeof e=="boolean")return!e;for(let n in e)if(n!=="$ref"&&t.all[n])return!0;return!1}ae.schemaHasRulesButRef=fP;function pP({topSchemaRef:e,schemaPath:t},n,o,r){if(!r){if(typeof n=="number"||typeof n=="boolean")return n;if(typeof n=="string")return(0,be._)`${n}`}return(0,be._)`${e}${t}${(0,be.getProperty)(o)}`}ae.schemaRefOrVal=pP;function mP(e){return yb(decodeURIComponent(e))}ae.unescapeFragment=mP;function hP(e){return encodeURIComponent($m(e))}ae.escapeFragment=hP;function $m(e){return typeof e=="number"?`${e}`:e.replace(/~/g,"~0").replace(/\//g,"~1")}ae.escapeJsonPointer=$m;function yb(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}ae.unescapeJsonPointer=yb;function gP(e,t){if(Array.isArray(e))for(let n of e)t(n);else t(e)}ae.eachItem=gP;function hb({mergeNames:e,mergeToName:t,mergeValues:n,resultToName:o}){return(r,i,a,s)=>{let c=a===void 0?i:a instanceof be.Name?(i instanceof be.Name?e(r,i,a):t(r,i,a),a):i instanceof be.Name?(t(r,a,i),i):n(i,a);return s===be.Name&&!(c instanceof be.Name)?o(r,c):c}}ae.mergeEvaluated={props:hb({mergeNames:(e,t,n)=>e.if((0,be._)`${n} !== true && ${t} !== undefined`,()=>{e.if((0,be._)`${t} === true`,()=>e.assign(n,!0),()=>e.assign(n,(0,be._)`${n} || {}`).code((0,be._)`Object.assign(${n}, ${t})`))}),mergeToName:(e,t,n)=>e.if((0,be._)`${n} !== true`,()=>{t===!0?e.assign(n,!0):(e.assign(n,(0,be._)`${n} || {}`),xm(e,n,t))}),mergeValues:(e,t)=>e===!0?!0:{...e,...t},resultToName:bb}),items:hb({mergeNames:(e,t,n)=>e.if((0,be._)`${n} !== true && ${t} !== undefined`,()=>e.assign(n,(0,be._)`${t} === true ? true : ${n} > ${t} ? ${n} : ${t}`)),mergeToName:(e,t,n)=>e.if((0,be._)`${n} !== true`,()=>e.assign(n,t===!0?!0:(0,be._)`${n} > ${t} ? ${n} : ${t}`)),mergeValues:(e,t)=>e===!0?!0:Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})};function bb(e,t){if(t===!0)return e.var("props",!0);let n=e.var("props",(0,be._)`{}`);return t!==void 0&&xm(e,n,t),n}ae.evaluatedPropsToName=bb;function xm(e,t,n){Object.keys(n).forEach(o=>e.assign((0,be._)`${t}${(0,be.getProperty)(o)}`,!0))}ae.setEvaluated=xm;var gb={};function vP(e,t){return e.scopeValue("func",{ref:t,code:gb[t.code]||(gb[t.code]=new uP._Code(t.code))})}ae.useFunc=vP;var bm;(function(e){e[e.Num=0]="Num",e[e.Str=1]="Str"})(bm||(ae.Type=bm={}));function _P(e,t,n){if(e instanceof be.Name){let o=t===bm.Num;return n?o?(0,be._)`"[" + ${e} + "]"`:(0,be._)`"['" + ${e} + "']"`:o?(0,be._)`"/" + ${e}`:(0,be._)`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return n?(0,be.getProperty)(e).toString():"/"+$m(e)}ae.getErrorPath=_P;function $b(e,t,n=e.opts.strictSchema){if(n){if(t=`strict mode: ${t}`,n===!0)throw new Error(t);e.self.logger.warn(t)}}ae.checkStrictMode=$b});var ir=A(wm=>{"use strict";Object.defineProperty(wm,"__esModule",{value:!0});var Ke=re(),yP={data:new Ke.Name("data"),valCxt:new Ke.Name("valCxt"),instancePath:new Ke.Name("instancePath"),parentData:new Ke.Name("parentData"),parentDataProperty:new Ke.Name("parentDataProperty"),rootData:new Ke.Name("rootData"),dynamicAnchors:new Ke.Name("dynamicAnchors"),vErrors:new Ke.Name("vErrors"),errors:new Ke.Name("errors"),this:new Ke.Name("this"),self:new Ke.Name("self"),scope:new Ke.Name("scope"),json:new Ke.Name("json"),jsonPos:new Ke.Name("jsonPos"),jsonLen:new Ke.Name("jsonLen"),jsonPart:new Ke.Name("jsonPart")};wm.default=yP});var fa=A(He=>{"use strict";Object.defineProperty(He,"__esModule",{value:!0});He.extendErrors=He.resetErrorsCount=He.reportExtraError=He.reportError=He.keyword$DataError=He.keywordError=void 0;var pe=re(),pl=fe(),Xe=ir();He.keywordError={message:({keyword:e})=>(0,pe.str)`must pass "${e}" keyword validation`};He.keyword$DataError={message:({keyword:e,schemaType:t})=>t?(0,pe.str)`"${e}" keyword must be ${t} ($data)`:(0,pe.str)`"${e}" keyword is invalid ($data)`};function bP(e,t=He.keywordError,n,o){let{it:r}=e,{gen:i,compositeRule:a,allErrors:s}=r,c=kb(e,t,n);o??(a||s)?xb(i,c):wb(r,(0,pe._)`[${c}]`)}He.reportError=bP;function $P(e,t=He.keywordError,n){let{it:o}=e,{gen:r,compositeRule:i,allErrors:a}=o,s=kb(e,t,n);xb(r,s),i||a||wb(o,Xe.default.vErrors)}He.reportExtraError=$P;function xP(e,t){e.assign(Xe.default.errors,t),e.if((0,pe._)`${Xe.default.vErrors} !== null`,()=>e.if(t,()=>e.assign((0,pe._)`${Xe.default.vErrors}.length`,t),()=>e.assign(Xe.default.vErrors,null)))}He.resetErrorsCount=xP;function wP({gen:e,keyword:t,schemaValue:n,data:o,errsCount:r,it:i}){if(r===void 0)throw new Error("ajv implementation error");let a=e.name("err");e.forRange("i",r,Xe.default.errors,s=>{e.const(a,(0,pe._)`${Xe.default.vErrors}[${s}]`),e.if((0,pe._)`${a}.instancePath === undefined`,()=>e.assign((0,pe._)`${a}.instancePath`,(0,pe.strConcat)(Xe.default.instancePath,i.errorPath))),e.assign((0,pe._)`${a}.schemaPath`,(0,pe.str)`${i.errSchemaPath}/${t}`),i.opts.verbose&&(e.assign((0,pe._)`${a}.schema`,n),e.assign((0,pe._)`${a}.data`,o))})}He.extendErrors=wP;function xb(e,t){let n=e.const("err",t);e.if((0,pe._)`${Xe.default.vErrors} === null`,()=>e.assign(Xe.default.vErrors,(0,pe._)`[${n}]`),(0,pe._)`${Xe.default.vErrors}.push(${n})`),e.code((0,pe._)`${Xe.default.errors}++`)}function wb(e,t){let{gen:n,validateName:o,schemaEnv:r}=e;r.$async?n.throw((0,pe._)`new ${e.ValidationError}(${t})`):(n.assign((0,pe._)`${o}.errors`,t),n.return(!1))}var sn={keyword:new pe.Name("keyword"),schemaPath:new pe.Name("schemaPath"),params:new pe.Name("params"),propertyName:new pe.Name("propertyName"),message:new pe.Name("message"),schema:new pe.Name("schema"),parentSchema:new pe.Name("parentSchema")};function kb(e,t,n){let{createErrors:o}=e.it;return o===!1?(0,pe._)`{}`:kP(e,t,n)}function kP(e,t,n={}){let{gen:o,it:r}=e,i=[SP(r,n),zP(e,n)];return IP(e,t,i),o.object(...i)}function SP({errorPath:e},{instancePath:t}){let n=t?(0,pe.str)`${e}${(0,pl.getErrorPath)(t,pl.Type.Str)}`:e;return[Xe.default.instancePath,(0,pe.strConcat)(Xe.default.instancePath,n)]}function zP({keyword:e,it:{errSchemaPath:t}},{schemaPath:n,parentSchema:o}){let r=o?t:(0,pe.str)`${t}/${e}`;return n&&(r=(0,pe.str)`${r}${(0,pl.getErrorPath)(n,pl.Type.Str)}`),[sn.schemaPath,r]}function IP(e,{params:t,message:n},o){let{keyword:r,data:i,schemaValue:a,it:s}=e,{opts:c,propertyName:l,topSchemaRef:d,schemaPath:f}=s;o.push([sn.keyword,r],[sn.params,typeof t=="function"?t(e):t||(0,pe._)`{}`]),c.messages&&o.push([sn.message,typeof n=="function"?n(e):n]),c.verbose&&o.push([sn.schema,a],[sn.parentSchema,(0,pe._)`${d}${f}`],[Xe.default.data,i]),l&&o.push([sn.propertyName,l])}});var zb=A(yo=>{"use strict";Object.defineProperty(yo,"__esModule",{value:!0});yo.boolOrEmptySchema=yo.topBoolOrEmptySchema=void 0;var EP=fa(),TP=re(),OP=ir(),PP={message:"boolean schema is false"};function jP(e){let{gen:t,schema:n,validateName:o}=e;n===!1?Sb(e,!1):typeof n=="object"&&n.$async===!0?t.return(OP.default.data):(t.assign((0,TP._)`${o}.errors`,null),t.return(!0))}yo.topBoolOrEmptySchema=jP;function NP(e,t){let{gen:n,schema:o}=e;o===!1?(n.var(t,!1),Sb(e)):n.var(t,!0)}yo.boolOrEmptySchema=NP;function Sb(e,t){let{gen:n,data:o}=e,r={gen:n,keyword:"false schema",data:o,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e};(0,EP.reportError)(r,PP,void 0,t)}});var km=A(bo=>{"use strict";Object.defineProperty(bo,"__esModule",{value:!0});bo.getRules=bo.isJSONType=void 0;var RP=["string","number","integer","boolean","null","object","array"],AP=new Set(RP);function DP(e){return typeof e=="string"&&AP.has(e)}bo.isJSONType=DP;function CP(){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:{}}}bo.getRules=CP});var Sm=A(jr=>{"use strict";Object.defineProperty(jr,"__esModule",{value:!0});jr.shouldUseRule=jr.shouldUseGroup=jr.schemaHasRulesForType=void 0;function UP({schema:e,self:t},n){let o=t.RULES.types[n];return o&&o!==!0&&Ib(e,o)}jr.schemaHasRulesForType=UP;function Ib(e,t){return t.rules.some(n=>Eb(e,n))}jr.shouldUseGroup=Ib;function Eb(e,t){var n;return e[t.keyword]!==void 0||((n=t.definition.implements)===null||n===void 0?void 0:n.some(o=>e[o]!==void 0))}jr.shouldUseRule=Eb});var pa=A(Je=>{"use strict";Object.defineProperty(Je,"__esModule",{value:!0});Je.reportTypeError=Je.checkDataTypes=Je.checkDataType=Je.coerceAndCheckDataType=Je.getJSONTypes=Je.getSchemaTypes=Je.DataType=void 0;var ZP=km(),MP=Sm(),LP=fa(),ee=re(),Tb=fe(),$o;(function(e){e[e.Correct=0]="Correct",e[e.Wrong=1]="Wrong"})($o||(Je.DataType=$o={}));function qP(e){let t=Ob(e.type);if(t.includes("null")){if(e.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!t.length&&e.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');e.nullable===!0&&t.push("null")}return t}Je.getSchemaTypes=qP;function Ob(e){let t=Array.isArray(e)?e:e?[e]:[];if(t.every(ZP.isJSONType))return t;throw new Error("type must be JSONType or JSONType[]: "+t.join(","))}Je.getJSONTypes=Ob;function VP(e,t){let{gen:n,data:o,opts:r}=e,i=FP(t,r.coerceTypes),a=t.length>0&&!(i.length===0&&t.length===1&&(0,MP.schemaHasRulesForType)(e,t[0]));if(a){let s=Im(t,o,r.strictNumbers,$o.Wrong);n.if(s,()=>{i.length?BP(e,t,i):Em(e)})}return a}Je.coerceAndCheckDataType=VP;var Pb=new Set(["string","number","integer","boolean","null"]);function FP(e,t){return t?e.filter(n=>Pb.has(n)||t==="array"&&n==="array"):[]}function BP(e,t,n){let{gen:o,data:r,opts:i}=e,a=o.let("dataType",(0,ee._)`typeof ${r}`),s=o.let("coerced",(0,ee._)`undefined`);i.coerceTypes==="array"&&o.if((0,ee._)`${a} == 'object' && Array.isArray(${r}) && ${r}.length == 1`,()=>o.assign(r,(0,ee._)`${r}[0]`).assign(a,(0,ee._)`typeof ${r}`).if(Im(t,r,i.strictNumbers),()=>o.assign(s,r))),o.if((0,ee._)`${s} !== undefined`);for(let l of n)(Pb.has(l)||l==="array"&&i.coerceTypes==="array")&&c(l);o.else(),Em(e),o.endIf(),o.if((0,ee._)`${s} !== undefined`,()=>{o.assign(r,s),KP(e,s)});function c(l){switch(l){case"string":o.elseIf((0,ee._)`${a} == "number" || ${a} == "boolean"`).assign(s,(0,ee._)`"" + ${r}`).elseIf((0,ee._)`${r} === null`).assign(s,(0,ee._)`""`);return;case"number":o.elseIf((0,ee._)`${a} == "boolean" || ${r} === null
|
|
6
6
|
|| (${a} == "string" && ${r} && ${r} == +${r})`).assign(s,(0,ee._)`+${r}`);return;case"integer":o.elseIf((0,ee._)`${a} === "boolean" || ${r} === null
|
|
7
7
|
|| (${a} === "string" && ${r} && ${r} == +${r} && !(${r} % 1))`).assign(s,(0,ee._)`+${r}`);return;case"boolean":o.elseIf((0,ee._)`${r} === "false" || ${r} === 0 || ${r} === null`).assign(s,!1).elseIf((0,ee._)`${r} === "true" || ${r} === 1`).assign(s,!0);return;case"null":o.elseIf((0,ee._)`${r} === "" || ${r} === 0 || ${r} === false`),o.assign(s,null);return;case"array":o.elseIf((0,ee._)`${a} === "string" || ${a} === "number"
|
|
8
|
-
|| ${a} === "boolean" || ${r} === null`).assign(s,(0,ee._)`[${r}]`)}}}function UO({gen:e,parentData:t,parentDataProperty:n},o){e.if((0,ee._)`${t} !== undefined`,()=>e.assign((0,ee._)`${t}[${n}]`,o))}function km(e,t,n,o=$o.Correct){let r=o===$o.Correct?ee.operators.EQ:ee.operators.NEQ,i;switch(e){case"null":return(0,ee._)`${t} ${r} null`;case"array":i=(0,ee._)`Array.isArray(${t})`;break;case"object":i=(0,ee._)`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;break;case"integer":i=a((0,ee._)`!(${t} % 1) && !isNaN(${t})`);break;case"number":i=a();break;default:return(0,ee._)`typeof ${t} ${r} ${e}`}return o===$o.Correct?i:(0,ee.not)(i);function a(s=ee.nil){return(0,ee.and)((0,ee._)`typeof ${t} == "number"`,s,n?(0,ee._)`isFinite(${t})`:ee.nil)}}Je.checkDataType=km;function Sm(e,t,n,o){if(e.length===1)return km(e[0],t,n,o);let r,i=(0,zb.toHash)(e);if(i.array&&i.object){let a=(0,ee._)`typeof ${t} != "object"`;r=i.null?a:(0,ee._)`!${t} || ${a}`,delete i.null,delete i.array,delete i.object}else r=ee.nil;i.number&&delete i.integer;for(let a in i)r=(0,ee.and)(r,km(a,t,n,o));return r}Je.checkDataTypes=Sm;var ZO={message:({schema:e})=>`must be ${e}`,params:({schema:e,schemaValue:t})=>typeof e=="string"?(0,ee._)`{type: ${e}}`:(0,ee._)`{type: ${t}}`};function zm(e){let t=MO(e);(0,NO.reportError)(t,ZO)}Je.reportTypeError=zm;function MO(e){let{gen:t,data:n,schema:o}=e,r=(0,zb.schemaRefOrVal)(e,o,"type");return{gen:t,keyword:"type",data:n,schema:o.type,schemaCode:r,schemaValue:r,parentSchema:o,params:{},it:e}}});var Pb=A(pl=>{"use strict";Object.defineProperty(pl,"__esModule",{value:!0});pl.assignDefaults=void 0;var xo=re(),LO=fe();function qO(e,t){let{properties:n,items:o}=e.schema;if(t==="object"&&n)for(let r in n)Tb(e,r,n[r].default);else t==="array"&&Array.isArray(o)&&o.forEach((r,i)=>Tb(e,i,r.default))}pl.assignDefaults=qO;function Tb(e,t,n){let{gen:o,compositeRule:r,data:i,opts:a}=e;if(n===void 0)return;let s=(0,xo._)`${i}${(0,xo.getProperty)(t)}`;if(r){(0,LO.checkStrictMode)(e,`default is ignored for: ${s}`);return}let c=(0,xo._)`${s} === undefined`;a.useDefaults==="empty"&&(c=(0,xo._)`${c} || ${s} === null || ${s} === ""`),o.if(c,(0,xo._)`${s} = ${(0,xo.stringify)(n)}`)}});var $t=A(_e=>{"use strict";Object.defineProperty(_e,"__esModule",{value:!0});_e.validateUnion=_e.validateArray=_e.usePattern=_e.callValidateCode=_e.schemaProperties=_e.allSchemaProperties=_e.noPropertyInData=_e.propertyInData=_e.isOwnProperty=_e.hasPropFunc=_e.reportMissingProp=_e.checkMissingProp=_e.checkReportMissingProp=void 0;var Se=re(),Im=fe(),Nr=ir(),VO=fe();function FO(e,t){let{gen:n,data:o,it:r}=e;n.if(Tm(n,o,t,r.opts.ownProperties),()=>{e.setParams({missingProperty:(0,Se._)`${t}`},!0),e.error()})}_e.checkReportMissingProp=FO;function BO({gen:e,data:t,it:{opts:n}},o,r){return(0,Se.or)(...o.map(i=>(0,Se.and)(Tm(e,t,i,n.ownProperties),(0,Se._)`${r} = ${i}`)))}_e.checkMissingProp=BO;function KO(e,t){e.setParams({missingProperty:t},!0),e.error()}_e.reportMissingProp=KO;function Ob(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,Se._)`Object.prototype.hasOwnProperty`})}_e.hasPropFunc=Ob;function Em(e,t,n){return(0,Se._)`${Ob(e)}.call(${t}, ${n})`}_e.isOwnProperty=Em;function HO(e,t,n,o){let r=(0,Se._)`${t}${(0,Se.getProperty)(n)} !== undefined`;return o?(0,Se._)`${r} && ${Em(e,t,n)}`:r}_e.propertyInData=HO;function Tm(e,t,n,o){let r=(0,Se._)`${t}${(0,Se.getProperty)(n)} === undefined`;return o?(0,Se.or)(r,(0,Se.not)(Em(e,t,n))):r}_e.noPropertyInData=Tm;function jb(e){return e?Object.keys(e).filter(t=>t!=="__proto__"):[]}_e.allSchemaProperties=jb;function JO(e,t){return jb(t).filter(n=>!(0,Im.alwaysValidSchema)(e,t[n]))}_e.schemaProperties=JO;function GO({schemaCode:e,data:t,it:{gen:n,topSchemaRef:o,schemaPath:r,errorPath:i},it:a},s,c,l){let d=l?(0,Se._)`${e}, ${t}, ${o}${r}`:t,f=[[Nr.default.instancePath,(0,Se.strConcat)(Nr.default.instancePath,i)],[Nr.default.parentData,a.parentData],[Nr.default.parentDataProperty,a.parentDataProperty],[Nr.default.rootData,Nr.default.rootData]];a.opts.dynamicRef&&f.push([Nr.default.dynamicAnchors,Nr.default.dynamicAnchors]);let _=(0,Se._)`${d}, ${n.object(...f)}`;return c!==Se.nil?(0,Se._)`${s}.call(${c}, ${_})`:(0,Se._)`${s}(${_})`}_e.callValidateCode=GO;var WO=(0,Se._)`new RegExp`;function XO({gen:e,it:{opts:t}},n){let o=t.unicodeRegExp?"u":"",{regExp:r}=t.code,i=r(n,o);return e.scopeValue("pattern",{key:i.toString(),ref:i,code:(0,Se._)`${r.code==="new RegExp"?WO:(0,VO.useFunc)(e,r)}(${n}, ${o})`})}_e.usePattern=XO;function YO(e){let{gen:t,data:n,keyword:o,it:r}=e,i=t.name("valid");if(r.allErrors){let s=t.let("valid",!0);return a(()=>t.assign(s,!1)),s}return t.var(i,!0),a(()=>t.break()),i;function a(s){let c=t.const("len",(0,Se._)`${n}.length`);t.forRange("i",0,c,l=>{e.subschema({keyword:o,dataProp:l,dataPropType:Im.Type.Num},i),t.if((0,Se.not)(i),s)})}}_e.validateArray=YO;function QO(e){let{gen:t,schema:n,keyword:o,it:r}=e;if(!Array.isArray(n))throw new Error("ajv implementation error");if(n.some(c=>(0,Im.alwaysValidSchema)(r,c))&&!r.opts.unevaluated)return;let a=t.let("valid",!1),s=t.name("_valid");t.block(()=>n.forEach((c,l)=>{let d=e.subschema({keyword:o,schemaProp:l,compositeRule:!0},s);t.assign(a,(0,Se._)`${a} || ${s}`),e.mergeValidEvaluated(d,s)||t.if((0,Se.not)(a))})),e.result(a,()=>e.reset(),()=>e.error(!0))}_e.validateUnion=QO});var Ab=A(Vt=>{"use strict";Object.defineProperty(Vt,"__esModule",{value:!0});Vt.validateKeywordUsage=Vt.validSchemaType=Vt.funcKeywordCode=Vt.macroKeywordCode=void 0;var Ye=re(),cn=ir(),ej=$t(),tj=fa();function rj(e,t){let{gen:n,keyword:o,schema:r,parentSchema:i,it:a}=e,s=t.macro.call(a.self,r,i,a),c=Rb(n,o,s);a.opts.validateSchema!==!1&&a.self.validateSchema(s,!0);let l=n.name("valid");e.subschema({schema:s,schemaPath:Ye.nil,errSchemaPath:`${a.errSchemaPath}/${o}`,topSchemaRef:c,compositeRule:!0},l),e.pass(l,()=>e.error(!0))}Vt.macroKeywordCode=rj;function nj(e,t){var n;let{gen:o,keyword:r,schema:i,parentSchema:a,$data:s,it:c}=e;ij(c,t);let l=!s&&t.compile?t.compile.call(c.self,i,a,c):t.validate,d=Rb(o,r,l),f=o.let("valid");e.block$data(f,_),e.ok((n=t.valid)!==null&&n!==void 0?n:f);function _(){if(t.errors===!1)b(),t.modifying&&Nb(e),x(()=>e.error());else{let I=t.async?v():g();t.modifying&&Nb(e),x(()=>oj(e,I))}}function v(){let I=o.let("ruleErrs",null);return o.try(()=>b((0,Ye._)`await `),R=>o.assign(f,!1).if((0,Ye._)`${R} instanceof ${c.ValidationError}`,()=>o.assign(I,(0,Ye._)`${R}.errors`),()=>o.throw(R))),I}function g(){let I=(0,Ye._)`${d}.errors`;return o.assign(I,null),b(Ye.nil),I}function b(I=t.async?(0,Ye._)`await `:Ye.nil){let R=c.opts.passContext?cn.default.this:cn.default.self,P=!("compile"in t&&!s||t.schema===!1);o.assign(f,(0,Ye._)`${I}${(0,ej.callValidateCode)(e,d,R,P)}`,t.modifying)}function x(I){var R;o.if((0,Ye.not)((R=t.valid)!==null&&R!==void 0?R:f),I)}}Vt.funcKeywordCode=nj;function Nb(e){let{gen:t,data:n,it:o}=e;t.if(o.parentData,()=>t.assign(n,(0,Ye._)`${o.parentData}[${o.parentDataProperty}]`))}function oj(e,t){let{gen:n}=e;n.if((0,Ye._)`Array.isArray(${t})`,()=>{n.assign(cn.default.vErrors,(0,Ye._)`${cn.default.vErrors} === null ? ${t} : ${cn.default.vErrors}.concat(${t})`).assign(cn.default.errors,(0,Ye._)`${cn.default.vErrors}.length`),(0,tj.extendErrors)(e)},()=>e.error())}function ij({schemaEnv:e},t){if(t.async&&!e.$async)throw new Error("async keyword in sync schema")}function Rb(e,t,n){if(n===void 0)throw new Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword",typeof n=="function"?{ref:n}:{ref:n,code:(0,Ye.stringify)(n)})}function aj(e,t,n=!1){return!t.length||t.some(o=>o==="array"?Array.isArray(e):o==="object"?e&&typeof e=="object"&&!Array.isArray(e):typeof e==o||n&&typeof e>"u")}Vt.validSchemaType=aj;function sj({schema:e,opts:t,self:n,errSchemaPath:o},r,i){if(Array.isArray(r.keyword)?!r.keyword.includes(i):r.keyword!==i)throw new Error("ajv implementation error");let a=r.dependencies;if(a?.some(s=>!Object.prototype.hasOwnProperty.call(e,s)))throw new Error(`parent schema must have dependencies of ${i}: ${a.join(",")}`);if(r.validateSchema&&!r.validateSchema(e[i])){let c=`keyword "${i}" value is invalid at path "${o}": `+n.errorsText(r.validateSchema.errors);if(t.validateSchema==="log")n.logger.error(c);else throw new Error(c)}}Vt.validateKeywordUsage=sj});var Cb=A(Rr=>{"use strict";Object.defineProperty(Rr,"__esModule",{value:!0});Rr.extendSubschemaMode=Rr.extendSubschemaData=Rr.getSubschema=void 0;var Ft=re(),Db=fe();function cj(e,{keyword:t,schemaProp:n,schema:o,schemaPath:r,errSchemaPath:i,topSchemaRef:a}){if(t!==void 0&&o!==void 0)throw new Error('both "keyword" and "schema" passed, only one allowed');if(t!==void 0){let s=e.schema[t];return n===void 0?{schema:s,schemaPath:(0,Ft._)`${e.schemaPath}${(0,Ft.getProperty)(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:s[n],schemaPath:(0,Ft._)`${e.schemaPath}${(0,Ft.getProperty)(t)}${(0,Ft.getProperty)(n)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${(0,Db.escapeFragment)(n)}`}}if(o!==void 0){if(r===void 0||i===void 0||a===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:o,schemaPath:r,topSchemaRef:a,errSchemaPath:i}}throw new Error('either "keyword" or "schema" must be passed')}Rr.getSubschema=cj;function uj(e,t,{dataProp:n,dataPropType:o,data:r,dataTypes:i,propertyName:a}){if(r!==void 0&&n!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');let{gen:s}=t;if(n!==void 0){let{errorPath:l,dataPathArr:d,opts:f}=t,_=s.let("data",(0,Ft._)`${t.data}${(0,Ft.getProperty)(n)}`,!0);c(_),e.errorPath=(0,Ft.str)`${l}${(0,Db.getErrorPath)(n,o,f.jsPropertySyntax)}`,e.parentDataProperty=(0,Ft._)`${n}`,e.dataPathArr=[...d,e.parentDataProperty]}if(r!==void 0){let l=r instanceof Ft.Name?r:s.let("data",r,!0);c(l),a!==void 0&&(e.propertyName=a)}i&&(e.dataTypes=i);function c(l){e.data=l,e.dataLevel=t.dataLevel+1,e.dataTypes=[],t.definedProperties=new Set,e.parentData=t.data,e.dataNames=[...t.dataNames,l]}}Rr.extendSubschemaData=uj;function lj(e,{jtdDiscriminator:t,jtdMetadata:n,compositeRule:o,createErrors:r,allErrors:i}){o!==void 0&&(e.compositeRule=o),r!==void 0&&(e.createErrors=r),i!==void 0&&(e.allErrors=i),e.jtdDiscriminator=t,e.jtdMetadata=n}Rr.extendSubschemaMode=lj});var Pm=A((b2,Ub)=>{"use strict";Ub.exports=function e(t,n){if(t===n)return!0;if(t&&n&&typeof t=="object"&&typeof n=="object"){if(t.constructor!==n.constructor)return!1;var o,r,i;if(Array.isArray(t)){if(o=t.length,o!=n.length)return!1;for(r=o;r--!==0;)if(!e(t[r],n[r]))return!1;return!0}if(t.constructor===RegExp)return t.source===n.source&&t.flags===n.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===n.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===n.toString();if(i=Object.keys(t),o=i.length,o!==Object.keys(n).length)return!1;for(r=o;r--!==0;)if(!Object.prototype.hasOwnProperty.call(n,i[r]))return!1;for(r=o;r--!==0;){var a=i[r];if(!e(t[a],n[a]))return!1}return!0}return t!==t&&n!==n}});var Mb=A(($2,Zb)=>{"use strict";var Ar=Zb.exports=function(e,t,n){typeof t=="function"&&(n=t,t={}),n=t.cb||n;var o=typeof n=="function"?n:n.pre||function(){},r=n.post||function(){};ml(t,o,r,e,"",e)};Ar.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};Ar.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};Ar.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};Ar.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function ml(e,t,n,o,r,i,a,s,c,l){if(o&&typeof o=="object"&&!Array.isArray(o)){t(o,r,i,a,s,c,l);for(var d in o){var f=o[d];if(Array.isArray(f)){if(d in Ar.arrayKeywords)for(var _=0;_<f.length;_++)ml(e,t,n,f[_],r+"/"+d+"/"+_,i,r,d,o,_)}else if(d in Ar.propsKeywords){if(f&&typeof f=="object")for(var v in f)ml(e,t,n,f[v],r+"/"+d+"/"+dj(v),i,r,d,o,v)}else(d in Ar.keywords||e.allKeys&&!(d in Ar.skipKeywords))&&ml(e,t,n,f,r+"/"+d,i,r,d,o)}n(o,r,i,a,s,c,l)}}function dj(e){return e.replace(/~/g,"~0").replace(/\//g,"~1")}});var ma=A(at=>{"use strict";Object.defineProperty(at,"__esModule",{value:!0});at.getSchemaRefs=at.resolveUrl=at.normalizeId=at._getFullPath=at.getFullPath=at.inlineRef=void 0;var fj=fe(),pj=Pm(),mj=Mb(),hj=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function gj(e,t=!0){return typeof e=="boolean"?!0:t===!0?!Om(e):t?Lb(e)<=t:!1}at.inlineRef=gj;var vj=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function Om(e){for(let t in e){if(vj.has(t))return!0;let n=e[t];if(Array.isArray(n)&&n.some(Om)||typeof n=="object"&&Om(n))return!0}return!1}function Lb(e){let t=0;for(let n in e){if(n==="$ref")return 1/0;if(t++,!hj.has(n)&&(typeof e[n]=="object"&&(0,fj.eachItem)(e[n],o=>t+=Lb(o)),t===1/0))return 1/0}return t}function qb(e,t="",n){n!==!1&&(t=wo(t));let o=e.parse(t);return Vb(e,o)}at.getFullPath=qb;function Vb(e,t){return e.serialize(t).split("#")[0]+"#"}at._getFullPath=Vb;var _j=/#\/?$/;function wo(e){return e?e.replace(_j,""):""}at.normalizeId=wo;function yj(e,t,n){return n=wo(n),e.resolve(t,n)}at.resolveUrl=yj;var bj=/^[a-z_][-a-z0-9._]*$/i;function $j(e,t){if(typeof e=="boolean")return{};let{schemaId:n,uriResolver:o}=this.opts,r=wo(e[n]||t),i={"":r},a=qb(o,r,!1),s={},c=new Set;return mj(e,{allKeys:!0},(f,_,v,g)=>{if(g===void 0)return;let b=a+_,x=i[g];typeof f[n]=="string"&&(x=I.call(this,f[n])),R.call(this,f.$anchor),R.call(this,f.$dynamicAnchor),i[_]=x;function I(P){let M=this.opts.uriResolver.resolve;if(P=wo(x?M(x,P):P),c.has(P))throw d(P);c.add(P);let V=this.refs[P];return typeof V=="string"&&(V=this.refs[V]),typeof V=="object"?l(f,V.schema,P):P!==wo(b)&&(P[0]==="#"?(l(f,s[P],P),s[P]=f):this.refs[P]=b),P}function R(P){if(typeof P=="string"){if(!bj.test(P))throw new Error(`invalid anchor "${P}"`);I.call(this,`#${P}`)}}}),s;function l(f,_,v){if(_!==void 0&&!pj(f,_))throw d(v)}function d(f){return new Error(`reference "${f}" resolves to more than one schema`)}}at.getSchemaRefs=$j});var va=A(Dr=>{"use strict";Object.defineProperty(Dr,"__esModule",{value:!0});Dr.getData=Dr.KeywordCxt=Dr.validateFunctionCode=void 0;var Jb=wb(),Fb=pa(),Nm=wm(),hl=pa(),xj=Pb(),ga=Ab(),jm=Cb(),K=re(),X=ir(),wj=ma(),ar=fe(),ha=fa();function kj(e){if(Xb(e)&&(Yb(e),Wb(e))){Ij(e);return}Gb(e,()=>(0,Jb.topBoolOrEmptySchema)(e))}Dr.validateFunctionCode=kj;function Gb({gen:e,validateName:t,schema:n,schemaEnv:o,opts:r},i){r.code.es5?e.func(t,(0,K._)`${X.default.data}, ${X.default.valCxt}`,o.$async,()=>{e.code((0,K._)`"use strict"; ${Bb(n,r)}`),zj(e,r),e.code(i)}):e.func(t,(0,K._)`${X.default.data}, ${Sj(r)}`,o.$async,()=>e.code(Bb(n,r)).code(i))}function Sj(e){return(0,K._)`{${X.default.instancePath}="", ${X.default.parentData}, ${X.default.parentDataProperty}, ${X.default.rootData}=${X.default.data}${e.dynamicRef?(0,K._)`, ${X.default.dynamicAnchors}={}`:K.nil}}={}`}function zj(e,t){e.if(X.default.valCxt,()=>{e.var(X.default.instancePath,(0,K._)`${X.default.valCxt}.${X.default.instancePath}`),e.var(X.default.parentData,(0,K._)`${X.default.valCxt}.${X.default.parentData}`),e.var(X.default.parentDataProperty,(0,K._)`${X.default.valCxt}.${X.default.parentDataProperty}`),e.var(X.default.rootData,(0,K._)`${X.default.valCxt}.${X.default.rootData}`),t.dynamicRef&&e.var(X.default.dynamicAnchors,(0,K._)`${X.default.valCxt}.${X.default.dynamicAnchors}`)},()=>{e.var(X.default.instancePath,(0,K._)`""`),e.var(X.default.parentData,(0,K._)`undefined`),e.var(X.default.parentDataProperty,(0,K._)`undefined`),e.var(X.default.rootData,X.default.data),t.dynamicRef&&e.var(X.default.dynamicAnchors,(0,K._)`{}`)})}function Ij(e){let{schema:t,opts:n,gen:o}=e;Gb(e,()=>{n.$comment&&t.$comment&&e$(e),jj(e),o.let(X.default.vErrors,null),o.let(X.default.errors,0),n.unevaluated&&Ej(e),Qb(e),Aj(e)})}function Ej(e){let{gen:t,validateName:n}=e;e.evaluated=t.const("evaluated",(0,K._)`${n}.evaluated`),t.if((0,K._)`${e.evaluated}.dynamicProps`,()=>t.assign((0,K._)`${e.evaluated}.props`,(0,K._)`undefined`)),t.if((0,K._)`${e.evaluated}.dynamicItems`,()=>t.assign((0,K._)`${e.evaluated}.items`,(0,K._)`undefined`))}function Bb(e,t){let n=typeof e=="object"&&e[t.schemaId];return n&&(t.code.source||t.code.process)?(0,K._)`/*# sourceURL=${n} */`:K.nil}function Tj(e,t){if(Xb(e)&&(Yb(e),Wb(e))){Pj(e,t);return}(0,Jb.boolOrEmptySchema)(e,t)}function Wb({schema:e,self:t}){if(typeof e=="boolean")return!e;for(let n in e)if(t.RULES.all[n])return!0;return!1}function Xb(e){return typeof e.schema!="boolean"}function Pj(e,t){let{schema:n,gen:o,opts:r}=e;r.$comment&&n.$comment&&e$(e),Nj(e),Rj(e);let i=o.const("_errs",X.default.errors);Qb(e,i),o.var(t,(0,K._)`${i} === ${X.default.errors}`)}function Yb(e){(0,ar.checkUnknownRules)(e),Oj(e)}function Qb(e,t){if(e.opts.jtd)return Kb(e,[],!1,t);let n=(0,Fb.getSchemaTypes)(e.schema),o=(0,Fb.coerceAndCheckDataType)(e,n);Kb(e,n,!o,t)}function Oj(e){let{schema:t,errSchemaPath:n,opts:o,self:r}=e;t.$ref&&o.ignoreKeywordsWithRef&&(0,ar.schemaHasRulesButRef)(t,r.RULES)&&r.logger.warn(`$ref: keywords ignored in schema at path "${n}"`)}function jj(e){let{schema:t,opts:n}=e;t.default!==void 0&&n.useDefaults&&n.strictSchema&&(0,ar.checkStrictMode)(e,"default is ignored in the schema root")}function Nj(e){let t=e.schema[e.opts.schemaId];t&&(e.baseId=(0,wj.resolveUrl)(e.opts.uriResolver,e.baseId,t))}function Rj(e){if(e.schema.$async&&!e.schemaEnv.$async)throw new Error("async schema in sync schema")}function e$({gen:e,schemaEnv:t,schema:n,errSchemaPath:o,opts:r}){let i=n.$comment;if(r.$comment===!0)e.code((0,K._)`${X.default.self}.logger.log(${i})`);else if(typeof r.$comment=="function"){let a=(0,K.str)`${o}/$comment`,s=e.scopeValue("root",{ref:t.root});e.code((0,K._)`${X.default.self}.opts.$comment(${i}, ${a}, ${s}.schema)`)}}function Aj(e){let{gen:t,schemaEnv:n,validateName:o,ValidationError:r,opts:i}=e;n.$async?t.if((0,K._)`${X.default.errors} === 0`,()=>t.return(X.default.data),()=>t.throw((0,K._)`new ${r}(${X.default.vErrors})`)):(t.assign((0,K._)`${o}.errors`,X.default.vErrors),i.unevaluated&&Dj(e),t.return((0,K._)`${X.default.errors} === 0`))}function Dj({gen:e,evaluated:t,props:n,items:o}){n instanceof K.Name&&e.assign((0,K._)`${t}.props`,n),o instanceof K.Name&&e.assign((0,K._)`${t}.items`,o)}function Kb(e,t,n,o){let{gen:r,schema:i,data:a,allErrors:s,opts:c,self:l}=e,{RULES:d}=l;if(i.$ref&&(c.ignoreKeywordsWithRef||!(0,ar.schemaHasRulesButRef)(i,d))){r.block(()=>r$(e,"$ref",d.all.$ref.definition));return}c.jtd||Cj(e,t),r.block(()=>{for(let _ of d.rules)f(_);f(d.post)});function f(_){(0,Nm.shouldUseGroup)(i,_)&&(_.type?(r.if((0,hl.checkDataType)(_.type,a,c.strictNumbers)),Hb(e,_),t.length===1&&t[0]===_.type&&n&&(r.else(),(0,hl.reportTypeError)(e)),r.endIf()):Hb(e,_),s||r.if((0,K._)`${X.default.errors} === ${o||0}`))}}function Hb(e,t){let{gen:n,schema:o,opts:{useDefaults:r}}=e;r&&(0,xj.assignDefaults)(e,t.type),n.block(()=>{for(let i of t.rules)(0,Nm.shouldUseRule)(o,i)&&r$(e,i.keyword,i.definition,t.type)})}function Cj(e,t){e.schemaEnv.meta||!e.opts.strictTypes||(Uj(e,t),e.opts.allowUnionTypes||Zj(e,t),Mj(e,e.dataTypes))}function Uj(e,t){if(t.length){if(!e.dataTypes.length){e.dataTypes=t;return}t.forEach(n=>{t$(e.dataTypes,n)||Rm(e,`type "${n}" not allowed by context "${e.dataTypes.join(",")}"`)}),qj(e,t)}}function Zj(e,t){t.length>1&&!(t.length===2&&t.includes("null"))&&Rm(e,"use allowUnionTypes to allow union type keyword")}function Mj(e,t){let n=e.self.RULES.all;for(let o in n){let r=n[o];if(typeof r=="object"&&(0,Nm.shouldUseRule)(e.schema,r)){let{type:i}=r.definition;i.length&&!i.some(a=>Lj(t,a))&&Rm(e,`missing type "${i.join(",")}" for keyword "${o}"`)}}}function Lj(e,t){return e.includes(t)||t==="number"&&e.includes("integer")}function t$(e,t){return e.includes(t)||t==="integer"&&e.includes("number")}function qj(e,t){let n=[];for(let o of e.dataTypes)t$(t,o)?n.push(o):t.includes("integer")&&o==="number"&&n.push("integer");e.dataTypes=n}function Rm(e,t){let n=e.schemaEnv.baseId+e.errSchemaPath;t+=` at "${n}" (strictTypes)`,(0,ar.checkStrictMode)(e,t,e.opts.strictTypes)}var gl=class{constructor(t,n,o){if((0,ga.validateKeywordUsage)(t,n,o),this.gen=t.gen,this.allErrors=t.allErrors,this.keyword=o,this.data=t.data,this.schema=t.schema[o],this.$data=n.$data&&t.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,ar.schemaRefOrVal)(t,this.schema,o,this.$data),this.schemaType=n.schemaType,this.parentSchema=t.schema,this.params={},this.it=t,this.def=n,this.$data)this.schemaCode=t.gen.const("vSchema",n$(this.$data,t));else if(this.schemaCode=this.schemaValue,!(0,ga.validSchemaType)(this.schema,n.schemaType,n.allowUndefined))throw new Error(`${o} value must be ${JSON.stringify(n.schemaType)}`);("code"in n?n.trackErrors:n.errors!==!1)&&(this.errsCount=t.gen.const("_errs",X.default.errors))}result(t,n,o){this.failResult((0,K.not)(t),n,o)}failResult(t,n,o){this.gen.if(t),o?o():this.error(),n?(this.gen.else(),n(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(t,n){this.failResult((0,K.not)(t),void 0,n)}fail(t){if(t===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(t),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(t){if(!this.$data)return this.fail(t);let{schemaCode:n}=this;this.fail((0,K._)`${n} !== undefined && (${(0,K.or)(this.invalid$data(),t)})`)}error(t,n,o){if(n){this.setParams(n),this._error(t,o),this.setParams({});return}this._error(t,o)}_error(t,n){(t?ha.reportExtraError:ha.reportError)(this,this.def.error,n)}$dataError(){(0,ha.reportError)(this,this.def.$dataError||ha.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,ha.resetErrorsCount)(this.gen,this.errsCount)}ok(t){this.allErrors||this.gen.if(t)}setParams(t,n){n?Object.assign(this.params,t):this.params=t}block$data(t,n,o=K.nil){this.gen.block(()=>{this.check$data(t,o),n()})}check$data(t=K.nil,n=K.nil){if(!this.$data)return;let{gen:o,schemaCode:r,schemaType:i,def:a}=this;o.if((0,K.or)((0,K._)`${r} === undefined`,n)),t!==K.nil&&o.assign(t,!0),(i.length||a.validateSchema)&&(o.elseIf(this.invalid$data()),this.$dataError(),t!==K.nil&&o.assign(t,!1)),o.else()}invalid$data(){let{gen:t,schemaCode:n,schemaType:o,def:r,it:i}=this;return(0,K.or)(a(),s());function a(){if(o.length){if(!(n instanceof K.Name))throw new Error("ajv implementation error");let c=Array.isArray(o)?o:[o];return(0,K._)`${(0,hl.checkDataTypes)(c,n,i.opts.strictNumbers,hl.DataType.Wrong)}`}return K.nil}function s(){if(r.validateSchema){let c=t.scopeValue("validate$data",{ref:r.validateSchema});return(0,K._)`!${c}(${n})`}return K.nil}}subschema(t,n){let o=(0,jm.getSubschema)(this.it,t);(0,jm.extendSubschemaData)(o,this.it,t),(0,jm.extendSubschemaMode)(o,t);let r={...this.it,...o,items:void 0,props:void 0};return Tj(r,n),r}mergeEvaluated(t,n){let{it:o,gen:r}=this;o.opts.unevaluated&&(o.props!==!0&&t.props!==void 0&&(o.props=ar.mergeEvaluated.props(r,t.props,o.props,n)),o.items!==!0&&t.items!==void 0&&(o.items=ar.mergeEvaluated.items(r,t.items,o.items,n)))}mergeValidEvaluated(t,n){let{it:o,gen:r}=this;if(o.opts.unevaluated&&(o.props!==!0||o.items!==!0))return r.if(n,()=>this.mergeEvaluated(t,K.Name)),!0}};Dr.KeywordCxt=gl;function r$(e,t,n,o){let r=new gl(e,n,t);"code"in n?n.code(r,o):r.$data&&n.validate?(0,ga.funcKeywordCode)(r,n):"macro"in n?(0,ga.macroKeywordCode)(r,n):(n.compile||n.validate)&&(0,ga.funcKeywordCode)(r,n)}var Vj=/^\/(?:[^~]|~0|~1)*$/,Fj=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function n$(e,{dataLevel:t,dataNames:n,dataPathArr:o}){let r,i;if(e==="")return X.default.rootData;if(e[0]==="/"){if(!Vj.test(e))throw new Error(`Invalid JSON-pointer: ${e}`);r=e,i=X.default.rootData}else{let l=Fj.exec(e);if(!l)throw new Error(`Invalid JSON-pointer: ${e}`);let d=+l[1];if(r=l[2],r==="#"){if(d>=t)throw new Error(c("property/index",d));return o[t-d]}if(d>t)throw new Error(c("data",d));if(i=n[t-d],!r)return i}let a=i,s=r.split("/");for(let l of s)l&&(i=(0,K._)`${i}${(0,K.getProperty)((0,ar.unescapeJsonPointer)(l))}`,a=(0,K._)`${a} && ${i}`);return a;function c(l,d){return`Cannot access ${l} ${d} levels up, current level is ${t}`}}Dr.getData=n$});var vl=A(Dm=>{"use strict";Object.defineProperty(Dm,"__esModule",{value:!0});var Am=class extends Error{constructor(t){super("validation failed"),this.errors=t,this.ajv=this.validation=!0}};Dm.default=Am});var _a=A(Zm=>{"use strict";Object.defineProperty(Zm,"__esModule",{value:!0});var Cm=ma(),Um=class extends Error{constructor(t,n,o,r){super(r||`can't resolve reference ${o} from id ${n}`),this.missingRef=(0,Cm.resolveUrl)(t,n,o),this.missingSchema=(0,Cm.normalizeId)((0,Cm.getFullPath)(t,this.missingRef))}};Zm.default=Um});var yl=A(xt=>{"use strict";Object.defineProperty(xt,"__esModule",{value:!0});xt.resolveSchema=xt.getCompilingSchema=xt.resolveRef=xt.compileSchema=xt.SchemaEnv=void 0;var Nt=re(),Bj=vl(),un=ir(),Rt=ma(),o$=fe(),Kj=va(),ko=class{constructor(t){var n;this.refs={},this.dynamicAnchors={};let o;typeof t.schema=="object"&&(o=t.schema),this.schema=t.schema,this.schemaId=t.schemaId,this.root=t.root||this,this.baseId=(n=t.baseId)!==null&&n!==void 0?n:(0,Rt.normalizeId)(o?.[t.schemaId||"$id"]),this.schemaPath=t.schemaPath,this.localRefs=t.localRefs,this.meta=t.meta,this.$async=o?.$async,this.refs={}}};xt.SchemaEnv=ko;function Lm(e){let t=i$.call(this,e);if(t)return t;let n=(0,Rt.getFullPath)(this.opts.uriResolver,e.root.baseId),{es5:o,lines:r}=this.opts.code,{ownProperties:i}=this.opts,a=new Nt.CodeGen(this.scope,{es5:o,lines:r,ownProperties:i}),s;e.$async&&(s=a.scopeValue("Error",{ref:Bj.default,code:(0,Nt._)`require("ajv/dist/runtime/validation_error").default`}));let c=a.scopeName("validate");e.validateName=c;let l={gen:a,allErrors:this.opts.allErrors,data:un.default.data,parentData:un.default.parentData,parentDataProperty:un.default.parentDataProperty,dataNames:[un.default.data],dataPathArr:[Nt.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:a.scopeValue("schema",this.opts.code.source===!0?{ref:e.schema,code:(0,Nt.stringify)(e.schema)}:{ref:e.schema}),validateName:c,ValidationError:s,schema:e.schema,schemaEnv:e,rootId:n,baseId:e.baseId||n,schemaPath:Nt.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,Nt._)`""`,opts:this.opts,self:this},d;try{this._compilations.add(e),(0,Kj.validateFunctionCode)(l),a.optimize(this.opts.code.optimize);let f=a.toString();d=`${a.scopeRefs(un.default.scope)}return ${f}`,this.opts.code.process&&(d=this.opts.code.process(d,e));let v=new Function(`${un.default.self}`,`${un.default.scope}`,d)(this,this.scope.get());if(this.scope.value(c,{ref:v}),v.errors=null,v.schema=e.schema,v.schemaEnv=e,e.$async&&(v.$async=!0),this.opts.code.source===!0&&(v.source={validateName:c,validateCode:f,scopeValues:a._values}),this.opts.unevaluated){let{props:g,items:b}=l;v.evaluated={props:g instanceof Nt.Name?void 0:g,items:b instanceof Nt.Name?void 0:b,dynamicProps:g instanceof Nt.Name,dynamicItems:b instanceof Nt.Name},v.source&&(v.source.evaluated=(0,Nt.stringify)(v.evaluated))}return e.validate=v,e}catch(f){throw delete e.validate,delete e.validateName,d&&this.logger.error("Error compiling schema, function code:",d),f}finally{this._compilations.delete(e)}}xt.compileSchema=Lm;function Hj(e,t,n){var o;n=(0,Rt.resolveUrl)(this.opts.uriResolver,t,n);let r=e.refs[n];if(r)return r;let i=Wj.call(this,e,n);if(i===void 0){let a=(o=e.localRefs)===null||o===void 0?void 0:o[n],{schemaId:s}=this.opts;a&&(i=new ko({schema:a,schemaId:s,root:e,baseId:t}))}if(i!==void 0)return e.refs[n]=Jj.call(this,i)}xt.resolveRef=Hj;function Jj(e){return(0,Rt.inlineRef)(e.schema,this.opts.inlineRefs)?e.schema:e.validate?e:Lm.call(this,e)}function i$(e){for(let t of this._compilations)if(Gj(t,e))return t}xt.getCompilingSchema=i$;function Gj(e,t){return e.schema===t.schema&&e.root===t.root&&e.baseId===t.baseId}function Wj(e,t){let n;for(;typeof(n=this.refs[t])=="string";)t=n;return n||this.schemas[t]||_l.call(this,e,t)}function _l(e,t){let n=this.opts.uriResolver.parse(t),o=(0,Rt._getFullPath)(this.opts.uriResolver,n),r=(0,Rt.getFullPath)(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&o===r)return Mm.call(this,n,e);let i=(0,Rt.normalizeId)(o),a=this.refs[i]||this.schemas[i];if(typeof a=="string"){let s=_l.call(this,e,a);return typeof s?.schema!="object"?void 0:Mm.call(this,n,s)}if(typeof a?.schema=="object"){if(a.validate||Lm.call(this,a),i===(0,Rt.normalizeId)(t)){let{schema:s}=a,{schemaId:c}=this.opts,l=s[c];return l&&(r=(0,Rt.resolveUrl)(this.opts.uriResolver,r,l)),new ko({schema:s,schemaId:c,root:e,baseId:r})}return Mm.call(this,n,a)}}xt.resolveSchema=_l;var Xj=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function Mm(e,{baseId:t,schema:n,root:o}){var r;if(((r=e.fragment)===null||r===void 0?void 0:r[0])!=="/")return;for(let s of e.fragment.slice(1).split("/")){if(typeof n=="boolean")return;let c=n[(0,o$.unescapeFragment)(s)];if(c===void 0)return;n=c;let l=typeof n=="object"&&n[this.opts.schemaId];!Xj.has(s)&&l&&(t=(0,Rt.resolveUrl)(this.opts.uriResolver,t,l))}let i;if(typeof n!="boolean"&&n.$ref&&!(0,o$.schemaHasRulesButRef)(n,this.RULES)){let s=(0,Rt.resolveUrl)(this.opts.uriResolver,t,n.$ref);i=_l.call(this,o,s)}let{schemaId:a}=this.opts;if(i=i||new ko({schema:n,schemaId:a,root:o,baseId:t}),i.schema!==i.root.schema)return i}});var a$=A((I2,Yj)=>{Yj.exports={$id:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",description:"Meta-schema for $data reference (JSON AnySchema extension proposal)",type:"object",required:["$data"],properties:{$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},additionalProperties:!1}});var Vm=A((E2,l$)=>{"use strict";var Qj=RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu),c$=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);function qm(e){let t="",n=0,o=0;for(o=0;o<e.length;o++)if(n=e[o].charCodeAt(0),n!==48){if(!(n>=48&&n<=57||n>=65&&n<=70||n>=97&&n<=102))return"";t+=e[o];break}for(o+=1;o<e.length;o++){if(n=e[o].charCodeAt(0),!(n>=48&&n<=57||n>=65&&n<=70||n>=97&&n<=102))return"";t+=e[o]}return t}var eN=RegExp.prototype.test.bind(/[^!"$&'()*+,\-.;=_`a-z{}~]/u);function s$(e){return e.length=0,!0}function tN(e,t,n){if(e.length){let o=qm(e);if(o!=="")t.push(o);else return n.error=!0,!1;e.length=0}return!0}function rN(e){let t=0,n={error:!1,address:"",zone:""},o=[],r=[],i=!1,a=!1,s=tN;for(let c=0;c<e.length;c++){let l=e[c];if(!(l==="["||l==="]"))if(l===":"){if(i===!0&&(a=!0),!s(r,o,n))break;if(++t>7){n.error=!0;break}c>0&&e[c-1]===":"&&(i=!0),o.push(":");continue}else if(l==="%"){if(!s(r,o,n))break;s=s$}else{r.push(l);continue}}return r.length&&(s===s$?n.zone=r.join(""):a?o.push(r.join("")):o.push(qm(r))),n.address=o.join(""),n}function u$(e){if(nN(e,":")<2)return{host:e,isIPV6:!1};let t=rN(e);if(t.error)return{host:e,isIPV6:!1};{let n=t.address,o=t.address;return t.zone&&(n+="%"+t.zone,o+="%25"+t.zone),{host:n,isIPV6:!0,escapedHost:o}}}function nN(e,t){let n=0;for(let o=0;o<e.length;o++)e[o]===t&&n++;return n}function oN(e){let t=e,n=[],o=-1,r=0;for(;r=t.length;){if(r===1){if(t===".")break;if(t==="/"){n.push("/");break}else{n.push(t);break}}else if(r===2){if(t[0]==="."){if(t[1]===".")break;if(t[1]==="/"){t=t.slice(2);continue}}else if(t[0]==="/"&&(t[1]==="."||t[1]==="/")){n.push("/");break}}else if(r===3&&t==="/.."){n.length!==0&&n.pop(),n.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),n.length!==0&&n.pop();continue}}if((o=t.indexOf("/",1))===-1){n.push(t);break}else n.push(t.slice(0,o)),t=t.slice(o)}return n.join("")}function iN(e,t){let n=t!==!0?escape:unescape;return e.scheme!==void 0&&(e.scheme=n(e.scheme)),e.userinfo!==void 0&&(e.userinfo=n(e.userinfo)),e.host!==void 0&&(e.host=n(e.host)),e.path!==void 0&&(e.path=n(e.path)),e.query!==void 0&&(e.query=n(e.query)),e.fragment!==void 0&&(e.fragment=n(e.fragment)),e}function aN(e){let t=[];if(e.userinfo!==void 0&&(t.push(e.userinfo),t.push("@")),e.host!==void 0){let n=unescape(e.host);if(!c$(n)){let o=u$(n);o.isIPV6===!0?n=`[${o.escapedHost}]`:n=e.host}t.push(n)}return(typeof e.port=="number"||typeof e.port=="string")&&(t.push(":"),t.push(String(e.port))),t.length?t.join(""):void 0}l$.exports={nonSimpleDomain:eN,recomposeAuthority:aN,normalizeComponentEncoding:iN,removeDotSegments:oN,isIPv4:c$,isUUID:Qj,normalizeIPv6:u$,stringArrayToHexStripped:qm}});var h$=A((T2,m$)=>{"use strict";var{isUUID:sN}=Vm(),cN=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu,uN=["http","https","ws","wss","urn","urn:uuid"];function lN(e){return uN.indexOf(e)!==-1}function Fm(e){return e.secure===!0?!0:e.secure===!1?!1:e.scheme?e.scheme.length===3&&(e.scheme[0]==="w"||e.scheme[0]==="W")&&(e.scheme[1]==="s"||e.scheme[1]==="S")&&(e.scheme[2]==="s"||e.scheme[2]==="S"):!1}function d$(e){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e}function f$(e){let t=String(e.scheme).toLowerCase()==="https";return(e.port===(t?443:80)||e.port==="")&&(e.port=void 0),e.path||(e.path="/"),e}function dN(e){return e.secure=Fm(e),e.resourceName=(e.path||"/")+(e.query?"?"+e.query:""),e.path=void 0,e.query=void 0,e}function fN(e){if((e.port===(Fm(e)?443:80)||e.port==="")&&(e.port=void 0),typeof e.secure=="boolean"&&(e.scheme=e.secure?"wss":"ws",e.secure=void 0),e.resourceName){let[t,n]=e.resourceName.split("?");e.path=t&&t!=="/"?t:void 0,e.query=n,e.resourceName=void 0}return e.fragment=void 0,e}function pN(e,t){if(!e.path)return e.error="URN can not be parsed",e;let n=e.path.match(cN);if(n){let o=t.scheme||e.scheme||"urn";e.nid=n[1].toLowerCase(),e.nss=n[2];let r=`${o}:${t.nid||e.nid}`,i=Bm(r);e.path=void 0,i&&(e=i.parse(e,t))}else e.error=e.error||"URN can not be parsed.";return e}function mN(e,t){if(e.nid===void 0)throw new Error("URN without nid cannot be serialized");let n=t.scheme||e.scheme||"urn",o=e.nid.toLowerCase(),r=`${n}:${t.nid||o}`,i=Bm(r);i&&(e=i.serialize(e,t));let a=e,s=e.nss;return a.path=`${o||t.nid}:${s}`,t.skipEscape=!0,a}function hN(e,t){let n=e;return n.uuid=n.nss,n.nss=void 0,!t.tolerant&&(!n.uuid||!sN(n.uuid))&&(n.error=n.error||"UUID is not valid."),n}function gN(e){let t=e;return t.nss=(e.uuid||"").toLowerCase(),t}var p$={scheme:"http",domainHost:!0,parse:d$,serialize:f$},vN={scheme:"https",domainHost:p$.domainHost,parse:d$,serialize:f$},bl={scheme:"ws",domainHost:!0,parse:dN,serialize:fN},_N={scheme:"wss",domainHost:bl.domainHost,parse:bl.parse,serialize:bl.serialize},yN={scheme:"urn",parse:pN,serialize:mN,skipNormalize:!0},bN={scheme:"urn:uuid",parse:hN,serialize:gN,skipNormalize:!0},$l={http:p$,https:vN,ws:bl,wss:_N,urn:yN,"urn:uuid":bN};Object.setPrototypeOf($l,null);function Bm(e){return e&&($l[e]||$l[e.toLowerCase()])||void 0}m$.exports={wsIsSecure:Fm,SCHEMES:$l,isValidSchemeName:lN,getSchemeHandler:Bm}});var _$=A((P2,wl)=>{"use strict";var{normalizeIPv6:$N,removeDotSegments:ya,recomposeAuthority:xN,normalizeComponentEncoding:xl,isIPv4:wN,nonSimpleDomain:kN}=Vm(),{SCHEMES:SN,getSchemeHandler:g$}=h$();function zN(e,t){return typeof e=="string"?e=Bt(sr(e,t),t):typeof e=="object"&&(e=sr(Bt(e,t),t)),e}function IN(e,t,n){let o=n?Object.assign({scheme:"null"},n):{scheme:"null"},r=v$(sr(e,o),sr(t,o),o,!0);return o.skipEscape=!0,Bt(r,o)}function v$(e,t,n,o){let r={};return o||(e=sr(Bt(e,n),n),t=sr(Bt(t,n),n)),n=n||{},!n.tolerant&&t.scheme?(r.scheme=t.scheme,r.userinfo=t.userinfo,r.host=t.host,r.port=t.port,r.path=ya(t.path||""),r.query=t.query):(t.userinfo!==void 0||t.host!==void 0||t.port!==void 0?(r.userinfo=t.userinfo,r.host=t.host,r.port=t.port,r.path=ya(t.path||""),r.query=t.query):(t.path?(t.path[0]==="/"?r.path=ya(t.path):((e.userinfo!==void 0||e.host!==void 0||e.port!==void 0)&&!e.path?r.path="/"+t.path:e.path?r.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:r.path=t.path,r.path=ya(r.path)),r.query=t.query):(r.path=e.path,t.query!==void 0?r.query=t.query:r.query=e.query),r.userinfo=e.userinfo,r.host=e.host,r.port=e.port),r.scheme=e.scheme),r.fragment=t.fragment,r}function EN(e,t,n){return typeof e=="string"?(e=unescape(e),e=Bt(xl(sr(e,n),!0),{...n,skipEscape:!0})):typeof e=="object"&&(e=Bt(xl(e,!0),{...n,skipEscape:!0})),typeof t=="string"?(t=unescape(t),t=Bt(xl(sr(t,n),!0),{...n,skipEscape:!0})):typeof t=="object"&&(t=Bt(xl(t,!0),{...n,skipEscape:!0})),e.toLowerCase()===t.toLowerCase()}function Bt(e,t){let n={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:""},o=Object.assign({},t),r=[],i=g$(o.scheme||n.scheme);i&&i.serialize&&i.serialize(n,o),n.path!==void 0&&(o.skipEscape?n.path=unescape(n.path):(n.path=escape(n.path),n.scheme!==void 0&&(n.path=n.path.split("%3A").join(":")))),o.reference!=="suffix"&&n.scheme&&r.push(n.scheme,":");let a=xN(n);if(a!==void 0&&(o.reference!=="suffix"&&r.push("//"),r.push(a),n.path&&n.path[0]!=="/"&&r.push("/")),n.path!==void 0){let s=n.path;!o.absolutePath&&(!i||!i.absolutePath)&&(s=ya(s)),a===void 0&&s[0]==="/"&&s[1]==="/"&&(s="/%2F"+s.slice(2)),r.push(s)}return n.query!==void 0&&r.push("?",n.query),n.fragment!==void 0&&r.push("#",n.fragment),r.join("")}var TN=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function sr(e,t){let n=Object.assign({},t),o={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0},r=!1;n.reference==="suffix"&&(n.scheme?e=n.scheme+":"+e:e="//"+e);let i=e.match(TN);if(i){if(o.scheme=i[1],o.userinfo=i[3],o.host=i[4],o.port=parseInt(i[5],10),o.path=i[6]||"",o.query=i[7],o.fragment=i[8],isNaN(o.port)&&(o.port=i[5]),o.host)if(wN(o.host)===!1){let c=$N(o.host);o.host=c.host.toLowerCase(),r=c.isIPV6}else r=!0;o.scheme===void 0&&o.userinfo===void 0&&o.host===void 0&&o.port===void 0&&o.query===void 0&&!o.path?o.reference="same-document":o.scheme===void 0?o.reference="relative":o.fragment===void 0?o.reference="absolute":o.reference="uri",n.reference&&n.reference!=="suffix"&&n.reference!==o.reference&&(o.error=o.error||"URI is not a "+n.reference+" reference.");let a=g$(n.scheme||o.scheme);if(!n.unicodeSupport&&(!a||!a.unicodeSupport)&&o.host&&(n.domainHost||a&&a.domainHost)&&r===!1&&kN(o.host))try{o.host=URL.domainToASCII(o.host.toLowerCase())}catch(s){o.error=o.error||"Host's domain name can not be converted to ASCII: "+s}(!a||a&&!a.skipNormalize)&&(e.indexOf("%")!==-1&&(o.scheme!==void 0&&(o.scheme=unescape(o.scheme)),o.host!==void 0&&(o.host=unescape(o.host))),o.path&&(o.path=escape(unescape(o.path))),o.fragment&&(o.fragment=encodeURI(decodeURIComponent(o.fragment)))),a&&a.parse&&a.parse(o,n)}else o.error=o.error||"URI can not be parsed.";return o}var Km={SCHEMES:SN,normalize:zN,resolve:IN,resolveComponent:v$,equal:EN,serialize:Bt,parse:sr};wl.exports=Km;wl.exports.default=Km;wl.exports.fastUri=Km});var b$=A(Hm=>{"use strict";Object.defineProperty(Hm,"__esModule",{value:!0});var y$=_$();y$.code='require("ajv/dist/runtime/uri").default';Hm.default=y$});var E$=A(Ue=>{"use strict";Object.defineProperty(Ue,"__esModule",{value:!0});Ue.CodeGen=Ue.Name=Ue.nil=Ue.stringify=Ue.str=Ue._=Ue.KeywordCxt=void 0;var PN=va();Object.defineProperty(Ue,"KeywordCxt",{enumerable:!0,get:function(){return PN.KeywordCxt}});var So=re();Object.defineProperty(Ue,"_",{enumerable:!0,get:function(){return So._}});Object.defineProperty(Ue,"str",{enumerable:!0,get:function(){return So.str}});Object.defineProperty(Ue,"stringify",{enumerable:!0,get:function(){return So.stringify}});Object.defineProperty(Ue,"nil",{enumerable:!0,get:function(){return So.nil}});Object.defineProperty(Ue,"Name",{enumerable:!0,get:function(){return So.Name}});Object.defineProperty(Ue,"CodeGen",{enumerable:!0,get:function(){return So.CodeGen}});var ON=vl(),S$=_a(),jN=xm(),ba=yl(),NN=re(),$a=ma(),kl=pa(),Gm=fe(),$$=a$(),RN=b$(),z$=(e,t)=>new RegExp(e,t);z$.code="new RegExp";var AN=["removeAdditional","useDefaults","coerceTypes"],DN=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),CN={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."},UN={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},x$=200;function ZN(e){var t,n,o,r,i,a,s,c,l,d,f,_,v,g,b,x,I,R,P,M,V,Me,ct,Ao,ur;let Lr=e.strict,mn=(t=e.code)===null||t===void 0?void 0:t.optimize,Ca=mn===!0||mn===void 0?1:mn||0,Ua=(o=(n=e.code)===null||n===void 0?void 0:n.regExp)!==null&&o!==void 0?o:z$,rd=(r=e.uriResolver)!==null&&r!==void 0?r:RN.default;return{strictSchema:(a=(i=e.strictSchema)!==null&&i!==void 0?i:Lr)!==null&&a!==void 0?a:!0,strictNumbers:(c=(s=e.strictNumbers)!==null&&s!==void 0?s:Lr)!==null&&c!==void 0?c:!0,strictTypes:(d=(l=e.strictTypes)!==null&&l!==void 0?l:Lr)!==null&&d!==void 0?d:"log",strictTuples:(_=(f=e.strictTuples)!==null&&f!==void 0?f:Lr)!==null&&_!==void 0?_:"log",strictRequired:(g=(v=e.strictRequired)!==null&&v!==void 0?v:Lr)!==null&&g!==void 0?g:!1,code:e.code?{...e.code,optimize:Ca,regExp:Ua}:{optimize:Ca,regExp:Ua},loopRequired:(b=e.loopRequired)!==null&&b!==void 0?b:x$,loopEnum:(x=e.loopEnum)!==null&&x!==void 0?x:x$,meta:(I=e.meta)!==null&&I!==void 0?I:!0,messages:(R=e.messages)!==null&&R!==void 0?R:!0,inlineRefs:(P=e.inlineRefs)!==null&&P!==void 0?P:!0,schemaId:(M=e.schemaId)!==null&&M!==void 0?M:"$id",addUsedSchema:(V=e.addUsedSchema)!==null&&V!==void 0?V:!0,validateSchema:(Me=e.validateSchema)!==null&&Me!==void 0?Me:!0,validateFormats:(ct=e.validateFormats)!==null&&ct!==void 0?ct:!0,unicodeRegExp:(Ao=e.unicodeRegExp)!==null&&Ao!==void 0?Ao:!0,int32range:(ur=e.int32range)!==null&&ur!==void 0?ur:!0,uriResolver:rd}}var xa=class{constructor(t={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,t=this.opts={...t,...ZN(t)};let{es5:n,lines:o}=this.opts.code;this.scope=new NN.ValueScope({scope:{},prefixes:DN,es5:n,lines:o}),this.logger=BN(t.logger);let r=t.validateFormats;t.validateFormats=!1,this.RULES=(0,jN.getRules)(),w$.call(this,CN,t,"NOT SUPPORTED"),w$.call(this,UN,t,"DEPRECATED","warn"),this._metaOpts=VN.call(this),t.formats&&LN.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),t.keywords&&qN.call(this,t.keywords),typeof t.meta=="object"&&this.addMetaSchema(t.meta),MN.call(this),t.validateFormats=r}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){let{$data:t,meta:n,schemaId:o}=this.opts,r=$$;o==="id"&&(r={...$$},r.id=r.$id,delete r.$id),n&&t&&this.addMetaSchema(r,r[o],!1)}defaultMeta(){let{meta:t,schemaId:n}=this.opts;return this.opts.defaultMeta=typeof t=="object"?t[n]||t:void 0}validate(t,n){let o;if(typeof t=="string"){if(o=this.getSchema(t),!o)throw new Error(`no schema with key or ref "${t}"`)}else o=this.compile(t);let r=o(n);return"$async"in o||(this.errors=o.errors),r}compile(t,n){let o=this._addSchema(t,n);return o.validate||this._compileSchemaEnv(o)}compileAsync(t,n){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");let{loadSchema:o}=this.opts;return r.call(this,t,n);async function r(d,f){await i.call(this,d.$schema);let _=this._addSchema(d,f);return _.validate||a.call(this,_)}async function i(d){d&&!this.getSchema(d)&&await r.call(this,{$ref:d},!0)}async function a(d){try{return this._compileSchemaEnv(d)}catch(f){if(!(f instanceof S$.default))throw f;return s.call(this,f),await c.call(this,f.missingSchema),a.call(this,d)}}function s({missingSchema:d,missingRef:f}){if(this.refs[d])throw new Error(`AnySchema ${d} is loaded but ${f} cannot be resolved`)}async function c(d){let f=await l.call(this,d);this.refs[d]||await i.call(this,f.$schema),this.refs[d]||this.addSchema(f,d,n)}async function l(d){let f=this._loading[d];if(f)return f;try{return await(this._loading[d]=o(d))}finally{delete this._loading[d]}}}addSchema(t,n,o,r=this.opts.validateSchema){if(Array.isArray(t)){for(let a of t)this.addSchema(a,void 0,o,r);return this}let i;if(typeof t=="object"){let{schemaId:a}=this.opts;if(i=t[a],i!==void 0&&typeof i!="string")throw new Error(`schema ${a} must be string`)}return n=(0,$a.normalizeId)(n||i),this._checkUnique(n),this.schemas[n]=this._addSchema(t,o,n,r,!0),this}addMetaSchema(t,n,o=this.opts.validateSchema){return this.addSchema(t,n,!0,o),this}validateSchema(t,n){if(typeof t=="boolean")return!0;let o;if(o=t.$schema,o!==void 0&&typeof o!="string")throw new Error("$schema must be a string");if(o=o||this.opts.defaultMeta||this.defaultMeta(),!o)return this.logger.warn("meta-schema not available"),this.errors=null,!0;let r=this.validate(o,t);if(!r&&n){let i="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(i);else throw new Error(i)}return r}getSchema(t){let n;for(;typeof(n=k$.call(this,t))=="string";)t=n;if(n===void 0){let{schemaId:o}=this.opts,r=new ba.SchemaEnv({schema:{},schemaId:o});if(n=ba.resolveSchema.call(this,r,t),!n)return;this.refs[t]=n}return n.validate||this._compileSchemaEnv(n)}removeSchema(t){if(t instanceof RegExp)return this._removeAllSchemas(this.schemas,t),this._removeAllSchemas(this.refs,t),this;switch(typeof t){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{let n=k$.call(this,t);return typeof n=="object"&&this._cache.delete(n.schema),delete this.schemas[t],delete this.refs[t],this}case"object":{let n=t;this._cache.delete(n);let o=t[this.opts.schemaId];return o&&(o=(0,$a.normalizeId)(o),delete this.schemas[o],delete this.refs[o]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(t){for(let n of t)this.addKeyword(n);return this}addKeyword(t,n){let o;if(typeof t=="string")o=t,typeof n=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),n.keyword=o);else if(typeof t=="object"&&n===void 0){if(n=t,o=n.keyword,Array.isArray(o)&&!o.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if(HN.call(this,o,n),!n)return(0,Gm.eachItem)(o,i=>Jm.call(this,i)),this;GN.call(this,n);let r={...n,type:(0,kl.getJSONTypes)(n.type),schemaType:(0,kl.getJSONTypes)(n.schemaType)};return(0,Gm.eachItem)(o,r.type.length===0?i=>Jm.call(this,i,r):i=>r.type.forEach(a=>Jm.call(this,i,r,a))),this}getKeyword(t){let n=this.RULES.all[t];return typeof n=="object"?n.definition:!!n}removeKeyword(t){let{RULES:n}=this;delete n.keywords[t],delete n.all[t];for(let o of n.rules){let r=o.rules.findIndex(i=>i.keyword===t);r>=0&&o.rules.splice(r,1)}return this}addFormat(t,n){return typeof n=="string"&&(n=new RegExp(n)),this.formats[t]=n,this}errorsText(t=this.errors,{separator:n=", ",dataVar:o="data"}={}){return!t||t.length===0?"No errors":t.map(r=>`${o}${r.instancePath} ${r.message}`).reduce((r,i)=>r+n+i)}$dataMetaSchema(t,n){let o=this.RULES.all;t=JSON.parse(JSON.stringify(t));for(let r of n){let i=r.split("/").slice(1),a=t;for(let s of i)a=a[s];for(let s in o){let c=o[s];if(typeof c!="object")continue;let{$data:l}=c.definition,d=a[s];l&&d&&(a[s]=I$(d))}}return t}_removeAllSchemas(t,n){for(let o in t){let r=t[o];(!n||n.test(o))&&(typeof r=="string"?delete t[o]:r&&!r.meta&&(this._cache.delete(r.schema),delete t[o]))}}_addSchema(t,n,o,r=this.opts.validateSchema,i=this.opts.addUsedSchema){let a,{schemaId:s}=this.opts;if(typeof t=="object")a=t[s];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof t!="boolean")throw new Error("schema must be object or boolean")}let c=this._cache.get(t);if(c!==void 0)return c;o=(0,$a.normalizeId)(a||o);let l=$a.getSchemaRefs.call(this,t,o);return c=new ba.SchemaEnv({schema:t,schemaId:s,meta:n,baseId:o,localRefs:l}),this._cache.set(c.schema,c),i&&!o.startsWith("#")&&(o&&this._checkUnique(o),this.refs[o]=c),r&&this.validateSchema(t,!0),c}_checkUnique(t){if(this.schemas[t]||this.refs[t])throw new Error(`schema with key or id "${t}" already exists`)}_compileSchemaEnv(t){if(t.meta?this._compileMetaSchema(t):ba.compileSchema.call(this,t),!t.validate)throw new Error("ajv implementation error");return t.validate}_compileMetaSchema(t){let n=this.opts;this.opts=this._metaOpts;try{ba.compileSchema.call(this,t)}finally{this.opts=n}}};xa.ValidationError=ON.default;xa.MissingRefError=S$.default;Ue.default=xa;function w$(e,t,n,o="error"){for(let r in e){let i=r;i in t&&this.logger[o](`${n}: option ${r}. ${e[i]}`)}}function k$(e){return e=(0,$a.normalizeId)(e),this.schemas[e]||this.refs[e]}function MN(){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 LN(){for(let e in this.opts.formats){let t=this.opts.formats[e];t&&this.addFormat(e,t)}}function qN(e){if(Array.isArray(e)){this.addVocabulary(e);return}this.logger.warn("keywords option as map is deprecated, pass array");for(let t in e){let n=e[t];n.keyword||(n.keyword=t),this.addKeyword(n)}}function VN(){let e={...this.opts};for(let t of AN)delete e[t];return e}var FN={log(){},warn(){},error(){}};function BN(e){if(e===!1)return FN;if(e===void 0)return console;if(e.log&&e.warn&&e.error)return e;throw new Error("logger must implement log, warn and error methods")}var KN=/^[a-z_$][a-z0-9_$:-]*$/i;function HN(e,t){let{RULES:n}=this;if((0,Gm.eachItem)(e,o=>{if(n.keywords[o])throw new Error(`Keyword ${o} is already defined`);if(!KN.test(o))throw new Error(`Keyword ${o} has invalid name`)}),!!t&&t.$data&&!("code"in t||"validate"in t))throw new Error('$data keyword must have "code" or "validate" function')}function Jm(e,t,n){var o;let r=t?.post;if(n&&r)throw new Error('keyword with "post" flag cannot have "type"');let{RULES:i}=this,a=r?i.post:i.rules.find(({type:c})=>c===n);if(a||(a={type:n,rules:[]},i.rules.push(a)),i.keywords[e]=!0,!t)return;let s={keyword:e,definition:{...t,type:(0,kl.getJSONTypes)(t.type),schemaType:(0,kl.getJSONTypes)(t.schemaType)}};t.before?JN.call(this,a,s,t.before):a.rules.push(s),i.all[e]=s,(o=t.implements)===null||o===void 0||o.forEach(c=>this.addKeyword(c))}function JN(e,t,n){let o=e.rules.findIndex(r=>r.keyword===n);o>=0?e.rules.splice(o,0,t):(e.rules.push(t),this.logger.warn(`rule ${n} is not defined`))}function GN(e){let{metaSchema:t}=e;t!==void 0&&(e.$data&&this.opts.$data&&(t=I$(t)),e.validateSchema=this.compile(t,!0))}var WN={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function I$(e){return{anyOf:[e,WN]}}});var T$=A(Wm=>{"use strict";Object.defineProperty(Wm,"__esModule",{value:!0});var XN={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};Wm.default=XN});var N$=A(ln=>{"use strict";Object.defineProperty(ln,"__esModule",{value:!0});ln.callRef=ln.getValidate=void 0;var YN=_a(),P$=$t(),st=re(),zo=ir(),O$=yl(),Sl=fe(),QN={keyword:"$ref",schemaType:"string",code(e){let{gen:t,schema:n,it:o}=e,{baseId:r,schemaEnv:i,validateName:a,opts:s,self:c}=o,{root:l}=i;if((n==="#"||n==="#/")&&r===l.baseId)return f();let d=O$.resolveRef.call(c,l,r,n);if(d===void 0)throw new YN.default(o.opts.uriResolver,r,n);if(d instanceof O$.SchemaEnv)return _(d);return v(d);function f(){if(i===l)return zl(e,a,i,i.$async);let g=t.scopeValue("root",{ref:l});return zl(e,(0,st._)`${g}.validate`,l,l.$async)}function _(g){let b=j$(e,g);zl(e,b,g,g.$async)}function v(g){let b=t.scopeValue("schema",s.code.source===!0?{ref:g,code:(0,st.stringify)(g)}:{ref:g}),x=t.name("valid"),I=e.subschema({schema:g,dataTypes:[],schemaPath:st.nil,topSchemaRef:b,errSchemaPath:n},x);e.mergeEvaluated(I),e.ok(x)}}};function j$(e,t){let{gen:n}=e;return t.validate?n.scopeValue("validate",{ref:t.validate}):(0,st._)`${n.scopeValue("wrapper",{ref:t})}.validate`}ln.getValidate=j$;function zl(e,t,n,o){let{gen:r,it:i}=e,{allErrors:a,schemaEnv:s,opts:c}=i,l=c.passContext?zo.default.this:st.nil;o?d():f();function d(){if(!s.$async)throw new Error("async schema referenced by sync schema");let g=r.let("valid");r.try(()=>{r.code((0,st._)`await ${(0,P$.callValidateCode)(e,t,l)}`),v(t),a||r.assign(g,!0)},b=>{r.if((0,st._)`!(${b} instanceof ${i.ValidationError})`,()=>r.throw(b)),_(b),a||r.assign(g,!1)}),e.ok(g)}function f(){e.result((0,P$.callValidateCode)(e,t,l),()=>v(t),()=>_(t))}function _(g){let b=(0,st._)`${g}.errors`;r.assign(zo.default.vErrors,(0,st._)`${zo.default.vErrors} === null ? ${b} : ${zo.default.vErrors}.concat(${b})`),r.assign(zo.default.errors,(0,st._)`${zo.default.vErrors}.length`)}function v(g){var b;if(!i.opts.unevaluated)return;let x=(b=n?.validate)===null||b===void 0?void 0:b.evaluated;if(i.props!==!0)if(x&&!x.dynamicProps)x.props!==void 0&&(i.props=Sl.mergeEvaluated.props(r,x.props,i.props));else{let I=r.var("props",(0,st._)`${g}.evaluated.props`);i.props=Sl.mergeEvaluated.props(r,I,i.props,st.Name)}if(i.items!==!0)if(x&&!x.dynamicItems)x.items!==void 0&&(i.items=Sl.mergeEvaluated.items(r,x.items,i.items));else{let I=r.var("items",(0,st._)`${g}.evaluated.items`);i.items=Sl.mergeEvaluated.items(r,I,i.items,st.Name)}}}ln.callRef=zl;ln.default=QN});var R$=A(Xm=>{"use strict";Object.defineProperty(Xm,"__esModule",{value:!0});var eR=T$(),tR=N$(),rR=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",eR.default,tR.default];Xm.default=rR});var A$=A(Ym=>{"use strict";Object.defineProperty(Ym,"__esModule",{value:!0});var Il=re(),Cr=Il.operators,El={maximum:{okStr:"<=",ok:Cr.LTE,fail:Cr.GT},minimum:{okStr:">=",ok:Cr.GTE,fail:Cr.LT},exclusiveMaximum:{okStr:"<",ok:Cr.LT,fail:Cr.GTE},exclusiveMinimum:{okStr:">",ok:Cr.GT,fail:Cr.LTE}},nR={message:({keyword:e,schemaCode:t})=>(0,Il.str)`must be ${El[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>(0,Il._)`{comparison: ${El[e].okStr}, limit: ${t}}`},oR={keyword:Object.keys(El),type:"number",schemaType:"number",$data:!0,error:nR,code(e){let{keyword:t,data:n,schemaCode:o}=e;e.fail$data((0,Il._)`${n} ${El[t].fail} ${o} || isNaN(${n})`)}};Ym.default=oR});var D$=A(Qm=>{"use strict";Object.defineProperty(Qm,"__esModule",{value:!0});var wa=re(),iR={message:({schemaCode:e})=>(0,wa.str)`must be multiple of ${e}`,params:({schemaCode:e})=>(0,wa._)`{multipleOf: ${e}}`},aR={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:iR,code(e){let{gen:t,data:n,schemaCode:o,it:r}=e,i=r.opts.multipleOfPrecision,a=t.let("res"),s=i?(0,wa._)`Math.abs(Math.round(${a}) - ${a}) > 1e-${i}`:(0,wa._)`${a} !== parseInt(${a})`;e.fail$data((0,wa._)`(${o} === 0 || (${a} = ${n}/${o}, ${s}))`)}};Qm.default=aR});var U$=A(eh=>{"use strict";Object.defineProperty(eh,"__esModule",{value:!0});function C$(e){let t=e.length,n=0,o=0,r;for(;o<t;)n++,r=e.charCodeAt(o++),r>=55296&&r<=56319&&o<t&&(r=e.charCodeAt(o),(r&64512)===56320&&o++);return n}eh.default=C$;C$.code='require("ajv/dist/runtime/ucs2length").default'});var Z$=A(th=>{"use strict";Object.defineProperty(th,"__esModule",{value:!0});var dn=re(),sR=fe(),cR=U$(),uR={message({keyword:e,schemaCode:t}){let n=e==="maxLength"?"more":"fewer";return(0,dn.str)`must NOT have ${n} than ${t} characters`},params:({schemaCode:e})=>(0,dn._)`{limit: ${e}}`},lR={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:uR,code(e){let{keyword:t,data:n,schemaCode:o,it:r}=e,i=t==="maxLength"?dn.operators.GT:dn.operators.LT,a=r.opts.unicode===!1?(0,dn._)`${n}.length`:(0,dn._)`${(0,sR.useFunc)(e.gen,cR.default)}(${n})`;e.fail$data((0,dn._)`${a} ${i} ${o}`)}};th.default=lR});var M$=A(rh=>{"use strict";Object.defineProperty(rh,"__esModule",{value:!0});var dR=$t(),fR=fe(),Io=re(),pR={message:({schemaCode:e})=>(0,Io.str)`must match pattern "${e}"`,params:({schemaCode:e})=>(0,Io._)`{pattern: ${e}}`},mR={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:pR,code(e){let{gen:t,data:n,$data:o,schema:r,schemaCode:i,it:a}=e,s=a.opts.unicodeRegExp?"u":"";if(o){let{regExp:c}=a.opts.code,l=c.code==="new RegExp"?(0,Io._)`new RegExp`:(0,fR.useFunc)(t,c),d=t.let("valid");t.try(()=>t.assign(d,(0,Io._)`${l}(${i}, ${s}).test(${n})`),()=>t.assign(d,!1)),e.fail$data((0,Io._)`!${d}`)}else{let c=(0,dR.usePattern)(e,r);e.fail$data((0,Io._)`!${c}.test(${n})`)}}};rh.default=mR});var L$=A(nh=>{"use strict";Object.defineProperty(nh,"__esModule",{value:!0});var ka=re(),hR={message({keyword:e,schemaCode:t}){let n=e==="maxProperties"?"more":"fewer";return(0,ka.str)`must NOT have ${n} than ${t} properties`},params:({schemaCode:e})=>(0,ka._)`{limit: ${e}}`},gR={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:hR,code(e){let{keyword:t,data:n,schemaCode:o}=e,r=t==="maxProperties"?ka.operators.GT:ka.operators.LT;e.fail$data((0,ka._)`Object.keys(${n}).length ${r} ${o}`)}};nh.default=gR});var q$=A(oh=>{"use strict";Object.defineProperty(oh,"__esModule",{value:!0});var Sa=$t(),za=re(),vR=fe(),_R={message:({params:{missingProperty:e}})=>(0,za.str)`must have required property '${e}'`,params:({params:{missingProperty:e}})=>(0,za._)`{missingProperty: ${e}}`},yR={keyword:"required",type:"object",schemaType:"array",$data:!0,error:_R,code(e){let{gen:t,schema:n,schemaCode:o,data:r,$data:i,it:a}=e,{opts:s}=a;if(!i&&n.length===0)return;let c=n.length>=s.loopRequired;if(a.allErrors?l():d(),s.strictRequired){let v=e.parentSchema.properties,{definedProperties:g}=e.it;for(let b of n)if(v?.[b]===void 0&&!g.has(b)){let x=a.schemaEnv.baseId+a.errSchemaPath,I=`required property "${b}" is not defined at "${x}" (strictRequired)`;(0,vR.checkStrictMode)(a,I,a.opts.strictRequired)}}function l(){if(c||i)e.block$data(za.nil,f);else for(let v of n)(0,Sa.checkReportMissingProp)(e,v)}function d(){let v=t.let("missing");if(c||i){let g=t.let("valid",!0);e.block$data(g,()=>_(v,g)),e.ok(g)}else t.if((0,Sa.checkMissingProp)(e,n,v)),(0,Sa.reportMissingProp)(e,v),t.else()}function f(){t.forOf("prop",o,v=>{e.setParams({missingProperty:v}),t.if((0,Sa.noPropertyInData)(t,r,v,s.ownProperties),()=>e.error())})}function _(v,g){e.setParams({missingProperty:v}),t.forOf(v,o,()=>{t.assign(g,(0,Sa.propertyInData)(t,r,v,s.ownProperties)),t.if((0,za.not)(g),()=>{e.error(),t.break()})},za.nil)}}};oh.default=yR});var V$=A(ih=>{"use strict";Object.defineProperty(ih,"__esModule",{value:!0});var Ia=re(),bR={message({keyword:e,schemaCode:t}){let n=e==="maxItems"?"more":"fewer";return(0,Ia.str)`must NOT have ${n} than ${t} items`},params:({schemaCode:e})=>(0,Ia._)`{limit: ${e}}`},$R={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:bR,code(e){let{keyword:t,data:n,schemaCode:o}=e,r=t==="maxItems"?Ia.operators.GT:Ia.operators.LT;e.fail$data((0,Ia._)`${n}.length ${r} ${o}`)}};ih.default=$R});var Tl=A(ah=>{"use strict";Object.defineProperty(ah,"__esModule",{value:!0});var F$=Pm();F$.code='require("ajv/dist/runtime/equal").default';ah.default=F$});var B$=A(ch=>{"use strict";Object.defineProperty(ch,"__esModule",{value:!0});var sh=pa(),Ze=re(),xR=fe(),wR=Tl(),kR={message:({params:{i:e,j:t}})=>(0,Ze.str)`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>(0,Ze._)`{i: ${e}, j: ${t}}`},SR={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:kR,code(e){let{gen:t,data:n,$data:o,schema:r,parentSchema:i,schemaCode:a,it:s}=e;if(!o&&!r)return;let c=t.let("valid"),l=i.items?(0,sh.getSchemaTypes)(i.items):[];e.block$data(c,d,(0,Ze._)`${a} === false`),e.ok(c);function d(){let g=t.let("i",(0,Ze._)`${n}.length`),b=t.let("j");e.setParams({i:g,j:b}),t.assign(c,!0),t.if((0,Ze._)`${g} > 1`,()=>(f()?_:v)(g,b))}function f(){return l.length>0&&!l.some(g=>g==="object"||g==="array")}function _(g,b){let x=t.name("item"),I=(0,sh.checkDataTypes)(l,x,s.opts.strictNumbers,sh.DataType.Wrong),R=t.const("indices",(0,Ze._)`{}`);t.for((0,Ze._)`;${g}--;`,()=>{t.let(x,(0,Ze._)`${n}[${g}]`),t.if(I,(0,Ze._)`continue`),l.length>1&&t.if((0,Ze._)`typeof ${x} == "string"`,(0,Ze._)`${x} += "_"`),t.if((0,Ze._)`typeof ${R}[${x}] == "number"`,()=>{t.assign(b,(0,Ze._)`${R}[${x}]`),e.error(),t.assign(c,!1).break()}).code((0,Ze._)`${R}[${x}] = ${g}`)})}function v(g,b){let x=(0,xR.useFunc)(t,wR.default),I=t.name("outer");t.label(I).for((0,Ze._)`;${g}--;`,()=>t.for((0,Ze._)`${b} = ${g}; ${b}--;`,()=>t.if((0,Ze._)`${x}(${n}[${g}], ${n}[${b}])`,()=>{e.error(),t.assign(c,!1).break(I)})))}}};ch.default=SR});var K$=A(lh=>{"use strict";Object.defineProperty(lh,"__esModule",{value:!0});var uh=re(),zR=fe(),IR=Tl(),ER={message:"must be equal to constant",params:({schemaCode:e})=>(0,uh._)`{allowedValue: ${e}}`},TR={keyword:"const",$data:!0,error:ER,code(e){let{gen:t,data:n,$data:o,schemaCode:r,schema:i}=e;o||i&&typeof i=="object"?e.fail$data((0,uh._)`!${(0,zR.useFunc)(t,IR.default)}(${n}, ${r})`):e.fail((0,uh._)`${i} !== ${n}`)}};lh.default=TR});var H$=A(dh=>{"use strict";Object.defineProperty(dh,"__esModule",{value:!0});var Ea=re(),PR=fe(),OR=Tl(),jR={message:"must be equal to one of the allowed values",params:({schemaCode:e})=>(0,Ea._)`{allowedValues: ${e}}`},NR={keyword:"enum",schemaType:"array",$data:!0,error:jR,code(e){let{gen:t,data:n,$data:o,schema:r,schemaCode:i,it:a}=e;if(!o&&r.length===0)throw new Error("enum must have non-empty array");let s=r.length>=a.opts.loopEnum,c,l=()=>c??(c=(0,PR.useFunc)(t,OR.default)),d;if(s||o)d=t.let("valid"),e.block$data(d,f);else{if(!Array.isArray(r))throw new Error("ajv implementation error");let v=t.const("vSchema",i);d=(0,Ea.or)(...r.map((g,b)=>_(v,b)))}e.pass(d);function f(){t.assign(d,!1),t.forOf("v",i,v=>t.if((0,Ea._)`${l()}(${n}, ${v})`,()=>t.assign(d,!0).break()))}function _(v,g){let b=r[g];return typeof b=="object"&&b!==null?(0,Ea._)`${l()}(${n}, ${v}[${g}])`:(0,Ea._)`${n} === ${b}`}}};dh.default=NR});var J$=A(fh=>{"use strict";Object.defineProperty(fh,"__esModule",{value:!0});var RR=A$(),AR=D$(),DR=Z$(),CR=M$(),UR=L$(),ZR=q$(),MR=V$(),LR=B$(),qR=K$(),VR=H$(),FR=[RR.default,AR.default,DR.default,CR.default,UR.default,ZR.default,MR.default,LR.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},qR.default,VR.default];fh.default=FR});var mh=A(Ta=>{"use strict";Object.defineProperty(Ta,"__esModule",{value:!0});Ta.validateAdditionalItems=void 0;var fn=re(),ph=fe(),BR={message:({params:{len:e}})=>(0,fn.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,fn._)`{limit: ${e}}`},KR={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:BR,code(e){let{parentSchema:t,it:n}=e,{items:o}=t;if(!Array.isArray(o)){(0,ph.checkStrictMode)(n,'"additionalItems" is ignored when "items" is not an array of schemas');return}G$(e,o)}};function G$(e,t){let{gen:n,schema:o,data:r,keyword:i,it:a}=e;a.items=!0;let s=n.const("len",(0,fn._)`${r}.length`);if(o===!1)e.setParams({len:t.length}),e.pass((0,fn._)`${s} <= ${t.length}`);else if(typeof o=="object"&&!(0,ph.alwaysValidSchema)(a,o)){let l=n.var("valid",(0,fn._)`${s} <= ${t.length}`);n.if((0,fn.not)(l),()=>c(l)),e.ok(l)}function c(l){n.forRange("i",t.length,s,d=>{e.subschema({keyword:i,dataProp:d,dataPropType:ph.Type.Num},l),a.allErrors||n.if((0,fn.not)(l),()=>n.break())})}}Ta.validateAdditionalItems=G$;Ta.default=KR});var hh=A(Pa=>{"use strict";Object.defineProperty(Pa,"__esModule",{value:!0});Pa.validateTuple=void 0;var W$=re(),Pl=fe(),HR=$t(),JR={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){let{schema:t,it:n}=e;if(Array.isArray(t))return X$(e,"additionalItems",t);n.items=!0,!(0,Pl.alwaysValidSchema)(n,t)&&e.ok((0,HR.validateArray)(e))}};function X$(e,t,n=e.schema){let{gen:o,parentSchema:r,data:i,keyword:a,it:s}=e;d(r),s.opts.unevaluated&&n.length&&s.items!==!0&&(s.items=Pl.mergeEvaluated.items(o,n.length,s.items));let c=o.name("valid"),l=o.const("len",(0,W$._)`${i}.length`);n.forEach((f,_)=>{(0,Pl.alwaysValidSchema)(s,f)||(o.if((0,W$._)`${l} > ${_}`,()=>e.subschema({keyword:a,schemaProp:_,dataProp:_},c)),e.ok(c))});function d(f){let{opts:_,errSchemaPath:v}=s,g=n.length,b=g===f.minItems&&(g===f.maxItems||f[t]===!1);if(_.strictTuples&&!b){let x=`"${a}" is ${g}-tuple, but minItems or maxItems/${t} are not specified or different at path "${v}"`;(0,Pl.checkStrictMode)(s,x,_.strictTuples)}}}Pa.validateTuple=X$;Pa.default=JR});var Y$=A(gh=>{"use strict";Object.defineProperty(gh,"__esModule",{value:!0});var GR=hh(),WR={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:e=>(0,GR.validateTuple)(e,"items")};gh.default=WR});var ex=A(vh=>{"use strict";Object.defineProperty(vh,"__esModule",{value:!0});var Q$=re(),XR=fe(),YR=$t(),QR=mh(),e1={message:({params:{len:e}})=>(0,Q$.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,Q$._)`{limit: ${e}}`},t1={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:e1,code(e){let{schema:t,parentSchema:n,it:o}=e,{prefixItems:r}=n;o.items=!0,!(0,XR.alwaysValidSchema)(o,t)&&(r?(0,QR.validateAdditionalItems)(e,r):e.ok((0,YR.validateArray)(e)))}};vh.default=t1});var tx=A(_h=>{"use strict";Object.defineProperty(_h,"__esModule",{value:!0});var wt=re(),Ol=fe(),r1={message:({params:{min:e,max:t}})=>t===void 0?(0,wt.str)`must contain at least ${e} valid item(s)`:(0,wt.str)`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>t===void 0?(0,wt._)`{minContains: ${e}}`:(0,wt._)`{minContains: ${e}, maxContains: ${t}}`},n1={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:r1,code(e){let{gen:t,schema:n,parentSchema:o,data:r,it:i}=e,a,s,{minContains:c,maxContains:l}=o;i.opts.next?(a=c===void 0?1:c,s=l):a=1;let d=t.const("len",(0,wt._)`${r}.length`);if(e.setParams({min:a,max:s}),s===void 0&&a===0){(0,Ol.checkStrictMode)(i,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(s!==void 0&&a>s){(0,Ol.checkStrictMode)(i,'"minContains" > "maxContains" is always invalid'),e.fail();return}if((0,Ol.alwaysValidSchema)(i,n)){let b=(0,wt._)`${d} >= ${a}`;s!==void 0&&(b=(0,wt._)`${b} && ${d} <= ${s}`),e.pass(b);return}i.items=!0;let f=t.name("valid");s===void 0&&a===1?v(f,()=>t.if(f,()=>t.break())):a===0?(t.let(f,!0),s!==void 0&&t.if((0,wt._)`${r}.length > 0`,_)):(t.let(f,!1),_()),e.result(f,()=>e.reset());function _(){let b=t.name("_valid"),x=t.let("count",0);v(b,()=>t.if(b,()=>g(x)))}function v(b,x){t.forRange("i",0,d,I=>{e.subschema({keyword:"contains",dataProp:I,dataPropType:Ol.Type.Num,compositeRule:!0},b),x()})}function g(b){t.code((0,wt._)`${b}++`),s===void 0?t.if((0,wt._)`${b} >= ${a}`,()=>t.assign(f,!0).break()):(t.if((0,wt._)`${b} > ${s}`,()=>t.assign(f,!1).break()),a===1?t.assign(f,!0):t.if((0,wt._)`${b} >= ${a}`,()=>t.assign(f,!0)))}}};_h.default=n1});var ox=A(Kt=>{"use strict";Object.defineProperty(Kt,"__esModule",{value:!0});Kt.validateSchemaDeps=Kt.validatePropertyDeps=Kt.error=void 0;var yh=re(),o1=fe(),Oa=$t();Kt.error={message:({params:{property:e,depsCount:t,deps:n}})=>{let o=t===1?"property":"properties";return(0,yh.str)`must have ${o} ${n} when property ${e} is present`},params:({params:{property:e,depsCount:t,deps:n,missingProperty:o}})=>(0,yh._)`{property: ${e},
|
|
8
|
+
|| ${a} === "boolean" || ${r} === null`).assign(s,(0,ee._)`[${r}]`)}}}function KP({gen:e,parentData:t,parentDataProperty:n},o){e.if((0,ee._)`${t} !== undefined`,()=>e.assign((0,ee._)`${t}[${n}]`,o))}function zm(e,t,n,o=$o.Correct){let r=o===$o.Correct?ee.operators.EQ:ee.operators.NEQ,i;switch(e){case"null":return(0,ee._)`${t} ${r} null`;case"array":i=(0,ee._)`Array.isArray(${t})`;break;case"object":i=(0,ee._)`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;break;case"integer":i=a((0,ee._)`!(${t} % 1) && !isNaN(${t})`);break;case"number":i=a();break;default:return(0,ee._)`typeof ${t} ${r} ${e}`}return o===$o.Correct?i:(0,ee.not)(i);function a(s=ee.nil){return(0,ee.and)((0,ee._)`typeof ${t} == "number"`,s,n?(0,ee._)`isFinite(${t})`:ee.nil)}}Je.checkDataType=zm;function Im(e,t,n,o){if(e.length===1)return zm(e[0],t,n,o);let r,i=(0,Tb.toHash)(e);if(i.array&&i.object){let a=(0,ee._)`typeof ${t} != "object"`;r=i.null?a:(0,ee._)`!${t} || ${a}`,delete i.null,delete i.array,delete i.object}else r=ee.nil;i.number&&delete i.integer;for(let a in i)r=(0,ee.and)(r,zm(a,t,n,o));return r}Je.checkDataTypes=Im;var HP={message:({schema:e})=>`must be ${e}`,params:({schema:e,schemaValue:t})=>typeof e=="string"?(0,ee._)`{type: ${e}}`:(0,ee._)`{type: ${t}}`};function Em(e){let t=JP(e);(0,LP.reportError)(t,HP)}Je.reportTypeError=Em;function JP(e){let{gen:t,data:n,schema:o}=e,r=(0,Tb.schemaRefOrVal)(e,o,"type");return{gen:t,keyword:"type",data:n,schema:o.type,schemaCode:r,schemaValue:r,parentSchema:o,params:{},it:e}}});var Nb=A(ml=>{"use strict";Object.defineProperty(ml,"__esModule",{value:!0});ml.assignDefaults=void 0;var xo=re(),GP=fe();function WP(e,t){let{properties:n,items:o}=e.schema;if(t==="object"&&n)for(let r in n)jb(e,r,n[r].default);else t==="array"&&Array.isArray(o)&&o.forEach((r,i)=>jb(e,i,r.default))}ml.assignDefaults=WP;function jb(e,t,n){let{gen:o,compositeRule:r,data:i,opts:a}=e;if(n===void 0)return;let s=(0,xo._)`${i}${(0,xo.getProperty)(t)}`;if(r){(0,GP.checkStrictMode)(e,`default is ignored for: ${s}`);return}let c=(0,xo._)`${s} === undefined`;a.useDefaults==="empty"&&(c=(0,xo._)`${c} || ${s} === null || ${s} === ""`),o.if(c,(0,xo._)`${s} = ${(0,xo.stringify)(n)}`)}});var $t=A(_e=>{"use strict";Object.defineProperty(_e,"__esModule",{value:!0});_e.validateUnion=_e.validateArray=_e.usePattern=_e.callValidateCode=_e.schemaProperties=_e.allSchemaProperties=_e.noPropertyInData=_e.propertyInData=_e.isOwnProperty=_e.hasPropFunc=_e.reportMissingProp=_e.checkMissingProp=_e.checkReportMissingProp=void 0;var Se=re(),Tm=fe(),Nr=ir(),XP=fe();function YP(e,t){let{gen:n,data:o,it:r}=e;n.if(Pm(n,o,t,r.opts.ownProperties),()=>{e.setParams({missingProperty:(0,Se._)`${t}`},!0),e.error()})}_e.checkReportMissingProp=YP;function QP({gen:e,data:t,it:{opts:n}},o,r){return(0,Se.or)(...o.map(i=>(0,Se.and)(Pm(e,t,i,n.ownProperties),(0,Se._)`${r} = ${i}`)))}_e.checkMissingProp=QP;function ej(e,t){e.setParams({missingProperty:t},!0),e.error()}_e.reportMissingProp=ej;function Rb(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,Se._)`Object.prototype.hasOwnProperty`})}_e.hasPropFunc=Rb;function Om(e,t,n){return(0,Se._)`${Rb(e)}.call(${t}, ${n})`}_e.isOwnProperty=Om;function tj(e,t,n,o){let r=(0,Se._)`${t}${(0,Se.getProperty)(n)} !== undefined`;return o?(0,Se._)`${r} && ${Om(e,t,n)}`:r}_e.propertyInData=tj;function Pm(e,t,n,o){let r=(0,Se._)`${t}${(0,Se.getProperty)(n)} === undefined`;return o?(0,Se.or)(r,(0,Se.not)(Om(e,t,n))):r}_e.noPropertyInData=Pm;function Ab(e){return e?Object.keys(e).filter(t=>t!=="__proto__"):[]}_e.allSchemaProperties=Ab;function rj(e,t){return Ab(t).filter(n=>!(0,Tm.alwaysValidSchema)(e,t[n]))}_e.schemaProperties=rj;function nj({schemaCode:e,data:t,it:{gen:n,topSchemaRef:o,schemaPath:r,errorPath:i},it:a},s,c,l){let d=l?(0,Se._)`${e}, ${t}, ${o}${r}`:t,f=[[Nr.default.instancePath,(0,Se.strConcat)(Nr.default.instancePath,i)],[Nr.default.parentData,a.parentData],[Nr.default.parentDataProperty,a.parentDataProperty],[Nr.default.rootData,Nr.default.rootData]];a.opts.dynamicRef&&f.push([Nr.default.dynamicAnchors,Nr.default.dynamicAnchors]);let _=(0,Se._)`${d}, ${n.object(...f)}`;return c!==Se.nil?(0,Se._)`${s}.call(${c}, ${_})`:(0,Se._)`${s}(${_})`}_e.callValidateCode=nj;var oj=(0,Se._)`new RegExp`;function ij({gen:e,it:{opts:t}},n){let o=t.unicodeRegExp?"u":"",{regExp:r}=t.code,i=r(n,o);return e.scopeValue("pattern",{key:i.toString(),ref:i,code:(0,Se._)`${r.code==="new RegExp"?oj:(0,XP.useFunc)(e,r)}(${n}, ${o})`})}_e.usePattern=ij;function aj(e){let{gen:t,data:n,keyword:o,it:r}=e,i=t.name("valid");if(r.allErrors){let s=t.let("valid",!0);return a(()=>t.assign(s,!1)),s}return t.var(i,!0),a(()=>t.break()),i;function a(s){let c=t.const("len",(0,Se._)`${n}.length`);t.forRange("i",0,c,l=>{e.subschema({keyword:o,dataProp:l,dataPropType:Tm.Type.Num},i),t.if((0,Se.not)(i),s)})}}_e.validateArray=aj;function sj(e){let{gen:t,schema:n,keyword:o,it:r}=e;if(!Array.isArray(n))throw new Error("ajv implementation error");if(n.some(c=>(0,Tm.alwaysValidSchema)(r,c))&&!r.opts.unevaluated)return;let a=t.let("valid",!1),s=t.name("_valid");t.block(()=>n.forEach((c,l)=>{let d=e.subschema({keyword:o,schemaProp:l,compositeRule:!0},s);t.assign(a,(0,Se._)`${a} || ${s}`),e.mergeValidEvaluated(d,s)||t.if((0,Se.not)(a))})),e.result(a,()=>e.reset(),()=>e.error(!0))}_e.validateUnion=sj});var Ub=A(Vt=>{"use strict";Object.defineProperty(Vt,"__esModule",{value:!0});Vt.validateKeywordUsage=Vt.validSchemaType=Vt.funcKeywordCode=Vt.macroKeywordCode=void 0;var Ye=re(),cn=ir(),cj=$t(),uj=fa();function lj(e,t){let{gen:n,keyword:o,schema:r,parentSchema:i,it:a}=e,s=t.macro.call(a.self,r,i,a),c=Cb(n,o,s);a.opts.validateSchema!==!1&&a.self.validateSchema(s,!0);let l=n.name("valid");e.subschema({schema:s,schemaPath:Ye.nil,errSchemaPath:`${a.errSchemaPath}/${o}`,topSchemaRef:c,compositeRule:!0},l),e.pass(l,()=>e.error(!0))}Vt.macroKeywordCode=lj;function dj(e,t){var n;let{gen:o,keyword:r,schema:i,parentSchema:a,$data:s,it:c}=e;pj(c,t);let l=!s&&t.compile?t.compile.call(c.self,i,a,c):t.validate,d=Cb(o,r,l),f=o.let("valid");e.block$data(f,_),e.ok((n=t.valid)!==null&&n!==void 0?n:f);function _(){if(t.errors===!1)b(),t.modifying&&Db(e),x(()=>e.error());else{let I=t.async?v():g();t.modifying&&Db(e),x(()=>fj(e,I))}}function v(){let I=o.let("ruleErrs",null);return o.try(()=>b((0,Ye._)`await `),R=>o.assign(f,!1).if((0,Ye._)`${R} instanceof ${c.ValidationError}`,()=>o.assign(I,(0,Ye._)`${R}.errors`),()=>o.throw(R))),I}function g(){let I=(0,Ye._)`${d}.errors`;return o.assign(I,null),b(Ye.nil),I}function b(I=t.async?(0,Ye._)`await `:Ye.nil){let R=c.opts.passContext?cn.default.this:cn.default.self,O=!("compile"in t&&!s||t.schema===!1);o.assign(f,(0,Ye._)`${I}${(0,cj.callValidateCode)(e,d,R,O)}`,t.modifying)}function x(I){var R;o.if((0,Ye.not)((R=t.valid)!==null&&R!==void 0?R:f),I)}}Vt.funcKeywordCode=dj;function Db(e){let{gen:t,data:n,it:o}=e;t.if(o.parentData,()=>t.assign(n,(0,Ye._)`${o.parentData}[${o.parentDataProperty}]`))}function fj(e,t){let{gen:n}=e;n.if((0,Ye._)`Array.isArray(${t})`,()=>{n.assign(cn.default.vErrors,(0,Ye._)`${cn.default.vErrors} === null ? ${t} : ${cn.default.vErrors}.concat(${t})`).assign(cn.default.errors,(0,Ye._)`${cn.default.vErrors}.length`),(0,uj.extendErrors)(e)},()=>e.error())}function pj({schemaEnv:e},t){if(t.async&&!e.$async)throw new Error("async keyword in sync schema")}function Cb(e,t,n){if(n===void 0)throw new Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword",typeof n=="function"?{ref:n}:{ref:n,code:(0,Ye.stringify)(n)})}function mj(e,t,n=!1){return!t.length||t.some(o=>o==="array"?Array.isArray(e):o==="object"?e&&typeof e=="object"&&!Array.isArray(e):typeof e==o||n&&typeof e>"u")}Vt.validSchemaType=mj;function hj({schema:e,opts:t,self:n,errSchemaPath:o},r,i){if(Array.isArray(r.keyword)?!r.keyword.includes(i):r.keyword!==i)throw new Error("ajv implementation error");let a=r.dependencies;if(a?.some(s=>!Object.prototype.hasOwnProperty.call(e,s)))throw new Error(`parent schema must have dependencies of ${i}: ${a.join(",")}`);if(r.validateSchema&&!r.validateSchema(e[i])){let c=`keyword "${i}" value is invalid at path "${o}": `+n.errorsText(r.validateSchema.errors);if(t.validateSchema==="log")n.logger.error(c);else throw new Error(c)}}Vt.validateKeywordUsage=hj});var Mb=A(Rr=>{"use strict";Object.defineProperty(Rr,"__esModule",{value:!0});Rr.extendSubschemaMode=Rr.extendSubschemaData=Rr.getSubschema=void 0;var Ft=re(),Zb=fe();function gj(e,{keyword:t,schemaProp:n,schema:o,schemaPath:r,errSchemaPath:i,topSchemaRef:a}){if(t!==void 0&&o!==void 0)throw new Error('both "keyword" and "schema" passed, only one allowed');if(t!==void 0){let s=e.schema[t];return n===void 0?{schema:s,schemaPath:(0,Ft._)`${e.schemaPath}${(0,Ft.getProperty)(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:s[n],schemaPath:(0,Ft._)`${e.schemaPath}${(0,Ft.getProperty)(t)}${(0,Ft.getProperty)(n)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${(0,Zb.escapeFragment)(n)}`}}if(o!==void 0){if(r===void 0||i===void 0||a===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:o,schemaPath:r,topSchemaRef:a,errSchemaPath:i}}throw new Error('either "keyword" or "schema" must be passed')}Rr.getSubschema=gj;function vj(e,t,{dataProp:n,dataPropType:o,data:r,dataTypes:i,propertyName:a}){if(r!==void 0&&n!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');let{gen:s}=t;if(n!==void 0){let{errorPath:l,dataPathArr:d,opts:f}=t,_=s.let("data",(0,Ft._)`${t.data}${(0,Ft.getProperty)(n)}`,!0);c(_),e.errorPath=(0,Ft.str)`${l}${(0,Zb.getErrorPath)(n,o,f.jsPropertySyntax)}`,e.parentDataProperty=(0,Ft._)`${n}`,e.dataPathArr=[...d,e.parentDataProperty]}if(r!==void 0){let l=r instanceof Ft.Name?r:s.let("data",r,!0);c(l),a!==void 0&&(e.propertyName=a)}i&&(e.dataTypes=i);function c(l){e.data=l,e.dataLevel=t.dataLevel+1,e.dataTypes=[],t.definedProperties=new Set,e.parentData=t.data,e.dataNames=[...t.dataNames,l]}}Rr.extendSubschemaData=vj;function _j(e,{jtdDiscriminator:t,jtdMetadata:n,compositeRule:o,createErrors:r,allErrors:i}){o!==void 0&&(e.compositeRule=o),r!==void 0&&(e.createErrors=r),i!==void 0&&(e.allErrors=i),e.jtdDiscriminator=t,e.jtdMetadata=n}Rr.extendSubschemaMode=_j});var jm=A((L2,Lb)=>{"use strict";Lb.exports=function e(t,n){if(t===n)return!0;if(t&&n&&typeof t=="object"&&typeof n=="object"){if(t.constructor!==n.constructor)return!1;var o,r,i;if(Array.isArray(t)){if(o=t.length,o!=n.length)return!1;for(r=o;r--!==0;)if(!e(t[r],n[r]))return!1;return!0}if(t.constructor===RegExp)return t.source===n.source&&t.flags===n.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===n.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===n.toString();if(i=Object.keys(t),o=i.length,o!==Object.keys(n).length)return!1;for(r=o;r--!==0;)if(!Object.prototype.hasOwnProperty.call(n,i[r]))return!1;for(r=o;r--!==0;){var a=i[r];if(!e(t[a],n[a]))return!1}return!0}return t!==t&&n!==n}});var Vb=A((q2,qb)=>{"use strict";var Ar=qb.exports=function(e,t,n){typeof t=="function"&&(n=t,t={}),n=t.cb||n;var o=typeof n=="function"?n:n.pre||function(){},r=n.post||function(){};hl(t,o,r,e,"",e)};Ar.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};Ar.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};Ar.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};Ar.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function hl(e,t,n,o,r,i,a,s,c,l){if(o&&typeof o=="object"&&!Array.isArray(o)){t(o,r,i,a,s,c,l);for(var d in o){var f=o[d];if(Array.isArray(f)){if(d in Ar.arrayKeywords)for(var _=0;_<f.length;_++)hl(e,t,n,f[_],r+"/"+d+"/"+_,i,r,d,o,_)}else if(d in Ar.propsKeywords){if(f&&typeof f=="object")for(var v in f)hl(e,t,n,f[v],r+"/"+d+"/"+yj(v),i,r,d,o,v)}else(d in Ar.keywords||e.allKeys&&!(d in Ar.skipKeywords))&&hl(e,t,n,f,r+"/"+d,i,r,d,o)}n(o,r,i,a,s,c,l)}}function yj(e){return e.replace(/~/g,"~0").replace(/\//g,"~1")}});var ma=A(at=>{"use strict";Object.defineProperty(at,"__esModule",{value:!0});at.getSchemaRefs=at.resolveUrl=at.normalizeId=at._getFullPath=at.getFullPath=at.inlineRef=void 0;var bj=fe(),$j=jm(),xj=Vb(),wj=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function kj(e,t=!0){return typeof e=="boolean"?!0:t===!0?!Nm(e):t?Fb(e)<=t:!1}at.inlineRef=kj;var Sj=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function Nm(e){for(let t in e){if(Sj.has(t))return!0;let n=e[t];if(Array.isArray(n)&&n.some(Nm)||typeof n=="object"&&Nm(n))return!0}return!1}function Fb(e){let t=0;for(let n in e){if(n==="$ref")return 1/0;if(t++,!wj.has(n)&&(typeof e[n]=="object"&&(0,bj.eachItem)(e[n],o=>t+=Fb(o)),t===1/0))return 1/0}return t}function Bb(e,t="",n){n!==!1&&(t=wo(t));let o=e.parse(t);return Kb(e,o)}at.getFullPath=Bb;function Kb(e,t){return e.serialize(t).split("#")[0]+"#"}at._getFullPath=Kb;var zj=/#\/?$/;function wo(e){return e?e.replace(zj,""):""}at.normalizeId=wo;function Ij(e,t,n){return n=wo(n),e.resolve(t,n)}at.resolveUrl=Ij;var Ej=/^[a-z_][-a-z0-9._]*$/i;function Tj(e,t){if(typeof e=="boolean")return{};let{schemaId:n,uriResolver:o}=this.opts,r=wo(e[n]||t),i={"":r},a=Bb(o,r,!1),s={},c=new Set;return xj(e,{allKeys:!0},(f,_,v,g)=>{if(g===void 0)return;let b=a+_,x=i[g];typeof f[n]=="string"&&(x=I.call(this,f[n])),R.call(this,f.$anchor),R.call(this,f.$dynamicAnchor),i[_]=x;function I(O){let M=this.opts.uriResolver.resolve;if(O=wo(x?M(x,O):O),c.has(O))throw d(O);c.add(O);let V=this.refs[O];return typeof V=="string"&&(V=this.refs[V]),typeof V=="object"?l(f,V.schema,O):O!==wo(b)&&(O[0]==="#"?(l(f,s[O],O),s[O]=f):this.refs[O]=b),O}function R(O){if(typeof O=="string"){if(!Ej.test(O))throw new Error(`invalid anchor "${O}"`);I.call(this,`#${O}`)}}}),s;function l(f,_,v){if(_!==void 0&&!$j(f,_))throw d(v)}function d(f){return new Error(`reference "${f}" resolves to more than one schema`)}}at.getSchemaRefs=Tj});var va=A(Dr=>{"use strict";Object.defineProperty(Dr,"__esModule",{value:!0});Dr.getData=Dr.KeywordCxt=Dr.validateFunctionCode=void 0;var Xb=zb(),Hb=pa(),Am=Sm(),gl=pa(),Oj=Nb(),ga=Ub(),Rm=Mb(),K=re(),X=ir(),Pj=ma(),ar=fe(),ha=fa();function jj(e){if(e$(e)&&(t$(e),Qb(e))){Aj(e);return}Yb(e,()=>(0,Xb.topBoolOrEmptySchema)(e))}Dr.validateFunctionCode=jj;function Yb({gen:e,validateName:t,schema:n,schemaEnv:o,opts:r},i){r.code.es5?e.func(t,(0,K._)`${X.default.data}, ${X.default.valCxt}`,o.$async,()=>{e.code((0,K._)`"use strict"; ${Jb(n,r)}`),Rj(e,r),e.code(i)}):e.func(t,(0,K._)`${X.default.data}, ${Nj(r)}`,o.$async,()=>e.code(Jb(n,r)).code(i))}function Nj(e){return(0,K._)`{${X.default.instancePath}="", ${X.default.parentData}, ${X.default.parentDataProperty}, ${X.default.rootData}=${X.default.data}${e.dynamicRef?(0,K._)`, ${X.default.dynamicAnchors}={}`:K.nil}}={}`}function Rj(e,t){e.if(X.default.valCxt,()=>{e.var(X.default.instancePath,(0,K._)`${X.default.valCxt}.${X.default.instancePath}`),e.var(X.default.parentData,(0,K._)`${X.default.valCxt}.${X.default.parentData}`),e.var(X.default.parentDataProperty,(0,K._)`${X.default.valCxt}.${X.default.parentDataProperty}`),e.var(X.default.rootData,(0,K._)`${X.default.valCxt}.${X.default.rootData}`),t.dynamicRef&&e.var(X.default.dynamicAnchors,(0,K._)`${X.default.valCxt}.${X.default.dynamicAnchors}`)},()=>{e.var(X.default.instancePath,(0,K._)`""`),e.var(X.default.parentData,(0,K._)`undefined`),e.var(X.default.parentDataProperty,(0,K._)`undefined`),e.var(X.default.rootData,X.default.data),t.dynamicRef&&e.var(X.default.dynamicAnchors,(0,K._)`{}`)})}function Aj(e){let{schema:t,opts:n,gen:o}=e;Yb(e,()=>{n.$comment&&t.$comment&&n$(e),Mj(e),o.let(X.default.vErrors,null),o.let(X.default.errors,0),n.unevaluated&&Dj(e),r$(e),Vj(e)})}function Dj(e){let{gen:t,validateName:n}=e;e.evaluated=t.const("evaluated",(0,K._)`${n}.evaluated`),t.if((0,K._)`${e.evaluated}.dynamicProps`,()=>t.assign((0,K._)`${e.evaluated}.props`,(0,K._)`undefined`)),t.if((0,K._)`${e.evaluated}.dynamicItems`,()=>t.assign((0,K._)`${e.evaluated}.items`,(0,K._)`undefined`))}function Jb(e,t){let n=typeof e=="object"&&e[t.schemaId];return n&&(t.code.source||t.code.process)?(0,K._)`/*# sourceURL=${n} */`:K.nil}function Cj(e,t){if(e$(e)&&(t$(e),Qb(e))){Uj(e,t);return}(0,Xb.boolOrEmptySchema)(e,t)}function Qb({schema:e,self:t}){if(typeof e=="boolean")return!e;for(let n in e)if(t.RULES.all[n])return!0;return!1}function e$(e){return typeof e.schema!="boolean"}function Uj(e,t){let{schema:n,gen:o,opts:r}=e;r.$comment&&n.$comment&&n$(e),Lj(e),qj(e);let i=o.const("_errs",X.default.errors);r$(e,i),o.var(t,(0,K._)`${i} === ${X.default.errors}`)}function t$(e){(0,ar.checkUnknownRules)(e),Zj(e)}function r$(e,t){if(e.opts.jtd)return Gb(e,[],!1,t);let n=(0,Hb.getSchemaTypes)(e.schema),o=(0,Hb.coerceAndCheckDataType)(e,n);Gb(e,n,!o,t)}function Zj(e){let{schema:t,errSchemaPath:n,opts:o,self:r}=e;t.$ref&&o.ignoreKeywordsWithRef&&(0,ar.schemaHasRulesButRef)(t,r.RULES)&&r.logger.warn(`$ref: keywords ignored in schema at path "${n}"`)}function Mj(e){let{schema:t,opts:n}=e;t.default!==void 0&&n.useDefaults&&n.strictSchema&&(0,ar.checkStrictMode)(e,"default is ignored in the schema root")}function Lj(e){let t=e.schema[e.opts.schemaId];t&&(e.baseId=(0,Pj.resolveUrl)(e.opts.uriResolver,e.baseId,t))}function qj(e){if(e.schema.$async&&!e.schemaEnv.$async)throw new Error("async schema in sync schema")}function n$({gen:e,schemaEnv:t,schema:n,errSchemaPath:o,opts:r}){let i=n.$comment;if(r.$comment===!0)e.code((0,K._)`${X.default.self}.logger.log(${i})`);else if(typeof r.$comment=="function"){let a=(0,K.str)`${o}/$comment`,s=e.scopeValue("root",{ref:t.root});e.code((0,K._)`${X.default.self}.opts.$comment(${i}, ${a}, ${s}.schema)`)}}function Vj(e){let{gen:t,schemaEnv:n,validateName:o,ValidationError:r,opts:i}=e;n.$async?t.if((0,K._)`${X.default.errors} === 0`,()=>t.return(X.default.data),()=>t.throw((0,K._)`new ${r}(${X.default.vErrors})`)):(t.assign((0,K._)`${o}.errors`,X.default.vErrors),i.unevaluated&&Fj(e),t.return((0,K._)`${X.default.errors} === 0`))}function Fj({gen:e,evaluated:t,props:n,items:o}){n instanceof K.Name&&e.assign((0,K._)`${t}.props`,n),o instanceof K.Name&&e.assign((0,K._)`${t}.items`,o)}function Gb(e,t,n,o){let{gen:r,schema:i,data:a,allErrors:s,opts:c,self:l}=e,{RULES:d}=l;if(i.$ref&&(c.ignoreKeywordsWithRef||!(0,ar.schemaHasRulesButRef)(i,d))){r.block(()=>i$(e,"$ref",d.all.$ref.definition));return}c.jtd||Bj(e,t),r.block(()=>{for(let _ of d.rules)f(_);f(d.post)});function f(_){(0,Am.shouldUseGroup)(i,_)&&(_.type?(r.if((0,gl.checkDataType)(_.type,a,c.strictNumbers)),Wb(e,_),t.length===1&&t[0]===_.type&&n&&(r.else(),(0,gl.reportTypeError)(e)),r.endIf()):Wb(e,_),s||r.if((0,K._)`${X.default.errors} === ${o||0}`))}}function Wb(e,t){let{gen:n,schema:o,opts:{useDefaults:r}}=e;r&&(0,Oj.assignDefaults)(e,t.type),n.block(()=>{for(let i of t.rules)(0,Am.shouldUseRule)(o,i)&&i$(e,i.keyword,i.definition,t.type)})}function Bj(e,t){e.schemaEnv.meta||!e.opts.strictTypes||(Kj(e,t),e.opts.allowUnionTypes||Hj(e,t),Jj(e,e.dataTypes))}function Kj(e,t){if(t.length){if(!e.dataTypes.length){e.dataTypes=t;return}t.forEach(n=>{o$(e.dataTypes,n)||Dm(e,`type "${n}" not allowed by context "${e.dataTypes.join(",")}"`)}),Wj(e,t)}}function Hj(e,t){t.length>1&&!(t.length===2&&t.includes("null"))&&Dm(e,"use allowUnionTypes to allow union type keyword")}function Jj(e,t){let n=e.self.RULES.all;for(let o in n){let r=n[o];if(typeof r=="object"&&(0,Am.shouldUseRule)(e.schema,r)){let{type:i}=r.definition;i.length&&!i.some(a=>Gj(t,a))&&Dm(e,`missing type "${i.join(",")}" for keyword "${o}"`)}}}function Gj(e,t){return e.includes(t)||t==="number"&&e.includes("integer")}function o$(e,t){return e.includes(t)||t==="integer"&&e.includes("number")}function Wj(e,t){let n=[];for(let o of e.dataTypes)o$(t,o)?n.push(o):t.includes("integer")&&o==="number"&&n.push("integer");e.dataTypes=n}function Dm(e,t){let n=e.schemaEnv.baseId+e.errSchemaPath;t+=` at "${n}" (strictTypes)`,(0,ar.checkStrictMode)(e,t,e.opts.strictTypes)}var vl=class{constructor(t,n,o){if((0,ga.validateKeywordUsage)(t,n,o),this.gen=t.gen,this.allErrors=t.allErrors,this.keyword=o,this.data=t.data,this.schema=t.schema[o],this.$data=n.$data&&t.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,ar.schemaRefOrVal)(t,this.schema,o,this.$data),this.schemaType=n.schemaType,this.parentSchema=t.schema,this.params={},this.it=t,this.def=n,this.$data)this.schemaCode=t.gen.const("vSchema",a$(this.$data,t));else if(this.schemaCode=this.schemaValue,!(0,ga.validSchemaType)(this.schema,n.schemaType,n.allowUndefined))throw new Error(`${o} value must be ${JSON.stringify(n.schemaType)}`);("code"in n?n.trackErrors:n.errors!==!1)&&(this.errsCount=t.gen.const("_errs",X.default.errors))}result(t,n,o){this.failResult((0,K.not)(t),n,o)}failResult(t,n,o){this.gen.if(t),o?o():this.error(),n?(this.gen.else(),n(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(t,n){this.failResult((0,K.not)(t),void 0,n)}fail(t){if(t===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(t),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(t){if(!this.$data)return this.fail(t);let{schemaCode:n}=this;this.fail((0,K._)`${n} !== undefined && (${(0,K.or)(this.invalid$data(),t)})`)}error(t,n,o){if(n){this.setParams(n),this._error(t,o),this.setParams({});return}this._error(t,o)}_error(t,n){(t?ha.reportExtraError:ha.reportError)(this,this.def.error,n)}$dataError(){(0,ha.reportError)(this,this.def.$dataError||ha.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,ha.resetErrorsCount)(this.gen,this.errsCount)}ok(t){this.allErrors||this.gen.if(t)}setParams(t,n){n?Object.assign(this.params,t):this.params=t}block$data(t,n,o=K.nil){this.gen.block(()=>{this.check$data(t,o),n()})}check$data(t=K.nil,n=K.nil){if(!this.$data)return;let{gen:o,schemaCode:r,schemaType:i,def:a}=this;o.if((0,K.or)((0,K._)`${r} === undefined`,n)),t!==K.nil&&o.assign(t,!0),(i.length||a.validateSchema)&&(o.elseIf(this.invalid$data()),this.$dataError(),t!==K.nil&&o.assign(t,!1)),o.else()}invalid$data(){let{gen:t,schemaCode:n,schemaType:o,def:r,it:i}=this;return(0,K.or)(a(),s());function a(){if(o.length){if(!(n instanceof K.Name))throw new Error("ajv implementation error");let c=Array.isArray(o)?o:[o];return(0,K._)`${(0,gl.checkDataTypes)(c,n,i.opts.strictNumbers,gl.DataType.Wrong)}`}return K.nil}function s(){if(r.validateSchema){let c=t.scopeValue("validate$data",{ref:r.validateSchema});return(0,K._)`!${c}(${n})`}return K.nil}}subschema(t,n){let o=(0,Rm.getSubschema)(this.it,t);(0,Rm.extendSubschemaData)(o,this.it,t),(0,Rm.extendSubschemaMode)(o,t);let r={...this.it,...o,items:void 0,props:void 0};return Cj(r,n),r}mergeEvaluated(t,n){let{it:o,gen:r}=this;o.opts.unevaluated&&(o.props!==!0&&t.props!==void 0&&(o.props=ar.mergeEvaluated.props(r,t.props,o.props,n)),o.items!==!0&&t.items!==void 0&&(o.items=ar.mergeEvaluated.items(r,t.items,o.items,n)))}mergeValidEvaluated(t,n){let{it:o,gen:r}=this;if(o.opts.unevaluated&&(o.props!==!0||o.items!==!0))return r.if(n,()=>this.mergeEvaluated(t,K.Name)),!0}};Dr.KeywordCxt=vl;function i$(e,t,n,o){let r=new vl(e,n,t);"code"in n?n.code(r,o):r.$data&&n.validate?(0,ga.funcKeywordCode)(r,n):"macro"in n?(0,ga.macroKeywordCode)(r,n):(n.compile||n.validate)&&(0,ga.funcKeywordCode)(r,n)}var Xj=/^\/(?:[^~]|~0|~1)*$/,Yj=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function a$(e,{dataLevel:t,dataNames:n,dataPathArr:o}){let r,i;if(e==="")return X.default.rootData;if(e[0]==="/"){if(!Xj.test(e))throw new Error(`Invalid JSON-pointer: ${e}`);r=e,i=X.default.rootData}else{let l=Yj.exec(e);if(!l)throw new Error(`Invalid JSON-pointer: ${e}`);let d=+l[1];if(r=l[2],r==="#"){if(d>=t)throw new Error(c("property/index",d));return o[t-d]}if(d>t)throw new Error(c("data",d));if(i=n[t-d],!r)return i}let a=i,s=r.split("/");for(let l of s)l&&(i=(0,K._)`${i}${(0,K.getProperty)((0,ar.unescapeJsonPointer)(l))}`,a=(0,K._)`${a} && ${i}`);return a;function c(l,d){return`Cannot access ${l} ${d} levels up, current level is ${t}`}}Dr.getData=a$});var _l=A(Um=>{"use strict";Object.defineProperty(Um,"__esModule",{value:!0});var Cm=class extends Error{constructor(t){super("validation failed"),this.errors=t,this.ajv=this.validation=!0}};Um.default=Cm});var _a=A(Lm=>{"use strict";Object.defineProperty(Lm,"__esModule",{value:!0});var Zm=ma(),Mm=class extends Error{constructor(t,n,o,r){super(r||`can't resolve reference ${o} from id ${n}`),this.missingRef=(0,Zm.resolveUrl)(t,n,o),this.missingSchema=(0,Zm.normalizeId)((0,Zm.getFullPath)(t,this.missingRef))}};Lm.default=Mm});var bl=A(xt=>{"use strict";Object.defineProperty(xt,"__esModule",{value:!0});xt.resolveSchema=xt.getCompilingSchema=xt.resolveRef=xt.compileSchema=xt.SchemaEnv=void 0;var Nt=re(),Qj=_l(),un=ir(),Rt=ma(),s$=fe(),eN=va(),ko=class{constructor(t){var n;this.refs={},this.dynamicAnchors={};let o;typeof t.schema=="object"&&(o=t.schema),this.schema=t.schema,this.schemaId=t.schemaId,this.root=t.root||this,this.baseId=(n=t.baseId)!==null&&n!==void 0?n:(0,Rt.normalizeId)(o?.[t.schemaId||"$id"]),this.schemaPath=t.schemaPath,this.localRefs=t.localRefs,this.meta=t.meta,this.$async=o?.$async,this.refs={}}};xt.SchemaEnv=ko;function Vm(e){let t=c$.call(this,e);if(t)return t;let n=(0,Rt.getFullPath)(this.opts.uriResolver,e.root.baseId),{es5:o,lines:r}=this.opts.code,{ownProperties:i}=this.opts,a=new Nt.CodeGen(this.scope,{es5:o,lines:r,ownProperties:i}),s;e.$async&&(s=a.scopeValue("Error",{ref:Qj.default,code:(0,Nt._)`require("ajv/dist/runtime/validation_error").default`}));let c=a.scopeName("validate");e.validateName=c;let l={gen:a,allErrors:this.opts.allErrors,data:un.default.data,parentData:un.default.parentData,parentDataProperty:un.default.parentDataProperty,dataNames:[un.default.data],dataPathArr:[Nt.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:a.scopeValue("schema",this.opts.code.source===!0?{ref:e.schema,code:(0,Nt.stringify)(e.schema)}:{ref:e.schema}),validateName:c,ValidationError:s,schema:e.schema,schemaEnv:e,rootId:n,baseId:e.baseId||n,schemaPath:Nt.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,Nt._)`""`,opts:this.opts,self:this},d;try{this._compilations.add(e),(0,eN.validateFunctionCode)(l),a.optimize(this.opts.code.optimize);let f=a.toString();d=`${a.scopeRefs(un.default.scope)}return ${f}`,this.opts.code.process&&(d=this.opts.code.process(d,e));let v=new Function(`${un.default.self}`,`${un.default.scope}`,d)(this,this.scope.get());if(this.scope.value(c,{ref:v}),v.errors=null,v.schema=e.schema,v.schemaEnv=e,e.$async&&(v.$async=!0),this.opts.code.source===!0&&(v.source={validateName:c,validateCode:f,scopeValues:a._values}),this.opts.unevaluated){let{props:g,items:b}=l;v.evaluated={props:g instanceof Nt.Name?void 0:g,items:b instanceof Nt.Name?void 0:b,dynamicProps:g instanceof Nt.Name,dynamicItems:b instanceof Nt.Name},v.source&&(v.source.evaluated=(0,Nt.stringify)(v.evaluated))}return e.validate=v,e}catch(f){throw delete e.validate,delete e.validateName,d&&this.logger.error("Error compiling schema, function code:",d),f}finally{this._compilations.delete(e)}}xt.compileSchema=Vm;function tN(e,t,n){var o;n=(0,Rt.resolveUrl)(this.opts.uriResolver,t,n);let r=e.refs[n];if(r)return r;let i=oN.call(this,e,n);if(i===void 0){let a=(o=e.localRefs)===null||o===void 0?void 0:o[n],{schemaId:s}=this.opts;a&&(i=new ko({schema:a,schemaId:s,root:e,baseId:t}))}if(i!==void 0)return e.refs[n]=rN.call(this,i)}xt.resolveRef=tN;function rN(e){return(0,Rt.inlineRef)(e.schema,this.opts.inlineRefs)?e.schema:e.validate?e:Vm.call(this,e)}function c$(e){for(let t of this._compilations)if(nN(t,e))return t}xt.getCompilingSchema=c$;function nN(e,t){return e.schema===t.schema&&e.root===t.root&&e.baseId===t.baseId}function oN(e,t){let n;for(;typeof(n=this.refs[t])=="string";)t=n;return n||this.schemas[t]||yl.call(this,e,t)}function yl(e,t){let n=this.opts.uriResolver.parse(t),o=(0,Rt._getFullPath)(this.opts.uriResolver,n),r=(0,Rt.getFullPath)(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&o===r)return qm.call(this,n,e);let i=(0,Rt.normalizeId)(o),a=this.refs[i]||this.schemas[i];if(typeof a=="string"){let s=yl.call(this,e,a);return typeof s?.schema!="object"?void 0:qm.call(this,n,s)}if(typeof a?.schema=="object"){if(a.validate||Vm.call(this,a),i===(0,Rt.normalizeId)(t)){let{schema:s}=a,{schemaId:c}=this.opts,l=s[c];return l&&(r=(0,Rt.resolveUrl)(this.opts.uriResolver,r,l)),new ko({schema:s,schemaId:c,root:e,baseId:r})}return qm.call(this,n,a)}}xt.resolveSchema=yl;var iN=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function qm(e,{baseId:t,schema:n,root:o}){var r;if(((r=e.fragment)===null||r===void 0?void 0:r[0])!=="/")return;for(let s of e.fragment.slice(1).split("/")){if(typeof n=="boolean")return;let c=n[(0,s$.unescapeFragment)(s)];if(c===void 0)return;n=c;let l=typeof n=="object"&&n[this.opts.schemaId];!iN.has(s)&&l&&(t=(0,Rt.resolveUrl)(this.opts.uriResolver,t,l))}let i;if(typeof n!="boolean"&&n.$ref&&!(0,s$.schemaHasRulesButRef)(n,this.RULES)){let s=(0,Rt.resolveUrl)(this.opts.uriResolver,t,n.$ref);i=yl.call(this,o,s)}let{schemaId:a}=this.opts;if(i=i||new ko({schema:n,schemaId:a,root:o,baseId:t}),i.schema!==i.root.schema)return i}});var u$=A((J2,aN)=>{aN.exports={$id:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",description:"Meta-schema for $data reference (JSON AnySchema extension proposal)",type:"object",required:["$data"],properties:{$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},additionalProperties:!1}});var Bm=A((G2,p$)=>{"use strict";var sN=RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu),d$=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);function Fm(e){let t="",n=0,o=0;for(o=0;o<e.length;o++)if(n=e[o].charCodeAt(0),n!==48){if(!(n>=48&&n<=57||n>=65&&n<=70||n>=97&&n<=102))return"";t+=e[o];break}for(o+=1;o<e.length;o++){if(n=e[o].charCodeAt(0),!(n>=48&&n<=57||n>=65&&n<=70||n>=97&&n<=102))return"";t+=e[o]}return t}var cN=RegExp.prototype.test.bind(/[^!"$&'()*+,\-.;=_`a-z{}~]/u);function l$(e){return e.length=0,!0}function uN(e,t,n){if(e.length){let o=Fm(e);if(o!=="")t.push(o);else return n.error=!0,!1;e.length=0}return!0}function lN(e){let t=0,n={error:!1,address:"",zone:""},o=[],r=[],i=!1,a=!1,s=uN;for(let c=0;c<e.length;c++){let l=e[c];if(!(l==="["||l==="]"))if(l===":"){if(i===!0&&(a=!0),!s(r,o,n))break;if(++t>7){n.error=!0;break}c>0&&e[c-1]===":"&&(i=!0),o.push(":");continue}else if(l==="%"){if(!s(r,o,n))break;s=l$}else{r.push(l);continue}}return r.length&&(s===l$?n.zone=r.join(""):a?o.push(r.join("")):o.push(Fm(r))),n.address=o.join(""),n}function f$(e){if(dN(e,":")<2)return{host:e,isIPV6:!1};let t=lN(e);if(t.error)return{host:e,isIPV6:!1};{let n=t.address,o=t.address;return t.zone&&(n+="%"+t.zone,o+="%25"+t.zone),{host:n,isIPV6:!0,escapedHost:o}}}function dN(e,t){let n=0;for(let o=0;o<e.length;o++)e[o]===t&&n++;return n}function fN(e){let t=e,n=[],o=-1,r=0;for(;r=t.length;){if(r===1){if(t===".")break;if(t==="/"){n.push("/");break}else{n.push(t);break}}else if(r===2){if(t[0]==="."){if(t[1]===".")break;if(t[1]==="/"){t=t.slice(2);continue}}else if(t[0]==="/"&&(t[1]==="."||t[1]==="/")){n.push("/");break}}else if(r===3&&t==="/.."){n.length!==0&&n.pop(),n.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),n.length!==0&&n.pop();continue}}if((o=t.indexOf("/",1))===-1){n.push(t);break}else n.push(t.slice(0,o)),t=t.slice(o)}return n.join("")}function pN(e,t){let n=t!==!0?escape:unescape;return e.scheme!==void 0&&(e.scheme=n(e.scheme)),e.userinfo!==void 0&&(e.userinfo=n(e.userinfo)),e.host!==void 0&&(e.host=n(e.host)),e.path!==void 0&&(e.path=n(e.path)),e.query!==void 0&&(e.query=n(e.query)),e.fragment!==void 0&&(e.fragment=n(e.fragment)),e}function mN(e){let t=[];if(e.userinfo!==void 0&&(t.push(e.userinfo),t.push("@")),e.host!==void 0){let n=unescape(e.host);if(!d$(n)){let o=f$(n);o.isIPV6===!0?n=`[${o.escapedHost}]`:n=e.host}t.push(n)}return(typeof e.port=="number"||typeof e.port=="string")&&(t.push(":"),t.push(String(e.port))),t.length?t.join(""):void 0}p$.exports={nonSimpleDomain:cN,recomposeAuthority:mN,normalizeComponentEncoding:pN,removeDotSegments:fN,isIPv4:d$,isUUID:sN,normalizeIPv6:f$,stringArrayToHexStripped:Fm}});var _$=A((W2,v$)=>{"use strict";var{isUUID:hN}=Bm(),gN=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu,vN=["http","https","ws","wss","urn","urn:uuid"];function _N(e){return vN.indexOf(e)!==-1}function Km(e){return e.secure===!0?!0:e.secure===!1?!1:e.scheme?e.scheme.length===3&&(e.scheme[0]==="w"||e.scheme[0]==="W")&&(e.scheme[1]==="s"||e.scheme[1]==="S")&&(e.scheme[2]==="s"||e.scheme[2]==="S"):!1}function m$(e){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e}function h$(e){let t=String(e.scheme).toLowerCase()==="https";return(e.port===(t?443:80)||e.port==="")&&(e.port=void 0),e.path||(e.path="/"),e}function yN(e){return e.secure=Km(e),e.resourceName=(e.path||"/")+(e.query?"?"+e.query:""),e.path=void 0,e.query=void 0,e}function bN(e){if((e.port===(Km(e)?443:80)||e.port==="")&&(e.port=void 0),typeof e.secure=="boolean"&&(e.scheme=e.secure?"wss":"ws",e.secure=void 0),e.resourceName){let[t,n]=e.resourceName.split("?");e.path=t&&t!=="/"?t:void 0,e.query=n,e.resourceName=void 0}return e.fragment=void 0,e}function $N(e,t){if(!e.path)return e.error="URN can not be parsed",e;let n=e.path.match(gN);if(n){let o=t.scheme||e.scheme||"urn";e.nid=n[1].toLowerCase(),e.nss=n[2];let r=`${o}:${t.nid||e.nid}`,i=Hm(r);e.path=void 0,i&&(e=i.parse(e,t))}else e.error=e.error||"URN can not be parsed.";return e}function xN(e,t){if(e.nid===void 0)throw new Error("URN without nid cannot be serialized");let n=t.scheme||e.scheme||"urn",o=e.nid.toLowerCase(),r=`${n}:${t.nid||o}`,i=Hm(r);i&&(e=i.serialize(e,t));let a=e,s=e.nss;return a.path=`${o||t.nid}:${s}`,t.skipEscape=!0,a}function wN(e,t){let n=e;return n.uuid=n.nss,n.nss=void 0,!t.tolerant&&(!n.uuid||!hN(n.uuid))&&(n.error=n.error||"UUID is not valid."),n}function kN(e){let t=e;return t.nss=(e.uuid||"").toLowerCase(),t}var g$={scheme:"http",domainHost:!0,parse:m$,serialize:h$},SN={scheme:"https",domainHost:g$.domainHost,parse:m$,serialize:h$},$l={scheme:"ws",domainHost:!0,parse:yN,serialize:bN},zN={scheme:"wss",domainHost:$l.domainHost,parse:$l.parse,serialize:$l.serialize},IN={scheme:"urn",parse:$N,serialize:xN,skipNormalize:!0},EN={scheme:"urn:uuid",parse:wN,serialize:kN,skipNormalize:!0},xl={http:g$,https:SN,ws:$l,wss:zN,urn:IN,"urn:uuid":EN};Object.setPrototypeOf(xl,null);function Hm(e){return e&&(xl[e]||xl[e.toLowerCase()])||void 0}v$.exports={wsIsSecure:Km,SCHEMES:xl,isValidSchemeName:_N,getSchemeHandler:Hm}});var $$=A((X2,kl)=>{"use strict";var{normalizeIPv6:TN,removeDotSegments:ya,recomposeAuthority:ON,normalizeComponentEncoding:wl,isIPv4:PN,nonSimpleDomain:jN}=Bm(),{SCHEMES:NN,getSchemeHandler:y$}=_$();function RN(e,t){return typeof e=="string"?e=Bt(sr(e,t),t):typeof e=="object"&&(e=sr(Bt(e,t),t)),e}function AN(e,t,n){let o=n?Object.assign({scheme:"null"},n):{scheme:"null"},r=b$(sr(e,o),sr(t,o),o,!0);return o.skipEscape=!0,Bt(r,o)}function b$(e,t,n,o){let r={};return o||(e=sr(Bt(e,n),n),t=sr(Bt(t,n),n)),n=n||{},!n.tolerant&&t.scheme?(r.scheme=t.scheme,r.userinfo=t.userinfo,r.host=t.host,r.port=t.port,r.path=ya(t.path||""),r.query=t.query):(t.userinfo!==void 0||t.host!==void 0||t.port!==void 0?(r.userinfo=t.userinfo,r.host=t.host,r.port=t.port,r.path=ya(t.path||""),r.query=t.query):(t.path?(t.path[0]==="/"?r.path=ya(t.path):((e.userinfo!==void 0||e.host!==void 0||e.port!==void 0)&&!e.path?r.path="/"+t.path:e.path?r.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:r.path=t.path,r.path=ya(r.path)),r.query=t.query):(r.path=e.path,t.query!==void 0?r.query=t.query:r.query=e.query),r.userinfo=e.userinfo,r.host=e.host,r.port=e.port),r.scheme=e.scheme),r.fragment=t.fragment,r}function DN(e,t,n){return typeof e=="string"?(e=unescape(e),e=Bt(wl(sr(e,n),!0),{...n,skipEscape:!0})):typeof e=="object"&&(e=Bt(wl(e,!0),{...n,skipEscape:!0})),typeof t=="string"?(t=unescape(t),t=Bt(wl(sr(t,n),!0),{...n,skipEscape:!0})):typeof t=="object"&&(t=Bt(wl(t,!0),{...n,skipEscape:!0})),e.toLowerCase()===t.toLowerCase()}function Bt(e,t){let n={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:""},o=Object.assign({},t),r=[],i=y$(o.scheme||n.scheme);i&&i.serialize&&i.serialize(n,o),n.path!==void 0&&(o.skipEscape?n.path=unescape(n.path):(n.path=escape(n.path),n.scheme!==void 0&&(n.path=n.path.split("%3A").join(":")))),o.reference!=="suffix"&&n.scheme&&r.push(n.scheme,":");let a=ON(n);if(a!==void 0&&(o.reference!=="suffix"&&r.push("//"),r.push(a),n.path&&n.path[0]!=="/"&&r.push("/")),n.path!==void 0){let s=n.path;!o.absolutePath&&(!i||!i.absolutePath)&&(s=ya(s)),a===void 0&&s[0]==="/"&&s[1]==="/"&&(s="/%2F"+s.slice(2)),r.push(s)}return n.query!==void 0&&r.push("?",n.query),n.fragment!==void 0&&r.push("#",n.fragment),r.join("")}var CN=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function sr(e,t){let n=Object.assign({},t),o={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0},r=!1;n.reference==="suffix"&&(n.scheme?e=n.scheme+":"+e:e="//"+e);let i=e.match(CN);if(i){if(o.scheme=i[1],o.userinfo=i[3],o.host=i[4],o.port=parseInt(i[5],10),o.path=i[6]||"",o.query=i[7],o.fragment=i[8],isNaN(o.port)&&(o.port=i[5]),o.host)if(PN(o.host)===!1){let c=TN(o.host);o.host=c.host.toLowerCase(),r=c.isIPV6}else r=!0;o.scheme===void 0&&o.userinfo===void 0&&o.host===void 0&&o.port===void 0&&o.query===void 0&&!o.path?o.reference="same-document":o.scheme===void 0?o.reference="relative":o.fragment===void 0?o.reference="absolute":o.reference="uri",n.reference&&n.reference!=="suffix"&&n.reference!==o.reference&&(o.error=o.error||"URI is not a "+n.reference+" reference.");let a=y$(n.scheme||o.scheme);if(!n.unicodeSupport&&(!a||!a.unicodeSupport)&&o.host&&(n.domainHost||a&&a.domainHost)&&r===!1&&jN(o.host))try{o.host=URL.domainToASCII(o.host.toLowerCase())}catch(s){o.error=o.error||"Host's domain name can not be converted to ASCII: "+s}(!a||a&&!a.skipNormalize)&&(e.indexOf("%")!==-1&&(o.scheme!==void 0&&(o.scheme=unescape(o.scheme)),o.host!==void 0&&(o.host=unescape(o.host))),o.path&&(o.path=escape(unescape(o.path))),o.fragment&&(o.fragment=encodeURI(decodeURIComponent(o.fragment)))),a&&a.parse&&a.parse(o,n)}else o.error=o.error||"URI can not be parsed.";return o}var Jm={SCHEMES:NN,normalize:RN,resolve:AN,resolveComponent:b$,equal:DN,serialize:Bt,parse:sr};kl.exports=Jm;kl.exports.default=Jm;kl.exports.fastUri=Jm});var w$=A(Gm=>{"use strict";Object.defineProperty(Gm,"__esModule",{value:!0});var x$=$$();x$.code='require("ajv/dist/runtime/uri").default';Gm.default=x$});var P$=A(Ue=>{"use strict";Object.defineProperty(Ue,"__esModule",{value:!0});Ue.CodeGen=Ue.Name=Ue.nil=Ue.stringify=Ue.str=Ue._=Ue.KeywordCxt=void 0;var UN=va();Object.defineProperty(Ue,"KeywordCxt",{enumerable:!0,get:function(){return UN.KeywordCxt}});var So=re();Object.defineProperty(Ue,"_",{enumerable:!0,get:function(){return So._}});Object.defineProperty(Ue,"str",{enumerable:!0,get:function(){return So.str}});Object.defineProperty(Ue,"stringify",{enumerable:!0,get:function(){return So.stringify}});Object.defineProperty(Ue,"nil",{enumerable:!0,get:function(){return So.nil}});Object.defineProperty(Ue,"Name",{enumerable:!0,get:function(){return So.Name}});Object.defineProperty(Ue,"CodeGen",{enumerable:!0,get:function(){return So.CodeGen}});var ZN=_l(),E$=_a(),MN=km(),ba=bl(),LN=re(),$a=ma(),Sl=pa(),Xm=fe(),k$=u$(),qN=w$(),T$=(e,t)=>new RegExp(e,t);T$.code="new RegExp";var VN=["removeAdditional","useDefaults","coerceTypes"],FN=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),BN={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."},KN={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},S$=200;function HN(e){var t,n,o,r,i,a,s,c,l,d,f,_,v,g,b,x,I,R,O,M,V,Me,ct,Ao,ur;let Lr=e.strict,mn=(t=e.code)===null||t===void 0?void 0:t.optimize,Ua=mn===!0||mn===void 0?1:mn||0,Za=(o=(n=e.code)===null||n===void 0?void 0:n.regExp)!==null&&o!==void 0?o:T$,od=(r=e.uriResolver)!==null&&r!==void 0?r:qN.default;return{strictSchema:(a=(i=e.strictSchema)!==null&&i!==void 0?i:Lr)!==null&&a!==void 0?a:!0,strictNumbers:(c=(s=e.strictNumbers)!==null&&s!==void 0?s:Lr)!==null&&c!==void 0?c:!0,strictTypes:(d=(l=e.strictTypes)!==null&&l!==void 0?l:Lr)!==null&&d!==void 0?d:"log",strictTuples:(_=(f=e.strictTuples)!==null&&f!==void 0?f:Lr)!==null&&_!==void 0?_:"log",strictRequired:(g=(v=e.strictRequired)!==null&&v!==void 0?v:Lr)!==null&&g!==void 0?g:!1,code:e.code?{...e.code,optimize:Ua,regExp:Za}:{optimize:Ua,regExp:Za},loopRequired:(b=e.loopRequired)!==null&&b!==void 0?b:S$,loopEnum:(x=e.loopEnum)!==null&&x!==void 0?x:S$,meta:(I=e.meta)!==null&&I!==void 0?I:!0,messages:(R=e.messages)!==null&&R!==void 0?R:!0,inlineRefs:(O=e.inlineRefs)!==null&&O!==void 0?O:!0,schemaId:(M=e.schemaId)!==null&&M!==void 0?M:"$id",addUsedSchema:(V=e.addUsedSchema)!==null&&V!==void 0?V:!0,validateSchema:(Me=e.validateSchema)!==null&&Me!==void 0?Me:!0,validateFormats:(ct=e.validateFormats)!==null&&ct!==void 0?ct:!0,unicodeRegExp:(Ao=e.unicodeRegExp)!==null&&Ao!==void 0?Ao:!0,int32range:(ur=e.int32range)!==null&&ur!==void 0?ur:!0,uriResolver:od}}var xa=class{constructor(t={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,t=this.opts={...t,...HN(t)};let{es5:n,lines:o}=this.opts.code;this.scope=new LN.ValueScope({scope:{},prefixes:FN,es5:n,lines:o}),this.logger=QN(t.logger);let r=t.validateFormats;t.validateFormats=!1,this.RULES=(0,MN.getRules)(),z$.call(this,BN,t,"NOT SUPPORTED"),z$.call(this,KN,t,"DEPRECATED","warn"),this._metaOpts=XN.call(this),t.formats&&GN.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),t.keywords&&WN.call(this,t.keywords),typeof t.meta=="object"&&this.addMetaSchema(t.meta),JN.call(this),t.validateFormats=r}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){let{$data:t,meta:n,schemaId:o}=this.opts,r=k$;o==="id"&&(r={...k$},r.id=r.$id,delete r.$id),n&&t&&this.addMetaSchema(r,r[o],!1)}defaultMeta(){let{meta:t,schemaId:n}=this.opts;return this.opts.defaultMeta=typeof t=="object"?t[n]||t:void 0}validate(t,n){let o;if(typeof t=="string"){if(o=this.getSchema(t),!o)throw new Error(`no schema with key or ref "${t}"`)}else o=this.compile(t);let r=o(n);return"$async"in o||(this.errors=o.errors),r}compile(t,n){let o=this._addSchema(t,n);return o.validate||this._compileSchemaEnv(o)}compileAsync(t,n){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");let{loadSchema:o}=this.opts;return r.call(this,t,n);async function r(d,f){await i.call(this,d.$schema);let _=this._addSchema(d,f);return _.validate||a.call(this,_)}async function i(d){d&&!this.getSchema(d)&&await r.call(this,{$ref:d},!0)}async function a(d){try{return this._compileSchemaEnv(d)}catch(f){if(!(f instanceof E$.default))throw f;return s.call(this,f),await c.call(this,f.missingSchema),a.call(this,d)}}function s({missingSchema:d,missingRef:f}){if(this.refs[d])throw new Error(`AnySchema ${d} is loaded but ${f} cannot be resolved`)}async function c(d){let f=await l.call(this,d);this.refs[d]||await i.call(this,f.$schema),this.refs[d]||this.addSchema(f,d,n)}async function l(d){let f=this._loading[d];if(f)return f;try{return await(this._loading[d]=o(d))}finally{delete this._loading[d]}}}addSchema(t,n,o,r=this.opts.validateSchema){if(Array.isArray(t)){for(let a of t)this.addSchema(a,void 0,o,r);return this}let i;if(typeof t=="object"){let{schemaId:a}=this.opts;if(i=t[a],i!==void 0&&typeof i!="string")throw new Error(`schema ${a} must be string`)}return n=(0,$a.normalizeId)(n||i),this._checkUnique(n),this.schemas[n]=this._addSchema(t,o,n,r,!0),this}addMetaSchema(t,n,o=this.opts.validateSchema){return this.addSchema(t,n,!0,o),this}validateSchema(t,n){if(typeof t=="boolean")return!0;let o;if(o=t.$schema,o!==void 0&&typeof o!="string")throw new Error("$schema must be a string");if(o=o||this.opts.defaultMeta||this.defaultMeta(),!o)return this.logger.warn("meta-schema not available"),this.errors=null,!0;let r=this.validate(o,t);if(!r&&n){let i="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(i);else throw new Error(i)}return r}getSchema(t){let n;for(;typeof(n=I$.call(this,t))=="string";)t=n;if(n===void 0){let{schemaId:o}=this.opts,r=new ba.SchemaEnv({schema:{},schemaId:o});if(n=ba.resolveSchema.call(this,r,t),!n)return;this.refs[t]=n}return n.validate||this._compileSchemaEnv(n)}removeSchema(t){if(t instanceof RegExp)return this._removeAllSchemas(this.schemas,t),this._removeAllSchemas(this.refs,t),this;switch(typeof t){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{let n=I$.call(this,t);return typeof n=="object"&&this._cache.delete(n.schema),delete this.schemas[t],delete this.refs[t],this}case"object":{let n=t;this._cache.delete(n);let o=t[this.opts.schemaId];return o&&(o=(0,$a.normalizeId)(o),delete this.schemas[o],delete this.refs[o]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(t){for(let n of t)this.addKeyword(n);return this}addKeyword(t,n){let o;if(typeof t=="string")o=t,typeof n=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),n.keyword=o);else if(typeof t=="object"&&n===void 0){if(n=t,o=n.keyword,Array.isArray(o)&&!o.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if(tR.call(this,o,n),!n)return(0,Xm.eachItem)(o,i=>Wm.call(this,i)),this;nR.call(this,n);let r={...n,type:(0,Sl.getJSONTypes)(n.type),schemaType:(0,Sl.getJSONTypes)(n.schemaType)};return(0,Xm.eachItem)(o,r.type.length===0?i=>Wm.call(this,i,r):i=>r.type.forEach(a=>Wm.call(this,i,r,a))),this}getKeyword(t){let n=this.RULES.all[t];return typeof n=="object"?n.definition:!!n}removeKeyword(t){let{RULES:n}=this;delete n.keywords[t],delete n.all[t];for(let o of n.rules){let r=o.rules.findIndex(i=>i.keyword===t);r>=0&&o.rules.splice(r,1)}return this}addFormat(t,n){return typeof n=="string"&&(n=new RegExp(n)),this.formats[t]=n,this}errorsText(t=this.errors,{separator:n=", ",dataVar:o="data"}={}){return!t||t.length===0?"No errors":t.map(r=>`${o}${r.instancePath} ${r.message}`).reduce((r,i)=>r+n+i)}$dataMetaSchema(t,n){let o=this.RULES.all;t=JSON.parse(JSON.stringify(t));for(let r of n){let i=r.split("/").slice(1),a=t;for(let s of i)a=a[s];for(let s in o){let c=o[s];if(typeof c!="object")continue;let{$data:l}=c.definition,d=a[s];l&&d&&(a[s]=O$(d))}}return t}_removeAllSchemas(t,n){for(let o in t){let r=t[o];(!n||n.test(o))&&(typeof r=="string"?delete t[o]:r&&!r.meta&&(this._cache.delete(r.schema),delete t[o]))}}_addSchema(t,n,o,r=this.opts.validateSchema,i=this.opts.addUsedSchema){let a,{schemaId:s}=this.opts;if(typeof t=="object")a=t[s];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof t!="boolean")throw new Error("schema must be object or boolean")}let c=this._cache.get(t);if(c!==void 0)return c;o=(0,$a.normalizeId)(a||o);let l=$a.getSchemaRefs.call(this,t,o);return c=new ba.SchemaEnv({schema:t,schemaId:s,meta:n,baseId:o,localRefs:l}),this._cache.set(c.schema,c),i&&!o.startsWith("#")&&(o&&this._checkUnique(o),this.refs[o]=c),r&&this.validateSchema(t,!0),c}_checkUnique(t){if(this.schemas[t]||this.refs[t])throw new Error(`schema with key or id "${t}" already exists`)}_compileSchemaEnv(t){if(t.meta?this._compileMetaSchema(t):ba.compileSchema.call(this,t),!t.validate)throw new Error("ajv implementation error");return t.validate}_compileMetaSchema(t){let n=this.opts;this.opts=this._metaOpts;try{ba.compileSchema.call(this,t)}finally{this.opts=n}}};xa.ValidationError=ZN.default;xa.MissingRefError=E$.default;Ue.default=xa;function z$(e,t,n,o="error"){for(let r in e){let i=r;i in t&&this.logger[o](`${n}: option ${r}. ${e[i]}`)}}function I$(e){return e=(0,$a.normalizeId)(e),this.schemas[e]||this.refs[e]}function JN(){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 GN(){for(let e in this.opts.formats){let t=this.opts.formats[e];t&&this.addFormat(e,t)}}function WN(e){if(Array.isArray(e)){this.addVocabulary(e);return}this.logger.warn("keywords option as map is deprecated, pass array");for(let t in e){let n=e[t];n.keyword||(n.keyword=t),this.addKeyword(n)}}function XN(){let e={...this.opts};for(let t of VN)delete e[t];return e}var YN={log(){},warn(){},error(){}};function QN(e){if(e===!1)return YN;if(e===void 0)return console;if(e.log&&e.warn&&e.error)return e;throw new Error("logger must implement log, warn and error methods")}var eR=/^[a-z_$][a-z0-9_$:-]*$/i;function tR(e,t){let{RULES:n}=this;if((0,Xm.eachItem)(e,o=>{if(n.keywords[o])throw new Error(`Keyword ${o} is already defined`);if(!eR.test(o))throw new Error(`Keyword ${o} has invalid name`)}),!!t&&t.$data&&!("code"in t||"validate"in t))throw new Error('$data keyword must have "code" or "validate" function')}function Wm(e,t,n){var o;let r=t?.post;if(n&&r)throw new Error('keyword with "post" flag cannot have "type"');let{RULES:i}=this,a=r?i.post:i.rules.find(({type:c})=>c===n);if(a||(a={type:n,rules:[]},i.rules.push(a)),i.keywords[e]=!0,!t)return;let s={keyword:e,definition:{...t,type:(0,Sl.getJSONTypes)(t.type),schemaType:(0,Sl.getJSONTypes)(t.schemaType)}};t.before?rR.call(this,a,s,t.before):a.rules.push(s),i.all[e]=s,(o=t.implements)===null||o===void 0||o.forEach(c=>this.addKeyword(c))}function rR(e,t,n){let o=e.rules.findIndex(r=>r.keyword===n);o>=0?e.rules.splice(o,0,t):(e.rules.push(t),this.logger.warn(`rule ${n} is not defined`))}function nR(e){let{metaSchema:t}=e;t!==void 0&&(e.$data&&this.opts.$data&&(t=O$(t)),e.validateSchema=this.compile(t,!0))}var oR={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function O$(e){return{anyOf:[e,oR]}}});var j$=A(Ym=>{"use strict";Object.defineProperty(Ym,"__esModule",{value:!0});var iR={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};Ym.default=iR});var D$=A(ln=>{"use strict";Object.defineProperty(ln,"__esModule",{value:!0});ln.callRef=ln.getValidate=void 0;var aR=_a(),N$=$t(),st=re(),zo=ir(),R$=bl(),zl=fe(),sR={keyword:"$ref",schemaType:"string",code(e){let{gen:t,schema:n,it:o}=e,{baseId:r,schemaEnv:i,validateName:a,opts:s,self:c}=o,{root:l}=i;if((n==="#"||n==="#/")&&r===l.baseId)return f();let d=R$.resolveRef.call(c,l,r,n);if(d===void 0)throw new aR.default(o.opts.uriResolver,r,n);if(d instanceof R$.SchemaEnv)return _(d);return v(d);function f(){if(i===l)return Il(e,a,i,i.$async);let g=t.scopeValue("root",{ref:l});return Il(e,(0,st._)`${g}.validate`,l,l.$async)}function _(g){let b=A$(e,g);Il(e,b,g,g.$async)}function v(g){let b=t.scopeValue("schema",s.code.source===!0?{ref:g,code:(0,st.stringify)(g)}:{ref:g}),x=t.name("valid"),I=e.subschema({schema:g,dataTypes:[],schemaPath:st.nil,topSchemaRef:b,errSchemaPath:n},x);e.mergeEvaluated(I),e.ok(x)}}};function A$(e,t){let{gen:n}=e;return t.validate?n.scopeValue("validate",{ref:t.validate}):(0,st._)`${n.scopeValue("wrapper",{ref:t})}.validate`}ln.getValidate=A$;function Il(e,t,n,o){let{gen:r,it:i}=e,{allErrors:a,schemaEnv:s,opts:c}=i,l=c.passContext?zo.default.this:st.nil;o?d():f();function d(){if(!s.$async)throw new Error("async schema referenced by sync schema");let g=r.let("valid");r.try(()=>{r.code((0,st._)`await ${(0,N$.callValidateCode)(e,t,l)}`),v(t),a||r.assign(g,!0)},b=>{r.if((0,st._)`!(${b} instanceof ${i.ValidationError})`,()=>r.throw(b)),_(b),a||r.assign(g,!1)}),e.ok(g)}function f(){e.result((0,N$.callValidateCode)(e,t,l),()=>v(t),()=>_(t))}function _(g){let b=(0,st._)`${g}.errors`;r.assign(zo.default.vErrors,(0,st._)`${zo.default.vErrors} === null ? ${b} : ${zo.default.vErrors}.concat(${b})`),r.assign(zo.default.errors,(0,st._)`${zo.default.vErrors}.length`)}function v(g){var b;if(!i.opts.unevaluated)return;let x=(b=n?.validate)===null||b===void 0?void 0:b.evaluated;if(i.props!==!0)if(x&&!x.dynamicProps)x.props!==void 0&&(i.props=zl.mergeEvaluated.props(r,x.props,i.props));else{let I=r.var("props",(0,st._)`${g}.evaluated.props`);i.props=zl.mergeEvaluated.props(r,I,i.props,st.Name)}if(i.items!==!0)if(x&&!x.dynamicItems)x.items!==void 0&&(i.items=zl.mergeEvaluated.items(r,x.items,i.items));else{let I=r.var("items",(0,st._)`${g}.evaluated.items`);i.items=zl.mergeEvaluated.items(r,I,i.items,st.Name)}}}ln.callRef=Il;ln.default=sR});var C$=A(Qm=>{"use strict";Object.defineProperty(Qm,"__esModule",{value:!0});var cR=j$(),uR=D$(),lR=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",cR.default,uR.default];Qm.default=lR});var U$=A(eh=>{"use strict";Object.defineProperty(eh,"__esModule",{value:!0});var El=re(),Cr=El.operators,Tl={maximum:{okStr:"<=",ok:Cr.LTE,fail:Cr.GT},minimum:{okStr:">=",ok:Cr.GTE,fail:Cr.LT},exclusiveMaximum:{okStr:"<",ok:Cr.LT,fail:Cr.GTE},exclusiveMinimum:{okStr:">",ok:Cr.GT,fail:Cr.LTE}},dR={message:({keyword:e,schemaCode:t})=>(0,El.str)`must be ${Tl[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>(0,El._)`{comparison: ${Tl[e].okStr}, limit: ${t}}`},fR={keyword:Object.keys(Tl),type:"number",schemaType:"number",$data:!0,error:dR,code(e){let{keyword:t,data:n,schemaCode:o}=e;e.fail$data((0,El._)`${n} ${Tl[t].fail} ${o} || isNaN(${n})`)}};eh.default=fR});var Z$=A(th=>{"use strict";Object.defineProperty(th,"__esModule",{value:!0});var wa=re(),pR={message:({schemaCode:e})=>(0,wa.str)`must be multiple of ${e}`,params:({schemaCode:e})=>(0,wa._)`{multipleOf: ${e}}`},mR={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:pR,code(e){let{gen:t,data:n,schemaCode:o,it:r}=e,i=r.opts.multipleOfPrecision,a=t.let("res"),s=i?(0,wa._)`Math.abs(Math.round(${a}) - ${a}) > 1e-${i}`:(0,wa._)`${a} !== parseInt(${a})`;e.fail$data((0,wa._)`(${o} === 0 || (${a} = ${n}/${o}, ${s}))`)}};th.default=mR});var L$=A(rh=>{"use strict";Object.defineProperty(rh,"__esModule",{value:!0});function M$(e){let t=e.length,n=0,o=0,r;for(;o<t;)n++,r=e.charCodeAt(o++),r>=55296&&r<=56319&&o<t&&(r=e.charCodeAt(o),(r&64512)===56320&&o++);return n}rh.default=M$;M$.code='require("ajv/dist/runtime/ucs2length").default'});var q$=A(nh=>{"use strict";Object.defineProperty(nh,"__esModule",{value:!0});var dn=re(),hR=fe(),gR=L$(),vR={message({keyword:e,schemaCode:t}){let n=e==="maxLength"?"more":"fewer";return(0,dn.str)`must NOT have ${n} than ${t} characters`},params:({schemaCode:e})=>(0,dn._)`{limit: ${e}}`},_R={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:vR,code(e){let{keyword:t,data:n,schemaCode:o,it:r}=e,i=t==="maxLength"?dn.operators.GT:dn.operators.LT,a=r.opts.unicode===!1?(0,dn._)`${n}.length`:(0,dn._)`${(0,hR.useFunc)(e.gen,gR.default)}(${n})`;e.fail$data((0,dn._)`${a} ${i} ${o}`)}};nh.default=_R});var V$=A(oh=>{"use strict";Object.defineProperty(oh,"__esModule",{value:!0});var yR=$t(),bR=fe(),Io=re(),$R={message:({schemaCode:e})=>(0,Io.str)`must match pattern "${e}"`,params:({schemaCode:e})=>(0,Io._)`{pattern: ${e}}`},xR={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:$R,code(e){let{gen:t,data:n,$data:o,schema:r,schemaCode:i,it:a}=e,s=a.opts.unicodeRegExp?"u":"";if(o){let{regExp:c}=a.opts.code,l=c.code==="new RegExp"?(0,Io._)`new RegExp`:(0,bR.useFunc)(t,c),d=t.let("valid");t.try(()=>t.assign(d,(0,Io._)`${l}(${i}, ${s}).test(${n})`),()=>t.assign(d,!1)),e.fail$data((0,Io._)`!${d}`)}else{let c=(0,yR.usePattern)(e,r);e.fail$data((0,Io._)`!${c}.test(${n})`)}}};oh.default=xR});var F$=A(ih=>{"use strict";Object.defineProperty(ih,"__esModule",{value:!0});var ka=re(),wR={message({keyword:e,schemaCode:t}){let n=e==="maxProperties"?"more":"fewer";return(0,ka.str)`must NOT have ${n} than ${t} properties`},params:({schemaCode:e})=>(0,ka._)`{limit: ${e}}`},kR={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:wR,code(e){let{keyword:t,data:n,schemaCode:o}=e,r=t==="maxProperties"?ka.operators.GT:ka.operators.LT;e.fail$data((0,ka._)`Object.keys(${n}).length ${r} ${o}`)}};ih.default=kR});var B$=A(ah=>{"use strict";Object.defineProperty(ah,"__esModule",{value:!0});var Sa=$t(),za=re(),SR=fe(),zR={message:({params:{missingProperty:e}})=>(0,za.str)`must have required property '${e}'`,params:({params:{missingProperty:e}})=>(0,za._)`{missingProperty: ${e}}`},IR={keyword:"required",type:"object",schemaType:"array",$data:!0,error:zR,code(e){let{gen:t,schema:n,schemaCode:o,data:r,$data:i,it:a}=e,{opts:s}=a;if(!i&&n.length===0)return;let c=n.length>=s.loopRequired;if(a.allErrors?l():d(),s.strictRequired){let v=e.parentSchema.properties,{definedProperties:g}=e.it;for(let b of n)if(v?.[b]===void 0&&!g.has(b)){let x=a.schemaEnv.baseId+a.errSchemaPath,I=`required property "${b}" is not defined at "${x}" (strictRequired)`;(0,SR.checkStrictMode)(a,I,a.opts.strictRequired)}}function l(){if(c||i)e.block$data(za.nil,f);else for(let v of n)(0,Sa.checkReportMissingProp)(e,v)}function d(){let v=t.let("missing");if(c||i){let g=t.let("valid",!0);e.block$data(g,()=>_(v,g)),e.ok(g)}else t.if((0,Sa.checkMissingProp)(e,n,v)),(0,Sa.reportMissingProp)(e,v),t.else()}function f(){t.forOf("prop",o,v=>{e.setParams({missingProperty:v}),t.if((0,Sa.noPropertyInData)(t,r,v,s.ownProperties),()=>e.error())})}function _(v,g){e.setParams({missingProperty:v}),t.forOf(v,o,()=>{t.assign(g,(0,Sa.propertyInData)(t,r,v,s.ownProperties)),t.if((0,za.not)(g),()=>{e.error(),t.break()})},za.nil)}}};ah.default=IR});var K$=A(sh=>{"use strict";Object.defineProperty(sh,"__esModule",{value:!0});var Ia=re(),ER={message({keyword:e,schemaCode:t}){let n=e==="maxItems"?"more":"fewer";return(0,Ia.str)`must NOT have ${n} than ${t} items`},params:({schemaCode:e})=>(0,Ia._)`{limit: ${e}}`},TR={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:ER,code(e){let{keyword:t,data:n,schemaCode:o}=e,r=t==="maxItems"?Ia.operators.GT:Ia.operators.LT;e.fail$data((0,Ia._)`${n}.length ${r} ${o}`)}};sh.default=TR});var Ol=A(ch=>{"use strict";Object.defineProperty(ch,"__esModule",{value:!0});var H$=jm();H$.code='require("ajv/dist/runtime/equal").default';ch.default=H$});var J$=A(lh=>{"use strict";Object.defineProperty(lh,"__esModule",{value:!0});var uh=pa(),Ze=re(),OR=fe(),PR=Ol(),jR={message:({params:{i:e,j:t}})=>(0,Ze.str)`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>(0,Ze._)`{i: ${e}, j: ${t}}`},NR={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:jR,code(e){let{gen:t,data:n,$data:o,schema:r,parentSchema:i,schemaCode:a,it:s}=e;if(!o&&!r)return;let c=t.let("valid"),l=i.items?(0,uh.getSchemaTypes)(i.items):[];e.block$data(c,d,(0,Ze._)`${a} === false`),e.ok(c);function d(){let g=t.let("i",(0,Ze._)`${n}.length`),b=t.let("j");e.setParams({i:g,j:b}),t.assign(c,!0),t.if((0,Ze._)`${g} > 1`,()=>(f()?_:v)(g,b))}function f(){return l.length>0&&!l.some(g=>g==="object"||g==="array")}function _(g,b){let x=t.name("item"),I=(0,uh.checkDataTypes)(l,x,s.opts.strictNumbers,uh.DataType.Wrong),R=t.const("indices",(0,Ze._)`{}`);t.for((0,Ze._)`;${g}--;`,()=>{t.let(x,(0,Ze._)`${n}[${g}]`),t.if(I,(0,Ze._)`continue`),l.length>1&&t.if((0,Ze._)`typeof ${x} == "string"`,(0,Ze._)`${x} += "_"`),t.if((0,Ze._)`typeof ${R}[${x}] == "number"`,()=>{t.assign(b,(0,Ze._)`${R}[${x}]`),e.error(),t.assign(c,!1).break()}).code((0,Ze._)`${R}[${x}] = ${g}`)})}function v(g,b){let x=(0,OR.useFunc)(t,PR.default),I=t.name("outer");t.label(I).for((0,Ze._)`;${g}--;`,()=>t.for((0,Ze._)`${b} = ${g}; ${b}--;`,()=>t.if((0,Ze._)`${x}(${n}[${g}], ${n}[${b}])`,()=>{e.error(),t.assign(c,!1).break(I)})))}}};lh.default=NR});var G$=A(fh=>{"use strict";Object.defineProperty(fh,"__esModule",{value:!0});var dh=re(),RR=fe(),AR=Ol(),DR={message:"must be equal to constant",params:({schemaCode:e})=>(0,dh._)`{allowedValue: ${e}}`},CR={keyword:"const",$data:!0,error:DR,code(e){let{gen:t,data:n,$data:o,schemaCode:r,schema:i}=e;o||i&&typeof i=="object"?e.fail$data((0,dh._)`!${(0,RR.useFunc)(t,AR.default)}(${n}, ${r})`):e.fail((0,dh._)`${i} !== ${n}`)}};fh.default=CR});var W$=A(ph=>{"use strict";Object.defineProperty(ph,"__esModule",{value:!0});var Ea=re(),UR=fe(),ZR=Ol(),MR={message:"must be equal to one of the allowed values",params:({schemaCode:e})=>(0,Ea._)`{allowedValues: ${e}}`},LR={keyword:"enum",schemaType:"array",$data:!0,error:MR,code(e){let{gen:t,data:n,$data:o,schema:r,schemaCode:i,it:a}=e;if(!o&&r.length===0)throw new Error("enum must have non-empty array");let s=r.length>=a.opts.loopEnum,c,l=()=>c??(c=(0,UR.useFunc)(t,ZR.default)),d;if(s||o)d=t.let("valid"),e.block$data(d,f);else{if(!Array.isArray(r))throw new Error("ajv implementation error");let v=t.const("vSchema",i);d=(0,Ea.or)(...r.map((g,b)=>_(v,b)))}e.pass(d);function f(){t.assign(d,!1),t.forOf("v",i,v=>t.if((0,Ea._)`${l()}(${n}, ${v})`,()=>t.assign(d,!0).break()))}function _(v,g){let b=r[g];return typeof b=="object"&&b!==null?(0,Ea._)`${l()}(${n}, ${v}[${g}])`:(0,Ea._)`${n} === ${b}`}}};ph.default=LR});var X$=A(mh=>{"use strict";Object.defineProperty(mh,"__esModule",{value:!0});var qR=U$(),VR=Z$(),FR=q$(),BR=V$(),KR=F$(),HR=B$(),JR=K$(),GR=J$(),WR=G$(),XR=W$(),YR=[qR.default,VR.default,FR.default,BR.default,KR.default,HR.default,JR.default,GR.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},WR.default,XR.default];mh.default=YR});var gh=A(Ta=>{"use strict";Object.defineProperty(Ta,"__esModule",{value:!0});Ta.validateAdditionalItems=void 0;var fn=re(),hh=fe(),QR={message:({params:{len:e}})=>(0,fn.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,fn._)`{limit: ${e}}`},e1={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:QR,code(e){let{parentSchema:t,it:n}=e,{items:o}=t;if(!Array.isArray(o)){(0,hh.checkStrictMode)(n,'"additionalItems" is ignored when "items" is not an array of schemas');return}Y$(e,o)}};function Y$(e,t){let{gen:n,schema:o,data:r,keyword:i,it:a}=e;a.items=!0;let s=n.const("len",(0,fn._)`${r}.length`);if(o===!1)e.setParams({len:t.length}),e.pass((0,fn._)`${s} <= ${t.length}`);else if(typeof o=="object"&&!(0,hh.alwaysValidSchema)(a,o)){let l=n.var("valid",(0,fn._)`${s} <= ${t.length}`);n.if((0,fn.not)(l),()=>c(l)),e.ok(l)}function c(l){n.forRange("i",t.length,s,d=>{e.subschema({keyword:i,dataProp:d,dataPropType:hh.Type.Num},l),a.allErrors||n.if((0,fn.not)(l),()=>n.break())})}}Ta.validateAdditionalItems=Y$;Ta.default=e1});var vh=A(Oa=>{"use strict";Object.defineProperty(Oa,"__esModule",{value:!0});Oa.validateTuple=void 0;var Q$=re(),Pl=fe(),t1=$t(),r1={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){let{schema:t,it:n}=e;if(Array.isArray(t))return ex(e,"additionalItems",t);n.items=!0,!(0,Pl.alwaysValidSchema)(n,t)&&e.ok((0,t1.validateArray)(e))}};function ex(e,t,n=e.schema){let{gen:o,parentSchema:r,data:i,keyword:a,it:s}=e;d(r),s.opts.unevaluated&&n.length&&s.items!==!0&&(s.items=Pl.mergeEvaluated.items(o,n.length,s.items));let c=o.name("valid"),l=o.const("len",(0,Q$._)`${i}.length`);n.forEach((f,_)=>{(0,Pl.alwaysValidSchema)(s,f)||(o.if((0,Q$._)`${l} > ${_}`,()=>e.subschema({keyword:a,schemaProp:_,dataProp:_},c)),e.ok(c))});function d(f){let{opts:_,errSchemaPath:v}=s,g=n.length,b=g===f.minItems&&(g===f.maxItems||f[t]===!1);if(_.strictTuples&&!b){let x=`"${a}" is ${g}-tuple, but minItems or maxItems/${t} are not specified or different at path "${v}"`;(0,Pl.checkStrictMode)(s,x,_.strictTuples)}}}Oa.validateTuple=ex;Oa.default=r1});var tx=A(_h=>{"use strict";Object.defineProperty(_h,"__esModule",{value:!0});var n1=vh(),o1={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:e=>(0,n1.validateTuple)(e,"items")};_h.default=o1});var nx=A(yh=>{"use strict";Object.defineProperty(yh,"__esModule",{value:!0});var rx=re(),i1=fe(),a1=$t(),s1=gh(),c1={message:({params:{len:e}})=>(0,rx.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,rx._)`{limit: ${e}}`},u1={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:c1,code(e){let{schema:t,parentSchema:n,it:o}=e,{prefixItems:r}=n;o.items=!0,!(0,i1.alwaysValidSchema)(o,t)&&(r?(0,s1.validateAdditionalItems)(e,r):e.ok((0,a1.validateArray)(e)))}};yh.default=u1});var ox=A(bh=>{"use strict";Object.defineProperty(bh,"__esModule",{value:!0});var wt=re(),jl=fe(),l1={message:({params:{min:e,max:t}})=>t===void 0?(0,wt.str)`must contain at least ${e} valid item(s)`:(0,wt.str)`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>t===void 0?(0,wt._)`{minContains: ${e}}`:(0,wt._)`{minContains: ${e}, maxContains: ${t}}`},d1={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:l1,code(e){let{gen:t,schema:n,parentSchema:o,data:r,it:i}=e,a,s,{minContains:c,maxContains:l}=o;i.opts.next?(a=c===void 0?1:c,s=l):a=1;let d=t.const("len",(0,wt._)`${r}.length`);if(e.setParams({min:a,max:s}),s===void 0&&a===0){(0,jl.checkStrictMode)(i,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(s!==void 0&&a>s){(0,jl.checkStrictMode)(i,'"minContains" > "maxContains" is always invalid'),e.fail();return}if((0,jl.alwaysValidSchema)(i,n)){let b=(0,wt._)`${d} >= ${a}`;s!==void 0&&(b=(0,wt._)`${b} && ${d} <= ${s}`),e.pass(b);return}i.items=!0;let f=t.name("valid");s===void 0&&a===1?v(f,()=>t.if(f,()=>t.break())):a===0?(t.let(f,!0),s!==void 0&&t.if((0,wt._)`${r}.length > 0`,_)):(t.let(f,!1),_()),e.result(f,()=>e.reset());function _(){let b=t.name("_valid"),x=t.let("count",0);v(b,()=>t.if(b,()=>g(x)))}function v(b,x){t.forRange("i",0,d,I=>{e.subschema({keyword:"contains",dataProp:I,dataPropType:jl.Type.Num,compositeRule:!0},b),x()})}function g(b){t.code((0,wt._)`${b}++`),s===void 0?t.if((0,wt._)`${b} >= ${a}`,()=>t.assign(f,!0).break()):(t.if((0,wt._)`${b} > ${s}`,()=>t.assign(f,!1).break()),a===1?t.assign(f,!0):t.if((0,wt._)`${b} >= ${a}`,()=>t.assign(f,!0)))}}};bh.default=d1});var sx=A(Kt=>{"use strict";Object.defineProperty(Kt,"__esModule",{value:!0});Kt.validateSchemaDeps=Kt.validatePropertyDeps=Kt.error=void 0;var $h=re(),f1=fe(),Pa=$t();Kt.error={message:({params:{property:e,depsCount:t,deps:n}})=>{let o=t===1?"property":"properties";return(0,$h.str)`must have ${o} ${n} when property ${e} is present`},params:({params:{property:e,depsCount:t,deps:n,missingProperty:o}})=>(0,$h._)`{property: ${e},
|
|
9
9
|
missingProperty: ${o},
|
|
10
10
|
depsCount: ${t},
|
|
11
|
-
deps: ${n}}`};var i1={keyword:"dependencies",type:"object",schemaType:"object",error:Kt.error,code(e){let[t,n]=a1(e);rx(e,t),nx(e,n)}};function a1({schema:e}){let t={},n={};for(let o in e){if(o==="__proto__")continue;let r=Array.isArray(e[o])?t:n;r[o]=e[o]}return[t,n]}function rx(e,t=e.schema){let{gen:n,data:o,it:r}=e;if(Object.keys(t).length===0)return;let i=n.let("missing");for(let a in t){let s=t[a];if(s.length===0)continue;let c=(0,Oa.propertyInData)(n,o,a,r.opts.ownProperties);e.setParams({property:a,depsCount:s.length,deps:s.join(", ")}),r.allErrors?n.if(c,()=>{for(let l of s)(0,Oa.checkReportMissingProp)(e,l)}):(n.if((0,yh._)`${c} && (${(0,Oa.checkMissingProp)(e,s,i)})`),(0,Oa.reportMissingProp)(e,i),n.else())}}Kt.validatePropertyDeps=rx;function nx(e,t=e.schema){let{gen:n,data:o,keyword:r,it:i}=e,a=n.name("valid");for(let s in t)(0,o1.alwaysValidSchema)(i,t[s])||(n.if((0,Oa.propertyInData)(n,o,s,i.opts.ownProperties),()=>{let c=e.subschema({keyword:r,schemaProp:s},a);e.mergeValidEvaluated(c,a)},()=>n.var(a,!0)),e.ok(a))}Kt.validateSchemaDeps=nx;Kt.default=i1});var ax=A(bh=>{"use strict";Object.defineProperty(bh,"__esModule",{value:!0});var ix=re(),s1=fe(),c1={message:"property name must be valid",params:({params:e})=>(0,ix._)`{propertyName: ${e.propertyName}}`},u1={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:c1,code(e){let{gen:t,schema:n,data:o,it:r}=e;if((0,s1.alwaysValidSchema)(r,n))return;let i=t.name("valid");t.forIn("key",o,a=>{e.setParams({propertyName:a}),e.subschema({keyword:"propertyNames",data:a,dataTypes:["string"],propertyName:a,compositeRule:!0},i),t.if((0,ix.not)(i),()=>{e.error(!0),r.allErrors||t.break()})}),e.ok(i)}};bh.default=u1});var xh=A($h=>{"use strict";Object.defineProperty($h,"__esModule",{value:!0});var jl=$t(),At=re(),l1=ir(),Nl=fe(),d1={message:"must NOT have additional properties",params:({params:e})=>(0,At._)`{additionalProperty: ${e.additionalProperty}}`},f1={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:d1,code(e){let{gen:t,schema:n,parentSchema:o,data:r,errsCount:i,it:a}=e;if(!i)throw new Error("ajv implementation error");let{allErrors:s,opts:c}=a;if(a.props=!0,c.removeAdditional!=="all"&&(0,Nl.alwaysValidSchema)(a,n))return;let l=(0,jl.allSchemaProperties)(o.properties),d=(0,jl.allSchemaProperties)(o.patternProperties);f(),e.ok((0,At._)`${i} === ${l1.default.errors}`);function f(){t.forIn("key",r,x=>{!l.length&&!d.length?g(x):t.if(_(x),()=>g(x))})}function _(x){let I;if(l.length>8){let R=(0,Nl.schemaRefOrVal)(a,o.properties,"properties");I=(0,jl.isOwnProperty)(t,R,x)}else l.length?I=(0,At.or)(...l.map(R=>(0,At._)`${x} === ${R}`)):I=At.nil;return d.length&&(I=(0,At.or)(I,...d.map(R=>(0,At._)`${(0,jl.usePattern)(e,R)}.test(${x})`))),(0,At.not)(I)}function v(x){t.code((0,At._)`delete ${r}[${x}]`)}function g(x){if(c.removeAdditional==="all"||c.removeAdditional&&n===!1){v(x);return}if(n===!1){e.setParams({additionalProperty:x}),e.error(),s||t.break();return}if(typeof n=="object"&&!(0,Nl.alwaysValidSchema)(a,n)){let I=t.name("valid");c.removeAdditional==="failing"?(b(x,I,!1),t.if((0,At.not)(I),()=>{e.reset(),v(x)})):(b(x,I),s||t.if((0,At.not)(I),()=>t.break()))}}function b(x,I,R){let P={keyword:"additionalProperties",dataProp:x,dataPropType:Nl.Type.Str};R===!1&&Object.assign(P,{compositeRule:!0,createErrors:!1,allErrors:!1}),e.subschema(P,I)}}};$h.default=f1});var ux=A(kh=>{"use strict";Object.defineProperty(kh,"__esModule",{value:!0});var p1=va(),sx=$t(),wh=fe(),cx=xh(),m1={keyword:"properties",type:"object",schemaType:"object",code(e){let{gen:t,schema:n,parentSchema:o,data:r,it:i}=e;i.opts.removeAdditional==="all"&&o.additionalProperties===void 0&&cx.default.code(new p1.KeywordCxt(i,cx.default,"additionalProperties"));let a=(0,sx.allSchemaProperties)(n);for(let f of a)i.definedProperties.add(f);i.opts.unevaluated&&a.length&&i.props!==!0&&(i.props=wh.mergeEvaluated.props(t,(0,wh.toHash)(a),i.props));let s=a.filter(f=>!(0,wh.alwaysValidSchema)(i,n[f]));if(s.length===0)return;let c=t.name("valid");for(let f of s)l(f)?d(f):(t.if((0,sx.propertyInData)(t,r,f,i.opts.ownProperties)),d(f),i.allErrors||t.else().var(c,!0),t.endIf()),e.it.definedProperties.add(f),e.ok(c);function l(f){return i.opts.useDefaults&&!i.compositeRule&&n[f].default!==void 0}function d(f){e.subschema({keyword:"properties",schemaProp:f,dataProp:f},c)}}};kh.default=m1});var px=A(Sh=>{"use strict";Object.defineProperty(Sh,"__esModule",{value:!0});var lx=$t(),Rl=re(),dx=fe(),fx=fe(),h1={keyword:"patternProperties",type:"object",schemaType:"object",code(e){let{gen:t,schema:n,data:o,parentSchema:r,it:i}=e,{opts:a}=i,s=(0,lx.allSchemaProperties)(n),c=s.filter(b=>(0,dx.alwaysValidSchema)(i,n[b]));if(s.length===0||c.length===s.length&&(!i.opts.unevaluated||i.props===!0))return;let l=a.strictSchema&&!a.allowMatchingProperties&&r.properties,d=t.name("valid");i.props!==!0&&!(i.props instanceof Rl.Name)&&(i.props=(0,fx.evaluatedPropsToName)(t,i.props));let{props:f}=i;_();function _(){for(let b of s)l&&v(b),i.allErrors?g(b):(t.var(d,!0),g(b),t.if(d))}function v(b){for(let x in l)new RegExp(b).test(x)&&(0,dx.checkStrictMode)(i,`property ${x} matches pattern ${b} (use allowMatchingProperties)`)}function g(b){t.forIn("key",o,x=>{t.if((0,Rl._)`${(0,lx.usePattern)(e,b)}.test(${x})`,()=>{let I=c.includes(b);I||e.subschema({keyword:"patternProperties",schemaProp:b,dataProp:x,dataPropType:fx.Type.Str},d),i.opts.unevaluated&&f!==!0?t.assign((0,Rl._)`${f}[${x}]`,!0):!I&&!i.allErrors&&t.if((0,Rl.not)(d),()=>t.break())})})}}};Sh.default=h1});var mx=A(zh=>{"use strict";Object.defineProperty(zh,"__esModule",{value:!0});var g1=fe(),v1={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){let{gen:t,schema:n,it:o}=e;if((0,g1.alwaysValidSchema)(o,n)){e.fail();return}let r=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},r),e.failResult(r,()=>e.reset(),()=>e.error())},error:{message:"must NOT be valid"}};zh.default=v1});var hx=A(Ih=>{"use strict";Object.defineProperty(Ih,"__esModule",{value:!0});var _1=$t(),y1={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:_1.validateUnion,error:{message:"must match a schema in anyOf"}};Ih.default=y1});var gx=A(Eh=>{"use strict";Object.defineProperty(Eh,"__esModule",{value:!0});var Al=re(),b1=fe(),$1={message:"must match exactly one schema in oneOf",params:({params:e})=>(0,Al._)`{passingSchemas: ${e.passing}}`},x1={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:$1,code(e){let{gen:t,schema:n,parentSchema:o,it:r}=e;if(!Array.isArray(n))throw new Error("ajv implementation error");if(r.opts.discriminator&&o.discriminator)return;let i=n,a=t.let("valid",!1),s=t.let("passing",null),c=t.name("_valid");e.setParams({passing:s}),t.block(l),e.result(a,()=>e.reset(),()=>e.error(!0));function l(){i.forEach((d,f)=>{let _;(0,b1.alwaysValidSchema)(r,d)?t.var(c,!0):_=e.subschema({keyword:"oneOf",schemaProp:f,compositeRule:!0},c),f>0&&t.if((0,Al._)`${c} && ${a}`).assign(a,!1).assign(s,(0,Al._)`[${s}, ${f}]`).else(),t.if(c,()=>{t.assign(a,!0),t.assign(s,f),_&&e.mergeEvaluated(_,Al.Name)})})}}};Eh.default=x1});var vx=A(Th=>{"use strict";Object.defineProperty(Th,"__esModule",{value:!0});var w1=fe(),k1={keyword:"allOf",schemaType:"array",code(e){let{gen:t,schema:n,it:o}=e;if(!Array.isArray(n))throw new Error("ajv implementation error");let r=t.name("valid");n.forEach((i,a)=>{if((0,w1.alwaysValidSchema)(o,i))return;let s=e.subschema({keyword:"allOf",schemaProp:a},r);e.ok(r),e.mergeEvaluated(s)})}};Th.default=k1});var bx=A(Ph=>{"use strict";Object.defineProperty(Ph,"__esModule",{value:!0});var Dl=re(),yx=fe(),S1={message:({params:e})=>(0,Dl.str)`must match "${e.ifClause}" schema`,params:({params:e})=>(0,Dl._)`{failingKeyword: ${e.ifClause}}`},z1={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:S1,code(e){let{gen:t,parentSchema:n,it:o}=e;n.then===void 0&&n.else===void 0&&(0,yx.checkStrictMode)(o,'"if" without "then" and "else" is ignored');let r=_x(o,"then"),i=_x(o,"else");if(!r&&!i)return;let a=t.let("valid",!0),s=t.name("_valid");if(c(),e.reset(),r&&i){let d=t.let("ifClause");e.setParams({ifClause:d}),t.if(s,l("then",d),l("else",d))}else r?t.if(s,l("then")):t.if((0,Dl.not)(s),l("else"));e.pass(a,()=>e.error(!0));function c(){let d=e.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},s);e.mergeEvaluated(d)}function l(d,f){return()=>{let _=e.subschema({keyword:d},s);t.assign(a,s),e.mergeValidEvaluated(_,a),f?t.assign(f,(0,Dl._)`${d}`):e.setParams({ifClause:d})}}}};function _x(e,t){let n=e.schema[t];return n!==void 0&&!(0,yx.alwaysValidSchema)(e,n)}Ph.default=z1});var $x=A(Oh=>{"use strict";Object.defineProperty(Oh,"__esModule",{value:!0});var I1=fe(),E1={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:n}){t.if===void 0&&(0,I1.checkStrictMode)(n,`"${e}" without "if" is ignored`)}};Oh.default=E1});var xx=A(jh=>{"use strict";Object.defineProperty(jh,"__esModule",{value:!0});var T1=mh(),P1=Y$(),O1=hh(),j1=ex(),N1=tx(),R1=ox(),A1=ax(),D1=xh(),C1=ux(),U1=px(),Z1=mx(),M1=hx(),L1=gx(),q1=vx(),V1=bx(),F1=$x();function B1(e=!1){let t=[Z1.default,M1.default,L1.default,q1.default,V1.default,F1.default,A1.default,D1.default,R1.default,C1.default,U1.default];return e?t.push(P1.default,j1.default):t.push(T1.default,O1.default),t.push(N1.default),t}jh.default=B1});var wx=A(Nh=>{"use strict";Object.defineProperty(Nh,"__esModule",{value:!0});var Te=re(),K1={message:({schemaCode:e})=>(0,Te.str)`must match format "${e}"`,params:({schemaCode:e})=>(0,Te._)`{format: ${e}}`},H1={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:K1,code(e,t){let{gen:n,data:o,$data:r,schema:i,schemaCode:a,it:s}=e,{opts:c,errSchemaPath:l,schemaEnv:d,self:f}=s;if(!c.validateFormats)return;r?_():v();function _(){let g=n.scopeValue("formats",{ref:f.formats,code:c.code.formats}),b=n.const("fDef",(0,Te._)`${g}[${a}]`),x=n.let("fType"),I=n.let("format");n.if((0,Te._)`typeof ${b} == "object" && !(${b} instanceof RegExp)`,()=>n.assign(x,(0,Te._)`${b}.type || "string"`).assign(I,(0,Te._)`${b}.validate`),()=>n.assign(x,(0,Te._)`"string"`).assign(I,b)),e.fail$data((0,Te.or)(R(),P()));function R(){return c.strictSchema===!1?Te.nil:(0,Te._)`${a} && !${I}`}function P(){let M=d.$async?(0,Te._)`(${b}.async ? await ${I}(${o}) : ${I}(${o}))`:(0,Te._)`${I}(${o})`,V=(0,Te._)`(typeof ${I} == "function" ? ${M} : ${I}.test(${o}))`;return(0,Te._)`${I} && ${I} !== true && ${x} === ${t} && !${V}`}}function v(){let g=f.formats[i];if(!g){R();return}if(g===!0)return;let[b,x,I]=P(g);b===t&&e.pass(M());function R(){if(c.strictSchema===!1){f.logger.warn(V());return}throw new Error(V());function V(){return`unknown format "${i}" ignored in schema at path "${l}"`}}function P(V){let Me=V instanceof RegExp?(0,Te.regexpCode)(V):c.code.formats?(0,Te._)`${c.code.formats}${(0,Te.getProperty)(i)}`:void 0,ct=n.scopeValue("formats",{key:i,ref:V,code:Me});return typeof V=="object"&&!(V instanceof RegExp)?[V.type||"string",V.validate,(0,Te._)`${ct}.validate`]:["string",V,ct]}function M(){if(typeof g=="object"&&!(g instanceof RegExp)&&g.async){if(!d.$async)throw new Error("async format in sync schema");return(0,Te._)`await ${I}(${o})`}return typeof x=="function"?(0,Te._)`${I}(${o})`:(0,Te._)`${I}.test(${o})`}}}};Nh.default=H1});var kx=A(Rh=>{"use strict";Object.defineProperty(Rh,"__esModule",{value:!0});var J1=wx(),G1=[J1.default];Rh.default=G1});var Sx=A(Eo=>{"use strict";Object.defineProperty(Eo,"__esModule",{value:!0});Eo.contentVocabulary=Eo.metadataVocabulary=void 0;Eo.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];Eo.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]});var Ix=A(Ah=>{"use strict";Object.defineProperty(Ah,"__esModule",{value:!0});var W1=R$(),X1=J$(),Y1=xx(),Q1=kx(),zx=Sx(),eA=[W1.default,X1.default,(0,Y1.default)(),Q1.default,zx.metadataVocabulary,zx.contentVocabulary];Ah.default=eA});var Tx=A(Cl=>{"use strict";Object.defineProperty(Cl,"__esModule",{value:!0});Cl.DiscrError=void 0;var Ex;(function(e){e.Tag="tag",e.Mapping="mapping"})(Ex||(Cl.DiscrError=Ex={}))});var Ox=A(Ch=>{"use strict";Object.defineProperty(Ch,"__esModule",{value:!0});var To=re(),Dh=Tx(),Px=yl(),tA=_a(),rA=fe(),nA={message:({params:{discrError:e,tagName:t}})=>e===Dh.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:n}})=>(0,To._)`{error: ${e}, tag: ${n}, tagValue: ${t}}`},oA={keyword:"discriminator",type:"object",schemaType:"object",error:nA,code(e){let{gen:t,data:n,schema:o,parentSchema:r,it:i}=e,{oneOf:a}=r;if(!i.opts.discriminator)throw new Error("discriminator: requires discriminator option");let s=o.propertyName;if(typeof s!="string")throw new Error("discriminator: requires propertyName");if(o.mapping)throw new Error("discriminator: mapping is not supported");if(!a)throw new Error("discriminator: requires oneOf keyword");let c=t.let("valid",!1),l=t.const("tag",(0,To._)`${n}${(0,To.getProperty)(s)}`);t.if((0,To._)`typeof ${l} == "string"`,()=>d(),()=>e.error(!1,{discrError:Dh.DiscrError.Tag,tag:l,tagName:s})),e.ok(c);function d(){let v=_();t.if(!1);for(let g in v)t.elseIf((0,To._)`${l} === ${g}`),t.assign(c,f(v[g]));t.else(),e.error(!1,{discrError:Dh.DiscrError.Mapping,tag:l,tagName:s}),t.endIf()}function f(v){let g=t.name("valid"),b=e.subschema({keyword:"oneOf",schemaProp:v},g);return e.mergeEvaluated(b,To.Name),g}function _(){var v;let g={},b=I(r),x=!0;for(let M=0;M<a.length;M++){let V=a[M];if(V?.$ref&&!(0,rA.schemaHasRulesButRef)(V,i.self.RULES)){let ct=V.$ref;if(V=Px.resolveRef.call(i.self,i.schemaEnv.root,i.baseId,ct),V instanceof Px.SchemaEnv&&(V=V.schema),V===void 0)throw new tA.default(i.opts.uriResolver,i.baseId,ct)}let Me=(v=V?.properties)===null||v===void 0?void 0:v[s];if(typeof Me!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${s}"`);x=x&&(b||I(V)),R(Me,M)}if(!x)throw new Error(`discriminator: "${s}" must be required`);return g;function I({required:M}){return Array.isArray(M)&&M.includes(s)}function R(M,V){if(M.const)P(M.const,V);else if(M.enum)for(let Me of M.enum)P(Me,V);else throw new Error(`discriminator: "properties/${s}" must have "const" or "enum"`)}function P(M,V){if(typeof M!="string"||M in g)throw new Error(`discriminator: "${s}" values must be unique strings`);g[M]=V}}}};Ch.default=oA});var jx=A((_q,iA)=>{iA.exports={$schema:"http://json-schema.org/draft-07/schema#",$id:"http://json-schema.org/draft-07/schema#",title:"Core schema meta-schema",definitions:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},type:["object","boolean"],properties:{$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},default:!0}});var Zh=A((ze,Uh)=>{"use strict";Object.defineProperty(ze,"__esModule",{value:!0});ze.MissingRefError=ze.ValidationError=ze.CodeGen=ze.Name=ze.nil=ze.stringify=ze.str=ze._=ze.KeywordCxt=ze.Ajv=void 0;var aA=E$(),sA=Ix(),cA=Ox(),Nx=jx(),uA=["/properties"],Ul="http://json-schema.org/draft-07/schema",Po=class extends aA.default{_addVocabularies(){super._addVocabularies(),sA.default.forEach(t=>this.addVocabulary(t)),this.opts.discriminator&&this.addKeyword(cA.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;let t=this.opts.$data?this.$dataMetaSchema(Nx,uA):Nx;this.addMetaSchema(t,Ul,!1),this.refs["http://json-schema.org/schema"]=Ul}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(Ul)?Ul:void 0)}};ze.Ajv=Po;Uh.exports=ze=Po;Uh.exports.Ajv=Po;Object.defineProperty(ze,"__esModule",{value:!0});ze.default=Po;var lA=va();Object.defineProperty(ze,"KeywordCxt",{enumerable:!0,get:function(){return lA.KeywordCxt}});var Oo=re();Object.defineProperty(ze,"_",{enumerable:!0,get:function(){return Oo._}});Object.defineProperty(ze,"str",{enumerable:!0,get:function(){return Oo.str}});Object.defineProperty(ze,"stringify",{enumerable:!0,get:function(){return Oo.stringify}});Object.defineProperty(ze,"nil",{enumerable:!0,get:function(){return Oo.nil}});Object.defineProperty(ze,"Name",{enumerable:!0,get:function(){return Oo.Name}});Object.defineProperty(ze,"CodeGen",{enumerable:!0,get:function(){return Oo.CodeGen}});var dA=vl();Object.defineProperty(ze,"ValidationError",{enumerable:!0,get:function(){return dA.default}});var fA=_a();Object.defineProperty(ze,"MissingRefError",{enumerable:!0,get:function(){return fA.default}})});var Lx=A(Jt=>{"use strict";Object.defineProperty(Jt,"__esModule",{value:!0});Jt.formatNames=Jt.fastFormats=Jt.fullFormats=void 0;function Ht(e,t){return{validate:e,compare:t}}Jt.fullFormats={date:Ht(Cx,Vh),time:Ht(Lh(!0),Fh),"date-time":Ht(Rx(!0),Zx),"iso-time":Ht(Lh(),Ux),"iso-date-time":Ht(Rx(),Mx),duration:/^P(?!$)((\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+S)?)?|(\d+W)?)$/,uri:_A,"uri-reference":/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,"uri-template":/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,url:/^(?:https?|ftp):\/\/(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)(?:\.(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)*(?:\.(?:[a-z\u{00a1}-\u{ffff}]{2,})))(?::\d{2,5})?(?:\/[^\s]*)?$/iu,email:/^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:/^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)$/,ipv6:/^((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){5}(((:[0-9a-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9a-f]{1,4}){1,7})|((:[0-9a-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))$/i,regex:SA,uuid:/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,"json-pointer":/^(?:\/(?:[^~/]|~0|~1)*)*$/,"json-pointer-uri-fragment":/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,"relative-json-pointer":/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/,byte:yA,int32:{type:"number",validate:xA},int64:{type:"number",validate:wA},float:{type:"number",validate:Dx},double:{type:"number",validate:Dx},password:!0,binary:!0};Jt.fastFormats={...Jt.fullFormats,date:Ht(/^\d\d\d\d-[0-1]\d-[0-3]\d$/,Vh),time:Ht(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,Fh),"date-time":Ht(/^\d\d\d\d-[0-1]\d-[0-3]\dt(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,Zx),"iso-time":Ht(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,Ux),"iso-date-time":Ht(/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,Mx),uri:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,email:/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i};Jt.formatNames=Object.keys(Jt.fullFormats);function pA(e){return e%4===0&&(e%100!==0||e%400===0)}var mA=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,hA=[0,31,28,31,30,31,30,31,31,30,31,30,31];function Cx(e){let t=mA.exec(e);if(!t)return!1;let n=+t[1],o=+t[2],r=+t[3];return o>=1&&o<=12&&r>=1&&r<=(o===2&&pA(n)?29:hA[o])}function Vh(e,t){if(e&&t)return e>t?1:e<t?-1:0}var Mh=/^(\d\d):(\d\d):(\d\d(?:\.\d+)?)(z|([+-])(\d\d)(?::?(\d\d))?)?$/i;function Lh(e){return function(n){let o=Mh.exec(n);if(!o)return!1;let r=+o[1],i=+o[2],a=+o[3],s=o[4],c=o[5]==="-"?-1:1,l=+(o[6]||0),d=+(o[7]||0);if(l>23||d>59||e&&!s)return!1;if(r<=23&&i<=59&&a<60)return!0;let f=i-d*c,_=r-l*c-(f<0?1:0);return(_===23||_===-1)&&(f===59||f===-1)&&a<61}}function Fh(e,t){if(!(e&&t))return;let n=new Date("2020-01-01T"+e).valueOf(),o=new Date("2020-01-01T"+t).valueOf();if(n&&o)return n-o}function Ux(e,t){if(!(e&&t))return;let n=Mh.exec(e),o=Mh.exec(t);if(n&&o)return e=n[1]+n[2]+n[3],t=o[1]+o[2]+o[3],e>t?1:e<t?-1:0}var qh=/t|\s/i;function Rx(e){let t=Lh(e);return function(o){let r=o.split(qh);return r.length===2&&Cx(r[0])&&t(r[1])}}function Zx(e,t){if(!(e&&t))return;let n=new Date(e).valueOf(),o=new Date(t).valueOf();if(n&&o)return n-o}function Mx(e,t){if(!(e&&t))return;let[n,o]=e.split(qh),[r,i]=t.split(qh),a=Vh(n,r);if(a!==void 0)return a||Fh(o,i)}var gA=/\/|:/,vA=/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i;function _A(e){return gA.test(e)&&vA.test(e)}var Ax=/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/gm;function yA(e){return Ax.lastIndex=0,Ax.test(e)}var bA=-(2**31),$A=2**31-1;function xA(e){return Number.isInteger(e)&&e<=$A&&e>=bA}function wA(e){return Number.isInteger(e)}function Dx(){return!0}var kA=/[^\\]\\Z/;function SA(e){if(kA.test(e))return!1;try{return new RegExp(e),!0}catch{return!1}}});var qx=A(jo=>{"use strict";Object.defineProperty(jo,"__esModule",{value:!0});jo.formatLimitDefinition=void 0;var zA=Zh(),Dt=re(),Ur=Dt.operators,Zl={formatMaximum:{okStr:"<=",ok:Ur.LTE,fail:Ur.GT},formatMinimum:{okStr:">=",ok:Ur.GTE,fail:Ur.LT},formatExclusiveMaximum:{okStr:"<",ok:Ur.LT,fail:Ur.GTE},formatExclusiveMinimum:{okStr:">",ok:Ur.GT,fail:Ur.LTE}},IA={message:({keyword:e,schemaCode:t})=>(0,Dt.str)`should be ${Zl[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>(0,Dt._)`{comparison: ${Zl[e].okStr}, limit: ${t}}`};jo.formatLimitDefinition={keyword:Object.keys(Zl),type:"string",schemaType:"string",$data:!0,error:IA,code(e){let{gen:t,data:n,schemaCode:o,keyword:r,it:i}=e,{opts:a,self:s}=i;if(!a.validateFormats)return;let c=new zA.KeywordCxt(i,s.RULES.all.format.definition,"format");c.$data?l():d();function l(){let _=t.scopeValue("formats",{ref:s.formats,code:a.code.formats}),v=t.const("fmt",(0,Dt._)`${_}[${c.schemaCode}]`);e.fail$data((0,Dt.or)((0,Dt._)`typeof ${v} != "object"`,(0,Dt._)`${v} instanceof RegExp`,(0,Dt._)`typeof ${v}.compare != "function"`,f(v)))}function d(){let _=c.schema,v=s.formats[_];if(!v||v===!0)return;if(typeof v!="object"||v instanceof RegExp||typeof v.compare!="function")throw new Error(`"${r}": format "${_}" does not define "compare" function`);let g=t.scopeValue("formats",{key:_,ref:v,code:a.code.formats?(0,Dt._)`${a.code.formats}${(0,Dt.getProperty)(_)}`:void 0});e.fail$data(f(g))}function f(_){return(0,Dt._)`${_}.compare(${n}, ${o}) ${Zl[r].fail} 0`}},dependencies:["format"]};var EA=e=>(e.addKeyword(jo.formatLimitDefinition),e);jo.default=EA});var Kx=A((ja,Bx)=>{"use strict";Object.defineProperty(ja,"__esModule",{value:!0});var No=Lx(),TA=qx(),Bh=re(),Vx=new Bh.Name("fullFormats"),PA=new Bh.Name("fastFormats"),Kh=(e,t={keywords:!0})=>{if(Array.isArray(t))return Fx(e,t,No.fullFormats,Vx),e;let[n,o]=t.mode==="fast"?[No.fastFormats,PA]:[No.fullFormats,Vx],r=t.formats||No.formatNames;return Fx(e,r,n,o),t.keywords&&(0,TA.default)(e),e};Kh.get=(e,t="full")=>{let o=(t==="fast"?No.fastFormats:No.fullFormats)[e];if(!o)throw new Error(`Unknown format "${e}"`);return o};function Fx(e,t,n,o){var r,i;(r=(i=e.opts.code).formats)!==null&&r!==void 0||(i.formats=(0,Bh._)`require("ajv-formats/dist/formats").${o}`);for(let a of t)e.addFormat(a,n[a])}Bx.exports=ja=Kh;Object.defineProperty(ja,"__esModule",{value:!0});ja.default=Kh});var Yh=A((Xh,ow)=>{(function(e,t){"use strict";typeof define=="function"&&define.amd?define("stackframe",[],t):typeof Xh=="object"?ow.exports=t():e.StackFrame=t()})(Xh,function(){"use strict";function e(v){return!isNaN(parseFloat(v))&&isFinite(v)}function t(v){return v.charAt(0).toUpperCase()+v.substring(1)}function n(v){return function(){return this[v]}}var o=["isConstructor","isEval","isNative","isToplevel"],r=["columnNumber","lineNumber"],i=["fileName","functionName","source"],a=["args"],s=["evalOrigin"],c=o.concat(r,i,a,s);function l(v){if(v)for(var g=0;g<c.length;g++)v[c[g]]!==void 0&&this["set"+t(c[g])](v[c[g]])}l.prototype={getArgs:function(){return this.args},setArgs:function(v){if(Object.prototype.toString.call(v)!=="[object Array]")throw new TypeError("Args must be an Array");this.args=v},getEvalOrigin:function(){return this.evalOrigin},setEvalOrigin:function(v){if(v instanceof l)this.evalOrigin=v;else if(v instanceof Object)this.evalOrigin=new l(v);else throw new TypeError("Eval Origin must be an Object or StackFrame")},toString:function(){var v=this.getFileName()||"",g=this.getLineNumber()||"",b=this.getColumnNumber()||"",x=this.getFunctionName()||"";return this.getIsEval()?v?"[eval] ("+v+":"+g+":"+b+")":"[eval]:"+g+":"+b:x?x+" ("+v+":"+g+":"+b+")":v+":"+g+":"+b}},l.fromString=function(g){var b=g.indexOf("("),x=g.lastIndexOf(")"),I=g.substring(0,b),R=g.substring(b+1,x).split(","),P=g.substring(x+1);if(P.indexOf("@")===0)var M=/@(.+?)(?::(\d+))?(?::(\d+))?$/.exec(P,""),V=M[1],Me=M[2],ct=M[3];return new l({functionName:I,args:R||void 0,fileName:V,lineNumber:Me||void 0,columnNumber:ct||void 0})};for(var d=0;d<o.length;d++)l.prototype["get"+t(o[d])]=n(o[d]),l.prototype["set"+t(o[d])]=(function(v){return function(g){this[v]=!!g}})(o[d]);for(var f=0;f<r.length;f++)l.prototype["get"+t(r[f])]=n(r[f]),l.prototype["set"+t(r[f])]=(function(v){return function(g){if(!e(g))throw new TypeError(v+" must be a Number");this[v]=Number(g)}})(r[f]);for(var _=0;_<i.length;_++)l.prototype["get"+t(i[_])]=n(i[_]),l.prototype["set"+t(i[_])]=(function(v){return function(g){this[v]=String(g)}})(i[_]);return l})});var aw=A((Qh,iw)=>{(function(e,t){"use strict";typeof define=="function"&&define.amd?define("error-stack-parser",["stackframe"],t):typeof Qh=="object"?iw.exports=t(Yh()):e.ErrorStackParser=t(e.StackFrame)})(Qh,function(t){"use strict";var n=/(^|@)\S+:\d+/,o=/^\s*at .*(\S+:\d+|\(native\))/m,r=/^(eval@)?(\[native code])?$/;return{parse:function(a){if(typeof a.stacktrace<"u"||typeof a["opera#sourceloc"]<"u")return this.parseOpera(a);if(a.stack&&a.stack.match(o))return this.parseV8OrIE(a);if(a.stack)return this.parseFFOrSafari(a);throw new Error("Cannot parse given Error object")},extractLocation:function(a){if(a.indexOf(":")===-1)return[a];var s=/(.+?)(?::(\d+))?(?::(\d+))?$/,c=s.exec(a.replace(/[()]/g,""));return[c[1],c[2]||void 0,c[3]||void 0]},parseV8OrIE:function(a){var s=a.stack.split(`
|
|
11
|
+
deps: ${n}}`};var p1={keyword:"dependencies",type:"object",schemaType:"object",error:Kt.error,code(e){let[t,n]=m1(e);ix(e,t),ax(e,n)}};function m1({schema:e}){let t={},n={};for(let o in e){if(o==="__proto__")continue;let r=Array.isArray(e[o])?t:n;r[o]=e[o]}return[t,n]}function ix(e,t=e.schema){let{gen:n,data:o,it:r}=e;if(Object.keys(t).length===0)return;let i=n.let("missing");for(let a in t){let s=t[a];if(s.length===0)continue;let c=(0,Pa.propertyInData)(n,o,a,r.opts.ownProperties);e.setParams({property:a,depsCount:s.length,deps:s.join(", ")}),r.allErrors?n.if(c,()=>{for(let l of s)(0,Pa.checkReportMissingProp)(e,l)}):(n.if((0,$h._)`${c} && (${(0,Pa.checkMissingProp)(e,s,i)})`),(0,Pa.reportMissingProp)(e,i),n.else())}}Kt.validatePropertyDeps=ix;function ax(e,t=e.schema){let{gen:n,data:o,keyword:r,it:i}=e,a=n.name("valid");for(let s in t)(0,f1.alwaysValidSchema)(i,t[s])||(n.if((0,Pa.propertyInData)(n,o,s,i.opts.ownProperties),()=>{let c=e.subschema({keyword:r,schemaProp:s},a);e.mergeValidEvaluated(c,a)},()=>n.var(a,!0)),e.ok(a))}Kt.validateSchemaDeps=ax;Kt.default=p1});var ux=A(xh=>{"use strict";Object.defineProperty(xh,"__esModule",{value:!0});var cx=re(),h1=fe(),g1={message:"property name must be valid",params:({params:e})=>(0,cx._)`{propertyName: ${e.propertyName}}`},v1={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:g1,code(e){let{gen:t,schema:n,data:o,it:r}=e;if((0,h1.alwaysValidSchema)(r,n))return;let i=t.name("valid");t.forIn("key",o,a=>{e.setParams({propertyName:a}),e.subschema({keyword:"propertyNames",data:a,dataTypes:["string"],propertyName:a,compositeRule:!0},i),t.if((0,cx.not)(i),()=>{e.error(!0),r.allErrors||t.break()})}),e.ok(i)}};xh.default=v1});var kh=A(wh=>{"use strict";Object.defineProperty(wh,"__esModule",{value:!0});var Nl=$t(),At=re(),_1=ir(),Rl=fe(),y1={message:"must NOT have additional properties",params:({params:e})=>(0,At._)`{additionalProperty: ${e.additionalProperty}}`},b1={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:y1,code(e){let{gen:t,schema:n,parentSchema:o,data:r,errsCount:i,it:a}=e;if(!i)throw new Error("ajv implementation error");let{allErrors:s,opts:c}=a;if(a.props=!0,c.removeAdditional!=="all"&&(0,Rl.alwaysValidSchema)(a,n))return;let l=(0,Nl.allSchemaProperties)(o.properties),d=(0,Nl.allSchemaProperties)(o.patternProperties);f(),e.ok((0,At._)`${i} === ${_1.default.errors}`);function f(){t.forIn("key",r,x=>{!l.length&&!d.length?g(x):t.if(_(x),()=>g(x))})}function _(x){let I;if(l.length>8){let R=(0,Rl.schemaRefOrVal)(a,o.properties,"properties");I=(0,Nl.isOwnProperty)(t,R,x)}else l.length?I=(0,At.or)(...l.map(R=>(0,At._)`${x} === ${R}`)):I=At.nil;return d.length&&(I=(0,At.or)(I,...d.map(R=>(0,At._)`${(0,Nl.usePattern)(e,R)}.test(${x})`))),(0,At.not)(I)}function v(x){t.code((0,At._)`delete ${r}[${x}]`)}function g(x){if(c.removeAdditional==="all"||c.removeAdditional&&n===!1){v(x);return}if(n===!1){e.setParams({additionalProperty:x}),e.error(),s||t.break();return}if(typeof n=="object"&&!(0,Rl.alwaysValidSchema)(a,n)){let I=t.name("valid");c.removeAdditional==="failing"?(b(x,I,!1),t.if((0,At.not)(I),()=>{e.reset(),v(x)})):(b(x,I),s||t.if((0,At.not)(I),()=>t.break()))}}function b(x,I,R){let O={keyword:"additionalProperties",dataProp:x,dataPropType:Rl.Type.Str};R===!1&&Object.assign(O,{compositeRule:!0,createErrors:!1,allErrors:!1}),e.subschema(O,I)}}};wh.default=b1});var fx=A(zh=>{"use strict";Object.defineProperty(zh,"__esModule",{value:!0});var $1=va(),lx=$t(),Sh=fe(),dx=kh(),x1={keyword:"properties",type:"object",schemaType:"object",code(e){let{gen:t,schema:n,parentSchema:o,data:r,it:i}=e;i.opts.removeAdditional==="all"&&o.additionalProperties===void 0&&dx.default.code(new $1.KeywordCxt(i,dx.default,"additionalProperties"));let a=(0,lx.allSchemaProperties)(n);for(let f of a)i.definedProperties.add(f);i.opts.unevaluated&&a.length&&i.props!==!0&&(i.props=Sh.mergeEvaluated.props(t,(0,Sh.toHash)(a),i.props));let s=a.filter(f=>!(0,Sh.alwaysValidSchema)(i,n[f]));if(s.length===0)return;let c=t.name("valid");for(let f of s)l(f)?d(f):(t.if((0,lx.propertyInData)(t,r,f,i.opts.ownProperties)),d(f),i.allErrors||t.else().var(c,!0),t.endIf()),e.it.definedProperties.add(f),e.ok(c);function l(f){return i.opts.useDefaults&&!i.compositeRule&&n[f].default!==void 0}function d(f){e.subschema({keyword:"properties",schemaProp:f,dataProp:f},c)}}};zh.default=x1});var gx=A(Ih=>{"use strict";Object.defineProperty(Ih,"__esModule",{value:!0});var px=$t(),Al=re(),mx=fe(),hx=fe(),w1={keyword:"patternProperties",type:"object",schemaType:"object",code(e){let{gen:t,schema:n,data:o,parentSchema:r,it:i}=e,{opts:a}=i,s=(0,px.allSchemaProperties)(n),c=s.filter(b=>(0,mx.alwaysValidSchema)(i,n[b]));if(s.length===0||c.length===s.length&&(!i.opts.unevaluated||i.props===!0))return;let l=a.strictSchema&&!a.allowMatchingProperties&&r.properties,d=t.name("valid");i.props!==!0&&!(i.props instanceof Al.Name)&&(i.props=(0,hx.evaluatedPropsToName)(t,i.props));let{props:f}=i;_();function _(){for(let b of s)l&&v(b),i.allErrors?g(b):(t.var(d,!0),g(b),t.if(d))}function v(b){for(let x in l)new RegExp(b).test(x)&&(0,mx.checkStrictMode)(i,`property ${x} matches pattern ${b} (use allowMatchingProperties)`)}function g(b){t.forIn("key",o,x=>{t.if((0,Al._)`${(0,px.usePattern)(e,b)}.test(${x})`,()=>{let I=c.includes(b);I||e.subschema({keyword:"patternProperties",schemaProp:b,dataProp:x,dataPropType:hx.Type.Str},d),i.opts.unevaluated&&f!==!0?t.assign((0,Al._)`${f}[${x}]`,!0):!I&&!i.allErrors&&t.if((0,Al.not)(d),()=>t.break())})})}}};Ih.default=w1});var vx=A(Eh=>{"use strict";Object.defineProperty(Eh,"__esModule",{value:!0});var k1=fe(),S1={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){let{gen:t,schema:n,it:o}=e;if((0,k1.alwaysValidSchema)(o,n)){e.fail();return}let r=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},r),e.failResult(r,()=>e.reset(),()=>e.error())},error:{message:"must NOT be valid"}};Eh.default=S1});var _x=A(Th=>{"use strict";Object.defineProperty(Th,"__esModule",{value:!0});var z1=$t(),I1={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:z1.validateUnion,error:{message:"must match a schema in anyOf"}};Th.default=I1});var yx=A(Oh=>{"use strict";Object.defineProperty(Oh,"__esModule",{value:!0});var Dl=re(),E1=fe(),T1={message:"must match exactly one schema in oneOf",params:({params:e})=>(0,Dl._)`{passingSchemas: ${e.passing}}`},O1={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:T1,code(e){let{gen:t,schema:n,parentSchema:o,it:r}=e;if(!Array.isArray(n))throw new Error("ajv implementation error");if(r.opts.discriminator&&o.discriminator)return;let i=n,a=t.let("valid",!1),s=t.let("passing",null),c=t.name("_valid");e.setParams({passing:s}),t.block(l),e.result(a,()=>e.reset(),()=>e.error(!0));function l(){i.forEach((d,f)=>{let _;(0,E1.alwaysValidSchema)(r,d)?t.var(c,!0):_=e.subschema({keyword:"oneOf",schemaProp:f,compositeRule:!0},c),f>0&&t.if((0,Dl._)`${c} && ${a}`).assign(a,!1).assign(s,(0,Dl._)`[${s}, ${f}]`).else(),t.if(c,()=>{t.assign(a,!0),t.assign(s,f),_&&e.mergeEvaluated(_,Dl.Name)})})}}};Oh.default=O1});var bx=A(Ph=>{"use strict";Object.defineProperty(Ph,"__esModule",{value:!0});var P1=fe(),j1={keyword:"allOf",schemaType:"array",code(e){let{gen:t,schema:n,it:o}=e;if(!Array.isArray(n))throw new Error("ajv implementation error");let r=t.name("valid");n.forEach((i,a)=>{if((0,P1.alwaysValidSchema)(o,i))return;let s=e.subschema({keyword:"allOf",schemaProp:a},r);e.ok(r),e.mergeEvaluated(s)})}};Ph.default=j1});var wx=A(jh=>{"use strict";Object.defineProperty(jh,"__esModule",{value:!0});var Cl=re(),xx=fe(),N1={message:({params:e})=>(0,Cl.str)`must match "${e.ifClause}" schema`,params:({params:e})=>(0,Cl._)`{failingKeyword: ${e.ifClause}}`},R1={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:N1,code(e){let{gen:t,parentSchema:n,it:o}=e;n.then===void 0&&n.else===void 0&&(0,xx.checkStrictMode)(o,'"if" without "then" and "else" is ignored');let r=$x(o,"then"),i=$x(o,"else");if(!r&&!i)return;let a=t.let("valid",!0),s=t.name("_valid");if(c(),e.reset(),r&&i){let d=t.let("ifClause");e.setParams({ifClause:d}),t.if(s,l("then",d),l("else",d))}else r?t.if(s,l("then")):t.if((0,Cl.not)(s),l("else"));e.pass(a,()=>e.error(!0));function c(){let d=e.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},s);e.mergeEvaluated(d)}function l(d,f){return()=>{let _=e.subschema({keyword:d},s);t.assign(a,s),e.mergeValidEvaluated(_,a),f?t.assign(f,(0,Cl._)`${d}`):e.setParams({ifClause:d})}}}};function $x(e,t){let n=e.schema[t];return n!==void 0&&!(0,xx.alwaysValidSchema)(e,n)}jh.default=R1});var kx=A(Nh=>{"use strict";Object.defineProperty(Nh,"__esModule",{value:!0});var A1=fe(),D1={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:n}){t.if===void 0&&(0,A1.checkStrictMode)(n,`"${e}" without "if" is ignored`)}};Nh.default=D1});var Sx=A(Rh=>{"use strict";Object.defineProperty(Rh,"__esModule",{value:!0});var C1=gh(),U1=tx(),Z1=vh(),M1=nx(),L1=ox(),q1=sx(),V1=ux(),F1=kh(),B1=fx(),K1=gx(),H1=vx(),J1=_x(),G1=yx(),W1=bx(),X1=wx(),Y1=kx();function Q1(e=!1){let t=[H1.default,J1.default,G1.default,W1.default,X1.default,Y1.default,V1.default,F1.default,q1.default,B1.default,K1.default];return e?t.push(U1.default,M1.default):t.push(C1.default,Z1.default),t.push(L1.default),t}Rh.default=Q1});var zx=A(Ah=>{"use strict";Object.defineProperty(Ah,"__esModule",{value:!0});var Te=re(),eA={message:({schemaCode:e})=>(0,Te.str)`must match format "${e}"`,params:({schemaCode:e})=>(0,Te._)`{format: ${e}}`},tA={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:eA,code(e,t){let{gen:n,data:o,$data:r,schema:i,schemaCode:a,it:s}=e,{opts:c,errSchemaPath:l,schemaEnv:d,self:f}=s;if(!c.validateFormats)return;r?_():v();function _(){let g=n.scopeValue("formats",{ref:f.formats,code:c.code.formats}),b=n.const("fDef",(0,Te._)`${g}[${a}]`),x=n.let("fType"),I=n.let("format");n.if((0,Te._)`typeof ${b} == "object" && !(${b} instanceof RegExp)`,()=>n.assign(x,(0,Te._)`${b}.type || "string"`).assign(I,(0,Te._)`${b}.validate`),()=>n.assign(x,(0,Te._)`"string"`).assign(I,b)),e.fail$data((0,Te.or)(R(),O()));function R(){return c.strictSchema===!1?Te.nil:(0,Te._)`${a} && !${I}`}function O(){let M=d.$async?(0,Te._)`(${b}.async ? await ${I}(${o}) : ${I}(${o}))`:(0,Te._)`${I}(${o})`,V=(0,Te._)`(typeof ${I} == "function" ? ${M} : ${I}.test(${o}))`;return(0,Te._)`${I} && ${I} !== true && ${x} === ${t} && !${V}`}}function v(){let g=f.formats[i];if(!g){R();return}if(g===!0)return;let[b,x,I]=O(g);b===t&&e.pass(M());function R(){if(c.strictSchema===!1){f.logger.warn(V());return}throw new Error(V());function V(){return`unknown format "${i}" ignored in schema at path "${l}"`}}function O(V){let Me=V instanceof RegExp?(0,Te.regexpCode)(V):c.code.formats?(0,Te._)`${c.code.formats}${(0,Te.getProperty)(i)}`:void 0,ct=n.scopeValue("formats",{key:i,ref:V,code:Me});return typeof V=="object"&&!(V instanceof RegExp)?[V.type||"string",V.validate,(0,Te._)`${ct}.validate`]:["string",V,ct]}function M(){if(typeof g=="object"&&!(g instanceof RegExp)&&g.async){if(!d.$async)throw new Error("async format in sync schema");return(0,Te._)`await ${I}(${o})`}return typeof x=="function"?(0,Te._)`${I}(${o})`:(0,Te._)`${I}.test(${o})`}}}};Ah.default=tA});var Ix=A(Dh=>{"use strict";Object.defineProperty(Dh,"__esModule",{value:!0});var rA=zx(),nA=[rA.default];Dh.default=nA});var Ex=A(Eo=>{"use strict";Object.defineProperty(Eo,"__esModule",{value:!0});Eo.contentVocabulary=Eo.metadataVocabulary=void 0;Eo.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];Eo.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]});var Ox=A(Ch=>{"use strict";Object.defineProperty(Ch,"__esModule",{value:!0});var oA=C$(),iA=X$(),aA=Sx(),sA=Ix(),Tx=Ex(),cA=[oA.default,iA.default,(0,aA.default)(),sA.default,Tx.metadataVocabulary,Tx.contentVocabulary];Ch.default=cA});var jx=A(Ul=>{"use strict";Object.defineProperty(Ul,"__esModule",{value:!0});Ul.DiscrError=void 0;var Px;(function(e){e.Tag="tag",e.Mapping="mapping"})(Px||(Ul.DiscrError=Px={}))});var Rx=A(Zh=>{"use strict";Object.defineProperty(Zh,"__esModule",{value:!0});var To=re(),Uh=jx(),Nx=bl(),uA=_a(),lA=fe(),dA={message:({params:{discrError:e,tagName:t}})=>e===Uh.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:n}})=>(0,To._)`{error: ${e}, tag: ${n}, tagValue: ${t}}`},fA={keyword:"discriminator",type:"object",schemaType:"object",error:dA,code(e){let{gen:t,data:n,schema:o,parentSchema:r,it:i}=e,{oneOf:a}=r;if(!i.opts.discriminator)throw new Error("discriminator: requires discriminator option");let s=o.propertyName;if(typeof s!="string")throw new Error("discriminator: requires propertyName");if(o.mapping)throw new Error("discriminator: mapping is not supported");if(!a)throw new Error("discriminator: requires oneOf keyword");let c=t.let("valid",!1),l=t.const("tag",(0,To._)`${n}${(0,To.getProperty)(s)}`);t.if((0,To._)`typeof ${l} == "string"`,()=>d(),()=>e.error(!1,{discrError:Uh.DiscrError.Tag,tag:l,tagName:s})),e.ok(c);function d(){let v=_();t.if(!1);for(let g in v)t.elseIf((0,To._)`${l} === ${g}`),t.assign(c,f(v[g]));t.else(),e.error(!1,{discrError:Uh.DiscrError.Mapping,tag:l,tagName:s}),t.endIf()}function f(v){let g=t.name("valid"),b=e.subschema({keyword:"oneOf",schemaProp:v},g);return e.mergeEvaluated(b,To.Name),g}function _(){var v;let g={},b=I(r),x=!0;for(let M=0;M<a.length;M++){let V=a[M];if(V?.$ref&&!(0,lA.schemaHasRulesButRef)(V,i.self.RULES)){let ct=V.$ref;if(V=Nx.resolveRef.call(i.self,i.schemaEnv.root,i.baseId,ct),V instanceof Nx.SchemaEnv&&(V=V.schema),V===void 0)throw new uA.default(i.opts.uriResolver,i.baseId,ct)}let Me=(v=V?.properties)===null||v===void 0?void 0:v[s];if(typeof Me!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${s}"`);x=x&&(b||I(V)),R(Me,M)}if(!x)throw new Error(`discriminator: "${s}" must be required`);return g;function I({required:M}){return Array.isArray(M)&&M.includes(s)}function R(M,V){if(M.const)O(M.const,V);else if(M.enum)for(let Me of M.enum)O(Me,V);else throw new Error(`discriminator: "properties/${s}" must have "const" or "enum"`)}function O(M,V){if(typeof M!="string"||M in g)throw new Error(`discriminator: "${s}" values must be unique strings`);g[M]=V}}}};Zh.default=fA});var Ax=A((Zq,pA)=>{pA.exports={$schema:"http://json-schema.org/draft-07/schema#",$id:"http://json-schema.org/draft-07/schema#",title:"Core schema meta-schema",definitions:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},type:["object","boolean"],properties:{$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},default:!0}});var Lh=A((ze,Mh)=>{"use strict";Object.defineProperty(ze,"__esModule",{value:!0});ze.MissingRefError=ze.ValidationError=ze.CodeGen=ze.Name=ze.nil=ze.stringify=ze.str=ze._=ze.KeywordCxt=ze.Ajv=void 0;var mA=P$(),hA=Ox(),gA=Rx(),Dx=Ax(),vA=["/properties"],Zl="http://json-schema.org/draft-07/schema",Oo=class extends mA.default{_addVocabularies(){super._addVocabularies(),hA.default.forEach(t=>this.addVocabulary(t)),this.opts.discriminator&&this.addKeyword(gA.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;let t=this.opts.$data?this.$dataMetaSchema(Dx,vA):Dx;this.addMetaSchema(t,Zl,!1),this.refs["http://json-schema.org/schema"]=Zl}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(Zl)?Zl:void 0)}};ze.Ajv=Oo;Mh.exports=ze=Oo;Mh.exports.Ajv=Oo;Object.defineProperty(ze,"__esModule",{value:!0});ze.default=Oo;var _A=va();Object.defineProperty(ze,"KeywordCxt",{enumerable:!0,get:function(){return _A.KeywordCxt}});var Po=re();Object.defineProperty(ze,"_",{enumerable:!0,get:function(){return Po._}});Object.defineProperty(ze,"str",{enumerable:!0,get:function(){return Po.str}});Object.defineProperty(ze,"stringify",{enumerable:!0,get:function(){return Po.stringify}});Object.defineProperty(ze,"nil",{enumerable:!0,get:function(){return Po.nil}});Object.defineProperty(ze,"Name",{enumerable:!0,get:function(){return Po.Name}});Object.defineProperty(ze,"CodeGen",{enumerable:!0,get:function(){return Po.CodeGen}});var yA=_l();Object.defineProperty(ze,"ValidationError",{enumerable:!0,get:function(){return yA.default}});var bA=_a();Object.defineProperty(ze,"MissingRefError",{enumerable:!0,get:function(){return bA.default}})});var Fx=A(Jt=>{"use strict";Object.defineProperty(Jt,"__esModule",{value:!0});Jt.formatNames=Jt.fastFormats=Jt.fullFormats=void 0;function Ht(e,t){return{validate:e,compare:t}}Jt.fullFormats={date:Ht(Mx,Bh),time:Ht(Vh(!0),Kh),"date-time":Ht(Cx(!0),qx),"iso-time":Ht(Vh(),Lx),"iso-date-time":Ht(Cx(),Vx),duration:/^P(?!$)((\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+S)?)?|(\d+W)?)$/,uri:zA,"uri-reference":/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,"uri-template":/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,url:/^(?:https?|ftp):\/\/(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)(?:\.(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)*(?:\.(?:[a-z\u{00a1}-\u{ffff}]{2,})))(?::\d{2,5})?(?:\/[^\s]*)?$/iu,email:/^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:/^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)$/,ipv6:/^((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){5}(((:[0-9a-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9a-f]{1,4}){1,7})|((:[0-9a-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))$/i,regex:NA,uuid:/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,"json-pointer":/^(?:\/(?:[^~/]|~0|~1)*)*$/,"json-pointer-uri-fragment":/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,"relative-json-pointer":/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/,byte:IA,int32:{type:"number",validate:OA},int64:{type:"number",validate:PA},float:{type:"number",validate:Zx},double:{type:"number",validate:Zx},password:!0,binary:!0};Jt.fastFormats={...Jt.fullFormats,date:Ht(/^\d\d\d\d-[0-1]\d-[0-3]\d$/,Bh),time:Ht(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,Kh),"date-time":Ht(/^\d\d\d\d-[0-1]\d-[0-3]\dt(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,qx),"iso-time":Ht(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,Lx),"iso-date-time":Ht(/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,Vx),uri:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,email:/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i};Jt.formatNames=Object.keys(Jt.fullFormats);function $A(e){return e%4===0&&(e%100!==0||e%400===0)}var xA=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,wA=[0,31,28,31,30,31,30,31,31,30,31,30,31];function Mx(e){let t=xA.exec(e);if(!t)return!1;let n=+t[1],o=+t[2],r=+t[3];return o>=1&&o<=12&&r>=1&&r<=(o===2&&$A(n)?29:wA[o])}function Bh(e,t){if(e&&t)return e>t?1:e<t?-1:0}var qh=/^(\d\d):(\d\d):(\d\d(?:\.\d+)?)(z|([+-])(\d\d)(?::?(\d\d))?)?$/i;function Vh(e){return function(n){let o=qh.exec(n);if(!o)return!1;let r=+o[1],i=+o[2],a=+o[3],s=o[4],c=o[5]==="-"?-1:1,l=+(o[6]||0),d=+(o[7]||0);if(l>23||d>59||e&&!s)return!1;if(r<=23&&i<=59&&a<60)return!0;let f=i-d*c,_=r-l*c-(f<0?1:0);return(_===23||_===-1)&&(f===59||f===-1)&&a<61}}function Kh(e,t){if(!(e&&t))return;let n=new Date("2020-01-01T"+e).valueOf(),o=new Date("2020-01-01T"+t).valueOf();if(n&&o)return n-o}function Lx(e,t){if(!(e&&t))return;let n=qh.exec(e),o=qh.exec(t);if(n&&o)return e=n[1]+n[2]+n[3],t=o[1]+o[2]+o[3],e>t?1:e<t?-1:0}var Fh=/t|\s/i;function Cx(e){let t=Vh(e);return function(o){let r=o.split(Fh);return r.length===2&&Mx(r[0])&&t(r[1])}}function qx(e,t){if(!(e&&t))return;let n=new Date(e).valueOf(),o=new Date(t).valueOf();if(n&&o)return n-o}function Vx(e,t){if(!(e&&t))return;let[n,o]=e.split(Fh),[r,i]=t.split(Fh),a=Bh(n,r);if(a!==void 0)return a||Kh(o,i)}var kA=/\/|:/,SA=/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i;function zA(e){return kA.test(e)&&SA.test(e)}var Ux=/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/gm;function IA(e){return Ux.lastIndex=0,Ux.test(e)}var EA=-(2**31),TA=2**31-1;function OA(e){return Number.isInteger(e)&&e<=TA&&e>=EA}function PA(e){return Number.isInteger(e)}function Zx(){return!0}var jA=/[^\\]\\Z/;function NA(e){if(jA.test(e))return!1;try{return new RegExp(e),!0}catch{return!1}}});var Bx=A(jo=>{"use strict";Object.defineProperty(jo,"__esModule",{value:!0});jo.formatLimitDefinition=void 0;var RA=Lh(),Dt=re(),Ur=Dt.operators,Ml={formatMaximum:{okStr:"<=",ok:Ur.LTE,fail:Ur.GT},formatMinimum:{okStr:">=",ok:Ur.GTE,fail:Ur.LT},formatExclusiveMaximum:{okStr:"<",ok:Ur.LT,fail:Ur.GTE},formatExclusiveMinimum:{okStr:">",ok:Ur.GT,fail:Ur.LTE}},AA={message:({keyword:e,schemaCode:t})=>(0,Dt.str)`should be ${Ml[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>(0,Dt._)`{comparison: ${Ml[e].okStr}, limit: ${t}}`};jo.formatLimitDefinition={keyword:Object.keys(Ml),type:"string",schemaType:"string",$data:!0,error:AA,code(e){let{gen:t,data:n,schemaCode:o,keyword:r,it:i}=e,{opts:a,self:s}=i;if(!a.validateFormats)return;let c=new RA.KeywordCxt(i,s.RULES.all.format.definition,"format");c.$data?l():d();function l(){let _=t.scopeValue("formats",{ref:s.formats,code:a.code.formats}),v=t.const("fmt",(0,Dt._)`${_}[${c.schemaCode}]`);e.fail$data((0,Dt.or)((0,Dt._)`typeof ${v} != "object"`,(0,Dt._)`${v} instanceof RegExp`,(0,Dt._)`typeof ${v}.compare != "function"`,f(v)))}function d(){let _=c.schema,v=s.formats[_];if(!v||v===!0)return;if(typeof v!="object"||v instanceof RegExp||typeof v.compare!="function")throw new Error(`"${r}": format "${_}" does not define "compare" function`);let g=t.scopeValue("formats",{key:_,ref:v,code:a.code.formats?(0,Dt._)`${a.code.formats}${(0,Dt.getProperty)(_)}`:void 0});e.fail$data(f(g))}function f(_){return(0,Dt._)`${_}.compare(${n}, ${o}) ${Ml[r].fail} 0`}},dependencies:["format"]};var DA=e=>(e.addKeyword(jo.formatLimitDefinition),e);jo.default=DA});var Gx=A((ja,Jx)=>{"use strict";Object.defineProperty(ja,"__esModule",{value:!0});var No=Fx(),CA=Bx(),Hh=re(),Kx=new Hh.Name("fullFormats"),UA=new Hh.Name("fastFormats"),Jh=(e,t={keywords:!0})=>{if(Array.isArray(t))return Hx(e,t,No.fullFormats,Kx),e;let[n,o]=t.mode==="fast"?[No.fastFormats,UA]:[No.fullFormats,Kx],r=t.formats||No.formatNames;return Hx(e,r,n,o),t.keywords&&(0,CA.default)(e),e};Jh.get=(e,t="full")=>{let o=(t==="fast"?No.fastFormats:No.fullFormats)[e];if(!o)throw new Error(`Unknown format "${e}"`);return o};function Hx(e,t,n,o){var r,i;(r=(i=e.opts.code).formats)!==null&&r!==void 0||(i.formats=(0,Hh._)`require("ajv-formats/dist/formats").${o}`);for(let a of t)e.addFormat(a,n[a])}Jx.exports=ja=Jh;Object.defineProperty(ja,"__esModule",{value:!0});ja.default=Jh});var eg=A((Qh,sw)=>{(function(e,t){"use strict";typeof define=="function"&&define.amd?define("stackframe",[],t):typeof Qh=="object"?sw.exports=t():e.StackFrame=t()})(Qh,function(){"use strict";function e(v){return!isNaN(parseFloat(v))&&isFinite(v)}function t(v){return v.charAt(0).toUpperCase()+v.substring(1)}function n(v){return function(){return this[v]}}var o=["isConstructor","isEval","isNative","isToplevel"],r=["columnNumber","lineNumber"],i=["fileName","functionName","source"],a=["args"],s=["evalOrigin"],c=o.concat(r,i,a,s);function l(v){if(v)for(var g=0;g<c.length;g++)v[c[g]]!==void 0&&this["set"+t(c[g])](v[c[g]])}l.prototype={getArgs:function(){return this.args},setArgs:function(v){if(Object.prototype.toString.call(v)!=="[object Array]")throw new TypeError("Args must be an Array");this.args=v},getEvalOrigin:function(){return this.evalOrigin},setEvalOrigin:function(v){if(v instanceof l)this.evalOrigin=v;else if(v instanceof Object)this.evalOrigin=new l(v);else throw new TypeError("Eval Origin must be an Object or StackFrame")},toString:function(){var v=this.getFileName()||"",g=this.getLineNumber()||"",b=this.getColumnNumber()||"",x=this.getFunctionName()||"";return this.getIsEval()?v?"[eval] ("+v+":"+g+":"+b+")":"[eval]:"+g+":"+b:x?x+" ("+v+":"+g+":"+b+")":v+":"+g+":"+b}},l.fromString=function(g){var b=g.indexOf("("),x=g.lastIndexOf(")"),I=g.substring(0,b),R=g.substring(b+1,x).split(","),O=g.substring(x+1);if(O.indexOf("@")===0)var M=/@(.+?)(?::(\d+))?(?::(\d+))?$/.exec(O,""),V=M[1],Me=M[2],ct=M[3];return new l({functionName:I,args:R||void 0,fileName:V,lineNumber:Me||void 0,columnNumber:ct||void 0})};for(var d=0;d<o.length;d++)l.prototype["get"+t(o[d])]=n(o[d]),l.prototype["set"+t(o[d])]=(function(v){return function(g){this[v]=!!g}})(o[d]);for(var f=0;f<r.length;f++)l.prototype["get"+t(r[f])]=n(r[f]),l.prototype["set"+t(r[f])]=(function(v){return function(g){if(!e(g))throw new TypeError(v+" must be a Number");this[v]=Number(g)}})(r[f]);for(var _=0;_<i.length;_++)l.prototype["get"+t(i[_])]=n(i[_]),l.prototype["set"+t(i[_])]=(function(v){return function(g){this[v]=String(g)}})(i[_]);return l})});var uw=A((tg,cw)=>{(function(e,t){"use strict";typeof define=="function"&&define.amd?define("error-stack-parser",["stackframe"],t):typeof tg=="object"?cw.exports=t(eg()):e.ErrorStackParser=t(e.StackFrame)})(tg,function(t){"use strict";var n=/(^|@)\S+:\d+/,o=/^\s*at .*(\S+:\d+|\(native\))/m,r=/^(eval@)?(\[native code])?$/;return{parse:function(a){if(typeof a.stacktrace<"u"||typeof a["opera#sourceloc"]<"u")return this.parseOpera(a);if(a.stack&&a.stack.match(o))return this.parseV8OrIE(a);if(a.stack)return this.parseFFOrSafari(a);throw new Error("Cannot parse given Error object")},extractLocation:function(a){if(a.indexOf(":")===-1)return[a];var s=/(.+?)(?::(\d+))?(?::(\d+))?$/,c=s.exec(a.replace(/[()]/g,""));return[c[1],c[2]||void 0,c[3]||void 0]},parseV8OrIE:function(a){var s=a.stack.split(`
|
|
12
12
|
`).filter(function(c){return!!c.match(o)},this);return s.map(function(c){c.indexOf("(eval ")>-1&&(c=c.replace(/eval code/g,"eval").replace(/(\(eval at [^()]*)|(,.*$)/g,""));var l=c.replace(/^\s+/,"").replace(/\(eval code/g,"(").replace(/^.*?\s+/,""),d=l.match(/ (\(.+\)$)/);l=d?l.replace(d[0],""):l;var f=this.extractLocation(d?d[1]:l),_=d&&l||void 0,v=["eval","<anonymous>"].indexOf(f[0])>-1?void 0:f[0];return new t({functionName:_,fileName:v,lineNumber:f[1],columnNumber:f[2],source:c})},this)},parseFFOrSafari:function(a){var s=a.stack.split(`
|
|
13
13
|
`).filter(function(c){return!c.match(r)},this);return s.map(function(c){if(c.indexOf(" > eval")>-1&&(c=c.replace(/ line (\d+)(?: > eval line \d+)* > eval:\d+:\d+/g,":$1")),c.indexOf("@")===-1&&c.indexOf(":")===-1)return new t({functionName:c});var l=/((.*".+"[^@]*)?[^@]*)(?:@)/,d=c.match(l),f=d&&d[1]?d[1]:void 0,_=this.extractLocation(c.replace(l,""));return new t({functionName:f,fileName:_[0],lineNumber:_[1],columnNumber:_[2],source:c})},this)},parseOpera:function(a){return!a.stacktrace||a.message.indexOf(`
|
|
14
14
|
`)>-1&&a.message.split(`
|
|
@@ -16,25 +16,25 @@
|
|
|
16
16
|
`).length?this.parseOpera9(a):a.stack?this.parseOpera11(a):this.parseOpera10(a)},parseOpera9:function(a){for(var s=/Line (\d+).*script (?:in )?(\S+)/i,c=a.message.split(`
|
|
17
17
|
`),l=[],d=2,f=c.length;d<f;d+=2){var _=s.exec(c[d]);_&&l.push(new t({fileName:_[2],lineNumber:_[1],source:c[d]}))}return l},parseOpera10:function(a){for(var s=/Line (\d+).*script (?:in )?(\S+)(?:: In function (\S+))?$/i,c=a.stacktrace.split(`
|
|
18
18
|
`),l=[],d=0,f=c.length;d<f;d+=2){var _=s.exec(c[d]);_&&l.push(new t({functionName:_[3]||void 0,fileName:_[2],lineNumber:_[1],source:c[d]}))}return l},parseOpera11:function(a){var s=a.stack.split(`
|
|
19
|
-
`).filter(function(c){return!!c.match(n)&&!c.match(/^Error created at/)},this);return s.map(function(c){var l=c.split("@"),d=this.extractLocation(l.pop()),f=l.shift()||"",_=f.replace(/<anonymous function(: (\w+))?>/,"$2").replace(/\([^)]*\)/g,"")||void 0,v;f.match(/\(([^)]*)\)/)&&(v=f.replace(/^[^(]+\(([^)]*)\)$/,"$1"));var g=v===void 0||v==="[arguments not available]"?void 0:v.split(",");return new t({functionName:_,args:g,fileName:d[0],lineNumber:d[1],columnNumber:d[2],source:c})},this)}}})});var
|
|
20
|
-
`&&o.shift(),this._lineBuffer.length>0&&(this._lineBuffer[this._lineBuffer.length-1]+=o[0],o.shift()),this._lastChunkEndedWithCR=e[e.length-1]=="\r",this._lineBuffer=this._lineBuffer.concat(o),this._pushBuffer(t,1,n)};Mr.prototype._pushBuffer=function(e,t,n){for(;this._lineBuffer.length>t;){var o=this._lineBuffer.shift();if((this._keepEmptyLines||o.length>0)&&!this.push(this._reencode(o,e))){var r=this;t4.setImmediate(function(){r._pushBuffer(e,t,n)});return}}n()};Mr.prototype._flush=function(e){this._pushBuffer(this._chunkEncoding,0,e)};Mr.prototype._reencode=function(e,t){return this.encoding&&this.encoding!=t?new Buffer(e,t).toString(this.encoding):this.encoding?e:new Buffer(e,t)}});var Sw=A((kw,og)=>{(function(e){if(typeof kw=="object"&&typeof og<"u")og.exports=e();else if(typeof define=="function"&&define.amd)define([],e);else{var t;typeof window<"u"?t=window:typeof global<"u"?t=global:typeof self<"u"?t=self:t=this,t.bugsnag=e()}})(function(){var e,t,n,o=(function(){function u(h,p,y,w){w===void 0&&(w=new Date),this.type=y,this.message=h,this.metadata=p,this.timestamp=w}var m=u.prototype;return m.toJSON=function(){return{type:this.type,name:this.message,timestamp:this.timestamp,metaData:this.metadata}},u})(),r=o,i=["navigation","request","process","log","user","state","error","manual"],a=function(u,m,h){for(var p=h,y=0,w=u.length;y<w;y++)p=m(p,u[y],y,u);return p},s=function(u,m){return a(u,function(h,p,y,w){return m(p,y,w)?h.concat(p):h},[])},c=function(u,m){return a(u,function(h,p,y,w){return h===!0||p===m},!1)},l=function(u){return Object.prototype.toString.call(u)==="[object Array]"},d=!{toString:null}.propertyIsEnumerable("toString"),f=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],_=function(u){var m=[],h;for(h in u)Object.prototype.hasOwnProperty.call(u,h)&&m.push(h);if(!d)return m;for(var p=0,y=f.length;p<y;p++)Object.prototype.hasOwnProperty.call(u,f[p])&&m.push(f[p]);return m},v=function(u,m){return u===void 0&&(u=1),m===void 0&&(m=1/0),function(h){return typeof h=="number"&&parseInt(""+h,10)===h&&h>=u&&h<=m}},g=function(u){return typeof u=="function"||l(u)&&s(u,function(m){return typeof m=="function"}).length===u.length},b=function(u){return typeof u=="string"&&!!u.length},x={},I=function(){return{unhandledExceptions:!0,unhandledRejections:!0}};x.schema={apiKey:{defaultValue:function(){return null},message:"is required",validate:b},appVersion:{defaultValue:function(){},message:"should be a string",validate:function(u){return u===void 0||b(u)}},appType:{defaultValue:function(){},message:"should be a string",validate:function(u){return u===void 0||b(u)}},autoDetectErrors:{defaultValue:function(){return!0},message:"should be true|false",validate:function(u){return u===!0||u===!1}},enabledErrorTypes:{defaultValue:function(){return I()},message:"should be an object containing the flags { unhandledExceptions:true|false, unhandledRejections:true|false }",allowPartialObject:!0,validate:function(u){if(typeof u!="object"||!u)return!1;var m=_(u),h=_(I());return!(s(m,function(p){return c(h,p)}).length<m.length||s(_(u),function(p){return typeof u[p]!="boolean"}).length>0)}},onError:{defaultValue:function(){return[]},message:"should be a function or array of functions",validate:g},onSession:{defaultValue:function(){return[]},message:"should be a function or array of functions",validate:g},onBreadcrumb:{defaultValue:function(){return[]},message:"should be a function or array of functions",validate:g},endpoints:{defaultValue:function(u){return typeof u>"u"?{notify:"https://notify.bugsnag.com",sessions:"https://sessions.bugsnag.com"}:{notify:null,sessions:null}},message:"should be an object containing endpoint URLs { notify, sessions }",validate:function(u){return u&&typeof u=="object"&&b(u.notify)&&b(u.sessions)&&s(_(u),function(m){return!c(["notify","sessions"],m)}).length===0}},autoTrackSessions:{defaultValue:function(u){return!0},message:"should be true|false",validate:function(u){return u===!0||u===!1}},enabledReleaseStages:{defaultValue:function(){return null},message:"should be an array of strings",validate:function(u){return u===null||l(u)&&s(u,function(m){return typeof m=="string"}).length===u.length}},releaseStage:{defaultValue:function(){return"production"},message:"should be a string",validate:function(u){return typeof u=="string"&&u.length}},maxBreadcrumbs:{defaultValue:function(){return 25},message:"should be a number \u2264100",validate:function(u){return v(0,100)(u)}},enabledBreadcrumbTypes:{defaultValue:function(){return i},message:"should be null or a list of available breadcrumb types ("+i.join(",")+")",validate:function(u){return u===null||l(u)&&a(u,function(m,h){return m===!1?m:c(i,h)},!0)}},context:{defaultValue:function(){},message:"should be a string",validate:function(u){return u===void 0||typeof u=="string"}},user:{defaultValue:function(){return{}},message:"should be an object with { id, email, name } properties",validate:function(u){return u===null||u&&a(_(u),function(m,h){return m&&c(["id","email","name"],h)},!0)}},metadata:{defaultValue:function(){return{}},message:"should be an object",validate:function(u){return typeof u=="object"&&u!==null}},logger:{defaultValue:function(){},message:"should be null or an object with methods { debug, info, warn, error }",validate:function(u){return!u||u&&a(["debug","info","warn","error"],function(m,h){return m&&typeof u[h]=="function"},!0)}},redactedKeys:{defaultValue:function(){return["password"]},message:"should be an array of strings|regexes",validate:function(u){return l(u)&&u.length===s(u,function(m){return typeof m=="string"||m&&typeof m.test=="function"}).length}},plugins:{defaultValue:function(){return[]},message:"should be an array of plugin objects",validate:function(u){return l(u)&&u.length===s(u,function(m){return m&&typeof m=="object"&&typeof m.load=="function"}).length}},featureFlags:{defaultValue:function(){return[]},message:'should be an array of objects that have a "name" property',validate:function(u){return l(u)&&u.length===s(u,function(m){return m&&typeof m=="object"&&typeof m.name=="string"}).length}},reportUnhandledPromiseRejectionsAsHandled:{defaultValue:function(){return!1},message:"should be true|false",validate:function(u){return u===!0||u===!1}},sendPayloadChecksums:{defaultValue:function(){return!1},message:"should be true|false",validate:function(u){return u===!0||u===!1}}};var R=aw(),P=function(u){for(var m=1;m<arguments.length;m++){var h=arguments[m];for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(u[p]=h[p])}return u},M=function(u,m){return a(u,function(h,p,y,w){return h.concat(m(p,y,w))},[])},V=function(u,m,h,p){var y=p&&p.redactedKeys?p.redactedKeys:[],w=p&&p.redactedPaths?p.redactedPaths:[];return JSON.stringify(ek(u,y,w),m,h)},Me=20,ct=25e3,Ao=8,ur="...";function Lr(u){return u instanceof Error||/^\[object (Error|(Dom)?Exception)\]$/.test(Object.prototype.toString.call(u))}function mn(u){return"[Throws: "+(u?u.message:"?")+"]"}function Ca(u,m){for(var h=0,p=u.length;h<p;h++)if(u[h]===m)return!0;return!1}function Ua(u,m){for(var h=0,p=u.length;h<p;h++)if(m.indexOf(u[h])===0)return!0;return!1}function rd(u,m){for(var h=0,p=u.length;h<p;h++)if(typeof u[h]=="string"&&u[h].toLowerCase()===m.toLowerCase()||u[h]&&typeof u[h].test=="function"&&u[h].test(m))return!0;return!1}function Yw(u){return Object.prototype.toString.call(u)==="[object Array]"}function Qw(u,m){try{return u[m]}catch(h){return mn(h)}}function ek(u,m,h){var p=[],y=0;function w(z,D){function L(){return D.length>Ao&&y>ct}if(y++,D.length>Me||L())return ur;if(z===null||typeof z!="object")return z;if(Ca(p,z))return"[Circular]";if(p.push(z),typeof z.toJSON=="function")try{y--;var Q=w(z.toJSON(),D);return p.pop(),Q}catch(_n){return mn(_n)}var de=Lr(z);if(de){y--;var Re=w({name:z.name,message:z.message},D);return p.pop(),Re}if(Yw(z)){for(var Le=[],fr=0,St=z.length;fr<St;fr++){if(L()){Le.push(ur);break}Le.push(w(z[fr],D.concat("[]")))}return p.pop(),Le}var vn={};try{for(var Gt in z)if(Object.prototype.hasOwnProperty.call(z,Gt)){if(Ua(h,D.join("."))&&rd(m,Gt)){vn[Gt]="[REDACTED]";continue}if(L()){vn[Gt]=ur;break}vn[Gt]=w(Qw(z,Gt),D.concat(Gt))}}catch{}return p.pop(),vn}return w(u,[])}function pg(u,m,h,p){if(typeof h=="string"){p===void 0?p=null:p!==null&&typeof p!="string"&&(p=V(p));var y=m[h];if(typeof y=="number"){u[y]={name:h,variant:p};return}u.push({name:h,variant:p}),m[h]=u.length-1}}function tk(u,m,h){if(l(m)){for(var p=0;p<m.length;++p){var y=m[p];y===null||typeof y!="object"||pg(u,h,y.name,y.variant)}return u}}function rk(u){return M(s(u,Boolean),function(m){var h=m.name,p=m.variant,y={featureFlag:h};return typeof p=="string"&&(y.variant=p),y})}function nk(u,m,h){var p=m[h];typeof p=="number"&&(u[p]=null,delete m[h])}var qr={add:pg,clear:nk,merge:tk,toEventApi:rk},Za=function(u){return!!u&&(!!u.stack||!!u.stacktrace||!!u["opera#sourceloc"])&&typeof(u.stack||u.stacktrace||u["opera#sourceloc"])=="string"&&u.stack!==u.name+": "+u.message},nd=cw(),ok=function(u,m,h,p){var y;if(m){var w;if(h===null)return mg(u,m);typeof h=="object"&&(w=h),typeof h=="string"&&(w=(y={},y[h]=p,y)),w&&(m==="__proto__"||m==="constructor"||m==="prototype"||(u[m]||(u[m]={}),u[m]=P({},u[m],w)))}},ik=function(u,m,h){if(typeof m=="string"){if(!h)return u[m];if(u[m])return u[m][h]}},mg=function(u,m,h){if(typeof m=="string"){if(!h){delete u[m];return}m==="__proto__"||m==="constructor"||m==="prototype"||u[m]&&delete u[m][h]}},hn={add:ok,get:ik,clear:mg};function od(){return od=Object.assign?Object.assign.bind():function(u){for(var m=1;m<arguments.length;m++){var h=arguments[m];for(var p in h)({}).hasOwnProperty.call(h,p)&&(u[p]=h[p])}return u},od.apply(null,arguments)}var ak=lw(),lr=(function(){function u(h,p,y,w,z){y===void 0&&(y=[]),w===void 0&&(w=uk()),this.apiKey=void 0,this.context=void 0,this.groupingHash=void 0,this.originalError=z,this._handledState=w,this.severity=this._handledState.severity,this.unhandled=this._handledState.unhandled,this.app={},this.device={},this.request={},this.response={},this.breadcrumbs=[],this.threads=[],this._metadata={},this._features=[],this._featuresIndex={},this._user={},this._session=void 0,this._correlation=void 0,this._groupingDiscriminator=void 0,this.errors=[gg(h,p,u.__type,y)]}var m=u.prototype;return m.addMetadata=function(p,y,w){return hn.add(this._metadata,p,y,w)},m.setTraceCorrelation=function(p,y){typeof p=="string"&&(this._correlation=od({traceId:p},typeof y=="string"?{spanId:y}:{}))},m.getGroupingDiscriminator=function(){return this._groupingDiscriminator},m.setGroupingDiscriminator=function(p){var y=this._groupingDiscriminator;return(typeof p=="string"||p===null||p===void 0)&&(this._groupingDiscriminator=p),y},m.getMetadata=function(p,y){return hn.get(this._metadata,p,y)},m.clearMetadata=function(p,y){return hn.clear(this._metadata,p,y)},m.addFeatureFlag=function(p,y){y===void 0&&(y=null),qr.add(this._features,this._featuresIndex,p,y)},m.addFeatureFlags=function(p){qr.merge(this._features,p,this._featuresIndex)},m.getFeatureFlags=function(){return qr.toEventApi(this._features)},m.clearFeatureFlag=function(p){qr.clear(this._features,this._featuresIndex,p)},m.clearFeatureFlags=function(){this._features=[],this._featuresIndex={}},m.getUser=function(){return this._user},m.setUser=function(p,y,w){this._user={id:p,email:y,name:w}},m.toJSON=function(){return{payloadVersion:"4",exceptions:M(this.errors,function(p){return P({},p,{message:p.errorMessage})}),severity:this.severity,unhandled:this._handledState.unhandled,severityReason:this._handledState.severityReason,app:this.app,device:this.device,request:this.request,response:this.response,breadcrumbs:this.breadcrumbs,context:this.context,groupingHash:this.groupingHash,groupingDiscriminator:this._groupingDiscriminator,metaData:this._metadata,user:this._user,session:this._session,featureFlags:this.getFeatureFlags(),correlation:this._correlation}},u})(),sk=function(u){var m={file:u.fileName,method:ck(u.functionName),lineNumber:u.lineNumber,columnNumber:u.columnNumber,code:void 0,inProject:void 0};return m.lineNumber>-1&&!m.file&&!m.method&&(m.file="global code"),m},ck=function(u){return/^global code$/i.test(u)?"global code":u},uk=function(){return{unhandled:!1,severity:"warning",severityReason:{type:"handledException"}}},hg=function(u){return typeof u=="string"?u:""};function gg(u,m,h,p){return{errorClass:hg(u),errorMessage:hg(m),type:h,stacktrace:a(p,function(y,w){var z=sk(w);try{return JSON.stringify(z)==="{}"?y:y.concat(z)}catch{return y}},[])}}function vg(u){return u.cause?[u].concat(vg(u.cause)):[u]}lr.getStacktrace=function(u,m,h){if(Za(u))return R.parse(u).slice(m);try{return s(ak.backtrace(),function(p){return(p.functionName||"").indexOf("StackGenerator$$")===-1}).slice(1+h)}catch{return[]}},lr.create=function(u,m,h,p,y,w){y===void 0&&(y=0);var z=yg(u,m,p,w),D=z[0],L=z[1],Q;try{var de=lr.getStacktrace(D,L>0?1+L+y:0,1+y);Q=new lr(D.name,D.message,de,h,u)}catch{Q=new lr(D.name,D.message,[],h,u)}if(D.name==="InvalidError"&&Q.addMetadata(""+p,"non-error parameter",_g(u)),D.cause){var Re,Le=vg(D).slice(1),fr=M(Le,function(St){var vn=nd(St)&&Za(St)?R.parse(St):[],Gt=yg(St,!0,"error cause"),_n=Gt[0];return _n.name==="InvalidError"&&Q.addMetadata("error cause",_g(St)),gg(_n.name,_n.message,lr.__type,vn)});(Re=Q.errors).push.apply(Re,fr)}return Q};var _g=function(u){return u===null?"null":u===void 0?"undefined":u},yg=function(u,m,h,p){var y,w=0,z=function(D){var L=h==="error cause"?"was":"received";p&&p.warn(h+" "+L+' a non-error: "'+D+'"');var Q=new Error(h+" "+L+' a non-error. See "'+h+'" tab for more detail.');return Q.name="InvalidError",Q};if(!m)nd(u)?y=u:(y=z(typeof u),w+=2);else switch(typeof u){case"string":case"number":case"boolean":y=new Error(String(u)),w+=1;break;case"function":y=z("function"),w+=2;break;case"object":u!==null&&nd(u)?y=u:u!==null&&lk(u)?(y=new Error(u.message||u.errorMessage),y.name=u.name||u.errorClass,w+=1):(y=z(u===null?"null":"unsupported object"),w+=2);break;default:y=z("nothing"),w+=2}if(!Za(y))try{throw y}catch(D){Za(D)&&(y=D,w=1)}return[y,w]};lr.__type="browserjs";var lk=function(u){return(typeof u.name=="string"||typeof u.errorClass=="string")&&(typeof u.message=="string"||typeof u.errorMessage=="string")},Ma=lr,dk=function(u,m,h){var p=0,y=function(){if(p>=u.length)return h(null,!0);m(u[p],function(w,z){if(w)return h(w);if(z===!1)return h(null,!1);p++,y()})};y()},fk=function(u,m,h,p){var y=function(w,z){if(typeof w!="function")return z(null);try{if(w.length!==2){var D=w(m);return D&&typeof D.then=="function"?D.then(function(L){return setTimeout(function(){return z(null,L)})},function(L){setTimeout(function(){return h(L),z(null,!0)})}):z(null,D)}w(m,function(L,Q){if(L)return h(L),z(null);z(null,Q)})}catch(L){h(L),z(null)}};dk(u,y,p)},id=function(u,m,h,p){for(var y=!1,w=u.slice();!y&&w.length;)try{y=w.pop()(m)===!1}catch(z){p.error("Error occurred in "+h+" callback, continuing anyway\u2026"),p.error(z)}return y},La=function(m,h){var p="000000000"+m;return p.substr(p.length-h)},pk=require("os");function mk(){try{return pk.hostname()}catch{return process.env._CLUSTER_NETWORK_NAME_||process.env.COMPUTERNAME||"hostname"}}var bg=2,hk=La(process.pid.toString(36),bg),$g=mk(),gk=$g.length,vk=La($g.split("").reduce(function(u,m){return+u+m.charCodeAt(0)},+gk+36).toString(36),bg),xg=function(){return hk+vk},_k=function(m){return typeof m=="string"&&/^c[a-z0-9]{20,32}$/.test(m)},Do=0,ad=4,qa=36,wg=Math.pow(qa,ad);function kg(){return La((Math.random()*wg<<0).toString(qa),ad)}function yk(){return Do=Do<wg?Do:0,Do++,Do-1}function sd(){var u="c",m=new Date().getTime().toString(qa),h=La(yk().toString(qa),ad),p=xg(),y=kg()+kg();return u+m+h+p+y}sd.fingerprint=xg,sd.isCuid=_k;var bk=sd,$k=(function(){function u(){this.id=bk(),this.startedAt=new Date,this._handled=0,this._unhandled=0,this._user={},this.app={},this.device={}}var m=u.prototype;return m.getUser=function(){return this._user},m.setUser=function(p,y,w){this._user={id:p,email:y,name:w}},m.toJSON=function(){return{id:this.id,startedAt:this.startedAt,events:{handled:this._handled,unhandled:this._unhandled}}},m._track=function(p){this[p._handledState.unhandled?"_unhandled":"_handled"]+=1},u})(),cd=$k,xk=qr.add,wk=qr.clear,ud=qr.merge,kk="00000",Sk="https://notify.bugsnag.smartbear.com",zk="https://sessions.bugsnag.smartbear.com",dr=function(){},Ik=(function(){function u(h,p,y,w){var z=this;p===void 0&&(p=x.schema),y===void 0&&(y=[]),this._notifier=w,this._config={},this._schema=p,this._delivery={sendSession:dr,sendEvent:dr},this._logger={debug:dr,info:dr,warn:dr,error:dr},this._plugins={},this._breadcrumbs=[],this._session=null,this._metadata={},this._featuresIndex={},this._features=[],this._context=void 0,this._user={},this._groupingDiscriminator=void 0,this._cbs={e:[],s:[],sp:[],b:[]},this.Client=u,this.Event=Ma,this.Breadcrumb=r,this.Session=cd,this._config=this._configure(h,y),M(y.concat(this._config.plugins),function(Q){Q&&z._loadPlugin(Q)}),this._depth=1;var D=this,L=this.notify;this.notify=function(){return L.apply(D,arguments)}}var m=u.prototype;return m.addMetadata=function(p,y,w){return hn.add(this._metadata,p,y,w)},m.getMetadata=function(p,y){return hn.get(this._metadata,p,y)},m.clearMetadata=function(p,y){return hn.clear(this._metadata,p,y)},m.addFeatureFlag=function(p,y){y===void 0&&(y=null),xk(this._features,this._featuresIndex,p,y)},m.addFeatureFlags=function(p){ud(this._features,p,this._featuresIndex)},m.clearFeatureFlag=function(p){wk(this._features,this._featuresIndex,p)},m.clearFeatureFlags=function(){this._features=[],this._featuresIndex={}},m.getContext=function(){return this._context},m.setContext=function(p){this._context=p},m.getGroupingDiscriminator=function(){return this._groupingDiscriminator},m.setGroupingDiscriminator=function(p){var y=this._groupingDiscriminator;return(typeof p=="string"||p===null||p===void 0)&&(this._groupingDiscriminator=p),y},m._configure=function(p,y){var w=a(y,function(Q,de){return de&&de.configSchema?P({},Q,de.configSchema):Q},this._schema);p.endpoints||(p.sendPayloadChecksums="sendPayloadChecksums"in p?p.sendPayloadChecksums:!0);var z=a(_(w),function(Q,de){var Re=w[de].defaultValue(p[de]);if(p[de]!==void 0){var Le=w[de].validate(p[de]);Le?w[de].allowPartialObject?Q.config[de]=P(Re,p[de]):Q.config[de]=p[de]:(Q.errors[de]=w[de].message,Q.config[de]=Re)}else Q.config[de]=Re;return Q},{errors:{},config:{}}),D=z.errors,L=z.config;if(w.apiKey){if(!L.apiKey)throw new Error("No Bugsnag API Key set");/^[0-9a-f]{32}$/i.test(L.apiKey)||(D.apiKey="should be a string of 32 hexadecimal characters"),p.endpoints===void 0&&L.apiKey.indexOf(kk)===0&&(L.endpoints={notify:Sk,sessions:zk})}return this._metadata=P({},L.metadata),ud(this._features,L.featureFlags,this._featuresIndex),this._user=P({},L.user),this._context=L.context,L.logger&&(this._logger=L.logger),L.onError&&(this._cbs.e=this._cbs.e.concat(L.onError)),L.onBreadcrumb&&(this._cbs.b=this._cbs.b.concat(L.onBreadcrumb)),L.onSession&&(this._cbs.s=this._cbs.s.concat(L.onSession)),_(D).length&&this._logger.warn(Ek(D,p)),L},m.getUser=function(){return this._user},m.setUser=function(p,y,w){this._user={id:p,email:y,name:w}},m._loadPlugin=function(p){var y=p.load(this);p.name&&(this._plugins["~"+p.name+"~"]=y)},m.getPlugin=function(p){return this._plugins["~"+p+"~"]},m._setDelivery=function(p){this._delivery=p(this)},m.startSession=function(){var p=new cd;p.app.releaseStage=this._config.releaseStage,p.app.version=this._config.appVersion,p.app.type=this._config.appType,p._user=P({},this._user);var y=id(this._cbs.s,p,"onSession",this._logger);return y?(this._logger.debug("Session not started due to onSession callback"),this):this._sessionDelegate.startSession(this,p)},m.addOnError=function(p,y){y===void 0&&(y=!1),this._cbs.e[y?"unshift":"push"](p)},m.removeOnError=function(p){this._cbs.e=s(this._cbs.e,function(y){return y!==p})},m._addOnSessionPayload=function(p){this._cbs.sp.push(p)},m.addOnSession=function(p){this._cbs.s.push(p)},m.removeOnSession=function(p){this._cbs.s=s(this._cbs.s,function(y){return y!==p})},m.addOnBreadcrumb=function(p,y){y===void 0&&(y=!1),this._cbs.b[y?"unshift":"push"](p)},m.removeOnBreadcrumb=function(p){this._cbs.b=s(this._cbs.b,function(y){return y!==p})},m.pauseSession=function(){return this._sessionDelegate.pauseSession(this)},m.resumeSession=function(){return this._sessionDelegate.resumeSession(this)},m.leaveBreadcrumb=function(p,y,w){if(p=typeof p=="string"?p:"",w=typeof w=="string"&&c(i,w)?w:"manual",y=typeof y=="object"&&y!==null?y:{},!!p){var z=new r(p,y,w),D=id(this._cbs.b,z,"onBreadcrumb",this._logger);if(D){this._logger.debug("Breadcrumb not attached due to onBreadcrumb callback");return}this._breadcrumbs.push(z),this._breadcrumbs.length>this._config.maxBreadcrumbs&&(this._breadcrumbs=this._breadcrumbs.slice(this._breadcrumbs.length-this._config.maxBreadcrumbs))}},m._isBreadcrumbTypeEnabled=function(p){var y=this._config.enabledBreadcrumbTypes;return y===null||c(y,p)},m.notify=function(p,y,w){w===void 0&&(w=dr);var z=Ma.create(p,!0,void 0,"notify()",this._depth+1,this._logger);this._notify(z,y,w)},m._notify=function(p,y,w){var z=this;if(w===void 0&&(w=dr),p.app=P({},p.app,{releaseStage:this._config.releaseStage,version:this._config.appVersion,type:this._config.appType}),p.context=p.context||this._context,p._metadata=P({},p._metadata,this._metadata),p._user=P({},p._user,this._user),p.breadcrumbs=this._breadcrumbs.slice(),p.setGroupingDiscriminator(this._groupingDiscriminator),ud(p._features,this._features,p._featuresIndex),this._config.enabledReleaseStages!==null&&!c(this._config.enabledReleaseStages,this._config.releaseStage))return this._logger.warn("Event not sent due to releaseStage/enabledReleaseStages configuration"),w(null,p);var D=p.severity,L=function(de){z._logger.error("Error occurred in onError callback, continuing anyway\u2026"),z._logger.error(de)},Q=[].concat(this._cbs.e).concat(y);fk(Q,p,L,function(de,Re){if(de&&L(de),!Re)return z._logger.debug("Event not sent due to onError callback"),w(null,p);z._isBreadcrumbTypeEnabled("error")&&u.prototype.leaveBreadcrumb.call(z,p.errors[0].errorClass,{errorClass:p.errors[0].errorClass,errorMessage:p.errors[0].errorMessage,severity:p.severity},"error"),D!==p.severity&&(p._handledState.severityReason={type:"userCallbackSetSeverity"}),p.unhandled!==p._handledState.unhandled&&(p._handledState.severityReason.unhandledOverridden=!0,p._handledState.unhandled=p.unhandled),z._session&&(z._session._track(p),p._session=z._session),z._delivery.sendEvent({apiKey:p.apiKey||z._config.apiKey,notifier:z._notifier,events:[p]},function(Le){return w(Le,p)})})},u})(),Ek=function(u,m){var h=new Error(`Invalid configuration
|
|
21
|
-
`+M(_(u),function(p){return" - "+p+" "+u[p]+", got "+
|
|
19
|
+
`).filter(function(c){return!!c.match(n)&&!c.match(/^Error created at/)},this);return s.map(function(c){var l=c.split("@"),d=this.extractLocation(l.pop()),f=l.shift()||"",_=f.replace(/<anonymous function(: (\w+))?>/,"$2").replace(/\([^)]*\)/g,"")||void 0,v;f.match(/\(([^)]*)\)/)&&(v=f.replace(/^[^(]+\(([^)]*)\)$/,"$1"));var g=v===void 0||v==="[arguments not available]"?void 0:v.split(",");return new t({functionName:_,args:g,fileName:d[0],lineNumber:d[1],columnNumber:d[2],source:c})},this)}}})});var dw=A(($9,lw)=>{lw.exports=JA;function JA(e){switch(Object.prototype.toString.call(e)){case"[object Error]":return!0;case"[object Exception]":return!0;case"[object DOMException]":return!0;default:return e instanceof Error}}});var pw=A((rg,fw)=>{(function(e,t){"use strict";typeof define=="function"&&define.amd?define("stack-generator",["stackframe"],t):typeof rg=="object"?fw.exports=t(eg()):e.StackGenerator=t(e.StackFrame)})(rg,function(e){return{backtrace:function(n){var o=[],r=10;typeof n=="object"&&typeof n.maxStackSize=="number"&&(r=n.maxStackSize);for(var i=arguments.callee;i&&o.length<r&&i.arguments;){for(var a=new Array(i.arguments.length),s=0;s<a.length;++s)a[s]=i.arguments[s];/function(?:\s+([\w$]+))+\s*\(/.test(i.toString())?o.push(new e({functionName:RegExp.$1||void 0,args:a})):o.push(new e({args:a}));try{i=i.caller}catch{break}}return o}}})});var gw=A((x9,hw)=>{hw.exports=mw;function mw(e,t){if(e&&t)return mw(e)(t);if(typeof e!="function")throw new TypeError("need wrapper function");return Object.keys(e).forEach(function(o){n[o]=e[o]}),n;function n(){for(var o=new Array(arguments.length),r=0;r<o.length;r++)o[r]=arguments[r];var i=e.apply(this,o),a=o[o.length-1];return typeof i=="function"&&i!==a&&Object.keys(a).forEach(function(s){i[s]=a[s]}),i}}});var og=A((w9,ng)=>{var vw=gw();ng.exports=vw(Gl);ng.exports.strict=vw(_w);Gl.proto=Gl(function(){Object.defineProperty(Function.prototype,"once",{value:function(){return Gl(this)},configurable:!0}),Object.defineProperty(Function.prototype,"onceStrict",{value:function(){return _w(this)},configurable:!0})});function Gl(e){var t=function(){return t.called?t.value:(t.called=!0,t.value=e.apply(this,arguments))};return t.called=!1,t}function _w(e){var t=function(){if(t.called)throw new Error(t.onceError);return t.called=!0,t.value=e.apply(this,arguments)},n=e.name||"Function wrapped with `once`";return t.onceError=n+" shouldn't be called more than once",t.called=!1,t}});var $w=A((k9,bw)=>{var GA=og(),WA=function(){},XA=global.Bare?queueMicrotask:process.nextTick.bind(process),YA=function(e){return e.setHeader&&typeof e.abort=="function"},QA=function(e){return e.stdio&&Array.isArray(e.stdio)&&e.stdio.length===3},yw=function(e,t,n){if(typeof t=="function")return yw(e,null,t);t||(t={}),n=GA(n||WA);var o=e._writableState,r=e._readableState,i=t.readable||t.readable!==!1&&e.readable,a=t.writable||t.writable!==!1&&e.writable,s=!1,c=function(){e.writable||l()},l=function(){a=!1,i||n.call(e)},d=function(){i=!1,a||n.call(e)},f=function(x){n.call(e,x?new Error("exited with error code: "+x):null)},_=function(x){n.call(e,x)},v=function(){XA(g)},g=function(){if(!s){if(i&&!(r&&r.ended&&!r.destroyed))return n.call(e,new Error("premature close"));if(a&&!(o&&o.ended&&!o.destroyed))return n.call(e,new Error("premature close"))}},b=function(){e.req.on("finish",l)};return YA(e)?(e.on("complete",l),e.on("abort",v),e.req?b():e.on("request",b)):a&&!o&&(e.on("end",c),e.on("close",c)),QA(e)&&e.on("exit",f),e.on("end",d),e.on("finish",l),t.error!==!1&&e.on("error",_),e.on("close",v),function(){s=!0,e.removeListener("complete",l),e.removeListener("abort",v),e.removeListener("request",b),e.req&&e.req.removeListener("finish",l),e.removeListener("end",c),e.removeListener("close",c),e.removeListener("finish",l),e.removeListener("exit",f),e.removeListener("end",d),e.removeListener("error",_),e.removeListener("close",v)}};bw.exports=yw});var kw=A((S9,ww)=>{var e4=og(),t4=$w(),Wl;try{Wl=require("fs")}catch{}var Ra=function(){},r4=typeof process>"u"?!1:/^v?\.0/.test(process.version),Xl=function(e){return typeof e=="function"},n4=function(e){return!r4||!Wl?!1:(e instanceof(Wl.ReadStream||Ra)||e instanceof(Wl.WriteStream||Ra))&&Xl(e.close)},o4=function(e){return e.setHeader&&Xl(e.abort)},i4=function(e,t,n,o){o=e4(o);var r=!1;e.on("close",function(){r=!0}),t4(e,{readable:t,writable:n},function(a){if(a)return o(a);r=!0,o()});var i=!1;return function(a){if(!r&&!i){if(i=!0,n4(e))return e.close(Ra);if(o4(e))return e.abort();if(Xl(e.destroy))return e.destroy();o(a||new Error("stream was destroyed"))}}},xw=function(e){e()},a4=function(e,t){return e.pipe(t)},s4=function(){var e=Array.prototype.slice.call(arguments),t=Xl(e[e.length-1]||Ra)&&e.pop()||Ra;if(Array.isArray(e[0])&&(e=e[0]),e.length<2)throw new Error("pump requires two streams per minimum");var n,o=e.map(function(r,i){var a=i<e.length-1,s=i>0;return i4(r,a,s,function(c){n||(n=c),c&&o.forEach(xw),!a&&(o.forEach(xw),t(n))})});return e.reduce(a4)};ww.exports=s4});var zw=A((z9,Ro)=>{var ig=require("stream"),c4=require("util"),u4=require("timers");Ro.exports=function(e,t){return Ro.exports.createStream(e,t)};Ro.exports.createStream=function(e,t){return e?Sw(e,t):new Mr(t)};Ro.exports.createLineStream=function(e){return console.log("WARNING: byline#createLineStream is deprecated and will be removed soon"),Sw(e)};function Sw(e,t){if(!e)throw new Error("expected readStream");if(!e.readable)throw new Error("readStream must be readable");var n=new Mr(t);return e.pipe(n),n}Ro.exports.LineStream=Mr;function Mr(e){ig.Transform.call(this,e),e=e||{},this._readableState.objectMode=!0,this._lineBuffer=[],this._keepEmptyLines=e.keepEmptyLines||!1,this._lastChunkEndedWithCR=!1;var t=this;this.on("pipe",function(n){t.encoding||n instanceof ig.Readable&&(t.encoding=n._readableState.encoding)})}c4.inherits(Mr,ig.Transform);Mr.prototype._transform=function(e,t,n){t=t||"utf8",Buffer.isBuffer(e)&&(t=="buffer"?(e=e.toString(),t="utf8"):e=e.toString(t)),this._chunkEncoding=t;var o=e.split(/\r\n|[\n\v\f\r\x85\u2028\u2029]/g);this._lastChunkEndedWithCR&&e[0]==`
|
|
20
|
+
`&&o.shift(),this._lineBuffer.length>0&&(this._lineBuffer[this._lineBuffer.length-1]+=o[0],o.shift()),this._lastChunkEndedWithCR=e[e.length-1]=="\r",this._lineBuffer=this._lineBuffer.concat(o),this._pushBuffer(t,1,n)};Mr.prototype._pushBuffer=function(e,t,n){for(;this._lineBuffer.length>t;){var o=this._lineBuffer.shift();if((this._keepEmptyLines||o.length>0)&&!this.push(this._reencode(o,e))){var r=this;u4.setImmediate(function(){r._pushBuffer(e,t,n)});return}}n()};Mr.prototype._flush=function(e){this._pushBuffer(this._chunkEncoding,0,e)};Mr.prototype._reencode=function(e,t){return this.encoding&&this.encoding!=t?new Buffer(e,t).toString(this.encoding):this.encoding?e:new Buffer(e,t)}});var Ew=A((Iw,ag)=>{(function(e){if(typeof Iw=="object"&&typeof ag<"u")ag.exports=e();else if(typeof define=="function"&&define.amd)define([],e);else{var t;typeof window<"u"?t=window:typeof global<"u"?t=global:typeof self<"u"?t=self:t=this,t.bugsnag=e()}})(function(){var e,t,n,o=(function(){function u(h,p,y,w){w===void 0&&(w=new Date),this.type=y,this.message=h,this.metadata=p,this.timestamp=w}var m=u.prototype;return m.toJSON=function(){return{type:this.type,name:this.message,timestamp:this.timestamp,metaData:this.metadata}},u})(),r=o,i=["navigation","request","process","log","user","state","error","manual"],a=function(u,m,h){for(var p=h,y=0,w=u.length;y<w;y++)p=m(p,u[y],y,u);return p},s=function(u,m){return a(u,function(h,p,y,w){return m(p,y,w)?h.concat(p):h},[])},c=function(u,m){return a(u,function(h,p,y,w){return h===!0||p===m},!1)},l=function(u){return Object.prototype.toString.call(u)==="[object Array]"},d=!{toString:null}.propertyIsEnumerable("toString"),f=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],_=function(u){var m=[],h;for(h in u)Object.prototype.hasOwnProperty.call(u,h)&&m.push(h);if(!d)return m;for(var p=0,y=f.length;p<y;p++)Object.prototype.hasOwnProperty.call(u,f[p])&&m.push(f[p]);return m},v=function(u,m){return u===void 0&&(u=1),m===void 0&&(m=1/0),function(h){return typeof h=="number"&&parseInt(""+h,10)===h&&h>=u&&h<=m}},g=function(u){return typeof u=="function"||l(u)&&s(u,function(m){return typeof m=="function"}).length===u.length},b=function(u){return typeof u=="string"&&!!u.length},x={},I=function(){return{unhandledExceptions:!0,unhandledRejections:!0}};x.schema={apiKey:{defaultValue:function(){return null},message:"is required",validate:b},appVersion:{defaultValue:function(){},message:"should be a string",validate:function(u){return u===void 0||b(u)}},appType:{defaultValue:function(){},message:"should be a string",validate:function(u){return u===void 0||b(u)}},autoDetectErrors:{defaultValue:function(){return!0},message:"should be true|false",validate:function(u){return u===!0||u===!1}},enabledErrorTypes:{defaultValue:function(){return I()},message:"should be an object containing the flags { unhandledExceptions:true|false, unhandledRejections:true|false }",allowPartialObject:!0,validate:function(u){if(typeof u!="object"||!u)return!1;var m=_(u),h=_(I());return!(s(m,function(p){return c(h,p)}).length<m.length||s(_(u),function(p){return typeof u[p]!="boolean"}).length>0)}},onError:{defaultValue:function(){return[]},message:"should be a function or array of functions",validate:g},onSession:{defaultValue:function(){return[]},message:"should be a function or array of functions",validate:g},onBreadcrumb:{defaultValue:function(){return[]},message:"should be a function or array of functions",validate:g},endpoints:{defaultValue:function(u){return typeof u>"u"?{notify:"https://notify.bugsnag.com",sessions:"https://sessions.bugsnag.com"}:{notify:null,sessions:null}},message:"should be an object containing endpoint URLs { notify, sessions }",validate:function(u){return u&&typeof u=="object"&&b(u.notify)&&b(u.sessions)&&s(_(u),function(m){return!c(["notify","sessions"],m)}).length===0}},autoTrackSessions:{defaultValue:function(u){return!0},message:"should be true|false",validate:function(u){return u===!0||u===!1}},enabledReleaseStages:{defaultValue:function(){return null},message:"should be an array of strings",validate:function(u){return u===null||l(u)&&s(u,function(m){return typeof m=="string"}).length===u.length}},releaseStage:{defaultValue:function(){return"production"},message:"should be a string",validate:function(u){return typeof u=="string"&&u.length}},maxBreadcrumbs:{defaultValue:function(){return 25},message:"should be a number \u2264100",validate:function(u){return v(0,100)(u)}},enabledBreadcrumbTypes:{defaultValue:function(){return i},message:"should be null or a list of available breadcrumb types ("+i.join(",")+")",validate:function(u){return u===null||l(u)&&a(u,function(m,h){return m===!1?m:c(i,h)},!0)}},context:{defaultValue:function(){},message:"should be a string",validate:function(u){return u===void 0||typeof u=="string"}},user:{defaultValue:function(){return{}},message:"should be an object with { id, email, name } properties",validate:function(u){return u===null||u&&a(_(u),function(m,h){return m&&c(["id","email","name"],h)},!0)}},metadata:{defaultValue:function(){return{}},message:"should be an object",validate:function(u){return typeof u=="object"&&u!==null}},logger:{defaultValue:function(){},message:"should be null or an object with methods { debug, info, warn, error }",validate:function(u){return!u||u&&a(["debug","info","warn","error"],function(m,h){return m&&typeof u[h]=="function"},!0)}},redactedKeys:{defaultValue:function(){return["password"]},message:"should be an array of strings|regexes",validate:function(u){return l(u)&&u.length===s(u,function(m){return typeof m=="string"||m&&typeof m.test=="function"}).length}},plugins:{defaultValue:function(){return[]},message:"should be an array of plugin objects",validate:function(u){return l(u)&&u.length===s(u,function(m){return m&&typeof m=="object"&&typeof m.load=="function"}).length}},featureFlags:{defaultValue:function(){return[]},message:'should be an array of objects that have a "name" property',validate:function(u){return l(u)&&u.length===s(u,function(m){return m&&typeof m=="object"&&typeof m.name=="string"}).length}},reportUnhandledPromiseRejectionsAsHandled:{defaultValue:function(){return!1},message:"should be true|false",validate:function(u){return u===!0||u===!1}},sendPayloadChecksums:{defaultValue:function(){return!1},message:"should be true|false",validate:function(u){return u===!0||u===!1}}};var R=uw(),O=function(u){for(var m=1;m<arguments.length;m++){var h=arguments[m];for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(u[p]=h[p])}return u},M=function(u,m){return a(u,function(h,p,y,w){return h.concat(m(p,y,w))},[])},V=function(u,m,h,p){var y=p&&p.redactedKeys?p.redactedKeys:[],w=p&&p.redactedPaths?p.redactedPaths:[];return JSON.stringify(ck(u,y,w),m,h)},Me=20,ct=25e3,Ao=8,ur="...";function Lr(u){return u instanceof Error||/^\[object (Error|(Dom)?Exception)\]$/.test(Object.prototype.toString.call(u))}function mn(u){return"[Throws: "+(u?u.message:"?")+"]"}function Ua(u,m){for(var h=0,p=u.length;h<p;h++)if(u[h]===m)return!0;return!1}function Za(u,m){for(var h=0,p=u.length;h<p;h++)if(m.indexOf(u[h])===0)return!0;return!1}function od(u,m){for(var h=0,p=u.length;h<p;h++)if(typeof u[h]=="string"&&u[h].toLowerCase()===m.toLowerCase()||u[h]&&typeof u[h].test=="function"&&u[h].test(m))return!0;return!1}function ak(u){return Object.prototype.toString.call(u)==="[object Array]"}function sk(u,m){try{return u[m]}catch(h){return mn(h)}}function ck(u,m,h){var p=[],y=0;function w(z,D){function L(){return D.length>Ao&&y>ct}if(y++,D.length>Me||L())return ur;if(z===null||typeof z!="object")return z;if(Ua(p,z))return"[Circular]";if(p.push(z),typeof z.toJSON=="function")try{y--;var Q=w(z.toJSON(),D);return p.pop(),Q}catch(_n){return mn(_n)}var de=Lr(z);if(de){y--;var Re=w({name:z.name,message:z.message},D);return p.pop(),Re}if(ak(z)){for(var Le=[],fr=0,St=z.length;fr<St;fr++){if(L()){Le.push(ur);break}Le.push(w(z[fr],D.concat("[]")))}return p.pop(),Le}var vn={};try{for(var Gt in z)if(Object.prototype.hasOwnProperty.call(z,Gt)){if(Za(h,D.join("."))&&od(m,Gt)){vn[Gt]="[REDACTED]";continue}if(L()){vn[Gt]=ur;break}vn[Gt]=w(sk(z,Gt),D.concat(Gt))}}catch{}return p.pop(),vn}return w(u,[])}function gg(u,m,h,p){if(typeof h=="string"){p===void 0?p=null:p!==null&&typeof p!="string"&&(p=V(p));var y=m[h];if(typeof y=="number"){u[y]={name:h,variant:p};return}u.push({name:h,variant:p}),m[h]=u.length-1}}function uk(u,m,h){if(l(m)){for(var p=0;p<m.length;++p){var y=m[p];y===null||typeof y!="object"||gg(u,h,y.name,y.variant)}return u}}function lk(u){return M(s(u,Boolean),function(m){var h=m.name,p=m.variant,y={featureFlag:h};return typeof p=="string"&&(y.variant=p),y})}function dk(u,m,h){var p=m[h];typeof p=="number"&&(u[p]=null,delete m[h])}var qr={add:gg,clear:dk,merge:uk,toEventApi:lk},Ma=function(u){return!!u&&(!!u.stack||!!u.stacktrace||!!u["opera#sourceloc"])&&typeof(u.stack||u.stacktrace||u["opera#sourceloc"])=="string"&&u.stack!==u.name+": "+u.message},id=dw(),fk=function(u,m,h,p){var y;if(m){var w;if(h===null)return vg(u,m);typeof h=="object"&&(w=h),typeof h=="string"&&(w=(y={},y[h]=p,y)),w&&(m==="__proto__"||m==="constructor"||m==="prototype"||(u[m]||(u[m]={}),u[m]=O({},u[m],w)))}},pk=function(u,m,h){if(typeof m=="string"){if(!h)return u[m];if(u[m])return u[m][h]}},vg=function(u,m,h){if(typeof m=="string"){if(!h){delete u[m];return}m==="__proto__"||m==="constructor"||m==="prototype"||u[m]&&delete u[m][h]}},hn={add:fk,get:pk,clear:vg};function ad(){return ad=Object.assign?Object.assign.bind():function(u){for(var m=1;m<arguments.length;m++){var h=arguments[m];for(var p in h)({}).hasOwnProperty.call(h,p)&&(u[p]=h[p])}return u},ad.apply(null,arguments)}var mk=pw(),lr=(function(){function u(h,p,y,w,z){y===void 0&&(y=[]),w===void 0&&(w=vk()),this.apiKey=void 0,this.context=void 0,this.groupingHash=void 0,this.originalError=z,this._handledState=w,this.severity=this._handledState.severity,this.unhandled=this._handledState.unhandled,this.app={},this.device={},this.request={},this.response={},this.breadcrumbs=[],this.threads=[],this._metadata={},this._features=[],this._featuresIndex={},this._user={},this._session=void 0,this._correlation=void 0,this._groupingDiscriminator=void 0,this.errors=[yg(h,p,u.__type,y)]}var m=u.prototype;return m.addMetadata=function(p,y,w){return hn.add(this._metadata,p,y,w)},m.setTraceCorrelation=function(p,y){typeof p=="string"&&(this._correlation=ad({traceId:p},typeof y=="string"?{spanId:y}:{}))},m.getGroupingDiscriminator=function(){return this._groupingDiscriminator},m.setGroupingDiscriminator=function(p){var y=this._groupingDiscriminator;return(typeof p=="string"||p===null||p===void 0)&&(this._groupingDiscriminator=p),y},m.getMetadata=function(p,y){return hn.get(this._metadata,p,y)},m.clearMetadata=function(p,y){return hn.clear(this._metadata,p,y)},m.addFeatureFlag=function(p,y){y===void 0&&(y=null),qr.add(this._features,this._featuresIndex,p,y)},m.addFeatureFlags=function(p){qr.merge(this._features,p,this._featuresIndex)},m.getFeatureFlags=function(){return qr.toEventApi(this._features)},m.clearFeatureFlag=function(p){qr.clear(this._features,this._featuresIndex,p)},m.clearFeatureFlags=function(){this._features=[],this._featuresIndex={}},m.getUser=function(){return this._user},m.setUser=function(p,y,w){this._user={id:p,email:y,name:w}},m.toJSON=function(){return{payloadVersion:"4",exceptions:M(this.errors,function(p){return O({},p,{message:p.errorMessage})}),severity:this.severity,unhandled:this._handledState.unhandled,severityReason:this._handledState.severityReason,app:this.app,device:this.device,request:this.request,response:this.response,breadcrumbs:this.breadcrumbs,context:this.context,groupingHash:this.groupingHash,groupingDiscriminator:this._groupingDiscriminator,metaData:this._metadata,user:this._user,session:this._session,featureFlags:this.getFeatureFlags(),correlation:this._correlation}},u})(),hk=function(u){var m={file:u.fileName,method:gk(u.functionName),lineNumber:u.lineNumber,columnNumber:u.columnNumber,code:void 0,inProject:void 0};return m.lineNumber>-1&&!m.file&&!m.method&&(m.file="global code"),m},gk=function(u){return/^global code$/i.test(u)?"global code":u},vk=function(){return{unhandled:!1,severity:"warning",severityReason:{type:"handledException"}}},_g=function(u){return typeof u=="string"?u:""};function yg(u,m,h,p){return{errorClass:_g(u),errorMessage:_g(m),type:h,stacktrace:a(p,function(y,w){var z=hk(w);try{return JSON.stringify(z)==="{}"?y:y.concat(z)}catch{return y}},[])}}function bg(u){return u.cause?[u].concat(bg(u.cause)):[u]}lr.getStacktrace=function(u,m,h){if(Ma(u))return R.parse(u).slice(m);try{return s(mk.backtrace(),function(p){return(p.functionName||"").indexOf("StackGenerator$$")===-1}).slice(1+h)}catch{return[]}},lr.create=function(u,m,h,p,y,w){y===void 0&&(y=0);var z=xg(u,m,p,w),D=z[0],L=z[1],Q;try{var de=lr.getStacktrace(D,L>0?1+L+y:0,1+y);Q=new lr(D.name,D.message,de,h,u)}catch{Q=new lr(D.name,D.message,[],h,u)}if(D.name==="InvalidError"&&Q.addMetadata(""+p,"non-error parameter",$g(u)),D.cause){var Re,Le=bg(D).slice(1),fr=M(Le,function(St){var vn=id(St)&&Ma(St)?R.parse(St):[],Gt=xg(St,!0,"error cause"),_n=Gt[0];return _n.name==="InvalidError"&&Q.addMetadata("error cause",$g(St)),yg(_n.name,_n.message,lr.__type,vn)});(Re=Q.errors).push.apply(Re,fr)}return Q};var $g=function(u){return u===null?"null":u===void 0?"undefined":u},xg=function(u,m,h,p){var y,w=0,z=function(D){var L=h==="error cause"?"was":"received";p&&p.warn(h+" "+L+' a non-error: "'+D+'"');var Q=new Error(h+" "+L+' a non-error. See "'+h+'" tab for more detail.');return Q.name="InvalidError",Q};if(!m)id(u)?y=u:(y=z(typeof u),w+=2);else switch(typeof u){case"string":case"number":case"boolean":y=new Error(String(u)),w+=1;break;case"function":y=z("function"),w+=2;break;case"object":u!==null&&id(u)?y=u:u!==null&&_k(u)?(y=new Error(u.message||u.errorMessage),y.name=u.name||u.errorClass,w+=1):(y=z(u===null?"null":"unsupported object"),w+=2);break;default:y=z("nothing"),w+=2}if(!Ma(y))try{throw y}catch(D){Ma(D)&&(y=D,w=1)}return[y,w]};lr.__type="browserjs";var _k=function(u){return(typeof u.name=="string"||typeof u.errorClass=="string")&&(typeof u.message=="string"||typeof u.errorMessage=="string")},La=lr,yk=function(u,m,h){var p=0,y=function(){if(p>=u.length)return h(null,!0);m(u[p],function(w,z){if(w)return h(w);if(z===!1)return h(null,!1);p++,y()})};y()},bk=function(u,m,h,p){var y=function(w,z){if(typeof w!="function")return z(null);try{if(w.length!==2){var D=w(m);return D&&typeof D.then=="function"?D.then(function(L){return setTimeout(function(){return z(null,L)})},function(L){setTimeout(function(){return h(L),z(null,!0)})}):z(null,D)}w(m,function(L,Q){if(L)return h(L),z(null);z(null,Q)})}catch(L){h(L),z(null)}};yk(u,y,p)},sd=function(u,m,h,p){for(var y=!1,w=u.slice();!y&&w.length;)try{y=w.pop()(m)===!1}catch(z){p.error("Error occurred in "+h+" callback, continuing anyway\u2026"),p.error(z)}return y},qa=function(m,h){var p="000000000"+m;return p.substr(p.length-h)},$k=require("os");function xk(){try{return $k.hostname()}catch{return process.env._CLUSTER_NETWORK_NAME_||process.env.COMPUTERNAME||"hostname"}}var wg=2,wk=qa(process.pid.toString(36),wg),kg=xk(),kk=kg.length,Sk=qa(kg.split("").reduce(function(u,m){return+u+m.charCodeAt(0)},+kk+36).toString(36),wg),Sg=function(){return wk+Sk},zk=function(m){return typeof m=="string"&&/^c[a-z0-9]{20,32}$/.test(m)},Do=0,cd=4,Va=36,zg=Math.pow(Va,cd);function Ig(){return qa((Math.random()*zg<<0).toString(Va),cd)}function Ik(){return Do=Do<zg?Do:0,Do++,Do-1}function ud(){var u="c",m=new Date().getTime().toString(Va),h=qa(Ik().toString(Va),cd),p=Sg(),y=Ig()+Ig();return u+m+h+p+y}ud.fingerprint=Sg,ud.isCuid=zk;var Ek=ud,Tk=(function(){function u(){this.id=Ek(),this.startedAt=new Date,this._handled=0,this._unhandled=0,this._user={},this.app={},this.device={}}var m=u.prototype;return m.getUser=function(){return this._user},m.setUser=function(p,y,w){this._user={id:p,email:y,name:w}},m.toJSON=function(){return{id:this.id,startedAt:this.startedAt,events:{handled:this._handled,unhandled:this._unhandled}}},m._track=function(p){this[p._handledState.unhandled?"_unhandled":"_handled"]+=1},u})(),ld=Tk,Ok=qr.add,Pk=qr.clear,dd=qr.merge,jk="00000",Nk="https://notify.bugsnag.smartbear.com",Rk="https://sessions.bugsnag.smartbear.com",dr=function(){},Ak=(function(){function u(h,p,y,w){var z=this;p===void 0&&(p=x.schema),y===void 0&&(y=[]),this._notifier=w,this._config={},this._schema=p,this._delivery={sendSession:dr,sendEvent:dr},this._logger={debug:dr,info:dr,warn:dr,error:dr},this._plugins={},this._breadcrumbs=[],this._session=null,this._metadata={},this._featuresIndex={},this._features=[],this._context=void 0,this._user={},this._groupingDiscriminator=void 0,this._cbs={e:[],s:[],sp:[],b:[]},this.Client=u,this.Event=La,this.Breadcrumb=r,this.Session=ld,this._config=this._configure(h,y),M(y.concat(this._config.plugins),function(Q){Q&&z._loadPlugin(Q)}),this._depth=1;var D=this,L=this.notify;this.notify=function(){return L.apply(D,arguments)}}var m=u.prototype;return m.addMetadata=function(p,y,w){return hn.add(this._metadata,p,y,w)},m.getMetadata=function(p,y){return hn.get(this._metadata,p,y)},m.clearMetadata=function(p,y){return hn.clear(this._metadata,p,y)},m.addFeatureFlag=function(p,y){y===void 0&&(y=null),Ok(this._features,this._featuresIndex,p,y)},m.addFeatureFlags=function(p){dd(this._features,p,this._featuresIndex)},m.clearFeatureFlag=function(p){Pk(this._features,this._featuresIndex,p)},m.clearFeatureFlags=function(){this._features=[],this._featuresIndex={}},m.getContext=function(){return this._context},m.setContext=function(p){this._context=p},m.getGroupingDiscriminator=function(){return this._groupingDiscriminator},m.setGroupingDiscriminator=function(p){var y=this._groupingDiscriminator;return(typeof p=="string"||p===null||p===void 0)&&(this._groupingDiscriminator=p),y},m._configure=function(p,y){var w=a(y,function(Q,de){return de&&de.configSchema?O({},Q,de.configSchema):Q},this._schema);p.endpoints||(p.sendPayloadChecksums="sendPayloadChecksums"in p?p.sendPayloadChecksums:!0);var z=a(_(w),function(Q,de){var Re=w[de].defaultValue(p[de]);if(p[de]!==void 0){var Le=w[de].validate(p[de]);Le?w[de].allowPartialObject?Q.config[de]=O(Re,p[de]):Q.config[de]=p[de]:(Q.errors[de]=w[de].message,Q.config[de]=Re)}else Q.config[de]=Re;return Q},{errors:{},config:{}}),D=z.errors,L=z.config;if(w.apiKey){if(!L.apiKey)throw new Error("No Bugsnag API Key set");/^[0-9a-f]{32}$/i.test(L.apiKey)||(D.apiKey="should be a string of 32 hexadecimal characters"),p.endpoints===void 0&&L.apiKey.indexOf(jk)===0&&(L.endpoints={notify:Nk,sessions:Rk})}return this._metadata=O({},L.metadata),dd(this._features,L.featureFlags,this._featuresIndex),this._user=O({},L.user),this._context=L.context,L.logger&&(this._logger=L.logger),L.onError&&(this._cbs.e=this._cbs.e.concat(L.onError)),L.onBreadcrumb&&(this._cbs.b=this._cbs.b.concat(L.onBreadcrumb)),L.onSession&&(this._cbs.s=this._cbs.s.concat(L.onSession)),_(D).length&&this._logger.warn(Dk(D,p)),L},m.getUser=function(){return this._user},m.setUser=function(p,y,w){this._user={id:p,email:y,name:w}},m._loadPlugin=function(p){var y=p.load(this);p.name&&(this._plugins["~"+p.name+"~"]=y)},m.getPlugin=function(p){return this._plugins["~"+p+"~"]},m._setDelivery=function(p){this._delivery=p(this)},m.startSession=function(){var p=new ld;p.app.releaseStage=this._config.releaseStage,p.app.version=this._config.appVersion,p.app.type=this._config.appType,p._user=O({},this._user);var y=sd(this._cbs.s,p,"onSession",this._logger);return y?(this._logger.debug("Session not started due to onSession callback"),this):this._sessionDelegate.startSession(this,p)},m.addOnError=function(p,y){y===void 0&&(y=!1),this._cbs.e[y?"unshift":"push"](p)},m.removeOnError=function(p){this._cbs.e=s(this._cbs.e,function(y){return y!==p})},m._addOnSessionPayload=function(p){this._cbs.sp.push(p)},m.addOnSession=function(p){this._cbs.s.push(p)},m.removeOnSession=function(p){this._cbs.s=s(this._cbs.s,function(y){return y!==p})},m.addOnBreadcrumb=function(p,y){y===void 0&&(y=!1),this._cbs.b[y?"unshift":"push"](p)},m.removeOnBreadcrumb=function(p){this._cbs.b=s(this._cbs.b,function(y){return y!==p})},m.pauseSession=function(){return this._sessionDelegate.pauseSession(this)},m.resumeSession=function(){return this._sessionDelegate.resumeSession(this)},m.leaveBreadcrumb=function(p,y,w){if(p=typeof p=="string"?p:"",w=typeof w=="string"&&c(i,w)?w:"manual",y=typeof y=="object"&&y!==null?y:{},!!p){var z=new r(p,y,w),D=sd(this._cbs.b,z,"onBreadcrumb",this._logger);if(D){this._logger.debug("Breadcrumb not attached due to onBreadcrumb callback");return}this._breadcrumbs.push(z),this._breadcrumbs.length>this._config.maxBreadcrumbs&&(this._breadcrumbs=this._breadcrumbs.slice(this._breadcrumbs.length-this._config.maxBreadcrumbs))}},m._isBreadcrumbTypeEnabled=function(p){var y=this._config.enabledBreadcrumbTypes;return y===null||c(y,p)},m.notify=function(p,y,w){w===void 0&&(w=dr);var z=La.create(p,!0,void 0,"notify()",this._depth+1,this._logger);this._notify(z,y,w)},m._notify=function(p,y,w){var z=this;if(w===void 0&&(w=dr),p.app=O({},p.app,{releaseStage:this._config.releaseStage,version:this._config.appVersion,type:this._config.appType}),p.context=p.context||this._context,p._metadata=O({},p._metadata,this._metadata),p._user=O({},p._user,this._user),p.breadcrumbs=this._breadcrumbs.slice(),p.setGroupingDiscriminator(this._groupingDiscriminator),dd(p._features,this._features,p._featuresIndex),this._config.enabledReleaseStages!==null&&!c(this._config.enabledReleaseStages,this._config.releaseStage))return this._logger.warn("Event not sent due to releaseStage/enabledReleaseStages configuration"),w(null,p);var D=p.severity,L=function(de){z._logger.error("Error occurred in onError callback, continuing anyway\u2026"),z._logger.error(de)},Q=[].concat(this._cbs.e).concat(y);bk(Q,p,L,function(de,Re){if(de&&L(de),!Re)return z._logger.debug("Event not sent due to onError callback"),w(null,p);z._isBreadcrumbTypeEnabled("error")&&u.prototype.leaveBreadcrumb.call(z,p.errors[0].errorClass,{errorClass:p.errors[0].errorClass,errorMessage:p.errors[0].errorMessage,severity:p.severity},"error"),D!==p.severity&&(p._handledState.severityReason={type:"userCallbackSetSeverity"}),p.unhandled!==p._handledState.unhandled&&(p._handledState.severityReason.unhandledOverridden=!0,p._handledState.unhandled=p.unhandled),z._session&&(z._session._track(p),p._session=z._session),z._delivery.sendEvent({apiKey:p.apiKey||z._config.apiKey,notifier:z._notifier,events:[p]},function(Le){return w(Le,p)})})},u})(),Dk=function(u,m){var h=new Error(`Invalid configuration
|
|
21
|
+
`+M(_(u),function(p){return" - "+p+" "+u[p]+", got "+Ck(m[p])}).join(`
|
|
22
22
|
|
|
23
|
-
`));return h},
|
|
23
|
+
`));return h},Ck=function(u){switch(typeof u){case"string":case"number":case"object":return JSON.stringify(u);default:return String(u)}},Fa=Ak,Ba={},Eg=["events.[].metaData","events.[].breadcrumbs.[].metaData","events.[].request","events.[].response"];Ba.event=function(u,m){var h=V(u,null,null,{redactedPaths:Eg,redactedKeys:m});return h.length>1e6&&(u.events[0]._metadata={notifier:`WARNING!
|
|
24
24
|
Serialized payload was `+h.length/1e6+`MB (limit = 1MB)
|
|
25
|
-
metadata was removed`},h=V(u,null,null,{redactedPaths:
|
|
26
|
-
`+St));m(null,St)})}),Re.write(y),Re.end()},
|
|
27
|
-
`+(z&&z.stack?z.stack:z),z),p.length>1e6&&u._logger.warn("Event oversized ("+(p.length/1e6).toFixed(2)+" MB)"),h(z)};if(u._config.endpoints.notify===null){var w=new Error("Event not sent due to incomplete endpoint configuration");return y(w)}try{
|
|
28
|
-
`+(w&&w.stack?w.stack:w),w),h(w)};if(u._config.endpoints.session===null){var y=new Error("Session not sent due to incomplete endpoint configuration");return p(y)}try{
|
|
29
|
-
`+
|
|
30
|
-
`+
|
|
25
|
+
metadata was removed`},h=V(u,null,null,{redactedPaths:Eg,redactedKeys:m})),h},Ba.session=function(u,m){var h=V(u,null,null);return h};var Uk=require("http"),Zk=require("https"),Mk=require("url"),Lk=Mk.parse,Tg=function(u,m){var h=u.url,p=u.headers,y=u.body,w=u.agent,z=!1,D=function(Le){z||(z=!0,m(Le))},L=Lk(h),Q=L.protocol==="https:",de=Q?Zk:Uk,Re=de.request({method:"POST",hostname:L.hostname,port:L.port,path:L.path,headers:p,agent:w});Re.on("error",D),Re.on("response",function(Le){qk(Le,function(fr,St){if(fr)return D(fr);if(Le.statusCode<200||Le.statusCode>=300)return D(new Error("Bad statusCode from API: "+Le.statusCode+`
|
|
26
|
+
`+St));m(null,St)})}),Re.write(y),Re.end()},qk=function(u,m){var h="";u.on("error",m),u.setEncoding("utf8"),u.on("data",function(p){h+=p}),u.on("end",function(){return m(null,h)})},Vk=function(u){return{sendEvent:function(m,h){h===void 0&&(h=function(){});var p=Ba.event(m,u._config.redactedKeys),y=function(z){z&&u._logger.error(`Event failed to send\u2026
|
|
27
|
+
`+(z&&z.stack?z.stack:z),z),p.length>1e6&&u._logger.warn("Event oversized ("+(p.length/1e6).toFixed(2)+" MB)"),h(z)};if(u._config.endpoints.notify===null){var w=new Error("Event not sent due to incomplete endpoint configuration");return y(w)}try{Tg({url:u._config.endpoints.notify,headers:{"Content-Type":"application/json","Bugsnag-Api-Key":m.apiKey||u._config.apiKey,"Bugsnag-Payload-Version":"4","Bugsnag-Sent-At":new Date().toISOString()},body:p,agent:u._config.agent},function(z,D){return y(z)})}catch(z){y(z)}},sendSession:function(m,h){h===void 0&&(h=function(){});var p=function(w){w&&u._logger.error(`Session failed to send\u2026
|
|
28
|
+
`+(w&&w.stack?w.stack:w),w),h(w)};if(u._config.endpoints.session===null){var y=new Error("Session not sent due to incomplete endpoint configuration");return p(y)}try{Tg({url:u._config.endpoints.sessions,headers:{"Content-Type":"application/json","Bugsnag-Api-Key":u._config.apiKey,"Bugsnag-Payload-Version":"1","Bugsnag-Sent-At":new Date().toISOString()},body:Ba.session(m,u._config.redactedKeys),agent:u._config.agent},function(w){return p(w)})}catch(w){p(w)}}}};function Co(){return Co=Object.assign?Object.assign.bind():function(u){for(var m=1;m<arguments.length;m++){var h=arguments[m];for(var p in h)({}).hasOwnProperty.call(h,p)&&(u[p]=h[p])}return u},Co.apply(null,arguments)}var fd=x.schema,Fk=require("os"),Bk=require("util"),Kk=Bk.inspect,Hk={appType:Co({},fd.appType,{defaultValue:function(){return"node"}}),projectRoot:{defaultValue:function(){return process.cwd()},validate:function(u){return u===null||b(u)},message:"should be string"},hostname:{defaultValue:function(){return Fk.hostname()},message:"should be a string",validate:function(u){return u===null||b(u)}},logger:Co({},fd.logger,{defaultValue:function(){return Jk()}}),releaseStage:Co({},fd.releaseStage,{defaultValue:function(){return process.env.NODE_ENV||"production"}}),agent:{defaultValue:function(){},message:"should be an HTTP(s) agent",validate:function(u){return u===void 0||Gk(u)}},onUncaughtException:{defaultValue:function(){return function(u,m,h){h.error("Uncaught exception"+Pg(m)+`, the process will now terminate\u2026
|
|
29
|
+
`+Og(u)),process.exit(1)}},message:"should be a function",validate:function(u){return typeof u=="function"}},onUnhandledRejection:{defaultValue:function(){return function(u,m,h){h.error("Unhandled rejection"+Pg(m)+`\u2026
|
|
30
|
+
`+Og(u))}},message:"should be a function",validate:function(u){return typeof u=="function"}}},Og=function(u){return u&&u.stack?u.stack:Kk(u)},Jk=function(){return["debug","info","warn","error"].reduce(function(u,m){var h=console[m]||console.log;return u[m]=h.bind(console,"[bugsnag]"),u},{})},Pg=function(u){return u.request&&Object.keys(u.request).length?" at "+u.request.httpMethod+" "+(u.request.path||u.request.url):""},Gk=function(u){return typeof u=="object"&&u!==null||typeof u=="boolean"},jg=new Date,Wk=function(){jg=new Date},Xk={name:"appDuration",load:function(u){return u.addOnError(function(m){var h=new Date;m.app.duration=h-jg},!0),{reset:Wk}}},pd={};pd.load=function(u){var m=/^(local-)?dev(elopment)?$/.test(u._config.releaseStage);m||!u._isBreadcrumbTypeEnabled("log")||M(Ng,function(h){var p=console[h];console[h]=function(){for(var y=arguments.length,w=new Array(y),z=0;z<y;z++)w[z]=arguments[z];u.leaveBreadcrumb("Console output",a(w,function(D,L,Q){var de="[Unknown value]";try{de=String(L)}catch{}if(de==="[object Object]")try{de=JSON.stringify(L)}catch{}return D["["+Q+"]"]=de,D},{severity:h.indexOf("group")===0?"log":h}),"log"),p.apply(console,w)},console[h]._restore=function(){console[h]=p}})},process.env.NODE_ENV!=="production"&&(pd.destroy=function(){return Ng.forEach(function(u){typeof console[u]._restore=="function"&&console[u]._restore()})});var Ng=s(["log","debug","info","warn","error"],function(u){return typeof console<"u"&&typeof console[u]=="function"}),md={},Rg=[];md=function(u){var m=new u.Client({},{},[],u._notifier);return m._config=u._config,m._breadcrumbs=u._breadcrumbs.slice(),m._metadata=O({},u._metadata),m._features=[].concat(u._features),m._featuresIndex=O({},u._featuresIndex),m._user=O({},u._user),m._context=u._context,m._cbs={e:u._cbs.e.slice(),s:u._cbs.s.slice(),sp:u._cbs.sp.slice(),b:u._cbs.b.slice()},m._logger=u._logger,m._delivery=u._delivery,m._sessionDelegate=u._sessionDelegate,Rg.forEach(function(h){h(m)}),m},md.registerCallback=function(u){Rg.push(u)};var gn={};gn.getStack=function(){return new Error().stack.split(`
|
|
31
31
|
`).slice(3).join(`
|
|
32
32
|
`)},gn.maybeUseFallbackStack=function(u,m){var h=u.stack.split(`
|
|
33
33
|
`);return(h.length===1||h.length===2&&/at Error \(native\)/.test(h[1]))&&(u.stack=h[0]+`
|
|
34
|
-
`+m),u};var Ba={},Fk=gn.getStack;Ba={name:"contextualize",load:function(u){var m=function(h,p){var y=Fk(),w=fd(u);return w.fallbackStack=y,w.addOnError(p),u._clientContext.run(w,h)};return m}},Ba.default=Ba;var Ka={},Bk=gn.getStack,Kk=gn.maybeUseFallbackStack;Ka={name:"intercept",load:function(u){var m=function(h,p){h===void 0&&(h=function(){}),typeof p!="function"&&(p=h,h=function(){});var y=Bk();return function(w){if(w){w.stack&&Kk(w,y);var z=u.Event.create(w,!0,{severity:"warning",unhandled:!1,severityReason:{type:"callbackErrorIntercept"}},"intercept()",1);u._notify(z,h);return}for(var D=arguments.length,L=new Array(D>1?D-1:0),Q=1;Q<D;Q++)L[Q-1]=arguments[Q];p.apply(void 0,L)}};return m}},Ka.default=Ka;function Ha(){return Ha=Object.assign?Object.assign.bind():function(u){for(var m=1;m<arguments.length;m++){var h=arguments[m];for(var p in h)({}).hasOwnProperty.call(h,p)&&(u[p]=h[p])}return u},Ha.apply(null,arguments)}var Uo=require("os"),Hk={load:function(u){var m={osName:Uo.platform()+" ("+Uo.arch()+")",osVersion:Uo.release(),totalMemory:Uo.totalmem(),hostname:u._config.hostname,runtimeVersions:{node:process.versions.node}};u._addOnSessionPayload(function(h){h.device=Ha({},h.device,m)}),u.addOnError(function(h){h.device=Ha({},h.device,m,{freeMemory:Uo.freemem(),time:new Date})},!0)}},jg=require("path"),Jk=jg.join,Gk=jg.resolve,Ng=function(u){return Jk(Gk(u),"/")},Wk={load:function(u){return u.addOnError(function(m){if(u._config.projectRoot){var h=Ng(u._config.projectRoot),p=m.errors.reduce(function(y,w){return y.concat(w.stacktrace)},[]);p.map(function(y){y.inProject=typeof y.file=="string"&&y.file.indexOf(h)===0&&!/\/node_modules\//.test(y.file)})}})}};function pd(){return pd=Object.assign?Object.assign.bind():function(u){for(var m=1;m<arguments.length;m++){var h=arguments[m];for(var p in h)({}).hasOwnProperty.call(h,p)&&(u[p]=h[p])}return u},pd.apply(null,arguments)}function Xk(u,m){u.prototype=Object.create(m.prototype),u.prototype.constructor=u,md(u,m)}function md(u,m){return md=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(h,p){return h.__proto__=p,h},md(u,m)}var Rg=3,Ag=200,Yk=require("fs"),Qk=Yk.createReadStream,eS=require("stream"),tS=eS.Writable,rS=$w(),nS=ww(),oS=require("path"),iS={load:function(u){if(u._config.sendCode){var m=function(h,p){return new Promise(function(y,w){try{if(!h.lineNumber||!h.file)return y(h);var z=oS.resolve(u._config.projectRoot,h.file),D=z+"@"+h.lineNumber;if(D in p)return h.code=p[D],y(h);aS(z,h.lineNumber,function(L,Q){return L||(h.code=p[D]=Q),y(h)})}catch{return y(h)}})};u.addOnError(function(h){return new Promise(function(p,y){var w=Object.create(null),z=h.errors.reduce(function(D,L){return D.concat(L.stacktrace)},[]);cS(z.map(function(D){return function(){return m(D,w)}})).then(p).catch(y)})})}},configSchema:{sendCode:{defaultValue:function(){return!0},validate:function(u){return u===!0||u===!1},message:"should be true or false"}}},aS=function(u,m,h){var p=m-Rg,y=m+Rg,w=Qk(u,{encoding:"utf8"}),z=new nS.LineStream({keepEmptyLines:!0}),D=new sS({start:p,end:y});D.on("done",function(){return w.destroy()}),rS(w,z,D,function(L){if(L&&L.message!=="premature close")return h(L);h(null,D.getCode())})},sS=(function(u){function m(p){var y;return y=u.call(this,pd({},p,{decodeStrings:!1}))||this,y._start=p.start,y._end=p.end,y._n=0,y._code={},y}Xk(m,u);var h=m.prototype;return h._write=function(y,w,z){return this._n++,this._n<this._start?z(null):this._n<=this._end?(this._code[String(this._n)]=y.length<=Ag?y:y.substr(0,Ag),z(null)):(this.emit("done"),z(null))},h.getCode=function(){return this._code},m})(tS),cS=function(u){return new Promise(function(m,h){var p=[];u.reduce(function(y,w){return y.then(function(z){return p.push(z),w()})},Promise.resolve()).then(function(y){p.push(y)}).then(function(){m(p.slice(1))})})},uS=gn.maybeUseFallbackStack,hd,lS={load:function(u){u._config.autoDetectErrors&&u._config.enabledErrorTypes.unhandledExceptions&&(hd=function(m){var h=u._clientContext&&u._clientContext.getStore(),p=h||u;m.stack&&p.fallbackStack&&uS(m,p.fallbackStack);var y=p.Event.create(m,!1,{severity:"error",unhandled:!0,severityReason:{type:"unhandledException"}},"uncaughtException handler",1);return new Promise(function(w){p._notify(y,function(){},function(z,D){z&&p._logger.error("Failed to send event to Bugsnag"),p._config.onUncaughtException(m,D,p._logger),w()})})},process.prependListener("uncaughtException",hd))},destroy:function(){process.removeListener("uncaughtException",hd)}},Ja,dS={load:function(u){!u._config.autoDetectErrors||!u._config.enabledErrorTypes.unhandledRejections||(Ja=function(m){var h=u._clientContext&&u._clientContext.getStore(),p=h||u,y=!u._config.reportUnhandledPromiseRejectionsAsHandled,w=p.Event.create(m,!1,{severity:"error",unhandled:y,severityReason:{type:"unhandledPromiseRejection"}},"unhandledRejection handler",1);return new Promise(function(z){p._notify(w,function(){},function(D,L){D&&p._logger.error("Failed to send event to Bugsnag"),p._config.onUnhandledRejection(m,L,p._logger),z()})})},process.prependListener?process.prependListener("unhandledRejection",Ja):process.on("unhandledRejection",Ja))},destroy:function(){process.removeListener("unhandledRejection",Ja)}},fS=gd;function gd(u){u=u||{},this.ms=u.min||100,this.max=u.max||1e4,this.factor=u.factor||2,this.jitter=u.jitter>0&&u.jitter<=1?u.jitter:0,this.attempts=0}gd.prototype.duration=function(){var u=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var m=Math.random(),h=Math.floor(m*this.jitter*u);u=(Math.floor(m*10)&1)==0?u-h:u+h}return Math.min(u,this.max)|0},gd.prototype.reset=function(){this.attempts=0};function pS(u,m){u.prototype=Object.create(m.prototype),u.prototype.constructor=u,vd(u,m)}function vd(u,m){return vd=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(h,p){return h.__proto__=p,h},vd(u,m)}var mS=10*1e3,hS=require("events").EventEmitter,gS=(function(u){function m(p){var y;return y=u.call(this)||this,y._sessions=new Map,y._interval=null,y._intervalLength=p||mS,y._summarize=y._summarize.bind(y),y}pS(m,u);var h=m.prototype;return h.start=function(){this._interval||(this._interval=setInterval(this._summarize,this._intervalLength).unref())},h.stop=function(){clearInterval(this._interval),this._interval=null},h.track=function(y){var w=vS(y.startedAt),z=this._sessions.get(w);return this._sessions.set(w,typeof z>"u"?1:z+1),y},h._summarize=function(){var y=this,w=[];this._sessions.forEach(function(z,D){w.push({startedAt:D,sessionsStarted:z}),y._sessions.delete(D)}),w.length&&this.emit("summary",w)},m})(hS),vS=function(u){var m=new Date(u);return m.setSeconds(0),m.setMilliseconds(0),m.toISOString()},_S={load:function(u){var m=null;u._sessionDelegate={startSession:function(h,p){return m||(m=new gS(h._config.sessionSummaryInterval),m.on("summary",yS(h)),m.start()),h._session=p,h._pausedSession=null,m.track(h._session),h},pauseSession:function(h){h._pausedSession=h._session,h._session=null},resumeSession:function(h){return h._session?h:h._pausedSession?(h._session=h._pausedSession,h._pausedSession=null,h):h.startSession()}}},configSchema:{sessionSummaryInterval:{defaultValue:function(){},validate:function(u){return u===void 0||v()(u)},message:"should be a positive integer"}}},yS=function(u){return function(m){if(u._config.enabledReleaseStages!==null&&!u._config.enabledReleaseStages.includes(u._config.releaseStage)){u._logger.warn("Session not sent due to releaseStage/enabledReleaseStages configuration");return}if(!m.length)return;var h=new fS({min:1e3,max:1e4}),p=10;w(y);function y(z){if(!z){var D=m.reduce(function(L,Q){return L+Q.sessionsStarted},0);return u._logger.debug(D+" session(s) reported")}if(h.attempts===10){u._logger.error("Session delivery failed, max retries exceeded",z);return}u._logger.debug("Session delivery failed, retry #"+(h.attempts+1)+"/"+p,z),setTimeout(function(){return w(y)},h.duration())}function w(z){var D={notifier:u._notifier,device:{},app:{releaseStage:u._config.releaseStage,version:u._config.appVersion,type:u._config.appType},sessionCounts:m},L=id(u._cbs.sp,D,"onSessionPayload",u._logger);if(L)return u._logger.debug("Session not sent due to onSessionPayload callback"),z(null);u._delivery.sendSession(D,z)}}},bS={load:function(u){u.addOnError(function(m){var h=m.errors.reduce(function(p,y){return p.concat(y.stacktrace)},[]);h.forEach(function(p){typeof p.file=="string"&&(p.file=p.file.replace(/\\/g,"/"))})})}},$S={load:function(u){return u.addOnError(function(m){if(u._config.projectRoot){var h=Ng(u._config.projectRoot),p=m.errors.reduce(function(y,w){return y.concat(w.stacktrace)},[]);p.map(function(y){typeof y.file=="string"&&y.file.indexOf(h)===0&&(y.file=y.file.replace(h,""))})}})}},Vr={};function _d(){return _d=Object.assign?Object.assign.bind():function(u){for(var m=1;m<arguments.length;m++){var h=arguments[m];for(var p in h)({}).hasOwnProperty.call(h,p)&&(u[p]=h[p])}return u},_d.apply(null,arguments)}var xS="Bugsnag Node",wS="8.8.0",kS="https://github.com/bugsnag/bugsnag-js",SS=require("async_hooks"),zS=SS.AsyncLocalStorage;Ma.__type="nodejs";var IS=_d({},x.schema,Zk),ES=[Vk,iS,Wk,$S,_S,Hk,lS,dS,Ka,Ba,bS,dd],kt={_client:null,createClient:function(u){typeof u=="string"&&(u={apiKey:u}),u||(u={});var m=new Va(u,IS,ES,{name:xS,version:wS,url:kS});return Object.keys(Va.prototype).forEach(function(h){var p=m[h];m[h]=function(){var y=m._clientContext&&typeof m._clientContext.getStore=="function"?m._clientContext.getStore():null,w=y||m,z=y?y[h]:p;w._depth+=1;var D=z.apply(w,arguments);return w._depth-=1,D}}),m._clientContext=new zS,m._setDelivery(Ak),m._logger.debug("Loaded!"),m},start:function(u){return kt._client?(kt._client._logger.warn("Bugsnag.start() was called more than once. Ignoring."),kt._client):(kt._client=kt.createClient(u),kt._client)},isStarted:function(){return kt._client!=null}};return Object.keys(Va.prototype).forEach(function(u){/^_/.test(u)||(kt[u]=function(){var m=kt._client,h=m&&m._clientContext&&m._clientContext.getStore();if(h&&(m=h),!m)return console.error("Bugsnag."+u+"() was called before Bugsnag.start()");m._depth+=1;var p=m[u].apply(m,arguments);return m._depth-=1,p})}),Vr=kt,Vr.Client=Va,Vr.Event=Ma,Vr.Session=cd,Vr.Breadcrumb=r,Vr.default=kt,Vr})});var Iw=A((a9,zw)=>{zw.exports=Sw()});var xd=ht(Lg()),qg=ht(require("path"));process.env.DOTENV_CONFIG_SILENT="true";xd.default.config();xd.default.config({path:qg.default.resolve(__dirname,"../../.env")});var ce;(function(e){e.assertEqual=r=>{};function t(r){}e.assertIs=t;function n(r){throw new Error}e.assertNever=n,e.arrayToEnum=r=>{let i={};for(let a of r)i[a]=a;return i},e.getValidEnumValues=r=>{let i=e.objectKeys(r).filter(s=>typeof r[r[s]]!="number"),a={};for(let s of i)a[s]=r[s];return e.objectValues(a)},e.objectValues=r=>e.objectKeys(r).map(function(i){return r[i]}),e.objectKeys=typeof Object.keys=="function"?r=>Object.keys(r):r=>{let i=[];for(let a in r)Object.prototype.hasOwnProperty.call(r,a)&&i.push(a);return i},e.find=(r,i)=>{for(let a of r)if(i(a))return a},e.isInteger=typeof Number.isInteger=="function"?r=>Number.isInteger(r):r=>typeof r=="number"&&Number.isFinite(r)&&Math.floor(r)===r;function o(r,i=" | "){return r.map(a=>typeof a=="string"?`'${a}'`:a).join(i)}e.joinValues=o,e.jsonStringifyReplacer=(r,i)=>typeof i=="bigint"?i.toString():i})(ce||(ce={}));var Vg;(function(e){e.mergeShapes=(t,n)=>({...t,...n})})(Vg||(Vg={}));var U=ce.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),Xt=e=>{switch(typeof e){case"undefined":return U.undefined;case"string":return U.string;case"number":return Number.isNaN(e)?U.nan:U.number;case"boolean":return U.boolean;case"function":return U.function;case"bigint":return U.bigint;case"symbol":return U.symbol;case"object":return Array.isArray(e)?U.array:e===null?U.null:e.then&&typeof e.then=="function"&&e.catch&&typeof e.catch=="function"?U.promise:typeof Map<"u"&&e instanceof Map?U.map:typeof Set<"u"&&e instanceof Set?U.set:typeof Date<"u"&&e instanceof Date?U.date:U.object;default:return U.unknown}};var T=ce.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"]);var ut=class e extends Error{get errors(){return this.issues}constructor(t){super(),this.issues=[],this.addIssue=o=>{this.issues=[...this.issues,o]},this.addIssues=(o=[])=>{this.issues=[...this.issues,...o]};let n=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,n):this.__proto__=n,this.name="ZodError",this.issues=t}format(t){let n=t||function(i){return i.message},o={_errors:[]},r=i=>{for(let a of i.issues)if(a.code==="invalid_union")a.unionErrors.map(r);else if(a.code==="invalid_return_type")r(a.returnTypeError);else if(a.code==="invalid_arguments")r(a.argumentsError);else if(a.path.length===0)o._errors.push(n(a));else{let s=o,c=0;for(;c<a.path.length;){let l=a.path[c];c===a.path.length-1?(s[l]=s[l]||{_errors:[]},s[l]._errors.push(n(a))):s[l]=s[l]||{_errors:[]},s=s[l],c++}}};return r(this),o}static assert(t){if(!(t instanceof e))throw new Error(`Not a ZodError: ${t}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,ce.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(t=n=>n.message){let n={},o=[];for(let r of this.issues)if(r.path.length>0){let i=r.path[0];n[i]=n[i]||[],n[i].push(t(r))}else o.push(t(r));return{formErrors:o,fieldErrors:n}}get formErrors(){return this.flatten()}};ut.create=e=>new ut(e);var GS=(e,t)=>{let n;switch(e.code){case T.invalid_type:e.received===U.undefined?n="Required":n=`Expected ${e.expected}, received ${e.received}`;break;case T.invalid_literal:n=`Invalid literal value, expected ${JSON.stringify(e.expected,ce.jsonStringifyReplacer)}`;break;case T.unrecognized_keys:n=`Unrecognized key(s) in object: ${ce.joinValues(e.keys,", ")}`;break;case T.invalid_union:n="Invalid input";break;case T.invalid_union_discriminator:n=`Invalid discriminator value. Expected ${ce.joinValues(e.options)}`;break;case T.invalid_enum_value:n=`Invalid enum value. Expected ${ce.joinValues(e.options)}, received '${e.received}'`;break;case T.invalid_arguments:n="Invalid function arguments";break;case T.invalid_return_type:n="Invalid function return type";break;case T.invalid_date:n="Invalid date";break;case T.invalid_string:typeof e.validation=="object"?"includes"in e.validation?(n=`Invalid input: must include "${e.validation.includes}"`,typeof e.validation.position=="number"&&(n=`${n} at one or more positions greater than or equal to ${e.validation.position}`)):"startsWith"in e.validation?n=`Invalid input: must start with "${e.validation.startsWith}"`:"endsWith"in e.validation?n=`Invalid input: must end with "${e.validation.endsWith}"`:ce.assertNever(e.validation):e.validation!=="regex"?n=`Invalid ${e.validation}`:n="Invalid";break;case T.too_small:e.type==="array"?n=`Array must contain ${e.exact?"exactly":e.inclusive?"at least":"more than"} ${e.minimum} element(s)`:e.type==="string"?n=`String must contain ${e.exact?"exactly":e.inclusive?"at least":"over"} ${e.minimum} character(s)`:e.type==="number"?n=`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:e.type==="bigint"?n=`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:e.type==="date"?n=`Date must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(e.minimum))}`:n="Invalid input";break;case T.too_big:e.type==="array"?n=`Array must contain ${e.exact?"exactly":e.inclusive?"at most":"less than"} ${e.maximum} element(s)`:e.type==="string"?n=`String must contain ${e.exact?"exactly":e.inclusive?"at most":"under"} ${e.maximum} character(s)`:e.type==="number"?n=`Number must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:e.type==="bigint"?n=`BigInt must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:e.type==="date"?n=`Date must be ${e.exact?"exactly":e.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(e.maximum))}`:n="Invalid input";break;case T.custom:n="Invalid input";break;case T.invalid_intersection_types:n="Intersection results could not be merged";break;case T.not_multiple_of:n=`Number must be a multiple of ${e.multipleOf}`;break;case T.not_finite:n="Number must be finite";break;default:n=t.defaultError,ce.assertNever(e)}return{message:n}},pr=GS;var WS=pr;function Mo(){return WS}var Wa=e=>{let{data:t,path:n,errorMaps:o,issueData:r}=e,i=[...n,...r.path||[]],a={...r,path:i};if(r.message!==void 0)return{...r,path:i,message:r.message};let s="",c=o.filter(l=>!!l).slice().reverse();for(let l of c)s=l(a,{data:t,defaultError:s}).message;return{...r,path:i,message:s}};function C(e,t){let n=Mo(),o=Wa({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,n,n===pr?void 0:pr].filter(r=>!!r)});e.common.issues.push(o)}var qe=class e{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(t,n){let o=[];for(let r of n){if(r.status==="aborted")return J;r.status==="dirty"&&t.dirty(),o.push(r.value)}return{status:t.value,value:o}}static async mergeObjectAsync(t,n){let o=[];for(let r of n){let i=await r.key,a=await r.value;o.push({key:i,value:a})}return e.mergeObjectSync(t,o)}static mergeObjectSync(t,n){let o={};for(let r of n){let{key:i,value:a}=r;if(i.status==="aborted"||a.status==="aborted")return J;i.status==="dirty"&&t.dirty(),a.status==="dirty"&&t.dirty(),i.value!=="__proto__"&&(typeof a.value<"u"||r.alwaysSet)&&(o[i.value]=a.value)}return{status:t.value,value:o}}},J=Object.freeze({status:"aborted"}),yn=e=>({status:"dirty",value:e}),Ge=e=>({status:"valid",value:e}),wd=e=>e.status==="aborted",kd=e=>e.status==="dirty",Br=e=>e.status==="valid",Lo=e=>typeof Promise<"u"&&e instanceof Promise;var q;(function(e){e.errToObj=t=>typeof t=="string"?{message:t}:t||{},e.toString=t=>typeof t=="string"?t:t?.message})(q||(q={}));var gt=class{constructor(t,n,o,r){this._cachedPath=[],this.parent=t,this.data=n,this._path=o,this._key=r}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}},Fg=(e,t)=>{if(Br(t))return{success:!0,data:t.value};if(!e.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;let n=new ut(e.common.issues);return this._error=n,this._error}}};function Y(e){if(!e)return{};let{errorMap:t,invalid_type_error:n,required_error:o,description:r}=e;if(t&&(n||o))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return t?{errorMap:t,description:r}:{errorMap:(a,s)=>{let{message:c}=e;return a.code==="invalid_enum_value"?{message:c??s.defaultError}:typeof s.data>"u"?{message:c??o??s.defaultError}:a.code!=="invalid_type"?{message:s.defaultError}:{message:c??n??s.defaultError}},description:r}}var ne=class{get description(){return this._def.description}_getType(t){return Xt(t.data)}_getOrReturnCtx(t,n){return n||{common:t.parent.common,data:t.data,parsedType:Xt(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}_processInputParams(t){return{status:new qe,ctx:{common:t.parent.common,data:t.data,parsedType:Xt(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}}_parseSync(t){let n=this._parse(t);if(Lo(n))throw new Error("Synchronous parse encountered promise.");return n}_parseAsync(t){let n=this._parse(t);return Promise.resolve(n)}parse(t,n){let o=this.safeParse(t,n);if(o.success)return o.data;throw o.error}safeParse(t,n){let o={common:{issues:[],async:n?.async??!1,contextualErrorMap:n?.errorMap},path:n?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:Xt(t)},r=this._parseSync({data:t,path:o.path,parent:o});return Fg(o,r)}"~validate"(t){let n={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:Xt(t)};if(!this["~standard"].async)try{let o=this._parseSync({data:t,path:[],parent:n});return Br(o)?{value:o.value}:{issues:n.common.issues}}catch(o){o?.message?.toLowerCase()?.includes("encountered")&&(this["~standard"].async=!0),n.common={issues:[],async:!0}}return this._parseAsync({data:t,path:[],parent:n}).then(o=>Br(o)?{value:o.value}:{issues:n.common.issues})}async parseAsync(t,n){let o=await this.safeParseAsync(t,n);if(o.success)return o.data;throw o.error}async safeParseAsync(t,n){let o={common:{issues:[],contextualErrorMap:n?.errorMap,async:!0},path:n?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:Xt(t)},r=this._parse({data:t,path:o.path,parent:o}),i=await(Lo(r)?r:Promise.resolve(r));return Fg(o,i)}refine(t,n){let o=r=>typeof n=="string"||typeof n>"u"?{message:n}:typeof n=="function"?n(r):n;return this._refinement((r,i)=>{let a=t(r),s=()=>i.addIssue({code:T.custom,...o(r)});return typeof Promise<"u"&&a instanceof Promise?a.then(c=>c?!0:(s(),!1)):a?!0:(s(),!1)})}refinement(t,n){return this._refinement((o,r)=>t(o)?!0:(r.addIssue(typeof n=="function"?n(o,r):n),!1))}_refinement(t){return new It({schema:this,typeName:O.ZodEffects,effect:{type:"refinement",refinement:t}})}superRefine(t){return this._refinement(t)}constructor(t){this.spa=this.safeParseAsync,this._def=t,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:n=>this["~validate"](n)}}optional(){return zt.create(this,this._def)}nullable(){return er.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return hr.create(this)}promise(){return Kr.create(this,this._def)}or(t){return kn.create([this,t],this._def)}and(t){return Sn.create(this,t,this._def)}transform(t){return new It({...Y(this._def),schema:this,typeName:O.ZodEffects,effect:{type:"transform",transform:t}})}default(t){let n=typeof t=="function"?t:()=>t;return new Pn({...Y(this._def),innerType:this,defaultValue:n,typeName:O.ZodDefault})}brand(){return new Xa({typeName:O.ZodBranded,type:this,...Y(this._def)})}catch(t){let n=typeof t=="function"?t:()=>t;return new On({...Y(this._def),innerType:this,catchValue:n,typeName:O.ZodCatch})}describe(t){let n=this.constructor;return new n({...this._def,description:t})}pipe(t){return Ya.create(this,t)}readonly(){return jn.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}},XS=/^c[^\s-]{8,}$/i,YS=/^[0-9a-z]+$/,QS=/^[0-9A-HJKMNP-TV-Z]{26}$/i,e0=/^[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,t0=/^[a-z0-9_-]{21}$/i,r0=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,n0=/^[-+]?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)?)??$/,o0=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,i0="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$",Sd,a0=/^(?:(?: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])$/,s0=/^(?:(?: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])$/,c0=/^(([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]))$/,u0=/^(([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])$/,l0=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,d0=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,Bg="((\\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])))",f0=new RegExp(`^${Bg}$`);function Kg(e){let t="[0-5]\\d";e.precision?t=`${t}\\.\\d{${e.precision}}`:e.precision==null&&(t=`${t}(\\.\\d+)?`);let n=e.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${t})${n}`}function p0(e){return new RegExp(`^${Kg(e)}$`)}function m0(e){let t=`${Bg}T${Kg(e)}`,n=[];return n.push(e.local?"Z?":"Z"),e.offset&&n.push("([+-]\\d{2}:?\\d{2})"),t=`${t}(${n.join("|")})`,new RegExp(`^${t}$`)}function h0(e,t){return!!((t==="v4"||!t)&&a0.test(e)||(t==="v6"||!t)&&c0.test(e))}function g0(e,t){if(!r0.test(e))return!1;try{let[n]=e.split(".");if(!n)return!1;let o=n.replace(/-/g,"+").replace(/_/g,"/").padEnd(n.length+(4-n.length%4)%4,"="),r=JSON.parse(atob(o));return!(typeof r!="object"||r===null||"typ"in r&&r?.typ!=="JWT"||!r.alg||t&&r.alg!==t)}catch{return!1}}function v0(e,t){return!!((t==="v4"||!t)&&s0.test(e)||(t==="v6"||!t)&&u0.test(e))}var $n=class e extends ne{_parse(t){if(this._def.coerce&&(t.data=String(t.data)),this._getType(t)!==U.string){let i=this._getOrReturnCtx(t);return C(i,{code:T.invalid_type,expected:U.string,received:i.parsedType}),J}let o=new qe,r;for(let i of this._def.checks)if(i.kind==="min")t.data.length<i.value&&(r=this._getOrReturnCtx(t,r),C(r,{code:T.too_small,minimum:i.value,type:"string",inclusive:!0,exact:!1,message:i.message}),o.dirty());else if(i.kind==="max")t.data.length>i.value&&(r=this._getOrReturnCtx(t,r),C(r,{code:T.too_big,maximum:i.value,type:"string",inclusive:!0,exact:!1,message:i.message}),o.dirty());else if(i.kind==="length"){let a=t.data.length>i.value,s=t.data.length<i.value;(a||s)&&(r=this._getOrReturnCtx(t,r),a?C(r,{code:T.too_big,maximum:i.value,type:"string",inclusive:!0,exact:!0,message:i.message}):s&&C(r,{code:T.too_small,minimum:i.value,type:"string",inclusive:!0,exact:!0,message:i.message}),o.dirty())}else if(i.kind==="email")o0.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"email",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="emoji")Sd||(Sd=new RegExp(i0,"u")),Sd.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"emoji",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="uuid")e0.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"uuid",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="nanoid")t0.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"nanoid",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="cuid")XS.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"cuid",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="cuid2")YS.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"cuid2",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="ulid")QS.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"ulid",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="url")try{new URL(t.data)}catch{r=this._getOrReturnCtx(t,r),C(r,{validation:"url",code:T.invalid_string,message:i.message}),o.dirty()}else i.kind==="regex"?(i.regex.lastIndex=0,i.regex.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"regex",code:T.invalid_string,message:i.message}),o.dirty())):i.kind==="trim"?t.data=t.data.trim():i.kind==="includes"?t.data.includes(i.value,i.position)||(r=this._getOrReturnCtx(t,r),C(r,{code:T.invalid_string,validation:{includes:i.value,position:i.position},message:i.message}),o.dirty()):i.kind==="toLowerCase"?t.data=t.data.toLowerCase():i.kind==="toUpperCase"?t.data=t.data.toUpperCase():i.kind==="startsWith"?t.data.startsWith(i.value)||(r=this._getOrReturnCtx(t,r),C(r,{code:T.invalid_string,validation:{startsWith:i.value},message:i.message}),o.dirty()):i.kind==="endsWith"?t.data.endsWith(i.value)||(r=this._getOrReturnCtx(t,r),C(r,{code:T.invalid_string,validation:{endsWith:i.value},message:i.message}),o.dirty()):i.kind==="datetime"?m0(i).test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{code:T.invalid_string,validation:"datetime",message:i.message}),o.dirty()):i.kind==="date"?f0.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{code:T.invalid_string,validation:"date",message:i.message}),o.dirty()):i.kind==="time"?p0(i).test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{code:T.invalid_string,validation:"time",message:i.message}),o.dirty()):i.kind==="duration"?n0.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"duration",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="ip"?h0(t.data,i.version)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"ip",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="jwt"?g0(t.data,i.alg)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"jwt",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="cidr"?v0(t.data,i.version)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"cidr",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="base64"?l0.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"base64",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="base64url"?d0.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"base64url",code:T.invalid_string,message:i.message}),o.dirty()):ce.assertNever(i);return{status:o.value,value:t.data}}_regex(t,n,o){return this.refinement(r=>t.test(r),{validation:n,code:T.invalid_string,...q.errToObj(o)})}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}email(t){return this._addCheck({kind:"email",...q.errToObj(t)})}url(t){return this._addCheck({kind:"url",...q.errToObj(t)})}emoji(t){return this._addCheck({kind:"emoji",...q.errToObj(t)})}uuid(t){return this._addCheck({kind:"uuid",...q.errToObj(t)})}nanoid(t){return this._addCheck({kind:"nanoid",...q.errToObj(t)})}cuid(t){return this._addCheck({kind:"cuid",...q.errToObj(t)})}cuid2(t){return this._addCheck({kind:"cuid2",...q.errToObj(t)})}ulid(t){return this._addCheck({kind:"ulid",...q.errToObj(t)})}base64(t){return this._addCheck({kind:"base64",...q.errToObj(t)})}base64url(t){return this._addCheck({kind:"base64url",...q.errToObj(t)})}jwt(t){return this._addCheck({kind:"jwt",...q.errToObj(t)})}ip(t){return this._addCheck({kind:"ip",...q.errToObj(t)})}cidr(t){return this._addCheck({kind:"cidr",...q.errToObj(t)})}datetime(t){return typeof t=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:t}):this._addCheck({kind:"datetime",precision:typeof t?.precision>"u"?null:t?.precision,offset:t?.offset??!1,local:t?.local??!1,...q.errToObj(t?.message)})}date(t){return this._addCheck({kind:"date",message:t})}time(t){return typeof t=="string"?this._addCheck({kind:"time",precision:null,message:t}):this._addCheck({kind:"time",precision:typeof t?.precision>"u"?null:t?.precision,...q.errToObj(t?.message)})}duration(t){return this._addCheck({kind:"duration",...q.errToObj(t)})}regex(t,n){return this._addCheck({kind:"regex",regex:t,...q.errToObj(n)})}includes(t,n){return this._addCheck({kind:"includes",value:t,position:n?.position,...q.errToObj(n?.message)})}startsWith(t,n){return this._addCheck({kind:"startsWith",value:t,...q.errToObj(n)})}endsWith(t,n){return this._addCheck({kind:"endsWith",value:t,...q.errToObj(n)})}min(t,n){return this._addCheck({kind:"min",value:t,...q.errToObj(n)})}max(t,n){return this._addCheck({kind:"max",value:t,...q.errToObj(n)})}length(t,n){return this._addCheck({kind:"length",value:t,...q.errToObj(n)})}nonempty(t){return this.min(1,q.errToObj(t))}trim(){return new e({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new e({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new e({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(t=>t.kind==="datetime")}get isDate(){return!!this._def.checks.find(t=>t.kind==="date")}get isTime(){return!!this._def.checks.find(t=>t.kind==="time")}get isDuration(){return!!this._def.checks.find(t=>t.kind==="duration")}get isEmail(){return!!this._def.checks.find(t=>t.kind==="email")}get isURL(){return!!this._def.checks.find(t=>t.kind==="url")}get isEmoji(){return!!this._def.checks.find(t=>t.kind==="emoji")}get isUUID(){return!!this._def.checks.find(t=>t.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(t=>t.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(t=>t.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(t=>t.kind==="cuid2")}get isULID(){return!!this._def.checks.find(t=>t.kind==="ulid")}get isIP(){return!!this._def.checks.find(t=>t.kind==="ip")}get isCIDR(){return!!this._def.checks.find(t=>t.kind==="cidr")}get isBase64(){return!!this._def.checks.find(t=>t.kind==="base64")}get isBase64url(){return!!this._def.checks.find(t=>t.kind==="base64url")}get minLength(){let t=null;for(let n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t}get maxLength(){let t=null;for(let n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t}};$n.create=e=>new $n({checks:[],typeName:O.ZodString,coerce:e?.coerce??!1,...Y(e)});function _0(e,t){let n=(e.toString().split(".")[1]||"").length,o=(t.toString().split(".")[1]||"").length,r=n>o?n:o,i=Number.parseInt(e.toFixed(r).replace(".","")),a=Number.parseInt(t.toFixed(r).replace(".",""));return i%a/10**r}var qo=class e extends ne{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(t){if(this._def.coerce&&(t.data=Number(t.data)),this._getType(t)!==U.number){let i=this._getOrReturnCtx(t);return C(i,{code:T.invalid_type,expected:U.number,received:i.parsedType}),J}let o,r=new qe;for(let i of this._def.checks)i.kind==="int"?ce.isInteger(t.data)||(o=this._getOrReturnCtx(t,o),C(o,{code:T.invalid_type,expected:"integer",received:"float",message:i.message}),r.dirty()):i.kind==="min"?(i.inclusive?t.data<i.value:t.data<=i.value)&&(o=this._getOrReturnCtx(t,o),C(o,{code:T.too_small,minimum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),r.dirty()):i.kind==="max"?(i.inclusive?t.data>i.value:t.data>=i.value)&&(o=this._getOrReturnCtx(t,o),C(o,{code:T.too_big,maximum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),r.dirty()):i.kind==="multipleOf"?_0(t.data,i.value)!==0&&(o=this._getOrReturnCtx(t,o),C(o,{code:T.not_multiple_of,multipleOf:i.value,message:i.message}),r.dirty()):i.kind==="finite"?Number.isFinite(t.data)||(o=this._getOrReturnCtx(t,o),C(o,{code:T.not_finite,message:i.message}),r.dirty()):ce.assertNever(i);return{status:r.value,value:t.data}}gte(t,n){return this.setLimit("min",t,!0,q.toString(n))}gt(t,n){return this.setLimit("min",t,!1,q.toString(n))}lte(t,n){return this.setLimit("max",t,!0,q.toString(n))}lt(t,n){return this.setLimit("max",t,!1,q.toString(n))}setLimit(t,n,o,r){return new e({...this._def,checks:[...this._def.checks,{kind:t,value:n,inclusive:o,message:q.toString(r)}]})}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}int(t){return this._addCheck({kind:"int",message:q.toString(t)})}positive(t){return this._addCheck({kind:"min",value:0,inclusive:!1,message:q.toString(t)})}negative(t){return this._addCheck({kind:"max",value:0,inclusive:!1,message:q.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:0,inclusive:!0,message:q.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:0,inclusive:!0,message:q.toString(t)})}multipleOf(t,n){return this._addCheck({kind:"multipleOf",value:t,message:q.toString(n)})}finite(t){return this._addCheck({kind:"finite",message:q.toString(t)})}safe(t){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:q.toString(t)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:q.toString(t)})}get minValue(){let t=null;for(let n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t}get maxValue(){let t=null;for(let n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t}get isInt(){return!!this._def.checks.find(t=>t.kind==="int"||t.kind==="multipleOf"&&ce.isInteger(t.value))}get isFinite(){let t=null,n=null;for(let o of this._def.checks){if(o.kind==="finite"||o.kind==="int"||o.kind==="multipleOf")return!0;o.kind==="min"?(n===null||o.value>n)&&(n=o.value):o.kind==="max"&&(t===null||o.value<t)&&(t=o.value)}return Number.isFinite(n)&&Number.isFinite(t)}};qo.create=e=>new qo({checks:[],typeName:O.ZodNumber,coerce:e?.coerce||!1,...Y(e)});var Vo=class e extends ne{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(t){if(this._def.coerce)try{t.data=BigInt(t.data)}catch{return this._getInvalidInput(t)}if(this._getType(t)!==U.bigint)return this._getInvalidInput(t);let o,r=new qe;for(let i of this._def.checks)i.kind==="min"?(i.inclusive?t.data<i.value:t.data<=i.value)&&(o=this._getOrReturnCtx(t,o),C(o,{code:T.too_small,type:"bigint",minimum:i.value,inclusive:i.inclusive,message:i.message}),r.dirty()):i.kind==="max"?(i.inclusive?t.data>i.value:t.data>=i.value)&&(o=this._getOrReturnCtx(t,o),C(o,{code:T.too_big,type:"bigint",maximum:i.value,inclusive:i.inclusive,message:i.message}),r.dirty()):i.kind==="multipleOf"?t.data%i.value!==BigInt(0)&&(o=this._getOrReturnCtx(t,o),C(o,{code:T.not_multiple_of,multipleOf:i.value,message:i.message}),r.dirty()):ce.assertNever(i);return{status:r.value,value:t.data}}_getInvalidInput(t){let n=this._getOrReturnCtx(t);return C(n,{code:T.invalid_type,expected:U.bigint,received:n.parsedType}),J}gte(t,n){return this.setLimit("min",t,!0,q.toString(n))}gt(t,n){return this.setLimit("min",t,!1,q.toString(n))}lte(t,n){return this.setLimit("max",t,!0,q.toString(n))}lt(t,n){return this.setLimit("max",t,!1,q.toString(n))}setLimit(t,n,o,r){return new e({...this._def,checks:[...this._def.checks,{kind:t,value:n,inclusive:o,message:q.toString(r)}]})}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}positive(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:q.toString(t)})}negative(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:q.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:q.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:q.toString(t)})}multipleOf(t,n){return this._addCheck({kind:"multipleOf",value:t,message:q.toString(n)})}get minValue(){let t=null;for(let n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t}get maxValue(){let t=null;for(let n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t}};Vo.create=e=>new Vo({checks:[],typeName:O.ZodBigInt,coerce:e?.coerce??!1,...Y(e)});var Fo=class extends ne{_parse(t){if(this._def.coerce&&(t.data=!!t.data),this._getType(t)!==U.boolean){let o=this._getOrReturnCtx(t);return C(o,{code:T.invalid_type,expected:U.boolean,received:o.parsedType}),J}return Ge(t.data)}};Fo.create=e=>new Fo({typeName:O.ZodBoolean,coerce:e?.coerce||!1,...Y(e)});var Bo=class e extends ne{_parse(t){if(this._def.coerce&&(t.data=new Date(t.data)),this._getType(t)!==U.date){let i=this._getOrReturnCtx(t);return C(i,{code:T.invalid_type,expected:U.date,received:i.parsedType}),J}if(Number.isNaN(t.data.getTime())){let i=this._getOrReturnCtx(t);return C(i,{code:T.invalid_date}),J}let o=new qe,r;for(let i of this._def.checks)i.kind==="min"?t.data.getTime()<i.value&&(r=this._getOrReturnCtx(t,r),C(r,{code:T.too_small,message:i.message,inclusive:!0,exact:!1,minimum:i.value,type:"date"}),o.dirty()):i.kind==="max"?t.data.getTime()>i.value&&(r=this._getOrReturnCtx(t,r),C(r,{code:T.too_big,message:i.message,inclusive:!0,exact:!1,maximum:i.value,type:"date"}),o.dirty()):ce.assertNever(i);return{status:o.value,value:new Date(t.data.getTime())}}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}min(t,n){return this._addCheck({kind:"min",value:t.getTime(),message:q.toString(n)})}max(t,n){return this._addCheck({kind:"max",value:t.getTime(),message:q.toString(n)})}get minDate(){let t=null;for(let n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t!=null?new Date(t):null}get maxDate(){let t=null;for(let n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t!=null?new Date(t):null}};Bo.create=e=>new Bo({checks:[],coerce:e?.coerce||!1,typeName:O.ZodDate,...Y(e)});var Ko=class extends ne{_parse(t){if(this._getType(t)!==U.symbol){let o=this._getOrReturnCtx(t);return C(o,{code:T.invalid_type,expected:U.symbol,received:o.parsedType}),J}return Ge(t.data)}};Ko.create=e=>new Ko({typeName:O.ZodSymbol,...Y(e)});var xn=class extends ne{_parse(t){if(this._getType(t)!==U.undefined){let o=this._getOrReturnCtx(t);return C(o,{code:T.invalid_type,expected:U.undefined,received:o.parsedType}),J}return Ge(t.data)}};xn.create=e=>new xn({typeName:O.ZodUndefined,...Y(e)});var wn=class extends ne{_parse(t){if(this._getType(t)!==U.null){let o=this._getOrReturnCtx(t);return C(o,{code:T.invalid_type,expected:U.null,received:o.parsedType}),J}return Ge(t.data)}};wn.create=e=>new wn({typeName:O.ZodNull,...Y(e)});var Ho=class extends ne{constructor(){super(...arguments),this._any=!0}_parse(t){return Ge(t.data)}};Ho.create=e=>new Ho({typeName:O.ZodAny,...Y(e)});var mr=class extends ne{constructor(){super(...arguments),this._unknown=!0}_parse(t){return Ge(t.data)}};mr.create=e=>new mr({typeName:O.ZodUnknown,...Y(e)});var Ct=class extends ne{_parse(t){let n=this._getOrReturnCtx(t);return C(n,{code:T.invalid_type,expected:U.never,received:n.parsedType}),J}};Ct.create=e=>new Ct({typeName:O.ZodNever,...Y(e)});var Jo=class extends ne{_parse(t){if(this._getType(t)!==U.undefined){let o=this._getOrReturnCtx(t);return C(o,{code:T.invalid_type,expected:U.void,received:o.parsedType}),J}return Ge(t.data)}};Jo.create=e=>new Jo({typeName:O.ZodVoid,...Y(e)});var hr=class e extends ne{_parse(t){let{ctx:n,status:o}=this._processInputParams(t),r=this._def;if(n.parsedType!==U.array)return C(n,{code:T.invalid_type,expected:U.array,received:n.parsedType}),J;if(r.exactLength!==null){let a=n.data.length>r.exactLength.value,s=n.data.length<r.exactLength.value;(a||s)&&(C(n,{code:a?T.too_big:T.too_small,minimum:s?r.exactLength.value:void 0,maximum:a?r.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:r.exactLength.message}),o.dirty())}if(r.minLength!==null&&n.data.length<r.minLength.value&&(C(n,{code:T.too_small,minimum:r.minLength.value,type:"array",inclusive:!0,exact:!1,message:r.minLength.message}),o.dirty()),r.maxLength!==null&&n.data.length>r.maxLength.value&&(C(n,{code:T.too_big,maximum:r.maxLength.value,type:"array",inclusive:!0,exact:!1,message:r.maxLength.message}),o.dirty()),n.common.async)return Promise.all([...n.data].map((a,s)=>r.type._parseAsync(new gt(n,a,n.path,s)))).then(a=>qe.mergeArray(o,a));let i=[...n.data].map((a,s)=>r.type._parseSync(new gt(n,a,n.path,s)));return qe.mergeArray(o,i)}get element(){return this._def.type}min(t,n){return new e({...this._def,minLength:{value:t,message:q.toString(n)}})}max(t,n){return new e({...this._def,maxLength:{value:t,message:q.toString(n)}})}length(t,n){return new e({...this._def,exactLength:{value:t,message:q.toString(n)}})}nonempty(t){return this.min(1,t)}};hr.create=(e,t)=>new hr({type:e,minLength:null,maxLength:null,exactLength:null,typeName:O.ZodArray,...Y(t)});function bn(e){if(e instanceof lt){let t={};for(let n in e.shape){let o=e.shape[n];t[n]=zt.create(bn(o))}return new lt({...e._def,shape:()=>t})}else return e instanceof hr?new hr({...e._def,type:bn(e.element)}):e instanceof zt?zt.create(bn(e.unwrap())):e instanceof er?er.create(bn(e.unwrap())):e instanceof Qt?Qt.create(e.items.map(t=>bn(t))):e}var lt=class e extends ne{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;let t=this._def.shape(),n=ce.objectKeys(t);return this._cached={shape:t,keys:n},this._cached}_parse(t){if(this._getType(t)!==U.object){let l=this._getOrReturnCtx(t);return C(l,{code:T.invalid_type,expected:U.object,received:l.parsedType}),J}let{status:o,ctx:r}=this._processInputParams(t),{shape:i,keys:a}=this._getCached(),s=[];if(!(this._def.catchall instanceof Ct&&this._def.unknownKeys==="strip"))for(let l in r.data)a.includes(l)||s.push(l);let c=[];for(let l of a){let d=i[l],f=r.data[l];c.push({key:{status:"valid",value:l},value:d._parse(new gt(r,f,r.path,l)),alwaysSet:l in r.data})}if(this._def.catchall instanceof Ct){let l=this._def.unknownKeys;if(l==="passthrough")for(let d of s)c.push({key:{status:"valid",value:d},value:{status:"valid",value:r.data[d]}});else if(l==="strict")s.length>0&&(C(r,{code:T.unrecognized_keys,keys:s}),o.dirty());else if(l!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{let l=this._def.catchall;for(let d of s){let f=r.data[d];c.push({key:{status:"valid",value:d},value:l._parse(new gt(r,f,r.path,d)),alwaysSet:d in r.data})}}return r.common.async?Promise.resolve().then(async()=>{let l=[];for(let d of c){let f=await d.key,_=await d.value;l.push({key:f,value:_,alwaysSet:d.alwaysSet})}return l}).then(l=>qe.mergeObjectSync(o,l)):qe.mergeObjectSync(o,c)}get shape(){return this._def.shape()}strict(t){return q.errToObj,new e({...this._def,unknownKeys:"strict",...t!==void 0?{errorMap:(n,o)=>{let r=this._def.errorMap?.(n,o).message??o.defaultError;return n.code==="unrecognized_keys"?{message:q.errToObj(t).message??r}:{message:r}}}:{}})}strip(){return new e({...this._def,unknownKeys:"strip"})}passthrough(){return new e({...this._def,unknownKeys:"passthrough"})}extend(t){return new e({...this._def,shape:()=>({...this._def.shape(),...t})})}merge(t){return new e({unknownKeys:t._def.unknownKeys,catchall:t._def.catchall,shape:()=>({...this._def.shape(),...t._def.shape()}),typeName:O.ZodObject})}setKey(t,n){return this.augment({[t]:n})}catchall(t){return new e({...this._def,catchall:t})}pick(t){let n={};for(let o of ce.objectKeys(t))t[o]&&this.shape[o]&&(n[o]=this.shape[o]);return new e({...this._def,shape:()=>n})}omit(t){let n={};for(let o of ce.objectKeys(this.shape))t[o]||(n[o]=this.shape[o]);return new e({...this._def,shape:()=>n})}deepPartial(){return bn(this)}partial(t){let n={};for(let o of ce.objectKeys(this.shape)){let r=this.shape[o];t&&!t[o]?n[o]=r:n[o]=r.optional()}return new e({...this._def,shape:()=>n})}required(t){let n={};for(let o of ce.objectKeys(this.shape))if(t&&!t[o])n[o]=this.shape[o];else{let i=this.shape[o];for(;i instanceof zt;)i=i._def.innerType;n[o]=i}return new e({...this._def,shape:()=>n})}keyof(){return Hg(ce.objectKeys(this.shape))}};lt.create=(e,t)=>new lt({shape:()=>e,unknownKeys:"strip",catchall:Ct.create(),typeName:O.ZodObject,...Y(t)});lt.strictCreate=(e,t)=>new lt({shape:()=>e,unknownKeys:"strict",catchall:Ct.create(),typeName:O.ZodObject,...Y(t)});lt.lazycreate=(e,t)=>new lt({shape:e,unknownKeys:"strip",catchall:Ct.create(),typeName:O.ZodObject,...Y(t)});var kn=class extends ne{_parse(t){let{ctx:n}=this._processInputParams(t),o=this._def.options;function r(i){for(let s of i)if(s.result.status==="valid")return s.result;for(let s of i)if(s.result.status==="dirty")return n.common.issues.push(...s.ctx.common.issues),s.result;let a=i.map(s=>new ut(s.ctx.common.issues));return C(n,{code:T.invalid_union,unionErrors:a}),J}if(n.common.async)return Promise.all(o.map(async i=>{let a={...n,common:{...n.common,issues:[]},parent:null};return{result:await i._parseAsync({data:n.data,path:n.path,parent:a}),ctx:a}})).then(r);{let i,a=[];for(let c of o){let l={...n,common:{...n.common,issues:[]},parent:null},d=c._parseSync({data:n.data,path:n.path,parent:l});if(d.status==="valid")return d;d.status==="dirty"&&!i&&(i={result:d,ctx:l}),l.common.issues.length&&a.push(l.common.issues)}if(i)return n.common.issues.push(...i.ctx.common.issues),i.result;let s=a.map(c=>new ut(c));return C(n,{code:T.invalid_union,unionErrors:s}),J}}get options(){return this._def.options}};kn.create=(e,t)=>new kn({options:e,typeName:O.ZodUnion,...Y(t)});var Yt=e=>e instanceof zn?Yt(e.schema):e instanceof It?Yt(e.innerType()):e instanceof In?[e.value]:e instanceof En?e.options:e instanceof Tn?ce.objectValues(e.enum):e instanceof Pn?Yt(e._def.innerType):e instanceof xn?[void 0]:e instanceof wn?[null]:e instanceof zt?[void 0,...Yt(e.unwrap())]:e instanceof er?[null,...Yt(e.unwrap())]:e instanceof Xa||e instanceof jn?Yt(e.unwrap()):e instanceof On?Yt(e._def.innerType):[],zd=class e extends ne{_parse(t){let{ctx:n}=this._processInputParams(t);if(n.parsedType!==U.object)return C(n,{code:T.invalid_type,expected:U.object,received:n.parsedType}),J;let o=this.discriminator,r=n.data[o],i=this.optionsMap.get(r);return i?n.common.async?i._parseAsync({data:n.data,path:n.path,parent:n}):i._parseSync({data:n.data,path:n.path,parent:n}):(C(n,{code:T.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[o]}),J)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(t,n,o){let r=new Map;for(let i of n){let a=Yt(i.shape[t]);if(!a.length)throw new Error(`A discriminator value for key \`${t}\` could not be extracted from all schema options`);for(let s of a){if(r.has(s))throw new Error(`Discriminator property ${String(t)} has duplicate value ${String(s)}`);r.set(s,i)}}return new e({typeName:O.ZodDiscriminatedUnion,discriminator:t,options:n,optionsMap:r,...Y(o)})}};function Id(e,t){let n=Xt(e),o=Xt(t);if(e===t)return{valid:!0,data:e};if(n===U.object&&o===U.object){let r=ce.objectKeys(t),i=ce.objectKeys(e).filter(s=>r.indexOf(s)!==-1),a={...e,...t};for(let s of i){let c=Id(e[s],t[s]);if(!c.valid)return{valid:!1};a[s]=c.data}return{valid:!0,data:a}}else if(n===U.array&&o===U.array){if(e.length!==t.length)return{valid:!1};let r=[];for(let i=0;i<e.length;i++){let a=e[i],s=t[i],c=Id(a,s);if(!c.valid)return{valid:!1};r.push(c.data)}return{valid:!0,data:r}}else return n===U.date&&o===U.date&&+e==+t?{valid:!0,data:e}:{valid:!1}}var Sn=class extends ne{_parse(t){let{status:n,ctx:o}=this._processInputParams(t),r=(i,a)=>{if(wd(i)||wd(a))return J;let s=Id(i.value,a.value);return s.valid?((kd(i)||kd(a))&&n.dirty(),{status:n.value,value:s.data}):(C(o,{code:T.invalid_intersection_types}),J)};return o.common.async?Promise.all([this._def.left._parseAsync({data:o.data,path:o.path,parent:o}),this._def.right._parseAsync({data:o.data,path:o.path,parent:o})]).then(([i,a])=>r(i,a)):r(this._def.left._parseSync({data:o.data,path:o.path,parent:o}),this._def.right._parseSync({data:o.data,path:o.path,parent:o}))}};Sn.create=(e,t,n)=>new Sn({left:e,right:t,typeName:O.ZodIntersection,...Y(n)});var Qt=class e extends ne{_parse(t){let{status:n,ctx:o}=this._processInputParams(t);if(o.parsedType!==U.array)return C(o,{code:T.invalid_type,expected:U.array,received:o.parsedType}),J;if(o.data.length<this._def.items.length)return C(o,{code:T.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),J;!this._def.rest&&o.data.length>this._def.items.length&&(C(o,{code:T.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),n.dirty());let i=[...o.data].map((a,s)=>{let c=this._def.items[s]||this._def.rest;return c?c._parse(new gt(o,a,o.path,s)):null}).filter(a=>!!a);return o.common.async?Promise.all(i).then(a=>qe.mergeArray(n,a)):qe.mergeArray(n,i)}get items(){return this._def.items}rest(t){return new e({...this._def,rest:t})}};Qt.create=(e,t)=>{if(!Array.isArray(e))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new Qt({items:e,typeName:O.ZodTuple,rest:null,...Y(t)})};var Ed=class e extends ne{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){let{status:n,ctx:o}=this._processInputParams(t);if(o.parsedType!==U.object)return C(o,{code:T.invalid_type,expected:U.object,received:o.parsedType}),J;let r=[],i=this._def.keyType,a=this._def.valueType;for(let s in o.data)r.push({key:i._parse(new gt(o,s,o.path,s)),value:a._parse(new gt(o,o.data[s],o.path,s)),alwaysSet:s in o.data});return o.common.async?qe.mergeObjectAsync(n,r):qe.mergeObjectSync(n,r)}get element(){return this._def.valueType}static create(t,n,o){return n instanceof ne?new e({keyType:t,valueType:n,typeName:O.ZodRecord,...Y(o)}):new e({keyType:$n.create(),valueType:t,typeName:O.ZodRecord,...Y(n)})}},Go=class extends ne{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){let{status:n,ctx:o}=this._processInputParams(t);if(o.parsedType!==U.map)return C(o,{code:T.invalid_type,expected:U.map,received:o.parsedType}),J;let r=this._def.keyType,i=this._def.valueType,a=[...o.data.entries()].map(([s,c],l)=>({key:r._parse(new gt(o,s,o.path,[l,"key"])),value:i._parse(new gt(o,c,o.path,[l,"value"]))}));if(o.common.async){let s=new Map;return Promise.resolve().then(async()=>{for(let c of a){let l=await c.key,d=await c.value;if(l.status==="aborted"||d.status==="aborted")return J;(l.status==="dirty"||d.status==="dirty")&&n.dirty(),s.set(l.value,d.value)}return{status:n.value,value:s}})}else{let s=new Map;for(let c of a){let l=c.key,d=c.value;if(l.status==="aborted"||d.status==="aborted")return J;(l.status==="dirty"||d.status==="dirty")&&n.dirty(),s.set(l.value,d.value)}return{status:n.value,value:s}}}};Go.create=(e,t,n)=>new Go({valueType:t,keyType:e,typeName:O.ZodMap,...Y(n)});var Wo=class e extends ne{_parse(t){let{status:n,ctx:o}=this._processInputParams(t);if(o.parsedType!==U.set)return C(o,{code:T.invalid_type,expected:U.set,received:o.parsedType}),J;let r=this._def;r.minSize!==null&&o.data.size<r.minSize.value&&(C(o,{code:T.too_small,minimum:r.minSize.value,type:"set",inclusive:!0,exact:!1,message:r.minSize.message}),n.dirty()),r.maxSize!==null&&o.data.size>r.maxSize.value&&(C(o,{code:T.too_big,maximum:r.maxSize.value,type:"set",inclusive:!0,exact:!1,message:r.maxSize.message}),n.dirty());let i=this._def.valueType;function a(c){let l=new Set;for(let d of c){if(d.status==="aborted")return J;d.status==="dirty"&&n.dirty(),l.add(d.value)}return{status:n.value,value:l}}let s=[...o.data.values()].map((c,l)=>i._parse(new gt(o,c,o.path,l)));return o.common.async?Promise.all(s).then(c=>a(c)):a(s)}min(t,n){return new e({...this._def,minSize:{value:t,message:q.toString(n)}})}max(t,n){return new e({...this._def,maxSize:{value:t,message:q.toString(n)}})}size(t,n){return this.min(t,n).max(t,n)}nonempty(t){return this.min(1,t)}};Wo.create=(e,t)=>new Wo({valueType:e,minSize:null,maxSize:null,typeName:O.ZodSet,...Y(t)});var Td=class e extends ne{constructor(){super(...arguments),this.validate=this.implement}_parse(t){let{ctx:n}=this._processInputParams(t);if(n.parsedType!==U.function)return C(n,{code:T.invalid_type,expected:U.function,received:n.parsedType}),J;function o(s,c){return Wa({data:s,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,Mo(),pr].filter(l=>!!l),issueData:{code:T.invalid_arguments,argumentsError:c}})}function r(s,c){return Wa({data:s,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,Mo(),pr].filter(l=>!!l),issueData:{code:T.invalid_return_type,returnTypeError:c}})}let i={errorMap:n.common.contextualErrorMap},a=n.data;if(this._def.returns instanceof Kr){let s=this;return Ge(async function(...c){let l=new ut([]),d=await s._def.args.parseAsync(c,i).catch(v=>{throw l.addIssue(o(c,v)),l}),f=await Reflect.apply(a,this,d);return await s._def.returns._def.type.parseAsync(f,i).catch(v=>{throw l.addIssue(r(f,v)),l})})}else{let s=this;return Ge(function(...c){let l=s._def.args.safeParse(c,i);if(!l.success)throw new ut([o(c,l.error)]);let d=Reflect.apply(a,this,l.data),f=s._def.returns.safeParse(d,i);if(!f.success)throw new ut([r(d,f.error)]);return f.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...t){return new e({...this._def,args:Qt.create(t).rest(mr.create())})}returns(t){return new e({...this._def,returns:t})}implement(t){return this.parse(t)}strictImplement(t){return this.parse(t)}static create(t,n,o){return new e({args:t||Qt.create([]).rest(mr.create()),returns:n||mr.create(),typeName:O.ZodFunction,...Y(o)})}},zn=class extends ne{get schema(){return this._def.getter()}_parse(t){let{ctx:n}=this._processInputParams(t);return this._def.getter()._parse({data:n.data,path:n.path,parent:n})}};zn.create=(e,t)=>new zn({getter:e,typeName:O.ZodLazy,...Y(t)});var In=class extends ne{_parse(t){if(t.data!==this._def.value){let n=this._getOrReturnCtx(t);return C(n,{received:n.data,code:T.invalid_literal,expected:this._def.value}),J}return{status:"valid",value:t.data}}get value(){return this._def.value}};In.create=(e,t)=>new In({value:e,typeName:O.ZodLiteral,...Y(t)});function Hg(e,t){return new En({values:e,typeName:O.ZodEnum,...Y(t)})}var En=class e extends ne{_parse(t){if(typeof t.data!="string"){let n=this._getOrReturnCtx(t),o=this._def.values;return C(n,{expected:ce.joinValues(o),received:n.parsedType,code:T.invalid_type}),J}if(this._cache||(this._cache=new Set(this._def.values)),!this._cache.has(t.data)){let n=this._getOrReturnCtx(t),o=this._def.values;return C(n,{received:n.data,code:T.invalid_enum_value,options:o}),J}return Ge(t.data)}get options(){return this._def.values}get enum(){let t={};for(let n of this._def.values)t[n]=n;return t}get Values(){let t={};for(let n of this._def.values)t[n]=n;return t}get Enum(){let t={};for(let n of this._def.values)t[n]=n;return t}extract(t,n=this._def){return e.create(t,{...this._def,...n})}exclude(t,n=this._def){return e.create(this.options.filter(o=>!t.includes(o)),{...this._def,...n})}};En.create=Hg;var Tn=class extends ne{_parse(t){let n=ce.getValidEnumValues(this._def.values),o=this._getOrReturnCtx(t);if(o.parsedType!==U.string&&o.parsedType!==U.number){let r=ce.objectValues(n);return C(o,{expected:ce.joinValues(r),received:o.parsedType,code:T.invalid_type}),J}if(this._cache||(this._cache=new Set(ce.getValidEnumValues(this._def.values))),!this._cache.has(t.data)){let r=ce.objectValues(n);return C(o,{received:o.data,code:T.invalid_enum_value,options:r}),J}return Ge(t.data)}get enum(){return this._def.values}};Tn.create=(e,t)=>new Tn({values:e,typeName:O.ZodNativeEnum,...Y(t)});var Kr=class extends ne{unwrap(){return this._def.type}_parse(t){let{ctx:n}=this._processInputParams(t);if(n.parsedType!==U.promise&&n.common.async===!1)return C(n,{code:T.invalid_type,expected:U.promise,received:n.parsedType}),J;let o=n.parsedType===U.promise?n.data:Promise.resolve(n.data);return Ge(o.then(r=>this._def.type.parseAsync(r,{path:n.path,errorMap:n.common.contextualErrorMap})))}};Kr.create=(e,t)=>new Kr({type:e,typeName:O.ZodPromise,...Y(t)});var It=class extends ne{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===O.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(t){let{status:n,ctx:o}=this._processInputParams(t),r=this._def.effect||null,i={addIssue:a=>{C(o,a),a.fatal?n.abort():n.dirty()},get path(){return o.path}};if(i.addIssue=i.addIssue.bind(i),r.type==="preprocess"){let a=r.transform(o.data,i);if(o.common.async)return Promise.resolve(a).then(async s=>{if(n.value==="aborted")return J;let c=await this._def.schema._parseAsync({data:s,path:o.path,parent:o});return c.status==="aborted"?J:c.status==="dirty"?yn(c.value):n.value==="dirty"?yn(c.value):c});{if(n.value==="aborted")return J;let s=this._def.schema._parseSync({data:a,path:o.path,parent:o});return s.status==="aborted"?J:s.status==="dirty"?yn(s.value):n.value==="dirty"?yn(s.value):s}}if(r.type==="refinement"){let a=s=>{let c=r.refinement(s,i);if(o.common.async)return Promise.resolve(c);if(c instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return s};if(o.common.async===!1){let s=this._def.schema._parseSync({data:o.data,path:o.path,parent:o});return s.status==="aborted"?J:(s.status==="dirty"&&n.dirty(),a(s.value),{status:n.value,value:s.value})}else return this._def.schema._parseAsync({data:o.data,path:o.path,parent:o}).then(s=>s.status==="aborted"?J:(s.status==="dirty"&&n.dirty(),a(s.value).then(()=>({status:n.value,value:s.value}))))}if(r.type==="transform")if(o.common.async===!1){let a=this._def.schema._parseSync({data:o.data,path:o.path,parent:o});if(!Br(a))return J;let s=r.transform(a.value,i);if(s instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:n.value,value:s}}else return this._def.schema._parseAsync({data:o.data,path:o.path,parent:o}).then(a=>Br(a)?Promise.resolve(r.transform(a.value,i)).then(s=>({status:n.value,value:s})):J);ce.assertNever(r)}};It.create=(e,t,n)=>new It({schema:e,typeName:O.ZodEffects,effect:t,...Y(n)});It.createWithPreprocess=(e,t,n)=>new It({schema:t,effect:{type:"preprocess",transform:e},typeName:O.ZodEffects,...Y(n)});var zt=class extends ne{_parse(t){return this._getType(t)===U.undefined?Ge(void 0):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}};zt.create=(e,t)=>new zt({innerType:e,typeName:O.ZodOptional,...Y(t)});var er=class extends ne{_parse(t){return this._getType(t)===U.null?Ge(null):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}};er.create=(e,t)=>new er({innerType:e,typeName:O.ZodNullable,...Y(t)});var Pn=class extends ne{_parse(t){let{ctx:n}=this._processInputParams(t),o=n.data;return n.parsedType===U.undefined&&(o=this._def.defaultValue()),this._def.innerType._parse({data:o,path:n.path,parent:n})}removeDefault(){return this._def.innerType}};Pn.create=(e,t)=>new Pn({innerType:e,typeName:O.ZodDefault,defaultValue:typeof t.default=="function"?t.default:()=>t.default,...Y(t)});var On=class extends ne{_parse(t){let{ctx:n}=this._processInputParams(t),o={...n,common:{...n.common,issues:[]}},r=this._def.innerType._parse({data:o.data,path:o.path,parent:{...o}});return Lo(r)?r.then(i=>({status:"valid",value:i.status==="valid"?i.value:this._def.catchValue({get error(){return new ut(o.common.issues)},input:o.data})})):{status:"valid",value:r.status==="valid"?r.value:this._def.catchValue({get error(){return new ut(o.common.issues)},input:o.data})}}removeCatch(){return this._def.innerType}};On.create=(e,t)=>new On({innerType:e,typeName:O.ZodCatch,catchValue:typeof t.catch=="function"?t.catch:()=>t.catch,...Y(t)});var Xo=class extends ne{_parse(t){if(this._getType(t)!==U.nan){let o=this._getOrReturnCtx(t);return C(o,{code:T.invalid_type,expected:U.nan,received:o.parsedType}),J}return{status:"valid",value:t.data}}};Xo.create=e=>new Xo({typeName:O.ZodNaN,...Y(e)});var Xa=class extends ne{_parse(t){let{ctx:n}=this._processInputParams(t),o=n.data;return this._def.type._parse({data:o,path:n.path,parent:n})}unwrap(){return this._def.type}},Ya=class e extends ne{_parse(t){let{status:n,ctx:o}=this._processInputParams(t);if(o.common.async)return(async()=>{let i=await this._def.in._parseAsync({data:o.data,path:o.path,parent:o});return i.status==="aborted"?J:i.status==="dirty"?(n.dirty(),yn(i.value)):this._def.out._parseAsync({data:i.value,path:o.path,parent:o})})();{let r=this._def.in._parseSync({data:o.data,path:o.path,parent:o});return r.status==="aborted"?J:r.status==="dirty"?(n.dirty(),{status:"dirty",value:r.value}):this._def.out._parseSync({data:r.value,path:o.path,parent:o})}}static create(t,n){return new e({in:t,out:n,typeName:O.ZodPipeline})}},jn=class extends ne{_parse(t){let n=this._def.innerType._parse(t),o=r=>(Br(r)&&(r.value=Object.freeze(r.value)),r);return Lo(n)?n.then(r=>o(r)):o(n)}unwrap(){return this._def.innerType}};jn.create=(e,t)=>new jn({innerType:e,typeName:O.ZodReadonly,...Y(t)});var sD={object:lt.lazycreate},O;(function(e){e.ZodString="ZodString",e.ZodNumber="ZodNumber",e.ZodNaN="ZodNaN",e.ZodBigInt="ZodBigInt",e.ZodBoolean="ZodBoolean",e.ZodDate="ZodDate",e.ZodSymbol="ZodSymbol",e.ZodUndefined="ZodUndefined",e.ZodNull="ZodNull",e.ZodAny="ZodAny",e.ZodUnknown="ZodUnknown",e.ZodNever="ZodNever",e.ZodVoid="ZodVoid",e.ZodArray="ZodArray",e.ZodObject="ZodObject",e.ZodUnion="ZodUnion",e.ZodDiscriminatedUnion="ZodDiscriminatedUnion",e.ZodIntersection="ZodIntersection",e.ZodTuple="ZodTuple",e.ZodRecord="ZodRecord",e.ZodMap="ZodMap",e.ZodSet="ZodSet",e.ZodFunction="ZodFunction",e.ZodLazy="ZodLazy",e.ZodLiteral="ZodLiteral",e.ZodEnum="ZodEnum",e.ZodEffects="ZodEffects",e.ZodNativeEnum="ZodNativeEnum",e.ZodOptional="ZodOptional",e.ZodNullable="ZodNullable",e.ZodDefault="ZodDefault",e.ZodCatch="ZodCatch",e.ZodPromise="ZodPromise",e.ZodBranded="ZodBranded",e.ZodPipeline="ZodPipeline",e.ZodReadonly="ZodReadonly"})(O||(O={}));var cD=$n.create,uD=qo.create,lD=Xo.create,dD=Vo.create,fD=Fo.create,pD=Bo.create,mD=Ko.create,hD=xn.create,gD=wn.create,vD=Ho.create,_D=mr.create,yD=Ct.create,bD=Jo.create,$D=hr.create,Jg=lt.create,xD=lt.strictCreate,wD=kn.create,kD=zd.create,SD=Sn.create,zD=Qt.create,ID=Ed.create,ED=Go.create,TD=Wo.create,PD=Td.create,OD=zn.create,jD=In.create,ND=En.create,RD=Tn.create,AD=Kr.create,DD=It.create,CD=zt.create,UD=er.create,ZD=It.createWithPreprocess,MD=Ya.create;var pt={};Fr(pt,{$ZodAny:()=>Gs,$ZodArray:()=>ec,$ZodAsyncError:()=>Et,$ZodBase64:()=>Zs,$ZodBase64URL:()=>Ms,$ZodBigInt:()=>di,$ZodBigIntFormat:()=>Bs,$ZodBoolean:()=>Vn,$ZodCIDRv4:()=>Cs,$ZodCIDRv6:()=>Us,$ZodCUID:()=>zs,$ZodCUID2:()=>Is,$ZodCatch:()=>vc,$ZodCheck:()=>$e,$ZodCheckBigIntFormat:()=>vf,$ZodCheckEndsWith:()=>Tf,$ZodCheckGreaterThan:()=>ms,$ZodCheckIncludes:()=>If,$ZodCheckLengthEquals:()=>wf,$ZodCheckLessThan:()=>ps,$ZodCheckLowerCase:()=>Sf,$ZodCheckMaxLength:()=>$f,$ZodCheckMaxSize:()=>_f,$ZodCheckMimeType:()=>Of,$ZodCheckMinLength:()=>xf,$ZodCheckMinSize:()=>yf,$ZodCheckMultipleOf:()=>hf,$ZodCheckNumberFormat:()=>gf,$ZodCheckOverwrite:()=>jf,$ZodCheckProperty:()=>Pf,$ZodCheckRegex:()=>kf,$ZodCheckSizeEquals:()=>bf,$ZodCheckStartsWith:()=>Ef,$ZodCheckStringFormat:()=>qn,$ZodCheckUpperCase:()=>zf,$ZodCodec:()=>Fn,$ZodCustom:()=>Sc,$ZodCustomStringFormat:()=>Vs,$ZodDate:()=>Qs,$ZodDefault:()=>pc,$ZodDiscriminatedUnion:()=>rc,$ZodE164:()=>Ls,$ZodEmail:()=>xs,$ZodEmoji:()=>ks,$ZodEncodeError:()=>gr,$ZodEnum:()=>sc,$ZodError:()=>ai,$ZodFile:()=>uc,$ZodFunction:()=>xc,$ZodGUID:()=>bs,$ZodIPv4:()=>As,$ZodIPv6:()=>Ds,$ZodISODate:()=>js,$ZodISODateTime:()=>Os,$ZodISODuration:()=>Rs,$ZodISOTime:()=>Ns,$ZodIntersection:()=>nc,$ZodJWT:()=>qs,$ZodKSUID:()=>Ps,$ZodLazy:()=>kc,$ZodLiteral:()=>cc,$ZodMap:()=>ic,$ZodNaN:()=>_c,$ZodNanoID:()=>Ss,$ZodNever:()=>Xs,$ZodNonOptional:()=>hc,$ZodNull:()=>Js,$ZodNullable:()=>fc,$ZodNumber:()=>li,$ZodNumberFormat:()=>Fs,$ZodObject:()=>tc,$ZodObjectJIT:()=>Df,$ZodOptional:()=>dc,$ZodPipe:()=>yc,$ZodPrefault:()=>mc,$ZodPromise:()=>wc,$ZodReadonly:()=>bc,$ZodRealError:()=>et,$ZodRecord:()=>oc,$ZodRegistry:()=>Kn,$ZodSet:()=>ac,$ZodString:()=>kr,$ZodStringFormat:()=>ge,$ZodSuccess:()=>gc,$ZodSymbol:()=>Ks,$ZodTemplateLiteral:()=>$c,$ZodTransform:()=>lc,$ZodTuple:()=>pi,$ZodType:()=>W,$ZodULID:()=>Es,$ZodURL:()=>ws,$ZodUUID:()=>$s,$ZodUndefined:()=>Hs,$ZodUnion:()=>fi,$ZodUnknown:()=>Ws,$ZodVoid:()=>Ys,$ZodXID:()=>Ts,$brand:()=>Qo,$constructor:()=>$,$input:()=>Pc,$output:()=>Tc,Doc:()=>ui,JSONSchema:()=>$_,JSONSchemaGenerator:()=>Ci,NEVER:()=>Qa,TimePrecision:()=>Nc,_any:()=>eu,_array:()=>Cf,_base64:()=>Ni,_base64url:()=>Ri,_bigint:()=>Hc,_boolean:()=>Bc,_catch:()=>jI,_check:()=>b_,_cidrv4:()=>Oi,_cidrv6:()=>ji,_coercedBigint:()=>Jc,_coercedBoolean:()=>Kc,_coercedDate:()=>iu,_coercedNumber:()=>Zc,_coercedString:()=>jc,_cuid:()=>ki,_cuid2:()=>Si,_custom:()=>pu,_date:()=>ou,_decode:()=>is,_decodeAsync:()=>ss,_default:()=>TI,_discriminatedUnion:()=>vI,_e164:()=>Ai,_email:()=>vi,_emoji:()=>xi,_encode:()=>os,_encodeAsync:()=>as,_endsWith:()=>to,_enum:()=>wI,_file:()=>fu,_float32:()=>Lc,_float64:()=>qc,_gt:()=>Mt,_gte:()=>Ve,_guid:()=>Hn,_includes:()=>Qn,_int:()=>Mc,_int32:()=>Vc,_int64:()=>Gc,_intersection:()=>_I,_ipv4:()=>Ti,_ipv6:()=>Pi,_isoDate:()=>Ac,_isoDateTime:()=>Rc,_isoDuration:()=>Cc,_isoTime:()=>Dc,_jwt:()=>Di,_ksuid:()=>Ei,_lazy:()=>DI,_length:()=>Qr,_literal:()=>SI,_lowercase:()=>Xn,_lt:()=>Zt,_lte:()=>rt,_map:()=>$I,_max:()=>rt,_maxLength:()=>Yr,_maxSize:()=>Xr,_mime:()=>ro,_min:()=>Ve,_minLength:()=>tr,_minSize:()=>zr,_multipleOf:()=>Sr,_nan:()=>au,_nanoid:()=>wi,_nativeEnum:()=>kI,_negative:()=>cu,_never:()=>ru,_nonnegative:()=>lu,_nonoptional:()=>PI,_nonpositive:()=>uu,_normalize:()=>no,_null:()=>Qc,_nullable:()=>EI,_number:()=>Uc,_optional:()=>II,_overwrite:()=>Lt,_parse:()=>Un,_parseAsync:()=>Zn,_pipe:()=>NI,_positive:()=>su,_promise:()=>CI,_property:()=>du,_readonly:()=>RI,_record:()=>bI,_refine:()=>mu,_regex:()=>Wn,_safeDecode:()=>us,_safeDecodeAsync:()=>ds,_safeEncode:()=>cs,_safeEncodeAsync:()=>ls,_safeParse:()=>Mn,_safeParseAsync:()=>Ln,_set:()=>xI,_size:()=>Gn,_startsWith:()=>eo,_string:()=>Oc,_stringFormat:()=>en,_stringbool:()=>gu,_success:()=>OI,_superRefine:()=>hu,_symbol:()=>Xc,_templateLiteral:()=>AI,_toLowerCase:()=>io,_toUpperCase:()=>ao,_transform:()=>zI,_trim:()=>oo,_tuple:()=>yI,_uint32:()=>Fc,_uint64:()=>Wc,_ulid:()=>zi,_undefined:()=>Yc,_union:()=>gI,_unknown:()=>tu,_uppercase:()=>Yn,_url:()=>Jn,_uuid:()=>_i,_uuidv4:()=>yi,_uuidv6:()=>bi,_uuidv7:()=>$i,_void:()=>nu,_xid:()=>Ii,clone:()=>Ne,config:()=>Ee,decode:()=>tv,decodeAsync:()=>nv,encode:()=>ev,encodeAsync:()=>rv,flattenError:()=>Dn,formatError:()=>Cn,globalConfig:()=>Yo,globalRegistry:()=>Tt,isValidBase64:()=>Af,isValidBase64URL:()=>kv,isValidJWT:()=>Sv,locales:()=>Bn,parse:()=>Jr,parseAsync:()=>Gr,prettifyError:()=>ns,regexes:()=>tt,registry:()=>gi,safeDecode:()=>iv,safeDecodeAsync:()=>sv,safeEncode:()=>ov,safeEncodeAsync:()=>av,safeParse:()=>xr,safeParseAsync:()=>wr,toDotPath:()=>Qg,toJSONSchema:()=>so,treeifyError:()=>rs,util:()=>E,version:()=>Nf});var Qa=Object.freeze({status:"aborted"});function $(e,t,n){function o(s,c){var l;Object.defineProperty(s,"_zod",{value:s._zod??{},enumerable:!1}),(l=s._zod).traits??(l.traits=new Set),s._zod.traits.add(e),t(s,c);for(let d in a.prototype)d in s||Object.defineProperty(s,d,{value:a.prototype[d].bind(s)});s._zod.constr=a,s._zod.def=c}let r=n?.Parent??Object;class i extends r{}Object.defineProperty(i,"name",{value:e});function a(s){var c;let l=n?.Parent?new i:this;o(l,s),(c=l._zod).deferred??(c.deferred=[]);for(let d of l._zod.deferred)d();return l}return Object.defineProperty(a,"init",{value:o}),Object.defineProperty(a,Symbol.hasInstance,{value:s=>n?.Parent&&s instanceof n.Parent?!0:s?._zod?.traits?.has(e)}),Object.defineProperty(a,"name",{value:e}),a}var Qo=Symbol("zod_brand"),Et=class extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}},gr=class extends Error{constructor(t){super(`Encountered unidirectional transform during encode: ${t}`),this.name="ZodEncodeError"}},Yo={};function Ee(e){return e&&Object.assign(Yo,e),Yo}var E={};Fr(E,{BIGINT_FORMAT_RANGES:()=>Ud,Class:()=>Od,NUMBER_FORMAT_RANGES:()=>Cd,aborted:()=>$r,allowsEval:()=>Nd,assert:()=>S0,assertEqual:()=>$0,assertIs:()=>w0,assertNever:()=>k0,assertNotEqual:()=>x0,assignProp:()=>_r,base64ToUint8Array:()=>Wg,base64urlToUint8Array:()=>q0,cached:()=>Rn,captureStackTrace:()=>ts,cleanEnum:()=>L0,cleanRegex:()=>ri,clone:()=>Ne,cloneDef:()=>I0,createTransparentProxy:()=>N0,defineLazy:()=>se,esc:()=>es,escapeRegex:()=>Ut,extend:()=>D0,finalizeIssue:()=>ft,floatSafeRemainder:()=>jd,getElementAtPath:()=>E0,getEnumValues:()=>ti,getLengthableOrigin:()=>ii,getParsedType:()=>j0,getSizableOrigin:()=>oi,hexToUint8Array:()=>F0,isObject:()=>Hr,isPlainObject:()=>br,issue:()=>An,joinValues:()=>S,jsonStringifyReplacer:()=>Nn,merge:()=>U0,mergeDefs:()=>yr,normalizeParams:()=>N,nullish:()=>vr,numKeys:()=>O0,objectClone:()=>z0,omit:()=>A0,optionalKeys:()=>Dd,partial:()=>Z0,pick:()=>R0,prefixIssues:()=>dt,primitiveTypes:()=>Ad,promiseAllObject:()=>T0,propertyKeyTypes:()=>ni,randomString:()=>P0,required:()=>M0,safeExtend:()=>C0,shallowClone:()=>Rd,stringifyPrimitive:()=>j,uint8ArrayToBase64:()=>Xg,uint8ArrayToBase64url:()=>V0,uint8ArrayToHex:()=>B0,unwrapMessage:()=>ei});function $0(e){return e}function x0(e){return e}function w0(e){}function k0(e){throw new Error}function S0(e){}function ti(e){let t=Object.values(e).filter(o=>typeof o=="number");return Object.entries(e).filter(([o,r])=>t.indexOf(+o)===-1).map(([o,r])=>r)}function S(e,t="|"){return e.map(n=>j(n)).join(t)}function Nn(e,t){return typeof t=="bigint"?t.toString():t}function Rn(e){return{get value(){{let n=e();return Object.defineProperty(this,"value",{value:n}),n}throw new Error("cached value already set")}}}function vr(e){return e==null}function ri(e){let t=e.startsWith("^")?1:0,n=e.endsWith("$")?e.length-1:e.length;return e.slice(t,n)}function jd(e,t){let n=(e.toString().split(".")[1]||"").length,o=t.toString(),r=(o.split(".")[1]||"").length;if(r===0&&/\d?e-\d?/.test(o)){let c=o.match(/\d?e-(\d?)/);c?.[1]&&(r=Number.parseInt(c[1]))}let i=n>r?n:r,a=Number.parseInt(e.toFixed(i).replace(".","")),s=Number.parseInt(t.toFixed(i).replace(".",""));return a%s/10**i}var Gg=Symbol("evaluating");function se(e,t,n){let o;Object.defineProperty(e,t,{get(){if(o!==Gg)return o===void 0&&(o=Gg,o=n()),o},set(r){Object.defineProperty(e,t,{value:r})},configurable:!0})}function z0(e){return Object.create(Object.getPrototypeOf(e),Object.getOwnPropertyDescriptors(e))}function _r(e,t,n){Object.defineProperty(e,t,{value:n,writable:!0,enumerable:!0,configurable:!0})}function yr(...e){let t={};for(let n of e){let o=Object.getOwnPropertyDescriptors(n);Object.assign(t,o)}return Object.defineProperties({},t)}function I0(e){return yr(e._zod.def)}function E0(e,t){return t?t.reduce((n,o)=>n?.[o],e):e}function T0(e){let t=Object.keys(e),n=t.map(o=>e[o]);return Promise.all(n).then(o=>{let r={};for(let i=0;i<t.length;i++)r[t[i]]=o[i];return r})}function P0(e=10){let t="abcdefghijklmnopqrstuvwxyz",n="";for(let o=0;o<e;o++)n+=t[Math.floor(Math.random()*t.length)];return n}function es(e){return JSON.stringify(e)}var ts="captureStackTrace"in Error?Error.captureStackTrace:(...e)=>{};function Hr(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}var Nd=Rn(()=>{if(typeof navigator<"u"&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{let e=Function;return new e(""),!0}catch{return!1}});function br(e){if(Hr(e)===!1)return!1;let t=e.constructor;if(t===void 0)return!0;let n=t.prototype;return!(Hr(n)===!1||Object.prototype.hasOwnProperty.call(n,"isPrototypeOf")===!1)}function Rd(e){return br(e)?{...e}:Array.isArray(e)?[...e]:e}function O0(e){let t=0;for(let n in e)Object.prototype.hasOwnProperty.call(e,n)&&t++;return t}var j0=e=>{let t=typeof e;switch(t){case"undefined":return"undefined";case"string":return"string";case"number":return Number.isNaN(e)?"nan":"number";case"boolean":return"boolean";case"function":return"function";case"bigint":return"bigint";case"symbol":return"symbol";case"object":return Array.isArray(e)?"array":e===null?"null":e.then&&typeof e.then=="function"&&e.catch&&typeof e.catch=="function"?"promise":typeof Map<"u"&&e instanceof Map?"map":typeof Set<"u"&&e instanceof Set?"set":typeof Date<"u"&&e instanceof Date?"date":typeof File<"u"&&e instanceof File?"file":"object";default:throw new Error(`Unknown data type: ${t}`)}},ni=new Set(["string","number","symbol"]),Ad=new Set(["string","number","bigint","boolean","symbol","undefined"]);function Ut(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function Ne(e,t,n){let o=new e._zod.constr(t??e._zod.def);return(!t||n?.parent)&&(o._zod.parent=e),o}function N(e){let t=e;if(!t)return{};if(typeof t=="string")return{error:()=>t};if(t?.message!==void 0){if(t?.error!==void 0)throw new Error("Cannot specify both `message` and `error` params");t.error=t.message}return delete t.message,typeof t.error=="string"?{...t,error:()=>t.error}:t}function N0(e){let t;return new Proxy({},{get(n,o,r){return t??(t=e()),Reflect.get(t,o,r)},set(n,o,r,i){return t??(t=e()),Reflect.set(t,o,r,i)},has(n,o){return t??(t=e()),Reflect.has(t,o)},deleteProperty(n,o){return t??(t=e()),Reflect.deleteProperty(t,o)},ownKeys(n){return t??(t=e()),Reflect.ownKeys(t)},getOwnPropertyDescriptor(n,o){return t??(t=e()),Reflect.getOwnPropertyDescriptor(t,o)},defineProperty(n,o,r){return t??(t=e()),Reflect.defineProperty(t,o,r)}})}function j(e){return typeof e=="bigint"?e.toString()+"n":typeof e=="string"?`"${e}"`:`${e}`}function Dd(e){return Object.keys(e).filter(t=>e[t]._zod.optin==="optional"&&e[t]._zod.optout==="optional")}var Cd={safeint:[Number.MIN_SAFE_INTEGER,Number.MAX_SAFE_INTEGER],int32:[-2147483648,2147483647],uint32:[0,4294967295],float32:[-34028234663852886e22,34028234663852886e22],float64:[-Number.MAX_VALUE,Number.MAX_VALUE]},Ud={int64:[BigInt("-9223372036854775808"),BigInt("9223372036854775807")],uint64:[BigInt(0),BigInt("18446744073709551615")]};function R0(e,t){let n=e._zod.def,o=yr(e._zod.def,{get shape(){let r={};for(let i in t){if(!(i in n.shape))throw new Error(`Unrecognized key: "${i}"`);t[i]&&(r[i]=n.shape[i])}return _r(this,"shape",r),r},checks:[]});return Ne(e,o)}function A0(e,t){let n=e._zod.def,o=yr(e._zod.def,{get shape(){let r={...e._zod.def.shape};for(let i in t){if(!(i in n.shape))throw new Error(`Unrecognized key: "${i}"`);t[i]&&delete r[i]}return _r(this,"shape",r),r},checks:[]});return Ne(e,o)}function D0(e,t){if(!br(t))throw new Error("Invalid input to extend: expected a plain object");let n=e._zod.def.checks;if(n&&n.length>0)throw new Error("Object schemas containing refinements cannot be extended. Use `.safeExtend()` instead.");let r=yr(e._zod.def,{get shape(){let i={...e._zod.def.shape,...t};return _r(this,"shape",i),i},checks:[]});return Ne(e,r)}function C0(e,t){if(!br(t))throw new Error("Invalid input to safeExtend: expected a plain object");let n={...e._zod.def,get shape(){let o={...e._zod.def.shape,...t};return _r(this,"shape",o),o},checks:e._zod.def.checks};return Ne(e,n)}function U0(e,t){let n=yr(e._zod.def,{get shape(){let o={...e._zod.def.shape,...t._zod.def.shape};return _r(this,"shape",o),o},get catchall(){return t._zod.def.catchall},checks:[]});return Ne(e,n)}function Z0(e,t,n){let o=yr(t._zod.def,{get shape(){let r=t._zod.def.shape,i={...r};if(n)for(let a in n){if(!(a in r))throw new Error(`Unrecognized key: "${a}"`);n[a]&&(i[a]=e?new e({type:"optional",innerType:r[a]}):r[a])}else for(let a in r)i[a]=e?new e({type:"optional",innerType:r[a]}):r[a];return _r(this,"shape",i),i},checks:[]});return Ne(t,o)}function M0(e,t,n){let o=yr(t._zod.def,{get shape(){let r=t._zod.def.shape,i={...r};if(n)for(let a in n){if(!(a in i))throw new Error(`Unrecognized key: "${a}"`);n[a]&&(i[a]=new e({type:"nonoptional",innerType:r[a]}))}else for(let a in r)i[a]=new e({type:"nonoptional",innerType:r[a]});return _r(this,"shape",i),i},checks:[]});return Ne(t,o)}function $r(e,t=0){if(e.aborted===!0)return!0;for(let n=t;n<e.issues.length;n++)if(e.issues[n]?.continue!==!0)return!0;return!1}function dt(e,t){return t.map(n=>{var o;return(o=n).path??(o.path=[]),n.path.unshift(e),n})}function ei(e){return typeof e=="string"?e:e?.message}function ft(e,t,n){let o={...e,path:e.path??[]};if(!e.message){let r=ei(e.inst?._zod.def?.error?.(e))??ei(t?.error?.(e))??ei(n.customError?.(e))??ei(n.localeError?.(e))??"Invalid input";o.message=r}return delete o.inst,delete o.continue,t?.reportInput||delete o.input,o}function oi(e){return e instanceof Set?"set":e instanceof Map?"map":e instanceof File?"file":"unknown"}function ii(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}function An(...e){let[t,n,o]=e;return typeof t=="string"?{message:t,code:"custom",input:n,inst:o}:{...t}}function L0(e){return Object.entries(e).filter(([t,n])=>Number.isNaN(Number.parseInt(t,10))).map(t=>t[1])}function Wg(e){let t=atob(e),n=new Uint8Array(t.length);for(let o=0;o<t.length;o++)n[o]=t.charCodeAt(o);return n}function Xg(e){let t="";for(let n=0;n<e.length;n++)t+=String.fromCharCode(e[n]);return btoa(t)}function q0(e){let t=e.replace(/-/g,"+").replace(/_/g,"/"),n="=".repeat((4-t.length%4)%4);return Wg(t+n)}function V0(e){return Xg(e).replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")}function F0(e){let t=e.replace(/^0x/,"");if(t.length%2!==0)throw new Error("Invalid hex string length");let n=new Uint8Array(t.length/2);for(let o=0;o<t.length;o+=2)n[o/2]=Number.parseInt(t.slice(o,o+2),16);return n}function B0(e){return Array.from(e).map(t=>t.toString(16).padStart(2,"0")).join("")}var Od=class{constructor(...t){}};var Yg=(e,t)=>{e.name="$ZodError",Object.defineProperty(e,"_zod",{value:e._zod,enumerable:!1}),Object.defineProperty(e,"issues",{value:t,enumerable:!1}),e.message=JSON.stringify(t,Nn,2),Object.defineProperty(e,"toString",{value:()=>e.message,enumerable:!1})},ai=$("$ZodError",Yg),et=$("$ZodError",Yg,{Parent:Error});function Dn(e,t=n=>n.message){let n={},o=[];for(let r of e.issues)r.path.length>0?(n[r.path[0]]=n[r.path[0]]||[],n[r.path[0]].push(t(r))):o.push(t(r));return{formErrors:o,fieldErrors:n}}function Cn(e,t){let n=t||function(i){return i.message},o={_errors:[]},r=i=>{for(let a of i.issues)if(a.code==="invalid_union"&&a.errors.length)a.errors.map(s=>r({issues:s}));else if(a.code==="invalid_key")r({issues:a.issues});else if(a.code==="invalid_element")r({issues:a.issues});else if(a.path.length===0)o._errors.push(n(a));else{let s=o,c=0;for(;c<a.path.length;){let l=a.path[c];c===a.path.length-1?(s[l]=s[l]||{_errors:[]},s[l]._errors.push(n(a))):s[l]=s[l]||{_errors:[]},s=s[l],c++}}};return r(e),o}function rs(e,t){let n=t||function(i){return i.message},o={errors:[]},r=(i,a=[])=>{var s,c;for(let l of i.issues)if(l.code==="invalid_union"&&l.errors.length)l.errors.map(d=>r({issues:d},l.path));else if(l.code==="invalid_key")r({issues:l.issues},l.path);else if(l.code==="invalid_element")r({issues:l.issues},l.path);else{let d=[...a,...l.path];if(d.length===0){o.errors.push(n(l));continue}let f=o,_=0;for(;_<d.length;){let v=d[_],g=_===d.length-1;typeof v=="string"?(f.properties??(f.properties={}),(s=f.properties)[v]??(s[v]={errors:[]}),f=f.properties[v]):(f.items??(f.items=[]),(c=f.items)[v]??(c[v]={errors:[]}),f=f.items[v]),g&&f.errors.push(n(l)),_++}}};return r(e),o}function Qg(e){let t=[],n=e.map(o=>typeof o=="object"?o.key:o);for(let o of n)typeof o=="number"?t.push(`[${o}]`):typeof o=="symbol"?t.push(`[${JSON.stringify(String(o))}]`):/[^\w$]/.test(o)?t.push(`[${JSON.stringify(o)}]`):(t.length&&t.push("."),t.push(o));return t.join("")}function ns(e){let t=[],n=[...e.issues].sort((o,r)=>(o.path??[]).length-(r.path??[]).length);for(let o of n)t.push(`\u2716 ${o.message}`),o.path?.length&&t.push(` \u2192 at ${Qg(o.path)}`);return t.join(`
|
|
35
|
-
`)}var Un=e=>(t,n,o,r)=>{let i=o?Object.assign(o,{async:!1}):{async:!1},a=t._zod.run({value:n,issues:[]},i);if(a instanceof Promise)throw new Et;if(a.issues.length){let s=new(r?.Err??e)(a.issues.map(c=>ft(c,i,Ee())));throw ts(s,r?.callee),s}return a.value},Jr=Un(et),Zn=e=>async(t,n,o,r)=>{let i=o?Object.assign(o,{async:!0}):{async:!0},a=t._zod.run({value:n,issues:[]},i);if(a instanceof Promise&&(a=await a),a.issues.length){let s=new(r?.Err??e)(a.issues.map(c=>ft(c,i,Ee())));throw ts(s,r?.callee),s}return a.value},Gr=Zn(et),Mn=e=>(t,n,o)=>{let r=o?{...o,async:!1}:{async:!1},i=t._zod.run({value:n,issues:[]},r);if(i instanceof Promise)throw new Et;return i.issues.length?{success:!1,error:new(e??ai)(i.issues.map(a=>ft(a,r,Ee())))}:{success:!0,data:i.value}},xr=Mn(et),Ln=e=>async(t,n,o)=>{let r=o?Object.assign(o,{async:!0}):{async:!0},i=t._zod.run({value:n,issues:[]},r);return i instanceof Promise&&(i=await i),i.issues.length?{success:!1,error:new e(i.issues.map(a=>ft(a,r,Ee())))}:{success:!0,data:i.value}},wr=Ln(et),os=e=>(t,n,o)=>{let r=o?Object.assign(o,{direction:"backward"}):{direction:"backward"};return Un(e)(t,n,r)},ev=os(et),is=e=>(t,n,o)=>Un(e)(t,n,o),tv=is(et),as=e=>async(t,n,o)=>{let r=o?Object.assign(o,{direction:"backward"}):{direction:"backward"};return Zn(e)(t,n,r)},rv=as(et),ss=e=>async(t,n,o)=>Zn(e)(t,n,o),nv=ss(et),cs=e=>(t,n,o)=>{let r=o?Object.assign(o,{direction:"backward"}):{direction:"backward"};return Mn(e)(t,n,r)},ov=cs(et),us=e=>(t,n,o)=>Mn(e)(t,n,o),iv=us(et),ls=e=>async(t,n,o)=>{let r=o?Object.assign(o,{direction:"backward"}):{direction:"backward"};return Ln(e)(t,n,r)},av=ls(et),ds=e=>async(t,n,o)=>Ln(e)(t,n,o),sv=ds(et);var tt={};Fr(tt,{base64:()=>Qd,base64url:()=>fs,bigint:()=>sf,boolean:()=>lf,browserEmail:()=>ez,cidrv4:()=>Xd,cidrv6:()=>Yd,cuid:()=>Zd,cuid2:()=>Md,date:()=>rf,datetime:()=>of,domain:()=>rz,duration:()=>Bd,e164:()=>tf,email:()=>Hd,emoji:()=>Jd,extendedDuration:()=>H0,guid:()=>Kd,hex:()=>nz,hostname:()=>ef,html5Email:()=>X0,idnEmail:()=>Q0,integer:()=>cf,ipv4:()=>Gd,ipv6:()=>Wd,ksuid:()=>Vd,lowercase:()=>pf,md5_base64:()=>iz,md5_base64url:()=>az,md5_hex:()=>oz,nanoid:()=>Fd,null:()=>df,number:()=>uf,rfc5322Email:()=>Y0,sha1_base64:()=>cz,sha1_base64url:()=>uz,sha1_hex:()=>sz,sha256_base64:()=>dz,sha256_base64url:()=>fz,sha256_hex:()=>lz,sha384_base64:()=>mz,sha384_base64url:()=>hz,sha384_hex:()=>pz,sha512_base64:()=>vz,sha512_base64url:()=>_z,sha512_hex:()=>gz,string:()=>af,time:()=>nf,ulid:()=>Ld,undefined:()=>ff,unicodeEmail:()=>cv,uppercase:()=>mf,uuid:()=>Wr,uuid4:()=>J0,uuid6:()=>G0,uuid7:()=>W0,xid:()=>qd});var Zd=/^[cC][^\s-]{8,}$/,Md=/^[0-9a-z]+$/,Ld=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,qd=/^[0-9a-vA-V]{20}$/,Vd=/^[A-Za-z0-9]{27}$/,Fd=/^[a-zA-Z0-9_-]{21}$/,Bd=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,H0=/^[-+]?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)?)??$/,Kd=/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/,Wr=e=>e?new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`):/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/,J0=Wr(4),G0=Wr(6),W0=Wr(7),Hd=/^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,X0=/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,Y0=/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/,cv=/^[^\s@"]{1,64}@[^\s@]{1,255}$/u,Q0=cv,ez=/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,tz="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";function Jd(){return new RegExp(tz,"u")}var Gd=/^(?:(?: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])$/,Wd=/^(([0-9a-fA-F]{1,4}:){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}|:))$/,Xd=/^((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])\/([0-9]|[1-2][0-9]|3[0-2])$/,Yd=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,Qd=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,fs=/^[A-Za-z0-9_-]*$/,ef=/^(?=.{1,253}\.?$)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[-0-9a-zA-Z]{0,61}[0-9a-zA-Z])?)*\.?$/,rz=/^([a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,}$/,tf=/^\+(?:[0-9]){6,14}[0-9]$/,uv="(?:(?:\\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])))",rf=new RegExp(`^${uv}$`);function lv(e){let t="(?:[01]\\d|2[0-3]):[0-5]\\d";return typeof e.precision=="number"?e.precision===-1?`${t}`:e.precision===0?`${t}:[0-5]\\d`:`${t}:[0-5]\\d\\.\\d{${e.precision}}`:`${t}(?::[0-5]\\d(?:\\.\\d+)?)?`}function nf(e){return new RegExp(`^${lv(e)}$`)}function of(e){let t=lv({precision:e.precision}),n=["Z"];e.local&&n.push(""),e.offset&&n.push("([+-](?:[01]\\d|2[0-3]):[0-5]\\d)");let o=`${t}(?:${n.join("|")})`;return new RegExp(`^${uv}T(?:${o})$`)}var af=e=>{let t=e?`[\\s\\S]{${e?.minimum??0},${e?.maximum??""}}`:"[\\s\\S]*";return new RegExp(`^${t}$`)},sf=/^-?\d+n?$/,cf=/^-?\d+$/,uf=/^-?\d+(?:\.\d+)?/,lf=/^(?:true|false)$/i,df=/^null$/i;var ff=/^undefined$/i;var pf=/^[^A-Z]*$/,mf=/^[^a-z]*$/,nz=/^[0-9a-fA-F]*$/;function si(e,t){return new RegExp(`^[A-Za-z0-9+/]{${e}}${t}$`)}function ci(e){return new RegExp(`^[A-Za-z0-9_-]{${e}}$`)}var oz=/^[0-9a-fA-F]{32}$/,iz=si(22,"=="),az=ci(22),sz=/^[0-9a-fA-F]{40}$/,cz=si(27,"="),uz=ci(27),lz=/^[0-9a-fA-F]{64}$/,dz=si(43,"="),fz=ci(43),pz=/^[0-9a-fA-F]{96}$/,mz=si(64,""),hz=ci(64),gz=/^[0-9a-fA-F]{128}$/,vz=si(86,"=="),_z=ci(86);var $e=$("$ZodCheck",(e,t)=>{var n;e._zod??(e._zod={}),e._zod.def=t,(n=e._zod).onattach??(n.onattach=[])}),fv={number:"number",bigint:"bigint",object:"date"},ps=$("$ZodCheckLessThan",(e,t)=>{$e.init(e,t);let n=fv[typeof t.value];e._zod.onattach.push(o=>{let r=o._zod.bag,i=(t.inclusive?r.maximum:r.exclusiveMaximum)??Number.POSITIVE_INFINITY;t.value<i&&(t.inclusive?r.maximum=t.value:r.exclusiveMaximum=t.value)}),e._zod.check=o=>{(t.inclusive?o.value<=t.value:o.value<t.value)||o.issues.push({origin:n,code:"too_big",maximum:t.value,input:o.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),ms=$("$ZodCheckGreaterThan",(e,t)=>{$e.init(e,t);let n=fv[typeof t.value];e._zod.onattach.push(o=>{let r=o._zod.bag,i=(t.inclusive?r.minimum:r.exclusiveMinimum)??Number.NEGATIVE_INFINITY;t.value>i&&(t.inclusive?r.minimum=t.value:r.exclusiveMinimum=t.value)}),e._zod.check=o=>{(t.inclusive?o.value>=t.value:o.value>t.value)||o.issues.push({origin:n,code:"too_small",minimum:t.value,input:o.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),hf=$("$ZodCheckMultipleOf",(e,t)=>{$e.init(e,t),e._zod.onattach.push(n=>{var o;(o=n._zod.bag).multipleOf??(o.multipleOf=t.value)}),e._zod.check=n=>{if(typeof n.value!=typeof t.value)throw new Error("Cannot mix number and bigint in multiple_of check.");(typeof n.value=="bigint"?n.value%t.value===BigInt(0):jd(n.value,t.value)===0)||n.issues.push({origin:typeof n.value,code:"not_multiple_of",divisor:t.value,input:n.value,inst:e,continue:!t.abort})}}),gf=$("$ZodCheckNumberFormat",(e,t)=>{$e.init(e,t),t.format=t.format||"float64";let n=t.format?.includes("int"),o=n?"int":"number",[r,i]=Cd[t.format];e._zod.onattach.push(a=>{let s=a._zod.bag;s.format=t.format,s.minimum=r,s.maximum=i,n&&(s.pattern=cf)}),e._zod.check=a=>{let s=a.value;if(n){if(!Number.isInteger(s)){a.issues.push({expected:o,format:t.format,code:"invalid_type",continue:!1,input:s,inst:e});return}if(!Number.isSafeInteger(s)){s>0?a.issues.push({input:s,code:"too_big",maximum:Number.MAX_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:o,continue:!t.abort}):a.issues.push({input:s,code:"too_small",minimum:Number.MIN_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:o,continue:!t.abort});return}}s<r&&a.issues.push({origin:"number",input:s,code:"too_small",minimum:r,inclusive:!0,inst:e,continue:!t.abort}),s>i&&a.issues.push({origin:"number",input:s,code:"too_big",maximum:i,inst:e})}}),vf=$("$ZodCheckBigIntFormat",(e,t)=>{$e.init(e,t);let[n,o]=Ud[t.format];e._zod.onattach.push(r=>{let i=r._zod.bag;i.format=t.format,i.minimum=n,i.maximum=o}),e._zod.check=r=>{let i=r.value;i<n&&r.issues.push({origin:"bigint",input:i,code:"too_small",minimum:n,inclusive:!0,inst:e,continue:!t.abort}),i>o&&r.issues.push({origin:"bigint",input:i,code:"too_big",maximum:o,inst:e})}}),_f=$("$ZodCheckMaxSize",(e,t)=>{var n;$e.init(e,t),(n=e._zod.def).when??(n.when=o=>{let r=o.value;return!vr(r)&&r.size!==void 0}),e._zod.onattach.push(o=>{let r=o._zod.bag.maximum??Number.POSITIVE_INFINITY;t.maximum<r&&(o._zod.bag.maximum=t.maximum)}),e._zod.check=o=>{let r=o.value;r.size<=t.maximum||o.issues.push({origin:oi(r),code:"too_big",maximum:t.maximum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),yf=$("$ZodCheckMinSize",(e,t)=>{var n;$e.init(e,t),(n=e._zod.def).when??(n.when=o=>{let r=o.value;return!vr(r)&&r.size!==void 0}),e._zod.onattach.push(o=>{let r=o._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>r&&(o._zod.bag.minimum=t.minimum)}),e._zod.check=o=>{let r=o.value;r.size>=t.minimum||o.issues.push({origin:oi(r),code:"too_small",minimum:t.minimum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),bf=$("$ZodCheckSizeEquals",(e,t)=>{var n;$e.init(e,t),(n=e._zod.def).when??(n.when=o=>{let r=o.value;return!vr(r)&&r.size!==void 0}),e._zod.onattach.push(o=>{let r=o._zod.bag;r.minimum=t.size,r.maximum=t.size,r.size=t.size}),e._zod.check=o=>{let r=o.value,i=r.size;if(i===t.size)return;let a=i>t.size;o.issues.push({origin:oi(r),...a?{code:"too_big",maximum:t.size}:{code:"too_small",minimum:t.size},inclusive:!0,exact:!0,input:o.value,inst:e,continue:!t.abort})}}),$f=$("$ZodCheckMaxLength",(e,t)=>{var n;$e.init(e,t),(n=e._zod.def).when??(n.when=o=>{let r=o.value;return!vr(r)&&r.length!==void 0}),e._zod.onattach.push(o=>{let r=o._zod.bag.maximum??Number.POSITIVE_INFINITY;t.maximum<r&&(o._zod.bag.maximum=t.maximum)}),e._zod.check=o=>{let r=o.value;if(r.length<=t.maximum)return;let a=ii(r);o.issues.push({origin:a,code:"too_big",maximum:t.maximum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),xf=$("$ZodCheckMinLength",(e,t)=>{var n;$e.init(e,t),(n=e._zod.def).when??(n.when=o=>{let r=o.value;return!vr(r)&&r.length!==void 0}),e._zod.onattach.push(o=>{let r=o._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>r&&(o._zod.bag.minimum=t.minimum)}),e._zod.check=o=>{let r=o.value;if(r.length>=t.minimum)return;let a=ii(r);o.issues.push({origin:a,code:"too_small",minimum:t.minimum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),wf=$("$ZodCheckLengthEquals",(e,t)=>{var n;$e.init(e,t),(n=e._zod.def).when??(n.when=o=>{let r=o.value;return!vr(r)&&r.length!==void 0}),e._zod.onattach.push(o=>{let r=o._zod.bag;r.minimum=t.length,r.maximum=t.length,r.length=t.length}),e._zod.check=o=>{let r=o.value,i=r.length;if(i===t.length)return;let a=ii(r),s=i>t.length;o.issues.push({origin:a,...s?{code:"too_big",maximum:t.length}:{code:"too_small",minimum:t.length},inclusive:!0,exact:!0,input:o.value,inst:e,continue:!t.abort})}}),qn=$("$ZodCheckStringFormat",(e,t)=>{var n,o;$e.init(e,t),e._zod.onattach.push(r=>{let i=r._zod.bag;i.format=t.format,t.pattern&&(i.patterns??(i.patterns=new Set),i.patterns.add(t.pattern))}),t.pattern?(n=e._zod).check??(n.check=r=>{t.pattern.lastIndex=0,!t.pattern.test(r.value)&&r.issues.push({origin:"string",code:"invalid_format",format:t.format,input:r.value,...t.pattern?{pattern:t.pattern.toString()}:{},inst:e,continue:!t.abort})}):(o=e._zod).check??(o.check=()=>{})}),kf=$("$ZodCheckRegex",(e,t)=>{qn.init(e,t),e._zod.check=n=>{t.pattern.lastIndex=0,!t.pattern.test(n.value)&&n.issues.push({origin:"string",code:"invalid_format",format:"regex",input:n.value,pattern:t.pattern.toString(),inst:e,continue:!t.abort})}}),Sf=$("$ZodCheckLowerCase",(e,t)=>{t.pattern??(t.pattern=pf),qn.init(e,t)}),zf=$("$ZodCheckUpperCase",(e,t)=>{t.pattern??(t.pattern=mf),qn.init(e,t)}),If=$("$ZodCheckIncludes",(e,t)=>{$e.init(e,t);let n=Ut(t.includes),o=new RegExp(typeof t.position=="number"?`^.{${t.position}}${n}`:n);t.pattern=o,e._zod.onattach.push(r=>{let i=r._zod.bag;i.patterns??(i.patterns=new Set),i.patterns.add(o)}),e._zod.check=r=>{r.value.includes(t.includes,t.position)||r.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:t.includes,input:r.value,inst:e,continue:!t.abort})}}),Ef=$("$ZodCheckStartsWith",(e,t)=>{$e.init(e,t);let n=new RegExp(`^${Ut(t.prefix)}.*`);t.pattern??(t.pattern=n),e._zod.onattach.push(o=>{let r=o._zod.bag;r.patterns??(r.patterns=new Set),r.patterns.add(n)}),e._zod.check=o=>{o.value.startsWith(t.prefix)||o.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:t.prefix,input:o.value,inst:e,continue:!t.abort})}}),Tf=$("$ZodCheckEndsWith",(e,t)=>{$e.init(e,t);let n=new RegExp(`.*${Ut(t.suffix)}$`);t.pattern??(t.pattern=n),e._zod.onattach.push(o=>{let r=o._zod.bag;r.patterns??(r.patterns=new Set),r.patterns.add(n)}),e._zod.check=o=>{o.value.endsWith(t.suffix)||o.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:t.suffix,input:o.value,inst:e,continue:!t.abort})}});function dv(e,t,n){e.issues.length&&t.issues.push(...dt(n,e.issues))}var Pf=$("$ZodCheckProperty",(e,t)=>{$e.init(e,t),e._zod.check=n=>{let o=t.schema._zod.run({value:n.value[t.property],issues:[]},{});if(o instanceof Promise)return o.then(r=>dv(r,n,t.property));dv(o,n,t.property)}}),Of=$("$ZodCheckMimeType",(e,t)=>{$e.init(e,t);let n=new Set(t.mime);e._zod.onattach.push(o=>{o._zod.bag.mime=t.mime}),e._zod.check=o=>{n.has(o.value.type)||o.issues.push({code:"invalid_value",values:t.mime,input:o.value.type,inst:e,continue:!t.abort})}}),jf=$("$ZodCheckOverwrite",(e,t)=>{$e.init(e,t),e._zod.check=n=>{n.value=t.tx(n.value)}});var ui=class{constructor(t=[]){this.content=[],this.indent=0,this&&(this.args=t)}indented(t){this.indent+=1,t(this),this.indent-=1}write(t){if(typeof t=="function"){t(this,{execution:"sync"}),t(this,{execution:"async"});return}let o=t.split(`
|
|
34
|
+
`+m),u};var Ka={},Yk=gn.getStack;Ka={name:"contextualize",load:function(u){var m=function(h,p){var y=Yk(),w=md(u);return w.fallbackStack=y,w.addOnError(p),u._clientContext.run(w,h)};return m}},Ka.default=Ka;var Ha={},Qk=gn.getStack,eS=gn.maybeUseFallbackStack;Ha={name:"intercept",load:function(u){var m=function(h,p){h===void 0&&(h=function(){}),typeof p!="function"&&(p=h,h=function(){});var y=Qk();return function(w){if(w){w.stack&&eS(w,y);var z=u.Event.create(w,!0,{severity:"warning",unhandled:!1,severityReason:{type:"callbackErrorIntercept"}},"intercept()",1);u._notify(z,h);return}for(var D=arguments.length,L=new Array(D>1?D-1:0),Q=1;Q<D;Q++)L[Q-1]=arguments[Q];p.apply(void 0,L)}};return m}},Ha.default=Ha;function Ja(){return Ja=Object.assign?Object.assign.bind():function(u){for(var m=1;m<arguments.length;m++){var h=arguments[m];for(var p in h)({}).hasOwnProperty.call(h,p)&&(u[p]=h[p])}return u},Ja.apply(null,arguments)}var Uo=require("os"),tS={load:function(u){var m={osName:Uo.platform()+" ("+Uo.arch()+")",osVersion:Uo.release(),totalMemory:Uo.totalmem(),hostname:u._config.hostname,runtimeVersions:{node:process.versions.node}};u._addOnSessionPayload(function(h){h.device=Ja({},h.device,m)}),u.addOnError(function(h){h.device=Ja({},h.device,m,{freeMemory:Uo.freemem(),time:new Date})},!0)}},Ag=require("path"),rS=Ag.join,nS=Ag.resolve,Dg=function(u){return rS(nS(u),"/")},oS={load:function(u){return u.addOnError(function(m){if(u._config.projectRoot){var h=Dg(u._config.projectRoot),p=m.errors.reduce(function(y,w){return y.concat(w.stacktrace)},[]);p.map(function(y){y.inProject=typeof y.file=="string"&&y.file.indexOf(h)===0&&!/\/node_modules\//.test(y.file)})}})}};function hd(){return hd=Object.assign?Object.assign.bind():function(u){for(var m=1;m<arguments.length;m++){var h=arguments[m];for(var p in h)({}).hasOwnProperty.call(h,p)&&(u[p]=h[p])}return u},hd.apply(null,arguments)}function iS(u,m){u.prototype=Object.create(m.prototype),u.prototype.constructor=u,gd(u,m)}function gd(u,m){return gd=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(h,p){return h.__proto__=p,h},gd(u,m)}var Cg=3,Ug=200,aS=require("fs"),sS=aS.createReadStream,cS=require("stream"),uS=cS.Writable,lS=kw(),dS=zw(),fS=require("path"),pS={load:function(u){if(u._config.sendCode){var m=function(h,p){return new Promise(function(y,w){try{if(!h.lineNumber||!h.file)return y(h);var z=fS.resolve(u._config.projectRoot,h.file),D=z+"@"+h.lineNumber;if(D in p)return h.code=p[D],y(h);mS(z,h.lineNumber,function(L,Q){return L||(h.code=p[D]=Q),y(h)})}catch{return y(h)}})};u.addOnError(function(h){return new Promise(function(p,y){var w=Object.create(null),z=h.errors.reduce(function(D,L){return D.concat(L.stacktrace)},[]);gS(z.map(function(D){return function(){return m(D,w)}})).then(p).catch(y)})})}},configSchema:{sendCode:{defaultValue:function(){return!0},validate:function(u){return u===!0||u===!1},message:"should be true or false"}}},mS=function(u,m,h){var p=m-Cg,y=m+Cg,w=sS(u,{encoding:"utf8"}),z=new dS.LineStream({keepEmptyLines:!0}),D=new hS({start:p,end:y});D.on("done",function(){return w.destroy()}),lS(w,z,D,function(L){if(L&&L.message!=="premature close")return h(L);h(null,D.getCode())})},hS=(function(u){function m(p){var y;return y=u.call(this,hd({},p,{decodeStrings:!1}))||this,y._start=p.start,y._end=p.end,y._n=0,y._code={},y}iS(m,u);var h=m.prototype;return h._write=function(y,w,z){return this._n++,this._n<this._start?z(null):this._n<=this._end?(this._code[String(this._n)]=y.length<=Ug?y:y.substr(0,Ug),z(null)):(this.emit("done"),z(null))},h.getCode=function(){return this._code},m})(uS),gS=function(u){return new Promise(function(m,h){var p=[];u.reduce(function(y,w){return y.then(function(z){return p.push(z),w()})},Promise.resolve()).then(function(y){p.push(y)}).then(function(){m(p.slice(1))})})},vS=gn.maybeUseFallbackStack,vd,_S={load:function(u){u._config.autoDetectErrors&&u._config.enabledErrorTypes.unhandledExceptions&&(vd=function(m){var h=u._clientContext&&u._clientContext.getStore(),p=h||u;m.stack&&p.fallbackStack&&vS(m,p.fallbackStack);var y=p.Event.create(m,!1,{severity:"error",unhandled:!0,severityReason:{type:"unhandledException"}},"uncaughtException handler",1);return new Promise(function(w){p._notify(y,function(){},function(z,D){z&&p._logger.error("Failed to send event to Bugsnag"),p._config.onUncaughtException(m,D,p._logger),w()})})},process.prependListener("uncaughtException",vd))},destroy:function(){process.removeListener("uncaughtException",vd)}},Ga,yS={load:function(u){!u._config.autoDetectErrors||!u._config.enabledErrorTypes.unhandledRejections||(Ga=function(m){var h=u._clientContext&&u._clientContext.getStore(),p=h||u,y=!u._config.reportUnhandledPromiseRejectionsAsHandled,w=p.Event.create(m,!1,{severity:"error",unhandled:y,severityReason:{type:"unhandledPromiseRejection"}},"unhandledRejection handler",1);return new Promise(function(z){p._notify(w,function(){},function(D,L){D&&p._logger.error("Failed to send event to Bugsnag"),p._config.onUnhandledRejection(m,L,p._logger),z()})})},process.prependListener?process.prependListener("unhandledRejection",Ga):process.on("unhandledRejection",Ga))},destroy:function(){process.removeListener("unhandledRejection",Ga)}},bS=_d;function _d(u){u=u||{},this.ms=u.min||100,this.max=u.max||1e4,this.factor=u.factor||2,this.jitter=u.jitter>0&&u.jitter<=1?u.jitter:0,this.attempts=0}_d.prototype.duration=function(){var u=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var m=Math.random(),h=Math.floor(m*this.jitter*u);u=(Math.floor(m*10)&1)==0?u-h:u+h}return Math.min(u,this.max)|0},_d.prototype.reset=function(){this.attempts=0};function $S(u,m){u.prototype=Object.create(m.prototype),u.prototype.constructor=u,yd(u,m)}function yd(u,m){return yd=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(h,p){return h.__proto__=p,h},yd(u,m)}var xS=10*1e3,wS=require("events").EventEmitter,kS=(function(u){function m(p){var y;return y=u.call(this)||this,y._sessions=new Map,y._interval=null,y._intervalLength=p||xS,y._summarize=y._summarize.bind(y),y}$S(m,u);var h=m.prototype;return h.start=function(){this._interval||(this._interval=setInterval(this._summarize,this._intervalLength).unref())},h.stop=function(){clearInterval(this._interval),this._interval=null},h.track=function(y){var w=SS(y.startedAt),z=this._sessions.get(w);return this._sessions.set(w,typeof z>"u"?1:z+1),y},h._summarize=function(){var y=this,w=[];this._sessions.forEach(function(z,D){w.push({startedAt:D,sessionsStarted:z}),y._sessions.delete(D)}),w.length&&this.emit("summary",w)},m})(wS),SS=function(u){var m=new Date(u);return m.setSeconds(0),m.setMilliseconds(0),m.toISOString()},zS={load:function(u){var m=null;u._sessionDelegate={startSession:function(h,p){return m||(m=new kS(h._config.sessionSummaryInterval),m.on("summary",IS(h)),m.start()),h._session=p,h._pausedSession=null,m.track(h._session),h},pauseSession:function(h){h._pausedSession=h._session,h._session=null},resumeSession:function(h){return h._session?h:h._pausedSession?(h._session=h._pausedSession,h._pausedSession=null,h):h.startSession()}}},configSchema:{sessionSummaryInterval:{defaultValue:function(){},validate:function(u){return u===void 0||v()(u)},message:"should be a positive integer"}}},IS=function(u){return function(m){if(u._config.enabledReleaseStages!==null&&!u._config.enabledReleaseStages.includes(u._config.releaseStage)){u._logger.warn("Session not sent due to releaseStage/enabledReleaseStages configuration");return}if(!m.length)return;var h=new bS({min:1e3,max:1e4}),p=10;w(y);function y(z){if(!z){var D=m.reduce(function(L,Q){return L+Q.sessionsStarted},0);return u._logger.debug(D+" session(s) reported")}if(h.attempts===10){u._logger.error("Session delivery failed, max retries exceeded",z);return}u._logger.debug("Session delivery failed, retry #"+(h.attempts+1)+"/"+p,z),setTimeout(function(){return w(y)},h.duration())}function w(z){var D={notifier:u._notifier,device:{},app:{releaseStage:u._config.releaseStage,version:u._config.appVersion,type:u._config.appType},sessionCounts:m},L=sd(u._cbs.sp,D,"onSessionPayload",u._logger);if(L)return u._logger.debug("Session not sent due to onSessionPayload callback"),z(null);u._delivery.sendSession(D,z)}}},ES={load:function(u){u.addOnError(function(m){var h=m.errors.reduce(function(p,y){return p.concat(y.stacktrace)},[]);h.forEach(function(p){typeof p.file=="string"&&(p.file=p.file.replace(/\\/g,"/"))})})}},TS={load:function(u){return u.addOnError(function(m){if(u._config.projectRoot){var h=Dg(u._config.projectRoot),p=m.errors.reduce(function(y,w){return y.concat(w.stacktrace)},[]);p.map(function(y){typeof y.file=="string"&&y.file.indexOf(h)===0&&(y.file=y.file.replace(h,""))})}})}},Vr={};function bd(){return bd=Object.assign?Object.assign.bind():function(u){for(var m=1;m<arguments.length;m++){var h=arguments[m];for(var p in h)({}).hasOwnProperty.call(h,p)&&(u[p]=h[p])}return u},bd.apply(null,arguments)}var OS="Bugsnag Node",PS="8.8.0",jS="https://github.com/bugsnag/bugsnag-js",NS=require("async_hooks"),RS=NS.AsyncLocalStorage;La.__type="nodejs";var AS=bd({},x.schema,Hk),DS=[Xk,pS,oS,TS,zS,tS,_S,yS,Ha,Ka,ES,pd],kt={_client:null,createClient:function(u){typeof u=="string"&&(u={apiKey:u}),u||(u={});var m=new Fa(u,AS,DS,{name:OS,version:PS,url:jS});return Object.keys(Fa.prototype).forEach(function(h){var p=m[h];m[h]=function(){var y=m._clientContext&&typeof m._clientContext.getStore=="function"?m._clientContext.getStore():null,w=y||m,z=y?y[h]:p;w._depth+=1;var D=z.apply(w,arguments);return w._depth-=1,D}}),m._clientContext=new RS,m._setDelivery(Vk),m._logger.debug("Loaded!"),m},start:function(u){return kt._client?(kt._client._logger.warn("Bugsnag.start() was called more than once. Ignoring."),kt._client):(kt._client=kt.createClient(u),kt._client)},isStarted:function(){return kt._client!=null}};return Object.keys(Fa.prototype).forEach(function(u){/^_/.test(u)||(kt[u]=function(){var m=kt._client,h=m&&m._clientContext&&m._clientContext.getStore();if(h&&(m=h),!m)return console.error("Bugsnag."+u+"() was called before Bugsnag.start()");m._depth+=1;var p=m[u].apply(m,arguments);return m._depth-=1,p})}),Vr=kt,Vr.Client=Fa,Vr.Event=La,Vr.Session=ld,Vr.Breadcrumb=r,Vr.default=kt,Vr})});var Ow=A((I9,Tw)=>{Tw.exports=Ew()});var kd=ht(Fg()),Bg=ht(require("path"));process.env.DOTENV_CONFIG_SILENT="true";kd.default.config();kd.default.config({path:Bg.default.resolve(__dirname,"../../.env")});var ce;(function(e){e.assertEqual=r=>{};function t(r){}e.assertIs=t;function n(r){throw new Error}e.assertNever=n,e.arrayToEnum=r=>{let i={};for(let a of r)i[a]=a;return i},e.getValidEnumValues=r=>{let i=e.objectKeys(r).filter(s=>typeof r[r[s]]!="number"),a={};for(let s of i)a[s]=r[s];return e.objectValues(a)},e.objectValues=r=>e.objectKeys(r).map(function(i){return r[i]}),e.objectKeys=typeof Object.keys=="function"?r=>Object.keys(r):r=>{let i=[];for(let a in r)Object.prototype.hasOwnProperty.call(r,a)&&i.push(a);return i},e.find=(r,i)=>{for(let a of r)if(i(a))return a},e.isInteger=typeof Number.isInteger=="function"?r=>Number.isInteger(r):r=>typeof r=="number"&&Number.isFinite(r)&&Math.floor(r)===r;function o(r,i=" | "){return r.map(a=>typeof a=="string"?`'${a}'`:a).join(i)}e.joinValues=o,e.jsonStringifyReplacer=(r,i)=>typeof i=="bigint"?i.toString():i})(ce||(ce={}));var Kg;(function(e){e.mergeShapes=(t,n)=>({...t,...n})})(Kg||(Kg={}));var U=ce.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),Xt=e=>{switch(typeof e){case"undefined":return U.undefined;case"string":return U.string;case"number":return Number.isNaN(e)?U.nan:U.number;case"boolean":return U.boolean;case"function":return U.function;case"bigint":return U.bigint;case"symbol":return U.symbol;case"object":return Array.isArray(e)?U.array:e===null?U.null:e.then&&typeof e.then=="function"&&e.catch&&typeof e.catch=="function"?U.promise:typeof Map<"u"&&e instanceof Map?U.map:typeof Set<"u"&&e instanceof Set?U.set:typeof Date<"u"&&e instanceof Date?U.date:U.object;default:return U.unknown}};var T=ce.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"]);var ut=class e extends Error{get errors(){return this.issues}constructor(t){super(),this.issues=[],this.addIssue=o=>{this.issues=[...this.issues,o]},this.addIssues=(o=[])=>{this.issues=[...this.issues,...o]};let n=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,n):this.__proto__=n,this.name="ZodError",this.issues=t}format(t){let n=t||function(i){return i.message},o={_errors:[]},r=i=>{for(let a of i.issues)if(a.code==="invalid_union")a.unionErrors.map(r);else if(a.code==="invalid_return_type")r(a.returnTypeError);else if(a.code==="invalid_arguments")r(a.argumentsError);else if(a.path.length===0)o._errors.push(n(a));else{let s=o,c=0;for(;c<a.path.length;){let l=a.path[c];c===a.path.length-1?(s[l]=s[l]||{_errors:[]},s[l]._errors.push(n(a))):s[l]=s[l]||{_errors:[]},s=s[l],c++}}};return r(this),o}static assert(t){if(!(t instanceof e))throw new Error(`Not a ZodError: ${t}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,ce.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(t=n=>n.message){let n={},o=[];for(let r of this.issues)if(r.path.length>0){let i=r.path[0];n[i]=n[i]||[],n[i].push(t(r))}else o.push(t(r));return{formErrors:o,fieldErrors:n}}get formErrors(){return this.flatten()}};ut.create=e=>new ut(e);var n0=(e,t)=>{let n;switch(e.code){case T.invalid_type:e.received===U.undefined?n="Required":n=`Expected ${e.expected}, received ${e.received}`;break;case T.invalid_literal:n=`Invalid literal value, expected ${JSON.stringify(e.expected,ce.jsonStringifyReplacer)}`;break;case T.unrecognized_keys:n=`Unrecognized key(s) in object: ${ce.joinValues(e.keys,", ")}`;break;case T.invalid_union:n="Invalid input";break;case T.invalid_union_discriminator:n=`Invalid discriminator value. Expected ${ce.joinValues(e.options)}`;break;case T.invalid_enum_value:n=`Invalid enum value. Expected ${ce.joinValues(e.options)}, received '${e.received}'`;break;case T.invalid_arguments:n="Invalid function arguments";break;case T.invalid_return_type:n="Invalid function return type";break;case T.invalid_date:n="Invalid date";break;case T.invalid_string:typeof e.validation=="object"?"includes"in e.validation?(n=`Invalid input: must include "${e.validation.includes}"`,typeof e.validation.position=="number"&&(n=`${n} at one or more positions greater than or equal to ${e.validation.position}`)):"startsWith"in e.validation?n=`Invalid input: must start with "${e.validation.startsWith}"`:"endsWith"in e.validation?n=`Invalid input: must end with "${e.validation.endsWith}"`:ce.assertNever(e.validation):e.validation!=="regex"?n=`Invalid ${e.validation}`:n="Invalid";break;case T.too_small:e.type==="array"?n=`Array must contain ${e.exact?"exactly":e.inclusive?"at least":"more than"} ${e.minimum} element(s)`:e.type==="string"?n=`String must contain ${e.exact?"exactly":e.inclusive?"at least":"over"} ${e.minimum} character(s)`:e.type==="number"?n=`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:e.type==="bigint"?n=`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:e.type==="date"?n=`Date must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(e.minimum))}`:n="Invalid input";break;case T.too_big:e.type==="array"?n=`Array must contain ${e.exact?"exactly":e.inclusive?"at most":"less than"} ${e.maximum} element(s)`:e.type==="string"?n=`String must contain ${e.exact?"exactly":e.inclusive?"at most":"under"} ${e.maximum} character(s)`:e.type==="number"?n=`Number must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:e.type==="bigint"?n=`BigInt must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:e.type==="date"?n=`Date must be ${e.exact?"exactly":e.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(e.maximum))}`:n="Invalid input";break;case T.custom:n="Invalid input";break;case T.invalid_intersection_types:n="Intersection results could not be merged";break;case T.not_multiple_of:n=`Number must be a multiple of ${e.multipleOf}`;break;case T.not_finite:n="Number must be finite";break;default:n=t.defaultError,ce.assertNever(e)}return{message:n}},pr=n0;var o0=pr;function Mo(){return o0}var Xa=e=>{let{data:t,path:n,errorMaps:o,issueData:r}=e,i=[...n,...r.path||[]],a={...r,path:i};if(r.message!==void 0)return{...r,path:i,message:r.message};let s="",c=o.filter(l=>!!l).slice().reverse();for(let l of c)s=l(a,{data:t,defaultError:s}).message;return{...r,path:i,message:s}};function C(e,t){let n=Mo(),o=Xa({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,n,n===pr?void 0:pr].filter(r=>!!r)});e.common.issues.push(o)}var qe=class e{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(t,n){let o=[];for(let r of n){if(r.status==="aborted")return J;r.status==="dirty"&&t.dirty(),o.push(r.value)}return{status:t.value,value:o}}static async mergeObjectAsync(t,n){let o=[];for(let r of n){let i=await r.key,a=await r.value;o.push({key:i,value:a})}return e.mergeObjectSync(t,o)}static mergeObjectSync(t,n){let o={};for(let r of n){let{key:i,value:a}=r;if(i.status==="aborted"||a.status==="aborted")return J;i.status==="dirty"&&t.dirty(),a.status==="dirty"&&t.dirty(),i.value!=="__proto__"&&(typeof a.value<"u"||r.alwaysSet)&&(o[i.value]=a.value)}return{status:t.value,value:o}}},J=Object.freeze({status:"aborted"}),yn=e=>({status:"dirty",value:e}),Ge=e=>({status:"valid",value:e}),Sd=e=>e.status==="aborted",zd=e=>e.status==="dirty",Br=e=>e.status==="valid",Lo=e=>typeof Promise<"u"&&e instanceof Promise;var q;(function(e){e.errToObj=t=>typeof t=="string"?{message:t}:t||{},e.toString=t=>typeof t=="string"?t:t?.message})(q||(q={}));var gt=class{constructor(t,n,o,r){this._cachedPath=[],this.parent=t,this.data=n,this._path=o,this._key=r}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}},Hg=(e,t)=>{if(Br(t))return{success:!0,data:t.value};if(!e.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;let n=new ut(e.common.issues);return this._error=n,this._error}}};function Y(e){if(!e)return{};let{errorMap:t,invalid_type_error:n,required_error:o,description:r}=e;if(t&&(n||o))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return t?{errorMap:t,description:r}:{errorMap:(a,s)=>{let{message:c}=e;return a.code==="invalid_enum_value"?{message:c??s.defaultError}:typeof s.data>"u"?{message:c??o??s.defaultError}:a.code!=="invalid_type"?{message:s.defaultError}:{message:c??n??s.defaultError}},description:r}}var ne=class{get description(){return this._def.description}_getType(t){return Xt(t.data)}_getOrReturnCtx(t,n){return n||{common:t.parent.common,data:t.data,parsedType:Xt(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}_processInputParams(t){return{status:new qe,ctx:{common:t.parent.common,data:t.data,parsedType:Xt(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}}_parseSync(t){let n=this._parse(t);if(Lo(n))throw new Error("Synchronous parse encountered promise.");return n}_parseAsync(t){let n=this._parse(t);return Promise.resolve(n)}parse(t,n){let o=this.safeParse(t,n);if(o.success)return o.data;throw o.error}safeParse(t,n){let o={common:{issues:[],async:n?.async??!1,contextualErrorMap:n?.errorMap},path:n?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:Xt(t)},r=this._parseSync({data:t,path:o.path,parent:o});return Hg(o,r)}"~validate"(t){let n={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:Xt(t)};if(!this["~standard"].async)try{let o=this._parseSync({data:t,path:[],parent:n});return Br(o)?{value:o.value}:{issues:n.common.issues}}catch(o){o?.message?.toLowerCase()?.includes("encountered")&&(this["~standard"].async=!0),n.common={issues:[],async:!0}}return this._parseAsync({data:t,path:[],parent:n}).then(o=>Br(o)?{value:o.value}:{issues:n.common.issues})}async parseAsync(t,n){let o=await this.safeParseAsync(t,n);if(o.success)return o.data;throw o.error}async safeParseAsync(t,n){let o={common:{issues:[],contextualErrorMap:n?.errorMap,async:!0},path:n?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:Xt(t)},r=this._parse({data:t,path:o.path,parent:o}),i=await(Lo(r)?r:Promise.resolve(r));return Hg(o,i)}refine(t,n){let o=r=>typeof n=="string"||typeof n>"u"?{message:n}:typeof n=="function"?n(r):n;return this._refinement((r,i)=>{let a=t(r),s=()=>i.addIssue({code:T.custom,...o(r)});return typeof Promise<"u"&&a instanceof Promise?a.then(c=>c?!0:(s(),!1)):a?!0:(s(),!1)})}refinement(t,n){return this._refinement((o,r)=>t(o)?!0:(r.addIssue(typeof n=="function"?n(o,r):n),!1))}_refinement(t){return new It({schema:this,typeName:P.ZodEffects,effect:{type:"refinement",refinement:t}})}superRefine(t){return this._refinement(t)}constructor(t){this.spa=this.safeParseAsync,this._def=t,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:n=>this["~validate"](n)}}optional(){return zt.create(this,this._def)}nullable(){return er.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return hr.create(this)}promise(){return Kr.create(this,this._def)}or(t){return kn.create([this,t],this._def)}and(t){return Sn.create(this,t,this._def)}transform(t){return new It({...Y(this._def),schema:this,typeName:P.ZodEffects,effect:{type:"transform",transform:t}})}default(t){let n=typeof t=="function"?t:()=>t;return new On({...Y(this._def),innerType:this,defaultValue:n,typeName:P.ZodDefault})}brand(){return new Ya({typeName:P.ZodBranded,type:this,...Y(this._def)})}catch(t){let n=typeof t=="function"?t:()=>t;return new Pn({...Y(this._def),innerType:this,catchValue:n,typeName:P.ZodCatch})}describe(t){let n=this.constructor;return new n({...this._def,description:t})}pipe(t){return Qa.create(this,t)}readonly(){return jn.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}},i0=/^c[^\s-]{8,}$/i,a0=/^[0-9a-z]+$/,s0=/^[0-9A-HJKMNP-TV-Z]{26}$/i,c0=/^[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,u0=/^[a-z0-9_-]{21}$/i,l0=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,d0=/^[-+]?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)?)??$/,f0=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,p0="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$",Id,m0=/^(?:(?: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])$/,h0=/^(?:(?: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])$/,g0=/^(([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]))$/,v0=/^(([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])$/,_0=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,y0=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,Jg="((\\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])))",b0=new RegExp(`^${Jg}$`);function Gg(e){let t="[0-5]\\d";e.precision?t=`${t}\\.\\d{${e.precision}}`:e.precision==null&&(t=`${t}(\\.\\d+)?`);let n=e.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${t})${n}`}function $0(e){return new RegExp(`^${Gg(e)}$`)}function x0(e){let t=`${Jg}T${Gg(e)}`,n=[];return n.push(e.local?"Z?":"Z"),e.offset&&n.push("([+-]\\d{2}:?\\d{2})"),t=`${t}(${n.join("|")})`,new RegExp(`^${t}$`)}function w0(e,t){return!!((t==="v4"||!t)&&m0.test(e)||(t==="v6"||!t)&&g0.test(e))}function k0(e,t){if(!l0.test(e))return!1;try{let[n]=e.split(".");if(!n)return!1;let o=n.replace(/-/g,"+").replace(/_/g,"/").padEnd(n.length+(4-n.length%4)%4,"="),r=JSON.parse(atob(o));return!(typeof r!="object"||r===null||"typ"in r&&r?.typ!=="JWT"||!r.alg||t&&r.alg!==t)}catch{return!1}}function S0(e,t){return!!((t==="v4"||!t)&&h0.test(e)||(t==="v6"||!t)&&v0.test(e))}var $n=class e extends ne{_parse(t){if(this._def.coerce&&(t.data=String(t.data)),this._getType(t)!==U.string){let i=this._getOrReturnCtx(t);return C(i,{code:T.invalid_type,expected:U.string,received:i.parsedType}),J}let o=new qe,r;for(let i of this._def.checks)if(i.kind==="min")t.data.length<i.value&&(r=this._getOrReturnCtx(t,r),C(r,{code:T.too_small,minimum:i.value,type:"string",inclusive:!0,exact:!1,message:i.message}),o.dirty());else if(i.kind==="max")t.data.length>i.value&&(r=this._getOrReturnCtx(t,r),C(r,{code:T.too_big,maximum:i.value,type:"string",inclusive:!0,exact:!1,message:i.message}),o.dirty());else if(i.kind==="length"){let a=t.data.length>i.value,s=t.data.length<i.value;(a||s)&&(r=this._getOrReturnCtx(t,r),a?C(r,{code:T.too_big,maximum:i.value,type:"string",inclusive:!0,exact:!0,message:i.message}):s&&C(r,{code:T.too_small,minimum:i.value,type:"string",inclusive:!0,exact:!0,message:i.message}),o.dirty())}else if(i.kind==="email")f0.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"email",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="emoji")Id||(Id=new RegExp(p0,"u")),Id.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"emoji",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="uuid")c0.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"uuid",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="nanoid")u0.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"nanoid",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="cuid")i0.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"cuid",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="cuid2")a0.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"cuid2",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="ulid")s0.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"ulid",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="url")try{new URL(t.data)}catch{r=this._getOrReturnCtx(t,r),C(r,{validation:"url",code:T.invalid_string,message:i.message}),o.dirty()}else i.kind==="regex"?(i.regex.lastIndex=0,i.regex.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"regex",code:T.invalid_string,message:i.message}),o.dirty())):i.kind==="trim"?t.data=t.data.trim():i.kind==="includes"?t.data.includes(i.value,i.position)||(r=this._getOrReturnCtx(t,r),C(r,{code:T.invalid_string,validation:{includes:i.value,position:i.position},message:i.message}),o.dirty()):i.kind==="toLowerCase"?t.data=t.data.toLowerCase():i.kind==="toUpperCase"?t.data=t.data.toUpperCase():i.kind==="startsWith"?t.data.startsWith(i.value)||(r=this._getOrReturnCtx(t,r),C(r,{code:T.invalid_string,validation:{startsWith:i.value},message:i.message}),o.dirty()):i.kind==="endsWith"?t.data.endsWith(i.value)||(r=this._getOrReturnCtx(t,r),C(r,{code:T.invalid_string,validation:{endsWith:i.value},message:i.message}),o.dirty()):i.kind==="datetime"?x0(i).test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{code:T.invalid_string,validation:"datetime",message:i.message}),o.dirty()):i.kind==="date"?b0.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{code:T.invalid_string,validation:"date",message:i.message}),o.dirty()):i.kind==="time"?$0(i).test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{code:T.invalid_string,validation:"time",message:i.message}),o.dirty()):i.kind==="duration"?d0.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"duration",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="ip"?w0(t.data,i.version)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"ip",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="jwt"?k0(t.data,i.alg)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"jwt",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="cidr"?S0(t.data,i.version)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"cidr",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="base64"?_0.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"base64",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="base64url"?y0.test(t.data)||(r=this._getOrReturnCtx(t,r),C(r,{validation:"base64url",code:T.invalid_string,message:i.message}),o.dirty()):ce.assertNever(i);return{status:o.value,value:t.data}}_regex(t,n,o){return this.refinement(r=>t.test(r),{validation:n,code:T.invalid_string,...q.errToObj(o)})}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}email(t){return this._addCheck({kind:"email",...q.errToObj(t)})}url(t){return this._addCheck({kind:"url",...q.errToObj(t)})}emoji(t){return this._addCheck({kind:"emoji",...q.errToObj(t)})}uuid(t){return this._addCheck({kind:"uuid",...q.errToObj(t)})}nanoid(t){return this._addCheck({kind:"nanoid",...q.errToObj(t)})}cuid(t){return this._addCheck({kind:"cuid",...q.errToObj(t)})}cuid2(t){return this._addCheck({kind:"cuid2",...q.errToObj(t)})}ulid(t){return this._addCheck({kind:"ulid",...q.errToObj(t)})}base64(t){return this._addCheck({kind:"base64",...q.errToObj(t)})}base64url(t){return this._addCheck({kind:"base64url",...q.errToObj(t)})}jwt(t){return this._addCheck({kind:"jwt",...q.errToObj(t)})}ip(t){return this._addCheck({kind:"ip",...q.errToObj(t)})}cidr(t){return this._addCheck({kind:"cidr",...q.errToObj(t)})}datetime(t){return typeof t=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:t}):this._addCheck({kind:"datetime",precision:typeof t?.precision>"u"?null:t?.precision,offset:t?.offset??!1,local:t?.local??!1,...q.errToObj(t?.message)})}date(t){return this._addCheck({kind:"date",message:t})}time(t){return typeof t=="string"?this._addCheck({kind:"time",precision:null,message:t}):this._addCheck({kind:"time",precision:typeof t?.precision>"u"?null:t?.precision,...q.errToObj(t?.message)})}duration(t){return this._addCheck({kind:"duration",...q.errToObj(t)})}regex(t,n){return this._addCheck({kind:"regex",regex:t,...q.errToObj(n)})}includes(t,n){return this._addCheck({kind:"includes",value:t,position:n?.position,...q.errToObj(n?.message)})}startsWith(t,n){return this._addCheck({kind:"startsWith",value:t,...q.errToObj(n)})}endsWith(t,n){return this._addCheck({kind:"endsWith",value:t,...q.errToObj(n)})}min(t,n){return this._addCheck({kind:"min",value:t,...q.errToObj(n)})}max(t,n){return this._addCheck({kind:"max",value:t,...q.errToObj(n)})}length(t,n){return this._addCheck({kind:"length",value:t,...q.errToObj(n)})}nonempty(t){return this.min(1,q.errToObj(t))}trim(){return new e({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new e({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new e({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(t=>t.kind==="datetime")}get isDate(){return!!this._def.checks.find(t=>t.kind==="date")}get isTime(){return!!this._def.checks.find(t=>t.kind==="time")}get isDuration(){return!!this._def.checks.find(t=>t.kind==="duration")}get isEmail(){return!!this._def.checks.find(t=>t.kind==="email")}get isURL(){return!!this._def.checks.find(t=>t.kind==="url")}get isEmoji(){return!!this._def.checks.find(t=>t.kind==="emoji")}get isUUID(){return!!this._def.checks.find(t=>t.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(t=>t.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(t=>t.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(t=>t.kind==="cuid2")}get isULID(){return!!this._def.checks.find(t=>t.kind==="ulid")}get isIP(){return!!this._def.checks.find(t=>t.kind==="ip")}get isCIDR(){return!!this._def.checks.find(t=>t.kind==="cidr")}get isBase64(){return!!this._def.checks.find(t=>t.kind==="base64")}get isBase64url(){return!!this._def.checks.find(t=>t.kind==="base64url")}get minLength(){let t=null;for(let n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t}get maxLength(){let t=null;for(let n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t}};$n.create=e=>new $n({checks:[],typeName:P.ZodString,coerce:e?.coerce??!1,...Y(e)});function z0(e,t){let n=(e.toString().split(".")[1]||"").length,o=(t.toString().split(".")[1]||"").length,r=n>o?n:o,i=Number.parseInt(e.toFixed(r).replace(".","")),a=Number.parseInt(t.toFixed(r).replace(".",""));return i%a/10**r}var qo=class e extends ne{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(t){if(this._def.coerce&&(t.data=Number(t.data)),this._getType(t)!==U.number){let i=this._getOrReturnCtx(t);return C(i,{code:T.invalid_type,expected:U.number,received:i.parsedType}),J}let o,r=new qe;for(let i of this._def.checks)i.kind==="int"?ce.isInteger(t.data)||(o=this._getOrReturnCtx(t,o),C(o,{code:T.invalid_type,expected:"integer",received:"float",message:i.message}),r.dirty()):i.kind==="min"?(i.inclusive?t.data<i.value:t.data<=i.value)&&(o=this._getOrReturnCtx(t,o),C(o,{code:T.too_small,minimum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),r.dirty()):i.kind==="max"?(i.inclusive?t.data>i.value:t.data>=i.value)&&(o=this._getOrReturnCtx(t,o),C(o,{code:T.too_big,maximum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),r.dirty()):i.kind==="multipleOf"?z0(t.data,i.value)!==0&&(o=this._getOrReturnCtx(t,o),C(o,{code:T.not_multiple_of,multipleOf:i.value,message:i.message}),r.dirty()):i.kind==="finite"?Number.isFinite(t.data)||(o=this._getOrReturnCtx(t,o),C(o,{code:T.not_finite,message:i.message}),r.dirty()):ce.assertNever(i);return{status:r.value,value:t.data}}gte(t,n){return this.setLimit("min",t,!0,q.toString(n))}gt(t,n){return this.setLimit("min",t,!1,q.toString(n))}lte(t,n){return this.setLimit("max",t,!0,q.toString(n))}lt(t,n){return this.setLimit("max",t,!1,q.toString(n))}setLimit(t,n,o,r){return new e({...this._def,checks:[...this._def.checks,{kind:t,value:n,inclusive:o,message:q.toString(r)}]})}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}int(t){return this._addCheck({kind:"int",message:q.toString(t)})}positive(t){return this._addCheck({kind:"min",value:0,inclusive:!1,message:q.toString(t)})}negative(t){return this._addCheck({kind:"max",value:0,inclusive:!1,message:q.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:0,inclusive:!0,message:q.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:0,inclusive:!0,message:q.toString(t)})}multipleOf(t,n){return this._addCheck({kind:"multipleOf",value:t,message:q.toString(n)})}finite(t){return this._addCheck({kind:"finite",message:q.toString(t)})}safe(t){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:q.toString(t)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:q.toString(t)})}get minValue(){let t=null;for(let n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t}get maxValue(){let t=null;for(let n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t}get isInt(){return!!this._def.checks.find(t=>t.kind==="int"||t.kind==="multipleOf"&&ce.isInteger(t.value))}get isFinite(){let t=null,n=null;for(let o of this._def.checks){if(o.kind==="finite"||o.kind==="int"||o.kind==="multipleOf")return!0;o.kind==="min"?(n===null||o.value>n)&&(n=o.value):o.kind==="max"&&(t===null||o.value<t)&&(t=o.value)}return Number.isFinite(n)&&Number.isFinite(t)}};qo.create=e=>new qo({checks:[],typeName:P.ZodNumber,coerce:e?.coerce||!1,...Y(e)});var Vo=class e extends ne{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(t){if(this._def.coerce)try{t.data=BigInt(t.data)}catch{return this._getInvalidInput(t)}if(this._getType(t)!==U.bigint)return this._getInvalidInput(t);let o,r=new qe;for(let i of this._def.checks)i.kind==="min"?(i.inclusive?t.data<i.value:t.data<=i.value)&&(o=this._getOrReturnCtx(t,o),C(o,{code:T.too_small,type:"bigint",minimum:i.value,inclusive:i.inclusive,message:i.message}),r.dirty()):i.kind==="max"?(i.inclusive?t.data>i.value:t.data>=i.value)&&(o=this._getOrReturnCtx(t,o),C(o,{code:T.too_big,type:"bigint",maximum:i.value,inclusive:i.inclusive,message:i.message}),r.dirty()):i.kind==="multipleOf"?t.data%i.value!==BigInt(0)&&(o=this._getOrReturnCtx(t,o),C(o,{code:T.not_multiple_of,multipleOf:i.value,message:i.message}),r.dirty()):ce.assertNever(i);return{status:r.value,value:t.data}}_getInvalidInput(t){let n=this._getOrReturnCtx(t);return C(n,{code:T.invalid_type,expected:U.bigint,received:n.parsedType}),J}gte(t,n){return this.setLimit("min",t,!0,q.toString(n))}gt(t,n){return this.setLimit("min",t,!1,q.toString(n))}lte(t,n){return this.setLimit("max",t,!0,q.toString(n))}lt(t,n){return this.setLimit("max",t,!1,q.toString(n))}setLimit(t,n,o,r){return new e({...this._def,checks:[...this._def.checks,{kind:t,value:n,inclusive:o,message:q.toString(r)}]})}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}positive(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:q.toString(t)})}negative(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:q.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:q.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:q.toString(t)})}multipleOf(t,n){return this._addCheck({kind:"multipleOf",value:t,message:q.toString(n)})}get minValue(){let t=null;for(let n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t}get maxValue(){let t=null;for(let n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t}};Vo.create=e=>new Vo({checks:[],typeName:P.ZodBigInt,coerce:e?.coerce??!1,...Y(e)});var Fo=class extends ne{_parse(t){if(this._def.coerce&&(t.data=!!t.data),this._getType(t)!==U.boolean){let o=this._getOrReturnCtx(t);return C(o,{code:T.invalid_type,expected:U.boolean,received:o.parsedType}),J}return Ge(t.data)}};Fo.create=e=>new Fo({typeName:P.ZodBoolean,coerce:e?.coerce||!1,...Y(e)});var Bo=class e extends ne{_parse(t){if(this._def.coerce&&(t.data=new Date(t.data)),this._getType(t)!==U.date){let i=this._getOrReturnCtx(t);return C(i,{code:T.invalid_type,expected:U.date,received:i.parsedType}),J}if(Number.isNaN(t.data.getTime())){let i=this._getOrReturnCtx(t);return C(i,{code:T.invalid_date}),J}let o=new qe,r;for(let i of this._def.checks)i.kind==="min"?t.data.getTime()<i.value&&(r=this._getOrReturnCtx(t,r),C(r,{code:T.too_small,message:i.message,inclusive:!0,exact:!1,minimum:i.value,type:"date"}),o.dirty()):i.kind==="max"?t.data.getTime()>i.value&&(r=this._getOrReturnCtx(t,r),C(r,{code:T.too_big,message:i.message,inclusive:!0,exact:!1,maximum:i.value,type:"date"}),o.dirty()):ce.assertNever(i);return{status:o.value,value:new Date(t.data.getTime())}}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}min(t,n){return this._addCheck({kind:"min",value:t.getTime(),message:q.toString(n)})}max(t,n){return this._addCheck({kind:"max",value:t.getTime(),message:q.toString(n)})}get minDate(){let t=null;for(let n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t!=null?new Date(t):null}get maxDate(){let t=null;for(let n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t!=null?new Date(t):null}};Bo.create=e=>new Bo({checks:[],coerce:e?.coerce||!1,typeName:P.ZodDate,...Y(e)});var Ko=class extends ne{_parse(t){if(this._getType(t)!==U.symbol){let o=this._getOrReturnCtx(t);return C(o,{code:T.invalid_type,expected:U.symbol,received:o.parsedType}),J}return Ge(t.data)}};Ko.create=e=>new Ko({typeName:P.ZodSymbol,...Y(e)});var xn=class extends ne{_parse(t){if(this._getType(t)!==U.undefined){let o=this._getOrReturnCtx(t);return C(o,{code:T.invalid_type,expected:U.undefined,received:o.parsedType}),J}return Ge(t.data)}};xn.create=e=>new xn({typeName:P.ZodUndefined,...Y(e)});var wn=class extends ne{_parse(t){if(this._getType(t)!==U.null){let o=this._getOrReturnCtx(t);return C(o,{code:T.invalid_type,expected:U.null,received:o.parsedType}),J}return Ge(t.data)}};wn.create=e=>new wn({typeName:P.ZodNull,...Y(e)});var Ho=class extends ne{constructor(){super(...arguments),this._any=!0}_parse(t){return Ge(t.data)}};Ho.create=e=>new Ho({typeName:P.ZodAny,...Y(e)});var mr=class extends ne{constructor(){super(...arguments),this._unknown=!0}_parse(t){return Ge(t.data)}};mr.create=e=>new mr({typeName:P.ZodUnknown,...Y(e)});var Ct=class extends ne{_parse(t){let n=this._getOrReturnCtx(t);return C(n,{code:T.invalid_type,expected:U.never,received:n.parsedType}),J}};Ct.create=e=>new Ct({typeName:P.ZodNever,...Y(e)});var Jo=class extends ne{_parse(t){if(this._getType(t)!==U.undefined){let o=this._getOrReturnCtx(t);return C(o,{code:T.invalid_type,expected:U.void,received:o.parsedType}),J}return Ge(t.data)}};Jo.create=e=>new Jo({typeName:P.ZodVoid,...Y(e)});var hr=class e extends ne{_parse(t){let{ctx:n,status:o}=this._processInputParams(t),r=this._def;if(n.parsedType!==U.array)return C(n,{code:T.invalid_type,expected:U.array,received:n.parsedType}),J;if(r.exactLength!==null){let a=n.data.length>r.exactLength.value,s=n.data.length<r.exactLength.value;(a||s)&&(C(n,{code:a?T.too_big:T.too_small,minimum:s?r.exactLength.value:void 0,maximum:a?r.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:r.exactLength.message}),o.dirty())}if(r.minLength!==null&&n.data.length<r.minLength.value&&(C(n,{code:T.too_small,minimum:r.minLength.value,type:"array",inclusive:!0,exact:!1,message:r.minLength.message}),o.dirty()),r.maxLength!==null&&n.data.length>r.maxLength.value&&(C(n,{code:T.too_big,maximum:r.maxLength.value,type:"array",inclusive:!0,exact:!1,message:r.maxLength.message}),o.dirty()),n.common.async)return Promise.all([...n.data].map((a,s)=>r.type._parseAsync(new gt(n,a,n.path,s)))).then(a=>qe.mergeArray(o,a));let i=[...n.data].map((a,s)=>r.type._parseSync(new gt(n,a,n.path,s)));return qe.mergeArray(o,i)}get element(){return this._def.type}min(t,n){return new e({...this._def,minLength:{value:t,message:q.toString(n)}})}max(t,n){return new e({...this._def,maxLength:{value:t,message:q.toString(n)}})}length(t,n){return new e({...this._def,exactLength:{value:t,message:q.toString(n)}})}nonempty(t){return this.min(1,t)}};hr.create=(e,t)=>new hr({type:e,minLength:null,maxLength:null,exactLength:null,typeName:P.ZodArray,...Y(t)});function bn(e){if(e instanceof lt){let t={};for(let n in e.shape){let o=e.shape[n];t[n]=zt.create(bn(o))}return new lt({...e._def,shape:()=>t})}else return e instanceof hr?new hr({...e._def,type:bn(e.element)}):e instanceof zt?zt.create(bn(e.unwrap())):e instanceof er?er.create(bn(e.unwrap())):e instanceof Qt?Qt.create(e.items.map(t=>bn(t))):e}var lt=class e extends ne{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;let t=this._def.shape(),n=ce.objectKeys(t);return this._cached={shape:t,keys:n},this._cached}_parse(t){if(this._getType(t)!==U.object){let l=this._getOrReturnCtx(t);return C(l,{code:T.invalid_type,expected:U.object,received:l.parsedType}),J}let{status:o,ctx:r}=this._processInputParams(t),{shape:i,keys:a}=this._getCached(),s=[];if(!(this._def.catchall instanceof Ct&&this._def.unknownKeys==="strip"))for(let l in r.data)a.includes(l)||s.push(l);let c=[];for(let l of a){let d=i[l],f=r.data[l];c.push({key:{status:"valid",value:l},value:d._parse(new gt(r,f,r.path,l)),alwaysSet:l in r.data})}if(this._def.catchall instanceof Ct){let l=this._def.unknownKeys;if(l==="passthrough")for(let d of s)c.push({key:{status:"valid",value:d},value:{status:"valid",value:r.data[d]}});else if(l==="strict")s.length>0&&(C(r,{code:T.unrecognized_keys,keys:s}),o.dirty());else if(l!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{let l=this._def.catchall;for(let d of s){let f=r.data[d];c.push({key:{status:"valid",value:d},value:l._parse(new gt(r,f,r.path,d)),alwaysSet:d in r.data})}}return r.common.async?Promise.resolve().then(async()=>{let l=[];for(let d of c){let f=await d.key,_=await d.value;l.push({key:f,value:_,alwaysSet:d.alwaysSet})}return l}).then(l=>qe.mergeObjectSync(o,l)):qe.mergeObjectSync(o,c)}get shape(){return this._def.shape()}strict(t){return q.errToObj,new e({...this._def,unknownKeys:"strict",...t!==void 0?{errorMap:(n,o)=>{let r=this._def.errorMap?.(n,o).message??o.defaultError;return n.code==="unrecognized_keys"?{message:q.errToObj(t).message??r}:{message:r}}}:{}})}strip(){return new e({...this._def,unknownKeys:"strip"})}passthrough(){return new e({...this._def,unknownKeys:"passthrough"})}extend(t){return new e({...this._def,shape:()=>({...this._def.shape(),...t})})}merge(t){return new e({unknownKeys:t._def.unknownKeys,catchall:t._def.catchall,shape:()=>({...this._def.shape(),...t._def.shape()}),typeName:P.ZodObject})}setKey(t,n){return this.augment({[t]:n})}catchall(t){return new e({...this._def,catchall:t})}pick(t){let n={};for(let o of ce.objectKeys(t))t[o]&&this.shape[o]&&(n[o]=this.shape[o]);return new e({...this._def,shape:()=>n})}omit(t){let n={};for(let o of ce.objectKeys(this.shape))t[o]||(n[o]=this.shape[o]);return new e({...this._def,shape:()=>n})}deepPartial(){return bn(this)}partial(t){let n={};for(let o of ce.objectKeys(this.shape)){let r=this.shape[o];t&&!t[o]?n[o]=r:n[o]=r.optional()}return new e({...this._def,shape:()=>n})}required(t){let n={};for(let o of ce.objectKeys(this.shape))if(t&&!t[o])n[o]=this.shape[o];else{let i=this.shape[o];for(;i instanceof zt;)i=i._def.innerType;n[o]=i}return new e({...this._def,shape:()=>n})}keyof(){return Wg(ce.objectKeys(this.shape))}};lt.create=(e,t)=>new lt({shape:()=>e,unknownKeys:"strip",catchall:Ct.create(),typeName:P.ZodObject,...Y(t)});lt.strictCreate=(e,t)=>new lt({shape:()=>e,unknownKeys:"strict",catchall:Ct.create(),typeName:P.ZodObject,...Y(t)});lt.lazycreate=(e,t)=>new lt({shape:e,unknownKeys:"strip",catchall:Ct.create(),typeName:P.ZodObject,...Y(t)});var kn=class extends ne{_parse(t){let{ctx:n}=this._processInputParams(t),o=this._def.options;function r(i){for(let s of i)if(s.result.status==="valid")return s.result;for(let s of i)if(s.result.status==="dirty")return n.common.issues.push(...s.ctx.common.issues),s.result;let a=i.map(s=>new ut(s.ctx.common.issues));return C(n,{code:T.invalid_union,unionErrors:a}),J}if(n.common.async)return Promise.all(o.map(async i=>{let a={...n,common:{...n.common,issues:[]},parent:null};return{result:await i._parseAsync({data:n.data,path:n.path,parent:a}),ctx:a}})).then(r);{let i,a=[];for(let c of o){let l={...n,common:{...n.common,issues:[]},parent:null},d=c._parseSync({data:n.data,path:n.path,parent:l});if(d.status==="valid")return d;d.status==="dirty"&&!i&&(i={result:d,ctx:l}),l.common.issues.length&&a.push(l.common.issues)}if(i)return n.common.issues.push(...i.ctx.common.issues),i.result;let s=a.map(c=>new ut(c));return C(n,{code:T.invalid_union,unionErrors:s}),J}}get options(){return this._def.options}};kn.create=(e,t)=>new kn({options:e,typeName:P.ZodUnion,...Y(t)});var Yt=e=>e instanceof zn?Yt(e.schema):e instanceof It?Yt(e.innerType()):e instanceof In?[e.value]:e instanceof En?e.options:e instanceof Tn?ce.objectValues(e.enum):e instanceof On?Yt(e._def.innerType):e instanceof xn?[void 0]:e instanceof wn?[null]:e instanceof zt?[void 0,...Yt(e.unwrap())]:e instanceof er?[null,...Yt(e.unwrap())]:e instanceof Ya||e instanceof jn?Yt(e.unwrap()):e instanceof Pn?Yt(e._def.innerType):[],Ed=class e extends ne{_parse(t){let{ctx:n}=this._processInputParams(t);if(n.parsedType!==U.object)return C(n,{code:T.invalid_type,expected:U.object,received:n.parsedType}),J;let o=this.discriminator,r=n.data[o],i=this.optionsMap.get(r);return i?n.common.async?i._parseAsync({data:n.data,path:n.path,parent:n}):i._parseSync({data:n.data,path:n.path,parent:n}):(C(n,{code:T.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[o]}),J)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(t,n,o){let r=new Map;for(let i of n){let a=Yt(i.shape[t]);if(!a.length)throw new Error(`A discriminator value for key \`${t}\` could not be extracted from all schema options`);for(let s of a){if(r.has(s))throw new Error(`Discriminator property ${String(t)} has duplicate value ${String(s)}`);r.set(s,i)}}return new e({typeName:P.ZodDiscriminatedUnion,discriminator:t,options:n,optionsMap:r,...Y(o)})}};function Td(e,t){let n=Xt(e),o=Xt(t);if(e===t)return{valid:!0,data:e};if(n===U.object&&o===U.object){let r=ce.objectKeys(t),i=ce.objectKeys(e).filter(s=>r.indexOf(s)!==-1),a={...e,...t};for(let s of i){let c=Td(e[s],t[s]);if(!c.valid)return{valid:!1};a[s]=c.data}return{valid:!0,data:a}}else if(n===U.array&&o===U.array){if(e.length!==t.length)return{valid:!1};let r=[];for(let i=0;i<e.length;i++){let a=e[i],s=t[i],c=Td(a,s);if(!c.valid)return{valid:!1};r.push(c.data)}return{valid:!0,data:r}}else return n===U.date&&o===U.date&&+e==+t?{valid:!0,data:e}:{valid:!1}}var Sn=class extends ne{_parse(t){let{status:n,ctx:o}=this._processInputParams(t),r=(i,a)=>{if(Sd(i)||Sd(a))return J;let s=Td(i.value,a.value);return s.valid?((zd(i)||zd(a))&&n.dirty(),{status:n.value,value:s.data}):(C(o,{code:T.invalid_intersection_types}),J)};return o.common.async?Promise.all([this._def.left._parseAsync({data:o.data,path:o.path,parent:o}),this._def.right._parseAsync({data:o.data,path:o.path,parent:o})]).then(([i,a])=>r(i,a)):r(this._def.left._parseSync({data:o.data,path:o.path,parent:o}),this._def.right._parseSync({data:o.data,path:o.path,parent:o}))}};Sn.create=(e,t,n)=>new Sn({left:e,right:t,typeName:P.ZodIntersection,...Y(n)});var Qt=class e extends ne{_parse(t){let{status:n,ctx:o}=this._processInputParams(t);if(o.parsedType!==U.array)return C(o,{code:T.invalid_type,expected:U.array,received:o.parsedType}),J;if(o.data.length<this._def.items.length)return C(o,{code:T.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),J;!this._def.rest&&o.data.length>this._def.items.length&&(C(o,{code:T.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),n.dirty());let i=[...o.data].map((a,s)=>{let c=this._def.items[s]||this._def.rest;return c?c._parse(new gt(o,a,o.path,s)):null}).filter(a=>!!a);return o.common.async?Promise.all(i).then(a=>qe.mergeArray(n,a)):qe.mergeArray(n,i)}get items(){return this._def.items}rest(t){return new e({...this._def,rest:t})}};Qt.create=(e,t)=>{if(!Array.isArray(e))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new Qt({items:e,typeName:P.ZodTuple,rest:null,...Y(t)})};var Od=class e extends ne{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){let{status:n,ctx:o}=this._processInputParams(t);if(o.parsedType!==U.object)return C(o,{code:T.invalid_type,expected:U.object,received:o.parsedType}),J;let r=[],i=this._def.keyType,a=this._def.valueType;for(let s in o.data)r.push({key:i._parse(new gt(o,s,o.path,s)),value:a._parse(new gt(o,o.data[s],o.path,s)),alwaysSet:s in o.data});return o.common.async?qe.mergeObjectAsync(n,r):qe.mergeObjectSync(n,r)}get element(){return this._def.valueType}static create(t,n,o){return n instanceof ne?new e({keyType:t,valueType:n,typeName:P.ZodRecord,...Y(o)}):new e({keyType:$n.create(),valueType:t,typeName:P.ZodRecord,...Y(n)})}},Go=class extends ne{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){let{status:n,ctx:o}=this._processInputParams(t);if(o.parsedType!==U.map)return C(o,{code:T.invalid_type,expected:U.map,received:o.parsedType}),J;let r=this._def.keyType,i=this._def.valueType,a=[...o.data.entries()].map(([s,c],l)=>({key:r._parse(new gt(o,s,o.path,[l,"key"])),value:i._parse(new gt(o,c,o.path,[l,"value"]))}));if(o.common.async){let s=new Map;return Promise.resolve().then(async()=>{for(let c of a){let l=await c.key,d=await c.value;if(l.status==="aborted"||d.status==="aborted")return J;(l.status==="dirty"||d.status==="dirty")&&n.dirty(),s.set(l.value,d.value)}return{status:n.value,value:s}})}else{let s=new Map;for(let c of a){let l=c.key,d=c.value;if(l.status==="aborted"||d.status==="aborted")return J;(l.status==="dirty"||d.status==="dirty")&&n.dirty(),s.set(l.value,d.value)}return{status:n.value,value:s}}}};Go.create=(e,t,n)=>new Go({valueType:t,keyType:e,typeName:P.ZodMap,...Y(n)});var Wo=class e extends ne{_parse(t){let{status:n,ctx:o}=this._processInputParams(t);if(o.parsedType!==U.set)return C(o,{code:T.invalid_type,expected:U.set,received:o.parsedType}),J;let r=this._def;r.minSize!==null&&o.data.size<r.minSize.value&&(C(o,{code:T.too_small,minimum:r.minSize.value,type:"set",inclusive:!0,exact:!1,message:r.minSize.message}),n.dirty()),r.maxSize!==null&&o.data.size>r.maxSize.value&&(C(o,{code:T.too_big,maximum:r.maxSize.value,type:"set",inclusive:!0,exact:!1,message:r.maxSize.message}),n.dirty());let i=this._def.valueType;function a(c){let l=new Set;for(let d of c){if(d.status==="aborted")return J;d.status==="dirty"&&n.dirty(),l.add(d.value)}return{status:n.value,value:l}}let s=[...o.data.values()].map((c,l)=>i._parse(new gt(o,c,o.path,l)));return o.common.async?Promise.all(s).then(c=>a(c)):a(s)}min(t,n){return new e({...this._def,minSize:{value:t,message:q.toString(n)}})}max(t,n){return new e({...this._def,maxSize:{value:t,message:q.toString(n)}})}size(t,n){return this.min(t,n).max(t,n)}nonempty(t){return this.min(1,t)}};Wo.create=(e,t)=>new Wo({valueType:e,minSize:null,maxSize:null,typeName:P.ZodSet,...Y(t)});var Pd=class e extends ne{constructor(){super(...arguments),this.validate=this.implement}_parse(t){let{ctx:n}=this._processInputParams(t);if(n.parsedType!==U.function)return C(n,{code:T.invalid_type,expected:U.function,received:n.parsedType}),J;function o(s,c){return Xa({data:s,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,Mo(),pr].filter(l=>!!l),issueData:{code:T.invalid_arguments,argumentsError:c}})}function r(s,c){return Xa({data:s,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,Mo(),pr].filter(l=>!!l),issueData:{code:T.invalid_return_type,returnTypeError:c}})}let i={errorMap:n.common.contextualErrorMap},a=n.data;if(this._def.returns instanceof Kr){let s=this;return Ge(async function(...c){let l=new ut([]),d=await s._def.args.parseAsync(c,i).catch(v=>{throw l.addIssue(o(c,v)),l}),f=await Reflect.apply(a,this,d);return await s._def.returns._def.type.parseAsync(f,i).catch(v=>{throw l.addIssue(r(f,v)),l})})}else{let s=this;return Ge(function(...c){let l=s._def.args.safeParse(c,i);if(!l.success)throw new ut([o(c,l.error)]);let d=Reflect.apply(a,this,l.data),f=s._def.returns.safeParse(d,i);if(!f.success)throw new ut([r(d,f.error)]);return f.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...t){return new e({...this._def,args:Qt.create(t).rest(mr.create())})}returns(t){return new e({...this._def,returns:t})}implement(t){return this.parse(t)}strictImplement(t){return this.parse(t)}static create(t,n,o){return new e({args:t||Qt.create([]).rest(mr.create()),returns:n||mr.create(),typeName:P.ZodFunction,...Y(o)})}},zn=class extends ne{get schema(){return this._def.getter()}_parse(t){let{ctx:n}=this._processInputParams(t);return this._def.getter()._parse({data:n.data,path:n.path,parent:n})}};zn.create=(e,t)=>new zn({getter:e,typeName:P.ZodLazy,...Y(t)});var In=class extends ne{_parse(t){if(t.data!==this._def.value){let n=this._getOrReturnCtx(t);return C(n,{received:n.data,code:T.invalid_literal,expected:this._def.value}),J}return{status:"valid",value:t.data}}get value(){return this._def.value}};In.create=(e,t)=>new In({value:e,typeName:P.ZodLiteral,...Y(t)});function Wg(e,t){return new En({values:e,typeName:P.ZodEnum,...Y(t)})}var En=class e extends ne{_parse(t){if(typeof t.data!="string"){let n=this._getOrReturnCtx(t),o=this._def.values;return C(n,{expected:ce.joinValues(o),received:n.parsedType,code:T.invalid_type}),J}if(this._cache||(this._cache=new Set(this._def.values)),!this._cache.has(t.data)){let n=this._getOrReturnCtx(t),o=this._def.values;return C(n,{received:n.data,code:T.invalid_enum_value,options:o}),J}return Ge(t.data)}get options(){return this._def.values}get enum(){let t={};for(let n of this._def.values)t[n]=n;return t}get Values(){let t={};for(let n of this._def.values)t[n]=n;return t}get Enum(){let t={};for(let n of this._def.values)t[n]=n;return t}extract(t,n=this._def){return e.create(t,{...this._def,...n})}exclude(t,n=this._def){return e.create(this.options.filter(o=>!t.includes(o)),{...this._def,...n})}};En.create=Wg;var Tn=class extends ne{_parse(t){let n=ce.getValidEnumValues(this._def.values),o=this._getOrReturnCtx(t);if(o.parsedType!==U.string&&o.parsedType!==U.number){let r=ce.objectValues(n);return C(o,{expected:ce.joinValues(r),received:o.parsedType,code:T.invalid_type}),J}if(this._cache||(this._cache=new Set(ce.getValidEnumValues(this._def.values))),!this._cache.has(t.data)){let r=ce.objectValues(n);return C(o,{received:o.data,code:T.invalid_enum_value,options:r}),J}return Ge(t.data)}get enum(){return this._def.values}};Tn.create=(e,t)=>new Tn({values:e,typeName:P.ZodNativeEnum,...Y(t)});var Kr=class extends ne{unwrap(){return this._def.type}_parse(t){let{ctx:n}=this._processInputParams(t);if(n.parsedType!==U.promise&&n.common.async===!1)return C(n,{code:T.invalid_type,expected:U.promise,received:n.parsedType}),J;let o=n.parsedType===U.promise?n.data:Promise.resolve(n.data);return Ge(o.then(r=>this._def.type.parseAsync(r,{path:n.path,errorMap:n.common.contextualErrorMap})))}};Kr.create=(e,t)=>new Kr({type:e,typeName:P.ZodPromise,...Y(t)});var It=class extends ne{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===P.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(t){let{status:n,ctx:o}=this._processInputParams(t),r=this._def.effect||null,i={addIssue:a=>{C(o,a),a.fatal?n.abort():n.dirty()},get path(){return o.path}};if(i.addIssue=i.addIssue.bind(i),r.type==="preprocess"){let a=r.transform(o.data,i);if(o.common.async)return Promise.resolve(a).then(async s=>{if(n.value==="aborted")return J;let c=await this._def.schema._parseAsync({data:s,path:o.path,parent:o});return c.status==="aborted"?J:c.status==="dirty"?yn(c.value):n.value==="dirty"?yn(c.value):c});{if(n.value==="aborted")return J;let s=this._def.schema._parseSync({data:a,path:o.path,parent:o});return s.status==="aborted"?J:s.status==="dirty"?yn(s.value):n.value==="dirty"?yn(s.value):s}}if(r.type==="refinement"){let a=s=>{let c=r.refinement(s,i);if(o.common.async)return Promise.resolve(c);if(c instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return s};if(o.common.async===!1){let s=this._def.schema._parseSync({data:o.data,path:o.path,parent:o});return s.status==="aborted"?J:(s.status==="dirty"&&n.dirty(),a(s.value),{status:n.value,value:s.value})}else return this._def.schema._parseAsync({data:o.data,path:o.path,parent:o}).then(s=>s.status==="aborted"?J:(s.status==="dirty"&&n.dirty(),a(s.value).then(()=>({status:n.value,value:s.value}))))}if(r.type==="transform")if(o.common.async===!1){let a=this._def.schema._parseSync({data:o.data,path:o.path,parent:o});if(!Br(a))return J;let s=r.transform(a.value,i);if(s instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:n.value,value:s}}else return this._def.schema._parseAsync({data:o.data,path:o.path,parent:o}).then(a=>Br(a)?Promise.resolve(r.transform(a.value,i)).then(s=>({status:n.value,value:s})):J);ce.assertNever(r)}};It.create=(e,t,n)=>new It({schema:e,typeName:P.ZodEffects,effect:t,...Y(n)});It.createWithPreprocess=(e,t,n)=>new It({schema:t,effect:{type:"preprocess",transform:e},typeName:P.ZodEffects,...Y(n)});var zt=class extends ne{_parse(t){return this._getType(t)===U.undefined?Ge(void 0):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}};zt.create=(e,t)=>new zt({innerType:e,typeName:P.ZodOptional,...Y(t)});var er=class extends ne{_parse(t){return this._getType(t)===U.null?Ge(null):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}};er.create=(e,t)=>new er({innerType:e,typeName:P.ZodNullable,...Y(t)});var On=class extends ne{_parse(t){let{ctx:n}=this._processInputParams(t),o=n.data;return n.parsedType===U.undefined&&(o=this._def.defaultValue()),this._def.innerType._parse({data:o,path:n.path,parent:n})}removeDefault(){return this._def.innerType}};On.create=(e,t)=>new On({innerType:e,typeName:P.ZodDefault,defaultValue:typeof t.default=="function"?t.default:()=>t.default,...Y(t)});var Pn=class extends ne{_parse(t){let{ctx:n}=this._processInputParams(t),o={...n,common:{...n.common,issues:[]}},r=this._def.innerType._parse({data:o.data,path:o.path,parent:{...o}});return Lo(r)?r.then(i=>({status:"valid",value:i.status==="valid"?i.value:this._def.catchValue({get error(){return new ut(o.common.issues)},input:o.data})})):{status:"valid",value:r.status==="valid"?r.value:this._def.catchValue({get error(){return new ut(o.common.issues)},input:o.data})}}removeCatch(){return this._def.innerType}};Pn.create=(e,t)=>new Pn({innerType:e,typeName:P.ZodCatch,catchValue:typeof t.catch=="function"?t.catch:()=>t.catch,...Y(t)});var Xo=class extends ne{_parse(t){if(this._getType(t)!==U.nan){let o=this._getOrReturnCtx(t);return C(o,{code:T.invalid_type,expected:U.nan,received:o.parsedType}),J}return{status:"valid",value:t.data}}};Xo.create=e=>new Xo({typeName:P.ZodNaN,...Y(e)});var Ya=class extends ne{_parse(t){let{ctx:n}=this._processInputParams(t),o=n.data;return this._def.type._parse({data:o,path:n.path,parent:n})}unwrap(){return this._def.type}},Qa=class e extends ne{_parse(t){let{status:n,ctx:o}=this._processInputParams(t);if(o.common.async)return(async()=>{let i=await this._def.in._parseAsync({data:o.data,path:o.path,parent:o});return i.status==="aborted"?J:i.status==="dirty"?(n.dirty(),yn(i.value)):this._def.out._parseAsync({data:i.value,path:o.path,parent:o})})();{let r=this._def.in._parseSync({data:o.data,path:o.path,parent:o});return r.status==="aborted"?J:r.status==="dirty"?(n.dirty(),{status:"dirty",value:r.value}):this._def.out._parseSync({data:r.value,path:o.path,parent:o})}}static create(t,n){return new e({in:t,out:n,typeName:P.ZodPipeline})}},jn=class extends ne{_parse(t){let n=this._def.innerType._parse(t),o=r=>(Br(r)&&(r.value=Object.freeze(r.value)),r);return Lo(n)?n.then(r=>o(r)):o(n)}unwrap(){return this._def.innerType}};jn.create=(e,t)=>new jn({innerType:e,typeName:P.ZodReadonly,...Y(t)});var ED={object:lt.lazycreate},P;(function(e){e.ZodString="ZodString",e.ZodNumber="ZodNumber",e.ZodNaN="ZodNaN",e.ZodBigInt="ZodBigInt",e.ZodBoolean="ZodBoolean",e.ZodDate="ZodDate",e.ZodSymbol="ZodSymbol",e.ZodUndefined="ZodUndefined",e.ZodNull="ZodNull",e.ZodAny="ZodAny",e.ZodUnknown="ZodUnknown",e.ZodNever="ZodNever",e.ZodVoid="ZodVoid",e.ZodArray="ZodArray",e.ZodObject="ZodObject",e.ZodUnion="ZodUnion",e.ZodDiscriminatedUnion="ZodDiscriminatedUnion",e.ZodIntersection="ZodIntersection",e.ZodTuple="ZodTuple",e.ZodRecord="ZodRecord",e.ZodMap="ZodMap",e.ZodSet="ZodSet",e.ZodFunction="ZodFunction",e.ZodLazy="ZodLazy",e.ZodLiteral="ZodLiteral",e.ZodEnum="ZodEnum",e.ZodEffects="ZodEffects",e.ZodNativeEnum="ZodNativeEnum",e.ZodOptional="ZodOptional",e.ZodNullable="ZodNullable",e.ZodDefault="ZodDefault",e.ZodCatch="ZodCatch",e.ZodPromise="ZodPromise",e.ZodBranded="ZodBranded",e.ZodPipeline="ZodPipeline",e.ZodReadonly="ZodReadonly"})(P||(P={}));var TD=$n.create,OD=qo.create,PD=Xo.create,jD=Vo.create,ND=Fo.create,RD=Bo.create,AD=Ko.create,DD=xn.create,CD=wn.create,UD=Ho.create,ZD=mr.create,MD=Ct.create,LD=Jo.create,qD=hr.create,Xg=lt.create,VD=lt.strictCreate,FD=kn.create,BD=Ed.create,KD=Sn.create,HD=Qt.create,JD=Od.create,GD=Go.create,WD=Wo.create,XD=Pd.create,YD=zn.create,QD=In.create,eC=En.create,tC=Tn.create,rC=Kr.create,nC=It.create,oC=zt.create,iC=er.create,aC=It.createWithPreprocess,sC=Qa.create;var pt={};Fr(pt,{$ZodAny:()=>Ws,$ZodArray:()=>tc,$ZodAsyncError:()=>Et,$ZodBase64:()=>Ms,$ZodBase64URL:()=>Ls,$ZodBigInt:()=>di,$ZodBigIntFormat:()=>Ks,$ZodBoolean:()=>Vn,$ZodCIDRv4:()=>Us,$ZodCIDRv6:()=>Zs,$ZodCUID:()=>Is,$ZodCUID2:()=>Es,$ZodCatch:()=>_c,$ZodCheck:()=>$e,$ZodCheckBigIntFormat:()=>yf,$ZodCheckEndsWith:()=>Pf,$ZodCheckGreaterThan:()=>hs,$ZodCheckIncludes:()=>Tf,$ZodCheckLengthEquals:()=>Sf,$ZodCheckLessThan:()=>ms,$ZodCheckLowerCase:()=>If,$ZodCheckMaxLength:()=>wf,$ZodCheckMaxSize:()=>bf,$ZodCheckMimeType:()=>Nf,$ZodCheckMinLength:()=>kf,$ZodCheckMinSize:()=>$f,$ZodCheckMultipleOf:()=>vf,$ZodCheckNumberFormat:()=>_f,$ZodCheckOverwrite:()=>Rf,$ZodCheckProperty:()=>jf,$ZodCheckRegex:()=>zf,$ZodCheckSizeEquals:()=>xf,$ZodCheckStartsWith:()=>Of,$ZodCheckStringFormat:()=>qn,$ZodCheckUpperCase:()=>Ef,$ZodCodec:()=>Fn,$ZodCustom:()=>zc,$ZodCustomStringFormat:()=>Fs,$ZodDate:()=>ec,$ZodDefault:()=>mc,$ZodDiscriminatedUnion:()=>nc,$ZodE164:()=>qs,$ZodEmail:()=>ws,$ZodEmoji:()=>Ss,$ZodEncodeError:()=>gr,$ZodEnum:()=>cc,$ZodError:()=>ai,$ZodFile:()=>lc,$ZodFunction:()=>wc,$ZodGUID:()=>$s,$ZodIPv4:()=>Ds,$ZodIPv6:()=>Cs,$ZodISODate:()=>Ns,$ZodISODateTime:()=>js,$ZodISODuration:()=>As,$ZodISOTime:()=>Rs,$ZodIntersection:()=>oc,$ZodJWT:()=>Vs,$ZodKSUID:()=>Ps,$ZodLazy:()=>Sc,$ZodLiteral:()=>uc,$ZodMap:()=>ac,$ZodNaN:()=>yc,$ZodNanoID:()=>zs,$ZodNever:()=>Ys,$ZodNonOptional:()=>gc,$ZodNull:()=>Gs,$ZodNullable:()=>pc,$ZodNumber:()=>li,$ZodNumberFormat:()=>Bs,$ZodObject:()=>rc,$ZodObjectJIT:()=>Uf,$ZodOptional:()=>fc,$ZodPipe:()=>bc,$ZodPrefault:()=>hc,$ZodPromise:()=>kc,$ZodReadonly:()=>$c,$ZodRealError:()=>et,$ZodRecord:()=>ic,$ZodRegistry:()=>Kn,$ZodSet:()=>sc,$ZodString:()=>kr,$ZodStringFormat:()=>ge,$ZodSuccess:()=>vc,$ZodSymbol:()=>Hs,$ZodTemplateLiteral:()=>xc,$ZodTransform:()=>dc,$ZodTuple:()=>pi,$ZodType:()=>W,$ZodULID:()=>Ts,$ZodURL:()=>ks,$ZodUUID:()=>xs,$ZodUndefined:()=>Js,$ZodUnion:()=>fi,$ZodUnknown:()=>Xs,$ZodVoid:()=>Qs,$ZodXID:()=>Os,$brand:()=>Qo,$constructor:()=>$,$input:()=>Pc,$output:()=>Oc,Doc:()=>ui,JSONSchema:()=>k_,JSONSchemaGenerator:()=>Ci,NEVER:()=>es,TimePrecision:()=>Rc,_any:()=>tu,_array:()=>Zf,_base64:()=>Ni,_base64url:()=>Ri,_bigint:()=>Jc,_boolean:()=>Kc,_catch:()=>MI,_check:()=>w_,_cidrv4:()=>Pi,_cidrv6:()=>ji,_coercedBigint:()=>Gc,_coercedBoolean:()=>Hc,_coercedDate:()=>au,_coercedNumber:()=>Mc,_coercedString:()=>Nc,_cuid:()=>ki,_cuid2:()=>Si,_custom:()=>mu,_date:()=>iu,_decode:()=>as,_decodeAsync:()=>cs,_default:()=>CI,_discriminatedUnion:()=>SI,_e164:()=>Ai,_email:()=>vi,_emoji:()=>xi,_encode:()=>is,_encodeAsync:()=>ss,_endsWith:()=>to,_enum:()=>PI,_file:()=>pu,_float32:()=>qc,_float64:()=>Vc,_gt:()=>Mt,_gte:()=>Ve,_guid:()=>Hn,_includes:()=>Qn,_int:()=>Lc,_int32:()=>Fc,_int64:()=>Wc,_intersection:()=>zI,_ipv4:()=>Ti,_ipv6:()=>Oi,_isoDate:()=>Dc,_isoDateTime:()=>Ac,_isoDuration:()=>Uc,_isoTime:()=>Cc,_jwt:()=>Di,_ksuid:()=>Ei,_lazy:()=>FI,_length:()=>Qr,_literal:()=>NI,_lowercase:()=>Xn,_lt:()=>Zt,_lte:()=>rt,_map:()=>TI,_max:()=>rt,_maxLength:()=>Yr,_maxSize:()=>Xr,_mime:()=>ro,_min:()=>Ve,_minLength:()=>tr,_minSize:()=>zr,_multipleOf:()=>Sr,_nan:()=>su,_nanoid:()=>wi,_nativeEnum:()=>jI,_negative:()=>uu,_never:()=>nu,_nonnegative:()=>du,_nonoptional:()=>UI,_nonpositive:()=>lu,_normalize:()=>no,_null:()=>eu,_nullable:()=>DI,_number:()=>Zc,_optional:()=>AI,_overwrite:()=>Lt,_parse:()=>Un,_parseAsync:()=>Zn,_pipe:()=>LI,_positive:()=>cu,_promise:()=>BI,_property:()=>fu,_readonly:()=>qI,_record:()=>EI,_refine:()=>hu,_regex:()=>Wn,_safeDecode:()=>ls,_safeDecodeAsync:()=>fs,_safeEncode:()=>us,_safeEncodeAsync:()=>ds,_safeParse:()=>Mn,_safeParseAsync:()=>Ln,_set:()=>OI,_size:()=>Gn,_startsWith:()=>eo,_string:()=>jc,_stringFormat:()=>en,_stringbool:()=>vu,_success:()=>ZI,_superRefine:()=>gu,_symbol:()=>Yc,_templateLiteral:()=>VI,_toLowerCase:()=>io,_toUpperCase:()=>ao,_transform:()=>RI,_trim:()=>oo,_tuple:()=>II,_uint32:()=>Bc,_uint64:()=>Xc,_ulid:()=>zi,_undefined:()=>Qc,_union:()=>kI,_unknown:()=>ru,_uppercase:()=>Yn,_url:()=>Jn,_uuid:()=>_i,_uuidv4:()=>yi,_uuidv6:()=>bi,_uuidv7:()=>$i,_void:()=>ou,_xid:()=>Ii,clone:()=>Ne,config:()=>Ee,decode:()=>ov,decodeAsync:()=>av,encode:()=>nv,encodeAsync:()=>iv,flattenError:()=>Dn,formatError:()=>Cn,globalConfig:()=>Yo,globalRegistry:()=>Tt,isValidBase64:()=>Cf,isValidBase64URL:()=>Iv,isValidJWT:()=>Ev,locales:()=>Bn,parse:()=>Jr,parseAsync:()=>Gr,prettifyError:()=>os,regexes:()=>tt,registry:()=>gi,safeDecode:()=>cv,safeDecodeAsync:()=>lv,safeEncode:()=>sv,safeEncodeAsync:()=>uv,safeParse:()=>xr,safeParseAsync:()=>wr,toDotPath:()=>rv,toJSONSchema:()=>so,treeifyError:()=>ns,util:()=>E,version:()=>Af});var es=Object.freeze({status:"aborted"});function $(e,t,n){function o(s,c){var l;Object.defineProperty(s,"_zod",{value:s._zod??{},enumerable:!1}),(l=s._zod).traits??(l.traits=new Set),s._zod.traits.add(e),t(s,c);for(let d in a.prototype)d in s||Object.defineProperty(s,d,{value:a.prototype[d].bind(s)});s._zod.constr=a,s._zod.def=c}let r=n?.Parent??Object;class i extends r{}Object.defineProperty(i,"name",{value:e});function a(s){var c;let l=n?.Parent?new i:this;o(l,s),(c=l._zod).deferred??(c.deferred=[]);for(let d of l._zod.deferred)d();return l}return Object.defineProperty(a,"init",{value:o}),Object.defineProperty(a,Symbol.hasInstance,{value:s=>n?.Parent&&s instanceof n.Parent?!0:s?._zod?.traits?.has(e)}),Object.defineProperty(a,"name",{value:e}),a}var Qo=Symbol("zod_brand"),Et=class extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}},gr=class extends Error{constructor(t){super(`Encountered unidirectional transform during encode: ${t}`),this.name="ZodEncodeError"}},Yo={};function Ee(e){return e&&Object.assign(Yo,e),Yo}var E={};Fr(E,{BIGINT_FORMAT_RANGES:()=>Md,Class:()=>Nd,NUMBER_FORMAT_RANGES:()=>Zd,aborted:()=>$r,allowsEval:()=>Ad,assert:()=>N0,assertEqual:()=>T0,assertIs:()=>P0,assertNever:()=>j0,assertNotEqual:()=>O0,assignProp:()=>_r,base64ToUint8Array:()=>Qg,base64urlToUint8Array:()=>W0,cached:()=>Rn,captureStackTrace:()=>rs,cleanEnum:()=>G0,cleanRegex:()=>ri,clone:()=>Ne,cloneDef:()=>A0,createTransparentProxy:()=>L0,defineLazy:()=>se,esc:()=>ts,escapeRegex:()=>Ut,extend:()=>F0,finalizeIssue:()=>ft,floatSafeRemainder:()=>Rd,getElementAtPath:()=>D0,getEnumValues:()=>ti,getLengthableOrigin:()=>ii,getParsedType:()=>M0,getSizableOrigin:()=>oi,hexToUint8Array:()=>Y0,isObject:()=>Hr,isPlainObject:()=>br,issue:()=>An,joinValues:()=>S,jsonStringifyReplacer:()=>Nn,merge:()=>K0,mergeDefs:()=>yr,normalizeParams:()=>N,nullish:()=>vr,numKeys:()=>Z0,objectClone:()=>R0,omit:()=>V0,optionalKeys:()=>Ud,partial:()=>H0,pick:()=>q0,prefixIssues:()=>dt,primitiveTypes:()=>Cd,promiseAllObject:()=>C0,propertyKeyTypes:()=>ni,randomString:()=>U0,required:()=>J0,safeExtend:()=>B0,shallowClone:()=>Dd,stringifyPrimitive:()=>j,uint8ArrayToBase64:()=>ev,uint8ArrayToBase64url:()=>X0,uint8ArrayToHex:()=>Q0,unwrapMessage:()=>ei});function T0(e){return e}function O0(e){return e}function P0(e){}function j0(e){throw new Error}function N0(e){}function ti(e){let t=Object.values(e).filter(o=>typeof o=="number");return Object.entries(e).filter(([o,r])=>t.indexOf(+o)===-1).map(([o,r])=>r)}function S(e,t="|"){return e.map(n=>j(n)).join(t)}function Nn(e,t){return typeof t=="bigint"?t.toString():t}function Rn(e){return{get value(){{let n=e();return Object.defineProperty(this,"value",{value:n}),n}throw new Error("cached value already set")}}}function vr(e){return e==null}function ri(e){let t=e.startsWith("^")?1:0,n=e.endsWith("$")?e.length-1:e.length;return e.slice(t,n)}function Rd(e,t){let n=(e.toString().split(".")[1]||"").length,o=t.toString(),r=(o.split(".")[1]||"").length;if(r===0&&/\d?e-\d?/.test(o)){let c=o.match(/\d?e-(\d?)/);c?.[1]&&(r=Number.parseInt(c[1]))}let i=n>r?n:r,a=Number.parseInt(e.toFixed(i).replace(".","")),s=Number.parseInt(t.toFixed(i).replace(".",""));return a%s/10**i}var Yg=Symbol("evaluating");function se(e,t,n){let o;Object.defineProperty(e,t,{get(){if(o!==Yg)return o===void 0&&(o=Yg,o=n()),o},set(r){Object.defineProperty(e,t,{value:r})},configurable:!0})}function R0(e){return Object.create(Object.getPrototypeOf(e),Object.getOwnPropertyDescriptors(e))}function _r(e,t,n){Object.defineProperty(e,t,{value:n,writable:!0,enumerable:!0,configurable:!0})}function yr(...e){let t={};for(let n of e){let o=Object.getOwnPropertyDescriptors(n);Object.assign(t,o)}return Object.defineProperties({},t)}function A0(e){return yr(e._zod.def)}function D0(e,t){return t?t.reduce((n,o)=>n?.[o],e):e}function C0(e){let t=Object.keys(e),n=t.map(o=>e[o]);return Promise.all(n).then(o=>{let r={};for(let i=0;i<t.length;i++)r[t[i]]=o[i];return r})}function U0(e=10){let t="abcdefghijklmnopqrstuvwxyz",n="";for(let o=0;o<e;o++)n+=t[Math.floor(Math.random()*t.length)];return n}function ts(e){return JSON.stringify(e)}var rs="captureStackTrace"in Error?Error.captureStackTrace:(...e)=>{};function Hr(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}var Ad=Rn(()=>{if(typeof navigator<"u"&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{let e=Function;return new e(""),!0}catch{return!1}});function br(e){if(Hr(e)===!1)return!1;let t=e.constructor;if(t===void 0)return!0;let n=t.prototype;return!(Hr(n)===!1||Object.prototype.hasOwnProperty.call(n,"isPrototypeOf")===!1)}function Dd(e){return br(e)?{...e}:Array.isArray(e)?[...e]:e}function Z0(e){let t=0;for(let n in e)Object.prototype.hasOwnProperty.call(e,n)&&t++;return t}var M0=e=>{let t=typeof e;switch(t){case"undefined":return"undefined";case"string":return"string";case"number":return Number.isNaN(e)?"nan":"number";case"boolean":return"boolean";case"function":return"function";case"bigint":return"bigint";case"symbol":return"symbol";case"object":return Array.isArray(e)?"array":e===null?"null":e.then&&typeof e.then=="function"&&e.catch&&typeof e.catch=="function"?"promise":typeof Map<"u"&&e instanceof Map?"map":typeof Set<"u"&&e instanceof Set?"set":typeof Date<"u"&&e instanceof Date?"date":typeof File<"u"&&e instanceof File?"file":"object";default:throw new Error(`Unknown data type: ${t}`)}},ni=new Set(["string","number","symbol"]),Cd=new Set(["string","number","bigint","boolean","symbol","undefined"]);function Ut(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function Ne(e,t,n){let o=new e._zod.constr(t??e._zod.def);return(!t||n?.parent)&&(o._zod.parent=e),o}function N(e){let t=e;if(!t)return{};if(typeof t=="string")return{error:()=>t};if(t?.message!==void 0){if(t?.error!==void 0)throw new Error("Cannot specify both `message` and `error` params");t.error=t.message}return delete t.message,typeof t.error=="string"?{...t,error:()=>t.error}:t}function L0(e){let t;return new Proxy({},{get(n,o,r){return t??(t=e()),Reflect.get(t,o,r)},set(n,o,r,i){return t??(t=e()),Reflect.set(t,o,r,i)},has(n,o){return t??(t=e()),Reflect.has(t,o)},deleteProperty(n,o){return t??(t=e()),Reflect.deleteProperty(t,o)},ownKeys(n){return t??(t=e()),Reflect.ownKeys(t)},getOwnPropertyDescriptor(n,o){return t??(t=e()),Reflect.getOwnPropertyDescriptor(t,o)},defineProperty(n,o,r){return t??(t=e()),Reflect.defineProperty(t,o,r)}})}function j(e){return typeof e=="bigint"?e.toString()+"n":typeof e=="string"?`"${e}"`:`${e}`}function Ud(e){return Object.keys(e).filter(t=>e[t]._zod.optin==="optional"&&e[t]._zod.optout==="optional")}var Zd={safeint:[Number.MIN_SAFE_INTEGER,Number.MAX_SAFE_INTEGER],int32:[-2147483648,2147483647],uint32:[0,4294967295],float32:[-34028234663852886e22,34028234663852886e22],float64:[-Number.MAX_VALUE,Number.MAX_VALUE]},Md={int64:[BigInt("-9223372036854775808"),BigInt("9223372036854775807")],uint64:[BigInt(0),BigInt("18446744073709551615")]};function q0(e,t){let n=e._zod.def,o=yr(e._zod.def,{get shape(){let r={};for(let i in t){if(!(i in n.shape))throw new Error(`Unrecognized key: "${i}"`);t[i]&&(r[i]=n.shape[i])}return _r(this,"shape",r),r},checks:[]});return Ne(e,o)}function V0(e,t){let n=e._zod.def,o=yr(e._zod.def,{get shape(){let r={...e._zod.def.shape};for(let i in t){if(!(i in n.shape))throw new Error(`Unrecognized key: "${i}"`);t[i]&&delete r[i]}return _r(this,"shape",r),r},checks:[]});return Ne(e,o)}function F0(e,t){if(!br(t))throw new Error("Invalid input to extend: expected a plain object");let n=e._zod.def.checks;if(n&&n.length>0)throw new Error("Object schemas containing refinements cannot be extended. Use `.safeExtend()` instead.");let r=yr(e._zod.def,{get shape(){let i={...e._zod.def.shape,...t};return _r(this,"shape",i),i},checks:[]});return Ne(e,r)}function B0(e,t){if(!br(t))throw new Error("Invalid input to safeExtend: expected a plain object");let n={...e._zod.def,get shape(){let o={...e._zod.def.shape,...t};return _r(this,"shape",o),o},checks:e._zod.def.checks};return Ne(e,n)}function K0(e,t){let n=yr(e._zod.def,{get shape(){let o={...e._zod.def.shape,...t._zod.def.shape};return _r(this,"shape",o),o},get catchall(){return t._zod.def.catchall},checks:[]});return Ne(e,n)}function H0(e,t,n){let o=yr(t._zod.def,{get shape(){let r=t._zod.def.shape,i={...r};if(n)for(let a in n){if(!(a in r))throw new Error(`Unrecognized key: "${a}"`);n[a]&&(i[a]=e?new e({type:"optional",innerType:r[a]}):r[a])}else for(let a in r)i[a]=e?new e({type:"optional",innerType:r[a]}):r[a];return _r(this,"shape",i),i},checks:[]});return Ne(t,o)}function J0(e,t,n){let o=yr(t._zod.def,{get shape(){let r=t._zod.def.shape,i={...r};if(n)for(let a in n){if(!(a in i))throw new Error(`Unrecognized key: "${a}"`);n[a]&&(i[a]=new e({type:"nonoptional",innerType:r[a]}))}else for(let a in r)i[a]=new e({type:"nonoptional",innerType:r[a]});return _r(this,"shape",i),i},checks:[]});return Ne(t,o)}function $r(e,t=0){if(e.aborted===!0)return!0;for(let n=t;n<e.issues.length;n++)if(e.issues[n]?.continue!==!0)return!0;return!1}function dt(e,t){return t.map(n=>{var o;return(o=n).path??(o.path=[]),n.path.unshift(e),n})}function ei(e){return typeof e=="string"?e:e?.message}function ft(e,t,n){let o={...e,path:e.path??[]};if(!e.message){let r=ei(e.inst?._zod.def?.error?.(e))??ei(t?.error?.(e))??ei(n.customError?.(e))??ei(n.localeError?.(e))??"Invalid input";o.message=r}return delete o.inst,delete o.continue,t?.reportInput||delete o.input,o}function oi(e){return e instanceof Set?"set":e instanceof Map?"map":e instanceof File?"file":"unknown"}function ii(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}function An(...e){let[t,n,o]=e;return typeof t=="string"?{message:t,code:"custom",input:n,inst:o}:{...t}}function G0(e){return Object.entries(e).filter(([t,n])=>Number.isNaN(Number.parseInt(t,10))).map(t=>t[1])}function Qg(e){let t=atob(e),n=new Uint8Array(t.length);for(let o=0;o<t.length;o++)n[o]=t.charCodeAt(o);return n}function ev(e){let t="";for(let n=0;n<e.length;n++)t+=String.fromCharCode(e[n]);return btoa(t)}function W0(e){let t=e.replace(/-/g,"+").replace(/_/g,"/"),n="=".repeat((4-t.length%4)%4);return Qg(t+n)}function X0(e){return ev(e).replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")}function Y0(e){let t=e.replace(/^0x/,"");if(t.length%2!==0)throw new Error("Invalid hex string length");let n=new Uint8Array(t.length/2);for(let o=0;o<t.length;o+=2)n[o/2]=Number.parseInt(t.slice(o,o+2),16);return n}function Q0(e){return Array.from(e).map(t=>t.toString(16).padStart(2,"0")).join("")}var Nd=class{constructor(...t){}};var tv=(e,t)=>{e.name="$ZodError",Object.defineProperty(e,"_zod",{value:e._zod,enumerable:!1}),Object.defineProperty(e,"issues",{value:t,enumerable:!1}),e.message=JSON.stringify(t,Nn,2),Object.defineProperty(e,"toString",{value:()=>e.message,enumerable:!1})},ai=$("$ZodError",tv),et=$("$ZodError",tv,{Parent:Error});function Dn(e,t=n=>n.message){let n={},o=[];for(let r of e.issues)r.path.length>0?(n[r.path[0]]=n[r.path[0]]||[],n[r.path[0]].push(t(r))):o.push(t(r));return{formErrors:o,fieldErrors:n}}function Cn(e,t){let n=t||function(i){return i.message},o={_errors:[]},r=i=>{for(let a of i.issues)if(a.code==="invalid_union"&&a.errors.length)a.errors.map(s=>r({issues:s}));else if(a.code==="invalid_key")r({issues:a.issues});else if(a.code==="invalid_element")r({issues:a.issues});else if(a.path.length===0)o._errors.push(n(a));else{let s=o,c=0;for(;c<a.path.length;){let l=a.path[c];c===a.path.length-1?(s[l]=s[l]||{_errors:[]},s[l]._errors.push(n(a))):s[l]=s[l]||{_errors:[]},s=s[l],c++}}};return r(e),o}function ns(e,t){let n=t||function(i){return i.message},o={errors:[]},r=(i,a=[])=>{var s,c;for(let l of i.issues)if(l.code==="invalid_union"&&l.errors.length)l.errors.map(d=>r({issues:d},l.path));else if(l.code==="invalid_key")r({issues:l.issues},l.path);else if(l.code==="invalid_element")r({issues:l.issues},l.path);else{let d=[...a,...l.path];if(d.length===0){o.errors.push(n(l));continue}let f=o,_=0;for(;_<d.length;){let v=d[_],g=_===d.length-1;typeof v=="string"?(f.properties??(f.properties={}),(s=f.properties)[v]??(s[v]={errors:[]}),f=f.properties[v]):(f.items??(f.items=[]),(c=f.items)[v]??(c[v]={errors:[]}),f=f.items[v]),g&&f.errors.push(n(l)),_++}}};return r(e),o}function rv(e){let t=[],n=e.map(o=>typeof o=="object"?o.key:o);for(let o of n)typeof o=="number"?t.push(`[${o}]`):typeof o=="symbol"?t.push(`[${JSON.stringify(String(o))}]`):/[^\w$]/.test(o)?t.push(`[${JSON.stringify(o)}]`):(t.length&&t.push("."),t.push(o));return t.join("")}function os(e){let t=[],n=[...e.issues].sort((o,r)=>(o.path??[]).length-(r.path??[]).length);for(let o of n)t.push(`\u2716 ${o.message}`),o.path?.length&&t.push(` \u2192 at ${rv(o.path)}`);return t.join(`
|
|
35
|
+
`)}var Un=e=>(t,n,o,r)=>{let i=o?Object.assign(o,{async:!1}):{async:!1},a=t._zod.run({value:n,issues:[]},i);if(a instanceof Promise)throw new Et;if(a.issues.length){let s=new(r?.Err??e)(a.issues.map(c=>ft(c,i,Ee())));throw rs(s,r?.callee),s}return a.value},Jr=Un(et),Zn=e=>async(t,n,o,r)=>{let i=o?Object.assign(o,{async:!0}):{async:!0},a=t._zod.run({value:n,issues:[]},i);if(a instanceof Promise&&(a=await a),a.issues.length){let s=new(r?.Err??e)(a.issues.map(c=>ft(c,i,Ee())));throw rs(s,r?.callee),s}return a.value},Gr=Zn(et),Mn=e=>(t,n,o)=>{let r=o?{...o,async:!1}:{async:!1},i=t._zod.run({value:n,issues:[]},r);if(i instanceof Promise)throw new Et;return i.issues.length?{success:!1,error:new(e??ai)(i.issues.map(a=>ft(a,r,Ee())))}:{success:!0,data:i.value}},xr=Mn(et),Ln=e=>async(t,n,o)=>{let r=o?Object.assign(o,{async:!0}):{async:!0},i=t._zod.run({value:n,issues:[]},r);return i instanceof Promise&&(i=await i),i.issues.length?{success:!1,error:new e(i.issues.map(a=>ft(a,r,Ee())))}:{success:!0,data:i.value}},wr=Ln(et),is=e=>(t,n,o)=>{let r=o?Object.assign(o,{direction:"backward"}):{direction:"backward"};return Un(e)(t,n,r)},nv=is(et),as=e=>(t,n,o)=>Un(e)(t,n,o),ov=as(et),ss=e=>async(t,n,o)=>{let r=o?Object.assign(o,{direction:"backward"}):{direction:"backward"};return Zn(e)(t,n,r)},iv=ss(et),cs=e=>async(t,n,o)=>Zn(e)(t,n,o),av=cs(et),us=e=>(t,n,o)=>{let r=o?Object.assign(o,{direction:"backward"}):{direction:"backward"};return Mn(e)(t,n,r)},sv=us(et),ls=e=>(t,n,o)=>Mn(e)(t,n,o),cv=ls(et),ds=e=>async(t,n,o)=>{let r=o?Object.assign(o,{direction:"backward"}):{direction:"backward"};return Ln(e)(t,n,r)},uv=ds(et),fs=e=>async(t,n,o)=>Ln(e)(t,n,o),lv=fs(et);var tt={};Fr(tt,{base64:()=>tf,base64url:()=>ps,bigint:()=>uf,boolean:()=>ff,browserEmail:()=>cz,cidrv4:()=>Qd,cidrv6:()=>ef,cuid:()=>Ld,cuid2:()=>qd,date:()=>of,datetime:()=>sf,domain:()=>lz,duration:()=>Hd,e164:()=>nf,email:()=>Gd,emoji:()=>Wd,extendedDuration:()=>tz,guid:()=>Jd,hex:()=>dz,hostname:()=>rf,html5Email:()=>iz,idnEmail:()=>sz,integer:()=>lf,ipv4:()=>Xd,ipv6:()=>Yd,ksuid:()=>Bd,lowercase:()=>hf,md5_base64:()=>pz,md5_base64url:()=>mz,md5_hex:()=>fz,nanoid:()=>Kd,null:()=>pf,number:()=>df,rfc5322Email:()=>az,sha1_base64:()=>gz,sha1_base64url:()=>vz,sha1_hex:()=>hz,sha256_base64:()=>yz,sha256_base64url:()=>bz,sha256_hex:()=>_z,sha384_base64:()=>xz,sha384_base64url:()=>wz,sha384_hex:()=>$z,sha512_base64:()=>Sz,sha512_base64url:()=>zz,sha512_hex:()=>kz,string:()=>cf,time:()=>af,ulid:()=>Vd,undefined:()=>mf,unicodeEmail:()=>dv,uppercase:()=>gf,uuid:()=>Wr,uuid4:()=>rz,uuid6:()=>nz,uuid7:()=>oz,xid:()=>Fd});var Ld=/^[cC][^\s-]{8,}$/,qd=/^[0-9a-z]+$/,Vd=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,Fd=/^[0-9a-vA-V]{20}$/,Bd=/^[A-Za-z0-9]{27}$/,Kd=/^[a-zA-Z0-9_-]{21}$/,Hd=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,tz=/^[-+]?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)?)??$/,Jd=/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/,Wr=e=>e?new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`):/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/,rz=Wr(4),nz=Wr(6),oz=Wr(7),Gd=/^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,iz=/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,az=/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/,dv=/^[^\s@"]{1,64}@[^\s@]{1,255}$/u,sz=dv,cz=/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,uz="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";function Wd(){return new RegExp(uz,"u")}var Xd=/^(?:(?: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])$/,Yd=/^(([0-9a-fA-F]{1,4}:){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}|:))$/,Qd=/^((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])\/([0-9]|[1-2][0-9]|3[0-2])$/,ef=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,tf=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,ps=/^[A-Za-z0-9_-]*$/,rf=/^(?=.{1,253}\.?$)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[-0-9a-zA-Z]{0,61}[0-9a-zA-Z])?)*\.?$/,lz=/^([a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,}$/,nf=/^\+(?:[0-9]){6,14}[0-9]$/,fv="(?:(?:\\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])))",of=new RegExp(`^${fv}$`);function pv(e){let t="(?:[01]\\d|2[0-3]):[0-5]\\d";return typeof e.precision=="number"?e.precision===-1?`${t}`:e.precision===0?`${t}:[0-5]\\d`:`${t}:[0-5]\\d\\.\\d{${e.precision}}`:`${t}(?::[0-5]\\d(?:\\.\\d+)?)?`}function af(e){return new RegExp(`^${pv(e)}$`)}function sf(e){let t=pv({precision:e.precision}),n=["Z"];e.local&&n.push(""),e.offset&&n.push("([+-](?:[01]\\d|2[0-3]):[0-5]\\d)");let o=`${t}(?:${n.join("|")})`;return new RegExp(`^${fv}T(?:${o})$`)}var cf=e=>{let t=e?`[\\s\\S]{${e?.minimum??0},${e?.maximum??""}}`:"[\\s\\S]*";return new RegExp(`^${t}$`)},uf=/^-?\d+n?$/,lf=/^-?\d+$/,df=/^-?\d+(?:\.\d+)?/,ff=/^(?:true|false)$/i,pf=/^null$/i;var mf=/^undefined$/i;var hf=/^[^A-Z]*$/,gf=/^[^a-z]*$/,dz=/^[0-9a-fA-F]*$/;function si(e,t){return new RegExp(`^[A-Za-z0-9+/]{${e}}${t}$`)}function ci(e){return new RegExp(`^[A-Za-z0-9_-]{${e}}$`)}var fz=/^[0-9a-fA-F]{32}$/,pz=si(22,"=="),mz=ci(22),hz=/^[0-9a-fA-F]{40}$/,gz=si(27,"="),vz=ci(27),_z=/^[0-9a-fA-F]{64}$/,yz=si(43,"="),bz=ci(43),$z=/^[0-9a-fA-F]{96}$/,xz=si(64,""),wz=ci(64),kz=/^[0-9a-fA-F]{128}$/,Sz=si(86,"=="),zz=ci(86);var $e=$("$ZodCheck",(e,t)=>{var n;e._zod??(e._zod={}),e._zod.def=t,(n=e._zod).onattach??(n.onattach=[])}),hv={number:"number",bigint:"bigint",object:"date"},ms=$("$ZodCheckLessThan",(e,t)=>{$e.init(e,t);let n=hv[typeof t.value];e._zod.onattach.push(o=>{let r=o._zod.bag,i=(t.inclusive?r.maximum:r.exclusiveMaximum)??Number.POSITIVE_INFINITY;t.value<i&&(t.inclusive?r.maximum=t.value:r.exclusiveMaximum=t.value)}),e._zod.check=o=>{(t.inclusive?o.value<=t.value:o.value<t.value)||o.issues.push({origin:n,code:"too_big",maximum:t.value,input:o.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),hs=$("$ZodCheckGreaterThan",(e,t)=>{$e.init(e,t);let n=hv[typeof t.value];e._zod.onattach.push(o=>{let r=o._zod.bag,i=(t.inclusive?r.minimum:r.exclusiveMinimum)??Number.NEGATIVE_INFINITY;t.value>i&&(t.inclusive?r.minimum=t.value:r.exclusiveMinimum=t.value)}),e._zod.check=o=>{(t.inclusive?o.value>=t.value:o.value>t.value)||o.issues.push({origin:n,code:"too_small",minimum:t.value,input:o.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),vf=$("$ZodCheckMultipleOf",(e,t)=>{$e.init(e,t),e._zod.onattach.push(n=>{var o;(o=n._zod.bag).multipleOf??(o.multipleOf=t.value)}),e._zod.check=n=>{if(typeof n.value!=typeof t.value)throw new Error("Cannot mix number and bigint in multiple_of check.");(typeof n.value=="bigint"?n.value%t.value===BigInt(0):Rd(n.value,t.value)===0)||n.issues.push({origin:typeof n.value,code:"not_multiple_of",divisor:t.value,input:n.value,inst:e,continue:!t.abort})}}),_f=$("$ZodCheckNumberFormat",(e,t)=>{$e.init(e,t),t.format=t.format||"float64";let n=t.format?.includes("int"),o=n?"int":"number",[r,i]=Zd[t.format];e._zod.onattach.push(a=>{let s=a._zod.bag;s.format=t.format,s.minimum=r,s.maximum=i,n&&(s.pattern=lf)}),e._zod.check=a=>{let s=a.value;if(n){if(!Number.isInteger(s)){a.issues.push({expected:o,format:t.format,code:"invalid_type",continue:!1,input:s,inst:e});return}if(!Number.isSafeInteger(s)){s>0?a.issues.push({input:s,code:"too_big",maximum:Number.MAX_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:o,continue:!t.abort}):a.issues.push({input:s,code:"too_small",minimum:Number.MIN_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:o,continue:!t.abort});return}}s<r&&a.issues.push({origin:"number",input:s,code:"too_small",minimum:r,inclusive:!0,inst:e,continue:!t.abort}),s>i&&a.issues.push({origin:"number",input:s,code:"too_big",maximum:i,inst:e})}}),yf=$("$ZodCheckBigIntFormat",(e,t)=>{$e.init(e,t);let[n,o]=Md[t.format];e._zod.onattach.push(r=>{let i=r._zod.bag;i.format=t.format,i.minimum=n,i.maximum=o}),e._zod.check=r=>{let i=r.value;i<n&&r.issues.push({origin:"bigint",input:i,code:"too_small",minimum:n,inclusive:!0,inst:e,continue:!t.abort}),i>o&&r.issues.push({origin:"bigint",input:i,code:"too_big",maximum:o,inst:e})}}),bf=$("$ZodCheckMaxSize",(e,t)=>{var n;$e.init(e,t),(n=e._zod.def).when??(n.when=o=>{let r=o.value;return!vr(r)&&r.size!==void 0}),e._zod.onattach.push(o=>{let r=o._zod.bag.maximum??Number.POSITIVE_INFINITY;t.maximum<r&&(o._zod.bag.maximum=t.maximum)}),e._zod.check=o=>{let r=o.value;r.size<=t.maximum||o.issues.push({origin:oi(r),code:"too_big",maximum:t.maximum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),$f=$("$ZodCheckMinSize",(e,t)=>{var n;$e.init(e,t),(n=e._zod.def).when??(n.when=o=>{let r=o.value;return!vr(r)&&r.size!==void 0}),e._zod.onattach.push(o=>{let r=o._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>r&&(o._zod.bag.minimum=t.minimum)}),e._zod.check=o=>{let r=o.value;r.size>=t.minimum||o.issues.push({origin:oi(r),code:"too_small",minimum:t.minimum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),xf=$("$ZodCheckSizeEquals",(e,t)=>{var n;$e.init(e,t),(n=e._zod.def).when??(n.when=o=>{let r=o.value;return!vr(r)&&r.size!==void 0}),e._zod.onattach.push(o=>{let r=o._zod.bag;r.minimum=t.size,r.maximum=t.size,r.size=t.size}),e._zod.check=o=>{let r=o.value,i=r.size;if(i===t.size)return;let a=i>t.size;o.issues.push({origin:oi(r),...a?{code:"too_big",maximum:t.size}:{code:"too_small",minimum:t.size},inclusive:!0,exact:!0,input:o.value,inst:e,continue:!t.abort})}}),wf=$("$ZodCheckMaxLength",(e,t)=>{var n;$e.init(e,t),(n=e._zod.def).when??(n.when=o=>{let r=o.value;return!vr(r)&&r.length!==void 0}),e._zod.onattach.push(o=>{let r=o._zod.bag.maximum??Number.POSITIVE_INFINITY;t.maximum<r&&(o._zod.bag.maximum=t.maximum)}),e._zod.check=o=>{let r=o.value;if(r.length<=t.maximum)return;let a=ii(r);o.issues.push({origin:a,code:"too_big",maximum:t.maximum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),kf=$("$ZodCheckMinLength",(e,t)=>{var n;$e.init(e,t),(n=e._zod.def).when??(n.when=o=>{let r=o.value;return!vr(r)&&r.length!==void 0}),e._zod.onattach.push(o=>{let r=o._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>r&&(o._zod.bag.minimum=t.minimum)}),e._zod.check=o=>{let r=o.value;if(r.length>=t.minimum)return;let a=ii(r);o.issues.push({origin:a,code:"too_small",minimum:t.minimum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),Sf=$("$ZodCheckLengthEquals",(e,t)=>{var n;$e.init(e,t),(n=e._zod.def).when??(n.when=o=>{let r=o.value;return!vr(r)&&r.length!==void 0}),e._zod.onattach.push(o=>{let r=o._zod.bag;r.minimum=t.length,r.maximum=t.length,r.length=t.length}),e._zod.check=o=>{let r=o.value,i=r.length;if(i===t.length)return;let a=ii(r),s=i>t.length;o.issues.push({origin:a,...s?{code:"too_big",maximum:t.length}:{code:"too_small",minimum:t.length},inclusive:!0,exact:!0,input:o.value,inst:e,continue:!t.abort})}}),qn=$("$ZodCheckStringFormat",(e,t)=>{var n,o;$e.init(e,t),e._zod.onattach.push(r=>{let i=r._zod.bag;i.format=t.format,t.pattern&&(i.patterns??(i.patterns=new Set),i.patterns.add(t.pattern))}),t.pattern?(n=e._zod).check??(n.check=r=>{t.pattern.lastIndex=0,!t.pattern.test(r.value)&&r.issues.push({origin:"string",code:"invalid_format",format:t.format,input:r.value,...t.pattern?{pattern:t.pattern.toString()}:{},inst:e,continue:!t.abort})}):(o=e._zod).check??(o.check=()=>{})}),zf=$("$ZodCheckRegex",(e,t)=>{qn.init(e,t),e._zod.check=n=>{t.pattern.lastIndex=0,!t.pattern.test(n.value)&&n.issues.push({origin:"string",code:"invalid_format",format:"regex",input:n.value,pattern:t.pattern.toString(),inst:e,continue:!t.abort})}}),If=$("$ZodCheckLowerCase",(e,t)=>{t.pattern??(t.pattern=hf),qn.init(e,t)}),Ef=$("$ZodCheckUpperCase",(e,t)=>{t.pattern??(t.pattern=gf),qn.init(e,t)}),Tf=$("$ZodCheckIncludes",(e,t)=>{$e.init(e,t);let n=Ut(t.includes),o=new RegExp(typeof t.position=="number"?`^.{${t.position}}${n}`:n);t.pattern=o,e._zod.onattach.push(r=>{let i=r._zod.bag;i.patterns??(i.patterns=new Set),i.patterns.add(o)}),e._zod.check=r=>{r.value.includes(t.includes,t.position)||r.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:t.includes,input:r.value,inst:e,continue:!t.abort})}}),Of=$("$ZodCheckStartsWith",(e,t)=>{$e.init(e,t);let n=new RegExp(`^${Ut(t.prefix)}.*`);t.pattern??(t.pattern=n),e._zod.onattach.push(o=>{let r=o._zod.bag;r.patterns??(r.patterns=new Set),r.patterns.add(n)}),e._zod.check=o=>{o.value.startsWith(t.prefix)||o.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:t.prefix,input:o.value,inst:e,continue:!t.abort})}}),Pf=$("$ZodCheckEndsWith",(e,t)=>{$e.init(e,t);let n=new RegExp(`.*${Ut(t.suffix)}$`);t.pattern??(t.pattern=n),e._zod.onattach.push(o=>{let r=o._zod.bag;r.patterns??(r.patterns=new Set),r.patterns.add(n)}),e._zod.check=o=>{o.value.endsWith(t.suffix)||o.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:t.suffix,input:o.value,inst:e,continue:!t.abort})}});function mv(e,t,n){e.issues.length&&t.issues.push(...dt(n,e.issues))}var jf=$("$ZodCheckProperty",(e,t)=>{$e.init(e,t),e._zod.check=n=>{let o=t.schema._zod.run({value:n.value[t.property],issues:[]},{});if(o instanceof Promise)return o.then(r=>mv(r,n,t.property));mv(o,n,t.property)}}),Nf=$("$ZodCheckMimeType",(e,t)=>{$e.init(e,t);let n=new Set(t.mime);e._zod.onattach.push(o=>{o._zod.bag.mime=t.mime}),e._zod.check=o=>{n.has(o.value.type)||o.issues.push({code:"invalid_value",values:t.mime,input:o.value.type,inst:e,continue:!t.abort})}}),Rf=$("$ZodCheckOverwrite",(e,t)=>{$e.init(e,t),e._zod.check=n=>{n.value=t.tx(n.value)}});var ui=class{constructor(t=[]){this.content=[],this.indent=0,this&&(this.args=t)}indented(t){this.indent+=1,t(this),this.indent-=1}write(t){if(typeof t=="function"){t(this,{execution:"sync"}),t(this,{execution:"async"});return}let o=t.split(`
|
|
36
36
|
`).filter(a=>a),r=Math.min(...o.map(a=>a.length-a.trimStart().length)),i=o.map(a=>a.slice(r)).map(a=>" ".repeat(this.indent*2)+a);for(let a of i)this.content.push(a)}compile(){let t=Function,n=this?.args,r=[...(this?.content??[""]).map(i=>` ${i}`)];return new t(...n,r.join(`
|
|
37
|
-
`))}};var Nf={major:4,minor:1,patch:9};var W=$("$ZodType",(e,t)=>{var n;e??(e={}),e._zod.def=t,e._zod.bag=e._zod.bag||{},e._zod.version=Nf;let o=[...e._zod.def.checks??[]];e._zod.traits.has("$ZodCheck")&&o.unshift(e);for(let r of o)for(let i of r._zod.onattach)i(e);if(o.length===0)(n=e._zod).deferred??(n.deferred=[]),e._zod.deferred?.push(()=>{e._zod.run=e._zod.parse});else{let r=(a,s,c)=>{let l=$r(a),d;for(let f of s){if(f._zod.def.when){if(!f._zod.def.when(a))continue}else if(l)continue;let _=a.issues.length,v=f._zod.check(a);if(v instanceof Promise&&c?.async===!1)throw new Et;if(d||v instanceof Promise)d=(d??Promise.resolve()).then(async()=>{await v,a.issues.length!==_&&(l||(l=$r(a,_)))});else{if(a.issues.length===_)continue;l||(l=$r(a,_))}}return d?d.then(()=>a):a},i=(a,s,c)=>{if($r(a))return a.aborted=!0,a;let l=r(s,o,c);if(l instanceof Promise){if(c.async===!1)throw new Et;return l.then(d=>e._zod.parse(d,c))}return e._zod.parse(l,c)};e._zod.run=(a,s)=>{if(s.skipChecks)return e._zod.parse(a,s);if(s.direction==="backward"){let l=e._zod.parse({value:a.value,issues:[]},{...s,skipChecks:!0});return l instanceof Promise?l.then(d=>i(d,a,s)):i(l,a,s)}let c=e._zod.parse(a,s);if(c instanceof Promise){if(s.async===!1)throw new Et;return c.then(l=>r(l,o,s))}return r(c,o,s)}}e["~standard"]={validate:r=>{try{let i=xr(e,r);return i.success?{value:i.data}:{issues:i.error?.issues}}catch{return wr(e,r).then(a=>a.success?{value:a.data}:{issues:a.error?.issues})}},vendor:"zod",version:1}}),kr=$("$ZodString",(e,t)=>{W.init(e,t),e._zod.pattern=[...e?._zod.bag?.patterns??[]].pop()??af(e._zod.bag),e._zod.parse=(n,o)=>{if(t.coerce)try{n.value=String(n.value)}catch{}return typeof n.value=="string"||n.issues.push({expected:"string",code:"invalid_type",input:n.value,inst:e}),n}}),ge=$("$ZodStringFormat",(e,t)=>{qn.init(e,t),kr.init(e,t)}),bs=$("$ZodGUID",(e,t)=>{t.pattern??(t.pattern=Kd),ge.init(e,t)}),$s=$("$ZodUUID",(e,t)=>{if(t.version){let o={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[t.version];if(o===void 0)throw new Error(`Invalid UUID version: "${t.version}"`);t.pattern??(t.pattern=Wr(o))}else t.pattern??(t.pattern=Wr());ge.init(e,t)}),xs=$("$ZodEmail",(e,t)=>{t.pattern??(t.pattern=Hd),ge.init(e,t)}),ws=$("$ZodURL",(e,t)=>{ge.init(e,t),e._zod.check=n=>{try{let o=n.value.trim(),r=new URL(o);t.hostname&&(t.hostname.lastIndex=0,t.hostname.test(r.hostname)||n.issues.push({code:"invalid_format",format:"url",note:"Invalid hostname",pattern:ef.source,input:n.value,inst:e,continue:!t.abort})),t.protocol&&(t.protocol.lastIndex=0,t.protocol.test(r.protocol.endsWith(":")?r.protocol.slice(0,-1):r.protocol)||n.issues.push({code:"invalid_format",format:"url",note:"Invalid protocol",pattern:t.protocol.source,input:n.value,inst:e,continue:!t.abort})),t.normalize?n.value=r.href:n.value=o;return}catch{n.issues.push({code:"invalid_format",format:"url",input:n.value,inst:e,continue:!t.abort})}}}),ks=$("$ZodEmoji",(e,t)=>{t.pattern??(t.pattern=Jd()),ge.init(e,t)}),Ss=$("$ZodNanoID",(e,t)=>{t.pattern??(t.pattern=Fd),ge.init(e,t)}),zs=$("$ZodCUID",(e,t)=>{t.pattern??(t.pattern=Zd),ge.init(e,t)}),Is=$("$ZodCUID2",(e,t)=>{t.pattern??(t.pattern=Md),ge.init(e,t)}),Es=$("$ZodULID",(e,t)=>{t.pattern??(t.pattern=Ld),ge.init(e,t)}),Ts=$("$ZodXID",(e,t)=>{t.pattern??(t.pattern=qd),ge.init(e,t)}),Ps=$("$ZodKSUID",(e,t)=>{t.pattern??(t.pattern=Vd),ge.init(e,t)}),Os=$("$ZodISODateTime",(e,t)=>{t.pattern??(t.pattern=of(t)),ge.init(e,t)}),js=$("$ZodISODate",(e,t)=>{t.pattern??(t.pattern=rf),ge.init(e,t)}),Ns=$("$ZodISOTime",(e,t)=>{t.pattern??(t.pattern=nf(t)),ge.init(e,t)}),Rs=$("$ZodISODuration",(e,t)=>{t.pattern??(t.pattern=Bd),ge.init(e,t)}),As=$("$ZodIPv4",(e,t)=>{t.pattern??(t.pattern=Gd),ge.init(e,t),e._zod.onattach.push(n=>{let o=n._zod.bag;o.format="ipv4"})}),Ds=$("$ZodIPv6",(e,t)=>{t.pattern??(t.pattern=Wd),ge.init(e,t),e._zod.onattach.push(n=>{let o=n._zod.bag;o.format="ipv6"}),e._zod.check=n=>{try{new URL(`http://[${n.value}]`)}catch{n.issues.push({code:"invalid_format",format:"ipv6",input:n.value,inst:e,continue:!t.abort})}}}),Cs=$("$ZodCIDRv4",(e,t)=>{t.pattern??(t.pattern=Xd),ge.init(e,t)}),Us=$("$ZodCIDRv6",(e,t)=>{t.pattern??(t.pattern=Yd),ge.init(e,t),e._zod.check=n=>{let o=n.value.split("/");try{if(o.length!==2)throw new Error;let[r,i]=o;if(!i)throw new Error;let a=Number(i);if(`${a}`!==i)throw new Error;if(a<0||a>128)throw new Error;new URL(`http://[${r}]`)}catch{n.issues.push({code:"invalid_format",format:"cidrv6",input:n.value,inst:e,continue:!t.abort})}}});function Af(e){if(e==="")return!0;if(e.length%4!==0)return!1;try{return atob(e),!0}catch{return!1}}var Zs=$("$ZodBase64",(e,t)=>{t.pattern??(t.pattern=Qd),ge.init(e,t),e._zod.onattach.push(n=>{n._zod.bag.contentEncoding="base64"}),e._zod.check=n=>{Af(n.value)||n.issues.push({code:"invalid_format",format:"base64",input:n.value,inst:e,continue:!t.abort})}});function kv(e){if(!fs.test(e))return!1;let t=e.replace(/[-_]/g,o=>o==="-"?"+":"/"),n=t.padEnd(Math.ceil(t.length/4)*4,"=");return Af(n)}var Ms=$("$ZodBase64URL",(e,t)=>{t.pattern??(t.pattern=fs),ge.init(e,t),e._zod.onattach.push(n=>{n._zod.bag.contentEncoding="base64url"}),e._zod.check=n=>{kv(n.value)||n.issues.push({code:"invalid_format",format:"base64url",input:n.value,inst:e,continue:!t.abort})}}),Ls=$("$ZodE164",(e,t)=>{t.pattern??(t.pattern=tf),ge.init(e,t)});function Sv(e,t=null){try{let n=e.split(".");if(n.length!==3)return!1;let[o]=n;if(!o)return!1;let r=JSON.parse(atob(o));return!("typ"in r&&r?.typ!=="JWT"||!r.alg||t&&(!("alg"in r)||r.alg!==t))}catch{return!1}}var qs=$("$ZodJWT",(e,t)=>{ge.init(e,t),e._zod.check=n=>{Sv(n.value,t.alg)||n.issues.push({code:"invalid_format",format:"jwt",input:n.value,inst:e,continue:!t.abort})}}),Vs=$("$ZodCustomStringFormat",(e,t)=>{ge.init(e,t),e._zod.check=n=>{t.fn(n.value)||n.issues.push({code:"invalid_format",format:t.format,input:n.value,inst:e,continue:!t.abort})}}),li=$("$ZodNumber",(e,t)=>{W.init(e,t),e._zod.pattern=e._zod.bag.pattern??uf,e._zod.parse=(n,o)=>{if(t.coerce)try{n.value=Number(n.value)}catch{}let r=n.value;if(typeof r=="number"&&!Number.isNaN(r)&&Number.isFinite(r))return n;let i=typeof r=="number"?Number.isNaN(r)?"NaN":Number.isFinite(r)?void 0:"Infinity":void 0;return n.issues.push({expected:"number",code:"invalid_type",input:r,inst:e,...i?{received:i}:{}}),n}}),Fs=$("$ZodNumber",(e,t)=>{gf.init(e,t),li.init(e,t)}),Vn=$("$ZodBoolean",(e,t)=>{W.init(e,t),e._zod.pattern=lf,e._zod.parse=(n,o)=>{if(t.coerce)try{n.value=!!n.value}catch{}let r=n.value;return typeof r=="boolean"||n.issues.push({expected:"boolean",code:"invalid_type",input:r,inst:e}),n}}),di=$("$ZodBigInt",(e,t)=>{W.init(e,t),e._zod.pattern=sf,e._zod.parse=(n,o)=>{if(t.coerce)try{n.value=BigInt(n.value)}catch{}return typeof n.value=="bigint"||n.issues.push({expected:"bigint",code:"invalid_type",input:n.value,inst:e}),n}}),Bs=$("$ZodBigInt",(e,t)=>{vf.init(e,t),di.init(e,t)}),Ks=$("$ZodSymbol",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{let r=n.value;return typeof r=="symbol"||n.issues.push({expected:"symbol",code:"invalid_type",input:r,inst:e}),n}}),Hs=$("$ZodUndefined",(e,t)=>{W.init(e,t),e._zod.pattern=ff,e._zod.values=new Set([void 0]),e._zod.optin="optional",e._zod.optout="optional",e._zod.parse=(n,o)=>{let r=n.value;return typeof r>"u"||n.issues.push({expected:"undefined",code:"invalid_type",input:r,inst:e}),n}}),Js=$("$ZodNull",(e,t)=>{W.init(e,t),e._zod.pattern=df,e._zod.values=new Set([null]),e._zod.parse=(n,o)=>{let r=n.value;return r===null||n.issues.push({expected:"null",code:"invalid_type",input:r,inst:e}),n}}),Gs=$("$ZodAny",(e,t)=>{W.init(e,t),e._zod.parse=n=>n}),Ws=$("$ZodUnknown",(e,t)=>{W.init(e,t),e._zod.parse=n=>n}),Xs=$("$ZodNever",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>(n.issues.push({expected:"never",code:"invalid_type",input:n.value,inst:e}),n)}),Ys=$("$ZodVoid",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{let r=n.value;return typeof r>"u"||n.issues.push({expected:"void",code:"invalid_type",input:r,inst:e}),n}}),Qs=$("$ZodDate",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{if(t.coerce)try{n.value=new Date(n.value)}catch{}let r=n.value,i=r instanceof Date;return i&&!Number.isNaN(r.getTime())||n.issues.push({expected:"date",code:"invalid_type",input:r,...i?{received:"Invalid Date"}:{},inst:e}),n}});function mv(e,t,n){e.issues.length&&t.issues.push(...dt(n,e.issues)),t.value[n]=e.value}var ec=$("$ZodArray",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{let r=n.value;if(!Array.isArray(r))return n.issues.push({expected:"array",code:"invalid_type",input:r,inst:e}),n;n.value=Array(r.length);let i=[];for(let a=0;a<r.length;a++){let s=r[a],c=t.element._zod.run({value:s,issues:[]},o);c instanceof Promise?i.push(c.then(l=>mv(l,n,a))):mv(c,n,a)}return i.length?Promise.all(i).then(()=>n):n}});function ys(e,t,n,o){e.issues.length&&t.issues.push(...dt(n,e.issues)),e.value===void 0?n in o&&(t.value[n]=void 0):t.value[n]=e.value}function zv(e){let t=Object.keys(e.shape);for(let o of t)if(!e.shape?.[o]?._zod?.traits?.has("$ZodType"))throw new Error(`Invalid element at key "${o}": expected a Zod schema`);let n=Dd(e.shape);return{...e,keys:t,keySet:new Set(t),numKeys:t.length,optionalKeys:new Set(n)}}function Iv(e,t,n,o,r,i){let a=[],s=r.keySet,c=r.catchall._zod,l=c.def.type;for(let d of Object.keys(t)){if(s.has(d))continue;if(l==="never"){a.push(d);continue}let f=c.run({value:t[d],issues:[]},o);f instanceof Promise?e.push(f.then(_=>ys(_,n,d,t))):ys(f,n,d,t)}return a.length&&n.issues.push({code:"unrecognized_keys",keys:a,input:t,inst:i}),e.length?Promise.all(e).then(()=>n):n}var tc=$("$ZodObject",(e,t)=>{W.init(e,t);let n=Rn(()=>zv(t));se(e._zod,"propValues",()=>{let a=t.shape,s={};for(let c in a){let l=a[c]._zod;if(l.values){s[c]??(s[c]=new Set);for(let d of l.values)s[c].add(d)}}return s});let o=Hr,r=t.catchall,i;e._zod.parse=(a,s)=>{i??(i=n.value);let c=a.value;if(!o(c))return a.issues.push({expected:"object",code:"invalid_type",input:c,inst:e}),a;a.value={};let l=[],d=i.shape;for(let f of i.keys){let v=d[f]._zod.run({value:c[f],issues:[]},s);v instanceof Promise?l.push(v.then(g=>ys(g,a,f,c))):ys(v,a,f,c)}return r?Iv(l,c,a,s,n.value,e):l.length?Promise.all(l).then(()=>a):a}}),Df=$("$ZodObjectJIT",(e,t)=>{tc.init(e,t);let n=e._zod.parse,o=Rn(()=>zv(t)),r=_=>{let v=new ui(["shape","payload","ctx"]),g=o.value,b=P=>{let M=es(P);return`shape[${M}]._zod.run({ value: input[${M}], issues: [] }, ctx)`};v.write("const input = payload.value;");let x=Object.create(null),I=0;for(let P of g.keys)x[P]=`key_${I++}`;v.write("const newResult = {};");for(let P of g.keys){let M=x[P],V=es(P);v.write(`const ${M} = ${b(P)};`),v.write(`
|
|
37
|
+
`))}};var Af={major:4,minor:1,patch:9};var W=$("$ZodType",(e,t)=>{var n;e??(e={}),e._zod.def=t,e._zod.bag=e._zod.bag||{},e._zod.version=Af;let o=[...e._zod.def.checks??[]];e._zod.traits.has("$ZodCheck")&&o.unshift(e);for(let r of o)for(let i of r._zod.onattach)i(e);if(o.length===0)(n=e._zod).deferred??(n.deferred=[]),e._zod.deferred?.push(()=>{e._zod.run=e._zod.parse});else{let r=(a,s,c)=>{let l=$r(a),d;for(let f of s){if(f._zod.def.when){if(!f._zod.def.when(a))continue}else if(l)continue;let _=a.issues.length,v=f._zod.check(a);if(v instanceof Promise&&c?.async===!1)throw new Et;if(d||v instanceof Promise)d=(d??Promise.resolve()).then(async()=>{await v,a.issues.length!==_&&(l||(l=$r(a,_)))});else{if(a.issues.length===_)continue;l||(l=$r(a,_))}}return d?d.then(()=>a):a},i=(a,s,c)=>{if($r(a))return a.aborted=!0,a;let l=r(s,o,c);if(l instanceof Promise){if(c.async===!1)throw new Et;return l.then(d=>e._zod.parse(d,c))}return e._zod.parse(l,c)};e._zod.run=(a,s)=>{if(s.skipChecks)return e._zod.parse(a,s);if(s.direction==="backward"){let l=e._zod.parse({value:a.value,issues:[]},{...s,skipChecks:!0});return l instanceof Promise?l.then(d=>i(d,a,s)):i(l,a,s)}let c=e._zod.parse(a,s);if(c instanceof Promise){if(s.async===!1)throw new Et;return c.then(l=>r(l,o,s))}return r(c,o,s)}}e["~standard"]={validate:r=>{try{let i=xr(e,r);return i.success?{value:i.data}:{issues:i.error?.issues}}catch{return wr(e,r).then(a=>a.success?{value:a.data}:{issues:a.error?.issues})}},vendor:"zod",version:1}}),kr=$("$ZodString",(e,t)=>{W.init(e,t),e._zod.pattern=[...e?._zod.bag?.patterns??[]].pop()??cf(e._zod.bag),e._zod.parse=(n,o)=>{if(t.coerce)try{n.value=String(n.value)}catch{}return typeof n.value=="string"||n.issues.push({expected:"string",code:"invalid_type",input:n.value,inst:e}),n}}),ge=$("$ZodStringFormat",(e,t)=>{qn.init(e,t),kr.init(e,t)}),$s=$("$ZodGUID",(e,t)=>{t.pattern??(t.pattern=Jd),ge.init(e,t)}),xs=$("$ZodUUID",(e,t)=>{if(t.version){let o={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[t.version];if(o===void 0)throw new Error(`Invalid UUID version: "${t.version}"`);t.pattern??(t.pattern=Wr(o))}else t.pattern??(t.pattern=Wr());ge.init(e,t)}),ws=$("$ZodEmail",(e,t)=>{t.pattern??(t.pattern=Gd),ge.init(e,t)}),ks=$("$ZodURL",(e,t)=>{ge.init(e,t),e._zod.check=n=>{try{let o=n.value.trim(),r=new URL(o);t.hostname&&(t.hostname.lastIndex=0,t.hostname.test(r.hostname)||n.issues.push({code:"invalid_format",format:"url",note:"Invalid hostname",pattern:rf.source,input:n.value,inst:e,continue:!t.abort})),t.protocol&&(t.protocol.lastIndex=0,t.protocol.test(r.protocol.endsWith(":")?r.protocol.slice(0,-1):r.protocol)||n.issues.push({code:"invalid_format",format:"url",note:"Invalid protocol",pattern:t.protocol.source,input:n.value,inst:e,continue:!t.abort})),t.normalize?n.value=r.href:n.value=o;return}catch{n.issues.push({code:"invalid_format",format:"url",input:n.value,inst:e,continue:!t.abort})}}}),Ss=$("$ZodEmoji",(e,t)=>{t.pattern??(t.pattern=Wd()),ge.init(e,t)}),zs=$("$ZodNanoID",(e,t)=>{t.pattern??(t.pattern=Kd),ge.init(e,t)}),Is=$("$ZodCUID",(e,t)=>{t.pattern??(t.pattern=Ld),ge.init(e,t)}),Es=$("$ZodCUID2",(e,t)=>{t.pattern??(t.pattern=qd),ge.init(e,t)}),Ts=$("$ZodULID",(e,t)=>{t.pattern??(t.pattern=Vd),ge.init(e,t)}),Os=$("$ZodXID",(e,t)=>{t.pattern??(t.pattern=Fd),ge.init(e,t)}),Ps=$("$ZodKSUID",(e,t)=>{t.pattern??(t.pattern=Bd),ge.init(e,t)}),js=$("$ZodISODateTime",(e,t)=>{t.pattern??(t.pattern=sf(t)),ge.init(e,t)}),Ns=$("$ZodISODate",(e,t)=>{t.pattern??(t.pattern=of),ge.init(e,t)}),Rs=$("$ZodISOTime",(e,t)=>{t.pattern??(t.pattern=af(t)),ge.init(e,t)}),As=$("$ZodISODuration",(e,t)=>{t.pattern??(t.pattern=Hd),ge.init(e,t)}),Ds=$("$ZodIPv4",(e,t)=>{t.pattern??(t.pattern=Xd),ge.init(e,t),e._zod.onattach.push(n=>{let o=n._zod.bag;o.format="ipv4"})}),Cs=$("$ZodIPv6",(e,t)=>{t.pattern??(t.pattern=Yd),ge.init(e,t),e._zod.onattach.push(n=>{let o=n._zod.bag;o.format="ipv6"}),e._zod.check=n=>{try{new URL(`http://[${n.value}]`)}catch{n.issues.push({code:"invalid_format",format:"ipv6",input:n.value,inst:e,continue:!t.abort})}}}),Us=$("$ZodCIDRv4",(e,t)=>{t.pattern??(t.pattern=Qd),ge.init(e,t)}),Zs=$("$ZodCIDRv6",(e,t)=>{t.pattern??(t.pattern=ef),ge.init(e,t),e._zod.check=n=>{let o=n.value.split("/");try{if(o.length!==2)throw new Error;let[r,i]=o;if(!i)throw new Error;let a=Number(i);if(`${a}`!==i)throw new Error;if(a<0||a>128)throw new Error;new URL(`http://[${r}]`)}catch{n.issues.push({code:"invalid_format",format:"cidrv6",input:n.value,inst:e,continue:!t.abort})}}});function Cf(e){if(e==="")return!0;if(e.length%4!==0)return!1;try{return atob(e),!0}catch{return!1}}var Ms=$("$ZodBase64",(e,t)=>{t.pattern??(t.pattern=tf),ge.init(e,t),e._zod.onattach.push(n=>{n._zod.bag.contentEncoding="base64"}),e._zod.check=n=>{Cf(n.value)||n.issues.push({code:"invalid_format",format:"base64",input:n.value,inst:e,continue:!t.abort})}});function Iv(e){if(!ps.test(e))return!1;let t=e.replace(/[-_]/g,o=>o==="-"?"+":"/"),n=t.padEnd(Math.ceil(t.length/4)*4,"=");return Cf(n)}var Ls=$("$ZodBase64URL",(e,t)=>{t.pattern??(t.pattern=ps),ge.init(e,t),e._zod.onattach.push(n=>{n._zod.bag.contentEncoding="base64url"}),e._zod.check=n=>{Iv(n.value)||n.issues.push({code:"invalid_format",format:"base64url",input:n.value,inst:e,continue:!t.abort})}}),qs=$("$ZodE164",(e,t)=>{t.pattern??(t.pattern=nf),ge.init(e,t)});function Ev(e,t=null){try{let n=e.split(".");if(n.length!==3)return!1;let[o]=n;if(!o)return!1;let r=JSON.parse(atob(o));return!("typ"in r&&r?.typ!=="JWT"||!r.alg||t&&(!("alg"in r)||r.alg!==t))}catch{return!1}}var Vs=$("$ZodJWT",(e,t)=>{ge.init(e,t),e._zod.check=n=>{Ev(n.value,t.alg)||n.issues.push({code:"invalid_format",format:"jwt",input:n.value,inst:e,continue:!t.abort})}}),Fs=$("$ZodCustomStringFormat",(e,t)=>{ge.init(e,t),e._zod.check=n=>{t.fn(n.value)||n.issues.push({code:"invalid_format",format:t.format,input:n.value,inst:e,continue:!t.abort})}}),li=$("$ZodNumber",(e,t)=>{W.init(e,t),e._zod.pattern=e._zod.bag.pattern??df,e._zod.parse=(n,o)=>{if(t.coerce)try{n.value=Number(n.value)}catch{}let r=n.value;if(typeof r=="number"&&!Number.isNaN(r)&&Number.isFinite(r))return n;let i=typeof r=="number"?Number.isNaN(r)?"NaN":Number.isFinite(r)?void 0:"Infinity":void 0;return n.issues.push({expected:"number",code:"invalid_type",input:r,inst:e,...i?{received:i}:{}}),n}}),Bs=$("$ZodNumber",(e,t)=>{_f.init(e,t),li.init(e,t)}),Vn=$("$ZodBoolean",(e,t)=>{W.init(e,t),e._zod.pattern=ff,e._zod.parse=(n,o)=>{if(t.coerce)try{n.value=!!n.value}catch{}let r=n.value;return typeof r=="boolean"||n.issues.push({expected:"boolean",code:"invalid_type",input:r,inst:e}),n}}),di=$("$ZodBigInt",(e,t)=>{W.init(e,t),e._zod.pattern=uf,e._zod.parse=(n,o)=>{if(t.coerce)try{n.value=BigInt(n.value)}catch{}return typeof n.value=="bigint"||n.issues.push({expected:"bigint",code:"invalid_type",input:n.value,inst:e}),n}}),Ks=$("$ZodBigInt",(e,t)=>{yf.init(e,t),di.init(e,t)}),Hs=$("$ZodSymbol",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{let r=n.value;return typeof r=="symbol"||n.issues.push({expected:"symbol",code:"invalid_type",input:r,inst:e}),n}}),Js=$("$ZodUndefined",(e,t)=>{W.init(e,t),e._zod.pattern=mf,e._zod.values=new Set([void 0]),e._zod.optin="optional",e._zod.optout="optional",e._zod.parse=(n,o)=>{let r=n.value;return typeof r>"u"||n.issues.push({expected:"undefined",code:"invalid_type",input:r,inst:e}),n}}),Gs=$("$ZodNull",(e,t)=>{W.init(e,t),e._zod.pattern=pf,e._zod.values=new Set([null]),e._zod.parse=(n,o)=>{let r=n.value;return r===null||n.issues.push({expected:"null",code:"invalid_type",input:r,inst:e}),n}}),Ws=$("$ZodAny",(e,t)=>{W.init(e,t),e._zod.parse=n=>n}),Xs=$("$ZodUnknown",(e,t)=>{W.init(e,t),e._zod.parse=n=>n}),Ys=$("$ZodNever",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>(n.issues.push({expected:"never",code:"invalid_type",input:n.value,inst:e}),n)}),Qs=$("$ZodVoid",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{let r=n.value;return typeof r>"u"||n.issues.push({expected:"void",code:"invalid_type",input:r,inst:e}),n}}),ec=$("$ZodDate",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{if(t.coerce)try{n.value=new Date(n.value)}catch{}let r=n.value,i=r instanceof Date;return i&&!Number.isNaN(r.getTime())||n.issues.push({expected:"date",code:"invalid_type",input:r,...i?{received:"Invalid Date"}:{},inst:e}),n}});function vv(e,t,n){e.issues.length&&t.issues.push(...dt(n,e.issues)),t.value[n]=e.value}var tc=$("$ZodArray",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{let r=n.value;if(!Array.isArray(r))return n.issues.push({expected:"array",code:"invalid_type",input:r,inst:e}),n;n.value=Array(r.length);let i=[];for(let a=0;a<r.length;a++){let s=r[a],c=t.element._zod.run({value:s,issues:[]},o);c instanceof Promise?i.push(c.then(l=>vv(l,n,a))):vv(c,n,a)}return i.length?Promise.all(i).then(()=>n):n}});function bs(e,t,n,o){e.issues.length&&t.issues.push(...dt(n,e.issues)),e.value===void 0?n in o&&(t.value[n]=void 0):t.value[n]=e.value}function Tv(e){let t=Object.keys(e.shape);for(let o of t)if(!e.shape?.[o]?._zod?.traits?.has("$ZodType"))throw new Error(`Invalid element at key "${o}": expected a Zod schema`);let n=Ud(e.shape);return{...e,keys:t,keySet:new Set(t),numKeys:t.length,optionalKeys:new Set(n)}}function Ov(e,t,n,o,r,i){let a=[],s=r.keySet,c=r.catchall._zod,l=c.def.type;for(let d of Object.keys(t)){if(s.has(d))continue;if(l==="never"){a.push(d);continue}let f=c.run({value:t[d],issues:[]},o);f instanceof Promise?e.push(f.then(_=>bs(_,n,d,t))):bs(f,n,d,t)}return a.length&&n.issues.push({code:"unrecognized_keys",keys:a,input:t,inst:i}),e.length?Promise.all(e).then(()=>n):n}var rc=$("$ZodObject",(e,t)=>{W.init(e,t);let n=Rn(()=>Tv(t));se(e._zod,"propValues",()=>{let a=t.shape,s={};for(let c in a){let l=a[c]._zod;if(l.values){s[c]??(s[c]=new Set);for(let d of l.values)s[c].add(d)}}return s});let o=Hr,r=t.catchall,i;e._zod.parse=(a,s)=>{i??(i=n.value);let c=a.value;if(!o(c))return a.issues.push({expected:"object",code:"invalid_type",input:c,inst:e}),a;a.value={};let l=[],d=i.shape;for(let f of i.keys){let v=d[f]._zod.run({value:c[f],issues:[]},s);v instanceof Promise?l.push(v.then(g=>bs(g,a,f,c))):bs(v,a,f,c)}return r?Ov(l,c,a,s,n.value,e):l.length?Promise.all(l).then(()=>a):a}}),Uf=$("$ZodObjectJIT",(e,t)=>{rc.init(e,t);let n=e._zod.parse,o=Rn(()=>Tv(t)),r=_=>{let v=new ui(["shape","payload","ctx"]),g=o.value,b=O=>{let M=ts(O);return`shape[${M}]._zod.run({ value: input[${M}], issues: [] }, ctx)`};v.write("const input = payload.value;");let x=Object.create(null),I=0;for(let O of g.keys)x[O]=`key_${I++}`;v.write("const newResult = {};");for(let O of g.keys){let M=x[O],V=ts(O);v.write(`const ${M} = ${b(O)};`),v.write(`
|
|
38
38
|
if (${M}.issues.length) {
|
|
39
39
|
payload.issues = payload.issues.concat(${M}.issues.map(iss => ({
|
|
40
40
|
...iss,
|
|
@@ -51,19 +51,30 @@ metadata was removed`},h=V(u,null,null,{redactedPaths:Sg,redactedKeys:m})),h},Fa
|
|
|
51
51
|
newResult[${V}] = ${M}.value;
|
|
52
52
|
}
|
|
53
53
|
|
|
54
|
-
`)}v.write("payload.value = newResult;"),v.write("return payload;");let R=v.compile();return(P,M)=>R(_,P,M)},i,a=Hr,s=!Yo.jitless,l=s&&Nd.value,d=t.catchall,f;e._zod.parse=(_,v)=>{f??(f=o.value);let g=_.value;return a(g)?s&&l&&v?.async===!1&&v.jitless!==!0?(i||(i=r(t.shape)),_=i(_,v),d?Iv([],g,_,v,f,e):_):n(_,v):(_.issues.push({expected:"object",code:"invalid_type",input:g,inst:e}),_)}});function hv(e,t,n,o){for(let i of e)if(i.issues.length===0)return t.value=i.value,t;let r=e.filter(i=>!$r(i));return r.length===1?(t.value=r[0].value,r[0]):(t.issues.push({code:"invalid_union",input:t.value,inst:n,errors:e.map(i=>i.issues.map(a=>ft(a,o,Ee())))}),t)}var fi=$("$ZodUnion",(e,t)=>{W.init(e,t),se(e._zod,"optin",()=>t.options.some(r=>r._zod.optin==="optional")?"optional":void 0),se(e._zod,"optout",()=>t.options.some(r=>r._zod.optout==="optional")?"optional":void 0),se(e._zod,"values",()=>{if(t.options.every(r=>r._zod.values))return new Set(t.options.flatMap(r=>Array.from(r._zod.values)))}),se(e._zod,"pattern",()=>{if(t.options.every(r=>r._zod.pattern)){let r=t.options.map(i=>i._zod.pattern);return new RegExp(`^(${r.map(i=>ri(i.source)).join("|")})$`)}});let n=t.options.length===1,o=t.options[0]._zod.run;e._zod.parse=(r,i)=>{if(n)return o(r,i);let a=!1,s=[];for(let c of t.options){let l=c._zod.run({value:r.value,issues:[]},i);if(l instanceof Promise)s.push(l),a=!0;else{if(l.issues.length===0)return l;s.push(l)}}return a?Promise.all(s).then(c=>hv(c,r,e,i)):hv(s,r,e,i)}}),rc=$("$ZodDiscriminatedUnion",(e,t)=>{fi.init(e,t);let n=e._zod.parse;se(e._zod,"propValues",()=>{let r={};for(let i of t.options){let a=i._zod.propValues;if(!a||Object.keys(a).length===0)throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(i)}"`);for(let[s,c]of Object.entries(a)){r[s]||(r[s]=new Set);for(let l of c)r[s].add(l)}}return r});let o=Rn(()=>{let r=t.options,i=new Map;for(let a of r){let s=a._zod.propValues?.[t.discriminator];if(!s||s.size===0)throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(a)}"`);for(let c of s){if(i.has(c))throw new Error(`Duplicate discriminator value "${String(c)}"`);i.set(c,a)}}return i});e._zod.parse=(r,i)=>{let a=r.value;if(!Hr(a))return r.issues.push({code:"invalid_type",expected:"object",input:a,inst:e}),r;let s=o.value.get(a?.[t.discriminator]);return s?s._zod.run(r,i):t.unionFallback?n(r,i):(r.issues.push({code:"invalid_union",errors:[],note:"No matching discriminator",discriminator:t.discriminator,input:a,path:[t.discriminator],inst:e}),r)}}),nc=$("$ZodIntersection",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{let r=n.value,i=t.left._zod.run({value:r,issues:[]},o),a=t.right._zod.run({value:r,issues:[]},o);return i instanceof Promise||a instanceof Promise?Promise.all([i,a]).then(([c,l])=>gv(n,c,l)):gv(n,i,a)}});function Rf(e,t){if(e===t)return{valid:!0,data:e};if(e instanceof Date&&t instanceof Date&&+e==+t)return{valid:!0,data:e};if(br(e)&&br(t)){let n=Object.keys(t),o=Object.keys(e).filter(i=>n.indexOf(i)!==-1),r={...e,...t};for(let i of o){let a=Rf(e[i],t[i]);if(!a.valid)return{valid:!1,mergeErrorPath:[i,...a.mergeErrorPath]};r[i]=a.data}return{valid:!0,data:r}}if(Array.isArray(e)&&Array.isArray(t)){if(e.length!==t.length)return{valid:!1,mergeErrorPath:[]};let n=[];for(let o=0;o<e.length;o++){let r=e[o],i=t[o],a=Rf(r,i);if(!a.valid)return{valid:!1,mergeErrorPath:[o,...a.mergeErrorPath]};n.push(a.data)}return{valid:!0,data:n}}return{valid:!1,mergeErrorPath:[]}}function gv(e,t,n){if(t.issues.length&&e.issues.push(...t.issues),n.issues.length&&e.issues.push(...n.issues),$r(e))return e;let o=Rf(t.value,n.value);if(!o.valid)throw new Error(`Unmergable intersection. Error path: ${JSON.stringify(o.mergeErrorPath)}`);return e.value=o.data,e}var pi=$("$ZodTuple",(e,t)=>{W.init(e,t);let n=t.items,o=n.length-[...n].reverse().findIndex(r=>r._zod.optin!=="optional");e._zod.parse=(r,i)=>{let a=r.value;if(!Array.isArray(a))return r.issues.push({input:a,inst:e,expected:"tuple",code:"invalid_type"}),r;r.value=[];let s=[];if(!t.rest){let l=a.length>n.length,d=a.length<o-1;if(l||d)return r.issues.push({...l?{code:"too_big",maximum:n.length}:{code:"too_small",minimum:n.length},input:a,inst:e,origin:"array"}),r}let c=-1;for(let l of n){if(c++,c>=a.length&&c>=o)continue;let d=l._zod.run({value:a[c],issues:[]},i);d instanceof Promise?s.push(d.then(f=>hs(f,r,c))):hs(d,r,c)}if(t.rest){let l=a.slice(n.length);for(let d of l){c++;let f=t.rest._zod.run({value:d,issues:[]},i);f instanceof Promise?s.push(f.then(_=>hs(_,r,c))):hs(f,r,c)}}return s.length?Promise.all(s).then(()=>r):r}});function hs(e,t,n){e.issues.length&&t.issues.push(...dt(n,e.issues)),t.value[n]=e.value}var oc=$("$ZodRecord",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{let r=n.value;if(!br(r))return n.issues.push({expected:"record",code:"invalid_type",input:r,inst:e}),n;let i=[];if(t.keyType._zod.values){let a=t.keyType._zod.values;n.value={};for(let c of a)if(typeof c=="string"||typeof c=="number"||typeof c=="symbol"){let l=t.valueType._zod.run({value:r[c],issues:[]},o);l instanceof Promise?i.push(l.then(d=>{d.issues.length&&n.issues.push(...dt(c,d.issues)),n.value[c]=d.value})):(l.issues.length&&n.issues.push(...dt(c,l.issues)),n.value[c]=l.value)}let s;for(let c in r)a.has(c)||(s=s??[],s.push(c));s&&s.length>0&&n.issues.push({code:"unrecognized_keys",input:r,inst:e,keys:s})}else{n.value={};for(let a of Reflect.ownKeys(r)){if(a==="__proto__")continue;let s=t.keyType._zod.run({value:a,issues:[]},o);if(s instanceof Promise)throw new Error("Async schemas not supported in object keys currently");if(s.issues.length){n.issues.push({code:"invalid_key",origin:"record",issues:s.issues.map(l=>ft(l,o,Ee())),input:a,path:[a],inst:e}),n.value[s.value]=s.value;continue}let c=t.valueType._zod.run({value:r[a],issues:[]},o);c instanceof Promise?i.push(c.then(l=>{l.issues.length&&n.issues.push(...dt(a,l.issues)),n.value[s.value]=l.value})):(c.issues.length&&n.issues.push(...dt(a,c.issues)),n.value[s.value]=c.value)}}return i.length?Promise.all(i).then(()=>n):n}}),ic=$("$ZodMap",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{let r=n.value;if(!(r instanceof Map))return n.issues.push({expected:"map",code:"invalid_type",input:r,inst:e}),n;let i=[];n.value=new Map;for(let[a,s]of r){let c=t.keyType._zod.run({value:a,issues:[]},o),l=t.valueType._zod.run({value:s,issues:[]},o);c instanceof Promise||l instanceof Promise?i.push(Promise.all([c,l]).then(([d,f])=>{vv(d,f,n,a,r,e,o)})):vv(c,l,n,a,r,e,o)}return i.length?Promise.all(i).then(()=>n):n}});function vv(e,t,n,o,r,i,a){e.issues.length&&(ni.has(typeof o)?n.issues.push(...dt(o,e.issues)):n.issues.push({code:"invalid_key",origin:"map",input:r,inst:i,issues:e.issues.map(s=>ft(s,a,Ee()))})),t.issues.length&&(ni.has(typeof o)?n.issues.push(...dt(o,t.issues)):n.issues.push({origin:"map",code:"invalid_element",input:r,inst:i,key:o,issues:t.issues.map(s=>ft(s,a,Ee()))})),n.value.set(e.value,t.value)}var ac=$("$ZodSet",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{let r=n.value;if(!(r instanceof Set))return n.issues.push({input:r,inst:e,expected:"set",code:"invalid_type"}),n;let i=[];n.value=new Set;for(let a of r){let s=t.valueType._zod.run({value:a,issues:[]},o);s instanceof Promise?i.push(s.then(c=>_v(c,n))):_v(s,n)}return i.length?Promise.all(i).then(()=>n):n}});function _v(e,t){e.issues.length&&t.issues.push(...e.issues),t.value.add(e.value)}var sc=$("$ZodEnum",(e,t)=>{W.init(e,t);let n=ti(t.entries),o=new Set(n);e._zod.values=o,e._zod.pattern=new RegExp(`^(${n.filter(r=>ni.has(typeof r)).map(r=>typeof r=="string"?Ut(r):r.toString()).join("|")})$`),e._zod.parse=(r,i)=>{let a=r.value;return o.has(a)||r.issues.push({code:"invalid_value",values:n,input:a,inst:e}),r}}),cc=$("$ZodLiteral",(e,t)=>{if(W.init(e,t),t.values.length===0)throw new Error("Cannot create literal schema with no valid values");e._zod.values=new Set(t.values),e._zod.pattern=new RegExp(`^(${t.values.map(n=>typeof n=="string"?Ut(n):n?Ut(n.toString()):String(n)).join("|")})$`),e._zod.parse=(n,o)=>{let r=n.value;return e._zod.values.has(r)||n.issues.push({code:"invalid_value",values:t.values,input:r,inst:e}),n}}),uc=$("$ZodFile",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{let r=n.value;return r instanceof File||n.issues.push({expected:"file",code:"invalid_type",input:r,inst:e}),n}}),lc=$("$ZodTransform",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{if(o.direction==="backward")throw new gr(e.constructor.name);let r=t.transform(n.value,n);if(o.async)return(r instanceof Promise?r:Promise.resolve(r)).then(a=>(n.value=a,n));if(r instanceof Promise)throw new Et;return n.value=r,n}});function yv(e,t){return e.issues.length&&t===void 0?{issues:[],value:void 0}:e}var dc=$("$ZodOptional",(e,t)=>{W.init(e,t),e._zod.optin="optional",e._zod.optout="optional",se(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,void 0]):void 0),se(e._zod,"pattern",()=>{let n=t.innerType._zod.pattern;return n?new RegExp(`^(${ri(n.source)})?$`):void 0}),e._zod.parse=(n,o)=>{if(t.innerType._zod.optin==="optional"){let r=t.innerType._zod.run(n,o);return r instanceof Promise?r.then(i=>yv(i,n.value)):yv(r,n.value)}return n.value===void 0?n:t.innerType._zod.run(n,o)}}),fc=$("$ZodNullable",(e,t)=>{W.init(e,t),se(e._zod,"optin",()=>t.innerType._zod.optin),se(e._zod,"optout",()=>t.innerType._zod.optout),se(e._zod,"pattern",()=>{let n=t.innerType._zod.pattern;return n?new RegExp(`^(${ri(n.source)}|null)$`):void 0}),se(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,null]):void 0),e._zod.parse=(n,o)=>n.value===null?n:t.innerType._zod.run(n,o)}),pc=$("$ZodDefault",(e,t)=>{W.init(e,t),e._zod.optin="optional",se(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(n,o)=>{if(o.direction==="backward")return t.innerType._zod.run(n,o);if(n.value===void 0)return n.value=t.defaultValue,n;let r=t.innerType._zod.run(n,o);return r instanceof Promise?r.then(i=>bv(i,t)):bv(r,t)}});function bv(e,t){return e.value===void 0&&(e.value=t.defaultValue),e}var mc=$("$ZodPrefault",(e,t)=>{W.init(e,t),e._zod.optin="optional",se(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(n,o)=>(o.direction==="backward"||n.value===void 0&&(n.value=t.defaultValue),t.innerType._zod.run(n,o))}),hc=$("$ZodNonOptional",(e,t)=>{W.init(e,t),se(e._zod,"values",()=>{let n=t.innerType._zod.values;return n?new Set([...n].filter(o=>o!==void 0)):void 0}),e._zod.parse=(n,o)=>{let r=t.innerType._zod.run(n,o);return r instanceof Promise?r.then(i=>$v(i,e)):$v(r,e)}});function $v(e,t){return!e.issues.length&&e.value===void 0&&e.issues.push({code:"invalid_type",expected:"nonoptional",input:e.value,inst:t}),e}var gc=$("$ZodSuccess",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{if(o.direction==="backward")throw new gr("ZodSuccess");let r=t.innerType._zod.run(n,o);return r instanceof Promise?r.then(i=>(n.value=i.issues.length===0,n)):(n.value=r.issues.length===0,n)}}),vc=$("$ZodCatch",(e,t)=>{W.init(e,t),se(e._zod,"optin",()=>t.innerType._zod.optin),se(e._zod,"optout",()=>t.innerType._zod.optout),se(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(n,o)=>{if(o.direction==="backward")return t.innerType._zod.run(n,o);let r=t.innerType._zod.run(n,o);return r instanceof Promise?r.then(i=>(n.value=i.value,i.issues.length&&(n.value=t.catchValue({...n,error:{issues:i.issues.map(a=>ft(a,o,Ee()))},input:n.value}),n.issues=[]),n)):(n.value=r.value,r.issues.length&&(n.value=t.catchValue({...n,error:{issues:r.issues.map(i=>ft(i,o,Ee()))},input:n.value}),n.issues=[]),n)}}),_c=$("$ZodNaN",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>((typeof n.value!="number"||!Number.isNaN(n.value))&&n.issues.push({input:n.value,inst:e,expected:"nan",code:"invalid_type"}),n)}),yc=$("$ZodPipe",(e,t)=>{W.init(e,t),se(e._zod,"values",()=>t.in._zod.values),se(e._zod,"optin",()=>t.in._zod.optin),se(e._zod,"optout",()=>t.out._zod.optout),se(e._zod,"propValues",()=>t.in._zod.propValues),e._zod.parse=(n,o)=>{if(o.direction==="backward"){let i=t.out._zod.run(n,o);return i instanceof Promise?i.then(a=>gs(a,t.in,o)):gs(i,t.in,o)}let r=t.in._zod.run(n,o);return r instanceof Promise?r.then(i=>gs(i,t.out,o)):gs(r,t.out,o)}});function gs(e,t,n){return e.issues.length?(e.aborted=!0,e):t._zod.run({value:e.value,issues:e.issues},n)}var Fn=$("$ZodCodec",(e,t)=>{W.init(e,t),se(e._zod,"values",()=>t.in._zod.values),se(e._zod,"optin",()=>t.in._zod.optin),se(e._zod,"optout",()=>t.out._zod.optout),se(e._zod,"propValues",()=>t.in._zod.propValues),e._zod.parse=(n,o)=>{if((o.direction||"forward")==="forward"){let i=t.in._zod.run(n,o);return i instanceof Promise?i.then(a=>vs(a,t,o)):vs(i,t,o)}else{let i=t.out._zod.run(n,o);return i instanceof Promise?i.then(a=>vs(a,t,o)):vs(i,t,o)}}});function vs(e,t,n){if(e.issues.length)return e.aborted=!0,e;if((n.direction||"forward")==="forward"){let r=t.transform(e.value,e);return r instanceof Promise?r.then(i=>_s(e,i,t.out,n)):_s(e,r,t.out,n)}else{let r=t.reverseTransform(e.value,e);return r instanceof Promise?r.then(i=>_s(e,i,t.in,n)):_s(e,r,t.in,n)}}function _s(e,t,n,o){return e.issues.length?(e.aborted=!0,e):n._zod.run({value:t,issues:e.issues},o)}var bc=$("$ZodReadonly",(e,t)=>{W.init(e,t),se(e._zod,"propValues",()=>t.innerType._zod.propValues),se(e._zod,"values",()=>t.innerType._zod.values),se(e._zod,"optin",()=>t.innerType._zod.optin),se(e._zod,"optout",()=>t.innerType._zod.optout),e._zod.parse=(n,o)=>{if(o.direction==="backward")return t.innerType._zod.run(n,o);let r=t.innerType._zod.run(n,o);return r instanceof Promise?r.then(xv):xv(r)}});function xv(e){return e.value=Object.freeze(e.value),e}var $c=$("$ZodTemplateLiteral",(e,t)=>{W.init(e,t);let n=[];for(let o of t.parts)if(typeof o=="object"&&o!==null){if(!o._zod.pattern)throw new Error(`Invalid template literal part, no pattern found: ${[...o._zod.traits].shift()}`);let r=o._zod.pattern instanceof RegExp?o._zod.pattern.source:o._zod.pattern;if(!r)throw new Error(`Invalid template literal part: ${o._zod.traits}`);let i=r.startsWith("^")?1:0,a=r.endsWith("$")?r.length-1:r.length;n.push(r.slice(i,a))}else if(o===null||Ad.has(typeof o))n.push(Ut(`${o}`));else throw new Error(`Invalid template literal part: ${o}`);e._zod.pattern=new RegExp(`^${n.join("")}$`),e._zod.parse=(o,r)=>typeof o.value!="string"?(o.issues.push({input:o.value,inst:e,expected:"template_literal",code:"invalid_type"}),o):(e._zod.pattern.lastIndex=0,e._zod.pattern.test(o.value)||o.issues.push({input:o.value,inst:e,code:"invalid_format",format:t.format??"template_literal",pattern:e._zod.pattern.source}),o)}),xc=$("$ZodFunction",(e,t)=>(W.init(e,t),e._def=t,e._zod.def=t,e.implement=n=>{if(typeof n!="function")throw new Error("implement() must be called with a function");return function(...o){let r=e._def.input?Jr(e._def.input,o):o,i=Reflect.apply(n,this,r);return e._def.output?Jr(e._def.output,i):i}},e.implementAsync=n=>{if(typeof n!="function")throw new Error("implementAsync() must be called with a function");return async function(...o){let r=e._def.input?await Gr(e._def.input,o):o,i=await Reflect.apply(n,this,r);return e._def.output?await Gr(e._def.output,i):i}},e._zod.parse=(n,o)=>typeof n.value!="function"?(n.issues.push({code:"invalid_type",expected:"function",input:n.value,inst:e}),n):(e._def.output&&e._def.output._zod.def.type==="promise"?n.value=e.implementAsync(n.value):n.value=e.implement(n.value),n),e.input=(...n)=>{let o=e.constructor;return Array.isArray(n[0])?new o({type:"function",input:new pi({type:"tuple",items:n[0],rest:n[1]}),output:e._def.output}):new o({type:"function",input:n[0],output:e._def.output})},e.output=n=>{let o=e.constructor;return new o({type:"function",input:e._def.input,output:n})},e)),wc=$("$ZodPromise",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>Promise.resolve(n.value).then(r=>t.innerType._zod.run({value:r,issues:[]},o))}),kc=$("$ZodLazy",(e,t)=>{W.init(e,t),se(e._zod,"innerType",()=>t.getter()),se(e._zod,"pattern",()=>e._zod.innerType._zod.pattern),se(e._zod,"propValues",()=>e._zod.innerType._zod.propValues),se(e._zod,"optin",()=>e._zod.innerType._zod.optin??void 0),se(e._zod,"optout",()=>e._zod.innerType._zod.optout??void 0),e._zod.parse=(n,o)=>e._zod.innerType._zod.run(n,o)}),Sc=$("$ZodCustom",(e,t)=>{$e.init(e,t),W.init(e,t),e._zod.parse=(n,o)=>n,e._zod.check=n=>{let o=n.value,r=t.fn(o);if(r instanceof Promise)return r.then(i=>wv(i,n,o,e));wv(r,n,o,e)}});function wv(e,t,n,o){if(!e){let r={code:"custom",input:n,inst:o,path:[...o._zod.def.path??[]],continue:!o._zod.def.abort};o._zod.def.params&&(r.params=o._zod.def.params),t.issues.push(An(r))}}var Bn={};Fr(Bn,{ar:()=>Ev,az:()=>Tv,be:()=>Ov,ca:()=>jv,cs:()=>Nv,da:()=>Rv,de:()=>Av,en:()=>zc,eo:()=>Dv,es:()=>Cv,fa:()=>Uv,fi:()=>Zv,fr:()=>Mv,frCA:()=>Lv,he:()=>qv,hu:()=>Vv,id:()=>Fv,is:()=>Bv,it:()=>Kv,ja:()=>Hv,ka:()=>Jv,kh:()=>Gv,km:()=>Ic,ko:()=>Wv,lt:()=>Yv,mk:()=>Qv,ms:()=>e_,nl:()=>t_,no:()=>r_,ota:()=>n_,pl:()=>i_,ps:()=>o_,pt:()=>a_,ru:()=>c_,sl:()=>u_,sv:()=>l_,ta:()=>d_,th:()=>f_,tr:()=>p_,ua:()=>m_,uk:()=>Ec,ur:()=>h_,vi:()=>g_,yo:()=>y_,zhCN:()=>v_,zhTW:()=>__});var bz=()=>{let e={string:{unit:"\u062D\u0631\u0641",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"},file:{unit:"\u0628\u0627\u064A\u062A",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"},array:{unit:"\u0639\u0646\u0635\u0631",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"},set:{unit:"\u0639\u0646\u0635\u0631",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"number";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0645\u062F\u062E\u0644",email:"\u0628\u0631\u064A\u062F \u0625\u0644\u0643\u062A\u0631\u0648\u0646\u064A",url:"\u0631\u0627\u0628\u0637",emoji:"\u0625\u064A\u0645\u0648\u062C\u064A",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u062A\u0627\u0631\u064A\u062E \u0648\u0648\u0642\u062A \u0628\u0645\u0639\u064A\u0627\u0631 ISO",date:"\u062A\u0627\u0631\u064A\u062E \u0628\u0645\u0639\u064A\u0627\u0631 ISO",time:"\u0648\u0642\u062A \u0628\u0645\u0639\u064A\u0627\u0631 ISO",duration:"\u0645\u062F\u0629 \u0628\u0645\u0639\u064A\u0627\u0631 ISO",ipv4:"\u0639\u0646\u0648\u0627\u0646 IPv4",ipv6:"\u0639\u0646\u0648\u0627\u0646 IPv6",cidrv4:"\u0645\u062F\u0649 \u0639\u0646\u0627\u0648\u064A\u0646 \u0628\u0635\u064A\u063A\u0629 IPv4",cidrv6:"\u0645\u062F\u0649 \u0639\u0646\u0627\u0648\u064A\u0646 \u0628\u0635\u064A\u063A\u0629 IPv6",base64:"\u0646\u064E\u0635 \u0628\u062A\u0631\u0645\u064A\u0632 base64-encoded",base64url:"\u0646\u064E\u0635 \u0628\u062A\u0631\u0645\u064A\u0632 base64url-encoded",json_string:"\u0646\u064E\u0635 \u0639\u0644\u0649 \u0647\u064A\u0626\u0629 JSON",e164:"\u0631\u0642\u0645 \u0647\u0627\u062A\u0641 \u0628\u0645\u0639\u064A\u0627\u0631 E.164",jwt:"JWT",template_literal:"\u0645\u062F\u062E\u0644"};return r=>{switch(r.code){case"invalid_type":return`\u0645\u062F\u062E\u0644\u0627\u062A \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644\u0629: \u064A\u0641\u062A\u0631\u0636 \u0625\u062F\u062E\u0627\u0644 ${r.expected}\u060C \u0648\u0644\u0643\u0646 \u062A\u0645 \u0625\u062F\u062E\u0627\u0644 ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u0645\u062F\u062E\u0644\u0627\u062A \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644\u0629: \u064A\u0641\u062A\u0631\u0636 \u0625\u062F\u062E\u0627\u0644 ${j(r.values[0])}`:`\u0627\u062E\u062A\u064A\u0627\u0631 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062A\u0648\u0642\u0639 \u0627\u0646\u062A\u0642\u0627\u0621 \u0623\u062D\u062F \u0647\u0630\u0647 \u0627\u0644\u062E\u064A\u0627\u0631\u0627\u062A: ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?` \u0623\u0643\u0628\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0623\u0646 \u062A\u0643\u0648\u0646 ${r.origin??"\u0627\u0644\u0642\u064A\u0645\u0629"} ${i} ${r.maximum.toString()} ${a.unit??"\u0639\u0646\u0635\u0631"}`:`\u0623\u0643\u0628\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0623\u0646 \u062A\u0643\u0648\u0646 ${r.origin??"\u0627\u0644\u0642\u064A\u0645\u0629"} ${i} ${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u0623\u0635\u063A\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0644\u0640 ${r.origin} \u0623\u0646 \u064A\u0643\u0648\u0646 ${i} ${r.minimum.toString()} ${a.unit}`:`\u0623\u0635\u063A\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0644\u0640 ${r.origin} \u0623\u0646 \u064A\u0643\u0648\u0646 ${i} ${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0628\u062F\u0623 \u0628\u0640 "${r.prefix}"`:i.format==="ends_with"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0646\u062A\u0647\u064A \u0628\u0640 "${i.suffix}"`:i.format==="includes"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u062A\u0636\u0645\u0651\u064E\u0646 "${i.includes}"`:i.format==="regex"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0637\u0627\u0628\u0642 \u0627\u0644\u0646\u0645\u0637 ${i.pattern}`:`${o[i.format]??r.format} \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644`}case"not_multiple_of":return`\u0631\u0642\u0645 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0643\u0648\u0646 \u0645\u0646 \u0645\u0636\u0627\u0639\u0641\u0627\u062A ${r.divisor}`;case"unrecognized_keys":return`\u0645\u0639\u0631\u0641${r.keys.length>1?"\u0627\u062A":""} \u063A\u0631\u064A\u0628${r.keys.length>1?"\u0629":""}: ${S(r.keys,"\u060C ")}`;case"invalid_key":return`\u0645\u0639\u0631\u0641 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644 \u0641\u064A ${r.origin}`;case"invalid_union":return"\u0645\u062F\u062E\u0644 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644";case"invalid_element":return`\u0645\u062F\u062E\u0644 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644 \u0641\u064A ${r.origin}`;default:return"\u0645\u062F\u062E\u0644 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644"}}};function Ev(){return{localeError:bz()}}var $z=()=>{let e={string:{unit:"simvol",verb:"olmal\u0131d\u0131r"},file:{unit:"bayt",verb:"olmal\u0131d\u0131r"},array:{unit:"element",verb:"olmal\u0131d\u0131r"},set:{unit:"element",verb:"olmal\u0131d\u0131r"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"number";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"input",email:"email address",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datetime",date:"ISO date",time:"ISO time",duration:"ISO duration",ipv4:"IPv4 address",ipv6:"IPv6 address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded string",base64url:"base64url-encoded string",json_string:"JSON string",e164:"E.164 number",jwt:"JWT",template_literal:"input"};return r=>{switch(r.code){case"invalid_type":return`Yanl\u0131\u015F d\u0259y\u0259r: g\xF6zl\u0259nil\u0259n ${r.expected}, daxil olan ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Yanl\u0131\u015F d\u0259y\u0259r: g\xF6zl\u0259nil\u0259n ${j(r.values[0])}`:`Yanl\u0131\u015F se\xE7im: a\u015Fa\u011F\u0131dak\u0131lardan biri olmal\u0131d\u0131r: ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\xC7ox b\xF6y\xFCk: g\xF6zl\u0259nil\u0259n ${r.origin??"d\u0259y\u0259r"} ${i}${r.maximum.toString()} ${a.unit??"element"}`:`\xC7ox b\xF6y\xFCk: g\xF6zl\u0259nil\u0259n ${r.origin??"d\u0259y\u0259r"} ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\xC7ox ki\xE7ik: g\xF6zl\u0259nil\u0259n ${r.origin} ${i}${r.minimum.toString()} ${a.unit}`:`\xC7ox ki\xE7ik: g\xF6zl\u0259nil\u0259n ${r.origin} ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Yanl\u0131\u015F m\u0259tn: "${i.prefix}" il\u0259 ba\u015Flamal\u0131d\u0131r`:i.format==="ends_with"?`Yanl\u0131\u015F m\u0259tn: "${i.suffix}" il\u0259 bitm\u0259lidir`:i.format==="includes"?`Yanl\u0131\u015F m\u0259tn: "${i.includes}" daxil olmal\u0131d\u0131r`:i.format==="regex"?`Yanl\u0131\u015F m\u0259tn: ${i.pattern} \u015Fablonuna uy\u011Fun olmal\u0131d\u0131r`:`Yanl\u0131\u015F ${o[i.format]??r.format}`}case"not_multiple_of":return`Yanl\u0131\u015F \u0259d\u0259d: ${r.divisor} il\u0259 b\xF6l\xFCn\u0259 bil\u0259n olmal\u0131d\u0131r`;case"unrecognized_keys":return`Tan\u0131nmayan a\xE7ar${r.keys.length>1?"lar":""}: ${S(r.keys,", ")}`;case"invalid_key":return`${r.origin} daxilind\u0259 yanl\u0131\u015F a\xE7ar`;case"invalid_union":return"Yanl\u0131\u015F d\u0259y\u0259r";case"invalid_element":return`${r.origin} daxilind\u0259 yanl\u0131\u015F d\u0259y\u0259r`;default:return"Yanl\u0131\u015F d\u0259y\u0259r"}}};function Tv(){return{localeError:$z()}}function Pv(e,t,n,o){let r=Math.abs(e),i=r%10,a=r%100;return a>=11&&a<=19?o:i===1?t:i>=2&&i<=4?n:o}var xz=()=>{let e={string:{unit:{one:"\u0441\u0456\u043C\u0432\u0430\u043B",few:"\u0441\u0456\u043C\u0432\u0430\u043B\u044B",many:"\u0441\u0456\u043C\u0432\u0430\u043B\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"},array:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u044B",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"},set:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u044B",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"},file:{unit:{one:"\u0431\u0430\u0439\u0442",few:"\u0431\u0430\u0439\u0442\u044B",many:"\u0431\u0430\u0439\u0442\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u043B\u0456\u043A";case"object":{if(Array.isArray(r))return"\u043C\u0430\u0441\u0456\u045E";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0443\u0432\u043E\u0434",email:"email \u0430\u0434\u0440\u0430\u0441",url:"URL",emoji:"\u044D\u043C\u043E\u0434\u0437\u0456",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0434\u0430\u0442\u0430 \u0456 \u0447\u0430\u0441",date:"ISO \u0434\u0430\u0442\u0430",time:"ISO \u0447\u0430\u0441",duration:"ISO \u043F\u0440\u0430\u0446\u044F\u0433\u043B\u0430\u0441\u0446\u044C",ipv4:"IPv4 \u0430\u0434\u0440\u0430\u0441",ipv6:"IPv6 \u0430\u0434\u0440\u0430\u0441",cidrv4:"IPv4 \u0434\u044B\u044F\u043F\u0430\u0437\u043E\u043D",cidrv6:"IPv6 \u0434\u044B\u044F\u043F\u0430\u0437\u043E\u043D",base64:"\u0440\u0430\u0434\u043E\u043A \u0443 \u0444\u0430\u0440\u043C\u0430\u0446\u0435 base64",base64url:"\u0440\u0430\u0434\u043E\u043A \u0443 \u0444\u0430\u0440\u043C\u0430\u0446\u0435 base64url",json_string:"JSON \u0440\u0430\u0434\u043E\u043A",e164:"\u043D\u0443\u043C\u0430\u0440 E.164",jwt:"JWT",template_literal:"\u0443\u0432\u043E\u0434"};return r=>{switch(r.code){case"invalid_type":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434: \u0447\u0430\u043A\u0430\u045E\u0441\u044F ${r.expected}, \u0430\u0442\u0440\u044B\u043C\u0430\u043D\u0430 ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F ${j(r.values[0])}`:`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0432\u0430\u0440\u044B\u044F\u043D\u0442: \u0447\u0430\u043A\u0430\u045E\u0441\u044F \u0430\u0434\u0437\u0456\u043D \u0437 ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);if(a){let s=Number(r.maximum),c=Pv(s,a.unit.one,a.unit.few,a.unit.many);return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u0432\u044F\u043B\u0456\u043A\u0456: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${r.origin??"\u0437\u043D\u0430\u0447\u044D\u043D\u043D\u0435"} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 ${a.verb} ${i}${r.maximum.toString()} ${c}`}return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u0432\u044F\u043B\u0456\u043A\u0456: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${r.origin??"\u0437\u043D\u0430\u0447\u044D\u043D\u043D\u0435"} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 \u0431\u044B\u0446\u044C ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);if(a){let s=Number(r.minimum),c=Pv(s,a.unit.one,a.unit.few,a.unit.many);return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u043C\u0430\u043B\u044B: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${r.origin} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 ${a.verb} ${i}${r.minimum.toString()} ${c}`}return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u043C\u0430\u043B\u044B: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${r.origin} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 \u0431\u044B\u0446\u044C ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u043F\u0430\u0447\u044B\u043D\u0430\u0446\u0446\u0430 \u0437 "${i.prefix}"`:i.format==="ends_with"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0437\u0430\u043A\u0430\u043D\u0447\u0432\u0430\u0446\u0446\u0430 \u043D\u0430 "${i.suffix}"`:i.format==="includes"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0437\u043C\u044F\u0448\u0447\u0430\u0446\u044C "${i.includes}"`:i.format==="regex"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0430\u0434\u043F\u0430\u0432\u044F\u0434\u0430\u0446\u044C \u0448\u0430\u0431\u043B\u043E\u043D\u0443 ${i.pattern}`:`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B ${o[i.format]??r.format}`}case"not_multiple_of":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u043B\u0456\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0431\u044B\u0446\u044C \u043A\u0440\u0430\u0442\u043D\u044B\u043C ${r.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u0430\u0441\u043F\u0430\u0437\u043D\u0430\u043D\u044B ${r.keys.length>1?"\u043A\u043B\u044E\u0447\u044B":"\u043A\u043B\u044E\u0447"}: ${S(r.keys,", ")}`;case"invalid_key":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u043A\u043B\u044E\u0447 \u0443 ${r.origin}`;case"invalid_union":return"\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434";case"invalid_element":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u0430\u0435 \u0437\u043D\u0430\u0447\u044D\u043D\u043D\u0435 \u045E ${r.origin}`;default:return"\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434"}}};function Ov(){return{localeError:xz()}}var wz=()=>{let e={string:{unit:"car\xE0cters",verb:"contenir"},file:{unit:"bytes",verb:"contenir"},array:{unit:"elements",verb:"contenir"},set:{unit:"elements",verb:"contenir"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"number";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"entrada",email:"adre\xE7a electr\xF2nica",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data i hora ISO",date:"data ISO",time:"hora ISO",duration:"durada ISO",ipv4:"adre\xE7a IPv4",ipv6:"adre\xE7a IPv6",cidrv4:"rang IPv4",cidrv6:"rang IPv6",base64:"cadena codificada en base64",base64url:"cadena codificada en base64url",json_string:"cadena JSON",e164:"n\xFAmero E.164",jwt:"JWT",template_literal:"entrada"};return r=>{switch(r.code){case"invalid_type":return`Tipus inv\xE0lid: s'esperava ${r.expected}, s'ha rebut ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Valor inv\xE0lid: s'esperava ${j(r.values[0])}`:`Opci\xF3 inv\xE0lida: s'esperava una de ${S(r.values," o ")}`;case"too_big":{let i=r.inclusive?"com a m\xE0xim":"menys de",a=t(r.origin);return a?`Massa gran: s'esperava que ${r.origin??"el valor"} contingu\xE9s ${i} ${r.maximum.toString()} ${a.unit??"elements"}`:`Massa gran: s'esperava que ${r.origin??"el valor"} fos ${i} ${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?"com a m\xEDnim":"m\xE9s de",a=t(r.origin);return a?`Massa petit: s'esperava que ${r.origin} contingu\xE9s ${i} ${r.minimum.toString()} ${a.unit}`:`Massa petit: s'esperava que ${r.origin} fos ${i} ${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Format inv\xE0lid: ha de comen\xE7ar amb "${i.prefix}"`:i.format==="ends_with"?`Format inv\xE0lid: ha d'acabar amb "${i.suffix}"`:i.format==="includes"?`Format inv\xE0lid: ha d'incloure "${i.includes}"`:i.format==="regex"?`Format inv\xE0lid: ha de coincidir amb el patr\xF3 ${i.pattern}`:`Format inv\xE0lid per a ${o[i.format]??r.format}`}case"not_multiple_of":return`N\xFAmero inv\xE0lid: ha de ser m\xFAltiple de ${r.divisor}`;case"unrecognized_keys":return`Clau${r.keys.length>1?"s":""} no reconeguda${r.keys.length>1?"s":""}: ${S(r.keys,", ")}`;case"invalid_key":return`Clau inv\xE0lida a ${r.origin}`;case"invalid_union":return"Entrada inv\xE0lida";case"invalid_element":return`Element inv\xE0lid a ${r.origin}`;default:return"Entrada inv\xE0lida"}}};function jv(){return{localeError:wz()}}var kz=()=>{let e={string:{unit:"znak\u016F",verb:"m\xEDt"},file:{unit:"bajt\u016F",verb:"m\xEDt"},array:{unit:"prvk\u016F",verb:"m\xEDt"},set:{unit:"prvk\u016F",verb:"m\xEDt"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u010D\xEDslo";case"string":return"\u0159et\u011Bzec";case"boolean":return"boolean";case"bigint":return"bigint";case"function":return"funkce";case"symbol":return"symbol";case"undefined":return"undefined";case"object":{if(Array.isArray(r))return"pole";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"regul\xE1rn\xED v\xFDraz",email:"e-mailov\xE1 adresa",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"datum a \u010Das ve form\xE1tu ISO",date:"datum ve form\xE1tu ISO",time:"\u010Das ve form\xE1tu ISO",duration:"doba trv\xE1n\xED ISO",ipv4:"IPv4 adresa",ipv6:"IPv6 adresa",cidrv4:"rozsah IPv4",cidrv6:"rozsah IPv6",base64:"\u0159et\u011Bzec zak\xF3dovan\xFD ve form\xE1tu base64",base64url:"\u0159et\u011Bzec zak\xF3dovan\xFD ve form\xE1tu base64url",json_string:"\u0159et\u011Bzec ve form\xE1tu JSON",e164:"\u010D\xEDslo E.164",jwt:"JWT",template_literal:"vstup"};return r=>{switch(r.code){case"invalid_type":return`Neplatn\xFD vstup: o\u010Dek\xE1v\xE1no ${r.expected}, obdr\u017Eeno ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Neplatn\xFD vstup: o\u010Dek\xE1v\xE1no ${j(r.values[0])}`:`Neplatn\xE1 mo\u017Enost: o\u010Dek\xE1v\xE1na jedna z hodnot ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Hodnota je p\u0159\xEDli\u0161 velk\xE1: ${r.origin??"hodnota"} mus\xED m\xEDt ${i}${r.maximum.toString()} ${a.unit??"prvk\u016F"}`:`Hodnota je p\u0159\xEDli\u0161 velk\xE1: ${r.origin??"hodnota"} mus\xED b\xFDt ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Hodnota je p\u0159\xEDli\u0161 mal\xE1: ${r.origin??"hodnota"} mus\xED m\xEDt ${i}${r.minimum.toString()} ${a.unit??"prvk\u016F"}`:`Hodnota je p\u0159\xEDli\u0161 mal\xE1: ${r.origin??"hodnota"} mus\xED b\xFDt ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED za\u010D\xEDnat na "${i.prefix}"`:i.format==="ends_with"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED kon\u010Dit na "${i.suffix}"`:i.format==="includes"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED obsahovat "${i.includes}"`:i.format==="regex"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED odpov\xEDdat vzoru ${i.pattern}`:`Neplatn\xFD form\xE1t ${o[i.format]??r.format}`}case"not_multiple_of":return`Neplatn\xE9 \u010D\xEDslo: mus\xED b\xFDt n\xE1sobkem ${r.divisor}`;case"unrecognized_keys":return`Nezn\xE1m\xE9 kl\xED\u010De: ${S(r.keys,", ")}`;case"invalid_key":return`Neplatn\xFD kl\xED\u010D v ${r.origin}`;case"invalid_union":return"Neplatn\xFD vstup";case"invalid_element":return`Neplatn\xE1 hodnota v ${r.origin}`;default:return"Neplatn\xFD vstup"}}};function Nv(){return{localeError:kz()}}var Sz=()=>{let e={string:{unit:"tegn",verb:"havde"},file:{unit:"bytes",verb:"havde"},array:{unit:"elementer",verb:"indeholdt"},set:{unit:"elementer",verb:"indeholdt"}},t={string:"streng",number:"tal",boolean:"boolean",array:"liste",object:"objekt",set:"s\xE6t",file:"fil"};function n(a){return e[a]??null}function o(a){return t[a]??a}let r=a=>{let s=typeof a;switch(s){case"number":return Number.isNaN(a)?"NaN":"tal";case"object":return Array.isArray(a)?"liste":a===null?"null":Object.getPrototypeOf(a)!==Object.prototype&&a.constructor?a.constructor.name:"objekt"}return s},i={regex:"input",email:"e-mailadresse",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO dato- og klokkesl\xE6t",date:"ISO-dato",time:"ISO-klokkesl\xE6t",duration:"ISO-varighed",ipv4:"IPv4-omr\xE5de",ipv6:"IPv6-omr\xE5de",cidrv4:"IPv4-spektrum",cidrv6:"IPv6-spektrum",base64:"base64-kodet streng",base64url:"base64url-kodet streng",json_string:"JSON-streng",e164:"E.164-nummer",jwt:"JWT",template_literal:"input"};return a=>{switch(a.code){case"invalid_type":return`Ugyldigt input: forventede ${o(a.expected)}, fik ${o(r(a.input))}`;case"invalid_value":return a.values.length===1?`Ugyldig v\xE6rdi: forventede ${j(a.values[0])}`:`Ugyldigt valg: forventede en af f\xF8lgende ${S(a.values,"|")}`;case"too_big":{let s=a.inclusive?"<=":"<",c=n(a.origin),l=o(a.origin);return c?`For stor: forventede ${l??"value"} ${c.verb} ${s} ${a.maximum.toString()} ${c.unit??"elementer"}`:`For stor: forventede ${l??"value"} havde ${s} ${a.maximum.toString()}`}case"too_small":{let s=a.inclusive?">=":">",c=n(a.origin),l=o(a.origin);return c?`For lille: forventede ${l} ${c.verb} ${s} ${a.minimum.toString()} ${c.unit}`:`For lille: forventede ${l} havde ${s} ${a.minimum.toString()}`}case"invalid_format":{let s=a;return s.format==="starts_with"?`Ugyldig streng: skal starte med "${s.prefix}"`:s.format==="ends_with"?`Ugyldig streng: skal ende med "${s.suffix}"`:s.format==="includes"?`Ugyldig streng: skal indeholde "${s.includes}"`:s.format==="regex"?`Ugyldig streng: skal matche m\xF8nsteret ${s.pattern}`:`Ugyldig ${i[s.format]??a.format}`}case"not_multiple_of":return`Ugyldigt tal: skal v\xE6re deleligt med ${a.divisor}`;case"unrecognized_keys":return`${a.keys.length>1?"Ukendte n\xF8gler":"Ukendt n\xF8gle"}: ${S(a.keys,", ")}`;case"invalid_key":return`Ugyldig n\xF8gle i ${a.origin}`;case"invalid_union":return"Ugyldigt input: matcher ingen af de tilladte typer";case"invalid_element":return`Ugyldig v\xE6rdi i ${a.origin}`;default:return"Ugyldigt input"}}};function Rv(){return{localeError:Sz()}}var zz=()=>{let e={string:{unit:"Zeichen",verb:"zu haben"},file:{unit:"Bytes",verb:"zu haben"},array:{unit:"Elemente",verb:"zu haben"},set:{unit:"Elemente",verb:"zu haben"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"Zahl";case"object":{if(Array.isArray(r))return"Array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"Eingabe",email:"E-Mail-Adresse",url:"URL",emoji:"Emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-Datum und -Uhrzeit",date:"ISO-Datum",time:"ISO-Uhrzeit",duration:"ISO-Dauer",ipv4:"IPv4-Adresse",ipv6:"IPv6-Adresse",cidrv4:"IPv4-Bereich",cidrv6:"IPv6-Bereich",base64:"Base64-codierter String",base64url:"Base64-URL-codierter String",json_string:"JSON-String",e164:"E.164-Nummer",jwt:"JWT",template_literal:"Eingabe"};return r=>{switch(r.code){case"invalid_type":return`Ung\xFCltige Eingabe: erwartet ${r.expected}, erhalten ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Ung\xFCltige Eingabe: erwartet ${j(r.values[0])}`:`Ung\xFCltige Option: erwartet eine von ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Zu gro\xDF: erwartet, dass ${r.origin??"Wert"} ${i}${r.maximum.toString()} ${a.unit??"Elemente"} hat`:`Zu gro\xDF: erwartet, dass ${r.origin??"Wert"} ${i}${r.maximum.toString()} ist`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Zu klein: erwartet, dass ${r.origin} ${i}${r.minimum.toString()} ${a.unit} hat`:`Zu klein: erwartet, dass ${r.origin} ${i}${r.minimum.toString()} ist`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Ung\xFCltiger String: muss mit "${i.prefix}" beginnen`:i.format==="ends_with"?`Ung\xFCltiger String: muss mit "${i.suffix}" enden`:i.format==="includes"?`Ung\xFCltiger String: muss "${i.includes}" enthalten`:i.format==="regex"?`Ung\xFCltiger String: muss dem Muster ${i.pattern} entsprechen`:`Ung\xFCltig: ${o[i.format]??r.format}`}case"not_multiple_of":return`Ung\xFCltige Zahl: muss ein Vielfaches von ${r.divisor} sein`;case"unrecognized_keys":return`${r.keys.length>1?"Unbekannte Schl\xFCssel":"Unbekannter Schl\xFCssel"}: ${S(r.keys,", ")}`;case"invalid_key":return`Ung\xFCltiger Schl\xFCssel in ${r.origin}`;case"invalid_union":return"Ung\xFCltige Eingabe";case"invalid_element":return`Ung\xFCltiger Wert in ${r.origin}`;default:return"Ung\xFCltige Eingabe"}}};function Av(){return{localeError:zz()}}var Iz=e=>{let t=typeof e;switch(t){case"number":return Number.isNaN(e)?"NaN":"number";case"object":{if(Array.isArray(e))return"array";if(e===null)return"null";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return t},Ez=()=>{let e={string:{unit:"characters",verb:"to have"},file:{unit:"bytes",verb:"to have"},array:{unit:"items",verb:"to have"},set:{unit:"items",verb:"to have"}};function t(o){return e[o]??null}let n={regex:"input",email:"email address",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datetime",date:"ISO date",time:"ISO time",duration:"ISO duration",ipv4:"IPv4 address",ipv6:"IPv6 address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded string",base64url:"base64url-encoded string",json_string:"JSON string",e164:"E.164 number",jwt:"JWT",template_literal:"input"};return o=>{switch(o.code){case"invalid_type":return`Invalid input: expected ${o.expected}, received ${Iz(o.input)}`;case"invalid_value":return o.values.length===1?`Invalid input: expected ${j(o.values[0])}`:`Invalid option: expected one of ${S(o.values,"|")}`;case"too_big":{let r=o.inclusive?"<=":"<",i=t(o.origin);return i?`Too big: expected ${o.origin??"value"} to have ${r}${o.maximum.toString()} ${i.unit??"elements"}`:`Too big: expected ${o.origin??"value"} to be ${r}${o.maximum.toString()}`}case"too_small":{let r=o.inclusive?">=":">",i=t(o.origin);return i?`Too small: expected ${o.origin} to have ${r}${o.minimum.toString()} ${i.unit}`:`Too small: expected ${o.origin} to be ${r}${o.minimum.toString()}`}case"invalid_format":{let r=o;return r.format==="starts_with"?`Invalid string: must start with "${r.prefix}"`:r.format==="ends_with"?`Invalid string: must end with "${r.suffix}"`:r.format==="includes"?`Invalid string: must include "${r.includes}"`:r.format==="regex"?`Invalid string: must match pattern ${r.pattern}`:`Invalid ${n[r.format]??o.format}`}case"not_multiple_of":return`Invalid number: must be a multiple of ${o.divisor}`;case"unrecognized_keys":return`Unrecognized key${o.keys.length>1?"s":""}: ${S(o.keys,", ")}`;case"invalid_key":return`Invalid key in ${o.origin}`;case"invalid_union":return"Invalid input";case"invalid_element":return`Invalid value in ${o.origin}`;default:return"Invalid input"}}};function zc(){return{localeError:Ez()}}var Tz=e=>{let t=typeof e;switch(t){case"number":return Number.isNaN(e)?"NaN":"nombro";case"object":{if(Array.isArray(e))return"tabelo";if(e===null)return"senvalora";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return t},Pz=()=>{let e={string:{unit:"karaktrojn",verb:"havi"},file:{unit:"bajtojn",verb:"havi"},array:{unit:"elementojn",verb:"havi"},set:{unit:"elementojn",verb:"havi"}};function t(o){return e[o]??null}let n={regex:"enigo",email:"retadreso",url:"URL",emoji:"emo\u011Dio",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-datotempo",date:"ISO-dato",time:"ISO-tempo",duration:"ISO-da\u016Dro",ipv4:"IPv4-adreso",ipv6:"IPv6-adreso",cidrv4:"IPv4-rango",cidrv6:"IPv6-rango",base64:"64-ume kodita karaktraro",base64url:"URL-64-ume kodita karaktraro",json_string:"JSON-karaktraro",e164:"E.164-nombro",jwt:"JWT",template_literal:"enigo"};return o=>{switch(o.code){case"invalid_type":return`Nevalida enigo: atendi\u011Dis ${o.expected}, ricevi\u011Dis ${Tz(o.input)}`;case"invalid_value":return o.values.length===1?`Nevalida enigo: atendi\u011Dis ${j(o.values[0])}`:`Nevalida opcio: atendi\u011Dis unu el ${S(o.values,"|")}`;case"too_big":{let r=o.inclusive?"<=":"<",i=t(o.origin);return i?`Tro granda: atendi\u011Dis ke ${o.origin??"valoro"} havu ${r}${o.maximum.toString()} ${i.unit??"elementojn"}`:`Tro granda: atendi\u011Dis ke ${o.origin??"valoro"} havu ${r}${o.maximum.toString()}`}case"too_small":{let r=o.inclusive?">=":">",i=t(o.origin);return i?`Tro malgranda: atendi\u011Dis ke ${o.origin} havu ${r}${o.minimum.toString()} ${i.unit}`:`Tro malgranda: atendi\u011Dis ke ${o.origin} estu ${r}${o.minimum.toString()}`}case"invalid_format":{let r=o;return r.format==="starts_with"?`Nevalida karaktraro: devas komenci\u011Di per "${r.prefix}"`:r.format==="ends_with"?`Nevalida karaktraro: devas fini\u011Di per "${r.suffix}"`:r.format==="includes"?`Nevalida karaktraro: devas inkluzivi "${r.includes}"`:r.format==="regex"?`Nevalida karaktraro: devas kongrui kun la modelo ${r.pattern}`:`Nevalida ${n[r.format]??o.format}`}case"not_multiple_of":return`Nevalida nombro: devas esti oblo de ${o.divisor}`;case"unrecognized_keys":return`Nekonata${o.keys.length>1?"j":""} \u015Dlosilo${o.keys.length>1?"j":""}: ${S(o.keys,", ")}`;case"invalid_key":return`Nevalida \u015Dlosilo en ${o.origin}`;case"invalid_union":return"Nevalida enigo";case"invalid_element":return`Nevalida valoro en ${o.origin}`;default:return"Nevalida enigo"}}};function Dv(){return{localeError:Pz()}}var Oz=()=>{let e={string:{unit:"caracteres",verb:"tener"},file:{unit:"bytes",verb:"tener"},array:{unit:"elementos",verb:"tener"},set:{unit:"elementos",verb:"tener"}},t={string:"texto",number:"n\xFAmero",boolean:"booleano",array:"arreglo",object:"objeto",set:"conjunto",file:"archivo",date:"fecha",bigint:"n\xFAmero grande",symbol:"s\xEDmbolo",undefined:"indefinido",null:"nulo",function:"funci\xF3n",map:"mapa",record:"registro",tuple:"tupla",enum:"enumeraci\xF3n",union:"uni\xF3n",literal:"literal",promise:"promesa",void:"vac\xEDo",never:"nunca",unknown:"desconocido",any:"cualquiera"};function n(a){return e[a]??null}function o(a){return t[a]??a}let r=a=>{let s=typeof a;switch(s){case"number":return Number.isNaN(a)?"NaN":"number";case"object":return Array.isArray(a)?"array":a===null?"null":Object.getPrototypeOf(a)!==Object.prototype?a.constructor.name:"object"}return s},i={regex:"entrada",email:"direcci\xF3n de correo electr\xF3nico",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"fecha y hora ISO",date:"fecha ISO",time:"hora ISO",duration:"duraci\xF3n ISO",ipv4:"direcci\xF3n IPv4",ipv6:"direcci\xF3n IPv6",cidrv4:"rango IPv4",cidrv6:"rango IPv6",base64:"cadena codificada en base64",base64url:"URL codificada en base64",json_string:"cadena JSON",e164:"n\xFAmero E.164",jwt:"JWT",template_literal:"entrada"};return a=>{switch(a.code){case"invalid_type":return`Entrada inv\xE1lida: se esperaba ${o(a.expected)}, recibido ${o(r(a.input))}`;case"invalid_value":return a.values.length===1?`Entrada inv\xE1lida: se esperaba ${j(a.values[0])}`:`Opci\xF3n inv\xE1lida: se esperaba una de ${S(a.values,"|")}`;case"too_big":{let s=a.inclusive?"<=":"<",c=n(a.origin),l=o(a.origin);return c?`Demasiado grande: se esperaba que ${l??"valor"} tuviera ${s}${a.maximum.toString()} ${c.unit??"elementos"}`:`Demasiado grande: se esperaba que ${l??"valor"} fuera ${s}${a.maximum.toString()}`}case"too_small":{let s=a.inclusive?">=":">",c=n(a.origin),l=o(a.origin);return c?`Demasiado peque\xF1o: se esperaba que ${l} tuviera ${s}${a.minimum.toString()} ${c.unit}`:`Demasiado peque\xF1o: se esperaba que ${l} fuera ${s}${a.minimum.toString()}`}case"invalid_format":{let s=a;return s.format==="starts_with"?`Cadena inv\xE1lida: debe comenzar con "${s.prefix}"`:s.format==="ends_with"?`Cadena inv\xE1lida: debe terminar en "${s.suffix}"`:s.format==="includes"?`Cadena inv\xE1lida: debe incluir "${s.includes}"`:s.format==="regex"?`Cadena inv\xE1lida: debe coincidir con el patr\xF3n ${s.pattern}`:`Inv\xE1lido ${i[s.format]??a.format}`}case"not_multiple_of":return`N\xFAmero inv\xE1lido: debe ser m\xFAltiplo de ${a.divisor}`;case"unrecognized_keys":return`Llave${a.keys.length>1?"s":""} desconocida${a.keys.length>1?"s":""}: ${S(a.keys,", ")}`;case"invalid_key":return`Llave inv\xE1lida en ${o(a.origin)}`;case"invalid_union":return"Entrada inv\xE1lida";case"invalid_element":return`Valor inv\xE1lido en ${o(a.origin)}`;default:return"Entrada inv\xE1lida"}}};function Cv(){return{localeError:Oz()}}var jz=()=>{let e={string:{unit:"\u06A9\u0627\u0631\u0627\u06A9\u062A\u0631",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"},file:{unit:"\u0628\u0627\u06CC\u062A",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"},array:{unit:"\u0622\u06CC\u062A\u0645",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"},set:{unit:"\u0622\u06CC\u062A\u0645",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u0639\u062F\u062F";case"object":{if(Array.isArray(r))return"\u0622\u0631\u0627\u06CC\u0647";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0648\u0631\u0648\u062F\u06CC",email:"\u0622\u062F\u0631\u0633 \u0627\u06CC\u0645\u06CC\u0644",url:"URL",emoji:"\u0627\u06CC\u0645\u0648\u062C\u06CC",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u062A\u0627\u0631\u06CC\u062E \u0648 \u0632\u0645\u0627\u0646 \u0627\u06CC\u0632\u0648",date:"\u062A\u0627\u0631\u06CC\u062E \u0627\u06CC\u0632\u0648",time:"\u0632\u0645\u0627\u0646 \u0627\u06CC\u0632\u0648",duration:"\u0645\u062F\u062A \u0632\u0645\u0627\u0646 \u0627\u06CC\u0632\u0648",ipv4:"IPv4 \u0622\u062F\u0631\u0633",ipv6:"IPv6 \u0622\u062F\u0631\u0633",cidrv4:"IPv4 \u062F\u0627\u0645\u0646\u0647",cidrv6:"IPv6 \u062F\u0627\u0645\u0646\u0647",base64:"base64-encoded \u0631\u0634\u062A\u0647",base64url:"base64url-encoded \u0631\u0634\u062A\u0647",json_string:"JSON \u0631\u0634\u062A\u0647",e164:"E.164 \u0639\u062F\u062F",jwt:"JWT",template_literal:"\u0648\u0631\u0648\u062F\u06CC"};return r=>{switch(r.code){case"invalid_type":return`\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0645\u06CC\u200C\u0628\u0627\u06CC\u0633\u062A ${r.expected} \u0645\u06CC\u200C\u0628\u0648\u062F\u060C ${n(r.input)} \u062F\u0631\u06CC\u0627\u0641\u062A \u0634\u062F`;case"invalid_value":return r.values.length===1?`\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0645\u06CC\u200C\u0628\u0627\u06CC\u0633\u062A ${j(r.values[0])} \u0645\u06CC\u200C\u0628\u0648\u062F`:`\u06AF\u0632\u06CC\u0646\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0645\u06CC\u200C\u0628\u0627\u06CC\u0633\u062A \u06CC\u06A9\u06CC \u0627\u0632 ${S(r.values,"|")} \u0645\u06CC\u200C\u0628\u0648\u062F`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u062E\u06CC\u0644\u06CC \u0628\u0632\u0631\u06AF: ${r.origin??"\u0645\u0642\u062F\u0627\u0631"} \u0628\u0627\u06CC\u062F ${i}${r.maximum.toString()} ${a.unit??"\u0639\u0646\u0635\u0631"} \u0628\u0627\u0634\u062F`:`\u062E\u06CC\u0644\u06CC \u0628\u0632\u0631\u06AF: ${r.origin??"\u0645\u0642\u062F\u0627\u0631"} \u0628\u0627\u06CC\u062F ${i}${r.maximum.toString()} \u0628\u0627\u0634\u062F`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u062E\u06CC\u0644\u06CC \u06A9\u0648\u0686\u06A9: ${r.origin} \u0628\u0627\u06CC\u062F ${i}${r.minimum.toString()} ${a.unit} \u0628\u0627\u0634\u062F`:`\u062E\u06CC\u0644\u06CC \u06A9\u0648\u0686\u06A9: ${r.origin} \u0628\u0627\u06CC\u062F ${i}${r.minimum.toString()} \u0628\u0627\u0634\u062F`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0628\u0627 "${i.prefix}" \u0634\u0631\u0648\u0639 \u0634\u0648\u062F`:i.format==="ends_with"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0628\u0627 "${i.suffix}" \u062A\u0645\u0627\u0645 \u0634\u0648\u062F`:i.format==="includes"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0634\u0627\u0645\u0644 "${i.includes}" \u0628\u0627\u0634\u062F`:i.format==="regex"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0628\u0627 \u0627\u0644\u06AF\u0648\u06CC ${i.pattern} \u0645\u0637\u0627\u0628\u0642\u062A \u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F`:`${o[i.format]??r.format} \u0646\u0627\u0645\u0639\u062A\u0628\u0631`}case"not_multiple_of":return`\u0639\u062F\u062F \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0645\u0636\u0631\u0628 ${r.divisor} \u0628\u0627\u0634\u062F`;case"unrecognized_keys":return`\u06A9\u0644\u06CC\u062F${r.keys.length>1?"\u0647\u0627\u06CC":""} \u0646\u0627\u0634\u0646\u0627\u0633: ${S(r.keys,", ")}`;case"invalid_key":return`\u06A9\u0644\u06CC\u062F \u0646\u0627\u0634\u0646\u0627\u0633 \u062F\u0631 ${r.origin}`;case"invalid_union":return"\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631";case"invalid_element":return`\u0645\u0642\u062F\u0627\u0631 \u0646\u0627\u0645\u0639\u062A\u0628\u0631 \u062F\u0631 ${r.origin}`;default:return"\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631"}}};function Uv(){return{localeError:jz()}}var Nz=()=>{let e={string:{unit:"merkki\xE4",subject:"merkkijonon"},file:{unit:"tavua",subject:"tiedoston"},array:{unit:"alkiota",subject:"listan"},set:{unit:"alkiota",subject:"joukon"},number:{unit:"",subject:"luvun"},bigint:{unit:"",subject:"suuren kokonaisluvun"},int:{unit:"",subject:"kokonaisluvun"},date:{unit:"",subject:"p\xE4iv\xE4m\xE4\xE4r\xE4n"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"number";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"s\xE4\xE4nn\xF6llinen lauseke",email:"s\xE4hk\xF6postiosoite",url:"URL-osoite",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-aikaleima",date:"ISO-p\xE4iv\xE4m\xE4\xE4r\xE4",time:"ISO-aika",duration:"ISO-kesto",ipv4:"IPv4-osoite",ipv6:"IPv6-osoite",cidrv4:"IPv4-alue",cidrv6:"IPv6-alue",base64:"base64-koodattu merkkijono",base64url:"base64url-koodattu merkkijono",json_string:"JSON-merkkijono",e164:"E.164-luku",jwt:"JWT",template_literal:"templaattimerkkijono"};return r=>{switch(r.code){case"invalid_type":return`Virheellinen tyyppi: odotettiin ${r.expected}, oli ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Virheellinen sy\xF6te: t\xE4ytyy olla ${j(r.values[0])}`:`Virheellinen valinta: t\xE4ytyy olla yksi seuraavista: ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Liian suuri: ${a.subject} t\xE4ytyy olla ${i}${r.maximum.toString()} ${a.unit}`.trim():`Liian suuri: arvon t\xE4ytyy olla ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Liian pieni: ${a.subject} t\xE4ytyy olla ${i}${r.minimum.toString()} ${a.unit}`.trim():`Liian pieni: arvon t\xE4ytyy olla ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Virheellinen sy\xF6te: t\xE4ytyy alkaa "${i.prefix}"`:i.format==="ends_with"?`Virheellinen sy\xF6te: t\xE4ytyy loppua "${i.suffix}"`:i.format==="includes"?`Virheellinen sy\xF6te: t\xE4ytyy sis\xE4lt\xE4\xE4 "${i.includes}"`:i.format==="regex"?`Virheellinen sy\xF6te: t\xE4ytyy vastata s\xE4\xE4nn\xF6llist\xE4 lauseketta ${i.pattern}`:`Virheellinen ${o[i.format]??r.format}`}case"not_multiple_of":return`Virheellinen luku: t\xE4ytyy olla luvun ${r.divisor} monikerta`;case"unrecognized_keys":return`${r.keys.length>1?"Tuntemattomat avaimet":"Tuntematon avain"}: ${S(r.keys,", ")}`;case"invalid_key":return"Virheellinen avain tietueessa";case"invalid_union":return"Virheellinen unioni";case"invalid_element":return"Virheellinen arvo joukossa";default:return"Virheellinen sy\xF6te"}}};function Zv(){return{localeError:Nz()}}var Rz=()=>{let e={string:{unit:"caract\xE8res",verb:"avoir"},file:{unit:"octets",verb:"avoir"},array:{unit:"\xE9l\xE9ments",verb:"avoir"},set:{unit:"\xE9l\xE9ments",verb:"avoir"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"nombre";case"object":{if(Array.isArray(r))return"tableau";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"entr\xE9e",email:"adresse e-mail",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"date et heure ISO",date:"date ISO",time:"heure ISO",duration:"dur\xE9e ISO",ipv4:"adresse IPv4",ipv6:"adresse IPv6",cidrv4:"plage IPv4",cidrv6:"plage IPv6",base64:"cha\xEEne encod\xE9e en base64",base64url:"cha\xEEne encod\xE9e en base64url",json_string:"cha\xEEne JSON",e164:"num\xE9ro E.164",jwt:"JWT",template_literal:"entr\xE9e"};return r=>{switch(r.code){case"invalid_type":return`Entr\xE9e invalide : ${r.expected} attendu, ${n(r.input)} re\xE7u`;case"invalid_value":return r.values.length===1?`Entr\xE9e invalide : ${j(r.values[0])} attendu`:`Option invalide : une valeur parmi ${S(r.values,"|")} attendue`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Trop grand : ${r.origin??"valeur"} doit ${a.verb} ${i}${r.maximum.toString()} ${a.unit??"\xE9l\xE9ment(s)"}`:`Trop grand : ${r.origin??"valeur"} doit \xEAtre ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Trop petit : ${r.origin} doit ${a.verb} ${i}${r.minimum.toString()} ${a.unit}`:`Trop petit : ${r.origin} doit \xEAtre ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Cha\xEEne invalide : doit commencer par "${i.prefix}"`:i.format==="ends_with"?`Cha\xEEne invalide : doit se terminer par "${i.suffix}"`:i.format==="includes"?`Cha\xEEne invalide : doit inclure "${i.includes}"`:i.format==="regex"?`Cha\xEEne invalide : doit correspondre au mod\xE8le ${i.pattern}`:`${o[i.format]??r.format} invalide`}case"not_multiple_of":return`Nombre invalide : doit \xEAtre un multiple de ${r.divisor}`;case"unrecognized_keys":return`Cl\xE9${r.keys.length>1?"s":""} non reconnue${r.keys.length>1?"s":""} : ${S(r.keys,", ")}`;case"invalid_key":return`Cl\xE9 invalide dans ${r.origin}`;case"invalid_union":return"Entr\xE9e invalide";case"invalid_element":return`Valeur invalide dans ${r.origin}`;default:return"Entr\xE9e invalide"}}};function Mv(){return{localeError:Rz()}}var Az=()=>{let e={string:{unit:"caract\xE8res",verb:"avoir"},file:{unit:"octets",verb:"avoir"},array:{unit:"\xE9l\xE9ments",verb:"avoir"},set:{unit:"\xE9l\xE9ments",verb:"avoir"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"number";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"entr\xE9e",email:"adresse courriel",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"date-heure ISO",date:"date ISO",time:"heure ISO",duration:"dur\xE9e ISO",ipv4:"adresse IPv4",ipv6:"adresse IPv6",cidrv4:"plage IPv4",cidrv6:"plage IPv6",base64:"cha\xEEne encod\xE9e en base64",base64url:"cha\xEEne encod\xE9e en base64url",json_string:"cha\xEEne JSON",e164:"num\xE9ro E.164",jwt:"JWT",template_literal:"entr\xE9e"};return r=>{switch(r.code){case"invalid_type":return`Entr\xE9e invalide : attendu ${r.expected}, re\xE7u ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Entr\xE9e invalide : attendu ${j(r.values[0])}`:`Option invalide : attendu l'une des valeurs suivantes ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"\u2264":"<",a=t(r.origin);return a?`Trop grand : attendu que ${r.origin??"la valeur"} ait ${i}${r.maximum.toString()} ${a.unit}`:`Trop grand : attendu que ${r.origin??"la valeur"} soit ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?"\u2265":">",a=t(r.origin);return a?`Trop petit : attendu que ${r.origin} ait ${i}${r.minimum.toString()} ${a.unit}`:`Trop petit : attendu que ${r.origin} soit ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Cha\xEEne invalide : doit commencer par "${i.prefix}"`:i.format==="ends_with"?`Cha\xEEne invalide : doit se terminer par "${i.suffix}"`:i.format==="includes"?`Cha\xEEne invalide : doit inclure "${i.includes}"`:i.format==="regex"?`Cha\xEEne invalide : doit correspondre au motif ${i.pattern}`:`${o[i.format]??r.format} invalide`}case"not_multiple_of":return`Nombre invalide : doit \xEAtre un multiple de ${r.divisor}`;case"unrecognized_keys":return`Cl\xE9${r.keys.length>1?"s":""} non reconnue${r.keys.length>1?"s":""} : ${S(r.keys,", ")}`;case"invalid_key":return`Cl\xE9 invalide dans ${r.origin}`;case"invalid_union":return"Entr\xE9e invalide";case"invalid_element":return`Valeur invalide dans ${r.origin}`;default:return"Entr\xE9e invalide"}}};function Lv(){return{localeError:Az()}}var Dz=()=>{let e={string:{unit:"\u05D0\u05D5\u05EA\u05D9\u05D5\u05EA",verb:"\u05DC\u05DB\u05DC\u05D5\u05DC"},file:{unit:"\u05D1\u05D9\u05D9\u05D8\u05D9\u05DD",verb:"\u05DC\u05DB\u05DC\u05D5\u05DC"},array:{unit:"\u05E4\u05E8\u05D9\u05D8\u05D9\u05DD",verb:"\u05DC\u05DB\u05DC\u05D5\u05DC"},set:{unit:"\u05E4\u05E8\u05D9\u05D8\u05D9\u05DD",verb:"\u05DC\u05DB\u05DC\u05D5\u05DC"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"number";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u05E7\u05DC\u05D8",email:"\u05DB\u05EA\u05D5\u05D1\u05EA \u05D0\u05D9\u05DE\u05D9\u05D9\u05DC",url:"\u05DB\u05EA\u05D5\u05D1\u05EA \u05E8\u05E9\u05EA",emoji:"\u05D0\u05D9\u05DE\u05D5\u05D2'\u05D9",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u05EA\u05D0\u05E8\u05D9\u05DA \u05D5\u05D6\u05DE\u05DF ISO",date:"\u05EA\u05D0\u05E8\u05D9\u05DA ISO",time:"\u05D6\u05DE\u05DF ISO",duration:"\u05DE\u05E9\u05DA \u05D6\u05DE\u05DF ISO",ipv4:"\u05DB\u05EA\u05D5\u05D1\u05EA IPv4",ipv6:"\u05DB\u05EA\u05D5\u05D1\u05EA IPv6",cidrv4:"\u05D8\u05D5\u05D5\u05D7 IPv4",cidrv6:"\u05D8\u05D5\u05D5\u05D7 IPv6",base64:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D1\u05D1\u05E1\u05D9\u05E1 64",base64url:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D1\u05D1\u05E1\u05D9\u05E1 64 \u05DC\u05DB\u05EA\u05D5\u05D1\u05D5\u05EA \u05E8\u05E9\u05EA",json_string:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA JSON",e164:"\u05DE\u05E1\u05E4\u05E8 E.164",jwt:"JWT",template_literal:"\u05E7\u05DC\u05D8"};return r=>{switch(r.code){case"invalid_type":return`\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05E6\u05E8\u05D9\u05DA ${r.expected}, \u05D4\u05EA\u05E7\u05D1\u05DC ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05E6\u05E8\u05D9\u05DA ${j(r.values[0])}`:`\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05E6\u05E8\u05D9\u05DA \u05D0\u05D7\u05EA \u05DE\u05D4\u05D0\u05E4\u05E9\u05E8\u05D5\u05D9\u05D5\u05EA ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u05D2\u05D3\u05D5\u05DC \u05DE\u05D3\u05D9: ${r.origin??"value"} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${i}${r.maximum.toString()} ${a.unit??"elements"}`:`\u05D2\u05D3\u05D5\u05DC \u05DE\u05D3\u05D9: ${r.origin??"value"} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u05E7\u05D8\u05DF \u05DE\u05D3\u05D9: ${r.origin} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${i}${r.minimum.toString()} ${a.unit}`:`\u05E7\u05D8\u05DF \u05DE\u05D3\u05D9: ${r.origin} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05E0\u05D4: \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05EA\u05D7\u05D9\u05DC \u05D1"${i.prefix}"`:i.format==="ends_with"?`\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05E0\u05D4: \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05E1\u05EA\u05D9\u05D9\u05DD \u05D1 "${i.suffix}"`:i.format==="includes"?`\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05E0\u05D4: \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05DB\u05DC\u05D5\u05DC "${i.includes}"`:i.format==="regex"?`\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05E0\u05D4: \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05EA\u05D0\u05D9\u05DD \u05DC\u05EA\u05D1\u05E0\u05D9\u05EA ${i.pattern}`:`${o[i.format]??r.format} \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF`}case"not_multiple_of":return`\u05DE\u05E1\u05E4\u05E8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05D7\u05D9\u05D9\u05D1 \u05DC\u05D4\u05D9\u05D5\u05EA \u05DE\u05DB\u05E4\u05DC\u05D4 \u05E9\u05DC ${r.divisor}`;case"unrecognized_keys":return`\u05DE\u05E4\u05EA\u05D7${r.keys.length>1?"\u05D5\u05EA":""} \u05DC\u05D0 \u05DE\u05D6\u05D5\u05D4${r.keys.length>1?"\u05D9\u05DD":"\u05D4"}: ${S(r.keys,", ")}`;case"invalid_key":return`\u05DE\u05E4\u05EA\u05D7 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF \u05D1${r.origin}`;case"invalid_union":return"\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF";case"invalid_element":return`\u05E2\u05E8\u05DA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF \u05D1${r.origin}`;default:return"\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF"}}};function qv(){return{localeError:Dz()}}var Cz=()=>{let e={string:{unit:"karakter",verb:"legyen"},file:{unit:"byte",verb:"legyen"},array:{unit:"elem",verb:"legyen"},set:{unit:"elem",verb:"legyen"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"sz\xE1m";case"object":{if(Array.isArray(r))return"t\xF6mb";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"bemenet",email:"email c\xEDm",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO id\u0151b\xE9lyeg",date:"ISO d\xE1tum",time:"ISO id\u0151",duration:"ISO id\u0151intervallum",ipv4:"IPv4 c\xEDm",ipv6:"IPv6 c\xEDm",cidrv4:"IPv4 tartom\xE1ny",cidrv6:"IPv6 tartom\xE1ny",base64:"base64-k\xF3dolt string",base64url:"base64url-k\xF3dolt string",json_string:"JSON string",e164:"E.164 sz\xE1m",jwt:"JWT",template_literal:"bemenet"};return r=>{switch(r.code){case"invalid_type":return`\xC9rv\xE9nytelen bemenet: a v\xE1rt \xE9rt\xE9k ${r.expected}, a kapott \xE9rt\xE9k ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\xC9rv\xE9nytelen bemenet: a v\xE1rt \xE9rt\xE9k ${j(r.values[0])}`:`\xC9rv\xE9nytelen opci\xF3: valamelyik \xE9rt\xE9k v\xE1rt ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`T\xFAl nagy: ${r.origin??"\xE9rt\xE9k"} m\xE9rete t\xFAl nagy ${i}${r.maximum.toString()} ${a.unit??"elem"}`:`T\xFAl nagy: a bemeneti \xE9rt\xE9k ${r.origin??"\xE9rt\xE9k"} t\xFAl nagy: ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`T\xFAl kicsi: a bemeneti \xE9rt\xE9k ${r.origin} m\xE9rete t\xFAl kicsi ${i}${r.minimum.toString()} ${a.unit}`:`T\xFAl kicsi: a bemeneti \xE9rt\xE9k ${r.origin} t\xFAl kicsi ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\xC9rv\xE9nytelen string: "${i.prefix}" \xE9rt\xE9kkel kell kezd\u0151dnie`:i.format==="ends_with"?`\xC9rv\xE9nytelen string: "${i.suffix}" \xE9rt\xE9kkel kell v\xE9gz\u0151dnie`:i.format==="includes"?`\xC9rv\xE9nytelen string: "${i.includes}" \xE9rt\xE9ket kell tartalmaznia`:i.format==="regex"?`\xC9rv\xE9nytelen string: ${i.pattern} mint\xE1nak kell megfelelnie`:`\xC9rv\xE9nytelen ${o[i.format]??r.format}`}case"not_multiple_of":return`\xC9rv\xE9nytelen sz\xE1m: ${r.divisor} t\xF6bbsz\xF6r\xF6s\xE9nek kell lennie`;case"unrecognized_keys":return`Ismeretlen kulcs${r.keys.length>1?"s":""}: ${S(r.keys,", ")}`;case"invalid_key":return`\xC9rv\xE9nytelen kulcs ${r.origin}`;case"invalid_union":return"\xC9rv\xE9nytelen bemenet";case"invalid_element":return`\xC9rv\xE9nytelen \xE9rt\xE9k: ${r.origin}`;default:return"\xC9rv\xE9nytelen bemenet"}}};function Vv(){return{localeError:Cz()}}var Uz=()=>{let e={string:{unit:"karakter",verb:"memiliki"},file:{unit:"byte",verb:"memiliki"},array:{unit:"item",verb:"memiliki"},set:{unit:"item",verb:"memiliki"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"number";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"input",email:"alamat email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"tanggal dan waktu format ISO",date:"tanggal format ISO",time:"jam format ISO",duration:"durasi format ISO",ipv4:"alamat IPv4",ipv6:"alamat IPv6",cidrv4:"rentang alamat IPv4",cidrv6:"rentang alamat IPv6",base64:"string dengan enkode base64",base64url:"string dengan enkode base64url",json_string:"string JSON",e164:"angka E.164",jwt:"JWT",template_literal:"input"};return r=>{switch(r.code){case"invalid_type":return`Input tidak valid: diharapkan ${r.expected}, diterima ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Input tidak valid: diharapkan ${j(r.values[0])}`:`Pilihan tidak valid: diharapkan salah satu dari ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Terlalu besar: diharapkan ${r.origin??"value"} memiliki ${i}${r.maximum.toString()} ${a.unit??"elemen"}`:`Terlalu besar: diharapkan ${r.origin??"value"} menjadi ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Terlalu kecil: diharapkan ${r.origin} memiliki ${i}${r.minimum.toString()} ${a.unit}`:`Terlalu kecil: diharapkan ${r.origin} menjadi ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`String tidak valid: harus dimulai dengan "${i.prefix}"`:i.format==="ends_with"?`String tidak valid: harus berakhir dengan "${i.suffix}"`:i.format==="includes"?`String tidak valid: harus menyertakan "${i.includes}"`:i.format==="regex"?`String tidak valid: harus sesuai pola ${i.pattern}`:`${o[i.format]??r.format} tidak valid`}case"not_multiple_of":return`Angka tidak valid: harus kelipatan dari ${r.divisor}`;case"unrecognized_keys":return`Kunci tidak dikenali ${r.keys.length>1?"s":""}: ${S(r.keys,", ")}`;case"invalid_key":return`Kunci tidak valid di ${r.origin}`;case"invalid_union":return"Input tidak valid";case"invalid_element":return`Nilai tidak valid di ${r.origin}`;default:return"Input tidak valid"}}};function Fv(){return{localeError:Uz()}}var Zz=e=>{let t=typeof e;switch(t){case"number":return Number.isNaN(e)?"NaN":"n\xFAmer";case"object":{if(Array.isArray(e))return"fylki";if(e===null)return"null";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return t},Mz=()=>{let e={string:{unit:"stafi",verb:"a\xF0 hafa"},file:{unit:"b\xE6ti",verb:"a\xF0 hafa"},array:{unit:"hluti",verb:"a\xF0 hafa"},set:{unit:"hluti",verb:"a\xF0 hafa"}};function t(o){return e[o]??null}let n={regex:"gildi",email:"netfang",url:"vefsl\xF3\xF0",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO dagsetning og t\xEDmi",date:"ISO dagsetning",time:"ISO t\xEDmi",duration:"ISO t\xEDmalengd",ipv4:"IPv4 address",ipv6:"IPv6 address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded strengur",base64url:"base64url-encoded strengur",json_string:"JSON strengur",e164:"E.164 t\xF6lugildi",jwt:"JWT",template_literal:"gildi"};return o=>{switch(o.code){case"invalid_type":return`Rangt gildi: \xDE\xFA sl\xF3st inn ${Zz(o.input)} \xFEar sem \xE1 a\xF0 vera ${o.expected}`;case"invalid_value":return o.values.length===1?`Rangt gildi: gert r\xE1\xF0 fyrir ${j(o.values[0])}`:`\xD3gilt val: m\xE1 vera eitt af eftirfarandi ${S(o.values,"|")}`;case"too_big":{let r=o.inclusive?"<=":"<",i=t(o.origin);return i?`Of st\xF3rt: gert er r\xE1\xF0 fyrir a\xF0 ${o.origin??"gildi"} hafi ${r}${o.maximum.toString()} ${i.unit??"hluti"}`:`Of st\xF3rt: gert er r\xE1\xF0 fyrir a\xF0 ${o.origin??"gildi"} s\xE9 ${r}${o.maximum.toString()}`}case"too_small":{let r=o.inclusive?">=":">",i=t(o.origin);return i?`Of l\xEDti\xF0: gert er r\xE1\xF0 fyrir a\xF0 ${o.origin} hafi ${r}${o.minimum.toString()} ${i.unit}`:`Of l\xEDti\xF0: gert er r\xE1\xF0 fyrir a\xF0 ${o.origin} s\xE9 ${r}${o.minimum.toString()}`}case"invalid_format":{let r=o;return r.format==="starts_with"?`\xD3gildur strengur: ver\xF0ur a\xF0 byrja \xE1 "${r.prefix}"`:r.format==="ends_with"?`\xD3gildur strengur: ver\xF0ur a\xF0 enda \xE1 "${r.suffix}"`:r.format==="includes"?`\xD3gildur strengur: ver\xF0ur a\xF0 innihalda "${r.includes}"`:r.format==="regex"?`\xD3gildur strengur: ver\xF0ur a\xF0 fylgja mynstri ${r.pattern}`:`Rangt ${n[r.format]??o.format}`}case"not_multiple_of":return`R\xF6ng tala: ver\xF0ur a\xF0 vera margfeldi af ${o.divisor}`;case"unrecognized_keys":return`\xD3\xFEekkt ${o.keys.length>1?"ir lyklar":"ur lykill"}: ${S(o.keys,", ")}`;case"invalid_key":return`Rangur lykill \xED ${o.origin}`;case"invalid_union":return"Rangt gildi";case"invalid_element":return`Rangt gildi \xED ${o.origin}`;default:return"Rangt gildi"}}};function Bv(){return{localeError:Mz()}}var Lz=()=>{let e={string:{unit:"caratteri",verb:"avere"},file:{unit:"byte",verb:"avere"},array:{unit:"elementi",verb:"avere"},set:{unit:"elementi",verb:"avere"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"numero";case"object":{if(Array.isArray(r))return"vettore";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"input",email:"indirizzo email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data e ora ISO",date:"data ISO",time:"ora ISO",duration:"durata ISO",ipv4:"indirizzo IPv4",ipv6:"indirizzo IPv6",cidrv4:"intervallo IPv4",cidrv6:"intervallo IPv6",base64:"stringa codificata in base64",base64url:"URL codificata in base64",json_string:"stringa JSON",e164:"numero E.164",jwt:"JWT",template_literal:"input"};return r=>{switch(r.code){case"invalid_type":return`Input non valido: atteso ${r.expected}, ricevuto ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Input non valido: atteso ${j(r.values[0])}`:`Opzione non valida: atteso uno tra ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Troppo grande: ${r.origin??"valore"} deve avere ${i}${r.maximum.toString()} ${a.unit??"elementi"}`:`Troppo grande: ${r.origin??"valore"} deve essere ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Troppo piccolo: ${r.origin} deve avere ${i}${r.minimum.toString()} ${a.unit}`:`Troppo piccolo: ${r.origin} deve essere ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Stringa non valida: deve iniziare con "${i.prefix}"`:i.format==="ends_with"?`Stringa non valida: deve terminare con "${i.suffix}"`:i.format==="includes"?`Stringa non valida: deve includere "${i.includes}"`:i.format==="regex"?`Stringa non valida: deve corrispondere al pattern ${i.pattern}`:`Invalid ${o[i.format]??r.format}`}case"not_multiple_of":return`Numero non valido: deve essere un multiplo di ${r.divisor}`;case"unrecognized_keys":return`Chiav${r.keys.length>1?"i":"e"} non riconosciut${r.keys.length>1?"e":"a"}: ${S(r.keys,", ")}`;case"invalid_key":return`Chiave non valida in ${r.origin}`;case"invalid_union":return"Input non valido";case"invalid_element":return`Valore non valido in ${r.origin}`;default:return"Input non valido"}}};function Kv(){return{localeError:Lz()}}var qz=()=>{let e={string:{unit:"\u6587\u5B57",verb:"\u3067\u3042\u308B"},file:{unit:"\u30D0\u30A4\u30C8",verb:"\u3067\u3042\u308B"},array:{unit:"\u8981\u7D20",verb:"\u3067\u3042\u308B"},set:{unit:"\u8981\u7D20",verb:"\u3067\u3042\u308B"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u6570\u5024";case"object":{if(Array.isArray(r))return"\u914D\u5217";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u5165\u529B\u5024",email:"\u30E1\u30FC\u30EB\u30A2\u30C9\u30EC\u30B9",url:"URL",emoji:"\u7D75\u6587\u5B57",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO\u65E5\u6642",date:"ISO\u65E5\u4ED8",time:"ISO\u6642\u523B",duration:"ISO\u671F\u9593",ipv4:"IPv4\u30A2\u30C9\u30EC\u30B9",ipv6:"IPv6\u30A2\u30C9\u30EC\u30B9",cidrv4:"IPv4\u7BC4\u56F2",cidrv6:"IPv6\u7BC4\u56F2",base64:"base64\u30A8\u30F3\u30B3\u30FC\u30C9\u6587\u5B57\u5217",base64url:"base64url\u30A8\u30F3\u30B3\u30FC\u30C9\u6587\u5B57\u5217",json_string:"JSON\u6587\u5B57\u5217",e164:"E.164\u756A\u53F7",jwt:"JWT",template_literal:"\u5165\u529B\u5024"};return r=>{switch(r.code){case"invalid_type":return`\u7121\u52B9\u306A\u5165\u529B: ${r.expected}\u304C\u671F\u5F85\u3055\u308C\u307E\u3057\u305F\u304C\u3001${n(r.input)}\u304C\u5165\u529B\u3055\u308C\u307E\u3057\u305F`;case"invalid_value":return r.values.length===1?`\u7121\u52B9\u306A\u5165\u529B: ${j(r.values[0])}\u304C\u671F\u5F85\u3055\u308C\u307E\u3057\u305F`:`\u7121\u52B9\u306A\u9078\u629E: ${S(r.values,"\u3001")}\u306E\u3044\u305A\u308C\u304B\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`;case"too_big":{let i=r.inclusive?"\u4EE5\u4E0B\u3067\u3042\u308B":"\u3088\u308A\u5C0F\u3055\u3044",a=t(r.origin);return a?`\u5927\u304D\u3059\u304E\u308B\u5024: ${r.origin??"\u5024"}\u306F${r.maximum.toString()}${a.unit??"\u8981\u7D20"}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:`\u5927\u304D\u3059\u304E\u308B\u5024: ${r.origin??"\u5024"}\u306F${r.maximum.toString()}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`}case"too_small":{let i=r.inclusive?"\u4EE5\u4E0A\u3067\u3042\u308B":"\u3088\u308A\u5927\u304D\u3044",a=t(r.origin);return a?`\u5C0F\u3055\u3059\u304E\u308B\u5024: ${r.origin}\u306F${r.minimum.toString()}${a.unit}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:`\u5C0F\u3055\u3059\u304E\u308B\u5024: ${r.origin}\u306F${r.minimum.toString()}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: "${i.prefix}"\u3067\u59CB\u307E\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:i.format==="ends_with"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: "${i.suffix}"\u3067\u7D42\u308F\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:i.format==="includes"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: "${i.includes}"\u3092\u542B\u3080\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:i.format==="regex"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: \u30D1\u30BF\u30FC\u30F3${i.pattern}\u306B\u4E00\u81F4\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:`\u7121\u52B9\u306A${o[i.format]??r.format}`}case"not_multiple_of":return`\u7121\u52B9\u306A\u6570\u5024: ${r.divisor}\u306E\u500D\u6570\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`;case"unrecognized_keys":return`\u8A8D\u8B58\u3055\u308C\u3066\u3044\u306A\u3044\u30AD\u30FC${r.keys.length>1?"\u7FA4":""}: ${S(r.keys,"\u3001")}`;case"invalid_key":return`${r.origin}\u5185\u306E\u7121\u52B9\u306A\u30AD\u30FC`;case"invalid_union":return"\u7121\u52B9\u306A\u5165\u529B";case"invalid_element":return`${r.origin}\u5185\u306E\u7121\u52B9\u306A\u5024`;default:return"\u7121\u52B9\u306A\u5165\u529B"}}};function Hv(){return{localeError:qz()}}var Vz=e=>{let t=typeof e;switch(t){case"number":return Number.isNaN(e)?"NaN":"\u10E0\u10D8\u10EA\u10EE\u10D5\u10D8";case"object":{if(Array.isArray(e))return"\u10DB\u10D0\u10E1\u10D8\u10D5\u10D8";if(e===null)return"null";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return{string:"\u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8",boolean:"\u10D1\u10E3\u10DA\u10D4\u10D0\u10DC\u10D8",undefined:"undefined",bigint:"bigint",symbol:"symbol",function:"\u10E4\u10E3\u10DC\u10E5\u10EA\u10D8\u10D0"}[t]??t},Fz=()=>{let e={string:{unit:"\u10E1\u10D8\u10DB\u10D1\u10DD\u10DA\u10DD",verb:"\u10E3\u10DC\u10D3\u10D0 \u10E8\u10D4\u10D8\u10EA\u10D0\u10D5\u10D3\u10D4\u10E1"},file:{unit:"\u10D1\u10D0\u10D8\u10E2\u10D8",verb:"\u10E3\u10DC\u10D3\u10D0 \u10E8\u10D4\u10D8\u10EA\u10D0\u10D5\u10D3\u10D4\u10E1"},array:{unit:"\u10D4\u10DA\u10D4\u10DB\u10D4\u10DC\u10E2\u10D8",verb:"\u10E3\u10DC\u10D3\u10D0 \u10E8\u10D4\u10D8\u10EA\u10D0\u10D5\u10D3\u10D4\u10E1"},set:{unit:"\u10D4\u10DA\u10D4\u10DB\u10D4\u10DC\u10E2\u10D8",verb:"\u10E3\u10DC\u10D3\u10D0 \u10E8\u10D4\u10D8\u10EA\u10D0\u10D5\u10D3\u10D4\u10E1"}};function t(o){return e[o]??null}let n={regex:"\u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0",email:"\u10D4\u10DA-\u10E4\u10DD\u10E1\u10E2\u10D8\u10E1 \u10DB\u10D8\u10E1\u10D0\u10DB\u10D0\u10E0\u10D7\u10D8",url:"URL",emoji:"\u10D4\u10DB\u10DD\u10EF\u10D8",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u10D7\u10D0\u10E0\u10D8\u10E6\u10D8-\u10D3\u10E0\u10DD",date:"\u10D7\u10D0\u10E0\u10D8\u10E6\u10D8",time:"\u10D3\u10E0\u10DD",duration:"\u10EE\u10D0\u10DC\u10D2\u10E0\u10EB\u10DA\u10D8\u10D5\u10DD\u10D1\u10D0",ipv4:"IPv4 \u10DB\u10D8\u10E1\u10D0\u10DB\u10D0\u10E0\u10D7\u10D8",ipv6:"IPv6 \u10DB\u10D8\u10E1\u10D0\u10DB\u10D0\u10E0\u10D7\u10D8",cidrv4:"IPv4 \u10D3\u10D8\u10D0\u10DE\u10D0\u10D6\u10DD\u10DC\u10D8",cidrv6:"IPv6 \u10D3\u10D8\u10D0\u10DE\u10D0\u10D6\u10DD\u10DC\u10D8",base64:"base64-\u10D9\u10DD\u10D3\u10D8\u10E0\u10D4\u10D1\u10E3\u10DA\u10D8 \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8",base64url:"base64url-\u10D9\u10DD\u10D3\u10D8\u10E0\u10D4\u10D1\u10E3\u10DA\u10D8 \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8",json_string:"JSON \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8",e164:"E.164 \u10DC\u10DD\u10DB\u10D4\u10E0\u10D8",jwt:"JWT",template_literal:"\u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0"};return o=>{switch(o.code){case"invalid_type":return`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${o.expected}, \u10DB\u10D8\u10E6\u10D4\u10D1\u10E3\u10DA\u10D8 ${Vz(o.input)}`;case"invalid_value":return o.values.length===1?`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${j(o.values[0])}`:`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10D5\u10D0\u10E0\u10D8\u10D0\u10DC\u10E2\u10D8: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8\u10D0 \u10D4\u10E0\u10D7-\u10D4\u10E0\u10D7\u10D8 ${S(o.values,"|")}-\u10D3\u10D0\u10DC`;case"too_big":{let r=o.inclusive?"<=":"<",i=t(o.origin);return i?`\u10D6\u10D4\u10D3\u10DB\u10D4\u10E2\u10D0\u10D3 \u10D3\u10D8\u10D3\u10D8: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${o.origin??"\u10DB\u10DC\u10D8\u10E8\u10D5\u10DC\u10D4\u10DA\u10DD\u10D1\u10D0"} ${i.verb} ${r}${o.maximum.toString()} ${i.unit}`:`\u10D6\u10D4\u10D3\u10DB\u10D4\u10E2\u10D0\u10D3 \u10D3\u10D8\u10D3\u10D8: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${o.origin??"\u10DB\u10DC\u10D8\u10E8\u10D5\u10DC\u10D4\u10DA\u10DD\u10D1\u10D0"} \u10D8\u10E7\u10DD\u10E1 ${r}${o.maximum.toString()}`}case"too_small":{let r=o.inclusive?">=":">",i=t(o.origin);return i?`\u10D6\u10D4\u10D3\u10DB\u10D4\u10E2\u10D0\u10D3 \u10DE\u10D0\u10E2\u10D0\u10E0\u10D0: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${o.origin} ${i.verb} ${r}${o.minimum.toString()} ${i.unit}`:`\u10D6\u10D4\u10D3\u10DB\u10D4\u10E2\u10D0\u10D3 \u10DE\u10D0\u10E2\u10D0\u10E0\u10D0: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${o.origin} \u10D8\u10E7\u10DD\u10E1 ${r}${o.minimum.toString()}`}case"invalid_format":{let r=o;return r.format==="starts_with"?`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8: \u10E3\u10DC\u10D3\u10D0 \u10D8\u10EC\u10E7\u10D4\u10D1\u10DD\u10D3\u10D4\u10E1 "${r.prefix}"-\u10D8\u10D7`:r.format==="ends_with"?`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8: \u10E3\u10DC\u10D3\u10D0 \u10DB\u10D7\u10D0\u10D5\u10E0\u10D3\u10D4\u10D1\u10DD\u10D3\u10D4\u10E1 "${r.suffix}"-\u10D8\u10D7`:r.format==="includes"?`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8: \u10E3\u10DC\u10D3\u10D0 \u10E8\u10D4\u10D8\u10EA\u10D0\u10D5\u10D3\u10D4\u10E1 "${r.includes}"-\u10E1`:r.format==="regex"?`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8: \u10E3\u10DC\u10D3\u10D0 \u10E8\u10D4\u10D4\u10E1\u10D0\u10D1\u10D0\u10DB\u10D4\u10D1\u10DD\u10D3\u10D4\u10E1 \u10E8\u10D0\u10D1\u10DA\u10DD\u10DC\u10E1 ${r.pattern}`:`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 ${n[r.format]??o.format}`}case"not_multiple_of":return`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E0\u10D8\u10EA\u10EE\u10D5\u10D8: \u10E3\u10DC\u10D3\u10D0 \u10D8\u10E7\u10DD\u10E1 ${o.divisor}-\u10D8\u10E1 \u10EF\u10D4\u10E0\u10D0\u10D3\u10D8`;case"unrecognized_keys":return`\u10E3\u10EA\u10DC\u10DD\u10D1\u10D8 \u10D2\u10D0\u10E1\u10D0\u10E6\u10D4\u10D1${o.keys.length>1?"\u10D4\u10D1\u10D8":"\u10D8"}: ${S(o.keys,", ")}`;case"invalid_key":return`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10D2\u10D0\u10E1\u10D0\u10E6\u10D4\u10D1\u10D8 ${o.origin}-\u10E8\u10D8`;case"invalid_union":return"\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0";case"invalid_element":return`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10DB\u10DC\u10D8\u10E8\u10D5\u10DC\u10D4\u10DA\u10DD\u10D1\u10D0 ${o.origin}-\u10E8\u10D8`;default:return"\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0"}}};function Jv(){return{localeError:Fz()}}var Bz=()=>{let e={string:{unit:"\u178F\u17BD\u17A2\u1780\u17D2\u179F\u179A",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"},file:{unit:"\u1794\u17C3",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"},array:{unit:"\u1792\u17B6\u178F\u17BB",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"},set:{unit:"\u1792\u17B6\u178F\u17BB",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"\u1798\u17B7\u1793\u1798\u17C2\u1793\u1787\u17B6\u179B\u17C1\u1781 (NaN)":"\u179B\u17C1\u1781";case"object":{if(Array.isArray(r))return"\u17A2\u17B6\u179A\u17C1 (Array)";if(r===null)return"\u1782\u17D2\u1798\u17B6\u1793\u178F\u1798\u17D2\u179B\u17C3 (null)";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B",email:"\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793\u17A2\u17CA\u17B8\u1798\u17C2\u179B",url:"URL",emoji:"\u179F\u1789\u17D2\u1789\u17B6\u17A2\u17B6\u179A\u1798\u17D2\u1798\u178E\u17CD",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u1780\u17B6\u179B\u1794\u179A\u17B7\u1785\u17D2\u1786\u17C1\u1791 \u1793\u17B7\u1784\u1798\u17C9\u17C4\u1784 ISO",date:"\u1780\u17B6\u179B\u1794\u179A\u17B7\u1785\u17D2\u1786\u17C1\u1791 ISO",time:"\u1798\u17C9\u17C4\u1784 ISO",duration:"\u179A\u1799\u17C8\u1796\u17C1\u179B ISO",ipv4:"\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv4",ipv6:"\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv6",cidrv4:"\u178A\u17C2\u1793\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv4",cidrv6:"\u178A\u17C2\u1793\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv6",base64:"\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u17A2\u17CA\u17B7\u1780\u17BC\u178A base64",base64url:"\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u17A2\u17CA\u17B7\u1780\u17BC\u178A base64url",json_string:"\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A JSON",e164:"\u179B\u17C1\u1781 E.164",jwt:"JWT",template_literal:"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B"};return r=>{switch(r.code){case"invalid_type":return`\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${r.expected} \u1794\u17C9\u17BB\u1793\u17D2\u178F\u17C2\u1791\u1791\u17BD\u179B\u1794\u17B6\u1793 ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${j(r.values[0])}`:`\u1787\u1798\u17D2\u179A\u17BE\u179F\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1787\u17B6\u1798\u17BD\u1799\u1780\u17D2\u1793\u17BB\u1784\u1785\u17C6\u178E\u17C4\u1798 ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u1792\u17C6\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${r.origin??"\u178F\u1798\u17D2\u179B\u17C3"} ${i} ${r.maximum.toString()} ${a.unit??"\u1792\u17B6\u178F\u17BB"}`:`\u1792\u17C6\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${r.origin??"\u178F\u1798\u17D2\u179B\u17C3"} ${i} ${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u178F\u17BC\u1785\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${r.origin} ${i} ${r.minimum.toString()} ${a.unit}`:`\u178F\u17BC\u1785\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${r.origin} ${i} ${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1785\u17B6\u1794\u17CB\u1795\u17D2\u178F\u17BE\u1798\u178A\u17C4\u1799 "${i.prefix}"`:i.format==="ends_with"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1794\u1789\u17D2\u1785\u1794\u17CB\u178A\u17C4\u1799 "${i.suffix}"`:i.format==="includes"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1798\u17B6\u1793 "${i.includes}"`:i.format==="regex"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u178F\u17C2\u1795\u17D2\u1782\u17BC\u1795\u17D2\u1782\u1784\u1793\u17B9\u1784\u1791\u1798\u17D2\u179A\u1784\u17CB\u178A\u17C2\u179B\u1794\u17B6\u1793\u1780\u17C6\u178E\u178F\u17CB ${i.pattern}`:`\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 ${o[i.format]??r.format}`}case"not_multiple_of":return`\u179B\u17C1\u1781\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u178F\u17C2\u1787\u17B6\u1796\u17A0\u17BB\u1782\u17BB\u178E\u1793\u17C3 ${r.divisor}`;case"unrecognized_keys":return`\u179A\u1780\u1783\u17BE\u1789\u179F\u17C4\u1798\u17B7\u1793\u179F\u17D2\u1782\u17B6\u179B\u17CB\u17D6 ${S(r.keys,", ")}`;case"invalid_key":return`\u179F\u17C4\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u1793\u17C5\u1780\u17D2\u1793\u17BB\u1784 ${r.origin}`;case"invalid_union":return"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C";case"invalid_element":return`\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u1793\u17C5\u1780\u17D2\u1793\u17BB\u1784 ${r.origin}`;default:return"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C"}}};function Ic(){return{localeError:Bz()}}function Gv(){return Ic()}var Kz=()=>{let e={string:{unit:"\uBB38\uC790",verb:"to have"},file:{unit:"\uBC14\uC774\uD2B8",verb:"to have"},array:{unit:"\uAC1C",verb:"to have"},set:{unit:"\uAC1C",verb:"to have"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"number";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\uC785\uB825",email:"\uC774\uBA54\uC77C \uC8FC\uC18C",url:"URL",emoji:"\uC774\uBAA8\uC9C0",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \uB0A0\uC9DC\uC2DC\uAC04",date:"ISO \uB0A0\uC9DC",time:"ISO \uC2DC\uAC04",duration:"ISO \uAE30\uAC04",ipv4:"IPv4 \uC8FC\uC18C",ipv6:"IPv6 \uC8FC\uC18C",cidrv4:"IPv4 \uBC94\uC704",cidrv6:"IPv6 \uBC94\uC704",base64:"base64 \uC778\uCF54\uB529 \uBB38\uC790\uC5F4",base64url:"base64url \uC778\uCF54\uB529 \uBB38\uC790\uC5F4",json_string:"JSON \uBB38\uC790\uC5F4",e164:"E.164 \uBC88\uD638",jwt:"JWT",template_literal:"\uC785\uB825"};return r=>{switch(r.code){case"invalid_type":return`\uC798\uBABB\uB41C \uC785\uB825: \uC608\uC0C1 \uD0C0\uC785\uC740 ${r.expected}, \uBC1B\uC740 \uD0C0\uC785\uC740 ${n(r.input)}\uC785\uB2C8\uB2E4`;case"invalid_value":return r.values.length===1?`\uC798\uBABB\uB41C \uC785\uB825: \uAC12\uC740 ${j(r.values[0])} \uC774\uC5B4\uC57C \uD569\uB2C8\uB2E4`:`\uC798\uBABB\uB41C \uC635\uC158: ${S(r.values,"\uB610\uB294 ")} \uC911 \uD558\uB098\uC5EC\uC57C \uD569\uB2C8\uB2E4`;case"too_big":{let i=r.inclusive?"\uC774\uD558":"\uBBF8\uB9CC",a=i==="\uBBF8\uB9CC"?"\uC774\uC5B4\uC57C \uD569\uB2C8\uB2E4":"\uC5EC\uC57C \uD569\uB2C8\uB2E4",s=t(r.origin),c=s?.unit??"\uC694\uC18C";return s?`${r.origin??"\uAC12"}\uC774 \uB108\uBB34 \uD07D\uB2C8\uB2E4: ${r.maximum.toString()}${c} ${i}${a}`:`${r.origin??"\uAC12"}\uC774 \uB108\uBB34 \uD07D\uB2C8\uB2E4: ${r.maximum.toString()} ${i}${a}`}case"too_small":{let i=r.inclusive?"\uC774\uC0C1":"\uCD08\uACFC",a=i==="\uC774\uC0C1"?"\uC774\uC5B4\uC57C \uD569\uB2C8\uB2E4":"\uC5EC\uC57C \uD569\uB2C8\uB2E4",s=t(r.origin),c=s?.unit??"\uC694\uC18C";return s?`${r.origin??"\uAC12"}\uC774 \uB108\uBB34 \uC791\uC2B5\uB2C8\uB2E4: ${r.minimum.toString()}${c} ${i}${a}`:`${r.origin??"\uAC12"}\uC774 \uB108\uBB34 \uC791\uC2B5\uB2C8\uB2E4: ${r.minimum.toString()} ${i}${a}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: "${i.prefix}"(\uC73C)\uB85C \uC2DC\uC791\uD574\uC57C \uD569\uB2C8\uB2E4`:i.format==="ends_with"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: "${i.suffix}"(\uC73C)\uB85C \uB05D\uB098\uC57C \uD569\uB2C8\uB2E4`:i.format==="includes"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: "${i.includes}"\uC744(\uB97C) \uD3EC\uD568\uD574\uC57C \uD569\uB2C8\uB2E4`:i.format==="regex"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: \uC815\uADDC\uC2DD ${i.pattern} \uD328\uD134\uACFC \uC77C\uCE58\uD574\uC57C \uD569\uB2C8\uB2E4`:`\uC798\uBABB\uB41C ${o[i.format]??r.format}`}case"not_multiple_of":return`\uC798\uBABB\uB41C \uC22B\uC790: ${r.divisor}\uC758 \uBC30\uC218\uC5EC\uC57C \uD569\uB2C8\uB2E4`;case"unrecognized_keys":return`\uC778\uC2DD\uD560 \uC218 \uC5C6\uB294 \uD0A4: ${S(r.keys,", ")}`;case"invalid_key":return`\uC798\uBABB\uB41C \uD0A4: ${r.origin}`;case"invalid_union":return"\uC798\uBABB\uB41C \uC785\uB825";case"invalid_element":return`\uC798\uBABB\uB41C \uAC12: ${r.origin}`;default:return"\uC798\uBABB\uB41C \uC785\uB825"}}};function Wv(){return{localeError:Kz()}}var Hz=e=>hi(typeof e,e),hi=(e,t=void 0)=>{switch(e){case"number":return Number.isNaN(t)?"NaN":"skai\u010Dius";case"bigint":return"sveikasis skai\u010Dius";case"string":return"eilut\u0117";case"boolean":return"login\u0117 reik\u0161m\u0117";case"undefined":case"void":return"neapibr\u0117\u017Eta reik\u0161m\u0117";case"function":return"funkcija";case"symbol":return"simbolis";case"object":return t===void 0?"ne\u017Einomas objektas":t===null?"nulin\u0117 reik\u0161m\u0117":Array.isArray(t)?"masyvas":Object.getPrototypeOf(t)!==Object.prototype&&t.constructor?t.constructor.name:"objektas";case"null":return"nulin\u0117 reik\u0161m\u0117"}return e},mi=e=>e.charAt(0).toUpperCase()+e.slice(1);function Xv(e){let t=Math.abs(e),n=t%10,o=t%100;return o>=11&&o<=19||n===0?"many":n===1?"one":"few"}var Jz=()=>{let e={string:{unit:{one:"simbolis",few:"simboliai",many:"simboli\u0173"},verb:{smaller:{inclusive:"turi b\u016Bti ne ilgesn\u0117 kaip",notInclusive:"turi b\u016Bti trumpesn\u0117 kaip"},bigger:{inclusive:"turi b\u016Bti ne trumpesn\u0117 kaip",notInclusive:"turi b\u016Bti ilgesn\u0117 kaip"}}},file:{unit:{one:"baitas",few:"baitai",many:"bait\u0173"},verb:{smaller:{inclusive:"turi b\u016Bti ne didesnis kaip",notInclusive:"turi b\u016Bti ma\u017Eesnis kaip"},bigger:{inclusive:"turi b\u016Bti ne ma\u017Eesnis kaip",notInclusive:"turi b\u016Bti didesnis kaip"}}},array:{unit:{one:"element\u0105",few:"elementus",many:"element\u0173"},verb:{smaller:{inclusive:"turi tur\u0117ti ne daugiau kaip",notInclusive:"turi tur\u0117ti ma\u017Eiau kaip"},bigger:{inclusive:"turi tur\u0117ti ne ma\u017Eiau kaip",notInclusive:"turi tur\u0117ti daugiau kaip"}}},set:{unit:{one:"element\u0105",few:"elementus",many:"element\u0173"},verb:{smaller:{inclusive:"turi tur\u0117ti ne daugiau kaip",notInclusive:"turi tur\u0117ti ma\u017Eiau kaip"},bigger:{inclusive:"turi tur\u0117ti ne ma\u017Eiau kaip",notInclusive:"turi tur\u0117ti daugiau kaip"}}}};function t(o,r,i,a){let s=e[o]??null;return s===null?s:{unit:s.unit[r],verb:s.verb[a][i?"inclusive":"notInclusive"]}}let n={regex:"\u012Fvestis",email:"el. pa\u0161to adresas",url:"URL",emoji:"jaustukas",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO data ir laikas",date:"ISO data",time:"ISO laikas",duration:"ISO trukm\u0117",ipv4:"IPv4 adresas",ipv6:"IPv6 adresas",cidrv4:"IPv4 tinklo prefiksas (CIDR)",cidrv6:"IPv6 tinklo prefiksas (CIDR)",base64:"base64 u\u017Ekoduota eilut\u0117",base64url:"base64url u\u017Ekoduota eilut\u0117",json_string:"JSON eilut\u0117",e164:"E.164 numeris",jwt:"JWT",template_literal:"\u012Fvestis"};return o=>{switch(o.code){case"invalid_type":return`Gautas tipas ${Hz(o.input)}, o tik\u0117tasi - ${hi(o.expected)}`;case"invalid_value":return o.values.length===1?`Privalo b\u016Bti ${j(o.values[0])}`:`Privalo b\u016Bti vienas i\u0161 ${S(o.values,"|")} pasirinkim\u0173`;case"too_big":{let r=hi(o.origin),i=t(o.origin,Xv(Number(o.maximum)),o.inclusive??!1,"smaller");if(i?.verb)return`${mi(r??o.origin??"reik\u0161m\u0117")} ${i.verb} ${o.maximum.toString()} ${i.unit??"element\u0173"}`;let a=o.inclusive?"ne didesnis kaip":"ma\u017Eesnis kaip";return`${mi(r??o.origin??"reik\u0161m\u0117")} turi b\u016Bti ${a} ${o.maximum.toString()} ${i?.unit}`}case"too_small":{let r=hi(o.origin),i=t(o.origin,Xv(Number(o.minimum)),o.inclusive??!1,"bigger");if(i?.verb)return`${mi(r??o.origin??"reik\u0161m\u0117")} ${i.verb} ${o.minimum.toString()} ${i.unit??"element\u0173"}`;let a=o.inclusive?"ne ma\u017Eesnis kaip":"didesnis kaip";return`${mi(r??o.origin??"reik\u0161m\u0117")} turi b\u016Bti ${a} ${o.minimum.toString()} ${i?.unit}`}case"invalid_format":{let r=o;return r.format==="starts_with"?`Eilut\u0117 privalo prasid\u0117ti "${r.prefix}"`:r.format==="ends_with"?`Eilut\u0117 privalo pasibaigti "${r.suffix}"`:r.format==="includes"?`Eilut\u0117 privalo \u012Ftraukti "${r.includes}"`:r.format==="regex"?`Eilut\u0117 privalo atitikti ${r.pattern}`:`Neteisingas ${n[r.format]??o.format}`}case"not_multiple_of":return`Skai\u010Dius privalo b\u016Bti ${o.divisor} kartotinis.`;case"unrecognized_keys":return`Neatpa\u017Eint${o.keys.length>1?"i":"as"} rakt${o.keys.length>1?"ai":"as"}: ${S(o.keys,", ")}`;case"invalid_key":return"Rastas klaidingas raktas";case"invalid_union":return"Klaidinga \u012Fvestis";case"invalid_element":{let r=hi(o.origin);return`${mi(r??o.origin??"reik\u0161m\u0117")} turi klaiding\u0105 \u012Fvest\u012F`}default:return"Klaidinga \u012Fvestis"}}};function Yv(){return{localeError:Jz()}}var Gz=()=>{let e={string:{unit:"\u0437\u043D\u0430\u0446\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"},file:{unit:"\u0431\u0430\u0458\u0442\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"},array:{unit:"\u0441\u0442\u0430\u0432\u043A\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"},set:{unit:"\u0441\u0442\u0430\u0432\u043A\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u0431\u0440\u043E\u0458";case"object":{if(Array.isArray(r))return"\u043D\u0438\u0437\u0430";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0432\u043D\u0435\u0441",email:"\u0430\u0434\u0440\u0435\u0441\u0430 \u043D\u0430 \u0435-\u043F\u043E\u0448\u0442\u0430",url:"URL",emoji:"\u0435\u043C\u043E\u045F\u0438",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0434\u0430\u0442\u0443\u043C \u0438 \u0432\u0440\u0435\u043C\u0435",date:"ISO \u0434\u0430\u0442\u0443\u043C",time:"ISO \u0432\u0440\u0435\u043C\u0435",duration:"ISO \u0432\u0440\u0435\u043C\u0435\u0442\u0440\u0430\u0435\u045A\u0435",ipv4:"IPv4 \u0430\u0434\u0440\u0435\u0441\u0430",ipv6:"IPv6 \u0430\u0434\u0440\u0435\u0441\u0430",cidrv4:"IPv4 \u043E\u043F\u0441\u0435\u0433",cidrv6:"IPv6 \u043E\u043F\u0441\u0435\u0433",base64:"base64-\u0435\u043D\u043A\u043E\u0434\u0438\u0440\u0430\u043D\u0430 \u043D\u0438\u0437\u0430",base64url:"base64url-\u0435\u043D\u043A\u043E\u0434\u0438\u0440\u0430\u043D\u0430 \u043D\u0438\u0437\u0430",json_string:"JSON \u043D\u0438\u0437\u0430",e164:"E.164 \u0431\u0440\u043E\u0458",jwt:"JWT",template_literal:"\u0432\u043D\u0435\u0441"};return r=>{switch(r.code){case"invalid_type":return`\u0413\u0440\u0435\u0448\u0435\u043D \u0432\u043D\u0435\u0441: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${r.expected}, \u043F\u0440\u0438\u043C\u0435\u043D\u043E ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Invalid input: expected ${j(r.values[0])}`:`\u0413\u0440\u0435\u0448\u0430\u043D\u0430 \u043E\u043F\u0446\u0438\u0458\u0430: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 \u0435\u0434\u043D\u0430 ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u0433\u043E\u043B\u0435\u043C: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${r.origin??"\u0432\u0440\u0435\u0434\u043D\u043E\u0441\u0442\u0430"} \u0434\u0430 \u0438\u043C\u0430 ${i}${r.maximum.toString()} ${a.unit??"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0438"}`:`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u0433\u043E\u043B\u0435\u043C: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${r.origin??"\u0432\u0440\u0435\u0434\u043D\u043E\u0441\u0442\u0430"} \u0434\u0430 \u0431\u0438\u0434\u0435 ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u043C\u0430\u043B: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${r.origin} \u0434\u0430 \u0438\u043C\u0430 ${i}${r.minimum.toString()} ${a.unit}`:`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u043C\u0430\u043B: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${r.origin} \u0434\u0430 \u0431\u0438\u0434\u0435 ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0437\u0430\u043F\u043E\u0447\u043D\u0443\u0432\u0430 \u0441\u043E "${i.prefix}"`:i.format==="ends_with"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0437\u0430\u0432\u0440\u0448\u0443\u0432\u0430 \u0441\u043E "${i.suffix}"`:i.format==="includes"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0432\u043A\u043B\u0443\u0447\u0443\u0432\u0430 "${i.includes}"`:i.format==="regex"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u043E\u0434\u0433\u043E\u0430\u0440\u0430 \u043D\u0430 \u043F\u0430\u0442\u0435\u0440\u043D\u043E\u0442 ${i.pattern}`:`Invalid ${o[i.format]??r.format}`}case"not_multiple_of":return`\u0413\u0440\u0435\u0448\u0435\u043D \u0431\u0440\u043E\u0458: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0431\u0438\u0434\u0435 \u0434\u0435\u043B\u0438\u0432 \u0441\u043E ${r.divisor}`;case"unrecognized_keys":return`${r.keys.length>1?"\u041D\u0435\u043F\u0440\u0435\u043F\u043E\u0437\u043D\u0430\u0435\u043D\u0438 \u043A\u043B\u0443\u0447\u0435\u0432\u0438":"\u041D\u0435\u043F\u0440\u0435\u043F\u043E\u0437\u043D\u0430\u0435\u043D \u043A\u043B\u0443\u0447"}: ${S(r.keys,", ")}`;case"invalid_key":return`\u0413\u0440\u0435\u0448\u0435\u043D \u043A\u043B\u0443\u0447 \u0432\u043E ${r.origin}`;case"invalid_union":return"\u0413\u0440\u0435\u0448\u0435\u043D \u0432\u043D\u0435\u0441";case"invalid_element":return`\u0413\u0440\u0435\u0448\u043D\u0430 \u0432\u0440\u0435\u0434\u043D\u043E\u0441\u0442 \u0432\u043E ${r.origin}`;default:return"\u0413\u0440\u0435\u0448\u0435\u043D \u0432\u043D\u0435\u0441"}}};function Qv(){return{localeError:Gz()}}var Wz=()=>{let e={string:{unit:"aksara",verb:"mempunyai"},file:{unit:"bait",verb:"mempunyai"},array:{unit:"elemen",verb:"mempunyai"},set:{unit:"elemen",verb:"mempunyai"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"nombor";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"input",email:"alamat e-mel",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"tarikh masa ISO",date:"tarikh ISO",time:"masa ISO",duration:"tempoh ISO",ipv4:"alamat IPv4",ipv6:"alamat IPv6",cidrv4:"julat IPv4",cidrv6:"julat IPv6",base64:"string dikodkan base64",base64url:"string dikodkan base64url",json_string:"string JSON",e164:"nombor E.164",jwt:"JWT",template_literal:"input"};return r=>{switch(r.code){case"invalid_type":return`Input tidak sah: dijangka ${r.expected}, diterima ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Input tidak sah: dijangka ${j(r.values[0])}`:`Pilihan tidak sah: dijangka salah satu daripada ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Terlalu besar: dijangka ${r.origin??"nilai"} ${a.verb} ${i}${r.maximum.toString()} ${a.unit??"elemen"}`:`Terlalu besar: dijangka ${r.origin??"nilai"} adalah ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Terlalu kecil: dijangka ${r.origin} ${a.verb} ${i}${r.minimum.toString()} ${a.unit}`:`Terlalu kecil: dijangka ${r.origin} adalah ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`String tidak sah: mesti bermula dengan "${i.prefix}"`:i.format==="ends_with"?`String tidak sah: mesti berakhir dengan "${i.suffix}"`:i.format==="includes"?`String tidak sah: mesti mengandungi "${i.includes}"`:i.format==="regex"?`String tidak sah: mesti sepadan dengan corak ${i.pattern}`:`${o[i.format]??r.format} tidak sah`}case"not_multiple_of":return`Nombor tidak sah: perlu gandaan ${r.divisor}`;case"unrecognized_keys":return`Kunci tidak dikenali: ${S(r.keys,", ")}`;case"invalid_key":return`Kunci tidak sah dalam ${r.origin}`;case"invalid_union":return"Input tidak sah";case"invalid_element":return`Nilai tidak sah dalam ${r.origin}`;default:return"Input tidak sah"}}};function e_(){return{localeError:Wz()}}var Xz=()=>{let e={string:{unit:"tekens"},file:{unit:"bytes"},array:{unit:"elementen"},set:{unit:"elementen"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"getal";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"invoer",email:"emailadres",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datum en tijd",date:"ISO datum",time:"ISO tijd",duration:"ISO duur",ipv4:"IPv4-adres",ipv6:"IPv6-adres",cidrv4:"IPv4-bereik",cidrv6:"IPv6-bereik",base64:"base64-gecodeerde tekst",base64url:"base64 URL-gecodeerde tekst",json_string:"JSON string",e164:"E.164-nummer",jwt:"JWT",template_literal:"invoer"};return r=>{switch(r.code){case"invalid_type":return`Ongeldige invoer: verwacht ${r.expected}, ontving ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Ongeldige invoer: verwacht ${j(r.values[0])}`:`Ongeldige optie: verwacht \xE9\xE9n van ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Te lang: verwacht dat ${r.origin??"waarde"} ${i}${r.maximum.toString()} ${a.unit??"elementen"} bevat`:`Te lang: verwacht dat ${r.origin??"waarde"} ${i}${r.maximum.toString()} is`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Te kort: verwacht dat ${r.origin} ${i}${r.minimum.toString()} ${a.unit} bevat`:`Te kort: verwacht dat ${r.origin} ${i}${r.minimum.toString()} is`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Ongeldige tekst: moet met "${i.prefix}" beginnen`:i.format==="ends_with"?`Ongeldige tekst: moet op "${i.suffix}" eindigen`:i.format==="includes"?`Ongeldige tekst: moet "${i.includes}" bevatten`:i.format==="regex"?`Ongeldige tekst: moet overeenkomen met patroon ${i.pattern}`:`Ongeldig: ${o[i.format]??r.format}`}case"not_multiple_of":return`Ongeldig getal: moet een veelvoud van ${r.divisor} zijn`;case"unrecognized_keys":return`Onbekende key${r.keys.length>1?"s":""}: ${S(r.keys,", ")}`;case"invalid_key":return`Ongeldige key in ${r.origin}`;case"invalid_union":return"Ongeldige invoer";case"invalid_element":return`Ongeldige waarde in ${r.origin}`;default:return"Ongeldige invoer"}}};function t_(){return{localeError:Xz()}}var Yz=()=>{let e={string:{unit:"tegn",verb:"\xE5 ha"},file:{unit:"bytes",verb:"\xE5 ha"},array:{unit:"elementer",verb:"\xE5 inneholde"},set:{unit:"elementer",verb:"\xE5 inneholde"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"tall";case"object":{if(Array.isArray(r))return"liste";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"input",email:"e-postadresse",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO dato- og klokkeslett",date:"ISO-dato",time:"ISO-klokkeslett",duration:"ISO-varighet",ipv4:"IPv4-omr\xE5de",ipv6:"IPv6-omr\xE5de",cidrv4:"IPv4-spekter",cidrv6:"IPv6-spekter",base64:"base64-enkodet streng",base64url:"base64url-enkodet streng",json_string:"JSON-streng",e164:"E.164-nummer",jwt:"JWT",template_literal:"input"};return r=>{switch(r.code){case"invalid_type":return`Ugyldig input: forventet ${r.expected}, fikk ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Ugyldig verdi: forventet ${j(r.values[0])}`:`Ugyldig valg: forventet en av ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`For stor(t): forventet ${r.origin??"value"} til \xE5 ha ${i}${r.maximum.toString()} ${a.unit??"elementer"}`:`For stor(t): forventet ${r.origin??"value"} til \xE5 ha ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`For lite(n): forventet ${r.origin} til \xE5 ha ${i}${r.minimum.toString()} ${a.unit}`:`For lite(n): forventet ${r.origin} til \xE5 ha ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Ugyldig streng: m\xE5 starte med "${i.prefix}"`:i.format==="ends_with"?`Ugyldig streng: m\xE5 ende med "${i.suffix}"`:i.format==="includes"?`Ugyldig streng: m\xE5 inneholde "${i.includes}"`:i.format==="regex"?`Ugyldig streng: m\xE5 matche m\xF8nsteret ${i.pattern}`:`Ugyldig ${o[i.format]??r.format}`}case"not_multiple_of":return`Ugyldig tall: m\xE5 v\xE6re et multiplum av ${r.divisor}`;case"unrecognized_keys":return`${r.keys.length>1?"Ukjente n\xF8kler":"Ukjent n\xF8kkel"}: ${S(r.keys,", ")}`;case"invalid_key":return`Ugyldig n\xF8kkel i ${r.origin}`;case"invalid_union":return"Ugyldig input";case"invalid_element":return`Ugyldig verdi i ${r.origin}`;default:return"Ugyldig input"}}};function r_(){return{localeError:Yz()}}var Qz=()=>{let e={string:{unit:"harf",verb:"olmal\u0131d\u0131r"},file:{unit:"bayt",verb:"olmal\u0131d\u0131r"},array:{unit:"unsur",verb:"olmal\u0131d\u0131r"},set:{unit:"unsur",verb:"olmal\u0131d\u0131r"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"numara";case"object":{if(Array.isArray(r))return"saf";if(r===null)return"gayb";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"giren",email:"epostag\xE2h",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO heng\xE2m\u0131",date:"ISO tarihi",time:"ISO zaman\u0131",duration:"ISO m\xFCddeti",ipv4:"IPv4 ni\u015F\xE2n\u0131",ipv6:"IPv6 ni\u015F\xE2n\u0131",cidrv4:"IPv4 menzili",cidrv6:"IPv6 menzili",base64:"base64-\u015Fifreli metin",base64url:"base64url-\u015Fifreli metin",json_string:"JSON metin",e164:"E.164 say\u0131s\u0131",jwt:"JWT",template_literal:"giren"};return r=>{switch(r.code){case"invalid_type":return`F\xE2sit giren: umulan ${r.expected}, al\u0131nan ${n(r.input)}`;case"invalid_value":return r.values.length===1?`F\xE2sit giren: umulan ${j(r.values[0])}`:`F\xE2sit tercih: m\xFBteberler ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Fazla b\xFCy\xFCk: ${r.origin??"value"}, ${i}${r.maximum.toString()} ${a.unit??"elements"} sahip olmal\u0131yd\u0131.`:`Fazla b\xFCy\xFCk: ${r.origin??"value"}, ${i}${r.maximum.toString()} olmal\u0131yd\u0131.`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Fazla k\xFC\xE7\xFCk: ${r.origin}, ${i}${r.minimum.toString()} ${a.unit} sahip olmal\u0131yd\u0131.`:`Fazla k\xFC\xE7\xFCk: ${r.origin}, ${i}${r.minimum.toString()} olmal\u0131yd\u0131.`}case"invalid_format":{let i=r;return i.format==="starts_with"?`F\xE2sit metin: "${i.prefix}" ile ba\u015Flamal\u0131.`:i.format==="ends_with"?`F\xE2sit metin: "${i.suffix}" ile bitmeli.`:i.format==="includes"?`F\xE2sit metin: "${i.includes}" ihtiv\xE2 etmeli.`:i.format==="regex"?`F\xE2sit metin: ${i.pattern} nak\u015F\u0131na uymal\u0131.`:`F\xE2sit ${o[i.format]??r.format}`}case"not_multiple_of":return`F\xE2sit say\u0131: ${r.divisor} kat\u0131 olmal\u0131yd\u0131.`;case"unrecognized_keys":return`Tan\u0131nmayan anahtar ${r.keys.length>1?"s":""}: ${S(r.keys,", ")}`;case"invalid_key":return`${r.origin} i\xE7in tan\u0131nmayan anahtar var.`;case"invalid_union":return"Giren tan\u0131namad\u0131.";case"invalid_element":return`${r.origin} i\xE7in tan\u0131nmayan k\u0131ymet var.`;default:return"K\u0131ymet tan\u0131namad\u0131."}}};function n_(){return{localeError:Qz()}}var eI=()=>{let e={string:{unit:"\u062A\u0648\u06A9\u064A",verb:"\u0648\u0644\u0631\u064A"},file:{unit:"\u0628\u0627\u06CC\u067C\u0633",verb:"\u0648\u0644\u0631\u064A"},array:{unit:"\u062A\u0648\u06A9\u064A",verb:"\u0648\u0644\u0631\u064A"},set:{unit:"\u062A\u0648\u06A9\u064A",verb:"\u0648\u0644\u0631\u064A"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u0639\u062F\u062F";case"object":{if(Array.isArray(r))return"\u0627\u0631\u06D0";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0648\u0631\u0648\u062F\u064A",email:"\u0628\u0631\u06CC\u069A\u0646\u0627\u0644\u06CC\u06A9",url:"\u06CC\u0648 \u0622\u0631 \u0627\u0644",emoji:"\u0627\u06CC\u0645\u0648\u062C\u064A",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u0646\u06CC\u067C\u0647 \u0627\u0648 \u0648\u062E\u062A",date:"\u0646\u06D0\u067C\u0647",time:"\u0648\u062E\u062A",duration:"\u0645\u0648\u062F\u0647",ipv4:"\u062F IPv4 \u067E\u062A\u0647",ipv6:"\u062F IPv6 \u067E\u062A\u0647",cidrv4:"\u062F IPv4 \u0633\u0627\u062D\u0647",cidrv6:"\u062F IPv6 \u0633\u0627\u062D\u0647",base64:"base64-encoded \u0645\u062A\u0646",base64url:"base64url-encoded \u0645\u062A\u0646",json_string:"JSON \u0645\u062A\u0646",e164:"\u062F E.164 \u0634\u0645\u06D0\u0631\u0647",jwt:"JWT",template_literal:"\u0648\u0631\u0648\u062F\u064A"};return r=>{switch(r.code){case"invalid_type":return`\u0646\u0627\u0633\u0645 \u0648\u0631\u0648\u062F\u064A: \u0628\u0627\u06CC\u062F ${r.expected} \u0648\u0627\u06CC, \u0645\u06AB\u0631 ${n(r.input)} \u062A\u0631\u0644\u0627\u0633\u0647 \u0634\u0648`;case"invalid_value":return r.values.length===1?`\u0646\u0627\u0633\u0645 \u0648\u0631\u0648\u062F\u064A: \u0628\u0627\u06CC\u062F ${j(r.values[0])} \u0648\u0627\u06CC`:`\u0646\u0627\u0633\u0645 \u0627\u0646\u062A\u062E\u0627\u0628: \u0628\u0627\u06CC\u062F \u06CC\u0648 \u0644\u0647 ${S(r.values,"|")} \u0685\u062E\u0647 \u0648\u0627\u06CC`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u0689\u06CC\u0631 \u0644\u0648\u06CC: ${r.origin??"\u0627\u0631\u0632\u069A\u062A"} \u0628\u0627\u06CC\u062F ${i}${r.maximum.toString()} ${a.unit??"\u0639\u0646\u0635\u0631\u0648\u0646\u0647"} \u0648\u0644\u0631\u064A`:`\u0689\u06CC\u0631 \u0644\u0648\u06CC: ${r.origin??"\u0627\u0631\u0632\u069A\u062A"} \u0628\u0627\u06CC\u062F ${i}${r.maximum.toString()} \u0648\u064A`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u0689\u06CC\u0631 \u06A9\u0648\u0686\u0646\u06CC: ${r.origin} \u0628\u0627\u06CC\u062F ${i}${r.minimum.toString()} ${a.unit} \u0648\u0644\u0631\u064A`:`\u0689\u06CC\u0631 \u06A9\u0648\u0686\u0646\u06CC: ${r.origin} \u0628\u0627\u06CC\u062F ${i}${r.minimum.toString()} \u0648\u064A`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F \u062F "${i.prefix}" \u0633\u0631\u0647 \u067E\u06CC\u0644 \u0634\u064A`:i.format==="ends_with"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F \u062F "${i.suffix}" \u0633\u0631\u0647 \u067E\u0627\u06CC \u062A\u0647 \u0648\u0631\u0633\u064A\u0696\u064A`:i.format==="includes"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F "${i.includes}" \u0648\u0644\u0631\u064A`:i.format==="regex"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F \u062F ${i.pattern} \u0633\u0631\u0647 \u0645\u0637\u0627\u0628\u0642\u062A \u0648\u0644\u0631\u064A`:`${o[i.format]??r.format} \u0646\u0627\u0633\u0645 \u062F\u06CC`}case"not_multiple_of":return`\u0646\u0627\u0633\u0645 \u0639\u062F\u062F: \u0628\u0627\u06CC\u062F \u062F ${r.divisor} \u0645\u0636\u0631\u0628 \u0648\u064A`;case"unrecognized_keys":return`\u0646\u0627\u0633\u0645 ${r.keys.length>1?"\u06A9\u0644\u06CC\u0689\u0648\u0646\u0647":"\u06A9\u0644\u06CC\u0689"}: ${S(r.keys,", ")}`;case"invalid_key":return`\u0646\u0627\u0633\u0645 \u06A9\u0644\u06CC\u0689 \u067E\u0647 ${r.origin} \u06A9\u06D0`;case"invalid_union":return"\u0646\u0627\u0633\u0645\u0647 \u0648\u0631\u0648\u062F\u064A";case"invalid_element":return`\u0646\u0627\u0633\u0645 \u0639\u0646\u0635\u0631 \u067E\u0647 ${r.origin} \u06A9\u06D0`;default:return"\u0646\u0627\u0633\u0645\u0647 \u0648\u0631\u0648\u062F\u064A"}}};function o_(){return{localeError:eI()}}var tI=()=>{let e={string:{unit:"znak\xF3w",verb:"mie\u0107"},file:{unit:"bajt\xF3w",verb:"mie\u0107"},array:{unit:"element\xF3w",verb:"mie\u0107"},set:{unit:"element\xF3w",verb:"mie\u0107"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"liczba";case"object":{if(Array.isArray(r))return"tablica";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"wyra\u017Cenie",email:"adres email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data i godzina w formacie ISO",date:"data w formacie ISO",time:"godzina w formacie ISO",duration:"czas trwania ISO",ipv4:"adres IPv4",ipv6:"adres IPv6",cidrv4:"zakres IPv4",cidrv6:"zakres IPv6",base64:"ci\u0105g znak\xF3w zakodowany w formacie base64",base64url:"ci\u0105g znak\xF3w zakodowany w formacie base64url",json_string:"ci\u0105g znak\xF3w w formacie JSON",e164:"liczba E.164",jwt:"JWT",template_literal:"wej\u015Bcie"};return r=>{switch(r.code){case"invalid_type":return`Nieprawid\u0142owe dane wej\u015Bciowe: oczekiwano ${r.expected}, otrzymano ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Nieprawid\u0142owe dane wej\u015Bciowe: oczekiwano ${j(r.values[0])}`:`Nieprawid\u0142owa opcja: oczekiwano jednej z warto\u015Bci ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Za du\u017Ca warto\u015B\u0107: oczekiwano, \u017Ce ${r.origin??"warto\u015B\u0107"} b\u0119dzie mie\u0107 ${i}${r.maximum.toString()} ${a.unit??"element\xF3w"}`:`Zbyt du\u017C(y/a/e): oczekiwano, \u017Ce ${r.origin??"warto\u015B\u0107"} b\u0119dzie wynosi\u0107 ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Za ma\u0142a warto\u015B\u0107: oczekiwano, \u017Ce ${r.origin??"warto\u015B\u0107"} b\u0119dzie mie\u0107 ${i}${r.minimum.toString()} ${a.unit??"element\xF3w"}`:`Zbyt ma\u0142(y/a/e): oczekiwano, \u017Ce ${r.origin??"warto\u015B\u0107"} b\u0119dzie wynosi\u0107 ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi zaczyna\u0107 si\u0119 od "${i.prefix}"`:i.format==="ends_with"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi ko\u0144czy\u0107 si\u0119 na "${i.suffix}"`:i.format==="includes"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi zawiera\u0107 "${i.includes}"`:i.format==="regex"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi odpowiada\u0107 wzorcowi ${i.pattern}`:`Nieprawid\u0142ow(y/a/e) ${o[i.format]??r.format}`}case"not_multiple_of":return`Nieprawid\u0142owa liczba: musi by\u0107 wielokrotno\u015Bci\u0105 ${r.divisor}`;case"unrecognized_keys":return`Nierozpoznane klucze${r.keys.length>1?"s":""}: ${S(r.keys,", ")}`;case"invalid_key":return`Nieprawid\u0142owy klucz w ${r.origin}`;case"invalid_union":return"Nieprawid\u0142owe dane wej\u015Bciowe";case"invalid_element":return`Nieprawid\u0142owa warto\u015B\u0107 w ${r.origin}`;default:return"Nieprawid\u0142owe dane wej\u015Bciowe"}}};function i_(){return{localeError:tI()}}var rI=()=>{let e={string:{unit:"caracteres",verb:"ter"},file:{unit:"bytes",verb:"ter"},array:{unit:"itens",verb:"ter"},set:{unit:"itens",verb:"ter"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"n\xFAmero";case"object":{if(Array.isArray(r))return"array";if(r===null)return"nulo";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"padr\xE3o",email:"endere\xE7o de e-mail",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data e hora ISO",date:"data ISO",time:"hora ISO",duration:"dura\xE7\xE3o ISO",ipv4:"endere\xE7o IPv4",ipv6:"endere\xE7o IPv6",cidrv4:"faixa de IPv4",cidrv6:"faixa de IPv6",base64:"texto codificado em base64",base64url:"URL codificada em base64",json_string:"texto JSON",e164:"n\xFAmero E.164",jwt:"JWT",template_literal:"entrada"};return r=>{switch(r.code){case"invalid_type":return`Tipo inv\xE1lido: esperado ${r.expected}, recebido ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Entrada inv\xE1lida: esperado ${j(r.values[0])}`:`Op\xE7\xE3o inv\xE1lida: esperada uma das ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Muito grande: esperado que ${r.origin??"valor"} tivesse ${i}${r.maximum.toString()} ${a.unit??"elementos"}`:`Muito grande: esperado que ${r.origin??"valor"} fosse ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Muito pequeno: esperado que ${r.origin} tivesse ${i}${r.minimum.toString()} ${a.unit}`:`Muito pequeno: esperado que ${r.origin} fosse ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Texto inv\xE1lido: deve come\xE7ar com "${i.prefix}"`:i.format==="ends_with"?`Texto inv\xE1lido: deve terminar com "${i.suffix}"`:i.format==="includes"?`Texto inv\xE1lido: deve incluir "${i.includes}"`:i.format==="regex"?`Texto inv\xE1lido: deve corresponder ao padr\xE3o ${i.pattern}`:`${o[i.format]??r.format} inv\xE1lido`}case"not_multiple_of":return`N\xFAmero inv\xE1lido: deve ser m\xFAltiplo de ${r.divisor}`;case"unrecognized_keys":return`Chave${r.keys.length>1?"s":""} desconhecida${r.keys.length>1?"s":""}: ${S(r.keys,", ")}`;case"invalid_key":return`Chave inv\xE1lida em ${r.origin}`;case"invalid_union":return"Entrada inv\xE1lida";case"invalid_element":return`Valor inv\xE1lido em ${r.origin}`;default:return"Campo inv\xE1lido"}}};function a_(){return{localeError:rI()}}function s_(e,t,n,o){let r=Math.abs(e),i=r%10,a=r%100;return a>=11&&a<=19?o:i===1?t:i>=2&&i<=4?n:o}var nI=()=>{let e={string:{unit:{one:"\u0441\u0438\u043C\u0432\u043E\u043B",few:"\u0441\u0438\u043C\u0432\u043E\u043B\u0430",many:"\u0441\u0438\u043C\u0432\u043E\u043B\u043E\u0432"},verb:"\u0438\u043C\u0435\u0442\u044C"},file:{unit:{one:"\u0431\u0430\u0439\u0442",few:"\u0431\u0430\u0439\u0442\u0430",many:"\u0431\u0430\u0439\u0442"},verb:"\u0438\u043C\u0435\u0442\u044C"},array:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u043E\u0432"},verb:"\u0438\u043C\u0435\u0442\u044C"},set:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u043E\u0432"},verb:"\u0438\u043C\u0435\u0442\u044C"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u0447\u0438\u0441\u043B\u043E";case"object":{if(Array.isArray(r))return"\u043C\u0430\u0441\u0441\u0438\u0432";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0432\u0432\u043E\u0434",email:"email \u0430\u0434\u0440\u0435\u0441",url:"URL",emoji:"\u044D\u043C\u043E\u0434\u0437\u0438",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0434\u0430\u0442\u0430 \u0438 \u0432\u0440\u0435\u043C\u044F",date:"ISO \u0434\u0430\u0442\u0430",time:"ISO \u0432\u0440\u0435\u043C\u044F",duration:"ISO \u0434\u043B\u0438\u0442\u0435\u043B\u044C\u043D\u043E\u0441\u0442\u044C",ipv4:"IPv4 \u0430\u0434\u0440\u0435\u0441",ipv6:"IPv6 \u0430\u0434\u0440\u0435\u0441",cidrv4:"IPv4 \u0434\u0438\u0430\u043F\u0430\u0437\u043E\u043D",cidrv6:"IPv6 \u0434\u0438\u0430\u043F\u0430\u0437\u043E\u043D",base64:"\u0441\u0442\u0440\u043E\u043A\u0430 \u0432 \u0444\u043E\u0440\u043C\u0430\u0442\u0435 base64",base64url:"\u0441\u0442\u0440\u043E\u043A\u0430 \u0432 \u0444\u043E\u0440\u043C\u0430\u0442\u0435 base64url",json_string:"JSON \u0441\u0442\u0440\u043E\u043A\u0430",e164:"\u043D\u043E\u043C\u0435\u0440 E.164",jwt:"JWT",template_literal:"\u0432\u0432\u043E\u0434"};return r=>{switch(r.code){case"invalid_type":return`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0432\u0432\u043E\u0434: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C ${r.expected}, \u043F\u043E\u043B\u0443\u0447\u0435\u043D\u043E ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0432\u0432\u043E\u0434: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C ${j(r.values[0])}`:`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0432\u0430\u0440\u0438\u0430\u043D\u0442: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C \u043E\u0434\u043D\u043E \u0438\u0437 ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);if(a){let s=Number(r.maximum),c=s_(s,a.unit.one,a.unit.few,a.unit.many);return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u0431\u043E\u043B\u044C\u0448\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${r.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435"} \u0431\u0443\u0434\u0435\u0442 \u0438\u043C\u0435\u0442\u044C ${i}${r.maximum.toString()} ${c}`}return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u0431\u043E\u043B\u044C\u0448\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${r.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435"} \u0431\u0443\u0434\u0435\u0442 ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);if(a){let s=Number(r.minimum),c=s_(s,a.unit.one,a.unit.few,a.unit.many);return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u043C\u0430\u043B\u0435\u043D\u044C\u043A\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${r.origin} \u0431\u0443\u0434\u0435\u0442 \u0438\u043C\u0435\u0442\u044C ${i}${r.minimum.toString()} ${c}`}return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u043C\u0430\u043B\u0435\u043D\u044C\u043A\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${r.origin} \u0431\u0443\u0434\u0435\u0442 ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u043D\u0430\u0447\u0438\u043D\u0430\u0442\u044C\u0441\u044F \u0441 "${i.prefix}"`:i.format==="ends_with"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u0437\u0430\u043A\u0430\u043D\u0447\u0438\u0432\u0430\u0442\u044C\u0441\u044F \u043D\u0430 "${i.suffix}"`:i.format==="includes"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u0441\u043E\u0434\u0435\u0440\u0436\u0430\u0442\u044C "${i.includes}"`:i.format==="regex"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u0441\u043E\u043E\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u043E\u0432\u0430\u0442\u044C \u0448\u0430\u0431\u043B\u043E\u043D\u0443 ${i.pattern}`:`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 ${o[i.format]??r.format}`}case"not_multiple_of":return`\u041D\u0435\u0432\u0435\u0440\u043D\u043E\u0435 \u0447\u0438\u0441\u043B\u043E: \u0434\u043E\u043B\u0436\u043D\u043E \u0431\u044B\u0442\u044C \u043A\u0440\u0430\u0442\u043D\u044B\u043C ${r.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u0430\u0441\u043F\u043E\u0437\u043D\u0430\u043D\u043D${r.keys.length>1?"\u044B\u0435":"\u044B\u0439"} \u043A\u043B\u044E\u0447${r.keys.length>1?"\u0438":""}: ${S(r.keys,", ")}`;case"invalid_key":return`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u043A\u043B\u044E\u0447 \u0432 ${r.origin}`;case"invalid_union":return"\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0435 \u0432\u0445\u043E\u0434\u043D\u044B\u0435 \u0434\u0430\u043D\u043D\u044B\u0435";case"invalid_element":return`\u041D\u0435\u0432\u0435\u0440\u043D\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435 \u0432 ${r.origin}`;default:return"\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0435 \u0432\u0445\u043E\u0434\u043D\u044B\u0435 \u0434\u0430\u043D\u043D\u044B\u0435"}}};function c_(){return{localeError:nI()}}var oI=()=>{let e={string:{unit:"znakov",verb:"imeti"},file:{unit:"bajtov",verb:"imeti"},array:{unit:"elementov",verb:"imeti"},set:{unit:"elementov",verb:"imeti"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u0161tevilo";case"object":{if(Array.isArray(r))return"tabela";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"vnos",email:"e-po\u0161tni naslov",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datum in \u010Das",date:"ISO datum",time:"ISO \u010Das",duration:"ISO trajanje",ipv4:"IPv4 naslov",ipv6:"IPv6 naslov",cidrv4:"obseg IPv4",cidrv6:"obseg IPv6",base64:"base64 kodiran niz",base64url:"base64url kodiran niz",json_string:"JSON niz",e164:"E.164 \u0161tevilka",jwt:"JWT",template_literal:"vnos"};return r=>{switch(r.code){case"invalid_type":return`Neveljaven vnos: pri\u010Dakovano ${r.expected}, prejeto ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Neveljaven vnos: pri\u010Dakovano ${j(r.values[0])}`:`Neveljavna mo\u017Enost: pri\u010Dakovano eno izmed ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Preveliko: pri\u010Dakovano, da bo ${r.origin??"vrednost"} imelo ${i}${r.maximum.toString()} ${a.unit??"elementov"}`:`Preveliko: pri\u010Dakovano, da bo ${r.origin??"vrednost"} ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Premajhno: pri\u010Dakovano, da bo ${r.origin} imelo ${i}${r.minimum.toString()} ${a.unit}`:`Premajhno: pri\u010Dakovano, da bo ${r.origin} ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Neveljaven niz: mora se za\u010Deti z "${i.prefix}"`:i.format==="ends_with"?`Neveljaven niz: mora se kon\u010Dati z "${i.suffix}"`:i.format==="includes"?`Neveljaven niz: mora vsebovati "${i.includes}"`:i.format==="regex"?`Neveljaven niz: mora ustrezati vzorcu ${i.pattern}`:`Neveljaven ${o[i.format]??r.format}`}case"not_multiple_of":return`Neveljavno \u0161tevilo: mora biti ve\u010Dkratnik ${r.divisor}`;case"unrecognized_keys":return`Neprepoznan${r.keys.length>1?"i klju\u010Di":" klju\u010D"}: ${S(r.keys,", ")}`;case"invalid_key":return`Neveljaven klju\u010D v ${r.origin}`;case"invalid_union":return"Neveljaven vnos";case"invalid_element":return`Neveljavna vrednost v ${r.origin}`;default:return"Neveljaven vnos"}}};function u_(){return{localeError:oI()}}var iI=()=>{let e={string:{unit:"tecken",verb:"att ha"},file:{unit:"bytes",verb:"att ha"},array:{unit:"objekt",verb:"att inneh\xE5lla"},set:{unit:"objekt",verb:"att inneh\xE5lla"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"antal";case"object":{if(Array.isArray(r))return"lista";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"regulj\xE4rt uttryck",email:"e-postadress",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-datum och tid",date:"ISO-datum",time:"ISO-tid",duration:"ISO-varaktighet",ipv4:"IPv4-intervall",ipv6:"IPv6-intervall",cidrv4:"IPv4-spektrum",cidrv6:"IPv6-spektrum",base64:"base64-kodad str\xE4ng",base64url:"base64url-kodad str\xE4ng",json_string:"JSON-str\xE4ng",e164:"E.164-nummer",jwt:"JWT",template_literal:"mall-literal"};return r=>{switch(r.code){case"invalid_type":return`Ogiltig inmatning: f\xF6rv\xE4ntat ${r.expected}, fick ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Ogiltig inmatning: f\xF6rv\xE4ntat ${j(r.values[0])}`:`Ogiltigt val: f\xF6rv\xE4ntade en av ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`F\xF6r stor(t): f\xF6rv\xE4ntade ${r.origin??"v\xE4rdet"} att ha ${i}${r.maximum.toString()} ${a.unit??"element"}`:`F\xF6r stor(t): f\xF6rv\xE4ntat ${r.origin??"v\xE4rdet"} att ha ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`F\xF6r lite(t): f\xF6rv\xE4ntade ${r.origin??"v\xE4rdet"} att ha ${i}${r.minimum.toString()} ${a.unit}`:`F\xF6r lite(t): f\xF6rv\xE4ntade ${r.origin??"v\xE4rdet"} att ha ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Ogiltig str\xE4ng: m\xE5ste b\xF6rja med "${i.prefix}"`:i.format==="ends_with"?`Ogiltig str\xE4ng: m\xE5ste sluta med "${i.suffix}"`:i.format==="includes"?`Ogiltig str\xE4ng: m\xE5ste inneh\xE5lla "${i.includes}"`:i.format==="regex"?`Ogiltig str\xE4ng: m\xE5ste matcha m\xF6nstret "${i.pattern}"`:`Ogiltig(t) ${o[i.format]??r.format}`}case"not_multiple_of":return`Ogiltigt tal: m\xE5ste vara en multipel av ${r.divisor}`;case"unrecognized_keys":return`${r.keys.length>1?"Ok\xE4nda nycklar":"Ok\xE4nd nyckel"}: ${S(r.keys,", ")}`;case"invalid_key":return`Ogiltig nyckel i ${r.origin??"v\xE4rdet"}`;case"invalid_union":return"Ogiltig input";case"invalid_element":return`Ogiltigt v\xE4rde i ${r.origin??"v\xE4rdet"}`;default:return"Ogiltig input"}}};function l_(){return{localeError:iI()}}var aI=()=>{let e={string:{unit:"\u0B8E\u0BB4\u0BC1\u0BA4\u0BCD\u0BA4\u0BC1\u0B95\u0BCD\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"},file:{unit:"\u0BAA\u0BC8\u0B9F\u0BCD\u0B9F\u0BC1\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"},array:{unit:"\u0B89\u0BB1\u0BC1\u0BAA\u0BCD\u0BAA\u0BC1\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"},set:{unit:"\u0B89\u0BB1\u0BC1\u0BAA\u0BCD\u0BAA\u0BC1\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"\u0B8E\u0BA3\u0BCD \u0B85\u0BB2\u0BCD\u0BB2\u0BBE\u0BA4\u0BA4\u0BC1":"\u0B8E\u0BA3\u0BCD";case"object":{if(Array.isArray(r))return"\u0B85\u0BA3\u0BBF";if(r===null)return"\u0BB5\u0BC6\u0BB1\u0BC1\u0BAE\u0BC8";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1",email:"\u0BAE\u0BBF\u0BA9\u0BCD\u0BA9\u0B9E\u0BCD\u0B9A\u0BB2\u0BCD \u0BAE\u0BC1\u0B95\u0BB5\u0BB0\u0BBF",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0BA4\u0BC7\u0BA4\u0BBF \u0BA8\u0BC7\u0BB0\u0BAE\u0BCD",date:"ISO \u0BA4\u0BC7\u0BA4\u0BBF",time:"ISO \u0BA8\u0BC7\u0BB0\u0BAE\u0BCD",duration:"ISO \u0B95\u0BBE\u0BB2 \u0B85\u0BB3\u0BB5\u0BC1",ipv4:"IPv4 \u0BAE\u0BC1\u0B95\u0BB5\u0BB0\u0BBF",ipv6:"IPv6 \u0BAE\u0BC1\u0B95\u0BB5\u0BB0\u0BBF",cidrv4:"IPv4 \u0BB5\u0BB0\u0BAE\u0BCD\u0BAA\u0BC1",cidrv6:"IPv6 \u0BB5\u0BB0\u0BAE\u0BCD\u0BAA\u0BC1",base64:"base64-encoded \u0B9A\u0BB0\u0BAE\u0BCD",base64url:"base64url-encoded \u0B9A\u0BB0\u0BAE\u0BCD",json_string:"JSON \u0B9A\u0BB0\u0BAE\u0BCD",e164:"E.164 \u0B8E\u0BA3\u0BCD",jwt:"JWT",template_literal:"input"};return r=>{switch(r.code){case"invalid_type":return`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${r.expected}, \u0BAA\u0BC6\u0BB1\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${j(r.values[0])}`:`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0BB5\u0BBF\u0BB0\u0BC1\u0BAA\u0BCD\u0BAA\u0BAE\u0BCD: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${S(r.values,"|")} \u0B87\u0BB2\u0BCD \u0B92\u0BA9\u0BCD\u0BB1\u0BC1`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u0BAE\u0BBF\u0B95 \u0BAA\u0BC6\u0BB0\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${r.origin??"\u0BAE\u0BA4\u0BBF\u0BAA\u0BCD\u0BAA\u0BC1"} ${i}${r.maximum.toString()} ${a.unit??"\u0B89\u0BB1\u0BC1\u0BAA\u0BCD\u0BAA\u0BC1\u0B95\u0BB3\u0BCD"} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:`\u0BAE\u0BBF\u0B95 \u0BAA\u0BC6\u0BB0\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${r.origin??"\u0BAE\u0BA4\u0BBF\u0BAA\u0BCD\u0BAA\u0BC1"} ${i}${r.maximum.toString()} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u0BAE\u0BBF\u0B95\u0B9A\u0BCD \u0B9A\u0BBF\u0BB1\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${r.origin} ${i}${r.minimum.toString()} ${a.unit} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:`\u0BAE\u0BBF\u0B95\u0B9A\u0BCD \u0B9A\u0BBF\u0BB1\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${r.origin} ${i}${r.minimum.toString()} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: "${i.prefix}" \u0B87\u0BB2\u0BCD \u0BA4\u0BCA\u0B9F\u0B99\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:i.format==="ends_with"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: "${i.suffix}" \u0B87\u0BB2\u0BCD \u0BAE\u0BC1\u0B9F\u0BBF\u0BB5\u0B9F\u0BC8\u0BAF \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:i.format==="includes"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: "${i.includes}" \u0B90 \u0B89\u0BB3\u0BCD\u0BB3\u0B9F\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:i.format==="regex"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: ${i.pattern} \u0BAE\u0BC1\u0BB1\u0BC8\u0BAA\u0BBE\u0B9F\u0BCD\u0B9F\u0BC1\u0B9F\u0BA9\u0BCD \u0BAA\u0BCA\u0BB0\u0BC1\u0BA8\u0BCD\u0BA4 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 ${o[i.format]??r.format}`}case"not_multiple_of":return`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B8E\u0BA3\u0BCD: ${r.divisor} \u0B87\u0BA9\u0BCD \u0BAA\u0BB2\u0BAE\u0BBE\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`;case"unrecognized_keys":return`\u0B85\u0B9F\u0BC8\u0BAF\u0BBE\u0BB3\u0BAE\u0BCD \u0BA4\u0BC6\u0BB0\u0BBF\u0BAF\u0BBE\u0BA4 \u0BB5\u0BBF\u0B9A\u0BC8${r.keys.length>1?"\u0B95\u0BB3\u0BCD":""}: ${S(r.keys,", ")}`;case"invalid_key":return`${r.origin} \u0B87\u0BB2\u0BCD \u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0BB5\u0BBF\u0B9A\u0BC8`;case"invalid_union":return"\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1";case"invalid_element":return`${r.origin} \u0B87\u0BB2\u0BCD \u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0BAE\u0BA4\u0BBF\u0BAA\u0BCD\u0BAA\u0BC1`;default:return"\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1"}}};function d_(){return{localeError:aI()}}var sI=()=>{let e={string:{unit:"\u0E15\u0E31\u0E27\u0E2D\u0E31\u0E01\u0E29\u0E23",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"},file:{unit:"\u0E44\u0E1A\u0E15\u0E4C",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"},array:{unit:"\u0E23\u0E32\u0E22\u0E01\u0E32\u0E23",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"},set:{unit:"\u0E23\u0E32\u0E22\u0E01\u0E32\u0E23",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"\u0E44\u0E21\u0E48\u0E43\u0E0A\u0E48\u0E15\u0E31\u0E27\u0E40\u0E25\u0E02 (NaN)":"\u0E15\u0E31\u0E27\u0E40\u0E25\u0E02";case"object":{if(Array.isArray(r))return"\u0E2D\u0E32\u0E23\u0E4C\u0E40\u0E23\u0E22\u0E4C (Array)";if(r===null)return"\u0E44\u0E21\u0E48\u0E21\u0E35\u0E04\u0E48\u0E32 (null)";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E17\u0E35\u0E48\u0E1B\u0E49\u0E2D\u0E19",email:"\u0E17\u0E35\u0E48\u0E2D\u0E22\u0E39\u0E48\u0E2D\u0E35\u0E40\u0E21\u0E25",url:"URL",emoji:"\u0E2D\u0E34\u0E42\u0E21\u0E08\u0E34",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48\u0E40\u0E27\u0E25\u0E32\u0E41\u0E1A\u0E1A ISO",date:"\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48\u0E41\u0E1A\u0E1A ISO",time:"\u0E40\u0E27\u0E25\u0E32\u0E41\u0E1A\u0E1A ISO",duration:"\u0E0A\u0E48\u0E27\u0E07\u0E40\u0E27\u0E25\u0E32\u0E41\u0E1A\u0E1A ISO",ipv4:"\u0E17\u0E35\u0E48\u0E2D\u0E22\u0E39\u0E48 IPv4",ipv6:"\u0E17\u0E35\u0E48\u0E2D\u0E22\u0E39\u0E48 IPv6",cidrv4:"\u0E0A\u0E48\u0E27\u0E07 IP \u0E41\u0E1A\u0E1A IPv4",cidrv6:"\u0E0A\u0E48\u0E27\u0E07 IP \u0E41\u0E1A\u0E1A IPv6",base64:"\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E41\u0E1A\u0E1A Base64",base64url:"\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E41\u0E1A\u0E1A Base64 \u0E2A\u0E33\u0E2B\u0E23\u0E31\u0E1A URL",json_string:"\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E41\u0E1A\u0E1A JSON",e164:"\u0E40\u0E1A\u0E2D\u0E23\u0E4C\u0E42\u0E17\u0E23\u0E28\u0E31\u0E1E\u0E17\u0E4C\u0E23\u0E30\u0E2B\u0E27\u0E48\u0E32\u0E07\u0E1B\u0E23\u0E30\u0E40\u0E17\u0E28 (E.164)",jwt:"\u0E42\u0E17\u0E40\u0E04\u0E19 JWT",template_literal:"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E17\u0E35\u0E48\u0E1B\u0E49\u0E2D\u0E19"};return r=>{switch(r.code){case"invalid_type":return`\u0E1B\u0E23\u0E30\u0E40\u0E20\u0E17\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E04\u0E27\u0E23\u0E40\u0E1B\u0E47\u0E19 ${r.expected} \u0E41\u0E15\u0E48\u0E44\u0E14\u0E49\u0E23\u0E31\u0E1A ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u0E04\u0E48\u0E32\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E04\u0E27\u0E23\u0E40\u0E1B\u0E47\u0E19 ${j(r.values[0])}`:`\u0E15\u0E31\u0E27\u0E40\u0E25\u0E37\u0E2D\u0E01\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E04\u0E27\u0E23\u0E40\u0E1B\u0E47\u0E19\u0E2B\u0E19\u0E36\u0E48\u0E07\u0E43\u0E19 ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"\u0E44\u0E21\u0E48\u0E40\u0E01\u0E34\u0E19":"\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32",a=t(r.origin);return a?`\u0E40\u0E01\u0E34\u0E19\u0E01\u0E33\u0E2B\u0E19\u0E14: ${r.origin??"\u0E04\u0E48\u0E32"} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${r.maximum.toString()} ${a.unit??"\u0E23\u0E32\u0E22\u0E01\u0E32\u0E23"}`:`\u0E40\u0E01\u0E34\u0E19\u0E01\u0E33\u0E2B\u0E19\u0E14: ${r.origin??"\u0E04\u0E48\u0E32"} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?"\u0E2D\u0E22\u0E48\u0E32\u0E07\u0E19\u0E49\u0E2D\u0E22":"\u0E21\u0E32\u0E01\u0E01\u0E27\u0E48\u0E32",a=t(r.origin);return a?`\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32\u0E01\u0E33\u0E2B\u0E19\u0E14: ${r.origin} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${r.minimum.toString()} ${a.unit}`:`\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32\u0E01\u0E33\u0E2B\u0E19\u0E14: ${r.origin} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E15\u0E49\u0E2D\u0E07\u0E02\u0E36\u0E49\u0E19\u0E15\u0E49\u0E19\u0E14\u0E49\u0E27\u0E22 "${i.prefix}"`:i.format==="ends_with"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E15\u0E49\u0E2D\u0E07\u0E25\u0E07\u0E17\u0E49\u0E32\u0E22\u0E14\u0E49\u0E27\u0E22 "${i.suffix}"`:i.format==="includes"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E15\u0E49\u0E2D\u0E07\u0E21\u0E35 "${i.includes}" \u0E2D\u0E22\u0E39\u0E48\u0E43\u0E19\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21`:i.format==="regex"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E15\u0E49\u0E2D\u0E07\u0E15\u0E23\u0E07\u0E01\u0E31\u0E1A\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E17\u0E35\u0E48\u0E01\u0E33\u0E2B\u0E19\u0E14 ${i.pattern}`:`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: ${o[i.format]??r.format}`}case"not_multiple_of":return`\u0E15\u0E31\u0E27\u0E40\u0E25\u0E02\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E15\u0E49\u0E2D\u0E07\u0E40\u0E1B\u0E47\u0E19\u0E08\u0E33\u0E19\u0E27\u0E19\u0E17\u0E35\u0E48\u0E2B\u0E32\u0E23\u0E14\u0E49\u0E27\u0E22 ${r.divisor} \u0E44\u0E14\u0E49\u0E25\u0E07\u0E15\u0E31\u0E27`;case"unrecognized_keys":return`\u0E1E\u0E1A\u0E04\u0E35\u0E22\u0E4C\u0E17\u0E35\u0E48\u0E44\u0E21\u0E48\u0E23\u0E39\u0E49\u0E08\u0E31\u0E01: ${S(r.keys,", ")}`;case"invalid_key":return`\u0E04\u0E35\u0E22\u0E4C\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07\u0E43\u0E19 ${r.origin}`;case"invalid_union":return"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E44\u0E21\u0E48\u0E15\u0E23\u0E07\u0E01\u0E31\u0E1A\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E22\u0E39\u0E40\u0E19\u0E35\u0E22\u0E19\u0E17\u0E35\u0E48\u0E01\u0E33\u0E2B\u0E19\u0E14\u0E44\u0E27\u0E49";case"invalid_element":return`\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07\u0E43\u0E19 ${r.origin}`;default:return"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07"}}};function f_(){return{localeError:sI()}}var cI=e=>{let t=typeof e;switch(t){case"number":return Number.isNaN(e)?"NaN":"number";case"object":{if(Array.isArray(e))return"array";if(e===null)return"null";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return t},uI=()=>{let e={string:{unit:"karakter",verb:"olmal\u0131"},file:{unit:"bayt",verb:"olmal\u0131"},array:{unit:"\xF6\u011Fe",verb:"olmal\u0131"},set:{unit:"\xF6\u011Fe",verb:"olmal\u0131"}};function t(o){return e[o]??null}let n={regex:"girdi",email:"e-posta adresi",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO tarih ve saat",date:"ISO tarih",time:"ISO saat",duration:"ISO s\xFCre",ipv4:"IPv4 adresi",ipv6:"IPv6 adresi",cidrv4:"IPv4 aral\u0131\u011F\u0131",cidrv6:"IPv6 aral\u0131\u011F\u0131",base64:"base64 ile \u015Fifrelenmi\u015F metin",base64url:"base64url ile \u015Fifrelenmi\u015F metin",json_string:"JSON dizesi",e164:"E.164 say\u0131s\u0131",jwt:"JWT",template_literal:"\u015Eablon dizesi"};return o=>{switch(o.code){case"invalid_type":return`Ge\xE7ersiz de\u011Fer: beklenen ${o.expected}, al\u0131nan ${cI(o.input)}`;case"invalid_value":return o.values.length===1?`Ge\xE7ersiz de\u011Fer: beklenen ${j(o.values[0])}`:`Ge\xE7ersiz se\xE7enek: a\u015Fa\u011F\u0131dakilerden biri olmal\u0131: ${S(o.values,"|")}`;case"too_big":{let r=o.inclusive?"<=":"<",i=t(o.origin);return i?`\xC7ok b\xFCy\xFCk: beklenen ${o.origin??"de\u011Fer"} ${r}${o.maximum.toString()} ${i.unit??"\xF6\u011Fe"}`:`\xC7ok b\xFCy\xFCk: beklenen ${o.origin??"de\u011Fer"} ${r}${o.maximum.toString()}`}case"too_small":{let r=o.inclusive?">=":">",i=t(o.origin);return i?`\xC7ok k\xFC\xE7\xFCk: beklenen ${o.origin} ${r}${o.minimum.toString()} ${i.unit}`:`\xC7ok k\xFC\xE7\xFCk: beklenen ${o.origin} ${r}${o.minimum.toString()}`}case"invalid_format":{let r=o;return r.format==="starts_with"?`Ge\xE7ersiz metin: "${r.prefix}" ile ba\u015Flamal\u0131`:r.format==="ends_with"?`Ge\xE7ersiz metin: "${r.suffix}" ile bitmeli`:r.format==="includes"?`Ge\xE7ersiz metin: "${r.includes}" i\xE7ermeli`:r.format==="regex"?`Ge\xE7ersiz metin: ${r.pattern} desenine uymal\u0131`:`Ge\xE7ersiz ${n[r.format]??o.format}`}case"not_multiple_of":return`Ge\xE7ersiz say\u0131: ${o.divisor} ile tam b\xF6l\xFCnebilmeli`;case"unrecognized_keys":return`Tan\u0131nmayan anahtar${o.keys.length>1?"lar":""}: ${S(o.keys,", ")}`;case"invalid_key":return`${o.origin} i\xE7inde ge\xE7ersiz anahtar`;case"invalid_union":return"Ge\xE7ersiz de\u011Fer";case"invalid_element":return`${o.origin} i\xE7inde ge\xE7ersiz de\u011Fer`;default:return"Ge\xE7ersiz de\u011Fer"}}};function p_(){return{localeError:uI()}}var lI=()=>{let e={string:{unit:"\u0441\u0438\u043C\u0432\u043E\u043B\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"},file:{unit:"\u0431\u0430\u0439\u0442\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"},array:{unit:"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"},set:{unit:"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u0447\u0438\u0441\u043B\u043E";case"object":{if(Array.isArray(r))return"\u043C\u0430\u0441\u0438\u0432";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456",email:"\u0430\u0434\u0440\u0435\u0441\u0430 \u0435\u043B\u0435\u043A\u0442\u0440\u043E\u043D\u043D\u043E\u0457 \u043F\u043E\u0448\u0442\u0438",url:"URL",emoji:"\u0435\u043C\u043E\u0434\u0437\u0456",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u0434\u0430\u0442\u0430 \u0442\u0430 \u0447\u0430\u0441 ISO",date:"\u0434\u0430\u0442\u0430 ISO",time:"\u0447\u0430\u0441 ISO",duration:"\u0442\u0440\u0438\u0432\u0430\u043B\u0456\u0441\u0442\u044C ISO",ipv4:"\u0430\u0434\u0440\u0435\u0441\u0430 IPv4",ipv6:"\u0430\u0434\u0440\u0435\u0441\u0430 IPv6",cidrv4:"\u0434\u0456\u0430\u043F\u0430\u0437\u043E\u043D IPv4",cidrv6:"\u0434\u0456\u0430\u043F\u0430\u0437\u043E\u043D IPv6",base64:"\u0440\u044F\u0434\u043E\u043A \u0443 \u043A\u043E\u0434\u0443\u0432\u0430\u043D\u043D\u0456 base64",base64url:"\u0440\u044F\u0434\u043E\u043A \u0443 \u043A\u043E\u0434\u0443\u0432\u0430\u043D\u043D\u0456 base64url",json_string:"\u0440\u044F\u0434\u043E\u043A JSON",e164:"\u043D\u043E\u043C\u0435\u0440 E.164",jwt:"JWT",template_literal:"\u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456"};return r=>{switch(r.code){case"invalid_type":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F ${r.expected}, \u043E\u0442\u0440\u0438\u043C\u0430\u043D\u043E ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F ${j(r.values[0])}`:`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0430 \u043E\u043F\u0446\u0456\u044F: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F \u043E\u0434\u043D\u0435 \u0437 ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u0432\u0435\u043B\u0438\u043A\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${r.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F"} ${a.verb} ${i}${r.maximum.toString()} ${a.unit??"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0456\u0432"}`:`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u0432\u0435\u043B\u0438\u043A\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${r.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F"} \u0431\u0443\u0434\u0435 ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u043C\u0430\u043B\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${r.origin} ${a.verb} ${i}${r.minimum.toString()} ${a.unit}`:`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u043C\u0430\u043B\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${r.origin} \u0431\u0443\u0434\u0435 ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u043F\u043E\u0447\u0438\u043D\u0430\u0442\u0438\u0441\u044F \u0437 "${i.prefix}"`:i.format==="ends_with"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u0437\u0430\u043A\u0456\u043D\u0447\u0443\u0432\u0430\u0442\u0438\u0441\u044F \u043D\u0430 "${i.suffix}"`:i.format==="includes"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u043C\u0456\u0441\u0442\u0438\u0442\u0438 "${i.includes}"`:i.format==="regex"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u0432\u0456\u0434\u043F\u043E\u0432\u0456\u0434\u0430\u0442\u0438 \u0448\u0430\u0431\u043B\u043E\u043D\u0443 ${i.pattern}`:`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 ${o[i.format]??r.format}`}case"not_multiple_of":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0435 \u0447\u0438\u0441\u043B\u043E: \u043F\u043E\u0432\u0438\u043D\u043D\u043E \u0431\u0443\u0442\u0438 \u043A\u0440\u0430\u0442\u043D\u0438\u043C ${r.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u043E\u0437\u043F\u0456\u0437\u043D\u0430\u043D\u0438\u0439 \u043A\u043B\u044E\u0447${r.keys.length>1?"\u0456":""}: ${S(r.keys,", ")}`;case"invalid_key":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u043A\u043B\u044E\u0447 \u0443 ${r.origin}`;case"invalid_union":return"\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456";case"invalid_element":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F \u0443 ${r.origin}`;default:return"\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456"}}};function Ec(){return{localeError:lI()}}function m_(){return Ec()}var dI=()=>{let e={string:{unit:"\u062D\u0631\u0648\u0641",verb:"\u06C1\u0648\u0646\u0627"},file:{unit:"\u0628\u0627\u0626\u0679\u0633",verb:"\u06C1\u0648\u0646\u0627"},array:{unit:"\u0622\u0626\u0679\u0645\u0632",verb:"\u06C1\u0648\u0646\u0627"},set:{unit:"\u0622\u0626\u0679\u0645\u0632",verb:"\u06C1\u0648\u0646\u0627"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u0646\u0645\u0628\u0631";case"object":{if(Array.isArray(r))return"\u0622\u0631\u06D2";if(r===null)return"\u0646\u0644";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0627\u0646 \u067E\u0679",email:"\u0627\u06CC \u0645\u06CC\u0644 \u0627\u06CC\u0688\u0631\u06CC\u0633",url:"\u06CC\u0648 \u0622\u0631 \u0627\u06CC\u0644",emoji:"\u0627\u06CC\u0645\u0648\u062C\u06CC",uuid:"\u06CC\u0648 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",uuidv4:"\u06CC\u0648 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC \u0648\u06CC 4",uuidv6:"\u06CC\u0648 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC \u0648\u06CC 6",nanoid:"\u0646\u06CC\u0646\u0648 \u0622\u0626\u06CC \u0688\u06CC",guid:"\u062C\u06CC \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",cuid:"\u0633\u06CC \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",cuid2:"\u0633\u06CC \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC 2",ulid:"\u06CC\u0648 \u0627\u06CC\u0644 \u0622\u0626\u06CC \u0688\u06CC",xid:"\u0627\u06CC\u06A9\u0633 \u0622\u0626\u06CC \u0688\u06CC",ksuid:"\u06A9\u06D2 \u0627\u06CC\u0633 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",datetime:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u0688\u06CC\u0679 \u0679\u0627\u0626\u0645",date:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u062A\u0627\u0631\u06CC\u062E",time:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u0648\u0642\u062A",duration:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u0645\u062F\u062A",ipv4:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 4 \u0627\u06CC\u0688\u0631\u06CC\u0633",ipv6:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 6 \u0627\u06CC\u0688\u0631\u06CC\u0633",cidrv4:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 4 \u0631\u06CC\u0646\u062C",cidrv6:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 6 \u0631\u06CC\u0646\u062C",base64:"\u0628\u06CC\u0633 64 \u0627\u0646 \u06A9\u0648\u0688\u0688 \u0633\u0679\u0631\u0646\u06AF",base64url:"\u0628\u06CC\u0633 64 \u06CC\u0648 \u0622\u0631 \u0627\u06CC\u0644 \u0627\u0646 \u06A9\u0648\u0688\u0688 \u0633\u0679\u0631\u0646\u06AF",json_string:"\u062C\u06D2 \u0627\u06CC\u0633 \u0627\u0648 \u0627\u06CC\u0646 \u0633\u0679\u0631\u0646\u06AF",e164:"\u0627\u06CC 164 \u0646\u0645\u0628\u0631",jwt:"\u062C\u06D2 \u0688\u0628\u0644\u06CC\u0648 \u0679\u06CC",template_literal:"\u0627\u0646 \u067E\u0679"};return r=>{switch(r.code){case"invalid_type":return`\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679: ${r.expected} \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627\u060C ${n(r.input)} \u0645\u0648\u0635\u0648\u0644 \u06C1\u0648\u0627`;case"invalid_value":return r.values.length===1?`\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679: ${j(r.values[0])} \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`:`\u063A\u0644\u0637 \u0622\u067E\u0634\u0646: ${S(r.values,"|")} \u0645\u06CC\u06BA \u0633\u06D2 \u0627\u06CC\u06A9 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u0628\u06C1\u062A \u0628\u0691\u0627: ${r.origin??"\u0648\u06CC\u0644\u06CC\u0648"} \u06A9\u06D2 ${i}${r.maximum.toString()} ${a.unit??"\u0639\u0646\u0627\u0635\u0631"} \u06C1\u0648\u0646\u06D2 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u06D2`:`\u0628\u06C1\u062A \u0628\u0691\u0627: ${r.origin??"\u0648\u06CC\u0644\u06CC\u0648"} \u06A9\u0627 ${i}${r.maximum.toString()} \u06C1\u0648\u0646\u0627 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u0628\u06C1\u062A \u0686\u06BE\u0648\u0679\u0627: ${r.origin} \u06A9\u06D2 ${i}${r.minimum.toString()} ${a.unit} \u06C1\u0648\u0646\u06D2 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u06D2`:`\u0628\u06C1\u062A \u0686\u06BE\u0648\u0679\u0627: ${r.origin} \u06A9\u0627 ${i}${r.minimum.toString()} \u06C1\u0648\u0646\u0627 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: "${i.prefix}" \u0633\u06D2 \u0634\u0631\u0648\u0639 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:i.format==="ends_with"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: "${i.suffix}" \u067E\u0631 \u062E\u062A\u0645 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:i.format==="includes"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: "${i.includes}" \u0634\u0627\u0645\u0644 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:i.format==="regex"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: \u067E\u06CC\u0679\u0631\u0646 ${i.pattern} \u0633\u06D2 \u0645\u06CC\u0686 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:`\u063A\u0644\u0637 ${o[i.format]??r.format}`}case"not_multiple_of":return`\u063A\u0644\u0637 \u0646\u0645\u0628\u0631: ${r.divisor} \u06A9\u0627 \u0645\u0636\u0627\u0639\u0641 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`;case"unrecognized_keys":return`\u063A\u06CC\u0631 \u062A\u0633\u0644\u06CC\u0645 \u0634\u062F\u06C1 \u06A9\u06CC${r.keys.length>1?"\u0632":""}: ${S(r.keys,"\u060C ")}`;case"invalid_key":return`${r.origin} \u0645\u06CC\u06BA \u063A\u0644\u0637 \u06A9\u06CC`;case"invalid_union":return"\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679";case"invalid_element":return`${r.origin} \u0645\u06CC\u06BA \u063A\u0644\u0637 \u0648\u06CC\u0644\u06CC\u0648`;default:return"\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679"}}};function h_(){return{localeError:dI()}}var fI=()=>{let e={string:{unit:"k\xFD t\u1EF1",verb:"c\xF3"},file:{unit:"byte",verb:"c\xF3"},array:{unit:"ph\u1EA7n t\u1EED",verb:"c\xF3"},set:{unit:"ph\u1EA7n t\u1EED",verb:"c\xF3"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"s\u1ED1";case"object":{if(Array.isArray(r))return"m\u1EA3ng";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0111\u1EA7u v\xE0o",email:"\u0111\u1ECBa ch\u1EC9 email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ng\xE0y gi\u1EDD ISO",date:"ng\xE0y ISO",time:"gi\u1EDD ISO",duration:"kho\u1EA3ng th\u1EDDi gian ISO",ipv4:"\u0111\u1ECBa ch\u1EC9 IPv4",ipv6:"\u0111\u1ECBa ch\u1EC9 IPv6",cidrv4:"d\u1EA3i IPv4",cidrv6:"d\u1EA3i IPv6",base64:"chu\u1ED7i m\xE3 h\xF3a base64",base64url:"chu\u1ED7i m\xE3 h\xF3a base64url",json_string:"chu\u1ED7i JSON",e164:"s\u1ED1 E.164",jwt:"JWT",template_literal:"\u0111\u1EA7u v\xE0o"};return r=>{switch(r.code){case"invalid_type":return`\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i ${r.expected}, nh\u1EADn \u0111\u01B0\u1EE3c ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i ${j(r.values[0])}`:`T\xF9y ch\u1ECDn kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i m\u1ED9t trong c\xE1c gi\xE1 tr\u1ECB ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Qu\xE1 l\u1EDBn: mong \u0111\u1EE3i ${r.origin??"gi\xE1 tr\u1ECB"} ${a.verb} ${i}${r.maximum.toString()} ${a.unit??"ph\u1EA7n t\u1EED"}`:`Qu\xE1 l\u1EDBn: mong \u0111\u1EE3i ${r.origin??"gi\xE1 tr\u1ECB"} ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Qu\xE1 nh\u1ECF: mong \u0111\u1EE3i ${r.origin} ${a.verb} ${i}${r.minimum.toString()} ${a.unit}`:`Qu\xE1 nh\u1ECF: mong \u0111\u1EE3i ${r.origin} ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i b\u1EAFt \u0111\u1EA7u b\u1EB1ng "${i.prefix}"`:i.format==="ends_with"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i k\u1EBFt th\xFAc b\u1EB1ng "${i.suffix}"`:i.format==="includes"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i bao g\u1ED3m "${i.includes}"`:i.format==="regex"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i kh\u1EDBp v\u1EDBi m\u1EABu ${i.pattern}`:`${o[i.format]??r.format} kh\xF4ng h\u1EE3p l\u1EC7`}case"not_multiple_of":return`S\u1ED1 kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i l\xE0 b\u1ED9i s\u1ED1 c\u1EE7a ${r.divisor}`;case"unrecognized_keys":return`Kh\xF3a kh\xF4ng \u0111\u01B0\u1EE3c nh\u1EADn d\u1EA1ng: ${S(r.keys,", ")}`;case"invalid_key":return`Kh\xF3a kh\xF4ng h\u1EE3p l\u1EC7 trong ${r.origin}`;case"invalid_union":return"\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7";case"invalid_element":return`Gi\xE1 tr\u1ECB kh\xF4ng h\u1EE3p l\u1EC7 trong ${r.origin}`;default:return"\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7"}}};function g_(){return{localeError:fI()}}var pI=()=>{let e={string:{unit:"\u5B57\u7B26",verb:"\u5305\u542B"},file:{unit:"\u5B57\u8282",verb:"\u5305\u542B"},array:{unit:"\u9879",verb:"\u5305\u542B"},set:{unit:"\u9879",verb:"\u5305\u542B"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"\u975E\u6570\u5B57(NaN)":"\u6570\u5B57";case"object":{if(Array.isArray(r))return"\u6570\u7EC4";if(r===null)return"\u7A7A\u503C(null)";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u8F93\u5165",email:"\u7535\u5B50\u90AE\u4EF6",url:"URL",emoji:"\u8868\u60C5\u7B26\u53F7",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO\u65E5\u671F\u65F6\u95F4",date:"ISO\u65E5\u671F",time:"ISO\u65F6\u95F4",duration:"ISO\u65F6\u957F",ipv4:"IPv4\u5730\u5740",ipv6:"IPv6\u5730\u5740",cidrv4:"IPv4\u7F51\u6BB5",cidrv6:"IPv6\u7F51\u6BB5",base64:"base64\u7F16\u7801\u5B57\u7B26\u4E32",base64url:"base64url\u7F16\u7801\u5B57\u7B26\u4E32",json_string:"JSON\u5B57\u7B26\u4E32",e164:"E.164\u53F7\u7801",jwt:"JWT",template_literal:"\u8F93\u5165"};return r=>{switch(r.code){case"invalid_type":return`\u65E0\u6548\u8F93\u5165\uFF1A\u671F\u671B ${r.expected}\uFF0C\u5B9E\u9645\u63A5\u6536 ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u65E0\u6548\u8F93\u5165\uFF1A\u671F\u671B ${j(r.values[0])}`:`\u65E0\u6548\u9009\u9879\uFF1A\u671F\u671B\u4EE5\u4E0B\u4E4B\u4E00 ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u6570\u503C\u8FC7\u5927\uFF1A\u671F\u671B ${r.origin??"\u503C"} ${i}${r.maximum.toString()} ${a.unit??"\u4E2A\u5143\u7D20"}`:`\u6570\u503C\u8FC7\u5927\uFF1A\u671F\u671B ${r.origin??"\u503C"} ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u6570\u503C\u8FC7\u5C0F\uFF1A\u671F\u671B ${r.origin} ${i}${r.minimum.toString()} ${a.unit}`:`\u6570\u503C\u8FC7\u5C0F\uFF1A\u671F\u671B ${r.origin} ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u4EE5 "${i.prefix}" \u5F00\u5934`:i.format==="ends_with"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u4EE5 "${i.suffix}" \u7ED3\u5C3E`:i.format==="includes"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u5305\u542B "${i.includes}"`:i.format==="regex"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u6EE1\u8DB3\u6B63\u5219\u8868\u8FBE\u5F0F ${i.pattern}`:`\u65E0\u6548${o[i.format]??r.format}`}case"not_multiple_of":return`\u65E0\u6548\u6570\u5B57\uFF1A\u5FC5\u987B\u662F ${r.divisor} \u7684\u500D\u6570`;case"unrecognized_keys":return`\u51FA\u73B0\u672A\u77E5\u7684\u952E(key): ${S(r.keys,", ")}`;case"invalid_key":return`${r.origin} \u4E2D\u7684\u952E(key)\u65E0\u6548`;case"invalid_union":return"\u65E0\u6548\u8F93\u5165";case"invalid_element":return`${r.origin} \u4E2D\u5305\u542B\u65E0\u6548\u503C(value)`;default:return"\u65E0\u6548\u8F93\u5165"}}};function v_(){return{localeError:pI()}}var mI=()=>{let e={string:{unit:"\u5B57\u5143",verb:"\u64C1\u6709"},file:{unit:"\u4F4D\u5143\u7D44",verb:"\u64C1\u6709"},array:{unit:"\u9805\u76EE",verb:"\u64C1\u6709"},set:{unit:"\u9805\u76EE",verb:"\u64C1\u6709"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"number";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u8F38\u5165",email:"\u90F5\u4EF6\u5730\u5740",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u65E5\u671F\u6642\u9593",date:"ISO \u65E5\u671F",time:"ISO \u6642\u9593",duration:"ISO \u671F\u9593",ipv4:"IPv4 \u4F4D\u5740",ipv6:"IPv6 \u4F4D\u5740",cidrv4:"IPv4 \u7BC4\u570D",cidrv6:"IPv6 \u7BC4\u570D",base64:"base64 \u7DE8\u78BC\u5B57\u4E32",base64url:"base64url \u7DE8\u78BC\u5B57\u4E32",json_string:"JSON \u5B57\u4E32",e164:"E.164 \u6578\u503C",jwt:"JWT",template_literal:"\u8F38\u5165"};return r=>{switch(r.code){case"invalid_type":return`\u7121\u6548\u7684\u8F38\u5165\u503C\uFF1A\u9810\u671F\u70BA ${r.expected}\uFF0C\u4F46\u6536\u5230 ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u7121\u6548\u7684\u8F38\u5165\u503C\uFF1A\u9810\u671F\u70BA ${j(r.values[0])}`:`\u7121\u6548\u7684\u9078\u9805\uFF1A\u9810\u671F\u70BA\u4EE5\u4E0B\u5176\u4E2D\u4E4B\u4E00 ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u6578\u503C\u904E\u5927\uFF1A\u9810\u671F ${r.origin??"\u503C"} \u61C9\u70BA ${i}${r.maximum.toString()} ${a.unit??"\u500B\u5143\u7D20"}`:`\u6578\u503C\u904E\u5927\uFF1A\u9810\u671F ${r.origin??"\u503C"} \u61C9\u70BA ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u6578\u503C\u904E\u5C0F\uFF1A\u9810\u671F ${r.origin} \u61C9\u70BA ${i}${r.minimum.toString()} ${a.unit}`:`\u6578\u503C\u904E\u5C0F\uFF1A\u9810\u671F ${r.origin} \u61C9\u70BA ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u4EE5 "${i.prefix}" \u958B\u982D`:i.format==="ends_with"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u4EE5 "${i.suffix}" \u7D50\u5C3E`:i.format==="includes"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u5305\u542B "${i.includes}"`:i.format==="regex"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u7B26\u5408\u683C\u5F0F ${i.pattern}`:`\u7121\u6548\u7684 ${o[i.format]??r.format}`}case"not_multiple_of":return`\u7121\u6548\u7684\u6578\u5B57\uFF1A\u5FC5\u9808\u70BA ${r.divisor} \u7684\u500D\u6578`;case"unrecognized_keys":return`\u7121\u6CD5\u8B58\u5225\u7684\u9375\u503C${r.keys.length>1?"\u5011":""}\uFF1A${S(r.keys,"\u3001")}`;case"invalid_key":return`${r.origin} \u4E2D\u6709\u7121\u6548\u7684\u9375\u503C`;case"invalid_union":return"\u7121\u6548\u7684\u8F38\u5165\u503C";case"invalid_element":return`${r.origin} \u4E2D\u6709\u7121\u6548\u7684\u503C`;default:return"\u7121\u6548\u7684\u8F38\u5165\u503C"}}};function __(){return{localeError:mI()}}var hI=()=>{let e={string:{unit:"\xE0mi",verb:"n\xED"},file:{unit:"bytes",verb:"n\xED"},array:{unit:"nkan",verb:"n\xED"},set:{unit:"nkan",verb:"n\xED"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"n\u1ECD\u0301mb\xE0";case"object":{if(Array.isArray(r))return"akop\u1ECD";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u1EB9\u0300r\u1ECD \xECb\xE1w\u1ECDl\xE9",email:"\xE0d\xEDr\u1EB9\u0301s\xEC \xECm\u1EB9\u0301l\xEC",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\xE0k\xF3k\xF2 ISO",date:"\u1ECDj\u1ECD\u0301 ISO",time:"\xE0k\xF3k\xF2 ISO",duration:"\xE0k\xF3k\xF2 t\xF3 p\xE9 ISO",ipv4:"\xE0d\xEDr\u1EB9\u0301s\xEC IPv4",ipv6:"\xE0d\xEDr\u1EB9\u0301s\xEC IPv6",cidrv4:"\xE0gb\xE8gb\xE8 IPv4",cidrv6:"\xE0gb\xE8gb\xE8 IPv6",base64:"\u1ECD\u0300r\u1ECD\u0300 t\xED a k\u1ECD\u0301 n\xED base64",base64url:"\u1ECD\u0300r\u1ECD\u0300 base64url",json_string:"\u1ECD\u0300r\u1ECD\u0300 JSON",e164:"n\u1ECD\u0301mb\xE0 E.164",jwt:"JWT",template_literal:"\u1EB9\u0300r\u1ECD \xECb\xE1w\u1ECDl\xE9"};return r=>{switch(r.code){case"invalid_type":return`\xCCb\xE1w\u1ECDl\xE9 a\u1E63\xEC\u1E63e: a n\xED l\xE1ti fi ${r.expected}, \xE0m\u1ECD\u0300 a r\xED ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\xCCb\xE1w\u1ECDl\xE9 a\u1E63\xEC\u1E63e: a n\xED l\xE1ti fi ${j(r.values[0])}`:`\xC0\u1E63\xE0y\xE0n a\u1E63\xEC\u1E63e: yan \u1ECD\u0300kan l\xE1ra ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`T\xF3 p\u1ECD\u0300 j\xF9: a n\xED l\xE1ti j\u1EB9\u0301 p\xE9 ${r.origin??"iye"} ${a.verb} ${i}${r.maximum} ${a.unit}`:`T\xF3 p\u1ECD\u0300 j\xF9: a n\xED l\xE1ti j\u1EB9\u0301 ${i}${r.maximum}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`K\xE9r\xE9 ju: a n\xED l\xE1ti j\u1EB9\u0301 p\xE9 ${r.origin} ${a.verb} ${i}${r.minimum} ${a.unit}`:`K\xE9r\xE9 ju: a n\xED l\xE1ti j\u1EB9\u0301 ${i}${r.minimum}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u1ECC\u0300r\u1ECD\u0300 a\u1E63\xEC\u1E63e: gb\u1ECD\u0301d\u1ECD\u0300 b\u1EB9\u0300r\u1EB9\u0300 p\u1EB9\u0300l\xFA "${i.prefix}"`:i.format==="ends_with"?`\u1ECC\u0300r\u1ECD\u0300 a\u1E63\xEC\u1E63e: gb\u1ECD\u0301d\u1ECD\u0300 par\xED p\u1EB9\u0300l\xFA "${i.suffix}"`:i.format==="includes"?`\u1ECC\u0300r\u1ECD\u0300 a\u1E63\xEC\u1E63e: gb\u1ECD\u0301d\u1ECD\u0300 n\xED "${i.includes}"`:i.format==="regex"?`\u1ECC\u0300r\u1ECD\u0300 a\u1E63\xEC\u1E63e: gb\u1ECD\u0301d\u1ECD\u0300 b\xE1 \xE0p\u1EB9\u1EB9r\u1EB9 mu ${i.pattern}`:`A\u1E63\xEC\u1E63e: ${o[i.format]??r.format}`}case"not_multiple_of":return`N\u1ECD\u0301mb\xE0 a\u1E63\xEC\u1E63e: gb\u1ECD\u0301d\u1ECD\u0300 j\u1EB9\u0301 \xE8y\xE0 p\xEDp\xEDn ti ${r.divisor}`;case"unrecognized_keys":return`B\u1ECDt\xECn\xEC \xE0\xECm\u1ECD\u0300: ${S(r.keys,", ")}`;case"invalid_key":return`B\u1ECDt\xECn\xEC a\u1E63\xEC\u1E63e n\xEDn\xFA ${r.origin}`;case"invalid_union":return"\xCCb\xE1w\u1ECDl\xE9 a\u1E63\xEC\u1E63e";case"invalid_element":return`Iye a\u1E63\xEC\u1E63e n\xEDn\xFA ${r.origin}`;default:return"\xCCb\xE1w\u1ECDl\xE9 a\u1E63\xEC\u1E63e"}}};function y_(){return{localeError:hI()}}var Tc=Symbol("ZodOutput"),Pc=Symbol("ZodInput"),Kn=class{constructor(){this._map=new WeakMap,this._idmap=new Map}add(t,...n){let o=n[0];if(this._map.set(t,o),o&&typeof o=="object"&&"id"in o){if(this._idmap.has(o.id))throw new Error(`ID ${o.id} already exists in the registry`);this._idmap.set(o.id,t)}return this}clear(){return this._map=new WeakMap,this._idmap=new Map,this}remove(t){let n=this._map.get(t);return n&&typeof n=="object"&&"id"in n&&this._idmap.delete(n.id),this._map.delete(t),this}get(t){let n=t._zod.parent;if(n){let o={...this.get(n)??{}};delete o.id;let r={...o,...this._map.get(t)};return Object.keys(r).length?r:void 0}return this._map.get(t)}has(t){return this._map.has(t)}};function gi(){return new Kn}var Tt=gi();function Oc(e,t){return new e({type:"string",...N(t)})}function jc(e,t){return new e({type:"string",coerce:!0,...N(t)})}function vi(e,t){return new e({type:"string",format:"email",check:"string_format",abort:!1,...N(t)})}function Hn(e,t){return new e({type:"string",format:"guid",check:"string_format",abort:!1,...N(t)})}function _i(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,...N(t)})}function yi(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v4",...N(t)})}function bi(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v6",...N(t)})}function $i(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v7",...N(t)})}function Jn(e,t){return new e({type:"string",format:"url",check:"string_format",abort:!1,...N(t)})}function xi(e,t){return new e({type:"string",format:"emoji",check:"string_format",abort:!1,...N(t)})}function wi(e,t){return new e({type:"string",format:"nanoid",check:"string_format",abort:!1,...N(t)})}function ki(e,t){return new e({type:"string",format:"cuid",check:"string_format",abort:!1,...N(t)})}function Si(e,t){return new e({type:"string",format:"cuid2",check:"string_format",abort:!1,...N(t)})}function zi(e,t){return new e({type:"string",format:"ulid",check:"string_format",abort:!1,...N(t)})}function Ii(e,t){return new e({type:"string",format:"xid",check:"string_format",abort:!1,...N(t)})}function Ei(e,t){return new e({type:"string",format:"ksuid",check:"string_format",abort:!1,...N(t)})}function Ti(e,t){return new e({type:"string",format:"ipv4",check:"string_format",abort:!1,...N(t)})}function Pi(e,t){return new e({type:"string",format:"ipv6",check:"string_format",abort:!1,...N(t)})}function Oi(e,t){return new e({type:"string",format:"cidrv4",check:"string_format",abort:!1,...N(t)})}function ji(e,t){return new e({type:"string",format:"cidrv6",check:"string_format",abort:!1,...N(t)})}function Ni(e,t){return new e({type:"string",format:"base64",check:"string_format",abort:!1,...N(t)})}function Ri(e,t){return new e({type:"string",format:"base64url",check:"string_format",abort:!1,...N(t)})}function Ai(e,t){return new e({type:"string",format:"e164",check:"string_format",abort:!1,...N(t)})}function Di(e,t){return new e({type:"string",format:"jwt",check:"string_format",abort:!1,...N(t)})}var Nc={Any:null,Minute:-1,Second:0,Millisecond:3,Microsecond:6};function Rc(e,t){return new e({type:"string",format:"datetime",check:"string_format",offset:!1,local:!1,precision:null,...N(t)})}function Ac(e,t){return new e({type:"string",format:"date",check:"string_format",...N(t)})}function Dc(e,t){return new e({type:"string",format:"time",check:"string_format",precision:null,...N(t)})}function Cc(e,t){return new e({type:"string",format:"duration",check:"string_format",...N(t)})}function Uc(e,t){return new e({type:"number",checks:[],...N(t)})}function Zc(e,t){return new e({type:"number",coerce:!0,checks:[],...N(t)})}function Mc(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"safeint",...N(t)})}function Lc(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"float32",...N(t)})}function qc(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"float64",...N(t)})}function Vc(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"int32",...N(t)})}function Fc(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"uint32",...N(t)})}function Bc(e,t){return new e({type:"boolean",...N(t)})}function Kc(e,t){return new e({type:"boolean",coerce:!0,...N(t)})}function Hc(e,t){return new e({type:"bigint",...N(t)})}function Jc(e,t){return new e({type:"bigint",coerce:!0,...N(t)})}function Gc(e,t){return new e({type:"bigint",check:"bigint_format",abort:!1,format:"int64",...N(t)})}function Wc(e,t){return new e({type:"bigint",check:"bigint_format",abort:!1,format:"uint64",...N(t)})}function Xc(e,t){return new e({type:"symbol",...N(t)})}function Yc(e,t){return new e({type:"undefined",...N(t)})}function Qc(e,t){return new e({type:"null",...N(t)})}function eu(e){return new e({type:"any"})}function tu(e){return new e({type:"unknown"})}function ru(e,t){return new e({type:"never",...N(t)})}function nu(e,t){return new e({type:"void",...N(t)})}function ou(e,t){return new e({type:"date",...N(t)})}function iu(e,t){return new e({type:"date",coerce:!0,...N(t)})}function au(e,t){return new e({type:"nan",...N(t)})}function Zt(e,t){return new ps({check:"less_than",...N(t),value:e,inclusive:!1})}function rt(e,t){return new ps({check:"less_than",...N(t),value:e,inclusive:!0})}function Mt(e,t){return new ms({check:"greater_than",...N(t),value:e,inclusive:!1})}function Ve(e,t){return new ms({check:"greater_than",...N(t),value:e,inclusive:!0})}function su(e){return Mt(0,e)}function cu(e){return Zt(0,e)}function uu(e){return rt(0,e)}function lu(e){return Ve(0,e)}function Sr(e,t){return new hf({check:"multiple_of",...N(t),value:e})}function Xr(e,t){return new _f({check:"max_size",...N(t),maximum:e})}function zr(e,t){return new yf({check:"min_size",...N(t),minimum:e})}function Gn(e,t){return new bf({check:"size_equals",...N(t),size:e})}function Yr(e,t){return new $f({check:"max_length",...N(t),maximum:e})}function tr(e,t){return new xf({check:"min_length",...N(t),minimum:e})}function Qr(e,t){return new wf({check:"length_equals",...N(t),length:e})}function Wn(e,t){return new kf({check:"string_format",format:"regex",...N(t),pattern:e})}function Xn(e){return new Sf({check:"string_format",format:"lowercase",...N(e)})}function Yn(e){return new zf({check:"string_format",format:"uppercase",...N(e)})}function Qn(e,t){return new If({check:"string_format",format:"includes",...N(t),includes:e})}function eo(e,t){return new Ef({check:"string_format",format:"starts_with",...N(t),prefix:e})}function to(e,t){return new Tf({check:"string_format",format:"ends_with",...N(t),suffix:e})}function du(e,t,n){return new Pf({check:"property",property:e,schema:t,...N(n)})}function ro(e,t){return new Of({check:"mime_type",mime:e,...N(t)})}function Lt(e){return new jf({check:"overwrite",tx:e})}function no(e){return Lt(t=>t.normalize(e))}function oo(){return Lt(e=>e.trim())}function io(){return Lt(e=>e.toLowerCase())}function ao(){return Lt(e=>e.toUpperCase())}function Cf(e,t,n){return new e({type:"array",element:t,...N(n)})}function gI(e,t,n){return new e({type:"union",options:t,...N(n)})}function vI(e,t,n,o){return new e({type:"union",options:n,discriminator:t,...N(o)})}function _I(e,t,n){return new e({type:"intersection",left:t,right:n})}function yI(e,t,n,o){let r=n instanceof W,i=r?o:n,a=r?n:null;return new e({type:"tuple",items:t,rest:a,...N(i)})}function bI(e,t,n,o){return new e({type:"record",keyType:t,valueType:n,...N(o)})}function $I(e,t,n,o){return new e({type:"map",keyType:t,valueType:n,...N(o)})}function xI(e,t,n){return new e({type:"set",valueType:t,...N(n)})}function wI(e,t,n){let o=Array.isArray(t)?Object.fromEntries(t.map(r=>[r,r])):t;return new e({type:"enum",entries:o,...N(n)})}function kI(e,t,n){return new e({type:"enum",entries:t,...N(n)})}function SI(e,t,n){return new e({type:"literal",values:Array.isArray(t)?t:[t],...N(n)})}function fu(e,t){return new e({type:"file",...N(t)})}function zI(e,t){return new e({type:"transform",transform:t})}function II(e,t){return new e({type:"optional",innerType:t})}function EI(e,t){return new e({type:"nullable",innerType:t})}function TI(e,t,n){return new e({type:"default",innerType:t,get defaultValue(){return typeof n=="function"?n():Rd(n)}})}function PI(e,t,n){return new e({type:"nonoptional",innerType:t,...N(n)})}function OI(e,t){return new e({type:"success",innerType:t})}function jI(e,t,n){return new e({type:"catch",innerType:t,catchValue:typeof n=="function"?n:()=>n})}function NI(e,t,n){return new e({type:"pipe",in:t,out:n})}function RI(e,t){return new e({type:"readonly",innerType:t})}function AI(e,t,n){return new e({type:"template_literal",parts:t,...N(n)})}function DI(e,t){return new e({type:"lazy",getter:t})}function CI(e,t){return new e({type:"promise",innerType:t})}function pu(e,t,n){let o=N(n);return o.abort??(o.abort=!0),new e({type:"custom",check:"custom",fn:t,...o})}function mu(e,t,n){return new e({type:"custom",check:"custom",fn:t,...N(n)})}function hu(e){let t=b_(n=>(n.addIssue=o=>{if(typeof o=="string")n.issues.push(An(o,n.value,t._zod.def));else{let r=o;r.fatal&&(r.continue=!1),r.code??(r.code="custom"),r.input??(r.input=n.value),r.inst??(r.inst=t),r.continue??(r.continue=!t._zod.def.abort),n.issues.push(An(r))}},e(n.value,n)));return t}function b_(e,t){let n=new $e({check:"custom",...N(t)});return n._zod.check=e,n}function gu(e,t){let n=N(t),o=n.truthy??["true","1","yes","on","y","enabled"],r=n.falsy??["false","0","no","off","n","disabled"];n.case!=="sensitive"&&(o=o.map(v=>typeof v=="string"?v.toLowerCase():v),r=r.map(v=>typeof v=="string"?v.toLowerCase():v));let i=new Set(o),a=new Set(r),s=e.Codec??Fn,c=e.Boolean??Vn,l=e.String??kr,d=new l({type:"string",error:n.error}),f=new c({type:"boolean",error:n.error}),_=new s({type:"pipe",in:d,out:f,transform:((v,g)=>{let b=v;return n.case!=="sensitive"&&(b=b.toLowerCase()),i.has(b)?!0:a.has(b)?!1:(g.issues.push({code:"invalid_value",expected:"stringbool",values:[...i,...a],input:g.value,inst:_,continue:!1}),{})}),reverseTransform:((v,g)=>v===!0?o[0]||"true":r[0]||"false"),error:n.error});return _}function en(e,t,n,o={}){let r=N(o),i={...N(o),check:"string_format",type:"string",format:t,fn:typeof n=="function"?n:s=>n.test(s),...r};return n instanceof RegExp&&(i.pattern=n),new e(i)}var Ci=class{constructor(t){this.counter=0,this.metadataRegistry=t?.metadata??Tt,this.target=t?.target??"draft-2020-12",this.unrepresentable=t?.unrepresentable??"throw",this.override=t?.override??(()=>{}),this.io=t?.io??"output",this.seen=new Map}process(t,n={path:[],schemaPath:[]}){var o;let r=t._zod.def,i={guid:"uuid",url:"uri",datetime:"date-time",json_string:"json-string",regex:""},a=this.seen.get(t);if(a)return a.count++,n.schemaPath.includes(t)&&(a.cycle=n.path),a.schema;let s={schema:{},count:1,cycle:void 0,path:n.path};this.seen.set(t,s);let c=t._zod.toJSONSchema?.();if(c)s.schema=c;else{let f={...n,schemaPath:[...n.schemaPath,t],path:n.path},_=t._zod.parent;if(_)s.ref=_,this.process(_,f),this.seen.get(_).isParent=!0;else{let v=s.schema;switch(r.type){case"string":{let g=v;g.type="string";let{minimum:b,maximum:x,format:I,patterns:R,contentEncoding:P}=t._zod.bag;if(typeof b=="number"&&(g.minLength=b),typeof x=="number"&&(g.maxLength=x),I&&(g.format=i[I]??I,g.format===""&&delete g.format),P&&(g.contentEncoding=P),R&&R.size>0){let M=[...R];M.length===1?g.pattern=M[0].source:M.length>1&&(s.schema.allOf=[...M.map(V=>({...this.target==="draft-7"||this.target==="draft-4"||this.target==="openapi-3.0"?{type:"string"}:{},pattern:V.source}))])}break}case"number":{let g=v,{minimum:b,maximum:x,format:I,multipleOf:R,exclusiveMaximum:P,exclusiveMinimum:M}=t._zod.bag;typeof I=="string"&&I.includes("int")?g.type="integer":g.type="number",typeof M=="number"&&(this.target==="draft-4"||this.target==="openapi-3.0"?(g.minimum=M,g.exclusiveMinimum=!0):g.exclusiveMinimum=M),typeof b=="number"&&(g.minimum=b,typeof M=="number"&&this.target!=="draft-4"&&(M>=b?delete g.minimum:delete g.exclusiveMinimum)),typeof P=="number"&&(this.target==="draft-4"||this.target==="openapi-3.0"?(g.maximum=P,g.exclusiveMaximum=!0):g.exclusiveMaximum=P),typeof x=="number"&&(g.maximum=x,typeof P=="number"&&this.target!=="draft-4"&&(P<=x?delete g.maximum:delete g.exclusiveMaximum)),typeof R=="number"&&(g.multipleOf=R);break}case"boolean":{let g=v;g.type="boolean";break}case"bigint":{if(this.unrepresentable==="throw")throw new Error("BigInt cannot be represented in JSON Schema");break}case"symbol":{if(this.unrepresentable==="throw")throw new Error("Symbols cannot be represented in JSON Schema");break}case"null":{this.target==="openapi-3.0"?(v.type="string",v.nullable=!0,v.enum=[null]):v.type="null";break}case"any":break;case"unknown":break;case"undefined":{if(this.unrepresentable==="throw")throw new Error("Undefined cannot be represented in JSON Schema");break}case"void":{if(this.unrepresentable==="throw")throw new Error("Void cannot be represented in JSON Schema");break}case"never":{v.not={};break}case"date":{if(this.unrepresentable==="throw")throw new Error("Date cannot be represented in JSON Schema");break}case"array":{let g=v,{minimum:b,maximum:x}=t._zod.bag;typeof b=="number"&&(g.minItems=b),typeof x=="number"&&(g.maxItems=x),g.type="array",g.items=this.process(r.element,{...f,path:[...f.path,"items"]});break}case"object":{let g=v;g.type="object",g.properties={};let b=r.shape;for(let R in b)g.properties[R]=this.process(b[R],{...f,path:[...f.path,"properties",R]});let x=new Set(Object.keys(b)),I=new Set([...x].filter(R=>{let P=r.shape[R]._zod;return this.io==="input"?P.optin===void 0:P.optout===void 0}));I.size>0&&(g.required=Array.from(I)),r.catchall?._zod.def.type==="never"?g.additionalProperties=!1:r.catchall?r.catchall&&(g.additionalProperties=this.process(r.catchall,{...f,path:[...f.path,"additionalProperties"]})):this.io==="output"&&(g.additionalProperties=!1);break}case"union":{let g=v,b=r.options.map((x,I)=>this.process(x,{...f,path:[...f.path,"anyOf",I]}));g.anyOf=b;break}case"intersection":{let g=v,b=this.process(r.left,{...f,path:[...f.path,"allOf",0]}),x=this.process(r.right,{...f,path:[...f.path,"allOf",1]}),I=P=>"allOf"in P&&Object.keys(P).length===1,R=[...I(b)?b.allOf:[b],...I(x)?x.allOf:[x]];g.allOf=R;break}case"tuple":{let g=v;g.type="array";let b=this.target==="draft-2020-12"?"prefixItems":"items",x=this.target==="draft-2020-12"||this.target==="openapi-3.0"?"items":"additionalItems",I=r.items.map((V,Me)=>this.process(V,{...f,path:[...f.path,b,Me]})),R=r.rest?this.process(r.rest,{...f,path:[...f.path,x,...this.target==="openapi-3.0"?[r.items.length]:[]]}):null;this.target==="draft-2020-12"?(g.prefixItems=I,R&&(g.items=R)):this.target==="openapi-3.0"?(g.items={anyOf:I},R&&g.items.anyOf.push(R),g.minItems=I.length,R||(g.maxItems=I.length)):(g.items=I,R&&(g.additionalItems=R));let{minimum:P,maximum:M}=t._zod.bag;typeof P=="number"&&(g.minItems=P),typeof M=="number"&&(g.maxItems=M);break}case"record":{let g=v;g.type="object",(this.target==="draft-7"||this.target==="draft-2020-12")&&(g.propertyNames=this.process(r.keyType,{...f,path:[...f.path,"propertyNames"]})),g.additionalProperties=this.process(r.valueType,{...f,path:[...f.path,"additionalProperties"]});break}case"map":{if(this.unrepresentable==="throw")throw new Error("Map cannot be represented in JSON Schema");break}case"set":{if(this.unrepresentable==="throw")throw new Error("Set cannot be represented in JSON Schema");break}case"enum":{let g=v,b=ti(r.entries);b.every(x=>typeof x=="number")&&(g.type="number"),b.every(x=>typeof x=="string")&&(g.type="string"),g.enum=b;break}case"literal":{let g=v,b=[];for(let x of r.values)if(x===void 0){if(this.unrepresentable==="throw")throw new Error("Literal `undefined` cannot be represented in JSON Schema")}else if(typeof x=="bigint"){if(this.unrepresentable==="throw")throw new Error("BigInt literals cannot be represented in JSON Schema");b.push(Number(x))}else b.push(x);if(b.length!==0)if(b.length===1){let x=b[0];g.type=x===null?"null":typeof x,this.target==="draft-4"||this.target==="openapi-3.0"?g.enum=[x]:g.const=x}else b.every(x=>typeof x=="number")&&(g.type="number"),b.every(x=>typeof x=="string")&&(g.type="string"),b.every(x=>typeof x=="boolean")&&(g.type="string"),b.every(x=>x===null)&&(g.type="null"),g.enum=b;break}case"file":{let g=v,b={type:"string",format:"binary",contentEncoding:"binary"},{minimum:x,maximum:I,mime:R}=t._zod.bag;x!==void 0&&(b.minLength=x),I!==void 0&&(b.maxLength=I),R?R.length===1?(b.contentMediaType=R[0],Object.assign(g,b)):g.anyOf=R.map(P=>({...b,contentMediaType:P})):Object.assign(g,b);break}case"transform":{if(this.unrepresentable==="throw")throw new Error("Transforms cannot be represented in JSON Schema");break}case"nullable":{let g=this.process(r.innerType,f);this.target==="openapi-3.0"?(s.ref=r.innerType,v.nullable=!0):v.anyOf=[g,{type:"null"}];break}case"nonoptional":{this.process(r.innerType,f),s.ref=r.innerType;break}case"success":{let g=v;g.type="boolean";break}case"default":{this.process(r.innerType,f),s.ref=r.innerType,v.default=JSON.parse(JSON.stringify(r.defaultValue));break}case"prefault":{this.process(r.innerType,f),s.ref=r.innerType,this.io==="input"&&(v._prefault=JSON.parse(JSON.stringify(r.defaultValue)));break}case"catch":{this.process(r.innerType,f),s.ref=r.innerType;let g;try{g=r.catchValue(void 0)}catch{throw new Error("Dynamic catch values are not supported in JSON Schema")}v.default=g;break}case"nan":{if(this.unrepresentable==="throw")throw new Error("NaN cannot be represented in JSON Schema");break}case"template_literal":{let g=v,b=t._zod.pattern;if(!b)throw new Error("Pattern not found in template literal");g.type="string",g.pattern=b.source;break}case"pipe":{let g=this.io==="input"?r.in._zod.def.type==="transform"?r.out:r.in:r.out;this.process(g,f),s.ref=g;break}case"readonly":{this.process(r.innerType,f),s.ref=r.innerType,v.readOnly=!0;break}case"promise":{this.process(r.innerType,f),s.ref=r.innerType;break}case"optional":{this.process(r.innerType,f),s.ref=r.innerType;break}case"lazy":{let g=t._zod.innerType;this.process(g,f),s.ref=g;break}case"custom":{if(this.unrepresentable==="throw")throw new Error("Custom types cannot be represented in JSON Schema");break}case"function":{if(this.unrepresentable==="throw")throw new Error("Function types cannot be represented in JSON Schema");break}default:}}}let l=this.metadataRegistry.get(t);return l&&Object.assign(s.schema,l),this.io==="input"&&je(t)&&(delete s.schema.examples,delete s.schema.default),this.io==="input"&&s.schema._prefault&&((o=s.schema).default??(o.default=s.schema._prefault)),delete s.schema._prefault,this.seen.get(t).schema}emit(t,n){let o={cycles:n?.cycles??"ref",reused:n?.reused??"inline",external:n?.external??void 0},r=this.seen.get(t);if(!r)throw new Error("Unprocessed schema. This is a bug in Zod.");let i=d=>{let f=this.target==="draft-2020-12"?"$defs":"definitions";if(o.external){let b=o.external.registry.get(d[0])?.id,x=o.external.uri??(R=>R);if(b)return{ref:x(b)};let I=d[1].defId??d[1].schema.id??`schema${this.counter++}`;return d[1].defId=I,{defId:I,ref:`${x("__shared")}#/${f}/${I}`}}if(d[1]===r)return{ref:"#"};let v=`#/${f}/`,g=d[1].schema.id??`__schema${this.counter++}`;return{defId:g,ref:v+g}},a=d=>{if(d[1].schema.$ref)return;let f=d[1],{ref:_,defId:v}=i(d);f.def={...f.schema},v&&(f.defId=v);let g=f.schema;for(let b in g)delete g[b];g.$ref=_};if(o.cycles==="throw")for(let d of this.seen.entries()){let f=d[1];if(f.cycle)throw new Error(`Cycle detected: #/${f.cycle?.join("/")}/<root>
|
|
54
|
+
`)}v.write("payload.value = newResult;"),v.write("return payload;");let R=v.compile();return(O,M)=>R(_,O,M)},i,a=Hr,s=!Yo.jitless,l=s&&Ad.value,d=t.catchall,f;e._zod.parse=(_,v)=>{f??(f=o.value);let g=_.value;return a(g)?s&&l&&v?.async===!1&&v.jitless!==!0?(i||(i=r(t.shape)),_=i(_,v),d?Ov([],g,_,v,f,e):_):n(_,v):(_.issues.push({expected:"object",code:"invalid_type",input:g,inst:e}),_)}});function _v(e,t,n,o){for(let i of e)if(i.issues.length===0)return t.value=i.value,t;let r=e.filter(i=>!$r(i));return r.length===1?(t.value=r[0].value,r[0]):(t.issues.push({code:"invalid_union",input:t.value,inst:n,errors:e.map(i=>i.issues.map(a=>ft(a,o,Ee())))}),t)}var fi=$("$ZodUnion",(e,t)=>{W.init(e,t),se(e._zod,"optin",()=>t.options.some(r=>r._zod.optin==="optional")?"optional":void 0),se(e._zod,"optout",()=>t.options.some(r=>r._zod.optout==="optional")?"optional":void 0),se(e._zod,"values",()=>{if(t.options.every(r=>r._zod.values))return new Set(t.options.flatMap(r=>Array.from(r._zod.values)))}),se(e._zod,"pattern",()=>{if(t.options.every(r=>r._zod.pattern)){let r=t.options.map(i=>i._zod.pattern);return new RegExp(`^(${r.map(i=>ri(i.source)).join("|")})$`)}});let n=t.options.length===1,o=t.options[0]._zod.run;e._zod.parse=(r,i)=>{if(n)return o(r,i);let a=!1,s=[];for(let c of t.options){let l=c._zod.run({value:r.value,issues:[]},i);if(l instanceof Promise)s.push(l),a=!0;else{if(l.issues.length===0)return l;s.push(l)}}return a?Promise.all(s).then(c=>_v(c,r,e,i)):_v(s,r,e,i)}}),nc=$("$ZodDiscriminatedUnion",(e,t)=>{fi.init(e,t);let n=e._zod.parse;se(e._zod,"propValues",()=>{let r={};for(let i of t.options){let a=i._zod.propValues;if(!a||Object.keys(a).length===0)throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(i)}"`);for(let[s,c]of Object.entries(a)){r[s]||(r[s]=new Set);for(let l of c)r[s].add(l)}}return r});let o=Rn(()=>{let r=t.options,i=new Map;for(let a of r){let s=a._zod.propValues?.[t.discriminator];if(!s||s.size===0)throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(a)}"`);for(let c of s){if(i.has(c))throw new Error(`Duplicate discriminator value "${String(c)}"`);i.set(c,a)}}return i});e._zod.parse=(r,i)=>{let a=r.value;if(!Hr(a))return r.issues.push({code:"invalid_type",expected:"object",input:a,inst:e}),r;let s=o.value.get(a?.[t.discriminator]);return s?s._zod.run(r,i):t.unionFallback?n(r,i):(r.issues.push({code:"invalid_union",errors:[],note:"No matching discriminator",discriminator:t.discriminator,input:a,path:[t.discriminator],inst:e}),r)}}),oc=$("$ZodIntersection",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{let r=n.value,i=t.left._zod.run({value:r,issues:[]},o),a=t.right._zod.run({value:r,issues:[]},o);return i instanceof Promise||a instanceof Promise?Promise.all([i,a]).then(([c,l])=>yv(n,c,l)):yv(n,i,a)}});function Df(e,t){if(e===t)return{valid:!0,data:e};if(e instanceof Date&&t instanceof Date&&+e==+t)return{valid:!0,data:e};if(br(e)&&br(t)){let n=Object.keys(t),o=Object.keys(e).filter(i=>n.indexOf(i)!==-1),r={...e,...t};for(let i of o){let a=Df(e[i],t[i]);if(!a.valid)return{valid:!1,mergeErrorPath:[i,...a.mergeErrorPath]};r[i]=a.data}return{valid:!0,data:r}}if(Array.isArray(e)&&Array.isArray(t)){if(e.length!==t.length)return{valid:!1,mergeErrorPath:[]};let n=[];for(let o=0;o<e.length;o++){let r=e[o],i=t[o],a=Df(r,i);if(!a.valid)return{valid:!1,mergeErrorPath:[o,...a.mergeErrorPath]};n.push(a.data)}return{valid:!0,data:n}}return{valid:!1,mergeErrorPath:[]}}function yv(e,t,n){if(t.issues.length&&e.issues.push(...t.issues),n.issues.length&&e.issues.push(...n.issues),$r(e))return e;let o=Df(t.value,n.value);if(!o.valid)throw new Error(`Unmergable intersection. Error path: ${JSON.stringify(o.mergeErrorPath)}`);return e.value=o.data,e}var pi=$("$ZodTuple",(e,t)=>{W.init(e,t);let n=t.items,o=n.length-[...n].reverse().findIndex(r=>r._zod.optin!=="optional");e._zod.parse=(r,i)=>{let a=r.value;if(!Array.isArray(a))return r.issues.push({input:a,inst:e,expected:"tuple",code:"invalid_type"}),r;r.value=[];let s=[];if(!t.rest){let l=a.length>n.length,d=a.length<o-1;if(l||d)return r.issues.push({...l?{code:"too_big",maximum:n.length}:{code:"too_small",minimum:n.length},input:a,inst:e,origin:"array"}),r}let c=-1;for(let l of n){if(c++,c>=a.length&&c>=o)continue;let d=l._zod.run({value:a[c],issues:[]},i);d instanceof Promise?s.push(d.then(f=>gs(f,r,c))):gs(d,r,c)}if(t.rest){let l=a.slice(n.length);for(let d of l){c++;let f=t.rest._zod.run({value:d,issues:[]},i);f instanceof Promise?s.push(f.then(_=>gs(_,r,c))):gs(f,r,c)}}return s.length?Promise.all(s).then(()=>r):r}});function gs(e,t,n){e.issues.length&&t.issues.push(...dt(n,e.issues)),t.value[n]=e.value}var ic=$("$ZodRecord",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{let r=n.value;if(!br(r))return n.issues.push({expected:"record",code:"invalid_type",input:r,inst:e}),n;let i=[];if(t.keyType._zod.values){let a=t.keyType._zod.values;n.value={};for(let c of a)if(typeof c=="string"||typeof c=="number"||typeof c=="symbol"){let l=t.valueType._zod.run({value:r[c],issues:[]},o);l instanceof Promise?i.push(l.then(d=>{d.issues.length&&n.issues.push(...dt(c,d.issues)),n.value[c]=d.value})):(l.issues.length&&n.issues.push(...dt(c,l.issues)),n.value[c]=l.value)}let s;for(let c in r)a.has(c)||(s=s??[],s.push(c));s&&s.length>0&&n.issues.push({code:"unrecognized_keys",input:r,inst:e,keys:s})}else{n.value={};for(let a of Reflect.ownKeys(r)){if(a==="__proto__")continue;let s=t.keyType._zod.run({value:a,issues:[]},o);if(s instanceof Promise)throw new Error("Async schemas not supported in object keys currently");if(s.issues.length){n.issues.push({code:"invalid_key",origin:"record",issues:s.issues.map(l=>ft(l,o,Ee())),input:a,path:[a],inst:e}),n.value[s.value]=s.value;continue}let c=t.valueType._zod.run({value:r[a],issues:[]},o);c instanceof Promise?i.push(c.then(l=>{l.issues.length&&n.issues.push(...dt(a,l.issues)),n.value[s.value]=l.value})):(c.issues.length&&n.issues.push(...dt(a,c.issues)),n.value[s.value]=c.value)}}return i.length?Promise.all(i).then(()=>n):n}}),ac=$("$ZodMap",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{let r=n.value;if(!(r instanceof Map))return n.issues.push({expected:"map",code:"invalid_type",input:r,inst:e}),n;let i=[];n.value=new Map;for(let[a,s]of r){let c=t.keyType._zod.run({value:a,issues:[]},o),l=t.valueType._zod.run({value:s,issues:[]},o);c instanceof Promise||l instanceof Promise?i.push(Promise.all([c,l]).then(([d,f])=>{bv(d,f,n,a,r,e,o)})):bv(c,l,n,a,r,e,o)}return i.length?Promise.all(i).then(()=>n):n}});function bv(e,t,n,o,r,i,a){e.issues.length&&(ni.has(typeof o)?n.issues.push(...dt(o,e.issues)):n.issues.push({code:"invalid_key",origin:"map",input:r,inst:i,issues:e.issues.map(s=>ft(s,a,Ee()))})),t.issues.length&&(ni.has(typeof o)?n.issues.push(...dt(o,t.issues)):n.issues.push({origin:"map",code:"invalid_element",input:r,inst:i,key:o,issues:t.issues.map(s=>ft(s,a,Ee()))})),n.value.set(e.value,t.value)}var sc=$("$ZodSet",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{let r=n.value;if(!(r instanceof Set))return n.issues.push({input:r,inst:e,expected:"set",code:"invalid_type"}),n;let i=[];n.value=new Set;for(let a of r){let s=t.valueType._zod.run({value:a,issues:[]},o);s instanceof Promise?i.push(s.then(c=>$v(c,n))):$v(s,n)}return i.length?Promise.all(i).then(()=>n):n}});function $v(e,t){e.issues.length&&t.issues.push(...e.issues),t.value.add(e.value)}var cc=$("$ZodEnum",(e,t)=>{W.init(e,t);let n=ti(t.entries),o=new Set(n);e._zod.values=o,e._zod.pattern=new RegExp(`^(${n.filter(r=>ni.has(typeof r)).map(r=>typeof r=="string"?Ut(r):r.toString()).join("|")})$`),e._zod.parse=(r,i)=>{let a=r.value;return o.has(a)||r.issues.push({code:"invalid_value",values:n,input:a,inst:e}),r}}),uc=$("$ZodLiteral",(e,t)=>{if(W.init(e,t),t.values.length===0)throw new Error("Cannot create literal schema with no valid values");e._zod.values=new Set(t.values),e._zod.pattern=new RegExp(`^(${t.values.map(n=>typeof n=="string"?Ut(n):n?Ut(n.toString()):String(n)).join("|")})$`),e._zod.parse=(n,o)=>{let r=n.value;return e._zod.values.has(r)||n.issues.push({code:"invalid_value",values:t.values,input:r,inst:e}),n}}),lc=$("$ZodFile",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{let r=n.value;return r instanceof File||n.issues.push({expected:"file",code:"invalid_type",input:r,inst:e}),n}}),dc=$("$ZodTransform",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{if(o.direction==="backward")throw new gr(e.constructor.name);let r=t.transform(n.value,n);if(o.async)return(r instanceof Promise?r:Promise.resolve(r)).then(a=>(n.value=a,n));if(r instanceof Promise)throw new Et;return n.value=r,n}});function xv(e,t){return e.issues.length&&t===void 0?{issues:[],value:void 0}:e}var fc=$("$ZodOptional",(e,t)=>{W.init(e,t),e._zod.optin="optional",e._zod.optout="optional",se(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,void 0]):void 0),se(e._zod,"pattern",()=>{let n=t.innerType._zod.pattern;return n?new RegExp(`^(${ri(n.source)})?$`):void 0}),e._zod.parse=(n,o)=>{if(t.innerType._zod.optin==="optional"){let r=t.innerType._zod.run(n,o);return r instanceof Promise?r.then(i=>xv(i,n.value)):xv(r,n.value)}return n.value===void 0?n:t.innerType._zod.run(n,o)}}),pc=$("$ZodNullable",(e,t)=>{W.init(e,t),se(e._zod,"optin",()=>t.innerType._zod.optin),se(e._zod,"optout",()=>t.innerType._zod.optout),se(e._zod,"pattern",()=>{let n=t.innerType._zod.pattern;return n?new RegExp(`^(${ri(n.source)}|null)$`):void 0}),se(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,null]):void 0),e._zod.parse=(n,o)=>n.value===null?n:t.innerType._zod.run(n,o)}),mc=$("$ZodDefault",(e,t)=>{W.init(e,t),e._zod.optin="optional",se(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(n,o)=>{if(o.direction==="backward")return t.innerType._zod.run(n,o);if(n.value===void 0)return n.value=t.defaultValue,n;let r=t.innerType._zod.run(n,o);return r instanceof Promise?r.then(i=>wv(i,t)):wv(r,t)}});function wv(e,t){return e.value===void 0&&(e.value=t.defaultValue),e}var hc=$("$ZodPrefault",(e,t)=>{W.init(e,t),e._zod.optin="optional",se(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(n,o)=>(o.direction==="backward"||n.value===void 0&&(n.value=t.defaultValue),t.innerType._zod.run(n,o))}),gc=$("$ZodNonOptional",(e,t)=>{W.init(e,t),se(e._zod,"values",()=>{let n=t.innerType._zod.values;return n?new Set([...n].filter(o=>o!==void 0)):void 0}),e._zod.parse=(n,o)=>{let r=t.innerType._zod.run(n,o);return r instanceof Promise?r.then(i=>kv(i,e)):kv(r,e)}});function kv(e,t){return!e.issues.length&&e.value===void 0&&e.issues.push({code:"invalid_type",expected:"nonoptional",input:e.value,inst:t}),e}var vc=$("$ZodSuccess",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>{if(o.direction==="backward")throw new gr("ZodSuccess");let r=t.innerType._zod.run(n,o);return r instanceof Promise?r.then(i=>(n.value=i.issues.length===0,n)):(n.value=r.issues.length===0,n)}}),_c=$("$ZodCatch",(e,t)=>{W.init(e,t),se(e._zod,"optin",()=>t.innerType._zod.optin),se(e._zod,"optout",()=>t.innerType._zod.optout),se(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(n,o)=>{if(o.direction==="backward")return t.innerType._zod.run(n,o);let r=t.innerType._zod.run(n,o);return r instanceof Promise?r.then(i=>(n.value=i.value,i.issues.length&&(n.value=t.catchValue({...n,error:{issues:i.issues.map(a=>ft(a,o,Ee()))},input:n.value}),n.issues=[]),n)):(n.value=r.value,r.issues.length&&(n.value=t.catchValue({...n,error:{issues:r.issues.map(i=>ft(i,o,Ee()))},input:n.value}),n.issues=[]),n)}}),yc=$("$ZodNaN",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>((typeof n.value!="number"||!Number.isNaN(n.value))&&n.issues.push({input:n.value,inst:e,expected:"nan",code:"invalid_type"}),n)}),bc=$("$ZodPipe",(e,t)=>{W.init(e,t),se(e._zod,"values",()=>t.in._zod.values),se(e._zod,"optin",()=>t.in._zod.optin),se(e._zod,"optout",()=>t.out._zod.optout),se(e._zod,"propValues",()=>t.in._zod.propValues),e._zod.parse=(n,o)=>{if(o.direction==="backward"){let i=t.out._zod.run(n,o);return i instanceof Promise?i.then(a=>vs(a,t.in,o)):vs(i,t.in,o)}let r=t.in._zod.run(n,o);return r instanceof Promise?r.then(i=>vs(i,t.out,o)):vs(r,t.out,o)}});function vs(e,t,n){return e.issues.length?(e.aborted=!0,e):t._zod.run({value:e.value,issues:e.issues},n)}var Fn=$("$ZodCodec",(e,t)=>{W.init(e,t),se(e._zod,"values",()=>t.in._zod.values),se(e._zod,"optin",()=>t.in._zod.optin),se(e._zod,"optout",()=>t.out._zod.optout),se(e._zod,"propValues",()=>t.in._zod.propValues),e._zod.parse=(n,o)=>{if((o.direction||"forward")==="forward"){let i=t.in._zod.run(n,o);return i instanceof Promise?i.then(a=>_s(a,t,o)):_s(i,t,o)}else{let i=t.out._zod.run(n,o);return i instanceof Promise?i.then(a=>_s(a,t,o)):_s(i,t,o)}}});function _s(e,t,n){if(e.issues.length)return e.aborted=!0,e;if((n.direction||"forward")==="forward"){let r=t.transform(e.value,e);return r instanceof Promise?r.then(i=>ys(e,i,t.out,n)):ys(e,r,t.out,n)}else{let r=t.reverseTransform(e.value,e);return r instanceof Promise?r.then(i=>ys(e,i,t.in,n)):ys(e,r,t.in,n)}}function ys(e,t,n,o){return e.issues.length?(e.aborted=!0,e):n._zod.run({value:t,issues:e.issues},o)}var $c=$("$ZodReadonly",(e,t)=>{W.init(e,t),se(e._zod,"propValues",()=>t.innerType._zod.propValues),se(e._zod,"values",()=>t.innerType._zod.values),se(e._zod,"optin",()=>t.innerType._zod.optin),se(e._zod,"optout",()=>t.innerType._zod.optout),e._zod.parse=(n,o)=>{if(o.direction==="backward")return t.innerType._zod.run(n,o);let r=t.innerType._zod.run(n,o);return r instanceof Promise?r.then(Sv):Sv(r)}});function Sv(e){return e.value=Object.freeze(e.value),e}var xc=$("$ZodTemplateLiteral",(e,t)=>{W.init(e,t);let n=[];for(let o of t.parts)if(typeof o=="object"&&o!==null){if(!o._zod.pattern)throw new Error(`Invalid template literal part, no pattern found: ${[...o._zod.traits].shift()}`);let r=o._zod.pattern instanceof RegExp?o._zod.pattern.source:o._zod.pattern;if(!r)throw new Error(`Invalid template literal part: ${o._zod.traits}`);let i=r.startsWith("^")?1:0,a=r.endsWith("$")?r.length-1:r.length;n.push(r.slice(i,a))}else if(o===null||Cd.has(typeof o))n.push(Ut(`${o}`));else throw new Error(`Invalid template literal part: ${o}`);e._zod.pattern=new RegExp(`^${n.join("")}$`),e._zod.parse=(o,r)=>typeof o.value!="string"?(o.issues.push({input:o.value,inst:e,expected:"template_literal",code:"invalid_type"}),o):(e._zod.pattern.lastIndex=0,e._zod.pattern.test(o.value)||o.issues.push({input:o.value,inst:e,code:"invalid_format",format:t.format??"template_literal",pattern:e._zod.pattern.source}),o)}),wc=$("$ZodFunction",(e,t)=>(W.init(e,t),e._def=t,e._zod.def=t,e.implement=n=>{if(typeof n!="function")throw new Error("implement() must be called with a function");return function(...o){let r=e._def.input?Jr(e._def.input,o):o,i=Reflect.apply(n,this,r);return e._def.output?Jr(e._def.output,i):i}},e.implementAsync=n=>{if(typeof n!="function")throw new Error("implementAsync() must be called with a function");return async function(...o){let r=e._def.input?await Gr(e._def.input,o):o,i=await Reflect.apply(n,this,r);return e._def.output?await Gr(e._def.output,i):i}},e._zod.parse=(n,o)=>typeof n.value!="function"?(n.issues.push({code:"invalid_type",expected:"function",input:n.value,inst:e}),n):(e._def.output&&e._def.output._zod.def.type==="promise"?n.value=e.implementAsync(n.value):n.value=e.implement(n.value),n),e.input=(...n)=>{let o=e.constructor;return Array.isArray(n[0])?new o({type:"function",input:new pi({type:"tuple",items:n[0],rest:n[1]}),output:e._def.output}):new o({type:"function",input:n[0],output:e._def.output})},e.output=n=>{let o=e.constructor;return new o({type:"function",input:e._def.input,output:n})},e)),kc=$("$ZodPromise",(e,t)=>{W.init(e,t),e._zod.parse=(n,o)=>Promise.resolve(n.value).then(r=>t.innerType._zod.run({value:r,issues:[]},o))}),Sc=$("$ZodLazy",(e,t)=>{W.init(e,t),se(e._zod,"innerType",()=>t.getter()),se(e._zod,"pattern",()=>e._zod.innerType._zod.pattern),se(e._zod,"propValues",()=>e._zod.innerType._zod.propValues),se(e._zod,"optin",()=>e._zod.innerType._zod.optin??void 0),se(e._zod,"optout",()=>e._zod.innerType._zod.optout??void 0),e._zod.parse=(n,o)=>e._zod.innerType._zod.run(n,o)}),zc=$("$ZodCustom",(e,t)=>{$e.init(e,t),W.init(e,t),e._zod.parse=(n,o)=>n,e._zod.check=n=>{let o=n.value,r=t.fn(o);if(r instanceof Promise)return r.then(i=>zv(i,n,o,e));zv(r,n,o,e)}});function zv(e,t,n,o){if(!e){let r={code:"custom",input:n,inst:o,path:[...o._zod.def.path??[]],continue:!o._zod.def.abort};o._zod.def.params&&(r.params=o._zod.def.params),t.issues.push(An(r))}}var Bn={};Fr(Bn,{ar:()=>Pv,az:()=>jv,be:()=>Rv,ca:()=>Av,cs:()=>Dv,da:()=>Cv,de:()=>Uv,en:()=>Ic,eo:()=>Zv,es:()=>Mv,fa:()=>Lv,fi:()=>qv,fr:()=>Vv,frCA:()=>Fv,he:()=>Bv,hu:()=>Kv,id:()=>Hv,is:()=>Jv,it:()=>Gv,ja:()=>Wv,ka:()=>Xv,kh:()=>Yv,km:()=>Ec,ko:()=>Qv,lt:()=>t_,mk:()=>r_,ms:()=>n_,nl:()=>o_,no:()=>i_,ota:()=>a_,pl:()=>c_,ps:()=>s_,pt:()=>u_,ru:()=>d_,sl:()=>f_,sv:()=>p_,ta:()=>m_,th:()=>h_,tr:()=>g_,ua:()=>v_,uk:()=>Tc,ur:()=>__,vi:()=>y_,yo:()=>x_,zhCN:()=>b_,zhTW:()=>$_});var Ez=()=>{let e={string:{unit:"\u062D\u0631\u0641",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"},file:{unit:"\u0628\u0627\u064A\u062A",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"},array:{unit:"\u0639\u0646\u0635\u0631",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"},set:{unit:"\u0639\u0646\u0635\u0631",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"number";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0645\u062F\u062E\u0644",email:"\u0628\u0631\u064A\u062F \u0625\u0644\u0643\u062A\u0631\u0648\u0646\u064A",url:"\u0631\u0627\u0628\u0637",emoji:"\u0625\u064A\u0645\u0648\u062C\u064A",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u062A\u0627\u0631\u064A\u062E \u0648\u0648\u0642\u062A \u0628\u0645\u0639\u064A\u0627\u0631 ISO",date:"\u062A\u0627\u0631\u064A\u062E \u0628\u0645\u0639\u064A\u0627\u0631 ISO",time:"\u0648\u0642\u062A \u0628\u0645\u0639\u064A\u0627\u0631 ISO",duration:"\u0645\u062F\u0629 \u0628\u0645\u0639\u064A\u0627\u0631 ISO",ipv4:"\u0639\u0646\u0648\u0627\u0646 IPv4",ipv6:"\u0639\u0646\u0648\u0627\u0646 IPv6",cidrv4:"\u0645\u062F\u0649 \u0639\u0646\u0627\u0648\u064A\u0646 \u0628\u0635\u064A\u063A\u0629 IPv4",cidrv6:"\u0645\u062F\u0649 \u0639\u0646\u0627\u0648\u064A\u0646 \u0628\u0635\u064A\u063A\u0629 IPv6",base64:"\u0646\u064E\u0635 \u0628\u062A\u0631\u0645\u064A\u0632 base64-encoded",base64url:"\u0646\u064E\u0635 \u0628\u062A\u0631\u0645\u064A\u0632 base64url-encoded",json_string:"\u0646\u064E\u0635 \u0639\u0644\u0649 \u0647\u064A\u0626\u0629 JSON",e164:"\u0631\u0642\u0645 \u0647\u0627\u062A\u0641 \u0628\u0645\u0639\u064A\u0627\u0631 E.164",jwt:"JWT",template_literal:"\u0645\u062F\u062E\u0644"};return r=>{switch(r.code){case"invalid_type":return`\u0645\u062F\u062E\u0644\u0627\u062A \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644\u0629: \u064A\u0641\u062A\u0631\u0636 \u0625\u062F\u062E\u0627\u0644 ${r.expected}\u060C \u0648\u0644\u0643\u0646 \u062A\u0645 \u0625\u062F\u062E\u0627\u0644 ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u0645\u062F\u062E\u0644\u0627\u062A \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644\u0629: \u064A\u0641\u062A\u0631\u0636 \u0625\u062F\u062E\u0627\u0644 ${j(r.values[0])}`:`\u0627\u062E\u062A\u064A\u0627\u0631 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062A\u0648\u0642\u0639 \u0627\u0646\u062A\u0642\u0627\u0621 \u0623\u062D\u062F \u0647\u0630\u0647 \u0627\u0644\u062E\u064A\u0627\u0631\u0627\u062A: ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?` \u0623\u0643\u0628\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0623\u0646 \u062A\u0643\u0648\u0646 ${r.origin??"\u0627\u0644\u0642\u064A\u0645\u0629"} ${i} ${r.maximum.toString()} ${a.unit??"\u0639\u0646\u0635\u0631"}`:`\u0623\u0643\u0628\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0623\u0646 \u062A\u0643\u0648\u0646 ${r.origin??"\u0627\u0644\u0642\u064A\u0645\u0629"} ${i} ${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u0623\u0635\u063A\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0644\u0640 ${r.origin} \u0623\u0646 \u064A\u0643\u0648\u0646 ${i} ${r.minimum.toString()} ${a.unit}`:`\u0623\u0635\u063A\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0644\u0640 ${r.origin} \u0623\u0646 \u064A\u0643\u0648\u0646 ${i} ${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0628\u062F\u0623 \u0628\u0640 "${r.prefix}"`:i.format==="ends_with"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0646\u062A\u0647\u064A \u0628\u0640 "${i.suffix}"`:i.format==="includes"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u062A\u0636\u0645\u0651\u064E\u0646 "${i.includes}"`:i.format==="regex"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0637\u0627\u0628\u0642 \u0627\u0644\u0646\u0645\u0637 ${i.pattern}`:`${o[i.format]??r.format} \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644`}case"not_multiple_of":return`\u0631\u0642\u0645 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0643\u0648\u0646 \u0645\u0646 \u0645\u0636\u0627\u0639\u0641\u0627\u062A ${r.divisor}`;case"unrecognized_keys":return`\u0645\u0639\u0631\u0641${r.keys.length>1?"\u0627\u062A":""} \u063A\u0631\u064A\u0628${r.keys.length>1?"\u0629":""}: ${S(r.keys,"\u060C ")}`;case"invalid_key":return`\u0645\u0639\u0631\u0641 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644 \u0641\u064A ${r.origin}`;case"invalid_union":return"\u0645\u062F\u062E\u0644 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644";case"invalid_element":return`\u0645\u062F\u062E\u0644 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644 \u0641\u064A ${r.origin}`;default:return"\u0645\u062F\u062E\u0644 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644"}}};function Pv(){return{localeError:Ez()}}var Tz=()=>{let e={string:{unit:"simvol",verb:"olmal\u0131d\u0131r"},file:{unit:"bayt",verb:"olmal\u0131d\u0131r"},array:{unit:"element",verb:"olmal\u0131d\u0131r"},set:{unit:"element",verb:"olmal\u0131d\u0131r"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"number";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"input",email:"email address",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datetime",date:"ISO date",time:"ISO time",duration:"ISO duration",ipv4:"IPv4 address",ipv6:"IPv6 address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded string",base64url:"base64url-encoded string",json_string:"JSON string",e164:"E.164 number",jwt:"JWT",template_literal:"input"};return r=>{switch(r.code){case"invalid_type":return`Yanl\u0131\u015F d\u0259y\u0259r: g\xF6zl\u0259nil\u0259n ${r.expected}, daxil olan ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Yanl\u0131\u015F d\u0259y\u0259r: g\xF6zl\u0259nil\u0259n ${j(r.values[0])}`:`Yanl\u0131\u015F se\xE7im: a\u015Fa\u011F\u0131dak\u0131lardan biri olmal\u0131d\u0131r: ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\xC7ox b\xF6y\xFCk: g\xF6zl\u0259nil\u0259n ${r.origin??"d\u0259y\u0259r"} ${i}${r.maximum.toString()} ${a.unit??"element"}`:`\xC7ox b\xF6y\xFCk: g\xF6zl\u0259nil\u0259n ${r.origin??"d\u0259y\u0259r"} ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\xC7ox ki\xE7ik: g\xF6zl\u0259nil\u0259n ${r.origin} ${i}${r.minimum.toString()} ${a.unit}`:`\xC7ox ki\xE7ik: g\xF6zl\u0259nil\u0259n ${r.origin} ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Yanl\u0131\u015F m\u0259tn: "${i.prefix}" il\u0259 ba\u015Flamal\u0131d\u0131r`:i.format==="ends_with"?`Yanl\u0131\u015F m\u0259tn: "${i.suffix}" il\u0259 bitm\u0259lidir`:i.format==="includes"?`Yanl\u0131\u015F m\u0259tn: "${i.includes}" daxil olmal\u0131d\u0131r`:i.format==="regex"?`Yanl\u0131\u015F m\u0259tn: ${i.pattern} \u015Fablonuna uy\u011Fun olmal\u0131d\u0131r`:`Yanl\u0131\u015F ${o[i.format]??r.format}`}case"not_multiple_of":return`Yanl\u0131\u015F \u0259d\u0259d: ${r.divisor} il\u0259 b\xF6l\xFCn\u0259 bil\u0259n olmal\u0131d\u0131r`;case"unrecognized_keys":return`Tan\u0131nmayan a\xE7ar${r.keys.length>1?"lar":""}: ${S(r.keys,", ")}`;case"invalid_key":return`${r.origin} daxilind\u0259 yanl\u0131\u015F a\xE7ar`;case"invalid_union":return"Yanl\u0131\u015F d\u0259y\u0259r";case"invalid_element":return`${r.origin} daxilind\u0259 yanl\u0131\u015F d\u0259y\u0259r`;default:return"Yanl\u0131\u015F d\u0259y\u0259r"}}};function jv(){return{localeError:Tz()}}function Nv(e,t,n,o){let r=Math.abs(e),i=r%10,a=r%100;return a>=11&&a<=19?o:i===1?t:i>=2&&i<=4?n:o}var Oz=()=>{let e={string:{unit:{one:"\u0441\u0456\u043C\u0432\u0430\u043B",few:"\u0441\u0456\u043C\u0432\u0430\u043B\u044B",many:"\u0441\u0456\u043C\u0432\u0430\u043B\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"},array:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u044B",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"},set:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u044B",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"},file:{unit:{one:"\u0431\u0430\u0439\u0442",few:"\u0431\u0430\u0439\u0442\u044B",many:"\u0431\u0430\u0439\u0442\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u043B\u0456\u043A";case"object":{if(Array.isArray(r))return"\u043C\u0430\u0441\u0456\u045E";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0443\u0432\u043E\u0434",email:"email \u0430\u0434\u0440\u0430\u0441",url:"URL",emoji:"\u044D\u043C\u043E\u0434\u0437\u0456",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0434\u0430\u0442\u0430 \u0456 \u0447\u0430\u0441",date:"ISO \u0434\u0430\u0442\u0430",time:"ISO \u0447\u0430\u0441",duration:"ISO \u043F\u0440\u0430\u0446\u044F\u0433\u043B\u0430\u0441\u0446\u044C",ipv4:"IPv4 \u0430\u0434\u0440\u0430\u0441",ipv6:"IPv6 \u0430\u0434\u0440\u0430\u0441",cidrv4:"IPv4 \u0434\u044B\u044F\u043F\u0430\u0437\u043E\u043D",cidrv6:"IPv6 \u0434\u044B\u044F\u043F\u0430\u0437\u043E\u043D",base64:"\u0440\u0430\u0434\u043E\u043A \u0443 \u0444\u0430\u0440\u043C\u0430\u0446\u0435 base64",base64url:"\u0440\u0430\u0434\u043E\u043A \u0443 \u0444\u0430\u0440\u043C\u0430\u0446\u0435 base64url",json_string:"JSON \u0440\u0430\u0434\u043E\u043A",e164:"\u043D\u0443\u043C\u0430\u0440 E.164",jwt:"JWT",template_literal:"\u0443\u0432\u043E\u0434"};return r=>{switch(r.code){case"invalid_type":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434: \u0447\u0430\u043A\u0430\u045E\u0441\u044F ${r.expected}, \u0430\u0442\u0440\u044B\u043C\u0430\u043D\u0430 ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F ${j(r.values[0])}`:`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0432\u0430\u0440\u044B\u044F\u043D\u0442: \u0447\u0430\u043A\u0430\u045E\u0441\u044F \u0430\u0434\u0437\u0456\u043D \u0437 ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);if(a){let s=Number(r.maximum),c=Nv(s,a.unit.one,a.unit.few,a.unit.many);return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u0432\u044F\u043B\u0456\u043A\u0456: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${r.origin??"\u0437\u043D\u0430\u0447\u044D\u043D\u043D\u0435"} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 ${a.verb} ${i}${r.maximum.toString()} ${c}`}return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u0432\u044F\u043B\u0456\u043A\u0456: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${r.origin??"\u0437\u043D\u0430\u0447\u044D\u043D\u043D\u0435"} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 \u0431\u044B\u0446\u044C ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);if(a){let s=Number(r.minimum),c=Nv(s,a.unit.one,a.unit.few,a.unit.many);return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u043C\u0430\u043B\u044B: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${r.origin} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 ${a.verb} ${i}${r.minimum.toString()} ${c}`}return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u043C\u0430\u043B\u044B: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${r.origin} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 \u0431\u044B\u0446\u044C ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u043F\u0430\u0447\u044B\u043D\u0430\u0446\u0446\u0430 \u0437 "${i.prefix}"`:i.format==="ends_with"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0437\u0430\u043A\u0430\u043D\u0447\u0432\u0430\u0446\u0446\u0430 \u043D\u0430 "${i.suffix}"`:i.format==="includes"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0437\u043C\u044F\u0448\u0447\u0430\u0446\u044C "${i.includes}"`:i.format==="regex"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0430\u0434\u043F\u0430\u0432\u044F\u0434\u0430\u0446\u044C \u0448\u0430\u0431\u043B\u043E\u043D\u0443 ${i.pattern}`:`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B ${o[i.format]??r.format}`}case"not_multiple_of":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u043B\u0456\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0431\u044B\u0446\u044C \u043A\u0440\u0430\u0442\u043D\u044B\u043C ${r.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u0430\u0441\u043F\u0430\u0437\u043D\u0430\u043D\u044B ${r.keys.length>1?"\u043A\u043B\u044E\u0447\u044B":"\u043A\u043B\u044E\u0447"}: ${S(r.keys,", ")}`;case"invalid_key":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u043A\u043B\u044E\u0447 \u0443 ${r.origin}`;case"invalid_union":return"\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434";case"invalid_element":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u0430\u0435 \u0437\u043D\u0430\u0447\u044D\u043D\u043D\u0435 \u045E ${r.origin}`;default:return"\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434"}}};function Rv(){return{localeError:Oz()}}var Pz=()=>{let e={string:{unit:"car\xE0cters",verb:"contenir"},file:{unit:"bytes",verb:"contenir"},array:{unit:"elements",verb:"contenir"},set:{unit:"elements",verb:"contenir"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"number";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"entrada",email:"adre\xE7a electr\xF2nica",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data i hora ISO",date:"data ISO",time:"hora ISO",duration:"durada ISO",ipv4:"adre\xE7a IPv4",ipv6:"adre\xE7a IPv6",cidrv4:"rang IPv4",cidrv6:"rang IPv6",base64:"cadena codificada en base64",base64url:"cadena codificada en base64url",json_string:"cadena JSON",e164:"n\xFAmero E.164",jwt:"JWT",template_literal:"entrada"};return r=>{switch(r.code){case"invalid_type":return`Tipus inv\xE0lid: s'esperava ${r.expected}, s'ha rebut ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Valor inv\xE0lid: s'esperava ${j(r.values[0])}`:`Opci\xF3 inv\xE0lida: s'esperava una de ${S(r.values," o ")}`;case"too_big":{let i=r.inclusive?"com a m\xE0xim":"menys de",a=t(r.origin);return a?`Massa gran: s'esperava que ${r.origin??"el valor"} contingu\xE9s ${i} ${r.maximum.toString()} ${a.unit??"elements"}`:`Massa gran: s'esperava que ${r.origin??"el valor"} fos ${i} ${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?"com a m\xEDnim":"m\xE9s de",a=t(r.origin);return a?`Massa petit: s'esperava que ${r.origin} contingu\xE9s ${i} ${r.minimum.toString()} ${a.unit}`:`Massa petit: s'esperava que ${r.origin} fos ${i} ${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Format inv\xE0lid: ha de comen\xE7ar amb "${i.prefix}"`:i.format==="ends_with"?`Format inv\xE0lid: ha d'acabar amb "${i.suffix}"`:i.format==="includes"?`Format inv\xE0lid: ha d'incloure "${i.includes}"`:i.format==="regex"?`Format inv\xE0lid: ha de coincidir amb el patr\xF3 ${i.pattern}`:`Format inv\xE0lid per a ${o[i.format]??r.format}`}case"not_multiple_of":return`N\xFAmero inv\xE0lid: ha de ser m\xFAltiple de ${r.divisor}`;case"unrecognized_keys":return`Clau${r.keys.length>1?"s":""} no reconeguda${r.keys.length>1?"s":""}: ${S(r.keys,", ")}`;case"invalid_key":return`Clau inv\xE0lida a ${r.origin}`;case"invalid_union":return"Entrada inv\xE0lida";case"invalid_element":return`Element inv\xE0lid a ${r.origin}`;default:return"Entrada inv\xE0lida"}}};function Av(){return{localeError:Pz()}}var jz=()=>{let e={string:{unit:"znak\u016F",verb:"m\xEDt"},file:{unit:"bajt\u016F",verb:"m\xEDt"},array:{unit:"prvk\u016F",verb:"m\xEDt"},set:{unit:"prvk\u016F",verb:"m\xEDt"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u010D\xEDslo";case"string":return"\u0159et\u011Bzec";case"boolean":return"boolean";case"bigint":return"bigint";case"function":return"funkce";case"symbol":return"symbol";case"undefined":return"undefined";case"object":{if(Array.isArray(r))return"pole";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"regul\xE1rn\xED v\xFDraz",email:"e-mailov\xE1 adresa",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"datum a \u010Das ve form\xE1tu ISO",date:"datum ve form\xE1tu ISO",time:"\u010Das ve form\xE1tu ISO",duration:"doba trv\xE1n\xED ISO",ipv4:"IPv4 adresa",ipv6:"IPv6 adresa",cidrv4:"rozsah IPv4",cidrv6:"rozsah IPv6",base64:"\u0159et\u011Bzec zak\xF3dovan\xFD ve form\xE1tu base64",base64url:"\u0159et\u011Bzec zak\xF3dovan\xFD ve form\xE1tu base64url",json_string:"\u0159et\u011Bzec ve form\xE1tu JSON",e164:"\u010D\xEDslo E.164",jwt:"JWT",template_literal:"vstup"};return r=>{switch(r.code){case"invalid_type":return`Neplatn\xFD vstup: o\u010Dek\xE1v\xE1no ${r.expected}, obdr\u017Eeno ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Neplatn\xFD vstup: o\u010Dek\xE1v\xE1no ${j(r.values[0])}`:`Neplatn\xE1 mo\u017Enost: o\u010Dek\xE1v\xE1na jedna z hodnot ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Hodnota je p\u0159\xEDli\u0161 velk\xE1: ${r.origin??"hodnota"} mus\xED m\xEDt ${i}${r.maximum.toString()} ${a.unit??"prvk\u016F"}`:`Hodnota je p\u0159\xEDli\u0161 velk\xE1: ${r.origin??"hodnota"} mus\xED b\xFDt ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Hodnota je p\u0159\xEDli\u0161 mal\xE1: ${r.origin??"hodnota"} mus\xED m\xEDt ${i}${r.minimum.toString()} ${a.unit??"prvk\u016F"}`:`Hodnota je p\u0159\xEDli\u0161 mal\xE1: ${r.origin??"hodnota"} mus\xED b\xFDt ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED za\u010D\xEDnat na "${i.prefix}"`:i.format==="ends_with"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED kon\u010Dit na "${i.suffix}"`:i.format==="includes"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED obsahovat "${i.includes}"`:i.format==="regex"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED odpov\xEDdat vzoru ${i.pattern}`:`Neplatn\xFD form\xE1t ${o[i.format]??r.format}`}case"not_multiple_of":return`Neplatn\xE9 \u010D\xEDslo: mus\xED b\xFDt n\xE1sobkem ${r.divisor}`;case"unrecognized_keys":return`Nezn\xE1m\xE9 kl\xED\u010De: ${S(r.keys,", ")}`;case"invalid_key":return`Neplatn\xFD kl\xED\u010D v ${r.origin}`;case"invalid_union":return"Neplatn\xFD vstup";case"invalid_element":return`Neplatn\xE1 hodnota v ${r.origin}`;default:return"Neplatn\xFD vstup"}}};function Dv(){return{localeError:jz()}}var Nz=()=>{let e={string:{unit:"tegn",verb:"havde"},file:{unit:"bytes",verb:"havde"},array:{unit:"elementer",verb:"indeholdt"},set:{unit:"elementer",verb:"indeholdt"}},t={string:"streng",number:"tal",boolean:"boolean",array:"liste",object:"objekt",set:"s\xE6t",file:"fil"};function n(a){return e[a]??null}function o(a){return t[a]??a}let r=a=>{let s=typeof a;switch(s){case"number":return Number.isNaN(a)?"NaN":"tal";case"object":return Array.isArray(a)?"liste":a===null?"null":Object.getPrototypeOf(a)!==Object.prototype&&a.constructor?a.constructor.name:"objekt"}return s},i={regex:"input",email:"e-mailadresse",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO dato- og klokkesl\xE6t",date:"ISO-dato",time:"ISO-klokkesl\xE6t",duration:"ISO-varighed",ipv4:"IPv4-omr\xE5de",ipv6:"IPv6-omr\xE5de",cidrv4:"IPv4-spektrum",cidrv6:"IPv6-spektrum",base64:"base64-kodet streng",base64url:"base64url-kodet streng",json_string:"JSON-streng",e164:"E.164-nummer",jwt:"JWT",template_literal:"input"};return a=>{switch(a.code){case"invalid_type":return`Ugyldigt input: forventede ${o(a.expected)}, fik ${o(r(a.input))}`;case"invalid_value":return a.values.length===1?`Ugyldig v\xE6rdi: forventede ${j(a.values[0])}`:`Ugyldigt valg: forventede en af f\xF8lgende ${S(a.values,"|")}`;case"too_big":{let s=a.inclusive?"<=":"<",c=n(a.origin),l=o(a.origin);return c?`For stor: forventede ${l??"value"} ${c.verb} ${s} ${a.maximum.toString()} ${c.unit??"elementer"}`:`For stor: forventede ${l??"value"} havde ${s} ${a.maximum.toString()}`}case"too_small":{let s=a.inclusive?">=":">",c=n(a.origin),l=o(a.origin);return c?`For lille: forventede ${l} ${c.verb} ${s} ${a.minimum.toString()} ${c.unit}`:`For lille: forventede ${l} havde ${s} ${a.minimum.toString()}`}case"invalid_format":{let s=a;return s.format==="starts_with"?`Ugyldig streng: skal starte med "${s.prefix}"`:s.format==="ends_with"?`Ugyldig streng: skal ende med "${s.suffix}"`:s.format==="includes"?`Ugyldig streng: skal indeholde "${s.includes}"`:s.format==="regex"?`Ugyldig streng: skal matche m\xF8nsteret ${s.pattern}`:`Ugyldig ${i[s.format]??a.format}`}case"not_multiple_of":return`Ugyldigt tal: skal v\xE6re deleligt med ${a.divisor}`;case"unrecognized_keys":return`${a.keys.length>1?"Ukendte n\xF8gler":"Ukendt n\xF8gle"}: ${S(a.keys,", ")}`;case"invalid_key":return`Ugyldig n\xF8gle i ${a.origin}`;case"invalid_union":return"Ugyldigt input: matcher ingen af de tilladte typer";case"invalid_element":return`Ugyldig v\xE6rdi i ${a.origin}`;default:return"Ugyldigt input"}}};function Cv(){return{localeError:Nz()}}var Rz=()=>{let e={string:{unit:"Zeichen",verb:"zu haben"},file:{unit:"Bytes",verb:"zu haben"},array:{unit:"Elemente",verb:"zu haben"},set:{unit:"Elemente",verb:"zu haben"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"Zahl";case"object":{if(Array.isArray(r))return"Array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"Eingabe",email:"E-Mail-Adresse",url:"URL",emoji:"Emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-Datum und -Uhrzeit",date:"ISO-Datum",time:"ISO-Uhrzeit",duration:"ISO-Dauer",ipv4:"IPv4-Adresse",ipv6:"IPv6-Adresse",cidrv4:"IPv4-Bereich",cidrv6:"IPv6-Bereich",base64:"Base64-codierter String",base64url:"Base64-URL-codierter String",json_string:"JSON-String",e164:"E.164-Nummer",jwt:"JWT",template_literal:"Eingabe"};return r=>{switch(r.code){case"invalid_type":return`Ung\xFCltige Eingabe: erwartet ${r.expected}, erhalten ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Ung\xFCltige Eingabe: erwartet ${j(r.values[0])}`:`Ung\xFCltige Option: erwartet eine von ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Zu gro\xDF: erwartet, dass ${r.origin??"Wert"} ${i}${r.maximum.toString()} ${a.unit??"Elemente"} hat`:`Zu gro\xDF: erwartet, dass ${r.origin??"Wert"} ${i}${r.maximum.toString()} ist`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Zu klein: erwartet, dass ${r.origin} ${i}${r.minimum.toString()} ${a.unit} hat`:`Zu klein: erwartet, dass ${r.origin} ${i}${r.minimum.toString()} ist`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Ung\xFCltiger String: muss mit "${i.prefix}" beginnen`:i.format==="ends_with"?`Ung\xFCltiger String: muss mit "${i.suffix}" enden`:i.format==="includes"?`Ung\xFCltiger String: muss "${i.includes}" enthalten`:i.format==="regex"?`Ung\xFCltiger String: muss dem Muster ${i.pattern} entsprechen`:`Ung\xFCltig: ${o[i.format]??r.format}`}case"not_multiple_of":return`Ung\xFCltige Zahl: muss ein Vielfaches von ${r.divisor} sein`;case"unrecognized_keys":return`${r.keys.length>1?"Unbekannte Schl\xFCssel":"Unbekannter Schl\xFCssel"}: ${S(r.keys,", ")}`;case"invalid_key":return`Ung\xFCltiger Schl\xFCssel in ${r.origin}`;case"invalid_union":return"Ung\xFCltige Eingabe";case"invalid_element":return`Ung\xFCltiger Wert in ${r.origin}`;default:return"Ung\xFCltige Eingabe"}}};function Uv(){return{localeError:Rz()}}var Az=e=>{let t=typeof e;switch(t){case"number":return Number.isNaN(e)?"NaN":"number";case"object":{if(Array.isArray(e))return"array";if(e===null)return"null";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return t},Dz=()=>{let e={string:{unit:"characters",verb:"to have"},file:{unit:"bytes",verb:"to have"},array:{unit:"items",verb:"to have"},set:{unit:"items",verb:"to have"}};function t(o){return e[o]??null}let n={regex:"input",email:"email address",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datetime",date:"ISO date",time:"ISO time",duration:"ISO duration",ipv4:"IPv4 address",ipv6:"IPv6 address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded string",base64url:"base64url-encoded string",json_string:"JSON string",e164:"E.164 number",jwt:"JWT",template_literal:"input"};return o=>{switch(o.code){case"invalid_type":return`Invalid input: expected ${o.expected}, received ${Az(o.input)}`;case"invalid_value":return o.values.length===1?`Invalid input: expected ${j(o.values[0])}`:`Invalid option: expected one of ${S(o.values,"|")}`;case"too_big":{let r=o.inclusive?"<=":"<",i=t(o.origin);return i?`Too big: expected ${o.origin??"value"} to have ${r}${o.maximum.toString()} ${i.unit??"elements"}`:`Too big: expected ${o.origin??"value"} to be ${r}${o.maximum.toString()}`}case"too_small":{let r=o.inclusive?">=":">",i=t(o.origin);return i?`Too small: expected ${o.origin} to have ${r}${o.minimum.toString()} ${i.unit}`:`Too small: expected ${o.origin} to be ${r}${o.minimum.toString()}`}case"invalid_format":{let r=o;return r.format==="starts_with"?`Invalid string: must start with "${r.prefix}"`:r.format==="ends_with"?`Invalid string: must end with "${r.suffix}"`:r.format==="includes"?`Invalid string: must include "${r.includes}"`:r.format==="regex"?`Invalid string: must match pattern ${r.pattern}`:`Invalid ${n[r.format]??o.format}`}case"not_multiple_of":return`Invalid number: must be a multiple of ${o.divisor}`;case"unrecognized_keys":return`Unrecognized key${o.keys.length>1?"s":""}: ${S(o.keys,", ")}`;case"invalid_key":return`Invalid key in ${o.origin}`;case"invalid_union":return"Invalid input";case"invalid_element":return`Invalid value in ${o.origin}`;default:return"Invalid input"}}};function Ic(){return{localeError:Dz()}}var Cz=e=>{let t=typeof e;switch(t){case"number":return Number.isNaN(e)?"NaN":"nombro";case"object":{if(Array.isArray(e))return"tabelo";if(e===null)return"senvalora";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return t},Uz=()=>{let e={string:{unit:"karaktrojn",verb:"havi"},file:{unit:"bajtojn",verb:"havi"},array:{unit:"elementojn",verb:"havi"},set:{unit:"elementojn",verb:"havi"}};function t(o){return e[o]??null}let n={regex:"enigo",email:"retadreso",url:"URL",emoji:"emo\u011Dio",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-datotempo",date:"ISO-dato",time:"ISO-tempo",duration:"ISO-da\u016Dro",ipv4:"IPv4-adreso",ipv6:"IPv6-adreso",cidrv4:"IPv4-rango",cidrv6:"IPv6-rango",base64:"64-ume kodita karaktraro",base64url:"URL-64-ume kodita karaktraro",json_string:"JSON-karaktraro",e164:"E.164-nombro",jwt:"JWT",template_literal:"enigo"};return o=>{switch(o.code){case"invalid_type":return`Nevalida enigo: atendi\u011Dis ${o.expected}, ricevi\u011Dis ${Cz(o.input)}`;case"invalid_value":return o.values.length===1?`Nevalida enigo: atendi\u011Dis ${j(o.values[0])}`:`Nevalida opcio: atendi\u011Dis unu el ${S(o.values,"|")}`;case"too_big":{let r=o.inclusive?"<=":"<",i=t(o.origin);return i?`Tro granda: atendi\u011Dis ke ${o.origin??"valoro"} havu ${r}${o.maximum.toString()} ${i.unit??"elementojn"}`:`Tro granda: atendi\u011Dis ke ${o.origin??"valoro"} havu ${r}${o.maximum.toString()}`}case"too_small":{let r=o.inclusive?">=":">",i=t(o.origin);return i?`Tro malgranda: atendi\u011Dis ke ${o.origin} havu ${r}${o.minimum.toString()} ${i.unit}`:`Tro malgranda: atendi\u011Dis ke ${o.origin} estu ${r}${o.minimum.toString()}`}case"invalid_format":{let r=o;return r.format==="starts_with"?`Nevalida karaktraro: devas komenci\u011Di per "${r.prefix}"`:r.format==="ends_with"?`Nevalida karaktraro: devas fini\u011Di per "${r.suffix}"`:r.format==="includes"?`Nevalida karaktraro: devas inkluzivi "${r.includes}"`:r.format==="regex"?`Nevalida karaktraro: devas kongrui kun la modelo ${r.pattern}`:`Nevalida ${n[r.format]??o.format}`}case"not_multiple_of":return`Nevalida nombro: devas esti oblo de ${o.divisor}`;case"unrecognized_keys":return`Nekonata${o.keys.length>1?"j":""} \u015Dlosilo${o.keys.length>1?"j":""}: ${S(o.keys,", ")}`;case"invalid_key":return`Nevalida \u015Dlosilo en ${o.origin}`;case"invalid_union":return"Nevalida enigo";case"invalid_element":return`Nevalida valoro en ${o.origin}`;default:return"Nevalida enigo"}}};function Zv(){return{localeError:Uz()}}var Zz=()=>{let e={string:{unit:"caracteres",verb:"tener"},file:{unit:"bytes",verb:"tener"},array:{unit:"elementos",verb:"tener"},set:{unit:"elementos",verb:"tener"}},t={string:"texto",number:"n\xFAmero",boolean:"booleano",array:"arreglo",object:"objeto",set:"conjunto",file:"archivo",date:"fecha",bigint:"n\xFAmero grande",symbol:"s\xEDmbolo",undefined:"indefinido",null:"nulo",function:"funci\xF3n",map:"mapa",record:"registro",tuple:"tupla",enum:"enumeraci\xF3n",union:"uni\xF3n",literal:"literal",promise:"promesa",void:"vac\xEDo",never:"nunca",unknown:"desconocido",any:"cualquiera"};function n(a){return e[a]??null}function o(a){return t[a]??a}let r=a=>{let s=typeof a;switch(s){case"number":return Number.isNaN(a)?"NaN":"number";case"object":return Array.isArray(a)?"array":a===null?"null":Object.getPrototypeOf(a)!==Object.prototype?a.constructor.name:"object"}return s},i={regex:"entrada",email:"direcci\xF3n de correo electr\xF3nico",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"fecha y hora ISO",date:"fecha ISO",time:"hora ISO",duration:"duraci\xF3n ISO",ipv4:"direcci\xF3n IPv4",ipv6:"direcci\xF3n IPv6",cidrv4:"rango IPv4",cidrv6:"rango IPv6",base64:"cadena codificada en base64",base64url:"URL codificada en base64",json_string:"cadena JSON",e164:"n\xFAmero E.164",jwt:"JWT",template_literal:"entrada"};return a=>{switch(a.code){case"invalid_type":return`Entrada inv\xE1lida: se esperaba ${o(a.expected)}, recibido ${o(r(a.input))}`;case"invalid_value":return a.values.length===1?`Entrada inv\xE1lida: se esperaba ${j(a.values[0])}`:`Opci\xF3n inv\xE1lida: se esperaba una de ${S(a.values,"|")}`;case"too_big":{let s=a.inclusive?"<=":"<",c=n(a.origin),l=o(a.origin);return c?`Demasiado grande: se esperaba que ${l??"valor"} tuviera ${s}${a.maximum.toString()} ${c.unit??"elementos"}`:`Demasiado grande: se esperaba que ${l??"valor"} fuera ${s}${a.maximum.toString()}`}case"too_small":{let s=a.inclusive?">=":">",c=n(a.origin),l=o(a.origin);return c?`Demasiado peque\xF1o: se esperaba que ${l} tuviera ${s}${a.minimum.toString()} ${c.unit}`:`Demasiado peque\xF1o: se esperaba que ${l} fuera ${s}${a.minimum.toString()}`}case"invalid_format":{let s=a;return s.format==="starts_with"?`Cadena inv\xE1lida: debe comenzar con "${s.prefix}"`:s.format==="ends_with"?`Cadena inv\xE1lida: debe terminar en "${s.suffix}"`:s.format==="includes"?`Cadena inv\xE1lida: debe incluir "${s.includes}"`:s.format==="regex"?`Cadena inv\xE1lida: debe coincidir con el patr\xF3n ${s.pattern}`:`Inv\xE1lido ${i[s.format]??a.format}`}case"not_multiple_of":return`N\xFAmero inv\xE1lido: debe ser m\xFAltiplo de ${a.divisor}`;case"unrecognized_keys":return`Llave${a.keys.length>1?"s":""} desconocida${a.keys.length>1?"s":""}: ${S(a.keys,", ")}`;case"invalid_key":return`Llave inv\xE1lida en ${o(a.origin)}`;case"invalid_union":return"Entrada inv\xE1lida";case"invalid_element":return`Valor inv\xE1lido en ${o(a.origin)}`;default:return"Entrada inv\xE1lida"}}};function Mv(){return{localeError:Zz()}}var Mz=()=>{let e={string:{unit:"\u06A9\u0627\u0631\u0627\u06A9\u062A\u0631",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"},file:{unit:"\u0628\u0627\u06CC\u062A",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"},array:{unit:"\u0622\u06CC\u062A\u0645",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"},set:{unit:"\u0622\u06CC\u062A\u0645",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u0639\u062F\u062F";case"object":{if(Array.isArray(r))return"\u0622\u0631\u0627\u06CC\u0647";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0648\u0631\u0648\u062F\u06CC",email:"\u0622\u062F\u0631\u0633 \u0627\u06CC\u0645\u06CC\u0644",url:"URL",emoji:"\u0627\u06CC\u0645\u0648\u062C\u06CC",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u062A\u0627\u0631\u06CC\u062E \u0648 \u0632\u0645\u0627\u0646 \u0627\u06CC\u0632\u0648",date:"\u062A\u0627\u0631\u06CC\u062E \u0627\u06CC\u0632\u0648",time:"\u0632\u0645\u0627\u0646 \u0627\u06CC\u0632\u0648",duration:"\u0645\u062F\u062A \u0632\u0645\u0627\u0646 \u0627\u06CC\u0632\u0648",ipv4:"IPv4 \u0622\u062F\u0631\u0633",ipv6:"IPv6 \u0622\u062F\u0631\u0633",cidrv4:"IPv4 \u062F\u0627\u0645\u0646\u0647",cidrv6:"IPv6 \u062F\u0627\u0645\u0646\u0647",base64:"base64-encoded \u0631\u0634\u062A\u0647",base64url:"base64url-encoded \u0631\u0634\u062A\u0647",json_string:"JSON \u0631\u0634\u062A\u0647",e164:"E.164 \u0639\u062F\u062F",jwt:"JWT",template_literal:"\u0648\u0631\u0648\u062F\u06CC"};return r=>{switch(r.code){case"invalid_type":return`\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0645\u06CC\u200C\u0628\u0627\u06CC\u0633\u062A ${r.expected} \u0645\u06CC\u200C\u0628\u0648\u062F\u060C ${n(r.input)} \u062F\u0631\u06CC\u0627\u0641\u062A \u0634\u062F`;case"invalid_value":return r.values.length===1?`\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0645\u06CC\u200C\u0628\u0627\u06CC\u0633\u062A ${j(r.values[0])} \u0645\u06CC\u200C\u0628\u0648\u062F`:`\u06AF\u0632\u06CC\u0646\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0645\u06CC\u200C\u0628\u0627\u06CC\u0633\u062A \u06CC\u06A9\u06CC \u0627\u0632 ${S(r.values,"|")} \u0645\u06CC\u200C\u0628\u0648\u062F`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u062E\u06CC\u0644\u06CC \u0628\u0632\u0631\u06AF: ${r.origin??"\u0645\u0642\u062F\u0627\u0631"} \u0628\u0627\u06CC\u062F ${i}${r.maximum.toString()} ${a.unit??"\u0639\u0646\u0635\u0631"} \u0628\u0627\u0634\u062F`:`\u062E\u06CC\u0644\u06CC \u0628\u0632\u0631\u06AF: ${r.origin??"\u0645\u0642\u062F\u0627\u0631"} \u0628\u0627\u06CC\u062F ${i}${r.maximum.toString()} \u0628\u0627\u0634\u062F`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u062E\u06CC\u0644\u06CC \u06A9\u0648\u0686\u06A9: ${r.origin} \u0628\u0627\u06CC\u062F ${i}${r.minimum.toString()} ${a.unit} \u0628\u0627\u0634\u062F`:`\u062E\u06CC\u0644\u06CC \u06A9\u0648\u0686\u06A9: ${r.origin} \u0628\u0627\u06CC\u062F ${i}${r.minimum.toString()} \u0628\u0627\u0634\u062F`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0628\u0627 "${i.prefix}" \u0634\u0631\u0648\u0639 \u0634\u0648\u062F`:i.format==="ends_with"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0628\u0627 "${i.suffix}" \u062A\u0645\u0627\u0645 \u0634\u0648\u062F`:i.format==="includes"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0634\u0627\u0645\u0644 "${i.includes}" \u0628\u0627\u0634\u062F`:i.format==="regex"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0628\u0627 \u0627\u0644\u06AF\u0648\u06CC ${i.pattern} \u0645\u0637\u0627\u0628\u0642\u062A \u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F`:`${o[i.format]??r.format} \u0646\u0627\u0645\u0639\u062A\u0628\u0631`}case"not_multiple_of":return`\u0639\u062F\u062F \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0645\u0636\u0631\u0628 ${r.divisor} \u0628\u0627\u0634\u062F`;case"unrecognized_keys":return`\u06A9\u0644\u06CC\u062F${r.keys.length>1?"\u0647\u0627\u06CC":""} \u0646\u0627\u0634\u0646\u0627\u0633: ${S(r.keys,", ")}`;case"invalid_key":return`\u06A9\u0644\u06CC\u062F \u0646\u0627\u0634\u0646\u0627\u0633 \u062F\u0631 ${r.origin}`;case"invalid_union":return"\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631";case"invalid_element":return`\u0645\u0642\u062F\u0627\u0631 \u0646\u0627\u0645\u0639\u062A\u0628\u0631 \u062F\u0631 ${r.origin}`;default:return"\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631"}}};function Lv(){return{localeError:Mz()}}var Lz=()=>{let e={string:{unit:"merkki\xE4",subject:"merkkijonon"},file:{unit:"tavua",subject:"tiedoston"},array:{unit:"alkiota",subject:"listan"},set:{unit:"alkiota",subject:"joukon"},number:{unit:"",subject:"luvun"},bigint:{unit:"",subject:"suuren kokonaisluvun"},int:{unit:"",subject:"kokonaisluvun"},date:{unit:"",subject:"p\xE4iv\xE4m\xE4\xE4r\xE4n"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"number";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"s\xE4\xE4nn\xF6llinen lauseke",email:"s\xE4hk\xF6postiosoite",url:"URL-osoite",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-aikaleima",date:"ISO-p\xE4iv\xE4m\xE4\xE4r\xE4",time:"ISO-aika",duration:"ISO-kesto",ipv4:"IPv4-osoite",ipv6:"IPv6-osoite",cidrv4:"IPv4-alue",cidrv6:"IPv6-alue",base64:"base64-koodattu merkkijono",base64url:"base64url-koodattu merkkijono",json_string:"JSON-merkkijono",e164:"E.164-luku",jwt:"JWT",template_literal:"templaattimerkkijono"};return r=>{switch(r.code){case"invalid_type":return`Virheellinen tyyppi: odotettiin ${r.expected}, oli ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Virheellinen sy\xF6te: t\xE4ytyy olla ${j(r.values[0])}`:`Virheellinen valinta: t\xE4ytyy olla yksi seuraavista: ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Liian suuri: ${a.subject} t\xE4ytyy olla ${i}${r.maximum.toString()} ${a.unit}`.trim():`Liian suuri: arvon t\xE4ytyy olla ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Liian pieni: ${a.subject} t\xE4ytyy olla ${i}${r.minimum.toString()} ${a.unit}`.trim():`Liian pieni: arvon t\xE4ytyy olla ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Virheellinen sy\xF6te: t\xE4ytyy alkaa "${i.prefix}"`:i.format==="ends_with"?`Virheellinen sy\xF6te: t\xE4ytyy loppua "${i.suffix}"`:i.format==="includes"?`Virheellinen sy\xF6te: t\xE4ytyy sis\xE4lt\xE4\xE4 "${i.includes}"`:i.format==="regex"?`Virheellinen sy\xF6te: t\xE4ytyy vastata s\xE4\xE4nn\xF6llist\xE4 lauseketta ${i.pattern}`:`Virheellinen ${o[i.format]??r.format}`}case"not_multiple_of":return`Virheellinen luku: t\xE4ytyy olla luvun ${r.divisor} monikerta`;case"unrecognized_keys":return`${r.keys.length>1?"Tuntemattomat avaimet":"Tuntematon avain"}: ${S(r.keys,", ")}`;case"invalid_key":return"Virheellinen avain tietueessa";case"invalid_union":return"Virheellinen unioni";case"invalid_element":return"Virheellinen arvo joukossa";default:return"Virheellinen sy\xF6te"}}};function qv(){return{localeError:Lz()}}var qz=()=>{let e={string:{unit:"caract\xE8res",verb:"avoir"},file:{unit:"octets",verb:"avoir"},array:{unit:"\xE9l\xE9ments",verb:"avoir"},set:{unit:"\xE9l\xE9ments",verb:"avoir"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"nombre";case"object":{if(Array.isArray(r))return"tableau";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"entr\xE9e",email:"adresse e-mail",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"date et heure ISO",date:"date ISO",time:"heure ISO",duration:"dur\xE9e ISO",ipv4:"adresse IPv4",ipv6:"adresse IPv6",cidrv4:"plage IPv4",cidrv6:"plage IPv6",base64:"cha\xEEne encod\xE9e en base64",base64url:"cha\xEEne encod\xE9e en base64url",json_string:"cha\xEEne JSON",e164:"num\xE9ro E.164",jwt:"JWT",template_literal:"entr\xE9e"};return r=>{switch(r.code){case"invalid_type":return`Entr\xE9e invalide : ${r.expected} attendu, ${n(r.input)} re\xE7u`;case"invalid_value":return r.values.length===1?`Entr\xE9e invalide : ${j(r.values[0])} attendu`:`Option invalide : une valeur parmi ${S(r.values,"|")} attendue`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Trop grand : ${r.origin??"valeur"} doit ${a.verb} ${i}${r.maximum.toString()} ${a.unit??"\xE9l\xE9ment(s)"}`:`Trop grand : ${r.origin??"valeur"} doit \xEAtre ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Trop petit : ${r.origin} doit ${a.verb} ${i}${r.minimum.toString()} ${a.unit}`:`Trop petit : ${r.origin} doit \xEAtre ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Cha\xEEne invalide : doit commencer par "${i.prefix}"`:i.format==="ends_with"?`Cha\xEEne invalide : doit se terminer par "${i.suffix}"`:i.format==="includes"?`Cha\xEEne invalide : doit inclure "${i.includes}"`:i.format==="regex"?`Cha\xEEne invalide : doit correspondre au mod\xE8le ${i.pattern}`:`${o[i.format]??r.format} invalide`}case"not_multiple_of":return`Nombre invalide : doit \xEAtre un multiple de ${r.divisor}`;case"unrecognized_keys":return`Cl\xE9${r.keys.length>1?"s":""} non reconnue${r.keys.length>1?"s":""} : ${S(r.keys,", ")}`;case"invalid_key":return`Cl\xE9 invalide dans ${r.origin}`;case"invalid_union":return"Entr\xE9e invalide";case"invalid_element":return`Valeur invalide dans ${r.origin}`;default:return"Entr\xE9e invalide"}}};function Vv(){return{localeError:qz()}}var Vz=()=>{let e={string:{unit:"caract\xE8res",verb:"avoir"},file:{unit:"octets",verb:"avoir"},array:{unit:"\xE9l\xE9ments",verb:"avoir"},set:{unit:"\xE9l\xE9ments",verb:"avoir"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"number";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"entr\xE9e",email:"adresse courriel",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"date-heure ISO",date:"date ISO",time:"heure ISO",duration:"dur\xE9e ISO",ipv4:"adresse IPv4",ipv6:"adresse IPv6",cidrv4:"plage IPv4",cidrv6:"plage IPv6",base64:"cha\xEEne encod\xE9e en base64",base64url:"cha\xEEne encod\xE9e en base64url",json_string:"cha\xEEne JSON",e164:"num\xE9ro E.164",jwt:"JWT",template_literal:"entr\xE9e"};return r=>{switch(r.code){case"invalid_type":return`Entr\xE9e invalide : attendu ${r.expected}, re\xE7u ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Entr\xE9e invalide : attendu ${j(r.values[0])}`:`Option invalide : attendu l'une des valeurs suivantes ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"\u2264":"<",a=t(r.origin);return a?`Trop grand : attendu que ${r.origin??"la valeur"} ait ${i}${r.maximum.toString()} ${a.unit}`:`Trop grand : attendu que ${r.origin??"la valeur"} soit ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?"\u2265":">",a=t(r.origin);return a?`Trop petit : attendu que ${r.origin} ait ${i}${r.minimum.toString()} ${a.unit}`:`Trop petit : attendu que ${r.origin} soit ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Cha\xEEne invalide : doit commencer par "${i.prefix}"`:i.format==="ends_with"?`Cha\xEEne invalide : doit se terminer par "${i.suffix}"`:i.format==="includes"?`Cha\xEEne invalide : doit inclure "${i.includes}"`:i.format==="regex"?`Cha\xEEne invalide : doit correspondre au motif ${i.pattern}`:`${o[i.format]??r.format} invalide`}case"not_multiple_of":return`Nombre invalide : doit \xEAtre un multiple de ${r.divisor}`;case"unrecognized_keys":return`Cl\xE9${r.keys.length>1?"s":""} non reconnue${r.keys.length>1?"s":""} : ${S(r.keys,", ")}`;case"invalid_key":return`Cl\xE9 invalide dans ${r.origin}`;case"invalid_union":return"Entr\xE9e invalide";case"invalid_element":return`Valeur invalide dans ${r.origin}`;default:return"Entr\xE9e invalide"}}};function Fv(){return{localeError:Vz()}}var Fz=()=>{let e={string:{unit:"\u05D0\u05D5\u05EA\u05D9\u05D5\u05EA",verb:"\u05DC\u05DB\u05DC\u05D5\u05DC"},file:{unit:"\u05D1\u05D9\u05D9\u05D8\u05D9\u05DD",verb:"\u05DC\u05DB\u05DC\u05D5\u05DC"},array:{unit:"\u05E4\u05E8\u05D9\u05D8\u05D9\u05DD",verb:"\u05DC\u05DB\u05DC\u05D5\u05DC"},set:{unit:"\u05E4\u05E8\u05D9\u05D8\u05D9\u05DD",verb:"\u05DC\u05DB\u05DC\u05D5\u05DC"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"number";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u05E7\u05DC\u05D8",email:"\u05DB\u05EA\u05D5\u05D1\u05EA \u05D0\u05D9\u05DE\u05D9\u05D9\u05DC",url:"\u05DB\u05EA\u05D5\u05D1\u05EA \u05E8\u05E9\u05EA",emoji:"\u05D0\u05D9\u05DE\u05D5\u05D2'\u05D9",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u05EA\u05D0\u05E8\u05D9\u05DA \u05D5\u05D6\u05DE\u05DF ISO",date:"\u05EA\u05D0\u05E8\u05D9\u05DA ISO",time:"\u05D6\u05DE\u05DF ISO",duration:"\u05DE\u05E9\u05DA \u05D6\u05DE\u05DF ISO",ipv4:"\u05DB\u05EA\u05D5\u05D1\u05EA IPv4",ipv6:"\u05DB\u05EA\u05D5\u05D1\u05EA IPv6",cidrv4:"\u05D8\u05D5\u05D5\u05D7 IPv4",cidrv6:"\u05D8\u05D5\u05D5\u05D7 IPv6",base64:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D1\u05D1\u05E1\u05D9\u05E1 64",base64url:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D1\u05D1\u05E1\u05D9\u05E1 64 \u05DC\u05DB\u05EA\u05D5\u05D1\u05D5\u05EA \u05E8\u05E9\u05EA",json_string:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA JSON",e164:"\u05DE\u05E1\u05E4\u05E8 E.164",jwt:"JWT",template_literal:"\u05E7\u05DC\u05D8"};return r=>{switch(r.code){case"invalid_type":return`\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05E6\u05E8\u05D9\u05DA ${r.expected}, \u05D4\u05EA\u05E7\u05D1\u05DC ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05E6\u05E8\u05D9\u05DA ${j(r.values[0])}`:`\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05E6\u05E8\u05D9\u05DA \u05D0\u05D7\u05EA \u05DE\u05D4\u05D0\u05E4\u05E9\u05E8\u05D5\u05D9\u05D5\u05EA ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u05D2\u05D3\u05D5\u05DC \u05DE\u05D3\u05D9: ${r.origin??"value"} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${i}${r.maximum.toString()} ${a.unit??"elements"}`:`\u05D2\u05D3\u05D5\u05DC \u05DE\u05D3\u05D9: ${r.origin??"value"} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u05E7\u05D8\u05DF \u05DE\u05D3\u05D9: ${r.origin} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${i}${r.minimum.toString()} ${a.unit}`:`\u05E7\u05D8\u05DF \u05DE\u05D3\u05D9: ${r.origin} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05E0\u05D4: \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05EA\u05D7\u05D9\u05DC \u05D1"${i.prefix}"`:i.format==="ends_with"?`\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05E0\u05D4: \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05E1\u05EA\u05D9\u05D9\u05DD \u05D1 "${i.suffix}"`:i.format==="includes"?`\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05E0\u05D4: \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05DB\u05DC\u05D5\u05DC "${i.includes}"`:i.format==="regex"?`\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05E0\u05D4: \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05EA\u05D0\u05D9\u05DD \u05DC\u05EA\u05D1\u05E0\u05D9\u05EA ${i.pattern}`:`${o[i.format]??r.format} \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF`}case"not_multiple_of":return`\u05DE\u05E1\u05E4\u05E8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05D7\u05D9\u05D9\u05D1 \u05DC\u05D4\u05D9\u05D5\u05EA \u05DE\u05DB\u05E4\u05DC\u05D4 \u05E9\u05DC ${r.divisor}`;case"unrecognized_keys":return`\u05DE\u05E4\u05EA\u05D7${r.keys.length>1?"\u05D5\u05EA":""} \u05DC\u05D0 \u05DE\u05D6\u05D5\u05D4${r.keys.length>1?"\u05D9\u05DD":"\u05D4"}: ${S(r.keys,", ")}`;case"invalid_key":return`\u05DE\u05E4\u05EA\u05D7 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF \u05D1${r.origin}`;case"invalid_union":return"\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF";case"invalid_element":return`\u05E2\u05E8\u05DA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF \u05D1${r.origin}`;default:return"\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF"}}};function Bv(){return{localeError:Fz()}}var Bz=()=>{let e={string:{unit:"karakter",verb:"legyen"},file:{unit:"byte",verb:"legyen"},array:{unit:"elem",verb:"legyen"},set:{unit:"elem",verb:"legyen"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"sz\xE1m";case"object":{if(Array.isArray(r))return"t\xF6mb";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"bemenet",email:"email c\xEDm",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO id\u0151b\xE9lyeg",date:"ISO d\xE1tum",time:"ISO id\u0151",duration:"ISO id\u0151intervallum",ipv4:"IPv4 c\xEDm",ipv6:"IPv6 c\xEDm",cidrv4:"IPv4 tartom\xE1ny",cidrv6:"IPv6 tartom\xE1ny",base64:"base64-k\xF3dolt string",base64url:"base64url-k\xF3dolt string",json_string:"JSON string",e164:"E.164 sz\xE1m",jwt:"JWT",template_literal:"bemenet"};return r=>{switch(r.code){case"invalid_type":return`\xC9rv\xE9nytelen bemenet: a v\xE1rt \xE9rt\xE9k ${r.expected}, a kapott \xE9rt\xE9k ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\xC9rv\xE9nytelen bemenet: a v\xE1rt \xE9rt\xE9k ${j(r.values[0])}`:`\xC9rv\xE9nytelen opci\xF3: valamelyik \xE9rt\xE9k v\xE1rt ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`T\xFAl nagy: ${r.origin??"\xE9rt\xE9k"} m\xE9rete t\xFAl nagy ${i}${r.maximum.toString()} ${a.unit??"elem"}`:`T\xFAl nagy: a bemeneti \xE9rt\xE9k ${r.origin??"\xE9rt\xE9k"} t\xFAl nagy: ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`T\xFAl kicsi: a bemeneti \xE9rt\xE9k ${r.origin} m\xE9rete t\xFAl kicsi ${i}${r.minimum.toString()} ${a.unit}`:`T\xFAl kicsi: a bemeneti \xE9rt\xE9k ${r.origin} t\xFAl kicsi ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\xC9rv\xE9nytelen string: "${i.prefix}" \xE9rt\xE9kkel kell kezd\u0151dnie`:i.format==="ends_with"?`\xC9rv\xE9nytelen string: "${i.suffix}" \xE9rt\xE9kkel kell v\xE9gz\u0151dnie`:i.format==="includes"?`\xC9rv\xE9nytelen string: "${i.includes}" \xE9rt\xE9ket kell tartalmaznia`:i.format==="regex"?`\xC9rv\xE9nytelen string: ${i.pattern} mint\xE1nak kell megfelelnie`:`\xC9rv\xE9nytelen ${o[i.format]??r.format}`}case"not_multiple_of":return`\xC9rv\xE9nytelen sz\xE1m: ${r.divisor} t\xF6bbsz\xF6r\xF6s\xE9nek kell lennie`;case"unrecognized_keys":return`Ismeretlen kulcs${r.keys.length>1?"s":""}: ${S(r.keys,", ")}`;case"invalid_key":return`\xC9rv\xE9nytelen kulcs ${r.origin}`;case"invalid_union":return"\xC9rv\xE9nytelen bemenet";case"invalid_element":return`\xC9rv\xE9nytelen \xE9rt\xE9k: ${r.origin}`;default:return"\xC9rv\xE9nytelen bemenet"}}};function Kv(){return{localeError:Bz()}}var Kz=()=>{let e={string:{unit:"karakter",verb:"memiliki"},file:{unit:"byte",verb:"memiliki"},array:{unit:"item",verb:"memiliki"},set:{unit:"item",verb:"memiliki"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"number";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"input",email:"alamat email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"tanggal dan waktu format ISO",date:"tanggal format ISO",time:"jam format ISO",duration:"durasi format ISO",ipv4:"alamat IPv4",ipv6:"alamat IPv6",cidrv4:"rentang alamat IPv4",cidrv6:"rentang alamat IPv6",base64:"string dengan enkode base64",base64url:"string dengan enkode base64url",json_string:"string JSON",e164:"angka E.164",jwt:"JWT",template_literal:"input"};return r=>{switch(r.code){case"invalid_type":return`Input tidak valid: diharapkan ${r.expected}, diterima ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Input tidak valid: diharapkan ${j(r.values[0])}`:`Pilihan tidak valid: diharapkan salah satu dari ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Terlalu besar: diharapkan ${r.origin??"value"} memiliki ${i}${r.maximum.toString()} ${a.unit??"elemen"}`:`Terlalu besar: diharapkan ${r.origin??"value"} menjadi ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Terlalu kecil: diharapkan ${r.origin} memiliki ${i}${r.minimum.toString()} ${a.unit}`:`Terlalu kecil: diharapkan ${r.origin} menjadi ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`String tidak valid: harus dimulai dengan "${i.prefix}"`:i.format==="ends_with"?`String tidak valid: harus berakhir dengan "${i.suffix}"`:i.format==="includes"?`String tidak valid: harus menyertakan "${i.includes}"`:i.format==="regex"?`String tidak valid: harus sesuai pola ${i.pattern}`:`${o[i.format]??r.format} tidak valid`}case"not_multiple_of":return`Angka tidak valid: harus kelipatan dari ${r.divisor}`;case"unrecognized_keys":return`Kunci tidak dikenali ${r.keys.length>1?"s":""}: ${S(r.keys,", ")}`;case"invalid_key":return`Kunci tidak valid di ${r.origin}`;case"invalid_union":return"Input tidak valid";case"invalid_element":return`Nilai tidak valid di ${r.origin}`;default:return"Input tidak valid"}}};function Hv(){return{localeError:Kz()}}var Hz=e=>{let t=typeof e;switch(t){case"number":return Number.isNaN(e)?"NaN":"n\xFAmer";case"object":{if(Array.isArray(e))return"fylki";if(e===null)return"null";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return t},Jz=()=>{let e={string:{unit:"stafi",verb:"a\xF0 hafa"},file:{unit:"b\xE6ti",verb:"a\xF0 hafa"},array:{unit:"hluti",verb:"a\xF0 hafa"},set:{unit:"hluti",verb:"a\xF0 hafa"}};function t(o){return e[o]??null}let n={regex:"gildi",email:"netfang",url:"vefsl\xF3\xF0",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO dagsetning og t\xEDmi",date:"ISO dagsetning",time:"ISO t\xEDmi",duration:"ISO t\xEDmalengd",ipv4:"IPv4 address",ipv6:"IPv6 address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded strengur",base64url:"base64url-encoded strengur",json_string:"JSON strengur",e164:"E.164 t\xF6lugildi",jwt:"JWT",template_literal:"gildi"};return o=>{switch(o.code){case"invalid_type":return`Rangt gildi: \xDE\xFA sl\xF3st inn ${Hz(o.input)} \xFEar sem \xE1 a\xF0 vera ${o.expected}`;case"invalid_value":return o.values.length===1?`Rangt gildi: gert r\xE1\xF0 fyrir ${j(o.values[0])}`:`\xD3gilt val: m\xE1 vera eitt af eftirfarandi ${S(o.values,"|")}`;case"too_big":{let r=o.inclusive?"<=":"<",i=t(o.origin);return i?`Of st\xF3rt: gert er r\xE1\xF0 fyrir a\xF0 ${o.origin??"gildi"} hafi ${r}${o.maximum.toString()} ${i.unit??"hluti"}`:`Of st\xF3rt: gert er r\xE1\xF0 fyrir a\xF0 ${o.origin??"gildi"} s\xE9 ${r}${o.maximum.toString()}`}case"too_small":{let r=o.inclusive?">=":">",i=t(o.origin);return i?`Of l\xEDti\xF0: gert er r\xE1\xF0 fyrir a\xF0 ${o.origin} hafi ${r}${o.minimum.toString()} ${i.unit}`:`Of l\xEDti\xF0: gert er r\xE1\xF0 fyrir a\xF0 ${o.origin} s\xE9 ${r}${o.minimum.toString()}`}case"invalid_format":{let r=o;return r.format==="starts_with"?`\xD3gildur strengur: ver\xF0ur a\xF0 byrja \xE1 "${r.prefix}"`:r.format==="ends_with"?`\xD3gildur strengur: ver\xF0ur a\xF0 enda \xE1 "${r.suffix}"`:r.format==="includes"?`\xD3gildur strengur: ver\xF0ur a\xF0 innihalda "${r.includes}"`:r.format==="regex"?`\xD3gildur strengur: ver\xF0ur a\xF0 fylgja mynstri ${r.pattern}`:`Rangt ${n[r.format]??o.format}`}case"not_multiple_of":return`R\xF6ng tala: ver\xF0ur a\xF0 vera margfeldi af ${o.divisor}`;case"unrecognized_keys":return`\xD3\xFEekkt ${o.keys.length>1?"ir lyklar":"ur lykill"}: ${S(o.keys,", ")}`;case"invalid_key":return`Rangur lykill \xED ${o.origin}`;case"invalid_union":return"Rangt gildi";case"invalid_element":return`Rangt gildi \xED ${o.origin}`;default:return"Rangt gildi"}}};function Jv(){return{localeError:Jz()}}var Gz=()=>{let e={string:{unit:"caratteri",verb:"avere"},file:{unit:"byte",verb:"avere"},array:{unit:"elementi",verb:"avere"},set:{unit:"elementi",verb:"avere"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"numero";case"object":{if(Array.isArray(r))return"vettore";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"input",email:"indirizzo email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data e ora ISO",date:"data ISO",time:"ora ISO",duration:"durata ISO",ipv4:"indirizzo IPv4",ipv6:"indirizzo IPv6",cidrv4:"intervallo IPv4",cidrv6:"intervallo IPv6",base64:"stringa codificata in base64",base64url:"URL codificata in base64",json_string:"stringa JSON",e164:"numero E.164",jwt:"JWT",template_literal:"input"};return r=>{switch(r.code){case"invalid_type":return`Input non valido: atteso ${r.expected}, ricevuto ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Input non valido: atteso ${j(r.values[0])}`:`Opzione non valida: atteso uno tra ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Troppo grande: ${r.origin??"valore"} deve avere ${i}${r.maximum.toString()} ${a.unit??"elementi"}`:`Troppo grande: ${r.origin??"valore"} deve essere ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Troppo piccolo: ${r.origin} deve avere ${i}${r.minimum.toString()} ${a.unit}`:`Troppo piccolo: ${r.origin} deve essere ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Stringa non valida: deve iniziare con "${i.prefix}"`:i.format==="ends_with"?`Stringa non valida: deve terminare con "${i.suffix}"`:i.format==="includes"?`Stringa non valida: deve includere "${i.includes}"`:i.format==="regex"?`Stringa non valida: deve corrispondere al pattern ${i.pattern}`:`Invalid ${o[i.format]??r.format}`}case"not_multiple_of":return`Numero non valido: deve essere un multiplo di ${r.divisor}`;case"unrecognized_keys":return`Chiav${r.keys.length>1?"i":"e"} non riconosciut${r.keys.length>1?"e":"a"}: ${S(r.keys,", ")}`;case"invalid_key":return`Chiave non valida in ${r.origin}`;case"invalid_union":return"Input non valido";case"invalid_element":return`Valore non valido in ${r.origin}`;default:return"Input non valido"}}};function Gv(){return{localeError:Gz()}}var Wz=()=>{let e={string:{unit:"\u6587\u5B57",verb:"\u3067\u3042\u308B"},file:{unit:"\u30D0\u30A4\u30C8",verb:"\u3067\u3042\u308B"},array:{unit:"\u8981\u7D20",verb:"\u3067\u3042\u308B"},set:{unit:"\u8981\u7D20",verb:"\u3067\u3042\u308B"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u6570\u5024";case"object":{if(Array.isArray(r))return"\u914D\u5217";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u5165\u529B\u5024",email:"\u30E1\u30FC\u30EB\u30A2\u30C9\u30EC\u30B9",url:"URL",emoji:"\u7D75\u6587\u5B57",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO\u65E5\u6642",date:"ISO\u65E5\u4ED8",time:"ISO\u6642\u523B",duration:"ISO\u671F\u9593",ipv4:"IPv4\u30A2\u30C9\u30EC\u30B9",ipv6:"IPv6\u30A2\u30C9\u30EC\u30B9",cidrv4:"IPv4\u7BC4\u56F2",cidrv6:"IPv6\u7BC4\u56F2",base64:"base64\u30A8\u30F3\u30B3\u30FC\u30C9\u6587\u5B57\u5217",base64url:"base64url\u30A8\u30F3\u30B3\u30FC\u30C9\u6587\u5B57\u5217",json_string:"JSON\u6587\u5B57\u5217",e164:"E.164\u756A\u53F7",jwt:"JWT",template_literal:"\u5165\u529B\u5024"};return r=>{switch(r.code){case"invalid_type":return`\u7121\u52B9\u306A\u5165\u529B: ${r.expected}\u304C\u671F\u5F85\u3055\u308C\u307E\u3057\u305F\u304C\u3001${n(r.input)}\u304C\u5165\u529B\u3055\u308C\u307E\u3057\u305F`;case"invalid_value":return r.values.length===1?`\u7121\u52B9\u306A\u5165\u529B: ${j(r.values[0])}\u304C\u671F\u5F85\u3055\u308C\u307E\u3057\u305F`:`\u7121\u52B9\u306A\u9078\u629E: ${S(r.values,"\u3001")}\u306E\u3044\u305A\u308C\u304B\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`;case"too_big":{let i=r.inclusive?"\u4EE5\u4E0B\u3067\u3042\u308B":"\u3088\u308A\u5C0F\u3055\u3044",a=t(r.origin);return a?`\u5927\u304D\u3059\u304E\u308B\u5024: ${r.origin??"\u5024"}\u306F${r.maximum.toString()}${a.unit??"\u8981\u7D20"}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:`\u5927\u304D\u3059\u304E\u308B\u5024: ${r.origin??"\u5024"}\u306F${r.maximum.toString()}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`}case"too_small":{let i=r.inclusive?"\u4EE5\u4E0A\u3067\u3042\u308B":"\u3088\u308A\u5927\u304D\u3044",a=t(r.origin);return a?`\u5C0F\u3055\u3059\u304E\u308B\u5024: ${r.origin}\u306F${r.minimum.toString()}${a.unit}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:`\u5C0F\u3055\u3059\u304E\u308B\u5024: ${r.origin}\u306F${r.minimum.toString()}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: "${i.prefix}"\u3067\u59CB\u307E\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:i.format==="ends_with"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: "${i.suffix}"\u3067\u7D42\u308F\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:i.format==="includes"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: "${i.includes}"\u3092\u542B\u3080\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:i.format==="regex"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: \u30D1\u30BF\u30FC\u30F3${i.pattern}\u306B\u4E00\u81F4\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:`\u7121\u52B9\u306A${o[i.format]??r.format}`}case"not_multiple_of":return`\u7121\u52B9\u306A\u6570\u5024: ${r.divisor}\u306E\u500D\u6570\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`;case"unrecognized_keys":return`\u8A8D\u8B58\u3055\u308C\u3066\u3044\u306A\u3044\u30AD\u30FC${r.keys.length>1?"\u7FA4":""}: ${S(r.keys,"\u3001")}`;case"invalid_key":return`${r.origin}\u5185\u306E\u7121\u52B9\u306A\u30AD\u30FC`;case"invalid_union":return"\u7121\u52B9\u306A\u5165\u529B";case"invalid_element":return`${r.origin}\u5185\u306E\u7121\u52B9\u306A\u5024`;default:return"\u7121\u52B9\u306A\u5165\u529B"}}};function Wv(){return{localeError:Wz()}}var Xz=e=>{let t=typeof e;switch(t){case"number":return Number.isNaN(e)?"NaN":"\u10E0\u10D8\u10EA\u10EE\u10D5\u10D8";case"object":{if(Array.isArray(e))return"\u10DB\u10D0\u10E1\u10D8\u10D5\u10D8";if(e===null)return"null";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return{string:"\u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8",boolean:"\u10D1\u10E3\u10DA\u10D4\u10D0\u10DC\u10D8",undefined:"undefined",bigint:"bigint",symbol:"symbol",function:"\u10E4\u10E3\u10DC\u10E5\u10EA\u10D8\u10D0"}[t]??t},Yz=()=>{let e={string:{unit:"\u10E1\u10D8\u10DB\u10D1\u10DD\u10DA\u10DD",verb:"\u10E3\u10DC\u10D3\u10D0 \u10E8\u10D4\u10D8\u10EA\u10D0\u10D5\u10D3\u10D4\u10E1"},file:{unit:"\u10D1\u10D0\u10D8\u10E2\u10D8",verb:"\u10E3\u10DC\u10D3\u10D0 \u10E8\u10D4\u10D8\u10EA\u10D0\u10D5\u10D3\u10D4\u10E1"},array:{unit:"\u10D4\u10DA\u10D4\u10DB\u10D4\u10DC\u10E2\u10D8",verb:"\u10E3\u10DC\u10D3\u10D0 \u10E8\u10D4\u10D8\u10EA\u10D0\u10D5\u10D3\u10D4\u10E1"},set:{unit:"\u10D4\u10DA\u10D4\u10DB\u10D4\u10DC\u10E2\u10D8",verb:"\u10E3\u10DC\u10D3\u10D0 \u10E8\u10D4\u10D8\u10EA\u10D0\u10D5\u10D3\u10D4\u10E1"}};function t(o){return e[o]??null}let n={regex:"\u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0",email:"\u10D4\u10DA-\u10E4\u10DD\u10E1\u10E2\u10D8\u10E1 \u10DB\u10D8\u10E1\u10D0\u10DB\u10D0\u10E0\u10D7\u10D8",url:"URL",emoji:"\u10D4\u10DB\u10DD\u10EF\u10D8",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u10D7\u10D0\u10E0\u10D8\u10E6\u10D8-\u10D3\u10E0\u10DD",date:"\u10D7\u10D0\u10E0\u10D8\u10E6\u10D8",time:"\u10D3\u10E0\u10DD",duration:"\u10EE\u10D0\u10DC\u10D2\u10E0\u10EB\u10DA\u10D8\u10D5\u10DD\u10D1\u10D0",ipv4:"IPv4 \u10DB\u10D8\u10E1\u10D0\u10DB\u10D0\u10E0\u10D7\u10D8",ipv6:"IPv6 \u10DB\u10D8\u10E1\u10D0\u10DB\u10D0\u10E0\u10D7\u10D8",cidrv4:"IPv4 \u10D3\u10D8\u10D0\u10DE\u10D0\u10D6\u10DD\u10DC\u10D8",cidrv6:"IPv6 \u10D3\u10D8\u10D0\u10DE\u10D0\u10D6\u10DD\u10DC\u10D8",base64:"base64-\u10D9\u10DD\u10D3\u10D8\u10E0\u10D4\u10D1\u10E3\u10DA\u10D8 \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8",base64url:"base64url-\u10D9\u10DD\u10D3\u10D8\u10E0\u10D4\u10D1\u10E3\u10DA\u10D8 \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8",json_string:"JSON \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8",e164:"E.164 \u10DC\u10DD\u10DB\u10D4\u10E0\u10D8",jwt:"JWT",template_literal:"\u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0"};return o=>{switch(o.code){case"invalid_type":return`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${o.expected}, \u10DB\u10D8\u10E6\u10D4\u10D1\u10E3\u10DA\u10D8 ${Xz(o.input)}`;case"invalid_value":return o.values.length===1?`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${j(o.values[0])}`:`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10D5\u10D0\u10E0\u10D8\u10D0\u10DC\u10E2\u10D8: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8\u10D0 \u10D4\u10E0\u10D7-\u10D4\u10E0\u10D7\u10D8 ${S(o.values,"|")}-\u10D3\u10D0\u10DC`;case"too_big":{let r=o.inclusive?"<=":"<",i=t(o.origin);return i?`\u10D6\u10D4\u10D3\u10DB\u10D4\u10E2\u10D0\u10D3 \u10D3\u10D8\u10D3\u10D8: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${o.origin??"\u10DB\u10DC\u10D8\u10E8\u10D5\u10DC\u10D4\u10DA\u10DD\u10D1\u10D0"} ${i.verb} ${r}${o.maximum.toString()} ${i.unit}`:`\u10D6\u10D4\u10D3\u10DB\u10D4\u10E2\u10D0\u10D3 \u10D3\u10D8\u10D3\u10D8: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${o.origin??"\u10DB\u10DC\u10D8\u10E8\u10D5\u10DC\u10D4\u10DA\u10DD\u10D1\u10D0"} \u10D8\u10E7\u10DD\u10E1 ${r}${o.maximum.toString()}`}case"too_small":{let r=o.inclusive?">=":">",i=t(o.origin);return i?`\u10D6\u10D4\u10D3\u10DB\u10D4\u10E2\u10D0\u10D3 \u10DE\u10D0\u10E2\u10D0\u10E0\u10D0: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${o.origin} ${i.verb} ${r}${o.minimum.toString()} ${i.unit}`:`\u10D6\u10D4\u10D3\u10DB\u10D4\u10E2\u10D0\u10D3 \u10DE\u10D0\u10E2\u10D0\u10E0\u10D0: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${o.origin} \u10D8\u10E7\u10DD\u10E1 ${r}${o.minimum.toString()}`}case"invalid_format":{let r=o;return r.format==="starts_with"?`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8: \u10E3\u10DC\u10D3\u10D0 \u10D8\u10EC\u10E7\u10D4\u10D1\u10DD\u10D3\u10D4\u10E1 "${r.prefix}"-\u10D8\u10D7`:r.format==="ends_with"?`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8: \u10E3\u10DC\u10D3\u10D0 \u10DB\u10D7\u10D0\u10D5\u10E0\u10D3\u10D4\u10D1\u10DD\u10D3\u10D4\u10E1 "${r.suffix}"-\u10D8\u10D7`:r.format==="includes"?`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8: \u10E3\u10DC\u10D3\u10D0 \u10E8\u10D4\u10D8\u10EA\u10D0\u10D5\u10D3\u10D4\u10E1 "${r.includes}"-\u10E1`:r.format==="regex"?`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8: \u10E3\u10DC\u10D3\u10D0 \u10E8\u10D4\u10D4\u10E1\u10D0\u10D1\u10D0\u10DB\u10D4\u10D1\u10DD\u10D3\u10D4\u10E1 \u10E8\u10D0\u10D1\u10DA\u10DD\u10DC\u10E1 ${r.pattern}`:`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 ${n[r.format]??o.format}`}case"not_multiple_of":return`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E0\u10D8\u10EA\u10EE\u10D5\u10D8: \u10E3\u10DC\u10D3\u10D0 \u10D8\u10E7\u10DD\u10E1 ${o.divisor}-\u10D8\u10E1 \u10EF\u10D4\u10E0\u10D0\u10D3\u10D8`;case"unrecognized_keys":return`\u10E3\u10EA\u10DC\u10DD\u10D1\u10D8 \u10D2\u10D0\u10E1\u10D0\u10E6\u10D4\u10D1${o.keys.length>1?"\u10D4\u10D1\u10D8":"\u10D8"}: ${S(o.keys,", ")}`;case"invalid_key":return`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10D2\u10D0\u10E1\u10D0\u10E6\u10D4\u10D1\u10D8 ${o.origin}-\u10E8\u10D8`;case"invalid_union":return"\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0";case"invalid_element":return`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10DB\u10DC\u10D8\u10E8\u10D5\u10DC\u10D4\u10DA\u10DD\u10D1\u10D0 ${o.origin}-\u10E8\u10D8`;default:return"\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0"}}};function Xv(){return{localeError:Yz()}}var Qz=()=>{let e={string:{unit:"\u178F\u17BD\u17A2\u1780\u17D2\u179F\u179A",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"},file:{unit:"\u1794\u17C3",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"},array:{unit:"\u1792\u17B6\u178F\u17BB",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"},set:{unit:"\u1792\u17B6\u178F\u17BB",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"\u1798\u17B7\u1793\u1798\u17C2\u1793\u1787\u17B6\u179B\u17C1\u1781 (NaN)":"\u179B\u17C1\u1781";case"object":{if(Array.isArray(r))return"\u17A2\u17B6\u179A\u17C1 (Array)";if(r===null)return"\u1782\u17D2\u1798\u17B6\u1793\u178F\u1798\u17D2\u179B\u17C3 (null)";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B",email:"\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793\u17A2\u17CA\u17B8\u1798\u17C2\u179B",url:"URL",emoji:"\u179F\u1789\u17D2\u1789\u17B6\u17A2\u17B6\u179A\u1798\u17D2\u1798\u178E\u17CD",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u1780\u17B6\u179B\u1794\u179A\u17B7\u1785\u17D2\u1786\u17C1\u1791 \u1793\u17B7\u1784\u1798\u17C9\u17C4\u1784 ISO",date:"\u1780\u17B6\u179B\u1794\u179A\u17B7\u1785\u17D2\u1786\u17C1\u1791 ISO",time:"\u1798\u17C9\u17C4\u1784 ISO",duration:"\u179A\u1799\u17C8\u1796\u17C1\u179B ISO",ipv4:"\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv4",ipv6:"\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv6",cidrv4:"\u178A\u17C2\u1793\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv4",cidrv6:"\u178A\u17C2\u1793\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv6",base64:"\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u17A2\u17CA\u17B7\u1780\u17BC\u178A base64",base64url:"\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u17A2\u17CA\u17B7\u1780\u17BC\u178A base64url",json_string:"\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A JSON",e164:"\u179B\u17C1\u1781 E.164",jwt:"JWT",template_literal:"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B"};return r=>{switch(r.code){case"invalid_type":return`\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${r.expected} \u1794\u17C9\u17BB\u1793\u17D2\u178F\u17C2\u1791\u1791\u17BD\u179B\u1794\u17B6\u1793 ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${j(r.values[0])}`:`\u1787\u1798\u17D2\u179A\u17BE\u179F\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1787\u17B6\u1798\u17BD\u1799\u1780\u17D2\u1793\u17BB\u1784\u1785\u17C6\u178E\u17C4\u1798 ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u1792\u17C6\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${r.origin??"\u178F\u1798\u17D2\u179B\u17C3"} ${i} ${r.maximum.toString()} ${a.unit??"\u1792\u17B6\u178F\u17BB"}`:`\u1792\u17C6\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${r.origin??"\u178F\u1798\u17D2\u179B\u17C3"} ${i} ${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u178F\u17BC\u1785\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${r.origin} ${i} ${r.minimum.toString()} ${a.unit}`:`\u178F\u17BC\u1785\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${r.origin} ${i} ${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1785\u17B6\u1794\u17CB\u1795\u17D2\u178F\u17BE\u1798\u178A\u17C4\u1799 "${i.prefix}"`:i.format==="ends_with"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1794\u1789\u17D2\u1785\u1794\u17CB\u178A\u17C4\u1799 "${i.suffix}"`:i.format==="includes"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1798\u17B6\u1793 "${i.includes}"`:i.format==="regex"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u178F\u17C2\u1795\u17D2\u1782\u17BC\u1795\u17D2\u1782\u1784\u1793\u17B9\u1784\u1791\u1798\u17D2\u179A\u1784\u17CB\u178A\u17C2\u179B\u1794\u17B6\u1793\u1780\u17C6\u178E\u178F\u17CB ${i.pattern}`:`\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 ${o[i.format]??r.format}`}case"not_multiple_of":return`\u179B\u17C1\u1781\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u178F\u17C2\u1787\u17B6\u1796\u17A0\u17BB\u1782\u17BB\u178E\u1793\u17C3 ${r.divisor}`;case"unrecognized_keys":return`\u179A\u1780\u1783\u17BE\u1789\u179F\u17C4\u1798\u17B7\u1793\u179F\u17D2\u1782\u17B6\u179B\u17CB\u17D6 ${S(r.keys,", ")}`;case"invalid_key":return`\u179F\u17C4\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u1793\u17C5\u1780\u17D2\u1793\u17BB\u1784 ${r.origin}`;case"invalid_union":return"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C";case"invalid_element":return`\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u1793\u17C5\u1780\u17D2\u1793\u17BB\u1784 ${r.origin}`;default:return"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C"}}};function Ec(){return{localeError:Qz()}}function Yv(){return Ec()}var eI=()=>{let e={string:{unit:"\uBB38\uC790",verb:"to have"},file:{unit:"\uBC14\uC774\uD2B8",verb:"to have"},array:{unit:"\uAC1C",verb:"to have"},set:{unit:"\uAC1C",verb:"to have"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"number";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\uC785\uB825",email:"\uC774\uBA54\uC77C \uC8FC\uC18C",url:"URL",emoji:"\uC774\uBAA8\uC9C0",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \uB0A0\uC9DC\uC2DC\uAC04",date:"ISO \uB0A0\uC9DC",time:"ISO \uC2DC\uAC04",duration:"ISO \uAE30\uAC04",ipv4:"IPv4 \uC8FC\uC18C",ipv6:"IPv6 \uC8FC\uC18C",cidrv4:"IPv4 \uBC94\uC704",cidrv6:"IPv6 \uBC94\uC704",base64:"base64 \uC778\uCF54\uB529 \uBB38\uC790\uC5F4",base64url:"base64url \uC778\uCF54\uB529 \uBB38\uC790\uC5F4",json_string:"JSON \uBB38\uC790\uC5F4",e164:"E.164 \uBC88\uD638",jwt:"JWT",template_literal:"\uC785\uB825"};return r=>{switch(r.code){case"invalid_type":return`\uC798\uBABB\uB41C \uC785\uB825: \uC608\uC0C1 \uD0C0\uC785\uC740 ${r.expected}, \uBC1B\uC740 \uD0C0\uC785\uC740 ${n(r.input)}\uC785\uB2C8\uB2E4`;case"invalid_value":return r.values.length===1?`\uC798\uBABB\uB41C \uC785\uB825: \uAC12\uC740 ${j(r.values[0])} \uC774\uC5B4\uC57C \uD569\uB2C8\uB2E4`:`\uC798\uBABB\uB41C \uC635\uC158: ${S(r.values,"\uB610\uB294 ")} \uC911 \uD558\uB098\uC5EC\uC57C \uD569\uB2C8\uB2E4`;case"too_big":{let i=r.inclusive?"\uC774\uD558":"\uBBF8\uB9CC",a=i==="\uBBF8\uB9CC"?"\uC774\uC5B4\uC57C \uD569\uB2C8\uB2E4":"\uC5EC\uC57C \uD569\uB2C8\uB2E4",s=t(r.origin),c=s?.unit??"\uC694\uC18C";return s?`${r.origin??"\uAC12"}\uC774 \uB108\uBB34 \uD07D\uB2C8\uB2E4: ${r.maximum.toString()}${c} ${i}${a}`:`${r.origin??"\uAC12"}\uC774 \uB108\uBB34 \uD07D\uB2C8\uB2E4: ${r.maximum.toString()} ${i}${a}`}case"too_small":{let i=r.inclusive?"\uC774\uC0C1":"\uCD08\uACFC",a=i==="\uC774\uC0C1"?"\uC774\uC5B4\uC57C \uD569\uB2C8\uB2E4":"\uC5EC\uC57C \uD569\uB2C8\uB2E4",s=t(r.origin),c=s?.unit??"\uC694\uC18C";return s?`${r.origin??"\uAC12"}\uC774 \uB108\uBB34 \uC791\uC2B5\uB2C8\uB2E4: ${r.minimum.toString()}${c} ${i}${a}`:`${r.origin??"\uAC12"}\uC774 \uB108\uBB34 \uC791\uC2B5\uB2C8\uB2E4: ${r.minimum.toString()} ${i}${a}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: "${i.prefix}"(\uC73C)\uB85C \uC2DC\uC791\uD574\uC57C \uD569\uB2C8\uB2E4`:i.format==="ends_with"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: "${i.suffix}"(\uC73C)\uB85C \uB05D\uB098\uC57C \uD569\uB2C8\uB2E4`:i.format==="includes"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: "${i.includes}"\uC744(\uB97C) \uD3EC\uD568\uD574\uC57C \uD569\uB2C8\uB2E4`:i.format==="regex"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: \uC815\uADDC\uC2DD ${i.pattern} \uD328\uD134\uACFC \uC77C\uCE58\uD574\uC57C \uD569\uB2C8\uB2E4`:`\uC798\uBABB\uB41C ${o[i.format]??r.format}`}case"not_multiple_of":return`\uC798\uBABB\uB41C \uC22B\uC790: ${r.divisor}\uC758 \uBC30\uC218\uC5EC\uC57C \uD569\uB2C8\uB2E4`;case"unrecognized_keys":return`\uC778\uC2DD\uD560 \uC218 \uC5C6\uB294 \uD0A4: ${S(r.keys,", ")}`;case"invalid_key":return`\uC798\uBABB\uB41C \uD0A4: ${r.origin}`;case"invalid_union":return"\uC798\uBABB\uB41C \uC785\uB825";case"invalid_element":return`\uC798\uBABB\uB41C \uAC12: ${r.origin}`;default:return"\uC798\uBABB\uB41C \uC785\uB825"}}};function Qv(){return{localeError:eI()}}var tI=e=>hi(typeof e,e),hi=(e,t=void 0)=>{switch(e){case"number":return Number.isNaN(t)?"NaN":"skai\u010Dius";case"bigint":return"sveikasis skai\u010Dius";case"string":return"eilut\u0117";case"boolean":return"login\u0117 reik\u0161m\u0117";case"undefined":case"void":return"neapibr\u0117\u017Eta reik\u0161m\u0117";case"function":return"funkcija";case"symbol":return"simbolis";case"object":return t===void 0?"ne\u017Einomas objektas":t===null?"nulin\u0117 reik\u0161m\u0117":Array.isArray(t)?"masyvas":Object.getPrototypeOf(t)!==Object.prototype&&t.constructor?t.constructor.name:"objektas";case"null":return"nulin\u0117 reik\u0161m\u0117"}return e},mi=e=>e.charAt(0).toUpperCase()+e.slice(1);function e_(e){let t=Math.abs(e),n=t%10,o=t%100;return o>=11&&o<=19||n===0?"many":n===1?"one":"few"}var rI=()=>{let e={string:{unit:{one:"simbolis",few:"simboliai",many:"simboli\u0173"},verb:{smaller:{inclusive:"turi b\u016Bti ne ilgesn\u0117 kaip",notInclusive:"turi b\u016Bti trumpesn\u0117 kaip"},bigger:{inclusive:"turi b\u016Bti ne trumpesn\u0117 kaip",notInclusive:"turi b\u016Bti ilgesn\u0117 kaip"}}},file:{unit:{one:"baitas",few:"baitai",many:"bait\u0173"},verb:{smaller:{inclusive:"turi b\u016Bti ne didesnis kaip",notInclusive:"turi b\u016Bti ma\u017Eesnis kaip"},bigger:{inclusive:"turi b\u016Bti ne ma\u017Eesnis kaip",notInclusive:"turi b\u016Bti didesnis kaip"}}},array:{unit:{one:"element\u0105",few:"elementus",many:"element\u0173"},verb:{smaller:{inclusive:"turi tur\u0117ti ne daugiau kaip",notInclusive:"turi tur\u0117ti ma\u017Eiau kaip"},bigger:{inclusive:"turi tur\u0117ti ne ma\u017Eiau kaip",notInclusive:"turi tur\u0117ti daugiau kaip"}}},set:{unit:{one:"element\u0105",few:"elementus",many:"element\u0173"},verb:{smaller:{inclusive:"turi tur\u0117ti ne daugiau kaip",notInclusive:"turi tur\u0117ti ma\u017Eiau kaip"},bigger:{inclusive:"turi tur\u0117ti ne ma\u017Eiau kaip",notInclusive:"turi tur\u0117ti daugiau kaip"}}}};function t(o,r,i,a){let s=e[o]??null;return s===null?s:{unit:s.unit[r],verb:s.verb[a][i?"inclusive":"notInclusive"]}}let n={regex:"\u012Fvestis",email:"el. pa\u0161to adresas",url:"URL",emoji:"jaustukas",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO data ir laikas",date:"ISO data",time:"ISO laikas",duration:"ISO trukm\u0117",ipv4:"IPv4 adresas",ipv6:"IPv6 adresas",cidrv4:"IPv4 tinklo prefiksas (CIDR)",cidrv6:"IPv6 tinklo prefiksas (CIDR)",base64:"base64 u\u017Ekoduota eilut\u0117",base64url:"base64url u\u017Ekoduota eilut\u0117",json_string:"JSON eilut\u0117",e164:"E.164 numeris",jwt:"JWT",template_literal:"\u012Fvestis"};return o=>{switch(o.code){case"invalid_type":return`Gautas tipas ${tI(o.input)}, o tik\u0117tasi - ${hi(o.expected)}`;case"invalid_value":return o.values.length===1?`Privalo b\u016Bti ${j(o.values[0])}`:`Privalo b\u016Bti vienas i\u0161 ${S(o.values,"|")} pasirinkim\u0173`;case"too_big":{let r=hi(o.origin),i=t(o.origin,e_(Number(o.maximum)),o.inclusive??!1,"smaller");if(i?.verb)return`${mi(r??o.origin??"reik\u0161m\u0117")} ${i.verb} ${o.maximum.toString()} ${i.unit??"element\u0173"}`;let a=o.inclusive?"ne didesnis kaip":"ma\u017Eesnis kaip";return`${mi(r??o.origin??"reik\u0161m\u0117")} turi b\u016Bti ${a} ${o.maximum.toString()} ${i?.unit}`}case"too_small":{let r=hi(o.origin),i=t(o.origin,e_(Number(o.minimum)),o.inclusive??!1,"bigger");if(i?.verb)return`${mi(r??o.origin??"reik\u0161m\u0117")} ${i.verb} ${o.minimum.toString()} ${i.unit??"element\u0173"}`;let a=o.inclusive?"ne ma\u017Eesnis kaip":"didesnis kaip";return`${mi(r??o.origin??"reik\u0161m\u0117")} turi b\u016Bti ${a} ${o.minimum.toString()} ${i?.unit}`}case"invalid_format":{let r=o;return r.format==="starts_with"?`Eilut\u0117 privalo prasid\u0117ti "${r.prefix}"`:r.format==="ends_with"?`Eilut\u0117 privalo pasibaigti "${r.suffix}"`:r.format==="includes"?`Eilut\u0117 privalo \u012Ftraukti "${r.includes}"`:r.format==="regex"?`Eilut\u0117 privalo atitikti ${r.pattern}`:`Neteisingas ${n[r.format]??o.format}`}case"not_multiple_of":return`Skai\u010Dius privalo b\u016Bti ${o.divisor} kartotinis.`;case"unrecognized_keys":return`Neatpa\u017Eint${o.keys.length>1?"i":"as"} rakt${o.keys.length>1?"ai":"as"}: ${S(o.keys,", ")}`;case"invalid_key":return"Rastas klaidingas raktas";case"invalid_union":return"Klaidinga \u012Fvestis";case"invalid_element":{let r=hi(o.origin);return`${mi(r??o.origin??"reik\u0161m\u0117")} turi klaiding\u0105 \u012Fvest\u012F`}default:return"Klaidinga \u012Fvestis"}}};function t_(){return{localeError:rI()}}var nI=()=>{let e={string:{unit:"\u0437\u043D\u0430\u0446\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"},file:{unit:"\u0431\u0430\u0458\u0442\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"},array:{unit:"\u0441\u0442\u0430\u0432\u043A\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"},set:{unit:"\u0441\u0442\u0430\u0432\u043A\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u0431\u0440\u043E\u0458";case"object":{if(Array.isArray(r))return"\u043D\u0438\u0437\u0430";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0432\u043D\u0435\u0441",email:"\u0430\u0434\u0440\u0435\u0441\u0430 \u043D\u0430 \u0435-\u043F\u043E\u0448\u0442\u0430",url:"URL",emoji:"\u0435\u043C\u043E\u045F\u0438",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0434\u0430\u0442\u0443\u043C \u0438 \u0432\u0440\u0435\u043C\u0435",date:"ISO \u0434\u0430\u0442\u0443\u043C",time:"ISO \u0432\u0440\u0435\u043C\u0435",duration:"ISO \u0432\u0440\u0435\u043C\u0435\u0442\u0440\u0430\u0435\u045A\u0435",ipv4:"IPv4 \u0430\u0434\u0440\u0435\u0441\u0430",ipv6:"IPv6 \u0430\u0434\u0440\u0435\u0441\u0430",cidrv4:"IPv4 \u043E\u043F\u0441\u0435\u0433",cidrv6:"IPv6 \u043E\u043F\u0441\u0435\u0433",base64:"base64-\u0435\u043D\u043A\u043E\u0434\u0438\u0440\u0430\u043D\u0430 \u043D\u0438\u0437\u0430",base64url:"base64url-\u0435\u043D\u043A\u043E\u0434\u0438\u0440\u0430\u043D\u0430 \u043D\u0438\u0437\u0430",json_string:"JSON \u043D\u0438\u0437\u0430",e164:"E.164 \u0431\u0440\u043E\u0458",jwt:"JWT",template_literal:"\u0432\u043D\u0435\u0441"};return r=>{switch(r.code){case"invalid_type":return`\u0413\u0440\u0435\u0448\u0435\u043D \u0432\u043D\u0435\u0441: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${r.expected}, \u043F\u0440\u0438\u043C\u0435\u043D\u043E ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Invalid input: expected ${j(r.values[0])}`:`\u0413\u0440\u0435\u0448\u0430\u043D\u0430 \u043E\u043F\u0446\u0438\u0458\u0430: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 \u0435\u0434\u043D\u0430 ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u0433\u043E\u043B\u0435\u043C: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${r.origin??"\u0432\u0440\u0435\u0434\u043D\u043E\u0441\u0442\u0430"} \u0434\u0430 \u0438\u043C\u0430 ${i}${r.maximum.toString()} ${a.unit??"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0438"}`:`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u0433\u043E\u043B\u0435\u043C: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${r.origin??"\u0432\u0440\u0435\u0434\u043D\u043E\u0441\u0442\u0430"} \u0434\u0430 \u0431\u0438\u0434\u0435 ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u043C\u0430\u043B: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${r.origin} \u0434\u0430 \u0438\u043C\u0430 ${i}${r.minimum.toString()} ${a.unit}`:`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u043C\u0430\u043B: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${r.origin} \u0434\u0430 \u0431\u0438\u0434\u0435 ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0437\u0430\u043F\u043E\u0447\u043D\u0443\u0432\u0430 \u0441\u043E "${i.prefix}"`:i.format==="ends_with"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0437\u0430\u0432\u0440\u0448\u0443\u0432\u0430 \u0441\u043E "${i.suffix}"`:i.format==="includes"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0432\u043A\u043B\u0443\u0447\u0443\u0432\u0430 "${i.includes}"`:i.format==="regex"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u043E\u0434\u0433\u043E\u0430\u0440\u0430 \u043D\u0430 \u043F\u0430\u0442\u0435\u0440\u043D\u043E\u0442 ${i.pattern}`:`Invalid ${o[i.format]??r.format}`}case"not_multiple_of":return`\u0413\u0440\u0435\u0448\u0435\u043D \u0431\u0440\u043E\u0458: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0431\u0438\u0434\u0435 \u0434\u0435\u043B\u0438\u0432 \u0441\u043E ${r.divisor}`;case"unrecognized_keys":return`${r.keys.length>1?"\u041D\u0435\u043F\u0440\u0435\u043F\u043E\u0437\u043D\u0430\u0435\u043D\u0438 \u043A\u043B\u0443\u0447\u0435\u0432\u0438":"\u041D\u0435\u043F\u0440\u0435\u043F\u043E\u0437\u043D\u0430\u0435\u043D \u043A\u043B\u0443\u0447"}: ${S(r.keys,", ")}`;case"invalid_key":return`\u0413\u0440\u0435\u0448\u0435\u043D \u043A\u043B\u0443\u0447 \u0432\u043E ${r.origin}`;case"invalid_union":return"\u0413\u0440\u0435\u0448\u0435\u043D \u0432\u043D\u0435\u0441";case"invalid_element":return`\u0413\u0440\u0435\u0448\u043D\u0430 \u0432\u0440\u0435\u0434\u043D\u043E\u0441\u0442 \u0432\u043E ${r.origin}`;default:return"\u0413\u0440\u0435\u0448\u0435\u043D \u0432\u043D\u0435\u0441"}}};function r_(){return{localeError:nI()}}var oI=()=>{let e={string:{unit:"aksara",verb:"mempunyai"},file:{unit:"bait",verb:"mempunyai"},array:{unit:"elemen",verb:"mempunyai"},set:{unit:"elemen",verb:"mempunyai"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"nombor";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"input",email:"alamat e-mel",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"tarikh masa ISO",date:"tarikh ISO",time:"masa ISO",duration:"tempoh ISO",ipv4:"alamat IPv4",ipv6:"alamat IPv6",cidrv4:"julat IPv4",cidrv6:"julat IPv6",base64:"string dikodkan base64",base64url:"string dikodkan base64url",json_string:"string JSON",e164:"nombor E.164",jwt:"JWT",template_literal:"input"};return r=>{switch(r.code){case"invalid_type":return`Input tidak sah: dijangka ${r.expected}, diterima ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Input tidak sah: dijangka ${j(r.values[0])}`:`Pilihan tidak sah: dijangka salah satu daripada ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Terlalu besar: dijangka ${r.origin??"nilai"} ${a.verb} ${i}${r.maximum.toString()} ${a.unit??"elemen"}`:`Terlalu besar: dijangka ${r.origin??"nilai"} adalah ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Terlalu kecil: dijangka ${r.origin} ${a.verb} ${i}${r.minimum.toString()} ${a.unit}`:`Terlalu kecil: dijangka ${r.origin} adalah ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`String tidak sah: mesti bermula dengan "${i.prefix}"`:i.format==="ends_with"?`String tidak sah: mesti berakhir dengan "${i.suffix}"`:i.format==="includes"?`String tidak sah: mesti mengandungi "${i.includes}"`:i.format==="regex"?`String tidak sah: mesti sepadan dengan corak ${i.pattern}`:`${o[i.format]??r.format} tidak sah`}case"not_multiple_of":return`Nombor tidak sah: perlu gandaan ${r.divisor}`;case"unrecognized_keys":return`Kunci tidak dikenali: ${S(r.keys,", ")}`;case"invalid_key":return`Kunci tidak sah dalam ${r.origin}`;case"invalid_union":return"Input tidak sah";case"invalid_element":return`Nilai tidak sah dalam ${r.origin}`;default:return"Input tidak sah"}}};function n_(){return{localeError:oI()}}var iI=()=>{let e={string:{unit:"tekens"},file:{unit:"bytes"},array:{unit:"elementen"},set:{unit:"elementen"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"getal";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"invoer",email:"emailadres",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datum en tijd",date:"ISO datum",time:"ISO tijd",duration:"ISO duur",ipv4:"IPv4-adres",ipv6:"IPv6-adres",cidrv4:"IPv4-bereik",cidrv6:"IPv6-bereik",base64:"base64-gecodeerde tekst",base64url:"base64 URL-gecodeerde tekst",json_string:"JSON string",e164:"E.164-nummer",jwt:"JWT",template_literal:"invoer"};return r=>{switch(r.code){case"invalid_type":return`Ongeldige invoer: verwacht ${r.expected}, ontving ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Ongeldige invoer: verwacht ${j(r.values[0])}`:`Ongeldige optie: verwacht \xE9\xE9n van ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Te lang: verwacht dat ${r.origin??"waarde"} ${i}${r.maximum.toString()} ${a.unit??"elementen"} bevat`:`Te lang: verwacht dat ${r.origin??"waarde"} ${i}${r.maximum.toString()} is`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Te kort: verwacht dat ${r.origin} ${i}${r.minimum.toString()} ${a.unit} bevat`:`Te kort: verwacht dat ${r.origin} ${i}${r.minimum.toString()} is`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Ongeldige tekst: moet met "${i.prefix}" beginnen`:i.format==="ends_with"?`Ongeldige tekst: moet op "${i.suffix}" eindigen`:i.format==="includes"?`Ongeldige tekst: moet "${i.includes}" bevatten`:i.format==="regex"?`Ongeldige tekst: moet overeenkomen met patroon ${i.pattern}`:`Ongeldig: ${o[i.format]??r.format}`}case"not_multiple_of":return`Ongeldig getal: moet een veelvoud van ${r.divisor} zijn`;case"unrecognized_keys":return`Onbekende key${r.keys.length>1?"s":""}: ${S(r.keys,", ")}`;case"invalid_key":return`Ongeldige key in ${r.origin}`;case"invalid_union":return"Ongeldige invoer";case"invalid_element":return`Ongeldige waarde in ${r.origin}`;default:return"Ongeldige invoer"}}};function o_(){return{localeError:iI()}}var aI=()=>{let e={string:{unit:"tegn",verb:"\xE5 ha"},file:{unit:"bytes",verb:"\xE5 ha"},array:{unit:"elementer",verb:"\xE5 inneholde"},set:{unit:"elementer",verb:"\xE5 inneholde"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"tall";case"object":{if(Array.isArray(r))return"liste";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"input",email:"e-postadresse",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO dato- og klokkeslett",date:"ISO-dato",time:"ISO-klokkeslett",duration:"ISO-varighet",ipv4:"IPv4-omr\xE5de",ipv6:"IPv6-omr\xE5de",cidrv4:"IPv4-spekter",cidrv6:"IPv6-spekter",base64:"base64-enkodet streng",base64url:"base64url-enkodet streng",json_string:"JSON-streng",e164:"E.164-nummer",jwt:"JWT",template_literal:"input"};return r=>{switch(r.code){case"invalid_type":return`Ugyldig input: forventet ${r.expected}, fikk ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Ugyldig verdi: forventet ${j(r.values[0])}`:`Ugyldig valg: forventet en av ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`For stor(t): forventet ${r.origin??"value"} til \xE5 ha ${i}${r.maximum.toString()} ${a.unit??"elementer"}`:`For stor(t): forventet ${r.origin??"value"} til \xE5 ha ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`For lite(n): forventet ${r.origin} til \xE5 ha ${i}${r.minimum.toString()} ${a.unit}`:`For lite(n): forventet ${r.origin} til \xE5 ha ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Ugyldig streng: m\xE5 starte med "${i.prefix}"`:i.format==="ends_with"?`Ugyldig streng: m\xE5 ende med "${i.suffix}"`:i.format==="includes"?`Ugyldig streng: m\xE5 inneholde "${i.includes}"`:i.format==="regex"?`Ugyldig streng: m\xE5 matche m\xF8nsteret ${i.pattern}`:`Ugyldig ${o[i.format]??r.format}`}case"not_multiple_of":return`Ugyldig tall: m\xE5 v\xE6re et multiplum av ${r.divisor}`;case"unrecognized_keys":return`${r.keys.length>1?"Ukjente n\xF8kler":"Ukjent n\xF8kkel"}: ${S(r.keys,", ")}`;case"invalid_key":return`Ugyldig n\xF8kkel i ${r.origin}`;case"invalid_union":return"Ugyldig input";case"invalid_element":return`Ugyldig verdi i ${r.origin}`;default:return"Ugyldig input"}}};function i_(){return{localeError:aI()}}var sI=()=>{let e={string:{unit:"harf",verb:"olmal\u0131d\u0131r"},file:{unit:"bayt",verb:"olmal\u0131d\u0131r"},array:{unit:"unsur",verb:"olmal\u0131d\u0131r"},set:{unit:"unsur",verb:"olmal\u0131d\u0131r"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"numara";case"object":{if(Array.isArray(r))return"saf";if(r===null)return"gayb";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"giren",email:"epostag\xE2h",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO heng\xE2m\u0131",date:"ISO tarihi",time:"ISO zaman\u0131",duration:"ISO m\xFCddeti",ipv4:"IPv4 ni\u015F\xE2n\u0131",ipv6:"IPv6 ni\u015F\xE2n\u0131",cidrv4:"IPv4 menzili",cidrv6:"IPv6 menzili",base64:"base64-\u015Fifreli metin",base64url:"base64url-\u015Fifreli metin",json_string:"JSON metin",e164:"E.164 say\u0131s\u0131",jwt:"JWT",template_literal:"giren"};return r=>{switch(r.code){case"invalid_type":return`F\xE2sit giren: umulan ${r.expected}, al\u0131nan ${n(r.input)}`;case"invalid_value":return r.values.length===1?`F\xE2sit giren: umulan ${j(r.values[0])}`:`F\xE2sit tercih: m\xFBteberler ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Fazla b\xFCy\xFCk: ${r.origin??"value"}, ${i}${r.maximum.toString()} ${a.unit??"elements"} sahip olmal\u0131yd\u0131.`:`Fazla b\xFCy\xFCk: ${r.origin??"value"}, ${i}${r.maximum.toString()} olmal\u0131yd\u0131.`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Fazla k\xFC\xE7\xFCk: ${r.origin}, ${i}${r.minimum.toString()} ${a.unit} sahip olmal\u0131yd\u0131.`:`Fazla k\xFC\xE7\xFCk: ${r.origin}, ${i}${r.minimum.toString()} olmal\u0131yd\u0131.`}case"invalid_format":{let i=r;return i.format==="starts_with"?`F\xE2sit metin: "${i.prefix}" ile ba\u015Flamal\u0131.`:i.format==="ends_with"?`F\xE2sit metin: "${i.suffix}" ile bitmeli.`:i.format==="includes"?`F\xE2sit metin: "${i.includes}" ihtiv\xE2 etmeli.`:i.format==="regex"?`F\xE2sit metin: ${i.pattern} nak\u015F\u0131na uymal\u0131.`:`F\xE2sit ${o[i.format]??r.format}`}case"not_multiple_of":return`F\xE2sit say\u0131: ${r.divisor} kat\u0131 olmal\u0131yd\u0131.`;case"unrecognized_keys":return`Tan\u0131nmayan anahtar ${r.keys.length>1?"s":""}: ${S(r.keys,", ")}`;case"invalid_key":return`${r.origin} i\xE7in tan\u0131nmayan anahtar var.`;case"invalid_union":return"Giren tan\u0131namad\u0131.";case"invalid_element":return`${r.origin} i\xE7in tan\u0131nmayan k\u0131ymet var.`;default:return"K\u0131ymet tan\u0131namad\u0131."}}};function a_(){return{localeError:sI()}}var cI=()=>{let e={string:{unit:"\u062A\u0648\u06A9\u064A",verb:"\u0648\u0644\u0631\u064A"},file:{unit:"\u0628\u0627\u06CC\u067C\u0633",verb:"\u0648\u0644\u0631\u064A"},array:{unit:"\u062A\u0648\u06A9\u064A",verb:"\u0648\u0644\u0631\u064A"},set:{unit:"\u062A\u0648\u06A9\u064A",verb:"\u0648\u0644\u0631\u064A"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u0639\u062F\u062F";case"object":{if(Array.isArray(r))return"\u0627\u0631\u06D0";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0648\u0631\u0648\u062F\u064A",email:"\u0628\u0631\u06CC\u069A\u0646\u0627\u0644\u06CC\u06A9",url:"\u06CC\u0648 \u0622\u0631 \u0627\u0644",emoji:"\u0627\u06CC\u0645\u0648\u062C\u064A",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u0646\u06CC\u067C\u0647 \u0627\u0648 \u0648\u062E\u062A",date:"\u0646\u06D0\u067C\u0647",time:"\u0648\u062E\u062A",duration:"\u0645\u0648\u062F\u0647",ipv4:"\u062F IPv4 \u067E\u062A\u0647",ipv6:"\u062F IPv6 \u067E\u062A\u0647",cidrv4:"\u062F IPv4 \u0633\u0627\u062D\u0647",cidrv6:"\u062F IPv6 \u0633\u0627\u062D\u0647",base64:"base64-encoded \u0645\u062A\u0646",base64url:"base64url-encoded \u0645\u062A\u0646",json_string:"JSON \u0645\u062A\u0646",e164:"\u062F E.164 \u0634\u0645\u06D0\u0631\u0647",jwt:"JWT",template_literal:"\u0648\u0631\u0648\u062F\u064A"};return r=>{switch(r.code){case"invalid_type":return`\u0646\u0627\u0633\u0645 \u0648\u0631\u0648\u062F\u064A: \u0628\u0627\u06CC\u062F ${r.expected} \u0648\u0627\u06CC, \u0645\u06AB\u0631 ${n(r.input)} \u062A\u0631\u0644\u0627\u0633\u0647 \u0634\u0648`;case"invalid_value":return r.values.length===1?`\u0646\u0627\u0633\u0645 \u0648\u0631\u0648\u062F\u064A: \u0628\u0627\u06CC\u062F ${j(r.values[0])} \u0648\u0627\u06CC`:`\u0646\u0627\u0633\u0645 \u0627\u0646\u062A\u062E\u0627\u0628: \u0628\u0627\u06CC\u062F \u06CC\u0648 \u0644\u0647 ${S(r.values,"|")} \u0685\u062E\u0647 \u0648\u0627\u06CC`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u0689\u06CC\u0631 \u0644\u0648\u06CC: ${r.origin??"\u0627\u0631\u0632\u069A\u062A"} \u0628\u0627\u06CC\u062F ${i}${r.maximum.toString()} ${a.unit??"\u0639\u0646\u0635\u0631\u0648\u0646\u0647"} \u0648\u0644\u0631\u064A`:`\u0689\u06CC\u0631 \u0644\u0648\u06CC: ${r.origin??"\u0627\u0631\u0632\u069A\u062A"} \u0628\u0627\u06CC\u062F ${i}${r.maximum.toString()} \u0648\u064A`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u0689\u06CC\u0631 \u06A9\u0648\u0686\u0646\u06CC: ${r.origin} \u0628\u0627\u06CC\u062F ${i}${r.minimum.toString()} ${a.unit} \u0648\u0644\u0631\u064A`:`\u0689\u06CC\u0631 \u06A9\u0648\u0686\u0646\u06CC: ${r.origin} \u0628\u0627\u06CC\u062F ${i}${r.minimum.toString()} \u0648\u064A`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F \u062F "${i.prefix}" \u0633\u0631\u0647 \u067E\u06CC\u0644 \u0634\u064A`:i.format==="ends_with"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F \u062F "${i.suffix}" \u0633\u0631\u0647 \u067E\u0627\u06CC \u062A\u0647 \u0648\u0631\u0633\u064A\u0696\u064A`:i.format==="includes"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F "${i.includes}" \u0648\u0644\u0631\u064A`:i.format==="regex"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F \u062F ${i.pattern} \u0633\u0631\u0647 \u0645\u0637\u0627\u0628\u0642\u062A \u0648\u0644\u0631\u064A`:`${o[i.format]??r.format} \u0646\u0627\u0633\u0645 \u062F\u06CC`}case"not_multiple_of":return`\u0646\u0627\u0633\u0645 \u0639\u062F\u062F: \u0628\u0627\u06CC\u062F \u062F ${r.divisor} \u0645\u0636\u0631\u0628 \u0648\u064A`;case"unrecognized_keys":return`\u0646\u0627\u0633\u0645 ${r.keys.length>1?"\u06A9\u0644\u06CC\u0689\u0648\u0646\u0647":"\u06A9\u0644\u06CC\u0689"}: ${S(r.keys,", ")}`;case"invalid_key":return`\u0646\u0627\u0633\u0645 \u06A9\u0644\u06CC\u0689 \u067E\u0647 ${r.origin} \u06A9\u06D0`;case"invalid_union":return"\u0646\u0627\u0633\u0645\u0647 \u0648\u0631\u0648\u062F\u064A";case"invalid_element":return`\u0646\u0627\u0633\u0645 \u0639\u0646\u0635\u0631 \u067E\u0647 ${r.origin} \u06A9\u06D0`;default:return"\u0646\u0627\u0633\u0645\u0647 \u0648\u0631\u0648\u062F\u064A"}}};function s_(){return{localeError:cI()}}var uI=()=>{let e={string:{unit:"znak\xF3w",verb:"mie\u0107"},file:{unit:"bajt\xF3w",verb:"mie\u0107"},array:{unit:"element\xF3w",verb:"mie\u0107"},set:{unit:"element\xF3w",verb:"mie\u0107"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"liczba";case"object":{if(Array.isArray(r))return"tablica";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"wyra\u017Cenie",email:"adres email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data i godzina w formacie ISO",date:"data w formacie ISO",time:"godzina w formacie ISO",duration:"czas trwania ISO",ipv4:"adres IPv4",ipv6:"adres IPv6",cidrv4:"zakres IPv4",cidrv6:"zakres IPv6",base64:"ci\u0105g znak\xF3w zakodowany w formacie base64",base64url:"ci\u0105g znak\xF3w zakodowany w formacie base64url",json_string:"ci\u0105g znak\xF3w w formacie JSON",e164:"liczba E.164",jwt:"JWT",template_literal:"wej\u015Bcie"};return r=>{switch(r.code){case"invalid_type":return`Nieprawid\u0142owe dane wej\u015Bciowe: oczekiwano ${r.expected}, otrzymano ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Nieprawid\u0142owe dane wej\u015Bciowe: oczekiwano ${j(r.values[0])}`:`Nieprawid\u0142owa opcja: oczekiwano jednej z warto\u015Bci ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Za du\u017Ca warto\u015B\u0107: oczekiwano, \u017Ce ${r.origin??"warto\u015B\u0107"} b\u0119dzie mie\u0107 ${i}${r.maximum.toString()} ${a.unit??"element\xF3w"}`:`Zbyt du\u017C(y/a/e): oczekiwano, \u017Ce ${r.origin??"warto\u015B\u0107"} b\u0119dzie wynosi\u0107 ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Za ma\u0142a warto\u015B\u0107: oczekiwano, \u017Ce ${r.origin??"warto\u015B\u0107"} b\u0119dzie mie\u0107 ${i}${r.minimum.toString()} ${a.unit??"element\xF3w"}`:`Zbyt ma\u0142(y/a/e): oczekiwano, \u017Ce ${r.origin??"warto\u015B\u0107"} b\u0119dzie wynosi\u0107 ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi zaczyna\u0107 si\u0119 od "${i.prefix}"`:i.format==="ends_with"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi ko\u0144czy\u0107 si\u0119 na "${i.suffix}"`:i.format==="includes"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi zawiera\u0107 "${i.includes}"`:i.format==="regex"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi odpowiada\u0107 wzorcowi ${i.pattern}`:`Nieprawid\u0142ow(y/a/e) ${o[i.format]??r.format}`}case"not_multiple_of":return`Nieprawid\u0142owa liczba: musi by\u0107 wielokrotno\u015Bci\u0105 ${r.divisor}`;case"unrecognized_keys":return`Nierozpoznane klucze${r.keys.length>1?"s":""}: ${S(r.keys,", ")}`;case"invalid_key":return`Nieprawid\u0142owy klucz w ${r.origin}`;case"invalid_union":return"Nieprawid\u0142owe dane wej\u015Bciowe";case"invalid_element":return`Nieprawid\u0142owa warto\u015B\u0107 w ${r.origin}`;default:return"Nieprawid\u0142owe dane wej\u015Bciowe"}}};function c_(){return{localeError:uI()}}var lI=()=>{let e={string:{unit:"caracteres",verb:"ter"},file:{unit:"bytes",verb:"ter"},array:{unit:"itens",verb:"ter"},set:{unit:"itens",verb:"ter"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"n\xFAmero";case"object":{if(Array.isArray(r))return"array";if(r===null)return"nulo";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"padr\xE3o",email:"endere\xE7o de e-mail",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data e hora ISO",date:"data ISO",time:"hora ISO",duration:"dura\xE7\xE3o ISO",ipv4:"endere\xE7o IPv4",ipv6:"endere\xE7o IPv6",cidrv4:"faixa de IPv4",cidrv6:"faixa de IPv6",base64:"texto codificado em base64",base64url:"URL codificada em base64",json_string:"texto JSON",e164:"n\xFAmero E.164",jwt:"JWT",template_literal:"entrada"};return r=>{switch(r.code){case"invalid_type":return`Tipo inv\xE1lido: esperado ${r.expected}, recebido ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Entrada inv\xE1lida: esperado ${j(r.values[0])}`:`Op\xE7\xE3o inv\xE1lida: esperada uma das ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Muito grande: esperado que ${r.origin??"valor"} tivesse ${i}${r.maximum.toString()} ${a.unit??"elementos"}`:`Muito grande: esperado que ${r.origin??"valor"} fosse ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Muito pequeno: esperado que ${r.origin} tivesse ${i}${r.minimum.toString()} ${a.unit}`:`Muito pequeno: esperado que ${r.origin} fosse ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Texto inv\xE1lido: deve come\xE7ar com "${i.prefix}"`:i.format==="ends_with"?`Texto inv\xE1lido: deve terminar com "${i.suffix}"`:i.format==="includes"?`Texto inv\xE1lido: deve incluir "${i.includes}"`:i.format==="regex"?`Texto inv\xE1lido: deve corresponder ao padr\xE3o ${i.pattern}`:`${o[i.format]??r.format} inv\xE1lido`}case"not_multiple_of":return`N\xFAmero inv\xE1lido: deve ser m\xFAltiplo de ${r.divisor}`;case"unrecognized_keys":return`Chave${r.keys.length>1?"s":""} desconhecida${r.keys.length>1?"s":""}: ${S(r.keys,", ")}`;case"invalid_key":return`Chave inv\xE1lida em ${r.origin}`;case"invalid_union":return"Entrada inv\xE1lida";case"invalid_element":return`Valor inv\xE1lido em ${r.origin}`;default:return"Campo inv\xE1lido"}}};function u_(){return{localeError:lI()}}function l_(e,t,n,o){let r=Math.abs(e),i=r%10,a=r%100;return a>=11&&a<=19?o:i===1?t:i>=2&&i<=4?n:o}var dI=()=>{let e={string:{unit:{one:"\u0441\u0438\u043C\u0432\u043E\u043B",few:"\u0441\u0438\u043C\u0432\u043E\u043B\u0430",many:"\u0441\u0438\u043C\u0432\u043E\u043B\u043E\u0432"},verb:"\u0438\u043C\u0435\u0442\u044C"},file:{unit:{one:"\u0431\u0430\u0439\u0442",few:"\u0431\u0430\u0439\u0442\u0430",many:"\u0431\u0430\u0439\u0442"},verb:"\u0438\u043C\u0435\u0442\u044C"},array:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u043E\u0432"},verb:"\u0438\u043C\u0435\u0442\u044C"},set:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u043E\u0432"},verb:"\u0438\u043C\u0435\u0442\u044C"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u0447\u0438\u0441\u043B\u043E";case"object":{if(Array.isArray(r))return"\u043C\u0430\u0441\u0441\u0438\u0432";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0432\u0432\u043E\u0434",email:"email \u0430\u0434\u0440\u0435\u0441",url:"URL",emoji:"\u044D\u043C\u043E\u0434\u0437\u0438",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0434\u0430\u0442\u0430 \u0438 \u0432\u0440\u0435\u043C\u044F",date:"ISO \u0434\u0430\u0442\u0430",time:"ISO \u0432\u0440\u0435\u043C\u044F",duration:"ISO \u0434\u043B\u0438\u0442\u0435\u043B\u044C\u043D\u043E\u0441\u0442\u044C",ipv4:"IPv4 \u0430\u0434\u0440\u0435\u0441",ipv6:"IPv6 \u0430\u0434\u0440\u0435\u0441",cidrv4:"IPv4 \u0434\u0438\u0430\u043F\u0430\u0437\u043E\u043D",cidrv6:"IPv6 \u0434\u0438\u0430\u043F\u0430\u0437\u043E\u043D",base64:"\u0441\u0442\u0440\u043E\u043A\u0430 \u0432 \u0444\u043E\u0440\u043C\u0430\u0442\u0435 base64",base64url:"\u0441\u0442\u0440\u043E\u043A\u0430 \u0432 \u0444\u043E\u0440\u043C\u0430\u0442\u0435 base64url",json_string:"JSON \u0441\u0442\u0440\u043E\u043A\u0430",e164:"\u043D\u043E\u043C\u0435\u0440 E.164",jwt:"JWT",template_literal:"\u0432\u0432\u043E\u0434"};return r=>{switch(r.code){case"invalid_type":return`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0432\u0432\u043E\u0434: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C ${r.expected}, \u043F\u043E\u043B\u0443\u0447\u0435\u043D\u043E ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0432\u0432\u043E\u0434: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C ${j(r.values[0])}`:`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0432\u0430\u0440\u0438\u0430\u043D\u0442: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C \u043E\u0434\u043D\u043E \u0438\u0437 ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);if(a){let s=Number(r.maximum),c=l_(s,a.unit.one,a.unit.few,a.unit.many);return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u0431\u043E\u043B\u044C\u0448\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${r.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435"} \u0431\u0443\u0434\u0435\u0442 \u0438\u043C\u0435\u0442\u044C ${i}${r.maximum.toString()} ${c}`}return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u0431\u043E\u043B\u044C\u0448\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${r.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435"} \u0431\u0443\u0434\u0435\u0442 ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);if(a){let s=Number(r.minimum),c=l_(s,a.unit.one,a.unit.few,a.unit.many);return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u043C\u0430\u043B\u0435\u043D\u044C\u043A\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${r.origin} \u0431\u0443\u0434\u0435\u0442 \u0438\u043C\u0435\u0442\u044C ${i}${r.minimum.toString()} ${c}`}return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u043C\u0430\u043B\u0435\u043D\u044C\u043A\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${r.origin} \u0431\u0443\u0434\u0435\u0442 ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u043D\u0430\u0447\u0438\u043D\u0430\u0442\u044C\u0441\u044F \u0441 "${i.prefix}"`:i.format==="ends_with"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u0437\u0430\u043A\u0430\u043D\u0447\u0438\u0432\u0430\u0442\u044C\u0441\u044F \u043D\u0430 "${i.suffix}"`:i.format==="includes"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u0441\u043E\u0434\u0435\u0440\u0436\u0430\u0442\u044C "${i.includes}"`:i.format==="regex"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u0441\u043E\u043E\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u043E\u0432\u0430\u0442\u044C \u0448\u0430\u0431\u043B\u043E\u043D\u0443 ${i.pattern}`:`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 ${o[i.format]??r.format}`}case"not_multiple_of":return`\u041D\u0435\u0432\u0435\u0440\u043D\u043E\u0435 \u0447\u0438\u0441\u043B\u043E: \u0434\u043E\u043B\u0436\u043D\u043E \u0431\u044B\u0442\u044C \u043A\u0440\u0430\u0442\u043D\u044B\u043C ${r.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u0430\u0441\u043F\u043E\u0437\u043D\u0430\u043D\u043D${r.keys.length>1?"\u044B\u0435":"\u044B\u0439"} \u043A\u043B\u044E\u0447${r.keys.length>1?"\u0438":""}: ${S(r.keys,", ")}`;case"invalid_key":return`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u043A\u043B\u044E\u0447 \u0432 ${r.origin}`;case"invalid_union":return"\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0435 \u0432\u0445\u043E\u0434\u043D\u044B\u0435 \u0434\u0430\u043D\u043D\u044B\u0435";case"invalid_element":return`\u041D\u0435\u0432\u0435\u0440\u043D\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435 \u0432 ${r.origin}`;default:return"\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0435 \u0432\u0445\u043E\u0434\u043D\u044B\u0435 \u0434\u0430\u043D\u043D\u044B\u0435"}}};function d_(){return{localeError:dI()}}var fI=()=>{let e={string:{unit:"znakov",verb:"imeti"},file:{unit:"bajtov",verb:"imeti"},array:{unit:"elementov",verb:"imeti"},set:{unit:"elementov",verb:"imeti"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u0161tevilo";case"object":{if(Array.isArray(r))return"tabela";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"vnos",email:"e-po\u0161tni naslov",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datum in \u010Das",date:"ISO datum",time:"ISO \u010Das",duration:"ISO trajanje",ipv4:"IPv4 naslov",ipv6:"IPv6 naslov",cidrv4:"obseg IPv4",cidrv6:"obseg IPv6",base64:"base64 kodiran niz",base64url:"base64url kodiran niz",json_string:"JSON niz",e164:"E.164 \u0161tevilka",jwt:"JWT",template_literal:"vnos"};return r=>{switch(r.code){case"invalid_type":return`Neveljaven vnos: pri\u010Dakovano ${r.expected}, prejeto ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Neveljaven vnos: pri\u010Dakovano ${j(r.values[0])}`:`Neveljavna mo\u017Enost: pri\u010Dakovano eno izmed ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Preveliko: pri\u010Dakovano, da bo ${r.origin??"vrednost"} imelo ${i}${r.maximum.toString()} ${a.unit??"elementov"}`:`Preveliko: pri\u010Dakovano, da bo ${r.origin??"vrednost"} ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Premajhno: pri\u010Dakovano, da bo ${r.origin} imelo ${i}${r.minimum.toString()} ${a.unit}`:`Premajhno: pri\u010Dakovano, da bo ${r.origin} ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Neveljaven niz: mora se za\u010Deti z "${i.prefix}"`:i.format==="ends_with"?`Neveljaven niz: mora se kon\u010Dati z "${i.suffix}"`:i.format==="includes"?`Neveljaven niz: mora vsebovati "${i.includes}"`:i.format==="regex"?`Neveljaven niz: mora ustrezati vzorcu ${i.pattern}`:`Neveljaven ${o[i.format]??r.format}`}case"not_multiple_of":return`Neveljavno \u0161tevilo: mora biti ve\u010Dkratnik ${r.divisor}`;case"unrecognized_keys":return`Neprepoznan${r.keys.length>1?"i klju\u010Di":" klju\u010D"}: ${S(r.keys,", ")}`;case"invalid_key":return`Neveljaven klju\u010D v ${r.origin}`;case"invalid_union":return"Neveljaven vnos";case"invalid_element":return`Neveljavna vrednost v ${r.origin}`;default:return"Neveljaven vnos"}}};function f_(){return{localeError:fI()}}var pI=()=>{let e={string:{unit:"tecken",verb:"att ha"},file:{unit:"bytes",verb:"att ha"},array:{unit:"objekt",verb:"att inneh\xE5lla"},set:{unit:"objekt",verb:"att inneh\xE5lla"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"antal";case"object":{if(Array.isArray(r))return"lista";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"regulj\xE4rt uttryck",email:"e-postadress",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-datum och tid",date:"ISO-datum",time:"ISO-tid",duration:"ISO-varaktighet",ipv4:"IPv4-intervall",ipv6:"IPv6-intervall",cidrv4:"IPv4-spektrum",cidrv6:"IPv6-spektrum",base64:"base64-kodad str\xE4ng",base64url:"base64url-kodad str\xE4ng",json_string:"JSON-str\xE4ng",e164:"E.164-nummer",jwt:"JWT",template_literal:"mall-literal"};return r=>{switch(r.code){case"invalid_type":return`Ogiltig inmatning: f\xF6rv\xE4ntat ${r.expected}, fick ${n(r.input)}`;case"invalid_value":return r.values.length===1?`Ogiltig inmatning: f\xF6rv\xE4ntat ${j(r.values[0])}`:`Ogiltigt val: f\xF6rv\xE4ntade en av ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`F\xF6r stor(t): f\xF6rv\xE4ntade ${r.origin??"v\xE4rdet"} att ha ${i}${r.maximum.toString()} ${a.unit??"element"}`:`F\xF6r stor(t): f\xF6rv\xE4ntat ${r.origin??"v\xE4rdet"} att ha ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`F\xF6r lite(t): f\xF6rv\xE4ntade ${r.origin??"v\xE4rdet"} att ha ${i}${r.minimum.toString()} ${a.unit}`:`F\xF6r lite(t): f\xF6rv\xE4ntade ${r.origin??"v\xE4rdet"} att ha ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Ogiltig str\xE4ng: m\xE5ste b\xF6rja med "${i.prefix}"`:i.format==="ends_with"?`Ogiltig str\xE4ng: m\xE5ste sluta med "${i.suffix}"`:i.format==="includes"?`Ogiltig str\xE4ng: m\xE5ste inneh\xE5lla "${i.includes}"`:i.format==="regex"?`Ogiltig str\xE4ng: m\xE5ste matcha m\xF6nstret "${i.pattern}"`:`Ogiltig(t) ${o[i.format]??r.format}`}case"not_multiple_of":return`Ogiltigt tal: m\xE5ste vara en multipel av ${r.divisor}`;case"unrecognized_keys":return`${r.keys.length>1?"Ok\xE4nda nycklar":"Ok\xE4nd nyckel"}: ${S(r.keys,", ")}`;case"invalid_key":return`Ogiltig nyckel i ${r.origin??"v\xE4rdet"}`;case"invalid_union":return"Ogiltig input";case"invalid_element":return`Ogiltigt v\xE4rde i ${r.origin??"v\xE4rdet"}`;default:return"Ogiltig input"}}};function p_(){return{localeError:pI()}}var mI=()=>{let e={string:{unit:"\u0B8E\u0BB4\u0BC1\u0BA4\u0BCD\u0BA4\u0BC1\u0B95\u0BCD\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"},file:{unit:"\u0BAA\u0BC8\u0B9F\u0BCD\u0B9F\u0BC1\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"},array:{unit:"\u0B89\u0BB1\u0BC1\u0BAA\u0BCD\u0BAA\u0BC1\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"},set:{unit:"\u0B89\u0BB1\u0BC1\u0BAA\u0BCD\u0BAA\u0BC1\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"\u0B8E\u0BA3\u0BCD \u0B85\u0BB2\u0BCD\u0BB2\u0BBE\u0BA4\u0BA4\u0BC1":"\u0B8E\u0BA3\u0BCD";case"object":{if(Array.isArray(r))return"\u0B85\u0BA3\u0BBF";if(r===null)return"\u0BB5\u0BC6\u0BB1\u0BC1\u0BAE\u0BC8";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1",email:"\u0BAE\u0BBF\u0BA9\u0BCD\u0BA9\u0B9E\u0BCD\u0B9A\u0BB2\u0BCD \u0BAE\u0BC1\u0B95\u0BB5\u0BB0\u0BBF",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0BA4\u0BC7\u0BA4\u0BBF \u0BA8\u0BC7\u0BB0\u0BAE\u0BCD",date:"ISO \u0BA4\u0BC7\u0BA4\u0BBF",time:"ISO \u0BA8\u0BC7\u0BB0\u0BAE\u0BCD",duration:"ISO \u0B95\u0BBE\u0BB2 \u0B85\u0BB3\u0BB5\u0BC1",ipv4:"IPv4 \u0BAE\u0BC1\u0B95\u0BB5\u0BB0\u0BBF",ipv6:"IPv6 \u0BAE\u0BC1\u0B95\u0BB5\u0BB0\u0BBF",cidrv4:"IPv4 \u0BB5\u0BB0\u0BAE\u0BCD\u0BAA\u0BC1",cidrv6:"IPv6 \u0BB5\u0BB0\u0BAE\u0BCD\u0BAA\u0BC1",base64:"base64-encoded \u0B9A\u0BB0\u0BAE\u0BCD",base64url:"base64url-encoded \u0B9A\u0BB0\u0BAE\u0BCD",json_string:"JSON \u0B9A\u0BB0\u0BAE\u0BCD",e164:"E.164 \u0B8E\u0BA3\u0BCD",jwt:"JWT",template_literal:"input"};return r=>{switch(r.code){case"invalid_type":return`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${r.expected}, \u0BAA\u0BC6\u0BB1\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${j(r.values[0])}`:`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0BB5\u0BBF\u0BB0\u0BC1\u0BAA\u0BCD\u0BAA\u0BAE\u0BCD: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${S(r.values,"|")} \u0B87\u0BB2\u0BCD \u0B92\u0BA9\u0BCD\u0BB1\u0BC1`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u0BAE\u0BBF\u0B95 \u0BAA\u0BC6\u0BB0\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${r.origin??"\u0BAE\u0BA4\u0BBF\u0BAA\u0BCD\u0BAA\u0BC1"} ${i}${r.maximum.toString()} ${a.unit??"\u0B89\u0BB1\u0BC1\u0BAA\u0BCD\u0BAA\u0BC1\u0B95\u0BB3\u0BCD"} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:`\u0BAE\u0BBF\u0B95 \u0BAA\u0BC6\u0BB0\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${r.origin??"\u0BAE\u0BA4\u0BBF\u0BAA\u0BCD\u0BAA\u0BC1"} ${i}${r.maximum.toString()} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u0BAE\u0BBF\u0B95\u0B9A\u0BCD \u0B9A\u0BBF\u0BB1\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${r.origin} ${i}${r.minimum.toString()} ${a.unit} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:`\u0BAE\u0BBF\u0B95\u0B9A\u0BCD \u0B9A\u0BBF\u0BB1\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${r.origin} ${i}${r.minimum.toString()} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: "${i.prefix}" \u0B87\u0BB2\u0BCD \u0BA4\u0BCA\u0B9F\u0B99\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:i.format==="ends_with"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: "${i.suffix}" \u0B87\u0BB2\u0BCD \u0BAE\u0BC1\u0B9F\u0BBF\u0BB5\u0B9F\u0BC8\u0BAF \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:i.format==="includes"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: "${i.includes}" \u0B90 \u0B89\u0BB3\u0BCD\u0BB3\u0B9F\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:i.format==="regex"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: ${i.pattern} \u0BAE\u0BC1\u0BB1\u0BC8\u0BAA\u0BBE\u0B9F\u0BCD\u0B9F\u0BC1\u0B9F\u0BA9\u0BCD \u0BAA\u0BCA\u0BB0\u0BC1\u0BA8\u0BCD\u0BA4 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 ${o[i.format]??r.format}`}case"not_multiple_of":return`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B8E\u0BA3\u0BCD: ${r.divisor} \u0B87\u0BA9\u0BCD \u0BAA\u0BB2\u0BAE\u0BBE\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`;case"unrecognized_keys":return`\u0B85\u0B9F\u0BC8\u0BAF\u0BBE\u0BB3\u0BAE\u0BCD \u0BA4\u0BC6\u0BB0\u0BBF\u0BAF\u0BBE\u0BA4 \u0BB5\u0BBF\u0B9A\u0BC8${r.keys.length>1?"\u0B95\u0BB3\u0BCD":""}: ${S(r.keys,", ")}`;case"invalid_key":return`${r.origin} \u0B87\u0BB2\u0BCD \u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0BB5\u0BBF\u0B9A\u0BC8`;case"invalid_union":return"\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1";case"invalid_element":return`${r.origin} \u0B87\u0BB2\u0BCD \u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0BAE\u0BA4\u0BBF\u0BAA\u0BCD\u0BAA\u0BC1`;default:return"\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1"}}};function m_(){return{localeError:mI()}}var hI=()=>{let e={string:{unit:"\u0E15\u0E31\u0E27\u0E2D\u0E31\u0E01\u0E29\u0E23",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"},file:{unit:"\u0E44\u0E1A\u0E15\u0E4C",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"},array:{unit:"\u0E23\u0E32\u0E22\u0E01\u0E32\u0E23",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"},set:{unit:"\u0E23\u0E32\u0E22\u0E01\u0E32\u0E23",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"\u0E44\u0E21\u0E48\u0E43\u0E0A\u0E48\u0E15\u0E31\u0E27\u0E40\u0E25\u0E02 (NaN)":"\u0E15\u0E31\u0E27\u0E40\u0E25\u0E02";case"object":{if(Array.isArray(r))return"\u0E2D\u0E32\u0E23\u0E4C\u0E40\u0E23\u0E22\u0E4C (Array)";if(r===null)return"\u0E44\u0E21\u0E48\u0E21\u0E35\u0E04\u0E48\u0E32 (null)";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E17\u0E35\u0E48\u0E1B\u0E49\u0E2D\u0E19",email:"\u0E17\u0E35\u0E48\u0E2D\u0E22\u0E39\u0E48\u0E2D\u0E35\u0E40\u0E21\u0E25",url:"URL",emoji:"\u0E2D\u0E34\u0E42\u0E21\u0E08\u0E34",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48\u0E40\u0E27\u0E25\u0E32\u0E41\u0E1A\u0E1A ISO",date:"\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48\u0E41\u0E1A\u0E1A ISO",time:"\u0E40\u0E27\u0E25\u0E32\u0E41\u0E1A\u0E1A ISO",duration:"\u0E0A\u0E48\u0E27\u0E07\u0E40\u0E27\u0E25\u0E32\u0E41\u0E1A\u0E1A ISO",ipv4:"\u0E17\u0E35\u0E48\u0E2D\u0E22\u0E39\u0E48 IPv4",ipv6:"\u0E17\u0E35\u0E48\u0E2D\u0E22\u0E39\u0E48 IPv6",cidrv4:"\u0E0A\u0E48\u0E27\u0E07 IP \u0E41\u0E1A\u0E1A IPv4",cidrv6:"\u0E0A\u0E48\u0E27\u0E07 IP \u0E41\u0E1A\u0E1A IPv6",base64:"\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E41\u0E1A\u0E1A Base64",base64url:"\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E41\u0E1A\u0E1A Base64 \u0E2A\u0E33\u0E2B\u0E23\u0E31\u0E1A URL",json_string:"\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E41\u0E1A\u0E1A JSON",e164:"\u0E40\u0E1A\u0E2D\u0E23\u0E4C\u0E42\u0E17\u0E23\u0E28\u0E31\u0E1E\u0E17\u0E4C\u0E23\u0E30\u0E2B\u0E27\u0E48\u0E32\u0E07\u0E1B\u0E23\u0E30\u0E40\u0E17\u0E28 (E.164)",jwt:"\u0E42\u0E17\u0E40\u0E04\u0E19 JWT",template_literal:"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E17\u0E35\u0E48\u0E1B\u0E49\u0E2D\u0E19"};return r=>{switch(r.code){case"invalid_type":return`\u0E1B\u0E23\u0E30\u0E40\u0E20\u0E17\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E04\u0E27\u0E23\u0E40\u0E1B\u0E47\u0E19 ${r.expected} \u0E41\u0E15\u0E48\u0E44\u0E14\u0E49\u0E23\u0E31\u0E1A ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u0E04\u0E48\u0E32\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E04\u0E27\u0E23\u0E40\u0E1B\u0E47\u0E19 ${j(r.values[0])}`:`\u0E15\u0E31\u0E27\u0E40\u0E25\u0E37\u0E2D\u0E01\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E04\u0E27\u0E23\u0E40\u0E1B\u0E47\u0E19\u0E2B\u0E19\u0E36\u0E48\u0E07\u0E43\u0E19 ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"\u0E44\u0E21\u0E48\u0E40\u0E01\u0E34\u0E19":"\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32",a=t(r.origin);return a?`\u0E40\u0E01\u0E34\u0E19\u0E01\u0E33\u0E2B\u0E19\u0E14: ${r.origin??"\u0E04\u0E48\u0E32"} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${r.maximum.toString()} ${a.unit??"\u0E23\u0E32\u0E22\u0E01\u0E32\u0E23"}`:`\u0E40\u0E01\u0E34\u0E19\u0E01\u0E33\u0E2B\u0E19\u0E14: ${r.origin??"\u0E04\u0E48\u0E32"} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?"\u0E2D\u0E22\u0E48\u0E32\u0E07\u0E19\u0E49\u0E2D\u0E22":"\u0E21\u0E32\u0E01\u0E01\u0E27\u0E48\u0E32",a=t(r.origin);return a?`\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32\u0E01\u0E33\u0E2B\u0E19\u0E14: ${r.origin} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${r.minimum.toString()} ${a.unit}`:`\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32\u0E01\u0E33\u0E2B\u0E19\u0E14: ${r.origin} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E15\u0E49\u0E2D\u0E07\u0E02\u0E36\u0E49\u0E19\u0E15\u0E49\u0E19\u0E14\u0E49\u0E27\u0E22 "${i.prefix}"`:i.format==="ends_with"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E15\u0E49\u0E2D\u0E07\u0E25\u0E07\u0E17\u0E49\u0E32\u0E22\u0E14\u0E49\u0E27\u0E22 "${i.suffix}"`:i.format==="includes"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E15\u0E49\u0E2D\u0E07\u0E21\u0E35 "${i.includes}" \u0E2D\u0E22\u0E39\u0E48\u0E43\u0E19\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21`:i.format==="regex"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E15\u0E49\u0E2D\u0E07\u0E15\u0E23\u0E07\u0E01\u0E31\u0E1A\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E17\u0E35\u0E48\u0E01\u0E33\u0E2B\u0E19\u0E14 ${i.pattern}`:`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: ${o[i.format]??r.format}`}case"not_multiple_of":return`\u0E15\u0E31\u0E27\u0E40\u0E25\u0E02\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E15\u0E49\u0E2D\u0E07\u0E40\u0E1B\u0E47\u0E19\u0E08\u0E33\u0E19\u0E27\u0E19\u0E17\u0E35\u0E48\u0E2B\u0E32\u0E23\u0E14\u0E49\u0E27\u0E22 ${r.divisor} \u0E44\u0E14\u0E49\u0E25\u0E07\u0E15\u0E31\u0E27`;case"unrecognized_keys":return`\u0E1E\u0E1A\u0E04\u0E35\u0E22\u0E4C\u0E17\u0E35\u0E48\u0E44\u0E21\u0E48\u0E23\u0E39\u0E49\u0E08\u0E31\u0E01: ${S(r.keys,", ")}`;case"invalid_key":return`\u0E04\u0E35\u0E22\u0E4C\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07\u0E43\u0E19 ${r.origin}`;case"invalid_union":return"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E44\u0E21\u0E48\u0E15\u0E23\u0E07\u0E01\u0E31\u0E1A\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E22\u0E39\u0E40\u0E19\u0E35\u0E22\u0E19\u0E17\u0E35\u0E48\u0E01\u0E33\u0E2B\u0E19\u0E14\u0E44\u0E27\u0E49";case"invalid_element":return`\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07\u0E43\u0E19 ${r.origin}`;default:return"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07"}}};function h_(){return{localeError:hI()}}var gI=e=>{let t=typeof e;switch(t){case"number":return Number.isNaN(e)?"NaN":"number";case"object":{if(Array.isArray(e))return"array";if(e===null)return"null";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return t},vI=()=>{let e={string:{unit:"karakter",verb:"olmal\u0131"},file:{unit:"bayt",verb:"olmal\u0131"},array:{unit:"\xF6\u011Fe",verb:"olmal\u0131"},set:{unit:"\xF6\u011Fe",verb:"olmal\u0131"}};function t(o){return e[o]??null}let n={regex:"girdi",email:"e-posta adresi",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO tarih ve saat",date:"ISO tarih",time:"ISO saat",duration:"ISO s\xFCre",ipv4:"IPv4 adresi",ipv6:"IPv6 adresi",cidrv4:"IPv4 aral\u0131\u011F\u0131",cidrv6:"IPv6 aral\u0131\u011F\u0131",base64:"base64 ile \u015Fifrelenmi\u015F metin",base64url:"base64url ile \u015Fifrelenmi\u015F metin",json_string:"JSON dizesi",e164:"E.164 say\u0131s\u0131",jwt:"JWT",template_literal:"\u015Eablon dizesi"};return o=>{switch(o.code){case"invalid_type":return`Ge\xE7ersiz de\u011Fer: beklenen ${o.expected}, al\u0131nan ${gI(o.input)}`;case"invalid_value":return o.values.length===1?`Ge\xE7ersiz de\u011Fer: beklenen ${j(o.values[0])}`:`Ge\xE7ersiz se\xE7enek: a\u015Fa\u011F\u0131dakilerden biri olmal\u0131: ${S(o.values,"|")}`;case"too_big":{let r=o.inclusive?"<=":"<",i=t(o.origin);return i?`\xC7ok b\xFCy\xFCk: beklenen ${o.origin??"de\u011Fer"} ${r}${o.maximum.toString()} ${i.unit??"\xF6\u011Fe"}`:`\xC7ok b\xFCy\xFCk: beklenen ${o.origin??"de\u011Fer"} ${r}${o.maximum.toString()}`}case"too_small":{let r=o.inclusive?">=":">",i=t(o.origin);return i?`\xC7ok k\xFC\xE7\xFCk: beklenen ${o.origin} ${r}${o.minimum.toString()} ${i.unit}`:`\xC7ok k\xFC\xE7\xFCk: beklenen ${o.origin} ${r}${o.minimum.toString()}`}case"invalid_format":{let r=o;return r.format==="starts_with"?`Ge\xE7ersiz metin: "${r.prefix}" ile ba\u015Flamal\u0131`:r.format==="ends_with"?`Ge\xE7ersiz metin: "${r.suffix}" ile bitmeli`:r.format==="includes"?`Ge\xE7ersiz metin: "${r.includes}" i\xE7ermeli`:r.format==="regex"?`Ge\xE7ersiz metin: ${r.pattern} desenine uymal\u0131`:`Ge\xE7ersiz ${n[r.format]??o.format}`}case"not_multiple_of":return`Ge\xE7ersiz say\u0131: ${o.divisor} ile tam b\xF6l\xFCnebilmeli`;case"unrecognized_keys":return`Tan\u0131nmayan anahtar${o.keys.length>1?"lar":""}: ${S(o.keys,", ")}`;case"invalid_key":return`${o.origin} i\xE7inde ge\xE7ersiz anahtar`;case"invalid_union":return"Ge\xE7ersiz de\u011Fer";case"invalid_element":return`${o.origin} i\xE7inde ge\xE7ersiz de\u011Fer`;default:return"Ge\xE7ersiz de\u011Fer"}}};function g_(){return{localeError:vI()}}var _I=()=>{let e={string:{unit:"\u0441\u0438\u043C\u0432\u043E\u043B\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"},file:{unit:"\u0431\u0430\u0439\u0442\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"},array:{unit:"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"},set:{unit:"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u0447\u0438\u0441\u043B\u043E";case"object":{if(Array.isArray(r))return"\u043C\u0430\u0441\u0438\u0432";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456",email:"\u0430\u0434\u0440\u0435\u0441\u0430 \u0435\u043B\u0435\u043A\u0442\u0440\u043E\u043D\u043D\u043E\u0457 \u043F\u043E\u0448\u0442\u0438",url:"URL",emoji:"\u0435\u043C\u043E\u0434\u0437\u0456",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u0434\u0430\u0442\u0430 \u0442\u0430 \u0447\u0430\u0441 ISO",date:"\u0434\u0430\u0442\u0430 ISO",time:"\u0447\u0430\u0441 ISO",duration:"\u0442\u0440\u0438\u0432\u0430\u043B\u0456\u0441\u0442\u044C ISO",ipv4:"\u0430\u0434\u0440\u0435\u0441\u0430 IPv4",ipv6:"\u0430\u0434\u0440\u0435\u0441\u0430 IPv6",cidrv4:"\u0434\u0456\u0430\u043F\u0430\u0437\u043E\u043D IPv4",cidrv6:"\u0434\u0456\u0430\u043F\u0430\u0437\u043E\u043D IPv6",base64:"\u0440\u044F\u0434\u043E\u043A \u0443 \u043A\u043E\u0434\u0443\u0432\u0430\u043D\u043D\u0456 base64",base64url:"\u0440\u044F\u0434\u043E\u043A \u0443 \u043A\u043E\u0434\u0443\u0432\u0430\u043D\u043D\u0456 base64url",json_string:"\u0440\u044F\u0434\u043E\u043A JSON",e164:"\u043D\u043E\u043C\u0435\u0440 E.164",jwt:"JWT",template_literal:"\u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456"};return r=>{switch(r.code){case"invalid_type":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F ${r.expected}, \u043E\u0442\u0440\u0438\u043C\u0430\u043D\u043E ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F ${j(r.values[0])}`:`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0430 \u043E\u043F\u0446\u0456\u044F: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F \u043E\u0434\u043D\u0435 \u0437 ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u0432\u0435\u043B\u0438\u043A\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${r.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F"} ${a.verb} ${i}${r.maximum.toString()} ${a.unit??"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0456\u0432"}`:`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u0432\u0435\u043B\u0438\u043A\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${r.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F"} \u0431\u0443\u0434\u0435 ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u043C\u0430\u043B\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${r.origin} ${a.verb} ${i}${r.minimum.toString()} ${a.unit}`:`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u043C\u0430\u043B\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${r.origin} \u0431\u0443\u0434\u0435 ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u043F\u043E\u0447\u0438\u043D\u0430\u0442\u0438\u0441\u044F \u0437 "${i.prefix}"`:i.format==="ends_with"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u0437\u0430\u043A\u0456\u043D\u0447\u0443\u0432\u0430\u0442\u0438\u0441\u044F \u043D\u0430 "${i.suffix}"`:i.format==="includes"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u043C\u0456\u0441\u0442\u0438\u0442\u0438 "${i.includes}"`:i.format==="regex"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u0432\u0456\u0434\u043F\u043E\u0432\u0456\u0434\u0430\u0442\u0438 \u0448\u0430\u0431\u043B\u043E\u043D\u0443 ${i.pattern}`:`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 ${o[i.format]??r.format}`}case"not_multiple_of":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0435 \u0447\u0438\u0441\u043B\u043E: \u043F\u043E\u0432\u0438\u043D\u043D\u043E \u0431\u0443\u0442\u0438 \u043A\u0440\u0430\u0442\u043D\u0438\u043C ${r.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u043E\u0437\u043F\u0456\u0437\u043D\u0430\u043D\u0438\u0439 \u043A\u043B\u044E\u0447${r.keys.length>1?"\u0456":""}: ${S(r.keys,", ")}`;case"invalid_key":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u043A\u043B\u044E\u0447 \u0443 ${r.origin}`;case"invalid_union":return"\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456";case"invalid_element":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F \u0443 ${r.origin}`;default:return"\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456"}}};function Tc(){return{localeError:_I()}}function v_(){return Tc()}var yI=()=>{let e={string:{unit:"\u062D\u0631\u0648\u0641",verb:"\u06C1\u0648\u0646\u0627"},file:{unit:"\u0628\u0627\u0626\u0679\u0633",verb:"\u06C1\u0648\u0646\u0627"},array:{unit:"\u0622\u0626\u0679\u0645\u0632",verb:"\u06C1\u0648\u0646\u0627"},set:{unit:"\u0622\u0626\u0679\u0645\u0632",verb:"\u06C1\u0648\u0646\u0627"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"\u0646\u0645\u0628\u0631";case"object":{if(Array.isArray(r))return"\u0622\u0631\u06D2";if(r===null)return"\u0646\u0644";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0627\u0646 \u067E\u0679",email:"\u0627\u06CC \u0645\u06CC\u0644 \u0627\u06CC\u0688\u0631\u06CC\u0633",url:"\u06CC\u0648 \u0622\u0631 \u0627\u06CC\u0644",emoji:"\u0627\u06CC\u0645\u0648\u062C\u06CC",uuid:"\u06CC\u0648 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",uuidv4:"\u06CC\u0648 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC \u0648\u06CC 4",uuidv6:"\u06CC\u0648 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC \u0648\u06CC 6",nanoid:"\u0646\u06CC\u0646\u0648 \u0622\u0626\u06CC \u0688\u06CC",guid:"\u062C\u06CC \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",cuid:"\u0633\u06CC \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",cuid2:"\u0633\u06CC \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC 2",ulid:"\u06CC\u0648 \u0627\u06CC\u0644 \u0622\u0626\u06CC \u0688\u06CC",xid:"\u0627\u06CC\u06A9\u0633 \u0622\u0626\u06CC \u0688\u06CC",ksuid:"\u06A9\u06D2 \u0627\u06CC\u0633 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",datetime:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u0688\u06CC\u0679 \u0679\u0627\u0626\u0645",date:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u062A\u0627\u0631\u06CC\u062E",time:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u0648\u0642\u062A",duration:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u0645\u062F\u062A",ipv4:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 4 \u0627\u06CC\u0688\u0631\u06CC\u0633",ipv6:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 6 \u0627\u06CC\u0688\u0631\u06CC\u0633",cidrv4:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 4 \u0631\u06CC\u0646\u062C",cidrv6:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 6 \u0631\u06CC\u0646\u062C",base64:"\u0628\u06CC\u0633 64 \u0627\u0646 \u06A9\u0648\u0688\u0688 \u0633\u0679\u0631\u0646\u06AF",base64url:"\u0628\u06CC\u0633 64 \u06CC\u0648 \u0622\u0631 \u0627\u06CC\u0644 \u0627\u0646 \u06A9\u0648\u0688\u0688 \u0633\u0679\u0631\u0646\u06AF",json_string:"\u062C\u06D2 \u0627\u06CC\u0633 \u0627\u0648 \u0627\u06CC\u0646 \u0633\u0679\u0631\u0646\u06AF",e164:"\u0627\u06CC 164 \u0646\u0645\u0628\u0631",jwt:"\u062C\u06D2 \u0688\u0628\u0644\u06CC\u0648 \u0679\u06CC",template_literal:"\u0627\u0646 \u067E\u0679"};return r=>{switch(r.code){case"invalid_type":return`\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679: ${r.expected} \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627\u060C ${n(r.input)} \u0645\u0648\u0635\u0648\u0644 \u06C1\u0648\u0627`;case"invalid_value":return r.values.length===1?`\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679: ${j(r.values[0])} \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`:`\u063A\u0644\u0637 \u0622\u067E\u0634\u0646: ${S(r.values,"|")} \u0645\u06CC\u06BA \u0633\u06D2 \u0627\u06CC\u06A9 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u0628\u06C1\u062A \u0628\u0691\u0627: ${r.origin??"\u0648\u06CC\u0644\u06CC\u0648"} \u06A9\u06D2 ${i}${r.maximum.toString()} ${a.unit??"\u0639\u0646\u0627\u0635\u0631"} \u06C1\u0648\u0646\u06D2 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u06D2`:`\u0628\u06C1\u062A \u0628\u0691\u0627: ${r.origin??"\u0648\u06CC\u0644\u06CC\u0648"} \u06A9\u0627 ${i}${r.maximum.toString()} \u06C1\u0648\u0646\u0627 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u0628\u06C1\u062A \u0686\u06BE\u0648\u0679\u0627: ${r.origin} \u06A9\u06D2 ${i}${r.minimum.toString()} ${a.unit} \u06C1\u0648\u0646\u06D2 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u06D2`:`\u0628\u06C1\u062A \u0686\u06BE\u0648\u0679\u0627: ${r.origin} \u06A9\u0627 ${i}${r.minimum.toString()} \u06C1\u0648\u0646\u0627 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: "${i.prefix}" \u0633\u06D2 \u0634\u0631\u0648\u0639 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:i.format==="ends_with"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: "${i.suffix}" \u067E\u0631 \u062E\u062A\u0645 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:i.format==="includes"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: "${i.includes}" \u0634\u0627\u0645\u0644 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:i.format==="regex"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: \u067E\u06CC\u0679\u0631\u0646 ${i.pattern} \u0633\u06D2 \u0645\u06CC\u0686 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:`\u063A\u0644\u0637 ${o[i.format]??r.format}`}case"not_multiple_of":return`\u063A\u0644\u0637 \u0646\u0645\u0628\u0631: ${r.divisor} \u06A9\u0627 \u0645\u0636\u0627\u0639\u0641 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`;case"unrecognized_keys":return`\u063A\u06CC\u0631 \u062A\u0633\u0644\u06CC\u0645 \u0634\u062F\u06C1 \u06A9\u06CC${r.keys.length>1?"\u0632":""}: ${S(r.keys,"\u060C ")}`;case"invalid_key":return`${r.origin} \u0645\u06CC\u06BA \u063A\u0644\u0637 \u06A9\u06CC`;case"invalid_union":return"\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679";case"invalid_element":return`${r.origin} \u0645\u06CC\u06BA \u063A\u0644\u0637 \u0648\u06CC\u0644\u06CC\u0648`;default:return"\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679"}}};function __(){return{localeError:yI()}}var bI=()=>{let e={string:{unit:"k\xFD t\u1EF1",verb:"c\xF3"},file:{unit:"byte",verb:"c\xF3"},array:{unit:"ph\u1EA7n t\u1EED",verb:"c\xF3"},set:{unit:"ph\u1EA7n t\u1EED",verb:"c\xF3"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"s\u1ED1";case"object":{if(Array.isArray(r))return"m\u1EA3ng";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u0111\u1EA7u v\xE0o",email:"\u0111\u1ECBa ch\u1EC9 email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ng\xE0y gi\u1EDD ISO",date:"ng\xE0y ISO",time:"gi\u1EDD ISO",duration:"kho\u1EA3ng th\u1EDDi gian ISO",ipv4:"\u0111\u1ECBa ch\u1EC9 IPv4",ipv6:"\u0111\u1ECBa ch\u1EC9 IPv6",cidrv4:"d\u1EA3i IPv4",cidrv6:"d\u1EA3i IPv6",base64:"chu\u1ED7i m\xE3 h\xF3a base64",base64url:"chu\u1ED7i m\xE3 h\xF3a base64url",json_string:"chu\u1ED7i JSON",e164:"s\u1ED1 E.164",jwt:"JWT",template_literal:"\u0111\u1EA7u v\xE0o"};return r=>{switch(r.code){case"invalid_type":return`\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i ${r.expected}, nh\u1EADn \u0111\u01B0\u1EE3c ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i ${j(r.values[0])}`:`T\xF9y ch\u1ECDn kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i m\u1ED9t trong c\xE1c gi\xE1 tr\u1ECB ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Qu\xE1 l\u1EDBn: mong \u0111\u1EE3i ${r.origin??"gi\xE1 tr\u1ECB"} ${a.verb} ${i}${r.maximum.toString()} ${a.unit??"ph\u1EA7n t\u1EED"}`:`Qu\xE1 l\u1EDBn: mong \u0111\u1EE3i ${r.origin??"gi\xE1 tr\u1ECB"} ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Qu\xE1 nh\u1ECF: mong \u0111\u1EE3i ${r.origin} ${a.verb} ${i}${r.minimum.toString()} ${a.unit}`:`Qu\xE1 nh\u1ECF: mong \u0111\u1EE3i ${r.origin} ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i b\u1EAFt \u0111\u1EA7u b\u1EB1ng "${i.prefix}"`:i.format==="ends_with"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i k\u1EBFt th\xFAc b\u1EB1ng "${i.suffix}"`:i.format==="includes"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i bao g\u1ED3m "${i.includes}"`:i.format==="regex"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i kh\u1EDBp v\u1EDBi m\u1EABu ${i.pattern}`:`${o[i.format]??r.format} kh\xF4ng h\u1EE3p l\u1EC7`}case"not_multiple_of":return`S\u1ED1 kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i l\xE0 b\u1ED9i s\u1ED1 c\u1EE7a ${r.divisor}`;case"unrecognized_keys":return`Kh\xF3a kh\xF4ng \u0111\u01B0\u1EE3c nh\u1EADn d\u1EA1ng: ${S(r.keys,", ")}`;case"invalid_key":return`Kh\xF3a kh\xF4ng h\u1EE3p l\u1EC7 trong ${r.origin}`;case"invalid_union":return"\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7";case"invalid_element":return`Gi\xE1 tr\u1ECB kh\xF4ng h\u1EE3p l\u1EC7 trong ${r.origin}`;default:return"\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7"}}};function y_(){return{localeError:bI()}}var $I=()=>{let e={string:{unit:"\u5B57\u7B26",verb:"\u5305\u542B"},file:{unit:"\u5B57\u8282",verb:"\u5305\u542B"},array:{unit:"\u9879",verb:"\u5305\u542B"},set:{unit:"\u9879",verb:"\u5305\u542B"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"\u975E\u6570\u5B57(NaN)":"\u6570\u5B57";case"object":{if(Array.isArray(r))return"\u6570\u7EC4";if(r===null)return"\u7A7A\u503C(null)";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u8F93\u5165",email:"\u7535\u5B50\u90AE\u4EF6",url:"URL",emoji:"\u8868\u60C5\u7B26\u53F7",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO\u65E5\u671F\u65F6\u95F4",date:"ISO\u65E5\u671F",time:"ISO\u65F6\u95F4",duration:"ISO\u65F6\u957F",ipv4:"IPv4\u5730\u5740",ipv6:"IPv6\u5730\u5740",cidrv4:"IPv4\u7F51\u6BB5",cidrv6:"IPv6\u7F51\u6BB5",base64:"base64\u7F16\u7801\u5B57\u7B26\u4E32",base64url:"base64url\u7F16\u7801\u5B57\u7B26\u4E32",json_string:"JSON\u5B57\u7B26\u4E32",e164:"E.164\u53F7\u7801",jwt:"JWT",template_literal:"\u8F93\u5165"};return r=>{switch(r.code){case"invalid_type":return`\u65E0\u6548\u8F93\u5165\uFF1A\u671F\u671B ${r.expected}\uFF0C\u5B9E\u9645\u63A5\u6536 ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u65E0\u6548\u8F93\u5165\uFF1A\u671F\u671B ${j(r.values[0])}`:`\u65E0\u6548\u9009\u9879\uFF1A\u671F\u671B\u4EE5\u4E0B\u4E4B\u4E00 ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u6570\u503C\u8FC7\u5927\uFF1A\u671F\u671B ${r.origin??"\u503C"} ${i}${r.maximum.toString()} ${a.unit??"\u4E2A\u5143\u7D20"}`:`\u6570\u503C\u8FC7\u5927\uFF1A\u671F\u671B ${r.origin??"\u503C"} ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u6570\u503C\u8FC7\u5C0F\uFF1A\u671F\u671B ${r.origin} ${i}${r.minimum.toString()} ${a.unit}`:`\u6570\u503C\u8FC7\u5C0F\uFF1A\u671F\u671B ${r.origin} ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u4EE5 "${i.prefix}" \u5F00\u5934`:i.format==="ends_with"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u4EE5 "${i.suffix}" \u7ED3\u5C3E`:i.format==="includes"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u5305\u542B "${i.includes}"`:i.format==="regex"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u6EE1\u8DB3\u6B63\u5219\u8868\u8FBE\u5F0F ${i.pattern}`:`\u65E0\u6548${o[i.format]??r.format}`}case"not_multiple_of":return`\u65E0\u6548\u6570\u5B57\uFF1A\u5FC5\u987B\u662F ${r.divisor} \u7684\u500D\u6570`;case"unrecognized_keys":return`\u51FA\u73B0\u672A\u77E5\u7684\u952E(key): ${S(r.keys,", ")}`;case"invalid_key":return`${r.origin} \u4E2D\u7684\u952E(key)\u65E0\u6548`;case"invalid_union":return"\u65E0\u6548\u8F93\u5165";case"invalid_element":return`${r.origin} \u4E2D\u5305\u542B\u65E0\u6548\u503C(value)`;default:return"\u65E0\u6548\u8F93\u5165"}}};function b_(){return{localeError:$I()}}var xI=()=>{let e={string:{unit:"\u5B57\u5143",verb:"\u64C1\u6709"},file:{unit:"\u4F4D\u5143\u7D44",verb:"\u64C1\u6709"},array:{unit:"\u9805\u76EE",verb:"\u64C1\u6709"},set:{unit:"\u9805\u76EE",verb:"\u64C1\u6709"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"number";case"object":{if(Array.isArray(r))return"array";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u8F38\u5165",email:"\u90F5\u4EF6\u5730\u5740",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u65E5\u671F\u6642\u9593",date:"ISO \u65E5\u671F",time:"ISO \u6642\u9593",duration:"ISO \u671F\u9593",ipv4:"IPv4 \u4F4D\u5740",ipv6:"IPv6 \u4F4D\u5740",cidrv4:"IPv4 \u7BC4\u570D",cidrv6:"IPv6 \u7BC4\u570D",base64:"base64 \u7DE8\u78BC\u5B57\u4E32",base64url:"base64url \u7DE8\u78BC\u5B57\u4E32",json_string:"JSON \u5B57\u4E32",e164:"E.164 \u6578\u503C",jwt:"JWT",template_literal:"\u8F38\u5165"};return r=>{switch(r.code){case"invalid_type":return`\u7121\u6548\u7684\u8F38\u5165\u503C\uFF1A\u9810\u671F\u70BA ${r.expected}\uFF0C\u4F46\u6536\u5230 ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\u7121\u6548\u7684\u8F38\u5165\u503C\uFF1A\u9810\u671F\u70BA ${j(r.values[0])}`:`\u7121\u6548\u7684\u9078\u9805\uFF1A\u9810\u671F\u70BA\u4EE5\u4E0B\u5176\u4E2D\u4E4B\u4E00 ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u6578\u503C\u904E\u5927\uFF1A\u9810\u671F ${r.origin??"\u503C"} \u61C9\u70BA ${i}${r.maximum.toString()} ${a.unit??"\u500B\u5143\u7D20"}`:`\u6578\u503C\u904E\u5927\uFF1A\u9810\u671F ${r.origin??"\u503C"} \u61C9\u70BA ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u6578\u503C\u904E\u5C0F\uFF1A\u9810\u671F ${r.origin} \u61C9\u70BA ${i}${r.minimum.toString()} ${a.unit}`:`\u6578\u503C\u904E\u5C0F\uFF1A\u9810\u671F ${r.origin} \u61C9\u70BA ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u4EE5 "${i.prefix}" \u958B\u982D`:i.format==="ends_with"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u4EE5 "${i.suffix}" \u7D50\u5C3E`:i.format==="includes"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u5305\u542B "${i.includes}"`:i.format==="regex"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u7B26\u5408\u683C\u5F0F ${i.pattern}`:`\u7121\u6548\u7684 ${o[i.format]??r.format}`}case"not_multiple_of":return`\u7121\u6548\u7684\u6578\u5B57\uFF1A\u5FC5\u9808\u70BA ${r.divisor} \u7684\u500D\u6578`;case"unrecognized_keys":return`\u7121\u6CD5\u8B58\u5225\u7684\u9375\u503C${r.keys.length>1?"\u5011":""}\uFF1A${S(r.keys,"\u3001")}`;case"invalid_key":return`${r.origin} \u4E2D\u6709\u7121\u6548\u7684\u9375\u503C`;case"invalid_union":return"\u7121\u6548\u7684\u8F38\u5165\u503C";case"invalid_element":return`${r.origin} \u4E2D\u6709\u7121\u6548\u7684\u503C`;default:return"\u7121\u6548\u7684\u8F38\u5165\u503C"}}};function $_(){return{localeError:xI()}}var wI=()=>{let e={string:{unit:"\xE0mi",verb:"n\xED"},file:{unit:"bytes",verb:"n\xED"},array:{unit:"nkan",verb:"n\xED"},set:{unit:"nkan",verb:"n\xED"}};function t(r){return e[r]??null}let n=r=>{let i=typeof r;switch(i){case"number":return Number.isNaN(r)?"NaN":"n\u1ECD\u0301mb\xE0";case"object":{if(Array.isArray(r))return"akop\u1ECD";if(r===null)return"null";if(Object.getPrototypeOf(r)!==Object.prototype&&r.constructor)return r.constructor.name}}return i},o={regex:"\u1EB9\u0300r\u1ECD \xECb\xE1w\u1ECDl\xE9",email:"\xE0d\xEDr\u1EB9\u0301s\xEC \xECm\u1EB9\u0301l\xEC",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\xE0k\xF3k\xF2 ISO",date:"\u1ECDj\u1ECD\u0301 ISO",time:"\xE0k\xF3k\xF2 ISO",duration:"\xE0k\xF3k\xF2 t\xF3 p\xE9 ISO",ipv4:"\xE0d\xEDr\u1EB9\u0301s\xEC IPv4",ipv6:"\xE0d\xEDr\u1EB9\u0301s\xEC IPv6",cidrv4:"\xE0gb\xE8gb\xE8 IPv4",cidrv6:"\xE0gb\xE8gb\xE8 IPv6",base64:"\u1ECD\u0300r\u1ECD\u0300 t\xED a k\u1ECD\u0301 n\xED base64",base64url:"\u1ECD\u0300r\u1ECD\u0300 base64url",json_string:"\u1ECD\u0300r\u1ECD\u0300 JSON",e164:"n\u1ECD\u0301mb\xE0 E.164",jwt:"JWT",template_literal:"\u1EB9\u0300r\u1ECD \xECb\xE1w\u1ECDl\xE9"};return r=>{switch(r.code){case"invalid_type":return`\xCCb\xE1w\u1ECDl\xE9 a\u1E63\xEC\u1E63e: a n\xED l\xE1ti fi ${r.expected}, \xE0m\u1ECD\u0300 a r\xED ${n(r.input)}`;case"invalid_value":return r.values.length===1?`\xCCb\xE1w\u1ECDl\xE9 a\u1E63\xEC\u1E63e: a n\xED l\xE1ti fi ${j(r.values[0])}`:`\xC0\u1E63\xE0y\xE0n a\u1E63\xEC\u1E63e: yan \u1ECD\u0300kan l\xE1ra ${S(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`T\xF3 p\u1ECD\u0300 j\xF9: a n\xED l\xE1ti j\u1EB9\u0301 p\xE9 ${r.origin??"iye"} ${a.verb} ${i}${r.maximum} ${a.unit}`:`T\xF3 p\u1ECD\u0300 j\xF9: a n\xED l\xE1ti j\u1EB9\u0301 ${i}${r.maximum}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`K\xE9r\xE9 ju: a n\xED l\xE1ti j\u1EB9\u0301 p\xE9 ${r.origin} ${a.verb} ${i}${r.minimum} ${a.unit}`:`K\xE9r\xE9 ju: a n\xED l\xE1ti j\u1EB9\u0301 ${i}${r.minimum}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u1ECC\u0300r\u1ECD\u0300 a\u1E63\xEC\u1E63e: gb\u1ECD\u0301d\u1ECD\u0300 b\u1EB9\u0300r\u1EB9\u0300 p\u1EB9\u0300l\xFA "${i.prefix}"`:i.format==="ends_with"?`\u1ECC\u0300r\u1ECD\u0300 a\u1E63\xEC\u1E63e: gb\u1ECD\u0301d\u1ECD\u0300 par\xED p\u1EB9\u0300l\xFA "${i.suffix}"`:i.format==="includes"?`\u1ECC\u0300r\u1ECD\u0300 a\u1E63\xEC\u1E63e: gb\u1ECD\u0301d\u1ECD\u0300 n\xED "${i.includes}"`:i.format==="regex"?`\u1ECC\u0300r\u1ECD\u0300 a\u1E63\xEC\u1E63e: gb\u1ECD\u0301d\u1ECD\u0300 b\xE1 \xE0p\u1EB9\u1EB9r\u1EB9 mu ${i.pattern}`:`A\u1E63\xEC\u1E63e: ${o[i.format]??r.format}`}case"not_multiple_of":return`N\u1ECD\u0301mb\xE0 a\u1E63\xEC\u1E63e: gb\u1ECD\u0301d\u1ECD\u0300 j\u1EB9\u0301 \xE8y\xE0 p\xEDp\xEDn ti ${r.divisor}`;case"unrecognized_keys":return`B\u1ECDt\xECn\xEC \xE0\xECm\u1ECD\u0300: ${S(r.keys,", ")}`;case"invalid_key":return`B\u1ECDt\xECn\xEC a\u1E63\xEC\u1E63e n\xEDn\xFA ${r.origin}`;case"invalid_union":return"\xCCb\xE1w\u1ECDl\xE9 a\u1E63\xEC\u1E63e";case"invalid_element":return`Iye a\u1E63\xEC\u1E63e n\xEDn\xFA ${r.origin}`;default:return"\xCCb\xE1w\u1ECDl\xE9 a\u1E63\xEC\u1E63e"}}};function x_(){return{localeError:wI()}}var Oc=Symbol("ZodOutput"),Pc=Symbol("ZodInput"),Kn=class{constructor(){this._map=new WeakMap,this._idmap=new Map}add(t,...n){let o=n[0];if(this._map.set(t,o),o&&typeof o=="object"&&"id"in o){if(this._idmap.has(o.id))throw new Error(`ID ${o.id} already exists in the registry`);this._idmap.set(o.id,t)}return this}clear(){return this._map=new WeakMap,this._idmap=new Map,this}remove(t){let n=this._map.get(t);return n&&typeof n=="object"&&"id"in n&&this._idmap.delete(n.id),this._map.delete(t),this}get(t){let n=t._zod.parent;if(n){let o={...this.get(n)??{}};delete o.id;let r={...o,...this._map.get(t)};return Object.keys(r).length?r:void 0}return this._map.get(t)}has(t){return this._map.has(t)}};function gi(){return new Kn}var Tt=gi();function jc(e,t){return new e({type:"string",...N(t)})}function Nc(e,t){return new e({type:"string",coerce:!0,...N(t)})}function vi(e,t){return new e({type:"string",format:"email",check:"string_format",abort:!1,...N(t)})}function Hn(e,t){return new e({type:"string",format:"guid",check:"string_format",abort:!1,...N(t)})}function _i(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,...N(t)})}function yi(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v4",...N(t)})}function bi(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v6",...N(t)})}function $i(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v7",...N(t)})}function Jn(e,t){return new e({type:"string",format:"url",check:"string_format",abort:!1,...N(t)})}function xi(e,t){return new e({type:"string",format:"emoji",check:"string_format",abort:!1,...N(t)})}function wi(e,t){return new e({type:"string",format:"nanoid",check:"string_format",abort:!1,...N(t)})}function ki(e,t){return new e({type:"string",format:"cuid",check:"string_format",abort:!1,...N(t)})}function Si(e,t){return new e({type:"string",format:"cuid2",check:"string_format",abort:!1,...N(t)})}function zi(e,t){return new e({type:"string",format:"ulid",check:"string_format",abort:!1,...N(t)})}function Ii(e,t){return new e({type:"string",format:"xid",check:"string_format",abort:!1,...N(t)})}function Ei(e,t){return new e({type:"string",format:"ksuid",check:"string_format",abort:!1,...N(t)})}function Ti(e,t){return new e({type:"string",format:"ipv4",check:"string_format",abort:!1,...N(t)})}function Oi(e,t){return new e({type:"string",format:"ipv6",check:"string_format",abort:!1,...N(t)})}function Pi(e,t){return new e({type:"string",format:"cidrv4",check:"string_format",abort:!1,...N(t)})}function ji(e,t){return new e({type:"string",format:"cidrv6",check:"string_format",abort:!1,...N(t)})}function Ni(e,t){return new e({type:"string",format:"base64",check:"string_format",abort:!1,...N(t)})}function Ri(e,t){return new e({type:"string",format:"base64url",check:"string_format",abort:!1,...N(t)})}function Ai(e,t){return new e({type:"string",format:"e164",check:"string_format",abort:!1,...N(t)})}function Di(e,t){return new e({type:"string",format:"jwt",check:"string_format",abort:!1,...N(t)})}var Rc={Any:null,Minute:-1,Second:0,Millisecond:3,Microsecond:6};function Ac(e,t){return new e({type:"string",format:"datetime",check:"string_format",offset:!1,local:!1,precision:null,...N(t)})}function Dc(e,t){return new e({type:"string",format:"date",check:"string_format",...N(t)})}function Cc(e,t){return new e({type:"string",format:"time",check:"string_format",precision:null,...N(t)})}function Uc(e,t){return new e({type:"string",format:"duration",check:"string_format",...N(t)})}function Zc(e,t){return new e({type:"number",checks:[],...N(t)})}function Mc(e,t){return new e({type:"number",coerce:!0,checks:[],...N(t)})}function Lc(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"safeint",...N(t)})}function qc(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"float32",...N(t)})}function Vc(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"float64",...N(t)})}function Fc(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"int32",...N(t)})}function Bc(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"uint32",...N(t)})}function Kc(e,t){return new e({type:"boolean",...N(t)})}function Hc(e,t){return new e({type:"boolean",coerce:!0,...N(t)})}function Jc(e,t){return new e({type:"bigint",...N(t)})}function Gc(e,t){return new e({type:"bigint",coerce:!0,...N(t)})}function Wc(e,t){return new e({type:"bigint",check:"bigint_format",abort:!1,format:"int64",...N(t)})}function Xc(e,t){return new e({type:"bigint",check:"bigint_format",abort:!1,format:"uint64",...N(t)})}function Yc(e,t){return new e({type:"symbol",...N(t)})}function Qc(e,t){return new e({type:"undefined",...N(t)})}function eu(e,t){return new e({type:"null",...N(t)})}function tu(e){return new e({type:"any"})}function ru(e){return new e({type:"unknown"})}function nu(e,t){return new e({type:"never",...N(t)})}function ou(e,t){return new e({type:"void",...N(t)})}function iu(e,t){return new e({type:"date",...N(t)})}function au(e,t){return new e({type:"date",coerce:!0,...N(t)})}function su(e,t){return new e({type:"nan",...N(t)})}function Zt(e,t){return new ms({check:"less_than",...N(t),value:e,inclusive:!1})}function rt(e,t){return new ms({check:"less_than",...N(t),value:e,inclusive:!0})}function Mt(e,t){return new hs({check:"greater_than",...N(t),value:e,inclusive:!1})}function Ve(e,t){return new hs({check:"greater_than",...N(t),value:e,inclusive:!0})}function cu(e){return Mt(0,e)}function uu(e){return Zt(0,e)}function lu(e){return rt(0,e)}function du(e){return Ve(0,e)}function Sr(e,t){return new vf({check:"multiple_of",...N(t),value:e})}function Xr(e,t){return new bf({check:"max_size",...N(t),maximum:e})}function zr(e,t){return new $f({check:"min_size",...N(t),minimum:e})}function Gn(e,t){return new xf({check:"size_equals",...N(t),size:e})}function Yr(e,t){return new wf({check:"max_length",...N(t),maximum:e})}function tr(e,t){return new kf({check:"min_length",...N(t),minimum:e})}function Qr(e,t){return new Sf({check:"length_equals",...N(t),length:e})}function Wn(e,t){return new zf({check:"string_format",format:"regex",...N(t),pattern:e})}function Xn(e){return new If({check:"string_format",format:"lowercase",...N(e)})}function Yn(e){return new Ef({check:"string_format",format:"uppercase",...N(e)})}function Qn(e,t){return new Tf({check:"string_format",format:"includes",...N(t),includes:e})}function eo(e,t){return new Of({check:"string_format",format:"starts_with",...N(t),prefix:e})}function to(e,t){return new Pf({check:"string_format",format:"ends_with",...N(t),suffix:e})}function fu(e,t,n){return new jf({check:"property",property:e,schema:t,...N(n)})}function ro(e,t){return new Nf({check:"mime_type",mime:e,...N(t)})}function Lt(e){return new Rf({check:"overwrite",tx:e})}function no(e){return Lt(t=>t.normalize(e))}function oo(){return Lt(e=>e.trim())}function io(){return Lt(e=>e.toLowerCase())}function ao(){return Lt(e=>e.toUpperCase())}function Zf(e,t,n){return new e({type:"array",element:t,...N(n)})}function kI(e,t,n){return new e({type:"union",options:t,...N(n)})}function SI(e,t,n,o){return new e({type:"union",options:n,discriminator:t,...N(o)})}function zI(e,t,n){return new e({type:"intersection",left:t,right:n})}function II(e,t,n,o){let r=n instanceof W,i=r?o:n,a=r?n:null;return new e({type:"tuple",items:t,rest:a,...N(i)})}function EI(e,t,n,o){return new e({type:"record",keyType:t,valueType:n,...N(o)})}function TI(e,t,n,o){return new e({type:"map",keyType:t,valueType:n,...N(o)})}function OI(e,t,n){return new e({type:"set",valueType:t,...N(n)})}function PI(e,t,n){let o=Array.isArray(t)?Object.fromEntries(t.map(r=>[r,r])):t;return new e({type:"enum",entries:o,...N(n)})}function jI(e,t,n){return new e({type:"enum",entries:t,...N(n)})}function NI(e,t,n){return new e({type:"literal",values:Array.isArray(t)?t:[t],...N(n)})}function pu(e,t){return new e({type:"file",...N(t)})}function RI(e,t){return new e({type:"transform",transform:t})}function AI(e,t){return new e({type:"optional",innerType:t})}function DI(e,t){return new e({type:"nullable",innerType:t})}function CI(e,t,n){return new e({type:"default",innerType:t,get defaultValue(){return typeof n=="function"?n():Dd(n)}})}function UI(e,t,n){return new e({type:"nonoptional",innerType:t,...N(n)})}function ZI(e,t){return new e({type:"success",innerType:t})}function MI(e,t,n){return new e({type:"catch",innerType:t,catchValue:typeof n=="function"?n:()=>n})}function LI(e,t,n){return new e({type:"pipe",in:t,out:n})}function qI(e,t){return new e({type:"readonly",innerType:t})}function VI(e,t,n){return new e({type:"template_literal",parts:t,...N(n)})}function FI(e,t){return new e({type:"lazy",getter:t})}function BI(e,t){return new e({type:"promise",innerType:t})}function mu(e,t,n){let o=N(n);return o.abort??(o.abort=!0),new e({type:"custom",check:"custom",fn:t,...o})}function hu(e,t,n){return new e({type:"custom",check:"custom",fn:t,...N(n)})}function gu(e){let t=w_(n=>(n.addIssue=o=>{if(typeof o=="string")n.issues.push(An(o,n.value,t._zod.def));else{let r=o;r.fatal&&(r.continue=!1),r.code??(r.code="custom"),r.input??(r.input=n.value),r.inst??(r.inst=t),r.continue??(r.continue=!t._zod.def.abort),n.issues.push(An(r))}},e(n.value,n)));return t}function w_(e,t){let n=new $e({check:"custom",...N(t)});return n._zod.check=e,n}function vu(e,t){let n=N(t),o=n.truthy??["true","1","yes","on","y","enabled"],r=n.falsy??["false","0","no","off","n","disabled"];n.case!=="sensitive"&&(o=o.map(v=>typeof v=="string"?v.toLowerCase():v),r=r.map(v=>typeof v=="string"?v.toLowerCase():v));let i=new Set(o),a=new Set(r),s=e.Codec??Fn,c=e.Boolean??Vn,l=e.String??kr,d=new l({type:"string",error:n.error}),f=new c({type:"boolean",error:n.error}),_=new s({type:"pipe",in:d,out:f,transform:((v,g)=>{let b=v;return n.case!=="sensitive"&&(b=b.toLowerCase()),i.has(b)?!0:a.has(b)?!1:(g.issues.push({code:"invalid_value",expected:"stringbool",values:[...i,...a],input:g.value,inst:_,continue:!1}),{})}),reverseTransform:((v,g)=>v===!0?o[0]||"true":r[0]||"false"),error:n.error});return _}function en(e,t,n,o={}){let r=N(o),i={...N(o),check:"string_format",type:"string",format:t,fn:typeof n=="function"?n:s=>n.test(s),...r};return n instanceof RegExp&&(i.pattern=n),new e(i)}var Ci=class{constructor(t){this.counter=0,this.metadataRegistry=t?.metadata??Tt,this.target=t?.target??"draft-2020-12",this.unrepresentable=t?.unrepresentable??"throw",this.override=t?.override??(()=>{}),this.io=t?.io??"output",this.seen=new Map}process(t,n={path:[],schemaPath:[]}){var o;let r=t._zod.def,i={guid:"uuid",url:"uri",datetime:"date-time",json_string:"json-string",regex:""},a=this.seen.get(t);if(a)return a.count++,n.schemaPath.includes(t)&&(a.cycle=n.path),a.schema;let s={schema:{},count:1,cycle:void 0,path:n.path};this.seen.set(t,s);let c=t._zod.toJSONSchema?.();if(c)s.schema=c;else{let f={...n,schemaPath:[...n.schemaPath,t],path:n.path},_=t._zod.parent;if(_)s.ref=_,this.process(_,f),this.seen.get(_).isParent=!0;else{let v=s.schema;switch(r.type){case"string":{let g=v;g.type="string";let{minimum:b,maximum:x,format:I,patterns:R,contentEncoding:O}=t._zod.bag;if(typeof b=="number"&&(g.minLength=b),typeof x=="number"&&(g.maxLength=x),I&&(g.format=i[I]??I,g.format===""&&delete g.format),O&&(g.contentEncoding=O),R&&R.size>0){let M=[...R];M.length===1?g.pattern=M[0].source:M.length>1&&(s.schema.allOf=[...M.map(V=>({...this.target==="draft-7"||this.target==="draft-4"||this.target==="openapi-3.0"?{type:"string"}:{},pattern:V.source}))])}break}case"number":{let g=v,{minimum:b,maximum:x,format:I,multipleOf:R,exclusiveMaximum:O,exclusiveMinimum:M}=t._zod.bag;typeof I=="string"&&I.includes("int")?g.type="integer":g.type="number",typeof M=="number"&&(this.target==="draft-4"||this.target==="openapi-3.0"?(g.minimum=M,g.exclusiveMinimum=!0):g.exclusiveMinimum=M),typeof b=="number"&&(g.minimum=b,typeof M=="number"&&this.target!=="draft-4"&&(M>=b?delete g.minimum:delete g.exclusiveMinimum)),typeof O=="number"&&(this.target==="draft-4"||this.target==="openapi-3.0"?(g.maximum=O,g.exclusiveMaximum=!0):g.exclusiveMaximum=O),typeof x=="number"&&(g.maximum=x,typeof O=="number"&&this.target!=="draft-4"&&(O<=x?delete g.maximum:delete g.exclusiveMaximum)),typeof R=="number"&&(g.multipleOf=R);break}case"boolean":{let g=v;g.type="boolean";break}case"bigint":{if(this.unrepresentable==="throw")throw new Error("BigInt cannot be represented in JSON Schema");break}case"symbol":{if(this.unrepresentable==="throw")throw new Error("Symbols cannot be represented in JSON Schema");break}case"null":{this.target==="openapi-3.0"?(v.type="string",v.nullable=!0,v.enum=[null]):v.type="null";break}case"any":break;case"unknown":break;case"undefined":{if(this.unrepresentable==="throw")throw new Error("Undefined cannot be represented in JSON Schema");break}case"void":{if(this.unrepresentable==="throw")throw new Error("Void cannot be represented in JSON Schema");break}case"never":{v.not={};break}case"date":{if(this.unrepresentable==="throw")throw new Error("Date cannot be represented in JSON Schema");break}case"array":{let g=v,{minimum:b,maximum:x}=t._zod.bag;typeof b=="number"&&(g.minItems=b),typeof x=="number"&&(g.maxItems=x),g.type="array",g.items=this.process(r.element,{...f,path:[...f.path,"items"]});break}case"object":{let g=v;g.type="object",g.properties={};let b=r.shape;for(let R in b)g.properties[R]=this.process(b[R],{...f,path:[...f.path,"properties",R]});let x=new Set(Object.keys(b)),I=new Set([...x].filter(R=>{let O=r.shape[R]._zod;return this.io==="input"?O.optin===void 0:O.optout===void 0}));I.size>0&&(g.required=Array.from(I)),r.catchall?._zod.def.type==="never"?g.additionalProperties=!1:r.catchall?r.catchall&&(g.additionalProperties=this.process(r.catchall,{...f,path:[...f.path,"additionalProperties"]})):this.io==="output"&&(g.additionalProperties=!1);break}case"union":{let g=v,b=r.options.map((x,I)=>this.process(x,{...f,path:[...f.path,"anyOf",I]}));g.anyOf=b;break}case"intersection":{let g=v,b=this.process(r.left,{...f,path:[...f.path,"allOf",0]}),x=this.process(r.right,{...f,path:[...f.path,"allOf",1]}),I=O=>"allOf"in O&&Object.keys(O).length===1,R=[...I(b)?b.allOf:[b],...I(x)?x.allOf:[x]];g.allOf=R;break}case"tuple":{let g=v;g.type="array";let b=this.target==="draft-2020-12"?"prefixItems":"items",x=this.target==="draft-2020-12"||this.target==="openapi-3.0"?"items":"additionalItems",I=r.items.map((V,Me)=>this.process(V,{...f,path:[...f.path,b,Me]})),R=r.rest?this.process(r.rest,{...f,path:[...f.path,x,...this.target==="openapi-3.0"?[r.items.length]:[]]}):null;this.target==="draft-2020-12"?(g.prefixItems=I,R&&(g.items=R)):this.target==="openapi-3.0"?(g.items={anyOf:I},R&&g.items.anyOf.push(R),g.minItems=I.length,R||(g.maxItems=I.length)):(g.items=I,R&&(g.additionalItems=R));let{minimum:O,maximum:M}=t._zod.bag;typeof O=="number"&&(g.minItems=O),typeof M=="number"&&(g.maxItems=M);break}case"record":{let g=v;g.type="object",(this.target==="draft-7"||this.target==="draft-2020-12")&&(g.propertyNames=this.process(r.keyType,{...f,path:[...f.path,"propertyNames"]})),g.additionalProperties=this.process(r.valueType,{...f,path:[...f.path,"additionalProperties"]});break}case"map":{if(this.unrepresentable==="throw")throw new Error("Map cannot be represented in JSON Schema");break}case"set":{if(this.unrepresentable==="throw")throw new Error("Set cannot be represented in JSON Schema");break}case"enum":{let g=v,b=ti(r.entries);b.every(x=>typeof x=="number")&&(g.type="number"),b.every(x=>typeof x=="string")&&(g.type="string"),g.enum=b;break}case"literal":{let g=v,b=[];for(let x of r.values)if(x===void 0){if(this.unrepresentable==="throw")throw new Error("Literal `undefined` cannot be represented in JSON Schema")}else if(typeof x=="bigint"){if(this.unrepresentable==="throw")throw new Error("BigInt literals cannot be represented in JSON Schema");b.push(Number(x))}else b.push(x);if(b.length!==0)if(b.length===1){let x=b[0];g.type=x===null?"null":typeof x,this.target==="draft-4"||this.target==="openapi-3.0"?g.enum=[x]:g.const=x}else b.every(x=>typeof x=="number")&&(g.type="number"),b.every(x=>typeof x=="string")&&(g.type="string"),b.every(x=>typeof x=="boolean")&&(g.type="string"),b.every(x=>x===null)&&(g.type="null"),g.enum=b;break}case"file":{let g=v,b={type:"string",format:"binary",contentEncoding:"binary"},{minimum:x,maximum:I,mime:R}=t._zod.bag;x!==void 0&&(b.minLength=x),I!==void 0&&(b.maxLength=I),R?R.length===1?(b.contentMediaType=R[0],Object.assign(g,b)):g.anyOf=R.map(O=>({...b,contentMediaType:O})):Object.assign(g,b);break}case"transform":{if(this.unrepresentable==="throw")throw new Error("Transforms cannot be represented in JSON Schema");break}case"nullable":{let g=this.process(r.innerType,f);this.target==="openapi-3.0"?(s.ref=r.innerType,v.nullable=!0):v.anyOf=[g,{type:"null"}];break}case"nonoptional":{this.process(r.innerType,f),s.ref=r.innerType;break}case"success":{let g=v;g.type="boolean";break}case"default":{this.process(r.innerType,f),s.ref=r.innerType,v.default=JSON.parse(JSON.stringify(r.defaultValue));break}case"prefault":{this.process(r.innerType,f),s.ref=r.innerType,this.io==="input"&&(v._prefault=JSON.parse(JSON.stringify(r.defaultValue)));break}case"catch":{this.process(r.innerType,f),s.ref=r.innerType;let g;try{g=r.catchValue(void 0)}catch{throw new Error("Dynamic catch values are not supported in JSON Schema")}v.default=g;break}case"nan":{if(this.unrepresentable==="throw")throw new Error("NaN cannot be represented in JSON Schema");break}case"template_literal":{let g=v,b=t._zod.pattern;if(!b)throw new Error("Pattern not found in template literal");g.type="string",g.pattern=b.source;break}case"pipe":{let g=this.io==="input"?r.in._zod.def.type==="transform"?r.out:r.in:r.out;this.process(g,f),s.ref=g;break}case"readonly":{this.process(r.innerType,f),s.ref=r.innerType,v.readOnly=!0;break}case"promise":{this.process(r.innerType,f),s.ref=r.innerType;break}case"optional":{this.process(r.innerType,f),s.ref=r.innerType;break}case"lazy":{let g=t._zod.innerType;this.process(g,f),s.ref=g;break}case"custom":{if(this.unrepresentable==="throw")throw new Error("Custom types cannot be represented in JSON Schema");break}case"function":{if(this.unrepresentable==="throw")throw new Error("Function types cannot be represented in JSON Schema");break}default:}}}let l=this.metadataRegistry.get(t);return l&&Object.assign(s.schema,l),this.io==="input"&&je(t)&&(delete s.schema.examples,delete s.schema.default),this.io==="input"&&s.schema._prefault&&((o=s.schema).default??(o.default=s.schema._prefault)),delete s.schema._prefault,this.seen.get(t).schema}emit(t,n){let o={cycles:n?.cycles??"ref",reused:n?.reused??"inline",external:n?.external??void 0},r=this.seen.get(t);if(!r)throw new Error("Unprocessed schema. This is a bug in Zod.");let i=d=>{let f=this.target==="draft-2020-12"?"$defs":"definitions";if(o.external){let b=o.external.registry.get(d[0])?.id,x=o.external.uri??(R=>R);if(b)return{ref:x(b)};let I=d[1].defId??d[1].schema.id??`schema${this.counter++}`;return d[1].defId=I,{defId:I,ref:`${x("__shared")}#/${f}/${I}`}}if(d[1]===r)return{ref:"#"};let v=`#/${f}/`,g=d[1].schema.id??`__schema${this.counter++}`;return{defId:g,ref:v+g}},a=d=>{if(d[1].schema.$ref)return;let f=d[1],{ref:_,defId:v}=i(d);f.def={...f.schema},v&&(f.defId=v);let g=f.schema;for(let b in g)delete g[b];g.$ref=_};if(o.cycles==="throw")for(let d of this.seen.entries()){let f=d[1];if(f.cycle)throw new Error(`Cycle detected: #/${f.cycle?.join("/")}/<root>
|
|
55
55
|
|
|
56
|
-
Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`)}for(let d of this.seen.entries()){let f=d[1];if(t===d[0]){a(d);continue}if(o.external){let v=o.external.registry.get(d[0])?.id;if(t!==d[0]&&v){a(d);continue}}if(this.metadataRegistry.get(d[0])?.id){a(d);continue}if(f.cycle){a(d);continue}if(f.count>1&&o.reused==="ref"){a(d);continue}}let s=(d,f)=>{let _=this.seen.get(d),v=_.def??_.schema,g={...v};if(_.ref===null)return;let b=_.ref;if(_.ref=null,b){s(b,f);let x=this.seen.get(b).schema;x.$ref&&(f.target==="draft-7"||f.target==="draft-4"||f.target==="openapi-3.0")?(v.allOf=v.allOf??[],v.allOf.push(x)):(Object.assign(v,x),Object.assign(v,g))}_.isParent||this.override({zodSchema:d,jsonSchema:v,path:_.path??[]})};for(let d of[...this.seen.entries()].reverse())s(d[0],{target:this.target});let c={};if(this.target==="draft-2020-12"?c.$schema="https://json-schema.org/draft/2020-12/schema":this.target==="draft-7"?c.$schema="http://json-schema.org/draft-07/schema#":this.target==="draft-4"?c.$schema="http://json-schema.org/draft-04/schema#":this.target==="openapi-3.0"||console.warn(`Invalid target: ${this.target}`),o.external?.uri){let d=o.external.registry.get(t)?.id;if(!d)throw new Error("Schema is missing an `id` property");c.$id=o.external.uri(d)}Object.assign(c,r.def);let l=o.external?.defs??{};for(let d of this.seen.entries()){let f=d[1];f.def&&f.defId&&(l[f.defId]=f.def)}o.external||Object.keys(l).length>0&&(this.target==="draft-2020-12"?c.$defs=l:c.definitions=l);try{return JSON.parse(JSON.stringify(c))}catch{throw new Error("Error converting schema to JSON.")}}};function so(e,t){if(e instanceof Kn){let o=new Ci(t),r={};for(let s of e._idmap.entries()){let[c,l]=s;o.process(l)}let i={},a={registry:e,uri:t?.uri,defs:r};for(let s of e._idmap.entries()){let[c,l]=s;i[c]=o.emit(l,{...t,external:a})}if(Object.keys(r).length>0){let s=o.target==="draft-2020-12"?"$defs":"definitions";i.__shared={[s]:r}}return{schemas:i}}let n=new Ci(t);return n.process(e),n.emit(e,t)}function je(e,t){let n=t??{seen:new Set};if(n.seen.has(e))return!1;n.seen.add(e);let r=e._zod.def;switch(r.type){case"string":case"number":case"bigint":case"boolean":case"date":case"symbol":case"undefined":case"null":case"any":case"unknown":case"never":case"void":case"literal":case"enum":case"nan":case"file":case"template_literal":return!1;case"array":return je(r.element,n);case"object":{for(let i in r.shape)if(je(r.shape[i],n))return!0;return!1}case"union":{for(let i of r.options)if(je(i,n))return!0;return!1}case"intersection":return je(r.left,n)||je(r.right,n);case"tuple":{for(let i of r.items)if(je(i,n))return!0;return!!(r.rest&&je(r.rest,n))}case"record":return je(r.keyType,n)||je(r.valueType,n);case"map":return je(r.keyType,n)||je(r.valueType,n);case"set":return je(r.valueType,n);case"promise":case"optional":case"nonoptional":case"nullable":case"readonly":return je(r.innerType,n);case"lazy":return je(r.getter(),n);case"default":return je(r.innerType,n);case"prefault":return je(r.innerType,n);case"custom":return!1;case"transform":return!0;case"pipe":return je(r.in,n)||je(r.out,n);case"success":return!1;case"catch":return!1;case"function":return!1;default:}throw new Error(`Unknown schema type: ${r.type}`)}var $_={};var ZI=$("ZodMiniType",(e,t)=>{if(!e._zod)throw new Error("Uninitialized schema in ZodMiniType.");W.init(e,t),e.def=t,e.type=t.type,e.parse=(n,o)=>Jr(e,n,o,{callee:e.parse}),e.safeParse=(n,o)=>xr(e,n,o),e.parseAsync=async(n,o)=>Gr(e,n,o,{callee:e.parseAsync}),e.safeParseAsync=async(n,o)=>wr(e,n,o),e.check=(...n)=>e.clone({...t,checks:[...t.checks??[],...n.map(o=>typeof o=="function"?{_zod:{check:o,def:{check:"custom"},onattach:[]}}:o)]}),e.clone=(n,o)=>Ne(e,n,o),e.brand=()=>e,e.register=((n,o)=>(n.add(e,o),e))});var MI=$("ZodMiniObject",(e,t)=>{tc.init(e,t),ZI.init(e,t),E.defineLazy(e,"shape",()=>t.shape)});function Uf(e,t){let n={type:"object",get shape(){return E.assignProp(this,"shape",{...e}),this.shape},...E.normalizeParams(t)};return new MI(n)}function vt(e){return!!e._zod}function tn(e){let t=Object.values(e);if(t.length===0)return Uf({});let n=t.every(vt),o=t.every(r=>!vt(r));if(n)return Uf(e);if(o)return Jg(e);throw new Error("Mixed Zod versions detected in object shape.")}function Ir(e,t){return vt(e)?xr(e,t):e.safeParse(t)}async function vu(e,t){return vt(e)?await wr(e,t):await e.safeParseAsync(t)}function Er(e){if(!e)return;let t;if(vt(e)?t=e._zod?.def?.shape:t=e.shape,!!t){if(typeof t=="function")try{return t()}catch{return}return t}}function co(e){if(e){if(typeof e=="object"){let t=e,n=e;if(!t._def&&!n._zod){let o=Object.values(e);if(o.length>0&&o.every(r=>typeof r=="object"&&r!==null&&(r._def!==void 0||r._zod!==void 0||typeof r.parse=="function")))return tn(e)}}if(vt(e)){let n=e._zod?.def;if(n&&(n.type==="object"||n.shape!==void 0))return e}else if(e.shape!==void 0)return e}}function _u(e){if(e&&typeof e=="object"){if("message"in e&&typeof e.message=="string")return e.message;if("issues"in e&&Array.isArray(e.issues)&&e.issues.length>0){let t=e.issues[0];if(t&&typeof t=="object"&&"message"in t)return String(t.message)}try{return JSON.stringify(e)}catch{return String(e)}}return String(e)}function k_(e){return e.description}function S_(e){if(vt(e))return e._zod?.def?.type==="optional";let t=e;return typeof e.isOptional=="function"?e.isOptional():t._def?.typeName==="ZodOptional"}function yu(e){if(vt(e)){let i=e._zod?.def;if(i){if(i.value!==void 0)return i.value;if(Array.isArray(i.values)&&i.values.length>0)return i.values[0]}}let n=e._def;if(n){if(n.value!==void 0)return n.value;if(Array.isArray(n.values)&&n.values.length>0)return n.values[0]}let o=e.value;if(o!==void 0)return o}var qt={};Fr(qt,{$brand:()=>Qo,$input:()=>Pc,$output:()=>Tc,NEVER:()=>Qa,TimePrecision:()=>Nc,ZodAny:()=>O_,ZodArray:()=>A_,ZodBase64:()=>hp,ZodBase64URL:()=>gp,ZodBigInt:()=>Vi,ZodBigIntFormat:()=>yp,ZodBoolean:()=>qi,ZodCIDRv4:()=>pp,ZodCIDRv6:()=>mp,ZodCUID:()=>ap,ZodCUID2:()=>sp,ZodCatch:()=>Y_,ZodCodec:()=>zp,ZodCustom:()=>Ou,ZodCustomStringFormat:()=>Mi,ZodDate:()=>Eu,ZodDefault:()=>K_,ZodDiscriminatedUnion:()=>D_,ZodE164:()=>vp,ZodEmail:()=>np,ZodEmoji:()=>op,ZodEnum:()=>Ui,ZodError:()=>BI,ZodFile:()=>V_,ZodFirstPartyTypeKind:()=>Ep,ZodFunction:()=>sy,ZodGUID:()=>ku,ZodIPv4:()=>dp,ZodIPv6:()=>fp,ZodISODate:()=>$u,ZodISODateTime:()=>bu,ZodISODuration:()=>wu,ZodISOTime:()=>xu,ZodIntersection:()=>C_,ZodIssueCode:()=>WE,ZodJWT:()=>_p,ZodKSUID:()=>lp,ZodLazy:()=>oy,ZodLiteral:()=>q_,ZodMap:()=>M_,ZodNaN:()=>ey,ZodNanoID:()=>ip,ZodNever:()=>N_,ZodNonOptional:()=>kp,ZodNull:()=>P_,ZodNullable:()=>B_,ZodNumber:()=>Li,ZodNumberFormat:()=>lo,ZodObject:()=>Tu,ZodOptional:()=>Ki,ZodPipe:()=>Sp,ZodPrefault:()=>J_,ZodPromise:()=>ay,ZodReadonly:()=>ty,ZodRealError:()=>nt,ZodRecord:()=>xp,ZodSet:()=>L_,ZodString:()=>Zi,ZodStringFormat:()=>xe,ZodSuccess:()=>X_,ZodSymbol:()=>E_,ZodTemplateLiteral:()=>ny,ZodTransform:()=>F_,ZodTuple:()=>U_,ZodType:()=>te,ZodULID:()=>cp,ZodURL:()=>Iu,ZodUUID:()=>rr,ZodUndefined:()=>T_,ZodUnion:()=>$p,ZodUnknown:()=>j_,ZodVoid:()=>R_,ZodXID:()=>up,_ZodString:()=>rp,_default:()=>H_,_function:()=>BE,any:()=>TE,array:()=>ie,base64:()=>fE,base64url:()=>pE,bigint:()=>kE,boolean:()=>Pe,catch:()=>Q_,check:()=>KE,cidrv4:()=>lE,cidrv6:()=>dE,clone:()=>Ne,codec:()=>qE,coerce:()=>Tp,config:()=>Ee,core:()=>pt,cuid:()=>nE,cuid2:()=>oE,custom:()=>Ip,date:()=>OE,decode:()=>Jf,decodeAsync:()=>Wf,discriminatedUnion:()=>Pu,e164:()=>mE,email:()=>HI,emoji:()=>tE,encode:()=>Hf,encodeAsync:()=>Gf,endsWith:()=>to,enum:()=>Be,file:()=>UE,flattenError:()=>Dn,float32:()=>bE,float64:()=>$E,formatError:()=>Cn,function:()=>BE,getErrorMap:()=>YE,globalRegistry:()=>Tt,gt:()=>Mt,gte:()=>Ve,guid:()=>JI,hash:()=>yE,hex:()=>_E,hostname:()=>vE,httpUrl:()=>eE,includes:()=>Qn,instanceof:()=>HE,int:()=>tp,int32:()=>xE,int64:()=>SE,intersection:()=>Bi,ipv4:()=>cE,ipv6:()=>uE,iso:()=>uo,json:()=>GE,jwt:()=>hE,keyof:()=>jE,ksuid:()=>sE,lazy:()=>iy,length:()=>Qr,literal:()=>B,locales:()=>Bn,looseObject:()=>Fe,lowercase:()=>Xn,lt:()=>Zt,lte:()=>rt,map:()=>AE,maxLength:()=>Yr,maxSize:()=>Xr,mime:()=>ro,minLength:()=>tr,minSize:()=>zr,multipleOf:()=>Sr,nan:()=>LE,nanoid:()=>rE,nativeEnum:()=>CE,negative:()=>cu,never:()=>bp,nonnegative:()=>lu,nonoptional:()=>W_,nonpositive:()=>uu,normalize:()=>no,null:()=>Fi,nullable:()=>Su,nullish:()=>ZE,number:()=>he,object:()=>Z,optional:()=>ke,overwrite:()=>Lt,parse:()=>Vf,parseAsync:()=>Ff,partialRecord:()=>RE,pipe:()=>zu,positive:()=>su,prefault:()=>G_,preprocess:()=>ju,prettifyError:()=>ns,promise:()=>FE,property:()=>du,readonly:()=>ry,record:()=>we,refine:()=>cy,regex:()=>Wn,regexes:()=>tt,registry:()=>gi,safeDecode:()=>Yf,safeDecodeAsync:()=>ep,safeEncode:()=>Xf,safeEncodeAsync:()=>Qf,safeParse:()=>Bf,safeParseAsync:()=>Kf,set:()=>DE,setErrorMap:()=>XE,size:()=>Gn,startsWith:()=>eo,strictObject:()=>NE,string:()=>k,stringFormat:()=>gE,stringbool:()=>JE,success:()=>ME,superRefine:()=>uy,symbol:()=>IE,templateLiteral:()=>VE,toJSONSchema:()=>so,toLowerCase:()=>io,toUpperCase:()=>ao,transform:()=>wp,treeifyError:()=>rs,trim:()=>oo,tuple:()=>Z_,uint32:()=>wE,uint64:()=>zE,ulid:()=>iE,undefined:()=>EE,union:()=>ve,unknown:()=>ye,uppercase:()=>Yn,url:()=>QI,util:()=>E,uuid:()=>GI,uuidv4:()=>WI,uuidv6:()=>XI,uuidv7:()=>YI,void:()=>PE,xid:()=>aE});var uo={};Fr(uo,{ZodISODate:()=>$u,ZodISODateTime:()=>bu,ZodISODuration:()=>wu,ZodISOTime:()=>xu,date:()=>Mf,datetime:()=>Zf,duration:()=>qf,time:()=>Lf});var bu=$("ZodISODateTime",(e,t)=>{Os.init(e,t),xe.init(e,t)});function Zf(e){return Rc(bu,e)}var $u=$("ZodISODate",(e,t)=>{js.init(e,t),xe.init(e,t)});function Mf(e){return Ac($u,e)}var xu=$("ZodISOTime",(e,t)=>{Ns.init(e,t),xe.init(e,t)});function Lf(e){return Dc(xu,e)}var wu=$("ZodISODuration",(e,t)=>{Rs.init(e,t),xe.init(e,t)});function qf(e){return Cc(wu,e)}var I_=(e,t)=>{ai.init(e,t),e.name="ZodError",Object.defineProperties(e,{format:{value:n=>Cn(e,n)},flatten:{value:n=>Dn(e,n)},addIssue:{value:n=>{e.issues.push(n),e.message=JSON.stringify(e.issues,Nn,2)}},addIssues:{value:n=>{e.issues.push(...n),e.message=JSON.stringify(e.issues,Nn,2)}},isEmpty:{get(){return e.issues.length===0}}})},BI=$("ZodError",I_),nt=$("ZodError",I_,{Parent:Error});var Vf=Un(nt),Ff=Zn(nt),Bf=Mn(nt),Kf=Ln(nt),Hf=os(nt),Jf=is(nt),Gf=as(nt),Wf=ss(nt),Xf=cs(nt),Yf=us(nt),Qf=ls(nt),ep=ds(nt);var te=$("ZodType",(e,t)=>(W.init(e,t),e.def=t,e.type=t.type,Object.defineProperty(e,"_def",{value:t}),e.check=(...n)=>e.clone({...t,checks:[...t.checks??[],...n.map(o=>typeof o=="function"?{_zod:{check:o,def:{check:"custom"},onattach:[]}}:o)]}),e.clone=(n,o)=>Ne(e,n,o),e.brand=()=>e,e.register=((n,o)=>(n.add(e,o),e)),e.parse=(n,o)=>Vf(e,n,o,{callee:e.parse}),e.safeParse=(n,o)=>Bf(e,n,o),e.parseAsync=async(n,o)=>Ff(e,n,o,{callee:e.parseAsync}),e.safeParseAsync=async(n,o)=>Kf(e,n,o),e.spa=e.safeParseAsync,e.encode=(n,o)=>Hf(e,n,o),e.decode=(n,o)=>Jf(e,n,o),e.encodeAsync=async(n,o)=>Gf(e,n,o),e.decodeAsync=async(n,o)=>Wf(e,n,o),e.safeEncode=(n,o)=>Xf(e,n,o),e.safeDecode=(n,o)=>Yf(e,n,o),e.safeEncodeAsync=async(n,o)=>Qf(e,n,o),e.safeDecodeAsync=async(n,o)=>ep(e,n,o),e.refine=(n,o)=>e.check(cy(n,o)),e.superRefine=n=>e.check(uy(n)),e.overwrite=n=>e.check(Lt(n)),e.optional=()=>ke(e),e.nullable=()=>Su(e),e.nullish=()=>ke(Su(e)),e.nonoptional=n=>W_(e,n),e.array=()=>ie(e),e.or=n=>ve([e,n]),e.and=n=>Bi(e,n),e.transform=n=>zu(e,wp(n)),e.default=n=>H_(e,n),e.prefault=n=>G_(e,n),e.catch=n=>Q_(e,n),e.pipe=n=>zu(e,n),e.readonly=()=>ry(e),e.describe=n=>{let o=e.clone();return Tt.add(o,{description:n}),o},Object.defineProperty(e,"description",{get(){return Tt.get(e)?.description},configurable:!0}),e.meta=(...n)=>{if(n.length===0)return Tt.get(e);let o=e.clone();return Tt.add(o,n[0]),o},e.isOptional=()=>e.safeParse(void 0).success,e.isNullable=()=>e.safeParse(null).success,e)),rp=$("_ZodString",(e,t)=>{kr.init(e,t),te.init(e,t);let n=e._zod.bag;e.format=n.format??null,e.minLength=n.minimum??null,e.maxLength=n.maximum??null,e.regex=(...o)=>e.check(Wn(...o)),e.includes=(...o)=>e.check(Qn(...o)),e.startsWith=(...o)=>e.check(eo(...o)),e.endsWith=(...o)=>e.check(to(...o)),e.min=(...o)=>e.check(tr(...o)),e.max=(...o)=>e.check(Yr(...o)),e.length=(...o)=>e.check(Qr(...o)),e.nonempty=(...o)=>e.check(tr(1,...o)),e.lowercase=o=>e.check(Xn(o)),e.uppercase=o=>e.check(Yn(o)),e.trim=()=>e.check(oo()),e.normalize=(...o)=>e.check(no(...o)),e.toLowerCase=()=>e.check(io()),e.toUpperCase=()=>e.check(ao())}),Zi=$("ZodString",(e,t)=>{kr.init(e,t),rp.init(e,t),e.email=n=>e.check(vi(np,n)),e.url=n=>e.check(Jn(Iu,n)),e.jwt=n=>e.check(Di(_p,n)),e.emoji=n=>e.check(xi(op,n)),e.guid=n=>e.check(Hn(ku,n)),e.uuid=n=>e.check(_i(rr,n)),e.uuidv4=n=>e.check(yi(rr,n)),e.uuidv6=n=>e.check(bi(rr,n)),e.uuidv7=n=>e.check($i(rr,n)),e.nanoid=n=>e.check(wi(ip,n)),e.guid=n=>e.check(Hn(ku,n)),e.cuid=n=>e.check(ki(ap,n)),e.cuid2=n=>e.check(Si(sp,n)),e.ulid=n=>e.check(zi(cp,n)),e.base64=n=>e.check(Ni(hp,n)),e.base64url=n=>e.check(Ri(gp,n)),e.xid=n=>e.check(Ii(up,n)),e.ksuid=n=>e.check(Ei(lp,n)),e.ipv4=n=>e.check(Ti(dp,n)),e.ipv6=n=>e.check(Pi(fp,n)),e.cidrv4=n=>e.check(Oi(pp,n)),e.cidrv6=n=>e.check(ji(mp,n)),e.e164=n=>e.check(Ai(vp,n)),e.datetime=n=>e.check(Zf(n)),e.date=n=>e.check(Mf(n)),e.time=n=>e.check(Lf(n)),e.duration=n=>e.check(qf(n))});function k(e){return Oc(Zi,e)}var xe=$("ZodStringFormat",(e,t)=>{ge.init(e,t),rp.init(e,t)}),np=$("ZodEmail",(e,t)=>{xs.init(e,t),xe.init(e,t)});function HI(e){return vi(np,e)}var ku=$("ZodGUID",(e,t)=>{bs.init(e,t),xe.init(e,t)});function JI(e){return Hn(ku,e)}var rr=$("ZodUUID",(e,t)=>{$s.init(e,t),xe.init(e,t)});function GI(e){return _i(rr,e)}function WI(e){return yi(rr,e)}function XI(e){return bi(rr,e)}function YI(e){return $i(rr,e)}var Iu=$("ZodURL",(e,t)=>{ws.init(e,t),xe.init(e,t)});function QI(e){return Jn(Iu,e)}function eE(e){return Jn(Iu,{protocol:/^https?$/,hostname:tt.domain,...E.normalizeParams(e)})}var op=$("ZodEmoji",(e,t)=>{ks.init(e,t),xe.init(e,t)});function tE(e){return xi(op,e)}var ip=$("ZodNanoID",(e,t)=>{Ss.init(e,t),xe.init(e,t)});function rE(e){return wi(ip,e)}var ap=$("ZodCUID",(e,t)=>{zs.init(e,t),xe.init(e,t)});function nE(e){return ki(ap,e)}var sp=$("ZodCUID2",(e,t)=>{Is.init(e,t),xe.init(e,t)});function oE(e){return Si(sp,e)}var cp=$("ZodULID",(e,t)=>{Es.init(e,t),xe.init(e,t)});function iE(e){return zi(cp,e)}var up=$("ZodXID",(e,t)=>{Ts.init(e,t),xe.init(e,t)});function aE(e){return Ii(up,e)}var lp=$("ZodKSUID",(e,t)=>{Ps.init(e,t),xe.init(e,t)});function sE(e){return Ei(lp,e)}var dp=$("ZodIPv4",(e,t)=>{As.init(e,t),xe.init(e,t)});function cE(e){return Ti(dp,e)}var fp=$("ZodIPv6",(e,t)=>{Ds.init(e,t),xe.init(e,t)});function uE(e){return Pi(fp,e)}var pp=$("ZodCIDRv4",(e,t)=>{Cs.init(e,t),xe.init(e,t)});function lE(e){return Oi(pp,e)}var mp=$("ZodCIDRv6",(e,t)=>{Us.init(e,t),xe.init(e,t)});function dE(e){return ji(mp,e)}var hp=$("ZodBase64",(e,t)=>{Zs.init(e,t),xe.init(e,t)});function fE(e){return Ni(hp,e)}var gp=$("ZodBase64URL",(e,t)=>{Ms.init(e,t),xe.init(e,t)});function pE(e){return Ri(gp,e)}var vp=$("ZodE164",(e,t)=>{Ls.init(e,t),xe.init(e,t)});function mE(e){return Ai(vp,e)}var _p=$("ZodJWT",(e,t)=>{qs.init(e,t),xe.init(e,t)});function hE(e){return Di(_p,e)}var Mi=$("ZodCustomStringFormat",(e,t)=>{Vs.init(e,t),xe.init(e,t)});function gE(e,t,n={}){return en(Mi,e,t,n)}function vE(e){return en(Mi,"hostname",tt.hostname,e)}function _E(e){return en(Mi,"hex",tt.hex,e)}function yE(e,t){let n=t?.enc??"hex",o=`${e}_${n}`,r=tt[o];if(!r)throw new Error(`Unrecognized hash format: ${o}`);return en(Mi,o,r,t)}var Li=$("ZodNumber",(e,t)=>{li.init(e,t),te.init(e,t),e.gt=(o,r)=>e.check(Mt(o,r)),e.gte=(o,r)=>e.check(Ve(o,r)),e.min=(o,r)=>e.check(Ve(o,r)),e.lt=(o,r)=>e.check(Zt(o,r)),e.lte=(o,r)=>e.check(rt(o,r)),e.max=(o,r)=>e.check(rt(o,r)),e.int=o=>e.check(tp(o)),e.safe=o=>e.check(tp(o)),e.positive=o=>e.check(Mt(0,o)),e.nonnegative=o=>e.check(Ve(0,o)),e.negative=o=>e.check(Zt(0,o)),e.nonpositive=o=>e.check(rt(0,o)),e.multipleOf=(o,r)=>e.check(Sr(o,r)),e.step=(o,r)=>e.check(Sr(o,r)),e.finite=()=>e;let n=e._zod.bag;e.minValue=Math.max(n.minimum??Number.NEGATIVE_INFINITY,n.exclusiveMinimum??Number.NEGATIVE_INFINITY)??null,e.maxValue=Math.min(n.maximum??Number.POSITIVE_INFINITY,n.exclusiveMaximum??Number.POSITIVE_INFINITY)??null,e.isInt=(n.format??"").includes("int")||Number.isSafeInteger(n.multipleOf??.5),e.isFinite=!0,e.format=n.format??null});function he(e){return Uc(Li,e)}var lo=$("ZodNumberFormat",(e,t)=>{Fs.init(e,t),Li.init(e,t)});function tp(e){return Mc(lo,e)}function bE(e){return Lc(lo,e)}function $E(e){return qc(lo,e)}function xE(e){return Vc(lo,e)}function wE(e){return Fc(lo,e)}var qi=$("ZodBoolean",(e,t)=>{Vn.init(e,t),te.init(e,t)});function Pe(e){return Bc(qi,e)}var Vi=$("ZodBigInt",(e,t)=>{di.init(e,t),te.init(e,t),e.gte=(o,r)=>e.check(Ve(o,r)),e.min=(o,r)=>e.check(Ve(o,r)),e.gt=(o,r)=>e.check(Mt(o,r)),e.gte=(o,r)=>e.check(Ve(o,r)),e.min=(o,r)=>e.check(Ve(o,r)),e.lt=(o,r)=>e.check(Zt(o,r)),e.lte=(o,r)=>e.check(rt(o,r)),e.max=(o,r)=>e.check(rt(o,r)),e.positive=o=>e.check(Mt(BigInt(0),o)),e.negative=o=>e.check(Zt(BigInt(0),o)),e.nonpositive=o=>e.check(rt(BigInt(0),o)),e.nonnegative=o=>e.check(Ve(BigInt(0),o)),e.multipleOf=(o,r)=>e.check(Sr(o,r));let n=e._zod.bag;e.minValue=n.minimum??null,e.maxValue=n.maximum??null,e.format=n.format??null});function kE(e){return Hc(Vi,e)}var yp=$("ZodBigIntFormat",(e,t)=>{Bs.init(e,t),Vi.init(e,t)});function SE(e){return Gc(yp,e)}function zE(e){return Wc(yp,e)}var E_=$("ZodSymbol",(e,t)=>{Ks.init(e,t),te.init(e,t)});function IE(e){return Xc(E_,e)}var T_=$("ZodUndefined",(e,t)=>{Hs.init(e,t),te.init(e,t)});function EE(e){return Yc(T_,e)}var P_=$("ZodNull",(e,t)=>{Js.init(e,t),te.init(e,t)});function Fi(e){return Qc(P_,e)}var O_=$("ZodAny",(e,t)=>{Gs.init(e,t),te.init(e,t)});function TE(){return eu(O_)}var j_=$("ZodUnknown",(e,t)=>{Ws.init(e,t),te.init(e,t)});function ye(){return tu(j_)}var N_=$("ZodNever",(e,t)=>{Xs.init(e,t),te.init(e,t)});function bp(e){return ru(N_,e)}var R_=$("ZodVoid",(e,t)=>{Ys.init(e,t),te.init(e,t)});function PE(e){return nu(R_,e)}var Eu=$("ZodDate",(e,t)=>{Qs.init(e,t),te.init(e,t),e.min=(o,r)=>e.check(Ve(o,r)),e.max=(o,r)=>e.check(rt(o,r));let n=e._zod.bag;e.minDate=n.minimum?new Date(n.minimum):null,e.maxDate=n.maximum?new Date(n.maximum):null});function OE(e){return ou(Eu,e)}var A_=$("ZodArray",(e,t)=>{ec.init(e,t),te.init(e,t),e.element=t.element,e.min=(n,o)=>e.check(tr(n,o)),e.nonempty=n=>e.check(tr(1,n)),e.max=(n,o)=>e.check(Yr(n,o)),e.length=(n,o)=>e.check(Qr(n,o)),e.unwrap=()=>e.element});function ie(e,t){return Cf(A_,e,t)}function jE(e){let t=e._zod.def.shape;return Be(Object.keys(t))}var Tu=$("ZodObject",(e,t)=>{Df.init(e,t),te.init(e,t),E.defineLazy(e,"shape",()=>t.shape),e.keyof=()=>Be(Object.keys(e._zod.def.shape)),e.catchall=n=>e.clone({...e._zod.def,catchall:n}),e.passthrough=()=>e.clone({...e._zod.def,catchall:ye()}),e.loose=()=>e.clone({...e._zod.def,catchall:ye()}),e.strict=()=>e.clone({...e._zod.def,catchall:bp()}),e.strip=()=>e.clone({...e._zod.def,catchall:void 0}),e.extend=n=>E.extend(e,n),e.safeExtend=n=>E.safeExtend(e,n),e.merge=n=>E.merge(e,n),e.pick=n=>E.pick(e,n),e.omit=n=>E.omit(e,n),e.partial=(...n)=>E.partial(Ki,e,n[0]),e.required=(...n)=>E.required(kp,e,n[0])});function Z(e,t){let n={type:"object",get shape(){return E.assignProp(this,"shape",e?E.objectClone(e):{}),this.shape},...E.normalizeParams(t)};return new Tu(n)}function NE(e,t){return new Tu({type:"object",get shape(){return E.assignProp(this,"shape",E.objectClone(e)),this.shape},catchall:bp(),...E.normalizeParams(t)})}function Fe(e,t){return new Tu({type:"object",get shape(){return E.assignProp(this,"shape",E.objectClone(e)),this.shape},catchall:ye(),...E.normalizeParams(t)})}var $p=$("ZodUnion",(e,t)=>{fi.init(e,t),te.init(e,t),e.options=t.options});function ve(e,t){return new $p({type:"union",options:e,...E.normalizeParams(t)})}var D_=$("ZodDiscriminatedUnion",(e,t)=>{$p.init(e,t),rc.init(e,t)});function Pu(e,t,n){return new D_({type:"union",options:t,discriminator:e,...E.normalizeParams(n)})}var C_=$("ZodIntersection",(e,t)=>{nc.init(e,t),te.init(e,t)});function Bi(e,t){return new C_({type:"intersection",left:e,right:t})}var U_=$("ZodTuple",(e,t)=>{pi.init(e,t),te.init(e,t),e.rest=n=>e.clone({...e._zod.def,rest:n})});function Z_(e,t,n){let o=t instanceof W,r=o?n:t,i=o?t:null;return new U_({type:"tuple",items:e,rest:i,...E.normalizeParams(r)})}var xp=$("ZodRecord",(e,t)=>{oc.init(e,t),te.init(e,t),e.keyType=t.keyType,e.valueType=t.valueType});function we(e,t,n){return new xp({type:"record",keyType:e,valueType:t,...E.normalizeParams(n)})}function RE(e,t,n){let o=Ne(e);return o._zod.values=void 0,new xp({type:"record",keyType:o,valueType:t,...E.normalizeParams(n)})}var M_=$("ZodMap",(e,t)=>{ic.init(e,t),te.init(e,t),e.keyType=t.keyType,e.valueType=t.valueType});function AE(e,t,n){return new M_({type:"map",keyType:e,valueType:t,...E.normalizeParams(n)})}var L_=$("ZodSet",(e,t)=>{ac.init(e,t),te.init(e,t),e.min=(...n)=>e.check(zr(...n)),e.nonempty=n=>e.check(zr(1,n)),e.max=(...n)=>e.check(Xr(...n)),e.size=(...n)=>e.check(Gn(...n))});function DE(e,t){return new L_({type:"set",valueType:e,...E.normalizeParams(t)})}var Ui=$("ZodEnum",(e,t)=>{sc.init(e,t),te.init(e,t),e.enum=t.entries,e.options=Object.values(t.entries);let n=new Set(Object.keys(t.entries));e.extract=(o,r)=>{let i={};for(let a of o)if(n.has(a))i[a]=t.entries[a];else throw new Error(`Key ${a} not found in enum`);return new Ui({...t,checks:[],...E.normalizeParams(r),entries:i})},e.exclude=(o,r)=>{let i={...t.entries};for(let a of o)if(n.has(a))delete i[a];else throw new Error(`Key ${a} not found in enum`);return new Ui({...t,checks:[],...E.normalizeParams(r),entries:i})}});function Be(e,t){let n=Array.isArray(e)?Object.fromEntries(e.map(o=>[o,o])):e;return new Ui({type:"enum",entries:n,...E.normalizeParams(t)})}function CE(e,t){return new Ui({type:"enum",entries:e,...E.normalizeParams(t)})}var q_=$("ZodLiteral",(e,t)=>{cc.init(e,t),te.init(e,t),e.values=new Set(t.values),Object.defineProperty(e,"value",{get(){if(t.values.length>1)throw new Error("This schema contains multiple valid literal values. Use `.values` instead.");return t.values[0]}})});function B(e,t){return new q_({type:"literal",values:Array.isArray(e)?e:[e],...E.normalizeParams(t)})}var V_=$("ZodFile",(e,t)=>{uc.init(e,t),te.init(e,t),e.min=(n,o)=>e.check(zr(n,o)),e.max=(n,o)=>e.check(Xr(n,o)),e.mime=(n,o)=>e.check(ro(Array.isArray(n)?n:[n],o))});function UE(e){return fu(V_,e)}var F_=$("ZodTransform",(e,t)=>{lc.init(e,t),te.init(e,t),e._zod.parse=(n,o)=>{if(o.direction==="backward")throw new gr(e.constructor.name);n.addIssue=i=>{if(typeof i=="string")n.issues.push(E.issue(i,n.value,t));else{let a=i;a.fatal&&(a.continue=!1),a.code??(a.code="custom"),a.input??(a.input=n.value),a.inst??(a.inst=e),n.issues.push(E.issue(a))}};let r=t.transform(n.value,n);return r instanceof Promise?r.then(i=>(n.value=i,n)):(n.value=r,n)}});function wp(e){return new F_({type:"transform",transform:e})}var Ki=$("ZodOptional",(e,t)=>{dc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function ke(e){return new Ki({type:"optional",innerType:e})}var B_=$("ZodNullable",(e,t)=>{fc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function Su(e){return new B_({type:"nullable",innerType:e})}function ZE(e){return ke(Su(e))}var K_=$("ZodDefault",(e,t)=>{pc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});function H_(e,t){return new K_({type:"default",innerType:e,get defaultValue(){return typeof t=="function"?t():E.shallowClone(t)}})}var J_=$("ZodPrefault",(e,t)=>{mc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function G_(e,t){return new J_({type:"prefault",innerType:e,get defaultValue(){return typeof t=="function"?t():E.shallowClone(t)}})}var kp=$("ZodNonOptional",(e,t)=>{hc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function W_(e,t){return new kp({type:"nonoptional",innerType:e,...E.normalizeParams(t)})}var X_=$("ZodSuccess",(e,t)=>{gc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function ME(e){return new X_({type:"success",innerType:e})}var Y_=$("ZodCatch",(e,t)=>{vc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});function Q_(e,t){return new Y_({type:"catch",innerType:e,catchValue:typeof t=="function"?t:()=>t})}var ey=$("ZodNaN",(e,t)=>{_c.init(e,t),te.init(e,t)});function LE(e){return au(ey,e)}var Sp=$("ZodPipe",(e,t)=>{yc.init(e,t),te.init(e,t),e.in=t.in,e.out=t.out});function zu(e,t){return new Sp({type:"pipe",in:e,out:t})}var zp=$("ZodCodec",(e,t)=>{Sp.init(e,t),Fn.init(e,t)});function qE(e,t,n){return new zp({type:"pipe",in:e,out:t,transform:n.decode,reverseTransform:n.encode})}var ty=$("ZodReadonly",(e,t)=>{bc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function ry(e){return new ty({type:"readonly",innerType:e})}var ny=$("ZodTemplateLiteral",(e,t)=>{$c.init(e,t),te.init(e,t)});function VE(e,t){return new ny({type:"template_literal",parts:e,...E.normalizeParams(t)})}var oy=$("ZodLazy",(e,t)=>{kc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.getter()});function iy(e){return new oy({type:"lazy",getter:e})}var ay=$("ZodPromise",(e,t)=>{wc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function FE(e){return new ay({type:"promise",innerType:e})}var sy=$("ZodFunction",(e,t)=>{xc.init(e,t),te.init(e,t)});function BE(e){return new sy({type:"function",input:Array.isArray(e?.input)?Z_(e?.input):e?.input??ie(ye()),output:e?.output??ye()})}var Ou=$("ZodCustom",(e,t)=>{Sc.init(e,t),te.init(e,t)});function KE(e){let t=new $e({check:"custom"});return t._zod.check=e,t}function Ip(e,t){return pu(Ou,e??(()=>!0),t)}function cy(e,t={}){return mu(Ou,e,t)}function uy(e){return hu(e)}function HE(e,t={error:`Input not instance of ${e.name}`}){let n=new Ou({type:"custom",check:"custom",fn:o=>o instanceof e,abort:!0,...E.normalizeParams(t)});return n._zod.bag.Class=e,n}var JE=(...e)=>gu({Codec:zp,Boolean:qi,String:Zi},...e);function GE(e){let t=iy(()=>ve([k(e),he(),Pe(),Fi(),ie(t),we(k(),t)]));return t}function ju(e,t){return zu(wp(e),t)}var WE={invalid_type:"invalid_type",too_big:"too_big",too_small:"too_small",invalid_format:"invalid_format",not_multiple_of:"not_multiple_of",unrecognized_keys:"unrecognized_keys",invalid_union:"invalid_union",invalid_key:"invalid_key",invalid_element:"invalid_element",invalid_value:"invalid_value",custom:"custom"};function XE(e){Ee({customError:e})}function YE(){return Ee().customError}var Ep;Ep||(Ep={});var Tp={};Fr(Tp,{bigint:()=>rT,boolean:()=>tT,date:()=>nT,number:()=>eT,string:()=>QE});function QE(e){return jc(Zi,e)}function eT(e){return Zc(Li,e)}function tT(e){return Kc(qi,e)}function rT(e){return Jc(Vi,e)}function nT(e){return iu(Eu,e)}Ee(zc());var Op="2025-11-25";var ly=[Op,"2025-06-18","2025-03-26","2024-11-05","2024-10-07"],Tr="io.modelcontextprotocol/related-task",Ru="2.0",Ae=Ip(e=>e!==null&&(typeof e=="object"||typeof e=="function")),dy=ve([k(),he().int()]),fy=k(),JZ=Fe({ttl:ve([he(),Fi()]).optional(),pollInterval:he().optional()}),iT=Z({ttl:he().optional()}),aT=Z({taskId:k()}),jp=Fe({progressToken:dy.optional(),[Tr]:aT.optional()}),mt=Z({_meta:jp.optional()}),Hi=mt.extend({task:iT.optional()}),py=e=>Hi.safeParse(e).success,De=Z({method:k(),params:mt.loose().optional()}),_t=Z({_meta:jp.optional()}),yt=Z({method:k(),params:_t.loose().optional()}),Ce=Fe({_meta:jp.optional()}),Au=ve([k(),he().int()]),my=Z({jsonrpc:B(Ru),id:Au,...De.shape}).strict(),Np=e=>my.safeParse(e).success,hy=Z({jsonrpc:B(Ru),...yt.shape}).strict(),gy=e=>hy.safeParse(e).success,Rp=Z({jsonrpc:B(Ru),id:Au,result:Ce}).strict(),Ji=e=>Rp.safeParse(e).success;var H;(function(e){e[e.ConnectionClosed=-32e3]="ConnectionClosed",e[e.RequestTimeout=-32001]="RequestTimeout",e[e.ParseError=-32700]="ParseError",e[e.InvalidRequest=-32600]="InvalidRequest",e[e.MethodNotFound=-32601]="MethodNotFound",e[e.InvalidParams=-32602]="InvalidParams",e[e.InternalError=-32603]="InternalError",e[e.UrlElicitationRequired=-32042]="UrlElicitationRequired"})(H||(H={}));var Ap=Z({jsonrpc:B(Ru),id:Au.optional(),error:Z({code:he().int(),message:k(),data:ye().optional()})}).strict();var vy=e=>Ap.safeParse(e).success;var _y=ve([my,hy,Rp,Ap]),GZ=ve([Rp,Ap]),Du=Ce.strict(),sT=_t.extend({requestId:Au.optional(),reason:k().optional()}),Cu=yt.extend({method:B("notifications/cancelled"),params:sT}),cT=Z({src:k(),mimeType:k().optional(),sizes:ie(k()).optional(),theme:Be(["light","dark"]).optional()}),Gi=Z({icons:ie(cT).optional()}),fo=Z({name:k(),title:k().optional()}),yy=fo.extend({...fo.shape,...Gi.shape,version:k(),websiteUrl:k().optional(),description:k().optional()}),uT=Bi(Z({applyDefaults:Pe().optional()}),we(k(),ye())),lT=ju(e=>e&&typeof e=="object"&&!Array.isArray(e)&&Object.keys(e).length===0?{form:{}}:e,Bi(Z({form:uT.optional(),url:Ae.optional()}),we(k(),ye()).optional())),dT=Fe({list:Ae.optional(),cancel:Ae.optional(),requests:Fe({sampling:Fe({createMessage:Ae.optional()}).optional(),elicitation:Fe({create:Ae.optional()}).optional()}).optional()}),fT=Fe({list:Ae.optional(),cancel:Ae.optional(),requests:Fe({tools:Fe({call:Ae.optional()}).optional()}).optional()}),pT=Z({experimental:we(k(),Ae).optional(),sampling:Z({context:Ae.optional(),tools:Ae.optional()}).optional(),elicitation:lT.optional(),roots:Z({listChanged:Pe().optional()}).optional(),tasks:dT.optional()}),mT=mt.extend({protocolVersion:k(),capabilities:pT,clientInfo:yy}),Dp=De.extend({method:B("initialize"),params:mT});var hT=Z({experimental:we(k(),Ae).optional(),logging:Ae.optional(),completions:Ae.optional(),prompts:Z({listChanged:Pe().optional()}).optional(),resources:Z({subscribe:Pe().optional(),listChanged:Pe().optional()}).optional(),tools:Z({listChanged:Pe().optional()}).optional(),tasks:fT.optional()}),gT=Ce.extend({protocolVersion:k(),capabilities:hT,serverInfo:yy,instructions:k().optional()}),Cp=yt.extend({method:B("notifications/initialized"),params:_t.optional()});var Uu=De.extend({method:B("ping"),params:mt.optional()}),vT=Z({progress:he(),total:ke(he()),message:ke(k())}),_T=Z({..._t.shape,...vT.shape,progressToken:dy}),Zu=yt.extend({method:B("notifications/progress"),params:_T}),yT=mt.extend({cursor:fy.optional()}),Wi=De.extend({params:yT.optional()}),Xi=Ce.extend({nextCursor:fy.optional()}),bT=Be(["working","input_required","completed","failed","cancelled"]),Yi=Z({taskId:k(),status:bT,ttl:ve([he(),Fi()]),createdAt:k(),lastUpdatedAt:k(),pollInterval:ke(he()),statusMessage:ke(k())}),po=Ce.extend({task:Yi}),$T=_t.merge(Yi),Qi=yt.extend({method:B("notifications/tasks/status"),params:$T}),Mu=De.extend({method:B("tasks/get"),params:mt.extend({taskId:k()})}),Lu=Ce.merge(Yi),qu=De.extend({method:B("tasks/result"),params:mt.extend({taskId:k()})}),WZ=Ce.loose(),Vu=Wi.extend({method:B("tasks/list")}),Fu=Xi.extend({tasks:ie(Yi)}),Bu=De.extend({method:B("tasks/cancel"),params:mt.extend({taskId:k()})}),by=Ce.merge(Yi),$y=Z({uri:k(),mimeType:ke(k()),_meta:we(k(),ye()).optional()}),xy=$y.extend({text:k()}),Up=k().refine(e=>{try{return atob(e),!0}catch{return!1}},{message:"Invalid Base64 string"}),wy=$y.extend({blob:Up}),ea=Be(["user","assistant"]),mo=Z({audience:ie(ea).optional(),priority:he().min(0).max(1).optional(),lastModified:uo.datetime({offset:!0}).optional()}),ky=Z({...fo.shape,...Gi.shape,uri:k(),description:ke(k()),mimeType:ke(k()),annotations:mo.optional(),_meta:ke(Fe({}))}),xT=Z({...fo.shape,...Gi.shape,uriTemplate:k(),description:ke(k()),mimeType:ke(k()),annotations:mo.optional(),_meta:ke(Fe({}))}),Ku=Wi.extend({method:B("resources/list")}),wT=Xi.extend({resources:ie(ky)}),Hu=Wi.extend({method:B("resources/templates/list")}),kT=Xi.extend({resourceTemplates:ie(xT)}),Zp=mt.extend({uri:k()}),ST=Zp,Ju=De.extend({method:B("resources/read"),params:ST}),zT=Ce.extend({contents:ie(ve([xy,wy]))}),IT=yt.extend({method:B("notifications/resources/list_changed"),params:_t.optional()}),ET=Zp,TT=De.extend({method:B("resources/subscribe"),params:ET}),PT=Zp,OT=De.extend({method:B("resources/unsubscribe"),params:PT}),jT=_t.extend({uri:k()}),NT=yt.extend({method:B("notifications/resources/updated"),params:jT}),RT=Z({name:k(),description:ke(k()),required:ke(Pe())}),AT=Z({...fo.shape,...Gi.shape,description:ke(k()),arguments:ke(ie(RT)),_meta:ke(Fe({}))}),Gu=Wi.extend({method:B("prompts/list")}),DT=Xi.extend({prompts:ie(AT)}),CT=mt.extend({name:k(),arguments:we(k(),k()).optional()}),Wu=De.extend({method:B("prompts/get"),params:CT}),Mp=Z({type:B("text"),text:k(),annotations:mo.optional(),_meta:we(k(),ye()).optional()}),Lp=Z({type:B("image"),data:Up,mimeType:k(),annotations:mo.optional(),_meta:we(k(),ye()).optional()}),qp=Z({type:B("audio"),data:Up,mimeType:k(),annotations:mo.optional(),_meta:we(k(),ye()).optional()}),UT=Z({type:B("tool_use"),name:k(),id:k(),input:we(k(),ye()),_meta:we(k(),ye()).optional()}),ZT=Z({type:B("resource"),resource:ve([xy,wy]),annotations:mo.optional(),_meta:we(k(),ye()).optional()}),MT=ky.extend({type:B("resource_link")}),Vp=ve([Mp,Lp,qp,MT,ZT]),LT=Z({role:ea,content:Vp}),qT=Ce.extend({description:k().optional(),messages:ie(LT)}),VT=yt.extend({method:B("notifications/prompts/list_changed"),params:_t.optional()}),FT=Z({title:k().optional(),readOnlyHint:Pe().optional(),destructiveHint:Pe().optional(),idempotentHint:Pe().optional(),openWorldHint:Pe().optional()}),BT=Z({taskSupport:Be(["required","optional","forbidden"]).optional()}),Sy=Z({...fo.shape,...Gi.shape,description:k().optional(),inputSchema:Z({type:B("object"),properties:we(k(),Ae).optional(),required:ie(k()).optional()}).catchall(ye()),outputSchema:Z({type:B("object"),properties:we(k(),Ae).optional(),required:ie(k()).optional()}).catchall(ye()).optional(),annotations:FT.optional(),execution:BT.optional(),_meta:we(k(),ye()).optional()}),Xu=Wi.extend({method:B("tools/list")}),KT=Xi.extend({tools:ie(Sy)}),Yu=Ce.extend({content:ie(Vp).default([]),structuredContent:we(k(),ye()).optional(),isError:Pe().optional()}),XZ=Yu.or(Ce.extend({toolResult:ye()})),HT=Hi.extend({name:k(),arguments:we(k(),ye()).optional()}),ho=De.extend({method:B("tools/call"),params:HT}),JT=yt.extend({method:B("notifications/tools/list_changed"),params:_t.optional()}),YZ=Z({autoRefresh:Pe().default(!0),debounceMs:he().int().nonnegative().default(300)}),ta=Be(["debug","info","notice","warning","error","critical","alert","emergency"]),GT=mt.extend({level:ta}),Fp=De.extend({method:B("logging/setLevel"),params:GT}),WT=_t.extend({level:ta,logger:k().optional(),data:ye()}),XT=yt.extend({method:B("notifications/message"),params:WT}),YT=Z({name:k().optional()}),QT=Z({hints:ie(YT).optional(),costPriority:he().min(0).max(1).optional(),speedPriority:he().min(0).max(1).optional(),intelligencePriority:he().min(0).max(1).optional()}),eP=Z({mode:Be(["auto","required","none"]).optional()}),tP=Z({type:B("tool_result"),toolUseId:k().describe("The unique identifier for the corresponding tool call."),content:ie(Vp).default([]),structuredContent:Z({}).loose().optional(),isError:Pe().optional(),_meta:we(k(),ye()).optional()}),rP=Pu("type",[Mp,Lp,qp]),Nu=Pu("type",[Mp,Lp,qp,UT,tP]),nP=Z({role:ea,content:ve([Nu,ie(Nu)]),_meta:we(k(),ye()).optional()}),oP=Hi.extend({messages:ie(nP),modelPreferences:QT.optional(),systemPrompt:k().optional(),includeContext:Be(["none","thisServer","allServers"]).optional(),temperature:he().optional(),maxTokens:he().int(),stopSequences:ie(k()).optional(),metadata:Ae.optional(),tools:ie(Sy).optional(),toolChoice:eP.optional()}),iP=De.extend({method:B("sampling/createMessage"),params:oP}),ra=Ce.extend({model:k(),stopReason:ke(Be(["endTurn","stopSequence","maxTokens"]).or(k())),role:ea,content:rP}),Bp=Ce.extend({model:k(),stopReason:ke(Be(["endTurn","stopSequence","maxTokens","toolUse"]).or(k())),role:ea,content:ve([Nu,ie(Nu)])}),aP=Z({type:B("boolean"),title:k().optional(),description:k().optional(),default:Pe().optional()}),sP=Z({type:B("string"),title:k().optional(),description:k().optional(),minLength:he().optional(),maxLength:he().optional(),format:Be(["email","uri","date","date-time"]).optional(),default:k().optional()}),cP=Z({type:Be(["number","integer"]),title:k().optional(),description:k().optional(),minimum:he().optional(),maximum:he().optional(),default:he().optional()}),uP=Z({type:B("string"),title:k().optional(),description:k().optional(),enum:ie(k()),default:k().optional()}),lP=Z({type:B("string"),title:k().optional(),description:k().optional(),oneOf:ie(Z({const:k(),title:k()})),default:k().optional()}),dP=Z({type:B("string"),title:k().optional(),description:k().optional(),enum:ie(k()),enumNames:ie(k()).optional(),default:k().optional()}),fP=ve([uP,lP]),pP=Z({type:B("array"),title:k().optional(),description:k().optional(),minItems:he().optional(),maxItems:he().optional(),items:Z({type:B("string"),enum:ie(k())}),default:ie(k()).optional()}),mP=Z({type:B("array"),title:k().optional(),description:k().optional(),minItems:he().optional(),maxItems:he().optional(),items:Z({anyOf:ie(Z({const:k(),title:k()}))}),default:ie(k()).optional()}),hP=ve([pP,mP]),gP=ve([dP,fP,hP]),vP=ve([gP,aP,sP,cP]),_P=Hi.extend({mode:B("form").optional(),message:k(),requestedSchema:Z({type:B("object"),properties:we(k(),vP),required:ie(k()).optional()})}),yP=Hi.extend({mode:B("url"),message:k(),elicitationId:k(),url:k().url()}),bP=ve([_P,yP]),$P=De.extend({method:B("elicitation/create"),params:bP}),xP=_t.extend({elicitationId:k()}),wP=yt.extend({method:B("notifications/elicitation/complete"),params:xP}),go=Ce.extend({action:Be(["accept","decline","cancel"]),content:ju(e=>e===null?void 0:e,we(k(),ve([k(),he(),Pe(),ie(k())])).optional())}),kP=Z({type:B("ref/resource"),uri:k()});var SP=Z({type:B("ref/prompt"),name:k()}),zP=mt.extend({ref:ve([SP,kP]),argument:Z({name:k(),value:k()}),context:Z({arguments:we(k(),k()).optional()}).optional()}),Qu=De.extend({method:B("completion/complete"),params:zP});function zy(e){if(e.params.ref.type!=="ref/prompt")throw new TypeError(`Expected CompleteRequestPrompt, but got ${e.params.ref.type}`)}function Iy(e){if(e.params.ref.type!=="ref/resource")throw new TypeError(`Expected CompleteRequestResourceTemplate, but got ${e.params.ref.type}`)}var IP=Ce.extend({completion:Fe({values:ie(k()).max(100),total:ke(he().int()),hasMore:ke(Pe())})}),EP=Z({uri:k().startsWith("file://"),name:k().optional(),_meta:we(k(),ye()).optional()}),TP=De.extend({method:B("roots/list"),params:mt.optional()}),Kp=Ce.extend({roots:ie(EP)}),PP=yt.extend({method:B("notifications/roots/list_changed"),params:_t.optional()}),QZ=ve([Uu,Dp,Qu,Fp,Wu,Gu,Ku,Hu,Ju,TT,OT,ho,Xu,Mu,qu,Vu,Bu]),e6=ve([Cu,Zu,Cp,PP,Qi]),t6=ve([Du,ra,Bp,go,Kp,Lu,Fu,po]),r6=ve([Uu,iP,$P,TP,Mu,qu,Vu,Bu]),n6=ve([Cu,Zu,XT,NT,IT,JT,VT,Qi,wP]),o6=ve([Du,gT,IP,qT,DT,wT,kT,zT,Yu,KT,Lu,Fu,po]),F=class e extends Error{constructor(t,n,o){super(`MCP error ${t}: ${n}`),this.code=t,this.data=o,this.name="McpError"}static fromError(t,n,o){if(t===H.UrlElicitationRequired&&o){let r=o;if(r.elicitations)return new Pp(r.elicitations,n)}return new e(t,n,o)}},Pp=class extends F{constructor(t,n=`URL elicitation${t.length>1?"s":""} required`){super(H.UrlElicitationRequired,n,{elicitations:t})}get elicitations(){return this.data?.elicitations??[]}};function Pr(e){return e==="completed"||e==="failed"||e==="cancelled"}var Ty=Symbol("Let zodToJsonSchema decide on which parser to use");var Ey={name:void 0,$refStrategy:"root",basePath:["#"],effectStrategy:"input",pipeStrategy:"all",dateStrategy:"format:date-time",mapStrategy:"entries",removeAdditionalStrategy:"passthrough",allowedAdditionalProperties:!0,rejectedAdditionalProperties:!1,definitionPath:"definitions",target:"jsonSchema7",strictUnions:!1,definitions:{},errorMessages:!1,markdownDescription:!1,patternStrategy:"escape",applyRegexFlags:!1,emailStrategy:"format:email",base64Strategy:"contentEncoding:base64",nameStrategy:"ref",openAiAnyTypeName:"OpenAiAnyType"},Py=e=>typeof e=="string"?{...Ey,name:e}:{...Ey,...e};var Oy=e=>{let t=Py(e),n=t.name!==void 0?[...t.basePath,t.definitionPath,t.name]:t.basePath;return{...t,flags:{hasReferencedOpenAiAnyType:!1},currentPath:n,propertyPath:void 0,seen:new Map(Object.entries(t.definitions).map(([o,r])=>[r._def,{def:r._def,path:[...t.basePath,t.definitionPath,o],jsonSchema:void 0}]))}};function Hp(e,t,n,o){o?.errorMessages&&n&&(e.errorMessage={...e.errorMessage,[t]:n})}function ue(e,t,n,o,r){e[t]=n,Hp(e,t,o,r)}var el=(e,t)=>{let n=0;for(;n<e.length&&n<t.length&&e[n]===t[n];n++);return[(e.length-n).toString(),...t.slice(n)].join("/")};function Ie(e){if(e.target!=="openAi")return{};let t=[...e.basePath,e.definitionPath,e.openAiAnyTypeName];return e.flags.hasReferencedOpenAiAnyType=!0,{$ref:e.$refStrategy==="relative"?el(t,e.currentPath):t.join("/")}}function jy(e,t){let n={type:"array"};return e.type?._def&&e.type?._def?.typeName!==O.ZodAny&&(n.items=G(e.type._def,{...t,currentPath:[...t.currentPath,"items"]})),e.minLength&&ue(n,"minItems",e.minLength.value,e.minLength.message,t),e.maxLength&&ue(n,"maxItems",e.maxLength.value,e.maxLength.message,t),e.exactLength&&(ue(n,"minItems",e.exactLength.value,e.exactLength.message,t),ue(n,"maxItems",e.exactLength.value,e.exactLength.message,t)),n}function Ny(e,t){let n={type:"integer",format:"int64"};if(!e.checks)return n;for(let o of e.checks)switch(o.kind){case"min":t.target==="jsonSchema7"?o.inclusive?ue(n,"minimum",o.value,o.message,t):ue(n,"exclusiveMinimum",o.value,o.message,t):(o.inclusive||(n.exclusiveMinimum=!0),ue(n,"minimum",o.value,o.message,t));break;case"max":t.target==="jsonSchema7"?o.inclusive?ue(n,"maximum",o.value,o.message,t):ue(n,"exclusiveMaximum",o.value,o.message,t):(o.inclusive||(n.exclusiveMaximum=!0),ue(n,"maximum",o.value,o.message,t));break;case"multipleOf":ue(n,"multipleOf",o.value,o.message,t);break}return n}function Ry(){return{type:"boolean"}}function tl(e,t){return G(e.type._def,t)}var Ay=(e,t)=>G(e.innerType._def,t);function Jp(e,t,n){let o=n??t.dateStrategy;if(Array.isArray(o))return{anyOf:o.map((r,i)=>Jp(e,t,r))};switch(o){case"string":case"format:date-time":return{type:"string",format:"date-time"};case"format:date":return{type:"string",format:"date"};case"integer":return OP(e,t)}}var OP=(e,t)=>{let n={type:"integer",format:"unix-time"};if(t.target==="openApi3")return n;for(let o of e.checks)switch(o.kind){case"min":ue(n,"minimum",o.value,o.message,t);break;case"max":ue(n,"maximum",o.value,o.message,t);break}return n};function Dy(e,t){return{...G(e.innerType._def,t),default:e.defaultValue()}}function Cy(e,t){return t.effectStrategy==="input"?G(e.schema._def,t):Ie(t)}function Uy(e){return{type:"string",enum:Array.from(e.values)}}var jP=e=>"type"in e&&e.type==="string"?!1:"allOf"in e;function Zy(e,t){let n=[G(e.left._def,{...t,currentPath:[...t.currentPath,"allOf","0"]}),G(e.right._def,{...t,currentPath:[...t.currentPath,"allOf","1"]})].filter(i=>!!i),o=t.target==="jsonSchema2019-09"?{unevaluatedProperties:!1}:void 0,r=[];return n.forEach(i=>{if(jP(i))r.push(...i.allOf),i.unevaluatedProperties===void 0&&(o=void 0);else{let a=i;if("additionalProperties"in i&&i.additionalProperties===!1){let{additionalProperties:s,...c}=i;a=c}else o=void 0;r.push(a)}}),r.length?{allOf:r,...o}:void 0}function My(e,t){let n=typeof e.value;return n!=="bigint"&&n!=="number"&&n!=="boolean"&&n!=="string"?{type:Array.isArray(e.value)?"array":"object"}:t.target==="openApi3"?{type:n==="bigint"?"integer":n,enum:[e.value]}:{type:n==="bigint"?"integer":n,const:e.value}}var Gp,Pt={cuid:/^[cC][^\s-]{8,}$/,cuid2:/^[0-9a-z]+$/,ulid:/^[0-9A-HJKMNP-TV-Z]{26}$/,email:/^(?!\.)(?!.*\.\.)([a-zA-Z0-9_'+\-\.]*)[a-zA-Z0-9_+-]@([a-zA-Z0-9][a-zA-Z0-9\-]*\.)+[a-zA-Z]{2,}$/,emoji:()=>(Gp===void 0&&(Gp=RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u")),Gp),uuid:/^[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}$/,ipv4:/^(?:(?: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])$/,ipv4Cidr:/^(?:(?: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])$/,ipv6:/^(([a-f0-9]{1,4}:){7}|::([a-f0-9]{1,4}:){0,6}|([a-f0-9]{1,4}:){1}:([a-f0-9]{1,4}:){0,5}|([a-f0-9]{1,4}:){2}:([a-f0-9]{1,4}:){0,4}|([a-f0-9]{1,4}:){3}:([a-f0-9]{1,4}:){0,3}|([a-f0-9]{1,4}:){4}:([a-f0-9]{1,4}:){0,2}|([a-f0-9]{1,4}:){5}:([a-f0-9]{1,4}:){0,1})([a-f0-9]{1,4}|(((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))\.){3}((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2})))$/,ipv6Cidr:/^(([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])$/,base64:/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,base64url:/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,nanoid:/^[a-zA-Z0-9_-]{21}$/,jwt:/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/};function rl(e,t){let n={type:"string"};if(e.checks)for(let o of e.checks)switch(o.kind){case"min":ue(n,"minLength",typeof n.minLength=="number"?Math.max(n.minLength,o.value):o.value,o.message,t);break;case"max":ue(n,"maxLength",typeof n.maxLength=="number"?Math.min(n.maxLength,o.value):o.value,o.message,t);break;case"email":switch(t.emailStrategy){case"format:email":Ot(n,"email",o.message,t);break;case"format:idn-email":Ot(n,"idn-email",o.message,t);break;case"pattern:zod":We(n,Pt.email,o.message,t);break}break;case"url":Ot(n,"uri",o.message,t);break;case"uuid":Ot(n,"uuid",o.message,t);break;case"regex":We(n,o.regex,o.message,t);break;case"cuid":We(n,Pt.cuid,o.message,t);break;case"cuid2":We(n,Pt.cuid2,o.message,t);break;case"startsWith":We(n,RegExp(`^${Wp(o.value,t)}`),o.message,t);break;case"endsWith":We(n,RegExp(`${Wp(o.value,t)}$`),o.message,t);break;case"datetime":Ot(n,"date-time",o.message,t);break;case"date":Ot(n,"date",o.message,t);break;case"time":Ot(n,"time",o.message,t);break;case"duration":Ot(n,"duration",o.message,t);break;case"length":ue(n,"minLength",typeof n.minLength=="number"?Math.max(n.minLength,o.value):o.value,o.message,t),ue(n,"maxLength",typeof n.maxLength=="number"?Math.min(n.maxLength,o.value):o.value,o.message,t);break;case"includes":{We(n,RegExp(Wp(o.value,t)),o.message,t);break}case"ip":{o.version!=="v6"&&Ot(n,"ipv4",o.message,t),o.version!=="v4"&&Ot(n,"ipv6",o.message,t);break}case"base64url":We(n,Pt.base64url,o.message,t);break;case"jwt":We(n,Pt.jwt,o.message,t);break;case"cidr":{o.version!=="v6"&&We(n,Pt.ipv4Cidr,o.message,t),o.version!=="v4"&&We(n,Pt.ipv6Cidr,o.message,t);break}case"emoji":We(n,Pt.emoji(),o.message,t);break;case"ulid":{We(n,Pt.ulid,o.message,t);break}case"base64":{switch(t.base64Strategy){case"format:binary":{Ot(n,"binary",o.message,t);break}case"contentEncoding:base64":{ue(n,"contentEncoding","base64",o.message,t);break}case"pattern:zod":{We(n,Pt.base64,o.message,t);break}}break}case"nanoid":We(n,Pt.nanoid,o.message,t);case"toLowerCase":case"toUpperCase":case"trim":break;default:}return n}function Wp(e,t){return t.patternStrategy==="escape"?RP(e):e}var NP=new Set("ABCDEFGHIJKLMNOPQRSTUVXYZabcdefghijklmnopqrstuvxyz0123456789");function RP(e){let t="";for(let n=0;n<e.length;n++)NP.has(e[n])||(t+="\\"),t+=e[n];return t}function Ot(e,t,n,o){e.format||e.anyOf?.some(r=>r.format)?(e.anyOf||(e.anyOf=[]),e.format&&(e.anyOf.push({format:e.format,...e.errorMessage&&o.errorMessages&&{errorMessage:{format:e.errorMessage.format}}}),delete e.format,e.errorMessage&&(delete e.errorMessage.format,Object.keys(e.errorMessage).length===0&&delete e.errorMessage)),e.anyOf.push({format:t,...n&&o.errorMessages&&{errorMessage:{format:n}}})):ue(e,"format",t,n,o)}function We(e,t,n,o){e.pattern||e.allOf?.some(r=>r.pattern)?(e.allOf||(e.allOf=[]),e.pattern&&(e.allOf.push({pattern:e.pattern,...e.errorMessage&&o.errorMessages&&{errorMessage:{pattern:e.errorMessage.pattern}}}),delete e.pattern,e.errorMessage&&(delete e.errorMessage.pattern,Object.keys(e.errorMessage).length===0&&delete e.errorMessage)),e.allOf.push({pattern:Ly(t,o),...n&&o.errorMessages&&{errorMessage:{pattern:n}}})):ue(e,"pattern",Ly(t,o),n,o)}function Ly(e,t){if(!t.applyRegexFlags||!e.flags)return e.source;let n={i:e.flags.includes("i"),m:e.flags.includes("m"),s:e.flags.includes("s")},o=n.i?e.source.toLowerCase():e.source,r="",i=!1,a=!1,s=!1;for(let c=0;c<o.length;c++){if(i){r+=o[c],i=!1;continue}if(n.i){if(a){if(o[c].match(/[a-z]/)){s?(r+=o[c],r+=`${o[c-2]}-${o[c]}`.toUpperCase(),s=!1):o[c+1]==="-"&&o[c+2]?.match(/[a-z]/)?(r+=o[c],s=!0):r+=`${o[c]}${o[c].toUpperCase()}`;continue}}else if(o[c].match(/[a-z]/)){r+=`[${o[c]}${o[c].toUpperCase()}]`;continue}}if(n.m){if(o[c]==="^"){r+=`(^|(?<=[\r
|
|
56
|
+
Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`)}for(let d of this.seen.entries()){let f=d[1];if(t===d[0]){a(d);continue}if(o.external){let v=o.external.registry.get(d[0])?.id;if(t!==d[0]&&v){a(d);continue}}if(this.metadataRegistry.get(d[0])?.id){a(d);continue}if(f.cycle){a(d);continue}if(f.count>1&&o.reused==="ref"){a(d);continue}}let s=(d,f)=>{let _=this.seen.get(d),v=_.def??_.schema,g={...v};if(_.ref===null)return;let b=_.ref;if(_.ref=null,b){s(b,f);let x=this.seen.get(b).schema;x.$ref&&(f.target==="draft-7"||f.target==="draft-4"||f.target==="openapi-3.0")?(v.allOf=v.allOf??[],v.allOf.push(x)):(Object.assign(v,x),Object.assign(v,g))}_.isParent||this.override({zodSchema:d,jsonSchema:v,path:_.path??[]})};for(let d of[...this.seen.entries()].reverse())s(d[0],{target:this.target});let c={};if(this.target==="draft-2020-12"?c.$schema="https://json-schema.org/draft/2020-12/schema":this.target==="draft-7"?c.$schema="http://json-schema.org/draft-07/schema#":this.target==="draft-4"?c.$schema="http://json-schema.org/draft-04/schema#":this.target==="openapi-3.0"||console.warn(`Invalid target: ${this.target}`),o.external?.uri){let d=o.external.registry.get(t)?.id;if(!d)throw new Error("Schema is missing an `id` property");c.$id=o.external.uri(d)}Object.assign(c,r.def);let l=o.external?.defs??{};for(let d of this.seen.entries()){let f=d[1];f.def&&f.defId&&(l[f.defId]=f.def)}o.external||Object.keys(l).length>0&&(this.target==="draft-2020-12"?c.$defs=l:c.definitions=l);try{return JSON.parse(JSON.stringify(c))}catch{throw new Error("Error converting schema to JSON.")}}};function so(e,t){if(e instanceof Kn){let o=new Ci(t),r={};for(let s of e._idmap.entries()){let[c,l]=s;o.process(l)}let i={},a={registry:e,uri:t?.uri,defs:r};for(let s of e._idmap.entries()){let[c,l]=s;i[c]=o.emit(l,{...t,external:a})}if(Object.keys(r).length>0){let s=o.target==="draft-2020-12"?"$defs":"definitions";i.__shared={[s]:r}}return{schemas:i}}let n=new Ci(t);return n.process(e),n.emit(e,t)}function je(e,t){let n=t??{seen:new Set};if(n.seen.has(e))return!1;n.seen.add(e);let r=e._zod.def;switch(r.type){case"string":case"number":case"bigint":case"boolean":case"date":case"symbol":case"undefined":case"null":case"any":case"unknown":case"never":case"void":case"literal":case"enum":case"nan":case"file":case"template_literal":return!1;case"array":return je(r.element,n);case"object":{for(let i in r.shape)if(je(r.shape[i],n))return!0;return!1}case"union":{for(let i of r.options)if(je(i,n))return!0;return!1}case"intersection":return je(r.left,n)||je(r.right,n);case"tuple":{for(let i of r.items)if(je(i,n))return!0;return!!(r.rest&&je(r.rest,n))}case"record":return je(r.keyType,n)||je(r.valueType,n);case"map":return je(r.keyType,n)||je(r.valueType,n);case"set":return je(r.valueType,n);case"promise":case"optional":case"nonoptional":case"nullable":case"readonly":return je(r.innerType,n);case"lazy":return je(r.getter(),n);case"default":return je(r.innerType,n);case"prefault":return je(r.innerType,n);case"custom":return!1;case"transform":return!0;case"pipe":return je(r.in,n)||je(r.out,n);case"success":return!1;case"catch":return!1;case"function":return!1;default:}throw new Error(`Unknown schema type: ${r.type}`)}var k_={};var HI=$("ZodMiniType",(e,t)=>{if(!e._zod)throw new Error("Uninitialized schema in ZodMiniType.");W.init(e,t),e.def=t,e.type=t.type,e.parse=(n,o)=>Jr(e,n,o,{callee:e.parse}),e.safeParse=(n,o)=>xr(e,n,o),e.parseAsync=async(n,o)=>Gr(e,n,o,{callee:e.parseAsync}),e.safeParseAsync=async(n,o)=>wr(e,n,o),e.check=(...n)=>e.clone({...t,checks:[...t.checks??[],...n.map(o=>typeof o=="function"?{_zod:{check:o,def:{check:"custom"},onattach:[]}}:o)]}),e.clone=(n,o)=>Ne(e,n,o),e.brand=()=>e,e.register=((n,o)=>(n.add(e,o),e))});var JI=$("ZodMiniObject",(e,t)=>{rc.init(e,t),HI.init(e,t),E.defineLazy(e,"shape",()=>t.shape)});function Mf(e,t){let n={type:"object",get shape(){return E.assignProp(this,"shape",{...e}),this.shape},...E.normalizeParams(t)};return new JI(n)}function vt(e){return!!e._zod}function tn(e){let t=Object.values(e);if(t.length===0)return Mf({});let n=t.every(vt),o=t.every(r=>!vt(r));if(n)return Mf(e);if(o)return Xg(e);throw new Error("Mixed Zod versions detected in object shape.")}function Ir(e,t){return vt(e)?xr(e,t):e.safeParse(t)}async function _u(e,t){return vt(e)?await wr(e,t):await e.safeParseAsync(t)}function Er(e){if(!e)return;let t;if(vt(e)?t=e._zod?.def?.shape:t=e.shape,!!t){if(typeof t=="function")try{return t()}catch{return}return t}}function co(e){if(e){if(typeof e=="object"){let t=e,n=e;if(!t._def&&!n._zod){let o=Object.values(e);if(o.length>0&&o.every(r=>typeof r=="object"&&r!==null&&(r._def!==void 0||r._zod!==void 0||typeof r.parse=="function")))return tn(e)}}if(vt(e)){let n=e._zod?.def;if(n&&(n.type==="object"||n.shape!==void 0))return e}else if(e.shape!==void 0)return e}}function yu(e){if(e&&typeof e=="object"){if("message"in e&&typeof e.message=="string")return e.message;if("issues"in e&&Array.isArray(e.issues)&&e.issues.length>0){let t=e.issues[0];if(t&&typeof t=="object"&&"message"in t)return String(t.message)}try{return JSON.stringify(e)}catch{return String(e)}}return String(e)}function I_(e){return e.description}function E_(e){if(vt(e))return e._zod?.def?.type==="optional";let t=e;return typeof e.isOptional=="function"?e.isOptional():t._def?.typeName==="ZodOptional"}function bu(e){if(vt(e)){let i=e._zod?.def;if(i){if(i.value!==void 0)return i.value;if(Array.isArray(i.values)&&i.values.length>0)return i.values[0]}}let n=e._def;if(n){if(n.value!==void 0)return n.value;if(Array.isArray(n.values)&&n.values.length>0)return n.values[0]}let o=e.value;if(o!==void 0)return o}var qt={};Fr(qt,{$brand:()=>Qo,$input:()=>Pc,$output:()=>Oc,NEVER:()=>es,TimePrecision:()=>Rc,ZodAny:()=>R_,ZodArray:()=>U_,ZodBase64:()=>vp,ZodBase64URL:()=>_p,ZodBigInt:()=>Vi,ZodBigIntFormat:()=>$p,ZodBoolean:()=>qi,ZodCIDRv4:()=>hp,ZodCIDRv6:()=>gp,ZodCUID:()=>cp,ZodCUID2:()=>up,ZodCatch:()=>ty,ZodCodec:()=>Ep,ZodCustom:()=>ju,ZodCustomStringFormat:()=>Mi,ZodDate:()=>Tu,ZodDefault:()=>G_,ZodDiscriminatedUnion:()=>Z_,ZodE164:()=>yp,ZodEmail:()=>ip,ZodEmoji:()=>ap,ZodEnum:()=>Ui,ZodError:()=>QI,ZodFile:()=>K_,ZodFirstPartyTypeKind:()=>Op,ZodFunction:()=>ly,ZodGUID:()=>Su,ZodIPv4:()=>pp,ZodIPv6:()=>mp,ZodISODate:()=>xu,ZodISODateTime:()=>$u,ZodISODuration:()=>ku,ZodISOTime:()=>wu,ZodIntersection:()=>M_,ZodIssueCode:()=>oT,ZodJWT:()=>bp,ZodKSUID:()=>fp,ZodLazy:()=>sy,ZodLiteral:()=>B_,ZodMap:()=>V_,ZodNaN:()=>ny,ZodNanoID:()=>sp,ZodNever:()=>D_,ZodNonOptional:()=>zp,ZodNull:()=>N_,ZodNullable:()=>J_,ZodNumber:()=>Li,ZodNumberFormat:()=>lo,ZodObject:()=>Ou,ZodOptional:()=>Ki,ZodPipe:()=>Ip,ZodPrefault:()=>X_,ZodPromise:()=>uy,ZodReadonly:()=>oy,ZodRealError:()=>nt,ZodRecord:()=>kp,ZodSet:()=>F_,ZodString:()=>Zi,ZodStringFormat:()=>xe,ZodSuccess:()=>ey,ZodSymbol:()=>P_,ZodTemplateLiteral:()=>ay,ZodTransform:()=>H_,ZodTuple:()=>L_,ZodType:()=>te,ZodULID:()=>lp,ZodURL:()=>Eu,ZodUUID:()=>rr,ZodUndefined:()=>j_,ZodUnion:()=>wp,ZodUnknown:()=>A_,ZodVoid:()=>C_,ZodXID:()=>dp,_ZodString:()=>op,_default:()=>W_,_function:()=>QE,any:()=>CE,array:()=>ie,base64:()=>bE,base64url:()=>$E,bigint:()=>jE,boolean:()=>Oe,catch:()=>ry,check:()=>eT,cidrv4:()=>_E,cidrv6:()=>yE,clone:()=>Ne,codec:()=>WE,coerce:()=>Pp,config:()=>Ee,core:()=>pt,cuid:()=>dE,cuid2:()=>fE,custom:()=>Tp,date:()=>ZE,decode:()=>Wf,decodeAsync:()=>Yf,discriminatedUnion:()=>Pu,e164:()=>xE,email:()=>tE,emoji:()=>uE,encode:()=>Gf,encodeAsync:()=>Xf,endsWith:()=>to,enum:()=>Be,file:()=>KE,flattenError:()=>Dn,float32:()=>EE,float64:()=>TE,formatError:()=>Cn,function:()=>QE,getErrorMap:()=>aT,globalRegistry:()=>Tt,gt:()=>Mt,gte:()=>Ve,guid:()=>rE,hash:()=>IE,hex:()=>zE,hostname:()=>SE,httpUrl:()=>cE,includes:()=>Qn,instanceof:()=>tT,int:()=>np,int32:()=>OE,int64:()=>NE,intersection:()=>Bi,ipv4:()=>gE,ipv6:()=>vE,iso:()=>uo,json:()=>nT,jwt:()=>wE,keyof:()=>ME,ksuid:()=>hE,lazy:()=>cy,length:()=>Qr,literal:()=>B,locales:()=>Bn,looseObject:()=>Fe,lowercase:()=>Xn,lt:()=>Zt,lte:()=>rt,map:()=>VE,maxLength:()=>Yr,maxSize:()=>Xr,mime:()=>ro,minLength:()=>tr,minSize:()=>zr,multipleOf:()=>Sr,nan:()=>GE,nanoid:()=>lE,nativeEnum:()=>BE,negative:()=>uu,never:()=>xp,nonnegative:()=>du,nonoptional:()=>Q_,nonpositive:()=>lu,normalize:()=>no,null:()=>Fi,nullable:()=>zu,nullish:()=>HE,number:()=>he,object:()=>Z,optional:()=>ke,overwrite:()=>Lt,parse:()=>Bf,parseAsync:()=>Kf,partialRecord:()=>qE,pipe:()=>Iu,positive:()=>cu,prefault:()=>Y_,preprocess:()=>Nu,prettifyError:()=>os,promise:()=>YE,property:()=>fu,readonly:()=>iy,record:()=>we,refine:()=>dy,regex:()=>Wn,regexes:()=>tt,registry:()=>gi,safeDecode:()=>ep,safeDecodeAsync:()=>rp,safeEncode:()=>Qf,safeEncodeAsync:()=>tp,safeParse:()=>Hf,safeParseAsync:()=>Jf,set:()=>FE,setErrorMap:()=>iT,size:()=>Gn,startsWith:()=>eo,strictObject:()=>LE,string:()=>k,stringFormat:()=>kE,stringbool:()=>rT,success:()=>JE,superRefine:()=>fy,symbol:()=>AE,templateLiteral:()=>XE,toJSONSchema:()=>so,toLowerCase:()=>io,toUpperCase:()=>ao,transform:()=>Sp,treeifyError:()=>ns,trim:()=>oo,tuple:()=>q_,uint32:()=>PE,uint64:()=>RE,ulid:()=>pE,undefined:()=>DE,union:()=>ve,unknown:()=>ye,uppercase:()=>Yn,url:()=>sE,util:()=>E,uuid:()=>nE,uuidv4:()=>oE,uuidv6:()=>iE,uuidv7:()=>aE,void:()=>UE,xid:()=>mE});var uo={};Fr(uo,{ZodISODate:()=>xu,ZodISODateTime:()=>$u,ZodISODuration:()=>ku,ZodISOTime:()=>wu,date:()=>qf,datetime:()=>Lf,duration:()=>Ff,time:()=>Vf});var $u=$("ZodISODateTime",(e,t)=>{js.init(e,t),xe.init(e,t)});function Lf(e){return Ac($u,e)}var xu=$("ZodISODate",(e,t)=>{Ns.init(e,t),xe.init(e,t)});function qf(e){return Dc(xu,e)}var wu=$("ZodISOTime",(e,t)=>{Rs.init(e,t),xe.init(e,t)});function Vf(e){return Cc(wu,e)}var ku=$("ZodISODuration",(e,t)=>{As.init(e,t),xe.init(e,t)});function Ff(e){return Uc(ku,e)}var O_=(e,t)=>{ai.init(e,t),e.name="ZodError",Object.defineProperties(e,{format:{value:n=>Cn(e,n)},flatten:{value:n=>Dn(e,n)},addIssue:{value:n=>{e.issues.push(n),e.message=JSON.stringify(e.issues,Nn,2)}},addIssues:{value:n=>{e.issues.push(...n),e.message=JSON.stringify(e.issues,Nn,2)}},isEmpty:{get(){return e.issues.length===0}}})},QI=$("ZodError",O_),nt=$("ZodError",O_,{Parent:Error});var Bf=Un(nt),Kf=Zn(nt),Hf=Mn(nt),Jf=Ln(nt),Gf=is(nt),Wf=as(nt),Xf=ss(nt),Yf=cs(nt),Qf=us(nt),ep=ls(nt),tp=ds(nt),rp=fs(nt);var te=$("ZodType",(e,t)=>(W.init(e,t),e.def=t,e.type=t.type,Object.defineProperty(e,"_def",{value:t}),e.check=(...n)=>e.clone({...t,checks:[...t.checks??[],...n.map(o=>typeof o=="function"?{_zod:{check:o,def:{check:"custom"},onattach:[]}}:o)]}),e.clone=(n,o)=>Ne(e,n,o),e.brand=()=>e,e.register=((n,o)=>(n.add(e,o),e)),e.parse=(n,o)=>Bf(e,n,o,{callee:e.parse}),e.safeParse=(n,o)=>Hf(e,n,o),e.parseAsync=async(n,o)=>Kf(e,n,o,{callee:e.parseAsync}),e.safeParseAsync=async(n,o)=>Jf(e,n,o),e.spa=e.safeParseAsync,e.encode=(n,o)=>Gf(e,n,o),e.decode=(n,o)=>Wf(e,n,o),e.encodeAsync=async(n,o)=>Xf(e,n,o),e.decodeAsync=async(n,o)=>Yf(e,n,o),e.safeEncode=(n,o)=>Qf(e,n,o),e.safeDecode=(n,o)=>ep(e,n,o),e.safeEncodeAsync=async(n,o)=>tp(e,n,o),e.safeDecodeAsync=async(n,o)=>rp(e,n,o),e.refine=(n,o)=>e.check(dy(n,o)),e.superRefine=n=>e.check(fy(n)),e.overwrite=n=>e.check(Lt(n)),e.optional=()=>ke(e),e.nullable=()=>zu(e),e.nullish=()=>ke(zu(e)),e.nonoptional=n=>Q_(e,n),e.array=()=>ie(e),e.or=n=>ve([e,n]),e.and=n=>Bi(e,n),e.transform=n=>Iu(e,Sp(n)),e.default=n=>W_(e,n),e.prefault=n=>Y_(e,n),e.catch=n=>ry(e,n),e.pipe=n=>Iu(e,n),e.readonly=()=>iy(e),e.describe=n=>{let o=e.clone();return Tt.add(o,{description:n}),o},Object.defineProperty(e,"description",{get(){return Tt.get(e)?.description},configurable:!0}),e.meta=(...n)=>{if(n.length===0)return Tt.get(e);let o=e.clone();return Tt.add(o,n[0]),o},e.isOptional=()=>e.safeParse(void 0).success,e.isNullable=()=>e.safeParse(null).success,e)),op=$("_ZodString",(e,t)=>{kr.init(e,t),te.init(e,t);let n=e._zod.bag;e.format=n.format??null,e.minLength=n.minimum??null,e.maxLength=n.maximum??null,e.regex=(...o)=>e.check(Wn(...o)),e.includes=(...o)=>e.check(Qn(...o)),e.startsWith=(...o)=>e.check(eo(...o)),e.endsWith=(...o)=>e.check(to(...o)),e.min=(...o)=>e.check(tr(...o)),e.max=(...o)=>e.check(Yr(...o)),e.length=(...o)=>e.check(Qr(...o)),e.nonempty=(...o)=>e.check(tr(1,...o)),e.lowercase=o=>e.check(Xn(o)),e.uppercase=o=>e.check(Yn(o)),e.trim=()=>e.check(oo()),e.normalize=(...o)=>e.check(no(...o)),e.toLowerCase=()=>e.check(io()),e.toUpperCase=()=>e.check(ao())}),Zi=$("ZodString",(e,t)=>{kr.init(e,t),op.init(e,t),e.email=n=>e.check(vi(ip,n)),e.url=n=>e.check(Jn(Eu,n)),e.jwt=n=>e.check(Di(bp,n)),e.emoji=n=>e.check(xi(ap,n)),e.guid=n=>e.check(Hn(Su,n)),e.uuid=n=>e.check(_i(rr,n)),e.uuidv4=n=>e.check(yi(rr,n)),e.uuidv6=n=>e.check(bi(rr,n)),e.uuidv7=n=>e.check($i(rr,n)),e.nanoid=n=>e.check(wi(sp,n)),e.guid=n=>e.check(Hn(Su,n)),e.cuid=n=>e.check(ki(cp,n)),e.cuid2=n=>e.check(Si(up,n)),e.ulid=n=>e.check(zi(lp,n)),e.base64=n=>e.check(Ni(vp,n)),e.base64url=n=>e.check(Ri(_p,n)),e.xid=n=>e.check(Ii(dp,n)),e.ksuid=n=>e.check(Ei(fp,n)),e.ipv4=n=>e.check(Ti(pp,n)),e.ipv6=n=>e.check(Oi(mp,n)),e.cidrv4=n=>e.check(Pi(hp,n)),e.cidrv6=n=>e.check(ji(gp,n)),e.e164=n=>e.check(Ai(yp,n)),e.datetime=n=>e.check(Lf(n)),e.date=n=>e.check(qf(n)),e.time=n=>e.check(Vf(n)),e.duration=n=>e.check(Ff(n))});function k(e){return jc(Zi,e)}var xe=$("ZodStringFormat",(e,t)=>{ge.init(e,t),op.init(e,t)}),ip=$("ZodEmail",(e,t)=>{ws.init(e,t),xe.init(e,t)});function tE(e){return vi(ip,e)}var Su=$("ZodGUID",(e,t)=>{$s.init(e,t),xe.init(e,t)});function rE(e){return Hn(Su,e)}var rr=$("ZodUUID",(e,t)=>{xs.init(e,t),xe.init(e,t)});function nE(e){return _i(rr,e)}function oE(e){return yi(rr,e)}function iE(e){return bi(rr,e)}function aE(e){return $i(rr,e)}var Eu=$("ZodURL",(e,t)=>{ks.init(e,t),xe.init(e,t)});function sE(e){return Jn(Eu,e)}function cE(e){return Jn(Eu,{protocol:/^https?$/,hostname:tt.domain,...E.normalizeParams(e)})}var ap=$("ZodEmoji",(e,t)=>{Ss.init(e,t),xe.init(e,t)});function uE(e){return xi(ap,e)}var sp=$("ZodNanoID",(e,t)=>{zs.init(e,t),xe.init(e,t)});function lE(e){return wi(sp,e)}var cp=$("ZodCUID",(e,t)=>{Is.init(e,t),xe.init(e,t)});function dE(e){return ki(cp,e)}var up=$("ZodCUID2",(e,t)=>{Es.init(e,t),xe.init(e,t)});function fE(e){return Si(up,e)}var lp=$("ZodULID",(e,t)=>{Ts.init(e,t),xe.init(e,t)});function pE(e){return zi(lp,e)}var dp=$("ZodXID",(e,t)=>{Os.init(e,t),xe.init(e,t)});function mE(e){return Ii(dp,e)}var fp=$("ZodKSUID",(e,t)=>{Ps.init(e,t),xe.init(e,t)});function hE(e){return Ei(fp,e)}var pp=$("ZodIPv4",(e,t)=>{Ds.init(e,t),xe.init(e,t)});function gE(e){return Ti(pp,e)}var mp=$("ZodIPv6",(e,t)=>{Cs.init(e,t),xe.init(e,t)});function vE(e){return Oi(mp,e)}var hp=$("ZodCIDRv4",(e,t)=>{Us.init(e,t),xe.init(e,t)});function _E(e){return Pi(hp,e)}var gp=$("ZodCIDRv6",(e,t)=>{Zs.init(e,t),xe.init(e,t)});function yE(e){return ji(gp,e)}var vp=$("ZodBase64",(e,t)=>{Ms.init(e,t),xe.init(e,t)});function bE(e){return Ni(vp,e)}var _p=$("ZodBase64URL",(e,t)=>{Ls.init(e,t),xe.init(e,t)});function $E(e){return Ri(_p,e)}var yp=$("ZodE164",(e,t)=>{qs.init(e,t),xe.init(e,t)});function xE(e){return Ai(yp,e)}var bp=$("ZodJWT",(e,t)=>{Vs.init(e,t),xe.init(e,t)});function wE(e){return Di(bp,e)}var Mi=$("ZodCustomStringFormat",(e,t)=>{Fs.init(e,t),xe.init(e,t)});function kE(e,t,n={}){return en(Mi,e,t,n)}function SE(e){return en(Mi,"hostname",tt.hostname,e)}function zE(e){return en(Mi,"hex",tt.hex,e)}function IE(e,t){let n=t?.enc??"hex",o=`${e}_${n}`,r=tt[o];if(!r)throw new Error(`Unrecognized hash format: ${o}`);return en(Mi,o,r,t)}var Li=$("ZodNumber",(e,t)=>{li.init(e,t),te.init(e,t),e.gt=(o,r)=>e.check(Mt(o,r)),e.gte=(o,r)=>e.check(Ve(o,r)),e.min=(o,r)=>e.check(Ve(o,r)),e.lt=(o,r)=>e.check(Zt(o,r)),e.lte=(o,r)=>e.check(rt(o,r)),e.max=(o,r)=>e.check(rt(o,r)),e.int=o=>e.check(np(o)),e.safe=o=>e.check(np(o)),e.positive=o=>e.check(Mt(0,o)),e.nonnegative=o=>e.check(Ve(0,o)),e.negative=o=>e.check(Zt(0,o)),e.nonpositive=o=>e.check(rt(0,o)),e.multipleOf=(o,r)=>e.check(Sr(o,r)),e.step=(o,r)=>e.check(Sr(o,r)),e.finite=()=>e;let n=e._zod.bag;e.minValue=Math.max(n.minimum??Number.NEGATIVE_INFINITY,n.exclusiveMinimum??Number.NEGATIVE_INFINITY)??null,e.maxValue=Math.min(n.maximum??Number.POSITIVE_INFINITY,n.exclusiveMaximum??Number.POSITIVE_INFINITY)??null,e.isInt=(n.format??"").includes("int")||Number.isSafeInteger(n.multipleOf??.5),e.isFinite=!0,e.format=n.format??null});function he(e){return Zc(Li,e)}var lo=$("ZodNumberFormat",(e,t)=>{Bs.init(e,t),Li.init(e,t)});function np(e){return Lc(lo,e)}function EE(e){return qc(lo,e)}function TE(e){return Vc(lo,e)}function OE(e){return Fc(lo,e)}function PE(e){return Bc(lo,e)}var qi=$("ZodBoolean",(e,t)=>{Vn.init(e,t),te.init(e,t)});function Oe(e){return Kc(qi,e)}var Vi=$("ZodBigInt",(e,t)=>{di.init(e,t),te.init(e,t),e.gte=(o,r)=>e.check(Ve(o,r)),e.min=(o,r)=>e.check(Ve(o,r)),e.gt=(o,r)=>e.check(Mt(o,r)),e.gte=(o,r)=>e.check(Ve(o,r)),e.min=(o,r)=>e.check(Ve(o,r)),e.lt=(o,r)=>e.check(Zt(o,r)),e.lte=(o,r)=>e.check(rt(o,r)),e.max=(o,r)=>e.check(rt(o,r)),e.positive=o=>e.check(Mt(BigInt(0),o)),e.negative=o=>e.check(Zt(BigInt(0),o)),e.nonpositive=o=>e.check(rt(BigInt(0),o)),e.nonnegative=o=>e.check(Ve(BigInt(0),o)),e.multipleOf=(o,r)=>e.check(Sr(o,r));let n=e._zod.bag;e.minValue=n.minimum??null,e.maxValue=n.maximum??null,e.format=n.format??null});function jE(e){return Jc(Vi,e)}var $p=$("ZodBigIntFormat",(e,t)=>{Ks.init(e,t),Vi.init(e,t)});function NE(e){return Wc($p,e)}function RE(e){return Xc($p,e)}var P_=$("ZodSymbol",(e,t)=>{Hs.init(e,t),te.init(e,t)});function AE(e){return Yc(P_,e)}var j_=$("ZodUndefined",(e,t)=>{Js.init(e,t),te.init(e,t)});function DE(e){return Qc(j_,e)}var N_=$("ZodNull",(e,t)=>{Gs.init(e,t),te.init(e,t)});function Fi(e){return eu(N_,e)}var R_=$("ZodAny",(e,t)=>{Ws.init(e,t),te.init(e,t)});function CE(){return tu(R_)}var A_=$("ZodUnknown",(e,t)=>{Xs.init(e,t),te.init(e,t)});function ye(){return ru(A_)}var D_=$("ZodNever",(e,t)=>{Ys.init(e,t),te.init(e,t)});function xp(e){return nu(D_,e)}var C_=$("ZodVoid",(e,t)=>{Qs.init(e,t),te.init(e,t)});function UE(e){return ou(C_,e)}var Tu=$("ZodDate",(e,t)=>{ec.init(e,t),te.init(e,t),e.min=(o,r)=>e.check(Ve(o,r)),e.max=(o,r)=>e.check(rt(o,r));let n=e._zod.bag;e.minDate=n.minimum?new Date(n.minimum):null,e.maxDate=n.maximum?new Date(n.maximum):null});function ZE(e){return iu(Tu,e)}var U_=$("ZodArray",(e,t)=>{tc.init(e,t),te.init(e,t),e.element=t.element,e.min=(n,o)=>e.check(tr(n,o)),e.nonempty=n=>e.check(tr(1,n)),e.max=(n,o)=>e.check(Yr(n,o)),e.length=(n,o)=>e.check(Qr(n,o)),e.unwrap=()=>e.element});function ie(e,t){return Zf(U_,e,t)}function ME(e){let t=e._zod.def.shape;return Be(Object.keys(t))}var Ou=$("ZodObject",(e,t)=>{Uf.init(e,t),te.init(e,t),E.defineLazy(e,"shape",()=>t.shape),e.keyof=()=>Be(Object.keys(e._zod.def.shape)),e.catchall=n=>e.clone({...e._zod.def,catchall:n}),e.passthrough=()=>e.clone({...e._zod.def,catchall:ye()}),e.loose=()=>e.clone({...e._zod.def,catchall:ye()}),e.strict=()=>e.clone({...e._zod.def,catchall:xp()}),e.strip=()=>e.clone({...e._zod.def,catchall:void 0}),e.extend=n=>E.extend(e,n),e.safeExtend=n=>E.safeExtend(e,n),e.merge=n=>E.merge(e,n),e.pick=n=>E.pick(e,n),e.omit=n=>E.omit(e,n),e.partial=(...n)=>E.partial(Ki,e,n[0]),e.required=(...n)=>E.required(zp,e,n[0])});function Z(e,t){let n={type:"object",get shape(){return E.assignProp(this,"shape",e?E.objectClone(e):{}),this.shape},...E.normalizeParams(t)};return new Ou(n)}function LE(e,t){return new Ou({type:"object",get shape(){return E.assignProp(this,"shape",E.objectClone(e)),this.shape},catchall:xp(),...E.normalizeParams(t)})}function Fe(e,t){return new Ou({type:"object",get shape(){return E.assignProp(this,"shape",E.objectClone(e)),this.shape},catchall:ye(),...E.normalizeParams(t)})}var wp=$("ZodUnion",(e,t)=>{fi.init(e,t),te.init(e,t),e.options=t.options});function ve(e,t){return new wp({type:"union",options:e,...E.normalizeParams(t)})}var Z_=$("ZodDiscriminatedUnion",(e,t)=>{wp.init(e,t),nc.init(e,t)});function Pu(e,t,n){return new Z_({type:"union",options:t,discriminator:e,...E.normalizeParams(n)})}var M_=$("ZodIntersection",(e,t)=>{oc.init(e,t),te.init(e,t)});function Bi(e,t){return new M_({type:"intersection",left:e,right:t})}var L_=$("ZodTuple",(e,t)=>{pi.init(e,t),te.init(e,t),e.rest=n=>e.clone({...e._zod.def,rest:n})});function q_(e,t,n){let o=t instanceof W,r=o?n:t,i=o?t:null;return new L_({type:"tuple",items:e,rest:i,...E.normalizeParams(r)})}var kp=$("ZodRecord",(e,t)=>{ic.init(e,t),te.init(e,t),e.keyType=t.keyType,e.valueType=t.valueType});function we(e,t,n){return new kp({type:"record",keyType:e,valueType:t,...E.normalizeParams(n)})}function qE(e,t,n){let o=Ne(e);return o._zod.values=void 0,new kp({type:"record",keyType:o,valueType:t,...E.normalizeParams(n)})}var V_=$("ZodMap",(e,t)=>{ac.init(e,t),te.init(e,t),e.keyType=t.keyType,e.valueType=t.valueType});function VE(e,t,n){return new V_({type:"map",keyType:e,valueType:t,...E.normalizeParams(n)})}var F_=$("ZodSet",(e,t)=>{sc.init(e,t),te.init(e,t),e.min=(...n)=>e.check(zr(...n)),e.nonempty=n=>e.check(zr(1,n)),e.max=(...n)=>e.check(Xr(...n)),e.size=(...n)=>e.check(Gn(...n))});function FE(e,t){return new F_({type:"set",valueType:e,...E.normalizeParams(t)})}var Ui=$("ZodEnum",(e,t)=>{cc.init(e,t),te.init(e,t),e.enum=t.entries,e.options=Object.values(t.entries);let n=new Set(Object.keys(t.entries));e.extract=(o,r)=>{let i={};for(let a of o)if(n.has(a))i[a]=t.entries[a];else throw new Error(`Key ${a} not found in enum`);return new Ui({...t,checks:[],...E.normalizeParams(r),entries:i})},e.exclude=(o,r)=>{let i={...t.entries};for(let a of o)if(n.has(a))delete i[a];else throw new Error(`Key ${a} not found in enum`);return new Ui({...t,checks:[],...E.normalizeParams(r),entries:i})}});function Be(e,t){let n=Array.isArray(e)?Object.fromEntries(e.map(o=>[o,o])):e;return new Ui({type:"enum",entries:n,...E.normalizeParams(t)})}function BE(e,t){return new Ui({type:"enum",entries:e,...E.normalizeParams(t)})}var B_=$("ZodLiteral",(e,t)=>{uc.init(e,t),te.init(e,t),e.values=new Set(t.values),Object.defineProperty(e,"value",{get(){if(t.values.length>1)throw new Error("This schema contains multiple valid literal values. Use `.values` instead.");return t.values[0]}})});function B(e,t){return new B_({type:"literal",values:Array.isArray(e)?e:[e],...E.normalizeParams(t)})}var K_=$("ZodFile",(e,t)=>{lc.init(e,t),te.init(e,t),e.min=(n,o)=>e.check(zr(n,o)),e.max=(n,o)=>e.check(Xr(n,o)),e.mime=(n,o)=>e.check(ro(Array.isArray(n)?n:[n],o))});function KE(e){return pu(K_,e)}var H_=$("ZodTransform",(e,t)=>{dc.init(e,t),te.init(e,t),e._zod.parse=(n,o)=>{if(o.direction==="backward")throw new gr(e.constructor.name);n.addIssue=i=>{if(typeof i=="string")n.issues.push(E.issue(i,n.value,t));else{let a=i;a.fatal&&(a.continue=!1),a.code??(a.code="custom"),a.input??(a.input=n.value),a.inst??(a.inst=e),n.issues.push(E.issue(a))}};let r=t.transform(n.value,n);return r instanceof Promise?r.then(i=>(n.value=i,n)):(n.value=r,n)}});function Sp(e){return new H_({type:"transform",transform:e})}var Ki=$("ZodOptional",(e,t)=>{fc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function ke(e){return new Ki({type:"optional",innerType:e})}var J_=$("ZodNullable",(e,t)=>{pc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function zu(e){return new J_({type:"nullable",innerType:e})}function HE(e){return ke(zu(e))}var G_=$("ZodDefault",(e,t)=>{mc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});function W_(e,t){return new G_({type:"default",innerType:e,get defaultValue(){return typeof t=="function"?t():E.shallowClone(t)}})}var X_=$("ZodPrefault",(e,t)=>{hc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function Y_(e,t){return new X_({type:"prefault",innerType:e,get defaultValue(){return typeof t=="function"?t():E.shallowClone(t)}})}var zp=$("ZodNonOptional",(e,t)=>{gc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function Q_(e,t){return new zp({type:"nonoptional",innerType:e,...E.normalizeParams(t)})}var ey=$("ZodSuccess",(e,t)=>{vc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function JE(e){return new ey({type:"success",innerType:e})}var ty=$("ZodCatch",(e,t)=>{_c.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});function ry(e,t){return new ty({type:"catch",innerType:e,catchValue:typeof t=="function"?t:()=>t})}var ny=$("ZodNaN",(e,t)=>{yc.init(e,t),te.init(e,t)});function GE(e){return su(ny,e)}var Ip=$("ZodPipe",(e,t)=>{bc.init(e,t),te.init(e,t),e.in=t.in,e.out=t.out});function Iu(e,t){return new Ip({type:"pipe",in:e,out:t})}var Ep=$("ZodCodec",(e,t)=>{Ip.init(e,t),Fn.init(e,t)});function WE(e,t,n){return new Ep({type:"pipe",in:e,out:t,transform:n.decode,reverseTransform:n.encode})}var oy=$("ZodReadonly",(e,t)=>{$c.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function iy(e){return new oy({type:"readonly",innerType:e})}var ay=$("ZodTemplateLiteral",(e,t)=>{xc.init(e,t),te.init(e,t)});function XE(e,t){return new ay({type:"template_literal",parts:e,...E.normalizeParams(t)})}var sy=$("ZodLazy",(e,t)=>{Sc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.getter()});function cy(e){return new sy({type:"lazy",getter:e})}var uy=$("ZodPromise",(e,t)=>{kc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function YE(e){return new uy({type:"promise",innerType:e})}var ly=$("ZodFunction",(e,t)=>{wc.init(e,t),te.init(e,t)});function QE(e){return new ly({type:"function",input:Array.isArray(e?.input)?q_(e?.input):e?.input??ie(ye()),output:e?.output??ye()})}var ju=$("ZodCustom",(e,t)=>{zc.init(e,t),te.init(e,t)});function eT(e){let t=new $e({check:"custom"});return t._zod.check=e,t}function Tp(e,t){return mu(ju,e??(()=>!0),t)}function dy(e,t={}){return hu(ju,e,t)}function fy(e){return gu(e)}function tT(e,t={error:`Input not instance of ${e.name}`}){let n=new ju({type:"custom",check:"custom",fn:o=>o instanceof e,abort:!0,...E.normalizeParams(t)});return n._zod.bag.Class=e,n}var rT=(...e)=>vu({Codec:Ep,Boolean:qi,String:Zi},...e);function nT(e){let t=cy(()=>ve([k(e),he(),Oe(),Fi(),ie(t),we(k(),t)]));return t}function Nu(e,t){return Iu(Sp(e),t)}var oT={invalid_type:"invalid_type",too_big:"too_big",too_small:"too_small",invalid_format:"invalid_format",not_multiple_of:"not_multiple_of",unrecognized_keys:"unrecognized_keys",invalid_union:"invalid_union",invalid_key:"invalid_key",invalid_element:"invalid_element",invalid_value:"invalid_value",custom:"custom"};function iT(e){Ee({customError:e})}function aT(){return Ee().customError}var Op;Op||(Op={});var Pp={};Fr(Pp,{bigint:()=>lT,boolean:()=>uT,date:()=>dT,number:()=>cT,string:()=>sT});function sT(e){return Nc(Zi,e)}function cT(e){return Mc(Li,e)}function uT(e){return Hc(qi,e)}function lT(e){return Gc(Vi,e)}function dT(e){return au(Tu,e)}Ee(Ic());var Np="2025-11-25";var py=[Np,"2025-06-18","2025-03-26","2024-11-05","2024-10-07"],Tr="io.modelcontextprotocol/related-task",Au="2.0",Ae=Tp(e=>e!==null&&(typeof e=="object"||typeof e=="function")),my=ve([k(),he().int()]),hy=k(),h6=Fe({ttl:ve([he(),Fi()]).optional(),pollInterval:he().optional()}),pT=Z({ttl:he().optional()}),mT=Z({taskId:k()}),Rp=Fe({progressToken:my.optional(),[Tr]:mT.optional()}),mt=Z({_meta:Rp.optional()}),Hi=mt.extend({task:pT.optional()}),gy=e=>Hi.safeParse(e).success,De=Z({method:k(),params:mt.loose().optional()}),_t=Z({_meta:Rp.optional()}),yt=Z({method:k(),params:_t.loose().optional()}),Ce=Fe({_meta:Rp.optional()}),Du=ve([k(),he().int()]),vy=Z({jsonrpc:B(Au),id:Du,...De.shape}).strict(),Ap=e=>vy.safeParse(e).success,_y=Z({jsonrpc:B(Au),...yt.shape}).strict(),yy=e=>_y.safeParse(e).success,Dp=Z({jsonrpc:B(Au),id:Du,result:Ce}).strict(),Ji=e=>Dp.safeParse(e).success;var H;(function(e){e[e.ConnectionClosed=-32e3]="ConnectionClosed",e[e.RequestTimeout=-32001]="RequestTimeout",e[e.ParseError=-32700]="ParseError",e[e.InvalidRequest=-32600]="InvalidRequest",e[e.MethodNotFound=-32601]="MethodNotFound",e[e.InvalidParams=-32602]="InvalidParams",e[e.InternalError=-32603]="InternalError",e[e.UrlElicitationRequired=-32042]="UrlElicitationRequired"})(H||(H={}));var Cp=Z({jsonrpc:B(Au),id:Du.optional(),error:Z({code:he().int(),message:k(),data:ye().optional()})}).strict();var by=e=>Cp.safeParse(e).success;var $y=ve([vy,_y,Dp,Cp]),g6=ve([Dp,Cp]),Cu=Ce.strict(),hT=_t.extend({requestId:Du.optional(),reason:k().optional()}),Uu=yt.extend({method:B("notifications/cancelled"),params:hT}),gT=Z({src:k(),mimeType:k().optional(),sizes:ie(k()).optional(),theme:Be(["light","dark"]).optional()}),Gi=Z({icons:ie(gT).optional()}),fo=Z({name:k(),title:k().optional()}),xy=fo.extend({...fo.shape,...Gi.shape,version:k(),websiteUrl:k().optional(),description:k().optional()}),vT=Bi(Z({applyDefaults:Oe().optional()}),we(k(),ye())),_T=Nu(e=>e&&typeof e=="object"&&!Array.isArray(e)&&Object.keys(e).length===0?{form:{}}:e,Bi(Z({form:vT.optional(),url:Ae.optional()}),we(k(),ye()).optional())),yT=Fe({list:Ae.optional(),cancel:Ae.optional(),requests:Fe({sampling:Fe({createMessage:Ae.optional()}).optional(),elicitation:Fe({create:Ae.optional()}).optional()}).optional()}),bT=Fe({list:Ae.optional(),cancel:Ae.optional(),requests:Fe({tools:Fe({call:Ae.optional()}).optional()}).optional()}),$T=Z({experimental:we(k(),Ae).optional(),sampling:Z({context:Ae.optional(),tools:Ae.optional()}).optional(),elicitation:_T.optional(),roots:Z({listChanged:Oe().optional()}).optional(),tasks:yT.optional()}),xT=mt.extend({protocolVersion:k(),capabilities:$T,clientInfo:xy}),Up=De.extend({method:B("initialize"),params:xT});var wT=Z({experimental:we(k(),Ae).optional(),logging:Ae.optional(),completions:Ae.optional(),prompts:Z({listChanged:Oe().optional()}).optional(),resources:Z({subscribe:Oe().optional(),listChanged:Oe().optional()}).optional(),tools:Z({listChanged:Oe().optional()}).optional(),tasks:bT.optional()}),kT=Ce.extend({protocolVersion:k(),capabilities:wT,serverInfo:xy,instructions:k().optional()}),Zp=yt.extend({method:B("notifications/initialized"),params:_t.optional()});var Zu=De.extend({method:B("ping"),params:mt.optional()}),ST=Z({progress:he(),total:ke(he()),message:ke(k())}),zT=Z({..._t.shape,...ST.shape,progressToken:my}),Mu=yt.extend({method:B("notifications/progress"),params:zT}),IT=mt.extend({cursor:hy.optional()}),Wi=De.extend({params:IT.optional()}),Xi=Ce.extend({nextCursor:hy.optional()}),ET=Be(["working","input_required","completed","failed","cancelled"]),Yi=Z({taskId:k(),status:ET,ttl:ve([he(),Fi()]),createdAt:k(),lastUpdatedAt:k(),pollInterval:ke(he()),statusMessage:ke(k())}),po=Ce.extend({task:Yi}),TT=_t.merge(Yi),Qi=yt.extend({method:B("notifications/tasks/status"),params:TT}),Lu=De.extend({method:B("tasks/get"),params:mt.extend({taskId:k()})}),qu=Ce.merge(Yi),Vu=De.extend({method:B("tasks/result"),params:mt.extend({taskId:k()})}),v6=Ce.loose(),Fu=Wi.extend({method:B("tasks/list")}),Bu=Xi.extend({tasks:ie(Yi)}),Ku=De.extend({method:B("tasks/cancel"),params:mt.extend({taskId:k()})}),wy=Ce.merge(Yi),ky=Z({uri:k(),mimeType:ke(k()),_meta:we(k(),ye()).optional()}),Sy=ky.extend({text:k()}),Mp=k().refine(e=>{try{return atob(e),!0}catch{return!1}},{message:"Invalid Base64 string"}),zy=ky.extend({blob:Mp}),ea=Be(["user","assistant"]),mo=Z({audience:ie(ea).optional(),priority:he().min(0).max(1).optional(),lastModified:uo.datetime({offset:!0}).optional()}),Iy=Z({...fo.shape,...Gi.shape,uri:k(),description:ke(k()),mimeType:ke(k()),annotations:mo.optional(),_meta:ke(Fe({}))}),OT=Z({...fo.shape,...Gi.shape,uriTemplate:k(),description:ke(k()),mimeType:ke(k()),annotations:mo.optional(),_meta:ke(Fe({}))}),Hu=Wi.extend({method:B("resources/list")}),PT=Xi.extend({resources:ie(Iy)}),Ju=Wi.extend({method:B("resources/templates/list")}),jT=Xi.extend({resourceTemplates:ie(OT)}),Lp=mt.extend({uri:k()}),NT=Lp,Gu=De.extend({method:B("resources/read"),params:NT}),RT=Ce.extend({contents:ie(ve([Sy,zy]))}),AT=yt.extend({method:B("notifications/resources/list_changed"),params:_t.optional()}),DT=Lp,CT=De.extend({method:B("resources/subscribe"),params:DT}),UT=Lp,ZT=De.extend({method:B("resources/unsubscribe"),params:UT}),MT=_t.extend({uri:k()}),LT=yt.extend({method:B("notifications/resources/updated"),params:MT}),qT=Z({name:k(),description:ke(k()),required:ke(Oe())}),VT=Z({...fo.shape,...Gi.shape,description:ke(k()),arguments:ke(ie(qT)),_meta:ke(Fe({}))}),Wu=Wi.extend({method:B("prompts/list")}),FT=Xi.extend({prompts:ie(VT)}),BT=mt.extend({name:k(),arguments:we(k(),k()).optional()}),Xu=De.extend({method:B("prompts/get"),params:BT}),qp=Z({type:B("text"),text:k(),annotations:mo.optional(),_meta:we(k(),ye()).optional()}),Vp=Z({type:B("image"),data:Mp,mimeType:k(),annotations:mo.optional(),_meta:we(k(),ye()).optional()}),Fp=Z({type:B("audio"),data:Mp,mimeType:k(),annotations:mo.optional(),_meta:we(k(),ye()).optional()}),KT=Z({type:B("tool_use"),name:k(),id:k(),input:we(k(),ye()),_meta:we(k(),ye()).optional()}),HT=Z({type:B("resource"),resource:ve([Sy,zy]),annotations:mo.optional(),_meta:we(k(),ye()).optional()}),JT=Iy.extend({type:B("resource_link")}),Bp=ve([qp,Vp,Fp,JT,HT]),GT=Z({role:ea,content:Bp}),WT=Ce.extend({description:k().optional(),messages:ie(GT)}),XT=yt.extend({method:B("notifications/prompts/list_changed"),params:_t.optional()}),YT=Z({title:k().optional(),readOnlyHint:Oe().optional(),destructiveHint:Oe().optional(),idempotentHint:Oe().optional(),openWorldHint:Oe().optional()}),QT=Z({taskSupport:Be(["required","optional","forbidden"]).optional()}),Ey=Z({...fo.shape,...Gi.shape,description:k().optional(),inputSchema:Z({type:B("object"),properties:we(k(),Ae).optional(),required:ie(k()).optional()}).catchall(ye()),outputSchema:Z({type:B("object"),properties:we(k(),Ae).optional(),required:ie(k()).optional()}).catchall(ye()).optional(),annotations:YT.optional(),execution:QT.optional(),_meta:we(k(),ye()).optional()}),Yu=Wi.extend({method:B("tools/list")}),eO=Xi.extend({tools:ie(Ey)}),Qu=Ce.extend({content:ie(Bp).default([]),structuredContent:we(k(),ye()).optional(),isError:Oe().optional()}),_6=Qu.or(Ce.extend({toolResult:ye()})),tO=Hi.extend({name:k(),arguments:we(k(),ye()).optional()}),ho=De.extend({method:B("tools/call"),params:tO}),rO=yt.extend({method:B("notifications/tools/list_changed"),params:_t.optional()}),y6=Z({autoRefresh:Oe().default(!0),debounceMs:he().int().nonnegative().default(300)}),ta=Be(["debug","info","notice","warning","error","critical","alert","emergency"]),nO=mt.extend({level:ta}),Kp=De.extend({method:B("logging/setLevel"),params:nO}),oO=_t.extend({level:ta,logger:k().optional(),data:ye()}),iO=yt.extend({method:B("notifications/message"),params:oO}),aO=Z({name:k().optional()}),sO=Z({hints:ie(aO).optional(),costPriority:he().min(0).max(1).optional(),speedPriority:he().min(0).max(1).optional(),intelligencePriority:he().min(0).max(1).optional()}),cO=Z({mode:Be(["auto","required","none"]).optional()}),uO=Z({type:B("tool_result"),toolUseId:k().describe("The unique identifier for the corresponding tool call."),content:ie(Bp).default([]),structuredContent:Z({}).loose().optional(),isError:Oe().optional(),_meta:we(k(),ye()).optional()}),lO=Pu("type",[qp,Vp,Fp]),Ru=Pu("type",[qp,Vp,Fp,KT,uO]),dO=Z({role:ea,content:ve([Ru,ie(Ru)]),_meta:we(k(),ye()).optional()}),fO=Hi.extend({messages:ie(dO),modelPreferences:sO.optional(),systemPrompt:k().optional(),includeContext:Be(["none","thisServer","allServers"]).optional(),temperature:he().optional(),maxTokens:he().int(),stopSequences:ie(k()).optional(),metadata:Ae.optional(),tools:ie(Ey).optional(),toolChoice:cO.optional()}),pO=De.extend({method:B("sampling/createMessage"),params:fO}),ra=Ce.extend({model:k(),stopReason:ke(Be(["endTurn","stopSequence","maxTokens"]).or(k())),role:ea,content:lO}),Hp=Ce.extend({model:k(),stopReason:ke(Be(["endTurn","stopSequence","maxTokens","toolUse"]).or(k())),role:ea,content:ve([Ru,ie(Ru)])}),mO=Z({type:B("boolean"),title:k().optional(),description:k().optional(),default:Oe().optional()}),hO=Z({type:B("string"),title:k().optional(),description:k().optional(),minLength:he().optional(),maxLength:he().optional(),format:Be(["email","uri","date","date-time"]).optional(),default:k().optional()}),gO=Z({type:Be(["number","integer"]),title:k().optional(),description:k().optional(),minimum:he().optional(),maximum:he().optional(),default:he().optional()}),vO=Z({type:B("string"),title:k().optional(),description:k().optional(),enum:ie(k()),default:k().optional()}),_O=Z({type:B("string"),title:k().optional(),description:k().optional(),oneOf:ie(Z({const:k(),title:k()})),default:k().optional()}),yO=Z({type:B("string"),title:k().optional(),description:k().optional(),enum:ie(k()),enumNames:ie(k()).optional(),default:k().optional()}),bO=ve([vO,_O]),$O=Z({type:B("array"),title:k().optional(),description:k().optional(),minItems:he().optional(),maxItems:he().optional(),items:Z({type:B("string"),enum:ie(k())}),default:ie(k()).optional()}),xO=Z({type:B("array"),title:k().optional(),description:k().optional(),minItems:he().optional(),maxItems:he().optional(),items:Z({anyOf:ie(Z({const:k(),title:k()}))}),default:ie(k()).optional()}),wO=ve([$O,xO]),kO=ve([yO,bO,wO]),SO=ve([kO,mO,hO,gO]),zO=Hi.extend({mode:B("form").optional(),message:k(),requestedSchema:Z({type:B("object"),properties:we(k(),SO),required:ie(k()).optional()})}),IO=Hi.extend({mode:B("url"),message:k(),elicitationId:k(),url:k().url()}),EO=ve([zO,IO]),TO=De.extend({method:B("elicitation/create"),params:EO}),OO=_t.extend({elicitationId:k()}),PO=yt.extend({method:B("notifications/elicitation/complete"),params:OO}),go=Ce.extend({action:Be(["accept","decline","cancel"]),content:Nu(e=>e===null?void 0:e,we(k(),ve([k(),he(),Oe(),ie(k())])).optional())}),jO=Z({type:B("ref/resource"),uri:k()});var NO=Z({type:B("ref/prompt"),name:k()}),RO=mt.extend({ref:ve([NO,jO]),argument:Z({name:k(),value:k()}),context:Z({arguments:we(k(),k()).optional()}).optional()}),el=De.extend({method:B("completion/complete"),params:RO});function Ty(e){if(e.params.ref.type!=="ref/prompt")throw new TypeError(`Expected CompleteRequestPrompt, but got ${e.params.ref.type}`)}function Oy(e){if(e.params.ref.type!=="ref/resource")throw new TypeError(`Expected CompleteRequestResourceTemplate, but got ${e.params.ref.type}`)}var AO=Ce.extend({completion:Fe({values:ie(k()).max(100),total:ke(he().int()),hasMore:ke(Oe())})}),DO=Z({uri:k().startsWith("file://"),name:k().optional(),_meta:we(k(),ye()).optional()}),CO=De.extend({method:B("roots/list"),params:mt.optional()}),Jp=Ce.extend({roots:ie(DO)}),UO=yt.extend({method:B("notifications/roots/list_changed"),params:_t.optional()}),b6=ve([Zu,Up,el,Kp,Xu,Wu,Hu,Ju,Gu,CT,ZT,ho,Yu,Lu,Vu,Fu,Ku]),$6=ve([Uu,Mu,Zp,UO,Qi]),x6=ve([Cu,ra,Hp,go,Jp,qu,Bu,po]),w6=ve([Zu,pO,TO,CO,Lu,Vu,Fu,Ku]),k6=ve([Uu,Mu,iO,LT,AT,rO,XT,Qi,PO]),S6=ve([Cu,kT,AO,WT,FT,PT,jT,RT,Qu,eO,qu,Bu,po]),F=class e extends Error{constructor(t,n,o){super(`MCP error ${t}: ${n}`),this.code=t,this.data=o,this.name="McpError"}static fromError(t,n,o){if(t===H.UrlElicitationRequired&&o){let r=o;if(r.elicitations)return new jp(r.elicitations,n)}return new e(t,n,o)}},jp=class extends F{constructor(t,n=`URL elicitation${t.length>1?"s":""} required`){super(H.UrlElicitationRequired,n,{elicitations:t})}get elicitations(){return this.data?.elicitations??[]}};function Or(e){return e==="completed"||e==="failed"||e==="cancelled"}var jy=Symbol("Let zodToJsonSchema decide on which parser to use");var Py={name:void 0,$refStrategy:"root",basePath:["#"],effectStrategy:"input",pipeStrategy:"all",dateStrategy:"format:date-time",mapStrategy:"entries",removeAdditionalStrategy:"passthrough",allowedAdditionalProperties:!0,rejectedAdditionalProperties:!1,definitionPath:"definitions",target:"jsonSchema7",strictUnions:!1,definitions:{},errorMessages:!1,markdownDescription:!1,patternStrategy:"escape",applyRegexFlags:!1,emailStrategy:"format:email",base64Strategy:"contentEncoding:base64",nameStrategy:"ref",openAiAnyTypeName:"OpenAiAnyType"},Ny=e=>typeof e=="string"?{...Py,name:e}:{...Py,...e};var Ry=e=>{let t=Ny(e),n=t.name!==void 0?[...t.basePath,t.definitionPath,t.name]:t.basePath;return{...t,flags:{hasReferencedOpenAiAnyType:!1},currentPath:n,propertyPath:void 0,seen:new Map(Object.entries(t.definitions).map(([o,r])=>[r._def,{def:r._def,path:[...t.basePath,t.definitionPath,o],jsonSchema:void 0}]))}};function Gp(e,t,n,o){o?.errorMessages&&n&&(e.errorMessage={...e.errorMessage,[t]:n})}function ue(e,t,n,o,r){e[t]=n,Gp(e,t,o,r)}var tl=(e,t)=>{let n=0;for(;n<e.length&&n<t.length&&e[n]===t[n];n++);return[(e.length-n).toString(),...t.slice(n)].join("/")};function Ie(e){if(e.target!=="openAi")return{};let t=[...e.basePath,e.definitionPath,e.openAiAnyTypeName];return e.flags.hasReferencedOpenAiAnyType=!0,{$ref:e.$refStrategy==="relative"?tl(t,e.currentPath):t.join("/")}}function Ay(e,t){let n={type:"array"};return e.type?._def&&e.type?._def?.typeName!==P.ZodAny&&(n.items=G(e.type._def,{...t,currentPath:[...t.currentPath,"items"]})),e.minLength&&ue(n,"minItems",e.minLength.value,e.minLength.message,t),e.maxLength&&ue(n,"maxItems",e.maxLength.value,e.maxLength.message,t),e.exactLength&&(ue(n,"minItems",e.exactLength.value,e.exactLength.message,t),ue(n,"maxItems",e.exactLength.value,e.exactLength.message,t)),n}function Dy(e,t){let n={type:"integer",format:"int64"};if(!e.checks)return n;for(let o of e.checks)switch(o.kind){case"min":t.target==="jsonSchema7"?o.inclusive?ue(n,"minimum",o.value,o.message,t):ue(n,"exclusiveMinimum",o.value,o.message,t):(o.inclusive||(n.exclusiveMinimum=!0),ue(n,"minimum",o.value,o.message,t));break;case"max":t.target==="jsonSchema7"?o.inclusive?ue(n,"maximum",o.value,o.message,t):ue(n,"exclusiveMaximum",o.value,o.message,t):(o.inclusive||(n.exclusiveMaximum=!0),ue(n,"maximum",o.value,o.message,t));break;case"multipleOf":ue(n,"multipleOf",o.value,o.message,t);break}return n}function Cy(){return{type:"boolean"}}function rl(e,t){return G(e.type._def,t)}var Uy=(e,t)=>G(e.innerType._def,t);function Wp(e,t,n){let o=n??t.dateStrategy;if(Array.isArray(o))return{anyOf:o.map((r,i)=>Wp(e,t,r))};switch(o){case"string":case"format:date-time":return{type:"string",format:"date-time"};case"format:date":return{type:"string",format:"date"};case"integer":return ZO(e,t)}}var ZO=(e,t)=>{let n={type:"integer",format:"unix-time"};if(t.target==="openApi3")return n;for(let o of e.checks)switch(o.kind){case"min":ue(n,"minimum",o.value,o.message,t);break;case"max":ue(n,"maximum",o.value,o.message,t);break}return n};function Zy(e,t){return{...G(e.innerType._def,t),default:e.defaultValue()}}function My(e,t){return t.effectStrategy==="input"?G(e.schema._def,t):Ie(t)}function Ly(e){return{type:"string",enum:Array.from(e.values)}}var MO=e=>"type"in e&&e.type==="string"?!1:"allOf"in e;function qy(e,t){let n=[G(e.left._def,{...t,currentPath:[...t.currentPath,"allOf","0"]}),G(e.right._def,{...t,currentPath:[...t.currentPath,"allOf","1"]})].filter(i=>!!i),o=t.target==="jsonSchema2019-09"?{unevaluatedProperties:!1}:void 0,r=[];return n.forEach(i=>{if(MO(i))r.push(...i.allOf),i.unevaluatedProperties===void 0&&(o=void 0);else{let a=i;if("additionalProperties"in i&&i.additionalProperties===!1){let{additionalProperties:s,...c}=i;a=c}else o=void 0;r.push(a)}}),r.length?{allOf:r,...o}:void 0}function Vy(e,t){let n=typeof e.value;return n!=="bigint"&&n!=="number"&&n!=="boolean"&&n!=="string"?{type:Array.isArray(e.value)?"array":"object"}:t.target==="openApi3"?{type:n==="bigint"?"integer":n,enum:[e.value]}:{type:n==="bigint"?"integer":n,const:e.value}}var Xp,Ot={cuid:/^[cC][^\s-]{8,}$/,cuid2:/^[0-9a-z]+$/,ulid:/^[0-9A-HJKMNP-TV-Z]{26}$/,email:/^(?!\.)(?!.*\.\.)([a-zA-Z0-9_'+\-\.]*)[a-zA-Z0-9_+-]@([a-zA-Z0-9][a-zA-Z0-9\-]*\.)+[a-zA-Z]{2,}$/,emoji:()=>(Xp===void 0&&(Xp=RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u")),Xp),uuid:/^[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}$/,ipv4:/^(?:(?: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])$/,ipv4Cidr:/^(?:(?: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])$/,ipv6:/^(([a-f0-9]{1,4}:){7}|::([a-f0-9]{1,4}:){0,6}|([a-f0-9]{1,4}:){1}:([a-f0-9]{1,4}:){0,5}|([a-f0-9]{1,4}:){2}:([a-f0-9]{1,4}:){0,4}|([a-f0-9]{1,4}:){3}:([a-f0-9]{1,4}:){0,3}|([a-f0-9]{1,4}:){4}:([a-f0-9]{1,4}:){0,2}|([a-f0-9]{1,4}:){5}:([a-f0-9]{1,4}:){0,1})([a-f0-9]{1,4}|(((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))\.){3}((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2})))$/,ipv6Cidr:/^(([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])$/,base64:/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,base64url:/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,nanoid:/^[a-zA-Z0-9_-]{21}$/,jwt:/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/};function nl(e,t){let n={type:"string"};if(e.checks)for(let o of e.checks)switch(o.kind){case"min":ue(n,"minLength",typeof n.minLength=="number"?Math.max(n.minLength,o.value):o.value,o.message,t);break;case"max":ue(n,"maxLength",typeof n.maxLength=="number"?Math.min(n.maxLength,o.value):o.value,o.message,t);break;case"email":switch(t.emailStrategy){case"format:email":Pt(n,"email",o.message,t);break;case"format:idn-email":Pt(n,"idn-email",o.message,t);break;case"pattern:zod":We(n,Ot.email,o.message,t);break}break;case"url":Pt(n,"uri",o.message,t);break;case"uuid":Pt(n,"uuid",o.message,t);break;case"regex":We(n,o.regex,o.message,t);break;case"cuid":We(n,Ot.cuid,o.message,t);break;case"cuid2":We(n,Ot.cuid2,o.message,t);break;case"startsWith":We(n,RegExp(`^${Yp(o.value,t)}`),o.message,t);break;case"endsWith":We(n,RegExp(`${Yp(o.value,t)}$`),o.message,t);break;case"datetime":Pt(n,"date-time",o.message,t);break;case"date":Pt(n,"date",o.message,t);break;case"time":Pt(n,"time",o.message,t);break;case"duration":Pt(n,"duration",o.message,t);break;case"length":ue(n,"minLength",typeof n.minLength=="number"?Math.max(n.minLength,o.value):o.value,o.message,t),ue(n,"maxLength",typeof n.maxLength=="number"?Math.min(n.maxLength,o.value):o.value,o.message,t);break;case"includes":{We(n,RegExp(Yp(o.value,t)),o.message,t);break}case"ip":{o.version!=="v6"&&Pt(n,"ipv4",o.message,t),o.version!=="v4"&&Pt(n,"ipv6",o.message,t);break}case"base64url":We(n,Ot.base64url,o.message,t);break;case"jwt":We(n,Ot.jwt,o.message,t);break;case"cidr":{o.version!=="v6"&&We(n,Ot.ipv4Cidr,o.message,t),o.version!=="v4"&&We(n,Ot.ipv6Cidr,o.message,t);break}case"emoji":We(n,Ot.emoji(),o.message,t);break;case"ulid":{We(n,Ot.ulid,o.message,t);break}case"base64":{switch(t.base64Strategy){case"format:binary":{Pt(n,"binary",o.message,t);break}case"contentEncoding:base64":{ue(n,"contentEncoding","base64",o.message,t);break}case"pattern:zod":{We(n,Ot.base64,o.message,t);break}}break}case"nanoid":We(n,Ot.nanoid,o.message,t);case"toLowerCase":case"toUpperCase":case"trim":break;default:}return n}function Yp(e,t){return t.patternStrategy==="escape"?qO(e):e}var LO=new Set("ABCDEFGHIJKLMNOPQRSTUVXYZabcdefghijklmnopqrstuvxyz0123456789");function qO(e){let t="";for(let n=0;n<e.length;n++)LO.has(e[n])||(t+="\\"),t+=e[n];return t}function Pt(e,t,n,o){e.format||e.anyOf?.some(r=>r.format)?(e.anyOf||(e.anyOf=[]),e.format&&(e.anyOf.push({format:e.format,...e.errorMessage&&o.errorMessages&&{errorMessage:{format:e.errorMessage.format}}}),delete e.format,e.errorMessage&&(delete e.errorMessage.format,Object.keys(e.errorMessage).length===0&&delete e.errorMessage)),e.anyOf.push({format:t,...n&&o.errorMessages&&{errorMessage:{format:n}}})):ue(e,"format",t,n,o)}function We(e,t,n,o){e.pattern||e.allOf?.some(r=>r.pattern)?(e.allOf||(e.allOf=[]),e.pattern&&(e.allOf.push({pattern:e.pattern,...e.errorMessage&&o.errorMessages&&{errorMessage:{pattern:e.errorMessage.pattern}}}),delete e.pattern,e.errorMessage&&(delete e.errorMessage.pattern,Object.keys(e.errorMessage).length===0&&delete e.errorMessage)),e.allOf.push({pattern:Fy(t,o),...n&&o.errorMessages&&{errorMessage:{pattern:n}}})):ue(e,"pattern",Fy(t,o),n,o)}function Fy(e,t){if(!t.applyRegexFlags||!e.flags)return e.source;let n={i:e.flags.includes("i"),m:e.flags.includes("m"),s:e.flags.includes("s")},o=n.i?e.source.toLowerCase():e.source,r="",i=!1,a=!1,s=!1;for(let c=0;c<o.length;c++){if(i){r+=o[c],i=!1;continue}if(n.i){if(a){if(o[c].match(/[a-z]/)){s?(r+=o[c],r+=`${o[c-2]}-${o[c]}`.toUpperCase(),s=!1):o[c+1]==="-"&&o[c+2]?.match(/[a-z]/)?(r+=o[c],s=!0):r+=`${o[c]}${o[c].toUpperCase()}`;continue}}else if(o[c].match(/[a-z]/)){r+=`[${o[c]}${o[c].toUpperCase()}]`;continue}}if(n.m){if(o[c]==="^"){r+=`(^|(?<=[\r
|
|
57
57
|
]))`;continue}else if(o[c]==="$"){r+=`($|(?=[\r
|
|
58
58
|
]))`;continue}}if(n.s&&o[c]==="."){r+=a?`${o[c]}\r
|
|
59
59
|
`:`[${o[c]}\r
|
|
60
|
-
]`;continue}r+=o[c],o[c]==="\\"?i=!0:a&&o[c]==="]"?a=!1:!a&&o[c]==="["&&(a=!0)}try{new RegExp(r)}catch{return console.warn(`Could not convert regex pattern at ${t.currentPath.join("/")} to a flag-independent form! Falling back to the flag-ignorant source`),e.source}return r}function nl(e,t){if(t.target==="openAi"&&console.warn("Warning: OpenAI may not support records in schemas! Try an array of key-value pairs instead."),t.target==="openApi3"&&e.keyType?._def.typeName===O.ZodEnum)return{type:"object",required:e.keyType._def.values,properties:e.keyType._def.values.reduce((o,r)=>({...o,[r]:G(e.valueType._def,{...t,currentPath:[...t.currentPath,"properties",r]})??Ie(t)}),{}),additionalProperties:t.rejectedAdditionalProperties};let n={type:"object",additionalProperties:G(e.valueType._def,{...t,currentPath:[...t.currentPath,"additionalProperties"]})??t.allowedAdditionalProperties};if(t.target==="openApi3")return n;if(e.keyType?._def.typeName===O.ZodString&&e.keyType._def.checks?.length){let{type:o,...r}=rl(e.keyType._def,t);return{...n,propertyNames:r}}else{if(e.keyType?._def.typeName===O.ZodEnum)return{...n,propertyNames:{enum:e.keyType._def.values}};if(e.keyType?._def.typeName===O.ZodBranded&&e.keyType._def.type._def.typeName===O.ZodString&&e.keyType._def.type._def.checks?.length){let{type:o,...r}=tl(e.keyType._def,t);return{...n,propertyNames:r}}}return n}function qy(e,t){if(t.mapStrategy==="record")return nl(e,t);let n=G(e.keyType._def,{...t,currentPath:[...t.currentPath,"items","items","0"]})||Ie(t),o=G(e.valueType._def,{...t,currentPath:[...t.currentPath,"items","items","1"]})||Ie(t);return{type:"array",maxItems:125,items:{type:"array",items:[n,o],minItems:2,maxItems:2}}}function Vy(e){let t=e.values,o=Object.keys(e.values).filter(i=>typeof t[t[i]]!="number").map(i=>t[i]),r=Array.from(new Set(o.map(i=>typeof i)));return{type:r.length===1?r[0]==="string"?"string":"number":["string","number"],enum:o}}function Fy(e){return e.target==="openAi"?void 0:{not:Ie({...e,currentPath:[...e.currentPath,"not"]})}}function By(e){return e.target==="openApi3"?{enum:["null"],nullable:!0}:{type:"null"}}var na={ZodString:"string",ZodNumber:"number",ZodBigInt:"integer",ZodBoolean:"boolean",ZodNull:"null"};function Hy(e,t){if(t.target==="openApi3")return Ky(e,t);let n=e.options instanceof Map?Array.from(e.options.values()):e.options;if(n.every(o=>o._def.typeName in na&&(!o._def.checks||!o._def.checks.length))){let o=n.reduce((r,i)=>{let a=na[i._def.typeName];return a&&!r.includes(a)?[...r,a]:r},[]);return{type:o.length>1?o:o[0]}}else if(n.every(o=>o._def.typeName==="ZodLiteral"&&!o.description)){let o=n.reduce((r,i)=>{let a=typeof i._def.value;switch(a){case"string":case"number":case"boolean":return[...r,a];case"bigint":return[...r,"integer"];case"object":if(i._def.value===null)return[...r,"null"];default:return r}},[]);if(o.length===n.length){let r=o.filter((i,a,s)=>s.indexOf(i)===a);return{type:r.length>1?r:r[0],enum:n.reduce((i,a)=>i.includes(a._def.value)?i:[...i,a._def.value],[])}}}else if(n.every(o=>o._def.typeName==="ZodEnum"))return{type:"string",enum:n.reduce((o,r)=>[...o,...r._def.values.filter(i=>!o.includes(i))],[])};return Ky(e,t)}var Ky=(e,t)=>{let n=(e.options instanceof Map?Array.from(e.options.values()):e.options).map((o,r)=>G(o._def,{...t,currentPath:[...t.currentPath,"anyOf",`${r}`]})).filter(o=>!!o&&(!t.strictUnions||typeof o=="object"&&Object.keys(o).length>0));return n.length?{anyOf:n}:void 0};function Jy(e,t){if(["ZodString","ZodNumber","ZodBigInt","ZodBoolean","ZodNull"].includes(e.innerType._def.typeName)&&(!e.innerType._def.checks||!e.innerType._def.checks.length))return t.target==="openApi3"?{type:na[e.innerType._def.typeName],nullable:!0}:{type:[na[e.innerType._def.typeName],"null"]};if(t.target==="openApi3"){let o=G(e.innerType._def,{...t,currentPath:[...t.currentPath]});return o&&"$ref"in o?{allOf:[o],nullable:!0}:o&&{...o,nullable:!0}}let n=G(e.innerType._def,{...t,currentPath:[...t.currentPath,"anyOf","0"]});return n&&{anyOf:[n,{type:"null"}]}}function Gy(e,t){let n={type:"number"};if(!e.checks)return n;for(let o of e.checks)switch(o.kind){case"int":n.type="integer",Hp(n,"type",o.message,t);break;case"min":t.target==="jsonSchema7"?o.inclusive?ue(n,"minimum",o.value,o.message,t):ue(n,"exclusiveMinimum",o.value,o.message,t):(o.inclusive||(n.exclusiveMinimum=!0),ue(n,"minimum",o.value,o.message,t));break;case"max":t.target==="jsonSchema7"?o.inclusive?ue(n,"maximum",o.value,o.message,t):ue(n,"exclusiveMaximum",o.value,o.message,t):(o.inclusive||(n.exclusiveMaximum=!0),ue(n,"maximum",o.value,o.message,t));break;case"multipleOf":ue(n,"multipleOf",o.value,o.message,t);break}return n}function Wy(e,t){let n=t.target==="openAi",o={type:"object",properties:{}},r=[],i=e.shape();for(let s in i){let c=i[s];if(c===void 0||c._def===void 0)continue;let l=DP(c);l&&n&&(c._def.typeName==="ZodOptional"&&(c=c._def.innerType),c.isNullable()||(c=c.nullable()),l=!1);let d=G(c._def,{...t,currentPath:[...t.currentPath,"properties",s],propertyPath:[...t.currentPath,"properties",s]});d!==void 0&&(o.properties[s]=d,l||r.push(s))}r.length&&(o.required=r);let a=AP(e,t);return a!==void 0&&(o.additionalProperties=a),o}function AP(e,t){if(e.catchall._def.typeName!=="ZodNever")return G(e.catchall._def,{...t,currentPath:[...t.currentPath,"additionalProperties"]});switch(e.unknownKeys){case"passthrough":return t.allowedAdditionalProperties;case"strict":return t.rejectedAdditionalProperties;case"strip":return t.removeAdditionalStrategy==="strict"?t.allowedAdditionalProperties:t.rejectedAdditionalProperties}}function DP(e){try{return e.isOptional()}catch{return!0}}var Xy=(e,t)=>{if(t.currentPath.toString()===t.propertyPath?.toString())return G(e.innerType._def,t);let n=G(e.innerType._def,{...t,currentPath:[...t.currentPath,"anyOf","1"]});return n?{anyOf:[{not:Ie(t)},n]}:Ie(t)};var Yy=(e,t)=>{if(t.pipeStrategy==="input")return G(e.in._def,t);if(t.pipeStrategy==="output")return G(e.out._def,t);let n=G(e.in._def,{...t,currentPath:[...t.currentPath,"allOf","0"]}),o=G(e.out._def,{...t,currentPath:[...t.currentPath,"allOf",n?"1":"0"]});return{allOf:[n,o].filter(r=>r!==void 0)}};function Qy(e,t){return G(e.type._def,t)}function eb(e,t){let o={type:"array",uniqueItems:!0,items:G(e.valueType._def,{...t,currentPath:[...t.currentPath,"items"]})};return e.minSize&&ue(o,"minItems",e.minSize.value,e.minSize.message,t),e.maxSize&&ue(o,"maxItems",e.maxSize.value,e.maxSize.message,t),o}function tb(e,t){return e.rest?{type:"array",minItems:e.items.length,items:e.items.map((n,o)=>G(n._def,{...t,currentPath:[...t.currentPath,"items",`${o}`]})).reduce((n,o)=>o===void 0?n:[...n,o],[]),additionalItems:G(e.rest._def,{...t,currentPath:[...t.currentPath,"additionalItems"]})}:{type:"array",minItems:e.items.length,maxItems:e.items.length,items:e.items.map((n,o)=>G(n._def,{...t,currentPath:[...t.currentPath,"items",`${o}`]})).reduce((n,o)=>o===void 0?n:[...n,o],[])}}function rb(e){return{not:Ie(e)}}function nb(e){return Ie(e)}var ob=(e,t)=>G(e.innerType._def,t);var ib=(e,t,n)=>{switch(t){case O.ZodString:return rl(e,n);case O.ZodNumber:return Gy(e,n);case O.ZodObject:return Wy(e,n);case O.ZodBigInt:return Ny(e,n);case O.ZodBoolean:return Ry();case O.ZodDate:return Jp(e,n);case O.ZodUndefined:return rb(n);case O.ZodNull:return By(n);case O.ZodArray:return jy(e,n);case O.ZodUnion:case O.ZodDiscriminatedUnion:return Hy(e,n);case O.ZodIntersection:return Zy(e,n);case O.ZodTuple:return tb(e,n);case O.ZodRecord:return nl(e,n);case O.ZodLiteral:return My(e,n);case O.ZodEnum:return Uy(e);case O.ZodNativeEnum:return Vy(e);case O.ZodNullable:return Jy(e,n);case O.ZodOptional:return Xy(e,n);case O.ZodMap:return qy(e,n);case O.ZodSet:return eb(e,n);case O.ZodLazy:return()=>e.getter()._def;case O.ZodPromise:return Qy(e,n);case O.ZodNaN:case O.ZodNever:return Fy(n);case O.ZodEffects:return Cy(e,n);case O.ZodAny:return Ie(n);case O.ZodUnknown:return nb(n);case O.ZodDefault:return Dy(e,n);case O.ZodBranded:return tl(e,n);case O.ZodReadonly:return ob(e,n);case O.ZodCatch:return Ay(e,n);case O.ZodPipeline:return Yy(e,n);case O.ZodFunction:case O.ZodVoid:case O.ZodSymbol:return;default:return(o=>{})(t)}};function G(e,t,n=!1){let o=t.seen.get(e);if(t.override){let s=t.override?.(e,t,o,n);if(s!==Ty)return s}if(o&&!n){let s=CP(o,t);if(s!==void 0)return s}let r={def:e,path:t.currentPath,jsonSchema:void 0};t.seen.set(e,r);let i=ib(e,e.typeName,t),a=typeof i=="function"?G(i(),t):i;if(a&&UP(e,t,a),t.postProcess){let s=t.postProcess(a,e,t);return r.jsonSchema=a,s}return r.jsonSchema=a,a}var CP=(e,t)=>{switch(t.$refStrategy){case"root":return{$ref:e.path.join("/")};case"relative":return{$ref:el(t.currentPath,e.path)};case"none":case"seen":return e.path.length<t.currentPath.length&&e.path.every((n,o)=>t.currentPath[o]===n)?(console.warn(`Recursive reference detected at ${t.currentPath.join("/")}! Defaulting to any`),Ie(t)):t.$refStrategy==="seen"?Ie(t):void 0}},UP=(e,t,n)=>(e.description&&(n.description=e.description,t.markdownDescription&&(n.markdownDescription=e.description)),n);var Xp=(e,t)=>{let n=Oy(t),o=typeof t=="object"&&t.definitions?Object.entries(t.definitions).reduce((c,[l,d])=>({...c,[l]:G(d._def,{...n,currentPath:[...n.basePath,n.definitionPath,l]},!0)??Ie(n)}),{}):void 0,r=typeof t=="string"?t:t?.nameStrategy==="title"?void 0:t?.name,i=G(e._def,r===void 0?n:{...n,currentPath:[...n.basePath,n.definitionPath,r]},!1)??Ie(n),a=typeof t=="object"&&t.name!==void 0&&t.nameStrategy==="title"?t.name:void 0;a!==void 0&&(i.title=a),n.flags.hasReferencedOpenAiAnyType&&(o||(o={}),o[n.openAiAnyTypeName]||(o[n.openAiAnyTypeName]={type:["string","number","integer","boolean","array","null"],items:{$ref:n.$refStrategy==="relative"?"1":[...n.basePath,n.definitionPath,n.openAiAnyTypeName].join("/")}}));let s=r===void 0?o?{...i,[n.definitionPath]:o}:i:{$ref:[...n.$refStrategy==="relative"?[]:n.basePath,n.definitionPath,r].join("/"),[n.definitionPath]:{...o,[r]:i}};return n.target==="jsonSchema7"?s.$schema="http://json-schema.org/draft-07/schema#":(n.target==="jsonSchema2019-09"||n.target==="openAi")&&(s.$schema="https://json-schema.org/draft/2019-09/schema#"),n.target==="openAi"&&("anyOf"in s||"oneOf"in s||"allOf"in s||"type"in s&&Array.isArray(s.type))&&console.warn("Warning: OpenAI may not support schemas with unions as roots! Try wrapping it in an object property."),s};function ZP(e){return!e||e==="jsonSchema7"||e==="draft-7"?"draft-7":e==="jsonSchema2019-09"||e==="draft-2020-12"?"draft-2020-12":"draft-7"}function Yp(e,t){return vt(e)?so(e,{target:ZP(t?.target),io:t?.pipeStrategy??"input"}):Xp(e,{strictUnions:t?.strictUnions??!0,pipeStrategy:t?.pipeStrategy??"input"})}function Qp(e){let n=Er(e)?.method;if(!n)throw new Error("Schema is missing a method literal");let o=yu(n);if(typeof o!="string")throw new Error("Schema method literal must be a string");return o}function em(e,t){let n=Ir(e,t);if(!n.success)throw n.error;return n.data}var MP=6e4,ol=class{constructor(t){this._options=t,this._requestMessageId=0,this._requestHandlers=new Map,this._requestHandlerAbortControllers=new Map,this._notificationHandlers=new Map,this._responseHandlers=new Map,this._progressHandlers=new Map,this._timeoutInfo=new Map,this._pendingDebouncedNotifications=new Set,this._taskProgressTokens=new Map,this._requestResolvers=new Map,this.setNotificationHandler(Cu,n=>{this._oncancel(n)}),this.setNotificationHandler(Zu,n=>{this._onprogress(n)}),this.setRequestHandler(Uu,n=>({})),this._taskStore=t?.taskStore,this._taskMessageQueue=t?.taskMessageQueue,this._taskStore&&(this.setRequestHandler(Mu,async(n,o)=>{let r=await this._taskStore.getTask(n.params.taskId,o.sessionId);if(!r)throw new F(H.InvalidParams,"Failed to retrieve task: Task not found");return{...r}}),this.setRequestHandler(qu,async(n,o)=>{let r=async()=>{let i=n.params.taskId;if(this._taskMessageQueue){let s;for(;s=await this._taskMessageQueue.dequeue(i,o.sessionId);){if(s.type==="response"||s.type==="error"){let c=s.message,l=c.id,d=this._requestResolvers.get(l);if(d)if(this._requestResolvers.delete(l),s.type==="response")d(c);else{let f=c,_=new F(f.error.code,f.error.message,f.error.data);d(_)}else{let f=s.type==="response"?"Response":"Error";this._onerror(new Error(`${f} handler missing for request ${l}`))}continue}await this._transport?.send(s.message,{relatedRequestId:o.requestId})}}let a=await this._taskStore.getTask(i,o.sessionId);if(!a)throw new F(H.InvalidParams,`Task not found: ${i}`);if(!Pr(a.status))return await this._waitForTaskUpdate(i,o.signal),await r();if(Pr(a.status)){let s=await this._taskStore.getTaskResult(i,o.sessionId);return this._clearTaskQueue(i),{...s,_meta:{...s._meta,[Tr]:{taskId:i}}}}return await r()};return await r()}),this.setRequestHandler(Vu,async(n,o)=>{try{let{tasks:r,nextCursor:i}=await this._taskStore.listTasks(n.params?.cursor,o.sessionId);return{tasks:r,nextCursor:i,_meta:{}}}catch(r){throw new F(H.InvalidParams,`Failed to list tasks: ${r instanceof Error?r.message:String(r)}`)}}),this.setRequestHandler(Bu,async(n,o)=>{try{let r=await this._taskStore.getTask(n.params.taskId,o.sessionId);if(!r)throw new F(H.InvalidParams,`Task not found: ${n.params.taskId}`);if(Pr(r.status))throw new F(H.InvalidParams,`Cannot cancel task in terminal status: ${r.status}`);await this._taskStore.updateTaskStatus(n.params.taskId,"cancelled","Client cancelled task execution.",o.sessionId),this._clearTaskQueue(n.params.taskId);let i=await this._taskStore.getTask(n.params.taskId,o.sessionId);if(!i)throw new F(H.InvalidParams,`Task not found after cancellation: ${n.params.taskId}`);return{_meta:{},...i}}catch(r){throw r instanceof F?r:new F(H.InvalidRequest,`Failed to cancel task: ${r instanceof Error?r.message:String(r)}`)}}))}async _oncancel(t){if(!t.params.requestId)return;this._requestHandlerAbortControllers.get(t.params.requestId)?.abort(t.params.reason)}_setupTimeout(t,n,o,r,i=!1){this._timeoutInfo.set(t,{timeoutId:setTimeout(r,n),startTime:Date.now(),timeout:n,maxTotalTimeout:o,resetTimeoutOnProgress:i,onTimeout:r})}_resetTimeout(t){let n=this._timeoutInfo.get(t);if(!n)return!1;let o=Date.now()-n.startTime;if(n.maxTotalTimeout&&o>=n.maxTotalTimeout)throw this._timeoutInfo.delete(t),F.fromError(H.RequestTimeout,"Maximum total timeout exceeded",{maxTotalTimeout:n.maxTotalTimeout,totalElapsed:o});return clearTimeout(n.timeoutId),n.timeoutId=setTimeout(n.onTimeout,n.timeout),!0}_cleanupTimeout(t){let n=this._timeoutInfo.get(t);n&&(clearTimeout(n.timeoutId),this._timeoutInfo.delete(t))}async connect(t){if(this._transport)throw new Error("Already connected to a transport. Call close() before connecting to a new transport, or use a separate Protocol instance per connection.");this._transport=t;let n=this.transport?.onclose;this._transport.onclose=()=>{n?.(),this._onclose()};let o=this.transport?.onerror;this._transport.onerror=i=>{o?.(i),this._onerror(i)};let r=this._transport?.onmessage;this._transport.onmessage=(i,a)=>{r?.(i,a),Ji(i)||vy(i)?this._onresponse(i):Np(i)?this._onrequest(i,a):gy(i)?this._onnotification(i):this._onerror(new Error(`Unknown message type: ${JSON.stringify(i)}`))},await this._transport.start()}_onclose(){let t=this._responseHandlers;this._responseHandlers=new Map,this._progressHandlers.clear(),this._taskProgressTokens.clear(),this._pendingDebouncedNotifications.clear();for(let o of this._requestHandlerAbortControllers.values())o.abort();this._requestHandlerAbortControllers.clear();let n=F.fromError(H.ConnectionClosed,"Connection closed");this._transport=void 0,this.onclose?.();for(let o of t.values())o(n)}_onerror(t){this.onerror?.(t)}_onnotification(t){let n=this._notificationHandlers.get(t.method)??this.fallbackNotificationHandler;n!==void 0&&Promise.resolve().then(()=>n(t)).catch(o=>this._onerror(new Error(`Uncaught error in notification handler: ${o}`)))}_onrequest(t,n){let o=this._requestHandlers.get(t.method)??this.fallbackRequestHandler,r=this._transport,i=t.params?._meta?.[Tr]?.taskId;if(o===void 0){let d={jsonrpc:"2.0",id:t.id,error:{code:H.MethodNotFound,message:"Method not found"}};i&&this._taskMessageQueue?this._enqueueTaskMessage(i,{type:"error",message:d,timestamp:Date.now()},r?.sessionId).catch(f=>this._onerror(new Error(`Failed to enqueue error response: ${f}`))):r?.send(d).catch(f=>this._onerror(new Error(`Failed to send an error response: ${f}`)));return}let a=new AbortController;this._requestHandlerAbortControllers.set(t.id,a);let s=py(t.params)?t.params.task:void 0,c=this._taskStore?this.requestTaskStore(t,r?.sessionId):void 0,l={signal:a.signal,sessionId:r?.sessionId,_meta:t.params?._meta,sendNotification:async d=>{if(a.signal.aborted)return;let f={relatedRequestId:t.id};i&&(f.relatedTask={taskId:i}),await this.notification(d,f)},sendRequest:async(d,f,_)=>{if(a.signal.aborted)throw new F(H.ConnectionClosed,"Request was cancelled");let v={..._,relatedRequestId:t.id};i&&!v.relatedTask&&(v.relatedTask={taskId:i});let g=v.relatedTask?.taskId??i;return g&&c&&await c.updateTaskStatus(g,"input_required"),await this.request(d,f,v)},authInfo:n?.authInfo,requestId:t.id,requestInfo:n?.requestInfo,taskId:i,taskStore:c,taskRequestedTtl:s?.ttl,closeSSEStream:n?.closeSSEStream,closeStandaloneSSEStream:n?.closeStandaloneSSEStream};Promise.resolve().then(()=>{s&&this.assertTaskHandlerCapability(t.method)}).then(()=>o(t,l)).then(async d=>{if(a.signal.aborted)return;let f={result:d,jsonrpc:"2.0",id:t.id};i&&this._taskMessageQueue?await this._enqueueTaskMessage(i,{type:"response",message:f,timestamp:Date.now()},r?.sessionId):await r?.send(f)},async d=>{if(a.signal.aborted)return;let f={jsonrpc:"2.0",id:t.id,error:{code:Number.isSafeInteger(d.code)?d.code:H.InternalError,message:d.message??"Internal error",...d.data!==void 0&&{data:d.data}}};i&&this._taskMessageQueue?await this._enqueueTaskMessage(i,{type:"error",message:f,timestamp:Date.now()},r?.sessionId):await r?.send(f)}).catch(d=>this._onerror(new Error(`Failed to send response: ${d}`))).finally(()=>{this._requestHandlerAbortControllers.delete(t.id)})}_onprogress(t){let{progressToken:n,...o}=t.params,r=Number(n),i=this._progressHandlers.get(r);if(!i){this._onerror(new Error(`Received a progress notification for an unknown token: ${JSON.stringify(t)}`));return}let a=this._responseHandlers.get(r),s=this._timeoutInfo.get(r);if(s&&a&&s.resetTimeoutOnProgress)try{this._resetTimeout(r)}catch(c){this._responseHandlers.delete(r),this._progressHandlers.delete(r),this._cleanupTimeout(r),a(c);return}i(o)}_onresponse(t){let n=Number(t.id),o=this._requestResolvers.get(n);if(o){if(this._requestResolvers.delete(n),Ji(t))o(t);else{let a=new F(t.error.code,t.error.message,t.error.data);o(a)}return}let r=this._responseHandlers.get(n);if(r===void 0){this._onerror(new Error(`Received a response for an unknown message ID: ${JSON.stringify(t)}`));return}this._responseHandlers.delete(n),this._cleanupTimeout(n);let i=!1;if(Ji(t)&&t.result&&typeof t.result=="object"){let a=t.result;if(a.task&&typeof a.task=="object"){let s=a.task;typeof s.taskId=="string"&&(i=!0,this._taskProgressTokens.set(s.taskId,n))}}if(i||this._progressHandlers.delete(n),Ji(t))r(t);else{let a=F.fromError(t.error.code,t.error.message,t.error.data);r(a)}}get transport(){return this._transport}async close(){await this._transport?.close()}async*requestStream(t,n,o){let{task:r}=o??{};if(!r){try{yield{type:"result",result:await this.request(t,n,o)}}catch(a){yield{type:"error",error:a instanceof F?a:new F(H.InternalError,String(a))}}return}let i;try{let a=await this.request(t,po,o);if(a.task)i=a.task.taskId,yield{type:"taskCreated",task:a.task};else throw new F(H.InternalError,"Task creation did not return a task");for(;;){let s=await this.getTask({taskId:i},o);if(yield{type:"taskStatus",task:s},Pr(s.status)){s.status==="completed"?yield{type:"result",result:await this.getTaskResult({taskId:i},n,o)}:s.status==="failed"?yield{type:"error",error:new F(H.InternalError,`Task ${i} failed`)}:s.status==="cancelled"&&(yield{type:"error",error:new F(H.InternalError,`Task ${i} was cancelled`)});return}if(s.status==="input_required"){yield{type:"result",result:await this.getTaskResult({taskId:i},n,o)};return}let c=s.pollInterval??this._options?.defaultTaskPollInterval??1e3;await new Promise(l=>setTimeout(l,c)),o?.signal?.throwIfAborted()}}catch(a){yield{type:"error",error:a instanceof F?a:new F(H.InternalError,String(a))}}}request(t,n,o){let{relatedRequestId:r,resumptionToken:i,onresumptiontoken:a,task:s,relatedTask:c}=o??{};return new Promise((l,d)=>{let f=R=>{d(R)};if(!this._transport){f(new Error("Not connected"));return}if(this._options?.enforceStrictCapabilities===!0)try{this.assertCapabilityForMethod(t.method),s&&this.assertTaskCapability(t.method)}catch(R){f(R);return}o?.signal?.throwIfAborted();let _=this._requestMessageId++,v={...t,jsonrpc:"2.0",id:_};o?.onprogress&&(this._progressHandlers.set(_,o.onprogress),v.params={...t.params,_meta:{...t.params?._meta||{},progressToken:_}}),s&&(v.params={...v.params,task:s}),c&&(v.params={...v.params,_meta:{...v.params?._meta||{},[Tr]:c}});let g=R=>{this._responseHandlers.delete(_),this._progressHandlers.delete(_),this._cleanupTimeout(_),this._transport?.send({jsonrpc:"2.0",method:"notifications/cancelled",params:{requestId:_,reason:String(R)}},{relatedRequestId:r,resumptionToken:i,onresumptiontoken:a}).catch(M=>this._onerror(new Error(`Failed to send cancellation: ${M}`)));let P=R instanceof F?R:new F(H.RequestTimeout,String(R));d(P)};this._responseHandlers.set(_,R=>{if(!o?.signal?.aborted){if(R instanceof Error)return d(R);try{let P=Ir(n,R.result);P.success?l(P.data):d(P.error)}catch(P){d(P)}}}),o?.signal?.addEventListener("abort",()=>{g(o?.signal?.reason)});let b=o?.timeout??MP,x=()=>g(F.fromError(H.RequestTimeout,"Request timed out",{timeout:b}));this._setupTimeout(_,b,o?.maxTotalTimeout,x,o?.resetTimeoutOnProgress??!1);let I=c?.taskId;if(I){let R=P=>{let M=this._responseHandlers.get(_);M?M(P):this._onerror(new Error(`Response handler missing for side-channeled request ${_}`))};this._requestResolvers.set(_,R),this._enqueueTaskMessage(I,{type:"request",message:v,timestamp:Date.now()}).catch(P=>{this._cleanupTimeout(_),d(P)})}else this._transport.send(v,{relatedRequestId:r,resumptionToken:i,onresumptiontoken:a}).catch(R=>{this._cleanupTimeout(_),d(R)})})}async getTask(t,n){return this.request({method:"tasks/get",params:t},Lu,n)}async getTaskResult(t,n,o){return this.request({method:"tasks/result",params:t},n,o)}async listTasks(t,n){return this.request({method:"tasks/list",params:t},Fu,n)}async cancelTask(t,n){return this.request({method:"tasks/cancel",params:t},by,n)}async notification(t,n){if(!this._transport)throw new Error("Not connected");this.assertNotificationCapability(t.method);let o=n?.relatedTask?.taskId;if(o){let s={...t,jsonrpc:"2.0",params:{...t.params,_meta:{...t.params?._meta||{},[Tr]:n.relatedTask}}};await this._enqueueTaskMessage(o,{type:"notification",message:s,timestamp:Date.now()});return}if((this._options?.debouncedNotificationMethods??[]).includes(t.method)&&!t.params&&!n?.relatedRequestId&&!n?.relatedTask){if(this._pendingDebouncedNotifications.has(t.method))return;this._pendingDebouncedNotifications.add(t.method),Promise.resolve().then(()=>{if(this._pendingDebouncedNotifications.delete(t.method),!this._transport)return;let s={...t,jsonrpc:"2.0"};n?.relatedTask&&(s={...s,params:{...s.params,_meta:{...s.params?._meta||{},[Tr]:n.relatedTask}}}),this._transport?.send(s,n).catch(c=>this._onerror(c))});return}let a={...t,jsonrpc:"2.0"};n?.relatedTask&&(a={...a,params:{...a.params,_meta:{...a.params?._meta||{},[Tr]:n.relatedTask}}}),await this._transport.send(a,n)}setRequestHandler(t,n){let o=Qp(t);this.assertRequestHandlerCapability(o),this._requestHandlers.set(o,(r,i)=>{let a=em(t,r);return Promise.resolve(n(a,i))})}removeRequestHandler(t){this._requestHandlers.delete(t)}assertCanSetRequestHandler(t){if(this._requestHandlers.has(t))throw new Error(`A request handler for ${t} already exists, which would be overridden`)}setNotificationHandler(t,n){let o=Qp(t);this._notificationHandlers.set(o,r=>{let i=em(t,r);return Promise.resolve(n(i))})}removeNotificationHandler(t){this._notificationHandlers.delete(t)}_cleanupTaskProgressHandler(t){let n=this._taskProgressTokens.get(t);n!==void 0&&(this._progressHandlers.delete(n),this._taskProgressTokens.delete(t))}async _enqueueTaskMessage(t,n,o){if(!this._taskStore||!this._taskMessageQueue)throw new Error("Cannot enqueue task message: taskStore and taskMessageQueue are not configured");let r=this._options?.maxTaskQueueSize;await this._taskMessageQueue.enqueue(t,n,o,r)}async _clearTaskQueue(t,n){if(this._taskMessageQueue){let o=await this._taskMessageQueue.dequeueAll(t,n);for(let r of o)if(r.type==="request"&&Np(r.message)){let i=r.message.id,a=this._requestResolvers.get(i);a?(a(new F(H.InternalError,"Task cancelled or completed")),this._requestResolvers.delete(i)):this._onerror(new Error(`Resolver missing for request ${i} during task ${t} cleanup`))}}}async _waitForTaskUpdate(t,n){let o=this._options?.defaultTaskPollInterval??1e3;try{let r=await this._taskStore?.getTask(t);r?.pollInterval&&(o=r.pollInterval)}catch{}return new Promise((r,i)=>{if(n.aborted){i(new F(H.InvalidRequest,"Request cancelled"));return}let a=setTimeout(r,o);n.addEventListener("abort",()=>{clearTimeout(a),i(new F(H.InvalidRequest,"Request cancelled"))},{once:!0})})}requestTaskStore(t,n){let o=this._taskStore;if(!o)throw new Error("No task store configured");return{createTask:async r=>{if(!t)throw new Error("No request provided");return await o.createTask(r,t.id,{method:t.method,params:t.params},n)},getTask:async r=>{let i=await o.getTask(r,n);if(!i)throw new F(H.InvalidParams,"Failed to retrieve task: Task not found");return i},storeTaskResult:async(r,i,a)=>{await o.storeTaskResult(r,i,a,n);let s=await o.getTask(r,n);if(s){let c=Qi.parse({method:"notifications/tasks/status",params:s});await this.notification(c),Pr(s.status)&&this._cleanupTaskProgressHandler(r)}},getTaskResult:r=>o.getTaskResult(r,n),updateTaskStatus:async(r,i,a)=>{let s=await o.getTask(r,n);if(!s)throw new F(H.InvalidParams,`Task "${r}" not found - it may have been cleaned up`);if(Pr(s.status))throw new F(H.InvalidParams,`Cannot update task "${r}" from terminal status "${s.status}" to "${i}". Terminal states (completed, failed, cancelled) cannot transition to other states.`);await o.updateTaskStatus(r,i,a,n);let c=await o.getTask(r,n);if(c){let l=Qi.parse({method:"notifications/tasks/status",params:c});await this.notification(l),Pr(c.status)&&this._cleanupTaskProgressHandler(r)}},listTasks:r=>o.listTasks(r,n)}}};function ab(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function sb(e,t){let n={...e};for(let o in t){let r=o,i=t[r];if(i===void 0)continue;let a=n[r];ab(a)&&ab(i)?n[r]={...a,...i}:n[r]=i}return n}var Hx=ht(Zh(),1),Jx=ht(Kx(),1);function OA(){let e=new Hx.default({strict:!1,validateFormats:!0,validateSchema:!1,allErrors:!0});return(0,Jx.default)(e),e}var Ml=class{constructor(t){this._ajv=t??OA()}getValidator(t){let n="$id"in t&&typeof t.$id=="string"?this._ajv.getSchema(t.$id)??this._ajv.compile(t):this._ajv.compile(t);return o=>n(o)?{valid:!0,data:o,errorMessage:void 0}:{valid:!1,data:void 0,errorMessage:this._ajv.errorsText(n.errors)}}};var Ll=class{constructor(t){this._server=t}requestStream(t,n,o){return this._server.requestStream(t,n,o)}createMessageStream(t,n){let o=this._server.getClientCapabilities();if((t.tools||t.toolChoice)&&!o?.sampling?.tools)throw new Error("Client does not support sampling tools capability.");if(t.messages.length>0){let r=t.messages[t.messages.length-1],i=Array.isArray(r.content)?r.content:[r.content],a=i.some(d=>d.type==="tool_result"),s=t.messages.length>1?t.messages[t.messages.length-2]:void 0,c=s?Array.isArray(s.content)?s.content:[s.content]:[],l=c.some(d=>d.type==="tool_use");if(a){if(i.some(d=>d.type!=="tool_result"))throw new Error("The last message must contain only tool_result content if any is present");if(!l)throw new Error("tool_result blocks are not matching any tool_use from the previous message")}if(l){let d=new Set(c.filter(_=>_.type==="tool_use").map(_=>_.id)),f=new Set(i.filter(_=>_.type==="tool_result").map(_=>_.toolUseId));if(d.size!==f.size||![...d].every(_=>f.has(_)))throw new Error("ids of tool_result blocks and tool_use blocks from previous message do not match")}}return this.requestStream({method:"sampling/createMessage",params:t},ra,n)}elicitInputStream(t,n){let o=this._server.getClientCapabilities(),r=t.mode??"form";switch(r){case"url":{if(!o?.elicitation?.url)throw new Error("Client does not support url elicitation.");break}case"form":{if(!o?.elicitation?.form)throw new Error("Client does not support form elicitation.");break}}let i=r==="form"&&t.mode===void 0?{...t,mode:"form"}:t;return this.requestStream({method:"elicitation/create",params:i},go,n)}async getTask(t,n){return this._server.getTask({taskId:t},n)}async getTaskResult(t,n,o){return this._server.getTaskResult({taskId:t},n,o)}async listTasks(t,n){return this._server.listTasks(t?{cursor:t}:void 0,n)}async cancelTask(t,n){return this._server.cancelTask({taskId:t},n)}};function Gx(e,t,n){if(!e)throw new Error(`${n} does not support task creation (required for ${t})`);switch(t){case"tools/call":if(!e.tools?.call)throw new Error(`${n} does not support task creation for tools/call (required for ${t})`);break;default:break}}function Wx(e,t,n){if(!e)throw new Error(`${n} does not support task creation (required for ${t})`);switch(t){case"sampling/createMessage":if(!e.sampling?.createMessage)throw new Error(`${n} does not support task creation for sampling/createMessage (required for ${t})`);break;case"elicitation/create":if(!e.elicitation?.create)throw new Error(`${n} does not support task creation for elicitation/create (required for ${t})`);break;default:break}}var ql=class extends ol{constructor(t,n){super(n),this._serverInfo=t,this._loggingLevels=new Map,this.LOG_LEVEL_SEVERITY=new Map(ta.options.map((o,r)=>[o,r])),this.isMessageIgnored=(o,r)=>{let i=this._loggingLevels.get(r);return i?this.LOG_LEVEL_SEVERITY.get(o)<this.LOG_LEVEL_SEVERITY.get(i):!1},this._capabilities=n?.capabilities??{},this._instructions=n?.instructions,this._jsonSchemaValidator=n?.jsonSchemaValidator??new Ml,this.setRequestHandler(Dp,o=>this._oninitialize(o)),this.setNotificationHandler(Cp,()=>this.oninitialized?.()),this._capabilities.logging&&this.setRequestHandler(Fp,async(o,r)=>{let i=r.sessionId||r.requestInfo?.headers["mcp-session-id"]||void 0,{level:a}=o.params,s=ta.safeParse(a);return s.success&&this._loggingLevels.set(i,s.data),{}})}get experimental(){return this._experimental||(this._experimental={tasks:new Ll(this)}),this._experimental}registerCapabilities(t){if(this.transport)throw new Error("Cannot register capabilities after connecting to transport");this._capabilities=sb(this._capabilities,t)}setRequestHandler(t,n){let r=Er(t)?.method;if(!r)throw new Error("Schema is missing a method literal");let i;if(vt(r)){let s=r;i=s._zod?.def?.value??s.value}else{let s=r;i=s._def?.value??s.value}if(typeof i!="string")throw new Error("Schema method literal must be a string");if(i==="tools/call"){let s=async(c,l)=>{let d=Ir(ho,c);if(!d.success){let g=d.error instanceof Error?d.error.message:String(d.error);throw new F(H.InvalidParams,`Invalid tools/call request: ${g}`)}let{params:f}=d.data,_=await Promise.resolve(n(c,l));if(f.task){let g=Ir(po,_);if(!g.success){let b=g.error instanceof Error?g.error.message:String(g.error);throw new F(H.InvalidParams,`Invalid task creation result: ${b}`)}return g.data}let v=Ir(Yu,_);if(!v.success){let g=v.error instanceof Error?v.error.message:String(v.error);throw new F(H.InvalidParams,`Invalid tools/call result: ${g}`)}return v.data};return super.setRequestHandler(t,s)}return super.setRequestHandler(t,n)}assertCapabilityForMethod(t){switch(t){case"sampling/createMessage":if(!this._clientCapabilities?.sampling)throw new Error(`Client does not support sampling (required for ${t})`);break;case"elicitation/create":if(!this._clientCapabilities?.elicitation)throw new Error(`Client does not support elicitation (required for ${t})`);break;case"roots/list":if(!this._clientCapabilities?.roots)throw new Error(`Client does not support listing roots (required for ${t})`);break;case"ping":break}}assertNotificationCapability(t){switch(t){case"notifications/message":if(!this._capabilities.logging)throw new Error(`Server does not support logging (required for ${t})`);break;case"notifications/resources/updated":case"notifications/resources/list_changed":if(!this._capabilities.resources)throw new Error(`Server does not support notifying about resources (required for ${t})`);break;case"notifications/tools/list_changed":if(!this._capabilities.tools)throw new Error(`Server does not support notifying of tool list changes (required for ${t})`);break;case"notifications/prompts/list_changed":if(!this._capabilities.prompts)throw new Error(`Server does not support notifying of prompt list changes (required for ${t})`);break;case"notifications/elicitation/complete":if(!this._clientCapabilities?.elicitation?.url)throw new Error(`Client does not support URL elicitation (required for ${t})`);break;case"notifications/cancelled":break;case"notifications/progress":break}}assertRequestHandlerCapability(t){if(this._capabilities)switch(t){case"completion/complete":if(!this._capabilities.completions)throw new Error(`Server does not support completions (required for ${t})`);break;case"logging/setLevel":if(!this._capabilities.logging)throw new Error(`Server does not support logging (required for ${t})`);break;case"prompts/get":case"prompts/list":if(!this._capabilities.prompts)throw new Error(`Server does not support prompts (required for ${t})`);break;case"resources/list":case"resources/templates/list":case"resources/read":if(!this._capabilities.resources)throw new Error(`Server does not support resources (required for ${t})`);break;case"tools/call":case"tools/list":if(!this._capabilities.tools)throw new Error(`Server does not support tools (required for ${t})`);break;case"tasks/get":case"tasks/list":case"tasks/result":case"tasks/cancel":if(!this._capabilities.tasks)throw new Error(`Server does not support tasks capability (required for ${t})`);break;case"ping":case"initialize":break}}assertTaskCapability(t){Wx(this._clientCapabilities?.tasks?.requests,t,"Client")}assertTaskHandlerCapability(t){this._capabilities&&Gx(this._capabilities.tasks?.requests,t,"Server")}async _oninitialize(t){let n=t.params.protocolVersion;return this._clientCapabilities=t.params.capabilities,this._clientVersion=t.params.clientInfo,{protocolVersion:ly.includes(n)?n:Op,capabilities:this.getCapabilities(),serverInfo:this._serverInfo,...this._instructions&&{instructions:this._instructions}}}getClientCapabilities(){return this._clientCapabilities}getClientVersion(){return this._clientVersion}getCapabilities(){return this._capabilities}async ping(){return this.request({method:"ping"},Du)}async createMessage(t,n){if((t.tools||t.toolChoice)&&!this._clientCapabilities?.sampling?.tools)throw new Error("Client does not support sampling tools capability.");if(t.messages.length>0){let o=t.messages[t.messages.length-1],r=Array.isArray(o.content)?o.content:[o.content],i=r.some(l=>l.type==="tool_result"),a=t.messages.length>1?t.messages[t.messages.length-2]:void 0,s=a?Array.isArray(a.content)?a.content:[a.content]:[],c=s.some(l=>l.type==="tool_use");if(i){if(r.some(l=>l.type!=="tool_result"))throw new Error("The last message must contain only tool_result content if any is present");if(!c)throw new Error("tool_result blocks are not matching any tool_use from the previous message")}if(c){let l=new Set(s.filter(f=>f.type==="tool_use").map(f=>f.id)),d=new Set(r.filter(f=>f.type==="tool_result").map(f=>f.toolUseId));if(l.size!==d.size||![...l].every(f=>d.has(f)))throw new Error("ids of tool_result blocks and tool_use blocks from previous message do not match")}}return t.tools?this.request({method:"sampling/createMessage",params:t},Bp,n):this.request({method:"sampling/createMessage",params:t},ra,n)}async elicitInput(t,n){switch(t.mode??"form"){case"url":{if(!this._clientCapabilities?.elicitation?.url)throw new Error("Client does not support url elicitation.");let r=t;return this.request({method:"elicitation/create",params:r},go,n)}case"form":{if(!this._clientCapabilities?.elicitation?.form)throw new Error("Client does not support form elicitation.");let r=t.mode==="form"?t:{...t,mode:"form"},i=await this.request({method:"elicitation/create",params:r},go,n);if(i.action==="accept"&&i.content&&r.requestedSchema)try{let s=this._jsonSchemaValidator.getValidator(r.requestedSchema)(i.content);if(!s.valid)throw new F(H.InvalidParams,`Elicitation response content does not match requested schema: ${s.errorMessage}`)}catch(a){throw a instanceof F?a:new F(H.InternalError,`Error validating elicitation response: ${a instanceof Error?a.message:String(a)}`)}return i}}}createElicitationCompletionNotifier(t,n){if(!this._clientCapabilities?.elicitation?.url)throw new Error("Client does not support URL elicitation (required for notifications/elicitation/complete)");return()=>this.notification({method:"notifications/elicitation/complete",params:{elicitationId:t}},n)}async listRoots(t,n){return this.request({method:"roots/list",params:t},Kp,n)}async sendLoggingMessage(t,n){if(this._capabilities.logging&&!this.isMessageIgnored(t.level,n))return this.notification({method:"notifications/message",params:t})}async sendResourceUpdated(t){return this.notification({method:"notifications/resources/updated",params:t})}async sendResourceListChanged(){return this.notification({method:"notifications/resources/list_changed"})}async sendToolListChanged(){return this.notification({method:"notifications/tools/list_changed"})}async sendPromptListChanged(){return this.notification({method:"notifications/prompts/list_changed"})}};var Yx=Symbol.for("mcp.completable");function Hh(e){return!!e&&typeof e=="object"&&Yx in e}function Qx(e){return e[Yx]?.complete}var Xx;(function(e){e.Completable="McpCompletable"})(Xx||(Xx={}));var jA=/^[A-Za-z0-9._-]{1,128}$/;function NA(e){let t=[];if(e.length===0)return{isValid:!1,warnings:["Tool name cannot be empty"]};if(e.length>128)return{isValid:!1,warnings:[`Tool name exceeds maximum length of 128 characters (current: ${e.length})`]};if(e.includes(" ")&&t.push("Tool name contains spaces, which may cause parsing issues"),e.includes(",")&&t.push("Tool name contains commas, which may cause parsing issues"),(e.startsWith("-")||e.endsWith("-"))&&t.push("Tool name starts or ends with a dash, which may cause parsing issues in some contexts"),(e.startsWith(".")||e.endsWith("."))&&t.push("Tool name starts or ends with a dot, which may cause parsing issues in some contexts"),!jA.test(e)){let n=e.split("").filter(o=>!/[A-Za-z0-9._-]/.test(o)).filter((o,r,i)=>i.indexOf(o)===r);return t.push(`Tool name contains invalid characters: ${n.map(o=>`"${o}"`).join(", ")}`,"Allowed characters are: A-Z, a-z, 0-9, underscore (_), dash (-), and dot (.)"),{isValid:!1,warnings:t}}return{isValid:!0,warnings:t}}function RA(e,t){if(t.length>0){console.warn(`Tool name validation warning for "${e}":`);for(let n of t)console.warn(` - ${n}`);console.warn("Tool registration will proceed, but this may cause compatibility issues."),console.warn("Consider updating the tool name to conform to the MCP tool naming standard."),console.warn("See SEP: Specify Format for Tool Names (https://github.com/modelcontextprotocol/modelcontextprotocol/issues/986) for more details.")}}function Jh(e){let t=NA(e);return RA(e,t.warnings),t.isValid}var Vl=class{constructor(t){this._mcpServer=t}registerToolTask(t,n,o){let r={taskSupport:"required",...n.execution};if(r.taskSupport==="forbidden")throw new Error(`Cannot register task-based tool '${t}' with taskSupport 'forbidden'. Use registerTool() instead.`);return this._mcpServer._createRegisteredTool(t,n.title,n.description,n.inputSchema,n.outputSchema,n.annotations,r,n._meta,o)}};var Fl=class{constructor(t,n){this._registeredResources={},this._registeredResourceTemplates={},this._registeredTools={},this._registeredPrompts={},this._toolHandlersInitialized=!1,this._completionHandlerInitialized=!1,this._resourceHandlersInitialized=!1,this._promptHandlersInitialized=!1,this.server=new ql(t,n)}get experimental(){return this._experimental||(this._experimental={tasks:new Vl(this)}),this._experimental}async connect(t){return await this.server.connect(t)}async close(){await this.server.close()}setToolRequestHandlers(){this._toolHandlersInitialized||(this.server.assertCanSetRequestHandler(Zr(Xu)),this.server.assertCanSetRequestHandler(Zr(ho)),this.server.registerCapabilities({tools:{listChanged:!0}}),this.server.setRequestHandler(Xu,()=>({tools:Object.entries(this._registeredTools).filter(([,t])=>t.enabled).map(([t,n])=>{let o={name:t,title:n.title,description:n.description,inputSchema:(()=>{let r=co(n.inputSchema);return r?Yp(r,{strictUnions:!0,pipeStrategy:"input"}):AA})(),annotations:n.annotations,execution:n.execution,_meta:n._meta};if(n.outputSchema){let r=co(n.outputSchema);r&&(o.outputSchema=Yp(r,{strictUnions:!0,pipeStrategy:"output"}))}return o})})),this.server.setRequestHandler(ho,async(t,n)=>{try{let o=this._registeredTools[t.params.name];if(!o)throw new F(H.InvalidParams,`Tool ${t.params.name} not found`);if(!o.enabled)throw new F(H.InvalidParams,`Tool ${t.params.name} disabled`);let r=!!t.params.task,i=o.execution?.taskSupport,a="createTask"in o.handler;if((i==="required"||i==="optional")&&!a)throw new F(H.InternalError,`Tool ${t.params.name} has taskSupport '${i}' but was not registered with registerToolTask`);if(i==="required"&&!r)throw new F(H.MethodNotFound,`Tool ${t.params.name} requires task augmentation (taskSupport: 'required')`);if(i==="optional"&&!r&&a)return await this.handleAutomaticTaskPolling(o,t,n);let s=await this.validateToolInput(o,t.params.arguments,t.params.name),c=await this.executeToolHandler(o,s,n);return r||await this.validateToolOutput(o,c,t.params.name),c}catch(o){if(o instanceof F&&o.code===H.UrlElicitationRequired)throw o;return this.createToolError(o instanceof Error?o.message:String(o))}}),this._toolHandlersInitialized=!0)}createToolError(t){return{content:[{type:"text",text:t}],isError:!0}}async validateToolInput(t,n,o){if(!t.inputSchema)return;let i=co(t.inputSchema)??t.inputSchema,a=await vu(i,n);if(!a.success){let s="error"in a?a.error:"Unknown error",c=_u(s);throw new F(H.InvalidParams,`Input validation error: Invalid arguments for tool ${o}: ${c}`)}return a.data}async validateToolOutput(t,n,o){if(!t.outputSchema||!("content"in n)||n.isError)return;if(!n.structuredContent)throw new F(H.InvalidParams,`Output validation error: Tool ${o} has an output schema but no structured content was provided`);let r=co(t.outputSchema),i=await vu(r,n.structuredContent);if(!i.success){let a="error"in i?i.error:"Unknown error",s=_u(a);throw new F(H.InvalidParams,`Output validation error: Invalid structured content for tool ${o}: ${s}`)}}async executeToolHandler(t,n,o){let r=t.handler;if("createTask"in r){if(!o.taskStore)throw new Error("No task store provided.");let a={...o,taskStore:o.taskStore};if(t.inputSchema){let s=r;return await Promise.resolve(s.createTask(n,a))}else{let s=r;return await Promise.resolve(s.createTask(a))}}if(t.inputSchema){let a=r;return await Promise.resolve(a(n,o))}else{let a=r;return await Promise.resolve(a(o))}}async handleAutomaticTaskPolling(t,n,o){if(!o.taskStore)throw new Error("No task store provided for task-capable tool.");let r=await this.validateToolInput(t,n.params.arguments,n.params.name),i=t.handler,a={...o,taskStore:o.taskStore},s=r?await Promise.resolve(i.createTask(r,a)):await Promise.resolve(i.createTask(a)),c=s.task.taskId,l=s.task,d=l.pollInterval??5e3;for(;l.status!=="completed"&&l.status!=="failed"&&l.status!=="cancelled";){await new Promise(_=>setTimeout(_,d));let f=await o.taskStore.getTask(c);if(!f)throw new F(H.InternalError,`Task ${c} not found during polling`);l=f}return await o.taskStore.getTaskResult(c)}setCompletionRequestHandler(){this._completionHandlerInitialized||(this.server.assertCanSetRequestHandler(Zr(Qu)),this.server.registerCapabilities({completions:{}}),this.server.setRequestHandler(Qu,async t=>{switch(t.params.ref.type){case"ref/prompt":return zy(t),this.handlePromptCompletion(t,t.params.ref);case"ref/resource":return Iy(t),this.handleResourceCompletion(t,t.params.ref);default:throw new F(H.InvalidParams,`Invalid completion reference: ${t.params.ref}`)}}),this._completionHandlerInitialized=!0)}async handlePromptCompletion(t,n){let o=this._registeredPrompts[n.name];if(!o)throw new F(H.InvalidParams,`Prompt ${n.name} not found`);if(!o.enabled)throw new F(H.InvalidParams,`Prompt ${n.name} disabled`);if(!o.argsSchema)return Na;let i=Er(o.argsSchema)?.[t.params.argument.name];if(!Hh(i))return Na;let a=Qx(i);if(!a)return Na;let s=await a(t.params.argument.value,t.params.context);return tw(s)}async handleResourceCompletion(t,n){let o=Object.values(this._registeredResourceTemplates).find(a=>a.resourceTemplate.uriTemplate.toString()===n.uri);if(!o){if(this._registeredResources[n.uri])return Na;throw new F(H.InvalidParams,`Resource template ${t.params.ref.uri} not found`)}let r=o.resourceTemplate.completeCallback(t.params.argument.name);if(!r)return Na;let i=await r(t.params.argument.value,t.params.context);return tw(i)}setResourceRequestHandlers(){this._resourceHandlersInitialized||(this.server.assertCanSetRequestHandler(Zr(Ku)),this.server.assertCanSetRequestHandler(Zr(Hu)),this.server.assertCanSetRequestHandler(Zr(Ju)),this.server.registerCapabilities({resources:{listChanged:!0}}),this.server.setRequestHandler(Ku,async(t,n)=>{let o=Object.entries(this._registeredResources).filter(([i,a])=>a.enabled).map(([i,a])=>({uri:i,name:a.name,...a.metadata})),r=[];for(let i of Object.values(this._registeredResourceTemplates)){if(!i.resourceTemplate.listCallback)continue;let a=await i.resourceTemplate.listCallback(n);for(let s of a.resources)r.push({...i.metadata,...s})}return{resources:[...o,...r]}}),this.server.setRequestHandler(Hu,async()=>({resourceTemplates:Object.entries(this._registeredResourceTemplates).map(([n,o])=>({name:n,uriTemplate:o.resourceTemplate.uriTemplate.toString(),...o.metadata}))})),this.server.setRequestHandler(Ju,async(t,n)=>{let o=new URL(t.params.uri),r=this._registeredResources[o.toString()];if(r){if(!r.enabled)throw new F(H.InvalidParams,`Resource ${o} disabled`);return r.readCallback(o,n)}for(let i of Object.values(this._registeredResourceTemplates)){let a=i.resourceTemplate.uriTemplate.match(o.toString());if(a)return i.readCallback(o,a,n)}throw new F(H.InvalidParams,`Resource ${o} not found`)}),this._resourceHandlersInitialized=!0)}setPromptRequestHandlers(){this._promptHandlersInitialized||(this.server.assertCanSetRequestHandler(Zr(Gu)),this.server.assertCanSetRequestHandler(Zr(Wu)),this.server.registerCapabilities({prompts:{listChanged:!0}}),this.server.setRequestHandler(Gu,()=>({prompts:Object.entries(this._registeredPrompts).filter(([,t])=>t.enabled).map(([t,n])=>({name:t,title:n.title,description:n.description,arguments:n.argsSchema?CA(n.argsSchema):void 0}))})),this.server.setRequestHandler(Wu,async(t,n)=>{let o=this._registeredPrompts[t.params.name];if(!o)throw new F(H.InvalidParams,`Prompt ${t.params.name} not found`);if(!o.enabled)throw new F(H.InvalidParams,`Prompt ${t.params.name} disabled`);if(o.argsSchema){let r=co(o.argsSchema),i=await vu(r,t.params.arguments);if(!i.success){let c="error"in i?i.error:"Unknown error",l=_u(c);throw new F(H.InvalidParams,`Invalid arguments for prompt ${t.params.name}: ${l}`)}let a=i.data,s=o.callback;return await Promise.resolve(s(a,n))}else{let r=o.callback;return await Promise.resolve(r(n))}}),this._promptHandlersInitialized=!0)}resource(t,n,...o){let r;typeof o[0]=="object"&&(r=o.shift());let i=o[0];if(typeof n=="string"){if(this._registeredResources[n])throw new Error(`Resource ${n} is already registered`);let a=this._createRegisteredResource(t,void 0,n,r,i);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),a}else{if(this._registeredResourceTemplates[t])throw new Error(`Resource template ${t} is already registered`);let a=this._createRegisteredResourceTemplate(t,void 0,n,r,i);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),a}}registerResource(t,n,o,r){if(typeof n=="string"){if(this._registeredResources[n])throw new Error(`Resource ${n} is already registered`);let i=this._createRegisteredResource(t,o.title,n,o,r);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),i}else{if(this._registeredResourceTemplates[t])throw new Error(`Resource template ${t} is already registered`);let i=this._createRegisteredResourceTemplate(t,o.title,n,o,r);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),i}}_createRegisteredResource(t,n,o,r,i){let a={name:t,title:n,metadata:r,readCallback:i,enabled:!0,disable:()=>a.update({enabled:!1}),enable:()=>a.update({enabled:!0}),remove:()=>a.update({uri:null}),update:s=>{typeof s.uri<"u"&&s.uri!==o&&(delete this._registeredResources[o],s.uri&&(this._registeredResources[s.uri]=a)),typeof s.name<"u"&&(a.name=s.name),typeof s.title<"u"&&(a.title=s.title),typeof s.metadata<"u"&&(a.metadata=s.metadata),typeof s.callback<"u"&&(a.readCallback=s.callback),typeof s.enabled<"u"&&(a.enabled=s.enabled),this.sendResourceListChanged()}};return this._registeredResources[o]=a,a}_createRegisteredResourceTemplate(t,n,o,r,i){let a={resourceTemplate:o,title:n,metadata:r,readCallback:i,enabled:!0,disable:()=>a.update({enabled:!1}),enable:()=>a.update({enabled:!0}),remove:()=>a.update({name:null}),update:l=>{typeof l.name<"u"&&l.name!==t&&(delete this._registeredResourceTemplates[t],l.name&&(this._registeredResourceTemplates[l.name]=a)),typeof l.title<"u"&&(a.title=l.title),typeof l.template<"u"&&(a.resourceTemplate=l.template),typeof l.metadata<"u"&&(a.metadata=l.metadata),typeof l.callback<"u"&&(a.readCallback=l.callback),typeof l.enabled<"u"&&(a.enabled=l.enabled),this.sendResourceListChanged()}};this._registeredResourceTemplates[t]=a;let s=o.uriTemplate.variableNames;return Array.isArray(s)&&s.some(l=>!!o.completeCallback(l))&&this.setCompletionRequestHandler(),a}_createRegisteredPrompt(t,n,o,r,i){let a={title:n,description:o,argsSchema:r===void 0?void 0:tn(r),callback:i,enabled:!0,disable:()=>a.update({enabled:!1}),enable:()=>a.update({enabled:!0}),remove:()=>a.update({name:null}),update:s=>{typeof s.name<"u"&&s.name!==t&&(delete this._registeredPrompts[t],s.name&&(this._registeredPrompts[s.name]=a)),typeof s.title<"u"&&(a.title=s.title),typeof s.description<"u"&&(a.description=s.description),typeof s.argsSchema<"u"&&(a.argsSchema=tn(s.argsSchema)),typeof s.callback<"u"&&(a.callback=s.callback),typeof s.enabled<"u"&&(a.enabled=s.enabled),this.sendPromptListChanged()}};return this._registeredPrompts[t]=a,r&&Object.values(r).some(c=>{let l=c instanceof Ki?c._def?.innerType:c;return Hh(l)})&&this.setCompletionRequestHandler(),a}_createRegisteredTool(t,n,o,r,i,a,s,c,l){Jh(t);let d={title:n,description:o,inputSchema:ew(r),outputSchema:ew(i),annotations:a,execution:s,_meta:c,handler:l,enabled:!0,disable:()=>d.update({enabled:!1}),enable:()=>d.update({enabled:!0}),remove:()=>d.update({name:null}),update:f=>{typeof f.name<"u"&&f.name!==t&&(typeof f.name=="string"&&Jh(f.name),delete this._registeredTools[t],f.name&&(this._registeredTools[f.name]=d)),typeof f.title<"u"&&(d.title=f.title),typeof f.description<"u"&&(d.description=f.description),typeof f.paramsSchema<"u"&&(d.inputSchema=tn(f.paramsSchema)),typeof f.outputSchema<"u"&&(d.outputSchema=tn(f.outputSchema)),typeof f.callback<"u"&&(d.handler=f.callback),typeof f.annotations<"u"&&(d.annotations=f.annotations),typeof f._meta<"u"&&(d._meta=f._meta),typeof f.enabled<"u"&&(d.enabled=f.enabled),this.sendToolListChanged()}};return this._registeredTools[t]=d,this.setToolRequestHandlers(),this.sendToolListChanged(),d}tool(t,...n){if(this._registeredTools[t])throw new Error(`Tool ${t} is already registered`);let o,r,i,a;if(typeof n[0]=="string"&&(o=n.shift()),n.length>1){let c=n[0];Gh(c)?(r=n.shift(),n.length>1&&typeof n[0]=="object"&&n[0]!==null&&!Gh(n[0])&&(a=n.shift())):typeof c=="object"&&c!==null&&(a=n.shift())}let s=n[0];return this._createRegisteredTool(t,void 0,o,r,i,a,{taskSupport:"forbidden"},void 0,s)}registerTool(t,n,o){if(this._registeredTools[t])throw new Error(`Tool ${t} is already registered`);let{title:r,description:i,inputSchema:a,outputSchema:s,annotations:c,_meta:l}=n;return this._createRegisteredTool(t,r,i,a,s,c,{taskSupport:"forbidden"},l,o)}prompt(t,...n){if(this._registeredPrompts[t])throw new Error(`Prompt ${t} is already registered`);let o;typeof n[0]=="string"&&(o=n.shift());let r;n.length>1&&(r=n.shift());let i=n[0],a=this._createRegisteredPrompt(t,void 0,o,r,i);return this.setPromptRequestHandlers(),this.sendPromptListChanged(),a}registerPrompt(t,n,o){if(this._registeredPrompts[t])throw new Error(`Prompt ${t} is already registered`);let{title:r,description:i,argsSchema:a}=n,s=this._createRegisteredPrompt(t,r,i,a,o);return this.setPromptRequestHandlers(),this.sendPromptListChanged(),s}isConnected(){return this.server.transport!==void 0}async sendLoggingMessage(t,n){return this.server.sendLoggingMessage(t,n)}sendResourceListChanged(){this.isConnected()&&this.server.sendResourceListChanged()}sendToolListChanged(){this.isConnected()&&this.server.sendToolListChanged()}sendPromptListChanged(){this.isConnected()&&this.server.sendPromptListChanged()}};var AA={type:"object",properties:{}};function rw(e){return e!==null&&typeof e=="object"&&"parse"in e&&typeof e.parse=="function"&&"safeParse"in e&&typeof e.safeParse=="function"}function DA(e){return"_def"in e||"_zod"in e||rw(e)}function Gh(e){return typeof e!="object"||e===null||DA(e)?!1:Object.keys(e).length===0?!0:Object.values(e).some(rw)}function ew(e){if(e)return Gh(e)?tn(e):e}function CA(e){let t=Er(e);return t?Object.entries(t).map(([n,o])=>{let r=k_(o),i=S_(o);return{name:n,description:r,required:!i}}):[]}function Zr(e){let n=Er(e)?.method;if(!n)throw new Error("Schema is missing a method literal");let o=yu(n);if(typeof o=="string")return o;throw new Error("Schema method literal must be a string")}function tw(e){return{completion:{values:e.slice(0,100),total:e.length,hasMore:e.length>100}}}var Na={completion:{values:[],hasMore:!1}};var Wh=ht(require("node:process"),1);var Bl=class{append(t){this._buffer=this._buffer?Buffer.concat([this._buffer,t]):t}readMessage(){if(!this._buffer)return null;let t=this._buffer.indexOf(`
|
|
61
|
-
`);if(t===-1)return null;let n=this._buffer.toString("utf8",0,t).replace(/\r$/,"");return this._buffer=this._buffer.subarray(t+1),
|
|
62
|
-
`}var
|
|
63
|
-
CREATE TABLE IF NOT EXISTS
|
|
60
|
+
]`;continue}r+=o[c],o[c]==="\\"?i=!0:a&&o[c]==="]"?a=!1:!a&&o[c]==="["&&(a=!0)}try{new RegExp(r)}catch{return console.warn(`Could not convert regex pattern at ${t.currentPath.join("/")} to a flag-independent form! Falling back to the flag-ignorant source`),e.source}return r}function ol(e,t){if(t.target==="openAi"&&console.warn("Warning: OpenAI may not support records in schemas! Try an array of key-value pairs instead."),t.target==="openApi3"&&e.keyType?._def.typeName===P.ZodEnum)return{type:"object",required:e.keyType._def.values,properties:e.keyType._def.values.reduce((o,r)=>({...o,[r]:G(e.valueType._def,{...t,currentPath:[...t.currentPath,"properties",r]})??Ie(t)}),{}),additionalProperties:t.rejectedAdditionalProperties};let n={type:"object",additionalProperties:G(e.valueType._def,{...t,currentPath:[...t.currentPath,"additionalProperties"]})??t.allowedAdditionalProperties};if(t.target==="openApi3")return n;if(e.keyType?._def.typeName===P.ZodString&&e.keyType._def.checks?.length){let{type:o,...r}=nl(e.keyType._def,t);return{...n,propertyNames:r}}else{if(e.keyType?._def.typeName===P.ZodEnum)return{...n,propertyNames:{enum:e.keyType._def.values}};if(e.keyType?._def.typeName===P.ZodBranded&&e.keyType._def.type._def.typeName===P.ZodString&&e.keyType._def.type._def.checks?.length){let{type:o,...r}=rl(e.keyType._def,t);return{...n,propertyNames:r}}}return n}function By(e,t){if(t.mapStrategy==="record")return ol(e,t);let n=G(e.keyType._def,{...t,currentPath:[...t.currentPath,"items","items","0"]})||Ie(t),o=G(e.valueType._def,{...t,currentPath:[...t.currentPath,"items","items","1"]})||Ie(t);return{type:"array",maxItems:125,items:{type:"array",items:[n,o],minItems:2,maxItems:2}}}function Ky(e){let t=e.values,o=Object.keys(e.values).filter(i=>typeof t[t[i]]!="number").map(i=>t[i]),r=Array.from(new Set(o.map(i=>typeof i)));return{type:r.length===1?r[0]==="string"?"string":"number":["string","number"],enum:o}}function Hy(e){return e.target==="openAi"?void 0:{not:Ie({...e,currentPath:[...e.currentPath,"not"]})}}function Jy(e){return e.target==="openApi3"?{enum:["null"],nullable:!0}:{type:"null"}}var na={ZodString:"string",ZodNumber:"number",ZodBigInt:"integer",ZodBoolean:"boolean",ZodNull:"null"};function Wy(e,t){if(t.target==="openApi3")return Gy(e,t);let n=e.options instanceof Map?Array.from(e.options.values()):e.options;if(n.every(o=>o._def.typeName in na&&(!o._def.checks||!o._def.checks.length))){let o=n.reduce((r,i)=>{let a=na[i._def.typeName];return a&&!r.includes(a)?[...r,a]:r},[]);return{type:o.length>1?o:o[0]}}else if(n.every(o=>o._def.typeName==="ZodLiteral"&&!o.description)){let o=n.reduce((r,i)=>{let a=typeof i._def.value;switch(a){case"string":case"number":case"boolean":return[...r,a];case"bigint":return[...r,"integer"];case"object":if(i._def.value===null)return[...r,"null"];default:return r}},[]);if(o.length===n.length){let r=o.filter((i,a,s)=>s.indexOf(i)===a);return{type:r.length>1?r:r[0],enum:n.reduce((i,a)=>i.includes(a._def.value)?i:[...i,a._def.value],[])}}}else if(n.every(o=>o._def.typeName==="ZodEnum"))return{type:"string",enum:n.reduce((o,r)=>[...o,...r._def.values.filter(i=>!o.includes(i))],[])};return Gy(e,t)}var Gy=(e,t)=>{let n=(e.options instanceof Map?Array.from(e.options.values()):e.options).map((o,r)=>G(o._def,{...t,currentPath:[...t.currentPath,"anyOf",`${r}`]})).filter(o=>!!o&&(!t.strictUnions||typeof o=="object"&&Object.keys(o).length>0));return n.length?{anyOf:n}:void 0};function Xy(e,t){if(["ZodString","ZodNumber","ZodBigInt","ZodBoolean","ZodNull"].includes(e.innerType._def.typeName)&&(!e.innerType._def.checks||!e.innerType._def.checks.length))return t.target==="openApi3"?{type:na[e.innerType._def.typeName],nullable:!0}:{type:[na[e.innerType._def.typeName],"null"]};if(t.target==="openApi3"){let o=G(e.innerType._def,{...t,currentPath:[...t.currentPath]});return o&&"$ref"in o?{allOf:[o],nullable:!0}:o&&{...o,nullable:!0}}let n=G(e.innerType._def,{...t,currentPath:[...t.currentPath,"anyOf","0"]});return n&&{anyOf:[n,{type:"null"}]}}function Yy(e,t){let n={type:"number"};if(!e.checks)return n;for(let o of e.checks)switch(o.kind){case"int":n.type="integer",Gp(n,"type",o.message,t);break;case"min":t.target==="jsonSchema7"?o.inclusive?ue(n,"minimum",o.value,o.message,t):ue(n,"exclusiveMinimum",o.value,o.message,t):(o.inclusive||(n.exclusiveMinimum=!0),ue(n,"minimum",o.value,o.message,t));break;case"max":t.target==="jsonSchema7"?o.inclusive?ue(n,"maximum",o.value,o.message,t):ue(n,"exclusiveMaximum",o.value,o.message,t):(o.inclusive||(n.exclusiveMaximum=!0),ue(n,"maximum",o.value,o.message,t));break;case"multipleOf":ue(n,"multipleOf",o.value,o.message,t);break}return n}function Qy(e,t){let n=t.target==="openAi",o={type:"object",properties:{}},r=[],i=e.shape();for(let s in i){let c=i[s];if(c===void 0||c._def===void 0)continue;let l=FO(c);l&&n&&(c._def.typeName==="ZodOptional"&&(c=c._def.innerType),c.isNullable()||(c=c.nullable()),l=!1);let d=G(c._def,{...t,currentPath:[...t.currentPath,"properties",s],propertyPath:[...t.currentPath,"properties",s]});d!==void 0&&(o.properties[s]=d,l||r.push(s))}r.length&&(o.required=r);let a=VO(e,t);return a!==void 0&&(o.additionalProperties=a),o}function VO(e,t){if(e.catchall._def.typeName!=="ZodNever")return G(e.catchall._def,{...t,currentPath:[...t.currentPath,"additionalProperties"]});switch(e.unknownKeys){case"passthrough":return t.allowedAdditionalProperties;case"strict":return t.rejectedAdditionalProperties;case"strip":return t.removeAdditionalStrategy==="strict"?t.allowedAdditionalProperties:t.rejectedAdditionalProperties}}function FO(e){try{return e.isOptional()}catch{return!0}}var eb=(e,t)=>{if(t.currentPath.toString()===t.propertyPath?.toString())return G(e.innerType._def,t);let n=G(e.innerType._def,{...t,currentPath:[...t.currentPath,"anyOf","1"]});return n?{anyOf:[{not:Ie(t)},n]}:Ie(t)};var tb=(e,t)=>{if(t.pipeStrategy==="input")return G(e.in._def,t);if(t.pipeStrategy==="output")return G(e.out._def,t);let n=G(e.in._def,{...t,currentPath:[...t.currentPath,"allOf","0"]}),o=G(e.out._def,{...t,currentPath:[...t.currentPath,"allOf",n?"1":"0"]});return{allOf:[n,o].filter(r=>r!==void 0)}};function rb(e,t){return G(e.type._def,t)}function nb(e,t){let o={type:"array",uniqueItems:!0,items:G(e.valueType._def,{...t,currentPath:[...t.currentPath,"items"]})};return e.minSize&&ue(o,"minItems",e.minSize.value,e.minSize.message,t),e.maxSize&&ue(o,"maxItems",e.maxSize.value,e.maxSize.message,t),o}function ob(e,t){return e.rest?{type:"array",minItems:e.items.length,items:e.items.map((n,o)=>G(n._def,{...t,currentPath:[...t.currentPath,"items",`${o}`]})).reduce((n,o)=>o===void 0?n:[...n,o],[]),additionalItems:G(e.rest._def,{...t,currentPath:[...t.currentPath,"additionalItems"]})}:{type:"array",minItems:e.items.length,maxItems:e.items.length,items:e.items.map((n,o)=>G(n._def,{...t,currentPath:[...t.currentPath,"items",`${o}`]})).reduce((n,o)=>o===void 0?n:[...n,o],[])}}function ib(e){return{not:Ie(e)}}function ab(e){return Ie(e)}var sb=(e,t)=>G(e.innerType._def,t);var cb=(e,t,n)=>{switch(t){case P.ZodString:return nl(e,n);case P.ZodNumber:return Yy(e,n);case P.ZodObject:return Qy(e,n);case P.ZodBigInt:return Dy(e,n);case P.ZodBoolean:return Cy();case P.ZodDate:return Wp(e,n);case P.ZodUndefined:return ib(n);case P.ZodNull:return Jy(n);case P.ZodArray:return Ay(e,n);case P.ZodUnion:case P.ZodDiscriminatedUnion:return Wy(e,n);case P.ZodIntersection:return qy(e,n);case P.ZodTuple:return ob(e,n);case P.ZodRecord:return ol(e,n);case P.ZodLiteral:return Vy(e,n);case P.ZodEnum:return Ly(e);case P.ZodNativeEnum:return Ky(e);case P.ZodNullable:return Xy(e,n);case P.ZodOptional:return eb(e,n);case P.ZodMap:return By(e,n);case P.ZodSet:return nb(e,n);case P.ZodLazy:return()=>e.getter()._def;case P.ZodPromise:return rb(e,n);case P.ZodNaN:case P.ZodNever:return Hy(n);case P.ZodEffects:return My(e,n);case P.ZodAny:return Ie(n);case P.ZodUnknown:return ab(n);case P.ZodDefault:return Zy(e,n);case P.ZodBranded:return rl(e,n);case P.ZodReadonly:return sb(e,n);case P.ZodCatch:return Uy(e,n);case P.ZodPipeline:return tb(e,n);case P.ZodFunction:case P.ZodVoid:case P.ZodSymbol:return;default:return(o=>{})(t)}};function G(e,t,n=!1){let o=t.seen.get(e);if(t.override){let s=t.override?.(e,t,o,n);if(s!==jy)return s}if(o&&!n){let s=BO(o,t);if(s!==void 0)return s}let r={def:e,path:t.currentPath,jsonSchema:void 0};t.seen.set(e,r);let i=cb(e,e.typeName,t),a=typeof i=="function"?G(i(),t):i;if(a&&KO(e,t,a),t.postProcess){let s=t.postProcess(a,e,t);return r.jsonSchema=a,s}return r.jsonSchema=a,a}var BO=(e,t)=>{switch(t.$refStrategy){case"root":return{$ref:e.path.join("/")};case"relative":return{$ref:tl(t.currentPath,e.path)};case"none":case"seen":return e.path.length<t.currentPath.length&&e.path.every((n,o)=>t.currentPath[o]===n)?(console.warn(`Recursive reference detected at ${t.currentPath.join("/")}! Defaulting to any`),Ie(t)):t.$refStrategy==="seen"?Ie(t):void 0}},KO=(e,t,n)=>(e.description&&(n.description=e.description,t.markdownDescription&&(n.markdownDescription=e.description)),n);var Qp=(e,t)=>{let n=Ry(t),o=typeof t=="object"&&t.definitions?Object.entries(t.definitions).reduce((c,[l,d])=>({...c,[l]:G(d._def,{...n,currentPath:[...n.basePath,n.definitionPath,l]},!0)??Ie(n)}),{}):void 0,r=typeof t=="string"?t:t?.nameStrategy==="title"?void 0:t?.name,i=G(e._def,r===void 0?n:{...n,currentPath:[...n.basePath,n.definitionPath,r]},!1)??Ie(n),a=typeof t=="object"&&t.name!==void 0&&t.nameStrategy==="title"?t.name:void 0;a!==void 0&&(i.title=a),n.flags.hasReferencedOpenAiAnyType&&(o||(o={}),o[n.openAiAnyTypeName]||(o[n.openAiAnyTypeName]={type:["string","number","integer","boolean","array","null"],items:{$ref:n.$refStrategy==="relative"?"1":[...n.basePath,n.definitionPath,n.openAiAnyTypeName].join("/")}}));let s=r===void 0?o?{...i,[n.definitionPath]:o}:i:{$ref:[...n.$refStrategy==="relative"?[]:n.basePath,n.definitionPath,r].join("/"),[n.definitionPath]:{...o,[r]:i}};return n.target==="jsonSchema7"?s.$schema="http://json-schema.org/draft-07/schema#":(n.target==="jsonSchema2019-09"||n.target==="openAi")&&(s.$schema="https://json-schema.org/draft/2019-09/schema#"),n.target==="openAi"&&("anyOf"in s||"oneOf"in s||"allOf"in s||"type"in s&&Array.isArray(s.type))&&console.warn("Warning: OpenAI may not support schemas with unions as roots! Try wrapping it in an object property."),s};function HO(e){return!e||e==="jsonSchema7"||e==="draft-7"?"draft-7":e==="jsonSchema2019-09"||e==="draft-2020-12"?"draft-2020-12":"draft-7"}function em(e,t){return vt(e)?so(e,{target:HO(t?.target),io:t?.pipeStrategy??"input"}):Qp(e,{strictUnions:t?.strictUnions??!0,pipeStrategy:t?.pipeStrategy??"input"})}function tm(e){let n=Er(e)?.method;if(!n)throw new Error("Schema is missing a method literal");let o=bu(n);if(typeof o!="string")throw new Error("Schema method literal must be a string");return o}function rm(e,t){let n=Ir(e,t);if(!n.success)throw n.error;return n.data}var JO=6e4,il=class{constructor(t){this._options=t,this._requestMessageId=0,this._requestHandlers=new Map,this._requestHandlerAbortControllers=new Map,this._notificationHandlers=new Map,this._responseHandlers=new Map,this._progressHandlers=new Map,this._timeoutInfo=new Map,this._pendingDebouncedNotifications=new Set,this._taskProgressTokens=new Map,this._requestResolvers=new Map,this.setNotificationHandler(Uu,n=>{this._oncancel(n)}),this.setNotificationHandler(Mu,n=>{this._onprogress(n)}),this.setRequestHandler(Zu,n=>({})),this._taskStore=t?.taskStore,this._taskMessageQueue=t?.taskMessageQueue,this._taskStore&&(this.setRequestHandler(Lu,async(n,o)=>{let r=await this._taskStore.getTask(n.params.taskId,o.sessionId);if(!r)throw new F(H.InvalidParams,"Failed to retrieve task: Task not found");return{...r}}),this.setRequestHandler(Vu,async(n,o)=>{let r=async()=>{let i=n.params.taskId;if(this._taskMessageQueue){let s;for(;s=await this._taskMessageQueue.dequeue(i,o.sessionId);){if(s.type==="response"||s.type==="error"){let c=s.message,l=c.id,d=this._requestResolvers.get(l);if(d)if(this._requestResolvers.delete(l),s.type==="response")d(c);else{let f=c,_=new F(f.error.code,f.error.message,f.error.data);d(_)}else{let f=s.type==="response"?"Response":"Error";this._onerror(new Error(`${f} handler missing for request ${l}`))}continue}await this._transport?.send(s.message,{relatedRequestId:o.requestId})}}let a=await this._taskStore.getTask(i,o.sessionId);if(!a)throw new F(H.InvalidParams,`Task not found: ${i}`);if(!Or(a.status))return await this._waitForTaskUpdate(i,o.signal),await r();if(Or(a.status)){let s=await this._taskStore.getTaskResult(i,o.sessionId);return this._clearTaskQueue(i),{...s,_meta:{...s._meta,[Tr]:{taskId:i}}}}return await r()};return await r()}),this.setRequestHandler(Fu,async(n,o)=>{try{let{tasks:r,nextCursor:i}=await this._taskStore.listTasks(n.params?.cursor,o.sessionId);return{tasks:r,nextCursor:i,_meta:{}}}catch(r){throw new F(H.InvalidParams,`Failed to list tasks: ${r instanceof Error?r.message:String(r)}`)}}),this.setRequestHandler(Ku,async(n,o)=>{try{let r=await this._taskStore.getTask(n.params.taskId,o.sessionId);if(!r)throw new F(H.InvalidParams,`Task not found: ${n.params.taskId}`);if(Or(r.status))throw new F(H.InvalidParams,`Cannot cancel task in terminal status: ${r.status}`);await this._taskStore.updateTaskStatus(n.params.taskId,"cancelled","Client cancelled task execution.",o.sessionId),this._clearTaskQueue(n.params.taskId);let i=await this._taskStore.getTask(n.params.taskId,o.sessionId);if(!i)throw new F(H.InvalidParams,`Task not found after cancellation: ${n.params.taskId}`);return{_meta:{},...i}}catch(r){throw r instanceof F?r:new F(H.InvalidRequest,`Failed to cancel task: ${r instanceof Error?r.message:String(r)}`)}}))}async _oncancel(t){if(!t.params.requestId)return;this._requestHandlerAbortControllers.get(t.params.requestId)?.abort(t.params.reason)}_setupTimeout(t,n,o,r,i=!1){this._timeoutInfo.set(t,{timeoutId:setTimeout(r,n),startTime:Date.now(),timeout:n,maxTotalTimeout:o,resetTimeoutOnProgress:i,onTimeout:r})}_resetTimeout(t){let n=this._timeoutInfo.get(t);if(!n)return!1;let o=Date.now()-n.startTime;if(n.maxTotalTimeout&&o>=n.maxTotalTimeout)throw this._timeoutInfo.delete(t),F.fromError(H.RequestTimeout,"Maximum total timeout exceeded",{maxTotalTimeout:n.maxTotalTimeout,totalElapsed:o});return clearTimeout(n.timeoutId),n.timeoutId=setTimeout(n.onTimeout,n.timeout),!0}_cleanupTimeout(t){let n=this._timeoutInfo.get(t);n&&(clearTimeout(n.timeoutId),this._timeoutInfo.delete(t))}async connect(t){if(this._transport)throw new Error("Already connected to a transport. Call close() before connecting to a new transport, or use a separate Protocol instance per connection.");this._transport=t;let n=this.transport?.onclose;this._transport.onclose=()=>{n?.(),this._onclose()};let o=this.transport?.onerror;this._transport.onerror=i=>{o?.(i),this._onerror(i)};let r=this._transport?.onmessage;this._transport.onmessage=(i,a)=>{r?.(i,a),Ji(i)||by(i)?this._onresponse(i):Ap(i)?this._onrequest(i,a):yy(i)?this._onnotification(i):this._onerror(new Error(`Unknown message type: ${JSON.stringify(i)}`))},await this._transport.start()}_onclose(){let t=this._responseHandlers;this._responseHandlers=new Map,this._progressHandlers.clear(),this._taskProgressTokens.clear(),this._pendingDebouncedNotifications.clear();for(let o of this._requestHandlerAbortControllers.values())o.abort();this._requestHandlerAbortControllers.clear();let n=F.fromError(H.ConnectionClosed,"Connection closed");this._transport=void 0,this.onclose?.();for(let o of t.values())o(n)}_onerror(t){this.onerror?.(t)}_onnotification(t){let n=this._notificationHandlers.get(t.method)??this.fallbackNotificationHandler;n!==void 0&&Promise.resolve().then(()=>n(t)).catch(o=>this._onerror(new Error(`Uncaught error in notification handler: ${o}`)))}_onrequest(t,n){let o=this._requestHandlers.get(t.method)??this.fallbackRequestHandler,r=this._transport,i=t.params?._meta?.[Tr]?.taskId;if(o===void 0){let d={jsonrpc:"2.0",id:t.id,error:{code:H.MethodNotFound,message:"Method not found"}};i&&this._taskMessageQueue?this._enqueueTaskMessage(i,{type:"error",message:d,timestamp:Date.now()},r?.sessionId).catch(f=>this._onerror(new Error(`Failed to enqueue error response: ${f}`))):r?.send(d).catch(f=>this._onerror(new Error(`Failed to send an error response: ${f}`)));return}let a=new AbortController;this._requestHandlerAbortControllers.set(t.id,a);let s=gy(t.params)?t.params.task:void 0,c=this._taskStore?this.requestTaskStore(t,r?.sessionId):void 0,l={signal:a.signal,sessionId:r?.sessionId,_meta:t.params?._meta,sendNotification:async d=>{if(a.signal.aborted)return;let f={relatedRequestId:t.id};i&&(f.relatedTask={taskId:i}),await this.notification(d,f)},sendRequest:async(d,f,_)=>{if(a.signal.aborted)throw new F(H.ConnectionClosed,"Request was cancelled");let v={..._,relatedRequestId:t.id};i&&!v.relatedTask&&(v.relatedTask={taskId:i});let g=v.relatedTask?.taskId??i;return g&&c&&await c.updateTaskStatus(g,"input_required"),await this.request(d,f,v)},authInfo:n?.authInfo,requestId:t.id,requestInfo:n?.requestInfo,taskId:i,taskStore:c,taskRequestedTtl:s?.ttl,closeSSEStream:n?.closeSSEStream,closeStandaloneSSEStream:n?.closeStandaloneSSEStream};Promise.resolve().then(()=>{s&&this.assertTaskHandlerCapability(t.method)}).then(()=>o(t,l)).then(async d=>{if(a.signal.aborted)return;let f={result:d,jsonrpc:"2.0",id:t.id};i&&this._taskMessageQueue?await this._enqueueTaskMessage(i,{type:"response",message:f,timestamp:Date.now()},r?.sessionId):await r?.send(f)},async d=>{if(a.signal.aborted)return;let f={jsonrpc:"2.0",id:t.id,error:{code:Number.isSafeInteger(d.code)?d.code:H.InternalError,message:d.message??"Internal error",...d.data!==void 0&&{data:d.data}}};i&&this._taskMessageQueue?await this._enqueueTaskMessage(i,{type:"error",message:f,timestamp:Date.now()},r?.sessionId):await r?.send(f)}).catch(d=>this._onerror(new Error(`Failed to send response: ${d}`))).finally(()=>{this._requestHandlerAbortControllers.delete(t.id)})}_onprogress(t){let{progressToken:n,...o}=t.params,r=Number(n),i=this._progressHandlers.get(r);if(!i){this._onerror(new Error(`Received a progress notification for an unknown token: ${JSON.stringify(t)}`));return}let a=this._responseHandlers.get(r),s=this._timeoutInfo.get(r);if(s&&a&&s.resetTimeoutOnProgress)try{this._resetTimeout(r)}catch(c){this._responseHandlers.delete(r),this._progressHandlers.delete(r),this._cleanupTimeout(r),a(c);return}i(o)}_onresponse(t){let n=Number(t.id),o=this._requestResolvers.get(n);if(o){if(this._requestResolvers.delete(n),Ji(t))o(t);else{let a=new F(t.error.code,t.error.message,t.error.data);o(a)}return}let r=this._responseHandlers.get(n);if(r===void 0){this._onerror(new Error(`Received a response for an unknown message ID: ${JSON.stringify(t)}`));return}this._responseHandlers.delete(n),this._cleanupTimeout(n);let i=!1;if(Ji(t)&&t.result&&typeof t.result=="object"){let a=t.result;if(a.task&&typeof a.task=="object"){let s=a.task;typeof s.taskId=="string"&&(i=!0,this._taskProgressTokens.set(s.taskId,n))}}if(i||this._progressHandlers.delete(n),Ji(t))r(t);else{let a=F.fromError(t.error.code,t.error.message,t.error.data);r(a)}}get transport(){return this._transport}async close(){await this._transport?.close()}async*requestStream(t,n,o){let{task:r}=o??{};if(!r){try{yield{type:"result",result:await this.request(t,n,o)}}catch(a){yield{type:"error",error:a instanceof F?a:new F(H.InternalError,String(a))}}return}let i;try{let a=await this.request(t,po,o);if(a.task)i=a.task.taskId,yield{type:"taskCreated",task:a.task};else throw new F(H.InternalError,"Task creation did not return a task");for(;;){let s=await this.getTask({taskId:i},o);if(yield{type:"taskStatus",task:s},Or(s.status)){s.status==="completed"?yield{type:"result",result:await this.getTaskResult({taskId:i},n,o)}:s.status==="failed"?yield{type:"error",error:new F(H.InternalError,`Task ${i} failed`)}:s.status==="cancelled"&&(yield{type:"error",error:new F(H.InternalError,`Task ${i} was cancelled`)});return}if(s.status==="input_required"){yield{type:"result",result:await this.getTaskResult({taskId:i},n,o)};return}let c=s.pollInterval??this._options?.defaultTaskPollInterval??1e3;await new Promise(l=>setTimeout(l,c)),o?.signal?.throwIfAborted()}}catch(a){yield{type:"error",error:a instanceof F?a:new F(H.InternalError,String(a))}}}request(t,n,o){let{relatedRequestId:r,resumptionToken:i,onresumptiontoken:a,task:s,relatedTask:c}=o??{};return new Promise((l,d)=>{let f=R=>{d(R)};if(!this._transport){f(new Error("Not connected"));return}if(this._options?.enforceStrictCapabilities===!0)try{this.assertCapabilityForMethod(t.method),s&&this.assertTaskCapability(t.method)}catch(R){f(R);return}o?.signal?.throwIfAborted();let _=this._requestMessageId++,v={...t,jsonrpc:"2.0",id:_};o?.onprogress&&(this._progressHandlers.set(_,o.onprogress),v.params={...t.params,_meta:{...t.params?._meta||{},progressToken:_}}),s&&(v.params={...v.params,task:s}),c&&(v.params={...v.params,_meta:{...v.params?._meta||{},[Tr]:c}});let g=R=>{this._responseHandlers.delete(_),this._progressHandlers.delete(_),this._cleanupTimeout(_),this._transport?.send({jsonrpc:"2.0",method:"notifications/cancelled",params:{requestId:_,reason:String(R)}},{relatedRequestId:r,resumptionToken:i,onresumptiontoken:a}).catch(M=>this._onerror(new Error(`Failed to send cancellation: ${M}`)));let O=R instanceof F?R:new F(H.RequestTimeout,String(R));d(O)};this._responseHandlers.set(_,R=>{if(!o?.signal?.aborted){if(R instanceof Error)return d(R);try{let O=Ir(n,R.result);O.success?l(O.data):d(O.error)}catch(O){d(O)}}}),o?.signal?.addEventListener("abort",()=>{g(o?.signal?.reason)});let b=o?.timeout??JO,x=()=>g(F.fromError(H.RequestTimeout,"Request timed out",{timeout:b}));this._setupTimeout(_,b,o?.maxTotalTimeout,x,o?.resetTimeoutOnProgress??!1);let I=c?.taskId;if(I){let R=O=>{let M=this._responseHandlers.get(_);M?M(O):this._onerror(new Error(`Response handler missing for side-channeled request ${_}`))};this._requestResolvers.set(_,R),this._enqueueTaskMessage(I,{type:"request",message:v,timestamp:Date.now()}).catch(O=>{this._cleanupTimeout(_),d(O)})}else this._transport.send(v,{relatedRequestId:r,resumptionToken:i,onresumptiontoken:a}).catch(R=>{this._cleanupTimeout(_),d(R)})})}async getTask(t,n){return this.request({method:"tasks/get",params:t},qu,n)}async getTaskResult(t,n,o){return this.request({method:"tasks/result",params:t},n,o)}async listTasks(t,n){return this.request({method:"tasks/list",params:t},Bu,n)}async cancelTask(t,n){return this.request({method:"tasks/cancel",params:t},wy,n)}async notification(t,n){if(!this._transport)throw new Error("Not connected");this.assertNotificationCapability(t.method);let o=n?.relatedTask?.taskId;if(o){let s={...t,jsonrpc:"2.0",params:{...t.params,_meta:{...t.params?._meta||{},[Tr]:n.relatedTask}}};await this._enqueueTaskMessage(o,{type:"notification",message:s,timestamp:Date.now()});return}if((this._options?.debouncedNotificationMethods??[]).includes(t.method)&&!t.params&&!n?.relatedRequestId&&!n?.relatedTask){if(this._pendingDebouncedNotifications.has(t.method))return;this._pendingDebouncedNotifications.add(t.method),Promise.resolve().then(()=>{if(this._pendingDebouncedNotifications.delete(t.method),!this._transport)return;let s={...t,jsonrpc:"2.0"};n?.relatedTask&&(s={...s,params:{...s.params,_meta:{...s.params?._meta||{},[Tr]:n.relatedTask}}}),this._transport?.send(s,n).catch(c=>this._onerror(c))});return}let a={...t,jsonrpc:"2.0"};n?.relatedTask&&(a={...a,params:{...a.params,_meta:{...a.params?._meta||{},[Tr]:n.relatedTask}}}),await this._transport.send(a,n)}setRequestHandler(t,n){let o=tm(t);this.assertRequestHandlerCapability(o),this._requestHandlers.set(o,(r,i)=>{let a=rm(t,r);return Promise.resolve(n(a,i))})}removeRequestHandler(t){this._requestHandlers.delete(t)}assertCanSetRequestHandler(t){if(this._requestHandlers.has(t))throw new Error(`A request handler for ${t} already exists, which would be overridden`)}setNotificationHandler(t,n){let o=tm(t);this._notificationHandlers.set(o,r=>{let i=rm(t,r);return Promise.resolve(n(i))})}removeNotificationHandler(t){this._notificationHandlers.delete(t)}_cleanupTaskProgressHandler(t){let n=this._taskProgressTokens.get(t);n!==void 0&&(this._progressHandlers.delete(n),this._taskProgressTokens.delete(t))}async _enqueueTaskMessage(t,n,o){if(!this._taskStore||!this._taskMessageQueue)throw new Error("Cannot enqueue task message: taskStore and taskMessageQueue are not configured");let r=this._options?.maxTaskQueueSize;await this._taskMessageQueue.enqueue(t,n,o,r)}async _clearTaskQueue(t,n){if(this._taskMessageQueue){let o=await this._taskMessageQueue.dequeueAll(t,n);for(let r of o)if(r.type==="request"&&Ap(r.message)){let i=r.message.id,a=this._requestResolvers.get(i);a?(a(new F(H.InternalError,"Task cancelled or completed")),this._requestResolvers.delete(i)):this._onerror(new Error(`Resolver missing for request ${i} during task ${t} cleanup`))}}}async _waitForTaskUpdate(t,n){let o=this._options?.defaultTaskPollInterval??1e3;try{let r=await this._taskStore?.getTask(t);r?.pollInterval&&(o=r.pollInterval)}catch{}return new Promise((r,i)=>{if(n.aborted){i(new F(H.InvalidRequest,"Request cancelled"));return}let a=setTimeout(r,o);n.addEventListener("abort",()=>{clearTimeout(a),i(new F(H.InvalidRequest,"Request cancelled"))},{once:!0})})}requestTaskStore(t,n){let o=this._taskStore;if(!o)throw new Error("No task store configured");return{createTask:async r=>{if(!t)throw new Error("No request provided");return await o.createTask(r,t.id,{method:t.method,params:t.params},n)},getTask:async r=>{let i=await o.getTask(r,n);if(!i)throw new F(H.InvalidParams,"Failed to retrieve task: Task not found");return i},storeTaskResult:async(r,i,a)=>{await o.storeTaskResult(r,i,a,n);let s=await o.getTask(r,n);if(s){let c=Qi.parse({method:"notifications/tasks/status",params:s});await this.notification(c),Or(s.status)&&this._cleanupTaskProgressHandler(r)}},getTaskResult:r=>o.getTaskResult(r,n),updateTaskStatus:async(r,i,a)=>{let s=await o.getTask(r,n);if(!s)throw new F(H.InvalidParams,`Task "${r}" not found - it may have been cleaned up`);if(Or(s.status))throw new F(H.InvalidParams,`Cannot update task "${r}" from terminal status "${s.status}" to "${i}". Terminal states (completed, failed, cancelled) cannot transition to other states.`);await o.updateTaskStatus(r,i,a,n);let c=await o.getTask(r,n);if(c){let l=Qi.parse({method:"notifications/tasks/status",params:c});await this.notification(l),Or(c.status)&&this._cleanupTaskProgressHandler(r)}},listTasks:r=>o.listTasks(r,n)}}};function ub(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function lb(e,t){let n={...e};for(let o in t){let r=o,i=t[r];if(i===void 0)continue;let a=n[r];ub(a)&&ub(i)?n[r]={...a,...i}:n[r]=i}return n}var Wx=ht(Lh(),1),Xx=ht(Gx(),1);function ZA(){let e=new Wx.default({strict:!1,validateFormats:!0,validateSchema:!1,allErrors:!0});return(0,Xx.default)(e),e}var Ll=class{constructor(t){this._ajv=t??ZA()}getValidator(t){let n="$id"in t&&typeof t.$id=="string"?this._ajv.getSchema(t.$id)??this._ajv.compile(t):this._ajv.compile(t);return o=>n(o)?{valid:!0,data:o,errorMessage:void 0}:{valid:!1,data:void 0,errorMessage:this._ajv.errorsText(n.errors)}}};var ql=class{constructor(t){this._server=t}requestStream(t,n,o){return this._server.requestStream(t,n,o)}createMessageStream(t,n){let o=this._server.getClientCapabilities();if((t.tools||t.toolChoice)&&!o?.sampling?.tools)throw new Error("Client does not support sampling tools capability.");if(t.messages.length>0){let r=t.messages[t.messages.length-1],i=Array.isArray(r.content)?r.content:[r.content],a=i.some(d=>d.type==="tool_result"),s=t.messages.length>1?t.messages[t.messages.length-2]:void 0,c=s?Array.isArray(s.content)?s.content:[s.content]:[],l=c.some(d=>d.type==="tool_use");if(a){if(i.some(d=>d.type!=="tool_result"))throw new Error("The last message must contain only tool_result content if any is present");if(!l)throw new Error("tool_result blocks are not matching any tool_use from the previous message")}if(l){let d=new Set(c.filter(_=>_.type==="tool_use").map(_=>_.id)),f=new Set(i.filter(_=>_.type==="tool_result").map(_=>_.toolUseId));if(d.size!==f.size||![...d].every(_=>f.has(_)))throw new Error("ids of tool_result blocks and tool_use blocks from previous message do not match")}}return this.requestStream({method:"sampling/createMessage",params:t},ra,n)}elicitInputStream(t,n){let o=this._server.getClientCapabilities(),r=t.mode??"form";switch(r){case"url":{if(!o?.elicitation?.url)throw new Error("Client does not support url elicitation.");break}case"form":{if(!o?.elicitation?.form)throw new Error("Client does not support form elicitation.");break}}let i=r==="form"&&t.mode===void 0?{...t,mode:"form"}:t;return this.requestStream({method:"elicitation/create",params:i},go,n)}async getTask(t,n){return this._server.getTask({taskId:t},n)}async getTaskResult(t,n,o){return this._server.getTaskResult({taskId:t},n,o)}async listTasks(t,n){return this._server.listTasks(t?{cursor:t}:void 0,n)}async cancelTask(t,n){return this._server.cancelTask({taskId:t},n)}};function Yx(e,t,n){if(!e)throw new Error(`${n} does not support task creation (required for ${t})`);switch(t){case"tools/call":if(!e.tools?.call)throw new Error(`${n} does not support task creation for tools/call (required for ${t})`);break;default:break}}function Qx(e,t,n){if(!e)throw new Error(`${n} does not support task creation (required for ${t})`);switch(t){case"sampling/createMessage":if(!e.sampling?.createMessage)throw new Error(`${n} does not support task creation for sampling/createMessage (required for ${t})`);break;case"elicitation/create":if(!e.elicitation?.create)throw new Error(`${n} does not support task creation for elicitation/create (required for ${t})`);break;default:break}}var Vl=class extends il{constructor(t,n){super(n),this._serverInfo=t,this._loggingLevels=new Map,this.LOG_LEVEL_SEVERITY=new Map(ta.options.map((o,r)=>[o,r])),this.isMessageIgnored=(o,r)=>{let i=this._loggingLevels.get(r);return i?this.LOG_LEVEL_SEVERITY.get(o)<this.LOG_LEVEL_SEVERITY.get(i):!1},this._capabilities=n?.capabilities??{},this._instructions=n?.instructions,this._jsonSchemaValidator=n?.jsonSchemaValidator??new Ll,this.setRequestHandler(Up,o=>this._oninitialize(o)),this.setNotificationHandler(Zp,()=>this.oninitialized?.()),this._capabilities.logging&&this.setRequestHandler(Kp,async(o,r)=>{let i=r.sessionId||r.requestInfo?.headers["mcp-session-id"]||void 0,{level:a}=o.params,s=ta.safeParse(a);return s.success&&this._loggingLevels.set(i,s.data),{}})}get experimental(){return this._experimental||(this._experimental={tasks:new ql(this)}),this._experimental}registerCapabilities(t){if(this.transport)throw new Error("Cannot register capabilities after connecting to transport");this._capabilities=lb(this._capabilities,t)}setRequestHandler(t,n){let r=Er(t)?.method;if(!r)throw new Error("Schema is missing a method literal");let i;if(vt(r)){let s=r;i=s._zod?.def?.value??s.value}else{let s=r;i=s._def?.value??s.value}if(typeof i!="string")throw new Error("Schema method literal must be a string");if(i==="tools/call"){let s=async(c,l)=>{let d=Ir(ho,c);if(!d.success){let g=d.error instanceof Error?d.error.message:String(d.error);throw new F(H.InvalidParams,`Invalid tools/call request: ${g}`)}let{params:f}=d.data,_=await Promise.resolve(n(c,l));if(f.task){let g=Ir(po,_);if(!g.success){let b=g.error instanceof Error?g.error.message:String(g.error);throw new F(H.InvalidParams,`Invalid task creation result: ${b}`)}return g.data}let v=Ir(Qu,_);if(!v.success){let g=v.error instanceof Error?v.error.message:String(v.error);throw new F(H.InvalidParams,`Invalid tools/call result: ${g}`)}return v.data};return super.setRequestHandler(t,s)}return super.setRequestHandler(t,n)}assertCapabilityForMethod(t){switch(t){case"sampling/createMessage":if(!this._clientCapabilities?.sampling)throw new Error(`Client does not support sampling (required for ${t})`);break;case"elicitation/create":if(!this._clientCapabilities?.elicitation)throw new Error(`Client does not support elicitation (required for ${t})`);break;case"roots/list":if(!this._clientCapabilities?.roots)throw new Error(`Client does not support listing roots (required for ${t})`);break;case"ping":break}}assertNotificationCapability(t){switch(t){case"notifications/message":if(!this._capabilities.logging)throw new Error(`Server does not support logging (required for ${t})`);break;case"notifications/resources/updated":case"notifications/resources/list_changed":if(!this._capabilities.resources)throw new Error(`Server does not support notifying about resources (required for ${t})`);break;case"notifications/tools/list_changed":if(!this._capabilities.tools)throw new Error(`Server does not support notifying of tool list changes (required for ${t})`);break;case"notifications/prompts/list_changed":if(!this._capabilities.prompts)throw new Error(`Server does not support notifying of prompt list changes (required for ${t})`);break;case"notifications/elicitation/complete":if(!this._clientCapabilities?.elicitation?.url)throw new Error(`Client does not support URL elicitation (required for ${t})`);break;case"notifications/cancelled":break;case"notifications/progress":break}}assertRequestHandlerCapability(t){if(this._capabilities)switch(t){case"completion/complete":if(!this._capabilities.completions)throw new Error(`Server does not support completions (required for ${t})`);break;case"logging/setLevel":if(!this._capabilities.logging)throw new Error(`Server does not support logging (required for ${t})`);break;case"prompts/get":case"prompts/list":if(!this._capabilities.prompts)throw new Error(`Server does not support prompts (required for ${t})`);break;case"resources/list":case"resources/templates/list":case"resources/read":if(!this._capabilities.resources)throw new Error(`Server does not support resources (required for ${t})`);break;case"tools/call":case"tools/list":if(!this._capabilities.tools)throw new Error(`Server does not support tools (required for ${t})`);break;case"tasks/get":case"tasks/list":case"tasks/result":case"tasks/cancel":if(!this._capabilities.tasks)throw new Error(`Server does not support tasks capability (required for ${t})`);break;case"ping":case"initialize":break}}assertTaskCapability(t){Qx(this._clientCapabilities?.tasks?.requests,t,"Client")}assertTaskHandlerCapability(t){this._capabilities&&Yx(this._capabilities.tasks?.requests,t,"Server")}async _oninitialize(t){let n=t.params.protocolVersion;return this._clientCapabilities=t.params.capabilities,this._clientVersion=t.params.clientInfo,{protocolVersion:py.includes(n)?n:Np,capabilities:this.getCapabilities(),serverInfo:this._serverInfo,...this._instructions&&{instructions:this._instructions}}}getClientCapabilities(){return this._clientCapabilities}getClientVersion(){return this._clientVersion}getCapabilities(){return this._capabilities}async ping(){return this.request({method:"ping"},Cu)}async createMessage(t,n){if((t.tools||t.toolChoice)&&!this._clientCapabilities?.sampling?.tools)throw new Error("Client does not support sampling tools capability.");if(t.messages.length>0){let o=t.messages[t.messages.length-1],r=Array.isArray(o.content)?o.content:[o.content],i=r.some(l=>l.type==="tool_result"),a=t.messages.length>1?t.messages[t.messages.length-2]:void 0,s=a?Array.isArray(a.content)?a.content:[a.content]:[],c=s.some(l=>l.type==="tool_use");if(i){if(r.some(l=>l.type!=="tool_result"))throw new Error("The last message must contain only tool_result content if any is present");if(!c)throw new Error("tool_result blocks are not matching any tool_use from the previous message")}if(c){let l=new Set(s.filter(f=>f.type==="tool_use").map(f=>f.id)),d=new Set(r.filter(f=>f.type==="tool_result").map(f=>f.toolUseId));if(l.size!==d.size||![...l].every(f=>d.has(f)))throw new Error("ids of tool_result blocks and tool_use blocks from previous message do not match")}}return t.tools?this.request({method:"sampling/createMessage",params:t},Hp,n):this.request({method:"sampling/createMessage",params:t},ra,n)}async elicitInput(t,n){switch(t.mode??"form"){case"url":{if(!this._clientCapabilities?.elicitation?.url)throw new Error("Client does not support url elicitation.");let r=t;return this.request({method:"elicitation/create",params:r},go,n)}case"form":{if(!this._clientCapabilities?.elicitation?.form)throw new Error("Client does not support form elicitation.");let r=t.mode==="form"?t:{...t,mode:"form"},i=await this.request({method:"elicitation/create",params:r},go,n);if(i.action==="accept"&&i.content&&r.requestedSchema)try{let s=this._jsonSchemaValidator.getValidator(r.requestedSchema)(i.content);if(!s.valid)throw new F(H.InvalidParams,`Elicitation response content does not match requested schema: ${s.errorMessage}`)}catch(a){throw a instanceof F?a:new F(H.InternalError,`Error validating elicitation response: ${a instanceof Error?a.message:String(a)}`)}return i}}}createElicitationCompletionNotifier(t,n){if(!this._clientCapabilities?.elicitation?.url)throw new Error("Client does not support URL elicitation (required for notifications/elicitation/complete)");return()=>this.notification({method:"notifications/elicitation/complete",params:{elicitationId:t}},n)}async listRoots(t,n){return this.request({method:"roots/list",params:t},Jp,n)}async sendLoggingMessage(t,n){if(this._capabilities.logging&&!this.isMessageIgnored(t.level,n))return this.notification({method:"notifications/message",params:t})}async sendResourceUpdated(t){return this.notification({method:"notifications/resources/updated",params:t})}async sendResourceListChanged(){return this.notification({method:"notifications/resources/list_changed"})}async sendToolListChanged(){return this.notification({method:"notifications/tools/list_changed"})}async sendPromptListChanged(){return this.notification({method:"notifications/prompts/list_changed"})}};var tw=Symbol.for("mcp.completable");function Gh(e){return!!e&&typeof e=="object"&&tw in e}function rw(e){return e[tw]?.complete}var ew;(function(e){e.Completable="McpCompletable"})(ew||(ew={}));var MA=/^[A-Za-z0-9._-]{1,128}$/;function LA(e){let t=[];if(e.length===0)return{isValid:!1,warnings:["Tool name cannot be empty"]};if(e.length>128)return{isValid:!1,warnings:[`Tool name exceeds maximum length of 128 characters (current: ${e.length})`]};if(e.includes(" ")&&t.push("Tool name contains spaces, which may cause parsing issues"),e.includes(",")&&t.push("Tool name contains commas, which may cause parsing issues"),(e.startsWith("-")||e.endsWith("-"))&&t.push("Tool name starts or ends with a dash, which may cause parsing issues in some contexts"),(e.startsWith(".")||e.endsWith("."))&&t.push("Tool name starts or ends with a dot, which may cause parsing issues in some contexts"),!MA.test(e)){let n=e.split("").filter(o=>!/[A-Za-z0-9._-]/.test(o)).filter((o,r,i)=>i.indexOf(o)===r);return t.push(`Tool name contains invalid characters: ${n.map(o=>`"${o}"`).join(", ")}`,"Allowed characters are: A-Z, a-z, 0-9, underscore (_), dash (-), and dot (.)"),{isValid:!1,warnings:t}}return{isValid:!0,warnings:t}}function qA(e,t){if(t.length>0){console.warn(`Tool name validation warning for "${e}":`);for(let n of t)console.warn(` - ${n}`);console.warn("Tool registration will proceed, but this may cause compatibility issues."),console.warn("Consider updating the tool name to conform to the MCP tool naming standard."),console.warn("See SEP: Specify Format for Tool Names (https://github.com/modelcontextprotocol/modelcontextprotocol/issues/986) for more details.")}}function Wh(e){let t=LA(e);return qA(e,t.warnings),t.isValid}var Fl=class{constructor(t){this._mcpServer=t}registerToolTask(t,n,o){let r={taskSupport:"required",...n.execution};if(r.taskSupport==="forbidden")throw new Error(`Cannot register task-based tool '${t}' with taskSupport 'forbidden'. Use registerTool() instead.`);return this._mcpServer._createRegisteredTool(t,n.title,n.description,n.inputSchema,n.outputSchema,n.annotations,r,n._meta,o)}};var Bl=class{constructor(t,n){this._registeredResources={},this._registeredResourceTemplates={},this._registeredTools={},this._registeredPrompts={},this._toolHandlersInitialized=!1,this._completionHandlerInitialized=!1,this._resourceHandlersInitialized=!1,this._promptHandlersInitialized=!1,this.server=new Vl(t,n)}get experimental(){return this._experimental||(this._experimental={tasks:new Fl(this)}),this._experimental}async connect(t){return await this.server.connect(t)}async close(){await this.server.close()}setToolRequestHandlers(){this._toolHandlersInitialized||(this.server.assertCanSetRequestHandler(Zr(Yu)),this.server.assertCanSetRequestHandler(Zr(ho)),this.server.registerCapabilities({tools:{listChanged:!0}}),this.server.setRequestHandler(Yu,()=>({tools:Object.entries(this._registeredTools).filter(([,t])=>t.enabled).map(([t,n])=>{let o={name:t,title:n.title,description:n.description,inputSchema:(()=>{let r=co(n.inputSchema);return r?em(r,{strictUnions:!0,pipeStrategy:"input"}):VA})(),annotations:n.annotations,execution:n.execution,_meta:n._meta};if(n.outputSchema){let r=co(n.outputSchema);r&&(o.outputSchema=em(r,{strictUnions:!0,pipeStrategy:"output"}))}return o})})),this.server.setRequestHandler(ho,async(t,n)=>{try{let o=this._registeredTools[t.params.name];if(!o)throw new F(H.InvalidParams,`Tool ${t.params.name} not found`);if(!o.enabled)throw new F(H.InvalidParams,`Tool ${t.params.name} disabled`);let r=!!t.params.task,i=o.execution?.taskSupport,a="createTask"in o.handler;if((i==="required"||i==="optional")&&!a)throw new F(H.InternalError,`Tool ${t.params.name} has taskSupport '${i}' but was not registered with registerToolTask`);if(i==="required"&&!r)throw new F(H.MethodNotFound,`Tool ${t.params.name} requires task augmentation (taskSupport: 'required')`);if(i==="optional"&&!r&&a)return await this.handleAutomaticTaskPolling(o,t,n);let s=await this.validateToolInput(o,t.params.arguments,t.params.name),c=await this.executeToolHandler(o,s,n);return r||await this.validateToolOutput(o,c,t.params.name),c}catch(o){if(o instanceof F&&o.code===H.UrlElicitationRequired)throw o;return this.createToolError(o instanceof Error?o.message:String(o))}}),this._toolHandlersInitialized=!0)}createToolError(t){return{content:[{type:"text",text:t}],isError:!0}}async validateToolInput(t,n,o){if(!t.inputSchema)return;let i=co(t.inputSchema)??t.inputSchema,a=await _u(i,n);if(!a.success){let s="error"in a?a.error:"Unknown error",c=yu(s);throw new F(H.InvalidParams,`Input validation error: Invalid arguments for tool ${o}: ${c}`)}return a.data}async validateToolOutput(t,n,o){if(!t.outputSchema||!("content"in n)||n.isError)return;if(!n.structuredContent)throw new F(H.InvalidParams,`Output validation error: Tool ${o} has an output schema but no structured content was provided`);let r=co(t.outputSchema),i=await _u(r,n.structuredContent);if(!i.success){let a="error"in i?i.error:"Unknown error",s=yu(a);throw new F(H.InvalidParams,`Output validation error: Invalid structured content for tool ${o}: ${s}`)}}async executeToolHandler(t,n,o){let r=t.handler;if("createTask"in r){if(!o.taskStore)throw new Error("No task store provided.");let a={...o,taskStore:o.taskStore};if(t.inputSchema){let s=r;return await Promise.resolve(s.createTask(n,a))}else{let s=r;return await Promise.resolve(s.createTask(a))}}if(t.inputSchema){let a=r;return await Promise.resolve(a(n,o))}else{let a=r;return await Promise.resolve(a(o))}}async handleAutomaticTaskPolling(t,n,o){if(!o.taskStore)throw new Error("No task store provided for task-capable tool.");let r=await this.validateToolInput(t,n.params.arguments,n.params.name),i=t.handler,a={...o,taskStore:o.taskStore},s=r?await Promise.resolve(i.createTask(r,a)):await Promise.resolve(i.createTask(a)),c=s.task.taskId,l=s.task,d=l.pollInterval??5e3;for(;l.status!=="completed"&&l.status!=="failed"&&l.status!=="cancelled";){await new Promise(_=>setTimeout(_,d));let f=await o.taskStore.getTask(c);if(!f)throw new F(H.InternalError,`Task ${c} not found during polling`);l=f}return await o.taskStore.getTaskResult(c)}setCompletionRequestHandler(){this._completionHandlerInitialized||(this.server.assertCanSetRequestHandler(Zr(el)),this.server.registerCapabilities({completions:{}}),this.server.setRequestHandler(el,async t=>{switch(t.params.ref.type){case"ref/prompt":return Ty(t),this.handlePromptCompletion(t,t.params.ref);case"ref/resource":return Oy(t),this.handleResourceCompletion(t,t.params.ref);default:throw new F(H.InvalidParams,`Invalid completion reference: ${t.params.ref}`)}}),this._completionHandlerInitialized=!0)}async handlePromptCompletion(t,n){let o=this._registeredPrompts[n.name];if(!o)throw new F(H.InvalidParams,`Prompt ${n.name} not found`);if(!o.enabled)throw new F(H.InvalidParams,`Prompt ${n.name} disabled`);if(!o.argsSchema)return Na;let i=Er(o.argsSchema)?.[t.params.argument.name];if(!Gh(i))return Na;let a=rw(i);if(!a)return Na;let s=await a(t.params.argument.value,t.params.context);return ow(s)}async handleResourceCompletion(t,n){let o=Object.values(this._registeredResourceTemplates).find(a=>a.resourceTemplate.uriTemplate.toString()===n.uri);if(!o){if(this._registeredResources[n.uri])return Na;throw new F(H.InvalidParams,`Resource template ${t.params.ref.uri} not found`)}let r=o.resourceTemplate.completeCallback(t.params.argument.name);if(!r)return Na;let i=await r(t.params.argument.value,t.params.context);return ow(i)}setResourceRequestHandlers(){this._resourceHandlersInitialized||(this.server.assertCanSetRequestHandler(Zr(Hu)),this.server.assertCanSetRequestHandler(Zr(Ju)),this.server.assertCanSetRequestHandler(Zr(Gu)),this.server.registerCapabilities({resources:{listChanged:!0}}),this.server.setRequestHandler(Hu,async(t,n)=>{let o=Object.entries(this._registeredResources).filter(([i,a])=>a.enabled).map(([i,a])=>({uri:i,name:a.name,...a.metadata})),r=[];for(let i of Object.values(this._registeredResourceTemplates)){if(!i.resourceTemplate.listCallback)continue;let a=await i.resourceTemplate.listCallback(n);for(let s of a.resources)r.push({...i.metadata,...s})}return{resources:[...o,...r]}}),this.server.setRequestHandler(Ju,async()=>({resourceTemplates:Object.entries(this._registeredResourceTemplates).map(([n,o])=>({name:n,uriTemplate:o.resourceTemplate.uriTemplate.toString(),...o.metadata}))})),this.server.setRequestHandler(Gu,async(t,n)=>{let o=new URL(t.params.uri),r=this._registeredResources[o.toString()];if(r){if(!r.enabled)throw new F(H.InvalidParams,`Resource ${o} disabled`);return r.readCallback(o,n)}for(let i of Object.values(this._registeredResourceTemplates)){let a=i.resourceTemplate.uriTemplate.match(o.toString());if(a)return i.readCallback(o,a,n)}throw new F(H.InvalidParams,`Resource ${o} not found`)}),this._resourceHandlersInitialized=!0)}setPromptRequestHandlers(){this._promptHandlersInitialized||(this.server.assertCanSetRequestHandler(Zr(Wu)),this.server.assertCanSetRequestHandler(Zr(Xu)),this.server.registerCapabilities({prompts:{listChanged:!0}}),this.server.setRequestHandler(Wu,()=>({prompts:Object.entries(this._registeredPrompts).filter(([,t])=>t.enabled).map(([t,n])=>({name:t,title:n.title,description:n.description,arguments:n.argsSchema?BA(n.argsSchema):void 0}))})),this.server.setRequestHandler(Xu,async(t,n)=>{let o=this._registeredPrompts[t.params.name];if(!o)throw new F(H.InvalidParams,`Prompt ${t.params.name} not found`);if(!o.enabled)throw new F(H.InvalidParams,`Prompt ${t.params.name} disabled`);if(o.argsSchema){let r=co(o.argsSchema),i=await _u(r,t.params.arguments);if(!i.success){let c="error"in i?i.error:"Unknown error",l=yu(c);throw new F(H.InvalidParams,`Invalid arguments for prompt ${t.params.name}: ${l}`)}let a=i.data,s=o.callback;return await Promise.resolve(s(a,n))}else{let r=o.callback;return await Promise.resolve(r(n))}}),this._promptHandlersInitialized=!0)}resource(t,n,...o){let r;typeof o[0]=="object"&&(r=o.shift());let i=o[0];if(typeof n=="string"){if(this._registeredResources[n])throw new Error(`Resource ${n} is already registered`);let a=this._createRegisteredResource(t,void 0,n,r,i);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),a}else{if(this._registeredResourceTemplates[t])throw new Error(`Resource template ${t} is already registered`);let a=this._createRegisteredResourceTemplate(t,void 0,n,r,i);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),a}}registerResource(t,n,o,r){if(typeof n=="string"){if(this._registeredResources[n])throw new Error(`Resource ${n} is already registered`);let i=this._createRegisteredResource(t,o.title,n,o,r);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),i}else{if(this._registeredResourceTemplates[t])throw new Error(`Resource template ${t} is already registered`);let i=this._createRegisteredResourceTemplate(t,o.title,n,o,r);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),i}}_createRegisteredResource(t,n,o,r,i){let a={name:t,title:n,metadata:r,readCallback:i,enabled:!0,disable:()=>a.update({enabled:!1}),enable:()=>a.update({enabled:!0}),remove:()=>a.update({uri:null}),update:s=>{typeof s.uri<"u"&&s.uri!==o&&(delete this._registeredResources[o],s.uri&&(this._registeredResources[s.uri]=a)),typeof s.name<"u"&&(a.name=s.name),typeof s.title<"u"&&(a.title=s.title),typeof s.metadata<"u"&&(a.metadata=s.metadata),typeof s.callback<"u"&&(a.readCallback=s.callback),typeof s.enabled<"u"&&(a.enabled=s.enabled),this.sendResourceListChanged()}};return this._registeredResources[o]=a,a}_createRegisteredResourceTemplate(t,n,o,r,i){let a={resourceTemplate:o,title:n,metadata:r,readCallback:i,enabled:!0,disable:()=>a.update({enabled:!1}),enable:()=>a.update({enabled:!0}),remove:()=>a.update({name:null}),update:l=>{typeof l.name<"u"&&l.name!==t&&(delete this._registeredResourceTemplates[t],l.name&&(this._registeredResourceTemplates[l.name]=a)),typeof l.title<"u"&&(a.title=l.title),typeof l.template<"u"&&(a.resourceTemplate=l.template),typeof l.metadata<"u"&&(a.metadata=l.metadata),typeof l.callback<"u"&&(a.readCallback=l.callback),typeof l.enabled<"u"&&(a.enabled=l.enabled),this.sendResourceListChanged()}};this._registeredResourceTemplates[t]=a;let s=o.uriTemplate.variableNames;return Array.isArray(s)&&s.some(l=>!!o.completeCallback(l))&&this.setCompletionRequestHandler(),a}_createRegisteredPrompt(t,n,o,r,i){let a={title:n,description:o,argsSchema:r===void 0?void 0:tn(r),callback:i,enabled:!0,disable:()=>a.update({enabled:!1}),enable:()=>a.update({enabled:!0}),remove:()=>a.update({name:null}),update:s=>{typeof s.name<"u"&&s.name!==t&&(delete this._registeredPrompts[t],s.name&&(this._registeredPrompts[s.name]=a)),typeof s.title<"u"&&(a.title=s.title),typeof s.description<"u"&&(a.description=s.description),typeof s.argsSchema<"u"&&(a.argsSchema=tn(s.argsSchema)),typeof s.callback<"u"&&(a.callback=s.callback),typeof s.enabled<"u"&&(a.enabled=s.enabled),this.sendPromptListChanged()}};return this._registeredPrompts[t]=a,r&&Object.values(r).some(c=>{let l=c instanceof Ki?c._def?.innerType:c;return Gh(l)})&&this.setCompletionRequestHandler(),a}_createRegisteredTool(t,n,o,r,i,a,s,c,l){Wh(t);let d={title:n,description:o,inputSchema:nw(r),outputSchema:nw(i),annotations:a,execution:s,_meta:c,handler:l,enabled:!0,disable:()=>d.update({enabled:!1}),enable:()=>d.update({enabled:!0}),remove:()=>d.update({name:null}),update:f=>{typeof f.name<"u"&&f.name!==t&&(typeof f.name=="string"&&Wh(f.name),delete this._registeredTools[t],f.name&&(this._registeredTools[f.name]=d)),typeof f.title<"u"&&(d.title=f.title),typeof f.description<"u"&&(d.description=f.description),typeof f.paramsSchema<"u"&&(d.inputSchema=tn(f.paramsSchema)),typeof f.outputSchema<"u"&&(d.outputSchema=tn(f.outputSchema)),typeof f.callback<"u"&&(d.handler=f.callback),typeof f.annotations<"u"&&(d.annotations=f.annotations),typeof f._meta<"u"&&(d._meta=f._meta),typeof f.enabled<"u"&&(d.enabled=f.enabled),this.sendToolListChanged()}};return this._registeredTools[t]=d,this.setToolRequestHandlers(),this.sendToolListChanged(),d}tool(t,...n){if(this._registeredTools[t])throw new Error(`Tool ${t} is already registered`);let o,r,i,a;if(typeof n[0]=="string"&&(o=n.shift()),n.length>1){let c=n[0];Xh(c)?(r=n.shift(),n.length>1&&typeof n[0]=="object"&&n[0]!==null&&!Xh(n[0])&&(a=n.shift())):typeof c=="object"&&c!==null&&(a=n.shift())}let s=n[0];return this._createRegisteredTool(t,void 0,o,r,i,a,{taskSupport:"forbidden"},void 0,s)}registerTool(t,n,o){if(this._registeredTools[t])throw new Error(`Tool ${t} is already registered`);let{title:r,description:i,inputSchema:a,outputSchema:s,annotations:c,_meta:l}=n;return this._createRegisteredTool(t,r,i,a,s,c,{taskSupport:"forbidden"},l,o)}prompt(t,...n){if(this._registeredPrompts[t])throw new Error(`Prompt ${t} is already registered`);let o;typeof n[0]=="string"&&(o=n.shift());let r;n.length>1&&(r=n.shift());let i=n[0],a=this._createRegisteredPrompt(t,void 0,o,r,i);return this.setPromptRequestHandlers(),this.sendPromptListChanged(),a}registerPrompt(t,n,o){if(this._registeredPrompts[t])throw new Error(`Prompt ${t} is already registered`);let{title:r,description:i,argsSchema:a}=n,s=this._createRegisteredPrompt(t,r,i,a,o);return this.setPromptRequestHandlers(),this.sendPromptListChanged(),s}isConnected(){return this.server.transport!==void 0}async sendLoggingMessage(t,n){return this.server.sendLoggingMessage(t,n)}sendResourceListChanged(){this.isConnected()&&this.server.sendResourceListChanged()}sendToolListChanged(){this.isConnected()&&this.server.sendToolListChanged()}sendPromptListChanged(){this.isConnected()&&this.server.sendPromptListChanged()}};var VA={type:"object",properties:{}};function iw(e){return e!==null&&typeof e=="object"&&"parse"in e&&typeof e.parse=="function"&&"safeParse"in e&&typeof e.safeParse=="function"}function FA(e){return"_def"in e||"_zod"in e||iw(e)}function Xh(e){return typeof e!="object"||e===null||FA(e)?!1:Object.keys(e).length===0?!0:Object.values(e).some(iw)}function nw(e){if(e)return Xh(e)?tn(e):e}function BA(e){let t=Er(e);return t?Object.entries(t).map(([n,o])=>{let r=I_(o),i=E_(o);return{name:n,description:r,required:!i}}):[]}function Zr(e){let n=Er(e)?.method;if(!n)throw new Error("Schema is missing a method literal");let o=bu(n);if(typeof o=="string")return o;throw new Error("Schema method literal must be a string")}function ow(e){return{completion:{values:e.slice(0,100),total:e.length,hasMore:e.length>100}}}var Na={completion:{values:[],hasMore:!1}};var Yh=ht(require("node:process"),1);var Kl=class{append(t){this._buffer=this._buffer?Buffer.concat([this._buffer,t]):t}readMessage(){if(!this._buffer)return null;let t=this._buffer.indexOf(`
|
|
61
|
+
`);if(t===-1)return null;let n=this._buffer.toString("utf8",0,t).replace(/\r$/,"");return this._buffer=this._buffer.subarray(t+1),KA(n)}clear(){this._buffer=void 0}};function KA(e){return $y.parse(JSON.parse(e))}function aw(e){return JSON.stringify(e)+`
|
|
62
|
+
`}var Hl=class{constructor(t=Yh.default.stdin,n=Yh.default.stdout){this._stdin=t,this._stdout=n,this._readBuffer=new Kl,this._started=!1,this._ondata=o=>{this._readBuffer.append(o),this.processReadBuffer()},this._onerror=o=>{this.onerror?.(o)}}async start(){if(this._started)throw new Error("StdioServerTransport already started! If using Server class, note that connect() calls start() automatically.");this._started=!0,this._stdin.on("data",this._ondata),this._stdin.on("error",this._onerror)}processReadBuffer(){for(;;)try{let t=this._readBuffer.readMessage();if(t===null)break;this.onmessage?.(t)}catch(t){this.onerror?.(t)}}async close(){this._stdin.off("data",this._ondata),this._stdin.off("error",this._onerror),this._stdin.listenerCount("data")===0&&this._stdin.pause(),this._readBuffer.clear(),this.onclose?.()}send(t){return new Promise(n=>{let o=aw(t);this._stdout.write(o)?n():this._stdout.once("drain",n)})}};var Jl="0.4.0";var dg=require("child_process");var lg=ht(Ow()),l4="ed1a4165d4f8fd836bf16f3ca1915a67",cg=!1,ug=!1,d4=["error","manual"],Aa="[REDACTED]",f4=[/password/i,/passphrase/i,/passwd/i,/pwd/i,/token/i,/secret/i,/authorization/i,/cookie/i,/api[_-]?key/i,/apple[_-]?id/i,/username/i,/account[_-]?name/i,/email/i,/security[_-]?code/i,/spawnargs/i],p4=/^[\[{].*[\]}]$/s,m4=new Set(["-w","--password","--passphrase","--token","--authorization"]),h4=[/("appleid"\s*:\s*")[^"]*(")/gi,/("username"\s*:\s*")[^"]*(")/gi,/("accountname"\s*:\s*")[^"]*(")/gi,/("email"\s*:\s*")[^"]*(")/gi,/("password"\s*:\s*")[^"]*(")/gi,/("passphrase"\s*:\s*")[^"]*(")/gi,/("passwd"\s*:\s*")[^"]*(")/gi,/("pwd"\s*:\s*")[^"]*(")/gi,/("token"\s*:\s*")[^"]*(")/gi,/("authorization"\s*:\s*")[^"]*(")/gi,/("cookie"\s*:\s*")[^"]*(")/gi,/("secret"\s*:\s*")[^"]*(")/gi],g4=new Set(["password","passphrase","passwd","pwd","token","authorization","cookie","setcookie","apikey","appleid","username","accountname","email","secret","securitycode"]);function v4(e){return e.toLowerCase().replace(/[^a-z0-9]/g,"")}function sg(e){let t=v4(e);return t?g4.has(t)?!0:t.includes("password")||t.includes("passphrase")||t.includes("passwd")||t.includes("token")||t.includes("secret")||t.includes("authorization")||t.includes("cookie"):!1}function Pw(e){let t=e;for(let n of h4)t=t.replace(n,`$1${Aa}$2`);return t}function jw(e){let t=e.trim();if(t&&p4.test(t))try{return JSON.stringify(Yl(JSON.parse(t)))}catch{return Pw(e)}return Pw(e)}function _4(e){let t=e.map(n=>Yl(n));for(let n=0;n<t.length;n+=1){let o=t[n];if(typeof o!="string")continue;let r=o.trim().toLowerCase();if(m4.has(r)&&n+1<t.length){t[n+1]=Aa;continue}r.startsWith("-w")&&r.length>2&&(t[n]="-w[REDACTED]")}return t}function Yl(e,t=""){if(e==null)return e;if(Array.isArray(e))return _4(e);if(typeof e=="string")return t&&sg(t)?Aa:jw(e);if(typeof e!="object")return t&&sg(t)?Aa:e;let n=e,o={};for(let[r,i]of Object.entries(n)){if(sg(r)){o[r]=Aa;continue}o[r]=Yl(i,r)}return o}function y4(e){if(Array.isArray(e?.errors))for(let t of e.errors)!t||typeof t!="object"||typeof t.errorMessage=="string"&&(t.errorMessage=jw(t.errorMessage))}function b4(e){if(!e||typeof e.getMetadata!="function")return;let t=e.getMetadata();if(!(!t||typeof t!="object"))for(let[n,o]of Object.entries(t)){typeof e.clearMetadata=="function"&&e.clearMetadata(n);let r=Yl(o,n);if(r&&typeof r=="object"&&!Array.isArray(r)){e.addMetadata(n,r);continue}e.addMetadata(n,{value:r})}}function $4(e){b4(e),y4(e)}function x4(e){if(e instanceof Error)return e;if(typeof e=="string")return new Error(e);try{return new Error(JSON.stringify(e))}catch{return new Error(String(e))}}function Nw(e){cg||(ug=e.isDevelopment,!ug&&(lg.default.start({apiKey:l4,autoTrackSessions:!1,appVersion:e.appVersion,logger:null,redactedKeys:f4,enabledBreadcrumbTypes:e.enabledBreadcrumbTypes??d4,onError:t=>{$4(t)}}),cg=!0))}function Rw(e,t={},n){!cg||ug||lg.default.notify(x4(e),o=>{o.addMetadata("metadata",t),n&&n(o)})}var w4=process.env.NODE_ENV=="development";Nw({isDevelopment:w4,appVersion:Jl});var Lw=ht(require("fs")),qw=ht(require("path"));var k4=new Set(["actionable_bug","apple_contract_change","upstream_terminal_failure","unknown"]),S4=new Set(["INVALID_REQUEST","PAYLOAD_TOO_LARGE","AUTH_REQUIRED","AUTH_IN_PROGRESS","TTY_REQUIRED","AUTHORIZATION_FAILED","NOT_FOUND"]),z4=new Set(["invalid_credentials","two_factor_required","upgrade_required"]);function Aw(e){if(!(!e||typeof e!="object"||Array.isArray(e)))return e}function Dw(e){if(typeof e=="number"&&Number.isFinite(e))return e;if(typeof e=="string"&&e.trim()!==""){let t=Number(e);if(Number.isFinite(t))return t}}function Qe(e){if(typeof e!="string")return;let t=e.trim();return t===""?void 0:t}function Ql(e){let t=Aw(e.telemetryHint);if(t)return{classification:Qe(t.classification),isTerminal:typeof t.isTerminal=="boolean"?t.isTerminal:void 0,isUserFault:typeof t.isUserFault=="boolean"?t.isUserFault:void 0,source:Qe(t.source),operation:Qe(t.operation),surface:Qe(t.surface),statusCode:Dw(t.statusCode),errorCode:Qe(t.errorCode),tool:Qe(t.tool),stage:Qe(t.stage),upstreamProvider:Qe(t.upstreamProvider)}}function ed(e){return Aw(e)}function I4(e,t){let n=Ql(t);if(n?.statusCode!=null)return n.statusCode;let o=ed(e);return Dw(o?.status??o?.statusCode??t.statusCode)}function E4(e,t){let n=Ql(t);if(n?.errorCode)return n.errorCode;let o=ed(e);return Qe(o?.errorCode??o?.code??t.errorCode)}function T4(e){let t=ed(e);return Qe(t?.name)==="DashboardApiError"}function O4(e){let t=ed(e);return Qe(t?.name)==="AppleAuthResponseError"}function P4(e){if(!(e instanceof Error))return!1;let t=e.message.toLowerCase();return t.includes("invalid apple id credentials")||t.includes("invalid credentials")||t.includes("incorrect verification code")}function j4(e){if(!(e instanceof Error))return!1;let t=e.message.toLowerCase();return t.includes("primary app id")&&(t.includes("not accessible")||t.includes("you can access"))}function N4(e,t){let n=Ql(t);if(n?.classification)return{report:k4.has(n.classification),classification:n.classification,reason:"explicit_hint_classification"};if(n?.isUserFault)return{report:!1,classification:"user_fault",reason:"explicit_hint_user_fault"};if(O4(e)){let a=Qe(e.reason);return a&&z4.has(a)?{report:!1,classification:"user_fault",reason:`apple_auth_${a}`}:{report:!0,classification:"apple_contract_change",reason:`apple_auth_${a??"unknown"}`}}if(n?.isTerminal===!1)return{report:!1,classification:"transient_non_terminal",reason:"explicit_hint_non_terminal"};if(n?.upstreamProvider&&n?.isTerminal===!0)return{report:!0,classification:"upstream_terminal_failure",reason:"explicit_hint_terminal_upstream"};if(P4(e))return{report:!1,classification:"user_fault",reason:"credential_user_fault_message"};let o=I4(e,t),r=E4(e,t);if(T4(e)&&o!=null&&o>=400&&o<500)return{report:!1,classification:"expected_flow",reason:"dashboard_api_4xx"};if(r&&S4.has(r))return{report:!1,classification:"expected_flow",reason:`dashboard_error_code_${r}`};if(j4(e))return{report:!1,classification:"expected_flow",reason:"primary_app_setup_flow"};if(o!=null&&o>=400&&o<500)return{report:!1,classification:"validation_error",reason:"generic_4xx"}}function Cw(e,t={}){let n=N4(e,t);return n||{report:!0,classification:"unknown",reason:"default_report"}}function Uw(e,t){let n=Ql(e),o=Qe(e.surface)??n?.surface??"unknown",r=Qe(e.source)??n?.source??"unknown",i=Qe(e.operation)??n?.operation??"unknown",a=typeof e.isTerminal=="boolean"?e.isTerminal:n?.isTerminal??null;return{...e,surface:o,source:r,operation:i,isTerminal:a,telemetryClassification:t.classification,telemetryDecisionReason:t.reason}}var R4="__asoBugsnagMetadata";function A4(e){if(!(!e||typeof e!="object"||Array.isArray(e)))return e}function Zw(e){if(e instanceof Error)return A4(e[R4])}function Mw(e){if(!(!e||typeof e!="object"||Array.isArray(e)))return e}function cr(e,t={}){let n=Zw(e)||{},o={...t,...n},r={...Mw(t.telemetryHint)||{},...Mw(n.telemetryHint)||{}};Object.keys(r).length>0&&(o.telemetryHint=r);let i=Cw(e,o);i.report&&Rw(e,Uw(o,i))}function D4(){let e=[qw.default.resolve(__dirname,"cli.js")];for(let t of e)if(Lw.default.existsSync(t))return t;return null}function C4(e){let t=D4();return t?(0,dg.spawn)(process.execPath,[t,...e],{env:process.env}):(0,dg.spawn)("aso",e,{env:process.env})}function Vw(e){return new Promise((t,n)=>{let o,r=typeof e[0]=="string"?e[0]:"unknown";try{o=C4(e)}catch(s){cr(s,{command:r,argCount:e.length,stage:"spawn",surface:"aso-mcp",telemetryHint:{classification:"actionable_bug",surface:"aso-mcp",source:"mcp.execute-aso-cli.spawn",stage:"spawn",tool:"aso_evaluate_keywords"}}),n(s);return}let i="",a="";o.stdout?.on("data",s=>{i+=s.toString()}),o.stderr?.on("data",s=>{a+=s.toString()}),o.on("close",s=>{t({stdout:i,stderr:a,exitCode:s??1})}),o.on("error",s=>{cr(s,{command:r,argCount:e.length,stage:"transport",surface:"aso-mcp",telemetryHint:{classification:"actionable_bug",surface:"aso-mcp",source:"mcp.execute-aso-cli.transport",stage:"transport",tool:"aso_evaluate_keywords"}}),t({stdout:i,stderr:s.message,exitCode:1})})})}function Fw(e){return e.exitCode!==0?{content:[{type:"text",text:`Error: ${e.stderr||e.stdout}`}],isError:!0}:{content:[{type:"text",text:e.stdout}]}}var Bw="research",U4="research:",td=Bw,Kw="Research";function Hw(e){let t=e.trim().toLowerCase();return t?t===Bw||t.startsWith(U4):!1}var rd=ht(require("fs")),pn=ht(require("path")),Jw=ht(require("os")),Gw=ht(require("better-sqlite3")),Z4=pn.join(Jw.homedir(),".aso"),M4=pn.join(Z4,"aso-db.sqlite"),Da=null;function L4(){let e=process.env.ASO_DB_PATH;return e&&e.trim()!==""?pn.resolve(e):M4}function q4(e){e.pragma("journal_mode = WAL"),e.pragma("foreign_keys = ON"),e.exec(`
|
|
63
|
+
CREATE TABLE IF NOT EXISTS owned_apps (
|
|
64
64
|
id TEXT PRIMARY KEY,
|
|
65
|
-
|
|
65
|
+
kind TEXT NOT NULL CHECK (kind IN ('owned', 'research')),
|
|
66
|
+
name TEXT NOT NULL,
|
|
67
|
+
average_user_rating REAL,
|
|
68
|
+
user_rating_count INTEGER,
|
|
69
|
+
previous_average_user_rating REAL,
|
|
70
|
+
previous_user_rating_count INTEGER,
|
|
71
|
+
icon_json TEXT,
|
|
72
|
+
expires_at TEXT,
|
|
73
|
+
last_fetched_at TEXT,
|
|
74
|
+
previous_fetched_at TEXT
|
|
66
75
|
);
|
|
76
|
+
CREATE INDEX IF NOT EXISTS idx_owned_apps_kind
|
|
77
|
+
ON owned_apps(kind);
|
|
67
78
|
|
|
68
79
|
CREATE TABLE IF NOT EXISTS aso_keywords (
|
|
69
80
|
country TEXT NOT NULL,
|
|
@@ -85,23 +96,18 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
85
96
|
ON aso_keywords(country, order_expires_at);
|
|
86
97
|
|
|
87
98
|
CREATE TABLE IF NOT EXISTS aso_apps (
|
|
88
|
-
bucket TEXT NOT NULL,
|
|
89
99
|
country TEXT NOT NULL,
|
|
90
100
|
app_id TEXT NOT NULL,
|
|
91
101
|
name TEXT NOT NULL,
|
|
92
102
|
subtitle TEXT,
|
|
93
103
|
average_user_rating REAL NOT NULL,
|
|
94
104
|
user_rating_count INTEGER NOT NULL,
|
|
95
|
-
previous_average_user_rating REAL,
|
|
96
|
-
previous_user_rating_count INTEGER,
|
|
97
105
|
release_date TEXT,
|
|
98
106
|
current_version_release_date TEXT,
|
|
99
107
|
icon_json TEXT,
|
|
100
108
|
icon_artwork_json TEXT,
|
|
101
109
|
expires_at TEXT,
|
|
102
|
-
|
|
103
|
-
previous_fetched_at TEXT,
|
|
104
|
-
PRIMARY KEY (bucket, country, app_id)
|
|
110
|
+
PRIMARY KEY (country, app_id)
|
|
105
111
|
);
|
|
106
112
|
|
|
107
113
|
CREATE TABLE IF NOT EXISTS app_keywords (
|
|
@@ -140,13 +146,17 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
140
146
|
);
|
|
141
147
|
CREATE INDEX IF NOT EXISTS idx_aso_keyword_failures_country_stage
|
|
142
148
|
ON aso_keyword_failures(country, stage);
|
|
143
|
-
`)
|
|
149
|
+
`)}function Ca(){if(Da)return Da;let e=L4(),t=pn.dirname(e);return rd.existsSync(t)||rd.mkdirSync(t,{recursive:!0}),Da=new Gw.default(e),q4(Da),Da}function fg(e){return e.trim().toLowerCase()}function Ww(e){let t=new Set;for(let n of e){let o=fg(n);o&&t.add(o)}return Array.from(t)}var F4="US";function Xw(e,t,n=F4){if(t.length===0)return;let o=Ca(),r=o.prepare(`INSERT OR IGNORE INTO app_keywords (
|
|
144
150
|
app_id, keyword, country, previous_position, added_at
|
|
145
151
|
)
|
|
146
|
-
VALUES (?, ?, ?, NULL, ?)`),i=new Date().toISOString();o.transaction(()=>{for(let s of t){let c=
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
+
VALUES (?, ?, ?, NULL, ?)`),i=new Date().toISOString();o.transaction(()=>{for(let s of t){let c=fg(s);c&&r.run(e,c,n,i)}})()}function B4(e){if(e)try{let t=JSON.parse(e);if(t&&typeof t=="object"&&!Array.isArray(t))return t}catch{}}function K4(e){return e==="research"?"research":"owned"}function H4(e){return{id:e.id,kind:K4(e.kind),name:e.name,averageUserRating:e.average_user_rating,userRatingCount:e.user_rating_count,previousAverageUserRating:e.previous_average_user_rating,previousUserRatingCount:e.previous_user_rating_count,icon:B4(e.icon_json),expiresAt:e.expires_at,lastFetchedAt:e.last_fetched_at,previousFetchedAt:e.previous_fetched_at}}function pg(e){let n=Ca().prepare(`SELECT id, kind, name, average_user_rating, user_rating_count,
|
|
153
|
+
previous_average_user_rating, previous_user_rating_count,
|
|
154
|
+
icon_json,
|
|
155
|
+
expires_at, last_fetched_at, previous_fetched_at
|
|
156
|
+
FROM owned_apps
|
|
157
|
+
WHERE id = ?`).get(e);return n?H4(n):null}function Yw(e){if(e.length===0)return;let t=Ca(),n=t.prepare(`INSERT INTO owned_apps (id, kind, name)
|
|
158
|
+
VALUES (@id, @kind, @name)
|
|
159
|
+
ON CONFLICT(id) DO UPDATE SET
|
|
160
|
+
kind = excluded.kind,
|
|
161
|
+
name = excluded.name`);t.transaction(()=>{for(let r of e)n.run({id:r.id,kind:r.kind,name:r.name})})()}function J4(e){let t=e.trim()||td,n=t.match(/^id(\d+)$/i);if(!n)return t;let o=n[1];return pg(o)?o:`id${o}`}function Qw(e,t,n=td){if(e.length===0)return 0;let o=Array.from(new Set(e.map(i=>i.trim().toLowerCase()).filter(i=>i.length>0)));if(o.length===0)return 0;let r=J4(n);if(!pg(r)){let i=Hw(r)?"research":"owned";Yw([{id:r,kind:i,name:r===td?Kw:r}])}return Xw(r,o,t),o.length}var G4=15,W4=70,ek=6,tk=qt.object({keywords:qt.array(qt.string().min(1).describe("ASO search term candidate. Can be a single word or a multi-word long-tail phrase.")).min(1).max(100).describe("List of ASO search term candidates. Comma-separated entries are split and normalized."),minPopularity:qt.number().min(ek).optional(),maxDifficulty:qt.number().optional(),appId:qt.string().trim().min(1).optional().describe("Optional local app id to associate accepted keywords with. Defaults to the research app when omitted.")});function X4(e){return e.length>=2&&/[a-z0-9]/.test(e)}function Y4(e){if(!e||e.length<2||e.length>60)return!1;let t=e.split(" ").filter(Boolean);return t.length===0||t.length>4?!1:t.every(n=>X4(n))}function Q4(e){return e.flatMap(t=>t.split(","))}function eD(e){return Ww(e).filter(t=>Y4(t))}function tD(e){let t=e.trim();if(!t)return null;try{return JSON.parse(t)}catch{return null}}function rD(e){if(!e||typeof e!="object")return null;let t=e;return!Array.isArray(t.items)||!Array.isArray(t.failedKeywords)?null:t.items}function mg(e){if(typeof e=="number"&&Number.isFinite(e))return e;if(typeof e=="string"&&e.trim()!==""){let t=Number(e);return Number.isFinite(t)?t:null}return null}function nD(e){return typeof e=="string"?e:""}function oD(e){let t=e??{};return{keyword:nD(t.keyword),popularity:mg(t.popularity),difficulty:mg(t.difficulty??t.difficultyScore),minDifficultyScore:mg(t.minDifficultyScore)}}function nd(e){return{content:[{type:"text",text:e}],isError:!0}}async function rk(e){let t=Math.max(e.minPopularity??G4,ek),n=e.maxDifficulty??W4,o=e.appId,r=Q4(e.keywords),i=eD(r);if(r.length>100)return nd(`Too many keywords: received ${r.length}, max is ${100}.`);if(i.length===0)return nd("No valid keywords were found in `keywords`.");let a=i.join(","),s=await Vw(["keywords",a,"--stdout"]);if(s.exitCode!==0)return Fw(s);let c=tD(s.stdout);if(c==null)return cr(new Error("MCP expected JSON output from aso keywords"),{surface:"aso-mcp",tool:"aso_evaluate_keywords",stage:"parse-json",command:"keywords",exitCode:s.exitCode,stdoutLength:s.stdout.length,stderrLength:s.stderr.length,telemetryHint:{classification:"actionable_bug",surface:"aso-mcp",source:"mcp.aso-evaluate-keywords.parse-json",stage:"parse",tool:"aso_evaluate_keywords"}}),nd("ASO command succeeded but response was not valid JSON.");let l=rD(c);if(l==null)return cr(new Error("MCP expected `{ items, failedKeywords }` envelope from aso keywords"),{surface:"aso-mcp",tool:"aso_evaluate_keywords",stage:"parse-envelope",command:"keywords",exitCode:s.exitCode,stdoutLength:s.stdout.length,stderrLength:s.stderr.length,telemetryHint:{classification:"actionable_bug",surface:"aso-mcp",source:"mcp.aso-evaluate-keywords.parse-envelope",stage:"parse",tool:"aso_evaluate_keywords"}}),nd("ASO command succeeded but response format was not valid `{ items, failedKeywords }` payload.");let f=l.map(oD).filter(_=>_.keyword!=="").map(_=>{let v=_.popularity,g=_.difficulty,b=v!=null&&v>=t,x=g!=null&&g<=n;return{..._,passes:b&&x}}).flatMap(_=>!_.passes||_.popularity==null||_.difficulty==null?[]:[{keyword:_.keyword,popularity:_.popularity,difficulty:_.difficulty,minDifficultyScore:_.minDifficultyScore}]);if(f.length>0)try{Qw(f.map(_=>_.keyword),"US",o)}catch(_){throw cr(_,{surface:"aso-mcp",tool:"aso_evaluate_keywords",stage:"persist",acceptedCount:f.length,telemetryHint:{classification:"actionable_bug",surface:"aso-mcp",source:"mcp.aso-evaluate-keywords.persist",stage:"persist",tool:"aso_evaluate_keywords"}}),_}return{content:[{type:"text",text:JSON.stringify(f,null,2)}]}}var nk=[20,18,1];function iD(e){let[t="0",n="0",o="0"]=e.replace(/^v/,"").split(".");return[Number.parseInt(t,10)||0,Number.parseInt(n,10)||0,Number.parseInt(o,10)||0]}function aD(e,t){for(let n=0;n<3;n+=1){if(e[n]>t[n])return!0;if(e[n]<t[n])return!1}return!0}function ok(e=process.version){let t=iD(e);if(!aD(t,nk))throw new Error(`aso-cli requires Node.js >= ${nk.join(".")}. Current runtime: ${e}.`)}ok();var ik=new Bl({name:"aso-mcp",title:"ASO MCP Server",version:Jl,description:"MCP server for ASO keyword evaluation and scoring through the standalone ASO CLI.",websiteUrl:"https://github.com/semihcihan/App-Store-Optimization-CLI"},{instructions:"Use `aso_evaluate_keywords` to evaluate explicit ASO keyword candidates. The tool returns only accepted keywords with compact scores."});ik.registerTool("aso_evaluate_keywords",{title:"Evaluate ASO keywords",description:"Evaluates explicit ASO search terms (single-word or multi-word long-tail phrases) and returns only accepted keywords with compact metrics: keyword, popularity, difficulty, minDifficultyScore.",inputSchema:tk},rk);async function sD(){let e=new Hl;await ik.connect(e)}sD().catch(e=>{cr(e,{surface:"aso-mcp",stage:"bootstrap",telemetryHint:{classification:"actionable_bug",surface:"aso-mcp",source:"mcp.index.main",stage:"bootstrap"}}),console.error("MCP server error:",e),process.exitCode=1});
|
|
152
162
|
//# sourceMappingURL=mcp.js.map
|