From e49b65a60ace657804c0f2810ae1e5739b1c2688 Mon Sep 17 00:00:00 2001 From: BOT Date: Tue, 21 Jan 2025 14:49:26 +0000 Subject: [PATCH] publish site --- docs/assets/index-1TGJS-me.js | 19 +++++++++++++++++++ docs/assets/index-CvWdp5iJ.js | 18 ------------------ docs/index.html | 4 ++-- docs/sw.js | 2 +- docs/version.json | 2 +- 5 files changed, 23 insertions(+), 22 deletions(-) create mode 100644 docs/assets/index-1TGJS-me.js delete mode 100644 docs/assets/index-CvWdp5iJ.js diff --git a/docs/assets/index-1TGJS-me.js b/docs/assets/index-1TGJS-me.js new file mode 100644 index 0000000..9432f30 --- /dev/null +++ b/docs/assets/index-1TGJS-me.js @@ -0,0 +1,19 @@ +var sp=Object.defineProperty;var ap=(t,e,r)=>e in t?sp(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r;var no=(t,e,r)=>(ap(t,typeof e!="symbol"?e+"":e,r),r);(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))n(s);new MutationObserver(s=>{for(const o of s)if(o.type==="childList")for(const u of o.addedNodes)u.tagName==="LINK"&&u.rel==="modulepreload"&&n(u)}).observe(document,{childList:!0,subtree:!0});function r(s){const o={};return s.integrity&&(o.integrity=s.integrity),s.referrerPolicy&&(o.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?o.credentials="include":s.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function n(s){if(s.ep)return;s.ep=!0;const o=r(s);fetch(s.href,o)}})();function je(){}function _u(t){return t()}function Qo(){return Object.create(null)}function Ut(t){t.forEach(_u)}function Tu(t){return typeof t=="function"}function Mi(t,e){return t!=t?e==e:t!==e||t&&typeof t=="object"||typeof t=="function"}let pa;function Yo(t,e){return t===e?!0:(pa||(pa=document.createElement("a")),pa.href=e,t===pa.href)}function op(t){return Object.keys(t).length===0}function L(t,e){t.appendChild(e)}function H(t,e,r){t.insertBefore(e,r||null)}function Z(t){t.parentNode&&t.parentNode.removeChild(t)}function Ro(t,e){for(let r=0;rt.removeEventListener(e,r,n)}function C(t,e,r){r==null?t.removeAttribute(e):t.getAttribute(e)!==r&&t.setAttribute(e,r)}function lp(t){return Array.from(t.childNodes)}function ln(t,e){e=""+e,t.data!==e&&(t.data=e)}function Oe(t,e){t.value=e??""}function Re(t,e,r,n){r==null?t.style.removeProperty(e):t.style.setProperty(e,r,"")}function va(t,e,r){for(let n=0;n{const s=t.$$.callbacks[e];if(s){const o=up(e,r,{cancelable:n});return s.slice().forEach(u=>{u.call(t,o)}),!o.defaultPrevented}return!0}}const bi=[],_a=[];let gi=[];const mo=[],cp=Promise.resolve();let bo=!1;function fp(){bo||(bo=!0,cp.then(Su))}function dn(t){gi.push(t)}function dp(t){mo.push(t)}const so=new Set;let pi=0;function Su(){if(pi!==0)return;const t=fn;do{try{for(;pit.indexOf(n)===-1?e.push(n):r.push(n)),r.forEach(n=>n()),gi=e}const Ra=new Set;let $r;function bp(){$r={r:0,c:[],p:$r}}function yp(){$r.r||Ut($r.c),$r=$r.p}function Sr(t,e){t&&t.i&&(Ra.delete(t),t.i(e))}function Gr(t,e,r,n){if(t&&t.o){if(Ra.has(t))return;Ra.add(t),$r.c.push(()=>{Ra.delete(t),n&&(r&&t.d(1),n())}),t.o(e)}else n&&n()}function Ri(t){return(t==null?void 0:t.length)!==void 0?t:Array.from(t)}function hp(t,e,r){const n=t.$$.props[e];n!==void 0&&(t.$$.bound[n]=r,r(t.$$.ctx[n]))}function on(t){t&&t.c()}function hi(t,e,r){const{fragment:n,after_update:s}=t.$$;n&&n.m(e,r),dn(()=>{const o=t.$$.on_mount.map(_u).filter(Tu);t.$$.on_destroy?t.$$.on_destroy.push(...o):Ut(o),t.$$.on_mount=[]}),s.forEach(dn)}function Ei(t,e){const r=t.$$;r.fragment!==null&&(mp(r.after_update),Ut(r.on_destroy),r.fragment&&r.fragment.d(e),r.on_destroy=r.fragment=null,r.ctx=[])}function Ep(t,e){t.$$.dirty[0]===-1&&(bi.push(t),fp(),t.$$.dirty.fill(0)),t.$$.dirty[e/31|0]|=1<{const g=h.length?h[0]:p;return c.ctx&&s(c.ctx[y],c.ctx[y]=g)&&(!c.skip_bound&&c.bound[y]&&c.bound[y](g),d&&Ep(t,y)),p}):[],c.update(),d=!0,Ut(c.before_update),c.fragment=n?n(c.ctx):!1,e.target){if(e.hydrate){const y=lp(e.target);c.fragment&&c.fragment.l(y),y.forEach(Z)}else c.fragment&&c.fragment.c();e.intro&&Sr(t.$$.fragment),hi(t,e.target,e.anchor),Su()}un(f)}class Gi{constructor(){no(this,"$$");no(this,"$$set")}$destroy(){Ei(this,1),this.$destroy=je}$on(e,r){if(!Tu(r))return je;const n=this.$$.callbacks[e]||(this.$$.callbacks[e]=[]);return n.push(r),()=>{const s=n.indexOf(r);s!==-1&&n.splice(s,1)}}$set(e){this.$$set&&!op(e)&&(this.$$.skip_bound=!0,this.$$set(e),this.$$.skip_bound=!1)}}const xp="4";typeof window<"u"&&(window.__svelte||(window.__svelte={v:new Set})).v.add(xp);var gp={VITE_API_ENDPOINT:"https://pppost-api.netlify.app/.netlify/functions",VITE_MASTODON_SERVER01:"Mastodon.cloud(prod) mastodon.cloud 7bh_j5Du2o0WVWcv_vyMf-MVwZuIOHWJBXw0zq6Owis",VITE_MASTODON_SERVER02:"Mstdn.jp mstdn.jp gIAagB7-8KP6XEW1xHW3Wh3UjOH9A-ircwMlZX-80xw",VITE_TWITTER_REDIRECT_URL:"https://amay077.github.io/pppost",BASE_URL:"./",MODE:"production",DEV:!1,PROD:!0,SSR:!1};const wt=(()=>{const t=["Mastodon.cloud(prod) mastodon.cloud 7bh_j5Du2o0WVWcv_vyMf-MVwZuIOHWJBXw0zq6Owis","Mstdn.jp mstdn.jp gIAagB7-8KP6XEW1xHW3Wh3UjOH9A-ircwMlZX-80xw",gp.VITE_MASTODON_SERVER03].filter(e=>(e==null?void 0:e.length)>0).map(e=>{const[r,n,s]=`${e}`.split(" ");return{name:r,server:n,client_id:s}});return console.log(t),{API_ENDPOINT:"https://pppost-api.netlify.app/.netlify/functions",post_targets:{mastodon:t,twitter:{redirect_uri:"https://amay077.github.io/pppost"}}}})();console.log(wt);function qi(t){localStorage.setItem(`ppp_setting_${t.type}`,JSON.stringify(t))}function ur(t){const e=localStorage.getItem(`ppp_setting_${t}`);return((e==null?void 0:e.length)??0)<=0?null:JSON.parse(e)}function _o(t){localStorage.removeItem(`ppp_setting_${t}`)}function Rp(t){localStorage.setItem("ppp_message",JSON.stringify(t))}function Ap(){const t=localStorage.getItem("ppp_message");return((t==null?void 0:t.length)??0)<=0?null:JSON.parse(t)}function el(t,e,r){const n=t.slice();return n[12]=e[r],n}function vp(t){let e,r;return{c(){e=Le("svg"),r=Le("path"),C(r,"fill-rule","evenodd"),C(r,"d","M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z"),C(e,"xmlns","http://www.w3.org/2000/svg"),C(e,"width","18"),C(e,"height","18"),C(e,"fill","currentColor"),C(e,"class","bi bi-chevron-down"),C(e,"viewBox","0 0 16 16")},m(n,s){H(n,e,s),L(e,r)},d(n){n&&Z(e)}}}function _p(t){let e,r;return{c(){e=Le("svg"),r=Le("path"),C(r,"fill-rule","evenodd"),C(r,"d","M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708z"),C(e,"xmlns","http://www.w3.org/2000/svg"),C(e,"width","18"),C(e,"height","18"),C(e,"fill","currentColor"),C(e,"class","bi bi-chevron-right"),C(e,"viewBox","0 0 16 16")},m(n,s){H(n,e,s),L(e,r)},d(n){n&&Z(e)}}}function tl(t){let e;function r(o,u){return o[3]!=null?wp:Tp}let n=r(t),s=n(t);return{c(){e=U("div"),s.c(),C(e,"class","p-1")},m(o,u){H(o,e,u),s.m(e,null)},p(o,u){n===(n=r(o))&&s?s.p(o,u):(s.d(1),s=n(o),s&&(s.c(),s.m(e,null)))},d(o){o&&Z(e),s.d()}}}function Tp(t){let e,r,n,s,o,u,l,f,c,d,y,p,h,g,R,A,_,S,B,V,j=Ri(t[5]),q=[];for(let X=0;Xt[10].call(u)),C(f,"class","btn btn-sm btn-primary"),Re(f,"width","60px"),C(o,"class","d-flex flex-row gap-1"),C(r,"class","d-flex flex-column gap-1"),C(g,"class","form-control form-control-sm"),C(g,"type","text"),C(A,"class","btn btn-sm btn-primary"),A.disabled=S=((X=t[2])==null?void 0:X.length)<=0,Re(A,"width","60px"),C(h,"class","d-flex flex-row gap-1"),C(d,"class","d-flex flex-column gap-1"),C(e,"class","d-flex flex-column gap-1")},m(X,oe){H(X,e,oe),L(e,r),L(r,n),L(r,s),L(r,o),L(o,u);for(let ce=0;ce{const R=o.find(_=>_.server===u);if(R==null){console.error("onApplyMastodonAccessToken -> settings:",R);return}const A=`https://${R.server}/oauth/authorize?client_id=${R.client_id}&response_type=code&redirect_uri=urn:ietf:wg:oauth:2.0:oob&scope=read+write`;window.open(A,"_blank")},d=async()=>{console.log("onApplyMastodonAccessToken -> mastodonCode:",l);const R=o.find(S=>S.server===u);if(R==null){console.error("onApplyMastodonAccessToken -> settings:",R);return}const A=await fetch(`${wt.API_ENDPOINT}/mastodon_token?server=${R.server}&code=${l}`);if(!A.ok){console.error("failed to fetch:",A);return}const _=await A.json();r(3,f={type:"mastodon",title:"Mastodon",enabled:!0,server:R.server,token_data:_}),qi(f),n("onChange"),alert("Mastodon に接続しました。")},y=()=>{r(0,s=!s)},p=()=>{r(3,f=null),_o("mastodon"),n("onChange")};function h(){u=wu(this),r(1,u),r(5,o)}function g(){l=this.value,r(2,l)}return[s,u,l,f,n,o,c,d,y,p,h,g]}class Sp extends Gi{constructor(e){super(),$i(this,e,Lp,Cp,Mi,{})}}var K=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function kp(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function ku(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var r=function n(){return this instanceof n?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};r.prototype=e.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(t).forEach(function(n){var s=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(r,n,s.get?s:{enumerable:!0,get:function(){return t[n]}})}),r}var pn={},ui={},To={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.DisallowedDomainError=t.UnsupportedDomainError=t.ReservedHandleError=t.InvalidHandleError=t.isValidTld=t.isValidHandle=t.normalizeAndEnsureValidHandle=t.normalizeHandle=t.ensureValidHandleRegex=t.ensureValidHandle=t.DISALLOWED_TLDS=t.INVALID_HANDLE=void 0,t.INVALID_HANDLE="handle.invalid",t.DISALLOWED_TLDS=[".local",".arpa",".invalid",".localhost",".internal",".example",".alt",".onion"];const e=y=>{if(!/^[a-zA-Z0-9.-]*$/.test(y))throw new l("Disallowed characters in handle (ASCII letters, digits, dashes, periods only)");if(y.length>253)throw new l("Handle is too long (253 chars max)");const p=y.split(".");if(p.length<2)throw new l("Handle domain needs at least two parts");for(let h=0;h63)throw new l("Handle part too long (max 63 chars)");if(g.endsWith("-")||g.startsWith("-"))throw new l("Handle parts can not start or end with hyphens");if(h+1==p.length&&!/^[a-zA-Z]/.test(g))throw new l("Handle final component (TLD) must start with ASCII letter")}};t.ensureValidHandle=e;const r=y=>{if(!/^([a-zA-Z0-9]([a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]([a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?$/.test(y))throw new l("Handle didn't validate via regex");if(y.length>253)throw new l("Handle is too long (253 chars max)")};t.ensureValidHandleRegex=r;const n=y=>y.toLowerCase();t.normalizeHandle=n;const s=y=>{const p=(0,t.normalizeHandle)(y);return(0,t.ensureValidHandle)(p),p};t.normalizeAndEnsureValidHandle=s;const o=y=>{try{(0,t.ensureValidHandle)(y)}catch(p){if(p instanceof l)return!1;throw p}return!0};t.isValidHandle=o;const u=y=>!t.DISALLOWED_TLDS.some(p=>y.endsWith(p));t.isValidTld=u;class l extends Error{}t.InvalidHandleError=l;class f extends Error{}t.ReservedHandleError=f;class c extends Error{}t.UnsupportedDomainError=c;class d extends Error{}t.DisallowedDomainError=d})(To);var cr={};Object.defineProperty(cr,"__esModule",{value:!0});cr.InvalidDidError=cr.ensureValidDidRegex=cr.ensureValidDid=void 0;const Dp=t=>{if(!/^[a-zA-Z0-9._:%-]*$/.test(t))throw new ar("Disallowed characters in DID (ASCII letters, digits, and a couple other characters only)");const e=t.split(":");if(e.length<3)throw new ar("DID requires prefix, method, and method-specific content");if(e[0]!="did")throw new ar('DID requires "did:" prefix');if(!/^[a-z]+$/.test(e[1]))throw new ar("DID method must be lower-case letters");if(t.endsWith(":")||t.endsWith("%"))throw new ar('DID can not end with ":" or "%"');if(t.length>2*1024)throw new ar("DID is too long (2048 chars max)")};cr.ensureValidDid=Dp;const Bp=t=>{if(!/^did:[a-z]+:[a-zA-Z0-9._:%-]*[a-zA-Z0-9._-]$/.test(t))throw new ar("DID didn't validate via regex");if(t.length>2*1024)throw new ar("DID is too long (2048 chars max)")};cr.ensureValidDidRegex=Bp;class ar extends Error{}cr.InvalidDidError=ar;var wo={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.InvalidNsidError=t.ensureValidNsidRegex=t.ensureValidNsid=t.NSID=void 0;class e{static parse(u){return new e(u)}static create(u,l){const f=[...u.split(".").reverse(),l].join(".");return new e(f)}static isValid(u){try{return e.parse(u),!0}catch{return!1}}constructor(u){Object.defineProperty(this,"segments",{enumerable:!0,configurable:!0,writable:!0,value:[]}),(0,t.ensureValidNsid)(u),this.segments=u.split(".")}get authority(){return this.segments.slice(0,this.segments.length-1).reverse().join(".")}get name(){return this.segments.at(this.segments.length-1)}toString(){return this.segments.join(".")}}t.NSID=e;const r=o=>{const u=o;if(!/^[a-zA-Z0-9.-]*$/.test(u))throw new s("Disallowed characters in NSID (ASCII letters, digits, dashes, periods only)");if(u.length>317)throw new s("NSID is too long (317 chars max)");const l=u.split(".");if(l.length<3)throw new s("NSID needs at least three parts");for(let f=0;f63)throw new s("NSID part too long (max 63 chars)");if(c.endsWith("-")||c.startsWith("-"))throw new s("NSID parts can not start or end with hyphen");if(/^[0-9]/.test(c)&&f==0)throw new s("NSID first part may not start with a digit");if(!/^[a-zA-Z]+$/.test(c)&&f+1==l.length)throw new s("NSID name part must be only letters")}};t.ensureValidNsid=r;const n=o=>{if(!/^[a-zA-Z]([a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(\.[a-zA-Z0-9]([a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(\.[a-zA-Z]([a-zA-Z]{0,61}[a-zA-Z])?)$/.test(o))throw new s("NSID didn't validate via regex");if(o.length>317)throw new s("NSID is too long (317 chars max)")};t.ensureValidNsidRegex=n;class s extends Error{}t.InvalidNsidError=s})(wo);var Du={},Ai={};Object.defineProperty(Ai,"__esModule",{value:!0});Ai.ensureValidAtUriRegex=Ai.ensureValidAtUri=void 0;const Bu=To,Pu=cr,Ku=wo,Pp=t=>{const e=t.split("#");if(e.length>2)throw new Error('ATURI can have at most one "#", separating fragment out');const r=e[1]||null;if(t=e[0],!/^[a-zA-Z0-9._~:@!$&')(*+,;=%/-]*$/.test(t))throw new Error("Disallowed characters in ATURI (ASCII)");const n=t.split("/");if(n.length>=3&&(n[0]!="at:"||n[1].length!=0))throw new Error('ATURI must start with "at://"');if(n.length<3)throw new Error("ATURI requires at least method and authority sections");try{n[2].startsWith("did:")?(0,Pu.ensureValidDid)(n[2]):(0,Bu.ensureValidHandle)(n[2])}catch{throw new Error("ATURI authority must be a valid handle or DID")}if(n.length>=4){if(n[3].length==0)throw new Error("ATURI can not have a slash after authority without a path segment");try{(0,Ku.ensureValidNsid)(n[3])}catch{throw new Error("ATURI requires first path segment (if supplied) to be valid NSID")}}if(n.length>=5&&n[4].length==0)throw new Error("ATURI can not have a slash after collection, unless record key is provided");if(n.length>=6)throw new Error("ATURI path can have at most two parts, and no trailing slash");if(e.length>=2&&r==null)throw new Error("ATURI fragment must be non-empty and start with slash");if(r!=null){if(r.length==0||r[0]!="/")throw new Error("ATURI fragment must be non-empty and start with slash");if(!/^\/[a-zA-Z0-9._~:@!$&')(*+,;=%[\]/-]*$/.test(r))throw new Error("Disallowed characters in ATURI fragment (ASCII)")}if(t.length>8*1024)throw new Error("ATURI is far too long")};Ai.ensureValidAtUri=Pp;const Kp=t=>{const e=/^at:\/\/(?[a-zA-Z0-9._:%-]+)(\/(?[a-zA-Z0-9-.]+)(\/(?[a-zA-Z0-9._~:@!$&%')(*+,;=-]+))?)?(#(?\/[a-zA-Z0-9._~:@!$&%')(*+,;=\-[\]/\\]*))?$/,r=t.match(e);if(!r||!r.groups)throw new Error("ATURI didn't validate via regex");const n=r.groups;try{(0,Bu.ensureValidHandleRegex)(n.authority)}catch{try{(0,Pu.ensureValidDidRegex)(n.authority)}catch{throw new Error("ATURI authority must be a valid handle or DID")}}if(n.collection)try{(0,Ku.ensureValidNsidRegex)(n.collection)}catch{throw new Error("ATURI collection path segment must be a valid NSID")}if(t.length>8*1024)throw new Error("ATURI is far too long")};Ai.ensureValidAtUriRegex=Kp;(function(t){var e=K&&K.__createBinding||(Object.create?function(l,f,c,d){d===void 0&&(d=c);var y=Object.getOwnPropertyDescriptor(f,c);(!y||("get"in y?!f.__esModule:y.writable||y.configurable))&&(y={enumerable:!0,get:function(){return f[c]}}),Object.defineProperty(l,d,y)}:function(l,f,c,d){d===void 0&&(d=c),l[d]=f[c]}),r=K&&K.__exportStar||function(l,f){for(var c in l)c!=="default"&&!Object.prototype.hasOwnProperty.call(f,c)&&e(f,l,c)};Object.defineProperty(t,"__esModule",{value:!0}),t.AtUri=t.ATP_URI_REGEX=void 0,r(Ai,t),t.ATP_URI_REGEX=/^(at:\/\/)?((?:did:[a-z0-9:%-]+)|(?:[a-z0-9][a-z0-9.:-]*))(\/[^?#\s]*)?(\?[^#\s]+)?(#[^\s]+)?$/i;const n=/^(\/[^?#\s]*)?(\?[^#\s]+)?(#[^\s]+)?$/i;class s{constructor(f,c){Object.defineProperty(this,"hash",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"host",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"pathname",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"searchParams",{enumerable:!0,configurable:!0,writable:!0,value:void 0});let d;if(c){if(d=o(c),!d)throw new Error(`Invalid at uri: ${c}`);const y=u(f);if(!y)throw new Error(`Invalid path: ${f}`);Object.assign(d,y)}else if(d=o(f),!d)throw new Error(`Invalid at uri: ${f}`);this.hash=d.hash,this.host=d.host,this.pathname=d.pathname,this.searchParams=d.searchParams}static make(f,c,d){let y=f;return c&&(y+="/"+c),d&&(y+="/"+d),new s(y)}get protocol(){return"at:"}get origin(){return`at://${this.host}`}get hostname(){return this.host}set hostname(f){this.host=f}get search(){return this.searchParams.toString()}set search(f){this.searchParams=new URLSearchParams(f)}get collection(){return this.pathname.split("/").filter(Boolean)[0]||""}set collection(f){const c=this.pathname.split("/").filter(Boolean);c[0]=f,this.pathname=c.join("/")}get rkey(){return this.pathname.split("/").filter(Boolean)[1]||""}set rkey(f){const c=this.pathname.split("/").filter(Boolean);c[0]||(c[0]="undefined"),c[1]=f,this.pathname=c.join("/")}get href(){return this.toString()}toString(){let f=this.pathname||"/";f.startsWith("/")||(f=`/${f}`);let c=this.searchParams.toString();c&&!c.startsWith("?")&&(c=`?${c}`);let d=this.hash;return d&&!d.startsWith("#")&&(d=`#${d}`),`at://${this.host}${f}${c}${d}`}}t.AtUri=s;function o(l){const f=t.ATP_URI_REGEX.exec(l);if(f)return{hash:f[5]||"",host:f[2]||"",pathname:f[3]||"",searchParams:new URLSearchParams(f[4]||"")}}function u(l){const f=n.exec(l);if(f)return{hash:f[3]||"",pathname:f[1]||"",searchParams:new URLSearchParams(f[2]||"")}}})(Du);var Uu={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.InvalidTidError=t.isValidTid=t.ensureValidTid=void 0;const e=s=>{if(s.length!=13)throw new n("TID must be 13 characters");if(!/^[234567abcdefghij][234567abcdefghijklmnopqrstuvwxyz]{12}$/.test(s))throw new n("TID syntax not valid (regex)")};t.ensureValidTid=e;const r=s=>{try{(0,t.ensureValidTid)(s)}catch(o){if(o instanceof n)return!1;throw o}return!0};t.isValidTid=r;class n extends Error{}t.InvalidTidError=n})(Uu);var Vu={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.InvalidRecordKeyError=t.isValidRecordKey=t.ensureValidRecordKey=void 0;const e=s=>{if(s.length>512||s.length<1)throw new n("record key must be 1 to 512 characters");if(!/^[a-zA-Z0-9_~.:-]{1,512}$/.test(s))throw new n("record key syntax not valid (regex)");if(s=="."||s=="..")throw new n('record key can not be "." or ".."')};t.ensureValidRecordKey=e;const r=s=>{try{(0,t.ensureValidRecordKey)(s)}catch(o){if(o instanceof n)return!1;throw o}return!0};t.isValidRecordKey=r;class n extends Error{}t.InvalidRecordKeyError=n})(Vu);var Iu={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.InvalidDatetimeError=t.normalizeDatetimeAlways=t.normalizeDatetime=t.isValidDatetime=t.ensureValidDatetime=void 0;const e=u=>{const l=new Date(u);if(isNaN(l.getTime()))throw new o("datetime did not parse as ISO 8601");if(l.toISOString().startsWith("-"))throw new o("datetime normalized to a negative time");if(!/^[0-9]{4}-[01][0-9]-[0-3][0-9]T[0-2][0-9]:[0-6][0-9]:[0-6][0-9](.[0-9]{1,20})?(Z|([+-][0-2][0-9]:[0-5][0-9]))$/.test(u))throw new o("datetime didn't validate via regex");if(u.length>64)throw new o("datetime is too long (64 chars max)");if(u.endsWith("-00:00"))throw new o('datetime can not use "-00:00" for UTC timezone');if(u.startsWith("000"))throw new o("datetime so close to year zero not allowed")};t.ensureValidDatetime=e;const r=u=>{try{(0,t.ensureValidDatetime)(u)}catch(l){if(l instanceof o)return!1;throw l}return!0};t.isValidDatetime=r;const n=u=>{if((0,t.isValidDatetime)(u)){const c=new Date(u).toISOString();if((0,t.isValidDatetime)(c))return c}if(!/.*(([+-]\d\d:?\d\d)|[a-zA-Z])$/.test(u)){const c=new Date(u+"Z");if(!isNaN(c.getTime())){const d=c.toISOString();if((0,t.isValidDatetime)(d))return d}}const l=new Date(u);if(isNaN(l.getTime()))throw new o("datetime did not parse as any timestamp format");const f=l.toISOString();if((0,t.isValidDatetime)(f))return f;throw new o("datetime normalized to invalid timestamp string")};t.normalizeDatetime=n;const s=u=>{try{return(0,t.normalizeDatetime)(u)}catch(l){if(l instanceof o)return new Date(0).toISOString();throw l}};t.normalizeDatetimeAlways=s;class o extends Error{}t.InvalidDatetimeError=o})(Iu);(function(t){var e=K&&K.__createBinding||(Object.create?function(n,s,o,u){u===void 0&&(u=o);var l=Object.getOwnPropertyDescriptor(s,o);(!l||("get"in l?!s.__esModule:l.writable||l.configurable))&&(l={enumerable:!0,get:function(){return s[o]}}),Object.defineProperty(n,u,l)}:function(n,s,o,u){u===void 0&&(u=o),n[u]=s[o]}),r=K&&K.__exportStar||function(n,s){for(var o in n)o!=="default"&&!Object.prototype.hasOwnProperty.call(s,o)&&e(s,n,o)};Object.defineProperty(t,"__esModule",{value:!0}),r(To,t),r(cr,t),r(wo,t),r(Du,t),r(Uu,t),r(Vu,t),r(Iu,t)})(ui);var yn={},ao={},ci={},yo={},Ft={},Ua={},hn={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.getParsedType=t.ZodParsedType=t.objectUtil=t.util=void 0;var e;(function(n){n.assertEqual=l=>l;function s(l){}n.assertIs=s;function o(l){throw new Error}n.assertNever=o,n.arrayToEnum=l=>{const f={};for(const c of l)f[c]=c;return f},n.getValidEnumValues=l=>{const f=n.objectKeys(l).filter(d=>typeof l[l[d]]!="number"),c={};for(const d of f)c[d]=l[d];return n.objectValues(c)},n.objectValues=l=>n.objectKeys(l).map(function(f){return l[f]}),n.objectKeys=typeof Object.keys=="function"?l=>Object.keys(l):l=>{const f=[];for(const c in l)Object.prototype.hasOwnProperty.call(l,c)&&f.push(c);return f},n.find=(l,f)=>{for(const c of l)if(f(c))return c},n.isInteger=typeof Number.isInteger=="function"?l=>Number.isInteger(l):l=>typeof l=="number"&&isFinite(l)&&Math.floor(l)===l;function u(l,f=" | "){return l.map(c=>typeof c=="string"?`'${c}'`:c).join(f)}n.joinValues=u,n.jsonStringifyReplacer=(l,f)=>typeof f=="bigint"?f.toString():f})(e=t.util||(t.util={})),function(n){n.mergeShapes=(s,o)=>({...s,...o})}(t.objectUtil||(t.objectUtil={})),t.ZodParsedType=e.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]);const r=n=>{switch(typeof n){case"undefined":return t.ZodParsedType.undefined;case"string":return t.ZodParsedType.string;case"number":return isNaN(n)?t.ZodParsedType.nan:t.ZodParsedType.number;case"boolean":return t.ZodParsedType.boolean;case"function":return t.ZodParsedType.function;case"bigint":return t.ZodParsedType.bigint;case"symbol":return t.ZodParsedType.symbol;case"object":return Array.isArray(n)?t.ZodParsedType.array:n===null?t.ZodParsedType.null:n.then&&typeof n.then=="function"&&n.catch&&typeof n.catch=="function"?t.ZodParsedType.promise:typeof Map<"u"&&n instanceof Map?t.ZodParsedType.map:typeof Set<"u"&&n instanceof Set?t.ZodParsedType.set:typeof Date<"u"&&n instanceof Date?t.ZodParsedType.date:t.ZodParsedType.object;default:return t.ZodParsedType.unknown}};t.getParsedType=r})(hn);var Xt={};Object.defineProperty(Xt,"__esModule",{value:!0});Xt.ZodError=Xt.quotelessJson=Xt.ZodIssueCode=void 0;const Ou=hn;Xt.ZodIssueCode=Ou.util.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"]);const Up=t=>JSON.stringify(t,null,2).replace(/"([^"]+)":/g,"$1:");Xt.quotelessJson=Up;class mn extends Error{constructor(e){super(),this.issues=[],this.addIssue=n=>{this.issues=[...this.issues,n]},this.addIssues=(n=[])=>{this.issues=[...this.issues,...n]};const r=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,r):this.__proto__=r,this.name="ZodError",this.issues=e}get errors(){return this.issues}format(e){const r=e||function(o){return o.message},n={_errors:[]},s=o=>{for(const u of o.issues)if(u.code==="invalid_union")u.unionErrors.map(s);else if(u.code==="invalid_return_type")s(u.returnTypeError);else if(u.code==="invalid_arguments")s(u.argumentsError);else if(u.path.length===0)n._errors.push(r(u));else{let l=n,f=0;for(;fr.message){const r={},n=[];for(const s of this.issues)s.path.length>0?(r[s.path[0]]=r[s.path[0]]||[],r[s.path[0]].push(e(s))):n.push(e(s));return{formErrors:n,fieldErrors:r}}get formErrors(){return this.flatten()}}Xt.ZodError=mn;mn.create=t=>new mn(t);Object.defineProperty(Ua,"__esModule",{value:!0});const Nr=hn,it=Xt,Vp=(t,e)=>{let r;switch(t.code){case it.ZodIssueCode.invalid_type:t.received===Nr.ZodParsedType.undefined?r="Required":r=`Expected ${t.expected}, received ${t.received}`;break;case it.ZodIssueCode.invalid_literal:r=`Invalid literal value, expected ${JSON.stringify(t.expected,Nr.util.jsonStringifyReplacer)}`;break;case it.ZodIssueCode.unrecognized_keys:r=`Unrecognized key(s) in object: ${Nr.util.joinValues(t.keys,", ")}`;break;case it.ZodIssueCode.invalid_union:r="Invalid input";break;case it.ZodIssueCode.invalid_union_discriminator:r=`Invalid discriminator value. Expected ${Nr.util.joinValues(t.options)}`;break;case it.ZodIssueCode.invalid_enum_value:r=`Invalid enum value. Expected ${Nr.util.joinValues(t.options)}, received '${t.received}'`;break;case it.ZodIssueCode.invalid_arguments:r="Invalid function arguments";break;case it.ZodIssueCode.invalid_return_type:r="Invalid function return type";break;case it.ZodIssueCode.invalid_date:r="Invalid date";break;case it.ZodIssueCode.invalid_string:typeof t.validation=="object"?"includes"in t.validation?(r=`Invalid input: must include "${t.validation.includes}"`,typeof t.validation.position=="number"&&(r=`${r} at one or more positions greater than or equal to ${t.validation.position}`)):"startsWith"in t.validation?r=`Invalid input: must start with "${t.validation.startsWith}"`:"endsWith"in t.validation?r=`Invalid input: must end with "${t.validation.endsWith}"`:Nr.util.assertNever(t.validation):t.validation!=="regex"?r=`Invalid ${t.validation}`:r="Invalid";break;case it.ZodIssueCode.too_small:t.type==="array"?r=`Array must contain ${t.exact?"exactly":t.inclusive?"at least":"more than"} ${t.minimum} element(s)`:t.type==="string"?r=`String must contain ${t.exact?"exactly":t.inclusive?"at least":"over"} ${t.minimum} character(s)`:t.type==="number"?r=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`:t.type==="date"?r=`Date must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(t.minimum))}`:r="Invalid input";break;case it.ZodIssueCode.too_big:t.type==="array"?r=`Array must contain ${t.exact?"exactly":t.inclusive?"at most":"less than"} ${t.maximum} element(s)`:t.type==="string"?r=`String must contain ${t.exact?"exactly":t.inclusive?"at most":"under"} ${t.maximum} character(s)`:t.type==="number"?r=`Number must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="bigint"?r=`BigInt must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="date"?r=`Date must be ${t.exact?"exactly":t.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(t.maximum))}`:r="Invalid input";break;case it.ZodIssueCode.custom:r="Invalid input";break;case it.ZodIssueCode.invalid_intersection_types:r="Intersection results could not be merged";break;case it.ZodIssueCode.not_multiple_of:r=`Number must be a multiple of ${t.multipleOf}`;break;case it.ZodIssueCode.not_finite:r="Number must be finite";break;default:r=e.defaultError,Nr.util.assertNever(t)}return{message:r}};Ua.default=Vp;var Ip=K&&K.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(Ft,"__esModule",{value:!0});Ft.getErrorMap=Ft.setErrorMap=Ft.defaultErrorMap=void 0;const ju=Ip(Ua);Ft.defaultErrorMap=ju.default;let Nu=ju.default;function Op(t){Nu=t}Ft.setErrorMap=Op;function jp(){return Nu}Ft.getErrorMap=jp;var Co={};(function(t){var e=K&&K.__importDefault||function(h){return h&&h.__esModule?h:{default:h}};Object.defineProperty(t,"__esModule",{value:!0}),t.isAsync=t.isValid=t.isDirty=t.isAborted=t.OK=t.DIRTY=t.INVALID=t.ParseStatus=t.addIssueToContext=t.EMPTY_PATH=t.makeIssue=void 0;const r=Ft,n=e(Ua),s=h=>{const{data:g,path:R,errorMaps:A,issueData:_}=h,S=[...R,..._.path||[]],B={..._,path:S};if(_.message!==void 0)return{..._,path:S,message:_.message};let V="";const j=A.filter(q=>!!q).slice().reverse();for(const q of j)V=q(B,{data:g,defaultError:V}).message;return{..._,path:S,message:V}};t.makeIssue=s,t.EMPTY_PATH=[];function o(h,g){const R=(0,r.getErrorMap)(),A=(0,t.makeIssue)({issueData:g,data:h.data,path:h.path,errorMaps:[h.common.contextualErrorMap,h.schemaErrorMap,R,R===n.default?void 0:n.default].filter(_=>!!_)});h.common.issues.push(A)}t.addIssueToContext=o;class u{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(g,R){const A=[];for(const _ of R){if(_.status==="aborted")return t.INVALID;_.status==="dirty"&&g.dirty(),A.push(_.value)}return{status:g.value,value:A}}static async mergeObjectAsync(g,R){const A=[];for(const _ of R){const S=await _.key,B=await _.value;A.push({key:S,value:B})}return u.mergeObjectSync(g,A)}static mergeObjectSync(g,R){const A={};for(const _ of R){const{key:S,value:B}=_;if(S.status==="aborted"||B.status==="aborted")return t.INVALID;S.status==="dirty"&&g.dirty(),B.status==="dirty"&&g.dirty(),S.value!=="__proto__"&&(typeof B.value<"u"||_.alwaysSet)&&(A[S.value]=B.value)}return{status:g.value,value:A}}}t.ParseStatus=u,t.INVALID=Object.freeze({status:"aborted"});const l=h=>({status:"dirty",value:h});t.DIRTY=l;const f=h=>({status:"valid",value:h});t.OK=f;const c=h=>h.status==="aborted";t.isAborted=c;const d=h=>h.status==="dirty";t.isDirty=d;const y=h=>h.status==="valid";t.isValid=y;const p=h=>typeof Promise<"u"&&h instanceof Promise;t.isAsync=p})(Co);var Mu={};Object.defineProperty(Mu,"__esModule",{value:!0});var $u={},Gu={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.errorUtil=void 0,function(e){e.errToObj=r=>typeof r=="string"?{message:r}:r||{},e.toString=r=>typeof r=="string"?r:r==null?void 0:r.message}(t.errorUtil||(t.errorUtil={}))})(Gu);(function(t){var e=K&&K.__classPrivateFieldGet||function(v,a,b,E){if(b==="a"&&!E)throw new TypeError("Private accessor was defined without a getter");if(typeof a=="function"?v!==a||!E:!a.has(v))throw new TypeError("Cannot read private member from an object whose class did not declare it");return b==="m"?E:b==="a"?E.call(v):E?E.value:a.get(v)},r=K&&K.__classPrivateFieldSet||function(v,a,b,E,T){if(E==="m")throw new TypeError("Private method is not writable");if(E==="a"&&!T)throw new TypeError("Private accessor was defined without a setter");if(typeof a=="function"?v!==a||!T:!a.has(v))throw new TypeError("Cannot write private member to an object whose class did not declare it");return E==="a"?T.call(v,b):T?T.value=b:a.set(v,b),b},n,s;Object.defineProperty(t,"__esModule",{value:!0}),t.boolean=t.bigint=t.array=t.any=t.coerce=t.ZodFirstPartyTypeKind=t.late=t.ZodSchema=t.Schema=t.custom=t.ZodReadonly=t.ZodPipeline=t.ZodBranded=t.BRAND=t.ZodNaN=t.ZodCatch=t.ZodDefault=t.ZodNullable=t.ZodOptional=t.ZodTransformer=t.ZodEffects=t.ZodPromise=t.ZodNativeEnum=t.ZodEnum=t.ZodLiteral=t.ZodLazy=t.ZodFunction=t.ZodSet=t.ZodMap=t.ZodRecord=t.ZodTuple=t.ZodIntersection=t.ZodDiscriminatedUnion=t.ZodUnion=t.ZodObject=t.ZodArray=t.ZodVoid=t.ZodNever=t.ZodUnknown=t.ZodAny=t.ZodNull=t.ZodUndefined=t.ZodSymbol=t.ZodDate=t.ZodBoolean=t.ZodBigInt=t.ZodNumber=t.ZodString=t.datetimeRegex=t.ZodType=void 0,t.NEVER=t.void=t.unknown=t.union=t.undefined=t.tuple=t.transformer=t.symbol=t.string=t.strictObject=t.set=t.record=t.promise=t.preprocess=t.pipeline=t.ostring=t.optional=t.onumber=t.oboolean=t.object=t.number=t.nullable=t.null=t.never=t.nativeEnum=t.nan=t.map=t.literal=t.lazy=t.intersection=t.instanceof=t.function=t.enum=t.effect=t.discriminatedUnion=t.date=void 0;const o=Ft,u=Gu,l=Co,f=hn,c=Xt;class d{constructor(a,b,E,T){this._cachedPath=[],this.parent=a,this.data=b,this._path=E,this._key=T}get path(){return this._cachedPath.length||(this._key instanceof Array?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}const y=(v,a)=>{if((0,l.isValid)(a))return{success:!0,data:a.value};if(!v.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;const b=new c.ZodError(v.common.issues);return this._error=b,this._error}}};function p(v){if(!v)return{};const{errorMap:a,invalid_type_error:b,required_error:E,description:T}=v;if(a&&(b||E))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return a?{errorMap:a,description:T}:{errorMap:(I,P)=>{var W,J;const{message:de}=v;return I.code==="invalid_enum_value"?{message:de??P.defaultError}:typeof P.data>"u"?{message:(W=de??E)!==null&&W!==void 0?W:P.defaultError}:I.code!=="invalid_type"?{message:P.defaultError}:{message:(J=de??b)!==null&&J!==void 0?J:P.defaultError}},description:T}}class h{constructor(a){this.spa=this.safeParseAsync,this._def=a,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)}get description(){return this._def.description}_getType(a){return(0,f.getParsedType)(a.data)}_getOrReturnCtx(a,b){return b||{common:a.parent.common,data:a.data,parsedType:(0,f.getParsedType)(a.data),schemaErrorMap:this._def.errorMap,path:a.path,parent:a.parent}}_processInputParams(a){return{status:new l.ParseStatus,ctx:{common:a.parent.common,data:a.data,parsedType:(0,f.getParsedType)(a.data),schemaErrorMap:this._def.errorMap,path:a.path,parent:a.parent}}}_parseSync(a){const b=this._parse(a);if((0,l.isAsync)(b))throw new Error("Synchronous parse encountered promise.");return b}_parseAsync(a){const b=this._parse(a);return Promise.resolve(b)}parse(a,b){const E=this.safeParse(a,b);if(E.success)return E.data;throw E.error}safeParse(a,b){var E;const T={common:{issues:[],async:(E=b==null?void 0:b.async)!==null&&E!==void 0?E:!1,contextualErrorMap:b==null?void 0:b.errorMap},path:(b==null?void 0:b.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:a,parsedType:(0,f.getParsedType)(a)},w=this._parseSync({data:a,path:T.path,parent:T});return y(T,w)}async parseAsync(a,b){const E=await this.safeParseAsync(a,b);if(E.success)return E.data;throw E.error}async safeParseAsync(a,b){const E={common:{issues:[],contextualErrorMap:b==null?void 0:b.errorMap,async:!0},path:(b==null?void 0:b.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:a,parsedType:(0,f.getParsedType)(a)},T=this._parse({data:a,path:E.path,parent:E}),w=await((0,l.isAsync)(T)?T:Promise.resolve(T));return y(E,w)}refine(a,b){const E=T=>typeof b=="string"||typeof b>"u"?{message:b}:typeof b=="function"?b(T):b;return this._refinement((T,w)=>{const I=a(T),P=()=>w.addIssue({code:c.ZodIssueCode.custom,...E(T)});return typeof Promise<"u"&&I instanceof Promise?I.then(W=>W?!0:(P(),!1)):I?!0:(P(),!1)})}refinement(a,b){return this._refinement((E,T)=>a(E)?!0:(T.addIssue(typeof b=="function"?b(E,T):b),!1))}_refinement(a){return new Lt({schema:this,typeName:le.ZodEffects,effect:{type:"refinement",refinement:a}})}superRefine(a){return this._refinement(a)}optional(){return Vt.create(this,this._def)}nullable(){return wr.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return Be.create(this,this._def)}promise(){return di.create(this,this._def)}or(a){return ft.create([this,a],this._def)}and(a){return _r.create(this,a,this._def)}transform(a){return new Lt({...p(this._def),schema:this,typeName:le.ZodEffects,effect:{type:"transform",transform:a}})}default(a){const b=typeof a=="function"?a:()=>a;return new Wi({...p(this._def),innerType:this,defaultValue:b,typeName:le.ZodDefault})}brand(){return new ro({typeName:le.ZodBranded,type:this,...p(this._def)})}catch(a){const b=typeof a=="function"?a:()=>a;return new Ji({...p(this._def),innerType:this,catchValue:b,typeName:le.ZodCatch})}describe(a){const b=this.constructor;return new b({...this._def,description:a})}pipe(a){return Qi.create(this,a)}readonly(){return Yi.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}t.ZodType=h,t.Schema=h,t.ZodSchema=h;const g=/^c[^\s-]{8,}$/i,R=/^[0-9a-z]+$/,A=/^[0-9A-HJKMNP-TV-Z]{26}$/,_=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,S=/^[a-z0-9_-]{21}$/i,B=/^[-+]?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)?)??$/,V=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,j="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";let q;const X=/^(?:(?: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])$/,oe=/^(([a-f0-9]{1,4}:){7}|::([a-f0-9]{1,4}:){0,6}|([a-f0-9]{1,4}:){1}:([a-f0-9]{1,4}:){0,5}|([a-f0-9]{1,4}:){2}:([a-f0-9]{1,4}:){0,4}|([a-f0-9]{1,4}:){3}:([a-f0-9]{1,4}:){0,3}|([a-f0-9]{1,4}:){4}:([a-f0-9]{1,4}:){0,2}|([a-f0-9]{1,4}:){5}:([a-f0-9]{1,4}:){0,1})([a-f0-9]{1,4}|(((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))\.){3}((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2})))$/,ce=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,ie="((\\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])))",Q=new RegExp(`^${ie}$`);function ot(v){let a="([01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d";return v.precision?a=`${a}\\.\\d{${v.precision}}`:v.precision==null&&(a=`${a}(\\.\\d+)?`),a}function ze(v){return new RegExp(`^${ot(v)}$`)}function se(v){let a=`${ie}T${ot(v)}`;const b=[];return b.push(v.local?"Z?":"Z"),v.offset&&b.push("([+-]\\d{2}:?\\d{2})"),a=`${a}(${b.join("|")})`,new RegExp(`^${a}$`)}t.datetimeRegex=se;function F(v,a){return!!((a==="v4"||!a)&&X.test(v)||(a==="v6"||!a)&&oe.test(v))}class O extends h{_parse(a){if(this._def.coerce&&(a.data=String(a.data)),this._getType(a)!==f.ZodParsedType.string){const w=this._getOrReturnCtx(a);return(0,l.addIssueToContext)(w,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.string,received:w.parsedType}),l.INVALID}const E=new l.ParseStatus;let T;for(const w of this._def.checks)if(w.kind==="min")a.data.lengthw.value&&(T=this._getOrReturnCtx(a,T),(0,l.addIssueToContext)(T,{code:c.ZodIssueCode.too_big,maximum:w.value,type:"string",inclusive:!0,exact:!1,message:w.message}),E.dirty());else if(w.kind==="length"){const I=a.data.length>w.value,P=a.data.lengtha.test(T),{validation:b,code:c.ZodIssueCode.invalid_string,...u.errorUtil.errToObj(E)})}_addCheck(a){return new O({...this._def,checks:[...this._def.checks,a]})}email(a){return this._addCheck({kind:"email",...u.errorUtil.errToObj(a)})}url(a){return this._addCheck({kind:"url",...u.errorUtil.errToObj(a)})}emoji(a){return this._addCheck({kind:"emoji",...u.errorUtil.errToObj(a)})}uuid(a){return this._addCheck({kind:"uuid",...u.errorUtil.errToObj(a)})}nanoid(a){return this._addCheck({kind:"nanoid",...u.errorUtil.errToObj(a)})}cuid(a){return this._addCheck({kind:"cuid",...u.errorUtil.errToObj(a)})}cuid2(a){return this._addCheck({kind:"cuid2",...u.errorUtil.errToObj(a)})}ulid(a){return this._addCheck({kind:"ulid",...u.errorUtil.errToObj(a)})}base64(a){return this._addCheck({kind:"base64",...u.errorUtil.errToObj(a)})}ip(a){return this._addCheck({kind:"ip",...u.errorUtil.errToObj(a)})}datetime(a){var b,E;return typeof a=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:a}):this._addCheck({kind:"datetime",precision:typeof(a==null?void 0:a.precision)>"u"?null:a==null?void 0:a.precision,offset:(b=a==null?void 0:a.offset)!==null&&b!==void 0?b:!1,local:(E=a==null?void 0:a.local)!==null&&E!==void 0?E:!1,...u.errorUtil.errToObj(a==null?void 0:a.message)})}date(a){return this._addCheck({kind:"date",message:a})}time(a){return typeof a=="string"?this._addCheck({kind:"time",precision:null,message:a}):this._addCheck({kind:"time",precision:typeof(a==null?void 0:a.precision)>"u"?null:a==null?void 0:a.precision,...u.errorUtil.errToObj(a==null?void 0:a.message)})}duration(a){return this._addCheck({kind:"duration",...u.errorUtil.errToObj(a)})}regex(a,b){return this._addCheck({kind:"regex",regex:a,...u.errorUtil.errToObj(b)})}includes(a,b){return this._addCheck({kind:"includes",value:a,position:b==null?void 0:b.position,...u.errorUtil.errToObj(b==null?void 0:b.message)})}startsWith(a,b){return this._addCheck({kind:"startsWith",value:a,...u.errorUtil.errToObj(b)})}endsWith(a,b){return this._addCheck({kind:"endsWith",value:a,...u.errorUtil.errToObj(b)})}min(a,b){return this._addCheck({kind:"min",value:a,...u.errorUtil.errToObj(b)})}max(a,b){return this._addCheck({kind:"max",value:a,...u.errorUtil.errToObj(b)})}length(a,b){return this._addCheck({kind:"length",value:a,...u.errorUtil.errToObj(b)})}nonempty(a){return this.min(1,u.errorUtil.errToObj(a))}trim(){return new O({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new O({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new O({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(a=>a.kind==="datetime")}get isDate(){return!!this._def.checks.find(a=>a.kind==="date")}get isTime(){return!!this._def.checks.find(a=>a.kind==="time")}get isDuration(){return!!this._def.checks.find(a=>a.kind==="duration")}get isEmail(){return!!this._def.checks.find(a=>a.kind==="email")}get isURL(){return!!this._def.checks.find(a=>a.kind==="url")}get isEmoji(){return!!this._def.checks.find(a=>a.kind==="emoji")}get isUUID(){return!!this._def.checks.find(a=>a.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(a=>a.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(a=>a.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(a=>a.kind==="cuid2")}get isULID(){return!!this._def.checks.find(a=>a.kind==="ulid")}get isIP(){return!!this._def.checks.find(a=>a.kind==="ip")}get isBase64(){return!!this._def.checks.find(a=>a.kind==="base64")}get minLength(){let a=null;for(const b of this._def.checks)b.kind==="min"&&(a===null||b.value>a)&&(a=b.value);return a}get maxLength(){let a=null;for(const b of this._def.checks)b.kind==="max"&&(a===null||b.value{var a;return new O({checks:[],typeName:le.ZodString,coerce:(a=v==null?void 0:v.coerce)!==null&&a!==void 0?a:!1,...p(v)})};function Y(v,a){const b=(v.toString().split(".")[1]||"").length,E=(a.toString().split(".")[1]||"").length,T=b>E?b:E,w=parseInt(v.toFixed(T).replace(".","")),I=parseInt(a.toFixed(T).replace(".",""));return w%I/Math.pow(10,T)}class M extends h{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(a){if(this._def.coerce&&(a.data=Number(a.data)),this._getType(a)!==f.ZodParsedType.number){const w=this._getOrReturnCtx(a);return(0,l.addIssueToContext)(w,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.number,received:w.parsedType}),l.INVALID}let E;const T=new l.ParseStatus;for(const w of this._def.checks)w.kind==="int"?f.util.isInteger(a.data)||(E=this._getOrReturnCtx(a,E),(0,l.addIssueToContext)(E,{code:c.ZodIssueCode.invalid_type,expected:"integer",received:"float",message:w.message}),T.dirty()):w.kind==="min"?(w.inclusive?a.dataw.value:a.data>=w.value)&&(E=this._getOrReturnCtx(a,E),(0,l.addIssueToContext)(E,{code:c.ZodIssueCode.too_big,maximum:w.value,type:"number",inclusive:w.inclusive,exact:!1,message:w.message}),T.dirty()):w.kind==="multipleOf"?Y(a.data,w.value)!==0&&(E=this._getOrReturnCtx(a,E),(0,l.addIssueToContext)(E,{code:c.ZodIssueCode.not_multiple_of,multipleOf:w.value,message:w.message}),T.dirty()):w.kind==="finite"?Number.isFinite(a.data)||(E=this._getOrReturnCtx(a,E),(0,l.addIssueToContext)(E,{code:c.ZodIssueCode.not_finite,message:w.message}),T.dirty()):f.util.assertNever(w);return{status:T.value,value:a.data}}gte(a,b){return this.setLimit("min",a,!0,u.errorUtil.toString(b))}gt(a,b){return this.setLimit("min",a,!1,u.errorUtil.toString(b))}lte(a,b){return this.setLimit("max",a,!0,u.errorUtil.toString(b))}lt(a,b){return this.setLimit("max",a,!1,u.errorUtil.toString(b))}setLimit(a,b,E,T){return new M({...this._def,checks:[...this._def.checks,{kind:a,value:b,inclusive:E,message:u.errorUtil.toString(T)}]})}_addCheck(a){return new M({...this._def,checks:[...this._def.checks,a]})}int(a){return this._addCheck({kind:"int",message:u.errorUtil.toString(a)})}positive(a){return this._addCheck({kind:"min",value:0,inclusive:!1,message:u.errorUtil.toString(a)})}negative(a){return this._addCheck({kind:"max",value:0,inclusive:!1,message:u.errorUtil.toString(a)})}nonpositive(a){return this._addCheck({kind:"max",value:0,inclusive:!0,message:u.errorUtil.toString(a)})}nonnegative(a){return this._addCheck({kind:"min",value:0,inclusive:!0,message:u.errorUtil.toString(a)})}multipleOf(a,b){return this._addCheck({kind:"multipleOf",value:a,message:u.errorUtil.toString(b)})}finite(a){return this._addCheck({kind:"finite",message:u.errorUtil.toString(a)})}safe(a){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:u.errorUtil.toString(a)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:u.errorUtil.toString(a)})}get minValue(){let a=null;for(const b of this._def.checks)b.kind==="min"&&(a===null||b.value>a)&&(a=b.value);return a}get maxValue(){let a=null;for(const b of this._def.checks)b.kind==="max"&&(a===null||b.valuea.kind==="int"||a.kind==="multipleOf"&&f.util.isInteger(a.value))}get isFinite(){let a=null,b=null;for(const E of this._def.checks){if(E.kind==="finite"||E.kind==="int"||E.kind==="multipleOf")return!0;E.kind==="min"?(b===null||E.value>b)&&(b=E.value):E.kind==="max"&&(a===null||E.valuenew M({checks:[],typeName:le.ZodNumber,coerce:(v==null?void 0:v.coerce)||!1,...p(v)});class te extends h{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(a){if(this._def.coerce&&(a.data=BigInt(a.data)),this._getType(a)!==f.ZodParsedType.bigint){const w=this._getOrReturnCtx(a);return(0,l.addIssueToContext)(w,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.bigint,received:w.parsedType}),l.INVALID}let E;const T=new l.ParseStatus;for(const w of this._def.checks)w.kind==="min"?(w.inclusive?a.dataw.value:a.data>=w.value)&&(E=this._getOrReturnCtx(a,E),(0,l.addIssueToContext)(E,{code:c.ZodIssueCode.too_big,type:"bigint",maximum:w.value,inclusive:w.inclusive,message:w.message}),T.dirty()):w.kind==="multipleOf"?a.data%w.value!==BigInt(0)&&(E=this._getOrReturnCtx(a,E),(0,l.addIssueToContext)(E,{code:c.ZodIssueCode.not_multiple_of,multipleOf:w.value,message:w.message}),T.dirty()):f.util.assertNever(w);return{status:T.value,value:a.data}}gte(a,b){return this.setLimit("min",a,!0,u.errorUtil.toString(b))}gt(a,b){return this.setLimit("min",a,!1,u.errorUtil.toString(b))}lte(a,b){return this.setLimit("max",a,!0,u.errorUtil.toString(b))}lt(a,b){return this.setLimit("max",a,!1,u.errorUtil.toString(b))}setLimit(a,b,E,T){return new te({...this._def,checks:[...this._def.checks,{kind:a,value:b,inclusive:E,message:u.errorUtil.toString(T)}]})}_addCheck(a){return new te({...this._def,checks:[...this._def.checks,a]})}positive(a){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:u.errorUtil.toString(a)})}negative(a){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:u.errorUtil.toString(a)})}nonpositive(a){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:u.errorUtil.toString(a)})}nonnegative(a){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:u.errorUtil.toString(a)})}multipleOf(a,b){return this._addCheck({kind:"multipleOf",value:a,message:u.errorUtil.toString(b)})}get minValue(){let a=null;for(const b of this._def.checks)b.kind==="min"&&(a===null||b.value>a)&&(a=b.value);return a}get maxValue(){let a=null;for(const b of this._def.checks)b.kind==="max"&&(a===null||b.value{var a;return new te({checks:[],typeName:le.ZodBigInt,coerce:(a=v==null?void 0:v.coerce)!==null&&a!==void 0?a:!1,...p(v)})};class z extends h{_parse(a){if(this._def.coerce&&(a.data=!!a.data),this._getType(a)!==f.ZodParsedType.boolean){const E=this._getOrReturnCtx(a);return(0,l.addIssueToContext)(E,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.boolean,received:E.parsedType}),l.INVALID}return(0,l.OK)(a.data)}}t.ZodBoolean=z,z.create=v=>new z({typeName:le.ZodBoolean,coerce:(v==null?void 0:v.coerce)||!1,...p(v)});class ne extends h{_parse(a){if(this._def.coerce&&(a.data=new Date(a.data)),this._getType(a)!==f.ZodParsedType.date){const w=this._getOrReturnCtx(a);return(0,l.addIssueToContext)(w,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.date,received:w.parsedType}),l.INVALID}if(isNaN(a.data.getTime())){const w=this._getOrReturnCtx(a);return(0,l.addIssueToContext)(w,{code:c.ZodIssueCode.invalid_date}),l.INVALID}const E=new l.ParseStatus;let T;for(const w of this._def.checks)w.kind==="min"?a.data.getTime()w.value&&(T=this._getOrReturnCtx(a,T),(0,l.addIssueToContext)(T,{code:c.ZodIssueCode.too_big,message:w.message,inclusive:!0,exact:!1,maximum:w.value,type:"date"}),E.dirty()):f.util.assertNever(w);return{status:E.value,value:new Date(a.data.getTime())}}_addCheck(a){return new ne({...this._def,checks:[...this._def.checks,a]})}min(a,b){return this._addCheck({kind:"min",value:a.getTime(),message:u.errorUtil.toString(b)})}max(a,b){return this._addCheck({kind:"max",value:a.getTime(),message:u.errorUtil.toString(b)})}get minDate(){let a=null;for(const b of this._def.checks)b.kind==="min"&&(a===null||b.value>a)&&(a=b.value);return a!=null?new Date(a):null}get maxDate(){let a=null;for(const b of this._def.checks)b.kind==="max"&&(a===null||b.valuenew ne({checks:[],coerce:(v==null?void 0:v.coerce)||!1,typeName:le.ZodDate,...p(v)});class fe extends h{_parse(a){if(this._getType(a)!==f.ZodParsedType.symbol){const E=this._getOrReturnCtx(a);return(0,l.addIssueToContext)(E,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.symbol,received:E.parsedType}),l.INVALID}return(0,l.OK)(a.data)}}t.ZodSymbol=fe,fe.create=v=>new fe({typeName:le.ZodSymbol,...p(v)});class he extends h{_parse(a){if(this._getType(a)!==f.ZodParsedType.undefined){const E=this._getOrReturnCtx(a);return(0,l.addIssueToContext)(E,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.undefined,received:E.parsedType}),l.INVALID}return(0,l.OK)(a.data)}}t.ZodUndefined=he,he.create=v=>new he({typeName:le.ZodUndefined,...p(v)});class ge extends h{_parse(a){if(this._getType(a)!==f.ZodParsedType.null){const E=this._getOrReturnCtx(a);return(0,l.addIssueToContext)(E,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.null,received:E.parsedType}),l.INVALID}return(0,l.OK)(a.data)}}t.ZodNull=ge,ge.create=v=>new ge({typeName:le.ZodNull,...p(v)});class Se extends h{constructor(){super(...arguments),this._any=!0}_parse(a){return(0,l.OK)(a.data)}}t.ZodAny=Se,Se.create=v=>new Se({typeName:le.ZodAny,...p(v)});class Ne extends h{constructor(){super(...arguments),this._unknown=!0}_parse(a){return(0,l.OK)(a.data)}}t.ZodUnknown=Ne,Ne.create=v=>new Ne({typeName:le.ZodUnknown,...p(v)});class ke extends h{_parse(a){const b=this._getOrReturnCtx(a);return(0,l.addIssueToContext)(b,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.never,received:b.parsedType}),l.INVALID}}t.ZodNever=ke,ke.create=v=>new ke({typeName:le.ZodNever,...p(v)});class Me extends h{_parse(a){if(this._getType(a)!==f.ZodParsedType.undefined){const E=this._getOrReturnCtx(a);return(0,l.addIssueToContext)(E,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.void,received:E.parsedType}),l.INVALID}return(0,l.OK)(a.data)}}t.ZodVoid=Me,Me.create=v=>new Me({typeName:le.ZodVoid,...p(v)});class Be extends h{_parse(a){const{ctx:b,status:E}=this._processInputParams(a),T=this._def;if(b.parsedType!==f.ZodParsedType.array)return(0,l.addIssueToContext)(b,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.array,received:b.parsedType}),l.INVALID;if(T.exactLength!==null){const I=b.data.length>T.exactLength.value,P=b.data.lengthT.maxLength.value&&((0,l.addIssueToContext)(b,{code:c.ZodIssueCode.too_big,maximum:T.maxLength.value,type:"array",inclusive:!0,exact:!1,message:T.maxLength.message}),E.dirty()),b.common.async)return Promise.all([...b.data].map((I,P)=>T.type._parseAsync(new d(b,I,b.path,P)))).then(I=>l.ParseStatus.mergeArray(E,I));const w=[...b.data].map((I,P)=>T.type._parseSync(new d(b,I,b.path,P)));return l.ParseStatus.mergeArray(E,w)}get element(){return this._def.type}min(a,b){return new Be({...this._def,minLength:{value:a,message:u.errorUtil.toString(b)}})}max(a,b){return new Be({...this._def,maxLength:{value:a,message:u.errorUtil.toString(b)}})}length(a,b){return new Be({...this._def,exactLength:{value:a,message:u.errorUtil.toString(b)}})}nonempty(a){return this.min(1,a)}}t.ZodArray=Be,Be.create=(v,a)=>new Be({type:v,minLength:null,maxLength:null,exactLength:null,typeName:le.ZodArray,...p(a)});function xe(v){if(v instanceof ye){const a={};for(const b in v.shape){const E=v.shape[b];a[b]=Vt.create(xe(E))}return new ye({...v._def,shape:()=>a})}else return v instanceof Be?new Be({...v._def,type:xe(v.element)}):v instanceof Vt?Vt.create(xe(v.unwrap())):v instanceof wr?wr.create(xe(v.unwrap())):v instanceof lt?lt.create(v.items.map(a=>xe(a))):v}class ye extends h{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;const a=this._def.shape(),b=f.util.objectKeys(a);return this._cached={shape:a,keys:b}}_parse(a){if(this._getType(a)!==f.ZodParsedType.object){const J=this._getOrReturnCtx(a);return(0,l.addIssueToContext)(J,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.object,received:J.parsedType}),l.INVALID}const{status:E,ctx:T}=this._processInputParams(a),{shape:w,keys:I}=this._getCached(),P=[];if(!(this._def.catchall instanceof ke&&this._def.unknownKeys==="strip"))for(const J in T.data)I.includes(J)||P.push(J);const W=[];for(const J of I){const de=w[J],_t=T.data[J];W.push({key:{status:"valid",value:J},value:de._parse(new d(T,_t,T.path,J)),alwaysSet:J in T.data})}if(this._def.catchall instanceof ke){const J=this._def.unknownKeys;if(J==="passthrough")for(const de of P)W.push({key:{status:"valid",value:de},value:{status:"valid",value:T.data[de]}});else if(J==="strict")P.length>0&&((0,l.addIssueToContext)(T,{code:c.ZodIssueCode.unrecognized_keys,keys:P}),E.dirty());else if(J!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{const J=this._def.catchall;for(const de of P){const _t=T.data[de];W.push({key:{status:"valid",value:de},value:J._parse(new d(T,_t,T.path,de)),alwaysSet:de in T.data})}}return T.common.async?Promise.resolve().then(async()=>{const J=[];for(const de of W){const _t=await de.key,Jo=await de.value;J.push({key:_t,value:Jo,alwaysSet:de.alwaysSet})}return J}).then(J=>l.ParseStatus.mergeObjectSync(E,J)):l.ParseStatus.mergeObjectSync(E,W)}get shape(){return this._def.shape()}strict(a){return u.errorUtil.errToObj,new ye({...this._def,unknownKeys:"strict",...a!==void 0?{errorMap:(b,E)=>{var T,w,I,P;const W=(I=(w=(T=this._def).errorMap)===null||w===void 0?void 0:w.call(T,b,E).message)!==null&&I!==void 0?I:E.defaultError;return b.code==="unrecognized_keys"?{message:(P=u.errorUtil.errToObj(a).message)!==null&&P!==void 0?P:W}:{message:W}}}:{}})}strip(){return new ye({...this._def,unknownKeys:"strip"})}passthrough(){return new ye({...this._def,unknownKeys:"passthrough"})}extend(a){return new ye({...this._def,shape:()=>({...this._def.shape(),...a})})}merge(a){return new ye({unknownKeys:a._def.unknownKeys,catchall:a._def.catchall,shape:()=>({...this._def.shape(),...a._def.shape()}),typeName:le.ZodObject})}setKey(a,b){return this.augment({[a]:b})}catchall(a){return new ye({...this._def,catchall:a})}pick(a){const b={};return f.util.objectKeys(a).forEach(E=>{a[E]&&this.shape[E]&&(b[E]=this.shape[E])}),new ye({...this._def,shape:()=>b})}omit(a){const b={};return f.util.objectKeys(this.shape).forEach(E=>{a[E]||(b[E]=this.shape[E])}),new ye({...this._def,shape:()=>b})}deepPartial(){return xe(this)}partial(a){const b={};return f.util.objectKeys(this.shape).forEach(E=>{const T=this.shape[E];a&&!a[E]?b[E]=T:b[E]=T.optional()}),new ye({...this._def,shape:()=>b})}required(a){const b={};return f.util.objectKeys(this.shape).forEach(E=>{if(a&&!a[E])b[E]=this.shape[E];else{let w=this.shape[E];for(;w instanceof Vt;)w=w._def.innerType;b[E]=w}}),new ye({...this._def,shape:()=>b})}keyof(){return Zi(f.util.objectKeys(this.shape))}}t.ZodObject=ye,ye.create=(v,a)=>new ye({shape:()=>v,unknownKeys:"strip",catchall:ke.create(),typeName:le.ZodObject,...p(a)}),ye.strictCreate=(v,a)=>new ye({shape:()=>v,unknownKeys:"strict",catchall:ke.create(),typeName:le.ZodObject,...p(a)}),ye.lazycreate=(v,a)=>new ye({shape:v,unknownKeys:"strip",catchall:ke.create(),typeName:le.ZodObject,...p(a)});class ft extends h{_parse(a){const{ctx:b}=this._processInputParams(a),E=this._def.options;function T(w){for(const P of w)if(P.result.status==="valid")return P.result;for(const P of w)if(P.result.status==="dirty")return b.common.issues.push(...P.ctx.common.issues),P.result;const I=w.map(P=>new c.ZodError(P.ctx.common.issues));return(0,l.addIssueToContext)(b,{code:c.ZodIssueCode.invalid_union,unionErrors:I}),l.INVALID}if(b.common.async)return Promise.all(E.map(async w=>{const I={...b,common:{...b.common,issues:[]},parent:null};return{result:await w._parseAsync({data:b.data,path:b.path,parent:I}),ctx:I}})).then(T);{let w;const I=[];for(const W of E){const J={...b,common:{...b.common,issues:[]},parent:null},de=W._parseSync({data:b.data,path:b.path,parent:J});if(de.status==="valid")return de;de.status==="dirty"&&!w&&(w={result:de,ctx:J}),J.common.issues.length&&I.push(J.common.issues)}if(w)return b.common.issues.push(...w.ctx.common.issues),w.result;const P=I.map(W=>new c.ZodError(W));return(0,l.addIssueToContext)(b,{code:c.ZodIssueCode.invalid_union,unionErrors:P}),l.INVALID}}get options(){return this._def.options}}t.ZodUnion=ft,ft.create=(v,a)=>new ft({options:v,typeName:le.ZodUnion,...p(a)});const et=v=>v instanceof ae?et(v.schema):v instanceof Lt?et(v.innerType()):v instanceof we?[v.value]:v instanceof Tr?v.options:v instanceof Hi?f.util.objectValues(v.enum):v instanceof Wi?et(v._def.innerType):v instanceof he?[void 0]:v instanceof ge?[null]:v instanceof Vt?[void 0,...et(v.unwrap())]:v instanceof wr?[null,...et(v.unwrap())]:v instanceof ro||v instanceof Yi?et(v.unwrap()):v instanceof Ji?et(v._def.innerType):[];class er extends h{_parse(a){const{ctx:b}=this._processInputParams(a);if(b.parsedType!==f.ZodParsedType.object)return(0,l.addIssueToContext)(b,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.object,received:b.parsedType}),l.INVALID;const E=this.discriminator,T=b.data[E],w=this.optionsMap.get(T);return w?b.common.async?w._parseAsync({data:b.data,path:b.path,parent:b}):w._parseSync({data:b.data,path:b.path,parent:b}):((0,l.addIssueToContext)(b,{code:c.ZodIssueCode.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[E]}),l.INVALID)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(a,b,E){const T=new Map;for(const w of b){const I=et(w.shape[a]);if(!I.length)throw new Error(`A discriminator value for key \`${a}\` could not be extracted from all schema options`);for(const P of I){if(T.has(P))throw new Error(`Discriminator property ${String(a)} has duplicate value ${String(P)}`);T.set(P,w)}}return new er({typeName:le.ZodDiscriminatedUnion,discriminator:a,options:b,optionsMap:T,...p(E)})}}t.ZodDiscriminatedUnion=er;function dt(v,a){const b=(0,f.getParsedType)(v),E=(0,f.getParsedType)(a);if(v===a)return{valid:!0,data:v};if(b===f.ZodParsedType.object&&E===f.ZodParsedType.object){const T=f.util.objectKeys(a),w=f.util.objectKeys(v).filter(P=>T.indexOf(P)!==-1),I={...v,...a};for(const P of w){const W=dt(v[P],a[P]);if(!W.valid)return{valid:!1};I[P]=W.data}return{valid:!0,data:I}}else if(b===f.ZodParsedType.array&&E===f.ZodParsedType.array){if(v.length!==a.length)return{valid:!1};const T=[];for(let w=0;w{if((0,l.isAborted)(w)||(0,l.isAborted)(I))return l.INVALID;const P=dt(w.value,I.value);return P.valid?(((0,l.isDirty)(w)||(0,l.isDirty)(I))&&b.dirty(),{status:b.value,value:P.data}):((0,l.addIssueToContext)(E,{code:c.ZodIssueCode.invalid_intersection_types}),l.INVALID)};return E.common.async?Promise.all([this._def.left._parseAsync({data:E.data,path:E.path,parent:E}),this._def.right._parseAsync({data:E.data,path:E.path,parent:E})]).then(([w,I])=>T(w,I)):T(this._def.left._parseSync({data:E.data,path:E.path,parent:E}),this._def.right._parseSync({data:E.data,path:E.path,parent:E}))}}t.ZodIntersection=_r,_r.create=(v,a,b)=>new _r({left:v,right:a,typeName:le.ZodIntersection,...p(b)});class lt extends h{_parse(a){const{status:b,ctx:E}=this._processInputParams(a);if(E.parsedType!==f.ZodParsedType.array)return(0,l.addIssueToContext)(E,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.array,received:E.parsedType}),l.INVALID;if(E.data.lengththis._def.items.length&&((0,l.addIssueToContext)(E,{code:c.ZodIssueCode.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),b.dirty());const w=[...E.data].map((I,P)=>{const W=this._def.items[P]||this._def.rest;return W?W._parse(new d(E,I,E.path,P)):null}).filter(I=>!!I);return E.common.async?Promise.all(w).then(I=>l.ParseStatus.mergeArray(b,I)):l.ParseStatus.mergeArray(b,w)}get items(){return this._def.items}rest(a){return new lt({...this._def,rest:a})}}t.ZodTuple=lt,lt.create=(v,a)=>{if(!Array.isArray(v))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new lt({items:v,typeName:le.ZodTuple,rest:null,...p(a)})};class pt extends h{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(a){const{status:b,ctx:E}=this._processInputParams(a);if(E.parsedType!==f.ZodParsedType.object)return(0,l.addIssueToContext)(E,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.object,received:E.parsedType}),l.INVALID;const T=[],w=this._def.keyType,I=this._def.valueType;for(const P in E.data)T.push({key:w._parse(new d(E,P,E.path,P)),value:I._parse(new d(E,E.data[P],E.path,P)),alwaysSet:P in E.data});return E.common.async?l.ParseStatus.mergeObjectAsync(b,T):l.ParseStatus.mergeObjectSync(b,T)}get element(){return this._def.valueType}static create(a,b,E){return b instanceof h?new pt({keyType:a,valueType:b,typeName:le.ZodRecord,...p(E)}):new pt({keyType:O.create(),valueType:a,typeName:le.ZodRecord,...p(b)})}}t.ZodRecord=pt;class $e extends h{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(a){const{status:b,ctx:E}=this._processInputParams(a);if(E.parsedType!==f.ZodParsedType.map)return(0,l.addIssueToContext)(E,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.map,received:E.parsedType}),l.INVALID;const T=this._def.keyType,w=this._def.valueType,I=[...E.data.entries()].map(([P,W],J)=>({key:T._parse(new d(E,P,E.path,[J,"key"])),value:w._parse(new d(E,W,E.path,[J,"value"]))}));if(E.common.async){const P=new Map;return Promise.resolve().then(async()=>{for(const W of I){const J=await W.key,de=await W.value;if(J.status==="aborted"||de.status==="aborted")return l.INVALID;(J.status==="dirty"||de.status==="dirty")&&b.dirty(),P.set(J.value,de.value)}return{status:b.value,value:P}})}else{const P=new Map;for(const W of I){const J=W.key,de=W.value;if(J.status==="aborted"||de.status==="aborted")return l.INVALID;(J.status==="dirty"||de.status==="dirty")&&b.dirty(),P.set(J.value,de.value)}return{status:b.value,value:P}}}}t.ZodMap=$e,$e.create=(v,a,b)=>new $e({valueType:a,keyType:v,typeName:le.ZodMap,...p(b)});class tr extends h{_parse(a){const{status:b,ctx:E}=this._processInputParams(a);if(E.parsedType!==f.ZodParsedType.set)return(0,l.addIssueToContext)(E,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.set,received:E.parsedType}),l.INVALID;const T=this._def;T.minSize!==null&&E.data.sizeT.maxSize.value&&((0,l.addIssueToContext)(E,{code:c.ZodIssueCode.too_big,maximum:T.maxSize.value,type:"set",inclusive:!0,exact:!1,message:T.maxSize.message}),b.dirty());const w=this._def.valueType;function I(W){const J=new Set;for(const de of W){if(de.status==="aborted")return l.INVALID;de.status==="dirty"&&b.dirty(),J.add(de.value)}return{status:b.value,value:J}}const P=[...E.data.values()].map((W,J)=>w._parse(new d(E,W,E.path,J)));return E.common.async?Promise.all(P).then(W=>I(W)):I(P)}min(a,b){return new tr({...this._def,minSize:{value:a,message:u.errorUtil.toString(b)}})}max(a,b){return new tr({...this._def,maxSize:{value:a,message:u.errorUtil.toString(b)}})}size(a,b){return this.min(a,b).max(a,b)}nonempty(a){return this.min(1,a)}}t.ZodSet=tr,tr.create=(v,a)=>new tr({valueType:v,minSize:null,maxSize:null,typeName:le.ZodSet,...p(a)});class rr extends h{constructor(){super(...arguments),this.validate=this.implement}_parse(a){const{ctx:b}=this._processInputParams(a);if(b.parsedType!==f.ZodParsedType.function)return(0,l.addIssueToContext)(b,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.function,received:b.parsedType}),l.INVALID;function E(P,W){return(0,l.makeIssue)({data:P,path:b.path,errorMaps:[b.common.contextualErrorMap,b.schemaErrorMap,(0,o.getErrorMap)(),o.defaultErrorMap].filter(J=>!!J),issueData:{code:c.ZodIssueCode.invalid_arguments,argumentsError:W}})}function T(P,W){return(0,l.makeIssue)({data:P,path:b.path,errorMaps:[b.common.contextualErrorMap,b.schemaErrorMap,(0,o.getErrorMap)(),o.defaultErrorMap].filter(J=>!!J),issueData:{code:c.ZodIssueCode.invalid_return_type,returnTypeError:W}})}const w={errorMap:b.common.contextualErrorMap},I=b.data;if(this._def.returns instanceof di){const P=this;return(0,l.OK)(async function(...W){const J=new c.ZodError([]),de=await P._def.args.parseAsync(W,w).catch(io=>{throw J.addIssue(E(W,io)),J}),_t=await Reflect.apply(I,this,de);return await P._def.returns._def.type.parseAsync(_t,w).catch(io=>{throw J.addIssue(T(_t,io)),J})})}else{const P=this;return(0,l.OK)(function(...W){const J=P._def.args.safeParse(W,w);if(!J.success)throw new c.ZodError([E(W,J.error)]);const de=Reflect.apply(I,this,J.data),_t=P._def.returns.safeParse(de,w);if(!_t.success)throw new c.ZodError([T(de,_t.error)]);return _t.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...a){return new rr({...this._def,args:lt.create(a).rest(Ne.create())})}returns(a){return new rr({...this._def,returns:a})}implement(a){return this.parse(a)}strictImplement(a){return this.parse(a)}static create(a,b,E){return new rr({args:a||lt.create([]).rest(Ne.create()),returns:b||Ne.create(),typeName:le.ZodFunction,...p(E)})}}t.ZodFunction=rr;class ae extends h{get schema(){return this._def.getter()}_parse(a){const{ctx:b}=this._processInputParams(a);return this._def.getter()._parse({data:b.data,path:b.path,parent:b})}}t.ZodLazy=ae,ae.create=(v,a)=>new ae({getter:v,typeName:le.ZodLazy,...p(a)});class we extends h{_parse(a){if(a.data!==this._def.value){const b=this._getOrReturnCtx(a);return(0,l.addIssueToContext)(b,{received:b.data,code:c.ZodIssueCode.invalid_literal,expected:this._def.value}),l.INVALID}return{status:"valid",value:a.data}}get value(){return this._def.value}}t.ZodLiteral=we,we.create=(v,a)=>new we({value:v,typeName:le.ZodLiteral,...p(a)});function Zi(v,a){return new Tr({values:v,typeName:le.ZodEnum,...p(a)})}class Tr extends h{constructor(){super(...arguments),n.set(this,void 0)}_parse(a){if(typeof a.data!="string"){const b=this._getOrReturnCtx(a),E=this._def.values;return(0,l.addIssueToContext)(b,{expected:f.util.joinValues(E),received:b.parsedType,code:c.ZodIssueCode.invalid_type}),l.INVALID}if(e(this,n,"f")||r(this,n,new Set(this._def.values),"f"),!e(this,n,"f").has(a.data)){const b=this._getOrReturnCtx(a),E=this._def.values;return(0,l.addIssueToContext)(b,{received:b.data,code:c.ZodIssueCode.invalid_enum_value,options:E}),l.INVALID}return(0,l.OK)(a.data)}get options(){return this._def.values}get enum(){const a={};for(const b of this._def.values)a[b]=b;return a}get Values(){const a={};for(const b of this._def.values)a[b]=b;return a}get Enum(){const a={};for(const b of this._def.values)a[b]=b;return a}extract(a,b=this._def){return Tr.create(a,{...this._def,...b})}exclude(a,b=this._def){return Tr.create(this.options.filter(E=>!a.includes(E)),{...this._def,...b})}}t.ZodEnum=Tr,n=new WeakMap,Tr.create=Zi;class Hi extends h{constructor(){super(...arguments),s.set(this,void 0)}_parse(a){const b=f.util.getValidEnumValues(this._def.values),E=this._getOrReturnCtx(a);if(E.parsedType!==f.ZodParsedType.string&&E.parsedType!==f.ZodParsedType.number){const T=f.util.objectValues(b);return(0,l.addIssueToContext)(E,{expected:f.util.joinValues(T),received:E.parsedType,code:c.ZodIssueCode.invalid_type}),l.INVALID}if(e(this,s,"f")||r(this,s,new Set(f.util.getValidEnumValues(this._def.values)),"f"),!e(this,s,"f").has(a.data)){const T=f.util.objectValues(b);return(0,l.addIssueToContext)(E,{received:E.data,code:c.ZodIssueCode.invalid_enum_value,options:T}),l.INVALID}return(0,l.OK)(a.data)}get enum(){return this._def.values}}t.ZodNativeEnum=Hi,s=new WeakMap,Hi.create=(v,a)=>new Hi({values:v,typeName:le.ZodNativeEnum,...p(a)});class di extends h{unwrap(){return this._def.type}_parse(a){const{ctx:b}=this._processInputParams(a);if(b.parsedType!==f.ZodParsedType.promise&&b.common.async===!1)return(0,l.addIssueToContext)(b,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.promise,received:b.parsedType}),l.INVALID;const E=b.parsedType===f.ZodParsedType.promise?b.data:Promise.resolve(b.data);return(0,l.OK)(E.then(T=>this._def.type.parseAsync(T,{path:b.path,errorMap:b.common.contextualErrorMap})))}}t.ZodPromise=di,di.create=(v,a)=>new di({type:v,typeName:le.ZodPromise,...p(a)});class Lt extends h{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===le.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(a){const{status:b,ctx:E}=this._processInputParams(a),T=this._def.effect||null,w={addIssue:I=>{(0,l.addIssueToContext)(E,I),I.fatal?b.abort():b.dirty()},get path(){return E.path}};if(w.addIssue=w.addIssue.bind(w),T.type==="preprocess"){const I=T.transform(E.data,w);if(E.common.async)return Promise.resolve(I).then(async P=>{if(b.value==="aborted")return l.INVALID;const W=await this._def.schema._parseAsync({data:P,path:E.path,parent:E});return W.status==="aborted"?l.INVALID:W.status==="dirty"||b.value==="dirty"?(0,l.DIRTY)(W.value):W});{if(b.value==="aborted")return l.INVALID;const P=this._def.schema._parseSync({data:I,path:E.path,parent:E});return P.status==="aborted"?l.INVALID:P.status==="dirty"||b.value==="dirty"?(0,l.DIRTY)(P.value):P}}if(T.type==="refinement"){const I=P=>{const W=T.refinement(P,w);if(E.common.async)return Promise.resolve(W);if(W instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return P};if(E.common.async===!1){const P=this._def.schema._parseSync({data:E.data,path:E.path,parent:E});return P.status==="aborted"?l.INVALID:(P.status==="dirty"&&b.dirty(),I(P.value),{status:b.value,value:P.value})}else return this._def.schema._parseAsync({data:E.data,path:E.path,parent:E}).then(P=>P.status==="aborted"?l.INVALID:(P.status==="dirty"&&b.dirty(),I(P.value).then(()=>({status:b.value,value:P.value}))))}if(T.type==="transform")if(E.common.async===!1){const I=this._def.schema._parseSync({data:E.data,path:E.path,parent:E});if(!(0,l.isValid)(I))return I;const P=T.transform(I.value,w);if(P instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:b.value,value:P}}else return this._def.schema._parseAsync({data:E.data,path:E.path,parent:E}).then(I=>(0,l.isValid)(I)?Promise.resolve(T.transform(I.value,w)).then(P=>({status:b.value,value:P})):I);f.util.assertNever(T)}}t.ZodEffects=Lt,t.ZodTransformer=Lt,Lt.create=(v,a,b)=>new Lt({schema:v,typeName:le.ZodEffects,effect:a,...p(b)}),Lt.createWithPreprocess=(v,a,b)=>new Lt({schema:a,effect:{type:"preprocess",transform:v},typeName:le.ZodEffects,...p(b)});class Vt extends h{_parse(a){return this._getType(a)===f.ZodParsedType.undefined?(0,l.OK)(void 0):this._def.innerType._parse(a)}unwrap(){return this._def.innerType}}t.ZodOptional=Vt,Vt.create=(v,a)=>new Vt({innerType:v,typeName:le.ZodOptional,...p(a)});class wr extends h{_parse(a){return this._getType(a)===f.ZodParsedType.null?(0,l.OK)(null):this._def.innerType._parse(a)}unwrap(){return this._def.innerType}}t.ZodNullable=wr,wr.create=(v,a)=>new wr({innerType:v,typeName:le.ZodNullable,...p(a)});class Wi extends h{_parse(a){const{ctx:b}=this._processInputParams(a);let E=b.data;return b.parsedType===f.ZodParsedType.undefined&&(E=this._def.defaultValue()),this._def.innerType._parse({data:E,path:b.path,parent:b})}removeDefault(){return this._def.innerType}}t.ZodDefault=Wi,Wi.create=(v,a)=>new Wi({innerType:v,typeName:le.ZodDefault,defaultValue:typeof a.default=="function"?a.default:()=>a.default,...p(a)});class Ji extends h{_parse(a){const{ctx:b}=this._processInputParams(a),E={...b,common:{...b.common,issues:[]}},T=this._def.innerType._parse({data:E.data,path:E.path,parent:{...E}});return(0,l.isAsync)(T)?T.then(w=>({status:"valid",value:w.status==="valid"?w.value:this._def.catchValue({get error(){return new c.ZodError(E.common.issues)},input:E.data})})):{status:"valid",value:T.status==="valid"?T.value:this._def.catchValue({get error(){return new c.ZodError(E.common.issues)},input:E.data})}}removeCatch(){return this._def.innerType}}t.ZodCatch=Ji,Ji.create=(v,a)=>new Ji({innerType:v,typeName:le.ZodCatch,catchValue:typeof a.catch=="function"?a.catch:()=>a.catch,...p(a)});class da extends h{_parse(a){if(this._getType(a)!==f.ZodParsedType.nan){const E=this._getOrReturnCtx(a);return(0,l.addIssueToContext)(E,{code:c.ZodIssueCode.invalid_type,expected:f.ZodParsedType.nan,received:E.parsedType}),l.INVALID}return{status:"valid",value:a.data}}}t.ZodNaN=da,da.create=v=>new da({typeName:le.ZodNaN,...p(v)}),t.BRAND=Symbol("zod_brand");class ro extends h{_parse(a){const{ctx:b}=this._processInputParams(a),E=b.data;return this._def.type._parse({data:E,path:b.path,parent:b})}unwrap(){return this._def.type}}t.ZodBranded=ro;class Qi extends h{_parse(a){const{status:b,ctx:E}=this._processInputParams(a);if(E.common.async)return(async()=>{const w=await this._def.in._parseAsync({data:E.data,path:E.path,parent:E});return w.status==="aborted"?l.INVALID:w.status==="dirty"?(b.dirty(),(0,l.DIRTY)(w.value)):this._def.out._parseAsync({data:w.value,path:E.path,parent:E})})();{const T=this._def.in._parseSync({data:E.data,path:E.path,parent:E});return T.status==="aborted"?l.INVALID:T.status==="dirty"?(b.dirty(),{status:"dirty",value:T.value}):this._def.out._parseSync({data:T.value,path:E.path,parent:E})}}static create(a,b){return new Qi({in:a,out:b,typeName:le.ZodPipeline})}}t.ZodPipeline=Qi;class Yi extends h{_parse(a){const b=this._def.innerType._parse(a),E=T=>((0,l.isValid)(T)&&(T.value=Object.freeze(T.value)),T);return(0,l.isAsync)(b)?b.then(T=>E(T)):E(b)}unwrap(){return this._def.innerType}}t.ZodReadonly=Yi,Yi.create=(v,a)=>new Yi({innerType:v,typeName:le.ZodReadonly,...p(a)});function Xo(v,a={},b){return v?Se.create().superRefine((E,T)=>{var w,I;if(!v(E)){const P=typeof a=="function"?a(E):typeof a=="string"?{message:a}:a,W=(I=(w=P.fatal)!==null&&w!==void 0?w:b)!==null&&I!==void 0?I:!0,J=typeof P=="string"?{message:P}:P;T.addIssue({code:"custom",...J,fatal:W})}}):Se.create()}t.custom=Xo,t.late={object:ye.lazycreate};var le;(function(v){v.ZodString="ZodString",v.ZodNumber="ZodNumber",v.ZodNaN="ZodNaN",v.ZodBigInt="ZodBigInt",v.ZodBoolean="ZodBoolean",v.ZodDate="ZodDate",v.ZodSymbol="ZodSymbol",v.ZodUndefined="ZodUndefined",v.ZodNull="ZodNull",v.ZodAny="ZodAny",v.ZodUnknown="ZodUnknown",v.ZodNever="ZodNever",v.ZodVoid="ZodVoid",v.ZodArray="ZodArray",v.ZodObject="ZodObject",v.ZodUnion="ZodUnion",v.ZodDiscriminatedUnion="ZodDiscriminatedUnion",v.ZodIntersection="ZodIntersection",v.ZodTuple="ZodTuple",v.ZodRecord="ZodRecord",v.ZodMap="ZodMap",v.ZodSet="ZodSet",v.ZodFunction="ZodFunction",v.ZodLazy="ZodLazy",v.ZodLiteral="ZodLiteral",v.ZodEnum="ZodEnum",v.ZodEffects="ZodEffects",v.ZodNativeEnum="ZodNativeEnum",v.ZodOptional="ZodOptional",v.ZodNullable="ZodNullable",v.ZodDefault="ZodDefault",v.ZodCatch="ZodCatch",v.ZodPromise="ZodPromise",v.ZodBranded="ZodBranded",v.ZodPipeline="ZodPipeline",v.ZodReadonly="ZodReadonly"})(le=t.ZodFirstPartyTypeKind||(t.ZodFirstPartyTypeKind={}));const Td=(v,a={message:`Input not instance of ${v.name}`})=>Xo(b=>b instanceof v,a);t.instanceof=Td;const zo=O.create;t.string=zo;const Zo=M.create;t.number=Zo;const wd=da.create;t.nan=wd;const Cd=te.create;t.bigint=Cd;const Ho=z.create;t.boolean=Ho;const Ld=ne.create;t.date=Ld;const Sd=fe.create;t.symbol=Sd;const kd=he.create;t.undefined=kd;const Dd=ge.create;t.null=Dd;const Bd=Se.create;t.any=Bd;const Pd=Ne.create;t.unknown=Pd;const Kd=ke.create;t.never=Kd;const Ud=Me.create;t.void=Ud;const Vd=Be.create;t.array=Vd;const Id=ye.create;t.object=Id;const Od=ye.strictCreate;t.strictObject=Od;const jd=ft.create;t.union=jd;const Nd=er.create;t.discriminatedUnion=Nd;const Md=_r.create;t.intersection=Md;const $d=lt.create;t.tuple=$d;const Gd=pt.create;t.record=Gd;const qd=$e.create;t.map=qd;const Fd=tr.create;t.set=Fd;const Xd=rr.create;t.function=Xd;const zd=ae.create;t.lazy=zd;const Zd=we.create;t.literal=Zd;const Hd=Tr.create;t.enum=Hd;const Wd=Hi.create;t.nativeEnum=Wd;const Jd=di.create;t.promise=Jd;const Wo=Lt.create;t.effect=Wo,t.transformer=Wo;const Qd=Vt.create;t.optional=Qd;const Yd=wr.create;t.nullable=Yd;const ep=Lt.createWithPreprocess;t.preprocess=ep;const tp=Qi.create;t.pipeline=tp;const rp=()=>zo().optional();t.ostring=rp;const ip=()=>Zo().optional();t.onumber=ip;const np=()=>Ho().optional();t.oboolean=np,t.coerce={string:v=>O.create({...v,coerce:!0}),number:v=>M.create({...v,coerce:!0}),boolean:v=>z.create({...v,coerce:!0}),bigint:v=>te.create({...v,coerce:!0}),date:v=>ne.create({...v,coerce:!0})},t.NEVER=l.INVALID})($u);(function(t){var e=K&&K.__createBinding||(Object.create?function(n,s,o,u){u===void 0&&(u=o),Object.defineProperty(n,u,{enumerable:!0,get:function(){return s[o]}})}:function(n,s,o,u){u===void 0&&(u=o),n[u]=s[o]}),r=K&&K.__exportStar||function(n,s){for(var o in n)o!=="default"&&!Object.prototype.hasOwnProperty.call(s,o)&&e(s,n,o)};Object.defineProperty(t,"__esModule",{value:!0}),r(Ft,t),r(Co,t),r(Mu,t),r(hn,t),r($u,t),r(Xt,t)})(yo);(function(t){var e=K&&K.__createBinding||(Object.create?function(u,l,f,c){c===void 0&&(c=f),Object.defineProperty(u,c,{enumerable:!0,get:function(){return l[f]}})}:function(u,l,f,c){c===void 0&&(c=f),u[c]=l[f]}),r=K&&K.__setModuleDefault||(Object.create?function(u,l){Object.defineProperty(u,"default",{enumerable:!0,value:l})}:function(u,l){u.default=l}),n=K&&K.__importStar||function(u){if(u&&u.__esModule)return u;var l={};if(u!=null)for(var f in u)f!=="default"&&Object.prototype.hasOwnProperty.call(u,f)&&e(l,u,f);return r(l,u),l},s=K&&K.__exportStar||function(u,l){for(var f in u)f!=="default"&&!Object.prototype.hasOwnProperty.call(l,f)&&e(l,u,f)};Object.defineProperty(t,"__esModule",{value:!0}),t.z=void 0;const o=n(yo);t.z=o,s(yo,t),t.default=o})(ci);var Et={},ir={},tt={},Yt={},Dr={};Object.defineProperty(Dr,"__esModule",{value:!0});Dr.isObject=Dr.assure=Dr.is=void 0;const Np=(t,e)=>e.safeParse(t).success;Dr.is=Np;const Mp=(t,e)=>t.parse(e);Dr.assure=Mp;const $p=t=>typeof t=="object"&&t!==null;Dr.isObject=$p;var vi={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.parseIntWithFallback=t.dedupeStrs=t.range=t.chunkArray=t.errHasMsg=t.isErrnoException=t.asyncFilter=t.s32decode=t.s32encode=t.streamToBuffer=t.flattenUint8Arrays=t.bailableWait=t.wait=t.jitter=t.noUndefinedVals=void 0;const e=_=>(Object.keys(_).forEach(S=>{_[S]===void 0&&delete _[S]}),_);t.noUndefinedVals=e;const r=_=>Math.round((Math.random()-.5)*_*2);t.jitter=r;const n=_=>new Promise(S=>setTimeout(S,_));t.wait=n;const s=_=>{let S;const B=new Promise(V=>{const j=setTimeout(V,_);S=()=>{clearTimeout(j),V()}});return{bail:S,wait:()=>B}};t.bailableWait=s;const o=_=>{const S=_.reduce((j,q)=>j+q.length,0),B=new Uint8Array(S);let V=0;return _.forEach(j=>{B.set(j,V),V+=j.length}),B};t.flattenUint8Arrays=o;const u=async _=>{const S=[];for await(const B of _)S.push(B);return(0,t.flattenUint8Arrays)(S)};t.streamToBuffer=u;const l="234567abcdefghijklmnopqrstuvwxyz",f=_=>{let S="";for(;_;){const B=_%32;_=Math.floor(_/32),S=l.charAt(B)+S}return S};t.s32encode=f;const c=_=>{let S=0;for(const B of _)S=S*32+l.indexOf(B);return S};t.s32decode=c;const d=async(_,S)=>{const B=await Promise.all(_.map(V=>S(V)));return _.filter((V,j)=>B[j])};t.asyncFilter=d;const y=_=>!!_&&_.code;t.isErrnoException=y;const p=(_,S)=>!!_&&typeof _=="object"&&_.message===S;t.errHasMsg=p;const h=(_,S)=>_.reduce((B,V,j)=>{const q=Math.floor(j/S);return B[q]||(B[q]=[]),B[q].push(V),B},[]);t.chunkArray=h;const g=_=>{const S=[];for(let B=0;B<_;B++)S.push(B);return S};t.range=g;const R=_=>[...new Set(_)];t.dedupeStrs=R;const A=(_,S)=>{const B=parseInt(_||"",10);return isNaN(B)?S:B};t.parseIntWithFallback=A})(vi);var _i={};Object.defineProperty(_i,"__esModule",{value:!0});_i.mapDefined=_i.keyBy=void 0;const Gp=(t,e)=>t.reduce((r,n)=>(r[n[e]]=n,r),{});_i.keyBy=Gp;const qp=(t,e)=>{const r=[];for(const n of t){const s=e(n);s!==void 0&&r.push(s)}return r};_i.mapDefined=qp;var qu={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.handleAllSettledErrors=t.AsyncBufferFullError=t.AsyncBuffer=t.allComplete=t.createDeferrables=t.createDeferrable=t.readFromGenerator=void 0;const e=vi,r=async(d,y,p=Promise.resolve(),h=Number.MAX_SAFE_INTEGER)=>{const g=[];let R,A=!1;const _=async()=>{if(await y(g.at(-1)))return!0;const B=(0,e.bailableWait)(20);return await B.wait(),R=B.bail,A?!1:await _()},S=new Promise(B=>{p.then(()=>{_().then(()=>B())})});try{for(;g.length{let d;const y=new Promise(p=>{d=()=>p()});return{resolve:d,complete:y}};t.createDeferrable=n;const s=d=>{const y=[];for(let p=0;p{await Promise.all(d.map(y=>y.complete))};t.allComplete=o;class u{constructor(y){Object.defineProperty(this,"maxSize",{enumerable:!0,configurable:!0,writable:!0,value:y}),Object.defineProperty(this,"buffer",{enumerable:!0,configurable:!0,writable:!0,value:[]}),Object.defineProperty(this,"promise",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"resolve",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"closed",{enumerable:!0,configurable:!0,writable:!0,value:!1}),Object.defineProperty(this,"toThrow",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.promise=Promise.resolve(),this.resolve=()=>null,this.resetPromise()}get curr(){return this.buffer}get size(){return this.buffer.length}get isClosed(){return this.closed}resetPromise(){this.promise=new Promise(y=>this.resolve=y)}push(y){this.buffer.push(y),this.resolve()}pushMany(y){y.forEach(p=>this.buffer.push(p)),this.resolve()}async*events(){for(;;){if(this.closed&&this.buffer.length===0){if(this.toThrow)throw this.toThrow;return}if(await this.promise,this.toThrow)throw this.toThrow;if(this.maxSize&&this.size>this.maxSize)throw new l(this.maxSize);const[y,...p]=this.buffer;y?(this.buffer=p,yield y):this.resetPromise()}}throw(y){this.toThrow=y,this.closed=!0,this.resolve()}close(){this.closed=!0,this.resolve()}}t.AsyncBuffer=u;class l extends Error{constructor(y){super(`ReachedMaxBufferSize: ${y}`)}}t.AsyncBufferFullError=l;const f=d=>{const y=d.filter(c).map(p=>p.reason);if(y.length!==0)throw y.length===1?y[0]:new AggregateError(y,"Multiple errors: "+y.map(p=>p==null?void 0:p.message).join(` +`))};t.handleAllSettledErrors=f;const c=d=>d.status==="rejected"})(qu);var En={};Object.defineProperty(En,"__esModule",{value:!0});En.TID=void 0;const ma=vi,il=13;let oo=0,nl=0,ba=null;function sl(t){return t.replaceAll("-","")}class or{constructor(e){Object.defineProperty(this,"str",{enumerable:!0,configurable:!0,writable:!0,value:void 0});const r=sl(e);if(r.length!==il)throw new Error(`Poorly formatted TID: ${r.length} length`);this.str=r}static next(e){const r=Math.max(Date.now(),oo);r===oo&&nl++,oo=r;const n=r*1e3+nl;ba===null&&(ba=Math.floor(Math.random()*32));const s=or.fromTime(n,ba);return!e||s.newerThan(e)?s:or.fromTime(e.timestamp()+1,ba)}static nextStr(e){return or.next(e?new or(e):void 0).toString()}static fromTime(e,r){const n=`${(0,ma.s32encode)(e)}${(0,ma.s32encode)(r).padStart(2,"2")}`;return new or(n)}static fromStr(e){return new or(e)}static oldestFirst(e,r){return e.compareTo(r)}static newestFirst(e,r){return r.compareTo(e)}static is(e){return sl(e).length===il}timestamp(){return(0,ma.s32decode)(this.str.slice(0,11))}clockid(){return(0,ma.s32decode)(this.str.slice(11,13))}formatted(){const e=this.toString();return`${e.slice(0,4)}-${e.slice(4,7)}-${e.slice(7,11)}-${e.slice(11,13)}`}toString(){return this.str}compareTo(e){return this.str>e.str?1:this.str0}olderThan(e){return this.compareTo(e)<0}}En.TID=or;En.default=or;var Fu={},Fp=Xu,al=128,Xp=127,zp=~Xp,Zp=Math.pow(2,31);function Xu(t,e,r){e=e||[],r=r||0;for(var n=r;t>=Zp;)e[r++]=t&255|al,t/=128;for(;t&zp;)e[r++]=t&255|al,t>>>=7;return e[r]=t|0,Xu.bytes=r-n+1,e}var Hp=ho,Wp=128,ol=127;function ho(t,n){var r=0,n=n||0,s=0,o=n,u,l=t.length;do{if(o>=l)throw ho.bytes=0,new RangeError("Could not decode varint");u=t[o++],r+=s<28?(u&ol)<=Wp);return ho.bytes=o-n,r}var Jp=Math.pow(2,7),Qp=Math.pow(2,14),Yp=Math.pow(2,21),e0=Math.pow(2,28),t0=Math.pow(2,35),r0=Math.pow(2,42),i0=Math.pow(2,49),n0=Math.pow(2,56),s0=Math.pow(2,63),a0=function(t){return t[Ta.decode(t,e),Ta.decode.bytes],wa=(t,e,r=0)=>(Ta.encode(t,e,r),e),Ca=t=>Ta.encodingLength(t),l0=(t,e)=>{if(t===e)return!0;if(t.byteLength!==e.byteLength)return!1;for(let r=0;r{if(t instanceof Uint8Array&&t.constructor.name==="Uint8Array")return t;if(t instanceof ArrayBuffer)return new Uint8Array(t);if(ArrayBuffer.isView(t))return new Uint8Array(t.buffer,t.byteOffset,t.byteLength);throw new Error("Unknown type, must be binary type")},u0=t=>new TextEncoder().encode(t),c0=t=>new TextDecoder().decode(t),f0=(t,e)=>{const r=e.byteLength,n=Ca(t),s=n+Ca(r),o=new Uint8Array(s+r);return wa(t,o,0),wa(r,o,n),o.set(e,s),new So(t,r,e,o)},d0=t=>{const e=Lo(t),[r,n]=Eo(e),[s,o]=Eo(e.subarray(n)),u=e.subarray(n+o);if(u.byteLength!==s)throw new Error("Incorrect length");return new So(r,s,u,e)},p0=(t,e)=>t===e?!0:t.code===e.code&&t.size===e.size&&l0(t.bytes,e.bytes);class So{constructor(e,r,n,s){this.code=e,this.size=r,this.digest=n,this.bytes=s}}function m0(t,e){if(t.length>=255)throw new TypeError("Alphabet too long");for(var r=new Uint8Array(256),n=0;n>>0,V=new Uint8Array(B);_!==S;){for(var j=g[_],q=0,X=B-1;(j!==0||q>>0,V[X]=j%l>>>0,j=j/l>>>0;if(j!==0)throw new Error("Non-zero carry");A=q,_++}for(var oe=B-A;oe!==B&&V[oe]===0;)oe++;for(var ce=f.repeat(R);oe>>0,B=new Uint8Array(S);g[R];){var V=r[g.charCodeAt(R)];if(V===255)return;for(var j=0,q=S-1;(V!==0||j<_)&&q!==-1;q--,j++)V+=l*B[q]>>>0,B[q]=V%256>>>0,V=V/256>>>0;if(V!==0)throw new Error("Non-zero carry");_=j,R++}if(g[R]!==" "){for(var X=S-_;X!==S&&B[X]===0;)X++;for(var oe=new Uint8Array(A+(S-X)),ce=A;X!==S;)oe[ce++]=B[X++];return oe}}}function h(g){var R=p(g);if(R)return R;throw new Error(`Non-${e} character`)}return{encode:y,decodeUnsafe:p,decode:h}}var b0=m0,y0=b0;class h0{constructor(e,r,n){this.name=e,this.prefix=r,this.baseEncode=n}encode(e){if(e instanceof Uint8Array)return`${this.prefix}${this.baseEncode(e)}`;throw Error("Unknown type, must be binary type")}}class E0{constructor(e,r,n){if(this.name=e,this.prefix=r,r.codePointAt(0)===void 0)throw new Error("Invalid prefix character");this.prefixCodePoint=r.codePointAt(0),this.baseDecode=n}decode(e){if(typeof e=="string"){if(e.codePointAt(0)!==this.prefixCodePoint)throw Error(`Unable to decode multibase string ${JSON.stringify(e)}, ${this.name} decoder only supports inputs prefixed with ${this.prefix}`);return this.baseDecode(e.slice(this.prefix.length))}else throw Error("Can only multibase decode strings")}or(e){return zu(this,e)}}class x0{constructor(e){this.decoders=e}or(e){return zu(this,e)}decode(e){const r=e[0],n=this.decoders[r];if(n)return n.decode(e);throw RangeError(`Unable to decode multibase string ${JSON.stringify(e)}, only inputs prefixed with ${Object.keys(this.decoders)} are supported`)}}const zu=(t,e)=>new x0({...t.decoders||{[t.prefix]:t},...e.decoders||{[e.prefix]:e}});class g0{constructor(e,r,n,s){this.name=e,this.prefix=r,this.baseEncode=n,this.baseDecode=s,this.encoder=new h0(e,r,n),this.decoder=new E0(e,r,s)}encode(e){return this.encoder.encode(e)}decode(e){return this.decoder.decode(e)}}const Va=({name:t,prefix:e,encode:r,decode:n})=>new g0(t,e,r,n),xn=({prefix:t,name:e,alphabet:r})=>{const{encode:n,decode:s}=y0(r,e);return Va({prefix:t,name:e,encode:n,decode:o=>Lo(s(o))})},R0=(t,e,r,n)=>{const s={};for(let d=0;d=8&&(l-=8,u[c++]=255&f>>l)}if(l>=r||255&f<<8-l)throw new SyntaxError("Unexpected end of data");return u},A0=(t,e,r)=>{const n=e[e.length-1]==="=",s=(1<r;)u-=r,o+=e[s&l>>u];if(u&&(o+=e[s&l<Va({prefix:e,name:t,encode(s){return A0(s,n,r)},decode(s){return R0(s,n,r,t)}}),lr=xn({name:"base58btc",prefix:"z",alphabet:"123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"}),v0=xn({name:"base58flickr",prefix:"Z",alphabet:"123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ"}),_0=Object.freeze(Object.defineProperty({__proto__:null,base58btc:lr,base58flickr:v0},Symbol.toStringTag,{value:"Module"})),cn=rt({prefix:"b",name:"base32",alphabet:"abcdefghijklmnopqrstuvwxyz234567",bitsPerChar:5}),T0=rt({prefix:"B",name:"base32upper",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZ234567",bitsPerChar:5}),w0=rt({prefix:"c",name:"base32pad",alphabet:"abcdefghijklmnopqrstuvwxyz234567=",bitsPerChar:5}),C0=rt({prefix:"C",name:"base32padupper",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZ234567=",bitsPerChar:5}),L0=rt({prefix:"v",name:"base32hex",alphabet:"0123456789abcdefghijklmnopqrstuv",bitsPerChar:5}),S0=rt({prefix:"V",name:"base32hexupper",alphabet:"0123456789ABCDEFGHIJKLMNOPQRSTUV",bitsPerChar:5}),k0=rt({prefix:"t",name:"base32hexpad",alphabet:"0123456789abcdefghijklmnopqrstuv=",bitsPerChar:5}),D0=rt({prefix:"T",name:"base32hexpadupper",alphabet:"0123456789ABCDEFGHIJKLMNOPQRSTUV=",bitsPerChar:5}),B0=rt({prefix:"h",name:"base32z",alphabet:"ybndrfg8ejkmcpqxot1uwisza345h769",bitsPerChar:5}),P0=Object.freeze(Object.defineProperty({__proto__:null,base32:cn,base32hex:L0,base32hexpad:k0,base32hexpadupper:D0,base32hexupper:S0,base32pad:w0,base32padupper:C0,base32upper:T0,base32z:B0},Symbol.toStringTag,{value:"Module"}));class nt{constructor(e,r,n,s){this.code=r,this.version=e,this.multihash=n,this.bytes=s,this.byteOffset=s.byteOffset,this.byteLength=s.byteLength,this.asCID=this,this._baseCache=new Map,Object.defineProperties(this,{byteOffset:ha,byteLength:ha,code:ya,version:ya,multihash:ya,bytes:ya,_baseCache:ha,asCID:ha})}toV0(){switch(this.version){case 0:return this;default:{const{code:e,multihash:r}=this;if(e!==en)throw new Error("Cannot convert a non dag-pb CID to CIDv0");if(r.code!==I0)throw new Error("Cannot convert non sha2-256 multihash CID to CIDv0");return nt.createV0(r)}}}toV1(){switch(this.version){case 0:{const{code:e,digest:r}=this.multihash,n=f0(e,r);return nt.createV1(this.code,n)}case 1:return this;default:throw Error(`Can not convert CID version ${this.version} to version 0. This is a bug please report`)}}equals(e){return e&&this.code===e.code&&this.version===e.version&&p0(this.multihash,e.multihash)}toString(e){const{bytes:r,version:n,_baseCache:s}=this;switch(n){case 0:return U0(r,s,e||lr.encoder);default:return V0(r,s,e||cn.encoder)}}toJSON(){return{code:this.code,version:this.version,hash:this.multihash.bytes}}get[Symbol.toStringTag](){return"CID"}[Symbol.for("nodejs.util.inspect.custom")](){return"CID("+this.toString()+")"}static isCID(e){return j0(/^0\.0/,N0),!!(e&&(e[ul]||e.asCID===e))}get toBaseEncodedString(){throw new Error("Deprecated, use .toString()")}get codec(){throw new Error('"codec" property is deprecated, use integer "code" property instead')}get buffer(){throw new Error("Deprecated .buffer property, use .bytes to get Uint8Array instead")}get multibaseName(){throw new Error('"multibaseName" property is deprecated')}get prefix(){throw new Error('"prefix" property is deprecated')}static asCID(e){if(e instanceof nt)return e;if(e!=null&&e.asCID===e){const{version:r,code:n,multihash:s,bytes:o}=e;return new nt(r,n,s,o||ll(r,n,s.bytes))}else if(e!=null&&e[ul]===!0){const{version:r,multihash:n,code:s}=e,o=d0(n);return nt.create(r,s,o)}else return null}static create(e,r,n){if(typeof r!="number")throw new Error("String codecs are no longer supported");switch(e){case 0:{if(r!==en)throw new Error(`Version 0 CID must use dag-pb (code: ${en}) block encoding`);return new nt(e,r,n,n.bytes)}case 1:{const s=ll(e,r,n.bytes);return new nt(e,r,n,s)}default:throw new Error("Invalid version")}}static createV0(e){return nt.create(0,en,e)}static createV1(e,r){return nt.create(1,e,r)}static decode(e){const[r,n]=nt.decodeFirst(e);if(n.length)throw new Error("Incorrect length");return r}static decodeFirst(e){const r=nt.inspectBytes(e),n=r.size-r.multihashSize,s=Lo(e.subarray(n,n+r.multihashSize));if(s.byteLength!==r.multihashSize)throw new Error("Incorrect length");const o=s.subarray(r.multihashSize-r.digestSize),u=new So(r.multihashCode,r.digestSize,o,s);return[r.version===0?nt.createV0(u):nt.createV1(r.codec,u),e.subarray(r.size)]}static inspectBytes(e){let r=0;const n=()=>{const[y,p]=Eo(e.subarray(r));return r+=p,y};let s=n(),o=en;if(s===18?(s=0,r=0):s===1&&(o=n()),s!==0&&s!==1)throw new RangeError(`Invalid CID version ${s}`);const u=r,l=n(),f=n(),c=r+f,d=c-u;return{version:s,codec:o,multihashCode:l,digestSize:f,multihashSize:d,size:c}}static parse(e,r){const[n,s]=K0(e,r),o=nt.decode(s);return o._baseCache.set(n,e),o}}const K0=(t,e)=>{switch(t[0]){case"Q":{const r=e||lr;return[lr.prefix,r.decode(`${lr.prefix}${t}`)]}case lr.prefix:{const r=e||lr;return[lr.prefix,r.decode(t)]}case cn.prefix:{const r=e||cn;return[cn.prefix,r.decode(t)]}default:{if(e==null)throw Error("To parse non base32 or base58btc encoded CID multibase decoder must be provided");return[t[0],e.decode(t)]}}},U0=(t,e,r)=>{const{prefix:n}=r;if(n!==lr.prefix)throw Error(`Cannot string encode V0 in ${r.name} encoding`);const s=e.get(n);if(s==null){const o=r.encode(t).slice(1);return e.set(n,o),o}else return s},V0=(t,e,r)=>{const{prefix:n}=r,s=e.get(n);if(s==null){const o=r.encode(t);return e.set(n,o),o}else return s},en=112,I0=18,ll=(t,e,r)=>{const n=Ca(t),s=n+Ca(e),o=new Uint8Array(s+r.byteLength);return wa(t,o,0),wa(e,o,n),o.set(r,s),o},ul=Symbol.for("@ipld/js-cid/CID"),ya={writable:!1,configurable:!1,enumerable:!0},ha={writable:!1,enumerable:!1,configurable:!1},O0="0.0.0-dev",j0=(t,e)=>{if(t.test(O0))console.warn(e);else throw new Error(e)},N0=`CID.isCID(v) is deprecated and will be removed in the next major release. +Following code pattern: + +if (CID.isCID(value)) { + doSomethingWithCID(value) +} + +Is replaced with: + +const cid = CID.asCID(value) +if (cid) { + // Make sure to use cid instead of value + doSomethingWithCID(cid) +} +`,M0=Object.freeze(Object.defineProperty({__proto__:null,CID:nt},Symbol.toStringTag,{value:"Module"})),Fi=ku(M0);function $0(t,e){for(let r=0;re[r])return 1}return t.byteLength>e.byteLength?1:t.byteLengths+o.length,0));const r=new Uint8Array(e);let n=0;for(const s of t)r.set(s,n),n+=s.length;return r}function q0(t,e){if(t===e)return!0;if(t.byteLength!==e.byteLength)return!1;for(let r=0;rc0(t),decode:t=>u0(t)}),X0=Object.freeze(Object.defineProperty({__proto__:null,identity:F0},Symbol.toStringTag,{value:"Module"})),z0=rt({prefix:"0",name:"base2",alphabet:"01",bitsPerChar:1}),Z0=Object.freeze(Object.defineProperty({__proto__:null,base2:z0},Symbol.toStringTag,{value:"Module"})),H0=rt({prefix:"7",name:"base8",alphabet:"01234567",bitsPerChar:3}),W0=Object.freeze(Object.defineProperty({__proto__:null,base8:H0},Symbol.toStringTag,{value:"Module"})),J0=xn({prefix:"9",name:"base10",alphabet:"0123456789"}),Q0=Object.freeze(Object.defineProperty({__proto__:null,base10:J0},Symbol.toStringTag,{value:"Module"})),Y0=rt({prefix:"f",name:"base16",alphabet:"0123456789abcdef",bitsPerChar:4}),em=rt({prefix:"F",name:"base16upper",alphabet:"0123456789ABCDEF",bitsPerChar:4}),tm=Object.freeze(Object.defineProperty({__proto__:null,base16:Y0,base16upper:em},Symbol.toStringTag,{value:"Module"})),rm=xn({prefix:"k",name:"base36",alphabet:"0123456789abcdefghijklmnopqrstuvwxyz"}),im=xn({prefix:"K",name:"base36upper",alphabet:"0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ"}),nm=Object.freeze(Object.defineProperty({__proto__:null,base36:rm,base36upper:im},Symbol.toStringTag,{value:"Module"})),sm=rt({prefix:"m",name:"base64",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",bitsPerChar:6}),am=rt({prefix:"M",name:"base64pad",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",bitsPerChar:6}),om=rt({prefix:"u",name:"base64url",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_",bitsPerChar:6}),lm=rt({prefix:"U",name:"base64urlpad",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_=",bitsPerChar:6}),um=Object.freeze(Object.defineProperty({__proto__:null,base64:sm,base64pad:am,base64url:om,base64urlpad:lm},Symbol.toStringTag,{value:"Module"})),Zu=Array.from("🚀🪐☄🛰🌌🌑🌒🌓🌔🌕🌖🌗🌘🌍🌏🌎🐉☀💻🖥💾💿😂❤😍🤣😊🙏💕😭😘👍😅👏😁🔥🥰💔💖💙😢🤔😆🙄💪😉☺👌🤗💜😔😎😇🌹🤦🎉💞✌✨🤷😱😌🌸🙌😋💗💚😏💛🙂💓🤩😄😀🖤😃💯🙈👇🎶😒🤭❣😜💋👀😪😑💥🙋😞😩😡🤪👊🥳😥🤤👉💃😳✋😚😝😴🌟😬🙃🍀🌷😻😓⭐✅🥺🌈😈🤘💦✔😣🏃💐☹🎊💘😠☝😕🌺🎂🌻😐🖕💝🙊😹🗣💫💀👑🎵🤞😛🔴😤🌼😫⚽🤙☕🏆🤫👈😮🙆🍻🍃🐶💁😲🌿🧡🎁⚡🌞🎈❌✊👋😰🤨😶🤝🚶💰🍓💢🤟🙁🚨💨🤬✈🎀🍺🤓😙💟🌱😖👶🥴▶➡❓💎💸⬇😨🌚🦋😷🕺⚠🙅😟😵👎🤲🤠🤧📌🔵💅🧐🐾🍒😗🤑🌊🤯🐷☎💧😯💆👆🎤🙇🍑❄🌴💣🐸💌📍🥀🤢👅💡💩👐📸👻🤐🤮🎼🥵🚩🍎🍊👼💍📣🥂"),cm=Zu.reduce((t,e,r)=>(t[r]=e,t),[]),fm=Zu.reduce((t,e,r)=>(t[e.codePointAt(0)]=r,t),[]);function dm(t){return t.reduce((e,r)=>(e+=cm[r],e),"")}function pm(t){const e=[];for(const r of t){const n=fm[r.codePointAt(0)];if(n===void 0)throw new Error(`Non-base256emoji character: ${r}`);e.push(n)}return new Uint8Array(e)}const mm=Va({prefix:"🚀",name:"base256emoji",encode:dm,decode:pm}),bm=Object.freeze(Object.defineProperty({__proto__:null,base256emoji:mm},Symbol.toStringTag,{value:"Module"}));new TextEncoder;new TextDecoder;const cl={...X0,...Z0,...W0,...Q0,...tm,...P0,...nm,..._0,...um,...bm};function Hu(t,e,r,n){return{name:t,prefix:e,encoder:{name:t,prefix:e,encode:r},decoder:{decode:n}}}const fl=Hu("utf8","u",t=>"u"+new TextDecoder("utf8").decode(t),t=>new TextEncoder().encode(t.substring(1))),lo=Hu("ascii","a",t=>{let e="a";for(let r=0;r{t=t.substring(1);const e=new Uint8Array(t.length);for(let r=0;r{if(Array.isArray(c))return c.map(d=>(0,t.jsonToIpld)(d));if(c&&typeof c=="object"){if(typeof c.$link=="string"&&Object.keys(c).length===1)return s.CID.parse(c.$link);if(typeof c.$bytes=="string"&&Object.keys(c).length===1)return o.fromString(c.$bytes,"base64");const d={};for(const y of Object.keys(c))d[y]=(0,t.jsonToIpld)(c[y]);return d}return c};t.jsonToIpld=u;const l=c=>{if(Array.isArray(c))return c.map(d=>(0,t.ipldToJson)(d));if(c&&typeof c=="object"){if(c instanceof Uint8Array)return{$bytes:o.toString(c,"base64")};if(s.CID.asCID(c))return{$link:c.toString()};const d={};for(const y of Object.keys(c))d[y]=(0,t.ipldToJson)(c[y]);return d}return c};t.ipldToJson=l;const f=(c,d)=>{var y;if(Array.isArray(c)&&Array.isArray(d)){if(c.length!==d.length)return!1;for(let p=0;p!0,getWaitMs:s=Qu}=e;let o=0,u;for(;!u;)try{return await t()}catch(l){const f=s(o);oe.CID.asCID(s)!==null,{message:"Not a CID"}).transform(s=>e.CID.asCID(s));t.schema={cid:n,bytes:r.z.instanceof(Uint8Array),string:r.z.string(),array:r.z.array(r.z.unknown()),map:r.z.record(r.z.string(),r.z.unknown()),unknown:r.z.unknown()},t.def={cid:{name:"cid",schema:t.schema.cid},bytes:{name:"bytes",schema:t.schema.bytes},string:{name:"string",schema:t.schema.string},map:{name:"map",schema:t.schema.map},unknown:{name:"unknown",schema:t.schema.unknown}}})(Yu);var ec={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.addHoursToDate=t.lessThanAgoMs=t.DAY=t.HOUR=t.MINUTE=t.SECOND=void 0,t.SECOND=1e3,t.MINUTE=t.SECOND*60,t.HOUR=t.MINUTE*60,t.DAY=t.HOUR*24;const e=(n,s)=>Date.now(){const o=s?new Date(s):new Date;return o.setHours(o.getHours()+n),o};t.addHoursToDate=r})(ec);var yt={},ko={},Do={},Bo={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EXTENDED_PICTOGRAPHIC=t.CLUSTER_BREAK=void 0,function(e){e[e.CR=0]="CR",e[e.LF=1]="LF",e[e.CONTROL=2]="CONTROL",e[e.EXTEND=3]="EXTEND",e[e.REGIONAL_INDICATOR=4]="REGIONAL_INDICATOR",e[e.SPACINGMARK=5]="SPACINGMARK",e[e.L=6]="L",e[e.V=7]="V",e[e.T=8]="T",e[e.LV=9]="LV",e[e.LVT=10]="LVT",e[e.OTHER=11]="OTHER",e[e.PREPEND=12]="PREPEND",e[e.E_BASE=13]="E_BASE",e[e.E_MODIFIER=14]="E_MODIFIER",e[e.ZWJ=15]="ZWJ",e[e.GLUE_AFTER_ZWJ=16]="GLUE_AFTER_ZWJ",e[e.E_BASE_GAZ=17]="E_BASE_GAZ"}(t.CLUSTER_BREAK||(t.CLUSTER_BREAK={})),t.EXTENDED_PICTOGRAPHIC=101})(Bo);var Po={};Object.defineProperty(Po,"__esModule",{value:!0});const be=Bo,nr=0,uo=1,_m=2,Tm=3,wm=4;class Cm{static isSurrogate(e,r){return 55296<=e.charCodeAt(r)&&e.charCodeAt(r)<=56319&&56320<=e.charCodeAt(r+1)&&e.charCodeAt(r+1)<=57343}static codePointAt(e,r){r===void 0&&(r=0);const n=e.charCodeAt(r);if(55296<=n&&n<=56319&&r=1){const s=e.charCodeAt(r-1),o=n;return 55296<=s&&s<=56319?(s-55296)*1024+(o-56320)+65536:o}return n}static shouldBreak(e,r,n,s,o,u){const l=[e].concat(r).concat([n]),f=[s].concat(o).concat([u]),c=l[l.length-2],d=n,y=u,p=l.lastIndexOf(be.CLUSTER_BREAK.REGIONAL_INDICATOR);if(p>0&&l.slice(1,p).every(function(g){return g===be.CLUSTER_BREAK.REGIONAL_INDICATOR})&&[be.CLUSTER_BREAK.PREPEND,be.CLUSTER_BREAK.REGIONAL_INDICATOR].indexOf(c)===-1)return l.filter(function(g){return g===be.CLUSTER_BREAK.REGIONAL_INDICATOR}).length%2===1?Tm:wm;if(c===be.CLUSTER_BREAK.CR&&d===be.CLUSTER_BREAK.LF)return nr;if(c===be.CLUSTER_BREAK.CONTROL||c===be.CLUSTER_BREAK.CR||c===be.CLUSTER_BREAK.LF)return uo;if(d===be.CLUSTER_BREAK.CONTROL||d===be.CLUSTER_BREAK.CR||d===be.CLUSTER_BREAK.LF)return uo;if(c===be.CLUSTER_BREAK.L&&(d===be.CLUSTER_BREAK.L||d===be.CLUSTER_BREAK.V||d===be.CLUSTER_BREAK.LV||d===be.CLUSTER_BREAK.LVT))return nr;if((c===be.CLUSTER_BREAK.LV||c===be.CLUSTER_BREAK.V)&&(d===be.CLUSTER_BREAK.V||d===be.CLUSTER_BREAK.T))return nr;if((c===be.CLUSTER_BREAK.LVT||c===be.CLUSTER_BREAK.T)&&d===be.CLUSTER_BREAK.T)return nr;if(d===be.CLUSTER_BREAK.EXTEND||d===be.CLUSTER_BREAK.ZWJ)return nr;if(d===be.CLUSTER_BREAK.SPACINGMARK)return nr;if(c===be.CLUSTER_BREAK.PREPEND)return nr;const h=f.slice(0,-1).lastIndexOf(be.EXTENDED_PICTOGRAPHIC);return h!==-1&&f[h]===be.EXTENDED_PICTOGRAPHIC&&l.slice(h+1,-2).every(function(g){return g===be.CLUSTER_BREAK.EXTEND})&&c===be.CLUSTER_BREAK.ZWJ&&y===be.EXTENDED_PICTOGRAPHIC?nr:r.indexOf(be.CLUSTER_BREAK.REGIONAL_INDICATOR)!==-1?_m:c===be.CLUSTER_BREAK.REGIONAL_INDICATOR&&d===be.CLUSTER_BREAK.REGIONAL_INDICATOR?nr:uo}}Po.default=Cm;var Ko={};Object.defineProperty(Ko,"__esModule",{value:!0});class Lm{constructor(e,r){this._index=0,this._str=e,this._nextBreak=r}[Symbol.iterator](){return this}next(){let e;if((e=this._nextBreak(this._str,this._index))=e.length-1)return e.length;const n=Ea.default.codePointAt(e,r),s=sr.getGraphemeBreakProperty(n),o=sr.getEmojiProperty(n),u=[],l=[];for(let f=r+1;fnew TextEncoder().encode(t).byteLength;yt.utf8Len=Im;const Om=t=>new Vm.default().countGraphemes(t);yt.graphemeLen=Om;const jm=t=>La.toString(La.fromString(t,"utf8"),"base64url");yt.utf8ToB64Url=jm;const Nm=t=>La.toString(La.fromString(t,"base64url"),"utf8");yt.b64UrlToUtf8=Nm;const Mm=t=>{const e=t.match(rc);if(!(e!=null&&e.groups))return null;const r=e.groups;return{grandfathered:r.grandfathered,language:r.language,extlang:r.extlang,script:r.script,region:r.region,variant:r.variant,extension:r.extension,privateUse:r.privateUseA||r.privateUseB}};yt.parseLanguage=Mm;const $m=t=>rc.test(t);yt.validateLanguage=$m;const rc=/^((?(en-GB-oed|i-ami|i-bnn|i-default|i-enochian|i-hak|i-klingon|i-lux|i-mingo|i-navajo|i-pwn|i-tao|i-tay|i-tsu|sgn-BE-FR|sgn-BE-NL|sgn-CH-DE)|(art-lojban|cel-gaulish|no-bok|no-nyn|zh-guoyu|zh-hakka|zh-min|zh-min-nan|zh-xiang))|((?([A-Za-z]{2,3}(-(?[A-Za-z]{3}(-[A-Za-z]{3}){0,2}))?)|[A-Za-z]{4}|[A-Za-z]{5,8})(-(? - + diff --git a/docs/sw.js b/docs/sw.js index f04f243..2f43f6a 100644 --- a/docs/sw.js +++ b/docs/sw.js @@ -1 +1 @@ -if(!self.define){let e,s={};const i=(i,n)=>(i=new URL(i+".js",n).href,s[i]||new Promise((s=>{if("document"in self){const e=document.createElement("script");e.src=i,e.onload=s,document.head.appendChild(e)}else e=i,importScripts(i),s()})).then((()=>{let e=s[i];if(!e)throw new Error(`Module ${i} didn’t register its module`);return e})));self.define=(n,r)=>{const c=e||("document"in self?document.currentScript.src:"")||location.href;if(s[c])return;let t={};const o=e=>i(e,c),l={module:{uri:c},exports:t,require:o};s[c]=Promise.all(n.map((e=>l[e]||o(e)))).then((e=>(r(...e),t)))}}define(["./workbox-7cfec069"],(function(e){"use strict";self.addEventListener("message",(e=>{e.data&&"SKIP_WAITING"===e.data.type&&self.skipWaiting()})),e.precacheAndRoute([{url:"assets/index-Bl3PYrVF.css",revision:null},{url:"assets/index-CvWdp5iJ.js",revision:null},{url:"index.html",revision:"cb591cda86ac14ef48cc8725cb48ba30"},{url:"registerSW.js",revision:"402b66900e731ca748771b6fc5e7a068"},{url:"app.png",revision:"2c49c49681cbc64897bc43eb543ace4e"},{url:"manifest.webmanifest",revision:"1f1242ececd6d07fc96b9b5818a1b269"}],{}),e.cleanupOutdatedCaches(),e.registerRoute(new e.NavigationRoute(e.createHandlerBoundToURL("index.html")))})); +if(!self.define){let e,s={};const i=(i,n)=>(i=new URL(i+".js",n).href,s[i]||new Promise((s=>{if("document"in self){const e=document.createElement("script");e.src=i,e.onload=s,document.head.appendChild(e)}else e=i,importScripts(i),s()})).then((()=>{let e=s[i];if(!e)throw new Error(`Module ${i} didn’t register its module`);return e})));self.define=(n,r)=>{const t=e||("document"in self?document.currentScript.src:"")||location.href;if(s[t])return;let o={};const c=e=>i(e,t),l={module:{uri:t},exports:o,require:c};s[t]=Promise.all(n.map((e=>l[e]||c(e)))).then((e=>(r(...e),o)))}}define(["./workbox-7cfec069"],(function(e){"use strict";self.addEventListener("message",(e=>{e.data&&"SKIP_WAITING"===e.data.type&&self.skipWaiting()})),e.precacheAndRoute([{url:"assets/index-1TGJS-me.js",revision:null},{url:"assets/index-Bl3PYrVF.css",revision:null},{url:"index.html",revision:"19a7da602f81029a2950f0b9f6e9658a"},{url:"registerSW.js",revision:"402b66900e731ca748771b6fc5e7a068"},{url:"app.png",revision:"2c49c49681cbc64897bc43eb543ace4e"},{url:"manifest.webmanifest",revision:"1f1242ececd6d07fc96b9b5818a1b269"}],{}),e.cleanupOutdatedCaches(),e.registerRoute(new e.NavigationRoute(e.createHandlerBoundToURL("index.html")))})); diff --git a/docs/version.json b/docs/version.json index e292c27..c27a1ef 100644 --- a/docs/version.json +++ b/docs/version.json @@ -1,3 +1,3 @@ { - "built_at": "2025-01-04T08:55:43.457Z" + "built_at": "2025-01-21T14:49:16.191Z" } \ No newline at end of file