@grackle-ai/web 0.132.0 → 0.132.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,40 @@
1
+ var Z;(function(e){e[e.Canceled=1]="Canceled",e[e.Unknown=2]="Unknown",e[e.InvalidArgument=3]="InvalidArgument",e[e.DeadlineExceeded=4]="DeadlineExceeded",e[e.NotFound=5]="NotFound",e[e.AlreadyExists=6]="AlreadyExists",e[e.PermissionDenied=7]="PermissionDenied",e[e.ResourceExhausted=8]="ResourceExhausted",e[e.FailedPrecondition=9]="FailedPrecondition",e[e.Aborted=10]="Aborted",e[e.OutOfRange=11]="OutOfRange",e[e.Unimplemented=12]="Unimplemented",e[e.Internal=13]="Internal",e[e.Unavailable=14]="Unavailable",e[e.DataLoss=15]="DataLoss",e[e.Unauthenticated=16]="Unauthenticated"})(Z||(Z={}));function at(e,n){return e!==null&&typeof e=="object"&&"$typeName"in e&&typeof e.$typeName=="string"?n===void 0?!0:n.typeName===e.$typeName:!1}var m;(function(e){e[e.DOUBLE=1]="DOUBLE",e[e.FLOAT=2]="FLOAT",e[e.INT64=3]="INT64",e[e.UINT64=4]="UINT64",e[e.INT32=5]="INT32",e[e.FIXED64=6]="FIXED64",e[e.FIXED32=7]="FIXED32",e[e.BOOL=8]="BOOL",e[e.STRING=9]="STRING",e[e.BYTES=12]="BYTES",e[e.UINT32=13]="UINT32",e[e.SFIXED32=15]="SFIXED32",e[e.SFIXED64=16]="SFIXED64",e[e.SINT32=17]="SINT32",e[e.SINT64=18]="SINT64"})(m||(m={}));function oa(){let e=0,n=0;for(let r=0;r<28;r+=7){let o=this.buf[this.pos++];if(e|=(o&127)<<r,(o&128)==0)return this.assertBounds(),[e,n]}let t=this.buf[this.pos++];if(e|=(t&15)<<28,n=(t&112)>>4,(t&128)==0)return this.assertBounds(),[e,n];for(let r=3;r<=31;r+=7){let o=this.buf[this.pos++];if(n|=(o&127)<<r,(o&128)==0)return this.assertBounds(),[e,n]}throw new Error("invalid varint")}function kn(e,n,t){for(let s=0;s<28;s=s+7){const i=e>>>s,a=!(!(i>>>7)&&n==0),c=(a?i|128:i)&255;if(t.push(c),!a)return}const r=e>>>28&15|(n&7)<<4,o=n>>3!=0;if(t.push((o?r|128:r)&255),!!o){for(let s=3;s<31;s=s+7){const i=n>>>s,a=!!(i>>>7),c=(a?i|128:i)&255;if(t.push(c),!a)return}t.push(n>>>31&1)}}const rn=4294967296;function Xt(e){const n=e[0]==="-";n&&(e=e.slice(1));const t=1e6;let r=0,o=0;function s(i,a){const c=Number(e.slice(i,a));o*=t,r=r*t+c,r>=rn&&(o=o+(r/rn|0),r=r%rn)}return s(-24,-18),s(-18,-12),s(-12,-6),s(-6),n?zo(r,o):ct(r,o)}function sa(e,n){let t=ct(e,n);const r=t.hi&2147483648;r&&(t=zo(t.lo,t.hi));const o=Xo(t.lo,t.hi);return r?"-"+o:o}function Xo(e,n){if({lo:e,hi:n}=ia(e,n),n<=2097151)return String(rn*n+e);const t=e&16777215,r=(e>>>24|n<<8)&16777215,o=n>>16&65535;let s=t+r*6777216+o*6710656,i=r+o*8147497,a=o*2;const c=1e7;return s>=c&&(i+=Math.floor(s/c),s%=c),i>=c&&(a+=Math.floor(i/c),i%=c),a.toString()+zt(i)+zt(s)}function ia(e,n){return{lo:e>>>0,hi:n>>>0}}function ct(e,n){return{lo:e|0,hi:n|0}}function zo(e,n){return n=~n,e?e=~e+1:n+=1,ct(e,n)}const zt=e=>{const n=String(e);return"0000000".slice(n.length)+n};function Jn(e,n){if(e>=0){for(;e>127;)n.push(e&127|128),e=e>>>7;n.push(e)}else{for(let t=0;t<9;t++)n.push(e&127|128),e=e>>7;n.push(1)}}function aa(){let e=this.buf[this.pos++],n=e&127;if((e&128)==0)return this.assertBounds(),n;if(e=this.buf[this.pos++],n|=(e&127)<<7,(e&128)==0)return this.assertBounds(),n;if(e=this.buf[this.pos++],n|=(e&127)<<14,(e&128)==0)return this.assertBounds(),n;if(e=this.buf[this.pos++],n|=(e&127)<<21,(e&128)==0)return this.assertBounds(),n;e=this.buf[this.pos++],n|=(e&15)<<28;for(let t=5;(e&128)!==0&&t<10;t++)e=this.buf[this.pos++];if((e&128)!=0)throw new Error("invalid varint");return this.assertBounds(),n>>>0}var Jt={};const w=ca();function ca(){const e=new DataView(new ArrayBuffer(8));if(typeof BigInt=="function"&&typeof e.getBigInt64=="function"&&typeof e.getBigUint64=="function"&&typeof e.setBigInt64=="function"&&typeof e.setBigUint64=="function"&&(!!globalThis.Deno||typeof process!="object"||typeof Jt!="object"||Jt.BUF_BIGINT_DISABLE!=="1")){const t=BigInt("-9223372036854775808"),r=BigInt("9223372036854775807"),o=BigInt("0"),s=BigInt("18446744073709551615");return{zero:BigInt(0),supported:!0,parse(i){const a=typeof i=="bigint"?i:BigInt(i);if(a>r||a<t)throw new Error(`invalid int64: ${i}`);return a},uParse(i){const a=typeof i=="bigint"?i:BigInt(i);if(a>s||a<o)throw new Error(`invalid uint64: ${i}`);return a},enc(i){return e.setBigInt64(0,this.parse(i),!0),{lo:e.getInt32(0,!0),hi:e.getInt32(4,!0)}},uEnc(i){return e.setBigInt64(0,this.uParse(i),!0),{lo:e.getInt32(0,!0),hi:e.getInt32(4,!0)}},dec(i,a){return e.setInt32(0,i,!0),e.setInt32(4,a,!0),e.getBigInt64(0,!0)},uDec(i,a){return e.setInt32(0,i,!0),e.setInt32(4,a,!0),e.getBigUint64(0,!0)}}}return{zero:"0",supported:!1,parse(t){return typeof t!="string"&&(t=t.toString()),Dt(t),t},uParse(t){return typeof t!="string"&&(t=t.toString()),xt(t),t},enc(t){return typeof t!="string"&&(t=t.toString()),Dt(t),Xt(t)},uEnc(t){return typeof t!="string"&&(t=t.toString()),xt(t),Xt(t)},dec(t,r){return sa(t,r)},uDec(t,r){return Xo(t,r)}}}function Dt(e){if(!/^-?[0-9]+$/.test(e))throw new Error("invalid int64: "+e)}function xt(e){if(!/^[0-9]+$/.test(e))throw new Error("invalid uint64: "+e)}function _e(e,n){switch(e){case m.STRING:return"";case m.BOOL:return!1;case m.DOUBLE:case m.FLOAT:return 0;case m.INT64:case m.UINT64:case m.SFIXED64:case m.FIXED64:case m.SINT64:return n?"0":w.zero;case m.BYTES:return new Uint8Array(0);default:return 0}}function ua(e,n){switch(e){case m.BOOL:return n===!1;case m.STRING:return n==="";case m.BYTES:return n instanceof Uint8Array&&!n.byteLength;default:return n==0}}const Jo=2,oe=Symbol.for("reflect unsafe local");function Do(e,n){const t=e[n.localName].case;return t===void 0?t:n.fields.find(r=>r.localName===t)}function la(e,n){const t=n.localName;if(n.oneof)return e[n.oneof.localName].case===t;if(n.presence!=Jo)return e[t]!==void 0&&Object.prototype.hasOwnProperty.call(e,t);switch(n.fieldKind){case"list":return e[t].length>0;case"map":return Object.keys(e[t]).length>0;case"scalar":return!ua(n.scalar,e[t]);case"enum":return e[t]!==n.enum.values[0].number}throw new Error("message field with implicit presence")}function Ue(e,n){return Object.prototype.hasOwnProperty.call(e,n)&&e[n]!==void 0}function xo(e,n){if(n.oneof){const t=e[n.oneof.localName];return t.case===n.localName?t.value:void 0}return e[n.localName]}function Ko(e,n,t){n.oneof?e[n.oneof.localName]={case:n.localName,value:t}:e[n.localName]=t}function da(e,n){const t=n.localName;if(n.oneof){const r=n.oneof.localName;e[r].case===t&&(e[r]={case:void 0})}else if(n.presence!=Jo)delete e[t];else switch(n.fieldKind){case"map":e[t]={};break;case"list":e[t]=[];break;case"enum":e[t]=n.enum.values[0].number;break;case"scalar":e[t]=_e(n.scalar,n.longAsString);break}}function ce(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function ut(e,n){var t,r,o,s;if(ce(e)&&oe in e&&"add"in e&&"field"in e&&typeof e.field=="function"){if(n!==void 0){const i=n,a=e.field();return i.listKind==a.listKind&&i.scalar===a.scalar&&((t=i.message)===null||t===void 0?void 0:t.typeName)===((r=a.message)===null||r===void 0?void 0:r.typeName)&&((o=i.enum)===null||o===void 0?void 0:o.typeName)===((s=a.enum)===null||s===void 0?void 0:s.typeName)}return!0}return!1}function lt(e,n){var t,r,o,s;if(ce(e)&&oe in e&&"has"in e&&"field"in e&&typeof e.field=="function"){if(n!==void 0){const i=n,a=e.field();return i.mapKey===a.mapKey&&i.mapKind==a.mapKind&&i.scalar===a.scalar&&((t=i.message)===null||t===void 0?void 0:t.typeName)===((r=a.message)===null||r===void 0?void 0:r.typeName)&&((o=i.enum)===null||o===void 0?void 0:o.typeName)===((s=a.enum)===null||s===void 0?void 0:s.typeName)}return!0}return!1}function dt(e,n){return ce(e)&&oe in e&&"desc"in e&&ce(e.desc)&&e.desc.kind==="message"&&(n===void 0||e.desc.typeName==n.typeName)}function fa(e){return Lo(e.$typeName)}function Ke(e){const n=e.fields[0];return Lo(e.typeName)&&n!==void 0&&n.fieldKind=="scalar"&&n.name=="value"&&n.number==1}function Lo(e){return e.startsWith("google.protobuf.")&&["DoubleValue","FloatValue","Int64Value","UInt64Value","Int32Value","UInt32Value","BoolValue","StringValue","BytesValue"].includes(e.substring(16))}const ma=999,ha=998,on=2;function H(e,n){if(at(n,e))return n;const t=Aa(e);return n!==void 0&&ga(e,t,n),t}function ga(e,n,t){for(const r of e.members){let o=t[r.localName];if(o==null)continue;let s;if(r.kind=="oneof"){const i=Do(t,r);if(!i)continue;s=i,o=xo(t,i)}else s=r;switch(s.fieldKind){case"message":o=ft(s,o);break;case"scalar":o=Mo(s,o);break;case"list":o=ba(s,o);break;case"map":o=pa(s,o);break}Ko(n,s,o)}return n}function Mo(e,n){return e.scalar==m.BYTES?mt(n):n}function pa(e,n){if(ce(n)){if(e.scalar==m.BYTES)return Kt(n,mt);if(e.mapKind=="message")return Kt(n,t=>ft(e,t))}return n}function ba(e,n){if(Array.isArray(n)){if(e.scalar==m.BYTES)return n.map(mt);if(e.listKind=="message")return n.map(t=>ft(e,t))}return n}function ft(e,n){if(e.fieldKind=="message"&&!e.oneof&&Ke(e.message))return Mo(e.message.fields[0],n);if(ce(n)){if(e.message.typeName=="google.protobuf.Struct"&&e.parent.typeName!=="google.protobuf.Value")return n;if(!at(n,e.message))return H(e.message,n)}return n}function mt(e){return Array.isArray(e)?new Uint8Array(e):e}function Kt(e,n){const t={};for(const r of Object.entries(e))t[r[0]]=n(r[1]);return t}const Ea=Symbol(),Lt=new WeakMap;function Aa(e){let n;if(Na(e)){const t=Lt.get(e);let r,o;if(t)({prototype:r,members:o}=t);else{r={},o=new Set;for(const s of e.members)s.kind!="oneof"&&(s.fieldKind!="scalar"&&s.fieldKind!="enum"||s.presence!=on&&(o.add(s),r[s.localName]=Bn(s)));Lt.set(e,{prototype:r,members:o})}n=Object.create(r),n.$typeName=e.typeName;for(const s of e.members)o.has(s)||s.kind=="field"&&(s.fieldKind=="message"||(s.fieldKind=="scalar"||s.fieldKind=="enum")&&s.presence!=on)||(n[s.localName]=Bn(s))}else{n={$typeName:e.typeName};for(const t of e.members)(t.kind=="oneof"||t.presence==on)&&(n[t.localName]=Bn(t))}return n}function Na(e){switch(e.file.edition){case ma:return!1;case ha:return!0;default:return e.fields.some(n=>n.presence!=on&&n.fieldKind!="message"&&!n.oneof)}}function Bn(e){if(e.kind=="oneof")return{case:void 0};if(e.fieldKind=="list")return[];if(e.fieldKind=="map")return{};if(e.fieldKind=="message")return Ea;const n=e.getDefaultValue();return n!==void 0?e.fieldKind=="scalar"&&e.longAsString?n.toString():n:e.fieldKind=="scalar"?_e(e.scalar,e.longAsString):e.enum.values[0].number}const ya=["FieldValueInvalidError","FieldListRangeError","ForeignFieldError"];class L extends Error{constructor(n,t,r="FieldValueInvalidError"){super(t),this.name=r,this.field=()=>n}}function Sa(e){return e instanceof Error&&ya.includes(e.name)&&"field"in e&&typeof e.field=="function"}const Fn=Symbol.for("@bufbuild/protobuf/text-encoding");function ht(){if(globalThis[Fn]==null){const e=new globalThis.TextEncoder,n=new globalThis.TextDecoder;globalThis[Fn]={encodeUtf8(t){return e.encode(t)},decodeUtf8(t){return n.decode(t)},checkUtf8(t){try{return encodeURIComponent(t),!0}catch{return!1}}}}return globalThis[Fn]}var G;(function(e){e[e.Varint=0]="Varint",e[e.Bit64=1]="Bit64",e[e.LengthDelimited=2]="LengthDelimited",e[e.StartGroup=3]="StartGroup",e[e.EndGroup=4]="EndGroup",e[e.Bit32=5]="Bit32"})(G||(G={}));const $o=34028234663852886e22,Po=-34028234663852886e22,jo=4294967295,Qo=2147483647,Ho=-2147483648;class qo{constructor(n=ht().encodeUtf8){this.encodeUtf8=n,this.stack=[],this.chunks=[],this.buf=[]}finish(){this.buf.length&&(this.chunks.push(new Uint8Array(this.buf)),this.buf=[]);let n=0;for(let o=0;o<this.chunks.length;o++)n+=this.chunks[o].length;let t=new Uint8Array(n),r=0;for(let o=0;o<this.chunks.length;o++)t.set(this.chunks[o],r),r+=this.chunks[o].length;return this.chunks=[],t}fork(){return this.stack.push({chunks:this.chunks,buf:this.buf}),this.chunks=[],this.buf=[],this}join(){let n=this.finish(),t=this.stack.pop();if(!t)throw new Error("invalid state, fork stack empty");return this.chunks=t.chunks,this.buf=t.buf,this.uint32(n.byteLength),this.raw(n)}tag(n,t){return this.uint32((n<<3|t)>>>0)}raw(n){return this.buf.length&&(this.chunks.push(new Uint8Array(this.buf)),this.buf=[]),this.chunks.push(n),this}uint32(n){for(Mt(n);n>127;)this.buf.push(n&127|128),n=n>>>7;return this.buf.push(n),this}int32(n){return Gn(n),Jn(n,this.buf),this}bool(n){return this.buf.push(n?1:0),this}bytes(n){return this.uint32(n.byteLength),this.raw(n)}string(n){let t=this.encodeUtf8(n);return this.uint32(t.byteLength),this.raw(t)}float(n){Ia(n);let t=new Uint8Array(4);return new DataView(t.buffer).setFloat32(0,n,!0),this.raw(t)}double(n){let t=new Uint8Array(8);return new DataView(t.buffer).setFloat64(0,n,!0),this.raw(t)}fixed32(n){Mt(n);let t=new Uint8Array(4);return new DataView(t.buffer).setUint32(0,n,!0),this.raw(t)}sfixed32(n){Gn(n);let t=new Uint8Array(4);return new DataView(t.buffer).setInt32(0,n,!0),this.raw(t)}sint32(n){return Gn(n),n=(n<<1^n>>31)>>>0,Jn(n,this.buf),this}sfixed64(n){let t=new Uint8Array(8),r=new DataView(t.buffer),o=w.enc(n);return r.setInt32(0,o.lo,!0),r.setInt32(4,o.hi,!0),this.raw(t)}fixed64(n){let t=new Uint8Array(8),r=new DataView(t.buffer),o=w.uEnc(n);return r.setInt32(0,o.lo,!0),r.setInt32(4,o.hi,!0),this.raw(t)}int64(n){let t=w.enc(n);return kn(t.lo,t.hi,this.buf),this}sint64(n){const t=w.enc(n),r=t.hi>>31,o=t.lo<<1^r,s=(t.hi<<1|t.lo>>>31)^r;return kn(o,s,this.buf),this}uint64(n){const t=w.uEnc(n);return kn(t.lo,t.hi,this.buf),this}}class gt{constructor(n,t=ht().decodeUtf8){this.decodeUtf8=t,this.varint64=oa,this.uint32=aa,this.buf=n,this.len=n.length,this.pos=0,this.view=new DataView(n.buffer,n.byteOffset,n.byteLength)}tag(){let n=this.uint32(),t=n>>>3,r=n&7;if(t<=0||r<0||r>5)throw new Error("illegal tag: field no "+t+" wire type "+r);return[t,r]}skip(n,t){let r=this.pos;switch(n){case G.Varint:for(;this.buf[this.pos++]&128;);break;case G.Bit64:this.pos+=4;case G.Bit32:this.pos+=4;break;case G.LengthDelimited:let o=this.uint32();this.pos+=o;break;case G.StartGroup:for(;;){const[s,i]=this.tag();if(i===G.EndGroup){if(t!==void 0&&s!==t)throw new Error("invalid end group tag");break}this.skip(i,s)}break;default:throw new Error("cant skip wire type "+n)}return this.assertBounds(),this.buf.subarray(r,this.pos)}assertBounds(){if(this.pos>this.len)throw new RangeError("premature EOF")}int32(){return this.uint32()|0}sint32(){let n=this.uint32();return n>>>1^-(n&1)}int64(){return w.dec(...this.varint64())}uint64(){return w.uDec(...this.varint64())}sint64(){let[n,t]=this.varint64(),r=-(n&1);return n=(n>>>1|(t&1)<<31)^r,t=t>>>1^r,w.dec(n,t)}bool(){let[n,t]=this.varint64();return n!==0||t!==0}fixed32(){return this.view.getUint32((this.pos+=4)-4,!0)}sfixed32(){return this.view.getInt32((this.pos+=4)-4,!0)}fixed64(){return w.uDec(this.sfixed32(),this.sfixed32())}sfixed64(){return w.dec(this.sfixed32(),this.sfixed32())}float(){return this.view.getFloat32((this.pos+=4)-4,!0)}double(){return this.view.getFloat64((this.pos+=8)-8,!0)}bytes(){let n=this.uint32(),t=this.pos;return this.pos+=n,this.assertBounds(),this.buf.subarray(t,t+n)}string(){return this.decodeUtf8(this.bytes())}}function Gn(e){if(typeof e=="string")e=Number(e);else if(typeof e!="number")throw new Error("invalid int32: "+typeof e);if(!Number.isInteger(e)||e>Qo||e<Ho)throw new Error("invalid int32: "+e)}function Mt(e){if(typeof e=="string")e=Number(e);else if(typeof e!="number")throw new Error("invalid uint32: "+typeof e);if(!Number.isInteger(e)||e>jo||e<0)throw new Error("invalid uint32: "+e)}function Ia(e){if(typeof e=="string"){const n=e;if(e=Number(e),Number.isNaN(e)&&n!=="NaN")throw new Error("invalid float32: "+n)}else if(typeof e!="number")throw new Error("invalid float32: "+typeof e);if(Number.isFinite(e)&&(e>$o||e<Po))throw new Error("invalid float32: "+e)}function he(e,n){const t=e.fieldKind=="list"?ut(n,e):e.fieldKind=="map"?lt(n,e):pt(e,n);if(t===!0)return;let r;switch(e.fieldKind){case"list":r=`expected ${ts(e)}, got ${X(n)}`;break;case"map":r=`expected ${rs(e)}, got ${X(n)}`;break;default:r=sn(e,n,t)}return new L(e,r)}function $t(e,n,t){const r=pt(e,t);if(r!==!0)return new L(e,`list item #${n+1}: ${sn(e,t,r)}`)}function _a(e,n,t){const r=es(n,e.mapKey);if(r!==!0)return new L(e,`invalid map key: ${sn({scalar:e.mapKey},n,r)}`);const o=pt(e,t);if(o!==!0)return new L(e,`map entry ${X(n)}: ${sn(e,t,o)}`)}function pt(e,n){return e.scalar!==void 0?es(n,e.scalar):e.enum!==void 0?e.enum.open?Number.isInteger(n):e.enum.values.some(t=>t.number===n):dt(n,e.message)}function es(e,n){switch(n){case m.DOUBLE:return typeof e=="number";case m.FLOAT:return typeof e!="number"?!1:Number.isNaN(e)||!Number.isFinite(e)?!0:e>$o||e<Po?`${e.toFixed()} out of range`:!0;case m.INT32:case m.SFIXED32:case m.SINT32:return typeof e!="number"||!Number.isInteger(e)?!1:e>Qo||e<Ho?`${e.toFixed()} out of range`:!0;case m.FIXED32:case m.UINT32:return typeof e!="number"||!Number.isInteger(e)?!1:e>jo||e<0?`${e.toFixed()} out of range`:!0;case m.BOOL:return typeof e=="boolean";case m.STRING:return typeof e!="string"?!1:ht().checkUtf8(e)||"invalid UTF8";case m.BYTES:return e instanceof Uint8Array;case m.INT64:case m.SFIXED64:case m.SINT64:if(typeof e=="bigint"||typeof e=="number"||typeof e=="string"&&e.length>0)try{return w.parse(e),!0}catch{return`${e} out of range`}return!1;case m.FIXED64:case m.UINT64:if(typeof e=="bigint"||typeof e=="number"||typeof e=="string"&&e.length>0)try{return w.uParse(e),!0}catch{return`${e} out of range`}return!1}}function sn(e,n,t){return t=typeof t=="string"?`: ${t}`:`, got ${X(n)}`,e.scalar!==void 0?`expected ${Za(e.scalar)}`+t:e.enum!==void 0?`expected ${e.enum.toString()}`+t:`expected ${ns(e.message)}`+t}function X(e){switch(typeof e){case"object":return e===null?"null":e instanceof Uint8Array?`Uint8Array(${e.length})`:Array.isArray(e)?`Array(${e.length})`:ut(e)?ts(e.field()):lt(e)?rs(e.field()):dt(e)?ns(e.desc):at(e)?`message ${e.$typeName}`:"object";case"string":return e.length>30?"string":`"${e.split('"').join('\\"')}"`;case"boolean":return String(e);case"number":return String(e);case"bigint":return String(e)+"n";default:return typeof e}}function ns(e){return`ReflectMessage (${e.typeName})`}function ts(e){switch(e.listKind){case"message":return`ReflectList (${e.message.toString()})`;case"enum":return`ReflectList (${e.enum.toString()})`;case"scalar":return`ReflectList (${m[e.scalar]})`}}function rs(e){switch(e.mapKind){case"message":return`ReflectMap (${m[e.mapKey]}, ${e.message.toString()})`;case"enum":return`ReflectMap (${m[e.mapKey]}, ${e.enum.toString()})`;case"scalar":return`ReflectMap (${m[e.mapKey]}, ${m[e.scalar]})`}}function Za(e){switch(e){case m.STRING:return"string";case m.BOOL:return"boolean";case m.INT64:case m.SINT64:case m.SFIXED64:return"bigint (int64)";case m.UINT64:case m.FIXED64:return"bigint (uint64)";case m.BYTES:return"Uint8Array";case m.DOUBLE:return"number (float64)";case m.FLOAT:return"number (float32)";case m.FIXED32:case m.UINT32:return"number (uint32)";case m.INT32:case m.SFIXED32:case m.SINT32:return"number (int32)"}}function q(e,n,t=!0){return new os(e,n,t)}const Pt=new WeakMap;class os{get sortedFields(){const n=Pt.get(this.desc);if(n)return n;const t=this.desc.fields.concat().sort((r,o)=>r.number-o.number);return Pt.set(this.desc,t),t}constructor(n,t,r=!0){this.lists=new Map,this.maps=new Map,this.check=r,this.desc=n,this.message=this[oe]=t??H(n),this.fields=n.fields,this.oneofs=n.oneofs,this.members=n.members}findNumber(n){return this._fieldsByNumber||(this._fieldsByNumber=new Map(this.desc.fields.map(t=>[t.number,t]))),this._fieldsByNumber.get(n)}oneofCase(n){return Fe(this.message,n),Do(this.message,n)}isSet(n){return Fe(this.message,n),la(this.message,n)}clear(n){Fe(this.message,n),da(this.message,n)}get(n){Fe(this.message,n);const t=xo(this.message,n);switch(n.fieldKind){case"list":let r=this.lists.get(n);return(!r||r[oe]!==t)&&this.lists.set(n,r=new Ra(n,t,this.check)),r;case"map":let o=this.maps.get(n);return(!o||o[oe]!==t)&&this.maps.set(n,o=new va(n,t,this.check)),o;case"message":return Et(n,t,this.check);case"scalar":return t===void 0?_e(n.scalar,!1):At(n,t);case"enum":return t??n.enum.values[0].number}}set(n,t){if(Fe(this.message,n),this.check){const o=he(n,t);if(o)throw o}let r;n.fieldKind=="message"?r=bt(n,t):lt(t)||ut(t)?r=t[oe]:r=Nt(n,t),Ko(this.message,n,r)}getUnknown(){return this.message.$unknown}setUnknown(n){this.message.$unknown=n}}function Fe(e,n){if(n.parent.typeName!==e.$typeName)throw new L(n,`cannot use ${n.toString()} with message ${e.$typeName}`,"ForeignFieldError")}class Ra{field(){return this._field}get size(){return this._arr.length}constructor(n,t,r){this._field=n,this._arr=this[oe]=t,this.check=r}get(n){const t=this._arr[n];return t===void 0?void 0:Tn(this._field,t,this.check)}set(n,t){if(n<0||n>=this._arr.length)throw new L(this._field,`list item #${n+1}: out of range`);if(this.check){const r=$t(this._field,n,t);if(r)throw r}this._arr[n]=jt(this._field,t)}add(n){if(this.check){const t=$t(this._field,this._arr.length,n);if(t)throw t}this._arr.push(jt(this._field,n))}clear(){this._arr.splice(0,this._arr.length)}[Symbol.iterator](){return this.values()}keys(){return this._arr.keys()}*values(){for(const n of this._arr)yield Tn(this._field,n,this.check)}*entries(){for(let n=0;n<this._arr.length;n++)yield[n,Tn(this._field,this._arr[n],this.check)]}}class va{constructor(n,t,r=!0){this.obj=this[oe]=t??{},this.check=r,this._field=n}field(){return this._field}set(n,t){if(this.check){const r=_a(this._field,n,t);if(r)throw r}return this.obj[je(n)]=Va(this._field,t),this}delete(n){const t=je(n),r=Object.prototype.hasOwnProperty.call(this.obj,t);return r&&delete this.obj[t],r}clear(){for(const n of Object.keys(this.obj))delete this.obj[n]}get(n){let t=this.obj[je(n)];return t!==void 0&&(t=Un(this._field,t,this.check)),t}has(n){return Object.prototype.hasOwnProperty.call(this.obj,je(n))}*keys(){for(const n of Object.keys(this.obj))yield Qt(n,this._field.mapKey)}*entries(){for(const n of Object.entries(this.obj))yield[Qt(n[0],this._field.mapKey),Un(this._field,n[1],this.check)]}[Symbol.iterator](){return this.entries()}get size(){return Object.keys(this.obj).length}*values(){for(const n of Object.values(this.obj))yield Un(this._field,n,this.check)}forEach(n,t){for(const r of this.entries())n.call(t,r[1],r[0],this)}}function bt(e,n){return dt(n)?fa(n.message)&&!e.oneof&&e.fieldKind=="message"?n.message.value:n.desc.typeName=="google.protobuf.Struct"&&e.parent.typeName!="google.protobuf.Value"?is(n.message):n.message:n}function Et(e,n,t){return n!==void 0&&(Ke(e.message)&&!e.oneof&&e.fieldKind=="message"?n={$typeName:e.message.typeName,value:At(e.message.fields[0],n)}:e.message.typeName=="google.protobuf.Struct"&&e.parent.typeName!="google.protobuf.Value"&&ce(n)&&(n=ss(n))),new os(e.message,n,t)}function jt(e,n){return e.listKind=="message"?bt(e,n):Nt(e,n)}function Tn(e,n,t){return e.listKind=="message"?Et(e,n,t):At(e,n)}function Va(e,n){return e.mapKind=="message"?bt(e,n):Nt(e,n)}function Un(e,n,t){return e.mapKind=="message"?Et(e,n,t):n}function je(e){return typeof e=="string"||typeof e=="number"?e:String(e)}function Qt(e,n){switch(n){case m.STRING:return e;case m.INT32:case m.FIXED32:case m.UINT32:case m.SFIXED32:case m.SINT32:{const t=Number.parseInt(e);if(Number.isFinite(t))return t;break}case m.BOOL:switch(e){case"true":return!0;case"false":return!1}break;case m.UINT64:case m.FIXED64:try{return w.uParse(e)}catch{}break;default:try{return w.parse(e)}catch{}break}return e}function At(e,n){switch(e.scalar){case m.INT64:case m.SFIXED64:case m.SINT64:"longAsString"in e&&e.longAsString&&typeof n=="string"&&(n=w.parse(n));break;case m.FIXED64:case m.UINT64:"longAsString"in e&&e.longAsString&&typeof n=="string"&&(n=w.uParse(n));break}return n}function Nt(e,n){switch(e.scalar){case m.INT64:case m.SFIXED64:case m.SINT64:"longAsString"in e&&e.longAsString?n=String(n):(typeof n=="string"||typeof n=="number")&&(n=w.parse(n));break;case m.FIXED64:case m.UINT64:"longAsString"in e&&e.longAsString?n=String(n):(typeof n=="string"||typeof n=="number")&&(n=w.uParse(n));break}return n}function ss(e){const n={$typeName:"google.protobuf.Struct",fields:{}};if(ce(e))for(const[t,r]of Object.entries(e))n.fields[t]=cs(r);return n}function is(e){const n={};for(const[t,r]of Object.entries(e.fields))n[t]=as(r);return n}function as(e){switch(e.kind.case){case"structValue":return is(e.kind.value);case"listValue":return e.kind.value.values.map(as);case"nullValue":case void 0:return null;default:return e.kind.value}}function cs(e){const n={$typeName:"google.protobuf.Value",kind:{case:void 0}};switch(typeof e){case"number":n.kind={case:"numberValue",value:e};break;case"string":n.kind={case:"stringValue",value:e};break;case"boolean":n.kind={case:"boolValue",value:e};break;case"object":if(e===null)n.kind={case:"nullValue",value:0};else if(Array.isArray(e)){const t={$typeName:"google.protobuf.ListValue",values:[]};if(Array.isArray(e))for(const r of e)t.values.push(cs(r));n.kind={case:"listValue",value:t}}else n.kind={case:"structValue",value:ss(e)};break}return n}function yt(e){const n=Ca();let t=e.length*3/4;e[e.length-2]=="="?t-=2:e[e.length-1]=="="&&(t-=1);let r=new Uint8Array(t),o=0,s=0,i,a=0;for(let c=0;c<e.length;c++){if(i=n[e.charCodeAt(c)],i===void 0)switch(e[c]){case"=":s=0;case`
2
+ `:case"\r":case" ":case" ":continue;default:throw Error("invalid base64 string")}switch(s){case 0:a=i,s=1;break;case 1:r[o++]=a<<2|(i&48)>>4,a=i,s=2;break;case 2:r[o++]=(a&15)<<4|(i&60)>>2,a=i,s=3;break;case 3:r[o++]=(a&3)<<6|i,s=0;break}}if(s==1)throw Error("invalid base64 string");return r.subarray(0,o)}function us(e,n="std"){const t=ls(n),r=n=="std";let o="",s=0,i,a=0;for(let c=0;c<e.length;c++)switch(i=e[c],s){case 0:o+=t[i>>2],a=(i&3)<<4,s=1;break;case 1:o+=t[a|i>>4],a=(i&15)<<2,s=2;break;case 2:o+=t[a|i>>6],o+=t[i&63],s=0;break}return s&&(o+=t[a],r&&(o+="=",s==1&&(o+="="))),o}let Qe,Ht,Ne;function ls(e){return Qe||(Qe="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split(""),Ht=Qe.slice(0,-2).concat("-","_")),e=="url"?Ht:Qe}function Ca(){if(!Ne){Ne=[];const e=ls("std");for(let n=0;n<e.length;n++)Ne[e[n].charCodeAt(0)]=n;Ne[45]=e.indexOf("+"),Ne[95]=e.indexOf("/")}return Ne}function Ze(e){let n=!1;const t=[];for(let r=0;r<e.length;r++){let o=e.charAt(r);switch(o){case"_":n=!0;break;case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":t.push(o),n=!1;break;default:n&&(n=!1,o=o.toUpperCase()),t.push(o);break}}return t.join("")}function ds(e){return e.replace(/[A-Z]/g,n=>"_"+n.toLowerCase())}const wa=new Set(["constructor","toString","toJSON","valueOf"]);function Ye(e){return wa.has(e)?e+"$":e}function St(e){for(const n of e.field)Ue(n,"jsonName")||(n.jsonName=Ze(n.name));e.nestedType.forEach(St)}function ka(e,n){const t=e.values.find(r=>r.name===n);if(!t)throw new Error(`cannot parse ${e} default value: ${n}`);return t.number}function Ba(e,n){switch(e){case m.STRING:return n;case m.BYTES:{const t=Fa(n);if(t===!1)throw new Error(`cannot parse ${m[e]} default value: ${n}`);return t}case m.INT64:case m.SFIXED64:case m.SINT64:return w.parse(n);case m.UINT64:case m.FIXED64:return w.uParse(n);case m.DOUBLE:case m.FLOAT:switch(n){case"inf":return Number.POSITIVE_INFINITY;case"-inf":return Number.NEGATIVE_INFINITY;case"nan":return Number.NaN;default:return parseFloat(n)}case m.BOOL:return n==="true";case m.INT32:case m.UINT32:case m.SINT32:case m.FIXED32:case m.SFIXED32:return parseInt(n,10)}}function Fa(e){const n=[],t={tail:e,c:"",next(){return this.tail.length==0?!1:(this.c=this.tail[0],this.tail=this.tail.substring(1),!0)},take(r){if(this.tail.length>=r){const o=this.tail.substring(0,r);return this.tail=this.tail.substring(r),o}return!1}};for(;t.next();)switch(t.c){case"\\":if(t.next())switch(t.c){case"\\":n.push(t.c.charCodeAt(0));break;case"b":n.push(8);break;case"f":n.push(12);break;case"n":n.push(10);break;case"r":n.push(13);break;case"t":n.push(9);break;case"v":n.push(11);break;case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":{const r=t.c,o=t.take(2);if(o===!1)return!1;const s=parseInt(r+o,8);if(Number.isNaN(s))return!1;n.push(s);break}case"x":{const r=t.c,o=t.take(2);if(o===!1)return!1;const s=parseInt(r+o,16);if(Number.isNaN(s))return!1;n.push(s);break}case"u":{const r=t.c,o=t.take(4);if(o===!1)return!1;const s=parseInt(r+o,16);if(Number.isNaN(s))return!1;const i=new Uint8Array(4);new DataView(i.buffer).setInt32(0,s,!0),n.push(i[0],i[1],i[2],i[3]);break}case"U":{const r=t.c,o=t.take(8);if(o===!1)return!1;const s=w.uEnc(r+o),i=new Uint8Array(8),a=new DataView(i.buffer);a.setInt32(0,s.lo,!0),a.setInt32(4,s.hi,!0),n.push(i[0],i[1],i[2],i[3],i[4],i[5],i[6],i[7]);break}}break;default:n.push(t.c.charCodeAt(0))}return new Uint8Array(n)}function*Dn(e){switch(e.kind){case"file":for(const n of e.messages)yield n,yield*Dn(n);yield*e.enums,yield*e.services,yield*e.extensions;break;case"message":for(const n of e.nestedMessages)yield n,yield*Dn(n);yield*e.nestedEnums,yield*e.nestedExtensions;break}}function fs(...e){const n=Ga();if(!e.length)return n;if("$typeName"in e[0]&&e[0].$typeName=="google.protobuf.FileDescriptorSet"){for(const t of e[0].file)tr(t,n);return n}if("$typeName"in e[0]){let s=function(i){const a=[];for(const c of i.dependency){if(n.getFile(c)!=null||o.has(c))continue;const u=r(c);if(!u)throw new Error(`Unable to resolve ${c}, imported by ${i.name}`);"kind"in u?n.addFile(u,!1,!0):(o.add(u.name),a.push(u))}return a.concat(...a.map(s))};const t=e[0],r=e[1],o=new Set;for(const i of[t,...s(t)].reverse())tr(i,n)}else for(const t of e)for(const r of t.files)n.addFile(r);return n}function Ga(){const e=new Map,n=new Map,t=new Map;return{kind:"registry",types:e,extendees:n,[Symbol.iterator](){return e.values()},get files(){return t.values()},addFile(r,o,s){if(t.set(r.proto.name,r),!o)for(const i of Dn(r))this.add(i);if(s)for(const i of r.dependencies)this.addFile(i,o,s)},add(r){if(r.kind=="extension"){let o=n.get(r.extendee.typeName);o||n.set(r.extendee.typeName,o=new Map),o.set(r.number,r)}e.set(r.typeName,r)},get(r){return e.get(r)},getFile(r){return t.get(r)},getMessage(r){const o=e.get(r);return(o==null?void 0:o.kind)=="message"?o:void 0},getEnum(r){const o=e.get(r);return(o==null?void 0:o.kind)=="enum"?o:void 0},getExtension(r){const o=e.get(r);return(o==null?void 0:o.kind)=="extension"?o:void 0},getExtensionFor(r,o){var s;return(s=n.get(r.typeName))===null||s===void 0?void 0:s.get(o)},getService(r){const o=e.get(r);return(o==null?void 0:o.kind)=="service"?o:void 0}}}const Ta=998,Ua=999,Ya=9,We=10,Te=11,Wa=12,qt=14,It=3,Oa=2,er=1,Xa=0,Yn=1,nr=2,za=3,Ja=1,Da=2,xa=1,ms={998:{fieldPresence:1,enumType:2,repeatedFieldEncoding:2,utf8Validation:3,messageEncoding:1,jsonFormat:2,enforceNamingStyle:2,defaultSymbolVisibility:1},999:{fieldPresence:2,enumType:1,repeatedFieldEncoding:1,utf8Validation:2,messageEncoding:1,jsonFormat:1,enforceNamingStyle:2,defaultSymbolVisibility:1},1e3:{fieldPresence:1,enumType:1,repeatedFieldEncoding:1,utf8Validation:2,messageEncoding:1,jsonFormat:1,enforceNamingStyle:2,defaultSymbolVisibility:1},1001:{fieldPresence:1,enumType:1,repeatedFieldEncoding:1,utf8Validation:2,messageEncoding:1,jsonFormat:1,enforceNamingStyle:1,defaultSymbolVisibility:2}};function tr(e,n){var t,r;const o={kind:"file",proto:e,deprecated:(r=(t=e.options)===null||t===void 0?void 0:t.deprecated)!==null&&r!==void 0?r:!1,edition:$a(e),name:e.name.replace(/\.proto$/,""),dependencies:Pa(e,n),enums:[],messages:[],extensions:[],services:[],toString(){return`file ${e.name}`}},s=new Map,i={get(a){return s.get(a)},add(a){var c;Q(((c=a.proto.options)===null||c===void 0?void 0:c.mapEntry)===!0),s.set(a.typeName,a)}};for(const a of e.enumType)hs(a,o,void 0,n);for(const a of e.messageType)gs(a,o,void 0,n,i);for(const a of e.service)Ka(a,o,n);xn(o,n);for(const a of s.values())Kn(a,n,i);for(const a of o.messages)Kn(a,n,i),xn(a,n);n.addFile(o,!0)}function xn(e,n){switch(e.kind){case"file":for(const t of e.proto.extension){const r=Ln(t,e,n);e.extensions.push(r),n.add(r)}break;case"message":for(const t of e.proto.extension){const r=Ln(t,e,n);e.nestedExtensions.push(r),n.add(r)}for(const t of e.nestedMessages)xn(t,n);break}}function Kn(e,n,t){const r=e.proto.oneofDecl.map(s=>Ma(s,e)),o=new Set;for(const s of e.proto.field){const i=Ha(s,r),a=Ln(s,e,n,i,t);e.fields.push(a),e.field[a.localName]=a,i===void 0?e.members.push(a):(i.fields.push(a),o.has(i)||(o.add(i),e.members.push(i)))}for(const s of r.filter(i=>o.has(i)))e.oneofs.push(s);for(const s of e.nestedMessages)Kn(s,n,t)}function hs(e,n,t,r){var o,s,i,a,c;const u=ja(e.name,e.value),l={kind:"enum",proto:e,deprecated:(s=(o=e.options)===null||o===void 0?void 0:o.deprecated)!==null&&s!==void 0?s:!1,file:n,parent:t,open:!0,name:e.name,typeName:An(e,t,n),value:{},values:[],sharedPrefix:u,toString(){return`enum ${this.typeName}`}};l.open=tc(l),r.add(l);for(const d of e.value){const g=d.name;l.values.push(l.value[d.number]={kind:"enum_value",proto:d,deprecated:(a=(i=d.options)===null||i===void 0?void 0:i.deprecated)!==null&&a!==void 0?a:!1,parent:l,name:g,localName:Ye(u==null?g:g.substring(u.length)),number:d.number,toString(){return`enum value ${l.typeName}.${g}`}})}((c=t==null?void 0:t.nestedEnums)!==null&&c!==void 0?c:n.enums).push(l)}function gs(e,n,t,r,o){var s,i,a,c;const u={kind:"message",proto:e,deprecated:(i=(s=e.options)===null||s===void 0?void 0:s.deprecated)!==null&&i!==void 0?i:!1,file:n,parent:t,name:e.name,typeName:An(e,t,n),fields:[],field:{},oneofs:[],members:[],nestedEnums:[],nestedMessages:[],nestedExtensions:[],toString(){return`message ${this.typeName}`}};((a=e.options)===null||a===void 0?void 0:a.mapEntry)===!0?o.add(u):(((c=t==null?void 0:t.nestedMessages)!==null&&c!==void 0?c:n.messages).push(u),r.add(u));for(const l of e.enumType)hs(l,n,u,r);for(const l of e.nestedType)gs(l,n,u,r,o)}function Ka(e,n,t){var r,o;const s={kind:"service",proto:e,deprecated:(o=(r=e.options)===null||r===void 0?void 0:r.deprecated)!==null&&o!==void 0?o:!1,file:n,name:e.name,typeName:An(e,void 0,n),methods:[],method:{},toString(){return`service ${this.typeName}`}};n.services.push(s),t.add(s);for(const i of e.method){const a=La(i,s,t);s.methods.push(a),s.method[a.localName]=a}}function La(e,n,t){var r,o,s,i;let a;e.clientStreaming&&e.serverStreaming?a="bidi_streaming":e.clientStreaming?a="client_streaming":e.serverStreaming?a="server_streaming":a="unary";const c=t.getMessage(re(e.inputType)),u=t.getMessage(re(e.outputType));Q(c,`invalid MethodDescriptorProto: input_type ${e.inputType} not found`),Q(u,`invalid MethodDescriptorProto: output_type ${e.inputType} not found`);const l=e.name;return{kind:"rpc",proto:e,deprecated:(o=(r=e.options)===null||r===void 0?void 0:r.deprecated)!==null&&o!==void 0?o:!1,parent:n,name:l,localName:Ye(l.length?Ye(l[0].toLowerCase()+l.substring(1)):l),methodKind:a,input:c,output:u,idempotency:(i=(s=e.options)===null||s===void 0?void 0:s.idempotencyLevel)!==null&&i!==void 0?i:Xa,toString(){return`rpc ${n.typeName}.${l}`}}}function Ma(e,n){return{kind:"oneof",proto:e,deprecated:!1,parent:n,fields:[],name:e.name,localName:Ye(Ze(e.name)),toString(){return`oneof ${n.typeName}.${this.name}`}}}function Ln(e,n,t,r,o){var s,i,a;const c=o===void 0,u={kind:"field",proto:e,deprecated:(i=(s=e.options)===null||s===void 0?void 0:s.deprecated)!==null&&i!==void 0?i:!1,name:e.name,number:e.number,scalar:void 0,message:void 0,enum:void 0,presence:qa(e,r,c,n),listKind:void 0,mapKind:void 0,mapKey:void 0,delimitedEncoding:void 0,packed:void 0,longAsString:!1,getDefaultValue:void 0};if(c){const f=n.kind=="file"?n:n.file,p=n.kind=="file"?void 0:n,b=An(e,p,f);u.kind="extension",u.file=f,u.parent=p,u.oneof=void 0,u.typeName=b,u.jsonName=`[${b}]`,u.toString=()=>`extension ${b}`;const E=t.getMessage(re(e.extendee));Q(E,`invalid FieldDescriptorProto: extendee ${e.extendee} not found`),u.extendee=E}else{const f=n;Q(f.kind=="message"),u.parent=f,u.oneof=r,u.localName=r?Ze(e.name):Ye(Ze(e.name)),u.jsonName=e.jsonName,u.toString=()=>`field ${f.typeName}.${e.name}`}const l=e.label,d=e.type,g=(a=e.options)===null||a===void 0?void 0:a.jstype;if(l===It){const f=d==Te?o==null?void 0:o.get(re(e.typeName)):void 0;if(f){u.fieldKind="map";const{key:p,value:b}=nc(f);return u.mapKey=p.scalar,u.mapKind=b.fieldKind,u.message=b.message,u.delimitedEncoding=!1,u.enum=b.enum,u.scalar=b.scalar,u}switch(u.fieldKind="list",d){case Te:case We:u.listKind="message",u.message=t.getMessage(re(e.typeName)),Q(u.message),u.delimitedEncoding=rr(e,n);break;case qt:u.listKind="enum",u.enum=t.getEnum(re(e.typeName)),Q(u.enum);break;default:u.listKind="scalar",u.scalar=d,u.longAsString=g==er;break}return u.packed=ec(e,n),u}switch(d){case Te:case We:u.fieldKind="message",u.message=t.getMessage(re(e.typeName)),Q(u.message,`invalid FieldDescriptorProto: type_name ${e.typeName} not found`),u.delimitedEncoding=rr(e,n),u.getDefaultValue=()=>{};break;case qt:{const f=t.getEnum(re(e.typeName));Q(f!==void 0,`invalid FieldDescriptorProto: type_name ${e.typeName} not found`),u.fieldKind="enum",u.enum=t.getEnum(re(e.typeName)),u.getDefaultValue=()=>Ue(e,"defaultValue")?ka(f,e.defaultValue):void 0;break}default:{u.fieldKind="scalar",u.scalar=d,u.longAsString=g==er,u.getDefaultValue=()=>Ue(e,"defaultValue")?Ba(d,e.defaultValue):void 0;break}}return u}function $a(e){switch(e.syntax){case"":case"proto2":return Ta;case"proto3":return Ua;case"editions":if(e.edition in ms)return e.edition;throw new Error(`${e.name}: unsupported edition`);default:throw new Error(`${e.name}: unsupported syntax "${e.syntax}"`)}}function Pa(e,n){return e.dependency.map(t=>{const r=n.getFile(t);if(!r)throw new Error(`Cannot find ${t}, imported by ${e.name}`);return r})}function ja(e,n){const t=Qa(e)+"_";for(const r of n){if(!r.name.toLowerCase().startsWith(t))return;const o=r.name.substring(t.length);if(o.length==0||/^\d/.test(o))return}return t}function Qa(e){return(e.substring(0,1)+e.substring(1).replace(/[A-Z]/g,n=>"_"+n)).toLowerCase()}function An(e,n,t){let r;return n?r=`${n.typeName}.${e.name}`:t.proto.package.length>0?r=`${t.proto.package}.${e.name}`:r=`${e.name}`,r}function re(e){return e.startsWith(".")?e.substring(1):e}function Ha(e,n){if(!Ue(e,"oneofIndex")||e.proto3Optional)return;const t=n[e.oneofIndex];return Q(t,`invalid FieldDescriptorProto: oneof #${e.oneofIndex} for field #${e.number} not found`),t}function qa(e,n,t,r){if(e.label==Oa)return za;if(e.label==It)return nr;if(n||e.proto3Optional||t)return Yn;const o=Re("fieldPresence",{proto:e,parent:r});return o==nr&&(e.type==Te||e.type==We)?Yn:o}function ec(e,n){if(e.label!=It)return!1;switch(e.type){case Ya:case Wa:case We:case Te:return!1}const t=e.options;return t&&Ue(t,"packed")?t.packed:Ja==Re("repeatedFieldEncoding",{proto:e,parent:n})}function nc(e){const n=e.fields.find(r=>r.number===1),t=e.fields.find(r=>r.number===2);return Q(n&&n.fieldKind=="scalar"&&n.scalar!=m.BYTES&&n.scalar!=m.FLOAT&&n.scalar!=m.DOUBLE&&t&&t.fieldKind!="list"&&t.fieldKind!="map"),{key:n,value:t}}function tc(e){var n;return xa==Re("enumType",{proto:e.proto,parent:(n=e.parent)!==null&&n!==void 0?n:e.file})}function rr(e,n){return e.type==We?!0:Da==Re("messageEncoding",{proto:e,parent:n})}function Re(e,n){var t,r;const o=(t=n.proto.options)===null||t===void 0?void 0:t.features;if(o){const s=o[e];if(s!=0)return s}if("kind"in n){if(n.kind=="message")return Re(e,(r=n.parent)!==null&&r!==void 0?r:n.file);const s=ms[n.edition];if(!s)throw new Error(`feature default for edition ${n.edition} not found`);return s[e]}return Re(e,n.parent)}function Q(e,n){if(!e)throw new Error(n)}function rc(e){const n=oc(e);return n.messageType.forEach(St),fs(n,()=>{}).getFile(n.name)}function oc(e){return Object.assign(Object.create({syntax:"",edition:0}),Object.assign(Object.assign({$typeName:"google.protobuf.FileDescriptorProto",dependency:[],publicDependency:[],weakDependency:[],optionDependency:[],service:[],extension:[]},e),{messageType:e.messageType.map(ps),enumType:e.enumType.map(bs)}))}function ps(e){var n,t,r,o,s,i,a,c;return Object.assign(Object.create({visibility:0}),{$typeName:"google.protobuf.DescriptorProto",name:e.name,field:(t=(n=e.field)===null||n===void 0?void 0:n.map(sc))!==null&&t!==void 0?t:[],extension:[],nestedType:(o=(r=e.nestedType)===null||r===void 0?void 0:r.map(ps))!==null&&o!==void 0?o:[],enumType:(i=(s=e.enumType)===null||s===void 0?void 0:s.map(bs))!==null&&i!==void 0?i:[],extensionRange:(c=(a=e.extensionRange)===null||a===void 0?void 0:a.map(l=>Object.assign({$typeName:"google.protobuf.DescriptorProto.ExtensionRange"},l)))!==null&&c!==void 0?c:[],oneofDecl:[],reservedRange:[],reservedName:[]})}function sc(e){return Object.assign(Object.create({label:1,typeName:"",extendee:"",defaultValue:"",oneofIndex:0,jsonName:"",proto3Optional:!1}),Object.assign(Object.assign({$typeName:"google.protobuf.FieldDescriptorProto"},e),{options:e.options?ic(e.options):void 0}))}function ic(e){var n,t,r;return Object.assign(Object.create({ctype:0,packed:!1,jstype:0,lazy:!1,unverifiedLazy:!1,deprecated:!1,weak:!1,debugRedact:!1,retention:0}),Object.assign(Object.assign({$typeName:"google.protobuf.FieldOptions"},e),{targets:(n=e.targets)!==null&&n!==void 0?n:[],editionDefaults:(r=(t=e.editionDefaults)===null||t===void 0?void 0:t.map(s=>Object.assign({$typeName:"google.protobuf.FieldOptions.EditionDefault"},s)))!==null&&r!==void 0?r:[],uninterpretedOption:[]}))}function bs(e){return Object.assign(Object.create({visibility:0}),{$typeName:"google.protobuf.EnumDescriptorProto",name:e.name,reservedName:[],reservedRange:[],value:e.value.map(t=>Object.assign({$typeName:"google.protobuf.EnumValueDescriptorProto"},t))})}function Le(e,n,...t){return t.reduce((r,o)=>r.nestedMessages[o],e.messages[n])}const ac=rc({name:"google/protobuf/descriptor.proto",package:"google.protobuf",messageType:[{name:"FileDescriptorSet",field:[{name:"file",number:1,type:11,label:3,typeName:".google.protobuf.FileDescriptorProto"}],extensionRange:[{start:536e6,end:536000001}]},{name:"FileDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"package",number:2,type:9,label:1},{name:"dependency",number:3,type:9,label:3},{name:"public_dependency",number:10,type:5,label:3},{name:"weak_dependency",number:11,type:5,label:3},{name:"option_dependency",number:15,type:9,label:3},{name:"message_type",number:4,type:11,label:3,typeName:".google.protobuf.DescriptorProto"},{name:"enum_type",number:5,type:11,label:3,typeName:".google.protobuf.EnumDescriptorProto"},{name:"service",number:6,type:11,label:3,typeName:".google.protobuf.ServiceDescriptorProto"},{name:"extension",number:7,type:11,label:3,typeName:".google.protobuf.FieldDescriptorProto"},{name:"options",number:8,type:11,label:1,typeName:".google.protobuf.FileOptions"},{name:"source_code_info",number:9,type:11,label:1,typeName:".google.protobuf.SourceCodeInfo"},{name:"syntax",number:12,type:9,label:1},{name:"edition",number:14,type:14,label:1,typeName:".google.protobuf.Edition"}]},{name:"DescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"field",number:2,type:11,label:3,typeName:".google.protobuf.FieldDescriptorProto"},{name:"extension",number:6,type:11,label:3,typeName:".google.protobuf.FieldDescriptorProto"},{name:"nested_type",number:3,type:11,label:3,typeName:".google.protobuf.DescriptorProto"},{name:"enum_type",number:4,type:11,label:3,typeName:".google.protobuf.EnumDescriptorProto"},{name:"extension_range",number:5,type:11,label:3,typeName:".google.protobuf.DescriptorProto.ExtensionRange"},{name:"oneof_decl",number:8,type:11,label:3,typeName:".google.protobuf.OneofDescriptorProto"},{name:"options",number:7,type:11,label:1,typeName:".google.protobuf.MessageOptions"},{name:"reserved_range",number:9,type:11,label:3,typeName:".google.protobuf.DescriptorProto.ReservedRange"},{name:"reserved_name",number:10,type:9,label:3},{name:"visibility",number:11,type:14,label:1,typeName:".google.protobuf.SymbolVisibility"}],nestedType:[{name:"ExtensionRange",field:[{name:"start",number:1,type:5,label:1},{name:"end",number:2,type:5,label:1},{name:"options",number:3,type:11,label:1,typeName:".google.protobuf.ExtensionRangeOptions"}]},{name:"ReservedRange",field:[{name:"start",number:1,type:5,label:1},{name:"end",number:2,type:5,label:1}]}]},{name:"ExtensionRangeOptions",field:[{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"},{name:"declaration",number:2,type:11,label:3,typeName:".google.protobuf.ExtensionRangeOptions.Declaration",options:{retention:2}},{name:"features",number:50,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"verification",number:3,type:14,label:1,typeName:".google.protobuf.ExtensionRangeOptions.VerificationState",defaultValue:"UNVERIFIED",options:{retention:2}}],nestedType:[{name:"Declaration",field:[{name:"number",number:1,type:5,label:1},{name:"full_name",number:2,type:9,label:1},{name:"type",number:3,type:9,label:1},{name:"reserved",number:5,type:8,label:1},{name:"repeated",number:6,type:8,label:1}]}],enumType:[{name:"VerificationState",value:[{name:"DECLARATION",number:0},{name:"UNVERIFIED",number:1}]}],extensionRange:[{start:1e3,end:536870912}]},{name:"FieldDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"number",number:3,type:5,label:1},{name:"label",number:4,type:14,label:1,typeName:".google.protobuf.FieldDescriptorProto.Label"},{name:"type",number:5,type:14,label:1,typeName:".google.protobuf.FieldDescriptorProto.Type"},{name:"type_name",number:6,type:9,label:1},{name:"extendee",number:2,type:9,label:1},{name:"default_value",number:7,type:9,label:1},{name:"oneof_index",number:9,type:5,label:1},{name:"json_name",number:10,type:9,label:1},{name:"options",number:8,type:11,label:1,typeName:".google.protobuf.FieldOptions"},{name:"proto3_optional",number:17,type:8,label:1}],enumType:[{name:"Type",value:[{name:"TYPE_DOUBLE",number:1},{name:"TYPE_FLOAT",number:2},{name:"TYPE_INT64",number:3},{name:"TYPE_UINT64",number:4},{name:"TYPE_INT32",number:5},{name:"TYPE_FIXED64",number:6},{name:"TYPE_FIXED32",number:7},{name:"TYPE_BOOL",number:8},{name:"TYPE_STRING",number:9},{name:"TYPE_GROUP",number:10},{name:"TYPE_MESSAGE",number:11},{name:"TYPE_BYTES",number:12},{name:"TYPE_UINT32",number:13},{name:"TYPE_ENUM",number:14},{name:"TYPE_SFIXED32",number:15},{name:"TYPE_SFIXED64",number:16},{name:"TYPE_SINT32",number:17},{name:"TYPE_SINT64",number:18}]},{name:"Label",value:[{name:"LABEL_OPTIONAL",number:1},{name:"LABEL_REPEATED",number:3},{name:"LABEL_REQUIRED",number:2}]}]},{name:"OneofDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"options",number:2,type:11,label:1,typeName:".google.protobuf.OneofOptions"}]},{name:"EnumDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"value",number:2,type:11,label:3,typeName:".google.protobuf.EnumValueDescriptorProto"},{name:"options",number:3,type:11,label:1,typeName:".google.protobuf.EnumOptions"},{name:"reserved_range",number:4,type:11,label:3,typeName:".google.protobuf.EnumDescriptorProto.EnumReservedRange"},{name:"reserved_name",number:5,type:9,label:3},{name:"visibility",number:6,type:14,label:1,typeName:".google.protobuf.SymbolVisibility"}],nestedType:[{name:"EnumReservedRange",field:[{name:"start",number:1,type:5,label:1},{name:"end",number:2,type:5,label:1}]}]},{name:"EnumValueDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"number",number:2,type:5,label:1},{name:"options",number:3,type:11,label:1,typeName:".google.protobuf.EnumValueOptions"}]},{name:"ServiceDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"method",number:2,type:11,label:3,typeName:".google.protobuf.MethodDescriptorProto"},{name:"options",number:3,type:11,label:1,typeName:".google.protobuf.ServiceOptions"}]},{name:"MethodDescriptorProto",field:[{name:"name",number:1,type:9,label:1},{name:"input_type",number:2,type:9,label:1},{name:"output_type",number:3,type:9,label:1},{name:"options",number:4,type:11,label:1,typeName:".google.protobuf.MethodOptions"},{name:"client_streaming",number:5,type:8,label:1,defaultValue:"false"},{name:"server_streaming",number:6,type:8,label:1,defaultValue:"false"}]},{name:"FileOptions",field:[{name:"java_package",number:1,type:9,label:1},{name:"java_outer_classname",number:8,type:9,label:1},{name:"java_multiple_files",number:10,type:8,label:1,defaultValue:"false"},{name:"java_generate_equals_and_hash",number:20,type:8,label:1,options:{deprecated:!0}},{name:"java_string_check_utf8",number:27,type:8,label:1,defaultValue:"false"},{name:"optimize_for",number:9,type:14,label:1,typeName:".google.protobuf.FileOptions.OptimizeMode",defaultValue:"SPEED"},{name:"go_package",number:11,type:9,label:1},{name:"cc_generic_services",number:16,type:8,label:1,defaultValue:"false"},{name:"java_generic_services",number:17,type:8,label:1,defaultValue:"false"},{name:"py_generic_services",number:18,type:8,label:1,defaultValue:"false"},{name:"deprecated",number:23,type:8,label:1,defaultValue:"false"},{name:"cc_enable_arenas",number:31,type:8,label:1,defaultValue:"true"},{name:"objc_class_prefix",number:36,type:9,label:1},{name:"csharp_namespace",number:37,type:9,label:1},{name:"swift_prefix",number:39,type:9,label:1},{name:"php_class_prefix",number:40,type:9,label:1},{name:"php_namespace",number:41,type:9,label:1},{name:"php_metadata_namespace",number:44,type:9,label:1},{name:"ruby_package",number:45,type:9,label:1},{name:"features",number:50,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],enumType:[{name:"OptimizeMode",value:[{name:"SPEED",number:1},{name:"CODE_SIZE",number:2},{name:"LITE_RUNTIME",number:3}]}],extensionRange:[{start:1e3,end:536870912}]},{name:"MessageOptions",field:[{name:"message_set_wire_format",number:1,type:8,label:1,defaultValue:"false"},{name:"no_standard_descriptor_accessor",number:2,type:8,label:1,defaultValue:"false"},{name:"deprecated",number:3,type:8,label:1,defaultValue:"false"},{name:"map_entry",number:7,type:8,label:1},{name:"deprecated_legacy_json_field_conflicts",number:11,type:8,label:1,options:{deprecated:!0}},{name:"features",number:12,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],extensionRange:[{start:1e3,end:536870912}]},{name:"FieldOptions",field:[{name:"ctype",number:1,type:14,label:1,typeName:".google.protobuf.FieldOptions.CType",defaultValue:"STRING"},{name:"packed",number:2,type:8,label:1},{name:"jstype",number:6,type:14,label:1,typeName:".google.protobuf.FieldOptions.JSType",defaultValue:"JS_NORMAL"},{name:"lazy",number:5,type:8,label:1,defaultValue:"false"},{name:"unverified_lazy",number:15,type:8,label:1,defaultValue:"false"},{name:"deprecated",number:3,type:8,label:1,defaultValue:"false"},{name:"weak",number:10,type:8,label:1,defaultValue:"false",options:{deprecated:!0}},{name:"debug_redact",number:16,type:8,label:1,defaultValue:"false"},{name:"retention",number:17,type:14,label:1,typeName:".google.protobuf.FieldOptions.OptionRetention"},{name:"targets",number:19,type:14,label:3,typeName:".google.protobuf.FieldOptions.OptionTargetType"},{name:"edition_defaults",number:20,type:11,label:3,typeName:".google.protobuf.FieldOptions.EditionDefault"},{name:"features",number:21,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"feature_support",number:22,type:11,label:1,typeName:".google.protobuf.FieldOptions.FeatureSupport"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],nestedType:[{name:"EditionDefault",field:[{name:"edition",number:3,type:14,label:1,typeName:".google.protobuf.Edition"},{name:"value",number:2,type:9,label:1}]},{name:"FeatureSupport",field:[{name:"edition_introduced",number:1,type:14,label:1,typeName:".google.protobuf.Edition"},{name:"edition_deprecated",number:2,type:14,label:1,typeName:".google.protobuf.Edition"},{name:"deprecation_warning",number:3,type:9,label:1},{name:"edition_removed",number:4,type:14,label:1,typeName:".google.protobuf.Edition"}]}],enumType:[{name:"CType",value:[{name:"STRING",number:0},{name:"CORD",number:1},{name:"STRING_PIECE",number:2}]},{name:"JSType",value:[{name:"JS_NORMAL",number:0},{name:"JS_STRING",number:1},{name:"JS_NUMBER",number:2}]},{name:"OptionRetention",value:[{name:"RETENTION_UNKNOWN",number:0},{name:"RETENTION_RUNTIME",number:1},{name:"RETENTION_SOURCE",number:2}]},{name:"OptionTargetType",value:[{name:"TARGET_TYPE_UNKNOWN",number:0},{name:"TARGET_TYPE_FILE",number:1},{name:"TARGET_TYPE_EXTENSION_RANGE",number:2},{name:"TARGET_TYPE_MESSAGE",number:3},{name:"TARGET_TYPE_FIELD",number:4},{name:"TARGET_TYPE_ONEOF",number:5},{name:"TARGET_TYPE_ENUM",number:6},{name:"TARGET_TYPE_ENUM_ENTRY",number:7},{name:"TARGET_TYPE_SERVICE",number:8},{name:"TARGET_TYPE_METHOD",number:9}]}],extensionRange:[{start:1e3,end:536870912}]},{name:"OneofOptions",field:[{name:"features",number:1,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],extensionRange:[{start:1e3,end:536870912}]},{name:"EnumOptions",field:[{name:"allow_alias",number:2,type:8,label:1},{name:"deprecated",number:3,type:8,label:1,defaultValue:"false"},{name:"deprecated_legacy_json_field_conflicts",number:6,type:8,label:1,options:{deprecated:!0}},{name:"features",number:7,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],extensionRange:[{start:1e3,end:536870912}]},{name:"EnumValueOptions",field:[{name:"deprecated",number:1,type:8,label:1,defaultValue:"false"},{name:"features",number:2,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"debug_redact",number:3,type:8,label:1,defaultValue:"false"},{name:"feature_support",number:4,type:11,label:1,typeName:".google.protobuf.FieldOptions.FeatureSupport"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],extensionRange:[{start:1e3,end:536870912}]},{name:"ServiceOptions",field:[{name:"features",number:34,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"deprecated",number:33,type:8,label:1,defaultValue:"false"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],extensionRange:[{start:1e3,end:536870912}]},{name:"MethodOptions",field:[{name:"deprecated",number:33,type:8,label:1,defaultValue:"false"},{name:"idempotency_level",number:34,type:14,label:1,typeName:".google.protobuf.MethodOptions.IdempotencyLevel",defaultValue:"IDEMPOTENCY_UNKNOWN"},{name:"features",number:35,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"uninterpreted_option",number:999,type:11,label:3,typeName:".google.protobuf.UninterpretedOption"}],enumType:[{name:"IdempotencyLevel",value:[{name:"IDEMPOTENCY_UNKNOWN",number:0},{name:"NO_SIDE_EFFECTS",number:1},{name:"IDEMPOTENT",number:2}]}],extensionRange:[{start:1e3,end:536870912}]},{name:"UninterpretedOption",field:[{name:"name",number:2,type:11,label:3,typeName:".google.protobuf.UninterpretedOption.NamePart"},{name:"identifier_value",number:3,type:9,label:1},{name:"positive_int_value",number:4,type:4,label:1},{name:"negative_int_value",number:5,type:3,label:1},{name:"double_value",number:6,type:1,label:1},{name:"string_value",number:7,type:12,label:1},{name:"aggregate_value",number:8,type:9,label:1}],nestedType:[{name:"NamePart",field:[{name:"name_part",number:1,type:9,label:2},{name:"is_extension",number:2,type:8,label:2}]}]},{name:"FeatureSet",field:[{name:"field_presence",number:1,type:14,label:1,typeName:".google.protobuf.FeatureSet.FieldPresence",options:{retention:1,targets:[4,1],editionDefaults:[{value:"EXPLICIT",edition:900},{value:"IMPLICIT",edition:999},{value:"EXPLICIT",edition:1e3}]}},{name:"enum_type",number:2,type:14,label:1,typeName:".google.protobuf.FeatureSet.EnumType",options:{retention:1,targets:[6,1],editionDefaults:[{value:"CLOSED",edition:900},{value:"OPEN",edition:999}]}},{name:"repeated_field_encoding",number:3,type:14,label:1,typeName:".google.protobuf.FeatureSet.RepeatedFieldEncoding",options:{retention:1,targets:[4,1],editionDefaults:[{value:"EXPANDED",edition:900},{value:"PACKED",edition:999}]}},{name:"utf8_validation",number:4,type:14,label:1,typeName:".google.protobuf.FeatureSet.Utf8Validation",options:{retention:1,targets:[4,1],editionDefaults:[{value:"NONE",edition:900},{value:"VERIFY",edition:999}]}},{name:"message_encoding",number:5,type:14,label:1,typeName:".google.protobuf.FeatureSet.MessageEncoding",options:{retention:1,targets:[4,1],editionDefaults:[{value:"LENGTH_PREFIXED",edition:900}]}},{name:"json_format",number:6,type:14,label:1,typeName:".google.protobuf.FeatureSet.JsonFormat",options:{retention:1,targets:[3,6,1],editionDefaults:[{value:"LEGACY_BEST_EFFORT",edition:900},{value:"ALLOW",edition:999}]}},{name:"enforce_naming_style",number:7,type:14,label:1,typeName:".google.protobuf.FeatureSet.EnforceNamingStyle",options:{retention:2,targets:[1,2,3,4,5,6,7,8,9],editionDefaults:[{value:"STYLE_LEGACY",edition:900},{value:"STYLE2024",edition:1001}]}},{name:"default_symbol_visibility",number:8,type:14,label:1,typeName:".google.protobuf.FeatureSet.VisibilityFeature.DefaultSymbolVisibility",options:{retention:2,targets:[1],editionDefaults:[{value:"EXPORT_ALL",edition:900},{value:"EXPORT_TOP_LEVEL",edition:1001}]}}],nestedType:[{name:"VisibilityFeature",enumType:[{name:"DefaultSymbolVisibility",value:[{name:"DEFAULT_SYMBOL_VISIBILITY_UNKNOWN",number:0},{name:"EXPORT_ALL",number:1},{name:"EXPORT_TOP_LEVEL",number:2},{name:"LOCAL_ALL",number:3},{name:"STRICT",number:4}]}]}],enumType:[{name:"FieldPresence",value:[{name:"FIELD_PRESENCE_UNKNOWN",number:0},{name:"EXPLICIT",number:1},{name:"IMPLICIT",number:2},{name:"LEGACY_REQUIRED",number:3}]},{name:"EnumType",value:[{name:"ENUM_TYPE_UNKNOWN",number:0},{name:"OPEN",number:1},{name:"CLOSED",number:2}]},{name:"RepeatedFieldEncoding",value:[{name:"REPEATED_FIELD_ENCODING_UNKNOWN",number:0},{name:"PACKED",number:1},{name:"EXPANDED",number:2}]},{name:"Utf8Validation",value:[{name:"UTF8_VALIDATION_UNKNOWN",number:0},{name:"VERIFY",number:2},{name:"NONE",number:3}]},{name:"MessageEncoding",value:[{name:"MESSAGE_ENCODING_UNKNOWN",number:0},{name:"LENGTH_PREFIXED",number:1},{name:"DELIMITED",number:2}]},{name:"JsonFormat",value:[{name:"JSON_FORMAT_UNKNOWN",number:0},{name:"ALLOW",number:1},{name:"LEGACY_BEST_EFFORT",number:2}]},{name:"EnforceNamingStyle",value:[{name:"ENFORCE_NAMING_STYLE_UNKNOWN",number:0},{name:"STYLE2024",number:1},{name:"STYLE_LEGACY",number:2}]}],extensionRange:[{start:1e3,end:9995},{start:9995,end:1e4},{start:1e4,end:10001}]},{name:"FeatureSetDefaults",field:[{name:"defaults",number:1,type:11,label:3,typeName:".google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault"},{name:"minimum_edition",number:4,type:14,label:1,typeName:".google.protobuf.Edition"},{name:"maximum_edition",number:5,type:14,label:1,typeName:".google.protobuf.Edition"}],nestedType:[{name:"FeatureSetEditionDefault",field:[{name:"edition",number:3,type:14,label:1,typeName:".google.protobuf.Edition"},{name:"overridable_features",number:4,type:11,label:1,typeName:".google.protobuf.FeatureSet"},{name:"fixed_features",number:5,type:11,label:1,typeName:".google.protobuf.FeatureSet"}]}]},{name:"SourceCodeInfo",field:[{name:"location",number:1,type:11,label:3,typeName:".google.protobuf.SourceCodeInfo.Location"}],nestedType:[{name:"Location",field:[{name:"path",number:1,type:5,label:3,options:{packed:!0}},{name:"span",number:2,type:5,label:3,options:{packed:!0}},{name:"leading_comments",number:3,type:9,label:1},{name:"trailing_comments",number:4,type:9,label:1},{name:"leading_detached_comments",number:6,type:9,label:3}]}],extensionRange:[{start:536e6,end:536000001}]},{name:"GeneratedCodeInfo",field:[{name:"annotation",number:1,type:11,label:3,typeName:".google.protobuf.GeneratedCodeInfo.Annotation"}],nestedType:[{name:"Annotation",field:[{name:"path",number:1,type:5,label:3,options:{packed:!0}},{name:"source_file",number:2,type:9,label:1},{name:"begin",number:3,type:5,label:1},{name:"end",number:4,type:5,label:1},{name:"semantic",number:5,type:14,label:1,typeName:".google.protobuf.GeneratedCodeInfo.Annotation.Semantic"}],enumType:[{name:"Semantic",value:[{name:"NONE",number:0},{name:"SET",number:1},{name:"ALIAS",number:2}]}]}]}],enumType:[{name:"Edition",value:[{name:"EDITION_UNKNOWN",number:0},{name:"EDITION_LEGACY",number:900},{name:"EDITION_PROTO2",number:998},{name:"EDITION_PROTO3",number:999},{name:"EDITION_2023",number:1e3},{name:"EDITION_2024",number:1001},{name:"EDITION_UNSTABLE",number:9999},{name:"EDITION_1_TEST_ONLY",number:1},{name:"EDITION_2_TEST_ONLY",number:2},{name:"EDITION_99997_TEST_ONLY",number:99997},{name:"EDITION_99998_TEST_ONLY",number:99998},{name:"EDITION_99999_TEST_ONLY",number:99999},{name:"EDITION_MAX",number:2147483647}]},{name:"SymbolVisibility",value:[{name:"VISIBILITY_UNSET",number:0},{name:"VISIBILITY_LOCAL",number:1},{name:"VISIBILITY_EXPORT",number:2}]}]}),cc=Le(ac,1);var or;(function(e){e[e.DECLARATION=0]="DECLARATION",e[e.UNVERIFIED=1]="UNVERIFIED"})(or||(or={}));var sr;(function(e){e[e.DOUBLE=1]="DOUBLE",e[e.FLOAT=2]="FLOAT",e[e.INT64=3]="INT64",e[e.UINT64=4]="UINT64",e[e.INT32=5]="INT32",e[e.FIXED64=6]="FIXED64",e[e.FIXED32=7]="FIXED32",e[e.BOOL=8]="BOOL",e[e.STRING=9]="STRING",e[e.GROUP=10]="GROUP",e[e.MESSAGE=11]="MESSAGE",e[e.BYTES=12]="BYTES",e[e.UINT32=13]="UINT32",e[e.ENUM=14]="ENUM",e[e.SFIXED32=15]="SFIXED32",e[e.SFIXED64=16]="SFIXED64",e[e.SINT32=17]="SINT32",e[e.SINT64=18]="SINT64"})(sr||(sr={}));var ir;(function(e){e[e.OPTIONAL=1]="OPTIONAL",e[e.REPEATED=3]="REPEATED",e[e.REQUIRED=2]="REQUIRED"})(ir||(ir={}));var ar;(function(e){e[e.SPEED=1]="SPEED",e[e.CODE_SIZE=2]="CODE_SIZE",e[e.LITE_RUNTIME=3]="LITE_RUNTIME"})(ar||(ar={}));var cr;(function(e){e[e.STRING=0]="STRING",e[e.CORD=1]="CORD",e[e.STRING_PIECE=2]="STRING_PIECE"})(cr||(cr={}));var ur;(function(e){e[e.JS_NORMAL=0]="JS_NORMAL",e[e.JS_STRING=1]="JS_STRING",e[e.JS_NUMBER=2]="JS_NUMBER"})(ur||(ur={}));var lr;(function(e){e[e.RETENTION_UNKNOWN=0]="RETENTION_UNKNOWN",e[e.RETENTION_RUNTIME=1]="RETENTION_RUNTIME",e[e.RETENTION_SOURCE=2]="RETENTION_SOURCE"})(lr||(lr={}));var dr;(function(e){e[e.TARGET_TYPE_UNKNOWN=0]="TARGET_TYPE_UNKNOWN",e[e.TARGET_TYPE_FILE=1]="TARGET_TYPE_FILE",e[e.TARGET_TYPE_EXTENSION_RANGE=2]="TARGET_TYPE_EXTENSION_RANGE",e[e.TARGET_TYPE_MESSAGE=3]="TARGET_TYPE_MESSAGE",e[e.TARGET_TYPE_FIELD=4]="TARGET_TYPE_FIELD",e[e.TARGET_TYPE_ONEOF=5]="TARGET_TYPE_ONEOF",e[e.TARGET_TYPE_ENUM=6]="TARGET_TYPE_ENUM",e[e.TARGET_TYPE_ENUM_ENTRY=7]="TARGET_TYPE_ENUM_ENTRY",e[e.TARGET_TYPE_SERVICE=8]="TARGET_TYPE_SERVICE",e[e.TARGET_TYPE_METHOD=9]="TARGET_TYPE_METHOD"})(dr||(dr={}));var Mn;(function(e){e[e.IDEMPOTENCY_UNKNOWN=0]="IDEMPOTENCY_UNKNOWN",e[e.NO_SIDE_EFFECTS=1]="NO_SIDE_EFFECTS",e[e.IDEMPOTENT=2]="IDEMPOTENT"})(Mn||(Mn={}));var fr;(function(e){e[e.DEFAULT_SYMBOL_VISIBILITY_UNKNOWN=0]="DEFAULT_SYMBOL_VISIBILITY_UNKNOWN",e[e.EXPORT_ALL=1]="EXPORT_ALL",e[e.EXPORT_TOP_LEVEL=2]="EXPORT_TOP_LEVEL",e[e.LOCAL_ALL=3]="LOCAL_ALL",e[e.STRICT=4]="STRICT"})(fr||(fr={}));var mr;(function(e){e[e.FIELD_PRESENCE_UNKNOWN=0]="FIELD_PRESENCE_UNKNOWN",e[e.EXPLICIT=1]="EXPLICIT",e[e.IMPLICIT=2]="IMPLICIT",e[e.LEGACY_REQUIRED=3]="LEGACY_REQUIRED"})(mr||(mr={}));var hr;(function(e){e[e.ENUM_TYPE_UNKNOWN=0]="ENUM_TYPE_UNKNOWN",e[e.OPEN=1]="OPEN",e[e.CLOSED=2]="CLOSED"})(hr||(hr={}));var gr;(function(e){e[e.REPEATED_FIELD_ENCODING_UNKNOWN=0]="REPEATED_FIELD_ENCODING_UNKNOWN",e[e.PACKED=1]="PACKED",e[e.EXPANDED=2]="EXPANDED"})(gr||(gr={}));var pr;(function(e){e[e.UTF8_VALIDATION_UNKNOWN=0]="UTF8_VALIDATION_UNKNOWN",e[e.VERIFY=2]="VERIFY",e[e.NONE=3]="NONE"})(pr||(pr={}));var br;(function(e){e[e.MESSAGE_ENCODING_UNKNOWN=0]="MESSAGE_ENCODING_UNKNOWN",e[e.LENGTH_PREFIXED=1]="LENGTH_PREFIXED",e[e.DELIMITED=2]="DELIMITED"})(br||(br={}));var Er;(function(e){e[e.JSON_FORMAT_UNKNOWN=0]="JSON_FORMAT_UNKNOWN",e[e.ALLOW=1]="ALLOW",e[e.LEGACY_BEST_EFFORT=2]="LEGACY_BEST_EFFORT"})(Er||(Er={}));var Ar;(function(e){e[e.ENFORCE_NAMING_STYLE_UNKNOWN=0]="ENFORCE_NAMING_STYLE_UNKNOWN",e[e.STYLE2024=1]="STYLE2024",e[e.STYLE_LEGACY=2]="STYLE_LEGACY"})(Ar||(Ar={}));var Nr;(function(e){e[e.NONE=0]="NONE",e[e.SET=1]="SET",e[e.ALIAS=2]="ALIAS"})(Nr||(Nr={}));var yr;(function(e){e[e.EDITION_UNKNOWN=0]="EDITION_UNKNOWN",e[e.EDITION_LEGACY=900]="EDITION_LEGACY",e[e.EDITION_PROTO2=998]="EDITION_PROTO2",e[e.EDITION_PROTO3=999]="EDITION_PROTO3",e[e.EDITION_2023=1e3]="EDITION_2023",e[e.EDITION_2024=1001]="EDITION_2024",e[e.EDITION_UNSTABLE=9999]="EDITION_UNSTABLE",e[e.EDITION_1_TEST_ONLY=1]="EDITION_1_TEST_ONLY",e[e.EDITION_2_TEST_ONLY=2]="EDITION_2_TEST_ONLY",e[e.EDITION_99997_TEST_ONLY=99997]="EDITION_99997_TEST_ONLY",e[e.EDITION_99998_TEST_ONLY=99998]="EDITION_99998_TEST_ONLY",e[e.EDITION_99999_TEST_ONLY=99999]="EDITION_99999_TEST_ONLY",e[e.EDITION_MAX=2147483647]="EDITION_MAX"})(yr||(yr={}));var Sr;(function(e){e[e.VISIBILITY_UNSET=0]="VISIBILITY_UNSET",e[e.VISIBILITY_LOCAL=1]="VISIBILITY_LOCAL",e[e.VISIBILITY_EXPORT=2]="VISIBILITY_EXPORT"})(Sr||(Sr={}));const Ir={readUnknownFields:!0};function uc(e){return e?Object.assign(Object.assign({},Ir),e):Ir}function Nn(e,n,t){const r=q(e,void 0,!1);return Es(r,new gt(n),uc(t),!1,n.byteLength),r.message}function Es(e,n,t,r,o){var s;const i=r?n.len:n.pos+o;let a,c;const u=(s=e.getUnknown())!==null&&s!==void 0?s:[];for(;n.pos<i&&([a,c]=n.tag(),!(r&&c==G.EndGroup));){const l=e.findNumber(a);if(!l){const d=n.skip(c,a);t.readUnknownFields&&u.push({no:a,wireType:c,data:d});continue}As(e,n,l,c,t)}if(r&&(c!=G.EndGroup||a!==o))throw new Error("invalid end group tag");u.length>0&&e.setUnknown(u)}function As(e,n,t,r,o){var s;switch(t.fieldKind){case"scalar":e.set(t,ve(n,t.scalar));break;case"enum":const i=ve(n,m.INT32);if(t.enum.open)e.set(t,i);else if(t.enum.values.some(c=>c.number===i))e.set(t,i);else if(o.readUnknownFields){const c=[];Jn(i,c);const u=(s=e.getUnknown())!==null&&s!==void 0?s:[];u.push({no:t.number,wireType:r,data:new Uint8Array(c)}),e.setUnknown(u)}break;case"message":e.set(t,_t(n,o,t,e.get(t)));break;case"list":dc(n,r,e.get(t),o);break;case"map":lc(n,e.get(t),o);break}}function lc(e,n,t){const r=n.field();let o,s;const i=e.uint32(),a=e.pos+i;for(;e.pos<a;){const[c]=e.tag();switch(c){case 1:o=ve(e,r.mapKey);break;case 2:switch(r.mapKind){case"scalar":s=ve(e,r.scalar);break;case"enum":s=e.int32();break;case"message":s=_t(e,t,r);break}break}}if(o===void 0&&(o=_e(r.mapKey,!1)),s===void 0)switch(r.mapKind){case"scalar":s=_e(r.scalar,!1);break;case"enum":s=r.enum.values[0].number;break;case"message":s=q(r.message,void 0,!1);break}n.set(o,s)}function dc(e,n,t,r){var o;const s=t.field();if(s.listKind==="message"){t.add(_t(e,r,s));return}const i=(o=s.scalar)!==null&&o!==void 0?o:m.INT32;if(!(n==G.LengthDelimited&&i!=m.STRING&&i!=m.BYTES)){t.add(ve(e,i));return}const c=e.uint32()+e.pos;for(;e.pos<c;)t.add(ve(e,i))}function _t(e,n,t,r){const o=t.delimitedEncoding,s=r??q(t.message,void 0,!1);return Es(s,e,n,o,o?t.number:e.uint32()),s}function ve(e,n){switch(n){case m.STRING:return e.string();case m.BOOL:return e.bool();case m.DOUBLE:return e.double();case m.FLOAT:return e.float();case m.INT32:return e.int32();case m.INT64:return e.int64();case m.UINT64:return e.uint64();case m.FIXED64:return e.fixed64();case m.BYTES:return e.bytes();case m.FIXED32:return e.fixed32();case m.SFIXED32:return e.sfixed32();case m.SFIXED64:return e.sfixed64();case m.SINT64:return e.sint64();case m.UINT32:return e.uint32();case m.SINT32:return e.sint32()}}function pe(e,n){var t;const r=Nn(cc,yt(e));return r.messageType.forEach(St),r.dependency=(t=n==null?void 0:n.map(s=>s.proto.name))!==null&&t!==void 0?t:[],fs(r,s=>n==null?void 0:n.find(i=>i.proto.name===s)).getFile(r.name)}const fc=pe("Chlnb29nbGUvcHJvdG9idWYvYW55LnByb3RvEg9nb29nbGUucHJvdG9idWYiJgoDQW55EhAKCHR5cGVfdXJsGAEgASgJEg0KBXZhbHVlGAIgASgMQnYKE2NvbS5nb29nbGUucHJvdG9idWZCCEFueVByb3RvUAFaLGdvb2dsZS5nb2xhbmcub3JnL3Byb3RvYnVmL3R5cGVzL2tub3duL2FueXBiogIDR1BCqgIeR29vZ2xlLlByb3RvYnVmLldlbGxLbm93blR5cGVzYgZwcm90bzM"),mc=Le(fc,0),hc=3,_r={writeUnknownFields:!0};function gc(e){return e?Object.assign(Object.assign({},_r),e):_r}function Ns(e,n,t){return an(new qo,gc(t),q(e,n)).finish()}function an(e,n,t){var r;for(const o of t.sortedFields){if(!t.isSet(o)){if(o.presence==hc)throw new Error(`cannot encode ${o} to binary: required field not set`);continue}ys(e,n,t,o)}if(n.writeUnknownFields)for(const{no:o,wireType:s,data:i}of(r=t.getUnknown())!==null&&r!==void 0?r:[])e.tag(o,s).raw(i);return e}function ys(e,n,t,r){var o;switch(r.fieldKind){case"scalar":case"enum":cn(e,t.desc.typeName,r.name,(o=r.scalar)!==null&&o!==void 0?o:m.INT32,r.number,t.get(r));break;case"list":pc(e,n,r,t.get(r));break;case"message":Ss(e,n,r,t.get(r));break;case"map":for(const[s,i]of t.get(r))bc(e,n,r,s,i);break}}function cn(e,n,t,r,o,s){Is(e.tag(o,Ec(r)),n,t,r,s)}function Ss(e,n,t,r){t.delimitedEncoding?an(e.tag(t.number,G.StartGroup),n,r).tag(t.number,G.EndGroup):an(e.tag(t.number,G.LengthDelimited).fork(),n,r).join()}function pc(e,n,t,r){var o;if(t.listKind=="message"){for(const i of r)Ss(e,n,t,i);return}const s=(o=t.scalar)!==null&&o!==void 0?o:m.INT32;if(t.packed){if(!r.size)return;e.tag(t.number,G.LengthDelimited).fork();for(const i of r)Is(e,t.parent.typeName,t.name,s,i);e.join();return}for(const i of r)cn(e,t.parent.typeName,t.name,s,t.number,i)}function bc(e,n,t,r,o){var s;switch(e.tag(t.number,G.LengthDelimited).fork(),cn(e,t.parent.typeName,t.name,t.mapKey,1,r),t.mapKind){case"scalar":case"enum":cn(e,t.parent.typeName,t.name,(s=t.scalar)!==null&&s!==void 0?s:m.INT32,2,o);break;case"message":an(e.tag(2,G.LengthDelimited).fork(),n,o).join();break}e.join()}function Is(e,n,t,r,o){try{switch(r){case m.STRING:e.string(o);break;case m.BOOL:e.bool(o);break;case m.DOUBLE:e.double(o);break;case m.FLOAT:e.float(o);break;case m.INT32:e.int32(o);break;case m.INT64:e.int64(o);break;case m.UINT64:e.uint64(o);break;case m.FIXED64:e.fixed64(o);break;case m.BYTES:e.bytes(o);break;case m.FIXED32:e.fixed32(o);break;case m.SFIXED32:e.sfixed32(o);break;case m.SFIXED64:e.sfixed64(o);break;case m.SINT64:e.sint64(o);break;case m.UINT32:e.uint32(o);break;case m.SINT32:e.sint32(o);break}}catch(s){throw s instanceof Error?new Error(`cannot encode field ${n}.${t} to binary: ${s.message}`):s}}function Ec(e){switch(e){case m.BYTES:case m.STRING:return G.LengthDelimited;case m.DOUBLE:case m.FIXED64:case m.SFIXED64:return G.Bit64;case m.FIXED32:case m.SFIXED32:case m.FLOAT:return G.Bit32;default:return G.Varint}}function Ac(e,n,t){let r=!1;return t||(t=H(mc),r=!0),t.value=Ns(e,n),t.typeUrl=Sc(n.$typeName),r?t:void 0}function Nc(e,n){if(e.typeUrl==="")return!1;const t=typeof n=="string"?n:n.typeName,r=_s(e.typeUrl);return t===r}function yc(e,n){if(e.typeUrl==="")return;const t=n.kind=="message"?n:n.getMessage(_s(e.typeUrl));if(!(!t||!Nc(e,t)))return Nn(t,e.value)}function Sc(e){return`type.googleapis.com/${e}`}function _s(e){const n=e.lastIndexOf("/"),t=n>=0?e.substring(n+1):e;if(!t.length)throw new Error(`invalid type url: ${e}`);return t}const Zt=pe("Chxnb29nbGUvcHJvdG9idWYvc3RydWN0LnByb3RvEg9nb29nbGUucHJvdG9idWYihAEKBlN0cnVjdBIzCgZmaWVsZHMYASADKAsyIy5nb29nbGUucHJvdG9idWYuU3RydWN0LkZpZWxkc0VudHJ5GkUKC0ZpZWxkc0VudHJ5EgsKA2tleRgBIAEoCRIlCgV2YWx1ZRgCIAEoCzIWLmdvb2dsZS5wcm90b2J1Zi5WYWx1ZToCOAEi6gEKBVZhbHVlEjAKCm51bGxfdmFsdWUYASABKA4yGi5nb29nbGUucHJvdG9idWYuTnVsbFZhbHVlSAASFgoMbnVtYmVyX3ZhbHVlGAIgASgBSAASFgoMc3RyaW5nX3ZhbHVlGAMgASgJSAASFAoKYm9vbF92YWx1ZRgEIAEoCEgAEi8KDHN0cnVjdF92YWx1ZRgFIAEoCzIXLmdvb2dsZS5wcm90b2J1Zi5TdHJ1Y3RIABIwCgpsaXN0X3ZhbHVlGAYgASgLMhouZ29vZ2xlLnByb3RvYnVmLkxpc3RWYWx1ZUgAQgYKBGtpbmQiMwoJTGlzdFZhbHVlEiYKBnZhbHVlcxgBIAMoCzIWLmdvb2dsZS5wcm90b2J1Zi5WYWx1ZSobCglOdWxsVmFsdWUSDgoKTlVMTF9WQUxVRRAAQn8KE2NvbS5nb29nbGUucHJvdG9idWZCC1N0cnVjdFByb3RvUAFaL2dvb2dsZS5nb2xhbmcub3JnL3Byb3RvYnVmL3R5cGVzL2tub3duL3N0cnVjdHBi+AEBogIDR1BCqgIeR29vZ2xlLlByb3RvYnVmLldlbGxLbm93blR5cGVzYgZwcm90bzM"),Ic=Le(Zt,0),Zs=Le(Zt,1),_c=Le(Zt,2);var $n;(function(e){e[e.NULL_VALUE=0]="NULL_VALUE"})($n||($n={}));function Zc(e,n){Rs(n,e);const t=vc(e.$unknown,n),[r,o,s]=yn(n);for(const i of t)As(r,new gt(i.data),o,i.wireType,{readUnknownFields:!0});return s()}function Rc(e,n,t){var r;Rs(n,e);const o=((r=e.$unknown)!==null&&r!==void 0?r:[]).filter(u=>u.no!==n.number),[s,i]=yn(n,t),a=new qo;ys(a,{writeUnknownFields:!0},s,i);const c=new gt(a.finish());for(;c.pos<c.len;){const[u,l]=c.tag(),d=c.skip(l,u);o.push({no:u,wireType:l,data:d})}e.$unknown=o}function vc(e,n){if(e===void 0)return[];if(n.fieldKind==="enum"||n.fieldKind==="scalar"){for(let t=e.length-1;t>=0;--t)if(e[t].no==n.number)return[e[t]];return[]}return e.filter(t=>t.no===n.number)}function yn(e,n){const t=e.typeName,r=Object.assign(Object.assign({},e),{kind:"field",parent:e.extendee,localName:t}),o=Object.assign(Object.assign({},e.extendee),{fields:[r],members:[r],oneofs:[]}),s=H(o,n!==void 0?{[t]:n}:void 0);return[q(o,s),r,()=>{const i=s[t];if(i===void 0){const a=e.message;return Ke(a)?_e(a.fields[0].scalar,a.fields[0].longAsString):H(a)}return i}]}function Rs(e,n){if(e.extendee.typeName!=n.$typeName)throw new Error(`extension ${e.typeName} can only be applied to message ${e.extendee.typeName}`)}const Vc=3,Cc=2,Zr={alwaysEmitImplicit:!1,enumAsInteger:!1,useProtoFieldName:!1};function wc(e){return e?Object.assign(Object.assign({},Zr),e):Zr}function kc(e,n,t){return Me(q(e,n),wc(t))}function Bc(e,n,t){var r;const o=kc(e,n,t);return JSON.stringify(o,null,(r=t==null?void 0:t.prettySpaces)!==null&&r!==void 0?r:0)}function Me(e,n){var t;const r=Uc(e,n);if(r!==void 0)return r;const o={};for(const s of e.sortedFields){if(!e.isSet(s)){if(s.presence==Vc)throw new Error(`cannot encode ${s} to JSON: required field not set`);if(!n.alwaysEmitImplicit||s.presence!==Cc)continue}const i=Rr(s,e.get(s),n);i!==void 0&&(o[Tc(s,n)]=i)}if(n.registry){const s=new Set;for(const{no:i}of(t=e.getUnknown())!==null&&t!==void 0?t:[])if(!s.has(i)){s.add(i);const a=n.registry.getExtensionFor(e.desc,i);if(!a)continue;const c=Zc(e.message,a),[u,l]=yn(a,c),d=Rr(l,u.get(l),n);d!==void 0&&(o[a.jsonName]=d)}}return o}function Rr(e,n,t){switch(e.fieldKind){case"scalar":return Sn(e,n);case"message":return Me(n,t);case"enum":return Rt(e.enum,n,t.enumAsInteger);case"list":return Gc(n,t);case"map":return Fc(n,t)}}function Fc(e,n){const t=e.field(),r={};switch(t.mapKind){case"scalar":for(const[o,s]of e)r[o]=Sn(t,s);break;case"message":for(const[o,s]of e)r[o]=Me(s,n);break;case"enum":for(const[o,s]of e)r[o]=Rt(t.enum,s,n.enumAsInteger);break}return n.alwaysEmitImplicit||e.size>0?r:void 0}function Gc(e,n){const t=e.field(),r=[];switch(t.listKind){case"scalar":for(const o of e)r.push(Sn(t,o));break;case"enum":for(const o of e)r.push(Rt(t.enum,o,n.enumAsInteger));break;case"message":for(const o of e)r.push(Me(o,n));break}return n.alwaysEmitImplicit||r.length>0?r:void 0}function Rt(e,n,t){var r;if(typeof n!="number")throw new Error(`cannot encode ${e} to JSON: expected number, got ${X(n)}`);if(e.typeName=="google.protobuf.NullValue")return null;if(t)return n;const o=e.value[n];return(r=o==null?void 0:o.name)!==null&&r!==void 0?r:n}function Sn(e,n){var t,r,o,s,i,a;switch(e.scalar){case m.INT32:case m.SFIXED32:case m.SINT32:case m.FIXED32:case m.UINT32:if(typeof n!="number")throw new Error(`cannot encode ${e} to JSON: ${(t=he(e,n))===null||t===void 0?void 0:t.message}`);return n;case m.FLOAT:case m.DOUBLE:if(typeof n!="number")throw new Error(`cannot encode ${e} to JSON: ${(r=he(e,n))===null||r===void 0?void 0:r.message}`);return Number.isNaN(n)?"NaN":n===Number.POSITIVE_INFINITY?"Infinity":n===Number.NEGATIVE_INFINITY?"-Infinity":n;case m.STRING:if(typeof n!="string")throw new Error(`cannot encode ${e} to JSON: ${(o=he(e,n))===null||o===void 0?void 0:o.message}`);return n;case m.BOOL:if(typeof n!="boolean")throw new Error(`cannot encode ${e} to JSON: ${(s=he(e,n))===null||s===void 0?void 0:s.message}`);return n;case m.UINT64:case m.FIXED64:case m.INT64:case m.SFIXED64:case m.SINT64:if(typeof n!="bigint"&&typeof n!="string")throw new Error(`cannot encode ${e} to JSON: ${(i=he(e,n))===null||i===void 0?void 0:i.message}`);return n.toString();case m.BYTES:if(n instanceof Uint8Array)return us(n);throw new Error(`cannot encode ${e} to JSON: ${(a=he(e,n))===null||a===void 0?void 0:a.message}`)}}function Tc(e,n){return n.useProtoFieldName?e.name:e.jsonName}function Uc(e,n){if(e.desc.typeName.startsWith("google.protobuf."))switch(e.desc.typeName){case"google.protobuf.Any":return Yc(e.message,n);case"google.protobuf.Timestamp":return Xc(e.message);case"google.protobuf.Duration":return Wc(e.message);case"google.protobuf.FieldMask":return Oc(e.message);case"google.protobuf.Struct":return vs(e.message);case"google.protobuf.Value":return vt(e.message);case"google.protobuf.ListValue":return Vs(e.message);default:if(Ke(e.desc)){const t=e.desc.fields[0];return Sn(t,e.get(t))}return}}function Yc(e,n){if(e.typeUrl==="")return{};const{registry:t}=n;let r,o;if(t&&(r=yc(e,t),r&&(o=t.getMessage(r.$typeName))),!o||!r)throw new Error(`cannot encode message ${e.$typeName} to JSON: "${e.typeUrl}" is not in the type registry`);let s=Me(q(o,r),n);return(o.typeName.startsWith("google.protobuf.")||s===null||Array.isArray(s)||typeof s!="object")&&(s={value:s}),s["@type"]=e.typeUrl,s}function Wc(e){const n=Number(e.seconds),t=e.nanos;if(n>315576e6||n<-315576e6)throw new Error(`cannot encode message ${e.$typeName} to JSON: value out of range`);if(n>0&&t<0||n<0&&t>0)throw new Error(`cannot encode message ${e.$typeName} to JSON: nanos sign must match seconds sign`);let r=e.seconds.toString();if(t!==0){let o=Math.abs(t).toString();o="0".repeat(9-o.length)+o,o.substring(3)==="000000"?o=o.substring(0,3):o.substring(6)==="000"&&(o=o.substring(0,6)),r+="."+o,t<0&&n==0&&(r="-"+r)}return r+"s"}function Oc(e){return e.paths.map(n=>{if(ds(Ze(n))!==n)throw new Error(`cannot encode message ${e.$typeName} to JSON: lowerCamelCase of path name "${n}" is irreversible`);return Ze(n)}).join(",")}function vs(e){const n={};for(const[t,r]of Object.entries(e.fields))n[t]=vt(r);return n}function vt(e){switch(e.kind.case){case"nullValue":return null;case"numberValue":if(!Number.isFinite(e.kind.value))throw new Error(`${e.$typeName} cannot be NaN or Infinity`);return e.kind.value;case"boolValue":return e.kind.value;case"stringValue":return e.kind.value;case"structValue":return vs(e.kind.value);case"listValue":return Vs(e.kind.value);default:throw new Error(`${e.$typeName} must have a value`)}}function Vs(e){return e.values.map(vt)}function Xc(e){const n=Number(e.seconds)*1e3;if(n<Date.parse("0001-01-01T00:00:00Z")||n>Date.parse("9999-12-31T23:59:59Z"))throw new Error(`cannot encode message ${e.$typeName} to JSON: must be from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59Z inclusive`);if(e.nanos<0)throw new Error(`cannot encode message ${e.$typeName} to JSON: nanos must not be negative`);if(e.nanos>999999999)throw new Error(`cannot encode message ${e.$typeName} to JSON: nanos must not be greater than 99999999`);let t="Z";if(e.nanos>0){const r=(e.nanos+1e9).toString().substring(1);r.substring(3)==="000000"?t="."+r.substring(0,3)+"Z":r.substring(6)==="000"?t="."+r.substring(0,6)+"Z":t="."+r+"Z"}return new Date(n).toISOString().replace(".000Z",t)}const vr={ignoreUnknownFields:!1};function zc(e){return e?Object.assign(Object.assign({},vr),e):vr}function Jc(e,n,t){return Cs(e,jc(n,e.typeName),t)}function Cs(e,n,t){const r=q(e);try{Oe(r,n,zc(t))}catch(o){throw Sa(o)?new Error(`cannot decode ${o.field()} from JSON: ${o.message}`,{cause:o}):o}return r.message}const Wn=new WeakMap;function Dc(e,n){var t;if(!Wn.has(e)){const r=new Map;for(const o of e.fields)r.set(o.name,o).set(o.jsonName,o);Wn.set(e,r)}return(t=Wn.get(e))===null||t===void 0?void 0:t.get(n)}function Oe(e,n,t){var r;if(Qc(e,n,t))return;if(n==null||Array.isArray(n)||typeof n!="object")throw new Error(`cannot decode ${e.desc} from JSON: ${X(n)}`);const o=new Map;for(const[s,i]of Object.entries(n)){const a=Dc(e.desc,s);if(a){if(a.oneof){if(i===null&&a.fieldKind=="scalar")continue;const c=o.get(a.oneof);if(c!==void 0)throw new L(a.oneof,`oneof set multiple times by ${c.name} and ${a.name}`);o.set(a.oneof,a)}Vr(e,a,i,t)}else{let c;if(s.startsWith("[")&&s.endsWith("]")&&(c=(r=t.registry)===null||r===void 0?void 0:r.getExtension(s.substring(1,s.length-1)))&&c.extendee.typeName===e.desc.typeName){const[u,l,d]=yn(c);Vr(u,l,i,t),Rc(e.message,c,d())}if(!c&&!t.ignoreUnknownFields)throw new Error(`cannot decode ${e.desc} from JSON: key "${s}" is unknown`)}}}function Vr(e,n,t,r){switch(n.fieldKind){case"scalar":$c(e,n,t);break;case"enum":Mc(e,n,t,r);break;case"message":Lc(e,n,t,r);break;case"list":Kc(e.get(n),t,r);break;case"map":xc(e.get(n),t,r);break}}function ws(e,n,t){if(e.scalar&&n!==null)return Vt(e,n);if(e.message&&!un(e,n)){const r=q(e.message);return Oe(r,n,t),r}if(e.enum&&!un(e,n))return ks(e.enum,n,t.ignoreUnknownFields);throw new L(e,`${e.fieldKind==="list"?"list item":"map value"} must not be null`)}function xc(e,n,t){if(n===null)return;const r=e.field();if(typeof n!="object"||Array.isArray(n))throw new L(r,"expected object, got "+X(n));for(const[o,s]of Object.entries(n)){const i=Pc(r.mapKey,o),a=ws(r,s,t);a!==In&&e.set(i,a)}}function Kc(e,n,t){if(n===null)return;const r=e.field();if(!Array.isArray(n))throw new L(r,"expected Array, got "+X(n));for(const o of n){const s=ws(r,o,t);s!==In&&e.add(s)}}function Lc(e,n,t,r){if(un(n,t)){e.clear(n);return}const o=e.isSet(n)?e.get(n):q(n.message);Oe(o,t,r),e.set(n,o)}function Mc(e,n,t,r){if(un(n,t)){e.clear(n);return}const o=ks(n.enum,t,r.ignoreUnknownFields);o!==In&&e.set(n,o)}function $c(e,n,t){t===null?e.clear(n):e.set(n,Vt(n,t))}function un(e,n){var t,r;return n===null&&((t=e.message)===null||t===void 0?void 0:t.typeName)!="google.protobuf.Value"&&((r=e.enum)===null||r===void 0?void 0:r.typeName)!="google.protobuf.NullValue"}const In=Symbol();function ks(e,n,t){if(n===null)return e.values[0].number;switch(typeof n){case"number":if(Number.isInteger(n))return n;break;case"string":const r=e.values.find(o=>o.name===n);if(r!==void 0)return r.number;if(t)return In;break}throw new Error(`cannot decode ${e} from JSON: ${X(n)}`)}function Vt(e,n){switch(e.scalar){case m.DOUBLE:case m.FLOAT:if(n==="NaN")return NaN;if(n==="Infinity")return Number.POSITIVE_INFINITY;if(n==="-Infinity")return Number.NEGATIVE_INFINITY;if(typeof n=="number"){if(Number.isNaN(n))throw new L(e,"unexpected NaN number");if(!Number.isFinite(n))throw new L(e,"unexpected infinite number");break}if(typeof n=="string"){if(n===""||n.trim().length!==n.length)break;const t=Number(n);if(!Number.isFinite(t))break;return t}break;case m.INT32:case m.FIXED32:case m.SFIXED32:case m.SINT32:case m.UINT32:return Bs(n);case m.BYTES:if(typeof n=="string"){if(n==="")return new Uint8Array(0);try{return yt(n)}catch(t){const r=t instanceof Error?t.message:String(t);throw new L(e,r)}}break}return n}function Pc(e,n){switch(e){case m.BOOL:switch(n){case"true":return!0;case"false":return!1}return n;case m.INT32:case m.FIXED32:case m.UINT32:case m.SFIXED32:case m.SINT32:return Bs(n);default:return n}}function Bs(e){if(typeof e=="string"){if(e===""||e.trim().length!==e.length)return e;const n=Number(e);return Number.isNaN(n)?e:n}return e}function jc(e,n){try{return JSON.parse(e)}catch(t){const r=t instanceof Error?t.message:String(t);throw new Error(`cannot decode message ${n} from JSON: ${r}`,{cause:t})}}function Qc(e,n,t){if(!e.desc.typeName.startsWith("google.protobuf."))return!1;switch(e.desc.typeName){case"google.protobuf.Any":return Hc(e.message,n,t),!0;case"google.protobuf.Timestamp":return qc(e.message,n),!0;case"google.protobuf.Duration":return eu(e.message,n),!0;case"google.protobuf.FieldMask":return nu(e.message,n),!0;case"google.protobuf.Struct":return Fs(e.message,n),!0;case"google.protobuf.Value":return Ct(e.message,n),!0;case"google.protobuf.ListValue":return Gs(e.message,n),!0;default:if(Ke(e.desc)){const r=e.desc.fields[0];return n===null?e.clear(r):e.set(r,Vt(r,n)),!0}return!1}}function Hc(e,n,t){var r;if(n===null||Array.isArray(n)||typeof n!="object")throw new Error(`cannot decode message ${e.$typeName} from JSON: expected object but got ${X(n)}`);if(Object.keys(n).length==0)return;const o=n["@type"];if(typeof o!="string"||o=="")throw new Error(`cannot decode message ${e.$typeName} from JSON: "@type" is empty`);const s=o.includes("/")?o.substring(o.lastIndexOf("/")+1):o;if(!s.length)throw new Error(`cannot decode message ${e.$typeName} from JSON: "@type" is invalid`);const i=(r=t.registry)===null||r===void 0?void 0:r.getMessage(s);if(!i)throw new Error(`cannot decode message ${e.$typeName} from JSON: ${o} is not in the type registry`);const a=q(i);if(s.startsWith("google.protobuf.")&&Object.prototype.hasOwnProperty.call(n,"value")){const c=n.value;Oe(a,c,t)}else{const c=Object.assign({},n);delete c["@type"],Oe(a,c,t)}Ac(a.desc,a.message,e)}function qc(e,n){if(typeof n!="string")throw new Error(`cannot decode message ${e.$typeName} from JSON: ${X(n)}`);const t=n.match(/^([0-9]{4})-([0-9]{2})-([0-9]{2})T([0-9]{2}):([0-9]{2}):([0-9]{2})(?:\.([0-9]{1,9}))?(?:Z|([+-][0-9][0-9]:[0-9][0-9]))$/);if(!t)throw new Error(`cannot decode message ${e.$typeName} from JSON: invalid RFC 3339 string`);const r=Date.parse(t[1]+"-"+t[2]+"-"+t[3]+"T"+t[4]+":"+t[5]+":"+t[6]+(t[8]?t[8]:"Z"));if(Number.isNaN(r))throw new Error(`cannot decode message ${e.$typeName} from JSON: invalid RFC 3339 string`);if(r<Date.parse("0001-01-01T00:00:00Z")||r>Date.parse("9999-12-31T23:59:59Z"))throw new Error(`cannot decode message ${e.$typeName} from JSON: must be from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59Z inclusive`);e.seconds=w.parse(r/1e3),e.nanos=0,t[7]&&(e.nanos=parseInt("1"+t[7]+"0".repeat(9-t[7].length))-1e9)}function eu(e,n){if(typeof n!="string")throw new Error(`cannot decode message ${e.$typeName} from JSON: ${X(n)}`);const t=n.match(/^(-?[0-9]+)(?:\.([0-9]+))?s/);if(t===null)throw new Error(`cannot decode message ${e.$typeName} from JSON: ${X(n)}`);const r=Number(t[1]);if(r>315576e6||r<-315576e6)throw new Error(`cannot decode message ${e.$typeName} from JSON: ${X(n)}`);if(e.seconds=w.parse(r),typeof t[2]!="string")return;const o=t[2]+"0".repeat(9-t[2].length);e.nanos=parseInt(o),(r<0||Object.is(r,-0))&&(e.nanos=-e.nanos)}function nu(e,n){if(typeof n!="string")throw new Error(`cannot decode message ${e.$typeName} from JSON: ${X(n)}`);n!==""&&(e.paths=n.split(",").map(t=>{if(t.includes("_"))throw new Error(`cannot decode message ${e.$typeName} from JSON: path names must be lowerCamelCase`);return ds(t)}))}function Fs(e,n){if(typeof n!="object"||n==null||Array.isArray(n))throw new Error(`cannot decode message ${e.$typeName} from JSON ${X(n)}`);for(const[t,r]of Object.entries(n)){const o=H(Zs);Ct(o,r),e.fields[t]=o}}function Ct(e,n){switch(typeof n){case"number":e.kind={case:"numberValue",value:n};break;case"string":e.kind={case:"stringValue",value:n};break;case"boolean":e.kind={case:"boolValue",value:n};break;case"object":if(n===null)e.kind={case:"nullValue",value:$n.NULL_VALUE};else if(Array.isArray(n)){const t=H(_c);Gs(t,n),e.kind={case:"listValue",value:t}}else{const t=H(Ic);Fs(t,n),e.kind={case:"structValue",value:t}}break;default:throw new Error(`cannot decode message ${e.$typeName} from JSON ${X(n)}`)}return e}function Gs(e,n){if(!Array.isArray(n))throw new Error(`cannot decode message ${e.$typeName} from JSON ${X(n)}`);for(const t of n){const r=H(Zs);Ct(r,t),e.values.push(r)}}function Pn(e){const n=Z[e];return typeof n!="string"?e.toString():n[0].toLowerCase()+n.substring(1).replace(/[A-Z]/g,t=>"_"+t.toLowerCase())}let He;function tu(e){if(!He){He={};for(const n of Object.values(Z))typeof n!="string"&&(He[Pn(n)]=n)}return He[e]}class T extends Error{constructor(n,t=Z.Unknown,r,o,s){super(ru(n,t)),this.name="ConnectError",Object.setPrototypeOf(this,new.target.prototype),this.rawMessage=n,this.code=t,this.metadata=new Headers(r??{}),this.details=o??[],this.cause=s}static from(n,t=Z.Unknown){return n instanceof T?n:n instanceof Error?n.name=="AbortError"||n.name=="TimeoutError"?new T(n.message,Z.Canceled):new T(n.message,t,void 0,void 0,n):new T(String(n),t,void 0,void 0,n)}static[Symbol.hasInstance](n){return n instanceof Error?Object.getPrototypeOf(n)===T.prototype?!0:n.name==="ConnectError"&&"code"in n&&typeof n.code=="number"&&"metadata"in n&&"details"in n&&Array.isArray(n.details)&&"rawMessage"in n&&typeof n.rawMessage=="string"&&"cause"in n:!1}findDetails(n){const t=n.kind==="message"?{getMessage:o=>o===n.typeName?n:void 0}:n,r=[];for(const o of this.details){if("desc"in o){t.getMessage(o.desc.typeName)&&r.push(H(o.desc,o.value));continue}const s=t.getMessage(o.type);if(s)try{r.push(Nn(s,o.value))}catch{}}return r}}function ru(e,n){return e.length?`[${Pn(n)}] ${e}`:`[${Pn(n)}]`}function ou(...e){const n=new Headers;for(const t of e)t.forEach((r,o)=>{n.append(o,r)});return n}function su(e,n){const t={};for(const r of e.methods){const o=n(r);o!=null&&(t[r.localName]=o)}return t}const Cr=1;function iu(e,n,t=!1){if(n>e){let r=`message size is larger than configured readMaxBytes ${e}`;throw t&&(r=`message size ${n} is larger than configured readMaxBytes ${e}`),new T(r,Z.ResourceExhausted)}}function au(e){return new cu(e)}class cu{constructor(n){this.readMaxBytes=n,this.header=new Uint8Array(5),this.headerView=new DataView(this.header.buffer),this.buf=[]}get byteLength(){return this.buf.reduce((n,t)=>n+t.byteLength,0)}decode(n){this.buf.push(n);const t=[];for(;;){let r=this.pop();if(!r)break;t.push(r)}return t}pop(){if(!(!this.env&&(this.env=this.head(),!this.env))&&this.cons(this.env.data)){const n=this.env;return this.env=void 0,n}}head(){if(!this.cons(this.header))return;const n=this.headerView.getUint8(0),t=this.headerView.getUint32(1);return iu(this.readMaxBytes,t,!0),{flags:n,data:new Uint8Array(t)}}cons(n){const t=n.byteLength;if(this.byteLength<t)return!1;let r=0;for(;r<t;){const o=this.buf.shift();o.byteLength>t-r?(n.set(o.subarray(0,t-r),r),this.buf.unshift(o.subarray(t-r)),r+=t-r):(n.set(o,r),r+=o.byteLength)}return!0}}function uu(e){let n;const t=au(4294967295);return new ReadableStream({start(){n=e.getReader()},async pull(r){let o=!1;for(;!o;){const s=await n.read();if(s.done)t.byteLength>0&&r.error(new T("protocol error: incomplete envelope",Z.InvalidArgument)),r.close();else for(const i of t.decode(s.value))r.enqueue(i),o=!0}}})}function lu(e,n){const t=new Uint8Array(n.length+5);t.set(n,5);const r=new DataView(t.buffer,t.byteOffset,t.byteLength);return r.setUint8(0,e),r.setUint32(1,n.length),t}var du=function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n=e[Symbol.asyncIterator],t;return n?n.call(e):(e=typeof __values=="function"?__values(e):e[Symbol.iterator](),t={},r("next"),r("throw"),r("return"),t[Symbol.asyncIterator]=function(){return this},t);function r(s){t[s]=e[s]&&function(i){return new Promise(function(a,c){i=e[s](i),o(a,c,i.done,i.value)})}}function o(s,i,a,c){Promise.resolve(c).then(function(u){s({value:u,done:a})},i)}},Xe=function(e){return this instanceof Xe?(this.v=e,this):new Xe(e)},fu=function(e,n,t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r=t.apply(e,n||[]),o,s=[];return o=Object.create((typeof AsyncIterator=="function"?AsyncIterator:Object).prototype),a("next"),a("throw"),a("return",i),o[Symbol.asyncIterator]=function(){return this},o;function i(f){return function(p){return Promise.resolve(p).then(f,d)}}function a(f,p){r[f]&&(o[f]=function(b){return new Promise(function(E,R){s.push([f,b,E,R])>1||c(f,b)})},p&&(o[f]=p(o[f])))}function c(f,p){try{u(r[f](p))}catch(b){g(s[0][3],b)}}function u(f){f.value instanceof Xe?Promise.resolve(f.value.v).then(l,d):g(s[0][2],f)}function l(f){c("next",f)}function d(f){c("throw",f)}function g(f,p){f(p),s.shift(),s.length&&c(s[0][0],s[0][1])}},mu=function(e){var n,t;return n={},r("next"),r("throw",function(o){throw o}),r("return"),n[Symbol.iterator]=function(){return this},n;function r(o,s){n[o]=e[o]?function(i){return(t=!t)?{value:Xe(e[o](i)),done:!1}:s?s(i):i}:s}};function hu(e){return fu(this,arguments,function*(){yield Xe(yield*mu(du(e)))})}var Ts=function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n=e[Symbol.asyncIterator],t;return n?n.call(e):(e=typeof __values=="function"?__values(e):e[Symbol.iterator](),t={},r("next"),r("throw"),r("return"),t[Symbol.asyncIterator]=function(){return this},t);function r(s){t[s]=e[s]&&function(i){return new Promise(function(a,c){i=e[s](i),o(a,c,i.done,i.value)})}}function o(s,i,a,c){Promise.resolve(c).then(function(u){s({value:u,done:a})},i)}},Ve=function(e){return this instanceof Ve?(this.v=e,this):new Ve(e)},gu=function(e){var n,t;return n={},r("next"),r("throw",function(o){throw o}),r("return"),n[Symbol.iterator]=function(){return this},n;function r(o,s){n[o]=e[o]?function(i){return(t=!t)?{value:Ve(e[o](i)),done:!1}:s?s(i):i}:s}},pu=function(e,n,t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r=t.apply(e,n||[]),o,s=[];return o=Object.create((typeof AsyncIterator=="function"?AsyncIterator:Object).prototype),a("next"),a("throw"),a("return",i),o[Symbol.asyncIterator]=function(){return this},o;function i(f){return function(p){return Promise.resolve(p).then(f,d)}}function a(f,p){r[f]&&(o[f]=function(b){return new Promise(function(E,R){s.push([f,b,E,R])>1||c(f,b)})},p&&(o[f]=p(o[f])))}function c(f,p){try{u(r[f](p))}catch(b){g(s[0][3],b)}}function u(f){f.value instanceof Ve?Promise.resolve(f.value.v).then(l,d):g(s[0][2],f)}function l(f){c("next",f)}function d(f){c("throw",f)}function g(f,p){f(p),s.shift(),s.length&&c(s[0][0],s[0][1])}};function Yg(e,n){return su(e,t=>{switch(t.methodKind){case"unary":return bu(n,t);case"server_streaming":return Eu(n,t);case"client_streaming":return Au(n,t);case"bidi_streaming":return Nu(n,t);default:return null}})}function bu(e,n){return async(t,r)=>{var o,s;const i=await e.unary(n,r==null?void 0:r.signal,r==null?void 0:r.timeoutMs,r==null?void 0:r.headers,t,r==null?void 0:r.contextValues);return(o=r==null?void 0:r.onHeader)===null||o===void 0||o.call(r,i.header),(s=r==null?void 0:r.onTrailer)===null||s===void 0||s.call(r,i.trailer),i.message}}function Eu(e,n){return(t,r)=>Us(e.stream(n,r==null?void 0:r.signal,r==null?void 0:r.timeoutMs,r==null?void 0:r.headers,hu([t]),r==null?void 0:r.contextValues),r)}function Au(e,n){return async(t,r)=>{var o,s,i,a,c,u;const l=await e.stream(n,r==null?void 0:r.signal,r==null?void 0:r.timeoutMs,r==null?void 0:r.headers,t,r==null?void 0:r.contextValues);(c=r==null?void 0:r.onHeader)===null||c===void 0||c.call(r,l.header);let d,g=0;try{for(var f=!0,p=Ts(l.message),b;b=await p.next(),o=b.done,!o;f=!0)a=b.value,f=!1,d=a,g++}catch(E){s={error:E}}finally{try{!f&&!o&&(i=p.return)&&await i.call(p)}finally{if(s)throw s.error}}if(!d)throw new T("protocol error: missing response message",Z.Unimplemented);if(g>1)throw new T("protocol error: received extra messages for client streaming method",Z.Unimplemented);return(u=r==null?void 0:r.onTrailer)===null||u===void 0||u.call(r,l.trailer),d}}function Nu(e,n){return(t,r)=>Us(e.stream(n,r==null?void 0:r.signal,r==null?void 0:r.timeoutMs,r==null?void 0:r.headers,t,r==null?void 0:r.contextValues),r)}function Us(e,n){const t=(function(){return pu(this,arguments,function*(){var r,o;const s=yield Ve(e);(r=n==null?void 0:n.onHeader)===null||r===void 0||r.call(n,s.header),yield Ve(yield*gu(Ts(s.message))),(o=n==null?void 0:n.onTrailer)===null||o===void 0||o.call(n,s.trailer)})})()[Symbol.asyncIterator]();return{[Symbol.asyncIterator]:()=>({next:()=>t.next()})}}function yu(...e){const n=new AbortController,t=e.filter(o=>o!==void 0).concat(n.signal);for(const o of t){if(o.aborted){r.apply(o);break}o.addEventListener("abort",r)}function r(){n.signal.aborted||n.abort(Ys(this));for(const o of t)o.removeEventListener("abort",r)}return n}function Su(e){const n=new AbortController,t=()=>{n.abort(new T("the operation timed out",Z.DeadlineExceeded))};let r;return e!==void 0&&(e<=0?t():r=setTimeout(t,e)),{signal:n.signal,cleanup:()=>clearTimeout(r)}}function Ys(e){if(!e.aborted)return;if(e.reason!==void 0)return e.reason;const n=new Error("This operation was aborted");return n.name="AbortError",n}function wr(){return{get(e){return e.id in this?this[e.id]:e.defaultValue},set(e,n){return this[e.id]=n,this},delete(e){return delete this[e.id],this}}}function _n(e,n,...t){if(t.length>0)throw new Error;return e.services[n]}function kr(e,n){return e.toString().replace(/\/?$/,`/${n.parent.typeName}/${n.name}`)}function Ws(e,n){return H(e,n)}function Iu(e,n){function t(r){return r.done===!0?r:{done:r.done,value:Ws(e,r.value)}}return{[Symbol.asyncIterator](){const r=n[Symbol.asyncIterator](),o={next:()=>r.next().then(t)};return r.throw!==void 0&&(o.throw=s=>r.throw(s).then(t)),r.return!==void 0&&(o.return=s=>r.return(s).then(t)),o}}}function Os(e,n){if(!n)return e;for(const t of n.concat().reverse())e=t(e);return e}function Xs(e){var n;const t=Object.assign({},e);return(n=t.ignoreUnknownFields)!==null&&n!==void 0||(t.ignoreUnknownFields=!0),t}function Br(e,n,t,r){const o=n?Fr(e.input,r):Gr(e.input,t);return{parse:(n?Fr(e.output,r):Gr(e.output,t)).parse,serialize:o.serialize}}function Fr(e,n){return{parse(t){try{return Nn(e,t,n)}catch(r){const o=r instanceof Error?r.message:String(r);throw new T(`parse binary: ${o}`,Z.Internal)}},serialize(t){try{return Ns(e,t,n)}catch(r){const o=r instanceof Error?r.message:String(r);throw new T(`serialize binary: ${o}`,Z.Internal)}}}}function Gr(e,n){var t,r;const o=(t=n==null?void 0:n.textEncoder)!==null&&t!==void 0?t:new TextEncoder,s=(r=n==null?void 0:n.textDecoder)!==null&&r!==void 0?r:new TextDecoder,i=Xs(n);return{parse(a){try{const c=s.decode(a);return Jc(e,c,i)}catch(c){throw T.from(c,Z.InvalidArgument)}},serialize(a){try{const c=Bc(e,a,i);return o.encode(c)}catch(c){throw T.from(c,Z.Internal)}}}}const _u=/^application\/(connect\+)?(?:(json)(?:; ?charset=utf-?8)?|(proto))$/i,Zu="application/proto",Ru="application/json",vu="application/connect+proto",Vu="application/connect+json";function Cu(e){const n=e==null?void 0:e.match(_u);if(!n)return;const t=!!n[1],r=!!n[3];return{stream:t,binary:r}}function zs(e,n,t){var r;if(n&&new Headers(n).forEach((a,c)=>t.metadata.append(c,a)),typeof e!="object"||e==null||Array.isArray(e))throw t;let o=t.code;"code"in e&&typeof e.code=="string"&&(o=(r=tu(e.code))!==null&&r!==void 0?r:o);const s=e.message;if(s!=null&&typeof s!="string")throw t;const i=new T(s??"",o,n);if("details"in e&&Array.isArray(e.details))for(const a of e.details){if(a===null||typeof a!="object"||Array.isArray(a)||typeof a.type!="string"||typeof a.value!="string")throw t;try{i.details.push({type:a.type,value:yt(a.value),debug:a.debug})}catch{throw t}}return i}const Tr=2;function wu(e){const n=new T("invalid end stream",Z.Unknown);let t;try{t=JSON.parse(typeof e=="string"?e:new TextDecoder().decode(e))}catch{throw n}if(typeof t!="object"||t==null||Array.isArray(t))throw n;const r=new Headers;if("metadata"in t){if(typeof t.metadata!="object"||t.metadata==null||Array.isArray(t.metadata))throw n;for(const[s,i]of Object.entries(t.metadata)){if(!Array.isArray(i)||i.some(a=>typeof a!="string"))throw n;for(const a of i)r.append(s,a)}}const o="error"in t&&t.error!=null?zs(t.error,r,n):void 0;return{metadata:r,error:o}}const ln="Content-Type",ku="Content-Length",Ur="Content-Encoding",Bu="Accept-Encoding",Fu="Connect-Timeout-Ms",Js="Connect-Protocol-Version",Gu="User-Agent";function Tu(e){switch(e){case 400:return Z.Internal;case 401:return Z.Unauthenticated;case 403:return Z.PermissionDenied;case 404:return Z.Unimplemented;case 429:return Z.Unavailable;case 502:return Z.Unavailable;case 503:return Z.Unavailable;case 504:return Z.Unavailable;default:return Z.Unknown}}function Yr(e){const n=new Headers,t=new Headers;return e.forEach((r,o)=>{o.toLowerCase().startsWith("trailer-")?t.append(o.substring(8),r):n.append(o,r)}),[n,t]}const Ds="1";function Wr(e,n,t,r,o){const s=new Headers(r??{});return t!==void 0&&s.set(Fu,`${t}`),s.set(ln,e=="unary"?n?Zu:Ru:n?vu:Vu),s.set(Js,Ds),s.has(Gu),s}function Or(e,n,t,r){const o=r.get(ln),s=Cu(o);if(t!==200){const a=new T(`HTTP ${t}`,Tu(t),r);if(e=="unary"&&s&&!s.binary)return{isUnaryError:!0,unaryError:a};throw a}const i={binary:n,stream:e!=="unary"};if((s==null?void 0:s.binary)!==i.binary||s.stream!==i.stream)throw new T(`unsupported content type ${o}`,s===void 0?Z.Unknown:Z.Internal,r);return{isUnaryError:!1}}const Xr="application/";function Uu(e,n){return n?us(e,"url"):encodeURIComponent(new TextDecoder().decode(e))}function Yu(e,n,t){let r=`?connect=v${Ds}`;const o=e.header.get(ln);(o==null?void 0:o.indexOf(Xr))===0&&(r+="&encoding="+encodeURIComponent(o.slice(Xr.length)));const s=e.header.get(Ur);s!==null&&s!=="identity"&&(r+="&compression="+encodeURIComponent(s),t=!0),t&&(r+="&base64=1"),r+="&message="+Uu(n,t);const i=e.url+r,a=new Headers(e.header);for(const c of[Js,ln,ku,Ur,Bu])a.delete(c);return Object.assign(Object.assign({},e),{requestMethod:"GET",url:i,header:a})}function Wu(e){const n=Os(e.next,e.interceptors),[t,r,o]=xs(e),s=Object.assign(Object.assign({},e.req),{message:Ws(e.req.method.input,e.req.message),signal:t});return n(s).then(i=>(o(),i),r)}function Ou(e){const n=Os(e.next,e.interceptors),[t,r,o]=xs(e),s=Object.assign(Object.assign({},e.req),{message:Iu(e.req.method.input,e.req.message),signal:t});let i=!1;return t.addEventListener("abort",function(){var a,c;const u=e.req.message[Symbol.asyncIterator]();i||(a=u.throw)===null||a===void 0||a.call(u,this.reason).catch(()=>{}),(c=u.return)===null||c===void 0||c.call(u).catch(()=>{})}),n(s).then(a=>Object.assign(Object.assign({},a),{message:{[Symbol.asyncIterator](){const c=a.message[Symbol.asyncIterator]();return{next(){return c.next().then(u=>(u.done==!0&&(i=!0,o()),u),r)}}}}}),r)}function xs(e){const{signal:n,cleanup:t}=Su(e.timeoutMs),r=yu(e.signal,n);return[r.signal,function(s){const i=T.from(n.aborted?Ys(n):s);return r.abort(i),t(),Promise.reject(i)},function(){t(),r.abort()}]}function Xu(){try{new Headers}catch{throw new Error("connect-web requires the fetch API. Are you running on an old version of Node.js? Node.js is not supported in Connect for Web - please stay tuned for Connect for Node.")}}var ze=function(e){return this instanceof ze?(this.v=e,this):new ze(e)},zu=function(e,n,t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r=t.apply(e,n||[]),o,s=[];return o=Object.create((typeof AsyncIterator=="function"?AsyncIterator:Object).prototype),a("next"),a("throw"),a("return",i),o[Symbol.asyncIterator]=function(){return this},o;function i(f){return function(p){return Promise.resolve(p).then(f,d)}}function a(f,p){r[f]&&(o[f]=function(b){return new Promise(function(E,R){s.push([f,b,E,R])>1||c(f,b)})},p&&(o[f]=p(o[f])))}function c(f,p){try{u(r[f](p))}catch(b){g(s[0][3],b)}}function u(f){f.value instanceof ze?Promise.resolve(f.value.v).then(l,d):g(s[0][2],f)}function l(f){c("next",f)}function d(f){c("throw",f)}function g(f,p){f(p),s.shift(),s.length&&c(s[0][0],s[0][1])}};const zr={redirect:"error"};function Wg(e){var n;Xu();const t=(n=e.useBinaryFormat)!==null&&n!==void 0?n:!1;return{async unary(r,o,s,i,a,c){const{serialize:u,parse:l}=Br(r,t,e.jsonOptions,e.binaryOptions);return s=s===void 0?e.defaultTimeoutMs:s<=0?void 0:s,await Wu({interceptors:e.interceptors,signal:o,timeoutMs:s,req:{stream:!1,service:r.parent,method:r,requestMethod:"POST",url:kr(e.baseUrl,r),header:Wr(r.methodKind,t,s,i,!1),contextValues:c??wr(),message:a},next:async d=>{var g;const f=e.useHttpGet===!0&&r.idempotency===Mn.NO_SIDE_EFFECTS;let p=null;f?d=Yu(d,u(d.message),t):p=u(d.message);const E=await((g=e.fetch)!==null&&g!==void 0?g:globalThis.fetch)(d.url,Object.assign(Object.assign({},zr),{method:d.requestMethod,headers:d.header,signal:d.signal,body:p})),{isUnaryError:R,unaryError:S}=Or(r.methodKind,t,E.status,E.headers);if(R)throw zs(await E.json(),ou(...Yr(E.headers)),S);const[z,B]=Yr(E.headers);return{stream:!1,service:r.parent,method:r,header:z,message:t?l(new Uint8Array(await E.arrayBuffer())):Cs(r.output,await E.json(),Xs(e.jsonOptions)),trailer:B}}})},async stream(r,o,s,i,a,c){const{serialize:u,parse:l}=Br(r,t,e.jsonOptions,e.binaryOptions);function d(f,p,b,E){return zu(this,arguments,function*(){const S=uu(f).getReader();let z=!1;for(;;){const B=yield ze(S.read());if(B.done)break;const{flags:W,data:O}=B.value;if((W&Cr)===Cr)throw new T("protocol error: received unsupported compressed output",Z.Internal);if((W&Tr)===Tr){z=!0;const U=wu(O);if(U.error){const J=U.error;throw b.forEach((M,$e)=>{J.metadata.append($e,M)}),J}U.metadata.forEach((J,M)=>p.set(M,J));continue}yield yield ze(l(O))}if("throwIfAborted"in E&&E.throwIfAborted(),!z)throw"missing EndStreamResponse"})}async function g(f){if(r.methodKind!="server_streaming")throw"The fetch API does not support streaming request bodies";const p=await f[Symbol.asyncIterator]().next();if(p.done==!0)throw"missing request message";return lu(0,u(p.value))}return s=s===void 0?e.defaultTimeoutMs:s<=0?void 0:s,await Ou({interceptors:e.interceptors,timeoutMs:s,signal:o,req:{stream:!0,service:r.parent,method:r,requestMethod:"POST",url:kr(e.baseUrl,r),header:Wr(r.methodKind,t,s,i,!1),contextValues:c??wr(),message:a},next:async f=>{var p;const E=await((p=e.fetch)!==null&&p!==void 0?p:globalThis.fetch)(f.url,Object.assign(Object.assign({},zr),{method:f.requestMethod,headers:f.header,signal:f.signal,body:await g(f.message)}));if(Or(r.methodKind,t,E.status,E.headers),E.body===null)throw"missing response body";const R=new Headers;return Object.assign(Object.assign({},f),{header:E.headers,trailer:R,message:d(E.body,R,E.headers,f.signal)})}})}}}const Zn=pe("ChtncmFja2xlL2dyYWNrbGVfdHlwZXMucHJvdG8SB2dyYWNrbGUiBwoFRW1wdHkiGwoNRW52aXJvbm1lbnRJZBIKCgJpZBgBIAEoCSIXCglTZXNzaW9uSWQSCgoCaWQYASABKAkiMAoQS2lsbEFnZW50UmVxdWVzdBIKCgJpZBgBIAEoCRIQCghncmFjZWZ1bBgCIAEoCCLXAQoLRW52aXJvbm1lbnQSCgoCaWQYASABKAkSFAoMZGlzcGxheV9uYW1lGAIgASgJEhQKDGFkYXB0ZXJfdHlwZRgDIAEoCRIWCg5hZGFwdGVyX2NvbmZpZxgEIAEoCRIUCgxib290c3RyYXBwZWQYBiABKAgSDgoGc3RhdHVzGAcgASgJEhEKCWxhc3Rfc2VlbhgIIAEoCRIQCghlbnZfaW5mbxgJIAEoCRISCgpjcmVhdGVkX2F0GAogASgJEhkKEWdpdGh1Yl9hY2NvdW50X2lkGAsgASgJIj0KD0Vudmlyb25tZW50TGlzdBIqCgxlbnZpcm9ubWVudHMYASADKAsyFC5ncmFja2xlLkVudmlyb25tZW50InYKFUFkZEVudmlyb25tZW50UmVxdWVzdBIUCgxkaXNwbGF5X25hbWUYASABKAkSFAoMYWRhcHRlcl90eXBlGAIgASgJEhYKDmFkYXB0ZXJfY29uZmlnGAMgASgJEhkKEWdpdGh1Yl9hY2NvdW50X2lkGAUgASgJIkIKDlByb3Zpc2lvbkV2ZW50Eg0KBXN0YWdlGAEgASgJEg8KB21lc3NhZ2UYAiABKAkSEAoIcHJvZ3Jl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MQVVERV9QUk9WSURFUl9NT0RFX1VOU1BFQ0lGSUVEEAASHAoYQ0xBVURFX1BST1ZJREVSX01PREVfT0ZGEAESJQohQ0xBVURFX1BST1ZJREVSX01PREVfU1VCU0NSSVBUSU9OEAISIAocQ0xBVURFX1BST1ZJREVSX01PREVfQVBJX0tFWRADKmIKDlByb3ZpZGVyVG9nZ2xlEh8KG1BST1ZJREVSX1RPR0dMRV9VTlNQRUNJRklFRBAAEhcKE1BST1ZJREVSX1RPR0dMRV9PRkYQARIWChJQUk9WSURFUl9UT0dHTEVfT04QAmIGcHJvdG8z");var I;(function(e){e[e.UNSPECIFIED=0]="UNSPECIFIED",e[e.TEXT=1]="TEXT",e[e.TOOL_USE=2]="TOOL_USE",e[e.TOOL_RESULT=3]="TOOL_RESULT",e[e.ERROR=4]="ERROR",e[e.STATUS=5]="STATUS",e[e.SYSTEM=6]="SYSTEM",e[e.USER_INPUT=9]="USER_INPUT",e[e.SIGNAL=10]="SIGNAL",e[e.USAGE=11]="USAGE",e[e.WIDGET=13]="WIDGET",e[e.TURN_STARTED=14]="TURN_STARTED",e[e.TURN_COMPLETE=15]="TURN_COMPLETE",e[e.INPUT_NEEDED=16]="INPUT_NEEDED"})(I||(I={}));var Y;(function(e){e[e.UNSPECIFIED=0]="UNSPECIFIED",e[e.NOT_STARTED=1]="NOT_STARTED",e[e.WORKING=3]="WORKING",e[e.PAUSED=4]="PAUSED",e[e.COMPLETE=5]="COMPLETE",e[e.FAILED=6]="FAILED"})(Y||(Y={}));var ie;(function(e){e[e.UNSPECIFIED=0]="UNSPECIFIED",e[e.ACTIVE=1]="ACTIVE",e[e.ARCHIVED=2]="ARCHIVED"})(ie||(ie={}));var ee;(function(e){e[e.UNSPECIFIED=0]="UNSPECIFIED",e[e.OFF=1]="OFF",e[e.SUBSCRIPTION=2]="SUBSCRIPTION",e[e.API_KEY=3]="API_KEY"})(ee||(ee={}));var ae;(function(e){e[e.UNSPECIFIED=0]="UNSPECIFIED",e[e.OFF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R1bGUSEy5ncmFja2xlLlNjaGVkdWxlSWQaDi5ncmFja2xlLkVtcHR5YgZwcm90bzM",[Zn]),zg=_n(xu,0),Ku=pe("Ch9ncmFja2xlL2dyYWNrbGVfa25vd2xlZGdlLnByb3RvEgdncmFja2xlMpQDChBHcmFja2xlS25vd2xlZGdlElQKD1NlYXJjaEtub3dsZWRnZRIfLmdyYWNrbGUuU2VhcmNoS25vd2xlZGdlUmVxdWVzdBogLmdyYWNrbGUuU2VhcmNoS25vd2xlZGdlUmVzcG9uc2USVwoQR2V0S25vd2xlZGdlTm9kZRIgLmdyYWNrbGUuR2V0S25vd2xlZGdlTm9kZVJlcXVlc3QaIS5ncmFja2xlLkdldEtub3dsZWRnZU5vZGVSZXNwb25zZRJgChNFeHBhbmRLbm93bGVkZ2VOb2RlEiMuZ3JhY2tsZS5FeHBhbmRLbm93bGVkZ2VOb2RlUmVxdWVzdBokLmdyYWNrbGUuRXhwYW5kS25vd2xlZGdlTm9kZVJlc3BvbnNlEm8KGExpc3RSZWNlbnRLbm93bGVkZ2VOb2RlcxIoLmdyYWNrbGUuTGlzdFJlY2VudEtub3dsZWRnZU5vZGVzUmVxdWVzdBopLmdyYWNrbGUuTGlzdFJlY2VudEtub3dsZWRnZU5vZGVzUmVzcG9uc2ViBnByb3RvMw",[Zn]),Jg=_n(Ku,0),Dg=8,xg="system",Kg="system",Lu=new Set(["config_get_default_persona","config_set_default_persona","credential_provider_list","credential_provider_set","env_list","env_add","env_provision","env_stop","env_destroy","env_remove","env_wake","ipc_spawn","ipc_write","ipc_close","ipc_list_fds","ipc_list_streams","ipc_terminate","ipc_create_stream","ipc_attach","ipc_share_stream","knowledge_search","knowledge_get_node","logs_get","persona_list","persona_create","persona_show","persona_edit","persona_delete","session_spawn","session_resume","session_status","session_kill","session_attach","session_send_input","task_list","task_search","task_create","task_show","task_update","task_start","task_delete","task_complete","task_resume","token_list","token_set","token_delete","usage_get","get_version_status","schedule_list","schedule_create","schedule_show","schedule_update","schedule_delete","workpad_write","workpad_read","workspace_list","workspace_create","workspace_get","workspace_update","workspace_archive","escalate_to_human","escalation_list","escalation_acknowledge","show_hello_widget","component_register","component_update","component_list","component_render","component_search","component_promote","widget_show","component_show"]),Lg=["task_create","task_list","task_search","task_show","task_start","task_complete","session_attach","session_send_input","persona_list","persona_show","ipc_spawn","ipc_write","ipc_close","ipc_terminate","ipc_list_fds","ipc_create_stream","ipc_attach","ipc_share_stream","knowledge_search","knowledge_get_node","logs_get","workpad_write","workpad_read","schedule_list","schedule_show","show_hello_widget","component_register","component_update","component_list","component_render","component_search","component_promote","widget_show","component_show"],Mg=["task_show","session_attach","session_send_input","persona_list","persona_show","ipc_spawn","ipc_write","ipc_close","ipc_terminate","ipc_list_fds","ipc_create_stream","ipc_attach","ipc_share_stream","knowledge_search","knowledge_get_node","logs_get","workpad_write","workpad_read"],$g=["task_create","task_list","task_search","task_show","task_start","task_complete","session_attach","session_send_input","persona_list","persona_show","ipc_spawn","ipc_write","ipc_close","ipc_terminate","ipc_list_fds","ipc_create_stream","ipc_attach","ipc_share_stream","knowledge_search","knowledge_get_node","logs_get","workpad_write","workpad_read","schedule_list","schedule_show","show_hello_widget","component_register","component_update","component_list","component_render","component_search","component_promote","widget_show","component_show","task_update","task_delete","task_resume","session_spawn","session_kill","session_status","persona_create","schedule_create","schedule_update","schedule_delete","escalate_to_human"],Pg=[...Lu];Object.assign(Object.create(null),{"":I.UNSPECIFIED,text:I.TEXT,tool_use:I.TOOL_USE,tool_result:I.TOOL_RESULT,error:I.ERROR,status:I.STATUS,system:I.SYSTEM,user_input:I.USER_INPUT,signal:I.SIGNAL,usage:I.USAGE,widget:I.WIDGET,turn_started:I.TURN_STARTED,turn_complete:I.TURN_COMPLETE,input_needed:I.INPUT_NEEDED});const Mu={[I.UNSPECIFIED]:"",[I.TEXT]:"text",[I.TOOL_USE]:"tool_use",[I.TOOL_RESULT]:"tool_result",[I.ERROR]:"error",[I.STATUS]:"status",[I.SYSTEM]:"system",[I.USER_INPUT]:"user_input",[I.SIGNAL]:"signal",[I.USAGE]:"usage",[I.WIDGET]:"widget",[I.TURN_STARTED]:"turn_started",[I.TURN_COMPLETE]:"turn_complete",[I.INPUT_NEEDED]:"input_needed"};function jg(e){return Mu[e]??""}Object.assign(Object.create(null),{"":Y.UNSPECIFIED,not_started:Y.NOT_STARTED,working:Y.WORKING,paused:Y.PAUSED,complete:Y.COMPLETE,failed:Y.FAILED,pending:Y.NOT_STARTED,assigned:Y.NOT_STARTED,in_progress:Y.WORKING,waiting_input:Y.PAUSED,review:Y.PAUSED,done:Y.COMPLETE});const $u={[Y.UNSPECIFIED]:"",[Y.NOT_STARTED]:"not_started",[Y.WORKING]:"working",[Y.PAUSED]:"paused",[Y.COMPLETE]:"complete",[Y.FAILED]:"failed"};function Qg(e){return $u[e]??""}Object.assign(Object.create(null),{"":ie.UNSPECIFIED,active:ie.ACTIVE,archived:ie.ARCHIVED});const Pu={[ie.UNSPECIFIED]:"",[ie.ACTIVE]:"active",[ie.ARCHIVED]:"archived"};function Hg(e){return Pu[e]??""}Object.assign(Object.create(null),{"":ee.UNSPECIFIED,off:ee.OFF,subscription:ee.SUBSCRIPTION,api_key:ee.API_KEY});const ju={[ee.UNSPECIFIED]:"",[ee.OFF]:"off",[ee.SUBSCRIPTION]:"subscription",[ee.API_KEY]:"api_key"};function qg(e){return ju[e]??""}Object.assign(Object.create(null),{"":ae.UNSPECIFIED,off:ae.OFF,on:ae.ON});const Qu={[ae.UNSPECIFIED]:"",[ae.OFF]:"off",[ae.ON]:"on"};function ep(e){return Qu[e]??""}function se(e){return Array.isArray?Array.isArray(e):Ms(e)==="[object Array]"}function Hu(e){if(typeof e=="string")return e;let n=e+"";return n=="0"&&1/e==-1/0?"-0":n}function qu(e){return e==null?"":Hu(e)}function ne(e){return typeof e=="string"}function Ks(e){return typeof e=="number"}function el(e){return e===!0||e===!1||nl(e)&&Ms(e)=="[object Boolean]"}function Ls(e){return typeof e=="object"}function nl(e){return Ls(e)&&e!==null}function K(e){return e!=null}function On(e){return!e.trim().length}function Ms(e){return e==null?e===void 0?"[object Undefined]":"[object Null]":Object.prototype.toString.call(e)}const tl="Incorrect 'index' type",rl=e=>`Invalid value for key ${e}`,ol=e=>`Pattern length exceeds max of ${e}.`,sl=e=>`Missing ${e} property in key`,il=e=>`Property 'weight' in key '${e}' must be a positive integer`,Jr=Object.prototype.hasOwnProperty;class al{constructor(n){this._keys=[],this._keyMap={};let t=0;n.forEach(r=>{let o=$s(r);this._keys.push(o),this._keyMap[o.id]=o,t+=o.weight}),this._keys.forEach(r=>{r.weight/=t})}get(n){return this._keyMap[n]}keys(){return this._keys}toJSON(){return JSON.stringify(this._keys)}}function $s(e){let n=null,t=null,r=null,o=1,s=null;if(ne(e)||se(e))r=e,n=Dr(e),t=jn(e);else{if(!Jr.call(e,"name"))throw new Error(sl("name"));const i=e.name;if(r=i,Jr.call(e,"weight")&&(o=e.weight,o<=0))throw new Error(il(i));n=Dr(i),t=jn(i),s=e.getFn}return{path:n,id:t,weight:o,src:r,getFn:s}}function Dr(e){return se(e)?e:e.split(".")}function jn(e){return se(e)?e.join("."):e}function cl(e,n){let t=[],r=!1;const o=(s,i,a)=>{if(K(s))if(!i[a])t.push(s);else{let c=i[a];const u=s[c];if(!K(u))return;if(a===i.length-1&&(ne(u)||Ks(u)||el(u)))t.push(qu(u));else if(se(u)){r=!0;for(let l=0,d=u.length;l<d;l+=1)o(u[l],i,a+1)}else i.length&&o(u,i,a+1)}};return o(e,ne(n)?n.split("."):n,0),r?t:t[0]}const ul={includeMatches:!1,findAllMatches:!1,minMatchCharLength:1},ll={isCaseSensitive:!1,ignoreDiacritics:!1,includeScore:!1,keys:[],shouldSort:!0,sortFn:(e,n)=>e.score===n.score?e.idx<n.idx?-1:1:e.score<n.score?-1:1},dl={location:0,threshold:.6,distance:100},fl={useExtendedSearch:!1,getFn:cl,ignoreLocation:!1,ignoreFieldNorm:!1,fieldNormWeight:1};var y={...ll,...ul,...dl,...fl};const ml=/[^ ]+/g;function hl(e=1,n=3){const t=new Map,r=Math.pow(10,n);return{get(o){const s=o.match(ml).length;if(t.has(s))return t.get(s);const i=1/Math.pow(s,.5*e),a=parseFloat(Math.round(i*r)/r);return t.set(s,a),a},clear(){t.clear()}}}class wt{constructor({getFn:n=y.getFn,fieldNormWeight:t=y.fieldNormWeight}={}){this.norm=hl(t,3),this.getFn=n,this.isCreated=!1,this.setIndexRecords()}setSources(n=[]){this.docs=n}setIndexRecords(n=[]){this.records=n}setKeys(n=[]){this.keys=n,this._keysMap={},n.forEach((t,r)=>{this._keysMap[t.id]=r})}create(){this.isCreated||!this.docs.length||(this.isCreated=!0,ne(this.docs[0])?this.docs.forEach((n,t)=>{this._addString(n,t)}):this.docs.forEach((n,t)=>{this._addObject(n,t)}),this.norm.clear())}add(n){const t=this.size();ne(n)?this._addString(n,t):this._addObject(n,t)}removeAt(n){this.records.splice(n,1);for(let t=n,r=this.size();t<r;t+=1)this.records[t].i-=1}getValueForItemAtKeyId(n,t){return n[this._keysMap[t]]}size(){return this.records.length}_addString(n,t){if(!K(n)||On(n))return;let r={v:n,i:t,n:this.norm.get(n)};this.records.push(r)}_addObject(n,t){let r={i:t,$:{}};this.keys.forEach((o,s)=>{let i=o.getFn?o.getFn(n):this.getFn(n,o.path);if(K(i)){if(se(i)){let a=[];const c=[{nestedArrIndex:-1,value:i}];for(;c.length;){const{nestedArrIndex:u,value:l}=c.pop();if(K(l))if(ne(l)&&!On(l)){let d={v:l,i:u,n:this.norm.get(l)};a.push(d)}else se(l)&&l.forEach((d,g)=>{c.push({nestedArrIndex:g,value:d})})}r.$[s]=a}else if(ne(i)&&!On(i)){let a={v:i,n:this.norm.get(i)};r.$[s]=a}}}),this.records.push(r)}toJSON(){return{keys:this.keys,records:this.records}}}function Ps(e,n,{getFn:t=y.getFn,fieldNormWeight:r=y.fieldNormWeight}={}){const o=new wt({getFn:t,fieldNormWeight:r});return o.setKeys(e.map($s)),o.setSources(n),o.create(),o}function gl(e,{getFn:n=y.getFn,fieldNormWeight:t=y.fieldNormWeight}={}){const{keys:r,records:o}=e,s=new wt({getFn:n,fieldNormWeight:t});return s.setKeys(r),s.setIndexRecords(o),s}function qe(e,{errors:n=0,currentLocation:t=0,expectedLocation:r=0,distance:o=y.distance,ignoreLocation:s=y.ignoreLocation}={}){const i=n/e.length;if(s)return i;const a=Math.abs(r-t);return o?i+a/o:a?1:i}function pl(e=[],n=y.minMatchCharLength){let t=[],r=-1,o=-1,s=0;for(let i=e.length;s<i;s+=1){let a=e[s];a&&r===-1?r=s:!a&&r!==-1&&(o=s-1,o-r+1>=n&&t.push([r,o]),r=-1)}return e[s-1]&&s-r>=n&&t.push([r,s-1]),t}const ge=32;function bl(e,n,t,{location:r=y.location,distance:o=y.distance,threshold:s=y.threshold,findAllMatches:i=y.findAllMatches,minMatchCharLength:a=y.minMatchCharLength,includeMatches:c=y.includeMatches,ignoreLocation:u=y.ignoreLocation}={}){if(n.length>ge)throw new Error(ol(ge));const l=n.length,d=e.length,g=Math.max(0,Math.min(r,d));let f=s,p=g;const b=a>1||c,E=b?Array(d):[];let R;for(;(R=e.indexOf(n,p))>-1;){let U=qe(n,{currentLocation:R,expectedLocation:g,distance:o,ignoreLocation:u});if(f=Math.min(U,f),p=R+l,b){let J=0;for(;J<l;)E[R+J]=1,J+=1}}p=-1;let S=[],z=1,B=l+d;const W=1<<l-1;for(let U=0;U<l;U+=1){let J=0,M=B;for(;J<M;)qe(n,{errors:U,currentLocation:g+M,expectedLocation:g,distance:o,ignoreLocation:u})<=f?J=M:B=M,M=Math.floor((B-J)/2+J);B=M;let $e=Math.max(1,g-M+1),wn=i?d:Math.min(g+M,d)+l,Ae=Array(wn+2);Ae[wn+1]=(1<<U)-1;for(let j=wn;j>=$e;j-=1){let Pe=j-1,Ot=t[e.charAt(Pe)];if(b&&(E[Pe]=+!!Ot),Ae[j]=(Ae[j+1]<<1|1)&Ot,U&&(Ae[j]|=(S[j+1]|S[j])<<1|1|S[j+1]),Ae[j]&W&&(z=qe(n,{errors:U,currentLocation:Pe,expectedLocation:g,distance:o,ignoreLocation:u}),z<=f)){if(f=z,p=Pe,p<=g)break;$e=Math.max(1,2*g-p)}}if(qe(n,{errors:U+1,currentLocation:g,expectedLocation:g,distance:o,ignoreLocation:u})>f)break;S=Ae}const O={isMatch:p>=0,score:Math.max(.001,z)};if(b){const U=pl(E,a);U.length?c&&(O.indices=U):O.isMatch=!1}return O}function El(e){let n={};for(let t=0,r=e.length;t<r;t+=1){const o=e.charAt(t);n[o]=(n[o]||0)|1<<r-t-1}return n}const dn=String.prototype.normalize?(e=>e.normalize("NFD").replace(/[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D3-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B62\u0B63\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0C00-\u0C04\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00-\u0D03\u0D3B\u0D3C\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D82\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EB9\u0EBB\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F\u109A-\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u192B\u1930-\u193B\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F\u1AB0-\u1ABE\u1B00-\u1B04\u1B34-\u1B44\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BE6-\u1BF3\u1C24-\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF2-\u1CF4\u1CF7-\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA880\uA881\uA8B4-\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9E5\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F]/g,"")):(e=>e);class js{constructor(n,{location:t=y.location,threshold:r=y.threshold,distance:o=y.distance,includeMatches:s=y.includeMatches,findAllMatches:i=y.findAllMatches,minMatchCharLength:a=y.minMatchCharLength,isCaseSensitive:c=y.isCaseSensitive,ignoreDiacritics:u=y.ignoreDiacritics,ignoreLocation:l=y.ignoreLocation}={}){if(this.options={location:t,threshold:r,distance:o,includeMatches:s,findAllMatches:i,minMatchCharLength:a,isCaseSensitive:c,ignoreDiacritics:u,ignoreLocation:l},n=c?n:n.toLowerCase(),n=u?dn(n):n,this.pattern=n,this.chunks=[],!this.pattern.length)return;const d=(f,p)=>{this.chunks.push({pattern:f,alphabet:El(f),startIndex:p})},g=this.pattern.length;if(g>ge){let f=0;const p=g%ge,b=g-p;for(;f<b;)d(this.pattern.substr(f,ge),f),f+=ge;if(p){const E=g-ge;d(this.pattern.substr(E),E)}}else d(this.pattern,0)}searchIn(n){const{isCaseSensitive:t,ignoreDiacritics:r,includeMatches:o}=this.options;if(n=t?n:n.toLowerCase(),n=r?dn(n):n,this.pattern===n){let b={isMatch:!0,score:0};return o&&(b.indices=[[0,n.length-1]]),b}const{location:s,distance:i,threshold:a,findAllMatches:c,minMatchCharLength:u,ignoreLocation:l}=this.options;let d=[],g=0,f=!1;this.chunks.forEach(({pattern:b,alphabet:E,startIndex:R})=>{const{isMatch:S,score:z,indices:B}=bl(n,b,E,{location:s+R,distance:i,threshold:a,findAllMatches:c,minMatchCharLength:u,includeMatches:o,ignoreLocation:l});S&&(f=!0),g+=z,S&&B&&(d=[...d,...B])});let p={isMatch:f,score:f?g/this.chunks.length:1};return f&&o&&(p.indices=d),p}}class de{constructor(n){this.pattern=n}static isMultiMatch(n){return xr(n,this.multiRegex)}static isSingleMatch(n){return xr(n,this.singleRegex)}search(){}}function xr(e,n){const t=e.match(n);return t?t[1]:null}class Al extends de{constructor(n){super(n)}static get type(){return"exact"}static get multiRegex(){return/^="(.*)"$/}static get singleRegex(){return/^=(.*)$/}search(n){const t=n===this.pattern;return{isMatch:t,score:t?0:1,indices:[0,this.pattern.length-1]}}}class Nl extends de{constructor(n){super(n)}static get type(){return"inverse-exact"}static get multiRegex(){return/^!"(.*)"$/}static get singleRegex(){return/^!(.*)$/}search(n){const r=n.indexOf(this.pattern)===-1;return{isMatch:r,score:r?0:1,indices:[0,n.length-1]}}}class yl extends de{constructor(n){super(n)}static get type(){return"prefix-exact"}static get multiRegex(){return/^\^"(.*)"$/}static get singleRegex(){return/^\^(.*)$/}search(n){const t=n.startsWith(this.pattern);return{isMatch:t,score:t?0:1,indices:[0,this.pattern.length-1]}}}class Sl extends de{constructor(n){super(n)}static get type(){return"inverse-prefix-exact"}static get multiRegex(){return/^!\^"(.*)"$/}static get singleRegex(){return/^!\^(.*)$/}search(n){const t=!n.startsWith(this.pattern);return{isMatch:t,score:t?0:1,indices:[0,n.length-1]}}}class Il extends de{constructor(n){super(n)}static get type(){return"suffix-exact"}static get multiRegex(){return/^"(.*)"\$$/}static get singleRegex(){return/^(.*)\$$/}search(n){const t=n.endsWith(this.pattern);return{isMatch:t,score:t?0:1,indices:[n.length-this.pattern.length,n.length-1]}}}class _l extends de{constructor(n){super(n)}static get type(){return"inverse-suffix-exact"}static get multiRegex(){return/^!"(.*)"\$$/}static get singleRegex(){return/^!(.*)\$$/}search(n){const t=!n.endsWith(this.pattern);return{isMatch:t,score:t?0:1,indices:[0,n.length-1]}}}class Qs extends de{constructor(n,{location:t=y.location,threshold:r=y.threshold,distance:o=y.distance,includeMatches:s=y.includeMatches,findAllMatches:i=y.findAllMatches,minMatchCharLength:a=y.minMatchCharLength,isCaseSensitive:c=y.isCaseSensitive,ignoreDiacritics:u=y.ignoreDiacritics,ignoreLocation:l=y.ignoreLocation}={}){super(n),this._bitapSearch=new js(n,{location:t,threshold:r,distance:o,includeMatches:s,findAllMatches:i,minMatchCharLength:a,isCaseSensitive:c,ignoreDiacritics:u,ignoreLocation:l})}static get type(){return"fuzzy"}static get multiRegex(){return/^"(.*)"$/}static get singleRegex(){return/^(.*)$/}search(n){return this._bitapSearch.searchIn(n)}}class Hs extends de{constructor(n){super(n)}static get type(){return"include"}static get multiRegex(){return/^'"(.*)"$/}static get singleRegex(){return/^'(.*)$/}search(n){let t=0,r;const o=[],s=this.pattern.length;for(;(r=n.indexOf(this.pattern,t))>-1;)t=r+s,o.push([r,t-1]);const i=!!o.length;return{isMatch:i,score:i?0:1,indices:o}}}const Qn=[Al,Hs,yl,Sl,_l,Il,Nl,Qs],Kr=Qn.length,Zl=/ +(?=(?:[^\"]*\"[^\"]*\")*[^\"]*$)/,Rl="|";function vl(e,n={}){return e.split(Rl).map(t=>{let r=t.trim().split(Zl).filter(s=>s&&!!s.trim()),o=[];for(let s=0,i=r.length;s<i;s+=1){const a=r[s];let c=!1,u=-1;for(;!c&&++u<Kr;){const l=Qn[u];let d=l.isMultiMatch(a);d&&(o.push(new l(d,n)),c=!0)}if(!c)for(u=-1;++u<Kr;){const l=Qn[u];let d=l.isSingleMatch(a);if(d){o.push(new l(d,n));break}}}return o})}const Vl=new Set([Qs.type,Hs.type]);class Cl{constructor(n,{isCaseSensitive:t=y.isCaseSensitive,ignoreDiacritics:r=y.ignoreDiacritics,includeMatches:o=y.includeMatches,minMatchCharLength:s=y.minMatchCharLength,ignoreLocation:i=y.ignoreLocation,findAllMatches:a=y.findAllMatches,location:c=y.location,threshold:u=y.threshold,distance:l=y.distance}={}){this.query=null,this.options={isCaseSensitive:t,ignoreDiacritics:r,includeMatches:o,minMatchCharLength:s,findAllMatches:a,ignoreLocation:i,location:c,threshold:u,distance:l},n=t?n:n.toLowerCase(),n=r?dn(n):n,this.pattern=n,this.query=vl(this.pattern,this.options)}static condition(n,t){return t.useExtendedSearch}searchIn(n){const t=this.query;if(!t)return{isMatch:!1,score:1};const{includeMatches:r,isCaseSensitive:o,ignoreDiacritics:s}=this.options;n=o?n:n.toLowerCase(),n=s?dn(n):n;let i=0,a=[],c=0;for(let u=0,l=t.length;u<l;u+=1){const d=t[u];a.length=0,i=0;for(let g=0,f=d.length;g<f;g+=1){const p=d[g],{isMatch:b,indices:E,score:R}=p.search(n);if(b){if(i+=1,c+=R,r){const S=p.constructor.type;Vl.has(S)?a=[...a,...E]:a.push(E)}}else{c=0,i=0,a.length=0;break}}if(i){let g={isMatch:!0,score:c/i};return r&&(g.indices=a),g}}return{isMatch:!1,score:1}}}const Hn=[];function wl(...e){Hn.push(...e)}function qn(e,n){for(let t=0,r=Hn.length;t<r;t+=1){let o=Hn[t];if(o.condition(e,n))return new o(e,n)}return new js(e,n)}const fn={AND:"$and",OR:"$or"},et={PATH:"$path",PATTERN:"$val"},nt=e=>!!(e[fn.AND]||e[fn.OR]),kl=e=>!!e[et.PATH],Bl=e=>!se(e)&&Ls(e)&&!nt(e),Lr=e=>({[fn.AND]:Object.keys(e).map(n=>({[n]:e[n]}))});function qs(e,n,{auto:t=!0}={}){const r=o=>{let s=Object.keys(o);const i=kl(o);if(!i&&s.length>1&&!nt(o))return r(Lr(o));if(Bl(o)){const c=i?o[et.PATH]:s[0],u=i?o[et.PATTERN]:o[c];if(!ne(u))throw new Error(rl(c));const l={keyId:jn(c),pattern:u};return t&&(l.searcher=qn(u,n)),l}let a={children:[],operator:s[0]};return s.forEach(c=>{const u=o[c];se(u)&&u.forEach(l=>{a.children.push(r(l))})}),a};return nt(e)||(e=Lr(e)),r(e)}function Fl(e,{ignoreFieldNorm:n=y.ignoreFieldNorm}){e.forEach(t=>{let r=1;t.matches.forEach(({key:o,norm:s,score:i})=>{const a=o?o.weight:null;r*=Math.pow(i===0&&a?Number.EPSILON:i,(a||1)*(n?1:s))}),t.score=r})}function Gl(e,n){const t=e.matches;n.matches=[],K(t)&&t.forEach(r=>{if(!K(r.indices)||!r.indices.length)return;const{indices:o,value:s}=r;let i={indices:o,value:s};r.key&&(i.key=r.key.src),r.idx>-1&&(i.refIndex=r.idx),n.matches.push(i)})}function Tl(e,n){n.score=e.score}function Ul(e,n,{includeMatches:t=y.includeMatches,includeScore:r=y.includeScore}={}){const o=[];return t&&o.push(Gl),r&&o.push(Tl),e.map(s=>{const{idx:i}=s,a={item:n[i],refIndex:i};return o.length&&o.forEach(c=>{c(s,a)}),a})}class ke{constructor(n,t={},r){this.options={...y,...t},this.options.useExtendedSearch,this._keyStore=new al(this.options.keys),this.setCollection(n,r)}setCollection(n,t){if(this._docs=n,t&&!(t instanceof wt))throw new Error(tl);this._myIndex=t||Ps(this.options.keys,this._docs,{getFn:this.options.getFn,fieldNormWeight:this.options.fieldNormWeight})}add(n){K(n)&&(this._docs.push(n),this._myIndex.add(n))}remove(n=()=>!1){const t=[];for(let r=0,o=this._docs.length;r<o;r+=1){const s=this._docs[r];n(s,r)&&(this.removeAt(r),r-=1,o-=1,t.push(s))}return t}removeAt(n){this._docs.splice(n,1),this._myIndex.removeAt(n)}getIndex(){return this._myIndex}search(n,{limit:t=-1}={}){const{includeMatches:r,includeScore:o,shouldSort:s,sortFn:i,ignoreFieldNorm:a}=this.options;let c=ne(n)?ne(this._docs[0])?this._searchStringList(n):this._searchObjectList(n):this._searchLogical(n);return Fl(c,{ignoreFieldNorm:a}),s&&c.sort(i),Ks(t)&&t>-1&&(c=c.slice(0,t)),Ul(c,this._docs,{includeMatches:r,includeScore:o})}_searchStringList(n){const t=qn(n,this.options),{records:r}=this._myIndex,o=[];return r.forEach(({v:s,i,n:a})=>{if(!K(s))return;const{isMatch:c,score:u,indices:l}=t.searchIn(s);c&&o.push({item:s,idx:i,matches:[{score:u,value:s,norm:a,indices:l}]})}),o}_searchLogical(n){const t=qs(n,this.options),r=(a,c,u)=>{if(!a.children){const{keyId:d,searcher:g}=a,f=this._findMatches({key:this._keyStore.get(d),value:this._myIndex.getValueForItemAtKeyId(c,d),searcher:g});return f&&f.length?[{idx:u,item:c,matches:f}]:[]}const l=[];for(let d=0,g=a.children.length;d<g;d+=1){const f=a.children[d],p=r(f,c,u);if(p.length)l.push(...p);else if(a.operator===fn.AND)return[]}return l},o=this._myIndex.records,s={},i=[];return o.forEach(({$:a,i:c})=>{if(K(a)){let u=r(t,a,c);u.length&&(s[c]||(s[c]={idx:c,item:a,matches:[]},i.push(s[c])),u.forEach(({matches:l})=>{s[c].matches.push(...l)}))}}),i}_searchObjectList(n){const t=qn(n,this.options),{keys:r,records:o}=this._myIndex,s=[];return o.forEach(({$:i,i:a})=>{if(!K(i))return;let c=[];r.forEach((u,l)=>{c.push(...this._findMatches({key:u,value:i[l],searcher:t}))}),c.length&&s.push({idx:a,item:i,matches:c})}),s}_findMatches({key:n,value:t,searcher:r}){if(!K(t))return[];let o=[];if(se(t))t.forEach(({v:s,i,n:a})=>{if(!K(s))return;const{isMatch:c,score:u,indices:l}=r.searchIn(s);c&&o.push({score:u,key:n,value:s,idx:i,norm:a,indices:l})});else{const{v:s,n:i}=t,{isMatch:a,score:c,indices:u}=r.searchIn(s);a&&o.push({score:c,key:n,value:s,norm:i,indices:u})}return o}}ke.version="7.1.0";ke.createIndex=Ps;ke.parseIndex=gl;ke.config=y;ke.parseQuery=qs;wl(Cl);function np(e,n,t,r){if(!n.trim())return[];const o=.3;return new ke(e,{keys:t,threshold:o,ignoreLocation:!0,includeScore:!0,includeMatches:!0,minMatchCharLength:2}).search(n).map(c=>({item:c.item,score:c.score??1,matches:(c.matches??[]).map(u=>({key:u.key??"",indices:u.indices}))}))}function h(e,n,t){function r(a,c){if(a._zod||Object.defineProperty(a,"_zod",{value:{def:c,constr:i,traits:new Set},enumerable:!1}),a._zod.traits.has(e))return;a._zod.traits.add(e),n(a,c);const u=i.prototype,l=Object.keys(u);for(let d=0;d<l.length;d++){const g=l[d];g in a||(a[g]=u[g].bind(a))}}const o=(t==null?void 0:t.Parent)??Object;class s extends o{}Object.defineProperty(s,"name",{value:e});function i(a){var c;const u=t!=null&&t.Parent?new s:this;r(u,a),(c=u._zod).deferred??(c.deferred=[]);for(const l of u._zod.deferred)l();return u}return Object.defineProperty(i,"init",{value:r}),Object.defineProperty(i,Symbol.hasInstance,{value:a=>{var c,u;return t!=null&&t.Parent&&a instanceof t.Parent?!0:(u=(c=a==null?void 0:a._zod)==null?void 0:c.traits)==null?void 0:u.has(e)}}),Object.defineProperty(i,"name",{value:e}),i}class Ie extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}}class ei extends Error{constructor(n){super(`Encountered unidirectional transform during encode: ${n}`),this.name="ZodEncodeError"}}const ni={};function ue(e){return ni}function ti(e){const n=Object.values(e).filter(r=>typeof r=="number");return Object.entries(e).filter(([r,o])=>n.indexOf(+r)===-1).map(([r,o])=>o)}function tt(e,n){return typeof n=="bigint"?n.toString():n}function Rn(e){return{get value(){{const n=e();return Object.defineProperty(this,"value",{value:n}),n}}}}function kt(e){return e==null}function Bt(e){const n=e.startsWith("^")?1:0,t=e.endsWith("$")?e.length-1:e.length;return e.slice(n,t)}function Yl(e,n){const t=(e.toString().split(".")[1]||"").length,r=n.toString();let o=(r.split(".")[1]||"").length;if(o===0&&/\d?e-\d?/.test(r)){const c=r.match(/\d?e-(\d?)/);c!=null&&c[1]&&(o=Number.parseInt(c[1]))}const s=t>o?t:o,i=Number.parseInt(e.toFixed(s).replace(".","")),a=Number.parseInt(n.toFixed(s).replace(".",""));return i%a/10**s}const Mr=Symbol("evaluating");function _(e,n,t){let r;Object.defineProperty(e,n,{get(){if(r!==Mr)return r===void 0&&(r=Mr,r=t()),r},set(o){Object.defineProperty(e,n,{value:o})},configurable:!0})}function be(e,n,t){Object.defineProperty(e,n,{value:t,writable:!0,enumerable:!0,configurable:!0})}function fe(...e){const n={};for(const t of e){const r=Object.getOwnPropertyDescriptors(t);Object.assign(n,r)}return Object.defineProperties({},n)}function $r(e){return JSON.stringify(e)}function Wl(e){return e.toLowerCase().trim().replace(/[^\w\s-]/g,"").replace(/[\s_-]+/g,"-").replace(/^-+|-+$/g,"")}const ri="captureStackTrace"in Error?Error.captureStackTrace:(...e)=>{};function Je(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}const Ol=Rn(()=>{var e;if(typeof navigator<"u"&&((e=navigator==null?void 0:navigator.userAgent)!=null&&e.includes("Cloudflare")))return!1;try{const n=Function;return new n(""),!0}catch{return!1}});function Ce(e){if(Je(e)===!1)return!1;const n=e.constructor;if(n===void 0||typeof n!="function")return!0;const t=n.prototype;return!(Je(t)===!1||Object.prototype.hasOwnProperty.call(t,"isPrototypeOf")===!1)}function oi(e){return Ce(e)?{...e}:Array.isArray(e)?[...e]:e}const Xl=new Set(["string","number","symbol"]);function we(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function me(e,n,t){const r=new e._zod.constr(n??e._zod.def);return(!n||t!=null&&t.parent)&&(r._zod.parent=e),r}function N(e){const n=e;if(!n)return{};if(typeof n=="string")return{error:()=>n};if((n==null?void 0:n.message)!==void 0){if((n==null?void 0:n.error)!==void 0)throw new Error("Cannot specify both `message` and `error` params");n.error=n.message}return delete n.message,typeof n.error=="string"?{...n,error:()=>n.error}:n}function zl(e){return Object.keys(e).filter(n=>e[n]._zod.optin==="optional"&&e[n]._zod.optout==="optional")}const Jl={safeint:[Number.MIN_SAFE_INTEGER,Number.MAX_SAFE_INTEGER],int32:[-2147483648,2147483647],uint32:[0,4294967295],float32:[-34028234663852886e22,34028234663852886e22],float64:[-Number.MAX_VALUE,Number.MAX_VALUE]};function Dl(e,n){const t=e._zod.def,r=t.checks;if(r&&r.length>0)throw new Error(".pick() cannot be used on object schemas containing refinements");const s=fe(e._zod.def,{get shape(){const i={};for(const a in n){if(!(a in t.shape))throw new Error(`Unrecognized key: "${a}"`);n[a]&&(i[a]=t.shape[a])}return be(this,"shape",i),i},checks:[]});return me(e,s)}function xl(e,n){const t=e._zod.def,r=t.checks;if(r&&r.length>0)throw new Error(".omit() cannot be used on object schemas containing refinements");const s=fe(e._zod.def,{get shape(){const i={...e._zod.def.shape};for(const a in n){if(!(a in t.shape))throw new Error(`Unrecognized key: "${a}"`);n[a]&&delete i[a]}return be(this,"shape",i),i},checks:[]});return me(e,s)}function Kl(e,n){if(!Ce(n))throw new Error("Invalid input to extend: expected a plain object");const t=e._zod.def.checks;if(t&&t.length>0){const s=e._zod.def.shape;for(const i in n)if(Object.getOwnPropertyDescriptor(s,i)!==void 0)throw new Error("Cannot overwrite keys on object schemas containing refinements. Use `.safeExtend()` instead.")}const o=fe(e._zod.def,{get shape(){const s={...e._zod.def.shape,...n};return be(this,"shape",s),s}});return me(e,o)}function Ll(e,n){if(!Ce(n))throw new Error("Invalid input to safeExtend: expected a plain object");const t=fe(e._zod.def,{get shape(){const r={...e._zod.def.shape,...n};return be(this,"shape",r),r}});return me(e,t)}function Ml(e,n){const t=fe(e._zod.def,{get shape(){const r={...e._zod.def.shape,...n._zod.def.shape};return be(this,"shape",r),r},get catchall(){return n._zod.def.catchall},checks:[]});return me(e,t)}function $l(e,n,t){const o=n._zod.def.checks;if(o&&o.length>0)throw new Error(".partial() cannot be used on object schemas containing refinements");const i=fe(n._zod.def,{get shape(){const a=n._zod.def.shape,c={...a};if(t)for(const u in t){if(!(u in a))throw new Error(`Unrecognized key: "${u}"`);t[u]&&(c[u]=e?new e({type:"optional",innerType:a[u]}):a[u])}else for(const u in a)c[u]=e?new e({type:"optional",innerType:a[u]}):a[u];return be(this,"shape",c),c},checks:[]});return me(n,i)}function Pl(e,n,t){const r=fe(n._zod.def,{get shape(){const o=n._zod.def.shape,s={...o};if(t)for(const i in t){if(!(i in s))throw new Error(`Unrecognized key: "${i}"`);t[i]&&(s[i]=new e({type:"nonoptional",innerType:o[i]}))}else for(const i in o)s[i]=new e({type:"nonoptional",innerType:o[i]});return be(this,"shape",s),s}});return me(n,r)}function ye(e,n=0){var t;if(e.aborted===!0)return!0;for(let r=n;r<e.issues.length;r++)if(((t=e.issues[r])==null?void 0:t.continue)!==!0)return!0;return!1}function Se(e,n){return n.map(t=>{var r;return(r=t).path??(r.path=[]),t.path.unshift(e),t})}function en(e){return typeof e=="string"?e:e==null?void 0:e.message}function le(e,n,t){var o,s,i,a,c,u;const r={...e,path:e.path??[]};if(!e.message){const l=en((i=(s=(o=e.inst)==null?void 0:o._zod.def)==null?void 0:s.error)==null?void 0:i.call(s,e))??en((a=n==null?void 0:n.error)==null?void 0:a.call(n,e))??en((c=t.customError)==null?void 0:c.call(t,e))??en((u=t.localeError)==null?void 0:u.call(t,e))??"Invalid input";r.message=l}return delete r.inst,delete r.continue,n!=null&&n.reportInput||delete r.input,r}function Ft(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}function De(...e){const[n,t,r]=e;return typeof n=="string"?{message:n,code:"custom",input:t,inst:r}:{...n}}const si=(e,n)=>{e.name="$ZodError",Object.defineProperty(e,"_zod",{value:e._zod,enumerable:!1}),Object.defineProperty(e,"issues",{value:n,enumerable:!1}),e.message=JSON.stringify(n,tt,2),Object.defineProperty(e,"toString",{value:()=>e.message,enumerable:!1})},ii=h("$ZodError",si),ai=h("$ZodError",si,{Parent:Error});function jl(e,n=t=>t.message){const t={},r=[];for(const o of e.issues)o.path.length>0?(t[o.path[0]]=t[o.path[0]]||[],t[o.path[0]].push(n(o))):r.push(n(o));return{formErrors:r,fieldErrors:t}}function Ql(e,n=t=>t.message){const t={_errors:[]},r=o=>{for(const s of o.issues)if(s.code==="invalid_union"&&s.errors.length)s.errors.map(i=>r({issues:i}));else if(s.code==="invalid_key")r({issues:s.issues});else if(s.code==="invalid_element")r({issues:s.issues});else if(s.path.length===0)t._errors.push(n(s));else{let i=t,a=0;for(;a<s.path.length;){const c=s.path[a];a===s.path.length-1?(i[c]=i[c]||{_errors:[]},i[c]._errors.push(n(s))):i[c]=i[c]||{_errors:[]},i=i[c],a++}}};return r(e),t}const Gt=e=>(n,t,r,o)=>{const s=r?Object.assign(r,{async:!1}):{async:!1},i=n._zod.run({value:t,issues:[]},s);if(i instanceof Promise)throw new Ie;if(i.issues.length){const a=new((o==null?void 0:o.Err)??e)(i.issues.map(c=>le(c,s,ue())));throw ri(a,o==null?void 0:o.callee),a}return i.value},Tt=e=>async(n,t,r,o)=>{const s=r?Object.assign(r,{async:!0}):{async:!0};let i=n._zod.run({value:t,issues:[]},s);if(i instanceof Promise&&(i=await i),i.issues.length){const a=new((o==null?void 0:o.Err)??e)(i.issues.map(c=>le(c,s,ue())));throw ri(a,o==null?void 0:o.callee),a}return i.value},vn=e=>(n,t,r)=>{const o=r?{...r,async:!1}:{async:!1},s=n._zod.run({value:t,issues:[]},o);if(s instanceof Promise)throw new Ie;return s.issues.length?{success:!1,error:new(e??ii)(s.issues.map(i=>le(i,o,ue())))}:{success:!0,data:s.value}},Hl=vn(ai),Vn=e=>async(n,t,r)=>{const o=r?Object.assign(r,{async:!0}):{async:!0};let s=n._zod.run({value:t,issues:[]},o);return s instanceof Promise&&(s=await s),s.issues.length?{success:!1,error:new e(s.issues.map(i=>le(i,o,ue())))}:{success:!0,data:s.value}},ql=Vn(ai),ed=e=>(n,t,r)=>{const o=r?Object.assign(r,{direction:"backward"}):{direction:"backward"};return Gt(e)(n,t,o)},nd=e=>(n,t,r)=>Gt(e)(n,t,r),td=e=>async(n,t,r)=>{const o=r?Object.assign(r,{direction:"backward"}):{direction:"backward"};return Tt(e)(n,t,o)},rd=e=>async(n,t,r)=>Tt(e)(n,t,r),od=e=>(n,t,r)=>{const o=r?Object.assign(r,{direction:"backward"}):{direction:"backward"};return vn(e)(n,t,o)},sd=e=>(n,t,r)=>vn(e)(n,t,r),id=e=>async(n,t,r)=>{const o=r?Object.assign(r,{direction:"backward"}):{direction:"backward"};return Vn(e)(n,t,o)},ad=e=>async(n,t,r)=>Vn(e)(n,t,r),cd=/^[cC][^\s-]{8,}$/,ud=/^[0-9a-z]+$/,ld=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,dd=/^[0-9a-vA-V]{20}$/,fd=/^[A-Za-z0-9]{27}$/,md=/^[a-zA-Z0-9_-]{21}$/,hd=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,gd=/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/,Pr=e=>e?new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`):/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/,pd=/^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,bd="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";function Ed(){return new RegExp(bd,"u")}const Ad=/^(?:(?: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])$/,Nd=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:))$/,yd=/^((25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/([0-9]|[1-2][0-9]|3[0-2])$/,Sd=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,Id=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,ci=/^[A-Za-z0-9_-]*$/,_d=/^\+[1-9]\d{6,14}$/,ui="(?:(?:\\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])))",Zd=new RegExp(`^${ui}$`);function li(e){const n="(?:[01]\\d|2[0-3]):[0-5]\\d";return typeof e.precision=="number"?e.precision===-1?`${n}`:e.precision===0?`${n}:[0-5]\\d`:`${n}:[0-5]\\d\\.\\d{${e.precision}}`:`${n}(?::[0-5]\\d(?:\\.\\d+)?)?`}function Rd(e){return new RegExp(`^${li(e)}$`)}function vd(e){const n=li({precision:e.precision}),t=["Z"];e.local&&t.push(""),e.offset&&t.push("([+-](?:[01]\\d|2[0-3]):[0-5]\\d)");const r=`${n}(?:${t.join("|")})`;return new RegExp(`^${ui}T(?:${r})$`)}const Vd=e=>{const n=e?`[\\s\\S]{${(e==null?void 0:e.minimum)??0},${(e==null?void 0:e.maximum)??""}}`:"[\\s\\S]*";return new RegExp(`^${n}$`)},Cd=/^-?\d+$/,di=/^-?\d+(?:\.\d+)?$/,wd=/^(?:true|false)$/i,kd=/^null$/i,Bd=/^undefined$/i,Fd=/^[^A-Z]*$/,Gd=/^[^a-z]*$/,x=h("$ZodCheck",(e,n)=>{var t;e._zod??(e._zod={}),e._zod.def=n,(t=e._zod).onattach??(t.onattach=[])}),fi={number:"number",bigint:"bigint",object:"date"},mi=h("$ZodCheckLessThan",(e,n)=>{x.init(e,n);const t=fi[typeof n.value];e._zod.onattach.push(r=>{const o=r._zod.bag,s=(n.inclusive?o.maximum:o.exclusiveMaximum)??Number.POSITIVE_INFINITY;n.value<s&&(n.inclusive?o.maximum=n.value:o.exclusiveMaximum=n.value)}),e._zod.check=r=>{(n.inclusive?r.value<=n.value:r.value<n.value)||r.issues.push({origin:t,code:"too_big",maximum:typeof n.value=="object"?n.value.getTime():n.value,input:r.value,inclusive:n.inclusive,inst:e,continue:!n.abort})}}),hi=h("$ZodCheckGreaterThan",(e,n)=>{x.init(e,n);const t=fi[typeof n.value];e._zod.onattach.push(r=>{const o=r._zod.bag,s=(n.inclusive?o.minimum:o.exclusiveMinimum)??Number.NEGATIVE_INFINITY;n.value>s&&(n.inclusive?o.minimum=n.value:o.exclusiveMinimum=n.value)}),e._zod.check=r=>{(n.inclusive?r.value>=n.value:r.value>n.value)||r.issues.push({origin:t,code:"too_small",minimum:typeof n.value=="object"?n.value.getTime():n.value,input:r.value,inclusive:n.inclusive,inst:e,continue:!n.abort})}}),Td=h("$ZodCheckMultipleOf",(e,n)=>{x.init(e,n),e._zod.onattach.push(t=>{var r;(r=t._zod.bag).multipleOf??(r.multipleOf=n.value)}),e._zod.check=t=>{if(typeof t.value!=typeof n.value)throw new Error("Cannot mix number and bigint in multiple_of check.");(typeof t.value=="bigint"?t.value%n.value===BigInt(0):Yl(t.value,n.value)===0)||t.issues.push({origin:typeof t.value,code:"not_multiple_of",divisor:n.value,input:t.value,inst:e,continue:!n.abort})}}),Ud=h("$ZodCheckNumberFormat",(e,n)=>{var i;x.init(e,n),n.format=n.format||"float64";const t=(i=n.format)==null?void 0:i.includes("int"),r=t?"int":"number",[o,s]=Jl[n.format];e._zod.onattach.push(a=>{const c=a._zod.bag;c.format=n.format,c.minimum=o,c.maximum=s,t&&(c.pattern=Cd)}),e._zod.check=a=>{const c=a.value;if(t){if(!Number.isInteger(c)){a.issues.push({expected:r,format:n.format,code:"invalid_type",continue:!1,input:c,inst:e});return}if(!Number.isSafeInteger(c)){c>0?a.issues.push({input:c,code:"too_big",maximum:Number.MAX_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:r,inclusive:!0,continue:!n.abort}):a.issues.push({input:c,code:"too_small",minimum:Number.MIN_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:r,inclusive:!0,continue:!n.abort});return}}c<o&&a.issues.push({origin:"number",input:c,code:"too_small",minimum:o,inclusive:!0,inst:e,continue:!n.abort}),c>s&&a.issues.push({origin:"number",input:c,code:"too_big",maximum:s,inclusive:!0,inst:e,continue:!n.abort})}}),Yd=h("$ZodCheckMaxLength",(e,n)=>{var t;x.init(e,n),(t=e._zod.def).when??(t.when=r=>{const o=r.value;return!kt(o)&&o.length!==void 0}),e._zod.onattach.push(r=>{const o=r._zod.bag.maximum??Number.POSITIVE_INFINITY;n.maximum<o&&(r._zod.bag.maximum=n.maximum)}),e._zod.check=r=>{const o=r.value;if(o.length<=n.maximum)return;const i=Ft(o);r.issues.push({origin:i,code:"too_big",maximum:n.maximum,inclusive:!0,input:o,inst:e,continue:!n.abort})}}),Wd=h("$ZodCheckMinLength",(e,n)=>{var t;x.init(e,n),(t=e._zod.def).when??(t.when=r=>{const o=r.value;return!kt(o)&&o.length!==void 0}),e._zod.onattach.push(r=>{const o=r._zod.bag.minimum??Number.NEGATIVE_INFINITY;n.minimum>o&&(r._zod.bag.minimum=n.minimum)}),e._zod.check=r=>{const o=r.value;if(o.length>=n.minimum)return;const i=Ft(o);r.issues.push({origin:i,code:"too_small",minimum:n.minimum,inclusive:!0,input:o,inst:e,continue:!n.abort})}}),Od=h("$ZodCheckLengthEquals",(e,n)=>{var t;x.init(e,n),(t=e._zod.def).when??(t.when=r=>{const o=r.value;return!kt(o)&&o.length!==void 0}),e._zod.onattach.push(r=>{const o=r._zod.bag;o.minimum=n.length,o.maximum=n.length,o.length=n.length}),e._zod.check=r=>{const o=r.value,s=o.length;if(s===n.length)return;const i=Ft(o),a=s>n.length;r.issues.push({origin:i,...a?{code:"too_big",maximum:n.length}:{code:"too_small",minimum:n.length},inclusive:!0,exact:!0,input:r.value,inst:e,continue:!n.abort})}}),Cn=h("$ZodCheckStringFormat",(e,n)=>{var t,r;x.init(e,n),e._zod.onattach.push(o=>{const s=o._zod.bag;s.format=n.format,n.pattern&&(s.patterns??(s.patterns=new Set),s.patterns.add(n.pattern))}),n.pattern?(t=e._zod).check??(t.check=o=>{n.pattern.lastIndex=0,!n.pattern.test(o.value)&&o.issues.push({origin:"string",code:"invalid_format",format:n.format,input:o.value,...n.pattern?{pattern:n.pattern.toString()}:{},inst:e,continue:!n.abort})}):(r=e._zod).check??(r.check=()=>{})}),Xd=h("$ZodCheckRegex",(e,n)=>{Cn.init(e,n),e._zod.check=t=>{n.pattern.lastIndex=0,!n.pattern.test(t.value)&&t.issues.push({origin:"string",code:"invalid_format",format:"regex",input:t.value,pattern:n.pattern.toString(),inst:e,continue:!n.abort})}}),zd=h("$ZodCheckLowerCase",(e,n)=>{n.pattern??(n.pattern=Fd),Cn.init(e,n)}),Jd=h("$ZodCheckUpperCase",(e,n)=>{n.pattern??(n.pattern=Gd),Cn.init(e,n)}),Dd=h("$ZodCheckIncludes",(e,n)=>{x.init(e,n);const t=we(n.includes),r=new RegExp(typeof n.position=="number"?`^.{${n.position}}${t}`:t);n.pattern=r,e._zod.onattach.push(o=>{const s=o._zod.bag;s.patterns??(s.patterns=new Set),s.patterns.add(r)}),e._zod.check=o=>{o.value.includes(n.includes,n.position)||o.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:n.includes,input:o.value,inst:e,continue:!n.abort})}}),xd=h("$ZodCheckStartsWith",(e,n)=>{x.init(e,n);const t=new RegExp(`^${we(n.prefix)}.*`);n.pattern??(n.pattern=t),e._zod.onattach.push(r=>{const o=r._zod.bag;o.patterns??(o.patterns=new Set),o.patterns.add(t)}),e._zod.check=r=>{r.value.startsWith(n.prefix)||r.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:n.prefix,input:r.value,inst:e,continue:!n.abort})}}),Kd=h("$ZodCheckEndsWith",(e,n)=>{x.init(e,n);const t=new RegExp(`.*${we(n.suffix)}$`);n.pattern??(n.pattern=t),e._zod.onattach.push(r=>{const o=r._zod.bag;o.patterns??(o.patterns=new Set),o.patterns.add(t)}),e._zod.check=r=>{r.value.endsWith(n.suffix)||r.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:n.suffix,input:r.value,inst:e,continue:!n.abort})}}),Ld=h("$ZodCheckOverwrite",(e,n)=>{x.init(e,n),e._zod.check=t=>{t.value=n.tx(t.value)}});class Md{constructor(n=[]){this.content=[],this.indent=0,this&&(this.args=n)}indented(n){this.indent+=1,n(this),this.indent-=1}write(n){if(typeof n=="function"){n(this,{execution:"sync"}),n(this,{execution:"async"});return}const r=n.split(`
3
+ `).filter(i=>i),o=Math.min(...r.map(i=>i.length-i.trimStart().length)),s=r.map(i=>i.slice(o)).map(i=>" ".repeat(this.indent*2)+i);for(const i of s)this.content.push(i)}compile(){const n=Function,t=this==null?void 0:this.args,o=[...((this==null?void 0:this.content)??[""]).map(s=>` ${s}`)];return new n(...t,o.join(`
4
+ `))}}const $d={major:4,minor:3,patch:6},V=h("$ZodType",(e,n)=>{var o;var t;e??(e={}),e._zod.def=n,e._zod.bag=e._zod.bag||{},e._zod.version=$d;const r=[...e._zod.def.checks??[]];e._zod.traits.has("$ZodCheck")&&r.unshift(e);for(const s of r)for(const i of s._zod.onattach)i(e);if(r.length===0)(t=e._zod).deferred??(t.deferred=[]),(o=e._zod.deferred)==null||o.push(()=>{e._zod.run=e._zod.parse});else{const s=(a,c,u)=>{let l=ye(a),d;for(const g of c){if(g._zod.def.when){if(!g._zod.def.when(a))continue}else if(l)continue;const f=a.issues.length,p=g._zod.check(a);if(p instanceof Promise&&(u==null?void 0:u.async)===!1)throw new Ie;if(d||p instanceof Promise)d=(d??Promise.resolve()).then(async()=>{await p,a.issues.length!==f&&(l||(l=ye(a,f)))});else{if(a.issues.length===f)continue;l||(l=ye(a,f))}}return d?d.then(()=>a):a},i=(a,c,u)=>{if(ye(a))return a.aborted=!0,a;const l=s(c,r,u);if(l instanceof Promise){if(u.async===!1)throw new Ie;return l.then(d=>e._zod.parse(d,u))}return e._zod.parse(l,u)};e._zod.run=(a,c)=>{if(c.skipChecks)return e._zod.parse(a,c);if(c.direction==="backward"){const l=e._zod.parse({value:a.value,issues:[]},{...c,skipChecks:!0});return l instanceof Promise?l.then(d=>i(d,a,c)):i(l,a,c)}const u=e._zod.parse(a,c);if(u instanceof Promise){if(c.async===!1)throw new Ie;return u.then(l=>s(l,r,c))}return s(u,r,c)}}_(e,"~standard",()=>({validate:s=>{var i;try{const a=Hl(e,s);return a.success?{value:a.data}:{issues:(i=a.error)==null?void 0:i.issues}}catch{return ql(e,s).then(c=>{var u;return c.success?{value:c.data}:{issues:(u=c.error)==null?void 0:u.issues}})}},vendor:"zod",version:1}))}),Ut=h("$ZodString",(e,n)=>{var t;V.init(e,n),e._zod.pattern=[...((t=e==null?void 0:e._zod.bag)==null?void 0:t.patterns)??[]].pop()??Vd(e._zod.bag),e._zod.parse=(r,o)=>{if(n.coerce)try{r.value=String(r.value)}catch{}return typeof r.value=="string"||r.issues.push({expected:"string",code:"invalid_type",input:r.value,inst:e}),r}}),k=h("$ZodStringFormat",(e,n)=>{Cn.init(e,n),Ut.init(e,n)}),Pd=h("$ZodGUID",(e,n)=>{n.pattern??(n.pattern=gd),k.init(e,n)}),jd=h("$ZodUUID",(e,n)=>{if(n.version){const r={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[n.version];if(r===void 0)throw new Error(`Invalid UUID version: "${n.version}"`);n.pattern??(n.pattern=Pr(r))}else n.pattern??(n.pattern=Pr());k.init(e,n)}),Qd=h("$ZodEmail",(e,n)=>{n.pattern??(n.pattern=pd),k.init(e,n)}),Hd=h("$ZodURL",(e,n)=>{k.init(e,n),e._zod.check=t=>{try{const r=t.value.trim(),o=new URL(r);n.hostname&&(n.hostname.lastIndex=0,n.hostname.test(o.hostname)||t.issues.push({code:"invalid_format",format:"url",note:"Invalid hostname",pattern:n.hostname.source,input:t.value,inst:e,continue:!n.abort})),n.protocol&&(n.protocol.lastIndex=0,n.protocol.test(o.protocol.endsWith(":")?o.protocol.slice(0,-1):o.protocol)||t.issues.push({code:"invalid_format",format:"url",note:"Invalid protocol",pattern:n.protocol.source,input:t.value,inst:e,continue:!n.abort})),n.normalize?t.value=o.href:t.value=r;return}catch{t.issues.push({code:"invalid_format",format:"url",input:t.value,inst:e,continue:!n.abort})}}}),qd=h("$ZodEmoji",(e,n)=>{n.pattern??(n.pattern=Ed()),k.init(e,n)}),ef=h("$ZodNanoID",(e,n)=>{n.pattern??(n.pattern=md),k.init(e,n)}),nf=h("$ZodCUID",(e,n)=>{n.pattern??(n.pattern=cd),k.init(e,n)}),tf=h("$ZodCUID2",(e,n)=>{n.pattern??(n.pattern=ud),k.init(e,n)}),rf=h("$ZodULID",(e,n)=>{n.pattern??(n.pattern=ld),k.init(e,n)}),of=h("$ZodXID",(e,n)=>{n.pattern??(n.pattern=dd),k.init(e,n)}),sf=h("$ZodKSUID",(e,n)=>{n.pattern??(n.pattern=fd),k.init(e,n)}),af=h("$ZodISODateTime",(e,n)=>{n.pattern??(n.pattern=vd(n)),k.init(e,n)}),cf=h("$ZodISODate",(e,n)=>{n.pattern??(n.pattern=Zd),k.init(e,n)}),uf=h("$ZodISOTime",(e,n)=>{n.pattern??(n.pattern=Rd(n)),k.init(e,n)}),lf=h("$ZodISODuration",(e,n)=>{n.pattern??(n.pattern=hd),k.init(e,n)}),df=h("$ZodIPv4",(e,n)=>{n.pattern??(n.pattern=Ad),k.init(e,n),e._zod.bag.format="ipv4"}),ff=h("$ZodIPv6",(e,n)=>{n.pattern??(n.pattern=Nd),k.init(e,n),e._zod.bag.format="ipv6",e._zod.check=t=>{try{new URL(`http://[${t.value}]`)}catch{t.issues.push({code:"invalid_format",format:"ipv6",input:t.value,inst:e,continue:!n.abort})}}}),mf=h("$ZodCIDRv4",(e,n)=>{n.pattern??(n.pattern=yd),k.init(e,n)}),hf=h("$ZodCIDRv6",(e,n)=>{n.pattern??(n.pattern=Sd),k.init(e,n),e._zod.check=t=>{const r=t.value.split("/");try{if(r.length!==2)throw new Error;const[o,s]=r;if(!s)throw new Error;const i=Number(s);if(`${i}`!==s)throw new Error;if(i<0||i>128)throw new Error;new URL(`http://[${o}]`)}catch{t.issues.push({code:"invalid_format",format:"cidrv6",input:t.value,inst:e,continue:!n.abort})}}});function gi(e){if(e==="")return!0;if(e.length%4!==0)return!1;try{return atob(e),!0}catch{return!1}}const gf=h("$ZodBase64",(e,n)=>{n.pattern??(n.pattern=Id),k.init(e,n),e._zod.bag.contentEncoding="base64",e._zod.check=t=>{gi(t.value)||t.issues.push({code:"invalid_format",format:"base64",input:t.value,inst:e,continue:!n.abort})}});function pf(e){if(!ci.test(e))return!1;const n=e.replace(/[-_]/g,r=>r==="-"?"+":"/"),t=n.padEnd(Math.ceil(n.length/4)*4,"=");return gi(t)}const bf=h("$ZodBase64URL",(e,n)=>{n.pattern??(n.pattern=ci),k.init(e,n),e._zod.bag.contentEncoding="base64url",e._zod.check=t=>{pf(t.value)||t.issues.push({code:"invalid_format",format:"base64url",input:t.value,inst:e,continue:!n.abort})}}),Ef=h("$ZodE164",(e,n)=>{n.pattern??(n.pattern=_d),k.init(e,n)});function Af(e,n=null){try{const t=e.split(".");if(t.length!==3)return!1;const[r]=t;if(!r)return!1;const o=JSON.parse(atob(r));return!("typ"in o&&(o==null?void 0:o.typ)!=="JWT"||!o.alg||n&&(!("alg"in o)||o.alg!==n))}catch{return!1}}const Nf=h("$ZodJWT",(e,n)=>{k.init(e,n),e._zod.check=t=>{Af(t.value,n.alg)||t.issues.push({code:"invalid_format",format:"jwt",input:t.value,inst:e,continue:!n.abort})}}),pi=h("$ZodNumber",(e,n)=>{V.init(e,n),e._zod.pattern=e._zod.bag.pattern??di,e._zod.parse=(t,r)=>{if(n.coerce)try{t.value=Number(t.value)}catch{}const o=t.value;if(typeof o=="number"&&!Number.isNaN(o)&&Number.isFinite(o))return t;const s=typeof o=="number"?Number.isNaN(o)?"NaN":Number.isFinite(o)?void 0:"Infinity":void 0;return t.issues.push({expected:"number",code:"invalid_type",input:o,inst:e,...s?{received:s}:{}}),t}}),yf=h("$ZodNumberFormat",(e,n)=>{Ud.init(e,n),pi.init(e,n)}),Sf=h("$ZodBoolean",(e,n)=>{V.init(e,n),e._zod.pattern=wd,e._zod.parse=(t,r)=>{if(n.coerce)try{t.value=!!t.value}catch{}const o=t.value;return typeof o=="boolean"||t.issues.push({expected:"boolean",code:"invalid_type",input:o,inst:e}),t}}),If=h("$ZodUndefined",(e,n)=>{V.init(e,n),e._zod.pattern=Bd,e._zod.values=new Set([void 0]),e._zod.optin="optional",e._zod.optout="optional",e._zod.parse=(t,r)=>{const o=t.value;return typeof o>"u"||t.issues.push({expected:"undefined",code:"invalid_type",input:o,inst:e}),t}}),_f=h("$ZodNull",(e,n)=>{V.init(e,n),e._zod.pattern=kd,e._zod.values=new Set([null]),e._zod.parse=(t,r)=>{const o=t.value;return o===null||t.issues.push({expected:"null",code:"invalid_type",input:o,inst:e}),t}}),Zf=h("$ZodUnknown",(e,n)=>{V.init(e,n),e._zod.parse=t=>t}),Rf=h("$ZodNever",(e,n)=>{V.init(e,n),e._zod.parse=(t,r)=>(t.issues.push({expected:"never",code:"invalid_type",input:t.value,inst:e}),t)});function jr(e,n,t){e.issues.length&&n.issues.push(...Se(t,e.issues)),n.value[t]=e.value}const vf=h("$ZodArray",(e,n)=>{V.init(e,n),e._zod.parse=(t,r)=>{const o=t.value;if(!Array.isArray(o))return t.issues.push({expected:"array",code:"invalid_type",input:o,inst:e}),t;t.value=Array(o.length);const s=[];for(let i=0;i<o.length;i++){const a=o[i],c=n.element._zod.run({value:a,issues:[]},r);c instanceof Promise?s.push(c.then(u=>jr(u,t,i))):jr(c,t,i)}return s.length?Promise.all(s).then(()=>t):t}});function mn(e,n,t,r,o){if(e.issues.length){if(o&&!(t in r))return;n.issues.push(...Se(t,e.issues))}e.value===void 0?t in r&&(n.value[t]=void 0):n.value[t]=e.value}function bi(e){var r,o,s,i;const n=Object.keys(e.shape);for(const a of n)if(!((i=(s=(o=(r=e.shape)==null?void 0:r[a])==null?void 0:o._zod)==null?void 0:s.traits)!=null&&i.has("$ZodType")))throw new Error(`Invalid element at key "${a}": expected a Zod schema`);const t=zl(e.shape);return{...e,keys:n,keySet:new Set(n),numKeys:n.length,optionalKeys:new Set(t)}}function Ei(e,n,t,r,o,s){const i=[],a=o.keySet,c=o.catchall._zod,u=c.def.type,l=c.optout==="optional";for(const d in n){if(a.has(d))continue;if(u==="never"){i.push(d);continue}const g=c.run({value:n[d],issues:[]},r);g instanceof Promise?e.push(g.then(f=>mn(f,t,d,n,l))):mn(g,t,d,n,l)}return i.length&&t.issues.push({code:"unrecognized_keys",keys:i,input:n,inst:s}),e.length?Promise.all(e).then(()=>t):t}const Vf=h("$ZodObject",(e,n)=>{V.init(e,n);const t=Object.getOwnPropertyDescriptor(n,"shape");if(!(t!=null&&t.get)){const a=n.shape;Object.defineProperty(n,"shape",{get:()=>{const c={...a};return Object.defineProperty(n,"shape",{value:c}),c}})}const r=Rn(()=>bi(n));_(e._zod,"propValues",()=>{const a=n.shape,c={};for(const u in a){const l=a[u]._zod;if(l.values){c[u]??(c[u]=new Set);for(const d of l.values)c[u].add(d)}}return c});const o=Je,s=n.catchall;let i;e._zod.parse=(a,c)=>{i??(i=r.value);const u=a.value;if(!o(u))return a.issues.push({expected:"object",code:"invalid_type",input:u,inst:e}),a;a.value={};const l=[],d=i.shape;for(const g of i.keys){const f=d[g],p=f._zod.optout==="optional",b=f._zod.run({value:u[g],issues:[]},c);b instanceof Promise?l.push(b.then(E=>mn(E,a,g,u,p))):mn(b,a,g,u,p)}return s?Ei(l,u,a,c,r.value,e):l.length?Promise.all(l).then(()=>a):a}}),Cf=h("$ZodObjectJIT",(e,n)=>{Vf.init(e,n);const t=e._zod.parse,r=Rn(()=>bi(n)),o=g=>{var z;const f=new Md(["shape","payload","ctx"]),p=r.value,b=B=>{const W=$r(B);return`shape[${W}]._zod.run({ value: input[${W}], issues: [] }, ctx)`};f.write("const input = payload.value;");const E=Object.create(null);let R=0;for(const B of p.keys)E[B]=`key_${R++}`;f.write("const newResult = {};");for(const B of p.keys){const W=E[B],O=$r(B),U=g[B],J=((z=U==null?void 0:U._zod)==null?void 0:z.optout)==="optional";f.write(`const ${W} = ${b(B)};`),J?f.write(`
5
+ if (${W}.issues.length) {
6
+ if (${O} in input) {
7
+ payload.issues = payload.issues.concat(${W}.issues.map(iss => ({
8
+ ...iss,
9
+ path: iss.path ? [${O}, ...iss.path] : [${O}]
10
+ })));
11
+ }
12
+ }
13
+
14
+ if (${W}.value === undefined) {
15
+ if (${O} in input) {
16
+ newResult[${O}] = undefined;
17
+ }
18
+ } else {
19
+ newResult[${O}] = ${W}.value;
20
+ }
21
+
22
+ `):f.write(`
23
+ if (${W}.issues.length) {
24
+ payload.issues = payload.issues.concat(${W}.issues.map(iss => ({
25
+ ...iss,
26
+ path: iss.path ? [${O}, ...iss.path] : [${O}]
27
+ })));
28
+ }
29
+
30
+ if (${W}.value === undefined) {
31
+ if (${O} in input) {
32
+ newResult[${O}] = undefined;
33
+ }
34
+ } else {
35
+ newResult[${O}] = ${W}.value;
36
+ }
37
+
38
+ `)}f.write("payload.value = newResult;"),f.write("return payload;");const S=f.compile();return(B,W)=>S(g,B,W)};let s;const i=Je,a=!ni.jitless,u=a&&Ol.value,l=n.catchall;let d;e._zod.parse=(g,f)=>{d??(d=r.value);const p=g.value;return i(p)?a&&u&&(f==null?void 0:f.async)===!1&&f.jitless!==!0?(s||(s=o(n.shape)),g=s(g,f),l?Ei([],p,g,f,d,e):g):t(g,f):(g.issues.push({expected:"object",code:"invalid_type",input:p,inst:e}),g)}});function Qr(e,n,t,r){for(const s of e)if(s.issues.length===0)return n.value=s.value,n;const o=e.filter(s=>!ye(s));return o.length===1?(n.value=o[0].value,o[0]):(n.issues.push({code:"invalid_union",input:n.value,inst:t,errors:e.map(s=>s.issues.map(i=>le(i,r,ue())))}),n)}const Ai=h("$ZodUnion",(e,n)=>{V.init(e,n),_(e._zod,"optin",()=>n.options.some(o=>o._zod.optin==="optional")?"optional":void 0),_(e._zod,"optout",()=>n.options.some(o=>o._zod.optout==="optional")?"optional":void 0),_(e._zod,"values",()=>{if(n.options.every(o=>o._zod.values))return new Set(n.options.flatMap(o=>Array.from(o._zod.values)))}),_(e._zod,"pattern",()=>{if(n.options.every(o=>o._zod.pattern)){const o=n.options.map(s=>s._zod.pattern);return new RegExp(`^(${o.map(s=>Bt(s.source)).join("|")})$`)}});const t=n.options.length===1,r=n.options[0]._zod.run;e._zod.parse=(o,s)=>{if(t)return r(o,s);let i=!1;const a=[];for(const c of n.options){const u=c._zod.run({value:o.value,issues:[]},s);if(u instanceof Promise)a.push(u),i=!0;else{if(u.issues.length===0)return u;a.push(u)}}return i?Promise.all(a).then(c=>Qr(c,o,e,s)):Qr(a,o,e,s)}}),wf=h("$ZodDiscriminatedUnion",(e,n)=>{n.inclusive=!1,Ai.init(e,n);const t=e._zod.parse;_(e._zod,"propValues",()=>{const o={};for(const s of n.options){const i=s._zod.propValues;if(!i||Object.keys(i).length===0)throw new Error(`Invalid discriminated union option at index "${n.options.indexOf(s)}"`);for(const[a,c]of Object.entries(i)){o[a]||(o[a]=new Set);for(const u of c)o[a].add(u)}}return o});const r=Rn(()=>{var i;const o=n.options,s=new Map;for(const a of o){const c=(i=a._zod.propValues)==null?void 0:i[n.discriminator];if(!c||c.size===0)throw new Error(`Invalid discriminated union option at index "${n.options.indexOf(a)}"`);for(const u of c){if(s.has(u))throw new Error(`Duplicate discriminator value "${String(u)}"`);s.set(u,a)}}return s});e._zod.parse=(o,s)=>{const i=o.value;if(!Je(i))return o.issues.push({code:"invalid_type",expected:"object",input:i,inst:e}),o;const a=r.value.get(i==null?void 0:i[n.discriminator]);return a?a._zod.run(o,s):n.unionFallback?t(o,s):(o.issues.push({code:"invalid_union",errors:[],note:"No matching discriminator",discriminator:n.discriminator,input:i,path:[n.discriminator],inst:e}),o)}}),kf=h("$ZodIntersection",(e,n)=>{V.init(e,n),e._zod.parse=(t,r)=>{const o=t.value,s=n.left._zod.run({value:o,issues:[]},r),i=n.right._zod.run({value:o,issues:[]},r);return s instanceof Promise||i instanceof Promise?Promise.all([s,i]).then(([c,u])=>Hr(t,c,u)):Hr(t,s,i)}});function rt(e,n){if(e===n)return{valid:!0,data:e};if(e instanceof Date&&n instanceof Date&&+e==+n)return{valid:!0,data:e};if(Ce(e)&&Ce(n)){const t=Object.keys(n),r=Object.keys(e).filter(s=>t.indexOf(s)!==-1),o={...e,...n};for(const s of r){const i=rt(e[s],n[s]);if(!i.valid)return{valid:!1,mergeErrorPath:[s,...i.mergeErrorPath]};o[s]=i.data}return{valid:!0,data:o}}if(Array.isArray(e)&&Array.isArray(n)){if(e.length!==n.length)return{valid:!1,mergeErrorPath:[]};const t=[];for(let r=0;r<e.length;r++){const o=e[r],s=n[r],i=rt(o,s);if(!i.valid)return{valid:!1,mergeErrorPath:[r,...i.mergeErrorPath]};t.push(i.data)}return{valid:!0,data:t}}return{valid:!1,mergeErrorPath:[]}}function Hr(e,n,t){const r=new Map;let o;for(const a of n.issues)if(a.code==="unrecognized_keys"){o??(o=a);for(const c of a.keys)r.has(c)||r.set(c,{}),r.get(c).l=!0}else e.issues.push(a);for(const a of t.issues)if(a.code==="unrecognized_keys")for(const c of a.keys)r.has(c)||r.set(c,{}),r.get(c).r=!0;else e.issues.push(a);const s=[...r].filter(([,a])=>a.l&&a.r).map(([a])=>a);if(s.length&&o&&e.issues.push({...o,keys:s}),ye(e))return e;const i=rt(n.value,t.value);if(!i.valid)throw new Error(`Unmergable intersection. Error path: ${JSON.stringify(i.mergeErrorPath)}`);return e.value=i.data,e}const Bf=h("$ZodRecord",(e,n)=>{V.init(e,n),e._zod.parse=(t,r)=>{const o=t.value;if(!Ce(o))return t.issues.push({expected:"record",code:"invalid_type",input:o,inst:e}),t;const s=[],i=n.keyType._zod.values;if(i){t.value={};const a=new Set;for(const u of i)if(typeof u=="string"||typeof u=="number"||typeof u=="symbol"){a.add(typeof u=="number"?u.toString():u);const l=n.valueType._zod.run({value:o[u],issues:[]},r);l instanceof Promise?s.push(l.then(d=>{d.issues.length&&t.issues.push(...Se(u,d.issues)),t.value[u]=d.value})):(l.issues.length&&t.issues.push(...Se(u,l.issues)),t.value[u]=l.value)}let c;for(const u in o)a.has(u)||(c=c??[],c.push(u));c&&c.length>0&&t.issues.push({code:"unrecognized_keys",input:o,inst:e,keys:c})}else{t.value={};for(const a of Reflect.ownKeys(o)){if(a==="__proto__")continue;let c=n.keyType._zod.run({value:a,issues:[]},r);if(c instanceof Promise)throw new Error("Async schemas not supported in object keys currently");if(typeof a=="string"&&di.test(a)&&c.issues.length){const d=n.keyType._zod.run({value:Number(a),issues:[]},r);if(d instanceof Promise)throw new Error("Async schemas not supported in object keys currently");d.issues.length===0&&(c=d)}if(c.issues.length){n.mode==="loose"?t.value[a]=o[a]:t.issues.push({code:"invalid_key",origin:"record",issues:c.issues.map(d=>le(d,r,ue())),input:a,path:[a],inst:e});continue}const l=n.valueType._zod.run({value:o[a],issues:[]},r);l instanceof Promise?s.push(l.then(d=>{d.issues.length&&t.issues.push(...Se(a,d.issues)),t.value[c.value]=d.value})):(l.issues.length&&t.issues.push(...Se(a,l.issues)),t.value[c.value]=l.value)}}return s.length?Promise.all(s).then(()=>t):t}}),Ff=h("$ZodEnum",(e,n)=>{V.init(e,n);const t=ti(n.entries),r=new Set(t);e._zod.values=r,e._zod.pattern=new RegExp(`^(${t.filter(o=>Xl.has(typeof o)).map(o=>typeof o=="string"?we(o):o.toString()).join("|")})$`),e._zod.parse=(o,s)=>{const i=o.value;return r.has(i)||o.issues.push({code:"invalid_value",values:t,input:i,inst:e}),o}}),Gf=h("$ZodLiteral",(e,n)=>{if(V.init(e,n),n.values.length===0)throw new Error("Cannot create literal schema with no valid values");const t=new Set(n.values);e._zod.values=t,e._zod.pattern=new RegExp(`^(${n.values.map(r=>typeof r=="string"?we(r):r?we(r.toString()):String(r)).join("|")})$`),e._zod.parse=(r,o)=>{const s=r.value;return t.has(s)||r.issues.push({code:"invalid_value",values:n.values,input:s,inst:e}),r}}),Tf=h("$ZodTransform",(e,n)=>{V.init(e,n),e._zod.parse=(t,r)=>{if(r.direction==="backward")throw new ei(e.constructor.name);const o=n.transform(t.value,t);if(r.async)return(o instanceof Promise?o:Promise.resolve(o)).then(i=>(t.value=i,t));if(o instanceof Promise)throw new Ie;return t.value=o,t}});function qr(e,n){return e.issues.length&&n===void 0?{issues:[],value:void 0}:e}const Ni=h("$ZodOptional",(e,n)=>{V.init(e,n),e._zod.optin="optional",e._zod.optout="optional",_(e._zod,"values",()=>n.innerType._zod.values?new Set([...n.innerType._zod.values,void 0]):void 0),_(e._zod,"pattern",()=>{const t=n.innerType._zod.pattern;return t?new RegExp(`^(${Bt(t.source)})?$`):void 0}),e._zod.parse=(t,r)=>{if(n.innerType._zod.optin==="optional"){const o=n.innerType._zod.run(t,r);return o instanceof Promise?o.then(s=>qr(s,t.value)):qr(o,t.value)}return t.value===void 0?t:n.innerType._zod.run(t,r)}}),Uf=h("$ZodExactOptional",(e,n)=>{Ni.init(e,n),_(e._zod,"values",()=>n.innerType._zod.values),_(e._zod,"pattern",()=>n.innerType._zod.pattern),e._zod.parse=(t,r)=>n.innerType._zod.run(t,r)}),Yf=h("$ZodNullable",(e,n)=>{V.init(e,n),_(e._zod,"optin",()=>n.innerType._zod.optin),_(e._zod,"optout",()=>n.innerType._zod.optout),_(e._zod,"pattern",()=>{const t=n.innerType._zod.pattern;return t?new RegExp(`^(${Bt(t.source)}|null)$`):void 0}),_(e._zod,"values",()=>n.innerType._zod.values?new Set([...n.innerType._zod.values,null]):void 0),e._zod.parse=(t,r)=>t.value===null?t:n.innerType._zod.run(t,r)}),Wf=h("$ZodDefault",(e,n)=>{V.init(e,n),e._zod.optin="optional",_(e._zod,"values",()=>n.innerType._zod.values),e._zod.parse=(t,r)=>{if(r.direction==="backward")return n.innerType._zod.run(t,r);if(t.value===void 0)return t.value=n.defaultValue,t;const o=n.innerType._zod.run(t,r);return o instanceof Promise?o.then(s=>eo(s,n)):eo(o,n)}});function eo(e,n){return e.value===void 0&&(e.value=n.defaultValue),e}const Of=h("$ZodPrefault",(e,n)=>{V.init(e,n),e._zod.optin="optional",_(e._zod,"values",()=>n.innerType._zod.values),e._zod.parse=(t,r)=>(r.direction==="backward"||t.value===void 0&&(t.value=n.defaultValue),n.innerType._zod.run(t,r))}),Xf=h("$ZodNonOptional",(e,n)=>{V.init(e,n),_(e._zod,"values",()=>{const t=n.innerType._zod.values;return t?new Set([...t].filter(r=>r!==void 0)):void 0}),e._zod.parse=(t,r)=>{const o=n.innerType._zod.run(t,r);return o instanceof Promise?o.then(s=>no(s,e)):no(o,e)}});function no(e,n){return!e.issues.length&&e.value===void 0&&e.issues.push({code:"invalid_type",expected:"nonoptional",input:e.value,inst:n}),e}const zf=h("$ZodCatch",(e,n)=>{V.init(e,n),_(e._zod,"optin",()=>n.innerType._zod.optin),_(e._zod,"optout",()=>n.innerType._zod.optout),_(e._zod,"values",()=>n.innerType._zod.values),e._zod.parse=(t,r)=>{if(r.direction==="backward")return n.innerType._zod.run(t,r);const o=n.innerType._zod.run(t,r);return o instanceof Promise?o.then(s=>(t.value=s.value,s.issues.length&&(t.value=n.catchValue({...t,error:{issues:s.issues.map(i=>le(i,r,ue()))},input:t.value}),t.issues=[]),t)):(t.value=o.value,o.issues.length&&(t.value=n.catchValue({...t,error:{issues:o.issues.map(s=>le(s,r,ue()))},input:t.value}),t.issues=[]),t)}}),Jf=h("$ZodPipe",(e,n)=>{V.init(e,n),_(e._zod,"values",()=>n.in._zod.values),_(e._zod,"optin",()=>n.in._zod.optin),_(e._zod,"optout",()=>n.out._zod.optout),_(e._zod,"propValues",()=>n.in._zod.propValues),e._zod.parse=(t,r)=>{if(r.direction==="backward"){const s=n.out._zod.run(t,r);return s instanceof Promise?s.then(i=>nn(i,n.in,r)):nn(s,n.in,r)}const o=n.in._zod.run(t,r);return o instanceof Promise?o.then(s=>nn(s,n.out,r)):nn(o,n.out,r)}});function nn(e,n,t){return e.issues.length?(e.aborted=!0,e):n._zod.run({value:e.value,issues:e.issues},t)}const Df=h("$ZodReadonly",(e,n)=>{V.init(e,n),_(e._zod,"propValues",()=>n.innerType._zod.propValues),_(e._zod,"values",()=>n.innerType._zod.values),_(e._zod,"optin",()=>{var t,r;return(r=(t=n.innerType)==null?void 0:t._zod)==null?void 0:r.optin}),_(e._zod,"optout",()=>{var t,r;return(r=(t=n.innerType)==null?void 0:t._zod)==null?void 0:r.optout}),e._zod.parse=(t,r)=>{if(r.direction==="backward")return n.innerType._zod.run(t,r);const o=n.innerType._zod.run(t,r);return o instanceof Promise?o.then(to):to(o)}});function to(e){return e.value=Object.freeze(e.value),e}const xf=h("$ZodCustom",(e,n)=>{x.init(e,n),V.init(e,n),e._zod.parse=(t,r)=>t,e._zod.check=t=>{const r=t.value,o=n.fn(r);if(o instanceof Promise)return o.then(s=>ro(s,t,r,e));ro(o,t,r,e)}});function ro(e,n,t,r){if(!e){const o={code:"custom",input:t,inst:r,path:[...r._zod.def.path??[]],continue:!r._zod.def.abort};r._zod.def.params&&(o.params=r._zod.def.params),n.issues.push(De(o))}}var oo;class Kf{constructor(){this._map=new WeakMap,this._idmap=new Map}add(n,...t){const r=t[0];return this._map.set(n,r),r&&typeof r=="object"&&"id"in r&&this._idmap.set(r.id,n),this}clear(){return this._map=new WeakMap,this._idmap=new Map,this}remove(n){const t=this._map.get(n);return t&&typeof t=="object"&&"id"in t&&this._idmap.delete(t.id),this._map.delete(n),this}get(n){const t=n._zod.parent;if(t){const r={...this.get(t)??{}};delete r.id;const o={...r,...this._map.get(n)};return Object.keys(o).length?o:void 0}return this._map.get(n)}has(n){return this._map.has(n)}}function Lf(){return new Kf}(oo=globalThis).__zod_globalRegistry??(oo.__zod_globalRegistry=Lf());const Ge=globalThis.__zod_globalRegistry;function Mf(e,n){return new e({type:"string",...N(n)})}function $f(e,n){return new e({type:"string",format:"email",check:"string_format",abort:!1,...N(n)})}function so(e,n){return new e({type:"string",format:"guid",check:"string_format",abort:!1,...N(n)})}function Pf(e,n){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,...N(n)})}function jf(e,n){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v4",...N(n)})}function Qf(e,n){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v6",...N(n)})}function Hf(e,n){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v7",...N(n)})}function qf(e,n){return new e({type:"string",format:"url",check:"string_format",abort:!1,...N(n)})}function em(e,n){return new e({type:"string",format:"emoji",check:"string_format",abort:!1,...N(n)})}function nm(e,n){return new e({type:"string",format:"nanoid",check:"string_format",abort:!1,...N(n)})}function tm(e,n){return new e({type:"string",format:"cuid",check:"string_format",abort:!1,...N(n)})}function rm(e,n){return new e({type:"string",format:"cuid2",check:"string_format",abort:!1,...N(n)})}function om(e,n){return new e({type:"string",format:"ulid",check:"string_format",abort:!1,...N(n)})}function sm(e,n){return new e({type:"string",format:"xid",check:"string_format",abort:!1,...N(n)})}function im(e,n){return new e({type:"string",format:"ksuid",check:"string_format",abort:!1,...N(n)})}function am(e,n){return new e({type:"string",format:"ipv4",check:"string_format",abort:!1,...N(n)})}function cm(e,n){return new e({type:"string",format:"ipv6",check:"string_format",abort:!1,...N(n)})}function um(e,n){return new e({type:"string",format:"cidrv4",check:"string_format",abort:!1,...N(n)})}function lm(e,n){return new e({type:"string",format:"cidrv6",check:"string_format",abort:!1,...N(n)})}function dm(e,n){return new e({type:"string",format:"base64",check:"string_format",abort:!1,...N(n)})}function fm(e,n){return new e({type:"string",format:"base64url",check:"string_format",abort:!1,...N(n)})}function mm(e,n){return new e({type:"string",format:"e164",check:"string_format",abort:!1,...N(n)})}function hm(e,n){return new e({type:"string",format:"jwt",check:"string_format",abort:!1,...N(n)})}function gm(e,n){return new e({type:"string",format:"datetime",check:"string_format",offset:!1,local:!1,precision:null,...N(n)})}function pm(e,n){return new e({type:"string",format:"date",check:"string_format",...N(n)})}function bm(e,n){return new e({type:"string",format:"time",check:"string_format",precision:null,...N(n)})}function Em(e,n){return new e({type:"string",format:"duration",check:"string_format",...N(n)})}function Am(e,n){return new e({type:"number",checks:[],...N(n)})}function Nm(e,n){return new e({type:"number",check:"number_format",abort:!1,format:"safeint",...N(n)})}function ym(e,n){return new e({type:"boolean",...N(n)})}function Sm(e,n){return new e({type:"undefined",...N(n)})}function Im(e,n){return new e({type:"null",...N(n)})}function _m(e){return new e({type:"unknown"})}function Zm(e,n){return new e({type:"never",...N(n)})}function io(e,n){return new mi({check:"less_than",...N(n),value:e,inclusive:!1})}function Xn(e,n){return new mi({check:"less_than",...N(n),value:e,inclusive:!0})}function ao(e,n){return new hi({check:"greater_than",...N(n),value:e,inclusive:!1})}function zn(e,n){return new hi({check:"greater_than",...N(n),value:e,inclusive:!0})}function co(e,n){return new Td({check:"multiple_of",...N(n),value:e})}function yi(e,n){return new Yd({check:"max_length",...N(n),maximum:e})}function hn(e,n){return new Wd({check:"min_length",...N(n),minimum:e})}function Si(e,n){return new Od({check:"length_equals",...N(n),length:e})}function Rm(e,n){return new Xd({check:"string_format",format:"regex",...N(n),pattern:e})}function vm(e){return new zd({check:"string_format",format:"lowercase",...N(e)})}function Vm(e){return new Jd({check:"string_format",format:"uppercase",...N(e)})}function Cm(e,n){return new Dd({check:"string_format",format:"includes",...N(n),includes:e})}function wm(e,n){return new xd({check:"string_format",format:"starts_with",...N(n),prefix:e})}function km(e,n){return new Kd({check:"string_format",format:"ends_with",...N(n),suffix:e})}function Be(e){return new Ld({check:"overwrite",tx:e})}function Bm(e){return Be(n=>n.normalize(e))}function Fm(){return Be(e=>e.trim())}function Gm(){return Be(e=>e.toLowerCase())}function Tm(){return Be(e=>e.toUpperCase())}function Um(){return Be(e=>Wl(e))}function Ym(e,n,t){return new e({type:"array",element:n,...N(t)})}function Wm(e,n,t){const r=N(t);return r.abort??(r.abort=!0),new e({type:"custom",check:"custom",fn:n,...r})}function Om(e,n,t){return new e({type:"custom",check:"custom",fn:n,...N(t)})}function Xm(e){const n=zm(t=>(t.addIssue=r=>{if(typeof r=="string")t.issues.push(De(r,t.value,n._zod.def));else{const o=r;o.fatal&&(o.continue=!1),o.code??(o.code="custom"),o.input??(o.input=t.value),o.inst??(o.inst=n),o.continue??(o.continue=!n._zod.def.abort),t.issues.push(De(o))}},e(t.value,t)));return n}function zm(e,n){const t=new x({check:"custom",...N(n)});return t._zod.check=e,t}function gn(e){let n=(e==null?void 0:e.target)??"draft-2020-12";return n==="draft-4"&&(n="draft-04"),n==="draft-7"&&(n="draft-07"),{processors:e.processors??{},metadataRegistry:(e==null?void 0:e.metadata)??Ge,target:n,unrepresentable:(e==null?void 0:e.unrepresentable)??"throw",override:(e==null?void 0:e.override)??(()=>{}),io:(e==null?void 0:e.io)??"output",counter:0,seen:new Map,cycles:(e==null?void 0:e.cycles)??"ref",reused:(e==null?void 0:e.reused)??"inline",external:(e==null?void 0:e.external)??void 0}}function v(e,n,t={path:[],schemaPath:[]}){var l,d;var r;const o=e._zod.def,s=n.seen.get(e);if(s)return s.count++,t.schemaPath.includes(e)&&(s.cycle=t.path),s.schema;const i={schema:{},count:1,cycle:void 0,path:t.path};n.seen.set(e,i);const a=(d=(l=e._zod).toJSONSchema)==null?void 0:d.call(l);if(a)i.schema=a;else{const g={...t,schemaPath:[...t.schemaPath,e],path:t.path};if(e._zod.processJSONSchema)e._zod.processJSONSchema(n,i.schema,g);else{const p=i.schema,b=n.processors[o.type];if(!b)throw new Error(`[toJSONSchema]: Non-representable type encountered: ${o.type}`);b(e,n,p,g)}const f=e._zod.parent;f&&(i.ref||(i.ref=f),v(f,n,g),n.seen.get(f).isParent=!0)}const c=n.metadataRegistry.get(e);return c&&Object.assign(i.schema,c),n.io==="input"&&D(e)&&(delete i.schema.examples,delete i.schema.default),n.io==="input"&&i.schema._prefault&&((r=i.schema).default??(r.default=i.schema._prefault)),delete i.schema._prefault,n.seen.get(e).schema}function pn(e,n){var i,a,c,u;const t=e.seen.get(n);if(!t)throw new Error("Unprocessed schema. This is a bug in Zod.");const r=new Map;for(const l of e.seen.entries()){const d=(i=e.metadataRegistry.get(l[0]))==null?void 0:i.id;if(d){const g=r.get(d);if(g&&g!==l[0])throw new Error(`Duplicate schema id "${d}" detected during JSON Schema conversion. Two different schemas cannot share the same id when converted together.`);r.set(d,l[0])}}const o=l=>{var b;const d=e.target==="draft-2020-12"?"$defs":"definitions";if(e.external){const E=(b=e.external.registry.get(l[0]))==null?void 0:b.id,R=e.external.uri??(z=>z);if(E)return{ref:R(E)};const S=l[1].defId??l[1].schema.id??`schema${e.counter++}`;return l[1].defId=S,{defId:S,ref:`${R("__shared")}#/${d}/${S}`}}if(l[1]===t)return{ref:"#"};const f=`#/${d}/`,p=l[1].schema.id??`__schema${e.counter++}`;return{defId:p,ref:f+p}},s=l=>{if(l[1].schema.$ref)return;const d=l[1],{ref:g,defId:f}=o(l);d.def={...d.schema},f&&(d.defId=f);const p=d.schema;for(const b in p)delete p[b];p.$ref=g};if(e.cycles==="throw")for(const l of e.seen.entries()){const d=l[1];if(d.cycle)throw new Error(`Cycle detected: #/${(a=d.cycle)==null?void 0:a.join("/")}/<root>
39
+
40
+ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`)}for(const l of e.seen.entries()){const d=l[1];if(n===l[0]){s(l);continue}if(e.external){const f=(c=e.external.registry.get(l[0]))==null?void 0:c.id;if(n!==l[0]&&f){s(l);continue}}if((u=e.metadataRegistry.get(l[0]))==null?void 0:u.id){s(l);continue}if(d.cycle){s(l);continue}if(d.count>1&&e.reused==="ref"){s(l);continue}}}function bn(e,n){var i,a,c;const t=e.seen.get(n);if(!t)throw new Error("Unprocessed schema. This is a bug in Zod.");const r=u=>{const l=e.seen.get(u);if(l.ref===null)return;const d=l.def??l.schema,g={...d},f=l.ref;if(l.ref=null,f){r(f);const b=e.seen.get(f),E=b.schema;if(E.$ref&&(e.target==="draft-07"||e.target==="draft-04"||e.target==="openapi-3.0")?(d.allOf=d.allOf??[],d.allOf.push(E)):Object.assign(d,E),Object.assign(d,g),u._zod.parent===f)for(const S in d)S==="$ref"||S==="allOf"||S in g||delete d[S];if(E.$ref&&b.def)for(const S in d)S==="$ref"||S==="allOf"||S in b.def&&JSON.stringify(d[S])===JSON.stringify(b.def[S])&&delete d[S]}const p=u._zod.parent;if(p&&p!==f){r(p);const b=e.seen.get(p);if(b!=null&&b.schema.$ref&&(d.$ref=b.schema.$ref,b.def))for(const E in d)E==="$ref"||E==="allOf"||E in b.def&&JSON.stringify(d[E])===JSON.stringify(b.def[E])&&delete d[E]}e.override({zodSchema:u,jsonSchema:d,path:l.path??[]})};for(const u of[...e.seen.entries()].reverse())r(u[0]);const o={};if(e.target==="draft-2020-12"?o.$schema="https://json-schema.org/draft/2020-12/schema":e.target==="draft-07"?o.$schema="http://json-schema.org/draft-07/schema#":e.target==="draft-04"?o.$schema="http://json-schema.org/draft-04/schema#":e.target,(i=e.external)!=null&&i.uri){const u=(a=e.external.registry.get(n))==null?void 0:a.id;if(!u)throw new Error("Schema is missing an `id` property");o.$id=e.external.uri(u)}Object.assign(o,t.def??t.schema);const s=((c=e.external)==null?void 0:c.defs)??{};for(const u of e.seen.entries()){const l=u[1];l.def&&l.defId&&(s[l.defId]=l.def)}e.external||Object.keys(s).length>0&&(e.target==="draft-2020-12"?o.$defs=s:o.definitions=s);try{const u=JSON.parse(JSON.stringify(o));return Object.defineProperty(u,"~standard",{value:{...n["~standard"],jsonSchema:{input:En(n,"input",e.processors),output:En(n,"output",e.processors)}},enumerable:!1,writable:!1}),u}catch{throw new Error("Error converting schema to JSON.")}}function D(e,n){const t=n??{seen:new Set};if(t.seen.has(e))return!1;t.seen.add(e);const r=e._zod.def;if(r.type==="transform")return!0;if(r.type==="array")return D(r.element,t);if(r.type==="set")return D(r.valueType,t);if(r.type==="lazy")return D(r.getter(),t);if(r.type==="promise"||r.type==="optional"||r.type==="nonoptional"||r.type==="nullable"||r.type==="readonly"||r.type==="default"||r.type==="prefault")return D(r.innerType,t);if(r.type==="intersection")return D(r.left,t)||D(r.right,t);if(r.type==="record"||r.type==="map")return D(r.keyType,t)||D(r.valueType,t);if(r.type==="pipe")return D(r.in,t)||D(r.out,t);if(r.type==="object"){for(const o in r.shape)if(D(r.shape[o],t))return!0;return!1}if(r.type==="union"){for(const o of r.options)if(D(o,t))return!0;return!1}if(r.type==="tuple"){for(const o of r.items)if(D(o,t))return!0;return!!(r.rest&&D(r.rest,t))}return!1}const Jm=(e,n={})=>t=>{const r=gn({...t,processors:n});return v(e,r),pn(r,e),bn(r,e)},En=(e,n,t={})=>r=>{const{libraryOptions:o,target:s}=r??{},i=gn({...o??{},target:s,io:n,processors:t});return v(e,i),pn(i,e),bn(i,e)},Dm={guid:"uuid",url:"uri",datetime:"date-time",json_string:"json-string",regex:""},Ii=(e,n,t,r)=>{const o=t;o.type="string";const{minimum:s,maximum:i,format:a,patterns:c,contentEncoding:u}=e._zod.bag;if(typeof s=="number"&&(o.minLength=s),typeof i=="number"&&(o.maxLength=i),a&&(o.format=Dm[a]??a,o.format===""&&delete o.format,a==="time"&&delete o.format),u&&(o.contentEncoding=u),c&&c.size>0){const l=[...c];l.length===1?o.pattern=l[0].source:l.length>1&&(o.allOf=[...l.map(d=>({...n.target==="draft-07"||n.target==="draft-04"||n.target==="openapi-3.0"?{type:"string"}:{},pattern:d.source}))])}},_i=(e,n,t,r)=>{const o=t,{minimum:s,maximum:i,format:a,multipleOf:c,exclusiveMaximum:u,exclusiveMinimum:l}=e._zod.bag;typeof a=="string"&&a.includes("int")?o.type="integer":o.type="number",typeof l=="number"&&(n.target==="draft-04"||n.target==="openapi-3.0"?(o.minimum=l,o.exclusiveMinimum=!0):o.exclusiveMinimum=l),typeof s=="number"&&(o.minimum=s,typeof l=="number"&&n.target!=="draft-04"&&(l>=s?delete o.minimum:delete o.exclusiveMinimum)),typeof u=="number"&&(n.target==="draft-04"||n.target==="openapi-3.0"?(o.maximum=u,o.exclusiveMaximum=!0):o.exclusiveMaximum=u),typeof i=="number"&&(o.maximum=i,typeof u=="number"&&n.target!=="draft-04"&&(u<=i?delete o.maximum:delete o.exclusiveMaximum)),typeof c=="number"&&(o.multipleOf=c)},Zi=(e,n,t,r)=>{t.type="boolean"},xm=(e,n,t,r)=>{if(n.unrepresentable==="throw")throw new Error("BigInt cannot be represented in JSON Schema")},Km=(e,n,t,r)=>{if(n.unrepresentable==="throw")throw new Error("Symbols cannot be represented in JSON Schema")},Ri=(e,n,t,r)=>{n.target==="openapi-3.0"?(t.type="string",t.nullable=!0,t.enum=[null]):t.type="null"},vi=(e,n,t,r)=>{if(n.unrepresentable==="throw")throw new Error("Undefined cannot be represented in JSON Schema")},Lm=(e,n,t,r)=>{if(n.unrepresentable==="throw")throw new Error("Void cannot be represented in JSON Schema")},Vi=(e,n,t,r)=>{t.not={}},Mm=(e,n,t,r)=>{},Ci=(e,n,t,r)=>{},$m=(e,n,t,r)=>{if(n.unrepresentable==="throw")throw new Error("Date cannot be represented in JSON Schema")},wi=(e,n,t,r)=>{const o=e._zod.def,s=ti(o.entries);s.every(i=>typeof i=="number")&&(t.type="number"),s.every(i=>typeof i=="string")&&(t.type="string"),t.enum=s},ki=(e,n,t,r)=>{const o=e._zod.def,s=[];for(const i of o.values)if(i===void 0){if(n.unrepresentable==="throw")throw new Error("Literal `undefined` cannot be represented in JSON Schema")}else if(typeof i=="bigint"){if(n.unrepresentable==="throw")throw new Error("BigInt literals cannot be represented in JSON Schema");s.push(Number(i))}else s.push(i);if(s.length!==0)if(s.length===1){const i=s[0];t.type=i===null?"null":typeof i,n.target==="draft-04"||n.target==="openapi-3.0"?t.enum=[i]:t.const=i}else s.every(i=>typeof i=="number")&&(t.type="number"),s.every(i=>typeof i=="string")&&(t.type="string"),s.every(i=>typeof i=="boolean")&&(t.type="boolean"),s.every(i=>i===null)&&(t.type="null"),t.enum=s},Pm=(e,n,t,r)=>{if(n.unrepresentable==="throw")throw new Error("NaN cannot be represented in JSON Schema")},jm=(e,n,t,r)=>{const o=t,s=e._zod.pattern;if(!s)throw new Error("Pattern not found in template literal");o.type="string",o.pattern=s.source},Qm=(e,n,t,r)=>{const o=t,s={type:"string",format:"binary",contentEncoding:"binary"},{minimum:i,maximum:a,mime:c}=e._zod.bag;i!==void 0&&(s.minLength=i),a!==void 0&&(s.maxLength=a),c?c.length===1?(s.contentMediaType=c[0],Object.assign(o,s)):(Object.assign(o,s),o.anyOf=c.map(u=>({contentMediaType:u}))):Object.assign(o,s)},Hm=(e,n,t,r)=>{t.type="boolean"},Bi=(e,n,t,r)=>{if(n.unrepresentable==="throw")throw new Error("Custom types cannot be represented in JSON Schema")},qm=(e,n,t,r)=>{if(n.unrepresentable==="throw")throw new Error("Function types cannot be represented in JSON Schema")},Fi=(e,n,t,r)=>{if(n.unrepresentable==="throw")throw new Error("Transforms cannot be represented in JSON Schema")},eh=(e,n,t,r)=>{if(n.unrepresentable==="throw")throw new Error("Map cannot be represented in JSON Schema")},nh=(e,n,t,r)=>{if(n.unrepresentable==="throw")throw new Error("Set cannot be represented in JSON Schema")},Gi=(e,n,t,r)=>{const o=t,s=e._zod.def,{minimum:i,maximum:a}=e._zod.bag;typeof i=="number"&&(o.minItems=i),typeof a=="number"&&(o.maxItems=a),o.type="array",o.items=v(s.element,n,{...r,path:[...r.path,"items"]})},Ti=(e,n,t,r)=>{var u;const o=t,s=e._zod.def;o.type="object",o.properties={};const i=s.shape;for(const l in i)o.properties[l]=v(i[l],n,{...r,path:[...r.path,"properties",l]});const a=new Set(Object.keys(i)),c=new Set([...a].filter(l=>{const d=s.shape[l]._zod;return n.io==="input"?d.optin===void 0:d.optout===void 0}));c.size>0&&(o.required=Array.from(c)),((u=s.catchall)==null?void 0:u._zod.def.type)==="never"?o.additionalProperties=!1:s.catchall?s.catchall&&(o.additionalProperties=v(s.catchall,n,{...r,path:[...r.path,"additionalProperties"]})):n.io==="output"&&(o.additionalProperties=!1)},Ui=(e,n,t,r)=>{const o=e._zod.def,s=o.inclusive===!1,i=o.options.map((a,c)=>v(a,n,{...r,path:[...r.path,s?"oneOf":"anyOf",c]}));s?t.oneOf=i:t.anyOf=i},Yi=(e,n,t,r)=>{const o=e._zod.def,s=v(o.left,n,{...r,path:[...r.path,"allOf",0]}),i=v(o.right,n,{...r,path:[...r.path,"allOf",1]}),a=u=>"allOf"in u&&Object.keys(u).length===1,c=[...a(s)?s.allOf:[s],...a(i)?i.allOf:[i]];t.allOf=c},th=(e,n,t,r)=>{const o=t,s=e._zod.def;o.type="array";const i=n.target==="draft-2020-12"?"prefixItems":"items",a=n.target==="draft-2020-12"||n.target==="openapi-3.0"?"items":"additionalItems",c=s.items.map((g,f)=>v(g,n,{...r,path:[...r.path,i,f]})),u=s.rest?v(s.rest,n,{...r,path:[...r.path,a,...n.target==="openapi-3.0"?[s.items.length]:[]]}):null;n.target==="draft-2020-12"?(o.prefixItems=c,u&&(o.items=u)):n.target==="openapi-3.0"?(o.items={anyOf:c},u&&o.items.anyOf.push(u),o.minItems=c.length,u||(o.maxItems=c.length)):(o.items=c,u&&(o.additionalItems=u));const{minimum:l,maximum:d}=e._zod.bag;typeof l=="number"&&(o.minItems=l),typeof d=="number"&&(o.maxItems=d)},Wi=(e,n,t,r)=>{const o=t,s=e._zod.def;o.type="object";const i=s.keyType,a=i._zod.bag,c=a==null?void 0:a.patterns;if(s.mode==="loose"&&c&&c.size>0){const l=v(s.valueType,n,{...r,path:[...r.path,"patternProperties","*"]});o.patternProperties={};for(const d of c)o.patternProperties[d.source]=l}else(n.target==="draft-07"||n.target==="draft-2020-12")&&(o.propertyNames=v(s.keyType,n,{...r,path:[...r.path,"propertyNames"]})),o.additionalProperties=v(s.valueType,n,{...r,path:[...r.path,"additionalProperties"]});const u=i._zod.values;if(u){const l=[...u].filter(d=>typeof d=="string"||typeof d=="number");l.length>0&&(o.required=l)}},Oi=(e,n,t,r)=>{const o=e._zod.def,s=v(o.innerType,n,r),i=n.seen.get(e);n.target==="openapi-3.0"?(i.ref=o.innerType,t.nullable=!0):t.anyOf=[s,{type:"null"}]},Xi=(e,n,t,r)=>{const o=e._zod.def;v(o.innerType,n,r);const s=n.seen.get(e);s.ref=o.innerType},zi=(e,n,t,r)=>{const o=e._zod.def;v(o.innerType,n,r);const s=n.seen.get(e);s.ref=o.innerType,t.default=JSON.parse(JSON.stringify(o.defaultValue))},Ji=(e,n,t,r)=>{const o=e._zod.def;v(o.innerType,n,r);const s=n.seen.get(e);s.ref=o.innerType,n.io==="input"&&(t._prefault=JSON.parse(JSON.stringify(o.defaultValue)))},Di=(e,n,t,r)=>{const o=e._zod.def;v(o.innerType,n,r);const s=n.seen.get(e);s.ref=o.innerType;let i;try{i=o.catchValue(void 0)}catch{throw new Error("Dynamic catch values are not supported in JSON Schema")}t.default=i},xi=(e,n,t,r)=>{const o=e._zod.def,s=n.io==="input"?o.in._zod.def.type==="transform"?o.out:o.in:o.out;v(s,n,r);const i=n.seen.get(e);i.ref=s},Ki=(e,n,t,r)=>{const o=e._zod.def;v(o.innerType,n,r);const s=n.seen.get(e);s.ref=o.innerType,t.readOnly=!0},rh=(e,n,t,r)=>{const o=e._zod.def;v(o.innerType,n,r);const s=n.seen.get(e);s.ref=o.innerType},Yt=(e,n,t,r)=>{const o=e._zod.def;v(o.innerType,n,r);const s=n.seen.get(e);s.ref=o.innerType},oh=(e,n,t,r)=>{const o=e._zod.innerType;v(o,n,r);const s=n.seen.get(e);s.ref=o},uo={string:Ii,number:_i,boolean:Zi,bigint:xm,symbol:Km,null:Ri,undefined:vi,void:Lm,never:Vi,any:Mm,unknown:Ci,date:$m,enum:wi,literal:ki,nan:Pm,template_literal:jm,file:Qm,success:Hm,custom:Bi,function:qm,transform:Fi,map:eh,set:nh,array:Gi,object:Ti,union:Ui,intersection:Yi,tuple:th,record:Wi,nullable:Oi,nonoptional:Xi,default:zi,prefault:Ji,catch:Di,pipe:xi,readonly:Ki,promise:rh,optional:Yt,lazy:oh};function sh(e,n){if("_idmap"in e){const r=e,o=gn({...n,processors:uo}),s={};for(const c of r._idmap.entries()){const[u,l]=c;v(l,o)}const i={},a={registry:r,uri:n==null?void 0:n.uri,defs:s};o.external=a;for(const c of r._idmap.entries()){const[u,l]=c;pn(o,l),i[u]=bn(o,l)}if(Object.keys(s).length>0){const c=o.target==="draft-2020-12"?"$defs":"definitions";i.__shared={[c]:s}}return{schemas:i}}const t=gn({...n,processors:uo});return v(e,t),pn(t,e),bn(t,e)}const ih=h("ZodISODateTime",(e,n)=>{af.init(e,n),F.init(e,n)});function ah(e){return gm(ih,e)}const ch=h("ZodISODate",(e,n)=>{cf.init(e,n),F.init(e,n)});function uh(e){return pm(ch,e)}const lh=h("ZodISOTime",(e,n)=>{uf.init(e,n),F.init(e,n)});function dh(e){return bm(lh,e)}const fh=h("ZodISODuration",(e,n)=>{lf.init(e,n),F.init(e,n)});function mh(e){return Em(fh,e)}const hh=(e,n)=>{ii.init(e,n),e.name="ZodError",Object.defineProperties(e,{format:{value:t=>Ql(e,t)},flatten:{value:t=>jl(e,t)},addIssue:{value:t=>{e.issues.push(t),e.message=JSON.stringify(e.issues,tt,2)}},addIssues:{value:t=>{e.issues.push(...t),e.message=JSON.stringify(e.issues,tt,2)}},isEmpty:{get(){return e.issues.length===0}}})},P=h("ZodError",hh,{Parent:Error}),gh=Gt(P),ph=Tt(P),bh=vn(P),Eh=Vn(P),Ah=ed(P),Nh=nd(P),yh=td(P),Sh=rd(P),Ih=od(P),_h=sd(P),Zh=id(P),Rh=ad(P),C=h("ZodType",(e,n)=>(V.init(e,n),Object.assign(e["~standard"],{jsonSchema:{input:En(e,"input"),output:En(e,"output")}}),e.toJSONSchema=Jm(e,{}),e.def=n,e.type=n.type,Object.defineProperty(e,"_def",{value:n}),e.check=(...t)=>e.clone(fe(n,{checks:[...n.checks??[],...t.map(r=>typeof r=="function"?{_zod:{check:r,def:{check:"custom"},onattach:[]}}:r)]}),{parent:!0}),e.with=e.check,e.clone=(t,r)=>me(e,t,r),e.brand=()=>e,e.register=((t,r)=>(t.add(e,r),e)),e.parse=(t,r)=>gh(e,t,r,{callee:e.parse}),e.safeParse=(t,r)=>bh(e,t,r),e.parseAsync=async(t,r)=>ph(e,t,r,{callee:e.parseAsync}),e.safeParseAsync=async(t,r)=>Eh(e,t,r),e.spa=e.safeParseAsync,e.encode=(t,r)=>Ah(e,t,r),e.decode=(t,r)=>Nh(e,t,r),e.encodeAsync=async(t,r)=>yh(e,t,r),e.decodeAsync=async(t,r)=>Sh(e,t,r),e.safeEncode=(t,r)=>Ih(e,t,r),e.safeDecode=(t,r)=>_h(e,t,r),e.safeEncodeAsync=async(t,r)=>Zh(e,t,r),e.safeDecodeAsync=async(t,r)=>Rh(e,t,r),e.refine=(t,r)=>e.check(Ag(t,r)),e.superRefine=t=>e.check(Ng(t)),e.overwrite=t=>e.check(Be(t)),e.optional=()=>fo(e),e.exactOptional=()=>ag(e),e.nullable=()=>mo(e),e.nullish=()=>fo(mo(e)),e.nonoptional=t=>mg(e,t),e.array=()=>$i(e),e.or=t=>qh([e,t]),e.and=t=>tg(e,t),e.transform=t=>it(e,Qi(t)),e.default=t=>lg(e,t),e.prefault=t=>fg(e,t),e.catch=t=>gg(e,t),e.pipe=t=>it(e,t),e.readonly=()=>Eg(e),e.describe=t=>{const r=e.clone();return Ge.add(r,{description:t}),r},Object.defineProperty(e,"description",{get(){var t;return(t=Ge.get(e))==null?void 0:t.description},configurable:!0}),e.meta=(...t)=>{if(t.length===0)return Ge.get(e);const r=e.clone();return Ge.add(r,t[0]),r},e.isOptional=()=>e.safeParse(void 0).success,e.isNullable=()=>e.safeParse(null).success,e.apply=t=>t(e),e)),Li=h("_ZodString",(e,n)=>{Ut.init(e,n),C.init(e,n),e._zod.processJSONSchema=(r,o,s)=>Ii(e,r,o);const t=e._zod.bag;e.format=t.format??null,e.minLength=t.minimum??null,e.maxLength=t.maximum??null,e.regex=(...r)=>e.check(Rm(...r)),e.includes=(...r)=>e.check(Cm(...r)),e.startsWith=(...r)=>e.check(wm(...r)),e.endsWith=(...r)=>e.check(km(...r)),e.min=(...r)=>e.check(hn(...r)),e.max=(...r)=>e.check(yi(...r)),e.length=(...r)=>e.check(Si(...r)),e.nonempty=(...r)=>e.check(hn(1,...r)),e.lowercase=r=>e.check(vm(r)),e.uppercase=r=>e.check(Vm(r)),e.trim=()=>e.check(Fm()),e.normalize=(...r)=>e.check(Bm(...r)),e.toLowerCase=()=>e.check(Gm()),e.toUpperCase=()=>e.check(Tm()),e.slugify=()=>e.check(Um())}),vh=h("ZodString",(e,n)=>{Ut.init(e,n),Li.init(e,n),e.email=t=>e.check($f(Vh,t)),e.url=t=>e.check(qf(Ch,t)),e.jwt=t=>e.check(hm(xh,t)),e.emoji=t=>e.check(em(wh,t)),e.guid=t=>e.check(so(lo,t)),e.uuid=t=>e.check(Pf(tn,t)),e.uuidv4=t=>e.check(jf(tn,t)),e.uuidv6=t=>e.check(Qf(tn,t)),e.uuidv7=t=>e.check(Hf(tn,t)),e.nanoid=t=>e.check(nm(kh,t)),e.guid=t=>e.check(so(lo,t)),e.cuid=t=>e.check(tm(Bh,t)),e.cuid2=t=>e.check(rm(Fh,t)),e.ulid=t=>e.check(om(Gh,t)),e.base64=t=>e.check(dm(zh,t)),e.base64url=t=>e.check(fm(Jh,t)),e.xid=t=>e.check(sm(Th,t)),e.ksuid=t=>e.check(im(Uh,t)),e.ipv4=t=>e.check(am(Yh,t)),e.ipv6=t=>e.check(cm(Wh,t)),e.cidrv4=t=>e.check(um(Oh,t)),e.cidrv6=t=>e.check(lm(Xh,t)),e.e164=t=>e.check(mm(Dh,t)),e.datetime=t=>e.check(ah(t)),e.date=t=>e.check(uh(t)),e.time=t=>e.check(dh(t)),e.duration=t=>e.check(mh(t))});function $(e){return Mf(vh,e)}const F=h("ZodStringFormat",(e,n)=>{k.init(e,n),Li.init(e,n)}),Vh=h("ZodEmail",(e,n)=>{Qd.init(e,n),F.init(e,n)}),lo=h("ZodGUID",(e,n)=>{Pd.init(e,n),F.init(e,n)}),tn=h("ZodUUID",(e,n)=>{jd.init(e,n),F.init(e,n)}),Ch=h("ZodURL",(e,n)=>{Hd.init(e,n),F.init(e,n)}),wh=h("ZodEmoji",(e,n)=>{qd.init(e,n),F.init(e,n)}),kh=h("ZodNanoID",(e,n)=>{ef.init(e,n),F.init(e,n)}),Bh=h("ZodCUID",(e,n)=>{nf.init(e,n),F.init(e,n)}),Fh=h("ZodCUID2",(e,n)=>{tf.init(e,n),F.init(e,n)}),Gh=h("ZodULID",(e,n)=>{rf.init(e,n),F.init(e,n)}),Th=h("ZodXID",(e,n)=>{of.init(e,n),F.init(e,n)}),Uh=h("ZodKSUID",(e,n)=>{sf.init(e,n),F.init(e,n)}),Yh=h("ZodIPv4",(e,n)=>{df.init(e,n),F.init(e,n)}),Wh=h("ZodIPv6",(e,n)=>{ff.init(e,n),F.init(e,n)}),Oh=h("ZodCIDRv4",(e,n)=>{mf.init(e,n),F.init(e,n)}),Xh=h("ZodCIDRv6",(e,n)=>{hf.init(e,n),F.init(e,n)}),zh=h("ZodBase64",(e,n)=>{gf.init(e,n),F.init(e,n)}),Jh=h("ZodBase64URL",(e,n)=>{bf.init(e,n),F.init(e,n)}),Dh=h("ZodE164",(e,n)=>{Ef.init(e,n),F.init(e,n)}),xh=h("ZodJWT",(e,n)=>{Nf.init(e,n),F.init(e,n)}),Mi=h("ZodNumber",(e,n)=>{pi.init(e,n),C.init(e,n),e._zod.processJSONSchema=(r,o,s)=>_i(e,r,o),e.gt=(r,o)=>e.check(ao(r,o)),e.gte=(r,o)=>e.check(zn(r,o)),e.min=(r,o)=>e.check(zn(r,o)),e.lt=(r,o)=>e.check(io(r,o)),e.lte=(r,o)=>e.check(Xn(r,o)),e.max=(r,o)=>e.check(Xn(r,o)),e.int=r=>e.check(xe(r)),e.safe=r=>e.check(xe(r)),e.positive=r=>e.check(ao(0,r)),e.nonnegative=r=>e.check(zn(0,r)),e.negative=r=>e.check(io(0,r)),e.nonpositive=r=>e.check(Xn(0,r)),e.multipleOf=(r,o)=>e.check(co(r,o)),e.step=(r,o)=>e.check(co(r,o)),e.finite=()=>e;const t=e._zod.bag;e.minValue=Math.max(t.minimum??Number.NEGATIVE_INFINITY,t.exclusiveMinimum??Number.NEGATIVE_INFINITY)??null,e.maxValue=Math.min(t.maximum??Number.POSITIVE_INFINITY,t.exclusiveMaximum??Number.POSITIVE_INFINITY)??null,e.isInt=(t.format??"").includes("int")||Number.isSafeInteger(t.multipleOf??.5),e.isFinite=!0,e.format=t.format??null});function tp(e){return Am(Mi,e)}const Kh=h("ZodNumberFormat",(e,n)=>{yf.init(e,n),Mi.init(e,n)});function xe(e){return Nm(Kh,e)}const Lh=h("ZodBoolean",(e,n)=>{Sf.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>Zi(e,t,r)});function Wt(e){return ym(Lh,e)}const Mh=h("ZodUndefined",(e,n)=>{If.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>vi(e,t)});function rp(e){return Sm(Mh,e)}const $h=h("ZodNull",(e,n)=>{_f.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>Ri(e,t,r)});function op(e){return Im($h,e)}const Ph=h("ZodUnknown",(e,n)=>{Zf.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>Ci()});function ot(){return _m(Ph)}const jh=h("ZodNever",(e,n)=>{Rf.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>Vi(e,t,r)});function Qh(e){return Zm(jh,e)}const Hh=h("ZodArray",(e,n)=>{vf.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>Gi(e,t,r,o),e.element=n.element,e.min=(t,r)=>e.check(hn(t,r)),e.nonempty=t=>e.check(hn(1,t)),e.max=(t,r)=>e.check(yi(t,r)),e.length=(t,r)=>e.check(Si(t,r)),e.unwrap=()=>e.element});function $i(e,n){return Ym(Hh,e,n)}const Pi=h("ZodObject",(e,n)=>{Cf.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>Ti(e,t,r,o),_(e,"shape",()=>n.shape),e.keyof=()=>Ee(Object.keys(e._zod.def.shape)),e.catchall=t=>e.clone({...e._zod.def,catchall:t}),e.passthrough=()=>e.clone({...e._zod.def,catchall:ot()}),e.loose=()=>e.clone({...e._zod.def,catchall:ot()}),e.strict=()=>e.clone({...e._zod.def,catchall:Qh()}),e.strip=()=>e.clone({...e._zod.def,catchall:void 0}),e.extend=t=>Kl(e,t),e.safeExtend=t=>Ll(e,t),e.merge=t=>Ml(e,t),e.pick=t=>Dl(e,t),e.omit=t=>xl(e,t),e.partial=(...t)=>$l(Hi,e,t[0]),e.required=(...t)=>Pl(qi,e,t[0])});function te(e,n){const t={type:"object",shape:e??{},...N(n)};return new Pi(t)}function sp(e,n){return new Pi({type:"object",shape:e,catchall:ot(),...N(n)})}const ji=h("ZodUnion",(e,n)=>{Ai.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>Ui(e,t,r,o),e.options=n.options});function qh(e,n){return new ji({type:"union",options:e,...N(n)})}const eg=h("ZodDiscriminatedUnion",(e,n)=>{ji.init(e,n),wf.init(e,n)});function ip(e,n,t){return new eg({type:"union",options:n,discriminator:e,...N(t)})}const ng=h("ZodIntersection",(e,n)=>{kf.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>Yi(e,t,r,o)});function tg(e,n){return new ng({type:"intersection",left:e,right:n})}const rg=h("ZodRecord",(e,n)=>{Bf.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>Wi(e,t,r,o),e.keyType=n.keyType,e.valueType=n.valueType});function ap(e,n,t){return new rg({type:"record",keyType:e,valueType:n,...N(t)})}const st=h("ZodEnum",(e,n)=>{Ff.init(e,n),C.init(e,n),e._zod.processJSONSchema=(r,o,s)=>wi(e,r,o),e.enum=n.entries,e.options=Object.values(n.entries);const t=new Set(Object.keys(n.entries));e.extract=(r,o)=>{const s={};for(const i of r)if(t.has(i))s[i]=n.entries[i];else throw new Error(`Key ${i} not found in enum`);return new st({...n,checks:[],...N(o),entries:s})},e.exclude=(r,o)=>{const s={...n.entries};for(const i of r)if(t.has(i))delete s[i];else throw new Error(`Key ${i} not found in enum`);return new st({...n,checks:[],...N(o),entries:s})}});function Ee(e,n){const t=Array.isArray(e)?Object.fromEntries(e.map(r=>[r,r])):e;return new st({type:"enum",entries:t,...N(n)})}const og=h("ZodLiteral",(e,n)=>{Gf.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>ki(e,t,r),e.values=new Set(n.values),Object.defineProperty(e,"value",{get(){if(n.values.length>1)throw new Error("This schema contains multiple valid literal values. Use `.values` instead.");return n.values[0]}})});function cp(e,n){return new og({type:"literal",values:Array.isArray(e)?e:[e],...N(n)})}const sg=h("ZodTransform",(e,n)=>{Tf.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>Fi(e,t),e._zod.parse=(t,r)=>{if(r.direction==="backward")throw new ei(e.constructor.name);t.addIssue=s=>{if(typeof s=="string")t.issues.push(De(s,t.value,n));else{const i=s;i.fatal&&(i.continue=!1),i.code??(i.code="custom"),i.input??(i.input=t.value),i.inst??(i.inst=e),t.issues.push(De(i))}};const o=n.transform(t.value,t);return o instanceof Promise?o.then(s=>(t.value=s,t)):(t.value=o,t)}});function Qi(e){return new sg({type:"transform",transform:e})}const Hi=h("ZodOptional",(e,n)=>{Ni.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>Yt(e,t,r,o),e.unwrap=()=>e._zod.def.innerType});function fo(e){return new Hi({type:"optional",innerType:e})}const ig=h("ZodExactOptional",(e,n)=>{Uf.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>Yt(e,t,r,o),e.unwrap=()=>e._zod.def.innerType});function ag(e){return new ig({type:"optional",innerType:e})}const cg=h("ZodNullable",(e,n)=>{Yf.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>Oi(e,t,r,o),e.unwrap=()=>e._zod.def.innerType});function mo(e){return new cg({type:"nullable",innerType:e})}const ug=h("ZodDefault",(e,n)=>{Wf.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>zi(e,t,r,o),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});function lg(e,n){return new ug({type:"default",innerType:e,get defaultValue(){return typeof n=="function"?n():oi(n)}})}const dg=h("ZodPrefault",(e,n)=>{Of.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>Ji(e,t,r,o),e.unwrap=()=>e._zod.def.innerType});function fg(e,n){return new dg({type:"prefault",innerType:e,get defaultValue(){return typeof n=="function"?n():oi(n)}})}const qi=h("ZodNonOptional",(e,n)=>{Xf.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>Xi(e,t,r,o),e.unwrap=()=>e._zod.def.innerType});function mg(e,n){return new qi({type:"nonoptional",innerType:e,...N(n)})}const hg=h("ZodCatch",(e,n)=>{zf.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>Di(e,t,r,o),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});function gg(e,n){return new hg({type:"catch",innerType:e,catchValue:typeof n=="function"?n:()=>n})}const pg=h("ZodPipe",(e,n)=>{Jf.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>xi(e,t,r,o),e.in=n.in,e.out=n.out});function it(e,n){return new pg({type:"pipe",in:e,out:n})}const bg=h("ZodReadonly",(e,n)=>{Df.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>Ki(e,t,r,o),e.unwrap=()=>e._zod.def.innerType});function Eg(e){return new bg({type:"readonly",innerType:e})}const ea=h("ZodCustom",(e,n)=>{xf.init(e,n),C.init(e,n),e._zod.processJSONSchema=(t,r,o)=>Bi(e,t)});function up(e,n){return Wm(ea,e??(()=>!0),n)}function Ag(e,n={}){return Om(ea,e,n)}function Ng(e){return Xm(e)}function lp(e,n){return it(Qi(e),n)}const na=Ee(["primary","danger","outline","ghost"]),ta=Ee(["sm","md","lg"]),yg=Ee(["sm","md","lg","xl"]),Sg=Ee(["rectangular","circular"]),Ig=Ee(["success","error","warning","info"]),_g=Ee(["top","bottom","left","right"]),Zg=te({variant:na.optional().describe("Visual style (default primary)."),size:ta.optional().describe("Button size (default md)."),disabled:Wt().optional()}),Rg=te({label:$(),description:$().optional()}),vg=te({label:$().describe("Main action label."),variant:na.optional(),size:ta.optional(),options:$i(Rg).describe("Secondary options shown in the dropdown.")}),Vg=te({variant:Ig.optional().describe("Severity (default info)."),dismissible:Wt().optional()}),Cg=te({size:yg.optional().describe("Spinner size (default md)."),label:$().optional().describe("Accessible label (default 'Loading')."),liveRegion:Wt().optional().describe("Announce status to screen readers via aria-live.")}),wg=te({width:$().optional().describe("CSS width (default 100%)."),height:$().optional().describe("CSS height (default 1rem)."),borderRadius:$().optional(),variant:Sg.optional()}),kg=te({lines:xe().min(1).optional().describe("Number of lines (default 3)."),lastLineWidth:$().optional().describe("Width of the last line (default 60%)."),lineHeight:$().optional(),gap:$().optional()}),Bg=te({lines:xe().min(1).optional().describe("Body text lines (default 2).")}),Fg=te({text:$().describe("Tooltip text."),placement:_g.optional().describe("Placement relative to the anchor (default top)."),delayMs:xe().min(0).optional()}),Gg=te({text:$().describe("Text to copy to the clipboard.")}),ra={Button:Zg,SplitButton:vg,Callout:Vg,Spinner:Cg,Skeleton:wg,SkeletonText:kg,SkeletonCard:Bg,Tooltip:Fg,CopyButton:Gg},ho={Button:{description:"Clickable action button with visual variants and sizes.",example:'<Button variant="primary">Deploy</Button>'},SplitButton:{description:"Primary action button with a dropdown of secondary options.",example:'<SplitButton label="Save" onClick={() => {}} options={[{ label: "Save as draft", onClick: () => {} }]} />'},Callout:{description:"Inline message box for info, success, warning, or error notes.",example:'<Callout variant="warning">Low disk space.</Callout>'},Spinner:{description:"Loading/progress spinner.",example:'<Spinner size="lg" label="Building…" />'},Skeleton:{description:"Rectangular or circular loading placeholder block.",example:'<Skeleton width="200px" height="2rem" />'},SkeletonText:{description:"Multi-line text loading placeholder.",example:"<SkeletonText lines={4} />"},SkeletonCard:{description:"Card-shaped loading placeholder (title + body lines).",example:"<SkeletonCard lines={3} />"},Tooltip:{description:"Hover tooltip wrapping its children.",example:'<Tooltip text="Copy to clipboard"><Button>Copy</Button></Tooltip>'},CopyButton:{description:"Button that copies the given text to the clipboard.",example:'<CopyButton text="npm install grackle" />'}},Tg=Object.fromEntries(Object.entries(ra).map(([e,n])=>[e,sh(n)]));Object.keys(ra).map(e=>({name:e,description:ho[e].description,propsSchema:JSON.stringify(Tg[e]),example:ho[e].example}));var go;(function(e){e.Enabled="enabled",e.Disabled="disabled",e.Unconfigured="unconfigured"})(go||(go={}));var po;(function(e){e.Steering="steering",e.Queued="queued"})(po||(po={}));var bo;(function(e){e.Creating="creating",e.Ready="ready",e.CreationFailed="creationFailed"})(bo||(bo={}));var Eo;(function(e){e[e.Idle=1]="Idle",e[e.Error=2]="Error",e[e.InProgress=8]="InProgress",e[e.InputNeeded=24]="InputNeeded",e[e.IsRead=32]="IsRead",e[e.IsArchived=64]="IsArchived"})(Eo||(Eo={}));var Ao;(function(e){e.Accept="accept",e.Decline="decline",e.Cancel="cancel"})(Ao||(Ao={}));var No;(function(e){e.Text="text",e.Number="number",e.Integer="integer",e.Boolean="boolean",e.SingleSelect="single-select",e.MultiSelect="multi-select"})(No||(No={}));var yo;(function(e){e.Text="text",e.Number="number",e.Boolean="boolean",e.Selected="selected",e.SelectedMany="selected-many"})(yo||(yo={}));var So;(function(e){e.Draft="draft",e.Submitted="submitted",e.Skipped="skipped"})(So||(So={}));var Io;(function(e){e.Complete="complete",e.Cancelled="cancelled",e.Error="error"})(Io||(Io={}));var _o;(function(e){e.Simple="simple",e.EmbeddedResource="embeddedResource",e.Resource="resource"})(_o||(_o={}));var Zo;(function(e){e.Markdown="markdown",e.ContentRef="contentRef",e.ToolCall="toolCall",e.Reasoning="reasoning",e.SystemNotification="systemNotification"})(Zo||(Zo={}));var Ro;(function(e){e.Streaming="streaming",e.PendingConfirmation="pending-confirmation",e.Running="running",e.PendingResultConfirmation="pending-result-confirmation",e.Completed="completed",e.Cancelled="cancelled"})(Ro||(Ro={}));var vo;(function(e){e.NotNeeded="not-needed",e.UserAction="user-action",e.Setting="setting"})(vo||(vo={}));var Vo;(function(e){e.Denied="denied",e.Skipped="skipped",e.ResultDenied="result-denied"})(Vo||(Vo={}));var Co;(function(e){e.Approve="approve",e.Deny="deny"})(Co||(Co={}));var wo;(function(e){e.Text="text",e.EmbeddedResource="embeddedResource",e.Resource="resource",e.FileEdit="fileEdit",e.Terminal="terminal",e.Subagent="subagent"})(wo||(wo={}));var ko;(function(e){e.Loading="loading",e.Loaded="loaded",e.Degraded="degraded",e.Error="error"})(ko||(ko={}));var Bo;(function(e){e.Client="client",e.Session="session"})(Bo||(Bo={}));var Fo;(function(e){e.Computing="computing",e.Ready="ready",e.Error="error"})(Fo||(Fo={}));var Go;(function(e){e.Changeset="changeset",e.Resource="resource",e.Range="range"})(Go||(Go={}));var A;(function(e){e.RootAgentsChanged="root/agentsChanged",e.RootActiveSessionsChanged="root/activeSessionsChanged",e.SessionReady="session/ready",e.SessionCreationFailed="session/creationFailed",e.SessionTurnStarted="session/turnStarted",e.SessionDelta="session/delta",e.SessionResponsePart="session/responsePart",e.SessionToolCallStart="session/toolCallStart",e.SessionToolCallDelta="session/toolCallDelta",e.SessionToolCallReady="session/toolCallReady",e.SessionToolCallConfirmed="session/toolCallConfirmed",e.SessionToolCallComplete="session/toolCallComplete",e.SessionToolCallResultConfirmed="session/toolCallResultConfirmed",e.SessionToolCallContentChanged="session/toolCallContentChanged",e.SessionTurnComplete="session/turnComplete",e.SessionTurnCancelled="session/turnCancelled",e.SessionError="session/error",e.SessionTitleChanged="session/titleChanged",e.SessionUsage="session/usage",e.SessionReasoning="session/reasoning",e.SessionModelChanged="session/modelChanged",e.SessionAgentChanged="session/agentChanged",e.SessionServerToolsChanged="session/serverToolsChanged",e.SessionActiveClientChanged="session/activeClientChanged",e.SessionActiveClientToolsChanged="session/activeClientToolsChanged",e.SessionPendingMessageSet="session/pendingMessageSet",e.SessionPendingMessageRemoved="session/pendingMessageRemoved",e.SessionQueuedMessagesReordered="session/queuedMessagesReordered",e.SessionInputRequested="session/inputRequested",e.SessionInputAnswerChanged="session/inputAnswerChanged",e.SessionInputCompleted="session/inputCompleted",e.SessionCustomizationsChanged="session/customizationsChanged",e.SessionCustomizationToggled="session/customizationToggled",e.SessionCustomizationUpdated="session/customizationUpdated",e.SessionTruncated="session/truncated",e.SessionIsReadChanged="session/isReadChanged",e.SessionIsArchivedChanged="session/isArchivedChanged",e.SessionActivityChanged="session/activityChanged",e.SessionChangesetsChanged="session/changesetsChanged",e.SessionConfigChanged="session/configChanged",e.SessionMetaChanged="session/metaChanged",e.ChangesetStatusChanged="changeset/statusChanged",e.ChangesetFileSet="changeset/fileSet",e.ChangesetFileRemoved="changeset/fileRemoved",e.ChangesetOperationsChanged="changeset/operationsChanged",e.ChangesetCleared="changeset/cleared",e.RootTerminalsChanged="root/terminalsChanged",e.RootConfigChanged="root/configChanged",e.TerminalData="terminal/data",e.TerminalInput="terminal/input",e.TerminalResized="terminal/resized",e.TerminalClaimed="terminal/claimed",e.TerminalTitleChanged="terminal/titleChanged",e.TerminalCwdChanged="terminal/cwdChanged",e.TerminalExited="terminal/exited",e.TerminalCleared="terminal/cleared",e.TerminalCommandDetectionAvailable="terminal/commandDetectionAvailable",e.TerminalCommandExecuted="terminal/commandExecuted",e.TerminalCommandFinished="terminal/commandFinished"})(A||(A={}));var To;(function(e){e.Replay="replay",e.Snapshot="snapshot"})(To||(To={}));var Uo;(function(e){e.Base64="base64",e.Utf8="utf-8"})(Uo||(Uo={}));var Yo;(function(e){e.UserMessage="userMessage"})(Yo||(Yo={}));var Wo;(function(e){e.Resource="resource",e.Range="range"})(Wo||(Wo={}));var Oo;(function(e){e.Required="required",e.Expired="expired"})(Oo||(Oo={}));A.RootAgentsChanged+"",A.RootActiveSessionsChanged+"",A.RootTerminalsChanged+"",A.RootConfigChanged+"",A.SessionReady+"",A.SessionCreationFailed+"",A.SessionTurnStarted+"",A.SessionDelta+"",A.SessionResponsePart+"",A.SessionToolCallStart+"",A.SessionToolCallDelta+"",A.SessionToolCallReady+"",A.SessionToolCallConfirmed+"",A.SessionToolCallComplete+"",A.SessionToolCallResultConfirmed+"",A.SessionToolCallContentChanged+"",A.SessionTurnComplete+"",A.SessionTurnCancelled+"",A.SessionError+"",A.SessionTitleChanged+"",A.SessionUsage+"",A.SessionReasoning+"",A.SessionModelChanged+"",A.SessionAgentChanged+"",A.SessionServerToolsChanged+"",A.SessionActiveClientChanged+"",A.SessionActiveClientToolsChanged+"",A.SessionPendingMessageSet+"",A.SessionPendingMessageRemoved+"",A.SessionQueuedMessagesReordered+"",A.SessionInputRequested+"",A.SessionInputAnswerChanged+"",A.SessionInputCompleted+"",A.SessionCustomizationsChanged+"",A.SessionCustomizationToggled+"",A.SessionCustomizationUpdated+"",A.SessionTruncated+"",A.SessionIsReadChanged+"",A.SessionIsArchivedChanged+"",A.SessionActivityChanged+"",A.SessionChangesetsChanged+"",A.SessionConfigChanged+"",A.SessionMetaChanged+"",A.ChangesetStatusChanged+"",A.ChangesetFileSet+"",A.ChangesetFileRemoved+"",A.ChangesetOperationsChanged+"",A.ChangesetCleared+"",A.TerminalData+"",A.TerminalInput+"",A.TerminalResized+"",A.TerminalClaimed+"",A.TerminalTitleChanged+"",A.TerminalCwdChanged+"",A.TerminalExited+"",A.TerminalCleared+"",A.TerminalCommandDetectionAvailable+"",A.TerminalCommandExecuted+"",A.TerminalCommandFinished+"";export{Lu as A,tg as B,T as C,Lg as D,lp as E,ah as F,Og as G,ip as H,Hl as I,rp as J,Qh as K,Dg as M,$g as O,Kg as R,xg as S,Mg as W,Ee as _,Yg as a,Xg as b,Wg as c,zg as d,Jg as e,np as f,Pg as g,Z as h,jg as i,qg as j,Wt as k,cp as l,$i as m,ot as n,te as o,ep as p,tp as q,ap as r,$ as s,Qg as t,qh as u,sp as v,Hg as w,up as x,fo as y,op as z};