@rizom/ops 0.2.0-alpha.3 → 0.2.0-alpha.300
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 +44 -3
- package/dist/age-key-bootstrap.d.ts +17 -0
- package/dist/brains-ops.js +453 -173
- package/dist/cert-bootstrap.d.ts +24 -0
- package/dist/content-repo-ref.d.ts +10 -0
- package/dist/content-repo.d.ts +13 -0
- package/dist/default-user-runner.d.ts +1 -1
- package/dist/deploy.js +99 -166
- package/dist/directory-sync-stress-system.d.ts +75 -0
- package/dist/directory-sync-stress.d.ts +107 -0
- package/dist/entries/deploy.d.ts +3 -2
- package/dist/images.d.ts +79 -0
- package/dist/index.d.ts +11 -0
- package/dist/index.js +523 -152
- package/dist/legacy-pilot-migration.d.ts +11 -0
- package/dist/load-registry.d.ts +74 -7
- package/dist/observed-status.d.ts +12 -0
- package/dist/onboard-user.d.ts +2 -2
- package/dist/origin-ca.d.ts +1 -0
- package/dist/parse-args.d.ts +2 -9
- package/dist/preview-domain.d.ts +9 -0
- package/dist/push-secrets.d.ts +2 -0
- package/dist/push-target.d.ts +1 -0
- package/dist/reconcile-all.d.ts +2 -2
- package/dist/reconcile-cohort.d.ts +2 -2
- package/dist/reconcile-dry-run.d.ts +9 -0
- package/dist/reconcile-lib.d.ts +4 -2
- package/dist/run-command.d.ts +19 -4
- package/dist/run-subprocess.d.ts +1 -0
- package/dist/schema.d.ts +119 -70
- package/dist/secrets-encrypt.d.ts +26 -0
- package/dist/secrets-push.d.ts +2 -5
- package/dist/ssh-key-bootstrap.d.ts +1 -0
- package/dist/stage-legacy-crossover.d.ts +20 -0
- package/dist/stress-command.d.ts +14 -0
- package/dist/stress-git-checkout.d.ts +21 -0
- package/dist/stress-health-monitor.d.ts +46 -0
- package/dist/upgrade.d.ts +10 -0
- package/dist/user-add.d.ts +15 -0
- package/dist/user-runner.d.ts +5 -0
- package/dist/verify-user.d.ts +22 -0
- package/package.json +47 -40
- package/templates/rover-pilot/.env.schema +28 -2
- package/templates/rover-pilot/.github/actions/varlock-env/action.yml +47 -0
- package/templates/rover-pilot/.github/workflows/build.yml +71 -17
- package/templates/rover-pilot/.github/workflows/deploy.yml +110 -45
- package/templates/rover-pilot/.github/workflows/directory-sync-stress.yml +119 -0
- package/templates/rover-pilot/.github/workflows/reconcile.yml +23 -3
- package/templates/rover-pilot/.github/workflows/upgrade.yml +104 -0
- package/templates/rover-pilot/README.md +20 -7
- package/templates/rover-pilot/deploy/scripts/decrypt-user-secrets.ts +139 -0
- package/templates/rover-pilot/deploy/scripts/helpers.ts +3 -0
- package/templates/rover-pilot/deploy/scripts/install-health-watchdog.ts +144 -0
- package/templates/rover-pilot/deploy/scripts/provision-server.ts +1 -1
- package/templates/rover-pilot/deploy/scripts/resolve-deploy-handles.ts +15 -4
- package/templates/rover-pilot/deploy/scripts/resolve-missing-images.ts +13 -0
- package/templates/rover-pilot/deploy/scripts/resolve-user-config.ts +49 -14
- package/templates/rover-pilot/deploy/scripts/sync-content-repo.ts +183 -0
- package/templates/rover-pilot/deploy/scripts/update-dns.ts +14 -4
- package/templates/rover-pilot/deploy/scripts/validate-secrets.ts +12 -1
- package/templates/rover-pilot/docs/canonical-crossover-record.md +104 -0
- package/templates/rover-pilot/docs/onboarding-checklist.md +39 -8
- package/templates/rover-pilot/docs/operator-playbook.md +298 -9
- package/templates/rover-pilot/docs/user-onboarding.md +90 -0
- package/templates/rover-pilot/package.json +3 -0
- package/templates/rover-pilot/pilot.yaml +5 -3
- package/templates/rover-pilot/users/alice.yaml +5 -1
- package/dist/user-secret-names.d.ts +0 -6
- package/templates/rover-pilot/.kamal/hooks/pre-deploy +0 -9
- package/templates/rover-pilot/deploy/Dockerfile +0 -15
- package/templates/rover-pilot/deploy/kamal/deploy.yml +0 -39
package/dist/index.js
CHANGED
|
@@ -1,174 +1,545 @@
|
|
|
1
1
|
// @bun
|
|
2
|
-
var
|
|
2
|
+
var GF=Object.create;var{getPrototypeOf:IF,defineProperty:dY,getOwnPropertyNames:QF}=Object;var DF=Object.prototype.hasOwnProperty;function XF($){return this[$]}var YF,VF,nY=($,U,J)=>{var G=$!=null&&typeof $==="object";if(G){var q=U?YF??=new WeakMap:VF??=new WeakMap,I=q.get($);if(I)return I}J=$!=null?GF(IF($)):{};let Q=U||!$||!$.__esModule?dY(J,"default",{value:$,enumerable:!0}):J;for(let D of QF($))if(!DF.call(Q,D))dY(Q,D,{get:XF.bind($,D),enumerable:!0});if(G)q.set($,Q);return Q};var J$=($,U)=>()=>(U||$((U={exports:{}}).exports,U),U.exports);var WF=($)=>$;function OF($,U){this[$]=WF.bind(null,U)}var UU=($,U)=>{for(var J in U)dY($,J,{get:U[J],enumerable:!0,configurable:!0,set:OF.bind(U,J)})};var O$=($,U)=>()=>($&&(U=$($=0)),U);var WU=import.meta.require;function SF($){return $&&$.__esModule&&Object.prototype.hasOwnProperty.call($,"default")?$.default:$}function x6(){if($T)return fJ;$T=1;function $(Q){return typeof Q>"u"||Q===null}function U(Q){return typeof Q==="object"&&Q!==null}function J(Q){if(Array.isArray(Q))return Q;else if($(Q))return[];return[Q]}function G(Q,D){if(D){let X=Object.keys(D);for(let Y=0,V=X.length;Y<V;Y+=1){let W=X[Y];Q[W]=D[W]}}return Q}function q(Q,D){let X="";for(let Y=0;Y<D;Y+=1)X+=Q;return X}function I(Q){return Q===0&&Number.NEGATIVE_INFINITY===1/Q}return fJ.isNothing=$,fJ.isObject=U,fJ.toArray=J,fJ.repeat=q,fJ.isNegativeZero=I,fJ.extend=G,fJ}function f6(){if(UT)return sY;UT=1;function $(J,G){let q="",I=J.reason||"(unknown reason)";if(!J.mark)return I;if(J.mark.name)q+='in "'+J.mark.name+'" ';if(q+="("+(J.mark.line+1)+":"+(J.mark.column+1)+")",!G&&J.mark.snippet)q+=`
|
|
3
|
+
|
|
4
|
+
`+J.mark.snippet;return I+" "+q}function U(J,G){if(Error.call(this),this.name="YAMLException",this.reason=J,this.mark=G,this.message=$(this,!1),Error.captureStackTrace)Error.captureStackTrace(this,this.constructor);else this.stack=Error().stack||""}return U.prototype=Object.create(Error.prototype),U.prototype.constructor=U,U.prototype.toString=function(G){return this.name+": "+$(this,G)},sY=U,sY}function LF(){if(JT)return tY;JT=1;let $=x6();function U(q,I,Q,D,X){let Y="",V="",W=Math.floor(X/2)-1;if(D-I>W)Y=" ... ",I=D-W+Y.length;if(Q-D>W)V=" ...",Q=D+W-V.length;return{str:Y+q.slice(I,Q).replace(/\t/g,"\u2192")+V,pos:D-I+Y.length}}function J(q,I){return $.repeat(" ",I-q.length)+q}function G(q,I){if(I=Object.create(I||null),!q.buffer)return null;if(!I.maxLength)I.maxLength=79;if(typeof I.indent!=="number")I.indent=1;if(typeof I.linesBefore!=="number")I.linesBefore=3;if(typeof I.linesAfter!=="number")I.linesAfter=2;let Q=/\r?\n|\r|\0/g,D=[0],X=[],Y,V=-1;while(Y=Q.exec(q.buffer))if(X.push(Y.index),D.push(Y.index+Y[0].length),q.position<=Y.index&&V<0)V=D.length-2;if(V<0)V=D.length-1;let W="",O=Math.min(q.line+I.linesAfter,X.length).toString().length,Z=I.maxLength-(I.indent+O+3);for(let w=1;w<=I.linesBefore;w++){if(V-w<0)break;let H=U(q.buffer,D[V-w],X[V-w],q.position-(D[V]-D[V-w]),Z);W=$.repeat(" ",I.indent)+J((q.line-w+1).toString(),O)+" | "+H.str+`
|
|
5
|
+
`+W}let M=U(q.buffer,D[V],X[V],q.position,Z);W+=$.repeat(" ",I.indent)+J((q.line+1).toString(),O)+" | "+M.str+`
|
|
6
|
+
`,W+=$.repeat("-",I.indent+O+3+M.pos)+`^
|
|
7
|
+
`;for(let w=1;w<=I.linesAfter;w++){if(V+w>=X.length)break;let H=U(q.buffer,D[V+w],X[V+w],q.position-(D[V]-D[V+w]),Z);W+=$.repeat(" ",I.indent)+J((q.line+w+1).toString(),O)+" | "+H.str+`
|
|
8
|
+
`}return W.replace(/\n$/,"")}return tY=G,tY}function h0(){if(qT)return eY;qT=1;let $=f6(),U=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],J=["scalar","sequence","mapping"];function G(I){let Q={};if(I!==null)Object.keys(I).forEach(function(D){I[D].forEach(function(X){Q[String(X)]=D})});return Q}function q(I,Q){if(Q=Q||{},Object.keys(Q).forEach(function(D){if(U.indexOf(D)===-1)throw new $('Unknown option "'+D+'" is met in definition of "'+I+'" YAML type.')}),this.options=Q,this.tag=I,this.kind=Q.kind||null,this.resolve=Q.resolve||function(){return!0},this.construct=Q.construct||function(D){return D},this.instanceOf=Q.instanceOf||null,this.predicate=Q.predicate||null,this.represent=Q.represent||null,this.representName=Q.representName||null,this.defaultStyle=Q.defaultStyle||null,this.multi=Q.multi||!1,this.styleAliases=G(Q.styleAliases||null),J.indexOf(this.kind)===-1)throw new $('Unknown kind "'+this.kind+'" is specified for "'+I+'" YAML type.')}return eY=q,eY}function PT(){if(GT)return $V;GT=1;let $=f6(),U=h0();function J(I,Q){let D=[];return I[Q].forEach(function(X){let Y=D.length;D.forEach(function(V,W){if(V.tag===X.tag&&V.kind===X.kind&&V.multi===X.multi)Y=W}),D[Y]=X}),D}function G(){let I={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}};function Q(D){if(D.multi)I.multi[D.kind].push(D),I.multi.fallback.push(D);else I[D.kind][D.tag]=I.fallback[D.tag]=D}for(let D=0,X=arguments.length;D<X;D+=1)arguments[D].forEach(Q);return I}function q(I){return this.extend(I)}return q.prototype.extend=function(Q){let D=[],X=[];if(Q instanceof U)X.push(Q);else if(Array.isArray(Q))X=X.concat(Q);else if(Q&&(Array.isArray(Q.implicit)||Array.isArray(Q.explicit))){if(Q.implicit)D=D.concat(Q.implicit);if(Q.explicit)X=X.concat(Q.explicit)}else throw new $("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");D.forEach(function(V){if(!(V instanceof U))throw new $("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(V.loadKind&&V.loadKind!=="scalar")throw new $("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(V.multi)throw new $("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}),X.forEach(function(V){if(!(V instanceof U))throw new $("Specified list of YAML types (or a single Type object) contains a non-Type object.")});let Y=Object.create(q.prototype);return Y.implicit=(this.implicit||[]).concat(D),Y.explicit=(this.explicit||[]).concat(X),Y.compiledImplicit=J(Y,"implicit"),Y.compiledExplicit=J(Y,"explicit"),Y.compiledTypeMap=G(Y.compiledImplicit,Y.compiledExplicit),Y},$V=q,$V}function BT(){if(IT)return UV;return IT=1,UV=new(h0())("tag:yaml.org,2002:str",{kind:"scalar",construct:function(U){return U!==null?U:""}}),UV}function ST(){if(QT)return JV;return QT=1,JV=new(h0())("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(U){return U!==null?U:[]}}),JV}function LT(){if(DT)return qV;return DT=1,qV=new(h0())("tag:yaml.org,2002:map",{kind:"mapping",construct:function(U){return U!==null?U:{}}}),qV}function ET(){if(XT)return GV;return XT=1,GV=new(PT())({explicit:[BT(),ST(),LT()]}),GV}function CT(){if(YT)return IV;YT=1;let $=h0();function U(q){if(q===null)return!0;let I=q.length;return I===1&&q==="~"||I===4&&(q==="null"||q==="Null"||q==="NULL")}function J(){return null}function G(q){return q===null}return IV=new $("tag:yaml.org,2002:null",{kind:"scalar",resolve:U,construct:J,predicate:G,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"},empty:function(){return""}},defaultStyle:"lowercase"}),IV}function _T(){if(VT)return QV;VT=1;let $=h0();function U(q){if(q===null)return!1;let I=q.length;return I===4&&(q==="true"||q==="True"||q==="TRUE")||I===5&&(q==="false"||q==="False"||q==="FALSE")}function J(q){return q==="true"||q==="True"||q==="TRUE"}function G(q){return Object.prototype.toString.call(q)==="[object Boolean]"}return QV=new $("tag:yaml.org,2002:bool",{kind:"scalar",resolve:U,construct:J,predicate:G,represent:{lowercase:function(q){return q?"true":"false"},uppercase:function(q){return q?"TRUE":"FALSE"},camelcase:function(q){return q?"True":"False"}},defaultStyle:"lowercase"}),QV}function vT(){if(WT)return DV;WT=1;let $=x6(),U=h0();function J(Y){return Y>=48&&Y<=57||Y>=65&&Y<=70||Y>=97&&Y<=102}function G(Y){return Y>=48&&Y<=55}function q(Y){return Y>=48&&Y<=57}function I(Y){if(Y===null)return!1;let V=Y.length,W=0,O=!1;if(!V)return!1;let Z=Y[W];if(Z==="-"||Z==="+")Z=Y[++W];if(Z==="0"){if(W+1===V)return!0;if(Z=Y[++W],Z==="b"){W++;for(;W<V;W++){if(Z=Y[W],Z!=="0"&&Z!=="1")return!1;O=!0}return O&&isFinite(Q(Y))}if(Z==="x"){W++;for(;W<V;W++){if(!J(Y.charCodeAt(W)))return!1;O=!0}return O&&isFinite(Q(Y))}if(Z==="o"){W++;for(;W<V;W++){if(!G(Y.charCodeAt(W)))return!1;O=!0}return O&&isFinite(Q(Y))}}for(;W<V;W++){if(!q(Y.charCodeAt(W)))return!1;O=!0}if(!O)return!1;return isFinite(Q(Y))}function Q(Y){let V=Y,W=1,O=V[0];if(O==="-"||O==="+"){if(O==="-")W=-1;V=V.slice(1),O=V[0]}if(V==="0")return 0;if(O==="0"){if(V[1]==="b")return W*parseInt(V.slice(2),2);if(V[1]==="x")return W*parseInt(V.slice(2),16);if(V[1]==="o")return W*parseInt(V.slice(2),8)}return W*parseInt(V,10)}function D(Y){return Q(Y)}function X(Y){return Object.prototype.toString.call(Y)==="[object Number]"&&(Y%1===0&&!$.isNegativeZero(Y))}return DV=new U("tag:yaml.org,2002:int",{kind:"scalar",resolve:I,construct:D,predicate:X,represent:{binary:function(Y){return Y>=0?"0b"+Y.toString(2):"-0b"+Y.toString(2).slice(1)},octal:function(Y){return Y>=0?"0o"+Y.toString(8):"-0o"+Y.toString(8).slice(1)},decimal:function(Y){return Y.toString(10)},hexadecimal:function(Y){return Y>=0?"0x"+Y.toString(16).toUpperCase():"-0x"+Y.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),DV}function FT(){if(OT)return XV;OT=1;let $=x6(),U=h0(),J=new RegExp("^(?:[-+]?(?:[0-9]+)(?:\\.[0-9]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$"),G=new RegExp("^(?:[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function q(Y){if(Y===null)return!1;if(!J.test(Y))return!1;if(isFinite(parseFloat(Y,10)))return!0;return G.test(Y)}function I(Y){let V=Y.toLowerCase(),W=V[0]==="-"?-1:1;if("+-".indexOf(V[0])>=0)V=V.slice(1);if(V===".inf")return W===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY;else if(V===".nan")return NaN;return W*parseFloat(V,10)}let Q=/^[-+]?[0-9]+e/;function D(Y,V){if(isNaN(Y))switch(V){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===Y)switch(V){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===Y)switch(V){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if($.isNegativeZero(Y))return"-0.0";let W=Y.toString(10);return Q.test(W)?W.replace("e",".e"):W}function X(Y){return Object.prototype.toString.call(Y)==="[object Number]"&&(Y%1!==0||$.isNegativeZero(Y))}return XV=new U("tag:yaml.org,2002:float",{kind:"scalar",resolve:q,construct:I,predicate:X,represent:D,defaultStyle:"lowercase"}),XV}function bT(){if(ZT)return YV;return ZT=1,YV=ET().extend({implicit:[CT(),_T(),vT(),FT()]}),YV}function uT(){if(RT)return VV;return RT=1,VV=bT(),VV}function kT(){if(NT)return WV;NT=1;let $=h0(),U=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),J=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");function G(Q){if(Q===null)return!1;if(U.exec(Q)!==null)return!0;if(J.exec(Q)!==null)return!0;return!1}function q(Q){let D=0,X=null,Y=U.exec(Q);if(Y===null)Y=J.exec(Q);if(Y===null)throw Error("Date resolve error");let V=+Y[1],W=+Y[2]-1,O=+Y[3];if(!Y[4])return new Date(Date.UTC(V,W,O));let Z=+Y[4],M=+Y[5],w=+Y[6];if(Y[7]){D=Y[7].slice(0,3);while(D.length<3)D+="0";D=+D}if(Y[9]){let g=+Y[10],P=+(Y[11]||0);if(X=(g*60+P)*60000,Y[9]==="-")X=-X}let H=new Date(Date.UTC(V,W,O,Z,M,w,D));if(X)H.setTime(H.getTime()-X);return H}function I(Q){return Q.toISOString()}return WV=new $("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:G,construct:q,instanceOf:Date,represent:I}),WV}function xT(){if(wT)return OV;wT=1;let $=h0();function U(J){return J==="<<"||J===null}return OV=new $("tag:yaml.org,2002:merge",{kind:"scalar",resolve:U}),OV}function fT(){if(MT)return ZV;MT=1;let $=h0(),U=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
|
|
9
|
+
\r`;function J(Q){if(Q===null)return!1;let D=0,X=Q.length,Y=U;for(let V=0;V<X;V++){let W=Y.indexOf(Q.charAt(V));if(W>64)continue;if(W<0)return!1;D+=6}return D%8===0}function G(Q){let D=Q.replace(/[\r\n=]/g,""),X=D.length,Y=U,V=0,W=[];for(let Z=0;Z<X;Z++){if(Z%4===0&&Z)W.push(V>>16&255),W.push(V>>8&255),W.push(V&255);V=V<<6|Y.indexOf(D.charAt(Z))}let O=X%4*6;if(O===0)W.push(V>>16&255),W.push(V>>8&255),W.push(V&255);else if(O===18)W.push(V>>10&255),W.push(V>>2&255);else if(O===12)W.push(V>>4&255);return new Uint8Array(W)}function q(Q){let D="",X=0,Y=Q.length,V=U;for(let O=0;O<Y;O++){if(O%3===0&&O)D+=V[X>>18&63],D+=V[X>>12&63],D+=V[X>>6&63],D+=V[X&63];X=(X<<8)+Q[O]}let W=Y%3;if(W===0)D+=V[X>>18&63],D+=V[X>>12&63],D+=V[X>>6&63],D+=V[X&63];else if(W===2)D+=V[X>>10&63],D+=V[X>>4&63],D+=V[X<<2&63],D+=V[64];else if(W===1)D+=V[X>>2&63],D+=V[X<<4&63],D+=V[64],D+=V[64];return D}function I(Q){return Object.prototype.toString.call(Q)==="[object Uint8Array]"}return ZV=new $("tag:yaml.org,2002:binary",{kind:"scalar",resolve:J,construct:G,predicate:I,represent:q}),ZV}function yT(){if(HT)return RV;HT=1;let $=h0(),U=Object.prototype.hasOwnProperty,J=Object.prototype.toString;function G(I){if(I===null)return!0;let Q=[],D=I;for(let X=0,Y=D.length;X<Y;X+=1){let V=D[X],W=!1;if(J.call(V)!=="[object Object]")return!1;let O;for(O in V)if(U.call(V,O))if(!W)W=!0;else return!1;if(!W)return!1;if(Q.indexOf(O)===-1)Q.push(O);else return!1}return!0}function q(I){return I!==null?I:[]}return RV=new $("tag:yaml.org,2002:omap",{kind:"sequence",resolve:G,construct:q}),RV}function mT(){if(TT)return NV;TT=1;let $=h0(),U=Object.prototype.toString;function J(q){if(q===null)return!0;let I=q,Q=Array(I.length);for(let D=0,X=I.length;D<X;D+=1){let Y=I[D];if(U.call(Y)!=="[object Object]")return!1;let V=Object.keys(Y);if(V.length!==1)return!1;Q[D]=[V[0],Y[V[0]]]}return!0}function G(q){if(q===null)return[];let I=q,Q=Array(I.length);for(let D=0,X=I.length;D<X;D+=1){let Y=I[D],V=Object.keys(Y);Q[D]=[V[0],Y[V[0]]]}return Q}return NV=new $("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:J,construct:G}),NV}function hT(){if(zT)return wV;zT=1;let $=h0(),U=Object.prototype.hasOwnProperty;function J(q){if(q===null)return!0;let I=q;for(let Q in I)if(U.call(I,Q)){if(I[Q]!==null)return!1}return!0}function G(q){return q!==null?q:{}}return wV=new $("tag:yaml.org,2002:set",{kind:"mapping",resolve:J,construct:G}),wV}function TV(){if(AT)return MV;return AT=1,MV=uT().extend({implicit:[kT(),xT()],explicit:[fT(),yT(),mT(),hT()]}),MV}function EF(){if(KT)return NQ;KT=1;let $=x6(),U=f6(),J=LF(),G=TV(),q=Object.prototype.hasOwnProperty,I=1,Q=2,D=3,X=4,Y=1,V=2,W=3,O=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,Z=/[\x85\u2028\u2029]/,M=/[,\[\]{}]/,w=/^(?:!|!!|![0-9A-Za-z-]+!)$/,H=/^(?:!|[^,\[\]{}])(?:%[0-9a-f]{2}|[0-9a-z\-#;/?:@&=+$,_.!~*'()\[\]])*$/i;function g(R){return Object.prototype.toString.call(R)}function P(R){return R===10||R===13}function C(R){return R===9||R===32}function F(R){return R===9||R===32||R===10||R===13}function f(R){return R===44||R===91||R===93||R===123||R===125}function E(R){if(R>=48&&R<=57)return R-48;let x=R|32;if(x>=97&&x<=102)return x-97+10;return-1}function p(R){if(R===120)return 2;if(R===117)return 4;if(R===85)return 8;return 0}function b(R){if(R>=48&&R<=57)return R-48;return-1}function h(R){switch(R){case 48:return"\x00";case 97:return"\x07";case 98:return"\b";case 116:return"\t";case 9:return"\t";case 110:return`
|
|
10
|
+
`;case 118:return"\v";case 102:return"\f";case 114:return"\r";case 101:return"\x1B";case 32:return" ";case 34:return'"';case 47:return"/";case 92:return"\\";case 78:return"\x85";case 95:return"\xA0";case 76:return"\u2028";case 80:return"\u2029";default:return""}}function s(R){if(R<=65535)return String.fromCharCode(R);return String.fromCharCode((R-65536>>10)+55296,(R-65536&1023)+56320)}function m(R,x,d){if(x==="__proto__")Object.defineProperty(R,x,{configurable:!0,enumerable:!0,writable:!0,value:d});else R[x]=d}let _=Array(256),v=Array(256);for(let R=0;R<256;R++)_[R]=h(R)?1:0,v[R]=h(R);function j(R,x){this.input=R,this.filename=x.filename||null,this.schema=x.schema||G,this.onWarning=x.onWarning||null,this.legacy=x.legacy||!1,this.json=x.json||!1,this.listener=x.listener||null,this.maxDepth=typeof x.maxDepth==="number"?x.maxDepth:100,this.maxTotalMergeKeys=typeof x.maxTotalMergeKeys==="number"?x.maxTotalMergeKeys:1e4,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=R.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.depth=0,this.totalMergeKeys=0,this.firstTabInLine=-1,this.documents=[],this.anchorMapTransactions=[]}function L(R,x){let d={name:R.filename,buffer:R.input.slice(0,-1),position:R.position,line:R.line,column:R.position-R.lineStart};return d.snippet=J(d),new U(x,d)}function S(R,x){throw L(R,x)}function y(R,x){if(R.onWarning)R.onWarning.call(null,L(R,x))}function u(R,x,d){let e=R.anchorMapTransactions;if(e.length!==0){let c=e[e.length-1];if(!q.call(c,x))c[x]={existed:q.call(R.anchorMap,x),value:R.anchorMap[x]}}R.anchorMap[x]=d}function l(R){R.anchorMapTransactions.push(Object.create(null))}function A(R){let x=R.anchorMapTransactions.pop(),d=R.anchorMapTransactions;if(d.length===0)return;let e=d[d.length-1],c=Object.keys(x);for(let I$=0,K=c.length;I$<K;I$+=1){let i=c[I$];if(!q.call(e,i))e[i]=x[i]}}function o(R){let x=R.anchorMapTransactions.pop(),d=Object.keys(x);for(let e=d.length-1;e>=0;e-=1){let c=x[d[e]];if(c.existed)R.anchorMap[d[e]]=c.value;else delete R.anchorMap[d[e]]}}function G$(R){return{position:R.position,line:R.line,lineStart:R.lineStart,lineIndent:R.lineIndent,firstTabInLine:R.firstTabInLine,tag:R.tag,anchor:R.anchor,kind:R.kind,result:R.result}}function B(R,x){R.position=x.position,R.line=x.line,R.lineStart=x.lineStart,R.lineIndent=x.lineIndent,R.firstTabInLine=x.firstTabInLine,R.tag=x.tag,R.anchor=x.anchor,R.kind=x.kind,R.result=x.result}let R$={YAML:function(x,d,e){if(x.version!==null)S(x,"duplication of %YAML directive");if(e.length!==1)S(x,"YAML directive accepts exactly one argument");let c=/^([0-9]+)\.([0-9]+)$/.exec(e[0]);if(c===null)S(x,"ill-formed argument of the YAML directive");let I$=parseInt(c[1],10),K=parseInt(c[2],10);if(I$!==1)S(x,"unacceptable YAML version of the document");if(x.version=e[0],x.checkLineBreaks=K<2,K!==1&&K!==2)y(x,"unsupported YAML version of the document")},TAG:function(x,d,e){let c;if(e.length!==2)S(x,"TAG directive accepts exactly two arguments");let I$=e[0];if(c=e[1],!w.test(I$))S(x,"ill-formed tag handle (first argument) of the TAG directive");if(q.call(x.tagMap,I$))S(x,'there is a previously declared suffix for "'+I$+'" tag handle');if(!H.test(c))S(x,"ill-formed tag prefix (second argument) of the TAG directive");try{c=decodeURIComponent(c)}catch(K){S(x,"tag prefix is malformed: "+c)}x.tagMap[I$]=c}};function H$(R,x,d,e){if(x<d){let c=R.input.slice(x,d);if(e)for(let I$=0,K=c.length;I$<K;I$+=1){let i=c.charCodeAt(I$);if(!(i===9||i>=32&&i<=1114111))S(R,"expected valid JSON character")}else if(O.test(c))S(R,"the stream contains non-printable characters");R.result+=c}}function K$(R,x,d,e){if(!$.isObject(d))S(R,"cannot merge mappings; the provided source object is unacceptable");let c=Object.keys(d);for(let I$=0,K=c.length;I$<K;I$+=1){let i=c[I$];if(R.maxTotalMergeKeys!==-1&&++R.totalMergeKeys>R.maxTotalMergeKeys)S(R,"merge keys exceeded maxTotalMergeKeys ("+R.maxTotalMergeKeys+")");if(!q.call(x,i))m(x,i,d[i]),e[i]=!0}}function A$(R,x,d,e,c,I$,K,i,q$){if(Array.isArray(c)){c=Array.prototype.slice.call(c);for(let $$=0,U$=c.length;$$<U$;$$+=1){if(Array.isArray(c[$$]))S(R,"nested arrays are not supported inside keys");if(typeof c==="object"&&g(c[$$])==="[object Object]")c[$$]="[object Object]"}}if(typeof c==="object"&&g(c)==="[object Object]")c="[object Object]";if(c=String(c),x===null)x={};if(e==="tag:yaml.org,2002:merge")if(Array.isArray(I$))for(let $$=0,U$=I$.length;$$<U$;$$+=1)K$(R,x,I$[$$],d);else K$(R,x,I$,d);else{if(!R.json&&!q.call(d,c)&&q.call(x,c))R.line=K||R.line,R.lineStart=i||R.lineStart,R.position=q$||R.position,S(R,"duplicated mapping key");m(x,c,I$),delete d[c]}return x}function w$(R){let x=R.input.charCodeAt(R.position);if(x===10)R.position++;else if(x===13){if(R.position++,R.input.charCodeAt(R.position)===10)R.position++}else S(R,"a line break is expected");R.line+=1,R.lineStart=R.position,R.firstTabInLine=-1}function P$(R,x,d){let e=0,c=R.input.charCodeAt(R.position);while(c!==0){while(C(c)){if(c===9&&R.firstTabInLine===-1)R.firstTabInLine=R.position;c=R.input.charCodeAt(++R.position)}if(x&&c===35)do c=R.input.charCodeAt(++R.position);while(c!==10&&c!==13&&c!==0);if(P(c)){w$(R),c=R.input.charCodeAt(R.position),e++,R.lineIndent=0;while(c===32)R.lineIndent++,c=R.input.charCodeAt(++R.position)}else break}if(d!==-1&&e!==0&&R.lineIndent<d)y(R,"deficient indentation");return e}function u$(R){let x=R.position,d=R.input.charCodeAt(x);if((d===45||d===46)&&d===R.input.charCodeAt(x+1)&&d===R.input.charCodeAt(x+2)){if(x+=3,d=R.input.charCodeAt(x),d===0||F(d))return!0}return!1}function m$(R,x){if(x===1)R.result+=" ";else if(x>1)R.result+=$.repeat(`
|
|
11
|
+
`,x-1)}function o$(R,x,d){let e,c,I$,K,i,q$,$$=R.kind,U$=R.result,Y$=R.input.charCodeAt(R.position);if(F(Y$)||f(Y$)||Y$===35||Y$===38||Y$===42||Y$===33||Y$===124||Y$===62||Y$===39||Y$===34||Y$===37||Y$===64||Y$===96)return!1;if(Y$===63||Y$===45){let D$=R.input.charCodeAt(R.position+1);if(F(D$)||d&&f(D$))return!1}R.kind="scalar",R.result="",e=c=R.position,I$=!1;while(Y$!==0){if(Y$===58){let D$=R.input.charCodeAt(R.position+1);if(F(D$)||d&&f(D$))break}else if(Y$===35){let D$=R.input.charCodeAt(R.position-1);if(F(D$))break}else if(R.position===R.lineStart&&u$(R)||d&&f(Y$))break;else if(P(Y$))if(K=R.line,i=R.lineStart,q$=R.lineIndent,P$(R,!1,-1),R.lineIndent>=x){I$=!0,Y$=R.input.charCodeAt(R.position);continue}else{R.position=c,R.line=K,R.lineStart=i,R.lineIndent=q$;break}if(I$)H$(R,e,c,!1),m$(R,R.line-K),e=c=R.position,I$=!1;if(!C(Y$))c=R.position+1;Y$=R.input.charCodeAt(++R.position)}if(H$(R,e,c,!1),R.result)return!0;return R.kind=$$,R.result=U$,!1}function J0(R,x){let d,e,c=R.input.charCodeAt(R.position);if(c!==39)return!1;R.kind="scalar",R.result="",R.position++,d=e=R.position;while((c=R.input.charCodeAt(R.position))!==0)if(c===39)if(H$(R,d,R.position,!0),c=R.input.charCodeAt(++R.position),c===39)d=R.position,R.position++,e=R.position;else return!0;else if(P(c))H$(R,d,e,!0),m$(R,P$(R,!1,x)),d=e=R.position;else if(R.position===R.lineStart&&u$(R))S(R,"unexpected end of the document within a single quoted scalar");else if(R.position++,!C(c))e=R.position;S(R,"unexpected end of the stream within a single quoted scalar")}function E0(R,x){let d,e,c,I$=R.input.charCodeAt(R.position);if(I$!==34)return!1;R.kind="scalar",R.result="",R.position++,d=e=R.position;while((I$=R.input.charCodeAt(R.position))!==0)if(I$===34)return H$(R,d,R.position,!0),R.position++,!0;else if(I$===92){if(H$(R,d,R.position,!0),I$=R.input.charCodeAt(++R.position),P(I$))P$(R,!1,x);else if(I$<256&&_[I$])R.result+=v[I$],R.position++;else if((c=p(I$))>0){let K=c,i=0;for(;K>0;K--)if(I$=R.input.charCodeAt(++R.position),(c=E(I$))>=0)i=(i<<4)+c;else S(R,"expected hexadecimal character");R.result+=s(i),R.position++}else S(R,"unknown escape sequence");d=e=R.position}else if(P(I$))H$(R,d,e,!0),m$(R,P$(R,!1,x)),d=e=R.position;else if(R.position===R.lineStart&&u$(R))S(R,"unexpected end of the document within a double quoted scalar");else if(R.position++,!C(I$))e=R.position;S(R,"unexpected end of the stream within a double quoted scalar")}function YU(R,x){let d=!0,e,c,I$,K=R.tag,i,q$=R.anchor,$$,U$,Y$,D$,z$=Object.create(null),T$,j$,S$,k$=R.input.charCodeAt(R.position);if(k$===91)$$=93,D$=!1,i=[];else if(k$===123)$$=125,D$=!0,i={};else return!1;if(R.anchor!==null)u(R,R.anchor,i);k$=R.input.charCodeAt(++R.position);while(k$!==0){if(P$(R,!0,x),k$=R.input.charCodeAt(R.position),k$===$$)return R.position++,R.tag=K,R.anchor=q$,R.kind=D$?"mapping":"sequence",R.result=i,!0;else if(!d)S(R,"missed comma between flow collection entries");else if(k$===44)S(R,"expected the node content, but found ','");if(j$=T$=S$=null,U$=Y$=!1,k$===63){let d$=R.input.charCodeAt(R.position+1);if(F(d$))U$=Y$=!0,R.position++,P$(R,!0,x)}if(e=R.line,c=R.lineStart,I$=R.position,FU(R,x,I,!1,!0),j$=R.tag,T$=R.result,P$(R,!0,x),k$=R.input.charCodeAt(R.position),(Y$||R.line===e)&&k$===58)U$=!0,k$=R.input.charCodeAt(++R.position),P$(R,!0,x),FU(R,x,I,!1,!0),S$=R.result;if(D$)A$(R,i,z$,j$,T$,S$,e,c,I$);else if(U$)i.push(A$(R,null,z$,j$,T$,S$,e,c,I$));else i.push(T$);if(P$(R,!0,x),k$=R.input.charCodeAt(R.position),k$===44)d=!0,k$=R.input.charCodeAt(++R.position);else d=!1}S(R,"unexpected end of the stream within a flow collection")}function VU(R,x){let d,e=Y,c=!1,I$=!1,K=x,i=0,q$=!1,$$,U$=R.input.charCodeAt(R.position);if(U$===124)d=!1;else if(U$===62)d=!0;else return!1;R.kind="scalar",R.result="";while(U$!==0)if(U$=R.input.charCodeAt(++R.position),U$===43||U$===45)if(Y===e)e=U$===43?W:V;else S(R,"repeat of a chomping mode identifier");else if(($$=b(U$))>=0)if($$===0)S(R,"bad explicit indentation width of a block scalar; it cannot be less than one");else if(!I$)K=x+$$-1,I$=!0;else S(R,"repeat of an indentation width identifier");else break;if(C(U$)){do U$=R.input.charCodeAt(++R.position);while(C(U$));if(U$===35)do U$=R.input.charCodeAt(++R.position);while(!P(U$)&&U$!==0)}while(U$!==0){w$(R),R.lineIndent=0,U$=R.input.charCodeAt(R.position);while((!I$||R.lineIndent<K)&&U$===32)R.lineIndent++,U$=R.input.charCodeAt(++R.position);if(!I$&&R.lineIndent>K)K=R.lineIndent;if(P(U$)){i++;continue}if(!I$&&K===0)S(R,"missing indentation for block scalar");if(R.lineIndent<K){if(e===W)R.result+=$.repeat(`
|
|
12
|
+
`,c?1+i:i);else if(e===Y){if(c)R.result+=`
|
|
13
|
+
`}break}if(d)if(C(U$))q$=!0,R.result+=$.repeat(`
|
|
14
|
+
`,c?1+i:i);else if(q$)q$=!1,R.result+=$.repeat(`
|
|
15
|
+
`,i+1);else if(i===0){if(c)R.result+=" "}else R.result+=$.repeat(`
|
|
16
|
+
`,i);else R.result+=$.repeat(`
|
|
17
|
+
`,c?1+i:i);c=!0,I$=!0,i=0;let Y$=R.position;while(!P(U$)&&U$!==0)U$=R.input.charCodeAt(++R.position);H$(R,Y$,R.position,!1)}return!0}function KU(R,x){let{tag:d,anchor:e}=R,c=[],I$=!1;if(R.firstTabInLine!==-1)return!1;if(R.anchor!==null)u(R,R.anchor,c);let K=R.input.charCodeAt(R.position);while(K!==0){if(R.firstTabInLine!==-1)R.position=R.firstTabInLine,S(R,"tab characters must not be used in indentation");if(K!==45)break;let i=R.input.charCodeAt(R.position+1);if(!F(i))break;if(I$=!0,R.position++,P$(R,!0,-1)){if(R.lineIndent<=x){c.push(null),K=R.input.charCodeAt(R.position);continue}}let q$=R.line;if(FU(R,x,D,!1,!0),c.push(R.result),P$(R,!0,-1),K=R.input.charCodeAt(R.position),(R.line===q$||R.lineIndent>x)&&K!==0)S(R,"bad indentation of a sequence entry");else if(R.lineIndent<x)break}if(I$)return R.tag=d,R.anchor=e,R.kind="sequence",R.result=c,!0;return!1}function mG(R,x,d){let e,c,I$,K,i=R.tag,q$=R.anchor,$$={},U$=Object.create(null),Y$=null,D$=null,z$=null,T$=!1,j$=!1;if(R.firstTabInLine!==-1)return!1;if(R.anchor!==null)u(R,R.anchor,$$);let S$=R.input.charCodeAt(R.position);while(S$!==0){if(!T$&&R.firstTabInLine!==-1)R.position=R.firstTabInLine,S(R,"tab characters must not be used in indentation");let k$=R.input.charCodeAt(R.position+1),d$=R.line;if((S$===63||S$===58)&&F(k$)){if(S$===63){if(T$)A$(R,$$,U$,Y$,D$,null,c,I$,K),Y$=D$=z$=null;j$=!0,T$=!0,e=!0}else if(T$)T$=!1,e=!0;else S(R,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line");R.position+=1,S$=k$}else{if(c=R.line,I$=R.lineStart,K=R.position,!FU(R,d,Q,!1,!0))break;if(R.line===d$){S$=R.input.charCodeAt(R.position);while(C(S$))S$=R.input.charCodeAt(++R.position);if(S$===58){if(S$=R.input.charCodeAt(++R.position),!F(S$))S(R,"a whitespace character is expected after the key-value separator within a block mapping");if(T$)A$(R,$$,U$,Y$,D$,null,c,I$,K),Y$=D$=z$=null;j$=!0,T$=!1,e=!1,Y$=R.tag,D$=R.result}else if(j$)S(R,"can not read an implicit mapping pair; a colon is missed");else return R.tag=i,R.anchor=q$,!0}else if(j$)S(R,"can not read a block mapping entry; a multiline key may not be an implicit key");else return R.tag=i,R.anchor=q$,!0}if(R.line===d$||R.lineIndent>x){if(T$)c=R.line,I$=R.lineStart,K=R.position;if(FU(R,x,X,!0,e))if(T$)D$=R.result;else z$=R.result;if(!T$)A$(R,$$,U$,Y$,D$,z$,c,I$,K),Y$=D$=z$=null;P$(R,!0,-1),S$=R.input.charCodeAt(R.position)}if((R.line===d$||R.lineIndent>x)&&S$!==0)S(R,"bad indentation of a mapping entry");else if(R.lineIndent<x)break}if(T$)A$(R,$$,U$,Y$,D$,null,c,I$,K);if(j$)R.tag=i,R.anchor=q$,R.kind="mapping",R.result=$$;return j$}function hG(R){let x=!1,d=!1,e,c,I$=R.input.charCodeAt(R.position);if(I$!==33)return!1;if(R.tag!==null)S(R,"duplication of a tag property");if(I$=R.input.charCodeAt(++R.position),I$===60)x=!0,I$=R.input.charCodeAt(++R.position);else if(I$===33)d=!0,e="!!",I$=R.input.charCodeAt(++R.position);else e="!";let K=R.position;if(x){do I$=R.input.charCodeAt(++R.position);while(I$!==0&&I$!==62);if(R.position<R.length)c=R.input.slice(K,R.position),I$=R.input.charCodeAt(++R.position);else S(R,"unexpected end of the stream within a verbatim tag")}else{while(I$!==0&&!F(I$)){if(I$===33)if(!d){if(e=R.input.slice(K-1,R.position+1),!w.test(e))S(R,"named tag handle cannot contain such characters");d=!0,K=R.position+1}else S(R,"tag suffix cannot contain exclamation marks");I$=R.input.charCodeAt(++R.position)}if(c=R.input.slice(K,R.position),M.test(c))S(R,"tag suffix cannot contain flow indicator characters")}if(c&&!H.test(c))S(R,"tag name cannot contain such characters: "+c);try{c=decodeURIComponent(c)}catch(i){S(R,"tag name is malformed: "+c)}if(x)R.tag=c;else if(q.call(R.tagMap,e))R.tag=R.tagMap[e]+c;else if(e==="!")R.tag="!"+c;else if(e==="!!")R.tag="tag:yaml.org,2002:"+c;else S(R,'undeclared tag handle "'+e+'"');return!0}function _q(R){let x=R.input.charCodeAt(R.position);if(x!==38)return!1;if(R.anchor!==null)S(R,"duplication of an anchor property");x=R.input.charCodeAt(++R.position);let d=R.position;while(x!==0&&!F(x)&&!f(x))x=R.input.charCodeAt(++R.position);if(R.position===d)S(R,"name of an anchor node must contain at least one character");return R.anchor=R.input.slice(d,R.position),!0}function rG(R){let x=R.input.charCodeAt(R.position);if(x!==42)return!1;x=R.input.charCodeAt(++R.position);let d=R.position;while(x!==0&&!F(x)&&!f(x))x=R.input.charCodeAt(++R.position);if(R.position===d)S(R,"name of an alias node must contain at least one character");let e=R.input.slice(d,R.position);if(!q.call(R.anchorMap,e))S(R,'unidentified alias "'+e+'"');return R.result=R.anchorMap[e],P$(R,!0,-1),!0}function F6(R,x,d,e){let c=G$(R);if(l(R),B(R,x),R.tag=null,R.anchor=null,R.kind=null,R.result=null,mG(R,d,e)&&R.kind==="mapping")return A(R),!0;return o(R),B(R,c),!1}function FU(R,x,d,e,c){let I$,K,i=1,q$=!1,$$=!1,U$=null,Y$,D$,z$;if(R.depth>=R.maxDepth)S(R,"nesting exceeded maxDepth ("+R.maxDepth+")");if(R.depth+=1,R.listener!==null)R.listener("open",R);R.tag=null,R.anchor=null,R.kind=null,R.result=null;let T$=I$=K=X===d||D===d;if(e){if(P$(R,!0,-1)){if(q$=!0,R.lineIndent>x)i=1;else if(R.lineIndent===x)i=0;else if(R.lineIndent<x)i=-1}}if(i===1)while(!0){let j$=R.input.charCodeAt(R.position),S$=G$(R);if(q$&&(j$===33&&R.tag!==null||j$===38&&R.anchor!==null))break;if(!hG(R)&&!_q(R))break;if(U$===null)U$=S$;if(P$(R,!0,-1)){if(q$=!0,K=T$,R.lineIndent>x)i=1;else if(R.lineIndent===x)i=0;else if(R.lineIndent<x)i=-1}else K=!1}if(K)K=q$||c;if(i===1||X===d){if(I===d||Q===d)D$=x;else D$=x+1;if(z$=R.position-R.lineStart,i===1)if(K&&(KU(R,z$)||mG(R,z$,D$))||YU(R,D$))$$=!0;else{let j$=R.input.charCodeAt(R.position);if(U$!==null&&T$&&!K&&j$!==124&&j$!==62&&F6(R,U$,U$.position-U$.lineStart,D$))$$=!0;else if(I$&&VU(R,D$)||J0(R,D$)||E0(R,D$))$$=!0;else if(rG(R)){if($$=!0,R.tag!==null||R.anchor!==null)S(R,"alias node should not have any properties")}else if(o$(R,D$,I===d)){if($$=!0,R.tag===null)R.tag="?"}if(R.anchor!==null)u(R,R.anchor,R.result)}else if(i===0)$$=K&&KU(R,z$)}if(R.tag===null){if(R.anchor!==null)u(R,R.anchor,R.result)}else if(R.tag==="?"){if(R.result!==null&&R.kind!=="scalar")S(R,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+R.kind+'"');for(let j$=0,S$=R.implicitTypes.length;j$<S$;j$+=1)if(Y$=R.implicitTypes[j$],Y$.resolve(R.result)){if(R.result=Y$.construct(R.result),R.tag=Y$.tag,R.anchor!==null)u(R,R.anchor,R.result);break}}else if(R.tag!=="!"){if(q.call(R.typeMap[R.kind||"fallback"],R.tag))Y$=R.typeMap[R.kind||"fallback"][R.tag];else{Y$=null;let j$=R.typeMap.multi[R.kind||"fallback"];for(let S$=0,k$=j$.length;S$<k$;S$+=1)if(R.tag.slice(0,j$[S$].tag.length)===j$[S$].tag){Y$=j$[S$];break}}if(!Y$)S(R,"unknown tag !<"+R.tag+">");if(R.result!==null&&Y$.kind!==R.kind)S(R,"unacceptable node kind for !<"+R.tag+'> tag; it should be "'+Y$.kind+'", not "'+R.kind+'"');if(!Y$.resolve(R.result,R.tag))S(R,"cannot resolve a node with !<"+R.tag+"> explicit tag");else if(R.result=Y$.construct(R.result,R.tag),R.anchor!==null)u(R,R.anchor,R.result)}if(R.listener!==null)R.listener("close",R);return R.depth-=1,R.tag!==null||R.anchor!==null||$$}function b6(R){let x=R.position,d=!1,e;R.version=null,R.checkLineBreaks=R.legacy,R.tagMap=Object.create(null),R.anchorMap=Object.create(null);while((e=R.input.charCodeAt(R.position))!==0){if(P$(R,!0,-1),e=R.input.charCodeAt(R.position),R.lineIndent>0||e!==37)break;d=!0,e=R.input.charCodeAt(++R.position);let c=R.position;while(e!==0&&!F(e))e=R.input.charCodeAt(++R.position);let I$=R.input.slice(c,R.position),K=[];if(I$.length<1)S(R,"directive name must not be less than one character in length");while(e!==0){while(C(e))e=R.input.charCodeAt(++R.position);if(e===35){do e=R.input.charCodeAt(++R.position);while(e!==0&&!P(e));break}if(P(e))break;c=R.position;while(e!==0&&!F(e))e=R.input.charCodeAt(++R.position);K.push(R.input.slice(c,R.position))}if(e!==0)w$(R);if(q.call(R$,I$))R$[I$](R,I$,K);else y(R,'unknown document directive "'+I$+'"')}if(P$(R,!0,-1),R.lineIndent===0&&R.input.charCodeAt(R.position)===45&&R.input.charCodeAt(R.position+1)===45&&R.input.charCodeAt(R.position+2)===45)R.position+=3,P$(R,!0,-1);else if(d)S(R,"directives end mark is expected");if(FU(R,R.lineIndent-1,X,!1,!0),P$(R,!0,-1),R.checkLineBreaks&&Z.test(R.input.slice(x,R.position)))y(R,"non-ASCII line breaks are interpreted as content");if(R.documents.push(R.result),R.position===R.lineStart&&u$(R)){if(R.input.charCodeAt(R.position)===46)R.position+=3,P$(R,!0,-1);return}if(R.position<R.length-1)S(R,"end of the stream or a document separator is expected")}function lG(R,x){if(R=String(R),x=x||{},R.length!==0){if(R.charCodeAt(R.length-1)!==10&&R.charCodeAt(R.length-1)!==13)R+=`
|
|
18
|
+
`;if(R.charCodeAt(0)===65279)R=R.slice(1)}let d=new j(R,x),e=R.indexOf("\x00");if(e!==-1)d.position=e,S(d,"null byte is not allowed in input");d.input+="\x00";while(d.input.charCodeAt(d.position)===32)d.lineIndent+=1,d.position+=1;while(d.position<d.length-1)b6(d);return d.documents}function a(R,x,d){if(x!==null&&typeof x==="object"&&typeof d>"u")d=x,x=null;let e=lG(R,d);if(typeof x!=="function")return e;for(let c=0,I$=e.length;c<I$;c+=1)x(e[c])}function t(R,x){let d=lG(R,x);if(d.length===0)return;else if(d.length===1)return d[0];throw new U("expected a single document in the stream, but found more")}return NQ.loadAll=a,NQ.load=t,NQ}function CF(){if(gT)return HV;gT=1;let $=x6(),U=f6(),J=TV(),G=Object.prototype.toString,q=Object.prototype.hasOwnProperty,I=65279,Q=9,D=10,X=13,Y=32,V=33,W=34,O=35,Z=37,M=38,w=39,H=42,g=44,P=45,C=58,F=61,f=62,E=63,p=64,b=91,h=93,s=96,m=123,_=124,v=125,j={};j[0]="\\0",j[7]="\\a",j[8]="\\b",j[9]="\\t",j[10]="\\n",j[11]="\\v",j[12]="\\f",j[13]="\\r",j[27]="\\e",j[34]="\\\"",j[92]="\\\\",j[133]="\\N",j[160]="\\_",j[8232]="\\L",j[8233]="\\P";let L=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"],S=/^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;function y(K,i){if(i===null)return{};let q$={},$$=Object.keys(i);for(let U$=0,Y$=$$.length;U$<Y$;U$+=1){let D$=$$[U$],z$=String(i[D$]);if(D$.slice(0,2)==="!!")D$="tag:yaml.org,2002:"+D$.slice(2);let T$=K.compiledTypeMap.fallback[D$];if(T$&&q.call(T$.styleAliases,z$))z$=T$.styleAliases[z$];q$[D$]=z$}return q$}function u(K){let i,q$,$$=K.toString(16).toUpperCase();if(K<=255)i="x",q$=2;else if(K<=65535)i="u",q$=4;else if(K<=4294967295)i="U",q$=8;else throw new U("code point within a string may not be greater than 0xFFFFFFFF");return"\\"+i+$.repeat("0",q$-$$.length)+$$}let l=1,A=2;function o(K){this.schema=K.schema||J,this.indent=Math.max(1,K.indent||2),this.noArrayIndent=K.noArrayIndent||!1,this.skipInvalid=K.skipInvalid||!1,this.flowLevel=$.isNothing(K.flowLevel)?-1:K.flowLevel,this.styleMap=y(this.schema,K.styles||null),this.sortKeys=K.sortKeys||!1,this.lineWidth=K.lineWidth||80,this.noRefs=K.noRefs||!1,this.noCompatMode=K.noCompatMode||!1,this.condenseFlow=K.condenseFlow||!1,this.quotingType=K.quotingType==='"'?A:l,this.forceQuotes=K.forceQuotes||!1,this.replacer=typeof K.replacer==="function"?K.replacer:null,this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}function G$(K,i){let q$=$.repeat(" ",i),$$=0,U$="",Y$=K.length;while($$<Y$){let D$,z$=K.indexOf(`
|
|
19
|
+
`,$$);if(z$===-1)D$=K.slice($$),$$=Y$;else D$=K.slice($$,z$+1),$$=z$+1;if(D$.length&&D$!==`
|
|
20
|
+
`)U$+=q$;U$+=D$}return U$}function B(K,i){return`
|
|
21
|
+
`+$.repeat(" ",K.indent*i)}function R$(K,i){for(let q$=0,$$=K.implicitTypes.length;q$<$$;q$+=1)if(K.implicitTypes[q$].resolve(i))return!0;return!1}function H$(K){return K===Y||K===Q}function K$(K){return K>=32&&K<=126||K>=161&&K<=55295&&K!==8232&&K!==8233||K>=57344&&K<=65533&&K!==I||K>=65536&&K<=1114111}function A$(K){return K$(K)&&K!==I&&K!==X&&K!==D}function w$(K,i,q$){let $$=A$(K),U$=$$&&!H$(K);return(q$?$$:$$&&K!==g&&K!==b&&K!==h&&K!==m&&K!==v)&&K!==O&&!(i===C&&!U$)||A$(i)&&!H$(i)&&K===O||i===C&&U$}function P$(K){return K$(K)&&K!==I&&!H$(K)&&K!==P&&K!==E&&K!==C&&K!==g&&K!==b&&K!==h&&K!==m&&K!==v&&K!==O&&K!==M&&K!==H&&K!==V&&K!==_&&K!==F&&K!==f&&K!==w&&K!==W&&K!==Z&&K!==p&&K!==s}function u$(K){return!H$(K)&&K!==C}function m$(K,i){let q$=K.charCodeAt(i),$$;if(q$>=55296&&q$<=56319&&i+1<K.length){if($$=K.charCodeAt(i+1),$$>=56320&&$$<=57343)return(q$-55296)*1024+$$-56320+65536}return q$}function o$(K){return/^\n* /.test(K)}let J0=1,E0=2,YU=3,VU=4,KU=5;function mG(K,i,q$,$$,U$,Y$,D$,z$){let T$,j$=0,S$=null,k$=!1,d$=!1,iH=$$!==-1,u6=-1,k6=P$(m$(K,0))&&u$(m$(K,K.length-1));if(i||D$)for(T$=0;T$<K.length;j$>=65536?T$+=2:T$++){if(j$=m$(K,T$),!K$(j$))return KU;k6=k6&&w$(j$,S$,z$),S$=j$}else{for(T$=0;T$<K.length;j$>=65536?T$+=2:T$++){if(j$=m$(K,T$),j$===D){if(k$=!0,iH)d$=d$||T$-u6-1>$$&&K[u6+1]!==" ",u6=T$}else if(!K$(j$))return KU;k6=k6&&w$(j$,S$,z$),S$=j$}d$=d$||iH&&(T$-u6-1>$$&&K[u6+1]!==" ")}if(!k$&&!d$){if(k6&&!D$&&!U$(K))return J0;return Y$===A?KU:E0}if(q$>9&&o$(K))return KU;if(!D$)return d$?VU:YU;return Y$===A?KU:E0}function hG(K,i,q$,$$,U$){K.dump=function(){if(i.length===0)return K.quotingType===A?'""':"''";if(!K.noCompatMode){if(L.indexOf(i)!==-1||S.test(i))return K.quotingType===A?'"'+i+'"':"'"+i+"'"}let Y$=K.indent*Math.max(1,q$),D$=K.lineWidth===-1?-1:Math.max(Math.min(K.lineWidth,40),K.lineWidth-Y$),z$=$$||K.flowLevel>-1&&q$>=K.flowLevel;function T$(j$){return R$(K,j$)}switch(mG(i,z$,K.indent,D$,T$,K.quotingType,K.forceQuotes&&!$$,U$)){case J0:return i;case E0:return"'"+i.replace(/'/g,"''")+"'";case YU:return"|"+_q(i,K.indent)+rG(G$(i,Y$));case VU:return">"+_q(i,K.indent)+rG(G$(F6(i,D$),Y$));case KU:return'"'+b6(i)+'"';default:throw new U("impossible error: invalid scalar style")}}()}function _q(K,i){let q$=o$(K)?String(i):"",$$=K[K.length-1]===`
|
|
22
|
+
`,Y$=$$&&(K[K.length-2]===`
|
|
23
|
+
`||K===`
|
|
24
|
+
`)?"+":$$?"":"-";return q$+Y$+`
|
|
25
|
+
`}function rG(K){return K[K.length-1]===`
|
|
26
|
+
`?K.slice(0,-1):K}function F6(K,i){let q$=/(\n+)([^\n]*)/g,$$=function(){let z$=K.indexOf(`
|
|
27
|
+
`);return z$=z$!==-1?z$:K.length,q$.lastIndex=z$,FU(K.slice(0,z$),i)}(),U$=K[0]===`
|
|
28
|
+
`||K[0]===" ",Y$,D$;while(D$=q$.exec(K)){let z$=D$[1],T$=D$[2];Y$=T$[0]===" ",$$+=z$+(!U$&&!Y$&&T$!==""?`
|
|
29
|
+
`:"")+FU(T$,i),U$=Y$}return $$}function FU(K,i){if(K===""||K[0]===" ")return K;let q$=/ [^ ]/g,$$,U$=0,Y$,D$=0,z$=0,T$="";while($$=q$.exec(K)){if(z$=$$.index,z$-U$>i)Y$=D$>U$?D$:z$,T$+=`
|
|
30
|
+
`+K.slice(U$,Y$),U$=Y$+1;D$=z$}if(T$+=`
|
|
31
|
+
`,K.length-U$>i&&D$>U$)T$+=K.slice(U$,D$)+`
|
|
32
|
+
`+K.slice(D$+1);else T$+=K.slice(U$);return T$.slice(1)}function b6(K){let i="",q$=0;for(let $$=0;$$<K.length;q$>=65536?$$+=2:$$++){q$=m$(K,$$);let U$=j[q$];if(!U$&&K$(q$)){if(i+=K[$$],q$>=65536)i+=K[$$+1]}else i+=U$||u(q$)}return i}function lG(K,i,q$){let $$="",U$=K.tag;for(let Y$=0,D$=q$.length;Y$<D$;Y$+=1){let z$=q$[Y$];if(K.replacer)z$=K.replacer.call(q$,String(Y$),z$);if(d(K,i,z$,!1,!1)||typeof z$>"u"&&d(K,i,null,!1,!1)){if($$!=="")$$+=","+(!K.condenseFlow?" ":"");$$+=K.dump}}K.tag=U$,K.dump="["+$$+"]"}function a(K,i,q$,$$){let U$="",Y$=K.tag;for(let D$=0,z$=q$.length;D$<z$;D$+=1){let T$=q$[D$];if(K.replacer)T$=K.replacer.call(q$,String(D$),T$);if(d(K,i+1,T$,!0,!0,!1,!0)||typeof T$>"u"&&d(K,i+1,null,!0,!0,!1,!0)){if(!$$||U$!=="")U$+=B(K,i);if(K.dump&&D===K.dump.charCodeAt(0))U$+="-";else U$+="- ";U$+=K.dump}}K.tag=Y$,K.dump=U$||"[]"}function t(K,i,q$){let $$="",U$=K.tag,Y$=Object.keys(q$);for(let D$=0,z$=Y$.length;D$<z$;D$+=1){let T$="";if($$!=="")T$+=", ";if(K.condenseFlow)T$+='"';let j$=Y$[D$],S$=q$[j$];if(K.replacer)S$=K.replacer.call(q$,j$,S$);if(!d(K,i,j$,!1,!1))continue;if(K.dump.length>1024)T$+="? ";if(T$+=K.dump+(K.condenseFlow?'"':"")+":"+(K.condenseFlow?"":" "),!d(K,i,S$,!1,!1))continue;T$+=K.dump,$$+=T$}K.tag=U$,K.dump="{"+$$+"}"}function R(K,i,q$,$$){let U$="",Y$=K.tag,D$=Object.keys(q$);if(K.sortKeys===!0)D$.sort();else if(typeof K.sortKeys==="function")D$.sort(K.sortKeys);else if(K.sortKeys)throw new U("sortKeys must be a boolean or a function");for(let z$=0,T$=D$.length;z$<T$;z$+=1){let j$="";if(!$$||U$!=="")j$+=B(K,i);let S$=D$[z$],k$=q$[S$];if(K.replacer)k$=K.replacer.call(q$,S$,k$);if(!d(K,i+1,S$,!0,!0,!0))continue;let d$=K.tag!==null&&K.tag!=="?"||K.dump&&K.dump.length>1024;if(d$)if(K.dump&&D===K.dump.charCodeAt(0))j$+="?";else j$+="? ";if(j$+=K.dump,d$)j$+=B(K,i);if(!d(K,i+1,k$,!0,d$))continue;if(K.dump&&D===K.dump.charCodeAt(0))j$+=":";else j$+=": ";j$+=K.dump,U$+=j$}K.tag=Y$,K.dump=U$||"{}"}function x(K,i,q$){let $$=q$?K.explicitTypes:K.implicitTypes;for(let U$=0,Y$=$$.length;U$<Y$;U$+=1){let D$=$$[U$];if((D$.instanceOf||D$.predicate)&&(!D$.instanceOf||typeof i==="object"&&i instanceof D$.instanceOf)&&(!D$.predicate||D$.predicate(i))){if(q$)if(D$.multi&&D$.representName)K.tag=D$.representName(i);else K.tag=D$.tag;else K.tag="?";if(D$.represent){let z$=K.styleMap[D$.tag]||D$.defaultStyle,T$;if(G.call(D$.represent)==="[object Function]")T$=D$.represent(i,z$);else if(q.call(D$.represent,z$))T$=D$.represent[z$](i,z$);else throw new U("!<"+D$.tag+'> tag resolver accepts not "'+z$+'" style');K.dump=T$}return!0}}return!1}function d(K,i,q$,$$,U$,Y$,D$){if(K.tag=null,K.dump=q$,!x(K,q$,!1))x(K,q$,!0);let z$=G.call(K.dump),T$=$$;if($$)$$=K.flowLevel<0||K.flowLevel>i;let j$=z$==="[object Object]"||z$==="[object Array]",S$,k$;if(j$)S$=K.duplicates.indexOf(q$),k$=S$!==-1;if(K.tag!==null&&K.tag!=="?"||k$||K.indent!==2&&i>0)U$=!1;if(k$&&K.usedDuplicates[S$])K.dump="*ref_"+S$;else{if(j$&&k$&&!K.usedDuplicates[S$])K.usedDuplicates[S$]=!0;if(z$==="[object Object]"){if($$&&Object.keys(K.dump).length!==0){if(R(K,i,K.dump,U$),k$)K.dump="&ref_"+S$+K.dump}else if(t(K,i,K.dump),k$)K.dump="&ref_"+S$+" "+K.dump}else if(z$==="[object Array]"){if($$&&K.dump.length!==0){if(K.noArrayIndent&&!D$&&i>0)a(K,i-1,K.dump,U$);else a(K,i,K.dump,U$);if(k$)K.dump="&ref_"+S$+K.dump}else if(lG(K,i,K.dump),k$)K.dump="&ref_"+S$+" "+K.dump}else if(z$==="[object String]"){if(K.tag!=="?")hG(K,K.dump,i,Y$,T$)}else if(z$==="[object Undefined]")return!1;else{if(K.skipInvalid)return!1;throw new U("unacceptable kind of an object to dump "+z$)}if(K.tag!==null&&K.tag!=="?"){let d$=encodeURI(K.tag[0]==="!"?K.tag.slice(1):K.tag).replace(/!/g,"%21");if(K.tag[0]==="!")d$="!"+d$;else if(d$.slice(0,18)==="tag:yaml.org,2002:")d$="!!"+d$.slice(18);else d$="!<"+d$+">";K.dump=d$+" "+K.dump}}return!0}function e(K,i){let q$=[],$$=[];c(K,q$,$$);let U$=$$.length;for(let Y$=0;Y$<U$;Y$+=1)i.duplicates.push(q$[$$[Y$]]);i.usedDuplicates=Array(U$)}function c(K,i,q$){if(K!==null&&typeof K==="object"){let $$=i.indexOf(K);if($$!==-1){if(q$.indexOf($$)===-1)q$.push($$)}else if(i.push(K),Array.isArray(K))for(let U$=0,Y$=K.length;U$<Y$;U$+=1)c(K[U$],i,q$);else{let U$=Object.keys(K);for(let Y$=0,D$=U$.length;Y$<D$;Y$+=1)c(K[U$[Y$]],i,q$)}}}function I$(K,i){i=i||{};let q$=new o(i);if(!q$.noRefs)e(K,q$);let $$=K;if(q$.replacer)$$=q$.replacer.call({"":$$},"",$$);if(d(q$,0,$$,!0,!0))return q$.dump+`
|
|
33
|
+
`;return""}return HV.dump=I$,HV}function _F(){if(jT)return C0;jT=1;let $=EF(),U=CF();function J(G,q){return function(){throw Error("Function yaml."+G+" is removed in js-yaml 4. Use yaml."+q+" instead, which is now safe by default.")}}return C0.Type=h0(),C0.Schema=PT(),C0.FAILSAFE_SCHEMA=ET(),C0.JSON_SCHEMA=bT(),C0.CORE_SCHEMA=uT(),C0.DEFAULT_SCHEMA=TV(),C0.load=$.load,C0.loadAll=$.loadAll,C0.dump=U.dump,C0.YAMLException=f6(),C0.types={binary:fT(),float:FT(),map:LT(),null:CT(),pairs:mT(),set:hT(),timestamp:kT(),bool:_T(),int:vT(),merge:xT(),omap:yT(),seq:ST(),str:BT()},C0.safeLoad=J("safeLoad","load"),C0.safeLoadAll=J("safeLoadAll","loadAll"),C0.safeDump=J("safeDump","dump"),C0}var C0,NQ,fJ,$T,sY,UT,tY,JT,eY,qT,$V,GT,UV,IT,JV,QT,qV,DT,GV,XT,IV,YT,QV,VT,DV,WT,XV,OT,YV,ZT,VV,RT,WV,NT,OV,wT,ZV,MT,RV,HT,NV,TT,wV,zT,MV,AT,KT,HV,gT,jT,vF,FF,D8$,X8$,Y8$,V8$,W8$,O8$,wQ,Z8$,zV,R8$,N8$,w8$,M8$,H8$;var MQ=O$(()=>{C0={},NQ={},fJ={};HV={};vF=_F(),FF=SF(vF),{Type:D8$,Schema:X8$,FAILSAFE_SCHEMA:Y8$,JSON_SCHEMA:V8$,CORE_SCHEMA:W8$,DEFAULT_SCHEMA:O8$,load:wQ,loadAll:Z8$,dump:zV,YAMLException:R8$,types:N8$,safeLoad:w8$,safeLoadAll:M8$,safeDump:H8$}=FF});function q0($,U){if($ instanceof Error)return $.message;return U??String($)}function pG($){return zV($,{skipInvalid:!0,noRefs:!0,sortKeys:!0})}function rT($){return wQ($)}function dG($,U){if(!$.trim())return{ok:!1,error:"file is empty"};let J;try{J=wQ($)}catch(q){return{ok:!1,error:q0(q,"YAML parse error")}}if(!bF(J))return{ok:!1,error:"expected a YAML mapping (key: value pairs)"};if(!U)return{ok:!0,data:J};let G=U.safeParse(J);if(!G.success)return{ok:!1,error:`invalid field(s): ${G.error.issues.map((I)=>I.path.map(String).join(".")).join(", ")}`};return{ok:!0,data:G.data}}function bF($){return Boolean($)&&typeof $==="object"&&!Array.isArray($)}var vq=O$(()=>{MQ()});function r($,U,J){function G(D,X){if(!D._zod)Object.defineProperty(D,"_zod",{value:{def:X,constr:Q,traits:new Set},enumerable:!1});if(D._zod.traits.has($))return;D._zod.traits.add($),U(D,X);let Y=Q.prototype,V=Object.keys(Y);for(let W=0;W<V.length;W++){let O=V[W];if(!(O in D))D[O]=Y[O].bind(D)}}let q=J?.Parent??Object;class I extends q{}Object.defineProperty(I,"name",{value:$});function Q(D){var X;let Y=J?.Parent?new I:this;G(Y,D),(X=Y._zod).deferred??(X.deferred=[]);for(let V of Y._zod.deferred)V();return Y}return Object.defineProperty(Q,"init",{value:G}),Object.defineProperty(Q,Symbol.hasInstance,{value:(D)=>{if(J?.Parent&&D instanceof J.Parent)return!0;return D?._zod?.traits?.has($)}}),Object.defineProperty(Q,"name",{value:$}),Q}function a$($){if($)Object.assign(Fq,$);return Fq}var lT,KV,gV,pU,bq,Fq;var uq=O$(()=>{KV=Object.freeze({status:"aborted"});gV=Symbol("zod_brand");pU=class pU extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}};bq=class bq extends Error{constructor($){super(`Encountered unidirectional transform during encode: ${$}`);this.name="ZodEncodeError"}};(lT=globalThis).__zod_globalConfig??(lT.__zod_globalConfig={});Fq=globalThis.__zod_globalConfig});var V$={};UU(V$,{unwrapMessage:()=>m6,uint8ArrayToHex:()=>Ib,uint8ArrayToBase64url:()=>qb,uint8ArrayToBase64:()=>dT,stringifyPrimitive:()=>Q$,slugify:()=>BV,shallowClone:()=>LV,safeExtend:()=>sF,required:()=>$b,randomString:()=>iF,propertyKeyTypes:()=>l6,promiseAllObject:()=>lF,primitiveTypes:()=>EV,prefixIssues:()=>JU,pick:()=>cF,partial:()=>eF,parsedType:()=>X$,optionalKeys:()=>CV,omit:()=>oF,objectClone:()=>mF,numKeys:()=>pF,nullish:()=>yJ,normalizeParams:()=>Z$,mergeDefs:()=>WJ,merge:()=>tF,jsonStringifyReplacer:()=>nG,joinValues:()=>n,issue:()=>oG,isPlainObject:()=>hJ,isObject:()=>kq,hexToUint8Array:()=>Gb,getSizableOrigin:()=>i6,getParsedType:()=>dF,getLengthableOrigin:()=>p6,getEnumValues:()=>h6,getElementAtPath:()=>rF,floatSafeRemainder:()=>PV,finalizeIssue:()=>l0,extend:()=>aF,explicitlyAborted:()=>FV,escapeRegex:()=>gU,esc:()=>HQ,defineLazy:()=>F$,createTransparentProxy:()=>nF,cloneDef:()=>hF,clone:()=>r0,cleanRegex:()=>r6,cleanEnum:()=>Ub,captureStackTrace:()=>TQ,cached:()=>cG,base64urlToUint8Array:()=>Jb,base64ToUint8Array:()=>pT,assignProp:()=>mJ,assertNotEqual:()=>kF,assertNever:()=>fF,assertIs:()=>xF,assertEqual:()=>uF,assert:()=>yF,allowsEval:()=>SV,aborted:()=>rJ,NUMBER_FORMAT_RANGES:()=>_V,Class:()=>nT,BIGINT_FORMAT_RANGES:()=>vV});function uF($){return $}function kF($){return $}function xF($){}function fF($){throw Error("Unexpected value in exhaustive check")}function yF($){}function h6($){let U=Object.values($).filter((G)=>typeof G==="number");return Object.entries($).filter(([G,q])=>U.indexOf(+G)===-1).map(([G,q])=>q)}function n($,U="|"){return $.map((J)=>Q$(J)).join(U)}function nG($,U){if(typeof U==="bigint")return U.toString();return U}function cG($){return{get value(){{let J=$();return Object.defineProperty(this,"value",{value:J}),J}throw Error("cached value already set")}}}function yJ($){return $===null||$===void 0}function r6($){let U=$.startsWith("^")?1:0,J=$.endsWith("$")?$.length-1:$.length;return $.slice(U,J)}function PV($,U){let J=$/U,G=Math.round(J),q=Number.EPSILON*Math.max(Math.abs(J),1);if(Math.abs(J-G)<q)return 0;return J-G}function F$($,U,J){let G=void 0;Object.defineProperty($,U,{get(){if(G===iT)return;if(G===void 0)G=iT,G=J();return G},set(q){Object.defineProperty($,U,{value:q})},configurable:!0})}function mF($){return Object.create(Object.getPrototypeOf($),Object.getOwnPropertyDescriptors($))}function mJ($,U,J){Object.defineProperty($,U,{value:J,writable:!0,enumerable:!0,configurable:!0})}function WJ(...$){let U={};for(let J of $){let G=Object.getOwnPropertyDescriptors(J);Object.assign(U,G)}return Object.defineProperties({},U)}function hF($){return WJ($._zod.def)}function rF($,U){if(!U)return $;return U.reduce((J,G)=>J?.[G],$)}function lF($){let U=Object.keys($),J=U.map((G)=>$[G]);return Promise.all(J).then((G)=>{let q={};for(let I=0;I<U.length;I++)q[U[I]]=G[I];return q})}function iF($=10){let J="";for(let G=0;G<$;G++)J+="abcdefghijklmnopqrstuvwxyz"[Math.floor(Math.random()*26)];return J}function HQ($){return JSON.stringify($)}function BV($){return $.toLowerCase().trim().replace(/[^\w\s-]/g,"").replace(/[\s_-]+/g,"-").replace(/^-+|-+$/g,"")}function kq($){return typeof $==="object"&&$!==null&&!Array.isArray($)}function hJ($){if(kq($)===!1)return!1;let U=$.constructor;if(U===void 0)return!0;if(typeof U!=="function")return!0;let J=U.prototype;if(kq(J)===!1)return!1;if(Object.prototype.hasOwnProperty.call(J,"isPrototypeOf")===!1)return!1;return!0}function LV($){if(hJ($))return{...$};if(Array.isArray($))return[...$];if($ instanceof Map)return new Map($);if($ instanceof Set)return new Set($);return $}function pF($){let U=0;for(let J in $)if(Object.prototype.hasOwnProperty.call($,J))U++;return U}function gU($){return $.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function r0($,U,J){let G=new $._zod.constr(U??$._zod.def);if(!U||J?.parent)G._zod.parent=$;return G}function Z$($){let U=$;if(!U)return{};if(typeof U==="string")return{error:()=>U};if(U?.message!==void 0){if(U?.error!==void 0)throw Error("Cannot specify both `message` and `error` params");U.error=U.message}if(delete U.message,typeof U.error==="string")return{...U,error:()=>U.error};return U}function nF($){let U;return new Proxy({},{get(J,G,q){return U??(U=$()),Reflect.get(U,G,q)},set(J,G,q,I){return U??(U=$()),Reflect.set(U,G,q,I)},has(J,G){return U??(U=$()),Reflect.has(U,G)},deleteProperty(J,G){return U??(U=$()),Reflect.deleteProperty(U,G)},ownKeys(J){return U??(U=$()),Reflect.ownKeys(U)},getOwnPropertyDescriptor(J,G){return U??(U=$()),Reflect.getOwnPropertyDescriptor(U,G)},defineProperty(J,G,q){return U??(U=$()),Reflect.defineProperty(U,G,q)}})}function Q$($){if(typeof $==="bigint")return $.toString()+"n";if(typeof $==="string")return`"${$}"`;return`${$}`}function CV($){return Object.keys($).filter((U)=>{return $[U]._zod.optin==="optional"&&$[U]._zod.optout==="optional"})}function cF($,U){let J=$._zod.def,G=J.checks;if(G&&G.length>0)throw Error(".pick() cannot be used on object schemas containing refinements");let I=WJ($._zod.def,{get shape(){let Q={};for(let D in U){if(!(D in J.shape))throw Error(`Unrecognized key: "${D}"`);if(!U[D])continue;Q[D]=J.shape[D]}return mJ(this,"shape",Q),Q},checks:[]});return r0($,I)}function oF($,U){let J=$._zod.def,G=J.checks;if(G&&G.length>0)throw Error(".omit() cannot be used on object schemas containing refinements");let I=WJ($._zod.def,{get shape(){let Q={...$._zod.def.shape};for(let D in U){if(!(D in J.shape))throw Error(`Unrecognized key: "${D}"`);if(!U[D])continue;delete Q[D]}return mJ(this,"shape",Q),Q},checks:[]});return r0($,I)}function aF($,U){if(!hJ(U))throw Error("Invalid input to extend: expected a plain object");let J=$._zod.def.checks;if(J&&J.length>0){let I=$._zod.def.shape;for(let Q in U)if(Object.getOwnPropertyDescriptor(I,Q)!==void 0)throw Error("Cannot overwrite keys on object schemas containing refinements. Use `.safeExtend()` instead.")}let q=WJ($._zod.def,{get shape(){let I={...$._zod.def.shape,...U};return mJ(this,"shape",I),I}});return r0($,q)}function sF($,U){if(!hJ(U))throw Error("Invalid input to safeExtend: expected a plain object");let J=WJ($._zod.def,{get shape(){let G={...$._zod.def.shape,...U};return mJ(this,"shape",G),G}});return r0($,J)}function tF($,U){if($._zod.def.checks?.length)throw Error(".merge() cannot be used on object schemas containing refinements. Use .safeExtend() instead.");let J=WJ($._zod.def,{get shape(){let G={...$._zod.def.shape,...U._zod.def.shape};return mJ(this,"shape",G),G},get catchall(){return U._zod.def.catchall},checks:U._zod.def.checks??[]});return r0($,J)}function eF($,U,J){let q=U._zod.def.checks;if(q&&q.length>0)throw Error(".partial() cannot be used on object schemas containing refinements");let Q=WJ(U._zod.def,{get shape(){let D=U._zod.def.shape,X={...D};if(J)for(let Y in J){if(!(Y in D))throw Error(`Unrecognized key: "${Y}"`);if(!J[Y])continue;X[Y]=$?new $({type:"optional",innerType:D[Y]}):D[Y]}else for(let Y in D)X[Y]=$?new $({type:"optional",innerType:D[Y]}):D[Y];return mJ(this,"shape",X),X},checks:[]});return r0(U,Q)}function $b($,U,J){let G=WJ(U._zod.def,{get shape(){let q=U._zod.def.shape,I={...q};if(J)for(let Q in J){if(!(Q in I))throw Error(`Unrecognized key: "${Q}"`);if(!J[Q])continue;I[Q]=new $({type:"nonoptional",innerType:q[Q]})}else for(let Q in q)I[Q]=new $({type:"nonoptional",innerType:q[Q]});return mJ(this,"shape",I),I}});return r0(U,G)}function rJ($,U=0){if($.aborted===!0)return!0;for(let J=U;J<$.issues.length;J++)if($.issues[J]?.continue!==!0)return!0;return!1}function FV($,U=0){if($.aborted===!0)return!0;for(let J=U;J<$.issues.length;J++)if($.issues[J]?.continue===!1)return!0;return!1}function JU($,U){return U.map((J)=>{var G;return(G=J).path??(G.path=[]),J.path.unshift($),J})}function m6($){return typeof $==="string"?$:$?.message}function l0($,U,J){let G=$.message?$.message:m6($.inst?._zod.def?.error?.($))??m6(U?.error?.($))??m6(J.customError?.($))??m6(J.localeError?.($))??"Invalid input",{inst:q,continue:I,input:Q,...D}=$;if(D.path??(D.path=[]),D.message=G,U?.reportInput)D.input=Q;return D}function i6($){if($ instanceof Set)return"set";if($ instanceof Map)return"map";if($ instanceof File)return"file";return"unknown"}function p6($){if(Array.isArray($))return"array";if(typeof $==="string")return"string";return"unknown"}function X$($){let U=typeof $;switch(U){case"number":return Number.isNaN($)?"nan":"number";case"object":{if($===null)return"null";if(Array.isArray($))return"array";let J=$;if(J&&Object.getPrototypeOf(J)!==Object.prototype&&"constructor"in J&&J.constructor)return J.constructor.name}}return U}function oG(...$){let[U,J,G]=$;if(typeof U==="string")return{message:U,code:"custom",input:J,inst:G};return{...U}}function Ub($){return Object.entries($).filter(([U,J])=>{return Number.isNaN(Number.parseInt(U,10))}).map((U)=>U[1])}function pT($){let U=atob($),J=new Uint8Array(U.length);for(let G=0;G<U.length;G++)J[G]=U.charCodeAt(G);return J}function dT($){let U="";for(let J=0;J<$.length;J++)U+=String.fromCharCode($[J]);return btoa(U)}function Jb($){let U=$.replace(/-/g,"+").replace(/_/g,"/"),J="=".repeat((4-U.length%4)%4);return pT(U+J)}function qb($){return dT($).replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")}function Gb($){let U=$.replace(/^0x/,"");if(U.length%2!==0)throw Error("Invalid hex string length");let J=new Uint8Array(U.length/2);for(let G=0;G<U.length;G+=2)J[G/2]=Number.parseInt(U.slice(G,G+2),16);return J}function Ib($){return Array.from($).map((U)=>U.toString(16).padStart(2,"0")).join("")}class nT{constructor(...$){}}var iT,TQ,SV,dF=($)=>{let U=typeof $;switch(U){case"undefined":return"undefined";case"string":return"string";case"number":return Number.isNaN($)?"nan":"number";case"boolean":return"boolean";case"function":return"function";case"bigint":return"bigint";case"symbol":return"symbol";case"object":if(Array.isArray($))return"array";if($===null)return"null";if($.then&&typeof $.then==="function"&&$.catch&&typeof $.catch==="function")return"promise";if(typeof Map<"u"&&$ instanceof Map)return"map";if(typeof Set<"u"&&$ instanceof Set)return"set";if(typeof Date<"u"&&$ instanceof Date)return"date";if(typeof File<"u"&&$ instanceof File)return"file";return"object";default:throw Error(`Unknown data type: ${U}`)}},l6,EV,_V,vV;var g$=O$(()=>{uq();iT=Symbol("evaluating");TQ="captureStackTrace"in Error?Error.captureStackTrace:(...$)=>{};SV=cG(()=>{if(Fq.jitless)return!1;if(typeof navigator<"u"&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{return new Function(""),!0}catch($){return!1}});l6=new Set(["string","number","symbol"]),EV=new Set(["string","number","bigint","boolean","symbol","undefined"]);_V={safeint:[Number.MIN_SAFE_INTEGER,Number.MAX_SAFE_INTEGER],int32:[-2147483648,2147483647],uint32:[0,4294967295],float32:[-340282346638528860000000000000000000000,340282346638528860000000000000000000000],float64:[-Number.MAX_VALUE,Number.MAX_VALUE]},vV={int64:[BigInt("-9223372036854775808"),BigInt("9223372036854775807")],uint64:[BigInt(0),BigInt("18446744073709551615")]}});function n6($,U=(J)=>J.message){let J={},G=[];for(let q of $.issues)if(q.path.length>0)J[q.path[0]]=J[q.path[0]]||[],J[q.path[0]].push(U(q));else G.push(U(q));return{formErrors:G,fieldErrors:J}}function c6($,U=(J)=>J.message){let J={_errors:[]},G=(q,I=[])=>{for(let Q of q.issues)if(Q.code==="invalid_union"&&Q.errors.length)Q.errors.map((D)=>G({issues:D},[...I,...Q.path]));else if(Q.code==="invalid_key")G({issues:Q.issues},[...I,...Q.path]);else if(Q.code==="invalid_element")G({issues:Q.issues},[...I,...Q.path]);else{let D=[...I,...Q.path];if(D.length===0)J._errors.push(U(Q));else{let X=J,Y=0;while(Y<D.length){let V=D[Y];if(Y!==D.length-1)X[V]=X[V]||{_errors:[]};else X[V]=X[V]||{_errors:[]},X[V]._errors.push(U(Q));X=X[V],Y++}}}};return G($),J}function bV($,U=(J)=>J.message){let J={errors:[]},G=(q,I=[])=>{var Q,D;for(let X of q.issues)if(X.code==="invalid_union"&&X.errors.length)X.errors.map((Y)=>G({issues:Y},[...I,...X.path]));else if(X.code==="invalid_key")G({issues:X.issues},[...I,...X.path]);else if(X.code==="invalid_element")G({issues:X.issues},[...I,...X.path]);else{let Y=[...I,...X.path];if(Y.length===0){J.errors.push(U(X));continue}let V=J,W=0;while(W<Y.length){let O=Y[W],Z=W===Y.length-1;if(typeof O==="string")V.properties??(V.properties={}),(Q=V.properties)[O]??(Q[O]={errors:[]}),V=V.properties[O];else V.items??(V.items=[]),(D=V.items)[O]??(D[O]={errors:[]}),V=V.items[O];if(Z)V.errors.push(U(X));W++}}};return G($),J}function oT($){let U=[],J=$.map((G)=>typeof G==="object"?G.key:G);for(let G of J)if(typeof G==="number")U.push(`[${G}]`);else if(typeof G==="symbol")U.push(`[${JSON.stringify(String(G))}]`);else if(/[^\w$]/.test(G))U.push(`[${JSON.stringify(G)}]`);else{if(U.length)U.push(".");U.push(G)}return U.join("")}function uV($){let U=[],J=[...$.issues].sort((G,q)=>(G.path??[]).length-(q.path??[]).length);for(let G of J)if(U.push(`\u2716 ${G.message}`),G.path?.length)U.push(` \u2192 at ${oT(G.path)}`);return U.join(`
|
|
34
|
+
`)}var cT=($,U)=>{$.name="$ZodError",Object.defineProperty($,"_zod",{value:$._zod,enumerable:!1}),Object.defineProperty($,"issues",{value:U,enumerable:!1}),$.message=JSON.stringify(U,nG,2),Object.defineProperty($,"toString",{value:()=>$.message,enumerable:!1})},d6,qU;var kV=O$(()=>{uq();g$();d6=r("$ZodError",cT),qU=r("$ZodError",cT,{Parent:Error})});var aG=($)=>(U,J,G,q)=>{let I=G?{...G,async:!1}:{async:!1},Q=U._zod.run({value:J,issues:[]},I);if(Q instanceof Promise)throw new pU;if(Q.issues.length){let D=new(q?.Err??$)(Q.issues.map((X)=>l0(X,I,a$())));throw TQ(D,q?.callee),D}return Q.value},zQ,sG=($)=>async(U,J,G,q)=>{let I=G?{...G,async:!0}:{async:!0},Q=U._zod.run({value:J,issues:[]},I);if(Q instanceof Promise)Q=await Q;if(Q.issues.length){let D=new(q?.Err??$)(Q.issues.map((X)=>l0(X,I,a$())));throw TQ(D,q?.callee),D}return Q.value},AQ,tG=($)=>(U,J,G)=>{let q=G?{...G,async:!1}:{async:!1},I=U._zod.run({value:J,issues:[]},q);if(I instanceof Promise)throw new pU;return I.issues.length?{success:!1,error:new($??d6)(I.issues.map((Q)=>l0(Q,q,a$())))}:{success:!0,data:I.value}},xV,eG=($)=>async(U,J,G)=>{let q=G?{...G,async:!0}:{async:!0},I=U._zod.run({value:J,issues:[]},q);if(I instanceof Promise)I=await I;return I.issues.length?{success:!1,error:new $(I.issues.map((Q)=>l0(Q,q,a$())))}:{success:!0,data:I.value}},fV,KQ=($)=>(U,J,G)=>{let q=G?{...G,direction:"backward"}:{direction:"backward"};return aG($)(U,J,q)},Db,gQ=($)=>(U,J,G)=>{return aG($)(U,J,G)},Xb,jQ=($)=>async(U,J,G)=>{let q=G?{...G,direction:"backward"}:{direction:"backward"};return sG($)(U,J,q)},Yb,PQ=($)=>async(U,J,G)=>{return sG($)(U,J,G)},Vb,BQ=($)=>(U,J,G)=>{let q=G?{...G,direction:"backward"}:{direction:"backward"};return tG($)(U,J,q)},Wb,SQ=($)=>(U,J,G)=>{return tG($)(U,J,G)},Ob,LQ=($)=>async(U,J,G)=>{let q=G?{...G,direction:"backward"}:{direction:"backward"};return eG($)(U,J,q)},Zb,EQ=($)=>async(U,J,G)=>{return eG($)(U,J,G)},Rb;var yV=O$(()=>{uq();kV();g$();zQ=aG(qU),AQ=sG(qU),xV=tG(qU),fV=eG(qU),Db=KQ(qU),Xb=gQ(qU),Yb=jQ(qU),Vb=PQ(qU),Wb=BQ(qU),Ob=SQ(qU),Zb=LQ(qU),Rb=EQ(qU)});var OU={};UU(OU,{xid:()=>lV,uuid7:()=>Hb,uuid6:()=>Mb,uuid4:()=>wb,uuid:()=>xq,uppercase:()=>RW,unicodeEmail:()=>aT,undefined:()=>OW,ulid:()=>rV,time:()=>IW,string:()=>DW,sha512_hex:()=>yb,sha512_base64url:()=>hb,sha512_base64:()=>mb,sha384_hex:()=>kb,sha384_base64url:()=>fb,sha384_base64:()=>xb,sha256_hex:()=>Fb,sha256_base64url:()=>ub,sha256_base64:()=>bb,sha1_hex:()=>Cb,sha1_base64url:()=>vb,sha1_base64:()=>_b,rfc5322Email:()=>zb,number:()=>o6,null:()=>WW,nanoid:()=>pV,md5_hex:()=>Sb,md5_base64url:()=>Eb,md5_base64:()=>Lb,mac:()=>tV,lowercase:()=>ZW,ksuid:()=>iV,ipv6:()=>sV,ipv4:()=>aV,integer:()=>YW,idnEmail:()=>Ab,httpProtocol:()=>JW,html5Email:()=>Tb,hostname:()=>jb,hex:()=>Bb,guid:()=>nV,extendedDuration:()=>Nb,emoji:()=>oV,email:()=>cV,e164:()=>qW,duration:()=>dV,domain:()=>Pb,datetime:()=>QW,date:()=>GW,cuid2:()=>hV,cuid:()=>mV,cidrv6:()=>$W,cidrv4:()=>eV,browserEmail:()=>Kb,boolean:()=>VW,bigint:()=>XW,base64url:()=>CQ,base64:()=>UW});function oV(){return new RegExp(gb,"u")}function tT($){return typeof $.precision==="number"?$.precision===-1?"(?:[01]\\d|2[0-3]):[0-5]\\d":$.precision===0?"(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d":`(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d\\.\\d{${$.precision}}`:"(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?"}function IW($){return new RegExp(`^${tT($)}$`)}function QW($){let U=tT({precision:$.precision}),J=["Z"];if($.local)J.push("");if($.offset)J.push("([+-](?:[01]\\d|2[0-3]):[0-5]\\d)");let G=`${U}(?:${J.join("|")})`;return new RegExp(`^${sT}T(?:${G})$`)}function a6($,U){return new RegExp(`^[A-Za-z0-9+/]{${$}}${U}$`)}function s6($){return new RegExp(`^[A-Za-z0-9_-]{${$}}$`)}var mV,hV,rV,lV,iV,pV,dV,Nb,nV,xq=($)=>{if(!$)return/^([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)$/;return new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${$}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`)},wb,Mb,Hb,cV,Tb,zb,aT,Ab,Kb,gb="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$",aV,sV,tV=($)=>{let U=gU($??":");return new RegExp(`^(?:[0-9A-F]{2}${U}){5}[0-9A-F]{2}$|^(?:[0-9a-f]{2}${U}){5}[0-9a-f]{2}$`)},eV,$W,UW,CQ,jb,Pb,JW,qW,sT="(?:(?:\\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])))",GW,DW=($)=>{let U=$?`[\\s\\S]{${$?.minimum??0},${$?.maximum??""}}`:"[\\s\\S]*";return new RegExp(`^${U}$`)},XW,YW,o6,VW,WW,OW,ZW,RW,Bb,Sb,Lb,Eb,Cb,_b,vb,Fb,bb,ub,kb,xb,fb,yb,mb,hb;var _Q=O$(()=>{g$();mV=/^[cC][0-9a-z]{6,}$/,hV=/^[0-9a-z]+$/,rV=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,lV=/^[0-9a-vA-V]{20}$/,iV=/^[A-Za-z0-9]{27}$/,pV=/^[a-zA-Z0-9_-]{21}$/,dV=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,Nb=/^[-+]?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)?)??$/,nV=/^([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})$/,wb=xq(4),Mb=xq(6),Hb=xq(7),cV=/^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,Tb=/^[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])?)*$/,zb=/^(([^<>()\[\]\\.,;:\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,}))$/,aT=/^[^\s@"]{1,64}@[^\s@]{1,255}$/u,Ab=aT,Kb=/^[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])?)*$/;aV=/^(?:(?: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])$/,sV=/^(([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}|:))$/,eV=/^((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])$/,$W=/^(([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])$/,UW=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,CQ=/^[A-Za-z0-9_-]*$/,jb=/^(?=.{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])?)*\.?$/,Pb=/^([a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,}$/,JW=/^https?$/,qW=/^\+[1-9]\d{6,14}$/,GW=new RegExp(`^${sT}$`);XW=/^-?\d+n?$/,YW=/^-?\d+$/,o6=/^-?\d+(?:\.\d+)?$/,VW=/^(?:true|false)$/i,WW=/^null$/i,OW=/^undefined$/i,ZW=/^[^A-Z]*$/,RW=/^[^a-z]*$/,Bb=/^[0-9a-fA-F]*$/;Sb=/^[0-9a-fA-F]{32}$/,Lb=a6(22,"=="),Eb=s6(22),Cb=/^[0-9a-fA-F]{40}$/,_b=a6(27,"="),vb=s6(27),Fb=/^[0-9a-fA-F]{64}$/,bb=a6(43,"="),ub=s6(43),kb=/^[0-9a-fA-F]{96}$/,xb=a6(64,""),fb=s6(64),yb=/^[0-9a-fA-F]{128}$/,mb=a6(86,"=="),hb=s6(86)});function eT($,U,J){if($.issues.length)U.issues.push(...JU(J,$.issues))}var p$,$z,vQ,FQ,NW,wW,MW,HW,TW,zW,AW,KW,gW,$8,jW,PW,BW,SW,LW,EW,CW,_W,vW;var bQ=O$(()=>{uq();_Q();g$();p$=r("$ZodCheck",($,U)=>{var J;$._zod??($._zod={}),$._zod.def=U,(J=$._zod).onattach??(J.onattach=[])}),$z={number:"number",bigint:"bigint",object:"date"},vQ=r("$ZodCheckLessThan",($,U)=>{p$.init($,U);let J=$z[typeof U.value];$._zod.onattach.push((G)=>{let q=G._zod.bag,I=(U.inclusive?q.maximum:q.exclusiveMaximum)??Number.POSITIVE_INFINITY;if(U.value<I)if(U.inclusive)q.maximum=U.value;else q.exclusiveMaximum=U.value}),$._zod.check=(G)=>{if(U.inclusive?G.value<=U.value:G.value<U.value)return;G.issues.push({origin:J,code:"too_big",maximum:typeof U.value==="object"?U.value.getTime():U.value,input:G.value,inclusive:U.inclusive,inst:$,continue:!U.abort})}}),FQ=r("$ZodCheckGreaterThan",($,U)=>{p$.init($,U);let J=$z[typeof U.value];$._zod.onattach.push((G)=>{let q=G._zod.bag,I=(U.inclusive?q.minimum:q.exclusiveMinimum)??Number.NEGATIVE_INFINITY;if(U.value>I)if(U.inclusive)q.minimum=U.value;else q.exclusiveMinimum=U.value}),$._zod.check=(G)=>{if(U.inclusive?G.value>=U.value:G.value>U.value)return;G.issues.push({origin:J,code:"too_small",minimum:typeof U.value==="object"?U.value.getTime():U.value,input:G.value,inclusive:U.inclusive,inst:$,continue:!U.abort})}}),NW=r("$ZodCheckMultipleOf",($,U)=>{p$.init($,U),$._zod.onattach.push((J)=>{var G;(G=J._zod.bag).multipleOf??(G.multipleOf=U.value)}),$._zod.check=(J)=>{if(typeof J.value!==typeof U.value)throw Error("Cannot mix number and bigint in multiple_of check.");if(typeof J.value==="bigint"?J.value%U.value===BigInt(0):PV(J.value,U.value)===0)return;J.issues.push({origin:typeof J.value,code:"not_multiple_of",divisor:U.value,input:J.value,inst:$,continue:!U.abort})}}),wW=r("$ZodCheckNumberFormat",($,U)=>{p$.init($,U),U.format=U.format||"float64";let J=U.format?.includes("int"),G=J?"int":"number",[q,I]=_V[U.format];$._zod.onattach.push((Q)=>{let D=Q._zod.bag;if(D.format=U.format,D.minimum=q,D.maximum=I,J)D.pattern=YW}),$._zod.check=(Q)=>{let D=Q.value;if(J){if(!Number.isInteger(D)){Q.issues.push({expected:G,format:U.format,code:"invalid_type",continue:!1,input:D,inst:$});return}if(!Number.isSafeInteger(D)){if(D>0)Q.issues.push({input:D,code:"too_big",maximum:Number.MAX_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:$,origin:G,inclusive:!0,continue:!U.abort});else Q.issues.push({input:D,code:"too_small",minimum:Number.MIN_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:$,origin:G,inclusive:!0,continue:!U.abort});return}}if(D<q)Q.issues.push({origin:"number",input:D,code:"too_small",minimum:q,inclusive:!0,inst:$,continue:!U.abort});if(D>I)Q.issues.push({origin:"number",input:D,code:"too_big",maximum:I,inclusive:!0,inst:$,continue:!U.abort})}}),MW=r("$ZodCheckBigIntFormat",($,U)=>{p$.init($,U);let[J,G]=vV[U.format];$._zod.onattach.push((q)=>{let I=q._zod.bag;I.format=U.format,I.minimum=J,I.maximum=G}),$._zod.check=(q)=>{let I=q.value;if(I<J)q.issues.push({origin:"bigint",input:I,code:"too_small",minimum:J,inclusive:!0,inst:$,continue:!U.abort});if(I>G)q.issues.push({origin:"bigint",input:I,code:"too_big",maximum:G,inclusive:!0,inst:$,continue:!U.abort})}}),HW=r("$ZodCheckMaxSize",($,U)=>{var J;p$.init($,U),(J=$._zod.def).when??(J.when=(G)=>{let q=G.value;return!yJ(q)&&q.size!==void 0}),$._zod.onattach.push((G)=>{let q=G._zod.bag.maximum??Number.POSITIVE_INFINITY;if(U.maximum<q)G._zod.bag.maximum=U.maximum}),$._zod.check=(G)=>{let q=G.value;if(q.size<=U.maximum)return;G.issues.push({origin:i6(q),code:"too_big",maximum:U.maximum,inclusive:!0,input:q,inst:$,continue:!U.abort})}}),TW=r("$ZodCheckMinSize",($,U)=>{var J;p$.init($,U),(J=$._zod.def).when??(J.when=(G)=>{let q=G.value;return!yJ(q)&&q.size!==void 0}),$._zod.onattach.push((G)=>{let q=G._zod.bag.minimum??Number.NEGATIVE_INFINITY;if(U.minimum>q)G._zod.bag.minimum=U.minimum}),$._zod.check=(G)=>{let q=G.value;if(q.size>=U.minimum)return;G.issues.push({origin:i6(q),code:"too_small",minimum:U.minimum,inclusive:!0,input:q,inst:$,continue:!U.abort})}}),zW=r("$ZodCheckSizeEquals",($,U)=>{var J;p$.init($,U),(J=$._zod.def).when??(J.when=(G)=>{let q=G.value;return!yJ(q)&&q.size!==void 0}),$._zod.onattach.push((G)=>{let q=G._zod.bag;q.minimum=U.size,q.maximum=U.size,q.size=U.size}),$._zod.check=(G)=>{let q=G.value,I=q.size;if(I===U.size)return;let Q=I>U.size;G.issues.push({origin:i6(q),...Q?{code:"too_big",maximum:U.size}:{code:"too_small",minimum:U.size},inclusive:!0,exact:!0,input:G.value,inst:$,continue:!U.abort})}}),AW=r("$ZodCheckMaxLength",($,U)=>{var J;p$.init($,U),(J=$._zod.def).when??(J.when=(G)=>{let q=G.value;return!yJ(q)&&q.length!==void 0}),$._zod.onattach.push((G)=>{let q=G._zod.bag.maximum??Number.POSITIVE_INFINITY;if(U.maximum<q)G._zod.bag.maximum=U.maximum}),$._zod.check=(G)=>{let q=G.value;if(q.length<=U.maximum)return;let Q=p6(q);G.issues.push({origin:Q,code:"too_big",maximum:U.maximum,inclusive:!0,input:q,inst:$,continue:!U.abort})}}),KW=r("$ZodCheckMinLength",($,U)=>{var J;p$.init($,U),(J=$._zod.def).when??(J.when=(G)=>{let q=G.value;return!yJ(q)&&q.length!==void 0}),$._zod.onattach.push((G)=>{let q=G._zod.bag.minimum??Number.NEGATIVE_INFINITY;if(U.minimum>q)G._zod.bag.minimum=U.minimum}),$._zod.check=(G)=>{let q=G.value;if(q.length>=U.minimum)return;let Q=p6(q);G.issues.push({origin:Q,code:"too_small",minimum:U.minimum,inclusive:!0,input:q,inst:$,continue:!U.abort})}}),gW=r("$ZodCheckLengthEquals",($,U)=>{var J;p$.init($,U),(J=$._zod.def).when??(J.when=(G)=>{let q=G.value;return!yJ(q)&&q.length!==void 0}),$._zod.onattach.push((G)=>{let q=G._zod.bag;q.minimum=U.length,q.maximum=U.length,q.length=U.length}),$._zod.check=(G)=>{let q=G.value,I=q.length;if(I===U.length)return;let Q=p6(q),D=I>U.length;G.issues.push({origin:Q,...D?{code:"too_big",maximum:U.length}:{code:"too_small",minimum:U.length},inclusive:!0,exact:!0,input:G.value,inst:$,continue:!U.abort})}}),$8=r("$ZodCheckStringFormat",($,U)=>{var J,G;if(p$.init($,U),$._zod.onattach.push((q)=>{let I=q._zod.bag;if(I.format=U.format,U.pattern)I.patterns??(I.patterns=new Set),I.patterns.add(U.pattern)}),U.pattern)(J=$._zod).check??(J.check=(q)=>{if(U.pattern.lastIndex=0,U.pattern.test(q.value))return;q.issues.push({origin:"string",code:"invalid_format",format:U.format,input:q.value,...U.pattern?{pattern:U.pattern.toString()}:{},inst:$,continue:!U.abort})});else(G=$._zod).check??(G.check=()=>{})}),jW=r("$ZodCheckRegex",($,U)=>{$8.init($,U),$._zod.check=(J)=>{if(U.pattern.lastIndex=0,U.pattern.test(J.value))return;J.issues.push({origin:"string",code:"invalid_format",format:"regex",input:J.value,pattern:U.pattern.toString(),inst:$,continue:!U.abort})}}),PW=r("$ZodCheckLowerCase",($,U)=>{U.pattern??(U.pattern=ZW),$8.init($,U)}),BW=r("$ZodCheckUpperCase",($,U)=>{U.pattern??(U.pattern=RW),$8.init($,U)}),SW=r("$ZodCheckIncludes",($,U)=>{p$.init($,U);let J=gU(U.includes),G=new RegExp(typeof U.position==="number"?`^.{${U.position}}${J}`:J);U.pattern=G,$._zod.onattach.push((q)=>{let I=q._zod.bag;I.patterns??(I.patterns=new Set),I.patterns.add(G)}),$._zod.check=(q)=>{if(q.value.includes(U.includes,U.position))return;q.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:U.includes,input:q.value,inst:$,continue:!U.abort})}}),LW=r("$ZodCheckStartsWith",($,U)=>{p$.init($,U);let J=new RegExp(`^${gU(U.prefix)}.*`);U.pattern??(U.pattern=J),$._zod.onattach.push((G)=>{let q=G._zod.bag;q.patterns??(q.patterns=new Set),q.patterns.add(J)}),$._zod.check=(G)=>{if(G.value.startsWith(U.prefix))return;G.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:U.prefix,input:G.value,inst:$,continue:!U.abort})}}),EW=r("$ZodCheckEndsWith",($,U)=>{p$.init($,U);let J=new RegExp(`.*${gU(U.suffix)}$`);U.pattern??(U.pattern=J),$._zod.onattach.push((G)=>{let q=G._zod.bag;q.patterns??(q.patterns=new Set),q.patterns.add(J)}),$._zod.check=(G)=>{if(G.value.endsWith(U.suffix))return;G.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:U.suffix,input:G.value,inst:$,continue:!U.abort})}});CW=r("$ZodCheckProperty",($,U)=>{p$.init($,U),$._zod.check=(J)=>{let G=U.schema._zod.run({value:J.value[U.property],issues:[]},{});if(G instanceof Promise)return G.then((q)=>eT(q,J,U.property));eT(G,J,U.property);return}}),_W=r("$ZodCheckMimeType",($,U)=>{p$.init($,U);let J=new Set(U.mime);$._zod.onattach.push((G)=>{G._zod.bag.mime=U.mime}),$._zod.check=(G)=>{if(J.has(G.value.type))return;G.issues.push({code:"invalid_value",values:U.mime,input:G.value.type,inst:$,continue:!U.abort})}}),vW=r("$ZodCheckOverwrite",($,U)=>{p$.init($,U),$._zod.check=(J)=>{J.value=U.tx(J.value)}})});class uQ{constructor($=[]){if(this.content=[],this.indent=0,this)this.args=$}indented($){this.indent+=1,$(this),this.indent-=1}write($){if(typeof $==="function"){$(this,{execution:"sync"}),$(this,{execution:"async"});return}let J=$.split(`
|
|
35
|
+
`).filter((I)=>I),G=Math.min(...J.map((I)=>I.length-I.trimStart().length)),q=J.map((I)=>I.slice(G)).map((I)=>" ".repeat(this.indent*2)+I);for(let I of q)this.content.push(I)}compile(){let $=Function,U=this?.args,G=[...(this?.content??[""]).map((q)=>` ${q}`)];return new $(...U,G.join(`
|
|
36
|
+
`))}}var FW;var bW=O$(()=>{FW={major:4,minor:4,patch:3}});function JO($){if($==="")return!0;if(/\s/.test($))return!1;if($.length%4!==0)return!1;try{return atob($),!0}catch{return!1}}function wz($){if(!CQ.test($))return!1;let U=$.replace(/[-_]/g,(G)=>G==="-"?"+":"/"),J=U.padEnd(Math.ceil(U.length/4)*4,"=");return JO(J)}function Mz($,U=null){try{let J=$.split(".");if(J.length!==3)return!1;let[G]=J;if(!G)return!1;let q=JSON.parse(atob(G));if("typ"in q&&q?.typ!=="JWT")return!1;if(!q.alg)return!1;if(U&&(!("alg"in q)||q.alg!==U))return!1;return!0}catch{return!1}}function Jz($,U,J){if($.issues.length)U.issues.push(...JU(J,$.issues));U.value[J]=$.value}function yQ($,U,J,G,q,I){let Q=J in G;if($.issues.length){if(q&&I&&!Q)return;U.issues.push(...JU(J,$.issues))}if(!Q&&!q){if(!$.issues.length)U.issues.push({code:"invalid_type",expected:"nonoptional",input:void 0,path:[J]});return}if($.value===void 0){if(Q)U.value[J]=void 0}else U.value[J]=$.value}function Hz($){let U=Object.keys($.shape);for(let G of U)if(!$.shape?.[G]?._zod?.traits?.has("$ZodType"))throw Error(`Invalid element at key "${G}": expected a Zod schema`);let J=CV($.shape);return{...$,keys:U,keySet:new Set(U),numKeys:U.length,optionalKeys:new Set(J)}}function Tz($,U,J,G,q,I){let Q=[],D=q.keySet,X=q.catchall._zod,Y=X.def.type,V=X.optin==="optional",W=X.optout==="optional";for(let O in U){if(O==="__proto__")continue;if(D.has(O))continue;if(Y==="never"){Q.push(O);continue}let Z=X.run({value:U[O],issues:[]},G);if(Z instanceof Promise)$.push(Z.then((M)=>yQ(M,J,O,U,V,W)));else yQ(Z,J,O,U,V,W)}if(Q.length)J.issues.push({code:"unrecognized_keys",keys:Q,input:U,inst:I});if(!$.length)return J;return Promise.all($).then(()=>{return J})}function qz($,U,J,G){for(let I of $)if(I.issues.length===0)return U.value=I.value,U;let q=$.filter((I)=>!rJ(I));if(q.length===1)return U.value=q[0].value,q[0];return U.issues.push({code:"invalid_union",input:U.value,inst:J,errors:$.map((I)=>I.issues.map((Q)=>l0(Q,G,a$())))}),U}function Gz($,U,J,G){let q=$.filter((I)=>I.issues.length===0);if(q.length===1)return U.value=q[0].value,U;if(q.length===0)U.issues.push({code:"invalid_union",input:U.value,inst:J,errors:$.map((I)=>I.issues.map((Q)=>l0(Q,G,a$())))});else U.issues.push({code:"invalid_union",input:U.value,inst:J,errors:[],inclusive:!1});return U}function uW($,U){if($===U)return{valid:!0,data:$};if($ instanceof Date&&U instanceof Date&&+$===+U)return{valid:!0,data:$};if(hJ($)&&hJ(U)){let J=Object.keys(U),G=Object.keys($).filter((I)=>J.indexOf(I)!==-1),q={...$,...U};for(let I of G){let Q=uW($[I],U[I]);if(!Q.valid)return{valid:!1,mergeErrorPath:[I,...Q.mergeErrorPath]};q[I]=Q.data}return{valid:!0,data:q}}if(Array.isArray($)&&Array.isArray(U)){if($.length!==U.length)return{valid:!1,mergeErrorPath:[]};let J=[];for(let G=0;G<$.length;G++){let q=$[G],I=U[G],Q=uW(q,I);if(!Q.valid)return{valid:!1,mergeErrorPath:[G,...Q.mergeErrorPath]};J.push(Q.data)}return{valid:!0,data:J}}return{valid:!1,mergeErrorPath:[]}}function Iz($,U,J){let G=new Map,q;for(let D of U.issues)if(D.code==="unrecognized_keys"){q??(q=D);for(let X of D.keys){if(!G.has(X))G.set(X,{});G.get(X).l=!0}}else $.issues.push(D);for(let D of J.issues)if(D.code==="unrecognized_keys")for(let X of D.keys){if(!G.has(X))G.set(X,{});G.get(X).r=!0}else $.issues.push(D);let I=[...G].filter(([,D])=>D.l&&D.r).map(([D])=>D);if(I.length&&q)$.issues.push({...q,keys:I});if(rJ($))return $;let Q=uW(U.value,J.value);if(!Q.valid)throw Error(`Unmergable intersection. Error path: ${JSON.stringify(Q.mergeErrorPath)}`);return $.value=Q.data,$}function Qz($,U){for(let J=$.length-1;J>=0;J--)if($[J]._zod[U]!=="optional")return J+1;return 0}function Dz($,U,J){if($.issues.length)U.issues.push(...JU(J,$.issues));U.value[J]=$.value}function Xz($,U,J,G,q){for(let I=0;I<J.length;I++){let Q=$[I],D=I<G.length;if(Q.issues.length){if(!D&&I>=q){U.value.length=I;break}U.issues.push(...JU(I,Q.issues))}U.value[I]=Q.value}for(let I=U.value.length-1;I>=G.length;I--)if(J[I]._zod.optout==="optional"&&U.value[I]===void 0)U.value.length=I;else break;return U}function Yz($,U,J,G,q,I,Q){if($.issues.length)if(l6.has(typeof G))J.issues.push(...JU(G,$.issues));else J.issues.push({code:"invalid_key",origin:"map",input:q,inst:I,issues:$.issues.map((D)=>l0(D,Q,a$()))});if(U.issues.length)if(l6.has(typeof G))J.issues.push(...JU(G,U.issues));else J.issues.push({origin:"map",code:"invalid_element",input:q,inst:I,key:G,issues:U.issues.map((D)=>l0(D,Q,a$()))});J.value.set($.value,U.value)}function Vz($,U){if($.issues.length)U.issues.push(...$.issues);U.value.add($.value)}function Wz($,U){if(U===void 0&&($.issues.length||$.fallback))return{issues:[],value:void 0};return $}function Oz($,U){if($.value===void 0)$.value=U.defaultValue;return $}function Zz($,U){if(!$.issues.length&&$.value===void 0)$.issues.push({code:"invalid_type",expected:"nonoptional",input:$.value,inst:U});return $}function kQ($,U,J){if($.issues.length)return $.aborted=!0,$;return U._zod.run({value:$.value,issues:$.issues,fallback:$.fallback},J)}function xQ($,U,J){if($.issues.length)return $.aborted=!0,$;if((J.direction||"forward")==="forward"){let q=U.transform($.value,$);if(q instanceof Promise)return q.then((I)=>fQ($,I,U.out,J));return fQ($,q,U.out,J)}else{let q=U.reverseTransform($.value,$);if(q instanceof Promise)return q.then((I)=>fQ($,I,U.in,J));return fQ($,q,U.in,J)}}function fQ($,U,J,G){if($.issues.length)return $.aborted=!0,$;return J._zod.run({value:U,issues:$.issues},G)}function Rz($){return $.value=Object.freeze($.value),$}function Nz($,U,J,G){if(!$){let q={code:"custom",input:J,inst:G,path:[...G._zod.def.path??[]],continue:!G._zod.def.abort};if(G._zod.def.params)q.params=G._zod.def.params;U.issues.push(oG(q))}}var E$,fq,r$,kW,xW,fW,yW,mW,hW,rW,lW,iW,pW,dW,nW,cW,oW,aW,sW,tW,eW,$O,UO,qO,GO,IO,QO,DO,mQ,XO,t6,hQ,YO,VO,WO,OO,ZO,RO,NO,wO,MO,HO,zz,TO,e6,zO,AO,KO,rQ,gO,jO,PO,BO,SO,LO,EO,lQ,CO,_O,vO,FO,bO,uO,kO,xO,iQ,$4,fO,yO,mO,hO,rO,lO,iO;var pO=O$(()=>{bQ();uq();yV();_Q();g$();bW();g$();E$=r("$ZodType",($,U)=>{var J;$??($={}),$._zod.def=U,$._zod.bag=$._zod.bag||{},$._zod.version=FW;let G=[...$._zod.def.checks??[]];if($._zod.traits.has("$ZodCheck"))G.unshift($);for(let q of G)for(let I of q._zod.onattach)I($);if(G.length===0)(J=$._zod).deferred??(J.deferred=[]),$._zod.deferred?.push(()=>{$._zod.run=$._zod.parse});else{let q=(Q,D,X)=>{let Y=rJ(Q),V;for(let W of D){if(W._zod.def.when){if(FV(Q))continue;if(!W._zod.def.when(Q))continue}else if(Y)continue;let O=Q.issues.length,Z=W._zod.check(Q);if(Z instanceof Promise&&X?.async===!1)throw new pU;if(V||Z instanceof Promise)V=(V??Promise.resolve()).then(async()=>{if(await Z,Q.issues.length===O)return;if(!Y)Y=rJ(Q,O)});else{if(Q.issues.length===O)continue;if(!Y)Y=rJ(Q,O)}}if(V)return V.then(()=>{return Q});return Q},I=(Q,D,X)=>{if(rJ(Q))return Q.aborted=!0,Q;let Y=q(D,G,X);if(Y instanceof Promise){if(X.async===!1)throw new pU;return Y.then((V)=>$._zod.parse(V,X))}return $._zod.parse(Y,X)};$._zod.run=(Q,D)=>{if(D.skipChecks)return $._zod.parse(Q,D);if(D.direction==="backward"){let Y=$._zod.parse({value:Q.value,issues:[]},{...D,skipChecks:!0});if(Y instanceof Promise)return Y.then((V)=>{return I(V,Q,D)});return I(Y,Q,D)}let X=$._zod.parse(Q,D);if(X instanceof Promise){if(D.async===!1)throw new pU;return X.then((Y)=>q(Y,G,D))}return q(X,G,D)}}F$($,"~standard",()=>({validate:(q)=>{try{let I=xV($,q);return I.success?{value:I.data}:{issues:I.error?.issues}}catch(I){return fV($,q).then((Q)=>Q.success?{value:Q.data}:{issues:Q.error?.issues})}},vendor:"zod",version:1}))}),fq=r("$ZodString",($,U)=>{E$.init($,U),$._zod.pattern=[...$?._zod.bag?.patterns??[]].pop()??DW($._zod.bag),$._zod.parse=(J,G)=>{if(U.coerce)try{J.value=String(J.value)}catch(q){}if(typeof J.value==="string")return J;return J.issues.push({expected:"string",code:"invalid_type",input:J.value,inst:$}),J}}),r$=r("$ZodStringFormat",($,U)=>{$8.init($,U),fq.init($,U)}),kW=r("$ZodGUID",($,U)=>{U.pattern??(U.pattern=nV),r$.init($,U)}),xW=r("$ZodUUID",($,U)=>{if(U.version){let G={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[U.version];if(G===void 0)throw Error(`Invalid UUID version: "${U.version}"`);U.pattern??(U.pattern=xq(G))}else U.pattern??(U.pattern=xq());r$.init($,U)}),fW=r("$ZodEmail",($,U)=>{U.pattern??(U.pattern=cV),r$.init($,U)}),yW=r("$ZodURL",($,U)=>{r$.init($,U),$._zod.check=(J)=>{try{let G=J.value.trim();if(!U.normalize&&U.protocol?.source===JW.source){if(!/^https?:\/\//i.test(G)){J.issues.push({code:"invalid_format",format:"url",note:"Invalid URL format",input:J.value,inst:$,continue:!U.abort});return}}let q=new URL(G);if(U.hostname){if(U.hostname.lastIndex=0,!U.hostname.test(q.hostname))J.issues.push({code:"invalid_format",format:"url",note:"Invalid hostname",pattern:U.hostname.source,input:J.value,inst:$,continue:!U.abort})}if(U.protocol){if(U.protocol.lastIndex=0,!U.protocol.test(q.protocol.endsWith(":")?q.protocol.slice(0,-1):q.protocol))J.issues.push({code:"invalid_format",format:"url",note:"Invalid protocol",pattern:U.protocol.source,input:J.value,inst:$,continue:!U.abort})}if(U.normalize)J.value=q.href;else J.value=G;return}catch(G){J.issues.push({code:"invalid_format",format:"url",input:J.value,inst:$,continue:!U.abort})}}}),mW=r("$ZodEmoji",($,U)=>{U.pattern??(U.pattern=oV()),r$.init($,U)}),hW=r("$ZodNanoID",($,U)=>{U.pattern??(U.pattern=pV),r$.init($,U)}),rW=r("$ZodCUID",($,U)=>{U.pattern??(U.pattern=mV),r$.init($,U)}),lW=r("$ZodCUID2",($,U)=>{U.pattern??(U.pattern=hV),r$.init($,U)}),iW=r("$ZodULID",($,U)=>{U.pattern??(U.pattern=rV),r$.init($,U)}),pW=r("$ZodXID",($,U)=>{U.pattern??(U.pattern=lV),r$.init($,U)}),dW=r("$ZodKSUID",($,U)=>{U.pattern??(U.pattern=iV),r$.init($,U)}),nW=r("$ZodISODateTime",($,U)=>{U.pattern??(U.pattern=QW(U)),r$.init($,U)}),cW=r("$ZodISODate",($,U)=>{U.pattern??(U.pattern=GW),r$.init($,U)}),oW=r("$ZodISOTime",($,U)=>{U.pattern??(U.pattern=IW(U)),r$.init($,U)}),aW=r("$ZodISODuration",($,U)=>{U.pattern??(U.pattern=dV),r$.init($,U)}),sW=r("$ZodIPv4",($,U)=>{U.pattern??(U.pattern=aV),r$.init($,U),$._zod.bag.format="ipv4"}),tW=r("$ZodIPv6",($,U)=>{U.pattern??(U.pattern=sV),r$.init($,U),$._zod.bag.format="ipv6",$._zod.check=(J)=>{try{new URL(`http://[${J.value}]`)}catch{J.issues.push({code:"invalid_format",format:"ipv6",input:J.value,inst:$,continue:!U.abort})}}}),eW=r("$ZodMAC",($,U)=>{U.pattern??(U.pattern=tV(U.delimiter)),r$.init($,U),$._zod.bag.format="mac"}),$O=r("$ZodCIDRv4",($,U)=>{U.pattern??(U.pattern=eV),r$.init($,U)}),UO=r("$ZodCIDRv6",($,U)=>{U.pattern??(U.pattern=$W),r$.init($,U),$._zod.check=(J)=>{let G=J.value.split("/");try{if(G.length!==2)throw Error();let[q,I]=G;if(!I)throw Error();let Q=Number(I);if(`${Q}`!==I)throw Error();if(Q<0||Q>128)throw Error();new URL(`http://[${q}]`)}catch{J.issues.push({code:"invalid_format",format:"cidrv6",input:J.value,inst:$,continue:!U.abort})}}});qO=r("$ZodBase64",($,U)=>{U.pattern??(U.pattern=UW),r$.init($,U),$._zod.bag.contentEncoding="base64",$._zod.check=(J)=>{if(JO(J.value))return;J.issues.push({code:"invalid_format",format:"base64",input:J.value,inst:$,continue:!U.abort})}});GO=r("$ZodBase64URL",($,U)=>{U.pattern??(U.pattern=CQ),r$.init($,U),$._zod.bag.contentEncoding="base64url",$._zod.check=(J)=>{if(wz(J.value))return;J.issues.push({code:"invalid_format",format:"base64url",input:J.value,inst:$,continue:!U.abort})}}),IO=r("$ZodE164",($,U)=>{U.pattern??(U.pattern=qW),r$.init($,U)});QO=r("$ZodJWT",($,U)=>{r$.init($,U),$._zod.check=(J)=>{if(Mz(J.value,U.alg))return;J.issues.push({code:"invalid_format",format:"jwt",input:J.value,inst:$,continue:!U.abort})}}),DO=r("$ZodCustomStringFormat",($,U)=>{r$.init($,U),$._zod.check=(J)=>{if(U.fn(J.value))return;J.issues.push({code:"invalid_format",format:U.format,input:J.value,inst:$,continue:!U.abort})}}),mQ=r("$ZodNumber",($,U)=>{E$.init($,U),$._zod.pattern=$._zod.bag.pattern??o6,$._zod.parse=(J,G)=>{if(U.coerce)try{J.value=Number(J.value)}catch(Q){}let q=J.value;if(typeof q==="number"&&!Number.isNaN(q)&&Number.isFinite(q))return J;let I=typeof q==="number"?Number.isNaN(q)?"NaN":!Number.isFinite(q)?"Infinity":void 0:void 0;return J.issues.push({expected:"number",code:"invalid_type",input:q,inst:$,...I?{received:I}:{}}),J}}),XO=r("$ZodNumberFormat",($,U)=>{wW.init($,U),mQ.init($,U)}),t6=r("$ZodBoolean",($,U)=>{E$.init($,U),$._zod.pattern=VW,$._zod.parse=(J,G)=>{if(U.coerce)try{J.value=Boolean(J.value)}catch(I){}let q=J.value;if(typeof q==="boolean")return J;return J.issues.push({expected:"boolean",code:"invalid_type",input:q,inst:$}),J}}),hQ=r("$ZodBigInt",($,U)=>{E$.init($,U),$._zod.pattern=XW,$._zod.parse=(J,G)=>{if(U.coerce)try{J.value=BigInt(J.value)}catch(q){}if(typeof J.value==="bigint")return J;return J.issues.push({expected:"bigint",code:"invalid_type",input:J.value,inst:$}),J}}),YO=r("$ZodBigIntFormat",($,U)=>{MW.init($,U),hQ.init($,U)}),VO=r("$ZodSymbol",($,U)=>{E$.init($,U),$._zod.parse=(J,G)=>{let q=J.value;if(typeof q==="symbol")return J;return J.issues.push({expected:"symbol",code:"invalid_type",input:q,inst:$}),J}}),WO=r("$ZodUndefined",($,U)=>{E$.init($,U),$._zod.pattern=OW,$._zod.values=new Set([void 0]),$._zod.parse=(J,G)=>{let q=J.value;if(typeof q>"u")return J;return J.issues.push({expected:"undefined",code:"invalid_type",input:q,inst:$}),J}}),OO=r("$ZodNull",($,U)=>{E$.init($,U),$._zod.pattern=WW,$._zod.values=new Set([null]),$._zod.parse=(J,G)=>{let q=J.value;if(q===null)return J;return J.issues.push({expected:"null",code:"invalid_type",input:q,inst:$}),J}}),ZO=r("$ZodAny",($,U)=>{E$.init($,U),$._zod.parse=(J)=>J}),RO=r("$ZodUnknown",($,U)=>{E$.init($,U),$._zod.parse=(J)=>J}),NO=r("$ZodNever",($,U)=>{E$.init($,U),$._zod.parse=(J,G)=>{return J.issues.push({expected:"never",code:"invalid_type",input:J.value,inst:$}),J}}),wO=r("$ZodVoid",($,U)=>{E$.init($,U),$._zod.parse=(J,G)=>{let q=J.value;if(typeof q>"u")return J;return J.issues.push({expected:"void",code:"invalid_type",input:q,inst:$}),J}}),MO=r("$ZodDate",($,U)=>{E$.init($,U),$._zod.parse=(J,G)=>{if(U.coerce)try{J.value=new Date(J.value)}catch(D){}let q=J.value,I=q instanceof Date;if(I&&!Number.isNaN(q.getTime()))return J;return J.issues.push({expected:"date",code:"invalid_type",input:q,...I?{received:"Invalid Date"}:{},inst:$}),J}});HO=r("$ZodArray",($,U)=>{E$.init($,U),$._zod.parse=(J,G)=>{let q=J.value;if(!Array.isArray(q))return J.issues.push({expected:"array",code:"invalid_type",input:q,inst:$}),J;J.value=Array(q.length);let I=[];for(let Q=0;Q<q.length;Q++){let D=q[Q],X=U.element._zod.run({value:D,issues:[]},G);if(X instanceof Promise)I.push(X.then((Y)=>Jz(Y,J,Q)));else Jz(X,J,Q)}if(I.length)return Promise.all(I).then(()=>J);return J}});zz=r("$ZodObject",($,U)=>{if(E$.init($,U),!Object.getOwnPropertyDescriptor(U,"shape")?.get){let D=U.shape;Object.defineProperty(U,"shape",{get:()=>{let X={...D};return Object.defineProperty(U,"shape",{value:X}),X}})}let G=cG(()=>Hz(U));F$($._zod,"propValues",()=>{let D=U.shape,X={};for(let Y in D){let V=D[Y]._zod;if(V.values){X[Y]??(X[Y]=new Set);for(let W of V.values)X[Y].add(W)}}return X});let q=kq,I=U.catchall,Q;$._zod.parse=(D,X)=>{Q??(Q=G.value);let Y=D.value;if(!q(Y))return D.issues.push({expected:"object",code:"invalid_type",input:Y,inst:$}),D;D.value={};let V=[],W=Q.shape;for(let O of Q.keys){let Z=W[O],M=Z._zod.optin==="optional",w=Z._zod.optout==="optional",H=Z._zod.run({value:Y[O],issues:[]},X);if(H instanceof Promise)V.push(H.then((g)=>yQ(g,D,O,Y,M,w)));else yQ(H,D,O,Y,M,w)}if(!I)return V.length?Promise.all(V).then(()=>D):D;return Tz(V,Y,D,X,G.value,$)}}),TO=r("$ZodObjectJIT",($,U)=>{zz.init($,U);let J=$._zod.parse,G=cG(()=>Hz(U)),q=(O)=>{let Z=new uQ(["shape","payload","ctx"]),M=G.value,w=(C)=>{let F=HQ(C);return`shape[${F}]._zod.run({ value: input[${F}], issues: [] }, ctx)`};Z.write("const input = payload.value;");let H=Object.create(null),g=0;for(let C of M.keys)H[C]=`key_${g++}`;Z.write("const newResult = {};");for(let C of M.keys){let F=H[C],f=HQ(C),E=O[C],p=E?._zod?.optin==="optional",b=E?._zod?.optout==="optional";if(Z.write(`const ${F} = ${w(C)};`),p&&b)Z.write(`
|
|
37
|
+
if (${F}.issues.length) {
|
|
38
|
+
if (${f} in input) {
|
|
39
|
+
payload.issues = payload.issues.concat(${F}.issues.map(iss => ({
|
|
40
|
+
...iss,
|
|
41
|
+
path: iss.path ? [${f}, ...iss.path] : [${f}]
|
|
42
|
+
})));
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
if (${F}.value === undefined) {
|
|
47
|
+
if (${f} in input) {
|
|
48
|
+
newResult[${f}] = undefined;
|
|
49
|
+
}
|
|
50
|
+
} else {
|
|
51
|
+
newResult[${f}] = ${F}.value;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
`);else if(!p)Z.write(`
|
|
55
|
+
const ${F}_present = ${f} in input;
|
|
56
|
+
if (${F}.issues.length) {
|
|
57
|
+
payload.issues = payload.issues.concat(${F}.issues.map(iss => ({
|
|
58
|
+
...iss,
|
|
59
|
+
path: iss.path ? [${f}, ...iss.path] : [${f}]
|
|
60
|
+
})));
|
|
61
|
+
}
|
|
62
|
+
if (!${F}_present && !${F}.issues.length) {
|
|
63
|
+
payload.issues.push({
|
|
64
|
+
code: "invalid_type",
|
|
65
|
+
expected: "nonoptional",
|
|
66
|
+
input: undefined,
|
|
67
|
+
path: [${f}]
|
|
68
|
+
});
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
if (${F}_present) {
|
|
72
|
+
if (${F}.value === undefined) {
|
|
73
|
+
newResult[${f}] = undefined;
|
|
74
|
+
} else {
|
|
75
|
+
newResult[${f}] = ${F}.value;
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
`);else Z.write(`
|
|
80
|
+
if (${F}.issues.length) {
|
|
81
|
+
payload.issues = payload.issues.concat(${F}.issues.map(iss => ({
|
|
82
|
+
...iss,
|
|
83
|
+
path: iss.path ? [${f}, ...iss.path] : [${f}]
|
|
84
|
+
})));
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
if (${F}.value === undefined) {
|
|
88
|
+
if (${f} in input) {
|
|
89
|
+
newResult[${f}] = undefined;
|
|
90
|
+
}
|
|
91
|
+
} else {
|
|
92
|
+
newResult[${f}] = ${F}.value;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
`)}Z.write("payload.value = newResult;"),Z.write("return payload;");let P=Z.compile();return(C,F)=>P(O,C,F)},I,Q=kq,D=!Fq.jitless,Y=D&&SV.value,V=U.catchall,W;$._zod.parse=(O,Z)=>{W??(W=G.value);let M=O.value;if(!Q(M))return O.issues.push({expected:"object",code:"invalid_type",input:M,inst:$}),O;if(D&&Y&&Z?.async===!1&&Z.jitless!==!0){if(!I)I=q(U.shape);if(O=I(O,Z),!V)return O;return Tz([],M,O,Z,W,$)}return J(O,Z)}});e6=r("$ZodUnion",($,U)=>{E$.init($,U),F$($._zod,"optin",()=>U.options.some((G)=>G._zod.optin==="optional")?"optional":void 0),F$($._zod,"optout",()=>U.options.some((G)=>G._zod.optout==="optional")?"optional":void 0),F$($._zod,"values",()=>{if(U.options.every((G)=>G._zod.values))return new Set(U.options.flatMap((G)=>Array.from(G._zod.values)));return}),F$($._zod,"pattern",()=>{if(U.options.every((G)=>G._zod.pattern)){let G=U.options.map((q)=>q._zod.pattern);return new RegExp(`^(${G.map((q)=>r6(q.source)).join("|")})$`)}return});let J=U.options.length===1?U.options[0]._zod.run:null;$._zod.parse=(G,q)=>{if(J)return J(G,q);let I=!1,Q=[];for(let D of U.options){let X=D._zod.run({value:G.value,issues:[]},q);if(X instanceof Promise)Q.push(X),I=!0;else{if(X.issues.length===0)return X;Q.push(X)}}if(!I)return qz(Q,G,$,q);return Promise.all(Q).then((D)=>{return qz(D,G,$,q)})}});zO=r("$ZodXor",($,U)=>{e6.init($,U),U.inclusive=!1;let J=U.options.length===1?U.options[0]._zod.run:null;$._zod.parse=(G,q)=>{if(J)return J(G,q);let I=!1,Q=[];for(let D of U.options){let X=D._zod.run({value:G.value,issues:[]},q);if(X instanceof Promise)Q.push(X),I=!0;else Q.push(X)}if(!I)return Gz(Q,G,$,q);return Promise.all(Q).then((D)=>{return Gz(D,G,$,q)})}}),AO=r("$ZodDiscriminatedUnion",($,U)=>{U.inclusive=!1,e6.init($,U);let J=$._zod.parse;F$($._zod,"propValues",()=>{let q={};for(let I of U.options){let Q=I._zod.propValues;if(!Q||Object.keys(Q).length===0)throw Error(`Invalid discriminated union option at index "${U.options.indexOf(I)}"`);for(let[D,X]of Object.entries(Q)){if(!q[D])q[D]=new Set;for(let Y of X)q[D].add(Y)}}return q});let G=cG(()=>{let q=U.options,I=new Map;for(let Q of q){let D=Q._zod.propValues?.[U.discriminator];if(!D||D.size===0)throw Error(`Invalid discriminated union option at index "${U.options.indexOf(Q)}"`);for(let X of D){if(I.has(X))throw Error(`Duplicate discriminator value "${String(X)}"`);I.set(X,Q)}}return I});$._zod.parse=(q,I)=>{let Q=q.value;if(!kq(Q))return q.issues.push({code:"invalid_type",expected:"object",input:Q,inst:$}),q;let D=G.value.get(Q?.[U.discriminator]);if(D)return D._zod.run(q,I);if(U.unionFallback||I.direction==="backward")return J(q,I);return q.issues.push({code:"invalid_union",errors:[],note:"No matching discriminator",discriminator:U.discriminator,options:Array.from(G.value.keys()),input:Q,path:[U.discriminator],inst:$}),q}}),KO=r("$ZodIntersection",($,U)=>{E$.init($,U),$._zod.parse=(J,G)=>{let q=J.value,I=U.left._zod.run({value:q,issues:[]},G),Q=U.right._zod.run({value:q,issues:[]},G);if(I instanceof Promise||Q instanceof Promise)return Promise.all([I,Q]).then(([X,Y])=>{return Iz(J,X,Y)});return Iz(J,I,Q)}});rQ=r("$ZodTuple",($,U)=>{E$.init($,U);let J=U.items;$._zod.parse=(G,q)=>{let I=G.value;if(!Array.isArray(I))return G.issues.push({input:I,inst:$,expected:"tuple",code:"invalid_type"}),G;G.value=[];let Q=[],D=Qz(J,"optin"),X=Qz(J,"optout");if(!U.rest){if(I.length<D)return G.issues.push({code:"too_small",minimum:D,inclusive:!0,input:I,inst:$,origin:"array"}),G;if(I.length>J.length)G.issues.push({code:"too_big",maximum:J.length,inclusive:!0,input:I,inst:$,origin:"array"})}let Y=Array(J.length);for(let V=0;V<J.length;V++){let W=J[V]._zod.run({value:I[V],issues:[]},q);if(W instanceof Promise)Q.push(W.then((O)=>{Y[V]=O}));else Y[V]=W}if(U.rest){let V=J.length-1,W=I.slice(J.length);for(let O of W){V++;let Z=U.rest._zod.run({value:O,issues:[]},q);if(Z instanceof Promise)Q.push(Z.then((M)=>Dz(M,G,V)));else Dz(Z,G,V)}}if(Q.length)return Promise.all(Q).then(()=>Xz(Y,G,J,I,X));return Xz(Y,G,J,I,X)}});gO=r("$ZodRecord",($,U)=>{E$.init($,U),$._zod.parse=(J,G)=>{let q=J.value;if(!hJ(q))return J.issues.push({expected:"record",code:"invalid_type",input:q,inst:$}),J;let I=[],Q=U.keyType._zod.values;if(Q){J.value={};let D=new Set;for(let Y of Q)if(typeof Y==="string"||typeof Y==="number"||typeof Y==="symbol"){D.add(typeof Y==="number"?Y.toString():Y);let V=U.keyType._zod.run({value:Y,issues:[]},G);if(V instanceof Promise)throw Error("Async schemas not supported in object keys currently");if(V.issues.length){J.issues.push({code:"invalid_key",origin:"record",issues:V.issues.map((Z)=>l0(Z,G,a$())),input:Y,path:[Y],inst:$});continue}let W=V.value,O=U.valueType._zod.run({value:q[Y],issues:[]},G);if(O instanceof Promise)I.push(O.then((Z)=>{if(Z.issues.length)J.issues.push(...JU(Y,Z.issues));J.value[W]=Z.value}));else{if(O.issues.length)J.issues.push(...JU(Y,O.issues));J.value[W]=O.value}}let X;for(let Y in q)if(!D.has(Y))X=X??[],X.push(Y);if(X&&X.length>0)J.issues.push({code:"unrecognized_keys",input:q,inst:$,keys:X})}else{J.value={};for(let D of Reflect.ownKeys(q)){if(D==="__proto__")continue;if(!Object.prototype.propertyIsEnumerable.call(q,D))continue;let X=U.keyType._zod.run({value:D,issues:[]},G);if(X instanceof Promise)throw Error("Async schemas not supported in object keys currently");if(typeof D==="string"&&o6.test(D)&&X.issues.length){let W=U.keyType._zod.run({value:Number(D),issues:[]},G);if(W instanceof Promise)throw Error("Async schemas not supported in object keys currently");if(W.issues.length===0)X=W}if(X.issues.length){if(U.mode==="loose")J.value[D]=q[D];else J.issues.push({code:"invalid_key",origin:"record",issues:X.issues.map((W)=>l0(W,G,a$())),input:D,path:[D],inst:$});continue}let V=U.valueType._zod.run({value:q[D],issues:[]},G);if(V instanceof Promise)I.push(V.then((W)=>{if(W.issues.length)J.issues.push(...JU(D,W.issues));J.value[X.value]=W.value}));else{if(V.issues.length)J.issues.push(...JU(D,V.issues));J.value[X.value]=V.value}}}if(I.length)return Promise.all(I).then(()=>J);return J}}),jO=r("$ZodMap",($,U)=>{E$.init($,U),$._zod.parse=(J,G)=>{let q=J.value;if(!(q instanceof Map))return J.issues.push({expected:"map",code:"invalid_type",input:q,inst:$}),J;let I=[];J.value=new Map;for(let[Q,D]of q){let X=U.keyType._zod.run({value:Q,issues:[]},G),Y=U.valueType._zod.run({value:D,issues:[]},G);if(X instanceof Promise||Y instanceof Promise)I.push(Promise.all([X,Y]).then(([V,W])=>{Yz(V,W,J,Q,q,$,G)}));else Yz(X,Y,J,Q,q,$,G)}if(I.length)return Promise.all(I).then(()=>J);return J}});PO=r("$ZodSet",($,U)=>{E$.init($,U),$._zod.parse=(J,G)=>{let q=J.value;if(!(q instanceof Set))return J.issues.push({input:q,inst:$,expected:"set",code:"invalid_type"}),J;let I=[];J.value=new Set;for(let Q of q){let D=U.valueType._zod.run({value:Q,issues:[]},G);if(D instanceof Promise)I.push(D.then((X)=>Vz(X,J)));else Vz(D,J)}if(I.length)return Promise.all(I).then(()=>J);return J}});BO=r("$ZodEnum",($,U)=>{E$.init($,U);let J=h6(U.entries),G=new Set(J);$._zod.values=G,$._zod.pattern=new RegExp(`^(${J.filter((q)=>l6.has(typeof q)).map((q)=>typeof q==="string"?gU(q):q.toString()).join("|")})$`),$._zod.parse=(q,I)=>{let Q=q.value;if(G.has(Q))return q;return q.issues.push({code:"invalid_value",values:J,input:Q,inst:$}),q}}),SO=r("$ZodLiteral",($,U)=>{if(E$.init($,U),U.values.length===0)throw Error("Cannot create literal schema with no valid values");let J=new Set(U.values);$._zod.values=J,$._zod.pattern=new RegExp(`^(${U.values.map((G)=>typeof G==="string"?gU(G):G?gU(G.toString()):String(G)).join("|")})$`),$._zod.parse=(G,q)=>{let I=G.value;if(J.has(I))return G;return G.issues.push({code:"invalid_value",values:U.values,input:I,inst:$}),G}}),LO=r("$ZodFile",($,U)=>{E$.init($,U),$._zod.parse=(J,G)=>{let q=J.value;if(q instanceof File)return J;return J.issues.push({expected:"file",code:"invalid_type",input:q,inst:$}),J}}),EO=r("$ZodTransform",($,U)=>{E$.init($,U),$._zod.optin="optional",$._zod.parse=(J,G)=>{if(G.direction==="backward")throw new bq($.constructor.name);let q=U.transform(J.value,J);if(G.async)return(q instanceof Promise?q:Promise.resolve(q)).then((Q)=>{return J.value=Q,J.fallback=!0,J});if(q instanceof Promise)throw new pU;return J.value=q,J.fallback=!0,J}});lQ=r("$ZodOptional",($,U)=>{E$.init($,U),$._zod.optin="optional",$._zod.optout="optional",F$($._zod,"values",()=>{return U.innerType._zod.values?new Set([...U.innerType._zod.values,void 0]):void 0}),F$($._zod,"pattern",()=>{let J=U.innerType._zod.pattern;return J?new RegExp(`^(${r6(J.source)})?$`):void 0}),$._zod.parse=(J,G)=>{if(U.innerType._zod.optin==="optional"){let q=J.value,I=U.innerType._zod.run(J,G);if(I instanceof Promise)return I.then((Q)=>Wz(Q,q));return Wz(I,q)}if(J.value===void 0)return J;return U.innerType._zod.run(J,G)}}),CO=r("$ZodExactOptional",($,U)=>{lQ.init($,U),F$($._zod,"values",()=>U.innerType._zod.values),F$($._zod,"pattern",()=>U.innerType._zod.pattern),$._zod.parse=(J,G)=>{return U.innerType._zod.run(J,G)}}),_O=r("$ZodNullable",($,U)=>{E$.init($,U),F$($._zod,"optin",()=>U.innerType._zod.optin),F$($._zod,"optout",()=>U.innerType._zod.optout),F$($._zod,"pattern",()=>{let J=U.innerType._zod.pattern;return J?new RegExp(`^(${r6(J.source)}|null)$`):void 0}),F$($._zod,"values",()=>{return U.innerType._zod.values?new Set([...U.innerType._zod.values,null]):void 0}),$._zod.parse=(J,G)=>{if(J.value===null)return J;return U.innerType._zod.run(J,G)}}),vO=r("$ZodDefault",($,U)=>{E$.init($,U),$._zod.optin="optional",F$($._zod,"values",()=>U.innerType._zod.values),$._zod.parse=(J,G)=>{if(G.direction==="backward")return U.innerType._zod.run(J,G);if(J.value===void 0)return J.value=U.defaultValue,J;let q=U.innerType._zod.run(J,G);if(q instanceof Promise)return q.then((I)=>Oz(I,U));return Oz(q,U)}});FO=r("$ZodPrefault",($,U)=>{E$.init($,U),$._zod.optin="optional",F$($._zod,"values",()=>U.innerType._zod.values),$._zod.parse=(J,G)=>{if(G.direction==="backward")return U.innerType._zod.run(J,G);if(J.value===void 0)J.value=U.defaultValue;return U.innerType._zod.run(J,G)}}),bO=r("$ZodNonOptional",($,U)=>{E$.init($,U),F$($._zod,"values",()=>{let J=U.innerType._zod.values;return J?new Set([...J].filter((G)=>G!==void 0)):void 0}),$._zod.parse=(J,G)=>{let q=U.innerType._zod.run(J,G);if(q instanceof Promise)return q.then((I)=>Zz(I,$));return Zz(q,$)}});uO=r("$ZodSuccess",($,U)=>{E$.init($,U),$._zod.parse=(J,G)=>{if(G.direction==="backward")throw new bq("ZodSuccess");let q=U.innerType._zod.run(J,G);if(q instanceof Promise)return q.then((I)=>{return J.value=I.issues.length===0,J});return J.value=q.issues.length===0,J}}),kO=r("$ZodCatch",($,U)=>{E$.init($,U),$._zod.optin="optional",F$($._zod,"optout",()=>U.innerType._zod.optout),F$($._zod,"values",()=>U.innerType._zod.values),$._zod.parse=(J,G)=>{if(G.direction==="backward")return U.innerType._zod.run(J,G);let q=U.innerType._zod.run(J,G);if(q instanceof Promise)return q.then((I)=>{if(J.value=I.value,I.issues.length)J.value=U.catchValue({...J,error:{issues:I.issues.map((Q)=>l0(Q,G,a$()))},input:J.value}),J.issues=[],J.fallback=!0;return J});if(J.value=q.value,q.issues.length)J.value=U.catchValue({...J,error:{issues:q.issues.map((I)=>l0(I,G,a$()))},input:J.value}),J.issues=[],J.fallback=!0;return J}}),xO=r("$ZodNaN",($,U)=>{E$.init($,U),$._zod.parse=(J,G)=>{if(typeof J.value!=="number"||!Number.isNaN(J.value))return J.issues.push({input:J.value,inst:$,expected:"nan",code:"invalid_type"}),J;return J}}),iQ=r("$ZodPipe",($,U)=>{E$.init($,U),F$($._zod,"values",()=>U.in._zod.values),F$($._zod,"optin",()=>U.in._zod.optin),F$($._zod,"optout",()=>U.out._zod.optout),F$($._zod,"propValues",()=>U.in._zod.propValues),$._zod.parse=(J,G)=>{if(G.direction==="backward"){let I=U.out._zod.run(J,G);if(I instanceof Promise)return I.then((Q)=>kQ(Q,U.in,G));return kQ(I,U.in,G)}let q=U.in._zod.run(J,G);if(q instanceof Promise)return q.then((I)=>kQ(I,U.out,G));return kQ(q,U.out,G)}});$4=r("$ZodCodec",($,U)=>{E$.init($,U),F$($._zod,"values",()=>U.in._zod.values),F$($._zod,"optin",()=>U.in._zod.optin),F$($._zod,"optout",()=>U.out._zod.optout),F$($._zod,"propValues",()=>U.in._zod.propValues),$._zod.parse=(J,G)=>{if((G.direction||"forward")==="forward"){let I=U.in._zod.run(J,G);if(I instanceof Promise)return I.then((Q)=>xQ(Q,U,G));return xQ(I,U,G)}else{let I=U.out._zod.run(J,G);if(I instanceof Promise)return I.then((Q)=>xQ(Q,U,G));return xQ(I,U,G)}}});fO=r("$ZodPreprocess",($,U)=>{iQ.init($,U)}),yO=r("$ZodReadonly",($,U)=>{E$.init($,U),F$($._zod,"propValues",()=>U.innerType._zod.propValues),F$($._zod,"values",()=>U.innerType._zod.values),F$($._zod,"optin",()=>U.innerType?._zod?.optin),F$($._zod,"optout",()=>U.innerType?._zod?.optout),$._zod.parse=(J,G)=>{if(G.direction==="backward")return U.innerType._zod.run(J,G);let q=U.innerType._zod.run(J,G);if(q instanceof Promise)return q.then(Rz);return Rz(q)}});mO=r("$ZodTemplateLiteral",($,U)=>{E$.init($,U);let J=[];for(let G of U.parts)if(typeof G==="object"&&G!==null){if(!G._zod.pattern)throw Error(`Invalid template literal part, no pattern found: ${[...G._zod.traits].shift()}`);let q=G._zod.pattern instanceof RegExp?G._zod.pattern.source:G._zod.pattern;if(!q)throw Error(`Invalid template literal part: ${G._zod.traits}`);let I=q.startsWith("^")?1:0,Q=q.endsWith("$")?q.length-1:q.length;J.push(q.slice(I,Q))}else if(G===null||EV.has(typeof G))J.push(gU(`${G}`));else throw Error(`Invalid template literal part: ${G}`);$._zod.pattern=new RegExp(`^${J.join("")}$`),$._zod.parse=(G,q)=>{if(typeof G.value!=="string")return G.issues.push({input:G.value,inst:$,expected:"string",code:"invalid_type"}),G;if($._zod.pattern.lastIndex=0,!$._zod.pattern.test(G.value))return G.issues.push({input:G.value,inst:$,code:"invalid_format",format:U.format??"template_literal",pattern:$._zod.pattern.source}),G;return G}}),hO=r("$ZodFunction",($,U)=>{return E$.init($,U),$._def=U,$._zod.def=U,$.implement=(J)=>{if(typeof J!=="function")throw Error("implement() must be called with a function");return function(...G){let q=$._def.input?zQ($._def.input,G):G,I=Reflect.apply(J,this,q);if($._def.output)return zQ($._def.output,I);return I}},$.implementAsync=(J)=>{if(typeof J!=="function")throw Error("implementAsync() must be called with a function");return async function(...G){let q=$._def.input?await AQ($._def.input,G):G,I=await Reflect.apply(J,this,q);if($._def.output)return await AQ($._def.output,I);return I}},$._zod.parse=(J,G)=>{if(typeof J.value!=="function")return J.issues.push({code:"invalid_type",expected:"function",input:J.value,inst:$}),J;if($._def.output&&$._def.output._zod.def.type==="promise")J.value=$.implementAsync(J.value);else J.value=$.implement(J.value);return J},$.input=(...J)=>{let G=$.constructor;if(Array.isArray(J[0]))return new G({type:"function",input:new rQ({type:"tuple",items:J[0],rest:J[1]}),output:$._def.output});return new G({type:"function",input:J[0],output:$._def.output})},$.output=(J)=>{return new $.constructor({type:"function",input:$._def.input,output:J})},$}),rO=r("$ZodPromise",($,U)=>{E$.init($,U),$._zod.parse=(J,G)=>{return Promise.resolve(J.value).then((q)=>U.innerType._zod.run({value:q,issues:[]},G))}}),lO=r("$ZodLazy",($,U)=>{E$.init($,U),F$($._zod,"innerType",()=>{let J=U;if(!J._cachedInner)J._cachedInner=U.getter();return J._cachedInner}),F$($._zod,"pattern",()=>$._zod.innerType?._zod?.pattern),F$($._zod,"propValues",()=>$._zod.innerType?._zod?.propValues),F$($._zod,"optin",()=>$._zod.innerType?._zod?.optin??void 0),F$($._zod,"optout",()=>$._zod.innerType?._zod?.optout??void 0),$._zod.parse=(J,G)=>{return $._zod.innerType._zod.run(J,G)}}),iO=r("$ZodCustom",($,U)=>{p$.init($,U),E$.init($,U),$._zod.parse=(J,G)=>{return J},$._zod.check=(J)=>{let G=J.value,q=U.fn(G);if(q instanceof Promise)return q.then((I)=>Nz(I,J,G,$));Nz(q,J,G,$);return}})});function dO(){return{localeError:lb()}}var lb=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))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 instanceof ${q.expected}\u060C \u0648\u0644\u0643\u0646 \u062A\u0645 \u0625\u062F\u062E\u0627\u0644 ${D}`;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 ${I}\u060C \u0648\u0644\u0643\u0646 \u062A\u0645 \u0625\u062F\u062E\u0627\u0644 ${D}`}case"invalid_value":if(q.values.length===1)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 ${Q$(q.values[0])}`;return`\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: ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return` \u0623\u0643\u0628\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0623\u0646 \u062A\u0643\u0648\u0646 ${q.origin??"\u0627\u0644\u0642\u064A\u0645\u0629"} ${I} ${q.maximum.toString()} ${Q.unit??"\u0639\u0646\u0635\u0631"}`;return`\u0623\u0643\u0628\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0623\u0646 \u062A\u0643\u0648\u0646 ${q.origin??"\u0627\u0644\u0642\u064A\u0645\u0629"} ${I} ${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`\u0623\u0635\u063A\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0644\u0640 ${q.origin} \u0623\u0646 \u064A\u0643\u0648\u0646 ${I} ${q.minimum.toString()} ${Q.unit}`;return`\u0623\u0635\u063A\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0644\u0640 ${q.origin} \u0623\u0646 \u064A\u0643\u0648\u0646 ${I} ${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0628\u062F\u0623 \u0628\u0640 "${q.prefix}"`;if(I.format==="ends_with")return`\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}"`;if(I.format==="includes")return`\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}"`;if(I.format==="regex")return`\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}`;return`${J[I.format]??q.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 ${q.divisor}`;case"unrecognized_keys":return`\u0645\u0639\u0631\u0641${q.keys.length>1?"\u0627\u062A":""} \u063A\u0631\u064A\u0628${q.keys.length>1?"\u0629":""}: ${n(q.keys,"\u060C ")}`;case"invalid_key":return`\u0645\u0639\u0631\u0641 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644 \u0641\u064A ${q.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 ${q.origin}`;default:return"\u0645\u062F\u062E\u0644 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644"}}};var Az=O$(()=>{g$()});function nO(){return{localeError:ib()}}var ib=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Yanl\u0131\u015F d\u0259y\u0259r: g\xF6zl\u0259nil\u0259n instanceof ${q.expected}, daxil olan ${D}`;return`Yanl\u0131\u015F d\u0259y\u0259r: g\xF6zl\u0259nil\u0259n ${I}, daxil olan ${D}`}case"invalid_value":if(q.values.length===1)return`Yanl\u0131\u015F d\u0259y\u0259r: g\xF6zl\u0259nil\u0259n ${Q$(q.values[0])}`;return`Yanl\u0131\u015F se\xE7im: a\u015Fa\u011F\u0131dak\u0131lardan biri olmal\u0131d\u0131r: ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`\xC7ox b\xF6y\xFCk: g\xF6zl\u0259nil\u0259n ${q.origin??"d\u0259y\u0259r"} ${I}${q.maximum.toString()} ${Q.unit??"element"}`;return`\xC7ox b\xF6y\xFCk: g\xF6zl\u0259nil\u0259n ${q.origin??"d\u0259y\u0259r"} ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`\xC7ox ki\xE7ik: g\xF6zl\u0259nil\u0259n ${q.origin} ${I}${q.minimum.toString()} ${Q.unit}`;return`\xC7ox ki\xE7ik: g\xF6zl\u0259nil\u0259n ${q.origin} ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Yanl\u0131\u015F m\u0259tn: "${I.prefix}" il\u0259 ba\u015Flamal\u0131d\u0131r`;if(I.format==="ends_with")return`Yanl\u0131\u015F m\u0259tn: "${I.suffix}" il\u0259 bitm\u0259lidir`;if(I.format==="includes")return`Yanl\u0131\u015F m\u0259tn: "${I.includes}" daxil olmal\u0131d\u0131r`;if(I.format==="regex")return`Yanl\u0131\u015F m\u0259tn: ${I.pattern} \u015Fablonuna uy\u011Fun olmal\u0131d\u0131r`;return`Yanl\u0131\u015F ${J[I.format]??q.format}`}case"not_multiple_of":return`Yanl\u0131\u015F \u0259d\u0259d: ${q.divisor} il\u0259 b\xF6l\xFCn\u0259 bil\u0259n olmal\u0131d\u0131r`;case"unrecognized_keys":return`Tan\u0131nmayan a\xE7ar${q.keys.length>1?"lar":""}: ${n(q.keys,", ")}`;case"invalid_key":return`${q.origin} daxilind\u0259 yanl\u0131\u015F a\xE7ar`;case"invalid_union":return"Yanl\u0131\u015F d\u0259y\u0259r";case"invalid_element":return`${q.origin} daxilind\u0259 yanl\u0131\u015F d\u0259y\u0259r`;default:return"Yanl\u0131\u015F d\u0259y\u0259r"}}};var Kz=O$(()=>{g$()});function gz($,U,J,G){let q=Math.abs($),I=q%10,Q=q%100;if(Q>=11&&Q<=19)return G;if(I===1)return U;if(I>=2&&I<=4)return J;return G}function cO(){return{localeError:pb()}}var pb=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"\u043B\u0456\u043A",array:"\u043C\u0430\u0441\u0456\u045E"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434: \u0447\u0430\u043A\u0430\u045E\u0441\u044F instanceof ${q.expected}, \u0430\u0442\u0440\u044B\u043C\u0430\u043D\u0430 ${D}`;return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434: \u0447\u0430\u043A\u0430\u045E\u0441\u044F ${I}, \u0430\u0442\u0440\u044B\u043C\u0430\u043D\u0430 ${D}`}case"invalid_value":if(q.values.length===1)return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F ${Q$(q.values[0])}`;return`\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 ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q){let D=Number(q.maximum),X=gz(D,Q.unit.one,Q.unit.few,Q.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 ${q.origin??"\u0437\u043D\u0430\u0447\u044D\u043D\u043D\u0435"} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 ${Q.verb} ${I}${q.maximum.toString()} ${X}`}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 ${q.origin??"\u0437\u043D\u0430\u0447\u044D\u043D\u043D\u0435"} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 \u0431\u044B\u0446\u044C ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q){let D=Number(q.minimum),X=gz(D,Q.unit.one,Q.unit.few,Q.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 ${q.origin} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 ${Q.verb} ${I}${q.minimum.toString()} ${X}`}return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u043C\u0430\u043B\u044B: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${q.origin} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 \u0431\u044B\u0446\u044C ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\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}"`;if(I.format==="ends_with")return`\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}"`;if(I.format==="includes")return`\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}"`;if(I.format==="regex")return`\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}`;return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B ${J[I.format]??q.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 ${q.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u0430\u0441\u043F\u0430\u0437\u043D\u0430\u043D\u044B ${q.keys.length>1?"\u043A\u043B\u044E\u0447\u044B":"\u043A\u043B\u044E\u0447"}: ${n(q.keys,", ")}`;case"invalid_key":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u043A\u043B\u044E\u0447 \u0443 ${q.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 ${q.origin}`;default:return"\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434"}}};var jz=O$(()=>{g$()});function oO(){return{localeError:db()}}var db=()=>{let $={string:{unit:"\u0441\u0438\u043C\u0432\u043E\u043B\u0430",verb:"\u0434\u0430 \u0441\u044A\u0434\u044A\u0440\u0436\u0430"},file:{unit:"\u0431\u0430\u0439\u0442\u0430",verb:"\u0434\u0430 \u0441\u044A\u0434\u044A\u0440\u0436\u0430"},array:{unit:"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0430",verb:"\u0434\u0430 \u0441\u044A\u0434\u044A\u0440\u0436\u0430"},set:{unit:"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0430",verb:"\u0434\u0430 \u0441\u044A\u0434\u044A\u0440\u0436\u0430"}};function U(q){return $[q]??null}let J={regex:"\u0432\u0445\u043E\u0434",email:"\u0438\u043C\u0435\u0439\u043B \u0430\u0434\u0440\u0435\u0441",url:"URL",emoji:"\u0435\u043C\u043E\u0434\u0436\u0438",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0432\u0440\u0435\u043C\u0435",date:"ISO \u0434\u0430\u0442\u0430",time:"ISO \u0432\u0440\u0435\u043C\u0435",duration:"ISO \u043F\u0440\u043E\u0434\u044A\u043B\u0436\u0438\u0442\u0435\u043B\u043D\u043E\u0441\u0442",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:"base64-\u043A\u043E\u0434\u0438\u0440\u0430\u043D \u043D\u0438\u0437",base64url:"base64url-\u043A\u043E\u0434\u0438\u0440\u0430\u043D \u043D\u0438\u0437",json_string:"JSON \u043D\u0438\u0437",e164:"E.164 \u043D\u043E\u043C\u0435\u0440",jwt:"JWT",template_literal:"\u0432\u0445\u043E\u0434"},G={nan:"NaN",number:"\u0447\u0438\u0441\u043B\u043E",array:"\u043C\u0430\u0441\u0438\u0432"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u0432\u0445\u043E\u0434: \u043E\u0447\u0430\u043A\u0432\u0430\u043D instanceof ${q.expected}, \u043F\u043E\u043B\u0443\u0447\u0435\u043D ${D}`;return`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u0432\u0445\u043E\u0434: \u043E\u0447\u0430\u043A\u0432\u0430\u043D ${I}, \u043F\u043E\u043B\u0443\u0447\u0435\u043D ${D}`}case"invalid_value":if(q.values.length===1)return`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u0432\u0445\u043E\u0434: \u043E\u0447\u0430\u043A\u0432\u0430\u043D ${Q$(q.values[0])}`;return`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u043D\u0430 \u043E\u043F\u0446\u0438\u044F: \u043E\u0447\u0430\u043A\u0432\u0430\u043D\u043E \u0435\u0434\u043D\u043E \u043E\u0442 ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`\u0422\u0432\u044A\u0440\u0434\u0435 \u0433\u043E\u043B\u044F\u043C\u043E: \u043E\u0447\u0430\u043A\u0432\u0430 \u0441\u0435 ${q.origin??"\u0441\u0442\u043E\u0439\u043D\u043E\u0441\u0442"} \u0434\u0430 \u0441\u044A\u0434\u044A\u0440\u0436\u0430 ${I}${q.maximum.toString()} ${Q.unit??"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0430"}`;return`\u0422\u0432\u044A\u0440\u0434\u0435 \u0433\u043E\u043B\u044F\u043C\u043E: \u043E\u0447\u0430\u043A\u0432\u0430 \u0441\u0435 ${q.origin??"\u0441\u0442\u043E\u0439\u043D\u043E\u0441\u0442"} \u0434\u0430 \u0431\u044A\u0434\u0435 ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`\u0422\u0432\u044A\u0440\u0434\u0435 \u043C\u0430\u043B\u043A\u043E: \u043E\u0447\u0430\u043A\u0432\u0430 \u0441\u0435 ${q.origin} \u0434\u0430 \u0441\u044A\u0434\u044A\u0440\u0436\u0430 ${I}${q.minimum.toString()} ${Q.unit}`;return`\u0422\u0432\u044A\u0440\u0434\u0435 \u043C\u0430\u043B\u043A\u043E: \u043E\u0447\u0430\u043A\u0432\u0430 \u0441\u0435 ${q.origin} \u0434\u0430 \u0431\u044A\u0434\u0435 ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u043D\u0438\u0437: \u0442\u0440\u044F\u0431\u0432\u0430 \u0434\u0430 \u0437\u0430\u043F\u043E\u0447\u0432\u0430 \u0441 "${I.prefix}"`;if(I.format==="ends_with")return`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u043D\u0438\u0437: \u0442\u0440\u044F\u0431\u0432\u0430 \u0434\u0430 \u0437\u0430\u0432\u044A\u0440\u0448\u0432\u0430 \u0441 "${I.suffix}"`;if(I.format==="includes")return`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u043D\u0438\u0437: \u0442\u0440\u044F\u0431\u0432\u0430 \u0434\u0430 \u0432\u043A\u043B\u044E\u0447\u0432\u0430 "${I.includes}"`;if(I.format==="regex")return`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u043D\u0438\u0437: \u0442\u0440\u044F\u0431\u0432\u0430 \u0434\u0430 \u0441\u044A\u0432\u043F\u0430\u0434\u0430 \u0441 ${I.pattern}`;let Q="\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D";if(I.format==="emoji")Q="\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u043D\u043E";if(I.format==="datetime")Q="\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u043D\u043E";if(I.format==="date")Q="\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u043D\u0430";if(I.format==="time")Q="\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u043D\u043E";if(I.format==="duration")Q="\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u043D\u0430";return`${Q} ${J[I.format]??q.format}`}case"not_multiple_of":return`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u043D\u043E \u0447\u0438\u0441\u043B\u043E: \u0442\u0440\u044F\u0431\u0432\u0430 \u0434\u0430 \u0431\u044A\u0434\u0435 \u043A\u0440\u0430\u0442\u043D\u043E \u043D\u0430 ${q.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u0430\u0437\u043F\u043E\u0437\u043D\u0430\u0442${q.keys.length>1?"\u0438":""} \u043A\u043B\u044E\u0447${q.keys.length>1?"\u043E\u0432\u0435":""}: ${n(q.keys,", ")}`;case"invalid_key":return`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u043A\u043B\u044E\u0447 \u0432 ${q.origin}`;case"invalid_union":return"\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u0432\u0445\u043E\u0434";case"invalid_element":return`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u043D\u0430 \u0441\u0442\u043E\u0439\u043D\u043E\u0441\u0442 \u0432 ${q.origin}`;default:return"\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u0432\u0445\u043E\u0434"}}};var Pz=O$(()=>{g$()});function aO(){return{localeError:nb()}}var nb=()=>{let $={string:{unit:"car\xE0cters",verb:"contenir"},file:{unit:"bytes",verb:"contenir"},array:{unit:"elements",verb:"contenir"},set:{unit:"elements",verb:"contenir"}};function U(q){return $[q]??null}let J={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"},G={nan:"NaN"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Tipus inv\xE0lid: s'esperava instanceof ${q.expected}, s'ha rebut ${D}`;return`Tipus inv\xE0lid: s'esperava ${I}, s'ha rebut ${D}`}case"invalid_value":if(q.values.length===1)return`Valor inv\xE0lid: s'esperava ${Q$(q.values[0])}`;return`Opci\xF3 inv\xE0lida: s'esperava una de ${n(q.values," o ")}`;case"too_big":{let I=q.inclusive?"com a m\xE0xim":"menys de",Q=U(q.origin);if(Q)return`Massa gran: s'esperava que ${q.origin??"el valor"} contingu\xE9s ${I} ${q.maximum.toString()} ${Q.unit??"elements"}`;return`Massa gran: s'esperava que ${q.origin??"el valor"} fos ${I} ${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?"com a m\xEDnim":"m\xE9s de",Q=U(q.origin);if(Q)return`Massa petit: s'esperava que ${q.origin} contingu\xE9s ${I} ${q.minimum.toString()} ${Q.unit}`;return`Massa petit: s'esperava que ${q.origin} fos ${I} ${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Format inv\xE0lid: ha de comen\xE7ar amb "${I.prefix}"`;if(I.format==="ends_with")return`Format inv\xE0lid: ha d'acabar amb "${I.suffix}"`;if(I.format==="includes")return`Format inv\xE0lid: ha d'incloure "${I.includes}"`;if(I.format==="regex")return`Format inv\xE0lid: ha de coincidir amb el patr\xF3 ${I.pattern}`;return`Format inv\xE0lid per a ${J[I.format]??q.format}`}case"not_multiple_of":return`N\xFAmero inv\xE0lid: ha de ser m\xFAltiple de ${q.divisor}`;case"unrecognized_keys":return`Clau${q.keys.length>1?"s":""} no reconeguda${q.keys.length>1?"s":""}: ${n(q.keys,", ")}`;case"invalid_key":return`Clau inv\xE0lida a ${q.origin}`;case"invalid_union":return"Entrada inv\xE0lida";case"invalid_element":return`Element inv\xE0lid a ${q.origin}`;default:return"Entrada inv\xE0lida"}}};var Bz=O$(()=>{g$()});function sO(){return{localeError:cb()}}var cb=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"\u010D\xEDslo",string:"\u0159et\u011Bzec",function:"funkce",array:"pole"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Neplatn\xFD vstup: o\u010Dek\xE1v\xE1no instanceof ${q.expected}, obdr\u017Eeno ${D}`;return`Neplatn\xFD vstup: o\u010Dek\xE1v\xE1no ${I}, obdr\u017Eeno ${D}`}case"invalid_value":if(q.values.length===1)return`Neplatn\xFD vstup: o\u010Dek\xE1v\xE1no ${Q$(q.values[0])}`;return`Neplatn\xE1 mo\u017Enost: o\u010Dek\xE1v\xE1na jedna z hodnot ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`Hodnota je p\u0159\xEDli\u0161 velk\xE1: ${q.origin??"hodnota"} mus\xED m\xEDt ${I}${q.maximum.toString()} ${Q.unit??"prvk\u016F"}`;return`Hodnota je p\u0159\xEDli\u0161 velk\xE1: ${q.origin??"hodnota"} mus\xED b\xFDt ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`Hodnota je p\u0159\xEDli\u0161 mal\xE1: ${q.origin??"hodnota"} mus\xED m\xEDt ${I}${q.minimum.toString()} ${Q.unit??"prvk\u016F"}`;return`Hodnota je p\u0159\xEDli\u0161 mal\xE1: ${q.origin??"hodnota"} mus\xED b\xFDt ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Neplatn\xFD \u0159et\u011Bzec: mus\xED za\u010D\xEDnat na "${I.prefix}"`;if(I.format==="ends_with")return`Neplatn\xFD \u0159et\u011Bzec: mus\xED kon\u010Dit na "${I.suffix}"`;if(I.format==="includes")return`Neplatn\xFD \u0159et\u011Bzec: mus\xED obsahovat "${I.includes}"`;if(I.format==="regex")return`Neplatn\xFD \u0159et\u011Bzec: mus\xED odpov\xEDdat vzoru ${I.pattern}`;return`Neplatn\xFD form\xE1t ${J[I.format]??q.format}`}case"not_multiple_of":return`Neplatn\xE9 \u010D\xEDslo: mus\xED b\xFDt n\xE1sobkem ${q.divisor}`;case"unrecognized_keys":return`Nezn\xE1m\xE9 kl\xED\u010De: ${n(q.keys,", ")}`;case"invalid_key":return`Neplatn\xFD kl\xED\u010D v ${q.origin}`;case"invalid_union":return"Neplatn\xFD vstup";case"invalid_element":return`Neplatn\xE1 hodnota v ${q.origin}`;default:return"Neplatn\xFD vstup"}}};var Sz=O$(()=>{g$()});function tO(){return{localeError:ob()}}var ob=()=>{let $={string:{unit:"tegn",verb:"havde"},file:{unit:"bytes",verb:"havde"},array:{unit:"elementer",verb:"indeholdt"},set:{unit:"elementer",verb:"indeholdt"}};function U(q){return $[q]??null}let J={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"},G={nan:"NaN",string:"streng",number:"tal",boolean:"boolean",array:"liste",object:"objekt",set:"s\xE6t",file:"fil"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Ugyldigt input: forventede instanceof ${q.expected}, fik ${D}`;return`Ugyldigt input: forventede ${I}, fik ${D}`}case"invalid_value":if(q.values.length===1)return`Ugyldig v\xE6rdi: forventede ${Q$(q.values[0])}`;return`Ugyldigt valg: forventede en af f\xF8lgende ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin),D=G[q.origin]??q.origin;if(Q)return`For stor: forventede ${D??"value"} ${Q.verb} ${I} ${q.maximum.toString()} ${Q.unit??"elementer"}`;return`For stor: forventede ${D??"value"} havde ${I} ${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin),D=G[q.origin]??q.origin;if(Q)return`For lille: forventede ${D} ${Q.verb} ${I} ${q.minimum.toString()} ${Q.unit}`;return`For lille: forventede ${D} havde ${I} ${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Ugyldig streng: skal starte med "${I.prefix}"`;if(I.format==="ends_with")return`Ugyldig streng: skal ende med "${I.suffix}"`;if(I.format==="includes")return`Ugyldig streng: skal indeholde "${I.includes}"`;if(I.format==="regex")return`Ugyldig streng: skal matche m\xF8nsteret ${I.pattern}`;return`Ugyldig ${J[I.format]??q.format}`}case"not_multiple_of":return`Ugyldigt tal: skal v\xE6re deleligt med ${q.divisor}`;case"unrecognized_keys":return`${q.keys.length>1?"Ukendte n\xF8gler":"Ukendt n\xF8gle"}: ${n(q.keys,", ")}`;case"invalid_key":return`Ugyldig n\xF8gle i ${q.origin}`;case"invalid_union":return"Ugyldigt input: matcher ingen af de tilladte typer";case"invalid_element":return`Ugyldig v\xE6rdi i ${q.origin}`;default:return"Ugyldigt input"}}};var Lz=O$(()=>{g$()});function eO(){return{localeError:ab()}}var ab=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"Zahl",array:"Array"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Ung\xFCltige Eingabe: erwartet instanceof ${q.expected}, erhalten ${D}`;return`Ung\xFCltige Eingabe: erwartet ${I}, erhalten ${D}`}case"invalid_value":if(q.values.length===1)return`Ung\xFCltige Eingabe: erwartet ${Q$(q.values[0])}`;return`Ung\xFCltige Option: erwartet eine von ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`Zu gro\xDF: erwartet, dass ${q.origin??"Wert"} ${I}${q.maximum.toString()} ${Q.unit??"Elemente"} hat`;return`Zu gro\xDF: erwartet, dass ${q.origin??"Wert"} ${I}${q.maximum.toString()} ist`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`Zu klein: erwartet, dass ${q.origin} ${I}${q.minimum.toString()} ${Q.unit} hat`;return`Zu klein: erwartet, dass ${q.origin} ${I}${q.minimum.toString()} ist`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Ung\xFCltiger String: muss mit "${I.prefix}" beginnen`;if(I.format==="ends_with")return`Ung\xFCltiger String: muss mit "${I.suffix}" enden`;if(I.format==="includes")return`Ung\xFCltiger String: muss "${I.includes}" enthalten`;if(I.format==="regex")return`Ung\xFCltiger String: muss dem Muster ${I.pattern} entsprechen`;return`Ung\xFCltig: ${J[I.format]??q.format}`}case"not_multiple_of":return`Ung\xFCltige Zahl: muss ein Vielfaches von ${q.divisor} sein`;case"unrecognized_keys":return`${q.keys.length>1?"Unbekannte Schl\xFCssel":"Unbekannter Schl\xFCssel"}: ${n(q.keys,", ")}`;case"invalid_key":return`Ung\xFCltiger Schl\xFCssel in ${q.origin}`;case"invalid_union":return"Ung\xFCltige Eingabe";case"invalid_element":return`Ung\xFCltiger Wert in ${q.origin}`;default:return"Ung\xFCltige Eingabe"}}};var Ez=O$(()=>{g$()});function $1(){return{localeError:sb()}}var sb=()=>{let $={string:{unit:"\u03C7\u03B1\u03C1\u03B1\u03BA\u03C4\u03AE\u03C1\u03B5\u03C2",verb:"\u03BD\u03B1 \u03AD\u03C7\u03B5\u03B9"},file:{unit:"bytes",verb:"\u03BD\u03B1 \u03AD\u03C7\u03B5\u03B9"},array:{unit:"\u03C3\u03C4\u03BF\u03B9\u03C7\u03B5\u03AF\u03B1",verb:"\u03BD\u03B1 \u03AD\u03C7\u03B5\u03B9"},set:{unit:"\u03C3\u03C4\u03BF\u03B9\u03C7\u03B5\u03AF\u03B1",verb:"\u03BD\u03B1 \u03AD\u03C7\u03B5\u03B9"},map:{unit:"\u03BA\u03B1\u03C4\u03B1\u03C7\u03C9\u03C1\u03AE\u03C3\u03B5\u03B9\u03C2",verb:"\u03BD\u03B1 \u03AD\u03C7\u03B5\u03B9"}};function U(q){return $[q]??null}let J={regex:"\u03B5\u03AF\u03C3\u03BF\u03B4\u03BF\u03C2",email:"\u03B4\u03B9\u03B5\u03CD\u03B8\u03C5\u03BD\u03C3\u03B7 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:"ISO \u03B7\u03BC\u03B5\u03C1\u03BF\u03BC\u03B7\u03BD\u03AF\u03B1 \u03BA\u03B1\u03B9 \u03CE\u03C1\u03B1",date:"ISO \u03B7\u03BC\u03B5\u03C1\u03BF\u03BC\u03B7\u03BD\u03AF\u03B1",time:"ISO \u03CE\u03C1\u03B1",duration:"ISO \u03B4\u03B9\u03AC\u03C1\u03BA\u03B5\u03B9\u03B1",ipv4:"\u03B4\u03B9\u03B5\u03CD\u03B8\u03C5\u03BD\u03C3\u03B7 IPv4",ipv6:"\u03B4\u03B9\u03B5\u03CD\u03B8\u03C5\u03BD\u03C3\u03B7 IPv6",mac:"\u03B4\u03B9\u03B5\u03CD\u03B8\u03C5\u03BD\u03C3\u03B7 MAC",cidrv4:"\u03B5\u03CD\u03C1\u03BF\u03C2 IPv4",cidrv6:"\u03B5\u03CD\u03C1\u03BF\u03C2 IPv6",base64:"\u03C3\u03C5\u03BC\u03B2\u03BF\u03BB\u03BF\u03C3\u03B5\u03B9\u03C1\u03AC \u03BA\u03C9\u03B4\u03B9\u03BA\u03BF\u03C0\u03BF\u03B9\u03B7\u03BC\u03AD\u03BD\u03B7 \u03C3\u03B5 base64",base64url:"\u03C3\u03C5\u03BC\u03B2\u03BF\u03BB\u03BF\u03C3\u03B5\u03B9\u03C1\u03AC \u03BA\u03C9\u03B4\u03B9\u03BA\u03BF\u03C0\u03BF\u03B9\u03B7\u03BC\u03AD\u03BD\u03B7 \u03C3\u03B5 base64url",json_string:"\u03C3\u03C5\u03BC\u03B2\u03BF\u03BB\u03BF\u03C3\u03B5\u03B9\u03C1\u03AC JSON",e164:"\u03B1\u03C1\u03B9\u03B8\u03BC\u03CC\u03C2 E.164",jwt:"JWT",template_literal:"\u03B5\u03AF\u03C3\u03BF\u03B4\u03BF\u03C2"},G={nan:"NaN"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(typeof q.expected==="string"&&/^[A-Z]/.test(q.expected))return`\u039C\u03B7 \u03AD\u03B3\u03BA\u03C5\u03C1\u03B7 \u03B5\u03AF\u03C3\u03BF\u03B4\u03BF\u03C2: \u03B1\u03BD\u03B1\u03BC\u03B5\u03BD\u03CC\u03C4\u03B1\u03BD instanceof ${q.expected}, \u03BB\u03AE\u03C6\u03B8\u03B7\u03BA\u03B5 ${D}`;return`\u039C\u03B7 \u03AD\u03B3\u03BA\u03C5\u03C1\u03B7 \u03B5\u03AF\u03C3\u03BF\u03B4\u03BF\u03C2: \u03B1\u03BD\u03B1\u03BC\u03B5\u03BD\u03CC\u03C4\u03B1\u03BD ${I}, \u03BB\u03AE\u03C6\u03B8\u03B7\u03BA\u03B5 ${D}`}case"invalid_value":if(q.values.length===1)return`\u039C\u03B7 \u03AD\u03B3\u03BA\u03C5\u03C1\u03B7 \u03B5\u03AF\u03C3\u03BF\u03B4\u03BF\u03C2: \u03B1\u03BD\u03B1\u03BC\u03B5\u03BD\u03CC\u03C4\u03B1\u03BD ${Q$(q.values[0])}`;return`\u039C\u03B7 \u03AD\u03B3\u03BA\u03C5\u03C1\u03B7 \u03B5\u03C0\u03B9\u03BB\u03BF\u03B3\u03AE: \u03B1\u03BD\u03B1\u03BC\u03B5\u03BD\u03CC\u03C4\u03B1\u03BD \u03AD\u03BD\u03B1 \u03B1\u03C0\u03CC ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`\u03A0\u03BF\u03BB\u03CD \u03BC\u03B5\u03B3\u03AC\u03BB\u03BF: \u03B1\u03BD\u03B1\u03BC\u03B5\u03BD\u03CC\u03C4\u03B1\u03BD ${q.origin??"\u03C4\u03B9\u03BC\u03AE"} \u03BD\u03B1 \u03AD\u03C7\u03B5\u03B9 ${I}${q.maximum.toString()} ${Q.unit??"\u03C3\u03C4\u03BF\u03B9\u03C7\u03B5\u03AF\u03B1"}`;return`\u03A0\u03BF\u03BB\u03CD \u03BC\u03B5\u03B3\u03AC\u03BB\u03BF: \u03B1\u03BD\u03B1\u03BC\u03B5\u03BD\u03CC\u03C4\u03B1\u03BD ${q.origin??"\u03C4\u03B9\u03BC\u03AE"} \u03BD\u03B1 \u03B5\u03AF\u03BD\u03B1\u03B9 ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`\u03A0\u03BF\u03BB\u03CD \u03BC\u03B9\u03BA\u03C1\u03CC: \u03B1\u03BD\u03B1\u03BC\u03B5\u03BD\u03CC\u03C4\u03B1\u03BD ${q.origin} \u03BD\u03B1 \u03AD\u03C7\u03B5\u03B9 ${I}${q.minimum.toString()} ${Q.unit}`;return`\u03A0\u03BF\u03BB\u03CD \u03BC\u03B9\u03BA\u03C1\u03CC: \u03B1\u03BD\u03B1\u03BC\u03B5\u03BD\u03CC\u03C4\u03B1\u03BD ${q.origin} \u03BD\u03B1 \u03B5\u03AF\u03BD\u03B1\u03B9 ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\u039C\u03B7 \u03AD\u03B3\u03BA\u03C5\u03C1\u03B7 \u03C3\u03C5\u03BC\u03B2\u03BF\u03BB\u03BF\u03C3\u03B5\u03B9\u03C1\u03AC: \u03C0\u03C1\u03AD\u03C0\u03B5\u03B9 \u03BD\u03B1 \u03BE\u03B5\u03BA\u03B9\u03BD\u03AC \u03BC\u03B5 "${I.prefix}"`;if(I.format==="ends_with")return`\u039C\u03B7 \u03AD\u03B3\u03BA\u03C5\u03C1\u03B7 \u03C3\u03C5\u03BC\u03B2\u03BF\u03BB\u03BF\u03C3\u03B5\u03B9\u03C1\u03AC: \u03C0\u03C1\u03AD\u03C0\u03B5\u03B9 \u03BD\u03B1 \u03C4\u03B5\u03BB\u03B5\u03B9\u03CE\u03BD\u03B5\u03B9 \u03BC\u03B5 "${I.suffix}"`;if(I.format==="includes")return`\u039C\u03B7 \u03AD\u03B3\u03BA\u03C5\u03C1\u03B7 \u03C3\u03C5\u03BC\u03B2\u03BF\u03BB\u03BF\u03C3\u03B5\u03B9\u03C1\u03AC: \u03C0\u03C1\u03AD\u03C0\u03B5\u03B9 \u03BD\u03B1 \u03C0\u03B5\u03C1\u03B9\u03AD\u03C7\u03B5\u03B9 "${I.includes}"`;if(I.format==="regex")return`\u039C\u03B7 \u03AD\u03B3\u03BA\u03C5\u03C1\u03B7 \u03C3\u03C5\u03BC\u03B2\u03BF\u03BB\u03BF\u03C3\u03B5\u03B9\u03C1\u03AC: \u03C0\u03C1\u03AD\u03C0\u03B5\u03B9 \u03BD\u03B1 \u03C4\u03B1\u03B9\u03C1\u03B9\u03AC\u03B6\u03B5\u03B9 \u03BC\u03B5 \u03C4\u03BF \u03BC\u03BF\u03C4\u03AF\u03B2\u03BF ${I.pattern}`;return`\u039C\u03B7 \u03AD\u03B3\u03BA\u03C5\u03C1\u03BF: ${J[I.format]??q.format}`}case"not_multiple_of":return`\u039C\u03B7 \u03AD\u03B3\u03BA\u03C5\u03C1\u03BF\u03C2 \u03B1\u03C1\u03B9\u03B8\u03BC\u03CC\u03C2: \u03C0\u03C1\u03AD\u03C0\u03B5\u03B9 \u03BD\u03B1 \u03B5\u03AF\u03BD\u03B1\u03B9 \u03C0\u03BF\u03BB\u03BB\u03B1\u03C0\u03BB\u03AC\u03C3\u03B9\u03BF \u03C4\u03BF\u03C5 ${q.divisor}`;case"unrecognized_keys":return`\u0386\u03B3\u03BD\u03C9\u03C3\u03C4${q.keys.length>1?"\u03B1":"\u03BF"} \u03BA\u03BB\u03B5\u03B9\u03B4${q.keys.length>1?"\u03B9\u03AC":"\u03AF"}: ${n(q.keys,", ")}`;case"invalid_key":return`\u039C\u03B7 \u03AD\u03B3\u03BA\u03C5\u03C1\u03BF \u03BA\u03BB\u03B5\u03B9\u03B4\u03AF \u03C3\u03C4\u03BF ${q.origin}`;case"invalid_union":return"\u039C\u03B7 \u03AD\u03B3\u03BA\u03C5\u03C1\u03B7 \u03B5\u03AF\u03C3\u03BF\u03B4\u03BF\u03C2";case"invalid_element":return`\u039C\u03B7 \u03AD\u03B3\u03BA\u03C5\u03C1\u03B7 \u03C4\u03B9\u03BC\u03AE \u03C3\u03C4\u03BF ${q.origin}`;default:return"\u039C\u03B7 \u03AD\u03B3\u03BA\u03C5\u03C1\u03B7 \u03B5\u03AF\u03C3\u03BF\u03B4\u03BF\u03C2"}}};var Cz=O$(()=>{g$()});function U4(){return{localeError:tb()}}var tb=()=>{let $={string:{unit:"characters",verb:"to have"},file:{unit:"bytes",verb:"to have"},array:{unit:"items",verb:"to have"},set:{unit:"items",verb:"to have"},map:{unit:"entries",verb:"to have"}};function U(q){return $[q]??null}let J={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",mac:"MAC 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"},G={nan:"NaN"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;return`Invalid input: expected ${I}, received ${D}`}case"invalid_value":if(q.values.length===1)return`Invalid input: expected ${Q$(q.values[0])}`;return`Invalid option: expected one of ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`Too big: expected ${q.origin??"value"} to have ${I}${q.maximum.toString()} ${Q.unit??"elements"}`;return`Too big: expected ${q.origin??"value"} to be ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`Too small: expected ${q.origin} to have ${I}${q.minimum.toString()} ${Q.unit}`;return`Too small: expected ${q.origin} to be ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Invalid string: must start with "${I.prefix}"`;if(I.format==="ends_with")return`Invalid string: must end with "${I.suffix}"`;if(I.format==="includes")return`Invalid string: must include "${I.includes}"`;if(I.format==="regex")return`Invalid string: must match pattern ${I.pattern}`;return`Invalid ${J[I.format]??q.format}`}case"not_multiple_of":return`Invalid number: must be a multiple of ${q.divisor}`;case"unrecognized_keys":return`Unrecognized key${q.keys.length>1?"s":""}: ${n(q.keys,", ")}`;case"invalid_key":return`Invalid key in ${q.origin}`;case"invalid_union":if(q.options&&Array.isArray(q.options)&&q.options.length>0)return`Invalid discriminator value. Expected ${q.options.map((Q)=>`'${Q}'`).join(" | ")}`;return"Invalid input";case"invalid_element":return`Invalid value in ${q.origin}`;default:return"Invalid input"}}};var U1=O$(()=>{g$()});function J1(){return{localeError:eb()}}var eb=()=>{let $={string:{unit:"karaktrojn",verb:"havi"},file:{unit:"bajtojn",verb:"havi"},array:{unit:"elementojn",verb:"havi"},set:{unit:"elementojn",verb:"havi"}};function U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"nombro",array:"tabelo",null:"senvalora"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Nevalida enigo: atendi\u011Dis instanceof ${q.expected}, ricevi\u011Dis ${D}`;return`Nevalida enigo: atendi\u011Dis ${I}, ricevi\u011Dis ${D}`}case"invalid_value":if(q.values.length===1)return`Nevalida enigo: atendi\u011Dis ${Q$(q.values[0])}`;return`Nevalida opcio: atendi\u011Dis unu el ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`Tro granda: atendi\u011Dis ke ${q.origin??"valoro"} havu ${I}${q.maximum.toString()} ${Q.unit??"elementojn"}`;return`Tro granda: atendi\u011Dis ke ${q.origin??"valoro"} havu ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`Tro malgranda: atendi\u011Dis ke ${q.origin} havu ${I}${q.minimum.toString()} ${Q.unit}`;return`Tro malgranda: atendi\u011Dis ke ${q.origin} estu ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Nevalida karaktraro: devas komenci\u011Di per "${I.prefix}"`;if(I.format==="ends_with")return`Nevalida karaktraro: devas fini\u011Di per "${I.suffix}"`;if(I.format==="includes")return`Nevalida karaktraro: devas inkluzivi "${I.includes}"`;if(I.format==="regex")return`Nevalida karaktraro: devas kongrui kun la modelo ${I.pattern}`;return`Nevalida ${J[I.format]??q.format}`}case"not_multiple_of":return`Nevalida nombro: devas esti oblo de ${q.divisor}`;case"unrecognized_keys":return`Nekonata${q.keys.length>1?"j":""} \u015Dlosilo${q.keys.length>1?"j":""}: ${n(q.keys,", ")}`;case"invalid_key":return`Nevalida \u015Dlosilo en ${q.origin}`;case"invalid_union":return"Nevalida enigo";case"invalid_element":return`Nevalida valoro en ${q.origin}`;default:return"Nevalida enigo"}}};var _z=O$(()=>{g$()});function q1(){return{localeError:$u()}}var $u=()=>{let $={string:{unit:"caracteres",verb:"tener"},file:{unit:"bytes",verb:"tener"},array:{unit:"elementos",verb:"tener"},set:{unit:"elementos",verb:"tener"}};function U(q){return $[q]??null}let J={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"},G={nan:"NaN",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"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Entrada inv\xE1lida: se esperaba instanceof ${q.expected}, recibido ${D}`;return`Entrada inv\xE1lida: se esperaba ${I}, recibido ${D}`}case"invalid_value":if(q.values.length===1)return`Entrada inv\xE1lida: se esperaba ${Q$(q.values[0])}`;return`Opci\xF3n inv\xE1lida: se esperaba una de ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin),D=G[q.origin]??q.origin;if(Q)return`Demasiado grande: se esperaba que ${D??"valor"} tuviera ${I}${q.maximum.toString()} ${Q.unit??"elementos"}`;return`Demasiado grande: se esperaba que ${D??"valor"} fuera ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin),D=G[q.origin]??q.origin;if(Q)return`Demasiado peque\xF1o: se esperaba que ${D} tuviera ${I}${q.minimum.toString()} ${Q.unit}`;return`Demasiado peque\xF1o: se esperaba que ${D} fuera ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Cadena inv\xE1lida: debe comenzar con "${I.prefix}"`;if(I.format==="ends_with")return`Cadena inv\xE1lida: debe terminar en "${I.suffix}"`;if(I.format==="includes")return`Cadena inv\xE1lida: debe incluir "${I.includes}"`;if(I.format==="regex")return`Cadena inv\xE1lida: debe coincidir con el patr\xF3n ${I.pattern}`;return`Inv\xE1lido ${J[I.format]??q.format}`}case"not_multiple_of":return`N\xFAmero inv\xE1lido: debe ser m\xFAltiplo de ${q.divisor}`;case"unrecognized_keys":return`Llave${q.keys.length>1?"s":""} desconocida${q.keys.length>1?"s":""}: ${n(q.keys,", ")}`;case"invalid_key":return`Llave inv\xE1lida en ${G[q.origin]??q.origin}`;case"invalid_union":return"Entrada inv\xE1lida";case"invalid_element":return`Valor inv\xE1lido en ${G[q.origin]??q.origin}`;default:return"Entrada inv\xE1lida"}}};var vz=O$(()=>{g$()});function G1(){return{localeError:Uu()}}var Uu=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"\u0639\u062F\u062F",array:"\u0622\u0631\u0627\u06CC\u0647"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0645\u06CC\u200C\u0628\u0627\u06CC\u0633\u062A instanceof ${q.expected} \u0645\u06CC\u200C\u0628\u0648\u062F\u060C ${D} \u062F\u0631\u06CC\u0627\u0641\u062A \u0634\u062F`;return`\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0645\u06CC\u200C\u0628\u0627\u06CC\u0633\u062A ${I} \u0645\u06CC\u200C\u0628\u0648\u062F\u060C ${D} \u062F\u0631\u06CC\u0627\u0641\u062A \u0634\u062F`}case"invalid_value":if(q.values.length===1)return`\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0645\u06CC\u200C\u0628\u0627\u06CC\u0633\u062A ${Q$(q.values[0])} \u0645\u06CC\u200C\u0628\u0648\u062F`;return`\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 ${n(q.values,"|")} \u0645\u06CC\u200C\u0628\u0648\u062F`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`\u062E\u06CC\u0644\u06CC \u0628\u0632\u0631\u06AF: ${q.origin??"\u0645\u0642\u062F\u0627\u0631"} \u0628\u0627\u06CC\u062F ${I}${q.maximum.toString()} ${Q.unit??"\u0639\u0646\u0635\u0631"} \u0628\u0627\u0634\u062F`;return`\u062E\u06CC\u0644\u06CC \u0628\u0632\u0631\u06AF: ${q.origin??"\u0645\u0642\u062F\u0627\u0631"} \u0628\u0627\u06CC\u062F ${I}${q.maximum.toString()} \u0628\u0627\u0634\u062F`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`\u062E\u06CC\u0644\u06CC \u06A9\u0648\u0686\u06A9: ${q.origin} \u0628\u0627\u06CC\u062F ${I}${q.minimum.toString()} ${Q.unit} \u0628\u0627\u0634\u062F`;return`\u062E\u06CC\u0644\u06CC \u06A9\u0648\u0686\u06A9: ${q.origin} \u0628\u0627\u06CC\u062F ${I}${q.minimum.toString()} \u0628\u0627\u0634\u062F`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\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`;if(I.format==="ends_with")return`\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`;if(I.format==="includes")return`\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`;if(I.format==="regex")return`\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`;return`${J[I.format]??q.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 ${q.divisor} \u0628\u0627\u0634\u062F`;case"unrecognized_keys":return`\u06A9\u0644\u06CC\u062F${q.keys.length>1?"\u0647\u0627\u06CC":""} \u0646\u0627\u0634\u0646\u0627\u0633: ${n(q.keys,", ")}`;case"invalid_key":return`\u06A9\u0644\u06CC\u062F \u0646\u0627\u0634\u0646\u0627\u0633 \u062F\u0631 ${q.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 ${q.origin}`;default:return"\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631"}}};var Fz=O$(()=>{g$()});function I1(){return{localeError:Ju()}}var Ju=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Virheellinen tyyppi: odotettiin instanceof ${q.expected}, oli ${D}`;return`Virheellinen tyyppi: odotettiin ${I}, oli ${D}`}case"invalid_value":if(q.values.length===1)return`Virheellinen sy\xF6te: t\xE4ytyy olla ${Q$(q.values[0])}`;return`Virheellinen valinta: t\xE4ytyy olla yksi seuraavista: ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`Liian suuri: ${Q.subject} t\xE4ytyy olla ${I}${q.maximum.toString()} ${Q.unit}`.trim();return`Liian suuri: arvon t\xE4ytyy olla ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`Liian pieni: ${Q.subject} t\xE4ytyy olla ${I}${q.minimum.toString()} ${Q.unit}`.trim();return`Liian pieni: arvon t\xE4ytyy olla ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Virheellinen sy\xF6te: t\xE4ytyy alkaa "${I.prefix}"`;if(I.format==="ends_with")return`Virheellinen sy\xF6te: t\xE4ytyy loppua "${I.suffix}"`;if(I.format==="includes")return`Virheellinen sy\xF6te: t\xE4ytyy sis\xE4lt\xE4\xE4 "${I.includes}"`;if(I.format==="regex")return`Virheellinen sy\xF6te: t\xE4ytyy vastata s\xE4\xE4nn\xF6llist\xE4 lauseketta ${I.pattern}`;return`Virheellinen ${J[I.format]??q.format}`}case"not_multiple_of":return`Virheellinen luku: t\xE4ytyy olla luvun ${q.divisor} monikerta`;case"unrecognized_keys":return`${q.keys.length>1?"Tuntemattomat avaimet":"Tuntematon avain"}: ${n(q.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"}}};var bz=O$(()=>{g$()});function Q1(){return{localeError:qu()}}var qu=()=>{let $={string:{unit:"caract\xE8res",verb:"avoir"},file:{unit:"octets",verb:"avoir"},array:{unit:"\xE9l\xE9ments",verb:"avoir"},set:{unit:"\xE9l\xE9ments",verb:"avoir"}};function U(q){return $[q]??null}let J={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"},G={string:"cha\xEEne",number:"nombre",int:"entier",boolean:"bool\xE9en",bigint:"grand entier",symbol:"symbole",undefined:"ind\xE9fini",null:"null",never:"jamais",void:"vide",date:"date",array:"tableau",object:"objet",tuple:"tuple",record:"enregistrement",map:"carte",set:"ensemble",file:"fichier",nonoptional:"non-optionnel",nan:"NaN",function:"fonction"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Entr\xE9e invalide : instanceof ${q.expected} attendu, ${D} re\xE7u`;return`Entr\xE9e invalide : ${I} attendu, ${D} re\xE7u`}case"invalid_value":if(q.values.length===1)return`Entr\xE9e invalide : ${Q$(q.values[0])} attendu`;return`Option invalide : une valeur parmi ${n(q.values,"|")} attendue`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`Trop grand : ${G[q.origin]??"valeur"} doit ${Q.verb} ${I}${q.maximum.toString()} ${Q.unit??"\xE9l\xE9ment(s)"}`;return`Trop grand : ${G[q.origin]??"valeur"} doit \xEAtre ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`Trop petit : ${G[q.origin]??"valeur"} doit ${Q.verb} ${I}${q.minimum.toString()} ${Q.unit}`;return`Trop petit : ${G[q.origin]??"valeur"} doit \xEAtre ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Cha\xEEne invalide : doit commencer par "${I.prefix}"`;if(I.format==="ends_with")return`Cha\xEEne invalide : doit se terminer par "${I.suffix}"`;if(I.format==="includes")return`Cha\xEEne invalide : doit inclure "${I.includes}"`;if(I.format==="regex")return`Cha\xEEne invalide : doit correspondre au mod\xE8le ${I.pattern}`;return`${J[I.format]??q.format} invalide`}case"not_multiple_of":return`Nombre invalide : doit \xEAtre un multiple de ${q.divisor}`;case"unrecognized_keys":return`Cl\xE9${q.keys.length>1?"s":""} non reconnue${q.keys.length>1?"s":""} : ${n(q.keys,", ")}`;case"invalid_key":return`Cl\xE9 invalide dans ${q.origin}`;case"invalid_union":return"Entr\xE9e invalide";case"invalid_element":return`Valeur invalide dans ${q.origin}`;default:return"Entr\xE9e invalide"}}};var uz=O$(()=>{g$()});function D1(){return{localeError:Gu()}}var Gu=()=>{let $={string:{unit:"caract\xE8res",verb:"avoir"},file:{unit:"octets",verb:"avoir"},array:{unit:"\xE9l\xE9ments",verb:"avoir"},set:{unit:"\xE9l\xE9ments",verb:"avoir"}};function U(q){return $[q]??null}let J={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"},G={nan:"NaN"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Entr\xE9e invalide : attendu instanceof ${q.expected}, re\xE7u ${D}`;return`Entr\xE9e invalide : attendu ${I}, re\xE7u ${D}`}case"invalid_value":if(q.values.length===1)return`Entr\xE9e invalide : attendu ${Q$(q.values[0])}`;return`Option invalide : attendu l'une des valeurs suivantes ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"\u2264":"<",Q=U(q.origin);if(Q)return`Trop grand : attendu que ${q.origin??"la valeur"} ait ${I}${q.maximum.toString()} ${Q.unit}`;return`Trop grand : attendu que ${q.origin??"la valeur"} soit ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?"\u2265":">",Q=U(q.origin);if(Q)return`Trop petit : attendu que ${q.origin} ait ${I}${q.minimum.toString()} ${Q.unit}`;return`Trop petit : attendu que ${q.origin} soit ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Cha\xEEne invalide : doit commencer par "${I.prefix}"`;if(I.format==="ends_with")return`Cha\xEEne invalide : doit se terminer par "${I.suffix}"`;if(I.format==="includes")return`Cha\xEEne invalide : doit inclure "${I.includes}"`;if(I.format==="regex")return`Cha\xEEne invalide : doit correspondre au motif ${I.pattern}`;return`${J[I.format]??q.format} invalide`}case"not_multiple_of":return`Nombre invalide : doit \xEAtre un multiple de ${q.divisor}`;case"unrecognized_keys":return`Cl\xE9${q.keys.length>1?"s":""} non reconnue${q.keys.length>1?"s":""} : ${n(q.keys,", ")}`;case"invalid_key":return`Cl\xE9 invalide dans ${q.origin}`;case"invalid_union":return"Entr\xE9e invalide";case"invalid_element":return`Valeur invalide dans ${q.origin}`;default:return"Entr\xE9e invalide"}}};var kz=O$(()=>{g$()});function X1(){return{localeError:Iu()}}var Iu=()=>{let $={string:{label:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA",gender:"f"},number:{label:"\u05DE\u05E1\u05E4\u05E8",gender:"m"},boolean:{label:"\u05E2\u05E8\u05DA \u05D1\u05D5\u05DC\u05D9\u05D0\u05E0\u05D9",gender:"m"},bigint:{label:"BigInt",gender:"m"},date:{label:"\u05EA\u05D0\u05E8\u05D9\u05DA",gender:"m"},array:{label:"\u05DE\u05E2\u05E8\u05DA",gender:"m"},object:{label:"\u05D0\u05D5\u05D1\u05D9\u05D9\u05E7\u05D8",gender:"m"},null:{label:"\u05E2\u05E8\u05DA \u05E8\u05D9\u05E7 (null)",gender:"m"},undefined:{label:"\u05E2\u05E8\u05DA \u05DC\u05D0 \u05DE\u05D5\u05D2\u05D3\u05E8 (undefined)",gender:"m"},symbol:{label:"\u05E1\u05D9\u05DE\u05D1\u05D5\u05DC (Symbol)",gender:"m"},function:{label:"\u05E4\u05D5\u05E0\u05E7\u05E6\u05D9\u05D4",gender:"f"},map:{label:"\u05DE\u05E4\u05D4 (Map)",gender:"f"},set:{label:"\u05E7\u05D1\u05D5\u05E6\u05D4 (Set)",gender:"f"},file:{label:"\u05E7\u05D5\u05D1\u05E5",gender:"m"},promise:{label:"Promise",gender:"m"},NaN:{label:"NaN",gender:"m"},unknown:{label:"\u05E2\u05E8\u05DA \u05DC\u05D0 \u05D9\u05D3\u05D5\u05E2",gender:"m"},value:{label:"\u05E2\u05E8\u05DA",gender:"m"}},U={string:{unit:"\u05EA\u05D5\u05D5\u05D9\u05DD",shortLabel:"\u05E7\u05E6\u05E8",longLabel:"\u05D0\u05E8\u05D5\u05DA"},file:{unit:"\u05D1\u05D9\u05D9\u05D8\u05D9\u05DD",shortLabel:"\u05E7\u05D8\u05DF",longLabel:"\u05D2\u05D3\u05D5\u05DC"},array:{unit:"\u05E4\u05E8\u05D9\u05D8\u05D9\u05DD",shortLabel:"\u05E7\u05D8\u05DF",longLabel:"\u05D2\u05D3\u05D5\u05DC"},set:{unit:"\u05E4\u05E8\u05D9\u05D8\u05D9\u05DD",shortLabel:"\u05E7\u05D8\u05DF",longLabel:"\u05D2\u05D3\u05D5\u05DC"},number:{unit:"",shortLabel:"\u05E7\u05D8\u05DF",longLabel:"\u05D2\u05D3\u05D5\u05DC"}},J=(Y)=>Y?$[Y]:void 0,G=(Y)=>{let V=J(Y);if(V)return V.label;return Y??$.unknown.label},q=(Y)=>`\u05D4${G(Y)}`,I=(Y)=>{return(J(Y)?.gender??"m")==="f"?"\u05E6\u05E8\u05D9\u05DB\u05D4 \u05DC\u05D4\u05D9\u05D5\u05EA":"\u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA"},Q=(Y)=>{if(!Y)return null;return U[Y]??null},D={regex:{label:"\u05E7\u05DC\u05D8",gender:"m"},email:{label:"\u05DB\u05EA\u05D5\u05D1\u05EA \u05D0\u05D9\u05DE\u05D9\u05D9\u05DC",gender:"f"},url:{label:"\u05DB\u05EA\u05D5\u05D1\u05EA \u05E8\u05E9\u05EA",gender:"f"},emoji:{label:"\u05D0\u05D9\u05DE\u05D5\u05D2'\u05D9",gender:"m"},uuid:{label:"UUID",gender:"m"},nanoid:{label:"nanoid",gender:"m"},guid:{label:"GUID",gender:"m"},cuid:{label:"cuid",gender:"m"},cuid2:{label:"cuid2",gender:"m"},ulid:{label:"ULID",gender:"m"},xid:{label:"XID",gender:"m"},ksuid:{label:"KSUID",gender:"m"},datetime:{label:"\u05EA\u05D0\u05E8\u05D9\u05DA \u05D5\u05D6\u05DE\u05DF ISO",gender:"m"},date:{label:"\u05EA\u05D0\u05E8\u05D9\u05DA ISO",gender:"m"},time:{label:"\u05D6\u05DE\u05DF ISO",gender:"m"},duration:{label:"\u05DE\u05E9\u05DA \u05D6\u05DE\u05DF ISO",gender:"m"},ipv4:{label:"\u05DB\u05EA\u05D5\u05D1\u05EA IPv4",gender:"f"},ipv6:{label:"\u05DB\u05EA\u05D5\u05D1\u05EA IPv6",gender:"f"},cidrv4:{label:"\u05D8\u05D5\u05D5\u05D7 IPv4",gender:"m"},cidrv6:{label:"\u05D8\u05D5\u05D5\u05D7 IPv6",gender:"m"},base64:{label:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D1\u05D1\u05E1\u05D9\u05E1 64",gender:"f"},base64url:{label:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D1\u05D1\u05E1\u05D9\u05E1 64 \u05DC\u05DB\u05EA\u05D5\u05D1\u05D5\u05EA \u05E8\u05E9\u05EA",gender:"f"},json_string:{label:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA JSON",gender:"f"},e164:{label:"\u05DE\u05E1\u05E4\u05E8 E.164",gender:"m"},jwt:{label:"JWT",gender:"m"},ends_with:{label:"\u05E7\u05DC\u05D8",gender:"m"},includes:{label:"\u05E7\u05DC\u05D8",gender:"m"},lowercase:{label:"\u05E7\u05DC\u05D8",gender:"m"},starts_with:{label:"\u05E7\u05DC\u05D8",gender:"m"},uppercase:{label:"\u05E7\u05DC\u05D8",gender:"m"}},X={nan:"NaN"};return(Y)=>{switch(Y.code){case"invalid_type":{let V=Y.expected,W=X[V??""]??G(V),O=X$(Y.input),Z=X[O]??$[O]?.label??O;if(/^[A-Z]/.test(Y.expected))return`\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA instanceof ${Y.expected}, \u05D4\u05EA\u05E7\u05D1\u05DC ${Z}`;return`\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${W}, \u05D4\u05EA\u05E7\u05D1\u05DC ${Z}`}case"invalid_value":{if(Y.values.length===1)return`\u05E2\u05E8\u05DA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05D4\u05E2\u05E8\u05DA \u05D7\u05D9\u05D9\u05D1 \u05DC\u05D4\u05D9\u05D5\u05EA ${Q$(Y.values[0])}`;let V=Y.values.map((Z)=>Q$(Z));if(Y.values.length===2)return`\u05E2\u05E8\u05DA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05D4\u05D0\u05E4\u05E9\u05E8\u05D5\u05D9\u05D5\u05EA \u05D4\u05DE\u05EA\u05D0\u05D9\u05DE\u05D5\u05EA \u05D4\u05DF ${V[0]} \u05D0\u05D5 ${V[1]}`;let W=V[V.length-1];return`\u05E2\u05E8\u05DA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05D4\u05D0\u05E4\u05E9\u05E8\u05D5\u05D9\u05D5\u05EA \u05D4\u05DE\u05EA\u05D0\u05D9\u05DE\u05D5\u05EA \u05D4\u05DF ${V.slice(0,-1).join(", ")} \u05D0\u05D5 ${W}`}case"too_big":{let V=Q(Y.origin),W=q(Y.origin??"value");if(Y.origin==="string")return`${V?.longLabel??"\u05D0\u05E8\u05D5\u05DA"} \u05DE\u05D3\u05D9: ${W} \u05E6\u05E8\u05D9\u05DB\u05D4 \u05DC\u05D4\u05DB\u05D9\u05DC ${Y.maximum.toString()} ${V?.unit??""} ${Y.inclusive?"\u05D0\u05D5 \u05E4\u05D7\u05D5\u05EA":"\u05DC\u05DB\u05DC \u05D4\u05D9\u05D5\u05EA\u05E8"}`.trim();if(Y.origin==="number"){let M=Y.inclusive?`\u05E7\u05D8\u05DF \u05D0\u05D5 \u05E9\u05D5\u05D5\u05D4 \u05DC-${Y.maximum}`:`\u05E7\u05D8\u05DF \u05DE-${Y.maximum}`;return`\u05D2\u05D3\u05D5\u05DC \u05DE\u05D3\u05D9: ${W} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${M}`}if(Y.origin==="array"||Y.origin==="set"){let M=Y.origin==="set"?"\u05E6\u05E8\u05D9\u05DB\u05D4":"\u05E6\u05E8\u05D9\u05DA",w=Y.inclusive?`${Y.maximum} ${V?.unit??""} \u05D0\u05D5 \u05E4\u05D7\u05D5\u05EA`:`\u05E4\u05D7\u05D5\u05EA \u05DE-${Y.maximum} ${V?.unit??""}`;return`\u05D2\u05D3\u05D5\u05DC \u05DE\u05D3\u05D9: ${W} ${M} \u05DC\u05D4\u05DB\u05D9\u05DC ${w}`.trim()}let O=Y.inclusive?"<=":"<",Z=I(Y.origin??"value");if(V?.unit)return`${V.longLabel} \u05DE\u05D3\u05D9: ${W} ${Z} ${O}${Y.maximum.toString()} ${V.unit}`;return`${V?.longLabel??"\u05D2\u05D3\u05D5\u05DC"} \u05DE\u05D3\u05D9: ${W} ${Z} ${O}${Y.maximum.toString()}`}case"too_small":{let V=Q(Y.origin),W=q(Y.origin??"value");if(Y.origin==="string")return`${V?.shortLabel??"\u05E7\u05E6\u05E8"} \u05DE\u05D3\u05D9: ${W} \u05E6\u05E8\u05D9\u05DB\u05D4 \u05DC\u05D4\u05DB\u05D9\u05DC ${Y.minimum.toString()} ${V?.unit??""} ${Y.inclusive?"\u05D0\u05D5 \u05D9\u05D5\u05EA\u05E8":"\u05DC\u05E4\u05D7\u05D5\u05EA"}`.trim();if(Y.origin==="number"){let M=Y.inclusive?`\u05D2\u05D3\u05D5\u05DC \u05D0\u05D5 \u05E9\u05D5\u05D5\u05D4 \u05DC-${Y.minimum}`:`\u05D2\u05D3\u05D5\u05DC \u05DE-${Y.minimum}`;return`\u05E7\u05D8\u05DF \u05DE\u05D3\u05D9: ${W} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${M}`}if(Y.origin==="array"||Y.origin==="set"){let M=Y.origin==="set"?"\u05E6\u05E8\u05D9\u05DB\u05D4":"\u05E6\u05E8\u05D9\u05DA";if(Y.minimum===1&&Y.inclusive){let H=Y.origin==="set"?"\u05DC\u05E4\u05D7\u05D5\u05EA \u05E4\u05E8\u05D9\u05D8 \u05D0\u05D7\u05D3":"\u05DC\u05E4\u05D7\u05D5\u05EA \u05E4\u05E8\u05D9\u05D8 \u05D0\u05D7\u05D3";return`\u05E7\u05D8\u05DF \u05DE\u05D3\u05D9: ${W} ${M} \u05DC\u05D4\u05DB\u05D9\u05DC ${H}`}let w=Y.inclusive?`${Y.minimum} ${V?.unit??""} \u05D0\u05D5 \u05D9\u05D5\u05EA\u05E8`:`\u05D9\u05D5\u05EA\u05E8 \u05DE-${Y.minimum} ${V?.unit??""}`;return`\u05E7\u05D8\u05DF \u05DE\u05D3\u05D9: ${W} ${M} \u05DC\u05D4\u05DB\u05D9\u05DC ${w}`.trim()}let O=Y.inclusive?">=":">",Z=I(Y.origin??"value");if(V?.unit)return`${V.shortLabel} \u05DE\u05D3\u05D9: ${W} ${Z} ${O}${Y.minimum.toString()} ${V.unit}`;return`${V?.shortLabel??"\u05E7\u05D8\u05DF"} \u05DE\u05D3\u05D9: ${W} ${Z} ${O}${Y.minimum.toString()}`}case"invalid_format":{let V=Y;if(V.format==="starts_with")return`\u05D4\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05EA\u05D7\u05D9\u05DC \u05D1 "${V.prefix}"`;if(V.format==="ends_with")return`\u05D4\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05E1\u05EA\u05D9\u05D9\u05DD \u05D1 "${V.suffix}"`;if(V.format==="includes")return`\u05D4\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05DB\u05DC\u05D5\u05DC "${V.includes}"`;if(V.format==="regex")return`\u05D4\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05EA\u05D0\u05D9\u05DD \u05DC\u05EA\u05D1\u05E0\u05D9\u05EA ${V.pattern}`;let W=D[V.format],O=W?.label??V.format,M=(W?.gender??"m")==="f"?"\u05EA\u05E7\u05D9\u05E0\u05D4":"\u05EA\u05E7\u05D9\u05DF";return`${O} \u05DC\u05D0 ${M}`}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 ${Y.divisor}`;case"unrecognized_keys":return`\u05DE\u05E4\u05EA\u05D7${Y.keys.length>1?"\u05D5\u05EA":""} \u05DC\u05D0 \u05DE\u05D6\u05D5\u05D4${Y.keys.length>1?"\u05D9\u05DD":"\u05D4"}: ${n(Y.keys,", ")}`;case"invalid_key":return"\u05E9\u05D3\u05D4 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF \u05D1\u05D0\u05D5\u05D1\u05D9\u05D9\u05E7\u05D8";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${q(Y.origin??"array")}`;default:return"\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF"}}};var xz=O$(()=>{g$()});function Y1(){return{localeError:Qu()}}var Qu=()=>{let $={string:{unit:"znakova",verb:"imati"},file:{unit:"bajtova",verb:"imati"},array:{unit:"stavki",verb:"imati"},set:{unit:"stavki",verb:"imati"}};function U(q){return $[q]??null}let J={regex:"unos",email:"email 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:"ISO datum i vrijeme",date:"ISO datum",time:"ISO vrijeme",duration:"ISO trajanje",ipv4:"IPv4 adresa",ipv6:"IPv6 adresa",cidrv4:"IPv4 raspon",cidrv6:"IPv6 raspon",base64:"base64 kodirani tekst",base64url:"base64url kodirani tekst",json_string:"JSON tekst",e164:"E.164 broj",jwt:"JWT",template_literal:"unos"},G={nan:"NaN",string:"tekst",number:"broj",boolean:"boolean",array:"niz",object:"objekt",set:"skup",file:"datoteka",date:"datum",bigint:"bigint",symbol:"simbol",undefined:"undefined",null:"null",function:"funkcija",map:"mapa"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Neispravan unos: o\u010Dekuje se instanceof ${q.expected}, a primljeno je ${D}`;return`Neispravan unos: o\u010Dekuje se ${I}, a primljeno je ${D}`}case"invalid_value":if(q.values.length===1)return`Neispravna vrijednost: o\u010Dekivano ${Q$(q.values[0])}`;return`Neispravna opcija: o\u010Dekivano jedno od ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin),D=G[q.origin]??q.origin;if(Q)return`Preveliko: o\u010Dekivano da ${D??"vrijednost"} ima ${I}${q.maximum.toString()} ${Q.unit??"elemenata"}`;return`Preveliko: o\u010Dekivano da ${D??"vrijednost"} bude ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin),D=G[q.origin]??q.origin;if(Q)return`Premalo: o\u010Dekivano da ${D} ima ${I}${q.minimum.toString()} ${Q.unit}`;return`Premalo: o\u010Dekivano da ${D} bude ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Neispravan tekst: mora zapo\u010Dinjati s "${I.prefix}"`;if(I.format==="ends_with")return`Neispravan tekst: mora zavr\u0161avati s "${I.suffix}"`;if(I.format==="includes")return`Neispravan tekst: mora sadr\u017Eavati "${I.includes}"`;if(I.format==="regex")return`Neispravan tekst: mora odgovarati uzorku ${I.pattern}`;return`Neispravna ${J[I.format]??q.format}`}case"not_multiple_of":return`Neispravan broj: mora biti vi\u0161ekratnik od ${q.divisor}`;case"unrecognized_keys":return`Neprepoznat${q.keys.length>1?"i klju\u010Devi":" klju\u010D"}: ${n(q.keys,", ")}`;case"invalid_key":return`Neispravan klju\u010D u ${G[q.origin]??q.origin}`;case"invalid_union":return"Neispravan unos";case"invalid_element":return`Neispravna vrijednost u ${G[q.origin]??q.origin}`;default:return"Neispravan unos"}}};var fz=O$(()=>{g$()});function V1(){return{localeError:Du()}}var Du=()=>{let $={string:{unit:"karakter",verb:"legyen"},file:{unit:"byte",verb:"legyen"},array:{unit:"elem",verb:"legyen"},set:{unit:"elem",verb:"legyen"}};function U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"sz\xE1m",array:"t\xF6mb"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`\xC9rv\xE9nytelen bemenet: a v\xE1rt \xE9rt\xE9k instanceof ${q.expected}, a kapott \xE9rt\xE9k ${D}`;return`\xC9rv\xE9nytelen bemenet: a v\xE1rt \xE9rt\xE9k ${I}, a kapott \xE9rt\xE9k ${D}`}case"invalid_value":if(q.values.length===1)return`\xC9rv\xE9nytelen bemenet: a v\xE1rt \xE9rt\xE9k ${Q$(q.values[0])}`;return`\xC9rv\xE9nytelen opci\xF3: valamelyik \xE9rt\xE9k v\xE1rt ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`T\xFAl nagy: ${q.origin??"\xE9rt\xE9k"} m\xE9rete t\xFAl nagy ${I}${q.maximum.toString()} ${Q.unit??"elem"}`;return`T\xFAl nagy: a bemeneti \xE9rt\xE9k ${q.origin??"\xE9rt\xE9k"} t\xFAl nagy: ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`T\xFAl kicsi: a bemeneti \xE9rt\xE9k ${q.origin} m\xE9rete t\xFAl kicsi ${I}${q.minimum.toString()} ${Q.unit}`;return`T\xFAl kicsi: a bemeneti \xE9rt\xE9k ${q.origin} t\xFAl kicsi ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\xC9rv\xE9nytelen string: "${I.prefix}" \xE9rt\xE9kkel kell kezd\u0151dnie`;if(I.format==="ends_with")return`\xC9rv\xE9nytelen string: "${I.suffix}" \xE9rt\xE9kkel kell v\xE9gz\u0151dnie`;if(I.format==="includes")return`\xC9rv\xE9nytelen string: "${I.includes}" \xE9rt\xE9ket kell tartalmaznia`;if(I.format==="regex")return`\xC9rv\xE9nytelen string: ${I.pattern} mint\xE1nak kell megfelelnie`;return`\xC9rv\xE9nytelen ${J[I.format]??q.format}`}case"not_multiple_of":return`\xC9rv\xE9nytelen sz\xE1m: ${q.divisor} t\xF6bbsz\xF6r\xF6s\xE9nek kell lennie`;case"unrecognized_keys":return`Ismeretlen kulcs${q.keys.length>1?"s":""}: ${n(q.keys,", ")}`;case"invalid_key":return`\xC9rv\xE9nytelen kulcs ${q.origin}`;case"invalid_union":return"\xC9rv\xE9nytelen bemenet";case"invalid_element":return`\xC9rv\xE9nytelen \xE9rt\xE9k: ${q.origin}`;default:return"\xC9rv\xE9nytelen bemenet"}}};var yz=O$(()=>{g$()});function mz($,U,J){return Math.abs($)===1?U:J}function U8($){if(!$)return"";let U=["\u0561","\u0565","\u0568","\u056B","\u0578","\u0578\u0582","\u0585"],J=$[$.length-1];return $+(U.includes(J)?"\u0576":"\u0568")}function W1(){return{localeError:Xu()}}var Xu=()=>{let $={string:{unit:{one:"\u0576\u0577\u0561\u0576",many:"\u0576\u0577\u0561\u0576\u0576\u0565\u0580"},verb:"\u0578\u0582\u0576\u0565\u0576\u0561\u056C"},file:{unit:{one:"\u0562\u0561\u0575\u0569",many:"\u0562\u0561\u0575\u0569\u0565\u0580"},verb:"\u0578\u0582\u0576\u0565\u0576\u0561\u056C"},array:{unit:{one:"\u057F\u0561\u0580\u0580",many:"\u057F\u0561\u0580\u0580\u0565\u0580"},verb:"\u0578\u0582\u0576\u0565\u0576\u0561\u056C"},set:{unit:{one:"\u057F\u0561\u0580\u0580",many:"\u057F\u0561\u0580\u0580\u0565\u0580"},verb:"\u0578\u0582\u0576\u0565\u0576\u0561\u056C"}};function U(q){return $[q]??null}let J={regex:"\u0574\u0578\u0582\u057F\u0584",email:"\u0567\u056C. \u0570\u0561\u057D\u0581\u0565",url:"URL",emoji:"\u0567\u0574\u0578\u057B\u056B",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0561\u0574\u057D\u0561\u0569\u056B\u057E \u0587 \u056A\u0561\u0574",date:"ISO \u0561\u0574\u057D\u0561\u0569\u056B\u057E",time:"ISO \u056A\u0561\u0574",duration:"ISO \u057F\u0587\u0578\u0572\u0578\u0582\u0569\u0575\u0578\u0582\u0576",ipv4:"IPv4 \u0570\u0561\u057D\u0581\u0565",ipv6:"IPv6 \u0570\u0561\u057D\u0581\u0565",cidrv4:"IPv4 \u0574\u056B\u057B\u0561\u056F\u0561\u0575\u0584",cidrv6:"IPv6 \u0574\u056B\u057B\u0561\u056F\u0561\u0575\u0584",base64:"base64 \u0571\u0587\u0561\u0579\u0561\u0583\u0578\u057E \u057F\u0578\u0572",base64url:"base64url \u0571\u0587\u0561\u0579\u0561\u0583\u0578\u057E \u057F\u0578\u0572",json_string:"JSON \u057F\u0578\u0572",e164:"E.164 \u0570\u0561\u0574\u0561\u0580",jwt:"JWT",template_literal:"\u0574\u0578\u0582\u057F\u0584"},G={nan:"NaN",number:"\u0569\u056B\u057E",array:"\u0566\u0561\u0576\u0563\u057E\u0561\u056E"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`\u054D\u056D\u0561\u056C \u0574\u0578\u0582\u057F\u0584\u0561\u0563\u0580\u0578\u0582\u0574\u2024 \u057D\u057A\u0561\u057D\u057E\u0578\u0582\u0574 \u0567\u0580 instanceof ${q.expected}, \u057D\u057F\u0561\u0581\u057E\u0565\u056C \u0567 ${D}`;return`\u054D\u056D\u0561\u056C \u0574\u0578\u0582\u057F\u0584\u0561\u0563\u0580\u0578\u0582\u0574\u2024 \u057D\u057A\u0561\u057D\u057E\u0578\u0582\u0574 \u0567\u0580 ${I}, \u057D\u057F\u0561\u0581\u057E\u0565\u056C \u0567 ${D}`}case"invalid_value":if(q.values.length===1)return`\u054D\u056D\u0561\u056C \u0574\u0578\u0582\u057F\u0584\u0561\u0563\u0580\u0578\u0582\u0574\u2024 \u057D\u057A\u0561\u057D\u057E\u0578\u0582\u0574 \u0567\u0580 ${Q$(q.values[1])}`;return`\u054D\u056D\u0561\u056C \u057F\u0561\u0580\u0562\u0565\u0580\u0561\u056F\u2024 \u057D\u057A\u0561\u057D\u057E\u0578\u0582\u0574 \u0567\u0580 \u0570\u0565\u057F\u0587\u0575\u0561\u056C\u0576\u0565\u0580\u056B\u0581 \u0574\u0565\u056F\u0568\u055D ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q){let D=Number(q.maximum),X=mz(D,Q.unit.one,Q.unit.many);return`\u0549\u0561\u0583\u0561\u0566\u0561\u0576\u0581 \u0574\u0565\u056E \u0561\u0580\u056A\u0565\u0584\u2024 \u057D\u057A\u0561\u057D\u057E\u0578\u0582\u0574 \u0567, \u0578\u0580 ${U8(q.origin??"\u0561\u0580\u056A\u0565\u0584")} \u056F\u0578\u0582\u0576\u0565\u0576\u0561 ${I}${q.maximum.toString()} ${X}`}return`\u0549\u0561\u0583\u0561\u0566\u0561\u0576\u0581 \u0574\u0565\u056E \u0561\u0580\u056A\u0565\u0584\u2024 \u057D\u057A\u0561\u057D\u057E\u0578\u0582\u0574 \u0567, \u0578\u0580 ${U8(q.origin??"\u0561\u0580\u056A\u0565\u0584")} \u056C\u056B\u0576\u056B ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q){let D=Number(q.minimum),X=mz(D,Q.unit.one,Q.unit.many);return`\u0549\u0561\u0583\u0561\u0566\u0561\u0576\u0581 \u0583\u0578\u0584\u0580 \u0561\u0580\u056A\u0565\u0584\u2024 \u057D\u057A\u0561\u057D\u057E\u0578\u0582\u0574 \u0567, \u0578\u0580 ${U8(q.origin)} \u056F\u0578\u0582\u0576\u0565\u0576\u0561 ${I}${q.minimum.toString()} ${X}`}return`\u0549\u0561\u0583\u0561\u0566\u0561\u0576\u0581 \u0583\u0578\u0584\u0580 \u0561\u0580\u056A\u0565\u0584\u2024 \u057D\u057A\u0561\u057D\u057E\u0578\u0582\u0574 \u0567, \u0578\u0580 ${U8(q.origin)} \u056C\u056B\u0576\u056B ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\u054D\u056D\u0561\u056C \u057F\u0578\u0572\u2024 \u057A\u0565\u057F\u0584 \u0567 \u057D\u056F\u057D\u057E\u056B "${I.prefix}"-\u0578\u057E`;if(I.format==="ends_with")return`\u054D\u056D\u0561\u056C \u057F\u0578\u0572\u2024 \u057A\u0565\u057F\u0584 \u0567 \u0561\u057E\u0561\u0580\u057F\u057E\u056B "${I.suffix}"-\u0578\u057E`;if(I.format==="includes")return`\u054D\u056D\u0561\u056C \u057F\u0578\u0572\u2024 \u057A\u0565\u057F\u0584 \u0567 \u057A\u0561\u0580\u0578\u0582\u0576\u0561\u056F\u056B "${I.includes}"`;if(I.format==="regex")return`\u054D\u056D\u0561\u056C \u057F\u0578\u0572\u2024 \u057A\u0565\u057F\u0584 \u0567 \u0570\u0561\u0574\u0561\u057A\u0561\u057F\u0561\u057D\u056D\u0561\u0576\u056B ${I.pattern} \u0571\u0587\u0561\u0579\u0561\u0583\u056B\u0576`;return`\u054D\u056D\u0561\u056C ${J[I.format]??q.format}`}case"not_multiple_of":return`\u054D\u056D\u0561\u056C \u0569\u056B\u057E\u2024 \u057A\u0565\u057F\u0584 \u0567 \u0562\u0561\u0566\u0574\u0561\u057A\u0561\u057F\u056B\u056F \u056C\u056B\u0576\u056B ${q.divisor}-\u056B`;case"unrecognized_keys":return`\u0549\u0573\u0561\u0576\u0561\u0579\u057E\u0561\u056E \u0562\u0561\u0576\u0561\u056C\u056B${q.keys.length>1?"\u0576\u0565\u0580":""}. ${n(q.keys,", ")}`;case"invalid_key":return`\u054D\u056D\u0561\u056C \u0562\u0561\u0576\u0561\u056C\u056B ${U8(q.origin)}-\u0578\u0582\u0574`;case"invalid_union":return"\u054D\u056D\u0561\u056C \u0574\u0578\u0582\u057F\u0584\u0561\u0563\u0580\u0578\u0582\u0574";case"invalid_element":return`\u054D\u056D\u0561\u056C \u0561\u0580\u056A\u0565\u0584 ${U8(q.origin)}-\u0578\u0582\u0574`;default:return"\u054D\u056D\u0561\u056C \u0574\u0578\u0582\u057F\u0584\u0561\u0563\u0580\u0578\u0582\u0574"}}};var hz=O$(()=>{g$()});function O1(){return{localeError:Yu()}}var Yu=()=>{let $={string:{unit:"karakter",verb:"memiliki"},file:{unit:"byte",verb:"memiliki"},array:{unit:"item",verb:"memiliki"},set:{unit:"item",verb:"memiliki"}};function U(q){return $[q]??null}let J={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"},G={nan:"NaN"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Input tidak valid: diharapkan instanceof ${q.expected}, diterima ${D}`;return`Input tidak valid: diharapkan ${I}, diterima ${D}`}case"invalid_value":if(q.values.length===1)return`Input tidak valid: diharapkan ${Q$(q.values[0])}`;return`Pilihan tidak valid: diharapkan salah satu dari ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`Terlalu besar: diharapkan ${q.origin??"value"} memiliki ${I}${q.maximum.toString()} ${Q.unit??"elemen"}`;return`Terlalu besar: diharapkan ${q.origin??"value"} menjadi ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`Terlalu kecil: diharapkan ${q.origin} memiliki ${I}${q.minimum.toString()} ${Q.unit}`;return`Terlalu kecil: diharapkan ${q.origin} menjadi ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`String tidak valid: harus dimulai dengan "${I.prefix}"`;if(I.format==="ends_with")return`String tidak valid: harus berakhir dengan "${I.suffix}"`;if(I.format==="includes")return`String tidak valid: harus menyertakan "${I.includes}"`;if(I.format==="regex")return`String tidak valid: harus sesuai pola ${I.pattern}`;return`${J[I.format]??q.format} tidak valid`}case"not_multiple_of":return`Angka tidak valid: harus kelipatan dari ${q.divisor}`;case"unrecognized_keys":return`Kunci tidak dikenali ${q.keys.length>1?"s":""}: ${n(q.keys,", ")}`;case"invalid_key":return`Kunci tidak valid di ${q.origin}`;case"invalid_union":return"Input tidak valid";case"invalid_element":return`Nilai tidak valid di ${q.origin}`;default:return"Input tidak valid"}}};var rz=O$(()=>{g$()});function Z1(){return{localeError:Vu()}}var Vu=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"n\xFAmer",array:"fylki"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Rangt gildi: \xDE\xFA sl\xF3st inn ${D} \xFEar sem \xE1 a\xF0 vera instanceof ${q.expected}`;return`Rangt gildi: \xDE\xFA sl\xF3st inn ${D} \xFEar sem \xE1 a\xF0 vera ${I}`}case"invalid_value":if(q.values.length===1)return`Rangt gildi: gert r\xE1\xF0 fyrir ${Q$(q.values[0])}`;return`\xD3gilt val: m\xE1 vera eitt af eftirfarandi ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`Of st\xF3rt: gert er r\xE1\xF0 fyrir a\xF0 ${q.origin??"gildi"} hafi ${I}${q.maximum.toString()} ${Q.unit??"hluti"}`;return`Of st\xF3rt: gert er r\xE1\xF0 fyrir a\xF0 ${q.origin??"gildi"} s\xE9 ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`Of l\xEDti\xF0: gert er r\xE1\xF0 fyrir a\xF0 ${q.origin} hafi ${I}${q.minimum.toString()} ${Q.unit}`;return`Of l\xEDti\xF0: gert er r\xE1\xF0 fyrir a\xF0 ${q.origin} s\xE9 ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\xD3gildur strengur: ver\xF0ur a\xF0 byrja \xE1 "${I.prefix}"`;if(I.format==="ends_with")return`\xD3gildur strengur: ver\xF0ur a\xF0 enda \xE1 "${I.suffix}"`;if(I.format==="includes")return`\xD3gildur strengur: ver\xF0ur a\xF0 innihalda "${I.includes}"`;if(I.format==="regex")return`\xD3gildur strengur: ver\xF0ur a\xF0 fylgja mynstri ${I.pattern}`;return`Rangt ${J[I.format]??q.format}`}case"not_multiple_of":return`R\xF6ng tala: ver\xF0ur a\xF0 vera margfeldi af ${q.divisor}`;case"unrecognized_keys":return`\xD3\xFEekkt ${q.keys.length>1?"ir lyklar":"ur lykill"}: ${n(q.keys,", ")}`;case"invalid_key":return`Rangur lykill \xED ${q.origin}`;case"invalid_union":return"Rangt gildi";case"invalid_element":return`Rangt gildi \xED ${q.origin}`;default:return"Rangt gildi"}}};var lz=O$(()=>{g$()});function R1(){return{localeError:Wu()}}var Wu=()=>{let $={string:{unit:"caratteri",verb:"avere"},file:{unit:"byte",verb:"avere"},array:{unit:"elementi",verb:"avere"},set:{unit:"elementi",verb:"avere"}};function U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"numero",array:"vettore"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Input non valido: atteso instanceof ${q.expected}, ricevuto ${D}`;return`Input non valido: atteso ${I}, ricevuto ${D}`}case"invalid_value":if(q.values.length===1)return`Input non valido: atteso ${Q$(q.values[0])}`;return`Opzione non valida: atteso uno tra ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`Troppo grande: ${q.origin??"valore"} deve avere ${I}${q.maximum.toString()} ${Q.unit??"elementi"}`;return`Troppo grande: ${q.origin??"valore"} deve essere ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`Troppo piccolo: ${q.origin} deve avere ${I}${q.minimum.toString()} ${Q.unit}`;return`Troppo piccolo: ${q.origin} deve essere ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Stringa non valida: deve iniziare con "${I.prefix}"`;if(I.format==="ends_with")return`Stringa non valida: deve terminare con "${I.suffix}"`;if(I.format==="includes")return`Stringa non valida: deve includere "${I.includes}"`;if(I.format==="regex")return`Stringa non valida: deve corrispondere al pattern ${I.pattern}`;return`Input non valido: ${J[I.format]??q.format}`}case"not_multiple_of":return`Numero non valido: deve essere un multiplo di ${q.divisor}`;case"unrecognized_keys":return`Chiav${q.keys.length>1?"i":"e"} non riconosciut${q.keys.length>1?"e":"a"}: ${n(q.keys,", ")}`;case"invalid_key":return`Chiave non valida in ${q.origin}`;case"invalid_union":return"Input non valido";case"invalid_element":return`Valore non valido in ${q.origin}`;default:return"Input non valido"}}};var iz=O$(()=>{g$()});function N1(){return{localeError:Ou()}}var Ou=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"\u6570\u5024",array:"\u914D\u5217"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`\u7121\u52B9\u306A\u5165\u529B: instanceof ${q.expected}\u304C\u671F\u5F85\u3055\u308C\u307E\u3057\u305F\u304C\u3001${D}\u304C\u5165\u529B\u3055\u308C\u307E\u3057\u305F`;return`\u7121\u52B9\u306A\u5165\u529B: ${I}\u304C\u671F\u5F85\u3055\u308C\u307E\u3057\u305F\u304C\u3001${D}\u304C\u5165\u529B\u3055\u308C\u307E\u3057\u305F`}case"invalid_value":if(q.values.length===1)return`\u7121\u52B9\u306A\u5165\u529B: ${Q$(q.values[0])}\u304C\u671F\u5F85\u3055\u308C\u307E\u3057\u305F`;return`\u7121\u52B9\u306A\u9078\u629E: ${n(q.values,"\u3001")}\u306E\u3044\u305A\u308C\u304B\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`;case"too_big":{let I=q.inclusive?"\u4EE5\u4E0B\u3067\u3042\u308B":"\u3088\u308A\u5C0F\u3055\u3044",Q=U(q.origin);if(Q)return`\u5927\u304D\u3059\u304E\u308B\u5024: ${q.origin??"\u5024"}\u306F${q.maximum.toString()}${Q.unit??"\u8981\u7D20"}${I}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`;return`\u5927\u304D\u3059\u304E\u308B\u5024: ${q.origin??"\u5024"}\u306F${q.maximum.toString()}${I}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`}case"too_small":{let I=q.inclusive?"\u4EE5\u4E0A\u3067\u3042\u308B":"\u3088\u308A\u5927\u304D\u3044",Q=U(q.origin);if(Q)return`\u5C0F\u3055\u3059\u304E\u308B\u5024: ${q.origin}\u306F${q.minimum.toString()}${Q.unit}${I}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`;return`\u5C0F\u3055\u3059\u304E\u308B\u5024: ${q.origin}\u306F${q.minimum.toString()}${I}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\u7121\u52B9\u306A\u6587\u5B57\u5217: "${I.prefix}"\u3067\u59CB\u307E\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`;if(I.format==="ends_with")return`\u7121\u52B9\u306A\u6587\u5B57\u5217: "${I.suffix}"\u3067\u7D42\u308F\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`;if(I.format==="includes")return`\u7121\u52B9\u306A\u6587\u5B57\u5217: "${I.includes}"\u3092\u542B\u3080\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`;if(I.format==="regex")return`\u7121\u52B9\u306A\u6587\u5B57\u5217: \u30D1\u30BF\u30FC\u30F3${I.pattern}\u306B\u4E00\u81F4\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`;return`\u7121\u52B9\u306A${J[I.format]??q.format}`}case"not_multiple_of":return`\u7121\u52B9\u306A\u6570\u5024: ${q.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${q.keys.length>1?"\u7FA4":""}: ${n(q.keys,"\u3001")}`;case"invalid_key":return`${q.origin}\u5185\u306E\u7121\u52B9\u306A\u30AD\u30FC`;case"invalid_union":return"\u7121\u52B9\u306A\u5165\u529B";case"invalid_element":return`${q.origin}\u5185\u306E\u7121\u52B9\u306A\u5024`;default:return"\u7121\u52B9\u306A\u5165\u529B"}}};var pz=O$(()=>{g$()});function w1(){return{localeError:Zu()}}var Zu=()=>{let $={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 U(q){return $[q]??null}let J={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 \u10D5\u10D4\u10DA\u10D8",base64url:"base64url-\u10D9\u10DD\u10D3\u10D8\u10E0\u10D4\u10D1\u10E3\u10DA\u10D8 \u10D5\u10D4\u10DA\u10D8",json_string:"JSON \u10D5\u10D4\u10DA\u10D8",e164:"E.164 \u10DC\u10DD\u10DB\u10D4\u10E0\u10D8",jwt:"JWT",template_literal:"\u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0"},G={nan:"NaN",number:"\u10E0\u10D8\u10EA\u10EE\u10D5\u10D8",string:"\u10D5\u10D4\u10DA\u10D8",boolean:"\u10D1\u10E3\u10DA\u10D4\u10D0\u10DC\u10D8",function:"\u10E4\u10E3\u10DC\u10E5\u10EA\u10D8\u10D0",array:"\u10DB\u10D0\u10E1\u10D8\u10D5\u10D8"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))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 instanceof ${q.expected}, \u10DB\u10D8\u10E6\u10D4\u10D1\u10E3\u10DA\u10D8 ${D}`;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 ${I}, \u10DB\u10D8\u10E6\u10D4\u10D1\u10E3\u10DA\u10D8 ${D}`}case"invalid_value":if(q.values.length===1)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 ${Q$(q.values[0])}`;return`\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 ${n(q.values,"|")}-\u10D3\u10D0\u10DC`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`\u10D6\u10D4\u10D3\u10DB\u10D4\u10E2\u10D0\u10D3 \u10D3\u10D8\u10D3\u10D8: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${q.origin??"\u10DB\u10DC\u10D8\u10E8\u10D5\u10DC\u10D4\u10DA\u10DD\u10D1\u10D0"} ${Q.verb} ${I}${q.maximum.toString()} ${Q.unit}`;return`\u10D6\u10D4\u10D3\u10DB\u10D4\u10E2\u10D0\u10D3 \u10D3\u10D8\u10D3\u10D8: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${q.origin??"\u10DB\u10DC\u10D8\u10E8\u10D5\u10DC\u10D4\u10DA\u10DD\u10D1\u10D0"} \u10D8\u10E7\u10DD\u10E1 ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`\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 ${q.origin} ${Q.verb} ${I}${q.minimum.toString()} ${Q.unit}`;return`\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 ${q.origin} \u10D8\u10E7\u10DD\u10E1 ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10D5\u10D4\u10DA\u10D8: \u10E3\u10DC\u10D3\u10D0 \u10D8\u10EC\u10E7\u10D4\u10D1\u10DD\u10D3\u10D4\u10E1 "${I.prefix}"-\u10D8\u10D7`;if(I.format==="ends_with")return`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10D5\u10D4\u10DA\u10D8: \u10E3\u10DC\u10D3\u10D0 \u10DB\u10D7\u10D0\u10D5\u10E0\u10D3\u10D4\u10D1\u10DD\u10D3\u10D4\u10E1 "${I.suffix}"-\u10D8\u10D7`;if(I.format==="includes")return`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10D5\u10D4\u10DA\u10D8: \u10E3\u10DC\u10D3\u10D0 \u10E8\u10D4\u10D8\u10EA\u10D0\u10D5\u10D3\u10D4\u10E1 "${I.includes}"-\u10E1`;if(I.format==="regex")return`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10D5\u10D4\u10DA\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 ${I.pattern}`;return`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 ${J[I.format]??q.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 ${q.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${q.keys.length>1?"\u10D4\u10D1\u10D8":"\u10D8"}: ${n(q.keys,", ")}`;case"invalid_key":return`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10D2\u10D0\u10E1\u10D0\u10E6\u10D4\u10D1\u10D8 ${q.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 ${q.origin}-\u10E8\u10D8`;default:return"\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0"}}};var dz=O$(()=>{g$()});function J4(){return{localeError:Ru()}}var Ru=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"\u179B\u17C1\u1781",array:"\u17A2\u17B6\u179A\u17C1 (Array)",null:"\u1782\u17D2\u1798\u17B6\u1793\u178F\u1798\u17D2\u179B\u17C3 (null)"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))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 instanceof ${q.expected} \u1794\u17C9\u17BB\u1793\u17D2\u178F\u17C2\u1791\u1791\u17BD\u179B\u1794\u17B6\u1793 ${D}`;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 ${I} \u1794\u17C9\u17BB\u1793\u17D2\u178F\u17C2\u1791\u1791\u17BD\u179B\u1794\u17B6\u1793 ${D}`}case"invalid_value":if(q.values.length===1)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 ${Q$(q.values[0])}`;return`\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 ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`\u1792\u17C6\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${q.origin??"\u178F\u1798\u17D2\u179B\u17C3"} ${I} ${q.maximum.toString()} ${Q.unit??"\u1792\u17B6\u178F\u17BB"}`;return`\u1792\u17C6\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${q.origin??"\u178F\u1798\u17D2\u179B\u17C3"} ${I} ${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`\u178F\u17BC\u1785\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${q.origin} ${I} ${q.minimum.toString()} ${Q.unit}`;return`\u178F\u17BC\u1785\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${q.origin} ${I} ${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\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}"`;if(I.format==="ends_with")return`\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}"`;if(I.format==="includes")return`\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}"`;if(I.format==="regex")return`\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}`;return`\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 ${J[I.format]??q.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 ${q.divisor}`;case"unrecognized_keys":return`\u179A\u1780\u1783\u17BE\u1789\u179F\u17C4\u1798\u17B7\u1793\u179F\u17D2\u1782\u17B6\u179B\u17CB\u17D6 ${n(q.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 ${q.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 ${q.origin}`;default:return"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C"}}};var M1=O$(()=>{g$()});function H1(){return J4()}var nz=O$(()=>{M1()});function T1(){return{localeError:Nu()}}var Nu=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`\uC798\uBABB\uB41C \uC785\uB825: \uC608\uC0C1 \uD0C0\uC785\uC740 instanceof ${q.expected}, \uBC1B\uC740 \uD0C0\uC785\uC740 ${D}\uC785\uB2C8\uB2E4`;return`\uC798\uBABB\uB41C \uC785\uB825: \uC608\uC0C1 \uD0C0\uC785\uC740 ${I}, \uBC1B\uC740 \uD0C0\uC785\uC740 ${D}\uC785\uB2C8\uB2E4`}case"invalid_value":if(q.values.length===1)return`\uC798\uBABB\uB41C \uC785\uB825: \uAC12\uC740 ${Q$(q.values[0])} \uC774\uC5B4\uC57C \uD569\uB2C8\uB2E4`;return`\uC798\uBABB\uB41C \uC635\uC158: ${n(q.values,"\uB610\uB294 ")} \uC911 \uD558\uB098\uC5EC\uC57C \uD569\uB2C8\uB2E4`;case"too_big":{let I=q.inclusive?"\uC774\uD558":"\uBBF8\uB9CC",Q=I==="\uBBF8\uB9CC"?"\uC774\uC5B4\uC57C \uD569\uB2C8\uB2E4":"\uC5EC\uC57C \uD569\uB2C8\uB2E4",D=U(q.origin),X=D?.unit??"\uC694\uC18C";if(D)return`${q.origin??"\uAC12"}\uC774 \uB108\uBB34 \uD07D\uB2C8\uB2E4: ${q.maximum.toString()}${X} ${I}${Q}`;return`${q.origin??"\uAC12"}\uC774 \uB108\uBB34 \uD07D\uB2C8\uB2E4: ${q.maximum.toString()} ${I}${Q}`}case"too_small":{let I=q.inclusive?"\uC774\uC0C1":"\uCD08\uACFC",Q=I==="\uC774\uC0C1"?"\uC774\uC5B4\uC57C \uD569\uB2C8\uB2E4":"\uC5EC\uC57C \uD569\uB2C8\uB2E4",D=U(q.origin),X=D?.unit??"\uC694\uC18C";if(D)return`${q.origin??"\uAC12"}\uC774 \uB108\uBB34 \uC791\uC2B5\uB2C8\uB2E4: ${q.minimum.toString()}${X} ${I}${Q}`;return`${q.origin??"\uAC12"}\uC774 \uB108\uBB34 \uC791\uC2B5\uB2C8\uB2E4: ${q.minimum.toString()} ${I}${Q}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: "${I.prefix}"(\uC73C)\uB85C \uC2DC\uC791\uD574\uC57C \uD569\uB2C8\uB2E4`;if(I.format==="ends_with")return`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: "${I.suffix}"(\uC73C)\uB85C \uB05D\uB098\uC57C \uD569\uB2C8\uB2E4`;if(I.format==="includes")return`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: "${I.includes}"\uC744(\uB97C) \uD3EC\uD568\uD574\uC57C \uD569\uB2C8\uB2E4`;if(I.format==="regex")return`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: \uC815\uADDC\uC2DD ${I.pattern} \uD328\uD134\uACFC \uC77C\uCE58\uD574\uC57C \uD569\uB2C8\uB2E4`;return`\uC798\uBABB\uB41C ${J[I.format]??q.format}`}case"not_multiple_of":return`\uC798\uBABB\uB41C \uC22B\uC790: ${q.divisor}\uC758 \uBC30\uC218\uC5EC\uC57C \uD569\uB2C8\uB2E4`;case"unrecognized_keys":return`\uC778\uC2DD\uD560 \uC218 \uC5C6\uB294 \uD0A4: ${n(q.keys,", ")}`;case"invalid_key":return`\uC798\uBABB\uB41C \uD0A4: ${q.origin}`;case"invalid_union":return"\uC798\uBABB\uB41C \uC785\uB825";case"invalid_element":return`\uC798\uBABB\uB41C \uAC12: ${q.origin}`;default:return"\uC798\uBABB\uB41C \uC785\uB825"}}};var cz=O$(()=>{g$()});function oz($){let U=Math.abs($),J=U%10,G=U%100;if(G>=11&&G<=19||J===0)return"many";if(J===1)return"one";return"few"}function z1(){return{localeError:wu()}}var q4=($)=>{return $.charAt(0).toUpperCase()+$.slice(1)},wu=()=>{let $={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 U(q,I,Q,D){let X=$[q]??null;if(X===null)return X;return{unit:X.unit[I],verb:X.verb[D][Q?"inclusive":"notInclusive"]}}let J={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"},G={nan:"NaN",number:"skai\u010Dius",bigint:"sveikasis skai\u010Dius",string:"eilut\u0117",boolean:"login\u0117 reik\u0161m\u0117",undefined:"neapibr\u0117\u017Eta reik\u0161m\u0117",function:"funkcija",symbol:"simbolis",array:"masyvas",object:"objektas",null:"nulin\u0117 reik\u0161m\u0117"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Gautas tipas ${D}, o tik\u0117tasi - instanceof ${q.expected}`;return`Gautas tipas ${D}, o tik\u0117tasi - ${I}`}case"invalid_value":if(q.values.length===1)return`Privalo b\u016Bti ${Q$(q.values[0])}`;return`Privalo b\u016Bti vienas i\u0161 ${n(q.values,"|")} pasirinkim\u0173`;case"too_big":{let I=G[q.origin]??q.origin,Q=U(q.origin,oz(Number(q.maximum)),q.inclusive??!1,"smaller");if(Q?.verb)return`${q4(I??q.origin??"reik\u0161m\u0117")} ${Q.verb} ${q.maximum.toString()} ${Q.unit??"element\u0173"}`;let D=q.inclusive?"ne didesnis kaip":"ma\u017Eesnis kaip";return`${q4(I??q.origin??"reik\u0161m\u0117")} turi b\u016Bti ${D} ${q.maximum.toString()} ${Q?.unit}`}case"too_small":{let I=G[q.origin]??q.origin,Q=U(q.origin,oz(Number(q.minimum)),q.inclusive??!1,"bigger");if(Q?.verb)return`${q4(I??q.origin??"reik\u0161m\u0117")} ${Q.verb} ${q.minimum.toString()} ${Q.unit??"element\u0173"}`;let D=q.inclusive?"ne ma\u017Eesnis kaip":"didesnis kaip";return`${q4(I??q.origin??"reik\u0161m\u0117")} turi b\u016Bti ${D} ${q.minimum.toString()} ${Q?.unit}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Eilut\u0117 privalo prasid\u0117ti "${I.prefix}"`;if(I.format==="ends_with")return`Eilut\u0117 privalo pasibaigti "${I.suffix}"`;if(I.format==="includes")return`Eilut\u0117 privalo \u012Ftraukti "${I.includes}"`;if(I.format==="regex")return`Eilut\u0117 privalo atitikti ${I.pattern}`;return`Neteisingas ${J[I.format]??q.format}`}case"not_multiple_of":return`Skai\u010Dius privalo b\u016Bti ${q.divisor} kartotinis.`;case"unrecognized_keys":return`Neatpa\u017Eint${q.keys.length>1?"i":"as"} rakt${q.keys.length>1?"ai":"as"}: ${n(q.keys,", ")}`;case"invalid_key":return"Rastas klaidingas raktas";case"invalid_union":return"Klaidinga \u012Fvestis";case"invalid_element":{let I=G[q.origin]??q.origin;return`${q4(I??q.origin??"reik\u0161m\u0117")} turi klaiding\u0105 \u012Fvest\u012F`}default:return"Klaidinga \u012Fvestis"}}};var az=O$(()=>{g$()});function A1(){return{localeError:Mu()}}var Mu=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"\u0431\u0440\u043E\u0458",array:"\u043D\u0438\u0437\u0430"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`\u0413\u0440\u0435\u0448\u0435\u043D \u0432\u043D\u0435\u0441: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 instanceof ${q.expected}, \u043F\u0440\u0438\u043C\u0435\u043D\u043E ${D}`;return`\u0413\u0440\u0435\u0448\u0435\u043D \u0432\u043D\u0435\u0441: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${I}, \u043F\u0440\u0438\u043C\u0435\u043D\u043E ${D}`}case"invalid_value":if(q.values.length===1)return`Invalid input: expected ${Q$(q.values[0])}`;return`\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 ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u0433\u043E\u043B\u0435\u043C: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${q.origin??"\u0432\u0440\u0435\u0434\u043D\u043E\u0441\u0442\u0430"} \u0434\u0430 \u0438\u043C\u0430 ${I}${q.maximum.toString()} ${Q.unit??"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0438"}`;return`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u0433\u043E\u043B\u0435\u043C: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${q.origin??"\u0432\u0440\u0435\u0434\u043D\u043E\u0441\u0442\u0430"} \u0434\u0430 \u0431\u0438\u0434\u0435 ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u043C\u0430\u043B: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${q.origin} \u0434\u0430 \u0438\u043C\u0430 ${I}${q.minimum.toString()} ${Q.unit}`;return`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u043C\u0430\u043B: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${q.origin} \u0434\u0430 \u0431\u0438\u0434\u0435 ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\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}"`;if(I.format==="ends_with")return`\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}"`;if(I.format==="includes")return`\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}"`;if(I.format==="regex")return`\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}`;return`Invalid ${J[I.format]??q.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 ${q.divisor}`;case"unrecognized_keys":return`${q.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"}: ${n(q.keys,", ")}`;case"invalid_key":return`\u0413\u0440\u0435\u0448\u0435\u043D \u043A\u043B\u0443\u0447 \u0432\u043E ${q.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 ${q.origin}`;default:return"\u0413\u0440\u0435\u0448\u0435\u043D \u0432\u043D\u0435\u0441"}}};var sz=O$(()=>{g$()});function K1(){return{localeError:Hu()}}var Hu=()=>{let $={string:{unit:"aksara",verb:"mempunyai"},file:{unit:"bait",verb:"mempunyai"},array:{unit:"elemen",verb:"mempunyai"},set:{unit:"elemen",verb:"mempunyai"}};function U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"nombor"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Input tidak sah: dijangka instanceof ${q.expected}, diterima ${D}`;return`Input tidak sah: dijangka ${I}, diterima ${D}`}case"invalid_value":if(q.values.length===1)return`Input tidak sah: dijangka ${Q$(q.values[0])}`;return`Pilihan tidak sah: dijangka salah satu daripada ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`Terlalu besar: dijangka ${q.origin??"nilai"} ${Q.verb} ${I}${q.maximum.toString()} ${Q.unit??"elemen"}`;return`Terlalu besar: dijangka ${q.origin??"nilai"} adalah ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`Terlalu kecil: dijangka ${q.origin} ${Q.verb} ${I}${q.minimum.toString()} ${Q.unit}`;return`Terlalu kecil: dijangka ${q.origin} adalah ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`String tidak sah: mesti bermula dengan "${I.prefix}"`;if(I.format==="ends_with")return`String tidak sah: mesti berakhir dengan "${I.suffix}"`;if(I.format==="includes")return`String tidak sah: mesti mengandungi "${I.includes}"`;if(I.format==="regex")return`String tidak sah: mesti sepadan dengan corak ${I.pattern}`;return`${J[I.format]??q.format} tidak sah`}case"not_multiple_of":return`Nombor tidak sah: perlu gandaan ${q.divisor}`;case"unrecognized_keys":return`Kunci tidak dikenali: ${n(q.keys,", ")}`;case"invalid_key":return`Kunci tidak sah dalam ${q.origin}`;case"invalid_union":return"Input tidak sah";case"invalid_element":return`Nilai tidak sah dalam ${q.origin}`;default:return"Input tidak sah"}}};var tz=O$(()=>{g$()});function g1(){return{localeError:Tu()}}var Tu=()=>{let $={string:{unit:"tekens",verb:"heeft"},file:{unit:"bytes",verb:"heeft"},array:{unit:"elementen",verb:"heeft"},set:{unit:"elementen",verb:"heeft"}};function U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"getal"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Ongeldige invoer: verwacht instanceof ${q.expected}, ontving ${D}`;return`Ongeldige invoer: verwacht ${I}, ontving ${D}`}case"invalid_value":if(q.values.length===1)return`Ongeldige invoer: verwacht ${Q$(q.values[0])}`;return`Ongeldige optie: verwacht \xE9\xE9n van ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin),D=q.origin==="date"?"laat":q.origin==="string"?"lang":"groot";if(Q)return`Te ${D}: verwacht dat ${q.origin??"waarde"} ${I}${q.maximum.toString()} ${Q.unit??"elementen"} ${Q.verb}`;return`Te ${D}: verwacht dat ${q.origin??"waarde"} ${I}${q.maximum.toString()} is`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin),D=q.origin==="date"?"vroeg":q.origin==="string"?"kort":"klein";if(Q)return`Te ${D}: verwacht dat ${q.origin} ${I}${q.minimum.toString()} ${Q.unit} ${Q.verb}`;return`Te ${D}: verwacht dat ${q.origin} ${I}${q.minimum.toString()} is`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Ongeldige tekst: moet met "${I.prefix}" beginnen`;if(I.format==="ends_with")return`Ongeldige tekst: moet op "${I.suffix}" eindigen`;if(I.format==="includes")return`Ongeldige tekst: moet "${I.includes}" bevatten`;if(I.format==="regex")return`Ongeldige tekst: moet overeenkomen met patroon ${I.pattern}`;return`Ongeldig: ${J[I.format]??q.format}`}case"not_multiple_of":return`Ongeldig getal: moet een veelvoud van ${q.divisor} zijn`;case"unrecognized_keys":return`Onbekende key${q.keys.length>1?"s":""}: ${n(q.keys,", ")}`;case"invalid_key":return`Ongeldige key in ${q.origin}`;case"invalid_union":return"Ongeldige invoer";case"invalid_element":return`Ongeldige waarde in ${q.origin}`;default:return"Ongeldige invoer"}}};var ez=O$(()=>{g$()});function j1(){return{localeError:zu()}}var zu=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"tall",array:"liste"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Ugyldig input: forventet instanceof ${q.expected}, fikk ${D}`;return`Ugyldig input: forventet ${I}, fikk ${D}`}case"invalid_value":if(q.values.length===1)return`Ugyldig verdi: forventet ${Q$(q.values[0])}`;return`Ugyldig valg: forventet en av ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`For stor(t): forventet ${q.origin??"value"} til \xE5 ha ${I}${q.maximum.toString()} ${Q.unit??"elementer"}`;return`For stor(t): forventet ${q.origin??"value"} til \xE5 ha ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`For lite(n): forventet ${q.origin} til \xE5 ha ${I}${q.minimum.toString()} ${Q.unit}`;return`For lite(n): forventet ${q.origin} til \xE5 ha ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Ugyldig streng: m\xE5 starte med "${I.prefix}"`;if(I.format==="ends_with")return`Ugyldig streng: m\xE5 ende med "${I.suffix}"`;if(I.format==="includes")return`Ugyldig streng: m\xE5 inneholde "${I.includes}"`;if(I.format==="regex")return`Ugyldig streng: m\xE5 matche m\xF8nsteret ${I.pattern}`;return`Ugyldig ${J[I.format]??q.format}`}case"not_multiple_of":return`Ugyldig tall: m\xE5 v\xE6re et multiplum av ${q.divisor}`;case"unrecognized_keys":return`${q.keys.length>1?"Ukjente n\xF8kler":"Ukjent n\xF8kkel"}: ${n(q.keys,", ")}`;case"invalid_key":return`Ugyldig n\xF8kkel i ${q.origin}`;case"invalid_union":return"Ugyldig input";case"invalid_element":return`Ugyldig verdi i ${q.origin}`;default:return"Ugyldig input"}}};var $A=O$(()=>{g$()});function P1(){return{localeError:Au()}}var Au=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"numara",array:"saf",null:"gayb"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`F\xE2sit giren: umulan instanceof ${q.expected}, al\u0131nan ${D}`;return`F\xE2sit giren: umulan ${I}, al\u0131nan ${D}`}case"invalid_value":if(q.values.length===1)return`F\xE2sit giren: umulan ${Q$(q.values[0])}`;return`F\xE2sit tercih: m\xFBteberler ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`Fazla b\xFCy\xFCk: ${q.origin??"value"}, ${I}${q.maximum.toString()} ${Q.unit??"elements"} sahip olmal\u0131yd\u0131.`;return`Fazla b\xFCy\xFCk: ${q.origin??"value"}, ${I}${q.maximum.toString()} olmal\u0131yd\u0131.`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`Fazla k\xFC\xE7\xFCk: ${q.origin}, ${I}${q.minimum.toString()} ${Q.unit} sahip olmal\u0131yd\u0131.`;return`Fazla k\xFC\xE7\xFCk: ${q.origin}, ${I}${q.minimum.toString()} olmal\u0131yd\u0131.`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`F\xE2sit metin: "${I.prefix}" ile ba\u015Flamal\u0131.`;if(I.format==="ends_with")return`F\xE2sit metin: "${I.suffix}" ile bitmeli.`;if(I.format==="includes")return`F\xE2sit metin: "${I.includes}" ihtiv\xE2 etmeli.`;if(I.format==="regex")return`F\xE2sit metin: ${I.pattern} nak\u015F\u0131na uymal\u0131.`;return`F\xE2sit ${J[I.format]??q.format}`}case"not_multiple_of":return`F\xE2sit say\u0131: ${q.divisor} kat\u0131 olmal\u0131yd\u0131.`;case"unrecognized_keys":return`Tan\u0131nmayan anahtar ${q.keys.length>1?"s":""}: ${n(q.keys,", ")}`;case"invalid_key":return`${q.origin} i\xE7in tan\u0131nmayan anahtar var.`;case"invalid_union":return"Giren tan\u0131namad\u0131.";case"invalid_element":return`${q.origin} i\xE7in tan\u0131nmayan k\u0131ymet var.`;default:return"K\u0131ymet tan\u0131namad\u0131."}}};var UA=O$(()=>{g$()});function B1(){return{localeError:Ku()}}var Ku=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"\u0639\u062F\u062F",array:"\u0627\u0631\u06D0"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`\u0646\u0627\u0633\u0645 \u0648\u0631\u0648\u062F\u064A: \u0628\u0627\u06CC\u062F instanceof ${q.expected} \u0648\u0627\u06CC, \u0645\u06AB\u0631 ${D} \u062A\u0631\u0644\u0627\u0633\u0647 \u0634\u0648`;return`\u0646\u0627\u0633\u0645 \u0648\u0631\u0648\u062F\u064A: \u0628\u0627\u06CC\u062F ${I} \u0648\u0627\u06CC, \u0645\u06AB\u0631 ${D} \u062A\u0631\u0644\u0627\u0633\u0647 \u0634\u0648`}case"invalid_value":if(q.values.length===1)return`\u0646\u0627\u0633\u0645 \u0648\u0631\u0648\u062F\u064A: \u0628\u0627\u06CC\u062F ${Q$(q.values[0])} \u0648\u0627\u06CC`;return`\u0646\u0627\u0633\u0645 \u0627\u0646\u062A\u062E\u0627\u0628: \u0628\u0627\u06CC\u062F \u06CC\u0648 \u0644\u0647 ${n(q.values,"|")} \u0685\u062E\u0647 \u0648\u0627\u06CC`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`\u0689\u06CC\u0631 \u0644\u0648\u06CC: ${q.origin??"\u0627\u0631\u0632\u069A\u062A"} \u0628\u0627\u06CC\u062F ${I}${q.maximum.toString()} ${Q.unit??"\u0639\u0646\u0635\u0631\u0648\u0646\u0647"} \u0648\u0644\u0631\u064A`;return`\u0689\u06CC\u0631 \u0644\u0648\u06CC: ${q.origin??"\u0627\u0631\u0632\u069A\u062A"} \u0628\u0627\u06CC\u062F ${I}${q.maximum.toString()} \u0648\u064A`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`\u0689\u06CC\u0631 \u06A9\u0648\u0686\u0646\u06CC: ${q.origin} \u0628\u0627\u06CC\u062F ${I}${q.minimum.toString()} ${Q.unit} \u0648\u0644\u0631\u064A`;return`\u0689\u06CC\u0631 \u06A9\u0648\u0686\u0646\u06CC: ${q.origin} \u0628\u0627\u06CC\u062F ${I}${q.minimum.toString()} \u0648\u064A`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F \u062F "${I.prefix}" \u0633\u0631\u0647 \u067E\u06CC\u0644 \u0634\u064A`;if(I.format==="ends_with")return`\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`;if(I.format==="includes")return`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F "${I.includes}" \u0648\u0644\u0631\u064A`;if(I.format==="regex")return`\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`;return`${J[I.format]??q.format} \u0646\u0627\u0633\u0645 \u062F\u06CC`}case"not_multiple_of":return`\u0646\u0627\u0633\u0645 \u0639\u062F\u062F: \u0628\u0627\u06CC\u062F \u062F ${q.divisor} \u0645\u0636\u0631\u0628 \u0648\u064A`;case"unrecognized_keys":return`\u0646\u0627\u0633\u0645 ${q.keys.length>1?"\u06A9\u0644\u06CC\u0689\u0648\u0646\u0647":"\u06A9\u0644\u06CC\u0689"}: ${n(q.keys,", ")}`;case"invalid_key":return`\u0646\u0627\u0633\u0645 \u06A9\u0644\u06CC\u0689 \u067E\u0647 ${q.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 ${q.origin} \u06A9\u06D0`;default:return"\u0646\u0627\u0633\u0645\u0647 \u0648\u0631\u0648\u062F\u064A"}}};var JA=O$(()=>{g$()});function S1(){return{localeError:gu()}}var gu=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"liczba",array:"tablica"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Nieprawid\u0142owe dane wej\u015Bciowe: oczekiwano instanceof ${q.expected}, otrzymano ${D}`;return`Nieprawid\u0142owe dane wej\u015Bciowe: oczekiwano ${I}, otrzymano ${D}`}case"invalid_value":if(q.values.length===1)return`Nieprawid\u0142owe dane wej\u015Bciowe: oczekiwano ${Q$(q.values[0])}`;return`Nieprawid\u0142owa opcja: oczekiwano jednej z warto\u015Bci ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`Za du\u017Ca warto\u015B\u0107: oczekiwano, \u017Ce ${q.origin??"warto\u015B\u0107"} b\u0119dzie mie\u0107 ${I}${q.maximum.toString()} ${Q.unit??"element\xF3w"}`;return`Zbyt du\u017C(y/a/e): oczekiwano, \u017Ce ${q.origin??"warto\u015B\u0107"} b\u0119dzie wynosi\u0107 ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`Za ma\u0142a warto\u015B\u0107: oczekiwano, \u017Ce ${q.origin??"warto\u015B\u0107"} b\u0119dzie mie\u0107 ${I}${q.minimum.toString()} ${Q.unit??"element\xF3w"}`;return`Zbyt ma\u0142(y/a/e): oczekiwano, \u017Ce ${q.origin??"warto\u015B\u0107"} b\u0119dzie wynosi\u0107 ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi zaczyna\u0107 si\u0119 od "${I.prefix}"`;if(I.format==="ends_with")return`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi ko\u0144czy\u0107 si\u0119 na "${I.suffix}"`;if(I.format==="includes")return`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi zawiera\u0107 "${I.includes}"`;if(I.format==="regex")return`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi odpowiada\u0107 wzorcowi ${I.pattern}`;return`Nieprawid\u0142ow(y/a/e) ${J[I.format]??q.format}`}case"not_multiple_of":return`Nieprawid\u0142owa liczba: musi by\u0107 wielokrotno\u015Bci\u0105 ${q.divisor}`;case"unrecognized_keys":return`Nierozpoznane klucze${q.keys.length>1?"s":""}: ${n(q.keys,", ")}`;case"invalid_key":return`Nieprawid\u0142owy klucz w ${q.origin}`;case"invalid_union":return"Nieprawid\u0142owe dane wej\u015Bciowe";case"invalid_element":return`Nieprawid\u0142owa warto\u015B\u0107 w ${q.origin}`;default:return"Nieprawid\u0142owe dane wej\u015Bciowe"}}};var qA=O$(()=>{g$()});function L1(){return{localeError:ju()}}var ju=()=>{let $={string:{unit:"caracteres",verb:"ter"},file:{unit:"bytes",verb:"ter"},array:{unit:"itens",verb:"ter"},set:{unit:"itens",verb:"ter"}};function U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"n\xFAmero",null:"nulo"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Tipo inv\xE1lido: esperado instanceof ${q.expected}, recebido ${D}`;return`Tipo inv\xE1lido: esperado ${I}, recebido ${D}`}case"invalid_value":if(q.values.length===1)return`Entrada inv\xE1lida: esperado ${Q$(q.values[0])}`;return`Op\xE7\xE3o inv\xE1lida: esperada uma das ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`Muito grande: esperado que ${q.origin??"valor"} tivesse ${I}${q.maximum.toString()} ${Q.unit??"elementos"}`;return`Muito grande: esperado que ${q.origin??"valor"} fosse ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`Muito pequeno: esperado que ${q.origin} tivesse ${I}${q.minimum.toString()} ${Q.unit}`;return`Muito pequeno: esperado que ${q.origin} fosse ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Texto inv\xE1lido: deve come\xE7ar com "${I.prefix}"`;if(I.format==="ends_with")return`Texto inv\xE1lido: deve terminar com "${I.suffix}"`;if(I.format==="includes")return`Texto inv\xE1lido: deve incluir "${I.includes}"`;if(I.format==="regex")return`Texto inv\xE1lido: deve corresponder ao padr\xE3o ${I.pattern}`;return`${J[I.format]??q.format} inv\xE1lido`}case"not_multiple_of":return`N\xFAmero inv\xE1lido: deve ser m\xFAltiplo de ${q.divisor}`;case"unrecognized_keys":return`Chave${q.keys.length>1?"s":""} desconhecida${q.keys.length>1?"s":""}: ${n(q.keys,", ")}`;case"invalid_key":return`Chave inv\xE1lida em ${q.origin}`;case"invalid_union":return"Entrada inv\xE1lida";case"invalid_element":return`Valor inv\xE1lido em ${q.origin}`;default:return"Campo inv\xE1lido"}}};var GA=O$(()=>{g$()});function E1(){return{localeError:Pu()}}var Pu=()=>{let $={string:{unit:"caractere",verb:"s\u0103 aib\u0103"},file:{unit:"octe\u021Bi",verb:"s\u0103 aib\u0103"},array:{unit:"elemente",verb:"s\u0103 aib\u0103"},set:{unit:"elemente",verb:"s\u0103 aib\u0103"},map:{unit:"intr\u0103ri",verb:"s\u0103 aib\u0103"}};function U(q){return $[q]??null}let J={regex:"intrare",email:"adres\u0103 de 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:"dat\u0103 \u0219i or\u0103 ISO",date:"dat\u0103 ISO",time:"or\u0103 ISO",duration:"durat\u0103 ISO",ipv4:"adres\u0103 IPv4",ipv6:"adres\u0103 IPv6",mac:"adres\u0103 MAC",cidrv4:"interval IPv4",cidrv6:"interval IPv6",base64:"\u0219ir codat base64",base64url:"\u0219ir codat base64url",json_string:"\u0219ir JSON",e164:"num\u0103r E.164",jwt:"JWT",template_literal:"intrare"},G={nan:"NaN",string:"\u0219ir",number:"num\u0103r",boolean:"boolean",function:"func\u021Bie",array:"matrice",object:"obiect",undefined:"nedefinit",symbol:"simbol",bigint:"num\u0103r mare",void:"void",never:"never",map:"hart\u0103",set:"set"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;return`Intrare invalid\u0103: a\u0219teptat ${I}, primit ${D}`}case"invalid_value":if(q.values.length===1)return`Intrare invalid\u0103: a\u0219teptat ${Q$(q.values[0])}`;return`Op\u021Biune invalid\u0103: a\u0219teptat una dintre ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`Prea mare: a\u0219teptat ca ${q.origin??"valoarea"} ${Q.verb} ${I}${q.maximum.toString()} ${Q.unit??"elemente"}`;return`Prea mare: a\u0219teptat ca ${q.origin??"valoarea"} s\u0103 fie ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`Prea mic: a\u0219teptat ca ${q.origin} ${Q.verb} ${I}${q.minimum.toString()} ${Q.unit}`;return`Prea mic: a\u0219teptat ca ${q.origin} s\u0103 fie ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\u0218ir invalid: trebuie s\u0103 \xEEnceap\u0103 cu "${I.prefix}"`;if(I.format==="ends_with")return`\u0218ir invalid: trebuie s\u0103 se termine cu "${I.suffix}"`;if(I.format==="includes")return`\u0218ir invalid: trebuie s\u0103 includ\u0103 "${I.includes}"`;if(I.format==="regex")return`\u0218ir invalid: trebuie s\u0103 se potriveasc\u0103 cu modelul ${I.pattern}`;return`Format invalid: ${J[I.format]??q.format}`}case"not_multiple_of":return`Num\u0103r invalid: trebuie s\u0103 fie multiplu de ${q.divisor}`;case"unrecognized_keys":return`Chei nerecunoscute: ${n(q.keys,", ")}`;case"invalid_key":return`Cheie invalid\u0103 \xEEn ${q.origin}`;case"invalid_union":return"Intrare invalid\u0103";case"invalid_element":return`Valoare invalid\u0103 \xEEn ${q.origin}`;default:return"Intrare invalid\u0103"}}};var IA=O$(()=>{g$()});function QA($,U,J,G){let q=Math.abs($),I=q%10,Q=q%100;if(Q>=11&&Q<=19)return G;if(I===1)return U;if(I>=2&&I<=4)return J;return G}function C1(){return{localeError:Bu()}}var Bu=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"\u0447\u0438\u0441\u043B\u043E",array:"\u043C\u0430\u0441\u0441\u0438\u0432"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0432\u0432\u043E\u0434: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C instanceof ${q.expected}, \u043F\u043E\u043B\u0443\u0447\u0435\u043D\u043E ${D}`;return`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0432\u0432\u043E\u0434: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C ${I}, \u043F\u043E\u043B\u0443\u0447\u0435\u043D\u043E ${D}`}case"invalid_value":if(q.values.length===1)return`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0432\u0432\u043E\u0434: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C ${Q$(q.values[0])}`;return`\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 ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q){let D=Number(q.maximum),X=QA(D,Q.unit.one,Q.unit.few,Q.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 ${q.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435"} \u0431\u0443\u0434\u0435\u0442 \u0438\u043C\u0435\u0442\u044C ${I}${q.maximum.toString()} ${X}`}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 ${q.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435"} \u0431\u0443\u0434\u0435\u0442 ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q){let D=Number(q.minimum),X=QA(D,Q.unit.one,Q.unit.few,Q.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 ${q.origin} \u0431\u0443\u0434\u0435\u0442 \u0438\u043C\u0435\u0442\u044C ${I}${q.minimum.toString()} ${X}`}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 ${q.origin} \u0431\u0443\u0434\u0435\u0442 ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\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}"`;if(I.format==="ends_with")return`\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}"`;if(I.format==="includes")return`\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}"`;if(I.format==="regex")return`\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}`;return`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 ${J[I.format]??q.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 ${q.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u0430\u0441\u043F\u043E\u0437\u043D\u0430\u043D\u043D${q.keys.length>1?"\u044B\u0435":"\u044B\u0439"} \u043A\u043B\u044E\u0447${q.keys.length>1?"\u0438":""}: ${n(q.keys,", ")}`;case"invalid_key":return`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u043A\u043B\u044E\u0447 \u0432 ${q.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 ${q.origin}`;default:return"\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0435 \u0432\u0445\u043E\u0434\u043D\u044B\u0435 \u0434\u0430\u043D\u043D\u044B\u0435"}}};var DA=O$(()=>{g$()});function _1(){return{localeError:Su()}}var Su=()=>{let $={string:{unit:"znakov",verb:"imeti"},file:{unit:"bajtov",verb:"imeti"},array:{unit:"elementov",verb:"imeti"},set:{unit:"elementov",verb:"imeti"}};function U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"\u0161tevilo",array:"tabela"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Neveljaven vnos: pri\u010Dakovano instanceof ${q.expected}, prejeto ${D}`;return`Neveljaven vnos: pri\u010Dakovano ${I}, prejeto ${D}`}case"invalid_value":if(q.values.length===1)return`Neveljaven vnos: pri\u010Dakovano ${Q$(q.values[0])}`;return`Neveljavna mo\u017Enost: pri\u010Dakovano eno izmed ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`Preveliko: pri\u010Dakovano, da bo ${q.origin??"vrednost"} imelo ${I}${q.maximum.toString()} ${Q.unit??"elementov"}`;return`Preveliko: pri\u010Dakovano, da bo ${q.origin??"vrednost"} ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`Premajhno: pri\u010Dakovano, da bo ${q.origin} imelo ${I}${q.minimum.toString()} ${Q.unit}`;return`Premajhno: pri\u010Dakovano, da bo ${q.origin} ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Neveljaven niz: mora se za\u010Deti z "${I.prefix}"`;if(I.format==="ends_with")return`Neveljaven niz: mora se kon\u010Dati z "${I.suffix}"`;if(I.format==="includes")return`Neveljaven niz: mora vsebovati "${I.includes}"`;if(I.format==="regex")return`Neveljaven niz: mora ustrezati vzorcu ${I.pattern}`;return`Neveljaven ${J[I.format]??q.format}`}case"not_multiple_of":return`Neveljavno \u0161tevilo: mora biti ve\u010Dkratnik ${q.divisor}`;case"unrecognized_keys":return`Neprepoznan${q.keys.length>1?"i klju\u010Di":" klju\u010D"}: ${n(q.keys,", ")}`;case"invalid_key":return`Neveljaven klju\u010D v ${q.origin}`;case"invalid_union":return"Neveljaven vnos";case"invalid_element":return`Neveljavna vrednost v ${q.origin}`;default:return"Neveljaven vnos"}}};var XA=O$(()=>{g$()});function v1(){return{localeError:Lu()}}var Lu=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"antal",array:"lista"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Ogiltig inmatning: f\xF6rv\xE4ntat instanceof ${q.expected}, fick ${D}`;return`Ogiltig inmatning: f\xF6rv\xE4ntat ${I}, fick ${D}`}case"invalid_value":if(q.values.length===1)return`Ogiltig inmatning: f\xF6rv\xE4ntat ${Q$(q.values[0])}`;return`Ogiltigt val: f\xF6rv\xE4ntade en av ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`F\xF6r stor(t): f\xF6rv\xE4ntade ${q.origin??"v\xE4rdet"} att ha ${I}${q.maximum.toString()} ${Q.unit??"element"}`;return`F\xF6r stor(t): f\xF6rv\xE4ntat ${q.origin??"v\xE4rdet"} att ha ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`F\xF6r lite(t): f\xF6rv\xE4ntade ${q.origin??"v\xE4rdet"} att ha ${I}${q.minimum.toString()} ${Q.unit}`;return`F\xF6r lite(t): f\xF6rv\xE4ntade ${q.origin??"v\xE4rdet"} att ha ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Ogiltig str\xE4ng: m\xE5ste b\xF6rja med "${I.prefix}"`;if(I.format==="ends_with")return`Ogiltig str\xE4ng: m\xE5ste sluta med "${I.suffix}"`;if(I.format==="includes")return`Ogiltig str\xE4ng: m\xE5ste inneh\xE5lla "${I.includes}"`;if(I.format==="regex")return`Ogiltig str\xE4ng: m\xE5ste matcha m\xF6nstret "${I.pattern}"`;return`Ogiltig(t) ${J[I.format]??q.format}`}case"not_multiple_of":return`Ogiltigt tal: m\xE5ste vara en multipel av ${q.divisor}`;case"unrecognized_keys":return`${q.keys.length>1?"Ok\xE4nda nycklar":"Ok\xE4nd nyckel"}: ${n(q.keys,", ")}`;case"invalid_key":return`Ogiltig nyckel i ${q.origin??"v\xE4rdet"}`;case"invalid_union":return"Ogiltig input";case"invalid_element":return`Ogiltigt v\xE4rde i ${q.origin??"v\xE4rdet"}`;default:return"Ogiltig input"}}};var YA=O$(()=>{g$()});function F1(){return{localeError:Eu()}}var Eu=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"\u0B8E\u0BA3\u0BCD",array:"\u0B85\u0BA3\u0BBF",null:"\u0BB5\u0BC6\u0BB1\u0BC1\u0BAE\u0BC8"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))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 instanceof ${q.expected}, \u0BAA\u0BC6\u0BB1\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${D}`;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 ${I}, \u0BAA\u0BC6\u0BB1\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${D}`}case"invalid_value":if(q.values.length===1)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 ${Q$(q.values[0])}`;return`\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 ${n(q.values,"|")} \u0B87\u0BB2\u0BCD \u0B92\u0BA9\u0BCD\u0BB1\u0BC1`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`\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 ${q.origin??"\u0BAE\u0BA4\u0BBF\u0BAA\u0BCD\u0BAA\u0BC1"} ${I}${q.maximum.toString()} ${Q.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`;return`\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 ${q.origin??"\u0BAE\u0BA4\u0BBF\u0BAA\u0BCD\u0BAA\u0BC1"} ${I}${q.maximum.toString()} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`\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 ${q.origin} ${I}${q.minimum.toString()} ${Q.unit} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`;return`\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 ${q.origin} ${I}${q.minimum.toString()} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\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`;if(I.format==="ends_with")return`\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`;if(I.format==="includes")return`\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`;if(I.format==="regex")return`\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`;return`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 ${J[I.format]??q.format}`}case"not_multiple_of":return`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B8E\u0BA3\u0BCD: ${q.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${q.keys.length>1?"\u0B95\u0BB3\u0BCD":""}: ${n(q.keys,", ")}`;case"invalid_key":return`${q.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`${q.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"}}};var VA=O$(()=>{g$()});function b1(){return{localeError:Cu()}}var Cu=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"\u0E15\u0E31\u0E27\u0E40\u0E25\u0E02",array:"\u0E2D\u0E32\u0E23\u0E4C\u0E40\u0E23\u0E22\u0E4C (Array)",null:"\u0E44\u0E21\u0E48\u0E21\u0E35\u0E04\u0E48\u0E32 (null)"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))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 instanceof ${q.expected} \u0E41\u0E15\u0E48\u0E44\u0E14\u0E49\u0E23\u0E31\u0E1A ${D}`;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 ${I} \u0E41\u0E15\u0E48\u0E44\u0E14\u0E49\u0E23\u0E31\u0E1A ${D}`}case"invalid_value":if(q.values.length===1)return`\u0E04\u0E48\u0E32\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E04\u0E27\u0E23\u0E40\u0E1B\u0E47\u0E19 ${Q$(q.values[0])}`;return`\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 ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"\u0E44\u0E21\u0E48\u0E40\u0E01\u0E34\u0E19":"\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32",Q=U(q.origin);if(Q)return`\u0E40\u0E01\u0E34\u0E19\u0E01\u0E33\u0E2B\u0E19\u0E14: ${q.origin??"\u0E04\u0E48\u0E32"} \u0E04\u0E27\u0E23\u0E21\u0E35${I} ${q.maximum.toString()} ${Q.unit??"\u0E23\u0E32\u0E22\u0E01\u0E32\u0E23"}`;return`\u0E40\u0E01\u0E34\u0E19\u0E01\u0E33\u0E2B\u0E19\u0E14: ${q.origin??"\u0E04\u0E48\u0E32"} \u0E04\u0E27\u0E23\u0E21\u0E35${I} ${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?"\u0E2D\u0E22\u0E48\u0E32\u0E07\u0E19\u0E49\u0E2D\u0E22":"\u0E21\u0E32\u0E01\u0E01\u0E27\u0E48\u0E32",Q=U(q.origin);if(Q)return`\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32\u0E01\u0E33\u0E2B\u0E19\u0E14: ${q.origin} \u0E04\u0E27\u0E23\u0E21\u0E35${I} ${q.minimum.toString()} ${Q.unit}`;return`\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32\u0E01\u0E33\u0E2B\u0E19\u0E14: ${q.origin} \u0E04\u0E27\u0E23\u0E21\u0E35${I} ${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\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}"`;if(I.format==="ends_with")return`\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}"`;if(I.format==="includes")return`\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`;if(I.format==="regex")return`\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}`;return`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: ${J[I.format]??q.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 ${q.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: ${n(q.keys,", ")}`;case"invalid_key":return`\u0E04\u0E35\u0E22\u0E4C\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07\u0E43\u0E19 ${q.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 ${q.origin}`;default:return"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07"}}};var WA=O$(()=>{g$()});function u1(){return{localeError:_u()}}var _u=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Ge\xE7ersiz de\u011Fer: beklenen instanceof ${q.expected}, al\u0131nan ${D}`;return`Ge\xE7ersiz de\u011Fer: beklenen ${I}, al\u0131nan ${D}`}case"invalid_value":if(q.values.length===1)return`Ge\xE7ersiz de\u011Fer: beklenen ${Q$(q.values[0])}`;return`Ge\xE7ersiz se\xE7enek: a\u015Fa\u011F\u0131dakilerden biri olmal\u0131: ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`\xC7ok b\xFCy\xFCk: beklenen ${q.origin??"de\u011Fer"} ${I}${q.maximum.toString()} ${Q.unit??"\xF6\u011Fe"}`;return`\xC7ok b\xFCy\xFCk: beklenen ${q.origin??"de\u011Fer"} ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`\xC7ok k\xFC\xE7\xFCk: beklenen ${q.origin} ${I}${q.minimum.toString()} ${Q.unit}`;return`\xC7ok k\xFC\xE7\xFCk: beklenen ${q.origin} ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Ge\xE7ersiz metin: "${I.prefix}" ile ba\u015Flamal\u0131`;if(I.format==="ends_with")return`Ge\xE7ersiz metin: "${I.suffix}" ile bitmeli`;if(I.format==="includes")return`Ge\xE7ersiz metin: "${I.includes}" i\xE7ermeli`;if(I.format==="regex")return`Ge\xE7ersiz metin: ${I.pattern} desenine uymal\u0131`;return`Ge\xE7ersiz ${J[I.format]??q.format}`}case"not_multiple_of":return`Ge\xE7ersiz say\u0131: ${q.divisor} ile tam b\xF6l\xFCnebilmeli`;case"unrecognized_keys":return`Tan\u0131nmayan anahtar${q.keys.length>1?"lar":""}: ${n(q.keys,", ")}`;case"invalid_key":return`${q.origin} i\xE7inde ge\xE7ersiz anahtar`;case"invalid_union":return"Ge\xE7ersiz de\u011Fer";case"invalid_element":return`${q.origin} i\xE7inde ge\xE7ersiz de\u011Fer`;default:return"Ge\xE7ersiz de\u011Fer"}}};var OA=O$(()=>{g$()});function G4(){return{localeError:vu()}}var vu=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"\u0447\u0438\u0441\u043B\u043E",array:"\u043C\u0430\u0441\u0438\u0432"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))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 instanceof ${q.expected}, \u043E\u0442\u0440\u0438\u043C\u0430\u043D\u043E ${D}`;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 ${I}, \u043E\u0442\u0440\u0438\u043C\u0430\u043D\u043E ${D}`}case"invalid_value":if(q.values.length===1)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 ${Q$(q.values[0])}`;return`\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 ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`\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 ${q.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F"} ${Q.verb} ${I}${q.maximum.toString()} ${Q.unit??"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0456\u0432"}`;return`\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 ${q.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F"} \u0431\u0443\u0434\u0435 ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u043C\u0430\u043B\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${q.origin} ${Q.verb} ${I}${q.minimum.toString()} ${Q.unit}`;return`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u043C\u0430\u043B\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${q.origin} \u0431\u0443\u0434\u0435 ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\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}"`;if(I.format==="ends_with")return`\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}"`;if(I.format==="includes")return`\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}"`;if(I.format==="regex")return`\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}`;return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 ${J[I.format]??q.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 ${q.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u043E\u0437\u043F\u0456\u0437\u043D\u0430\u043D\u0438\u0439 \u043A\u043B\u044E\u0447${q.keys.length>1?"\u0456":""}: ${n(q.keys,", ")}`;case"invalid_key":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u043A\u043B\u044E\u0447 \u0443 ${q.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 ${q.origin}`;default:return"\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456"}}};var k1=O$(()=>{g$()});function x1(){return G4()}var ZA=O$(()=>{k1()});function f1(){return{localeError:Fu()}}var Fu=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"\u0646\u0645\u0628\u0631",array:"\u0622\u0631\u06D2",null:"\u0646\u0644"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679: instanceof ${q.expected} \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627\u060C ${D} \u0645\u0648\u0635\u0648\u0644 \u06C1\u0648\u0627`;return`\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679: ${I} \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627\u060C ${D} \u0645\u0648\u0635\u0648\u0644 \u06C1\u0648\u0627`}case"invalid_value":if(q.values.length===1)return`\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679: ${Q$(q.values[0])} \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`;return`\u063A\u0644\u0637 \u0622\u067E\u0634\u0646: ${n(q.values,"|")} \u0645\u06CC\u06BA \u0633\u06D2 \u0627\u06CC\u06A9 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`\u0628\u06C1\u062A \u0628\u0691\u0627: ${q.origin??"\u0648\u06CC\u0644\u06CC\u0648"} \u06A9\u06D2 ${I}${q.maximum.toString()} ${Q.unit??"\u0639\u0646\u0627\u0635\u0631"} \u06C1\u0648\u0646\u06D2 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u06D2`;return`\u0628\u06C1\u062A \u0628\u0691\u0627: ${q.origin??"\u0648\u06CC\u0644\u06CC\u0648"} \u06A9\u0627 ${I}${q.maximum.toString()} \u06C1\u0648\u0646\u0627 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`\u0628\u06C1\u062A \u0686\u06BE\u0648\u0679\u0627: ${q.origin} \u06A9\u06D2 ${I}${q.minimum.toString()} ${Q.unit} \u06C1\u0648\u0646\u06D2 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u06D2`;return`\u0628\u06C1\u062A \u0686\u06BE\u0648\u0679\u0627: ${q.origin} \u06A9\u0627 ${I}${q.minimum.toString()} \u06C1\u0648\u0646\u0627 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\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`;if(I.format==="ends_with")return`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: "${I.suffix}" \u067E\u0631 \u062E\u062A\u0645 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`;if(I.format==="includes")return`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: "${I.includes}" \u0634\u0627\u0645\u0644 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`;if(I.format==="regex")return`\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`;return`\u063A\u0644\u0637 ${J[I.format]??q.format}`}case"not_multiple_of":return`\u063A\u0644\u0637 \u0646\u0645\u0628\u0631: ${q.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${q.keys.length>1?"\u0632":""}: ${n(q.keys,"\u060C ")}`;case"invalid_key":return`${q.origin} \u0645\u06CC\u06BA \u063A\u0644\u0637 \u06A9\u06CC`;case"invalid_union":return"\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679";case"invalid_element":return`${q.origin} \u0645\u06CC\u06BA \u063A\u0644\u0637 \u0648\u06CC\u0644\u06CC\u0648`;default:return"\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679"}}};var RA=O$(()=>{g$()});function y1(){return{localeError:bu()}}var bu=()=>{let $={string:{unit:"belgi",verb:"bo\u2018lishi kerak"},file:{unit:"bayt",verb:"bo\u2018lishi kerak"},array:{unit:"element",verb:"bo\u2018lishi kerak"},set:{unit:"element",verb:"bo\u2018lishi kerak"},map:{unit:"yozuv",verb:"bo\u2018lishi kerak"}};function U(q){return $[q]??null}let J={regex:"kirish",email:"elektron pochta manzili",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 sana va vaqti",date:"ISO sana",time:"ISO vaqt",duration:"ISO davomiylik",ipv4:"IPv4 manzil",ipv6:"IPv6 manzil",mac:"MAC manzil",cidrv4:"IPv4 diapazon",cidrv6:"IPv6 diapazon",base64:"base64 kodlangan satr",base64url:"base64url kodlangan satr",json_string:"JSON satr",e164:"E.164 raqam",jwt:"JWT",template_literal:"kirish"},G={nan:"NaN",number:"raqam",array:"massiv"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`Noto\u2018g\u2018ri kirish: kutilgan instanceof ${q.expected}, qabul qilingan ${D}`;return`Noto\u2018g\u2018ri kirish: kutilgan ${I}, qabul qilingan ${D}`}case"invalid_value":if(q.values.length===1)return`Noto\u2018g\u2018ri kirish: kutilgan ${Q$(q.values[0])}`;return`Noto\u2018g\u2018ri variant: quyidagilardan biri kutilgan ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`Juda katta: kutilgan ${q.origin??"qiymat"} ${I}${q.maximum.toString()} ${Q.unit} ${Q.verb}`;return`Juda katta: kutilgan ${q.origin??"qiymat"} ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`Juda kichik: kutilgan ${q.origin} ${I}${q.minimum.toString()} ${Q.unit} ${Q.verb}`;return`Juda kichik: kutilgan ${q.origin} ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Noto\u2018g\u2018ri satr: "${I.prefix}" bilan boshlanishi kerak`;if(I.format==="ends_with")return`Noto\u2018g\u2018ri satr: "${I.suffix}" bilan tugashi kerak`;if(I.format==="includes")return`Noto\u2018g\u2018ri satr: "${I.includes}" ni o\u2018z ichiga olishi kerak`;if(I.format==="regex")return`Noto\u2018g\u2018ri satr: ${I.pattern} shabloniga mos kelishi kerak`;return`Noto\u2018g\u2018ri ${J[I.format]??q.format}`}case"not_multiple_of":return`Noto\u2018g\u2018ri raqam: ${q.divisor} ning karralisi bo\u2018lishi kerak`;case"unrecognized_keys":return`Noma\u2019lum kalit${q.keys.length>1?"lar":""}: ${n(q.keys,", ")}`;case"invalid_key":return`${q.origin} dagi kalit noto\u2018g\u2018ri`;case"invalid_union":return"Noto\u2018g\u2018ri kirish";case"invalid_element":return`${q.origin} da noto\u2018g\u2018ri qiymat`;default:return"Noto\u2018g\u2018ri kirish"}}};var NA=O$(()=>{g$()});function m1(){return{localeError:uu()}}var uu=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"s\u1ED1",array:"m\u1EA3ng"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i instanceof ${q.expected}, nh\u1EADn \u0111\u01B0\u1EE3c ${D}`;return`\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i ${I}, nh\u1EADn \u0111\u01B0\u1EE3c ${D}`}case"invalid_value":if(q.values.length===1)return`\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i ${Q$(q.values[0])}`;return`T\xF9y ch\u1ECDn kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i m\u1ED9t trong c\xE1c gi\xE1 tr\u1ECB ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`Qu\xE1 l\u1EDBn: mong \u0111\u1EE3i ${q.origin??"gi\xE1 tr\u1ECB"} ${Q.verb} ${I}${q.maximum.toString()} ${Q.unit??"ph\u1EA7n t\u1EED"}`;return`Qu\xE1 l\u1EDBn: mong \u0111\u1EE3i ${q.origin??"gi\xE1 tr\u1ECB"} ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`Qu\xE1 nh\u1ECF: mong \u0111\u1EE3i ${q.origin} ${Q.verb} ${I}${q.minimum.toString()} ${Q.unit}`;return`Qu\xE1 nh\u1ECF: mong \u0111\u1EE3i ${q.origin} ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i b\u1EAFt \u0111\u1EA7u b\u1EB1ng "${I.prefix}"`;if(I.format==="ends_with")return`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i k\u1EBFt th\xFAc b\u1EB1ng "${I.suffix}"`;if(I.format==="includes")return`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i bao g\u1ED3m "${I.includes}"`;if(I.format==="regex")return`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i kh\u1EDBp v\u1EDBi m\u1EABu ${I.pattern}`;return`${J[I.format]??q.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 ${q.divisor}`;case"unrecognized_keys":return`Kh\xF3a kh\xF4ng \u0111\u01B0\u1EE3c nh\u1EADn d\u1EA1ng: ${n(q.keys,", ")}`;case"invalid_key":return`Kh\xF3a kh\xF4ng h\u1EE3p l\u1EC7 trong ${q.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 ${q.origin}`;default:return"\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7"}}};var wA=O$(()=>{g$()});function h1(){return{localeError:ku()}}var ku=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"\u6570\u5B57",array:"\u6570\u7EC4",null:"\u7A7A\u503C(null)"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`\u65E0\u6548\u8F93\u5165\uFF1A\u671F\u671B instanceof ${q.expected}\uFF0C\u5B9E\u9645\u63A5\u6536 ${D}`;return`\u65E0\u6548\u8F93\u5165\uFF1A\u671F\u671B ${I}\uFF0C\u5B9E\u9645\u63A5\u6536 ${D}`}case"invalid_value":if(q.values.length===1)return`\u65E0\u6548\u8F93\u5165\uFF1A\u671F\u671B ${Q$(q.values[0])}`;return`\u65E0\u6548\u9009\u9879\uFF1A\u671F\u671B\u4EE5\u4E0B\u4E4B\u4E00 ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`\u6570\u503C\u8FC7\u5927\uFF1A\u671F\u671B ${q.origin??"\u503C"} ${I}${q.maximum.toString()} ${Q.unit??"\u4E2A\u5143\u7D20"}`;return`\u6570\u503C\u8FC7\u5927\uFF1A\u671F\u671B ${q.origin??"\u503C"} ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`\u6570\u503C\u8FC7\u5C0F\uFF1A\u671F\u671B ${q.origin} ${I}${q.minimum.toString()} ${Q.unit}`;return`\u6570\u503C\u8FC7\u5C0F\uFF1A\u671F\u671B ${q.origin} ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u4EE5 "${I.prefix}" \u5F00\u5934`;if(I.format==="ends_with")return`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u4EE5 "${I.suffix}" \u7ED3\u5C3E`;if(I.format==="includes")return`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u5305\u542B "${I.includes}"`;if(I.format==="regex")return`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u6EE1\u8DB3\u6B63\u5219\u8868\u8FBE\u5F0F ${I.pattern}`;return`\u65E0\u6548${J[I.format]??q.format}`}case"not_multiple_of":return`\u65E0\u6548\u6570\u5B57\uFF1A\u5FC5\u987B\u662F ${q.divisor} \u7684\u500D\u6570`;case"unrecognized_keys":return`\u51FA\u73B0\u672A\u77E5\u7684\u952E(key): ${n(q.keys,", ")}`;case"invalid_key":return`${q.origin} \u4E2D\u7684\u952E(key)\u65E0\u6548`;case"invalid_union":return"\u65E0\u6548\u8F93\u5165";case"invalid_element":return`${q.origin} \u4E2D\u5305\u542B\u65E0\u6548\u503C(value)`;default:return"\u65E0\u6548\u8F93\u5165"}}};var MA=O$(()=>{g$()});function r1(){return{localeError:xu()}}var xu=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`\u7121\u6548\u7684\u8F38\u5165\u503C\uFF1A\u9810\u671F\u70BA instanceof ${q.expected}\uFF0C\u4F46\u6536\u5230 ${D}`;return`\u7121\u6548\u7684\u8F38\u5165\u503C\uFF1A\u9810\u671F\u70BA ${I}\uFF0C\u4F46\u6536\u5230 ${D}`}case"invalid_value":if(q.values.length===1)return`\u7121\u6548\u7684\u8F38\u5165\u503C\uFF1A\u9810\u671F\u70BA ${Q$(q.values[0])}`;return`\u7121\u6548\u7684\u9078\u9805\uFF1A\u9810\u671F\u70BA\u4EE5\u4E0B\u5176\u4E2D\u4E4B\u4E00 ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`\u6578\u503C\u904E\u5927\uFF1A\u9810\u671F ${q.origin??"\u503C"} \u61C9\u70BA ${I}${q.maximum.toString()} ${Q.unit??"\u500B\u5143\u7D20"}`;return`\u6578\u503C\u904E\u5927\uFF1A\u9810\u671F ${q.origin??"\u503C"} \u61C9\u70BA ${I}${q.maximum.toString()}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`\u6578\u503C\u904E\u5C0F\uFF1A\u9810\u671F ${q.origin} \u61C9\u70BA ${I}${q.minimum.toString()} ${Q.unit}`;return`\u6578\u503C\u904E\u5C0F\uFF1A\u9810\u671F ${q.origin} \u61C9\u70BA ${I}${q.minimum.toString()}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u4EE5 "${I.prefix}" \u958B\u982D`;if(I.format==="ends_with")return`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u4EE5 "${I.suffix}" \u7D50\u5C3E`;if(I.format==="includes")return`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u5305\u542B "${I.includes}"`;if(I.format==="regex")return`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u7B26\u5408\u683C\u5F0F ${I.pattern}`;return`\u7121\u6548\u7684 ${J[I.format]??q.format}`}case"not_multiple_of":return`\u7121\u6548\u7684\u6578\u5B57\uFF1A\u5FC5\u9808\u70BA ${q.divisor} \u7684\u500D\u6578`;case"unrecognized_keys":return`\u7121\u6CD5\u8B58\u5225\u7684\u9375\u503C${q.keys.length>1?"\u5011":""}\uFF1A${n(q.keys,"\u3001")}`;case"invalid_key":return`${q.origin} \u4E2D\u6709\u7121\u6548\u7684\u9375\u503C`;case"invalid_union":return"\u7121\u6548\u7684\u8F38\u5165\u503C";case"invalid_element":return`${q.origin} \u4E2D\u6709\u7121\u6548\u7684\u503C`;default:return"\u7121\u6548\u7684\u8F38\u5165\u503C"}}};var HA=O$(()=>{g$()});function l1(){return{localeError:fu()}}var fu=()=>{let $={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 U(q){return $[q]??null}let J={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"},G={nan:"NaN",number:"n\u1ECD\u0301mb\xE0",array:"akop\u1ECD"};return(q)=>{switch(q.code){case"invalid_type":{let I=G[q.expected]??q.expected,Q=X$(q.input),D=G[Q]??Q;if(/^[A-Z]/.test(q.expected))return`\xCCb\xE1w\u1ECDl\xE9 a\u1E63\xEC\u1E63e: a n\xED l\xE1ti fi instanceof ${q.expected}, \xE0m\u1ECD\u0300 a r\xED ${D}`;return`\xCCb\xE1w\u1ECDl\xE9 a\u1E63\xEC\u1E63e: a n\xED l\xE1ti fi ${I}, \xE0m\u1ECD\u0300 a r\xED ${D}`}case"invalid_value":if(q.values.length===1)return`\xCCb\xE1w\u1ECDl\xE9 a\u1E63\xEC\u1E63e: a n\xED l\xE1ti fi ${Q$(q.values[0])}`;return`\xC0\u1E63\xE0y\xE0n a\u1E63\xEC\u1E63e: yan \u1ECD\u0300kan l\xE1ra ${n(q.values,"|")}`;case"too_big":{let I=q.inclusive?"<=":"<",Q=U(q.origin);if(Q)return`T\xF3 p\u1ECD\u0300 j\xF9: a n\xED l\xE1ti j\u1EB9\u0301 p\xE9 ${q.origin??"iye"} ${Q.verb} ${I}${q.maximum} ${Q.unit}`;return`T\xF3 p\u1ECD\u0300 j\xF9: a n\xED l\xE1ti j\u1EB9\u0301 ${I}${q.maximum}`}case"too_small":{let I=q.inclusive?">=":">",Q=U(q.origin);if(Q)return`K\xE9r\xE9 ju: a n\xED l\xE1ti j\u1EB9\u0301 p\xE9 ${q.origin} ${Q.verb} ${I}${q.minimum} ${Q.unit}`;return`K\xE9r\xE9 ju: a n\xED l\xE1ti j\u1EB9\u0301 ${I}${q.minimum}`}case"invalid_format":{let I=q;if(I.format==="starts_with")return`\u1ECC\u0300r\u1ECD\u0300 a\u1E63\xEC\u1E63e: gb\u1ECD\u0301d\u1ECD\u0300 b\u1EB9\u0300r\u1EB9\u0300 p\u1EB9\u0300l\xFA "${I.prefix}"`;if(I.format==="ends_with")return`\u1ECC\u0300r\u1ECD\u0300 a\u1E63\xEC\u1E63e: gb\u1ECD\u0301d\u1ECD\u0300 par\xED p\u1EB9\u0300l\xFA "${I.suffix}"`;if(I.format==="includes")return`\u1ECC\u0300r\u1ECD\u0300 a\u1E63\xEC\u1E63e: gb\u1ECD\u0301d\u1ECD\u0300 n\xED "${I.includes}"`;if(I.format==="regex")return`\u1ECC\u0300r\u1ECD\u0300 a\u1E63\xEC\u1E63e: gb\u1ECD\u0301d\u1ECD\u0300 b\xE1 \xE0p\u1EB9\u1EB9r\u1EB9 mu ${I.pattern}`;return`A\u1E63\xEC\u1E63e: ${J[I.format]??q.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 ${q.divisor}`;case"unrecognized_keys":return`B\u1ECDt\xECn\xEC \xE0\xECm\u1ECD\u0300: ${n(q.keys,", ")}`;case"invalid_key":return`B\u1ECDt\xECn\xEC a\u1E63\xEC\u1E63e n\xEDn\xFA ${q.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 ${q.origin}`;default:return"\xCCb\xE1w\u1ECDl\xE9 a\u1E63\xEC\u1E63e"}}};var TA=O$(()=>{g$()});var I4={};UU(I4,{zhTW:()=>r1,zhCN:()=>h1,yo:()=>l1,vi:()=>m1,uz:()=>y1,ur:()=>f1,uk:()=>G4,ua:()=>x1,tr:()=>u1,th:()=>b1,ta:()=>F1,sv:()=>v1,sl:()=>_1,ru:()=>C1,ro:()=>E1,pt:()=>L1,ps:()=>B1,pl:()=>S1,ota:()=>P1,no:()=>j1,nl:()=>g1,ms:()=>K1,mk:()=>A1,lt:()=>z1,ko:()=>T1,km:()=>J4,kh:()=>H1,ka:()=>w1,ja:()=>N1,it:()=>R1,is:()=>Z1,id:()=>O1,hy:()=>W1,hu:()=>V1,hr:()=>Y1,he:()=>X1,frCA:()=>D1,fr:()=>Q1,fi:()=>I1,fa:()=>G1,es:()=>q1,eo:()=>J1,en:()=>U4,el:()=>$1,de:()=>eO,da:()=>tO,cs:()=>sO,ca:()=>aO,bg:()=>oO,be:()=>cO,az:()=>nO,ar:()=>dO});var i1=O$(()=>{Az();Kz();jz();Pz();Bz();Sz();Lz();Ez();Cz();U1();_z();vz();Fz();bz();uz();kz();xz();fz();yz();hz();rz();lz();iz();pz();dz();nz();M1();cz();az();sz();tz();ez();$A();UA();JA();qA();GA();IA();DA();XA();YA();VA();WA();OA();ZA();k1();RA();NA();wA();MA();HA();TA()});class n1{constructor(){this._map=new WeakMap,this._idmap=new Map}add($,...U){let J=U[0];if(this._map.set($,J),J&&typeof J==="object"&&"id"in J)this._idmap.set(J.id,$);return this}clear(){return this._map=new WeakMap,this._idmap=new Map,this}remove($){let U=this._map.get($);if(U&&typeof U==="object"&&"id"in U)this._idmap.delete(U.id);return this._map.delete($),this}get($){let U=$._zod.parent;if(U){let J={...this.get(U)??{}};delete J.id;let G={...J,...this._map.get($)};return Object.keys(G).length?G:void 0}return this._map.get($)}has($){return this._map.has($)}}function pQ(){return new n1}var zA,p1,d1,w0;var Q4=O$(()=>{p1=Symbol("ZodOutput"),d1=Symbol("ZodInput");(zA=globalThis).__zod_globalRegistry??(zA.__zod_globalRegistry=pQ());w0=globalThis.__zod_globalRegistry});function c1($,U){return new $({type:"string",...Z$(U)})}function o1($,U){return new $({type:"string",coerce:!0,...Z$(U)})}function dQ($,U){return new $({type:"string",format:"email",check:"string_format",abort:!1,...Z$(U)})}function D4($,U){return new $({type:"string",format:"guid",check:"string_format",abort:!1,...Z$(U)})}function nQ($,U){return new $({type:"string",format:"uuid",check:"string_format",abort:!1,...Z$(U)})}function cQ($,U){return new $({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v4",...Z$(U)})}function oQ($,U){return new $({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v6",...Z$(U)})}function aQ($,U){return new $({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v7",...Z$(U)})}function X4($,U){return new $({type:"string",format:"url",check:"string_format",abort:!1,...Z$(U)})}function sQ($,U){return new $({type:"string",format:"emoji",check:"string_format",abort:!1,...Z$(U)})}function tQ($,U){return new $({type:"string",format:"nanoid",check:"string_format",abort:!1,...Z$(U)})}function eQ($,U){return new $({type:"string",format:"cuid",check:"string_format",abort:!1,...Z$(U)})}function $D($,U){return new $({type:"string",format:"cuid2",check:"string_format",abort:!1,...Z$(U)})}function UD($,U){return new $({type:"string",format:"ulid",check:"string_format",abort:!1,...Z$(U)})}function JD($,U){return new $({type:"string",format:"xid",check:"string_format",abort:!1,...Z$(U)})}function qD($,U){return new $({type:"string",format:"ksuid",check:"string_format",abort:!1,...Z$(U)})}function GD($,U){return new $({type:"string",format:"ipv4",check:"string_format",abort:!1,...Z$(U)})}function ID($,U){return new $({type:"string",format:"ipv6",check:"string_format",abort:!1,...Z$(U)})}function a1($,U){return new $({type:"string",format:"mac",check:"string_format",abort:!1,...Z$(U)})}function QD($,U){return new $({type:"string",format:"cidrv4",check:"string_format",abort:!1,...Z$(U)})}function DD($,U){return new $({type:"string",format:"cidrv6",check:"string_format",abort:!1,...Z$(U)})}function XD($,U){return new $({type:"string",format:"base64",check:"string_format",abort:!1,...Z$(U)})}function YD($,U){return new $({type:"string",format:"base64url",check:"string_format",abort:!1,...Z$(U)})}function VD($,U){return new $({type:"string",format:"e164",check:"string_format",abort:!1,...Z$(U)})}function WD($,U){return new $({type:"string",format:"jwt",check:"string_format",abort:!1,...Z$(U)})}function t1($,U){return new $({type:"string",format:"datetime",check:"string_format",offset:!1,local:!1,precision:null,...Z$(U)})}function e1($,U){return new $({type:"string",format:"date",check:"string_format",...Z$(U)})}function $Z($,U){return new $({type:"string",format:"time",check:"string_format",precision:null,...Z$(U)})}function UZ($,U){return new $({type:"string",format:"duration",check:"string_format",...Z$(U)})}function JZ($,U){return new $({type:"number",checks:[],...Z$(U)})}function qZ($,U){return new $({type:"number",coerce:!0,checks:[],...Z$(U)})}function GZ($,U){return new $({type:"number",check:"number_format",abort:!1,format:"safeint",...Z$(U)})}function IZ($,U){return new $({type:"number",check:"number_format",abort:!1,format:"float32",...Z$(U)})}function QZ($,U){return new $({type:"number",check:"number_format",abort:!1,format:"float64",...Z$(U)})}function DZ($,U){return new $({type:"number",check:"number_format",abort:!1,format:"int32",...Z$(U)})}function XZ($,U){return new $({type:"number",check:"number_format",abort:!1,format:"uint32",...Z$(U)})}function YZ($,U){return new $({type:"boolean",...Z$(U)})}function VZ($,U){return new $({type:"boolean",coerce:!0,...Z$(U)})}function WZ($,U){return new $({type:"bigint",...Z$(U)})}function OZ($,U){return new $({type:"bigint",coerce:!0,...Z$(U)})}function ZZ($,U){return new $({type:"bigint",check:"bigint_format",abort:!1,format:"int64",...Z$(U)})}function RZ($,U){return new $({type:"bigint",check:"bigint_format",abort:!1,format:"uint64",...Z$(U)})}function NZ($,U){return new $({type:"symbol",...Z$(U)})}function wZ($,U){return new $({type:"undefined",...Z$(U)})}function MZ($,U){return new $({type:"null",...Z$(U)})}function HZ($){return new $({type:"any"})}function TZ($){return new $({type:"unknown"})}function zZ($,U){return new $({type:"never",...Z$(U)})}function AZ($,U){return new $({type:"void",...Z$(U)})}function KZ($,U){return new $({type:"date",...Z$(U)})}function gZ($,U){return new $({type:"date",coerce:!0,...Z$(U)})}function jZ($,U){return new $({type:"nan",...Z$(U)})}function dU($,U){return new vQ({check:"less_than",...Z$(U),value:$,inclusive:!1})}function ZU($,U){return new vQ({check:"less_than",...Z$(U),value:$,inclusive:!0})}function nU($,U){return new FQ({check:"greater_than",...Z$(U),value:$,inclusive:!1})}function i0($,U){return new FQ({check:"greater_than",...Z$(U),value:$,inclusive:!0})}function OD($){return nU(0,$)}function ZD($){return dU(0,$)}function RD($){return ZU(0,$)}function ND($){return i0(0,$)}function lJ($,U){return new NW({check:"multiple_of",...Z$(U),value:$})}function iJ($,U){return new HW({check:"max_size",...Z$(U),maximum:$})}function cU($,U){return new TW({check:"min_size",...Z$(U),minimum:$})}function yq($,U){return new zW({check:"size_equals",...Z$(U),size:$})}function mq($,U){return new AW({check:"max_length",...Z$(U),maximum:$})}function OJ($,U){return new KW({check:"min_length",...Z$(U),minimum:$})}function hq($,U){return new gW({check:"length_equals",...Z$(U),length:$})}function J8($,U){return new jW({check:"string_format",format:"regex",...Z$(U),pattern:$})}function q8($){return new PW({check:"string_format",format:"lowercase",...Z$($)})}function G8($){return new BW({check:"string_format",format:"uppercase",...Z$($)})}function I8($,U){return new SW({check:"string_format",format:"includes",...Z$(U),includes:$})}function Q8($,U){return new LW({check:"string_format",format:"starts_with",...Z$(U),prefix:$})}function D8($,U){return new EW({check:"string_format",format:"ends_with",...Z$(U),suffix:$})}function wD($,U,J){return new CW({check:"property",property:$,schema:U,...Z$(J)})}function X8($,U){return new _W({check:"mime_type",mime:$,...Z$(U)})}function uU($){return new vW({check:"overwrite",tx:$})}function Y8($){return uU((U)=>U.normalize($))}function V8(){return uU(($)=>$.trim())}function W8(){return uU(($)=>$.toLowerCase())}function O8(){return uU(($)=>$.toUpperCase())}function Z8(){return uU(($)=>BV($))}function PZ($,U,J){return new $({type:"array",element:U,...Z$(J)})}function mu($,U,J){return new $({type:"union",options:U,...Z$(J)})}function hu($,U,J){return new $({type:"union",options:U,inclusive:!1,...Z$(J)})}function ru($,U,J,G){return new $({type:"union",options:J,discriminator:U,...Z$(G)})}function lu($,U,J){return new $({type:"intersection",left:U,right:J})}function iu($,U,J,G){let q=J instanceof E$;return new $({type:"tuple",items:U,rest:q?J:null,...Z$(q?G:J)})}function pu($,U,J,G){return new $({type:"record",keyType:U,valueType:J,...Z$(G)})}function du($,U,J,G){return new $({type:"map",keyType:U,valueType:J,...Z$(G)})}function nu($,U,J){return new $({type:"set",valueType:U,...Z$(J)})}function cu($,U,J){let G=Array.isArray(U)?Object.fromEntries(U.map((q)=>[q,q])):U;return new $({type:"enum",entries:G,...Z$(J)})}function ou($,U,J){return new $({type:"enum",entries:U,...Z$(J)})}function au($,U,J){return new $({type:"literal",values:Array.isArray(U)?U:[U],...Z$(J)})}function BZ($,U){return new $({type:"file",...Z$(U)})}function su($,U){return new $({type:"transform",transform:U})}function tu($,U){return new $({type:"optional",innerType:U})}function eu($,U){return new $({type:"nullable",innerType:U})}function $k($,U,J){return new $({type:"default",innerType:U,get defaultValue(){return typeof J==="function"?J():LV(J)}})}function Uk($,U,J){return new $({type:"nonoptional",innerType:U,...Z$(J)})}function Jk($,U){return new $({type:"success",innerType:U})}function qk($,U,J){return new $({type:"catch",innerType:U,catchValue:typeof J==="function"?J:()=>J})}function Gk($,U,J){return new $({type:"pipe",in:U,out:J})}function Ik($,U){return new $({type:"readonly",innerType:U})}function Qk($,U,J){return new $({type:"template_literal",parts:U,...Z$(J)})}function Dk($,U){return new $({type:"lazy",getter:U})}function Xk($,U){return new $({type:"promise",innerType:U})}function SZ($,U,J){let G=Z$(J);return G.abort??(G.abort=!0),new $({type:"custom",check:"custom",fn:U,...G})}function LZ($,U,J){return new $({type:"custom",check:"custom",fn:U,...Z$(J)})}function EZ($,U){let J=AA((G)=>{return G.addIssue=(q)=>{if(typeof q==="string")G.issues.push(oG(q,G.value,J._zod.def));else{let I=q;if(I.fatal)I.continue=!1;I.code??(I.code="custom"),I.input??(I.input=G.value),I.inst??(I.inst=J),I.continue??(I.continue=!J._zod.def.abort),G.issues.push(oG(I))}},$(G.value,G)},U);return J}function AA($,U){let J=new p$({check:"custom",...Z$(U)});return J._zod.check=$,J}function CZ($){let U=new p$({check:"describe"});return U._zod.onattach=[(J)=>{let G=w0.get(J)??{};w0.add(J,{...G,description:$})}],U._zod.check=()=>{},U}function _Z($){let U=new p$({check:"meta"});return U._zod.onattach=[(J)=>{let G=w0.get(J)??{};w0.add(J,{...G,...$})}],U._zod.check=()=>{},U}function vZ($,U){let J=Z$(U),G=J.truthy??["true","1","yes","on","y","enabled"],q=J.falsy??["false","0","no","off","n","disabled"];if(J.case!=="sensitive")G=G.map((Z)=>typeof Z==="string"?Z.toLowerCase():Z),q=q.map((Z)=>typeof Z==="string"?Z.toLowerCase():Z);let I=new Set(G),Q=new Set(q),D=$.Codec??$4,X=$.Boolean??t6,V=new($.String??fq)({type:"string",error:J.error}),W=new X({type:"boolean",error:J.error}),O=new D({type:"pipe",in:V,out:W,transform:(Z,M)=>{let w=Z;if(J.case!=="sensitive")w=w.toLowerCase();if(I.has(w))return!0;else if(Q.has(w))return!1;else return M.issues.push({code:"invalid_value",expected:"stringbool",values:[...I,...Q],input:M.value,inst:O,continue:!1}),{}},reverseTransform:(Z,M)=>{if(Z===!0)return G[0]||"true";else return q[0]||"false"},error:J.error});return O}function R8($,U,J,G={}){let q=Z$(G),I={...Z$(G),check:"string_format",type:"string",format:U,fn:typeof J==="function"?J:(D)=>J.test(D),...q};if(J instanceof RegExp)I.pattern=J;return new $(I)}var s1;var KA=O$(()=>{bQ();Q4();pO();g$();s1={Any:null,Minute:-1,Second:0,Millisecond:3,Microsecond:6}});function pJ($){let U=$?.target??"draft-2020-12";if(U==="draft-4")U="draft-04";if(U==="draft-7")U="draft-07";return{processors:$.processors??{},metadataRegistry:$?.metadata??w0,target:U,unrepresentable:$?.unrepresentable??"throw",override:$?.override??(()=>{}),io:$?.io??"output",counter:0,seen:new Map,cycles:$?.cycles??"ref",reused:$?.reused??"inline",external:$?.external??void 0}}function h$($,U,J={path:[],schemaPath:[]}){var G;let q=$._zod.def,I=U.seen.get($);if(I){if(I.count++,J.schemaPath.includes($))I.cycle=J.path;return I.schema}let Q={schema:{},count:1,cycle:void 0,path:J.path};U.seen.set($,Q);let D=$._zod.toJSONSchema?.();if(D)Q.schema=D;else{let V={...J,schemaPath:[...J.schemaPath,$],path:J.path};if($._zod.processJSONSchema)$._zod.processJSONSchema(U,Q.schema,V);else{let O=Q.schema,Z=U.processors[q.type];if(!Z)throw Error(`[toJSONSchema]: Non-representable type encountered: ${q.type}`);Z($,U,O,V)}let W=$._zod.parent;if(W){if(!Q.ref)Q.ref=W;h$(W,U,V),U.seen.get(W).isParent=!0}}let X=U.metadataRegistry.get($);if(X)Object.assign(Q.schema,X);if(U.io==="input"&&p0($))delete Q.schema.examples,delete Q.schema.default;if(U.io==="input"&&"_prefault"in Q.schema)(G=Q.schema).default??(G.default=Q.schema._prefault);return delete Q.schema._prefault,U.seen.get($).schema}function dJ($,U){let J=$.seen.get(U);if(!J)throw Error("Unprocessed schema. This is a bug in Zod.");let G=new Map;for(let Q of $.seen.entries()){let D=$.metadataRegistry.get(Q[0])?.id;if(D){let X=G.get(D);if(X&&X!==Q[0])throw Error(`Duplicate schema id "${D}" detected during JSON Schema conversion. Two different schemas cannot share the same id when converted together.`);G.set(D,Q[0])}}let q=(Q)=>{let D=$.target==="draft-2020-12"?"$defs":"definitions";if($.external){let W=$.external.registry.get(Q[0])?.id,O=$.external.uri??((M)=>M);if(W)return{ref:O(W)};let Z=Q[1].defId??Q[1].schema.id??`schema${$.counter++}`;return Q[1].defId=Z,{defId:Z,ref:`${O("__shared")}#/${D}/${Z}`}}if(Q[1]===J)return{ref:"#"};let Y=`${"#"}/${D}/`,V=Q[1].schema.id??`__schema${$.counter++}`;return{defId:V,ref:Y+V}},I=(Q)=>{if(Q[1].schema.$ref)return;let D=Q[1],{ref:X,defId:Y}=q(Q);if(D.def={...D.schema},Y)D.defId=Y;let V=D.schema;for(let W in V)delete V[W];V.$ref=X};if($.cycles==="throw")for(let Q of $.seen.entries()){let D=Q[1];if(D.cycle)throw Error(`Cycle detected: #/${D.cycle?.join("/")}/<root>
|
|
96
|
+
|
|
97
|
+
Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`)}for(let Q of $.seen.entries()){let D=Q[1];if(U===Q[0]){I(Q);continue}if($.external){let Y=$.external.registry.get(Q[0])?.id;if(U!==Q[0]&&Y){I(Q);continue}}if($.metadataRegistry.get(Q[0])?.id){I(Q);continue}if(D.cycle){I(Q);continue}if(D.count>1){if($.reused==="ref"){I(Q);continue}}}}function nJ($,U){let J=$.seen.get(U);if(!J)throw Error("Unprocessed schema. This is a bug in Zod.");let G=(D)=>{let X=$.seen.get(D);if(X.ref===null)return;let Y=X.def??X.schema,V={...Y},W=X.ref;if(X.ref=null,W){G(W);let Z=$.seen.get(W),M=Z.schema;if(M.$ref&&($.target==="draft-07"||$.target==="draft-04"||$.target==="openapi-3.0"))Y.allOf=Y.allOf??[],Y.allOf.push(M);else Object.assign(Y,M);if(Object.assign(Y,V),D._zod.parent===W)for(let H in Y){if(H==="$ref"||H==="allOf")continue;if(!(H in V))delete Y[H]}if(M.$ref&&Z.def)for(let H in Y){if(H==="$ref"||H==="allOf")continue;if(H in Z.def&&JSON.stringify(Y[H])===JSON.stringify(Z.def[H]))delete Y[H]}}let O=D._zod.parent;if(O&&O!==W){G(O);let Z=$.seen.get(O);if(Z?.schema.$ref){if(Y.$ref=Z.schema.$ref,Z.def)for(let M in Y){if(M==="$ref"||M==="allOf")continue;if(M in Z.def&&JSON.stringify(Y[M])===JSON.stringify(Z.def[M]))delete Y[M]}}}$.override({zodSchema:D,jsonSchema:Y,path:X.path??[]})};for(let D of[...$.seen.entries()].reverse())G(D[0]);let q={};if($.target==="draft-2020-12")q.$schema="https://json-schema.org/draft/2020-12/schema";else if($.target==="draft-07")q.$schema="http://json-schema.org/draft-07/schema#";else if($.target==="draft-04")q.$schema="http://json-schema.org/draft-04/schema#";else if($.target==="openapi-3.0");if($.external?.uri){let D=$.external.registry.get(U)?.id;if(!D)throw Error("Schema is missing an `id` property");q.$id=$.external.uri(D)}Object.assign(q,J.def??J.schema);let I=$.metadataRegistry.get(U)?.id;if(I!==void 0&&q.id===I)delete q.id;let Q=$.external?.defs??{};for(let D of $.seen.entries()){let X=D[1];if(X.def&&X.defId){if(X.def.id===X.defId)delete X.def.id;Q[X.defId]=X.def}}if($.external);else if(Object.keys(Q).length>0)if($.target==="draft-2020-12")q.$defs=Q;else q.definitions=Q;try{let D=JSON.parse(JSON.stringify(q));return Object.defineProperty(D,"~standard",{value:{...U["~standard"],jsonSchema:{input:N8(U,"input",$.processors),output:N8(U,"output",$.processors)}},enumerable:!1,writable:!1}),D}catch(D){throw Error("Error converting schema to JSON.")}}function p0($,U){let J=U??{seen:new Set};if(J.seen.has($))return!1;J.seen.add($);let G=$._zod.def;if(G.type==="transform")return!0;if(G.type==="array")return p0(G.element,J);if(G.type==="set")return p0(G.valueType,J);if(G.type==="lazy")return p0(G.getter(),J);if(G.type==="promise"||G.type==="optional"||G.type==="nonoptional"||G.type==="nullable"||G.type==="readonly"||G.type==="default"||G.type==="prefault")return p0(G.innerType,J);if(G.type==="intersection")return p0(G.left,J)||p0(G.right,J);if(G.type==="record"||G.type==="map")return p0(G.keyType,J)||p0(G.valueType,J);if(G.type==="pipe"){if($._zod.traits.has("$ZodCodec"))return!0;return p0(G.in,J)||p0(G.out,J)}if(G.type==="object"){for(let q in G.shape)if(p0(G.shape[q],J))return!0;return!1}if(G.type==="union"){for(let q of G.options)if(p0(q,J))return!0;return!1}if(G.type==="tuple"){for(let q of G.items)if(p0(q,J))return!0;if(G.rest&&p0(G.rest,J))return!0;return!1}return!1}var FZ=($,U={})=>(J)=>{let G=pJ({...J,processors:U});return h$($,G),dJ(G,$),nJ(G,$)},N8=($,U,J={})=>(G)=>{let{libraryOptions:q,target:I}=G??{},Q=pJ({...q??{},target:I,io:U,processors:J});return h$($,Q),dJ(Q,$),nJ(Q,$)};var Y4=O$(()=>{Q4()});function zD($,U){if("_idmap"in $){let G=$,q=pJ({...U,processors:MD}),I={};for(let X of G._idmap.entries()){let[Y,V]=X;h$(V,q)}let Q={},D={registry:G,uri:U?.uri,defs:I};q.external=D;for(let X of G._idmap.entries()){let[Y,V]=X;dJ(q,V),Q[Y]=nJ(q,V)}if(Object.keys(I).length>0){let X=q.target==="draft-2020-12"?"$defs":"definitions";Q.__shared={[X]:I}}return{schemas:Q}}let J=pJ({...U,processors:MD});return h$($,J),dJ(J,$),nJ(J,$)}var Yk,bZ=($,U,J,G)=>{let q=J;q.type="string";let{minimum:I,maximum:Q,format:D,patterns:X,contentEncoding:Y}=$._zod.bag;if(typeof I==="number")q.minLength=I;if(typeof Q==="number")q.maxLength=Q;if(D){if(q.format=Yk[D]??D,q.format==="")delete q.format;if(D==="time")delete q.format}if(Y)q.contentEncoding=Y;if(X&&X.size>0){let V=[...X];if(V.length===1)q.pattern=V[0].source;else if(V.length>1)q.allOf=[...V.map((W)=>({...U.target==="draft-07"||U.target==="draft-04"||U.target==="openapi-3.0"?{type:"string"}:{},pattern:W.source}))]}},uZ=($,U,J,G)=>{let q=J,{minimum:I,maximum:Q,format:D,multipleOf:X,exclusiveMaximum:Y,exclusiveMinimum:V}=$._zod.bag;if(typeof D==="string"&&D.includes("int"))q.type="integer";else q.type="number";let W=typeof V==="number"&&V>=(I??Number.NEGATIVE_INFINITY),O=typeof Y==="number"&&Y<=(Q??Number.POSITIVE_INFINITY),Z=U.target==="draft-04"||U.target==="openapi-3.0";if(W)if(Z)q.minimum=V,q.exclusiveMinimum=!0;else q.exclusiveMinimum=V;else if(typeof I==="number")q.minimum=I;if(O)if(Z)q.maximum=Y,q.exclusiveMaximum=!0;else q.exclusiveMaximum=Y;else if(typeof Q==="number")q.maximum=Q;if(typeof X==="number")q.multipleOf=X},kZ=($,U,J,G)=>{J.type="boolean"},xZ=($,U,J,G)=>{if(U.unrepresentable==="throw")throw Error("BigInt cannot be represented in JSON Schema")},fZ=($,U,J,G)=>{if(U.unrepresentable==="throw")throw Error("Symbols cannot be represented in JSON Schema")},yZ=($,U,J,G)=>{if(U.target==="openapi-3.0")J.type="string",J.nullable=!0,J.enum=[null];else J.type="null"},mZ=($,U,J,G)=>{if(U.unrepresentable==="throw")throw Error("Undefined cannot be represented in JSON Schema")},hZ=($,U,J,G)=>{if(U.unrepresentable==="throw")throw Error("Void cannot be represented in JSON Schema")},rZ=($,U,J,G)=>{J.not={}},lZ=($,U,J,G)=>{},iZ=($,U,J,G)=>{},pZ=($,U,J,G)=>{if(U.unrepresentable==="throw")throw Error("Date cannot be represented in JSON Schema")},dZ=($,U,J,G)=>{let q=$._zod.def,I=h6(q.entries);if(I.every((Q)=>typeof Q==="number"))J.type="number";if(I.every((Q)=>typeof Q==="string"))J.type="string";J.enum=I},nZ=($,U,J,G)=>{let q=$._zod.def,I=[];for(let Q of q.values)if(Q===void 0){if(U.unrepresentable==="throw")throw Error("Literal `undefined` cannot be represented in JSON Schema")}else if(typeof Q==="bigint")if(U.unrepresentable==="throw")throw Error("BigInt literals cannot be represented in JSON Schema");else I.push(Number(Q));else I.push(Q);if(I.length===0);else if(I.length===1){let Q=I[0];if(J.type=Q===null?"null":typeof Q,U.target==="draft-04"||U.target==="openapi-3.0")J.enum=[Q];else J.const=Q}else{if(I.every((Q)=>typeof Q==="number"))J.type="number";if(I.every((Q)=>typeof Q==="string"))J.type="string";if(I.every((Q)=>typeof Q==="boolean"))J.type="boolean";if(I.every((Q)=>Q===null))J.type="null";J.enum=I}},cZ=($,U,J,G)=>{if(U.unrepresentable==="throw")throw Error("NaN cannot be represented in JSON Schema")},oZ=($,U,J,G)=>{let q=J,I=$._zod.pattern;if(!I)throw Error("Pattern not found in template literal");q.type="string",q.pattern=I.source},aZ=($,U,J,G)=>{let q=J,I={type:"string",format:"binary",contentEncoding:"binary"},{minimum:Q,maximum:D,mime:X}=$._zod.bag;if(Q!==void 0)I.minLength=Q;if(D!==void 0)I.maxLength=D;if(X)if(X.length===1)I.contentMediaType=X[0],Object.assign(q,I);else Object.assign(q,I),q.anyOf=X.map((Y)=>({contentMediaType:Y}));else Object.assign(q,I)},sZ=($,U,J,G)=>{J.type="boolean"},tZ=($,U,J,G)=>{if(U.unrepresentable==="throw")throw Error("Custom types cannot be represented in JSON Schema")},eZ=($,U,J,G)=>{if(U.unrepresentable==="throw")throw Error("Function types cannot be represented in JSON Schema")},$R=($,U,J,G)=>{if(U.unrepresentable==="throw")throw Error("Transforms cannot be represented in JSON Schema")},UR=($,U,J,G)=>{if(U.unrepresentable==="throw")throw Error("Map cannot be represented in JSON Schema")},JR=($,U,J,G)=>{if(U.unrepresentable==="throw")throw Error("Set cannot be represented in JSON Schema")},qR=($,U,J,G)=>{let q=J,I=$._zod.def,{minimum:Q,maximum:D}=$._zod.bag;if(typeof Q==="number")q.minItems=Q;if(typeof D==="number")q.maxItems=D;q.type="array",q.items=h$(I.element,U,{...G,path:[...G.path,"items"]})},GR=($,U,J,G)=>{let q=J,I=$._zod.def;q.type="object",q.properties={};let Q=I.shape;for(let Y in Q)q.properties[Y]=h$(Q[Y],U,{...G,path:[...G.path,"properties",Y]});let D=new Set(Object.keys(Q)),X=new Set([...D].filter((Y)=>{let V=I.shape[Y]._zod;if(U.io==="input")return V.optin===void 0;else return V.optout===void 0}));if(X.size>0)q.required=Array.from(X);if(I.catchall?._zod.def.type==="never")q.additionalProperties=!1;else if(!I.catchall){if(U.io==="output")q.additionalProperties=!1}else if(I.catchall)q.additionalProperties=h$(I.catchall,U,{...G,path:[...G.path,"additionalProperties"]})},HD=($,U,J,G)=>{let q=$._zod.def,I=q.inclusive===!1,Q=q.options.map((D,X)=>h$(D,U,{...G,path:[...G.path,I?"oneOf":"anyOf",X]}));if(I)J.oneOf=Q;else J.anyOf=Q},IR=($,U,J,G)=>{let q=$._zod.def,I=h$(q.left,U,{...G,path:[...G.path,"allOf",0]}),Q=h$(q.right,U,{...G,path:[...G.path,"allOf",1]}),D=(Y)=>("allOf"in Y)&&Object.keys(Y).length===1,X=[...D(I)?I.allOf:[I],...D(Q)?Q.allOf:[Q]];J.allOf=X},QR=($,U,J,G)=>{let q=J,I=$._zod.def;q.type="array";let Q=U.target==="draft-2020-12"?"prefixItems":"items",D=U.target==="draft-2020-12"?"items":U.target==="openapi-3.0"?"items":"additionalItems",X=I.items.map((O,Z)=>h$(O,U,{...G,path:[...G.path,Q,Z]})),Y=I.rest?h$(I.rest,U,{...G,path:[...G.path,D,...U.target==="openapi-3.0"?[I.items.length]:[]]}):null;if(U.target==="draft-2020-12"){if(q.prefixItems=X,Y)q.items=Y}else if(U.target==="openapi-3.0"){if(q.items={anyOf:X},Y)q.items.anyOf.push(Y);if(q.minItems=X.length,!Y)q.maxItems=X.length}else if(q.items=X,Y)q.additionalItems=Y;let{minimum:V,maximum:W}=$._zod.bag;if(typeof V==="number")q.minItems=V;if(typeof W==="number")q.maxItems=W},DR=($,U,J,G)=>{let q=J,I=$._zod.def;q.type="object";let Q=I.keyType,X=Q._zod.bag?.patterns;if(I.mode==="loose"&&X&&X.size>0){let V=h$(I.valueType,U,{...G,path:[...G.path,"patternProperties","*"]});q.patternProperties={};for(let W of X)q.patternProperties[W.source]=V}else{if(U.target==="draft-07"||U.target==="draft-2020-12")q.propertyNames=h$(I.keyType,U,{...G,path:[...G.path,"propertyNames"]});q.additionalProperties=h$(I.valueType,U,{...G,path:[...G.path,"additionalProperties"]})}let Y=Q._zod.values;if(Y){let V=[...Y].filter((W)=>typeof W==="string"||typeof W==="number");if(V.length>0)q.required=V}},XR=($,U,J,G)=>{let q=$._zod.def,I=h$(q.innerType,U,G),Q=U.seen.get($);if(U.target==="openapi-3.0")Q.ref=q.innerType,J.nullable=!0;else J.anyOf=[I,{type:"null"}]},YR=($,U,J,G)=>{let q=$._zod.def;h$(q.innerType,U,G);let I=U.seen.get($);I.ref=q.innerType},VR=($,U,J,G)=>{let q=$._zod.def;h$(q.innerType,U,G);let I=U.seen.get($);I.ref=q.innerType,J.default=JSON.parse(JSON.stringify(q.defaultValue))},WR=($,U,J,G)=>{let q=$._zod.def;h$(q.innerType,U,G);let I=U.seen.get($);if(I.ref=q.innerType,U.io==="input")J._prefault=JSON.parse(JSON.stringify(q.defaultValue))},OR=($,U,J,G)=>{let q=$._zod.def;h$(q.innerType,U,G);let I=U.seen.get($);I.ref=q.innerType;let Q;try{Q=q.catchValue(void 0)}catch{throw Error("Dynamic catch values are not supported in JSON Schema")}J.default=Q},ZR=($,U,J,G)=>{let q=$._zod.def,I=q.in._zod.traits.has("$ZodTransform"),Q=U.io==="input"?I?q.out:q.in:q.out;h$(Q,U,G);let D=U.seen.get($);D.ref=Q},RR=($,U,J,G)=>{let q=$._zod.def;h$(q.innerType,U,G);let I=U.seen.get($);I.ref=q.innerType,J.readOnly=!0},NR=($,U,J,G)=>{let q=$._zod.def;h$(q.innerType,U,G);let I=U.seen.get($);I.ref=q.innerType},TD=($,U,J,G)=>{let q=$._zod.def;h$(q.innerType,U,G);let I=U.seen.get($);I.ref=q.innerType},wR=($,U,J,G)=>{let q=$._zod.innerType;h$(q,U,G);let I=U.seen.get($);I.ref=q},MD;var V4=O$(()=>{Y4();g$();Yk={guid:"uuid",url:"uri",datetime:"date-time",json_string:"json-string",regex:""},MD={string:bZ,number:uZ,boolean:kZ,bigint:xZ,symbol:fZ,null:yZ,undefined:mZ,void:hZ,never:rZ,any:lZ,unknown:iZ,date:pZ,enum:dZ,literal:nZ,nan:cZ,template_literal:oZ,file:aZ,success:sZ,custom:tZ,function:eZ,transform:$R,map:UR,set:JR,array:qR,object:GR,union:HD,intersection:IR,tuple:QR,record:DR,nullable:XR,nonoptional:YR,default:VR,prefault:WR,catch:OR,pipe:ZR,readonly:RR,promise:NR,optional:TD,lazy:wR}});class MR{get metadataRegistry(){return this.ctx.metadataRegistry}get target(){return this.ctx.target}get unrepresentable(){return this.ctx.unrepresentable}get override(){return this.ctx.override}get io(){return this.ctx.io}get counter(){return this.ctx.counter}set counter($){this.ctx.counter=$}get seen(){return this.ctx.seen}constructor($){let U=$?.target??"draft-2020-12";if(U==="draft-4")U="draft-04";if(U==="draft-7")U="draft-07";this.ctx=pJ({processors:MD,target:U,...$?.metadata&&{metadata:$.metadata},...$?.unrepresentable&&{unrepresentable:$.unrepresentable},...$?.override&&{override:$.override},...$?.io&&{io:$.io}})}process($,U={path:[],schemaPath:[]}){return h$($,this.ctx,U)}emit($,U){if(U){if(U.cycles)this.ctx.cycles=U.cycles;if(U.reused)this.ctx.reused=U.reused;if(U.external)this.ctx.external=U.external}dJ(this.ctx,$);let J=nJ(this.ctx,$),{"~standard":G,...q}=J;return q}}var gA=O$(()=>{V4();Y4()});var jA={};var PA=()=>{};var ZJ={};UU(ZJ,{version:()=>FW,util:()=>V$,treeifyError:()=>bV,toJSONSchema:()=>zD,toDotPath:()=>oT,safeParseAsync:()=>fV,safeParse:()=>xV,safeEncodeAsync:()=>Zb,safeEncode:()=>Wb,safeDecodeAsync:()=>Rb,safeDecode:()=>Ob,registry:()=>pQ,regexes:()=>OU,process:()=>h$,prettifyError:()=>uV,parseAsync:()=>AQ,parse:()=>zQ,meta:()=>_Z,locales:()=>I4,isValidJWT:()=>Mz,isValidBase64URL:()=>wz,isValidBase64:()=>JO,initializeContext:()=>pJ,globalRegistry:()=>w0,globalConfig:()=>Fq,formatError:()=>c6,flattenError:()=>n6,finalize:()=>nJ,extractDefs:()=>dJ,encodeAsync:()=>Yb,encode:()=>Db,describe:()=>CZ,decodeAsync:()=>Vb,decode:()=>Xb,createToJSONSchemaMethod:()=>FZ,createStandardJSONSchemaMethod:()=>N8,config:()=>a$,clone:()=>r0,_xor:()=>hu,_xid:()=>JD,_void:()=>AZ,_uuidv7:()=>aQ,_uuidv6:()=>oQ,_uuidv4:()=>cQ,_uuid:()=>nQ,_url:()=>X4,_uppercase:()=>G8,_unknown:()=>TZ,_union:()=>mu,_undefined:()=>wZ,_ulid:()=>UD,_uint64:()=>RZ,_uint32:()=>XZ,_tuple:()=>iu,_trim:()=>V8,_transform:()=>su,_toUpperCase:()=>O8,_toLowerCase:()=>W8,_templateLiteral:()=>Qk,_symbol:()=>NZ,_superRefine:()=>EZ,_success:()=>Jk,_stringbool:()=>vZ,_stringFormat:()=>R8,_string:()=>c1,_startsWith:()=>Q8,_slugify:()=>Z8,_size:()=>yq,_set:()=>nu,_safeParseAsync:()=>eG,_safeParse:()=>tG,_safeEncodeAsync:()=>LQ,_safeEncode:()=>BQ,_safeDecodeAsync:()=>EQ,_safeDecode:()=>SQ,_regex:()=>J8,_refine:()=>LZ,_record:()=>pu,_readonly:()=>Ik,_property:()=>wD,_promise:()=>Xk,_positive:()=>OD,_pipe:()=>Gk,_parseAsync:()=>sG,_parse:()=>aG,_overwrite:()=>uU,_optional:()=>tu,_number:()=>JZ,_nullable:()=>eu,_null:()=>MZ,_normalize:()=>Y8,_nonpositive:()=>RD,_nonoptional:()=>Uk,_nonnegative:()=>ND,_never:()=>zZ,_negative:()=>ZD,_nativeEnum:()=>ou,_nanoid:()=>tQ,_nan:()=>jZ,_multipleOf:()=>lJ,_minSize:()=>cU,_minLength:()=>OJ,_min:()=>i0,_mime:()=>X8,_maxSize:()=>iJ,_maxLength:()=>mq,_max:()=>ZU,_map:()=>du,_mac:()=>a1,_lte:()=>ZU,_lt:()=>dU,_lowercase:()=>q8,_literal:()=>au,_length:()=>hq,_lazy:()=>Dk,_ksuid:()=>qD,_jwt:()=>WD,_isoTime:()=>$Z,_isoDuration:()=>UZ,_isoDateTime:()=>t1,_isoDate:()=>e1,_ipv6:()=>ID,_ipv4:()=>GD,_intersection:()=>lu,_int64:()=>ZZ,_int32:()=>DZ,_int:()=>GZ,_includes:()=>I8,_guid:()=>D4,_gte:()=>i0,_gt:()=>nU,_float64:()=>QZ,_float32:()=>IZ,_file:()=>BZ,_enum:()=>cu,_endsWith:()=>D8,_encodeAsync:()=>jQ,_encode:()=>KQ,_emoji:()=>sQ,_email:()=>dQ,_e164:()=>VD,_discriminatedUnion:()=>ru,_default:()=>$k,_decodeAsync:()=>PQ,_decode:()=>gQ,_date:()=>KZ,_custom:()=>SZ,_cuid2:()=>$D,_cuid:()=>eQ,_coercedString:()=>o1,_coercedNumber:()=>qZ,_coercedDate:()=>gZ,_coercedBoolean:()=>VZ,_coercedBigint:()=>OZ,_cidrv6:()=>DD,_cidrv4:()=>QD,_check:()=>AA,_catch:()=>qk,_boolean:()=>YZ,_bigint:()=>WZ,_base64url:()=>YD,_base64:()=>XD,_array:()=>PZ,_any:()=>HZ,TimePrecision:()=>s1,NEVER:()=>KV,JSONSchemaGenerator:()=>MR,JSONSchema:()=>jA,Doc:()=>uQ,$output:()=>p1,$input:()=>d1,$constructor:()=>r,$brand:()=>gV,$ZodXor:()=>zO,$ZodXID:()=>pW,$ZodVoid:()=>wO,$ZodUnknown:()=>RO,$ZodUnion:()=>e6,$ZodUndefined:()=>WO,$ZodUUID:()=>xW,$ZodURL:()=>yW,$ZodULID:()=>iW,$ZodType:()=>E$,$ZodTuple:()=>rQ,$ZodTransform:()=>EO,$ZodTemplateLiteral:()=>mO,$ZodSymbol:()=>VO,$ZodSuccess:()=>uO,$ZodStringFormat:()=>r$,$ZodString:()=>fq,$ZodSet:()=>PO,$ZodRegistry:()=>n1,$ZodRecord:()=>gO,$ZodRealError:()=>qU,$ZodReadonly:()=>yO,$ZodPromise:()=>rO,$ZodPreprocess:()=>fO,$ZodPrefault:()=>FO,$ZodPipe:()=>iQ,$ZodOptional:()=>lQ,$ZodObjectJIT:()=>TO,$ZodObject:()=>zz,$ZodNumberFormat:()=>XO,$ZodNumber:()=>mQ,$ZodNullable:()=>_O,$ZodNull:()=>OO,$ZodNonOptional:()=>bO,$ZodNever:()=>NO,$ZodNanoID:()=>hW,$ZodNaN:()=>xO,$ZodMap:()=>jO,$ZodMAC:()=>eW,$ZodLiteral:()=>SO,$ZodLazy:()=>lO,$ZodKSUID:()=>dW,$ZodJWT:()=>QO,$ZodIntersection:()=>KO,$ZodISOTime:()=>oW,$ZodISODuration:()=>aW,$ZodISODateTime:()=>nW,$ZodISODate:()=>cW,$ZodIPv6:()=>tW,$ZodIPv4:()=>sW,$ZodGUID:()=>kW,$ZodFunction:()=>hO,$ZodFile:()=>LO,$ZodExactOptional:()=>CO,$ZodError:()=>d6,$ZodEnum:()=>BO,$ZodEncodeError:()=>bq,$ZodEmoji:()=>mW,$ZodEmail:()=>fW,$ZodE164:()=>IO,$ZodDiscriminatedUnion:()=>AO,$ZodDefault:()=>vO,$ZodDate:()=>MO,$ZodCustomStringFormat:()=>DO,$ZodCustom:()=>iO,$ZodCodec:()=>$4,$ZodCheckUpperCase:()=>BW,$ZodCheckStringFormat:()=>$8,$ZodCheckStartsWith:()=>LW,$ZodCheckSizeEquals:()=>zW,$ZodCheckRegex:()=>jW,$ZodCheckProperty:()=>CW,$ZodCheckOverwrite:()=>vW,$ZodCheckNumberFormat:()=>wW,$ZodCheckMultipleOf:()=>NW,$ZodCheckMinSize:()=>TW,$ZodCheckMinLength:()=>KW,$ZodCheckMimeType:()=>_W,$ZodCheckMaxSize:()=>HW,$ZodCheckMaxLength:()=>AW,$ZodCheckLowerCase:()=>PW,$ZodCheckLessThan:()=>vQ,$ZodCheckLengthEquals:()=>gW,$ZodCheckIncludes:()=>SW,$ZodCheckGreaterThan:()=>FQ,$ZodCheckEndsWith:()=>EW,$ZodCheckBigIntFormat:()=>MW,$ZodCheck:()=>p$,$ZodCatch:()=>kO,$ZodCUID2:()=>lW,$ZodCUID:()=>rW,$ZodCIDRv6:()=>UO,$ZodCIDRv4:()=>$O,$ZodBoolean:()=>t6,$ZodBigIntFormat:()=>YO,$ZodBigInt:()=>hQ,$ZodBase64URL:()=>GO,$ZodBase64:()=>qO,$ZodAsyncError:()=>pU,$ZodArray:()=>HO,$ZodAny:()=>ZO});var RU=O$(()=>{g$();_Q();i1();V4();gA();PA();uq();yV();kV();pO();bQ();bW();Q4();KA();Y4()});var AD={};UU(AD,{uppercase:()=>G8,trim:()=>V8,toUpperCase:()=>O8,toLowerCase:()=>W8,startsWith:()=>Q8,slugify:()=>Z8,size:()=>yq,regex:()=>J8,property:()=>wD,positive:()=>OD,overwrite:()=>uU,normalize:()=>Y8,nonpositive:()=>RD,nonnegative:()=>ND,negative:()=>ZD,multipleOf:()=>lJ,minSize:()=>cU,minLength:()=>OJ,mime:()=>X8,maxSize:()=>iJ,maxLength:()=>mq,lte:()=>ZU,lt:()=>dU,lowercase:()=>q8,length:()=>hq,includes:()=>I8,gte:()=>i0,gt:()=>nU,endsWith:()=>D8});var KD=O$(()=>{RU()});var w8={};UU(w8,{time:()=>zR,duration:()=>AR,datetime:()=>HR,date:()=>TR,ZodISOTime:()=>PD,ZodISODuration:()=>BD,ZodISODateTime:()=>gD,ZodISODate:()=>jD});function HR($){return t1(gD,$)}function TR($){return e1(jD,$)}function zR($){return $Z(PD,$)}function AR($){return UZ(BD,$)}var gD,jD,PD,BD;var W4=O$(()=>{RU();Z4();gD=r("ZodISODateTime",($,U)=>{nW.init($,U),l$.init($,U)});jD=r("ZodISODate",($,U)=>{cW.init($,U),l$.init($,U)});PD=r("ZodISOTime",($,U)=>{oW.init($,U),l$.init($,U)});BD=r("ZodISODuration",($,U)=>{aW.init($,U),l$.init($,U)})});var BA=($,U)=>{d6.init($,U),$.name="ZodError",Object.defineProperties($,{format:{value:(J)=>c6($,J)},flatten:{value:(J)=>n6($,J)},addIssue:{value:(J)=>{$.issues.push(J),$.message=JSON.stringify($.issues,nG,2)}},addIssues:{value:(J)=>{$.issues.push(...J),$.message=JSON.stringify($.issues,nG,2)}},isEmpty:{get(){return $.issues.length===0}}})},SA,GU;var KR=O$(()=>{RU();RU();g$();SA=r("ZodError",BA),GU=r("ZodError",BA,{Parent:Error})});var gR,jR,PR,BR,SR,LR,ER,CR,_R,vR,FR,bR;var uR=O$(()=>{RU();KR();gR=aG(GU),jR=sG(GU),PR=tG(GU),BR=eG(GU),SR=KQ(GU),LR=gQ(GU),ER=jQ(GU),CR=PQ(GU),_R=BQ(GU),vR=SQ(GU),FR=LQ(GU),bR=EQ(GU)});var O4={};UU(O4,{xor:()=>TK,xid:()=>rA,void:()=>ZK,uuidv7:()=>bA,uuidv6:()=>FA,uuidv4:()=>vA,uuid:()=>_A,url:()=>uA,unknown:()=>rq,union:()=>cD,undefined:()=>WK,ulid:()=>hA,uint64:()=>YK,uint32:()=>QK,tuple:()=>eR,transform:()=>aD,templateLiteral:()=>FK,symbol:()=>VK,superRefine:()=>S7,success:()=>EK,stringbool:()=>hK,stringFormat:()=>eA,string:()=>R4,strictObject:()=>MK,set:()=>jK,refine:()=>B7,record:()=>$7,readonly:()=>z7,promise:()=>bK,preprocess:()=>lK,prefault:()=>O7,pipe:()=>LD,partialRecord:()=>AK,optional:()=>w4,object:()=>wK,number:()=>xR,nullish:()=>LK,nullable:()=>M4,null:()=>rR,nonoptional:()=>Z7,never:()=>nD,nativeEnum:()=>PK,nanoid:()=>fA,nan:()=>CK,meta:()=>yK,map:()=>gK,mac:()=>pA,looseRecord:()=>KK,looseObject:()=>HK,literal:()=>BK,lazy:()=>g7,ksuid:()=>lA,keyof:()=>NK,jwt:()=>tA,json:()=>rK,ipv6:()=>dA,ipv4:()=>iA,invertCodec:()=>vK,intersection:()=>sR,int64:()=>XK,int32:()=>IK,int:()=>SD,instanceof:()=>mK,httpUrl:()=>kA,hostname:()=>$K,hex:()=>UK,hash:()=>JK,guid:()=>CA,function:()=>uK,float64:()=>GK,float32:()=>qK,file:()=>SK,exactOptional:()=>D7,enum:()=>oD,emoji:()=>xA,email:()=>EA,e164:()=>sA,discriminatedUnion:()=>zK,describe:()=>fK,date:()=>RK,custom:()=>xK,cuid2:()=>mA,cuid:()=>yA,codec:()=>_K,cidrv6:()=>cA,cidrv4:()=>nA,check:()=>kK,catch:()=>w7,boolean:()=>fR,bigint:()=>DK,base64url:()=>aA,base64:()=>oA,array:()=>A4,any:()=>OK,_function:()=>uK,_default:()=>V7,_ZodString:()=>ED,ZodXor:()=>cR,ZodXID:()=>kD,ZodVoid:()=>dR,ZodUnknown:()=>iR,ZodUnion:()=>g4,ZodUndefined:()=>mR,ZodUUID:()=>oU,ZodURL:()=>T4,ZodULID:()=>uD,ZodType:()=>v$,ZodTuple:()=>tR,ZodTransform:()=>I7,ZodTemplateLiteral:()=>A7,ZodSymbol:()=>yR,ZodSuccess:()=>R7,ZodStringFormat:()=>l$,ZodString:()=>T8,ZodSet:()=>J7,ZodRecord:()=>M8,ZodReadonly:()=>T7,ZodPromise:()=>j7,ZodPreprocess:()=>H7,ZodPrefault:()=>W7,ZodPipe:()=>j4,ZodOptional:()=>sD,ZodObject:()=>K4,ZodNumberFormat:()=>lq,ZodNumber:()=>A8,ZodNullable:()=>X7,ZodNull:()=>hR,ZodNonOptional:()=>tD,ZodNever:()=>pR,ZodNanoID:()=>vD,ZodNaN:()=>M7,ZodMap:()=>U7,ZodMAC:()=>kR,ZodLiteral:()=>q7,ZodLazy:()=>K7,ZodKSUID:()=>xD,ZodJWT:()=>pD,ZodIntersection:()=>aR,ZodIPv6:()=>yD,ZodIPv4:()=>fD,ZodGUID:()=>N4,ZodFunction:()=>P7,ZodFile:()=>G7,ZodExactOptional:()=>Q7,ZodEnum:()=>H8,ZodEmoji:()=>_D,ZodEmail:()=>CD,ZodE164:()=>iD,ZodDiscriminatedUnion:()=>oR,ZodDefault:()=>Y7,ZodDate:()=>z4,ZodCustomStringFormat:()=>z8,ZodCustom:()=>B4,ZodCodec:()=>P4,ZodCatch:()=>N7,ZodCUID2:()=>bD,ZodCUID:()=>FD,ZodCIDRv6:()=>hD,ZodCIDRv4:()=>mD,ZodBoolean:()=>K8,ZodBigIntFormat:()=>dD,ZodBigInt:()=>g8,ZodBase64URL:()=>lD,ZodBase64:()=>rD,ZodArray:()=>nR,ZodAny:()=>lR});function H4($,U,J){let G=Object.getPrototypeOf($),q=LA.get(G);if(!q)q=new Set,LA.set(G,q);if(q.has(U))return;q.add(U);for(let I in J){let Q=J[I];Object.defineProperty(G,I,{configurable:!0,enumerable:!1,get(){let D=Q.bind(this);return Object.defineProperty(this,I,{configurable:!0,writable:!0,enumerable:!0,value:D}),D},set(D){Object.defineProperty(this,I,{configurable:!0,writable:!0,enumerable:!0,value:D})}})}}function R4($){return c1(T8,$)}function EA($){return dQ(CD,$)}function CA($){return D4(N4,$)}function _A($){return nQ(oU,$)}function vA($){return cQ(oU,$)}function FA($){return oQ(oU,$)}function bA($){return aQ(oU,$)}function uA($){return X4(T4,$)}function kA($){return X4(T4,{protocol:OU.httpProtocol,hostname:OU.domain,...V$.normalizeParams($)})}function xA($){return sQ(_D,$)}function fA($){return tQ(vD,$)}function yA($){return eQ(FD,$)}function mA($){return $D(bD,$)}function hA($){return UD(uD,$)}function rA($){return JD(kD,$)}function lA($){return qD(xD,$)}function iA($){return GD(fD,$)}function pA($){return a1(kR,$)}function dA($){return ID(yD,$)}function nA($){return QD(mD,$)}function cA($){return DD(hD,$)}function oA($){return XD(rD,$)}function aA($){return YD(lD,$)}function sA($){return VD(iD,$)}function tA($){return WD(pD,$)}function eA($,U,J={}){return R8(z8,$,U,J)}function $K($){return R8(z8,"hostname",OU.hostname,$)}function UK($){return R8(z8,"hex",OU.hex,$)}function JK($,U){let J=U?.enc??"hex",G=`${$}_${J}`,q=OU[G];if(!q)throw Error(`Unrecognized hash format: ${G}`);return R8(z8,G,q,U)}function xR($){return JZ(A8,$)}function SD($){return GZ(lq,$)}function qK($){return IZ(lq,$)}function GK($){return QZ(lq,$)}function IK($){return DZ(lq,$)}function QK($){return XZ(lq,$)}function fR($){return YZ(K8,$)}function DK($){return WZ(g8,$)}function XK($){return ZZ(dD,$)}function YK($){return RZ(dD,$)}function VK($){return NZ(yR,$)}function WK($){return wZ(mR,$)}function rR($){return MZ(hR,$)}function OK(){return HZ(lR)}function rq(){return TZ(iR)}function nD($){return zZ(pR,$)}function ZK($){return AZ(dR,$)}function RK($){return KZ(z4,$)}function A4($,U){return PZ(nR,$,U)}function NK($){let U=$._zod.def.shape;return oD(Object.keys(U))}function wK($,U){let J={type:"object",shape:$??{},...V$.normalizeParams(U)};return new K4(J)}function MK($,U){return new K4({type:"object",shape:$,catchall:nD(),...V$.normalizeParams(U)})}function HK($,U){return new K4({type:"object",shape:$,catchall:rq(),...V$.normalizeParams(U)})}function cD($,U){return new g4({type:"union",options:$,...V$.normalizeParams(U)})}function TK($,U){return new cR({type:"union",options:$,inclusive:!1,...V$.normalizeParams(U)})}function zK($,U,J){return new oR({type:"union",options:U,discriminator:$,...V$.normalizeParams(J)})}function sR($,U){return new aR({type:"intersection",left:$,right:U})}function eR($,U,J){let G=U instanceof E$,q=G?J:U;return new tR({type:"tuple",items:$,rest:G?U:null,...V$.normalizeParams(q)})}function $7($,U,J){if(!U||!U._zod)return new M8({type:"record",keyType:R4(),valueType:$,...V$.normalizeParams(U)});return new M8({type:"record",keyType:$,valueType:U,...V$.normalizeParams(J)})}function AK($,U,J){let G=r0($);return G._zod.values=void 0,new M8({type:"record",keyType:G,valueType:U,...V$.normalizeParams(J)})}function KK($,U,J){return new M8({type:"record",keyType:$,valueType:U,mode:"loose",...V$.normalizeParams(J)})}function gK($,U,J){return new U7({type:"map",keyType:$,valueType:U,...V$.normalizeParams(J)})}function jK($,U){return new J7({type:"set",valueType:$,...V$.normalizeParams(U)})}function oD($,U){let J=Array.isArray($)?Object.fromEntries($.map((G)=>[G,G])):$;return new H8({type:"enum",entries:J,...V$.normalizeParams(U)})}function PK($,U){return new H8({type:"enum",entries:$,...V$.normalizeParams(U)})}function BK($,U){return new q7({type:"literal",values:Array.isArray($)?$:[$],...V$.normalizeParams(U)})}function SK($){return BZ(G7,$)}function aD($){return new I7({type:"transform",transform:$})}function w4($){return new sD({type:"optional",innerType:$})}function D7($){return new Q7({type:"optional",innerType:$})}function M4($){return new X7({type:"nullable",innerType:$})}function LK($){return w4(M4($))}function V7($,U){return new Y7({type:"default",innerType:$,get defaultValue(){return typeof U==="function"?U():V$.shallowClone(U)}})}function O7($,U){return new W7({type:"prefault",innerType:$,get defaultValue(){return typeof U==="function"?U():V$.shallowClone(U)}})}function Z7($,U){return new tD({type:"nonoptional",innerType:$,...V$.normalizeParams(U)})}function EK($){return new R7({type:"success",innerType:$})}function w7($,U){return new N7({type:"catch",innerType:$,catchValue:typeof U==="function"?U:()=>U})}function CK($){return jZ(M7,$)}function LD($,U){return new j4({type:"pipe",in:$,out:U})}function _K($,U,J){return new P4({type:"pipe",in:$,out:U,transform:J.decode,reverseTransform:J.encode})}function vK($){let U=$._zod.def;return new P4({type:"pipe",in:U.out,out:U.in,transform:U.reverseTransform,reverseTransform:U.transform})}function z7($){return new T7({type:"readonly",innerType:$})}function FK($,U){return new A7({type:"template_literal",parts:$,...V$.normalizeParams(U)})}function g7($){return new K7({type:"lazy",getter:$})}function bK($){return new j7({type:"promise",innerType:$})}function uK($){return new P7({type:"function",input:Array.isArray($?.input)?eR($?.input):$?.input??A4(rq()),output:$?.output??rq()})}function kK($){let U=new p$({check:"custom"});return U._zod.check=$,U}function xK($,U){return SZ(B4,$??(()=>!0),U)}function B7($,U={}){return LZ(B4,$,U)}function S7($,U){return EZ($,U)}function mK($,U={}){let J=new B4({type:"custom",check:"custom",fn:(G)=>G instanceof $,abort:!0,...V$.normalizeParams(U)});return J._zod.bag.Class=$,J._zod.check=(G)=>{if(!(G.value instanceof $))G.issues.push({code:"invalid_type",expected:$.name,input:G.value,inst:J,path:[...J._zod.def.path??[]]})},J}function rK($){let U=g7(()=>{return cD([R4($),xR(),fR(),rR(),A4(U),$7(R4(),U)])});return U}function lK($,U){return new H7({type:"pipe",in:aD($),out:U})}var LA,v$,ED,T8,l$,CD,N4,oU,T4,_D,vD,FD,bD,uD,kD,xD,fD,kR,yD,mD,hD,rD,lD,iD,pD,z8,A8,lq,K8,g8,dD,yR,mR,hR,lR,iR,pR,dR,z4,nR,K4,g4,cR,oR,aR,tR,M8,U7,J7,H8,q7,G7,I7,sD,Q7,X7,Y7,W7,tD,R7,N7,M7,j4,P4,H7,T7,A7,K7,j7,P7,B4,fK,yK,hK=(...$)=>vZ({Codec:P4,Boolean:K8,String:T8},...$);var Z4=O$(()=>{RU();RU();V4();Y4();KD();W4();uR();LA=new WeakMap;v$=r("ZodType",($,U)=>{return E$.init($,U),Object.assign($["~standard"],{jsonSchema:{input:N8($,"input"),output:N8($,"output")}}),$.toJSONSchema=FZ($,{}),$.def=U,$.type=U.type,Object.defineProperty($,"_def",{value:U}),$.parse=(J,G)=>gR($,J,G,{callee:$.parse}),$.safeParse=(J,G)=>PR($,J,G),$.parseAsync=async(J,G)=>jR($,J,G,{callee:$.parseAsync}),$.safeParseAsync=async(J,G)=>BR($,J,G),$.spa=$.safeParseAsync,$.encode=(J,G)=>SR($,J,G),$.decode=(J,G)=>LR($,J,G),$.encodeAsync=async(J,G)=>ER($,J,G),$.decodeAsync=async(J,G)=>CR($,J,G),$.safeEncode=(J,G)=>_R($,J,G),$.safeDecode=(J,G)=>vR($,J,G),$.safeEncodeAsync=async(J,G)=>FR($,J,G),$.safeDecodeAsync=async(J,G)=>bR($,J,G),H4($,"ZodType",{check(...J){let G=this.def;return this.clone(V$.mergeDefs(G,{checks:[...G.checks??[],...J.map((q)=>typeof q==="function"?{_zod:{check:q,def:{check:"custom"},onattach:[]}}:q)]}),{parent:!0})},with(...J){return this.check(...J)},clone(J,G){return r0(this,J,G)},brand(){return this},register(J,G){return J.add(this,G),this},refine(J,G){return this.check(B7(J,G))},superRefine(J,G){return this.check(S7(J,G))},overwrite(J){return this.check(uU(J))},optional(){return w4(this)},exactOptional(){return D7(this)},nullable(){return M4(this)},nullish(){return w4(M4(this))},nonoptional(J){return Z7(this,J)},array(){return A4(this)},or(J){return cD([this,J])},and(J){return sR(this,J)},transform(J){return LD(this,aD(J))},default(J){return V7(this,J)},prefault(J){return O7(this,J)},catch(J){return w7(this,J)},pipe(J){return LD(this,J)},readonly(){return z7(this)},describe(J){let G=this.clone();return w0.add(G,{description:J}),G},meta(...J){if(J.length===0)return w0.get(this);let G=this.clone();return w0.add(G,J[0]),G},isOptional(){return this.safeParse(void 0).success},isNullable(){return this.safeParse(null).success},apply(J){return J(this)}}),Object.defineProperty($,"description",{get(){return w0.get($)?.description},configurable:!0}),$}),ED=r("_ZodString",($,U)=>{fq.init($,U),v$.init($,U),$._zod.processJSONSchema=(G,q,I)=>bZ($,G,q,I);let J=$._zod.bag;$.format=J.format??null,$.minLength=J.minimum??null,$.maxLength=J.maximum??null,H4($,"_ZodString",{regex(...G){return this.check(J8(...G))},includes(...G){return this.check(I8(...G))},startsWith(...G){return this.check(Q8(...G))},endsWith(...G){return this.check(D8(...G))},min(...G){return this.check(OJ(...G))},max(...G){return this.check(mq(...G))},length(...G){return this.check(hq(...G))},nonempty(...G){return this.check(OJ(1,...G))},lowercase(G){return this.check(q8(G))},uppercase(G){return this.check(G8(G))},trim(){return this.check(V8())},normalize(...G){return this.check(Y8(...G))},toLowerCase(){return this.check(W8())},toUpperCase(){return this.check(O8())},slugify(){return this.check(Z8())}})}),T8=r("ZodString",($,U)=>{fq.init($,U),ED.init($,U),$.email=(J)=>$.check(dQ(CD,J)),$.url=(J)=>$.check(X4(T4,J)),$.jwt=(J)=>$.check(WD(pD,J)),$.emoji=(J)=>$.check(sQ(_D,J)),$.guid=(J)=>$.check(D4(N4,J)),$.uuid=(J)=>$.check(nQ(oU,J)),$.uuidv4=(J)=>$.check(cQ(oU,J)),$.uuidv6=(J)=>$.check(oQ(oU,J)),$.uuidv7=(J)=>$.check(aQ(oU,J)),$.nanoid=(J)=>$.check(tQ(vD,J)),$.guid=(J)=>$.check(D4(N4,J)),$.cuid=(J)=>$.check(eQ(FD,J)),$.cuid2=(J)=>$.check($D(bD,J)),$.ulid=(J)=>$.check(UD(uD,J)),$.base64=(J)=>$.check(XD(rD,J)),$.base64url=(J)=>$.check(YD(lD,J)),$.xid=(J)=>$.check(JD(kD,J)),$.ksuid=(J)=>$.check(qD(xD,J)),$.ipv4=(J)=>$.check(GD(fD,J)),$.ipv6=(J)=>$.check(ID(yD,J)),$.cidrv4=(J)=>$.check(QD(mD,J)),$.cidrv6=(J)=>$.check(DD(hD,J)),$.e164=(J)=>$.check(VD(iD,J)),$.datetime=(J)=>$.check(HR(J)),$.date=(J)=>$.check(TR(J)),$.time=(J)=>$.check(zR(J)),$.duration=(J)=>$.check(AR(J))});l$=r("ZodStringFormat",($,U)=>{r$.init($,U),ED.init($,U)}),CD=r("ZodEmail",($,U)=>{fW.init($,U),l$.init($,U)});N4=r("ZodGUID",($,U)=>{kW.init($,U),l$.init($,U)});oU=r("ZodUUID",($,U)=>{xW.init($,U),l$.init($,U)});T4=r("ZodURL",($,U)=>{yW.init($,U),l$.init($,U)});_D=r("ZodEmoji",($,U)=>{mW.init($,U),l$.init($,U)});vD=r("ZodNanoID",($,U)=>{hW.init($,U),l$.init($,U)});FD=r("ZodCUID",($,U)=>{rW.init($,U),l$.init($,U)});bD=r("ZodCUID2",($,U)=>{lW.init($,U),l$.init($,U)});uD=r("ZodULID",($,U)=>{iW.init($,U),l$.init($,U)});kD=r("ZodXID",($,U)=>{pW.init($,U),l$.init($,U)});xD=r("ZodKSUID",($,U)=>{dW.init($,U),l$.init($,U)});fD=r("ZodIPv4",($,U)=>{sW.init($,U),l$.init($,U)});kR=r("ZodMAC",($,U)=>{eW.init($,U),l$.init($,U)});yD=r("ZodIPv6",($,U)=>{tW.init($,U),l$.init($,U)});mD=r("ZodCIDRv4",($,U)=>{$O.init($,U),l$.init($,U)});hD=r("ZodCIDRv6",($,U)=>{UO.init($,U),l$.init($,U)});rD=r("ZodBase64",($,U)=>{qO.init($,U),l$.init($,U)});lD=r("ZodBase64URL",($,U)=>{GO.init($,U),l$.init($,U)});iD=r("ZodE164",($,U)=>{IO.init($,U),l$.init($,U)});pD=r("ZodJWT",($,U)=>{QO.init($,U),l$.init($,U)});z8=r("ZodCustomStringFormat",($,U)=>{DO.init($,U),l$.init($,U)});A8=r("ZodNumber",($,U)=>{mQ.init($,U),v$.init($,U),$._zod.processJSONSchema=(G,q,I)=>uZ($,G,q,I),H4($,"ZodNumber",{gt(G,q){return this.check(nU(G,q))},gte(G,q){return this.check(i0(G,q))},min(G,q){return this.check(i0(G,q))},lt(G,q){return this.check(dU(G,q))},lte(G,q){return this.check(ZU(G,q))},max(G,q){return this.check(ZU(G,q))},int(G){return this.check(SD(G))},safe(G){return this.check(SD(G))},positive(G){return this.check(nU(0,G))},nonnegative(G){return this.check(i0(0,G))},negative(G){return this.check(dU(0,G))},nonpositive(G){return this.check(ZU(0,G))},multipleOf(G,q){return this.check(lJ(G,q))},step(G,q){return this.check(lJ(G,q))},finite(){return this}});let J=$._zod.bag;$.minValue=Math.max(J.minimum??Number.NEGATIVE_INFINITY,J.exclusiveMinimum??Number.NEGATIVE_INFINITY)??null,$.maxValue=Math.min(J.maximum??Number.POSITIVE_INFINITY,J.exclusiveMaximum??Number.POSITIVE_INFINITY)??null,$.isInt=(J.format??"").includes("int")||Number.isSafeInteger(J.multipleOf??0.5),$.isFinite=!0,$.format=J.format??null});lq=r("ZodNumberFormat",($,U)=>{XO.init($,U),A8.init($,U)});K8=r("ZodBoolean",($,U)=>{t6.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>kZ($,J,G,q)});g8=r("ZodBigInt",($,U)=>{hQ.init($,U),v$.init($,U),$._zod.processJSONSchema=(G,q,I)=>xZ($,G,q,I),$.gte=(G,q)=>$.check(i0(G,q)),$.min=(G,q)=>$.check(i0(G,q)),$.gt=(G,q)=>$.check(nU(G,q)),$.gte=(G,q)=>$.check(i0(G,q)),$.min=(G,q)=>$.check(i0(G,q)),$.lt=(G,q)=>$.check(dU(G,q)),$.lte=(G,q)=>$.check(ZU(G,q)),$.max=(G,q)=>$.check(ZU(G,q)),$.positive=(G)=>$.check(nU(BigInt(0),G)),$.negative=(G)=>$.check(dU(BigInt(0),G)),$.nonpositive=(G)=>$.check(ZU(BigInt(0),G)),$.nonnegative=(G)=>$.check(i0(BigInt(0),G)),$.multipleOf=(G,q)=>$.check(lJ(G,q));let J=$._zod.bag;$.minValue=J.minimum??null,$.maxValue=J.maximum??null,$.format=J.format??null});dD=r("ZodBigIntFormat",($,U)=>{YO.init($,U),g8.init($,U)});yR=r("ZodSymbol",($,U)=>{VO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>fZ($,J,G,q)});mR=r("ZodUndefined",($,U)=>{WO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>mZ($,J,G,q)});hR=r("ZodNull",($,U)=>{OO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>yZ($,J,G,q)});lR=r("ZodAny",($,U)=>{ZO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>lZ($,J,G,q)});iR=r("ZodUnknown",($,U)=>{RO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>iZ($,J,G,q)});pR=r("ZodNever",($,U)=>{NO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>rZ($,J,G,q)});dR=r("ZodVoid",($,U)=>{wO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>hZ($,J,G,q)});z4=r("ZodDate",($,U)=>{MO.init($,U),v$.init($,U),$._zod.processJSONSchema=(G,q,I)=>pZ($,G,q,I),$.min=(G,q)=>$.check(i0(G,q)),$.max=(G,q)=>$.check(ZU(G,q));let J=$._zod.bag;$.minDate=J.minimum?new Date(J.minimum):null,$.maxDate=J.maximum?new Date(J.maximum):null});nR=r("ZodArray",($,U)=>{HO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>qR($,J,G,q),$.element=U.element,H4($,"ZodArray",{min(J,G){return this.check(OJ(J,G))},nonempty(J){return this.check(OJ(1,J))},max(J,G){return this.check(mq(J,G))},length(J,G){return this.check(hq(J,G))},unwrap(){return this.element}})});K4=r("ZodObject",($,U)=>{TO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>GR($,J,G,q),V$.defineLazy($,"shape",()=>{return U.shape}),H4($,"ZodObject",{keyof(){return oD(Object.keys(this._zod.def.shape))},catchall(J){return this.clone({...this._zod.def,catchall:J})},passthrough(){return this.clone({...this._zod.def,catchall:rq()})},loose(){return this.clone({...this._zod.def,catchall:rq()})},strict(){return this.clone({...this._zod.def,catchall:nD()})},strip(){return this.clone({...this._zod.def,catchall:void 0})},extend(J){return V$.extend(this,J)},safeExtend(J){return V$.safeExtend(this,J)},merge(J){return V$.merge(this,J)},pick(J){return V$.pick(this,J)},omit(J){return V$.omit(this,J)},partial(...J){return V$.partial(sD,this,J[0])},required(...J){return V$.required(tD,this,J[0])}})});g4=r("ZodUnion",($,U)=>{e6.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>HD($,J,G,q),$.options=U.options});cR=r("ZodXor",($,U)=>{g4.init($,U),zO.init($,U),$._zod.processJSONSchema=(J,G,q)=>HD($,J,G,q),$.options=U.options});oR=r("ZodDiscriminatedUnion",($,U)=>{g4.init($,U),AO.init($,U)});aR=r("ZodIntersection",($,U)=>{KO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>IR($,J,G,q)});tR=r("ZodTuple",($,U)=>{rQ.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>QR($,J,G,q),$.rest=(J)=>$.clone({...$._zod.def,rest:J})});M8=r("ZodRecord",($,U)=>{gO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>DR($,J,G,q),$.keyType=U.keyType,$.valueType=U.valueType});U7=r("ZodMap",($,U)=>{jO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>UR($,J,G,q),$.keyType=U.keyType,$.valueType=U.valueType,$.min=(...J)=>$.check(cU(...J)),$.nonempty=(J)=>$.check(cU(1,J)),$.max=(...J)=>$.check(iJ(...J)),$.size=(...J)=>$.check(yq(...J))});J7=r("ZodSet",($,U)=>{PO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>JR($,J,G,q),$.min=(...J)=>$.check(cU(...J)),$.nonempty=(J)=>$.check(cU(1,J)),$.max=(...J)=>$.check(iJ(...J)),$.size=(...J)=>$.check(yq(...J))});H8=r("ZodEnum",($,U)=>{BO.init($,U),v$.init($,U),$._zod.processJSONSchema=(G,q,I)=>dZ($,G,q,I),$.enum=U.entries,$.options=Object.values(U.entries);let J=new Set(Object.keys(U.entries));$.extract=(G,q)=>{let I={};for(let Q of G)if(J.has(Q))I[Q]=U.entries[Q];else throw Error(`Key ${Q} not found in enum`);return new H8({...U,checks:[],...V$.normalizeParams(q),entries:I})},$.exclude=(G,q)=>{let I={...U.entries};for(let Q of G)if(J.has(Q))delete I[Q];else throw Error(`Key ${Q} not found in enum`);return new H8({...U,checks:[],...V$.normalizeParams(q),entries:I})}});q7=r("ZodLiteral",($,U)=>{SO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>nZ($,J,G,q),$.values=new Set(U.values),Object.defineProperty($,"value",{get(){if(U.values.length>1)throw Error("This schema contains multiple valid literal values. Use `.values` instead.");return U.values[0]}})});G7=r("ZodFile",($,U)=>{LO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>aZ($,J,G,q),$.min=(J,G)=>$.check(cU(J,G)),$.max=(J,G)=>$.check(iJ(J,G)),$.mime=(J,G)=>$.check(X8(Array.isArray(J)?J:[J],G))});I7=r("ZodTransform",($,U)=>{EO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>$R($,J,G,q),$._zod.parse=(J,G)=>{if(G.direction==="backward")throw new bq($.constructor.name);J.addIssue=(I)=>{if(typeof I==="string")J.issues.push(V$.issue(I,J.value,U));else{let Q=I;if(Q.fatal)Q.continue=!1;Q.code??(Q.code="custom"),Q.input??(Q.input=J.value),Q.inst??(Q.inst=$),J.issues.push(V$.issue(Q))}};let q=U.transform(J.value,J);if(q instanceof Promise)return q.then((I)=>{return J.value=I,J.fallback=!0,J});return J.value=q,J.fallback=!0,J}});sD=r("ZodOptional",($,U)=>{lQ.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>TD($,J,G,q),$.unwrap=()=>$._zod.def.innerType});Q7=r("ZodExactOptional",($,U)=>{CO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>TD($,J,G,q),$.unwrap=()=>$._zod.def.innerType});X7=r("ZodNullable",($,U)=>{_O.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>XR($,J,G,q),$.unwrap=()=>$._zod.def.innerType});Y7=r("ZodDefault",($,U)=>{vO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>VR($,J,G,q),$.unwrap=()=>$._zod.def.innerType,$.removeDefault=$.unwrap});W7=r("ZodPrefault",($,U)=>{FO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>WR($,J,G,q),$.unwrap=()=>$._zod.def.innerType});tD=r("ZodNonOptional",($,U)=>{bO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>YR($,J,G,q),$.unwrap=()=>$._zod.def.innerType});R7=r("ZodSuccess",($,U)=>{uO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>sZ($,J,G,q),$.unwrap=()=>$._zod.def.innerType});N7=r("ZodCatch",($,U)=>{kO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>OR($,J,G,q),$.unwrap=()=>$._zod.def.innerType,$.removeCatch=$.unwrap});M7=r("ZodNaN",($,U)=>{xO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>cZ($,J,G,q)});j4=r("ZodPipe",($,U)=>{iQ.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>ZR($,J,G,q),$.in=U.in,$.out=U.out});P4=r("ZodCodec",($,U)=>{j4.init($,U),$4.init($,U)});H7=r("ZodPreprocess",($,U)=>{j4.init($,U),fO.init($,U)}),T7=r("ZodReadonly",($,U)=>{yO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>RR($,J,G,q),$.unwrap=()=>$._zod.def.innerType});A7=r("ZodTemplateLiteral",($,U)=>{mO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>oZ($,J,G,q)});K7=r("ZodLazy",($,U)=>{lO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>wR($,J,G,q),$.unwrap=()=>$._zod.def.getter()});j7=r("ZodPromise",($,U)=>{rO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>NR($,J,G,q),$.unwrap=()=>$._zod.def.innerType});P7=r("ZodFunction",($,U)=>{hO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>eZ($,J,G,q)});B4=r("ZodCustom",($,U)=>{iO.init($,U),v$.init($,U),$._zod.processJSONSchema=(J,G,q)=>tZ($,J,G,q)});fK=CZ,yK=_Z});function Zk($){a$({customError:$})}function Rk(){return a$().customError}var Ok,L7;var iK=O$(()=>{RU();Ok={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($){})(L7||(L7={}))});function wk($,U){let J=$.$schema;if(J==="https://json-schema.org/draft/2020-12/schema")return"draft-2020-12";if(J==="http://json-schema.org/draft-07/schema#")return"draft-7";if(J==="http://json-schema.org/draft-04/schema#")return"draft-4";return U??"draft-2020-12"}function Mk($,U){if(!$.startsWith("#"))throw Error("External $ref is not supported, only local refs (#/...) are allowed");let J=$.slice(1).split("/").filter(Boolean);if(J.length===0)return U.rootSchema;let G=U.version==="draft-2020-12"?"$defs":"definitions";if(J[0]===G){let q=J[1];if(!q||!U.defs[q])throw Error(`Reference not found: ${$}`);return U.defs[q]}throw Error(`Reference not found: ${$}`)}function pK($,U){if($.not!==void 0){if(typeof $.not==="object"&&Object.keys($.not).length===0)return M$.never();throw Error("not is not supported in Zod (except { not: {} } for never)")}if($.unevaluatedItems!==void 0)throw Error("unevaluatedItems is not supported");if($.unevaluatedProperties!==void 0)throw Error("unevaluatedProperties is not supported");if($.if!==void 0||$.then!==void 0||$.else!==void 0)throw Error("Conditional schemas (if/then/else) are not supported");if($.dependentSchemas!==void 0||$.dependentRequired!==void 0)throw Error("dependentSchemas and dependentRequired are not supported");if($.$ref){let q=$.$ref;if(U.refs.has(q))return U.refs.get(q);if(U.processing.has(q))return M$.lazy(()=>{if(!U.refs.has(q))throw Error(`Circular reference not resolved: ${q}`);return U.refs.get(q)});U.processing.add(q);let I=Mk(q,U),Q=_0(I,U);return U.refs.set(q,Q),U.processing.delete(q),Q}if($.enum!==void 0){let q=$.enum;if(U.version==="openapi-3.0"&&$.nullable===!0&&q.length===1&&q[0]===null)return M$.null();if(q.length===0)return M$.never();if(q.length===1)return M$.literal(q[0]);if(q.every((Q)=>typeof Q==="string"))return M$.enum(q);let I=q.map((Q)=>M$.literal(Q));if(I.length<2)return I[0];return M$.union([I[0],I[1],...I.slice(2)])}if($.const!==void 0)return M$.literal($.const);let J=$.type;if(Array.isArray(J)){let q=J.map((I)=>{let Q={...$,type:I};return pK(Q,U)});if(q.length===0)return M$.never();if(q.length===1)return q[0];return M$.union(q)}if(!J)return M$.any();let G;switch(J){case"string":{let q=M$.string();if($.format){let I=$.format;if(I==="email")q=q.check(M$.email());else if(I==="uri"||I==="uri-reference")q=q.check(M$.url());else if(I==="uuid"||I==="guid")q=q.check(M$.uuid());else if(I==="date-time")q=q.check(M$.iso.datetime());else if(I==="date")q=q.check(M$.iso.date());else if(I==="time")q=q.check(M$.iso.time());else if(I==="duration")q=q.check(M$.iso.duration());else if(I==="ipv4")q=q.check(M$.ipv4());else if(I==="ipv6")q=q.check(M$.ipv6());else if(I==="mac")q=q.check(M$.mac());else if(I==="cidr")q=q.check(M$.cidrv4());else if(I==="cidr-v6")q=q.check(M$.cidrv6());else if(I==="base64")q=q.check(M$.base64());else if(I==="base64url")q=q.check(M$.base64url());else if(I==="e164")q=q.check(M$.e164());else if(I==="jwt")q=q.check(M$.jwt());else if(I==="emoji")q=q.check(M$.emoji());else if(I==="nanoid")q=q.check(M$.nanoid());else if(I==="cuid")q=q.check(M$.cuid());else if(I==="cuid2")q=q.check(M$.cuid2());else if(I==="ulid")q=q.check(M$.ulid());else if(I==="xid")q=q.check(M$.xid());else if(I==="ksuid")q=q.check(M$.ksuid())}if(typeof $.minLength==="number")q=q.min($.minLength);if(typeof $.maxLength==="number")q=q.max($.maxLength);if($.pattern)q=q.regex(new RegExp($.pattern));G=q;break}case"number":case"integer":{let q=J==="integer"?M$.number().int():M$.number();if(typeof $.minimum==="number")q=q.min($.minimum);if(typeof $.maximum==="number")q=q.max($.maximum);if(typeof $.exclusiveMinimum==="number")q=q.gt($.exclusiveMinimum);else if($.exclusiveMinimum===!0&&typeof $.minimum==="number")q=q.gt($.minimum);if(typeof $.exclusiveMaximum==="number")q=q.lt($.exclusiveMaximum);else if($.exclusiveMaximum===!0&&typeof $.maximum==="number")q=q.lt($.maximum);if(typeof $.multipleOf==="number")q=q.multipleOf($.multipleOf);G=q;break}case"boolean":{G=M$.boolean();break}case"null":{G=M$.null();break}case"object":{let q={},I=$.properties||{},Q=new Set($.required||[]);for(let[X,Y]of Object.entries(I)){let V=_0(Y,U);q[X]=Q.has(X)?V:V.optional()}if($.propertyNames){let X=_0($.propertyNames,U),Y=$.additionalProperties&&typeof $.additionalProperties==="object"?_0($.additionalProperties,U):M$.any();if(Object.keys(q).length===0){G=M$.record(X,Y);break}let V=M$.object(q).passthrough(),W=M$.looseRecord(X,Y);G=M$.intersection(V,W);break}if($.patternProperties){let X=$.patternProperties,Y=Object.keys(X),V=[];for(let O of Y){let Z=_0(X[O],U),M=M$.string().regex(new RegExp(O));V.push(M$.looseRecord(M,Z))}let W=[];if(Object.keys(q).length>0)W.push(M$.object(q).passthrough());if(W.push(...V),W.length===0)G=M$.object({}).passthrough();else if(W.length===1)G=W[0];else{let O=M$.intersection(W[0],W[1]);for(let Z=2;Z<W.length;Z++)O=M$.intersection(O,W[Z]);G=O}break}let D=M$.object(q);if($.additionalProperties===!1)G=D.strict();else if(typeof $.additionalProperties==="object")G=D.catchall(_0($.additionalProperties,U));else G=D.passthrough();break}case"array":{let{prefixItems:q,items:I}=$;if(q&&Array.isArray(q)){let Q=q.map((X)=>_0(X,U)),D=I&&typeof I==="object"&&!Array.isArray(I)?_0(I,U):void 0;if(D)G=M$.tuple(Q).rest(D);else G=M$.tuple(Q);if(typeof $.minItems==="number")G=G.check(M$.minLength($.minItems));if(typeof $.maxItems==="number")G=G.check(M$.maxLength($.maxItems))}else if(Array.isArray(I)){let Q=I.map((X)=>_0(X,U)),D=$.additionalItems&&typeof $.additionalItems==="object"?_0($.additionalItems,U):void 0;if(D)G=M$.tuple(Q).rest(D);else G=M$.tuple(Q);if(typeof $.minItems==="number")G=G.check(M$.minLength($.minItems));if(typeof $.maxItems==="number")G=G.check(M$.maxLength($.maxItems))}else if(I!==void 0){let Q=_0(I,U),D=M$.array(Q);if(typeof $.minItems==="number")D=D.min($.minItems);if(typeof $.maxItems==="number")D=D.max($.maxItems);G=D}else G=M$.array(M$.any());break}default:throw Error(`Unsupported type: ${J}`)}return G}function _0($,U){if(typeof $==="boolean")return $?M$.any():M$.never();let J=pK($,U),G=$.type||$.enum!==void 0||$.const!==void 0;if($.anyOf&&Array.isArray($.anyOf)){let D=$.anyOf.map((Y)=>_0(Y,U)),X=M$.union(D);J=G?M$.intersection(J,X):X}if($.oneOf&&Array.isArray($.oneOf)){let D=$.oneOf.map((Y)=>_0(Y,U)),X=M$.xor(D);J=G?M$.intersection(J,X):X}if($.allOf&&Array.isArray($.allOf))if($.allOf.length===0)J=G?J:M$.any();else{let D=G?J:_0($.allOf[0],U),X=G?0:1;for(let Y=X;Y<$.allOf.length;Y++)D=M$.intersection(D,_0($.allOf[Y],U));J=D}if($.nullable===!0&&U.version==="openapi-3.0")J=M$.nullable(J);if($.readOnly===!0)J=M$.readonly(J);if($.default!==void 0)J=J.default($.default);let q={},I=["$id","id","$comment","$anchor","$vocabulary","$dynamicRef","$dynamicAnchor"];for(let D of I)if(D in $)q[D]=$[D];let Q=["contentEncoding","contentMediaType","contentSchema"];for(let D of Q)if(D in $)q[D]=$[D];for(let D of Object.keys($))if(!Nk.has(D))q[D]=$[D];if(Object.keys(q).length>0)U.registry.add(J,q);if($.description)J=J.describe($.description);return J}function dK($,U){if(typeof $==="boolean")return $?M$.any():M$.never();let J;try{J=JSON.parse(JSON.stringify($))}catch{throw Error("fromJSONSchema input is not valid JSON (possibly cyclic); use $defs/$ref for recursive schemas")}let G=wk(J,U?.defaultTarget),q=J.$defs||J.definitions||{},I={version:G,defs:q,refs:new Map,processing:new Set,rootSchema:J,registry:U?.registry??w0};return _0(J,I)}var M$,Nk;var nK=O$(()=>{Q4();KD();W4();Z4();M$={...O4,...AD,iso:w8},Nk=new Set(["$schema","$ref","$defs","definitions","$id","id","$comment","$anchor","$vocabulary","$dynamicRef","$dynamicAnchor","type","enum","const","anyOf","oneOf","allOf","not","properties","required","additionalProperties","patternProperties","propertyNames","minProperties","maxProperties","items","prefixItems","additionalItems","minItems","maxItems","uniqueItems","contains","minContains","maxContains","minLength","maxLength","pattern","format","minimum","maximum","exclusiveMinimum","exclusiveMaximum","multipleOf","description","default","contentEncoding","contentMediaType","contentSchema","unevaluatedItems","unevaluatedProperties","if","then","else","dependentSchemas","dependentRequired","nullable","readOnly"])});var E7={};UU(E7,{string:()=>Hk,number:()=>Tk,date:()=>Kk,boolean:()=>zk,bigint:()=>Ak});function Hk($){return o1(T8,$)}function Tk($){return qZ(A8,$)}function zk($){return VZ(K8,$)}function Ak($){return OZ(g8,$)}function Kk($){return gZ(z4,$)}var cK=O$(()=>{RU();Z4()});var N={};UU(N,{xor:()=>TK,xid:()=>rA,void:()=>ZK,uuidv7:()=>bA,uuidv6:()=>FA,uuidv4:()=>vA,uuid:()=>_A,util:()=>V$,url:()=>uA,uppercase:()=>G8,unknown:()=>rq,union:()=>cD,undefined:()=>WK,ulid:()=>hA,uint64:()=>YK,uint32:()=>QK,tuple:()=>eR,trim:()=>V8,treeifyError:()=>bV,transform:()=>aD,toUpperCase:()=>O8,toLowerCase:()=>W8,toJSONSchema:()=>zD,templateLiteral:()=>FK,symbol:()=>VK,superRefine:()=>S7,success:()=>EK,stringbool:()=>hK,stringFormat:()=>eA,string:()=>R4,strictObject:()=>MK,startsWith:()=>Q8,slugify:()=>Z8,size:()=>yq,setErrorMap:()=>Zk,set:()=>jK,safeParseAsync:()=>BR,safeParse:()=>PR,safeEncodeAsync:()=>FR,safeEncode:()=>_R,safeDecodeAsync:()=>bR,safeDecode:()=>vR,registry:()=>pQ,regexes:()=>OU,regex:()=>J8,refine:()=>B7,record:()=>$7,readonly:()=>z7,property:()=>wD,promise:()=>bK,prettifyError:()=>uV,preprocess:()=>lK,prefault:()=>O7,positive:()=>OD,pipe:()=>LD,partialRecord:()=>AK,parseAsync:()=>jR,parse:()=>gR,overwrite:()=>uU,optional:()=>w4,object:()=>wK,number:()=>xR,nullish:()=>LK,nullable:()=>M4,null:()=>rR,normalize:()=>Y8,nonpositive:()=>RD,nonoptional:()=>Z7,nonnegative:()=>ND,never:()=>nD,negative:()=>ZD,nativeEnum:()=>PK,nanoid:()=>fA,nan:()=>CK,multipleOf:()=>lJ,minSize:()=>cU,minLength:()=>OJ,mime:()=>X8,meta:()=>yK,maxSize:()=>iJ,maxLength:()=>mq,map:()=>gK,mac:()=>pA,lte:()=>ZU,lt:()=>dU,lowercase:()=>q8,looseRecord:()=>KK,looseObject:()=>HK,locales:()=>I4,literal:()=>BK,length:()=>hq,lazy:()=>g7,ksuid:()=>lA,keyof:()=>NK,jwt:()=>tA,json:()=>rK,iso:()=>w8,ipv6:()=>dA,ipv4:()=>iA,invertCodec:()=>vK,intersection:()=>sR,int64:()=>XK,int32:()=>IK,int:()=>SD,instanceof:()=>mK,includes:()=>I8,httpUrl:()=>kA,hostname:()=>$K,hex:()=>UK,hash:()=>JK,guid:()=>CA,gte:()=>i0,gt:()=>nU,globalRegistry:()=>w0,getErrorMap:()=>Rk,function:()=>uK,fromJSONSchema:()=>dK,formatError:()=>c6,float64:()=>GK,float32:()=>qK,flattenError:()=>n6,file:()=>SK,exactOptional:()=>D7,enum:()=>oD,endsWith:()=>D8,encodeAsync:()=>ER,encode:()=>SR,emoji:()=>xA,email:()=>EA,e164:()=>sA,discriminatedUnion:()=>zK,describe:()=>fK,decodeAsync:()=>CR,decode:()=>LR,date:()=>RK,custom:()=>xK,cuid2:()=>mA,cuid:()=>yA,core:()=>ZJ,config:()=>a$,coerce:()=>E7,codec:()=>_K,clone:()=>r0,cidrv6:()=>cA,cidrv4:()=>nA,check:()=>kK,catch:()=>w7,boolean:()=>fR,bigint:()=>DK,base64url:()=>aA,base64:()=>oA,array:()=>A4,any:()=>OK,_function:()=>uK,_default:()=>V7,_ZodString:()=>ED,ZodXor:()=>cR,ZodXID:()=>kD,ZodVoid:()=>dR,ZodUnknown:()=>iR,ZodUnion:()=>g4,ZodUndefined:()=>mR,ZodUUID:()=>oU,ZodURL:()=>T4,ZodULID:()=>uD,ZodType:()=>v$,ZodTuple:()=>tR,ZodTransform:()=>I7,ZodTemplateLiteral:()=>A7,ZodSymbol:()=>yR,ZodSuccess:()=>R7,ZodStringFormat:()=>l$,ZodString:()=>T8,ZodSet:()=>J7,ZodRecord:()=>M8,ZodRealError:()=>GU,ZodReadonly:()=>T7,ZodPromise:()=>j7,ZodPreprocess:()=>H7,ZodPrefault:()=>W7,ZodPipe:()=>j4,ZodOptional:()=>sD,ZodObject:()=>K4,ZodNumberFormat:()=>lq,ZodNumber:()=>A8,ZodNullable:()=>X7,ZodNull:()=>hR,ZodNonOptional:()=>tD,ZodNever:()=>pR,ZodNanoID:()=>vD,ZodNaN:()=>M7,ZodMap:()=>U7,ZodMAC:()=>kR,ZodLiteral:()=>q7,ZodLazy:()=>K7,ZodKSUID:()=>xD,ZodJWT:()=>pD,ZodIssueCode:()=>Ok,ZodIntersection:()=>aR,ZodISOTime:()=>PD,ZodISODuration:()=>BD,ZodISODateTime:()=>gD,ZodISODate:()=>jD,ZodIPv6:()=>yD,ZodIPv4:()=>fD,ZodGUID:()=>N4,ZodFunction:()=>P7,ZodFirstPartyTypeKind:()=>L7,ZodFile:()=>G7,ZodExactOptional:()=>Q7,ZodError:()=>SA,ZodEnum:()=>H8,ZodEmoji:()=>_D,ZodEmail:()=>CD,ZodE164:()=>iD,ZodDiscriminatedUnion:()=>oR,ZodDefault:()=>Y7,ZodDate:()=>z4,ZodCustomStringFormat:()=>z8,ZodCustom:()=>B4,ZodCodec:()=>P4,ZodCatch:()=>N7,ZodCUID2:()=>bD,ZodCUID:()=>FD,ZodCIDRv6:()=>hD,ZodCIDRv4:()=>mD,ZodBoolean:()=>K8,ZodBigIntFormat:()=>dD,ZodBigInt:()=>g8,ZodBase64URL:()=>lD,ZodBase64:()=>rD,ZodArray:()=>nR,ZodAny:()=>lR,TimePrecision:()=>s1,NEVER:()=>KV,$output:()=>p1,$input:()=>d1,$brand:()=>gV});var C7=O$(()=>{RU();RU();U1();RU();V4();nK();i1();W4();W4();cK();Z4();KD();KR();uR();iK();a$(U4())});var oK=O$(()=>{C7();C7()});var _7=O$(()=>{oK()});var b$=O$(()=>{_7()});var gk,jk,aU,sU,iq,Pk,aK,Bk,Sk,sK,eD,j8,cJ,Lk,Ek,Ck,_k,vk,v7,Fk,$X;var P8=O$(()=>{b$();gk=/^\d+\.\d+\.\d+(?:-[0-9A-Za-z.-]+)?(?:\+[0-9A-Za-z.-]+)?$/,jk=/^[a-z0-9]+(?:-[a-z0-9]+)*$/,aU=N.string().regex(gk,"expected exact pinned version"),sU=N.string().regex(jk,"expected lowercase handle slug"),iq=N.string().min(1),Pk=N.string().startsWith("age1").min(1),aK=N.enum(["core","site","publishing","team"]),Bk=["professional","team","organization"],Sk=N.enum(Bk),sK=N.array(aK).min(1),eD=N.array(N.string().min(1)),j8=N.strictObject({brainVersion:aU,bundles:sK,add:eD.optional(),remove:eD.optional(),githubOrg:N.string().min(1),contentRepoPrefix:N.string().min(1),domainSuffix:N.string().min(1),aiApiKey:iq,gitSyncToken:iq,contentRepoAdminToken:iq,agePublicKey:Pk}).superRefine(($,U)=>{if(new Set($.bundles).size!==$.bundles.length)U.addIssue({code:N.ZodIssueCode.custom,path:["bundles"],message:"canonical bundles must be unique"})}),cJ=N.strictObject({members:N.array(sU).min(1),brainVersionOverride:aU.optional(),bundlesOverride:sK.optional(),addOverride:eD.optional(),removeOverride:eD.optional(),aiApiKeyOverride:iq.optional(),gitSyncTokenOverride:iq.optional()}).superRefine(($,U)=>{if(new Set($.members).size!==$.members.length)U.addIssue({code:N.ZodIssueCode.custom,path:["members"],message:"cohort members must be unique"});if($.bundlesOverride&&new Set($.bundlesOverride).size!==$.bundlesOverride.length)U.addIssue({code:N.ZodIssueCode.custom,path:["bundlesOverride"],message:"canonical bundle overrides must be unique"})}),Lk=N.strictObject({platform:N.enum(["github","instagram","linkedin","email","website"]),url:N.string().min(1),label:N.string().min(1).optional()}),Ek=N.strictObject({name:N.string().min(1).optional(),description:N.string().min(1).optional(),website:N.string().min(1).optional(),email:N.string().min(1).optional(),story:N.string().min(1).optional(),socialLinks:N.array(Lk).optional()}),Ck=N.strictObject({delivery:N.literal("email"),email:N.string().email()}),_k=N.strictObject({enabled:N.boolean().optional(),endpoint:N.string().url().refine(($)=>new URL($).protocol==="wss:",{message:"Jetstream endpoint must use wss"}).optional(),replayWindowSeconds:N.number().int().min(60).optional(),denyDids:N.array(N.string().startsWith("did:plc:")).optional(),denyDomains:N.array(N.string().min(1)).optional(),skillKeywords:N.array(N.string().min(1)).optional(),queueLimit:N.number().int().min(1).max(1e4).optional(),concurrency:N.number().int().min(1).max(32).optional(),perDidCooldownSeconds:N.number().int().nonnegative().optional(),fetchBudgetPerMinute:N.number().int().min(1).optional(),newAgentsPerHour:N.number().int().min(1).optional(),pendingCandidateCeiling:N.number().int().min(1).optional(),staleCandidateRetentionDays:N.number().int().min(1).optional(),requestTimeoutMs:N.number().int().min(100).optional(),maxResponseBytes:N.number().int().min(1024).optional(),maxRedirects:N.number().int().nonnegative().optional(),retryAttempts:N.number().int().min(1).optional(),heartbeatIntervalHours:N.number().min(1).optional()}),vk=N.strictObject({identifier:N.string().min(1),accountDid:N.string().min(1).optional(),lexiconAuthority:N.boolean().optional(),jetstream:_k.optional()}),v7=N.strictObject({package:N.string().min(1),version:aU,theme:N.string().min(1).optional(),themeVersion:aU.optional()}).superRefine(($,U)=>{let J=$.theme?.startsWith("@rizom/")===!0;if(J&&$.themeVersion===void 0)U.addIssue({code:N.ZodIssueCode.custom,path:["themeVersion"],message:"external @rizom themes require an exact version pin"});if(!J&&$.themeVersion!==void 0)U.addIssue({code:N.ZodIssueCode.custom,path:["themeVersion"],message:"themeVersion is valid only for external @rizom themes"})}),Fk=N.strictObject({onboarding:N.boolean().optional()}),$X=N.strictObject({handle:sU,discord:N.strictObject({enabled:N.boolean(),anchorUserId:N.string().min(1).optional()}),aiApiKeyOverride:iq.optional(),gitSyncTokenOverride:iq.optional(),domainOverride:N.string().min(1).optional(),cloudflareZoneId:N.string().min(1).optional(),contentRepoOverride:N.string().min(1).optional(),profileKind:Sk.optional(),embeddingEnabled:N.boolean().optional(),topicExtractionEnabled:N.boolean().optional(),addOverride:N.array(N.string().min(1)).optional(),removeOverride:N.array(N.string().min(1)).optional(),siteOverride:v7.optional(),setup:Ck.optional(),atproto:vk.optional(),playbooks:Fk.optional(),anchorProfile:Ek.optional()})});import{access as bk,readdir as uk,readFile as kk}from"fs/promises";import{basename as F7,join as S4,relative as xk}from"path";async function M0($,U={}){let[J,G,q]=await Promise.all([b7(S4($,"pilot.yaml"),j8),fk($),yk($)]),I=mk(G,q),Q=q.map((X)=>({id:X.id,members:[...X.data.members].sort(),...X.data.brainVersionOverride?{brainVersionOverride:X.data.brainVersionOverride}:{},...X.data.bundlesOverride?{bundlesOverride:X.data.bundlesOverride}:{},...X.data.addOverride?{addOverride:X.data.addOverride}:{},...X.data.removeOverride?{removeOverride:X.data.removeOverride}:{},...X.data.aiApiKeyOverride?{aiApiKeyOverride:X.data.aiApiKeyOverride}:{},...X.data.gitSyncTokenOverride?{gitSyncTokenOverride:X.data.gitSyncTokenOverride}:{}})).sort((X,Y)=>X.id.localeCompare(Y.id)),D=await Promise.all(G.map(async(X)=>{let Y=I.get(X.data.handle);if(!Y)throw new pq(`User ${X.data.handle} must belong to exactly one cohort`);let V=Y.data.brainVersionOverride??J.brainVersion,W={handle:X.data.handle,cohort:Y.id,brainVersion:V,bundles:[...Y.data.bundlesOverride??J.bundles],add:tK([...Y.data.addOverride??(Y.data.bundlesOverride?[]:J.add??[]),...X.data.addOverride??[]]),remove:tK([...Y.data.removeOverride??(Y.data.bundlesOverride?[]:J.remove??[]),...X.data.removeOverride??[]]),domain:X.data.domainOverride??`${X.data.handle}${J.domainSuffix}`,...X.data.cloudflareZoneId?{cloudflareZoneId:X.data.cloudflareZoneId}:{},contentRepo:X.data.contentRepoOverride??`${J.contentRepoPrefix}${X.data.handle}-content`,...X.data.profileKind?{profileKind:X.data.profileKind}:{},...X.data.embeddingEnabled!==void 0?{embeddingEnabled:X.data.embeddingEnabled}:{},...X.data.topicExtractionEnabled!==void 0?{topicExtractionEnabled:X.data.topicExtractionEnabled}:{},...X.data.siteOverride?{siteOverride:{...X.data.siteOverride}}:{},discordEnabled:X.data.discord.enabled,...X.data.discord.anchorUserId?{discordAnchorUserId:X.data.discord.anchorUserId}:{},effectiveAiApiKey:X.data.aiApiKeyOverride??Y.data.aiApiKeyOverride??J.aiApiKey,effectiveGitSyncToken:X.data.gitSyncTokenOverride??Y.data.gitSyncTokenOverride??J.gitSyncToken,...X.data.setup?{setup:X.data.setup}:{},...X.data.atproto?{atproto:X.data.atproto}:{},...X.data.playbooks?{playbooks:X.data.playbooks}:{},anchorProfile:hk(X.data.handle,X.data.anchorProfile),snapshotStatus:await lk($,X.data.handle)},O=await U.resolveStatus?.(W);return{...W,serverStatus:O?.serverStatus??"unknown",deployStatus:O?.deployStatus??"unknown",dnsStatus:O?.dnsStatus??"unknown",mcpStatus:O?.mcpStatus??"unknown"}}));return D.sort((X,Y)=>X.handle.localeCompare(Y.handle)),{pilot:J,cohorts:Q,users:D}}async function fk($){let U=S4($,"users"),J=(await eK(U)).filter((q)=>!F7(q).endsWith(".secrets.yaml"));return(await Promise.all(J.map(async(q)=>{let I=$g(F7(q)),Q=await b7(q,$X);if(Q.handle!==I){let D=Ug(xk($,q));throw new pq(`${D} must declare handle: ${I}`)}return{id:I,data:Q}}))).sort((q,I)=>q.id.localeCompare(I.id))}async function yk($){let U=S4($,"cohorts"),J=await eK(U);return(await Promise.all(J.map(async(q)=>({id:$g(F7(q)),data:await b7(q,cJ)})))).sort((q,I)=>q.id.localeCompare(I.id))}function mk($,U){let J=new Map($.map((q)=>[q.data.handle,q])),G=new Map;for(let q of U)for(let I of q.data.members){if(!J.has(I))throw new pq(`Cohort ${q.id} references unknown user ${I}`);if(G.has(I))throw new pq(`User ${I} must belong to exactly one cohort`);G.set(I,q)}for(let q of $)if(!G.has(q.data.handle))throw new pq(`User ${q.data.handle} must belong to exactly one cohort`);return G}function hk($,U){return{name:U?.name??rk($),...U?.description?{description:U.description}:{},...U?.website?{website:U.website}:{},...U?.email?{email:U.email}:{},...U?.story?{story:U.story}:{},...U?.socialLinks?{socialLinks:U.socialLinks.map((J)=>({platform:J.platform,url:J.url,...J.label?{label:J.label}:{}}))}:{}}}function rk($){return $.split("-").filter((U)=>U.length>0).map((U)=>U.charAt(0).toUpperCase()+U.slice(1)).join(" ")}async function lk($,U){let J=S4($,"users",U,"brain.yaml");try{return await bk(J),"present"}catch{return"missing"}}async function eK($){return(await uk($,{withFileTypes:!0})).filter((J)=>J.isFile()&&J.name.endsWith(".yaml")).map((J)=>S4($,J.name)).sort((J,G)=>J.localeCompare(G))}async function b7($,U){let J=await kk($,"utf8"),G=dG(J,U);if(!G.ok)throw new pq(`${Ug($)}: ${G.error}`);return G.data}function tK($){return[...new Set($)]}function $g($){return $.replace(/\.ya?ml$/,"")}function Ug($){return $.replaceAll("\\","/")}var pq;var RJ=O$(()=>{vq();P8();pq=class pq extends Error{}});import{mkdir as ik,writeFile as pk}from"fs/promises";import{join as Jg}from"path";async function dq($,U={}){let G=(U.registry??await M0($,U)).users.map((I)=>{let Q=I.discordEnabled?"on":"off";return[I.handle,I.cohort,I.bundles.join(","),I.add.join(","),I.remove.join(","),I.brainVersion,I.domain,I.contentRepo,Q,I.serverStatus,I.deployStatus,I.dnsStatus,I.mcpStatus]}),q=["<!-- generated by brains-ops; do not edit -->","",dk,nk,...G.map((I)=>`| ${I.join(" | ")} |`),""].join(`
|
|
98
|
+
`);await ik(Jg($,"views"),{recursive:!0}),await pk(Jg($,"views","users.md"),q)}var dk="| handle | cohort | bundles | add | remove | brainVersion | domain | contentRepo | discord | serverStatus | deployStatus | dnsStatus | mcpStatus |",nk="| --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- |";var L4=O$(()=>{RJ()});var E4=J$((pQ$,Sg)=>{var nx=Object.prototype.toString;Sg.exports=function(U){if(U===void 0)return"undefined";if(U===null)return"null";var J=typeof U;if(J==="boolean")return"boolean";if(J==="string")return"string";if(J==="number")return"number";if(J==="symbol")return"symbol";if(J==="function")return tx(U)?"generatorfunction":"function";if(cx(U))return"array";if(Uf(U))return"buffer";if($f(U))return"arguments";if(ax(U))return"date";if(ox(U))return"error";if(sx(U))return"regexp";switch(Bg(U)){case"Symbol":return"symbol";case"Promise":return"promise";case"WeakMap":return"weakmap";case"WeakSet":return"weakset";case"Map":return"map";case"Set":return"set";case"Int8Array":return"int8array";case"Uint8Array":return"uint8array";case"Uint8ClampedArray":return"uint8clampedarray";case"Int16Array":return"int16array";case"Uint16Array":return"uint16array";case"Int32Array":return"int32array";case"Uint32Array":return"uint32array";case"Float32Array":return"float32array";case"Float64Array":return"float64array"}if(ex(U))return"generator";switch(J=nx.call(U),J){case"[object Object]":return"object";case"[object Map Iterator]":return"mapiterator";case"[object Set Iterator]":return"setiterator";case"[object String Iterator]":return"stringiterator";case"[object Array Iterator]":return"arrayiterator"}return J.slice(8,-1).toLowerCase().replace(/\s/g,"")};function Bg($){return typeof $.constructor==="function"?$.constructor.name:null}function cx($){if(Array.isArray)return Array.isArray($);return $ instanceof Array}function ox($){return $ instanceof Error||typeof $.message==="string"&&$.constructor&&typeof $.constructor.stackTraceLimit==="number"}function ax($){if($ instanceof Date)return!0;return typeof $.toDateString==="function"&&typeof $.getDate==="function"&&typeof $.setDate==="function"}function sx($){if($ instanceof RegExp)return!0;return typeof $.flags==="string"&&typeof $.ignoreCase==="boolean"&&typeof $.multiline==="boolean"&&typeof $.global==="boolean"}function tx($,U){return Bg($)==="GeneratorFunction"}function ex($){return typeof $.throw==="function"&&typeof $.return==="function"&&typeof $.next==="function"}function $f($){try{if(typeof $.length==="number"&&typeof $.callee==="function")return!0}catch(U){if(U.message.indexOf("callee")!==-1)return!0}return!1}function Uf($){if($.constructor&&typeof $.constructor.isBuffer==="function")return $.constructor.isBuffer($);return!1}});var Eg=J$((dQ$,Lg)=>{/*!
|
|
3
99
|
* is-extendable <https://github.com/jonschlinkert/is-extendable>
|
|
4
100
|
*
|
|
5
101
|
* Copyright (c) 2015, Jon Schlinkert.
|
|
6
102
|
* Licensed under the MIT License.
|
|
7
|
-
*/
|
|
8
|
-
`),
|
|
9
|
-
`));if(
|
|
10
|
-
`));
|
|
11
|
-
`));else
|
|
12
|
-
`));return J.sections=
|
|
13
|
-
\x85\u2028\u2029`.indexOf(this.buffer.charAt(
|
|
14
|
-
\x85\u2028\u2029`.indexOf(this.buffer.charAt(
|
|
15
|
-
`+
|
|
16
|
-
`+J}return G};
|
|
17
|
-
\r`;function
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
`,
|
|
21
|
-
`}break}if(G)if(
|
|
22
|
-
`,
|
|
23
|
-
`,
|
|
24
|
-
`,
|
|
25
|
-
`,
|
|
26
|
-
`;if(
|
|
27
|
-
`,G),
|
|
28
|
-
`)
|
|
29
|
-
`+
|
|
30
|
-
`,
|
|
31
|
-
|
|
32
|
-
`),
|
|
33
|
-
`}function
|
|
34
|
-
|
|
35
|
-
`);return
|
|
36
|
-
|
|
37
|
-
`:"")+
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
`;return""}function
|
|
103
|
+
*/Lg.exports=function(U){return typeof U<"u"&&U!==null&&(typeof U==="object"||typeof U==="function")}});var vg=J$((nQ$,_g)=>{var Cg=Eg();_g.exports=function(U){if(!Cg(U))U={};var J=arguments.length;for(var G=1;G<J;G++){var q=arguments[G];if(Cg(q))Jf(U,q)}return U};function Jf($,U){for(var J in U)if(qf(U,J))$[J]=U[J]}function qf($,U){return Object.prototype.hasOwnProperty.call($,U)}});var ug=J$((cQ$,bg)=>{var Gf=E4(),If=vg();bg.exports=function($,U){if(typeof U==="function")U={parse:U};var J=Df($),G={section_delimiter:"---",parse:Yf},q=If({},G,U),I=q.section_delimiter,Q=J.content.split(/\r?\n/),D=null,X=Fg(),Y=[],V=[];function W(g){J.content=g,D=[],Y=[]}function O(g){if(V.length)X.key=Xf(V[0],I),X.content=g,q.parse(X,D),D.push(X),X=Fg(),Y=[],V=[]}for(var Z=0;Z<Q.length;Z++){var M=Q[Z],w=V.length,H=M.trim();if(Qf(H,I)){if(H.length===3&&Z!==0){if(w===0||w===2){Y.push(M);continue}V.push(H),X.data=Y.join(`
|
|
104
|
+
`),Y=[];continue}if(D===null)W(Y.join(`
|
|
105
|
+
`));if(w===2)O(Y.join(`
|
|
106
|
+
`));V.push(H);continue}Y.push(M)}if(D===null)W(Y.join(`
|
|
107
|
+
`));else O(Y.join(`
|
|
108
|
+
`));return J.sections=D,J};function Qf($,U){if($.slice(0,U.length)!==U)return!1;if($.charAt(U.length+1)===U.slice(-1))return!1;return!0}function Df($){if(Gf($)!=="object")$={content:$};if(typeof $.content!=="string"&&!Vf($.content))throw TypeError("expected a buffer or string");return $.content=$.content.toString(),$.sections=[],$}function Xf($,U){return $?$.slice(U.length).trim():""}function Fg(){return{key:"",data:"",content:""}}function Yf($){return $}function Vf($){if($&&$.constructor&&typeof $.constructor.isBuffer==="function")return $.constructor.isBuffer($);return!1}});var cq=J$((wf,nq)=>{function kg($){return typeof $>"u"||$===null}function Wf($){return typeof $==="object"&&$!==null}function Of($){if(Array.isArray($))return $;else if(kg($))return[];return[$]}function Zf($,U){var J,G,q,I;if(U){I=Object.keys(U);for(J=0,G=I.length;J<G;J+=1)q=I[J],$[q]=U[q]}return $}function Rf($,U){var J="",G;for(G=0;G<U;G+=1)J+=$;return J}function Nf($){return $===0&&Number.NEGATIVE_INFINITY===1/$}wf.isNothing=kg;wf.isObject=Wf;wf.toArray=Of;wf.repeat=Rf;wf.isNegativeZero=Nf;wf.extend=Zf});var S8=J$((oQ$,xg)=>{function C4($,U){if(Error.call(this),this.name="YAMLException",this.reason=$,this.mark=U,this.message=(this.reason||"(unknown reason)")+(this.mark?" "+this.mark.toString():""),Error.captureStackTrace)Error.captureStackTrace(this,this.constructor);else this.stack=Error().stack||""}C4.prototype=Object.create(Error.prototype);C4.prototype.constructor=C4;C4.prototype.toString=function(U){var J=this.name+": ";if(J+=this.reason||"(unknown reason)",!U&&this.mark)J+=" "+this.mark.toString();return J};xg.exports=C4});var mg=J$((aQ$,yg)=>{var fg=cq();function d7($,U,J,G,q){this.name=$,this.buffer=U,this.position=J,this.line=G,this.column=q}d7.prototype.getSnippet=function(U,J){var G,q,I,Q,D;if(!this.buffer)return null;U=U||4,J=J||75,G="",q=this.position;while(q>0&&`\x00\r
|
|
109
|
+
\x85\u2028\u2029`.indexOf(this.buffer.charAt(q-1))===-1)if(q-=1,this.position-q>J/2-1){G=" ... ",q+=5;break}I="",Q=this.position;while(Q<this.buffer.length&&`\x00\r
|
|
110
|
+
\x85\u2028\u2029`.indexOf(this.buffer.charAt(Q))===-1)if(Q+=1,Q-this.position>J/2-1){I=" ... ",Q-=5;break}return D=this.buffer.slice(q,Q),fg.repeat(" ",U)+G+D+I+`
|
|
111
|
+
`+fg.repeat(" ",U+this.position-q+G.length)+"^"};d7.prototype.toString=function(U){var J,G="";if(this.name)G+='in "'+this.name+'" ';if(G+="at line "+(this.line+1)+", column "+(this.column+1),!U){if(J=this.getSnippet(),J)G+=`:
|
|
112
|
+
`+J}return G};yg.exports=d7});var X0=J$((sQ$,rg)=>{var hg=S8(),gf=["kind","resolve","construct","instanceOf","predicate","represent","defaultStyle","styleAliases"],jf=["scalar","sequence","mapping"];function Pf($){var U={};if($!==null)Object.keys($).forEach(function(J){$[J].forEach(function(G){U[String(G)]=J})});return U}function Bf($,U){if(U=U||{},Object.keys(U).forEach(function(J){if(gf.indexOf(J)===-1)throw new hg('Unknown option "'+J+'" is met in definition of "'+$+'" YAML type.')}),this.tag=$,this.kind=U.kind||null,this.resolve=U.resolve||function(){return!0},this.construct=U.construct||function(J){return J},this.instanceOf=U.instanceOf||null,this.predicate=U.predicate||null,this.represent=U.represent||null,this.defaultStyle=U.defaultStyle||null,this.styleAliases=Pf(U.styleAliases||null),jf.indexOf(this.kind)===-1)throw new hg('Unknown kind "'+this.kind+'" is specified for "'+$+'" YAML type.')}rg.exports=Bf});var oq=J$((tQ$,ig)=>{var lg=cq(),GX=S8(),Sf=X0();function n7($,U,J){var G=[];return $.include.forEach(function(q){J=n7(q,U,J)}),$[U].forEach(function(q){J.forEach(function(I,Q){if(I.tag===q.tag&&I.kind===q.kind)G.push(Q)}),J.push(q)}),J.filter(function(q,I){return G.indexOf(I)===-1})}function Lf(){var $={scalar:{},sequence:{},mapping:{},fallback:{}},U,J;function G(q){$[q.kind][q.tag]=$.fallback[q.tag]=q}for(U=0,J=arguments.length;U<J;U+=1)arguments[U].forEach(G);return $}function L8($){this.include=$.include||[],this.implicit=$.implicit||[],this.explicit=$.explicit||[],this.implicit.forEach(function(U){if(U.loadKind&&U.loadKind!=="scalar")throw new GX("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.")}),this.compiledImplicit=n7(this,"implicit",[]),this.compiledExplicit=n7(this,"explicit",[]),this.compiledTypeMap=Lf(this.compiledImplicit,this.compiledExplicit)}L8.DEFAULT=null;L8.create=function(){var U,J;switch(arguments.length){case 1:U=L8.DEFAULT,J=arguments[0];break;case 2:U=arguments[0],J=arguments[1];break;default:throw new GX("Wrong number of arguments for Schema.create function")}if(U=lg.toArray(U),J=lg.toArray(J),!U.every(function(G){return G instanceof L8}))throw new GX("Specified list of super schemas (or a single Schema object) contains a non-Schema object.");if(!J.every(function(G){return G instanceof Sf}))throw new GX("Specified list of YAML types (or a single Type object) contains a non-Type object.");return new L8({include:U,explicit:J})};ig.exports=L8});var dg=J$((eQ$,pg)=>{var Ef=X0();pg.exports=new Ef("tag:yaml.org,2002:str",{kind:"scalar",construct:function($){return $!==null?$:""}})});var cg=J$(($D$,ng)=>{var Cf=X0();ng.exports=new Cf("tag:yaml.org,2002:seq",{kind:"sequence",construct:function($){return $!==null?$:[]}})});var ag=J$((UD$,og)=>{var _f=X0();og.exports=new _f("tag:yaml.org,2002:map",{kind:"mapping",construct:function($){return $!==null?$:{}}})});var IX=J$((JD$,sg)=>{var vf=oq();sg.exports=new vf({explicit:[dg(),cg(),ag()]})});var eg=J$((qD$,tg)=>{var Ff=X0();function bf($){if($===null)return!0;var U=$.length;return U===1&&$==="~"||U===4&&($==="null"||$==="Null"||$==="NULL")}function uf(){return null}function kf($){return $===null}tg.exports=new Ff("tag:yaml.org,2002:null",{kind:"scalar",resolve:bf,construct:uf,predicate:kf,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"}},defaultStyle:"lowercase"})});var Uj=J$((GD$,$j)=>{var xf=X0();function ff($){if($===null)return!1;var U=$.length;return U===4&&($==="true"||$==="True"||$==="TRUE")||U===5&&($==="false"||$==="False"||$==="FALSE")}function yf($){return $==="true"||$==="True"||$==="TRUE"}function mf($){return Object.prototype.toString.call($)==="[object Boolean]"}$j.exports=new xf("tag:yaml.org,2002:bool",{kind:"scalar",resolve:ff,construct:yf,predicate:mf,represent:{lowercase:function($){return $?"true":"false"},uppercase:function($){return $?"TRUE":"FALSE"},camelcase:function($){return $?"True":"False"}},defaultStyle:"lowercase"})});var qj=J$((ID$,Jj)=>{var hf=cq(),rf=X0();function lf($){return 48<=$&&$<=57||65<=$&&$<=70||97<=$&&$<=102}function pf($){return 48<=$&&$<=55}function df($){return 48<=$&&$<=57}function nf($){if($===null)return!1;var U=$.length,J=0,G=!1,q;if(!U)return!1;if(q=$[J],q==="-"||q==="+")q=$[++J];if(q==="0"){if(J+1===U)return!0;if(q=$[++J],q==="b"){J++;for(;J<U;J++){if(q=$[J],q==="_")continue;if(q!=="0"&&q!=="1")return!1;G=!0}return G&&q!=="_"}if(q==="x"){J++;for(;J<U;J++){if(q=$[J],q==="_")continue;if(!lf($.charCodeAt(J)))return!1;G=!0}return G&&q!=="_"}for(;J<U;J++){if(q=$[J],q==="_")continue;if(!pf($.charCodeAt(J)))return!1;G=!0}return G&&q!=="_"}if(q==="_")return!1;for(;J<U;J++){if(q=$[J],q==="_")continue;if(q===":")break;if(!df($.charCodeAt(J)))return!1;G=!0}if(!G||q==="_")return!1;if(q!==":")return!0;return/^(:[0-5]?[0-9])+$/.test($.slice(J))}function cf($){var U=$,J=1,G,q,I=[];if(U.indexOf("_")!==-1)U=U.replace(/_/g,"");if(G=U[0],G==="-"||G==="+"){if(G==="-")J=-1;U=U.slice(1),G=U[0]}if(U==="0")return 0;if(G==="0"){if(U[1]==="b")return J*parseInt(U.slice(2),2);if(U[1]==="x")return J*parseInt(U,16);return J*parseInt(U,8)}if(U.indexOf(":")!==-1)return U.split(":").forEach(function(Q){I.unshift(parseInt(Q,10))}),U=0,q=1,I.forEach(function(Q){U+=Q*q,q*=60}),J*U;return J*parseInt(U,10)}function of($){return Object.prototype.toString.call($)==="[object Number]"&&($%1===0&&!hf.isNegativeZero($))}Jj.exports=new rf("tag:yaml.org,2002:int",{kind:"scalar",resolve:nf,construct:cf,predicate:of,represent:{binary:function($){return $>=0?"0b"+$.toString(2):"-0b"+$.toString(2).slice(1)},octal:function($){return $>=0?"0"+$.toString(8):"-0"+$.toString(8).slice(1)},decimal:function($){return $.toString(10)},hexadecimal:function($){return $>=0?"0x"+$.toString(16).toUpperCase():"-0x"+$.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}})});var Qj=J$((QD$,Ij)=>{var Gj=cq(),af=X0(),sf=new RegExp("^(?:[-+]?(?:0|[1-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\\.[0-9_]*|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function tf($){if($===null)return!1;if(!sf.test($)||$[$.length-1]==="_")return!1;return!0}function ef($){var U,J,G,q;if(U=$.replace(/_/g,"").toLowerCase(),J=U[0]==="-"?-1:1,q=[],"+-".indexOf(U[0])>=0)U=U.slice(1);if(U===".inf")return J===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY;else if(U===".nan")return NaN;else if(U.indexOf(":")>=0)return U.split(":").forEach(function(I){q.unshift(parseFloat(I,10))}),U=0,G=1,q.forEach(function(I){U+=I*G,G*=60}),J*U;return J*parseFloat(U,10)}var $y=/^[-+]?[0-9]+e/;function Uy($,U){var J;if(isNaN($))switch(U){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===$)switch(U){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===$)switch(U){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(Gj.isNegativeZero($))return"-0.0";return J=$.toString(10),$y.test(J)?J.replace("e",".e"):J}function Jy($){return Object.prototype.toString.call($)==="[object Number]"&&($%1!==0||Gj.isNegativeZero($))}Ij.exports=new af("tag:yaml.org,2002:float",{kind:"scalar",resolve:tf,construct:ef,predicate:Jy,represent:Uy,defaultStyle:"lowercase"})});var c7=J$((DD$,Dj)=>{var qy=oq();Dj.exports=new qy({include:[IX()],implicit:[eg(),Uj(),qj(),Qj()]})});var o7=J$((XD$,Xj)=>{var Gy=oq();Xj.exports=new Gy({include:[c7()]})});var Oj=J$((YD$,Wj)=>{var Iy=X0(),Yj=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),Vj=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");function Qy($){if($===null)return!1;if(Yj.exec($)!==null)return!0;if(Vj.exec($)!==null)return!0;return!1}function Dy($){var U,J,G,q,I,Q,D,X=0,Y=null,V,W,O;if(U=Yj.exec($),U===null)U=Vj.exec($);if(U===null)throw Error("Date resolve error");if(J=+U[1],G=+U[2]-1,q=+U[3],!U[4])return new Date(Date.UTC(J,G,q));if(I=+U[4],Q=+U[5],D=+U[6],U[7]){X=U[7].slice(0,3);while(X.length<3)X+="0";X=+X}if(U[9]){if(V=+U[10],W=+(U[11]||0),Y=(V*60+W)*60000,U[9]==="-")Y=-Y}if(O=new Date(Date.UTC(J,G,q,I,Q,D,X)),Y)O.setTime(O.getTime()-Y);return O}function Xy($){return $.toISOString()}Wj.exports=new Iy("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:Qy,construct:Dy,instanceOf:Date,represent:Xy})});var Rj=J$((VD$,Zj)=>{var Yy=X0();function Vy($){return $==="<<"||$===null}Zj.exports=new Yy("tag:yaml.org,2002:merge",{kind:"scalar",resolve:Vy})});var wj=J$((WD$,Nj)=>{var aq;try{a7=WU,aq=a7("buffer").Buffer}catch($){}var a7,Wy=X0(),s7=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
|
|
113
|
+
\r`;function Oy($){if($===null)return!1;var U,J,G=0,q=$.length,I=s7;for(J=0;J<q;J++){if(U=I.indexOf($.charAt(J)),U>64)continue;if(U<0)return!1;G+=6}return G%8===0}function Zy($){var U,J,G=$.replace(/[\r\n=]/g,""),q=G.length,I=s7,Q=0,D=[];for(U=0;U<q;U++){if(U%4===0&&U)D.push(Q>>16&255),D.push(Q>>8&255),D.push(Q&255);Q=Q<<6|I.indexOf(G.charAt(U))}if(J=q%4*6,J===0)D.push(Q>>16&255),D.push(Q>>8&255),D.push(Q&255);else if(J===18)D.push(Q>>10&255),D.push(Q>>2&255);else if(J===12)D.push(Q>>4&255);if(aq)return aq.from?aq.from(D):new aq(D);return D}function Ry($){var U="",J=0,G,q,I=$.length,Q=s7;for(G=0;G<I;G++){if(G%3===0&&G)U+=Q[J>>18&63],U+=Q[J>>12&63],U+=Q[J>>6&63],U+=Q[J&63];J=(J<<8)+$[G]}if(q=I%3,q===0)U+=Q[J>>18&63],U+=Q[J>>12&63],U+=Q[J>>6&63],U+=Q[J&63];else if(q===2)U+=Q[J>>10&63],U+=Q[J>>4&63],U+=Q[J<<2&63],U+=Q[64];else if(q===1)U+=Q[J>>2&63],U+=Q[J<<4&63],U+=Q[64],U+=Q[64];return U}function Ny($){return aq&&aq.isBuffer($)}Nj.exports=new Wy("tag:yaml.org,2002:binary",{kind:"scalar",resolve:Oy,construct:Zy,predicate:Ny,represent:Ry})});var Hj=J$((ZD$,Mj)=>{var wy=X0(),My=Object.prototype.hasOwnProperty,Hy=Object.prototype.toString;function Ty($){if($===null)return!0;var U=[],J,G,q,I,Q,D=$;for(J=0,G=D.length;J<G;J+=1){if(q=D[J],Q=!1,Hy.call(q)!=="[object Object]")return!1;for(I in q)if(My.call(q,I))if(!Q)Q=!0;else return!1;if(!Q)return!1;if(U.indexOf(I)===-1)U.push(I);else return!1}return!0}function zy($){return $!==null?$:[]}Mj.exports=new wy("tag:yaml.org,2002:omap",{kind:"sequence",resolve:Ty,construct:zy})});var zj=J$((RD$,Tj)=>{var Ay=X0(),Ky=Object.prototype.toString;function gy($){if($===null)return!0;var U,J,G,q,I,Q=$;I=Array(Q.length);for(U=0,J=Q.length;U<J;U+=1){if(G=Q[U],Ky.call(G)!=="[object Object]")return!1;if(q=Object.keys(G),q.length!==1)return!1;I[U]=[q[0],G[q[0]]]}return!0}function jy($){if($===null)return[];var U,J,G,q,I,Q=$;I=Array(Q.length);for(U=0,J=Q.length;U<J;U+=1)G=Q[U],q=Object.keys(G),I[U]=[q[0],G[q[0]]];return I}Tj.exports=new Ay("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:gy,construct:jy})});var Kj=J$((ND$,Aj)=>{var Py=X0(),By=Object.prototype.hasOwnProperty;function Sy($){if($===null)return!0;var U,J=$;for(U in J)if(By.call(J,U)){if(J[U]!==null)return!1}return!0}function Ly($){return $!==null?$:{}}Aj.exports=new Py("tag:yaml.org,2002:set",{kind:"mapping",resolve:Sy,construct:Ly})});var E8=J$((wD$,gj)=>{var Ey=oq();gj.exports=new Ey({include:[o7()],implicit:[Oj(),Rj()],explicit:[wj(),Hj(),zj(),Kj()]})});var Pj=J$((MD$,jj)=>{var Cy=X0();function _y(){return!0}function vy(){return}function Fy(){return""}function by($){return typeof $>"u"}jj.exports=new Cy("tag:yaml.org,2002:js/undefined",{kind:"scalar",resolve:_y,construct:vy,predicate:by,represent:Fy})});var Sj=J$((HD$,Bj)=>{var uy=X0();function ky($){if($===null)return!1;if($.length===0)return!1;var U=$,J=/\/([gim]*)$/.exec($),G="";if(U[0]==="/"){if(J)G=J[1];if(G.length>3)return!1;if(U[U.length-G.length-1]!=="/")return!1}return!0}function xy($){var U=$,J=/\/([gim]*)$/.exec($),G="";if(U[0]==="/"){if(J)G=J[1];U=U.slice(1,U.length-G.length-1)}return new RegExp(U,G)}function fy($){var U="/"+$.source+"/";if($.global)U+="g";if($.multiline)U+="m";if($.ignoreCase)U+="i";return U}function yy($){return Object.prototype.toString.call($)==="[object RegExp]"}Bj.exports=new uy("tag:yaml.org,2002:js/regexp",{kind:"scalar",resolve:ky,construct:xy,predicate:yy,represent:fy})});var Ej=J$((TD$,Lj)=>{var QX;try{t7=WU,QX=t7("esprima")}catch($){if(typeof window<"u")QX=window.esprima}var t7,my=X0();function hy($){if($===null)return!1;try{var U="("+$+")",J=QX.parse(U,{range:!0});if(J.type!=="Program"||J.body.length!==1||J.body[0].type!=="ExpressionStatement"||J.body[0].expression.type!=="ArrowFunctionExpression"&&J.body[0].expression.type!=="FunctionExpression")return!1;return!0}catch(G){return!1}}function ry($){var U="("+$+")",J=QX.parse(U,{range:!0}),G=[],q;if(J.type!=="Program"||J.body.length!==1||J.body[0].type!=="ExpressionStatement"||J.body[0].expression.type!=="ArrowFunctionExpression"&&J.body[0].expression.type!=="FunctionExpression")throw Error("Failed to resolve function");if(J.body[0].expression.params.forEach(function(I){G.push(I.name)}),q=J.body[0].expression.body.range,J.body[0].expression.body.type==="BlockStatement")return Function(G,U.slice(q[0]+1,q[1]-1));return Function(G,"return "+U.slice(q[0],q[1]))}function ly($){return $.toString()}function iy($){return Object.prototype.toString.call($)==="[object Function]"}Lj.exports=new my("tag:yaml.org,2002:js/function",{kind:"scalar",resolve:hy,construct:ry,predicate:iy,represent:ly})});var _4=J$((AD$,_j)=>{var Cj=oq();_j.exports=Cj.DEFAULT=new Cj({include:[E8()],explicit:[Pj(),Sj(),Ej()]})});var sj=J$((Rm,v4)=>{var NJ=cq(),fj=S8(),py=mg(),yj=E8(),dy=_4(),tJ=Object.prototype.hasOwnProperty,DX=1,mj=2,hj=3,XX=4,e7=1,ny=2,vj=3,cy=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,oy=/[\x85\u2028\u2029]/,ay=/[,\[\]\{\}]/,rj=/^(?:!|!!|![a-z\-]+!)$/i,lj=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function Fj($){return Object.prototype.toString.call($)}function tU($){return $===10||$===13}function sq($){return $===9||$===32}function IU($){return $===9||$===32||$===10||$===13}function C8($){return $===44||$===91||$===93||$===123||$===125}function sy($){var U;if(48<=$&&$<=57)return $-48;if(U=$|32,97<=U&&U<=102)return U-97+10;return-1}function ty($){if($===120)return 2;if($===117)return 4;if($===85)return 8;return 0}function ey($){if(48<=$&&$<=57)return $-48;return-1}function bj($){return $===48?"\x00":$===97?"\x07":$===98?"\b":$===116?"\t":$===9?"\t":$===110?`
|
|
114
|
+
`:$===118?"\v":$===102?"\f":$===114?"\r":$===101?"\x1B":$===32?" ":$===34?'"':$===47?"/":$===92?"\\":$===78?"\x85":$===95?"\xA0":$===76?"\u2028":$===80?"\u2029":""}function $m($){if($<=65535)return String.fromCharCode($);return String.fromCharCode(($-65536>>10)+55296,($-65536&1023)+56320)}function ij($,U,J){if(U==="__proto__")Object.defineProperty($,U,{configurable:!0,enumerable:!0,writable:!0,value:J});else $[U]=J}var pj=Array(256),dj=Array(256);for(aJ=0;aJ<256;aJ++)pj[aJ]=bj(aJ)?1:0,dj[aJ]=bj(aJ);var aJ;function Um($,U){this.input=$,this.filename=U.filename||null,this.schema=U.schema||dy,this.onWarning=U.onWarning||null,this.legacy=U.legacy||!1,this.json=U.json||!1,this.listener=U.listener||null,this.maxTotalMergeKeys=typeof U.maxTotalMergeKeys==="number"?U.maxTotalMergeKeys:1e4,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=$.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.totalMergeKeys=0,this.documents=[]}function nj($,U){return new fj(U,new py($.filename,$.input,$.position,$.line,$.position-$.lineStart))}function L$($,U){throw nj($,U)}function YX($,U){if($.onWarning)$.onWarning.call(null,nj($,U))}var uj={YAML:function(U,J,G){var q,I,Q;if(U.version!==null)L$(U,"duplication of %YAML directive");if(G.length!==1)L$(U,"YAML directive accepts exactly one argument");if(q=/^([0-9]+)\.([0-9]+)$/.exec(G[0]),q===null)L$(U,"ill-formed argument of the YAML directive");if(I=parseInt(q[1],10),Q=parseInt(q[2],10),I!==1)L$(U,"unacceptable YAML version of the document");if(U.version=G[0],U.checkLineBreaks=Q<2,Q!==1&&Q!==2)YX(U,"unsupported YAML version of the document")},TAG:function(U,J,G){var q,I;if(G.length!==2)L$(U,"TAG directive accepts exactly two arguments");if(q=G[0],I=G[1],!rj.test(q))L$(U,"ill-formed tag handle (first argument) of the TAG directive");if(tJ.call(U.tagMap,q))L$(U,'there is a previously declared suffix for "'+q+'" tag handle');if(!lj.test(I))L$(U,"ill-formed tag prefix (second argument) of the TAG directive");U.tagMap[q]=I}};function sJ($,U,J,G){var q,I,Q,D;if(U<J){if(D=$.input.slice(U,J),G){for(q=0,I=D.length;q<I;q+=1)if(Q=D.charCodeAt(q),!(Q===9||32<=Q&&Q<=1114111))L$($,"expected valid JSON character")}else if(cy.test(D))L$($,"the stream contains non-printable characters");$.result+=D}}function kj($,U,J,G){var q,I,Q,D;if(!NJ.isObject(J))L$($,"cannot merge mappings; the provided source object is unacceptable");q=Object.keys(J);for(Q=0,D=q.length;Q<D;Q+=1){if(I=q[Q],$.maxTotalMergeKeys!==-1&&++$.totalMergeKeys>$.maxTotalMergeKeys)L$($,"merge keys exceeded maxTotalMergeKeys ("+$.maxTotalMergeKeys+")");if(!tJ.call(U,I))ij(U,I,J[I]),G[I]=!0}}function _8($,U,J,G,q,I,Q,D){var X,Y;if(Array.isArray(q)){q=Array.prototype.slice.call(q);for(X=0,Y=q.length;X<Y;X+=1){if(Array.isArray(q[X]))L$($,"nested arrays are not supported inside keys");if(typeof q==="object"&&Fj(q[X])==="[object Object]")q[X]="[object Object]"}}if(typeof q==="object"&&Fj(q)==="[object Object]")q="[object Object]";if(q=String(q),U===null)U={};if(G==="tag:yaml.org,2002:merge")if(Array.isArray(I))for(X=0,Y=I.length;X<Y;X+=1)kj($,U,I[X],J);else kj($,U,I,J);else{if(!$.json&&!tJ.call(J,q)&&tJ.call(U,q))$.line=Q||$.line,$.position=D||$.position,L$($,"duplicated mapping key");ij(U,q,I),delete J[q]}return U}function $N($){var U=$.input.charCodeAt($.position);if(U===10)$.position++;else if(U===13){if($.position++,$.input.charCodeAt($.position)===10)$.position++}else L$($,"a line break is expected");$.line+=1,$.lineStart=$.position}function G0($,U,J){var G=0,q=$.input.charCodeAt($.position);while(q!==0){while(sq(q))q=$.input.charCodeAt(++$.position);if(U&&q===35)do q=$.input.charCodeAt(++$.position);while(q!==10&&q!==13&&q!==0);if(tU(q)){$N($),q=$.input.charCodeAt($.position),G++,$.lineIndent=0;while(q===32)$.lineIndent++,q=$.input.charCodeAt(++$.position)}else break}if(J!==-1&&G!==0&&$.lineIndent<J)YX($,"deficient indentation");return G}function VX($){var U=$.position,J;if(J=$.input.charCodeAt(U),(J===45||J===46)&&J===$.input.charCodeAt(U+1)&&J===$.input.charCodeAt(U+2)){if(U+=3,J=$.input.charCodeAt(U),J===0||IU(J))return!0}return!1}function UN($,U){if(U===1)$.result+=" ";else if(U>1)$.result+=NJ.repeat(`
|
|
115
|
+
`,U-1)}function Jm($,U,J){var G,q,I,Q,D,X,Y,V,W=$.kind,O=$.result,Z;if(Z=$.input.charCodeAt($.position),IU(Z)||C8(Z)||Z===35||Z===38||Z===42||Z===33||Z===124||Z===62||Z===39||Z===34||Z===37||Z===64||Z===96)return!1;if(Z===63||Z===45){if(q=$.input.charCodeAt($.position+1),IU(q)||J&&C8(q))return!1}$.kind="scalar",$.result="",I=Q=$.position,D=!1;while(Z!==0){if(Z===58){if(q=$.input.charCodeAt($.position+1),IU(q)||J&&C8(q))break}else if(Z===35){if(G=$.input.charCodeAt($.position-1),IU(G))break}else if($.position===$.lineStart&&VX($)||J&&C8(Z))break;else if(tU(Z))if(X=$.line,Y=$.lineStart,V=$.lineIndent,G0($,!1,-1),$.lineIndent>=U){D=!0,Z=$.input.charCodeAt($.position);continue}else{$.position=Q,$.line=X,$.lineStart=Y,$.lineIndent=V;break}if(D)sJ($,I,Q,!1),UN($,$.line-X),I=Q=$.position,D=!1;if(!sq(Z))Q=$.position+1;Z=$.input.charCodeAt(++$.position)}if(sJ($,I,Q,!1),$.result)return!0;return $.kind=W,$.result=O,!1}function qm($,U){var J,G,q;if(J=$.input.charCodeAt($.position),J!==39)return!1;$.kind="scalar",$.result="",$.position++,G=q=$.position;while((J=$.input.charCodeAt($.position))!==0)if(J===39)if(sJ($,G,$.position,!0),J=$.input.charCodeAt(++$.position),J===39)G=$.position,$.position++,q=$.position;else return!0;else if(tU(J))sJ($,G,q,!0),UN($,G0($,!1,U)),G=q=$.position;else if($.position===$.lineStart&&VX($))L$($,"unexpected end of the document within a single quoted scalar");else $.position++,q=$.position;L$($,"unexpected end of the stream within a single quoted scalar")}function Gm($,U){var J,G,q,I,Q,D;if(D=$.input.charCodeAt($.position),D!==34)return!1;$.kind="scalar",$.result="",$.position++,J=G=$.position;while((D=$.input.charCodeAt($.position))!==0)if(D===34)return sJ($,J,$.position,!0),$.position++,!0;else if(D===92){if(sJ($,J,$.position,!0),D=$.input.charCodeAt(++$.position),tU(D))G0($,!1,U);else if(D<256&&pj[D])$.result+=dj[D],$.position++;else if((Q=ty(D))>0){q=Q,I=0;for(;q>0;q--)if(D=$.input.charCodeAt(++$.position),(Q=sy(D))>=0)I=(I<<4)+Q;else L$($,"expected hexadecimal character");$.result+=$m(I),$.position++}else L$($,"unknown escape sequence");J=G=$.position}else if(tU(D))sJ($,J,G,!0),UN($,G0($,!1,U)),J=G=$.position;else if($.position===$.lineStart&&VX($))L$($,"unexpected end of the document within a double quoted scalar");else $.position++,G=$.position;L$($,"unexpected end of the stream within a double quoted scalar")}function Im($,U){var J=!0,G,q=$.tag,I,Q=$.anchor,D,X,Y,V,W,O={},Z,M,w,H;if(H=$.input.charCodeAt($.position),H===91)X=93,W=!1,I=[];else if(H===123)X=125,W=!0,I={};else return!1;if($.anchor!==null)$.anchorMap[$.anchor]=I;H=$.input.charCodeAt(++$.position);while(H!==0){if(G0($,!0,U),H=$.input.charCodeAt($.position),H===X)return $.position++,$.tag=q,$.anchor=Q,$.kind=W?"mapping":"sequence",$.result=I,!0;else if(!J)L$($,"missed comma between flow collection entries");if(M=Z=w=null,Y=V=!1,H===63){if(D=$.input.charCodeAt($.position+1),IU(D))Y=V=!0,$.position++,G0($,!0,U)}if(G=$.line,v8($,U,DX,!1,!0),M=$.tag,Z=$.result,G0($,!0,U),H=$.input.charCodeAt($.position),(V||$.line===G)&&H===58)Y=!0,H=$.input.charCodeAt(++$.position),G0($,!0,U),v8($,U,DX,!1,!0),w=$.result;if(W)_8($,I,O,M,Z,w);else if(Y)I.push(_8($,null,O,M,Z,w));else I.push(Z);if(G0($,!0,U),H=$.input.charCodeAt($.position),H===44)J=!0,H=$.input.charCodeAt(++$.position);else J=!1}L$($,"unexpected end of the stream within a flow collection")}function Qm($,U){var J,G,q=e7,I=!1,Q=!1,D=U,X=0,Y=!1,V,W;if(W=$.input.charCodeAt($.position),W===124)G=!1;else if(W===62)G=!0;else return!1;$.kind="scalar",$.result="";while(W!==0)if(W=$.input.charCodeAt(++$.position),W===43||W===45)if(e7===q)q=W===43?vj:ny;else L$($,"repeat of a chomping mode identifier");else if((V=ey(W))>=0)if(V===0)L$($,"bad explicit indentation width of a block scalar; it cannot be less than one");else if(!Q)D=U+V-1,Q=!0;else L$($,"repeat of an indentation width identifier");else break;if(sq(W)){do W=$.input.charCodeAt(++$.position);while(sq(W));if(W===35)do W=$.input.charCodeAt(++$.position);while(!tU(W)&&W!==0)}while(W!==0){$N($),$.lineIndent=0,W=$.input.charCodeAt($.position);while((!Q||$.lineIndent<D)&&W===32)$.lineIndent++,W=$.input.charCodeAt(++$.position);if(!Q&&$.lineIndent>D)D=$.lineIndent;if(tU(W)){X++;continue}if($.lineIndent<D){if(q===vj)$.result+=NJ.repeat(`
|
|
116
|
+
`,I?1+X:X);else if(q===e7){if(I)$.result+=`
|
|
117
|
+
`}break}if(G)if(sq(W))Y=!0,$.result+=NJ.repeat(`
|
|
118
|
+
`,I?1+X:X);else if(Y)Y=!1,$.result+=NJ.repeat(`
|
|
119
|
+
`,X+1);else if(X===0){if(I)$.result+=" "}else $.result+=NJ.repeat(`
|
|
120
|
+
`,X);else $.result+=NJ.repeat(`
|
|
121
|
+
`,I?1+X:X);I=!0,Q=!0,X=0,J=$.position;while(!tU(W)&&W!==0)W=$.input.charCodeAt(++$.position);sJ($,J,$.position,!1)}return!0}function xj($,U){var J,G=$.tag,q=$.anchor,I=[],Q,D=!1,X;if($.anchor!==null)$.anchorMap[$.anchor]=I;X=$.input.charCodeAt($.position);while(X!==0){if(X!==45)break;if(Q=$.input.charCodeAt($.position+1),!IU(Q))break;if(D=!0,$.position++,G0($,!0,-1)){if($.lineIndent<=U){I.push(null),X=$.input.charCodeAt($.position);continue}}if(J=$.line,v8($,U,hj,!1,!0),I.push($.result),G0($,!0,-1),X=$.input.charCodeAt($.position),($.line===J||$.lineIndent>U)&&X!==0)L$($,"bad indentation of a sequence entry");else if($.lineIndent<U)break}if(D)return $.tag=G,$.anchor=q,$.kind="sequence",$.result=I,!0;return!1}function Dm($,U,J){var G,q,I,Q,D=$.tag,X=$.anchor,Y={},V={},W=null,O=null,Z=null,M=!1,w=!1,H;if($.anchor!==null)$.anchorMap[$.anchor]=Y;H=$.input.charCodeAt($.position);while(H!==0){if(G=$.input.charCodeAt($.position+1),I=$.line,Q=$.position,(H===63||H===58)&&IU(G)){if(H===63){if(M)_8($,Y,V,W,O,null),W=O=Z=null;w=!0,M=!0,q=!0}else if(M)M=!1,q=!0;else L$($,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line");$.position+=1,H=G}else if(v8($,J,mj,!1,!0))if($.line===I){H=$.input.charCodeAt($.position);while(sq(H))H=$.input.charCodeAt(++$.position);if(H===58){if(H=$.input.charCodeAt(++$.position),!IU(H))L$($,"a whitespace character is expected after the key-value separator within a block mapping");if(M)_8($,Y,V,W,O,null),W=O=Z=null;w=!0,M=!1,q=!1,W=$.tag,O=$.result}else if(w)L$($,"can not read an implicit mapping pair; a colon is missed");else return $.tag=D,$.anchor=X,!0}else if(w)L$($,"can not read a block mapping entry; a multiline key may not be an implicit key");else return $.tag=D,$.anchor=X,!0;else break;if($.line===I||$.lineIndent>U){if(v8($,U,XX,!0,q))if(M)O=$.result;else Z=$.result;if(!M)_8($,Y,V,W,O,Z,I,Q),W=O=Z=null;G0($,!0,-1),H=$.input.charCodeAt($.position)}if($.lineIndent>U&&H!==0)L$($,"bad indentation of a mapping entry");else if($.lineIndent<U)break}if(M)_8($,Y,V,W,O,null);if(w)$.tag=D,$.anchor=X,$.kind="mapping",$.result=Y;return w}function Xm($){var U,J=!1,G=!1,q,I,Q;if(Q=$.input.charCodeAt($.position),Q!==33)return!1;if($.tag!==null)L$($,"duplication of a tag property");if(Q=$.input.charCodeAt(++$.position),Q===60)J=!0,Q=$.input.charCodeAt(++$.position);else if(Q===33)G=!0,q="!!",Q=$.input.charCodeAt(++$.position);else q="!";if(U=$.position,J){do Q=$.input.charCodeAt(++$.position);while(Q!==0&&Q!==62);if($.position<$.length)I=$.input.slice(U,$.position),Q=$.input.charCodeAt(++$.position);else L$($,"unexpected end of the stream within a verbatim tag")}else{while(Q!==0&&!IU(Q)){if(Q===33)if(!G){if(q=$.input.slice(U-1,$.position+1),!rj.test(q))L$($,"named tag handle cannot contain such characters");G=!0,U=$.position+1}else L$($,"tag suffix cannot contain exclamation marks");Q=$.input.charCodeAt(++$.position)}if(I=$.input.slice(U,$.position),ay.test(I))L$($,"tag suffix cannot contain flow indicator characters")}if(I&&!lj.test(I))L$($,"tag name cannot contain such characters: "+I);if(J)$.tag=I;else if(tJ.call($.tagMap,q))$.tag=$.tagMap[q]+I;else if(q==="!")$.tag="!"+I;else if(q==="!!")$.tag="tag:yaml.org,2002:"+I;else L$($,'undeclared tag handle "'+q+'"');return!0}function Ym($){var U,J;if(J=$.input.charCodeAt($.position),J!==38)return!1;if($.anchor!==null)L$($,"duplication of an anchor property");J=$.input.charCodeAt(++$.position),U=$.position;while(J!==0&&!IU(J)&&!C8(J))J=$.input.charCodeAt(++$.position);if($.position===U)L$($,"name of an anchor node must contain at least one character");return $.anchor=$.input.slice(U,$.position),!0}function Vm($){var U,J,G;if(G=$.input.charCodeAt($.position),G!==42)return!1;G=$.input.charCodeAt(++$.position),U=$.position;while(G!==0&&!IU(G)&&!C8(G))G=$.input.charCodeAt(++$.position);if($.position===U)L$($,"name of an alias node must contain at least one character");if(J=$.input.slice(U,$.position),!tJ.call($.anchorMap,J))L$($,'unidentified alias "'+J+'"');return $.result=$.anchorMap[J],G0($,!0,-1),!0}function v8($,U,J,G,q){var I,Q,D,X=1,Y=!1,V=!1,W,O,Z,M,w;if($.listener!==null)$.listener("open",$);if($.tag=null,$.anchor=null,$.kind=null,$.result=null,I=Q=D=XX===J||hj===J,G){if(G0($,!0,-1)){if(Y=!0,$.lineIndent>U)X=1;else if($.lineIndent===U)X=0;else if($.lineIndent<U)X=-1}}if(X===1)while(Xm($)||Ym($))if(G0($,!0,-1)){if(Y=!0,D=I,$.lineIndent>U)X=1;else if($.lineIndent===U)X=0;else if($.lineIndent<U)X=-1}else D=!1;if(D)D=Y||q;if(X===1||XX===J){if(DX===J||mj===J)M=U;else M=U+1;if(w=$.position-$.lineStart,X===1)if(D&&(xj($,w)||Dm($,w,M))||Im($,M))V=!0;else{if(Q&&Qm($,M)||qm($,M)||Gm($,M))V=!0;else if(Vm($)){if(V=!0,$.tag!==null||$.anchor!==null)L$($,"alias node should not have any properties")}else if(Jm($,M,DX===J)){if(V=!0,$.tag===null)$.tag="?"}if($.anchor!==null)$.anchorMap[$.anchor]=$.result}else if(X===0)V=D&&xj($,w)}if($.tag!==null&&$.tag!=="!")if($.tag==="?"){if($.result!==null&&$.kind!=="scalar")L$($,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+$.kind+'"');for(W=0,O=$.implicitTypes.length;W<O;W+=1)if(Z=$.implicitTypes[W],Z.resolve($.result)){if($.result=Z.construct($.result),$.tag=Z.tag,$.anchor!==null)$.anchorMap[$.anchor]=$.result;break}}else if(tJ.call($.typeMap[$.kind||"fallback"],$.tag)){if(Z=$.typeMap[$.kind||"fallback"][$.tag],$.result!==null&&Z.kind!==$.kind)L$($,"unacceptable node kind for !<"+$.tag+'> tag; it should be "'+Z.kind+'", not "'+$.kind+'"');if(!Z.resolve($.result))L$($,"cannot resolve a node with !<"+$.tag+"> explicit tag");else if($.result=Z.construct($.result),$.anchor!==null)$.anchorMap[$.anchor]=$.result}else L$($,"unknown tag !<"+$.tag+">");if($.listener!==null)$.listener("close",$);return $.tag!==null||$.anchor!==null||V}function Wm($){var U=$.position,J,G,q,I=!1,Q;$.version=null,$.checkLineBreaks=$.legacy,$.tagMap={},$.anchorMap={};while((Q=$.input.charCodeAt($.position))!==0){if(G0($,!0,-1),Q=$.input.charCodeAt($.position),$.lineIndent>0||Q!==37)break;I=!0,Q=$.input.charCodeAt(++$.position),J=$.position;while(Q!==0&&!IU(Q))Q=$.input.charCodeAt(++$.position);if(G=$.input.slice(J,$.position),q=[],G.length<1)L$($,"directive name must not be less than one character in length");while(Q!==0){while(sq(Q))Q=$.input.charCodeAt(++$.position);if(Q===35){do Q=$.input.charCodeAt(++$.position);while(Q!==0&&!tU(Q));break}if(tU(Q))break;J=$.position;while(Q!==0&&!IU(Q))Q=$.input.charCodeAt(++$.position);q.push($.input.slice(J,$.position))}if(Q!==0)$N($);if(tJ.call(uj,G))uj[G]($,G,q);else YX($,'unknown document directive "'+G+'"')}if(G0($,!0,-1),$.lineIndent===0&&$.input.charCodeAt($.position)===45&&$.input.charCodeAt($.position+1)===45&&$.input.charCodeAt($.position+2)===45)$.position+=3,G0($,!0,-1);else if(I)L$($,"directives end mark is expected");if(v8($,$.lineIndent-1,XX,!1,!0),G0($,!0,-1),$.checkLineBreaks&&oy.test($.input.slice(U,$.position)))YX($,"non-ASCII line breaks are interpreted as content");if($.documents.push($.result),$.position===$.lineStart&&VX($)){if($.input.charCodeAt($.position)===46)$.position+=3,G0($,!0,-1);return}if($.position<$.length-1)L$($,"end of the stream or a document separator is expected");else return}function cj($,U){if($=String($),U=U||{},$.length!==0){if($.charCodeAt($.length-1)!==10&&$.charCodeAt($.length-1)!==13)$+=`
|
|
122
|
+
`;if($.charCodeAt(0)===65279)$=$.slice(1)}var J=new Um($,U),G=$.indexOf("\x00");if(G!==-1)J.position=G,L$(J,"null byte is not allowed in input");J.input+="\x00";while(J.input.charCodeAt(J.position)===32)J.lineIndent+=1,J.position+=1;while(J.position<J.length-1)Wm(J);return J.documents}function oj($,U,J){if(U!==null&&typeof U==="object"&&typeof J>"u")J=U,U=null;var G=cj($,J);if(typeof U!=="function")return G;for(var q=0,I=G.length;q<I;q+=1)U(G[q])}function aj($,U){var J=cj($,U);if(J.length===0)return;else if(J.length===1)return J[0];throw new fj("expected a single document in the stream, but found more")}function Om($,U,J){if(typeof U==="object"&&U!==null&&typeof J>"u")J=U,U=null;return oj($,U,NJ.extend({schema:yj},J))}function Zm($,U){return aj($,NJ.extend({schema:yj},U))}Rm.loadAll=oj;Rm.load=aj;Rm.safeLoadAll=Om;Rm.safeLoad=Zm});var zP=J$((em,IN)=>{var b4=cq(),u4=S8(),Tm=_4(),zm=E8(),IP=Object.prototype.toString,QP=Object.prototype.hasOwnProperty,Am=9,F4=10,Km=13,gm=32,jm=33,Pm=34,DP=35,Bm=37,Sm=38,Lm=39,Em=42,XP=44,Cm=45,YP=58,_m=61,vm=62,Fm=63,bm=64,VP=91,WP=93,um=96,OP=123,km=124,ZP=125,v0={};v0[0]="\\0";v0[7]="\\a";v0[8]="\\b";v0[9]="\\t";v0[10]="\\n";v0[11]="\\v";v0[12]="\\f";v0[13]="\\r";v0[27]="\\e";v0[34]="\\\"";v0[92]="\\\\";v0[133]="\\N";v0[160]="\\_";v0[8232]="\\L";v0[8233]="\\P";var xm=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"];function fm($,U){var J,G,q,I,Q,D,X;if(U===null)return{};J={},G=Object.keys(U);for(q=0,I=G.length;q<I;q+=1){if(Q=G[q],D=String(U[Q]),Q.slice(0,2)==="!!")Q="tag:yaml.org,2002:"+Q.slice(2);if(X=$.compiledTypeMap.fallback[Q],X&&QP.call(X.styleAliases,D))D=X.styleAliases[D];J[Q]=D}return J}function tj($){var U,J,G;if(U=$.toString(16).toUpperCase(),$<=255)J="x",G=2;else if($<=65535)J="u",G=4;else if($<=4294967295)J="U",G=8;else throw new u4("code point within a string may not be greater than 0xFFFFFFFF");return"\\"+J+b4.repeat("0",G-U.length)+U}function ym($){this.schema=$.schema||Tm,this.indent=Math.max(1,$.indent||2),this.noArrayIndent=$.noArrayIndent||!1,this.skipInvalid=$.skipInvalid||!1,this.flowLevel=b4.isNothing($.flowLevel)?-1:$.flowLevel,this.styleMap=fm(this.schema,$.styles||null),this.sortKeys=$.sortKeys||!1,this.lineWidth=$.lineWidth||80,this.noRefs=$.noRefs||!1,this.noCompatMode=$.noCompatMode||!1,this.condenseFlow=$.condenseFlow||!1,this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}function ej($,U){var J=b4.repeat(" ",U),G=0,q=-1,I="",Q,D=$.length;while(G<D){if(q=$.indexOf(`
|
|
123
|
+
`,G),q===-1)Q=$.slice(G),G=D;else Q=$.slice(G,q+1),G=q+1;if(Q.length&&Q!==`
|
|
124
|
+
`)I+=J;I+=Q}return I}function JN($,U){return`
|
|
125
|
+
`+b4.repeat(" ",$.indent*U)}function mm($,U){var J,G,q;for(J=0,G=$.implicitTypes.length;J<G;J+=1)if(q=$.implicitTypes[J],q.resolve(U))return!0;return!1}function GN($){return $===gm||$===Am}function F8($){return 32<=$&&$<=126||161<=$&&$<=55295&&$!==8232&&$!==8233||57344<=$&&$<=65533&&$!==65279||65536<=$&&$<=1114111}function hm($){return F8($)&&!GN($)&&$!==65279&&$!==Km&&$!==F4}function $P($,U){return F8($)&&$!==65279&&$!==XP&&$!==VP&&$!==WP&&$!==OP&&$!==ZP&&$!==YP&&($!==DP||U&&hm(U))}function rm($){return F8($)&&$!==65279&&!GN($)&&$!==Cm&&$!==Fm&&$!==YP&&$!==XP&&$!==VP&&$!==WP&&$!==OP&&$!==ZP&&$!==DP&&$!==Sm&&$!==Em&&$!==jm&&$!==km&&$!==_m&&$!==vm&&$!==Lm&&$!==Pm&&$!==Bm&&$!==bm&&$!==um}function RP($){var U=/^\n* /;return U.test($)}var NP=1,wP=2,MP=3,HP=4,WX=5;function lm($,U,J,G,q){var I,Q,D,X=!1,Y=!1,V=G!==-1,W=-1,O=rm($.charCodeAt(0))&&!GN($.charCodeAt($.length-1));if(U)for(I=0;I<$.length;I++){if(Q=$.charCodeAt(I),!F8(Q))return WX;D=I>0?$.charCodeAt(I-1):null,O=O&&$P(Q,D)}else{for(I=0;I<$.length;I++){if(Q=$.charCodeAt(I),Q===F4){if(X=!0,V)Y=Y||I-W-1>G&&$[W+1]!==" ",W=I}else if(!F8(Q))return WX;D=I>0?$.charCodeAt(I-1):null,O=O&&$P(Q,D)}Y=Y||V&&(I-W-1>G&&$[W+1]!==" ")}if(!X&&!Y)return O&&!q($)?NP:wP;if(J>9&&RP($))return WX;return Y?HP:MP}function im($,U,J,G){$.dump=function(){if(U.length===0)return"''";if(!$.noCompatMode&&xm.indexOf(U)!==-1)return"'"+U+"'";var q=$.indent*Math.max(1,J),I=$.lineWidth===-1?-1:Math.max(Math.min($.lineWidth,40),$.lineWidth-q),Q=G||$.flowLevel>-1&&J>=$.flowLevel;function D(X){return mm($,X)}switch(lm(U,Q,$.indent,I,D)){case NP:return U;case wP:return"'"+U.replace(/'/g,"''")+"'";case MP:return"|"+UP(U,$.indent)+JP(ej(U,q));case HP:return">"+UP(U,$.indent)+JP(ej(pm(U,I),q));case WX:return'"'+dm(U,I)+'"';default:throw new u4("impossible error: invalid scalar style")}}()}function UP($,U){var J=RP($)?String(U):"",G=$[$.length-1]===`
|
|
126
|
+
`,q=G&&($[$.length-2]===`
|
|
127
|
+
`||$===`
|
|
128
|
+
`),I=q?"+":G?"":"-";return J+I+`
|
|
129
|
+
`}function JP($){return $[$.length-1]===`
|
|
130
|
+
`?$.slice(0,-1):$}function pm($,U){var J=/(\n+)([^\n]*)/g,G=function(){var Y=$.indexOf(`
|
|
131
|
+
`);return Y=Y!==-1?Y:$.length,J.lastIndex=Y,qP($.slice(0,Y),U)}(),q=$[0]===`
|
|
132
|
+
`||$[0]===" ",I,Q;while(Q=J.exec($)){var D=Q[1],X=Q[2];I=X[0]===" ",G+=D+(!q&&!I&&X!==""?`
|
|
133
|
+
`:"")+qP(X,U),q=I}return G}function qP($,U){if($===""||$[0]===" ")return $;var J=/ [^ ]/g,G,q=0,I,Q=0,D=0,X="";while(G=J.exec($)){if(D=G.index,D-q>U)I=Q>q?Q:D,X+=`
|
|
134
|
+
`+$.slice(q,I),q=I+1;Q=D}if(X+=`
|
|
135
|
+
`,$.length-q>U&&Q>q)X+=$.slice(q,Q)+`
|
|
136
|
+
`+$.slice(Q+1);else X+=$.slice(q);return X.slice(1)}function dm($){var U="",J,G,q;for(var I=0;I<$.length;I++){if(J=$.charCodeAt(I),J>=55296&&J<=56319){if(G=$.charCodeAt(I+1),G>=56320&&G<=57343){U+=tj((J-55296)*1024+G-56320+65536),I++;continue}}q=v0[J],U+=!q&&F8(J)?$[I]:q||tj(J)}return U}function nm($,U,J){var G="",q=$.tag,I,Q;for(I=0,Q=J.length;I<Q;I+=1)if(tq($,U,J[I],!1,!1)){if(I!==0)G+=","+(!$.condenseFlow?" ":"");G+=$.dump}$.tag=q,$.dump="["+G+"]"}function cm($,U,J,G){var q="",I=$.tag,Q,D;for(Q=0,D=J.length;Q<D;Q+=1)if(tq($,U+1,J[Q],!0,!0)){if(!G||Q!==0)q+=JN($,U);if($.dump&&F4===$.dump.charCodeAt(0))q+="-";else q+="- ";q+=$.dump}$.tag=I,$.dump=q||"[]"}function om($,U,J){var G="",q=$.tag,I=Object.keys(J),Q,D,X,Y,V;for(Q=0,D=I.length;Q<D;Q+=1){if(V="",Q!==0)V+=", ";if($.condenseFlow)V+='"';if(X=I[Q],Y=J[X],!tq($,U,X,!1,!1))continue;if($.dump.length>1024)V+="? ";if(V+=$.dump+($.condenseFlow?'"':"")+":"+($.condenseFlow?"":" "),!tq($,U,Y,!1,!1))continue;V+=$.dump,G+=V}$.tag=q,$.dump="{"+G+"}"}function am($,U,J,G){var q="",I=$.tag,Q=Object.keys(J),D,X,Y,V,W,O;if($.sortKeys===!0)Q.sort();else if(typeof $.sortKeys==="function")Q.sort($.sortKeys);else if($.sortKeys)throw new u4("sortKeys must be a boolean or a function");for(D=0,X=Q.length;D<X;D+=1){if(O="",!G||D!==0)O+=JN($,U);if(Y=Q[D],V=J[Y],!tq($,U+1,Y,!0,!0,!0))continue;if(W=$.tag!==null&&$.tag!=="?"||$.dump&&$.dump.length>1024,W)if($.dump&&F4===$.dump.charCodeAt(0))O+="?";else O+="? ";if(O+=$.dump,W)O+=JN($,U);if(!tq($,U+1,V,!0,W))continue;if($.dump&&F4===$.dump.charCodeAt(0))O+=":";else O+=": ";O+=$.dump,q+=O}$.tag=I,$.dump=q||"{}"}function GP($,U,J){var G,q,I,Q,D,X;q=J?$.explicitTypes:$.implicitTypes;for(I=0,Q=q.length;I<Q;I+=1)if(D=q[I],(D.instanceOf||D.predicate)&&(!D.instanceOf||typeof U==="object"&&U instanceof D.instanceOf)&&(!D.predicate||D.predicate(U))){if($.tag=J?D.tag:"?",D.represent){if(X=$.styleMap[D.tag]||D.defaultStyle,IP.call(D.represent)==="[object Function]")G=D.represent(U,X);else if(QP.call(D.represent,X))G=D.represent[X](U,X);else throw new u4("!<"+D.tag+'> tag resolver accepts not "'+X+'" style');$.dump=G}return!0}return!1}function tq($,U,J,G,q,I){if($.tag=null,$.dump=J,!GP($,J,!1))GP($,J,!0);var Q=IP.call($.dump);if(G)G=$.flowLevel<0||$.flowLevel>U;var D=Q==="[object Object]"||Q==="[object Array]",X,Y;if(D)X=$.duplicates.indexOf(J),Y=X!==-1;if($.tag!==null&&$.tag!=="?"||Y||$.indent!==2&&U>0)q=!1;if(Y&&$.usedDuplicates[X])$.dump="*ref_"+X;else{if(D&&Y&&!$.usedDuplicates[X])$.usedDuplicates[X]=!0;if(Q==="[object Object]"){if(G&&Object.keys($.dump).length!==0){if(am($,U,$.dump,q),Y)$.dump="&ref_"+X+$.dump}else if(om($,U,$.dump),Y)$.dump="&ref_"+X+" "+$.dump}else if(Q==="[object Array]"){var V=$.noArrayIndent&&U>0?U-1:U;if(G&&$.dump.length!==0){if(cm($,V,$.dump,q),Y)$.dump="&ref_"+X+$.dump}else if(nm($,V,$.dump),Y)$.dump="&ref_"+X+" "+$.dump}else if(Q==="[object String]"){if($.tag!=="?")im($,$.dump,U,I)}else{if($.skipInvalid)return!1;throw new u4("unacceptable kind of an object to dump "+Q)}if($.tag!==null&&$.tag!=="?")$.dump="!<"+$.tag+"> "+$.dump}return!0}function sm($,U){var J=[],G=[],q,I;qN($,J,G);for(q=0,I=G.length;q<I;q+=1)U.duplicates.push(J[G[q]]);U.usedDuplicates=Array(I)}function qN($,U,J){var G,q,I;if($!==null&&typeof $==="object")if(q=U.indexOf($),q!==-1){if(J.indexOf(q)===-1)J.push(q)}else if(U.push($),Array.isArray($))for(q=0,I=$.length;q<I;q+=1)qN($[q],U,J);else{G=Object.keys($);for(q=0,I=G.length;q<I;q+=1)qN($[G[q]],U,J)}}function TP($,U){U=U||{};var J=new ym(U);if(!J.noRefs)sm($,J);if(tq(J,0,$,!0,!0))return J.dump+`
|
|
137
|
+
`;return""}function tm($,U){return TP($,b4.extend({schema:zm},U))}em.dump=TP;em.safeDump=tm});var KP=J$((Jh,s$)=>{var OX=sj(),AP=zP();function ZX($){return function(){throw Error("Function "+$+" is deprecated and cannot be used.")}}Jh.Type=X0();Jh.Schema=oq();Jh.FAILSAFE_SCHEMA=IX();Jh.JSON_SCHEMA=c7();Jh.CORE_SCHEMA=o7();Jh.DEFAULT_SAFE_SCHEMA=E8();Jh.DEFAULT_FULL_SCHEMA=_4();Jh.load=OX.load;Jh.loadAll=OX.loadAll;Jh.safeLoad=OX.safeLoad;Jh.safeLoadAll=OX.safeLoadAll;Jh.dump=AP.dump;Jh.safeDump=AP.safeDump;Jh.YAMLException=S8();Jh.MINIMAL_SCHEMA=IX();Jh.SAFE_SCHEMA=E8();Jh.DEFAULT_SCHEMA=_4();Jh.scan=ZX("scan");Jh.parse=ZX("parse");Jh.compose=ZX("compose");Jh.addConstructor=ZX("addConstructor")});var jP=J$((KD$,gP)=>{var jh=KP();gP.exports=jh});var YN=J$((DN,XN)=>{var RX=jP(),QN=DN=XN.exports;QN.yaml={parse:RX.safeLoad.bind(RX),stringify:RX.safeDump.bind(RX)};QN.json={parse:JSON.parse.bind(JSON),stringify:function($,U){let J=Object.assign({replacer:null,space:2},U);return JSON.stringify($,J.replacer,J.space)}};QN.javascript={parse:function parse(str,options,wrap){try{if(wrap!==!1)str=`(function() {
|
|
42
138
|
return `+str.trim()+`;
|
|
43
|
-
}());`;return eval(str)||{}}catch(
|
|
139
|
+
}());`;return eval(str)||{}}catch($){if(wrap!==!1&&/(unexpected|identifier)/i.test($.message))return parse(str,options,!1);throw SyntaxError($)}},stringify:function(){throw Error("stringifying JavaScript is not supported")}}});var BP=J$((gD$,PP)=>{/*!
|
|
44
140
|
* strip-bom-string <https://github.com/jonschlinkert/strip-bom-string>
|
|
45
141
|
*
|
|
46
142
|
* Copyright (c) 2015, 2017, Jon Schlinkert.
|
|
47
143
|
* Released under the MIT License.
|
|
48
|
-
*/
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
`+J.delimiters[1],
|
|
52
|
-
`)
|
|
144
|
+
*/PP.exports=function($){if(typeof $==="string"&&$.charAt(0)==="\uFEFF")return $.slice(1);return $}});var NX=J$((Ph)=>{var SP=BP(),LP=E4();Ph.define=function($,U,J){Reflect.defineProperty($,U,{enumerable:!1,configurable:!0,writable:!0,value:J})};Ph.isBuffer=function($){return LP($)==="buffer"};Ph.isObject=function($){return LP($)==="object"};Ph.toBuffer=function($){return typeof $==="string"?Buffer.from($):$};Ph.toString=function($){if(Ph.isBuffer($))return SP(String($));if(typeof $!=="string")throw TypeError("expected input to be a string or buffer");return SP($)};Ph.arrayify=function($){return $?Array.isArray($)?$:[$]:[]};Ph.startsWith=function($,U,J){if(typeof J!=="number")J=U.length;return $.slice(0,J)===U}});var k4=J$((PD$,CP)=>{var vh=YN(),Fh=NX();CP.exports=function($){let U=Object.assign({},$);if(U.delimiters=Fh.arrayify(U.delims||U.delimiters||"---"),U.delimiters.length===1)U.delimiters.push(U.delimiters[0]);return U.language=(U.language||U.lang||"yaml").toLowerCase(),U.engines=Object.assign({},vh,U.parsers,U.engines),U}});var VN=J$((BD$,_P)=>{_P.exports=function($,U){let J=U.engines[$]||U.engines[bh($)];if(typeof J>"u")throw Error('gray-matter engine "'+$+'" is not registered');if(typeof J==="function")J={parse:J};return J};function bh($){switch($.toLowerCase()){case"js":case"javascript":return"javascript";case"coffee":case"coffeescript":case"cson":return"coffee";case"yaml":case"yml":return"yaml";default:return $}}});var WN=J$((SD$,vP)=>{var uh=E4(),kh=VN(),xh=k4();vP.exports=function($,U,J){if(U==null&&J==null)switch(uh($)){case"object":U=$.data,J={};break;case"string":return $;default:throw TypeError("expected file to be a string or object")}let G=$.content,q=xh(J);if(U==null){if(!q.data)return $;U=q.data}let I=$.language||q.language,Q=kh(I,q);if(typeof Q.stringify!=="function")throw TypeError('expected "'+I+'.stringify" to be a function');U=Object.assign({},$.data,U);let D=q.delimiters[0],X=q.delimiters[1],Y=Q.stringify(U,J).trim(),V="";if(Y!=="{}")V=b8(D)+b8(Y)+b8(X);if(typeof $.excerpt==="string"&&$.excerpt!==""){if(G.indexOf($.excerpt.trim())===-1)V+=b8($.excerpt)+b8(X)}return V+b8(G)};function b8($){return $.slice(-1)!==`
|
|
145
|
+
`?$+`
|
|
146
|
+
`:$}});var bP=J$((LD$,FP)=>{var fh=k4();FP.exports=function($,U){let J=fh(U);if($.data==null)$.data={};if(typeof J.excerpt==="function")return J.excerpt($,J);let G=$.data.excerpt_separator||J.excerpt_separator;if(G==null&&(J.excerpt===!1||J.excerpt==null))return $;let q=typeof J.excerpt==="string"?J.excerpt:G||J.delimiters[0],I=$.content.indexOf(q);if(I!==-1)$.excerpt=$.content.slice(0,I);return $}});var xP=J$((ED$,kP)=>{var uP=E4(),yh=WN(),u8=NX();kP.exports=function($){if(uP($)!=="object")$={content:$};if(uP($.data)!=="object")$.data={};if($.contents&&$.content==null)$.content=$.contents;return u8.define($,"orig",u8.toBuffer($.content)),u8.define($,"language",$.language||""),u8.define($,"matter",$.matter||""),u8.define($,"stringify",function(U,J){if(J&&J.language)$.language=J.language;return yh($,U,J)}),$.content=u8.toString($.content),$.isEmpty=!1,$.excerpt="",$}});var yP=J$((CD$,fP)=>{var mh=VN(),hh=k4();fP.exports=function($,U,J){let G=hh(J),q=mh($,G);if(typeof q.parse!=="function")throw TypeError('expected "'+$+'.parse" to be a function');return q.parse(U,G)}});var lP=J$((_D$,rP)=>{var rh=WU("fs"),lh=ug(),ON=k4(),ih=WN(),mP=bP(),ph=YN(),dh=xP(),nh=yP(),hP=NX();function n0($,U){if($==="")return{data:{},content:$,excerpt:"",orig:$};let J=dh($),G=n0.cache[J.content];if(!U){if(G)return J=Object.assign({},G),J.orig=G.orig,J;n0.cache[J.content]=J}return ch(J,U)}function ch($,U){let J=ON(U),G=J.delimiters[0],q=`
|
|
147
|
+
`+J.delimiters[1],I=$.content;if(J.language)$.language=J.language;let Q=G.length;if(!hP.startsWith(I,G,Q))return mP($,J),$;if(I.charAt(Q)===G.slice(-1))return $;I=I.slice(Q);let D=I.length,X=n0.language(I,J);if(X.name)$.language=X.name,I=I.slice(X.raw.length);let Y=I.indexOf(q);if(Y===-1)Y=D;if($.matter=I.slice(0,Y),$.matter.replace(/^\s*#[^\n]+/gm,"").trim()==="")$.isEmpty=!0,$.empty=$.content,$.data={};else $.data=nh($.language,$.matter,J);if(Y===D)$.content="";else{if($.content=I.slice(Y+q.length),$.content[0]==="\r")$.content=$.content.slice(1);if($.content[0]===`
|
|
148
|
+
`)$.content=$.content.slice(1)}if(mP($,J),J.sections===!0||typeof J.section==="function")lh($,J.section);return $}n0.engines=ph;n0.stringify=function($,U,J){if(typeof $==="string")$=n0($,J);return ih($,U,J)};n0.read=function($,U){let J=rh.readFileSync($,"utf8"),G=n0(J,U);return G.path=$,G};n0.test=function($,U){return hP.startsWith($,ON(U).delimiters[0])};n0.language=function($,U){let G=ON(U).delimiters[0];if(n0.test($))$=$.slice(G.length);let q=$.slice(0,$.search(/\r?\n/));return{raw:q,name:q?q.trim():""}};n0.cache={};n0.clearCache=function(){n0.cache={}};rP.exports=n0});var RB=J$((mV$,ZB)=>{var y8=1000,m8=y8*60,h8=m8*60,qG=h8*24,Ml=qG*7,Hl=qG*365.25;ZB.exports=function($,U){U=U||{};var J=typeof $;if(J==="string"&&$.length>0)return Tl($);else if(J==="number"&&isFinite($))return U.long?Al($):zl($);throw Error("val is not a non-empty string or a valid number. val="+JSON.stringify($))};function Tl($){if($=String($),$.length>100)return;var U=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec($);if(!U)return;var J=parseFloat(U[1]),G=(U[2]||"ms").toLowerCase();switch(G){case"years":case"year":case"yrs":case"yr":case"y":return J*Hl;case"weeks":case"week":case"w":return J*Ml;case"days":case"day":case"d":return J*qG;case"hours":case"hour":case"hrs":case"hr":case"h":return J*h8;case"minutes":case"minute":case"mins":case"min":case"m":return J*m8;case"seconds":case"second":case"secs":case"sec":case"s":return J*y8;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return J;default:return}}function zl($){var U=Math.abs($);if(U>=qG)return Math.round($/qG)+"d";if(U>=h8)return Math.round($/h8)+"h";if(U>=m8)return Math.round($/m8)+"m";if(U>=y8)return Math.round($/y8)+"s";return $+"ms"}function Al($){var U=Math.abs($);if(U>=qG)return BX($,U,qG,"day");if(U>=h8)return BX($,U,h8,"hour");if(U>=m8)return BX($,U,m8,"minute");if(U>=y8)return BX($,U,y8,"second");return $+" ms"}function BX($,U,J,G){var q=U>=J*1.5;return Math.round($/J)+" "+G+(q?"s":"")}});var SN=J$((hV$,NB)=>{function Kl($){J.debug=J,J.default=J,J.coerce=X,J.disable=Q,J.enable=q,J.enabled=D,J.humanize=RB(),J.destroy=Y,Object.keys($).forEach((V)=>{J[V]=$[V]}),J.names=[],J.skips=[],J.formatters={};function U(V){let W=0;for(let O=0;O<V.length;O++)W=(W<<5)-W+V.charCodeAt(O),W|=0;return J.colors[Math.abs(W)%J.colors.length]}J.selectColor=U;function J(V){let W,O=null,Z,M;function w(...H){if(!w.enabled)return;let g=w,P=Number(new Date),C=P-(W||P);if(g.diff=C,g.prev=W,g.curr=P,W=P,H[0]=J.coerce(H[0]),typeof H[0]!=="string")H.unshift("%O");let F=0;H[0]=H[0].replace(/%([a-zA-Z%])/g,(E,p)=>{if(E==="%%")return"%";F++;let b=J.formatters[p];if(typeof b==="function"){let h=H[F];E=b.call(g,h),H.splice(F,1),F--}return E}),J.formatArgs.call(g,H),(g.log||J.log).apply(g,H)}if(w.namespace=V,w.useColors=J.useColors(),w.color=J.selectColor(V),w.extend=G,w.destroy=J.destroy,Object.defineProperty(w,"enabled",{enumerable:!0,configurable:!1,get:()=>{if(O!==null)return O;if(Z!==J.namespaces)Z=J.namespaces,M=J.enabled(V);return M},set:(H)=>{O=H}}),typeof J.init==="function")J.init(w);return w}function G(V,W){let O=J(this.namespace+(typeof W>"u"?":":W)+V);return O.log=this.log,O}function q(V){J.save(V),J.namespaces=V,J.names=[],J.skips=[];let W=(typeof V==="string"?V:"").trim().replace(/\s+/g,",").split(",").filter(Boolean);for(let O of W)if(O[0]==="-")J.skips.push(O.slice(1));else J.names.push(O)}function I(V,W){let O=0,Z=0,M=-1,w=0;while(O<V.length)if(Z<W.length&&(W[Z]===V[O]||W[Z]==="*"))if(W[Z]==="*")M=Z,w=O,Z++;else O++,Z++;else if(M!==-1)Z=M+1,w++,O=w;else return!1;while(Z<W.length&&W[Z]==="*")Z++;return Z===W.length}function Q(){let V=[...J.names,...J.skips.map((W)=>"-"+W)].join(",");return J.enable(""),V}function D(V){for(let W of J.skips)if(I(V,W))return!1;for(let W of J.names)if(I(V,W))return!0;return!1}function X(V){if(V instanceof Error)return V.stack||V.message;return V}function Y(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}return J.enable(J.load()),J}NB.exports=Kl});var MB=J$((wB,SX)=>{wB.formatArgs=jl;wB.save=Pl;wB.load=Bl;wB.useColors=gl;wB.storage=Sl();wB.destroy=(()=>{let $=!1;return()=>{if(!$)$=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}})();wB.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function gl(){if(typeof window<"u"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs))return!0;if(typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;let $;return typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&($=navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/))&&parseInt($[1],10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function jl($){if($[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+$[0]+(this.useColors?"%c ":" ")+"+"+SX.exports.humanize(this.diff),!this.useColors)return;let U="color: "+this.color;$.splice(1,0,U,"color: inherit");let J=0,G=0;$[0].replace(/%[a-zA-Z%]/g,(q)=>{if(q==="%%")return;if(J++,q==="%c")G=J}),$.splice(G,0,U)}wB.log=console.debug||console.log||(()=>{});function Pl($){try{if($)wB.storage.setItem("debug",$);else wB.storage.removeItem("debug")}catch(U){}}function Bl(){let $;try{$=wB.storage.getItem("debug")||wB.storage.getItem("DEBUG")}catch(U){}if(!$&&typeof process<"u"&&"env"in process)$=process.env.DEBUG;return $}function Sl(){try{return localStorage}catch($){}}SX.exports=SN()(wB);var{formatters:Ll}=SX.exports;Ll.j=function($){try{return JSON.stringify($)}catch(U){return"[UnexpectedJSONParseError]: "+U.message}}});var TB=J$((lV$,HB)=>{HB.exports=($,U=process.argv)=>{let J=$.startsWith("-")?"":$.length===1?"-":"--",G=U.indexOf(J+$),q=U.indexOf("--");return G!==-1&&(q===-1||G<q)}});var KB=J$((iV$,AB)=>{var kl=WU("os"),zB=WU("tty"),jU=TB(),{env:Z0}=process,Uq;if(jU("no-color")||jU("no-colors")||jU("color=false")||jU("color=never"))Uq=0;else if(jU("color")||jU("colors")||jU("color=true")||jU("color=always"))Uq=1;if("FORCE_COLOR"in Z0)if(Z0.FORCE_COLOR==="true")Uq=1;else if(Z0.FORCE_COLOR==="false")Uq=0;else Uq=Z0.FORCE_COLOR.length===0?1:Math.min(parseInt(Z0.FORCE_COLOR,10),3);function LN($){if($===0)return!1;return{level:$,hasBasic:!0,has256:$>=2,has16m:$>=3}}function EN($,U){if(Uq===0)return 0;if(jU("color=16m")||jU("color=full")||jU("color=truecolor"))return 3;if(jU("color=256"))return 2;if($&&!U&&Uq===void 0)return 0;let J=Uq||0;if(Z0.TERM==="dumb")return J;if(process.platform==="win32"){let G=kl.release().split(".");if(Number(G[0])>=10&&Number(G[2])>=10586)return Number(G[2])>=14931?3:2;return 1}if("CI"in Z0){if(["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE"].some((G)=>(G in Z0))||Z0.CI_NAME==="codeship")return 1;return J}if("TEAMCITY_VERSION"in Z0)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(Z0.TEAMCITY_VERSION)?1:0;if(Z0.COLORTERM==="truecolor")return 3;if("TERM_PROGRAM"in Z0){let G=parseInt((Z0.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(Z0.TERM_PROGRAM){case"iTerm.app":return G>=3?3:2;case"Apple_Terminal":return 2}}if(/-256(color)?$/i.test(Z0.TERM))return 2;if(/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(Z0.TERM))return 1;if("COLORTERM"in Z0)return 1;return J}function xl($){let U=EN($,$&&$.isTTY);return LN(U)}AB.exports={supportsColor:xl,stdout:LN(EN(!0,zB.isatty(1))),stderr:LN(EN(!0,zB.isatty(2)))}});var BB=J$((jB,EX)=>{var fl=WU("tty"),LX=WU("util");jB.init=pl;jB.log=rl;jB.formatArgs=ml;jB.save=ll;jB.load=il;jB.useColors=yl;jB.destroy=LX.deprecate(()=>{},"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");jB.colors=[6,2,3,4,5,1];try{let $=KB();if($&&($.stderr||$).level>=2)jB.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221]}catch($){}jB.inspectOpts=Object.keys(process.env).filter(($)=>{return/^debug_/i.test($)}).reduce(($,U)=>{let J=U.substring(6).toLowerCase().replace(/_([a-z])/g,(q,I)=>{return I.toUpperCase()}),G=process.env[U];if(/^(yes|on|true|enabled)$/i.test(G))G=!0;else if(/^(no|off|false|disabled)$/i.test(G))G=!1;else if(G==="null")G=null;else G=Number(G);return $[J]=G,$},{});function yl(){return"colors"in jB.inspectOpts?Boolean(jB.inspectOpts.colors):fl.isatty(process.stderr.fd)}function ml($){let{namespace:U,useColors:J}=this;if(J){let G=this.color,q="\x1B[3"+(G<8?G:"8;5;"+G),I=` ${q};1m${U} \x1B[0m`;$[0]=I+$[0].split(`
|
|
53
149
|
`).join(`
|
|
54
|
-
`+
|
|
55
|
-
`)}function
|
|
56
|
-
`).map(($)=>$.trim()).join(" ")};N6.O=function(q){return this.inspectOpts.colors=this.useColors,B3.inspect(q,this.inspectOpts)}});var L6=m((eA,kJ)=>{if(typeof process>"u"||process.type==="renderer"||!1||process.__nwjs)kJ.exports=B6();else kJ.exports=P6()});var S8=m((ZP,j8)=>{var Z3=Object.prototype.hasOwnProperty,N8=Object.prototype.toString,B8=Object.defineProperty,R8=Object.getOwnPropertyDescriptor,w8=function($){if(typeof Array.isArray==="function")return Array.isArray($);return N8.call($)==="[object Array]"},F8=function($){if(!$||N8.call($)!=="[object Object]")return!1;var J=Z3.call($,"constructor"),G=$.constructor&&$.constructor.prototype&&Z3.call($.constructor.prototype,"isPrototypeOf");if($.constructor&&!J&&!G)return!1;var X;for(X in $);return typeof X>"u"||Z3.call($,X)},O8=function($,J){if(B8&&J.name==="__proto__")B8($,J.name,{enumerable:!0,configurable:!0,value:J.newValue,writable:!0});else $[J.name]=J.newValue},A8=function($,J){if(J==="__proto__"){if(!Z3.call($,J))return;else if(R8)return R8($,J).value}return $[J]};j8.exports=function q(){var $,J,G,X,Y,U,Q=arguments[0],V=1,W=arguments.length,H=!1;if(typeof Q==="boolean")H=Q,Q=arguments[1]||{},V=2;if(Q==null||typeof Q!=="object"&&typeof Q!=="function")Q={};for(;V<W;++V)if($=arguments[V],$!=null){for(J in $)if(G=A8(Q,J),X=A8($,J),Q!==X){if(H&&X&&(F8(X)||(Y=w8(X)))){if(Y)Y=!1,U=G&&w8(G)?G:[];else U=G&&F8(G)?G:{};O8(Q,{name:J,newValue:q(H,U,X)})}else if(typeof X<"u")O8(Q,{name:J,newValue:X})}}return Q}});import{access as kD,chmod as fD,mkdir as v7,readFile as uD,writeFile as pD}from"fs/promises";import{dirname as lD,join as k2}from"path";import{fileURLToPath as rD}from"url";var v$={name:"@rizom/ops",description:"Operator CLI for managing private brain fleet registry repos",publishConfig:{access:"public"},version:"0.2.0-alpha.3",type:"module",exports:{".":{types:"./dist/index.d.ts",import:"./dist/index.js"},"./deploy":{bun:"./dist/deploy.js",types:"./dist/deploy.d.ts",import:"./dist/deploy.js"}},main:"./dist/index.js",types:"./dist/index.d.ts",bin:{"brains-ops":"./dist/brains-ops.js"},files:["dist","templates"],scripts:{build:"bun scripts/build.ts",prepublishOnly:"bun scripts/build.ts",typecheck:"tsc --noEmit",lint:"eslint . --ext .ts","lint:fix":"eslint . --ext .ts --fix",test:"bun test"},dependencies:{},devDependencies:{"@brains/eslint-config":"workspace:*","@brains/typescript-config":"workspace:*","@brains/utils":"workspace:*","@types/bun":"latest",typescript:"^5.3.3"},repository:{type:"git",url:"https://github.com/rizom-ai/brains.git",directory:"packages/brains-ops"},license:"Apache-2.0",author:"Yeehaa <yeehaa@rizom.ai> (https://rizom.ai)",homepage:"https://github.com/rizom-ai/brains/tree/main/packages/brains-ops#readme",bugs:"https://github.com/rizom-ai/brains/issues",engines:{bun:">=1.3.3"},keywords:["brains","ops","cli","deploy","fleet","operator"]};import{mkdir as yD,writeFile as hD}from"fs/promises";import{join as g7}from"path";import{access as CD,readdir as ED,readFile as TD}from"fs/promises";import{basename as T7,join as I$,relative as _D}from"path";var b={};s2(b,{void:()=>uG,util:()=>o,unknown:()=>kG,union:()=>iG,undefined:()=>hG,tuple:()=>nG,transformer:()=>XX,symbol:()=>yG,string:()=>U5,strictObject:()=>rG,setErrorMap:()=>UG,set:()=>sG,record:()=>oG,quotelessJson:()=>XG,promise:()=>GX,preprocess:()=>QX,pipeline:()=>VX,ostring:()=>WX,optional:()=>YX,onumber:()=>HX,oboolean:()=>zX,objectUtil:()=>i3,object:()=>lG,number:()=>Q5,nullable:()=>UX,null:()=>xG,never:()=>fG,nativeEnum:()=>JX,nan:()=>IG,map:()=>aG,makeIssue:()=>a0,literal:()=>qX,lazy:()=>eG,late:()=>_G,isValid:()=>B1,isDirty:()=>h$,isAsync:()=>W0,isAborted:()=>y$,intersection:()=>cG,instanceof:()=>bG,getParsedType:()=>tq,getErrorMap:()=>V0,function:()=>tG,enum:()=>$X,effect:()=>XX,discriminatedUnion:()=>dG,defaultErrorMap:()=>W1,datetimeRegex:()=>G5,date:()=>vG,custom:()=>Y5,coerce:()=>MX,boolean:()=>V5,bigint:()=>gG,array:()=>pG,any:()=>mG,addIssueToContext:()=>_,ZodVoid:()=>t0,ZodUnknown:()=>R1,ZodUnion:()=>B0,ZodUndefined:()=>K0,ZodType:()=>c,ZodTuple:()=>q1,ZodTransformer:()=>cq,ZodSymbol:()=>s0,ZodString:()=>lq,ZodSet:()=>x1,ZodSchema:()=>c,ZodRecord:()=>e0,ZodReadonly:()=>j0,ZodPromise:()=>m1,ZodPipeline:()=>J$,ZodParsedType:()=>E,ZodOptional:()=>iq,ZodObject:()=>Uq,ZodNumber:()=>w1,ZodNullable:()=>z1,ZodNull:()=>D0,ZodNever:()=>eq,ZodNativeEnum:()=>O0,ZodNaN:()=>$$,ZodMap:()=>q$,ZodLiteral:()=>F0,ZodLazy:()=>w0,ZodIssueCode:()=>Z,ZodIntersection:()=>R0,ZodFunction:()=>z0,ZodFirstPartyTypeKind:()=>u,ZodError:()=>Aq,ZodEnum:()=>O1,ZodEffects:()=>cq,ZodDiscriminatedUnion:()=>x$,ZodDefault:()=>A0,ZodDate:()=>y1,ZodCatch:()=>N0,ZodBranded:()=>m$,ZodBoolean:()=>M0,ZodBigInt:()=>F1,ZodArray:()=>rq,ZodAny:()=>h1,Schema:()=>c,ParseStatus:()=>wq,OK:()=>Nq,NEVER:()=>KX,INVALID:()=>k,EMPTY_PATH:()=>QG,DIRTY:()=>v1,BRAND:()=>TG});var o;(function(q){q.assertEqual=(X)=>{};function $(X){}q.assertIs=$;function J(X){throw Error()}q.assertNever=J,q.arrayToEnum=(X)=>{let Y={};for(let U of X)Y[U]=U;return Y},q.getValidEnumValues=(X)=>{let Y=q.objectKeys(X).filter((Q)=>typeof X[X[Q]]!=="number"),U={};for(let Q of Y)U[Q]=X[Q];return q.objectValues(U)},q.objectValues=(X)=>{return q.objectKeys(X).map(function(Y){return X[Y]})},q.objectKeys=typeof Object.keys==="function"?(X)=>Object.keys(X):(X)=>{let Y=[];for(let U in X)if(Object.prototype.hasOwnProperty.call(X,U))Y.push(U);return Y},q.find=(X,Y)=>{for(let U of X)if(Y(U))return U;return},q.isInteger=typeof Number.isInteger==="function"?(X)=>Number.isInteger(X):(X)=>typeof X==="number"&&Number.isFinite(X)&&Math.floor(X)===X;function G(X,Y=" | "){return X.map((U)=>typeof U==="string"?`'${U}'`:U).join(Y)}q.joinValues=G,q.jsonStringifyReplacer=(X,Y)=>{if(typeof Y==="bigint")return Y.toString();return Y}})(o||(o={}));var i3;(function(q){q.mergeShapes=($,J)=>{return{...$,...J}}})(i3||(i3={}));var E=o.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),tq=(q)=>{switch(typeof q){case"undefined":return E.undefined;case"string":return E.string;case"number":return Number.isNaN(q)?E.nan:E.number;case"boolean":return E.boolean;case"function":return E.function;case"bigint":return E.bigint;case"symbol":return E.symbol;case"object":if(Array.isArray(q))return E.array;if(q===null)return E.null;if(q.then&&typeof q.then==="function"&&q.catch&&typeof q.catch==="function")return E.promise;if(typeof Map<"u"&&q instanceof Map)return E.map;if(typeof Set<"u"&&q instanceof Set)return E.set;if(typeof Date<"u"&&q instanceof Date)return E.date;return E.object;default:return E.unknown}};var Z=o.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"]),XG=(q)=>{return JSON.stringify(q,null,2).replace(/"([^"]+)":/g,"$1:")};class Aq extends Error{get errors(){return this.issues}constructor(q){super();this.issues=[],this.addIssue=(J)=>{this.issues=[...this.issues,J]},this.addIssues=(J=[])=>{this.issues=[...this.issues,...J]};let $=new.target.prototype;if(Object.setPrototypeOf)Object.setPrototypeOf(this,$);else this.__proto__=$;this.name="ZodError",this.issues=q}format(q){let $=q||function(X){return X.message},J={_errors:[]},G=(X)=>{for(let Y of X.issues)if(Y.code==="invalid_union")Y.unionErrors.map(G);else if(Y.code==="invalid_return_type")G(Y.returnTypeError);else if(Y.code==="invalid_arguments")G(Y.argumentsError);else if(Y.path.length===0)J._errors.push($(Y));else{let U=J,Q=0;while(Q<Y.path.length){let V=Y.path[Q];if(Q!==Y.path.length-1)U[V]=U[V]||{_errors:[]};else U[V]=U[V]||{_errors:[]},U[V]._errors.push($(Y));U=U[V],Q++}}};return G(this),J}static assert(q){if(!(q instanceof Aq))throw Error(`Not a ZodError: ${q}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,o.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(q=($)=>$.message){let $={},J=[];for(let G of this.issues)if(G.path.length>0){let X=G.path[0];$[X]=$[X]||[],$[X].push(q(G))}else J.push(q(G));return{formErrors:J,fieldErrors:$}}get formErrors(){return this.flatten()}}Aq.create=(q)=>{return new Aq(q)};var YG=(q,$)=>{let J;switch(q.code){case Z.invalid_type:if(q.received===E.undefined)J="Required";else J=`Expected ${q.expected}, received ${q.received}`;break;case Z.invalid_literal:J=`Invalid literal value, expected ${JSON.stringify(q.expected,o.jsonStringifyReplacer)}`;break;case Z.unrecognized_keys:J=`Unrecognized key(s) in object: ${o.joinValues(q.keys,", ")}`;break;case Z.invalid_union:J="Invalid input";break;case Z.invalid_union_discriminator:J=`Invalid discriminator value. Expected ${o.joinValues(q.options)}`;break;case Z.invalid_enum_value:J=`Invalid enum value. Expected ${o.joinValues(q.options)}, received '${q.received}'`;break;case Z.invalid_arguments:J="Invalid function arguments";break;case Z.invalid_return_type:J="Invalid function return type";break;case Z.invalid_date:J="Invalid date";break;case Z.invalid_string:if(typeof q.validation==="object")if("includes"in q.validation){if(J=`Invalid input: must include "${q.validation.includes}"`,typeof q.validation.position==="number")J=`${J} at one or more positions greater than or equal to ${q.validation.position}`}else if("startsWith"in q.validation)J=`Invalid input: must start with "${q.validation.startsWith}"`;else if("endsWith"in q.validation)J=`Invalid input: must end with "${q.validation.endsWith}"`;else o.assertNever(q.validation);else if(q.validation!=="regex")J=`Invalid ${q.validation}`;else J="Invalid";break;case Z.too_small:if(q.type==="array")J=`Array must contain ${q.exact?"exactly":q.inclusive?"at least":"more than"} ${q.minimum} element(s)`;else if(q.type==="string")J=`String must contain ${q.exact?"exactly":q.inclusive?"at least":"over"} ${q.minimum} character(s)`;else if(q.type==="number")J=`Number must be ${q.exact?"exactly equal to ":q.inclusive?"greater than or equal to ":"greater than "}${q.minimum}`;else if(q.type==="bigint")J=`Number must be ${q.exact?"exactly equal to ":q.inclusive?"greater than or equal to ":"greater than "}${q.minimum}`;else if(q.type==="date")J=`Date must be ${q.exact?"exactly equal to ":q.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(q.minimum))}`;else J="Invalid input";break;case Z.too_big:if(q.type==="array")J=`Array must contain ${q.exact?"exactly":q.inclusive?"at most":"less than"} ${q.maximum} element(s)`;else if(q.type==="string")J=`String must contain ${q.exact?"exactly":q.inclusive?"at most":"under"} ${q.maximum} character(s)`;else if(q.type==="number")J=`Number must be ${q.exact?"exactly":q.inclusive?"less than or equal to":"less than"} ${q.maximum}`;else if(q.type==="bigint")J=`BigInt must be ${q.exact?"exactly":q.inclusive?"less than or equal to":"less than"} ${q.maximum}`;else if(q.type==="date")J=`Date must be ${q.exact?"exactly":q.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(q.maximum))}`;else J="Invalid input";break;case Z.custom:J="Invalid input";break;case Z.invalid_intersection_types:J="Intersection results could not be merged";break;case Z.not_multiple_of:J=`Number must be a multiple of ${q.multipleOf}`;break;case Z.not_finite:J="Number must be finite";break;default:J=$.defaultError,o.assertNever(q)}return{message:J}},W1=YG;var t2=W1;function UG(q){t2=q}function V0(){return t2}var a0=(q)=>{let{data:$,path:J,errorMaps:G,issueData:X}=q,Y=[...J,...X.path||[]],U={...X,path:Y};if(X.message!==void 0)return{...X,path:Y,message:X.message};let Q="",V=G.filter((W)=>!!W).slice().reverse();for(let W of V)Q=W(U,{data:$,defaultError:Q}).message;return{...X,path:Y,message:Q}},QG=[];function _(q,$){let J=V0(),G=a0({issueData:$,data:q.data,path:q.path,errorMaps:[q.common.contextualErrorMap,q.schemaErrorMap,J,J===W1?void 0:W1].filter((X)=>!!X)});q.common.issues.push(G)}class wq{constructor(){this.value="valid"}dirty(){if(this.value==="valid")this.value="dirty"}abort(){if(this.value!=="aborted")this.value="aborted"}static mergeArray(q,$){let J=[];for(let G of $){if(G.status==="aborted")return k;if(G.status==="dirty")q.dirty();J.push(G.value)}return{status:q.value,value:J}}static async mergeObjectAsync(q,$){let J=[];for(let G of $){let X=await G.key,Y=await G.value;J.push({key:X,value:Y})}return wq.mergeObjectSync(q,J)}static mergeObjectSync(q,$){let J={};for(let G of $){let{key:X,value:Y}=G;if(X.status==="aborted")return k;if(Y.status==="aborted")return k;if(X.status==="dirty")q.dirty();if(Y.status==="dirty")q.dirty();if(X.value!=="__proto__"&&(typeof Y.value<"u"||G.alwaysSet))J[X.value]=Y.value}return{status:q.value,value:J}}}var k=Object.freeze({status:"aborted"}),v1=(q)=>({status:"dirty",value:q}),Nq=(q)=>({status:"valid",value:q}),y$=(q)=>q.status==="aborted",h$=(q)=>q.status==="dirty",B1=(q)=>q.status==="valid",W0=(q)=>typeof Promise<"u"&&q instanceof Promise;var y;(function(q){q.errToObj=($)=>typeof $==="string"?{message:$}:$||{},q.toString=($)=>typeof $==="string"?$:$?.message})(y||(y={}));class dq{constructor(q,$,J,G){this._cachedPath=[],this.parent=q,this.data=$,this._path=J,this._key=G}get path(){if(!this._cachedPath.length)if(Array.isArray(this._key))this._cachedPath.push(...this._path,...this._key);else this._cachedPath.push(...this._path,this._key);return this._cachedPath}}var e2=(q,$)=>{if(B1($))return{success:!0,data:$.value};else{if(!q.common.issues.length)throw Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;let J=new Aq(q.common.issues);return this._error=J,this._error}}}};function i(q){if(!q)return{};let{errorMap:$,invalid_type_error:J,required_error:G,description:X}=q;if($&&(J||G))throw Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);if($)return{errorMap:$,description:X};return{errorMap:(U,Q)=>{let{message:V}=q;if(U.code==="invalid_enum_value")return{message:V??Q.defaultError};if(typeof Q.data>"u")return{message:V??G??Q.defaultError};if(U.code!=="invalid_type")return{message:Q.defaultError};return{message:V??J??Q.defaultError}},description:X}}class c{get description(){return this._def.description}_getType(q){return tq(q.data)}_getOrReturnCtx(q,$){return $||{common:q.parent.common,data:q.data,parsedType:tq(q.data),schemaErrorMap:this._def.errorMap,path:q.path,parent:q.parent}}_processInputParams(q){return{status:new wq,ctx:{common:q.parent.common,data:q.data,parsedType:tq(q.data),schemaErrorMap:this._def.errorMap,path:q.path,parent:q.parent}}}_parseSync(q){let $=this._parse(q);if(W0($))throw Error("Synchronous parse encountered promise.");return $}_parseAsync(q){let $=this._parse(q);return Promise.resolve($)}parse(q,$){let J=this.safeParse(q,$);if(J.success)return J.data;throw J.error}safeParse(q,$){let J={common:{issues:[],async:$?.async??!1,contextualErrorMap:$?.errorMap},path:$?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:q,parsedType:tq(q)},G=this._parseSync({data:q,path:J.path,parent:J});return e2(J,G)}"~validate"(q){let $={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:q,parsedType:tq(q)};if(!this["~standard"].async)try{let J=this._parseSync({data:q,path:[],parent:$});return B1(J)?{value:J.value}:{issues:$.common.issues}}catch(J){if(J?.message?.toLowerCase()?.includes("encountered"))this["~standard"].async=!0;$.common={issues:[],async:!0}}return this._parseAsync({data:q,path:[],parent:$}).then((J)=>B1(J)?{value:J.value}:{issues:$.common.issues})}async parseAsync(q,$){let J=await this.safeParseAsync(q,$);if(J.success)return J.data;throw J.error}async safeParseAsync(q,$){let J={common:{issues:[],contextualErrorMap:$?.errorMap,async:!0},path:$?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:q,parsedType:tq(q)},G=this._parse({data:q,path:J.path,parent:J}),X=await(W0(G)?G:Promise.resolve(G));return e2(J,X)}refine(q,$){let J=(G)=>{if(typeof $==="string"||typeof $>"u")return{message:$};else if(typeof $==="function")return $(G);else return $};return this._refinement((G,X)=>{let Y=q(G),U=()=>X.addIssue({code:Z.custom,...J(G)});if(typeof Promise<"u"&&Y instanceof Promise)return Y.then((Q)=>{if(!Q)return U(),!1;else return!0});if(!Y)return U(),!1;else return!0})}refinement(q,$){return this._refinement((J,G)=>{if(!q(J))return G.addIssue(typeof $==="function"?$(J,G):$),!1;else return!0})}_refinement(q){return new cq({schema:this,typeName:u.ZodEffects,effect:{type:"refinement",refinement:q}})}superRefine(q){return this._refinement(q)}constructor(q){this.spa=this.safeParseAsync,this._def=q,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:($)=>this["~validate"]($)}}optional(){return iq.create(this,this._def)}nullable(){return z1.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return rq.create(this)}promise(){return m1.create(this,this._def)}or(q){return B0.create([this,q],this._def)}and(q){return R0.create(this,q,this._def)}transform(q){return new cq({...i(this._def),schema:this,typeName:u.ZodEffects,effect:{type:"transform",transform:q}})}default(q){let $=typeof q==="function"?q:()=>q;return new A0({...i(this._def),innerType:this,defaultValue:$,typeName:u.ZodDefault})}brand(){return new m$({typeName:u.ZodBranded,type:this,...i(this._def)})}catch(q){let $=typeof q==="function"?q:()=>q;return new N0({...i(this._def),innerType:this,catchValue:$,typeName:u.ZodCatch})}describe(q){return new this.constructor({...this._def,description:q})}pipe(q){return J$.create(this,q)}readonly(){return j0.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}var VG=/^c[^\s-]{8,}$/i,WG=/^[0-9a-z]+$/,HG=/^[0-9A-HJKMNP-TV-Z]{26}$/i,zG=/^[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,MG=/^[a-z0-9_-]{21}$/i,KG=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,DG=/^[-+]?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)?)??$/,BG=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,RG="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$",d3,wG=/^(?:(?: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])$/,FG=/^(?:(?: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])$/,OG=/^(([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]))$/,AG=/^(([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])$/,NG=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,jG=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,$5="((\\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])))",SG=new RegExp(`^${$5}$`);function J5(q){let $="[0-5]\\d";if(q.precision)$=`${$}\\.\\d{${q.precision}}`;else if(q.precision==null)$=`${$}(\\.\\d+)?`;let J=q.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${$})${J}`}function PG(q){return new RegExp(`^${J5(q)}$`)}function G5(q){let $=`${$5}T${J5(q)}`,J=[];if(J.push(q.local?"Z?":"Z"),q.offset)J.push("([+-]\\d{2}:?\\d{2})");return $=`${$}(${J.join("|")})`,new RegExp(`^${$}$`)}function LG(q,$){if(($==="v4"||!$)&&wG.test(q))return!0;if(($==="v6"||!$)&&OG.test(q))return!0;return!1}function ZG(q,$){if(!KG.test(q))return!1;try{let[J]=q.split(".");if(!J)return!1;let G=J.replace(/-/g,"+").replace(/_/g,"/").padEnd(J.length+(4-J.length%4)%4,"="),X=JSON.parse(atob(G));if(typeof X!=="object"||X===null)return!1;if("typ"in X&&X?.typ!=="JWT")return!1;if(!X.alg)return!1;if($&&X.alg!==$)return!1;return!0}catch{return!1}}function CG(q,$){if(($==="v4"||!$)&&FG.test(q))return!0;if(($==="v6"||!$)&&AG.test(q))return!0;return!1}class lq extends c{_parse(q){if(this._def.coerce)q.data=String(q.data);if(this._getType(q)!==E.string){let X=this._getOrReturnCtx(q);return _(X,{code:Z.invalid_type,expected:E.string,received:X.parsedType}),k}let J=new wq,G=void 0;for(let X of this._def.checks)if(X.kind==="min"){if(q.data.length<X.value)G=this._getOrReturnCtx(q,G),_(G,{code:Z.too_small,minimum:X.value,type:"string",inclusive:!0,exact:!1,message:X.message}),J.dirty()}else if(X.kind==="max"){if(q.data.length>X.value)G=this._getOrReturnCtx(q,G),_(G,{code:Z.too_big,maximum:X.value,type:"string",inclusive:!0,exact:!1,message:X.message}),J.dirty()}else if(X.kind==="length"){let Y=q.data.length>X.value,U=q.data.length<X.value;if(Y||U){if(G=this._getOrReturnCtx(q,G),Y)_(G,{code:Z.too_big,maximum:X.value,type:"string",inclusive:!0,exact:!0,message:X.message});else if(U)_(G,{code:Z.too_small,minimum:X.value,type:"string",inclusive:!0,exact:!0,message:X.message});J.dirty()}}else if(X.kind==="email"){if(!BG.test(q.data))G=this._getOrReturnCtx(q,G),_(G,{validation:"email",code:Z.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="emoji"){if(!d3)d3=new RegExp(RG,"u");if(!d3.test(q.data))G=this._getOrReturnCtx(q,G),_(G,{validation:"emoji",code:Z.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="uuid"){if(!zG.test(q.data))G=this._getOrReturnCtx(q,G),_(G,{validation:"uuid",code:Z.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="nanoid"){if(!MG.test(q.data))G=this._getOrReturnCtx(q,G),_(G,{validation:"nanoid",code:Z.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="cuid"){if(!VG.test(q.data))G=this._getOrReturnCtx(q,G),_(G,{validation:"cuid",code:Z.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="cuid2"){if(!WG.test(q.data))G=this._getOrReturnCtx(q,G),_(G,{validation:"cuid2",code:Z.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="ulid"){if(!HG.test(q.data))G=this._getOrReturnCtx(q,G),_(G,{validation:"ulid",code:Z.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="url")try{new URL(q.data)}catch{G=this._getOrReturnCtx(q,G),_(G,{validation:"url",code:Z.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="regex"){if(X.regex.lastIndex=0,!X.regex.test(q.data))G=this._getOrReturnCtx(q,G),_(G,{validation:"regex",code:Z.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="trim")q.data=q.data.trim();else if(X.kind==="includes"){if(!q.data.includes(X.value,X.position))G=this._getOrReturnCtx(q,G),_(G,{code:Z.invalid_string,validation:{includes:X.value,position:X.position},message:X.message}),J.dirty()}else if(X.kind==="toLowerCase")q.data=q.data.toLowerCase();else if(X.kind==="toUpperCase")q.data=q.data.toUpperCase();else if(X.kind==="startsWith"){if(!q.data.startsWith(X.value))G=this._getOrReturnCtx(q,G),_(G,{code:Z.invalid_string,validation:{startsWith:X.value},message:X.message}),J.dirty()}else if(X.kind==="endsWith"){if(!q.data.endsWith(X.value))G=this._getOrReturnCtx(q,G),_(G,{code:Z.invalid_string,validation:{endsWith:X.value},message:X.message}),J.dirty()}else if(X.kind==="datetime"){if(!G5(X).test(q.data))G=this._getOrReturnCtx(q,G),_(G,{code:Z.invalid_string,validation:"datetime",message:X.message}),J.dirty()}else if(X.kind==="date"){if(!SG.test(q.data))G=this._getOrReturnCtx(q,G),_(G,{code:Z.invalid_string,validation:"date",message:X.message}),J.dirty()}else if(X.kind==="time"){if(!PG(X).test(q.data))G=this._getOrReturnCtx(q,G),_(G,{code:Z.invalid_string,validation:"time",message:X.message}),J.dirty()}else if(X.kind==="duration"){if(!DG.test(q.data))G=this._getOrReturnCtx(q,G),_(G,{validation:"duration",code:Z.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="ip"){if(!LG(q.data,X.version))G=this._getOrReturnCtx(q,G),_(G,{validation:"ip",code:Z.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="jwt"){if(!ZG(q.data,X.alg))G=this._getOrReturnCtx(q,G),_(G,{validation:"jwt",code:Z.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="cidr"){if(!CG(q.data,X.version))G=this._getOrReturnCtx(q,G),_(G,{validation:"cidr",code:Z.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="base64"){if(!NG.test(q.data))G=this._getOrReturnCtx(q,G),_(G,{validation:"base64",code:Z.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="base64url"){if(!jG.test(q.data))G=this._getOrReturnCtx(q,G),_(G,{validation:"base64url",code:Z.invalid_string,message:X.message}),J.dirty()}else o.assertNever(X);return{status:J.value,value:q.data}}_regex(q,$,J){return this.refinement((G)=>q.test(G),{validation:$,code:Z.invalid_string,...y.errToObj(J)})}_addCheck(q){return new lq({...this._def,checks:[...this._def.checks,q]})}email(q){return this._addCheck({kind:"email",...y.errToObj(q)})}url(q){return this._addCheck({kind:"url",...y.errToObj(q)})}emoji(q){return this._addCheck({kind:"emoji",...y.errToObj(q)})}uuid(q){return this._addCheck({kind:"uuid",...y.errToObj(q)})}nanoid(q){return this._addCheck({kind:"nanoid",...y.errToObj(q)})}cuid(q){return this._addCheck({kind:"cuid",...y.errToObj(q)})}cuid2(q){return this._addCheck({kind:"cuid2",...y.errToObj(q)})}ulid(q){return this._addCheck({kind:"ulid",...y.errToObj(q)})}base64(q){return this._addCheck({kind:"base64",...y.errToObj(q)})}base64url(q){return this._addCheck({kind:"base64url",...y.errToObj(q)})}jwt(q){return this._addCheck({kind:"jwt",...y.errToObj(q)})}ip(q){return this._addCheck({kind:"ip",...y.errToObj(q)})}cidr(q){return this._addCheck({kind:"cidr",...y.errToObj(q)})}datetime(q){if(typeof q==="string")return this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:q});return this._addCheck({kind:"datetime",precision:typeof q?.precision>"u"?null:q?.precision,offset:q?.offset??!1,local:q?.local??!1,...y.errToObj(q?.message)})}date(q){return this._addCheck({kind:"date",message:q})}time(q){if(typeof q==="string")return this._addCheck({kind:"time",precision:null,message:q});return this._addCheck({kind:"time",precision:typeof q?.precision>"u"?null:q?.precision,...y.errToObj(q?.message)})}duration(q){return this._addCheck({kind:"duration",...y.errToObj(q)})}regex(q,$){return this._addCheck({kind:"regex",regex:q,...y.errToObj($)})}includes(q,$){return this._addCheck({kind:"includes",value:q,position:$?.position,...y.errToObj($?.message)})}startsWith(q,$){return this._addCheck({kind:"startsWith",value:q,...y.errToObj($)})}endsWith(q,$){return this._addCheck({kind:"endsWith",value:q,...y.errToObj($)})}min(q,$){return this._addCheck({kind:"min",value:q,...y.errToObj($)})}max(q,$){return this._addCheck({kind:"max",value:q,...y.errToObj($)})}length(q,$){return this._addCheck({kind:"length",value:q,...y.errToObj($)})}nonempty(q){return this.min(1,y.errToObj(q))}trim(){return new lq({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new lq({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new lq({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find((q)=>q.kind==="datetime")}get isDate(){return!!this._def.checks.find((q)=>q.kind==="date")}get isTime(){return!!this._def.checks.find((q)=>q.kind==="time")}get isDuration(){return!!this._def.checks.find((q)=>q.kind==="duration")}get isEmail(){return!!this._def.checks.find((q)=>q.kind==="email")}get isURL(){return!!this._def.checks.find((q)=>q.kind==="url")}get isEmoji(){return!!this._def.checks.find((q)=>q.kind==="emoji")}get isUUID(){return!!this._def.checks.find((q)=>q.kind==="uuid")}get isNANOID(){return!!this._def.checks.find((q)=>q.kind==="nanoid")}get isCUID(){return!!this._def.checks.find((q)=>q.kind==="cuid")}get isCUID2(){return!!this._def.checks.find((q)=>q.kind==="cuid2")}get isULID(){return!!this._def.checks.find((q)=>q.kind==="ulid")}get isIP(){return!!this._def.checks.find((q)=>q.kind==="ip")}get isCIDR(){return!!this._def.checks.find((q)=>q.kind==="cidr")}get isBase64(){return!!this._def.checks.find((q)=>q.kind==="base64")}get isBase64url(){return!!this._def.checks.find((q)=>q.kind==="base64url")}get minLength(){let q=null;for(let $ of this._def.checks)if($.kind==="min"){if(q===null||$.value>q)q=$.value}return q}get maxLength(){let q=null;for(let $ of this._def.checks)if($.kind==="max"){if(q===null||$.value<q)q=$.value}return q}}lq.create=(q)=>{return new lq({checks:[],typeName:u.ZodString,coerce:q?.coerce??!1,...i(q)})};function EG(q,$){let J=(q.toString().split(".")[1]||"").length,G=($.toString().split(".")[1]||"").length,X=J>G?J:G,Y=Number.parseInt(q.toFixed(X).replace(".","")),U=Number.parseInt($.toFixed(X).replace(".",""));return Y%U/10**X}class w1 extends c{constructor(){super(...arguments);this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(q){if(this._def.coerce)q.data=Number(q.data);if(this._getType(q)!==E.number){let X=this._getOrReturnCtx(q);return _(X,{code:Z.invalid_type,expected:E.number,received:X.parsedType}),k}let J=void 0,G=new wq;for(let X of this._def.checks)if(X.kind==="int"){if(!o.isInteger(q.data))J=this._getOrReturnCtx(q,J),_(J,{code:Z.invalid_type,expected:"integer",received:"float",message:X.message}),G.dirty()}else if(X.kind==="min"){if(X.inclusive?q.data<X.value:q.data<=X.value)J=this._getOrReturnCtx(q,J),_(J,{code:Z.too_small,minimum:X.value,type:"number",inclusive:X.inclusive,exact:!1,message:X.message}),G.dirty()}else if(X.kind==="max"){if(X.inclusive?q.data>X.value:q.data>=X.value)J=this._getOrReturnCtx(q,J),_(J,{code:Z.too_big,maximum:X.value,type:"number",inclusive:X.inclusive,exact:!1,message:X.message}),G.dirty()}else if(X.kind==="multipleOf"){if(EG(q.data,X.value)!==0)J=this._getOrReturnCtx(q,J),_(J,{code:Z.not_multiple_of,multipleOf:X.value,message:X.message}),G.dirty()}else if(X.kind==="finite"){if(!Number.isFinite(q.data))J=this._getOrReturnCtx(q,J),_(J,{code:Z.not_finite,message:X.message}),G.dirty()}else o.assertNever(X);return{status:G.value,value:q.data}}gte(q,$){return this.setLimit("min",q,!0,y.toString($))}gt(q,$){return this.setLimit("min",q,!1,y.toString($))}lte(q,$){return this.setLimit("max",q,!0,y.toString($))}lt(q,$){return this.setLimit("max",q,!1,y.toString($))}setLimit(q,$,J,G){return new w1({...this._def,checks:[...this._def.checks,{kind:q,value:$,inclusive:J,message:y.toString(G)}]})}_addCheck(q){return new w1({...this._def,checks:[...this._def.checks,q]})}int(q){return this._addCheck({kind:"int",message:y.toString(q)})}positive(q){return this._addCheck({kind:"min",value:0,inclusive:!1,message:y.toString(q)})}negative(q){return this._addCheck({kind:"max",value:0,inclusive:!1,message:y.toString(q)})}nonpositive(q){return this._addCheck({kind:"max",value:0,inclusive:!0,message:y.toString(q)})}nonnegative(q){return this._addCheck({kind:"min",value:0,inclusive:!0,message:y.toString(q)})}multipleOf(q,$){return this._addCheck({kind:"multipleOf",value:q,message:y.toString($)})}finite(q){return this._addCheck({kind:"finite",message:y.toString(q)})}safe(q){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:y.toString(q)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:y.toString(q)})}get minValue(){let q=null;for(let $ of this._def.checks)if($.kind==="min"){if(q===null||$.value>q)q=$.value}return q}get maxValue(){let q=null;for(let $ of this._def.checks)if($.kind==="max"){if(q===null||$.value<q)q=$.value}return q}get isInt(){return!!this._def.checks.find((q)=>q.kind==="int"||q.kind==="multipleOf"&&o.isInteger(q.value))}get isFinite(){let q=null,$=null;for(let J of this._def.checks)if(J.kind==="finite"||J.kind==="int"||J.kind==="multipleOf")return!0;else if(J.kind==="min"){if($===null||J.value>$)$=J.value}else if(J.kind==="max"){if(q===null||J.value<q)q=J.value}return Number.isFinite($)&&Number.isFinite(q)}}w1.create=(q)=>{return new w1({checks:[],typeName:u.ZodNumber,coerce:q?.coerce||!1,...i(q)})};class F1 extends c{constructor(){super(...arguments);this.min=this.gte,this.max=this.lte}_parse(q){if(this._def.coerce)try{q.data=BigInt(q.data)}catch{return this._getInvalidInput(q)}if(this._getType(q)!==E.bigint)return this._getInvalidInput(q);let J=void 0,G=new wq;for(let X of this._def.checks)if(X.kind==="min"){if(X.inclusive?q.data<X.value:q.data<=X.value)J=this._getOrReturnCtx(q,J),_(J,{code:Z.too_small,type:"bigint",minimum:X.value,inclusive:X.inclusive,message:X.message}),G.dirty()}else if(X.kind==="max"){if(X.inclusive?q.data>X.value:q.data>=X.value)J=this._getOrReturnCtx(q,J),_(J,{code:Z.too_big,type:"bigint",maximum:X.value,inclusive:X.inclusive,message:X.message}),G.dirty()}else if(X.kind==="multipleOf"){if(q.data%X.value!==BigInt(0))J=this._getOrReturnCtx(q,J),_(J,{code:Z.not_multiple_of,multipleOf:X.value,message:X.message}),G.dirty()}else o.assertNever(X);return{status:G.value,value:q.data}}_getInvalidInput(q){let $=this._getOrReturnCtx(q);return _($,{code:Z.invalid_type,expected:E.bigint,received:$.parsedType}),k}gte(q,$){return this.setLimit("min",q,!0,y.toString($))}gt(q,$){return this.setLimit("min",q,!1,y.toString($))}lte(q,$){return this.setLimit("max",q,!0,y.toString($))}lt(q,$){return this.setLimit("max",q,!1,y.toString($))}setLimit(q,$,J,G){return new F1({...this._def,checks:[...this._def.checks,{kind:q,value:$,inclusive:J,message:y.toString(G)}]})}_addCheck(q){return new F1({...this._def,checks:[...this._def.checks,q]})}positive(q){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:y.toString(q)})}negative(q){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:y.toString(q)})}nonpositive(q){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:y.toString(q)})}nonnegative(q){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:y.toString(q)})}multipleOf(q,$){return this._addCheck({kind:"multipleOf",value:q,message:y.toString($)})}get minValue(){let q=null;for(let $ of this._def.checks)if($.kind==="min"){if(q===null||$.value>q)q=$.value}return q}get maxValue(){let q=null;for(let $ of this._def.checks)if($.kind==="max"){if(q===null||$.value<q)q=$.value}return q}}F1.create=(q)=>{return new F1({checks:[],typeName:u.ZodBigInt,coerce:q?.coerce??!1,...i(q)})};class M0 extends c{_parse(q){if(this._def.coerce)q.data=Boolean(q.data);if(this._getType(q)!==E.boolean){let J=this._getOrReturnCtx(q);return _(J,{code:Z.invalid_type,expected:E.boolean,received:J.parsedType}),k}return Nq(q.data)}}M0.create=(q)=>{return new M0({typeName:u.ZodBoolean,coerce:q?.coerce||!1,...i(q)})};class y1 extends c{_parse(q){if(this._def.coerce)q.data=new Date(q.data);if(this._getType(q)!==E.date){let X=this._getOrReturnCtx(q);return _(X,{code:Z.invalid_type,expected:E.date,received:X.parsedType}),k}if(Number.isNaN(q.data.getTime())){let X=this._getOrReturnCtx(q);return _(X,{code:Z.invalid_date}),k}let J=new wq,G=void 0;for(let X of this._def.checks)if(X.kind==="min"){if(q.data.getTime()<X.value)G=this._getOrReturnCtx(q,G),_(G,{code:Z.too_small,message:X.message,inclusive:!0,exact:!1,minimum:X.value,type:"date"}),J.dirty()}else if(X.kind==="max"){if(q.data.getTime()>X.value)G=this._getOrReturnCtx(q,G),_(G,{code:Z.too_big,message:X.message,inclusive:!0,exact:!1,maximum:X.value,type:"date"}),J.dirty()}else o.assertNever(X);return{status:J.value,value:new Date(q.data.getTime())}}_addCheck(q){return new y1({...this._def,checks:[...this._def.checks,q]})}min(q,$){return this._addCheck({kind:"min",value:q.getTime(),message:y.toString($)})}max(q,$){return this._addCheck({kind:"max",value:q.getTime(),message:y.toString($)})}get minDate(){let q=null;for(let $ of this._def.checks)if($.kind==="min"){if(q===null||$.value>q)q=$.value}return q!=null?new Date(q):null}get maxDate(){let q=null;for(let $ of this._def.checks)if($.kind==="max"){if(q===null||$.value<q)q=$.value}return q!=null?new Date(q):null}}y1.create=(q)=>{return new y1({checks:[],coerce:q?.coerce||!1,typeName:u.ZodDate,...i(q)})};class s0 extends c{_parse(q){if(this._getType(q)!==E.symbol){let J=this._getOrReturnCtx(q);return _(J,{code:Z.invalid_type,expected:E.symbol,received:J.parsedType}),k}return Nq(q.data)}}s0.create=(q)=>{return new s0({typeName:u.ZodSymbol,...i(q)})};class K0 extends c{_parse(q){if(this._getType(q)!==E.undefined){let J=this._getOrReturnCtx(q);return _(J,{code:Z.invalid_type,expected:E.undefined,received:J.parsedType}),k}return Nq(q.data)}}K0.create=(q)=>{return new K0({typeName:u.ZodUndefined,...i(q)})};class D0 extends c{_parse(q){if(this._getType(q)!==E.null){let J=this._getOrReturnCtx(q);return _(J,{code:Z.invalid_type,expected:E.null,received:J.parsedType}),k}return Nq(q.data)}}D0.create=(q)=>{return new D0({typeName:u.ZodNull,...i(q)})};class h1 extends c{constructor(){super(...arguments);this._any=!0}_parse(q){return Nq(q.data)}}h1.create=(q)=>{return new h1({typeName:u.ZodAny,...i(q)})};class R1 extends c{constructor(){super(...arguments);this._unknown=!0}_parse(q){return Nq(q.data)}}R1.create=(q)=>{return new R1({typeName:u.ZodUnknown,...i(q)})};class eq extends c{_parse(q){let $=this._getOrReturnCtx(q);return _($,{code:Z.invalid_type,expected:E.never,received:$.parsedType}),k}}eq.create=(q)=>{return new eq({typeName:u.ZodNever,...i(q)})};class t0 extends c{_parse(q){if(this._getType(q)!==E.undefined){let J=this._getOrReturnCtx(q);return _(J,{code:Z.invalid_type,expected:E.void,received:J.parsedType}),k}return Nq(q.data)}}t0.create=(q)=>{return new t0({typeName:u.ZodVoid,...i(q)})};class rq extends c{_parse(q){let{ctx:$,status:J}=this._processInputParams(q),G=this._def;if($.parsedType!==E.array)return _($,{code:Z.invalid_type,expected:E.array,received:$.parsedType}),k;if(G.exactLength!==null){let Y=$.data.length>G.exactLength.value,U=$.data.length<G.exactLength.value;if(Y||U)_($,{code:Y?Z.too_big:Z.too_small,minimum:U?G.exactLength.value:void 0,maximum:Y?G.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:G.exactLength.message}),J.dirty()}if(G.minLength!==null){if($.data.length<G.minLength.value)_($,{code:Z.too_small,minimum:G.minLength.value,type:"array",inclusive:!0,exact:!1,message:G.minLength.message}),J.dirty()}if(G.maxLength!==null){if($.data.length>G.maxLength.value)_($,{code:Z.too_big,maximum:G.maxLength.value,type:"array",inclusive:!0,exact:!1,message:G.maxLength.message}),J.dirty()}if($.common.async)return Promise.all([...$.data].map((Y,U)=>{return G.type._parseAsync(new dq($,Y,$.path,U))})).then((Y)=>{return wq.mergeArray(J,Y)});let X=[...$.data].map((Y,U)=>{return G.type._parseSync(new dq($,Y,$.path,U))});return wq.mergeArray(J,X)}get element(){return this._def.type}min(q,$){return new rq({...this._def,minLength:{value:q,message:y.toString($)}})}max(q,$){return new rq({...this._def,maxLength:{value:q,message:y.toString($)}})}length(q,$){return new rq({...this._def,exactLength:{value:q,message:y.toString($)}})}nonempty(q){return this.min(1,q)}}rq.create=(q,$)=>{return new rq({type:q,minLength:null,maxLength:null,exactLength:null,typeName:u.ZodArray,...i($)})};function H0(q){if(q instanceof Uq){let $={};for(let J in q.shape){let G=q.shape[J];$[J]=iq.create(H0(G))}return new Uq({...q._def,shape:()=>$})}else if(q instanceof rq)return new rq({...q._def,type:H0(q.element)});else if(q instanceof iq)return iq.create(H0(q.unwrap()));else if(q instanceof z1)return z1.create(H0(q.unwrap()));else if(q instanceof q1)return q1.create(q.items.map(($)=>H0($)));else return q}class Uq extends c{constructor(){super(...arguments);this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;let q=this._def.shape(),$=o.objectKeys(q);return this._cached={shape:q,keys:$},this._cached}_parse(q){if(this._getType(q)!==E.object){let V=this._getOrReturnCtx(q);return _(V,{code:Z.invalid_type,expected:E.object,received:V.parsedType}),k}let{status:J,ctx:G}=this._processInputParams(q),{shape:X,keys:Y}=this._getCached(),U=[];if(!(this._def.catchall instanceof eq&&this._def.unknownKeys==="strip")){for(let V in G.data)if(!Y.includes(V))U.push(V)}let Q=[];for(let V of Y){let W=X[V],H=G.data[V];Q.push({key:{status:"valid",value:V},value:W._parse(new dq(G,H,G.path,V)),alwaysSet:V in G.data})}if(this._def.catchall instanceof eq){let V=this._def.unknownKeys;if(V==="passthrough")for(let W of U)Q.push({key:{status:"valid",value:W},value:{status:"valid",value:G.data[W]}});else if(V==="strict"){if(U.length>0)_(G,{code:Z.unrecognized_keys,keys:U}),J.dirty()}else if(V==="strip");else throw Error("Internal ZodObject error: invalid unknownKeys value.")}else{let V=this._def.catchall;for(let W of U){let H=G.data[W];Q.push({key:{status:"valid",value:W},value:V._parse(new dq(G,H,G.path,W)),alwaysSet:W in G.data})}}if(G.common.async)return Promise.resolve().then(async()=>{let V=[];for(let W of Q){let H=await W.key,z=await W.value;V.push({key:H,value:z,alwaysSet:W.alwaysSet})}return V}).then((V)=>{return wq.mergeObjectSync(J,V)});else return wq.mergeObjectSync(J,Q)}get shape(){return this._def.shape()}strict(q){return y.errToObj,new Uq({...this._def,unknownKeys:"strict",...q!==void 0?{errorMap:($,J)=>{let G=this._def.errorMap?.($,J).message??J.defaultError;if($.code==="unrecognized_keys")return{message:y.errToObj(q).message??G};return{message:G}}}:{}})}strip(){return new Uq({...this._def,unknownKeys:"strip"})}passthrough(){return new Uq({...this._def,unknownKeys:"passthrough"})}extend(q){return new Uq({...this._def,shape:()=>({...this._def.shape(),...q})})}merge(q){return new Uq({unknownKeys:q._def.unknownKeys,catchall:q._def.catchall,shape:()=>({...this._def.shape(),...q._def.shape()}),typeName:u.ZodObject})}setKey(q,$){return this.augment({[q]:$})}catchall(q){return new Uq({...this._def,catchall:q})}pick(q){let $={};for(let J of o.objectKeys(q))if(q[J]&&this.shape[J])$[J]=this.shape[J];return new Uq({...this._def,shape:()=>$})}omit(q){let $={};for(let J of o.objectKeys(this.shape))if(!q[J])$[J]=this.shape[J];return new Uq({...this._def,shape:()=>$})}deepPartial(){return H0(this)}partial(q){let $={};for(let J of o.objectKeys(this.shape)){let G=this.shape[J];if(q&&!q[J])$[J]=G;else $[J]=G.optional()}return new Uq({...this._def,shape:()=>$})}required(q){let $={};for(let J of o.objectKeys(this.shape))if(q&&!q[J])$[J]=this.shape[J];else{let X=this.shape[J];while(X instanceof iq)X=X._def.innerType;$[J]=X}return new Uq({...this._def,shape:()=>$})}keyof(){return X5(o.objectKeys(this.shape))}}Uq.create=(q,$)=>{return new Uq({shape:()=>q,unknownKeys:"strip",catchall:eq.create(),typeName:u.ZodObject,...i($)})};Uq.strictCreate=(q,$)=>{return new Uq({shape:()=>q,unknownKeys:"strict",catchall:eq.create(),typeName:u.ZodObject,...i($)})};Uq.lazycreate=(q,$)=>{return new Uq({shape:q,unknownKeys:"strip",catchall:eq.create(),typeName:u.ZodObject,...i($)})};class B0 extends c{_parse(q){let{ctx:$}=this._processInputParams(q),J=this._def.options;function G(X){for(let U of X)if(U.result.status==="valid")return U.result;for(let U of X)if(U.result.status==="dirty")return $.common.issues.push(...U.ctx.common.issues),U.result;let Y=X.map((U)=>new Aq(U.ctx.common.issues));return _($,{code:Z.invalid_union,unionErrors:Y}),k}if($.common.async)return Promise.all(J.map(async(X)=>{let Y={...$,common:{...$.common,issues:[]},parent:null};return{result:await X._parseAsync({data:$.data,path:$.path,parent:Y}),ctx:Y}})).then(G);else{let X=void 0,Y=[];for(let Q of J){let V={...$,common:{...$.common,issues:[]},parent:null},W=Q._parseSync({data:$.data,path:$.path,parent:V});if(W.status==="valid")return W;else if(W.status==="dirty"&&!X)X={result:W,ctx:V};if(V.common.issues.length)Y.push(V.common.issues)}if(X)return $.common.issues.push(...X.ctx.common.issues),X.result;let U=Y.map((Q)=>new Aq(Q));return _($,{code:Z.invalid_union,unionErrors:U}),k}}get options(){return this._def.options}}B0.create=(q,$)=>{return new B0({options:q,typeName:u.ZodUnion,...i($)})};var H1=(q)=>{if(q instanceof w0)return H1(q.schema);else if(q instanceof cq)return H1(q.innerType());else if(q instanceof F0)return[q.value];else if(q instanceof O1)return q.options;else if(q instanceof O0)return o.objectValues(q.enum);else if(q instanceof A0)return H1(q._def.innerType);else if(q instanceof K0)return[void 0];else if(q instanceof D0)return[null];else if(q instanceof iq)return[void 0,...H1(q.unwrap())];else if(q instanceof z1)return[null,...H1(q.unwrap())];else if(q instanceof m$)return H1(q.unwrap());else if(q instanceof j0)return H1(q.unwrap());else if(q instanceof N0)return H1(q._def.innerType);else return[]};class x$ extends c{_parse(q){let{ctx:$}=this._processInputParams(q);if($.parsedType!==E.object)return _($,{code:Z.invalid_type,expected:E.object,received:$.parsedType}),k;let J=this.discriminator,G=$.data[J],X=this.optionsMap.get(G);if(!X)return _($,{code:Z.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[J]}),k;if($.common.async)return X._parseAsync({data:$.data,path:$.path,parent:$});else return X._parseSync({data:$.data,path:$.path,parent:$})}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(q,$,J){let G=new Map;for(let X of $){let Y=H1(X.shape[q]);if(!Y.length)throw Error(`A discriminator value for key \`${q}\` could not be extracted from all schema options`);for(let U of Y){if(G.has(U))throw Error(`Discriminator property ${String(q)} has duplicate value ${String(U)}`);G.set(U,X)}}return new x$({typeName:u.ZodDiscriminatedUnion,discriminator:q,options:$,optionsMap:G,...i(J)})}}function c3(q,$){let J=tq(q),G=tq($);if(q===$)return{valid:!0,data:q};else if(J===E.object&&G===E.object){let X=o.objectKeys($),Y=o.objectKeys(q).filter((Q)=>X.indexOf(Q)!==-1),U={...q,...$};for(let Q of Y){let V=c3(q[Q],$[Q]);if(!V.valid)return{valid:!1};U[Q]=V.data}return{valid:!0,data:U}}else if(J===E.array&&G===E.array){if(q.length!==$.length)return{valid:!1};let X=[];for(let Y=0;Y<q.length;Y++){let U=q[Y],Q=$[Y],V=c3(U,Q);if(!V.valid)return{valid:!1};X.push(V.data)}return{valid:!0,data:X}}else if(J===E.date&&G===E.date&&+q===+$)return{valid:!0,data:q};else return{valid:!1}}class R0 extends c{_parse(q){let{status:$,ctx:J}=this._processInputParams(q),G=(X,Y)=>{if(y$(X)||y$(Y))return k;let U=c3(X.value,Y.value);if(!U.valid)return _(J,{code:Z.invalid_intersection_types}),k;if(h$(X)||h$(Y))$.dirty();return{status:$.value,value:U.data}};if(J.common.async)return Promise.all([this._def.left._parseAsync({data:J.data,path:J.path,parent:J}),this._def.right._parseAsync({data:J.data,path:J.path,parent:J})]).then(([X,Y])=>G(X,Y));else return G(this._def.left._parseSync({data:J.data,path:J.path,parent:J}),this._def.right._parseSync({data:J.data,path:J.path,parent:J}))}}R0.create=(q,$,J)=>{return new R0({left:q,right:$,typeName:u.ZodIntersection,...i(J)})};class q1 extends c{_parse(q){let{status:$,ctx:J}=this._processInputParams(q);if(J.parsedType!==E.array)return _(J,{code:Z.invalid_type,expected:E.array,received:J.parsedType}),k;if(J.data.length<this._def.items.length)return _(J,{code:Z.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),k;if(!this._def.rest&&J.data.length>this._def.items.length)_(J,{code:Z.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),$.dirty();let X=[...J.data].map((Y,U)=>{let Q=this._def.items[U]||this._def.rest;if(!Q)return null;return Q._parse(new dq(J,Y,J.path,U))}).filter((Y)=>!!Y);if(J.common.async)return Promise.all(X).then((Y)=>{return wq.mergeArray($,Y)});else return wq.mergeArray($,X)}get items(){return this._def.items}rest(q){return new q1({...this._def,rest:q})}}q1.create=(q,$)=>{if(!Array.isArray(q))throw Error("You must pass an array of schemas to z.tuple([ ... ])");return new q1({items:q,typeName:u.ZodTuple,rest:null,...i($)})};class e0 extends c{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(q){let{status:$,ctx:J}=this._processInputParams(q);if(J.parsedType!==E.object)return _(J,{code:Z.invalid_type,expected:E.object,received:J.parsedType}),k;let G=[],X=this._def.keyType,Y=this._def.valueType;for(let U in J.data)G.push({key:X._parse(new dq(J,U,J.path,U)),value:Y._parse(new dq(J,J.data[U],J.path,U)),alwaysSet:U in J.data});if(J.common.async)return wq.mergeObjectAsync($,G);else return wq.mergeObjectSync($,G)}get element(){return this._def.valueType}static create(q,$,J){if($ instanceof c)return new e0({keyType:q,valueType:$,typeName:u.ZodRecord,...i(J)});return new e0({keyType:lq.create(),valueType:q,typeName:u.ZodRecord,...i($)})}}class q$ extends c{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(q){let{status:$,ctx:J}=this._processInputParams(q);if(J.parsedType!==E.map)return _(J,{code:Z.invalid_type,expected:E.map,received:J.parsedType}),k;let G=this._def.keyType,X=this._def.valueType,Y=[...J.data.entries()].map(([U,Q],V)=>{return{key:G._parse(new dq(J,U,J.path,[V,"key"])),value:X._parse(new dq(J,Q,J.path,[V,"value"]))}});if(J.common.async){let U=new Map;return Promise.resolve().then(async()=>{for(let Q of Y){let V=await Q.key,W=await Q.value;if(V.status==="aborted"||W.status==="aborted")return k;if(V.status==="dirty"||W.status==="dirty")$.dirty();U.set(V.value,W.value)}return{status:$.value,value:U}})}else{let U=new Map;for(let Q of Y){let{key:V,value:W}=Q;if(V.status==="aborted"||W.status==="aborted")return k;if(V.status==="dirty"||W.status==="dirty")$.dirty();U.set(V.value,W.value)}return{status:$.value,value:U}}}}q$.create=(q,$,J)=>{return new q$({valueType:$,keyType:q,typeName:u.ZodMap,...i(J)})};class x1 extends c{_parse(q){let{status:$,ctx:J}=this._processInputParams(q);if(J.parsedType!==E.set)return _(J,{code:Z.invalid_type,expected:E.set,received:J.parsedType}),k;let G=this._def;if(G.minSize!==null){if(J.data.size<G.minSize.value)_(J,{code:Z.too_small,minimum:G.minSize.value,type:"set",inclusive:!0,exact:!1,message:G.minSize.message}),$.dirty()}if(G.maxSize!==null){if(J.data.size>G.maxSize.value)_(J,{code:Z.too_big,maximum:G.maxSize.value,type:"set",inclusive:!0,exact:!1,message:G.maxSize.message}),$.dirty()}let X=this._def.valueType;function Y(Q){let V=new Set;for(let W of Q){if(W.status==="aborted")return k;if(W.status==="dirty")$.dirty();V.add(W.value)}return{status:$.value,value:V}}let U=[...J.data.values()].map((Q,V)=>X._parse(new dq(J,Q,J.path,V)));if(J.common.async)return Promise.all(U).then((Q)=>Y(Q));else return Y(U)}min(q,$){return new x1({...this._def,minSize:{value:q,message:y.toString($)}})}max(q,$){return new x1({...this._def,maxSize:{value:q,message:y.toString($)}})}size(q,$){return this.min(q,$).max(q,$)}nonempty(q){return this.min(1,q)}}x1.create=(q,$)=>{return new x1({valueType:q,minSize:null,maxSize:null,typeName:u.ZodSet,...i($)})};class z0 extends c{constructor(){super(...arguments);this.validate=this.implement}_parse(q){let{ctx:$}=this._processInputParams(q);if($.parsedType!==E.function)return _($,{code:Z.invalid_type,expected:E.function,received:$.parsedType}),k;function J(U,Q){return a0({data:U,path:$.path,errorMaps:[$.common.contextualErrorMap,$.schemaErrorMap,V0(),W1].filter((V)=>!!V),issueData:{code:Z.invalid_arguments,argumentsError:Q}})}function G(U,Q){return a0({data:U,path:$.path,errorMaps:[$.common.contextualErrorMap,$.schemaErrorMap,V0(),W1].filter((V)=>!!V),issueData:{code:Z.invalid_return_type,returnTypeError:Q}})}let X={errorMap:$.common.contextualErrorMap},Y=$.data;if(this._def.returns instanceof m1){let U=this;return Nq(async function(...Q){let V=new Aq([]),W=await U._def.args.parseAsync(Q,X).catch((B)=>{throw V.addIssue(J(Q,B)),V}),H=await Reflect.apply(Y,this,W);return await U._def.returns._def.type.parseAsync(H,X).catch((B)=>{throw V.addIssue(G(H,B)),V})})}else{let U=this;return Nq(function(...Q){let V=U._def.args.safeParse(Q,X);if(!V.success)throw new Aq([J(Q,V.error)]);let W=Reflect.apply(Y,this,V.data),H=U._def.returns.safeParse(W,X);if(!H.success)throw new Aq([G(W,H.error)]);return H.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...q){return new z0({...this._def,args:q1.create(q).rest(R1.create())})}returns(q){return new z0({...this._def,returns:q})}implement(q){return this.parse(q)}strictImplement(q){return this.parse(q)}static create(q,$,J){return new z0({args:q?q:q1.create([]).rest(R1.create()),returns:$||R1.create(),typeName:u.ZodFunction,...i(J)})}}class w0 extends c{get schema(){return this._def.getter()}_parse(q){let{ctx:$}=this._processInputParams(q);return this._def.getter()._parse({data:$.data,path:$.path,parent:$})}}w0.create=(q,$)=>{return new w0({getter:q,typeName:u.ZodLazy,...i($)})};class F0 extends c{_parse(q){if(q.data!==this._def.value){let $=this._getOrReturnCtx(q);return _($,{received:$.data,code:Z.invalid_literal,expected:this._def.value}),k}return{status:"valid",value:q.data}}get value(){return this._def.value}}F0.create=(q,$)=>{return new F0({value:q,typeName:u.ZodLiteral,...i($)})};function X5(q,$){return new O1({values:q,typeName:u.ZodEnum,...i($)})}class O1 extends c{_parse(q){if(typeof q.data!=="string"){let $=this._getOrReturnCtx(q),J=this._def.values;return _($,{expected:o.joinValues(J),received:$.parsedType,code:Z.invalid_type}),k}if(!this._cache)this._cache=new Set(this._def.values);if(!this._cache.has(q.data)){let $=this._getOrReturnCtx(q),J=this._def.values;return _($,{received:$.data,code:Z.invalid_enum_value,options:J}),k}return Nq(q.data)}get options(){return this._def.values}get enum(){let q={};for(let $ of this._def.values)q[$]=$;return q}get Values(){let q={};for(let $ of this._def.values)q[$]=$;return q}get Enum(){let q={};for(let $ of this._def.values)q[$]=$;return q}extract(q,$=this._def){return O1.create(q,{...this._def,...$})}exclude(q,$=this._def){return O1.create(this.options.filter((J)=>!q.includes(J)),{...this._def,...$})}}O1.create=X5;class O0 extends c{_parse(q){let $=o.getValidEnumValues(this._def.values),J=this._getOrReturnCtx(q);if(J.parsedType!==E.string&&J.parsedType!==E.number){let G=o.objectValues($);return _(J,{expected:o.joinValues(G),received:J.parsedType,code:Z.invalid_type}),k}if(!this._cache)this._cache=new Set(o.getValidEnumValues(this._def.values));if(!this._cache.has(q.data)){let G=o.objectValues($);return _(J,{received:J.data,code:Z.invalid_enum_value,options:G}),k}return Nq(q.data)}get enum(){return this._def.values}}O0.create=(q,$)=>{return new O0({values:q,typeName:u.ZodNativeEnum,...i($)})};class m1 extends c{unwrap(){return this._def.type}_parse(q){let{ctx:$}=this._processInputParams(q);if($.parsedType!==E.promise&&$.common.async===!1)return _($,{code:Z.invalid_type,expected:E.promise,received:$.parsedType}),k;let J=$.parsedType===E.promise?$.data:Promise.resolve($.data);return Nq(J.then((G)=>{return this._def.type.parseAsync(G,{path:$.path,errorMap:$.common.contextualErrorMap})}))}}m1.create=(q,$)=>{return new m1({type:q,typeName:u.ZodPromise,...i($)})};class cq extends c{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===u.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(q){let{status:$,ctx:J}=this._processInputParams(q),G=this._def.effect||null,X={addIssue:(Y)=>{if(_(J,Y),Y.fatal)$.abort();else $.dirty()},get path(){return J.path}};if(X.addIssue=X.addIssue.bind(X),G.type==="preprocess"){let Y=G.transform(J.data,X);if(J.common.async)return Promise.resolve(Y).then(async(U)=>{if($.value==="aborted")return k;let Q=await this._def.schema._parseAsync({data:U,path:J.path,parent:J});if(Q.status==="aborted")return k;if(Q.status==="dirty")return v1(Q.value);if($.value==="dirty")return v1(Q.value);return Q});else{if($.value==="aborted")return k;let U=this._def.schema._parseSync({data:Y,path:J.path,parent:J});if(U.status==="aborted")return k;if(U.status==="dirty")return v1(U.value);if($.value==="dirty")return v1(U.value);return U}}if(G.type==="refinement"){let Y=(U)=>{let Q=G.refinement(U,X);if(J.common.async)return Promise.resolve(Q);if(Q instanceof Promise)throw Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return U};if(J.common.async===!1){let U=this._def.schema._parseSync({data:J.data,path:J.path,parent:J});if(U.status==="aborted")return k;if(U.status==="dirty")$.dirty();return Y(U.value),{status:$.value,value:U.value}}else return this._def.schema._parseAsync({data:J.data,path:J.path,parent:J}).then((U)=>{if(U.status==="aborted")return k;if(U.status==="dirty")$.dirty();return Y(U.value).then(()=>{return{status:$.value,value:U.value}})})}if(G.type==="transform")if(J.common.async===!1){let Y=this._def.schema._parseSync({data:J.data,path:J.path,parent:J});if(!B1(Y))return k;let U=G.transform(Y.value,X);if(U instanceof Promise)throw Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:$.value,value:U}}else return this._def.schema._parseAsync({data:J.data,path:J.path,parent:J}).then((Y)=>{if(!B1(Y))return k;return Promise.resolve(G.transform(Y.value,X)).then((U)=>({status:$.value,value:U}))});o.assertNever(G)}}cq.create=(q,$,J)=>{return new cq({schema:q,typeName:u.ZodEffects,effect:$,...i(J)})};cq.createWithPreprocess=(q,$,J)=>{return new cq({schema:$,effect:{type:"preprocess",transform:q},typeName:u.ZodEffects,...i(J)})};class iq extends c{_parse(q){if(this._getType(q)===E.undefined)return Nq(void 0);return this._def.innerType._parse(q)}unwrap(){return this._def.innerType}}iq.create=(q,$)=>{return new iq({innerType:q,typeName:u.ZodOptional,...i($)})};class z1 extends c{_parse(q){if(this._getType(q)===E.null)return Nq(null);return this._def.innerType._parse(q)}unwrap(){return this._def.innerType}}z1.create=(q,$)=>{return new z1({innerType:q,typeName:u.ZodNullable,...i($)})};class A0 extends c{_parse(q){let{ctx:$}=this._processInputParams(q),J=$.data;if($.parsedType===E.undefined)J=this._def.defaultValue();return this._def.innerType._parse({data:J,path:$.path,parent:$})}removeDefault(){return this._def.innerType}}A0.create=(q,$)=>{return new A0({innerType:q,typeName:u.ZodDefault,defaultValue:typeof $.default==="function"?$.default:()=>$.default,...i($)})};class N0 extends c{_parse(q){let{ctx:$}=this._processInputParams(q),J={...$,common:{...$.common,issues:[]}},G=this._def.innerType._parse({data:J.data,path:J.path,parent:{...J}});if(W0(G))return G.then((X)=>{return{status:"valid",value:X.status==="valid"?X.value:this._def.catchValue({get error(){return new Aq(J.common.issues)},input:J.data})}});else return{status:"valid",value:G.status==="valid"?G.value:this._def.catchValue({get error(){return new Aq(J.common.issues)},input:J.data})}}removeCatch(){return this._def.innerType}}N0.create=(q,$)=>{return new N0({innerType:q,typeName:u.ZodCatch,catchValue:typeof $.catch==="function"?$.catch:()=>$.catch,...i($)})};class $$ extends c{_parse(q){if(this._getType(q)!==E.nan){let J=this._getOrReturnCtx(q);return _(J,{code:Z.invalid_type,expected:E.nan,received:J.parsedType}),k}return{status:"valid",value:q.data}}}$$.create=(q)=>{return new $$({typeName:u.ZodNaN,...i(q)})};var TG=Symbol("zod_brand");class m$ extends c{_parse(q){let{ctx:$}=this._processInputParams(q),J=$.data;return this._def.type._parse({data:J,path:$.path,parent:$})}unwrap(){return this._def.type}}class J$ extends c{_parse(q){let{status:$,ctx:J}=this._processInputParams(q);if(J.common.async)return(async()=>{let X=await this._def.in._parseAsync({data:J.data,path:J.path,parent:J});if(X.status==="aborted")return k;if(X.status==="dirty")return $.dirty(),v1(X.value);else return this._def.out._parseAsync({data:X.value,path:J.path,parent:J})})();else{let G=this._def.in._parseSync({data:J.data,path:J.path,parent:J});if(G.status==="aborted")return k;if(G.status==="dirty")return $.dirty(),{status:"dirty",value:G.value};else return this._def.out._parseSync({data:G.value,path:J.path,parent:J})}}static create(q,$){return new J$({in:q,out:$,typeName:u.ZodPipeline})}}class j0 extends c{_parse(q){let $=this._def.innerType._parse(q),J=(G)=>{if(B1(G))G.value=Object.freeze(G.value);return G};return W0($)?$.then((G)=>J(G)):J($)}unwrap(){return this._def.innerType}}j0.create=(q,$)=>{return new j0({innerType:q,typeName:u.ZodReadonly,...i($)})};function q5(q,$){let J=typeof q==="function"?q($):typeof q==="string"?{message:q}:q;return typeof J==="string"?{message:J}:J}function Y5(q,$={},J){if(q)return h1.create().superRefine((G,X)=>{let Y=q(G);if(Y instanceof Promise)return Y.then((U)=>{if(!U){let Q=q5($,G),V=Q.fatal??J??!0;X.addIssue({code:"custom",...Q,fatal:V})}});if(!Y){let U=q5($,G),Q=U.fatal??J??!0;X.addIssue({code:"custom",...U,fatal:Q})}return});return h1.create()}var _G={object:Uq.lazycreate},u;(function(q){q.ZodString="ZodString",q.ZodNumber="ZodNumber",q.ZodNaN="ZodNaN",q.ZodBigInt="ZodBigInt",q.ZodBoolean="ZodBoolean",q.ZodDate="ZodDate",q.ZodSymbol="ZodSymbol",q.ZodUndefined="ZodUndefined",q.ZodNull="ZodNull",q.ZodAny="ZodAny",q.ZodUnknown="ZodUnknown",q.ZodNever="ZodNever",q.ZodVoid="ZodVoid",q.ZodArray="ZodArray",q.ZodObject="ZodObject",q.ZodUnion="ZodUnion",q.ZodDiscriminatedUnion="ZodDiscriminatedUnion",q.ZodIntersection="ZodIntersection",q.ZodTuple="ZodTuple",q.ZodRecord="ZodRecord",q.ZodMap="ZodMap",q.ZodSet="ZodSet",q.ZodFunction="ZodFunction",q.ZodLazy="ZodLazy",q.ZodLiteral="ZodLiteral",q.ZodEnum="ZodEnum",q.ZodEffects="ZodEffects",q.ZodNativeEnum="ZodNativeEnum",q.ZodOptional="ZodOptional",q.ZodNullable="ZodNullable",q.ZodDefault="ZodDefault",q.ZodCatch="ZodCatch",q.ZodPromise="ZodPromise",q.ZodBranded="ZodBranded",q.ZodPipeline="ZodPipeline",q.ZodReadonly="ZodReadonly"})(u||(u={}));var bG=(q,$={message:`Input not instance of ${q.name}`})=>Y5((J)=>J instanceof q,$),U5=lq.create,Q5=w1.create,IG=$$.create,gG=F1.create,V5=M0.create,vG=y1.create,yG=s0.create,hG=K0.create,xG=D0.create,mG=h1.create,kG=R1.create,fG=eq.create,uG=t0.create,pG=rq.create,lG=Uq.create,rG=Uq.strictCreate,iG=B0.create,dG=x$.create,cG=R0.create,nG=q1.create,oG=e0.create,aG=q$.create,sG=x1.create,tG=z0.create,eG=w0.create,qX=F0.create,$X=O1.create,JX=O0.create,GX=m1.create,XX=cq.create,YX=iq.create,UX=z1.create,QX=cq.createWithPreprocess,VX=J$.create,WX=()=>U5().optional(),HX=()=>Q5().optional(),zX=()=>V5().optional(),MX={string:(q)=>lq.create({...q,coerce:!0}),number:(q)=>w1.create({...q,coerce:!0}),boolean:(q)=>M0.create({...q,coerce:!0}),bigint:(q)=>F1.create({...q,coerce:!0}),date:(q)=>y1.create({...q,coerce:!0})};var KX=k;var DX=b.object({url:b.string(),authToken:b.string().optional()});import{openSync as BX,writeSync as RX}from"fs";class nq{static instance=null;level;context;useStderr;format;logFile;fileHandle;constructor(q={},$){if(this.level=q.level??3,this.context=q.context??void 0,this.useStderr=q.useStderr??!1,this.format=q.format??"text",this.logFile=q.logFile,$!==void 0)this.fileHandle=$;else if(this.logFile)try{this.fileHandle=BX(this.logFile,"a")}catch{}}static getInstance(q){if(!nq.instance)nq.instance=new nq(q);else if(q?.useStderr!==void 0)nq.instance.useStderr=q.useStderr;return nq.instance}static resetInstance(){nq.instance=null}static createFresh(q){return new nq(q)}formatEntry(q,$,J){let G=new Date().toISOString();if(this.format==="json"){let X={ts:G,level:q,msg:$};if(this.context)X.ctx=this.context;if(J.length>0)X.data=J;return JSON.stringify(X)}return this.context?`[${G}] [${this.context}] ${$}`:`[${G}] ${$}`}write(q,$,J,G){if(this.format==="json")q(this.formatEntry($,J,G));else if(G.length>0)q(this.formatEntry($,J,[]),...G);else q(this.formatEntry($,J,[]));if(this.fileHandle!==void 0){let X=this.formatJsonEntry($,J,G);try{RX(this.fileHandle,X+`
|
|
57
|
-
`)}
|
|
58
|
-
`).map((
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
`+
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
`
|
|
88
|
-
`}
|
|
89
|
-
`}
|
|
90
|
-
|
|
91
|
-
`}
|
|
92
|
-
`}
|
|
93
|
-
`}
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
`}
|
|
98
|
-
${
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
`,Nfr:"\uD835\uDD11",NoBreak:"\u2060",NonBreakingSpace:"\xA0",Nopf:"\u2115",Not:"\u2AEC",NotCongruent:"\u2262",NotCupCap:"\u226D",NotDoubleVerticalBar:"\u2226",NotElement:"\u2209",NotEqual:"\u2260",NotEqualTilde:"\u2242\u0338",NotExists:"\u2204",NotGreater:"\u226F",NotGreaterEqual:"\u2271",NotGreaterFullEqual:"\u2267\u0338",NotGreaterGreater:"\u226B\u0338",NotGreaterLess:"\u2279",NotGreaterSlantEqual:"\u2A7E\u0338",NotGreaterTilde:"\u2275",NotHumpDownHump:"\u224E\u0338",NotHumpEqual:"\u224F\u0338",NotLeftTriangle:"\u22EA",NotLeftTriangleBar:"\u29CF\u0338",NotLeftTriangleEqual:"\u22EC",NotLess:"\u226E",NotLessEqual:"\u2270",NotLessGreater:"\u2278",NotLessLess:"\u226A\u0338",NotLessSlantEqual:"\u2A7D\u0338",NotLessTilde:"\u2274",NotNestedGreaterGreater:"\u2AA2\u0338",NotNestedLessLess:"\u2AA1\u0338",NotPrecedes:"\u2280",NotPrecedesEqual:"\u2AAF\u0338",NotPrecedesSlantEqual:"\u22E0",NotReverseElement:"\u220C",NotRightTriangle:"\u22EB",NotRightTriangleBar:"\u29D0\u0338",NotRightTriangleEqual:"\u22ED",NotSquareSubset:"\u228F\u0338",NotSquareSubsetEqual:"\u22E2",NotSquareSuperset:"\u2290\u0338",NotSquareSupersetEqual:"\u22E3",NotSubset:"\u2282\u20D2",NotSubsetEqual:"\u2288",NotSucceeds:"\u2281",NotSucceedsEqual:"\u2AB0\u0338",NotSucceedsSlantEqual:"\u22E1",NotSucceedsTilde:"\u227F\u0338",NotSuperset:"\u2283\u20D2",NotSupersetEqual:"\u2289",NotTilde:"\u2241",NotTildeEqual:"\u2244",NotTildeFullEqual:"\u2247",NotTildeTilde:"\u2249",NotVerticalBar:"\u2224",Nscr:"\uD835\uDCA9",Ntilde:"\xD1",Nu:"\u039D",OElig:"\u0152",Oacute:"\xD3",Ocirc:"\xD4",Ocy:"\u041E",Odblac:"\u0150",Ofr:"\uD835\uDD12",Ograve:"\xD2",Omacr:"\u014C",Omega:"\u03A9",Omicron:"\u039F",Oopf:"\uD835\uDD46",OpenCurlyDoubleQuote:"\u201C",OpenCurlyQuote:"\u2018",Or:"\u2A54",Oscr:"\uD835\uDCAA",Oslash:"\xD8",Otilde:"\xD5",Otimes:"\u2A37",Ouml:"\xD6",OverBar:"\u203E",OverBrace:"\u23DE",OverBracket:"\u23B4",OverParenthesis:"\u23DC",PartialD:"\u2202",Pcy:"\u041F",Pfr:"\uD835\uDD13",Phi:"\u03A6",Pi:"\u03A0",PlusMinus:"\xB1",Poincareplane:"\u210C",Popf:"\u2119",Pr:"\u2ABB",Precedes:"\u227A",PrecedesEqual:"\u2AAF",PrecedesSlantEqual:"\u227C",PrecedesTilde:"\u227E",Prime:"\u2033",Product:"\u220F",Proportion:"\u2237",Proportional:"\u221D",Pscr:"\uD835\uDCAB",Psi:"\u03A8",QUOT:'"',Qfr:"\uD835\uDD14",Qopf:"\u211A",Qscr:"\uD835\uDCAC",RBarr:"\u2910",REG:"\xAE",Racute:"\u0154",Rang:"\u27EB",Rarr:"\u21A0",Rarrtl:"\u2916",Rcaron:"\u0158",Rcedil:"\u0156",Rcy:"\u0420",Re:"\u211C",ReverseElement:"\u220B",ReverseEquilibrium:"\u21CB",ReverseUpEquilibrium:"\u296F",Rfr:"\u211C",Rho:"\u03A1",RightAngleBracket:"\u27E9",RightArrow:"\u2192",RightArrowBar:"\u21E5",RightArrowLeftArrow:"\u21C4",RightCeiling:"\u2309",RightDoubleBracket:"\u27E7",RightDownTeeVector:"\u295D",RightDownVector:"\u21C2",RightDownVectorBar:"\u2955",RightFloor:"\u230B",RightTee:"\u22A2",RightTeeArrow:"\u21A6",RightTeeVector:"\u295B",RightTriangle:"\u22B3",RightTriangleBar:"\u29D0",RightTriangleEqual:"\u22B5",RightUpDownVector:"\u294F",RightUpTeeVector:"\u295C",RightUpVector:"\u21BE",RightUpVectorBar:"\u2954",RightVector:"\u21C0",RightVectorBar:"\u2953",Rightarrow:"\u21D2",Ropf:"\u211D",RoundImplies:"\u2970",Rrightarrow:"\u21DB",Rscr:"\u211B",Rsh:"\u21B1",RuleDelayed:"\u29F4",SHCHcy:"\u0429",SHcy:"\u0428",SOFTcy:"\u042C",Sacute:"\u015A",Sc:"\u2ABC",Scaron:"\u0160",Scedil:"\u015E",Scirc:"\u015C",Scy:"\u0421",Sfr:"\uD835\uDD16",ShortDownArrow:"\u2193",ShortLeftArrow:"\u2190",ShortRightArrow:"\u2192",ShortUpArrow:"\u2191",Sigma:"\u03A3",SmallCircle:"\u2218",Sopf:"\uD835\uDD4A",Sqrt:"\u221A",Square:"\u25A1",SquareIntersection:"\u2293",SquareSubset:"\u228F",SquareSubsetEqual:"\u2291",SquareSuperset:"\u2290",SquareSupersetEqual:"\u2292",SquareUnion:"\u2294",Sscr:"\uD835\uDCAE",Star:"\u22C6",Sub:"\u22D0",Subset:"\u22D0",SubsetEqual:"\u2286",Succeeds:"\u227B",SucceedsEqual:"\u2AB0",SucceedsSlantEqual:"\u227D",SucceedsTilde:"\u227F",SuchThat:"\u220B",Sum:"\u2211",Sup:"\u22D1",Superset:"\u2283",SupersetEqual:"\u2287",Supset:"\u22D1",THORN:"\xDE",TRADE:"\u2122",TSHcy:"\u040B",TScy:"\u0426",Tab:"\t",Tau:"\u03A4",Tcaron:"\u0164",Tcedil:"\u0162",Tcy:"\u0422",Tfr:"\uD835\uDD17",Therefore:"\u2234",Theta:"\u0398",ThickSpace:"\u205F\u200A",ThinSpace:"\u2009",Tilde:"\u223C",TildeEqual:"\u2243",TildeFullEqual:"\u2245",TildeTilde:"\u2248",Topf:"\uD835\uDD4B",TripleDot:"\u20DB",Tscr:"\uD835\uDCAF",Tstrok:"\u0166",Uacute:"\xDA",Uarr:"\u219F",Uarrocir:"\u2949",Ubrcy:"\u040E",Ubreve:"\u016C",Ucirc:"\xDB",Ucy:"\u0423",Udblac:"\u0170",Ufr:"\uD835\uDD18",Ugrave:"\xD9",Umacr:"\u016A",UnderBar:"_",UnderBrace:"\u23DF",UnderBracket:"\u23B5",UnderParenthesis:"\u23DD",Union:"\u22C3",UnionPlus:"\u228E",Uogon:"\u0172",Uopf:"\uD835\uDD4C",UpArrow:"\u2191",UpArrowBar:"\u2912",UpArrowDownArrow:"\u21C5",UpDownArrow:"\u2195",UpEquilibrium:"\u296E",UpTee:"\u22A5",UpTeeArrow:"\u21A5",Uparrow:"\u21D1",Updownarrow:"\u21D5",UpperLeftArrow:"\u2196",UpperRightArrow:"\u2197",Upsi:"\u03D2",Upsilon:"\u03A5",Uring:"\u016E",Uscr:"\uD835\uDCB0",Utilde:"\u0168",Uuml:"\xDC",VDash:"\u22AB",Vbar:"\u2AEB",Vcy:"\u0412",Vdash:"\u22A9",Vdashl:"\u2AE6",Vee:"\u22C1",Verbar:"\u2016",Vert:"\u2016",VerticalBar:"\u2223",VerticalLine:"|",VerticalSeparator:"\u2758",VerticalTilde:"\u2240",VeryThinSpace:"\u200A",Vfr:"\uD835\uDD19",Vopf:"\uD835\uDD4D",Vscr:"\uD835\uDCB1",Vvdash:"\u22AA",Wcirc:"\u0174",Wedge:"\u22C0",Wfr:"\uD835\uDD1A",Wopf:"\uD835\uDD4E",Wscr:"\uD835\uDCB2",Xfr:"\uD835\uDD1B",Xi:"\u039E",Xopf:"\uD835\uDD4F",Xscr:"\uD835\uDCB3",YAcy:"\u042F",YIcy:"\u0407",YUcy:"\u042E",Yacute:"\xDD",Ycirc:"\u0176",Ycy:"\u042B",Yfr:"\uD835\uDD1C",Yopf:"\uD835\uDD50",Yscr:"\uD835\uDCB4",Yuml:"\u0178",ZHcy:"\u0416",Zacute:"\u0179",Zcaron:"\u017D",Zcy:"\u0417",Zdot:"\u017B",ZeroWidthSpace:"\u200B",Zeta:"\u0396",Zfr:"\u2128",Zopf:"\u2124",Zscr:"\uD835\uDCB5",aacute:"\xE1",abreve:"\u0103",ac:"\u223E",acE:"\u223E\u0333",acd:"\u223F",acirc:"\xE2",acute:"\xB4",acy:"\u0430",aelig:"\xE6",af:"\u2061",afr:"\uD835\uDD1E",agrave:"\xE0",alefsym:"\u2135",aleph:"\u2135",alpha:"\u03B1",amacr:"\u0101",amalg:"\u2A3F",amp:"&",and:"\u2227",andand:"\u2A55",andd:"\u2A5C",andslope:"\u2A58",andv:"\u2A5A",ang:"\u2220",ange:"\u29A4",angle:"\u2220",angmsd:"\u2221",angmsdaa:"\u29A8",angmsdab:"\u29A9",angmsdac:"\u29AA",angmsdad:"\u29AB",angmsdae:"\u29AC",angmsdaf:"\u29AD",angmsdag:"\u29AE",angmsdah:"\u29AF",angrt:"\u221F",angrtvb:"\u22BE",angrtvbd:"\u299D",angsph:"\u2222",angst:"\xC5",angzarr:"\u237C",aogon:"\u0105",aopf:"\uD835\uDD52",ap:"\u2248",apE:"\u2A70",apacir:"\u2A6F",ape:"\u224A",apid:"\u224B",apos:"'",approx:"\u2248",approxeq:"\u224A",aring:"\xE5",ascr:"\uD835\uDCB6",ast:"*",asymp:"\u2248",asympeq:"\u224D",atilde:"\xE3",auml:"\xE4",awconint:"\u2233",awint:"\u2A11",bNot:"\u2AED",backcong:"\u224C",backepsilon:"\u03F6",backprime:"\u2035",backsim:"\u223D",backsimeq:"\u22CD",barvee:"\u22BD",barwed:"\u2305",barwedge:"\u2305",bbrk:"\u23B5",bbrktbrk:"\u23B6",bcong:"\u224C",bcy:"\u0431",bdquo:"\u201E",becaus:"\u2235",because:"\u2235",bemptyv:"\u29B0",bepsi:"\u03F6",bernou:"\u212C",beta:"\u03B2",beth:"\u2136",between:"\u226C",bfr:"\uD835\uDD1F",bigcap:"\u22C2",bigcirc:"\u25EF",bigcup:"\u22C3",bigodot:"\u2A00",bigoplus:"\u2A01",bigotimes:"\u2A02",bigsqcup:"\u2A06",bigstar:"\u2605",bigtriangledown:"\u25BD",bigtriangleup:"\u25B3",biguplus:"\u2A04",bigvee:"\u22C1",bigwedge:"\u22C0",bkarow:"\u290D",blacklozenge:"\u29EB",blacksquare:"\u25AA",blacktriangle:"\u25B4",blacktriangledown:"\u25BE",blacktriangleleft:"\u25C2",blacktriangleright:"\u25B8",blank:"\u2423",blk12:"\u2592",blk14:"\u2591",blk34:"\u2593",block:"\u2588",bne:"=\u20E5",bnequiv:"\u2261\u20E5",bnot:"\u2310",bopf:"\uD835\uDD53",bot:"\u22A5",bottom:"\u22A5",bowtie:"\u22C8",boxDL:"\u2557",boxDR:"\u2554",boxDl:"\u2556",boxDr:"\u2553",boxH:"\u2550",boxHD:"\u2566",boxHU:"\u2569",boxHd:"\u2564",boxHu:"\u2567",boxUL:"\u255D",boxUR:"\u255A",boxUl:"\u255C",boxUr:"\u2559",boxV:"\u2551",boxVH:"\u256C",boxVL:"\u2563",boxVR:"\u2560",boxVh:"\u256B",boxVl:"\u2562",boxVr:"\u255F",boxbox:"\u29C9",boxdL:"\u2555",boxdR:"\u2552",boxdl:"\u2510",boxdr:"\u250C",boxh:"\u2500",boxhD:"\u2565",boxhU:"\u2568",boxhd:"\u252C",boxhu:"\u2534",boxminus:"\u229F",boxplus:"\u229E",boxtimes:"\u22A0",boxuL:"\u255B",boxuR:"\u2558",boxul:"\u2518",boxur:"\u2514",boxv:"\u2502",boxvH:"\u256A",boxvL:"\u2561",boxvR:"\u255E",boxvh:"\u253C",boxvl:"\u2524",boxvr:"\u251C",bprime:"\u2035",breve:"\u02D8",brvbar:"\xA6",bscr:"\uD835\uDCB7",bsemi:"\u204F",bsim:"\u223D",bsime:"\u22CD",bsol:"\\",bsolb:"\u29C5",bsolhsub:"\u27C8",bull:"\u2022",bullet:"\u2022",bump:"\u224E",bumpE:"\u2AAE",bumpe:"\u224F",bumpeq:"\u224F",cacute:"\u0107",cap:"\u2229",capand:"\u2A44",capbrcup:"\u2A49",capcap:"\u2A4B",capcup:"\u2A47",capdot:"\u2A40",caps:"\u2229\uFE00",caret:"\u2041",caron:"\u02C7",ccaps:"\u2A4D",ccaron:"\u010D",ccedil:"\xE7",ccirc:"\u0109",ccups:"\u2A4C",ccupssm:"\u2A50",cdot:"\u010B",cedil:"\xB8",cemptyv:"\u29B2",cent:"\xA2",centerdot:"\xB7",cfr:"\uD835\uDD20",chcy:"\u0447",check:"\u2713",checkmark:"\u2713",chi:"\u03C7",cir:"\u25CB",cirE:"\u29C3",circ:"\u02C6",circeq:"\u2257",circlearrowleft:"\u21BA",circlearrowright:"\u21BB",circledR:"\xAE",circledS:"\u24C8",circledast:"\u229B",circledcirc:"\u229A",circleddash:"\u229D",cire:"\u2257",cirfnint:"\u2A10",cirmid:"\u2AEF",cirscir:"\u29C2",clubs:"\u2663",clubsuit:"\u2663",colon:":",colone:"\u2254",coloneq:"\u2254",comma:",",commat:"@",comp:"\u2201",compfn:"\u2218",complement:"\u2201",complexes:"\u2102",cong:"\u2245",congdot:"\u2A6D",conint:"\u222E",copf:"\uD835\uDD54",coprod:"\u2210",copy:"\xA9",copysr:"\u2117",crarr:"\u21B5",cross:"\u2717",cscr:"\uD835\uDCB8",csub:"\u2ACF",csube:"\u2AD1",csup:"\u2AD0",csupe:"\u2AD2",ctdot:"\u22EF",cudarrl:"\u2938",cudarrr:"\u2935",cuepr:"\u22DE",cuesc:"\u22DF",cularr:"\u21B6",cularrp:"\u293D",cup:"\u222A",cupbrcap:"\u2A48",cupcap:"\u2A46",cupcup:"\u2A4A",cupdot:"\u228D",cupor:"\u2A45",cups:"\u222A\uFE00",curarr:"\u21B7",curarrm:"\u293C",curlyeqprec:"\u22DE",curlyeqsucc:"\u22DF",curlyvee:"\u22CE",curlywedge:"\u22CF",curren:"\xA4",curvearrowleft:"\u21B6",curvearrowright:"\u21B7",cuvee:"\u22CE",cuwed:"\u22CF",cwconint:"\u2232",cwint:"\u2231",cylcty:"\u232D",dArr:"\u21D3",dHar:"\u2965",dagger:"\u2020",daleth:"\u2138",darr:"\u2193",dash:"\u2010",dashv:"\u22A3",dbkarow:"\u290F",dblac:"\u02DD",dcaron:"\u010F",dcy:"\u0434",dd:"\u2146",ddagger:"\u2021",ddarr:"\u21CA",ddotseq:"\u2A77",deg:"\xB0",delta:"\u03B4",demptyv:"\u29B1",dfisht:"\u297F",dfr:"\uD835\uDD21",dharl:"\u21C3",dharr:"\u21C2",diam:"\u22C4",diamond:"\u22C4",diamondsuit:"\u2666",diams:"\u2666",die:"\xA8",digamma:"\u03DD",disin:"\u22F2",div:"\xF7",divide:"\xF7",divideontimes:"\u22C7",divonx:"\u22C7",djcy:"\u0452",dlcorn:"\u231E",dlcrop:"\u230D",dollar:"$",dopf:"\uD835\uDD55",dot:"\u02D9",doteq:"\u2250",doteqdot:"\u2251",dotminus:"\u2238",dotplus:"\u2214",dotsquare:"\u22A1",doublebarwedge:"\u2306",downarrow:"\u2193",downdownarrows:"\u21CA",downharpoonleft:"\u21C3",downharpoonright:"\u21C2",drbkarow:"\u2910",drcorn:"\u231F",drcrop:"\u230C",dscr:"\uD835\uDCB9",dscy:"\u0455",dsol:"\u29F6",dstrok:"\u0111",dtdot:"\u22F1",dtri:"\u25BF",dtrif:"\u25BE",duarr:"\u21F5",duhar:"\u296F",dwangle:"\u29A6",dzcy:"\u045F",dzigrarr:"\u27FF",eDDot:"\u2A77",eDot:"\u2251",eacute:"\xE9",easter:"\u2A6E",ecaron:"\u011B",ecir:"\u2256",ecirc:"\xEA",ecolon:"\u2255",ecy:"\u044D",edot:"\u0117",ee:"\u2147",efDot:"\u2252",efr:"\uD835\uDD22",eg:"\u2A9A",egrave:"\xE8",egs:"\u2A96",egsdot:"\u2A98",el:"\u2A99",elinters:"\u23E7",ell:"\u2113",els:"\u2A95",elsdot:"\u2A97",emacr:"\u0113",empty:"\u2205",emptyset:"\u2205",emptyv:"\u2205",emsp13:"\u2004",emsp14:"\u2005",emsp:"\u2003",eng:"\u014B",ensp:"\u2002",eogon:"\u0119",eopf:"\uD835\uDD56",epar:"\u22D5",eparsl:"\u29E3",eplus:"\u2A71",epsi:"\u03B5",epsilon:"\u03B5",epsiv:"\u03F5",eqcirc:"\u2256",eqcolon:"\u2255",eqsim:"\u2242",eqslantgtr:"\u2A96",eqslantless:"\u2A95",equals:"=",equest:"\u225F",equiv:"\u2261",equivDD:"\u2A78",eqvparsl:"\u29E5",erDot:"\u2253",erarr:"\u2971",escr:"\u212F",esdot:"\u2250",esim:"\u2242",eta:"\u03B7",eth:"\xF0",euml:"\xEB",euro:"\u20AC",excl:"!",exist:"\u2203",expectation:"\u2130",exponentiale:"\u2147",fallingdotseq:"\u2252",fcy:"\u0444",female:"\u2640",ffilig:"\uFB03",fflig:"\uFB00",ffllig:"\uFB04",ffr:"\uD835\uDD23",filig:"\uFB01",fjlig:"fj",flat:"\u266D",fllig:"\uFB02",fltns:"\u25B1",fnof:"\u0192",fopf:"\uD835\uDD57",forall:"\u2200",fork:"\u22D4",forkv:"\u2AD9",fpartint:"\u2A0D",frac12:"\xBD",frac13:"\u2153",frac14:"\xBC",frac15:"\u2155",frac16:"\u2159",frac18:"\u215B",frac23:"\u2154",frac25:"\u2156",frac34:"\xBE",frac35:"\u2157",frac38:"\u215C",frac45:"\u2158",frac56:"\u215A",frac58:"\u215D",frac78:"\u215E",frasl:"\u2044",frown:"\u2322",fscr:"\uD835\uDCBB",gE:"\u2267",gEl:"\u2A8C",gacute:"\u01F5",gamma:"\u03B3",gammad:"\u03DD",gap:"\u2A86",gbreve:"\u011F",gcirc:"\u011D",gcy:"\u0433",gdot:"\u0121",ge:"\u2265",gel:"\u22DB",geq:"\u2265",geqq:"\u2267",geqslant:"\u2A7E",ges:"\u2A7E",gescc:"\u2AA9",gesdot:"\u2A80",gesdoto:"\u2A82",gesdotol:"\u2A84",gesl:"\u22DB\uFE00",gesles:"\u2A94",gfr:"\uD835\uDD24",gg:"\u226B",ggg:"\u22D9",gimel:"\u2137",gjcy:"\u0453",gl:"\u2277",glE:"\u2A92",gla:"\u2AA5",glj:"\u2AA4",gnE:"\u2269",gnap:"\u2A8A",gnapprox:"\u2A8A",gne:"\u2A88",gneq:"\u2A88",gneqq:"\u2269",gnsim:"\u22E7",gopf:"\uD835\uDD58",grave:"`",gscr:"\u210A",gsim:"\u2273",gsime:"\u2A8E",gsiml:"\u2A90",gt:">",gtcc:"\u2AA7",gtcir:"\u2A7A",gtdot:"\u22D7",gtlPar:"\u2995",gtquest:"\u2A7C",gtrapprox:"\u2A86",gtrarr:"\u2978",gtrdot:"\u22D7",gtreqless:"\u22DB",gtreqqless:"\u2A8C",gtrless:"\u2277",gtrsim:"\u2273",gvertneqq:"\u2269\uFE00",gvnE:"\u2269\uFE00",hArr:"\u21D4",hairsp:"\u200A",half:"\xBD",hamilt:"\u210B",hardcy:"\u044A",harr:"\u2194",harrcir:"\u2948",harrw:"\u21AD",hbar:"\u210F",hcirc:"\u0125",hearts:"\u2665",heartsuit:"\u2665",hellip:"\u2026",hercon:"\u22B9",hfr:"\uD835\uDD25",hksearow:"\u2925",hkswarow:"\u2926",hoarr:"\u21FF",homtht:"\u223B",hookleftarrow:"\u21A9",hookrightarrow:"\u21AA",hopf:"\uD835\uDD59",horbar:"\u2015",hscr:"\uD835\uDCBD",hslash:"\u210F",hstrok:"\u0127",hybull:"\u2043",hyphen:"\u2010",iacute:"\xED",ic:"\u2063",icirc:"\xEE",icy:"\u0438",iecy:"\u0435",iexcl:"\xA1",iff:"\u21D4",ifr:"\uD835\uDD26",igrave:"\xEC",ii:"\u2148",iiiint:"\u2A0C",iiint:"\u222D",iinfin:"\u29DC",iiota:"\u2129",ijlig:"\u0133",imacr:"\u012B",image:"\u2111",imagline:"\u2110",imagpart:"\u2111",imath:"\u0131",imof:"\u22B7",imped:"\u01B5",in:"\u2208",incare:"\u2105",infin:"\u221E",infintie:"\u29DD",inodot:"\u0131",int:"\u222B",intcal:"\u22BA",integers:"\u2124",intercal:"\u22BA",intlarhk:"\u2A17",intprod:"\u2A3C",iocy:"\u0451",iogon:"\u012F",iopf:"\uD835\uDD5A",iota:"\u03B9",iprod:"\u2A3C",iquest:"\xBF",iscr:"\uD835\uDCBE",isin:"\u2208",isinE:"\u22F9",isindot:"\u22F5",isins:"\u22F4",isinsv:"\u22F3",isinv:"\u2208",it:"\u2062",itilde:"\u0129",iukcy:"\u0456",iuml:"\xEF",jcirc:"\u0135",jcy:"\u0439",jfr:"\uD835\uDD27",jmath:"\u0237",jopf:"\uD835\uDD5B",jscr:"\uD835\uDCBF",jsercy:"\u0458",jukcy:"\u0454",kappa:"\u03BA",kappav:"\u03F0",kcedil:"\u0137",kcy:"\u043A",kfr:"\uD835\uDD28",kgreen:"\u0138",khcy:"\u0445",kjcy:"\u045C",kopf:"\uD835\uDD5C",kscr:"\uD835\uDCC0",lAarr:"\u21DA",lArr:"\u21D0",lAtail:"\u291B",lBarr:"\u290E",lE:"\u2266",lEg:"\u2A8B",lHar:"\u2962",lacute:"\u013A",laemptyv:"\u29B4",lagran:"\u2112",lambda:"\u03BB",lang:"\u27E8",langd:"\u2991",langle:"\u27E8",lap:"\u2A85",laquo:"\xAB",larr:"\u2190",larrb:"\u21E4",larrbfs:"\u291F",larrfs:"\u291D",larrhk:"\u21A9",larrlp:"\u21AB",larrpl:"\u2939",larrsim:"\u2973",larrtl:"\u21A2",lat:"\u2AAB",latail:"\u2919",late:"\u2AAD",lates:"\u2AAD\uFE00",lbarr:"\u290C",lbbrk:"\u2772",lbrace:"{",lbrack:"[",lbrke:"\u298B",lbrksld:"\u298F",lbrkslu:"\u298D",lcaron:"\u013E",lcedil:"\u013C",lceil:"\u2308",lcub:"{",lcy:"\u043B",ldca:"\u2936",ldquo:"\u201C",ldquor:"\u201E",ldrdhar:"\u2967",ldrushar:"\u294B",ldsh:"\u21B2",le:"\u2264",leftarrow:"\u2190",leftarrowtail:"\u21A2",leftharpoondown:"\u21BD",leftharpoonup:"\u21BC",leftleftarrows:"\u21C7",leftrightarrow:"\u2194",leftrightarrows:"\u21C6",leftrightharpoons:"\u21CB",leftrightsquigarrow:"\u21AD",leftthreetimes:"\u22CB",leg:"\u22DA",leq:"\u2264",leqq:"\u2266",leqslant:"\u2A7D",les:"\u2A7D",lescc:"\u2AA8",lesdot:"\u2A7F",lesdoto:"\u2A81",lesdotor:"\u2A83",lesg:"\u22DA\uFE00",lesges:"\u2A93",lessapprox:"\u2A85",lessdot:"\u22D6",lesseqgtr:"\u22DA",lesseqqgtr:"\u2A8B",lessgtr:"\u2276",lesssim:"\u2272",lfisht:"\u297C",lfloor:"\u230A",lfr:"\uD835\uDD29",lg:"\u2276",lgE:"\u2A91",lhard:"\u21BD",lharu:"\u21BC",lharul:"\u296A",lhblk:"\u2584",ljcy:"\u0459",ll:"\u226A",llarr:"\u21C7",llcorner:"\u231E",llhard:"\u296B",lltri:"\u25FA",lmidot:"\u0140",lmoust:"\u23B0",lmoustache:"\u23B0",lnE:"\u2268",lnap:"\u2A89",lnapprox:"\u2A89",lne:"\u2A87",lneq:"\u2A87",lneqq:"\u2268",lnsim:"\u22E6",loang:"\u27EC",loarr:"\u21FD",lobrk:"\u27E6",longleftarrow:"\u27F5",longleftrightarrow:"\u27F7",longmapsto:"\u27FC",longrightarrow:"\u27F6",looparrowleft:"\u21AB",looparrowright:"\u21AC",lopar:"\u2985",lopf:"\uD835\uDD5D",loplus:"\u2A2D",lotimes:"\u2A34",lowast:"\u2217",lowbar:"_",loz:"\u25CA",lozenge:"\u25CA",lozf:"\u29EB",lpar:"(",lparlt:"\u2993",lrarr:"\u21C6",lrcorner:"\u231F",lrhar:"\u21CB",lrhard:"\u296D",lrm:"\u200E",lrtri:"\u22BF",lsaquo:"\u2039",lscr:"\uD835\uDCC1",lsh:"\u21B0",lsim:"\u2272",lsime:"\u2A8D",lsimg:"\u2A8F",lsqb:"[",lsquo:"\u2018",lsquor:"\u201A",lstrok:"\u0142",lt:"<",ltcc:"\u2AA6",ltcir:"\u2A79",ltdot:"\u22D6",lthree:"\u22CB",ltimes:"\u22C9",ltlarr:"\u2976",ltquest:"\u2A7B",ltrPar:"\u2996",ltri:"\u25C3",ltrie:"\u22B4",ltrif:"\u25C2",lurdshar:"\u294A",luruhar:"\u2966",lvertneqq:"\u2268\uFE00",lvnE:"\u2268\uFE00",mDDot:"\u223A",macr:"\xAF",male:"\u2642",malt:"\u2720",maltese:"\u2720",map:"\u21A6",mapsto:"\u21A6",mapstodown:"\u21A7",mapstoleft:"\u21A4",mapstoup:"\u21A5",marker:"\u25AE",mcomma:"\u2A29",mcy:"\u043C",mdash:"\u2014",measuredangle:"\u2221",mfr:"\uD835\uDD2A",mho:"\u2127",micro:"\xB5",mid:"\u2223",midast:"*",midcir:"\u2AF0",middot:"\xB7",minus:"\u2212",minusb:"\u229F",minusd:"\u2238",minusdu:"\u2A2A",mlcp:"\u2ADB",mldr:"\u2026",mnplus:"\u2213",models:"\u22A7",mopf:"\uD835\uDD5E",mp:"\u2213",mscr:"\uD835\uDCC2",mstpos:"\u223E",mu:"\u03BC",multimap:"\u22B8",mumap:"\u22B8",nGg:"\u22D9\u0338",nGt:"\u226B\u20D2",nGtv:"\u226B\u0338",nLeftarrow:"\u21CD",nLeftrightarrow:"\u21CE",nLl:"\u22D8\u0338",nLt:"\u226A\u20D2",nLtv:"\u226A\u0338",nRightarrow:"\u21CF",nVDash:"\u22AF",nVdash:"\u22AE",nabla:"\u2207",nacute:"\u0144",nang:"\u2220\u20D2",nap:"\u2249",napE:"\u2A70\u0338",napid:"\u224B\u0338",napos:"\u0149",napprox:"\u2249",natur:"\u266E",natural:"\u266E",naturals:"\u2115",nbsp:"\xA0",nbump:"\u224E\u0338",nbumpe:"\u224F\u0338",ncap:"\u2A43",ncaron:"\u0148",ncedil:"\u0146",ncong:"\u2247",ncongdot:"\u2A6D\u0338",ncup:"\u2A42",ncy:"\u043D",ndash:"\u2013",ne:"\u2260",neArr:"\u21D7",nearhk:"\u2924",nearr:"\u2197",nearrow:"\u2197",nedot:"\u2250\u0338",nequiv:"\u2262",nesear:"\u2928",nesim:"\u2242\u0338",nexist:"\u2204",nexists:"\u2204",nfr:"\uD835\uDD2B",ngE:"\u2267\u0338",nge:"\u2271",ngeq:"\u2271",ngeqq:"\u2267\u0338",ngeqslant:"\u2A7E\u0338",nges:"\u2A7E\u0338",ngsim:"\u2275",ngt:"\u226F",ngtr:"\u226F",nhArr:"\u21CE",nharr:"\u21AE",nhpar:"\u2AF2",ni:"\u220B",nis:"\u22FC",nisd:"\u22FA",niv:"\u220B",njcy:"\u045A",nlArr:"\u21CD",nlE:"\u2266\u0338",nlarr:"\u219A",nldr:"\u2025",nle:"\u2270",nleftarrow:"\u219A",nleftrightarrow:"\u21AE",nleq:"\u2270",nleqq:"\u2266\u0338",nleqslant:"\u2A7D\u0338",nles:"\u2A7D\u0338",nless:"\u226E",nlsim:"\u2274",nlt:"\u226E",nltri:"\u22EA",nltrie:"\u22EC",nmid:"\u2224",nopf:"\uD835\uDD5F",not:"\xAC",notin:"\u2209",notinE:"\u22F9\u0338",notindot:"\u22F5\u0338",notinva:"\u2209",notinvb:"\u22F7",notinvc:"\u22F6",notni:"\u220C",notniva:"\u220C",notnivb:"\u22FE",notnivc:"\u22FD",npar:"\u2226",nparallel:"\u2226",nparsl:"\u2AFD\u20E5",npart:"\u2202\u0338",npolint:"\u2A14",npr:"\u2280",nprcue:"\u22E0",npre:"\u2AAF\u0338",nprec:"\u2280",npreceq:"\u2AAF\u0338",nrArr:"\u21CF",nrarr:"\u219B",nrarrc:"\u2933\u0338",nrarrw:"\u219D\u0338",nrightarrow:"\u219B",nrtri:"\u22EB",nrtrie:"\u22ED",nsc:"\u2281",nsccue:"\u22E1",nsce:"\u2AB0\u0338",nscr:"\uD835\uDCC3",nshortmid:"\u2224",nshortparallel:"\u2226",nsim:"\u2241",nsime:"\u2244",nsimeq:"\u2244",nsmid:"\u2224",nspar:"\u2226",nsqsube:"\u22E2",nsqsupe:"\u22E3",nsub:"\u2284",nsubE:"\u2AC5\u0338",nsube:"\u2288",nsubset:"\u2282\u20D2",nsubseteq:"\u2288",nsubseteqq:"\u2AC5\u0338",nsucc:"\u2281",nsucceq:"\u2AB0\u0338",nsup:"\u2285",nsupE:"\u2AC6\u0338",nsupe:"\u2289",nsupset:"\u2283\u20D2",nsupseteq:"\u2289",nsupseteqq:"\u2AC6\u0338",ntgl:"\u2279",ntilde:"\xF1",ntlg:"\u2278",ntriangleleft:"\u22EA",ntrianglelefteq:"\u22EC",ntriangleright:"\u22EB",ntrianglerighteq:"\u22ED",nu:"\u03BD",num:"#",numero:"\u2116",numsp:"\u2007",nvDash:"\u22AD",nvHarr:"\u2904",nvap:"\u224D\u20D2",nvdash:"\u22AC",nvge:"\u2265\u20D2",nvgt:">\u20D2",nvinfin:"\u29DE",nvlArr:"\u2902",nvle:"\u2264\u20D2",nvlt:"<\u20D2",nvltrie:"\u22B4\u20D2",nvrArr:"\u2903",nvrtrie:"\u22B5\u20D2",nvsim:"\u223C\u20D2",nwArr:"\u21D6",nwarhk:"\u2923",nwarr:"\u2196",nwarrow:"\u2196",nwnear:"\u2927",oS:"\u24C8",oacute:"\xF3",oast:"\u229B",ocir:"\u229A",ocirc:"\xF4",ocy:"\u043E",odash:"\u229D",odblac:"\u0151",odiv:"\u2A38",odot:"\u2299",odsold:"\u29BC",oelig:"\u0153",ofcir:"\u29BF",ofr:"\uD835\uDD2C",ogon:"\u02DB",ograve:"\xF2",ogt:"\u29C1",ohbar:"\u29B5",ohm:"\u03A9",oint:"\u222E",olarr:"\u21BA",olcir:"\u29BE",olcross:"\u29BB",oline:"\u203E",olt:"\u29C0",omacr:"\u014D",omega:"\u03C9",omicron:"\u03BF",omid:"\u29B6",ominus:"\u2296",oopf:"\uD835\uDD60",opar:"\u29B7",operp:"\u29B9",oplus:"\u2295",or:"\u2228",orarr:"\u21BB",ord:"\u2A5D",order:"\u2134",orderof:"\u2134",ordf:"\xAA",ordm:"\xBA",origof:"\u22B6",oror:"\u2A56",orslope:"\u2A57",orv:"\u2A5B",oscr:"\u2134",oslash:"\xF8",osol:"\u2298",otilde:"\xF5",otimes:"\u2297",otimesas:"\u2A36",ouml:"\xF6",ovbar:"\u233D",par:"\u2225",para:"\xB6",parallel:"\u2225",parsim:"\u2AF3",parsl:"\u2AFD",part:"\u2202",pcy:"\u043F",percnt:"%",period:".",permil:"\u2030",perp:"\u22A5",pertenk:"\u2031",pfr:"\uD835\uDD2D",phi:"\u03C6",phiv:"\u03D5",phmmat:"\u2133",phone:"\u260E",pi:"\u03C0",pitchfork:"\u22D4",piv:"\u03D6",planck:"\u210F",planckh:"\u210E",plankv:"\u210F",plus:"+",plusacir:"\u2A23",plusb:"\u229E",pluscir:"\u2A22",plusdo:"\u2214",plusdu:"\u2A25",pluse:"\u2A72",plusmn:"\xB1",plussim:"\u2A26",plustwo:"\u2A27",pm:"\xB1",pointint:"\u2A15",popf:"\uD835\uDD61",pound:"\xA3",pr:"\u227A",prE:"\u2AB3",prap:"\u2AB7",prcue:"\u227C",pre:"\u2AAF",prec:"\u227A",precapprox:"\u2AB7",preccurlyeq:"\u227C",preceq:"\u2AAF",precnapprox:"\u2AB9",precneqq:"\u2AB5",precnsim:"\u22E8",precsim:"\u227E",prime:"\u2032",primes:"\u2119",prnE:"\u2AB5",prnap:"\u2AB9",prnsim:"\u22E8",prod:"\u220F",profalar:"\u232E",profline:"\u2312",profsurf:"\u2313",prop:"\u221D",propto:"\u221D",prsim:"\u227E",prurel:"\u22B0",pscr:"\uD835\uDCC5",psi:"\u03C8",puncsp:"\u2008",qfr:"\uD835\uDD2E",qint:"\u2A0C",qopf:"\uD835\uDD62",qprime:"\u2057",qscr:"\uD835\uDCC6",quaternions:"\u210D",quatint:"\u2A16",quest:"?",questeq:"\u225F",quot:'"',rAarr:"\u21DB",rArr:"\u21D2",rAtail:"\u291C",rBarr:"\u290F",rHar:"\u2964",race:"\u223D\u0331",racute:"\u0155",radic:"\u221A",raemptyv:"\u29B3",rang:"\u27E9",rangd:"\u2992",range:"\u29A5",rangle:"\u27E9",raquo:"\xBB",rarr:"\u2192",rarrap:"\u2975",rarrb:"\u21E5",rarrbfs:"\u2920",rarrc:"\u2933",rarrfs:"\u291E",rarrhk:"\u21AA",rarrlp:"\u21AC",rarrpl:"\u2945",rarrsim:"\u2974",rarrtl:"\u21A3",rarrw:"\u219D",ratail:"\u291A",ratio:"\u2236",rationals:"\u211A",rbarr:"\u290D",rbbrk:"\u2773",rbrace:"}",rbrack:"]",rbrke:"\u298C",rbrksld:"\u298E",rbrkslu:"\u2990",rcaron:"\u0159",rcedil:"\u0157",rceil:"\u2309",rcub:"}",rcy:"\u0440",rdca:"\u2937",rdldhar:"\u2969",rdquo:"\u201D",rdquor:"\u201D",rdsh:"\u21B3",real:"\u211C",realine:"\u211B",realpart:"\u211C",reals:"\u211D",rect:"\u25AD",reg:"\xAE",rfisht:"\u297D",rfloor:"\u230B",rfr:"\uD835\uDD2F",rhard:"\u21C1",rharu:"\u21C0",rharul:"\u296C",rho:"\u03C1",rhov:"\u03F1",rightarrow:"\u2192",rightarrowtail:"\u21A3",rightharpoondown:"\u21C1",rightharpoonup:"\u21C0",rightleftarrows:"\u21C4",rightleftharpoons:"\u21CC",rightrightarrows:"\u21C9",rightsquigarrow:"\u219D",rightthreetimes:"\u22CC",ring:"\u02DA",risingdotseq:"\u2253",rlarr:"\u21C4",rlhar:"\u21CC",rlm:"\u200F",rmoust:"\u23B1",rmoustache:"\u23B1",rnmid:"\u2AEE",roang:"\u27ED",roarr:"\u21FE",robrk:"\u27E7",ropar:"\u2986",ropf:"\uD835\uDD63",roplus:"\u2A2E",rotimes:"\u2A35",rpar:")",rpargt:"\u2994",rppolint:"\u2A12",rrarr:"\u21C9",rsaquo:"\u203A",rscr:"\uD835\uDCC7",rsh:"\u21B1",rsqb:"]",rsquo:"\u2019",rsquor:"\u2019",rthree:"\u22CC",rtimes:"\u22CA",rtri:"\u25B9",rtrie:"\u22B5",rtrif:"\u25B8",rtriltri:"\u29CE",ruluhar:"\u2968",rx:"\u211E",sacute:"\u015B",sbquo:"\u201A",sc:"\u227B",scE:"\u2AB4",scap:"\u2AB8",scaron:"\u0161",sccue:"\u227D",sce:"\u2AB0",scedil:"\u015F",scirc:"\u015D",scnE:"\u2AB6",scnap:"\u2ABA",scnsim:"\u22E9",scpolint:"\u2A13",scsim:"\u227F",scy:"\u0441",sdot:"\u22C5",sdotb:"\u22A1",sdote:"\u2A66",seArr:"\u21D8",searhk:"\u2925",searr:"\u2198",searrow:"\u2198",sect:"\xA7",semi:";",seswar:"\u2929",setminus:"\u2216",setmn:"\u2216",sext:"\u2736",sfr:"\uD835\uDD30",sfrown:"\u2322",sharp:"\u266F",shchcy:"\u0449",shcy:"\u0448",shortmid:"\u2223",shortparallel:"\u2225",shy:"\xAD",sigma:"\u03C3",sigmaf:"\u03C2",sigmav:"\u03C2",sim:"\u223C",simdot:"\u2A6A",sime:"\u2243",simeq:"\u2243",simg:"\u2A9E",simgE:"\u2AA0",siml:"\u2A9D",simlE:"\u2A9F",simne:"\u2246",simplus:"\u2A24",simrarr:"\u2972",slarr:"\u2190",smallsetminus:"\u2216",smashp:"\u2A33",smeparsl:"\u29E4",smid:"\u2223",smile:"\u2323",smt:"\u2AAA",smte:"\u2AAC",smtes:"\u2AAC\uFE00",softcy:"\u044C",sol:"/",solb:"\u29C4",solbar:"\u233F",sopf:"\uD835\uDD64",spades:"\u2660",spadesuit:"\u2660",spar:"\u2225",sqcap:"\u2293",sqcaps:"\u2293\uFE00",sqcup:"\u2294",sqcups:"\u2294\uFE00",sqsub:"\u228F",sqsube:"\u2291",sqsubset:"\u228F",sqsubseteq:"\u2291",sqsup:"\u2290",sqsupe:"\u2292",sqsupset:"\u2290",sqsupseteq:"\u2292",squ:"\u25A1",square:"\u25A1",squarf:"\u25AA",squf:"\u25AA",srarr:"\u2192",sscr:"\uD835\uDCC8",ssetmn:"\u2216",ssmile:"\u2323",sstarf:"\u22C6",star:"\u2606",starf:"\u2605",straightepsilon:"\u03F5",straightphi:"\u03D5",strns:"\xAF",sub:"\u2282",subE:"\u2AC5",subdot:"\u2ABD",sube:"\u2286",subedot:"\u2AC3",submult:"\u2AC1",subnE:"\u2ACB",subne:"\u228A",subplus:"\u2ABF",subrarr:"\u2979",subset:"\u2282",subseteq:"\u2286",subseteqq:"\u2AC5",subsetneq:"\u228A",subsetneqq:"\u2ACB",subsim:"\u2AC7",subsub:"\u2AD5",subsup:"\u2AD3",succ:"\u227B",succapprox:"\u2AB8",succcurlyeq:"\u227D",succeq:"\u2AB0",succnapprox:"\u2ABA",succneqq:"\u2AB6",succnsim:"\u22E9",succsim:"\u227F",sum:"\u2211",sung:"\u266A",sup1:"\xB9",sup2:"\xB2",sup3:"\xB3",sup:"\u2283",supE:"\u2AC6",supdot:"\u2ABE",supdsub:"\u2AD8",supe:"\u2287",supedot:"\u2AC4",suphsol:"\u27C9",suphsub:"\u2AD7",suplarr:"\u297B",supmult:"\u2AC2",supnE:"\u2ACC",supne:"\u228B",supplus:"\u2AC0",supset:"\u2283",supseteq:"\u2287",supseteqq:"\u2AC6",supsetneq:"\u228B",supsetneqq:"\u2ACC",supsim:"\u2AC8",supsub:"\u2AD4",supsup:"\u2AD6",swArr:"\u21D9",swarhk:"\u2926",swarr:"\u2199",swarrow:"\u2199",swnwar:"\u292A",szlig:"\xDF",target:"\u2316",tau:"\u03C4",tbrk:"\u23B4",tcaron:"\u0165",tcedil:"\u0163",tcy:"\u0442",tdot:"\u20DB",telrec:"\u2315",tfr:"\uD835\uDD31",there4:"\u2234",therefore:"\u2234",theta:"\u03B8",thetasym:"\u03D1",thetav:"\u03D1",thickapprox:"\u2248",thicksim:"\u223C",thinsp:"\u2009",thkap:"\u2248",thksim:"\u223C",thorn:"\xFE",tilde:"\u02DC",times:"\xD7",timesb:"\u22A0",timesbar:"\u2A31",timesd:"\u2A30",tint:"\u222D",toea:"\u2928",top:"\u22A4",topbot:"\u2336",topcir:"\u2AF1",topf:"\uD835\uDD65",topfork:"\u2ADA",tosa:"\u2929",tprime:"\u2034",trade:"\u2122",triangle:"\u25B5",triangledown:"\u25BF",triangleleft:"\u25C3",trianglelefteq:"\u22B4",triangleq:"\u225C",triangleright:"\u25B9",trianglerighteq:"\u22B5",tridot:"\u25EC",trie:"\u225C",triminus:"\u2A3A",triplus:"\u2A39",trisb:"\u29CD",tritime:"\u2A3B",trpezium:"\u23E2",tscr:"\uD835\uDCC9",tscy:"\u0446",tshcy:"\u045B",tstrok:"\u0167",twixt:"\u226C",twoheadleftarrow:"\u219E",twoheadrightarrow:"\u21A0",uArr:"\u21D1",uHar:"\u2963",uacute:"\xFA",uarr:"\u2191",ubrcy:"\u045E",ubreve:"\u016D",ucirc:"\xFB",ucy:"\u0443",udarr:"\u21C5",udblac:"\u0171",udhar:"\u296E",ufisht:"\u297E",ufr:"\uD835\uDD32",ugrave:"\xF9",uharl:"\u21BF",uharr:"\u21BE",uhblk:"\u2580",ulcorn:"\u231C",ulcorner:"\u231C",ulcrop:"\u230F",ultri:"\u25F8",umacr:"\u016B",uml:"\xA8",uogon:"\u0173",uopf:"\uD835\uDD66",uparrow:"\u2191",updownarrow:"\u2195",upharpoonleft:"\u21BF",upharpoonright:"\u21BE",uplus:"\u228E",upsi:"\u03C5",upsih:"\u03D2",upsilon:"\u03C5",upuparrows:"\u21C8",urcorn:"\u231D",urcorner:"\u231D",urcrop:"\u230E",uring:"\u016F",urtri:"\u25F9",uscr:"\uD835\uDCCA",utdot:"\u22F0",utilde:"\u0169",utri:"\u25B5",utrif:"\u25B4",uuarr:"\u21C8",uuml:"\xFC",uwangle:"\u29A7",vArr:"\u21D5",vBar:"\u2AE8",vBarv:"\u2AE9",vDash:"\u22A8",vangrt:"\u299C",varepsilon:"\u03F5",varkappa:"\u03F0",varnothing:"\u2205",varphi:"\u03D5",varpi:"\u03D6",varpropto:"\u221D",varr:"\u2195",varrho:"\u03F1",varsigma:"\u03C2",varsubsetneq:"\u228A\uFE00",varsubsetneqq:"\u2ACB\uFE00",varsupsetneq:"\u228B\uFE00",varsupsetneqq:"\u2ACC\uFE00",vartheta:"\u03D1",vartriangleleft:"\u22B2",vartriangleright:"\u22B3",vcy:"\u0432",vdash:"\u22A2",vee:"\u2228",veebar:"\u22BB",veeeq:"\u225A",vellip:"\u22EE",verbar:"|",vert:"|",vfr:"\uD835\uDD33",vltri:"\u22B2",vnsub:"\u2282\u20D2",vnsup:"\u2283\u20D2",vopf:"\uD835\uDD67",vprop:"\u221D",vrtri:"\u22B3",vscr:"\uD835\uDCCB",vsubnE:"\u2ACB\uFE00",vsubne:"\u228A\uFE00",vsupnE:"\u2ACC\uFE00",vsupne:"\u228B\uFE00",vzigzag:"\u299A",wcirc:"\u0175",wedbar:"\u2A5F",wedge:"\u2227",wedgeq:"\u2259",weierp:"\u2118",wfr:"\uD835\uDD34",wopf:"\uD835\uDD68",wp:"\u2118",wr:"\u2240",wreath:"\u2240",wscr:"\uD835\uDCCC",xcap:"\u22C2",xcirc:"\u25EF",xcup:"\u22C3",xdtri:"\u25BD",xfr:"\uD835\uDD35",xhArr:"\u27FA",xharr:"\u27F7",xi:"\u03BE",xlArr:"\u27F8",xlarr:"\u27F5",xmap:"\u27FC",xnis:"\u22FB",xodot:"\u2A00",xopf:"\uD835\uDD69",xoplus:"\u2A01",xotime:"\u2A02",xrArr:"\u27F9",xrarr:"\u27F6",xscr:"\uD835\uDCCD",xsqcup:"\u2A06",xuplus:"\u2A04",xutri:"\u25B3",xvee:"\u22C1",xwedge:"\u22C0",yacute:"\xFD",yacy:"\u044F",ycirc:"\u0177",ycy:"\u044B",yen:"\xA5",yfr:"\uD835\uDD36",yicy:"\u0457",yopf:"\uD835\uDD6A",yscr:"\uD835\uDCCE",yucy:"\u044E",yuml:"\xFF",zacute:"\u017A",zcaron:"\u017E",zcy:"\u0437",zdot:"\u017C",zeetrf:"\u2128",zeta:"\u03B6",zfr:"\uD835\uDD37",zhcy:"\u0436",zigrarr:"\u21DD",zopf:"\uD835\uDD6B",zscr:"\uD835\uDCCF",zwj:"\u200D",zwnj:"\u200C"};var JW={}.hasOwnProperty;function I0(q){return JW.call(jJ,q)?jJ[q]:!1}var K={carriageReturn:-5,lineFeed:-4,carriageReturnLineFeed:-3,horizontalTab:-2,virtualSpace:-1,eof:null,nul:0,soh:1,stx:2,etx:3,eot:4,enq:5,ack:6,bel:7,bs:8,ht:9,lf:10,vt:11,ff:12,cr:13,so:14,si:15,dle:16,dc1:17,dc2:18,dc3:19,dc4:20,nak:21,syn:22,etb:23,can:24,em:25,sub:26,esc:27,fs:28,gs:29,rs:30,us:31,space:32,exclamationMark:33,quotationMark:34,numberSign:35,dollarSign:36,percentSign:37,ampersand:38,apostrophe:39,leftParenthesis:40,rightParenthesis:41,asterisk:42,plusSign:43,comma:44,dash:45,dot:46,slash:47,digit0:48,digit1:49,digit2:50,digit3:51,digit4:52,digit5:53,digit6:54,digit7:55,digit8:56,digit9:57,colon:58,semicolon:59,lessThan:60,equalsTo:61,greaterThan:62,questionMark:63,atSign:64,uppercaseA:65,uppercaseB:66,uppercaseC:67,uppercaseD:68,uppercaseE:69,uppercaseF:70,uppercaseG:71,uppercaseH:72,uppercaseI:73,uppercaseJ:74,uppercaseK:75,uppercaseL:76,uppercaseM:77,uppercaseN:78,uppercaseO:79,uppercaseP:80,uppercaseQ:81,uppercaseR:82,uppercaseS:83,uppercaseT:84,uppercaseU:85,uppercaseV:86,uppercaseW:87,uppercaseX:88,uppercaseY:89,uppercaseZ:90,leftSquareBracket:91,backslash:92,rightSquareBracket:93,caret:94,underscore:95,graveAccent:96,lowercaseA:97,lowercaseB:98,lowercaseC:99,lowercaseD:100,lowercaseE:101,lowercaseF:102,lowercaseG:103,lowercaseH:104,lowercaseI:105,lowercaseJ:106,lowercaseK:107,lowercaseL:108,lowercaseM:109,lowercaseN:110,lowercaseO:111,lowercaseP:112,lowercaseQ:113,lowercaseR:114,lowercaseS:115,lowercaseT:116,lowercaseU:117,lowercaseV:118,lowercaseW:119,lowercaseX:120,lowercaseY:121,lowercaseZ:122,leftCurlyBrace:123,verticalBar:124,rightCurlyBrace:125,tilde:126,del:127,byteOrderMarker:65279,replacementCharacter:65533};var C={attentionSideAfter:2,attentionSideBefore:1,atxHeadingOpeningFenceSizeMax:6,autolinkDomainSizeMax:63,autolinkSchemeSizeMax:32,cdataOpeningString:"CDATA[",characterGroupPunctuation:2,characterGroupWhitespace:1,characterReferenceDecimalSizeMax:7,characterReferenceHexadecimalSizeMax:6,characterReferenceNamedSizeMax:31,codeFencedSequenceSizeMin:3,contentTypeContent:"content",contentTypeDocument:"document",contentTypeFlow:"flow",contentTypeString:"string",contentTypeText:"text",hardBreakPrefixSizeMin:2,htmlBasic:6,htmlCdata:5,htmlComment:2,htmlComplete:7,htmlDeclaration:4,htmlInstruction:3,htmlRawSizeMax:8,htmlRaw:1,linkResourceDestinationBalanceMax:32,linkReferenceSizeMax:999,listItemValueSizeMax:10,numericBaseDecimal:10,numericBaseHexadecimal:16,tabSize:4,thematicBreakMarkerCountMin:3,v8MaxSafeChunkSize:1e4};var M={data:"data",whitespace:"whitespace",lineEnding:"lineEnding",lineEndingBlank:"lineEndingBlank",linePrefix:"linePrefix",lineSuffix:"lineSuffix",atxHeading:"atxHeading",atxHeadingSequence:"atxHeadingSequence",atxHeadingText:"atxHeadingText",autolink:"autolink",autolinkEmail:"autolinkEmail",autolinkMarker:"autolinkMarker",autolinkProtocol:"autolinkProtocol",characterEscape:"characterEscape",characterEscapeValue:"characterEscapeValue",characterReference:"characterReference",characterReferenceMarker:"characterReferenceMarker",characterReferenceMarkerNumeric:"characterReferenceMarkerNumeric",characterReferenceMarkerHexadecimal:"characterReferenceMarkerHexadecimal",characterReferenceValue:"characterReferenceValue",codeFenced:"codeFenced",codeFencedFence:"codeFencedFence",codeFencedFenceSequence:"codeFencedFenceSequence",codeFencedFenceInfo:"codeFencedFenceInfo",codeFencedFenceMeta:"codeFencedFenceMeta",codeFlowValue:"codeFlowValue",codeIndented:"codeIndented",codeText:"codeText",codeTextData:"codeTextData",codeTextPadding:"codeTextPadding",codeTextSequence:"codeTextSequence",content:"content",definition:"definition",definitionDestination:"definitionDestination",definitionDestinationLiteral:"definitionDestinationLiteral",definitionDestinationLiteralMarker:"definitionDestinationLiteralMarker",definitionDestinationRaw:"definitionDestinationRaw",definitionDestinationString:"definitionDestinationString",definitionLabel:"definitionLabel",definitionLabelMarker:"definitionLabelMarker",definitionLabelString:"definitionLabelString",definitionMarker:"definitionMarker",definitionTitle:"definitionTitle",definitionTitleMarker:"definitionTitleMarker",definitionTitleString:"definitionTitleString",emphasis:"emphasis",emphasisSequence:"emphasisSequence",emphasisText:"emphasisText",escapeMarker:"escapeMarker",hardBreakEscape:"hardBreakEscape",hardBreakTrailing:"hardBreakTrailing",htmlFlow:"htmlFlow",htmlFlowData:"htmlFlowData",htmlText:"htmlText",htmlTextData:"htmlTextData",image:"image",label:"label",labelText:"labelText",labelLink:"labelLink",labelImage:"labelImage",labelMarker:"labelMarker",labelImageMarker:"labelImageMarker",labelEnd:"labelEnd",link:"link",paragraph:"paragraph",reference:"reference",referenceMarker:"referenceMarker",referenceString:"referenceString",resource:"resource",resourceDestination:"resourceDestination",resourceDestinationLiteral:"resourceDestinationLiteral",resourceDestinationLiteralMarker:"resourceDestinationLiteralMarker",resourceDestinationRaw:"resourceDestinationRaw",resourceDestinationString:"resourceDestinationString",resourceMarker:"resourceMarker",resourceTitle:"resourceTitle",resourceTitleMarker:"resourceTitleMarker",resourceTitleString:"resourceTitleString",setextHeading:"setextHeading",setextHeadingText:"setextHeadingText",setextHeadingLine:"setextHeadingLine",setextHeadingLineSequence:"setextHeadingLineSequence",strong:"strong",strongSequence:"strongSequence",strongText:"strongText",thematicBreak:"thematicBreak",thematicBreakSequence:"thematicBreakSequence",blockQuote:"blockQuote",blockQuotePrefix:"blockQuotePrefix",blockQuoteMarker:"blockQuoteMarker",blockQuotePrefixWhitespace:"blockQuotePrefixWhitespace",listOrdered:"listOrdered",listUnordered:"listUnordered",listItemIndent:"listItemIndent",listItemMarker:"listItemMarker",listItemPrefix:"listItemPrefix",listItemPrefixWhitespace:"listItemPrefixWhitespace",listItemValue:"listItemValue",chunkDocument:"chunkDocument",chunkContent:"chunkContent",chunkFlow:"chunkFlow",chunkText:"chunkText",chunkString:"chunkString"};var hq={ht:"\t",lf:`
|
|
104
|
-
`,cr:"\r",space:" ",exclamationMark:"!",quotationMark:'"',numberSign:"#",dollarSign:"$",percentSign:"%",ampersand:"&",apostrophe:"'",leftParenthesis:"(",rightParenthesis:")",asterisk:"*",plusSign:"+",comma:",",dash:"-",dot:".",slash:"/",digit0:"0",digit1:"1",digit2:"2",digit3:"3",digit4:"4",digit5:"5",digit6:"6",digit7:"7",digit8:"8",digit9:"9",colon:":",semicolon:";",lessThan:"<",equalsTo:"=",greaterThan:">",questionMark:"?",atSign:"@",uppercaseA:"A",uppercaseB:"B",uppercaseC:"C",uppercaseD:"D",uppercaseE:"E",uppercaseF:"F",uppercaseG:"G",uppercaseH:"H",uppercaseI:"I",uppercaseJ:"J",uppercaseK:"K",uppercaseL:"L",uppercaseM:"M",uppercaseN:"N",uppercaseO:"O",uppercaseP:"P",uppercaseQ:"Q",uppercaseR:"R",uppercaseS:"S",uppercaseT:"T",uppercaseU:"U",uppercaseV:"V",uppercaseW:"W",uppercaseX:"X",uppercaseY:"Y",uppercaseZ:"Z",leftSquareBracket:"[",backslash:"\\",rightSquareBracket:"]",caret:"^",underscore:"_",graveAccent:"`",lowercaseA:"a",lowercaseB:"b",lowercaseC:"c",lowercaseD:"d",lowercaseE:"e",lowercaseF:"f",lowercaseG:"g",lowercaseH:"h",lowercaseI:"i",lowercaseJ:"j",lowercaseK:"k",lowercaseL:"l",lowercaseM:"m",lowercaseN:"n",lowercaseO:"o",lowercaseP:"p",lowercaseQ:"q",lowercaseR:"r",lowercaseS:"s",lowercaseT:"t",lowercaseU:"u",lowercaseV:"v",lowercaseW:"w",lowercaseX:"x",lowercaseY:"y",lowercaseZ:"z",leftCurlyBrace:"{",verticalBar:"|",rightCurlyBrace:"}",tilde:"~",replacementCharacter:"\uFFFD"};function Fq(q,$,J,G){let X=q.length,Y=0,U;if($<0)$=-$>X?0:X+$;else $=$>X?X:$;if(J=J>0?J:0,G.length<C.v8MaxSafeChunkSize)U=Array.from(G),U.unshift($,J),q.splice(...U);else{if(J)q.splice($,J);while(Y<G.length)U=G.slice(Y,Y+C.v8MaxSafeChunkSize),U.unshift($,0),q.splice(...U),Y+=C.v8MaxSafeChunkSize,$+=C.v8MaxSafeChunkSize}}function Cq(q,$){if(q.length>0)return Fq(q,q.length,0,$),q;return $}var i9={}.hasOwnProperty;function d9(q){let $={},J=-1;while(++J<q.length)GW($,q[J]);return $}function GW(q,$){let J;for(J in $){let X=(i9.call(q,J)?q[J]:void 0)||(q[J]={}),Y=$[J],U;if(Y)for(U in Y){if(!i9.call(X,U))X[U]=[];let Q=Y[U];XW(X[U],Array.isArray(Q)?Q:Q?[Q]:[])}}}function XW(q,$){let J=-1,G=[];while(++J<$.length)($[J].add==="after"?q:G).push($[J]);Fq(q,0,0,G)}function G3(q,$){let J=Number.parseInt(q,$);if(J<K.ht||J===K.vt||J>K.cr&&J<K.space||J>K.tilde&&J<160||J>55295&&J<57344||J>64975&&J<65008||(J&65535)===65535||(J&65535)===65534||J>1114111)return hq.replacementCharacter;return String.fromCodePoint(J)}function K1(q){return q.replace(/[\t\n\r ]+/g,hq.space).replace(/^ | $/g,"").toLowerCase().toUpperCase()}var xq=S1(/[A-Za-z]/),Eq=S1(/[\dA-Za-z]/),c9=S1(/[#-'*+\--9=?A-Z^-~]/);function F$(q){return q!==null&&(q<K.space||q===K.del)}var O$=S1(/\d/),n9=S1(/[\dA-Fa-f]/),o9=S1(/[!-/:-@[-`{-~]/);function T(q){return q!==null&&q<K.horizontalTab}function Wq(q){return q!==null&&(q<K.nul||q===K.space)}function p(q){return q===K.horizontalTab||q===K.virtualSpace||q===K.space}var a9=S1(/\p{P}|\p{S}/u),s9=S1(/\s/);function S1(q){return $;function $(J){return J!==null&&J>-1&&q.test(String.fromCharCode(J))}}function r(q,$,J,G){let X=G?G-1:Number.POSITIVE_INFINITY,Y=0;return U;function U(V){if(p(V))return q.enter(J),Q(V);return $(V)}function Q(V){if(p(V)&&Y++<X)return q.consume(V),Q;return q.exit(J),$(V)}}var t9={tokenize:YW};function YW(q){let $=q.attempt(this.parser.constructs.contentInitial,G,X),J;return $;function G(Q){if(R(Q===K.eof||T(Q),"expected eol or eof"),Q===K.eof){q.consume(Q);return}return q.enter(M.lineEnding),q.consume(Q),q.exit(M.lineEnding),r(q,$,M.linePrefix)}function X(Q){return R(Q!==K.eof&&!T(Q),"expected anything other than a line ending or EOF"),q.enter(M.paragraph),Y(Q)}function Y(Q){let V=q.enter(M.chunkText,{contentType:C.contentTypeText,previous:J});if(J)J.next=V;return J=V,U(Q)}function U(Q){if(Q===K.eof){q.exit(M.chunkText),q.exit(M.paragraph),q.consume(Q);return}if(T(Q))return q.consume(Q),q.exit(M.chunkText),Y;return q.consume(Q),U}}var q6={tokenize:UW},e9={tokenize:QW};function UW(q){let $=this,J=[],G=0,X,Y,U;return Q;function Q(h){if(G<J.length){let a=J[G];return $.containerState=a[1],R(a[0].continuation,"expected `continuation` to be defined on container construct"),q.attempt(a[0].continuation,V,W)(h)}return W(h)}function V(h){if(R($.containerState,"expected `containerState` to be defined after continuation"),G++,$.containerState._closeFlow){if($.containerState._closeFlow=void 0,X)I();let a=$.events.length,Gq=a,S;while(Gq--)if($.events[Gq][0]==="exit"&&$.events[Gq][1].type===M.chunkFlow){S=$.events[Gq][1].end;break}R(S,"could not find previous flow chunk"),L(G);let e=a;while(e<$.events.length)$.events[e][1].end={...S},e++;return Fq($.events,Gq+1,0,$.events.slice(a)),$.events.length=e,W(h)}return Q(h)}function W(h){if(G===J.length){if(!X)return B(h);if(X.currentConstruct&&X.currentConstruct.concrete)return O(h);$.interrupt=Boolean(X.currentConstruct&&!X._gfmTableDynamicInterruptHack)}return $.containerState={},q.check(e9,H,z)(h)}function H(h){if(X)I();return L(G),B(h)}function z(h){return $.parser.lazy[$.now().line]=G!==J.length,U=$.now().offset,O(h)}function B(h){return $.containerState={},q.attempt(e9,D,O)(h)}function D(h){return R($.currentConstruct,"expected `currentConstruct` to be defined on tokenizer"),R($.containerState,"expected `containerState` to be defined on tokenizer"),G++,J.push([$.currentConstruct,$.containerState]),B(h)}function O(h){if(h===K.eof){if(X)I();L(0),q.consume(h);return}return X=X||$.parser.flow($.now()),q.enter(M.chunkFlow,{_tokenizer:X,contentType:C.contentTypeFlow,previous:Y}),j(h)}function j(h){if(h===K.eof){P(q.exit(M.chunkFlow),!0),L(0),q.consume(h);return}if(T(h))return q.consume(h),P(q.exit(M.chunkFlow)),G=0,$.interrupt=void 0,Q;return q.consume(h),j}function P(h,a){R(X,"expected `childFlow` to be defined when continuing");let Gq=$.sliceStream(h);if(a)Gq.push(null);if(h.previous=Y,Y)Y.next=h;if(Y=h,X.defineSkip(h.start),X.write(Gq),$.parser.lazy[h.start.line]){let S=X.events.length;while(S--)if(X.events[S][1].start.offset<U&&(!X.events[S][1].end||X.events[S][1].end.offset>U))return;let e=$.events.length,Yq=e,s,Xq;while(Yq--)if($.events[Yq][0]==="exit"&&$.events[Yq][1].type===M.chunkFlow){if(s){Xq=$.events[Yq][1].end;break}s=!0}R(Xq,"could not find previous flow chunk"),L(G),S=e;while(S<$.events.length)$.events[S][1].end={...Xq},S++;Fq($.events,Yq+1,0,$.events.slice(e)),$.events.length=S}}function L(h){let a=J.length;while(a-- >h){let Gq=J[a];$.containerState=Gq[1],R(Gq[0].exit,"expected `exit` to be defined on container construct"),Gq[0].exit.call($,q)}J.length=h}function I(){R($.containerState,"expected `containerState` to be defined when closing flow"),R(X,"expected `childFlow` to be defined when closing it"),X.write([K.eof]),Y=void 0,X=void 0,$.containerState._closeFlow=void 0}}function QW(q,$,J){return R(this.parser.constructs.disable.null,"expected `disable.null` to be populated"),r(q,q.attempt(this.parser.constructs.document,$,J),M.linePrefix,this.parser.constructs.disable.null.includes("codeIndented")?void 0:C.tabSize)}function g0(q){if(q===K.eof||Wq(q)||s9(q))return C.characterGroupWhitespace;if(a9(q))return C.characterGroupPunctuation}function v0(q,$,J){let G=[],X=-1;while(++X<q.length){let Y=q[X].resolveAll;if(Y&&!G.includes(Y))$=Y($,J),G.push(Y)}return $}var A$={name:"attention",resolveAll:VW,tokenize:WW};function VW(q,$){let J=-1,G,X,Y,U,Q,V,W,H;while(++J<q.length)if(q[J][0]==="enter"&&q[J][1].type==="attentionSequence"&&q[J][1]._close){G=J;while(G--)if(q[G][0]==="exit"&&q[G][1].type==="attentionSequence"&&q[G][1]._open&&$.sliceSerialize(q[G][1]).charCodeAt(0)===$.sliceSerialize(q[J][1]).charCodeAt(0)){if((q[G][1]._close||q[J][1]._open)&&(q[J][1].end.offset-q[J][1].start.offset)%3&&!((q[G][1].end.offset-q[G][1].start.offset+q[J][1].end.offset-q[J][1].start.offset)%3))continue;V=q[G][1].end.offset-q[G][1].start.offset>1&&q[J][1].end.offset-q[J][1].start.offset>1?2:1;let z={...q[G][1].end},B={...q[J][1].start};if($6(z,-V),$6(B,V),U={type:V>1?M.strongSequence:M.emphasisSequence,start:z,end:{...q[G][1].end}},Q={type:V>1?M.strongSequence:M.emphasisSequence,start:{...q[J][1].start},end:B},Y={type:V>1?M.strongText:M.emphasisText,start:{...q[G][1].end},end:{...q[J][1].start}},X={type:V>1?M.strong:M.emphasis,start:{...U.start},end:{...Q.end}},q[G][1].end={...U.start},q[J][1].start={...Q.end},W=[],q[G][1].end.offset-q[G][1].start.offset)W=Cq(W,[["enter",q[G][1],$],["exit",q[G][1],$]]);if(W=Cq(W,[["enter",X,$],["enter",U,$],["exit",U,$],["enter",Y,$]]),R($.parser.constructs.insideSpan.null,"expected `insideSpan` to be populated"),W=Cq(W,v0($.parser.constructs.insideSpan.null,q.slice(G+1,J),$)),W=Cq(W,[["exit",Y,$],["enter",Q,$],["exit",Q,$],["exit",X,$]]),q[J][1].end.offset-q[J][1].start.offset)H=2,W=Cq(W,[["enter",q[J][1],$],["exit",q[J][1],$]]);else H=0;Fq(q,G-1,J-G+3,W),J=G+W.length-H-2;break}}J=-1;while(++J<q.length)if(q[J][1].type==="attentionSequence")q[J][1].type="data";return q}function WW(q,$){let J=this.parser.constructs.attentionMarkers.null,G=this.previous,X=g0(G),Y;return U;function U(V){return R(V===K.asterisk||V===K.underscore,"expected asterisk or underscore"),Y=V,q.enter("attentionSequence"),Q(V)}function Q(V){if(V===Y)return q.consume(V),Q;let W=q.exit("attentionSequence"),H=g0(V);R(J,"expected `attentionMarkers` to be populated");let z=!H||H===C.characterGroupPunctuation&&X||J.includes(V),B=!X||X===C.characterGroupPunctuation&&H||J.includes(G);return W._open=Boolean(Y===K.asterisk?z:z&&(X||!B)),W._close=Boolean(Y===K.asterisk?B:B&&(H||!z)),$(V)}}function $6(q,$){q.column+=$,q.offset+=$,q._bufferIndex+=$}var SJ={name:"autolink",tokenize:HW};function HW(q,$,J){let G=0;return X;function X(D){return R(D===K.lessThan,"expected `<`"),q.enter(M.autolink),q.enter(M.autolinkMarker),q.consume(D),q.exit(M.autolinkMarker),q.enter(M.autolinkProtocol),Y}function Y(D){if(xq(D))return q.consume(D),U;if(D===K.atSign)return J(D);return W(D)}function U(D){if(D===K.plusSign||D===K.dash||D===K.dot||Eq(D))return G=1,Q(D);return W(D)}function Q(D){if(D===K.colon)return q.consume(D),G=0,V;if((D===K.plusSign||D===K.dash||D===K.dot||Eq(D))&&G++<C.autolinkSchemeSizeMax)return q.consume(D),Q;return G=0,W(D)}function V(D){if(D===K.greaterThan)return q.exit(M.autolinkProtocol),q.enter(M.autolinkMarker),q.consume(D),q.exit(M.autolinkMarker),q.exit(M.autolink),$;if(D===K.eof||D===K.space||D===K.lessThan||F$(D))return J(D);return q.consume(D),V}function W(D){if(D===K.atSign)return q.consume(D),H;if(c9(D))return q.consume(D),W;return J(D)}function H(D){return Eq(D)?z(D):J(D)}function z(D){if(D===K.dot)return q.consume(D),G=0,H;if(D===K.greaterThan)return q.exit(M.autolinkProtocol).type=M.autolinkEmail,q.enter(M.autolinkMarker),q.consume(D),q.exit(M.autolinkMarker),q.exit(M.autolink),$;return B(D)}function B(D){if((D===K.dash||Eq(D))&&G++<C.autolinkDomainSizeMax){let O=D===K.dash?B:z;return q.consume(D),O}return J(D)}}var P1={partial:!0,tokenize:zW};function zW(q,$,J){return G;function G(Y){return p(Y)?r(q,X,M.linePrefix)(Y):X(Y)}function X(Y){return Y===K.eof||T(Y)?$(Y):J(Y)}}var X3={continuation:{tokenize:KW},exit:DW,name:"blockQuote",tokenize:MW};function MW(q,$,J){let G=this;return X;function X(U){if(U===K.greaterThan){let Q=G.containerState;if(R(Q,"expected `containerState` to be defined in container"),!Q.open)q.enter(M.blockQuote,{_container:!0}),Q.open=!0;return q.enter(M.blockQuotePrefix),q.enter(M.blockQuoteMarker),q.consume(U),q.exit(M.blockQuoteMarker),Y}return J(U)}function Y(U){if(p(U))return q.enter(M.blockQuotePrefixWhitespace),q.consume(U),q.exit(M.blockQuotePrefixWhitespace),q.exit(M.blockQuotePrefix),$;return q.exit(M.blockQuotePrefix),$(U)}}function KW(q,$,J){let G=this;return X;function X(U){if(p(U))return R(G.parser.constructs.disable.null,"expected `disable.null` to be populated"),r(q,Y,M.linePrefix,G.parser.constructs.disable.null.includes("codeIndented")?void 0:C.tabSize)(U);return Y(U)}function Y(U){return q.attempt(X3,$,J)(U)}}function DW(q){q.exit(M.blockQuote)}var Y3={name:"characterEscape",tokenize:BW};function BW(q,$,J){return G;function G(Y){return R(Y===K.backslash,"expected `\\`"),q.enter(M.characterEscape),q.enter(M.escapeMarker),q.consume(Y),q.exit(M.escapeMarker),X}function X(Y){if(o9(Y))return q.enter(M.characterEscapeValue),q.consume(Y),q.exit(M.characterEscapeValue),q.exit(M.characterEscape),$;return J(Y)}}var U3={name:"characterReference",tokenize:RW};function RW(q,$,J){let G=this,X=0,Y,U;return Q;function Q(z){return R(z===K.ampersand,"expected `&`"),q.enter(M.characterReference),q.enter(M.characterReferenceMarker),q.consume(z),q.exit(M.characterReferenceMarker),V}function V(z){if(z===K.numberSign)return q.enter(M.characterReferenceMarkerNumeric),q.consume(z),q.exit(M.characterReferenceMarkerNumeric),W;return q.enter(M.characterReferenceValue),Y=C.characterReferenceNamedSizeMax,U=Eq,H(z)}function W(z){if(z===K.uppercaseX||z===K.lowercaseX)return q.enter(M.characterReferenceMarkerHexadecimal),q.consume(z),q.exit(M.characterReferenceMarkerHexadecimal),q.enter(M.characterReferenceValue),Y=C.characterReferenceHexadecimalSizeMax,U=n9,H;return q.enter(M.characterReferenceValue),Y=C.characterReferenceDecimalSizeMax,U=O$,H(z)}function H(z){if(z===K.semicolon&&X){let B=q.exit(M.characterReferenceValue);if(U===Eq&&!I0(G.sliceSerialize(B)))return J(z);return q.enter(M.characterReferenceMarker),q.consume(z),q.exit(M.characterReferenceMarker),q.exit(M.characterReference),$}if(U(z)&&X++<Y)return q.consume(z),H;return J(z)}}var J6={partial:!0,tokenize:FW},Q3={concrete:!0,name:"codeFenced",tokenize:wW};function wW(q,$,J){let G=this,X={partial:!0,tokenize:Gq},Y=0,U=0,Q;return V;function V(S){return W(S)}function W(S){R(S===K.graveAccent||S===K.tilde,"expected `` ` `` or `~`");let e=G.events[G.events.length-1];return Y=e&&e[1].type===M.linePrefix?e[2].sliceSerialize(e[1],!0).length:0,Q=S,q.enter(M.codeFenced),q.enter(M.codeFencedFence),q.enter(M.codeFencedFenceSequence),H(S)}function H(S){if(S===Q)return U++,q.consume(S),H;if(U<C.codeFencedSequenceSizeMin)return J(S);return q.exit(M.codeFencedFenceSequence),p(S)?r(q,z,M.whitespace)(S):z(S)}function z(S){if(S===K.eof||T(S))return q.exit(M.codeFencedFence),G.interrupt?$(S):q.check(J6,j,a)(S);return q.enter(M.codeFencedFenceInfo),q.enter(M.chunkString,{contentType:C.contentTypeString}),B(S)}function B(S){if(S===K.eof||T(S))return q.exit(M.chunkString),q.exit(M.codeFencedFenceInfo),z(S);if(p(S))return q.exit(M.chunkString),q.exit(M.codeFencedFenceInfo),r(q,D,M.whitespace)(S);if(S===K.graveAccent&&S===Q)return J(S);return q.consume(S),B}function D(S){if(S===K.eof||T(S))return z(S);return q.enter(M.codeFencedFenceMeta),q.enter(M.chunkString,{contentType:C.contentTypeString}),O(S)}function O(S){if(S===K.eof||T(S))return q.exit(M.chunkString),q.exit(M.codeFencedFenceMeta),z(S);if(S===K.graveAccent&&S===Q)return J(S);return q.consume(S),O}function j(S){return R(T(S),"expected eol"),q.attempt(X,a,P)(S)}function P(S){return R(T(S),"expected eol"),q.enter(M.lineEnding),q.consume(S),q.exit(M.lineEnding),L}function L(S){return Y>0&&p(S)?r(q,I,M.linePrefix,Y+1)(S):I(S)}function I(S){if(S===K.eof||T(S))return q.check(J6,j,a)(S);return q.enter(M.codeFlowValue),h(S)}function h(S){if(S===K.eof||T(S))return q.exit(M.codeFlowValue),I(S);return q.consume(S),h}function a(S){return q.exit(M.codeFenced),$(S)}function Gq(S,e,Yq){let s=0;return Xq;function Xq(d){return R(T(d),"expected eol"),S.enter(M.lineEnding),S.consume(d),S.exit(M.lineEnding),kq}function kq(d){return R(G.parser.constructs.disable.null,"expected `disable.null` to be populated"),S.enter(M.codeFencedFence),p(d)?r(S,Jq,M.linePrefix,G.parser.constructs.disable.null.includes("codeIndented")?void 0:C.tabSize)(d):Jq(d)}function Jq(d){if(d===Q)return S.enter(M.codeFencedFenceSequence),g(d);return Yq(d)}function g(d){if(d===Q)return s++,S.consume(d),g;if(s>=U)return S.exit(M.codeFencedFenceSequence),p(d)?r(S,l,M.whitespace)(d):l(d);return Yq(d)}function l(d){if(d===K.eof||T(d))return S.exit(M.codeFencedFence),e(d);return Yq(d)}}}function FW(q,$,J){let G=this;return X;function X(U){if(U===K.eof)return J(U);return R(T(U),"expected eol"),q.enter(M.lineEnding),q.consume(U),q.exit(M.lineEnding),Y}function Y(U){return G.parser.lazy[G.now().line]?J(U):$(U)}}var N$={name:"codeIndented",tokenize:AW},OW={partial:!0,tokenize:NW};function AW(q,$,J){let G=this;return X;function X(W){return R(p(W)),q.enter(M.codeIndented),r(q,Y,M.linePrefix,C.tabSize+1)(W)}function Y(W){let H=G.events[G.events.length-1];return H&&H[1].type===M.linePrefix&&H[2].sliceSerialize(H[1],!0).length>=C.tabSize?U(W):J(W)}function U(W){if(W===K.eof)return V(W);if(T(W))return q.attempt(OW,U,V)(W);return q.enter(M.codeFlowValue),Q(W)}function Q(W){if(W===K.eof||T(W))return q.exit(M.codeFlowValue),U(W);return q.consume(W),Q}function V(W){return q.exit(M.codeIndented),$(W)}}function NW(q,$,J){let G=this;return X;function X(U){if(G.parser.lazy[G.now().line])return J(U);if(T(U))return q.enter(M.lineEnding),q.consume(U),q.exit(M.lineEnding),X;return r(q,Y,M.linePrefix,C.tabSize+1)(U)}function Y(U){let Q=G.events[G.events.length-1];return Q&&Q[1].type===M.linePrefix&&Q[2].sliceSerialize(Q[1],!0).length>=C.tabSize?$(U):T(U)?X(U):J(U)}}var PJ={name:"codeText",previous:G6,resolve:jW,tokenize:SW};function jW(q){let $=q.length-4,J=3,G,X;if((q[J][1].type===M.lineEnding||q[J][1].type==="space")&&(q[$][1].type===M.lineEnding||q[$][1].type==="space")){G=J;while(++G<$)if(q[G][1].type===M.codeTextData){q[J][1].type=M.codeTextPadding,q[$][1].type=M.codeTextPadding,J+=2,$-=2;break}}G=J-1,$++;while(++G<=$)if(X===void 0){if(G!==$&&q[G][1].type!==M.lineEnding)X=G}else if(G===$||q[G][1].type===M.lineEnding){if(q[X][1].type=M.codeTextData,G!==X+2)q[X][1].end=q[G-1][1].end,q.splice(X+2,G-X-2),$-=G-X-2,G=X+2;X=void 0}return q}function G6(q){return q!==K.graveAccent||this.events[this.events.length-1][1].type===M.characterEscape}function SW(q,$,J){let G=this,X=0,Y,U;return Q;function Q(B){return R(B===K.graveAccent,"expected `` ` ``"),R(G6.call(G,G.previous),"expected correct previous"),q.enter(M.codeText),q.enter(M.codeTextSequence),V(B)}function V(B){if(B===K.graveAccent)return q.consume(B),X++,V;return q.exit(M.codeTextSequence),W(B)}function W(B){if(B===K.eof)return J(B);if(B===K.space)return q.enter("space"),q.consume(B),q.exit("space"),W;if(B===K.graveAccent)return U=q.enter(M.codeTextSequence),Y=0,z(B);if(T(B))return q.enter(M.lineEnding),q.consume(B),q.exit(M.lineEnding),W;return q.enter(M.codeTextData),H(B)}function H(B){if(B===K.eof||B===K.space||B===K.graveAccent||T(B))return q.exit(M.codeTextData),W(B);return q.consume(B),H}function z(B){if(B===K.graveAccent)return q.consume(B),Y++,z;if(Y===X)return q.exit(M.codeTextSequence),q.exit(M.codeText),$(B);return U.type=M.codeTextData,H(B)}}class LJ{constructor(q){this.left=q?[...q]:[],this.right=[]}get(q){if(q<0||q>=this.left.length+this.right.length)throw RangeError("Cannot access index `"+q+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");if(q<this.left.length)return this.left[q];return this.right[this.right.length-q+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(q,$){let J=$===null||$===void 0?Number.POSITIVE_INFINITY:$;if(J<this.left.length)return this.left.slice(q,J);if(q>this.left.length)return this.right.slice(this.right.length-J+this.left.length,this.right.length-q+this.left.length).reverse();return this.left.slice(q).concat(this.right.slice(this.right.length-J+this.left.length).reverse())}splice(q,$,J){let G=$||0;this.setCursor(Math.trunc(q));let X=this.right.splice(this.right.length-G,Number.POSITIVE_INFINITY);if(J)j$(this.left,J);return X.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(q){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(q)}pushMany(q){this.setCursor(Number.POSITIVE_INFINITY),j$(this.left,q)}unshift(q){this.setCursor(0),this.right.push(q)}unshiftMany(q){this.setCursor(0),j$(this.right,q.reverse())}setCursor(q){if(q===this.left.length||q>this.left.length&&this.right.length===0||q<0&&this.left.length===0)return;if(q<this.left.length){let $=this.left.splice(q,Number.POSITIVE_INFINITY);j$(this.right,$.reverse())}else{let $=this.right.splice(this.left.length+this.right.length-q,Number.POSITIVE_INFINITY);j$(this.left,$.reverse())}}}function j$(q,$){let J=0;if($.length<C.v8MaxSafeChunkSize)q.push(...$);else while(J<$.length)q.push(...$.slice(J,J+C.v8MaxSafeChunkSize)),J+=C.v8MaxSafeChunkSize}function V3(q){let $={},J=-1,G,X,Y,U,Q,V,W,H=new LJ(q);while(++J<H.length){while(J in $)J=$[J];if(G=H.get(J),J&&G[1].type===M.chunkFlow&&H.get(J-1)[1].type===M.listItemPrefix){if(R(G[1]._tokenizer,"expected `_tokenizer` on subtokens"),V=G[1]._tokenizer.events,Y=0,Y<V.length&&V[Y][1].type===M.lineEndingBlank)Y+=2;if(Y<V.length&&V[Y][1].type===M.content)while(++Y<V.length){if(V[Y][1].type===M.content)break;if(V[Y][1].type===M.chunkText)V[Y][1]._isInFirstContentOfListItem=!0,Y++}}if(G[0]==="enter"){if(G[1].contentType)Object.assign($,PW(H,J)),J=$[J],W=!0}else if(G[1]._container){Y=J,X=void 0;while(Y--)if(U=H.get(Y),U[1].type===M.lineEnding||U[1].type===M.lineEndingBlank){if(U[0]==="enter"){if(X)H.get(X)[1].type=M.lineEndingBlank;U[1].type=M.lineEnding,X=Y}}else if(U[1].type===M.linePrefix||U[1].type===M.listItemIndent);else break;if(X)G[1].end={...H.get(X)[1].start},Q=H.slice(X,J),Q.unshift(G),H.splice(X,J-X+1,Q)}}return Fq(q,0,Number.POSITIVE_INFINITY,H.slice(0)),!W}function PW(q,$){let J=q.get($)[1],G=q.get($)[2],X=$-1,Y=[];R(J.contentType,"expected `contentType` on subtokens");let U=J._tokenizer;if(!U){if(U=G.parser[J.contentType](J.start),J._contentTypeTextTrailing)U._contentTypeTextTrailing=!0}let Q=U.events,V=[],W={},H,z,B=-1,D=J,O=0,j=0,P=[j];while(D){while(q.get(++X)[1]!==D);if(R(!z||D.previous===z,"expected previous to match"),R(!z||z.next===D,"expected next to match"),Y.push(X),!D._tokenizer){if(H=G.sliceStream(D),!D.next)H.push(K.eof);if(z)U.defineSkip(D.start);if(D._isInFirstContentOfListItem)U._gfmTasklistFirstContentOfListItem=!0;if(U.write(H),D._isInFirstContentOfListItem)U._gfmTasklistFirstContentOfListItem=void 0}z=D,D=D.next}D=J;while(++B<Q.length)if(Q[B][0]==="exit"&&Q[B-1][0]==="enter"&&Q[B][1].type===Q[B-1][1].type&&Q[B][1].start.line!==Q[B][1].end.line)R(D,"expected a current token"),j=B+1,P.push(j),D._tokenizer=void 0,D.previous=void 0,D=D.next;if(U.events=[],D)D._tokenizer=void 0,D.previous=void 0,R(!D.next,"expected no next token");else P.pop();B=P.length;while(B--){let L=Q.slice(P[B],P[B+1]),I=Y.pop();R(I!==void 0,"expected a start position when splicing"),V.push([I,I+L.length-1]),q.splice(I,2,L)}V.reverse(),B=-1;while(++B<V.length)W[O+V[B][0]]=O+V[B][1],O+=V[B][1]-V[B][0]-1;return W}var ZJ={resolve:ZW,tokenize:CW},LW={partial:!0,tokenize:EW};function ZW(q){return V3(q),q}function CW(q,$){let J;return G;function G(Q){return R(Q!==K.eof&&!T(Q),"expected no eof or eol"),q.enter(M.content),J=q.enter(M.chunkContent,{contentType:C.contentTypeContent}),X(Q)}function X(Q){if(Q===K.eof)return Y(Q);if(T(Q))return q.check(LW,U,Y)(Q);return q.consume(Q),X}function Y(Q){return q.exit(M.chunkContent),q.exit(M.content),$(Q)}function U(Q){return R(T(Q),"expected eol"),q.consume(Q),q.exit(M.chunkContent),R(J,"expected previous token"),J.next=q.enter(M.chunkContent,{contentType:C.contentTypeContent,previous:J}),J=J.next,X}}function EW(q,$,J){let G=this;return X;function X(U){return R(T(U),"expected a line ending"),q.exit(M.chunkContent),q.enter(M.lineEnding),q.consume(U),q.exit(M.lineEnding),r(q,Y,M.linePrefix)}function Y(U){if(U===K.eof||T(U))return J(U);R(G.parser.constructs.disable.null,"expected `disable.null` to be populated");let Q=G.events[G.events.length-1];if(!G.parser.constructs.disable.null.includes("codeIndented")&&Q&&Q[1].type===M.linePrefix&&Q[2].sliceSerialize(Q[1],!0).length>=C.tabSize)return $(U);return q.interrupt(G.parser.constructs.flow,J,$)(U)}}function W3(q,$,J,G,X,Y,U,Q,V){let W=V||Number.POSITIVE_INFINITY,H=0;return z;function z(L){if(L===K.lessThan)return q.enter(G),q.enter(X),q.enter(Y),q.consume(L),q.exit(Y),B;if(L===K.eof||L===K.space||L===K.rightParenthesis||F$(L))return J(L);return q.enter(G),q.enter(U),q.enter(Q),q.enter(M.chunkString,{contentType:C.contentTypeString}),j(L)}function B(L){if(L===K.greaterThan)return q.enter(Y),q.consume(L),q.exit(Y),q.exit(X),q.exit(G),$;return q.enter(Q),q.enter(M.chunkString,{contentType:C.contentTypeString}),D(L)}function D(L){if(L===K.greaterThan)return q.exit(M.chunkString),q.exit(Q),B(L);if(L===K.eof||L===K.lessThan||T(L))return J(L);return q.consume(L),L===K.backslash?O:D}function O(L){if(L===K.lessThan||L===K.greaterThan||L===K.backslash)return q.consume(L),D;return D(L)}function j(L){if(!H&&(L===K.eof||L===K.rightParenthesis||Wq(L)))return q.exit(M.chunkString),q.exit(Q),q.exit(U),q.exit(G),$(L);if(H<W&&L===K.leftParenthesis)return q.consume(L),H++,j;if(L===K.rightParenthesis)return q.consume(L),H--,j;if(L===K.eof||L===K.space||L===K.leftParenthesis||F$(L))return J(L);return q.consume(L),L===K.backslash?P:j}function P(L){if(L===K.leftParenthesis||L===K.rightParenthesis||L===K.backslash)return q.consume(L),j;return j(L)}}function H3(q,$,J,G,X,Y){let U=this,Q=0,V;return W;function W(D){return R(D===K.leftSquareBracket,"expected `[`"),q.enter(G),q.enter(X),q.consume(D),q.exit(X),q.enter(Y),H}function H(D){if(Q>C.linkReferenceSizeMax||D===K.eof||D===K.leftSquareBracket||D===K.rightSquareBracket&&!V||D===K.caret&&!Q&&"_hiddenFootnoteSupport"in U.parser.constructs)return J(D);if(D===K.rightSquareBracket)return q.exit(Y),q.enter(X),q.consume(D),q.exit(X),q.exit(G),$;if(T(D))return q.enter(M.lineEnding),q.consume(D),q.exit(M.lineEnding),H;return q.enter(M.chunkString,{contentType:C.contentTypeString}),z(D)}function z(D){if(D===K.eof||D===K.leftSquareBracket||D===K.rightSquareBracket||T(D)||Q++>C.linkReferenceSizeMax)return q.exit(M.chunkString),H(D);if(q.consume(D),!V)V=!p(D);return D===K.backslash?B:z}function B(D){if(D===K.leftSquareBracket||D===K.backslash||D===K.rightSquareBracket)return q.consume(D),Q++,z;return z(D)}}function z3(q,$,J,G,X,Y){let U;return Q;function Q(B){if(B===K.quotationMark||B===K.apostrophe||B===K.leftParenthesis)return q.enter(G),q.enter(X),q.consume(B),q.exit(X),U=B===K.leftParenthesis?K.rightParenthesis:B,V;return J(B)}function V(B){if(B===U)return q.enter(X),q.consume(B),q.exit(X),q.exit(G),$;return q.enter(Y),W(B)}function W(B){if(B===U)return q.exit(Y),V(U);if(B===K.eof)return J(B);if(T(B))return q.enter(M.lineEnding),q.consume(B),q.exit(M.lineEnding),r(q,W,M.linePrefix);return q.enter(M.chunkString,{contentType:C.contentTypeString}),H(B)}function H(B){if(B===U||B===K.eof||T(B))return q.exit(M.chunkString),W(B);return q.consume(B),B===K.backslash?z:H}function z(B){if(B===U||B===K.backslash)return q.consume(B),H;return H(B)}}function n1(q,$){let J;return G;function G(X){if(T(X))return q.enter(M.lineEnding),q.consume(X),q.exit(M.lineEnding),J=!0,G;if(p(X))return r(q,G,J?M.linePrefix:M.lineSuffix)(X);return $(X)}}var CJ={name:"definition",tokenize:_W},TW={partial:!0,tokenize:bW};function _W(q,$,J){let G=this,X;return Y;function Y(D){return q.enter(M.definition),U(D)}function U(D){return R(D===K.leftSquareBracket,"expected `[`"),H3.call(G,q,Q,J,M.definitionLabel,M.definitionLabelMarker,M.definitionLabelString)(D)}function Q(D){if(X=K1(G.sliceSerialize(G.events[G.events.length-1][1]).slice(1,-1)),D===K.colon)return q.enter(M.definitionMarker),q.consume(D),q.exit(M.definitionMarker),V;return J(D)}function V(D){return Wq(D)?n1(q,W)(D):W(D)}function W(D){return W3(q,H,J,M.definitionDestination,M.definitionDestinationLiteral,M.definitionDestinationLiteralMarker,M.definitionDestinationRaw,M.definitionDestinationString)(D)}function H(D){return q.attempt(TW,z,z)(D)}function z(D){return p(D)?r(q,B,M.whitespace)(D):B(D)}function B(D){if(D===K.eof||T(D))return q.exit(M.definition),G.parser.defined.push(X),$(D);return J(D)}}function bW(q,$,J){return G;function G(Q){return Wq(Q)?n1(q,X)(Q):J(Q)}function X(Q){return z3(q,Y,J,M.definitionTitle,M.definitionTitleMarker,M.definitionTitleString)(Q)}function Y(Q){return p(Q)?r(q,U,M.whitespace)(Q):U(Q)}function U(Q){return Q===K.eof||T(Q)?$(Q):J(Q)}}var EJ={name:"hardBreakEscape",tokenize:IW};function IW(q,$,J){return G;function G(Y){return R(Y===K.backslash,"expected `\\`"),q.enter(M.hardBreakEscape),q.consume(Y),X}function X(Y){if(T(Y))return q.exit(M.hardBreakEscape),$(Y);return J(Y)}}var TJ={name:"headingAtx",resolve:gW,tokenize:vW};function gW(q,$){let J=q.length-2,G=3,X,Y;if(q[G][1].type===M.whitespace)G+=2;if(J-2>G&&q[J][1].type===M.whitespace)J-=2;if(q[J][1].type===M.atxHeadingSequence&&(G===J-1||J-4>G&&q[J-2][1].type===M.whitespace))J-=G+1===J?2:4;if(J>G)X={type:M.atxHeadingText,start:q[G][1].start,end:q[J][1].end},Y={type:M.chunkText,start:q[G][1].start,end:q[J][1].end,contentType:C.contentTypeText},Fq(q,G,J-G+1,[["enter",X,$],["enter",Y,$],["exit",Y,$],["exit",X,$]]);return q}function vW(q,$,J){let G=0;return X;function X(H){return q.enter(M.atxHeading),Y(H)}function Y(H){return R(H===K.numberSign,"expected `#`"),q.enter(M.atxHeadingSequence),U(H)}function U(H){if(H===K.numberSign&&G++<C.atxHeadingOpeningFenceSizeMax)return q.consume(H),U;if(H===K.eof||Wq(H))return q.exit(M.atxHeadingSequence),Q(H);return J(H)}function Q(H){if(H===K.numberSign)return q.enter(M.atxHeadingSequence),V(H);if(H===K.eof||T(H))return q.exit(M.atxHeading),$(H);if(p(H))return r(q,Q,M.whitespace)(H);return q.enter(M.atxHeadingText),W(H)}function V(H){if(H===K.numberSign)return q.consume(H),V;return q.exit(M.atxHeadingSequence),Q(H)}function W(H){if(H===K.eof||H===K.numberSign||Wq(H))return q.exit(M.atxHeadingText),Q(H);return q.consume(H),W}}var X6=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],_J=["pre","script","style","textarea"];var bJ={concrete:!0,name:"htmlFlow",resolveTo:xW,tokenize:mW},yW={partial:!0,tokenize:fW},hW={partial:!0,tokenize:kW};function xW(q){let $=q.length;while($--)if(q[$][0]==="enter"&&q[$][1].type===M.htmlFlow)break;if($>1&&q[$-2][1].type===M.linePrefix)q[$][1].start=q[$-2][1].start,q[$+1][1].start=q[$-2][1].start,q.splice($-2,2);return q}function mW(q,$,J){let G=this,X,Y,U,Q,V;return W;function W(F){return H(F)}function H(F){return R(F===K.lessThan,"expected `<`"),q.enter(M.htmlFlow),q.enter(M.htmlFlowData),q.consume(F),z}function z(F){if(F===K.exclamationMark)return q.consume(F),B;if(F===K.slash)return q.consume(F),Y=!0,j;if(F===K.questionMark)return q.consume(F),X=C.htmlInstruction,G.interrupt?$:w;if(xq(F))return R(F!==null),q.consume(F),U=String.fromCharCode(F),P;return J(F)}function B(F){if(F===K.dash)return q.consume(F),X=C.htmlComment,D;if(F===K.leftSquareBracket)return q.consume(F),X=C.htmlCdata,Q=0,O;if(xq(F))return q.consume(F),X=C.htmlDeclaration,G.interrupt?$:w;return J(F)}function D(F){if(F===K.dash)return q.consume(F),G.interrupt?$:w;return J(F)}function O(F){let gq=C.cdataOpeningString;if(F===gq.charCodeAt(Q++)){if(q.consume(F),Q===gq.length)return G.interrupt?$:Jq;return O}return J(F)}function j(F){if(xq(F))return R(F!==null),q.consume(F),U=String.fromCharCode(F),P;return J(F)}function P(F){if(F===K.eof||F===K.slash||F===K.greaterThan||Wq(F)){let gq=F===K.slash,b1=U.toLowerCase();if(!gq&&!Y&&_J.includes(b1))return X=C.htmlRaw,G.interrupt?$(F):Jq(F);if(X6.includes(U.toLowerCase())){if(X=C.htmlBasic,gq)return q.consume(F),L;return G.interrupt?$(F):Jq(F)}return X=C.htmlComplete,G.interrupt&&!G.parser.lazy[G.now().line]?J(F):Y?I(F):h(F)}if(F===K.dash||Eq(F))return q.consume(F),U+=String.fromCharCode(F),P;return J(F)}function L(F){if(F===K.greaterThan)return q.consume(F),G.interrupt?$:Jq;return J(F)}function I(F){if(p(F))return q.consume(F),I;return Xq(F)}function h(F){if(F===K.slash)return q.consume(F),Xq;if(F===K.colon||F===K.underscore||xq(F))return q.consume(F),a;if(p(F))return q.consume(F),h;return Xq(F)}function a(F){if(F===K.dash||F===K.dot||F===K.colon||F===K.underscore||Eq(F))return q.consume(F),a;return Gq(F)}function Gq(F){if(F===K.equalsTo)return q.consume(F),S;if(p(F))return q.consume(F),Gq;return h(F)}function S(F){if(F===K.eof||F===K.lessThan||F===K.equalsTo||F===K.greaterThan||F===K.graveAccent)return J(F);if(F===K.quotationMark||F===K.apostrophe)return q.consume(F),V=F,e;if(p(F))return q.consume(F),S;return Yq(F)}function e(F){if(F===V)return q.consume(F),V=null,s;if(F===K.eof||T(F))return J(F);return q.consume(F),e}function Yq(F){if(F===K.eof||F===K.quotationMark||F===K.apostrophe||F===K.slash||F===K.lessThan||F===K.equalsTo||F===K.greaterThan||F===K.graveAccent||Wq(F))return Gq(F);return q.consume(F),Yq}function s(F){if(F===K.slash||F===K.greaterThan||p(F))return h(F);return J(F)}function Xq(F){if(F===K.greaterThan)return q.consume(F),kq;return J(F)}function kq(F){if(F===K.eof||T(F))return Jq(F);if(p(F))return q.consume(F),kq;return J(F)}function Jq(F){if(F===K.dash&&X===C.htmlComment)return q.consume(F),Qq;if(F===K.lessThan&&X===C.htmlRaw)return q.consume(F),Mq;if(F===K.greaterThan&&X===C.htmlDeclaration)return q.consume(F),uq;if(F===K.questionMark&&X===C.htmlInstruction)return q.consume(F),w;if(F===K.rightSquareBracket&&X===C.htmlCdata)return q.consume(F),aq;if(T(F)&&(X===C.htmlBasic||X===C.htmlComplete))return q.exit(M.htmlFlowData),q.check(yW,Y1,g)(F);if(F===K.eof||T(F))return q.exit(M.htmlFlowData),g(F);return q.consume(F),Jq}function g(F){return q.check(hW,l,Y1)(F)}function l(F){return R(T(F)),q.enter(M.lineEnding),q.consume(F),q.exit(M.lineEnding),d}function d(F){if(F===K.eof||T(F))return g(F);return q.enter(M.htmlFlowData),Jq(F)}function Qq(F){if(F===K.dash)return q.consume(F),w;return Jq(F)}function Mq(F){if(F===K.slash)return q.consume(F),U="",fq;return Jq(F)}function fq(F){if(F===K.greaterThan){let gq=U.toLowerCase();if(_J.includes(gq))return q.consume(F),uq;return Jq(F)}if(xq(F)&&U.length<C.htmlRawSizeMax)return R(F!==null),q.consume(F),U+=String.fromCharCode(F),fq;return Jq(F)}function aq(F){if(F===K.rightSquareBracket)return q.consume(F),w;return Jq(F)}function w(F){if(F===K.greaterThan)return q.consume(F),uq;if(F===K.dash&&X===C.htmlComment)return q.consume(F),w;return Jq(F)}function uq(F){if(F===K.eof||T(F))return q.exit(M.htmlFlowData),Y1(F);return q.consume(F),uq}function Y1(F){return q.exit(M.htmlFlow),$(F)}}function kW(q,$,J){let G=this;return X;function X(U){if(T(U))return q.enter(M.lineEnding),q.consume(U),q.exit(M.lineEnding),Y;return J(U)}function Y(U){return G.parser.lazy[G.now().line]?J(U):$(U)}}function fW(q,$,J){return G;function G(X){return R(T(X),"expected a line ending"),q.enter(M.lineEnding),q.consume(X),q.exit(M.lineEnding),q.attempt(P1,$,J)}}var IJ={name:"htmlText",tokenize:uW};function uW(q,$,J){let G=this,X,Y,U;return Q;function Q(w){return R(w===K.lessThan,"expected `<`"),q.enter(M.htmlText),q.enter(M.htmlTextData),q.consume(w),V}function V(w){if(w===K.exclamationMark)return q.consume(w),W;if(w===K.slash)return q.consume(w),Gq;if(w===K.questionMark)return q.consume(w),h;if(xq(w))return q.consume(w),Yq;return J(w)}function W(w){if(w===K.dash)return q.consume(w),H;if(w===K.leftSquareBracket)return q.consume(w),Y=0,O;if(xq(w))return q.consume(w),I;return J(w)}function H(w){if(w===K.dash)return q.consume(w),D;return J(w)}function z(w){if(w===K.eof)return J(w);if(w===K.dash)return q.consume(w),B;if(T(w))return U=z,Mq(w);return q.consume(w),z}function B(w){if(w===K.dash)return q.consume(w),D;return z(w)}function D(w){return w===K.greaterThan?Qq(w):w===K.dash?B(w):z(w)}function O(w){let uq=C.cdataOpeningString;if(w===uq.charCodeAt(Y++))return q.consume(w),Y===uq.length?j:O;return J(w)}function j(w){if(w===K.eof)return J(w);if(w===K.rightSquareBracket)return q.consume(w),P;if(T(w))return U=j,Mq(w);return q.consume(w),j}function P(w){if(w===K.rightSquareBracket)return q.consume(w),L;return j(w)}function L(w){if(w===K.greaterThan)return Qq(w);if(w===K.rightSquareBracket)return q.consume(w),L;return j(w)}function I(w){if(w===K.eof||w===K.greaterThan)return Qq(w);if(T(w))return U=I,Mq(w);return q.consume(w),I}function h(w){if(w===K.eof)return J(w);if(w===K.questionMark)return q.consume(w),a;if(T(w))return U=h,Mq(w);return q.consume(w),h}function a(w){return w===K.greaterThan?Qq(w):h(w)}function Gq(w){if(xq(w))return q.consume(w),S;return J(w)}function S(w){if(w===K.dash||Eq(w))return q.consume(w),S;return e(w)}function e(w){if(T(w))return U=e,Mq(w);if(p(w))return q.consume(w),e;return Qq(w)}function Yq(w){if(w===K.dash||Eq(w))return q.consume(w),Yq;if(w===K.slash||w===K.greaterThan||Wq(w))return s(w);return J(w)}function s(w){if(w===K.slash)return q.consume(w),Qq;if(w===K.colon||w===K.underscore||xq(w))return q.consume(w),Xq;if(T(w))return U=s,Mq(w);if(p(w))return q.consume(w),s;return Qq(w)}function Xq(w){if(w===K.dash||w===K.dot||w===K.colon||w===K.underscore||Eq(w))return q.consume(w),Xq;return kq(w)}function kq(w){if(w===K.equalsTo)return q.consume(w),Jq;if(T(w))return U=kq,Mq(w);if(p(w))return q.consume(w),kq;return s(w)}function Jq(w){if(w===K.eof||w===K.lessThan||w===K.equalsTo||w===K.greaterThan||w===K.graveAccent)return J(w);if(w===K.quotationMark||w===K.apostrophe)return q.consume(w),X=w,g;if(T(w))return U=Jq,Mq(w);if(p(w))return q.consume(w),Jq;return q.consume(w),l}function g(w){if(w===X)return q.consume(w),X=void 0,d;if(w===K.eof)return J(w);if(T(w))return U=g,Mq(w);return q.consume(w),g}function l(w){if(w===K.eof||w===K.quotationMark||w===K.apostrophe||w===K.lessThan||w===K.equalsTo||w===K.graveAccent)return J(w);if(w===K.slash||w===K.greaterThan||Wq(w))return s(w);return q.consume(w),l}function d(w){if(w===K.slash||w===K.greaterThan||Wq(w))return s(w);return J(w)}function Qq(w){if(w===K.greaterThan)return q.consume(w),q.exit(M.htmlTextData),q.exit(M.htmlText),$;return J(w)}function Mq(w){return R(U,"expected return state"),R(T(w),"expected eol"),q.exit(M.htmlTextData),q.enter(M.lineEnding),q.consume(w),q.exit(M.lineEnding),fq}function fq(w){return R(G.parser.constructs.disable.null,"expected `disable.null` to be populated"),p(w)?r(q,aq,M.linePrefix,G.parser.constructs.disable.null.includes("codeIndented")?void 0:C.tabSize)(w):aq(w)}function aq(w){return q.enter(M.htmlTextData),U(w)}}var o1={name:"labelEnd",resolveAll:iW,resolveTo:dW,tokenize:cW},pW={tokenize:nW},lW={tokenize:oW},rW={tokenize:aW};function iW(q){let $=-1,J=[];while(++$<q.length){let G=q[$][1];if(J.push(q[$]),G.type===M.labelImage||G.type===M.labelLink||G.type===M.labelEnd){let X=G.type===M.labelImage?4:2;G.type=M.data,$+=X}}if(q.length!==J.length)Fq(q,0,q.length,J);return q}function dW(q,$){let J=q.length,G=0,X,Y,U,Q;while(J--)if(X=q[J][1],Y){if(X.type===M.link||X.type===M.labelLink&&X._inactive)break;if(q[J][0]==="enter"&&X.type===M.labelLink)X._inactive=!0}else if(U){if(q[J][0]==="enter"&&(X.type===M.labelImage||X.type===M.labelLink)&&!X._balanced){if(Y=J,X.type!==M.labelLink){G=2;break}}}else if(X.type===M.labelEnd)U=J;R(Y!==void 0,"`open` is supposed to be found"),R(U!==void 0,"`close` is supposed to be found");let V={type:q[Y][1].type===M.labelLink?M.link:M.image,start:{...q[Y][1].start},end:{...q[q.length-1][1].end}},W={type:M.label,start:{...q[Y][1].start},end:{...q[U][1].end}},H={type:M.labelText,start:{...q[Y+G+2][1].end},end:{...q[U-2][1].start}};return Q=[["enter",V,$],["enter",W,$]],Q=Cq(Q,q.slice(Y+1,Y+G+3)),Q=Cq(Q,[["enter",H,$]]),R($.parser.constructs.insideSpan.null,"expected `insideSpan.null` to be populated"),Q=Cq(Q,v0($.parser.constructs.insideSpan.null,q.slice(Y+G+4,U-3),$)),Q=Cq(Q,[["exit",H,$],q[U-2],q[U-1],["exit",W,$]]),Q=Cq(Q,q.slice(U+1)),Q=Cq(Q,[["exit",V,$]]),Fq(q,Y,q.length,Q),q}function cW(q,$,J){let G=this,X=G.events.length,Y,U;while(X--)if((G.events[X][1].type===M.labelImage||G.events[X][1].type===M.labelLink)&&!G.events[X][1]._balanced){Y=G.events[X][1];break}return Q;function Q(B){if(R(B===K.rightSquareBracket,"expected `]`"),!Y)return J(B);if(Y._inactive)return z(B);return U=G.parser.defined.includes(K1(G.sliceSerialize({start:Y.end,end:G.now()}))),q.enter(M.labelEnd),q.enter(M.labelMarker),q.consume(B),q.exit(M.labelMarker),q.exit(M.labelEnd),V}function V(B){if(B===K.leftParenthesis)return q.attempt(pW,H,U?H:z)(B);if(B===K.leftSquareBracket)return q.attempt(lW,H,U?W:z)(B);return U?H(B):z(B)}function W(B){return q.attempt(rW,H,z)(B)}function H(B){return $(B)}function z(B){return Y._balanced=!0,J(B)}}function nW(q,$,J){return G;function G(z){return R(z===K.leftParenthesis,"expected left paren"),q.enter(M.resource),q.enter(M.resourceMarker),q.consume(z),q.exit(M.resourceMarker),X}function X(z){return Wq(z)?n1(q,Y)(z):Y(z)}function Y(z){if(z===K.rightParenthesis)return H(z);return W3(q,U,Q,M.resourceDestination,M.resourceDestinationLiteral,M.resourceDestinationLiteralMarker,M.resourceDestinationRaw,M.resourceDestinationString,C.linkResourceDestinationBalanceMax)(z)}function U(z){return Wq(z)?n1(q,V)(z):H(z)}function Q(z){return J(z)}function V(z){if(z===K.quotationMark||z===K.apostrophe||z===K.leftParenthesis)return z3(q,W,J,M.resourceTitle,M.resourceTitleMarker,M.resourceTitleString)(z);return H(z)}function W(z){return Wq(z)?n1(q,H)(z):H(z)}function H(z){if(z===K.rightParenthesis)return q.enter(M.resourceMarker),q.consume(z),q.exit(M.resourceMarker),q.exit(M.resource),$;return J(z)}}function oW(q,$,J){let G=this;return X;function X(Q){return R(Q===K.leftSquareBracket,"expected left bracket"),H3.call(G,q,Y,U,M.reference,M.referenceMarker,M.referenceString)(Q)}function Y(Q){return G.parser.defined.includes(K1(G.sliceSerialize(G.events[G.events.length-1][1]).slice(1,-1)))?$(Q):J(Q)}function U(Q){return J(Q)}}function aW(q,$,J){return G;function G(Y){return R(Y===K.leftSquareBracket,"expected left bracket"),q.enter(M.reference),q.enter(M.referenceMarker),q.consume(Y),q.exit(M.referenceMarker),X}function X(Y){if(Y===K.rightSquareBracket)return q.enter(M.referenceMarker),q.consume(Y),q.exit(M.referenceMarker),q.exit(M.reference),$;return J(Y)}}var gJ={name:"labelStartImage",resolveAll:o1.resolveAll,tokenize:sW};function sW(q,$,J){let G=this;return X;function X(Q){return R(Q===K.exclamationMark,"expected `!`"),q.enter(M.labelImage),q.enter(M.labelImageMarker),q.consume(Q),q.exit(M.labelImageMarker),Y}function Y(Q){if(Q===K.leftSquareBracket)return q.enter(M.labelMarker),q.consume(Q),q.exit(M.labelMarker),q.exit(M.labelImage),U;return J(Q)}function U(Q){return Q===K.caret&&"_hiddenFootnoteSupport"in G.parser.constructs?J(Q):$(Q)}}var vJ={name:"labelStartLink",resolveAll:o1.resolveAll,tokenize:tW};function tW(q,$,J){let G=this;return X;function X(U){return R(U===K.leftSquareBracket,"expected `[`"),q.enter(M.labelLink),q.enter(M.labelMarker),q.consume(U),q.exit(M.labelMarker),q.exit(M.labelLink),Y}function Y(U){return U===K.caret&&"_hiddenFootnoteSupport"in G.parser.constructs?J(U):$(U)}}var S$={name:"lineEnding",tokenize:eW};function eW(q,$){return J;function J(G){return R(T(G),"expected eol"),q.enter(M.lineEnding),q.consume(G),q.exit(M.lineEnding),r(q,$,M.linePrefix)}}var a1={name:"thematicBreak",tokenize:qH};function qH(q,$,J){let G=0,X;return Y;function Y(W){return q.enter(M.thematicBreak),U(W)}function U(W){return R(W===K.asterisk||W===K.dash||W===K.underscore,"expected `*`, `-`, or `_`"),X=W,Q(W)}function Q(W){if(W===X)return q.enter(M.thematicBreakSequence),V(W);if(G>=C.thematicBreakMarkerCountMin&&(W===K.eof||T(W)))return q.exit(M.thematicBreak),$(W);return J(W)}function V(W){if(W===X)return q.consume(W),G++,V;return q.exit(M.thematicBreakSequence),p(W)?r(q,Q,M.whitespace)(W):Q(W)}}var Sq={continuation:{tokenize:XH},exit:UH,name:"list",tokenize:GH},$H={partial:!0,tokenize:QH},JH={partial:!0,tokenize:YH};function GH(q,$,J){let G=this,X=G.events[G.events.length-1],Y=X&&X[1].type===M.linePrefix?X[2].sliceSerialize(X[1],!0).length:0,U=0;return Q;function Q(D){R(G.containerState,"expected state");let O=G.containerState.type||(D===K.asterisk||D===K.plusSign||D===K.dash?M.listUnordered:M.listOrdered);if(O===M.listUnordered?!G.containerState.marker||D===G.containerState.marker:O$(D)){if(!G.containerState.type)G.containerState.type=O,q.enter(O,{_container:!0});if(O===M.listUnordered)return q.enter(M.listItemPrefix),D===K.asterisk||D===K.dash?q.check(a1,J,W)(D):W(D);if(!G.interrupt||D===K.digit1)return q.enter(M.listItemPrefix),q.enter(M.listItemValue),V(D)}return J(D)}function V(D){if(R(G.containerState,"expected state"),O$(D)&&++U<C.listItemValueSizeMax)return q.consume(D),V;if((!G.interrupt||U<2)&&(G.containerState.marker?D===G.containerState.marker:D===K.rightParenthesis||D===K.dot))return q.exit(M.listItemValue),W(D);return J(D)}function W(D){return R(G.containerState,"expected state"),R(D!==K.eof,"eof (`null`) is not a marker"),q.enter(M.listItemMarker),q.consume(D),q.exit(M.listItemMarker),G.containerState.marker=G.containerState.marker||D,q.check(P1,G.interrupt?J:H,q.attempt($H,B,z))}function H(D){return R(G.containerState,"expected state"),G.containerState.initialBlankLine=!0,Y++,B(D)}function z(D){if(p(D))return q.enter(M.listItemPrefixWhitespace),q.consume(D),q.exit(M.listItemPrefixWhitespace),B;return J(D)}function B(D){return R(G.containerState,"expected state"),G.containerState.size=Y+G.sliceSerialize(q.exit(M.listItemPrefix),!0).length,$(D)}}function XH(q,$,J){let G=this;return R(G.containerState,"expected state"),G.containerState._closeFlow=void 0,q.check(P1,X,Y);function X(Q){return R(G.containerState,"expected state"),R(typeof G.containerState.size==="number","expected size"),G.containerState.furtherBlankLines=G.containerState.furtherBlankLines||G.containerState.initialBlankLine,r(q,$,M.listItemIndent,G.containerState.size+1)(Q)}function Y(Q){if(R(G.containerState,"expected state"),G.containerState.furtherBlankLines||!p(Q))return G.containerState.furtherBlankLines=void 0,G.containerState.initialBlankLine=void 0,U(Q);return G.containerState.furtherBlankLines=void 0,G.containerState.initialBlankLine=void 0,q.attempt(JH,$,U)(Q)}function U(Q){return R(G.containerState,"expected state"),G.containerState._closeFlow=!0,G.interrupt=void 0,R(G.parser.constructs.disable.null,"expected `disable.null` to be populated"),r(q,q.attempt(Sq,$,J),M.linePrefix,G.parser.constructs.disable.null.includes("codeIndented")?void 0:C.tabSize)(Q)}}function YH(q,$,J){let G=this;return R(G.containerState,"expected state"),R(typeof G.containerState.size==="number","expected size"),r(q,X,M.listItemIndent,G.containerState.size+1);function X(Y){R(G.containerState,"expected state");let U=G.events[G.events.length-1];return U&&U[1].type===M.listItemIndent&&U[2].sliceSerialize(U[1],!0).length===G.containerState.size?$(Y):J(Y)}}function UH(q){R(this.containerState,"expected state"),R(typeof this.containerState.type==="string","expected type"),q.exit(this.containerState.type)}function QH(q,$,J){let G=this;return R(G.parser.constructs.disable.null,"expected `disable.null` to be populated"),r(q,X,M.listItemPrefixWhitespace,G.parser.constructs.disable.null.includes("codeIndented")?void 0:C.tabSize+1);function X(Y){let U=G.events[G.events.length-1];return!p(Y)&&U&&U[1].type===M.listItemPrefixWhitespace?$(Y):J(Y)}}var M3={name:"setextUnderline",resolveTo:VH,tokenize:WH};function VH(q,$){let J=q.length,G,X,Y;while(J--)if(q[J][0]==="enter"){if(q[J][1].type===M.content){G=J;break}if(q[J][1].type===M.paragraph)X=J}else{if(q[J][1].type===M.content)q.splice(J,1);if(!Y&&q[J][1].type===M.definition)Y=J}R(X!==void 0,"expected a `text` index to be found"),R(G!==void 0,"expected a `text` index to be found"),R(q[G][2]===$,"enter context should be same"),R(q[q.length-1][2]===$,"enter context should be same");let U={type:M.setextHeading,start:{...q[G][1].start},end:{...q[q.length-1][1].end}};if(q[X][1].type=M.setextHeadingText,Y)q.splice(X,0,["enter",U,$]),q.splice(Y+1,0,["exit",q[G][1],$]),q[G][1].end={...q[Y][1].end};else q[G][1]=U;return q.push(["exit",U,$]),q}function WH(q,$,J){let G=this,X;return Y;function Y(W){let H=G.events.length,z;R(W===K.dash||W===K.equalsTo,"expected `=` or `-`");while(H--)if(G.events[H][1].type!==M.lineEnding&&G.events[H][1].type!==M.linePrefix&&G.events[H][1].type!==M.content){z=G.events[H][1].type===M.paragraph;break}if(!G.parser.lazy[G.now().line]&&(G.interrupt||z))return q.enter(M.setextHeadingLine),X=W,U(W);return J(W)}function U(W){return q.enter(M.setextHeadingLineSequence),Q(W)}function Q(W){if(W===X)return q.consume(W),Q;return q.exit(M.setextHeadingLineSequence),p(W)?r(q,V,M.lineSuffix)(W):V(W)}function V(W){if(W===K.eof||T(W))return q.exit(M.setextHeadingLine),$(W);return J(W)}}var Y6={tokenize:HH};function HH(q){let $=this,J=q.attempt(P1,G,q.attempt(this.parser.constructs.flowInitial,X,r(q,q.attempt(this.parser.constructs.flow,X,q.attempt(ZJ,X)),M.linePrefix)));return J;function G(Y){if(R(Y===K.eof||T(Y),"expected eol or eof"),Y===K.eof){q.consume(Y);return}return q.enter(M.lineEndingBlank),q.consume(Y),q.exit(M.lineEndingBlank),$.currentConstruct=void 0,J}function X(Y){if(R(Y===K.eof||T(Y),"expected eol or eof"),Y===K.eof){q.consume(Y);return}return q.enter(M.lineEnding),q.consume(Y),q.exit(M.lineEnding),$.currentConstruct=void 0,J}}var U6={resolveAll:H6()},Q6=W6("string"),V6=W6("text");function W6(q){return{resolveAll:H6(q==="text"?zH:void 0),tokenize:$};function $(J){let G=this,X=this.parser.constructs[q],Y=J.attempt(X,U,Q);return U;function U(H){return W(H)?Y(H):Q(H)}function Q(H){if(H===K.eof){J.consume(H);return}return J.enter(M.data),J.consume(H),V}function V(H){if(W(H))return J.exit(M.data),Y(H);return J.consume(H),V}function W(H){if(H===K.eof)return!0;let z=X[H],B=-1;if(z){R(Array.isArray(z),"expected `disable.null` to be populated");while(++B<z.length){let D=z[B];if(!D.previous||D.previous.call(G,G.previous))return!0}}return!1}}}function H6(q){return $;function $(J,G){let X=-1,Y;while(++X<=J.length)if(Y===void 0){if(J[X]&&J[X][1].type===M.data)Y=X,X++}else if(!J[X]||J[X][1].type!==M.data){if(X!==Y+2)J[Y][1].end=J[X-1][1].end,J.splice(Y+2,X-Y-2),X=Y+2;Y=void 0}return q?q(J,G):J}}function zH(q,$){let J=0;while(++J<=q.length)if((J===q.length||q[J][1].type===M.lineEnding)&&q[J-1][1].type===M.data){let G=q[J-1][1],X=$.sliceStream(G),Y=X.length,U=-1,Q=0,V;while(Y--){let W=X[Y];if(typeof W==="string"){U=W.length;while(W.charCodeAt(U-1)===K.space)Q++,U--;if(U)break;U=-1}else if(W===K.horizontalTab)V=!0,Q++;else if(W===K.virtualSpace);else{Y++;break}}if($._contentTypeTextTrailing&&J===q.length)Q=0;if(Q){let W={type:J===q.length||V||Q<C.hardBreakPrefixSizeMin?M.lineSuffix:M.hardBreakTrailing,start:{_bufferIndex:Y?U:G.start._bufferIndex+U,_index:G.start._index+Y,line:G.end.line,column:G.end.column-Q,offset:G.end.offset-Q},end:{...G.end}};if(G.end={...W.start},G.start.offset===G.end.offset)Object.assign(G,W);else q.splice(J,0,["enter",W,$],["exit",W,$]),J+=2}J++}return q}var yJ={};s2(yJ,{text:()=>wH,string:()=>RH,insideSpan:()=>FH,flowInitial:()=>DH,flow:()=>BH,document:()=>MH,disable:()=>AH,contentInitial:()=>KH,attentionMarkers:()=>OH});var MH={[K.asterisk]:Sq,[K.plusSign]:Sq,[K.dash]:Sq,[K.digit0]:Sq,[K.digit1]:Sq,[K.digit2]:Sq,[K.digit3]:Sq,[K.digit4]:Sq,[K.digit5]:Sq,[K.digit6]:Sq,[K.digit7]:Sq,[K.digit8]:Sq,[K.digit9]:Sq,[K.greaterThan]:X3},KH={[K.leftSquareBracket]:CJ},DH={[K.horizontalTab]:N$,[K.virtualSpace]:N$,[K.space]:N$},BH={[K.numberSign]:TJ,[K.asterisk]:a1,[K.dash]:[M3,a1],[K.lessThan]:bJ,[K.equalsTo]:M3,[K.underscore]:a1,[K.graveAccent]:Q3,[K.tilde]:Q3},RH={[K.ampersand]:U3,[K.backslash]:Y3},wH={[K.carriageReturn]:S$,[K.lineFeed]:S$,[K.carriageReturnLineFeed]:S$,[K.exclamationMark]:gJ,[K.ampersand]:U3,[K.asterisk]:A$,[K.lessThan]:[SJ,IJ],[K.leftSquareBracket]:vJ,[K.backslash]:[EJ,Y3],[K.rightSquareBracket]:o1,[K.underscore]:A$,[K.graveAccent]:PJ},FH={null:[A$,U6]},OH={null:[K.asterisk,K.underscore]},AH={null:[]};var Z6=r3(L6(),1);var e1=Z6.default("micromark");function C6(q,$,J){let G={_bufferIndex:-1,_index:0,line:J&&J.line||1,column:J&&J.column||1,offset:J&&J.offset||0},X={},Y=[],U=[],Q=[],V=!0,W={attempt:s(e),check:s(Yq),consume:a,enter:Gq,exit:S,interrupt:s(Yq,{interrupt:!0})},H={code:K.eof,containerState:{},defineSkip:L,events:[],now:P,parser:q,previous:K.eof,sliceSerialize:O,sliceStream:j,write:D},z=$.tokenize.call(H,W),B;if($.resolveAll)Y.push($);return H;function D(g){if(U=Cq(U,g),I(),U[U.length-1]!==K.eof)return[];return Xq($,0),H.events=v0(Y,H.events,H),H.events}function O(g,l){return Xz(j(g),l)}function j(g){return Gz(U,g)}function P(){let{_bufferIndex:g,_index:l,line:d,column:Qq,offset:Mq}=G;return{_bufferIndex:g,_index:l,line:d,column:Qq,offset:Mq}}function L(g){X[g.line]=g.column,Jq(),e1("position: define skip: `%j`",G)}function I(){let g;while(G._index<U.length){let l=U[G._index];if(typeof l==="string"){if(g=G._index,G._bufferIndex<0)G._bufferIndex=0;while(G._index===g&&G._bufferIndex<l.length)h(l.charCodeAt(G._bufferIndex))}else h(l)}}function h(g){R(V===!0,"expected character to be consumed"),V=void 0,e1("main: passing `%s` to %s",g,z&&z.name),B=g,R(typeof z==="function","expected state"),z=z(g)}function a(g){if(R(g===B,"expected given code to equal expected code"),e1("consume: `%s`",g),R(V===void 0,"expected code to not have been consumed: this might be because `return x(code)` instead of `return x` was used"),R(g===null?H.events.length===0||H.events[H.events.length-1][0]==="exit":H.events[H.events.length-1][0]==="enter","expected last token to be open"),T(g))G.line++,G.column=1,G.offset+=g===K.carriageReturnLineFeed?2:1,Jq(),e1("position: after eol: `%j`",G);else if(g!==K.virtualSpace)G.column++,G.offset++;if(G._bufferIndex<0)G._index++;else if(G._bufferIndex++,G._bufferIndex===U[G._index].length)G._bufferIndex=-1,G._index++;H.previous=g,V=!0}function Gq(g,l){let d=l||{};return d.type=g,d.start=P(),R(typeof g==="string","expected string type"),R(g.length>0,"expected non-empty string"),e1("enter: `%s`",g),H.events.push(["enter",d,H]),Q.push(d),d}function S(g){R(typeof g==="string","expected string type"),R(g.length>0,"expected non-empty string");let l=Q.pop();return R(l,"cannot close w/o open tokens"),l.end=P(),R(g===l.type,"expected exit token to match current token"),R(!(l.start._index===l.end._index&&l.start._bufferIndex===l.end._bufferIndex),"expected non-empty token (`"+g+"`)"),e1("exit: `%s`",l.type),H.events.push(["exit",l,H]),l}function e(g,l){Xq(g,l.from)}function Yq(g,l){l.restore()}function s(g,l){return d;function d(Qq,Mq,fq){let aq,w,uq,Y1;return Array.isArray(Qq)?gq(Qq):("tokenize"in Qq)?gq([Qq]):F(Qq);function F(Kq){return c0;function c0(U1){let I1=U1!==null&&Kq[U1],U0=U1!==null&&Kq.null,p3=[...Array.isArray(I1)?I1:I1?[I1]:[],...Array.isArray(U0)?U0:U0?[U0]:[]];return gq(p3)(U1)}}function gq(Kq){if(aq=Kq,w=0,Kq.length===0)return R(fq,"expected `bogusState` to be given"),fq;return b1(Kq[w])}function b1(Kq){return c0;function c0(U1){if(Y1=kq(),uq=Kq,!Kq.partial)H.currentConstruct=Kq;if(R(H.parser.constructs.disable.null,"expected `disable.null` to be populated"),Kq.name&&H.parser.constructs.disable.null.includes(Kq.name))return g$(U1);return Kq.tokenize.call(l?Object.assign(Object.create(H),l):H,W,u3,g$)(U1)}}function u3(Kq){return R(Kq===B,"expected code"),V=!0,g(uq,Y1),Mq}function g$(Kq){if(R(Kq===B,"expected code"),V=!0,Y1.restore(),++w<aq.length)return b1(aq[w]);return fq}}}function Xq(g,l){if(g.resolveAll&&!Y.includes(g))Y.push(g);if(g.resolve)Fq(H.events,l,H.events.length-l,g.resolve(H.events.slice(l),H));if(g.resolveTo)H.events=g.resolveTo(H.events,H);R(g.partial||H.events.length===0||H.events[H.events.length-1][0]==="exit","expected last token to end")}function kq(){let g=P(),l=H.previous,d=H.currentConstruct,Qq=H.events.length,Mq=Array.from(Q);return{from:Qq,restore:fq};function fq(){G=g,H.previous=l,H.currentConstruct=d,H.events.length=Qq,Q=Mq,Jq(),e1("position: restore: `%j`",G)}}function Jq(){if(G.line in X&&G.column<2)G.column=X[G.line],G.offset+=X[G.line]-1}}function Gz(q,$){let J=$.start._index,G=$.start._bufferIndex,X=$.end._index,Y=$.end._bufferIndex,U;if(J===X)R(Y>-1,"expected non-negative end buffer index"),R(G>-1,"expected non-negative start buffer index"),U=[q[J].slice(G,Y)];else{if(U=q.slice(J,X),G>-1){let Q=U[0];if(typeof Q==="string")U[0]=Q.slice(G);else R(G===0,"expected `startBufferIndex` to be `0`"),U.shift()}if(Y>0)U.push(q[X].slice(0,Y))}return U}function Xz(q,$){let J=-1,G=[],X;while(++J<q.length){let Y=q[J],U;if(typeof Y==="string")U=Y;else switch(Y){case K.carriageReturn:{U=hq.cr;break}case K.lineFeed:{U=hq.lf;break}case K.carriageReturnLineFeed:{U=hq.cr+hq.lf;break}case K.horizontalTab:{U=$?hq.space:hq.ht;break}case K.virtualSpace:{if(!$&&X)continue;U=hq.space;break}default:R(typeof Y==="number","expected number"),U=String.fromCharCode(Y)}X=Y===K.horizontalTab,G.push(U)}return G.join("")}function fJ(q){let G={constructs:d9([yJ,...(q||{}).extensions||[]]),content:X(t9),defined:[],document:X(q6),flow:X(Y6),lazy:{},string:X(Q6),text:X(V6)};return G;function X(Y){return U;function U(Q){return C6(G,Y,Q)}}}function uJ(q){while(!V3(q));return q}var E6=/[\0\t\n\r]/g;function pJ(){let q=1,$="",J=!0,G;return X;function X(Y,U,Q){let V=[],W,H,z,B,D;if(Y=$+(typeof Y==="string"?Y.toString():new TextDecoder(U||void 0).decode(Y)),z=0,$="",J){if(Y.charCodeAt(0)===K.byteOrderMarker)z++;J=void 0}while(z<Y.length){if(E6.lastIndex=z,W=E6.exec(Y),B=W&&W.index!==void 0?W.index:Y.length,D=Y.charCodeAt(B),!W){$=Y.slice(z);break}if(D===K.lf&&z===B&&G)V.push(K.carriageReturnLineFeed),G=void 0;else{if(G)V.push(K.carriageReturn),G=void 0;if(z<B)V.push(Y.slice(z,B)),q+=B-z;switch(D){case K.nul:{V.push(K.replacementCharacter),q++;break}case K.ht:{H=Math.ceil(q/C.tabSize)*C.tabSize,V.push(K.horizontalTab);while(q++<H)V.push(K.virtualSpace);break}case K.lf:{V.push(K.lineFeed),q=1;break}default:G=!0,q=1}}z=B+1}if(Q){if(G)V.push(K.carriageReturn);if($)V.push($);V.push(K.eof)}return V}}var Yz=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function w3(q){return q.replace(Yz,Uz)}function Uz(q,$,J){if($)return $;if(J.charCodeAt(0)===K.numberSign){let X=J.charCodeAt(1),Y=X===K.lowercaseX||X===K.uppercaseX;return G3(J.slice(Y?2:1),Y?C.numericBaseHexadecimal:C.numericBaseDecimal)}return I0(J)||q}function Z1(q){if(!q||typeof q!=="object")return"";if("position"in q||"type"in q)return T6(q.position);if("start"in q||"end"in q)return T6(q);if("line"in q||"column"in q)return lJ(q);return""}function lJ(q){return _6(q&&q.line)+":"+_6(q&&q.column)}function T6(q){return lJ(q&&q.start)+"-"+lJ(q&&q.end)}function _6(q){return q&&typeof q==="number"?q:1}var I6={}.hasOwnProperty;function rJ(q,$,J){if($&&typeof $==="object")J=$,$=void 0;return Qz(J)(uJ(fJ(J).document().write(pJ()(q,$,!0))))}function Qz(q){let $={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:Y(o2),autolinkProtocol:s,autolinkEmail:s,atxHeading:Y(d2),blockQuote:Y(U1),characterEscape:s,characterReference:s,codeFenced:Y(I1),codeFencedFenceInfo:U,codeFencedFenceMeta:U,codeIndented:Y(I1,U),codeText:Y(U0,U),codeTextData:s,data:s,codeFlowValue:s,definition:Y(p3),definitionDestinationString:U,definitionLabelString:U,definitionTitleString:U,emphasis:Y(u7),hardBreakEscape:Y(c2),hardBreakTrailing:Y(c2),htmlFlow:Y(n2,U),htmlFlowData:s,htmlText:Y(n2,U),htmlTextData:s,image:Y(p7),label:U,link:Y(o2),listItem:Y(l7),listItemValue:B,listOrdered:Y(a2,z),listUnordered:Y(a2),paragraph:Y(r7),reference:F,referenceString:U,resourceDestinationString:U,resourceTitleString:U,setextHeading:Y(d2),strong:Y(i7),thematicBreak:Y(c7)},exit:{atxHeading:V(),atxHeadingSequence:Gq,autolink:V(),autolinkEmail:c0,autolinkProtocol:Kq,blockQuote:V(),characterEscapeValue:Xq,characterReferenceMarkerHexadecimal:b1,characterReferenceMarkerNumeric:b1,characterReferenceValue:u3,characterReference:g$,codeFenced:V(P),codeFencedFence:j,codeFencedFenceInfo:D,codeFencedFenceMeta:O,codeFlowValue:Xq,codeIndented:V(L),codeText:V(d),codeTextData:Xq,data:Xq,definition:V(),definitionDestinationString:a,definitionLabelString:I,definitionTitleString:h,emphasis:V(),hardBreakEscape:V(Jq),hardBreakTrailing:V(Jq),htmlFlow:V(g),htmlFlowData:Xq,htmlText:V(l),htmlTextData:Xq,image:V(Mq),label:aq,labelText:fq,lineEnding:kq,link:V(Qq),listItem:V(),listOrdered:V(),listUnordered:V(),paragraph:V(),referenceString:gq,resourceDestinationString:w,resourceTitleString:uq,resource:Y1,setextHeading:V(Yq),setextHeadingLineSequence:e,setextHeadingText:S,strong:V(),thematicBreak:V()}};g6($,(q||{}).mdastExtensions||[]);let J={};return G;function G(A){let N={type:"root",children:[]},v={stack:[N],tokenStack:[],config:$,enter:Q,exit:W,buffer:U,resume:H,data:J},n=[],t=-1;while(++t<A.length)if(A[t][1].type===M.listOrdered||A[t][1].type===M.listUnordered)if(A[t][0]==="enter")n.push(t);else{let Tq=n.pop();R(typeof Tq==="number","expected list to be open"),t=X(A,Tq,t)}t=-1;while(++t<A.length){let Tq=$[A[t][0]];if(I6.call(Tq,A[t][1].type))Tq[A[t][1].type].call(Object.assign({sliceSerialize:A[t][2].sliceSerialize},v),A[t][1])}if(v.tokenStack.length>0){let Tq=v.tokenStack[v.tokenStack.length-1];(Tq[1]||b6).call(v,void 0,Tq[0])}N.position={start:C1(A.length>0?A[0][1].start:{line:1,column:1,offset:0}),end:C1(A.length>0?A[A.length-2][1].end:{line:1,column:1,offset:0})},t=-1;while(++t<$.transforms.length)N=$.transforms[t](N)||N;return N}function X(A,N,v){let n=N-1,t=-1,Tq=!1,g1,Q1,n0,o0;while(++n<=v){let vq=A[n];switch(vq[1].type){case M.listUnordered:case M.listOrdered:case M.blockQuote:{if(vq[0]==="enter")t++;else t--;o0=void 0;break}case M.lineEndingBlank:{if(vq[0]==="enter"){if(g1&&!o0&&!t&&!n0)n0=n;o0=void 0}break}case M.linePrefix:case M.listItemValue:case M.listItemMarker:case M.listItemPrefix:case M.listItemPrefixWhitespace:break;default:o0=void 0}if(!t&&vq[0]==="enter"&&vq[1].type===M.listItemPrefix||t===-1&&vq[0]==="exit"&&(vq[1].type===M.listUnordered||vq[1].type===M.listOrdered)){if(g1){let Q0=n;Q1=void 0;while(Q0--){let V1=A[Q0];if(V1[1].type===M.lineEnding||V1[1].type===M.lineEndingBlank){if(V1[0]==="exit")continue;if(Q1)A[Q1][1].type=M.lineEndingBlank,Tq=!0;V1[1].type=M.lineEnding,Q1=Q0}else if(V1[1].type===M.linePrefix||V1[1].type===M.blockQuotePrefix||V1[1].type===M.blockQuotePrefixWhitespace||V1[1].type===M.blockQuoteMarker||V1[1].type===M.listItemIndent);else break}if(n0&&(!Q1||n0<Q1))g1._spread=!0;g1.end=Object.assign({},Q1?A[Q1][1].start:vq[1].end),A.splice(Q1||n,0,["exit",g1,vq[2]]),n++,v++}if(vq[1].type===M.listItemPrefix){let Q0={type:"listItem",_spread:!1,start:Object.assign({},vq[1].start),end:void 0};g1=Q0,A.splice(n,0,["enter",Q0,vq[2]]),n++,v++,n0=void 0,o0=!0}}}return A[N][1]._spread=Tq,v}function Y(A,N){return v;function v(n){if(Q.call(this,A(n),n),N)N.call(this,n)}}function U(){this.stack.push({type:"fragment",children:[]})}function Q(A,N,v){let n=this.stack[this.stack.length-1];R(n,"expected `parent`"),R("children"in n,"expected `parent`"),n.children.push(A),this.stack.push(A),this.tokenStack.push([N,v||void 0]),A.position={start:C1(N.start),end:void 0}}function V(A){return N;function N(v){if(A)A.call(this,v);W.call(this,v)}}function W(A,N){let v=this.stack.pop();R(v,"expected `node`");let n=this.tokenStack.pop();if(!n)throw Error("Cannot close `"+A.type+"` ("+Z1({start:A.start,end:A.end})+"): it\u2019s not open");else if(n[0].type!==A.type)if(N)N.call(this,A,n[0]);else(n[1]||b6).call(this,A,n[0]);R(v.type!=="fragment","unexpected fragment `exit`ed"),R(v.position,"expected `position` to be defined"),v.position.end=C1(A.end)}function H(){return c1(this.stack.pop())}function z(){this.data.expectingFirstListItemValue=!0}function B(A){if(this.data.expectingFirstListItemValue){let N=this.stack[this.stack.length-2];R(N,"expected nodes on stack"),R(N.type==="list","expected list on stack"),N.start=Number.parseInt(this.sliceSerialize(A),C.numericBaseDecimal),this.data.expectingFirstListItemValue=void 0}}function D(){let A=this.resume(),N=this.stack[this.stack.length-1];R(N,"expected node on stack"),R(N.type==="code","expected code on stack"),N.lang=A}function O(){let A=this.resume(),N=this.stack[this.stack.length-1];R(N,"expected node on stack"),R(N.type==="code","expected code on stack"),N.meta=A}function j(){if(this.data.flowCodeInside)return;this.buffer(),this.data.flowCodeInside=!0}function P(){let A=this.resume(),N=this.stack[this.stack.length-1];R(N,"expected node on stack"),R(N.type==="code","expected code on stack"),N.value=A.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function L(){let A=this.resume(),N=this.stack[this.stack.length-1];R(N,"expected node on stack"),R(N.type==="code","expected code on stack"),N.value=A.replace(/(\r?\n|\r)$/g,"")}function I(A){let N=this.resume(),v=this.stack[this.stack.length-1];R(v,"expected node on stack"),R(v.type==="definition","expected definition on stack"),v.label=N,v.identifier=K1(this.sliceSerialize(A)).toLowerCase()}function h(){let A=this.resume(),N=this.stack[this.stack.length-1];R(N,"expected node on stack"),R(N.type==="definition","expected definition on stack"),N.title=A}function a(){let A=this.resume(),N=this.stack[this.stack.length-1];R(N,"expected node on stack"),R(N.type==="definition","expected definition on stack"),N.url=A}function Gq(A){let N=this.stack[this.stack.length-1];if(R(N,"expected node on stack"),R(N.type==="heading","expected heading on stack"),!N.depth){let v=this.sliceSerialize(A).length;R(v===1||v===2||v===3||v===4||v===5||v===6,"expected `depth` between `1` and `6`"),N.depth=v}}function S(){this.data.setextHeadingSlurpLineEnding=!0}function e(A){let N=this.stack[this.stack.length-1];R(N,"expected node on stack"),R(N.type==="heading","expected heading on stack"),N.depth=this.sliceSerialize(A).codePointAt(0)===K.equalsTo?1:2}function Yq(){this.data.setextHeadingSlurpLineEnding=void 0}function s(A){let N=this.stack[this.stack.length-1];R(N,"expected node on stack"),R("children"in N,"expected parent on stack");let v=N.children,n=v[v.length-1];if(!n||n.type!=="text")n=d7(),n.position={start:C1(A.start),end:void 0},v.push(n);this.stack.push(n)}function Xq(A){let N=this.stack.pop();R(N,"expected a `node` to be on the stack"),R("value"in N,"expected a `literal` to be on the stack"),R(N.position,"expected `node` to have an open position"),N.value+=this.sliceSerialize(A),N.position.end=C1(A.end)}function kq(A){let N=this.stack[this.stack.length-1];if(R(N,"expected `node`"),this.data.atHardBreak){R("children"in N,"expected `parent`");let v=N.children[N.children.length-1];R(v.position,"expected tail to have a starting position"),v.position.end=C1(A.end),this.data.atHardBreak=void 0;return}if(!this.data.setextHeadingSlurpLineEnding&&$.canContainEols.includes(N.type))s.call(this,A),Xq.call(this,A)}function Jq(){this.data.atHardBreak=!0}function g(){let A=this.resume(),N=this.stack[this.stack.length-1];R(N,"expected node on stack"),R(N.type==="html","expected html on stack"),N.value=A}function l(){let A=this.resume(),N=this.stack[this.stack.length-1];R(N,"expected node on stack"),R(N.type==="html","expected html on stack"),N.value=A}function d(){let A=this.resume(),N=this.stack[this.stack.length-1];R(N,"expected node on stack"),R(N.type==="inlineCode","expected inline code on stack"),N.value=A}function Qq(){let A=this.stack[this.stack.length-1];if(R(A,"expected node on stack"),R(A.type==="link","expected link on stack"),this.data.inReference){let N=this.data.referenceType||"shortcut";A.type+="Reference",A.referenceType=N,delete A.url,delete A.title}else delete A.identifier,delete A.label;this.data.referenceType=void 0}function Mq(){let A=this.stack[this.stack.length-1];if(R(A,"expected node on stack"),R(A.type==="image","expected image on stack"),this.data.inReference){let N=this.data.referenceType||"shortcut";A.type+="Reference",A.referenceType=N,delete A.url,delete A.title}else delete A.identifier,delete A.label;this.data.referenceType=void 0}function fq(A){let N=this.sliceSerialize(A),v=this.stack[this.stack.length-2];R(v,"expected ancestor on stack"),R(v.type==="image"||v.type==="link","expected image or link on stack"),v.label=w3(N),v.identifier=K1(N).toLowerCase()}function aq(){let A=this.stack[this.stack.length-1];R(A,"expected node on stack"),R(A.type==="fragment","expected fragment on stack");let N=this.resume(),v=this.stack[this.stack.length-1];if(R(v,"expected node on stack"),R(v.type==="image"||v.type==="link","expected image or link on stack"),this.data.inReference=!0,v.type==="link"){let n=A.children;v.children=n}else v.alt=N}function w(){let A=this.resume(),N=this.stack[this.stack.length-1];R(N,"expected node on stack"),R(N.type==="image"||N.type==="link","expected image or link on stack"),N.url=A}function uq(){let A=this.resume(),N=this.stack[this.stack.length-1];R(N,"expected node on stack"),R(N.type==="image"||N.type==="link","expected image or link on stack"),N.title=A}function Y1(){this.data.inReference=void 0}function F(){this.data.referenceType="collapsed"}function gq(A){let N=this.resume(),v=this.stack[this.stack.length-1];R(v,"expected node on stack"),R(v.type==="image"||v.type==="link","expected image reference or link reference on stack"),v.label=N,v.identifier=K1(this.sliceSerialize(A)).toLowerCase(),this.data.referenceType="full"}function b1(A){R(A.type==="characterReferenceMarkerNumeric"||A.type==="characterReferenceMarkerHexadecimal"),this.data.characterReferenceType=A.type}function u3(A){let N=this.sliceSerialize(A),v=this.data.characterReferenceType,n;if(v)n=G3(N,v===M.characterReferenceMarkerNumeric?C.numericBaseDecimal:C.numericBaseHexadecimal),this.data.characterReferenceType=void 0;else{let Tq=I0(N);R(Tq!==!1,"expected reference to decode"),n=Tq}let t=this.stack[this.stack.length-1];R(t,"expected `node`"),R("value"in t,"expected `node.value`"),t.value+=n}function g$(A){let N=this.stack.pop();R(N,"expected `node`"),R(N.position,"expected `node.position`"),N.position.end=C1(A.end)}function Kq(A){Xq.call(this,A);let N=this.stack[this.stack.length-1];R(N,"expected node on stack"),R(N.type==="link","expected link on stack"),N.url=this.sliceSerialize(A)}function c0(A){Xq.call(this,A);let N=this.stack[this.stack.length-1];R(N,"expected node on stack"),R(N.type==="link","expected link on stack"),N.url="mailto:"+this.sliceSerialize(A)}function U1(){return{type:"blockquote",children:[]}}function I1(){return{type:"code",lang:null,meta:null,value:""}}function U0(){return{type:"inlineCode",value:""}}function p3(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function u7(){return{type:"emphasis",children:[]}}function d2(){return{type:"heading",depth:0,children:[]}}function c2(){return{type:"break"}}function n2(){return{type:"html",value:""}}function p7(){return{type:"image",title:null,url:"",alt:null}}function o2(){return{type:"link",title:null,url:"",children:[]}}function a2(A){return{type:"list",ordered:A.type==="listOrdered",start:null,spread:A._spread,children:[]}}function l7(A){return{type:"listItem",spread:A._spread,checked:null,children:[]}}function r7(){return{type:"paragraph",children:[]}}function i7(){return{type:"strong",children:[]}}function d7(){return{type:"text",value:""}}function c7(){return{type:"thematicBreak"}}}function C1(q){return{line:q.line,column:q.column,offset:q.offset}}function g6(q,$){let J=-1;while(++J<$.length){let G=$[J];if(Array.isArray(G))g6(q,G);else Vz(q,G)}}function Vz(q,$){let J;for(J in $)if(I6.call($,J))switch(J){case"canContainEols":{let G=$[J];if(G)q[J].push(...G);break}case"transforms":{let G=$[J];if(G)q[J].push(...G);break}case"enter":case"exit":{let G=$[J];if(G)Object.assign(q[J],G);break}}}function b6(q,$){if(q)throw Error("Cannot close `"+q.type+"` ("+Z1({start:q.start,end:q.end})+"): a different token (`"+$.type+"`, "+Z1({start:$.start,end:$.end})+") is open");else throw Error("Cannot close document, a token (`"+$.type+"`, "+Z1({start:$.start,end:$.end})+") is still open")}function F3(q){let $=this;$.parser=J;function J(G){return rJ(G,{...$.data("settings"),...q,extensions:$.data("micromarkExtensions")||[],mdastExtensions:$.data("fromMarkdownExtensions")||[]})}}var v6={}.hasOwnProperty;function y6(q,$){let J=$||{};function G(X,...Y){let{invalid:U,handlers:Q}=G;if(X&&v6.call(X,q)){let V=String(X[q]);U=v6.call(Q,V)?Q[V]:G.unknown}if(U)return U.call(this,X,...Y)}return G.handlers=J.handlers||{},G.invalid=J.invalid,G.unknown=J.unknown,G}var Wz={}.hasOwnProperty;function iJ(q,$){let J=-1,G;if($.extensions)while(++J<$.extensions.length)iJ(q,$.extensions[J]);for(G in $)if(Wz.call($,G))switch(G){case"extensions":break;case"unsafe":{h6(q[G],$[G]);break}case"join":{h6(q[G],$[G]);break}case"handlers":{Hz(q[G],$[G]);break}default:q.options[G]=$[G]}return q}function h6(q,$){if($)q.push(...$)}function Hz(q,$){if($)Object.assign(q,$)}function x6(q,$,J,G){let X=J.enter("blockquote"),Y=J.createTracker(G);Y.move("> "),Y.shift(2);let U=J.indentLines(J.containerFlow(q,Y.current()),zz);return X(),U}function zz(q,$,J){return">"+(J?"":" ")+q}function O3(q,$){return m6(q,$.inConstruct,!0)&&!m6(q,$.notInConstruct,!1)}function m6(q,$,J){if(typeof $==="string")$=[$];if(!$||$.length===0)return J;let G=-1;while(++G<$.length)if(q.includes($[G]))return!0;return!1}function dJ(q,$,J,G){let X=-1;while(++X<J.unsafe.length)if(J.unsafe[X].character===`
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
`),Y)H
|
|
108
|
-
|
|
109
|
-
|
|
150
|
+
`+I),$.push(q+"m+"+EX.exports.humanize(this.diff)+"\x1B[0m")}else $[0]=hl()+U+" "+$[0]}function hl(){if(jB.inspectOpts.hideDate)return"";return new Date().toISOString()+" "}function rl(...$){return process.stderr.write(LX.formatWithOptions(jB.inspectOpts,...$)+`
|
|
151
|
+
`)}function ll($){if($)process.env.DEBUG=$;else delete process.env.DEBUG}function il(){return process.env.DEBUG}function pl($){$.inspectOpts={};let U=Object.keys(jB.inspectOpts);for(let J=0;J<U.length;J++)$.inspectOpts[U[J]]=jB.inspectOpts[U[J]]}EX.exports=SN()(jB);var{formatters:gB}=EX.exports;gB.o=function($){return this.inspectOpts.colors=this.useColors,LX.inspect($,this.inspectOpts).split(`
|
|
152
|
+
`).map((U)=>U.trim()).join(" ")};gB.O=function($){return this.inspectOpts.colors=this.useColors,LX.inspect($,this.inspectOpts)}});var SB=J$((dV$,CN)=>{if(typeof process>"u"||process.type==="renderer"||!1||process.__nwjs)CN.exports=MB();else CN.exports=BB()});var PS=J$((TZ$,jS)=>{var yX=Object.prototype.hasOwnProperty,gS=Object.prototype.toString,MS=Object.defineProperty,HS=Object.getOwnPropertyDescriptor,TS=function(U){if(typeof Array.isArray==="function")return Array.isArray(U);return gS.call(U)==="[object Array]"},zS=function(U){if(!U||gS.call(U)!=="[object Object]")return!1;var J=yX.call(U,"constructor"),G=U.constructor&&U.constructor.prototype&&yX.call(U.constructor.prototype,"isPrototypeOf");if(U.constructor&&!J&&!G)return!1;var q;for(q in U);return typeof q>"u"||yX.call(U,q)},AS=function(U,J){if(MS&&J.name==="__proto__")MS(U,J.name,{enumerable:!0,configurable:!0,value:J.newValue,writable:!0});else U[J.name]=J.newValue},KS=function(U,J){if(J==="__proto__"){if(!yX.call(U,J))return;else if(HS)return HS(U,J).value}return U[J]};jS.exports=function $(){var U,J,G,q,I,Q,D=arguments[0],X=1,Y=arguments.length,V=!1;if(typeof D==="boolean")V=D,D=arguments[1]||{},X=2;if(D==null||typeof D!=="object"&&typeof D!=="function")D={};for(;X<Y;++X)if(U=arguments[X],U!=null){for(J in U)if(G=KS(D,J),q=KS(U,J),D!==q){if(V&&q&&(zS(q)||(I=TS(q)))){if(I)I=!1,Q=G&&TS(G)?G:[];else Q=G&&zS(G)?G:{};AS(D,{name:J,newValue:$(V,Q,q)})}else if(typeof q<"u")AS(D,{name:J,newValue:q})}}return D}});function X5($,U){let J=$.indexOf("/");if(J===-1)return{org:U,name:$};return{org:$.slice(0,J),name:$.slice(J+1)}}function lS($,U){let{org:J,name:G}=X5($,U);return`${J}/${G}`}function dX($){return async(U)=>({brainYaml:Mp(U,$),envFile:jp(U,$),contentRepoFiles:Kp(U)})}function Mp($,U){let J=["brain: brain",`kind: ${$.profileKind??"professional"}`,`domain: ${$.domain}`,"bundles:",...$.bundles.map((G)=>` - ${G}`),...$.embeddingEnabled!==void 0?["","embedding:",` enabled: ${String($.embeddingEnabled)}`]:[],...cS("add",$.add),...cS("remove",$.remove),...Tp($),"",Ap($),"","plugins:",...$.setup?.delivery==="email"?[" auth-service:",...zp($.setup.email)," notifications:"," defaultRecipient:"," type: email",` address: ${$.setup.email}`]:[],...$.playbooks?.onboarding?[" onboarding:"," enabled: true"]:[],...$.topicExtractionEnabled!==void 0?[" topics:",` enableAutoExtraction: ${String($.topicExtractionEnabled)}`]:[]," directory-sync:"," git:",` repo: ${aS($,U)}`," authToken: ${GIT_SYNC_TOKEN}",...$.atproto?[" atproto:",` identifier: ${$.atproto.identifier}`,...$.atproto.accountDid?[` accountDid: ${$.atproto.accountDid}`]:[],...$.atproto.lexiconAuthority!==void 0?[` lexiconAuthority: ${String($.atproto.lexiconAuthority)}`]:[],...Hp($.atproto.jetstream)," appPassword: ${ATPROTO_APP_PASSWORD}"]:[]];if($.setup?.delivery==="email")J.push(" email:"),J.push(" transport: resend"),J.push(" apiKey: ${SETUP_EMAIL_API_KEY}"),J.push(" from: ${SETUP_EMAIL_FROM}");return J.push(""),J.join(`
|
|
153
|
+
`)}function Hp($){if(!$)return[];return[" jetstream:",...pG($).trimEnd().split(`
|
|
154
|
+
`).map((J)=>` ${J}`)]}function cS($,U){if(U.length===0)return[];return["",`${$}:`,...U.map((J)=>` - ${J}`)]}function Tp($){if(!$.siteOverride)return[];return["","site:",` package: ${oS($.siteOverride.package)}`,...$.siteOverride.theme?[` theme: ${oS($.siteOverride.theme)}`]:[]]}function oS($){return JSON.stringify($)}function aS($,U){return lS($.contentRepo,U)}function zp($){return[" setupEmail:",` to: ${$}`," subject: Welcome to Rover \u2014 set up your passkey"," body: |"," Hi,",""," Your Rover is ready.",""," Rover is your own AI \u2014 a private assistant deployed just for you, that holds your notes, links, and ideas, and gets more useful the more you put into it.",""," Set up your passkey:"," {{setupUrl}}",""," This link is single-use. Do not forward it."," It expires at {{expiresAt}}.",""," After setup, open your chat and say hello:"," {{origin}}/chat",""," Sign in with the passkey you just registered. The chat in your browser is where you and Rover will spend most of your time.",""," The onboarding guide shows the way of working \u2014 capture, ask back, shape:"," https://github.com/rizom-ai/brains/blob/main/packages/brains-ops/templates/rover-pilot/docs/user-onboarding.md",""," If this link is expired, does not work, or you did not expect this email, reply to your Rover operator and we will help."]}function Ap($){if($.discordEnabled&&$.discordAnchorUserId)return`anchors: ["discord:${$.discordAnchorUserId}"]`;return"anchors: []"}function Kp($){return[{path:"anchor-profile/anchor-profile.md",content:gp($)}]}function gp($){let U={name:$.anchorProfile.name,...$.anchorProfile.description?{description:$.anchorProfile.description}:{},...$.anchorProfile.website?{website:$.anchorProfile.website}:{},...$.anchorProfile.email?{email:$.anchorProfile.email}:{},...$.anchorProfile.socialLinks?{socialLinks:$.anchorProfile.socialLinks}:{}},J=$.anchorProfile.story??"This profile was initialized by brains-ops. Edit it in your content repo.";return`---
|
|
155
|
+
${pG(U).trimEnd()}
|
|
156
|
+
---
|
|
157
|
+
|
|
158
|
+
${J}
|
|
159
|
+
`}function jp($,U){return[`BRAIN_VERSION=${$.brainVersion}`,`CONTENT_REPO=${aS($,U)}`,""].join(`
|
|
160
|
+
`)}var Y5=O$(()=>{vq()});var cC={};UU(cC,{upgradePilotRepo:()=>Ia});import{readFile as Ua}from"fs/promises";import{join as Ja}from"path";async function nC($){let U=Ja($,"package.json"),G=qa.parse(JSON.parse(await Ua(U,"utf8"))).devDependencies?.["@rizom/ops"];if(!G)throw Error(`${U} does not pin @rizom/ops as a devDependency`);return G}async function Ga($,U){let G=await Bun.spawn($,{cwd:U,stdout:"inherit",stderr:"inherit"}).exited;if(G!==0)throw Error(`${$.join(" ")} failed with exit ${G}`)}async function Ia($,U={}){let J=U.exec??Ga,G=await nC($),q=U.version??"latest";await J(["bun","add","--dev","--exact",`@rizom/ops@${q}`],$);let I=await nC($);return await J(["bun","x","brains-ops","init","."],$),{from:G,to:I}}var qa;var oC=O$(()=>{b$();qa=N.object({devDependencies:N.record(N.string(),N.string()).optional()})});var x$=J$((Za)=>{var wM=Symbol.for("yaml.alias"),aC=Symbol.for("yaml.document"),o9=Symbol.for("yaml.map"),sC=Symbol.for("yaml.pair"),MM=Symbol.for("yaml.scalar"),a9=Symbol.for("yaml.seq"),bJ=Symbol.for("yaml.node.type"),Qa=($)=>!!$&&typeof $==="object"&&$[bJ]===wM,Da=($)=>!!$&&typeof $==="object"&&$[bJ]===aC,Xa=($)=>!!$&&typeof $==="object"&&$[bJ]===o9,Ya=($)=>!!$&&typeof $==="object"&&$[bJ]===sC,tC=($)=>!!$&&typeof $==="object"&&$[bJ]===MM,Va=($)=>!!$&&typeof $==="object"&&$[bJ]===a9;function eC($){if($&&typeof $==="object")switch($[bJ]){case o9:case a9:return!0}return!1}function Wa($){if($&&typeof $==="object")switch($[bJ]){case wM:case o9:case MM:case a9:return!0}return!1}var Oa=($)=>(tC($)||eC($))&&!!$.anchor;Za.ALIAS=wM;Za.DOC=aC;Za.MAP=o9;Za.NODE_TYPE=bJ;Za.PAIR=sC;Za.SCALAR=MM;Za.SEQ=a9;Za.hasAnchor=Oa;Za.isAlias=Qa;Za.isCollection=eC;Za.isDocument=Da;Za.isMap=Xa;Za.isNode=Wa;Za.isPair=Ya;Za.isScalar=tC;Za.isSeq=Va});var FI=J$((Ca)=>{var W0=x$(),XU=Symbol("break visit"),$_=Symbol("skip children"),XJ=Symbol("remove node");function s9($,U){let J=U_(U);if(W0.isDocument($)){if(H6(null,$.contents,J,Object.freeze([$]))===XJ)$.contents=null}else H6(null,$,J,Object.freeze([]))}s9.BREAK=XU;s9.SKIP=$_;s9.REMOVE=XJ;function H6($,U,J,G){let q=J_($,U,J,G);if(W0.isNode(q)||W0.isPair(q))return q_($,G,q),H6($,q,J,G);if(typeof q!=="symbol"){if(W0.isCollection(U)){G=Object.freeze(G.concat(U));for(let I=0;I<U.items.length;++I){let Q=H6(I,U.items[I],J,G);if(typeof Q==="number")I=Q-1;else if(Q===XU)return XU;else if(Q===XJ)U.items.splice(I,1),I-=1}}else if(W0.isPair(U)){G=Object.freeze(G.concat(U));let I=H6("key",U.key,J,G);if(I===XU)return XU;else if(I===XJ)U.key=null;let Q=H6("value",U.value,J,G);if(Q===XU)return XU;else if(Q===XJ)U.value=null}}return q}async function t9($,U){let J=U_(U);if(W0.isDocument($)){if(await T6(null,$.contents,J,Object.freeze([$]))===XJ)$.contents=null}else await T6(null,$,J,Object.freeze([]))}t9.BREAK=XU;t9.SKIP=$_;t9.REMOVE=XJ;async function T6($,U,J,G){let q=await J_($,U,J,G);if(W0.isNode(q)||W0.isPair(q))return q_($,G,q),T6($,q,J,G);if(typeof q!=="symbol"){if(W0.isCollection(U)){G=Object.freeze(G.concat(U));for(let I=0;I<U.items.length;++I){let Q=await T6(I,U.items[I],J,G);if(typeof Q==="number")I=Q-1;else if(Q===XU)return XU;else if(Q===XJ)U.items.splice(I,1),I-=1}}else if(W0.isPair(U)){G=Object.freeze(G.concat(U));let I=await T6("key",U.key,J,G);if(I===XU)return XU;else if(I===XJ)U.key=null;let Q=await T6("value",U.value,J,G);if(Q===XU)return XU;else if(Q===XJ)U.value=null}}return q}function U_($){if(typeof $==="object"&&($.Collection||$.Node||$.Value))return Object.assign({Alias:$.Node,Map:$.Node,Scalar:$.Node,Seq:$.Node},$.Value&&{Map:$.Value,Scalar:$.Value,Seq:$.Value},$.Collection&&{Map:$.Collection,Seq:$.Collection},$);return $}function J_($,U,J,G){if(typeof J==="function")return J($,U,G);if(W0.isMap(U))return J.Map?.($,U,G);if(W0.isSeq(U))return J.Seq?.($,U,G);if(W0.isPair(U))return J.Pair?.($,U,G);if(W0.isScalar(U))return J.Scalar?.($,U,G);if(W0.isAlias(U))return J.Alias?.($,U,G);return}function q_($,U,J){let G=U[U.length-1];if(W0.isCollection(G))G.items[$]=J;else if(W0.isPair(G))if($==="key")G.key=J;else G.value=J;else if(W0.isDocument(G))G.contents=J;else{let q=W0.isAlias(G)?"alias":"scalar";throw Error(`Cannot replace node with ${q} parent`)}}Ca.visit=s9;Ca.visitAsync=t9});var HM=J$((ka)=>{var G_=x$(),Fa=FI(),ba={"!":"%21",",":"%2C","[":"%5B","]":"%5D","{":"%7B","}":"%7D"},ua=($)=>$.replace(/[!,[\]{}]/g,(U)=>ba[U]);class _U{constructor($,U){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},_U.defaultYaml,$),this.tags=Object.assign({},_U.defaultTags,U)}clone(){let $=new _U(this.yaml,this.tags);return $.docStart=this.docStart,$}atDocument(){let $=new _U(this.yaml,this.tags);switch(this.yaml.version){case"1.1":this.atNextDocument=!0;break;case"1.2":this.atNextDocument=!1,this.yaml={explicit:_U.defaultYaml.explicit,version:"1.2"},this.tags=Object.assign({},_U.defaultTags);break}return $}add($,U){if(this.atNextDocument)this.yaml={explicit:_U.defaultYaml.explicit,version:"1.1"},this.tags=Object.assign({},_U.defaultTags),this.atNextDocument=!1;let J=$.trim().split(/[ \t]+/),G=J.shift();switch(G){case"%TAG":{if(J.length!==2){if(U(0,"%TAG directive should contain exactly two parts"),J.length<2)return!1}let[q,I]=J;return this.tags[q]=I,!0}case"%YAML":{if(this.yaml.explicit=!0,J.length!==1)return U(0,"%YAML directive should contain exactly one part"),!1;let[q]=J;if(q==="1.1"||q==="1.2")return this.yaml.version=q,!0;else{let I=/^\d+\.\d+$/.test(q);return U(6,`Unsupported YAML version ${q}`,I),!1}}default:return U(0,`Unknown directive ${G}`,!0),!1}}tagName($,U){if($==="!")return"!";if($[0]!=="!")return U(`Not a valid tag: ${$}`),null;if($[1]==="<"){let I=$.slice(2,-1);if(I==="!"||I==="!!")return U(`Verbatim tags aren't resolved, so ${$} is invalid.`),null;if($[$.length-1]!==">")U("Verbatim tags must end with a >");return I}let[,J,G]=$.match(/^(.*!)([^!]*)$/s);if(!G)U(`The ${$} tag has no suffix`);let q=this.tags[J];if(q)try{return q+decodeURIComponent(G)}catch(I){return U(String(I)),null}if(J==="!")return $;return U(`Could not resolve tag: ${$}`),null}tagString($){for(let[U,J]of Object.entries(this.tags))if($.startsWith(J))return U+ua($.substring(J.length));return $[0]==="!"?$:`!<${$}>`}toString($){let U=this.yaml.explicit?[`%YAML ${this.yaml.version||"1.2"}`]:[],J=Object.entries(this.tags),G;if($&&J.length>0&&G_.isNode($.contents)){let q={};Fa.visit($.contents,(I,Q)=>{if(G_.isNode(Q)&&Q.tag)q[Q.tag]=!0}),G=Object.keys(q)}else G=[];for(let[q,I]of J){if(q==="!!"&&I==="tag:yaml.org,2002:")continue;if(!$||G.some((Q)=>Q.startsWith(I)))U.push(`%TAG ${q} ${I}`)}return U.join(`
|
|
161
|
+
`)}}_U.defaultYaml={explicit:!1,version:"1.2"};_U.defaultTags={"!!":"tag:yaml.org,2002:"};ka.Directives=_U});var e9=J$((ha)=>{var I_=x$(),fa=FI();function ya($){if(/[\x00-\x19\s,[\]{}]/.test($)){let J=`Anchor must not contain whitespace or control characters: ${JSON.stringify($)}`;throw Error(J)}return!0}function Q_($){let U=new Set;return fa.visit($,{Value(J,G){if(G.anchor)U.add(G.anchor)}}),U}function D_($,U){for(let J=1;;++J){let G=`${$}${J}`;if(!U.has(G))return G}}function ma($,U){let J=[],G=new Map,q=null;return{onAnchor:(I)=>{J.push(I),q??(q=Q_($));let Q=D_(U,q);return q.add(Q),Q},setAnchors:()=>{for(let I of J){let Q=G.get(I);if(typeof Q==="object"&&Q.anchor&&(I_.isScalar(Q.node)||I_.isCollection(Q.node)))Q.node.anchor=Q.anchor;else{let D=Error("Failed to resolve repeated object (this should not happen)");throw D.source=I,D}}},sourceObjects:G}}ha.anchorIsValid=ya;ha.anchorNames=Q_;ha.createNodeAnchors=ma;ha.findNewAnchor=D_});var TM=J$((da)=>{function bI($,U,J,G){if(G&&typeof G==="object")if(Array.isArray(G))for(let q=0,I=G.length;q<I;++q){let Q=G[q],D=bI($,G,String(q),Q);if(D===void 0)delete G[q];else if(D!==Q)G[q]=D}else if(G instanceof Map)for(let q of Array.from(G.keys())){let I=G.get(q),Q=bI($,G,q,I);if(Q===void 0)G.delete(q);else if(Q!==I)G.set(q,Q)}else if(G instanceof Set)for(let q of Array.from(G)){let I=bI($,G,q,q);if(I===void 0)G.delete(q);else if(I!==q)G.delete(q),G.add(I)}else for(let[q,I]of Object.entries(G)){let Q=bI($,G,q,I);if(Q===void 0)delete G[q];else if(Q!==I)G[q]=Q}return $.call(U,J,G)}da.applyReviver=bI});var Kq=J$((oa)=>{var ca=x$();function X_($,U,J){if(Array.isArray($))return $.map((G,q)=>X_(G,String(q),J));if($&&typeof $.toJSON==="function"){if(!J||!ca.hasAnchor($))return $.toJSON(U,J);let G={aliasCount:0,count:1,res:void 0};J.anchors.set($,G),J.onCreate=(I)=>{G.res=I,delete J.onCreate};let q=$.toJSON(U,J);if(J.onCreate)J.onCreate(q);return q}if(typeof $==="bigint"&&!J?.keep)return Number($);return $}oa.toJS=X_});var $Y=J$((ea)=>{var sa=TM(),Y_=x$(),ta=Kq();class V_{constructor($){Object.defineProperty(this,Y_.NODE_TYPE,{value:$})}clone(){let $=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));if(this.range)$.range=this.range.slice();return $}toJS($,{mapAsMap:U,maxAliasCount:J,onAnchor:G,reviver:q}={}){if(!Y_.isDocument($))throw TypeError("A document argument is required");let I={anchors:new Map,doc:$,keep:!0,mapAsMap:U===!0,mapKeyWarned:!1,maxAliasCount:typeof J==="number"?J:100},Q=ta.toJS(this,"",I);if(typeof G==="function")for(let{count:D,res:X}of I.anchors.values())G(X,D);return typeof q==="function"?sa.applyReviver(q,{"":Q},"",Q):Q}}ea.NodeBase=V_});var uI=J$((Is)=>{var Us=e9(),Js=FI(),z6=x$(),qs=$Y(),Gs=Kq();class W_ extends qs.NodeBase{constructor($){super(z6.ALIAS);this.source=$,Object.defineProperty(this,"tag",{set(){throw Error("Alias nodes cannot have tags")}})}resolve($,U){if(U?.maxAliasCount===0)throw ReferenceError("Alias resolution is disabled");let J;if(U?.aliasResolveCache)J=U.aliasResolveCache;else if(J=[],Js.visit($,{Node:(q,I)=>{if(z6.isAlias(I)||z6.hasAnchor(I))J.push(I)}}),U)U.aliasResolveCache=J;let G=void 0;for(let q of J){if(q===this)break;if(q.anchor===this.source)G=q}return G}toJSON($,U){if(!U)return{source:this.source};let{anchors:J,doc:G,maxAliasCount:q}=U,I=this.resolve(G,U);if(!I){let D=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw ReferenceError(D)}let Q=J.get(I);if(!Q)Gs.toJS(I,null,U),Q=J.get(I);if(Q?.res===void 0)throw ReferenceError("This should not happen: Alias anchor was not resolved?");if(q>=0){if(Q.count+=1,Q.aliasCount===0)Q.aliasCount=UY(G,I,J);if(Q.count*Q.aliasCount>q)throw ReferenceError("Excessive alias count indicates a resource exhaustion attack")}return Q.res}toString($,U,J){let G=`*${this.source}`;if($){if(Us.anchorIsValid(this.source),$.options.verifyAliasOrder&&!$.anchors.has(this.source)){let q=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw Error(q)}if($.implicitKey)return`${G} `}return G}}function UY($,U,J){if(z6.isAlias(U)){let G=U.resolve($),q=J&&G&&J.get(G);return q?q.count*q.aliasCount:0}else if(z6.isCollection(U)){let G=0;for(let q of U.items){let I=UY($,q,J);if(I>G)G=I}return G}else if(z6.isPair(U)){let G=UY($,U.key,J),q=UY($,U.value,J);return Math.max(G,q)}return 1}Is.Alias=W_});var D0=J$((Ws)=>{var Ds=x$(),Xs=$Y(),Ys=Kq(),Vs=($)=>!$||typeof $!=="function"&&typeof $!=="object";class _G extends Xs.NodeBase{constructor($){super(Ds.SCALAR);this.value=$}toJSON($,U){return U?.keep?this.value:Ys.toJS(this.value,$,U)}toString(){return String(this.value)}}_G.BLOCK_FOLDED="BLOCK_FOLDED";_G.BLOCK_LITERAL="BLOCK_LITERAL";_G.PLAIN="PLAIN";_G.QUOTE_DOUBLE="QUOTE_DOUBLE";_G.QUOTE_SINGLE="QUOTE_SINGLE";Ws.Scalar=_G;Ws.isScalarValue=Vs});var kI=J$((Hs)=>{var Rs=uI(),vG=x$(),O_=D0(),Ns="tag:yaml.org,2002:";function ws($,U,J){if(U){let G=J.filter((I)=>I.tag===U),q=G.find((I)=>!I.format)??G[0];if(!q)throw Error(`Tag ${U} not found`);return q}return J.find((G)=>G.identify?.($)&&!G.format)}function Ms($,U,J){if(vG.isDocument($))$=$.contents;if(vG.isNode($))return $;if(vG.isPair($)){let W=J.schema[vG.MAP].createNode?.(J.schema,null,J);return W.items.push($),W}if($ instanceof String||$ instanceof Number||$ instanceof Boolean||typeof BigInt<"u"&&$ instanceof BigInt)$=$.valueOf();let{aliasDuplicateObjects:G,onAnchor:q,onTagObj:I,schema:Q,sourceObjects:D}=J,X=void 0;if(G&&$&&typeof $==="object")if(X=D.get($),X)return X.anchor??(X.anchor=q($)),new Rs.Alias(X.anchor);else X={anchor:null,node:null},D.set($,X);if(U?.startsWith("!!"))U=Ns+U.slice(2);let Y=ws($,U,Q.tags);if(!Y){if($&&typeof $.toJSON==="function")$=$.toJSON();if(!$||typeof $!=="object"){let W=new O_.Scalar($);if(X)X.node=W;return W}Y=$ instanceof Map?Q[vG.MAP]:(Symbol.iterator in Object($))?Q[vG.SEQ]:Q[vG.MAP]}if(I)I(Y),delete J.onTagObj;let V=Y?.createNode?Y.createNode(J.schema,$,J):typeof Y?.nodeClass?.from==="function"?Y.nodeClass.from(J.schema,$,J):new O_.Scalar($);if(U)V.tag=U;else if(!Y.default)V.tag=Y.tag;if(X)X.node=V;return V}Hs.createNode=Ms});var JY=J$((Ks)=>{var zs=kI(),YJ=x$(),As=$Y();function zM($,U,J){let G=J;for(let q=U.length-1;q>=0;--q){let I=U[q];if(typeof I==="number"&&Number.isInteger(I)&&I>=0){let Q=[];Q[I]=G,G=Q}else G=new Map([[I,G]])}return zs.createNode(G,void 0,{aliasDuplicateObjects:!1,keepUndefined:!1,onAnchor:()=>{throw Error("This should not happen, please report a bug.")},schema:$,sourceObjects:new Map})}var Z_=($)=>$==null||typeof $==="object"&&!!$[Symbol.iterator]().next().done;class R_ extends As.NodeBase{constructor($,U){super($);Object.defineProperty(this,"schema",{value:U,configurable:!0,enumerable:!1,writable:!0})}clone($){let U=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));if($)U.schema=$;if(U.items=U.items.map((J)=>YJ.isNode(J)||YJ.isPair(J)?J.clone($):J),this.range)U.range=this.range.slice();return U}addIn($,U){if(Z_($))this.add(U);else{let[J,...G]=$,q=this.get(J,!0);if(YJ.isCollection(q))q.addIn(G,U);else if(q===void 0&&this.schema)this.set(J,zM(this.schema,G,U));else throw Error(`Expected YAML collection at ${J}. Remaining path: ${G}`)}}deleteIn($){let[U,...J]=$;if(J.length===0)return this.delete(U);let G=this.get(U,!0);if(YJ.isCollection(G))return G.deleteIn(J);else throw Error(`Expected YAML collection at ${U}. Remaining path: ${J}`)}getIn($,U){let[J,...G]=$,q=this.get(J,!0);if(G.length===0)return!U&&YJ.isScalar(q)?q.value:q;else return YJ.isCollection(q)?q.getIn(G,U):void 0}hasAllNullValues($){return this.items.every((U)=>{if(!YJ.isPair(U))return!1;let J=U.value;return J==null||$&&YJ.isScalar(J)&&J.value==null&&!J.commentBefore&&!J.comment&&!J.tag})}hasIn($){let[U,...J]=$;if(J.length===0)return this.has(U);let G=this.get(U,!0);return YJ.isCollection(G)?G.hasIn(J):!1}setIn($,U){let[J,...G]=$;if(G.length===0)this.set(J,U);else{let q=this.get(J,!0);if(YJ.isCollection(q))q.setIn(G,U);else if(q===void 0&&this.schema)this.set(J,zM(this.schema,G,U));else throw Error(`Expected YAML collection at ${J}. Remaining path: ${G}`)}}}Ks.Collection=R_;Ks.collectionFromPath=zM;Ks.isEmptyPath=Z_});var xI=J$((Ls)=>{var Bs=($)=>$.replace(/^(?!$)(?: $)?/gm,"#");function AM($,U){if(/^\n+$/.test($))return $.substring(1);return U?$.replace(/^(?! *$)/gm,U):$}var Ss=($,U,J)=>$.endsWith(`
|
|
162
|
+
`)?AM(J,U):J.includes(`
|
|
163
|
+
`)?`
|
|
164
|
+
`+AM(J,U):($.endsWith(" ")?"":" ")+J;Ls.indentComment=AM;Ls.lineComment=Ss;Ls.stringifyComment=Bs});var w_=J$((Fs)=>{function vs($,U,J="flow",{indentAtStart:G,lineWidth:q=80,minContentWidth:I=20,onFold:Q,onOverflow:D}={}){if(!q||q<0)return $;if(q<I)I=0;let X=Math.max(1+I,1+q-U.length);if($.length<=X)return $;let Y=[],V={},W=q-U.length;if(typeof G==="number")if(G>q-Math.max(2,I))Y.push(0);else W=q-G;let O=void 0,Z=void 0,M=!1,w=-1,H=-1,g=-1;if(J==="block"){if(w=N_($,w,U.length),w!==-1)W=w+X}for(let C;C=$[w+=1];){if(J==="quoted"&&C==="\\"){switch(H=w,$[w+1]){case"x":w+=3;break;case"u":w+=5;break;case"U":w+=9;break;default:w+=1}g=w}if(C===`
|
|
165
|
+
`){if(J==="block")w=N_($,w,U.length);W=w+U.length+X,O=void 0}else{if(C===" "&&Z&&Z!==" "&&Z!==`
|
|
166
|
+
`&&Z!=="\t"){let F=$[w+1];if(F&&F!==" "&&F!==`
|
|
167
|
+
`&&F!=="\t")O=w}if(w>=W)if(O)Y.push(O),W=O+X,O=void 0;else if(J==="quoted"){while(Z===" "||Z==="\t")Z=C,C=$[w+=1],M=!0;let F=w>g+1?w-2:H-1;if(V[F])return $;Y.push(F),V[F]=!0,W=F+X,O=void 0}else M=!0}Z=C}if(M&&D)D();if(Y.length===0)return $;if(Q)Q();let P=$.slice(0,Y[0]);for(let C=0;C<Y.length;++C){let F=Y[C],f=Y[C+1]||$.length;if(F===0)P=`
|
|
168
|
+
${U}${$.slice(0,f)}`;else{if(J==="quoted"&&V[F])P+=`${$[F]}\\`;P+=`
|
|
169
|
+
${U}${$.slice(F+1,f)}`}}return P}function N_($,U,J){let G=U,q=U+1,I=$[q];while(I===" "||I==="\t")if(U<q+J)I=$[++U];else{do I=$[++U];while(I&&I!==`
|
|
170
|
+
`);G=U,q=U+1,I=$[q]}return G}Fs.FOLD_BLOCK="block";Fs.FOLD_FLOW="flow";Fs.FOLD_QUOTED="quoted";Fs.foldFlowLines=vs});var yI=J$((hs)=>{var rU=D0(),gq=w_(),GY=($,U)=>({indentAtStart:U?$.indent.length:$.indentAtStart,lineWidth:$.options.lineWidth,minContentWidth:$.options.minContentWidth}),IY=($)=>/^(%|---|\.\.\.)/m.test($);function fs($,U,J){if(!U||U<0)return!1;let G=U-J,q=$.length;if(q<=G)return!1;for(let I=0,Q=0;I<q;++I)if($[I]===`
|
|
171
|
+
`){if(I-Q>G)return!0;if(Q=I+1,q-Q<=G)return!1}return!0}function fI($,U){let J=JSON.stringify($);if(U.options.doubleQuotedAsJSON)return J;let{implicitKey:G}=U,q=U.options.doubleQuotedMinMultiLineLength,I=U.indent||(IY($)?" ":""),Q="",D=0;for(let X=0,Y=J[X];Y;Y=J[++X]){if(Y===" "&&J[X+1]==="\\"&&J[X+2]==="n")Q+=J.slice(D,X)+"\\ ",X+=1,D=X,Y="\\";if(Y==="\\")switch(J[X+1]){case"u":{Q+=J.slice(D,X);let V=J.substr(X+2,4);switch(V){case"0000":Q+="\\0";break;case"0007":Q+="\\a";break;case"000b":Q+="\\v";break;case"001b":Q+="\\e";break;case"0085":Q+="\\N";break;case"00a0":Q+="\\_";break;case"2028":Q+="\\L";break;case"2029":Q+="\\P";break;default:if(V.substr(0,2)==="00")Q+="\\x"+V.substr(2);else Q+=J.substr(X,6)}X+=5,D=X+1}break;case"n":if(G||J[X+2]==='"'||J.length<q)X+=1;else{Q+=J.slice(D,X)+`
|
|
172
|
+
|
|
173
|
+
`;while(J[X+2]==="\\"&&J[X+3]==="n"&&J[X+4]!=='"')Q+=`
|
|
174
|
+
`,X+=2;if(Q+=I,J[X+2]===" ")Q+="\\";X+=1,D=X+1}break;default:X+=1}}return Q=D?Q+J.slice(D):J,G?Q:gq.foldFlowLines(Q,I,gq.FOLD_QUOTED,GY(U,!1))}function KM($,U){if(U.options.singleQuote===!1||U.implicitKey&&$.includes(`
|
|
175
|
+
`)||/[ \t]\n|\n[ \t]/.test($))return fI($,U);let J=U.indent||(IY($)?" ":""),G="'"+$.replace(/'/g,"''").replace(/\n+/g,`$&
|
|
176
|
+
${J}`)+"'";return U.implicitKey?G:gq.foldFlowLines(G,J,gq.FOLD_FLOW,GY(U,!1))}function A6($,U){let{singleQuote:J}=U.options,G;if(J===!1)G=fI;else{let q=$.includes('"'),I=$.includes("'");if(q&&!I)G=KM;else if(I&&!q)G=fI;else G=J?KM:fI}return G($,U)}var gM;try{gM=new RegExp(`(^|(?<!
|
|
177
|
+
))
|
|
178
|
+
+(?!
|
|
179
|
+
|$)`,"g")}catch{gM=/\n+(?!\n|$)/g}function qY({comment:$,type:U,value:J},G,q,I){let{blockQuote:Q,commentString:D,lineWidth:X}=G.options;if(!Q||/\n[\t ]+$/.test(J))return A6(J,G);let Y=G.indent||(G.forceBlockIndent||IY(J)?" ":""),V=Q==="literal"?!0:Q==="folded"||U===rU.Scalar.BLOCK_FOLDED?!1:U===rU.Scalar.BLOCK_LITERAL?!0:!fs(J,X,Y.length);if(!J)return V?`|
|
|
180
|
+
`:`>
|
|
181
|
+
`;let W,O;for(O=J.length;O>0;--O){let f=J[O-1];if(f!==`
|
|
182
|
+
`&&f!=="\t"&&f!==" ")break}let Z=J.substring(O),M=Z.indexOf(`
|
|
183
|
+
`);if(M===-1)W="-";else if(J===Z||M!==Z.length-1){if(W="+",I)I()}else W="";if(Z){if(J=J.slice(0,-Z.length),Z[Z.length-1]===`
|
|
184
|
+
`)Z=Z.slice(0,-1);Z=Z.replace(gM,`$&${Y}`)}let w=!1,H,g=-1;for(H=0;H<J.length;++H){let f=J[H];if(f===" ")w=!0;else if(f===`
|
|
185
|
+
`)g=H;else break}let P=J.substring(0,g<H?g+1:H);if(P)J=J.substring(P.length),P=P.replace(/\n+/g,`$&${Y}`);let F=(w?Y?"2":"1":"")+W;if($){if(F+=" "+D($.replace(/ ?[\r\n]+/g," ")),q)q()}if(!V){let f=J.replace(/\n+/g,`
|
|
186
|
+
$&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,"$1$2").replace(/\n+/g,`$&${Y}`),E=!1,p=GY(G,!0);if(Q!=="folded"&&U!==rU.Scalar.BLOCK_FOLDED)p.onOverflow=()=>{E=!0};let b=gq.foldFlowLines(`${P}${f}${Z}`,Y,gq.FOLD_BLOCK,p);if(!E)return`>${F}
|
|
187
|
+
${Y}${b}`}return J=J.replace(/\n+/g,`$&${Y}`),`|${F}
|
|
188
|
+
${Y}${P}${J}${Z}`}function ys($,U,J,G){let{type:q,value:I}=$,{actualString:Q,implicitKey:D,indent:X,indentStep:Y,inFlow:V}=U;if(D&&I.includes(`
|
|
189
|
+
`)||V&&/[[\]{},]/.test(I))return A6(I,U);if(/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(I))return D||V||!I.includes(`
|
|
190
|
+
`)?A6(I,U):qY($,U,J,G);if(!D&&!V&&q!==rU.Scalar.PLAIN&&I.includes(`
|
|
191
|
+
`))return qY($,U,J,G);if(IY(I)){if(X==="")return U.forceBlockIndent=!0,qY($,U,J,G);else if(D&&X===Y)return A6(I,U)}let W=I.replace(/\n+/g,`$&
|
|
192
|
+
${X}`);if(Q){let O=(w)=>w.default&&w.tag!=="tag:yaml.org,2002:str"&&w.test?.test(W),{compat:Z,tags:M}=U.doc.schema;if(M.some(O)||Z?.some(O))return A6(I,U)}return D?W:gq.foldFlowLines(W,X,gq.FOLD_FLOW,GY(U,!1))}function ms($,U,J,G){let{implicitKey:q,inFlow:I}=U,Q=typeof $.value==="string"?$:Object.assign({},$,{value:String($.value)}),{type:D}=$;if(D!==rU.Scalar.QUOTE_DOUBLE){if(/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(Q.value))D=rU.Scalar.QUOTE_DOUBLE}let X=(V)=>{switch(V){case rU.Scalar.BLOCK_FOLDED:case rU.Scalar.BLOCK_LITERAL:return q||I?A6(Q.value,U):qY(Q,U,J,G);case rU.Scalar.QUOTE_DOUBLE:return fI(Q.value,U);case rU.Scalar.QUOTE_SINGLE:return KM(Q.value,U);case rU.Scalar.PLAIN:return ys(Q,U,J,G);default:return null}},Y=X(D);if(Y===null){let{defaultKeyType:V,defaultStringType:W}=U.options,O=q&&V||W;if(Y=X(O),Y===null)throw Error(`Unsupported default string type ${O}`)}return Y}hs.stringifyString=ms});var mI=J$((as)=>{var ls=e9(),jq=x$(),is=xI(),ps=yI();function ds($,U){let J=Object.assign({blockQuote:!0,commentString:is.stringifyComment,defaultKeyType:null,defaultStringType:"PLAIN",directives:null,doubleQuotedAsJSON:!1,doubleQuotedMinMultiLineLength:40,falseStr:"false",flowCollectionPadding:!0,indentSeq:!0,lineWidth:80,minContentWidth:20,nullStr:"null",simpleKeys:!1,singleQuote:null,trailingComma:!1,trueStr:"true",verifyAliasOrder:!0},$.schema.toStringOptions,U),G;switch(J.collectionStyle){case"block":G=!1;break;case"flow":G=!0;break;default:G=null}return{anchors:new Set,doc:$,flowCollectionPadding:J.flowCollectionPadding?" ":"",indent:"",indentStep:typeof J.indent==="number"?" ".repeat(J.indent):" ",inFlow:G,options:J}}function ns($,U){if(U.tag){let q=$.filter((I)=>I.tag===U.tag);if(q.length>0)return q.find((I)=>I.format===U.format)??q[0]}let J=void 0,G;if(jq.isScalar(U)){G=U.value;let q=$.filter((I)=>I.identify?.(G));if(q.length>1){let I=q.filter((Q)=>Q.test);if(I.length>0)q=I}J=q.find((I)=>I.format===U.format)??q.find((I)=>!I.format)}else G=U,J=$.find((q)=>q.nodeClass&&G instanceof q.nodeClass);if(!J){let q=G?.constructor?.name??(G===null?"null":typeof G);throw Error(`Tag not resolved for ${q} value`)}return J}function cs($,U,{anchors:J,doc:G}){if(!G.directives)return"";let q=[],I=(jq.isScalar($)||jq.isCollection($))&&$.anchor;if(I&&ls.anchorIsValid(I))J.add(I),q.push(`&${I}`);let Q=$.tag??(U.default?null:U.tag);if(Q)q.push(G.directives.tagString(Q));return q.join(" ")}function os($,U,J,G){if(jq.isPair($))return $.toString(U,J,G);if(jq.isAlias($)){if(U.doc.directives)return $.toString(U);if(U.resolvedAliases?.has($))throw TypeError("Cannot stringify circular structure without alias nodes");else{if(U.resolvedAliases)U.resolvedAliases.add($);else U.resolvedAliases=new Set([$]);$=$.resolve(U.doc)}}let q=void 0,I=jq.isNode($)?$:U.doc.createNode($,{onTagObj:(X)=>q=X});q??(q=ns(U.doc.schema.tags,I));let Q=cs(I,q,U);if(Q.length>0)U.indentAtStart=(U.indentAtStart??0)+Q.length+1;let D=typeof q.stringify==="function"?q.stringify(I,U,J,G):jq.isScalar(I)?ps.stringifyString(I,U,J,G):I.toString(U,J,G);if(!Q)return D;return jq.isScalar(I)||D[0]==="{"||D[0]==="["?`${Q} ${D}`:`${Q}
|
|
193
|
+
${U.indent}${D}`}as.createStringifyContext=ds;as.stringify=os});var T_=J$(($t)=>{var uJ=x$(),M_=D0(),H_=mI(),hI=xI();function es({key:$,value:U},J,G,q){let{allNullValues:I,doc:Q,indent:D,indentStep:X,options:{commentString:Y,indentSeq:V,simpleKeys:W}}=J,O=uJ.isNode($)&&$.comment||null;if(W){if(O)throw Error("With simple keys, key nodes cannot have comments");if(uJ.isCollection($)||!uJ.isNode($)&&typeof $==="object")throw Error("With simple keys, collection cannot be used as a key value")}let Z=!W&&(!$||O&&U==null&&!J.inFlow||uJ.isCollection($)||(uJ.isScalar($)?$.type===M_.Scalar.BLOCK_FOLDED||$.type===M_.Scalar.BLOCK_LITERAL:typeof $==="object"));J=Object.assign({},J,{allNullValues:!1,implicitKey:!Z&&(W||!I),indent:D+X});let M=!1,w=!1,H=H_.stringify($,J,()=>M=!0,()=>w=!0);if(!Z&&!J.inFlow&&H.length>1024){if(W)throw Error("With simple keys, single line scalar must not span more than 1024 characters");Z=!0}if(J.inFlow){if(I||U==null){if(M&&G)G();return H===""?"?":Z?`? ${H}`:H}}else if(I&&!W||U==null&&Z){if(H=`? ${H}`,O&&!M)H+=hI.lineComment(H,J.indent,Y(O));else if(w&&q)q();return H}if(M)O=null;if(Z){if(O)H+=hI.lineComment(H,J.indent,Y(O));H=`? ${H}
|
|
194
|
+
${D}:`}else if(H=`${H}:`,O)H+=hI.lineComment(H,J.indent,Y(O));let g,P,C;if(uJ.isNode(U))g=!!U.spaceBefore,P=U.commentBefore,C=U.comment;else if(g=!1,P=null,C=null,U&&typeof U==="object")U=Q.createNode(U);if(J.implicitKey=!1,!Z&&!O&&uJ.isScalar(U))J.indentAtStart=H.length+1;if(w=!1,!V&&X.length>=2&&!J.inFlow&&!Z&&uJ.isSeq(U)&&!U.flow&&!U.tag&&!U.anchor)J.indent=J.indent.substring(2);let F=!1,f=H_.stringify(U,J,()=>F=!0,()=>w=!0),E=" ";if(O||g||P){if(E=g?`
|
|
195
|
+
`:"",P){let p=Y(P);E+=`
|
|
196
|
+
${hI.indentComment(p,J.indent)}`}if(f===""&&!J.inFlow){if(E===`
|
|
197
|
+
`&&C)E=`
|
|
198
|
+
|
|
199
|
+
`}else E+=`
|
|
200
|
+
${J.indent}`}else if(!Z&&uJ.isCollection(U)){let p=f[0],b=f.indexOf(`
|
|
201
|
+
`),h=b!==-1,s=J.inFlow??U.flow??U.items.length===0;if(h||!s){let m=!1;if(h&&(p==="&"||p==="!")){let _=f.indexOf(" ");if(p==="&"&&_!==-1&&_<b&&f[_+1]==="!")_=f.indexOf(" ",_+1);if(_===-1||b<_)m=!0}if(!m)E=`
|
|
202
|
+
${J.indent}`}}else if(f===""||f[0]===`
|
|
203
|
+
`)E="";if(H+=E+f,J.inFlow){if(F&&G)G()}else if(C&&!F)H+=hI.lineComment(H,J.indent,Y(C));else if(w&&q)q();return H}$t.stringifyPair=es});var jM=J$((Gt)=>{var z_=WU("process");function Jt($,...U){if($==="debug")console.log(...U)}function qt($,U){if($==="debug"||$==="warn")if(typeof z_.emitWarning==="function")z_.emitWarning(U);else console.warn(U)}Gt.debug=Jt;Gt.warn=qt});var YY=J$((Xt)=>{var XY=x$(),A_=D0(),QY="<<",DY={identify:($)=>$===QY||typeof $==="symbol"&&$.description===QY,default:"key",tag:"tag:yaml.org,2002:merge",test:/^<<$/,resolve:()=>Object.assign(new A_.Scalar(Symbol(QY)),{addToJSMap:K_}),stringify:()=>QY},Dt=($,U)=>(DY.identify(U)||XY.isScalar(U)&&(!U.type||U.type===A_.Scalar.PLAIN)&&DY.identify(U.value))&&$?.doc.schema.tags.some((J)=>J.tag===DY.tag&&J.default);function K_($,U,J){let G=g_($,J);if(XY.isSeq(G))for(let q of G.items)PM($,U,q);else if(Array.isArray(G))for(let q of G)PM($,U,q);else PM($,U,G)}function PM($,U,J){let G=g_($,J);if(!XY.isMap(G))throw Error("Merge sources must be maps or map aliases");let q=G.toJSON(null,$,Map);for(let[I,Q]of q)if(U instanceof Map){if(!U.has(I))U.set(I,Q)}else if(U instanceof Set)U.add(I);else if(!Object.prototype.hasOwnProperty.call(U,I))Object.defineProperty(U,I,{value:Q,writable:!0,enumerable:!0,configurable:!0});return U}function g_($,U){return $&&XY.isAlias(U)?U.resolve($.doc,$):U}Xt.addMergeToJSMap=K_;Xt.isMergeKey=Dt;Xt.merge=DY});var SM=J$((wt)=>{var Ot=jM(),j_=YY(),Zt=mI(),P_=x$(),BM=Kq();function Rt($,U,{key:J,value:G}){if(P_.isNode(J)&&J.addToJSMap)J.addToJSMap($,U,G);else if(j_.isMergeKey($,J))j_.addMergeToJSMap($,U,G);else{let q=BM.toJS(J,"",$);if(U instanceof Map)U.set(q,BM.toJS(G,q,$));else if(U instanceof Set)U.add(q);else{let I=Nt(J,q,$),Q=BM.toJS(G,I,$);if(I in U)Object.defineProperty(U,I,{value:Q,writable:!0,enumerable:!0,configurable:!0});else U[I]=Q}}return U}function Nt($,U,J){if(U===null)return"";if(typeof U!=="object")return String(U);if(P_.isNode($)&&J?.doc){let G=Zt.createStringifyContext(J.doc,{});G.anchors=new Set;for(let I of J.anchors.keys())G.anchors.add(I.anchor);G.inFlow=!0,G.inStringifyKey=!0;let q=$.toString(G);if(!J.mapKeyWarned){let I=JSON.stringify(q);if(I.length>40)I=I.substring(0,36)+'..."';Ot.warn(J.doc.options.logLevel,`Keys with collection values will be stringified due to JS Object restrictions: ${I}. Set mapAsMap: true to use object keys.`),J.mapKeyWarned=!0}return q}return JSON.stringify(U)}wt.addPairToJSMap=Rt});var Pq=J$((At)=>{var B_=kI(),Ht=T_(),Tt=SM(),VY=x$();function zt($,U,J){let G=B_.createNode($,void 0,J),q=B_.createNode(U,void 0,J);return new WY(G,q)}class WY{constructor($,U=null){Object.defineProperty(this,VY.NODE_TYPE,{value:VY.PAIR}),this.key=$,this.value=U}clone($){let{key:U,value:J}=this;if(VY.isNode(U))U=U.clone($);if(VY.isNode(J))J=J.clone($);return new WY(U,J)}toJSON($,U){let J=U?.mapAsMap?new Map:{};return Tt.addPairToJSMap(U,J,this)}toString($,U,J){return $?.doc?Ht.stringifyPair(this,$,U,J):JSON.stringify(this)}}At.Pair=WY;At.createPair=zt});var LM=J$((St)=>{var FG=x$(),S_=mI(),OY=xI();function jt($,U,J){return(U.inFlow??$.flow?Bt:Pt)($,U,J)}function Pt({comment:$,items:U},J,{blockItemPrefix:G,flowChars:q,itemIndent:I,onChompKeep:Q,onComment:D}){let{indent:X,options:{commentString:Y}}=J,V=Object.assign({},J,{indent:I,type:null}),W=!1,O=[];for(let M=0;M<U.length;++M){let w=U[M],H=null;if(FG.isNode(w)){if(!W&&w.spaceBefore)O.push("");if(ZY(J,O,w.commentBefore,W),w.comment)H=w.comment}else if(FG.isPair(w)){let P=FG.isNode(w.key)?w.key:null;if(P){if(!W&&P.spaceBefore)O.push("");ZY(J,O,P.commentBefore,W)}}W=!1;let g=S_.stringify(w,V,()=>H=null,()=>W=!0);if(H)g+=OY.lineComment(g,I,Y(H));if(W&&H)W=!1;O.push(G+g)}let Z;if(O.length===0)Z=q.start+q.end;else{Z=O[0];for(let M=1;M<O.length;++M){let w=O[M];Z+=w?`
|
|
204
|
+
${X}${w}`:`
|
|
205
|
+
`}}if($){if(Z+=`
|
|
206
|
+
`+OY.indentComment(Y($),X),D)D()}else if(W&&Q)Q();return Z}function Bt({items:$},U,{flowChars:J,itemIndent:G}){let{indent:q,indentStep:I,flowCollectionPadding:Q,options:{commentString:D}}=U;G+=I;let X=Object.assign({},U,{indent:G,inFlow:!0,type:null}),Y=!1,V=0,W=[];for(let M=0;M<$.length;++M){let w=$[M],H=null;if(FG.isNode(w)){if(w.spaceBefore)W.push("");if(ZY(U,W,w.commentBefore,!1),w.comment)H=w.comment}else if(FG.isPair(w)){let P=FG.isNode(w.key)?w.key:null;if(P){if(P.spaceBefore)W.push("");if(ZY(U,W,P.commentBefore,!1),P.comment)Y=!0}let C=FG.isNode(w.value)?w.value:null;if(C){if(C.comment)H=C.comment;if(C.commentBefore)Y=!0}else if(w.value==null&&P?.comment)H=P.comment}if(H)Y=!0;let g=S_.stringify(w,X,()=>H=null);if(Y||(Y=W.length>V||g.includes(`
|
|
207
|
+
`)),M<$.length-1)g+=",";else if(U.options.trailingComma){if(U.options.lineWidth>0)Y||(Y=W.reduce((P,C)=>P+C.length+2,2)+(g.length+2)>U.options.lineWidth);if(Y)g+=","}if(H)g+=OY.lineComment(g,G,D(H));W.push(g),V=W.length}let{start:O,end:Z}=J;if(W.length===0)return O+Z;else{if(!Y){let M=W.reduce((w,H)=>w+H.length+2,2);Y=U.options.lineWidth>0&&M>U.options.lineWidth}if(Y){let M=O;for(let w of W)M+=w?`
|
|
208
|
+
${I}${q}${w}`:`
|
|
209
|
+
`;return`${M}
|
|
210
|
+
${q}${Z}`}else return`${O}${Q}${W.join(" ")}${Q}${Z}`}}function ZY({indent:$,options:{commentString:U}},J,G,q){if(G&&q)G=G.replace(/^\n+/,"");if(G){let I=OY.indentComment(U(G),$);J.push(I.trimStart())}}St.stringifyCollection=jt});var Sq=J$((Ft)=>{var Et=LM(),Ct=SM(),_t=JY(),Bq=x$(),RY=Pq(),vt=D0();function rI($,U){let J=Bq.isScalar(U)?U.value:U;for(let G of $)if(Bq.isPair(G)){if(G.key===U||G.key===J)return G;if(Bq.isScalar(G.key)&&G.key.value===J)return G}return}class L_ extends _t.Collection{static get tagName(){return"tag:yaml.org,2002:map"}constructor($){super(Bq.MAP,$);this.items=[]}static from($,U,J){let{keepUndefined:G,replacer:q}=J,I=new this($),Q=(D,X)=>{if(typeof q==="function")X=q.call(U,D,X);else if(Array.isArray(q)&&!q.includes(D))return;if(X!==void 0||G)I.items.push(RY.createPair(D,X,J))};if(U instanceof Map)for(let[D,X]of U)Q(D,X);else if(U&&typeof U==="object")for(let D of Object.keys(U))Q(D,U[D]);if(typeof $.sortMapEntries==="function")I.items.sort($.sortMapEntries);return I}add($,U){let J;if(Bq.isPair($))J=$;else if(!$||typeof $!=="object"||!("key"in $))J=new RY.Pair($,$?.value);else J=new RY.Pair($.key,$.value);let G=rI(this.items,J.key),q=this.schema?.sortMapEntries;if(G){if(!U)throw Error(`Key ${J.key} already set`);if(Bq.isScalar(G.value)&&vt.isScalarValue(J.value))G.value.value=J.value;else G.value=J.value}else if(q){let I=this.items.findIndex((Q)=>q(J,Q)<0);if(I===-1)this.items.push(J);else this.items.splice(I,0,J)}else this.items.push(J)}delete($){let U=rI(this.items,$);if(!U)return!1;return this.items.splice(this.items.indexOf(U),1).length>0}get($,U){let G=rI(this.items,$)?.value;return(!U&&Bq.isScalar(G)?G.value:G)??void 0}has($){return!!rI(this.items,$)}set($,U){this.add(new RY.Pair($,U),!0)}toJSON($,U,J){let G=J?new J:U?.mapAsMap?new Map:{};if(U?.onCreate)U.onCreate(G);for(let q of this.items)Ct.addPairToJSMap(U,G,q);return G}toString($,U,J){if(!$)return JSON.stringify(this);for(let G of this.items)if(!Bq.isPair(G))throw Error(`Map items must all be pairs; found ${JSON.stringify(G)} instead`);if(!$.allNullValues&&this.hasAllNullValues(!1))$=Object.assign({},$,{allNullValues:!0});return Et.stringifyCollection(this,$,{blockItemPrefix:"",flowChars:{start:"{",end:"}"},itemIndent:$.indent||"",onChompKeep:J,onComment:U})}}Ft.YAMLMap=L_;Ft.findPair=rI});var K6=J$((ft)=>{var kt=x$(),E_=Sq(),xt={collection:"map",default:!0,nodeClass:E_.YAMLMap,tag:"tag:yaml.org,2002:map",resolve($,U){if(!kt.isMap($))U("Expected a mapping for this tag");return $},createNode:($,U,J)=>E_.YAMLMap.from($,U,J)};ft.map=xt});var Lq=J$((pt)=>{var mt=kI(),ht=LM(),rt=JY(),wY=x$(),lt=D0(),it=Kq();class C_ extends rt.Collection{static get tagName(){return"tag:yaml.org,2002:seq"}constructor($){super(wY.SEQ,$);this.items=[]}add($){this.items.push($)}delete($){let U=NY($);if(typeof U!=="number")return!1;return this.items.splice(U,1).length>0}get($,U){let J=NY($);if(typeof J!=="number")return;let G=this.items[J];return!U&&wY.isScalar(G)?G.value:G}has($){let U=NY($);return typeof U==="number"&&U<this.items.length}set($,U){let J=NY($);if(typeof J!=="number")throw Error(`Expected a valid index, not ${$}.`);let G=this.items[J];if(wY.isScalar(G)&<.isScalarValue(U))G.value=U;else this.items[J]=U}toJSON($,U){let J=[];if(U?.onCreate)U.onCreate(J);let G=0;for(let q of this.items)J.push(it.toJS(q,String(G++),U));return J}toString($,U,J){if(!$)return JSON.stringify(this);return ht.stringifyCollection(this,$,{blockItemPrefix:"- ",flowChars:{start:"[",end:"]"},itemIndent:($.indent||"")+" ",onChompKeep:J,onComment:U})}static from($,U,J){let{replacer:G}=J,q=new this($);if(U&&Symbol.iterator in Object(U)){let I=0;for(let Q of U){if(typeof G==="function"){let D=U instanceof Set?Q:String(I++);Q=G.call(U,D,Q)}q.items.push(mt.createNode(Q,void 0,J))}}return q}}function NY($){let U=wY.isScalar($)?$.value:$;if(U&&typeof U==="string")U=Number(U);return typeof U==="number"&&Number.isInteger(U)&&U>=0?U:null}pt.YAMLSeq=C_});var g6=J$((ot)=>{var nt=x$(),__=Lq(),ct={collection:"seq",default:!0,nodeClass:__.YAMLSeq,tag:"tag:yaml.org,2002:seq",resolve($,U){if(!nt.isSeq($))U("Expected a sequence for this tag");return $},createNode:($,U,J)=>__.YAMLSeq.from($,U,J)};ot.seq=ct});var lI=J$((et)=>{var st=yI(),tt={identify:($)=>typeof $==="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:($)=>$,stringify($,U,J,G){return U=Object.assign({actualString:!0},U),st.stringifyString($,U,J,G)}};et.string=tt});var MY=J$((Ue)=>{var v_=D0(),F_={identify:($)=>$==null,createNode:()=>new v_.Scalar(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>new v_.Scalar(null),stringify:({source:$},U)=>typeof $==="string"&&F_.test.test($)?$:U.options.nullStr};Ue.nullTag=F_});var EM=J$((Ge)=>{var qe=D0(),b_={identify:($)=>typeof $==="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,resolve:($)=>new qe.Scalar($[0]==="t"||$[0]==="T"),stringify({source:$,value:U},J){if($&&b_.test.test($)){let G=$[0]==="t"||$[0]==="T";if(U===G)return $}return U?J.options.trueStr:J.options.falseStr}};Ge.boolTag=b_});var j6=J$((De)=>{function Qe({format:$,minFractionDigits:U,tag:J,value:G}){if(typeof G==="bigint")return String(G);let q=typeof G==="number"?G:Number(G);if(!isFinite(q))return isNaN(q)?".nan":q<0?"-.inf":".inf";let I=Object.is(G,-0)?"-0":JSON.stringify(G);if(!$&&U&&(!J||J==="tag:yaml.org,2002:float")&&/^-?\d/.test(I)&&!I.includes("e")){let Q=I.indexOf(".");if(Q<0)Q=I.length,I+=".";let D=U-(I.length-Q-1);while(D-- >0)I+="0"}return I}De.stringifyNumber=Qe});var _M=J$((Ze)=>{var Ye=D0(),CM=j6(),Ve={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:($)=>$.slice(-3).toLowerCase()==="nan"?NaN:$[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:CM.stringifyNumber},We={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/,resolve:($)=>parseFloat($),stringify($){let U=Number($.value);return isFinite(U)?U.toExponential():CM.stringifyNumber($)}},Oe={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/,resolve($){let U=new Ye.Scalar(parseFloat($)),J=$.indexOf(".");if(J!==-1&&$[$.length-1]==="0")U.minFractionDigits=$.length-J-1;return U},stringify:CM.stringifyNumber};Ze.float=Oe;Ze.floatExp=We;Ze.floatNaN=Ve});var FM=J$((ze)=>{var u_=j6(),HY=($)=>typeof $==="bigint"||Number.isInteger($),vM=($,U,J,{intAsBigInt:G})=>G?BigInt($):parseInt($.substring(U),J);function k_($,U,J){let{value:G}=$;if(HY(G)&&G>=0)return J+G.toString(U);return u_.stringifyNumber($)}var Me={identify:($)=>HY($)&&$>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^0o[0-7]+$/,resolve:($,U,J)=>vM($,2,8,J),stringify:($)=>k_($,8,"0o")},He={identify:HY,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9]+$/,resolve:($,U,J)=>vM($,0,10,J),stringify:u_.stringifyNumber},Te={identify:($)=>HY($)&&$>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^0x[0-9a-fA-F]+$/,resolve:($,U,J)=>vM($,2,16,J),stringify:($)=>k_($,16,"0x")};ze.int=He;ze.intHex=Te;ze.intOct=Me});var x_=J$((Ce)=>{var je=K6(),Pe=MY(),Be=g6(),Se=lI(),Le=EM(),bM=_M(),uM=FM(),Ee=[je.map,Be.seq,Se.string,Pe.nullTag,Le.boolTag,uM.intOct,uM.int,uM.intHex,bM.floatNaN,bM.floatExp,bM.float];Ce.schema=Ee});var y_=J$((fe)=>{var ve=D0(),Fe=K6(),be=g6();function f_($){return typeof $==="bigint"||Number.isInteger($)}var TY=({value:$})=>JSON.stringify($),ue=[{identify:($)=>typeof $==="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:($)=>$,stringify:TY},{identify:($)=>$==null,createNode:()=>new ve.Scalar(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^null$/,resolve:()=>null,stringify:TY},{identify:($)=>typeof $==="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^true$|^false$/,resolve:($)=>$==="true",stringify:TY},{identify:f_,default:!0,tag:"tag:yaml.org,2002:int",test:/^-?(?:0|[1-9][0-9]*)$/,resolve:($,U,{intAsBigInt:J})=>J?BigInt($):parseInt($,10),stringify:({value:$})=>f_($)?$.toString():JSON.stringify($)},{identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,resolve:($)=>parseFloat($),stringify:TY}],ke={default:!0,tag:"",test:/^/,resolve($,U){return U(`Unresolved plain scalar ${JSON.stringify($)}`),$}},xe=[Fe.map,be.seq].concat(ue,ke);fe.schema=xe});var xM=J$((re)=>{var iI=WU("buffer"),kM=D0(),me=yI(),he={identify:($)=>$ instanceof Uint8Array,default:!1,tag:"tag:yaml.org,2002:binary",resolve($,U){if(typeof iI.Buffer==="function")return iI.Buffer.from($,"base64");else if(typeof atob==="function"){let J=atob($.replace(/[\n\r]/g,"")),G=new Uint8Array(J.length);for(let q=0;q<J.length;++q)G[q]=J.charCodeAt(q);return G}else return U("This environment does not support reading binary tags; either Buffer or atob is required"),$},stringify({comment:$,type:U,value:J},G,q,I){if(!J)return"";let Q=J,D;if(typeof iI.Buffer==="function")D=Q instanceof iI.Buffer?Q.toString("base64"):iI.Buffer.from(Q.buffer).toString("base64");else if(typeof btoa==="function"){let X="";for(let Y=0;Y<Q.length;++Y)X+=String.fromCharCode(Q[Y]);D=btoa(X)}else throw Error("This environment does not support writing binary tags; either Buffer or btoa is required");if(U??(U=kM.Scalar.BLOCK_LITERAL),U!==kM.Scalar.QUOTE_DOUBLE){let X=Math.max(G.options.lineWidth-G.indent.length,G.options.minContentWidth),Y=Math.ceil(D.length/X),V=Array(Y);for(let W=0,O=0;W<Y;++W,O+=X)V[W]=D.substr(O,X);D=V.join(U===kM.Scalar.BLOCK_LITERAL?`
|
|
211
|
+
`:" ")}return me.stringifyString({comment:$,type:U,value:D},G,q,I)}};re.binary=he});var AY=J$((ne)=>{var zY=x$(),fM=Pq(),ie=D0(),pe=Lq();function m_($,U){if(zY.isSeq($))for(let J=0;J<$.items.length;++J){let G=$.items[J];if(zY.isPair(G))continue;else if(zY.isMap(G)){if(G.items.length>1)U("Each pair must have its own sequence indicator");let q=G.items[0]||new fM.Pair(new ie.Scalar(null));if(G.commentBefore)q.key.commentBefore=q.key.commentBefore?`${G.commentBefore}
|
|
212
|
+
${q.key.commentBefore}`:G.commentBefore;if(G.comment){let I=q.value??q.key;I.comment=I.comment?`${G.comment}
|
|
213
|
+
${I.comment}`:G.comment}G=q}$.items[J]=zY.isPair(G)?G:new fM.Pair(G)}else U("Expected a sequence for this tag");return $}function h_($,U,J){let{replacer:G}=J,q=new pe.YAMLSeq($);q.tag="tag:yaml.org,2002:pairs";let I=0;if(U&&Symbol.iterator in Object(U))for(let Q of U){if(typeof G==="function")Q=G.call(U,String(I++),Q);let D,X;if(Array.isArray(Q))if(Q.length===2)D=Q[0],X=Q[1];else throw TypeError(`Expected [key, value] tuple: ${Q}`);else if(Q&&Q instanceof Object){let Y=Object.keys(Q);if(Y.length===1)D=Y[0],X=Q[D];else throw TypeError(`Expected tuple with one key, not ${Y.length} keys`)}else D=Q;q.items.push(fM.createPair(D,X,J))}return q}var de={collection:"seq",default:!1,tag:"tag:yaml.org,2002:pairs",resolve:m_,createNode:h_};ne.createPairs=h_;ne.pairs=de;ne.resolvePairs=m_});var mM=J$((ee)=>{var r_=x$(),yM=Kq(),pI=Sq(),se=Lq(),l_=AY();class bG extends se.YAMLSeq{constructor(){super();this.add=pI.YAMLMap.prototype.add.bind(this),this.delete=pI.YAMLMap.prototype.delete.bind(this),this.get=pI.YAMLMap.prototype.get.bind(this),this.has=pI.YAMLMap.prototype.has.bind(this),this.set=pI.YAMLMap.prototype.set.bind(this),this.tag=bG.tag}toJSON($,U){if(!U)return super.toJSON($);let J=new Map;if(U?.onCreate)U.onCreate(J);for(let G of this.items){let q,I;if(r_.isPair(G))q=yM.toJS(G.key,"",U),I=yM.toJS(G.value,q,U);else q=yM.toJS(G,"",U);if(J.has(q))throw Error("Ordered maps must not include duplicate keys");J.set(q,I)}return J}static from($,U,J){let G=l_.createPairs($,U,J),q=new this;return q.items=G.items,q}}bG.tag="tag:yaml.org,2002:omap";var te={collection:"seq",identify:($)=>$ instanceof Map,nodeClass:bG,default:!1,tag:"tag:yaml.org,2002:omap",resolve($,U){let J=l_.resolvePairs($,U),G=[];for(let{key:q}of J.items)if(r_.isScalar(q))if(G.includes(q.value))U(`Ordered maps must not include duplicate keys: ${q.value}`);else G.push(q.value);return Object.assign(new bG,J)},createNode:($,U,J)=>bG.from($,U,J)};ee.YAMLOMap=bG;ee.omap=te});var c_=J$((J$$)=>{var i_=D0();function p_({value:$,source:U},J){if(U&&($?d_:n_).test.test(U))return U;return $?J.options.trueStr:J.options.falseStr}var d_={identify:($)=>$===!0,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,resolve:()=>new i_.Scalar(!0),stringify:p_},n_={identify:($)=>$===!1,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,resolve:()=>new i_.Scalar(!1),stringify:p_};J$$.falseTag=n_;J$$.trueTag=d_});var o_=J$((Y$$)=>{var I$$=D0(),hM=j6(),Q$$={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:($)=>$.slice(-3).toLowerCase()==="nan"?NaN:$[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:hM.stringifyNumber},D$$={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/,resolve:($)=>parseFloat($.replace(/_/g,"")),stringify($){let U=Number($.value);return isFinite(U)?U.toExponential():hM.stringifyNumber($)}},X$$={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,resolve($){let U=new I$$.Scalar(parseFloat($.replace(/_/g,""))),J=$.indexOf(".");if(J!==-1){let G=$.substring(J+1).replace(/_/g,"");if(G[G.length-1]==="0")U.minFractionDigits=G.length}return U},stringify:hM.stringifyNumber};Y$$.float=X$$;Y$$.floatExp=D$$;Y$$.floatNaN=Q$$});var s_=J$((M$$)=>{var a_=j6(),dI=($)=>typeof $==="bigint"||Number.isInteger($);function KY($,U,J,{intAsBigInt:G}){let q=$[0];if(q==="-"||q==="+")U+=1;if($=$.substring(U).replace(/_/g,""),G){switch(J){case 2:$=`0b${$}`;break;case 8:$=`0o${$}`;break;case 16:$=`0x${$}`;break}let Q=BigInt($);return q==="-"?BigInt(-1)*Q:Q}let I=parseInt($,J);return q==="-"?-1*I:I}function rM($,U,J){let{value:G}=$;if(dI(G)){let q=G.toString(U);return G<0?"-"+J+q.substr(1):J+q}return a_.stringifyNumber($)}var Z$$={identify:dI,default:!0,tag:"tag:yaml.org,2002:int",format:"BIN",test:/^[-+]?0b[0-1_]+$/,resolve:($,U,J)=>KY($,2,2,J),stringify:($)=>rM($,2,"0b")},R$$={identify:dI,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^[-+]?0[0-7_]+$/,resolve:($,U,J)=>KY($,1,8,J),stringify:($)=>rM($,8,"0")},N$$={identify:dI,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9][0-9_]*$/,resolve:($,U,J)=>KY($,0,10,J),stringify:a_.stringifyNumber},w$$={identify:dI,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^[-+]?0x[0-9a-fA-F_]+$/,resolve:($,U,J)=>KY($,2,16,J),stringify:($)=>rM($,16,"0x")};M$$.int=N$$;M$$.intBin=Z$$;M$$.intHex=w$$;M$$.intOct=R$$});var lM=J$((g$$)=>{var PY=x$(),gY=Pq(),jY=Sq();class uG extends jY.YAMLMap{constructor($){super($);this.tag=uG.tag}add($){let U;if(PY.isPair($))U=$;else if($&&typeof $==="object"&&"key"in $&&"value"in $&&$.value===null)U=new gY.Pair($.key,null);else U=new gY.Pair($,null);if(!jY.findPair(this.items,U.key))this.items.push(U)}get($,U){let J=jY.findPair(this.items,$);return!U&&PY.isPair(J)?PY.isScalar(J.key)?J.key.value:J.key:J}set($,U){if(typeof U!=="boolean")throw Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof U}`);let J=jY.findPair(this.items,$);if(J&&!U)this.items.splice(this.items.indexOf(J),1);else if(!J&&U)this.items.push(new gY.Pair($))}toJSON($,U){return super.toJSON($,U,Set)}toString($,U,J){if(!$)return JSON.stringify(this);if(this.hasAllNullValues(!0))return super.toString(Object.assign({},$,{allNullValues:!0}),U,J);else throw Error("Set items must all have null values")}static from($,U,J){let{replacer:G}=J,q=new this($);if(U&&Symbol.iterator in Object(U))for(let I of U){if(typeof G==="function")I=G.call(U,I,I);q.items.push(gY.createPair(I,null,J))}return q}}uG.tag="tag:yaml.org,2002:set";var K$$={collection:"map",identify:($)=>$ instanceof Set,nodeClass:uG,default:!1,tag:"tag:yaml.org,2002:set",createNode:($,U,J)=>uG.from($,U,J),resolve($,U){if(PY.isMap($))if($.hasAllNullValues(!0))return Object.assign(new uG,$);else U("Set items must all have null values");else U("Expected a mapping for this tag");return $}};g$$.YAMLSet=uG;g$$.set=K$$});var pM=J$((E$$)=>{var B$$=j6();function iM($,U){let J=$[0],G=J==="-"||J==="+"?$.substring(1):$,q=(Q)=>U?BigInt(Q):Number(Q),I=G.replace(/_/g,"").split(":").reduce((Q,D)=>Q*q(60)+q(D),q(0));return J==="-"?q(-1)*I:I}function t_($){let{value:U}=$,J=(Q)=>Q;if(typeof U==="bigint")J=(Q)=>BigInt(Q);else if(isNaN(U)||!isFinite(U))return B$$.stringifyNumber($);let G="";if(U<0)G="-",U*=J(-1);let q=J(60),I=[U%q];if(U<60)I.unshift(0);else if(U=(U-I[0])/q,I.unshift(U%q),U>=60)U=(U-I[0])/q,I.unshift(U);return G+I.map((Q)=>String(Q).padStart(2,"0")).join(":").replace(/000000\d*$/,"")}var S$$={identify:($)=>typeof $==="bigint"||Number.isInteger($),default:!0,tag:"tag:yaml.org,2002:int",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/,resolve:($,U,{intAsBigInt:J})=>iM($,J),stringify:t_},L$$={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/,resolve:($)=>iM($,!1),stringify:t_},e_={identify:($)=>$ instanceof Date,default:!0,tag:"tag:yaml.org,2002:timestamp",test:RegExp("^([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?$"),resolve($){let U=$.match(e_.test);if(!U)throw Error("!!timestamp expects a date, starting with yyyy-mm-dd");let[,J,G,q,I,Q,D]=U.map(Number),X=U[7]?Number((U[7]+"00").substr(1,3)):0,Y=Date.UTC(J,G-1,q,I||0,Q||0,D||0,X),V=U[8];if(V&&V!=="Z"){let W=iM(V,!1);if(Math.abs(W)<30)W*=60;Y-=60000*W}return new Date(Y)},stringify:({value:$})=>$?.toISOString().replace(/(T00:00:00)?\.000Z$/,"")??""};E$$.floatTime=L$$;E$$.intTime=S$$;E$$.timestamp=e_});var U3=J$((l$$)=>{var F$$=K6(),b$$=MY(),u$$=g6(),k$$=lI(),x$$=xM(),$3=c_(),dM=o_(),BY=s_(),f$$=YY(),y$$=mM(),m$$=AY(),h$$=lM(),nM=pM(),r$$=[F$$.map,u$$.seq,k$$.string,b$$.nullTag,$3.trueTag,$3.falseTag,BY.intBin,BY.intOct,BY.int,BY.intHex,dM.floatNaN,dM.floatExp,dM.float,x$$.binary,f$$.merge,y$$.omap,m$$.pairs,h$$.set,nM.intTime,nM.floatTime,nM.timestamp];l$$.schema=r$$});var W3=J$((t$$)=>{var I3=K6(),p$$=MY(),Q3=g6(),d$$=lI(),n$$=EM(),cM=_M(),oM=FM(),c$$=x_(),o$$=y_(),D3=xM(),nI=YY(),X3=mM(),Y3=AY(),J3=U3(),V3=lM(),SY=pM(),q3=new Map([["core",c$$.schema],["failsafe",[I3.map,Q3.seq,d$$.string]],["json",o$$.schema],["yaml11",J3.schema],["yaml-1.1",J3.schema]]),G3={binary:D3.binary,bool:n$$.boolTag,float:cM.float,floatExp:cM.floatExp,floatNaN:cM.floatNaN,floatTime:SY.floatTime,int:oM.int,intHex:oM.intHex,intOct:oM.intOct,intTime:SY.intTime,map:I3.map,merge:nI.merge,null:p$$.nullTag,omap:X3.omap,pairs:Y3.pairs,seq:Q3.seq,set:V3.set,timestamp:SY.timestamp},a$$={"tag:yaml.org,2002:binary":D3.binary,"tag:yaml.org,2002:merge":nI.merge,"tag:yaml.org,2002:omap":X3.omap,"tag:yaml.org,2002:pairs":Y3.pairs,"tag:yaml.org,2002:set":V3.set,"tag:yaml.org,2002:timestamp":SY.timestamp};function s$$($,U,J){let G=q3.get(U);if(G&&!$)return J&&!G.includes(nI.merge)?G.concat(nI.merge):G.slice();let q=G;if(!q)if(Array.isArray($))q=[];else{let I=Array.from(q3.keys()).filter((Q)=>Q!=="yaml11").map((Q)=>JSON.stringify(Q)).join(", ");throw Error(`Unknown schema "${U}"; use one of ${I} or define customTags array`)}if(Array.isArray($))for(let I of $)q=q.concat(I);else if(typeof $==="function")q=$(q.slice());if(J)q=q.concat(nI.merge);return q.reduce((I,Q)=>{let D=typeof Q==="string"?G3[Q]:Q;if(!D){let X=JSON.stringify(Q),Y=Object.keys(G3).map((V)=>JSON.stringify(V)).join(", ");throw Error(`Unknown custom tag ${X}; use one of ${Y}`)}if(!I.includes(D))I.push(D);return I},[])}t$$.coreKnownTags=a$$;t$$.getTags=s$$});var tM=J$((I0$)=>{var aM=x$(),U0$=K6(),J0$=g6(),q0$=lI(),LY=W3(),G0$=($,U)=>$.key<U.key?-1:$.key>U.key?1:0;class sM{constructor({compat:$,customTags:U,merge:J,resolveKnownTags:G,schema:q,sortMapEntries:I,toStringDefaults:Q}){this.compat=Array.isArray($)?LY.getTags($,"compat"):$?LY.getTags(null,$):null,this.name=typeof q==="string"&&q||"core",this.knownTags=G?LY.coreKnownTags:{},this.tags=LY.getTags(U,this.name,J),this.toStringOptions=Q??null,Object.defineProperty(this,aM.MAP,{value:U0$.map}),Object.defineProperty(this,aM.SCALAR,{value:q0$.string}),Object.defineProperty(this,aM.SEQ,{value:J0$.seq}),this.sortMapEntries=typeof I==="function"?I:I===!0?G0$:null}clone(){let $=Object.create(sM.prototype,Object.getOwnPropertyDescriptors(this));return $.tags=this.tags.slice(),$}}I0$.Schema=sM});var O3=J$((Y0$)=>{var D0$=x$(),eM=mI(),cI=xI();function X0$($,U){let J=[],G=U.directives===!0;if(U.directives!==!1&&$.directives){let X=$.directives.toString($);if(X)J.push(X),G=!0;else if($.directives.docStart)G=!0}if(G)J.push("---");let q=eM.createStringifyContext($,U),{commentString:I}=q.options;if($.commentBefore){if(J.length!==1)J.unshift("");let X=I($.commentBefore);J.unshift(cI.indentComment(X,""))}let Q=!1,D=null;if($.contents){if(D0$.isNode($.contents)){if($.contents.spaceBefore&&G)J.push("");if($.contents.commentBefore){let V=I($.contents.commentBefore);J.push(cI.indentComment(V,""))}q.forceBlockIndent=!!$.comment,D=$.contents.comment}let X=D?void 0:()=>Q=!0,Y=eM.stringify($.contents,q,()=>D=null,X);if(D)Y+=cI.lineComment(Y,"",I(D));if((Y[0]==="|"||Y[0]===">")&&J[J.length-1]==="---")J[J.length-1]=`--- ${Y}`;else J.push(Y)}else J.push(eM.stringify($.contents,q));if($.directives?.docEnd)if($.comment){let X=I($.comment);if(X.includes(`
|
|
214
|
+
`))J.push("..."),J.push(cI.indentComment(X,""));else J.push(`... ${X}`)}else J.push("...");else{let X=$.comment;if(X&&Q)X=X.replace(/^\n+/,"");if(X){if((!Q||D)&&J[J.length-1]!=="")J.push("");J.push(cI.indentComment(I(X),""))}}return J.join(`
|
|
215
|
+
`)+`
|
|
216
|
+
`}Y0$.stringifyDocument=X0$});var oI=J$((H0$)=>{var W0$=uI(),P6=JY(),vU=x$(),O0$=Pq(),Z0$=Kq(),R0$=tM(),N0$=O3(),$H=e9(),w0$=TM(),M0$=kI(),UH=HM();class JH{constructor($,U,J){this.commentBefore=null,this.comment=null,this.errors=[],this.warnings=[],Object.defineProperty(this,vU.NODE_TYPE,{value:vU.DOC});let G=null;if(typeof U==="function"||Array.isArray(U))G=U;else if(J===void 0&&U)J=U,U=void 0;let q=Object.assign({intAsBigInt:!1,keepSourceTokens:!1,logLevel:"warn",prettyErrors:!0,strict:!0,stringKeys:!1,uniqueKeys:!0,version:"1.2"},J);this.options=q;let{version:I}=q;if(J?._directives){if(this.directives=J._directives.atDocument(),this.directives.yaml.explicit)I=this.directives.yaml.version}else this.directives=new UH.Directives({version:I});this.setSchema(I,J),this.contents=$===void 0?null:this.createNode($,G,J)}clone(){let $=Object.create(JH.prototype,{[vU.NODE_TYPE]:{value:vU.DOC}});if($.commentBefore=this.commentBefore,$.comment=this.comment,$.errors=this.errors.slice(),$.warnings=this.warnings.slice(),$.options=Object.assign({},this.options),this.directives)$.directives=this.directives.clone();if($.schema=this.schema.clone(),$.contents=vU.isNode(this.contents)?this.contents.clone($.schema):this.contents,this.range)$.range=this.range.slice();return $}add($){if(B6(this.contents))this.contents.add($)}addIn($,U){if(B6(this.contents))this.contents.addIn($,U)}createAlias($,U){if(!$.anchor){let J=$H.anchorNames(this);$.anchor=!U||J.has(U)?$H.findNewAnchor(U||"a",J):U}return new W0$.Alias($.anchor)}createNode($,U,J){let G=void 0;if(typeof U==="function")$=U.call({"":$},"",$),G=U;else if(Array.isArray(U)){let w=(g)=>typeof g==="number"||g instanceof String||g instanceof Number,H=U.filter(w).map(String);if(H.length>0)U=U.concat(H);G=U}else if(J===void 0&&U)J=U,U=void 0;let{aliasDuplicateObjects:q,anchorPrefix:I,flow:Q,keepUndefined:D,onTagObj:X,tag:Y}=J??{},{onAnchor:V,setAnchors:W,sourceObjects:O}=$H.createNodeAnchors(this,I||"a"),Z={aliasDuplicateObjects:q??!0,keepUndefined:D??!1,onAnchor:V,onTagObj:X,replacer:G,schema:this.schema,sourceObjects:O},M=M0$.createNode($,Y,Z);if(Q&&vU.isCollection(M))M.flow=!0;return W(),M}createPair($,U,J={}){let G=this.createNode($,null,J),q=this.createNode(U,null,J);return new O0$.Pair(G,q)}delete($){return B6(this.contents)?this.contents.delete($):!1}deleteIn($){if(P6.isEmptyPath($)){if(this.contents==null)return!1;return this.contents=null,!0}return B6(this.contents)?this.contents.deleteIn($):!1}get($,U){return vU.isCollection(this.contents)?this.contents.get($,U):void 0}getIn($,U){if(P6.isEmptyPath($))return!U&&vU.isScalar(this.contents)?this.contents.value:this.contents;return vU.isCollection(this.contents)?this.contents.getIn($,U):void 0}has($){return vU.isCollection(this.contents)?this.contents.has($):!1}hasIn($){if(P6.isEmptyPath($))return this.contents!==void 0;return vU.isCollection(this.contents)?this.contents.hasIn($):!1}set($,U){if(this.contents==null)this.contents=P6.collectionFromPath(this.schema,[$],U);else if(B6(this.contents))this.contents.set($,U)}setIn($,U){if(P6.isEmptyPath($))this.contents=U;else if(this.contents==null)this.contents=P6.collectionFromPath(this.schema,Array.from($),U);else if(B6(this.contents))this.contents.setIn($,U)}setSchema($,U={}){if(typeof $==="number")$=String($);let J;switch($){case"1.1":if(this.directives)this.directives.yaml.version="1.1";else this.directives=new UH.Directives({version:"1.1"});J={resolveKnownTags:!1,schema:"yaml-1.1"};break;case"1.2":case"next":if(this.directives)this.directives.yaml.version=$;else this.directives=new UH.Directives({version:$});J={resolveKnownTags:!0,schema:"core"};break;case null:if(this.directives)delete this.directives;J=null;break;default:{let G=JSON.stringify($);throw Error(`Expected '1.1', '1.2' or null as first argument, but found: ${G}`)}}if(U.schema instanceof Object)this.schema=U.schema;else if(J)this.schema=new R0$.Schema(Object.assign(J,U));else throw Error("With a null YAML version, the { schema: Schema } option is required")}toJS({json:$,jsonArg:U,mapAsMap:J,maxAliasCount:G,onAnchor:q,reviver:I}={}){let Q={anchors:new Map,doc:this,keep:!$,mapAsMap:J===!0,mapKeyWarned:!1,maxAliasCount:typeof G==="number"?G:100},D=Z0$.toJS(this.contents,U??"",Q);if(typeof q==="function")for(let{count:X,res:Y}of Q.anchors.values())q(Y,X);return typeof I==="function"?w0$.applyReviver(I,{"":D},"",D):D}toJSON($,U){return this.toJS({json:!0,jsonArg:$,mapAsMap:!1,onAnchor:U})}toString($={}){if(this.errors.length>0)throw Error("Document with errors cannot be stringified");if("indent"in $&&(!Number.isInteger($.indent)||Number($.indent)<=0)){let U=JSON.stringify($.indent);throw Error(`"indent" option must be a positive integer, not ${U}`)}return N0$.stringifyDocument(this,$)}}function B6($){if(vU.isCollection($))return!0;throw Error("Expected a YAML collection as document contents")}H0$.Document=JH});var aI=J$((A0$)=>{class EY extends Error{constructor($,U,J,G){super();this.name=$,this.code=J,this.message=G,this.pos=U}}class Z3 extends EY{constructor($,U,J){super("YAMLParseError",$,U,J)}}class R3 extends EY{constructor($,U,J){super("YAMLWarning",$,U,J)}}var z0$=($,U)=>(J)=>{if(J.pos[0]===-1)return;J.linePos=J.pos.map((D)=>U.linePos(D));let{line:G,col:q}=J.linePos[0];J.message+=` at line ${G}, column ${q}`;let I=q-1,Q=$.substring(U.lineStarts[G-1],U.lineStarts[G]).replace(/[\n\r]+$/,"");if(I>=60&&Q.length>80){let D=Math.min(I-39,Q.length-79);Q="\u2026"+Q.substring(D),I-=D-1}if(Q.length>80)Q=Q.substring(0,79)+"\u2026";if(G>1&&/^ *$/.test(Q.substring(0,I))){let D=$.substring(U.lineStarts[G-2],U.lineStarts[G-1]);if(D.length>80)D=D.substring(0,79)+`\u2026
|
|
217
|
+
`;Q=D+Q}if(/[^ ]/.test(Q)){let D=1,X=J.linePos[1];if(X?.line===G&&X.col>q)D=Math.max(1,Math.min(X.col-q,80-I));let Y=" ".repeat(I)+"^".repeat(D);J.message+=`:
|
|
218
|
+
|
|
219
|
+
${Q}
|
|
220
|
+
${Y}
|
|
221
|
+
`}};A0$.YAMLError=EY;A0$.YAMLParseError=Z3;A0$.YAMLWarning=R3;A0$.prettifyError=z0$});var sI=J$((S0$)=>{function B0$($,{flow:U,indicator:J,next:G,offset:q,onError:I,parentIndent:Q,startOnNewline:D}){let X=!1,Y=D,V=D,W="",O="",Z=!1,M=!1,w=null,H=null,g=null,P=null,C=null,F=null,f=null;for(let b of $){if(M){if(b.type!=="space"&&b.type!=="newline"&&b.type!=="comma")I(b.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space");M=!1}if(w){if(Y&&b.type!=="comment"&&b.type!=="newline")I(w,"TAB_AS_INDENT","Tabs are not allowed as indentation");w=null}switch(b.type){case"space":if(!U&&(J!=="doc-start"||G?.type!=="flow-collection")&&b.source.includes("\t"))w=b;V=!0;break;case"comment":{if(!V)I(b,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");let h=b.source.substring(1)||" ";if(!W)W=h;else W+=O+h;O="",Y=!1;break}case"newline":if(Y){if(W)W+=b.source;else if(!F||J!=="seq-item-ind")X=!0}else O+=b.source;if(Y=!0,Z=!0,H||g)P=b;V=!0;break;case"anchor":if(H)I(b,"MULTIPLE_ANCHORS","A node can have at most one anchor");if(b.source.endsWith(":"))I(b.offset+b.source.length-1,"BAD_ALIAS","Anchor ending in : is ambiguous",!0);H=b,f??(f=b.offset),Y=!1,V=!1,M=!0;break;case"tag":{if(g)I(b,"MULTIPLE_TAGS","A node can have at most one tag");g=b,f??(f=b.offset),Y=!1,V=!1,M=!0;break}case J:if(H||g)I(b,"BAD_PROP_ORDER",`Anchors and tags must be after the ${b.source} indicator`);if(F)I(b,"UNEXPECTED_TOKEN",`Unexpected ${b.source} in ${U??"collection"}`);F=b,Y=J==="seq-item-ind"||J==="explicit-key-ind",V=!1;break;case"comma":if(U){if(C)I(b,"UNEXPECTED_TOKEN",`Unexpected , in ${U}`);C=b,Y=!1,V=!1;break}default:I(b,"UNEXPECTED_TOKEN",`Unexpected ${b.type} token`),Y=!1,V=!1}}let E=$[$.length-1],p=E?E.offset+E.source.length:q;if(M&&G&&G.type!=="space"&&G.type!=="newline"&&G.type!=="comma"&&(G.type!=="scalar"||G.source!==""))I(G.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space");if(w&&(Y&&w.indent<=Q||G?.type==="block-map"||G?.type==="block-seq"))I(w,"TAB_AS_INDENT","Tabs are not allowed as indentation");return{comma:C,found:F,spaceBefore:X,comment:W,hasNewline:Z,anchor:H,tag:g,newlineAfterProp:P,end:p,start:f??p}}S0$.resolveProps=B0$});var CY=J$((E0$)=>{function qH($){if(!$)return null;switch($.type){case"alias":case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":if($.source.includes(`
|
|
222
|
+
`))return!0;if($.end){for(let U of $.end)if(U.type==="newline")return!0}return!1;case"flow-collection":for(let U of $.items){for(let J of U.start)if(J.type==="newline")return!0;if(U.sep){for(let J of U.sep)if(J.type==="newline")return!0}if(qH(U.key)||qH(U.value))return!0}return!1;default:return!0}}E0$.containsNewline=qH});var GH=J$((F0$)=>{var _0$=CY();function v0$($,U,J){if(U?.type==="flow-collection"){let G=U.end[0];if(G.indent===$&&(G.source==="]"||G.source==="}")&&_0$.containsNewline(U))J(G,"BAD_INDENT","Flow end indicator should be more indented than parent",!0)}}F0$.flowIndentCheck=v0$});var IH=J$((k0$)=>{var N3=x$();function u0$($,U,J){let{uniqueKeys:G}=$.options;if(G===!1)return!1;let q=typeof G==="function"?G:(I,Q)=>I===Q||N3.isScalar(I)&&N3.isScalar(Q)&&I.value===Q.value;return U.some((I)=>q(I.key,J))}k0$.mapIncludes=u0$});var z3=J$((r0$)=>{var w3=Pq(),f0$=Sq(),M3=sI(),y0$=CY(),H3=GH(),m0$=IH(),T3="All mapping items must start at the same column";function h0$({composeNode:$,composeEmptyNode:U},J,G,q,I){let D=new(I?.nodeClass??f0$.YAMLMap)(J.schema);if(J.atRoot)J.atRoot=!1;let X=G.offset,Y=null;for(let V of G.items){let{start:W,key:O,sep:Z,value:M}=V,w=M3.resolveProps(W,{indicator:"explicit-key-ind",next:O??Z?.[0],offset:X,onError:q,parentIndent:G.indent,startOnNewline:!0}),H=!w.found;if(H){if(O){if(O.type==="block-seq")q(X,"BLOCK_AS_IMPLICIT_KEY","A block sequence may not be used as an implicit map key");else if("indent"in O&&O.indent!==G.indent)q(X,"BAD_INDENT",T3)}if(!w.anchor&&!w.tag&&!Z){if(Y=w.end,w.comment)if(D.comment)D.comment+=`
|
|
223
|
+
`+w.comment;else D.comment=w.comment;continue}if(w.newlineAfterProp||y0$.containsNewline(O))q(O??W[W.length-1],"MULTILINE_IMPLICIT_KEY","Implicit keys need to be on a single line")}else if(w.found?.indent!==G.indent)q(X,"BAD_INDENT",T3);J.atKey=!0;let g=w.end,P=O?$(J,O,w,q):U(J,g,W,null,w,q);if(J.schema.compat)H3.flowIndentCheck(G.indent,O,q);if(J.atKey=!1,m0$.mapIncludes(J,D.items,P))q(g,"DUPLICATE_KEY","Map keys must be unique");let C=M3.resolveProps(Z??[],{indicator:"map-value-ind",next:M,offset:P.range[2],onError:q,parentIndent:G.indent,startOnNewline:!O||O.type==="block-scalar"});if(X=C.end,C.found){if(H){if(M?.type==="block-map"&&!C.hasNewline)q(X,"BLOCK_AS_IMPLICIT_KEY","Nested mappings are not allowed in compact mappings");if(J.options.strict&&w.start<C.found.offset-1024)q(P.range,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit block mapping key")}let F=M?$(J,M,C,q):U(J,X,Z,null,C,q);if(J.schema.compat)H3.flowIndentCheck(G.indent,M,q);X=F.range[2];let f=new w3.Pair(P,F);if(J.options.keepSourceTokens)f.srcToken=V;D.items.push(f)}else{if(H)q(P.range,"MISSING_CHAR","Implicit map keys need to be followed by map values");if(C.comment)if(P.comment)P.comment+=`
|
|
224
|
+
`+C.comment;else P.comment=C.comment;let F=new w3.Pair(P);if(J.options.keepSourceTokens)F.srcToken=V;D.items.push(F)}}if(Y&&Y<X)q(Y,"IMPOSSIBLE","Map comment with trailing content");return D.range=[G.offset,X,Y??X],D}r0$.resolveBlockMap=h0$});var A3=J$((c0$)=>{var i0$=Lq(),p0$=sI(),d0$=GH();function n0$({composeNode:$,composeEmptyNode:U},J,G,q,I){let D=new(I?.nodeClass??i0$.YAMLSeq)(J.schema);if(J.atRoot)J.atRoot=!1;if(J.atKey)J.atKey=!1;let X=G.offset,Y=null;for(let{start:V,value:W}of G.items){let O=p0$.resolveProps(V,{indicator:"seq-item-ind",next:W,offset:X,onError:q,parentIndent:G.indent,startOnNewline:!0});if(!O.found)if(O.anchor||O.tag||W)if(W?.type==="block-seq")q(O.end,"BAD_INDENT","All sequence items must start at the same column");else q(X,"MISSING_CHAR","Sequence item without - indicator");else{if(Y=O.end,O.comment)D.comment=O.comment;continue}let Z=W?$(J,W,O,q):U(J,O.end,V,null,O,q);if(J.schema.compat)d0$.flowIndentCheck(G.indent,W,q);X=Z.range[2],D.items.push(Z)}return D.range=[G.offset,X,Y??X],D}c0$.resolveBlockSeq=n0$});var S6=J$((s0$)=>{function a0$($,U,J,G){let q="";if($){let I=!1,Q="";for(let D of $){let{source:X,type:Y}=D;switch(Y){case"space":I=!0;break;case"comment":{if(J&&!I)G(D,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");let V=X.substring(1)||" ";if(!q)q=V;else q+=Q+V;Q="";break}case"newline":if(q)Q+=X;I=!0;break;default:G(D,"UNEXPECTED_TOKEN",`Unexpected ${Y} at node end`)}U+=X.length}}return{comment:q,offset:U}}s0$.resolveEnd=a0$});var j3=J$((QU$)=>{var e0$=x$(),$U$=Pq(),K3=Sq(),UU$=Lq(),JU$=S6(),g3=sI(),qU$=CY(),GU$=IH(),QH="Block collections are not allowed within flow collections",DH=($)=>$&&($.type==="block-map"||$.type==="block-seq");function IU$({composeNode:$,composeEmptyNode:U},J,G,q,I){let Q=G.start.source==="{",D=Q?"flow map":"flow sequence",Y=new(I?.nodeClass??(Q?K3.YAMLMap:UU$.YAMLSeq))(J.schema);Y.flow=!0;let V=J.atRoot;if(V)J.atRoot=!1;if(J.atKey)J.atKey=!1;let W=G.offset+G.start.source.length;for(let H=0;H<G.items.length;++H){let g=G.items[H],{start:P,key:C,sep:F,value:f}=g,E=g3.resolveProps(P,{flow:D,indicator:"explicit-key-ind",next:C??F?.[0],offset:W,onError:q,parentIndent:G.indent,startOnNewline:!1});if(!E.found){if(!E.anchor&&!E.tag&&!F&&!f){if(H===0&&E.comma)q(E.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${D}`);else if(H<G.items.length-1)q(E.start,"UNEXPECTED_TOKEN",`Unexpected empty item in ${D}`);if(E.comment)if(Y.comment)Y.comment+=`
|
|
225
|
+
`+E.comment;else Y.comment=E.comment;W=E.end;continue}if(!Q&&J.options.strict&&qU$.containsNewline(C))q(C,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line")}if(H===0){if(E.comma)q(E.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${D}`)}else{if(!E.comma)q(E.start,"MISSING_CHAR",`Missing , between ${D} items`);if(E.comment){let p="";$:for(let b of P)switch(b.type){case"comma":case"space":break;case"comment":p=b.source.substring(1);break $;default:break $}if(p){let b=Y.items[Y.items.length-1];if(e0$.isPair(b))b=b.value??b.key;if(b.comment)b.comment+=`
|
|
226
|
+
`+p;else b.comment=p;E.comment=E.comment.substring(p.length+1)}}}if(!Q&&!F&&!E.found){let p=f?$(J,f,E,q):U(J,E.end,F,null,E,q);if(Y.items.push(p),W=p.range[2],DH(f))q(p.range,"BLOCK_IN_FLOW",QH)}else{J.atKey=!0;let p=E.end,b=C?$(J,C,E,q):U(J,p,P,null,E,q);if(DH(C))q(b.range,"BLOCK_IN_FLOW",QH);J.atKey=!1;let h=g3.resolveProps(F??[],{flow:D,indicator:"map-value-ind",next:f,offset:b.range[2],onError:q,parentIndent:G.indent,startOnNewline:!1});if(h.found){if(!Q&&!E.found&&J.options.strict){if(F)for(let _ of F){if(_===h.found)break;if(_.type==="newline"){q(_,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line");break}}if(E.start<h.found.offset-1024)q(h.found,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit flow sequence key")}}else if(f)if("source"in f&&f.source?.[0]===":")q(f,"MISSING_CHAR",`Missing space after : in ${D}`);else q(h.start,"MISSING_CHAR",`Missing , or : between ${D} items`);let s=f?$(J,f,h,q):h.found?U(J,h.end,F,null,h,q):null;if(s){if(DH(f))q(s.range,"BLOCK_IN_FLOW",QH)}else if(h.comment)if(b.comment)b.comment+=`
|
|
227
|
+
`+h.comment;else b.comment=h.comment;let m=new $U$.Pair(b,s);if(J.options.keepSourceTokens)m.srcToken=g;if(Q){let _=Y;if(GU$.mapIncludes(J,_.items,b))q(p,"DUPLICATE_KEY","Map keys must be unique");_.items.push(m)}else{let _=new K3.YAMLMap(J.schema);_.flow=!0,_.items.push(m);let v=(s??b).range;_.range=[b.range[0],v[1],v[2]],Y.items.push(_)}W=s?s.range[2]:h.end}}let O=Q?"}":"]",[Z,...M]=G.end,w=W;if(Z?.source===O)w=Z.offset+Z.source.length;else{let H=D[0].toUpperCase()+D.substring(1),g=V?`${H} must end with a ${O}`:`${H} in block collection must be sufficiently indented and end with a ${O}`;if(q(W,V?"MISSING_CHAR":"BAD_INDENT",g),Z&&Z.source.length!==1)M.unshift(Z)}if(M.length>0){let H=JU$.resolveEnd(M,w,J.options.strict,q);if(H.comment)if(Y.comment)Y.comment+=`
|
|
228
|
+
`+H.comment;else Y.comment=H.comment;Y.range=[G.offset,w,H.offset]}else Y.range=[G.offset,w,w];return Y}QU$.resolveFlowCollection=IU$});var P3=J$((wU$)=>{var XU$=x$(),YU$=D0(),VU$=Sq(),WU$=Lq(),OU$=z3(),ZU$=A3(),RU$=j3();function XH($,U,J,G,q,I){let Q=J.type==="block-map"?OU$.resolveBlockMap($,U,J,G,I):J.type==="block-seq"?ZU$.resolveBlockSeq($,U,J,G,I):RU$.resolveFlowCollection($,U,J,G,I),D=Q.constructor;if(q==="!"||q===D.tagName)return Q.tag=D.tagName,Q;if(q)Q.tag=q;return Q}function NU$($,U,J,G,q){let I=G.tag,Q=!I?null:U.directives.tagName(I.source,(O)=>q(I,"TAG_RESOLVE_FAILED",O));if(J.type==="block-seq"){let{anchor:O,newlineAfterProp:Z}=G,M=O&&I?O.offset>I.offset?O:I:O??I;if(M&&(!Z||Z.offset<M.offset))q(M,"MISSING_CHAR","Missing newline after block sequence props")}let D=J.type==="block-map"?"map":J.type==="block-seq"?"seq":J.start.source==="{"?"map":"seq";if(!I||!Q||Q==="!"||Q===VU$.YAMLMap.tagName&&D==="map"||Q===WU$.YAMLSeq.tagName&&D==="seq")return XH($,U,J,q,Q);let X=U.schema.tags.find((O)=>O.tag===Q&&O.collection===D);if(!X){let O=U.schema.knownTags[Q];if(O?.collection===D)U.schema.tags.push(Object.assign({},O,{default:!1})),X=O;else{if(O)q(I,"BAD_COLLECTION_TYPE",`${O.tag} used for ${D} collection, but expects ${O.collection??"scalar"}`,!0);else q(I,"TAG_RESOLVE_FAILED",`Unresolved tag: ${Q}`,!0);return XH($,U,J,q,Q)}}let Y=XH($,U,J,q,Q,X),V=X.resolve?.(Y,(O)=>q(I,"TAG_RESOLVE_FAILED",O),U.options)??Y,W=XU$.isNode(V)?V:new YU$.Scalar(V);if(W.range=Y.range,W.tag=Q,X?.format)W.format=X.format;return W}wU$.composeCollection=NU$});var VH=J$((AU$)=>{var YH=D0();function HU$($,U,J){let G=U.offset,q=TU$(U,$.options.strict,J);if(!q)return{value:"",type:null,comment:"",range:[G,G,G]};let I=q.mode===">"?YH.Scalar.BLOCK_FOLDED:YH.Scalar.BLOCK_LITERAL,Q=U.source?zU$(U.source):[],D=Q.length;for(let w=Q.length-1;w>=0;--w){let H=Q[w][1];if(H===""||H==="\r")D=w;else break}if(D===0){let w=q.chomp==="+"&&Q.length>0?`
|
|
229
|
+
`.repeat(Math.max(1,Q.length-1)):"",H=G+q.length;if(U.source)H+=U.source.length;return{value:w,type:I,comment:q.comment,range:[G,H,H]}}let X=U.indent+q.indent,Y=U.offset+q.length,V=0;for(let w=0;w<D;++w){let[H,g]=Q[w];if(g===""||g==="\r"){if(q.indent===0&&H.length>X)X=H.length}else{if(H.length<X)J(Y+H.length,"MISSING_CHAR","Block scalars with more-indented leading empty lines must use an explicit indentation indicator");if(q.indent===0)X=H.length;if(V=w,X===0&&!$.atRoot)J(Y,"BAD_INDENT","Block scalar values in collections must be indented");break}Y+=H.length+g.length+1}for(let w=Q.length-1;w>=D;--w)if(Q[w][0].length>X)D=w+1;let W="",O="",Z=!1;for(let w=0;w<V;++w)W+=Q[w][0].slice(X)+`
|
|
230
|
+
`;for(let w=V;w<D;++w){let[H,g]=Q[w];Y+=H.length+g.length+1;let P=g[g.length-1]==="\r";if(P)g=g.slice(0,-1);if(g&&H.length<X){let F=`Block scalar lines must not be less indented than their ${q.indent?"explicit indentation indicator":"first line"}`;J(Y-g.length-(P?2:1),"BAD_INDENT",F),H=""}if(I===YH.Scalar.BLOCK_LITERAL)W+=O+H.slice(X)+g,O=`
|
|
231
|
+
`;else if(H.length>X||g[0]==="\t"){if(O===" ")O=`
|
|
232
|
+
`;else if(!Z&&O===`
|
|
233
|
+
`)O=`
|
|
234
|
+
|
|
235
|
+
`;W+=O+H.slice(X)+g,O=`
|
|
236
|
+
`,Z=!0}else if(g==="")if(O===`
|
|
237
|
+
`)W+=`
|
|
238
|
+
`;else O=`
|
|
239
|
+
`;else W+=O+g,O=" ",Z=!1}switch(q.chomp){case"-":break;case"+":for(let w=D;w<Q.length;++w)W+=`
|
|
240
|
+
`+Q[w][0].slice(X);if(W[W.length-1]!==`
|
|
241
|
+
`)W+=`
|
|
242
|
+
`;break;default:W+=`
|
|
243
|
+
`}let M=G+q.length+U.source.length;return{value:W,type:I,comment:q.comment,range:[G,M,M]}}function TU$({offset:$,props:U},J,G){if(U[0].type!=="block-scalar-header")return G(U[0],"IMPOSSIBLE","Block scalar header not found"),null;let{source:q}=U[0],I=q[0],Q=0,D="",X=-1;for(let O=1;O<q.length;++O){let Z=q[O];if(!D&&(Z==="-"||Z==="+"))D=Z;else{let M=Number(Z);if(!Q&&M)Q=M;else if(X===-1)X=$+O}}if(X!==-1)G(X,"UNEXPECTED_TOKEN",`Block scalar header includes extra characters: ${q}`);let Y=!1,V="",W=q.length;for(let O=1;O<U.length;++O){let Z=U[O];switch(Z.type){case"space":Y=!0;case"newline":W+=Z.source.length;break;case"comment":if(J&&!Y)G(Z,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");W+=Z.source.length,V=Z.source.substring(1);break;case"error":G(Z,"UNEXPECTED_TOKEN",Z.message),W+=Z.source.length;break;default:{let M=`Unexpected token in block scalar header: ${Z.type}`;G(Z,"UNEXPECTED_TOKEN",M);let w=Z.source;if(w&&typeof w==="string")W+=w.length}}}return{mode:I,indent:Q,chomp:D,comment:V,length:W}}function zU$($){let U=$.split(/\n( *)/),J=U[0],G=J.match(/^( *)/),I=[G?.[1]?[G[1],J.slice(G[1].length)]:["",J]];for(let Q=1;Q<U.length;Q+=2)I.push([U[Q],U[Q+1]]);return I}AU$.resolveBlockScalar=HU$});var OH=J$((_U$)=>{var WH=D0(),gU$=S6();function jU$($,U,J){let{offset:G,type:q,source:I,end:Q}=$,D,X,Y=(O,Z,M)=>J(G+O,Z,M);switch(q){case"scalar":D=WH.Scalar.PLAIN,X=PU$(I,Y);break;case"single-quoted-scalar":D=WH.Scalar.QUOTE_SINGLE,X=BU$(I,Y);break;case"double-quoted-scalar":D=WH.Scalar.QUOTE_DOUBLE,X=SU$(I,Y);break;default:return J($,"UNEXPECTED_TOKEN",`Expected a flow scalar value, but found: ${q}`),{value:"",type:null,comment:"",range:[G,G+I.length,G+I.length]}}let V=G+I.length,W=gU$.resolveEnd(Q,V,U,J);return{value:X,type:D,comment:W.comment,range:[G,V,W.offset]}}function PU$($,U){let J="";switch($[0]){case"\t":J="a tab character";break;case",":J="flow indicator character ,";break;case"%":J="directive indicator character %";break;case"|":case">":{J=`block scalar indicator ${$[0]}`;break}case"@":case"`":{J=`reserved character ${$[0]}`;break}}if(J)U(0,"BAD_SCALAR_START",`Plain value cannot start with ${J}`);return B3($)}function BU$($,U){if($[$.length-1]!=="'"||$.length===1)U($.length,"MISSING_CHAR","Missing closing 'quote");return B3($.slice(1,-1)).replace(/''/g,"'")}function B3($){let U,J;try{U=new RegExp(`(.*?)(?<![ ])[ ]*\r?
|
|
244
|
+
`,"sy"),J=new RegExp(`[ ]*(.*?)(?:(?<![ ])[ ]*)?\r?
|
|
245
|
+
`,"sy")}catch{U=/(.*?)[ \t]*\r?\n/sy,J=/[ \t]*(.*?)[ \t]*\r?\n/sy}let G=U.exec($);if(!G)return $;let q=G[1],I=" ",Q=U.lastIndex;J.lastIndex=Q;while(G=J.exec($)){if(G[1]==="")if(I===`
|
|
246
|
+
`)q+=I;else I=`
|
|
247
|
+
`;else q+=I+G[1],I=" ";Q=J.lastIndex}let D=/[ \t]*(.*)/sy;return D.lastIndex=Q,G=D.exec($),q+I+(G?.[1]??"")}function SU$($,U){let J="";for(let G=1;G<$.length-1;++G){let q=$[G];if(q==="\r"&&$[G+1]===`
|
|
248
|
+
`)continue;if(q===`
|
|
249
|
+
`){let{fold:I,offset:Q}=LU$($,G);J+=I,G=Q}else if(q==="\\"){let I=$[++G],Q=EU$[I];if(Q)J+=Q;else if(I===`
|
|
250
|
+
`){I=$[G+1];while(I===" "||I==="\t")I=$[++G+1]}else if(I==="\r"&&$[G+1]===`
|
|
251
|
+
`){I=$[++G+1];while(I===" "||I==="\t")I=$[++G+1]}else if(I==="x"||I==="u"||I==="U"){let D=I==="x"?2:I==="u"?4:8;J+=CU$($,G+1,D,U),G+=D}else{let D=$.substr(G-1,2);U(G-1,"BAD_DQ_ESCAPE",`Invalid escape sequence ${D}`),J+=D}}else if(q===" "||q==="\t"){let I=G,Q=$[G+1];while(Q===" "||Q==="\t")Q=$[++G+1];if(Q!==`
|
|
252
|
+
`&&!(Q==="\r"&&$[G+2]===`
|
|
253
|
+
`))J+=G>I?$.slice(I,G+1):q}else J+=q}if($[$.length-1]!=='"'||$.length===1)U($.length,"MISSING_CHAR",'Missing closing "quote');return J}function LU$($,U){let J="",G=$[U+1];while(G===" "||G==="\t"||G===`
|
|
254
|
+
`||G==="\r"){if(G==="\r"&&$[U+2]!==`
|
|
255
|
+
`)break;if(G===`
|
|
256
|
+
`)J+=`
|
|
257
|
+
`;U+=1,G=$[U+1]}if(!J)J=" ";return{fold:J,offset:U}}var EU$={"0":"\x00",a:"\x07",b:"\b",e:"\x1B",f:"\f",n:`
|
|
258
|
+
`,r:"\r",t:"\t",v:"\v",N:"\x85",_:"\xA0",L:"\u2028",P:"\u2029"," ":" ",'"':'"',"/":"/","\\":"\\","\t":"\t"};function CU$($,U,J,G){let q=$.substr(U,J),Q=q.length===J&&/^[0-9a-fA-F]+$/.test(q)?parseInt(q,16):NaN;try{return String.fromCodePoint(Q)}catch{let D=$.substr(U-2,J+2);return G(U-2,"BAD_DQ_ESCAPE",`Invalid escape sequence ${D}`),D}}_U$.resolveFlowScalar=jU$});var L3=J$((fU$)=>{var kG=x$(),S3=D0(),FU$=VH(),bU$=OH();function uU$($,U,J,G){let{value:q,type:I,comment:Q,range:D}=U.type==="block-scalar"?FU$.resolveBlockScalar($,U,G):bU$.resolveFlowScalar(U,$.options.strict,G),X=J?$.directives.tagName(J.source,(W)=>G(J,"TAG_RESOLVE_FAILED",W)):null,Y;if($.options.stringKeys&&$.atKey)Y=$.schema[kG.SCALAR];else if(X)Y=kU$($.schema,q,X,J,G);else if(U.type==="scalar")Y=xU$($,q,U,G);else Y=$.schema[kG.SCALAR];let V;try{let W=Y.resolve(q,(O)=>G(J??U,"TAG_RESOLVE_FAILED",O),$.options);V=kG.isScalar(W)?W:new S3.Scalar(W)}catch(W){let O=W instanceof Error?W.message:String(W);G(J??U,"TAG_RESOLVE_FAILED",O),V=new S3.Scalar(q)}if(V.range=D,V.source=q,I)V.type=I;if(X)V.tag=X;if(Y.format)V.format=Y.format;if(Q)V.comment=Q;return V}function kU$($,U,J,G,q){if(J==="!")return $[kG.SCALAR];let I=[];for(let D of $.tags)if(!D.collection&&D.tag===J)if(D.default&&D.test)I.push(D);else return D;for(let D of I)if(D.test?.test(U))return D;let Q=$.knownTags[J];if(Q&&!Q.collection)return $.tags.push(Object.assign({},Q,{default:!1,test:void 0})),Q;return q(G,"TAG_RESOLVE_FAILED",`Unresolved tag: ${J}`,J!=="tag:yaml.org,2002:str"),$[kG.SCALAR]}function xU$({atKey:$,directives:U,schema:J},G,q,I){let Q=J.tags.find((D)=>(D.default===!0||$&&D.default==="key")&&D.test?.test(G))||J[kG.SCALAR];if(J.compat){let D=J.compat.find((X)=>X.default&&X.test?.test(G))??J[kG.SCALAR];if(Q.tag!==D.tag){let X=U.tagString(Q.tag),Y=U.tagString(D.tag),V=`Value may be parsed as either ${X} or ${Y}`;I(q,"TAG_RESOLVE_FAILED",V,!0)}}return Q}fU$.composeScalar=uU$});var E3=J$((hU$)=>{function mU$($,U,J){if(U){J??(J=U.length);for(let G=J-1;G>=0;--G){let q=U[G];switch(q.type){case"space":case"comment":case"newline":$-=q.source.length;continue}q=U[++G];while(q?.type==="space")$+=q.source.length,q=U[++G];break}}return $}hU$.emptyScalarPosition=mU$});var v3=J$((aU$)=>{var lU$=uI(),iU$=x$(),pU$=P3(),C3=L3(),dU$=S6(),nU$=E3(),cU$={composeNode:_3,composeEmptyNode:ZH};function _3($,U,J,G){let q=$.atKey,{spaceBefore:I,comment:Q,anchor:D,tag:X}=J,Y,V=!0;switch(U.type){case"alias":if(Y=oU$($,U,G),D||X)G(U,"ALIAS_PROPS","An alias node must not specify any properties");break;case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"block-scalar":if(Y=C3.composeScalar($,U,X,G),D)Y.anchor=D.source.substring(1);break;case"block-map":case"block-seq":case"flow-collection":try{if(Y=pU$.composeCollection(cU$,$,U,J,G),D)Y.anchor=D.source.substring(1)}catch(W){let O=W instanceof Error?W.message:String(W);G(U,"RESOURCE_EXHAUSTION",O)}break;default:{let W=U.type==="error"?U.message:`Unsupported token (type: ${U.type})`;G(U,"UNEXPECTED_TOKEN",W),V=!1}}if(Y??(Y=ZH($,U.offset,void 0,null,J,G)),D&&Y.anchor==="")G(D,"BAD_ALIAS","Anchor cannot be an empty string");if(q&&$.options.stringKeys&&(!iU$.isScalar(Y)||typeof Y.value!=="string"||Y.tag&&Y.tag!=="tag:yaml.org,2002:str"))G(X??U,"NON_STRING_KEY","With stringKeys, all keys must be strings");if(I)Y.spaceBefore=!0;if(Q)if(U.type==="scalar"&&U.source==="")Y.comment=Q;else Y.commentBefore=Q;if($.options.keepSourceTokens&&V)Y.srcToken=U;return Y}function ZH($,U,J,G,{spaceBefore:q,comment:I,anchor:Q,tag:D,end:X},Y){let V={type:"scalar",offset:nU$.emptyScalarPosition(U,J,G),indent:-1,source:""},W=C3.composeScalar($,V,D,Y);if(Q){if(W.anchor=Q.source.substring(1),W.anchor==="")Y(Q,"BAD_ALIAS","Anchor cannot be an empty string")}if(q)W.spaceBefore=!0;if(I)W.comment=I,W.range[2]=X;return W}function oU$({options:$},{offset:U,source:J,end:G},q){let I=new lU$.Alias(J.substring(1));if(I.source==="")q(U,"BAD_ALIAS","Alias cannot be an empty string");if(I.source.endsWith(":"))q(U+J.length-1,"BAD_ALIAS","Alias ending in : is ambiguous",!0);let Q=U+J.length,D=dU$.resolveEnd(G,Q,$.strict,q);if(I.range=[U,Q,D.offset],D.comment)I.comment=D.comment;return I}aU$.composeEmptyNode=ZH;aU$.composeNode=_3});var b3=J$((qJ$)=>{var eU$=oI(),F3=v3(),$J$=S6(),UJ$=sI();function JJ$($,U,{offset:J,start:G,value:q,end:I},Q){let D=Object.assign({_directives:U},$),X=new eU$.Document(void 0,D),Y={atKey:!1,atRoot:!0,directives:X.directives,options:X.options,schema:X.schema},V=UJ$.resolveProps(G,{indicator:"doc-start",next:q??I?.[0],offset:J,onError:Q,parentIndent:0,startOnNewline:!0});if(V.found){if(X.directives.docStart=!0,q&&(q.type==="block-map"||q.type==="block-seq")&&!V.hasNewline)Q(V.end,"MISSING_CHAR","Block collection cannot start on same line with directives-end marker")}X.contents=q?F3.composeNode(Y,q,V,Q):F3.composeEmptyNode(Y,V.end,G,null,V,Q);let W=X.contents.range[2],O=$J$.resolveEnd(I,W,!1,Q);if(O.comment)X.comment=O.comment;return X.range=[J,W,O.offset],X}qJ$.composeDoc=JJ$});var RH=J$((VJ$)=>{var IJ$=WU("process"),QJ$=HM(),DJ$=oI(),tI=aI(),u3=x$(),XJ$=b3(),YJ$=S6();function eI($){if(typeof $==="number")return[$,$+1];if(Array.isArray($))return $.length===2?$:[$[0],$[1]];let{offset:U,source:J}=$;return[U,U+(typeof J==="string"?J.length:1)]}function k3($){let U="",J=!1,G=!1;for(let q=0;q<$.length;++q){let I=$[q];switch(I[0]){case"#":U+=(U===""?"":G?`
|
|
259
|
+
|
|
260
|
+
`:`
|
|
261
|
+
`)+(I.substring(1)||" "),J=!0,G=!1;break;case"%":if($[q+1]?.[0]!=="#")q+=1;J=!1;break;default:if(!J)G=!0;J=!1}}return{comment:U,afterEmptyLine:G}}class x3{constructor($={}){this.doc=null,this.atDirectives=!1,this.prelude=[],this.errors=[],this.warnings=[],this.onError=(U,J,G,q)=>{let I=eI(U);if(q)this.warnings.push(new tI.YAMLWarning(I,J,G));else this.errors.push(new tI.YAMLParseError(I,J,G))},this.directives=new QJ$.Directives({version:$.version||"1.2"}),this.options=$}decorate($,U){let{comment:J,afterEmptyLine:G}=k3(this.prelude);if(J){let q=$.contents;if(U)$.comment=$.comment?`${$.comment}
|
|
262
|
+
${J}`:J;else if(G||$.directives.docStart||!q)$.commentBefore=J;else if(u3.isCollection(q)&&!q.flow&&q.items.length>0){let I=q.items[0];if(u3.isPair(I))I=I.key;let Q=I.commentBefore;I.commentBefore=Q?`${J}
|
|
263
|
+
${Q}`:J}else{let I=q.commentBefore;q.commentBefore=I?`${J}
|
|
264
|
+
${I}`:J}}if(U){for(let q=0;q<this.errors.length;++q)$.errors.push(this.errors[q]);for(let q=0;q<this.warnings.length;++q)$.warnings.push(this.warnings[q])}else $.errors=this.errors,$.warnings=this.warnings;this.prelude=[],this.errors=[],this.warnings=[]}streamInfo(){return{comment:k3(this.prelude).comment,directives:this.directives,errors:this.errors,warnings:this.warnings}}*compose($,U=!1,J=-1){for(let G of $)yield*this.next(G);yield*this.end(U,J)}*next($){if(IJ$.env.LOG_STREAM)console.dir($,{depth:null});switch($.type){case"directive":this.directives.add($.source,(U,J,G)=>{let q=eI($);q[0]+=U,this.onError(q,"BAD_DIRECTIVE",J,G)}),this.prelude.push($.source),this.atDirectives=!0;break;case"document":{let U=XJ$.composeDoc(this.options,this.directives,$,this.onError);if(this.atDirectives&&!U.directives.docStart)this.onError($,"MISSING_CHAR","Missing directives-end/doc-start indicator line");if(this.decorate(U,!1),this.doc)yield this.doc;this.doc=U,this.atDirectives=!1;break}case"byte-order-mark":case"space":break;case"comment":case"newline":this.prelude.push($.source);break;case"error":{let U=$.source?`${$.message}: ${JSON.stringify($.source)}`:$.message,J=new tI.YAMLParseError(eI($),"UNEXPECTED_TOKEN",U);if(this.atDirectives||!this.doc)this.errors.push(J);else this.doc.errors.push(J);break}case"doc-end":{if(!this.doc){this.errors.push(new tI.YAMLParseError(eI($),"UNEXPECTED_TOKEN","Unexpected doc-end without preceding document"));break}this.doc.directives.docEnd=!0;let U=YJ$.resolveEnd($.end,$.offset+$.source.length,this.doc.options.strict,this.onError);if(this.decorate(this.doc,!0),U.comment){let J=this.doc.comment;this.doc.comment=J?`${J}
|
|
265
|
+
${U.comment}`:U.comment}this.doc.range[2]=U.offset;break}default:this.errors.push(new tI.YAMLParseError(eI($),"UNEXPECTED_TOKEN",`Unsupported token ${$.type}`))}}*end($=!1,U=-1){if(this.doc)this.decorate(this.doc,!0),yield this.doc,this.doc=null;else if($){let J=Object.assign({_directives:this.directives},this.options),G=new DJ$.Document(void 0,J);if(this.atDirectives)this.onError(U,"MISSING_CHAR","Missing directives-end indicator line");G.range=[0,U,U],this.decorate(G,!1),yield G}}}VJ$.Composer=x3});var m3=J$((TJ$)=>{var OJ$=VH(),ZJ$=OH(),RJ$=aI(),f3=yI();function NJ$($,U=!0,J){if($){let G=(q,I,Q)=>{let D=typeof q==="number"?q:Array.isArray(q)?q[0]:q.offset;if(J)J(D,I,Q);else throw new RJ$.YAMLParseError([D,D+1],I,Q)};switch($.type){case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return ZJ$.resolveFlowScalar($,U,G);case"block-scalar":return OJ$.resolveBlockScalar({options:{strict:U}},$,G)}}return null}function wJ$($,U){let{implicitKey:J=!1,indent:G,inFlow:q=!1,offset:I=-1,type:Q="PLAIN"}=U,D=f3.stringifyString({type:Q,value:$},{implicitKey:J,indent:G>0?" ".repeat(G):"",inFlow:q,options:{blockQuote:!0,lineWidth:-1}}),X=U.end??[{type:"newline",offset:-1,indent:G,source:`
|
|
266
|
+
`}];switch(D[0]){case"|":case">":{let Y=D.indexOf(`
|
|
267
|
+
`),V=D.substring(0,Y),W=D.substring(Y+1)+`
|
|
268
|
+
`,O=[{type:"block-scalar-header",offset:I,indent:G,source:V}];if(!y3(O,X))O.push({type:"newline",offset:-1,indent:G,source:`
|
|
269
|
+
`});return{type:"block-scalar",offset:I,indent:G,props:O,source:W}}case'"':return{type:"double-quoted-scalar",offset:I,indent:G,source:D,end:X};case"'":return{type:"single-quoted-scalar",offset:I,indent:G,source:D,end:X};default:return{type:"scalar",offset:I,indent:G,source:D,end:X}}}function MJ$($,U,J={}){let{afterKey:G=!1,implicitKey:q=!1,inFlow:I=!1,type:Q}=J,D="indent"in $?$.indent:null;if(G&&typeof D==="number")D+=2;if(!Q)switch($.type){case"single-quoted-scalar":Q="QUOTE_SINGLE";break;case"double-quoted-scalar":Q="QUOTE_DOUBLE";break;case"block-scalar":{let Y=$.props[0];if(Y.type!=="block-scalar-header")throw Error("Invalid block scalar header");Q=Y.source[0]===">"?"BLOCK_FOLDED":"BLOCK_LITERAL";break}default:Q="PLAIN"}let X=f3.stringifyString({type:Q,value:U},{implicitKey:q||D===null,indent:D!==null&&D>0?" ".repeat(D):"",inFlow:I,options:{blockQuote:!0,lineWidth:-1}});switch(X[0]){case"|":case">":HJ$($,X);break;case'"':NH($,X,"double-quoted-scalar");break;case"'":NH($,X,"single-quoted-scalar");break;default:NH($,X,"scalar")}}function HJ$($,U){let J=U.indexOf(`
|
|
270
|
+
`),G=U.substring(0,J),q=U.substring(J+1)+`
|
|
271
|
+
`;if($.type==="block-scalar"){let I=$.props[0];if(I.type!=="block-scalar-header")throw Error("Invalid block scalar header");I.source=G,$.source=q}else{let{offset:I}=$,Q="indent"in $?$.indent:-1,D=[{type:"block-scalar-header",offset:I,indent:Q,source:G}];if(!y3(D,"end"in $?$.end:void 0))D.push({type:"newline",offset:-1,indent:Q,source:`
|
|
272
|
+
`});for(let X of Object.keys($))if(X!=="type"&&X!=="offset")delete $[X];Object.assign($,{type:"block-scalar",indent:Q,props:D,source:q})}}function y3($,U){if(U)for(let J of U)switch(J.type){case"space":case"comment":$.push(J);break;case"newline":return $.push(J),!0}return!1}function NH($,U,J){switch($.type){case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":$.type=J,$.source=U;break;case"block-scalar":{let G=$.props.slice(1),q=U.length;if($.props[0].type==="block-scalar-header")q-=$.props[0].source.length;for(let I of G)I.offset+=q;delete $.props,Object.assign($,{type:J,source:U,end:G});break}case"block-map":case"block-seq":{let q={type:"newline",offset:$.offset+U.length,indent:$.indent,source:`
|
|
273
|
+
`};delete $.items,Object.assign($,{type:J,source:U,end:[q]});break}default:{let G="indent"in $?$.indent:-1,q="end"in $&&Array.isArray($.end)?$.end.filter((I)=>I.type==="space"||I.type==="comment"||I.type==="newline"):[];for(let I of Object.keys($))if(I!=="type"&&I!=="offset")delete $[I];Object.assign($,{type:J,indent:G,source:U,end:q})}}}TJ$.createScalarToken=wJ$;TJ$.resolveAsScalar=NJ$;TJ$.setScalarValue=MJ$});var h3=J$((jJ$)=>{var gJ$=($)=>("type"in $)?vY($):_Y($);function vY($){switch($.type){case"block-scalar":{let U="";for(let J of $.props)U+=vY(J);return U+$.source}case"block-map":case"block-seq":{let U="";for(let J of $.items)U+=_Y(J);return U}case"flow-collection":{let U=$.start.source;for(let J of $.items)U+=_Y(J);for(let J of $.end)U+=J.source;return U}case"document":{let U=_Y($);if($.end)for(let J of $.end)U+=J.source;return U}default:{let U=$.source;if("end"in $&&$.end)for(let J of $.end)U+=J.source;return U}}}function _Y({start:$,key:U,sep:J,value:G}){let q="";for(let I of $)q+=I.source;if(U)q+=vY(U);if(J)for(let I of J)q+=I.source;if(G)q+=vY(G);return q}jJ$.stringify=gJ$});var i3=J$((SJ$)=>{var wH=Symbol("break visit"),BJ$=Symbol("skip children"),r3=Symbol("remove item");function xG($,U){if("type"in $&&$.type==="document")$={start:$.start,value:$.value};l3(Object.freeze([]),$,U)}xG.BREAK=wH;xG.SKIP=BJ$;xG.REMOVE=r3;xG.itemAtPath=($,U)=>{let J=$;for(let[G,q]of U){let I=J?.[G];if(I&&"items"in I)J=I.items[q];else return}return J};xG.parentCollection=($,U)=>{let J=xG.itemAtPath($,U.slice(0,-1)),G=U[U.length-1][0],q=J?.[G];if(q&&"items"in q)return q;throw Error("Parent collection not found")};function l3($,U,J){let G=J(U,$);if(typeof G==="symbol")return G;for(let q of["key","value"]){let I=U[q];if(I&&"items"in I){for(let Q=0;Q<I.items.length;++Q){let D=l3(Object.freeze($.concat([[q,Q]])),I.items[Q],J);if(typeof D==="number")Q=D-1;else if(D===wH)return wH;else if(D===r3)I.items.splice(Q,1),Q-=1}if(typeof G==="function"&&q==="key")G=G(U,$)}}return typeof G==="function"?G(U,$):G}SJ$.visit=xG});var FY=J$((uJ$)=>{var MH=m3(),EJ$=h3(),CJ$=i3(),HH="\uFEFF",TH="\x02",zH="\x18",AH="\x1F",_J$=($)=>!!$&&("items"in $),vJ$=($)=>!!$&&($.type==="scalar"||$.type==="single-quoted-scalar"||$.type==="double-quoted-scalar"||$.type==="block-scalar");function FJ$($){switch($){case HH:return"<BOM>";case TH:return"<DOC>";case zH:return"<FLOW_END>";case AH:return"<SCALAR>";default:return JSON.stringify($)}}function bJ$($){switch($){case HH:return"byte-order-mark";case TH:return"doc-mode";case zH:return"flow-error-end";case AH:return"scalar";case"---":return"doc-start";case"...":return"doc-end";case"":case`
|
|
274
|
+
`:case`\r
|
|
275
|
+
`:return"newline";case"-":return"seq-item-ind";case"?":return"explicit-key-ind";case":":return"map-value-ind";case"{":return"flow-map-start";case"}":return"flow-map-end";case"[":return"flow-seq-start";case"]":return"flow-seq-end";case",":return"comma"}switch($[0]){case" ":case"\t":return"space";case"#":return"comment";case"%":return"directive-line";case"*":return"alias";case"&":return"anchor";case"!":return"tag";case"'":return"single-quoted-scalar";case'"':return"double-quoted-scalar";case"|":case">":return"block-scalar-header"}return null}uJ$.createScalarToken=MH.createScalarToken;uJ$.resolveAsScalar=MH.resolveAsScalar;uJ$.setScalarValue=MH.setScalarValue;uJ$.stringify=EJ$.stringify;uJ$.visit=CJ$.visit;uJ$.BOM=HH;uJ$.DOCUMENT=TH;uJ$.FLOW_END=zH;uJ$.SCALAR=AH;uJ$.isCollection=_J$;uJ$.isScalar=vJ$;uJ$.prettyToken=FJ$;uJ$.tokenType=bJ$});var gH=J$((sJ$)=>{var $Q=FY();function lU($){switch($){case void 0:case" ":case`
|
|
276
|
+
`:case"\r":case"\t":return!0;default:return!1}}var p3=new Set("0123456789ABCDEFabcdef"),oJ$=new Set("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()"),bY=new Set(",[]{}"),aJ$=new Set(` ,[]{}
|
|
277
|
+
\r `),KH=($)=>!$||aJ$.has($);class d3{constructor(){this.atEnd=!1,this.blockScalarIndent=-1,this.blockScalarKeep=!1,this.buffer="",this.flowKey=!1,this.flowLevel=0,this.indentNext=0,this.indentValue=0,this.lineEndPos=null,this.next=null,this.pos=0}*lex($,U=!1){if($){if(typeof $!=="string")throw TypeError("source is not a string");this.buffer=this.buffer?this.buffer+$:$,this.lineEndPos=null}this.atEnd=!U;let J=this.next??"stream";while(J&&(U||this.hasChars(1)))J=yield*this.parseNext(J)}atLineEnd(){let $=this.pos,U=this.buffer[$];while(U===" "||U==="\t")U=this.buffer[++$];if(!U||U==="#"||U===`
|
|
278
|
+
`)return!0;if(U==="\r")return this.buffer[$+1]===`
|
|
279
|
+
`;return!1}charAt($){return this.buffer[this.pos+$]}continueScalar($){let U=this.buffer[$];if(this.indentNext>0){let J=0;while(U===" ")U=this.buffer[++J+$];if(U==="\r"){let G=this.buffer[J+$+1];if(G===`
|
|
280
|
+
`||!G&&!this.atEnd)return $+J+1}return U===`
|
|
281
|
+
`||J>=this.indentNext||!U&&!this.atEnd?$+J:-1}if(U==="-"||U==="."){let J=this.buffer.substr($,3);if((J==="---"||J==="...")&&lU(this.buffer[$+3]))return-1}return $}getLine(){let $=this.lineEndPos;if(typeof $!=="number"||$!==-1&&$<this.pos)$=this.buffer.indexOf(`
|
|
282
|
+
`,this.pos),this.lineEndPos=$;if($===-1)return this.atEnd?this.buffer.substring(this.pos):null;if(this.buffer[$-1]==="\r")$-=1;return this.buffer.substring(this.pos,$)}hasChars($){return this.pos+$<=this.buffer.length}setNext($){return this.buffer=this.buffer.substring(this.pos),this.pos=0,this.lineEndPos=null,this.next=$,null}peek($){return this.buffer.substr(this.pos,$)}*parseNext($){switch($){case"stream":return yield*this.parseStream();case"line-start":return yield*this.parseLineStart();case"block-start":return yield*this.parseBlockStart();case"doc":return yield*this.parseDocument();case"flow":return yield*this.parseFlowCollection();case"quoted-scalar":return yield*this.parseQuotedScalar();case"block-scalar":return yield*this.parseBlockScalar();case"plain-scalar":return yield*this.parsePlainScalar()}}*parseStream(){let $=this.getLine();if($===null)return this.setNext("stream");if($[0]===$Q.BOM)yield*this.pushCount(1),$=$.substring(1);if($[0]==="%"){let U=$.length,J=$.indexOf("#");while(J!==-1){let q=$[J-1];if(q===" "||q==="\t"){U=J-1;break}else J=$.indexOf("#",J+1)}while(!0){let q=$[U-1];if(q===" "||q==="\t")U-=1;else break}let G=(yield*this.pushCount(U))+(yield*this.pushSpaces(!0));return yield*this.pushCount($.length-G),this.pushNewline(),"stream"}if(this.atLineEnd()){let U=yield*this.pushSpaces(!0);return yield*this.pushCount($.length-U),yield*this.pushNewline(),"stream"}return yield $Q.DOCUMENT,yield*this.parseLineStart()}*parseLineStart(){let $=this.charAt(0);if(!$&&!this.atEnd)return this.setNext("line-start");if($==="-"||$==="."){if(!this.atEnd&&!this.hasChars(4))return this.setNext("line-start");let U=this.peek(3);if((U==="---"||U==="...")&&lU(this.charAt(3)))return yield*this.pushCount(3),this.indentValue=0,this.indentNext=0,U==="---"?"doc":"stream"}if(this.indentValue=yield*this.pushSpaces(!1),this.indentNext>this.indentValue&&!lU(this.charAt(1)))this.indentNext=this.indentValue;return yield*this.parseBlockStart()}*parseBlockStart(){let[$,U]=this.peek(2);if(!U&&!this.atEnd)return this.setNext("block-start");if(($==="-"||$==="?"||$===":")&&lU(U)){let J=(yield*this.pushCount(1))+(yield*this.pushSpaces(!0));return this.indentNext=this.indentValue+1,this.indentValue+=J,"block-start"}return"doc"}*parseDocument(){yield*this.pushSpaces(!0);let $=this.getLine();if($===null)return this.setNext("doc");let U=yield*this.pushIndicators();switch($[U]){case"#":yield*this.pushCount($.length-U);case void 0:return yield*this.pushNewline(),yield*this.parseLineStart();case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel=1,"flow";case"}":case"]":return yield*this.pushCount(1),"doc";case"*":return yield*this.pushUntil(KH),"doc";case'"':case"'":return yield*this.parseQuotedScalar();case"|":case">":return U+=yield*this.parseBlockScalarHeader(),U+=yield*this.pushSpaces(!0),yield*this.pushCount($.length-U),yield*this.pushNewline(),yield*this.parseBlockScalar();default:return yield*this.parsePlainScalar()}}*parseFlowCollection(){let $,U,J=-1;do{if($=yield*this.pushNewline(),$>0)U=yield*this.pushSpaces(!1),this.indentValue=J=U;else U=0;U+=yield*this.pushSpaces(!0)}while($+U>0);let G=this.getLine();if(G===null)return this.setNext("flow");if(J!==-1&&J<this.indentNext&&G[0]!=="#"||J===0&&(G.startsWith("---")||G.startsWith("..."))&&lU(G[3])){if(!(J===this.indentNext-1&&this.flowLevel===1&&(G[0]==="]"||G[0]==="}")))return this.flowLevel=0,yield $Q.FLOW_END,yield*this.parseLineStart()}let q=0;while(G[q]===",")q+=yield*this.pushCount(1),q+=yield*this.pushSpaces(!0),this.flowKey=!1;switch(q+=yield*this.pushIndicators(),G[q]){case void 0:return"flow";case"#":return yield*this.pushCount(G.length-q),"flow";case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel+=1,"flow";case"}":case"]":return yield*this.pushCount(1),this.flowKey=!0,this.flowLevel-=1,this.flowLevel?"flow":"doc";case"*":return yield*this.pushUntil(KH),"flow";case'"':case"'":return this.flowKey=!0,yield*this.parseQuotedScalar();case":":{let I=this.charAt(1);if(this.flowKey||lU(I)||I===",")return this.flowKey=!1,yield*this.pushCount(1),yield*this.pushSpaces(!0),"flow"}default:return this.flowKey=!1,yield*this.parsePlainScalar()}}*parseQuotedScalar(){let $=this.charAt(0),U=this.buffer.indexOf($,this.pos+1);if($==="'")while(U!==-1&&this.buffer[U+1]==="'")U=this.buffer.indexOf("'",U+2);else while(U!==-1){let q=0;while(this.buffer[U-1-q]==="\\")q+=1;if(q%2===0)break;U=this.buffer.indexOf('"',U+1)}let J=this.buffer.substring(0,U),G=J.indexOf(`
|
|
283
|
+
`,this.pos);if(G!==-1){while(G!==-1){let q=this.continueScalar(G+1);if(q===-1)break;G=J.indexOf(`
|
|
284
|
+
`,q)}if(G!==-1)U=G-(J[G-1]==="\r"?2:1)}if(U===-1){if(!this.atEnd)return this.setNext("quoted-scalar");U=this.buffer.length}return yield*this.pushToIndex(U+1,!1),this.flowLevel?"flow":"doc"}*parseBlockScalarHeader(){this.blockScalarIndent=-1,this.blockScalarKeep=!1;let $=this.pos;while(!0){let U=this.buffer[++$];if(U==="+")this.blockScalarKeep=!0;else if(U>"0"&&U<="9")this.blockScalarIndent=Number(U)-1;else if(U!=="-")break}return yield*this.pushUntil((U)=>lU(U)||U==="#")}*parseBlockScalar(){let $=this.pos-1,U=0,J;$:for(let q=this.pos;J=this.buffer[q];++q)switch(J){case" ":U+=1;break;case`
|
|
285
|
+
`:$=q,U=0;break;case"\r":{let I=this.buffer[q+1];if(!I&&!this.atEnd)return this.setNext("block-scalar");if(I===`
|
|
286
|
+
`)break}default:break $}if(!J&&!this.atEnd)return this.setNext("block-scalar");if(U>=this.indentNext){if(this.blockScalarIndent===-1)this.indentNext=U;else this.indentNext=this.blockScalarIndent+(this.indentNext===0?1:this.indentNext);do{let q=this.continueScalar($+1);if(q===-1)break;$=this.buffer.indexOf(`
|
|
287
|
+
`,q)}while($!==-1);if($===-1){if(!this.atEnd)return this.setNext("block-scalar");$=this.buffer.length}}let G=$+1;J=this.buffer[G];while(J===" ")J=this.buffer[++G];if(J==="\t"){while(J==="\t"||J===" "||J==="\r"||J===`
|
|
288
|
+
`)J=this.buffer[++G];$=G-1}else if(!this.blockScalarKeep)do{let q=$-1,I=this.buffer[q];if(I==="\r")I=this.buffer[--q];let Q=q;while(I===" ")I=this.buffer[--q];if(I===`
|
|
289
|
+
`&&q>=this.pos&&q+1+U>Q)$=q;else break}while(!0);return yield $Q.SCALAR,yield*this.pushToIndex($+1,!0),yield*this.parseLineStart()}*parsePlainScalar(){let $=this.flowLevel>0,U=this.pos-1,J=this.pos-1,G;while(G=this.buffer[++J])if(G===":"){let q=this.buffer[J+1];if(lU(q)||$&&bY.has(q))break;U=J}else if(lU(G)){let q=this.buffer[J+1];if(G==="\r")if(q===`
|
|
290
|
+
`)J+=1,G=`
|
|
291
|
+
`,q=this.buffer[J+1];else U=J;if(q==="#"||$&&bY.has(q))break;if(G===`
|
|
292
|
+
`){let I=this.continueScalar(J+1);if(I===-1)break;J=Math.max(J,I-2)}}else{if($&&bY.has(G))break;U=J}if(!G&&!this.atEnd)return this.setNext("plain-scalar");return yield $Q.SCALAR,yield*this.pushToIndex(U+1,!0),$?"flow":"doc"}*pushCount($){if($>0)return yield this.buffer.substr(this.pos,$),this.pos+=$,$;return 0}*pushToIndex($,U){let J=this.buffer.slice(this.pos,$);if(J)return yield J,this.pos+=J.length,J.length;else if(U)yield"";return 0}*pushIndicators(){let $=0;$:while(!0){switch(this.charAt(0)){case"!":$+=yield*this.pushTag(),$+=yield*this.pushSpaces(!0);continue $;case"&":$+=yield*this.pushUntil(KH),$+=yield*this.pushSpaces(!0);continue $;case"-":case"?":case":":{let U=this.flowLevel>0,J=this.charAt(1);if(lU(J)||U&&bY.has(J)){if(!U)this.indentNext=this.indentValue+1;else if(this.flowKey)this.flowKey=!1;$+=yield*this.pushCount(1),$+=yield*this.pushSpaces(!0);continue $}}}break $}return $}*pushTag(){if(this.charAt(1)==="<"){let $=this.pos+2,U=this.buffer[$];while(!lU(U)&&U!==">")U=this.buffer[++$];return yield*this.pushToIndex(U===">"?$+1:$,!1)}else{let $=this.pos+1,U=this.buffer[$];while(U)if(oJ$.has(U))U=this.buffer[++$];else if(U==="%"&&p3.has(this.buffer[$+1])&&p3.has(this.buffer[$+2]))U=this.buffer[$+=3];else break;return yield*this.pushToIndex($,!1)}}*pushNewline(){let $=this.buffer[this.pos];if($===`
|
|
293
|
+
`)return yield*this.pushCount(1);else if($==="\r"&&this.charAt(1)===`
|
|
294
|
+
`)return yield*this.pushCount(2);else return 0}*pushSpaces($){let U=this.pos-1,J;do J=this.buffer[++U];while(J===" "||$&&J==="\t");let G=U-this.pos;if(G>0)yield this.buffer.substr(this.pos,G),this.pos=U;return G}*pushUntil($){let U=this.pos,J=this.buffer[U];while(!$(J))J=this.buffer[++U];return yield*this.pushToIndex(U,!1)}}sJ$.Lexer=d3});var jH=J$((eJ$)=>{class n3{constructor(){this.lineStarts=[],this.addNewLine=($)=>this.lineStarts.push($),this.linePos=($)=>{let U=0,J=this.lineStarts.length;while(U<J){let q=U+J>>1;if(this.lineStarts[q]<$)U=q+1;else J=q}if(this.lineStarts[U]===$)return{line:U+1,col:1};if(U===0)return{line:0,col:$};let G=this.lineStarts[U-1];return{line:U,col:$-G+1}}}}eJ$.LineCounter=n3});var PH=J$((qq$)=>{var Uq$=WU("process"),c3=FY(),Jq$=gH();function Eq($,U){for(let J=0;J<$.length;++J)if($[J].type===U)return!0;return!1}function o3($){for(let U=0;U<$.length;++U)switch($[U].type){case"space":case"comment":case"newline":break;default:return U}return-1}function s3($){switch($?.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"flow-collection":return!0;default:return!1}}function uY($){switch($.type){case"document":return $.start;case"block-map":{let U=$.items[$.items.length-1];return U.sep??U.start}case"block-seq":return $.items[$.items.length-1].start;default:return[]}}function L6($){if($.length===0)return[];let U=$.length;$:while(--U>=0)switch($[U].type){case"doc-start":case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":case"newline":break $}while($[++U]?.type==="space");return $.splice(U,$.length)}function kY($,U){if(U.length<1e5)Array.prototype.push.apply($,U);else for(let J=0;J<U.length;++J)$.push(U[J])}function a3($){if($.start.type==="flow-seq-start"){for(let U of $.items)if(U.sep&&!U.value&&!Eq(U.start,"explicit-key-ind")&&!Eq(U.sep,"map-value-ind")){if(U.key)U.value=U.key;if(delete U.key,s3(U.value))if(U.value.end)kY(U.value.end,U.sep);else U.value.end=U.sep;else kY(U.start,U.sep);delete U.sep}}}class t3{constructor($){this.atNewLine=!0,this.atScalar=!1,this.indent=0,this.offset=0,this.onKeyLine=!1,this.stack=[],this.source="",this.type="",this.lexer=new Jq$.Lexer,this.onNewLine=$}*parse($,U=!1){if(this.onNewLine&&this.offset===0)this.onNewLine(0);for(let J of this.lexer.lex($,U))yield*this.next(J);if(!U)yield*this.end()}*next($){if(this.source=$,Uq$.env.LOG_TOKENS)console.log("|",c3.prettyToken($));if(this.atScalar){this.atScalar=!1,yield*this.step(),this.offset+=$.length;return}let U=c3.tokenType($);if(!U){let J=`Not a YAML token: ${$}`;yield*this.pop({type:"error",offset:this.offset,message:J,source:$}),this.offset+=$.length}else if(U==="scalar")this.atNewLine=!1,this.atScalar=!0,this.type="scalar";else{switch(this.type=U,yield*this.step(),U){case"newline":if(this.atNewLine=!0,this.indent=0,this.onNewLine)this.onNewLine(this.offset+$.length);break;case"space":if(this.atNewLine&&$[0]===" ")this.indent+=$.length;break;case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":if(this.atNewLine)this.indent+=$.length;break;case"doc-mode":case"flow-error-end":return;default:this.atNewLine=!1}this.offset+=$.length}}*end(){while(this.stack.length>0)yield*this.pop()}get sourceToken(){return{type:this.type,offset:this.offset,indent:this.indent,source:this.source}}*step(){let $=this.peek(1);if(this.type==="doc-end"&&$?.type!=="doc-end"){while(this.stack.length>0)yield*this.pop();this.stack.push({type:"doc-end",offset:this.offset,source:this.source});return}if(!$)return yield*this.stream();switch($.type){case"document":return yield*this.document($);case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return yield*this.scalar($);case"block-scalar":return yield*this.blockScalar($);case"block-map":return yield*this.blockMap($);case"block-seq":return yield*this.blockSequence($);case"flow-collection":return yield*this.flowCollection($);case"doc-end":return yield*this.documentEnd($)}yield*this.pop()}peek($){return this.stack[this.stack.length-$]}*pop($){let U=$??this.stack.pop();if(!U)yield{type:"error",offset:this.offset,source:"",message:"Tried to pop an empty stack"};else if(this.stack.length===0)yield U;else{let J=this.peek(1);if(U.type==="block-scalar")U.indent="indent"in J?J.indent:0;else if(U.type==="flow-collection"&&J.type==="document")U.indent=0;if(U.type==="flow-collection")a3(U);switch(J.type){case"document":J.value=U;break;case"block-scalar":J.props.push(U);break;case"block-map":{let G=J.items[J.items.length-1];if(G.value){J.items.push({start:[],key:U,sep:[]}),this.onKeyLine=!0;return}else if(G.sep)G.value=U;else{Object.assign(G,{key:U,sep:[]}),this.onKeyLine=!G.explicitKey;return}break}case"block-seq":{let G=J.items[J.items.length-1];if(G.value)J.items.push({start:[],value:U});else G.value=U;break}case"flow-collection":{let G=J.items[J.items.length-1];if(!G||G.value)J.items.push({start:[],key:U,sep:[]});else if(G.sep)G.value=U;else Object.assign(G,{key:U,sep:[]});return}default:yield*this.pop(),yield*this.pop(U)}if((J.type==="document"||J.type==="block-map"||J.type==="block-seq")&&(U.type==="block-map"||U.type==="block-seq")){let G=U.items[U.items.length-1];if(G&&!G.sep&&!G.value&&G.start.length>0&&o3(G.start)===-1&&(U.indent===0||G.start.every((q)=>q.type!=="comment"||q.indent<U.indent))){if(J.type==="document")J.end=G.start;else J.items.push({start:G.start});U.items.splice(-1,1)}}}}*stream(){switch(this.type){case"directive-line":yield{type:"directive",offset:this.offset,source:this.source};return;case"byte-order-mark":case"space":case"comment":case"newline":yield this.sourceToken;return;case"doc-mode":case"doc-start":{let $={type:"document",offset:this.offset,start:[]};if(this.type==="doc-start")$.start.push(this.sourceToken);this.stack.push($);return}}yield{type:"error",offset:this.offset,message:`Unexpected ${this.type} token in YAML stream`,source:this.source}}*document($){if($.value)return yield*this.lineEnd($);switch(this.type){case"doc-start":{if(o3($.start)!==-1)yield*this.pop(),yield*this.step();else $.start.push(this.sourceToken);return}case"anchor":case"tag":case"space":case"comment":case"newline":$.start.push(this.sourceToken);return}let U=this.startBlockValue($);if(U)this.stack.push(U);else yield{type:"error",offset:this.offset,message:`Unexpected ${this.type} token in YAML document`,source:this.source}}*scalar($){if(this.type==="map-value-ind"){let U=uY(this.peek(2)),J=L6(U),G;if($.end)G=$.end,G.push(this.sourceToken),delete $.end;else G=[this.sourceToken];let q={type:"block-map",offset:$.offset,indent:$.indent,items:[{start:J,key:$,sep:G}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=q}else yield*this.lineEnd($)}*blockScalar($){switch(this.type){case"space":case"comment":case"newline":$.props.push(this.sourceToken);return;case"scalar":if($.source=this.source,this.atNewLine=!0,this.indent=0,this.onNewLine){let U=this.source.indexOf(`
|
|
295
|
+
`)+1;while(U!==0)this.onNewLine(this.offset+U),U=this.source.indexOf(`
|
|
296
|
+
`,U)+1}yield*this.pop();break;default:yield*this.pop(),yield*this.step()}}*blockMap($){let U=$.items[$.items.length-1];switch(this.type){case"newline":if(this.onKeyLine=!1,U.value){let J="end"in U.value?U.value.end:void 0;if((Array.isArray(J)?J[J.length-1]:void 0)?.type==="comment")J?.push(this.sourceToken);else $.items.push({start:[this.sourceToken]})}else if(U.sep)U.sep.push(this.sourceToken);else U.start.push(this.sourceToken);return;case"space":case"comment":if(U.value)$.items.push({start:[this.sourceToken]});else if(U.sep)U.sep.push(this.sourceToken);else{if(this.atIndentedComment(U.start,$.indent)){let G=$.items[$.items.length-2]?.value?.end;if(Array.isArray(G)){kY(G,U.start),G.push(this.sourceToken),$.items.pop();return}}U.start.push(this.sourceToken)}return}if(this.indent>=$.indent){let J=!this.onKeyLine&&this.indent===$.indent,G=J&&(U.sep||U.explicitKey)&&this.type!=="seq-item-ind",q=[];if(G&&U.sep&&!U.value){let I=[];for(let Q=0;Q<U.sep.length;++Q){let D=U.sep[Q];switch(D.type){case"newline":I.push(Q);break;case"space":break;case"comment":if(D.indent>$.indent)I.length=0;break;default:I.length=0}}if(I.length>=2)q=U.sep.splice(I[1])}switch(this.type){case"anchor":case"tag":if(G||U.value)q.push(this.sourceToken),$.items.push({start:q}),this.onKeyLine=!0;else if(U.sep)U.sep.push(this.sourceToken);else U.start.push(this.sourceToken);return;case"explicit-key-ind":if(!U.sep&&!U.explicitKey)U.start.push(this.sourceToken),U.explicitKey=!0;else if(G||U.value)q.push(this.sourceToken),$.items.push({start:q,explicitKey:!0});else this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken],explicitKey:!0}]});this.onKeyLine=!0;return;case"map-value-ind":if(U.explicitKey)if(!U.sep)if(Eq(U.start,"newline"))Object.assign(U,{key:null,sep:[this.sourceToken]});else{let I=L6(U.start);this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:I,key:null,sep:[this.sourceToken]}]})}else if(U.value)$.items.push({start:[],key:null,sep:[this.sourceToken]});else if(Eq(U.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:q,key:null,sep:[this.sourceToken]}]});else if(s3(U.key)&&!Eq(U.sep,"newline")){let I=L6(U.start),Q=U.key,D=U.sep;D.push(this.sourceToken),delete U.key,delete U.sep,this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:I,key:Q,sep:D}]})}else if(q.length>0)U.sep=U.sep.concat(q,this.sourceToken);else U.sep.push(this.sourceToken);else if(!U.sep)Object.assign(U,{key:null,sep:[this.sourceToken]});else if(U.value||G)$.items.push({start:q,key:null,sep:[this.sourceToken]});else if(Eq(U.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[],key:null,sep:[this.sourceToken]}]});else U.sep.push(this.sourceToken);this.onKeyLine=!0;return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{let I=this.flowScalar(this.type);if(G||U.value)$.items.push({start:q,key:I,sep:[]}),this.onKeyLine=!0;else if(U.sep)this.stack.push(I);else Object.assign(U,{key:I,sep:[]}),this.onKeyLine=!0;return}default:{let I=this.startBlockValue($);if(I){if(I.type==="block-seq"){if(!U.explicitKey&&U.sep&&!Eq(U.sep,"newline")){yield*this.pop({type:"error",offset:this.offset,message:"Unexpected block-seq-ind on same line with key",source:this.source});return}}else if(J)$.items.push({start:q});this.stack.push(I);return}}}}yield*this.pop(),yield*this.step()}*blockSequence($){let U=$.items[$.items.length-1];switch(this.type){case"newline":if(U.value){let J="end"in U.value?U.value.end:void 0;if((Array.isArray(J)?J[J.length-1]:void 0)?.type==="comment")J?.push(this.sourceToken);else $.items.push({start:[this.sourceToken]})}else U.start.push(this.sourceToken);return;case"space":case"comment":if(U.value)$.items.push({start:[this.sourceToken]});else{if(this.atIndentedComment(U.start,$.indent)){let G=$.items[$.items.length-2]?.value?.end;if(Array.isArray(G)){kY(G,U.start),G.push(this.sourceToken),$.items.pop();return}}U.start.push(this.sourceToken)}return;case"anchor":case"tag":if(U.value||this.indent<=$.indent)break;U.start.push(this.sourceToken);return;case"seq-item-ind":if(this.indent!==$.indent)break;if(U.value||Eq(U.start,"seq-item-ind"))$.items.push({start:[this.sourceToken]});else U.start.push(this.sourceToken);return}if(this.indent>$.indent){let J=this.startBlockValue($);if(J){this.stack.push(J);return}}yield*this.pop(),yield*this.step()}*flowCollection($){let U=$.items[$.items.length-1];if(this.type==="flow-error-end"){let J;do yield*this.pop(),J=this.peek(1);while(J?.type==="flow-collection")}else if($.end.length===0){switch(this.type){case"comma":case"explicit-key-ind":if(!U||U.sep)$.items.push({start:[this.sourceToken]});else U.start.push(this.sourceToken);return;case"map-value-ind":if(!U||U.value)$.items.push({start:[],key:null,sep:[this.sourceToken]});else if(U.sep)U.sep.push(this.sourceToken);else Object.assign(U,{key:null,sep:[this.sourceToken]});return;case"space":case"comment":case"newline":case"anchor":case"tag":if(!U||U.value)$.items.push({start:[this.sourceToken]});else if(U.sep)U.sep.push(this.sourceToken);else U.start.push(this.sourceToken);return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{let G=this.flowScalar(this.type);if(!U||U.value)$.items.push({start:[],key:G,sep:[]});else if(U.sep)this.stack.push(G);else Object.assign(U,{key:G,sep:[]});return}case"flow-map-end":case"flow-seq-end":$.end.push(this.sourceToken);return}let J=this.startBlockValue($);if(J)this.stack.push(J);else yield*this.pop(),yield*this.step()}else{let J=this.peek(2);if(J.type==="block-map"&&(this.type==="map-value-ind"&&J.indent===$.indent||this.type==="newline"&&!J.items[J.items.length-1].sep))yield*this.pop(),yield*this.step();else if(this.type==="map-value-ind"&&J.type!=="flow-collection"){let G=uY(J),q=L6(G);a3($);let I=$.end.splice(1,$.end.length);I.push(this.sourceToken);let Q={type:"block-map",offset:$.offset,indent:$.indent,items:[{start:q,key:$,sep:I}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=Q}else yield*this.lineEnd($)}}flowScalar($){if(this.onNewLine){let U=this.source.indexOf(`
|
|
297
|
+
`)+1;while(U!==0)this.onNewLine(this.offset+U),U=this.source.indexOf(`
|
|
298
|
+
`,U)+1}return{type:$,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue($){switch(this.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return this.flowScalar(this.type);case"block-scalar-header":return{type:"block-scalar",offset:this.offset,indent:this.indent,props:[this.sourceToken],source:""};case"flow-map-start":case"flow-seq-start":return{type:"flow-collection",offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case"seq-item-ind":return{type:"block-seq",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case"explicit-key-ind":{this.onKeyLine=!0;let U=uY($),J=L6(U);return J.push(this.sourceToken),{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:J,explicitKey:!0}]}}case"map-value-ind":{this.onKeyLine=!0;let U=uY($),J=L6(U);return{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:J,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment($,U){if(this.type!=="comment")return!1;if(this.indent<=U)return!1;return $.every((J)=>J.type==="newline"||J.type==="space")}*documentEnd($){if(this.type!=="doc-mode"){if($.end)$.end.push(this.sourceToken);else $.end=[this.sourceToken];if(this.type==="newline")yield*this.pop()}}*lineEnd($){switch(this.type){case"comma":case"doc-start":case"doc-end":case"flow-seq-end":case"flow-map-end":case"map-value-ind":yield*this.pop(),yield*this.step();break;case"newline":this.onKeyLine=!1;case"space":case"comment":default:if($.end)$.end.push(this.sourceToken);else $.end=[this.sourceToken];if(this.type==="newline")yield*this.pop()}}}qq$.Parser=t3});var qv=J$((Oq$)=>{var e3=RH(),Iq$=oI(),UQ=aI(),Qq$=jM(),Dq$=x$(),Xq$=jH(),$v=PH();function Uv($){let U=$.prettyErrors!==!1;return{lineCounter:$.lineCounter||U&&new Xq$.LineCounter||null,prettyErrors:U}}function Yq$($,U={}){let{lineCounter:J,prettyErrors:G}=Uv(U),q=new $v.Parser(J?.addNewLine),I=new e3.Composer(U),Q=Array.from(I.compose(q.parse($)));if(G&&J)for(let D of Q)D.errors.forEach(UQ.prettifyError($,J)),D.warnings.forEach(UQ.prettifyError($,J));if(Q.length>0)return Q;return Object.assign([],{empty:!0},I.streamInfo())}function Jv($,U={}){let{lineCounter:J,prettyErrors:G}=Uv(U),q=new $v.Parser(J?.addNewLine),I=new e3.Composer(U),Q=null;for(let D of I.compose(q.parse($),!0,$.length))if(!Q)Q=D;else if(Q.options.logLevel!=="silent"){Q.errors.push(new UQ.YAMLParseError(D.range.slice(0,2),"MULTIPLE_DOCS","Source contains multiple documents; please use YAML.parseAllDocuments()"));break}if(G&&J)Q.errors.forEach(UQ.prettifyError($,J)),Q.warnings.forEach(UQ.prettifyError($,J));return Q}function Vq$($,U,J){let G=void 0;if(typeof U==="function")G=U;else if(J===void 0&&U&&typeof U==="object")J=U;let q=Jv($,J);if(!q)return null;if(q.warnings.forEach((I)=>Qq$.warn(q.options.logLevel,I)),q.errors.length>0)if(q.options.logLevel!=="silent")throw q.errors[0];else q.errors=[];return q.toJS(Object.assign({reviver:G},J))}function Wq$($,U,J){let G=null;if(typeof U==="function"||Array.isArray(U))G=U;else if(J===void 0&&U)J=U;if(typeof J==="string")J=J.length;if(typeof J==="number"){let q=Math.round(J);J=q<1?void 0:q>8?{indent:8}:{indent:q}}if($===void 0){let{keepUndefined:q}=J??U??{};if(!q)return}if(Dq$.isDocument($)&&!G)return $.toString(J);return new Iq$.Document($,G,J).toString(J)}Oq$.parse=Vq$;Oq$.parseAllDocuments=Yq$;Oq$.parseDocument=Jv;Oq$.stringify=Wq$});var Mq$,Hq$,Tq$,BH,zq$,Cq,Aq$,Kq$,gq$,jq$,GK$,Pq$,Bq$,Sq$,xY,Gv,Lq$,Eq$,Cq$,_q$,vq$,Fq$,bq$,uq$,kq$,xq$,fG,kJ,fq$,fY,yq$,mq$,hq$,rq$,lq$,iq$,pq$,dq$,nq$,cq$,JQ,oq$,aq$,sq$;var SH=O$(()=>{Mq$=RH(),Hq$=oI(),Tq$=tM(),BH=aI(),zq$=uI(),Cq=x$(),Aq$=Pq(),Kq$=D0(),gq$=Sq(),jq$=Lq(),GK$=FY(),Pq$=gH(),Bq$=jH(),Sq$=PH(),xY=qv(),Gv=FI();Lq$=Mq$.Composer,Eq$=Hq$.Document,Cq$=Tq$.Schema,_q$=BH.YAMLError,vq$=BH.YAMLParseError,Fq$=BH.YAMLWarning,bq$=zq$.Alias,uq$=Cq.isAlias,kq$=Cq.isCollection,xq$=Cq.isDocument,fG=Cq.isMap,kJ=Cq.isNode,fq$=Cq.isPair,fY=Cq.isScalar,yq$=Cq.isSeq,mq$=Aq$.Pair,hq$=Kq$.Scalar,rq$=gq$.YAMLMap,lq$=jq$.YAMLSeq,iq$=Pq$.Lexer,pq$=Bq$.LineCounter,dq$=Sq$.Parser,nq$=xY.parse,cq$=xY.parseAllDocuments,JQ=xY.parseDocument,oq$=xY.stringify,aq$=Gv.visit,sq$=Gv.visitAsync});function Xv($){if($==="core")return{bundles:["core"]};if($==="default")return{bundles:["core","site","publishing"],add:["obsidian-vault"],remove:[...$G$]};return{bundles:["core","site","publishing"],add:["obsidian-vault"]}}function UG$($){let U=tq$.parse($);return j8.parse({brainVersion:U.brainVersion,...Xv(U.preset),githubOrg:U.githubOrg,contentRepoPrefix:U.contentRepoPrefix,domainSuffix:U.domainSuffix,aiApiKey:U.aiApiKey,gitSyncToken:U.gitSyncToken,contentRepoAdminToken:U.contentRepoAdminToken,agePublicKey:U.agePublicKey})}function JG$($){let U=eq$.parse($),J=U.presetOverride?Xv(U.presetOverride):void 0;return cJ.parse({members:[...U.members],...U.brainVersionOverride?{brainVersionOverride:U.brainVersionOverride}:{},...J?{bundlesOverride:J.bundles,...J.add?{addOverride:J.add}:{},...J.remove?{removeOverride:J.remove}:{}}:{},...U.aiApiKeyOverride?{aiApiKeyOverride:U.aiApiKeyOverride}:{},...U.gitSyncTokenOverride?{gitSyncTokenOverride:U.gitSyncTokenOverride}:{}})}function Yv($){let U=JQ($,{keepSourceTokens:!0});if(U.errors.length>0)throw Error(`Invalid desired-state YAML: ${U.errors[0]?.message}`);if(!fG(U.contents))throw Error("Desired-state YAML must contain a mapping");return U}function LH($,U){if(!fG($.contents))return;return $.contents.items.find((J)=>fY(J.key)&&J.key.value===U)}function Iv($,U){if(!kJ($)||!kJ(U))return;if($.commentBefore!==void 0)U.commentBefore=$.commentBefore;if($.comment!==void 0)U.comment=$.comment;if($.spaceBefore!==void 0)U.spaceBefore=$.spaceBefore}function Qv($,U){if(!$||!kJ(U))return;let J=[kJ($.key)?$.key.commentBefore:void 0,kJ($.key)?$.key.comment:void 0,kJ($.value)?$.value.commentBefore:void 0,kJ($.value)?$.value.comment:void 0].filter((G)=>G!==void 0);if(J.length===0)return;U.commentBefore=[U.commentBefore,...J].filter((G)=>G!==void 0).join(`
|
|
299
|
+
`)}function Vv($,U,J,G){if(!fG($.contents))throw Error("Desired-state YAML must contain a mapping");let q=$.contents.items.findIndex((Q)=>fY(Q.key)&&Q.key.value===U),I=$.createPair(J,[...G]);if(q>=0){let Q=$.contents.items[q];Iv(Q?.key,I.key),Iv(Q?.value,I.value),$.contents.items.splice(q,1,I)}else $.contents.add(I);return I}function Wv($){let U=Yv($),J=UG$(U.toJS()),G=LH(U,"schemaVersion"),q=LH(U,"model");Qv(G,LH(U,"brainVersion")?.key),U.delete("schemaVersion");let I=Vv(U,"preset","bundles",J.bundles);if(Qv(q,I.key),U.delete("model"),J.add)U.set("add",J.add);else U.delete("add");if(J.remove)U.set("remove",J.remove);else U.delete("remove");return j8.parse(U.toJS()),U.toString({lineWidth:0})}function Ov($){let U=Yv($),J=JG$(U.toJS());if(J.bundlesOverride)Vv(U,"presetOverride","bundlesOverride",J.bundlesOverride);else U.delete("presetOverride"),U.delete("bundlesOverride");if(J.addOverride)U.set("addOverride",J.addOverride);else U.delete("addOverride");if(J.removeOverride)U.set("removeOverride",J.removeOverride);else U.delete("removeOverride");return cJ.parse(U.toJS()),U.toString({lineWidth:0})}var Dv,qQ,tq$,eq$,$G$;var Zv=O$(()=>{vq();b$();SH();P8();Dv=N.enum(["core","default","pro"]),qQ=N.string().min(1),tq$=N.strictObject({schemaVersion:N.literal(1),brainVersion:aU,model:N.literal("rover"),githubOrg:N.string().min(1),contentRepoPrefix:N.string().min(1),domainSuffix:N.string().min(1),preset:Dv,aiApiKey:qQ,gitSyncToken:qQ,contentRepoAdminToken:qQ,agePublicKey:N.string().startsWith("age1").min(1)}),eq$=N.strictObject({members:N.array(sU).min(1),brainVersionOverride:aU.optional(),presetOverride:Dv.optional(),aiApiKeyOverride:qQ.optional(),gitSyncTokenOverride:qQ.optional()}).superRefine(($,U)=>{if(new Set($.members).size!==$.members.length)U.addIssue({code:N.ZodIssueCode.custom,path:["members"],message:"cohort members must be unique"})}),$G$=["series","portfolio","content-pipeline","social-media","newsletter","stock-photo"]});var Hv={};UU(Hv,{stageLegacyCrossover:()=>OG$,parseReviewedSitePins:()=>Mv,loadReviewedSitePins:()=>VG$});import{access as qG$,cp as GG$,mkdir as Rv,readFile as GQ,readdir as wv,writeFile as E6}from"fs/promises";import{basename as IG$,join as VJ,relative as yY,resolve as Nv}from"path";import{fileURLToPath as QG$}from"url";function Mv($){let U=dG($,DG$);if(!U.ok)throw Error(`Invalid reviewed site pins: ${U.error}`);return U.data.sites}async function VG$($){return Mv(await GQ($,"utf8"))}async function WG$($,U){let J=VJ($,"users"),G=(await wv(J,{withFileTypes:!0})).filter((Q)=>Q.isFile()&&/\.ya?ml$/.test(Q.name)).map((Q)=>Q.name).sort(),q=new Set(Object.keys(U??{})),I=[];for(let Q of G){let D=VJ(J,Q),X=await GQ(D,"utf8"),Y=JQ(X,{keepSourceTokens:!0});if(Y.errors.length>0||!fG(Y.contents))throw Error(`Invalid user desired-state YAML: ${Q}`);let V=XG$.parse(Y.toJS());if(!V.siteOverride)continue;let W=U?.[V.handle];if(!W)throw Error(`User ${V.handle} has a siteOverride but no reviewed site pin`);if(q.delete(V.handle),W.package!==V.siteOverride.package||W.theme!==V.siteOverride.theme)throw Error(`Reviewed site pin identity does not match user ${V.handle}`);if(V.siteOverride.version!==void 0&&V.siteOverride.version!==W.version)throw Error(`Reviewed site version does not match the existing pin for user ${V.handle}`);if(V.siteOverride.themeVersion!==void 0&&V.siteOverride.themeVersion!==W.themeVersion)throw Error(`Reviewed theme version does not match the existing pin for user ${V.handle}`);if(Y.setIn(["siteOverride","version"],W.version),W.themeVersion!==void 0)Y.setIn(["siteOverride","themeVersion"],W.themeVersion);else Y.deleteIn(["siteOverride","themeVersion"]);$X.parse(Y.toJS());let O=Y.toString({lineWidth:0});if(O!==X)await E6(D,O),I.push(yY($,D))}if(q.size>0)throw Error(`Reviewed site pins do not match site users: ${[...q].sort().join(", ")}`);return I}async function OG$($,U,J={}){let G=Nv($),q=Nv(U);if(G===q||q.startsWith(`${G}/`))throw Error("Crossover output must be outside the source repository");await GG$(G,q,{recursive:!0,errorOnExist:!0,force:!1,filter:(Z)=>{let M=IG$(Z);return M!==".git"&&M!==".operator"&&M!==".brains-ops"&&M!==".turbo"&&M!=="dist"&&M!=="node_modules"&&M!==".env"&&M!==".env.local"&&!M.endsWith(".secrets.yaml")}});let I=[],Q=VJ(q,"docs","canonical-crossover-record.md");try{await qG$(Q)}catch{await Rv(VJ(q,"docs"),{recursive:!0}),await E6(Q,await GQ(YG$,"utf8")),I.push("docs/canonical-crossover-record.md")}let D=VJ(q,"pilot.yaml"),X=await GQ(D,"utf8");await E6(D,Wv(X)),I.push("pilot.yaml");let Y=VJ(q,"cohorts"),V=(await wv(Y,{withFileTypes:!0})).filter((Z)=>Z.isFile()&&/\.ya?ml$/.test(Z.name)).map((Z)=>Z.name).sort();for(let Z of V){let M=VJ(Y,Z),w=await GQ(M,"utf8");await E6(M,Ov(w)),I.push(yY(q,M))}I.push(...await WG$(q,J.sitePins));let W=await M0(q),O=dX(W.pilot.githubOrg);for(let Z of W.users){let M=await O(Z),w=VJ(q,"users",Z.handle);if(await Rv(w,{recursive:!0}),M.brainYaml){let H=VJ(w,"brain.yaml");await E6(H,M.brainYaml),I.push(yY(q,H))}if(M.envFile){let H=VJ(w,".env");await E6(H,M.envFile),I.push(yY(q,H))}}return await dq(q,{registry:W}),I.push("views/users.md"),{outputDir:q,changedFiles:[...new Set(I)].sort()}}var DG$,XG$,YG$;var Tv=O$(()=>{vq();b$();SH();Y5();Zv();RJ();L4();P8();DG$=N.strictObject({sites:N.record(sU,v7)}),XG$=N.object({handle:sU,siteOverride:N.object({package:N.string().min(1),version:aU.optional(),theme:N.string().min(1).optional(),themeVersion:aU.optional()}).optional()}).passthrough(),YG$=QG$(new URL("../templates/rover-pilot/docs/canonical-crossover-record.md",import.meta.url))});function N0($,U,J,G,q){return Av.parse({id:$,operation:U,count:J,targetProbeCount:G,settleMs:q})}function CH($){return QQ.parse(structuredClone(NG$[$]))}function DQ($){let U=`stress:${$.handle}`;if($.confirmation!==U)throw Error(`Directory-sync stress requires --confirm ${U}`);let J=/(^|[-_.])smoke($|[-_.])/i;if(!J.test($.handle)||!J.test($.domain)||!J.test($.contentRepo))throw Error("Directory-sync stress is smoke-only; handle, domain, and content repository must all identify smoke")}async function hY($,U={}){let J=U.fetchImpl??fetch,G=U.now??(()=>new Date),q=U.timeoutMs??20000,I=G(),Q=new AbortController,D=setTimeout(()=>Q.abort(),q);try{let X=await J($,{method:"GET",signal:Q.signal});return await X.arrayBuffer(),EH.parse({timestamp:I.toISOString(),endpoint:new URL($).pathname,status:X.status,durationMs:Math.max(0,G().getTime()-I.getTime()),ok:X.ok})}catch(X){return EH.parse({timestamp:I.toISOString(),endpoint:new URL($).pathname,status:0,durationMs:Math.max(0,G().getTime()-I.getTime()),ok:!1,error:wG$(X)})}finally{clearTimeout(D)}}async function _H($,U){let J=QQ.parse($),G=[],q,I=await U.prepare(J),Q,D;try{try{await U.startMonitoring()}catch(X){q=`monitor: ${mY(X)}`}if(!q)for(let X of J.phases)try{let Y=Kv.parse(await U.executePhase(X,I));if(G.push(Y),!Y.success){q=`${X.id}: ${Y.error??"phase failed"}`;break}}catch(Y){let V=mY(Y);G.push({id:X.id,operation:X.operation,count:X.count,success:!1,error:V}),q=`${X.id}: ${V}`;break}}finally{try{if(Q=gv.parse(await U.cleanup(I)),!Q.success&&!q)q=Q.error??"cleanup failed"}catch(X){let Y=mY(X);Q={success:!1,probesRemaining:0,error:Y},q??=`cleanup: ${Y}`}try{D=jv.parse(await U.stopMonitoring())}catch(X){let Y=mY(X);D={health:[],runtime:[]},q??=`monitor: ${Y}`}}return q??=Bv(D,J.maximumExternalAiCalls??0),Pv.parse({profile:J.profile,success:q===void 0&&G.length===J.phases.length&&Q.success,baseline:I,phases:G,cleanup:Q,metrics:D,...q?{failure:q}:{}})}function Bv($,U=0){let J=$.health.find((I)=>!I.ok);if(J)return`health: ${J.endpoint} unavailable`;let G=$.externalAiCalls??0;if(G>U)return U===0?`external AI: observed ${G} call(s)`:`external AI: observed ${G} call(s), cap ${U}`;if($.container?.oomKilled)return"container: OOM killed";let q=$.container?.restartCount??0;if(q>0)return`container: restarted ${q} time(s)`;if($.container&&$.container.status!=="running")return`container: ${$.container.status}`;return}function wG$($){if($ instanceof Error)return`${$.name}: ${$.message}`;return String($)}function mY($){return q0($)}var IQ,zv,Av,QQ,ZG$,EH,RG$,Kv,gv,jv,Pv,NG$;var rY=O$(()=>{b$();IQ=N.enum(["regression","load","stress"]),zv=N.enum(["add","update","rename","delete"]),Av=N.object({id:N.string().min(1),operation:zv,count:N.number().int().positive().max(700),targetProbeCount:N.number().int().min(0).max(700),settleMs:N.number().int().nonnegative().max(300000)}),QQ=N.object({profile:IQ,maximumProbeCount:N.number().int().positive().max(700),maximumExternalAiCalls:N.number().int().nonnegative().max(1e4).optional(),phases:N.array(Av).min(1)}),ZG$=N.object({entities:N.number().int().nonnegative(),notes:N.number().int().nonnegative(),version:N.string().min(1)}),EH=N.object({timestamp:N.iso.datetime(),endpoint:N.string().startsWith("/"),status:N.number().int().nonnegative(),durationMs:N.number().nonnegative(),ok:N.boolean(),error:N.string().optional()}),RG$=N.object({timestamp:N.iso.datetime(),cpuPercent:N.number().nonnegative(),memoryPercent:N.number().nonnegative(),pids:N.number().int().nonnegative()}),Kv=N.object({id:N.string().min(1),operation:zv,count:N.number().int().positive(),success:N.boolean(),commitLatencyMs:N.number().nonnegative().optional(),persistenceLatencyMs:N.number().nonnegative().optional(),error:N.string().optional()}),gv=N.object({success:N.boolean(),probesRemaining:N.number().int().nonnegative(),finalEntities:N.number().int().nonnegative().optional(),finalNotes:N.number().int().nonnegative().optional(),contentTreeRestored:N.boolean().optional(),error:N.string().optional()}),jv=N.object({health:N.array(EH),runtime:N.array(RG$),externalAiCalls:N.number().int().nonnegative().optional(),container:N.object({status:N.string(),restartCount:N.number().int().nonnegative(),oomKilled:N.boolean()}).optional()}),Pv=N.object({profile:IQ,success:N.boolean(),baseline:ZG$,phases:N.array(Kv),cleanup:gv,metrics:jv,failure:N.string().optional()}),NG$={regression:{profile:"regression",maximumProbeCount:20,phases:[N0("add20","add",20,20,0),N0("update20","update",20,20,30000),N0("delete20","delete",20,0,150000)]},load:{profile:"load",maximumProbeCount:350,phases:[N0("add50","add",50,50,0),N0("add150","add",100,150,0),N0("add350","add",200,350,0),N0("update350a","update",350,350,45000),N0("rename100","rename",100,350,45000),N0("update350b","update",350,350,45000),N0("delete350","delete",350,0,150000)]},stress:{profile:"stress",maximumProbeCount:700,phases:[N0("add50","add",50,50,0),N0("add150","add",100,150,0),N0("add350","add",200,350,0),N0("add700","add",350,700,0),N0("update700a","update",700,700,45000),N0("rename200","rename",200,700,45000),N0("update700b","update",700,700,45000),N0("delete700","delete",700,0,150000)]}}});import{spawn as MG$}from"child_process";async function Sv($,U,J,G){let q=await $(U,J,G);if(q.exitCode!==0)throw XQ(U,J,q);return q}function XQ($,U,J){let G=J.stderr.trim()||J.stdout.trim();return Error(`${$} ${U.join(" ")} exited with ${J.exitCode}${G?`: ${G}`:""}`)}var C6=async($,U,J={})=>new Promise((G,q)=>{let I=MG$($,[...U],{cwd:J.cwd,env:J.env?{...process.env,...J.env}:process.env,stdio:["pipe","pipe","pipe"]}),Q="",D="";I.stdout.setEncoding("utf8"),I.stderr.setEncoding("utf8"),I.stdout.on("data",(X)=>{Q+=X}),I.stderr.on("data",(X)=>{D+=X}),I.on("error",q),I.on("close",(X)=>{G({exitCode:X??1,stdout:Q,stderr:D})}),I.stdin.end(J.stdin)});var lY=()=>{};class _6{#$;#U;dir;constructor($,U,J){this.#$=$,this.dir=U,this.#U=J}static async clone($,U,J,G){let q=new _6($,J,G);return await Sv($,"git",["-c","credential.helper=","-c",`credential.helper=${Lv}`,"clone","--branch","main","--single-branch",`https://github.com/${U}.git`,J],{env:q.environment()}),await q.run(["config","--local","credential.helper",Lv]),await q.run(["reset","--hard","origin/main"]),q}async run($,U=!0){let J=await this.#$("git",$,{cwd:this.dir,env:this.environment()});if(U&&J.exitCode!==0)throw XQ("git",$,J);return J}async output($){return(await this.run($)).stdout.trim()}async sync($=!1){if(await this.run(["fetch","origin","main"]),$)await this.run(["reset","--hard","origin/main"]);else await this.run(["pull","--rebase","origin","main"])}async commitAll($){await this.run(["add","-A"]),await this.run(["-c","user.name=brains-ops","-c","user.email=ops@rizom.ai","commit","-m",$])}async pushMainWithRebase(){for(let $=1;$<=5;$+=1){if((await this.run(["push","origin","main"],!1)).exitCode===0)return;await this.run(["pull","--rebase","origin","main"])}throw Error("Unable to push content main after five rebase attempts")}async pruneStressBackupBranches(){let U=(await this.run(["ls-remote","--heads","origin","refs/heads/ops/directory-sync-stress-backup-*"])).stdout.split(/\r?\n/).map((J)=>J.match(/\trefs\/heads\/(ops\/directory-sync-stress-backup-[^\s]+)$/)?.[1]).filter((J)=>J!==void 0).sort();for(let J of U)await this.run(["push","origin","--delete",J]);return U}environment(){return{GH_TOKEN:this.#U,GITHUB_TOKEN:this.#U}}}var Lv='!f() { test "$1" = get && echo username=x-access-token && echo "password=$GH_TOKEN"; }; f';var Ev=O$(()=>{lY()});function YQ($){return $.entityCounts.find((U)=>U.entityType==="note")?.count??0}class vH{#$;#U=[];#G=[];#X=new Set(["/health/ready"]);#q=!0;#Y;#Q;#J="";#I=0;#V;constructor($){this.#$=$}get startedAt(){return this.#J}get error(){return this.#Q}get healthSamples(){return this.#U}get runtimeSamples(){return this.#G}gateHealthSamples(){return this.#U.slice(this.#I,this.#V??this.#U.length)}markGateEnd(){this.#V=this.#U.length}async discoverEndpoints(){for(let $ of["/health/live","/health/operate"])if((await hY(`https://${this.#$.domain}${$}`,{fetchImpl:this.#$.fetchImpl,now:this.#$.now,timeoutMs:5000})).status!==404)this.#X.add($)}start(){this.#q=!1,this.#Q=void 0,this.#I=this.#U.length,this.#V=void 0,this.#J=this.#$.now().toISOString(),this.#Y=Promise.all([this.#O(),this.#Z()]).then(()=>{return}).catch(($)=>{this.#Q=$,this.#q=!0})}async stop(){this.#q=!0,await this.#Y}async waitForHealthSnapshot($){return this.waitForEntityBaseline(void 0,void 0,$)}async waitForEntityBaseline($,U,J){let G=this.#$.now().getTime();while(this.#$.now().getTime()-G<J){let q=await this.fetchHealthPayload();if(this.#D(q,$,U))return q;await this.#$.sleep(5000)}return}async waitForStableEntityBaseline($,U,J){let G=this.#$.now().getTime(),q=0;while(this.#$.now().getTime()-G<J){let I=await this.fetchHealthPayload();if(this.#D(I,$,U)){if(q+=1,q===2)return I}else q=0;await this.#$.sleep(5000)}return}async fetchHealthPayload(){let $=this.#$.now(),U=new AbortController,J=setTimeout(()=>U.abort(),20000);try{let G=await this.#$.fetchImpl(`https://${this.#$.domain}/health/operate`,{signal:U.signal}),q=await G.text();if(this.#U.push({timestamp:$.toISOString(),endpoint:"/health/operate",status:G.status,durationMs:Math.max(0,this.#$.now().getTime()-$.getTime()),ok:G.ok}),!G.ok)return;return HG$.parse(JSON.parse(q)).app}catch(G){this.#U.push({timestamp:$.toISOString(),endpoint:"/health/operate",status:0,durationMs:Math.max(0,this.#$.now().getTime()-$.getTime()),ok:!1,error:G instanceof Error?`${G.name}: ${G.message}`:String(G)});return}finally{clearTimeout(J)}}#D($,U,J){return $!==void 0&&(U===void 0||YQ($)===U)&&(J===void 0||$.entities===J)}async#O(){while(!this.#q){for(let $ of this.#X)this.#U.push(await hY(`https://${this.#$.domain}${$}`,{fetchImpl:this.#$.fetchImpl,now:this.#$.now,timeoutMs:20000}));await this.#$.sleep(4000)}}async#Z(){while(!this.#q){let $=await this.#$.sampleRuntime();if($)this.#G.push($);await this.#$.sleep(1000)}}}var HG$;var Cv=O$(()=>{b$();rY();HG$=N.object({status:N.literal("ready"),operationalStatus:N.literal("operational"),app:N.object({version:N.string(),entities:N.number().int().nonnegative(),entityCounts:N.array(N.object({entityType:N.string(),count:N.number().int().nonnegative()})).default([])})})});var iY={};UU(iY,{verifyDirectorySyncStressAccess:()=>Fv,runStressCommand:()=>C6,runDeployedDirectorySyncStress:()=>vv,removeProbeFiles:()=>yH,parseStressRuntimeSample:()=>fv,listProbeFiles:()=>yG,cleanupDirectorySyncStress:()=>bv,applyDirectorySyncStressPhase:()=>xv});import{chmod as TG$,mkdir as bH,mkdtemp as uH,readFile as zG$,readdir as AG$,rename as KG$,rm as WQ,writeFile as iU}from"fs/promises";import{tmpdir as kH}from"os";import{join as c$,resolve as xH}from"path";async function vv($){let U=$.now??(()=>new Date),J=U().toISOString(),G=mH(J),q=xH($.artifactsDir??c$($.rootDir,".brains-ops","stress",G));await bH(q,{recursive:!0});let{pilot:I,user:Q}=await fH($.rootDir,$.handle);DQ({handle:Q.handle,domain:Q.domain,contentRepo:Q.contentRepo,confirmation:$.confirmation});let D=IQ.parse($.profile),X=$.plan?QQ.parse($.plan):CH(D);if(X.profile!==D)throw Error(`Directory-sync stress plan profile ${X.profile} does not match requested profile ${D}`);if((X.maximumExternalAiCalls??0)===0)kv(Q);let Y=gG$.parse($.env??process.env),V=new uv({runId:G,artifactsDir:q,user:Q,githubOrg:I.githubOrg,serverLabel:`${I.contentRepoPrefix}${Q.handle}`,environment:Y,fetchImpl:$.fetchImpl??fetch,commandRunner:$.commandRunner??C6,logger:$.logger??console.info,now:U,sleep:$.sleep??Bun.sleep}),W;try{W=await _H(X,V)}finally{await V.dispose()}let O={runId:G,artifactsDir:q,target:{handle:Q.handle,domain:Q.domain,contentRepo:`${I.githubOrg}/${Q.contentRepo}`},startedAt:J,completedAt:U().toISOString(),report:W};return await LG$(O),O}async function Fv($){let J=($.now??(()=>new Date))().toISOString(),G=mH(J),q=xH($.artifactsDir??c$($.rootDir,".brains-ops","stress",`access-check-${G}`));await bH(q,{recursive:!0});let{pilot:I,user:Q}=await fH($.rootDir,$.handle);DQ({handle:Q.handle,domain:Q.domain,contentRepo:Q.contentRepo,confirmation:$.confirmation}),kv(Q);let D=($.env??process.env).CONTENT_REPO_ADMIN_TOKEN;if(!D)throw Error("Missing CONTENT_REPO_ADMIN_TOKEN");let X=await uH(c$(kH(),"brains-ops-directory-sync-access-check-"));try{let Y=await _6.clone($.commandRunner??C6,`${I.githubOrg}/${Q.contentRepo}`,c$(X,"content"),D),V=await Y.output(["rev-parse","HEAD"]);await Y.run(["push","--dry-run","origin",`HEAD:refs/heads/ops/directory-sync-stress-access-check-${G}`]);let W={success:!0,artifactsDir:q,checkedAt:J,remoteHead:V,target:{handle:Q.handle,domain:Q.domain,contentRepo:`${I.githubOrg}/${Q.contentRepo}`}};return await iU(c$(q,"access-check.json"),`${JSON.stringify(W,null,2)}
|
|
300
|
+
`),W}finally{await WQ(X,{recursive:!0,force:!0})}}async function bv($){let U=$.now??(()=>new Date),J=xH($.artifactsDir??c$($.rootDir,".brains-ops","stress",`cleanup-${mH(U().toISOString())}`));await bH(J,{recursive:!0});let{pilot:G,user:q}=await fH($.rootDir,$.handle);DQ({handle:q.handle,domain:q.domain,contentRepo:q.contentRepo,confirmation:$.confirmation});let I=($.env??process.env).CONTENT_REPO_ADMIN_TOKEN;if(!I)throw Error("Missing CONTENT_REPO_ADMIN_TOKEN");let Q=$.commandRunner??C6,D=$.logger??console.info,X=await uH(c$(kH(),"brains-ops-directory-sync-cleanup-")),Y=c$(X,"content");try{let V=await _6.clone(Q,`${G.githubOrg}/${q.contentRepo}`,Y,I),W=await yH(V.dir),O;if(W>0)await V.commitAll("test(directory-sync): clean residual stress probes"),await V.pushMainWithRebase(),O=await V.output(["rev-parse","HEAD"]),D(`Removed ${W} directory-sync stress probes`);let Z=(await yG(V.dir)).length,M=Z===0?await V.pruneStressBackupBranches():[],w={success:Z===0,artifactsDir:J,probesRemoved:W,probesRemaining:Z,backupBranchesDeleted:M,...O?{cleanupCommit:O}:{}};return await iU(c$(J,"cleanup.json"),`${JSON.stringify(w,null,2)}
|
|
301
|
+
`),w}finally{await WQ(X,{recursive:!0,force:!0})}}class uv{#$;#U;#G;#X;#q;#Y;#Q;#J;#I;#V;#D;constructor($){this.#$=$,this.#U=new vH({domain:$.user.domain,fetchImpl:$.fetchImpl,now:$.now,sleep:$.sleep,sampleRuntime:()=>this.#T()})}async prepare($){this.#G=await uH(c$(kH(),"brains-ops-directory-sync-stress-"));let U=c$(this.#G,"content");this.#q=c$(this.#G,"id_ed25519"),this.#Y=c$(this.#G,"known_hosts"),this.#Q=await this.#Z(),await iU(this.#q,SG$(this.#$.environment.KAMAL_SSH_PRIVATE_KEY),{mode:384}),await TG$(this.#q,384);let J=await this.#N("ssh-keyscan",["-T","10","-t","ed25519",this.#Q]);if(J.exitCode!==0||!J.stdout.trim())throw Error("Unable to resolve smoke SSH host key");await iU(this.#Y,J.stdout,{mode:384});let G=await this.#W(["docker","ps","--filter","label=service=rover","--filter","label=role=web","--format","{{.Names}}"]);if(this.#J=G.stdout.trim().split(/\r?\n/)[0],!this.#J||!/^[A-Za-z0-9_.-]+$/.test(this.#J))throw Error("Unable to resolve a running smoke container");let q=await _6.clone(this.#$.commandRunner,`${this.#$.githubOrg}/${this.#$.user.contentRepo}`,U,this.#$.environment.CONTENT_REPO_ADMIN_TOKEN);if(this.#X=q,(await yG(q.dir)).length>0)throw Error("Directory-sync stress probes already exist");let I=await q.output(["rev-parse","HEAD"]);this.#V=await q.output(["rev-parse","HEAD^{tree}"]),this.#D=await this.#O();let Q=await this.#U.waitForHealthSnapshot(60000);if(!Q)throw Error("Smoke health was unavailable before stress testing");return this.#I=`ops/directory-sync-stress-backup-${this.#$.runId}`,await q.run(["push","origin",`HEAD:refs/heads/${this.#I}`]),await this.#U.discoverEndpoints(),await iU(c$(this.#$.artifactsDir,"state.json"),`${JSON.stringify({runId:this.#$.runId,profile:$.profile,originalHead:I,originalTree:this.#V,backupBranch:this.#I,baseline:{entities:Q.entities,notes:YQ(Q),version:Q.version}},null,2)}
|
|
302
|
+
`),this.#$.logger(`Prepared ${$.profile} directory-sync stress run for ${this.#$.user.handle}`),{entities:Q.entities,notes:YQ(Q),version:Q.version}}async startMonitoring(){this.#w(),this.#U.start()}async executePhase($,U){this.#w();let J=this.#X;if(!J)throw Error("Directory-sync stress checkout is not prepared");await J.sync();let G=this.#U.healthSamples.length,q=this.#$.now().getTime(),I=await this.#R();if(I?.pending!==0||I.processing!==0)return v6($,"health did not provide a drained queue before the phase");await xv(J.dir,$),await J.commitAll(`test(directory-sync): stress ${$.id}`),await J.pushMainWithRebase();let Q=this.#$.now().getTime(),D=await J.output(["rev-parse","HEAD"]),X=await this.#M(D,900000);if(X===void 0)return v6($,"runtime did not pull the phase commit");let Y;if($.operation==="rename"){let Z=U.notes+$.targetProbeCount;if($.settleMs>0)await this.#$.sleep($.settleMs);let M=await this.#U.waitForStableEntityBaseline(Z,void 0,1200000);if(Y=this.#$.now().getTime()-Q,!M)return v6($,`health did not stabilize at ${Z} notes`,X,Y)}else if($.operation==="add"||$.operation==="delete"){let Z=U.notes+$.targetProbeCount,M=this.#$.now().getTime(),w=await this.#U.waitForEntityBaseline(Z,void 0,1200000);if(Y=this.#$.now().getTime()-M,!w)return v6($,`health did not reach ${Z} notes`,X,Y)}if($.operation!=="rename"&&$.settleMs>0)await this.#$.sleep($.settleMs);let V=$.operation==="delete"?0:Math.ceil($.count/50);if(!await this.#H(I.completedImports+V,1200000))return v6($,`health did not observe ${V} completed import job(s) with a drained queue`,X,Y);let O=this.#U.healthSamples.slice(G).find((Z)=>!Z.ok);if(O)return v6($,`${O.endpoint} unavailable (${O.status===0?O.error??"unknown":O.status})`,X,Y);return this.#$.logger(`Completed ${$.id} in ${this.#$.now().getTime()-q}ms`),{id:$.id,operation:$.operation,count:$.count,success:!0,commitLatencyMs:X,...Y===void 0?{}:{persistenceLatencyMs:Y}}}async cleanup($){let U=this.#X;if(!U)return{success:!1,probesRemaining:0,error:"stress checkout was not prepared"};try{if(await U.sync(!0),await yH(U.dir)>0)await U.commitAll("test(directory-sync): remove stress probes"),await U.pushMainWithRebase();let G=(await yG(U.dir)).length;this.#U.markGateEnd();let q=await this.#U.waitForEntityBaseline($.notes,$.entities,1200000);await U.sync(!0);let Q=await U.output(["rev-parse","HEAD^{tree}"])===this.#V,D=G===0&&q!==void 0&&Q;if(D&&this.#I){if((await U.run(["push","origin","--delete",this.#I],!1)).exitCode!==0)this.#$.logger(`Warning: unable to delete backup branch ${this.#I}`)}return{success:D,probesRemaining:G,...q?{finalEntities:q.entities,finalNotes:YQ(q)}:{},contentTreeRestored:Q,...!D?{error:!q?"entity baseline was not restored before cleanup timeout":!Q?"content tree differs from the pre-stress baseline":"stress probes remain after cleanup"}:{}}}catch(J){return{success:!1,probesRemaining:(await yG(U.dir)).length,error:q0(J)}}}async stopMonitoring(){await this.#U.stop(),await iU(c$(this.#$.artifactsDir,"health-samples.json"),`${JSON.stringify(this.#U.healthSamples,null,2)}
|
|
303
|
+
`);let $=0;if(this.#J&&this.#U.startedAt){let G=await this.#W(["docker","logs","--since",this.#U.startedAt,this.#J],!1),q=`${G.stdout}${G.stderr}`;$=q.match(/\] ai:usage \{/g)?.length??0,await iU(c$(this.#$.artifactsDir,"runtime.log"),q)}let U=await this.#O(),J={health:this.#U.gateHealthSamples(),runtime:[...this.#U.runtimeSamples],externalAiCalls:$,...U?{container:U}:{}};if(this.#U.error)throw this.#U.error;return J}async dispose(){if(await this.#U.stop(),this.#G)await WQ(this.#G,{recursive:!0,force:!0})}async#O(){if(!this.#J)return;let $=await this.#W(["docker","inspect",this.#J],!1);if($.exitCode!==0)return;try{let J=N.array(N.object({RestartCount:N.number().int().nonnegative(),State:N.object({Status:N.string(),OOMKilled:N.boolean(),StartedAt:N.string().min(1)})})).parse(JSON.parse($.stdout))[0];if(!J)return;let G=Math.max(0,J.RestartCount-(this.#D?.restartCount??0)),q=this.#D!==void 0&&J.State.StartedAt!==this.#D.startedAt;return{status:J.State.Status,restartCount:Math.max(G,q?1:0),oomKilled:J.State.OOMKilled&&!(this.#D?.oomKilled??!1),startedAt:J.State.StartedAt}}catch{return}}async#Z(){let $=encodeURIComponent(`brain=${this.#$.serverLabel}`),U=await this.#$.fetchImpl(`https://api.hetzner.cloud/v1/servers?label_selector=${$}`,{headers:{Authorization:`Bearer ${this.#$.environment.HCLOUD_TOKEN}`}});if(!U.ok)throw Error(`Hetzner server lookup failed with ${U.status}`);let G=jG$.parse(await U.json()).servers[0];if(G?.status!=="running")throw Error("Smoke server is not running");return G.public_net.ipv4.ip}async#M($,U){let J=this.#J;if(!J)throw Error("Directory-sync stress container is not prepared");let G=this.#$.now().getTime();while(this.#$.now().getTime()-G<U){if((await this.#W(["docker","exec",J,"git","-C","/app/brain-data","merge-base","--is-ancestor",$,"HEAD"],!1)).exitCode===0)return this.#$.now().getTime()-G;await this.#$.sleep(5000)}return}async#R(){let $=new AbortController,U=setTimeout(()=>$.abort(),20000);try{let J=await this.#$.fetchImpl(`https://${this.#$.user.domain}/health/operate`,{method:"GET",signal:$.signal});if(!J.ok)return;let G=PG$.parse(await J.json()),q=G.resources.queue.byType.filter((I)=>I.type==="directory-sync:directory-import"&&I.status==="completed").reduce((I,Q)=>I+Q.count,0);return{pending:G.resources.queue.totals.pending,processing:G.resources.queue.totals.processing,completedImports:q}}catch{return}finally{clearTimeout(U)}}async#H($,U){let J=this.#$.now().getTime(),G=0;while(this.#$.now().getTime()-J<U){let q=await this.#R();if(q?.pending===0&&q.processing===0&&q.completedImports>=$){if(G+=1,G===2)return!0}else G=0;await this.#$.sleep(5000)}return!1}async#T(){let $=this.#J;if(!$)throw Error("Directory-sync stress container is not prepared");let U=await this.#W(["timeout","15","docker","stats","--no-stream","--format","{{.CPUPerc}},{{.MemPerc}},{{.PIDs}}",$],!1);return fv(U.stdout.trim(),this.#$.now().toISOString())}async#W($,U=!0){let J=this.#q,G=this.#Y,q=this.#Q;if(!J||!G||!q)throw Error("Directory-sync stress SSH access is not prepared");let I=await this.#N("ssh",["-i",J,"-o","BatchMode=yes","-o","IdentitiesOnly=yes","-o","ConnectTimeout=10","-o","StrictHostKeyChecking=yes","-o",`UserKnownHostsFile=${G}`,`root@${q}`,...$]);if(U&&I.exitCode!==0)throw XQ("ssh",$,I);return I}async#N($,U,J){return this.#$.commandRunner($,U,J)}#w(){if(!this.#X||!this.#q||!this.#Y||!this.#Q||!this.#J)throw Error("Directory-sync stress driver is not prepared")}}function kv($){if($.embeddingEnabled!==!1)throw Error("Directory-sync stress requires embeddingEnabled: false for a hermetic smoke workload");if($.topicExtractionEnabled!==!1)throw Error("Directory-sync stress requires topicExtractionEnabled: false for a hermetic smoke workload")}async function fH($,U){let J=await M0($),G=J.users.find((q)=>q.handle===U);if(!G)throw Error(`Unknown pilot user: ${U}`);return{pilot:J.pilot,user:G}}async function xv($,U){let J=await yG($);switch(U.operation){case"add":{let G=U.targetProbeCount-J.length;if(G!==U.count)throw Error(`${U.id} expected to add ${U.count} probes from ${J.length}`);let q=J.map(BG$).filter((Q)=>Q!==void 0),I=q.length===0?1:Math.max(...q)+1;for(let Q=I;Q<I+G;Q+=1){let D=String(Q).padStart(3,"0");await iU(c$($,`directory-sync-stress-${D}.md`),["---",`title: "Directory Sync Stress ${D}"`,"---","",`Deterministic directory-sync stress probe ${D}.`,"Payload: abcdefghijklmnopqrstuvwxyz-0123456789-abcdefghijklmnopqrstuvwxyz.",""].join(`
|
|
304
|
+
`))}break}case"update":{if(J.length!==U.count)throw Error(`${U.id} expected ${U.count} probes, found ${J.length}`);for(let G of J){let q=c$($,G),I=await zG$(q,"utf8");await iU(q,`${I.trimEnd()}
|
|
305
|
+
|
|
306
|
+
Update marker: ${U.id}.
|
|
307
|
+
`)}break}case"rename":{let G=J.filter((q)=>/^directory-sync-stress-\d+\.md$/.test(q)).slice(0,U.count);if(G.length!==U.count)throw Error(`${U.id} expected ${U.count} unrenamed probes, found ${G.length}`);for(let q of G)await KG$(c$($,q),c$($,q.replace("directory-sync-stress-","directory-sync-stress-renamed-")));break}case"delete":{if(J.length!==U.count)throw Error(`${U.id} expected ${U.count} probes, found ${J.length}`);await Promise.all(J.map((G)=>WQ(c$($,G),{force:!0})));break}}}async function yG($){return(await AG$($)).filter((J)=>/^directory-sync-stress-(?:renamed-)?\d+\.md$/.test(J)&&!J.includes("/")).sort()}async function yH($){let U=await yG($);return await Promise.all(U.map((J)=>WQ(c$($,J),{force:!0}))),U.length}function BG$($){let U=$.match(/(\d+)\.md$/)?.[1];return U?Number.parseInt(U,10):void 0}function v6($,U,J,G){return{id:$.id,operation:$.operation,count:$.count,success:!1,...J===void 0?{}:{commitLatencyMs:J},...G===void 0?{}:{persistenceLatencyMs:G},error:U}}function fv($,U){let[J,G,q]=$.split(",");if(!J||!G||!q)return;let I=Number.parseFloat(J.replace("%","")),Q=Number.parseFloat(G.replace("%","")),D=Number.parseInt(q,10);if(!Number.isFinite(I)||!Number.isFinite(Q)||!Number.isFinite(D))return;return{timestamp:U,cpuPercent:I,memoryPercent:Q,pids:D}}function SG$($){return`${$.replace(/\r\n/g,`
|
|
308
|
+
`).replace(/\\n/g,`
|
|
309
|
+
`).trimEnd()}
|
|
310
|
+
`}function mH($){return $.replace(/[-:.TZ]/g,"").slice(0,14)}async function LG$($){await iU(c$($.artifactsDir,"report.json"),`${JSON.stringify($,null,2)}
|
|
311
|
+
`),await iU(c$($.artifactsDir,"report.md"),EG$($))}function EG$($){let U=$.report.metrics.runtime,J=$.report.metrics.health,G=U.map((D)=>D.cpuPercent).sort((D,X)=>D-X),q=U.map((D)=>D.memoryPercent),I=J.filter((D)=>!D.ok),Q=["# Directory-sync stress report","",`- Run: \`${$.runId}\``,`- Target: \`${$.target.handle}\` (${$.target.domain})`,`- Profile: \`${$.report.profile}\``,`- Version: \`${$.report.baseline.version}\``,`- Result: **${$.report.success?"PASS":"FAIL"}**`,`- Started: ${$.startedAt}`,`- Completed: ${$.completedAt}`,"","## Phases","","| Phase | Operation | Count | Result | Pull latency | Persistence latency |","| --- | --- | ---: | --- | ---: | ---: |",...$.report.phases.map((D)=>`| ${D.id} | ${D.operation} | ${D.count} | ${D.success?"pass":`fail: ${D.error??"unknown"}`} | ${_v(D.commitLatencyMs)} | ${_v(D.persistenceLatencyMs)} |`),"","## Runtime","",`- Samples: ${U.length}`,`- CPU p50/p95/p99/max: ${VQ(FH(G,0.5))} / ${VQ(FH(G,0.95))} / ${VQ(FH(G,0.99))} / ${VQ(G.at(-1))}`,`- Memory max: ${VQ(q.length?Math.max(...q):void 0)}`,`- PIDs max: ${U.length?Math.max(...U.map((D)=>D.pids)):"n/a"}`,`- Container status/restarts/OOM: ${$.report.metrics.container?`${$.report.metrics.container.status} / ${$.report.metrics.container.restartCount} / ${$.report.metrics.container.oomKilled}`:"unknown"}`,`- External AI calls: ${$.report.metrics.externalAiCalls??0}`,`- Health samples: ${J.length}`,`- Health failures: ${I.length}`,"","## Cleanup","",`- Result: ${$.report.cleanup.success?"pass":"fail"}`,`- Remaining probes: ${$.report.cleanup.probesRemaining}`,`- Final entities: ${$.report.cleanup.finalEntities??"unknown"}`,`- Final notes: ${$.report.cleanup.finalNotes??"unknown"}`,`- Content tree restored: ${$.report.cleanup.contentTreeRestored??"unknown"}`,""];if($.report.failure)Q.push("## Failure","",$.report.failure,"");return`${Q.join(`
|
|
312
|
+
`)}
|
|
313
|
+
`}function FH($,U){if($.length===0)return;let J=Math.max(0,Math.ceil($.length*U)-1);return $[J]}function VQ($){return $===void 0?"n/a":`${$.toFixed(2)}%`}function _v($){return $===void 0?"n/a":`${($/1000).toFixed(1)}s`}var gG$,jG$,PG$;var OQ=O$(()=>{b$();rY();RJ();lY();Ev();Cv();lY();gG$=N.object({HCLOUD_TOKEN:N.string().min(1),KAMAL_SSH_PRIVATE_KEY:N.string().min(1),CONTENT_REPO_ADMIN_TOKEN:N.string().min(1)}),jG$=N.object({servers:N.array(N.object({id:N.number().int(),status:N.string(),public_net:N.object({ipv4:N.object({ip:N.string().min(1)})})}))}),PG$=N.object({status:N.literal("ready"),operationalStatus:N.literal("operational"),resources:N.object({queue:N.object({totals:N.object({pending:N.number().int().nonnegative(),processing:N.number().int().nonnegative()}),byType:N.array(N.object({type:N.string(),status:N.string(),count:N.number().int().nonnegative()}))})})})});import{access as qg,chmod as u7,mkdir as UX,readFile as Ig,writeFile as Gg}from"fs/promises";import{dirname as ck,join as B8}from"path";import{fileURLToPath as ok}from"url";var ZQ={name:"@rizom/ops",version:"0.2.0-alpha.300",description:"Operator CLI for managing private brain fleet registry repos",keywords:["brains","ops","cli","deploy","fleet","operator"],license:"AGPL-3.0-only",author:"Yeehaa <yeehaa@rizom.ai> (https://rizom.ai)",bin:{"brains-ops":"./dist/brains-ops.js"},bugs:"https://github.com/rizom-ai/brains/issues",dependencies:{"age-encryption":"^0.3.0",yaml:"^2.9.0"},devDependencies:{"@brains/deploy-support":"workspace:*","@brains/eslint-config":"workspace:*","@brains/profile":"workspace:*","@brains/site-composition":"workspace:*","@brains/typescript-config":"workspace:*","@brains/utils":"workspace:*","@types/bun":"^1.3.14",typescript:"^7.0.2"},engines:{bun:">=1.3.3"},exports:{".":{types:"./dist/index.d.ts",import:"./dist/index.js"},"./deploy":{types:"./dist/deploy.d.ts",import:"./dist/deploy.js",bun:"./dist/deploy.js"}},files:["dist","templates"],homepage:"https://github.com/rizom-ai/brains/tree/main/packages/brains-ops#readme",main:"./dist/index.js",publishConfig:{access:"public"},repository:{type:"git",url:"https://github.com/rizom-ai/brains.git",directory:"packages/brains-ops"},scripts:{build:"bun scripts/build.ts",lint:"eslint . --max-warnings 0","lint:fix":"eslint . --max-warnings 0 --fix",prepublishOnly:"bun scripts/build.ts",test:"bun run build && bun test --timeout 20000","test:smoke":"bun run build && RUN_SMOKE_TESTS=1 bun test --timeout 60000",typecheck:"tsc --noEmit"},type:"module",types:"./dist/index.d.ts"};var pH=`ARG BUN_VERSION=1.3.10
|
|
314
|
+
FROM oven/bun:\${BUN_VERSION}-slim AS runtime
|
|
315
|
+
|
|
316
|
+
LABEL ai.rizom.brain.watchdog="true"
|
|
317
|
+
|
|
318
|
+
WORKDIR /app
|
|
319
|
+
|
|
320
|
+
RUN apt-get update && apt-get install -y --no-install-recommends \\
|
|
321
|
+
curl ca-certificates git tini \\
|
|
322
|
+
&& rm -rf /var/lib/apt/lists/*
|
|
323
|
+
|
|
324
|
+
ENV XDG_DATA_HOME=/data
|
|
325
|
+
ENV XDG_CONFIG_HOME=/config
|
|
326
|
+
RUN mkdir -p /app/data /app/cache /app/brain-data && \\
|
|
327
|
+
chmod -R 777 /app/data /app/cache /app/brain-data
|
|
328
|
+
|
|
329
|
+
EXPOSE 8080
|
|
330
|
+
|
|
331
|
+
HEALTHCHECK --interval=30s --timeout=5s --start-period=60s --retries=3 \\
|
|
332
|
+
CMD curl --fail --silent --show-error http://127.0.0.1:8080/health/live || exit 1
|
|
333
|
+
|
|
334
|
+
ENTRYPOINT ["/usr/bin/tini", "--"]
|
|
335
|
+
CMD ["bun", "./node_modules/@rizom/brain/dist/brain.js", "start"]
|
|
336
|
+
|
|
337
|
+
# --- standalone: bake full project into image (brain-cli deploy) ---
|
|
338
|
+
FROM runtime AS standalone
|
|
339
|
+
COPY package.json ./package.json
|
|
340
|
+
RUN bun install --production --ignore-scripts
|
|
341
|
+
RUN bunx playwright-core install --with-deps chromium-headless-shell \\
|
|
342
|
+
&& rm -rf /var/lib/apt/lists/* /tmp/*
|
|
343
|
+
COPY . .
|
|
344
|
+
|
|
345
|
+
# --- fleet: install published brain at pinned version (ops deploy) ---
|
|
346
|
+
FROM runtime AS fleet
|
|
347
|
+
ARG BRAIN_VERSION
|
|
348
|
+
ARG SITE_PACKAGES
|
|
349
|
+
# playwright-core is also installed explicitly so the chromium install
|
|
350
|
+
# below resolves against an installed package rather than relying on
|
|
351
|
+
# transitive resolution from @rizom/brain. The brain bundle externalizes
|
|
352
|
+
# playwright-core, so a missing or mismatched install would fail at
|
|
353
|
+
# runtime rather than build time.
|
|
354
|
+
RUN test -n "$BRAIN_VERSION" \\
|
|
355
|
+
&& printf '{"name":"rover-pilot-runtime","private":true}\\n' > package.json \\
|
|
356
|
+
&& if [ -n "$SITE_PACKAGES" ]; then \\
|
|
357
|
+
bun add @rizom/brain@$BRAIN_VERSION playwright-core $SITE_PACKAGES; \\
|
|
358
|
+
else \\
|
|
359
|
+
bun add @rizom/brain@$BRAIN_VERSION playwright-core; \\
|
|
360
|
+
fi
|
|
361
|
+
RUN bunx playwright-core install --with-deps chromium-headless-shell \\
|
|
362
|
+
&& rm -rf /var/lib/apt/lists/* /tmp/*
|
|
363
|
+
`;var dH=`service: __SERVICE_NAME__
|
|
364
|
+
image: <%= ENV['IMAGE_REPOSITORY'] %>
|
|
365
|
+
|
|
366
|
+
servers:
|
|
367
|
+
web:
|
|
368
|
+
hosts:
|
|
369
|
+
- <%= ENV['SERVER_IP'] %>
|
|
370
|
+
|
|
371
|
+
proxy:
|
|
372
|
+
ssl:
|
|
373
|
+
certificate_pem: CERTIFICATE_PEM
|
|
374
|
+
private_key_pem: PRIVATE_KEY_PEM
|
|
375
|
+
hosts:
|
|
376
|
+
- <%= ENV['BRAIN_DOMAIN'] %>
|
|
377
|
+
# <% if ENV['WWW_DOMAIN'] && !ENV['WWW_DOMAIN'].empty? %>
|
|
378
|
+
- <%= ENV['WWW_DOMAIN'] %>
|
|
379
|
+
# <% end %>
|
|
380
|
+
- <%= ENV['PREVIEW_DOMAIN'] %>
|
|
381
|
+
app_port: 8080
|
|
382
|
+
healthcheck:
|
|
383
|
+
path: /health/ready
|
|
384
|
+
|
|
385
|
+
registry:
|
|
386
|
+
server: ghcr.io
|
|
387
|
+
username: <%= ENV['REGISTRY_USERNAME'] %>
|
|
388
|
+
password:
|
|
389
|
+
- KAMAL_REGISTRY_PASSWORD
|
|
390
|
+
|
|
391
|
+
builder:
|
|
392
|
+
arch: amd64
|
|
393
|
+
|
|
394
|
+
env:
|
|
395
|
+
clear:
|
|
396
|
+
NODE_ENV: production
|
|
397
|
+
secret:
|
|
398
|
+
- AI_API_KEY
|
|
399
|
+
- GIT_SYNC_TOKEN
|
|
400
|
+
- DISCORD_BOT_TOKEN
|
|
401
|
+
- DISCORD_PUBLIC_KEY
|
|
402
|
+
- DISCORD_APPLICATION_ID
|
|
403
|
+
- ATPROTO_APP_PASSWORD
|
|
404
|
+
- SETUP_EMAIL_TO
|
|
405
|
+
- SETUP_EMAIL_API_KEY
|
|
406
|
+
- SETUP_EMAIL_FROM
|
|
407
|
+
|
|
408
|
+
volumes:
|
|
409
|
+
- /opt/brain-data:/app/brain-data
|
|
410
|
+
- /opt/brain-runtime:/app/data
|
|
411
|
+
- /opt/brain-state:/data
|
|
412
|
+
- /opt/brain-config:/config
|
|
413
|
+
- /opt/brain-dist:/app/dist
|
|
414
|
+
- /opt/brain.yaml:/app/brain.yaml
|
|
415
|
+
`;function cY($={}){let U=$.deployConfigPath??"config/deploy.yml";return`#!/usr/bin/env bash
|
|
416
|
+
set -euo pipefail
|
|
417
|
+
|
|
418
|
+
BRAIN_FILE="${$.brainYamlPath??"brain.yaml"}"
|
|
419
|
+
SSH_USER="$(ruby -e 'require "yaml"; config = YAML.load_file("${U}") || {}; puts(config.dig("ssh", "user") || "root")')"
|
|
420
|
+
IFS=',' read -ra HOSTS <<< "$KAMAL_HOSTS"
|
|
421
|
+
for host in "\${HOSTS[@]}"; do
|
|
422
|
+
scp -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null "$BRAIN_FILE" "\${SSH_USER}@\${host}:/opt/brain.yaml"
|
|
423
|
+
done
|
|
424
|
+
`}import{appendFileSync as hG$,readFileSync as wF}from"fs";var MF=/^# ---- .+ ----$/;function nH($,U){let J=[],G=new Set,q=U?.skipSections??new Set,I=!1,Q=!1,D=!1;for(let X of $.split(/\r?\n/)){let Y=X.trim();if(MF.test(Y)){I=q.has(Y),Q=!1,D=!1;continue}if(I)continue;if(Y.startsWith("#")){if(Y.includes("@required"))Q=!0;if(Y.includes("@sensitive"))D=!0;continue}let V=Y.match(/^([A-Z][A-Z0-9_]*)=/);if(!V?.[1]){Q=!1,D=!1;continue}let W=V[1];if(!G.has(W))G.add(W),J.push({key:W,required:Q,sensitive:D});Q=!1,D=!1}return J}function oY($,U){return nH(wF($,"utf8"),U)}import{existsSync as HF,readFileSync as TF}from"fs";import{homedir as zF}from"os";import{isAbsolute as AF,join as aY,resolve as KF}from"path";function bU($){let U={};for(let J of[aY($,".env"),aY($,".env.local")]){if(!HF(J))continue;let G=gF(TF(J,"utf8"));for(let[q,I]of Object.entries(G))U[q]=I}return U}function O0($,U,J){return U[$]??J[$]}function xJ($,U){if($.startsWith("~/"))return aY(process.env.HOME??zF(),$.slice(2));if(AF($))return $;return KF(U,$)}function gF($){let U={};for(let J of $.split(/\r?\n/)){let G=J.trim();if(G.length===0||G.startsWith("#"))continue;let q=J.match(/^\s*(?:export\s+)?([A-Z][A-Z0-9_]*)\s*=\s*(.*)\s*$/),I=q?.[1],Q=q?.[2];if(!I||Q===void 0)continue;U[I]=jF(Q)}return U}function jF($){if($.length>=2&&$.startsWith("'")&&$.endsWith("'"))return $.slice(1,-1);if($.length>=2&&$.startsWith('"')&&$.endsWith('"'))return $.slice(1,-1).replace(/\\n/g,`
|
|
425
|
+
`).replace(/\\r/g,"\r").replace(/\\t/g,"\t").replace(/\\"/g,'"').replace(/\\\\/g,"\\");return $}var oH=["install-health-watchdog.ts","provision-server.ts","update-dns.ts","validate-secrets.ts","write-kamal-secrets.ts","write-ssh-key.ts"];var PF={"install-health-watchdog.ts":"/usr/local/sbin/brains-health-watchdog","provision-server.ts":'requireEnv("HCLOUD_TOKEN")',"update-dns.ts":'requireEnv("CF_API_TOKEN")',"validate-secrets.ts":"const requiredKeys = schema","write-kamal-secrets.ts":".kamal/secrets","write-ssh-key.ts":'requireEnv("KAMAL_SSH_PRIVATE_KEY")'};function aH($,U,J){if(U===J)return!1;return U.includes(PF[$])}function sH(){return pH}function tH($){if($.includes('LABEL ai.rizom.brain.watchdog="true"')&&$.includes("http://127.0.0.1:8080/health/live")&&$.includes('ENTRYPOINT ["/usr/bin/tini", "--"]')&&$.includes('CMD ["bun", "./node_modules/@rizom/brain/dist/brain.js", "start"]'))return!1;return($.includes('CMD ["./node_modules/.bin/brain", "start"]')||$.includes('CMD ["bun", "./node_modules/@rizom/brain/dist/brain.js", "start"]'))&&["ARG BUN_VERSION=","FROM oven/bun:${BUN_VERSION}-slim AS runtime","FROM runtime AS standalone","FROM runtime AS fleet","bunx playwright-core install --with-deps chromium-headless-shell"].every((G)=>$.includes(G))}function RQ($){return dH.replace("__SERVICE_NAME__",$.serviceName)}var BF=["/opt/brain-runtime:/app/data","/opt/brain-state:/data","/opt/brain-config:/config","/opt/brain-dist:/app/dist"];function iG($){return $.replace(/\nvolumes:\n(?: {2}- .*\n)+$/,`
|
|
426
|
+
volumes:
|
|
427
|
+
- __VOLUMES__
|
|
428
|
+
`)}function cH($){return $.replace(/\n {4}# <% if ENV\['WWW_DOMAIN'\] && !ENV\['WWW_DOMAIN'\]\.empty\? %>\n {4}- <%= ENV\['WWW_DOMAIN'\] %>\n {4}# <% end %>/,"")}function eH($,U,J=(G)=>G){let G=cH(J($)),q=cH(J(RQ({serviceName:U}))),I=BF.every((X)=>G.includes(X)),Q=q.replace("path: /health/ready","path: /health"),D=iG(G);return G===Q||!I&&(D===iG(q)||D===iG(Q))}L4();var ak=["pilot.yaml","package.json",".env.schema",".gitignore","cohorts/cohort-1.yaml","users/alice.yaml",".github/actions/varlock-env/action.yml",".github/workflows/build.yml",".github/workflows/deploy.yml",".github/workflows/directory-sync-stress.yml",".github/workflows/reconcile.yml",".github/workflows/upgrade.yml","deploy/Dockerfile","deploy/kamal/deploy.yml","deploy/scripts/helpers.ts","deploy/scripts/install-health-watchdog.ts","deploy/scripts/provision-server.ts","deploy/scripts/update-dns.ts","deploy/scripts/write-ssh-key.ts","deploy/scripts/decrypt-user-secrets.ts","deploy/scripts/validate-secrets.ts","deploy/scripts/write-kamal-secrets.ts","deploy/scripts/resolve-user-config.ts","deploy/scripts/resolve-missing-images.ts","deploy/scripts/resolve-deploy-handles.ts","deploy/scripts/sync-content-repo.ts",".kamal/hooks/pre-deploy","docs/onboarding-checklist.md","docs/canonical-crossover-record.md","docs/operator-playbook.md","docs/user-onboarding.md","README.md"],k7=new Set([".kamal/hooks/pre-deploy"]),sk=new Set(["cohorts/cohort-1.yaml","users/alice.yaml","docs/canonical-crossover-record.md"]),tk=ok(new URL("../templates/rover-pilot/",import.meta.url)),ek=[`service: rover
|
|
429
|
+
image: <%= ENV['IMAGE_REPOSITORY'] %>
|
|
430
|
+
|
|
431
|
+
servers:
|
|
432
|
+
web:
|
|
433
|
+
hosts:
|
|
434
|
+
- <%= ENV['SERVER_IP'] %>
|
|
435
|
+
|
|
436
|
+
proxy:
|
|
437
|
+
ssl:
|
|
438
|
+
certificate_pem: CERTIFICATE_PEM
|
|
439
|
+
private_key_pem: PRIVATE_KEY_PEM
|
|
440
|
+
hosts:
|
|
441
|
+
- <%= ENV['BRAIN_DOMAIN'] %>
|
|
442
|
+
- <%= ENV['PREVIEW_DOMAIN'] %>
|
|
443
|
+
app_port: 80
|
|
444
|
+
healthcheck:
|
|
445
|
+
path: /health
|
|
446
|
+
|
|
447
|
+
registry:
|
|
448
|
+
server: ghcr.io
|
|
449
|
+
username: <%= ENV['REGISTRY_USERNAME'] %>
|
|
450
|
+
password:
|
|
451
|
+
- KAMAL_REGISTRY_PASSWORD
|
|
452
|
+
|
|
453
|
+
builder:
|
|
454
|
+
arch: amd64
|
|
455
|
+
|
|
456
|
+
env:
|
|
457
|
+
clear:
|
|
458
|
+
NODE_ENV: production
|
|
459
|
+
secret:
|
|
460
|
+
- AI_API_KEY
|
|
461
|
+
- GIT_SYNC_TOKEN
|
|
462
|
+
- DISCORD_BOT_TOKEN
|
|
463
|
+
|
|
464
|
+
volumes:
|
|
465
|
+
- /opt/brain-data:/app/brain-data
|
|
466
|
+
- /opt/brain.yaml:/app/brain.yaml
|
|
467
|
+
`];function oJ($){return(U)=>U.includes($)}function $x($){return oH.find((U)=>$===`deploy/scripts/${U}`)}function x7($){return $.replace(/\n {2}secret:\n(?: {4}- .*\n)+\nvolumes:\n/,`
|
|
468
|
+
secret:
|
|
469
|
+
- __DYNAMIC_SECRETS__
|
|
470
|
+
|
|
471
|
+
volumes:
|
|
472
|
+
`)}function Ux($){return eH($,"rover",x7)}function Jx($){if($.includes("DISCORD_APPLICATION_ID")&&$.includes("ATPROTO_APP_PASSWORD"))return!1;let U=iG(x7($)),J=iG(x7(RQ({serviceName:"rover"})));return U===J}var qx=[/\n# Stored with the per-user Discord credentials and injected at deploy time\.\n# @sensitive\nDISCORD_PUBLIC_KEY=\n\n# @sensitive\nDISCORD_APPLICATION_ID=\n/,/\n# AT Protocol publishing\/discovery \(optional, per-user\)\n# Comes from the decrypted users\/<handle>\.secrets\.yaml\.age file when configured\.\n# @sensitive\nATPROTO_APP_PASSWORD=\n/];function Gx($,U){let J=(G)=>qx.reduce((q,I)=>q.replace(I,`
|
|
473
|
+
`),G);return J($)===J(U)}var Ix=[`writeSecretGitHubEnv("DISCORD_PUBLIC_KEY", secrets["discordPublicKey"]);
|
|
474
|
+
writeSecretGitHubEnv("DISCORD_APPLICATION_ID", secrets["discordApplicationId"]);
|
|
475
|
+
`,`writeSecretGitHubEnv("ATPROTO_APP_PASSWORD", secrets["atprotoAppPassword"]);
|
|
476
|
+
`];function Qx($,U){let J=(G)=>Ix.reduce((q,I)=>q.replace(I,""),G);return J($)===J(U)}function Dx($){return $.includes('if (eventName !== "push") {')&&$.includes('const currentSha = requireEnv("GITHUB_SHA");')}var Xx={".env.schema":Gx,"deploy/Dockerfile":($)=>tH($),"deploy/kamal/deploy.yml":($)=>ek.includes($)||Ux($)||Jx($),"deploy/scripts/decrypt-user-secrets.ts":Qx,"deploy/scripts/resolve-deploy-handles.ts":($)=>Dx($),"deploy/scripts/helpers.ts":oJ('"@rizom/ops/deploy"'),"deploy/scripts/resolve-user-config.ts":oJ("loadPilotRegistry"),"deploy/scripts/resolve-missing-images.ts":oJ("runResolveMissingImages"),"deploy/scripts/sync-content-repo.ts":oJ("GIT_SYNC_TOKEN"),".github/workflows/build.yml":oJ("resolve-missing-images.ts"),".github/workflows/deploy.yml":oJ("install-health-watchdog.ts"),".github/workflows/reconcile.yml":oJ("brains-ops reconcile"),".github/workflows/upgrade.yml":oJ("brains-ops upgrade")};function Yx($,U,J){let G=$x($);if(G&&aH(G,U,J))return!0;return Xx[$]?.(U,J)??!1}async function f7($){await UX($,{recursive:!0});let U=B8($,"views","users.md"),J=!0;try{await qg(U)}catch{J=!1}let G=!0;try{await qg(B8($,"pilot.yaml"))}catch{G=!1}await UX(B8($,"users"),{recursive:!0}),await UX(B8($,"cohorts"),{recursive:!0});let q=ak.filter((I)=>!(G&&sk.has(I))).map(async(I)=>{let Q=B8($,I);await UX(ck(Q),{recursive:!0}),await Vx(I,Q)});if(await Promise.all(q),!J)await dq($)}async function Vx($,U){let J=await Wx($);try{if(await Gg(U,J,{flag:"wx"}),k7.has($))await u7(U,493);return}catch(q){if(!Zx(q,"EEXIST"))throw q}let G=await Ig(U,"utf8");if(G===J){if(k7.has($))await u7(U,493);return}if(!Yx($,G,J))return;if(await Gg(U,J),k7.has($))await u7(U,493)}async function Wx($){if($===".gitignore")return`node_modules/
|
|
477
|
+
.brains-ops/
|
|
478
|
+
users/*.secrets.yaml
|
|
479
|
+
`;if($==="deploy/Dockerfile")return sH();if($==="deploy/kamal/deploy.yml")return RQ({serviceName:"rover"});if($===".kamal/hooks/pre-deploy")return cY({deployConfigPath:"deploy/kamal/deploy.yml",brainYamlPath:"${BRAIN_YAML_PATH:-brain.yaml}"});let U=B8(tk,$),J=await Ig(U,"utf8");return Ox(J)}function Ox($){return $.replaceAll("__BRAINS_OPS_VERSION__",ZQ.version).replaceAll("__BUN_VERSION__",Bun.version)}function Zx($,U){return typeof $==="object"&&$!==null&&"code"in $&&$.code===U}RJ();RJ();import{createHash as Nx}from"crypto";import{spawn as Rx}from"child_process";var d0=async($,U,J={})=>new Promise((G,q)=>{let I=Rx($,U,{stdio:["pipe","inherit","inherit"],env:J.env?{...process.env,...J.env}:process.env,cwd:J.cwd});if(I.on("error",q),I.on("close",(Q)=>{if(Q===0){G();return}q(Error(`${$} ${U.join(" ")} exited with code ${Q??1}`))}),J.stdin)I.stdin.end(J.stdin);else I.stdin.end()});function y7($,U){let J=[...new Set(U.map((q)=>q.trim()).filter(Boolean))].sort();if(J.length===0)return`brain-${$}`;let G=Nx("sha256").update(J.join(`
|
|
480
|
+
`)).digest("hex").slice(0,12);return`brain-${$}-sites-${G}`}function Qg($){if(!$)return[];if(!$.theme?.startsWith("@rizom/"))return[`${$.package}@${$.version}`];if($.themeVersion===void 0)throw Error(`Theme ${$.theme} has no explicit version pin`);return[`${$.package}@${$.version}`,`${$.theme}@${$.themeVersion}`]}function Dg($){let U=new Map;for(let J of $){let G=[...new Set(Qg(J.siteOverride))].sort(),q=y7(J.brainVersion,G);U.set(q,{tag:q,brainVersion:J.brainVersion,sitePackages:G})}return[...U.values()].sort((J,G)=>J.tag.localeCompare(G.tag))}async function Xg($){let U=$.brainVersionInput?.trim()??"";if(U){let G=($.sitePackagesInput??"").split(/\s+/).filter(Boolean),q=y7(U,G);if(!$.allowTagOverwrite&&await $.imageExists(q))throw Error(`Image tag ${q} already exists; published tags are immutable. Pick a new version, or pass overwrite=true only when replacing a tag whose containers were never deployed.`);return[{tag:q,brainVersion:U,sitePackages:G}]}let J=[];for(let G of Dg($.users))if(!await $.imageExists(G.tag))J.push(G);return J}async function wx($){let U=$.env??process.env,J=$.runCommand??d0,G=$.log??console.log,q=U.BRAIN_VERSION_INPUT?.trim()??"",I=U.SITE_PACKAGES_INPUT?.trim()??"",Q=U.ALLOW_TAG_OVERWRITE?.trim()==="true",D=q?[]:(await M0($.rootDir)).users,X=await Xg({users:D,brainVersionInput:q,sitePackagesInput:I,allowTagOverwrite:Q,imageExists:async(Y)=>{try{return await J("docker",["manifest","inspect",`${$.imageRepository}:${Y}`]),!0}catch{return!1}}});for(let Y of X)G(`build needed: ${Y.tag} (brain ${Y.brainVersion}${Y.sitePackages.length>0?`, sites ${Y.sitePackages.join(" ")}`:""})`);if(X.length===0)G("All declared images already exist; nothing to build.");return $.writeOutput("images_json",JSON.stringify(X.map((Y)=>({tag:Y.tag,brain_version:Y.brainVersion,site_packages:Y.sitePackages.join(" ")})))),X}b$();var Yg=N.object({id:N.string(),template:N.string(),content:N.unknown().optional(),dataQuery:N.looseObject({entityType:N.string().optional(),template:N.string().optional(),query:N.looseObject({id:N.string().optional(),limit:N.number().optional(),offset:N.number().optional()}).optional()}).optional(),order:N.number().optional()}),Vg=["primary","secondary"],Wg=N.object({show:N.boolean().default(!1),label:N.string().optional(),slot:N.enum(Vg).default("primary"),priority:N.number().min(0).max(100).default(50)}).optional(),Og=N.object({id:N.string(),path:N.string(),title:N.string().default(""),pageLabel:N.string().optional(),description:N.string().default(""),sections:N.array(Yg).default([]),layout:N.string().default("default"),fullscreen:N.boolean().optional(),pluginId:N.string().optional(),sourceEntityType:N.string().optional(),external:N.boolean().optional(),navigation:Wg}),Mx=N.object({routes:N.array(Og),pluginId:N.string()}),Hx=N.object({paths:N.array(N.string()).optional(),pluginId:N.string().optional()}),Tx=N.object({pluginId:N.string().optional()}),zx=N.object({path:N.string()}),JX=N.object({label:N.string(),href:N.string(),priority:N.number()});b$();var qX=N.object({heading:N.string().describe("Main CTA heading text"),buttonText:N.string().describe("Call-to-action button text"),buttonLink:N.string().describe("URL or anchor for the CTA button")}),m7=N.object({blurb:N.string().optional().describe("Short italic subtitle under the section title")}),h7=N.object({represents:N.enum(["brain","anchor"]).default("anchor").describe("Identity represented by the site"),title:N.string().describe("The site's title"),description:N.string().describe("The site's description"),url:N.string().optional().describe("Canonical site URL"),copyright:N.string().optional().describe("Copyright notice text"),logo:N.boolean().optional().describe("Whether to display logo instead of title text in header"),themeMode:N.enum(["light","dark"]).optional().describe("Default theme mode"),analyticsScript:N.string().optional().describe("Analytics script HTML"),cta:qX.optional().describe("Call-to-action configuration"),sections:N.record(N.string(),m7).optional().describe("Optional per-section blurbs, keyed by section id (e.g. 'essays', 'presentations', 'about'). Used by homepage templates that render editorial section headers.")});var Ax=N.object({platform:N.enum(["github","instagram","linkedin","email","website"]).describe("Social media platform"),url:N.string().describe("Profile or contact URL"),label:N.string().optional().describe("Optional display label")}),Kx=N.object({represents:N.enum(["brain","anchor"]).default("anchor").describe("Identity represented by the site"),title:N.string().describe("The site's title"),description:N.string().describe("The site's description"),url:N.string().optional().describe("Canonical site URL"),copyright:N.string(),logo:N.boolean().optional().describe("Whether to display logo instead of title text in header"),themeMode:N.enum(["light","dark"]).optional().describe("Default theme mode"),analyticsScript:N.string().optional().describe("Analytics script HTML"),cta:qX.optional().describe("Call-to-action configuration"),sections:N.record(N.string(),m7).optional().describe("Optional per-section blurbs, keyed by section id (e.g. 'essays', 'presentations', 'about'). Used by homepage templates that render editorial section headers."),navigation:N.object({primary:N.array(JX),secondary:N.array(JX)}),socialLinks:N.array(Ax).optional().describe("Social media links from profile metadata")});b$();var eI$=N.record(N.string(),N.unknown());b$();var DQ$=N.object({message:N.string()});b$();var Zg=N.object({type:N.literal("event"),event:N.string().min(1),fromState:N.string().min(1).optional()}),gx=N.object({conversationId:N.string().min(1),interfaceType:N.string().min(1),channelId:N.string().min(1).optional(),channelName:N.string().min(1),userPermissionLevel:N.enum(["admin","trusted","public"]),isAnchor:N.boolean(),action:Zg});b$();var Rg=N.object({id:N.string(),toolCallId:N.string().optional(),toolName:N.string(),summary:N.string(),completionSummary:N.string().optional(),preview:N.string().optional(),args:N.unknown()}),Ng=N.enum(["approval-requested","approval-responded","output-available","output-denied","output-error"]),jx=N.object({kind:N.literal("tool-approval"),id:N.string(),toolCallId:N.string().optional(),toolName:N.string(),input:N.record(N.string(),N.unknown()).optional(),summary:N.string(),completionSummary:N.string().optional(),preview:N.string().optional(),state:Ng,output:N.unknown().optional(),error:N.string().optional()});var wg=N.object({entityType:N.string().optional(),entityId:N.string().optional(),attachmentType:N.string().optional()}),Mg=N.object({mediaType:N.string().min(1),url:N.string().min(1),downloadUrl:N.string().min(1).optional(),previewUrl:N.string().min(1).optional(),filename:N.string().min(1).optional(),sizeBytes:N.number().nonnegative().optional(),source:wg.optional()}),Px=N.object({kind:N.literal("attachment"),id:N.string(),jobId:N.string().optional(),title:N.string(),description:N.string().optional(),attachment:Mg});var Hg=N.object({id:N.string().min(1),title:N.string().min(1).optional(),source:N.string().min(1),url:N.string().min(1).optional(),entityType:N.string().min(1).optional(),entityId:N.string().min(1).optional(),excerpt:N.string().min(1).optional(),provenance:N.record(N.string(),N.unknown()).optional()}),Bx=N.object({kind:N.literal("sources"),id:N.string().min(1),title:N.string().min(1).optional(),sources:N.array(Hg).min(1)});var Sx=N.object({type:N.literal("prompt"),id:N.string().min(1),label:N.string().min(1),prompt:N.string().min(1),description:N.string().min(1).optional()});var Lx=N.object({type:N.literal("event"),id:N.string().min(1),label:N.string().min(1),event:N.string().min(1),fromState:N.string().min(1).optional(),description:N.string().min(1).optional()});var Tg=N.discriminatedUnion("type",[Sx,Lx]),Ex=N.object({kind:N.literal("actions"),id:N.string().min(1),title:N.string().min(1).optional(),defaultOpen:N.boolean().optional(),actions:N.array(Tg).min(1)});var zg=N.discriminatedUnion("kind",[jx,Px,Bx,Ex]),Ag=N.object({toolName:N.string(),args:N.record(N.string(),N.unknown()).optional(),jobId:N.string().optional(),data:N.unknown().optional(),error:N.object({message:N.string(),code:N.string().optional()}).optional()}),Cx=N.object({text:N.string(),toolResults:N.array(Ag).optional(),cards:N.array(zg).optional(),pendingConfirmations:N.array(Rg).optional(),usage:N.object({promptTokens:N.number(),completionTokens:N.number(),totalTokens:N.number()})});b$();var Kg=N.enum(["admin","trusted","public"]),_x=N.object({conversationId:N.string().min(1),message:N.string(),interfaceType:N.string().min(1),channelId:N.string().optional(),channelName:N.string().optional(),userPermissionLevel:Kg}),gg=N.object({id:N.string().min(1),source:N.string().min(1),title:N.string().optional(),content:N.string().min(1),provenance:N.record(N.string(),N.unknown()).optional()}),vx=N.object({items:N.array(gg).default([])});b$();var l7=N.discriminatedUnion("kind",[N.object({kind:N.literal("user"),userId:N.string().min(1),canonicalId:N.string().min(1).optional()}),N.object({kind:N.literal("external"),externalActorId:N.string().min(1)}),N.object({kind:N.literal("agent"),agentId:N.string().min(1)}),N.object({kind:N.literal("service"),serviceId:N.string().min(1)})]);b$();var Fx=N.object({actor:l7}),jg=N.object({userId:N.string().min(1),personId:N.string().min(1),canonicalId:N.string().min(1).optional(),displayName:N.string().min(1),permissionLevel:N.enum(["admin","trusted","public"])}),bx=N.object({principal:jg.nullable()});b$();var i7=N.strictObject({name:N.string().min(1).optional(),address:N.email()}),ux=N.strictObject({personId:N.string().min(1).max(200),displayName:N.string().trim().min(1).max(200),permissionLevel:N.enum(["admin","trusted","public"])}),kx=N.strictObject({messageId:N.string().min(1),sourceRef:N.string().min(1),threadId:N.string().min(1).optional(),from:i7,replyTo:i7.optional(),to:N.array(i7),subject:N.string(),receivedAt:N.iso.datetime(),text:N.string(),html:N.string().min(1).optional(),headers:N.strictObject({listUnsubscribe:N.string().min(1).optional(),autoSubmitted:N.string().min(1).optional(),precedence:N.string().min(1).optional(),inReplyTo:N.string().min(1).optional(),references:N.array(N.string().min(1)).optional()}),sender:ux.optional()});b$();var xx=N.strictObject({permissionLevel:N.enum(["admin","trusted","public"])}),fx=N.custom(($)=>typeof AbortSignal<"u"&&$ instanceof AbortSignal),yx=N.strictObject({sourceRef:N.string().regex(/^imap:[a-f0-9]{64}$/),actor:xx,signal:fx.optional()}),p7=N.strictObject({name:N.string().trim().min(1).max(300).optional(),address:N.email().max(320)}),mx=N.strictObject({messageId:N.string().trim().min(1).max(2000),from:p7,replyTo:p7.optional(),to:N.array(p7).max(100),subject:N.string().max(1000),receivedAt:N.iso.datetime(),text:N.string().max(1e5),inReplyTo:N.string().trim().min(1).max(2000).optional(),references:N.array(N.string().trim().min(1).max(2000)).max(100),truncated:N.boolean()}),hx=N.discriminatedUnion("kind",[N.strictObject({kind:N.literal("available"),message:mx}),N.strictObject({kind:N.literal("unavailable")})]);b$();var rx=N.object({url:N.string(),authToken:N.string().optional()});b$();var lx=N.object({success:N.boolean(),entityId:N.string().optional(),error:N.string().optional()});b$();var ix=N.enum(["user","assistant"]);b$();var Pg=N.object({entityType:N.string().min(1),entityId:N.string().min(1),contentHash:N.string().min(1).optional()}),px=N.object({rootJobId:N.string().min(1),causationId:N.string().min(1),projectionId:N.string().min(1).optional(),projectionLineage:N.array(N.string().min(1)),sourceEntity:Pg.optional(),derivationDepth:N.number().int().nonnegative()}).superRefine(($,U)=>{if($.derivationDepth!==$.projectionLineage.length)U.addIssue({code:"custom",path:["derivationDepth"],message:"Derivation depth must equal projection lineage length"});let J=$.projectionLineage.at(-1);if($.projectionId!==J)U.addIssue({code:"custom",path:["projectionId"],message:"Current projection must equal the final projection lineage entry"})});b$();var dx=N.strictObject({waveId:N.string().trim().min(1),sourceTypes:N.array(N.string().trim().min(1)),changedTargetTypes:N.array(N.string().trim().min(1))});var fi=nY(lP(),1);class iP extends Error{name="Assertion";code="ERR_ASSERTION";constructor($,U,J,G,q){super($);if(Error.captureStackTrace)Error.captureStackTrace(this,this.constructor);this.actual=U,this.expected=J,this.generated=q,this.operator=G}}function k($,U){oh(Boolean($),!1,!0,"ok","Expected value to be truthy",U)}function oh($,U,J,G,q,I){if(!$)throw I instanceof Error?I:new iP(I||q,U,J,G,!I)}var ah={};function eq($,U){let J=U||ah,G=typeof J.includeImageAlt==="boolean"?J.includeImageAlt:!0,q=typeof J.includeHtml==="boolean"?J.includeHtml:!0;return dP($,G,q)}function dP($,U,J){if(sh($)){if("value"in $)return $.type==="html"&&!J?"":$.value;if(U&&"alt"in $&&$.alt)return $.alt;if("children"in $)return pP($.children,U,J)}if(Array.isArray($))return pP($,U,J);return""}function pP($,U,J){let G=[],q=-1;while(++q<$.length)G[q]=dP($[q],U,J);return G.join("")}function sh($){return Boolean($&&typeof $==="object")}var ZN={AElig:"\xC6",AMP:"&",Aacute:"\xC1",Abreve:"\u0102",Acirc:"\xC2",Acy:"\u0410",Afr:"\uD835\uDD04",Agrave:"\xC0",Alpha:"\u0391",Amacr:"\u0100",And:"\u2A53",Aogon:"\u0104",Aopf:"\uD835\uDD38",ApplyFunction:"\u2061",Aring:"\xC5",Ascr:"\uD835\uDC9C",Assign:"\u2254",Atilde:"\xC3",Auml:"\xC4",Backslash:"\u2216",Barv:"\u2AE7",Barwed:"\u2306",Bcy:"\u0411",Because:"\u2235",Bernoullis:"\u212C",Beta:"\u0392",Bfr:"\uD835\uDD05",Bopf:"\uD835\uDD39",Breve:"\u02D8",Bscr:"\u212C",Bumpeq:"\u224E",CHcy:"\u0427",COPY:"\xA9",Cacute:"\u0106",Cap:"\u22D2",CapitalDifferentialD:"\u2145",Cayleys:"\u212D",Ccaron:"\u010C",Ccedil:"\xC7",Ccirc:"\u0108",Cconint:"\u2230",Cdot:"\u010A",Cedilla:"\xB8",CenterDot:"\xB7",Cfr:"\u212D",Chi:"\u03A7",CircleDot:"\u2299",CircleMinus:"\u2296",CirclePlus:"\u2295",CircleTimes:"\u2297",ClockwiseContourIntegral:"\u2232",CloseCurlyDoubleQuote:"\u201D",CloseCurlyQuote:"\u2019",Colon:"\u2237",Colone:"\u2A74",Congruent:"\u2261",Conint:"\u222F",ContourIntegral:"\u222E",Copf:"\u2102",Coproduct:"\u2210",CounterClockwiseContourIntegral:"\u2233",Cross:"\u2A2F",Cscr:"\uD835\uDC9E",Cup:"\u22D3",CupCap:"\u224D",DD:"\u2145",DDotrahd:"\u2911",DJcy:"\u0402",DScy:"\u0405",DZcy:"\u040F",Dagger:"\u2021",Darr:"\u21A1",Dashv:"\u2AE4",Dcaron:"\u010E",Dcy:"\u0414",Del:"\u2207",Delta:"\u0394",Dfr:"\uD835\uDD07",DiacriticalAcute:"\xB4",DiacriticalDot:"\u02D9",DiacriticalDoubleAcute:"\u02DD",DiacriticalGrave:"`",DiacriticalTilde:"\u02DC",Diamond:"\u22C4",DifferentialD:"\u2146",Dopf:"\uD835\uDD3B",Dot:"\xA8",DotDot:"\u20DC",DotEqual:"\u2250",DoubleContourIntegral:"\u222F",DoubleDot:"\xA8",DoubleDownArrow:"\u21D3",DoubleLeftArrow:"\u21D0",DoubleLeftRightArrow:"\u21D4",DoubleLeftTee:"\u2AE4",DoubleLongLeftArrow:"\u27F8",DoubleLongLeftRightArrow:"\u27FA",DoubleLongRightArrow:"\u27F9",DoubleRightArrow:"\u21D2",DoubleRightTee:"\u22A8",DoubleUpArrow:"\u21D1",DoubleUpDownArrow:"\u21D5",DoubleVerticalBar:"\u2225",DownArrow:"\u2193",DownArrowBar:"\u2913",DownArrowUpArrow:"\u21F5",DownBreve:"\u0311",DownLeftRightVector:"\u2950",DownLeftTeeVector:"\u295E",DownLeftVector:"\u21BD",DownLeftVectorBar:"\u2956",DownRightTeeVector:"\u295F",DownRightVector:"\u21C1",DownRightVectorBar:"\u2957",DownTee:"\u22A4",DownTeeArrow:"\u21A7",Downarrow:"\u21D3",Dscr:"\uD835\uDC9F",Dstrok:"\u0110",ENG:"\u014A",ETH:"\xD0",Eacute:"\xC9",Ecaron:"\u011A",Ecirc:"\xCA",Ecy:"\u042D",Edot:"\u0116",Efr:"\uD835\uDD08",Egrave:"\xC8",Element:"\u2208",Emacr:"\u0112",EmptySmallSquare:"\u25FB",EmptyVerySmallSquare:"\u25AB",Eogon:"\u0118",Eopf:"\uD835\uDD3C",Epsilon:"\u0395",Equal:"\u2A75",EqualTilde:"\u2242",Equilibrium:"\u21CC",Escr:"\u2130",Esim:"\u2A73",Eta:"\u0397",Euml:"\xCB",Exists:"\u2203",ExponentialE:"\u2147",Fcy:"\u0424",Ffr:"\uD835\uDD09",FilledSmallSquare:"\u25FC",FilledVerySmallSquare:"\u25AA",Fopf:"\uD835\uDD3D",ForAll:"\u2200",Fouriertrf:"\u2131",Fscr:"\u2131",GJcy:"\u0403",GT:">",Gamma:"\u0393",Gammad:"\u03DC",Gbreve:"\u011E",Gcedil:"\u0122",Gcirc:"\u011C",Gcy:"\u0413",Gdot:"\u0120",Gfr:"\uD835\uDD0A",Gg:"\u22D9",Gopf:"\uD835\uDD3E",GreaterEqual:"\u2265",GreaterEqualLess:"\u22DB",GreaterFullEqual:"\u2267",GreaterGreater:"\u2AA2",GreaterLess:"\u2277",GreaterSlantEqual:"\u2A7E",GreaterTilde:"\u2273",Gscr:"\uD835\uDCA2",Gt:"\u226B",HARDcy:"\u042A",Hacek:"\u02C7",Hat:"^",Hcirc:"\u0124",Hfr:"\u210C",HilbertSpace:"\u210B",Hopf:"\u210D",HorizontalLine:"\u2500",Hscr:"\u210B",Hstrok:"\u0126",HumpDownHump:"\u224E",HumpEqual:"\u224F",IEcy:"\u0415",IJlig:"\u0132",IOcy:"\u0401",Iacute:"\xCD",Icirc:"\xCE",Icy:"\u0418",Idot:"\u0130",Ifr:"\u2111",Igrave:"\xCC",Im:"\u2111",Imacr:"\u012A",ImaginaryI:"\u2148",Implies:"\u21D2",Int:"\u222C",Integral:"\u222B",Intersection:"\u22C2",InvisibleComma:"\u2063",InvisibleTimes:"\u2062",Iogon:"\u012E",Iopf:"\uD835\uDD40",Iota:"\u0399",Iscr:"\u2110",Itilde:"\u0128",Iukcy:"\u0406",Iuml:"\xCF",Jcirc:"\u0134",Jcy:"\u0419",Jfr:"\uD835\uDD0D",Jopf:"\uD835\uDD41",Jscr:"\uD835\uDCA5",Jsercy:"\u0408",Jukcy:"\u0404",KHcy:"\u0425",KJcy:"\u040C",Kappa:"\u039A",Kcedil:"\u0136",Kcy:"\u041A",Kfr:"\uD835\uDD0E",Kopf:"\uD835\uDD42",Kscr:"\uD835\uDCA6",LJcy:"\u0409",LT:"<",Lacute:"\u0139",Lambda:"\u039B",Lang:"\u27EA",Laplacetrf:"\u2112",Larr:"\u219E",Lcaron:"\u013D",Lcedil:"\u013B",Lcy:"\u041B",LeftAngleBracket:"\u27E8",LeftArrow:"\u2190",LeftArrowBar:"\u21E4",LeftArrowRightArrow:"\u21C6",LeftCeiling:"\u2308",LeftDoubleBracket:"\u27E6",LeftDownTeeVector:"\u2961",LeftDownVector:"\u21C3",LeftDownVectorBar:"\u2959",LeftFloor:"\u230A",LeftRightArrow:"\u2194",LeftRightVector:"\u294E",LeftTee:"\u22A3",LeftTeeArrow:"\u21A4",LeftTeeVector:"\u295A",LeftTriangle:"\u22B2",LeftTriangleBar:"\u29CF",LeftTriangleEqual:"\u22B4",LeftUpDownVector:"\u2951",LeftUpTeeVector:"\u2960",LeftUpVector:"\u21BF",LeftUpVectorBar:"\u2958",LeftVector:"\u21BC",LeftVectorBar:"\u2952",Leftarrow:"\u21D0",Leftrightarrow:"\u21D4",LessEqualGreater:"\u22DA",LessFullEqual:"\u2266",LessGreater:"\u2276",LessLess:"\u2AA1",LessSlantEqual:"\u2A7D",LessTilde:"\u2272",Lfr:"\uD835\uDD0F",Ll:"\u22D8",Lleftarrow:"\u21DA",Lmidot:"\u013F",LongLeftArrow:"\u27F5",LongLeftRightArrow:"\u27F7",LongRightArrow:"\u27F6",Longleftarrow:"\u27F8",Longleftrightarrow:"\u27FA",Longrightarrow:"\u27F9",Lopf:"\uD835\uDD43",LowerLeftArrow:"\u2199",LowerRightArrow:"\u2198",Lscr:"\u2112",Lsh:"\u21B0",Lstrok:"\u0141",Lt:"\u226A",Map:"\u2905",Mcy:"\u041C",MediumSpace:"\u205F",Mellintrf:"\u2133",Mfr:"\uD835\uDD10",MinusPlus:"\u2213",Mopf:"\uD835\uDD44",Mscr:"\u2133",Mu:"\u039C",NJcy:"\u040A",Nacute:"\u0143",Ncaron:"\u0147",Ncedil:"\u0145",Ncy:"\u041D",NegativeMediumSpace:"\u200B",NegativeThickSpace:"\u200B",NegativeThinSpace:"\u200B",NegativeVeryThinSpace:"\u200B",NestedGreaterGreater:"\u226B",NestedLessLess:"\u226A",NewLine:`
|
|
481
|
+
`,Nfr:"\uD835\uDD11",NoBreak:"\u2060",NonBreakingSpace:"\xA0",Nopf:"\u2115",Not:"\u2AEC",NotCongruent:"\u2262",NotCupCap:"\u226D",NotDoubleVerticalBar:"\u2226",NotElement:"\u2209",NotEqual:"\u2260",NotEqualTilde:"\u2242\u0338",NotExists:"\u2204",NotGreater:"\u226F",NotGreaterEqual:"\u2271",NotGreaterFullEqual:"\u2267\u0338",NotGreaterGreater:"\u226B\u0338",NotGreaterLess:"\u2279",NotGreaterSlantEqual:"\u2A7E\u0338",NotGreaterTilde:"\u2275",NotHumpDownHump:"\u224E\u0338",NotHumpEqual:"\u224F\u0338",NotLeftTriangle:"\u22EA",NotLeftTriangleBar:"\u29CF\u0338",NotLeftTriangleEqual:"\u22EC",NotLess:"\u226E",NotLessEqual:"\u2270",NotLessGreater:"\u2278",NotLessLess:"\u226A\u0338",NotLessSlantEqual:"\u2A7D\u0338",NotLessTilde:"\u2274",NotNestedGreaterGreater:"\u2AA2\u0338",NotNestedLessLess:"\u2AA1\u0338",NotPrecedes:"\u2280",NotPrecedesEqual:"\u2AAF\u0338",NotPrecedesSlantEqual:"\u22E0",NotReverseElement:"\u220C",NotRightTriangle:"\u22EB",NotRightTriangleBar:"\u29D0\u0338",NotRightTriangleEqual:"\u22ED",NotSquareSubset:"\u228F\u0338",NotSquareSubsetEqual:"\u22E2",NotSquareSuperset:"\u2290\u0338",NotSquareSupersetEqual:"\u22E3",NotSubset:"\u2282\u20D2",NotSubsetEqual:"\u2288",NotSucceeds:"\u2281",NotSucceedsEqual:"\u2AB0\u0338",NotSucceedsSlantEqual:"\u22E1",NotSucceedsTilde:"\u227F\u0338",NotSuperset:"\u2283\u20D2",NotSupersetEqual:"\u2289",NotTilde:"\u2241",NotTildeEqual:"\u2244",NotTildeFullEqual:"\u2247",NotTildeTilde:"\u2249",NotVerticalBar:"\u2224",Nscr:"\uD835\uDCA9",Ntilde:"\xD1",Nu:"\u039D",OElig:"\u0152",Oacute:"\xD3",Ocirc:"\xD4",Ocy:"\u041E",Odblac:"\u0150",Ofr:"\uD835\uDD12",Ograve:"\xD2",Omacr:"\u014C",Omega:"\u03A9",Omicron:"\u039F",Oopf:"\uD835\uDD46",OpenCurlyDoubleQuote:"\u201C",OpenCurlyQuote:"\u2018",Or:"\u2A54",Oscr:"\uD835\uDCAA",Oslash:"\xD8",Otilde:"\xD5",Otimes:"\u2A37",Ouml:"\xD6",OverBar:"\u203E",OverBrace:"\u23DE",OverBracket:"\u23B4",OverParenthesis:"\u23DC",PartialD:"\u2202",Pcy:"\u041F",Pfr:"\uD835\uDD13",Phi:"\u03A6",Pi:"\u03A0",PlusMinus:"\xB1",Poincareplane:"\u210C",Popf:"\u2119",Pr:"\u2ABB",Precedes:"\u227A",PrecedesEqual:"\u2AAF",PrecedesSlantEqual:"\u227C",PrecedesTilde:"\u227E",Prime:"\u2033",Product:"\u220F",Proportion:"\u2237",Proportional:"\u221D",Pscr:"\uD835\uDCAB",Psi:"\u03A8",QUOT:'"',Qfr:"\uD835\uDD14",Qopf:"\u211A",Qscr:"\uD835\uDCAC",RBarr:"\u2910",REG:"\xAE",Racute:"\u0154",Rang:"\u27EB",Rarr:"\u21A0",Rarrtl:"\u2916",Rcaron:"\u0158",Rcedil:"\u0156",Rcy:"\u0420",Re:"\u211C",ReverseElement:"\u220B",ReverseEquilibrium:"\u21CB",ReverseUpEquilibrium:"\u296F",Rfr:"\u211C",Rho:"\u03A1",RightAngleBracket:"\u27E9",RightArrow:"\u2192",RightArrowBar:"\u21E5",RightArrowLeftArrow:"\u21C4",RightCeiling:"\u2309",RightDoubleBracket:"\u27E7",RightDownTeeVector:"\u295D",RightDownVector:"\u21C2",RightDownVectorBar:"\u2955",RightFloor:"\u230B",RightTee:"\u22A2",RightTeeArrow:"\u21A6",RightTeeVector:"\u295B",RightTriangle:"\u22B3",RightTriangleBar:"\u29D0",RightTriangleEqual:"\u22B5",RightUpDownVector:"\u294F",RightUpTeeVector:"\u295C",RightUpVector:"\u21BE",RightUpVectorBar:"\u2954",RightVector:"\u21C0",RightVectorBar:"\u2953",Rightarrow:"\u21D2",Ropf:"\u211D",RoundImplies:"\u2970",Rrightarrow:"\u21DB",Rscr:"\u211B",Rsh:"\u21B1",RuleDelayed:"\u29F4",SHCHcy:"\u0429",SHcy:"\u0428",SOFTcy:"\u042C",Sacute:"\u015A",Sc:"\u2ABC",Scaron:"\u0160",Scedil:"\u015E",Scirc:"\u015C",Scy:"\u0421",Sfr:"\uD835\uDD16",ShortDownArrow:"\u2193",ShortLeftArrow:"\u2190",ShortRightArrow:"\u2192",ShortUpArrow:"\u2191",Sigma:"\u03A3",SmallCircle:"\u2218",Sopf:"\uD835\uDD4A",Sqrt:"\u221A",Square:"\u25A1",SquareIntersection:"\u2293",SquareSubset:"\u228F",SquareSubsetEqual:"\u2291",SquareSuperset:"\u2290",SquareSupersetEqual:"\u2292",SquareUnion:"\u2294",Sscr:"\uD835\uDCAE",Star:"\u22C6",Sub:"\u22D0",Subset:"\u22D0",SubsetEqual:"\u2286",Succeeds:"\u227B",SucceedsEqual:"\u2AB0",SucceedsSlantEqual:"\u227D",SucceedsTilde:"\u227F",SuchThat:"\u220B",Sum:"\u2211",Sup:"\u22D1",Superset:"\u2283",SupersetEqual:"\u2287",Supset:"\u22D1",THORN:"\xDE",TRADE:"\u2122",TSHcy:"\u040B",TScy:"\u0426",Tab:"\t",Tau:"\u03A4",Tcaron:"\u0164",Tcedil:"\u0162",Tcy:"\u0422",Tfr:"\uD835\uDD17",Therefore:"\u2234",Theta:"\u0398",ThickSpace:"\u205F\u200A",ThinSpace:"\u2009",Tilde:"\u223C",TildeEqual:"\u2243",TildeFullEqual:"\u2245",TildeTilde:"\u2248",Topf:"\uD835\uDD4B",TripleDot:"\u20DB",Tscr:"\uD835\uDCAF",Tstrok:"\u0166",Uacute:"\xDA",Uarr:"\u219F",Uarrocir:"\u2949",Ubrcy:"\u040E",Ubreve:"\u016C",Ucirc:"\xDB",Ucy:"\u0423",Udblac:"\u0170",Ufr:"\uD835\uDD18",Ugrave:"\xD9",Umacr:"\u016A",UnderBar:"_",UnderBrace:"\u23DF",UnderBracket:"\u23B5",UnderParenthesis:"\u23DD",Union:"\u22C3",UnionPlus:"\u228E",Uogon:"\u0172",Uopf:"\uD835\uDD4C",UpArrow:"\u2191",UpArrowBar:"\u2912",UpArrowDownArrow:"\u21C5",UpDownArrow:"\u2195",UpEquilibrium:"\u296E",UpTee:"\u22A5",UpTeeArrow:"\u21A5",Uparrow:"\u21D1",Updownarrow:"\u21D5",UpperLeftArrow:"\u2196",UpperRightArrow:"\u2197",Upsi:"\u03D2",Upsilon:"\u03A5",Uring:"\u016E",Uscr:"\uD835\uDCB0",Utilde:"\u0168",Uuml:"\xDC",VDash:"\u22AB",Vbar:"\u2AEB",Vcy:"\u0412",Vdash:"\u22A9",Vdashl:"\u2AE6",Vee:"\u22C1",Verbar:"\u2016",Vert:"\u2016",VerticalBar:"\u2223",VerticalLine:"|",VerticalSeparator:"\u2758",VerticalTilde:"\u2240",VeryThinSpace:"\u200A",Vfr:"\uD835\uDD19",Vopf:"\uD835\uDD4D",Vscr:"\uD835\uDCB1",Vvdash:"\u22AA",Wcirc:"\u0174",Wedge:"\u22C0",Wfr:"\uD835\uDD1A",Wopf:"\uD835\uDD4E",Wscr:"\uD835\uDCB2",Xfr:"\uD835\uDD1B",Xi:"\u039E",Xopf:"\uD835\uDD4F",Xscr:"\uD835\uDCB3",YAcy:"\u042F",YIcy:"\u0407",YUcy:"\u042E",Yacute:"\xDD",Ycirc:"\u0176",Ycy:"\u042B",Yfr:"\uD835\uDD1C",Yopf:"\uD835\uDD50",Yscr:"\uD835\uDCB4",Yuml:"\u0178",ZHcy:"\u0416",Zacute:"\u0179",Zcaron:"\u017D",Zcy:"\u0417",Zdot:"\u017B",ZeroWidthSpace:"\u200B",Zeta:"\u0396",Zfr:"\u2128",Zopf:"\u2124",Zscr:"\uD835\uDCB5",aacute:"\xE1",abreve:"\u0103",ac:"\u223E",acE:"\u223E\u0333",acd:"\u223F",acirc:"\xE2",acute:"\xB4",acy:"\u0430",aelig:"\xE6",af:"\u2061",afr:"\uD835\uDD1E",agrave:"\xE0",alefsym:"\u2135",aleph:"\u2135",alpha:"\u03B1",amacr:"\u0101",amalg:"\u2A3F",amp:"&",and:"\u2227",andand:"\u2A55",andd:"\u2A5C",andslope:"\u2A58",andv:"\u2A5A",ang:"\u2220",ange:"\u29A4",angle:"\u2220",angmsd:"\u2221",angmsdaa:"\u29A8",angmsdab:"\u29A9",angmsdac:"\u29AA",angmsdad:"\u29AB",angmsdae:"\u29AC",angmsdaf:"\u29AD",angmsdag:"\u29AE",angmsdah:"\u29AF",angrt:"\u221F",angrtvb:"\u22BE",angrtvbd:"\u299D",angsph:"\u2222",angst:"\xC5",angzarr:"\u237C",aogon:"\u0105",aopf:"\uD835\uDD52",ap:"\u2248",apE:"\u2A70",apacir:"\u2A6F",ape:"\u224A",apid:"\u224B",apos:"'",approx:"\u2248",approxeq:"\u224A",aring:"\xE5",ascr:"\uD835\uDCB6",ast:"*",asymp:"\u2248",asympeq:"\u224D",atilde:"\xE3",auml:"\xE4",awconint:"\u2233",awint:"\u2A11",bNot:"\u2AED",backcong:"\u224C",backepsilon:"\u03F6",backprime:"\u2035",backsim:"\u223D",backsimeq:"\u22CD",barvee:"\u22BD",barwed:"\u2305",barwedge:"\u2305",bbrk:"\u23B5",bbrktbrk:"\u23B6",bcong:"\u224C",bcy:"\u0431",bdquo:"\u201E",becaus:"\u2235",because:"\u2235",bemptyv:"\u29B0",bepsi:"\u03F6",bernou:"\u212C",beta:"\u03B2",beth:"\u2136",between:"\u226C",bfr:"\uD835\uDD1F",bigcap:"\u22C2",bigcirc:"\u25EF",bigcup:"\u22C3",bigodot:"\u2A00",bigoplus:"\u2A01",bigotimes:"\u2A02",bigsqcup:"\u2A06",bigstar:"\u2605",bigtriangledown:"\u25BD",bigtriangleup:"\u25B3",biguplus:"\u2A04",bigvee:"\u22C1",bigwedge:"\u22C0",bkarow:"\u290D",blacklozenge:"\u29EB",blacksquare:"\u25AA",blacktriangle:"\u25B4",blacktriangledown:"\u25BE",blacktriangleleft:"\u25C2",blacktriangleright:"\u25B8",blank:"\u2423",blk12:"\u2592",blk14:"\u2591",blk34:"\u2593",block:"\u2588",bne:"=\u20E5",bnequiv:"\u2261\u20E5",bnot:"\u2310",bopf:"\uD835\uDD53",bot:"\u22A5",bottom:"\u22A5",bowtie:"\u22C8",boxDL:"\u2557",boxDR:"\u2554",boxDl:"\u2556",boxDr:"\u2553",boxH:"\u2550",boxHD:"\u2566",boxHU:"\u2569",boxHd:"\u2564",boxHu:"\u2567",boxUL:"\u255D",boxUR:"\u255A",boxUl:"\u255C",boxUr:"\u2559",boxV:"\u2551",boxVH:"\u256C",boxVL:"\u2563",boxVR:"\u2560",boxVh:"\u256B",boxVl:"\u2562",boxVr:"\u255F",boxbox:"\u29C9",boxdL:"\u2555",boxdR:"\u2552",boxdl:"\u2510",boxdr:"\u250C",boxh:"\u2500",boxhD:"\u2565",boxhU:"\u2568",boxhd:"\u252C",boxhu:"\u2534",boxminus:"\u229F",boxplus:"\u229E",boxtimes:"\u22A0",boxuL:"\u255B",boxuR:"\u2558",boxul:"\u2518",boxur:"\u2514",boxv:"\u2502",boxvH:"\u256A",boxvL:"\u2561",boxvR:"\u255E",boxvh:"\u253C",boxvl:"\u2524",boxvr:"\u251C",bprime:"\u2035",breve:"\u02D8",brvbar:"\xA6",bscr:"\uD835\uDCB7",bsemi:"\u204F",bsim:"\u223D",bsime:"\u22CD",bsol:"\\",bsolb:"\u29C5",bsolhsub:"\u27C8",bull:"\u2022",bullet:"\u2022",bump:"\u224E",bumpE:"\u2AAE",bumpe:"\u224F",bumpeq:"\u224F",cacute:"\u0107",cap:"\u2229",capand:"\u2A44",capbrcup:"\u2A49",capcap:"\u2A4B",capcup:"\u2A47",capdot:"\u2A40",caps:"\u2229\uFE00",caret:"\u2041",caron:"\u02C7",ccaps:"\u2A4D",ccaron:"\u010D",ccedil:"\xE7",ccirc:"\u0109",ccups:"\u2A4C",ccupssm:"\u2A50",cdot:"\u010B",cedil:"\xB8",cemptyv:"\u29B2",cent:"\xA2",centerdot:"\xB7",cfr:"\uD835\uDD20",chcy:"\u0447",check:"\u2713",checkmark:"\u2713",chi:"\u03C7",cir:"\u25CB",cirE:"\u29C3",circ:"\u02C6",circeq:"\u2257",circlearrowleft:"\u21BA",circlearrowright:"\u21BB",circledR:"\xAE",circledS:"\u24C8",circledast:"\u229B",circledcirc:"\u229A",circleddash:"\u229D",cire:"\u2257",cirfnint:"\u2A10",cirmid:"\u2AEF",cirscir:"\u29C2",clubs:"\u2663",clubsuit:"\u2663",colon:":",colone:"\u2254",coloneq:"\u2254",comma:",",commat:"@",comp:"\u2201",compfn:"\u2218",complement:"\u2201",complexes:"\u2102",cong:"\u2245",congdot:"\u2A6D",conint:"\u222E",copf:"\uD835\uDD54",coprod:"\u2210",copy:"\xA9",copysr:"\u2117",crarr:"\u21B5",cross:"\u2717",cscr:"\uD835\uDCB8",csub:"\u2ACF",csube:"\u2AD1",csup:"\u2AD0",csupe:"\u2AD2",ctdot:"\u22EF",cudarrl:"\u2938",cudarrr:"\u2935",cuepr:"\u22DE",cuesc:"\u22DF",cularr:"\u21B6",cularrp:"\u293D",cup:"\u222A",cupbrcap:"\u2A48",cupcap:"\u2A46",cupcup:"\u2A4A",cupdot:"\u228D",cupor:"\u2A45",cups:"\u222A\uFE00",curarr:"\u21B7",curarrm:"\u293C",curlyeqprec:"\u22DE",curlyeqsucc:"\u22DF",curlyvee:"\u22CE",curlywedge:"\u22CF",curren:"\xA4",curvearrowleft:"\u21B6",curvearrowright:"\u21B7",cuvee:"\u22CE",cuwed:"\u22CF",cwconint:"\u2232",cwint:"\u2231",cylcty:"\u232D",dArr:"\u21D3",dHar:"\u2965",dagger:"\u2020",daleth:"\u2138",darr:"\u2193",dash:"\u2010",dashv:"\u22A3",dbkarow:"\u290F",dblac:"\u02DD",dcaron:"\u010F",dcy:"\u0434",dd:"\u2146",ddagger:"\u2021",ddarr:"\u21CA",ddotseq:"\u2A77",deg:"\xB0",delta:"\u03B4",demptyv:"\u29B1",dfisht:"\u297F",dfr:"\uD835\uDD21",dharl:"\u21C3",dharr:"\u21C2",diam:"\u22C4",diamond:"\u22C4",diamondsuit:"\u2666",diams:"\u2666",die:"\xA8",digamma:"\u03DD",disin:"\u22F2",div:"\xF7",divide:"\xF7",divideontimes:"\u22C7",divonx:"\u22C7",djcy:"\u0452",dlcorn:"\u231E",dlcrop:"\u230D",dollar:"$",dopf:"\uD835\uDD55",dot:"\u02D9",doteq:"\u2250",doteqdot:"\u2251",dotminus:"\u2238",dotplus:"\u2214",dotsquare:"\u22A1",doublebarwedge:"\u2306",downarrow:"\u2193",downdownarrows:"\u21CA",downharpoonleft:"\u21C3",downharpoonright:"\u21C2",drbkarow:"\u2910",drcorn:"\u231F",drcrop:"\u230C",dscr:"\uD835\uDCB9",dscy:"\u0455",dsol:"\u29F6",dstrok:"\u0111",dtdot:"\u22F1",dtri:"\u25BF",dtrif:"\u25BE",duarr:"\u21F5",duhar:"\u296F",dwangle:"\u29A6",dzcy:"\u045F",dzigrarr:"\u27FF",eDDot:"\u2A77",eDot:"\u2251",eacute:"\xE9",easter:"\u2A6E",ecaron:"\u011B",ecir:"\u2256",ecirc:"\xEA",ecolon:"\u2255",ecy:"\u044D",edot:"\u0117",ee:"\u2147",efDot:"\u2252",efr:"\uD835\uDD22",eg:"\u2A9A",egrave:"\xE8",egs:"\u2A96",egsdot:"\u2A98",el:"\u2A99",elinters:"\u23E7",ell:"\u2113",els:"\u2A95",elsdot:"\u2A97",emacr:"\u0113",empty:"\u2205",emptyset:"\u2205",emptyv:"\u2205",emsp13:"\u2004",emsp14:"\u2005",emsp:"\u2003",eng:"\u014B",ensp:"\u2002",eogon:"\u0119",eopf:"\uD835\uDD56",epar:"\u22D5",eparsl:"\u29E3",eplus:"\u2A71",epsi:"\u03B5",epsilon:"\u03B5",epsiv:"\u03F5",eqcirc:"\u2256",eqcolon:"\u2255",eqsim:"\u2242",eqslantgtr:"\u2A96",eqslantless:"\u2A95",equals:"=",equest:"\u225F",equiv:"\u2261",equivDD:"\u2A78",eqvparsl:"\u29E5",erDot:"\u2253",erarr:"\u2971",escr:"\u212F",esdot:"\u2250",esim:"\u2242",eta:"\u03B7",eth:"\xF0",euml:"\xEB",euro:"\u20AC",excl:"!",exist:"\u2203",expectation:"\u2130",exponentiale:"\u2147",fallingdotseq:"\u2252",fcy:"\u0444",female:"\u2640",ffilig:"\uFB03",fflig:"\uFB00",ffllig:"\uFB04",ffr:"\uD835\uDD23",filig:"\uFB01",fjlig:"fj",flat:"\u266D",fllig:"\uFB02",fltns:"\u25B1",fnof:"\u0192",fopf:"\uD835\uDD57",forall:"\u2200",fork:"\u22D4",forkv:"\u2AD9",fpartint:"\u2A0D",frac12:"\xBD",frac13:"\u2153",frac14:"\xBC",frac15:"\u2155",frac16:"\u2159",frac18:"\u215B",frac23:"\u2154",frac25:"\u2156",frac34:"\xBE",frac35:"\u2157",frac38:"\u215C",frac45:"\u2158",frac56:"\u215A",frac58:"\u215D",frac78:"\u215E",frasl:"\u2044",frown:"\u2322",fscr:"\uD835\uDCBB",gE:"\u2267",gEl:"\u2A8C",gacute:"\u01F5",gamma:"\u03B3",gammad:"\u03DD",gap:"\u2A86",gbreve:"\u011F",gcirc:"\u011D",gcy:"\u0433",gdot:"\u0121",ge:"\u2265",gel:"\u22DB",geq:"\u2265",geqq:"\u2267",geqslant:"\u2A7E",ges:"\u2A7E",gescc:"\u2AA9",gesdot:"\u2A80",gesdoto:"\u2A82",gesdotol:"\u2A84",gesl:"\u22DB\uFE00",gesles:"\u2A94",gfr:"\uD835\uDD24",gg:"\u226B",ggg:"\u22D9",gimel:"\u2137",gjcy:"\u0453",gl:"\u2277",glE:"\u2A92",gla:"\u2AA5",glj:"\u2AA4",gnE:"\u2269",gnap:"\u2A8A",gnapprox:"\u2A8A",gne:"\u2A88",gneq:"\u2A88",gneqq:"\u2269",gnsim:"\u22E7",gopf:"\uD835\uDD58",grave:"`",gscr:"\u210A",gsim:"\u2273",gsime:"\u2A8E",gsiml:"\u2A90",gt:">",gtcc:"\u2AA7",gtcir:"\u2A7A",gtdot:"\u22D7",gtlPar:"\u2995",gtquest:"\u2A7C",gtrapprox:"\u2A86",gtrarr:"\u2978",gtrdot:"\u22D7",gtreqless:"\u22DB",gtreqqless:"\u2A8C",gtrless:"\u2277",gtrsim:"\u2273",gvertneqq:"\u2269\uFE00",gvnE:"\u2269\uFE00",hArr:"\u21D4",hairsp:"\u200A",half:"\xBD",hamilt:"\u210B",hardcy:"\u044A",harr:"\u2194",harrcir:"\u2948",harrw:"\u21AD",hbar:"\u210F",hcirc:"\u0125",hearts:"\u2665",heartsuit:"\u2665",hellip:"\u2026",hercon:"\u22B9",hfr:"\uD835\uDD25",hksearow:"\u2925",hkswarow:"\u2926",hoarr:"\u21FF",homtht:"\u223B",hookleftarrow:"\u21A9",hookrightarrow:"\u21AA",hopf:"\uD835\uDD59",horbar:"\u2015",hscr:"\uD835\uDCBD",hslash:"\u210F",hstrok:"\u0127",hybull:"\u2043",hyphen:"\u2010",iacute:"\xED",ic:"\u2063",icirc:"\xEE",icy:"\u0438",iecy:"\u0435",iexcl:"\xA1",iff:"\u21D4",ifr:"\uD835\uDD26",igrave:"\xEC",ii:"\u2148",iiiint:"\u2A0C",iiint:"\u222D",iinfin:"\u29DC",iiota:"\u2129",ijlig:"\u0133",imacr:"\u012B",image:"\u2111",imagline:"\u2110",imagpart:"\u2111",imath:"\u0131",imof:"\u22B7",imped:"\u01B5",in:"\u2208",incare:"\u2105",infin:"\u221E",infintie:"\u29DD",inodot:"\u0131",int:"\u222B",intcal:"\u22BA",integers:"\u2124",intercal:"\u22BA",intlarhk:"\u2A17",intprod:"\u2A3C",iocy:"\u0451",iogon:"\u012F",iopf:"\uD835\uDD5A",iota:"\u03B9",iprod:"\u2A3C",iquest:"\xBF",iscr:"\uD835\uDCBE",isin:"\u2208",isinE:"\u22F9",isindot:"\u22F5",isins:"\u22F4",isinsv:"\u22F3",isinv:"\u2208",it:"\u2062",itilde:"\u0129",iukcy:"\u0456",iuml:"\xEF",jcirc:"\u0135",jcy:"\u0439",jfr:"\uD835\uDD27",jmath:"\u0237",jopf:"\uD835\uDD5B",jscr:"\uD835\uDCBF",jsercy:"\u0458",jukcy:"\u0454",kappa:"\u03BA",kappav:"\u03F0",kcedil:"\u0137",kcy:"\u043A",kfr:"\uD835\uDD28",kgreen:"\u0138",khcy:"\u0445",kjcy:"\u045C",kopf:"\uD835\uDD5C",kscr:"\uD835\uDCC0",lAarr:"\u21DA",lArr:"\u21D0",lAtail:"\u291B",lBarr:"\u290E",lE:"\u2266",lEg:"\u2A8B",lHar:"\u2962",lacute:"\u013A",laemptyv:"\u29B4",lagran:"\u2112",lambda:"\u03BB",lang:"\u27E8",langd:"\u2991",langle:"\u27E8",lap:"\u2A85",laquo:"\xAB",larr:"\u2190",larrb:"\u21E4",larrbfs:"\u291F",larrfs:"\u291D",larrhk:"\u21A9",larrlp:"\u21AB",larrpl:"\u2939",larrsim:"\u2973",larrtl:"\u21A2",lat:"\u2AAB",latail:"\u2919",late:"\u2AAD",lates:"\u2AAD\uFE00",lbarr:"\u290C",lbbrk:"\u2772",lbrace:"{",lbrack:"[",lbrke:"\u298B",lbrksld:"\u298F",lbrkslu:"\u298D",lcaron:"\u013E",lcedil:"\u013C",lceil:"\u2308",lcub:"{",lcy:"\u043B",ldca:"\u2936",ldquo:"\u201C",ldquor:"\u201E",ldrdhar:"\u2967",ldrushar:"\u294B",ldsh:"\u21B2",le:"\u2264",leftarrow:"\u2190",leftarrowtail:"\u21A2",leftharpoondown:"\u21BD",leftharpoonup:"\u21BC",leftleftarrows:"\u21C7",leftrightarrow:"\u2194",leftrightarrows:"\u21C6",leftrightharpoons:"\u21CB",leftrightsquigarrow:"\u21AD",leftthreetimes:"\u22CB",leg:"\u22DA",leq:"\u2264",leqq:"\u2266",leqslant:"\u2A7D",les:"\u2A7D",lescc:"\u2AA8",lesdot:"\u2A7F",lesdoto:"\u2A81",lesdotor:"\u2A83",lesg:"\u22DA\uFE00",lesges:"\u2A93",lessapprox:"\u2A85",lessdot:"\u22D6",lesseqgtr:"\u22DA",lesseqqgtr:"\u2A8B",lessgtr:"\u2276",lesssim:"\u2272",lfisht:"\u297C",lfloor:"\u230A",lfr:"\uD835\uDD29",lg:"\u2276",lgE:"\u2A91",lhard:"\u21BD",lharu:"\u21BC",lharul:"\u296A",lhblk:"\u2584",ljcy:"\u0459",ll:"\u226A",llarr:"\u21C7",llcorner:"\u231E",llhard:"\u296B",lltri:"\u25FA",lmidot:"\u0140",lmoust:"\u23B0",lmoustache:"\u23B0",lnE:"\u2268",lnap:"\u2A89",lnapprox:"\u2A89",lne:"\u2A87",lneq:"\u2A87",lneqq:"\u2268",lnsim:"\u22E6",loang:"\u27EC",loarr:"\u21FD",lobrk:"\u27E6",longleftarrow:"\u27F5",longleftrightarrow:"\u27F7",longmapsto:"\u27FC",longrightarrow:"\u27F6",looparrowleft:"\u21AB",looparrowright:"\u21AC",lopar:"\u2985",lopf:"\uD835\uDD5D",loplus:"\u2A2D",lotimes:"\u2A34",lowast:"\u2217",lowbar:"_",loz:"\u25CA",lozenge:"\u25CA",lozf:"\u29EB",lpar:"(",lparlt:"\u2993",lrarr:"\u21C6",lrcorner:"\u231F",lrhar:"\u21CB",lrhard:"\u296D",lrm:"\u200E",lrtri:"\u22BF",lsaquo:"\u2039",lscr:"\uD835\uDCC1",lsh:"\u21B0",lsim:"\u2272",lsime:"\u2A8D",lsimg:"\u2A8F",lsqb:"[",lsquo:"\u2018",lsquor:"\u201A",lstrok:"\u0142",lt:"<",ltcc:"\u2AA6",ltcir:"\u2A79",ltdot:"\u22D6",lthree:"\u22CB",ltimes:"\u22C9",ltlarr:"\u2976",ltquest:"\u2A7B",ltrPar:"\u2996",ltri:"\u25C3",ltrie:"\u22B4",ltrif:"\u25C2",lurdshar:"\u294A",luruhar:"\u2966",lvertneqq:"\u2268\uFE00",lvnE:"\u2268\uFE00",mDDot:"\u223A",macr:"\xAF",male:"\u2642",malt:"\u2720",maltese:"\u2720",map:"\u21A6",mapsto:"\u21A6",mapstodown:"\u21A7",mapstoleft:"\u21A4",mapstoup:"\u21A5",marker:"\u25AE",mcomma:"\u2A29",mcy:"\u043C",mdash:"\u2014",measuredangle:"\u2221",mfr:"\uD835\uDD2A",mho:"\u2127",micro:"\xB5",mid:"\u2223",midast:"*",midcir:"\u2AF0",middot:"\xB7",minus:"\u2212",minusb:"\u229F",minusd:"\u2238",minusdu:"\u2A2A",mlcp:"\u2ADB",mldr:"\u2026",mnplus:"\u2213",models:"\u22A7",mopf:"\uD835\uDD5E",mp:"\u2213",mscr:"\uD835\uDCC2",mstpos:"\u223E",mu:"\u03BC",multimap:"\u22B8",mumap:"\u22B8",nGg:"\u22D9\u0338",nGt:"\u226B\u20D2",nGtv:"\u226B\u0338",nLeftarrow:"\u21CD",nLeftrightarrow:"\u21CE",nLl:"\u22D8\u0338",nLt:"\u226A\u20D2",nLtv:"\u226A\u0338",nRightarrow:"\u21CF",nVDash:"\u22AF",nVdash:"\u22AE",nabla:"\u2207",nacute:"\u0144",nang:"\u2220\u20D2",nap:"\u2249",napE:"\u2A70\u0338",napid:"\u224B\u0338",napos:"\u0149",napprox:"\u2249",natur:"\u266E",natural:"\u266E",naturals:"\u2115",nbsp:"\xA0",nbump:"\u224E\u0338",nbumpe:"\u224F\u0338",ncap:"\u2A43",ncaron:"\u0148",ncedil:"\u0146",ncong:"\u2247",ncongdot:"\u2A6D\u0338",ncup:"\u2A42",ncy:"\u043D",ndash:"\u2013",ne:"\u2260",neArr:"\u21D7",nearhk:"\u2924",nearr:"\u2197",nearrow:"\u2197",nedot:"\u2250\u0338",nequiv:"\u2262",nesear:"\u2928",nesim:"\u2242\u0338",nexist:"\u2204",nexists:"\u2204",nfr:"\uD835\uDD2B",ngE:"\u2267\u0338",nge:"\u2271",ngeq:"\u2271",ngeqq:"\u2267\u0338",ngeqslant:"\u2A7E\u0338",nges:"\u2A7E\u0338",ngsim:"\u2275",ngt:"\u226F",ngtr:"\u226F",nhArr:"\u21CE",nharr:"\u21AE",nhpar:"\u2AF2",ni:"\u220B",nis:"\u22FC",nisd:"\u22FA",niv:"\u220B",njcy:"\u045A",nlArr:"\u21CD",nlE:"\u2266\u0338",nlarr:"\u219A",nldr:"\u2025",nle:"\u2270",nleftarrow:"\u219A",nleftrightarrow:"\u21AE",nleq:"\u2270",nleqq:"\u2266\u0338",nleqslant:"\u2A7D\u0338",nles:"\u2A7D\u0338",nless:"\u226E",nlsim:"\u2274",nlt:"\u226E",nltri:"\u22EA",nltrie:"\u22EC",nmid:"\u2224",nopf:"\uD835\uDD5F",not:"\xAC",notin:"\u2209",notinE:"\u22F9\u0338",notindot:"\u22F5\u0338",notinva:"\u2209",notinvb:"\u22F7",notinvc:"\u22F6",notni:"\u220C",notniva:"\u220C",notnivb:"\u22FE",notnivc:"\u22FD",npar:"\u2226",nparallel:"\u2226",nparsl:"\u2AFD\u20E5",npart:"\u2202\u0338",npolint:"\u2A14",npr:"\u2280",nprcue:"\u22E0",npre:"\u2AAF\u0338",nprec:"\u2280",npreceq:"\u2AAF\u0338",nrArr:"\u21CF",nrarr:"\u219B",nrarrc:"\u2933\u0338",nrarrw:"\u219D\u0338",nrightarrow:"\u219B",nrtri:"\u22EB",nrtrie:"\u22ED",nsc:"\u2281",nsccue:"\u22E1",nsce:"\u2AB0\u0338",nscr:"\uD835\uDCC3",nshortmid:"\u2224",nshortparallel:"\u2226",nsim:"\u2241",nsime:"\u2244",nsimeq:"\u2244",nsmid:"\u2224",nspar:"\u2226",nsqsube:"\u22E2",nsqsupe:"\u22E3",nsub:"\u2284",nsubE:"\u2AC5\u0338",nsube:"\u2288",nsubset:"\u2282\u20D2",nsubseteq:"\u2288",nsubseteqq:"\u2AC5\u0338",nsucc:"\u2281",nsucceq:"\u2AB0\u0338",nsup:"\u2285",nsupE:"\u2AC6\u0338",nsupe:"\u2289",nsupset:"\u2283\u20D2",nsupseteq:"\u2289",nsupseteqq:"\u2AC6\u0338",ntgl:"\u2279",ntilde:"\xF1",ntlg:"\u2278",ntriangleleft:"\u22EA",ntrianglelefteq:"\u22EC",ntriangleright:"\u22EB",ntrianglerighteq:"\u22ED",nu:"\u03BD",num:"#",numero:"\u2116",numsp:"\u2007",nvDash:"\u22AD",nvHarr:"\u2904",nvap:"\u224D\u20D2",nvdash:"\u22AC",nvge:"\u2265\u20D2",nvgt:">\u20D2",nvinfin:"\u29DE",nvlArr:"\u2902",nvle:"\u2264\u20D2",nvlt:"<\u20D2",nvltrie:"\u22B4\u20D2",nvrArr:"\u2903",nvrtrie:"\u22B5\u20D2",nvsim:"\u223C\u20D2",nwArr:"\u21D6",nwarhk:"\u2923",nwarr:"\u2196",nwarrow:"\u2196",nwnear:"\u2927",oS:"\u24C8",oacute:"\xF3",oast:"\u229B",ocir:"\u229A",ocirc:"\xF4",ocy:"\u043E",odash:"\u229D",odblac:"\u0151",odiv:"\u2A38",odot:"\u2299",odsold:"\u29BC",oelig:"\u0153",ofcir:"\u29BF",ofr:"\uD835\uDD2C",ogon:"\u02DB",ograve:"\xF2",ogt:"\u29C1",ohbar:"\u29B5",ohm:"\u03A9",oint:"\u222E",olarr:"\u21BA",olcir:"\u29BE",olcross:"\u29BB",oline:"\u203E",olt:"\u29C0",omacr:"\u014D",omega:"\u03C9",omicron:"\u03BF",omid:"\u29B6",ominus:"\u2296",oopf:"\uD835\uDD60",opar:"\u29B7",operp:"\u29B9",oplus:"\u2295",or:"\u2228",orarr:"\u21BB",ord:"\u2A5D",order:"\u2134",orderof:"\u2134",ordf:"\xAA",ordm:"\xBA",origof:"\u22B6",oror:"\u2A56",orslope:"\u2A57",orv:"\u2A5B",oscr:"\u2134",oslash:"\xF8",osol:"\u2298",otilde:"\xF5",otimes:"\u2297",otimesas:"\u2A36",ouml:"\xF6",ovbar:"\u233D",par:"\u2225",para:"\xB6",parallel:"\u2225",parsim:"\u2AF3",parsl:"\u2AFD",part:"\u2202",pcy:"\u043F",percnt:"%",period:".",permil:"\u2030",perp:"\u22A5",pertenk:"\u2031",pfr:"\uD835\uDD2D",phi:"\u03C6",phiv:"\u03D5",phmmat:"\u2133",phone:"\u260E",pi:"\u03C0",pitchfork:"\u22D4",piv:"\u03D6",planck:"\u210F",planckh:"\u210E",plankv:"\u210F",plus:"+",plusacir:"\u2A23",plusb:"\u229E",pluscir:"\u2A22",plusdo:"\u2214",plusdu:"\u2A25",pluse:"\u2A72",plusmn:"\xB1",plussim:"\u2A26",plustwo:"\u2A27",pm:"\xB1",pointint:"\u2A15",popf:"\uD835\uDD61",pound:"\xA3",pr:"\u227A",prE:"\u2AB3",prap:"\u2AB7",prcue:"\u227C",pre:"\u2AAF",prec:"\u227A",precapprox:"\u2AB7",preccurlyeq:"\u227C",preceq:"\u2AAF",precnapprox:"\u2AB9",precneqq:"\u2AB5",precnsim:"\u22E8",precsim:"\u227E",prime:"\u2032",primes:"\u2119",prnE:"\u2AB5",prnap:"\u2AB9",prnsim:"\u22E8",prod:"\u220F",profalar:"\u232E",profline:"\u2312",profsurf:"\u2313",prop:"\u221D",propto:"\u221D",prsim:"\u227E",prurel:"\u22B0",pscr:"\uD835\uDCC5",psi:"\u03C8",puncsp:"\u2008",qfr:"\uD835\uDD2E",qint:"\u2A0C",qopf:"\uD835\uDD62",qprime:"\u2057",qscr:"\uD835\uDCC6",quaternions:"\u210D",quatint:"\u2A16",quest:"?",questeq:"\u225F",quot:'"',rAarr:"\u21DB",rArr:"\u21D2",rAtail:"\u291C",rBarr:"\u290F",rHar:"\u2964",race:"\u223D\u0331",racute:"\u0155",radic:"\u221A",raemptyv:"\u29B3",rang:"\u27E9",rangd:"\u2992",range:"\u29A5",rangle:"\u27E9",raquo:"\xBB",rarr:"\u2192",rarrap:"\u2975",rarrb:"\u21E5",rarrbfs:"\u2920",rarrc:"\u2933",rarrfs:"\u291E",rarrhk:"\u21AA",rarrlp:"\u21AC",rarrpl:"\u2945",rarrsim:"\u2974",rarrtl:"\u21A3",rarrw:"\u219D",ratail:"\u291A",ratio:"\u2236",rationals:"\u211A",rbarr:"\u290D",rbbrk:"\u2773",rbrace:"}",rbrack:"]",rbrke:"\u298C",rbrksld:"\u298E",rbrkslu:"\u2990",rcaron:"\u0159",rcedil:"\u0157",rceil:"\u2309",rcub:"}",rcy:"\u0440",rdca:"\u2937",rdldhar:"\u2969",rdquo:"\u201D",rdquor:"\u201D",rdsh:"\u21B3",real:"\u211C",realine:"\u211B",realpart:"\u211C",reals:"\u211D",rect:"\u25AD",reg:"\xAE",rfisht:"\u297D",rfloor:"\u230B",rfr:"\uD835\uDD2F",rhard:"\u21C1",rharu:"\u21C0",rharul:"\u296C",rho:"\u03C1",rhov:"\u03F1",rightarrow:"\u2192",rightarrowtail:"\u21A3",rightharpoondown:"\u21C1",rightharpoonup:"\u21C0",rightleftarrows:"\u21C4",rightleftharpoons:"\u21CC",rightrightarrows:"\u21C9",rightsquigarrow:"\u219D",rightthreetimes:"\u22CC",ring:"\u02DA",risingdotseq:"\u2253",rlarr:"\u21C4",rlhar:"\u21CC",rlm:"\u200F",rmoust:"\u23B1",rmoustache:"\u23B1",rnmid:"\u2AEE",roang:"\u27ED",roarr:"\u21FE",robrk:"\u27E7",ropar:"\u2986",ropf:"\uD835\uDD63",roplus:"\u2A2E",rotimes:"\u2A35",rpar:")",rpargt:"\u2994",rppolint:"\u2A12",rrarr:"\u21C9",rsaquo:"\u203A",rscr:"\uD835\uDCC7",rsh:"\u21B1",rsqb:"]",rsquo:"\u2019",rsquor:"\u2019",rthree:"\u22CC",rtimes:"\u22CA",rtri:"\u25B9",rtrie:"\u22B5",rtrif:"\u25B8",rtriltri:"\u29CE",ruluhar:"\u2968",rx:"\u211E",sacute:"\u015B",sbquo:"\u201A",sc:"\u227B",scE:"\u2AB4",scap:"\u2AB8",scaron:"\u0161",sccue:"\u227D",sce:"\u2AB0",scedil:"\u015F",scirc:"\u015D",scnE:"\u2AB6",scnap:"\u2ABA",scnsim:"\u22E9",scpolint:"\u2A13",scsim:"\u227F",scy:"\u0441",sdot:"\u22C5",sdotb:"\u22A1",sdote:"\u2A66",seArr:"\u21D8",searhk:"\u2925",searr:"\u2198",searrow:"\u2198",sect:"\xA7",semi:";",seswar:"\u2929",setminus:"\u2216",setmn:"\u2216",sext:"\u2736",sfr:"\uD835\uDD30",sfrown:"\u2322",sharp:"\u266F",shchcy:"\u0449",shcy:"\u0448",shortmid:"\u2223",shortparallel:"\u2225",shy:"\xAD",sigma:"\u03C3",sigmaf:"\u03C2",sigmav:"\u03C2",sim:"\u223C",simdot:"\u2A6A",sime:"\u2243",simeq:"\u2243",simg:"\u2A9E",simgE:"\u2AA0",siml:"\u2A9D",simlE:"\u2A9F",simne:"\u2246",simplus:"\u2A24",simrarr:"\u2972",slarr:"\u2190",smallsetminus:"\u2216",smashp:"\u2A33",smeparsl:"\u29E4",smid:"\u2223",smile:"\u2323",smt:"\u2AAA",smte:"\u2AAC",smtes:"\u2AAC\uFE00",softcy:"\u044C",sol:"/",solb:"\u29C4",solbar:"\u233F",sopf:"\uD835\uDD64",spades:"\u2660",spadesuit:"\u2660",spar:"\u2225",sqcap:"\u2293",sqcaps:"\u2293\uFE00",sqcup:"\u2294",sqcups:"\u2294\uFE00",sqsub:"\u228F",sqsube:"\u2291",sqsubset:"\u228F",sqsubseteq:"\u2291",sqsup:"\u2290",sqsupe:"\u2292",sqsupset:"\u2290",sqsupseteq:"\u2292",squ:"\u25A1",square:"\u25A1",squarf:"\u25AA",squf:"\u25AA",srarr:"\u2192",sscr:"\uD835\uDCC8",ssetmn:"\u2216",ssmile:"\u2323",sstarf:"\u22C6",star:"\u2606",starf:"\u2605",straightepsilon:"\u03F5",straightphi:"\u03D5",strns:"\xAF",sub:"\u2282",subE:"\u2AC5",subdot:"\u2ABD",sube:"\u2286",subedot:"\u2AC3",submult:"\u2AC1",subnE:"\u2ACB",subne:"\u228A",subplus:"\u2ABF",subrarr:"\u2979",subset:"\u2282",subseteq:"\u2286",subseteqq:"\u2AC5",subsetneq:"\u228A",subsetneqq:"\u2ACB",subsim:"\u2AC7",subsub:"\u2AD5",subsup:"\u2AD3",succ:"\u227B",succapprox:"\u2AB8",succcurlyeq:"\u227D",succeq:"\u2AB0",succnapprox:"\u2ABA",succneqq:"\u2AB6",succnsim:"\u22E9",succsim:"\u227F",sum:"\u2211",sung:"\u266A",sup1:"\xB9",sup2:"\xB2",sup3:"\xB3",sup:"\u2283",supE:"\u2AC6",supdot:"\u2ABE",supdsub:"\u2AD8",supe:"\u2287",supedot:"\u2AC4",suphsol:"\u27C9",suphsub:"\u2AD7",suplarr:"\u297B",supmult:"\u2AC2",supnE:"\u2ACC",supne:"\u228B",supplus:"\u2AC0",supset:"\u2283",supseteq:"\u2287",supseteqq:"\u2AC6",supsetneq:"\u228B",supsetneqq:"\u2ACC",supsim:"\u2AC8",supsub:"\u2AD4",supsup:"\u2AD6",swArr:"\u21D9",swarhk:"\u2926",swarr:"\u2199",swarrow:"\u2199",swnwar:"\u292A",szlig:"\xDF",target:"\u2316",tau:"\u03C4",tbrk:"\u23B4",tcaron:"\u0165",tcedil:"\u0163",tcy:"\u0442",tdot:"\u20DB",telrec:"\u2315",tfr:"\uD835\uDD31",there4:"\u2234",therefore:"\u2234",theta:"\u03B8",thetasym:"\u03D1",thetav:"\u03D1",thickapprox:"\u2248",thicksim:"\u223C",thinsp:"\u2009",thkap:"\u2248",thksim:"\u223C",thorn:"\xFE",tilde:"\u02DC",times:"\xD7",timesb:"\u22A0",timesbar:"\u2A31",timesd:"\u2A30",tint:"\u222D",toea:"\u2928",top:"\u22A4",topbot:"\u2336",topcir:"\u2AF1",topf:"\uD835\uDD65",topfork:"\u2ADA",tosa:"\u2929",tprime:"\u2034",trade:"\u2122",triangle:"\u25B5",triangledown:"\u25BF",triangleleft:"\u25C3",trianglelefteq:"\u22B4",triangleq:"\u225C",triangleright:"\u25B9",trianglerighteq:"\u22B5",tridot:"\u25EC",trie:"\u225C",triminus:"\u2A3A",triplus:"\u2A39",trisb:"\u29CD",tritime:"\u2A3B",trpezium:"\u23E2",tscr:"\uD835\uDCC9",tscy:"\u0446",tshcy:"\u045B",tstrok:"\u0167",twixt:"\u226C",twoheadleftarrow:"\u219E",twoheadrightarrow:"\u21A0",uArr:"\u21D1",uHar:"\u2963",uacute:"\xFA",uarr:"\u2191",ubrcy:"\u045E",ubreve:"\u016D",ucirc:"\xFB",ucy:"\u0443",udarr:"\u21C5",udblac:"\u0171",udhar:"\u296E",ufisht:"\u297E",ufr:"\uD835\uDD32",ugrave:"\xF9",uharl:"\u21BF",uharr:"\u21BE",uhblk:"\u2580",ulcorn:"\u231C",ulcorner:"\u231C",ulcrop:"\u230F",ultri:"\u25F8",umacr:"\u016B",uml:"\xA8",uogon:"\u0173",uopf:"\uD835\uDD66",uparrow:"\u2191",updownarrow:"\u2195",upharpoonleft:"\u21BF",upharpoonright:"\u21BE",uplus:"\u228E",upsi:"\u03C5",upsih:"\u03D2",upsilon:"\u03C5",upuparrows:"\u21C8",urcorn:"\u231D",urcorner:"\u231D",urcrop:"\u230E",uring:"\u016F",urtri:"\u25F9",uscr:"\uD835\uDCCA",utdot:"\u22F0",utilde:"\u0169",utri:"\u25B5",utrif:"\u25B4",uuarr:"\u21C8",uuml:"\xFC",uwangle:"\u29A7",vArr:"\u21D5",vBar:"\u2AE8",vBarv:"\u2AE9",vDash:"\u22A8",vangrt:"\u299C",varepsilon:"\u03F5",varkappa:"\u03F0",varnothing:"\u2205",varphi:"\u03D5",varpi:"\u03D6",varpropto:"\u221D",varr:"\u2195",varrho:"\u03F1",varsigma:"\u03C2",varsubsetneq:"\u228A\uFE00",varsubsetneqq:"\u2ACB\uFE00",varsupsetneq:"\u228B\uFE00",varsupsetneqq:"\u2ACC\uFE00",vartheta:"\u03D1",vartriangleleft:"\u22B2",vartriangleright:"\u22B3",vcy:"\u0432",vdash:"\u22A2",vee:"\u2228",veebar:"\u22BB",veeeq:"\u225A",vellip:"\u22EE",verbar:"|",vert:"|",vfr:"\uD835\uDD33",vltri:"\u22B2",vnsub:"\u2282\u20D2",vnsup:"\u2283\u20D2",vopf:"\uD835\uDD67",vprop:"\u221D",vrtri:"\u22B3",vscr:"\uD835\uDCCB",vsubnE:"\u2ACB\uFE00",vsubne:"\u228A\uFE00",vsupnE:"\u2ACC\uFE00",vsupne:"\u228B\uFE00",vzigzag:"\u299A",wcirc:"\u0175",wedbar:"\u2A5F",wedge:"\u2227",wedgeq:"\u2259",weierp:"\u2118",wfr:"\uD835\uDD34",wopf:"\uD835\uDD68",wp:"\u2118",wr:"\u2240",wreath:"\u2240",wscr:"\uD835\uDCCC",xcap:"\u22C2",xcirc:"\u25EF",xcup:"\u22C3",xdtri:"\u25BD",xfr:"\uD835\uDD35",xhArr:"\u27FA",xharr:"\u27F7",xi:"\u03BE",xlArr:"\u27F8",xlarr:"\u27F5",xmap:"\u27FC",xnis:"\u22FB",xodot:"\u2A00",xopf:"\uD835\uDD69",xoplus:"\u2A01",xotime:"\u2A02",xrArr:"\u27F9",xrarr:"\u27F6",xscr:"\uD835\uDCCD",xsqcup:"\u2A06",xuplus:"\u2A04",xutri:"\u25B3",xvee:"\u22C1",xwedge:"\u22C0",yacute:"\xFD",yacy:"\u044F",ycirc:"\u0177",ycy:"\u044B",yen:"\xA5",yfr:"\uD835\uDD36",yicy:"\u0457",yopf:"\uD835\uDD6A",yscr:"\uD835\uDCCE",yucy:"\u044E",yuml:"\xFF",zacute:"\u017A",zcaron:"\u017E",zcy:"\u0437",zdot:"\u017C",zeetrf:"\u2128",zeta:"\u03B6",zfr:"\uD835\uDD37",zhcy:"\u0436",zigrarr:"\u21DD",zopf:"\uD835\uDD6B",zscr:"\uD835\uDCCF",zwj:"\u200D",zwnj:"\u200C"};var th={}.hasOwnProperty;function k8($){return th.call(ZN,$)?ZN[$]:!1}var z={carriageReturn:-5,lineFeed:-4,carriageReturnLineFeed:-3,horizontalTab:-2,virtualSpace:-1,eof:null,nul:0,soh:1,stx:2,etx:3,eot:4,enq:5,ack:6,bel:7,bs:8,ht:9,lf:10,vt:11,ff:12,cr:13,so:14,si:15,dle:16,dc1:17,dc2:18,dc3:19,dc4:20,nak:21,syn:22,etb:23,can:24,em:25,sub:26,esc:27,fs:28,gs:29,rs:30,us:31,space:32,exclamationMark:33,quotationMark:34,numberSign:35,dollarSign:36,percentSign:37,ampersand:38,apostrophe:39,leftParenthesis:40,rightParenthesis:41,asterisk:42,plusSign:43,comma:44,dash:45,dot:46,slash:47,digit0:48,digit1:49,digit2:50,digit3:51,digit4:52,digit5:53,digit6:54,digit7:55,digit8:56,digit9:57,colon:58,semicolon:59,lessThan:60,equalsTo:61,greaterThan:62,questionMark:63,atSign:64,uppercaseA:65,uppercaseB:66,uppercaseC:67,uppercaseD:68,uppercaseE:69,uppercaseF:70,uppercaseG:71,uppercaseH:72,uppercaseI:73,uppercaseJ:74,uppercaseK:75,uppercaseL:76,uppercaseM:77,uppercaseN:78,uppercaseO:79,uppercaseP:80,uppercaseQ:81,uppercaseR:82,uppercaseS:83,uppercaseT:84,uppercaseU:85,uppercaseV:86,uppercaseW:87,uppercaseX:88,uppercaseY:89,uppercaseZ:90,leftSquareBracket:91,backslash:92,rightSquareBracket:93,caret:94,underscore:95,graveAccent:96,lowercaseA:97,lowercaseB:98,lowercaseC:99,lowercaseD:100,lowercaseE:101,lowercaseF:102,lowercaseG:103,lowercaseH:104,lowercaseI:105,lowercaseJ:106,lowercaseK:107,lowercaseL:108,lowercaseM:109,lowercaseN:110,lowercaseO:111,lowercaseP:112,lowercaseQ:113,lowercaseR:114,lowercaseS:115,lowercaseT:116,lowercaseU:117,lowercaseV:118,lowercaseW:119,lowercaseX:120,lowercaseY:121,lowercaseZ:122,leftCurlyBrace:123,verticalBar:124,rightCurlyBrace:125,tilde:126,del:127,byteOrderMarker:65279,replacementCharacter:65533};var W$={attentionSideAfter:2,attentionSideBefore:1,atxHeadingOpeningFenceSizeMax:6,autolinkDomainSizeMax:63,autolinkSchemeSizeMax:32,cdataOpeningString:"CDATA[",characterGroupPunctuation:2,characterGroupWhitespace:1,characterReferenceDecimalSizeMax:7,characterReferenceHexadecimalSizeMax:6,characterReferenceNamedSizeMax:31,codeFencedSequenceSizeMin:3,contentTypeContent:"content",contentTypeDocument:"document",contentTypeFlow:"flow",contentTypeString:"string",contentTypeText:"text",hardBreakPrefixSizeMin:2,htmlBasic:6,htmlCdata:5,htmlComment:2,htmlComplete:7,htmlDeclaration:4,htmlInstruction:3,htmlRawSizeMax:8,htmlRaw:1,linkResourceDestinationBalanceMax:32,linkReferenceSizeMax:999,listItemValueSizeMax:10,numericBaseDecimal:10,numericBaseHexadecimal:16,tabSize:4,thematicBreakMarkerCountMin:3,v8MaxSafeChunkSize:1e4};var T={data:"data",whitespace:"whitespace",lineEnding:"lineEnding",lineEndingBlank:"lineEndingBlank",linePrefix:"linePrefix",lineSuffix:"lineSuffix",atxHeading:"atxHeading",atxHeadingSequence:"atxHeadingSequence",atxHeadingText:"atxHeadingText",autolink:"autolink",autolinkEmail:"autolinkEmail",autolinkMarker:"autolinkMarker",autolinkProtocol:"autolinkProtocol",characterEscape:"characterEscape",characterEscapeValue:"characterEscapeValue",characterReference:"characterReference",characterReferenceMarker:"characterReferenceMarker",characterReferenceMarkerNumeric:"characterReferenceMarkerNumeric",characterReferenceMarkerHexadecimal:"characterReferenceMarkerHexadecimal",characterReferenceValue:"characterReferenceValue",codeFenced:"codeFenced",codeFencedFence:"codeFencedFence",codeFencedFenceSequence:"codeFencedFenceSequence",codeFencedFenceInfo:"codeFencedFenceInfo",codeFencedFenceMeta:"codeFencedFenceMeta",codeFlowValue:"codeFlowValue",codeIndented:"codeIndented",codeText:"codeText",codeTextData:"codeTextData",codeTextPadding:"codeTextPadding",codeTextSequence:"codeTextSequence",content:"content",definition:"definition",definitionDestination:"definitionDestination",definitionDestinationLiteral:"definitionDestinationLiteral",definitionDestinationLiteralMarker:"definitionDestinationLiteralMarker",definitionDestinationRaw:"definitionDestinationRaw",definitionDestinationString:"definitionDestinationString",definitionLabel:"definitionLabel",definitionLabelMarker:"definitionLabelMarker",definitionLabelString:"definitionLabelString",definitionMarker:"definitionMarker",definitionTitle:"definitionTitle",definitionTitleMarker:"definitionTitleMarker",definitionTitleString:"definitionTitleString",emphasis:"emphasis",emphasisSequence:"emphasisSequence",emphasisText:"emphasisText",escapeMarker:"escapeMarker",hardBreakEscape:"hardBreakEscape",hardBreakTrailing:"hardBreakTrailing",htmlFlow:"htmlFlow",htmlFlowData:"htmlFlowData",htmlText:"htmlText",htmlTextData:"htmlTextData",image:"image",label:"label",labelText:"labelText",labelLink:"labelLink",labelImage:"labelImage",labelMarker:"labelMarker",labelImageMarker:"labelImageMarker",labelEnd:"labelEnd",link:"link",paragraph:"paragraph",reference:"reference",referenceMarker:"referenceMarker",referenceString:"referenceString",resource:"resource",resourceDestination:"resourceDestination",resourceDestinationLiteral:"resourceDestinationLiteral",resourceDestinationLiteralMarker:"resourceDestinationLiteralMarker",resourceDestinationRaw:"resourceDestinationRaw",resourceDestinationString:"resourceDestinationString",resourceMarker:"resourceMarker",resourceTitle:"resourceTitle",resourceTitleMarker:"resourceTitleMarker",resourceTitleString:"resourceTitleString",setextHeading:"setextHeading",setextHeadingText:"setextHeadingText",setextHeadingLine:"setextHeadingLine",setextHeadingLineSequence:"setextHeadingLineSequence",strong:"strong",strongSequence:"strongSequence",strongText:"strongText",thematicBreak:"thematicBreak",thematicBreakSequence:"thematicBreakSequence",blockQuote:"blockQuote",blockQuotePrefix:"blockQuotePrefix",blockQuoteMarker:"blockQuoteMarker",blockQuotePrefixWhitespace:"blockQuotePrefixWhitespace",listOrdered:"listOrdered",listUnordered:"listUnordered",listItemIndent:"listItemIndent",listItemMarker:"listItemMarker",listItemPrefix:"listItemPrefix",listItemPrefixWhitespace:"listItemPrefixWhitespace",listItemValue:"listItemValue",chunkDocument:"chunkDocument",chunkContent:"chunkContent",chunkFlow:"chunkFlow",chunkText:"chunkText",chunkString:"chunkString"};var NU={ht:"\t",lf:`
|
|
482
|
+
`,cr:"\r",space:" ",exclamationMark:"!",quotationMark:'"',numberSign:"#",dollarSign:"$",percentSign:"%",ampersand:"&",apostrophe:"'",leftParenthesis:"(",rightParenthesis:")",asterisk:"*",plusSign:"+",comma:",",dash:"-",dot:".",slash:"/",digit0:"0",digit1:"1",digit2:"2",digit3:"3",digit4:"4",digit5:"5",digit6:"6",digit7:"7",digit8:"8",digit9:"9",colon:":",semicolon:";",lessThan:"<",equalsTo:"=",greaterThan:">",questionMark:"?",atSign:"@",uppercaseA:"A",uppercaseB:"B",uppercaseC:"C",uppercaseD:"D",uppercaseE:"E",uppercaseF:"F",uppercaseG:"G",uppercaseH:"H",uppercaseI:"I",uppercaseJ:"J",uppercaseK:"K",uppercaseL:"L",uppercaseM:"M",uppercaseN:"N",uppercaseO:"O",uppercaseP:"P",uppercaseQ:"Q",uppercaseR:"R",uppercaseS:"S",uppercaseT:"T",uppercaseU:"U",uppercaseV:"V",uppercaseW:"W",uppercaseX:"X",uppercaseY:"Y",uppercaseZ:"Z",leftSquareBracket:"[",backslash:"\\",rightSquareBracket:"]",caret:"^",underscore:"_",graveAccent:"`",lowercaseA:"a",lowercaseB:"b",lowercaseC:"c",lowercaseD:"d",lowercaseE:"e",lowercaseF:"f",lowercaseG:"g",lowercaseH:"h",lowercaseI:"i",lowercaseJ:"j",lowercaseK:"k",lowercaseL:"l",lowercaseM:"m",lowercaseN:"n",lowercaseO:"o",lowercaseP:"p",lowercaseQ:"q",lowercaseR:"r",lowercaseS:"s",lowercaseT:"t",lowercaseU:"u",lowercaseV:"v",lowercaseW:"w",lowercaseX:"x",lowercaseY:"y",lowercaseZ:"z",leftCurlyBrace:"{",verticalBar:"|",rightCurlyBrace:"}",tilde:"~",replacementCharacter:"\uFFFD"};function H0($,U,J,G){let q=$.length,I=0,Q;if(U<0)U=-U>q?0:q+U;else U=U>q?q:U;if(J=J>0?J:0,G.length<W$.v8MaxSafeChunkSize)Q=Array.from(G),Q.unshift(U,J),$.splice(...Q);else{if(J)$.splice(U,J);while(I<G.length)Q=G.slice(I,I+W$.v8MaxSafeChunkSize),Q.unshift(U,0),$.splice(...Q),I+=W$.v8MaxSafeChunkSize,U+=W$.v8MaxSafeChunkSize}}function c0($,U){if($.length>0)return H0($,$.length,0,U),$;return U}var nP={}.hasOwnProperty;function cP($){let U={},J=-1;while(++J<$.length)eh(U,$[J]);return U}function eh($,U){let J;for(J in U){let q=(nP.call($,J)?$[J]:void 0)||($[J]={}),I=U[J],Q;if(I)for(Q in I){if(!nP.call(q,Q))q[Q]=[];let D=I[Q];$r(q[Q],Array.isArray(D)?D:D?[D]:[])}}}function $r($,U){let J=-1,G=[];while(++J<U.length)(U[J].add==="after"?$:G).push(U[J]);H0($,0,0,G)}function wX($,U){let J=Number.parseInt($,U);if(J<z.ht||J===z.vt||J>z.cr&&J<z.space||J>z.tilde&&J<160||J>55295&&J<57344||J>64975&&J<65008||(J&65535)===65535||(J&65535)===65534||J>1114111)return NU.replacementCharacter;return String.fromCodePoint(J)}function wJ($){return $.replace(/[\t\n\r ]+/g,NU.space).replace(/^ | $/g,"").toLowerCase().toUpperCase()}var wU=eJ(/[A-Za-z]/),o0=eJ(/[\dA-Za-z]/),oP=eJ(/[#-'*+\--9=?A-Z^-~]/);function x4($){return $!==null&&($<z.space||$===z.del)}var f4=eJ(/\d/),aP=eJ(/[\dA-Fa-f]/),sP=eJ(/[!-/:-@[-`{-~]/);function N$($){return $!==null&&$<z.horizontalTab}function e$($){return $!==null&&($<z.nul||$===z.space)}function C$($){return $===z.horizontalTab||$===z.virtualSpace||$===z.space}var tP=eJ(/\p{P}|\p{S}/u),eP=eJ(/\s/);function eJ($){return U;function U(J){return J!==null&&J>-1&&$.test(String.fromCharCode(J))}}function _$($,U,J,G){let q=G?G-1:Number.POSITIVE_INFINITY,I=0;return Q;function Q(X){if(C$(X))return $.enter(J),D(X);return U(X)}function D(X){if(C$(X)&&I++<q)return $.consume(X),D;return $.exit(J),U(X)}}var $B={tokenize:Ur};function Ur($){let U=$.attempt(this.parser.constructs.contentInitial,G,q),J;return U;function G(D){if(k(D===z.eof||N$(D),"expected eol or eof"),D===z.eof){$.consume(D);return}return $.enter(T.lineEnding),$.consume(D),$.exit(T.lineEnding),_$($,U,T.linePrefix)}function q(D){return k(D!==z.eof&&!N$(D),"expected anything other than a line ending or EOF"),$.enter(T.paragraph),I(D)}function I(D){let X=$.enter(T.chunkText,{contentType:W$.contentTypeText,previous:J});if(J)J.next=X;return J=X,Q(D)}function Q(D){if(D===z.eof){$.exit(T.chunkText),$.exit(T.paragraph),$.consume(D);return}if(N$(D))return $.consume(D),$.exit(T.chunkText),I;return $.consume(D),Q}}var JB={tokenize:Jr},UB={tokenize:qr};function Jr($){let U=this,J=[],G=0,q,I,Q;return D;function D(C){if(G<J.length){let F=J[G];return U.containerState=F[1],k(F[0].continuation,"expected `continuation` to be defined on container construct"),$.attempt(F[0].continuation,X,Y)(C)}return Y(C)}function X(C){if(k(U.containerState,"expected `containerState` to be defined after continuation"),G++,U.containerState._closeFlow){if(U.containerState._closeFlow=void 0,q)P();let F=U.events.length,f=F,E;while(f--)if(U.events[f][0]==="exit"&&U.events[f][1].type===T.chunkFlow){E=U.events[f][1].end;break}k(E,"could not find previous flow chunk"),g(G);let p=F;while(p<U.events.length)U.events[p][1].end={...E},p++;return H0(U.events,f+1,0,U.events.slice(F)),U.events.length=p,Y(C)}return D(C)}function Y(C){if(G===J.length){if(!q)return O(C);if(q.currentConstruct&&q.currentConstruct.concrete)return M(C);U.interrupt=Boolean(q.currentConstruct&&!q._gfmTableDynamicInterruptHack)}return U.containerState={},$.check(UB,V,W)(C)}function V(C){if(q)P();return g(G),O(C)}function W(C){return U.parser.lazy[U.now().line]=G!==J.length,Q=U.now().offset,M(C)}function O(C){return U.containerState={},$.attempt(UB,Z,M)(C)}function Z(C){return k(U.currentConstruct,"expected `currentConstruct` to be defined on tokenizer"),k(U.containerState,"expected `containerState` to be defined on tokenizer"),G++,J.push([U.currentConstruct,U.containerState]),O(C)}function M(C){if(C===z.eof){if(q)P();g(0),$.consume(C);return}return q=q||U.parser.flow(U.now()),$.enter(T.chunkFlow,{_tokenizer:q,contentType:W$.contentTypeFlow,previous:I}),w(C)}function w(C){if(C===z.eof){H($.exit(T.chunkFlow),!0),g(0),$.consume(C);return}if(N$(C))return $.consume(C),H($.exit(T.chunkFlow)),G=0,U.interrupt=void 0,D;return $.consume(C),w}function H(C,F){k(q,"expected `childFlow` to be defined when continuing");let f=U.sliceStream(C);if(F)f.push(null);if(C.previous=I,I)I.next=C;if(I=C,q.defineSkip(C.start),q.write(f),U.parser.lazy[C.start.line]){let E=q.events.length;while(E--)if(q.events[E][1].start.offset<Q&&(!q.events[E][1].end||q.events[E][1].end.offset>Q))return;let p=U.events.length,b=p,h,s;while(b--)if(U.events[b][0]==="exit"&&U.events[b][1].type===T.chunkFlow){if(h){s=U.events[b][1].end;break}h=!0}k(s,"could not find previous flow chunk"),g(G),E=p;while(E<U.events.length)U.events[E][1].end={...s},E++;H0(U.events,b+1,0,U.events.slice(p)),U.events.length=E}}function g(C){let F=J.length;while(F-- >C){let f=J[F];U.containerState=f[1],k(f[0].exit,"expected `exit` to be defined on container construct"),f[0].exit.call(U,$)}J.length=C}function P(){k(U.containerState,"expected `containerState` to be defined when closing flow"),k(q,"expected `childFlow` to be defined when closing it"),q.write([z.eof]),I=void 0,q=void 0,U.containerState._closeFlow=void 0}}function qr($,U,J){return k(this.parser.constructs.disable.null,"expected `disable.null` to be populated"),_$($,$.attempt(this.parser.constructs.document,U,J),T.linePrefix,this.parser.constructs.disable.null.includes("codeIndented")?void 0:W$.tabSize)}function x8($){if($===z.eof||e$($)||eP($))return W$.characterGroupWhitespace;if(tP($))return W$.characterGroupPunctuation}function f8($,U,J){let G=[],q=-1;while(++q<$.length){let I=$[q].resolveAll;if(I&&!G.includes(I))U=I(U,J),G.push(I)}return U}var y4={name:"attention",resolveAll:Gr,tokenize:Ir};function Gr($,U){let J=-1,G,q,I,Q,D,X,Y,V;while(++J<$.length)if($[J][0]==="enter"&&$[J][1].type==="attentionSequence"&&$[J][1]._close){G=J;while(G--)if($[G][0]==="exit"&&$[G][1].type==="attentionSequence"&&$[G][1]._open&&U.sliceSerialize($[G][1]).charCodeAt(0)===U.sliceSerialize($[J][1]).charCodeAt(0)){if(($[G][1]._close||$[J][1]._open)&&($[J][1].end.offset-$[J][1].start.offset)%3&&!(($[G][1].end.offset-$[G][1].start.offset+$[J][1].end.offset-$[J][1].start.offset)%3))continue;X=$[G][1].end.offset-$[G][1].start.offset>1&&$[J][1].end.offset-$[J][1].start.offset>1?2:1;let W={...$[G][1].end},O={...$[J][1].start};if(qB(W,-X),qB(O,X),Q={type:X>1?T.strongSequence:T.emphasisSequence,start:W,end:{...$[G][1].end}},D={type:X>1?T.strongSequence:T.emphasisSequence,start:{...$[J][1].start},end:O},I={type:X>1?T.strongText:T.emphasisText,start:{...$[G][1].end},end:{...$[J][1].start}},q={type:X>1?T.strong:T.emphasis,start:{...Q.start},end:{...D.end}},$[G][1].end={...Q.start},$[J][1].start={...D.end},Y=[],$[G][1].end.offset-$[G][1].start.offset)Y=c0(Y,[["enter",$[G][1],U],["exit",$[G][1],U]]);if(Y=c0(Y,[["enter",q,U],["enter",Q,U],["exit",Q,U],["enter",I,U]]),k(U.parser.constructs.insideSpan.null,"expected `insideSpan` to be populated"),Y=c0(Y,f8(U.parser.constructs.insideSpan.null,$.slice(G+1,J),U)),Y=c0(Y,[["exit",I,U],["enter",D,U],["exit",D,U],["exit",q,U]]),$[J][1].end.offset-$[J][1].start.offset)V=2,Y=c0(Y,[["enter",$[J][1],U],["exit",$[J][1],U]]);else V=0;H0($,G-1,J-G+3,Y),J=G+Y.length-V-2;break}}J=-1;while(++J<$.length)if($[J][1].type==="attentionSequence")$[J][1].type="data";return $}function Ir($,U){let J=this.parser.constructs.attentionMarkers.null,G=this.previous,q=x8(G),I;return Q;function Q(X){return k(X===z.asterisk||X===z.underscore,"expected asterisk or underscore"),I=X,$.enter("attentionSequence"),D(X)}function D(X){if(X===I)return $.consume(X),D;let Y=$.exit("attentionSequence"),V=x8(X);k(J,"expected `attentionMarkers` to be populated");let W=!V||V===W$.characterGroupPunctuation&&q||J.includes(X),O=!q||q===W$.characterGroupPunctuation&&V||J.includes(G);return Y._open=Boolean(I===z.asterisk?W:W&&(q||!O)),Y._close=Boolean(I===z.asterisk?O:O&&(V||!W)),U(X)}}function qB($,U){$.column+=U,$.offset+=U,$._bufferIndex+=U}var RN={name:"autolink",tokenize:Qr};function Qr($,U,J){let G=0;return q;function q(Z){return k(Z===z.lessThan,"expected `<`"),$.enter(T.autolink),$.enter(T.autolinkMarker),$.consume(Z),$.exit(T.autolinkMarker),$.enter(T.autolinkProtocol),I}function I(Z){if(wU(Z))return $.consume(Z),Q;if(Z===z.atSign)return J(Z);return Y(Z)}function Q(Z){if(Z===z.plusSign||Z===z.dash||Z===z.dot||o0(Z))return G=1,D(Z);return Y(Z)}function D(Z){if(Z===z.colon)return $.consume(Z),G=0,X;if((Z===z.plusSign||Z===z.dash||Z===z.dot||o0(Z))&&G++<W$.autolinkSchemeSizeMax)return $.consume(Z),D;return G=0,Y(Z)}function X(Z){if(Z===z.greaterThan)return $.exit(T.autolinkProtocol),$.enter(T.autolinkMarker),$.consume(Z),$.exit(T.autolinkMarker),$.exit(T.autolink),U;if(Z===z.eof||Z===z.space||Z===z.lessThan||x4(Z))return J(Z);return $.consume(Z),X}function Y(Z){if(Z===z.atSign)return $.consume(Z),V;if(oP(Z))return $.consume(Z),Y;return J(Z)}function V(Z){return o0(Z)?W(Z):J(Z)}function W(Z){if(Z===z.dot)return $.consume(Z),G=0,V;if(Z===z.greaterThan)return $.exit(T.autolinkProtocol).type=T.autolinkEmail,$.enter(T.autolinkMarker),$.consume(Z),$.exit(T.autolinkMarker),$.exit(T.autolink),U;return O(Z)}function O(Z){if((Z===z.dash||o0(Z))&&G++<W$.autolinkDomainSizeMax){let M=Z===z.dash?O:W;return $.consume(Z),M}return J(Z)}}var $q={partial:!0,tokenize:Dr};function Dr($,U,J){return G;function G(I){return C$(I)?_$($,q,T.linePrefix)(I):q(I)}function q(I){return I===z.eof||N$(I)?U(I):J(I)}}var MX={continuation:{tokenize:Yr},exit:Vr,name:"blockQuote",tokenize:Xr};function Xr($,U,J){let G=this;return q;function q(Q){if(Q===z.greaterThan){let D=G.containerState;if(k(D,"expected `containerState` to be defined in container"),!D.open)$.enter(T.blockQuote,{_container:!0}),D.open=!0;return $.enter(T.blockQuotePrefix),$.enter(T.blockQuoteMarker),$.consume(Q),$.exit(T.blockQuoteMarker),I}return J(Q)}function I(Q){if(C$(Q))return $.enter(T.blockQuotePrefixWhitespace),$.consume(Q),$.exit(T.blockQuotePrefixWhitespace),$.exit(T.blockQuotePrefix),U;return $.exit(T.blockQuotePrefix),U(Q)}}function Yr($,U,J){let G=this;return q;function q(Q){if(C$(Q))return k(G.parser.constructs.disable.null,"expected `disable.null` to be populated"),_$($,I,T.linePrefix,G.parser.constructs.disable.null.includes("codeIndented")?void 0:W$.tabSize)(Q);return I(Q)}function I(Q){return $.attempt(MX,U,J)(Q)}}function Vr($){$.exit(T.blockQuote)}var HX={name:"characterEscape",tokenize:Wr};function Wr($,U,J){return G;function G(I){return k(I===z.backslash,"expected `\\`"),$.enter(T.characterEscape),$.enter(T.escapeMarker),$.consume(I),$.exit(T.escapeMarker),q}function q(I){if(sP(I))return $.enter(T.characterEscapeValue),$.consume(I),$.exit(T.characterEscapeValue),$.exit(T.characterEscape),U;return J(I)}}var TX={name:"characterReference",tokenize:Or};function Or($,U,J){let G=this,q=0,I,Q;return D;function D(W){return k(W===z.ampersand,"expected `&`"),$.enter(T.characterReference),$.enter(T.characterReferenceMarker),$.consume(W),$.exit(T.characterReferenceMarker),X}function X(W){if(W===z.numberSign)return $.enter(T.characterReferenceMarkerNumeric),$.consume(W),$.exit(T.characterReferenceMarkerNumeric),Y;return $.enter(T.characterReferenceValue),I=W$.characterReferenceNamedSizeMax,Q=o0,V(W)}function Y(W){if(W===z.uppercaseX||W===z.lowercaseX)return $.enter(T.characterReferenceMarkerHexadecimal),$.consume(W),$.exit(T.characterReferenceMarkerHexadecimal),$.enter(T.characterReferenceValue),I=W$.characterReferenceHexadecimalSizeMax,Q=aP,V;return $.enter(T.characterReferenceValue),I=W$.characterReferenceDecimalSizeMax,Q=f4,V(W)}function V(W){if(W===z.semicolon&&q){let O=$.exit(T.characterReferenceValue);if(Q===o0&&!k8(G.sliceSerialize(O)))return J(W);return $.enter(T.characterReferenceMarker),$.consume(W),$.exit(T.characterReferenceMarker),$.exit(T.characterReference),U}if(Q(W)&&q++<I)return $.consume(W),V;return J(W)}}var GB={partial:!0,tokenize:Rr},zX={concrete:!0,name:"codeFenced",tokenize:Zr};function Zr($,U,J){let G=this,q={partial:!0,tokenize:f},I=0,Q=0,D;return X;function X(E){return Y(E)}function Y(E){k(E===z.graveAccent||E===z.tilde,"expected `` ` `` or `~`");let p=G.events[G.events.length-1];return I=p&&p[1].type===T.linePrefix?p[2].sliceSerialize(p[1],!0).length:0,D=E,$.enter(T.codeFenced),$.enter(T.codeFencedFence),$.enter(T.codeFencedFenceSequence),V(E)}function V(E){if(E===D)return Q++,$.consume(E),V;if(Q<W$.codeFencedSequenceSizeMin)return J(E);return $.exit(T.codeFencedFenceSequence),C$(E)?_$($,W,T.whitespace)(E):W(E)}function W(E){if(E===z.eof||N$(E))return $.exit(T.codeFencedFence),G.interrupt?U(E):$.check(GB,w,F)(E);return $.enter(T.codeFencedFenceInfo),$.enter(T.chunkString,{contentType:W$.contentTypeString}),O(E)}function O(E){if(E===z.eof||N$(E))return $.exit(T.chunkString),$.exit(T.codeFencedFenceInfo),W(E);if(C$(E))return $.exit(T.chunkString),$.exit(T.codeFencedFenceInfo),_$($,Z,T.whitespace)(E);if(E===z.graveAccent&&E===D)return J(E);return $.consume(E),O}function Z(E){if(E===z.eof||N$(E))return W(E);return $.enter(T.codeFencedFenceMeta),$.enter(T.chunkString,{contentType:W$.contentTypeString}),M(E)}function M(E){if(E===z.eof||N$(E))return $.exit(T.chunkString),$.exit(T.codeFencedFenceMeta),W(E);if(E===z.graveAccent&&E===D)return J(E);return $.consume(E),M}function w(E){return k(N$(E),"expected eol"),$.attempt(q,F,H)(E)}function H(E){return k(N$(E),"expected eol"),$.enter(T.lineEnding),$.consume(E),$.exit(T.lineEnding),g}function g(E){return I>0&&C$(E)?_$($,P,T.linePrefix,I+1)(E):P(E)}function P(E){if(E===z.eof||N$(E))return $.check(GB,w,F)(E);return $.enter(T.codeFlowValue),C(E)}function C(E){if(E===z.eof||N$(E))return $.exit(T.codeFlowValue),P(E);return $.consume(E),C}function F(E){return $.exit(T.codeFenced),U(E)}function f(E,p,b){let h=0;return s;function s(L){return k(N$(L),"expected eol"),E.enter(T.lineEnding),E.consume(L),E.exit(T.lineEnding),m}function m(L){return k(G.parser.constructs.disable.null,"expected `disable.null` to be populated"),E.enter(T.codeFencedFence),C$(L)?_$(E,_,T.linePrefix,G.parser.constructs.disable.null.includes("codeIndented")?void 0:W$.tabSize)(L):_(L)}function _(L){if(L===D)return E.enter(T.codeFencedFenceSequence),v(L);return b(L)}function v(L){if(L===D)return h++,E.consume(L),v;if(h>=Q)return E.exit(T.codeFencedFenceSequence),C$(L)?_$(E,j,T.whitespace)(L):j(L);return b(L)}function j(L){if(L===z.eof||N$(L))return E.exit(T.codeFencedFence),p(L);return b(L)}}}function Rr($,U,J){let G=this;return q;function q(Q){if(Q===z.eof)return J(Q);return k(N$(Q),"expected eol"),$.enter(T.lineEnding),$.consume(Q),$.exit(T.lineEnding),I}function I(Q){return G.parser.lazy[G.now().line]?J(Q):U(Q)}}var m4={name:"codeIndented",tokenize:wr},Nr={partial:!0,tokenize:Mr};function wr($,U,J){let G=this;return q;function q(Y){return k(C$(Y)),$.enter(T.codeIndented),_$($,I,T.linePrefix,W$.tabSize+1)(Y)}function I(Y){let V=G.events[G.events.length-1];return V&&V[1].type===T.linePrefix&&V[2].sliceSerialize(V[1],!0).length>=W$.tabSize?Q(Y):J(Y)}function Q(Y){if(Y===z.eof)return X(Y);if(N$(Y))return $.attempt(Nr,Q,X)(Y);return $.enter(T.codeFlowValue),D(Y)}function D(Y){if(Y===z.eof||N$(Y))return $.exit(T.codeFlowValue),Q(Y);return $.consume(Y),D}function X(Y){return $.exit(T.codeIndented),U(Y)}}function Mr($,U,J){let G=this;return q;function q(Q){if(G.parser.lazy[G.now().line])return J(Q);if(N$(Q))return $.enter(T.lineEnding),$.consume(Q),$.exit(T.lineEnding),q;return _$($,I,T.linePrefix,W$.tabSize+1)(Q)}function I(Q){let D=G.events[G.events.length-1];return D&&D[1].type===T.linePrefix&&D[2].sliceSerialize(D[1],!0).length>=W$.tabSize?U(Q):N$(Q)?q(Q):J(Q)}}var NN={name:"codeText",previous:IB,resolve:Hr,tokenize:Tr};function Hr($){let U=$.length-4,J=3,G,q;if(($[J][1].type===T.lineEnding||$[J][1].type==="space")&&($[U][1].type===T.lineEnding||$[U][1].type==="space")){G=J;while(++G<U)if($[G][1].type===T.codeTextData){$[J][1].type=T.codeTextPadding,$[U][1].type=T.codeTextPadding,J+=2,U-=2;break}}G=J-1,U++;while(++G<=U)if(q===void 0){if(G!==U&&$[G][1].type!==T.lineEnding)q=G}else if(G===U||$[G][1].type===T.lineEnding){if($[q][1].type=T.codeTextData,G!==q+2)$[q][1].end=$[G-1][1].end,$.splice(q+2,G-q-2),U-=G-q-2,G=q+2;q=void 0}return $}function IB($){return $!==z.graveAccent||this.events[this.events.length-1][1].type===T.characterEscape}function Tr($,U,J){let G=this,q=0,I,Q;return D;function D(O){return k(O===z.graveAccent,"expected `` ` ``"),k(IB.call(G,G.previous),"expected correct previous"),$.enter(T.codeText),$.enter(T.codeTextSequence),X(O)}function X(O){if(O===z.graveAccent)return $.consume(O),q++,X;return $.exit(T.codeTextSequence),Y(O)}function Y(O){if(O===z.eof)return J(O);if(O===z.space)return $.enter("space"),$.consume(O),$.exit("space"),Y;if(O===z.graveAccent)return Q=$.enter(T.codeTextSequence),I=0,W(O);if(N$(O))return $.enter(T.lineEnding),$.consume(O),$.exit(T.lineEnding),Y;return $.enter(T.codeTextData),V(O)}function V(O){if(O===z.eof||O===z.space||O===z.graveAccent||N$(O))return $.exit(T.codeTextData),Y(O);return $.consume(O),V}function W(O){if(O===z.graveAccent)return $.consume(O),I++,W;if(I===q)return $.exit(T.codeTextSequence),$.exit(T.codeText),U(O);return Q.type=T.codeTextData,V(O)}}class wN{constructor($){this.left=$?[...$]:[],this.right=[]}get($){if($<0||$>=this.left.length+this.right.length)throw RangeError("Cannot access index `"+$+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");if($<this.left.length)return this.left[$];return this.right[this.right.length-$+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice($,U){let J=U===null||U===void 0?Number.POSITIVE_INFINITY:U;if(J<this.left.length)return this.left.slice($,J);if($>this.left.length)return this.right.slice(this.right.length-J+this.left.length,this.right.length-$+this.left.length).reverse();return this.left.slice($).concat(this.right.slice(this.right.length-J+this.left.length).reverse())}splice($,U,J){let G=U||0;this.setCursor(Math.trunc($));let q=this.right.splice(this.right.length-G,Number.POSITIVE_INFINITY);if(J)h4(this.left,J);return q.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push($){this.setCursor(Number.POSITIVE_INFINITY),this.left.push($)}pushMany($){this.setCursor(Number.POSITIVE_INFINITY),h4(this.left,$)}unshift($){this.setCursor(0),this.right.push($)}unshiftMany($){this.setCursor(0),h4(this.right,$.reverse())}setCursor($){if($===this.left.length||$>this.left.length&&this.right.length===0||$<0&&this.left.length===0)return;if($<this.left.length){let U=this.left.splice($,Number.POSITIVE_INFINITY);h4(this.right,U.reverse())}else{let U=this.right.splice(this.left.length+this.right.length-$,Number.POSITIVE_INFINITY);h4(this.left,U.reverse())}}}function h4($,U){let J=0;if(U.length<W$.v8MaxSafeChunkSize)$.push(...U);else while(J<U.length)$.push(...U.slice(J,J+W$.v8MaxSafeChunkSize)),J+=W$.v8MaxSafeChunkSize}function AX($){let U={},J=-1,G,q,I,Q,D,X,Y,V=new wN($);while(++J<V.length){while(J in U)J=U[J];if(G=V.get(J),J&&G[1].type===T.chunkFlow&&V.get(J-1)[1].type===T.listItemPrefix){if(k(G[1]._tokenizer,"expected `_tokenizer` on subtokens"),X=G[1]._tokenizer.events,I=0,I<X.length&&X[I][1].type===T.lineEndingBlank)I+=2;if(I<X.length&&X[I][1].type===T.content)while(++I<X.length){if(X[I][1].type===T.content)break;if(X[I][1].type===T.chunkText)X[I][1]._isInFirstContentOfListItem=!0,I++}}if(G[0]==="enter"){if(G[1].contentType)Object.assign(U,zr(V,J)),J=U[J],Y=!0}else if(G[1]._container){I=J,q=void 0;while(I--)if(Q=V.get(I),Q[1].type===T.lineEnding||Q[1].type===T.lineEndingBlank){if(Q[0]==="enter"){if(q)V.get(q)[1].type=T.lineEndingBlank;Q[1].type=T.lineEnding,q=I}}else if(Q[1].type===T.linePrefix||Q[1].type===T.listItemIndent);else break;if(q)G[1].end={...V.get(q)[1].start},D=V.slice(q,J),D.unshift(G),V.splice(q,J-q+1,D)}}return H0($,0,Number.POSITIVE_INFINITY,V.slice(0)),!Y}function zr($,U){let J=$.get(U)[1],G=$.get(U)[2],q=U-1,I=[];k(J.contentType,"expected `contentType` on subtokens");let Q=J._tokenizer;if(!Q){if(Q=G.parser[J.contentType](J.start),J._contentTypeTextTrailing)Q._contentTypeTextTrailing=!0}let D=Q.events,X=[],Y={},V,W,O=-1,Z=J,M=0,w=0,H=[w];while(Z){while($.get(++q)[1]!==Z);if(k(!W||Z.previous===W,"expected previous to match"),k(!W||W.next===Z,"expected next to match"),I.push(q),!Z._tokenizer){if(V=G.sliceStream(Z),!Z.next)V.push(z.eof);if(W)Q.defineSkip(Z.start);if(Z._isInFirstContentOfListItem)Q._gfmTasklistFirstContentOfListItem=!0;if(Q.write(V),Z._isInFirstContentOfListItem)Q._gfmTasklistFirstContentOfListItem=void 0}W=Z,Z=Z.next}Z=J;while(++O<D.length)if(D[O][0]==="exit"&&D[O-1][0]==="enter"&&D[O][1].type===D[O-1][1].type&&D[O][1].start.line!==D[O][1].end.line)k(Z,"expected a current token"),w=O+1,H.push(w),Z._tokenizer=void 0,Z.previous=void 0,Z=Z.next;if(Q.events=[],Z)Z._tokenizer=void 0,Z.previous=void 0,k(!Z.next,"expected no next token");else H.pop();O=H.length;while(O--){let g=D.slice(H[O],H[O+1]),P=I.pop();k(P!==void 0,"expected a start position when splicing"),X.push([P,P+g.length-1]),$.splice(P,2,g)}X.reverse(),O=-1;while(++O<X.length)Y[M+X[O][0]]=M+X[O][1],M+=X[O][1]-X[O][0]-1;return Y}var MN={resolve:Kr,tokenize:gr},Ar={partial:!0,tokenize:jr};function Kr($){return AX($),$}function gr($,U){let J;return G;function G(D){return k(D!==z.eof&&!N$(D),"expected no eof or eol"),$.enter(T.content),J=$.enter(T.chunkContent,{contentType:W$.contentTypeContent}),q(D)}function q(D){if(D===z.eof)return I(D);if(N$(D))return $.check(Ar,Q,I)(D);return $.consume(D),q}function I(D){return $.exit(T.chunkContent),$.exit(T.content),U(D)}function Q(D){return k(N$(D),"expected eol"),$.consume(D),$.exit(T.chunkContent),k(J,"expected previous token"),J.next=$.enter(T.chunkContent,{contentType:W$.contentTypeContent,previous:J}),J=J.next,q}}function jr($,U,J){let G=this;return q;function q(Q){return k(N$(Q),"expected a line ending"),$.exit(T.chunkContent),$.enter(T.lineEnding),$.consume(Q),$.exit(T.lineEnding),_$($,I,T.linePrefix)}function I(Q){if(Q===z.eof||N$(Q))return J(Q);k(G.parser.constructs.disable.null,"expected `disable.null` to be populated");let D=G.events[G.events.length-1];if(!G.parser.constructs.disable.null.includes("codeIndented")&&D&&D[1].type===T.linePrefix&&D[2].sliceSerialize(D[1],!0).length>=W$.tabSize)return U(Q);return $.interrupt(G.parser.constructs.flow,J,U)(Q)}}function KX($,U,J,G,q,I,Q,D,X){let Y=X||Number.POSITIVE_INFINITY,V=0;return W;function W(g){if(g===z.lessThan)return $.enter(G),$.enter(q),$.enter(I),$.consume(g),$.exit(I),O;if(g===z.eof||g===z.space||g===z.rightParenthesis||x4(g))return J(g);return $.enter(G),$.enter(Q),$.enter(D),$.enter(T.chunkString,{contentType:W$.contentTypeString}),w(g)}function O(g){if(g===z.greaterThan)return $.enter(I),$.consume(g),$.exit(I),$.exit(q),$.exit(G),U;return $.enter(D),$.enter(T.chunkString,{contentType:W$.contentTypeString}),Z(g)}function Z(g){if(g===z.greaterThan)return $.exit(T.chunkString),$.exit(D),O(g);if(g===z.eof||g===z.lessThan||N$(g))return J(g);return $.consume(g),g===z.backslash?M:Z}function M(g){if(g===z.lessThan||g===z.greaterThan||g===z.backslash)return $.consume(g),Z;return Z(g)}function w(g){if(!V&&(g===z.eof||g===z.rightParenthesis||e$(g)))return $.exit(T.chunkString),$.exit(D),$.exit(Q),$.exit(G),U(g);if(V<Y&&g===z.leftParenthesis)return $.consume(g),V++,w;if(g===z.rightParenthesis)return $.consume(g),V--,w;if(g===z.eof||g===z.space||g===z.leftParenthesis||x4(g))return J(g);return $.consume(g),g===z.backslash?H:w}function H(g){if(g===z.leftParenthesis||g===z.rightParenthesis||g===z.backslash)return $.consume(g),w;return w(g)}}function gX($,U,J,G,q,I){let Q=this,D=0,X;return Y;function Y(Z){return k(Z===z.leftSquareBracket,"expected `[`"),$.enter(G),$.enter(q),$.consume(Z),$.exit(q),$.enter(I),V}function V(Z){if(D>W$.linkReferenceSizeMax||Z===z.eof||Z===z.leftSquareBracket||Z===z.rightSquareBracket&&!X||Z===z.caret&&!D&&"_hiddenFootnoteSupport"in Q.parser.constructs)return J(Z);if(Z===z.rightSquareBracket)return $.exit(I),$.enter(q),$.consume(Z),$.exit(q),$.exit(G),U;if(N$(Z))return $.enter(T.lineEnding),$.consume(Z),$.exit(T.lineEnding),V;return $.enter(T.chunkString,{contentType:W$.contentTypeString}),W(Z)}function W(Z){if(Z===z.eof||Z===z.leftSquareBracket||Z===z.rightSquareBracket||N$(Z)||D++>W$.linkReferenceSizeMax)return $.exit(T.chunkString),V(Z);if($.consume(Z),!X)X=!C$(Z);return Z===z.backslash?O:W}function O(Z){if(Z===z.leftSquareBracket||Z===z.backslash||Z===z.rightSquareBracket)return $.consume(Z),D++,W;return W(Z)}}function jX($,U,J,G,q,I){let Q;return D;function D(O){if(O===z.quotationMark||O===z.apostrophe||O===z.leftParenthesis)return $.enter(G),$.enter(q),$.consume(O),$.exit(q),Q=O===z.leftParenthesis?z.rightParenthesis:O,X;return J(O)}function X(O){if(O===Q)return $.enter(q),$.consume(O),$.exit(q),$.exit(G),U;return $.enter(I),Y(O)}function Y(O){if(O===Q)return $.exit(I),X(Q);if(O===z.eof)return J(O);if(N$(O))return $.enter(T.lineEnding),$.consume(O),$.exit(T.lineEnding),_$($,Y,T.linePrefix);return $.enter(T.chunkString,{contentType:W$.contentTypeString}),V(O)}function V(O){if(O===Q||O===z.eof||N$(O))return $.exit(T.chunkString),Y(O);return $.consume(O),O===z.backslash?W:V}function W(O){if(O===Q||O===z.backslash)return $.consume(O),V;return V(O)}}function $G($,U){let J;return G;function G(q){if(N$(q))return $.enter(T.lineEnding),$.consume(q),$.exit(T.lineEnding),J=!0,G;if(C$(q))return _$($,G,J?T.linePrefix:T.lineSuffix)(q);return U(q)}}var HN={name:"definition",tokenize:Br},Pr={partial:!0,tokenize:Sr};function Br($,U,J){let G=this,q;return I;function I(Z){return $.enter(T.definition),Q(Z)}function Q(Z){return k(Z===z.leftSquareBracket,"expected `[`"),gX.call(G,$,D,J,T.definitionLabel,T.definitionLabelMarker,T.definitionLabelString)(Z)}function D(Z){if(q=wJ(G.sliceSerialize(G.events[G.events.length-1][1]).slice(1,-1)),Z===z.colon)return $.enter(T.definitionMarker),$.consume(Z),$.exit(T.definitionMarker),X;return J(Z)}function X(Z){return e$(Z)?$G($,Y)(Z):Y(Z)}function Y(Z){return KX($,V,J,T.definitionDestination,T.definitionDestinationLiteral,T.definitionDestinationLiteralMarker,T.definitionDestinationRaw,T.definitionDestinationString)(Z)}function V(Z){return $.attempt(Pr,W,W)(Z)}function W(Z){return C$(Z)?_$($,O,T.whitespace)(Z):O(Z)}function O(Z){if(Z===z.eof||N$(Z))return $.exit(T.definition),G.parser.defined.push(q),U(Z);return J(Z)}}function Sr($,U,J){return G;function G(D){return e$(D)?$G($,q)(D):J(D)}function q(D){return jX($,I,J,T.definitionTitle,T.definitionTitleMarker,T.definitionTitleString)(D)}function I(D){return C$(D)?_$($,Q,T.whitespace)(D):Q(D)}function Q(D){return D===z.eof||N$(D)?U(D):J(D)}}var TN={name:"hardBreakEscape",tokenize:Lr};function Lr($,U,J){return G;function G(I){return k(I===z.backslash,"expected `\\`"),$.enter(T.hardBreakEscape),$.consume(I),q}function q(I){if(N$(I))return $.exit(T.hardBreakEscape),U(I);return J(I)}}var zN={name:"headingAtx",resolve:Er,tokenize:Cr};function Er($,U){let J=$.length-2,G=3,q,I;if($[G][1].type===T.whitespace)G+=2;if(J-2>G&&$[J][1].type===T.whitespace)J-=2;if($[J][1].type===T.atxHeadingSequence&&(G===J-1||J-4>G&&$[J-2][1].type===T.whitespace))J-=G+1===J?2:4;if(J>G)q={type:T.atxHeadingText,start:$[G][1].start,end:$[J][1].end},I={type:T.chunkText,start:$[G][1].start,end:$[J][1].end,contentType:W$.contentTypeText},H0($,G,J-G+1,[["enter",q,U],["enter",I,U],["exit",I,U],["exit",q,U]]);return $}function Cr($,U,J){let G=0;return q;function q(V){return $.enter(T.atxHeading),I(V)}function I(V){return k(V===z.numberSign,"expected `#`"),$.enter(T.atxHeadingSequence),Q(V)}function Q(V){if(V===z.numberSign&&G++<W$.atxHeadingOpeningFenceSizeMax)return $.consume(V),Q;if(V===z.eof||e$(V))return $.exit(T.atxHeadingSequence),D(V);return J(V)}function D(V){if(V===z.numberSign)return $.enter(T.atxHeadingSequence),X(V);if(V===z.eof||N$(V))return $.exit(T.atxHeading),U(V);if(C$(V))return _$($,D,T.whitespace)(V);return $.enter(T.atxHeadingText),Y(V)}function X(V){if(V===z.numberSign)return $.consume(V),X;return $.exit(T.atxHeadingSequence),D(V)}function Y(V){if(V===z.eof||V===z.numberSign||e$(V))return $.exit(T.atxHeadingText),D(V);return $.consume(V),Y}}var QB=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],AN=["pre","script","style","textarea"];var KN={concrete:!0,name:"htmlFlow",resolveTo:Fr,tokenize:br},_r={partial:!0,tokenize:kr},vr={partial:!0,tokenize:ur};function Fr($){let U=$.length;while(U--)if($[U][0]==="enter"&&$[U][1].type===T.htmlFlow)break;if(U>1&&$[U-2][1].type===T.linePrefix)$[U][1].start=$[U-2][1].start,$[U+1][1].start=$[U-2][1].start,$.splice(U-2,2);return $}function br($,U,J){let G=this,q,I,Q,D,X;return Y;function Y(B){return V(B)}function V(B){return k(B===z.lessThan,"expected `<`"),$.enter(T.htmlFlow),$.enter(T.htmlFlowData),$.consume(B),W}function W(B){if(B===z.exclamationMark)return $.consume(B),O;if(B===z.slash)return $.consume(B),I=!0,w;if(B===z.questionMark)return $.consume(B),q=W$.htmlInstruction,G.interrupt?U:A;if(wU(B))return k(B!==null),$.consume(B),Q=String.fromCharCode(B),H;return J(B)}function O(B){if(B===z.dash)return $.consume(B),q=W$.htmlComment,Z;if(B===z.leftSquareBracket)return $.consume(B),q=W$.htmlCdata,D=0,M;if(wU(B))return $.consume(B),q=W$.htmlDeclaration,G.interrupt?U:A;return J(B)}function Z(B){if(B===z.dash)return $.consume(B),G.interrupt?U:A;return J(B)}function M(B){let R$=W$.cdataOpeningString;if(B===R$.charCodeAt(D++)){if($.consume(B),D===R$.length)return G.interrupt?U:_;return M}return J(B)}function w(B){if(wU(B))return k(B!==null),$.consume(B),Q=String.fromCharCode(B),H;return J(B)}function H(B){if(B===z.eof||B===z.slash||B===z.greaterThan||e$(B)){let R$=B===z.slash,H$=Q.toLowerCase();if(!R$&&!I&&AN.includes(H$))return q=W$.htmlRaw,G.interrupt?U(B):_(B);if(QB.includes(Q.toLowerCase())){if(q=W$.htmlBasic,R$)return $.consume(B),g;return G.interrupt?U(B):_(B)}return q=W$.htmlComplete,G.interrupt&&!G.parser.lazy[G.now().line]?J(B):I?P(B):C(B)}if(B===z.dash||o0(B))return $.consume(B),Q+=String.fromCharCode(B),H;return J(B)}function g(B){if(B===z.greaterThan)return $.consume(B),G.interrupt?U:_;return J(B)}function P(B){if(C$(B))return $.consume(B),P;return s(B)}function C(B){if(B===z.slash)return $.consume(B),s;if(B===z.colon||B===z.underscore||wU(B))return $.consume(B),F;if(C$(B))return $.consume(B),C;return s(B)}function F(B){if(B===z.dash||B===z.dot||B===z.colon||B===z.underscore||o0(B))return $.consume(B),F;return f(B)}function f(B){if(B===z.equalsTo)return $.consume(B),E;if(C$(B))return $.consume(B),f;return C(B)}function E(B){if(B===z.eof||B===z.lessThan||B===z.equalsTo||B===z.greaterThan||B===z.graveAccent)return J(B);if(B===z.quotationMark||B===z.apostrophe)return $.consume(B),X=B,p;if(C$(B))return $.consume(B),E;return b(B)}function p(B){if(B===X)return $.consume(B),X=null,h;if(B===z.eof||N$(B))return J(B);return $.consume(B),p}function b(B){if(B===z.eof||B===z.quotationMark||B===z.apostrophe||B===z.slash||B===z.lessThan||B===z.equalsTo||B===z.greaterThan||B===z.graveAccent||e$(B))return f(B);return $.consume(B),b}function h(B){if(B===z.slash||B===z.greaterThan||C$(B))return C(B);return J(B)}function s(B){if(B===z.greaterThan)return $.consume(B),m;return J(B)}function m(B){if(B===z.eof||N$(B))return _(B);if(C$(B))return $.consume(B),m;return J(B)}function _(B){if(B===z.dash&&q===W$.htmlComment)return $.consume(B),S;if(B===z.lessThan&&q===W$.htmlRaw)return $.consume(B),y;if(B===z.greaterThan&&q===W$.htmlDeclaration)return $.consume(B),o;if(B===z.questionMark&&q===W$.htmlInstruction)return $.consume(B),A;if(B===z.rightSquareBracket&&q===W$.htmlCdata)return $.consume(B),l;if(N$(B)&&(q===W$.htmlBasic||q===W$.htmlComplete))return $.exit(T.htmlFlowData),$.check(_r,G$,v)(B);if(B===z.eof||N$(B))return $.exit(T.htmlFlowData),v(B);return $.consume(B),_}function v(B){return $.check(vr,j,G$)(B)}function j(B){return k(N$(B)),$.enter(T.lineEnding),$.consume(B),$.exit(T.lineEnding),L}function L(B){if(B===z.eof||N$(B))return v(B);return $.enter(T.htmlFlowData),_(B)}function S(B){if(B===z.dash)return $.consume(B),A;return _(B)}function y(B){if(B===z.slash)return $.consume(B),Q="",u;return _(B)}function u(B){if(B===z.greaterThan){let R$=Q.toLowerCase();if(AN.includes(R$))return $.consume(B),o;return _(B)}if(wU(B)&&Q.length<W$.htmlRawSizeMax)return k(B!==null),$.consume(B),Q+=String.fromCharCode(B),u;return _(B)}function l(B){if(B===z.rightSquareBracket)return $.consume(B),A;return _(B)}function A(B){if(B===z.greaterThan)return $.consume(B),o;if(B===z.dash&&q===W$.htmlComment)return $.consume(B),A;return _(B)}function o(B){if(B===z.eof||N$(B))return $.exit(T.htmlFlowData),G$(B);return $.consume(B),o}function G$(B){return $.exit(T.htmlFlow),U(B)}}function ur($,U,J){let G=this;return q;function q(Q){if(N$(Q))return $.enter(T.lineEnding),$.consume(Q),$.exit(T.lineEnding),I;return J(Q)}function I(Q){return G.parser.lazy[G.now().line]?J(Q):U(Q)}}function kr($,U,J){return G;function G(q){return k(N$(q),"expected a line ending"),$.enter(T.lineEnding),$.consume(q),$.exit(T.lineEnding),$.attempt($q,U,J)}}var gN={name:"htmlText",tokenize:xr};function xr($,U,J){let G=this,q,I,Q;return D;function D(A){return k(A===z.lessThan,"expected `<`"),$.enter(T.htmlText),$.enter(T.htmlTextData),$.consume(A),X}function X(A){if(A===z.exclamationMark)return $.consume(A),Y;if(A===z.slash)return $.consume(A),f;if(A===z.questionMark)return $.consume(A),C;if(wU(A))return $.consume(A),b;return J(A)}function Y(A){if(A===z.dash)return $.consume(A),V;if(A===z.leftSquareBracket)return $.consume(A),I=0,M;if(wU(A))return $.consume(A),P;return J(A)}function V(A){if(A===z.dash)return $.consume(A),Z;return J(A)}function W(A){if(A===z.eof)return J(A);if(A===z.dash)return $.consume(A),O;if(N$(A))return Q=W,y(A);return $.consume(A),W}function O(A){if(A===z.dash)return $.consume(A),Z;return W(A)}function Z(A){return A===z.greaterThan?S(A):A===z.dash?O(A):W(A)}function M(A){let o=W$.cdataOpeningString;if(A===o.charCodeAt(I++))return $.consume(A),I===o.length?w:M;return J(A)}function w(A){if(A===z.eof)return J(A);if(A===z.rightSquareBracket)return $.consume(A),H;if(N$(A))return Q=w,y(A);return $.consume(A),w}function H(A){if(A===z.rightSquareBracket)return $.consume(A),g;return w(A)}function g(A){if(A===z.greaterThan)return S(A);if(A===z.rightSquareBracket)return $.consume(A),g;return w(A)}function P(A){if(A===z.eof||A===z.greaterThan)return S(A);if(N$(A))return Q=P,y(A);return $.consume(A),P}function C(A){if(A===z.eof)return J(A);if(A===z.questionMark)return $.consume(A),F;if(N$(A))return Q=C,y(A);return $.consume(A),C}function F(A){return A===z.greaterThan?S(A):C(A)}function f(A){if(wU(A))return $.consume(A),E;return J(A)}function E(A){if(A===z.dash||o0(A))return $.consume(A),E;return p(A)}function p(A){if(N$(A))return Q=p,y(A);if(C$(A))return $.consume(A),p;return S(A)}function b(A){if(A===z.dash||o0(A))return $.consume(A),b;if(A===z.slash||A===z.greaterThan||e$(A))return h(A);return J(A)}function h(A){if(A===z.slash)return $.consume(A),S;if(A===z.colon||A===z.underscore||wU(A))return $.consume(A),s;if(N$(A))return Q=h,y(A);if(C$(A))return $.consume(A),h;return S(A)}function s(A){if(A===z.dash||A===z.dot||A===z.colon||A===z.underscore||o0(A))return $.consume(A),s;return m(A)}function m(A){if(A===z.equalsTo)return $.consume(A),_;if(N$(A))return Q=m,y(A);if(C$(A))return $.consume(A),m;return h(A)}function _(A){if(A===z.eof||A===z.lessThan||A===z.equalsTo||A===z.greaterThan||A===z.graveAccent)return J(A);if(A===z.quotationMark||A===z.apostrophe)return $.consume(A),q=A,v;if(N$(A))return Q=_,y(A);if(C$(A))return $.consume(A),_;return $.consume(A),j}function v(A){if(A===q)return $.consume(A),q=void 0,L;if(A===z.eof)return J(A);if(N$(A))return Q=v,y(A);return $.consume(A),v}function j(A){if(A===z.eof||A===z.quotationMark||A===z.apostrophe||A===z.lessThan||A===z.equalsTo||A===z.graveAccent)return J(A);if(A===z.slash||A===z.greaterThan||e$(A))return h(A);return $.consume(A),j}function L(A){if(A===z.slash||A===z.greaterThan||e$(A))return h(A);return J(A)}function S(A){if(A===z.greaterThan)return $.consume(A),$.exit(T.htmlTextData),$.exit(T.htmlText),U;return J(A)}function y(A){return k(Q,"expected return state"),k(N$(A),"expected eol"),$.exit(T.htmlTextData),$.enter(T.lineEnding),$.consume(A),$.exit(T.lineEnding),u}function u(A){return k(G.parser.constructs.disable.null,"expected `disable.null` to be populated"),C$(A)?_$($,l,T.linePrefix,G.parser.constructs.disable.null.includes("codeIndented")?void 0:W$.tabSize)(A):l(A)}function l(A){return $.enter(T.htmlTextData),Q(A)}}var UG={name:"labelEnd",resolveAll:hr,resolveTo:rr,tokenize:lr},fr={tokenize:ir},yr={tokenize:pr},mr={tokenize:dr};function hr($){let U=-1,J=[];while(++U<$.length){let G=$[U][1];if(J.push($[U]),G.type===T.labelImage||G.type===T.labelLink||G.type===T.labelEnd){let q=G.type===T.labelImage?4:2;G.type=T.data,U+=q}}if($.length!==J.length)H0($,0,$.length,J);return $}function rr($,U){let J=$.length,G=0,q,I,Q,D;while(J--)if(q=$[J][1],I){if(q.type===T.link||q.type===T.labelLink&&q._inactive)break;if($[J][0]==="enter"&&q.type===T.labelLink)q._inactive=!0}else if(Q){if($[J][0]==="enter"&&(q.type===T.labelImage||q.type===T.labelLink)&&!q._balanced){if(I=J,q.type!==T.labelLink){G=2;break}}}else if(q.type===T.labelEnd)Q=J;k(I!==void 0,"`open` is supposed to be found"),k(Q!==void 0,"`close` is supposed to be found");let X={type:$[I][1].type===T.labelLink?T.link:T.image,start:{...$[I][1].start},end:{...$[$.length-1][1].end}},Y={type:T.label,start:{...$[I][1].start},end:{...$[Q][1].end}},V={type:T.labelText,start:{...$[I+G+2][1].end},end:{...$[Q-2][1].start}};return D=[["enter",X,U],["enter",Y,U]],D=c0(D,$.slice(I+1,I+G+3)),D=c0(D,[["enter",V,U]]),k(U.parser.constructs.insideSpan.null,"expected `insideSpan.null` to be populated"),D=c0(D,f8(U.parser.constructs.insideSpan.null,$.slice(I+G+4,Q-3),U)),D=c0(D,[["exit",V,U],$[Q-2],$[Q-1],["exit",Y,U]]),D=c0(D,$.slice(Q+1)),D=c0(D,[["exit",X,U]]),H0($,I,$.length,D),$}function lr($,U,J){let G=this,q=G.events.length,I,Q;while(q--)if((G.events[q][1].type===T.labelImage||G.events[q][1].type===T.labelLink)&&!G.events[q][1]._balanced){I=G.events[q][1];break}return D;function D(O){if(k(O===z.rightSquareBracket,"expected `]`"),!I)return J(O);if(I._inactive)return W(O);return Q=G.parser.defined.includes(wJ(G.sliceSerialize({start:I.end,end:G.now()}))),$.enter(T.labelEnd),$.enter(T.labelMarker),$.consume(O),$.exit(T.labelMarker),$.exit(T.labelEnd),X}function X(O){if(O===z.leftParenthesis)return $.attempt(fr,V,Q?V:W)(O);if(O===z.leftSquareBracket)return $.attempt(yr,V,Q?Y:W)(O);return Q?V(O):W(O)}function Y(O){return $.attempt(mr,V,W)(O)}function V(O){return U(O)}function W(O){return I._balanced=!0,J(O)}}function ir($,U,J){return G;function G(W){return k(W===z.leftParenthesis,"expected left paren"),$.enter(T.resource),$.enter(T.resourceMarker),$.consume(W),$.exit(T.resourceMarker),q}function q(W){return e$(W)?$G($,I)(W):I(W)}function I(W){if(W===z.rightParenthesis)return V(W);return KX($,Q,D,T.resourceDestination,T.resourceDestinationLiteral,T.resourceDestinationLiteralMarker,T.resourceDestinationRaw,T.resourceDestinationString,W$.linkResourceDestinationBalanceMax)(W)}function Q(W){return e$(W)?$G($,X)(W):V(W)}function D(W){return J(W)}function X(W){if(W===z.quotationMark||W===z.apostrophe||W===z.leftParenthesis)return jX($,Y,J,T.resourceTitle,T.resourceTitleMarker,T.resourceTitleString)(W);return V(W)}function Y(W){return e$(W)?$G($,V)(W):V(W)}function V(W){if(W===z.rightParenthesis)return $.enter(T.resourceMarker),$.consume(W),$.exit(T.resourceMarker),$.exit(T.resource),U;return J(W)}}function pr($,U,J){let G=this;return q;function q(D){return k(D===z.leftSquareBracket,"expected left bracket"),gX.call(G,$,I,Q,T.reference,T.referenceMarker,T.referenceString)(D)}function I(D){return G.parser.defined.includes(wJ(G.sliceSerialize(G.events[G.events.length-1][1]).slice(1,-1)))?U(D):J(D)}function Q(D){return J(D)}}function dr($,U,J){return G;function G(I){return k(I===z.leftSquareBracket,"expected left bracket"),$.enter(T.reference),$.enter(T.referenceMarker),$.consume(I),$.exit(T.referenceMarker),q}function q(I){if(I===z.rightSquareBracket)return $.enter(T.referenceMarker),$.consume(I),$.exit(T.referenceMarker),$.exit(T.reference),U;return J(I)}}var jN={name:"labelStartImage",resolveAll:UG.resolveAll,tokenize:nr};function nr($,U,J){let G=this;return q;function q(D){return k(D===z.exclamationMark,"expected `!`"),$.enter(T.labelImage),$.enter(T.labelImageMarker),$.consume(D),$.exit(T.labelImageMarker),I}function I(D){if(D===z.leftSquareBracket)return $.enter(T.labelMarker),$.consume(D),$.exit(T.labelMarker),$.exit(T.labelImage),Q;return J(D)}function Q(D){return D===z.caret&&"_hiddenFootnoteSupport"in G.parser.constructs?J(D):U(D)}}var PN={name:"labelStartLink",resolveAll:UG.resolveAll,tokenize:cr};function cr($,U,J){let G=this;return q;function q(Q){return k(Q===z.leftSquareBracket,"expected `[`"),$.enter(T.labelLink),$.enter(T.labelMarker),$.consume(Q),$.exit(T.labelMarker),$.exit(T.labelLink),I}function I(Q){return Q===z.caret&&"_hiddenFootnoteSupport"in G.parser.constructs?J(Q):U(Q)}}var r4={name:"lineEnding",tokenize:or};function or($,U){return J;function J(G){return k(N$(G),"expected eol"),$.enter(T.lineEnding),$.consume(G),$.exit(T.lineEnding),_$($,U,T.linePrefix)}}var JG={name:"thematicBreak",tokenize:ar};function ar($,U,J){let G=0,q;return I;function I(Y){return $.enter(T.thematicBreak),Q(Y)}function Q(Y){return k(Y===z.asterisk||Y===z.dash||Y===z.underscore,"expected `*`, `-`, or `_`"),q=Y,D(Y)}function D(Y){if(Y===q)return $.enter(T.thematicBreakSequence),X(Y);if(G>=W$.thematicBreakMarkerCountMin&&(Y===z.eof||N$(Y)))return $.exit(T.thematicBreak),U(Y);return J(Y)}function X(Y){if(Y===q)return $.consume(Y),G++,X;return $.exit(T.thematicBreakSequence),C$(Y)?_$($,D,T.whitespace)(Y):D(Y)}}var F0={continuation:{tokenize:$l},exit:Jl,name:"list",tokenize:er},sr={partial:!0,tokenize:ql},tr={partial:!0,tokenize:Ul};function er($,U,J){let G=this,q=G.events[G.events.length-1],I=q&&q[1].type===T.linePrefix?q[2].sliceSerialize(q[1],!0).length:0,Q=0;return D;function D(Z){k(G.containerState,"expected state");let M=G.containerState.type||(Z===z.asterisk||Z===z.plusSign||Z===z.dash?T.listUnordered:T.listOrdered);if(M===T.listUnordered?!G.containerState.marker||Z===G.containerState.marker:f4(Z)){if(!G.containerState.type)G.containerState.type=M,$.enter(M,{_container:!0});if(M===T.listUnordered)return $.enter(T.listItemPrefix),Z===z.asterisk||Z===z.dash?$.check(JG,J,Y)(Z):Y(Z);if(!G.interrupt||Z===z.digit1)return $.enter(T.listItemPrefix),$.enter(T.listItemValue),X(Z)}return J(Z)}function X(Z){if(k(G.containerState,"expected state"),f4(Z)&&++Q<W$.listItemValueSizeMax)return $.consume(Z),X;if((!G.interrupt||Q<2)&&(G.containerState.marker?Z===G.containerState.marker:Z===z.rightParenthesis||Z===z.dot))return $.exit(T.listItemValue),Y(Z);return J(Z)}function Y(Z){return k(G.containerState,"expected state"),k(Z!==z.eof,"eof (`null`) is not a marker"),$.enter(T.listItemMarker),$.consume(Z),$.exit(T.listItemMarker),G.containerState.marker=G.containerState.marker||Z,$.check($q,G.interrupt?J:V,$.attempt(sr,O,W))}function V(Z){return k(G.containerState,"expected state"),G.containerState.initialBlankLine=!0,I++,O(Z)}function W(Z){if(C$(Z))return $.enter(T.listItemPrefixWhitespace),$.consume(Z),$.exit(T.listItemPrefixWhitespace),O;return J(Z)}function O(Z){return k(G.containerState,"expected state"),G.containerState.size=I+G.sliceSerialize($.exit(T.listItemPrefix),!0).length,U(Z)}}function $l($,U,J){let G=this;return k(G.containerState,"expected state"),G.containerState._closeFlow=void 0,$.check($q,q,I);function q(D){return k(G.containerState,"expected state"),k(typeof G.containerState.size==="number","expected size"),G.containerState.furtherBlankLines=G.containerState.furtherBlankLines||G.containerState.initialBlankLine,_$($,U,T.listItemIndent,G.containerState.size+1)(D)}function I(D){if(k(G.containerState,"expected state"),G.containerState.furtherBlankLines||!C$(D))return G.containerState.furtherBlankLines=void 0,G.containerState.initialBlankLine=void 0,Q(D);return G.containerState.furtherBlankLines=void 0,G.containerState.initialBlankLine=void 0,$.attempt(tr,U,Q)(D)}function Q(D){return k(G.containerState,"expected state"),G.containerState._closeFlow=!0,G.interrupt=void 0,k(G.parser.constructs.disable.null,"expected `disable.null` to be populated"),_$($,$.attempt(F0,U,J),T.linePrefix,G.parser.constructs.disable.null.includes("codeIndented")?void 0:W$.tabSize)(D)}}function Ul($,U,J){let G=this;return k(G.containerState,"expected state"),k(typeof G.containerState.size==="number","expected size"),_$($,q,T.listItemIndent,G.containerState.size+1);function q(I){k(G.containerState,"expected state");let Q=G.events[G.events.length-1];return Q&&Q[1].type===T.listItemIndent&&Q[2].sliceSerialize(Q[1],!0).length===G.containerState.size?U(I):J(I)}}function Jl($){k(this.containerState,"expected state"),k(typeof this.containerState.type==="string","expected type"),$.exit(this.containerState.type)}function ql($,U,J){let G=this;return k(G.parser.constructs.disable.null,"expected `disable.null` to be populated"),_$($,q,T.listItemPrefixWhitespace,G.parser.constructs.disable.null.includes("codeIndented")?void 0:W$.tabSize+1);function q(I){let Q=G.events[G.events.length-1];return!C$(I)&&Q&&Q[1].type===T.listItemPrefixWhitespace?U(I):J(I)}}var PX={name:"setextUnderline",resolveTo:Gl,tokenize:Il};function Gl($,U){let J=$.length,G,q,I;while(J--)if($[J][0]==="enter"){if($[J][1].type===T.content){G=J;break}if($[J][1].type===T.paragraph)q=J}else{if($[J][1].type===T.content)$.splice(J,1);if(!I&&$[J][1].type===T.definition)I=J}k(q!==void 0,"expected a `text` index to be found"),k(G!==void 0,"expected a `text` index to be found"),k($[G][2]===U,"enter context should be same"),k($[$.length-1][2]===U,"enter context should be same");let Q={type:T.setextHeading,start:{...$[G][1].start},end:{...$[$.length-1][1].end}};if($[q][1].type=T.setextHeadingText,I)$.splice(q,0,["enter",Q,U]),$.splice(I+1,0,["exit",$[G][1],U]),$[G][1].end={...$[I][1].end};else $[G][1]=Q;return $.push(["exit",Q,U]),$}function Il($,U,J){let G=this,q;return I;function I(Y){let V=G.events.length,W;k(Y===z.dash||Y===z.equalsTo,"expected `=` or `-`");while(V--)if(G.events[V][1].type!==T.lineEnding&&G.events[V][1].type!==T.linePrefix&&G.events[V][1].type!==T.content){W=G.events[V][1].type===T.paragraph;break}if(!G.parser.lazy[G.now().line]&&(G.interrupt||W))return $.enter(T.setextHeadingLine),q=Y,Q(Y);return J(Y)}function Q(Y){return $.enter(T.setextHeadingLineSequence),D(Y)}function D(Y){if(Y===q)return $.consume(Y),D;return $.exit(T.setextHeadingLineSequence),C$(Y)?_$($,X,T.lineSuffix)(Y):X(Y)}function X(Y){if(Y===z.eof||N$(Y))return $.exit(T.setextHeadingLine),U(Y);return J(Y)}}var DB={tokenize:Ql};function Ql($){let U=this,J=$.attempt($q,G,$.attempt(this.parser.constructs.flowInitial,q,_$($,$.attempt(this.parser.constructs.flow,q,$.attempt(MN,q)),T.linePrefix)));return J;function G(I){if(k(I===z.eof||N$(I),"expected eol or eof"),I===z.eof){$.consume(I);return}return $.enter(T.lineEndingBlank),$.consume(I),$.exit(T.lineEndingBlank),U.currentConstruct=void 0,J}function q(I){if(k(I===z.eof||N$(I),"expected eol or eof"),I===z.eof){$.consume(I);return}return $.enter(T.lineEnding),$.consume(I),$.exit(T.lineEnding),U.currentConstruct=void 0,J}}var XB={resolveAll:OB()},YB=WB("string"),VB=WB("text");function WB($){return{resolveAll:OB($==="text"?Dl:void 0),tokenize:U};function U(J){let G=this,q=this.parser.constructs[$],I=J.attempt(q,Q,D);return Q;function Q(V){return Y(V)?I(V):D(V)}function D(V){if(V===z.eof){J.consume(V);return}return J.enter(T.data),J.consume(V),X}function X(V){if(Y(V))return J.exit(T.data),I(V);return J.consume(V),X}function Y(V){if(V===z.eof)return!0;let W=q[V],O=-1;if(W){k(Array.isArray(W),"expected `disable.null` to be populated");while(++O<W.length){let Z=W[O];if(!Z.previous||Z.previous.call(G,G.previous))return!0}}return!1}}}function OB($){return U;function U(J,G){let q=-1,I;while(++q<=J.length)if(I===void 0){if(J[q]&&J[q][1].type===T.data)I=q,q++}else if(!J[q]||J[q][1].type!==T.data){if(q!==I+2)J[I][1].end=J[q-1][1].end,J.splice(I+2,q-I-2),q=I+2;I=void 0}return $?$(J,G):J}}function Dl($,U){let J=0;while(++J<=$.length)if((J===$.length||$[J][1].type===T.lineEnding)&&$[J-1][1].type===T.data){let G=$[J-1][1],q=U.sliceStream(G),I=q.length,Q=-1,D=0,X;while(I--){let Y=q[I];if(typeof Y==="string"){Q=Y.length;while(Y.charCodeAt(Q-1)===z.space)D++,Q--;if(Q)break;Q=-1}else if(Y===z.horizontalTab)X=!0,D++;else if(Y===z.virtualSpace);else{I++;break}}if(U._contentTypeTextTrailing&&J===$.length)D=0;if(D){let Y={type:J===$.length||X||D<W$.hardBreakPrefixSizeMin?T.lineSuffix:T.hardBreakTrailing,start:{_bufferIndex:I?Q:G.start._bufferIndex+Q,_index:G.start._index+I,line:G.end.line,column:G.end.column-D,offset:G.end.offset-D},end:{...G.end}};if(G.end={...Y.start},G.start.offset===G.end.offset)Object.assign(G,Y);else $.splice(J,0,["enter",Y,U],["exit",Y,U]),J+=2}J++}return $}var BN={};UU(BN,{text:()=>Zl,string:()=>Ol,insideSpan:()=>Rl,flowInitial:()=>Vl,flow:()=>Wl,document:()=>Xl,disable:()=>wl,contentInitial:()=>Yl,attentionMarkers:()=>Nl});var Xl={[z.asterisk]:F0,[z.plusSign]:F0,[z.dash]:F0,[z.digit0]:F0,[z.digit1]:F0,[z.digit2]:F0,[z.digit3]:F0,[z.digit4]:F0,[z.digit5]:F0,[z.digit6]:F0,[z.digit7]:F0,[z.digit8]:F0,[z.digit9]:F0,[z.greaterThan]:MX},Yl={[z.leftSquareBracket]:HN},Vl={[z.horizontalTab]:m4,[z.virtualSpace]:m4,[z.space]:m4},Wl={[z.numberSign]:zN,[z.asterisk]:JG,[z.dash]:[PX,JG],[z.lessThan]:KN,[z.equalsTo]:PX,[z.underscore]:JG,[z.graveAccent]:zX,[z.tilde]:zX},Ol={[z.ampersand]:TX,[z.backslash]:HX},Zl={[z.carriageReturn]:r4,[z.lineFeed]:r4,[z.carriageReturnLineFeed]:r4,[z.exclamationMark]:jN,[z.ampersand]:TX,[z.asterisk]:y4,[z.lessThan]:[RN,gN],[z.leftSquareBracket]:PN,[z.backslash]:[TN,HX],[z.rightSquareBracket]:UG,[z.underscore]:y4,[z.graveAccent]:NN},Rl={null:[y4,XB]},Nl={null:[z.asterisk,z.underscore]},wl={null:[]};var LB=nY(SB(),1);var IG=LB.default("micromark");function EB($,U,J){let G={_bufferIndex:-1,_index:0,line:J&&J.line||1,column:J&&J.column||1,offset:J&&J.offset||0},q={},I=[],Q=[],D=[],X=!0,Y={attempt:h(p),check:h(b),consume:F,enter:f,exit:E,interrupt:h(b,{interrupt:!0})},V={code:z.eof,containerState:{},defineSkip:g,events:[],now:H,parser:$,previous:z.eof,sliceSerialize:M,sliceStream:w,write:Z},W=U.tokenize.call(V,Y),O;if(U.resolveAll)I.push(U);return V;function Z(v){if(Q=c0(Q,v),P(),Q[Q.length-1]!==z.eof)return[];return s(U,0),V.events=f8(I,V.events,V),V.events}function M(v,j){return $i(w(v),j)}function w(v){return el(Q,v)}function H(){let{_bufferIndex:v,_index:j,line:L,column:S,offset:y}=G;return{_bufferIndex:v,_index:j,line:L,column:S,offset:y}}function g(v){q[v.line]=v.column,_(),IG("position: define skip: `%j`",G)}function P(){let v;while(G._index<Q.length){let j=Q[G._index];if(typeof j==="string"){if(v=G._index,G._bufferIndex<0)G._bufferIndex=0;while(G._index===v&&G._bufferIndex<j.length)C(j.charCodeAt(G._bufferIndex))}else C(j)}}function C(v){k(X===!0,"expected character to be consumed"),X=void 0,IG("main: passing `%s` to %s",v,W&&W.name),O=v,k(typeof W==="function","expected state"),W=W(v)}function F(v){if(k(v===O,"expected given code to equal expected code"),IG("consume: `%s`",v),k(X===void 0,"expected code to not have been consumed: this might be because `return x(code)` instead of `return x` was used"),k(v===null?V.events.length===0||V.events[V.events.length-1][0]==="exit":V.events[V.events.length-1][0]==="enter","expected last token to be open"),N$(v))G.line++,G.column=1,G.offset+=v===z.carriageReturnLineFeed?2:1,_(),IG("position: after eol: `%j`",G);else if(v!==z.virtualSpace)G.column++,G.offset++;if(G._bufferIndex<0)G._index++;else if(G._bufferIndex++,G._bufferIndex===Q[G._index].length)G._bufferIndex=-1,G._index++;V.previous=v,X=!0}function f(v,j){let L=j||{};return L.type=v,L.start=H(),k(typeof v==="string","expected string type"),k(v.length>0,"expected non-empty string"),IG("enter: `%s`",v),V.events.push(["enter",L,V]),D.push(L),L}function E(v){k(typeof v==="string","expected string type"),k(v.length>0,"expected non-empty string");let j=D.pop();return k(j,"cannot close w/o open tokens"),j.end=H(),k(v===j.type,"expected exit token to match current token"),k(!(j.start._index===j.end._index&&j.start._bufferIndex===j.end._bufferIndex),"expected non-empty token (`"+v+"`)"),IG("exit: `%s`",j.type),V.events.push(["exit",j,V]),j}function p(v,j){s(v,j.from)}function b(v,j){j.restore()}function h(v,j){return L;function L(S,y,u){let l,A,o,G$;return Array.isArray(S)?R$(S):("tokenize"in S)?R$([S]):B(S);function B(w$){return P$;function P$(u$){let m$=u$!==null&&w$[u$],o$=u$!==null&&w$.null,J0=[...Array.isArray(m$)?m$:m$?[m$]:[],...Array.isArray(o$)?o$:o$?[o$]:[]];return R$(J0)(u$)}}function R$(w$){if(l=w$,A=0,w$.length===0)return k(u,"expected `bogusState` to be given"),u;return H$(w$[A])}function H$(w$){return P$;function P$(u$){if(G$=m(),o=w$,!w$.partial)V.currentConstruct=w$;if(k(V.parser.constructs.disable.null,"expected `disable.null` to be populated"),w$.name&&V.parser.constructs.disable.null.includes(w$.name))return A$(u$);return w$.tokenize.call(j?Object.assign(Object.create(V),j):V,Y,K$,A$)(u$)}}function K$(w$){return k(w$===O,"expected code"),X=!0,v(o,G$),y}function A$(w$){if(k(w$===O,"expected code"),X=!0,G$.restore(),++A<l.length)return H$(l[A]);return u}}}function s(v,j){if(v.resolveAll&&!I.includes(v))I.push(v);if(v.resolve)H0(V.events,j,V.events.length-j,v.resolve(V.events.slice(j),V));if(v.resolveTo)V.events=v.resolveTo(V.events,V);k(v.partial||V.events.length===0||V.events[V.events.length-1][0]==="exit","expected last token to end")}function m(){let v=H(),j=V.previous,L=V.currentConstruct,S=V.events.length,y=Array.from(D);return{from:S,restore:u};function u(){G=v,V.previous=j,V.currentConstruct=L,V.events.length=S,D=y,_(),IG("position: restore: `%j`",G)}}function _(){if(G.line in q&&G.column<2)G.column=q[G.line],G.offset+=q[G.line]-1}}function el($,U){let J=U.start._index,G=U.start._bufferIndex,q=U.end._index,I=U.end._bufferIndex,Q;if(J===q)k(I>-1,"expected non-negative end buffer index"),k(G>-1,"expected non-negative start buffer index"),Q=[$[J].slice(G,I)];else{if(Q=$.slice(J,q),G>-1){let D=Q[0];if(typeof D==="string")Q[0]=D.slice(G);else k(G===0,"expected `startBufferIndex` to be `0`"),Q.shift()}if(I>0)Q.push($[q].slice(0,I))}return Q}function $i($,U){let J=-1,G=[],q;while(++J<$.length){let I=$[J],Q;if(typeof I==="string")Q=I;else switch(I){case z.carriageReturn:{Q=NU.cr;break}case z.lineFeed:{Q=NU.lf;break}case z.carriageReturnLineFeed:{Q=NU.cr+NU.lf;break}case z.horizontalTab:{Q=U?NU.space:NU.ht;break}case z.virtualSpace:{if(!U&&q)continue;Q=NU.space;break}default:k(typeof I==="number","expected number"),Q=String.fromCharCode(I)}q=I===z.horizontalTab,G.push(Q)}return G.join("")}function _N($){let G={constructs:cP([BN,...($||{}).extensions||[]]),content:q($B),defined:[],document:q(JB),flow:q(DB),lazy:{},string:q(YB),text:q(VB)};return G;function q(I){return Q;function Q(D){return EB(G,I,D)}}}function vN($){while(!AX($));return $}var CB=/[\0\t\n\r]/g;function FN(){let $=1,U="",J=!0,G;return q;function q(I,Q,D){let X=[],Y,V,W,O,Z;if(I=U+(typeof I==="string"?I.toString():new TextDecoder(Q||void 0).decode(I)),W=0,U="",J){if(I.charCodeAt(0)===z.byteOrderMarker)W++;J=void 0}while(W<I.length){if(CB.lastIndex=W,Y=CB.exec(I),O=Y&&Y.index!==void 0?Y.index:I.length,Z=I.charCodeAt(O),!Y){U=I.slice(W);break}if(Z===z.lf&&W===O&&G)X.push(z.carriageReturnLineFeed),G=void 0;else{if(G)X.push(z.carriageReturn),G=void 0;if(W<O)X.push(I.slice(W,O)),$+=O-W;switch(Z){case z.nul:{X.push(z.replacementCharacter),$++;break}case z.ht:{V=Math.ceil($/W$.tabSize)*W$.tabSize,X.push(z.horizontalTab);while($++<V)X.push(z.virtualSpace);break}case z.lf:{X.push(z.lineFeed),$=1;break}default:G=!0,$=1}}W=O+1}if(D){if(G)X.push(z.carriageReturn);if(U)X.push(U);X.push(z.eof)}return X}}var Ui=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function CX($){return $.replace(Ui,Ji)}function Ji($,U,J){if(U)return U;if(J.charCodeAt(0)===z.numberSign){let q=J.charCodeAt(1),I=q===z.lowercaseX||q===z.uppercaseX;return wX(J.slice(I?2:1),I?W$.numericBaseHexadecimal:W$.numericBaseDecimal)}return k8(J)||$}function Jq($){if(!$||typeof $!=="object")return"";if("position"in $||"type"in $)return _B($.position);if("start"in $||"end"in $)return _B($);if("line"in $||"column"in $)return bN($);return""}function bN($){return vB($&&$.line)+":"+vB($&&$.column)}function _B($){return bN($&&$.start)+"-"+bN($&&$.end)}function vB($){return $&&typeof $==="number"?$:1}var bB={}.hasOwnProperty;function uN($,U,J){if(U&&typeof U==="object")J=U,U=void 0;return qi(J)(vN(_N(J).document().write(FN()($,U,!0))))}function qi($){let U={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:I(hG),autolinkProtocol:h,autolinkEmail:h,atxHeading:I(YU),blockQuote:I(u$),characterEscape:h,characterReference:h,codeFenced:I(m$),codeFencedFenceInfo:Q,codeFencedFenceMeta:Q,codeIndented:I(m$,Q),codeText:I(o$,Q),codeTextData:h,data:h,codeFlowValue:h,definition:I(J0),definitionDestinationString:Q,definitionLabelString:Q,definitionTitleString:Q,emphasis:I(E0),hardBreakEscape:I(VU),hardBreakTrailing:I(VU),htmlFlow:I(KU,Q),htmlFlowData:h,htmlText:I(KU,Q),htmlTextData:h,image:I(mG),label:Q,link:I(hG),listItem:I(rG),listItemValue:O,listOrdered:I(_q,W),listUnordered:I(_q),paragraph:I(F6),reference:B,referenceString:Q,resourceDestinationString:Q,resourceTitleString:Q,setextHeading:I(YU),strong:I(FU),thematicBreak:I(lG)},exit:{atxHeading:X(),atxHeadingSequence:f,autolink:X(),autolinkEmail:P$,autolinkProtocol:w$,blockQuote:X(),characterEscapeValue:s,characterReferenceMarkerHexadecimal:H$,characterReferenceMarkerNumeric:H$,characterReferenceValue:K$,characterReference:A$,codeFenced:X(H),codeFencedFence:w,codeFencedFenceInfo:Z,codeFencedFenceMeta:M,codeFlowValue:s,codeIndented:X(g),codeText:X(L),codeTextData:s,data:s,definition:X(),definitionDestinationString:F,definitionLabelString:P,definitionTitleString:C,emphasis:X(),hardBreakEscape:X(_),hardBreakTrailing:X(_),htmlFlow:X(v),htmlFlowData:s,htmlText:X(j),htmlTextData:s,image:X(y),label:l,labelText:u,lineEnding:m,link:X(S),listItem:X(),listOrdered:X(),listUnordered:X(),paragraph:X(),referenceString:R$,resourceDestinationString:A,resourceTitleString:o,resource:G$,setextHeading:X(b),setextHeadingLineSequence:p,setextHeadingText:E,strong:X(),thematicBreak:X()}};uB(U,($||{}).mdastExtensions||[]);let J={};return G;function G(a){let t={type:"root",children:[]},R={stack:[t],tokenStack:[],config:U,enter:D,exit:Y,buffer:Q,resume:V,data:J},x=[],d=-1;while(++d<a.length)if(a[d][1].type===T.listOrdered||a[d][1].type===T.listUnordered)if(a[d][0]==="enter")x.push(d);else{let e=x.pop();k(typeof e==="number","expected list to be open"),d=q(a,e,d)}d=-1;while(++d<a.length){let e=U[a[d][0]];if(bB.call(e,a[d][1].type))e[a[d][1].type].call(Object.assign({sliceSerialize:a[d][2].sliceSerialize},R),a[d][1])}if(R.tokenStack.length>0){let e=R.tokenStack[R.tokenStack.length-1];(e[1]||FB).call(R,void 0,e[0])}t.position={start:qq(a.length>0?a[0][1].start:{line:1,column:1,offset:0}),end:qq(a.length>0?a[a.length-2][1].end:{line:1,column:1,offset:0})},d=-1;while(++d<U.transforms.length)t=U.transforms[d](t)||t;return t}function q(a,t,R){let x=t-1,d=-1,e=!1,c,I$,K,i;while(++x<=R){let q$=a[x];switch(q$[1].type){case T.listUnordered:case T.listOrdered:case T.blockQuote:{if(q$[0]==="enter")d++;else d--;i=void 0;break}case T.lineEndingBlank:{if(q$[0]==="enter"){if(c&&!i&&!d&&!K)K=x;i=void 0}break}case T.linePrefix:case T.listItemValue:case T.listItemMarker:case T.listItemPrefix:case T.listItemPrefixWhitespace:break;default:i=void 0}if(!d&&q$[0]==="enter"&&q$[1].type===T.listItemPrefix||d===-1&&q$[0]==="exit"&&(q$[1].type===T.listUnordered||q$[1].type===T.listOrdered)){if(c){let $$=x;I$=void 0;while($$--){let U$=a[$$];if(U$[1].type===T.lineEnding||U$[1].type===T.lineEndingBlank){if(U$[0]==="exit")continue;if(I$)a[I$][1].type=T.lineEndingBlank,e=!0;U$[1].type=T.lineEnding,I$=$$}else if(U$[1].type===T.linePrefix||U$[1].type===T.blockQuotePrefix||U$[1].type===T.blockQuotePrefixWhitespace||U$[1].type===T.blockQuoteMarker||U$[1].type===T.listItemIndent);else break}if(K&&(!I$||K<I$))c._spread=!0;c.end=Object.assign({},I$?a[I$][1].start:q$[1].end),a.splice(I$||x,0,["exit",c,q$[2]]),x++,R++}if(q$[1].type===T.listItemPrefix){let $$={type:"listItem",_spread:!1,start:Object.assign({},q$[1].start),end:void 0};c=$$,a.splice(x,0,["enter",$$,q$[2]]),x++,R++,K=void 0,i=!0}}}return a[t][1]._spread=e,R}function I(a,t){return R;function R(x){if(D.call(this,a(x),x),t)t.call(this,x)}}function Q(){this.stack.push({type:"fragment",children:[]})}function D(a,t,R){let x=this.stack[this.stack.length-1];k(x,"expected `parent`"),k("children"in x,"expected `parent`"),x.children.push(a),this.stack.push(a),this.tokenStack.push([t,R||void 0]),a.position={start:qq(t.start),end:void 0}}function X(a){return t;function t(R){if(a)a.call(this,R);Y.call(this,R)}}function Y(a,t){let R=this.stack.pop();k(R,"expected `node`");let x=this.tokenStack.pop();if(!x)throw Error("Cannot close `"+a.type+"` ("+Jq({start:a.start,end:a.end})+"): it\u2019s not open");else if(x[0].type!==a.type)if(t)t.call(this,a,x[0]);else(x[1]||FB).call(this,a,x[0]);k(R.type!=="fragment","unexpected fragment `exit`ed"),k(R.position,"expected `position` to be defined"),R.position.end=qq(a.end)}function V(){return eq(this.stack.pop())}function W(){this.data.expectingFirstListItemValue=!0}function O(a){if(this.data.expectingFirstListItemValue){let t=this.stack[this.stack.length-2];k(t,"expected nodes on stack"),k(t.type==="list","expected list on stack"),t.start=Number.parseInt(this.sliceSerialize(a),W$.numericBaseDecimal),this.data.expectingFirstListItemValue=void 0}}function Z(){let a=this.resume(),t=this.stack[this.stack.length-1];k(t,"expected node on stack"),k(t.type==="code","expected code on stack"),t.lang=a}function M(){let a=this.resume(),t=this.stack[this.stack.length-1];k(t,"expected node on stack"),k(t.type==="code","expected code on stack"),t.meta=a}function w(){if(this.data.flowCodeInside)return;this.buffer(),this.data.flowCodeInside=!0}function H(){let a=this.resume(),t=this.stack[this.stack.length-1];k(t,"expected node on stack"),k(t.type==="code","expected code on stack"),t.value=a.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function g(){let a=this.resume(),t=this.stack[this.stack.length-1];k(t,"expected node on stack"),k(t.type==="code","expected code on stack"),t.value=a.replace(/(\r?\n|\r)$/g,"")}function P(a){let t=this.resume(),R=this.stack[this.stack.length-1];k(R,"expected node on stack"),k(R.type==="definition","expected definition on stack"),R.label=t,R.identifier=wJ(this.sliceSerialize(a)).toLowerCase()}function C(){let a=this.resume(),t=this.stack[this.stack.length-1];k(t,"expected node on stack"),k(t.type==="definition","expected definition on stack"),t.title=a}function F(){let a=this.resume(),t=this.stack[this.stack.length-1];k(t,"expected node on stack"),k(t.type==="definition","expected definition on stack"),t.url=a}function f(a){let t=this.stack[this.stack.length-1];if(k(t,"expected node on stack"),k(t.type==="heading","expected heading on stack"),!t.depth){let R=this.sliceSerialize(a).length;k(R===1||R===2||R===3||R===4||R===5||R===6,"expected `depth` between `1` and `6`"),t.depth=R}}function E(){this.data.setextHeadingSlurpLineEnding=!0}function p(a){let t=this.stack[this.stack.length-1];k(t,"expected node on stack"),k(t.type==="heading","expected heading on stack"),t.depth=this.sliceSerialize(a).codePointAt(0)===z.equalsTo?1:2}function b(){this.data.setextHeadingSlurpLineEnding=void 0}function h(a){let t=this.stack[this.stack.length-1];k(t,"expected node on stack"),k("children"in t,"expected parent on stack");let R=t.children,x=R[R.length-1];if(!x||x.type!=="text")x=b6(),x.position={start:qq(a.start),end:void 0},R.push(x);this.stack.push(x)}function s(a){let t=this.stack.pop();k(t,"expected a `node` to be on the stack"),k("value"in t,"expected a `literal` to be on the stack"),k(t.position,"expected `node` to have an open position"),t.value+=this.sliceSerialize(a),t.position.end=qq(a.end)}function m(a){let t=this.stack[this.stack.length-1];if(k(t,"expected `node`"),this.data.atHardBreak){k("children"in t,"expected `parent`");let R=t.children[t.children.length-1];k(R.position,"expected tail to have a starting position"),R.position.end=qq(a.end),this.data.atHardBreak=void 0;return}if(!this.data.setextHeadingSlurpLineEnding&&U.canContainEols.includes(t.type))h.call(this,a),s.call(this,a)}function _(){this.data.atHardBreak=!0}function v(){let a=this.resume(),t=this.stack[this.stack.length-1];k(t,"expected node on stack"),k(t.type==="html","expected html on stack"),t.value=a}function j(){let a=this.resume(),t=this.stack[this.stack.length-1];k(t,"expected node on stack"),k(t.type==="html","expected html on stack"),t.value=a}function L(){let a=this.resume(),t=this.stack[this.stack.length-1];k(t,"expected node on stack"),k(t.type==="inlineCode","expected inline code on stack"),t.value=a}function S(){let a=this.stack[this.stack.length-1];if(k(a,"expected node on stack"),k(a.type==="link","expected link on stack"),this.data.inReference){let t=this.data.referenceType||"shortcut";a.type+="Reference",a.referenceType=t,delete a.url,delete a.title}else delete a.identifier,delete a.label;this.data.referenceType=void 0}function y(){let a=this.stack[this.stack.length-1];if(k(a,"expected node on stack"),k(a.type==="image","expected image on stack"),this.data.inReference){let t=this.data.referenceType||"shortcut";a.type+="Reference",a.referenceType=t,delete a.url,delete a.title}else delete a.identifier,delete a.label;this.data.referenceType=void 0}function u(a){let t=this.sliceSerialize(a),R=this.stack[this.stack.length-2];k(R,"expected ancestor on stack"),k(R.type==="image"||R.type==="link","expected image or link on stack"),R.label=CX(t),R.identifier=wJ(t).toLowerCase()}function l(){let a=this.stack[this.stack.length-1];k(a,"expected node on stack"),k(a.type==="fragment","expected fragment on stack");let t=this.resume(),R=this.stack[this.stack.length-1];if(k(R,"expected node on stack"),k(R.type==="image"||R.type==="link","expected image or link on stack"),this.data.inReference=!0,R.type==="link"){let x=a.children;R.children=x}else R.alt=t}function A(){let a=this.resume(),t=this.stack[this.stack.length-1];k(t,"expected node on stack"),k(t.type==="image"||t.type==="link","expected image or link on stack"),t.url=a}function o(){let a=this.resume(),t=this.stack[this.stack.length-1];k(t,"expected node on stack"),k(t.type==="image"||t.type==="link","expected image or link on stack"),t.title=a}function G$(){this.data.inReference=void 0}function B(){this.data.referenceType="collapsed"}function R$(a){let t=this.resume(),R=this.stack[this.stack.length-1];k(R,"expected node on stack"),k(R.type==="image"||R.type==="link","expected image reference or link reference on stack"),R.label=t,R.identifier=wJ(this.sliceSerialize(a)).toLowerCase(),this.data.referenceType="full"}function H$(a){k(a.type==="characterReferenceMarkerNumeric"||a.type==="characterReferenceMarkerHexadecimal"),this.data.characterReferenceType=a.type}function K$(a){let t=this.sliceSerialize(a),R=this.data.characterReferenceType,x;if(R)x=wX(t,R===T.characterReferenceMarkerNumeric?W$.numericBaseDecimal:W$.numericBaseHexadecimal),this.data.characterReferenceType=void 0;else{let e=k8(t);k(e!==!1,"expected reference to decode"),x=e}let d=this.stack[this.stack.length-1];k(d,"expected `node`"),k("value"in d,"expected `node.value`"),d.value+=x}function A$(a){let t=this.stack.pop();k(t,"expected `node`"),k(t.position,"expected `node.position`"),t.position.end=qq(a.end)}function w$(a){s.call(this,a);let t=this.stack[this.stack.length-1];k(t,"expected node on stack"),k(t.type==="link","expected link on stack"),t.url=this.sliceSerialize(a)}function P$(a){s.call(this,a);let t=this.stack[this.stack.length-1];k(t,"expected node on stack"),k(t.type==="link","expected link on stack"),t.url="mailto:"+this.sliceSerialize(a)}function u$(){return{type:"blockquote",children:[]}}function m$(){return{type:"code",lang:null,meta:null,value:""}}function o$(){return{type:"inlineCode",value:""}}function J0(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function E0(){return{type:"emphasis",children:[]}}function YU(){return{type:"heading",depth:0,children:[]}}function VU(){return{type:"break"}}function KU(){return{type:"html",value:""}}function mG(){return{type:"image",title:null,url:"",alt:null}}function hG(){return{type:"link",title:null,url:"",children:[]}}function _q(a){return{type:"list",ordered:a.type==="listOrdered",start:null,spread:a._spread,children:[]}}function rG(a){return{type:"listItem",spread:a._spread,checked:null,children:[]}}function F6(){return{type:"paragraph",children:[]}}function FU(){return{type:"strong",children:[]}}function b6(){return{type:"text",value:""}}function lG(){return{type:"thematicBreak"}}}function qq($){return{line:$.line,column:$.column,offset:$.offset}}function uB($,U){let J=-1;while(++J<U.length){let G=U[J];if(Array.isArray(G))uB($,G);else Gi($,G)}}function Gi($,U){let J;for(J in U)if(bB.call(U,J))switch(J){case"canContainEols":{let G=U[J];if(G)$[J].push(...G);break}case"transforms":{let G=U[J];if(G)$[J].push(...G);break}case"enter":case"exit":{let G=U[J];if(G)Object.assign($[J],G);break}}}function FB($,U){if($)throw Error("Cannot close `"+$.type+"` ("+Jq({start:$.start,end:$.end})+"): a different token (`"+U.type+"`, "+Jq({start:U.start,end:U.end})+") is open");else throw Error("Cannot close document, a token (`"+U.type+"`, "+Jq({start:U.start,end:U.end})+") is still open")}function _X($){let U=this;U.parser=J;function J(G){return uN(G,{...U.data("settings"),...$,extensions:U.data("micromarkExtensions")||[],mdastExtensions:U.data("fromMarkdownExtensions")||[]})}}var kB={}.hasOwnProperty;function xB($,U){let J=U||{};function G(q,...I){let{invalid:Q,handlers:D}=G;if(q&&kB.call(q,$)){let X=String(q[$]);Q=kB.call(D,X)?D[X]:G.unknown}if(Q)return Q.call(this,q,...I)}return G.handlers=J.handlers||{},G.invalid=J.invalid,G.unknown=J.unknown,G}var Ii={}.hasOwnProperty;function kN($,U){let J=-1,G;if(U.extensions)while(++J<U.extensions.length)kN($,U.extensions[J]);for(G in U)if(Ii.call(U,G))switch(G){case"extensions":break;case"unsafe":{fB($[G],U[G]);break}case"join":{fB($[G],U[G]);break}case"handlers":{Qi($[G],U[G]);break}default:$.options[G]=U[G]}return $}function fB($,U){if(U)$.push(...U)}function Qi($,U){if(U)Object.assign($,U)}function yB($,U,J,G){let q=J.enter("blockquote"),I=J.createTracker(G);I.move("> "),I.shift(2);let Q=J.indentLines(J.containerFlow($,I.current()),Di);return q(),Q}function Di($,U,J){return">"+(J?"":" ")+$}function vX($,U){return mB($,U.inConstruct,!0)&&!mB($,U.notInConstruct,!1)}function mB($,U,J){if(typeof U==="string")U=[U];if(!U||U.length===0)return J;let G=-1;while(++G<U.length)if($.includes(U[G]))return!0;return!1}function xN($,U,J,G){let q=-1;while(++q<J.unsafe.length)if(J.unsafe[q].character===`
|
|
483
|
+
`&&vX(J.stack,J.unsafe[q]))return/[ \t]/.test(G.before)?"":" ";return"\\\n"}function hB($,U){let J=String($),G=J.indexOf(U),q=G,I=0,Q=0;if(typeof U!=="string")throw TypeError("Expected substring");while(G!==-1){if(G===q){if(++I>Q)Q=I}else I=1;q=G+U.length,G=J.indexOf(U,q)}return Q}function i4($,U){return Boolean(U.options.fences===!1&&$.value&&!$.lang&&/[^ \r\n]/.test($.value)&&!/^[\t ]*(?:[\r\n]|$)|(?:^|[\r\n])[\t ]*$/.test($.value))}function rB($){let U=$.options.fence||"`";if(U!=="`"&&U!=="~")throw Error("Cannot serialize code with `"+U+"` for `options.fence`, expected `` ` `` or `~`");return U}function lB($,U,J,G){let q=rB(J),I=$.value||"",Q=q==="`"?"GraveAccent":"Tilde";if(i4($,J)){let W=J.enter("codeIndented"),O=J.indentLines(I,Xi);return W(),O}let D=J.createTracker(G),X=q.repeat(Math.max(hB(I,q)+1,3)),Y=J.enter("codeFenced"),V=D.move(X);if($.lang){let W=J.enter(`codeFencedLang${Q}`);V+=D.move(J.safe($.lang,{before:V,after:" ",encode:["`"],...D.current()})),W()}if($.lang&&$.meta){let W=J.enter(`codeFencedMeta${Q}`);V+=D.move(" "),V+=D.move(J.safe($.meta,{before:V,after:`
|
|
484
|
+
`,encode:["`"],...D.current()})),W()}if(V+=D.move(`
|
|
485
|
+
`),I)V+=D.move(I+`
|
|
486
|
+
`);return V+=D.move(X),Y(),V}function Xi($,U,J){return(J?"":" ")+$}function r8($){let U=$.options.quote||'"';if(U!=='"'&&U!=="'")throw Error("Cannot serialize title with `"+U+"` for `options.quote`, expected `\"`, or `'`");return U}function iB($,U,J,G){let q=r8(J),I=q==='"'?"Quote":"Apostrophe",Q=J.enter("definition"),D=J.enter("label"),X=J.createTracker(G),Y=X.move("[");if(Y+=X.move(J.safe(J.associationId($),{before:Y,after:"]",...X.current()})),Y+=X.move("]: "),D(),!$.url||/[\0- \u007F]/.test($.url))D=J.enter("destinationLiteral"),Y+=X.move("<"),Y+=X.move(J.safe($.url,{before:Y,after:">",...X.current()})),Y+=X.move(">");else D=J.enter("destinationRaw"),Y+=X.move(J.safe($.url,{before:Y,after:$.title?" ":`
|
|
487
|
+
`,...X.current()}));if(D(),$.title)D=J.enter(`title${I}`),Y+=X.move(" "+q),Y+=X.move(J.safe($.title,{before:Y,after:q,...X.current()})),Y+=X.move(q),D();return Q(),Y}function pB($){let U=$.options.emphasis||"*";if(U!=="*"&&U!=="_")throw Error("Cannot serialize emphasis with `"+U+"` for `options.emphasis`, expected `*`, or `_`");return U}function MU($){return"&#x"+$.toString(16).toUpperCase()+";"}function l8($,U,J){let G=x8($),q=x8(U);if(G===void 0)return q===void 0?J==="_"?{inside:!0,outside:!0}:{inside:!1,outside:!1}:q===1?{inside:!0,outside:!0}:{inside:!1,outside:!0};if(G===1)return q===void 0?{inside:!1,outside:!1}:q===1?{inside:!0,outside:!0}:{inside:!1,outside:!1};return q===void 0?{inside:!1,outside:!1}:q===1?{inside:!0,outside:!1}:{inside:!1,outside:!1}}fN.peek=Yi;function fN($,U,J,G){let q=pB(J),I=J.enter("emphasis"),Q=J.createTracker(G),D=Q.move(q),X=Q.move(J.containerPhrasing($,{after:q,before:D,...Q.current()})),Y=X.charCodeAt(0),V=l8(G.before.charCodeAt(G.before.length-1),Y,q);if(V.inside)X=MU(Y)+X.slice(1);let W=X.charCodeAt(X.length-1),O=l8(G.after.charCodeAt(0),W,q);if(O.inside)X=X.slice(0,-1)+MU(W);let Z=Q.move(q);return I(),J.attentionEncodeSurroundingInfo={after:O.outside,before:V.outside},D+X+Z}function Yi($,U,J){return J.options.emphasis||"*"}var i8=function($){if($===null||$===void 0)return Zi;if(typeof $==="function")return FX($);if(typeof $==="object")return Array.isArray($)?Vi($):Wi($);if(typeof $==="string")return Oi($);throw Error("Expected function, string, or object as test")};function Vi($){let U=[],J=-1;while(++J<$.length)U[J]=i8($[J]);return FX(G);function G(...q){let I=-1;while(++I<U.length)if(U[I].apply(this,q))return!0;return!1}}function Wi($){let U=$;return FX(J);function J(G){let q=G,I;for(I in $)if(q[I]!==U[I])return!1;return!0}}function Oi($){return FX(U);function U(J){return J&&J.type===$}}function FX($){return U;function U(J,G,q){return Boolean(Ri(J)&&$.call(this,J,typeof G==="number"?G:void 0,q||void 0))}}function Zi(){return!0}function Ri($){return $!==null&&typeof $==="object"&&"type"in $}function dB($){return"\x1B[33m"+$+"\x1B[39m"}var nB=[],bX=!0,QG=!1,uX="skip";function yN($,U,J,G){let q;if(typeof U==="function"&&typeof J!=="function")G=J,J=U;else q=U;let I=i8(q),Q=G?-1:1;D($,void 0,[])();function D(X,Y,V){let W=X&&typeof X==="object"?X:{};if(typeof W.type==="string"){let Z=typeof W.tagName==="string"?W.tagName:typeof W.name==="string"?W.name:void 0;Object.defineProperty(O,"name",{value:"node ("+dB(X.type+(Z?"<"+Z+">":""))+")"})}return O;function O(){let Z=nB,M,w,H;if(!U||I(X,Y,V[V.length-1]||void 0)){if(Z=Ni(J(X,V)),Z[0]===QG)return Z}if("children"in X&&X.children){let g=X;if(g.children&&Z[0]!==uX){w=(G?g.children.length:-1)+Q,H=V.concat(g);while(w>-1&&w<g.children.length){let P=g.children[w];if(M=D(P,w,H)(),M[0]===QG)return M;w=typeof M[1]==="number"?M[1]:w+Q}}}return Z}}}function Ni($){if(Array.isArray($))return $;if(typeof $==="number")return[bX,$];return $===null||$===void 0?nB:[$]}function mN($,U,J,G){let q,I,Q;if(typeof U==="function"&&typeof J!=="function")I=void 0,Q=U,q=J;else I=U,Q=J,q=G;yN($,I,D,q);function D(X,Y){let V=Y[Y.length-1],W=V?V.children.indexOf(X):void 0;return Q(X,W,V)}}function kX($,U){let J=!1;return mN($,function(G){if("value"in G&&/\r?\n|\r/.test(G.value)||G.type==="break")return J=!0,QG}),Boolean((!$.depth||$.depth<3)&&eq($)&&(U.options.setext||J))}function cB($,U,J,G){let q=Math.max(Math.min(6,$.depth||1),1),I=J.createTracker(G);if(kX($,J)){let V=J.enter("headingSetext"),W=J.enter("phrasing"),O=J.containerPhrasing($,{...I.current(),before:`
|
|
110
488
|
`,after:`
|
|
111
|
-
`});return
|
|
112
|
-
`+(
|
|
113
|
-
`))+1))}let
|
|
114
|
-
`,...
|
|
115
|
-
`,inConstruct:["codeFencedLangGraveAccent","codeFencedLangTilde","codeFencedMetaGraveAccent","codeFencedMetaTilde","destinationLiteral","headingAtx"]},{character:" ",after:"[\\r\\n]",inConstruct:"phrasing"},{character:" ",before:"[\\r\\n]",inConstruct:"phrasing"},{character:" ",inConstruct:["codeFencedLangGraveAccent","codeFencedLangTilde"]},{character:"!",after:"\\[",inConstruct:"phrasing",notInConstruct
|
|
116
|
-
]|$)`},{character:"&",after:"[#A-Za-z]",inConstruct:"phrasing"},{character:"'",inConstruct:"titleApostrophe"},{character:"(",inConstruct:"destinationRaw"},{before:"\\]",character:"(",inConstruct:"phrasing",notInConstruct
|
|
117
|
-
*])`},{character:"*",inConstruct:"phrasing",notInConstruct
|
|
489
|
+
`});return W(),V(),O+`
|
|
490
|
+
`+(q===1?"=":"-").repeat(O.length-(Math.max(O.lastIndexOf("\r"),O.lastIndexOf(`
|
|
491
|
+
`))+1))}let Q="#".repeat(q),D=J.enter("headingAtx"),X=J.enter("phrasing");I.move(Q+" ");let Y=J.containerPhrasing($,{before:"# ",after:`
|
|
492
|
+
`,...I.current()});if(/^[\t ]/.test(Y))Y=MU(Y.charCodeAt(0))+Y.slice(1);if(Y=Y?Q+" "+Y:Q,J.options.closeAtx)Y+=" "+Q;return X(),D(),Y}hN.peek=wi;function hN($){return $.value||""}function wi(){return"<"}rN.peek=Mi;function rN($,U,J,G){let q=r8(J),I=q==='"'?"Quote":"Apostrophe",Q=J.enter("image"),D=J.enter("label"),X=J.createTracker(G),Y=X.move("![");if(Y+=X.move(J.safe($.alt,{before:Y,after:"]",...X.current()})),Y+=X.move("]("),D(),!$.url&&$.title||/[\0- \u007F]/.test($.url))D=J.enter("destinationLiteral"),Y+=X.move("<"),Y+=X.move(J.safe($.url,{before:Y,after:">",...X.current()})),Y+=X.move(">");else D=J.enter("destinationRaw"),Y+=X.move(J.safe($.url,{before:Y,after:$.title?" ":")",...X.current()}));if(D(),$.title)D=J.enter(`title${I}`),Y+=X.move(" "+q),Y+=X.move(J.safe($.title,{before:Y,after:q,...X.current()})),Y+=X.move(q),D();return Y+=X.move(")"),Q(),Y}function Mi(){return"!"}lN.peek=Hi;function lN($,U,J,G){let q=$.referenceType,I=J.enter("imageReference"),Q=J.enter("label"),D=J.createTracker(G),X=D.move("!["),Y=J.safe($.alt,{before:X,after:"]",...D.current()});X+=D.move(Y+"]["),Q();let V=J.stack;J.stack=[],Q=J.enter("reference");let W=J.safe(J.associationId($),{before:X,after:"]",...D.current()});if(Q(),J.stack=V,I(),q==="full"||!Y||Y!==W)X+=D.move(W+"]");else if(q==="shortcut")X=X.slice(0,-1);else X+=D.move("]");return X}function Hi(){return"!"}iN.peek=Ti;function iN($,U,J){let G=$.value||"",q="`",I=-1;while(new RegExp("(^|[^`])"+q+"([^`]|$)").test(G))q+="`";if(/[^ \r\n]/.test(G)&&(/^[ \r\n]/.test(G)&&/[ \r\n]$/.test(G)||/^`|`$/.test(G)))G=" "+G+" ";while(++I<J.unsafe.length){let Q=J.unsafe[I],D=J.compilePattern(Q),X;if(!Q.atBreak)continue;while(X=D.exec(G)){let Y=X.index;if(G.charCodeAt(Y)===10&&G.charCodeAt(Y-1)===13)Y--;G=G.slice(0,Y)+" "+G.slice(X.index+1)}}return q+G+q}function Ti(){return"`"}function pN($,U){let J=eq($);return Boolean(!U.options.resourceLink&&$.url&&!$.title&&$.children&&$.children.length===1&&$.children[0].type==="text"&&(J===$.url||"mailto:"+J===$.url)&&/^[a-z][a-z+.-]+:/i.test($.url)&&!/[\0- <>\u007F]/.test($.url))}dN.peek=zi;function dN($,U,J,G){let q=r8(J),I=q==='"'?"Quote":"Apostrophe",Q=J.createTracker(G),D,X;if(pN($,J)){let V=J.stack;J.stack=[],D=J.enter("autolink");let W=Q.move("<");return W+=Q.move(J.containerPhrasing($,{before:W,after:">",...Q.current()})),W+=Q.move(">"),D(),J.stack=V,W}D=J.enter("link"),X=J.enter("label");let Y=Q.move("[");if(Y+=Q.move(J.containerPhrasing($,{before:Y,after:"](",...Q.current()})),Y+=Q.move("]("),X(),!$.url&&$.title||/[\0- \u007F]/.test($.url))X=J.enter("destinationLiteral"),Y+=Q.move("<"),Y+=Q.move(J.safe($.url,{before:Y,after:">",...Q.current()})),Y+=Q.move(">");else X=J.enter("destinationRaw"),Y+=Q.move(J.safe($.url,{before:Y,after:$.title?" ":")",...Q.current()}));if(X(),$.title)X=J.enter(`title${I}`),Y+=Q.move(" "+q),Y+=Q.move(J.safe($.title,{before:Y,after:q,...Q.current()})),Y+=Q.move(q),X();return Y+=Q.move(")"),D(),Y}function zi($,U,J){return pN($,J)?"<":"["}nN.peek=Ai;function nN($,U,J,G){let q=$.referenceType,I=J.enter("linkReference"),Q=J.enter("label"),D=J.createTracker(G),X=D.move("["),Y=J.containerPhrasing($,{before:X,after:"]",...D.current()});X+=D.move(Y+"]["),Q();let V=J.stack;J.stack=[],Q=J.enter("reference");let W=J.safe(J.associationId($),{before:X,after:"]",...D.current()});if(Q(),J.stack=V,I(),q==="full"||!Y||Y!==W)X+=D.move(W+"]");else if(q==="shortcut")X=X.slice(0,-1);else X+=D.move("]");return X}function Ai(){return"["}function p8($){let U=$.options.bullet||"*";if(U!=="*"&&U!=="+"&&U!=="-")throw Error("Cannot serialize items with `"+U+"` for `options.bullet`, expected `*`, `+`, or `-`");return U}function oB($){let U=p8($),J=$.options.bulletOther;if(!J)return U==="*"?"-":"*";if(J!=="*"&&J!=="+"&&J!=="-")throw Error("Cannot serialize items with `"+J+"` for `options.bulletOther`, expected `*`, `+`, or `-`");if(J===U)throw Error("Expected `bullet` (`"+U+"`) and `bulletOther` (`"+J+"`) to be different");return J}function aB($){let U=$.options.bulletOrdered||".";if(U!=="."&&U!==")")throw Error("Cannot serialize items with `"+U+"` for `options.bulletOrdered`, expected `.` or `)`");return U}function xX($){let U=$.options.rule||"*";if(U!=="*"&&U!=="-"&&U!=="_")throw Error("Cannot serialize rules with `"+U+"` for `options.rule`, expected `*`, `-`, or `_`");return U}function sB($,U,J,G){let q=J.enter("list"),I=J.bulletCurrent,Q=$.ordered?aB(J):p8(J),D=$.ordered?Q==="."?")":".":oB(J),X=U&&J.bulletLastUsed?Q===J.bulletLastUsed:!1;if(!$.ordered){let V=$.children?$.children[0]:void 0;if((Q==="*"||Q==="-")&&V&&(!V.children||!V.children[0])&&J.stack[J.stack.length-1]==="list"&&J.stack[J.stack.length-2]==="listItem"&&J.stack[J.stack.length-3]==="list"&&J.stack[J.stack.length-4]==="listItem"&&J.indexStack[J.indexStack.length-1]===0&&J.indexStack[J.indexStack.length-2]===0&&J.indexStack[J.indexStack.length-3]===0)X=!0;if(xX(J)===Q&&V){let W=-1;while(++W<$.children.length){let O=$.children[W];if(O&&O.type==="listItem"&&O.children&&O.children[0]&&O.children[0].type==="thematicBreak"){X=!0;break}}}}if(X)Q=D;J.bulletCurrent=Q;let Y=J.containerFlow($,G);return J.bulletLastUsed=Q,J.bulletCurrent=I,q(),Y}function tB($){let U=$.options.listItemIndent||"one";if(U!=="tab"&&U!=="one"&&U!=="mixed")throw Error("Cannot serialize items with `"+U+"` for `options.listItemIndent`, expected `tab`, `one`, or `mixed`");return U}function eB($,U,J,G){let q=tB(J),I=J.bulletCurrent||p8(J);if(U&&U.type==="list"&&U.ordered)I=(typeof U.start==="number"&&U.start>-1?U.start:1)+(J.options.incrementListMarker===!1?0:U.children.indexOf($))+I;let Q=I.length+1;if(q==="tab"||q==="mixed"&&(U&&U.type==="list"&&U.spread||$.spread))Q=Math.ceil(Q/4)*4;let D=J.createTracker(G);D.move(I+" ".repeat(Q-I.length)),D.shift(Q);let X=J.enter("listItem"),Y=J.indentLines(J.containerFlow($,D.current()),V);return X(),Y;function V(W,O,Z){if(O)return(Z?"":" ".repeat(Q))+W;return(Z?I:I+" ".repeat(Q-I.length))+W}}function $S($,U,J,G){let q=J.enter("paragraph"),I=J.enter("phrasing"),Q=J.containerPhrasing($,G);return I(),q(),Q}var cN=i8(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function US($,U,J,G){return($.children.some(function(Q){return cN(Q)})?J.containerPhrasing:J.containerFlow).call(J,$,G)}function JS($){let U=$.options.strong||"*";if(U!=="*"&&U!=="_")throw Error("Cannot serialize strong with `"+U+"` for `options.strong`, expected `*`, or `_`");return U}oN.peek=Ki;function oN($,U,J,G){let q=JS(J),I=J.enter("strong"),Q=J.createTracker(G),D=Q.move(q+q),X=Q.move(J.containerPhrasing($,{after:q,before:D,...Q.current()})),Y=X.charCodeAt(0),V=l8(G.before.charCodeAt(G.before.length-1),Y,q);if(V.inside)X=MU(Y)+X.slice(1);let W=X.charCodeAt(X.length-1),O=l8(G.after.charCodeAt(0),W,q);if(O.inside)X=X.slice(0,-1)+MU(W);let Z=Q.move(q+q);return I(),J.attentionEncodeSurroundingInfo={after:O.outside,before:V.outside},D+X+Z}function Ki($,U,J){return J.options.strong||"*"}function qS($,U,J,G){return J.safe($.value,G)}function GS($){let U=$.options.ruleRepetition||3;if(U<3)throw Error("Cannot serialize rules with repetition `"+U+"` for `options.ruleRepetition`, expected `3` or more");return U}function IS($,U,J){let G=(xX(J)+(J.options.ruleSpaces?" ":"")).repeat(GS(J));return J.options.ruleSpaces?G.slice(0,-1):G}var QS={blockquote:yB,break:xN,code:lB,definition:iB,emphasis:fN,hardBreak:xN,heading:cB,html:hN,image:rN,imageReference:lN,inlineCode:iN,link:dN,linkReference:nN,list:sB,listItem:eB,paragraph:$S,root:US,strong:oN,text:qS,thematicBreak:IS};var DS=[gi];function gi($,U,J,G){if(U.type==="code"&&i4(U,G)&&($.type==="list"||$.type===U.type&&i4($,G)))return!1;if("spread"in J&&typeof J.spread==="boolean"){if($.type==="paragraph"&&($.type===U.type||U.type==="definition"||U.type==="heading"&&kX(U,G)))return;return J.spread?1:0}}var DG=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"],XS=[{character:"\t",after:"[\\r\\n]",inConstruct:"phrasing"},{character:"\t",before:"[\\r\\n]",inConstruct:"phrasing"},{character:"\t",inConstruct:["codeFencedLangGraveAccent","codeFencedLangTilde"]},{character:"\r",inConstruct:["codeFencedLangGraveAccent","codeFencedLangTilde","codeFencedMetaGraveAccent","codeFencedMetaTilde","destinationLiteral","headingAtx"]},{character:`
|
|
493
|
+
`,inConstruct:["codeFencedLangGraveAccent","codeFencedLangTilde","codeFencedMetaGraveAccent","codeFencedMetaTilde","destinationLiteral","headingAtx"]},{character:" ",after:"[\\r\\n]",inConstruct:"phrasing"},{character:" ",before:"[\\r\\n]",inConstruct:"phrasing"},{character:" ",inConstruct:["codeFencedLangGraveAccent","codeFencedLangTilde"]},{character:"!",after:"\\[",inConstruct:"phrasing",notInConstruct:DG},{character:'"',inConstruct:"titleQuote"},{atBreak:!0,character:"#"},{character:"#",inConstruct:"headingAtx",after:`(?:[\r
|
|
494
|
+
]|$)`},{character:"&",after:"[#A-Za-z]",inConstruct:"phrasing"},{character:"'",inConstruct:"titleApostrophe"},{character:"(",inConstruct:"destinationRaw"},{before:"\\]",character:"(",inConstruct:"phrasing",notInConstruct:DG},{atBreak:!0,before:"\\d+",character:")"},{character:")",inConstruct:"destinationRaw"},{atBreak:!0,character:"*",after:`(?:[ \r
|
|
495
|
+
*])`},{character:"*",inConstruct:"phrasing",notInConstruct:DG},{atBreak:!0,character:"+",after:`(?:[ \r
|
|
118
496
|
])`},{atBreak:!0,character:"-",after:`(?:[ \r
|
|
119
497
|
-])`},{atBreak:!0,before:"\\d+",character:".",after:`(?:[ \r
|
|
120
|
-
]|$)`},{atBreak:!0,character:"<",after:"[!/?A-Za-z]"},{character:"<",after:"[!/?A-Za-z]",inConstruct:"phrasing",notInConstruct
|
|
121
|
-
`)&&
|
|
498
|
+
]|$)`},{atBreak:!0,character:"<",after:"[!/?A-Za-z]"},{character:"<",after:"[!/?A-Za-z]",inConstruct:"phrasing",notInConstruct:DG},{character:"<",inConstruct:"destinationLiteral"},{atBreak:!0,character:"="},{atBreak:!0,character:">"},{character:">",inConstruct:"destinationLiteral"},{atBreak:!0,character:"["},{character:"[",inConstruct:"phrasing",notInConstruct:DG},{character:"[",inConstruct:["label","reference"]},{character:"\\",after:"[\\r\\n]",inConstruct:"phrasing"},{character:"]",inConstruct:["label","reference"]},{atBreak:!0,character:"_"},{character:"_",inConstruct:"phrasing",notInConstruct:DG},{atBreak:!0,character:"`"},{character:"`",inConstruct:["codeFencedLangGraveAccent","codeFencedMetaGraveAccent"]},{character:"`",inConstruct:"phrasing",notInConstruct:DG},{atBreak:!0,character:"~"}];function YS($){if($.label||!$.identifier)return $.label||"";return CX($.identifier)}function VS($){if(!$._compiled){let U=($.atBreak?"[\\r\\n][\\t ]*":"")+($.before?"(?:"+$.before+")":"");$._compiled=new RegExp((U?"("+U+")":"")+(/[|\\{}()[\]^$+*?.-]/.test($.character)?"\\":"")+$.character+($.after?"(?:"+$.after+")":""),"g")}return $._compiled}function WS($,U,J){let G=U.indexStack,q=$.children||[],I=[],Q=-1,D=J.before,X;G.push(-1);let Y=U.createTracker(J);while(++Q<q.length){let V=q[Q],W;if(G[G.length-1]=Q,Q+1<q.length){let M=U.handle.handlers[q[Q+1].type];if(M&&M.peek)M=M.peek;W=M?M(q[Q+1],$,U,{before:"",after:"",...Y.current()}).charAt(0):""}else W=J.after;if(I.length>0&&(D==="\r"||D===`
|
|
499
|
+
`)&&V.type==="html")I[I.length-1]=I[I.length-1].replace(/(\r?\n|\r)$/," "),D=" ",Y=U.createTracker(J),Y.move(I.join(""));let O=U.handle(V,$,U,{...Y.current(),after:W,before:D});if(X&&X===O.slice(0,1))O=MU(X.charCodeAt(0))+O.slice(1);let Z=U.attentionEncodeSurroundingInfo;if(U.attentionEncodeSurroundingInfo=void 0,X=void 0,Z){if(I.length>0&&Z.before&&D===I[I.length-1].slice(-1))I[I.length-1]=I[I.length-1].slice(0,-1)+MU(D.charCodeAt(0));if(Z.after)X=W}Y.move(O),I.push(O),D=O.slice(-1)}return G.pop(),I.join("")}function OS($,U,J){let G=U.indexStack,q=$.children||[],I=U.createTracker(J),Q=[],D=-1;G.push(-1);while(++D<q.length){let X=q[D];if(G[G.length-1]=D,Q.push(I.move(U.handle(X,$,U,{before:`
|
|
122
500
|
`,after:`
|
|
123
|
-
`,...
|
|
124
|
-
`.repeat(1+
|
|
501
|
+
`,...I.current()}))),X.type!=="list")U.bulletLastUsed=void 0;if(D<q.length-1)Q.push(I.move(ji(X,q[D+1],$,U)))}return G.pop(),Q.join("")}function ji($,U,J,G){let q=G.join.length;while(q--){let I=G.join[q]($,U,J,G);if(I===!0||I===1)break;if(typeof I==="number")return`
|
|
502
|
+
`.repeat(1+I);if(I===!1)return`
|
|
125
503
|
|
|
126
504
|
<!---->
|
|
127
505
|
|
|
128
506
|
`}return`
|
|
129
507
|
|
|
130
|
-
`}var
|
|
508
|
+
`}var Pi=/\r?\n|\r/g;function ZS($,U){let J=[],G=0,q=0,I;while(I=Pi.exec($))Q($.slice(G,I.index)),J.push(I[0]),G=I.index+I[0].length,q++;return Q($.slice(G)),J.join("");function Q(D){J.push(U(D,q,!D))}}function NS($,U,J){let G=(J.before||"")+(U||"")+(J.after||""),q=[],I=[],Q={},D=-1;while(++D<$.unsafe.length){let V=$.unsafe[D];if(!vX($.stack,V))continue;let W=$.compilePattern(V),O;while(O=W.exec(G)){let Z="before"in V||Boolean(V.atBreak),M="after"in V,w=O.index+(Z?O[1].length:0);if(q.includes(w)){if(Q[w].before&&!Z)Q[w].before=!1;if(Q[w].after&&!M)Q[w].after=!1}else q.push(w),Q[w]={before:Z,after:M}}}q.sort(Bi);let X=J.before?J.before.length:0,Y=G.length-(J.after?J.after.length:0);D=-1;while(++D<q.length){let V=q[D];if(V<X||V>=Y)continue;if(V+1<Y&&q[D+1]===V+1&&Q[V].after&&!Q[V+1].before&&!Q[V+1].after||q[D-1]===V-1&&Q[V].before&&!Q[V-1].before&&!Q[V-1].after)continue;if(X!==V)I.push(RS(G.slice(X,V),"\\"));if(X=V,/[!-/:-@[-`{-~]/.test(G.charAt(V))&&(!J.encode||!J.encode.includes(G.charAt(V))))I.push("\\");else I.push(MU(G.charCodeAt(V))),X++}return I.push(RS(G.slice(X,Y),J.after)),I.join("")}function Bi($,U){return $-U}function RS($,U){let J=/\\(?=[!-/:-@[-`{-~])/g,G=[],q=[],I=$+U,Q=-1,D=0,X;while(X=J.exec(I))G.push(X.index);while(++Q<G.length){if(D!==G[Q])q.push($.slice(D,G[Q]));q.push("\\"),D=G[Q]}return q.push($.slice(D)),q.join("")}function wS($){let U=$||{},J=U.now||{},G=U.lineShift||0,q=J.line||1,I=J.column||1;return{move:X,current:Q,shift:D};function Q(){return{now:{line:q,column:I},lineShift:G}}function D(Y){G+=Y}function X(Y){let V=Y||"",W=V.split(/\r?\n|\r/g),O=W[W.length-1];return q+=W.length-1,I=W.length===1?I+O.length:1+O.length+G,V}}function aN($,U){let J=U||{},G={associationId:YS,containerPhrasing:Ci,containerFlow:_i,createTracker:wS,compilePattern:VS,enter:I,handlers:{...QS},handle:void 0,indentLines:ZS,indexStack:[],join:[...DS],options:{},safe:vi,stack:[],unsafe:[...XS]};if(kN(G,J),G.options.tightDefinitions)G.join.push(Ei);G.handle=xB("type",{invalid:Si,unknown:Li,handlers:G.handlers});let q=G.handle($,void 0,G,{before:`
|
|
131
509
|
`,after:`
|
|
132
|
-
`,now:{line:1,column:1},lineShift:0});if(
|
|
133
|
-
`;return X;function Y(U){return G.stack.push(U),Q;function Q(){G.stack.pop()}}}function bz(q){throw Error("Cannot handle value `"+q+"`, expected node")}function Iz(q){throw Error("Cannot handle unknown node `"+q.type+"`")}function gz(q,$){if(q.type==="definition"&&q.type===$.type)return 0}function vz(q,$){return W8(q,this,$)}function yz(q,$){return H8(q,this,$)}function hz(q,$){return K8(this,q,$)}function L3(q){let $=this;$.compiler=J;function J(G){return Y2(G,{...$.data("settings"),...q,extensions:$.data("toMarkdownExtensions")||[]})}}function U2(q){if(q)throw q}var _3=r3(S8(),1);function Z$(q){if(typeof q!=="object"||q===null)return!1;let $=Object.getPrototypeOf(q);return($===null||$===Object.prototype||Object.getPrototypeOf($)===null)&&!(Symbol.toStringTag in q)&&!(Symbol.iterator in q)}function Q2(){let q=[],$={run:J,use:G};return $;function J(...X){let Y=-1,U=X.pop();if(typeof U!=="function")throw TypeError("Expected function as last argument, not "+U);Q(null,...X);function Q(V,...W){let H=q[++Y],z=-1;if(V){U(V);return}while(++z<X.length)if(W[z]===null||W[z]===void 0)W[z]=X[z];if(X=W,H)P8(H,Q)(...W);else U(null,...W)}}function G(X){if(typeof X!=="function")throw TypeError("Expected `middelware` to be a function, not "+X);return q.push(X),$}}function P8(q,$){let J;return G;function G(...U){let Q=q.length>U.length,V;if(Q)U.push(X);try{V=q.apply(this,U)}catch(W){let H=W;if(Q&&J)throw H;return X(H)}if(!Q)if(V&&V.then&&typeof V.then==="function")V.then(Y,X);else if(V instanceof Error)X(V);else Y(V)}function X(U,...Q){if(!J)J=!0,$(U,...Q)}function Y(U){X(null,U)}}class Oq extends Error{constructor(q,$,J){super();if(typeof $==="string")J=$,$=void 0;let G="",X={},Y=!1;if($)if("line"in $&&"column"in $)X={place:$};else if("start"in $&&"end"in $)X={place:$};else if("type"in $)X={ancestors:[$],place:$.position};else X={...$};if(typeof q==="string")G=q;else if(!X.cause&&q)Y=!0,G=q.message,X.cause=q;if(!X.ruleId&&!X.source&&typeof J==="string"){let Q=J.indexOf(":");if(Q===-1)X.ruleId=J;else X.source=J.slice(0,Q),X.ruleId=J.slice(Q+1)}if(!X.place&&X.ancestors&&X.ancestors){let Q=X.ancestors[X.ancestors.length-1];if(Q)X.place=Q.position}let U=X.place&&"start"in X.place?X.place.start:X.place;this.ancestors=X.ancestors||void 0,this.cause=X.cause||void 0,this.column=U?U.column:void 0,this.fatal=void 0,this.file="",this.message=G,this.line=U?U.line:void 0,this.name=Z1(X.place)||"1:1",this.place=X.place||void 0,this.reason=this.message,this.ruleId=X.ruleId||void 0,this.source=X.source||void 0,this.stack=Y&&X.cause&&typeof X.cause.stack==="string"?X.cause.stack:"",this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}}Oq.prototype.file="";Oq.prototype.name="";Oq.prototype.reason="";Oq.prototype.message="";Oq.prototype.stack="";Oq.prototype.column=void 0;Oq.prototype.line=void 0;Oq.prototype.ancestors=void 0;Oq.prototype.cause=void 0;Oq.prototype.fatal=void 0;Oq.prototype.place=void 0;Oq.prototype.ruleId=void 0;Oq.prototype.source=void 0;import{default as oq}from"path";import{default as L8}from"process";import{fileURLToPath as Z8}from"url";function C3(q){return Boolean(q!==null&&typeof q==="object"&&"href"in q&&q.href&&"protocol"in q&&q.protocol&&q.auth===void 0)}var V2=["history","path","basename","stem","extname","dirname"];class E3{constructor(q){let $;if(!q)$={};else if(C3(q))$={path:q};else if(typeof q==="string"||xz(q))$={value:q};else $=q;this.cwd="cwd"in $?"":L8.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let J=-1;while(++J<V2.length){let X=V2[J];if(X in $&&$[X]!==void 0&&$[X]!==null)this[X]=X==="history"?[...$[X]]:$[X]}let G;for(G in $)if(!V2.includes(G))this[G]=$[G]}get basename(){return typeof this.path==="string"?oq.basename(this.path):void 0}set basename(q){H2(q,"basename"),W2(q,"basename"),this.path=oq.join(this.dirname||"",q)}get dirname(){return typeof this.path==="string"?oq.dirname(this.path):void 0}set dirname(q){C8(this.basename,"dirname"),this.path=oq.join(q||"",this.basename)}get extname(){return typeof this.path==="string"?oq.extname(this.path):void 0}set extname(q){if(W2(q,"extname"),C8(this.dirname,"extname"),q){if(q.codePointAt(0)!==46)throw Error("`extname` must start with `.`");if(q.includes(".",1))throw Error("`extname` cannot contain multiple dots")}this.path=oq.join(this.dirname,this.stem+(q||""))}get path(){return this.history[this.history.length-1]}set path(q){if(C3(q))q=Z8(q);if(H2(q,"path"),this.path!==q)this.history.push(q)}get stem(){return typeof this.path==="string"?oq.basename(this.path,this.extname):void 0}set stem(q){H2(q,"stem"),W2(q,"stem"),this.path=oq.join(this.dirname||"",q+(this.extname||""))}fail(q,$,J){let G=this.message(q,$,J);throw G.fatal=!0,G}info(q,$,J){let G=this.message(q,$,J);return G.fatal=void 0,G}message(q,$,J){let G=new Oq(q,$,J);if(this.path)G.name=this.path+":"+G.name,G.file=this.path;return G.fatal=!1,this.messages.push(G),G}toString(q){if(this.value===void 0)return"";if(typeof this.value==="string")return this.value;return new TextDecoder(q||void 0).decode(this.value)}}function W2(q,$){if(q&&q.includes(oq.sep))throw Error("`"+$+"` cannot be a path: did not expect `"+oq.sep+"`")}function H2(q,$){if(!q)throw Error("`"+$+"` cannot be empty")}function C8(q,$){if(!q)throw Error("Setting `"+$+"` requires `path` to be set too")}function xz(q){return Boolean(q&&typeof q==="object"&&"byteLength"in q&&"byteOffset"in q)}var E8=function(q){let G=this.constructor.prototype,X=G[q],Y=function(){return X.apply(Y,arguments)};return Object.setPrototypeOf(Y,G),Y};var mz={}.hasOwnProperty;class D2 extends E8{constructor(){super("copy");this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=Q2()}copy(){let q=new D2,$=-1;while(++$<this.attachers.length){let J=this.attachers[$];q.use(...J)}return q.data(_3.default(!0,{},this.namespace)),q}data(q,$){if(typeof q==="string"){if(arguments.length===2)return K2("data",this.frozen),this.namespace[q]=$,this;return mz.call(this.namespace,q)&&this.namespace[q]||void 0}if(q)return K2("data",this.frozen),this.namespace=q,this;return this.namespace}freeze(){if(this.frozen)return this;let q=this;while(++this.freezeIndex<this.attachers.length){let[$,...J]=this.attachers[this.freezeIndex];if(J[0]===!1)continue;if(J[0]===!0)J[0]=void 0;let G=$.call(q,...J);if(typeof G==="function")this.transformers.use(G)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(q){this.freeze();let $=T3(q),J=this.parser||this.Parser;return z2("parse",J),J(String($),$)}process(q,$){let J=this;return this.freeze(),z2("process",this.parser||this.Parser),M2("process",this.compiler||this.Compiler),$?G(void 0,$):new Promise(G);function G(X,Y){let U=T3(q),Q=J.parse(U);J.run(Q,U,function(W,H,z){if(W||!H||!z)return V(W);let B=H,D=J.stringify(B,z);if(fz(D))z.value=D;else z.result=D;V(W,z)});function V(W,H){if(W||!H)Y(W);else if(X)X(H);else R($,"`done` is defined if `resolve` is not"),$(void 0,H)}}}processSync(q){let $=!1,J;return this.freeze(),z2("processSync",this.parser||this.Parser),M2("processSync",this.compiler||this.Compiler),this.process(q,G),_8("processSync","process",$),R(J,"we either bailed on an error or have a tree"),J;function G(X,Y){$=!0,U2(X),J=Y}}run(q,$,J){T8(q),this.freeze();let G=this.transformers;if(!J&&typeof $==="function")J=$,$=void 0;return J?X(void 0,J):new Promise(X);function X(Y,U){R(typeof $!=="function","`file` can\u2019t be a `done` anymore, we checked");let Q=T3($);G.run(q,Q,V);function V(W,H,z){let B=H||q;if(W)U(W);else if(Y)Y(B);else R(J,"`done` is defined if `resolve` is not"),J(void 0,B,z)}}}runSync(q,$){let J=!1,G;return this.run(q,$,X),_8("runSync","run",J),R(G,"we either bailed on an error or have a tree"),G;function X(Y,U){U2(Y),G=U,J=!0}}stringify(q,$){this.freeze();let J=T3($),G=this.compiler||this.Compiler;return M2("stringify",G),T8(q),G(q,J)}use(q,...$){let J=this.attachers,G=this.namespace;if(K2("use",this.frozen),q===null||q===void 0);else if(typeof q==="function")Q(q,$);else if(typeof q==="object")if(Array.isArray(q))U(q);else Y(q);else throw TypeError("Expected usable value, not `"+q+"`");return this;function X(V){if(typeof V==="function")Q(V,[]);else if(typeof V==="object")if(Array.isArray(V)){let[W,...H]=V;Q(W,H)}else Y(V);else throw TypeError("Expected usable value, not `"+V+"`")}function Y(V){if(!("plugins"in V)&&!("settings"in V))throw Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");if(U(V.plugins),V.settings)G.settings=_3.default(!0,G.settings,V.settings)}function U(V){let W=-1;if(V===null||V===void 0);else if(Array.isArray(V))while(++W<V.length){let H=V[W];X(H)}else throw TypeError("Expected a list of plugins, not `"+V+"`")}function Q(V,W){let H=-1,z=-1;while(++H<J.length)if(J[H][0]===V){z=H;break}if(z===-1)J.push([V,...W]);else if(W.length>0){let[B,...D]=W,O=J[z][1];if(Z$(O)&&Z$(B))B=_3.default(!0,O,B);J[z]=[V,B,...D]}}}}var B2=new D2().freeze();function z2(q,$){if(typeof $!=="function")throw TypeError("Cannot `"+q+"` without `parser`")}function M2(q,$){if(typeof $!=="function")throw TypeError("Cannot `"+q+"` without `compiler`")}function K2(q,$){if($)throw Error("Cannot call `"+q+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function T8(q){if(!Z$(q)||typeof q.type!=="string")throw TypeError("Expected node, got `"+q+"`")}function _8(q,$,J){if(!J)throw Error("`"+q+"` finished async. Use `"+$+"` instead")}function T3(q){return kz(q)?q:new E3(q)}function kz(q){return Boolean(q&&typeof q==="object"&&"message"in q&&"messages"in q)}function fz(q){return typeof q==="string"||uz(q)}function uz(q){return Boolean(q&&typeof q==="object"&&"byteLength"in q&&"byteOffset"in q)}var b3=B2().use(F3).use(L3).freeze();var ML=b3();var KL=new J3({gfm:!0,breaks:!0});/*! js-yaml 4.1.1 https://github.com/nodeca/js-yaml @license MIT */function d8(q){return typeof q>"u"||q===null}function lz(q){return typeof q==="object"&&q!==null}function rz(q){if(Array.isArray(q))return q;else if(d8(q))return[];return[q]}function iz(q,$){var J,G,X,Y;if($){Y=Object.keys($);for(J=0,G=Y.length;J<G;J+=1)X=Y[J],q[X]=$[X]}return q}function dz(q,$){var J="",G;for(G=0;G<$;G+=1)J+=q;return J}function cz(q){return q===0&&Number.NEGATIVE_INFINITY===1/q}var nz=d8,oz=lz,az=rz,sz=dz,tz=cz,ez=iz,Bq={isNothing:nz,isObject:oz,toArray:az,repeat:sz,isNegativeZero:tz,extend:ez};function c8(q,$){var J="",G=q.reason||"(unknown reason)";if(!q.mark)return G;if(q.mark.name)J+='in "'+q.mark.name+'" ';if(J+="("+(q.mark.line+1)+":"+(q.mark.column+1)+")",!$&&q.mark.snippet)J+=`
|
|
134
|
-
|
|
135
|
-
`+q.mark.snippet;return G+" "+J}function E$(q,$){if(Error.call(this),this.name="YAMLException",this.reason=q,this.mark=$,this.message=c8(this,!1),Error.captureStackTrace)Error.captureStackTrace(this,this.constructor);else this.stack=Error().stack||""}E$.prototype=Object.create(Error.prototype);E$.prototype.constructor=E$;E$.prototype.toString=function($){return this.name+": "+c8(this,$)};var bq=E$;function R2(q,$,J,G,X){var Y="",U="",Q=Math.floor(X/2)-1;if(G-$>Q)Y=" ... ",$=G-Q+Y.length;if(J-G>Q)U=" ...",J=G+Q-U.length;return{str:Y+q.slice($,J).replace(/\t/g,"\u2192")+U,pos:G-$+Y.length}}function w2(q,$){return Bq.repeat(" ",$-q.length)+q}function qM(q,$){if($=Object.create($||null),!q.buffer)return null;if(!$.maxLength)$.maxLength=79;if(typeof $.indent!=="number")$.indent=1;if(typeof $.linesBefore!=="number")$.linesBefore=3;if(typeof $.linesAfter!=="number")$.linesAfter=2;var J=/\r?\n|\r|\0/g,G=[0],X=[],Y,U=-1;while(Y=J.exec(q.buffer))if(X.push(Y.index),G.push(Y.index+Y[0].length),q.position<=Y.index&&U<0)U=G.length-2;if(U<0)U=G.length-1;var Q="",V,W,H=Math.min(q.line+$.linesAfter,X.length).toString().length,z=$.maxLength-($.indent+H+3);for(V=1;V<=$.linesBefore;V++){if(U-V<0)break;W=R2(q.buffer,G[U-V],X[U-V],q.position-(G[U]-G[U-V]),z),Q=Bq.repeat(" ",$.indent)+w2((q.line-V+1).toString(),H)+" | "+W.str+`
|
|
136
|
-
`+Q}W=R2(q.buffer,G[U],X[U],q.position,z),Q+=Bq.repeat(" ",$.indent)+w2((q.line+1).toString(),H)+" | "+W.str+`
|
|
137
|
-
`,Q+=Bq.repeat("-",$.indent+H+3+W.pos)+`^
|
|
138
|
-
`;for(V=1;V<=$.linesAfter;V++){if(U+V>=X.length)break;W=R2(q.buffer,G[U+V],X[U+V],q.position-(G[U]-G[U+V]),z),Q+=Bq.repeat(" ",$.indent)+w2((q.line+V+1).toString(),H)+" | "+W.str+`
|
|
139
|
-
`}return Q.replace(/\n$/,"")}var $M=qM,JM=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],GM=["scalar","sequence","mapping"];function XM(q){var $={};if(q!==null)Object.keys(q).forEach(function(J){q[J].forEach(function(G){$[String(G)]=J})});return $}function YM(q,$){if($=$||{},Object.keys($).forEach(function(J){if(JM.indexOf(J)===-1)throw new bq('Unknown option "'+J+'" is met in definition of "'+q+'" YAML type.')}),this.options=$,this.tag=q,this.kind=$.kind||null,this.resolve=$.resolve||function(){return!0},this.construct=$.construct||function(J){return J},this.instanceOf=$.instanceOf||null,this.predicate=$.predicate||null,this.represent=$.represent||null,this.representName=$.representName||null,this.defaultStyle=$.defaultStyle||null,this.multi=$.multi||!1,this.styleAliases=XM($.styleAliases||null),GM.indexOf(this.kind)===-1)throw new bq('Unknown kind "'+this.kind+'" is specified for "'+q+'" YAML type.')}var Pq=YM;function b8(q,$){var J=[];return q[$].forEach(function(G){var X=J.length;J.forEach(function(Y,U){if(Y.tag===G.tag&&Y.kind===G.kind&&Y.multi===G.multi)X=U}),J[X]=G}),J}function UM(){var q={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}},$,J;function G(X){if(X.multi)q.multi[X.kind].push(X),q.multi.fallback.push(X);else q[X.kind][X.tag]=q.fallback[X.tag]=X}for($=0,J=arguments.length;$<J;$+=1)arguments[$].forEach(G);return q}function O2(q){return this.extend(q)}O2.prototype.extend=function($){var J=[],G=[];if($ instanceof Pq)G.push($);else if(Array.isArray($))G=G.concat($);else if($&&(Array.isArray($.implicit)||Array.isArray($.explicit))){if($.implicit)J=J.concat($.implicit);if($.explicit)G=G.concat($.explicit)}else throw new bq("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");J.forEach(function(Y){if(!(Y instanceof Pq))throw new bq("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(Y.loadKind&&Y.loadKind!=="scalar")throw new bq("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(Y.multi)throw new bq("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}),G.forEach(function(Y){if(!(Y instanceof Pq))throw new bq("Specified list of YAML types (or a single Type object) contains a non-Type object.")});var X=Object.create(O2.prototype);return X.implicit=(this.implicit||[]).concat(J),X.explicit=(this.explicit||[]).concat(G),X.compiledImplicit=b8(X,"implicit"),X.compiledExplicit=b8(X,"explicit"),X.compiledTypeMap=UM(X.compiledImplicit,X.compiledExplicit),X};var QM=O2,VM=new Pq("tag:yaml.org,2002:str",{kind:"scalar",construct:function(q){return q!==null?q:""}}),WM=new Pq("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(q){return q!==null?q:[]}}),HM=new Pq("tag:yaml.org,2002:map",{kind:"mapping",construct:function(q){return q!==null?q:{}}}),zM=new QM({explicit:[VM,WM,HM]});function MM(q){if(q===null)return!0;var $=q.length;return $===1&&q==="~"||$===4&&(q==="null"||q==="Null"||q==="NULL")}function KM(){return null}function DM(q){return q===null}var BM=new Pq("tag:yaml.org,2002:null",{kind:"scalar",resolve:MM,construct:KM,predicate:DM,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"},empty:function(){return""}},defaultStyle:"lowercase"});function RM(q){if(q===null)return!1;var $=q.length;return $===4&&(q==="true"||q==="True"||q==="TRUE")||$===5&&(q==="false"||q==="False"||q==="FALSE")}function wM(q){return q==="true"||q==="True"||q==="TRUE"}function FM(q){return Object.prototype.toString.call(q)==="[object Boolean]"}var OM=new Pq("tag:yaml.org,2002:bool",{kind:"scalar",resolve:RM,construct:wM,predicate:FM,represent:{lowercase:function(q){return q?"true":"false"},uppercase:function(q){return q?"TRUE":"FALSE"},camelcase:function(q){return q?"True":"False"}},defaultStyle:"lowercase"});function AM(q){return 48<=q&&q<=57||65<=q&&q<=70||97<=q&&q<=102}function NM(q){return 48<=q&&q<=55}function jM(q){return 48<=q&&q<=57}function SM(q){if(q===null)return!1;var $=q.length,J=0,G=!1,X;if(!$)return!1;if(X=q[J],X==="-"||X==="+")X=q[++J];if(X==="0"){if(J+1===$)return!0;if(X=q[++J],X==="b"){J++;for(;J<$;J++){if(X=q[J],X==="_")continue;if(X!=="0"&&X!=="1")return!1;G=!0}return G&&X!=="_"}if(X==="x"){J++;for(;J<$;J++){if(X=q[J],X==="_")continue;if(!AM(q.charCodeAt(J)))return!1;G=!0}return G&&X!=="_"}if(X==="o"){J++;for(;J<$;J++){if(X=q[J],X==="_")continue;if(!NM(q.charCodeAt(J)))return!1;G=!0}return G&&X!=="_"}}if(X==="_")return!1;for(;J<$;J++){if(X=q[J],X==="_")continue;if(!jM(q.charCodeAt(J)))return!1;G=!0}if(!G||X==="_")return!1;return!0}function PM(q){var $=q,J=1,G;if($.indexOf("_")!==-1)$=$.replace(/_/g,"");if(G=$[0],G==="-"||G==="+"){if(G==="-")J=-1;$=$.slice(1),G=$[0]}if($==="0")return 0;if(G==="0"){if($[1]==="b")return J*parseInt($.slice(2),2);if($[1]==="x")return J*parseInt($.slice(2),16);if($[1]==="o")return J*parseInt($.slice(2),8)}return J*parseInt($,10)}function LM(q){return Object.prototype.toString.call(q)==="[object Number]"&&(q%1===0&&!Bq.isNegativeZero(q))}var ZM=new Pq("tag:yaml.org,2002:int",{kind:"scalar",resolve:SM,construct:PM,predicate:LM,represent:{binary:function(q){return q>=0?"0b"+q.toString(2):"-0b"+q.toString(2).slice(1)},octal:function(q){return q>=0?"0o"+q.toString(8):"-0o"+q.toString(8).slice(1)},decimal:function(q){return q.toString(10)},hexadecimal:function(q){return q>=0?"0x"+q.toString(16).toUpperCase():"-0x"+q.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),CM=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function EM(q){if(q===null)return!1;if(!CM.test(q)||q[q.length-1]==="_")return!1;return!0}function TM(q){var $,J;if($=q.replace(/_/g,"").toLowerCase(),J=$[0]==="-"?-1:1,"+-".indexOf($[0])>=0)$=$.slice(1);if($===".inf")return J===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY;else if($===".nan")return NaN;return J*parseFloat($,10)}var _M=/^[-+]?[0-9]+e/;function bM(q,$){var J;if(isNaN(q))switch($){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===q)switch($){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===q)switch($){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(Bq.isNegativeZero(q))return"-0.0";return J=q.toString(10),_M.test(J)?J.replace("e",".e"):J}function IM(q){return Object.prototype.toString.call(q)==="[object Number]"&&(q%1!==0||Bq.isNegativeZero(q))}var gM=new Pq("tag:yaml.org,2002:float",{kind:"scalar",resolve:EM,construct:TM,predicate:IM,represent:bM,defaultStyle:"lowercase"}),vM=zM.extend({implicit:[BM,OM,ZM,gM]}),yM=vM,n8=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),o8=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");function hM(q){if(q===null)return!1;if(n8.exec(q)!==null)return!0;if(o8.exec(q)!==null)return!0;return!1}function xM(q){var $,J,G,X,Y,U,Q,V=0,W=null,H,z,B;if($=n8.exec(q),$===null)$=o8.exec(q);if($===null)throw Error("Date resolve error");if(J=+$[1],G=+$[2]-1,X=+$[3],!$[4])return new Date(Date.UTC(J,G,X));if(Y=+$[4],U=+$[5],Q=+$[6],$[7]){V=$[7].slice(0,3);while(V.length<3)V+="0";V=+V}if($[9]){if(H=+$[10],z=+($[11]||0),W=(H*60+z)*60000,$[9]==="-")W=-W}if(B=new Date(Date.UTC(J,G,X,Y,U,Q,V)),W)B.setTime(B.getTime()-W);return B}function mM(q){return q.toISOString()}var kM=new Pq("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:hM,construct:xM,instanceOf:Date,represent:mM});function fM(q){return q==="<<"||q===null}var uM=new Pq("tag:yaml.org,2002:merge",{kind:"scalar",resolve:fM}),P2=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
|
|
140
|
-
\r`;function pM(q){if(q===null)return!1;var $,J,G=0,X=q.length,Y=P2;for(J=0;J<X;J++){if($=Y.indexOf(q.charAt(J)),$>64)continue;if($<0)return!1;G+=6}return G%8===0}function lM(q){var $,J,G=q.replace(/[\r\n=]/g,""),X=G.length,Y=P2,U=0,Q=[];for($=0;$<X;$++){if($%4===0&&$)Q.push(U>>16&255),Q.push(U>>8&255),Q.push(U&255);U=U<<6|Y.indexOf(G.charAt($))}if(J=X%4*6,J===0)Q.push(U>>16&255),Q.push(U>>8&255),Q.push(U&255);else if(J===18)Q.push(U>>10&255),Q.push(U>>2&255);else if(J===12)Q.push(U>>4&255);return new Uint8Array(Q)}function rM(q){var $="",J=0,G,X,Y=q.length,U=P2;for(G=0;G<Y;G++){if(G%3===0&&G)$+=U[J>>18&63],$+=U[J>>12&63],$+=U[J>>6&63],$+=U[J&63];J=(J<<8)+q[G]}if(X=Y%3,X===0)$+=U[J>>18&63],$+=U[J>>12&63],$+=U[J>>6&63],$+=U[J&63];else if(X===2)$+=U[J>>10&63],$+=U[J>>4&63],$+=U[J<<2&63],$+=U[64];else if(X===1)$+=U[J>>2&63],$+=U[J<<4&63],$+=U[64],$+=U[64];return $}function iM(q){return Object.prototype.toString.call(q)==="[object Uint8Array]"}var dM=new Pq("tag:yaml.org,2002:binary",{kind:"scalar",resolve:pM,construct:lM,predicate:iM,represent:rM}),cM=Object.prototype.hasOwnProperty,nM=Object.prototype.toString;function oM(q){if(q===null)return!0;var $=[],J,G,X,Y,U,Q=q;for(J=0,G=Q.length;J<G;J+=1){if(X=Q[J],U=!1,nM.call(X)!=="[object Object]")return!1;for(Y in X)if(cM.call(X,Y))if(!U)U=!0;else return!1;if(!U)return!1;if($.indexOf(Y)===-1)$.push(Y);else return!1}return!0}function aM(q){return q!==null?q:[]}var sM=new Pq("tag:yaml.org,2002:omap",{kind:"sequence",resolve:oM,construct:aM}),tM=Object.prototype.toString;function eM(q){if(q===null)return!0;var $,J,G,X,Y,U=q;Y=Array(U.length);for($=0,J=U.length;$<J;$+=1){if(G=U[$],tM.call(G)!=="[object Object]")return!1;if(X=Object.keys(G),X.length!==1)return!1;Y[$]=[X[0],G[X[0]]]}return!0}function qK(q){if(q===null)return[];var $,J,G,X,Y,U=q;Y=Array(U.length);for($=0,J=U.length;$<J;$+=1)G=U[$],X=Object.keys(G),Y[$]=[X[0],G[X[0]]];return Y}var $K=new Pq("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:eM,construct:qK}),JK=Object.prototype.hasOwnProperty;function GK(q){if(q===null)return!0;var $,J=q;for($ in J)if(JK.call(J,$)){if(J[$]!==null)return!1}return!0}function XK(q){return q!==null?q:{}}var YK=new Pq("tag:yaml.org,2002:set",{kind:"mapping",resolve:GK,construct:XK}),a8=yM.extend({implicit:[kM,uM],explicit:[dM,sM,$K,YK]}),_1=Object.prototype.hasOwnProperty,I3=1,s8=2,t8=3,g3=4,F2=1,UK=2,I8=3,QK=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,VK=/[\x85\u2028\u2029]/,WK=/[,\[\]\{\}]/,e8=/^(?:!|!!|![a-z\-]+!)$/i,q7=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function g8(q){return Object.prototype.toString.call(q)}function X1(q){return q===10||q===13}function J0(q){return q===9||q===32}function Iq(q){return q===9||q===32||q===10||q===13}function l0(q){return q===44||q===91||q===93||q===123||q===125}function HK(q){var $;if(48<=q&&q<=57)return q-48;if($=q|32,97<=$&&$<=102)return $-97+10;return-1}function zK(q){if(q===120)return 2;if(q===117)return 4;if(q===85)return 8;return 0}function MK(q){if(48<=q&&q<=57)return q-48;return-1}function v8(q){return q===48?"\x00":q===97?"\x07":q===98?"\b":q===116?"\t":q===9?"\t":q===110?`
|
|
141
|
-
`:q===118?"\v":q===102?"\f":q===114?"\r":q===101?"\x1B":q===32?" ":q===34?'"':q===47?"/":q===92?"\\":q===78?"\x85":q===95?"\xA0":q===76?"\u2028":q===80?"\u2029":""}function KK(q){if(q<=65535)return String.fromCharCode(q);return String.fromCharCode((q-65536>>10)+55296,(q-65536&1023)+56320)}function $7(q,$,J){if($==="__proto__")Object.defineProperty(q,$,{configurable:!0,enumerable:!0,writable:!0,value:J});else q[$]=J}var J7=Array(256),G7=Array(256);for(E1=0;E1<256;E1++)J7[E1]=v8(E1)?1:0,G7[E1]=v8(E1);var E1;function DK(q,$){this.input=q,this.filename=$.filename||null,this.schema=$.schema||a8,this.onWarning=$.onWarning||null,this.legacy=$.legacy||!1,this.json=$.json||!1,this.listener=$.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=q.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.firstTabInLine=-1,this.documents=[]}function X7(q,$){var J={name:q.filename,buffer:q.input.slice(0,-1),position:q.position,line:q.line,column:q.position-q.lineStart};return J.snippet=$M(J),new bq($,J)}function x(q,$){throw X7(q,$)}function v3(q,$){if(q.onWarning)q.onWarning.call(null,X7(q,$))}var y8={YAML:function($,J,G){var X,Y,U;if($.version!==null)x($,"duplication of %YAML directive");if(G.length!==1)x($,"YAML directive accepts exactly one argument");if(X=/^([0-9]+)\.([0-9]+)$/.exec(G[0]),X===null)x($,"ill-formed argument of the YAML directive");if(Y=parseInt(X[1],10),U=parseInt(X[2],10),Y!==1)x($,"unacceptable YAML version of the document");if($.version=G[0],$.checkLineBreaks=U<2,U!==1&&U!==2)v3($,"unsupported YAML version of the document")},TAG:function($,J,G){var X,Y;if(G.length!==2)x($,"TAG directive accepts exactly two arguments");if(X=G[0],Y=G[1],!e8.test(X))x($,"ill-formed tag handle (first argument) of the TAG directive");if(_1.call($.tagMap,X))x($,'there is a previously declared suffix for "'+X+'" tag handle');if(!q7.test(Y))x($,"ill-formed tag prefix (second argument) of the TAG directive");try{Y=decodeURIComponent(Y)}catch(U){x($,"tag prefix is malformed: "+Y)}$.tagMap[X]=Y}};function T1(q,$,J,G){var X,Y,U,Q;if($<J){if(Q=q.input.slice($,J),G){for(X=0,Y=Q.length;X<Y;X+=1)if(U=Q.charCodeAt(X),!(U===9||32<=U&&U<=1114111))x(q,"expected valid JSON character")}else if(QK.test(Q))x(q,"the stream contains non-printable characters");q.result+=Q}}function h8(q,$,J,G){var X,Y,U,Q;if(!Bq.isObject(J))x(q,"cannot merge mappings; the provided source object is unacceptable");X=Object.keys(J);for(U=0,Q=X.length;U<Q;U+=1)if(Y=X[U],!_1.call($,Y))$7($,Y,J[Y]),G[Y]=!0}function r0(q,$,J,G,X,Y,U,Q,V){var W,H;if(Array.isArray(X)){X=Array.prototype.slice.call(X);for(W=0,H=X.length;W<H;W+=1){if(Array.isArray(X[W]))x(q,"nested arrays are not supported inside keys");if(typeof X==="object"&&g8(X[W])==="[object Object]")X[W]="[object Object]"}}if(typeof X==="object"&&g8(X)==="[object Object]")X="[object Object]";if(X=String(X),$===null)$={};if(G==="tag:yaml.org,2002:merge")if(Array.isArray(Y))for(W=0,H=Y.length;W<H;W+=1)h8(q,$,Y[W],J);else h8(q,$,Y,J);else{if(!q.json&&!_1.call(J,X)&&_1.call($,X))q.line=U||q.line,q.lineStart=Q||q.lineStart,q.position=V||q.position,x(q,"duplicated mapping key");$7($,X,Y),delete J[X]}return $}function L2(q){var $=q.input.charCodeAt(q.position);if($===10)q.position++;else if($===13){if(q.position++,q.input.charCodeAt(q.position)===10)q.position++}else x(q,"a line break is expected");q.line+=1,q.lineStart=q.position,q.firstTabInLine=-1}function zq(q,$,J){var G=0,X=q.input.charCodeAt(q.position);while(X!==0){while(J0(X)){if(X===9&&q.firstTabInLine===-1)q.firstTabInLine=q.position;X=q.input.charCodeAt(++q.position)}if($&&X===35)do X=q.input.charCodeAt(++q.position);while(X!==10&&X!==13&&X!==0);if(X1(X)){L2(q),X=q.input.charCodeAt(q.position),G++,q.lineIndent=0;while(X===32)q.lineIndent++,X=q.input.charCodeAt(++q.position)}else break}if(J!==-1&&G!==0&&q.lineIndent<J)v3(q,"deficient indentation");return G}function x3(q){var $=q.position,J;if(J=q.input.charCodeAt($),(J===45||J===46)&&J===q.input.charCodeAt($+1)&&J===q.input.charCodeAt($+2)){if($+=3,J=q.input.charCodeAt($),J===0||Iq(J))return!0}return!1}function Z2(q,$){if($===1)q.result+=" ";else if($>1)q.result+=Bq.repeat(`
|
|
142
|
-
`,$-1)}function BK(q,$,J){var G,X,Y,U,Q,V,W,H,z=q.kind,B=q.result,D;if(D=q.input.charCodeAt(q.position),Iq(D)||l0(D)||D===35||D===38||D===42||D===33||D===124||D===62||D===39||D===34||D===37||D===64||D===96)return!1;if(D===63||D===45){if(X=q.input.charCodeAt(q.position+1),Iq(X)||J&&l0(X))return!1}q.kind="scalar",q.result="",Y=U=q.position,Q=!1;while(D!==0){if(D===58){if(X=q.input.charCodeAt(q.position+1),Iq(X)||J&&l0(X))break}else if(D===35){if(G=q.input.charCodeAt(q.position-1),Iq(G))break}else if(q.position===q.lineStart&&x3(q)||J&&l0(D))break;else if(X1(D))if(V=q.line,W=q.lineStart,H=q.lineIndent,zq(q,!1,-1),q.lineIndent>=$){Q=!0,D=q.input.charCodeAt(q.position);continue}else{q.position=U,q.line=V,q.lineStart=W,q.lineIndent=H;break}if(Q)T1(q,Y,U,!1),Z2(q,q.line-V),Y=U=q.position,Q=!1;if(!J0(D))U=q.position+1;D=q.input.charCodeAt(++q.position)}if(T1(q,Y,U,!1),q.result)return!0;return q.kind=z,q.result=B,!1}function RK(q,$){var J,G,X;if(J=q.input.charCodeAt(q.position),J!==39)return!1;q.kind="scalar",q.result="",q.position++,G=X=q.position;while((J=q.input.charCodeAt(q.position))!==0)if(J===39)if(T1(q,G,q.position,!0),J=q.input.charCodeAt(++q.position),J===39)G=q.position,q.position++,X=q.position;else return!0;else if(X1(J))T1(q,G,X,!0),Z2(q,zq(q,!1,$)),G=X=q.position;else if(q.position===q.lineStart&&x3(q))x(q,"unexpected end of the document within a single quoted scalar");else q.position++,X=q.position;x(q,"unexpected end of the stream within a single quoted scalar")}function wK(q,$){var J,G,X,Y,U,Q;if(Q=q.input.charCodeAt(q.position),Q!==34)return!1;q.kind="scalar",q.result="",q.position++,J=G=q.position;while((Q=q.input.charCodeAt(q.position))!==0)if(Q===34)return T1(q,J,q.position,!0),q.position++,!0;else if(Q===92){if(T1(q,J,q.position,!0),Q=q.input.charCodeAt(++q.position),X1(Q))zq(q,!1,$);else if(Q<256&&J7[Q])q.result+=G7[Q],q.position++;else if((U=zK(Q))>0){X=U,Y=0;for(;X>0;X--)if(Q=q.input.charCodeAt(++q.position),(U=HK(Q))>=0)Y=(Y<<4)+U;else x(q,"expected hexadecimal character");q.result+=KK(Y),q.position++}else x(q,"unknown escape sequence");J=G=q.position}else if(X1(Q))T1(q,J,G,!0),Z2(q,zq(q,!1,$)),J=G=q.position;else if(q.position===q.lineStart&&x3(q))x(q,"unexpected end of the document within a double quoted scalar");else q.position++,G=q.position;x(q,"unexpected end of the stream within a double quoted scalar")}function FK(q,$){var J=!0,G,X,Y,U=q.tag,Q,V=q.anchor,W,H,z,B,D,O=Object.create(null),j,P,L,I;if(I=q.input.charCodeAt(q.position),I===91)H=93,D=!1,Q=[];else if(I===123)H=125,D=!0,Q={};else return!1;if(q.anchor!==null)q.anchorMap[q.anchor]=Q;I=q.input.charCodeAt(++q.position);while(I!==0){if(zq(q,!0,$),I=q.input.charCodeAt(q.position),I===H)return q.position++,q.tag=U,q.anchor=V,q.kind=D?"mapping":"sequence",q.result=Q,!0;else if(!J)x(q,"missed comma between flow collection entries");else if(I===44)x(q,"expected the node content, but found ','");if(P=j=L=null,z=B=!1,I===63){if(W=q.input.charCodeAt(q.position+1),Iq(W))z=B=!0,q.position++,zq(q,!0,$)}if(G=q.line,X=q.lineStart,Y=q.position,i0(q,$,I3,!1,!0),P=q.tag,j=q.result,zq(q,!0,$),I=q.input.charCodeAt(q.position),(B||q.line===G)&&I===58)z=!0,I=q.input.charCodeAt(++q.position),zq(q,!0,$),i0(q,$,I3,!1,!0),L=q.result;if(D)r0(q,Q,O,P,j,L,G,X,Y);else if(z)Q.push(r0(q,null,O,P,j,L,G,X,Y));else Q.push(j);if(zq(q,!0,$),I=q.input.charCodeAt(q.position),I===44)J=!0,I=q.input.charCodeAt(++q.position);else J=!1}x(q,"unexpected end of the stream within a flow collection")}function OK(q,$){var J,G,X=F2,Y=!1,U=!1,Q=$,V=0,W=!1,H,z;if(z=q.input.charCodeAt(q.position),z===124)G=!1;else if(z===62)G=!0;else return!1;q.kind="scalar",q.result="";while(z!==0)if(z=q.input.charCodeAt(++q.position),z===43||z===45)if(F2===X)X=z===43?I8:UK;else x(q,"repeat of a chomping mode identifier");else if((H=MK(z))>=0)if(H===0)x(q,"bad explicit indentation width of a block scalar; it cannot be less than one");else if(!U)Q=$+H-1,U=!0;else x(q,"repeat of an indentation width identifier");else break;if(J0(z)){do z=q.input.charCodeAt(++q.position);while(J0(z));if(z===35)do z=q.input.charCodeAt(++q.position);while(!X1(z)&&z!==0)}while(z!==0){L2(q),q.lineIndent=0,z=q.input.charCodeAt(q.position);while((!U||q.lineIndent<Q)&&z===32)q.lineIndent++,z=q.input.charCodeAt(++q.position);if(!U&&q.lineIndent>Q)Q=q.lineIndent;if(X1(z)){V++;continue}if(q.lineIndent<Q){if(X===I8)q.result+=Bq.repeat(`
|
|
143
|
-
`,Y?1+V:V);else if(X===F2){if(Y)q.result+=`
|
|
144
|
-
`}break}if(G)if(J0(z))W=!0,q.result+=Bq.repeat(`
|
|
145
|
-
`,Y?1+V:V);else if(W)W=!1,q.result+=Bq.repeat(`
|
|
146
|
-
`,V+1);else if(V===0){if(Y)q.result+=" "}else q.result+=Bq.repeat(`
|
|
147
|
-
`,V);else q.result+=Bq.repeat(`
|
|
148
|
-
`,Y?1+V:V);Y=!0,U=!0,V=0,J=q.position;while(!X1(z)&&z!==0)z=q.input.charCodeAt(++q.position);T1(q,J,q.position,!1)}return!0}function x8(q,$){var J,G=q.tag,X=q.anchor,Y=[],U,Q=!1,V;if(q.firstTabInLine!==-1)return!1;if(q.anchor!==null)q.anchorMap[q.anchor]=Y;V=q.input.charCodeAt(q.position);while(V!==0){if(q.firstTabInLine!==-1)q.position=q.firstTabInLine,x(q,"tab characters must not be used in indentation");if(V!==45)break;if(U=q.input.charCodeAt(q.position+1),!Iq(U))break;if(Q=!0,q.position++,zq(q,!0,-1)){if(q.lineIndent<=$){Y.push(null),V=q.input.charCodeAt(q.position);continue}}if(J=q.line,i0(q,$,t8,!1,!0),Y.push(q.result),zq(q,!0,-1),V=q.input.charCodeAt(q.position),(q.line===J||q.lineIndent>$)&&V!==0)x(q,"bad indentation of a sequence entry");else if(q.lineIndent<$)break}if(Q)return q.tag=G,q.anchor=X,q.kind="sequence",q.result=Y,!0;return!1}function AK(q,$,J){var G,X,Y,U,Q,V,W=q.tag,H=q.anchor,z={},B=Object.create(null),D=null,O=null,j=null,P=!1,L=!1,I;if(q.firstTabInLine!==-1)return!1;if(q.anchor!==null)q.anchorMap[q.anchor]=z;I=q.input.charCodeAt(q.position);while(I!==0){if(!P&&q.firstTabInLine!==-1)q.position=q.firstTabInLine,x(q,"tab characters must not be used in indentation");if(G=q.input.charCodeAt(q.position+1),Y=q.line,(I===63||I===58)&&Iq(G)){if(I===63){if(P)r0(q,z,B,D,O,null,U,Q,V),D=O=j=null;L=!0,P=!0,X=!0}else if(P)P=!1,X=!0;else x(q,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line");q.position+=1,I=G}else{if(U=q.line,Q=q.lineStart,V=q.position,!i0(q,J,s8,!1,!0))break;if(q.line===Y){I=q.input.charCodeAt(q.position);while(J0(I))I=q.input.charCodeAt(++q.position);if(I===58){if(I=q.input.charCodeAt(++q.position),!Iq(I))x(q,"a whitespace character is expected after the key-value separator within a block mapping");if(P)r0(q,z,B,D,O,null,U,Q,V),D=O=j=null;L=!0,P=!1,X=!1,D=q.tag,O=q.result}else if(L)x(q,"can not read an implicit mapping pair; a colon is missed");else return q.tag=W,q.anchor=H,!0}else if(L)x(q,"can not read a block mapping entry; a multiline key may not be an implicit key");else return q.tag=W,q.anchor=H,!0}if(q.line===Y||q.lineIndent>$){if(P)U=q.line,Q=q.lineStart,V=q.position;if(i0(q,$,g3,!0,X))if(P)O=q.result;else j=q.result;if(!P)r0(q,z,B,D,O,j,U,Q,V),D=O=j=null;zq(q,!0,-1),I=q.input.charCodeAt(q.position)}if((q.line===Y||q.lineIndent>$)&&I!==0)x(q,"bad indentation of a mapping entry");else if(q.lineIndent<$)break}if(P)r0(q,z,B,D,O,null,U,Q,V);if(L)q.tag=W,q.anchor=H,q.kind="mapping",q.result=z;return L}function NK(q){var $,J=!1,G=!1,X,Y,U;if(U=q.input.charCodeAt(q.position),U!==33)return!1;if(q.tag!==null)x(q,"duplication of a tag property");if(U=q.input.charCodeAt(++q.position),U===60)J=!0,U=q.input.charCodeAt(++q.position);else if(U===33)G=!0,X="!!",U=q.input.charCodeAt(++q.position);else X="!";if($=q.position,J){do U=q.input.charCodeAt(++q.position);while(U!==0&&U!==62);if(q.position<q.length)Y=q.input.slice($,q.position),U=q.input.charCodeAt(++q.position);else x(q,"unexpected end of the stream within a verbatim tag")}else{while(U!==0&&!Iq(U)){if(U===33)if(!G){if(X=q.input.slice($-1,q.position+1),!e8.test(X))x(q,"named tag handle cannot contain such characters");G=!0,$=q.position+1}else x(q,"tag suffix cannot contain exclamation marks");U=q.input.charCodeAt(++q.position)}if(Y=q.input.slice($,q.position),WK.test(Y))x(q,"tag suffix cannot contain flow indicator characters")}if(Y&&!q7.test(Y))x(q,"tag name cannot contain such characters: "+Y);try{Y=decodeURIComponent(Y)}catch(Q){x(q,"tag name is malformed: "+Y)}if(J)q.tag=Y;else if(_1.call(q.tagMap,X))q.tag=q.tagMap[X]+Y;else if(X==="!")q.tag="!"+Y;else if(X==="!!")q.tag="tag:yaml.org,2002:"+Y;else x(q,'undeclared tag handle "'+X+'"');return!0}function jK(q){var $,J;if(J=q.input.charCodeAt(q.position),J!==38)return!1;if(q.anchor!==null)x(q,"duplication of an anchor property");J=q.input.charCodeAt(++q.position),$=q.position;while(J!==0&&!Iq(J)&&!l0(J))J=q.input.charCodeAt(++q.position);if(q.position===$)x(q,"name of an anchor node must contain at least one character");return q.anchor=q.input.slice($,q.position),!0}function SK(q){var $,J,G;if(G=q.input.charCodeAt(q.position),G!==42)return!1;G=q.input.charCodeAt(++q.position),$=q.position;while(G!==0&&!Iq(G)&&!l0(G))G=q.input.charCodeAt(++q.position);if(q.position===$)x(q,"name of an alias node must contain at least one character");if(J=q.input.slice($,q.position),!_1.call(q.anchorMap,J))x(q,'unidentified alias "'+J+'"');return q.result=q.anchorMap[J],zq(q,!0,-1),!0}function i0(q,$,J,G,X){var Y,U,Q,V=1,W=!1,H=!1,z,B,D,O,j,P;if(q.listener!==null)q.listener("open",q);if(q.tag=null,q.anchor=null,q.kind=null,q.result=null,Y=U=Q=g3===J||t8===J,G){if(zq(q,!0,-1)){if(W=!0,q.lineIndent>$)V=1;else if(q.lineIndent===$)V=0;else if(q.lineIndent<$)V=-1}}if(V===1)while(NK(q)||jK(q))if(zq(q,!0,-1)){if(W=!0,Q=Y,q.lineIndent>$)V=1;else if(q.lineIndent===$)V=0;else if(q.lineIndent<$)V=-1}else Q=!1;if(Q)Q=W||X;if(V===1||g3===J){if(I3===J||s8===J)j=$;else j=$+1;if(P=q.position-q.lineStart,V===1)if(Q&&(x8(q,P)||AK(q,P,j))||FK(q,j))H=!0;else{if(U&&OK(q,j)||RK(q,j)||wK(q,j))H=!0;else if(SK(q)){if(H=!0,q.tag!==null||q.anchor!==null)x(q,"alias node should not have any properties")}else if(BK(q,j,I3===J)){if(H=!0,q.tag===null)q.tag="?"}if(q.anchor!==null)q.anchorMap[q.anchor]=q.result}else if(V===0)H=Q&&x8(q,P)}if(q.tag===null){if(q.anchor!==null)q.anchorMap[q.anchor]=q.result}else if(q.tag==="?"){if(q.result!==null&&q.kind!=="scalar")x(q,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+q.kind+'"');for(z=0,B=q.implicitTypes.length;z<B;z+=1)if(O=q.implicitTypes[z],O.resolve(q.result)){if(q.result=O.construct(q.result),q.tag=O.tag,q.anchor!==null)q.anchorMap[q.anchor]=q.result;break}}else if(q.tag!=="!"){if(_1.call(q.typeMap[q.kind||"fallback"],q.tag))O=q.typeMap[q.kind||"fallback"][q.tag];else{O=null,D=q.typeMap.multi[q.kind||"fallback"];for(z=0,B=D.length;z<B;z+=1)if(q.tag.slice(0,D[z].tag.length)===D[z].tag){O=D[z];break}}if(!O)x(q,"unknown tag !<"+q.tag+">");if(q.result!==null&&O.kind!==q.kind)x(q,"unacceptable node kind for !<"+q.tag+'> tag; it should be "'+O.kind+'", not "'+q.kind+'"');if(!O.resolve(q.result,q.tag))x(q,"cannot resolve a node with !<"+q.tag+"> explicit tag");else if(q.result=O.construct(q.result,q.tag),q.anchor!==null)q.anchorMap[q.anchor]=q.result}if(q.listener!==null)q.listener("close",q);return q.tag!==null||q.anchor!==null||H}function PK(q){var $=q.position,J,G,X,Y=!1,U;q.version=null,q.checkLineBreaks=q.legacy,q.tagMap=Object.create(null),q.anchorMap=Object.create(null);while((U=q.input.charCodeAt(q.position))!==0){if(zq(q,!0,-1),U=q.input.charCodeAt(q.position),q.lineIndent>0||U!==37)break;Y=!0,U=q.input.charCodeAt(++q.position),J=q.position;while(U!==0&&!Iq(U))U=q.input.charCodeAt(++q.position);if(G=q.input.slice(J,q.position),X=[],G.length<1)x(q,"directive name must not be less than one character in length");while(U!==0){while(J0(U))U=q.input.charCodeAt(++q.position);if(U===35){do U=q.input.charCodeAt(++q.position);while(U!==0&&!X1(U));break}if(X1(U))break;J=q.position;while(U!==0&&!Iq(U))U=q.input.charCodeAt(++q.position);X.push(q.input.slice(J,q.position))}if(U!==0)L2(q);if(_1.call(y8,G))y8[G](q,G,X);else v3(q,'unknown document directive "'+G+'"')}if(zq(q,!0,-1),q.lineIndent===0&&q.input.charCodeAt(q.position)===45&&q.input.charCodeAt(q.position+1)===45&&q.input.charCodeAt(q.position+2)===45)q.position+=3,zq(q,!0,-1);else if(Y)x(q,"directives end mark is expected");if(i0(q,q.lineIndent-1,g3,!1,!0),zq(q,!0,-1),q.checkLineBreaks&&VK.test(q.input.slice($,q.position)))v3(q,"non-ASCII line breaks are interpreted as content");if(q.documents.push(q.result),q.position===q.lineStart&&x3(q)){if(q.input.charCodeAt(q.position)===46)q.position+=3,zq(q,!0,-1);return}if(q.position<q.length-1)x(q,"end of the stream or a document separator is expected");else return}function Y7(q,$){if(q=String(q),$=$||{},q.length!==0){if(q.charCodeAt(q.length-1)!==10&&q.charCodeAt(q.length-1)!==13)q+=`
|
|
149
|
-
`;if(q.charCodeAt(0)===65279)q=q.slice(1)}var J=new DK(q,$),G=q.indexOf("\x00");if(G!==-1)J.position=G,x(J,"null byte is not allowed in input");J.input+="\x00";while(J.input.charCodeAt(J.position)===32)J.lineIndent+=1,J.position+=1;while(J.position<J.length-1)PK(J);return J.documents}function LK(q,$,J){if($!==null&&typeof $==="object"&&typeof J>"u")J=$,$=null;var G=Y7(q,J);if(typeof $!=="function")return G;for(var X=0,Y=G.length;X<Y;X+=1)$(G[X])}function ZK(q,$){var J=Y7(q,$);if(J.length===0)return;else if(J.length===1)return J[0];throw new bq("expected a single document in the stream, but found more")}var CK=LK,EK=ZK,U7={loadAll:CK,load:EK},Q7=Object.prototype.toString,V7=Object.prototype.hasOwnProperty,C2=65279,TK=9,T$=10,_K=13,bK=32,IK=33,gK=34,A2=35,vK=37,yK=38,hK=39,xK=42,W7=44,mK=45,y3=58,kK=61,fK=62,uK=63,pK=64,H7=91,z7=93,lK=96,M7=123,rK=124,K7=125,Lq={};Lq[0]="\\0";Lq[7]="\\a";Lq[8]="\\b";Lq[9]="\\t";Lq[10]="\\n";Lq[11]="\\v";Lq[12]="\\f";Lq[13]="\\r";Lq[27]="\\e";Lq[34]="\\\"";Lq[92]="\\\\";Lq[133]="\\N";Lq[160]="\\_";Lq[8232]="\\L";Lq[8233]="\\P";var iK=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"],dK=/^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;function cK(q,$){var J,G,X,Y,U,Q,V;if($===null)return{};J={},G=Object.keys($);for(X=0,Y=G.length;X<Y;X+=1){if(U=G[X],Q=String($[U]),U.slice(0,2)==="!!")U="tag:yaml.org,2002:"+U.slice(2);if(V=q.compiledTypeMap.fallback[U],V&&V7.call(V.styleAliases,Q))Q=V.styleAliases[Q];J[U]=Q}return J}function nK(q){var $,J,G;if($=q.toString(16).toUpperCase(),q<=255)J="x",G=2;else if(q<=65535)J="u",G=4;else if(q<=4294967295)J="U",G=8;else throw new bq("code point within a string may not be greater than 0xFFFFFFFF");return"\\"+J+Bq.repeat("0",G-$.length)+$}var oK=1,_$=2;function aK(q){this.schema=q.schema||a8,this.indent=Math.max(1,q.indent||2),this.noArrayIndent=q.noArrayIndent||!1,this.skipInvalid=q.skipInvalid||!1,this.flowLevel=Bq.isNothing(q.flowLevel)?-1:q.flowLevel,this.styleMap=cK(this.schema,q.styles||null),this.sortKeys=q.sortKeys||!1,this.lineWidth=q.lineWidth||80,this.noRefs=q.noRefs||!1,this.noCompatMode=q.noCompatMode||!1,this.condenseFlow=q.condenseFlow||!1,this.quotingType=q.quotingType==='"'?_$:oK,this.forceQuotes=q.forceQuotes||!1,this.replacer=typeof q.replacer==="function"?q.replacer:null,this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}function m8(q,$){var J=Bq.repeat(" ",$),G=0,X=-1,Y="",U,Q=q.length;while(G<Q){if(X=q.indexOf(`
|
|
150
|
-
`,G),X===-1)U=q.slice(G),G=Q;else U=q.slice(G,X+1),G=X+1;if(U.length&&U!==`
|
|
151
|
-
`)Y+=J;Y+=U}return Y}function N2(q,$){return`
|
|
152
|
-
`+Bq.repeat(" ",q.indent*$)}function sK(q,$){var J,G,X;for(J=0,G=q.implicitTypes.length;J<G;J+=1)if(X=q.implicitTypes[J],X.resolve($))return!0;return!1}function h3(q){return q===bK||q===TK}function b$(q){return 32<=q&&q<=126||161<=q&&q<=55295&&q!==8232&&q!==8233||57344<=q&&q<=65533&&q!==C2||65536<=q&&q<=1114111}function k8(q){return b$(q)&&q!==C2&&q!==_K&&q!==T$}function f8(q,$,J){var G=k8(q),X=G&&!h3(q);return(J?G:G&&q!==W7&&q!==H7&&q!==z7&&q!==M7&&q!==K7)&&q!==A2&&!($===y3&&!X)||k8($)&&!h3($)&&q===A2||$===y3&&X}function tK(q){return b$(q)&&q!==C2&&!h3(q)&&q!==mK&&q!==uK&&q!==y3&&q!==W7&&q!==H7&&q!==z7&&q!==M7&&q!==K7&&q!==A2&&q!==yK&&q!==xK&&q!==IK&&q!==rK&&q!==kK&&q!==fK&&q!==hK&&q!==gK&&q!==vK&&q!==pK&&q!==lK}function eK(q){return!h3(q)&&q!==y3}function C$(q,$){var J=q.charCodeAt($),G;if(J>=55296&&J<=56319&&$+1<q.length){if(G=q.charCodeAt($+1),G>=56320&&G<=57343)return(J-55296)*1024+G-56320+65536}return J}function D7(q){var $=/^\n* /;return $.test(q)}var B7=1,j2=2,R7=3,w7=4,p0=5;function qD(q,$,J,G,X,Y,U,Q){var V,W=0,H=null,z=!1,B=!1,D=G!==-1,O=-1,j=tK(C$(q,0))&&eK(C$(q,q.length-1));if($||U)for(V=0;V<q.length;W>=65536?V+=2:V++){if(W=C$(q,V),!b$(W))return p0;j=j&&f8(W,H,Q),H=W}else{for(V=0;V<q.length;W>=65536?V+=2:V++){if(W=C$(q,V),W===T$){if(z=!0,D)B=B||V-O-1>G&&q[O+1]!==" ",O=V}else if(!b$(W))return p0;j=j&&f8(W,H,Q),H=W}B=B||D&&(V-O-1>G&&q[O+1]!==" ")}if(!z&&!B){if(j&&!U&&!X(q))return B7;return Y===_$?p0:j2}if(J>9&&D7(q))return p0;if(!U)return B?w7:R7;return Y===_$?p0:j2}function $D(q,$,J,G,X){q.dump=function(){if($.length===0)return q.quotingType===_$?'""':"''";if(!q.noCompatMode){if(iK.indexOf($)!==-1||dK.test($))return q.quotingType===_$?'"'+$+'"':"'"+$+"'"}var Y=q.indent*Math.max(1,J),U=q.lineWidth===-1?-1:Math.max(Math.min(q.lineWidth,40),q.lineWidth-Y),Q=G||q.flowLevel>-1&&J>=q.flowLevel;function V(W){return sK(q,W)}switch(qD($,Q,q.indent,U,V,q.quotingType,q.forceQuotes&&!G,X)){case B7:return $;case j2:return"'"+$.replace(/'/g,"''")+"'";case R7:return"|"+u8($,q.indent)+p8(m8($,Y));case w7:return">"+u8($,q.indent)+p8(m8(JD($,U),Y));case p0:return'"'+GD($)+'"';default:throw new bq("impossible error: invalid scalar style")}}()}function u8(q,$){var J=D7(q)?String($):"",G=q[q.length-1]===`
|
|
153
|
-
`,X=G&&(q[q.length-2]===`
|
|
154
|
-
`||q===`
|
|
155
|
-
`),Y=X?"+":G?"":"-";return J+Y+`
|
|
156
|
-
`}function p8(q){return q[q.length-1]===`
|
|
157
|
-
`?q.slice(0,-1):q}function JD(q,$){var J=/(\n+)([^\n]*)/g,G=function(){var W=q.indexOf(`
|
|
158
|
-
`);return W=W!==-1?W:q.length,J.lastIndex=W,l8(q.slice(0,W),$)}(),X=q[0]===`
|
|
159
|
-
`||q[0]===" ",Y,U;while(U=J.exec(q)){var Q=U[1],V=U[2];Y=V[0]===" ",G+=Q+(!X&&!Y&&V!==""?`
|
|
160
|
-
`:"")+l8(V,$),X=Y}return G}function l8(q,$){if(q===""||q[0]===" ")return q;var J=/ [^ ]/g,G,X=0,Y,U=0,Q=0,V="";while(G=J.exec(q)){if(Q=G.index,Q-X>$)Y=U>X?U:Q,V+=`
|
|
161
|
-
`+q.slice(X,Y),X=Y+1;U=Q}if(V+=`
|
|
162
|
-
`,q.length-X>$&&U>X)V+=q.slice(X,U)+`
|
|
163
|
-
`+q.slice(U+1);else V+=q.slice(X);return V.slice(1)}function GD(q){var $="",J=0,G;for(var X=0;X<q.length;J>=65536?X+=2:X++)if(J=C$(q,X),G=Lq[J],!G&&b$(J)){if($+=q[X],J>=65536)$+=q[X+1]}else $+=G||nK(J);return $}function XD(q,$,J){var G="",X=q.tag,Y,U,Q;for(Y=0,U=J.length;Y<U;Y+=1){if(Q=J[Y],q.replacer)Q=q.replacer.call(J,String(Y),Q);if(D1(q,$,Q,!1,!1)||typeof Q>"u"&&D1(q,$,null,!1,!1)){if(G!=="")G+=","+(!q.condenseFlow?" ":"");G+=q.dump}}q.tag=X,q.dump="["+G+"]"}function r8(q,$,J,G){var X="",Y=q.tag,U,Q,V;for(U=0,Q=J.length;U<Q;U+=1){if(V=J[U],q.replacer)V=q.replacer.call(J,String(U),V);if(D1(q,$+1,V,!0,!0,!1,!0)||typeof V>"u"&&D1(q,$+1,null,!0,!0,!1,!0)){if(!G||X!=="")X+=N2(q,$);if(q.dump&&T$===q.dump.charCodeAt(0))X+="-";else X+="- ";X+=q.dump}}q.tag=Y,q.dump=X||"[]"}function YD(q,$,J){var G="",X=q.tag,Y=Object.keys(J),U,Q,V,W,H;for(U=0,Q=Y.length;U<Q;U+=1){if(H="",G!=="")H+=", ";if(q.condenseFlow)H+='"';if(V=Y[U],W=J[V],q.replacer)W=q.replacer.call(J,V,W);if(!D1(q,$,V,!1,!1))continue;if(q.dump.length>1024)H+="? ";if(H+=q.dump+(q.condenseFlow?'"':"")+":"+(q.condenseFlow?"":" "),!D1(q,$,W,!1,!1))continue;H+=q.dump,G+=H}q.tag=X,q.dump="{"+G+"}"}function UD(q,$,J,G){var X="",Y=q.tag,U=Object.keys(J),Q,V,W,H,z,B;if(q.sortKeys===!0)U.sort();else if(typeof q.sortKeys==="function")U.sort(q.sortKeys);else if(q.sortKeys)throw new bq("sortKeys must be a boolean or a function");for(Q=0,V=U.length;Q<V;Q+=1){if(B="",!G||X!=="")B+=N2(q,$);if(W=U[Q],H=J[W],q.replacer)H=q.replacer.call(J,W,H);if(!D1(q,$+1,W,!0,!0,!0))continue;if(z=q.tag!==null&&q.tag!=="?"||q.dump&&q.dump.length>1024,z)if(q.dump&&T$===q.dump.charCodeAt(0))B+="?";else B+="? ";if(B+=q.dump,z)B+=N2(q,$);if(!D1(q,$+1,H,!0,z))continue;if(q.dump&&T$===q.dump.charCodeAt(0))B+=":";else B+=": ";B+=q.dump,X+=B}q.tag=Y,q.dump=X||"{}"}function i8(q,$,J){var G,X,Y,U,Q,V;X=J?q.explicitTypes:q.implicitTypes;for(Y=0,U=X.length;Y<U;Y+=1)if(Q=X[Y],(Q.instanceOf||Q.predicate)&&(!Q.instanceOf||typeof $==="object"&&$ instanceof Q.instanceOf)&&(!Q.predicate||Q.predicate($))){if(J)if(Q.multi&&Q.representName)q.tag=Q.representName($);else q.tag=Q.tag;else q.tag="?";if(Q.represent){if(V=q.styleMap[Q.tag]||Q.defaultStyle,Q7.call(Q.represent)==="[object Function]")G=Q.represent($,V);else if(V7.call(Q.represent,V))G=Q.represent[V]($,V);else throw new bq("!<"+Q.tag+'> tag resolver accepts not "'+V+'" style');q.dump=G}return!0}return!1}function D1(q,$,J,G,X,Y,U){if(q.tag=null,q.dump=J,!i8(q,J,!1))i8(q,J,!0);var Q=Q7.call(q.dump),V=G,W;if(G)G=q.flowLevel<0||q.flowLevel>$;var H=Q==="[object Object]"||Q==="[object Array]",z,B;if(H)z=q.duplicates.indexOf(J),B=z!==-1;if(q.tag!==null&&q.tag!=="?"||B||q.indent!==2&&$>0)X=!1;if(B&&q.usedDuplicates[z])q.dump="*ref_"+z;else{if(H&&B&&!q.usedDuplicates[z])q.usedDuplicates[z]=!0;if(Q==="[object Object]"){if(G&&Object.keys(q.dump).length!==0){if(UD(q,$,q.dump,X),B)q.dump="&ref_"+z+q.dump}else if(YD(q,$,q.dump),B)q.dump="&ref_"+z+" "+q.dump}else if(Q==="[object Array]"){if(G&&q.dump.length!==0){if(q.noArrayIndent&&!U&&$>0)r8(q,$-1,q.dump,X);else r8(q,$,q.dump,X);if(B)q.dump="&ref_"+z+q.dump}else if(XD(q,$,q.dump),B)q.dump="&ref_"+z+" "+q.dump}else if(Q==="[object String]"){if(q.tag!=="?")$D(q,q.dump,$,Y,V)}else if(Q==="[object Undefined]")return!1;else{if(q.skipInvalid)return!1;throw new bq("unacceptable kind of an object to dump "+Q)}if(q.tag!==null&&q.tag!=="?"){if(W=encodeURI(q.tag[0]==="!"?q.tag.slice(1):q.tag).replace(/!/g,"%21"),q.tag[0]==="!")W="!"+W;else if(W.slice(0,18)==="tag:yaml.org,2002:")W="!!"+W.slice(18);else W="!<"+W+">";q.dump=W+" "+q.dump}}return!0}function QD(q,$){var J=[],G=[],X,Y;S2(q,J,G);for(X=0,Y=G.length;X<Y;X+=1)$.duplicates.push(J[G[X]]);$.usedDuplicates=Array(Y)}function S2(q,$,J){var G,X,Y;if(q!==null&&typeof q==="object")if(X=$.indexOf(q),X!==-1){if(J.indexOf(X)===-1)J.push(X)}else if($.push(q),Array.isArray(q))for(X=0,Y=q.length;X<Y;X+=1)S2(q[X],$,J);else{G=Object.keys(q);for(X=0,Y=G.length;X<Y;X+=1)S2(q[G[X]],$,J)}}function VD(q,$){$=$||{};var J=new aK($);if(!J.noRefs)QD(q,J);var G=q;if(J.replacer)G=J.replacer.call({"":G},"",G);if(D1(J,0,G,!0,!0))return J.dump+`
|
|
164
|
-
`;return""}var WD=VD,HD={dump:WD};function E2(q,$){return function(){throw Error("Function yaml."+q+" is removed in js-yaml 4. Use yaml."+$+" instead, which is now safe by default.")}}var{load:T2,loadAll:RL}=U7,F7=HD.dump;var wL=E2("safeLoad","load"),FL=E2("safeLoadAll","loadAll"),OL=E2("safeDump","dump");function b2(q,$){if(!q.trim())return{ok:!1,error:"file is empty"};let J;try{J=T2(q)}catch(X){return{ok:!1,error:X instanceof Error?X.message:"YAML parse error"}}if(!J||typeof J!=="object"||Array.isArray(J))return{ok:!1,error:"expected a YAML mapping (key: value pairs)"};if(!$)return{ok:!0,data:J};let G=$.safeParse(J);if(!G.success)return{ok:!1,error:`invalid field(s): ${G.error.issues.map((Y)=>Y.path.join(".")).join(", ")}`};return{ok:!0,data:G.data}}var _L=b.object({message:b.string()});var zD=b.object({message:b.string().describe("Natural language response to the query"),summary:b.string().optional().describe("Brief summary if applicable"),topics:b.array(b.string()).optional().describe("Related topics mentioned"),sources:b.array(b.object({id:b.string(),type:b.string(),excerpt:b.string().optional(),relevance:b.number().min(0).max(1).optional()})).optional().describe("Source entities used to answer the query"),metadata:b.record(b.string(),b.unknown()).optional()}).describe("defaultQueryResponse"),MD=b.object({message:b.string()}).describe("simpleTextResponse"),O7=b.object({success:b.boolean(),entityId:b.string().optional(),message:b.string()}).describe("createEntityResponse"),A7=b.object({success:b.boolean(),entityId:b.string(),changes:b.array(b.string()).optional(),message:b.string()}).describe("updateEntityResponse");class N7{schema;config;processor=b3();constructor(q,$){this.schema=q;this.config=$}getLabels(){let q={};for(let $ of this.config.mappings)q[$.key]=$.label;return q}generateBodyTemplate(){if(this.config.mappings.length===0)return"";let q=[];for(let $ of this.config.mappings)q.push(`## ${$.label}`,"",`<!-- Write your ${$.label.toLowerCase()} here -->`,"");return q.join(`
|
|
510
|
+
`,now:{line:1,column:1},lineShift:0});if(q&&q.charCodeAt(q.length-1)!==10&&q.charCodeAt(q.length-1)!==13)q+=`
|
|
511
|
+
`;return q;function I(Q){return G.stack.push(Q),D;function D(){G.stack.pop()}}}function Si($){throw Error("Cannot handle value `"+$+"`, expected node")}function Li($){throw Error("Cannot handle unknown node `"+$.type+"`")}function Ei($,U){if($.type==="definition"&&$.type===U.type)return 0}function Ci($,U){return WS($,this,U)}function _i($,U){return OS($,this,U)}function vi($,U){return NS(this,$,U)}function fX($){let U=this;U.compiler=J;function J(G){return aN(G,{...U.data("settings"),...$,extensions:U.data("toMarkdownExtensions")||[]})}}function sN($){if($)throw $}var lX=nY(PS(),1);function p4($){if(typeof $!=="object"||$===null)return!1;let U=Object.getPrototypeOf($);return(U===null||U===Object.prototype||Object.getPrototypeOf(U)===null)&&!(Symbol.toStringTag in $)&&!(Symbol.iterator in $)}function tN(){let $=[],U={run:J,use:G};return U;function J(...q){let I=-1,Q=q.pop();if(typeof Q!=="function")throw TypeError("Expected function as last argument, not "+Q);D(null,...q);function D(X,...Y){let V=$[++I],W=-1;if(X){Q(X);return}while(++W<q.length)if(Y[W]===null||Y[W]===void 0)Y[W]=q[W];if(q=Y,V)BS(V,D)(...Y);else Q(null,...Y)}}function G(q){if(typeof q!=="function")throw TypeError("Expected `middelware` to be a function, not "+q);return $.push(q),U}}function BS($,U){let J;return G;function G(...Q){let D=$.length>Q.length,X;if(D)Q.push(q);try{X=$.apply(this,Q)}catch(Y){let V=Y;if(D&&J)throw V;return q(V)}if(!D)if(X&&X.then&&typeof X.then==="function")X.then(I,q);else if(X instanceof Error)q(X);else I(X)}function q(Q,...D){if(!J)J=!0,U(Q,...D)}function I(Q){q(null,Q)}}class T0 extends Error{constructor($,U,J){super();if(typeof U==="string")J=U,U=void 0;let G="",q={},I=!1;if(U)if("line"in U&&"column"in U)q={place:U};else if("start"in U&&"end"in U)q={place:U};else if("type"in U)q={ancestors:[U],place:U.position};else q={...U};if(typeof $==="string")G=$;else if(!q.cause&&$)I=!0,G=$.message,q.cause=$;if(!q.ruleId&&!q.source&&typeof J==="string"){let D=J.indexOf(":");if(D===-1)q.ruleId=J;else q.source=J.slice(0,D),q.ruleId=J.slice(D+1)}if(!q.place&&q.ancestors&&q.ancestors){let D=q.ancestors[q.ancestors.length-1];if(D)q.place=D.position}let Q=q.place&&"start"in q.place?q.place.start:q.place;this.ancestors=q.ancestors||void 0,this.cause=q.cause||void 0,this.column=Q?Q.column:void 0,this.fatal=void 0,this.file="",this.message=G,this.line=Q?Q.line:void 0,this.name=Jq(q.place)||"1:1",this.place=q.place||void 0,this.reason=this.message,this.ruleId=q.ruleId||void 0,this.source=q.source||void 0,this.stack=I&&q.cause&&typeof q.cause.stack==="string"?q.cause.stack:"",this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}}T0.prototype.file="";T0.prototype.name="";T0.prototype.reason="";T0.prototype.message="";T0.prototype.stack="";T0.prototype.column=void 0;T0.prototype.line=void 0;T0.prototype.ancestors=void 0;T0.prototype.cause=void 0;T0.prototype.fatal=void 0;T0.prototype.place=void 0;T0.prototype.ruleId=void 0;T0.prototype.source=void 0;import{default as kU}from"path";import{default as SS}from"process";import{fileURLToPath as LS}from"url";function mX($){return Boolean($!==null&&typeof $==="object"&&"href"in $&&$.href&&"protocol"in $&&$.protocol&&$.auth===void 0)}var eN=["history","path","basename","stem","extname","dirname"];class hX{constructor($){let U;if(!$)U={};else if(mX($))U={path:$};else if(typeof $==="string"||Fi($))U={value:$};else U=$;this.cwd="cwd"in U?"":SS.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let J=-1;while(++J<eN.length){let q=eN[J];if(q in U&&U[q]!==void 0&&U[q]!==null)this[q]=q==="history"?[...U[q]]:U[q]}let G;for(G in U)if(!eN.includes(G))this[G]=U[G]}get basename(){return typeof this.path==="string"?kU.basename(this.path):void 0}set basename($){U5($,"basename"),$5($,"basename"),this.path=kU.join(this.dirname||"",$)}get dirname(){return typeof this.path==="string"?kU.dirname(this.path):void 0}set dirname($){ES(this.basename,"dirname"),this.path=kU.join($||"",this.basename)}get extname(){return typeof this.path==="string"?kU.extname(this.path):void 0}set extname($){if($5($,"extname"),ES(this.dirname,"extname"),$){if($.codePointAt(0)!==46)throw Error("`extname` must start with `.`");if($.includes(".",1))throw Error("`extname` cannot contain multiple dots")}this.path=kU.join(this.dirname,this.stem+($||""))}get path(){return this.history[this.history.length-1]}set path($){if(mX($))$=LS($);if(U5($,"path"),this.path!==$)this.history.push($)}get stem(){return typeof this.path==="string"?kU.basename(this.path,this.extname):void 0}set stem($){U5($,"stem"),$5($,"stem"),this.path=kU.join(this.dirname||"",$+(this.extname||""))}fail($,U,J){let G=this.message($,U,J);throw G.fatal=!0,G}info($,U,J){let G=this.message($,U,J);return G.fatal=void 0,G}message($,U,J){let G=new T0($,U,J);if(this.path)G.name=this.path+":"+G.name,G.file=this.path;return G.fatal=!1,this.messages.push(G),G}toString($){if(this.value===void 0)return"";if(typeof this.value==="string")return this.value;return new TextDecoder($||void 0).decode(this.value)}}function $5($,U){if($&&$.includes(kU.sep))throw Error("`"+U+"` cannot be a path: did not expect `"+kU.sep+"`")}function U5($,U){if(!$)throw Error("`"+U+"` cannot be empty")}function ES($,U){if(!$)throw Error("Setting `"+U+"` requires `path` to be set too")}function Fi($){return Boolean($&&typeof $==="object"&&"byteLength"in $&&"byteOffset"in $)}var CS=function($){let G=this.constructor.prototype,q=G[$],I=function(){return q.apply(I,arguments)};return Object.setPrototypeOf(I,G),I};var bi={}.hasOwnProperty;class I5 extends CS{constructor(){super("copy");this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=tN()}copy(){let $=new I5,U=-1;while(++U<this.attachers.length){let J=this.attachers[U];$.use(...J)}return $.data(lX.default(!0,{},this.namespace)),$}data($,U){if(typeof $==="string"){if(arguments.length===2)return G5("data",this.frozen),this.namespace[$]=U,this;return bi.call(this.namespace,$)&&this.namespace[$]||void 0}if($)return G5("data",this.frozen),this.namespace=$,this;return this.namespace}freeze(){if(this.frozen)return this;let $=this;while(++this.freezeIndex<this.attachers.length){let[U,...J]=this.attachers[this.freezeIndex];if(J[0]===!1)continue;if(J[0]===!0)J[0]=void 0;let G=U.call($,...J);if(typeof G==="function")this.transformers.use(G)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse($){this.freeze();let U=rX($),J=this.parser||this.Parser;return J5("parse",J),J(String(U),U)}process($,U){let J=this;return this.freeze(),J5("process",this.parser||this.Parser),q5("process",this.compiler||this.Compiler),U?G(void 0,U):new Promise(G);function G(q,I){let Q=rX($),D=J.parse(Q);J.run(D,Q,function(Y,V,W){if(Y||!V||!W)return X(Y);let O=V,Z=J.stringify(O,W);if(ki(Z))W.value=Z;else W.result=Z;X(Y,W)});function X(Y,V){if(Y||!V)I(Y);else if(q)q(V);else k(U,"`done` is defined if `resolve` is not"),U(void 0,V)}}}processSync($){let U=!1,J;return this.freeze(),J5("processSync",this.parser||this.Parser),q5("processSync",this.compiler||this.Compiler),this.process($,G),vS("processSync","process",U),k(J,"we either bailed on an error or have a tree"),J;function G(q,I){U=!0,sN(q),J=I}}run($,U,J){_S($),this.freeze();let G=this.transformers;if(!J&&typeof U==="function")J=U,U=void 0;return J?q(void 0,J):new Promise(q);function q(I,Q){k(typeof U!=="function","`file` can\u2019t be a `done` anymore, we checked");let D=rX(U);G.run($,D,X);function X(Y,V,W){let O=V||$;if(Y)Q(Y);else if(I)I(O);else k(J,"`done` is defined if `resolve` is not"),J(void 0,O,W)}}}runSync($,U){let J=!1,G;return this.run($,U,q),vS("runSync","run",J),k(G,"we either bailed on an error or have a tree"),G;function q(I,Q){sN(I),G=Q,J=!0}}stringify($,U){this.freeze();let J=rX(U),G=this.compiler||this.Compiler;return q5("stringify",G),_S($),G($,J)}use($,...U){let J=this.attachers,G=this.namespace;if(G5("use",this.frozen),$===null||$===void 0);else if(typeof $==="function")D($,U);else if(typeof $==="object")if(Array.isArray($))Q($);else I($);else throw TypeError("Expected usable value, not `"+$+"`");return this;function q(X){if(typeof X==="function")D(X,[]);else if(typeof X==="object")if(Array.isArray(X)){let[Y,...V]=X;D(Y,V)}else I(X);else throw TypeError("Expected usable value, not `"+X+"`")}function I(X){if(!("plugins"in X)&&!("settings"in X))throw Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");if(Q(X.plugins),X.settings)G.settings=lX.default(!0,G.settings,X.settings)}function Q(X){let Y=-1;if(X===null||X===void 0);else if(Array.isArray(X))while(++Y<X.length){let V=X[Y];q(V)}else throw TypeError("Expected a list of plugins, not `"+X+"`")}function D(X,Y){let V=-1,W=-1;while(++V<J.length)if(J[V][0]===X){W=V;break}if(W===-1)J.push([X,...Y]);else if(Y.length>0){let[O,...Z]=Y,M=J[W][1];if(p4(M)&&p4(O))O=lX.default(!0,M,O);J[W]=[X,O,...Z]}}}}var Q5=new I5().freeze();function J5($,U){if(typeof U!=="function")throw TypeError("Cannot `"+$+"` without `parser`")}function q5($,U){if(typeof U!=="function")throw TypeError("Cannot `"+$+"` without `compiler`")}function G5($,U){if(U)throw Error("Cannot call `"+$+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function _S($){if(!p4($)||typeof $.type!=="string")throw TypeError("Expected node, got `"+$+"`")}function vS($,U,J){if(!J)throw Error("`"+$+"` finished async. Use `"+U+"` instead")}function rX($){return ui($)?$:new hX($)}function ui($){return Boolean($&&typeof $==="object"&&"message"in $&&"messages"in $)}function ki($){return typeof $==="string"||xi($)}function xi($){return Boolean($&&typeof $==="object"&&"byteLength"in $&&"byteOffset"in $)}var iX=Q5().use(_X).use(fX).freeze();var GR$=iX();b$();var FS=N.object({audiences:N.array(N.string()).optional(),positioning:N.string().optional()}),bS=N.object({summary:N.string().optional(),traits:N.array(N.string()).optional(),principles:N.array(N.string()).optional(),preferredTerms:N.array(N.string()).optional(),avoid:N.array(N.string()).optional()}),uS=N.object({artDirection:N.string().optional(),palette:N.array(N.string()).optional(),composition:N.string().optional(),mood:N.string().optional(),preferred:N.array(N.string()).optional(),avoid:N.array(N.string()).optional()}),mi=N.object({name:N.string().describe("Style guide name"),messaging:FS.optional(),voice:bS.optional(),visual:uS.optional()});b$();var hi=N.object({id:N.string().min(1),trigger:N.string().min(1),playbookId:N.string().min(1),once:N.boolean().default(!0),starterText:N.string().min(1),description:N.string().min(1).optional(),starterPrompt:N.string().min(1)}).strict();b$();var ri=N.object({message:N.string().describe("Natural language response to the query"),summary:N.string().optional().describe("Brief summary if applicable"),topics:N.array(N.string()).optional().describe("Related topics mentioned"),sources:N.array(N.object({id:N.string(),type:N.string(),excerpt:N.string().optional(),relevance:N.number().min(0).max(1).optional()})).optional().describe("Source entities used to answer the query"),metadata:N.record(N.string(),N.unknown()).optional()}).describe("defaultQueryResponse"),li=N.object({message:N.string()}).describe("simpleTextResponse"),kS=N.object({success:N.boolean(),entityId:N.string().optional(),message:N.string()}).describe("createEntityResponse"),xS=N.object({success:N.boolean(),entityId:N.string(),changes:N.array(N.string()).optional(),message:N.string()}).describe("updateEntityResponse");b$();var fS=N.record(N.string(),N.unknown());class pX{schema;config;processor=iX();constructor($,U){this.schema=$,this.config=U}getLabels(){let $={};for(let U of this.config.mappings)$[U.key]=U.label;return $}generateBodyTemplate(){if(this.config.mappings.length===0)return"";let $=[];for(let U of this.config.mappings)$.push(`## ${U.label}`,"",`<!-- Write your ${U.label.toLowerCase()} here -->`,"");return $.join(`
|
|
165
512
|
`).trimEnd()+`
|
|
166
|
-
`}format(
|
|
167
|
-
`)}catch{throw Error(
|
|
168
|
-
`)}extractTextFromParagraph(
|
|
169
|
-
`)}}var
|
|
170
|
-
`)
|
|
171
|
-
|
|
172
|
-
`)}function
|
|
173
|
-
`)}async function d0(q,$,J,G){let X=new Set,Y=y7($.pilot.githubOrg);for(let Q of J){let V=(G?await G(Q):void 0)??{},W=await Y(Q),H=V.brainYaml??W.brainYaml,z=V.envFile??W.envFile;if(z)await h7(q,Q.handle,".env",z);if(H)await h7(q,Q.handle,"brain.yaml",H),X.add(Q.handle)}let U=X.size===0?$:{...$,users:$.users.map((Q)=>X.has(Q.handle)?{...Q,snapshotStatus:"present"}:Q)};await Y0(q,{registry:U})}async function h7(q,$,J,G){let X=GB(q,"users",$,J);await qB(JB(X),{recursive:!0}),await $B(X,G)}async function f3(q,$){let J=await X0(q),G=J.users.find((X)=>X.handle===$);if(!G)throw Error(`Unknown user handle: ${$}`);return{registry:J,user:G}}async function x7(q,$){let J=await X0(q),G=J.cohorts.find((X)=>X.id===$);if(!G)throw Error(`Unknown cohort: ${$}`);return{registry:J,users:J.users.filter((X)=>X.cohort===G.id)}}async function m7(q){let $=await X0(q);return{registry:$,users:$.users}}async function u2(q,$,J){let{registry:G,user:X}=await f3(q,$);await d0(q,G,[X],J)}async function p2(q,$,J){let{registry:G,users:X}=await x7(q,$);await d0(q,G,X,J)}async function l2(q,$){let{registry:J,users:G}=await m7(q);await d0(q,J,G,$)}import{parseArgs as XB}from"util";var YB={help:{type:"boolean",short:"h"},version:{type:"boolean",short:"v"},"dry-run":{type:"boolean"}};function r2(q,$){let J=q[$];return typeof J==="boolean"?J:void 0}function UB(q){let{values:$,positionals:J}=XB({args:q,options:YB,allowPositionals:!0});if($.help)return{command:"help",args:[],flags:{help:!0}};if($.version)return{command:"version",args:[],flags:{version:!0}};return{command:J[0]??"help",args:J.slice(1),flags:{help:r2($,"help"),version:r2($,"version"),dryRun:r2($,"dry-run")}}}import{readFileSync as QB}from"fs";async function i2(q,$,J={}){let{user:G}=await f3(q,$),X=J.env??process.env,Y=J.logger??console.log,U=y2(q),Q=g2(`${q}/.env.schema`),V=VB(Q,G),W=[],H=[],z=new Map;for(let D of V){z.set(D.destination,D.required);let O=WB(D,X,U,q);if(O===void 0||O.trim().length===0){H.push(D.destination);continue}W.push([D.destination,O])}if(W.length===0)throw Error("No pushable local secrets found for the selected pilot user");if(J.dryRun)return Y(`Dry run: would push ${W.length} secrets to GitHub Secrets.`),Y(`Secrets: ${W.map(([D])=>D).join(", ")}`),k7(Y,H,z),{pushedKeys:W.map(([D])=>D),skippedKeys:H,dryRun:!0};let B=J.runCommand??HB;return Y(`Pushing ${W.length} secrets to GitHub Secrets...`),await Promise.all(W.map(([D,O])=>B("gh",["secret","set",D],{stdin:O}))),k7(Y,H,z),{pushedKeys:W.map(([D])=>D),skippedKeys:H}}function VB(q,$){let J=k3($.handle);return q.flatMap((G)=>{switch(G.key){case"AI_API_KEY":return[{destination:$.effectiveAiApiKey,sourceKeys:[$.effectiveAiApiKey,"AI_API_KEY"],required:G.required}];case"GIT_SYNC_TOKEN":return[{destination:J.gitSyncTokenSecretName,sourceKeys:[J.gitSyncTokenSecretName,"GIT_SYNC_TOKEN"],required:G.required}];case"MCP_AUTH_TOKEN":return[{destination:J.mcpAuthTokenSecretName,sourceKeys:[J.mcpAuthTokenSecretName,"MCP_AUTH_TOKEN"],required:G.required}];case"DISCORD_BOT_TOKEN":if(!$.discordEnabled)return[];return[{destination:J.discordBotTokenSecretName,sourceKeys:[J.discordBotTokenSecretName,"DISCORD_BOT_TOKEN"],required:G.required}];default:return[{destination:G.key,sourceKeys:[G.key],required:G.required}]}})}function WB(q,$,J,G){let X=[q.destination,...q.sourceKeys];for(let Y of X){let U=m3(`${Y}_FILE`,$,J);if(U&&U.trim().length>0)return QB(h2(U,G),"utf8")}for(let Y of X){let U=m3(Y,$,J);if(U!==void 0)return U}return}function k7(q,$,J){let G=$.filter((Y)=>J.get(Y)),X=$.filter((Y)=>!J.get(Y));f7(q,"Required before first deploy",G),f7(q,"Safe to ignore for now",X)}function f7(q,$,J){if(J.length===0)return;q(`${$} (${J.length}):`);for(let G of J)q(` - ${G}`)}var HB=async(q,$,J={})=>{let{spawn:G}=await import("child_process");await new Promise((X,Y)=>{let U=G(q,$,{stdio:["pipe","inherit","inherit"],env:J.env?{...process.env,...J.env}:process.env});if(U.on("error",Y),U.on("close",(Q)=>{if(Q===0){X();return}Y(Error(`${q} ${$.join(" ")} exited with code ${Q??1}`))}),J.stdin){U.stdin.end(J.stdin);return}U.stdin.end()})};async function zB(q,$={}){switch(q.command){case"init":{let J=q.args[0];if(!J)return{success:!1,message:"Usage: brains-ops init <repo>"};return await f2(J),{success:!0,message:`Initialized ${J}`}}case"render":{let J=q.args[0];if(!J)return{success:!1,message:"Usage: brains-ops render <repo>"};return await Y0(J,{...$.resolveStatus?{resolveStatus:$.resolveStatus}:{}}),{success:!0,message:`Rendered ${J}/views/users.md`}}case"onboard":{let J=q.args[0],G=q.args[1];if(!J||!G)return{success:!1,message:"Usage: brains-ops onboard <repo> <handle>"};return await u2(J,G,$.runner),{success:!0,message:`Onboarded ${G}`}}case"secrets:push":{let J=q.args[0],G=q.args[1];if(!J||!G)return{success:!1,message:"Usage: brains-ops secrets:push <repo> <handle>"};let X=await i2(J,G,{env:$.env,logger:$.logger,dryRun:q.flags.dryRun,runCommand:$.secretRunCommand});return{success:!0,message:X.dryRun?`Dry run: would push ${X.pushedKeys.length} secrets`:`Pushed ${X.pushedKeys.length} secrets for ${G}`}}case"reconcile-cohort":{let J=q.args[0],G=q.args[1];if(!J||!G)return{success:!1,message:"Usage: brains-ops reconcile-cohort <repo> <cohort>"};return await p2(J,G,$.runner),{success:!0,message:`Reconciled cohort ${G}`}}case"reconcile-all":{let J=q.args[0];if(!J)return{success:!1,message:"Usage: brains-ops reconcile-all <repo>"};return await l2(J,$.runner),{success:!0,message:"Reconciled all cohorts"}}case"help":return{success:!0,message:["brains-ops \u2014 operator CLI for private brain fleet repos","","Usage: brains-ops <command> [args]","","Commands:"," init <repo>"," render <repo>"," onboard <repo> <handle>"," secrets:push <repo> <handle>"," reconcile-cohort <repo> <cohort>"," reconcile-all <repo>"," help"].join(`
|
|
174
|
-
`)
|
|
513
|
+
`}format($){try{let U=[`# ${this.config.title}`,""];for(let J of this.config.mappings)this.formatField($,J,U,2);return U.join(`
|
|
514
|
+
`)}catch(U){throw Error(`Failed to format structured content: ${this.describeError(U)}`,{cause:U})}}parse($){try{let U=this.processor.parse($),J=this.extractSections(U,2),G=this.buildDataFromSections(J,this.config.mappings);return this.schema.parse(G)}catch(U){throw Error(`Failed to parse structured content: ${this.describeError(U)}`,{cause:U})}}describeError($){if($ instanceof N.ZodError)return $.issues.map((U)=>`${U.path.join(".")||"(root)"}: ${U.message}`).join("; ");return q0($)}escapeBlockMarkup($){return $.replace(/^(\s*)#/gm,"$1\\#")}formatField($,U,J,G){let q="#".repeat(G)+" "+U.label,I=this.getValueByPath($,U.key);if(U.type==="custom"&&U.formatter){if(I!==void 0&&I!==null){J.push(q,"");let Q=U.formatter(I);if(Q)J.push(Q,"")}return}switch(U.type){case"string":case"number":if(I===void 0||I===null)break;J.push(q,this.escapeBlockMarkup(String(I)),"");break;case"object":if(J.push(q),U.children&&I)for(let Q of U.children)this.formatField(I,Q,J,G+1);break;case"array":if(J.push(q,""),Array.isArray(I))if(U.itemType==="object"&&U.itemMappings)I.forEach((Q,D)=>{if(J.push(`${"#".repeat(G+1)} ${U.label.slice(0,-1)} ${D+1}`),J.push(""),U.itemMappings)for(let X of U.itemMappings)this.formatField(Q,X,J,G+2)});else{for(let Q of I){let D=this.defaultArrayItemFormat(Q);J.push(`- ${D}`)}J.push("")}break}}getValueByPath($,U){let J=U.split("."),G=$;for(let q of J){let I=fS.safeParse(G);if(!I.success)return;G=I.data[q]}return G}defaultArrayItemFormat($){if(typeof $==="string"||typeof $==="number")return String($);return JSON.stringify($)}extractSections($,U){let J=new Map,G=null,q=[];for(let I of $.children)if(I.type==="heading"&&I.depth===U){if(G)J.set(G.toLowerCase(),q);G=this.getHeadingText(I),q=[]}else if(G)q.push(I);if(G)J.set(G.toLowerCase(),q);return J}extractSubsections($,U){let J=new Map,G=null,q=[];for(let I of $)if(I.type==="heading"&&I.depth===U){if(G)J.set(G.toLowerCase(),q);G=this.getHeadingText(I),q=[]}else if(G)q.push(I);if(G)J.set(G.toLowerCase(),q);return J}textNodeSchema=N.object({type:N.literal("text"),value:N.string()});extractTextValue($){let U=this.textNodeSchema.safeParse($);return U.success?U.data.value:""}getHeadingText($){return $.children.filter((J)=>J.type==="text").map((J)=>this.extractTextValue(J)).join("")}buildDataFromSections($,U,J=2){let G={};for(let q of U){let I=$.get(q.label.toLowerCase());if(q.type==="custom"&&q.parser&&I){let Q=this.getTextFromSection(I),D=q.parser(Q);this.setValueByPath(G,q.key,D)}else if(q.type==="object"&&q.children&&I){let Q=this.extractSubsections(I,J+1),D=this.buildDataFromSections(Q,q.children,J+1);this.setValueByPath(G,q.key,D)}else if(q.type==="array"&&I)if(q.itemType==="object"&&q.itemMappings){let Q=this.extractObjectArrayItems(I,J+1,q.itemMappings);this.setValueByPath(G,q.key,Q)}else{let Q=this.extractSimpleArrayItems(I);this.setValueByPath(G,q.key,Q)}else if(I){let Q=this.getTextFromSection(I),D=q.type==="number"?Number(Q):Q;this.setValueByPath(G,q.key,D)}}return G}setValueByPath($,U,J){let G=U.split("."),q=$;for(let Q=0;Q<G.length-1;Q++){let D=G[Q];if(!D)continue;let X=fS.safeParse(q[D]);if(X.success){q[D]=X.data,q=X.data;continue}let Y={};q[D]=Y,q=Y}let I=G[G.length-1];if(I)q[I]=J}getTextFromSection($){let U=[];for(let J of $)if(J.type==="paragraph"){let G=this.extractTextFromParagraph(J);if(G)U.push(G)}else if(J.type==="list"){let G=J;for(let q of G.children){let I=this.extractTextFromListItem(q);if(I)U.push(`- ${I}`)}}return U.join(`
|
|
515
|
+
`)}extractTextFromParagraph($){return this.extractInlineText($.children).trim()}extractInlineText($){let U=[];for(let J of $)if(J.type==="text")U.push(this.extractTextValue(J));else if(J.type==="emphasis"){let G=this.extractInlineText(J.children);if(G)U.push(`*${G}*`)}else if(J.type==="strong"){let G=this.extractInlineText(J.children);if(G)U.push(`**${G}**`)}return U.join("")}extractSimpleArrayItems($){let U=[];for(let J of $)if(J.type==="list"){let G=J;for(let q of G.children){let I=this.extractTextFromListItem(q);if(I)U.push(I)}}return U}extractObjectArrayItems($,U,J){let G=[],q=[],I=!1;for(let Q of $)if(Q.type==="heading"&&Q.depth===U){if(I&&q.length>0){let D=this.extractSubsections(q,U+1),X=this.buildDataFromSections(D,J,U+1);G.push(X)}q=[],I=!0}else if(I)q.push(Q);if(I&&q.length>0){let Q=this.extractSubsections(q,U+1),D=this.buildDataFromSections(Q,J,U+1);G.push(D)}return G}extractTextFromListItem($){let U=[];for(let J of $.children)if(J.type==="paragraph"){let G=this.extractTextFromParagraph(J);if(G)U.push(G)}return U.join(`
|
|
516
|
+
`)}}b$();MQ();var y7$=N.record(N.string(),N.unknown());MQ();b$();var YN$=N.object({slug:N.string(),title:N.string(),type:N.string(),entityId:N.string(),contentHash:N.string()});b$();b$();b$();var ii=h7.omit({url:!0,analyticsScript:!0}),pi=ii.extend({title:N.string().optional().describe("Optional site title override"),description:N.string().optional().describe("Optional site description override")});function D5($,U={}){let J=yS($),G=yS(U.sharedDomain??"rizom.ai").replace(/^\./,""),q=`.${G}`;if(J.endsWith(q)){let I=J.slice(0,-q.length);if(I.length>0&&!I.includes("."))return`${I}-preview.${G}`}return`preview.${J}`}function yS($){return $.trim().replace(/^https?:\/\//i,"").replace(/\/$/,"").toLowerCase()}b$();_7();var hS=["primary","secondary"];var di=N.custom(($)=>typeof $==="function","Expected a Preact component"),ni=N.strictObject({show:N.boolean().optional(),label:N.string().min(1).optional(),slot:N.enum(hS).optional(),priority:N.number().optional()}),ci=N.strictObject({id:N.string().min(1),template:N.string().min(1),content:N.unknown().optional(),dataQuery:N.looseObject({entityType:N.string().optional(),template:N.string().optional(),query:N.record(N.string(),N.unknown()).optional()}).optional(),order:N.number().optional()}),oi=N.strictObject({id:N.string().min(1),path:N.string().startsWith("/"),title:N.string().optional(),pageLabel:N.string().optional(),description:N.string().optional(),sections:N.array(ci).optional(),layout:N.string().min(1).optional(),fullscreen:N.boolean().optional(),pluginId:N.string().optional(),sourceEntityType:N.string().optional(),external:N.boolean().optional(),navigation:ni.optional()}),ai=N.strictObject({label:N.string().min(1),pluralName:N.string().min(1).optional(),layout:N.string().min(1).optional(),paginate:N.boolean().optional(),pageSize:N.number().int().positive().optional(),navigation:N.strictObject({show:N.boolean().optional(),slot:N.enum(hS).optional(),priority:N.number().optional()}).optional()}),si=N.strictObject({schema:N.custom(($)=>$ instanceof N.ZodType,"Expected a Zod schema"),component:N.custom(($)=>typeof $==="function","Expected a Preact component"),title:N.string().min(1),description:N.string(),requiredPermission:N.enum(["admin","trusted","public"]).optional(),fullscreen:N.boolean().optional()}),mS=N.strictObject({namespace:N.string().min(1),sections:N.record(N.string(),si)}),ti=N.record(N.string(),N.json()),ei=N.record(N.string(),N.record(N.string(),ti)),rS=N.strictObject({layouts:N.record(N.string(),di).refine(($)=>typeof $.default==="function",{message:'Site layouts must include a "default" component'}),routes:N.array(oi),content:ei.optional(),sections:N.union([mS,N.array(mS)]).optional(),themeOverride:N.string().optional(),headScripts:N.array(N.string()).optional(),entityDisplay:N.record(N.string(),ai),staticAssets:N.record(N.string(),N.string()).optional()}).superRefine(($,U)=>{let J=new Set;for(let[I,Q]of $.routes.entries()){if(J.has(Q.id))U.addIssue({code:"custom",path:["routes",I,"id"],message:`Duplicate route id "${Q.id}"`});J.add(Q.id);let D=Q.layout??"default";if(!$.layouts[D])U.addIssue({code:"custom",path:["routes",I,"layout"],message:`Unknown layout "${D}"`})}let G=Array.isArray($.sections)?$.sections:$.sections?[$.sections]:[],q=new Map(G.map((I)=>[I.namespace,I]));if(q.size!==G.length)U.addIssue({code:"custom",path:["sections"],message:"Section group namespaces must be unique"});for(let[I,Q]of Object.entries($.content??{})){let D=q.get(I);if(!D){U.addIssue({code:"custom",path:["content",I],message:`Content namespace "${I}" has no section group`});continue}for(let[X,Y]of Object.entries(Q)){let V=D.sections[X];if(!V){U.addIssue({code:"custom",path:["content",I,X],message:`Content section "${I}.${X}" is not defined`});continue}let W=V.schema.safeParse(Y);if(!W.success)U.addIssue({code:"custom",path:["content",I,X],message:`Content does not satisfy the "${I}.${X}" schema: ${N.prettifyError(W.error)}`})}}});var $p=N.string();function Up($){return $!==null&&typeof $==="object"&&!Array.isArray($)}var Jp=N.custom(($)=>{if(!Up($))return!1;let{plugin:U,...J}=$;if(U!==void 0&&typeof U!=="function")return!1;return rS.safeParse(J).success});function qp($,U={}){return D5($,U)}L4();import{mkdir as Pp,writeFile as Bp}from"fs/promises";import{dirname as Sp,join as sS}from"path";import{mkdtemp as Gp,mkdir as Ip,readFile as Qp,rm as Dp,writeFile as Xp}from"fs/promises";import{tmpdir as Yp}from"os";import{dirname as Vp,join as dS}from"path";var Wp=["name: Your Name Here","Delete this and write your own"];async function nS($,U,J,G,q={}){if(G.length===0)return;let I=q.env??process.env,Q=bU($),D=iS(I,Q,J.effectiveGitSyncToken),X=q.contentRepoAdminTokenSelector?iS(I,Q,q.contentRepoAdminTokenSelector):void 0,Y=X5(J.contentRepo,U),V=q.contentRepoRemoteResolver?.(J,U,D)??Rp(Y,D);if(!V)return;let W=await Gp(dS(Yp(),`brains-ops-content-sync-${J.handle}-`)),O=q.runCommand??d0,Z=q.fetchImpl??fetch;try{if(!q.contentRepoRemoteResolver){if(!X)throw Error(`${q.contentRepoAdminTokenSelector??"CONTENT_REPO_ADMIN_TOKEN"} is required to check or create content repos`);await Np(Y,X,Z)}await O("git",["clone",V,W]),await wp(W,O),await O("git",["config","user.name","brains-ops[bot]"],{cwd:W}),await O("git",["config","user.email","41898282+github-actions[bot]@users.noreply.github.com"],{cwd:W});let M=!1;for(let w of G)if(await Op(W,w))M=!0;if(!M)return;await O("git",["add","."],{cwd:W}),await O("git",["commit","-m",`chore(content): seed ${J.handle} anchor profile`],{cwd:W}),await O("git",["push","origin","HEAD:main"],{cwd:W})}finally{await Dp(W,{recursive:!0,force:!0})}}async function Op($,U){let J=dS($,U.path),G=await Qp(J,"utf8").catch(()=>{return});if(G===U.content)return!1;if(G!==void 0&&!Zp(G))return!1;return await Ip(Vp(J),{recursive:!0}),await Xp(J,U.content),!0}function Zp($){return Wp.some((U)=>$.includes(U))}function iS($,U,J){return O0(J,$,U)}function Rp($,U){if(!U)return;return`https://x-access-token:${encodeURIComponent(U)}@github.com/${$.org}/${$.name}.git`}async function Np($,U,J){let{org:G,name:q}=$,Q=`https://api.github.com/repos/${`${encodeURIComponent(G)}/${encodeURIComponent(q)}`}`,D={Accept:"application/vnd.github+json",Authorization:`Bearer ${U}`,"User-Agent":"brains-ops","X-GitHub-Api-Version":"2022-11-28"},X=await J(Q,{headers:D});if(X.ok)return;if(X.status!==404)throw Error(`Failed to check GitHub repo ${G}/${q}: ${X.status} ${await pS(X)}`);let Y=await J(`https://api.github.com/orgs/${encodeURIComponent(G)}/repos`,{method:"POST",headers:D,body:JSON.stringify({name:q,private:!0,auto_init:!1})});if(Y.ok){console.log(`Created missing content repo ${G}/${q}`);return}if(Y.status===422){if((await J(Q,{headers:D})).ok)return}throw Error(`Failed to create GitHub repo ${G}/${q}: ${Y.status} ${await pS(Y)}`)}async function pS($){let U=await $.text();return U.trim().length===0?$.statusText:U}async function wp($,U){try{await U("git",["checkout","-B","main","origin/main"],{cwd:$})}catch{await U("git",["checkout","-B","main"],{cwd:$})}}Y5();RJ();async function d8($,U,J,G,q={}){let I=dX(U.pilot.githubOrg);for(let Q of J){let D={};if(G){let O=await G(Q);if(O!==void 0)D=O}let X=await I(Q),Y=D.brainYaml??X.brainYaml,V=D.envFile??X.envFile,W=D.contentRepoFiles??X.contentRepoFiles??[];if(V)await V5($,Q.handle,".env",V);if(Y)await V5($,Q.handle,"brain.yaml",Y);await nS($,U.pilot.githubOrg,Q,W,{contentRepoAdminTokenSelector:U.pilot.contentRepoAdminToken,...q});for(let O of W)await V5($,Q.handle,sS("content",O.path),O.content)}}async function V5($,U,J,G){let q=sS($,"users",U,J);await Pp(Sp(q),{recursive:!0}),await Bp(q,G)}async function nX($,U){let J=await M0($),G=J.users.find((q)=>q.handle===U);if(!G)throw Error(`Unknown user handle: ${U}`);return{registry:J,user:G}}async function tS($,U){let J=await M0($),G=J.cohorts.find((q)=>q.id===U);if(!G)throw Error(`Unknown cohort: ${U}`);return{registry:J,users:J.users.filter((q)=>q.cohort===G.id)}}async function eS($){let U=await M0($);return{registry:U,users:U.users}}async function W5($,U,J,G={}){let{registry:q,user:I}=await nX($,U);await d8($,q,[I],J,G)}vq();P8();import{access as Lp,mkdir as $2,readFile as Ep,writeFile as J2}from"fs/promises";import{basename as Cp,join as n8}from"path";async function O5($,U,J){let G=sU.parse(U),q=sU.parse(J.cohort),I=n8($,"users"),Q=n8($,"cohorts"),D=n8(I,`${G}.yaml`),X=n8(I,`${G}.secrets.yaml`),Y=n8(I,`${G}.secrets.yaml.age`),V=n8(Q,`${q}.yaml`);await Promise.all([$2(I,{recursive:!0}),$2(Q,{recursive:!0})]);let W=await U2(D,Fp(G,J.anchorId)),Z=await kp(Y)?!1:await U2(X,bp(G)),{addedToCohort:M}=await _p(V,G);return{handle:G,cohort:q,userPath:D,secretsTemplatePath:X,cohortPath:V,createdUser:W,createdSecretsTemplate:Z,addedToCohort:M}}async function _p($,U){let J=await vp($);if(J.members.includes(U))return{addedToCohort:!1};let G={...J,members:[...J.members,U].sort()};return await J2($,up(G)),{addedToCohort:!0}}async function vp($){try{let U=await Ep($,"utf8"),J=dG(U,cJ);if(!J.ok)throw Error(`${Cp($)}: ${J.error}`);return J.data}catch(U){if(fp(U))return{members:[]};throw U}}function Fp($,U){return[`handle: ${$}`,"anchorProfile:",` name: ${yp($)}`,"discord:"," enabled: true",...U?[` anchorUserId: ${JSON.stringify(U)}`]:[],""].join(`
|
|
517
|
+
`)}function bp($){return["# local per-user secret staging file",`# fill values, run \`bunx brains-ops secrets:encrypt . ${$}\`, then the plaintext file will be removed`,"discordBotToken: ","atprotoAppPassword: ","# For custom-domain sites, paste PEMs with literal \\n escapes.","certificatePem: ","privateKeyPem: ",""].join(`
|
|
518
|
+
`)}function up($){return["members:",...$.members.map((U)=>` - ${U}`),...$.brainVersionOverride?[`brainVersionOverride: ${$.brainVersionOverride}`]:[],...$.bundlesOverride?["bundlesOverride:",...$.bundlesOverride.map((U)=>` - ${U}`)]:[],...$.addOverride?["addOverride:",...$.addOverride.map((U)=>` - ${U}`)]:[],...$.removeOverride?["removeOverride:",...$.removeOverride.map((U)=>` - ${U}`)]:[],...$.aiApiKeyOverride?[`aiApiKeyOverride: ${$.aiApiKeyOverride}`]:[],...$.gitSyncTokenOverride?[`gitSyncTokenOverride: ${$.gitSyncTokenOverride}`]:[],""].join(`
|
|
519
|
+
`)}async function U2($,U){try{return await J2($,U,{flag:"wx"}),!0}catch(J){if(xp(J))return!1;throw J}}async function kp($){try{return await Lp($),!0}catch{return!1}}function xp($){return q2($,"EEXIST")}function fp($){return q2($,"ENOENT")}function q2($,U){return typeof $==="object"&&$!==null&&"code"in $&&$.code===U}function yp($){return $.split("-").filter((U)=>U.length>0).map((U)=>`${U[0]?.toUpperCase()??""}${U.slice(1)}`).join(" ")}async function Z5($,U,J,G={}){let{registry:q,users:I}=await tS($,U);await d8($,q,I,J,G)}async function d4($,U,J={}){let{registry:G,users:q}=await eS($);await d8($,G,q,U,J)}import{parseArgs as mp}from"util";function I0($){return $}class G2 extends Error{constructor($){super($);this.name="CliUsageError"}}function hp($,U){let J={...U};for(let G of $)for(let[q,I]of Object.entries(G.flags??{})){let Q=J[q];if(Q===void 0){J[q]=I;continue}if(Q.type!==I.type||Q.short!==I.short||Q.default!==I.default)throw Error(`Conflicting definitions for flag --${q}: commands must agree on type, short, and default`)}return J}function rp($){let U={};for(let[J,G]of Object.entries($))U[J]={type:G.type,...G.short!==void 0?{short:G.short}:{},...G.default!==void 0?{default:G.default}:{}};return U}function lp($){if(!($ instanceof Error)||!("code"in $))return!1;return $.code==="ERR_PARSE_ARGS_UNKNOWN_OPTION"||$.code==="ERR_PARSE_ARGS_INVALID_OPTION_VALUE"}function I2($,U){let J=hp(U.commands,U.globalFlags??{}),G,q;try{({values:G,positionals:q}=mp({args:$,options:rp(J),allowPositionals:!0,strict:U.strict??!0}))}catch(Q){if(lp(Q))throw new G2(Q.message.split(". ")[0]??Q.message);throw Q}if("help"in J&&G.help===!0)return{command:"help",args:[],flags:{help:!0}};if("version"in J&&G.version===!0)return{command:"version",args:[],flags:{version:!0}};let I={};for(let[Q,D]of Object.entries(J)){let X=G[Q];if(typeof X==="string"&&D.type==="string")I[Q]=X;else if(typeof X==="boolean"&&D.type==="boolean")I[Q]=X}return{command:q[0]??"help",args:q.slice(1),flags:I}}function Q2($){let U=$.reduce((J,G)=>Math.max(J,G.label.length),0);return $.map((J)=>` ${J.label.padEnd(U)} ${J.description}`)}function ip($){return Q2($.map((U)=>({label:U.usage?`${U.name} ${U.usage}`:U.name,description:U.description})))}function pp($,U){let J=U.type==="string"?` ${U.placeholder??"<value>"}`:"",G=U.short!==void 0?`, -${U.short}`:"";return`--${$}${J}${G}`}function D2($){return Q2(Object.entries($).map(([U,J])=>({label:pp(U,J),description:J.description})))}function X2($,U){return`Usage: ${$} ${U.name}${U.usage?` ${U.usage}`:""}`}function dp($){return JSON.stringify(Object.entries($).map(([U,J])=>[U,J.type,J.short??"",J.description,J.placeholder??"",J.default??""]).sort((U,J)=>String(U[0]).localeCompare(String(J[0]))))}function np($){let U=[],J=new Map;for(let q of $){let I=q.flags??{};if(Object.keys(I).length===0)continue;let Q=dp(I),D=J.get(Q);if(D){D.names.push(q.name);continue}let X={names:[q.name],flags:I};J.set(Q,X),U.push(X)}let G=[];for(let q of U)G.push("",`${q.names.join(" / ")} options:`),G.push(...D2(q.flags));return G}function Y2($){let U=[$.intro,"",`Usage: ${$.cliName} ${$.usage??"<command> [args]"}`,"","Commands:",...ip($.commands)];if($.globalFlags&&Object.keys($.globalFlags).length>0)U.push("","Options:",...D2($.globalFlags));return U.push(...np($.commands)),U.join(`
|
|
520
|
+
`)}function V2($){let U=new Map;for(let J of $){if(U.has(J.name))throw Error(`Duplicate command name: ${J.name}`);U.set(J.name,J)}return U}function a0($,U){let J=$[U];return typeof J==="string"?J:void 0}function cX($,U){let J=$[U];return typeof J==="boolean"?J:void 0}import{existsSync as Ec,mkdirSync as Cc,readFileSync as JM,writeFileSync as qM}from"fs";import{dirname as _c,join as RC}from"path";function R5($){return $ instanceof Uint8Array||ArrayBuffer.isView($)&&$.constructor.name==="Uint8Array"&&"BYTES_PER_ELEMENT"in $&&$.BYTES_PER_ELEMENT===1}function $0($,U=""){if(typeof $!=="number"){let J=U&&`"${U}" `;throw TypeError(`${J}expected number, got ${typeof $}`)}if(!Number.isSafeInteger($)||$<0){let J=U&&`"${U}" `;throw RangeError(`${J}expected integer >= 0, got ${$}`)}}function z0($,U,J=""){let G=R5($),q=$?.length,I=U!==void 0;if(!G||I&&q!==U){let Q=J&&`"${J}" `,D=I?` of length ${U}`:"",X=G?`length=${q}`:`type=${typeof $}`,Y=Q+"expected Uint8Array"+D+", got "+X;if(!G)throw TypeError(Y);throw RangeError(Y)}return $}function HJ($){if(typeof $!=="function"||typeof $.create!=="function")throw TypeError("Hash must wrapped by utils.createHasher");if($0($.outputLen),$0($.blockLen),$.outputLen<1)throw Error('"outputLen" must be >= 1');if($.blockLen<1)throw Error('"blockLen" must be >= 1')}function c8($,U=!0){if($.destroyed)throw Error("Hash instance has been destroyed");if(U&&$.finished)throw Error("Hash#digest() has already been called")}function oX($,U){z0($,void 0,"digestInto() output");let J=U.outputLen;if($.length<J)throw RangeError('"digestInto() output" expected to be of length >='+J)}function aX($){return new Uint32Array($.buffer,$.byteOffset,Math.floor($.byteLength/4))}function s0(...$){for(let U=0;U<$.length;U++)$[U].fill(0)}function o8($){return new DataView($.buffer,$.byteOffset,$.byteLength)}function xU($,U){return $<<32-U|$>>>U}function f$($,U){return $<<U|$>>>32-U>>>0}var cp=(()=>new Uint8Array(new Uint32Array([287454020]).buffer)[0]===68)();function op($){return $<<24&4278190080|$<<8&16711680|$>>>8&65280|$>>>24&255}function ap($){for(let U=0;U<$.length;U++)$[U]=op($[U]);return $}var N5=cp?($)=>$:ap,O2=(()=>typeof Uint8Array.from([]).toHex==="function"&&typeof Uint8Array.fromHex==="function")(),sp=Array.from({length:256},($,U)=>U.toString(16).padStart(2,"0"));function sX($){if(z0($),O2)return $.toHex();let U="";for(let J=0;J<$.length;J++)U+=sp[$[J]];return U}var MJ={_0:48,_9:57,A:65,F:70,a:97,f:102};function W2($){if($>=MJ._0&&$<=MJ._9)return $-MJ._0;if($>=MJ.A&&$<=MJ.F)return $-(MJ.A-10);if($>=MJ.a&&$<=MJ.f)return $-(MJ.a-10);return}function n4($){if(typeof $!=="string")throw TypeError("hex string expected, got "+typeof $);if(O2)try{return Uint8Array.fromHex($)}catch(q){if(q instanceof SyntaxError)throw RangeError(q.message);throw q}let U=$.length,J=U/2;if(U%2)throw RangeError("hex string expected, got unpadded hex of length "+U);let G=new Uint8Array(J);for(let q=0,I=0;q<J;q++,I+=2){let Q=W2($.charCodeAt(I)),D=W2($.charCodeAt(I+1));if(Q===void 0||D===void 0){let X=$[I]+$[I+1];throw RangeError('hex string expected, got non-hex character "'+X+'" at index '+I)}G[q]=Q*16+D}return G}function tp($){if(typeof $!=="string")throw TypeError("string expected");return new Uint8Array(new TextEncoder().encode($))}function w5($,U=""){if(typeof $==="string")return tp($);return z0($,void 0,U)}function M5(...$){let U=0;for(let G=0;G<$.length;G++){let q=$[G];z0(q),U+=q.length}let J=new Uint8Array(U);for(let G=0,q=0;G<$.length;G++){let I=$[G];J.set(I,q),q+=I.length}return J}function tX($,U){if(U!==void 0&&{}.toString.call(U)!=="[object Object]")throw TypeError("options must be object or undefined");return Object.assign($,U)}function H5($,U={}){let J=(q,I)=>$(I).update(q).digest(),G=$(void 0);return J.outputLen=G.outputLen,J.blockLen=G.blockLen,J.canXOF=G.canXOF,J.create=(q)=>$(q),Object.assign(J,U),Object.freeze(J)}function TJ($=32){$0($,"bytesLength");let U=typeof globalThis==="object"?globalThis.crypto:null;if(typeof U?.getRandomValues!=="function")throw Error("crypto.getRandomValues must be defined");if($>65536)throw RangeError(`"bytesLength" expected <= 65536, got ${$}`);return U.getRandomValues(new Uint8Array($))}var T5=($)=>({oid:Uint8Array.from([6,9,96,134,72,1,101,3,4,2,$])});class z5{oHash;iHash;blockLen;outputLen;canXOF=!1;finished=!1;destroyed=!1;constructor($,U){if(HJ($),z0(U,void 0,"key"),this.iHash=$.create(),typeof this.iHash.update!=="function")throw Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;let J=this.blockLen,G=new Uint8Array(J);G.set(U.length>J?$.create().update(U).digest():U);for(let q=0;q<G.length;q++)G[q]^=54;this.iHash.update(G),this.oHash=$.create();for(let q=0;q<G.length;q++)G[q]^=106;this.oHash.update(G),s0(G)}update($){return c8(this),this.iHash.update($),this}digestInto($){c8(this),oX($,this),this.finished=!0;let U=$.subarray(0,this.outputLen);this.iHash.digestInto(U),this.oHash.update(U),this.oHash.digestInto(U),this.destroy()}digest(){let $=new Uint8Array(this.oHash.outputLen);return this.digestInto($),$}_cloneInto($){$||=Object.create(Object.getPrototypeOf(this),{});let{oHash:U,iHash:J,finished:G,destroyed:q,blockLen:I,outputLen:Q}=this;return $=$,$.finished=G,$.destroyed=q,$.blockLen=I,$.outputLen=Q,$.oHash=U._cloneInto($.oHash),$.iHash=J._cloneInto($.iHash),$}clone(){return this._cloneInto()}destroy(){this.destroyed=!0,this.oHash.destroy(),this.iHash.destroy()}}var eU=(()=>{let $=(U,J,G)=>new z5(U,J).update(G).digest();return $.create=(U,J)=>new z5(U,J),$})();function c4($,U,J){if(HJ($),J===void 0)J=new Uint8Array($.outputLen);return eU($,J,U)}var A5=Uint8Array.of(0),Z2=Uint8Array.of();function K5($,U,J,G=32){HJ($),$0(G,"length"),z0(U,void 0,"prk");let q=$.outputLen;if(U.length<q)throw Error('"prk" must be at least HashLen octets');if(G>255*q)throw Error("Length must be <= 255*HashLen");let I=Math.ceil(G/q);if(J===void 0)J=Z2;else z0(J,void 0,"info");let Q=new Uint8Array(I*q),D=eU.create($,U),X=D._cloneInto(),Y=new Uint8Array(D.outputLen);for(let V=0;V<I;V++)A5[0]=V+1,X.update(V===0?Z2:Y).update(J).update(A5).digestInto(Y),Q.set(Y,q*V),D._cloneInto(X);return D.destroy(),X.destroy(),s0(Y,A5),Q.slice(0,G)}var Gq=($,U,J,G,q)=>K5($,c4($,U,J),G,q);function R2($,U,J){return $&U^~$&J}function N2($,U,J){return $&U^$&J^U&J}class eX{blockLen;outputLen;canXOF=!1;padOffset;isLE;buffer;view;finished=!1;length=0;pos=0;destroyed=!1;constructor($,U,J,G){this.blockLen=$,this.outputLen=U,this.padOffset=J,this.isLE=G,this.buffer=new Uint8Array($),this.view=o8(this.buffer)}update($){c8(this),z0($);let{view:U,buffer:J,blockLen:G}=this,q=$.length;for(let I=0;I<q;){let Q=Math.min(G-this.pos,q-I);if(Q===G){let D=o8($);for(;G<=q-I;I+=G)this.process(D,I);continue}if(J.set($.subarray(I,I+Q),this.pos),this.pos+=Q,I+=Q,this.pos===G)this.process(U,0),this.pos=0}return this.length+=$.length,this.roundClean(),this}digestInto($){c8(this),oX($,this),this.finished=!0;let{buffer:U,view:J,blockLen:G,isLE:q}=this,{pos:I}=this;if(U[I++]=128,s0(this.buffer.subarray(I)),this.padOffset>G-I)this.process(J,0),I=0;for(let V=I;V<G;V++)U[V]=0;J.setBigUint64(G-8,BigInt(this.length*8),q),this.process(J,0);let Q=o8($),D=this.outputLen;if(D%4)throw Error("_sha2: outputLen must be aligned to 32bit");let X=D/4,Y=this.get();if(X>Y.length)throw Error("_sha2: outputLen bigger than state");for(let V=0;V<X;V++)Q.setUint32(4*V,Y[V],q)}digest(){let{buffer:$,outputLen:U}=this;this.digestInto($);let J=$.slice(0,U);return this.destroy(),J}_cloneInto($){$||=new this.constructor,$.set(...this.get());let{blockLen:U,buffer:J,length:G,finished:q,destroyed:I,pos:Q}=this;if($.destroyed=I,$.finished=q,$.length=G,$.pos=Q,G%U)$.buffer.set(J);return $}clone(){return this._cloneInto()}}var zJ=Uint32Array.from([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),AJ=Uint32Array.from([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]),A0=Uint32Array.from([3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]),K0=Uint32Array.from([1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209]);var $9=BigInt(4294967295),w2=BigInt(32);function ep($,U=!1){if(U)return{h:Number($&$9),l:Number($>>w2&$9)};return{h:Number($>>w2&$9)|0,l:Number($&$9)|0}}function M2($,U=!1){let J=$.length,G=new Uint32Array(J),q=new Uint32Array(J);for(let I=0;I<J;I++){let{h:Q,l:D}=ep($[I],U);[G[I],q[I]]=[Q,D]}return[G,q]}var g5=($,U,J)=>$>>>J,j5=($,U,J)=>$<<32-J|U>>>J,XG=($,U,J)=>$>>>J|U<<32-J,YG=($,U,J)=>$<<32-J|U>>>J,o4=($,U,J)=>$<<64-J|U>>>J-32,a4=($,U,J)=>$>>>J-32|U<<64-J;function $J($,U,J,G){let q=(U>>>0)+(G>>>0);return{h:$+J+(q/4294967296|0)|0,l:q|0}}var H2=($,U,J)=>($>>>0)+(U>>>0)+(J>>>0),T2=($,U,J,G)=>U+J+G+($/4294967296|0)|0,z2=($,U,J,G)=>($>>>0)+(U>>>0)+(J>>>0)+(G>>>0),A2=($,U,J,G,q)=>U+J+G+q+($/4294967296|0)|0,K2=($,U,J,G,q)=>($>>>0)+(U>>>0)+(J>>>0)+(G>>>0)+(q>>>0),g2=($,U,J,G,q,I)=>U+J+G+q+I+($/4294967296|0)|0;var Ud=Uint32Array.from([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),Iq=new Uint32Array(64);class P5 extends eX{constructor($){super(64,$,8,!1)}get(){let{A:$,B:U,C:J,D:G,E:q,F:I,G:Q,H:D}=this;return[$,U,J,G,q,I,Q,D]}set($,U,J,G,q,I,Q,D){this.A=$|0,this.B=U|0,this.C=J|0,this.D=G|0,this.E=q|0,this.F=I|0,this.G=Q|0,this.H=D|0}process($,U){for(let V=0;V<16;V++,U+=4)Iq[V]=$.getUint32(U,!1);for(let V=16;V<64;V++){let W=Iq[V-15],O=Iq[V-2],Z=xU(W,7)^xU(W,18)^W>>>3,M=xU(O,17)^xU(O,19)^O>>>10;Iq[V]=M+Iq[V-7]+Z+Iq[V-16]|0}let{A:J,B:G,C:q,D:I,E:Q,F:D,G:X,H:Y}=this;for(let V=0;V<64;V++){let W=xU(Q,6)^xU(Q,11)^xU(Q,25),O=Y+W+R2(Q,D,X)+Ud[V]+Iq[V]|0,M=(xU(J,2)^xU(J,13)^xU(J,22))+N2(J,G,q)|0;Y=X,X=D,D=Q,Q=I+O|0,I=q,q=G,G=J,J=O+M|0}J=J+this.A|0,G=G+this.B|0,q=q+this.C|0,I=I+this.D|0,Q=Q+this.E|0,D=D+this.F|0,X=X+this.G|0,Y=Y+this.H|0,this.set(J,G,q,I,Q,D,X,Y)}roundClean(){s0(Iq)}destroy(){this.destroyed=!0,this.set(0,0,0,0,0,0,0,0),s0(this.buffer)}}class j2 extends P5{A=zJ[0]|0;B=zJ[1]|0;C=zJ[2]|0;D=zJ[3]|0;E=zJ[4]|0;F=zJ[5]|0;G=zJ[6]|0;H=zJ[7]|0;constructor(){super(32)}}class Jd extends P5{A=AJ[0]|0;B=AJ[1]|0;C=AJ[2]|0;D=AJ[3]|0;E=AJ[4]|0;F=AJ[5]|0;G=AJ[6]|0;H=AJ[7]|0;constructor(){super(28)}}var P2=(()=>M2(["0x428a2f98d728ae22","0x7137449123ef65cd","0xb5c0fbcfec4d3b2f","0xe9b5dba58189dbbc","0x3956c25bf348b538","0x59f111f1b605d019","0x923f82a4af194f9b","0xab1c5ed5da6d8118","0xd807aa98a3030242","0x12835b0145706fbe","0x243185be4ee4b28c","0x550c7dc3d5ffb4e2","0x72be5d74f27b896f","0x80deb1fe3b1696b1","0x9bdc06a725c71235","0xc19bf174cf692694","0xe49b69c19ef14ad2","0xefbe4786384f25e3","0x0fc19dc68b8cd5b5","0x240ca1cc77ac9c65","0x2de92c6f592b0275","0x4a7484aa6ea6e483","0x5cb0a9dcbd41fbd4","0x76f988da831153b5","0x983e5152ee66dfab","0xa831c66d2db43210","0xb00327c898fb213f","0xbf597fc7beef0ee4","0xc6e00bf33da88fc2","0xd5a79147930aa725","0x06ca6351e003826f","0x142929670a0e6e70","0x27b70a8546d22ffc","0x2e1b21385c26c926","0x4d2c6dfc5ac42aed","0x53380d139d95b3df","0x650a73548baf63de","0x766a0abb3c77b2a8","0x81c2c92e47edaee6","0x92722c851482353b","0xa2bfe8a14cf10364","0xa81a664bbc423001","0xc24b8b70d0f89791","0xc76c51a30654be30","0xd192e819d6ef5218","0xd69906245565a910","0xf40e35855771202a","0x106aa07032bbd1b8","0x19a4c116b8d2d0c8","0x1e376c085141ab53","0x2748774cdf8eeb99","0x34b0bcb5e19b48a8","0x391c0cb3c5c95a63","0x4ed8aa4ae3418acb","0x5b9cca4f7763e373","0x682e6ff3d6b2b8a3","0x748f82ee5defb2fc","0x78a5636f43172f60","0x84c87814a1f0ab72","0x8cc702081a6439ec","0x90befffa23631e28","0xa4506cebde82bde9","0xbef9a3f7b2c67915","0xc67178f2e372532b","0xca273eceea26619c","0xd186b8c721c0c207","0xeada7dd6cde0eb1e","0xf57d4f7fee6ed178","0x06f067aa72176fba","0x0a637dc5a2c898a6","0x113f9804bef90dae","0x1b710b35131c471b","0x28db77f523047d84","0x32caab7b40c72493","0x3c9ebe0a15c9bebc","0x431d67c49c100d4c","0x4cc5d4becb3e42b6","0x597f299cfc657e2a","0x5fcb6fab3ad6faec","0x6c44198c4a475817"].map(($)=>BigInt($))))(),qd=(()=>P2[0])(),Gd=(()=>P2[1])(),Qq=new Uint32Array(80),Dq=new Uint32Array(80);class s4 extends eX{constructor($){super(128,$,16,!1)}get(){let{Ah:$,Al:U,Bh:J,Bl:G,Ch:q,Cl:I,Dh:Q,Dl:D,Eh:X,El:Y,Fh:V,Fl:W,Gh:O,Gl:Z,Hh:M,Hl:w}=this;return[$,U,J,G,q,I,Q,D,X,Y,V,W,O,Z,M,w]}set($,U,J,G,q,I,Q,D,X,Y,V,W,O,Z,M,w){this.Ah=$|0,this.Al=U|0,this.Bh=J|0,this.Bl=G|0,this.Ch=q|0,this.Cl=I|0,this.Dh=Q|0,this.Dl=D|0,this.Eh=X|0,this.El=Y|0,this.Fh=V|0,this.Fl=W|0,this.Gh=O|0,this.Gl=Z|0,this.Hh=M|0,this.Hl=w|0}process($,U){for(let P=0;P<16;P++,U+=4)Qq[P]=$.getUint32(U),Dq[P]=$.getUint32(U+=4);for(let P=16;P<80;P++){let C=Qq[P-15]|0,F=Dq[P-15]|0,f=XG(C,F,1)^XG(C,F,8)^g5(C,F,7),E=YG(C,F,1)^YG(C,F,8)^j5(C,F,7),p=Qq[P-2]|0,b=Dq[P-2]|0,h=XG(p,b,19)^o4(p,b,61)^g5(p,b,6),s=YG(p,b,19)^a4(p,b,61)^j5(p,b,6),m=z2(E,s,Dq[P-7],Dq[P-16]),_=A2(m,f,h,Qq[P-7],Qq[P-16]);Qq[P]=_|0,Dq[P]=m|0}let{Ah:J,Al:G,Bh:q,Bl:I,Ch:Q,Cl:D,Dh:X,Dl:Y,Eh:V,El:W,Fh:O,Fl:Z,Gh:M,Gl:w,Hh:H,Hl:g}=this;for(let P=0;P<80;P++){let C=XG(V,W,14)^XG(V,W,18)^o4(V,W,41),F=YG(V,W,14)^YG(V,W,18)^a4(V,W,41),f=V&O^~V&M,E=W&Z^~W&w,p=K2(g,F,E,Gd[P],Dq[P]),b=g2(p,H,C,f,qd[P],Qq[P]),h=p|0,s=XG(J,G,28)^o4(J,G,34)^o4(J,G,39),m=YG(J,G,28)^a4(J,G,34)^a4(J,G,39),_=J&q^J&Q^q&Q,v=G&I^G&D^I&D;H=M|0,g=w|0,M=O|0,w=Z|0,O=V|0,Z=W|0,{h:V,l:W}=$J(X|0,Y|0,b|0,h|0),X=Q|0,Y=D|0,Q=q|0,D=I|0,q=J|0,I=G|0;let j=H2(h,m,v);J=T2(j,b,s,_),G=j|0}({h:J,l:G}=$J(this.Ah|0,this.Al|0,J|0,G|0)),{h:q,l:I}=$J(this.Bh|0,this.Bl|0,q|0,I|0),{h:Q,l:D}=$J(this.Ch|0,this.Cl|0,Q|0,D|0),{h:X,l:Y}=$J(this.Dh|0,this.Dl|0,X|0,Y|0),{h:V,l:W}=$J(this.Eh|0,this.El|0,V|0,W|0),{h:O,l:Z}=$J(this.Fh|0,this.Fl|0,O|0,Z|0),{h:M,l:w}=$J(this.Gh|0,this.Gl|0,M|0,w|0),{h:H,l:g}=$J(this.Hh|0,this.Hl|0,H|0,g|0),this.set(J,G,q,I,Q,D,X,Y,V,W,O,Z,M,w,H,g)}roundClean(){s0(Qq,Dq)}destroy(){this.destroyed=!0,s0(this.buffer),this.set(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0)}}class B2 extends s4{Ah=K0[0]|0;Al=K0[1]|0;Bh=K0[2]|0;Bl=K0[3]|0;Ch=K0[4]|0;Cl=K0[5]|0;Dh=K0[6]|0;Dl=K0[7]|0;Eh=K0[8]|0;El=K0[9]|0;Fh=K0[10]|0;Fl=K0[11]|0;Gh=K0[12]|0;Gl=K0[13]|0;Hh=K0[14]|0;Hl=K0[15]|0;constructor(){super(64)}}class Id extends s4{Ah=A0[0]|0;Al=A0[1]|0;Bh=A0[2]|0;Bl=A0[3]|0;Ch=A0[4]|0;Cl=A0[5]|0;Dh=A0[6]|0;Dl=A0[7]|0;Eh=A0[8]|0;El=A0[9]|0;Fh=A0[10]|0;Fl=A0[11]|0;Gh=A0[12]|0;Gl=A0[13]|0;Hh=A0[14]|0;Hl=A0[15]|0;constructor(){super(48)}}var b0=Uint32Array.from([2352822216,424955298,1944164710,2312950998,502970286,855612546,1738396948,1479516111,258812777,2077511080,2011393907,79989058,1067287976,1780299464,286451373,2446758561]),u0=Uint32Array.from([573645204,4230739756,2673172387,3360449730,596883563,1867755857,2520282905,1497426621,2519219938,2827943907,3193839141,1401305490,721525244,746961066,246885852,2177182882]);class Qd extends s4{Ah=b0[0]|0;Al=b0[1]|0;Bh=b0[2]|0;Bl=b0[3]|0;Ch=b0[4]|0;Cl=b0[5]|0;Dh=b0[6]|0;Dl=b0[7]|0;Eh=b0[8]|0;El=b0[9]|0;Fh=b0[10]|0;Fl=b0[11]|0;Gh=b0[12]|0;Gl=b0[13]|0;Hh=b0[14]|0;Hl=b0[15]|0;constructor(){super(28)}}class Dd extends s4{Ah=u0[0]|0;Al=u0[1]|0;Bh=u0[2]|0;Bl=u0[3]|0;Ch=u0[4]|0;Cl=u0[5]|0;Dh=u0[6]|0;Dl=u0[7]|0;Eh=u0[8]|0;El=u0[9]|0;Fh=u0[10]|0;Fl=u0[11]|0;Gh=u0[12]|0;Gl=u0[13]|0;Hh=u0[14]|0;Hl=u0[15]|0;constructor(){super(32)}}var U0=H5(()=>new j2,T5(1));var U9=H5(()=>new B2,T5(3));/*! scure-base - MIT License (c) 2022 Paul Miller (paulmillr.com) */function Q9($){return $ instanceof Uint8Array||ArrayBuffer.isView($)&&$.constructor.name==="Uint8Array"&&"BYTES_PER_ELEMENT"in $&&$.BYTES_PER_ELEMENT===1}function L5($){if(!Q9($))throw TypeError("Uint8Array expected")}function _2($,U){if(!Array.isArray(U))return!1;if(U.length===0)return!0;if($)return U.every((J)=>typeof J==="string");else return U.every((J)=>Number.isSafeInteger(J))}function v2($){if(typeof $!=="function")throw TypeError("function expected");return!0}function Xq($,U){if(typeof U!=="string")throw TypeError(`${$}: string expected`);return!0}function e4($){if(typeof $!=="number")throw TypeError(`number expected, got ${typeof $}`);if(!Number.isSafeInteger($))throw RangeError(`invalid integer: ${$}`)}function q9($){if(!Array.isArray($))throw TypeError("array expected")}function G9($,U){if(!_2(!0,U))throw TypeError(`${$}: array of strings expected`)}function E5($,U){if(!_2(!1,U))throw TypeError(`${$}: array of numbers expected`)}function HU(...$){let U=(I)=>I,J=(I,Q)=>(D)=>I(Q(D)),G=$.map((I)=>I.encode).reduceRight(J,U),q=$.map((I)=>I.decode).reduce(J,U);return{encode:G,decode:q}}function TU($){let U=typeof $==="string"?$.split(""):$,J=U.length;G9("alphabet",U);let G=new Map(U.map((q,I)=>[q,I]));return{encode:(q)=>{return q9(q),q.map((I)=>{if(!Number.isSafeInteger(I)||I<0||I>=J)throw Error(`alphabet.encode: digit index outside alphabet "${I}". Allowed: ${$}`);return U[I]})},decode:(q)=>{return q9(q),q.map((I)=>{Xq("alphabet.decode",I);let Q=G.get(I);if(Q===void 0)throw Error(`Unknown letter: "${I}". Allowed: ${$}`);return Q})}}}function zU($=""){return Xq("join",$),{encode:(U)=>{return G9("join.decode",U),U.join($)},decode:(U)=>{return Xq("join.decode",U),U.split($)}}}function D9($,U="="){return e4($),Xq("padding",U),{encode(J){G9("padding.encode",J);while(J.length*$%8)J.push(U);return J},decode(J){G9("padding.decode",J);let G=J.length;if(G*$%8)throw Error("padding: invalid, string should have whole number of bytes");for(;G>0&&J[G-1]===U;G--)if((G-1)*$%8===0)throw Error("padding: invalid, string has too much padding");return J.slice(0,G)}}}function F2($){return v2($),{encode:(U)=>U,decode:(U)=>$(U)}}function S2($,U,J){if(U<2)throw RangeError(`convertRadix: invalid from=${U}, base cannot be less than 2`);if(J<2)throw RangeError(`convertRadix: invalid to=${J}, base cannot be less than 2`);if(q9($),!$.length)return[];let G=0,q=[],I=Array.from($,(D)=>{if(e4(D),D<0||D>=U)throw Error(`invalid integer: ${D}`);return D}),Q=I.length;while(!0){let D=0,X=!0;for(let Y=G;Y<Q;Y++){let V=I[Y],W=U*D,O=W+V;if(!Number.isSafeInteger(O)||W/U!==D||O-V!==W)throw Error("convertRadix: carry overflow");let Z=O/J;D=O%J;let M=Math.floor(Z);if(I[Y]=M,!Number.isSafeInteger(M)||M*J+D!==O)throw Error("convertRadix: carry overflow");if(!X)continue;else if(!M)G=Y;else X=!1}if(q.push(D),X)break}for(let D=0;D<$.length-1&&$[D]===0;D++)q.push(0);return q.reverse()}var b2=($,U)=>U===0?$:b2(U,$%U),I9=($,U)=>$+(U-b2($,U)),J9=(()=>{let $=[];for(let U=0;U<40;U++)$.push(2**U);return $})();function B5($,U,J,G){if(q9($),U<=0||U>32)throw RangeError(`convertRadix2: wrong from=${U}`);if(J<=0||J>32)throw RangeError(`convertRadix2: wrong to=${J}`);if(I9(U,J)>32)throw Error(`convertRadix2: carry overflow from=${U} to=${J} carryBits=${I9(U,J)}`);let q=0,I=0,Q=J9[U],D=J9[J]-1,X=[];for(let Y of $){if(e4(Y),Y>=Q)throw Error(`convertRadix2: invalid data word=${Y} from=${U}`);if(q=q<<U|Y,I+U>32)throw Error(`convertRadix2: carry overflow pos=${I} from=${U}`);I+=U;for(;I>=J;I-=J)X.push((q>>I-J&D)>>>0);let V=J9[I];if(V===void 0)throw Error("invalid carry");q&=V-1}if(q=q<<J-I&D,!G&&I>=U)throw Error("Excess padding");if(!G&&q>0)throw Error(`Non-zero padding: ${q}`);if(G&&I>0)X.push(q>>>0);return X}function Xd($){e4($);let U=256;return{encode:(J)=>{if(!Q9(J))throw TypeError("radix.encode input should be Uint8Array");return S2(Array.from(J),U,$)},decode:(J)=>{return E5("radix.decode",J),Uint8Array.from(S2(J,$,U))}}}function PU($,U=!1){if(e4($),$<=0||$>32)throw RangeError("radix2: bits should be in (0..32]");if(I9(8,$)>32||I9($,8)>32)throw RangeError("radix2: carry overflow");return{encode:(J)=>{if(!Q9(J))throw TypeError("radix2.encode input should be Uint8Array");return B5(Array.from(J),8,$,!U)},decode:(J)=>{return E5("radix2.decode",J),Uint8Array.from(B5(J,$,8,U))}}}function L2($){return v2($),function(...U){try{return $.apply(null,U)}catch(J){}}}var p5$=Object.freeze(HU(PU(4),TU("0123456789ABCDEF"),zU(""))),d5$=Object.freeze(HU(PU(5),TU("ABCDEFGHIJKLMNOPQRSTUVWXYZ234567"),D9(5),zU(""))),n5$=Object.freeze(HU(PU(5),TU("ABCDEFGHIJKLMNOPQRSTUVWXYZ234567"),zU(""))),c5$=Object.freeze(HU(PU(5),TU("0123456789ABCDEFGHIJKLMNOPQRSTUV"),D9(5),zU(""))),o5$=Object.freeze(HU(PU(5),TU("0123456789ABCDEFGHIJKLMNOPQRSTUV"),zU(""))),a5$=Object.freeze(HU(PU(5),TU("0123456789ABCDEFGHJKMNPQRSTVWXYZ"),zU(""),F2(($)=>$.toUpperCase().replace(/O/g,"0").replace(/[IL]/g,"1")))),u2=(()=>typeof Uint8Array.from([]).toBase64==="function"&&typeof Uint8Array.fromBase64==="function")(),Yd=/[\t\n\f\r ]/,k2=($,U)=>{Xq("base64",$);let J=U?"base64url":"base64";if($.length>0&&Yd.test($))throw Error("invalid base64");return Uint8Array.fromBase64($,{alphabet:J,lastChunkHandling:"strict"})},C5=Object.freeze(u2?{encode($){return L5($),$.toBase64()},decode($){return k2($,!1)}}:HU(PU(6),TU("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"),D9(6),zU(""))),k0=Object.freeze(HU(PU(6),TU("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"),zU(""))),s5$=Object.freeze(u2?{encode($){return L5($),$.toBase64({alphabet:"base64url"})},decode($){return k2($,!0)}}:HU(PU(6),TU("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"),D9(6),zU(""))),t5$=Object.freeze(HU(PU(6),TU("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"),zU(""))),_5=($)=>HU(Xd(58),TU($),zU("")),e5$=Object.freeze(_5("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz")),$w$=Object.freeze(_5("123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ")),Uw$=Object.freeze(_5("rpshnaf39wBUDNEGHJKLM4PQRST7VWXYZ2bcdeCg65jkm8oFqi1tuvAxyz"));var S5=HU(TU("qpzry9x8gf2tvdw0s3jn54khce6mua7l"),zU("")),E2=[996825010,642813549,513874426,1027748829,705979059];function t4($){let U=$>>25,J=($&33554431)<<5;for(let G=0;G<E2.length;G++)if((U>>G&1)===1)J^=E2[G];return J}function C2($,U,J=1){let G=$.length,q=1;for(let I=0;I<G;I++){let Q=$.charCodeAt(I);if(Q<33||Q>126)throw Error(`Invalid prefix (${$})`);q=t4(q)^Q>>5}q=t4(q);for(let I=0;I<G;I++)q=t4(q)^$.charCodeAt(I)&31;for(let I of U)q=t4(q)^I;for(let I=0;I<6;I++)q=t4(q);return q^=J,S5.encode(B5([q%J9[30]],30,5,!1))}function x2($){let U=$==="bech32"?1:734539939,J=PU(5),G=J.decode,q=J.encode,I=L2(G);function Q(W,O,Z=90){if(Xq("bech32.encode prefix",W),Q9(O))O=Array.from(O);E5("bech32.encode",O);let M=W.length;if(M===0)throw TypeError(`Invalid prefix length ${M}`);let w=M+7+O.length;if(Z!==!1&&w>Z)throw TypeError(`Length ${w} exceeds limit ${Z}`);let H=W.toLowerCase(),g=C2(H,O,U);return`${H}1${S5.encode(O)}${g}`}function D(W,O=90){Xq("bech32.decode input",W);let Z=W.length;if(Z<8||O!==!1&&Z>O)throw TypeError(`invalid string length: ${Z} (${W}). Expected (8..${O})`);let M=W.toLowerCase();if(W!==M&&W!==W.toUpperCase())throw Error("String must be lowercase or uppercase");let w=M.lastIndexOf("1");if(w===0||w===-1)throw Error('Letter "1" must be present between prefix and data only');let H=M.slice(0,w),g=M.slice(w+1);if(g.length<6)throw Error("Data must be at least 6 characters long");let P=S5.decode(g).slice(0,-6),C=C2(H,P,U);if(!g.endsWith(C))throw Error(`Invalid checksum in ${W}: expected "${C}"`);return{prefix:H,words:P}}let X=L2(D);function Y(W){let{prefix:O,words:Z}=D(W,!1);return{prefix:O,words:Z,bytes:G(Z)}}function V(W,O){return Q(W,q(O))}return{encode:Q,decode:D,encodeFromBytes:V,decodeToBytes:Y,decodeUnsafe:X,fromWords:G,fromWordsUnsafe:I,toWords:q}}var AU=Object.freeze(x2("bech32")),Jw$=Object.freeze(x2("bech32m"));var Vd=(()=>typeof Uint8Array.from([]).toHex==="function"&&typeof Uint8Array.fromHex==="function")(),Wd={encode($){return L5($),$.toHex()},decode($){return Xq("hex",$),Uint8Array.fromHex($)}},qw$=Object.freeze(Vd?Wd:HU(PU(4),TU("0123456789abcdef"),zU(""),F2(($)=>{if(typeof $!=="string"||$.length%2!==0)throw TypeError(`hex.decode: expected string, got ${typeof $} with length ${$.length}`);return $.toLowerCase()})));function Zd($,U,J,G){HJ($);let q=tX({dkLen:32,asyncTick:10},G),{c:I,dkLen:Q,asyncTick:D}=q;if($0(I,"c"),$0(Q,"dkLen"),$0(D,"asyncTick"),I<1)throw Error("iterations (c) must be >= 1");if(Q<1)throw Error('"dkLen" must be >= 1');if(Q>4294967295*$.outputLen)throw Error("derived key too long");let X=w5(U,"password"),Y=w5(J,"salt"),V=new Uint8Array(Q),W=eU.create($,X),O=W._cloneInto().update(Y);return{c:I,dkLen:Q,asyncTick:D,DK:V,PRF:W,PRFSalt:O}}function Rd($,U,J,G,q){if($.destroy(),U.destroy(),G)G.destroy();return s0(q),J}function v5($,U,J,G){let{c:q,dkLen:I,DK:Q,PRF:D,PRFSalt:X}=Zd($,U,J,G),Y,V=new Uint8Array(4),W=o8(V),O=new Uint8Array(D.outputLen);for(let Z=1,M=0;M<I;Z++,M+=D.outputLen){let w=Q.subarray(M,M+D.outputLen);W.setInt32(0,Z,!1),(Y=X._cloneInto(Y)).update(V).digestInto(O),w.set(O.subarray(0,w.length));for(let H=1;H<q;H++){D._cloneInto(Y).update(O).digestInto(O);for(let g=0;g<w.length;g++)w[g]^=O[g]}}return Rd(D,X,Q,Y,O)}function f2($,U,J,G,q,I){let Q=$[U++]^J[G++],D=$[U++]^J[G++],X=$[U++]^J[G++],Y=$[U++]^J[G++],V=$[U++]^J[G++],W=$[U++]^J[G++],O=$[U++]^J[G++],Z=$[U++]^J[G++],M=$[U++]^J[G++],w=$[U++]^J[G++],H=$[U++]^J[G++],g=$[U++]^J[G++],P=$[U++]^J[G++],C=$[U++]^J[G++],F=$[U++]^J[G++],f=$[U++]^J[G++],E=Q,p=D,b=X,h=Y,s=V,m=W,_=O,v=Z,j=M,L=w,S=H,y=g,u=P,l=C,A=F,o=f;for(let G$=0;G$<8;G$+=2)s^=f$(E+u|0,7),j^=f$(s+E|0,9),u^=f$(j+s|0,13),E^=f$(u+j|0,18),L^=f$(m+p|0,7),l^=f$(L+m|0,9),p^=f$(l+L|0,13),m^=f$(p+l|0,18),A^=f$(S+_|0,7),b^=f$(A+S|0,9),_^=f$(b+A|0,13),S^=f$(_+b|0,18),h^=f$(o+y|0,7),v^=f$(h+o|0,9),y^=f$(v+h|0,13),o^=f$(y+v|0,18),p^=f$(E+h|0,7),b^=f$(p+E|0,9),h^=f$(b+p|0,13),E^=f$(h+b|0,18),_^=f$(m+s|0,7),v^=f$(_+m|0,9),s^=f$(v+_|0,13),m^=f$(s+v|0,18),y^=f$(S+L|0,7),j^=f$(y+S|0,9),L^=f$(j+y|0,13),S^=f$(L+j|0,18),u^=f$(o+A|0,7),l^=f$(u+o|0,9),A^=f$(l+u|0,13),o^=f$(A+l|0,18);q[I++]=Q+E|0,q[I++]=D+p|0,q[I++]=X+b|0,q[I++]=Y+h|0,q[I++]=V+s|0,q[I++]=W+m|0,q[I++]=O+_|0,q[I++]=Z+v|0,q[I++]=M+j|0,q[I++]=w+L|0,q[I++]=H+S|0,q[I++]=g+y|0,q[I++]=P+u|0,q[I++]=C+l|0,q[I++]=F+A|0,q[I++]=f+o|0}function F5($,U,J,G,q){let I=G+0,Q=G+16*q;for(let D=0;D<16;D++)J[Q+D]=$[U+(2*q-1)*16+D];for(let D=0;D<q;D++,I+=16,U+=16){if(f2(J,Q,$,U,J,I),D>0)Q+=16;f2(J,I,$,U+=16,J,Q)}}function Nd($,U,J){let G=tX({dkLen:32,asyncTick:10,maxmem:1073742848},J),{N:q,r:I,p:Q,dkLen:D,asyncTick:X,maxmem:Y,onProgress:V}=G;if($0(q,"N"),$0(I,"r"),$0(Q,"p"),$0(D,"dkLen"),$0(X,"asyncTick"),$0(Y,"maxmem"),V!==void 0&&typeof V!=="function")throw Error("progressCb must be a function");let W=128*I,O=W/4,Z=Math.pow(2,32);if(q<=1||(q&q-1)!==0||q>Z)throw Error('"N" expected a power of 2, and 2^1 <= N <= 2^32');if(Q<1||Q>(Z-1)*32/W)throw Error('"p" expected integer 1..((2^32 - 1) * 32) / (128 * r)');if(D<1||D>(Z-1)*32)throw Error('"dkLen" expected integer 1..(2^32 - 1) * 32');let M=W*(q+Q+1);if(M>Y)throw Error('"maxmem" limit was hit: memUsed(128*r*(N+p+1))='+M+", maxmem="+Y);let w=v5(U0,$,U,{c:1,dkLen:W*Q}),H=aX(w),g=aX(new Uint8Array(W*q)),P=aX(new Uint8Array(W)),C=()=>{};if(V){let F=2*q*Q,f=Math.max(Math.floor(F/1e4),1),E=0;C=()=>{if(E++,V&&(!(E%f)||E===F))V(E/F)}}return{N:q,r:I,p:Q,dkLen:D,blockSize32:O,V:g,B32:H,B:w,tmp:P,blockMixCb:C,asyncTick:X}}function wd($,U,J,G,q){let I=v5(U0,$,J,{c:1,dkLen:U});return s0(J,G,q),I}function b5($,U,J){let{N:G,r:q,p:I,dkLen:Q,blockSize32:D,V:X,B32:Y,B:V,tmp:W,blockMixCb:O}=Nd($,U,J);N5(Y);for(let Z=0;Z<I;Z++){let M=D*Z;for(let w=0;w<D;w++)X[w]=Y[M+w];for(let w=0,H=0;w<G-1;w++)F5(X,H,X,H+=D,q),O();F5(X,(G-1)*D,Y,M,q),O();for(let w=0;w<G;w++){let H=(Y[M+D-16]&G-1)>>>0;for(let g=0;g<D;g++)W[g]=Y[M+g]^X[H*D+g];F5(W,0,Y,M,q),O()}}return N5(Y),wd($,Q,V,X,W)}/*! noble-ciphers - MIT License (c) 2023 Paul Miller (paulmillr.com) */function Md($){return $ instanceof Uint8Array||ArrayBuffer.isView($)&&$.constructor.name==="Uint8Array"&&"BYTES_PER_ELEMENT"in $&&$.BYTES_PER_ELEMENT===1}function X9($){if(typeof $!=="boolean")throw TypeError(`boolean expected, not ${$}`)}function a8($){if(typeof $!=="number")throw TypeError("number expected, got "+typeof $);if(!Number.isSafeInteger($)||$<0)throw RangeError("positive integer expected, got "+$)}function Y0($,U,J=""){let G=Md($),q=$?.length,I=U!==void 0;if(!G||I&&q!==U){let Q=J&&`"${J}" `,D=I?` of length ${U}`:"",X=G?`length=${q}`:`type=${typeof $}`,Y=Q+"expected Uint8Array"+D+", got "+X;if(!G)throw TypeError(Y);throw RangeError(Y)}return $}function u5($,U=!0){if($.destroyed)throw Error("Hash instance has been destroyed");if(U&&$.finished)throw Error("Hash#digest() has already been called")}function y2($,U,J=!1){Y0($,void 0,"output");let G=U.outputLen;if($.length<G)throw RangeError("digestInto() expects output buffer of length at least "+G);if(J&&!s8($))throw Error("invalid output, must be aligned")}function UJ($){return new Uint32Array($.buffer,$.byteOffset,Math.floor($.byteLength/4))}function fU(...$){for(let U=0;U<$.length;U++)$[U].fill(0)}function Hd($){return new DataView($.buffer,$.byteOffset,$.byteLength)}var VG=(()=>new Uint8Array(new Uint32Array([287454020]).buffer)[0]===68)(),Td=($)=>$<<24&4278190080|$<<8&16711680|$>>>8&65280|$>>>24&255;var zd=($)=>{for(let U=0;U<$.length;U++)$[U]=Td($[U]);return $},KJ=VG?($)=>$:zd;function m2($,U){if(U==null||typeof U!=="object")throw Error("options must be defined");return Object.assign($,U)}function h2($,U){if($.length!==U.length)return!1;let J=0;for(let G=0;G<$.length;G++)J|=$[G]^U[G];return J===0}function r2($,U,J){let G=U,q=J||(()=>[]),I=(D,X)=>G(X,...q(D)).update(D).digest(),Q=G(new Uint8Array($),...q(new Uint8Array(0)));return I.outputLen=Q.outputLen,I.blockLen=Q.blockLen,I.create=(D,...X)=>G(D,...X),I}var l2=($,U)=>{function J(G,...q){if(Y0(G,void 0,"key"),$.nonceLength!==void 0){let V=q[0];Y0(V,$.varSizeNonce?void 0:$.nonceLength,"nonce")}let I=$.tagLength;if(I&&q[1]!==void 0)Y0(q[1],void 0,"AAD");let Q=U(G,...q),D=(V,W)=>{if(W!==void 0){if(V!==2)throw Error("cipher output not supported");Y0(W,void 0,"output")}},X=!1;return{encrypt(V,W){if(X)throw Error("cannot encrypt() twice with same key + nonce");return X=!0,Y0(V),D(Q.encrypt.length,W),Q.encrypt(V,W)},decrypt(V,W){if(Y0(V),I&&V.length<I)throw Error('"ciphertext" expected length bigger than tagLength='+I);return D(Q.decrypt.length,W),Q.decrypt(V,W)}}}return Object.assign(J,$),J};function $I($,U,J=!0){if(U===void 0)return new Uint8Array($);if(Y0(U,void 0,"output"),U.length!==$)throw Error('"output" expected Uint8Array of length '+$+", got: "+U.length);if(J&&!s8(U))throw Error("invalid output, must be aligned");return U}function i2($,U,J){a8($),a8(U),X9(J);let G=new Uint8Array(16),q=Hd(G);return q.setBigUint64(0,BigInt(U),J),q.setBigUint64(8,BigInt($),J),G}function s8($){return $.byteOffset%4===0}function t8($){return Uint8Array.from(Y0($))}var d2=($)=>Uint8Array.from($.split(""),(U)=>U.charCodeAt(0)),Ad=(()=>KJ(UJ(d2("expand 16-byte k"))))(),Kd=(()=>KJ(UJ(d2("expand 32-byte k"))))();function y$($,U){return $<<U|$>>>32-U}var UI=64,gd=16,k5=(()=>4294967295)(),p2=Uint32Array.of();function jd($,U,J,G,q,I,Q,D){let X=q.length,Y=new Uint8Array(UI),V=UJ(Y),W=VG&&s8(q)&&s8(I),O=W?UJ(q):p2,Z=W?UJ(I):p2;if(!VG){for(let M=0;M<X;Q++){if($(U,J,G,V,Q,D),KJ(V),Q>=k5)throw Error("arx: counter overflow");let w=Math.min(UI,X-M);for(let H=0,g;H<w;H++)g=M+H,I[g]=q[g]^Y[H];M+=w}return}for(let M=0;M<X;Q++){if($(U,J,G,V,Q,D),Q>=k5)throw Error("arx: counter overflow");let w=Math.min(UI,X-M);if(W&&w===UI){let H=M/4;if(M%4!==0)throw Error("arx: invalid block position");for(let g=0,P;g<gd;g++)P=H+g,Z[P]=O[P]^V[g];M+=UI;continue}for(let H=0,g;H<w;H++)g=M+H,I[g]=q[g]^Y[H];M+=w}}function n2($,U){let{allowShortKeys:J,extendNonceFn:G,counterLength:q,counterRight:I,rounds:Q}=m2({allowShortKeys:!1,counterLength:8,counterRight:!1,rounds:20},U);if(typeof $!=="function")throw Error("core must be a function");return a8(q),a8(Q),X9(I),X9(J),(D,X,Y,V,W=0)=>{Y0(D,void 0,"key"),Y0(X,void 0,"nonce"),Y0(Y,void 0,"data");let O=Y.length;if(V=$I(O,V,!1),a8(W),W<0||W>=k5)throw Error("arx: counter overflow");let Z=[],M=D.length,w,H;if(M===32)Z.push(w=t8(D)),H=Kd;else if(M===16&&J)w=new Uint8Array(32),w.set(D),w.set(D,16),H=Ad,Z.push(w);else throw Y0(D,32,"arx key"),Error("invalid key size");if(!VG||!s8(X))Z.push(X=t8(X));let g=UJ(w);if(G){if(X.length!==24)throw Error("arx: extended nonce must be 24 bytes");let F=X.subarray(0,16);if(VG)G(H,g,UJ(F),g);else{let f=KJ(Uint32Array.from(H));G(f,g,UJ(F),g),fU(f),KJ(g)}X=X.subarray(16)}else if(!VG)KJ(g);let P=16-q;if(P!==X.length)throw Error(`arx: nonce must be ${P} or 16 bytes`);if(P!==12){let F=new Uint8Array(12);F.set(X,I?0:12-X.length),X=F,Z.push(X)}let C=KJ(UJ(X));try{return jd($,H,g,C,Y,V,W,Q),V}finally{fU(...Z)}}}function g0($,U){return $[U++]&255|($[U++]&255)<<8}class c2{blockLen=16;outputLen=16;buffer=new Uint8Array(16);r=new Uint16Array(10);h=new Uint16Array(10);pad=new Uint16Array(8);pos=0;finished=!1;destroyed=!1;constructor($){$=t8(Y0($,32,"key"));let U=g0($,0),J=g0($,2),G=g0($,4),q=g0($,6),I=g0($,8),Q=g0($,10),D=g0($,12),X=g0($,14);this.r[0]=U&8191,this.r[1]=(U>>>13|J<<3)&8191,this.r[2]=(J>>>10|G<<6)&7939,this.r[3]=(G>>>7|q<<9)&8191,this.r[4]=(q>>>4|I<<12)&255,this.r[5]=I>>>1&8190,this.r[6]=(I>>>14|Q<<2)&8191,this.r[7]=(Q>>>11|D<<5)&8065,this.r[8]=(D>>>8|X<<8)&8191,this.r[9]=X>>>5&127;for(let Y=0;Y<8;Y++)this.pad[Y]=g0($,16+2*Y)}process($,U,J=!1){let G=J?0:2048,{h:q,r:I}=this,Q=I[0],D=I[1],X=I[2],Y=I[3],V=I[4],W=I[5],O=I[6],Z=I[7],M=I[8],w=I[9],H=g0($,U+0),g=g0($,U+2),P=g0($,U+4),C=g0($,U+6),F=g0($,U+8),f=g0($,U+10),E=g0($,U+12),p=g0($,U+14),b=q[0]+(H&8191),h=q[1]+((H>>>13|g<<3)&8191),s=q[2]+((g>>>10|P<<6)&8191),m=q[3]+((P>>>7|C<<9)&8191),_=q[4]+((C>>>4|F<<12)&8191),v=q[5]+(F>>>1&8191),j=q[6]+((F>>>14|f<<2)&8191),L=q[7]+((f>>>11|E<<5)&8191),S=q[8]+((E>>>8|p<<8)&8191),y=q[9]+(p>>>5|G),u=0,l=u+b*Q+h*(5*w)+s*(5*M)+m*(5*Z)+_*(5*O);u=l>>>13,l&=8191,l+=v*(5*W)+j*(5*V)+L*(5*Y)+S*(5*X)+y*(5*D),u+=l>>>13,l&=8191;let A=u+b*D+h*Q+s*(5*w)+m*(5*M)+_*(5*Z);u=A>>>13,A&=8191,A+=v*(5*O)+j*(5*W)+L*(5*V)+S*(5*Y)+y*(5*X),u+=A>>>13,A&=8191;let o=u+b*X+h*D+s*Q+m*(5*w)+_*(5*M);u=o>>>13,o&=8191,o+=v*(5*Z)+j*(5*O)+L*(5*W)+S*(5*V)+y*(5*Y),u+=o>>>13,o&=8191;let G$=u+b*Y+h*X+s*D+m*Q+_*(5*w);u=G$>>>13,G$&=8191,G$+=v*(5*M)+j*(5*Z)+L*(5*O)+S*(5*W)+y*(5*V),u+=G$>>>13,G$&=8191;let B=u+b*V+h*Y+s*X+m*D+_*Q;u=B>>>13,B&=8191,B+=v*(5*w)+j*(5*M)+L*(5*Z)+S*(5*O)+y*(5*W),u+=B>>>13,B&=8191;let R$=u+b*W+h*V+s*Y+m*X+_*D;u=R$>>>13,R$&=8191,R$+=v*Q+j*(5*w)+L*(5*M)+S*(5*Z)+y*(5*O),u+=R$>>>13,R$&=8191;let H$=u+b*O+h*W+s*V+m*Y+_*X;u=H$>>>13,H$&=8191,H$+=v*D+j*Q+L*(5*w)+S*(5*M)+y*(5*Z),u+=H$>>>13,H$&=8191;let K$=u+b*Z+h*O+s*W+m*V+_*Y;u=K$>>>13,K$&=8191,K$+=v*X+j*D+L*Q+S*(5*w)+y*(5*M),u+=K$>>>13,K$&=8191;let A$=u+b*M+h*Z+s*O+m*W+_*V;u=A$>>>13,A$&=8191,A$+=v*Y+j*X+L*D+S*Q+y*(5*w),u+=A$>>>13,A$&=8191;let w$=u+b*w+h*M+s*Z+m*O+_*W;u=w$>>>13,w$&=8191,w$+=v*V+j*Y+L*X+S*D+y*Q,u+=w$>>>13,w$&=8191,u=(u<<2)+u|0,u=u+l|0,l=u&8191,u=u>>>13,A+=u,q[0]=l,q[1]=A,q[2]=o,q[3]=G$,q[4]=B,q[5]=R$,q[6]=H$,q[7]=K$,q[8]=A$,q[9]=w$}finalize(){let{h:$,pad:U}=this,J=new Uint16Array(10),G=$[1]>>>13;$[1]&=8191;for(let Q=2;Q<10;Q++)$[Q]+=G,G=$[Q]>>>13,$[Q]&=8191;$[0]+=G*5,G=$[0]>>>13,$[0]&=8191,$[1]+=G,G=$[1]>>>13,$[1]&=8191,$[2]+=G,J[0]=$[0]+5,G=J[0]>>>13,J[0]&=8191;for(let Q=1;Q<10;Q++)J[Q]=$[Q]+G,G=J[Q]>>>13,J[Q]&=8191;J[9]-=8192;let q=(G^1)-1;for(let Q=0;Q<10;Q++)J[Q]&=q;q=~q;for(let Q=0;Q<10;Q++)$[Q]=$[Q]&q|J[Q];$[0]=($[0]|$[1]<<13)&65535,$[1]=($[1]>>>3|$[2]<<10)&65535,$[2]=($[2]>>>6|$[3]<<7)&65535,$[3]=($[3]>>>9|$[4]<<4)&65535,$[4]=($[4]>>>12|$[5]<<1|$[6]<<14)&65535,$[5]=($[6]>>>2|$[7]<<11)&65535,$[6]=($[7]>>>5|$[8]<<8)&65535,$[7]=($[8]>>>8|$[9]<<5)&65535;let I=$[0]+U[0];$[0]=I&65535;for(let Q=1;Q<8;Q++)I=($[Q]+U[Q]|0)+(I>>>16)|0,$[Q]=I&65535;fU(J)}update($){u5(this),Y0($),$=t8($);let{buffer:U,blockLen:J}=this,G=$.length;for(let q=0;q<G;){let I=Math.min(J-this.pos,G-q);if(I===J){for(;J<=G-q;q+=J)this.process($,q);continue}if(U.set($.subarray(q,q+I),this.pos),this.pos+=I,q+=I,this.pos===J)this.process(U,0,!1),this.pos=0}return this}destroy(){this.destroyed=!0,fU(this.h,this.r,this.buffer,this.pad)}digestInto($){u5(this),y2($,this),this.finished=!0;let{buffer:U,h:J}=this,{pos:G}=this;if(G){U[G++]=1;for(;G<16;G++)U[G]=0;this.process(U,0,!0)}this.finalize();let q=0;for(let I=0;I<8;I++)$[q++]=J[I]>>>0,$[q++]=J[I]>>>8}digest(){let{buffer:$,outputLen:U}=this;this.digestInto($);let J=$.slice(0,U);return this.destroy(),J}}var o2=r2(32,($)=>new c2($));function Pd($,U,J,G,q,I=20){let Q=$[0],D=$[1],X=$[2],Y=$[3],V=U[0],W=U[1],O=U[2],Z=U[3],M=U[4],w=U[5],H=U[6],g=U[7],P=q,C=J[0],F=J[1],f=J[2],E=Q,p=D,b=X,h=Y,s=V,m=W,_=O,v=Z,j=M,L=w,S=H,y=g,u=P,l=C,A=F,o=f;for(let B=0;B<I;B+=2)E=E+s|0,u=y$(u^E,16),j=j+u|0,s=y$(s^j,12),E=E+s|0,u=y$(u^E,8),j=j+u|0,s=y$(s^j,7),p=p+m|0,l=y$(l^p,16),L=L+l|0,m=y$(m^L,12),p=p+m|0,l=y$(l^p,8),L=L+l|0,m=y$(m^L,7),b=b+_|0,A=y$(A^b,16),S=S+A|0,_=y$(_^S,12),b=b+_|0,A=y$(A^b,8),S=S+A|0,_=y$(_^S,7),h=h+v|0,o=y$(o^h,16),y=y+o|0,v=y$(v^y,12),h=h+v|0,o=y$(o^h,8),y=y+o|0,v=y$(v^y,7),E=E+m|0,o=y$(o^E,16),S=S+o|0,m=y$(m^S,12),E=E+m|0,o=y$(o^E,8),S=S+o|0,m=y$(m^S,7),p=p+_|0,u=y$(u^p,16),y=y+u|0,_=y$(_^y,12),p=p+_|0,u=y$(u^p,8),y=y+u|0,_=y$(_^y,7),b=b+v|0,l=y$(l^b,16),j=j+l|0,v=y$(v^j,12),b=b+v|0,l=y$(l^b,8),j=j+l|0,v=y$(v^j,7),h=h+s|0,A=y$(A^h,16),L=L+A|0,s=y$(s^L,12),h=h+s|0,A=y$(A^h,8),L=L+A|0,s=y$(s^L,7);let G$=0;G[G$++]=Q+E|0,G[G$++]=D+p|0,G[G$++]=X+b|0,G[G$++]=Y+h|0,G[G$++]=V+s|0,G[G$++]=W+m|0,G[G$++]=O+_|0,G[G$++]=Z+v|0,G[G$++]=M+j|0,G[G$++]=w+L|0,G[G$++]=H+S|0,G[G$++]=g+y|0,G[G$++]=P+u|0,G[G$++]=C+l|0,G[G$++]=F+A|0,G[G$++]=f+o|0}var Bd=n2(Pd,{counterRight:!1,counterLength:4,allowShortKeys:!1});var Sd=new Uint8Array(16),a2=($,U)=>{$.update(U);let J=U.length%16;if(J)$.update(Sd.subarray(J))},Ld=new Uint8Array(32);function s2($,U,J,G,q){if(q!==void 0)Y0(q,void 0,"AAD");let I=$(U,J,Ld),Q=i2(G.length,q?q.length:0,!0),D=o2.create(I);if(q)a2(D,q);a2(D,G),D.update(Q);let X=D.digest();return fU(I,Q),X}var Ed=($)=>(U,J,G)=>{return{encrypt(I,Q){let D=I.length;Q=$I(D+16,Q,!1),Q.set(I);let X=Q.subarray(0,-16);$(U,J,X,X,1);let Y=s2($,U,J,X,G);return Q.set(Y,D),fU(Y),Q},decrypt(I,Q){Q=$I(I.length-16,Q,!1);let D=I.subarray(0,-16),X=I.subarray(-16),Y=s2($,U,J,D,G);if(!h2(X,Y))throw fU(Y),Error("invalid tag");return Q.set(I.subarray(0,-16)),$(U,J,Q,Q,1),fU(Y),Q}}},BU=l2({blockSize:64,nonceLength:12,tagLength:16},Ed(Bd));/*! noble-hashes - MIT License (c) 2022 Paul Miller (paulmillr.com) */function e8($){return $ instanceof Uint8Array||ArrayBuffer.isView($)&&$.constructor.name==="Uint8Array"}function R0($,U=""){if(!Number.isSafeInteger($)||$<0){let J=U&&`"${U}" `;throw Error(`${J}expected integer >= 0, got ${$}`)}}function B$($,U,J=""){let G=e8($),q=$?.length,I=U!==void 0;if(!G||I&&q!==U){let Q=J&&`"${J}" `,D=I?` of length ${U}`:"",X=G?`length=${q}`:`type=${typeof $}`;throw Error(Q+"expected Uint8Array"+D+", got "+X)}return $}function SU($){if(typeof $!=="function"||typeof $.create!=="function")throw Error("Hash must wrapped by utils.createHasher");R0($.outputLen),R0($.blockLen)}function jJ($,U=!0){if($.destroyed)throw Error("Hash instance has been destroyed");if(U&&$.finished)throw Error("Hash#digest() has already been called")}function Y9($,U){B$($,void 0,"digestInto() output");let J=U.outputLen;if($.length<J)throw Error('"digestInto() output" expected to be of length >='+J)}function V9($){return new Uint32Array($.buffer,$.byteOffset,Math.floor($.byteLength/4))}function QU(...$){for(let U=0;U<$.length;U++)$[U].fill(0)}function W9($){return new DataView($.buffer,$.byteOffset,$.byteLength)}function yU($,U){return $<<32-U|$>>>U}var Cd=(()=>new Uint8Array(new Uint32Array([287454020]).buffer)[0]===68)();function _d($){return $<<24&4278190080|$<<8&16711680|$>>>8&65280|$>>>24&255}function vd($){for(let U=0;U<$.length;U++)$[U]=_d($[U]);return $}var x5=Cd?($)=>$:vd,e2=(()=>typeof Uint8Array.from([]).toHex==="function"&&typeof Uint8Array.fromHex==="function")(),Fd=Array.from({length:256},($,U)=>U.toString(16).padStart(2,"0"));function WG($){if(B$($),e2)return $.toHex();let U="";for(let J=0;J<$.length;J++)U+=Fd[$[J]];return U}var gJ={_0:48,_9:57,A:65,F:70,a:97,f:102};function t2($){if($>=gJ._0&&$<=gJ._9)return $-gJ._0;if($>=gJ.A&&$<=gJ.F)return $-(gJ.A-10);if($>=gJ.a&&$<=gJ.f)return $-(gJ.a-10);return}function OG($){if(typeof $!=="string")throw Error("hex string expected, got "+typeof $);if(e2)return Uint8Array.fromHex($);let U=$.length,J=U/2;if(U%2)throw Error("hex string expected, got unpadded hex of length "+U);let G=new Uint8Array(J);for(let q=0,I=0;q<J;q++,I+=2){let Q=t2($.charCodeAt(I)),D=t2($.charCodeAt(I+1));if(Q===void 0||D===void 0){let X=$[I]+$[I+1];throw Error('hex string expected, got non-hex character "'+X+'" at index '+I)}G[q]=Q*16+D}return G}function Q0(...$){let U=0;for(let G=0;G<$.length;G++){let q=$[G];B$(q),U+=q.length}let J=new Uint8Array(U);for(let G=0,q=0;G<$.length;G++){let I=$[G];J.set(I,q),q+=I.length}return J}function $6($,U={}){let J=(q,I)=>$(I).update(q).digest(),G=$(void 0);return J.outputLen=G.outputLen,J.blockLen=G.blockLen,J.create=(q)=>$(q),Object.assign(J,U),Object.freeze(J)}function Yq($=32){let U=typeof globalThis==="object"?globalThis.crypto:null;if(typeof U?.getRandomValues!=="function")throw Error("crypto.getRandomValues must be defined");return U.getRandomValues(new Uint8Array($))}var Vq=($)=>({oid:Uint8Array.from([6,9,96,134,72,1,101,3,4,2,$])});/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */var y5=BigInt(0),f5=BigInt(1);function JI($,U=""){if(typeof $!=="boolean"){let J=U&&`"${U}" `;throw Error(J+"expected boolean, got type="+typeof $)}return $}function $L($){if(typeof $==="bigint"){if(!O9($))throw Error("positive bigint expected, got "+$)}else R0($);return $}function qI($){let U=$L($).toString(16);return U.length&1?"0"+U:U}function UL($){if(typeof $!=="string")throw Error("hex string expected, got "+typeof $);return $===""?y5:BigInt("0x"+$)}function Wq($){return UL(WG($))}function Oq($){return UL(WG(Z9(B$($)).reverse()))}function U6($,U){R0(U),$=$L($);let J=OG($.toString(16).padStart(U*2,"0"));if(J.length!==U)throw Error("number too large");return J}function GI($,U){return U6($,U).reverse()}function Z9($){return Uint8Array.from($)}function Zq($){return Uint8Array.from($,(U,J)=>{let G=U.charCodeAt(0);if(U.length!==1||G>127)throw Error(`string contains non-ASCII character "${$[J]}" with code ${G} at position ${J}`);return G})}var O9=($)=>typeof $==="bigint"&&y5<=$;function bd($,U,J){return O9($)&&O9(U)&&O9(J)&&U<=$&&$<J}function II($,U,J,G){if(!bd(U,J,G))throw Error("expected valid "+$+": "+J+" <= n < "+G+", got "+U)}function m5($){let U;for(U=0;$>y5;$>>=f5,U+=1);return U}var QI=($)=>(f5<<BigInt($))-f5;function JL($,U,J){if(R0($,"hashLen"),R0(U,"qByteLen"),typeof J!=="function")throw Error("hmacFn must be a function");let G=(H)=>new Uint8Array(H),q=Uint8Array.of(),I=Uint8Array.of(0),Q=Uint8Array.of(1),D=1000,X=G($),Y=G($),V=0,W=()=>{X.fill(1),Y.fill(0),V=0},O=(...H)=>J(Y,Q0(X,...H)),Z=(H=q)=>{if(Y=O(I,H),X=O(),H.length===0)return;Y=O(Q,H),X=O()},M=()=>{if(V++>=D)throw Error("drbg: tried max amount of iterations");let H=0,g=[];while(H<U){X=O();let P=X.slice();g.push(P),H+=X.length}return Q0(...g)};return(H,g)=>{W(),Z(H);let P=void 0;while(!(P=g(M())))Z();return W(),P}}function ZG($,U={},J={}){if(!$||typeof $!=="object")throw Error("expected valid options object");function G(I,Q,D){let X=$[I];if(D&&X===void 0)return;let Y=typeof X;if(Y!==Q||X===null)throw Error(`param "${I}" is invalid: expected ${Q}, got ${Y}`)}let q=(I,Q)=>Object.entries(I).forEach(([D,X])=>G(D,X,Q));q(U,!1),q(J,!0)}function h5($){let U=new WeakMap;return(J,...G)=>{let q=U.get(J);if(q!==void 0)return q;let I=$(J,...G);return U.set(J,I),I}}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */var e0=BigInt(0),x0=BigInt(1),RG=BigInt(2),IL=BigInt(3),QL=BigInt(4),DL=BigInt(5),ud=BigInt(7),XL=BigInt(8),kd=BigInt(9),YL=BigInt(16);function t0($,U){let J=$%U;return J>=e0?J:U+J}function LU($,U,J){let G=$;while(U-- >e0)G*=G,G%=J;return G}function qL($,U){if($===e0)throw Error("invert: expected non-zero number");if(U<=e0)throw Error("invert: expected positive modulus, got "+U);let J=t0($,U),G=U,q=e0,I=x0,Q=x0,D=e0;while(J!==e0){let Y=G/J,V=G%J,W=q-Q*Y,O=I-D*Y;G=J,J=V,q=Q,I=D,Q=W,D=O}if(G!==x0)throw Error("invert: does not exist");return t0(q,U)}function r5($,U,J){if(!$.eql($.sqr(U),J))throw Error("Cannot find square root")}function VL($,U){let J=($.ORDER+x0)/QL,G=$.pow(U,J);return r5($,G,U),G}function xd($,U){let J=($.ORDER-DL)/XL,G=$.mul(U,RG),q=$.pow(G,J),I=$.mul(U,q),Q=$.mul($.mul(I,RG),q),D=$.mul(I,$.sub(Q,$.ONE));return r5($,D,U),D}function fd($){let U=R9($),J=WL($),G=J(U,U.neg(U.ONE)),q=J(U,G),I=J(U,U.neg(G)),Q=($+ud)/YL;return(D,X)=>{let Y=D.pow(X,Q),V=D.mul(Y,G),W=D.mul(Y,q),O=D.mul(Y,I),Z=D.eql(D.sqr(V),X),M=D.eql(D.sqr(W),X);Y=D.cmov(Y,V,Z),V=D.cmov(O,W,M);let w=D.eql(D.sqr(V),X),H=D.cmov(Y,V,w);return r5(D,H,X),H}}function WL($){if($<IL)throw Error("sqrt is not defined for small field");let U=$-x0,J=0;while(U%RG===e0)U/=RG,J++;let G=RG,q=R9($);while(GL(q,G)===1)if(G++>1000)throw Error("Cannot find square root: probably non-prime P");if(J===1)return VL;let I=q.pow(G,U),Q=(U+x0)/RG;return function(X,Y){if(X.is0(Y))return Y;if(GL(X,Y)!==1)throw Error("Cannot find square root");let V=J,W=X.mul(X.ONE,I),O=X.pow(Y,U),Z=X.pow(Y,Q);while(!X.eql(O,X.ONE)){if(X.is0(O))return X.ZERO;let M=1,w=X.sqr(O);while(!X.eql(w,X.ONE))if(M++,w=X.sqr(w),M===V)throw Error("Cannot find square root");let H=x0<<BigInt(V-M-1),g=X.pow(W,H);V=M,W=X.sqr(g),O=X.mul(O,W),Z=X.mul(Z,g)}return Z}}function yd($){if($%QL===IL)return VL;if($%XL===DL)return xd;if($%YL===kd)return fd($);return WL($)}var md=["create","isValid","is0","neg","inv","sqrt","sqr","eql","add","sub","mul","pow","div","addN","subN","mulN","sqrN"];function l5($){let U={ORDER:"bigint",BYTES:"number",BITS:"number"},J=md.reduce((G,q)=>{return G[q]="function",G},U);return ZG($,J),$}function hd($,U,J){if(J<e0)throw Error("invalid exponent, negatives unsupported");if(J===e0)return $.ONE;if(J===x0)return U;let G=$.ONE,q=U;while(J>e0){if(J&x0)G=$.mul(G,q);q=$.sqr(q),J>>=x0}return G}function DI($,U,J=!1){let G=Array(U.length).fill(J?$.ZERO:void 0),q=U.reduce((Q,D,X)=>{if($.is0(D))return Q;return G[X]=Q,$.mul(Q,D)},$.ONE),I=$.inv(q);return U.reduceRight((Q,D,X)=>{if($.is0(D))return Q;return G[X]=$.mul(Q,G[X]),$.mul(Q,D)},I),G}function GL($,U){let J=($.ORDER-x0)/RG,G=$.pow(U,J),q=$.eql(G,$.ONE),I=$.eql(G,$.ZERO),Q=$.eql(G,$.neg($.ONE));if(!q&&!I&&!Q)throw Error("invalid Legendre symbol result");return q?1:I?0:-1}function rd($,U){if(U!==void 0)R0(U);let J=U!==void 0?U:$.toString(2).length,G=Math.ceil(J/8);return{nBitLength:J,nByteLength:G}}class OL{ORDER;BITS;BYTES;isLE;ZERO=e0;ONE=x0;_lengths;_sqrt;_mod;constructor($,U={}){if($<=e0)throw Error("invalid field: expected ORDER > 0, got "+$);let J=void 0;if(this.isLE=!1,U!=null&&typeof U==="object"){if(typeof U.BITS==="number")J=U.BITS;if(typeof U.sqrt==="function")this.sqrt=U.sqrt;if(typeof U.isLE==="boolean")this.isLE=U.isLE;if(U.allowedLengths)this._lengths=U.allowedLengths?.slice();if(typeof U.modFromBytes==="boolean")this._mod=U.modFromBytes}let{nBitLength:G,nByteLength:q}=rd($,J);if(q>2048)throw Error("invalid field: expected ORDER of <= 2048 bytes");this.ORDER=$,this.BITS=G,this.BYTES=q,this._sqrt=void 0,Object.preventExtensions(this)}create($){return t0($,this.ORDER)}isValid($){if(typeof $!=="bigint")throw Error("invalid field element: expected bigint, got "+typeof $);return e0<=$&&$<this.ORDER}is0($){return $===e0}isValidNot0($){return!this.is0($)&&this.isValid($)}isOdd($){return($&x0)===x0}neg($){return t0(-$,this.ORDER)}eql($,U){return $===U}sqr($){return t0($*$,this.ORDER)}add($,U){return t0($+U,this.ORDER)}sub($,U){return t0($-U,this.ORDER)}mul($,U){return t0($*U,this.ORDER)}pow($,U){return hd(this,$,U)}div($,U){return t0($*qL(U,this.ORDER),this.ORDER)}sqrN($){return $*$}addN($,U){return $+U}subN($,U){return $-U}mulN($,U){return $*U}inv($){return qL($,this.ORDER)}sqrt($){if(!this._sqrt)this._sqrt=yd(this.ORDER);return this._sqrt(this,$)}toBytes($){return this.isLE?GI($,this.BYTES):U6($,this.BYTES)}fromBytes($,U=!1){B$($);let{_lengths:J,BYTES:G,isLE:q,ORDER:I,_mod:Q}=this;if(J){if(!J.includes($.length)||$.length>G)throw Error("Field.fromBytes: expected "+J+" bytes, got "+$.length);let X=new Uint8Array(G);X.set($,q?0:X.length-$.length),$=X}if($.length!==G)throw Error("Field.fromBytes: expected "+G+" bytes, got "+$.length);let D=q?Oq($):Wq($);if(Q)D=t0(D,I);if(!U){if(!this.isValid(D))throw Error("invalid field element: outside of range 0..ORDER")}return D}invertBatch($){return DI(this,$)}cmov($,U,J){return J?U:$}}function R9($,U={}){return new OL($,U)}function ZL($){if(typeof $!=="bigint")throw Error("field order must be bigint");let U=$.toString(2).length;return Math.ceil(U/8)}function i5($){let U=ZL($);return U+Math.ceil(U/2)}function RL($,U,J=!1){B$($);let G=$.length,q=ZL(U),I=i5(U);if(G<16||G<I||G>1024)throw Error("expected "+I+"-1024 bytes of input, got "+G);let Q=J?Oq($):Wq($),D=t0(Q,U-x0)+x0;return J?GI(D,q):U6(D,q)}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */var J6=BigInt(0),NG=BigInt(1);function XI($,U){let J=U.negate();return $?J:U}function c5($,U){let J=DI($.Fp,U.map((G)=>G.Z));return U.map((G,q)=>$.fromAffine(G.toAffine(J[q])))}function HL($,U){if(!Number.isSafeInteger($)||$<=0||$>U)throw Error("invalid window size, expected [1.."+U+"], got W="+$)}function p5($,U){HL($,U);let J=Math.ceil(U/$)+1,G=2**($-1),q=2**$,I=QI($),Q=BigInt($);return{windows:J,windowSize:G,mask:I,maxNumber:q,shiftBy:Q}}function NL($,U,J){let{windowSize:G,mask:q,maxNumber:I,shiftBy:Q}=J,D=Number($&q),X=$>>Q;if(D>G)D-=I,X+=NG;let Y=U*G,V=Y+Math.abs(D)-1,W=D===0,O=D<0,Z=U%2!==0;return{nextN:X,offset:V,isZero:W,isNeg:O,isNegF:Z,offsetF:Y}}var d5=new WeakMap,TL=new WeakMap;function n5($){return TL.get($)||1}function wL($){if($!==J6)throw Error("invalid wNAF")}class o5{BASE;ZERO;Fn;bits;constructor($,U){this.BASE=$.BASE,this.ZERO=$.ZERO,this.Fn=$.Fn,this.bits=U}_unsafeLadder($,U,J=this.ZERO){let G=$;while(U>J6){if(U&NG)J=J.add(G);G=G.double(),U>>=NG}return J}precomputeWindow($,U){let{windows:J,windowSize:G}=p5(U,this.bits),q=[],I=$,Q=I;for(let D=0;D<J;D++){Q=I,q.push(Q);for(let X=1;X<G;X++)Q=Q.add(I),q.push(Q);I=Q.double()}return q}wNAF($,U,J){if(!this.Fn.isValid(J))throw Error("invalid scalar");let G=this.ZERO,q=this.BASE,I=p5($,this.bits);for(let Q=0;Q<I.windows;Q++){let{nextN:D,offset:X,isZero:Y,isNeg:V,isNegF:W,offsetF:O}=NL(J,Q,I);if(J=D,Y)q=q.add(XI(W,U[O]));else G=G.add(XI(V,U[X]))}return wL(J),{p:G,f:q}}wNAFUnsafe($,U,J,G=this.ZERO){let q=p5($,this.bits);for(let I=0;I<q.windows;I++){if(J===J6)break;let{nextN:Q,offset:D,isZero:X,isNeg:Y}=NL(J,I,q);if(J=Q,X)continue;else{let V=U[D];G=G.add(Y?V.negate():V)}}return wL(J),G}getPrecomputes($,U,J){let G=d5.get(U);if(!G){if(G=this.precomputeWindow(U,$),$!==1){if(typeof J==="function")G=J(G);d5.set(U,G)}}return G}cached($,U,J){let G=n5($);return this.wNAF(G,this.getPrecomputes(G,$,J),U)}unsafe($,U,J,G){let q=n5($);if(q===1)return this._unsafeLadder($,U,G);return this.wNAFUnsafe(q,this.getPrecomputes(q,$,J),U,G)}createCache($,U){HL(U,this.bits),TL.set($,U),d5.delete($)}hasCache($){return n5($)!==1}}function zL($,U,J,G){let q=U,I=$.ZERO,Q=$.ZERO;while(J>J6||G>J6){if(J&NG)I=I.add(q);if(G&NG)Q=Q.add(q);q=q.double(),J>>=NG,G>>=NG}return{p1:I,p2:Q}}function ML($,U,J){if(U){if(U.ORDER!==$)throw Error("Field.ORDER must match order: Fp == p, Fn == n");return l5(U),U}else return R9($,{isLE:J})}function AL($,U,J={},G){if(G===void 0)G=$==="edwards";if(!U||typeof U!=="object")throw Error(`expected valid ${$} CURVE object`);for(let X of["p","n","h"]){let Y=U[X];if(!(typeof Y==="bigint"&&Y>J6))throw Error(`CURVE.${X} must be positive bigint`)}let q=ML(U.p,J.Fp,G),I=ML(U.n,J.Fn,G),D=["Gx","Gy","a",$==="weierstrass"?"b":"d"];for(let X of D)if(!q.isValid(U[X]))throw Error(`CURVE.${X} must be valid field element of CURVE.Fp`);return U=Object.freeze(Object.assign({},U)),{CURVE:U,Fp:q,Fn:I}}function N9($,U){return function(G){let q=$(G);return{secretKey:q,publicKey:U(q)}}}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */var YI=BigInt(0),q6=BigInt(1),w9=BigInt(2);function ld($){return ZG($,{adjustScalarBytes:"function",powPminus2:"function"}),Object.freeze({...$})}function KL($){let U=ld($),{P:J,type:G,adjustScalarBytes:q,powPminus2:I,randomBytes:Q}=U,D=G==="x25519";if(!D&&G!=="x448")throw Error("invalid type");let X=Q||Yq,Y=D?255:448,V=D?32:56,W=D?BigInt(9):BigInt(5),O=D?BigInt(121665):BigInt(39081),Z=D?w9**BigInt(254):w9**BigInt(447),M=D?BigInt(8)*w9**BigInt(251)-q6:BigInt(4)*w9**BigInt(445)-q6,w=Z+M+q6,H=(j)=>t0(j,J),g=P(W);function P(j){return GI(H(j),V)}function C(j){let L=Z9(B$(j,V,"uCoordinate"));if(D)L[31]&=127;return H(Oq(L))}function F(j){return Oq(q(Z9(B$(j,V,"scalar"))))}function f(j,L){let S=s(C(L),F(j));if(S===YI)throw Error("invalid private or public key received");return P(S)}function E(j){return f(j,g)}let p=E,b=f;function h(j,L,S){let y=H(j*(L-S));return L=H(L-y),S=H(S+y),{x_2:L,x_3:S}}function s(j,L){II("u",j,YI,J),II("scalar",L,Z,w);let S=L,y=j,u=q6,l=YI,A=j,o=q6,G$=YI;for(let R$=BigInt(Y-1);R$>=YI;R$--){let H$=S>>R$&q6;G$^=H$,{x_2:u,x_3:A}=h(G$,u,A),{x_2:l,x_3:o}=h(G$,l,o),G$=H$;let K$=u+l,A$=H(K$*K$),w$=u-l,P$=H(w$*w$),u$=A$-P$,m$=A+o,o$=A-o,J0=H(o$*K$),E0=H(m$*w$),YU=J0+E0,VU=J0-E0;A=H(YU*YU),o=H(y*H(VU*VU)),u=H(A$*P$),l=H(u$*(A$+H(O*u$)))}({x_2:u,x_3:A}=h(G$,u,A)),{x_2:l,x_3:o}=h(G$,l,o);let B=I(l);return H(u*B)}let m={secretKey:V,publicKey:V,seed:V},_=(j=X(V))=>{return B$(j,m.seed,"seed"),j},v={randomSecretKey:_};return Object.freeze({keygen:N9(_,p),getSharedSecret:b,getPublicKey:p,scalarMult:f,scalarMultBase:E,utils:v,GuBytes:g.slice(),lengths:m})}class a5{oHash;iHash;blockLen;outputLen;finished=!1;destroyed=!1;constructor($,U){if(SU($),B$(U,void 0,"key"),this.iHash=$.create(),typeof this.iHash.update!=="function")throw Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;let J=this.blockLen,G=new Uint8Array(J);G.set(U.length>J?$.create().update(U).digest():U);for(let q=0;q<G.length;q++)G[q]^=54;this.iHash.update(G),this.oHash=$.create();for(let q=0;q<G.length;q++)G[q]^=106;this.oHash.update(G),QU(G)}update($){return jJ(this),this.iHash.update($),this}digestInto($){jJ(this),B$($,this.outputLen,"output"),this.finished=!0,this.iHash.digestInto($),this.oHash.update($),this.oHash.digestInto($),this.destroy()}digest(){let $=new Uint8Array(this.oHash.outputLen);return this.digestInto($),$}_cloneInto($){$||=Object.create(Object.getPrototypeOf(this),{});let{oHash:U,iHash:J,finished:G,destroyed:q,blockLen:I,outputLen:Q}=this;return $=$,$.finished=G,$.destroyed=q,$.blockLen=I,$.outputLen=Q,$.oHash=U._cloneInto($.oHash),$.iHash=J._cloneInto($.iHash),$}clone(){return this._cloneInto()}destroy(){this.destroyed=!0,this.oHash.destroy(),this.iHash.destroy()}}var G6=($,U,J)=>new a5($,U).update(J).digest();G6.create=($,U)=>new a5($,U);/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */var gL=($,U)=>($+($>=0?U:-U)/PL)/U;function id($,U,J){let[[G,q],[I,Q]]=U,D=gL(Q*$,J),X=gL(-q*$,J),Y=$-D*G-X*I,V=-D*q-X*Q,W=Y<PJ,O=V<PJ;if(W)Y=-Y;if(O)V=-V;let Z=QI(Math.ceil(m5(J)/2))+I6;if(Y<PJ||Y>=Z||V<PJ||V>=Z)throw Error("splitScalar (endomorphism): failed, k="+$);return{k1neg:W,k1:Y,k2neg:O,k2:V}}function t5($){if(!["compact","recovered","der"].includes($))throw Error('Signature format must be "compact", "recovered", or "der"');return $}function s5($,U){let J={};for(let G of Object.keys(U))J[G]=$[G]===void 0?U[G]:$[G];if(JI(J.lowS,"lowS"),JI(J.prehash,"prehash"),J.format!==void 0)t5(J.format);return J}class jL extends Error{constructor($=""){super($)}}var Rq={Err:jL,_tlv:{encode:($,U)=>{let{Err:J}=Rq;if($<0||$>256)throw new J("tlv.encode: wrong tag");if(U.length&1)throw new J("tlv.encode: unpadded data");let G=U.length/2,q=qI(G);if(q.length/2&128)throw new J("tlv.encode: long form length too big");let I=G>127?qI(q.length/2|128):"";return qI($)+I+q+U},decode($,U){let{Err:J}=Rq,G=0;if($<0||$>256)throw new J("tlv.encode: wrong tag");if(U.length<2||U[G++]!==$)throw new J("tlv.decode: wrong tlv");let q=U[G++],I=!!(q&128),Q=0;if(!I)Q=q;else{let X=q&127;if(!X)throw new J("tlv.decode(long): indefinite length not supported");if(X>4)throw new J("tlv.decode(long): byte length is too big");let Y=U.subarray(G,G+X);if(Y.length!==X)throw new J("tlv.decode: length bytes not complete");if(Y[0]===0)throw new J("tlv.decode(long): zero leftmost byte");for(let V of Y)Q=Q<<8|V;if(G+=X,Q<128)throw new J("tlv.decode(long): not minimal encoding")}let D=U.subarray(G,G+Q);if(D.length!==Q)throw new J("tlv.decode: wrong value length");return{v:D,l:U.subarray(G+Q)}}},_int:{encode($){let{Err:U}=Rq;if($<PJ)throw new U("integer: negative integers are not allowed");let J=qI($);if(Number.parseInt(J[0],16)&8)J="00"+J;if(J.length&1)throw new U("unexpected DER parsing assertion: unpadded hex");return J},decode($){let{Err:U}=Rq;if($[0]&128)throw new U("invalid signature integer: negative");if($[0]===0&&!($[1]&128))throw new U("invalid signature integer: unnecessary leading zero");return Wq($)}},toSig($){let{Err:U,_int:J,_tlv:G}=Rq,q=B$($,void 0,"signature"),{v:I,l:Q}=G.decode(48,q);if(Q.length)throw new U("invalid signature: left bytes after parsing");let{v:D,l:X}=G.decode(2,I),{v:Y,l:V}=G.decode(2,X);if(V.length)throw new U("invalid signature: left bytes after parsing");return{r:J.decode(D),s:J.decode(Y)}},hexFromSig($){let{_tlv:U,_int:J}=Rq,G=U.encode(2,J.encode($.r)),q=U.encode(2,J.encode($.s)),I=G+q;return U.encode(48,I)}},PJ=BigInt(0),I6=BigInt(1),PL=BigInt(2),M9=BigInt(3),pd=BigInt(4);function e5($,U={}){let J=AL("weierstrass",$,U),{Fp:G,Fn:q}=J,I=J.CURVE,{h:Q,n:D}=I;ZG(U,{},{allowInfinityPoint:"boolean",clearCofactor:"function",isTorsionFree:"function",fromBytes:"function",toBytes:"function",endo:"object"});let{endo:X}=U;if(X){if(!G.is0(I.a)||typeof X.beta!=="bigint"||!Array.isArray(X.basises))throw Error('invalid endo: expected "beta": bigint and "basises": array')}let Y=SL(G,q);function V(){if(!G.isOdd)throw Error("compression is not supported: Field does not have .isOdd()")}function W(_,v,j){let{x:L,y:S}=v.toAffine(),y=G.toBytes(L);if(JI(j,"isCompressed"),j){V();let u=!G.isOdd(S);return Q0(BL(u),y)}else return Q0(Uint8Array.of(4),y,G.toBytes(S))}function O(_){B$(_,void 0,"Point");let{publicKey:v,publicKeyUncompressed:j}=Y,L=_.length,S=_[0],y=_.subarray(1);if(L===v&&(S===2||S===3)){let u=G.fromBytes(y);if(!G.isValid(u))throw Error("bad point: is not on curve, wrong x");let l=w(u),A;try{A=G.sqrt(l)}catch(B){let R$=B instanceof Error?": "+B.message:"";throw Error("bad point: is not on curve, sqrt error"+R$)}V();let o=G.isOdd(A);if((S&1)===1!==o)A=G.neg(A);return{x:u,y:A}}else if(L===j&&S===4){let u=G.BYTES,l=G.fromBytes(y.subarray(0,u)),A=G.fromBytes(y.subarray(u,u*2));if(!H(l,A))throw Error("bad point: is not on curve");return{x:l,y:A}}else throw Error(`bad point: got length ${L}, expected compressed=${v} or uncompressed=${j}`)}let Z=U.toBytes||W,M=U.fromBytes||O;function w(_){let v=G.sqr(_),j=G.mul(v,_);return G.add(G.add(j,G.mul(_,I.a)),I.b)}function H(_,v){let j=G.sqr(v),L=w(_);return G.eql(j,L)}if(!H(I.Gx,I.Gy))throw Error("bad curve params: generator point");let g=G.mul(G.pow(I.a,M9),pd),P=G.mul(G.sqr(I.b),BigInt(27));if(G.is0(G.add(g,P)))throw Error("bad curve params: a or b");function C(_,v,j=!1){if(!G.isValid(v)||j&&G.is0(v))throw Error(`bad point coordinate ${_}`);return v}function F(_){if(!(_ instanceof h))throw Error("Weierstrass Point expected")}function f(_){if(!X||!X.basises)throw Error("no endo");return id(_,X.basises,q.ORDER)}let E=h5((_,v)=>{let{X:j,Y:L,Z:S}=_;if(G.eql(S,G.ONE))return{x:j,y:L};let y=_.is0();if(v==null)v=y?G.ONE:G.inv(S);let u=G.mul(j,v),l=G.mul(L,v),A=G.mul(S,v);if(y)return{x:G.ZERO,y:G.ZERO};if(!G.eql(A,G.ONE))throw Error("invZ was invalid");return{x:u,y:l}}),p=h5((_)=>{if(_.is0()){if(U.allowInfinityPoint&&!G.is0(_.Y))return;throw Error("bad point: ZERO")}let{x:v,y:j}=_.toAffine();if(!G.isValid(v)||!G.isValid(j))throw Error("bad point: x or y not field elements");if(!H(v,j))throw Error("bad point: equation left != right");if(!_.isTorsionFree())throw Error("bad point: not in prime-order subgroup");return!0});function b(_,v,j,L,S){return j=new h(G.mul(j.X,_),j.Y,j.Z),v=XI(L,v),j=XI(S,j),v.add(j)}class h{static BASE=new h(I.Gx,I.Gy,G.ONE);static ZERO=new h(G.ZERO,G.ONE,G.ZERO);static Fp=G;static Fn=q;X;Y;Z;constructor(_,v,j){this.X=C("x",_),this.Y=C("y",v,!0),this.Z=C("z",j),Object.freeze(this)}static CURVE(){return I}static fromAffine(_){let{x:v,y:j}=_||{};if(!_||!G.isValid(v)||!G.isValid(j))throw Error("invalid affine point");if(_ instanceof h)throw Error("projective point not allowed");if(G.is0(v)&&G.is0(j))return h.ZERO;return new h(v,j,G.ONE)}static fromBytes(_){let v=h.fromAffine(M(B$(_,void 0,"point")));return v.assertValidity(),v}static fromHex(_){return h.fromBytes(OG(_))}get x(){return this.toAffine().x}get y(){return this.toAffine().y}precompute(_=8,v=!0){if(m.createCache(this,_),!v)this.multiply(M9);return this}assertValidity(){p(this)}hasEvenY(){let{y:_}=this.toAffine();if(!G.isOdd)throw Error("Field doesn't support isOdd");return!G.isOdd(_)}equals(_){F(_);let{X:v,Y:j,Z:L}=this,{X:S,Y:y,Z:u}=_,l=G.eql(G.mul(v,u),G.mul(S,L)),A=G.eql(G.mul(j,u),G.mul(y,L));return l&&A}negate(){return new h(this.X,G.neg(this.Y),this.Z)}double(){let{a:_,b:v}=I,j=G.mul(v,M9),{X:L,Y:S,Z:y}=this,u=G.ZERO,l=G.ZERO,A=G.ZERO,o=G.mul(L,L),G$=G.mul(S,S),B=G.mul(y,y),R$=G.mul(L,S);return R$=G.add(R$,R$),A=G.mul(L,y),A=G.add(A,A),u=G.mul(_,A),l=G.mul(j,B),l=G.add(u,l),u=G.sub(G$,l),l=G.add(G$,l),l=G.mul(u,l),u=G.mul(R$,u),A=G.mul(j,A),B=G.mul(_,B),R$=G.sub(o,B),R$=G.mul(_,R$),R$=G.add(R$,A),A=G.add(o,o),o=G.add(A,o),o=G.add(o,B),o=G.mul(o,R$),l=G.add(l,o),B=G.mul(S,y),B=G.add(B,B),o=G.mul(B,R$),u=G.sub(u,o),A=G.mul(B,G$),A=G.add(A,A),A=G.add(A,A),new h(u,l,A)}add(_){F(_);let{X:v,Y:j,Z:L}=this,{X:S,Y:y,Z:u}=_,l=G.ZERO,A=G.ZERO,o=G.ZERO,G$=I.a,B=G.mul(I.b,M9),R$=G.mul(v,S),H$=G.mul(j,y),K$=G.mul(L,u),A$=G.add(v,j),w$=G.add(S,y);A$=G.mul(A$,w$),w$=G.add(R$,H$),A$=G.sub(A$,w$),w$=G.add(v,L);let P$=G.add(S,u);return w$=G.mul(w$,P$),P$=G.add(R$,K$),w$=G.sub(w$,P$),P$=G.add(j,L),l=G.add(y,u),P$=G.mul(P$,l),l=G.add(H$,K$),P$=G.sub(P$,l),o=G.mul(G$,w$),l=G.mul(B,K$),o=G.add(l,o),l=G.sub(H$,o),o=G.add(H$,o),A=G.mul(l,o),H$=G.add(R$,R$),H$=G.add(H$,R$),K$=G.mul(G$,K$),w$=G.mul(B,w$),H$=G.add(H$,K$),K$=G.sub(R$,K$),K$=G.mul(G$,K$),w$=G.add(w$,K$),R$=G.mul(H$,w$),A=G.add(A,R$),R$=G.mul(P$,w$),l=G.mul(A$,l),l=G.sub(l,R$),R$=G.mul(A$,H$),o=G.mul(P$,o),o=G.add(o,R$),new h(l,A,o)}subtract(_){return this.add(_.negate())}is0(){return this.equals(h.ZERO)}multiply(_){let{endo:v}=U;if(!q.isValidNot0(_))throw Error("invalid scalar: out of range");let j,L,S=(y)=>m.cached(this,y,(u)=>c5(h,u));if(v){let{k1neg:y,k1:u,k2neg:l,k2:A}=f(_),{p:o,f:G$}=S(u),{p:B,f:R$}=S(A);L=G$.add(R$),j=b(v.beta,o,B,y,l)}else{let{p:y,f:u}=S(_);j=y,L=u}return c5(h,[j,L])[0]}multiplyUnsafe(_){let{endo:v}=U,j=this;if(!q.isValid(_))throw Error("invalid scalar: out of range");if(_===PJ||j.is0())return h.ZERO;if(_===I6)return j;if(m.hasCache(this))return this.multiply(_);if(v){let{k1neg:L,k1:S,k2neg:y,k2:u}=f(_),{p1:l,p2:A}=zL(h,j,S,u);return b(v.beta,l,A,L,y)}else return m.unsafe(j,_)}toAffine(_){return E(this,_)}isTorsionFree(){let{isTorsionFree:_}=U;if(Q===I6)return!0;if(_)return _(h,this);return m.unsafe(this,D).is0()}clearCofactor(){let{clearCofactor:_}=U;if(Q===I6)return this;if(_)return _(h,this);return this.multiplyUnsafe(Q)}isSmallOrder(){return this.multiplyUnsafe(Q).is0()}toBytes(_=!0){return JI(_,"isCompressed"),this.assertValidity(),Z(h,this,_)}toHex(_=!0){return WG(this.toBytes(_))}toString(){return`<Point ${this.is0()?"ZERO":this.toHex()}>`}}let s=q.BITS,m=new o5(h,U.endo?Math.ceil(s/2):s);return h.BASE.precompute(8),h}function BL($){return Uint8Array.of($?2:3)}function SL($,U){return{secretKey:U.BYTES,publicKey:1+$.BYTES,publicKeyUncompressed:1+2*$.BYTES,publicKeyHasPrefix:!0,signature:2*U.BYTES}}function dd($,U={}){let{Fn:J}=$,G=U.randomBytes||Yq,q=Object.assign(SL($.Fp,J),{seed:i5(J.ORDER)});function I(Z){try{let M=J.fromBytes(Z);return J.isValidNot0(M)}catch(M){return!1}}function Q(Z,M){let{publicKey:w,publicKeyUncompressed:H}=q;try{let g=Z.length;if(M===!0&&g!==w)return!1;if(M===!1&&g!==H)return!1;return!!$.fromBytes(Z)}catch(g){return!1}}function D(Z=G(q.seed)){return RL(B$(Z,q.seed,"seed"),J.ORDER)}function X(Z,M=!0){return $.BASE.multiply(J.fromBytes(Z)).toBytes(M)}function Y(Z){let{secretKey:M,publicKey:w,publicKeyUncompressed:H}=q;if(!e8(Z))return;if("_lengths"in J&&J._lengths||M===w)return;let g=B$(Z,void 0,"key").length;return g===w||g===H}function V(Z,M,w=!0){if(Y(Z)===!0)throw Error("first arg must be private key");if(Y(M)===!1)throw Error("second arg must be public key");let H=J.fromBytes(Z);return $.fromBytes(M).multiply(H).toBytes(w)}let W={isValidSecretKey:I,isValidPublicKey:Q,randomSecretKey:D},O=N9(D,X);return Object.freeze({getPublicKey:X,getSharedSecret:V,keygen:O,Point:$,utils:W,lengths:q})}function $w($,U,J={}){SU(U),ZG(J,{},{hmac:"function",lowS:"boolean",randomBytes:"function",bits2int:"function",bits2int_modN:"function"}),J=Object.assign({},J);let G=J.randomBytes||Yq,q=J.hmac||((j,L)=>G6(U,j,L)),{Fp:I,Fn:Q}=$,{ORDER:D,BITS:X}=Q,{keygen:Y,getPublicKey:V,getSharedSecret:W,utils:O,lengths:Z}=dd($,J),M={prehash:!0,lowS:typeof J.lowS==="boolean"?J.lowS:!0,format:"compact",extraEntropy:!1},w=D*PL<I.ORDER;function H(j){let L=D>>I6;return j>L}function g(j,L){if(!Q.isValidNot0(L))throw Error(`invalid signature ${j}: out of range 1..Point.Fn.ORDER`);return L}function P(){if(w)throw Error('"recovered" sig type is not supported for cofactor >2 curves')}function C(j,L){t5(L);let S=Z.signature,y=L==="compact"?S:L==="recovered"?S+1:void 0;return B$(j,y)}class F{r;s;recovery;constructor(j,L,S){if(this.r=g("r",j),this.s=g("s",L),S!=null){if(P(),![0,1,2,3].includes(S))throw Error("invalid recovery id");this.recovery=S}Object.freeze(this)}static fromBytes(j,L=M.format){C(j,L);let S;if(L==="der"){let{r:A,s:o}=Rq.toSig(B$(j));return new F(A,o)}if(L==="recovered")S=j[0],L="compact",j=j.subarray(1);let y=Z.signature/2,u=j.subarray(0,y),l=j.subarray(y,y*2);return new F(Q.fromBytes(u),Q.fromBytes(l),S)}static fromHex(j,L){return this.fromBytes(OG(j),L)}assertRecovery(){let{recovery:j}=this;if(j==null)throw Error("invalid recovery id: must be present");return j}addRecoveryBit(j){return new F(this.r,this.s,j)}recoverPublicKey(j){let{r:L,s:S}=this,y=this.assertRecovery(),u=y===2||y===3?L+D:L;if(!I.isValid(u))throw Error("invalid recovery id: sig.r+curve.n != R.x");let l=I.toBytes(u),A=$.fromBytes(Q0(BL((y&1)===0),l)),o=Q.inv(u),G$=E(B$(j,void 0,"msgHash")),B=Q.create(-G$*o),R$=Q.create(S*o),H$=$.BASE.multiplyUnsafe(B).add(A.multiplyUnsafe(R$));if(H$.is0())throw Error("invalid recovery: point at infinify");return H$.assertValidity(),H$}hasHighS(){return H(this.s)}toBytes(j=M.format){if(t5(j),j==="der")return OG(Rq.hexFromSig(this));let{r:L,s:S}=this,y=Q.toBytes(L),u=Q.toBytes(S);if(j==="recovered")return P(),Q0(Uint8Array.of(this.assertRecovery()),y,u);return Q0(y,u)}toHex(j){return WG(this.toBytes(j))}}let f=J.bits2int||function(L){if(L.length>8192)throw Error("input is too large");let S=Wq(L),y=L.length*8-X;return y>0?S>>BigInt(y):S},E=J.bits2int_modN||function(L){return Q.create(f(L))},p=QI(X);function b(j){return II("num < 2^"+X,j,PJ,p),Q.toBytes(j)}function h(j,L){return B$(j,void 0,"message"),L?B$(U(j),void 0,"prehashed message"):j}function s(j,L,S){let{lowS:y,prehash:u,extraEntropy:l}=s5(S,M);j=h(j,u);let A=E(j),o=Q.fromBytes(L);if(!Q.isValidNot0(o))throw Error("invalid private key");let G$=[b(o),b(A)];if(l!=null&&l!==!1){let K$=l===!0?G(Z.secretKey):l;G$.push(B$(K$,void 0,"extraEntropy"))}let B=Q0(...G$),R$=A;function H$(K$){let A$=f(K$);if(!Q.isValidNot0(A$))return;let w$=Q.inv(A$),P$=$.BASE.multiply(A$).toAffine(),u$=Q.create(P$.x);if(u$===PJ)return;let m$=Q.create(w$*Q.create(R$+u$*o));if(m$===PJ)return;let o$=(P$.x===u$?0:2)|Number(P$.y&I6),J0=m$;if(y&&H(m$))J0=Q.neg(m$),o$^=1;return new F(u$,J0,w?void 0:o$)}return{seed:B,k2sig:H$}}function m(j,L,S={}){let{seed:y,k2sig:u}=s(j,L,S);return JL(U.outputLen,Q.BYTES,q)(y,u).toBytes(S.format)}function _(j,L,S,y={}){let{lowS:u,prehash:l,format:A}=s5(y,M);if(S=B$(S,void 0,"publicKey"),L=h(L,l),!e8(j)){let o=j instanceof F?", use sig.toBytes()":"";throw Error("verify expects Uint8Array signature"+o)}C(j,A);try{let o=F.fromBytes(j,A),G$=$.fromBytes(S);if(u&&o.hasHighS())return!1;let{r:B,s:R$}=o,H$=E(L),K$=Q.inv(R$),A$=Q.create(H$*K$),w$=Q.create(B*K$),P$=$.BASE.multiplyUnsafe(A$).add(G$.multiplyUnsafe(w$));if(P$.is0())return!1;return Q.create(P$.x)===B}catch(o){return!1}}function v(j,L,S={}){let{prehash:y}=s5(S,M);return L=h(L,y),F.fromBytes(j,"recovered").recoverPublicKey(L).toBytes()}return Object.freeze({keygen:Y,getPublicKey:V,getSharedSecret:W,utils:O,lengths:Z,Point:$,sign:m,verify:_,recoverPublicKey:v,Signature:F,hash:U})}function LL($,U,J){return $&U^~$&J}function EL($,U,J){return $&U^$&J^U&J}class H9{blockLen;outputLen;padOffset;isLE;buffer;view;finished=!1;length=0;pos=0;destroyed=!1;constructor($,U,J,G){this.blockLen=$,this.outputLen=U,this.padOffset=J,this.isLE=G,this.buffer=new Uint8Array($),this.view=W9(this.buffer)}update($){jJ(this),B$($);let{view:U,buffer:J,blockLen:G}=this,q=$.length;for(let I=0;I<q;){let Q=Math.min(G-this.pos,q-I);if(Q===G){let D=W9($);for(;G<=q-I;I+=G)this.process(D,I);continue}if(J.set($.subarray(I,I+Q),this.pos),this.pos+=Q,I+=Q,this.pos===G)this.process(U,0),this.pos=0}return this.length+=$.length,this.roundClean(),this}digestInto($){jJ(this),Y9($,this),this.finished=!0;let{buffer:U,view:J,blockLen:G,isLE:q}=this,{pos:I}=this;if(U[I++]=128,QU(this.buffer.subarray(I)),this.padOffset>G-I)this.process(J,0),I=0;for(let V=I;V<G;V++)U[V]=0;J.setBigUint64(G-8,BigInt(this.length*8),q),this.process(J,0);let Q=W9($),D=this.outputLen;if(D%4)throw Error("_sha2: outputLen must be aligned to 32bit");let X=D/4,Y=this.get();if(X>Y.length)throw Error("_sha2: outputLen bigger than state");for(let V=0;V<X;V++)Q.setUint32(4*V,Y[V],q)}digest(){let{buffer:$,outputLen:U}=this;this.digestInto($);let J=$.slice(0,U);return this.destroy(),J}_cloneInto($){$||=new this.constructor,$.set(...this.get());let{blockLen:U,buffer:J,length:G,finished:q,destroyed:I,pos:Q}=this;if($.destroyed=I,$.finished=q,$.length=G,$.pos=Q,G%U)$.buffer.set(J);return $}clone(){return this._cloneInto()}}var BJ=Uint32Array.from([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),SJ=Uint32Array.from([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]),j0=Uint32Array.from([3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]),P0=Uint32Array.from([1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209]);var T9=BigInt(4294967295),CL=BigInt(32);function nd($,U=!1){if(U)return{h:Number($&T9),l:Number($>>CL&T9)};return{h:Number($>>CL&T9)|0,l:Number($&T9)|0}}function z9($,U=!1){let J=$.length,G=new Uint32Array(J),q=new Uint32Array(J);for(let I=0;I<J;I++){let{h:Q,l:D}=nd($[I],U);[G[I],q[I]]=[Q,D]}return[G,q]}var Uw=($,U,J)=>$>>>J,Jw=($,U,J)=>$<<32-J|U>>>J,wG=($,U,J)=>$>>>J|U<<32-J,MG=($,U,J)=>$<<32-J|U>>>J,VI=($,U,J)=>$<<64-J|U>>>J-32,WI=($,U,J)=>$>>>J-32|U<<64-J;var _L=($,U,J)=>$<<J|U>>>32-J,vL=($,U,J)=>U<<J|$>>>32-J,FL=($,U,J)=>U<<J-32|$>>>64-J,bL=($,U,J)=>$<<J-32|U>>>64-J;function JJ($,U,J,G){let q=(U>>>0)+(G>>>0);return{h:$+J+(q/4294967296|0)|0,l:q|0}}var uL=($,U,J)=>($>>>0)+(U>>>0)+(J>>>0),kL=($,U,J,G)=>U+J+G+($/4294967296|0)|0,xL=($,U,J,G)=>($>>>0)+(U>>>0)+(J>>>0)+(G>>>0),fL=($,U,J,G,q)=>U+J+G+q+($/4294967296|0)|0,yL=($,U,J,G,q)=>($>>>0)+(U>>>0)+(J>>>0)+(G>>>0)+(q>>>0),mL=($,U,J,G,q,I)=>U+J+G+q+I+($/4294967296|0)|0;var od=Uint32Array.from([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),Nq=new Uint32Array(64);class qw extends H9{constructor($){super(64,$,8,!1)}get(){let{A:$,B:U,C:J,D:G,E:q,F:I,G:Q,H:D}=this;return[$,U,J,G,q,I,Q,D]}set($,U,J,G,q,I,Q,D){this.A=$|0,this.B=U|0,this.C=J|0,this.D=G|0,this.E=q|0,this.F=I|0,this.G=Q|0,this.H=D|0}process($,U){for(let V=0;V<16;V++,U+=4)Nq[V]=$.getUint32(U,!1);for(let V=16;V<64;V++){let W=Nq[V-15],O=Nq[V-2],Z=yU(W,7)^yU(W,18)^W>>>3,M=yU(O,17)^yU(O,19)^O>>>10;Nq[V]=M+Nq[V-7]+Z+Nq[V-16]|0}let{A:J,B:G,C:q,D:I,E:Q,F:D,G:X,H:Y}=this;for(let V=0;V<64;V++){let W=yU(Q,6)^yU(Q,11)^yU(Q,25),O=Y+W+LL(Q,D,X)+od[V]+Nq[V]|0,M=(yU(J,2)^yU(J,13)^yU(J,22))+EL(J,G,q)|0;Y=X,X=D,D=Q,Q=I+O|0,I=q,q=G,G=J,J=O+M|0}J=J+this.A|0,G=G+this.B|0,q=q+this.C|0,I=I+this.D|0,Q=Q+this.E|0,D=D+this.F|0,X=X+this.G|0,Y=Y+this.H|0,this.set(J,G,q,I,Q,D,X,Y)}roundClean(){QU(Nq)}destroy(){this.set(0,0,0,0,0,0,0,0),QU(this.buffer)}}class hL extends qw{A=BJ[0]|0;B=BJ[1]|0;C=BJ[2]|0;D=BJ[3]|0;E=BJ[4]|0;F=BJ[5]|0;G=BJ[6]|0;H=BJ[7]|0;constructor(){super(32)}}class ad extends qw{A=SJ[0]|0;B=SJ[1]|0;C=SJ[2]|0;D=SJ[3]|0;E=SJ[4]|0;F=SJ[5]|0;G=SJ[6]|0;H=SJ[7]|0;constructor(){super(28)}}var rL=(()=>z9(["0x428a2f98d728ae22","0x7137449123ef65cd","0xb5c0fbcfec4d3b2f","0xe9b5dba58189dbbc","0x3956c25bf348b538","0x59f111f1b605d019","0x923f82a4af194f9b","0xab1c5ed5da6d8118","0xd807aa98a3030242","0x12835b0145706fbe","0x243185be4ee4b28c","0x550c7dc3d5ffb4e2","0x72be5d74f27b896f","0x80deb1fe3b1696b1","0x9bdc06a725c71235","0xc19bf174cf692694","0xe49b69c19ef14ad2","0xefbe4786384f25e3","0x0fc19dc68b8cd5b5","0x240ca1cc77ac9c65","0x2de92c6f592b0275","0x4a7484aa6ea6e483","0x5cb0a9dcbd41fbd4","0x76f988da831153b5","0x983e5152ee66dfab","0xa831c66d2db43210","0xb00327c898fb213f","0xbf597fc7beef0ee4","0xc6e00bf33da88fc2","0xd5a79147930aa725","0x06ca6351e003826f","0x142929670a0e6e70","0x27b70a8546d22ffc","0x2e1b21385c26c926","0x4d2c6dfc5ac42aed","0x53380d139d95b3df","0x650a73548baf63de","0x766a0abb3c77b2a8","0x81c2c92e47edaee6","0x92722c851482353b","0xa2bfe8a14cf10364","0xa81a664bbc423001","0xc24b8b70d0f89791","0xc76c51a30654be30","0xd192e819d6ef5218","0xd69906245565a910","0xf40e35855771202a","0x106aa07032bbd1b8","0x19a4c116b8d2d0c8","0x1e376c085141ab53","0x2748774cdf8eeb99","0x34b0bcb5e19b48a8","0x391c0cb3c5c95a63","0x4ed8aa4ae3418acb","0x5b9cca4f7763e373","0x682e6ff3d6b2b8a3","0x748f82ee5defb2fc","0x78a5636f43172f60","0x84c87814a1f0ab72","0x8cc702081a6439ec","0x90befffa23631e28","0xa4506cebde82bde9","0xbef9a3f7b2c67915","0xc67178f2e372532b","0xca273eceea26619c","0xd186b8c721c0c207","0xeada7dd6cde0eb1e","0xf57d4f7fee6ed178","0x06f067aa72176fba","0x0a637dc5a2c898a6","0x113f9804bef90dae","0x1b710b35131c471b","0x28db77f523047d84","0x32caab7b40c72493","0x3c9ebe0a15c9bebc","0x431d67c49c100d4c","0x4cc5d4becb3e42b6","0x597f299cfc657e2a","0x5fcb6fab3ad6faec","0x6c44198c4a475817"].map(($)=>BigInt($))))(),sd=(()=>rL[0])(),td=(()=>rL[1])(),wq=new Uint32Array(80),Mq=new Uint32Array(80);class OI extends H9{constructor($){super(128,$,16,!1)}get(){let{Ah:$,Al:U,Bh:J,Bl:G,Ch:q,Cl:I,Dh:Q,Dl:D,Eh:X,El:Y,Fh:V,Fl:W,Gh:O,Gl:Z,Hh:M,Hl:w}=this;return[$,U,J,G,q,I,Q,D,X,Y,V,W,O,Z,M,w]}set($,U,J,G,q,I,Q,D,X,Y,V,W,O,Z,M,w){this.Ah=$|0,this.Al=U|0,this.Bh=J|0,this.Bl=G|0,this.Ch=q|0,this.Cl=I|0,this.Dh=Q|0,this.Dl=D|0,this.Eh=X|0,this.El=Y|0,this.Fh=V|0,this.Fl=W|0,this.Gh=O|0,this.Gl=Z|0,this.Hh=M|0,this.Hl=w|0}process($,U){for(let P=0;P<16;P++,U+=4)wq[P]=$.getUint32(U),Mq[P]=$.getUint32(U+=4);for(let P=16;P<80;P++){let C=wq[P-15]|0,F=Mq[P-15]|0,f=wG(C,F,1)^wG(C,F,8)^Uw(C,F,7),E=MG(C,F,1)^MG(C,F,8)^Jw(C,F,7),p=wq[P-2]|0,b=Mq[P-2]|0,h=wG(p,b,19)^VI(p,b,61)^Uw(p,b,6),s=MG(p,b,19)^WI(p,b,61)^Jw(p,b,6),m=xL(E,s,Mq[P-7],Mq[P-16]),_=fL(m,f,h,wq[P-7],wq[P-16]);wq[P]=_|0,Mq[P]=m|0}let{Ah:J,Al:G,Bh:q,Bl:I,Ch:Q,Cl:D,Dh:X,Dl:Y,Eh:V,El:W,Fh:O,Fl:Z,Gh:M,Gl:w,Hh:H,Hl:g}=this;for(let P=0;P<80;P++){let C=wG(V,W,14)^wG(V,W,18)^VI(V,W,41),F=MG(V,W,14)^MG(V,W,18)^WI(V,W,41),f=V&O^~V&M,E=W&Z^~W&w,p=yL(g,F,E,td[P],Mq[P]),b=mL(p,H,C,f,sd[P],wq[P]),h=p|0,s=wG(J,G,28)^VI(J,G,34)^VI(J,G,39),m=MG(J,G,28)^WI(J,G,34)^WI(J,G,39),_=J&q^J&Q^q&Q,v=G&I^G&D^I&D;H=M|0,g=w|0,M=O|0,w=Z|0,O=V|0,Z=W|0,{h:V,l:W}=JJ(X|0,Y|0,b|0,h|0),X=Q|0,Y=D|0,Q=q|0,D=I|0,q=J|0,I=G|0;let j=uL(h,m,v);J=kL(j,b,s,_),G=j|0}({h:J,l:G}=JJ(this.Ah|0,this.Al|0,J|0,G|0)),{h:q,l:I}=JJ(this.Bh|0,this.Bl|0,q|0,I|0),{h:Q,l:D}=JJ(this.Ch|0,this.Cl|0,Q|0,D|0),{h:X,l:Y}=JJ(this.Dh|0,this.Dl|0,X|0,Y|0),{h:V,l:W}=JJ(this.Eh|0,this.El|0,V|0,W|0),{h:O,l:Z}=JJ(this.Fh|0,this.Fl|0,O|0,Z|0),{h:M,l:w}=JJ(this.Gh|0,this.Gl|0,M|0,w|0),{h:H,l:g}=JJ(this.Hh|0,this.Hl|0,H|0,g|0),this.set(J,G,q,I,Q,D,X,Y,V,W,O,Z,M,w,H,g)}roundClean(){QU(wq,Mq)}destroy(){QU(this.buffer),this.set(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0)}}class ed extends OI{Ah=P0[0]|0;Al=P0[1]|0;Bh=P0[2]|0;Bl=P0[3]|0;Ch=P0[4]|0;Cl=P0[5]|0;Dh=P0[6]|0;Dl=P0[7]|0;Eh=P0[8]|0;El=P0[9]|0;Fh=P0[10]|0;Fl=P0[11]|0;Gh=P0[12]|0;Gl=P0[13]|0;Hh=P0[14]|0;Hl=P0[15]|0;constructor(){super(64)}}class lL extends OI{Ah=j0[0]|0;Al=j0[1]|0;Bh=j0[2]|0;Bl=j0[3]|0;Ch=j0[4]|0;Cl=j0[5]|0;Dh=j0[6]|0;Dl=j0[7]|0;Eh=j0[8]|0;El=j0[9]|0;Fh=j0[10]|0;Fl=j0[11]|0;Gh=j0[12]|0;Gl=j0[13]|0;Hh=j0[14]|0;Hl=j0[15]|0;constructor(){super(48)}}var f0=Uint32Array.from([2352822216,424955298,1944164710,2312950998,502970286,855612546,1738396948,1479516111,258812777,2077511080,2011393907,79989058,1067287976,1780299464,286451373,2446758561]),y0=Uint32Array.from([573645204,4230739756,2673172387,3360449730,596883563,1867755857,2520282905,1497426621,2519219938,2827943907,3193839141,1401305490,721525244,746961066,246885852,2177182882]);class $n extends OI{Ah=f0[0]|0;Al=f0[1]|0;Bh=f0[2]|0;Bl=f0[3]|0;Ch=f0[4]|0;Cl=f0[5]|0;Dh=f0[6]|0;Dl=f0[7]|0;Eh=f0[8]|0;El=f0[9]|0;Fh=f0[10]|0;Fl=f0[11]|0;Gh=f0[12]|0;Gl=f0[13]|0;Hh=f0[14]|0;Hl=f0[15]|0;constructor(){super(28)}}class Un extends OI{Ah=y0[0]|0;Al=y0[1]|0;Bh=y0[2]|0;Bl=y0[3]|0;Ch=y0[4]|0;Cl=y0[5]|0;Dh=y0[6]|0;Dl=y0[7]|0;Eh=y0[8]|0;El=y0[9]|0;Fh=y0[10]|0;Fl=y0[11]|0;Gh=y0[12]|0;Gl=y0[13]|0;Hh=y0[14]|0;Hl=y0[15]|0;constructor(){super(32)}}var A9=$6(()=>new hL,Vq(1));var iL=$6(()=>new lL,Vq(2));/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */var Jn=BigInt(1),pL=BigInt(2),qn=BigInt(3),Gn=BigInt(5),GM$=BigInt(8),dL=BigInt("0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed");function In($){let U=BigInt(10),J=BigInt(20),G=BigInt(40),q=BigInt(80),I=dL,D=$*$%I*$%I,X=LU(D,pL,I)*D%I,Y=LU(X,Jn,I)*$%I,V=LU(Y,Gn,I)*Y%I,W=LU(V,U,I)*V%I,O=LU(W,J,I)*W%I,Z=LU(O,G,I)*O%I,M=LU(Z,q,I)*Z%I,w=LU(M,q,I)*Z%I,H=LU(w,U,I)*V%I;return{pow_p_5_8:LU(H,pL,I)*$%I,b2:D}}function Qn($){return $[0]&=248,$[31]&=127,$[31]|=64,$}var nL=(()=>{let $=dL;return KL({P:$,type:"x25519",powPminus2:(U)=>{let{pow_p_5_8:J,b2:G}=In(U);return t0(LU(J,qn,$)*G,$)},adjustScalarBytes:Qn})})();/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */var Dn=(()=>({p:BigInt("0xffffffff00000001000000000000000000000000ffffffffffffffffffffffff"),n:BigInt("0xffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551"),h:BigInt(1),a:BigInt("0xffffffff00000001000000000000000000000000fffffffffffffffffffffffc"),b:BigInt("0x5ac635d8aa3a93e7b3ebbd55769886bc651d06b0cc53b0f63bce3c3e27d2604b"),Gx:BigInt("0x6b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c296"),Gy:BigInt("0x4fe342e2fe1a7f9b8ee7eb4a7c0f9e162bce33576b315ececbb6406837bf51f5")}))(),Xn=(()=>({p:BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff"),n:BigInt("0xffffffffffffffffffffffffffffffffffffffffffffffffc7634d81f4372ddf581a0db248b0a77aecec196accc52973"),h:BigInt(1),a:BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000fffffffc"),b:BigInt("0xb3312fa7e23ee7e4988e056be3f82d19181d9c6efe8141120314088f5013875ac656398d8a2ed19d2a85c8edd3ec2aef"),Gx:BigInt("0xaa87ca22be8b05378eb1c71ef320ad746e1d3b628ba79b9859f741e082542a385502f25dbf55296c3a545e3872760ab7"),Gy:BigInt("0x3617de4a96262c6f5d9e98bf9292dc29f8f41dbd289a147ce9da3113b5f0b8c00a60b1ce1d7e819d7a431d7c90ea0e5f")}))();var Yn=e5(Dn),Gw=$w(Yn,A9);var Vn=e5(Xn),cL=$w(Vn,iL);function aL($,U,J){if(SU($),J===void 0)J=new Uint8Array($.outputLen);return G6($,J,U)}var Iw=Uint8Array.of(0),oL=Uint8Array.of();function sL($,U,J,G=32){SU($),R0(G,"length");let q=$.outputLen;if(G>255*q)throw Error("Length must be <= 255*HashLen");let I=Math.ceil(G/q);if(J===void 0)J=oL;else B$(J,void 0,"info");let Q=new Uint8Array(I*q),D=G6.create($,U),X=D._cloneInto(),Y=new Uint8Array(D.outputLen);for(let V=0;V<I;V++)Iw[0]=V+1,X.update(V===0?oL:Y).update(J).update(Iw).digestInto(Y),Q.set(Y,q*V),D._cloneInto(X);return D.destroy(),X.destroy(),QU(Y,Iw),Q.slice(0,G)}var Wn=BigInt(0),ZI=BigInt(1),On=BigInt(2),Zn=BigInt(7),Rn=BigInt(256),Nn=BigInt(113),$E=[],UE=[],JE=[];for(let $=0,U=ZI,J=1,G=0;$<24;$++){[J,G]=[G,(2*J+3*G)%5],$E.push(2*(5*G+J)),UE.push(($+1)*($+2)/2%64);let q=Wn;for(let I=0;I<7;I++)if(U=(U<<ZI^(U>>Zn)*Nn)%Rn,U&On)q^=ZI<<(ZI<<BigInt(I))-ZI;JE.push(q)}var qE=z9(JE,!0),wn=qE[0],Mn=qE[1],tL=($,U,J)=>J>32?FL($,U,J):_L($,U,J),eL=($,U,J)=>J>32?bL($,U,J):vL($,U,J);function Hn($,U=24){let J=new Uint32Array(10);for(let G=24-U;G<24;G++){for(let Q=0;Q<10;Q++)J[Q]=$[Q]^$[Q+10]^$[Q+20]^$[Q+30]^$[Q+40];for(let Q=0;Q<10;Q+=2){let D=(Q+8)%10,X=(Q+2)%10,Y=J[X],V=J[X+1],W=tL(Y,V,1)^J[D],O=eL(Y,V,1)^J[D+1];for(let Z=0;Z<50;Z+=10)$[Q+Z]^=W,$[Q+Z+1]^=O}let q=$[2],I=$[3];for(let Q=0;Q<24;Q++){let D=UE[Q],X=tL(q,I,D),Y=eL(q,I,D),V=$E[Q];q=$[V],I=$[V+1],$[V]=X,$[V+1]=Y}for(let Q=0;Q<50;Q+=10){for(let D=0;D<10;D++)J[D]=$[Q+D];for(let D=0;D<10;D++)$[Q+D]^=~J[(D+2)%10]&J[(D+4)%10]}$[0]^=wn[G],$[1]^=Mn[G]}QU(J)}class K9{state;pos=0;posOut=0;finished=!1;state32;destroyed=!1;blockLen;suffix;outputLen;enableXOF=!1;rounds;constructor($,U,J,G=!1,q=24){if(this.blockLen=$,this.suffix=U,this.outputLen=J,this.enableXOF=G,this.rounds=q,R0(J,"outputLen"),!(0<$&&$<200))throw Error("only keccak-f1600 function is supported");this.state=new Uint8Array(200),this.state32=V9(this.state)}clone(){return this._cloneInto()}keccak(){x5(this.state32),Hn(this.state32,this.rounds),x5(this.state32),this.posOut=0,this.pos=0}update($){jJ(this),B$($);let{blockLen:U,state:J}=this,G=$.length;for(let q=0;q<G;){let I=Math.min(U-this.pos,G-q);for(let Q=0;Q<I;Q++)J[this.pos++]^=$[q++];if(this.pos===U)this.keccak()}return this}finish(){if(this.finished)return;this.finished=!0;let{state:$,suffix:U,pos:J,blockLen:G}=this;if($[J]^=U,(U&128)!==0&&J===G-1)this.keccak();$[G-1]^=128,this.keccak()}writeInto($){jJ(this,!1),B$($),this.finish();let U=this.state,{blockLen:J}=this;for(let G=0,q=$.length;G<q;){if(this.posOut>=J)this.keccak();let I=Math.min(J-this.posOut,q-G);$.set(U.subarray(this.posOut,this.posOut+I),G),this.posOut+=I,G+=I}return $}xofInto($){if(!this.enableXOF)throw Error("XOF is not possible for this instance");return this.writeInto($)}xof($){return R0($),this.xofInto(new Uint8Array($))}digestInto($){if(Y9($,this),this.finished)throw Error("digest() was already called");return this.writeInto($),this.destroy(),$}digest(){return this.digestInto(new Uint8Array(this.outputLen))}destroy(){this.destroyed=!0,QU(this.state)}_cloneInto($){let{blockLen:U,suffix:J,outputLen:G,rounds:q,enableXOF:I}=this;return $||=new K9(U,J,G,I,q),$.state32.set(this.state32),$.pos=this.pos,$.posOut=this.posOut,$.finished=this.finished,$.rounds=q,$.suffix=J,$.outputLen=G,$.enableXOF=I,$.destroyed=this.destroyed,$}}var GE=($,U,J,G={})=>$6(()=>new K9(U,$,J),G);var HG=GE(6,136,32,Vq(8));var IE=GE(6,72,64,Vq(10));var QE=($,U,J,G={})=>$6((q={})=>new K9(U,$,q.dkLen===void 0?J:q.dkLen,!0),G),DE=QE(31,168,16,Vq(11)),qJ=QE(31,136,32,Vq(12));function Qw($){if(!Number.isSafeInteger($)||$<0||$>4294967295)throw Error("wrong u32 integer:"+$);return $}function YE($){return Qw($),($&$-1)===0&&$!==0}function Dw($,U){Qw($);let J=0;for(let G=0;G<U;G++,$>>>=1)J=J<<1|$&1;return J}function VE($){return Qw($),31-Math.clz32($)}function XE($){let U=$.length;if(U<2||!YE(U))throw Error("n must be a power of 2 and greater than 1. Got "+U);let J=VE(U);for(let G=0;G<U;G++){let q=Dw(G,J);if(G<q){let I=$[G];$[G]=$[q],$[q]=I}}return $}var Xw=($,U)=>{let{N:J,roots:G,dit:q,invertButterflies:I=!1,skipStages:Q=0,brp:D=!0}=U,X=VE(J);if(!YE(J))throw Error("FFT: Polynomial size should be power of two");let Y=q!==I;return(V)=>{if(V.length!==J)throw Error("FFT: wrong Polynomial length");if(q&&D)XE(V);for(let W=0,O=1;W<X-Q;W++){let Z=q?W+1+Q:X-W,M=1<<Z,w=M>>1,H=J>>Z;for(let g=0;g<J;g+=M)for(let P=0,C=O++;P<w;P++){let F=I?q?J-C:C:P*H,f=g+P,E=g+P+w,p=G[F],b=V[E],h=V[f];if(Y){let s=$.mul(b,p);V[f]=$.add(h,s),V[E]=$.sub(h,s)}else if(I)V[f]=$.add(b,h),V[E]=$.mul($.sub(b,h),p);else V[f]=$.add(h,b),V[E]=$.mul($.sub(h,b),p)}}if(!q&&D)XE(V);return V}};/*! noble-post-quantum - MIT License (c) 2024 Paul Miller (paulmillr.com) */var GJ=Yq;function g9($,U){if($.length!==U.length)return!1;let J=0;for(let G=0;G<$.length;G++)J|=$[G]^U[G];return J===0}function WE($){return Uint8Array.from($)}function TG($,...U){let J=(q)=>typeof q==="number"?q:q.bytesLen,G=U.reduce((q,I)=>q+J(I),0);return{bytesLen:G,encode:(q)=>{let I=new Uint8Array(G);for(let Q=0,D=0;Q<U.length;Q++){let X=U[Q],Y=J(X),V=typeof X==="number"?q[Q]:X.encode(q[Q]);if(B$(V,Y,$),I.set(V,D),typeof X!=="number")V.fill(0);D+=Y}return I},decode:(q)=>{B$(q,G,$);let I=[];for(let Q of U){let D=J(Q),X=q.subarray(0,D);I.push(typeof Q==="number"?X:Q.decode(X)),q=q.subarray(D)}return I}}}function j9($,U){let J=U*$.bytesLen;return{bytesLen:J,encode:(G)=>{if(G.length!==U)throw Error(`vecCoder.encode: wrong length=${G.length}. Expected: ${U}`);let q=new Uint8Array(J);for(let I=0,Q=0;I<G.length;I++){let D=$.encode(G[I]);q.set(D,Q),D.fill(0),Q+=D.length}return q},decode:(G)=>{B$(G,J);let q=[];for(let I=0;I<G.length;I+=$.bytesLen)q.push($.decode(G.subarray(I,I+$.bytesLen)));return q}}}function V0(...$){for(let U of $)if(Array.isArray(U))for(let J of U)J.fill(0);else U.fill(0)}function Yw($){return(1<<$)-1}var TM$=Uint8Array.of();/*! noble-post-quantum - MIT License (c) 2024 Paul Miller (paulmillr.com) */var OE=($)=>{let{newPoly:U,N:J,Q:G,F:q,ROOT_OF_UNITY:I,brvBits:Q,isKyber:D}=$,X=(P,C=G)=>{let F=P%C|0;return(F>=0?F|0:C+F|0)|0},Y=(P,C=G)=>{let F=X(P,C)|0;return(F>C>>1?F-C|0:F)|0};function V(){let P=U(J);for(let C=0;C<J;C++){let F=Dw(C,Q),f=BigInt(I)**BigInt(F)%BigInt(G);P[C]=Number(f)|0}return P}let W=V(),O={add:(P,C)=>X((P|0)+(C|0))|0,sub:(P,C)=>X((P|0)-(C|0))|0,mul:(P,C)=>X((P|0)*(C|0))|0,inv:(P)=>{throw Error("not implemented")}},Z={N:J,roots:W,invertButterflies:!0,skipStages:D?1:0,brp:!1},M=Xw(O,{dit:!1,...Z}),w=Xw(O,{dit:!0,...Z});return{mod:X,smod:Y,nttZetas:W,NTT:{encode:(P)=>{return M(P)},decode:(P)=>{w(P);for(let C=0;C<P.length;C++)P[C]=X(q*P[C]);return P}},bitsCoder:(P,C)=>{let F=Yw(P),f=P*(J/8);return{bytesLen:f,encode:(E)=>{let p=new Uint8Array(f);for(let b=0,h=0,s=0,m=0;b<E.length;b++){h|=(C.encode(E[b])&F)<<s,s+=P;for(;s>=8;s-=8,h>>=8)p[m++]=h&Yw(s)}return p},decode:(E)=>{let p=U(J);for(let b=0,h=0,s=0,m=0;b<E.length;b++){h|=E[b]<<s,s+=8;for(;s>=P;s-=P,h>>=P)p[m++]=C.decode(h&F)}return p}}}}},Tn=($)=>(U,J)=>{if(!J)J=$.blockLen;let G=new Uint8Array(U.length+2);G.set(U);let q=U.length,I=new Uint8Array(J),Q=$.create({}),D=0,X=0;return{stats:()=>({calls:D,xofs:X}),get:(Y,V)=>{return G[q+0]=Y,G[q+1]=V,Q.destroy(),Q=$.create({}).update(G),D++,()=>{return X++,Q.xofInto(I)}},clean:()=>{Q.destroy(),V0(I,G)}}},ZE=Tn(DE);/*! noble-post-quantum - MIT License (c) 2024 Paul Miller (paulmillr.com) */var m0=256,LJ=3329,zn=3303,An=17,{mod:wI,nttZetas:Kn,NTT:zG,bitsCoder:gn}=OE({N:m0,Q:LJ,F:zn,ROOT_OF_UNITY:An,newPoly:($)=>new Uint16Array($),brvBits:7,isKyber:!0}),Vw={512:{N:m0,Q:LJ,K:2,ETA1:3,ETA2:2,du:10,dv:4,RBGstrength:128},768:{N:m0,Q:LJ,K:3,ETA1:2,ETA2:2,du:10,dv:4,RBGstrength:192},1024:{N:m0,Q:LJ,K:4,ETA1:2,ETA2:2,du:11,dv:5,RBGstrength:256}},jn=($)=>{if($>=12)return{encode:(J)=>J,decode:(J)=>J};let U=2**($-1);return{encode:(J)=>((J<<$)+LJ/2)/LJ,decode:(J)=>J*LJ+U>>>$}},RI=($)=>gn($,jn($));function AG($,U){for(let J=0;J<m0;J++)$[J]=wI($[J]+U[J])}function Pn($,U){for(let J=0;J<m0;J++)$[J]=wI($[J]-U[J])}function Bn($,U,J,G,q){let I=wI(U*G*q+$*J),Q=wI($*G+U*J);return{c0:I,c1:Q}}function P9($,U){for(let J=0;J<m0/2;J++){let G=Kn[64+(J>>1)];if(J&1)G=-G;let{c0:q,c1:I}=Bn($[2*J+0],$[2*J+1],U[2*J+0],U[2*J+1],G);$[2*J+0]=q,$[2*J+1]=I}return $}function RE($){let U=new Uint16Array(m0);for(let J=0;J<m0;){let G=$();if(G.length%3)throw Error("SampleNTT: unaligned block");for(let q=0;J<m0&&q+3<=G.length;q+=3){let I=(G[q+0]>>0|G[q+1]<<8)&4095,Q=(G[q+1]>>4|G[q+2]<<4)&4095;if(I<LJ)U[J++]=I;if(J<m0&&Q<LJ)U[J++]=Q}}return U}function NI($,U,J,G){let q=$(G*m0/4,U,J),I=new Uint16Array(m0),Q=V9(q),D=0;for(let X=0,Y=0,V=0,W=0;X<Q.length;X++){let O=Q[X];for(let Z=0;Z<32;Z++)if(V+=O&1,O>>=1,D+=1,D===G)W=V,V=0;else if(D===2*G)I[Y++]=wI(W-V),V=0,D=0}if(D)throw Error(`sampleCBD: leftover bits: ${D}`);return I}var Sn=($)=>{let{K:U,PRF:J,XOF:G,HASH512:q,ETA1:I,ETA2:Q,du:D,dv:X}=$,Y=RI(1),V=RI(X),W=RI(D),O=TG("publicKey",j9(RI(12),U),32),Z=j9(RI(12),U),M=TG("ciphertext",j9(W,U),V),w=TG("seed",32,32);return{secretCoder:Z,lengths:{secretKey:Z.bytesLen,publicKey:O.bytesLen,cipherText:M.bytesLen},keygen:(H)=>{B$(H,32,"seed");let g=new Uint8Array(33);g.set(H),g[32]=U;let P=q(g),[C,F]=w.decode(P),f=[],E=[];for(let h=0;h<U;h++)f.push(zG.encode(NI(J,F,h,I)));let p=G(C);for(let h=0;h<U;h++){let s=zG.encode(NI(J,F,U+h,I));for(let m=0;m<U;m++){let _=RE(p.get(m,h));AG(s,P9(_,f[m]))}E.push(s)}p.clean();let b={publicKey:O.encode([E,C]),secretKey:Z.encode(f)};return V0(C,F,f,E,g,P),b},encrypt:(H,g,P)=>{let[C,F]=O.decode(H),f=[];for(let m=0;m<U;m++)f.push(zG.encode(NI(J,P,m,I)));let E=G(F),p=new Uint16Array(m0),b=[];for(let m=0;m<U;m++){let _=NI(J,P,U+m,Q),v=new Uint16Array(m0);for(let j=0;j<U;j++){let L=RE(E.get(m,j));AG(v,P9(L,f[j]))}AG(_,zG.decode(v)),b.push(_),AG(p,P9(C[m],f[m])),V0(v)}E.clean();let h=NI(J,P,2*U,Q);AG(h,zG.decode(p));let s=Y.decode(g);return AG(s,h),V0(C,f,p,h),M.encode([b,s])},decrypt:(H,g)=>{let[P,C]=M.decode(H),F=Z.decode(g),f=new Uint16Array(m0);for(let E=0;E<U;E++)AG(f,P9(F[E],zG.encode(P[E])));return Pn(C,zG.decode(f)),V0(f,F,P),Y.encode(C)}}};function Ww($){let U=Sn($),{HASH256:J,HASH512:G,KDF:q}=$,{secretCoder:I,lengths:Q}=U,D=TG("secretKey",Q.secretKey,Q.publicKey,32,32),X=32,Y=64;return{info:{type:"ml-kem"},lengths:{...Q,seed:64,msg:32,msgRand:32,secretKey:D.bytesLen},keygen:(V=GJ(64))=>{B$(V,64,"seed");let{publicKey:W,secretKey:O}=U.keygen(V.subarray(0,32)),Z=J(W),M=D.encode([O,W,Z,V.subarray(32)]);return V0(O,Z),{publicKey:W,secretKey:M}},getPublicKey:(V)=>{let[W,O,Z,M]=D.decode(V);return Uint8Array.from(O)},encapsulate:(V,W=GJ(32))=>{B$(V,Q.publicKey,"publicKey"),B$(W,32,"message");let O=V.subarray(0,384*$.K),Z=I.encode(I.decode(WE(O)));if(!g9(Z,O))throw V0(Z),Error("ML-KEM.encapsulate: wrong publicKey modulus");V0(Z);let M=G.create().update(W).update(J(V)).digest(),w=U.encrypt(V,W,M.subarray(32,64));return V0(M.subarray(32)),{cipherText:w,sharedSecret:M.subarray(0,32)}},decapsulate:(V,W)=>{B$(W,D.bytesLen,"secretKey"),B$(V,Q.cipherText,"cipherText");let O=D.bytesLen-96,Z=O+32,M=J(W.subarray(O/2,Z));if(!g9(M,W.subarray(Z,Z+32)))throw Error("invalid secretKey: hash check failed");let[w,H,g,P]=D.decode(W),C=U.decrypt(V,w),F=G.create().update(C).update(g).digest(),f=F.subarray(0,32),E=U.encrypt(H,C,F.subarray(32,64)),p=g9(V,E),b=q.create({dkLen:32}).update(P).update(V).digest();return V0(C,E,!p?f:b),p?f:b}}}function Ln($,U,J){return qJ.create({dkLen:$}).update(U).update(new Uint8Array([J])).digest()}var Ow={HASH256:HG,HASH512:IE,KDF:qJ,XOF:ZE,PRF:Ln},CM$=Ww({...Ow,...Vw[512]}),MI=Ww({...Ow,...Vw[768]}),NE=Ww({...Ow,...Vw[1024]});/*! noble-post-quantum - MIT License (c) 2024 Paul Miller (paulmillr.com) */function En($,U=!1){let{lengths:J,keygen:G}=$;if(U){let I=$.Point.Fn;if(!I)throw Error("No Point.Fn");G=(Q=GJ(J.seed))=>{B$(Q,J.seed,"seed");let D=I.isLE?Oq(Q):Wq(Q),X=I.toBytes(I.create(D));return{secretKey:X,publicKey:$.getPublicKey(X)}}}return{lengths:{secretKey:J.secretKey,publicKey:J.publicKey,seed:J.seed},keygen:G,getPublicKey:(q)=>$.getPublicKey(q)}}function Zw($,U=!1){let J=En($,U);if(!$.getSharedSecret)throw Error("wrong curve");return{lengths:{...J.lengths,msg:J.lengths.seed,cipherText:J.lengths.publicKey},keygen:J.keygen,getPublicKey:J.getPublicKey,encapsulate(G,q=GJ($.lengths.seed)){let I=this.keygen(q).secretKey,Q=this.decapsulate(G,I),D=$.getPublicKey(I);return V0(I),{sharedSecret:Q,cipherText:D}},decapsulate(G,q){let I=$.getSharedSecret(q,G);return $.lengths.publicKeyHasPrefix?I.subarray(1):I}}}function HI($,U){return TG(U,...$.map((J)=>{if(typeof J.lengths[U]!=="number")throw Error("wrong length: "+U);return J.lengths[U]}))}function Rw($){return(U,J)=>$(U,{dkLen:J})}function Cn($,U,...J){let G=HI(J,"seed"),q=HI(J,"publicKey");if($===void 0)$=G.bytesLen;R0($);function I(Q){B$(Q,$);let D=G.decode(U(Q,G.bytesLen)),X=J.map((W,O)=>W.keygen(D[O])),Y=X.map((W)=>W.secretKey),V=X.map((W)=>W.publicKey);return{secretKey:Y,publicKey:V}}return{info:{lengths:{seed:$,publicKey:q.bytesLen,secretKey:$}},getPublicKey(Q){return this.keygen(Q).publicKey},keygen(Q=GJ($)){let{publicKey:D,secretKey:X}=I(Q),Y=q.encode(D);return V0(D),V0(X),{secretKey:Q,publicKey:Y}},expandDecapsulationKey:I,realSeedLen:$}}function B9($,U,J,G,...q){let I=Cn($,J,...q),Q=HI(q,"cipherText"),D=HI(q,"publicKey"),X=HI(q,"msg");if(U===void 0)U=X.bytesLen;return R0(U),{lengths:{...I.info.lengths,msg:U,msgRand:X.bytesLen,cipherText:Q.bytesLen},getPublicKey:I.getPublicKey,keygen:I.keygen,encapsulate(Y,V=GJ(X.bytesLen)){let W=D.decode(Y),O=X.decode(V),Z=q.map((g,P)=>g.encapsulate(W[P],O[P])),M=Z.map((g)=>g.sharedSecret),w=Z.map((g)=>g.cipherText),H={sharedSecret:G(W,w,M),cipherText:Q.encode(w)};return V0(M,w),H},decapsulate(Y,V){let W=Q.decode(Y),{publicKey:O,secretKey:Z}=I.expandDecapsulationKey(V),M=q.map((w,H)=>w.decapsulate(W[H],Z[H]));return G(O,W,M)}}}function wE($,U,J,G,q){return SU(G),SU(q),B9(32,32,Rw(G),(I,Q,D)=>q(Q0(D[0],D[1],Q[1],I[1],Zq($))),U,J)}var hM$=wE("QSF-KEM(ML-KEM-768,P-256)-XOF(SHAKE256)-KDF(SHA3-256)",MI,Zw(Gw,!0),qJ,HG),rM$=wE("QSF-KEM(ML-KEM-1024,P-384)-XOF(SHAKE256)-KDF(SHA3-256)",NE,Zw(cL,!0),qJ,HG);function _n($,U,J,G,q){return SU(G),SU(q),B9(32,32,Rw(G),(I,Q,D)=>{let X=Q0(D[0],D[1],Q[0],I[0],Q[1],I[1],Zq($)),Y=32,V=Q0(Zq("hybrid_prk"),X),W=aL(q,V),O=Q0(U6(32,2),Zq("shared_secret"),Zq("")),Z=sL(q,W,O,32);return V0(W,O,V,X),Z},U,J)}var ME=Zw(nL),lM$=_n("KitchenSink-KEM(ML-KEM-768,X25519)-XOF(SHAKE256)-KDF(HKDF-SHA-256)",MI,ME,qJ,A9),vn=(()=>B9(32,32,Rw(qJ),($,U,J)=>HG(Q0(J[0],J[1],U[1],$[1],Zq("\\.//^\\"))),MI,ME))();function Fn($,U,J,G){let q=$.Point.Fn;if(!q)throw Error("no Point.Fn");function I(Q){let D;for(let V=0,W=U;;V=W,W+=U){if(W>Q.length)throw Error("rejection sampling failed");if(D=q.fromBytes(Q.subarray(V,W),!0),q.isValidNot0(D))break}let X=q.toBytes(q.create(D)),Y=$.getPublicKey(X,!1);return{secretKey:X,publicKey:Y}}return{lengths:{secretKey:U,publicKey:J,seed:G,msg:G,cipherText:J},keygen(Q=GJ(G)){return B$(Q,G,"seed"),I(Q)},getPublicKey(Q){return $.getPublicKey(Q,!1)},encapsulate(Q,D=GJ(G)){B$(D,G,"rand");let{secretKey:X}=I(D),Y=this.decapsulate(Q,X),V=$.getPublicKey(X,!1);return V0(X),{sharedSecret:Y,cipherText:V}},decapsulate(Q,D){return $.getSharedSecret(D,Q).subarray(1)}}}function bn($,U,J,G){let{secretKey:q,publicKeyUncompressed:I}=J.lengths;if(!q||!I)throw Error("wrong curve");let Q=Fn(J,q,I,G),D=64,X=D+G;return B9(32,32,(Y)=>{B$(Y,32);let V=qJ(Y,{dkLen:X}),W=V.subarray(0,D),O=V.subarray(D,X);return Q0(W,O)},(Y,V,W)=>HG(Q0(W[0],W[1],V[1],Y[1],Zq($))),U,Q)}var un=(()=>bn("MLKEM768-P256",MI,Gw,128))();var S9=vn,HE=un;/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */var i$=($,U,J)=>z0($,U,J),ww=$0,Q6=sX,B0=(...$)=>M5(...$),D6=($)=>n4($),X6=R5,Y6=($)=>TJ($),E9=BigInt(0),Nw=BigInt(1);function EJ($,U=""){if(typeof $!=="boolean"){let J=U&&`"${U}" `;throw TypeError(J+"expected boolean, got type="+typeof $)}return $}function C9($){if(typeof $==="bigint"){if(!L9($))throw RangeError("positive bigint expected, got "+$)}else ww($);return $}function IJ($,U=""){if(typeof $!=="number"){let J=U&&`"${U}" `;throw TypeError(J+"expected number, got type="+typeof $)}if(!Number.isSafeInteger($)){let J=U&&`"${U}" `;throw RangeError(J+"expected safe integer, got "+$)}}function TI($){let U=C9($).toString(16);return U.length&1?"0"+U:U}function TE($){if(typeof $!=="string")throw TypeError("hex string expected, got "+typeof $);return $===""?E9:BigInt("0x"+$)}function KG($){return TE(sX($))}function mU($){return TE(sX(Hq(z0($)).reverse()))}function _9($,U){if($0(U),U===0)throw RangeError("zero length");$=C9($);let J=$.toString(16);if(J.length>U*2)throw RangeError("number too large");return n4(J.padStart(U*2,"0"))}function zI($,U){return _9($,U).reverse()}function zE($,U){if($=i$($),U=i$(U),$.length!==U.length)return!1;let J=0;for(let G=0;G<$.length;G++)J|=$[G]^U[G];return J===0}function Hq($){return Uint8Array.from(i$($))}function v9($){if(typeof $!=="string")throw TypeError("ascii string expected, got "+typeof $);return Uint8Array.from($,(U,J)=>{let G=U.charCodeAt(0);if(U.length!==1||G>127)throw RangeError(`string contains non-ASCII character "${$[J]}" with code ${G} at position ${J}`);return G})}var L9=($)=>typeof $==="bigint"&&E9<=$;function kn($,U,J){return L9($)&&L9(U)&&L9(J)&&U<=$&&$<J}function CJ($,U,J,G){if(!kn(U,J,G))throw RangeError("expected valid "+$+": "+J+" <= n < "+G+", got "+U)}function V6($){if($<E9)throw Error("expected non-negative bigint, got "+$);let U;for(U=0;$>E9;$>>=Nw,U+=1);return U}var AI=($)=>(Nw<<BigInt($))-Nw;function AE($,U,J){if($0($,"hashLen"),$0(U,"qByteLen"),typeof J!=="function")throw TypeError("hmacFn must be a function");let G=(H)=>new Uint8Array(H),q=Uint8Array.of(),I=Uint8Array.of(0),Q=Uint8Array.of(1),D=1000,X=G($),Y=G($),V=0,W=()=>{X.fill(1),Y.fill(0),V=0},O=(...H)=>J(Y,B0(X,...H)),Z=(H=q)=>{if(Y=O(I,H),X=O(),H.length===0)return;Y=O(Q,H),X=O()},M=()=>{if(V++>=D)throw Error("drbg: tried max amount of iterations");let H=0,g=[];while(H<U){X=O();let P=X.slice();g.push(P),H+=X.length}return B0(...g)};return(H,g)=>{W(),Z(H);let P=void 0;while((P=g(M()))===void 0)Z();return W(),P}}function EU($,U={},J={}){if(Object.prototype.toString.call($)!=="[object Object]")throw TypeError("expected valid options object");function G(I,Q,D){if(!D&&Q!=="function"&&!Object.hasOwn($,I))throw TypeError(`param "${I}" is invalid: expected own property`);let X=$[I];if(D&&X===void 0)return;let Y=typeof X;if(Y!==Q||X===null)throw TypeError(`param "${I}" is invalid: expected ${Q}, got ${Y}`)}let q=(I,Q)=>Object.entries(I).forEach(([D,X])=>G(D,X,Q));q(U,!1),q(J,!0)}var Mw=()=>{throw Error("not implemented")};/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */var S0=BigInt(0),t$=BigInt(1),gG=BigInt(2),PE=BigInt(3),BE=BigInt(4),SE=BigInt(5),xn=BigInt(7),LE=BigInt(8),fn=BigInt(9),EE=BigInt(16);function n$($,U){if(U<=S0)throw Error("mod: expected positive modulus, got "+U);let J=$%U;return J>=S0?J:U+J}function CU($,U,J){if(U<S0)throw Error("pow2: expected non-negative exponent, got "+U);let G=$;while(U-- >S0)G*=G,G%=J;return G}function KE($,U){if($===S0)throw Error("invert: expected non-zero number");if(U<=S0)throw Error("invert: expected positive modulus, got "+U);let J=n$($,U),G=U,q=S0,I=t$,Q=t$,D=S0;while(J!==S0){let Y=G/J,V=G-J*Y,W=q-Q*Y,O=I-D*Y;G=J,J=V,q=Q,I=D,Q=W,D=O}if(G!==t$)throw Error("invert: does not exist");return n$(q,U)}function Hw($,U,J){let G=$;if(!G.eql(G.sqr(U),J))throw Error("Cannot find square root")}function CE($,U){let J=$,G=(J.ORDER+t$)/BE,q=J.pow(U,G);return Hw(J,q,U),q}function yn($,U){let J=$,G=(J.ORDER-SE)/LE,q=J.mul(U,gG),I=J.pow(q,G),Q=J.mul(U,I),D=J.mul(J.mul(Q,gG),I),X=J.mul(Q,J.sub(D,J.ONE));return Hw(J,X,U),X}function mn($){let U=F9($),J=_E($),G=J(U,U.neg(U.ONE)),q=J(U,G),I=J(U,U.neg(G)),Q=($+xn)/EE;return(D,X)=>{let Y=D,V=Y.pow(X,Q),W=Y.mul(V,G),O=Y.mul(V,q),Z=Y.mul(V,I),M=Y.eql(Y.sqr(W),X),w=Y.eql(Y.sqr(O),X);V=Y.cmov(V,W,M),W=Y.cmov(Z,O,w);let H=Y.eql(Y.sqr(W),X),g=Y.cmov(V,W,H);return Hw(Y,g,X),g}}function _E($){if($<PE)throw Error("sqrt is not defined for small field");let U=$-t$,J=0;while(U%gG===S0)U/=gG,J++;let G=gG,q=F9($);while(gE(q,G)===1)if(G++>1000)throw Error("Cannot find square root: probably non-prime P");if(J===1)return CE;let I=q.pow(G,U),Q=(U+t$)/gG;return function(X,Y){let V=X;if(V.is0(Y))return Y;if(gE(V,Y)!==1)throw Error("Cannot find square root");let W=J,O=V.mul(V.ONE,I),Z=V.pow(Y,U),M=V.pow(Y,Q);while(!V.eql(Z,V.ONE)){if(V.is0(Z))return V.ZERO;let w=1,H=V.sqr(Z);while(!V.eql(H,V.ONE))if(w++,H=V.sqr(H),w===W)throw Error("Cannot find square root");let g=t$<<BigInt(W-w-1),P=V.pow(O,g);W=w,O=V.sqr(P),Z=V.mul(Z,O),M=V.mul(M,P)}return M}}function hn($){if($%BE===PE)return CE;if($%LE===SE)return yn;if($%EE===fn)return mn($);return _E($)}var _J=($,U)=>(n$($,U)&t$)===t$,rn=["create","isValid","is0","neg","inv","sqrt","sqr","eql","add","sub","mul","pow","div","addN","subN","mulN","sqrN"];function Tw($){let U={ORDER:"bigint",BYTES:"number",BITS:"number"},J=rn.reduce((G,q)=>{return G[q]="function",G},U);if(EU($,J),IJ($.BYTES,"BYTES"),IJ($.BITS,"BITS"),$.BYTES<1||$.BITS<1)throw Error("invalid field: expected BYTES/BITS > 0");if($.ORDER<=t$)throw Error("invalid field: expected ORDER > 1, got "+$.ORDER);return $}function ln($,U,J){let G=$;if(J<S0)throw Error("invalid exponent, negatives unsupported");if(J===S0)return G.ONE;if(J===t$)return U;let q=G.ONE,I=U;while(J>S0){if(J&t$)q=G.mul(q,I);I=G.sqr(I),J>>=t$}return q}function KI($,U,J=!1){let G=$,q=Array(U.length).fill(J?G.ZERO:void 0),I=U.reduce((D,X,Y)=>{if(G.is0(X))return D;return q[Y]=D,G.mul(D,X)},G.ONE),Q=G.inv(I);return U.reduceRight((D,X,Y)=>{if(G.is0(X))return D;return q[Y]=G.mul(D,q[Y]),G.mul(D,X)},Q),q}function gE($,U){let J=$,G=(J.ORDER-t$)/gG,q=J.pow(U,G),I=J.eql(q,J.ONE),Q=J.eql(q,J.ZERO),D=J.eql(q,J.neg(J.ONE));if(!I&&!Q&&!D)throw Error("invalid Legendre symbol result");return I?1:Q?0:-1}function pn($,U){if(U!==void 0)ww(U);if($<=S0)throw Error("invalid n length: expected positive n, got "+$);if(U!==void 0&&U<1)throw Error("invalid n length: expected positive bit length, got "+U);let J=V6($);if(U!==void 0&&U<J)throw Error(`invalid n length: expected bit length (${J}) >= n.length (${U})`);let G=U!==void 0?U:J,q=Math.ceil(G/8);return{nBitLength:G,nByteLength:q}}var jE=new WeakMap;class zw{ORDER;BITS;BYTES;isLE;ZERO=S0;ONE=t$;_lengths;_mod;constructor($,U={}){if($<=t$)throw Error("invalid field: expected ORDER > 1, got "+$);let J=void 0;if(this.isLE=!1,U!=null&&typeof U==="object"){if(typeof U.BITS==="number")J=U.BITS;if(typeof U.sqrt==="function")Object.defineProperty(this,"sqrt",{value:U.sqrt,enumerable:!0});if(typeof U.isLE==="boolean")this.isLE=U.isLE;if(U.allowedLengths)this._lengths=Object.freeze(U.allowedLengths.slice());if(typeof U.modFromBytes==="boolean")this._mod=U.modFromBytes}let{nBitLength:G,nByteLength:q}=pn($,J);if(q>2048)throw Error("invalid field: expected ORDER of <= 2048 bytes");this.ORDER=$,this.BITS=G,this.BYTES=q,Object.freeze(this)}create($){return n$($,this.ORDER)}isValid($){if(typeof $!=="bigint")throw TypeError("invalid field element: expected bigint, got "+typeof $);return S0<=$&&$<this.ORDER}is0($){return $===S0}isValidNot0($){return!this.is0($)&&this.isValid($)}isOdd($){return($&t$)===t$}neg($){return n$(-$,this.ORDER)}eql($,U){return $===U}sqr($){return n$($*$,this.ORDER)}add($,U){return n$($+U,this.ORDER)}sub($,U){return n$($-U,this.ORDER)}mul($,U){return n$($*U,this.ORDER)}pow($,U){return ln(this,$,U)}div($,U){return n$($*KE(U,this.ORDER),this.ORDER)}sqrN($){return $*$}addN($,U){return $+U}subN($,U){return $-U}mulN($,U){return $*U}inv($){return KE($,this.ORDER)}sqrt($){let U=jE.get(this);if(!U)jE.set(this,U=hn(this.ORDER));return U(this,$)}toBytes($){return this.isLE?zI($,this.BYTES):_9($,this.BYTES)}fromBytes($,U=!1){i$($);let{_lengths:J,BYTES:G,isLE:q,ORDER:I,_mod:Q}=this;if(J){if($.length<1||!J.includes($.length)||$.length>G)throw Error("Field.fromBytes: expected "+J+" bytes, got "+$.length);let X=new Uint8Array(G);X.set($,q?0:X.length-$.length),$=X}if($.length!==G)throw Error("Field.fromBytes: expected "+G+" bytes, got "+$.length);let D=q?mU($):KG($);if(Q)D=n$(D,I);if(!U){if(!this.isValid(D))throw Error("invalid field element: outside of range 0..ORDER")}return D}invertBatch($){return KI(this,$)}cmov($,U,J){return EJ(J,"condition"),J?U:$}}Object.freeze(zw.prototype);function F9($,U={}){return new zw($,U)}function vE($){if(typeof $!=="bigint")throw Error("field order must be bigint");if($<=t$)throw Error("field order must be greater than 1");let U=V6($-t$);return Math.ceil(U/8)}function Aw($){let U=vE($);return U+Math.ceil(U/2)}function FE($,U,J=!1){i$($);let G=$.length,q=vE(U),I=Math.max(Aw(U),16);if(G<I||G>1024)throw Error("expected "+I+"-1024 bytes of input, got "+G);let Q=J?mU($):KG($),D=n$(Q,U-t$)+t$;return J?zI(D,q):_9(D,q)}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */var W6=BigInt(0),jG=BigInt(1);function gI($,U){let J=U.negate();return $?J:U}function PG($,U){let J=KI($.Fp,U.map((G)=>G.Z));return U.map((G,q)=>$.fromAffine(G.toAffine(J[q])))}function xE($,U){if(!Number.isSafeInteger($)||$<=0||$>U)throw Error("invalid window size, expected [1.."+U+"], got W="+$)}function Kw($,U){xE($,U);let J=Math.ceil(U/$)+1,G=2**($-1),q=2**$,I=AI($),Q=BigInt($);return{windows:J,windowSize:G,mask:I,maxNumber:q,shiftBy:Q}}function bE($,U,J){let{windowSize:G,mask:q,maxNumber:I,shiftBy:Q}=J,D=Number($&q),X=$>>Q;if(D>G)D-=I,X+=jG;let Y=U*G,V=Y+Math.abs(D)-1,W=D===0,O=D<0,Z=U%2!==0;return{nextN:X,offset:V,isZero:W,isNeg:O,isNegF:Z,offsetF:Y}}var gw=new WeakMap,fE=new WeakMap;function jw($){return fE.get($)||1}function uE($){if($!==W6)throw Error("invalid wNAF")}class jI{BASE;ZERO;Fn;bits;constructor($,U){this.BASE=$.BASE,this.ZERO=$.ZERO,this.Fn=$.Fn,this.bits=U}_unsafeLadder($,U,J=this.ZERO){let G=$;while(U>W6){if(U&jG)J=J.add(G);G=G.double(),U>>=jG}return J}precomputeWindow($,U){let{windows:J,windowSize:G}=Kw(U,this.bits),q=[],I=$,Q=I;for(let D=0;D<J;D++){Q=I,q.push(Q);for(let X=1;X<G;X++)Q=Q.add(I),q.push(Q);I=Q.double()}return q}wNAF($,U,J){if(!this.Fn.isValid(J))throw Error("invalid scalar");let G=this.ZERO,q=this.BASE,I=Kw($,this.bits);for(let Q=0;Q<I.windows;Q++){let{nextN:D,offset:X,isZero:Y,isNeg:V,isNegF:W,offsetF:O}=bE(J,Q,I);if(J=D,Y)q=q.add(gI(W,U[O]));else G=G.add(gI(V,U[X]))}return uE(J),{p:G,f:q}}wNAFUnsafe($,U,J,G=this.ZERO){let q=Kw($,this.bits);for(let I=0;I<q.windows;I++){if(J===W6)break;let{nextN:Q,offset:D,isZero:X,isNeg:Y}=bE(J,I,q);if(J=Q,X)continue;else{let V=U[D];G=G.add(Y?V.negate():V)}}return uE(J),G}getPrecomputes($,U,J){let G=gw.get(U);if(!G){if(G=this.precomputeWindow(U,$),$!==1){if(typeof J==="function")G=J(G);gw.set(U,G)}}return G}cached($,U,J){let G=jw($);return this.wNAF(G,this.getPrecomputes(G,$,J),U)}unsafe($,U,J,G){let q=jw($);if(q===1)return this._unsafeLadder($,U,G);return this.wNAFUnsafe(q,this.getPrecomputes(q,$,J),U,G)}createCache($,U){xE(U,this.bits),fE.set($,U),gw.delete($)}hasCache($){return jw($)!==1}}function yE($,U,J,G){let q=U,I=$.ZERO,Q=$.ZERO;while(J>W6||G>W6){if(J&jG)I=I.add(q);if(G&jG)Q=Q.add(q);q=q.double(),J>>=jG,G>>=jG}return{p1:I,p2:Q}}function kE($,U,J){if(U){if(U.ORDER!==$)throw Error("Field.ORDER must match order: Fp == p, Fn == n");return Tw(U),U}else return F9($,{isLE:J})}function b9($,U,J={},G){if(G===void 0)G=$==="edwards";if(!U||typeof U!=="object")throw Error(`expected valid ${$} CURVE object`);for(let X of["p","n","h"]){let Y=U[X];if(!(typeof Y==="bigint"&&Y>W6))throw Error(`CURVE.${X} must be positive bigint`)}let q=kE(U.p,J.Fp,G),I=kE(U.n,J.Fn,G),D=["Gx","Gy","a",$==="weierstrass"?"b":"d"];for(let X of D)if(!q.isValid(U[X]))throw Error(`CURVE.${X} must be valid field element of CURVE.Fp`);return U=Object.freeze(Object.assign({},U)),{CURVE:U,Fp:q,Fn:I}}function PI($,U){return function(G){let q=$(G);return{secretKey:q,publicKey:U(q)}}}function BI($,U){if(IJ($),IJ(U),U<0||U>4)throw Error("invalid I2OSP length: "+U);if($<0||$>2**(8*U)-1)throw Error("invalid I2OSP input: "+$);let J=Array.from({length:U}).fill(0);for(let G=U-1;G>=0;G--)J[G]=$&255,$>>>=8;return new Uint8Array(J)}function dn($,U){let J=new Uint8Array($.length);for(let G=0;G<$.length;G++)J[G]=$[G]^U[G];return J}function nn($){if(!X6($)&&typeof $!=="string")throw Error("DST must be Uint8Array or ascii string");let U=typeof $==="string"?v9($):$;if(U.length===0)throw Error("DST must be non-empty");return U}function Pw($,U,J,G){if(i$($),IJ(J),U=nn(U),U.length>255)U=G(B0(v9("H2C-OVERSIZE-DST-"),U));let{outputLen:q,blockLen:I}=G,Q=Math.ceil(J/q);if(J>65535||Q>255)throw Error("expand_message_xmd: invalid lenInBytes");let D=B0(U,BI(U.length,1)),X=new Uint8Array(I),Y=BI(J,2),V=Array(Q),W=G(B0(X,$,Y,BI(0,1),D));V[0]=G(B0(W,BI(1,1),D));for(let Z=1;Z<Q;Z++){let M=[dn(W,V[Z-1]),BI(Z+1,1),D];V[Z]=G(B0(...M))}return B0(...V).slice(0,J)}var mE="HashToScalar-";/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */var hE=($,U)=>($+($>=0?U:-U)/lE)/U;function cn($,U,J){CJ("scalar",$,QJ,J);let[[G,q],[I,Q]]=U,D=hE(Q*$,J),X=hE(-q*$,J),Y=$-D*G-X*I,V=-D*q-X*Q,W=Y<QJ,O=V<QJ;if(W)Y=-Y;if(O)V=-V;let Z=AI(Math.ceil(V6(J)/2))+Tq;if(Y<QJ||Y>=Z||V<QJ||V>=Z)throw Error("splitScalar (endomorphism): failed for k");return{k1neg:W,k1:Y,k2neg:O,k2:V}}function Sw($){if(!["compact","recovered","der"].includes($))throw Error('Signature format must be "compact", "recovered", or "der"');return $}function Bw($,U){EU($);let J={};for(let G of Object.keys(U))J[G]=$[G]===void 0?U[G]:$[G];if(EJ(J.lowS,"lowS"),EJ(J.prehash,"prehash"),J.format!==void 0)Sw(J.format);return J}class rE extends Error{constructor($=""){super($)}}var hU={Err:rE,_tlv:{encode:($,U)=>{let{Err:J}=hU;if(IJ($,"tag"),$<0||$>255)throw new J("tlv.encode: wrong tag");if(typeof U!=="string")throw TypeError('"data" expected string, got type='+typeof U);if(U.length&1)throw new J("tlv.encode: unpadded data");let G=U.length/2,q=TI(G);if(q.length/2&128)throw new J("tlv.encode: long form length too big");let I=G>127?TI(q.length/2|128):"";return TI($)+I+q+U},decode($,U){let{Err:J}=hU;U=i$(U,void 0,"DER data");let G=0;if($<0||$>255)throw new J("tlv.encode: wrong tag");if(U.length<2||U[G++]!==$)throw new J("tlv.decode: wrong tlv");let q=U[G++],I=!!(q&128),Q=0;if(!I)Q=q;else{let X=q&127;if(!X)throw new J("tlv.decode(long): indefinite length not supported");if(X>4)throw new J("tlv.decode(long): byte length is too big");let Y=U.subarray(G,G+X);if(Y.length!==X)throw new J("tlv.decode: length bytes not complete");if(Y[0]===0)throw new J("tlv.decode(long): zero leftmost byte");for(let V of Y)Q=Q<<8|V;if(G+=X,Q<128)throw new J("tlv.decode(long): not minimal encoding")}let D=U.subarray(G,G+Q);if(D.length!==Q)throw new J("tlv.decode: wrong value length");return{v:D,l:U.subarray(G+Q)}}},_int:{encode($){let{Err:U}=hU;if(C9($),$<QJ)throw new U("integer: negative integers are not allowed");let J=TI($);if(Number.parseInt(J[0],16)&8)J="00"+J;if(J.length&1)throw new U("unexpected DER parsing assertion: unpadded hex");return J},decode($){let{Err:U}=hU;if($.length<1)throw new U("invalid signature integer: empty");if($[0]&128)throw new U("invalid signature integer: negative");if($.length>1&&$[0]===0&&!($[1]&128))throw new U("invalid signature integer: unnecessary leading zero");return KG($)}},toSig($){let{Err:U,_int:J,_tlv:G}=hU,q=i$($,void 0,"signature"),{v:I,l:Q}=G.decode(48,q);if(Q.length)throw new U("invalid signature: left bytes after parsing");let{v:D,l:X}=G.decode(2,I),{v:Y,l:V}=G.decode(2,X);if(V.length)throw new U("invalid signature: left bytes after parsing");return{r:J.decode(D),s:J.decode(Y)}},hexFromSig($){let{_tlv:U,_int:J}=hU,G=U.encode(2,J.encode($.r)),q=U.encode(2,J.encode($.s)),I=G+q;return U.encode(48,I)}};Object.freeze(hU._tlv);Object.freeze(hU._int);Object.freeze(hU);var QJ=BigInt(0),Tq=BigInt(1),lE=BigInt(2),u9=BigInt(3),on=BigInt(4);function iE($,U={}){let J=b9("weierstrass",$,U),G=J.Fp,q=J.Fn,I=J.CURVE,{h:Q,n:D}=I;EU(U,{},{allowInfinityPoint:"boolean",clearCofactor:"function",isTorsionFree:"function",fromBytes:"function",toBytes:"function",endo:"object"});let{endo:X,allowInfinityPoint:Y}=U;if(X){if(!G.is0(I.a)||typeof X.beta!=="bigint"||!Array.isArray(X.basises))throw Error('invalid endo: expected "beta": bigint and "basises": array')}let V=dE(G,q);function W(){if(!G.isOdd)throw Error("compression is not supported: Field does not have .isOdd()")}function O(m,_,v){if(Y&&_.is0())return Uint8Array.of(0);let{x:j,y:L}=_.toAffine(),S=G.toBytes(j);if(EJ(v,"isCompressed"),v){W();let y=!G.isOdd(L);return B0(pE(y),S)}else return B0(Uint8Array.of(4),S,G.toBytes(L))}function Z(m){i$(m,void 0,"Point");let{publicKey:_,publicKeyUncompressed:v}=V,j=m.length,L=m[0],S=m.subarray(1);if(Y&&j===1&&L===0)return{x:G.ZERO,y:G.ZERO};if(j===_&&(L===2||L===3)){let y=G.fromBytes(S);if(!G.isValid(y))throw Error("bad point: is not on curve, wrong x");let u=H(y),l;try{l=G.sqrt(u)}catch(G$){let B=G$ instanceof Error?": "+G$.message:"";throw Error("bad point: is not on curve, sqrt error"+B)}W();let A=G.isOdd(l);if((L&1)===1!==A)l=G.neg(l);return{x:y,y:l}}else if(j===v&&L===4){let y=G.BYTES,u=G.fromBytes(S.subarray(0,y)),l=G.fromBytes(S.subarray(y,y*2));if(!g(u,l))throw Error("bad point: is not on curve");return{x:u,y:l}}else throw Error(`bad point: got length ${j}, expected compressed=${_} or uncompressed=${v}`)}let M=U.toBytes===void 0?O:U.toBytes,w=U.fromBytes===void 0?Z:U.fromBytes;function H(m){let _=G.sqr(m),v=G.mul(_,m);return G.add(G.add(v,G.mul(m,I.a)),I.b)}function g(m,_){let v=G.sqr(_),j=H(m);return G.eql(v,j)}if(!g(I.Gx,I.Gy))throw Error("bad curve params: generator point");let P=G.mul(G.pow(I.a,u9),on),C=G.mul(G.sqr(I.b),BigInt(27));if(G.is0(G.add(P,C)))throw Error("bad curve params: a or b");function F(m,_,v=!1){if(!G.isValid(_)||v&&G.is0(_))throw Error(`bad point coordinate ${m}`);return _}function f(m){if(!(m instanceof b))throw Error("Weierstrass Point expected")}function E(m){if(!X||!X.basises)throw Error("no endo");return cn(m,X.basises,q.ORDER)}function p(m,_,v,j,L){return v=new b(G.mul(v.X,m),v.Y,v.Z),_=gI(j,_),v=gI(L,v),_.add(v)}class b{static BASE=new b(I.Gx,I.Gy,G.ONE);static ZERO=new b(G.ZERO,G.ONE,G.ZERO);static Fp=G;static Fn=q;X;Y;Z;constructor(m,_,v){this.X=F("x",m),this.Y=F("y",_,!0),this.Z=F("z",v),Object.freeze(this)}static CURVE(){return I}static fromAffine(m){let{x:_,y:v}=m||{};if(!m||!G.isValid(_)||!G.isValid(v))throw Error("invalid affine point");if(m instanceof b)throw Error("projective point not allowed");if(G.is0(_)&&G.is0(v))return b.ZERO;return new b(_,v,G.ONE)}static fromBytes(m){let _=b.fromAffine(w(i$(m,void 0,"point")));return _.assertValidity(),_}static fromHex(m){return b.fromBytes(D6(m))}get x(){return this.toAffine().x}get y(){return this.toAffine().y}precompute(m=8,_=!0){if(s.createCache(this,m),!_)this.multiply(u9);return this}assertValidity(){let m=this;if(m.is0()){if(U.allowInfinityPoint&&G.is0(m.X)&&G.eql(m.Y,G.ONE)&&G.is0(m.Z))return;throw Error("bad point: ZERO")}let{x:_,y:v}=m.toAffine();if(!G.isValid(_)||!G.isValid(v))throw Error("bad point: x or y not field elements");if(!g(_,v))throw Error("bad point: equation left != right");if(!m.isTorsionFree())throw Error("bad point: not in prime-order subgroup")}hasEvenY(){let{y:m}=this.toAffine();if(!G.isOdd)throw Error("Field doesn't support isOdd");return!G.isOdd(m)}equals(m){f(m);let{X:_,Y:v,Z:j}=this,{X:L,Y:S,Z:y}=m,u=G.eql(G.mul(_,y),G.mul(L,j)),l=G.eql(G.mul(v,y),G.mul(S,j));return u&&l}negate(){return new b(this.X,G.neg(this.Y),this.Z)}double(){let{a:m,b:_}=I,v=G.mul(_,u9),{X:j,Y:L,Z:S}=this,y=G.ZERO,u=G.ZERO,l=G.ZERO,A=G.mul(j,j),o=G.mul(L,L),G$=G.mul(S,S),B=G.mul(j,L);return B=G.add(B,B),l=G.mul(j,S),l=G.add(l,l),y=G.mul(m,l),u=G.mul(v,G$),u=G.add(y,u),y=G.sub(o,u),u=G.add(o,u),u=G.mul(y,u),y=G.mul(B,y),l=G.mul(v,l),G$=G.mul(m,G$),B=G.sub(A,G$),B=G.mul(m,B),B=G.add(B,l),l=G.add(A,A),A=G.add(l,A),A=G.add(A,G$),A=G.mul(A,B),u=G.add(u,A),G$=G.mul(L,S),G$=G.add(G$,G$),A=G.mul(G$,B),y=G.sub(y,A),l=G.mul(G$,o),l=G.add(l,l),l=G.add(l,l),new b(y,u,l)}add(m){f(m);let{X:_,Y:v,Z:j}=this,{X:L,Y:S,Z:y}=m,u=G.ZERO,l=G.ZERO,A=G.ZERO,o=I.a,G$=G.mul(I.b,u9),B=G.mul(_,L),R$=G.mul(v,S),H$=G.mul(j,y),K$=G.add(_,v),A$=G.add(L,S);K$=G.mul(K$,A$),A$=G.add(B,R$),K$=G.sub(K$,A$),A$=G.add(_,j);let w$=G.add(L,y);return A$=G.mul(A$,w$),w$=G.add(B,H$),A$=G.sub(A$,w$),w$=G.add(v,j),u=G.add(S,y),w$=G.mul(w$,u),u=G.add(R$,H$),w$=G.sub(w$,u),A=G.mul(o,A$),u=G.mul(G$,H$),A=G.add(u,A),u=G.sub(R$,A),A=G.add(R$,A),l=G.mul(u,A),R$=G.add(B,B),R$=G.add(R$,B),H$=G.mul(o,H$),A$=G.mul(G$,A$),R$=G.add(R$,H$),H$=G.sub(B,H$),H$=G.mul(o,H$),A$=G.add(A$,H$),B=G.mul(R$,A$),l=G.add(l,B),B=G.mul(w$,A$),u=G.mul(K$,u),u=G.sub(u,B),B=G.mul(K$,R$),A=G.mul(w$,A),A=G.add(A,B),new b(u,l,A)}subtract(m){return f(m),this.add(m.negate())}is0(){return this.equals(b.ZERO)}multiply(m){let{endo:_}=U;if(!q.isValidNot0(m))throw RangeError("invalid scalar: out of range");let v,j,L=(S)=>s.cached(this,S,(y)=>PG(b,y));if(_){let{k1neg:S,k1:y,k2neg:u,k2:l}=E(m),{p:A,f:o}=L(y),{p:G$,f:B}=L(l);j=o.add(B),v=p(_.beta,A,G$,S,u)}else{let{p:S,f:y}=L(m);v=S,j=y}return PG(b,[v,j])[0]}multiplyUnsafe(m){let{endo:_}=U,v=this,j=m;if(!q.isValid(j))throw RangeError("invalid scalar: out of range");if(j===QJ||v.is0())return b.ZERO;if(j===Tq)return v;if(s.hasCache(this))return this.multiply(j);if(_){let{k1neg:L,k1:S,k2neg:y,k2:u}=E(j),{p1:l,p2:A}=yE(b,v,S,u);return p(_.beta,l,A,L,y)}else return s.unsafe(v,j)}toAffine(m){let _=this,v=m,{X:j,Y:L,Z:S}=_;if(G.eql(S,G.ONE))return{x:j,y:L};let y=_.is0();if(v==null)v=y?G.ONE:G.inv(S);let u=G.mul(j,v),l=G.mul(L,v),A=G.mul(S,v);if(y)return{x:G.ZERO,y:G.ZERO};if(!G.eql(A,G.ONE))throw Error("invZ was invalid");return{x:u,y:l}}isTorsionFree(){let{isTorsionFree:m}=U;if(Q===Tq)return!0;if(m)return m(b,this);return s.unsafe(this,D).is0()}clearCofactor(){let{clearCofactor:m}=U;if(Q===Tq)return this;if(m)return m(b,this);return this.multiplyUnsafe(Q)}isSmallOrder(){if(Q===Tq)return this.is0();return this.clearCofactor().is0()}toBytes(m=!0){return EJ(m,"isCompressed"),this.assertValidity(),M(b,this,m)}toHex(m=!0){return Q6(this.toBytes(m))}toString(){return`<Point ${this.is0()?"ZERO":this.toHex()}>`}}let h=q.BITS,s=new jI(b,U.endo?Math.ceil(h/2):h);if(h>=8)b.BASE.precompute(8);return Object.freeze(b.prototype),Object.freeze(b),b}function pE($){return Uint8Array.of($?2:3)}function dE($,U){return{secretKey:U.BYTES,publicKey:1+$.BYTES,publicKeyUncompressed:1+2*$.BYTES,publicKeyHasPrefix:!0,signature:2*U.BYTES}}function an($,U={}){let{Fn:J}=$,G=U.randomBytes===void 0?Y6:U.randomBytes,q=Object.assign(dE($.Fp,J),{seed:Math.max(Aw(J.ORDER),16)});function I(Z){try{let M=J.fromBytes(Z);return J.isValidNot0(M)}catch(M){return!1}}function Q(Z,M){let{publicKey:w,publicKeyUncompressed:H}=q;try{let g=Z.length;if(M===!0&&g!==w)return!1;if(M===!1&&g!==H)return!1;return!!$.fromBytes(Z)}catch(g){return!1}}function D(Z){return Z=Z===void 0?G(q.seed):Z,FE(i$(Z,q.seed,"seed"),J.ORDER)}function X(Z,M=!0){return $.BASE.multiply(J.fromBytes(Z)).toBytes(M)}function Y(Z){let{secretKey:M,publicKey:w,publicKeyUncompressed:H}=q,g=J._lengths;if(!X6(Z))return;let P=i$(Z,void 0,"key").length,C=P===w||P===H,F=P===M||!!g?.includes(P);if(C&&F)return;return C}function V(Z,M,w=!0){if(Y(Z)===!0)throw Error("first arg must be private key");if(Y(M)===!1)throw Error("second arg must be public key");let H=J.fromBytes(Z);return $.fromBytes(M).multiply(H).toBytes(w)}let W={isValidSecretKey:I,isValidPublicKey:Q,randomSecretKey:D},O=PI(D,X);return Object.freeze(W),Object.freeze(q),Object.freeze({getPublicKey:X,getSharedSecret:V,keygen:O,Point:$,utils:W,lengths:q})}function nE($,U,J={}){let G=U;HJ(G),EU(J,{},{hmac:"function",lowS:"boolean",randomBytes:"function",bits2int:"function",bits2int_modN:"function"}),J=Object.assign({},J);let q=J.randomBytes===void 0?Y6:J.randomBytes,I=J.hmac===void 0?(L,S)=>eU(G,L,S):J.hmac,{Fp:Q,Fn:D}=$,{ORDER:X,BITS:Y}=D,{keygen:V,getPublicKey:W,getSharedSecret:O,utils:Z,lengths:M}=an($,J),w={prehash:!0,lowS:typeof J.lowS==="boolean"?J.lowS:!0,format:"compact",extraEntropy:!1},H=X*lE+Tq<Q.ORDER;function g(L){let S=X>>Tq;return L>S}function P(L,S){if(!D.isValidNot0(S))throw Error(`invalid signature ${L}: out of range 1..Point.Fn.ORDER`);return S}function C(){if(H)throw Error('"recovered" sig type is not supported for cofactor >2 curves')}function F(L,S){Sw(S);let y=M.signature,u=S==="compact"?y:S==="recovered"?y+1:void 0;return i$(L,u)}class f{r;s;recovery;constructor(L,S,y){if(this.r=P("r",L),this.s=P("s",S),y!=null){if(C(),![0,1,2,3].includes(y))throw Error("invalid recovery id");this.recovery=y}Object.freeze(this)}static fromBytes(L,S=w.format){F(L,S);let y;if(S==="der"){let{r:o,s:G$}=hU.toSig(i$(L));return new f(o,G$)}if(S==="recovered")y=L[0],S="compact",L=L.subarray(1);let u=M.signature/2,l=L.subarray(0,u),A=L.subarray(u,u*2);return new f(D.fromBytes(l),D.fromBytes(A),y)}static fromHex(L,S){return this.fromBytes(D6(L),S)}assertRecovery(){let{recovery:L}=this;if(L==null)throw Error("invalid recovery id: must be present");return L}addRecoveryBit(L){return new f(this.r,this.s,L)}recoverPublicKey(L){let{r:S,s:y}=this,u=this.assertRecovery(),l=u===2||u===3?S+X:S;if(!Q.isValid(l))throw Error("invalid recovery id: sig.r+curve.n != R.x");let A=Q.toBytes(l),o=$.fromBytes(B0(pE((u&1)===0),A)),G$=D.inv(l),B=p(i$(L,void 0,"msgHash")),R$=D.create(-B*G$),H$=D.create(y*G$),K$=$.BASE.multiplyUnsafe(R$).add(o.multiplyUnsafe(H$));if(K$.is0())throw Error("invalid recovery: point at infinify");return K$.assertValidity(),K$}hasHighS(){return g(this.s)}toBytes(L=w.format){if(Sw(L),L==="der")return D6(hU.hexFromSig(this));let{r:S,s:y}=this,u=D.toBytes(S),l=D.toBytes(y);if(L==="recovered")return C(),B0(Uint8Array.of(this.assertRecovery()),u,l);return B0(u,l)}toHex(L){return Q6(this.toBytes(L))}}Object.freeze(f.prototype),Object.freeze(f);let E=J.bits2int===void 0?function(S){if(S.length>8192)throw Error("input is too large");let y=KG(S),u=S.length*8-Y;return u>0?y>>BigInt(u):y}:J.bits2int,p=J.bits2int_modN===void 0?function(S){return D.create(E(S))}:J.bits2int_modN,b=AI(Y);function h(L){return CJ("num < 2^"+Y,L,QJ,b),D.toBytes(L)}function s(L,S){return i$(L,void 0,"message"),S?i$(G(L),void 0,"prehashed message"):L}function m(L,S,y){let{lowS:u,prehash:l,extraEntropy:A}=Bw(y,w);L=s(L,l);let o=p(L),G$=D.fromBytes(S);if(!D.isValidNot0(G$))throw Error("invalid private key");let B=[h(G$),h(o)];if(A!=null&&A!==!1){let A$=A===!0?q(M.secretKey):A;B.push(i$(A$,void 0,"extraEntropy"))}let R$=B0(...B),H$=o;function K$(A$){let w$=E(A$);if(!D.isValidNot0(w$))return;let P$=D.inv(w$),u$=$.BASE.multiply(w$).toAffine(),m$=D.create(u$.x);if(m$===QJ)return;let o$=D.create(P$*D.create(H$+m$*G$));if(o$===QJ)return;let J0=(u$.x===m$?0:2)|Number(u$.y&Tq),E0=o$;if(u&&g(o$))E0=D.neg(o$),J0^=1;return new f(m$,E0,H?void 0:J0)}return{seed:R$,k2sig:K$}}function _(L,S,y={}){let{seed:u,k2sig:l}=m(L,S,y);return AE(G.outputLen,D.BYTES,I)(u,l).toBytes(y.format)}function v(L,S,y,u={}){let{lowS:l,prehash:A,format:o}=Bw(u,w);if(y=i$(y,void 0,"publicKey"),S=s(S,A),!X6(L)){let G$=L instanceof f?", use sig.toBytes()":"";throw Error("verify expects Uint8Array signature"+G$)}F(L,o);try{let G$=f.fromBytes(L,o),B=$.fromBytes(y);if(l&&G$.hasHighS())return!1;let{r:R$,s:H$}=G$,K$=p(S),A$=D.inv(H$),w$=D.create(K$*A$),P$=D.create(R$*A$),u$=$.BASE.multiplyUnsafe(w$).add(B.multiplyUnsafe(P$));if(u$.is0())return!1;return D.create(u$.x)===R$}catch(G$){return!1}}function j(L,S,y={}){let{prehash:u}=Bw(y,w);return S=s(S,u),f.fromBytes(L,"recovered").recoverPublicKey(S).toBytes()}return Object.freeze({keygen:V,getPublicKey:W,getSharedSecret:O,utils:Z,lengths:M,Point:$,sign:_,verify:v,recoverPublicKey:j,Signature:f,hash:G})}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */var sn=(()=>({p:BigInt("0xffffffff00000001000000000000000000000000ffffffffffffffffffffffff"),n:BigInt("0xffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551"),h:BigInt(1),a:BigInt("0xffffffff00000001000000000000000000000000fffffffffffffffffffffffc"),b:BigInt("0x5ac635d8aa3a93e7b3ebbd55769886bc651d06b0cc53b0f63bce3c3e27d2604b"),Gx:BigInt("0x6b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c296"),Gy:BigInt("0x4fe342e2fe1a7f9b8ee7eb4a7c0f9e162bce33576b315ececbb6406837bf51f5")}))();var tn=iE(sn),O6=nE(tn,U0);/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */var zq=BigInt(0),DU=BigInt(1),Lw=BigInt(2),en=BigInt(8);function $c($,U,J,G){let q=$.sqr(J),I=$.sqr(G),Q=$.add($.mul(U.a,q),I),D=$.add($.ONE,$.mul(U.d,$.mul(q,I)));return $.eql(Q,D)}function cE($,U={}){let J=U,G=b9("edwards",$,J,J.FpFnLE),{Fp:q,Fn:I}=G,Q=G.CURVE,{h:D}=Q;EU(J,{},{uvRatio:"function"});let X=Lw<<BigInt(I.BYTES*8)-DU,Y=(w)=>q.create(w),V=J.uvRatio===void 0?(w,H)=>{try{return{isValid:!0,value:q.sqrt(q.div(w,H))}}catch(g){return{isValid:!1,value:zq}}}:J.uvRatio;if(!$c(q,Q,Q.Gx,Q.Gy))throw Error("bad curve params: generator point");function W(w,H,g=!1){let P=g?DU:zq;return CJ("coordinate "+w,H,P,X),H}function O(w){if(!(w instanceof Z))throw Error("EdwardsPoint expected")}class Z{static BASE=new Z(Q.Gx,Q.Gy,DU,Y(Q.Gx*Q.Gy));static ZERO=new Z(zq,DU,DU,zq);static Fp=q;static Fn=I;X;Y;Z;T;constructor(w,H,g,P){this.X=W("x",w),this.Y=W("y",H),this.Z=W("z",g,!0),this.T=W("t",P),Object.freeze(this)}static CURVE(){return Q}static fromAffine(w){if(w instanceof Z)throw Error("extended point not allowed");let{x:H,y:g}=w||{};return W("x",H),W("y",g),new Z(H,g,DU,Y(H*g))}static fromBytes(w,H=!1){let g=q.BYTES,{a:P,d:C}=Q;w=Hq(i$(w,g,"point")),EJ(H,"zip215");let F=Hq(w),f=w[g-1];F[g-1]=f&-129;let E=mU(F),p=H?X:q.ORDER;CJ("point.y",E,zq,p);let b=Y(E*E),h=Y(b-DU),s=Y(C*b-P),{isValid:m,value:_}=V(h,s);if(!m)throw Error("bad point: invalid y coordinate");let v=(_&DU)===DU,j=(f&128)!==0;if(!H&&_===zq&&j)throw Error("bad point: x=0 and x_0=1");if(j!==v)_=Y(-_);return Z.fromAffine({x:_,y:E})}static fromHex(w,H=!1){return Z.fromBytes(D6(w),H)}get x(){return this.toAffine().x}get y(){return this.toAffine().y}precompute(w=8,H=!0){if(M.createCache(this,w),!H)this.multiply(Lw);return this}assertValidity(){let w=this,{a:H,d:g}=Q;if(w.is0())throw Error("bad point: ZERO");let{X:P,Y:C,Z:F,T:f}=w,E=Y(P*P),p=Y(C*C),b=Y(F*F),h=Y(b*b),s=Y(E*H),m=Y(b*Y(s+p)),_=Y(h+Y(g*Y(E*p)));if(m!==_)throw Error("bad point: equation left != right (1)");let v=Y(P*C),j=Y(F*f);if(v!==j)throw Error("bad point: equation left != right (2)")}equals(w){O(w);let{X:H,Y:g,Z:P}=this,{X:C,Y:F,Z:f}=w,E=Y(H*f),p=Y(C*P),b=Y(g*f),h=Y(F*P);return E===p&&b===h}is0(){return this.equals(Z.ZERO)}negate(){return new Z(Y(-this.X),this.Y,this.Z,Y(-this.T))}double(){let{a:w}=Q,{X:H,Y:g,Z:P}=this,C=Y(H*H),F=Y(g*g),f=Y(Lw*Y(P*P)),E=Y(w*C),p=H+g,b=Y(Y(p*p)-C-F),h=E+F,s=h-f,m=E-F,_=Y(b*s),v=Y(h*m),j=Y(b*m),L=Y(s*h);return new Z(_,v,L,j)}add(w){O(w);let{a:H,d:g}=Q,{X:P,Y:C,Z:F,T:f}=this,{X:E,Y:p,Z:b,T:h}=w,s=Y(P*E),m=Y(C*p),_=Y(f*g*h),v=Y(F*b),j=Y((P+C)*(E+p)-s-m),L=v-_,S=v+_,y=Y(m-H*s),u=Y(j*L),l=Y(S*y),A=Y(j*y),o=Y(L*S);return new Z(u,l,o,A)}subtract(w){return O(w),this.add(w.negate())}multiply(w){if(!I.isValidNot0(w))throw RangeError("invalid scalar: expected 1 <= sc < curve.n");let{p:H,f:g}=M.cached(this,w,(P)=>PG(Z,P));return PG(Z,[H,g])[0]}multiplyUnsafe(w){if(!I.isValid(w))throw RangeError("invalid scalar: expected 0 <= sc < curve.n");if(w===zq)return Z.ZERO;if(this.is0()||w===DU)return this;return M.unsafe(this,w,(H)=>PG(Z,H))}isSmallOrder(){return this.clearCofactor().is0()}isTorsionFree(){return M.unsafe(this,Q.n).is0()}toAffine(w){let H=this,g=w,{X:P,Y:C,Z:F}=H,f=H.is0();if(g==null)g=f?en:q.inv(F);let E=Y(P*g),p=Y(C*g),b=q.mul(F,g);if(f)return{x:zq,y:DU};if(b!==DU)throw Error("invZ was invalid");return{x:E,y:p}}clearCofactor(){if(D===DU)return this;return this.multiplyUnsafe(D)}toBytes(){let{x:w,y:H}=this.toAffine(),g=q.toBytes(H);return g[g.length-1]|=w&DU?128:0,g}toHex(){return Q6(this.toBytes())}toString(){return`<Point ${this.is0()?"ZERO":this.toHex()}>`}}let M=new jI(Z,I.BITS);if(I.BITS>=8)Z.BASE.precompute(8);return Object.freeze(Z.prototype),Object.freeze(Z),Z}class Ew{static BASE;static ZERO;static Fp;static Fn;ep;constructor($){this.ep=$}static fromBytes($){Mw()}static fromHex($){Mw()}get x(){return this.toAffine().x}get y(){return this.toAffine().y}clearCofactor(){return this}assertValidity(){this.ep.assertValidity()}toAffine($){return this.ep.toAffine($)}toHex(){return Q6(this.toBytes())}toString(){return this.toHex()}isTorsionFree(){return!0}isSmallOrder(){return!1}add($){return this.assertSame($),this.init(this.ep.add($.ep))}subtract($){return this.assertSame($),this.init(this.ep.subtract($.ep))}multiply($){return this.init(this.ep.multiply($))}multiplyUnsafe($){return this.init(this.ep.multiplyUnsafe($))}double(){return this.init(this.ep.double())}negate(){return this.init(this.ep.negate())}precompute($,U){return this.ep.precompute($,U),this}}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */var SI=BigInt(0),Z6=BigInt(1),k9=BigInt(2);function Uc($){return EU($,{P:"bigint",type:"string",adjustScalarBytes:"function",powPminus2:"function"},{randomBytes:"function"}),Object.freeze({...$})}function oE($){let U=Uc($),{P:J,type:G,adjustScalarBytes:q,powPminus2:I,randomBytes:Q}=U,D=G==="x25519";if(!D&&G!=="x448")throw Error("invalid type");let X=Q===void 0?Y6:Q,Y=D?255:448,V=D?32:56,W=D?BigInt(9):BigInt(5),O=D?BigInt(121665):BigInt(39081),Z=D?k9**BigInt(254):k9**BigInt(447),M=D?BigInt(8)*k9**BigInt(251)-Z6:BigInt(4)*k9**BigInt(445)-Z6,w=Z+M+Z6,H=(j)=>n$(j,J),g=P(W);function P(j){return zI(H(j),V)}function C(j){let L=Hq(i$(j,V,"uCoordinate"));if(D)L[31]&=127;return H(mU(L))}function F(j){return mU(q(Hq(i$(j,V,"scalar"))))}function f(j,L){let S=s(C(L),F(j));if(S===SI)throw Error("invalid private or public key received");return P(S)}function E(j){return f(j,g)}let p=E,b=f;function h(j,L,S){let y=H(j*(L-S));return L=H(L-y),S=H(S+y),{x_2:L,x_3:S}}function s(j,L){CJ("u",j,SI,J),CJ("scalar",L,Z,w);let S=L,y=j,u=Z6,l=SI,A=j,o=Z6,G$=SI;for(let R$=BigInt(Y-1);R$>=SI;R$--){let H$=S>>R$&Z6;G$^=H$,{x_2:u,x_3:A}=h(G$,u,A),{x_2:l,x_3:o}=h(G$,l,o),G$=H$;let K$=u+l,A$=H(K$*K$),w$=u-l,P$=H(w$*w$),u$=A$-P$,m$=A+o,o$=A-o,J0=H(o$*K$),E0=H(m$*w$),YU=J0+E0,VU=J0-E0;A=H(YU*YU),o=H(y*H(VU*VU)),u=H(A$*P$),l=H(u$*(A$+H(O*u$)))}({x_2:u,x_3:A}=h(G$,u,A)),{x_2:l,x_3:o}=h(G$,l,o);let B=I(l);return H(u*B)}let m={secretKey:V,publicKey:V,seed:V},_=(j)=>{return j=j===void 0?X(V):j,i$(j,m.seed,"seed"),j},v={randomSecretKey:_};return Object.freeze(m),Object.freeze(v),Object.freeze({keygen:PI(_,p),getSharedSecret:b,getPublicKey:p,scalarMult:f,scalarMultBase:E,utils:v,GuBytes:g.slice(),lengths:m})}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */var Jc=BigInt(0),vJ=BigInt(1),aE=BigInt(2),qc=BigInt(3),Gc=BigInt(5),Ic=BigInt(8),SG=BigInt("0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed"),Fw=(()=>({p:SG,n:BigInt("0x1000000000000000000000000000000014def9dea2f79cd65812631a5cf5d3ed"),h:Ic,a:BigInt("0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffec"),d:BigInt("0x52036cee2b6ffe738cc740797779e89800700a4d4141d8ab75eb4dca135978a3"),Gx:BigInt("0x216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a"),Gy:BigInt("0x6666666666666666666666666666666666666666666666666666666666666658")}))();function eE($){let U=BigInt(10),J=BigInt(20),G=BigInt(40),q=BigInt(80),I=SG,D=$*$%I*$%I,X=CU(D,aE,I)*D%I,Y=CU(X,vJ,I)*$%I,V=CU(Y,Gc,I)*Y%I,W=CU(V,U,I)*V%I,O=CU(W,J,I)*W%I,Z=CU(O,G,I)*O%I,M=CU(Z,q,I)*Z%I,w=CU(M,q,I)*Z%I,H=CU(w,U,I)*V%I;return{pow_p_5_8:CU(H,aE,I)*$%I,b2:D}}function Qc($){return $[0]&=248,$[31]&=127,$[31]|=64,$}var Cw=BigInt("19681161376707505956807079304988542015446066515923890162744021073123829784752");function bw($,U){let J=SG,G=n$(U*U*U,J),q=n$(G*G*U,J),I=eE($*q).pow_p_5_8,Q=n$($*G*I,J),D=n$(U*Q*Q,J),X=Q,Y=n$(Q*Cw,J),V=D===$,W=D===n$(-$,J),O=D===n$(-$*Cw,J);if(V)Q=X;if(W||O)Q=Y;if(_J(Q,J))Q=n$(-Q,J);return{isValid:V||W,value:Q}}var BG=cE(Fw,{uvRatio:bw}),Aq=(()=>BG.Fp)(),$C=(()=>BG.Fn)();var x9=(()=>{let $=SG;return oE({P:$,type:"x25519",powPminus2:(U)=>{let{pow_p_5_8:J,b2:G}=eE(U);return n$(CU(J,qc,$)*G,$)},adjustScalarBytes:Qc})})();var _w=Cw,Dc=BigInt("25063068953384623474111414158702152701244531502492656460079210482610430750235"),Xc=BigInt("54469307008909316920995813868745141605393597292927456921205312896311721017578"),Yc=BigInt("1159843021668779879193775521855586647937357759715417654439879720876111806838"),Vc=BigInt("40440834346308536858101042469323190826248399146238708352240133220865137265952"),sE=($)=>bw(vJ,$),Wc=BigInt("0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"),vw=($)=>Aq.create(mU($)&Wc);function tE($){let{d:U}=Fw,J=SG,G=(g)=>Aq.create(g),q=G(_w*$*$),I=G((q+vJ)*Yc),Q=BigInt(-1),D=G((Q-U*q)*G(q+U)),{isValid:X,value:Y}=bw(I,D),V=G(Y*$);if(!_J(V,J))V=G(-V);if(!X)Y=V;if(!X)Q=q;let W=G(Q*(q-vJ)*Vc-D),O=Y*Y,Z=G((Y+Y)*D),M=G(W*Dc),w=G(vJ-O),H=G(vJ+O);return new BG(G(Z*H),G(w*M),G(M*H),G(Z*w))}class $U extends Ew{static BASE=(()=>new $U(BG.BASE))();static ZERO=(()=>new $U(BG.ZERO))();static Fp=(()=>Aq)();static Fn=(()=>$C)();constructor($){super($)}static fromAffine($){return new $U(BG.fromAffine($))}assertSame($){if(!($ instanceof $U))throw Error("RistrettoPoint expected")}init($){return new $U($)}static fromBytes($){z0($,32);let{a:U,d:J}=Fw,G=SG,q=(C)=>Aq.create(C),I=vw($);if(!zE(Aq.toBytes(I),$)||_J(I,G))throw Error("invalid ristretto255 encoding 1");let Q=q(I*I),D=q(vJ+U*Q),X=q(vJ-U*Q),Y=q(D*D),V=q(X*X),W=q(U*J*Y-V),{isValid:O,value:Z}=sE(q(W*V)),M=q(Z*X),w=q(Z*M*W),H=q((I+I)*M);if(_J(H,G))H=q(-H);let g=q(D*w),P=q(H*g);if(!O||_J(P,G)||g===Jc)throw Error("invalid ristretto255 encoding 2");return new $U(new BG(H,g,vJ,P))}static fromHex($){return $U.fromBytes(n4($))}toBytes(){let{X:$,Y:U,Z:J,T:G}=this.ep,q=SG,I=(w)=>Aq.create(w),Q=I(I(J+U)*I(J-U)),D=I($*U),X=I(D*D),{value:Y}=sE(I(Q*X)),V=I(Y*Q),W=I(Y*D),O=I(V*W*G),Z;if(_J(G*O,q)){let w=I(U*_w),H=I($*_w);$=w,U=H,Z=I(V*Xc)}else Z=W;if(_J($*O,q))U=I(-U);let M=I((J-U)*Z);if(_J(M,q))M=I(-M);return Aq.toBytes(M)}equals($){this.assertSame($);let{X:U,Y:J}=this.ep,{X:G,Y:q}=$.ep,I=(X)=>Aq.create(X),Q=I(U*q)===I(J*G),D=I(J*q)===I(U*G);return Q||D}is0(){return this.equals($U.ZERO)}}Object.freeze($U.BASE);Object.freeze($U.ZERO);Object.freeze($U.prototype);Object.freeze($U);var Oc=Object.freeze({Point:$U,hashToCurve($,U){let J=U?.DST===void 0?"ristretto255_XMD:SHA-512_R255MAP_RO_":U.DST,G=Pw($,J,64,U9);return Oc.deriveToCurve(G)},hashToScalar($,U={DST:mE}){let J=Pw($,U.DST,64,U9);return $C.create(mU(J))},deriveToCurve($){z0($,64);let U=vw($.subarray(0,32)),J=tE(U),G=vw($.subarray(32,64)),q=tE(G);return new $U(J.add(q))}});var UC=!1,Zc=!1;async function JC($,U){if(Zc)return await U();try{return await $()}catch(J){if(J instanceof ReferenceError||J instanceof DOMException&&J.name==="NotSupportedError")return await U();else throw J}}async function f9($,U){return await JC(async()=>{let J=uw($)?$:await Nc($),G=await crypto.subtle.importKey("raw",wc(U),{name:"X25519"},UC,[]);return new Uint8Array(await crypto.subtle.deriveBits({name:"X25519",public:G},J,256))},()=>{if(uw($))throw Error("CryptoKey provided but X25519 WebCrypto is not supported");return x9.scalarMult($,U)})}async function LI($){return await JC(async()=>{return f9($,x9.GuBytes)},()=>{if(uw($))throw Error("CryptoKey provided but X25519 WebCrypto is not supported");return x9.scalarMultBase($)})}var Rc=new Uint8Array([48,46,2,1,0,48,5,6,3,43,101,110,4,34,4,32]);async function Nc($){if($.length!==32)throw Error("X25519 private key must be 32 bytes");let U=new Uint8Array([...Rc,...$]);return crypto.subtle.importKey("pkcs8",U,{name:"X25519"},UC,["deriveBits"])}function uw($){return typeof CryptoKey<"u"&&$ instanceof CryptoKey}function wc($){return $}class kw{s;transcript=[];buf=new Uint8Array(0);constructor($){this.s=$.getReader()}async readLine(){let $=[];while(!0){let U=this.buf.indexOf(10);if(U>=0)return $.push(this.buf.subarray(0,U)),this.transcript.push(this.buf.subarray(0,U+1)),this.buf=this.buf.subarray(U+1),Hc(LG($));if(this.buf.length>0)$.push(this.buf),this.transcript.push(this.buf);let J=await this.s.read();if(J.done)return this.buf=LG($),null;this.buf=J.value}}close(){return this.s.releaseLock(),{rest:this.buf,transcript:LG(this.transcript)}}}function Hc($){return $.forEach((U)=>{if(U<32||U>126)throw Error("invalid non-ASCII byte in header")}),new TextDecoder().decode($)}function LG($){let U=$.reduce((q,I)=>q+I.length,0),J=new Uint8Array(U),G=0;for(let q of $)J.set(q,G),G+=q.length;return J}function R6($,...U){return $.pipeThrough(new TransformStream({start(J){for(let G of U)J.enqueue(G)}}))}function y9($){return new ReadableStream({start(U){U.enqueue($),U.close()}})}async function xw($){if(!($ instanceof ReadableStream))throw Error("readAll expects a ReadableStream<Uint8Array>");return new Uint8Array(await new Response($).arrayBuffer())}async function qC($){if(!($ instanceof ReadableStream))throw Error("readAllString expects a ReadableStream<Uint8Array>");return await new Response($).text()}async function GC($,U){let J=$.getReader(),G=[],q=0;while(q<U){let{done:X,value:Y}=await J.read();if(X)throw Error("stream ended before reading "+U.toString()+" bytes");G.push(Y),q+=Y.length}J.releaseLock();let I=LG(G),Q=I.subarray(0,U),D=R6($,I.subarray(U));return{data:Q,rest:D}}class DJ{args;body;constructor($,U){this.args=$,this.body=U}}async function Tc($){let U=await $.readLine();if(U===null)throw Error("invalid stanza");let J=U.split(" ");if(J.length<2||J.shift()!=="->")return{next:U};for(let I of J)if(I.length===0)throw Error("invalid stanza");let G=[];for(;;){let I=await $.readLine();if(I===null)throw Error("invalid stanza");let Q=k0.decode(I);if(Q.length>48)throw Error("invalid stanza");if(G.push(Q),Q.length<48)break}let q=LG(G);return{s:new DJ(J,q)}}async function IC($){let U=new kw($),J=await U.readLine();if(J!=="age-encryption.org/v1")throw Error("invalid version "+(J??"line"));let G=[];for(;;){let{s:q,next:I}=await Tc(U);if(q!==void 0){G.push(q);continue}if(!I.startsWith("--- "))throw Error("invalid header");let Q=k0.decode(I.slice(4)),{rest:D,transcript:X}=U.close(),Y=X.slice(0,X.length-1-I.length+3);return{stanzas:G,headerNoMAC:Y,MAC:Q,headerSize:X.length,rest:R6($,D)}}}function fw($){let U=[];U.push(`age-encryption.org/v1
|
|
521
|
+
`);for(let J of $){U.push("-> "+J.args.join(" ")+`
|
|
522
|
+
`);for(let G=0;G<J.body.length;G+=48){let q=G+48;if(q>J.body.length)q=J.body.length;U.push(k0.encode(J.body.subarray(G,q))+`
|
|
523
|
+
`)}if(J.body.length%48===0)U.push(`
|
|
524
|
+
`)}return U.push("---"),new TextEncoder().encode(U.join(""))}function QC($,U){return LG([fw($),new TextEncoder().encode(" "+k0.encode(U)+`
|
|
525
|
+
`)])}function hw(){return DC()}function DC(){let $=TJ(32),U=AU.encodeFromBytes("AGE-SECRET-KEY-",$).toUpperCase();return Promise.resolve(U)}async function h9($){let U;if(YC($))U=$;else if($.startsWith("AGE-SECRET-KEY-PQ-1")){let G=AU.decodeToBytes($);if(G.prefix.toUpperCase()!=="AGE-SECRET-KEY-PQ-"||G.bytes.length!==32)throw Error("invalid identity");let q=S9.getPublicKey(G.bytes);return AU.encode("age1pq",AU.toWords(q),!1)}else{let G=AU.decodeToBytes($);if(!$.startsWith("AGE-SECRET-KEY-1")||G.prefix.toUpperCase()!=="AGE-SECRET-KEY-"||G.bytes.length!==32)throw Error("invalid identity");U=G.bytes}let J=await LI(U);return AU.encodeFromBytes("age",J)}class rw{recipient;constructor($){let U=AU.decodeToBytes($);if(!$.startsWith("age1pq1")||U.prefix.toLowerCase()!=="age1pq"||U.bytes.length!==1216)throw Error("invalid recipient");this.recipient=U.bytes}wrapFileKey($){let{cipherText:U,sharedSecret:J}=S9.encapsulate(this.recipient),G=new TextEncoder().encode("age-encryption.org/mlkem768x25519"),{key:q,nonce:I}=r9(XC,J,G),Q=BU(q,I).encrypt($);return[new DJ(["mlkem768x25519",k0.encode(U)],Q)]}}class lw{identity;constructor($){let U=AU.decodeToBytes($);if(!$.startsWith("AGE-SECRET-KEY-PQ-1")||U.prefix.toUpperCase()!=="AGE-SECRET-KEY-PQ-"||U.bytes.length!==32)throw Error("invalid identity");this.identity=U.bytes}unwrapFileKey($){for(let U of $){if(U.args.length<1||U.args[0]!=="mlkem768x25519")continue;if(U.args.length!==2)throw Error("invalid mlkem768x25519 stanza");let J=k0.decode(U.args[1]);if(J.length!==1120)throw Error("invalid mlkem768x25519 stanza");if(U.body.length!==32)throw Error("invalid mlkem768x25519 stanza");let G=S9.decapsulate(J,this.identity),q=new TextEncoder().encode("age-encryption.org/mlkem768x25519"),{key:I,nonce:Q}=r9(XC,G,q);try{return BU(I,Q).decrypt(U.body)}catch{continue}}return null}}var XC=25722,zc=80,yw=16;function r9($,U,J){let G=Ac($),q=m9(G,void 0,"psk_id_hash",new Uint8Array(0)),I=m9(G,void 0,"info_hash",J),Q=new Uint8Array(1+q.length+I.length);Q[0]=0,Q.set(q,1),Q.set(I,1+q.length);let D=m9(G,U,"secret",new Uint8Array(0)),X=mw(G,D,"key",Q,32),Y=mw(G,D,"base_nonce",Q,12);return{key:X,nonce:Y}}function Ac($){let U=new Uint8Array(10);return U.set(new TextEncoder().encode("HPKE"),0),U[4]=$>>8&255,U[5]=$&255,U[6]=0,U[7]=1,U[8]=0,U[9]=3,U}function m9($,U,J,G){let q=new Uint8Array(7+$.length+J.length+G.length),I=0;return q.set(new TextEncoder().encode("HPKE-v1"),I),I+=7,q.set($,I),I+=$.length,q.set(new TextEncoder().encode(J),I),I+=J.length,q.set(G,I),c4(U0,q,U)}function mw($,U,J,G,q){let I=new Uint8Array(9+$.length+J.length+G.length),Q=0;return I[Q]=q>>8&255,I[Q+1]=q&255,Q+=2,I.set(new TextEncoder().encode("HPKE-v1"),Q),Q+=7,I.set($,Q),Q+=$.length,I.set(new TextEncoder().encode(J),Q),Q+=J.length,I.set(G,Q),K5(U0,U,I,q)}function Kc($){if($.length!==O6.lengths.publicKeyUncompressed)$=O6.Point.fromBytes($).toBytes(!1);let U=O6.utils.randomSecretKey(),J=O6.getPublicKey(U,!1),G=O6.getSharedSecret(U,$,!0).subarray(1),q=new Uint8Array(J.length+$.length);q.set(J,0),q.set($,J.length);let I=new Uint8Array(5);I.set(new TextEncoder().encode("KEM"),0),I[3]=yw>>8,I[4]=yw&255;let Q=m9(I,void 0,"eae_prk",G),D=mw(I,Q,"shared_secret",q,32);return{encapsulatedKey:J,sharedSecret:D}}class iw{recipient;constructor($){let U=AU.decodeToBytes($);if(!$.startsWith("age1tag1")||U.prefix.toLowerCase()!=="age1tag"||U.bytes.length!==33)throw Error("invalid recipient");this.recipient=U.bytes}wrapFileKey($){let{encapsulatedKey:U,sharedSecret:J}=Kc(this.recipient),G=new TextEncoder().encode("age-encryption.org/p256tag"),q=(()=>{let X=U0(this.recipient).subarray(0,4),Y=new Uint8Array(U.length+X.length);return Y.set(U,0),Y.set(X,U.length),c4(U0,Y,G).subarray(0,4)})(),{key:I,nonce:Q}=r9(yw,J,G),D=BU(I,Q).encrypt($);return[new DJ(["p256tag",k0.encode(q),k0.encode(U)],D)]}}class pw{recipient;constructor($){let U=AU.decodeToBytes($);if(!$.startsWith("age1tagpq1")||U.prefix.toLowerCase()!=="age1tagpq"||U.bytes.length!==1249)throw Error("invalid recipient");this.recipient=U.bytes}wrapFileKey($){let{cipherText:U,sharedSecret:J}=HE.encapsulate(this.recipient),G=new TextEncoder().encode("age-encryption.org/mlkem768p256tag"),q=(()=>{let X=U0(this.recipient.subarray(1184)).subarray(0,4),Y=new Uint8Array(U.length+X.length);return Y.set(U,0),Y.set(X,U.length),c4(U0,Y,G).subarray(0,4)})(),{key:I,nonce:Q}=r9(zc,J,G),D=BU(I,Q).encrypt($);return[new DJ(["mlkem768p256tag",k0.encode(q),k0.encode(U)],D)]}}class dw{recipient;constructor($){let U=AU.decodeToBytes($);if(!$.startsWith("age1")||U.prefix.toLowerCase()!=="age"||U.bytes.length!==32)throw Error("invalid recipient");this.recipient=U.bytes}async wrapFileKey($){let U=TJ(32),J=await LI(U),G=await f9(U,this.recipient),q=new Uint8Array(J.length+this.recipient.length);q.set(J),q.set(this.recipient,J.length);let I=new TextEncoder().encode("age-encryption.org/v1/X25519"),Q=Gq(U0,G,q,I,32);return[new DJ(["X25519",k0.encode(J)],ow($,Q))]}}class l9{identity;recipient;constructor($){if(YC($)){this.identity=$,this.recipient=LI($);return}let U=AU.decodeToBytes($);if(!$.startsWith("AGE-SECRET-KEY-1")||U.prefix.toUpperCase()!=="AGE-SECRET-KEY-"||U.bytes.length!==32)throw Error("invalid identity");this.identity=U.bytes,this.recipient=LI(U.bytes)}async unwrapFileKey($){for(let U of $){if(U.args.length<1||U.args[0]!=="X25519")continue;if(U.args.length!==2)throw Error("invalid X25519 stanza");let J=k0.decode(U.args[1]);if(J.length!==32)throw Error("invalid X25519 stanza");let G=await f9(this.identity,J),q=await this.recipient,I=new Uint8Array(J.length+q.length);I.set(J),I.set(q,J.length);let Q=new TextEncoder().encode("age-encryption.org/v1/X25519"),D=Gq(U0,G,I,Q,32),X=aw(U.body,D);if(X!==null)return X}return null}}class nw{passphrase;logN;constructor($,U){this.passphrase=$,this.logN=U}wrapFileKey($){let U=TJ(16),J="age-encryption.org/v1/scrypt",G=new Uint8Array(44);G.set(new TextEncoder().encode("age-encryption.org/v1/scrypt")),G.set(U,28);let q=b5(this.passphrase,G,{N:2**this.logN,r:8,p:1,dkLen:32});return[new DJ(["scrypt",k0.encode(U),this.logN.toString()],ow($,q))]}}class cw{passphrase;constructor($){this.passphrase=$}unwrapFileKey($){for(let U of $){if(U.args.length<1||U.args[0]!=="scrypt")continue;if($.length!==1)throw Error("scrypt recipient is not the only one in the header");if(U.args.length!==3)throw Error("invalid scrypt stanza");if(!/^[1-9][0-9]*$/.test(U.args[2]))throw Error("invalid scrypt stanza");let J=k0.decode(U.args[1]);if(J.length!==16)throw Error("invalid scrypt stanza");let G=Number(U.args[2]);if(G>20)throw Error("scrypt work factor is too high");let q="age-encryption.org/v1/scrypt",I=new Uint8Array(q.length+16);I.set(new TextEncoder().encode(q)),I.set(J,q.length);let Q=b5(this.passphrase,I,{N:2**G,r:8,p:1,dkLen:32}),D=aw(U.body,Q);if(D!==null)return D}return null}}function ow($,U){let J=new Uint8Array(12);return BU(U,J).encrypt($)}function aw($,U){if($.length!==32)throw Error("invalid stanza");let J=new Uint8Array(12);try{return BU(U,J).decrypt($)}catch{return null}}function YC($){return typeof CryptoKey<"u"&&$ instanceof CryptoKey}var EG=16,tw=(()=>65536)(),sw=(()=>tw+EG)();function VC($){let U=new Uint8Array(12),J=()=>{for(let Q=U.length-2;Q>=0;Q--)if(U[Q]++,U[Q]!==0)break},G=!0,q=new Uint8Array(sw),I=0;return new TransformStream({transform(Q,D){while(Q.length>0){if(I===q.length){let Y=BU($,U).decrypt(q);D.enqueue(Y),J(),I=0,G=!1}let X=Math.min(q.length-I,Q.length);q.set(Q.subarray(0,X),I),I+=X,Q=Q.subarray(X)}},flush(Q){U[11]=1;let D=BU($,U).decrypt(q.subarray(0,I));if(!G&&D.length===0)throw Error("final chunk is empty");Q.enqueue(D)}})}function WC($){if($<EG)throw Error("ciphertext is too small");if($===EG)return 0;let U=Math.floor($/sw),J=$%sw;if(0<J&&J<=EG)throw Error("ciphertext size is invalid");let G=$;return G-=U*EG,G-=J>0?EG:0,G}function OC($){let U=new Uint8Array(12),J=()=>{for(let I=U.length-2;I>=0;I--)if(U[I]++,U[I]!==0)break},G=new Uint8Array(tw),q=0;return new TransformStream({transform(I,Q){while(I.length>0){if(q===G.length){let X=BU($,U).encrypt(G);Q.enqueue(X),J(),q=0}let D=Math.min(G.length-q,I.length);G.set(I.subarray(0,D),q),q+=D,I=I.subarray(D)}},flush(I){U[11]=1;let Q=BU($,U).encrypt(G.subarray(0,q));I.enqueue(Q)}})}function ZC($){let U=Math.max(1,Math.ceil($/tw));return $+EG*U}var EI={};UU(EI,{encode:()=>gc,decode:()=>jc});function gc($){let U=[];U.push(`-----BEGIN AGE ENCRYPTED FILE-----
|
|
526
|
+
`);for(let J=0;J<$.length;J+=48){let G=J+48;if(G>$.length)G=$.length;U.push(C5.encode($.subarray(J,G))+`
|
|
527
|
+
`)}return U.push(`-----END AGE ENCRYPTED FILE-----
|
|
528
|
+
`),U.join("")}function jc($){let U=$.trim().replaceAll(`\r
|
|
529
|
+
`,`
|
|
530
|
+
`).split(`
|
|
531
|
+
`);if(U.shift()!=="-----BEGIN AGE ENCRYPTED FILE-----")throw Error("invalid header");if(U.pop()!=="-----END AGE ENCRYPTED FILE-----")throw Error("invalid footer");function J(G,q){if(G===U.length-1)return q.length>0&&q.length<=64&&q.length%4===0;return q.length===64}if(!U.every((G,q)=>J(q,G)))throw Error("invalid line length");if(!U.every((G)=>/^[A-Za-z0-9+/=]+$/.test(G)))throw Error("invalid base64");return C5.decode(U.join(""))}class ew{passphrase=null;scryptWorkFactor=18;recipients=[];setPassphrase($){if(this.passphrase!==null)throw Error("can encrypt to at most one passphrase");if(this.recipients.length!==0)throw Error("can't encrypt to both recipients and passphrases");this.passphrase=$}setScryptWorkFactor($){this.scryptWorkFactor=$}addRecipient($){if(this.passphrase!==null)throw Error("can't encrypt to both recipients and passphrases");if(typeof $==="string")if($.startsWith("age1pq1"))this.recipients.push(new rw($));else if($.startsWith("age1tag1"))this.recipients.push(new iw($));else if($.startsWith("age1tagpq1"))this.recipients.push(new pw($));else if($.startsWith("age1"))this.recipients.push(new dw($));else throw Error("unrecognized recipient type");else this.recipients.push($)}async encrypt($){let U=TJ(16),J=[],G=this.recipients;if(this.passphrase!==null)G=[new nw(this.passphrase,this.scryptWorkFactor)];for(let O of G)J.push(...await O.wrapFileKey(U));let q=new TextEncoder().encode("header"),I=Gq(U0,U,void 0,q,32),Q=eU(U0,I,fw(J)),D=QC(J,Q),X=TJ(16),Y=new TextEncoder().encode("payload"),V=Gq(U0,U,X,Y,32),W=OC(V);if(!($ instanceof ReadableStream)){if(typeof $==="string")$=new TextEncoder().encode($);return await xw(R6(y9($).pipeThrough(W),D,X))}return Object.assign(R6($.pipeThrough(W),D,X),{size:(O)=>ZC(O)+D.length+X.length})}}class $M{identities=[];addPassphrase($){this.identities.push(new cw($))}addIdentity($){if(Lc($))this.identities.push(new l9($));else if(typeof $==="string")if($.startsWith("AGE-SECRET-KEY-1"))this.identities.push(new l9($));else if($.startsWith("AGE-SECRET-KEY-PQ-1"))this.identities.push(new lw($));else throw Error("unrecognized identity type");else this.identities.push($)}async decrypt($,U){let J=$ instanceof ReadableStream?$:y9($),{fileKey:G,headerSize:q,rest:I}=await this.decryptHeaderInternal(J),{data:Q,rest:D}=await GC(I,16),X=new TextEncoder().encode("payload"),Y=Gq(U0,G,Q,X,32),V=VC(Y),W=D.pipeThrough(V),O=Object.assign(W,{size:(Z)=>WC(Z-q-Q.length)});if($ instanceof ReadableStream)return O;if(U==="text")return await qC(W);return await xw(W)}async decryptHeader($){return(await this.decryptHeaderInternal(y9($))).fileKey}async decryptHeaderInternal($){let U=await IC($),J=await this.unwrapFileKey(U.stanzas);if(J===null)throw Error("no identity matched any of the file's recipients");let G=new TextEncoder().encode("header"),q=Gq(U0,J,void 0,G,32),I=eU(U0,q,U.headerNoMAC);if(!Sc(U.MAC,I))throw Error("invalid header HMAC");return{fileKey:J,headerSize:U.headerSize,rest:U.rest}}async unwrapFileKey($){for(let U of this.identities){let J=await U.unwrapFileKey($);if(J!==null)return J}return null}}function Sc($,U){if($.length!==U.length)return!1;let J=0;for(let G=0;G<$.length;G++)J|=$[G]^U[G];return J===0}function Lc($){return typeof CryptoKey<"u"&&$ instanceof CryptoKey}function UM($,U,J){if(J.length===0)return;$(`${U} (${J.length}):`);for(let G of J)$(` - ${G}`)}function i9($,U,J){let G=U.filter((I)=>J(I)),q=U.filter((I)=>!J(I));UM($,"Required before first deploy",G),UM($,"Safe to ignore for now",q)}async function FJ($,U,J={}){let G=J.runCommand??d0;(J.logger??console.log)(`Pushing ${U.length} env-backed secrets to GitHub Secrets...`),await Promise.all(U.map(([I,Q])=>G("gh",["secret","set",I],{stdin:Q})))}function CG($){let U=$?.trim().toLowerCase();if(!U)return;if(U==="gh"||U==="github")return"gh";if(U==="bw"||U==="bitwarden")return"bitwarden";throw Error(`Unsupported --push-to value: ${$}`)}async function GM($,U={}){try{let J=await NC($,U);return{success:!0,message:J.createdLocalKey?`Age key ready at ${J.identityPath}`:`Age key already ready at ${J.identityPath}`}}catch(J){return{success:!1,message:q0(J,"Age key bootstrap failed")}}}async function NC($,U={}){let J=U.logger??console.log,G=RC($,".brains-ops","age","identity.txt"),q=!1,I,Q;if(Ec(G))I=N6(JM(G,"utf8")),Q=await h9(I);else Cc(_c(G),{recursive:!0,mode:448}),I=await hw(),Q=await h9(I),qM(G,Fc(I,Q),{encoding:"utf8",mode:384}),q=!0;vc(RC($,"pilot.yaml"),Q);let D=CG(U.pushTo);if(D)await FJ(D,[["AGE_SECRET_KEY",JM(G,"utf8")]],{logger:J,runCommand:U.runCommand??d0});if(J(q?`Created ${G}`:`Reusing ${G}`),J(`Configured pilot.yaml agePublicKey ${Q}`),D)J(`Pushed AGE_SECRET_KEY to ${D}`);return{createdLocalKey:q,identityPath:G,agePublicKey:Q}}function vc($,U){let J=JM($,"utf8"),G=J.match(/^agePublicKey:\s*(.+)$/m),q=G?.[1]?.trim().replace(/^['"]|['"]$/g,"");if(q===U)return;if(q&&q!=="age1replace-with-your-public-key")throw Error(`pilot.yaml agePublicKey does not match local age identity (${q} !== ${U})`);if(G){qM($,J.replace(/^agePublicKey:\s*.+$/m,`agePublicKey: ${U}`),"utf8");return}let I=J.endsWith(`
|
|
532
|
+
`)?`${J}agePublicKey: ${U}
|
|
533
|
+
`:`${J}
|
|
534
|
+
agePublicKey: ${U}
|
|
535
|
+
`;qM($,I,"utf8")}function N6($){let U=$.split(/\r?\n/).map((J)=>J.trim()).find((J)=>J.startsWith("AGE-SECRET-KEY-"));if(!U)throw Error("Missing AGE-SECRET-KEY in age identity file");return U}function Fc($,U){return["# generated by brains-ops age-key:bootstrap",`# public key: ${U}`,$,""].join(`
|
|
536
|
+
`)}import{mkdir as Jo,writeFile as IM}from"fs/promises";import{dirname as BC,join as QM}from"path";import{createSign as kc,generateKeyPairSync as xc}from"crypto";async function bc($){let U=await $.text();if(!U.trim())return;try{return JSON.parse(U)}catch{return U}}async function w6($,U,J){let G=await bc($),q=U.safeParse(G);if(!$.ok||!q.success){let I=J.formatError??uc;throw Error(`${J.label}${I($,G)}`)}return q.data}function uc($,U){let J=U===void 0?"":`: ${typeof U==="string"?U:JSON.stringify(U)}`;return` (${$.status} ${$.statusText}${J})`}b$();var fc="2.5.4.3",yc="1.2.840.113549.1.1.11",HC="https://api.cloudflare.com/client/v4",mc="origin-rsa",hc=5475,TC=15000;function zC($){return{Authorization:`Bearer ${$}`,"Content-Type":"application/json"}}var wC=N.looseObject({message:N.string().optional()}),rc=N.looseObject({errors:N.array(wC).optional(),messages:N.array(wC).optional()}),lc=N.looseObject({certificate:N.string().min(1),expires_on:N.string().optional()}),ic=N.looseObject({success:N.literal(!0),result:lc}),pc=N.looseObject({success:N.literal(!0)});function AC(){let{privateKey:$,publicKey:U}=xc("rsa",{modulusLength:2048,privateKeyEncoding:{type:"pkcs8",format:"pem"},publicKeyEncoding:{type:"spki",format:"der"}});return{privateKeyPem:$,publicKeyDer:Buffer.from(U)}}function KC($,U){let J=CI(sc(CI(MC(fc),cc($)))),G=CI(nc(0),J,Buffer.from(U.publicKeyDer),tc(0,Buffer.alloc(0))),q=kc("sha256").update(G).sign(U.privateKeyPem),I=CI(G,CI(MC(yc),ac()),oc(q));return{csrPem:dc("CERTIFICATE REQUEST",I),certificationRequestInfoDer:G,signature:q}}async function gC($,U,J,G){let q=await $(`${HC}/certificates`,{method:"POST",headers:zC(U),body:JSON.stringify({hostnames:[G,`*.${G}`],requested_validity:hc,request_type:mc,csr:J}),signal:AbortSignal.timeout(TC)}),I=await w6(q,ic,{label:"Cloudflare Origin CA request failed",formatError:PC}),D={certificatePem:`${I.result.certificate.trim()}
|
|
537
|
+
`};if(I.result.expires_on)D.expiresOn=I.result.expires_on;return D}async function jC($,U,J){let G=await $(`${HC}/zones/${J}/settings/ssl`,{method:"PATCH",headers:zC(U),body:JSON.stringify({value:"strict"}),signal:AbortSignal.timeout(TC)});await w6(G,pc,{label:"Cloudflare zone SSL update failed",formatError:PC})}function dc($,U){let G=U.toString("base64").match(/.{1,64}/g)??[];return[`-----BEGIN ${$}-----`,...G,`-----END ${$}-----`,""].join(`
|
|
538
|
+
`)}function nc($){if($!==0)throw Error("Only zero-valued INTEGER encoding is currently supported");return Buffer.from([2,1,0])}function MC($){let U=$.split(".").map((Q)=>Number(Q));if(U.length<2||U.some((Q)=>Number.isNaN(Q)))throw Error(`Invalid OID: ${$}`);let J=U[0],G=U[1];if(J===void 0||G===void 0)throw Error(`Invalid OID: ${$}`);let I=[J*40+G];for(let Q of U.slice(2)){let D=$o(Q);I.push(...D)}return M6(6,Buffer.from(I))}function cc($){return M6(12,Buffer.from($,"utf8"))}function oc($){return M6(3,Buffer.concat([Buffer.from([0]),$]))}function ac(){return Buffer.from([5,0])}function CI(...$){return M6(48,Buffer.concat($))}function sc(...$){return M6(49,Buffer.concat($))}function tc($,U){return M6(160+$,U)}function M6($,U){return Buffer.concat([Buffer.from([$]),ec(U.length),U])}function ec($){if($<128)return Buffer.from([$]);let U=[],J=$;while(J>0)U.unshift(J&255),J>>=8;return Buffer.from([128|U.length,...U])}function $o($){if(!Number.isInteger($)||$<0)throw Error(`Invalid OID component: ${$}`);if($===0)return[0];let U=[],J=$;while(J>0)U.unshift(J&127),J>>=7;for(let G=0;G<U.length-1;G+=1)U[G]=(U[G]??0)|128;return U}function PC($,U){let J=Uo(U),G=J.length>0?`: ${J.join("; ")}`:"";return` (${$.status} ${$.statusText}${G})`}function Uo($){let U=rc.safeParse($);if(!U.success)return[];return[...U.data.errors??[],...U.data.messages??[]].map((J)=>J.message).filter((J)=>typeof J==="string"&&J.length>0)}RJ();async function DM($,U={}){try{return await LC($,U),{success:!0}}catch(J){return{success:!1,message:q0(J,"Certificate bootstrap failed")}}}async function LC($,U={}){let J=await M0($),G=Go(J,U.handle),q=G.domain,I=U.env??process.env,Q=bU($),D=U.cfApiToken??O0("CF_API_TOKEN",I,Q),X=U.cfZoneId??G.cloudflareZoneId??O0("CF_ZONE_ID",I,Q);if(!D)throw Error("Missing CF_API_TOKEN");if(!X)throw Error("Missing CF_ZONE_ID");let Y=U.fetchImpl??fetch,V=U.logger??console.log,W=AC(),{csrPem:O}=KC(q,W),Z=await gC(Y,D,O,q),M=QM($,".brains-ops","certs",G.id,"origin.pem"),w=QM($,".brains-ops","certs",G.id,"origin.key"),H=QM(BC(M),"secrets.yaml");await Jo(BC(M),{recursive:!0}),await Promise.all([IM(M,Z.certificatePem,"utf-8"),IM(w,W.privateKeyPem,{encoding:"utf-8",mode:384}),IM(H,qo(Z.certificatePem,W.privateKeyPem),"utf-8")]),await jC(Y,D,X);let g=CG(U.pushTo);if(g)await FJ(g,[["CERTIFICATE_PEM",Z.certificatePem],["PRIVATE_KEY_PEM",W.privateKeyPem]],{logger:V,runCommand:U.runCommand??d0});if(V(`Issued ${G.id} Origin CA cert for ${q} and *.${q}`),V(`Wrote ${M}`),V(`Wrote ${w}`),V(`Wrote ${H}`),Z.expiresOn)V(`Expires on ${Z.expiresOn}`);if(V("Cloudflare zone SSL mode set to Full (strict)"),g)V(`Pushed CERTIFICATE_PEM and PRIVATE_KEY_PEM to ${g}`);return{domain:q,certificatePath:M,privateKeyPath:w,certificatePem:Z.certificatePem,secretsSnippetPath:H}}function qo($,U){return[`certificatePem: ${SC($)}`,`privateKeyPem: ${SC(U)}`,""].join(`
|
|
539
|
+
`)}function SC($){return`"${$.replace(/"/g,"\\\"").replace(/\n/g,"\\n")}"`}function Go($,U){if(!U)return{id:"shared",domain:Io($.pilot.domainSuffix)};let J=$.users.find((G)=>G.handle===U);if(!J)throw Error(`Unknown user handle: ${U}`);return{id:U,domain:J.domain,...J.cloudflareZoneId?{cloudflareZoneId:J.cloudflareZoneId}:{}}}function Io($){let U=$.trim().replace(/^\./,"").replace(/\.$/,"");if(!U||U.includes("*"))throw Error(`Invalid pilot domainSuffix: ${$}`);return U}import{lookup as Qo}from"dns/promises";function CC($={}){let U=$.fetchImpl??fetch,J=$.lookupHost??Qo;return async function(q){let I=await Do(q.domain,J),[Q,D,X]=await Promise.all([EC(q.domain,"/health/ready",U),EC(q.domain,"/health/operate",U),Xo(q.domain,U)]);return{dnsStatus:I,serverStatus:Q,deployStatus:D,mcpStatus:X}}}async function Do($,U){try{return(await U($)).address?"ready":"failed"}catch{return"failed"}}async function EC($,U,J){try{return(await _C(J,`https://${$}${U}`,{method:"GET"})).ok?"ready":"failed"}catch{return"failed"}}async function Xo($,U){try{let J=await _C(U,`https://${$}/mcp`,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({jsonrpc:"2.0",id:1,method:"initialize",params:{}})});return J.status===401||J.ok?"ready":"failed"}catch{return"failed"}}async function _C($,U,J){let G=new AbortController,q=setTimeout(()=>G.abort(),5000);try{return await $(U,{...J,signal:G.signal})}finally{clearTimeout(q)}}import{createHash as Yo}from"crypto";import{cp as Vo,lstat as Wo,mkdtemp as Oo,readFile as Zo,readdir as Ro,readlink as No,rm as wo}from"fs/promises";import{tmpdir as Mo}from"os";import{basename as Ho,join as _I,relative as To,resolve as zo,sep as Ao}from"path";var Ko=new Set([".git",".operator",".brains-ops",".turbo","dist","node_modules"]);async function bC($){let U=zo($),J=await Oo(_I(Mo(),"brains-ops-reconcile-")),G=_I(J,"repo");try{await Vo(U,G,{recursive:!0,errorOnExist:!0,force:!1,filter:(D)=>go(U,D)});let q=await XM(G);await vC(G);let I=await XM(G);await vC(G);let Q=await XM(G);return{firstPassChangedFiles:FC(q,I),secondPassChangedFiles:FC(I,Q)}}finally{await wo(J,{recursive:!0,force:!0})}}function go($,U){let J=To($,U);if(J.length===0)return!0;if(J.split(Ao).some((q)=>Ko.has(q)))return!1;if(J===".env"||J===".env.local")return!1;return!Ho(J).endsWith(".secrets.yaml")}async function vC($){await d4($,void 0,{env:{},contentRepoRemoteResolver:()=>{return},fetchImpl:async()=>{throw Error("Dry-run reconcile attempted external HTTP access")},runCommand:async()=>{throw Error("Dry-run reconcile attempted a subprocess")}})}async function XM($){let U=new Map;return await uC($,"",U),U}async function uC($,U,J){let G=_I($,U),q=await Ro(G,{withFileTypes:!0});q.sort((I,Q)=>I.name.localeCompare(Q.name));for(let I of q){let Q=_I(U,I.name),D=_I($,Q);if(I.isDirectory()){await uC($,Q,J);continue}let Y=(await Wo(D)).isSymbolicLink()?`symlink:${await No(D)}`:await Zo(D);J.set(Q,Yo("sha256").update(Y).digest("hex"))}}function FC($,U){return[...new Set([...$.keys(),...U.keys()])].filter((G)=>$.get(G)!==U.get(G)).sort()}L4();import{readFileSync as vI}from"fs";import{access as jo,rm as Po,writeFile as mC}from"fs/promises";import{join as YM,relative as kC}from"path";vq();b$();var hC=N.strictObject({gitSyncToken:N.string().min(1).optional(),discordBotToken:N.string().min(1).optional(),discordPublicKey:N.string().min(1).optional(),discordApplicationId:N.string().min(1).optional(),aiApiKey:N.string().min(1).optional(),atprotoAppPassword:N.string().min(1).optional(),certificatePem:N.string().min(1).optional(),privateKeyPem:N.string().min(1).optional()});async function VM($,U,J={}){let{registry:G,user:q}=await nX($,U),I=J.env??process.env,Q=J.logger??console.log,D=bU($),X=YM($,"users",`${U}.secrets.yaml.age`),Y=YM($,"users",`${U}.secrets.yaml`),V=yC(kC($,X)),W=yC(kC($,Y)),O=Lo(Y),Z=await Eo(X,$,I,D),M=await rC(Y),w={sharedAiApiKeySelector:G.pilot.aiApiKey,sharedGitSyncTokenSelector:G.pilot.gitSyncToken,effectiveAiApiKeySelector:q.effectiveAiApiKey,effectiveGitSyncTokenSelector:q.effectiveGitSyncToken,discordEnabled:q.discordEnabled},H;try{H=Bo($,I,D,O,Z,w)}catch(E){if(!J.dryRun&&O===void 0&&E instanceof Error){let p=vo(w);if(p.length>0)throw await Fo(Y,p),Error(`Missing required secrets for ${U}. Created ${W}; fill it in and rerun secrets:encrypt. ${E.message}`,{cause:E})}throw E}let g=`${pG(H).trimEnd()}
|
|
540
|
+
`;_o(g,H);let P=Object.keys(H);if(J.dryRun){if(Q(`Dry run: would encrypt ${P.length} secrets to ${V}.`),Q(P.length>0?`Keys: ${P.join(", ")}`:"Keys: (none \u2014 shared defaults only)"),M)Q(`Would remove plaintext file ${W}.`);return{encryptedPath:V,plaintextPath:W,deletedPlaintext:M,encryptedKeys:P,dryRun:!0}}let C=new ew;C.addRecipient(G.pilot.agePublicKey);let F=await C.encrypt(g),f=EI.encode(F);if(await mC(X,f),await Po(Y,{force:!0}),Q(`Encrypted ${P.length} secrets to ${V}.`),M)Q(`Removed plaintext file ${W}.`);return{encryptedPath:V,plaintextPath:W,deletedPlaintext:M,encryptedKeys:P}}function Bo($,U,J,G,q,I){let Q=xC($,U,J,G,q,"aiApiKey",I.effectiveAiApiKeySelector,I.sharedAiApiKeySelector),D=xC($,U,J,G,q,"gitSyncToken",I.effectiveGitSyncTokenSelector,I.sharedGitSyncTokenSelector),X=I.discordEnabled?p9($,U,J,G,q,"discordBotToken","DISCORD_BOT_TOKEN"):void 0,Y=I.discordEnabled?p9($,U,J,G,q,"discordPublicKey","DISCORD_PUBLIC_KEY"):void 0,V=I.discordEnabled?p9($,U,J,G,q,"discordApplicationId","DISCORD_APPLICATION_ID"):void 0,W=d9($,U,J,G,q,"atprotoAppPassword","ATPROTO_APP_PASSWORD"),O=fC(d9($,U,J,G,q,"certificatePem","CERTIFICATE_PEM")),Z=fC(d9($,U,J,G,q,"privateKeyPem","PRIVATE_KEY_PEM"));return hC.parse({...Q?{aiApiKey:Q}:{},...D?{gitSyncToken:D}:{},...X?{discordBotToken:X}:{},...Y?{discordPublicKey:Y}:{},...V?{discordApplicationId:V}:{},...W?{atprotoAppPassword:W}:{},...O?{certificatePem:O}:{},...Z?{privateKeyPem:Z}:{}})}function xC($,U,J,G,q,I,Q,D){if(Q===D)return;return p9($,U,J,G,q,I,Q)}function p9($,U,J,G,q,I,Q){let D=d9($,U,J,G,q,I,Q);if(D===void 0||D.trim().length===0)throw Error(`Missing required secret value for ${String(I)}. Set it in users/<handle>.secrets.yaml or fall back to ${Q}/${Q}_FILE before running secrets:encrypt.`);return D}function fC($){return $?.replace(/\r\n?|\n/g,"\\n")}function d9($,U,J,G,q,I,Q){return So(G,q,I,Q,U,J,$)}function So($,U,J,G,q,I,Q){let D=$?.[J];if(D!==void 0&&D.trim().length>0)return D;let X=O0(`${G}_FILE`,q,I);if(X&&X.trim().length>0)return vI(xJ(X,Q),"utf8");let Y=O0(G,q,I);if(Y!==void 0&&Y.trim().length>0)return Y;let V=U?.[J];if(V!==void 0&&V.trim().length>0)return V;return}function Lo($){let U;try{U=vI($,"utf8")}catch{return}try{return WM(U)}catch(J){throw Error(`Unable to parse plaintext secrets file ${$}: ${q0(J)}`,{cause:J})}}async function Eo($,U,J,G){if(!await rC($))return;let q=Co(U,J,G);if(!q)return;let I;try{let Q=vI($,"utf8"),D=EI.decode(Q),X=new $M;X.addIdentity(q),I=await X.decrypt(D,"text")}catch{return}try{return WM(I)}catch(Q){throw Error(`Unable to parse decrypted secrets from ${$}: ${q0(Q)}`,{cause:Q})}}function Co($,U,J){let G=O0("AGE_SECRET_KEY_FILE",U,J);if(G&&G.trim().length>0)return N6(vI(xJ(G,$),"utf8"));let q=O0("AGE_SECRET_KEY",U,J);if(q&&q.trim().length>0)return N6(q);try{return N6(vI(YM($,".brains-ops","age","identity.txt"),"utf8"))}catch{return}}function WM($){let U=rT($),J={};if(U!==null&&typeof U==="object"&&!Array.isArray(U)){for(let[G,q]of Object.entries(U))if(typeof q==="string")J[G]=q}return hC.partial().parse(J)}function _o($,U){let J={...U},G={...WM($)},q=new Set([...Object.keys(J),...Object.keys(G)]);for(let I of q)if(J[I]!==G[I])throw Error(`secrets:encrypt round-trip verification failed for ${I}; refusing to write a corrupted encrypted payload`)}function vo($){return[...$.effectiveAiApiKeySelector!==$.sharedAiApiKeySelector?["aiApiKey"]:[],...$.effectiveGitSyncTokenSelector!==$.sharedGitSyncTokenSelector?["gitSyncToken"]:[],...$.discordEnabled?["discordBotToken","discordPublicKey","discordApplicationId"]:[]]}async function Fo($,U){let J=["# local per-user secret staging file","# fill values, run `bunx brains-ops secrets:encrypt . <handle>`, then the plaintext file will be removed",...U.map((G)=>`${G}: `),""].join(`
|
|
541
|
+
`);await mC($,J,{flag:"wx"})}async function rC($){try{return await jo($),!0}catch{return!1}}function yC($){return $.replaceAll("\\","/")}import{readFileSync as bo}from"fs";async function OM($,U={}){let J=U.env??process.env,G=U.logger??console.log,q=bU($),I=oY(`${$}/.env.schema`),Q=ko(I),D=[],X=[],Y=new Map;for(let W of Q){Y.set(W.key,W.required);let O=xo(W.key,J,q,$);if(O===void 0||O.trim().length===0){X.push(W.key);continue}D.push([W.key,O])}if(D.length===0)throw Error("No pushable local secrets found for this pilot repo");let V=(W)=>Y.get(W)??!1;if(U.dryRun)return G(`Dry run: would push ${D.length} secrets to GitHub Secrets.`),G(`Secrets: ${D.map(([W])=>W).join(", ")}`),i9(G,X,V),{pushedKeys:D.map(([W])=>W),skippedKeys:X,dryRun:!0};return await FJ("gh",D,{logger:G,runCommand:U.runCommand??d0}),i9(G,X,V),{pushedKeys:D.map(([W])=>W),skippedKeys:X}}var uo=new Set(["DISCORD_BOT_TOKEN","DISCORD_PUBLIC_KEY","DISCORD_APPLICATION_ID"]);function ko($){return $.filter((U)=>!uo.has(U.key)).map((U)=>({key:U.key,required:U.required}))}function xo($,U,J,G){let q=O0(`${$}_FILE`,U,J);if(q&&q.trim().length>0)return bo(xJ(q,G),"utf8");let I=O0($,U,J);if(I===void 0||I.trim().length===0)return;return I}b$();import{execFileSync as lC}from"child_process";import{chmodSync as fo,existsSync as yo,mkdirSync as mo,readFileSync as iC,writeFileSync as ho}from"fs";import{dirname as ro,join as lo}from"path";import{homedir as io}from"os";var pC=N.object({id:N.number(),name:N.string(),public_key:N.string()}),po=N.object({ssh_keys:N.array(pC)}),no={createEd25519KeyPair($,U){lC("ssh-keygen",["-t","ed25519","-f",$,"-C",U,"-N",""],{stdio:"ignore"})},derivePublicKey($){return lC("ssh-keygen",["-y","-f",$],{encoding:"utf-8",stdio:["ignore","pipe","inherit"]}).trim()}};async function n9($,U={}){try{let J=await ZM($,U);return{success:!0,message:J.createdLocalKey?`SSH deploy key ready at ${J.privateKeyPath}`:`SSH deploy key already ready at ${J.privateKeyPath}`}}catch(J){return{success:!1,message:q0(J,"SSH key bootstrap failed")}}}async function ZM($,U={}){let J=U.env??process.env,G=bU($),q=U.logger??console.log,I=U.fetchImpl??fetch,Q=U.sshKeygen??no,D=O0("HCLOUD_TOKEN",J,G);if(!D)throw Error("Missing HCLOUD_TOKEN");let X=O0("HCLOUD_SSH_KEY_NAME",J,G);if(!X)throw Error("Missing HCLOUD_SSH_KEY_NAME");let Y=O0("KAMAL_SSH_PRIVATE_KEY_FILE",J,G),V=Y?xJ(Y,$):lo(io(),".ssh",`${oo(X)}_ed25519`),W=`${V}.pub`,O=!1;if(!yo(V))mo(ro(V),{recursive:!0,mode:448}),Q.createEd25519KeyPair(V,X),O=!0;fo(V,384);let Z;if(O)Z=iC(W,"utf-8").trim();else Z=Q.derivePublicKey(V),ho(W,`${Z}
|
|
542
|
+
`,"utf-8");if(Z.length===0)throw Error(`Unable to derive a public key from ${V}`);let M=await co({fetchImpl:I,hcloudToken:D,publicKey:Z,sshKeyName:X}),w=CG(U.pushTo);if(w)await FJ(w,[["KAMAL_SSH_PRIVATE_KEY",iC(V,"utf-8")]],{logger:q,runCommand:U.runCommand??d0});if(q(O?`Created ${V}`:`Reusing ${V}`),q(M?`Registered Hetzner SSH key ${X}`:`Hetzner SSH key ${X} already exists`),w)q(`Pushed KAMAL_SSH_PRIVATE_KEY to ${w}`);return{createdHetznerKey:M,createdLocalKey:O,privateKeyPath:V,publicKeyPath:W,sshKeyName:X}}async function co($){let U=new URL("https://api.hetzner.cloud/v1/ssh_keys");U.searchParams.set("name",$.sshKeyName);let J=await $.fetchImpl(U.toString(),{headers:{Authorization:`Bearer ${$.hcloudToken}`,"Content-Type":"application/json"}}),{ssh_keys:G}=await w6(J,po,{label:"Hetzner SSH key lookup failed"}),[q]=G;if(q){if(q.public_key.trim()!==$.publicKey)throw Error(`Existing Hetzner SSH key ${$.sshKeyName} does not match the local public key`);return!1}let I=await $.fetchImpl("https://api.hetzner.cloud/v1/ssh_keys",{method:"POST",headers:{Authorization:`Bearer ${$.hcloudToken}`,"Content-Type":"application/json"},body:JSON.stringify({name:$.sshKeyName,public_key:$.publicKey})});return await w6(I,N.object({ssh_key:pC}),{label:"Hetzner SSH key create failed"}),!0}function oo($){return $.replace(/[^A-Za-z0-9._-]+/g,"_")}b$();RJ();var ao=N.looseObject({status:N.string(),operationalStatus:N.string(),checks:N.array(N.looseObject({name:N.string(),status:N.string(),message:N.string().optional()})).default([]),app:N.looseObject({daemons:N.array(N.looseObject({name:N.string().optional(),status:N.string().optional(),health:N.looseObject({status:N.string().optional(),message:N.string().optional()}).optional()})).default([])}).default({daemons:[]})});async function RM($,U,J={}){let G=J.fetchImpl??fetch,I=(await M0($)).users.find((O)=>O.handle===U);if(!I)throw Error(`Unknown pilot user: ${U}`);let Q=`https://${I.domain}`,D=[],X=[],Y=N.number().int().positive().max(30).parse(J.operationalRetryAttempts??6),V=N.number().int().nonnegative().max(60000).parse(J.operationalRetryDelayMs??1e4),W=J.sleep??((O)=>new Promise((Z)=>setTimeout(Z,O)));if(await c9("health",()=>so(G,Q,Y,V,W),D,X),await c9("mcp-auth-gate",()=>$a(G,Q),D,X),I.bundles.includes("site"))await c9("site",()=>dC(G,`${Q}/`,"site"),D,X),await c9("cms",()=>dC(G,`${Q}/cms`,"cms"),D,X),J.logger?.("WARN Manual check still required: passkey setup/handoff completed from the setup email.");return{handle:I.handle,bundles:I.bundles,domain:I.domain,contentRepo:I.contentRepo,checks:D,failedChecks:X}}async function c9($,U,J,G){try{await U(),J.push($)}catch(q){G.push({name:$,message:q0(q)})}}async function so($,U,J,G,q){let I;for(let Q=1;Q<=J;Q++)try{await to($,U);return}catch(D){if(I=D,Q<J)await q(G)}throw I}async function to($,U){let G=await NM($,`${U}/health/operate`,{method:"GET"}),q=await G.json().catch(()=>null),I=ao.safeParse(q);if(!G.ok){let D=I.success?I.data.checks.filter((X)=>X.status!=="healthy").slice(0,10).map((X)=>`${X.name}: ${eo(X.message??X.status)}`):[];throw Error(`/health/operate returned ${G.status}, expected 200${D.length>0?` (${D.join("; ")})`:""}`)}if(!I.success)throw Error(`/health/operate response did not match expected shape: ${I.error.message}`);let Q=I.data;if(Q.status!=="ready")throw Error(`/health/operate status is ${Q.status}, expected ready`);if(Q.operationalStatus!=="operational")throw Error(`/health/operate operationalStatus is ${Q.operationalStatus}, expected operational`);for(let D of Q.app.daemons){let X=D.status??"unknown",Y=D.health?.status;if(X==="error"||Y==="unhealthy")throw Error(`daemon ${D.name??"unknown"} is unhealthy (${X}/${Y??"unknown"})`)}}function eo($){let U=$.replaceAll(/\s+/g," ").trim();return U.length<=300?U:`${U.slice(0,297)}...`}async function $a($,U){let J=await NM($,`${U}/mcp`,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({jsonrpc:"2.0",id:1,method:"initialize"})});if(J.status<400||J.status>=500)throw Error(`unauthenticated POST /mcp returned ${J.status}, expected a 4xx auth failure`)}async function dC($,U,J){let G=await NM($,U,{method:"GET"});if(G.status>=400)throw Error(`${J} ${U} returned ${G.status}, expected < 400`)}async function NM($,U,J){let G=new AbortController,q=setTimeout(()=>G.abort(),20000);try{return await $(U,{...J,redirect:"follow",signal:G.signal})}finally{clearTimeout(q)}}var mv="brains-ops",hH={type:"string",placeholder:"<target>",description:"Push target (`gh` or `github`)"},rH={type:"boolean",description:"Show what would happen without writing anything"};function L0($){return{success:!1,message:X2(mv,$)}}var hv=I0({name:"init",usage:"<repo>",description:"Create a pilot repo skeleton",run:async({args:$})=>{let U=$[0];if(!U)return L0(hv);return await f7(U),{success:!0,message:`Initialized ${U}`}}}),rv=I0({name:"upgrade",usage:"<repo>",description:"Bump @rizom/ops and refresh the generated scaffold",flags:{to:{type:"string",placeholder:"<version>",description:"Explicit @rizom/ops version (`latest` by default)"}},run:async({args:$,flags:U})=>{let J=$[0];if(!J)return L0(rv);let G=a0(U,"to"),{upgradePilotRepo:q}=await Promise.resolve().then(() => (oC(),cC)),{from:I,to:Q}=await q(J,{...G&&G!=="latest"?{version:G}:{}});return{success:!0,message:I===Q?`Already at @rizom/ops@${Q}; scaffold refreshed`:`Upgraded @rizom/ops ${I} -> ${Q}; scaffold refreshed`}}}),lv=I0({name:"crossover:stage",usage:"<source-repo> <output-dir> [site-pins.yaml]",description:"Stage a reviewed canonical crossover copy",run:async({args:$})=>{let U=$[0],J=$[1],G=$[2];if(!U||!J)return L0(lv);let{loadReviewedSitePins:q,stageLegacyCrossover:I}=await Promise.resolve().then(() => (Tv(),Hv)),Q=G?await q(G):void 0,D=await I(U,J,{sitePins:Q});return{success:!0,message:`Staged ${D.changedFiles.length} reviewed crossover files in ${D.outputDir}`}}}),iv=I0({name:"render",usage:"<repo>",description:"Render the observed users table to views/users.md",run:async({args:$},U)=>{let J=$[0];if(!J)return L0(iv);let G=U.resolveStatus??CC({...U.fetchImpl?{fetchImpl:U.fetchImpl}:{},...U.lookupHost?{lookupHost:U.lookupHost}:{}});return await dq(J,{resolveStatus:G}),{success:!0,message:`Rendered ${J}/views/users.md`}}}),pv=I0({name:"user:add",usage:"<repo> <handle> --cohort <cohort>",description:"Add a user to a cohort",flags:{cohort:{type:"string",placeholder:"<cohort>",description:"Cohort the user joins"},"anchor-id":{type:"string",placeholder:"<id>",description:"Discord anchor user id stored on the user record"}},run:async({args:$,flags:U})=>{let J=$[0],G=$[1],q=a0(U,"cohort");if(!J||!G||!q)return L0(pv);let I=a0(U,"anchor-id");return await O5(J,G,{cohort:q,...I?{anchorId:I}:{}}),{success:!0,message:`Added ${G} to ${q}`}}}),dv=I0({name:"onboard",usage:"<repo> <handle>",description:"Generate a user's brain.yaml and .env",run:async({args:$},U)=>{let J=$[0],G=$[1];if(!J||!G)return L0(dv);return await W5(J,G,U.runner,{...U.env?{env:U.env}:{}}),{success:!0,message:`Onboarded ${G}`}}}),nv=I0({name:"age-key:bootstrap",usage:"<repo>",description:"Generate the pilot age key and optional GitHub secret",flags:{"push-to":hH},run:async({args:$,flags:U},J)=>{let G=$[0];if(!G)return L0(nv);let q=a0(U,"push-to");return GM(G,{...J.logger?{logger:J.logger}:{},...q?{pushTo:q}:{},...J.bootstrapRunCommand?{runCommand:J.bootstrapRunCommand}:{}})}}),cv=I0({name:"ssh-key:bootstrap",usage:"<repo>",description:"Bootstrap a deploy SSH key and optional GitHub secret",flags:{"push-to":hH},run:async({args:$,flags:U},J)=>{let G=$[0];if(!G)return L0(cv);let q=a0(U,"push-to");return n9(G,{...J.env?{env:J.env}:{},...J.fetchImpl?{fetchImpl:J.fetchImpl}:{},...J.logger?{logger:J.logger}:{},...q?{pushTo:q}:{},...J.bootstrapRunCommand?{runCommand:J.bootstrapRunCommand}:{},...J.sshKeygen?{sshKeygen:J.sshKeygen}:{}})}}),ov=I0({name:"cert:bootstrap",usage:"<repo>",description:"Issue Cloudflare Origin CA certificates for pilot users",flags:{handle:{type:"string",placeholder:"<handle>",description:"Only issue the certificate for this user handle"},"push-to":hH},run:async({args:$,flags:U},J)=>{let G=$[0];if(!G)return L0(ov);let q=a0(U,"handle"),I=a0(U,"push-to");return DM(G,{...J.env?{env:J.env}:{},...J.fetchImpl?{fetchImpl:J.fetchImpl}:{},...J.logger?{logger:J.logger}:{},...q?{handle:q}:{},...I?{pushTo:I}:{},...J.bootstrapRunCommand?{runCommand:J.bootstrapRunCommand}:{}})}}),av=I0({name:"secrets:push",usage:"<repo>",description:"Push env-backed local secrets to GitHub Secrets",flags:{"dry-run":rH},run:async({args:$,flags:U},J)=>{let G=$[0];if(!G)return L0(av);let q=await OM(G,{env:J.env,logger:J.logger,dryRun:cX(U,"dry-run")});return{success:!0,message:q.dryRun?`Dry run: would push ${q.pushedKeys.length} secrets`:`Pushed ${q.pushedKeys.length} secrets`}}}),sv=I0({name:"secrets:encrypt",usage:"<repo> <handle>",description:"Encrypt pilot secrets for a user with age",flags:{"dry-run":rH},run:async({args:$,flags:U},J)=>{let G=$[0],q=$[1];if(!G||!q)return L0(sv);let I=await VM(G,q,{env:J.env,logger:J.logger,dryRun:cX(U,"dry-run")});return{success:!0,message:I.dryRun?`Dry run: would encrypt ${I.encryptedKeys.length} secrets for ${q}`:`Encrypted ${I.encryptedKeys.length} secrets for ${q}`}}}),tv=I0({name:"stress:directory-sync",usage:"<repo> <handle> --profile <regression|load|stress> --confirm stress:<handle> [--artifacts-dir <path>]",description:"Run a smoke-only directory-sync stress profile",flags:{profile:{type:"string",placeholder:"<profile>",description:"Stress profile (`regression`, `load`, or `stress`)"},confirm:{type:"string",placeholder:"stress:<handle>",description:"Explicit smoke target confirmation"},"artifacts-dir":{type:"string",placeholder:"<path>",description:"Directory for JSON, Markdown, samples, and logs"}},run:async({args:$,flags:U},J)=>{let G=$[0],q=$[1],I=a0(U,"profile"),Q=a0(U,"confirm");if(!G||!q||!Q||I!=="regression"&&I!=="load"&&I!=="stress")return L0(tv);let D=J.directorySyncStressRunner??(await Promise.resolve().then(() => (OQ(),iY))).runDeployedDirectorySyncStress,X=a0(U,"artifacts-dir"),Y=await D({rootDir:G,handle:q,profile:I,confirmation:Q,...X?{artifactsDir:X}:{},...J.env?{env:J.env}:{},...J.fetchImpl?{fetchImpl:J.fetchImpl}:{},...J.logger?{logger:J.logger}:{}});return{success:Y.report.success,message:`${Y.report.success?"Passed":"Failed"} ${I} directory-sync stress for ${q}; artifacts: ${Y.artifactsDir}`}}}),ev=I0({name:"stress:directory-sync:verify-access",usage:"<repo> <handle> --confirm stress:<handle> [--artifacts-dir <path>]",description:"Verify smoke stress credentials without remote writes",flags:{confirm:{type:"string",placeholder:"stress:<handle>",description:"Explicit smoke target confirmation"},"artifacts-dir":{type:"string",placeholder:"<path>",description:"Directory for the access-check result"}},run:async({args:$,flags:U},J)=>{let G=$[0],q=$[1],I=a0(U,"confirm");if(!G||!q||!I)return L0(ev);let Q=J.directorySyncStressAccessRunner??(await Promise.resolve().then(() => (OQ(),iY))).verifyDirectorySyncStressAccess,D=a0(U,"artifacts-dir"),X=await Q({rootDir:G,handle:q,confirmation:I,...D?{artifactsDir:D}:{},...J.env?{env:J.env}:{}});return{success:X.success,message:`Verified directory-sync stress access for ${q} at ${X.remoteHead}; artifacts: ${X.artifactsDir}`}}}),$F=I0({name:"stress:directory-sync:cleanup",usage:"<repo> <handle> --confirm stress:<handle> [--artifacts-dir <path>]",description:"Remove residual smoke directory-sync stress probes",flags:{confirm:{type:"string",placeholder:"stress:<handle>",description:"Explicit smoke target confirmation"},"artifacts-dir":{type:"string",placeholder:"<path>",description:"Directory for the cleanup result"}},run:async({args:$,flags:U},J)=>{let G=$[0],q=$[1],I=a0(U,"confirm");if(!G||!q||!I)return L0($F);let Q=J.directorySyncStressCleanupRunner??(await Promise.resolve().then(() => (OQ(),iY))).cleanupDirectorySyncStress,D=a0(U,"artifacts-dir"),X=await Q({rootDir:G,handle:q,confirmation:I,...D?{artifactsDir:D}:{},...J.env?{env:J.env}:{},...J.logger?{logger:J.logger}:{}});return{success:X.success,message:`${X.success?"Cleaned":"Failed to clean"} directory-sync stress probes for ${q}; removed ${X.probesRemoved}, remaining ${X.probesRemaining}`}}}),UF=I0({name:"verify-user",usage:"<repo> <handle>",description:"Probe a deployed user's endpoints",run:async({args:$},U)=>{let J=$[0],G=$[1];if(!J||!G)return L0(UF);let q=await RM(J,G,{...U.fetchImpl?{fetchImpl:U.fetchImpl}:{},...U.logger?{logger:U.logger}:{},...U.verificationRetryAttempts!==void 0?{operationalRetryAttempts:U.verificationRetryAttempts}:{},...U.verificationRetryDelayMs!==void 0?{operationalRetryDelayMs:U.verificationRetryDelayMs}:{},...U.sleep?{sleep:U.sleep}:{}}),I=q.checks.length>0?q.checks.join(", "):"none";if(q.failedChecks.length>0){let Q=q.failedChecks.map((D)=>` ${D.name}: ${D.message}`).join(`
|
|
543
|
+
`);return{success:!1,message:`Verified ${q.handle} (${q.bundles.join(",")}) at https://${q.domain}: passed ${I}; failed:
|
|
544
|
+
${Q}`}}return{success:!0,message:`Verified ${q.handle} (${q.bundles.join(",")}) at https://${q.domain}: ${I}`}}}),JF=I0({name:"reconcile-cohort",usage:"<repo> <cohort>",description:"Reconcile all users in a cohort",run:async({args:$},U)=>{let J=$[0],G=$[1];if(!J||!G)return L0(JF);return await Z5(J,G,U.runner,{...U.env?{env:U.env}:{}}),{success:!0,message:`Reconciled cohort ${G}`}}});function yv($,U){return[$,...U.length===0?["- (none)"]:U.map((J)=>`- ${J}`)]}var qF=I0({name:"reconcile-all",usage:"<repo> [--dry-run]",description:"Reconcile every cohort",flags:{"dry-run":rH},run:async({args:$,flags:U},J)=>{let G=$[0];if(!G)return L0(qF);if(cX(U,"dry-run")){let q=await bC(G),I=q.firstPassChangedFiles.length,Q=q.secondPassChangedFiles.length;return{success:Q===0,message:[`Dry-run reconcile found ${I} first-pass changed file(s); second pass ${Q===0?"converged with zero drift":`still changed ${Q} file(s)`}`,...yv("First-pass changed files:",q.firstPassChangedFiles),...yv("Second-pass changed files:",q.secondPassChangedFiles)].join(`
|
|
545
|
+
`)}}return await d4(G,J.runner,{...J.env?{env:J.env}:{}}),{success:!0,message:"Reconciled all cohorts"}}}),CG$=I0({name:"help",description:"Show this help message",run:()=>({success:!0,message:Y2({cliName:mv,intro:"brains-ops \u2014 operator CLI for private brain fleet repos",commands:pY,globalFlags:lH})})}),_G$=I0({name:"version",description:"Show version",run:()=>({success:!0,message:`brains-ops ${ZQ.version}`})}),lH={help:{type:"boolean",short:"h",description:"Show help"},version:{type:"boolean",short:"v",description:"Show version"}},pY=[hv,rv,lv,iv,pv,dv,nv,cv,ov,av,sv,tv,ev,$F,UF,JF,qF,CG$,_G$],vG$=V2(pY);async function FG$($,U={}){let J=vG$.get($.command);if(!J)return{success:!1,message:`Unknown command: ${$.command}`};return J.run({args:$.args,flags:$.flags},U)}function bG$($){return I2($,{commands:pY,globalFlags:lH})}rY();OQ();P8();export{dq as writeUsersTable,RM as verifyPilotUser,Fv as verifyDirectorySyncStressAccess,Bv as stressMetricsFailure,Qg as sitePackagesFor,y7 as siteImageTag,hY as sampleStressHealth,wx as runResolveMissingImages,n9 as runPilotSshKeyBootstrap,DM as runPilotCertBootstrap,GM as runPilotAgeKeyBootstrap,_H as runDirectorySyncStressPlan,vv as runDeployedDirectorySyncStress,FG$ as runCommand,Xg as resolveImageBuilds,CH as resolveDirectorySyncStressPlan,Dg as requiredImages,Z5 as reconcileCohort,d4 as reconcileAll,OM as pushPilotSecrets,j8 as pilotSchema,bG$ as parseArgs,W5 as onboardUser,M0 as loadPilotRegistry,f7 as initPilotRepo,N6 as extractAgeIdentity,VM as encryptPilotSecrets,Pv as directorySyncStressReportSchema,IQ as directorySyncStressProfileSchema,QQ as directorySyncStressPlanSchema,qp as derivePreviewDomain,cJ as cohortSchema,bv as cleanupDirectorySyncStress,aK as canonicalBundleIdSchema,ZM as bootstrapPilotSshKey,LC as bootstrapPilotOriginCertificate,NC as bootstrapPilotAgeKey,DQ as assertDirectorySyncStressTarget,O5 as addPilotUser};
|