obsidian-tc 1.3.3 → 1.3.4

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 CHANGED
@@ -9,7 +9,7 @@ See the [repo root README](../../README.md) for project overview and the
9
9
 
10
10
  ## Status
11
11
 
12
- ✅ **Shipped — v1.0.2.** The full tool surface (105 tools across 28 domains, milestones
12
+ ✅ **Shipped — v1.3.4.** The full tool surface (105 tools across 28 domains, milestones
13
13
  M0–M7) is implemented and released. Built on Bun + Hono with Zod 4 schemas; runs under
14
14
  Node `>=24` (the test suite runs vitest under Node for `node:sqlite`).
15
15
 
package/dist/cli.js CHANGED
@@ -166,7 +166,7 @@ ${J.comment}`:J.comment}this.doc.range[2]=J.offset;break}default:this.errors.pus
166
166
  `)+1;while(J!==0)this.onNewLine(this.offset+J),J=this.source.indexOf(`
167
167
  `,J)+1}yield*this.pop();break;default:yield*this.pop(),yield*this.step()}}*blockMap($){let J=$.items[$.items.length-1];switch(this.type){case"newline":if(this.onKeyLine=!1,J.value){let W="end"in J.value?J.value.end:void 0;if((Array.isArray(W)?W[W.length-1]:void 0)?.type==="comment")W?.push(this.sourceToken);else $.items.push({start:[this.sourceToken]})}else if(J.sep)J.sep.push(this.sourceToken);else J.start.push(this.sourceToken);return;case"space":case"comment":if(J.value)$.items.push({start:[this.sourceToken]});else if(J.sep)J.sep.push(this.sourceToken);else{if(this.atIndentedComment(J.start,$.indent)){let Q=$.items[$.items.length-2]?.value?.end;if(Array.isArray(Q)){eK(Q,J.start),Q.push(this.sourceToken),$.items.pop();return}}J.start.push(this.sourceToken)}return}if(this.indent>=$.indent){let W=!this.onKeyLine&&this.indent===$.indent,Q=W&&(J.sep||J.explicitKey)&&this.type!=="seq-item-ind",X=[];if(Q&&J.sep&&!J.value){let Y=[];for(let U=0;U<J.sep.length;++U){let G=J.sep[U];switch(G.type){case"newline":Y.push(U);break;case"space":break;case"comment":if(G.indent>$.indent)Y.length=0;break;default:Y.length=0}}if(Y.length>=2)X=J.sep.splice(Y[1])}switch(this.type){case"anchor":case"tag":if(Q||J.value)X.push(this.sourceToken),$.items.push({start:X}),this.onKeyLine=!0;else if(J.sep)J.sep.push(this.sourceToken);else J.start.push(this.sourceToken);return;case"explicit-key-ind":if(!J.sep&&!J.explicitKey)J.start.push(this.sourceToken),J.explicitKey=!0;else if(Q||J.value)X.push(this.sourceToken),$.items.push({start:X,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(J.explicitKey)if(!J.sep)if(d0(J.start,"newline"))Object.assign(J,{key:null,sep:[this.sourceToken]});else{let Y=OW(J.start);this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:Y,key:null,sep:[this.sourceToken]}]})}else if(J.value)$.items.push({start:[],key:null,sep:[this.sourceToken]});else if(d0(J.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:X,key:null,sep:[this.sourceToken]}]});else if(BQ$(J.key)&&!d0(J.sep,"newline")){let Y=OW(J.start),U=J.key,G=J.sep;G.push(this.sourceToken),delete J.key,delete J.sep,this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:Y,key:U,sep:G}]})}else if(X.length>0)J.sep=J.sep.concat(X,this.sourceToken);else J.sep.push(this.sourceToken);else if(!J.sep)Object.assign(J,{key:null,sep:[this.sourceToken]});else if(J.value||Q)$.items.push({start:X,key:null,sep:[this.sourceToken]});else if(d0(J.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[],key:null,sep:[this.sourceToken]}]});else J.sep.push(this.sourceToken);this.onKeyLine=!0;return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{let Y=this.flowScalar(this.type);if(Q||J.value)$.items.push({start:X,key:Y,sep:[]}),this.onKeyLine=!0;else if(J.sep)this.stack.push(Y);else Object.assign(J,{key:Y,sep:[]}),this.onKeyLine=!0;return}default:{let Y=this.startBlockValue($);if(Y){if(Y.type==="block-seq"){if(!J.explicitKey&&J.sep&&!d0(J.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(W)$.items.push({start:X});this.stack.push(Y);return}}}}yield*this.pop(),yield*this.step()}*blockSequence($){let J=$.items[$.items.length-1];switch(this.type){case"newline":if(J.value){let W="end"in J.value?J.value.end:void 0;if((Array.isArray(W)?W[W.length-1]:void 0)?.type==="comment")W?.push(this.sourceToken);else $.items.push({start:[this.sourceToken]})}else J.start.push(this.sourceToken);return;case"space":case"comment":if(J.value)$.items.push({start:[this.sourceToken]});else{if(this.atIndentedComment(J.start,$.indent)){let Q=$.items[$.items.length-2]?.value?.end;if(Array.isArray(Q)){eK(Q,J.start),Q.push(this.sourceToken),$.items.pop();return}}J.start.push(this.sourceToken)}return;case"anchor":case"tag":if(J.value||this.indent<=$.indent)break;J.start.push(this.sourceToken);return;case"seq-item-ind":if(this.indent!==$.indent)break;if(J.value||d0(J.start,"seq-item-ind"))$.items.push({start:[this.sourceToken]});else J.start.push(this.sourceToken);return}if(this.indent>$.indent){let W=this.startBlockValue($);if(W){this.stack.push(W);return}}yield*this.pop(),yield*this.step()}*flowCollection($){let J=$.items[$.items.length-1];if(this.type==="flow-error-end"){let W;do yield*this.pop(),W=this.peek(1);while(W?.type==="flow-collection")}else if($.end.length===0){switch(this.type){case"comma":case"explicit-key-ind":if(!J||J.sep)$.items.push({start:[this.sourceToken]});else J.start.push(this.sourceToken);return;case"map-value-ind":if(!J||J.value)$.items.push({start:[],key:null,sep:[this.sourceToken]});else if(J.sep)J.sep.push(this.sourceToken);else Object.assign(J,{key:null,sep:[this.sourceToken]});return;case"space":case"comment":case"newline":case"anchor":case"tag":if(!J||J.value)$.items.push({start:[this.sourceToken]});else if(J.sep)J.sep.push(this.sourceToken);else J.start.push(this.sourceToken);return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{let Q=this.flowScalar(this.type);if(!J||J.value)$.items.push({start:[],key:Q,sep:[]});else if(J.sep)this.stack.push(Q);else Object.assign(J,{key:Q,sep:[]});return}case"flow-map-end":case"flow-seq-end":$.end.push(this.sourceToken);return}let W=this.startBlockValue($);if(W)this.stack.push(W);else yield*this.pop(),yield*this.step()}else{let W=this.peek(2);if(W.type==="block-map"&&(this.type==="map-value-ind"&&W.indent===$.indent||this.type==="newline"&&!W.items[W.items.length-1].sep))yield*this.pop(),yield*this.step();else if(this.type==="map-value-ind"&&W.type!=="flow-collection"){let Q=sK(W),X=OW(Q);ZQ$($);let Y=$.end.splice(1,$.end.length);Y.push(this.sourceToken);let U={type:"block-map",offset:$.offset,indent:$.indent,items:[{start:X,key:$,sep:Y}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=U}else yield*this.lineEnd($)}}flowScalar($){if(this.onNewLine){let J=this.source.indexOf(`
168
168
  `)+1;while(J!==0)this.onNewLine(this.offset+J),J=this.source.indexOf(`
169
- `,J)+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 J=sK($),W=OW(J);return W.push(this.sourceToken),{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:W,explicitKey:!0}]}}case"map-value-ind":{this.onKeyLine=!0;let J=sK($),W=OW(J);return{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:W,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment($,J){if(this.type!=="comment")return!1;if(this.indent<=J)return!1;return $.every((W)=>W.type==="newline"||W.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()}}}OJ6.Parser=DQ$});var IQ$=z((MJ6)=>{var FQ$=EM(),IJ6=kQ(),gQ=bQ(),zJ6=fL(),jJ6=P$(),NJ6=fM(),HQ$=yM();function OQ$($){let J=$.prettyErrors!==!1;return{lineCounter:$.lineCounter||J&&new NJ6.LineCounter||null,prettyErrors:J}}function VJ6($,J={}){let{lineCounter:W,prettyErrors:Q}=OQ$(J),X=new HQ$.Parser(W?.addNewLine),Y=new FQ$.Composer(J),U=Array.from(Y.compose(X.parse($)));if(Q&&W)for(let G of U)G.errors.forEach(gQ.prettifyError($,W)),G.warnings.forEach(gQ.prettifyError($,W));if(U.length>0)return U;return Object.assign([],{empty:!0},Y.streamInfo())}function qQ$($,J={}){let{lineCounter:W,prettyErrors:Q}=OQ$(J),X=new HQ$.Parser(W?.addNewLine),Y=new FQ$.Composer(J),U=null;for(let G of Y.compose(X.parse($),!0,$.length))if(!U)U=G;else if(U.options.logLevel!=="silent"){U.errors.push(new gQ.YAMLParseError(G.range.slice(0,2),"MULTIPLE_DOCS","Source contains multiple documents; please use YAML.parseAllDocuments()"));break}if(Q&&W)U.errors.forEach(gQ.prettifyError($,W)),U.warnings.forEach(gQ.prettifyError($,W));return U}function AJ6($,J,W){let Q=void 0;if(typeof J==="function")Q=J;else if(W===void 0&&J&&typeof J==="object")W=J;let X=qQ$($,W);if(!X)return null;if(X.warnings.forEach((Y)=>zJ6.warn(X.options.logLevel,Y)),X.errors.length>0)if(X.options.logLevel!=="silent")throw X.errors[0];else X.errors=[];return X.toJS(Object.assign({reviver:Q},W))}function LJ6($,J,W){let Q=null;if(typeof J==="function"||Array.isArray(J))Q=J;else if(W===void 0&&J)W=J;if(typeof W==="string")W=W.length;if(typeof W==="number"){let X=Math.round(W);W=X<1?void 0:X>8?{indent:8}:{indent:X}}if($===void 0){let{keepUndefined:X}=W??J??{};if(!X)return}if(jJ6.isDocument($)&&!Q)return $.toString(W);return new IJ6.Document($,Q,W).toString(W)}MJ6.parse=AJ6;MJ6.parseAllDocuments=VJ6;MJ6.parseDocument=qQ$;MJ6.stringify=LJ6});var gM=z((uJ6)=>{var RJ6=EM(),wJ6=kQ(),CJ6=ZM(),xM=bQ(),_J6=jQ(),p0=P$(),kJ6=u0(),bJ6=U6(),vJ6=c0(),fJ6=l0(),yJ6=aK(),xJ6=vM(),gJ6=fM(),hJ6=yM(),$Z=IQ$(),zQ$=IQ();uJ6.Composer=RJ6.Composer;uJ6.Document=wJ6.Document;uJ6.Schema=CJ6.Schema;uJ6.YAMLError=xM.YAMLError;uJ6.YAMLParseError=xM.YAMLParseError;uJ6.YAMLWarning=xM.YAMLWarning;uJ6.Alias=_J6.Alias;uJ6.isAlias=p0.isAlias;uJ6.isCollection=p0.isCollection;uJ6.isDocument=p0.isDocument;uJ6.isMap=p0.isMap;uJ6.isNode=p0.isNode;uJ6.isPair=p0.isPair;uJ6.isScalar=p0.isScalar;uJ6.isSeq=p0.isSeq;uJ6.Pair=kJ6.Pair;uJ6.Scalar=bJ6.Scalar;uJ6.YAMLMap=vJ6.YAMLMap;uJ6.YAMLSeq=fJ6.YAMLSeq;uJ6.CST=yJ6;uJ6.Lexer=xJ6.Lexer;uJ6.LineCounter=gJ6.LineCounter;uJ6.Parser=hJ6.Parser;uJ6.parse=$Z.parse;uJ6.parseAllDocuments=$Z.parseAllDocuments;uJ6.parseDocument=$Z.parseDocument;uJ6.stringify=$Z.stringify;uJ6.visit=zQ$.visit;uJ6.visitAsync=zQ$.visitAsync});import{mkdirSync as JX6,readFileSync as CW}from"node:fs";import{join as WX6}from"node:path";import{fileURLToPath as F8}from"node:url";var H4="1.3.3";var F2=String.fromCharCode(0),H2=process.platform==="win32"||process.platform==="darwin";function aU$($,J=H2){let W=$.replace(/\*\*/g,F2),Q="";for(let X of W)if(X===F2)Q+=".*";else if(X==="*")Q+="[^/]*";else if(X==="?")Q+="[^/]";else Q+=X.replace(/[.+^${}()|[\]\\]/g,"\\$&");return new RegExp(`^${Q}$`,J?"i":"")}function E$($,J,W=H2){return aU$($.normalize("NFC"),W).test(J.normalize("NFC"))}var tU$=[".obsidian",".git",".trash"],sU$=new Set([".obsidian/bookmarks.json",".obsidian/workspaces.json"]);function O4($){let J=$.normalize("NFC");if(sU$.has(J))return!1;let W=J.toLowerCase();return tU$.some((Q)=>W===Q||W.startsWith(`${Q}/`))}class G7{cfg;constructor($){this.cfg=$}scopesForPath($){let J=this.cfg.defaultScopes;for(let W of this.cfg.rules)if(E$(W.glob,$))J=W.scopes;return J}get readOnly(){return this.cfg.readOnly}get readPaths(){return this.cfg.readPaths}get strictReadDefault(){return this.cfg.strictReadDefault===!0}get writePaths(){return this.cfg.writePaths}get deletePaths(){return this.cfg.deletePaths}}function QJ($,J){return $.prepareCached?$.prepareCached(J):$.prepare(J)}function _W($,J){QJ($,`INSERT INTO event_log
169
+ `,J)+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 J=sK($),W=OW(J);return W.push(this.sourceToken),{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:W,explicitKey:!0}]}}case"map-value-ind":{this.onKeyLine=!0;let J=sK($),W=OW(J);return{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:W,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment($,J){if(this.type!=="comment")return!1;if(this.indent<=J)return!1;return $.every((W)=>W.type==="newline"||W.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()}}}OJ6.Parser=DQ$});var IQ$=z((MJ6)=>{var FQ$=EM(),IJ6=kQ(),gQ=bQ(),zJ6=fL(),jJ6=P$(),NJ6=fM(),HQ$=yM();function OQ$($){let J=$.prettyErrors!==!1;return{lineCounter:$.lineCounter||J&&new NJ6.LineCounter||null,prettyErrors:J}}function VJ6($,J={}){let{lineCounter:W,prettyErrors:Q}=OQ$(J),X=new HQ$.Parser(W?.addNewLine),Y=new FQ$.Composer(J),U=Array.from(Y.compose(X.parse($)));if(Q&&W)for(let G of U)G.errors.forEach(gQ.prettifyError($,W)),G.warnings.forEach(gQ.prettifyError($,W));if(U.length>0)return U;return Object.assign([],{empty:!0},Y.streamInfo())}function qQ$($,J={}){let{lineCounter:W,prettyErrors:Q}=OQ$(J),X=new HQ$.Parser(W?.addNewLine),Y=new FQ$.Composer(J),U=null;for(let G of Y.compose(X.parse($),!0,$.length))if(!U)U=G;else if(U.options.logLevel!=="silent"){U.errors.push(new gQ.YAMLParseError(G.range.slice(0,2),"MULTIPLE_DOCS","Source contains multiple documents; please use YAML.parseAllDocuments()"));break}if(Q&&W)U.errors.forEach(gQ.prettifyError($,W)),U.warnings.forEach(gQ.prettifyError($,W));return U}function AJ6($,J,W){let Q=void 0;if(typeof J==="function")Q=J;else if(W===void 0&&J&&typeof J==="object")W=J;let X=qQ$($,W);if(!X)return null;if(X.warnings.forEach((Y)=>zJ6.warn(X.options.logLevel,Y)),X.errors.length>0)if(X.options.logLevel!=="silent")throw X.errors[0];else X.errors=[];return X.toJS(Object.assign({reviver:Q},W))}function LJ6($,J,W){let Q=null;if(typeof J==="function"||Array.isArray(J))Q=J;else if(W===void 0&&J)W=J;if(typeof W==="string")W=W.length;if(typeof W==="number"){let X=Math.round(W);W=X<1?void 0:X>8?{indent:8}:{indent:X}}if($===void 0){let{keepUndefined:X}=W??J??{};if(!X)return}if(jJ6.isDocument($)&&!Q)return $.toString(W);return new IJ6.Document($,Q,W).toString(W)}MJ6.parse=AJ6;MJ6.parseAllDocuments=VJ6;MJ6.parseDocument=qQ$;MJ6.stringify=LJ6});var gM=z((uJ6)=>{var RJ6=EM(),wJ6=kQ(),CJ6=ZM(),xM=bQ(),_J6=jQ(),p0=P$(),kJ6=u0(),bJ6=U6(),vJ6=c0(),fJ6=l0(),yJ6=aK(),xJ6=vM(),gJ6=fM(),hJ6=yM(),$Z=IQ$(),zQ$=IQ();uJ6.Composer=RJ6.Composer;uJ6.Document=wJ6.Document;uJ6.Schema=CJ6.Schema;uJ6.YAMLError=xM.YAMLError;uJ6.YAMLParseError=xM.YAMLParseError;uJ6.YAMLWarning=xM.YAMLWarning;uJ6.Alias=_J6.Alias;uJ6.isAlias=p0.isAlias;uJ6.isCollection=p0.isCollection;uJ6.isDocument=p0.isDocument;uJ6.isMap=p0.isMap;uJ6.isNode=p0.isNode;uJ6.isPair=p0.isPair;uJ6.isScalar=p0.isScalar;uJ6.isSeq=p0.isSeq;uJ6.Pair=kJ6.Pair;uJ6.Scalar=bJ6.Scalar;uJ6.YAMLMap=vJ6.YAMLMap;uJ6.YAMLSeq=fJ6.YAMLSeq;uJ6.CST=yJ6;uJ6.Lexer=xJ6.Lexer;uJ6.LineCounter=gJ6.LineCounter;uJ6.Parser=hJ6.Parser;uJ6.parse=$Z.parse;uJ6.parseAllDocuments=$Z.parseAllDocuments;uJ6.parseDocument=$Z.parseDocument;uJ6.stringify=$Z.stringify;uJ6.visit=zQ$.visit;uJ6.visitAsync=zQ$.visitAsync});import{mkdirSync as JX6,readFileSync as CW}from"node:fs";import{join as WX6}from"node:path";import{fileURLToPath as F8}from"node:url";var H4="1.3.4";var F2=String.fromCharCode(0),H2=process.platform==="win32"||process.platform==="darwin";function aU$($,J=H2){let W=$.replace(/\*\*/g,F2),Q="";for(let X of W)if(X===F2)Q+=".*";else if(X==="*")Q+="[^/]*";else if(X==="?")Q+="[^/]";else Q+=X.replace(/[.+^${}()|[\]\\]/g,"\\$&");return new RegExp(`^${Q}$`,J?"i":"")}function E$($,J,W=H2){return aU$($.normalize("NFC"),W).test(J.normalize("NFC"))}var tU$=[".obsidian",".git",".trash"],sU$=new Set([".obsidian/bookmarks.json",".obsidian/workspaces.json"]);function O4($){let J=$.normalize("NFC");if(sU$.has(J))return!1;let W=J.toLowerCase();return tU$.some((Q)=>W===Q||W.startsWith(`${Q}/`))}class G7{cfg;constructor($){this.cfg=$}scopesForPath($){let J=this.cfg.defaultScopes;for(let W of this.cfg.rules)if(E$(W.glob,$))J=W.scopes;return J}get readOnly(){return this.cfg.readOnly}get readPaths(){return this.cfg.readPaths}get strictReadDefault(){return this.cfg.strictReadDefault===!0}get writePaths(){return this.cfg.writePaths}get deletePaths(){return this.cfg.deletePaths}}function QJ($,J){return $.prepareCached?$.prepareCached(J):$.prepare(J)}function _W($,J){QJ($,`INSERT INTO event_log
170
170
  (ts, vault_id, tool_name, caller, duration_ms, result_size, status, error_code, args_hash, event_type)
171
171
  VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?)`).run(J.ts,J.vault_id??null,J.tool_name??null,J.caller??null,J.duration_ms??null,J.result_size??null,J.status,J.error_code??null,J.args_hash??null,J.event_type??"tool_invocation")}var K7="1";function Z7($,J){let W={...$.plugins};for(let Q of J.forceEnabled??[]){let X=W[Q];W[Q]=X?{...X,installed:!0}:{installed:!0}}for(let Q of J.forceDisabled??[])W[Q]={installed:!1};return{...$,plugins:W}}function vZ($,J){if($.companion==="unreachable")return{kind:"plugin_unreachable"};if($.companion==="missing")return{kind:"plugin_missing",reason:"companion_missing"};let W=$.plugins[J];if(W?.installed)return W.version?{kind:"available",version:W.version}:{kind:"available"};return{kind:"plugin_missing",reason:"plugin_not_installed"}}class B7{byVault=new Map;set($,J){this.byVault.set($,J)}get($){return this.byVault.get($)??{companion:"missing",plugins:{}}}has($){return this.byVault.has($)}}var F={};d6(F,{xor:()=>pE,xid:()=>OE,void:()=>hE,uuidv7:()=>UE,uuidv6:()=>YE,uuidv4:()=>QE,uuid:()=>XE,util:()=>f,url:()=>GE,uppercase:()=>P8,unknown:()=>HJ,union:()=>gY,undefined:()=>xE,ulid:()=>HE,uint64:()=>fE,uint32:()=>kE,tuple:()=>Wq,trim:()=>C8,treeifyError:()=>iZ,transform:()=>uY,toUpperCase:()=>k8,toLowerCase:()=>_8,toJSONSchema:()=>DY,templateLiteral:()=>YS,symbol:()=>yE,superRefine:()=>Cq,success:()=>JS,stringbool:()=>HS,stringFormat:()=>EE,string:()=>J5,strictObject:()=>lE,startsWith:()=>S8,slugify:()=>b8,size:()=>BJ,setErrorMap:()=>kK$,set:()=>aE,safeParseAsync:()=>CO,safeParse:()=>wO,safeEncodeAsync:()=>xO,safeEncode:()=>fO,safeDecodeAsync:()=>gO,safeDecode:()=>yO,registry:()=>y7,regexes:()=>Y4,regex:()=>L8,refine:()=>wq,record:()=>Xq,readonly:()=>Mq,property:()=>GY,promise:()=>US,prettifyError:()=>oZ,preprocess:()=>qS,prefault:()=>qq,positive:()=>XY,pipe:()=>jY,partialRecord:()=>iE,parseAsync:()=>RO,parse:()=>TO,overwrite:()=>k4,optional:()=>X5,object:()=>cE,number:()=>uO,nullish:()=>$S,nullable:()=>Q5,null:()=>pO,normalize:()=>w8,nonpositive:()=>YY,nonoptional:()=>Iq,nonnegative:()=>UY,never:()=>xY,negative:()=>QY,nativeEnum:()=>tE,nanoid:()=>BE,nan:()=>WS,multipleOf:()=>W0,minSize:()=>J1,minLength:()=>M1,mime:()=>R8,meta:()=>DS,maxSize:()=>X0,maxLength:()=>DJ,map:()=>rE,mac:()=>zE,lte:()=>U4,lt:()=>e4,lowercase:()=>M8,looseRecord:()=>oE,looseObject:()=>dE,locales:()=>tW,literal:()=>sE,length:()=>FJ,lazy:()=>Sq,ksuid:()=>qE,keyof:()=>mE,jwt:()=>PE,json:()=>OS,iso:()=>y8,ipv6:()=>jE,ipv4:()=>IE,invertCodec:()=>QS,intersection:()=>$q,int64:()=>vE,int32:()=>_E,int:()=>zY,instanceof:()=>FS,includes:()=>E8,httpUrl:()=>KE,hostname:()=>SE,hex:()=>TE,hash:()=>RE,guid:()=>WE,gte:()=>y6,gt:()=>$1,globalRegistry:()=>j6,getErrorMap:()=>bK$,function:()=>GS,fromJSONSchema:()=>zS,formatError:()=>uW,float64:()=>CE,float32:()=>wE,flattenError:()=>hW,file:()=>eE,exactOptional:()=>Bq,enum:()=>hY,endsWith:()=>T8,encodeAsync:()=>bO,encode:()=>_O,emoji:()=>ZE,email:()=>JE,e164:()=>ME,discriminatedUnion:()=>nE,describe:()=>BS,decodeAsync:()=>vO,decode:()=>kO,date:()=>uE,custom:()=>ZS,cuid2:()=>FE,cuid:()=>DE,core:()=>P1,config:()=>J6,coerce:()=>kq,codec:()=>XS,clone:()=>v6,cidrv6:()=>VE,cidrv4:()=>NE,check:()=>KS,catch:()=>Nq,boolean:()=>mO,bigint:()=>bE,base64url:()=>LE,base64:()=>AE,array:()=>K5,any:()=>gE,_function:()=>GS,_default:()=>Hq,_ZodString:()=>NY,ZodXor:()=>tO,ZodXID:()=>SY,ZodVoid:()=>rO,ZodUnknown:()=>iO,ZodUnion:()=>B5,ZodUndefined:()=>lO,ZodUUID:()=>W1,ZodURL:()=>U5,ZodULID:()=>EY,ZodType:()=>K$,ZodTuple:()=>Jq,ZodTransform:()=>Kq,ZodTemplateLiteral:()=>Pq,ZodSymbol:()=>cO,ZodSuccess:()=>zq,ZodStringFormat:()=>k$,ZodString:()=>h8,ZodSet:()=>Yq,ZodRecord:()=>x8,ZodRealError:()=>i6,ZodReadonly:()=>Lq,ZodPromise:()=>Tq,ZodPreprocess:()=>Aq,ZodPrefault:()=>Oq,ZodPipe:()=>D5,ZodOptional:()=>mY,ZodObject:()=>Z5,ZodNumberFormat:()=>OJ,ZodNumber:()=>m8,ZodNullable:()=>Dq,ZodNull:()=>dO,ZodNonOptional:()=>cY,ZodNever:()=>oO,ZodNanoID:()=>LY,ZodNaN:()=>Vq,ZodMap:()=>Qq,ZodMAC:()=>hO,ZodLiteral:()=>Uq,ZodLazy:()=>Eq,ZodKSUID:()=>TY,ZodJWT:()=>fY,ZodIssueCode:()=>_K$,ZodIntersection:()=>eO,ZodISOTime:()=>qY,ZodISODuration:()=>IY,ZodISODateTime:()=>HY,ZodISODate:()=>OY,ZodIPv6:()=>wY,ZodIPv4:()=>RY,ZodGUID:()=>W5,ZodFunction:()=>Rq,ZodFirstPartyTypeKind:()=>_q,ZodFile:()=>Gq,ZodExactOptional:()=>Zq,ZodError:()=>wK$,ZodEnum:()=>g8,ZodEmoji:()=>AY,ZodEmail:()=>VY,ZodE164:()=>vY,ZodDiscriminatedUnion:()=>sO,ZodDefault:()=>Fq,ZodDate:()=>G5,ZodCustomStringFormat:()=>u8,ZodCustom:()=>H5,ZodCodec:()=>F5,ZodCatch:()=>jq,ZodCUID2:()=>PY,ZodCUID:()=>MY,ZodCIDRv6:()=>_Y,ZodCIDRv4:()=>CY,ZodBoolean:()=>c8,ZodBigIntFormat:()=>yY,ZodBigInt:()=>l8,ZodBase64URL:()=>bY,ZodBase64:()=>kY,ZodArray:()=>aO,ZodAny:()=>nO,TimePrecision:()=>WH,NEVER:()=>fZ,$output:()=>aF,$input:()=>tF,$brand:()=>yZ});var P1={};d6(P1,{version:()=>dB,util:()=>f,treeifyError:()=>iZ,toJSONSchema:()=>DY,toDotPath:()=>V2,safeParseAsync:()=>aZ,safeParse:()=>rZ,safeEncodeAsync:()=>_G$,safeEncode:()=>wG$,safeDecodeAsync:()=>kG$,safeDecode:()=>CG$,registry:()=>y7,regexes:()=>Y4,process:()=>R$,prettifyError:()=>oZ,parseAsync:()=>O7,parse:()=>H7,meta:()=>yH,locales:()=>tW,isValidJWT:()=>c2,isValidBase64URL:()=>m2,isValidBase64:()=>FD,initializeContext:()=>Q0,globalRegistry:()=>j6,globalConfig:()=>YJ,formatError:()=>uW,flattenError:()=>hW,finalize:()=>U0,extractDefs:()=>Y0,encodeAsync:()=>TG$,encode:()=>EG$,describe:()=>fH,decodeAsync:()=>RG$,decode:()=>SG$,createToJSONSchemaMethod:()=>gH,createStandardJSONSchemaMethod:()=>f8,config:()=>J6,clone:()=>v6,_xor:()=>YK$,_xid:()=>i7,_void:()=>SH,_uuidv7:()=>m7,_uuidv6:()=>u7,_uuidv4:()=>h7,_uuid:()=>g7,_url:()=>eW,_uppercase:()=>P8,_unknown:()=>PH,_union:()=>QK$,_undefined:()=>AH,_ulid:()=>n7,_uint64:()=>NH,_uint32:()=>HH,_tuple:()=>KK$,_trim:()=>C8,_transform:()=>qK$,_toUpperCase:()=>k8,_toLowerCase:()=>_8,_templateLiteral:()=>PK$,_symbol:()=>VH,_superRefine:()=>vH,_success:()=>VK$,_stringbool:()=>xH,_stringFormat:()=>v8,_string:()=>eF,_startsWith:()=>S8,_slugify:()=>b8,_size:()=>BJ,_set:()=>DK$,_safeParseAsync:()=>N8,_safeParse:()=>j8,_safeEncodeAsync:()=>A7,_safeEncode:()=>N7,_safeDecodeAsync:()=>L7,_safeDecode:()=>V7,_regex:()=>L8,_refine:()=>bH,_record:()=>ZK$,_readonly:()=>MK$,_property:()=>GY,_promise:()=>SK$,_positive:()=>XY,_pipe:()=>LK$,_parseAsync:()=>z8,_parse:()=>I8,_overwrite:()=>k4,_optional:()=>IK$,_number:()=>GH,_nullable:()=>zK$,_null:()=>LH,_normalize:()=>w8,_nonpositive:()=>YY,_nonoptional:()=>NK$,_nonnegative:()=>UY,_never:()=>EH,_negative:()=>QY,_nativeEnum:()=>HK$,_nanoid:()=>l7,_nan:()=>wH,_multipleOf:()=>W0,_minSize:()=>J1,_minLength:()=>M1,_min:()=>y6,_mime:()=>R8,_maxSize:()=>X0,_maxLength:()=>DJ,_max:()=>U4,_map:()=>BK$,_mac:()=>JH,_lte:()=>U4,_lt:()=>e4,_lowercase:()=>M8,_literal:()=>OK$,_length:()=>FJ,_lazy:()=>EK$,_ksuid:()=>o7,_jwt:()=>WY,_isoTime:()=>YH,_isoDuration:()=>UH,_isoDateTime:()=>XH,_isoDate:()=>QH,_ipv6:()=>a7,_ipv4:()=>r7,_intersection:()=>GK$,_int64:()=>jH,_int32:()=>FH,_int:()=>ZH,_includes:()=>E8,_guid:()=>sW,_gte:()=>y6,_gt:()=>$1,_float64:()=>DH,_float32:()=>BH,_file:()=>_H,_enum:()=>FK$,_endsWith:()=>T8,_encodeAsync:()=>z7,_encode:()=>q7,_emoji:()=>c7,_email:()=>x7,_e164:()=>JY,_discriminatedUnion:()=>UK$,_default:()=>jK$,_decodeAsync:()=>j7,_decode:()=>I7,_date:()=>TH,_custom:()=>kH,_cuid2:()=>p7,_cuid:()=>d7,_coercedString:()=>$H,_coercedNumber:()=>KH,_coercedDate:()=>RH,_coercedBoolean:()=>qH,_coercedBigint:()=>zH,_cidrv6:()=>s7,_cidrv4:()=>t7,_check:()=>t2,_catch:()=>AK$,_boolean:()=>OH,_bigint:()=>IH,_base64url:()=>$Y,_base64:()=>e7,_array:()=>CH,_any:()=>MH,TimePrecision:()=>WH,NEVER:()=>fZ,JSONSchemaGenerator:()=>LO,JSONSchema:()=>s2,Doc:()=>S7,$output:()=>aF,$input:()=>tF,$constructor:()=>M,$brand:()=>yZ,$ZodXor:()=>CD,$ZodXID:()=>JD,$ZodVoid:()=>SD,$ZodUnknown:()=>PD,$ZodUnion:()=>pW,$ZodUndefined:()=>AD,$ZodUUID:()=>iB,$ZodURL:()=>rB,$ZodULID:()=>$D,$ZodType:()=>X$,$ZodTuple:()=>b7,$ZodTransform:()=>hD,$ZodTemplateLiteral:()=>aD,$ZodSymbol:()=>VD,$ZodSuccess:()=>pD,$ZodStringFormat:()=>_$,$ZodString:()=>ZJ,$ZodSet:()=>fD,$ZodRegistry:()=>sF,$ZodRecord:()=>bD,$ZodRealError:()=>n6,$ZodReadonly:()=>rD,$ZodPromise:()=>sD,$ZodPreprocess:()=>oD,$ZodPrefault:()=>lD,$ZodPipe:()=>f7,$ZodOptional:()=>v7,$ZodObjectJIT:()=>wD,$ZodObject:()=>p2,$ZodNumberFormat:()=>jD,$ZodNumber:()=>_7,$ZodNullable:()=>mD,$ZodNull:()=>LD,$ZodNonOptional:()=>dD,$ZodNever:()=>ED,$ZodNanoID:()=>tB,$ZodNaN:()=>iD,$ZodMap:()=>vD,$ZodMAC:()=>ZD,$ZodLiteral:()=>xD,$ZodLazy:()=>eD,$ZodKSUID:()=>WD,$ZodJWT:()=>ID,$ZodIntersection:()=>kD,$ZodISOTime:()=>YD,$ZodISODuration:()=>UD,$ZodISODateTime:()=>XD,$ZodISODate:()=>QD,$ZodIPv6:()=>KD,$ZodIPv4:()=>GD,$ZodGUID:()=>nB,$ZodFunction:()=>tD,$ZodFile:()=>gD,$ZodExactOptional:()=>uD,$ZodError:()=>gW,$ZodEnum:()=>yD,$ZodEncodeError:()=>UJ,$ZodEmoji:()=>aB,$ZodEmail:()=>oB,$ZodE164:()=>qD,$ZodDiscriminatedUnion:()=>_D,$ZodDefault:()=>cD,$ZodDate:()=>TD,$ZodCustomStringFormat:()=>zD,$ZodCustom:()=>$F,$ZodCodec:()=>nW,$ZodCheckUpperCase:()=>xB,$ZodCheckStringFormat:()=>V8,$ZodCheckStartsWith:()=>hB,$ZodCheckSizeEquals:()=>_B,$ZodCheckRegex:()=>fB,$ZodCheckProperty:()=>mB,$ZodCheckOverwrite:()=>lB,$ZodCheckNumberFormat:()=>TB,$ZodCheckMultipleOf:()=>SB,$ZodCheckMinSize:()=>CB,$ZodCheckMinLength:()=>bB,$ZodCheckMimeType:()=>cB,$ZodCheckMaxSize:()=>wB,$ZodCheckMaxLength:()=>kB,$ZodCheckLowerCase:()=>yB,$ZodCheckLessThan:()=>P7,$ZodCheckLengthEquals:()=>vB,$ZodCheckIncludes:()=>gB,$ZodCheckGreaterThan:()=>E7,$ZodCheckEndsWith:()=>uB,$ZodCheckBigIntFormat:()=>RB,$ZodCheck:()=>v$,$ZodCatch:()=>nD,$ZodCUID2:()=>eB,$ZodCUID:()=>sB,$ZodCIDRv6:()=>DD,$ZodCIDRv4:()=>BD,$ZodBoolean:()=>dW,$ZodBigIntFormat:()=>ND,$ZodBigInt:()=>k7,$ZodBase64URL:()=>OD,$ZodBase64:()=>HD,$ZodAsyncError:()=>s4,$ZodArray:()=>RD,$ZodAny:()=>MD});var O2,fZ=Object.freeze({status:"aborted"});function M($,J,W){function Q(G,K){if(!G._zod)Object.defineProperty(G,"_zod",{value:{def:K,constr:U,traits:new Set},enumerable:!1});if(G._zod.traits.has($))return;G._zod.traits.add($),J(G,K);let Z=U.prototype,B=Object.keys(Z);for(let D=0;D<B.length;D++){let H=B[D];if(!(H in G))G[H]=Z[H].bind(G)}}let X=W?.Parent??Object;class Y extends X{}Object.defineProperty(Y,"name",{value:$});function U(G){var K;let Z=W?.Parent?new Y:this;Q(Z,G),(K=Z._zod).deferred??(K.deferred=[]);for(let B of Z._zod.deferred)B();return Z}return Object.defineProperty(U,"init",{value:Q}),Object.defineProperty(U,Symbol.hasInstance,{value:(G)=>{if(W?.Parent&&G instanceof W.Parent)return!0;return G?._zod?.traits?.has($)}}),Object.defineProperty(U,"name",{value:$}),U}var yZ=Symbol("zod_brand");class s4 extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}}class UJ extends Error{constructor($){super(`Encountered unidirectional transform during encode: ${$}`);this.name="ZodEncodeError"}}(O2=globalThis).__zod_globalConfig??(O2.__zod_globalConfig={});var YJ=globalThis.__zod_globalConfig;function J6($){if($)Object.assign(YJ,$);return YJ}var f={};d6(f,{unwrapMessage:()=>kW,uint8ArrayToHex:()=>MG$,uint8ArrayToBase64url:()=>AG$,uint8ArrayToBase64:()=>z2,stringifyPrimitive:()=>b,slugify:()=>hZ,shallowClone:()=>mZ,safeExtend:()=>qG$,required:()=>jG$,randomString:()=>KG$,propertyKeyTypes:()=>fW,promiseAllObject:()=>GG$,primitiveTypes:()=>cZ,prefixIssues:()=>p6,pick:()=>FG$,partial:()=>zG$,parsedType:()=>v,optionalKeys:()=>lZ,omit:()=>HG$,objectClone:()=>QG$,numKeys:()=>ZG$,nullish:()=>s1,normalizeParams:()=>u,mergeDefs:()=>L1,merge:()=>IG$,jsonStringifyReplacer:()=>H8,joinValues:()=>S,issue:()=>q8,isPlainObject:()=>$0,isObject:()=>GJ,hexToUint8Array:()=>LG$,getSizableOrigin:()=>yW,getParsedType:()=>BG$,getLengthableOrigin:()=>xW,getEnumValues:()=>bW,getElementAtPath:()=>UG$,floatSafeRemainder:()=>gZ,finalizeIssue:()=>f6,extend:()=>OG$,explicitlyAborted:()=>nZ,escapeRegex:()=>q4,esc:()=>D7,defineLazy:()=>q$,createTransparentProxy:()=>DG$,cloneDef:()=>YG$,clone:()=>v6,cleanRegex:()=>vW,cleanEnum:()=>NG$,captureStackTrace:()=>F7,cached:()=>O8,base64urlToUint8Array:()=>VG$,base64ToUint8Array:()=>I2,assignProp:()=>e1,assertNotEqual:()=>$G$,assertNever:()=>WG$,assertIs:()=>JG$,assertEqual:()=>eU$,assert:()=>XG$,allowsEval:()=>uZ,aborted:()=>J0,NUMBER_FORMAT_RANGES:()=>dZ,Class:()=>j2,BIGINT_FORMAT_RANGES:()=>pZ});function eU$($){return $}function $G$($){return $}function JG$($){}function WG$($){throw Error("Unexpected value in exhaustive check")}function XG$($){}function bW($){let J=Object.values($).filter((Q)=>typeof Q==="number");return Object.entries($).filter(([Q,X])=>J.indexOf(+Q)===-1).map(([Q,X])=>X)}function S($,J="|"){return $.map((W)=>b(W)).join(J)}function H8($,J){if(typeof J==="bigint")return J.toString();return J}function O8($){return{get value(){{let W=$();return Object.defineProperty(this,"value",{value:W}),W}throw Error("cached value already set")}}}function s1($){return $===null||$===void 0}function vW($){let J=$.startsWith("^")?1:0,W=$.endsWith("$")?$.length-1:$.length;return $.slice(J,W)}function gZ($,J){let W=$/J,Q=Math.round(W),X=Number.EPSILON*Math.max(Math.abs(W),1);if(Math.abs(W-Q)<X)return 0;return W-Q}var q2=Symbol("evaluating");function q$($,J,W){let Q=void 0;Object.defineProperty($,J,{get(){if(Q===q2)return;if(Q===void 0)Q=q2,Q=W();return Q},set(X){Object.defineProperty($,J,{value:X})},configurable:!0})}function QG$($){return Object.create(Object.getPrototypeOf($),Object.getOwnPropertyDescriptors($))}function e1($,J,W){Object.defineProperty($,J,{value:W,writable:!0,enumerable:!0,configurable:!0})}function L1(...$){let J={};for(let W of $){let Q=Object.getOwnPropertyDescriptors(W);Object.assign(J,Q)}return Object.defineProperties({},J)}function YG$($){return L1($._zod.def)}function UG$($,J){if(!J)return $;return J.reduce((W,Q)=>W?.[Q],$)}function GG$($){let J=Object.keys($),W=J.map((Q)=>$[Q]);return Promise.all(W).then((Q)=>{let X={};for(let Y=0;Y<J.length;Y++)X[J[Y]]=Q[Y];return X})}function KG$($=10){let W="";for(let Q=0;Q<$;Q++)W+="abcdefghijklmnopqrstuvwxyz"[Math.floor(Math.random()*26)];return W}function D7($){return JSON.stringify($)}function hZ($){return $.toLowerCase().trim().replace(/[^\w\s-]/g,"").replace(/[\s_-]+/g,"-").replace(/^-+|-+$/g,"")}var F7="captureStackTrace"in Error?Error.captureStackTrace:(...$)=>{};function GJ($){return typeof $==="object"&&$!==null&&!Array.isArray($)}var uZ=O8(()=>{if(YJ.jitless)return!1;if(typeof navigator<"u"&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{return new Function(""),!0}catch($){return!1}});function $0($){if(GJ($)===!1)return!1;let J=$.constructor;if(J===void 0)return!0;if(typeof J!=="function")return!0;let W=J.prototype;if(GJ(W)===!1)return!1;if(Object.prototype.hasOwnProperty.call(W,"isPrototypeOf")===!1)return!1;return!0}function mZ($){if($0($))return{...$};if(Array.isArray($))return[...$];if($ instanceof Map)return new Map($);if($ instanceof Set)return new Set($);return $}function ZG$($){let J=0;for(let W in $)if(Object.prototype.hasOwnProperty.call($,W))J++;return J}var BG$=($)=>{let J=typeof $;switch(J){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: ${J}`)}},fW=new Set(["string","number","symbol"]),cZ=new Set(["string","number","bigint","boolean","symbol","undefined"]);function q4($){return $.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function v6($,J,W){let Q=new $._zod.constr(J??$._zod.def);if(!J||W?.parent)Q._zod.parent=$;return Q}function u($){let J=$;if(!J)return{};if(typeof J==="string")return{error:()=>J};if(J?.message!==void 0){if(J?.error!==void 0)throw Error("Cannot specify both `message` and `error` params");J.error=J.message}if(delete J.message,typeof J.error==="string")return{...J,error:()=>J.error};return J}function DG$($){let J;return new Proxy({},{get(W,Q,X){return J??(J=$()),Reflect.get(J,Q,X)},set(W,Q,X,Y){return J??(J=$()),Reflect.set(J,Q,X,Y)},has(W,Q){return J??(J=$()),Reflect.has(J,Q)},deleteProperty(W,Q){return J??(J=$()),Reflect.deleteProperty(J,Q)},ownKeys(W){return J??(J=$()),Reflect.ownKeys(J)},getOwnPropertyDescriptor(W,Q){return J??(J=$()),Reflect.getOwnPropertyDescriptor(J,Q)},defineProperty(W,Q,X){return J??(J=$()),Reflect.defineProperty(J,Q,X)}})}function b($){if(typeof $==="bigint")return $.toString()+"n";if(typeof $==="string")return`"${$}"`;return`${$}`}function lZ($){return Object.keys($).filter((J)=>{return $[J]._zod.optin==="optional"&&$[J]._zod.optout==="optional"})}var dZ={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]},pZ={int64:[BigInt("-9223372036854775808"),BigInt("9223372036854775807")],uint64:[BigInt(0),BigInt("18446744073709551615")]};function FG$($,J){let W=$._zod.def,Q=W.checks;if(Q&&Q.length>0)throw Error(".pick() cannot be used on object schemas containing refinements");let Y=L1($._zod.def,{get shape(){let U={};for(let G in J){if(!(G in W.shape))throw Error(`Unrecognized key: "${G}"`);if(!J[G])continue;U[G]=W.shape[G]}return e1(this,"shape",U),U},checks:[]});return v6($,Y)}function HG$($,J){let W=$._zod.def,Q=W.checks;if(Q&&Q.length>0)throw Error(".omit() cannot be used on object schemas containing refinements");let Y=L1($._zod.def,{get shape(){let U={...$._zod.def.shape};for(let G in J){if(!(G in W.shape))throw Error(`Unrecognized key: "${G}"`);if(!J[G])continue;delete U[G]}return e1(this,"shape",U),U},checks:[]});return v6($,Y)}function OG$($,J){if(!$0(J))throw Error("Invalid input to extend: expected a plain object");let W=$._zod.def.checks;if(W&&W.length>0){let Y=$._zod.def.shape;for(let U in J)if(Object.getOwnPropertyDescriptor(Y,U)!==void 0)throw Error("Cannot overwrite keys on object schemas containing refinements. Use `.safeExtend()` instead.")}let X=L1($._zod.def,{get shape(){let Y={...$._zod.def.shape,...J};return e1(this,"shape",Y),Y}});return v6($,X)}function qG$($,J){if(!$0(J))throw Error("Invalid input to safeExtend: expected a plain object");let W=L1($._zod.def,{get shape(){let Q={...$._zod.def.shape,...J};return e1(this,"shape",Q),Q}});return v6($,W)}function IG$($,J){if($._zod.def.checks?.length)throw Error(".merge() cannot be used on object schemas containing refinements. Use .safeExtend() instead.");let W=L1($._zod.def,{get shape(){let Q={...$._zod.def.shape,...J._zod.def.shape};return e1(this,"shape",Q),Q},get catchall(){return J._zod.def.catchall},checks:J._zod.def.checks??[]});return v6($,W)}function zG$($,J,W){let X=J._zod.def.checks;if(X&&X.length>0)throw Error(".partial() cannot be used on object schemas containing refinements");let U=L1(J._zod.def,{get shape(){let G=J._zod.def.shape,K={...G};if(W)for(let Z in W){if(!(Z in G))throw Error(`Unrecognized key: "${Z}"`);if(!W[Z])continue;K[Z]=$?new $({type:"optional",innerType:G[Z]}):G[Z]}else for(let Z in G)K[Z]=$?new $({type:"optional",innerType:G[Z]}):G[Z];return e1(this,"shape",K),K},checks:[]});return v6(J,U)}function jG$($,J,W){let Q=L1(J._zod.def,{get shape(){let X=J._zod.def.shape,Y={...X};if(W)for(let U in W){if(!(U in Y))throw Error(`Unrecognized key: "${U}"`);if(!W[U])continue;Y[U]=new $({type:"nonoptional",innerType:X[U]})}else for(let U in X)Y[U]=new $({type:"nonoptional",innerType:X[U]});return e1(this,"shape",Y),Y}});return v6(J,Q)}function J0($,J=0){if($.aborted===!0)return!0;for(let W=J;W<$.issues.length;W++)if($.issues[W]?.continue!==!0)return!0;return!1}function nZ($,J=0){if($.aborted===!0)return!0;for(let W=J;W<$.issues.length;W++)if($.issues[W]?.continue===!1)return!0;return!1}function p6($,J){return J.map((W)=>{var Q;return(Q=W).path??(Q.path=[]),W.path.unshift($),W})}function kW($){return typeof $==="string"?$:$?.message}function f6($,J,W){let Q=$.message?$.message:kW($.inst?._zod.def?.error?.($))??kW(J?.error?.($))??kW(W.customError?.($))??kW(W.localeError?.($))??"Invalid input",{inst:X,continue:Y,input:U,...G}=$;if(G.path??(G.path=[]),G.message=Q,J?.reportInput)G.input=U;return G}function yW($){if($ instanceof Set)return"set";if($ instanceof Map)return"map";if($ instanceof File)return"file";return"unknown"}function xW($){if(Array.isArray($))return"array";if(typeof $==="string")return"string";return"unknown"}function v($){let J=typeof $;switch(J){case"number":return Number.isNaN($)?"nan":"number";case"object":{if($===null)return"null";if(Array.isArray($))return"array";let W=$;if(W&&Object.getPrototypeOf(W)!==Object.prototype&&"constructor"in W&&W.constructor)return W.constructor.name}}return J}function q8(...$){let[J,W,Q]=$;if(typeof J==="string")return{message:J,code:"custom",input:W,inst:Q};return{...J}}function NG$($){return Object.entries($).filter(([J,W])=>{return Number.isNaN(Number.parseInt(J,10))}).map((J)=>J[1])}function I2($){let J=atob($),W=new Uint8Array(J.length);for(let Q=0;Q<J.length;Q++)W[Q]=J.charCodeAt(Q);return W}function z2($){let J="";for(let W=0;W<$.length;W++)J+=String.fromCharCode($[W]);return btoa(J)}function VG$($){let J=$.replace(/-/g,"+").replace(/_/g,"/"),W="=".repeat((4-J.length%4)%4);return I2(J+W)}function AG$($){return z2($).replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")}function LG$($){let J=$.replace(/^0x/,"");if(J.length%2!==0)throw Error("Invalid hex string length");let W=new Uint8Array(J.length/2);for(let Q=0;Q<J.length;Q+=2)W[Q/2]=Number.parseInt(J.slice(Q,Q+2),16);return W}function MG$($){return Array.from($).map((J)=>J.toString(16).padStart(2,"0")).join("")}class j2{constructor(...$){}}var N2=($,J)=>{$.name="$ZodError",Object.defineProperty($,"_zod",{value:$._zod,enumerable:!1}),Object.defineProperty($,"issues",{value:J,enumerable:!1}),$.message=JSON.stringify(J,H8,2),Object.defineProperty($,"toString",{value:()=>$.message,enumerable:!1})},gW=M("$ZodError",N2),n6=M("$ZodError",N2,{Parent:Error});function hW($,J=(W)=>W.message){let W={},Q=[];for(let X of $.issues)if(X.path.length>0)W[X.path[0]]=W[X.path[0]]||[],W[X.path[0]].push(J(X));else Q.push(J(X));return{formErrors:Q,fieldErrors:W}}function uW($,J=(W)=>W.message){let W={_errors:[]},Q=(X,Y=[])=>{for(let U of X.issues)if(U.code==="invalid_union"&&U.errors.length)U.errors.map((G)=>Q({issues:G},[...Y,...U.path]));else if(U.code==="invalid_key")Q({issues:U.issues},[...Y,...U.path]);else if(U.code==="invalid_element")Q({issues:U.issues},[...Y,...U.path]);else{let G=[...Y,...U.path];if(G.length===0)W._errors.push(J(U));else{let K=W,Z=0;while(Z<G.length){let B=G[Z];if(Z!==G.length-1)K[B]=K[B]||{_errors:[]};else K[B]=K[B]||{_errors:[]},K[B]._errors.push(J(U));K=K[B],Z++}}}};return Q($),W}function iZ($,J=(W)=>W.message){let W={errors:[]},Q=(X,Y=[])=>{var U,G;for(let K of X.issues)if(K.code==="invalid_union"&&K.errors.length)K.errors.map((Z)=>Q({issues:Z},[...Y,...K.path]));else if(K.code==="invalid_key")Q({issues:K.issues},[...Y,...K.path]);else if(K.code==="invalid_element")Q({issues:K.issues},[...Y,...K.path]);else{let Z=[...Y,...K.path];if(Z.length===0){W.errors.push(J(K));continue}let B=W,D=0;while(D<Z.length){let H=Z[D],O=D===Z.length-1;if(typeof H==="string")B.properties??(B.properties={}),(U=B.properties)[H]??(U[H]={errors:[]}),B=B.properties[H];else B.items??(B.items=[]),(G=B.items)[H]??(G[H]={errors:[]}),B=B.items[H];if(O)B.errors.push(J(K));D++}}};return Q($),W}function V2($){let J=[],W=$.map((Q)=>typeof Q==="object"?Q.key:Q);for(let Q of W)if(typeof Q==="number")J.push(`[${Q}]`);else if(typeof Q==="symbol")J.push(`[${JSON.stringify(String(Q))}]`);else if(/[^\w$]/.test(Q))J.push(`[${JSON.stringify(Q)}]`);else{if(J.length)J.push(".");J.push(Q)}return J.join("")}function oZ($){let J=[],W=[...$.issues].sort((Q,X)=>(Q.path??[]).length-(X.path??[]).length);for(let Q of W)if(J.push(`✖ ${Q.message}`),Q.path?.length)J.push(` → at ${V2(Q.path)}`);return J.join(`
172
172
  `)}var I8=($)=>(J,W,Q,X)=>{let Y=Q?{...Q,async:!1}:{async:!1},U=J._zod.run({value:W,issues:[]},Y);if(U instanceof Promise)throw new s4;if(U.issues.length){let G=new(X?.Err??$)(U.issues.map((K)=>f6(K,Y,J6())));throw F7(G,X?.callee),G}return U.value},H7=I8(n6),z8=($)=>async(J,W,Q,X)=>{let Y=Q?{...Q,async:!0}:{async:!0},U=J._zod.run({value:W,issues:[]},Y);if(U instanceof Promise)U=await U;if(U.issues.length){let G=new(X?.Err??$)(U.issues.map((K)=>f6(K,Y,J6())));throw F7(G,X?.callee),G}return U.value},O7=z8(n6),j8=($)=>(J,W,Q)=>{let X=Q?{...Q,async:!1}:{async:!1},Y=J._zod.run({value:W,issues:[]},X);if(Y instanceof Promise)throw new s4;return Y.issues.length?{success:!1,error:new($??gW)(Y.issues.map((U)=>f6(U,X,J6())))}:{success:!0,data:Y.value}},rZ=j8(n6),N8=($)=>async(J,W,Q)=>{let X=Q?{...Q,async:!0}:{async:!0},Y=J._zod.run({value:W,issues:[]},X);if(Y instanceof Promise)Y=await Y;return Y.issues.length?{success:!1,error:new $(Y.issues.map((U)=>f6(U,X,J6())))}:{success:!0,data:Y.value}},aZ=N8(n6),q7=($)=>(J,W,Q)=>{let X=Q?{...Q,direction:"backward"}:{direction:"backward"};return I8($)(J,W,X)},EG$=q7(n6),I7=($)=>(J,W,Q)=>{return I8($)(J,W,Q)},SG$=I7(n6),z7=($)=>async(J,W,Q)=>{let X=Q?{...Q,direction:"backward"}:{direction:"backward"};return z8($)(J,W,X)},TG$=z7(n6),j7=($)=>async(J,W,Q)=>{return z8($)(J,W,Q)},RG$=j7(n6),N7=($)=>(J,W,Q)=>{let X=Q?{...Q,direction:"backward"}:{direction:"backward"};return j8($)(J,W,X)},wG$=N7(n6),V7=($)=>(J,W,Q)=>{return j8($)(J,W,Q)},CG$=V7(n6),A7=($)=>async(J,W,Q)=>{let X=Q?{...Q,direction:"backward"}:{direction:"backward"};return N8($)(J,W,X)},_G$=A7(n6),L7=($)=>async(J,W,Q)=>{return N8($)(J,W,Q)},kG$=L7(n6);var Y4={};d6(Y4,{xid:()=>$B,uuid7:()=>yG$,uuid6:()=>fG$,uuid4:()=>vG$,uuid:()=>KJ,uppercase:()=>EB,unicodeEmail:()=>A2,undefined:()=>MB,ulid:()=>eZ,time:()=>IB,string:()=>jB,sha512_hex:()=>X3$,sha512_base64url:()=>Y3$,sha512_base64:()=>Q3$,sha384_hex:()=>$3$,sha384_base64url:()=>W3$,sha384_base64:()=>J3$,sha256_hex:()=>tG$,sha256_base64url:()=>eG$,sha256_base64:()=>sG$,sha1_hex:()=>oG$,sha1_base64url:()=>aG$,sha1_base64:()=>rG$,rfc5322Email:()=>gG$,number:()=>mW,null:()=>LB,nanoid:()=>WB,md5_hex:()=>pG$,md5_base64url:()=>iG$,md5_base64:()=>nG$,mac:()=>ZB,lowercase:()=>PB,ksuid:()=>JB,ipv6:()=>KB,ipv4:()=>GB,integer:()=>VB,idnEmail:()=>hG$,httpProtocol:()=>HB,html5Email:()=>xG$,hostname:()=>cG$,hex:()=>dG$,guid:()=>QB,extendedDuration:()=>bG$,emoji:()=>UB,email:()=>YB,e164:()=>OB,duration:()=>XB,domain:()=>lG$,datetime:()=>zB,date:()=>qB,cuid2:()=>sZ,cuid:()=>tZ,cidrv6:()=>DB,cidrv4:()=>BB,browserEmail:()=>uG$,boolean:()=>AB,bigint:()=>NB,base64url:()=>M7,base64:()=>FB});var tZ=/^[cC][0-9a-z]{6,}$/,sZ=/^[0-9a-z]+$/,eZ=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,$B=/^[0-9a-vA-V]{20}$/,JB=/^[A-Za-z0-9]{27}$/,WB=/^[a-zA-Z0-9_-]{21}$/,XB=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,bG$=/^[-+]?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)?)??$/,QB=/^([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})$/,KJ=($)=>{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})$`)},vG$=KJ(4),fG$=KJ(6),yG$=KJ(7),YB=/^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,xG$=/^[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])?)*$/,gG$=/^(([^<>()\[\]\\.,;:\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,}))$/,A2=/^[^\s@"]{1,64}@[^\s@]{1,255}$/u,hG$=A2,uG$=/^[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])?)*$/,mG$="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";function UB(){return new RegExp(mG$,"u")}var GB=/^(?:(?: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])$/,KB=/^(([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}|:))$/,ZB=($)=>{let J=q4($??":");return new RegExp(`^(?:[0-9A-F]{2}${J}){5}[0-9A-F]{2}$|^(?:[0-9a-f]{2}${J}){5}[0-9a-f]{2}$`)},BB=/^((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])$/,DB=/^(([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])$/,FB=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,M7=/^[A-Za-z0-9_-]*$/,cG$=/^(?=.{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])?)*\.?$/,lG$=/^([a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,}$/,HB=/^https?$/,OB=/^\+[1-9]\d{6,14}$/,L2="(?:(?:\\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])))",qB=new RegExp(`^${L2}$`);function M2($){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 IB($){return new RegExp(`^${M2($)}$`)}function zB($){let J=M2({precision:$.precision}),W=["Z"];if($.local)W.push("");if($.offset)W.push("([+-](?:[01]\\d|2[0-3]):[0-5]\\d)");let Q=`${J}(?:${W.join("|")})`;return new RegExp(`^${L2}T(?:${Q})$`)}var jB=($)=>{let J=$?`[\\s\\S]{${$?.minimum??0},${$?.maximum??""}}`:"[\\s\\S]*";return new RegExp(`^${J}$`)},NB=/^-?\d+n?$/,VB=/^-?\d+$/,mW=/^-?\d+(?:\.\d+)?$/,AB=/^(?:true|false)$/i,LB=/^null$/i;var MB=/^undefined$/i;var PB=/^[^A-Z]*$/,EB=/^[^a-z]*$/,dG$=/^[0-9a-fA-F]*$/;function cW($,J){return new RegExp(`^[A-Za-z0-9+/]{${$}}${J}$`)}function lW($){return new RegExp(`^[A-Za-z0-9_-]{${$}}$`)}var pG$=/^[0-9a-fA-F]{32}$/,nG$=cW(22,"=="),iG$=lW(22),oG$=/^[0-9a-fA-F]{40}$/,rG$=cW(27,"="),aG$=lW(27),tG$=/^[0-9a-fA-F]{64}$/,sG$=cW(43,"="),eG$=lW(43),$3$=/^[0-9a-fA-F]{96}$/,J3$=cW(64,""),W3$=lW(64),X3$=/^[0-9a-fA-F]{128}$/,Q3$=cW(86,"=="),Y3$=lW(86);var v$=M("$ZodCheck",($,J)=>{var W;$._zod??($._zod={}),$._zod.def=J,(W=$._zod).onattach??(W.onattach=[])}),E2={number:"number",bigint:"bigint",object:"date"},P7=M("$ZodCheckLessThan",($,J)=>{v$.init($,J);let W=E2[typeof J.value];$._zod.onattach.push((Q)=>{let X=Q._zod.bag,Y=(J.inclusive?X.maximum:X.exclusiveMaximum)??Number.POSITIVE_INFINITY;if(J.value<Y)if(J.inclusive)X.maximum=J.value;else X.exclusiveMaximum=J.value}),$._zod.check=(Q)=>{if(J.inclusive?Q.value<=J.value:Q.value<J.value)return;Q.issues.push({origin:W,code:"too_big",maximum:typeof J.value==="object"?J.value.getTime():J.value,input:Q.value,inclusive:J.inclusive,inst:$,continue:!J.abort})}}),E7=M("$ZodCheckGreaterThan",($,J)=>{v$.init($,J);let W=E2[typeof J.value];$._zod.onattach.push((Q)=>{let X=Q._zod.bag,Y=(J.inclusive?X.minimum:X.exclusiveMinimum)??Number.NEGATIVE_INFINITY;if(J.value>Y)if(J.inclusive)X.minimum=J.value;else X.exclusiveMinimum=J.value}),$._zod.check=(Q)=>{if(J.inclusive?Q.value>=J.value:Q.value>J.value)return;Q.issues.push({origin:W,code:"too_small",minimum:typeof J.value==="object"?J.value.getTime():J.value,input:Q.value,inclusive:J.inclusive,inst:$,continue:!J.abort})}}),SB=M("$ZodCheckMultipleOf",($,J)=>{v$.init($,J),$._zod.onattach.push((W)=>{var Q;(Q=W._zod.bag).multipleOf??(Q.multipleOf=J.value)}),$._zod.check=(W)=>{if(typeof W.value!==typeof J.value)throw Error("Cannot mix number and bigint in multiple_of check.");if(typeof W.value==="bigint"?W.value%J.value===BigInt(0):gZ(W.value,J.value)===0)return;W.issues.push({origin:typeof W.value,code:"not_multiple_of",divisor:J.value,input:W.value,inst:$,continue:!J.abort})}}),TB=M("$ZodCheckNumberFormat",($,J)=>{v$.init($,J),J.format=J.format||"float64";let W=J.format?.includes("int"),Q=W?"int":"number",[X,Y]=dZ[J.format];$._zod.onattach.push((U)=>{let G=U._zod.bag;if(G.format=J.format,G.minimum=X,G.maximum=Y,W)G.pattern=VB}),$._zod.check=(U)=>{let G=U.value;if(W){if(!Number.isInteger(G)){U.issues.push({expected:Q,format:J.format,code:"invalid_type",continue:!1,input:G,inst:$});return}if(!Number.isSafeInteger(G)){if(G>0)U.issues.push({input:G,code:"too_big",maximum:Number.MAX_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:$,origin:Q,inclusive:!0,continue:!J.abort});else U.issues.push({input:G,code:"too_small",minimum:Number.MIN_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:$,origin:Q,inclusive:!0,continue:!J.abort});return}}if(G<X)U.issues.push({origin:"number",input:G,code:"too_small",minimum:X,inclusive:!0,inst:$,continue:!J.abort});if(G>Y)U.issues.push({origin:"number",input:G,code:"too_big",maximum:Y,inclusive:!0,inst:$,continue:!J.abort})}}),RB=M("$ZodCheckBigIntFormat",($,J)=>{v$.init($,J);let[W,Q]=pZ[J.format];$._zod.onattach.push((X)=>{let Y=X._zod.bag;Y.format=J.format,Y.minimum=W,Y.maximum=Q}),$._zod.check=(X)=>{let Y=X.value;if(Y<W)X.issues.push({origin:"bigint",input:Y,code:"too_small",minimum:W,inclusive:!0,inst:$,continue:!J.abort});if(Y>Q)X.issues.push({origin:"bigint",input:Y,code:"too_big",maximum:Q,inclusive:!0,inst:$,continue:!J.abort})}}),wB=M("$ZodCheckMaxSize",($,J)=>{var W;v$.init($,J),(W=$._zod.def).when??(W.when=(Q)=>{let X=Q.value;return!s1(X)&&X.size!==void 0}),$._zod.onattach.push((Q)=>{let X=Q._zod.bag.maximum??Number.POSITIVE_INFINITY;if(J.maximum<X)Q._zod.bag.maximum=J.maximum}),$._zod.check=(Q)=>{let X=Q.value;if(X.size<=J.maximum)return;Q.issues.push({origin:yW(X),code:"too_big",maximum:J.maximum,inclusive:!0,input:X,inst:$,continue:!J.abort})}}),CB=M("$ZodCheckMinSize",($,J)=>{var W;v$.init($,J),(W=$._zod.def).when??(W.when=(Q)=>{let X=Q.value;return!s1(X)&&X.size!==void 0}),$._zod.onattach.push((Q)=>{let X=Q._zod.bag.minimum??Number.NEGATIVE_INFINITY;if(J.minimum>X)Q._zod.bag.minimum=J.minimum}),$._zod.check=(Q)=>{let X=Q.value;if(X.size>=J.minimum)return;Q.issues.push({origin:yW(X),code:"too_small",minimum:J.minimum,inclusive:!0,input:X,inst:$,continue:!J.abort})}}),_B=M("$ZodCheckSizeEquals",($,J)=>{var W;v$.init($,J),(W=$._zod.def).when??(W.when=(Q)=>{let X=Q.value;return!s1(X)&&X.size!==void 0}),$._zod.onattach.push((Q)=>{let X=Q._zod.bag;X.minimum=J.size,X.maximum=J.size,X.size=J.size}),$._zod.check=(Q)=>{let X=Q.value,Y=X.size;if(Y===J.size)return;let U=Y>J.size;Q.issues.push({origin:yW(X),...U?{code:"too_big",maximum:J.size}:{code:"too_small",minimum:J.size},inclusive:!0,exact:!0,input:Q.value,inst:$,continue:!J.abort})}}),kB=M("$ZodCheckMaxLength",($,J)=>{var W;v$.init($,J),(W=$._zod.def).when??(W.when=(Q)=>{let X=Q.value;return!s1(X)&&X.length!==void 0}),$._zod.onattach.push((Q)=>{let X=Q._zod.bag.maximum??Number.POSITIVE_INFINITY;if(J.maximum<X)Q._zod.bag.maximum=J.maximum}),$._zod.check=(Q)=>{let X=Q.value;if(X.length<=J.maximum)return;let U=xW(X);Q.issues.push({origin:U,code:"too_big",maximum:J.maximum,inclusive:!0,input:X,inst:$,continue:!J.abort})}}),bB=M("$ZodCheckMinLength",($,J)=>{var W;v$.init($,J),(W=$._zod.def).when??(W.when=(Q)=>{let X=Q.value;return!s1(X)&&X.length!==void 0}),$._zod.onattach.push((Q)=>{let X=Q._zod.bag.minimum??Number.NEGATIVE_INFINITY;if(J.minimum>X)Q._zod.bag.minimum=J.minimum}),$._zod.check=(Q)=>{let X=Q.value;if(X.length>=J.minimum)return;let U=xW(X);Q.issues.push({origin:U,code:"too_small",minimum:J.minimum,inclusive:!0,input:X,inst:$,continue:!J.abort})}}),vB=M("$ZodCheckLengthEquals",($,J)=>{var W;v$.init($,J),(W=$._zod.def).when??(W.when=(Q)=>{let X=Q.value;return!s1(X)&&X.length!==void 0}),$._zod.onattach.push((Q)=>{let X=Q._zod.bag;X.minimum=J.length,X.maximum=J.length,X.length=J.length}),$._zod.check=(Q)=>{let X=Q.value,Y=X.length;if(Y===J.length)return;let U=xW(X),G=Y>J.length;Q.issues.push({origin:U,...G?{code:"too_big",maximum:J.length}:{code:"too_small",minimum:J.length},inclusive:!0,exact:!0,input:Q.value,inst:$,continue:!J.abort})}}),V8=M("$ZodCheckStringFormat",($,J)=>{var W,Q;if(v$.init($,J),$._zod.onattach.push((X)=>{let Y=X._zod.bag;if(Y.format=J.format,J.pattern)Y.patterns??(Y.patterns=new Set),Y.patterns.add(J.pattern)}),J.pattern)(W=$._zod).check??(W.check=(X)=>{if(J.pattern.lastIndex=0,J.pattern.test(X.value))return;X.issues.push({origin:"string",code:"invalid_format",format:J.format,input:X.value,...J.pattern?{pattern:J.pattern.toString()}:{},inst:$,continue:!J.abort})});else(Q=$._zod).check??(Q.check=()=>{})}),fB=M("$ZodCheckRegex",($,J)=>{V8.init($,J),$._zod.check=(W)=>{if(J.pattern.lastIndex=0,J.pattern.test(W.value))return;W.issues.push({origin:"string",code:"invalid_format",format:"regex",input:W.value,pattern:J.pattern.toString(),inst:$,continue:!J.abort})}}),yB=M("$ZodCheckLowerCase",($,J)=>{J.pattern??(J.pattern=PB),V8.init($,J)}),xB=M("$ZodCheckUpperCase",($,J)=>{J.pattern??(J.pattern=EB),V8.init($,J)}),gB=M("$ZodCheckIncludes",($,J)=>{v$.init($,J);let W=q4(J.includes),Q=new RegExp(typeof J.position==="number"?`^.{${J.position}}${W}`:W);J.pattern=Q,$._zod.onattach.push((X)=>{let Y=X._zod.bag;Y.patterns??(Y.patterns=new Set),Y.patterns.add(Q)}),$._zod.check=(X)=>{if(X.value.includes(J.includes,J.position))return;X.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:J.includes,input:X.value,inst:$,continue:!J.abort})}}),hB=M("$ZodCheckStartsWith",($,J)=>{v$.init($,J);let W=new RegExp(`^${q4(J.prefix)}.*`);J.pattern??(J.pattern=W),$._zod.onattach.push((Q)=>{let X=Q._zod.bag;X.patterns??(X.patterns=new Set),X.patterns.add(W)}),$._zod.check=(Q)=>{if(Q.value.startsWith(J.prefix))return;Q.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:J.prefix,input:Q.value,inst:$,continue:!J.abort})}}),uB=M("$ZodCheckEndsWith",($,J)=>{v$.init($,J);let W=new RegExp(`.*${q4(J.suffix)}$`);J.pattern??(J.pattern=W),$._zod.onattach.push((Q)=>{let X=Q._zod.bag;X.patterns??(X.patterns=new Set),X.patterns.add(W)}),$._zod.check=(Q)=>{if(Q.value.endsWith(J.suffix))return;Q.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:J.suffix,input:Q.value,inst:$,continue:!J.abort})}});function P2($,J,W){if($.issues.length)J.issues.push(...p6(W,$.issues))}var mB=M("$ZodCheckProperty",($,J)=>{v$.init($,J),$._zod.check=(W)=>{let Q=J.schema._zod.run({value:W.value[J.property],issues:[]},{});if(Q instanceof Promise)return Q.then((X)=>P2(X,W,J.property));P2(Q,W,J.property);return}}),cB=M("$ZodCheckMimeType",($,J)=>{v$.init($,J);let W=new Set(J.mime);$._zod.onattach.push((Q)=>{Q._zod.bag.mime=J.mime}),$._zod.check=(Q)=>{if(W.has(Q.value.type))return;Q.issues.push({code:"invalid_value",values:J.mime,input:Q.value.type,inst:$,continue:!J.abort})}}),lB=M("$ZodCheckOverwrite",($,J)=>{v$.init($,J),$._zod.check=(W)=>{W.value=J.tx(W.value)}});class S7{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 W=$.split(`
@@ -508,5 +508,5 @@ ${q5}`),process.exit(2)}};if($.kind==="config-show"||$.kind==="config-validate")
508
508
  `),process.exit(1)}ZX6().catch(($)=>{process.stderr.write(`fatal: ${$.message}
509
509
  `),process.exit(1)});
510
510
 
511
- //# debugId=9B1DDE5D3A0E830964756E2164756E21
511
+ //# debugId=90933FB757A3FF3564756E2164756E21
512
512
  //# sourceMappingURL=cli.js.map