From eb009f921a0f7627b5b07ba18dbeca91ff5bf8dd Mon Sep 17 00:00:00 2001 From: Aenimus Date: Fri, 15 Aug 2025 21:23:48 +0100 Subject: [PATCH 1/3] fix: propagate @external interface object fields --- composition-go/index.global.js | 80 +-- composition/src/errors/errors.ts | 7 +- composition/src/utils/types.ts | 3 +- .../src/v1/federation/federation-factory.ts | 47 +- .../v1/directives/interface-object.test.ts | 470 ++++++++++++++++++ composition/tests/v1/entity-interface.test.ts | 18 +- 6 files changed, 570 insertions(+), 55 deletions(-) diff --git a/composition-go/index.global.js b/composition-go/index.global.js index b8fcdb02ea..1a8c9da943 100644 --- a/composition-go/index.global.js +++ b/composition-go/index.global.js @@ -15,9 +15,9 @@ class URL { return urlCanParse(url, base || ''); } } -"use strict";var shim=(()=>{var rJ=Object.create;var Id=Object.defineProperty,iJ=Object.defineProperties,aJ=Object.getOwnPropertyDescriptor,sJ=Object.getOwnPropertyDescriptors,oJ=Object.getOwnPropertyNames,RA=Object.getOwnPropertySymbols,uJ=Object.getPrototypeOf,PA=Object.prototype.hasOwnProperty,cJ=Object.prototype.propertyIsEnumerable;var nn=Math.pow,Iy=(e,t,n)=>t in e?Id(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,x=(e,t)=>{for(var n in t||(t={}))PA.call(t,n)&&Iy(e,n,t[n]);if(RA)for(var n of RA(t))cJ.call(t,n)&&Iy(e,n,t[n]);return e},Y=(e,t)=>iJ(e,sJ(t));var Lu=(e,t)=>()=>(e&&(t=e(e=0)),t);var w=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),sm=(e,t)=>{for(var n in t)Id(e,n,{get:t[n],enumerable:!0})},FA=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of oJ(t))!PA.call(e,i)&&i!==n&&Id(e,i,{get:()=>t[i],enumerable:!(r=aJ(t,i))||r.enumerable});return e};var ss=(e,t,n)=>(n=e!=null?rJ(uJ(e)):{},FA(t||!e||!e.__esModule?Id(n,"default",{value:e,enumerable:!0}):n,e)),om=e=>FA(Id({},"__esModule",{value:!0}),e);var _=(e,t,n)=>(Iy(e,typeof t!="symbol"?t+"":t,n),n);var vi=(e,t,n)=>new Promise((r,i)=>{var a=l=>{try{c(n.next(l))}catch(p){i(p)}},o=l=>{try{c(n.throw(l))}catch(p){i(p)}},c=l=>l.done?r(l.value):Promise.resolve(l.value).then(a,o);c((n=n.apply(e,t)).next())});var m=Lu(()=>{"use strict"});var O={};sm(O,{_debugEnd:()=>yR,_debugProcess:()=>hR,_events:()=>BR,_eventsCount:()=>UR,_exiting:()=>ZA,_fatalExceptions:()=>mR,_getActiveHandles:()=>rR,_getActiveRequests:()=>nR,_kill:()=>aR,_linkedBinding:()=>WA,_maxListeners:()=>CR,_preload_modules:()=>FR,_rawDebug:()=>HA,_startProfilerIdleNotifier:()=>IR,_stopProfilerIdleNotifier:()=>gR,_tickCallback:()=>ER,abort:()=>OR,addListener:()=>kR,allowedNodeEnvironmentFlags:()=>dR,arch:()=>UA,argv:()=>xA,argv0:()=>PR,assert:()=>pR,binding:()=>GA,chdir:()=>YA,config:()=>eR,cpuUsage:()=>lm,cwd:()=>QA,debugPort:()=>RR,default:()=>QR,dlopen:()=>tR,domain:()=>XA,emit:()=>jR,emitWarning:()=>KA,env:()=>MA,execArgv:()=>qA,execPath:()=>AR,exit:()=>cR,features:()=>fR,hasUncaughtExceptionCaptureCallback:()=>TR,hrtime:()=>cm,kill:()=>uR,listeners:()=>$R,memoryUsage:()=>oR,moduleLoadList:()=>zA,nextTick:()=>LA,off:()=>xR,on:()=>us,once:()=>MR,openStdin:()=>lR,pid:()=>DR,platform:()=>kA,ppid:()=>bR,prependListener:()=>KR,prependOnceListener:()=>GR,reallyExit:()=>iR,release:()=>JA,removeAllListeners:()=>VR,removeListener:()=>qR,resourceUsage:()=>sR,setSourceMapsEnabled:()=>wR,setUncaughtExceptionCaptureCallback:()=>NR,stderr:()=>vR,stdin:()=>SR,stdout:()=>_R,title:()=>BA,umask:()=>$A,uptime:()=>LR,version:()=>VA,versions:()=>jA});function vy(e){throw new Error("Node.js process "+e+" is not supported by JSPM core outside of Node.js")}function lJ(){!Yc||!Cu||(Yc=!1,Cu.length?os=Cu.concat(os):um=-1,os.length&&wA())}function wA(){if(!Yc){var e=setTimeout(lJ,0);Yc=!0;for(var t=os.length;t;){for(Cu=os,os=[];++um1)for(var n=1;n{"use strict";m();T();N();os=[],Yc=!1,um=-1;CA.prototype.run=function(){this.fun.apply(null,this.array)};BA="browser",UA="x64",kA="browser",MA={PATH:"/usr/bin",LANG:navigator.language+".UTF-8",PWD:"/",HOME:"/home",TMP:"/tmp"},xA=["/usr/bin/node"],qA=[],VA="v16.8.0",jA={},KA=function(e,t){console.warn((t?t+": ":"")+e)},GA=function(e){vy("binding")},$A=function(e){return 0},QA=function(){return"/"},YA=function(e){},JA={name:"node",sourceUrl:"",headersUrl:"",libUrl:""};HA=hr,zA=[];XA={},ZA=!1,eR={};iR=hr,aR=hr,lm=function(){return{}},sR=lm,oR=lm,uR=hr,cR=hr,lR=hr,dR={};fR={inspector:!1,debug:!1,uv:!1,ipv6:!1,tls_alpn:!1,tls_sni:!1,tls_ocsp:!1,tls:!1,cached_builtins:!0},mR=hr,NR=hr;ER=hr,hR=hr,yR=hr,IR=hr,gR=hr,_R=void 0,vR=void 0,SR=void 0,OR=hr,DR=2,bR=1,AR="/bin/usr/node",RR=9229,PR="node",FR=[],wR=hr,Jo={now:typeof performance!="undefined"?performance.now.bind(performance):void 0,timing:typeof performance!="undefined"?performance.timing:void 0};Jo.now===void 0&&(gy=Date.now(),Jo.timing&&Jo.timing.navigationStart&&(gy=Jo.timing.navigationStart),Jo.now=()=>Date.now()-gy);_y=1e9;cm.bigint=function(e){var t=cm(e);return typeof BigInt=="undefined"?t[0]*_y+t[1]:BigInt(t[0]*_y)+BigInt(t[1])};CR=10,BR={},UR=0;kR=us,MR=us,xR=us,qR=us,VR=us,jR=hr,KR=us,GR=us;QR={version:VA,versions:jA,arch:UA,platform:kA,release:JA,_rawDebug:HA,moduleLoadList:zA,binding:GA,_linkedBinding:WA,_events:BR,_eventsCount:UR,_maxListeners:CR,on:us,addListener:kR,once:MR,off:xR,removeListener:qR,removeAllListeners:VR,emit:jR,prependListener:KR,prependOnceListener:GR,listeners:$R,domain:XA,_exiting:ZA,config:eR,dlopen:tR,uptime:LR,_getActiveRequests:nR,_getActiveHandles:rR,reallyExit:iR,_kill:aR,cpuUsage:lm,resourceUsage:sR,memoryUsage:oR,kill:uR,exit:cR,openStdin:lR,allowedNodeEnvironmentFlags:dR,assert:pR,features:fR,_fatalExceptions:mR,setUncaughtExceptionCaptureCallback:NR,hasUncaughtExceptionCaptureCallback:TR,emitWarning:KA,nextTick:LA,_tickCallback:ER,_debugProcess:hR,_debugEnd:yR,_startProfilerIdleNotifier:IR,_stopProfilerIdleNotifier:gR,stdout:_R,stdin:SR,stderr:vR,abort:OR,umask:$A,chdir:YA,cwd:QA,env:MA,title:BA,argv:xA,execArgv:qA,pid:DR,ppid:bR,execPath:AR,debugPort:RR,hrtime:cm,argv0:PR,_preload_modules:FR,setSourceMapsEnabled:wR}});var N=Lu(()=>{"use strict";YR()});function dJ(){if(JR)return gd;JR=!0,gd.byteLength=c,gd.toByteArray=p,gd.fromByteArray=g;for(var e=[],t=[],n=typeof Uint8Array!="undefined"?Uint8Array:Array,r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",i=0,a=r.length;i0)throw new Error("Invalid string. Length must be a multiple of 4");var k=v.indexOf("=");k===-1&&(k=F);var K=k===F?0:4-k%4;return[k,K]}function c(v){var F=o(v),k=F[0],K=F[1];return(k+K)*3/4-K}function l(v,F,k){return(F+k)*3/4-k}function p(v){var F,k=o(v),K=k[0],$=k[1],ne=new n(l(v,K,$)),z=0,Te=$>0?K-4:K,pe;for(pe=0;pe>16&255,ne[z++]=F>>8&255,ne[z++]=F&255;return $===2&&(F=t[v.charCodeAt(pe)]<<2|t[v.charCodeAt(pe+1)]>>4,ne[z++]=F&255),$===1&&(F=t[v.charCodeAt(pe)]<<10|t[v.charCodeAt(pe+1)]<<4|t[v.charCodeAt(pe+2)]>>2,ne[z++]=F>>8&255,ne[z++]=F&255),ne}function f(v){return e[v>>18&63]+e[v>>12&63]+e[v>>6&63]+e[v&63]}function y(v,F,k){for(var K,$=[],ne=F;neTe?Te:z+ne));return K===1?(F=v[k-1],$.push(e[F>>2]+e[F<<4&63]+"==")):K===2&&(F=(v[k-2]<<8)+v[k-1],$.push(e[F>>10]+e[F>>4&63]+e[F<<2&63]+"=")),$.join("")}return gd}function pJ(){if(HR)return dm;HR=!0;return dm.read=function(e,t,n,r,i){var a,o,c=i*8-r-1,l=(1<>1,f=-7,y=n?i-1:0,g=n?-1:1,v=e[t+y];for(y+=g,a=v&(1<<-f)-1,v>>=-f,f+=c;f>0;a=a*256+e[t+y],y+=g,f-=8);for(o=a&(1<<-f)-1,a>>=-f,f+=r;f>0;o=o*256+e[t+y],y+=g,f-=8);if(a===0)a=1-p;else{if(a===l)return o?NaN:(v?-1:1)*(1/0);o=o+Math.pow(2,r),a=a-p}return(v?-1:1)*o*Math.pow(2,a-r)},dm.write=function(e,t,n,r,i,a){var o,c,l,p=a*8-i-1,f=(1<>1,g=i===23?Math.pow(2,-24)-Math.pow(2,-77):0,v=r?0:a-1,F=r?1:-1,k=t<0||t===0&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(c=isNaN(t)?1:0,o=f):(o=Math.floor(Math.log(t)/Math.LN2),t*(l=Math.pow(2,-o))<1&&(o--,l*=2),o+y>=1?t+=g/l:t+=g*Math.pow(2,1-y),t*l>=2&&(o++,l/=2),o+y>=f?(c=0,o=f):o+y>=1?(c=(t*l-1)*Math.pow(2,i),o=o+y):(c=t*Math.pow(2,y-1)*Math.pow(2,i),o=0));i>=8;e[n+v]=c&255,v+=F,c/=256,i-=8);for(o=o<0;e[n+v]=o&255,v+=F,o/=256,p-=8);e[n+v-F]|=k*128},dm}function fJ(){if(zR)return Bu;zR=!0;let e=dJ(),t=pJ(),n=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;Bu.Buffer=o,Bu.SlowBuffer=$,Bu.INSPECT_MAX_BYTES=50;let r=2147483647;Bu.kMaxLength=r,o.TYPED_ARRAY_SUPPORT=i(),!o.TYPED_ARRAY_SUPPORT&&typeof console!="undefined"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function i(){try{let A=new Uint8Array(1),h={foo:function(){return 42}};return Object.setPrototypeOf(h,Uint8Array.prototype),Object.setPrototypeOf(A,h),A.foo()===42}catch(A){return!1}}Object.defineProperty(o.prototype,"parent",{enumerable:!0,get:function(){if(o.isBuffer(this))return this.buffer}}),Object.defineProperty(o.prototype,"offset",{enumerable:!0,get:function(){if(o.isBuffer(this))return this.byteOffset}});function a(A){if(A>r)throw new RangeError('The value "'+A+'" is invalid for option "size"');let h=new Uint8Array(A);return Object.setPrototypeOf(h,o.prototype),h}function o(A,h,I){if(typeof A=="number"){if(typeof h=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return f(A)}return c(A,h,I)}o.poolSize=8192;function c(A,h,I){if(typeof A=="string")return y(A,h);if(ArrayBuffer.isView(A))return v(A);if(A==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof A);if(xt(A,ArrayBuffer)||A&&xt(A.buffer,ArrayBuffer)||typeof SharedArrayBuffer!="undefined"&&(xt(A,SharedArrayBuffer)||A&&xt(A.buffer,SharedArrayBuffer)))return F(A,h,I);if(typeof A=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');let C=A.valueOf&&A.valueOf();if(C!=null&&C!==A)return o.from(C,h,I);let G=k(A);if(G)return G;if(typeof Symbol!="undefined"&&Symbol.toPrimitive!=null&&typeof A[Symbol.toPrimitive]=="function")return o.from(A[Symbol.toPrimitive]("string"),h,I);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof A)}o.from=function(A,h,I){return c(A,h,I)},Object.setPrototypeOf(o.prototype,Uint8Array.prototype),Object.setPrototypeOf(o,Uint8Array);function l(A){if(typeof A!="number")throw new TypeError('"size" argument must be of type number');if(A<0)throw new RangeError('The value "'+A+'" is invalid for option "size"')}function p(A,h,I){return l(A),A<=0?a(A):h!==void 0?typeof I=="string"?a(A).fill(h,I):a(A).fill(h):a(A)}o.alloc=function(A,h,I){return p(A,h,I)};function f(A){return l(A),a(A<0?0:K(A)|0)}o.allocUnsafe=function(A){return f(A)},o.allocUnsafeSlow=function(A){return f(A)};function y(A,h){if((typeof h!="string"||h==="")&&(h="utf8"),!o.isEncoding(h))throw new TypeError("Unknown encoding: "+h);let I=ne(A,h)|0,C=a(I),G=C.write(A,h);return G!==I&&(C=C.slice(0,G)),C}function g(A){let h=A.length<0?0:K(A.length)|0,I=a(h);for(let C=0;C=r)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+r.toString(16)+" bytes");return A|0}function $(A){return+A!=A&&(A=0),o.alloc(+A)}o.isBuffer=function(h){return h!=null&&h._isBuffer===!0&&h!==o.prototype},o.compare=function(h,I){if(xt(h,Uint8Array)&&(h=o.from(h,h.offset,h.byteLength)),xt(I,Uint8Array)&&(I=o.from(I,I.offset,I.byteLength)),!o.isBuffer(h)||!o.isBuffer(I))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(h===I)return 0;let C=h.length,G=I.length;for(let re=0,le=Math.min(C,G);reG.length?(o.isBuffer(le)||(le=o.from(le)),le.copy(G,re)):Uint8Array.prototype.set.call(G,le,re);else if(o.isBuffer(le))le.copy(G,re);else throw new TypeError('"list" argument must be an Array of Buffers');re+=le.length}return G};function ne(A,h){if(o.isBuffer(A))return A.length;if(ArrayBuffer.isView(A)||xt(A,ArrayBuffer))return A.byteLength;if(typeof A!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof A);let I=A.length,C=arguments.length>2&&arguments[2]===!0;if(!C&&I===0)return 0;let G=!1;for(;;)switch(h){case"ascii":case"latin1":case"binary":return I;case"utf8":case"utf-8":return za(A).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return I*2;case"hex":return I>>>1;case"base64":return pr(A).length;default:if(G)return C?-1:za(A).length;h=(""+h).toLowerCase(),G=!0}}o.byteLength=ne;function z(A,h,I){let C=!1;if((h===void 0||h<0)&&(h=0),h>this.length||((I===void 0||I>this.length)&&(I=this.length),I<=0)||(I>>>=0,h>>>=0,I<=h))return"";for(A||(A="utf8");;)switch(A){case"hex":return Rr(this,h,I);case"utf8":case"utf-8":return Wt(this,h,I);case"ascii":return dn(this,h,I);case"latin1":case"binary":return Ar(this,h,I);case"base64":return zt(this,h,I);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Un(this,h,I);default:if(C)throw new TypeError("Unknown encoding: "+A);A=(A+"").toLowerCase(),C=!0}}o.prototype._isBuffer=!0;function Te(A,h,I){let C=A[h];A[h]=A[I],A[I]=C}o.prototype.swap16=function(){let h=this.length;if(h%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let I=0;II&&(h+=" ... "),""},n&&(o.prototype[n]=o.prototype.inspect),o.prototype.compare=function(h,I,C,G,re){if(xt(h,Uint8Array)&&(h=o.from(h,h.offset,h.byteLength)),!o.isBuffer(h))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof h);if(I===void 0&&(I=0),C===void 0&&(C=h?h.length:0),G===void 0&&(G=0),re===void 0&&(re=this.length),I<0||C>h.length||G<0||re>this.length)throw new RangeError("out of range index");if(G>=re&&I>=C)return 0;if(G>=re)return-1;if(I>=C)return 1;if(I>>>=0,C>>>=0,G>>>=0,re>>>=0,this===h)return 0;let le=re-G,ft=C-I,pn=Math.min(le,ft),tn=this.slice(G,re),hn=h.slice(I,C);for(let Xt=0;Xt2147483647?I=2147483647:I<-2147483648&&(I=-2147483648),I=+I,fr(I)&&(I=G?0:A.length-1),I<0&&(I=A.length+I),I>=A.length){if(G)return-1;I=A.length-1}else if(I<0)if(G)I=0;else return-1;if(typeof h=="string"&&(h=o.from(h,C)),o.isBuffer(h))return h.length===0?-1:Fe(A,h,I,C,G);if(typeof h=="number")return h=h&255,typeof Uint8Array.prototype.indexOf=="function"?G?Uint8Array.prototype.indexOf.call(A,h,I):Uint8Array.prototype.lastIndexOf.call(A,h,I):Fe(A,[h],I,C,G);throw new TypeError("val must be string, number or Buffer")}function Fe(A,h,I,C,G){let re=1,le=A.length,ft=h.length;if(C!==void 0&&(C=String(C).toLowerCase(),C==="ucs2"||C==="ucs-2"||C==="utf16le"||C==="utf-16le")){if(A.length<2||h.length<2)return-1;re=2,le/=2,ft/=2,I/=2}function pn(hn,Xt){return re===1?hn[Xt]:hn.readUInt16BE(Xt*re)}let tn;if(G){let hn=-1;for(tn=I;tnle&&(I=le-ft),tn=I;tn>=0;tn--){let hn=!0;for(let Xt=0;XtG&&(C=G)):C=G;let re=h.length;C>re/2&&(C=re/2);let le;for(le=0;le>>0,isFinite(C)?(C=C>>>0,G===void 0&&(G="utf8")):(G=C,C=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");let re=this.length-I;if((C===void 0||C>re)&&(C=re),h.length>0&&(C<0||I<0)||I>this.length)throw new RangeError("Attempt to write outside buffer bounds");G||(G="utf8");let le=!1;for(;;)switch(G){case"hex":return Ve(this,h,I,C);case"utf8":case"utf-8":return et(this,h,I,C);case"ascii":case"latin1":case"binary":return X(this,h,I,C);case"base64":return ve(this,h,I,C);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return gt(this,h,I,C);default:if(le)throw new TypeError("Unknown encoding: "+G);G=(""+G).toLowerCase(),le=!0}},o.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function zt(A,h,I){return h===0&&I===A.length?e.fromByteArray(A):e.fromByteArray(A.slice(h,I))}function Wt(A,h,I){I=Math.min(A.length,I);let C=[],G=h;for(;G239?4:re>223?3:re>191?2:1;if(G+ft<=I){let pn,tn,hn,Xt;switch(ft){case 1:re<128&&(le=re);break;case 2:pn=A[G+1],(pn&192)===128&&(Xt=(re&31)<<6|pn&63,Xt>127&&(le=Xt));break;case 3:pn=A[G+1],tn=A[G+2],(pn&192)===128&&(tn&192)===128&&(Xt=(re&15)<<12|(pn&63)<<6|tn&63,Xt>2047&&(Xt<55296||Xt>57343)&&(le=Xt));break;case 4:pn=A[G+1],tn=A[G+2],hn=A[G+3],(pn&192)===128&&(tn&192)===128&&(hn&192)===128&&(Xt=(re&15)<<18|(pn&63)<<12|(tn&63)<<6|hn&63,Xt>65535&&Xt<1114112&&(le=Xt))}}le===null?(le=65533,ft=1):le>65535&&(le-=65536,C.push(le>>>10&1023|55296),le=56320|le&1023),C.push(le),G+=ft}return Vt(C)}let Dn=4096;function Vt(A){let h=A.length;if(h<=Dn)return String.fromCharCode.apply(String,A);let I="",C=0;for(;CC)&&(I=C);let G="";for(let re=h;reC&&(h=C),I<0?(I+=C,I<0&&(I=0)):I>C&&(I=C),II)throw new RangeError("Trying to access beyond buffer length")}o.prototype.readUintLE=o.prototype.readUIntLE=function(h,I,C){h=h>>>0,I=I>>>0,C||$t(h,I,this.length);let G=this[h],re=1,le=0;for(;++le>>0,I=I>>>0,C||$t(h,I,this.length);let G=this[h+--I],re=1;for(;I>0&&(re*=256);)G+=this[h+--I]*re;return G},o.prototype.readUint8=o.prototype.readUInt8=function(h,I){return h=h>>>0,I||$t(h,1,this.length),this[h]},o.prototype.readUint16LE=o.prototype.readUInt16LE=function(h,I){return h=h>>>0,I||$t(h,2,this.length),this[h]|this[h+1]<<8},o.prototype.readUint16BE=o.prototype.readUInt16BE=function(h,I){return h=h>>>0,I||$t(h,2,this.length),this[h]<<8|this[h+1]},o.prototype.readUint32LE=o.prototype.readUInt32LE=function(h,I){return h=h>>>0,I||$t(h,4,this.length),(this[h]|this[h+1]<<8|this[h+2]<<16)+this[h+3]*16777216},o.prototype.readUint32BE=o.prototype.readUInt32BE=function(h,I){return h=h>>>0,I||$t(h,4,this.length),this[h]*16777216+(this[h+1]<<16|this[h+2]<<8|this[h+3])},o.prototype.readBigUInt64LE=ya(function(h){h=h>>>0,tt(h,"offset");let I=this[h],C=this[h+7];(I===void 0||C===void 0)&&At(h,this.length-8);let G=I+this[++h]*nn(2,8)+this[++h]*nn(2,16)+this[++h]*nn(2,24),re=this[++h]+this[++h]*nn(2,8)+this[++h]*nn(2,16)+C*nn(2,24);return BigInt(G)+(BigInt(re)<>>0,tt(h,"offset");let I=this[h],C=this[h+7];(I===void 0||C===void 0)&&At(h,this.length-8);let G=I*nn(2,24)+this[++h]*nn(2,16)+this[++h]*nn(2,8)+this[++h],re=this[++h]*nn(2,24)+this[++h]*nn(2,16)+this[++h]*nn(2,8)+C;return(BigInt(G)<>>0,I=I>>>0,C||$t(h,I,this.length);let G=this[h],re=1,le=0;for(;++le=re&&(G-=Math.pow(2,8*I)),G},o.prototype.readIntBE=function(h,I,C){h=h>>>0,I=I>>>0,C||$t(h,I,this.length);let G=I,re=1,le=this[h+--G];for(;G>0&&(re*=256);)le+=this[h+--G]*re;return re*=128,le>=re&&(le-=Math.pow(2,8*I)),le},o.prototype.readInt8=function(h,I){return h=h>>>0,I||$t(h,1,this.length),this[h]&128?(255-this[h]+1)*-1:this[h]},o.prototype.readInt16LE=function(h,I){h=h>>>0,I||$t(h,2,this.length);let C=this[h]|this[h+1]<<8;return C&32768?C|4294901760:C},o.prototype.readInt16BE=function(h,I){h=h>>>0,I||$t(h,2,this.length);let C=this[h+1]|this[h]<<8;return C&32768?C|4294901760:C},o.prototype.readInt32LE=function(h,I){return h=h>>>0,I||$t(h,4,this.length),this[h]|this[h+1]<<8|this[h+2]<<16|this[h+3]<<24},o.prototype.readInt32BE=function(h,I){return h=h>>>0,I||$t(h,4,this.length),this[h]<<24|this[h+1]<<16|this[h+2]<<8|this[h+3]},o.prototype.readBigInt64LE=ya(function(h){h=h>>>0,tt(h,"offset");let I=this[h],C=this[h+7];(I===void 0||C===void 0)&&At(h,this.length-8);let G=this[h+4]+this[h+5]*nn(2,8)+this[h+6]*nn(2,16)+(C<<24);return(BigInt(G)<>>0,tt(h,"offset");let I=this[h],C=this[h+7];(I===void 0||C===void 0)&&At(h,this.length-8);let G=(I<<24)+this[++h]*nn(2,16)+this[++h]*nn(2,8)+this[++h];return(BigInt(G)<>>0,I||$t(h,4,this.length),t.read(this,h,!0,23,4)},o.prototype.readFloatBE=function(h,I){return h=h>>>0,I||$t(h,4,this.length),t.read(this,h,!1,23,4)},o.prototype.readDoubleLE=function(h,I){return h=h>>>0,I||$t(h,8,this.length),t.read(this,h,!0,52,8)},o.prototype.readDoubleBE=function(h,I){return h=h>>>0,I||$t(h,8,this.length),t.read(this,h,!1,52,8)};function bn(A,h,I,C,G,re){if(!o.isBuffer(A))throw new TypeError('"buffer" argument must be a Buffer instance');if(h>G||hA.length)throw new RangeError("Index out of range")}o.prototype.writeUintLE=o.prototype.writeUIntLE=function(h,I,C,G){if(h=+h,I=I>>>0,C=C>>>0,!G){let ft=Math.pow(2,8*C)-1;bn(this,h,I,C,ft,0)}let re=1,le=0;for(this[I]=h&255;++le>>0,C=C>>>0,!G){let ft=Math.pow(2,8*C)-1;bn(this,h,I,C,ft,0)}let re=C-1,le=1;for(this[I+re]=h&255;--re>=0&&(le*=256);)this[I+re]=h/le&255;return I+C},o.prototype.writeUint8=o.prototype.writeUInt8=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,1,255,0),this[I]=h&255,I+1},o.prototype.writeUint16LE=o.prototype.writeUInt16LE=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,2,65535,0),this[I]=h&255,this[I+1]=h>>>8,I+2},o.prototype.writeUint16BE=o.prototype.writeUInt16BE=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,2,65535,0),this[I]=h>>>8,this[I+1]=h&255,I+2},o.prototype.writeUint32LE=o.prototype.writeUInt32LE=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,4,4294967295,0),this[I+3]=h>>>24,this[I+2]=h>>>16,this[I+1]=h>>>8,this[I]=h&255,I+4},o.prototype.writeUint32BE=o.prototype.writeUInt32BE=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,4,4294967295,0),this[I]=h>>>24,this[I+1]=h>>>16,this[I+2]=h>>>8,this[I+3]=h&255,I+4};function oe(A,h,I,C,G){Lt(h,C,G,A,I,7);let re=Number(h&BigInt(4294967295));A[I++]=re,re=re>>8,A[I++]=re,re=re>>8,A[I++]=re,re=re>>8,A[I++]=re;let le=Number(h>>BigInt(32)&BigInt(4294967295));return A[I++]=le,le=le>>8,A[I++]=le,le=le>>8,A[I++]=le,le=le>>8,A[I++]=le,I}function De(A,h,I,C,G){Lt(h,C,G,A,I,7);let re=Number(h&BigInt(4294967295));A[I+7]=re,re=re>>8,A[I+6]=re,re=re>>8,A[I+5]=re,re=re>>8,A[I+4]=re;let le=Number(h>>BigInt(32)&BigInt(4294967295));return A[I+3]=le,le=le>>8,A[I+2]=le,le=le>>8,A[I+1]=le,le=le>>8,A[I]=le,I+8}o.prototype.writeBigUInt64LE=ya(function(h,I=0){return oe(this,h,I,BigInt(0),BigInt("0xffffffffffffffff"))}),o.prototype.writeBigUInt64BE=ya(function(h,I=0){return De(this,h,I,BigInt(0),BigInt("0xffffffffffffffff"))}),o.prototype.writeIntLE=function(h,I,C,G){if(h=+h,I=I>>>0,!G){let pn=Math.pow(2,8*C-1);bn(this,h,I,C,pn-1,-pn)}let re=0,le=1,ft=0;for(this[I]=h&255;++re>0)-ft&255;return I+C},o.prototype.writeIntBE=function(h,I,C,G){if(h=+h,I=I>>>0,!G){let pn=Math.pow(2,8*C-1);bn(this,h,I,C,pn-1,-pn)}let re=C-1,le=1,ft=0;for(this[I+re]=h&255;--re>=0&&(le*=256);)h<0&&ft===0&&this[I+re+1]!==0&&(ft=1),this[I+re]=(h/le>>0)-ft&255;return I+C},o.prototype.writeInt8=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,1,127,-128),h<0&&(h=255+h+1),this[I]=h&255,I+1},o.prototype.writeInt16LE=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,2,32767,-32768),this[I]=h&255,this[I+1]=h>>>8,I+2},o.prototype.writeInt16BE=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,2,32767,-32768),this[I]=h>>>8,this[I+1]=h&255,I+2},o.prototype.writeInt32LE=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,4,2147483647,-2147483648),this[I]=h&255,this[I+1]=h>>>8,this[I+2]=h>>>16,this[I+3]=h>>>24,I+4},o.prototype.writeInt32BE=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,4,2147483647,-2147483648),h<0&&(h=4294967295+h+1),this[I]=h>>>24,this[I+1]=h>>>16,this[I+2]=h>>>8,this[I+3]=h&255,I+4},o.prototype.writeBigInt64LE=ya(function(h,I=0){return oe(this,h,I,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),o.prototype.writeBigInt64BE=ya(function(h,I=0){return De(this,h,I,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function _e(A,h,I,C,G,re){if(I+C>A.length)throw new RangeError("Index out of range");if(I<0)throw new RangeError("Index out of range")}function Ce(A,h,I,C,G){return h=+h,I=I>>>0,G||_e(A,h,I,4),t.write(A,h,I,C,23,4),I+4}o.prototype.writeFloatLE=function(h,I,C){return Ce(this,h,I,!0,C)},o.prototype.writeFloatBE=function(h,I,C){return Ce(this,h,I,!1,C)};function _t(A,h,I,C,G){return h=+h,I=I>>>0,G||_e(A,h,I,8),t.write(A,h,I,C,52,8),I+8}o.prototype.writeDoubleLE=function(h,I,C){return _t(this,h,I,!0,C)},o.prototype.writeDoubleBE=function(h,I,C){return _t(this,h,I,!1,C)},o.prototype.copy=function(h,I,C,G){if(!o.isBuffer(h))throw new TypeError("argument should be a Buffer");if(C||(C=0),!G&&G!==0&&(G=this.length),I>=h.length&&(I=h.length),I||(I=0),G>0&&G=this.length)throw new RangeError("Index out of range");if(G<0)throw new RangeError("sourceEnd out of bounds");G>this.length&&(G=this.length),h.length-I>>0,C=C===void 0?this.length:C>>>0,h||(h=0);let re;if(typeof h=="number")for(re=I;renn(2,32)?G=xe(String(I)):typeof I=="bigint"&&(G=String(I),(I>nn(BigInt(2),BigInt(32))||I<-nn(BigInt(2),BigInt(32)))&&(G=xe(G)),G+="n"),C+=` It must be ${h}. Received ${G}`,C},RangeError);function xe(A){let h="",I=A.length,C=A[0]==="-"?1:0;for(;I>=C+4;I-=3)h=`_${A.slice(I-3,I)}${h}`;return`${A.slice(0,I)}${h}`}function Qe(A,h,I){tt(h,"offset"),(A[h]===void 0||A[h+I]===void 0)&&At(h,A.length-(I+1))}function Lt(A,h,I,C,G,re){if(A>I||A3?h===0||h===BigInt(0)?ft=`>= 0${le} and < 2${le} ** ${(re+1)*8}${le}`:ft=`>= -(2${le} ** ${(re+1)*8-1}${le}) and < 2 ** ${(re+1)*8-1}${le}`:ft=`>= ${h}${le} and <= ${I}${le}`,new J.ERR_OUT_OF_RANGE("value",ft,A)}Qe(C,G,re)}function tt(A,h){if(typeof A!="number")throw new J.ERR_INVALID_ARG_TYPE(h,"number",A)}function At(A,h,I){throw Math.floor(A)!==A?(tt(A,I),new J.ERR_OUT_OF_RANGE(I||"offset","an integer",A)):h<0?new J.ERR_BUFFER_OUT_OF_BOUNDS:new J.ERR_OUT_OF_RANGE(I||"offset",`>= ${I?1:0} and <= ${h}`,A)}let Ha=/[^+/0-9A-Za-z-_]/g;function xr(A){if(A=A.split("=")[0],A=A.trim().replace(Ha,""),A.length<2)return"";for(;A.length%4!==0;)A=A+"=";return A}function za(A,h){h=h||1/0;let I,C=A.length,G=null,re=[];for(let le=0;le55295&&I<57344){if(!G){if(I>56319){(h-=3)>-1&&re.push(239,191,189);continue}else if(le+1===C){(h-=3)>-1&&re.push(239,191,189);continue}G=I;continue}if(I<56320){(h-=3)>-1&&re.push(239,191,189),G=I;continue}I=(G-55296<<10|I-56320)+65536}else G&&(h-=3)>-1&&re.push(239,191,189);if(G=null,I<128){if((h-=1)<0)break;re.push(I)}else if(I<2048){if((h-=2)<0)break;re.push(I>>6|192,I&63|128)}else if(I<65536){if((h-=3)<0)break;re.push(I>>12|224,I>>6&63|128,I&63|128)}else if(I<1114112){if((h-=4)<0)break;re.push(I>>18|240,I>>12&63|128,I>>6&63|128,I&63|128)}else throw new Error("Invalid code point")}return re}function Lc(A){let h=[];for(let I=0;I>8,G=I%256,re.push(G),re.push(C);return re}function pr(A){return e.toByteArray(xr(A))}function ni(A,h,I,C){let G;for(G=0;G=h.length||G>=A.length);++G)h[G+I]=A[G];return G}function xt(A,h){return A instanceof h||A!=null&&A.constructor!=null&&A.constructor.name!=null&&A.constructor.name===h.name}function fr(A){return A!==A}let _u=function(){let A="0123456789abcdef",h=new Array(256);for(let I=0;I<16;++I){let C=I*16;for(let G=0;G<16;++G)h[C+G]=A[I]+A[G]}return h}();function ya(A){return typeof BigInt=="undefined"?vu:A}function vu(){throw new Error("BigInt not supported")}return Bu}var gd,JR,dm,HR,Bu,zR,Uu,D,Fde,wde,WR=Lu(()=>{"use strict";m();T();N();gd={},JR=!1;dm={},HR=!1;Bu={},zR=!1;Uu=fJ();Uu.Buffer;Uu.SlowBuffer;Uu.INSPECT_MAX_BYTES;Uu.kMaxLength;D=Uu.Buffer,Fde=Uu.INSPECT_MAX_BYTES,wde=Uu.kMaxLength});var T=Lu(()=>{"use strict";WR()});var XR=w(Jc=>{"use strict";m();T();N();Object.defineProperty(Jc,"__esModule",{value:!0});Jc.versionInfo=Jc.version=void 0;var mJ="16.9.0";Jc.version=mJ;var NJ=Object.freeze({major:16,minor:9,patch:0,preReleaseTag:null});Jc.versionInfo=NJ});var Lr=w(Sy=>{"use strict";m();T();N();Object.defineProperty(Sy,"__esModule",{value:!0});Sy.devAssert=TJ;function TJ(e,t){if(!!!e)throw new Error(t)}});var pm=w(Oy=>{"use strict";m();T();N();Object.defineProperty(Oy,"__esModule",{value:!0});Oy.isPromise=EJ;function EJ(e){return typeof(e==null?void 0:e.then)=="function"}});var va=w(Dy=>{"use strict";m();T();N();Object.defineProperty(Dy,"__esModule",{value:!0});Dy.isObjectLike=hJ;function hJ(e){return typeof e=="object"&&e!==null}});var yr=w(by=>{"use strict";m();T();N();Object.defineProperty(by,"__esModule",{value:!0});by.invariant=yJ;function yJ(e,t){if(!!!e)throw new Error(t!=null?t:"Unexpected invariant triggered.")}});var fm=w(Ay=>{"use strict";m();T();N();Object.defineProperty(Ay,"__esModule",{value:!0});Ay.getLocation=_J;var IJ=yr(),gJ=/\r\n|[\n\r]/g;function _J(e,t){let n=0,r=1;for(let i of e.body.matchAll(gJ)){if(typeof i.index=="number"||(0,IJ.invariant)(!1),i.index>=t)break;n=i.index+i[0].length,r+=1}return{line:r,column:t+1-n}}});var Ry=w(mm=>{"use strict";m();T();N();Object.defineProperty(mm,"__esModule",{value:!0});mm.printLocation=SJ;mm.printSourceLocation=eP;var vJ=fm();function SJ(e){return eP(e.source,(0,vJ.getLocation)(e.source,e.start))}function eP(e,t){let n=e.locationOffset.column-1,r="".padStart(n)+e.body,i=t.line-1,a=e.locationOffset.line-1,o=t.line+a,c=t.line===1?n:0,l=t.column+c,p=`${e.name}:${o}:${l} -`,f=r.split(/\r\n|[\n\r]/g),y=f[i];if(y.length>120){let g=Math.floor(l/80),v=l%80,F=[];for(let k=0;k["|",k]),["|","^".padStart(v)],["|",F[g+1]]])}return p+ZR([[`${o-1} |`,f[i-1]],[`${o} |`,y],["|","^".padStart(l)],[`${o+1} |`,f[i+1]]])}function ZR(e){let t=e.filter(([r,i])=>i!==void 0),n=Math.max(...t.map(([r])=>r.length));return t.map(([r,i])=>r.padStart(n)+(i?" "+i:"")).join(` -`)}});var He=w(Hc=>{"use strict";m();T();N();Object.defineProperty(Hc,"__esModule",{value:!0});Hc.GraphQLError=void 0;Hc.formatError=AJ;Hc.printError=bJ;var OJ=va(),tP=fm(),nP=Ry();function DJ(e){let t=e[0];return t==null||"kind"in t||"length"in t?{nodes:t,source:e[1],positions:e[2],path:e[3],originalError:e[4],extensions:e[5]}:t}var Py=class e extends Error{constructor(t,...n){var r,i,a;let{nodes:o,source:c,positions:l,path:p,originalError:f,extensions:y}=DJ(n);super(t),this.name="GraphQLError",this.path=p!=null?p:void 0,this.originalError=f!=null?f:void 0,this.nodes=rP(Array.isArray(o)?o:o?[o]:void 0);let g=rP((r=this.nodes)===null||r===void 0?void 0:r.map(F=>F.loc).filter(F=>F!=null));this.source=c!=null?c:g==null||(i=g[0])===null||i===void 0?void 0:i.source,this.positions=l!=null?l:g==null?void 0:g.map(F=>F.start),this.locations=l&&c?l.map(F=>(0,tP.getLocation)(c,F)):g==null?void 0:g.map(F=>(0,tP.getLocation)(F.source,F.start));let v=(0,OJ.isObjectLike)(f==null?void 0:f.extensions)?f==null?void 0:f.extensions:void 0;this.extensions=(a=y!=null?y:v)!==null&&a!==void 0?a:Object.create(null),Object.defineProperties(this,{message:{writable:!0,enumerable:!0},name:{enumerable:!1},nodes:{enumerable:!1},source:{enumerable:!1},positions:{enumerable:!1},originalError:{enumerable:!1}}),f!=null&&f.stack?Object.defineProperty(this,"stack",{value:f.stack,writable:!0,configurable:!0}):Error.captureStackTrace?Error.captureStackTrace(this,e):Object.defineProperty(this,"stack",{value:Error().stack,writable:!0,configurable:!0})}get[Symbol.toStringTag](){return"GraphQLError"}toString(){let t=this.message;if(this.nodes)for(let n of this.nodes)n.loc&&(t+=` +"use strict";var shim=(()=>{var rJ=Object.create;var Id=Object.defineProperty,iJ=Object.defineProperties,aJ=Object.getOwnPropertyDescriptor,sJ=Object.getOwnPropertyDescriptors,oJ=Object.getOwnPropertyNames,RA=Object.getOwnPropertySymbols,uJ=Object.getPrototypeOf,PA=Object.prototype.hasOwnProperty,cJ=Object.prototype.propertyIsEnumerable;var nn=Math.pow,Iy=(e,t,n)=>t in e?Id(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,x=(e,t)=>{for(var n in t||(t={}))PA.call(t,n)&&Iy(e,n,t[n]);if(RA)for(var n of RA(t))cJ.call(t,n)&&Iy(e,n,t[n]);return e},Y=(e,t)=>iJ(e,sJ(t));var Lu=(e,t)=>()=>(e&&(t=e(e=0)),t);var w=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),sm=(e,t)=>{for(var n in t)Id(e,n,{get:t[n],enumerable:!0})},FA=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of oJ(t))!PA.call(e,i)&&i!==n&&Id(e,i,{get:()=>t[i],enumerable:!(r=aJ(t,i))||r.enumerable});return e};var ss=(e,t,n)=>(n=e!=null?rJ(uJ(e)):{},FA(t||!e||!e.__esModule?Id(n,"default",{value:e,enumerable:!0}):n,e)),om=e=>FA(Id({},"__esModule",{value:!0}),e);var _=(e,t,n)=>(Iy(e,typeof t!="symbol"?t+"":t,n),n);var vi=(e,t,n)=>new Promise((r,i)=>{var a=l=>{try{c(n.next(l))}catch(p){i(p)}},o=l=>{try{c(n.throw(l))}catch(p){i(p)}},c=l=>l.done?r(l.value):Promise.resolve(l.value).then(a,o);c((n=n.apply(e,t)).next())});var m=Lu(()=>{"use strict"});var O={};sm(O,{_debugEnd:()=>yR,_debugProcess:()=>hR,_events:()=>BR,_eventsCount:()=>UR,_exiting:()=>ZA,_fatalExceptions:()=>mR,_getActiveHandles:()=>rR,_getActiveRequests:()=>nR,_kill:()=>aR,_linkedBinding:()=>WA,_maxListeners:()=>CR,_preload_modules:()=>FR,_rawDebug:()=>HA,_startProfilerIdleNotifier:()=>IR,_stopProfilerIdleNotifier:()=>gR,_tickCallback:()=>ER,abort:()=>OR,addListener:()=>kR,allowedNodeEnvironmentFlags:()=>dR,arch:()=>UA,argv:()=>xA,argv0:()=>PR,assert:()=>pR,binding:()=>GA,chdir:()=>YA,config:()=>eR,cpuUsage:()=>lm,cwd:()=>QA,debugPort:()=>RR,default:()=>QR,dlopen:()=>tR,domain:()=>XA,emit:()=>jR,emitWarning:()=>KA,env:()=>MA,execArgv:()=>qA,execPath:()=>AR,exit:()=>cR,features:()=>fR,hasUncaughtExceptionCaptureCallback:()=>TR,hrtime:()=>cm,kill:()=>uR,listeners:()=>$R,memoryUsage:()=>oR,moduleLoadList:()=>zA,nextTick:()=>LA,off:()=>xR,on:()=>us,once:()=>MR,openStdin:()=>lR,pid:()=>DR,platform:()=>kA,ppid:()=>bR,prependListener:()=>KR,prependOnceListener:()=>GR,reallyExit:()=>iR,release:()=>JA,removeAllListeners:()=>VR,removeListener:()=>qR,resourceUsage:()=>sR,setSourceMapsEnabled:()=>wR,setUncaughtExceptionCaptureCallback:()=>NR,stderr:()=>vR,stdin:()=>SR,stdout:()=>_R,title:()=>BA,umask:()=>$A,uptime:()=>LR,version:()=>VA,versions:()=>jA});function vy(e){throw new Error("Node.js process "+e+" is not supported by JSPM core outside of Node.js")}function lJ(){!Yc||!Cu||(Yc=!1,Cu.length?os=Cu.concat(os):um=-1,os.length&&wA())}function wA(){if(!Yc){var e=setTimeout(lJ,0);Yc=!0;for(var t=os.length;t;){for(Cu=os,os=[];++um1)for(var n=1;n{"use strict";m();T();N();os=[],Yc=!1,um=-1;CA.prototype.run=function(){this.fun.apply(null,this.array)};BA="browser",UA="x64",kA="browser",MA={PATH:"/usr/bin",LANG:navigator.language+".UTF-8",PWD:"/",HOME:"/home",TMP:"/tmp"},xA=["/usr/bin/node"],qA=[],VA="v16.8.0",jA={},KA=function(e,t){console.warn((t?t+": ":"")+e)},GA=function(e){vy("binding")},$A=function(e){return 0},QA=function(){return"/"},YA=function(e){},JA={name:"node",sourceUrl:"",headersUrl:"",libUrl:""};HA=hr,zA=[];XA={},ZA=!1,eR={};iR=hr,aR=hr,lm=function(){return{}},sR=lm,oR=lm,uR=hr,cR=hr,lR=hr,dR={};fR={inspector:!1,debug:!1,uv:!1,ipv6:!1,tls_alpn:!1,tls_sni:!1,tls_ocsp:!1,tls:!1,cached_builtins:!0},mR=hr,NR=hr;ER=hr,hR=hr,yR=hr,IR=hr,gR=hr,_R=void 0,vR=void 0,SR=void 0,OR=hr,DR=2,bR=1,AR="/bin/usr/node",RR=9229,PR="node",FR=[],wR=hr,Jo={now:typeof performance!="undefined"?performance.now.bind(performance):void 0,timing:typeof performance!="undefined"?performance.timing:void 0};Jo.now===void 0&&(gy=Date.now(),Jo.timing&&Jo.timing.navigationStart&&(gy=Jo.timing.navigationStart),Jo.now=()=>Date.now()-gy);_y=1e9;cm.bigint=function(e){var t=cm(e);return typeof BigInt=="undefined"?t[0]*_y+t[1]:BigInt(t[0]*_y)+BigInt(t[1])};CR=10,BR={},UR=0;kR=us,MR=us,xR=us,qR=us,VR=us,jR=hr,KR=us,GR=us;QR={version:VA,versions:jA,arch:UA,platform:kA,release:JA,_rawDebug:HA,moduleLoadList:zA,binding:GA,_linkedBinding:WA,_events:BR,_eventsCount:UR,_maxListeners:CR,on:us,addListener:kR,once:MR,off:xR,removeListener:qR,removeAllListeners:VR,emit:jR,prependListener:KR,prependOnceListener:GR,listeners:$R,domain:XA,_exiting:ZA,config:eR,dlopen:tR,uptime:LR,_getActiveRequests:nR,_getActiveHandles:rR,reallyExit:iR,_kill:aR,cpuUsage:lm,resourceUsage:sR,memoryUsage:oR,kill:uR,exit:cR,openStdin:lR,allowedNodeEnvironmentFlags:dR,assert:pR,features:fR,_fatalExceptions:mR,setUncaughtExceptionCaptureCallback:NR,hasUncaughtExceptionCaptureCallback:TR,emitWarning:KA,nextTick:LA,_tickCallback:ER,_debugProcess:hR,_debugEnd:yR,_startProfilerIdleNotifier:IR,_stopProfilerIdleNotifier:gR,stdout:_R,stdin:SR,stderr:vR,abort:OR,umask:$A,chdir:YA,cwd:QA,env:MA,title:BA,argv:xA,execArgv:qA,pid:DR,ppid:bR,execPath:AR,debugPort:RR,hrtime:cm,argv0:PR,_preload_modules:FR,setSourceMapsEnabled:wR}});var N=Lu(()=>{"use strict";YR()});function dJ(){if(JR)return gd;JR=!0,gd.byteLength=c,gd.toByteArray=p,gd.fromByteArray=g;for(var e=[],t=[],n=typeof Uint8Array!="undefined"?Uint8Array:Array,r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",i=0,a=r.length;i0)throw new Error("Invalid string. Length must be a multiple of 4");var U=v.indexOf("=");U===-1&&(U=P);var K=U===P?0:4-U%4;return[U,K]}function c(v){var P=o(v),U=P[0],K=P[1];return(U+K)*3/4-K}function l(v,P,U){return(P+U)*3/4-U}function p(v){var P,U=o(v),K=U[0],$=U[1],ne=new n(l(v,K,$)),z=0,Te=$>0?K-4:K,pe;for(pe=0;pe>16&255,ne[z++]=P>>8&255,ne[z++]=P&255;return $===2&&(P=t[v.charCodeAt(pe)]<<2|t[v.charCodeAt(pe+1)]>>4,ne[z++]=P&255),$===1&&(P=t[v.charCodeAt(pe)]<<10|t[v.charCodeAt(pe+1)]<<4|t[v.charCodeAt(pe+2)]>>2,ne[z++]=P>>8&255,ne[z++]=P&255),ne}function f(v){return e[v>>18&63]+e[v>>12&63]+e[v>>6&63]+e[v&63]}function y(v,P,U){for(var K,$=[],ne=P;neTe?Te:z+ne));return K===1?(P=v[U-1],$.push(e[P>>2]+e[P<<4&63]+"==")):K===2&&(P=(v[U-2]<<8)+v[U-1],$.push(e[P>>10]+e[P>>4&63]+e[P<<2&63]+"=")),$.join("")}return gd}function pJ(){if(HR)return dm;HR=!0;return dm.read=function(e,t,n,r,i){var a,o,c=i*8-r-1,l=(1<>1,f=-7,y=n?i-1:0,g=n?-1:1,v=e[t+y];for(y+=g,a=v&(1<<-f)-1,v>>=-f,f+=c;f>0;a=a*256+e[t+y],y+=g,f-=8);for(o=a&(1<<-f)-1,a>>=-f,f+=r;f>0;o=o*256+e[t+y],y+=g,f-=8);if(a===0)a=1-p;else{if(a===l)return o?NaN:(v?-1:1)*(1/0);o=o+Math.pow(2,r),a=a-p}return(v?-1:1)*o*Math.pow(2,a-r)},dm.write=function(e,t,n,r,i,a){var o,c,l,p=a*8-i-1,f=(1<>1,g=i===23?Math.pow(2,-24)-Math.pow(2,-77):0,v=r?0:a-1,P=r?1:-1,U=t<0||t===0&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(c=isNaN(t)?1:0,o=f):(o=Math.floor(Math.log(t)/Math.LN2),t*(l=Math.pow(2,-o))<1&&(o--,l*=2),o+y>=1?t+=g/l:t+=g*Math.pow(2,1-y),t*l>=2&&(o++,l/=2),o+y>=f?(c=0,o=f):o+y>=1?(c=(t*l-1)*Math.pow(2,i),o=o+y):(c=t*Math.pow(2,y-1)*Math.pow(2,i),o=0));i>=8;e[n+v]=c&255,v+=P,c/=256,i-=8);for(o=o<0;e[n+v]=o&255,v+=P,o/=256,p-=8);e[n+v-P]|=U*128},dm}function fJ(){if(zR)return Bu;zR=!0;let e=dJ(),t=pJ(),n=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;Bu.Buffer=o,Bu.SlowBuffer=$,Bu.INSPECT_MAX_BYTES=50;let r=2147483647;Bu.kMaxLength=r,o.TYPED_ARRAY_SUPPORT=i(),!o.TYPED_ARRAY_SUPPORT&&typeof console!="undefined"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function i(){try{let A=new Uint8Array(1),h={foo:function(){return 42}};return Object.setPrototypeOf(h,Uint8Array.prototype),Object.setPrototypeOf(A,h),A.foo()===42}catch(A){return!1}}Object.defineProperty(o.prototype,"parent",{enumerable:!0,get:function(){if(o.isBuffer(this))return this.buffer}}),Object.defineProperty(o.prototype,"offset",{enumerable:!0,get:function(){if(o.isBuffer(this))return this.byteOffset}});function a(A){if(A>r)throw new RangeError('The value "'+A+'" is invalid for option "size"');let h=new Uint8Array(A);return Object.setPrototypeOf(h,o.prototype),h}function o(A,h,I){if(typeof A=="number"){if(typeof h=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return f(A)}return c(A,h,I)}o.poolSize=8192;function c(A,h,I){if(typeof A=="string")return y(A,h);if(ArrayBuffer.isView(A))return v(A);if(A==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof A);if(xt(A,ArrayBuffer)||A&&xt(A.buffer,ArrayBuffer)||typeof SharedArrayBuffer!="undefined"&&(xt(A,SharedArrayBuffer)||A&&xt(A.buffer,SharedArrayBuffer)))return P(A,h,I);if(typeof A=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');let C=A.valueOf&&A.valueOf();if(C!=null&&C!==A)return o.from(C,h,I);let G=U(A);if(G)return G;if(typeof Symbol!="undefined"&&Symbol.toPrimitive!=null&&typeof A[Symbol.toPrimitive]=="function")return o.from(A[Symbol.toPrimitive]("string"),h,I);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof A)}o.from=function(A,h,I){return c(A,h,I)},Object.setPrototypeOf(o.prototype,Uint8Array.prototype),Object.setPrototypeOf(o,Uint8Array);function l(A){if(typeof A!="number")throw new TypeError('"size" argument must be of type number');if(A<0)throw new RangeError('The value "'+A+'" is invalid for option "size"')}function p(A,h,I){return l(A),A<=0?a(A):h!==void 0?typeof I=="string"?a(A).fill(h,I):a(A).fill(h):a(A)}o.alloc=function(A,h,I){return p(A,h,I)};function f(A){return l(A),a(A<0?0:K(A)|0)}o.allocUnsafe=function(A){return f(A)},o.allocUnsafeSlow=function(A){return f(A)};function y(A,h){if((typeof h!="string"||h==="")&&(h="utf8"),!o.isEncoding(h))throw new TypeError("Unknown encoding: "+h);let I=ne(A,h)|0,C=a(I),G=C.write(A,h);return G!==I&&(C=C.slice(0,G)),C}function g(A){let h=A.length<0?0:K(A.length)|0,I=a(h);for(let C=0;C=r)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+r.toString(16)+" bytes");return A|0}function $(A){return+A!=A&&(A=0),o.alloc(+A)}o.isBuffer=function(h){return h!=null&&h._isBuffer===!0&&h!==o.prototype},o.compare=function(h,I){if(xt(h,Uint8Array)&&(h=o.from(h,h.offset,h.byteLength)),xt(I,Uint8Array)&&(I=o.from(I,I.offset,I.byteLength)),!o.isBuffer(h)||!o.isBuffer(I))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(h===I)return 0;let C=h.length,G=I.length;for(let re=0,le=Math.min(C,G);reG.length?(o.isBuffer(le)||(le=o.from(le)),le.copy(G,re)):Uint8Array.prototype.set.call(G,le,re);else if(o.isBuffer(le))le.copy(G,re);else throw new TypeError('"list" argument must be an Array of Buffers');re+=le.length}return G};function ne(A,h){if(o.isBuffer(A))return A.length;if(ArrayBuffer.isView(A)||xt(A,ArrayBuffer))return A.byteLength;if(typeof A!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof A);let I=A.length,C=arguments.length>2&&arguments[2]===!0;if(!C&&I===0)return 0;let G=!1;for(;;)switch(h){case"ascii":case"latin1":case"binary":return I;case"utf8":case"utf-8":return za(A).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return I*2;case"hex":return I>>>1;case"base64":return pr(A).length;default:if(G)return C?-1:za(A).length;h=(""+h).toLowerCase(),G=!0}}o.byteLength=ne;function z(A,h,I){let C=!1;if((h===void 0||h<0)&&(h=0),h>this.length||((I===void 0||I>this.length)&&(I=this.length),I<=0)||(I>>>=0,h>>>=0,I<=h))return"";for(A||(A="utf8");;)switch(A){case"hex":return Rr(this,h,I);case"utf8":case"utf-8":return Wt(this,h,I);case"ascii":return dn(this,h,I);case"latin1":case"binary":return Ar(this,h,I);case"base64":return zt(this,h,I);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Un(this,h,I);default:if(C)throw new TypeError("Unknown encoding: "+A);A=(A+"").toLowerCase(),C=!0}}o.prototype._isBuffer=!0;function Te(A,h,I){let C=A[h];A[h]=A[I],A[I]=C}o.prototype.swap16=function(){let h=this.length;if(h%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let I=0;II&&(h+=" ... "),""},n&&(o.prototype[n]=o.prototype.inspect),o.prototype.compare=function(h,I,C,G,re){if(xt(h,Uint8Array)&&(h=o.from(h,h.offset,h.byteLength)),!o.isBuffer(h))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof h);if(I===void 0&&(I=0),C===void 0&&(C=h?h.length:0),G===void 0&&(G=0),re===void 0&&(re=this.length),I<0||C>h.length||G<0||re>this.length)throw new RangeError("out of range index");if(G>=re&&I>=C)return 0;if(G>=re)return-1;if(I>=C)return 1;if(I>>>=0,C>>>=0,G>>>=0,re>>>=0,this===h)return 0;let le=re-G,ft=C-I,pn=Math.min(le,ft),tn=this.slice(G,re),hn=h.slice(I,C);for(let Xt=0;Xt2147483647?I=2147483647:I<-2147483648&&(I=-2147483648),I=+I,fr(I)&&(I=G?0:A.length-1),I<0&&(I=A.length+I),I>=A.length){if(G)return-1;I=A.length-1}else if(I<0)if(G)I=0;else return-1;if(typeof h=="string"&&(h=o.from(h,C)),o.isBuffer(h))return h.length===0?-1:Fe(A,h,I,C,G);if(typeof h=="number")return h=h&255,typeof Uint8Array.prototype.indexOf=="function"?G?Uint8Array.prototype.indexOf.call(A,h,I):Uint8Array.prototype.lastIndexOf.call(A,h,I):Fe(A,[h],I,C,G);throw new TypeError("val must be string, number or Buffer")}function Fe(A,h,I,C,G){let re=1,le=A.length,ft=h.length;if(C!==void 0&&(C=String(C).toLowerCase(),C==="ucs2"||C==="ucs-2"||C==="utf16le"||C==="utf-16le")){if(A.length<2||h.length<2)return-1;re=2,le/=2,ft/=2,I/=2}function pn(hn,Xt){return re===1?hn[Xt]:hn.readUInt16BE(Xt*re)}let tn;if(G){let hn=-1;for(tn=I;tnle&&(I=le-ft),tn=I;tn>=0;tn--){let hn=!0;for(let Xt=0;XtG&&(C=G)):C=G;let re=h.length;C>re/2&&(C=re/2);let le;for(le=0;le>>0,isFinite(C)?(C=C>>>0,G===void 0&&(G="utf8")):(G=C,C=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");let re=this.length-I;if((C===void 0||C>re)&&(C=re),h.length>0&&(C<0||I<0)||I>this.length)throw new RangeError("Attempt to write outside buffer bounds");G||(G="utf8");let le=!1;for(;;)switch(G){case"hex":return xe(this,h,I,C);case"utf8":case"utf-8":return et(this,h,I,C);case"ascii":case"latin1":case"binary":return X(this,h,I,C);case"base64":return ve(this,h,I,C);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return gt(this,h,I,C);default:if(le)throw new TypeError("Unknown encoding: "+G);G=(""+G).toLowerCase(),le=!0}},o.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function zt(A,h,I){return h===0&&I===A.length?e.fromByteArray(A):e.fromByteArray(A.slice(h,I))}function Wt(A,h,I){I=Math.min(A.length,I);let C=[],G=h;for(;G239?4:re>223?3:re>191?2:1;if(G+ft<=I){let pn,tn,hn,Xt;switch(ft){case 1:re<128&&(le=re);break;case 2:pn=A[G+1],(pn&192)===128&&(Xt=(re&31)<<6|pn&63,Xt>127&&(le=Xt));break;case 3:pn=A[G+1],tn=A[G+2],(pn&192)===128&&(tn&192)===128&&(Xt=(re&15)<<12|(pn&63)<<6|tn&63,Xt>2047&&(Xt<55296||Xt>57343)&&(le=Xt));break;case 4:pn=A[G+1],tn=A[G+2],hn=A[G+3],(pn&192)===128&&(tn&192)===128&&(hn&192)===128&&(Xt=(re&15)<<18|(pn&63)<<12|(tn&63)<<6|hn&63,Xt>65535&&Xt<1114112&&(le=Xt))}}le===null?(le=65533,ft=1):le>65535&&(le-=65536,C.push(le>>>10&1023|55296),le=56320|le&1023),C.push(le),G+=ft}return Vt(C)}let Dn=4096;function Vt(A){let h=A.length;if(h<=Dn)return String.fromCharCode.apply(String,A);let I="",C=0;for(;CC)&&(I=C);let G="";for(let re=h;reC&&(h=C),I<0?(I+=C,I<0&&(I=0)):I>C&&(I=C),II)throw new RangeError("Trying to access beyond buffer length")}o.prototype.readUintLE=o.prototype.readUIntLE=function(h,I,C){h=h>>>0,I=I>>>0,C||$t(h,I,this.length);let G=this[h],re=1,le=0;for(;++le>>0,I=I>>>0,C||$t(h,I,this.length);let G=this[h+--I],re=1;for(;I>0&&(re*=256);)G+=this[h+--I]*re;return G},o.prototype.readUint8=o.prototype.readUInt8=function(h,I){return h=h>>>0,I||$t(h,1,this.length),this[h]},o.prototype.readUint16LE=o.prototype.readUInt16LE=function(h,I){return h=h>>>0,I||$t(h,2,this.length),this[h]|this[h+1]<<8},o.prototype.readUint16BE=o.prototype.readUInt16BE=function(h,I){return h=h>>>0,I||$t(h,2,this.length),this[h]<<8|this[h+1]},o.prototype.readUint32LE=o.prototype.readUInt32LE=function(h,I){return h=h>>>0,I||$t(h,4,this.length),(this[h]|this[h+1]<<8|this[h+2]<<16)+this[h+3]*16777216},o.prototype.readUint32BE=o.prototype.readUInt32BE=function(h,I){return h=h>>>0,I||$t(h,4,this.length),this[h]*16777216+(this[h+1]<<16|this[h+2]<<8|this[h+3])},o.prototype.readBigUInt64LE=ya(function(h){h=h>>>0,tt(h,"offset");let I=this[h],C=this[h+7];(I===void 0||C===void 0)&&At(h,this.length-8);let G=I+this[++h]*nn(2,8)+this[++h]*nn(2,16)+this[++h]*nn(2,24),re=this[++h]+this[++h]*nn(2,8)+this[++h]*nn(2,16)+C*nn(2,24);return BigInt(G)+(BigInt(re)<>>0,tt(h,"offset");let I=this[h],C=this[h+7];(I===void 0||C===void 0)&&At(h,this.length-8);let G=I*nn(2,24)+this[++h]*nn(2,16)+this[++h]*nn(2,8)+this[++h],re=this[++h]*nn(2,24)+this[++h]*nn(2,16)+this[++h]*nn(2,8)+C;return(BigInt(G)<>>0,I=I>>>0,C||$t(h,I,this.length);let G=this[h],re=1,le=0;for(;++le=re&&(G-=Math.pow(2,8*I)),G},o.prototype.readIntBE=function(h,I,C){h=h>>>0,I=I>>>0,C||$t(h,I,this.length);let G=I,re=1,le=this[h+--G];for(;G>0&&(re*=256);)le+=this[h+--G]*re;return re*=128,le>=re&&(le-=Math.pow(2,8*I)),le},o.prototype.readInt8=function(h,I){return h=h>>>0,I||$t(h,1,this.length),this[h]&128?(255-this[h]+1)*-1:this[h]},o.prototype.readInt16LE=function(h,I){h=h>>>0,I||$t(h,2,this.length);let C=this[h]|this[h+1]<<8;return C&32768?C|4294901760:C},o.prototype.readInt16BE=function(h,I){h=h>>>0,I||$t(h,2,this.length);let C=this[h+1]|this[h]<<8;return C&32768?C|4294901760:C},o.prototype.readInt32LE=function(h,I){return h=h>>>0,I||$t(h,4,this.length),this[h]|this[h+1]<<8|this[h+2]<<16|this[h+3]<<24},o.prototype.readInt32BE=function(h,I){return h=h>>>0,I||$t(h,4,this.length),this[h]<<24|this[h+1]<<16|this[h+2]<<8|this[h+3]},o.prototype.readBigInt64LE=ya(function(h){h=h>>>0,tt(h,"offset");let I=this[h],C=this[h+7];(I===void 0||C===void 0)&&At(h,this.length-8);let G=this[h+4]+this[h+5]*nn(2,8)+this[h+6]*nn(2,16)+(C<<24);return(BigInt(G)<>>0,tt(h,"offset");let I=this[h],C=this[h+7];(I===void 0||C===void 0)&&At(h,this.length-8);let G=(I<<24)+this[++h]*nn(2,16)+this[++h]*nn(2,8)+this[++h];return(BigInt(G)<>>0,I||$t(h,4,this.length),t.read(this,h,!0,23,4)},o.prototype.readFloatBE=function(h,I){return h=h>>>0,I||$t(h,4,this.length),t.read(this,h,!1,23,4)},o.prototype.readDoubleLE=function(h,I){return h=h>>>0,I||$t(h,8,this.length),t.read(this,h,!0,52,8)},o.prototype.readDoubleBE=function(h,I){return h=h>>>0,I||$t(h,8,this.length),t.read(this,h,!1,52,8)};function bn(A,h,I,C,G,re){if(!o.isBuffer(A))throw new TypeError('"buffer" argument must be a Buffer instance');if(h>G||hA.length)throw new RangeError("Index out of range")}o.prototype.writeUintLE=o.prototype.writeUIntLE=function(h,I,C,G){if(h=+h,I=I>>>0,C=C>>>0,!G){let ft=Math.pow(2,8*C)-1;bn(this,h,I,C,ft,0)}let re=1,le=0;for(this[I]=h&255;++le>>0,C=C>>>0,!G){let ft=Math.pow(2,8*C)-1;bn(this,h,I,C,ft,0)}let re=C-1,le=1;for(this[I+re]=h&255;--re>=0&&(le*=256);)this[I+re]=h/le&255;return I+C},o.prototype.writeUint8=o.prototype.writeUInt8=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,1,255,0),this[I]=h&255,I+1},o.prototype.writeUint16LE=o.prototype.writeUInt16LE=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,2,65535,0),this[I]=h&255,this[I+1]=h>>>8,I+2},o.prototype.writeUint16BE=o.prototype.writeUInt16BE=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,2,65535,0),this[I]=h>>>8,this[I+1]=h&255,I+2},o.prototype.writeUint32LE=o.prototype.writeUInt32LE=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,4,4294967295,0),this[I+3]=h>>>24,this[I+2]=h>>>16,this[I+1]=h>>>8,this[I]=h&255,I+4},o.prototype.writeUint32BE=o.prototype.writeUInt32BE=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,4,4294967295,0),this[I]=h>>>24,this[I+1]=h>>>16,this[I+2]=h>>>8,this[I+3]=h&255,I+4};function oe(A,h,I,C,G){Lt(h,C,G,A,I,7);let re=Number(h&BigInt(4294967295));A[I++]=re,re=re>>8,A[I++]=re,re=re>>8,A[I++]=re,re=re>>8,A[I++]=re;let le=Number(h>>BigInt(32)&BigInt(4294967295));return A[I++]=le,le=le>>8,A[I++]=le,le=le>>8,A[I++]=le,le=le>>8,A[I++]=le,I}function De(A,h,I,C,G){Lt(h,C,G,A,I,7);let re=Number(h&BigInt(4294967295));A[I+7]=re,re=re>>8,A[I+6]=re,re=re>>8,A[I+5]=re,re=re>>8,A[I+4]=re;let le=Number(h>>BigInt(32)&BigInt(4294967295));return A[I+3]=le,le=le>>8,A[I+2]=le,le=le>>8,A[I+1]=le,le=le>>8,A[I]=le,I+8}o.prototype.writeBigUInt64LE=ya(function(h,I=0){return oe(this,h,I,BigInt(0),BigInt("0xffffffffffffffff"))}),o.prototype.writeBigUInt64BE=ya(function(h,I=0){return De(this,h,I,BigInt(0),BigInt("0xffffffffffffffff"))}),o.prototype.writeIntLE=function(h,I,C,G){if(h=+h,I=I>>>0,!G){let pn=Math.pow(2,8*C-1);bn(this,h,I,C,pn-1,-pn)}let re=0,le=1,ft=0;for(this[I]=h&255;++re>0)-ft&255;return I+C},o.prototype.writeIntBE=function(h,I,C,G){if(h=+h,I=I>>>0,!G){let pn=Math.pow(2,8*C-1);bn(this,h,I,C,pn-1,-pn)}let re=C-1,le=1,ft=0;for(this[I+re]=h&255;--re>=0&&(le*=256);)h<0&&ft===0&&this[I+re+1]!==0&&(ft=1),this[I+re]=(h/le>>0)-ft&255;return I+C},o.prototype.writeInt8=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,1,127,-128),h<0&&(h=255+h+1),this[I]=h&255,I+1},o.prototype.writeInt16LE=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,2,32767,-32768),this[I]=h&255,this[I+1]=h>>>8,I+2},o.prototype.writeInt16BE=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,2,32767,-32768),this[I]=h>>>8,this[I+1]=h&255,I+2},o.prototype.writeInt32LE=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,4,2147483647,-2147483648),this[I]=h&255,this[I+1]=h>>>8,this[I+2]=h>>>16,this[I+3]=h>>>24,I+4},o.prototype.writeInt32BE=function(h,I,C){return h=+h,I=I>>>0,C||bn(this,h,I,4,2147483647,-2147483648),h<0&&(h=4294967295+h+1),this[I]=h>>>24,this[I+1]=h>>>16,this[I+2]=h>>>8,this[I+3]=h&255,I+4},o.prototype.writeBigInt64LE=ya(function(h,I=0){return oe(this,h,I,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),o.prototype.writeBigInt64BE=ya(function(h,I=0){return De(this,h,I,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function _e(A,h,I,C,G,re){if(I+C>A.length)throw new RangeError("Index out of range");if(I<0)throw new RangeError("Index out of range")}function Ce(A,h,I,C,G){return h=+h,I=I>>>0,G||_e(A,h,I,4),t.write(A,h,I,C,23,4),I+4}o.prototype.writeFloatLE=function(h,I,C){return Ce(this,h,I,!0,C)},o.prototype.writeFloatBE=function(h,I,C){return Ce(this,h,I,!1,C)};function _t(A,h,I,C,G){return h=+h,I=I>>>0,G||_e(A,h,I,8),t.write(A,h,I,C,52,8),I+8}o.prototype.writeDoubleLE=function(h,I,C){return _t(this,h,I,!0,C)},o.prototype.writeDoubleBE=function(h,I,C){return _t(this,h,I,!1,C)},o.prototype.copy=function(h,I,C,G){if(!o.isBuffer(h))throw new TypeError("argument should be a Buffer");if(C||(C=0),!G&&G!==0&&(G=this.length),I>=h.length&&(I=h.length),I||(I=0),G>0&&G=this.length)throw new RangeError("Index out of range");if(G<0)throw new RangeError("sourceEnd out of bounds");G>this.length&&(G=this.length),h.length-I>>0,C=C===void 0?this.length:C>>>0,h||(h=0);let re;if(typeof h=="number")for(re=I;renn(2,32)?G=qe(String(I)):typeof I=="bigint"&&(G=String(I),(I>nn(BigInt(2),BigInt(32))||I<-nn(BigInt(2),BigInt(32)))&&(G=qe(G)),G+="n"),C+=` It must be ${h}. Received ${G}`,C},RangeError);function qe(A){let h="",I=A.length,C=A[0]==="-"?1:0;for(;I>=C+4;I-=3)h=`_${A.slice(I-3,I)}${h}`;return`${A.slice(0,I)}${h}`}function Qe(A,h,I){tt(h,"offset"),(A[h]===void 0||A[h+I]===void 0)&&At(h,A.length-(I+1))}function Lt(A,h,I,C,G,re){if(A>I||A3?h===0||h===BigInt(0)?ft=`>= 0${le} and < 2${le} ** ${(re+1)*8}${le}`:ft=`>= -(2${le} ** ${(re+1)*8-1}${le}) and < 2 ** ${(re+1)*8-1}${le}`:ft=`>= ${h}${le} and <= ${I}${le}`,new J.ERR_OUT_OF_RANGE("value",ft,A)}Qe(C,G,re)}function tt(A,h){if(typeof A!="number")throw new J.ERR_INVALID_ARG_TYPE(h,"number",A)}function At(A,h,I){throw Math.floor(A)!==A?(tt(A,I),new J.ERR_OUT_OF_RANGE(I||"offset","an integer",A)):h<0?new J.ERR_BUFFER_OUT_OF_BOUNDS:new J.ERR_OUT_OF_RANGE(I||"offset",`>= ${I?1:0} and <= ${h}`,A)}let Ha=/[^+/0-9A-Za-z-_]/g;function xr(A){if(A=A.split("=")[0],A=A.trim().replace(Ha,""),A.length<2)return"";for(;A.length%4!==0;)A=A+"=";return A}function za(A,h){h=h||1/0;let I,C=A.length,G=null,re=[];for(let le=0;le55295&&I<57344){if(!G){if(I>56319){(h-=3)>-1&&re.push(239,191,189);continue}else if(le+1===C){(h-=3)>-1&&re.push(239,191,189);continue}G=I;continue}if(I<56320){(h-=3)>-1&&re.push(239,191,189),G=I;continue}I=(G-55296<<10|I-56320)+65536}else G&&(h-=3)>-1&&re.push(239,191,189);if(G=null,I<128){if((h-=1)<0)break;re.push(I)}else if(I<2048){if((h-=2)<0)break;re.push(I>>6|192,I&63|128)}else if(I<65536){if((h-=3)<0)break;re.push(I>>12|224,I>>6&63|128,I&63|128)}else if(I<1114112){if((h-=4)<0)break;re.push(I>>18|240,I>>12&63|128,I>>6&63|128,I&63|128)}else throw new Error("Invalid code point")}return re}function Lc(A){let h=[];for(let I=0;I>8,G=I%256,re.push(G),re.push(C);return re}function pr(A){return e.toByteArray(xr(A))}function ni(A,h,I,C){let G;for(G=0;G=h.length||G>=A.length);++G)h[G+I]=A[G];return G}function xt(A,h){return A instanceof h||A!=null&&A.constructor!=null&&A.constructor.name!=null&&A.constructor.name===h.name}function fr(A){return A!==A}let _u=function(){let A="0123456789abcdef",h=new Array(256);for(let I=0;I<16;++I){let C=I*16;for(let G=0;G<16;++G)h[C+G]=A[I]+A[G]}return h}();function ya(A){return typeof BigInt=="undefined"?vu:A}function vu(){throw new Error("BigInt not supported")}return Bu}var gd,JR,dm,HR,Bu,zR,Uu,D,Fde,wde,WR=Lu(()=>{"use strict";m();T();N();gd={},JR=!1;dm={},HR=!1;Bu={},zR=!1;Uu=fJ();Uu.Buffer;Uu.SlowBuffer;Uu.INSPECT_MAX_BYTES;Uu.kMaxLength;D=Uu.Buffer,Fde=Uu.INSPECT_MAX_BYTES,wde=Uu.kMaxLength});var T=Lu(()=>{"use strict";WR()});var XR=w(Jc=>{"use strict";m();T();N();Object.defineProperty(Jc,"__esModule",{value:!0});Jc.versionInfo=Jc.version=void 0;var mJ="16.9.0";Jc.version=mJ;var NJ=Object.freeze({major:16,minor:9,patch:0,preReleaseTag:null});Jc.versionInfo=NJ});var Lr=w(Sy=>{"use strict";m();T();N();Object.defineProperty(Sy,"__esModule",{value:!0});Sy.devAssert=TJ;function TJ(e,t){if(!!!e)throw new Error(t)}});var pm=w(Oy=>{"use strict";m();T();N();Object.defineProperty(Oy,"__esModule",{value:!0});Oy.isPromise=EJ;function EJ(e){return typeof(e==null?void 0:e.then)=="function"}});var va=w(Dy=>{"use strict";m();T();N();Object.defineProperty(Dy,"__esModule",{value:!0});Dy.isObjectLike=hJ;function hJ(e){return typeof e=="object"&&e!==null}});var yr=w(by=>{"use strict";m();T();N();Object.defineProperty(by,"__esModule",{value:!0});by.invariant=yJ;function yJ(e,t){if(!!!e)throw new Error(t!=null?t:"Unexpected invariant triggered.")}});var fm=w(Ay=>{"use strict";m();T();N();Object.defineProperty(Ay,"__esModule",{value:!0});Ay.getLocation=_J;var IJ=yr(),gJ=/\r\n|[\n\r]/g;function _J(e,t){let n=0,r=1;for(let i of e.body.matchAll(gJ)){if(typeof i.index=="number"||(0,IJ.invariant)(!1),i.index>=t)break;n=i.index+i[0].length,r+=1}return{line:r,column:t+1-n}}});var Ry=w(mm=>{"use strict";m();T();N();Object.defineProperty(mm,"__esModule",{value:!0});mm.printLocation=SJ;mm.printSourceLocation=eP;var vJ=fm();function SJ(e){return eP(e.source,(0,vJ.getLocation)(e.source,e.start))}function eP(e,t){let n=e.locationOffset.column-1,r="".padStart(n)+e.body,i=t.line-1,a=e.locationOffset.line-1,o=t.line+a,c=t.line===1?n:0,l=t.column+c,p=`${e.name}:${o}:${l} +`,f=r.split(/\r\n|[\n\r]/g),y=f[i];if(y.length>120){let g=Math.floor(l/80),v=l%80,P=[];for(let U=0;U["|",U]),["|","^".padStart(v)],["|",P[g+1]]])}return p+ZR([[`${o-1} |`,f[i-1]],[`${o} |`,y],["|","^".padStart(l)],[`${o+1} |`,f[i+1]]])}function ZR(e){let t=e.filter(([r,i])=>i!==void 0),n=Math.max(...t.map(([r])=>r.length));return t.map(([r,i])=>r.padStart(n)+(i?" "+i:"")).join(` +`)}});var He=w(Hc=>{"use strict";m();T();N();Object.defineProperty(Hc,"__esModule",{value:!0});Hc.GraphQLError=void 0;Hc.formatError=AJ;Hc.printError=bJ;var OJ=va(),tP=fm(),nP=Ry();function DJ(e){let t=e[0];return t==null||"kind"in t||"length"in t?{nodes:t,source:e[1],positions:e[2],path:e[3],originalError:e[4],extensions:e[5]}:t}var Py=class e extends Error{constructor(t,...n){var r,i,a;let{nodes:o,source:c,positions:l,path:p,originalError:f,extensions:y}=DJ(n);super(t),this.name="GraphQLError",this.path=p!=null?p:void 0,this.originalError=f!=null?f:void 0,this.nodes=rP(Array.isArray(o)?o:o?[o]:void 0);let g=rP((r=this.nodes)===null||r===void 0?void 0:r.map(P=>P.loc).filter(P=>P!=null));this.source=c!=null?c:g==null||(i=g[0])===null||i===void 0?void 0:i.source,this.positions=l!=null?l:g==null?void 0:g.map(P=>P.start),this.locations=l&&c?l.map(P=>(0,tP.getLocation)(c,P)):g==null?void 0:g.map(P=>(0,tP.getLocation)(P.source,P.start));let v=(0,OJ.isObjectLike)(f==null?void 0:f.extensions)?f==null?void 0:f.extensions:void 0;this.extensions=(a=y!=null?y:v)!==null&&a!==void 0?a:Object.create(null),Object.defineProperties(this,{message:{writable:!0,enumerable:!0},name:{enumerable:!1},nodes:{enumerable:!1},source:{enumerable:!1},positions:{enumerable:!1},originalError:{enumerable:!1}}),f!=null&&f.stack?Object.defineProperty(this,"stack",{value:f.stack,writable:!0,configurable:!0}):Error.captureStackTrace?Error.captureStackTrace(this,e):Object.defineProperty(this,"stack",{value:Error().stack,writable:!0,configurable:!0})}get[Symbol.toStringTag](){return"GraphQLError"}toString(){let t=this.message;if(this.nodes)for(let n of this.nodes)n.loc&&(t+=` `+(0,nP.printLocation)(n.loc));else if(this.source&&this.locations)for(let n of this.locations)t+=` @@ -36,30 +36,30 @@ https://yarnpkg.com/en/docs/selective-version-resolutions Duplicate "graphql" modules cannot be used at the same time since different versions may have different capabilities and behavior. The data from one version used in the function from another could produce confusing and -spurious results.`)}}return!1};Im.instanceOf=s3});var _m=w(Fd=>{"use strict";m();T();N();Object.defineProperty(Fd,"__esModule",{value:!0});Fd.Source=void 0;Fd.isSource=c3;var Ky=Lr(),o3=Yt(),u3=Pd(),gm=class{constructor(t,n="GraphQL request",r={line:1,column:1}){typeof t=="string"||(0,Ky.devAssert)(!1,`Body must be a string. Received: ${(0,o3.inspect)(t)}.`),this.body=t,this.name=n,this.locationOffset=r,this.locationOffset.line>0||(0,Ky.devAssert)(!1,"line in locationOffset is 1-indexed and must be positive."),this.locationOffset.column>0||(0,Ky.devAssert)(!1,"column in locationOffset is 1-indexed and must be positive.")}get[Symbol.toStringTag](){return"Source"}};Fd.Source=gm;function c3(e){return(0,u3.instanceOf)(e,gm)}});var Xc=w(Ho=>{"use strict";m();T();N();Object.defineProperty(Ho,"__esModule",{value:!0});Ho.Parser=void 0;Ho.parse=d3;Ho.parseConstValue=f3;Ho.parseType=m3;Ho.parseValue=p3;var qu=Nm(),wd=Sa(),l3=zc(),at=Pt(),pP=hm(),dP=_m(),Se=bd();function d3(e,t){return new Vu(e,t).parseDocument()}function p3(e,t){let n=new Vu(e,t);n.expectToken(Se.TokenKind.SOF);let r=n.parseValueLiteral(!1);return n.expectToken(Se.TokenKind.EOF),r}function f3(e,t){let n=new Vu(e,t);n.expectToken(Se.TokenKind.SOF);let r=n.parseConstValueLiteral();return n.expectToken(Se.TokenKind.EOF),r}function m3(e,t){let n=new Vu(e,t);n.expectToken(Se.TokenKind.SOF);let r=n.parseTypeReference();return n.expectToken(Se.TokenKind.EOF),r}var Vu=class{constructor(t,n={}){let r=(0,dP.isSource)(t)?t:new dP.Source(t);this._lexer=new pP.Lexer(r),this._options=n,this._tokenCounter=0}parseName(){let t=this.expectToken(Se.TokenKind.NAME);return this.node(t,{kind:at.Kind.NAME,value:t.value})}parseDocument(){return this.node(this._lexer.token,{kind:at.Kind.DOCUMENT,definitions:this.many(Se.TokenKind.SOF,this.parseDefinition,Se.TokenKind.EOF)})}parseDefinition(){if(this.peek(Se.TokenKind.BRACE_L))return this.parseOperationDefinition();let t=this.peekDescription(),n=t?this._lexer.lookahead():this._lexer.token;if(n.kind===Se.TokenKind.NAME){switch(n.value){case"schema":return this.parseSchemaDefinition();case"scalar":return this.parseScalarTypeDefinition();case"type":return this.parseObjectTypeDefinition();case"interface":return this.parseInterfaceTypeDefinition();case"union":return this.parseUnionTypeDefinition();case"enum":return this.parseEnumTypeDefinition();case"input":return this.parseInputObjectTypeDefinition();case"directive":return this.parseDirectiveDefinition()}if(t)throw(0,qu.syntaxError)(this._lexer.source,this._lexer.token.start,"Unexpected description, descriptions are supported only on type definitions.");switch(n.value){case"query":case"mutation":case"subscription":return this.parseOperationDefinition();case"fragment":return this.parseFragmentDefinition();case"extend":return this.parseTypeSystemExtension()}}throw this.unexpected(n)}parseOperationDefinition(){let t=this._lexer.token;if(this.peek(Se.TokenKind.BRACE_L))return this.node(t,{kind:at.Kind.OPERATION_DEFINITION,operation:wd.OperationTypeNode.QUERY,name:void 0,variableDefinitions:[],directives:[],selectionSet:this.parseSelectionSet()});let n=this.parseOperationType(),r;return this.peek(Se.TokenKind.NAME)&&(r=this.parseName()),this.node(t,{kind:at.Kind.OPERATION_DEFINITION,operation:n,name:r,variableDefinitions:this.parseVariableDefinitions(),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseOperationType(){let t=this.expectToken(Se.TokenKind.NAME);switch(t.value){case"query":return wd.OperationTypeNode.QUERY;case"mutation":return wd.OperationTypeNode.MUTATION;case"subscription":return wd.OperationTypeNode.SUBSCRIPTION}throw this.unexpected(t)}parseVariableDefinitions(){return this.optionalMany(Se.TokenKind.PAREN_L,this.parseVariableDefinition,Se.TokenKind.PAREN_R)}parseVariableDefinition(){return this.node(this._lexer.token,{kind:at.Kind.VARIABLE_DEFINITION,variable:this.parseVariable(),type:(this.expectToken(Se.TokenKind.COLON),this.parseTypeReference()),defaultValue:this.expectOptionalToken(Se.TokenKind.EQUALS)?this.parseConstValueLiteral():void 0,directives:this.parseConstDirectives()})}parseVariable(){let t=this._lexer.token;return this.expectToken(Se.TokenKind.DOLLAR),this.node(t,{kind:at.Kind.VARIABLE,name:this.parseName()})}parseSelectionSet(){return this.node(this._lexer.token,{kind:at.Kind.SELECTION_SET,selections:this.many(Se.TokenKind.BRACE_L,this.parseSelection,Se.TokenKind.BRACE_R)})}parseSelection(){return this.peek(Se.TokenKind.SPREAD)?this.parseFragment():this.parseField()}parseField(){let t=this._lexer.token,n=this.parseName(),r,i;return this.expectOptionalToken(Se.TokenKind.COLON)?(r=n,i=this.parseName()):i=n,this.node(t,{kind:at.Kind.FIELD,alias:r,name:i,arguments:this.parseArguments(!1),directives:this.parseDirectives(!1),selectionSet:this.peek(Se.TokenKind.BRACE_L)?this.parseSelectionSet():void 0})}parseArguments(t){let n=t?this.parseConstArgument:this.parseArgument;return this.optionalMany(Se.TokenKind.PAREN_L,n,Se.TokenKind.PAREN_R)}parseArgument(t=!1){let n=this._lexer.token,r=this.parseName();return this.expectToken(Se.TokenKind.COLON),this.node(n,{kind:at.Kind.ARGUMENT,name:r,value:this.parseValueLiteral(t)})}parseConstArgument(){return this.parseArgument(!0)}parseFragment(){let t=this._lexer.token;this.expectToken(Se.TokenKind.SPREAD);let n=this.expectOptionalKeyword("on");return!n&&this.peek(Se.TokenKind.NAME)?this.node(t,{kind:at.Kind.FRAGMENT_SPREAD,name:this.parseFragmentName(),directives:this.parseDirectives(!1)}):this.node(t,{kind:at.Kind.INLINE_FRAGMENT,typeCondition:n?this.parseNamedType():void 0,directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentDefinition(){let t=this._lexer.token;return this.expectKeyword("fragment"),this._options.allowLegacyFragmentVariables===!0?this.node(t,{kind:at.Kind.FRAGMENT_DEFINITION,name:this.parseFragmentName(),variableDefinitions:this.parseVariableDefinitions(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()}):this.node(t,{kind:at.Kind.FRAGMENT_DEFINITION,name:this.parseFragmentName(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentName(){if(this._lexer.token.value==="on")throw this.unexpected();return this.parseName()}parseValueLiteral(t){let n=this._lexer.token;switch(n.kind){case Se.TokenKind.BRACKET_L:return this.parseList(t);case Se.TokenKind.BRACE_L:return this.parseObject(t);case Se.TokenKind.INT:return this.advanceLexer(),this.node(n,{kind:at.Kind.INT,value:n.value});case Se.TokenKind.FLOAT:return this.advanceLexer(),this.node(n,{kind:at.Kind.FLOAT,value:n.value});case Se.TokenKind.STRING:case Se.TokenKind.BLOCK_STRING:return this.parseStringLiteral();case Se.TokenKind.NAME:switch(this.advanceLexer(),n.value){case"true":return this.node(n,{kind:at.Kind.BOOLEAN,value:!0});case"false":return this.node(n,{kind:at.Kind.BOOLEAN,value:!1});case"null":return this.node(n,{kind:at.Kind.NULL});default:return this.node(n,{kind:at.Kind.ENUM,value:n.value})}case Se.TokenKind.DOLLAR:if(t)if(this.expectToken(Se.TokenKind.DOLLAR),this._lexer.token.kind===Se.TokenKind.NAME){let r=this._lexer.token.value;throw(0,qu.syntaxError)(this._lexer.source,n.start,`Unexpected variable "$${r}" in constant value.`)}else throw this.unexpected(n);return this.parseVariable();default:throw this.unexpected()}}parseConstValueLiteral(){return this.parseValueLiteral(!0)}parseStringLiteral(){let t=this._lexer.token;return this.advanceLexer(),this.node(t,{kind:at.Kind.STRING,value:t.value,block:t.kind===Se.TokenKind.BLOCK_STRING})}parseList(t){let n=()=>this.parseValueLiteral(t);return this.node(this._lexer.token,{kind:at.Kind.LIST,values:this.any(Se.TokenKind.BRACKET_L,n,Se.TokenKind.BRACKET_R)})}parseObject(t){let n=()=>this.parseObjectField(t);return this.node(this._lexer.token,{kind:at.Kind.OBJECT,fields:this.any(Se.TokenKind.BRACE_L,n,Se.TokenKind.BRACE_R)})}parseObjectField(t){let n=this._lexer.token,r=this.parseName();return this.expectToken(Se.TokenKind.COLON),this.node(n,{kind:at.Kind.OBJECT_FIELD,name:r,value:this.parseValueLiteral(t)})}parseDirectives(t){let n=[];for(;this.peek(Se.TokenKind.AT);)n.push(this.parseDirective(t));return n}parseConstDirectives(){return this.parseDirectives(!0)}parseDirective(t){let n=this._lexer.token;return this.expectToken(Se.TokenKind.AT),this.node(n,{kind:at.Kind.DIRECTIVE,name:this.parseName(),arguments:this.parseArguments(t)})}parseTypeReference(){let t=this._lexer.token,n;if(this.expectOptionalToken(Se.TokenKind.BRACKET_L)){let r=this.parseTypeReference();this.expectToken(Se.TokenKind.BRACKET_R),n=this.node(t,{kind:at.Kind.LIST_TYPE,type:r})}else n=this.parseNamedType();return this.expectOptionalToken(Se.TokenKind.BANG)?this.node(t,{kind:at.Kind.NON_NULL_TYPE,type:n}):n}parseNamedType(){return this.node(this._lexer.token,{kind:at.Kind.NAMED_TYPE,name:this.parseName()})}peekDescription(){return this.peek(Se.TokenKind.STRING)||this.peek(Se.TokenKind.BLOCK_STRING)}parseDescription(){if(this.peekDescription())return this.parseStringLiteral()}parseSchemaDefinition(){let t=this._lexer.token,n=this.parseDescription();this.expectKeyword("schema");let r=this.parseConstDirectives(),i=this.many(Se.TokenKind.BRACE_L,this.parseOperationTypeDefinition,Se.TokenKind.BRACE_R);return this.node(t,{kind:at.Kind.SCHEMA_DEFINITION,description:n,directives:r,operationTypes:i})}parseOperationTypeDefinition(){let t=this._lexer.token,n=this.parseOperationType();this.expectToken(Se.TokenKind.COLON);let r=this.parseNamedType();return this.node(t,{kind:at.Kind.OPERATION_TYPE_DEFINITION,operation:n,type:r})}parseScalarTypeDefinition(){let t=this._lexer.token,n=this.parseDescription();this.expectKeyword("scalar");let r=this.parseName(),i=this.parseConstDirectives();return this.node(t,{kind:at.Kind.SCALAR_TYPE_DEFINITION,description:n,name:r,directives:i})}parseObjectTypeDefinition(){let t=this._lexer.token,n=this.parseDescription();this.expectKeyword("type");let r=this.parseName(),i=this.parseImplementsInterfaces(),a=this.parseConstDirectives(),o=this.parseFieldsDefinition();return this.node(t,{kind:at.Kind.OBJECT_TYPE_DEFINITION,description:n,name:r,interfaces:i,directives:a,fields:o})}parseImplementsInterfaces(){return this.expectOptionalKeyword("implements")?this.delimitedMany(Se.TokenKind.AMP,this.parseNamedType):[]}parseFieldsDefinition(){return this.optionalMany(Se.TokenKind.BRACE_L,this.parseFieldDefinition,Se.TokenKind.BRACE_R)}parseFieldDefinition(){let t=this._lexer.token,n=this.parseDescription(),r=this.parseName(),i=this.parseArgumentDefs();this.expectToken(Se.TokenKind.COLON);let a=this.parseTypeReference(),o=this.parseConstDirectives();return this.node(t,{kind:at.Kind.FIELD_DEFINITION,description:n,name:r,arguments:i,type:a,directives:o})}parseArgumentDefs(){return this.optionalMany(Se.TokenKind.PAREN_L,this.parseInputValueDef,Se.TokenKind.PAREN_R)}parseInputValueDef(){let t=this._lexer.token,n=this.parseDescription(),r=this.parseName();this.expectToken(Se.TokenKind.COLON);let i=this.parseTypeReference(),a;this.expectOptionalToken(Se.TokenKind.EQUALS)&&(a=this.parseConstValueLiteral());let o=this.parseConstDirectives();return this.node(t,{kind:at.Kind.INPUT_VALUE_DEFINITION,description:n,name:r,type:i,defaultValue:a,directives:o})}parseInterfaceTypeDefinition(){let t=this._lexer.token,n=this.parseDescription();this.expectKeyword("interface");let r=this.parseName(),i=this.parseImplementsInterfaces(),a=this.parseConstDirectives(),o=this.parseFieldsDefinition();return this.node(t,{kind:at.Kind.INTERFACE_TYPE_DEFINITION,description:n,name:r,interfaces:i,directives:a,fields:o})}parseUnionTypeDefinition(){let t=this._lexer.token,n=this.parseDescription();this.expectKeyword("union");let r=this.parseName(),i=this.parseConstDirectives(),a=this.parseUnionMemberTypes();return this.node(t,{kind:at.Kind.UNION_TYPE_DEFINITION,description:n,name:r,directives:i,types:a})}parseUnionMemberTypes(){return this.expectOptionalToken(Se.TokenKind.EQUALS)?this.delimitedMany(Se.TokenKind.PIPE,this.parseNamedType):[]}parseEnumTypeDefinition(){let t=this._lexer.token,n=this.parseDescription();this.expectKeyword("enum");let r=this.parseName(),i=this.parseConstDirectives(),a=this.parseEnumValuesDefinition();return this.node(t,{kind:at.Kind.ENUM_TYPE_DEFINITION,description:n,name:r,directives:i,values:a})}parseEnumValuesDefinition(){return this.optionalMany(Se.TokenKind.BRACE_L,this.parseEnumValueDefinition,Se.TokenKind.BRACE_R)}parseEnumValueDefinition(){let t=this._lexer.token,n=this.parseDescription(),r=this.parseEnumValueName(),i=this.parseConstDirectives();return this.node(t,{kind:at.Kind.ENUM_VALUE_DEFINITION,description:n,name:r,directives:i})}parseEnumValueName(){if(this._lexer.token.value==="true"||this._lexer.token.value==="false"||this._lexer.token.value==="null")throw(0,qu.syntaxError)(this._lexer.source,this._lexer.token.start,`${vm(this._lexer.token)} is reserved and cannot be used for an enum value.`);return this.parseName()}parseInputObjectTypeDefinition(){let t=this._lexer.token,n=this.parseDescription();this.expectKeyword("input");let r=this.parseName(),i=this.parseConstDirectives(),a=this.parseInputFieldsDefinition();return this.node(t,{kind:at.Kind.INPUT_OBJECT_TYPE_DEFINITION,description:n,name:r,directives:i,fields:a})}parseInputFieldsDefinition(){return this.optionalMany(Se.TokenKind.BRACE_L,this.parseInputValueDef,Se.TokenKind.BRACE_R)}parseTypeSystemExtension(){let t=this._lexer.lookahead();if(t.kind===Se.TokenKind.NAME)switch(t.value){case"schema":return this.parseSchemaExtension();case"scalar":return this.parseScalarTypeExtension();case"type":return this.parseObjectTypeExtension();case"interface":return this.parseInterfaceTypeExtension();case"union":return this.parseUnionTypeExtension();case"enum":return this.parseEnumTypeExtension();case"input":return this.parseInputObjectTypeExtension()}throw this.unexpected(t)}parseSchemaExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("schema");let n=this.parseConstDirectives(),r=this.optionalMany(Se.TokenKind.BRACE_L,this.parseOperationTypeDefinition,Se.TokenKind.BRACE_R);if(n.length===0&&r.length===0)throw this.unexpected();return this.node(t,{kind:at.Kind.SCHEMA_EXTENSION,directives:n,operationTypes:r})}parseScalarTypeExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("scalar");let n=this.parseName(),r=this.parseConstDirectives();if(r.length===0)throw this.unexpected();return this.node(t,{kind:at.Kind.SCALAR_TYPE_EXTENSION,name:n,directives:r})}parseObjectTypeExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("type");let n=this.parseName(),r=this.parseImplementsInterfaces(),i=this.parseConstDirectives(),a=this.parseFieldsDefinition();if(r.length===0&&i.length===0&&a.length===0)throw this.unexpected();return this.node(t,{kind:at.Kind.OBJECT_TYPE_EXTENSION,name:n,interfaces:r,directives:i,fields:a})}parseInterfaceTypeExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("interface");let n=this.parseName(),r=this.parseImplementsInterfaces(),i=this.parseConstDirectives(),a=this.parseFieldsDefinition();if(r.length===0&&i.length===0&&a.length===0)throw this.unexpected();return this.node(t,{kind:at.Kind.INTERFACE_TYPE_EXTENSION,name:n,interfaces:r,directives:i,fields:a})}parseUnionTypeExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("union");let n=this.parseName(),r=this.parseConstDirectives(),i=this.parseUnionMemberTypes();if(r.length===0&&i.length===0)throw this.unexpected();return this.node(t,{kind:at.Kind.UNION_TYPE_EXTENSION,name:n,directives:r,types:i})}parseEnumTypeExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("enum");let n=this.parseName(),r=this.parseConstDirectives(),i=this.parseEnumValuesDefinition();if(r.length===0&&i.length===0)throw this.unexpected();return this.node(t,{kind:at.Kind.ENUM_TYPE_EXTENSION,name:n,directives:r,values:i})}parseInputObjectTypeExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("input");let n=this.parseName(),r=this.parseConstDirectives(),i=this.parseInputFieldsDefinition();if(r.length===0&&i.length===0)throw this.unexpected();return this.node(t,{kind:at.Kind.INPUT_OBJECT_TYPE_EXTENSION,name:n,directives:r,fields:i})}parseDirectiveDefinition(){let t=this._lexer.token,n=this.parseDescription();this.expectKeyword("directive"),this.expectToken(Se.TokenKind.AT);let r=this.parseName(),i=this.parseArgumentDefs(),a=this.expectOptionalKeyword("repeatable");this.expectKeyword("on");let o=this.parseDirectiveLocations();return this.node(t,{kind:at.Kind.DIRECTIVE_DEFINITION,description:n,name:r,arguments:i,repeatable:a,locations:o})}parseDirectiveLocations(){return this.delimitedMany(Se.TokenKind.PIPE,this.parseDirectiveLocation)}parseDirectiveLocation(){let t=this._lexer.token,n=this.parseName();if(Object.prototype.hasOwnProperty.call(l3.DirectiveLocation,n.value))return n;throw this.unexpected(t)}node(t,n){return this._options.noLocation!==!0&&(n.loc=new wd.Location(t,this._lexer.lastToken,this._lexer.source)),n}peek(t){return this._lexer.token.kind===t}expectToken(t){let n=this._lexer.token;if(n.kind===t)return this.advanceLexer(),n;throw(0,qu.syntaxError)(this._lexer.source,n.start,`Expected ${fP(t)}, found ${vm(n)}.`)}expectOptionalToken(t){return this._lexer.token.kind===t?(this.advanceLexer(),!0):!1}expectKeyword(t){let n=this._lexer.token;if(n.kind===Se.TokenKind.NAME&&n.value===t)this.advanceLexer();else throw(0,qu.syntaxError)(this._lexer.source,n.start,`Expected "${t}", found ${vm(n)}.`)}expectOptionalKeyword(t){let n=this._lexer.token;return n.kind===Se.TokenKind.NAME&&n.value===t?(this.advanceLexer(),!0):!1}unexpected(t){let n=t!=null?t:this._lexer.token;return(0,qu.syntaxError)(this._lexer.source,n.start,`Unexpected ${vm(n)}.`)}any(t,n,r){this.expectToken(t);let i=[];for(;!this.expectOptionalToken(r);)i.push(n.call(this));return i}optionalMany(t,n,r){if(this.expectOptionalToken(t)){let i=[];do i.push(n.call(this));while(!this.expectOptionalToken(r));return i}return[]}many(t,n,r){this.expectToken(t);let i=[];do i.push(n.call(this));while(!this.expectOptionalToken(r));return i}delimitedMany(t,n){this.expectOptionalToken(t);let r=[];do r.push(n.call(this));while(this.expectOptionalToken(t));return r}advanceLexer(){let{maxTokens:t}=this._options,n=this._lexer.advance();if(t!==void 0&&n.kind!==Se.TokenKind.EOF&&(++this._tokenCounter,this._tokenCounter>t))throw(0,qu.syntaxError)(this._lexer.source,n.start,`Document contains more that ${t} tokens. Parsing aborted.`)}};Ho.Parser=Vu;function vm(e){let t=e.value;return fP(e.kind)+(t!=null?` "${t}"`:"")}function fP(e){return(0,pP.isPunctuatorTokenKind)(e)?`"${e}"`:e}});var zo=w(Gy=>{"use strict";m();T();N();Object.defineProperty(Gy,"__esModule",{value:!0});Gy.didYouMean=T3;var N3=5;function T3(e,t){let[n,r]=t?[e,t]:[void 0,e],i=" Did you mean ";n&&(i+=n+" ");let a=r.map(l=>`"${l}"`);switch(a.length){case 0:return"";case 1:return i+a[0]+"?";case 2:return i+a[0]+" or "+a[1]+"?"}let o=a.slice(0,N3),c=o.pop();return i+o.join(", ")+", or "+c+"?"}});var mP=w($y=>{"use strict";m();T();N();Object.defineProperty($y,"__esModule",{value:!0});$y.identityFunc=E3;function E3(e){return e}});var Wo=w(Qy=>{"use strict";m();T();N();Object.defineProperty(Qy,"__esModule",{value:!0});Qy.keyMap=h3;function h3(e,t){let n=Object.create(null);for(let r of e)n[t(r)]=r;return n}});var Ld=w(Yy=>{"use strict";m();T();N();Object.defineProperty(Yy,"__esModule",{value:!0});Yy.keyValMap=y3;function y3(e,t,n){let r=Object.create(null);for(let i of e)r[t(i)]=n(i);return r}});var Hy=w(Jy=>{"use strict";m();T();N();Object.defineProperty(Jy,"__esModule",{value:!0});Jy.mapValue=I3;function I3(e,t){let n=Object.create(null);for(let r of Object.keys(e))n[r]=t(e[r],r);return n}});var Cd=w(Wy=>{"use strict";m();T();N();Object.defineProperty(Wy,"__esModule",{value:!0});Wy.naturalCompare=g3;function g3(e,t){let n=0,r=0;for(;n0);let c=0;do++r,c=c*10+a-zy,a=t.charCodeAt(r);while(Sm(a)&&c>0);if(oc)return 1}else{if(ia)return 1;++n,++r}}return e.length-t.length}var zy=48,_3=57;function Sm(e){return!isNaN(e)&&zy<=e&&e<=_3}});var Xo=w(Zy=>{"use strict";m();T();N();Object.defineProperty(Zy,"__esModule",{value:!0});Zy.suggestionList=S3;var v3=Cd();function S3(e,t){let n=Object.create(null),r=new Xy(e),i=Math.floor(e.length*.4)+1;for(let a of t){let o=r.measure(a,i);o!==void 0&&(n[a]=o)}return Object.keys(n).sort((a,o)=>{let c=n[a]-n[o];return c!==0?c:(0,v3.naturalCompare)(a,o)})}var Xy=class{constructor(t){this._input=t,this._inputLowerCase=t.toLowerCase(),this._inputArray=NP(this._inputLowerCase),this._rows=[new Array(t.length+1).fill(0),new Array(t.length+1).fill(0),new Array(t.length+1).fill(0)]}measure(t,n){if(this._input===t)return 0;let r=t.toLowerCase();if(this._inputLowerCase===r)return 1;let i=NP(r),a=this._inputArray;if(i.lengthn)return;let l=this._rows;for(let f=0;f<=c;f++)l[0][f]=f;for(let f=1;f<=o;f++){let y=l[(f-1)%3],g=l[f%3],v=g[0]=f;for(let F=1;F<=c;F++){let k=i[f-1]===a[F-1]?0:1,K=Math.min(y[F]+1,g[F-1]+1,y[F-1]+k);if(f>1&&F>1&&i[f-1]===a[F-2]&&i[f-2]===a[F-1]){let $=l[(f-2)%3][F-2];K=Math.min(K,$+1)}Kn)return}let p=l[o%3][c];return p<=n?p:void 0}};function NP(e){let t=e.length,n=new Array(t);for(let r=0;r{"use strict";m();T();N();Object.defineProperty(eI,"__esModule",{value:!0});eI.toObjMap=O3;function O3(e){if(e==null)return Object.create(null);if(Object.getPrototypeOf(e)===null)return e;let t=Object.create(null);for(let[n,r]of Object.entries(e))t[n]=r;return t}});var TP=w(tI=>{"use strict";m();T();N();Object.defineProperty(tI,"__esModule",{value:!0});tI.printString=D3;function D3(e){return`"${e.replace(b3,A3)}"`}var b3=/[\x00-\x1f\x22\x5c\x7f-\x9f]/g;function A3(e){return R3[e.charCodeAt(0)]}var R3=["\\u0000","\\u0001","\\u0002","\\u0003","\\u0004","\\u0005","\\u0006","\\u0007","\\b","\\t","\\n","\\u000B","\\f","\\r","\\u000E","\\u000F","\\u0010","\\u0011","\\u0012","\\u0013","\\u0014","\\u0015","\\u0016","\\u0017","\\u0018","\\u0019","\\u001A","\\u001B","\\u001C","\\u001D","\\u001E","\\u001F","","",'\\"',"","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\\\","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\u007F","\\u0080","\\u0081","\\u0082","\\u0083","\\u0084","\\u0085","\\u0086","\\u0087","\\u0088","\\u0089","\\u008A","\\u008B","\\u008C","\\u008D","\\u008E","\\u008F","\\u0090","\\u0091","\\u0092","\\u0093","\\u0094","\\u0095","\\u0096","\\u0097","\\u0098","\\u0099","\\u009A","\\u009B","\\u009C","\\u009D","\\u009E","\\u009F"]});var ju=w(Zo=>{"use strict";m();T();N();Object.defineProperty(Zo,"__esModule",{value:!0});Zo.BREAK=void 0;Zo.getEnterLeaveForKind=Dm;Zo.getVisitFn=C3;Zo.visit=w3;Zo.visitInParallel=L3;var P3=Lr(),F3=Yt(),nI=Sa(),EP=Pt(),Zc=Object.freeze({});Zo.BREAK=Zc;function w3(e,t,n=nI.QueryDocumentKeys){let r=new Map;for(let $ of Object.values(EP.Kind))r.set($,Dm(t,$));let i,a=Array.isArray(e),o=[e],c=-1,l=[],p=e,f,y,g=[],v=[];do{c++;let $=c===o.length,ne=$&&l.length!==0;if($){if(f=v.length===0?void 0:g[g.length-1],p=y,y=v.pop(),ne)if(a){p=p.slice();let Te=0;for(let[pe,Fe]of l){let Ve=pe-Te;Fe===null?(p.splice(Ve,1),Te++):p[Ve]=Fe}}else{p=Object.defineProperties({},Object.getOwnPropertyDescriptors(p));for(let[Te,pe]of l)p[Te]=pe}c=i.index,o=i.keys,l=i.edits,a=i.inArray,i=i.prev}else if(y){if(f=a?c:o[c],p=y[f],p==null)continue;g.push(f)}let z;if(!Array.isArray(p)){var F,k;(0,nI.isNode)(p)||(0,P3.devAssert)(!1,`Invalid AST Node: ${(0,F3.inspect)(p)}.`);let Te=$?(F=r.get(p.kind))===null||F===void 0?void 0:F.leave:(k=r.get(p.kind))===null||k===void 0?void 0:k.enter;if(z=Te==null?void 0:Te.call(t,p,f,y,g,v),z===Zc)break;if(z===!1){if(!$){g.pop();continue}}else if(z!==void 0&&(l.push([f,z]),!$))if((0,nI.isNode)(z))p=z;else{g.pop();continue}}if(z===void 0&&ne&&l.push([f,p]),$)g.pop();else{var K;i={inArray:a,index:c,keys:o,edits:l,prev:i},a=Array.isArray(p),o=a?p:(K=n[p.kind])!==null&&K!==void 0?K:[],c=-1,l=[],y&&v.push(y),y=p}}while(i!==void 0);return l.length!==0?l[l.length-1][1]:e}function L3(e){let t=new Array(e.length).fill(null),n=Object.create(null);for(let r of Object.values(EP.Kind)){let i=!1,a=new Array(e.length).fill(void 0),o=new Array(e.length).fill(void 0);for(let l=0;l{"use strict";m();T();N();Object.defineProperty(rI,"__esModule",{value:!0});rI.print=M3;var B3=Od(),U3=TP(),k3=ju();function M3(e){return(0,k3.visit)(e,q3)}var x3=80,q3={Name:{leave:e=>e.value},Variable:{leave:e=>"$"+e.name},Document:{leave:e=>qe(e.definitions,` +spurious results.`)}}return!1};Im.instanceOf=s3});var _m=w(Fd=>{"use strict";m();T();N();Object.defineProperty(Fd,"__esModule",{value:!0});Fd.Source=void 0;Fd.isSource=c3;var Ky=Lr(),o3=Yt(),u3=Pd(),gm=class{constructor(t,n="GraphQL request",r={line:1,column:1}){typeof t=="string"||(0,Ky.devAssert)(!1,`Body must be a string. Received: ${(0,o3.inspect)(t)}.`),this.body=t,this.name=n,this.locationOffset=r,this.locationOffset.line>0||(0,Ky.devAssert)(!1,"line in locationOffset is 1-indexed and must be positive."),this.locationOffset.column>0||(0,Ky.devAssert)(!1,"column in locationOffset is 1-indexed and must be positive.")}get[Symbol.toStringTag](){return"Source"}};Fd.Source=gm;function c3(e){return(0,u3.instanceOf)(e,gm)}});var Xc=w(Ho=>{"use strict";m();T();N();Object.defineProperty(Ho,"__esModule",{value:!0});Ho.Parser=void 0;Ho.parse=d3;Ho.parseConstValue=f3;Ho.parseType=m3;Ho.parseValue=p3;var qu=Nm(),wd=Sa(),l3=zc(),at=Pt(),pP=hm(),dP=_m(),Se=bd();function d3(e,t){return new Vu(e,t).parseDocument()}function p3(e,t){let n=new Vu(e,t);n.expectToken(Se.TokenKind.SOF);let r=n.parseValueLiteral(!1);return n.expectToken(Se.TokenKind.EOF),r}function f3(e,t){let n=new Vu(e,t);n.expectToken(Se.TokenKind.SOF);let r=n.parseConstValueLiteral();return n.expectToken(Se.TokenKind.EOF),r}function m3(e,t){let n=new Vu(e,t);n.expectToken(Se.TokenKind.SOF);let r=n.parseTypeReference();return n.expectToken(Se.TokenKind.EOF),r}var Vu=class{constructor(t,n={}){let r=(0,dP.isSource)(t)?t:new dP.Source(t);this._lexer=new pP.Lexer(r),this._options=n,this._tokenCounter=0}parseName(){let t=this.expectToken(Se.TokenKind.NAME);return this.node(t,{kind:at.Kind.NAME,value:t.value})}parseDocument(){return this.node(this._lexer.token,{kind:at.Kind.DOCUMENT,definitions:this.many(Se.TokenKind.SOF,this.parseDefinition,Se.TokenKind.EOF)})}parseDefinition(){if(this.peek(Se.TokenKind.BRACE_L))return this.parseOperationDefinition();let t=this.peekDescription(),n=t?this._lexer.lookahead():this._lexer.token;if(n.kind===Se.TokenKind.NAME){switch(n.value){case"schema":return this.parseSchemaDefinition();case"scalar":return this.parseScalarTypeDefinition();case"type":return this.parseObjectTypeDefinition();case"interface":return this.parseInterfaceTypeDefinition();case"union":return this.parseUnionTypeDefinition();case"enum":return this.parseEnumTypeDefinition();case"input":return this.parseInputObjectTypeDefinition();case"directive":return this.parseDirectiveDefinition()}if(t)throw(0,qu.syntaxError)(this._lexer.source,this._lexer.token.start,"Unexpected description, descriptions are supported only on type definitions.");switch(n.value){case"query":case"mutation":case"subscription":return this.parseOperationDefinition();case"fragment":return this.parseFragmentDefinition();case"extend":return this.parseTypeSystemExtension()}}throw this.unexpected(n)}parseOperationDefinition(){let t=this._lexer.token;if(this.peek(Se.TokenKind.BRACE_L))return this.node(t,{kind:at.Kind.OPERATION_DEFINITION,operation:wd.OperationTypeNode.QUERY,name:void 0,variableDefinitions:[],directives:[],selectionSet:this.parseSelectionSet()});let n=this.parseOperationType(),r;return this.peek(Se.TokenKind.NAME)&&(r=this.parseName()),this.node(t,{kind:at.Kind.OPERATION_DEFINITION,operation:n,name:r,variableDefinitions:this.parseVariableDefinitions(),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseOperationType(){let t=this.expectToken(Se.TokenKind.NAME);switch(t.value){case"query":return wd.OperationTypeNode.QUERY;case"mutation":return wd.OperationTypeNode.MUTATION;case"subscription":return wd.OperationTypeNode.SUBSCRIPTION}throw this.unexpected(t)}parseVariableDefinitions(){return this.optionalMany(Se.TokenKind.PAREN_L,this.parseVariableDefinition,Se.TokenKind.PAREN_R)}parseVariableDefinition(){return this.node(this._lexer.token,{kind:at.Kind.VARIABLE_DEFINITION,variable:this.parseVariable(),type:(this.expectToken(Se.TokenKind.COLON),this.parseTypeReference()),defaultValue:this.expectOptionalToken(Se.TokenKind.EQUALS)?this.parseConstValueLiteral():void 0,directives:this.parseConstDirectives()})}parseVariable(){let t=this._lexer.token;return this.expectToken(Se.TokenKind.DOLLAR),this.node(t,{kind:at.Kind.VARIABLE,name:this.parseName()})}parseSelectionSet(){return this.node(this._lexer.token,{kind:at.Kind.SELECTION_SET,selections:this.many(Se.TokenKind.BRACE_L,this.parseSelection,Se.TokenKind.BRACE_R)})}parseSelection(){return this.peek(Se.TokenKind.SPREAD)?this.parseFragment():this.parseField()}parseField(){let t=this._lexer.token,n=this.parseName(),r,i;return this.expectOptionalToken(Se.TokenKind.COLON)?(r=n,i=this.parseName()):i=n,this.node(t,{kind:at.Kind.FIELD,alias:r,name:i,arguments:this.parseArguments(!1),directives:this.parseDirectives(!1),selectionSet:this.peek(Se.TokenKind.BRACE_L)?this.parseSelectionSet():void 0})}parseArguments(t){let n=t?this.parseConstArgument:this.parseArgument;return this.optionalMany(Se.TokenKind.PAREN_L,n,Se.TokenKind.PAREN_R)}parseArgument(t=!1){let n=this._lexer.token,r=this.parseName();return this.expectToken(Se.TokenKind.COLON),this.node(n,{kind:at.Kind.ARGUMENT,name:r,value:this.parseValueLiteral(t)})}parseConstArgument(){return this.parseArgument(!0)}parseFragment(){let t=this._lexer.token;this.expectToken(Se.TokenKind.SPREAD);let n=this.expectOptionalKeyword("on");return!n&&this.peek(Se.TokenKind.NAME)?this.node(t,{kind:at.Kind.FRAGMENT_SPREAD,name:this.parseFragmentName(),directives:this.parseDirectives(!1)}):this.node(t,{kind:at.Kind.INLINE_FRAGMENT,typeCondition:n?this.parseNamedType():void 0,directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentDefinition(){let t=this._lexer.token;return this.expectKeyword("fragment"),this._options.allowLegacyFragmentVariables===!0?this.node(t,{kind:at.Kind.FRAGMENT_DEFINITION,name:this.parseFragmentName(),variableDefinitions:this.parseVariableDefinitions(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()}):this.node(t,{kind:at.Kind.FRAGMENT_DEFINITION,name:this.parseFragmentName(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentName(){if(this._lexer.token.value==="on")throw this.unexpected();return this.parseName()}parseValueLiteral(t){let n=this._lexer.token;switch(n.kind){case Se.TokenKind.BRACKET_L:return this.parseList(t);case Se.TokenKind.BRACE_L:return this.parseObject(t);case Se.TokenKind.INT:return this.advanceLexer(),this.node(n,{kind:at.Kind.INT,value:n.value});case Se.TokenKind.FLOAT:return this.advanceLexer(),this.node(n,{kind:at.Kind.FLOAT,value:n.value});case Se.TokenKind.STRING:case Se.TokenKind.BLOCK_STRING:return this.parseStringLiteral();case Se.TokenKind.NAME:switch(this.advanceLexer(),n.value){case"true":return this.node(n,{kind:at.Kind.BOOLEAN,value:!0});case"false":return this.node(n,{kind:at.Kind.BOOLEAN,value:!1});case"null":return this.node(n,{kind:at.Kind.NULL});default:return this.node(n,{kind:at.Kind.ENUM,value:n.value})}case Se.TokenKind.DOLLAR:if(t)if(this.expectToken(Se.TokenKind.DOLLAR),this._lexer.token.kind===Se.TokenKind.NAME){let r=this._lexer.token.value;throw(0,qu.syntaxError)(this._lexer.source,n.start,`Unexpected variable "$${r}" in constant value.`)}else throw this.unexpected(n);return this.parseVariable();default:throw this.unexpected()}}parseConstValueLiteral(){return this.parseValueLiteral(!0)}parseStringLiteral(){let t=this._lexer.token;return this.advanceLexer(),this.node(t,{kind:at.Kind.STRING,value:t.value,block:t.kind===Se.TokenKind.BLOCK_STRING})}parseList(t){let n=()=>this.parseValueLiteral(t);return this.node(this._lexer.token,{kind:at.Kind.LIST,values:this.any(Se.TokenKind.BRACKET_L,n,Se.TokenKind.BRACKET_R)})}parseObject(t){let n=()=>this.parseObjectField(t);return this.node(this._lexer.token,{kind:at.Kind.OBJECT,fields:this.any(Se.TokenKind.BRACE_L,n,Se.TokenKind.BRACE_R)})}parseObjectField(t){let n=this._lexer.token,r=this.parseName();return this.expectToken(Se.TokenKind.COLON),this.node(n,{kind:at.Kind.OBJECT_FIELD,name:r,value:this.parseValueLiteral(t)})}parseDirectives(t){let n=[];for(;this.peek(Se.TokenKind.AT);)n.push(this.parseDirective(t));return n}parseConstDirectives(){return this.parseDirectives(!0)}parseDirective(t){let n=this._lexer.token;return this.expectToken(Se.TokenKind.AT),this.node(n,{kind:at.Kind.DIRECTIVE,name:this.parseName(),arguments:this.parseArguments(t)})}parseTypeReference(){let t=this._lexer.token,n;if(this.expectOptionalToken(Se.TokenKind.BRACKET_L)){let r=this.parseTypeReference();this.expectToken(Se.TokenKind.BRACKET_R),n=this.node(t,{kind:at.Kind.LIST_TYPE,type:r})}else n=this.parseNamedType();return this.expectOptionalToken(Se.TokenKind.BANG)?this.node(t,{kind:at.Kind.NON_NULL_TYPE,type:n}):n}parseNamedType(){return this.node(this._lexer.token,{kind:at.Kind.NAMED_TYPE,name:this.parseName()})}peekDescription(){return this.peek(Se.TokenKind.STRING)||this.peek(Se.TokenKind.BLOCK_STRING)}parseDescription(){if(this.peekDescription())return this.parseStringLiteral()}parseSchemaDefinition(){let t=this._lexer.token,n=this.parseDescription();this.expectKeyword("schema");let r=this.parseConstDirectives(),i=this.many(Se.TokenKind.BRACE_L,this.parseOperationTypeDefinition,Se.TokenKind.BRACE_R);return this.node(t,{kind:at.Kind.SCHEMA_DEFINITION,description:n,directives:r,operationTypes:i})}parseOperationTypeDefinition(){let t=this._lexer.token,n=this.parseOperationType();this.expectToken(Se.TokenKind.COLON);let r=this.parseNamedType();return this.node(t,{kind:at.Kind.OPERATION_TYPE_DEFINITION,operation:n,type:r})}parseScalarTypeDefinition(){let t=this._lexer.token,n=this.parseDescription();this.expectKeyword("scalar");let r=this.parseName(),i=this.parseConstDirectives();return this.node(t,{kind:at.Kind.SCALAR_TYPE_DEFINITION,description:n,name:r,directives:i})}parseObjectTypeDefinition(){let t=this._lexer.token,n=this.parseDescription();this.expectKeyword("type");let r=this.parseName(),i=this.parseImplementsInterfaces(),a=this.parseConstDirectives(),o=this.parseFieldsDefinition();return this.node(t,{kind:at.Kind.OBJECT_TYPE_DEFINITION,description:n,name:r,interfaces:i,directives:a,fields:o})}parseImplementsInterfaces(){return this.expectOptionalKeyword("implements")?this.delimitedMany(Se.TokenKind.AMP,this.parseNamedType):[]}parseFieldsDefinition(){return this.optionalMany(Se.TokenKind.BRACE_L,this.parseFieldDefinition,Se.TokenKind.BRACE_R)}parseFieldDefinition(){let t=this._lexer.token,n=this.parseDescription(),r=this.parseName(),i=this.parseArgumentDefs();this.expectToken(Se.TokenKind.COLON);let a=this.parseTypeReference(),o=this.parseConstDirectives();return this.node(t,{kind:at.Kind.FIELD_DEFINITION,description:n,name:r,arguments:i,type:a,directives:o})}parseArgumentDefs(){return this.optionalMany(Se.TokenKind.PAREN_L,this.parseInputValueDef,Se.TokenKind.PAREN_R)}parseInputValueDef(){let t=this._lexer.token,n=this.parseDescription(),r=this.parseName();this.expectToken(Se.TokenKind.COLON);let i=this.parseTypeReference(),a;this.expectOptionalToken(Se.TokenKind.EQUALS)&&(a=this.parseConstValueLiteral());let o=this.parseConstDirectives();return this.node(t,{kind:at.Kind.INPUT_VALUE_DEFINITION,description:n,name:r,type:i,defaultValue:a,directives:o})}parseInterfaceTypeDefinition(){let t=this._lexer.token,n=this.parseDescription();this.expectKeyword("interface");let r=this.parseName(),i=this.parseImplementsInterfaces(),a=this.parseConstDirectives(),o=this.parseFieldsDefinition();return this.node(t,{kind:at.Kind.INTERFACE_TYPE_DEFINITION,description:n,name:r,interfaces:i,directives:a,fields:o})}parseUnionTypeDefinition(){let t=this._lexer.token,n=this.parseDescription();this.expectKeyword("union");let r=this.parseName(),i=this.parseConstDirectives(),a=this.parseUnionMemberTypes();return this.node(t,{kind:at.Kind.UNION_TYPE_DEFINITION,description:n,name:r,directives:i,types:a})}parseUnionMemberTypes(){return this.expectOptionalToken(Se.TokenKind.EQUALS)?this.delimitedMany(Se.TokenKind.PIPE,this.parseNamedType):[]}parseEnumTypeDefinition(){let t=this._lexer.token,n=this.parseDescription();this.expectKeyword("enum");let r=this.parseName(),i=this.parseConstDirectives(),a=this.parseEnumValuesDefinition();return this.node(t,{kind:at.Kind.ENUM_TYPE_DEFINITION,description:n,name:r,directives:i,values:a})}parseEnumValuesDefinition(){return this.optionalMany(Se.TokenKind.BRACE_L,this.parseEnumValueDefinition,Se.TokenKind.BRACE_R)}parseEnumValueDefinition(){let t=this._lexer.token,n=this.parseDescription(),r=this.parseEnumValueName(),i=this.parseConstDirectives();return this.node(t,{kind:at.Kind.ENUM_VALUE_DEFINITION,description:n,name:r,directives:i})}parseEnumValueName(){if(this._lexer.token.value==="true"||this._lexer.token.value==="false"||this._lexer.token.value==="null")throw(0,qu.syntaxError)(this._lexer.source,this._lexer.token.start,`${vm(this._lexer.token)} is reserved and cannot be used for an enum value.`);return this.parseName()}parseInputObjectTypeDefinition(){let t=this._lexer.token,n=this.parseDescription();this.expectKeyword("input");let r=this.parseName(),i=this.parseConstDirectives(),a=this.parseInputFieldsDefinition();return this.node(t,{kind:at.Kind.INPUT_OBJECT_TYPE_DEFINITION,description:n,name:r,directives:i,fields:a})}parseInputFieldsDefinition(){return this.optionalMany(Se.TokenKind.BRACE_L,this.parseInputValueDef,Se.TokenKind.BRACE_R)}parseTypeSystemExtension(){let t=this._lexer.lookahead();if(t.kind===Se.TokenKind.NAME)switch(t.value){case"schema":return this.parseSchemaExtension();case"scalar":return this.parseScalarTypeExtension();case"type":return this.parseObjectTypeExtension();case"interface":return this.parseInterfaceTypeExtension();case"union":return this.parseUnionTypeExtension();case"enum":return this.parseEnumTypeExtension();case"input":return this.parseInputObjectTypeExtension()}throw this.unexpected(t)}parseSchemaExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("schema");let n=this.parseConstDirectives(),r=this.optionalMany(Se.TokenKind.BRACE_L,this.parseOperationTypeDefinition,Se.TokenKind.BRACE_R);if(n.length===0&&r.length===0)throw this.unexpected();return this.node(t,{kind:at.Kind.SCHEMA_EXTENSION,directives:n,operationTypes:r})}parseScalarTypeExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("scalar");let n=this.parseName(),r=this.parseConstDirectives();if(r.length===0)throw this.unexpected();return this.node(t,{kind:at.Kind.SCALAR_TYPE_EXTENSION,name:n,directives:r})}parseObjectTypeExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("type");let n=this.parseName(),r=this.parseImplementsInterfaces(),i=this.parseConstDirectives(),a=this.parseFieldsDefinition();if(r.length===0&&i.length===0&&a.length===0)throw this.unexpected();return this.node(t,{kind:at.Kind.OBJECT_TYPE_EXTENSION,name:n,interfaces:r,directives:i,fields:a})}parseInterfaceTypeExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("interface");let n=this.parseName(),r=this.parseImplementsInterfaces(),i=this.parseConstDirectives(),a=this.parseFieldsDefinition();if(r.length===0&&i.length===0&&a.length===0)throw this.unexpected();return this.node(t,{kind:at.Kind.INTERFACE_TYPE_EXTENSION,name:n,interfaces:r,directives:i,fields:a})}parseUnionTypeExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("union");let n=this.parseName(),r=this.parseConstDirectives(),i=this.parseUnionMemberTypes();if(r.length===0&&i.length===0)throw this.unexpected();return this.node(t,{kind:at.Kind.UNION_TYPE_EXTENSION,name:n,directives:r,types:i})}parseEnumTypeExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("enum");let n=this.parseName(),r=this.parseConstDirectives(),i=this.parseEnumValuesDefinition();if(r.length===0&&i.length===0)throw this.unexpected();return this.node(t,{kind:at.Kind.ENUM_TYPE_EXTENSION,name:n,directives:r,values:i})}parseInputObjectTypeExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("input");let n=this.parseName(),r=this.parseConstDirectives(),i=this.parseInputFieldsDefinition();if(r.length===0&&i.length===0)throw this.unexpected();return this.node(t,{kind:at.Kind.INPUT_OBJECT_TYPE_EXTENSION,name:n,directives:r,fields:i})}parseDirectiveDefinition(){let t=this._lexer.token,n=this.parseDescription();this.expectKeyword("directive"),this.expectToken(Se.TokenKind.AT);let r=this.parseName(),i=this.parseArgumentDefs(),a=this.expectOptionalKeyword("repeatable");this.expectKeyword("on");let o=this.parseDirectiveLocations();return this.node(t,{kind:at.Kind.DIRECTIVE_DEFINITION,description:n,name:r,arguments:i,repeatable:a,locations:o})}parseDirectiveLocations(){return this.delimitedMany(Se.TokenKind.PIPE,this.parseDirectiveLocation)}parseDirectiveLocation(){let t=this._lexer.token,n=this.parseName();if(Object.prototype.hasOwnProperty.call(l3.DirectiveLocation,n.value))return n;throw this.unexpected(t)}node(t,n){return this._options.noLocation!==!0&&(n.loc=new wd.Location(t,this._lexer.lastToken,this._lexer.source)),n}peek(t){return this._lexer.token.kind===t}expectToken(t){let n=this._lexer.token;if(n.kind===t)return this.advanceLexer(),n;throw(0,qu.syntaxError)(this._lexer.source,n.start,`Expected ${fP(t)}, found ${vm(n)}.`)}expectOptionalToken(t){return this._lexer.token.kind===t?(this.advanceLexer(),!0):!1}expectKeyword(t){let n=this._lexer.token;if(n.kind===Se.TokenKind.NAME&&n.value===t)this.advanceLexer();else throw(0,qu.syntaxError)(this._lexer.source,n.start,`Expected "${t}", found ${vm(n)}.`)}expectOptionalKeyword(t){let n=this._lexer.token;return n.kind===Se.TokenKind.NAME&&n.value===t?(this.advanceLexer(),!0):!1}unexpected(t){let n=t!=null?t:this._lexer.token;return(0,qu.syntaxError)(this._lexer.source,n.start,`Unexpected ${vm(n)}.`)}any(t,n,r){this.expectToken(t);let i=[];for(;!this.expectOptionalToken(r);)i.push(n.call(this));return i}optionalMany(t,n,r){if(this.expectOptionalToken(t)){let i=[];do i.push(n.call(this));while(!this.expectOptionalToken(r));return i}return[]}many(t,n,r){this.expectToken(t);let i=[];do i.push(n.call(this));while(!this.expectOptionalToken(r));return i}delimitedMany(t,n){this.expectOptionalToken(t);let r=[];do r.push(n.call(this));while(this.expectOptionalToken(t));return r}advanceLexer(){let{maxTokens:t}=this._options,n=this._lexer.advance();if(t!==void 0&&n.kind!==Se.TokenKind.EOF&&(++this._tokenCounter,this._tokenCounter>t))throw(0,qu.syntaxError)(this._lexer.source,n.start,`Document contains more that ${t} tokens. Parsing aborted.`)}};Ho.Parser=Vu;function vm(e){let t=e.value;return fP(e.kind)+(t!=null?` "${t}"`:"")}function fP(e){return(0,pP.isPunctuatorTokenKind)(e)?`"${e}"`:e}});var zo=w(Gy=>{"use strict";m();T();N();Object.defineProperty(Gy,"__esModule",{value:!0});Gy.didYouMean=T3;var N3=5;function T3(e,t){let[n,r]=t?[e,t]:[void 0,e],i=" Did you mean ";n&&(i+=n+" ");let a=r.map(l=>`"${l}"`);switch(a.length){case 0:return"";case 1:return i+a[0]+"?";case 2:return i+a[0]+" or "+a[1]+"?"}let o=a.slice(0,N3),c=o.pop();return i+o.join(", ")+", or "+c+"?"}});var mP=w($y=>{"use strict";m();T();N();Object.defineProperty($y,"__esModule",{value:!0});$y.identityFunc=E3;function E3(e){return e}});var Wo=w(Qy=>{"use strict";m();T();N();Object.defineProperty(Qy,"__esModule",{value:!0});Qy.keyMap=h3;function h3(e,t){let n=Object.create(null);for(let r of e)n[t(r)]=r;return n}});var Ld=w(Yy=>{"use strict";m();T();N();Object.defineProperty(Yy,"__esModule",{value:!0});Yy.keyValMap=y3;function y3(e,t,n){let r=Object.create(null);for(let i of e)r[t(i)]=n(i);return r}});var Hy=w(Jy=>{"use strict";m();T();N();Object.defineProperty(Jy,"__esModule",{value:!0});Jy.mapValue=I3;function I3(e,t){let n=Object.create(null);for(let r of Object.keys(e))n[r]=t(e[r],r);return n}});var Cd=w(Wy=>{"use strict";m();T();N();Object.defineProperty(Wy,"__esModule",{value:!0});Wy.naturalCompare=g3;function g3(e,t){let n=0,r=0;for(;n0);let c=0;do++r,c=c*10+a-zy,a=t.charCodeAt(r);while(Sm(a)&&c>0);if(oc)return 1}else{if(ia)return 1;++n,++r}}return e.length-t.length}var zy=48,_3=57;function Sm(e){return!isNaN(e)&&zy<=e&&e<=_3}});var Xo=w(Zy=>{"use strict";m();T();N();Object.defineProperty(Zy,"__esModule",{value:!0});Zy.suggestionList=S3;var v3=Cd();function S3(e,t){let n=Object.create(null),r=new Xy(e),i=Math.floor(e.length*.4)+1;for(let a of t){let o=r.measure(a,i);o!==void 0&&(n[a]=o)}return Object.keys(n).sort((a,o)=>{let c=n[a]-n[o];return c!==0?c:(0,v3.naturalCompare)(a,o)})}var Xy=class{constructor(t){this._input=t,this._inputLowerCase=t.toLowerCase(),this._inputArray=NP(this._inputLowerCase),this._rows=[new Array(t.length+1).fill(0),new Array(t.length+1).fill(0),new Array(t.length+1).fill(0)]}measure(t,n){if(this._input===t)return 0;let r=t.toLowerCase();if(this._inputLowerCase===r)return 1;let i=NP(r),a=this._inputArray;if(i.lengthn)return;let l=this._rows;for(let f=0;f<=c;f++)l[0][f]=f;for(let f=1;f<=o;f++){let y=l[(f-1)%3],g=l[f%3],v=g[0]=f;for(let P=1;P<=c;P++){let U=i[f-1]===a[P-1]?0:1,K=Math.min(y[P]+1,g[P-1]+1,y[P-1]+U);if(f>1&&P>1&&i[f-1]===a[P-2]&&i[f-2]===a[P-1]){let $=l[(f-2)%3][P-2];K=Math.min(K,$+1)}Kn)return}let p=l[o%3][c];return p<=n?p:void 0}};function NP(e){let t=e.length,n=new Array(t);for(let r=0;r{"use strict";m();T();N();Object.defineProperty(eI,"__esModule",{value:!0});eI.toObjMap=O3;function O3(e){if(e==null)return Object.create(null);if(Object.getPrototypeOf(e)===null)return e;let t=Object.create(null);for(let[n,r]of Object.entries(e))t[n]=r;return t}});var TP=w(tI=>{"use strict";m();T();N();Object.defineProperty(tI,"__esModule",{value:!0});tI.printString=D3;function D3(e){return`"${e.replace(b3,A3)}"`}var b3=/[\x00-\x1f\x22\x5c\x7f-\x9f]/g;function A3(e){return R3[e.charCodeAt(0)]}var R3=["\\u0000","\\u0001","\\u0002","\\u0003","\\u0004","\\u0005","\\u0006","\\u0007","\\b","\\t","\\n","\\u000B","\\f","\\r","\\u000E","\\u000F","\\u0010","\\u0011","\\u0012","\\u0013","\\u0014","\\u0015","\\u0016","\\u0017","\\u0018","\\u0019","\\u001A","\\u001B","\\u001C","\\u001D","\\u001E","\\u001F","","",'\\"',"","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\\\","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\u007F","\\u0080","\\u0081","\\u0082","\\u0083","\\u0084","\\u0085","\\u0086","\\u0087","\\u0088","\\u0089","\\u008A","\\u008B","\\u008C","\\u008D","\\u008E","\\u008F","\\u0090","\\u0091","\\u0092","\\u0093","\\u0094","\\u0095","\\u0096","\\u0097","\\u0098","\\u0099","\\u009A","\\u009B","\\u009C","\\u009D","\\u009E","\\u009F"]});var ju=w(Zo=>{"use strict";m();T();N();Object.defineProperty(Zo,"__esModule",{value:!0});Zo.BREAK=void 0;Zo.getEnterLeaveForKind=Dm;Zo.getVisitFn=C3;Zo.visit=w3;Zo.visitInParallel=L3;var P3=Lr(),F3=Yt(),nI=Sa(),EP=Pt(),Zc=Object.freeze({});Zo.BREAK=Zc;function w3(e,t,n=nI.QueryDocumentKeys){let r=new Map;for(let $ of Object.values(EP.Kind))r.set($,Dm(t,$));let i,a=Array.isArray(e),o=[e],c=-1,l=[],p=e,f,y,g=[],v=[];do{c++;let $=c===o.length,ne=$&&l.length!==0;if($){if(f=v.length===0?void 0:g[g.length-1],p=y,y=v.pop(),ne)if(a){p=p.slice();let Te=0;for(let[pe,Fe]of l){let xe=pe-Te;Fe===null?(p.splice(xe,1),Te++):p[xe]=Fe}}else{p=Object.defineProperties({},Object.getOwnPropertyDescriptors(p));for(let[Te,pe]of l)p[Te]=pe}c=i.index,o=i.keys,l=i.edits,a=i.inArray,i=i.prev}else if(y){if(f=a?c:o[c],p=y[f],p==null)continue;g.push(f)}let z;if(!Array.isArray(p)){var P,U;(0,nI.isNode)(p)||(0,P3.devAssert)(!1,`Invalid AST Node: ${(0,F3.inspect)(p)}.`);let Te=$?(P=r.get(p.kind))===null||P===void 0?void 0:P.leave:(U=r.get(p.kind))===null||U===void 0?void 0:U.enter;if(z=Te==null?void 0:Te.call(t,p,f,y,g,v),z===Zc)break;if(z===!1){if(!$){g.pop();continue}}else if(z!==void 0&&(l.push([f,z]),!$))if((0,nI.isNode)(z))p=z;else{g.pop();continue}}if(z===void 0&&ne&&l.push([f,p]),$)g.pop();else{var K;i={inArray:a,index:c,keys:o,edits:l,prev:i},a=Array.isArray(p),o=a?p:(K=n[p.kind])!==null&&K!==void 0?K:[],c=-1,l=[],y&&v.push(y),y=p}}while(i!==void 0);return l.length!==0?l[l.length-1][1]:e}function L3(e){let t=new Array(e.length).fill(null),n=Object.create(null);for(let r of Object.values(EP.Kind)){let i=!1,a=new Array(e.length).fill(void 0),o=new Array(e.length).fill(void 0);for(let l=0;l{"use strict";m();T();N();Object.defineProperty(rI,"__esModule",{value:!0});rI.print=M3;var B3=Od(),U3=TP(),k3=ju();function M3(e){return(0,k3.visit)(e,q3)}var x3=80,q3={Name:{leave:e=>e.value},Variable:{leave:e=>"$"+e.name},Document:{leave:e=>Ve(e.definitions,` -`)},OperationDefinition:{leave(e){let t=Dt("(",qe(e.variableDefinitions,", "),")"),n=qe([e.operation,qe([e.name,t]),qe(e.directives," ")]," ");return(n==="query"?"":n+" ")+e.selectionSet}},VariableDefinition:{leave:({variable:e,type:t,defaultValue:n,directives:r})=>e+": "+t+Dt(" = ",n)+Dt(" ",qe(r," "))},SelectionSet:{leave:({selections:e})=>zi(e)},Field:{leave({alias:e,name:t,arguments:n,directives:r,selectionSet:i}){let a=Dt("",e,": ")+t,o=a+Dt("(",qe(n,", "),")");return o.length>x3&&(o=a+Dt(`( -`,bm(qe(n,` +`)},OperationDefinition:{leave(e){let t=Dt("(",Ve(e.variableDefinitions,", "),")"),n=Ve([e.operation,Ve([e.name,t]),Ve(e.directives," ")]," ");return(n==="query"?"":n+" ")+e.selectionSet}},VariableDefinition:{leave:({variable:e,type:t,defaultValue:n,directives:r})=>e+": "+t+Dt(" = ",n)+Dt(" ",Ve(r," "))},SelectionSet:{leave:({selections:e})=>zi(e)},Field:{leave({alias:e,name:t,arguments:n,directives:r,selectionSet:i}){let a=Dt("",e,": ")+t,o=a+Dt("(",Ve(n,", "),")");return o.length>x3&&(o=a+Dt(`( +`,bm(Ve(n,` `)),` -)`)),qe([o,qe(r," "),i]," ")}},Argument:{leave:({name:e,value:t})=>e+": "+t},FragmentSpread:{leave:({name:e,directives:t})=>"..."+e+Dt(" ",qe(t," "))},InlineFragment:{leave:({typeCondition:e,directives:t,selectionSet:n})=>qe(["...",Dt("on ",e),qe(t," "),n]," ")},FragmentDefinition:{leave:({name:e,typeCondition:t,variableDefinitions:n,directives:r,selectionSet:i})=>`fragment ${e}${Dt("(",qe(n,", "),")")} on ${t} ${Dt("",qe(r," ")," ")}`+i},IntValue:{leave:({value:e})=>e},FloatValue:{leave:({value:e})=>e},StringValue:{leave:({value:e,block:t})=>t?(0,B3.printBlockString)(e):(0,U3.printString)(e)},BooleanValue:{leave:({value:e})=>e?"true":"false"},NullValue:{leave:()=>"null"},EnumValue:{leave:({value:e})=>e},ListValue:{leave:({values:e})=>"["+qe(e,", ")+"]"},ObjectValue:{leave:({fields:e})=>"{"+qe(e,", ")+"}"},ObjectField:{leave:({name:e,value:t})=>e+": "+t},Directive:{leave:({name:e,arguments:t})=>"@"+e+Dt("(",qe(t,", "),")")},NamedType:{leave:({name:e})=>e},ListType:{leave:({type:e})=>"["+e+"]"},NonNullType:{leave:({type:e})=>e+"!"},SchemaDefinition:{leave:({description:e,directives:t,operationTypes:n})=>Dt("",e,` -`)+qe(["schema",qe(t," "),zi(n)]," ")},OperationTypeDefinition:{leave:({operation:e,type:t})=>e+": "+t},ScalarTypeDefinition:{leave:({description:e,name:t,directives:n})=>Dt("",e,` -`)+qe(["scalar",t,qe(n," ")]," ")},ObjectTypeDefinition:{leave:({description:e,name:t,interfaces:n,directives:r,fields:i})=>Dt("",e,` -`)+qe(["type",t,Dt("implements ",qe(n," & ")),qe(r," "),zi(i)]," ")},FieldDefinition:{leave:({description:e,name:t,arguments:n,type:r,directives:i})=>Dt("",e,` +)`)),Ve([o,Ve(r," "),i]," ")}},Argument:{leave:({name:e,value:t})=>e+": "+t},FragmentSpread:{leave:({name:e,directives:t})=>"..."+e+Dt(" ",Ve(t," "))},InlineFragment:{leave:({typeCondition:e,directives:t,selectionSet:n})=>Ve(["...",Dt("on ",e),Ve(t," "),n]," ")},FragmentDefinition:{leave:({name:e,typeCondition:t,variableDefinitions:n,directives:r,selectionSet:i})=>`fragment ${e}${Dt("(",Ve(n,", "),")")} on ${t} ${Dt("",Ve(r," ")," ")}`+i},IntValue:{leave:({value:e})=>e},FloatValue:{leave:({value:e})=>e},StringValue:{leave:({value:e,block:t})=>t?(0,B3.printBlockString)(e):(0,U3.printString)(e)},BooleanValue:{leave:({value:e})=>e?"true":"false"},NullValue:{leave:()=>"null"},EnumValue:{leave:({value:e})=>e},ListValue:{leave:({values:e})=>"["+Ve(e,", ")+"]"},ObjectValue:{leave:({fields:e})=>"{"+Ve(e,", ")+"}"},ObjectField:{leave:({name:e,value:t})=>e+": "+t},Directive:{leave:({name:e,arguments:t})=>"@"+e+Dt("(",Ve(t,", "),")")},NamedType:{leave:({name:e})=>e},ListType:{leave:({type:e})=>"["+e+"]"},NonNullType:{leave:({type:e})=>e+"!"},SchemaDefinition:{leave:({description:e,directives:t,operationTypes:n})=>Dt("",e,` +`)+Ve(["schema",Ve(t," "),zi(n)]," ")},OperationTypeDefinition:{leave:({operation:e,type:t})=>e+": "+t},ScalarTypeDefinition:{leave:({description:e,name:t,directives:n})=>Dt("",e,` +`)+Ve(["scalar",t,Ve(n," ")]," ")},ObjectTypeDefinition:{leave:({description:e,name:t,interfaces:n,directives:r,fields:i})=>Dt("",e,` +`)+Ve(["type",t,Dt("implements ",Ve(n," & ")),Ve(r," "),zi(i)]," ")},FieldDefinition:{leave:({description:e,name:t,arguments:n,type:r,directives:i})=>Dt("",e,` `)+t+(hP(n)?Dt(`( -`,bm(qe(n,` +`,bm(Ve(n,` `)),` -)`):Dt("(",qe(n,", "),")"))+": "+r+Dt(" ",qe(i," "))},InputValueDefinition:{leave:({description:e,name:t,type:n,defaultValue:r,directives:i})=>Dt("",e,` -`)+qe([t+": "+n,Dt("= ",r),qe(i," ")]," ")},InterfaceTypeDefinition:{leave:({description:e,name:t,interfaces:n,directives:r,fields:i})=>Dt("",e,` -`)+qe(["interface",t,Dt("implements ",qe(n," & ")),qe(r," "),zi(i)]," ")},UnionTypeDefinition:{leave:({description:e,name:t,directives:n,types:r})=>Dt("",e,` -`)+qe(["union",t,qe(n," "),Dt("= ",qe(r," | "))]," ")},EnumTypeDefinition:{leave:({description:e,name:t,directives:n,values:r})=>Dt("",e,` -`)+qe(["enum",t,qe(n," "),zi(r)]," ")},EnumValueDefinition:{leave:({description:e,name:t,directives:n})=>Dt("",e,` -`)+qe([t,qe(n," ")]," ")},InputObjectTypeDefinition:{leave:({description:e,name:t,directives:n,fields:r})=>Dt("",e,` -`)+qe(["input",t,qe(n," "),zi(r)]," ")},DirectiveDefinition:{leave:({description:e,name:t,arguments:n,repeatable:r,locations:i})=>Dt("",e,` +)`):Dt("(",Ve(n,", "),")"))+": "+r+Dt(" ",Ve(i," "))},InputValueDefinition:{leave:({description:e,name:t,type:n,defaultValue:r,directives:i})=>Dt("",e,` +`)+Ve([t+": "+n,Dt("= ",r),Ve(i," ")]," ")},InterfaceTypeDefinition:{leave:({description:e,name:t,interfaces:n,directives:r,fields:i})=>Dt("",e,` +`)+Ve(["interface",t,Dt("implements ",Ve(n," & ")),Ve(r," "),zi(i)]," ")},UnionTypeDefinition:{leave:({description:e,name:t,directives:n,types:r})=>Dt("",e,` +`)+Ve(["union",t,Ve(n," "),Dt("= ",Ve(r," | "))]," ")},EnumTypeDefinition:{leave:({description:e,name:t,directives:n,values:r})=>Dt("",e,` +`)+Ve(["enum",t,Ve(n," "),zi(r)]," ")},EnumValueDefinition:{leave:({description:e,name:t,directives:n})=>Dt("",e,` +`)+Ve([t,Ve(n," ")]," ")},InputObjectTypeDefinition:{leave:({description:e,name:t,directives:n,fields:r})=>Dt("",e,` +`)+Ve(["input",t,Ve(n," "),zi(r)]," ")},DirectiveDefinition:{leave:({description:e,name:t,arguments:n,repeatable:r,locations:i})=>Dt("",e,` `)+"directive @"+t+(hP(n)?Dt(`( -`,bm(qe(n,` +`,bm(Ve(n,` `)),` -)`):Dt("(",qe(n,", "),")"))+(r?" repeatable":"")+" on "+qe(i," | ")},SchemaExtension:{leave:({directives:e,operationTypes:t})=>qe(["extend schema",qe(e," "),zi(t)]," ")},ScalarTypeExtension:{leave:({name:e,directives:t})=>qe(["extend scalar",e,qe(t," ")]," ")},ObjectTypeExtension:{leave:({name:e,interfaces:t,directives:n,fields:r})=>qe(["extend type",e,Dt("implements ",qe(t," & ")),qe(n," "),zi(r)]," ")},InterfaceTypeExtension:{leave:({name:e,interfaces:t,directives:n,fields:r})=>qe(["extend interface",e,Dt("implements ",qe(t," & ")),qe(n," "),zi(r)]," ")},UnionTypeExtension:{leave:({name:e,directives:t,types:n})=>qe(["extend union",e,qe(t," "),Dt("= ",qe(n," | "))]," ")},EnumTypeExtension:{leave:({name:e,directives:t,values:n})=>qe(["extend enum",e,qe(t," "),zi(n)]," ")},InputObjectTypeExtension:{leave:({name:e,directives:t,fields:n})=>qe(["extend input",e,qe(t," "),zi(n)]," ")}};function qe(e,t=""){var n;return(n=e==null?void 0:e.filter(r=>r).join(t))!==null&&n!==void 0?n:""}function zi(e){return Dt(`{ -`,bm(qe(e,` +)`):Dt("(",Ve(n,", "),")"))+(r?" repeatable":"")+" on "+Ve(i," | ")},SchemaExtension:{leave:({directives:e,operationTypes:t})=>Ve(["extend schema",Ve(e," "),zi(t)]," ")},ScalarTypeExtension:{leave:({name:e,directives:t})=>Ve(["extend scalar",e,Ve(t," ")]," ")},ObjectTypeExtension:{leave:({name:e,interfaces:t,directives:n,fields:r})=>Ve(["extend type",e,Dt("implements ",Ve(t," & ")),Ve(n," "),zi(r)]," ")},InterfaceTypeExtension:{leave:({name:e,interfaces:t,directives:n,fields:r})=>Ve(["extend interface",e,Dt("implements ",Ve(t," & ")),Ve(n," "),zi(r)]," ")},UnionTypeExtension:{leave:({name:e,directives:t,types:n})=>Ve(["extend union",e,Ve(t," "),Dt("= ",Ve(n," | "))]," ")},EnumTypeExtension:{leave:({name:e,directives:t,values:n})=>Ve(["extend enum",e,Ve(t," "),zi(n)]," ")},InputObjectTypeExtension:{leave:({name:e,directives:t,fields:n})=>Ve(["extend input",e,Ve(t," "),zi(n)]," ")}};function Ve(e,t=""){var n;return(n=e==null?void 0:e.filter(r=>r).join(t))!==null&&n!==void 0?n:""}function zi(e){return Dt(`{ +`,bm(Ve(e,` `)),` }`)}function Dt(e,t,n=""){return t!=null&&t!==""?e+t+n:""}function bm(e){return Dt(" ",e.replace(/\n/g,` `))}function hP(e){var t;return(t=e==null?void 0:e.some(n=>n.includes(` @@ -67,11 +67,11 @@ spurious results.`)}}return!1};Im.instanceOf=s3});var _m=w(Fd=>{"use strict";m() In some cases, you need to provide options to alter GraphQL's execution behavior in ways field arguments will not suffice, such as conditionally including or skipping a field. Directives provide this by describing additional information to the executor.`,fields:()=>({name:{type:new ke.GraphQLNonNull(rn.GraphQLString),resolve:e=>e.name},description:{type:rn.GraphQLString,resolve:e=>e.description},isRepeatable:{type:new ke.GraphQLNonNull(rn.GraphQLBoolean),resolve:e=>e.isRepeatable},locations:{type:new ke.GraphQLNonNull(new ke.GraphQLList(new ke.GraphQLNonNull(EI))),resolve:e=>e.locations},args:{type:new ke.GraphQLNonNull(new ke.GraphQLList(new ke.GraphQLNonNull(Jd))),args:{includeDeprecated:{type:rn.GraphQLBoolean,defaultValue:!1}},resolve(e,{includeDeprecated:t}){return t?e.args:e.args.filter(n=>n.deprecationReason==null)}}})});Jt.__Directive=TI;var EI=new ke.GraphQLEnumType({name:"__DirectiveLocation",description:"A Directive can be adjacent to many parts of the GraphQL language, a __DirectiveLocation describes one such possible adjacencies.",values:{QUERY:{value:zn.DirectiveLocation.QUERY,description:"Location adjacent to a query operation."},MUTATION:{value:zn.DirectiveLocation.MUTATION,description:"Location adjacent to a mutation operation."},SUBSCRIPTION:{value:zn.DirectiveLocation.SUBSCRIPTION,description:"Location adjacent to a subscription operation."},FIELD:{value:zn.DirectiveLocation.FIELD,description:"Location adjacent to a field."},FRAGMENT_DEFINITION:{value:zn.DirectiveLocation.FRAGMENT_DEFINITION,description:"Location adjacent to a fragment definition."},FRAGMENT_SPREAD:{value:zn.DirectiveLocation.FRAGMENT_SPREAD,description:"Location adjacent to a fragment spread."},INLINE_FRAGMENT:{value:zn.DirectiveLocation.INLINE_FRAGMENT,description:"Location adjacent to an inline fragment."},VARIABLE_DEFINITION:{value:zn.DirectiveLocation.VARIABLE_DEFINITION,description:"Location adjacent to a variable definition."},SCHEMA:{value:zn.DirectiveLocation.SCHEMA,description:"Location adjacent to a schema definition."},SCALAR:{value:zn.DirectiveLocation.SCALAR,description:"Location adjacent to a scalar definition."},OBJECT:{value:zn.DirectiveLocation.OBJECT,description:"Location adjacent to an object type definition."},FIELD_DEFINITION:{value:zn.DirectiveLocation.FIELD_DEFINITION,description:"Location adjacent to a field definition."},ARGUMENT_DEFINITION:{value:zn.DirectiveLocation.ARGUMENT_DEFINITION,description:"Location adjacent to an argument definition."},INTERFACE:{value:zn.DirectiveLocation.INTERFACE,description:"Location adjacent to an interface definition."},UNION:{value:zn.DirectiveLocation.UNION,description:"Location adjacent to a union definition."},ENUM:{value:zn.DirectiveLocation.ENUM,description:"Location adjacent to an enum definition."},ENUM_VALUE:{value:zn.DirectiveLocation.ENUM_VALUE,description:"Location adjacent to an enum value definition."},INPUT_OBJECT:{value:zn.DirectiveLocation.INPUT_OBJECT,description:"Location adjacent to an input object type definition."},INPUT_FIELD_DEFINITION:{value:zn.DirectiveLocation.INPUT_FIELD_DEFINITION,description:"Location adjacent to an input object field definition."}}});Jt.__DirectiveLocation=EI;var bi=new ke.GraphQLObjectType({name:"__Type",description:"The fundamental unit of any GraphQL Schema is the type. There are many kinds of types in GraphQL as represented by the `__TypeKind` enum.\n\nDepending on the kind of a type, certain fields describe information about that type. Scalar types provide no information beyond a name, description and optional `specifiedByURL`, while Enum types provide their values. Object and Interface types provide the fields they describe. Abstract types, Union and Interface, provide the Object types possible at runtime. List and NonNull types compose other types.",fields:()=>({kind:{type:new ke.GraphQLNonNull(II),resolve(e){if((0,ke.isScalarType)(e))return Wn.SCALAR;if((0,ke.isObjectType)(e))return Wn.OBJECT;if((0,ke.isInterfaceType)(e))return Wn.INTERFACE;if((0,ke.isUnionType)(e))return Wn.UNION;if((0,ke.isEnumType)(e))return Wn.ENUM;if((0,ke.isInputObjectType)(e))return Wn.INPUT_OBJECT;if((0,ke.isListType)(e))return Wn.LIST;if((0,ke.isNonNullType)(e))return Wn.NON_NULL;(0,LH.invariant)(!1,`Unexpected type: "${(0,wH.inspect)(e)}".`)}},name:{type:rn.GraphQLString,resolve:e=>"name"in e?e.name:void 0},description:{type:rn.GraphQLString,resolve:e=>"description"in e?e.description:void 0},specifiedByURL:{type:rn.GraphQLString,resolve:e=>"specifiedByURL"in e?e.specifiedByURL:void 0},fields:{type:new ke.GraphQLList(new ke.GraphQLNonNull(hI)),args:{includeDeprecated:{type:rn.GraphQLBoolean,defaultValue:!1}},resolve(e,{includeDeprecated:t}){if((0,ke.isObjectType)(e)||(0,ke.isInterfaceType)(e)){let n=Object.values(e.getFields());return t?n:n.filter(r=>r.deprecationReason==null)}}},interfaces:{type:new ke.GraphQLList(new ke.GraphQLNonNull(bi)),resolve(e){if((0,ke.isObjectType)(e)||(0,ke.isInterfaceType)(e))return e.getInterfaces()}},possibleTypes:{type:new ke.GraphQLList(new ke.GraphQLNonNull(bi)),resolve(e,t,n,{schema:r}){if((0,ke.isAbstractType)(e))return r.getPossibleTypes(e)}},enumValues:{type:new ke.GraphQLList(new ke.GraphQLNonNull(yI)),args:{includeDeprecated:{type:rn.GraphQLBoolean,defaultValue:!1}},resolve(e,{includeDeprecated:t}){if((0,ke.isEnumType)(e)){let n=e.getValues();return t?n:n.filter(r=>r.deprecationReason==null)}}},inputFields:{type:new ke.GraphQLList(new ke.GraphQLNonNull(Jd)),args:{includeDeprecated:{type:rn.GraphQLBoolean,defaultValue:!1}},resolve(e,{includeDeprecated:t}){if((0,ke.isInputObjectType)(e)){let n=Object.values(e.getFields());return t?n:n.filter(r=>r.deprecationReason==null)}}},ofType:{type:bi,resolve:e=>"ofType"in e?e.ofType:void 0},isOneOf:{type:rn.GraphQLBoolean,resolve:e=>{if((0,ke.isInputObjectType)(e))return e.isOneOf}}})});Jt.__Type=bi;var hI=new ke.GraphQLObjectType({name:"__Field",description:"Object and Interface types are described by a list of Fields, each of which has a name, potentially a list of arguments, and a return type.",fields:()=>({name:{type:new ke.GraphQLNonNull(rn.GraphQLString),resolve:e=>e.name},description:{type:rn.GraphQLString,resolve:e=>e.description},args:{type:new ke.GraphQLNonNull(new ke.GraphQLList(new ke.GraphQLNonNull(Jd))),args:{includeDeprecated:{type:rn.GraphQLBoolean,defaultValue:!1}},resolve(e,{includeDeprecated:t}){return t?e.args:e.args.filter(n=>n.deprecationReason==null)}},type:{type:new ke.GraphQLNonNull(bi),resolve:e=>e.type},isDeprecated:{type:new ke.GraphQLNonNull(rn.GraphQLBoolean),resolve:e=>e.deprecationReason!=null},deprecationReason:{type:rn.GraphQLString,resolve:e=>e.deprecationReason}})});Jt.__Field=hI;var Jd=new ke.GraphQLObjectType({name:"__InputValue",description:"Arguments provided to Fields or Directives and the input fields of an InputObject are represented as Input Values which describe their type and optionally a default value.",fields:()=>({name:{type:new ke.GraphQLNonNull(rn.GraphQLString),resolve:e=>e.name},description:{type:rn.GraphQLString,resolve:e=>e.description},type:{type:new ke.GraphQLNonNull(bi),resolve:e=>e.type},defaultValue:{type:rn.GraphQLString,description:"A GraphQL-formatted string representing the default value for this input value.",resolve(e){let{type:t,defaultValue:n}=e,r=(0,BH.astFromValue)(n,t);return r?(0,CH.print)(r):null}},isDeprecated:{type:new ke.GraphQLNonNull(rn.GraphQLBoolean),resolve:e=>e.deprecationReason!=null},deprecationReason:{type:rn.GraphQLString,resolve:e=>e.deprecationReason}})});Jt.__InputValue=Jd;var yI=new ke.GraphQLObjectType({name:"__EnumValue",description:"One possible value for a given Enum. Enum values are unique values, not a placeholder for a string or numeric value. However an Enum value is returned in a JSON response as a string.",fields:()=>({name:{type:new ke.GraphQLNonNull(rn.GraphQLString),resolve:e=>e.name},description:{type:rn.GraphQLString,resolve:e=>e.description},isDeprecated:{type:new ke.GraphQLNonNull(rn.GraphQLBoolean),resolve:e=>e.deprecationReason!=null},deprecationReason:{type:rn.GraphQLString,resolve:e=>e.deprecationReason}})});Jt.__EnumValue=yI;var Wn;Jt.TypeKind=Wn;(function(e){e.SCALAR="SCALAR",e.OBJECT="OBJECT",e.INTERFACE="INTERFACE",e.UNION="UNION",e.ENUM="ENUM",e.INPUT_OBJECT="INPUT_OBJECT",e.LIST="LIST",e.NON_NULL="NON_NULL"})(Wn||(Jt.TypeKind=Wn={}));var II=new ke.GraphQLEnumType({name:"__TypeKind",description:"An enum describing what kind of type a given `__Type` is.",values:{SCALAR:{value:Wn.SCALAR,description:"Indicates this type is a scalar."},OBJECT:{value:Wn.OBJECT,description:"Indicates this type is an object. `fields` and `interfaces` are valid fields."},INTERFACE:{value:Wn.INTERFACE,description:"Indicates this type is an interface. `fields`, `interfaces`, and `possibleTypes` are valid fields."},UNION:{value:Wn.UNION,description:"Indicates this type is a union. `possibleTypes` is a valid field."},ENUM:{value:Wn.ENUM,description:"Indicates this type is an enum. `enumValues` is a valid field."},INPUT_OBJECT:{value:Wn.INPUT_OBJECT,description:"Indicates this type is an input object. `inputFields` is a valid field."},LIST:{value:Wn.LIST,description:"Indicates this type is a list. `ofType` is a valid field."},NON_NULL:{value:Wn.NON_NULL,description:"Indicates this type is a non-null. `ofType` is a valid field."}}});Jt.__TypeKind=II;var UH={name:"__schema",type:new ke.GraphQLNonNull(NI),description:"Access the current type schema of this server.",args:[],resolve:(e,t,n,{schema:r})=>r,deprecationReason:void 0,extensions:Object.create(null),astNode:void 0};Jt.SchemaMetaFieldDef=UH;var kH={name:"__type",type:bi,description:"Request the type information of a single type.",args:[{name:"name",description:void 0,type:new ke.GraphQLNonNull(rn.GraphQLString),defaultValue:void 0,deprecationReason:void 0,extensions:Object.create(null),astNode:void 0}],resolve:(e,{name:t},n,{schema:r})=>r.getType(t),deprecationReason:void 0,extensions:Object.create(null),astNode:void 0};Jt.TypeMetaFieldDef=kH;var MH={name:"__typename",type:new ke.GraphQLNonNull(rn.GraphQLString),description:"The name of the current Object type at runtime.",args:[],resolve:(e,t,n,{parentType:r})=>r.name,deprecationReason:void 0,extensions:Object.create(null),astNode:void 0};Jt.TypeNameMetaFieldDef=MH;var ZP=Object.freeze([NI,TI,EI,bi,hI,Jd,yI,II]);Jt.introspectionTypes=ZP;function xH(e){return ZP.some(({name:t})=>e.name===t)}});var Ju=w(nl=>{"use strict";m();T();N();Object.defineProperty(nl,"__esModule",{value:!0});nl.GraphQLSchema=void 0;nl.assertSchema=GH;nl.isSchema=tF;var Ym=Lr(),_I=Yt(),qH=Pd(),VH=va(),jH=Om(),gI=Sa(),Xi=Ft(),eF=Gr(),KH=Ai();function tF(e){return(0,qH.instanceOf)(e,Jm)}function GH(e){if(!tF(e))throw new Error(`Expected ${(0,_I.inspect)(e)} to be a GraphQL schema.`);return e}var Jm=class{constructor(t){var n,r;this.__validationErrors=t.assumeValid===!0?[]:void 0,(0,VH.isObjectLike)(t)||(0,Ym.devAssert)(!1,"Must provide configuration object."),!t.types||Array.isArray(t.types)||(0,Ym.devAssert)(!1,`"types" must be Array if provided but got: ${(0,_I.inspect)(t.types)}.`),!t.directives||Array.isArray(t.directives)||(0,Ym.devAssert)(!1,`"directives" must be Array if provided but got: ${(0,_I.inspect)(t.directives)}.`),this.description=t.description,this.extensions=(0,jH.toObjMap)(t.extensions),this.astNode=t.astNode,this.extensionASTNodes=(n=t.extensionASTNodes)!==null&&n!==void 0?n:[],this._queryType=t.query,this._mutationType=t.mutation,this._subscriptionType=t.subscription,this._directives=(r=t.directives)!==null&&r!==void 0?r:eF.specifiedDirectives;let i=new Set(t.types);if(t.types!=null)for(let a of t.types)i.delete(a),Zi(a,i);this._queryType!=null&&Zi(this._queryType,i),this._mutationType!=null&&Zi(this._mutationType,i),this._subscriptionType!=null&&Zi(this._subscriptionType,i);for(let a of this._directives)if((0,eF.isDirective)(a))for(let o of a.args)Zi(o.type,i);Zi(KH.__Schema,i),this._typeMap=Object.create(null),this._subTypeMap=Object.create(null),this._implementationsMap=Object.create(null);for(let a of i){if(a==null)continue;let o=a.name;if(o||(0,Ym.devAssert)(!1,"One of the provided types for building the Schema is missing a name."),this._typeMap[o]!==void 0)throw new Error(`Schema must contain uniquely named types but contains multiple types named "${o}".`);if(this._typeMap[o]=a,(0,Xi.isInterfaceType)(a)){for(let c of a.getInterfaces())if((0,Xi.isInterfaceType)(c)){let l=this._implementationsMap[c.name];l===void 0&&(l=this._implementationsMap[c.name]={objects:[],interfaces:[]}),l.interfaces.push(a)}}else if((0,Xi.isObjectType)(a)){for(let c of a.getInterfaces())if((0,Xi.isInterfaceType)(c)){let l=this._implementationsMap[c.name];l===void 0&&(l=this._implementationsMap[c.name]={objects:[],interfaces:[]}),l.objects.push(a)}}}}get[Symbol.toStringTag](){return"GraphQLSchema"}getQueryType(){return this._queryType}getMutationType(){return this._mutationType}getSubscriptionType(){return this._subscriptionType}getRootType(t){switch(t){case gI.OperationTypeNode.QUERY:return this.getQueryType();case gI.OperationTypeNode.MUTATION:return this.getMutationType();case gI.OperationTypeNode.SUBSCRIPTION:return this.getSubscriptionType()}}getTypeMap(){return this._typeMap}getType(t){return this.getTypeMap()[t]}getPossibleTypes(t){return(0,Xi.isUnionType)(t)?t.getTypes():this.getImplementations(t).objects}getImplementations(t){let n=this._implementationsMap[t.name];return n!=null?n:{objects:[],interfaces:[]}}isSubType(t,n){let r=this._subTypeMap[t.name];if(r===void 0){if(r=Object.create(null),(0,Xi.isUnionType)(t))for(let i of t.getTypes())r[i.name]=!0;else{let i=this.getImplementations(t);for(let a of i.objects)r[a.name]=!0;for(let a of i.interfaces)r[a.name]=!0}this._subTypeMap[t.name]=r}return r[n.name]!==void 0}getDirectives(){return this._directives}getDirective(t){return this.getDirectives().find(n=>n.name===t)}toConfig(){return{description:this.description,query:this.getQueryType(),mutation:this.getMutationType(),subscription:this.getSubscriptionType(),types:Object.values(this.getTypeMap()),directives:this.getDirectives(),extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes,assumeValid:this.__validationErrors!==void 0}}};nl.GraphQLSchema=Jm;function Zi(e,t){let n=(0,Xi.getNamedType)(e);if(!t.has(n)){if(t.add(n),(0,Xi.isUnionType)(n))for(let r of n.getTypes())Zi(r,t);else if((0,Xi.isObjectType)(n)||(0,Xi.isInterfaceType)(n)){for(let r of n.getInterfaces())Zi(r,t);for(let r of Object.values(n.getFields())){Zi(r.type,t);for(let i of r.args)Zi(i.type,t)}}else if((0,Xi.isInputObjectType)(n))for(let r of Object.values(n.getFields()))Zi(r.type,t)}return t}});var zd=w(Hm=>{"use strict";m();T();N();Object.defineProperty(Hm,"__esModule",{value:!0});Hm.assertValidSchema=JH;Hm.validateSchema=oF;var gr=Yt(),$H=He(),vI=Sa(),nF=qd(),Rn=Ft(),sF=Gr(),QH=Ai(),YH=Ju();function oF(e){if((0,YH.assertSchema)(e),e.__validationErrors)return e.__validationErrors;let t=new OI(e);HH(t),zH(t),WH(t);let n=t.getErrors();return e.__validationErrors=n,n}function JH(e){let t=oF(e);if(t.length!==0)throw new Error(t.map(n=>n.message).join(` -`))}var OI=class{constructor(t){this._errors=[],this.schema=t}reportError(t,n){let r=Array.isArray(n)?n.filter(Boolean):n;this._errors.push(new $H.GraphQLError(t,{nodes:r}))}getErrors(){return this._errors}};function HH(e){let t=e.schema,n=t.getQueryType();if(!n)e.reportError("Query root type must be provided.",t.astNode);else if(!(0,Rn.isObjectType)(n)){var r;e.reportError(`Query root type must be Object type, it cannot be ${(0,gr.inspect)(n)}.`,(r=SI(t,vI.OperationTypeNode.QUERY))!==null&&r!==void 0?r:n.astNode)}let i=t.getMutationType();if(i&&!(0,Rn.isObjectType)(i)){var a;e.reportError(`Mutation root type must be Object type if provided, it cannot be ${(0,gr.inspect)(i)}.`,(a=SI(t,vI.OperationTypeNode.MUTATION))!==null&&a!==void 0?a:i.astNode)}let o=t.getSubscriptionType();if(o&&!(0,Rn.isObjectType)(o)){var c;e.reportError(`Subscription root type must be Object type if provided, it cannot be ${(0,gr.inspect)(o)}.`,(c=SI(t,vI.OperationTypeNode.SUBSCRIPTION))!==null&&c!==void 0?c:o.astNode)}}function SI(e,t){var n;return(n=[e.astNode,...e.extensionASTNodes].flatMap(r=>{var i;return(i=r==null?void 0:r.operationTypes)!==null&&i!==void 0?i:[]}).find(r=>r.operation===t))===null||n===void 0?void 0:n.type}function zH(e){for(let n of e.schema.getDirectives()){if(!(0,sF.isDirective)(n)){e.reportError(`Expected directive but got: ${(0,gr.inspect)(n)}.`,n==null?void 0:n.astNode);continue}Hu(e,n);for(let r of n.args)if(Hu(e,r),(0,Rn.isInputType)(r.type)||e.reportError(`The type of @${n.name}(${r.name}:) must be Input Type but got: ${(0,gr.inspect)(r.type)}.`,r.astNode),(0,Rn.isRequiredArgument)(r)&&r.deprecationReason!=null){var t;e.reportError(`Required argument @${n.name}(${r.name}:) cannot be deprecated.`,[DI(r.astNode),(t=r.astNode)===null||t===void 0?void 0:t.type])}}}function Hu(e,t){t.name.startsWith("__")&&e.reportError(`Name "${t.name}" must not begin with "__", which is reserved by GraphQL introspection.`,t.astNode)}function WH(e){let t=i6(e),n=e.schema.getTypeMap();for(let r of Object.values(n)){if(!(0,Rn.isNamedType)(r)){e.reportError(`Expected GraphQL named type but got: ${(0,gr.inspect)(r)}.`,r.astNode);continue}(0,QH.isIntrospectionType)(r)||Hu(e,r),(0,Rn.isObjectType)(r)||(0,Rn.isInterfaceType)(r)?(rF(e,r),iF(e,r)):(0,Rn.isUnionType)(r)?e6(e,r):(0,Rn.isEnumType)(r)?t6(e,r):(0,Rn.isInputObjectType)(r)&&(n6(e,r),t(r))}}function rF(e,t){let n=Object.values(t.getFields());n.length===0&&e.reportError(`Type ${t.name} must define one or more fields.`,[t.astNode,...t.extensionASTNodes]);for(let o of n){if(Hu(e,o),!(0,Rn.isOutputType)(o.type)){var r;e.reportError(`The type of ${t.name}.${o.name} must be Output Type but got: ${(0,gr.inspect)(o.type)}.`,(r=o.astNode)===null||r===void 0?void 0:r.type)}for(let c of o.args){let l=c.name;if(Hu(e,c),!(0,Rn.isInputType)(c.type)){var i;e.reportError(`The type of ${t.name}.${o.name}(${l}:) must be Input Type but got: ${(0,gr.inspect)(c.type)}.`,(i=c.astNode)===null||i===void 0?void 0:i.type)}if((0,Rn.isRequiredArgument)(c)&&c.deprecationReason!=null){var a;e.reportError(`Required argument ${t.name}.${o.name}(${l}:) cannot be deprecated.`,[DI(c.astNode),(a=c.astNode)===null||a===void 0?void 0:a.type])}}}}function iF(e,t){let n=Object.create(null);for(let r of t.getInterfaces()){if(!(0,Rn.isInterfaceType)(r)){e.reportError(`Type ${(0,gr.inspect)(t)} must only implement Interface types, it cannot implement ${(0,gr.inspect)(r)}.`,Hd(t,r));continue}if(t===r){e.reportError(`Type ${t.name} cannot implement itself because it would create a circular reference.`,Hd(t,r));continue}if(n[r.name]){e.reportError(`Type ${t.name} can only implement ${r.name} once.`,Hd(t,r));continue}n[r.name]=!0,ZH(e,t,r),XH(e,t,r)}}function XH(e,t,n){let r=t.getFields();for(let l of Object.values(n.getFields())){let p=l.name,f=r[p];if(!f){e.reportError(`Interface field ${n.name}.${p} expected but ${t.name} does not provide it.`,[l.astNode,t.astNode,...t.extensionASTNodes]);continue}if(!(0,nF.isTypeSubTypeOf)(e.schema,f.type,l.type)){var i,a;e.reportError(`Interface field ${n.name}.${p} expects type ${(0,gr.inspect)(l.type)} but ${t.name}.${p} is type ${(0,gr.inspect)(f.type)}.`,[(i=l.astNode)===null||i===void 0?void 0:i.type,(a=f.astNode)===null||a===void 0?void 0:a.type])}for(let y of l.args){let g=y.name,v=f.args.find(F=>F.name===g);if(!v){e.reportError(`Interface field argument ${n.name}.${p}(${g}:) expected but ${t.name}.${p} does not provide it.`,[y.astNode,f.astNode]);continue}if(!(0,nF.isEqualType)(y.type,v.type)){var o,c;e.reportError(`Interface field argument ${n.name}.${p}(${g}:) expects type ${(0,gr.inspect)(y.type)} but ${t.name}.${p}(${g}:) is type ${(0,gr.inspect)(v.type)}.`,[(o=y.astNode)===null||o===void 0?void 0:o.type,(c=v.astNode)===null||c===void 0?void 0:c.type])}}for(let y of f.args){let g=y.name;!l.args.find(F=>F.name===g)&&(0,Rn.isRequiredArgument)(y)&&e.reportError(`Object field ${t.name}.${p} includes required argument ${g} that is missing from the Interface field ${n.name}.${p}.`,[y.astNode,l.astNode])}}}function ZH(e,t,n){let r=t.getInterfaces();for(let i of n.getInterfaces())r.includes(i)||e.reportError(i===t?`Type ${t.name} cannot implement ${n.name} because it would create a circular reference.`:`Type ${t.name} must implement ${i.name} because it is implemented by ${n.name}.`,[...Hd(n,i),...Hd(t,n)])}function e6(e,t){let n=t.getTypes();n.length===0&&e.reportError(`Union type ${t.name} must define one or more member types.`,[t.astNode,...t.extensionASTNodes]);let r=Object.create(null);for(let i of n){if(r[i.name]){e.reportError(`Union type ${t.name} can only include type ${i.name} once.`,aF(t,i.name));continue}r[i.name]=!0,(0,Rn.isObjectType)(i)||e.reportError(`Union type ${t.name} can only include Object types, it cannot include ${(0,gr.inspect)(i)}.`,aF(t,String(i)))}}function t6(e,t){let n=t.getValues();n.length===0&&e.reportError(`Enum type ${t.name} must define one or more values.`,[t.astNode,...t.extensionASTNodes]);for(let r of n)Hu(e,r)}function n6(e,t){let n=Object.values(t.getFields());n.length===0&&e.reportError(`Input Object type ${t.name} must define one or more fields.`,[t.astNode,...t.extensionASTNodes]);for(let a of n){if(Hu(e,a),!(0,Rn.isInputType)(a.type)){var r;e.reportError(`The type of ${t.name}.${a.name} must be Input Type but got: ${(0,gr.inspect)(a.type)}.`,(r=a.astNode)===null||r===void 0?void 0:r.type)}if((0,Rn.isRequiredInputField)(a)&&a.deprecationReason!=null){var i;e.reportError(`Required input field ${t.name}.${a.name} cannot be deprecated.`,[DI(a.astNode),(i=a.astNode)===null||i===void 0?void 0:i.type])}t.isOneOf&&r6(t,a,e)}}function r6(e,t,n){if((0,Rn.isNonNullType)(t.type)){var r;n.reportError(`OneOf input field ${e.name}.${t.name} must be nullable.`,(r=t.astNode)===null||r===void 0?void 0:r.type)}t.defaultValue!==void 0&&n.reportError(`OneOf input field ${e.name}.${t.name} cannot have a default value.`,t.astNode)}function i6(e){let t=Object.create(null),n=[],r=Object.create(null);return i;function i(a){if(t[a.name])return;t[a.name]=!0,r[a.name]=n.length;let o=Object.values(a.getFields());for(let c of o)if((0,Rn.isNonNullType)(c.type)&&(0,Rn.isInputObjectType)(c.type.ofType)){let l=c.type.ofType,p=r[l.name];if(n.push(c),p===void 0)i(l);else{let f=n.slice(p),y=f.map(g=>g.name).join(".");e.reportError(`Cannot reference Input Object "${l.name}" within itself through a series of non-null fields: "${y}".`,f.map(g=>g.astNode))}n.pop()}r[a.name]=void 0}}function Hd(e,t){let{astNode:n,extensionASTNodes:r}=e;return(n!=null?[n,...r]:r).flatMap(a=>{var o;return(o=a.interfaces)!==null&&o!==void 0?o:[]}).filter(a=>a.name.value===t.name)}function aF(e,t){let{astNode:n,extensionASTNodes:r}=e;return(n!=null?[n,...r]:r).flatMap(a=>{var o;return(o=a.types)!==null&&o!==void 0?o:[]}).filter(a=>a.name.value===t)}function DI(e){var t;return e==null||(t=e.directives)===null||t===void 0?void 0:t.find(n=>n.name.value===sF.GraphQLDeprecatedDirective.name)}});var Aa=w(RI=>{"use strict";m();T();N();Object.defineProperty(RI,"__esModule",{value:!0});RI.typeFromAST=AI;var bI=Pt(),uF=Ft();function AI(e,t){switch(t.kind){case bI.Kind.LIST_TYPE:{let n=AI(e,t.type);return n&&new uF.GraphQLList(n)}case bI.Kind.NON_NULL_TYPE:{let n=AI(e,t.type);return n&&new uF.GraphQLNonNull(n)}case bI.Kind.NAMED_TYPE:return e.getType(t.name.value)}}});var zm=w(Wd=>{"use strict";m();T();N();Object.defineProperty(Wd,"__esModule",{value:!0});Wd.TypeInfo=void 0;Wd.visitWithTypeInfo=o6;var a6=Sa(),Pn=Pt(),cF=ju(),Fn=Ft(),rl=Ai(),lF=Aa(),PI=class{constructor(t,n,r){this._schema=t,this._typeStack=[],this._parentTypeStack=[],this._inputTypeStack=[],this._fieldDefStack=[],this._defaultValueStack=[],this._directive=null,this._argument=null,this._enumValue=null,this._getFieldDef=r!=null?r:s6,n&&((0,Fn.isInputType)(n)&&this._inputTypeStack.push(n),(0,Fn.isCompositeType)(n)&&this._parentTypeStack.push(n),(0,Fn.isOutputType)(n)&&this._typeStack.push(n))}get[Symbol.toStringTag](){return"TypeInfo"}getType(){if(this._typeStack.length>0)return this._typeStack[this._typeStack.length-1]}getParentType(){if(this._parentTypeStack.length>0)return this._parentTypeStack[this._parentTypeStack.length-1]}getInputType(){if(this._inputTypeStack.length>0)return this._inputTypeStack[this._inputTypeStack.length-1]}getParentInputType(){if(this._inputTypeStack.length>1)return this._inputTypeStack[this._inputTypeStack.length-2]}getFieldDef(){if(this._fieldDefStack.length>0)return this._fieldDefStack[this._fieldDefStack.length-1]}getDefaultValue(){if(this._defaultValueStack.length>0)return this._defaultValueStack[this._defaultValueStack.length-1]}getDirective(){return this._directive}getArgument(){return this._argument}getEnumValue(){return this._enumValue}enter(t){let n=this._schema;switch(t.kind){case Pn.Kind.SELECTION_SET:{let i=(0,Fn.getNamedType)(this.getType());this._parentTypeStack.push((0,Fn.isCompositeType)(i)?i:void 0);break}case Pn.Kind.FIELD:{let i=this.getParentType(),a,o;i&&(a=this._getFieldDef(n,i,t),a&&(o=a.type)),this._fieldDefStack.push(a),this._typeStack.push((0,Fn.isOutputType)(o)?o:void 0);break}case Pn.Kind.DIRECTIVE:this._directive=n.getDirective(t.name.value);break;case Pn.Kind.OPERATION_DEFINITION:{let i=n.getRootType(t.operation);this._typeStack.push((0,Fn.isObjectType)(i)?i:void 0);break}case Pn.Kind.INLINE_FRAGMENT:case Pn.Kind.FRAGMENT_DEFINITION:{let i=t.typeCondition,a=i?(0,lF.typeFromAST)(n,i):(0,Fn.getNamedType)(this.getType());this._typeStack.push((0,Fn.isOutputType)(a)?a:void 0);break}case Pn.Kind.VARIABLE_DEFINITION:{let i=(0,lF.typeFromAST)(n,t.type);this._inputTypeStack.push((0,Fn.isInputType)(i)?i:void 0);break}case Pn.Kind.ARGUMENT:{var r;let i,a,o=(r=this.getDirective())!==null&&r!==void 0?r:this.getFieldDef();o&&(i=o.args.find(c=>c.name===t.name.value),i&&(a=i.type)),this._argument=i,this._defaultValueStack.push(i?i.defaultValue:void 0),this._inputTypeStack.push((0,Fn.isInputType)(a)?a:void 0);break}case Pn.Kind.LIST:{let i=(0,Fn.getNullableType)(this.getInputType()),a=(0,Fn.isListType)(i)?i.ofType:i;this._defaultValueStack.push(void 0),this._inputTypeStack.push((0,Fn.isInputType)(a)?a:void 0);break}case Pn.Kind.OBJECT_FIELD:{let i=(0,Fn.getNamedType)(this.getInputType()),a,o;(0,Fn.isInputObjectType)(i)&&(o=i.getFields()[t.name.value],o&&(a=o.type)),this._defaultValueStack.push(o?o.defaultValue:void 0),this._inputTypeStack.push((0,Fn.isInputType)(a)?a:void 0);break}case Pn.Kind.ENUM:{let i=(0,Fn.getNamedType)(this.getInputType()),a;(0,Fn.isEnumType)(i)&&(a=i.getValue(t.value)),this._enumValue=a;break}default:}}leave(t){switch(t.kind){case Pn.Kind.SELECTION_SET:this._parentTypeStack.pop();break;case Pn.Kind.FIELD:this._fieldDefStack.pop(),this._typeStack.pop();break;case Pn.Kind.DIRECTIVE:this._directive=null;break;case Pn.Kind.OPERATION_DEFINITION:case Pn.Kind.INLINE_FRAGMENT:case Pn.Kind.FRAGMENT_DEFINITION:this._typeStack.pop();break;case Pn.Kind.VARIABLE_DEFINITION:this._inputTypeStack.pop();break;case Pn.Kind.ARGUMENT:this._argument=null,this._defaultValueStack.pop(),this._inputTypeStack.pop();break;case Pn.Kind.LIST:case Pn.Kind.OBJECT_FIELD:this._defaultValueStack.pop(),this._inputTypeStack.pop();break;case Pn.Kind.ENUM:this._enumValue=null;break;default:}}};Wd.TypeInfo=PI;function s6(e,t,n){let r=n.name.value;if(r===rl.SchemaMetaFieldDef.name&&e.getQueryType()===t)return rl.SchemaMetaFieldDef;if(r===rl.TypeMetaFieldDef.name&&e.getQueryType()===t)return rl.TypeMetaFieldDef;if(r===rl.TypeNameMetaFieldDef.name&&(0,Fn.isCompositeType)(t))return rl.TypeNameMetaFieldDef;if((0,Fn.isObjectType)(t)||(0,Fn.isInterfaceType)(t))return t.getFields()[r]}function o6(e,t){return{enter(...n){let r=n[0];e.enter(r);let i=(0,cF.getEnterLeaveForKind)(t,r.kind).enter;if(i){let a=i.apply(t,n);return a!==void 0&&(e.leave(r),(0,a6.isNode)(a)&&e.enter(a)),a}},leave(...n){let r=n[0],i=(0,cF.getEnterLeaveForKind)(t,r.kind).leave,a;return i&&(a=i.apply(t,n)),e.leave(r),a}}}});var zu=w(Ri=>{"use strict";m();T();N();Object.defineProperty(Ri,"__esModule",{value:!0});Ri.isConstValueNode=FI;Ri.isDefinitionNode=u6;Ri.isExecutableDefinitionNode=dF;Ri.isSelectionNode=c6;Ri.isTypeDefinitionNode=mF;Ri.isTypeExtensionNode=TF;Ri.isTypeNode=l6;Ri.isTypeSystemDefinitionNode=fF;Ri.isTypeSystemExtensionNode=NF;Ri.isValueNode=pF;var wt=Pt();function u6(e){return dF(e)||fF(e)||NF(e)}function dF(e){return e.kind===wt.Kind.OPERATION_DEFINITION||e.kind===wt.Kind.FRAGMENT_DEFINITION}function c6(e){return e.kind===wt.Kind.FIELD||e.kind===wt.Kind.FRAGMENT_SPREAD||e.kind===wt.Kind.INLINE_FRAGMENT}function pF(e){return e.kind===wt.Kind.VARIABLE||e.kind===wt.Kind.INT||e.kind===wt.Kind.FLOAT||e.kind===wt.Kind.STRING||e.kind===wt.Kind.BOOLEAN||e.kind===wt.Kind.NULL||e.kind===wt.Kind.ENUM||e.kind===wt.Kind.LIST||e.kind===wt.Kind.OBJECT}function FI(e){return pF(e)&&(e.kind===wt.Kind.LIST?e.values.some(FI):e.kind===wt.Kind.OBJECT?e.fields.some(t=>FI(t.value)):e.kind!==wt.Kind.VARIABLE)}function l6(e){return e.kind===wt.Kind.NAMED_TYPE||e.kind===wt.Kind.LIST_TYPE||e.kind===wt.Kind.NON_NULL_TYPE}function fF(e){return e.kind===wt.Kind.SCHEMA_DEFINITION||mF(e)||e.kind===wt.Kind.DIRECTIVE_DEFINITION}function mF(e){return e.kind===wt.Kind.SCALAR_TYPE_DEFINITION||e.kind===wt.Kind.OBJECT_TYPE_DEFINITION||e.kind===wt.Kind.INTERFACE_TYPE_DEFINITION||e.kind===wt.Kind.UNION_TYPE_DEFINITION||e.kind===wt.Kind.ENUM_TYPE_DEFINITION||e.kind===wt.Kind.INPUT_OBJECT_TYPE_DEFINITION}function NF(e){return e.kind===wt.Kind.SCHEMA_EXTENSION||TF(e)}function TF(e){return e.kind===wt.Kind.SCALAR_TYPE_EXTENSION||e.kind===wt.Kind.OBJECT_TYPE_EXTENSION||e.kind===wt.Kind.INTERFACE_TYPE_EXTENSION||e.kind===wt.Kind.UNION_TYPE_EXTENSION||e.kind===wt.Kind.ENUM_TYPE_EXTENSION||e.kind===wt.Kind.INPUT_OBJECT_TYPE_EXTENSION}});var LI=w(wI=>{"use strict";m();T();N();Object.defineProperty(wI,"__esModule",{value:!0});wI.ExecutableDefinitionsRule=f6;var d6=He(),EF=Pt(),p6=zu();function f6(e){return{Document(t){for(let n of t.definitions)if(!(0,p6.isExecutableDefinitionNode)(n)){let r=n.kind===EF.Kind.SCHEMA_DEFINITION||n.kind===EF.Kind.SCHEMA_EXTENSION?"schema":'"'+n.name.value+'"';e.reportError(new d6.GraphQLError(`The ${r} definition is not executable.`,{nodes:n}))}return!1}}}});var BI=w(CI=>{"use strict";m();T();N();Object.defineProperty(CI,"__esModule",{value:!0});CI.FieldsOnCorrectTypeRule=E6;var hF=zo(),m6=Cd(),N6=Xo(),T6=He(),Xd=Ft();function E6(e){return{Field(t){let n=e.getParentType();if(n&&!e.getFieldDef()){let i=e.getSchema(),a=t.name.value,o=(0,hF.didYouMean)("to use an inline fragment on",h6(i,n,a));o===""&&(o=(0,hF.didYouMean)(y6(n,a))),e.reportError(new T6.GraphQLError(`Cannot query field "${a}" on type "${n.name}".`+o,{nodes:t}))}}}}function h6(e,t,n){if(!(0,Xd.isAbstractType)(t))return[];let r=new Set,i=Object.create(null);for(let o of e.getPossibleTypes(t))if(o.getFields()[n]){r.add(o),i[o.name]=1;for(let c of o.getInterfaces()){var a;c.getFields()[n]&&(r.add(c),i[c.name]=((a=i[c.name])!==null&&a!==void 0?a:0)+1)}}return[...r].sort((o,c)=>{let l=i[c.name]-i[o.name];return l!==0?l:(0,Xd.isInterfaceType)(o)&&e.isSubType(o,c)?-1:(0,Xd.isInterfaceType)(c)&&e.isSubType(c,o)?1:(0,m6.naturalCompare)(o.name,c.name)}).map(o=>o.name)}function y6(e,t){if((0,Xd.isObjectType)(e)||(0,Xd.isInterfaceType)(e)){let n=Object.keys(e.getFields());return(0,N6.suggestionList)(t,n)}return[]}});var kI=w(UI=>{"use strict";m();T();N();Object.defineProperty(UI,"__esModule",{value:!0});UI.FragmentsOnCompositeTypesRule=I6;var yF=He(),IF=ci(),gF=Ft(),_F=Aa();function I6(e){return{InlineFragment(t){let n=t.typeCondition;if(n){let r=(0,_F.typeFromAST)(e.getSchema(),n);if(r&&!(0,gF.isCompositeType)(r)){let i=(0,IF.print)(n);e.reportError(new yF.GraphQLError(`Fragment cannot condition on non composite type "${i}".`,{nodes:n}))}}},FragmentDefinition(t){let n=(0,_F.typeFromAST)(e.getSchema(),t.typeCondition);if(n&&!(0,gF.isCompositeType)(n)){let r=(0,IF.print)(t.typeCondition);e.reportError(new yF.GraphQLError(`Fragment "${t.name.value}" cannot condition on non composite type "${r}".`,{nodes:t.typeCondition}))}}}}});var MI=w(Wm=>{"use strict";m();T();N();Object.defineProperty(Wm,"__esModule",{value:!0});Wm.KnownArgumentNamesOnDirectivesRule=DF;Wm.KnownArgumentNamesRule=v6;var vF=zo(),SF=Xo(),OF=He(),g6=Pt(),_6=Gr();function v6(e){return Y(x({},DF(e)),{Argument(t){let n=e.getArgument(),r=e.getFieldDef(),i=e.getParentType();if(!n&&r&&i){let a=t.name.value,o=r.args.map(l=>l.name),c=(0,SF.suggestionList)(a,o);e.reportError(new OF.GraphQLError(`Unknown argument "${a}" on field "${i.name}.${r.name}".`+(0,vF.didYouMean)(c),{nodes:t}))}}})}function DF(e){let t=Object.create(null),n=e.getSchema(),r=n?n.getDirectives():_6.specifiedDirectives;for(let o of r)t[o.name]=o.args.map(c=>c.name);let i=e.getDocument().definitions;for(let o of i)if(o.kind===g6.Kind.DIRECTIVE_DEFINITION){var a;let c=(a=o.arguments)!==null&&a!==void 0?a:[];t[o.name.value]=c.map(l=>l.name.value)}return{Directive(o){let c=o.name.value,l=t[c];if(o.arguments&&l)for(let p of o.arguments){let f=p.name.value;if(!l.includes(f)){let y=(0,SF.suggestionList)(f,l);e.reportError(new OF.GraphQLError(`Unknown argument "${f}" on directive "@${c}".`+(0,vF.didYouMean)(y),{nodes:p}))}}return!1}}}});var jI=w(VI=>{"use strict";m();T();N();Object.defineProperty(VI,"__esModule",{value:!0});VI.KnownDirectivesRule=D6;var S6=Yt(),xI=yr(),bF=He(),qI=Sa(),Xn=zc(),En=Pt(),O6=Gr();function D6(e){let t=Object.create(null),n=e.getSchema(),r=n?n.getDirectives():O6.specifiedDirectives;for(let a of r)t[a.name]=a.locations;let i=e.getDocument().definitions;for(let a of i)a.kind===En.Kind.DIRECTIVE_DEFINITION&&(t[a.name.value]=a.locations.map(o=>o.value));return{Directive(a,o,c,l,p){let f=a.name.value,y=t[f];if(!y){e.reportError(new bF.GraphQLError(`Unknown directive "@${f}".`,{nodes:a}));return}let g=b6(p);g&&!y.includes(g)&&e.reportError(new bF.GraphQLError(`Directive "@${f}" may not be used on ${g}.`,{nodes:a}))}}}function b6(e){let t=e[e.length-1];switch("kind"in t||(0,xI.invariant)(!1),t.kind){case En.Kind.OPERATION_DEFINITION:return A6(t.operation);case En.Kind.FIELD:return Xn.DirectiveLocation.FIELD;case En.Kind.FRAGMENT_SPREAD:return Xn.DirectiveLocation.FRAGMENT_SPREAD;case En.Kind.INLINE_FRAGMENT:return Xn.DirectiveLocation.INLINE_FRAGMENT;case En.Kind.FRAGMENT_DEFINITION:return Xn.DirectiveLocation.FRAGMENT_DEFINITION;case En.Kind.VARIABLE_DEFINITION:return Xn.DirectiveLocation.VARIABLE_DEFINITION;case En.Kind.SCHEMA_DEFINITION:case En.Kind.SCHEMA_EXTENSION:return Xn.DirectiveLocation.SCHEMA;case En.Kind.SCALAR_TYPE_DEFINITION:case En.Kind.SCALAR_TYPE_EXTENSION:return Xn.DirectiveLocation.SCALAR;case En.Kind.OBJECT_TYPE_DEFINITION:case En.Kind.OBJECT_TYPE_EXTENSION:return Xn.DirectiveLocation.OBJECT;case En.Kind.FIELD_DEFINITION:return Xn.DirectiveLocation.FIELD_DEFINITION;case En.Kind.INTERFACE_TYPE_DEFINITION:case En.Kind.INTERFACE_TYPE_EXTENSION:return Xn.DirectiveLocation.INTERFACE;case En.Kind.UNION_TYPE_DEFINITION:case En.Kind.UNION_TYPE_EXTENSION:return Xn.DirectiveLocation.UNION;case En.Kind.ENUM_TYPE_DEFINITION:case En.Kind.ENUM_TYPE_EXTENSION:return Xn.DirectiveLocation.ENUM;case En.Kind.ENUM_VALUE_DEFINITION:return Xn.DirectiveLocation.ENUM_VALUE;case En.Kind.INPUT_OBJECT_TYPE_DEFINITION:case En.Kind.INPUT_OBJECT_TYPE_EXTENSION:return Xn.DirectiveLocation.INPUT_OBJECT;case En.Kind.INPUT_VALUE_DEFINITION:{let n=e[e.length-3];return"kind"in n||(0,xI.invariant)(!1),n.kind===En.Kind.INPUT_OBJECT_TYPE_DEFINITION?Xn.DirectiveLocation.INPUT_FIELD_DEFINITION:Xn.DirectiveLocation.ARGUMENT_DEFINITION}default:(0,xI.invariant)(!1,"Unexpected kind: "+(0,S6.inspect)(t.kind))}}function A6(e){switch(e){case qI.OperationTypeNode.QUERY:return Xn.DirectiveLocation.QUERY;case qI.OperationTypeNode.MUTATION:return Xn.DirectiveLocation.MUTATION;case qI.OperationTypeNode.SUBSCRIPTION:return Xn.DirectiveLocation.SUBSCRIPTION}}});var GI=w(KI=>{"use strict";m();T();N();Object.defineProperty(KI,"__esModule",{value:!0});KI.KnownFragmentNamesRule=P6;var R6=He();function P6(e){return{FragmentSpread(t){let n=t.name.value;e.getFragment(n)||e.reportError(new R6.GraphQLError(`Unknown fragment "${n}".`,{nodes:t.name}))}}}});var YI=w(QI=>{"use strict";m();T();N();Object.defineProperty(QI,"__esModule",{value:!0});QI.KnownTypeNamesRule=U6;var F6=zo(),w6=Xo(),L6=He(),$I=zu(),C6=Ai(),B6=ba();function U6(e){let t=e.getSchema(),n=t?t.getTypeMap():Object.create(null),r=Object.create(null);for(let a of e.getDocument().definitions)(0,$I.isTypeDefinitionNode)(a)&&(r[a.name.value]=!0);let i=[...Object.keys(n),...Object.keys(r)];return{NamedType(a,o,c,l,p){let f=a.name.value;if(!n[f]&&!r[f]){var y;let g=(y=p[2])!==null&&y!==void 0?y:c,v=g!=null&&k6(g);if(v&&AF.includes(f))return;let F=(0,w6.suggestionList)(f,v?AF.concat(i):i);e.reportError(new L6.GraphQLError(`Unknown type "${f}".`+(0,F6.didYouMean)(F),{nodes:a}))}}}}var AF=[...B6.specifiedScalarTypes,...C6.introspectionTypes].map(e=>e.name);function k6(e){return"kind"in e&&((0,$I.isTypeSystemDefinitionNode)(e)||(0,$I.isTypeSystemExtensionNode)(e))}});var HI=w(JI=>{"use strict";m();T();N();Object.defineProperty(JI,"__esModule",{value:!0});JI.LoneAnonymousOperationRule=q6;var M6=He(),x6=Pt();function q6(e){let t=0;return{Document(n){t=n.definitions.filter(r=>r.kind===x6.Kind.OPERATION_DEFINITION).length},OperationDefinition(n){!n.name&&t>1&&e.reportError(new M6.GraphQLError("This anonymous operation must be the only defined operation.",{nodes:n}))}}}});var WI=w(zI=>{"use strict";m();T();N();Object.defineProperty(zI,"__esModule",{value:!0});zI.LoneSchemaDefinitionRule=V6;var RF=He();function V6(e){var t,n,r;let i=e.getSchema(),a=(t=(n=(r=i==null?void 0:i.astNode)!==null&&r!==void 0?r:i==null?void 0:i.getQueryType())!==null&&n!==void 0?n:i==null?void 0:i.getMutationType())!==null&&t!==void 0?t:i==null?void 0:i.getSubscriptionType(),o=0;return{SchemaDefinition(c){if(a){e.reportError(new RF.GraphQLError("Cannot define a new schema within a schema extension.",{nodes:c}));return}o>0&&e.reportError(new RF.GraphQLError("Must provide only one schema definition.",{nodes:c})),++o}}}});var ZI=w(XI=>{"use strict";m();T();N();Object.defineProperty(XI,"__esModule",{value:!0});XI.MaxIntrospectionDepthRule=G6;var j6=He(),PF=Pt(),K6=3;function G6(e){function t(n,r=Object.create(null),i=0){if(n.kind===PF.Kind.FRAGMENT_SPREAD){let a=n.name.value;if(r[a]===!0)return!1;let o=e.getFragment(a);if(!o)return!1;try{return r[a]=!0,t(o,r,i)}finally{r[a]=void 0}}if(n.kind===PF.Kind.FIELD&&(n.name.value==="fields"||n.name.value==="interfaces"||n.name.value==="possibleTypes"||n.name.value==="inputFields")&&(i++,i>=K6))return!0;if("selectionSet"in n&&n.selectionSet){for(let a of n.selectionSet.selections)if(t(a,r,i))return!0}return!1}return{Field(n){if((n.name.value==="__schema"||n.name.value==="__type")&&t(n))return e.reportError(new j6.GraphQLError("Maximum introspection depth exceeded",{nodes:[n]})),!1}}}});var tg=w(eg=>{"use strict";m();T();N();Object.defineProperty(eg,"__esModule",{value:!0});eg.NoFragmentCyclesRule=Q6;var $6=He();function Q6(e){let t=Object.create(null),n=[],r=Object.create(null);return{OperationDefinition:()=>!1,FragmentDefinition(a){return i(a),!1}};function i(a){if(t[a.name.value])return;let o=a.name.value;t[o]=!0;let c=e.getFragmentSpreads(a.selectionSet);if(c.length!==0){r[o]=n.length;for(let l of c){let p=l.name.value,f=r[p];if(n.push(l),f===void 0){let y=e.getFragment(p);y&&i(y)}else{let y=n.slice(f),g=y.slice(0,-1).map(v=>'"'+v.name.value+'"').join(", ");e.reportError(new $6.GraphQLError(`Cannot spread fragment "${p}" within itself`+(g!==""?` via ${g}.`:"."),{nodes:y}))}n.pop()}r[o]=void 0}}}});var rg=w(ng=>{"use strict";m();T();N();Object.defineProperty(ng,"__esModule",{value:!0});ng.NoUndefinedVariablesRule=J6;var Y6=He();function J6(e){let t=Object.create(null);return{OperationDefinition:{enter(){t=Object.create(null)},leave(n){let r=e.getRecursiveVariableUsages(n);for(let{node:i}of r){let a=i.name.value;t[a]!==!0&&e.reportError(new Y6.GraphQLError(n.name?`Variable "$${a}" is not defined by operation "${n.name.value}".`:`Variable "$${a}" is not defined.`,{nodes:[i,n]}))}}},VariableDefinition(n){t[n.variable.name.value]=!0}}}});var ag=w(ig=>{"use strict";m();T();N();Object.defineProperty(ig,"__esModule",{value:!0});ig.NoUnusedFragmentsRule=z6;var H6=He();function z6(e){let t=[],n=[];return{OperationDefinition(r){return t.push(r),!1},FragmentDefinition(r){return n.push(r),!1},Document:{leave(){let r=Object.create(null);for(let i of t)for(let a of e.getRecursivelyReferencedFragments(i))r[a.name.value]=!0;for(let i of n){let a=i.name.value;r[a]!==!0&&e.reportError(new H6.GraphQLError(`Fragment "${a}" is never used.`,{nodes:i}))}}}}}});var og=w(sg=>{"use strict";m();T();N();Object.defineProperty(sg,"__esModule",{value:!0});sg.NoUnusedVariablesRule=X6;var W6=He();function X6(e){let t=[];return{OperationDefinition:{enter(){t=[]},leave(n){let r=Object.create(null),i=e.getRecursiveVariableUsages(n);for(let{node:a}of i)r[a.name.value]=!0;for(let a of t){let o=a.variable.name.value;r[o]!==!0&&e.reportError(new W6.GraphQLError(n.name?`Variable "$${o}" is never used in operation "${n.name.value}".`:`Variable "$${o}" is never used.`,{nodes:a}))}}},VariableDefinition(n){t.push(n)}}}});var lg=w(cg=>{"use strict";m();T();N();Object.defineProperty(cg,"__esModule",{value:!0});cg.sortValueNode=ug;var Z6=Cd(),ds=Pt();function ug(e){switch(e.kind){case ds.Kind.OBJECT:return Y(x({},e),{fields:ez(e.fields)});case ds.Kind.LIST:return Y(x({},e),{values:e.values.map(ug)});case ds.Kind.INT:case ds.Kind.FLOAT:case ds.Kind.STRING:case ds.Kind.BOOLEAN:case ds.Kind.NULL:case ds.Kind.ENUM:case ds.Kind.VARIABLE:return e}}function ez(e){return e.map(t=>Y(x({},t),{value:ug(t.value)})).sort((t,n)=>(0,Z6.naturalCompare)(t.name.value,n.name.value))}});var Eg=w(Tg=>{"use strict";m();T();N();Object.defineProperty(Tg,"__esModule",{value:!0});Tg.OverlappingFieldsCanBeMergedRule=iz;var FF=Yt(),tz=He(),dg=Pt(),nz=ci(),$r=Ft(),rz=lg(),LF=Aa();function CF(e){return Array.isArray(e)?e.map(([t,n])=>`subfields "${t}" conflict because `+CF(n)).join(" and "):e}function iz(e){let t=new mg,n=new Map;return{SelectionSet(r){let i=az(e,n,t,e.getParentType(),r);for(let[[a,o],c,l]of i){let p=CF(o);e.reportError(new tz.GraphQLError(`Fields "${a}" conflict because ${p}. Use different aliases on the fields to fetch both if this was intentional.`,{nodes:c.concat(l)}))}}}}function az(e,t,n,r,i){let a=[],[o,c]=eN(e,t,r,i);if(oz(e,a,t,n,o),c.length!==0)for(let l=0;l1)for(let c=0;c[a.value,o]));return n.every(a=>{let o=a.value,c=i.get(a.name.value);return c===void 0?!1:wF(o)===wF(c)})}function wF(e){return(0,nz.print)((0,rz.sortValueNode)(e))}function pg(e,t){return(0,$r.isListType)(e)?(0,$r.isListType)(t)?pg(e.ofType,t.ofType):!0:(0,$r.isListType)(t)?!0:(0,$r.isNonNullType)(e)?(0,$r.isNonNullType)(t)?pg(e.ofType,t.ofType):!0:(0,$r.isNonNullType)(t)?!0:(0,$r.isLeafType)(e)||(0,$r.isLeafType)(t)?e!==t:!1}function eN(e,t,n,r){let i=t.get(r);if(i)return i;let a=Object.create(null),o=Object.create(null);UF(e,n,r,a,o);let c=[a,Object.keys(o)];return t.set(r,c),c}function fg(e,t,n){let r=t.get(n.selectionSet);if(r)return r;let i=(0,LF.typeFromAST)(e.getSchema(),n.typeCondition);return eN(e,t,i,n.selectionSet)}function UF(e,t,n,r,i){for(let a of n.selections)switch(a.kind){case dg.Kind.FIELD:{let o=a.name.value,c;((0,$r.isObjectType)(t)||(0,$r.isInterfaceType)(t))&&(c=t.getFields()[o]);let l=a.alias?a.alias.value:o;r[l]||(r[l]=[]),r[l].push([t,a,c]);break}case dg.Kind.FRAGMENT_SPREAD:i[a.name.value]=!0;break;case dg.Kind.INLINE_FRAGMENT:{let o=a.typeCondition,c=o?(0,LF.typeFromAST)(e.getSchema(),o):t;UF(e,c,a.selectionSet,r,i);break}}}function cz(e,t,n,r){if(e.length>0)return[[t,e.map(([i])=>i)],[n,...e.map(([,i])=>i).flat()],[r,...e.map(([,,i])=>i).flat()]]}var mg=class{constructor(){this._data=new Map}has(t,n,r){var i;let[a,o]=t{"use strict";m();T();N();Object.defineProperty(yg,"__esModule",{value:!0});yg.PossibleFragmentSpreadsRule=dz;var tN=Yt(),kF=He(),hg=Ft(),MF=qd(),lz=Aa();function dz(e){return{InlineFragment(t){let n=e.getType(),r=e.getParentType();if((0,hg.isCompositeType)(n)&&(0,hg.isCompositeType)(r)&&!(0,MF.doTypesOverlap)(e.getSchema(),n,r)){let i=(0,tN.inspect)(r),a=(0,tN.inspect)(n);e.reportError(new kF.GraphQLError(`Fragment cannot be spread here as objects of type "${i}" can never be of type "${a}".`,{nodes:t}))}},FragmentSpread(t){let n=t.name.value,r=pz(e,n),i=e.getParentType();if(r&&i&&!(0,MF.doTypesOverlap)(e.getSchema(),r,i)){let a=(0,tN.inspect)(i),o=(0,tN.inspect)(r);e.reportError(new kF.GraphQLError(`Fragment "${n}" cannot be spread here as objects of type "${a}" can never be of type "${o}".`,{nodes:t}))}}}}function pz(e,t){let n=e.getFragment(t);if(n){let r=(0,lz.typeFromAST)(e.getSchema(),n.typeCondition);if((0,hg.isCompositeType)(r))return r}}});var _g=w(gg=>{"use strict";m();T();N();Object.defineProperty(gg,"__esModule",{value:!0});gg.PossibleTypeExtensionsRule=Tz;var fz=zo(),qF=Yt(),VF=yr(),mz=Xo(),xF=He(),In=Pt(),Nz=zu(),il=Ft();function Tz(e){let t=e.getSchema(),n=Object.create(null);for(let i of e.getDocument().definitions)(0,Nz.isTypeDefinitionNode)(i)&&(n[i.name.value]=i);return{ScalarTypeExtension:r,ObjectTypeExtension:r,InterfaceTypeExtension:r,UnionTypeExtension:r,EnumTypeExtension:r,InputObjectTypeExtension:r};function r(i){let a=i.name.value,o=n[a],c=t==null?void 0:t.getType(a),l;if(o?l=Ez[o.kind]:c&&(l=hz(c)),l){if(l!==i.kind){let p=yz(i.kind);e.reportError(new xF.GraphQLError(`Cannot extend non-${p} type "${a}".`,{nodes:o?[o,i]:i}))}}else{let p=Object.keys(x(x({},n),t==null?void 0:t.getTypeMap())),f=(0,mz.suggestionList)(a,p);e.reportError(new xF.GraphQLError(`Cannot extend type "${a}" because it is not defined.`+(0,fz.didYouMean)(f),{nodes:i.name}))}}}var Ez={[In.Kind.SCALAR_TYPE_DEFINITION]:In.Kind.SCALAR_TYPE_EXTENSION,[In.Kind.OBJECT_TYPE_DEFINITION]:In.Kind.OBJECT_TYPE_EXTENSION,[In.Kind.INTERFACE_TYPE_DEFINITION]:In.Kind.INTERFACE_TYPE_EXTENSION,[In.Kind.UNION_TYPE_DEFINITION]:In.Kind.UNION_TYPE_EXTENSION,[In.Kind.ENUM_TYPE_DEFINITION]:In.Kind.ENUM_TYPE_EXTENSION,[In.Kind.INPUT_OBJECT_TYPE_DEFINITION]:In.Kind.INPUT_OBJECT_TYPE_EXTENSION};function hz(e){if((0,il.isScalarType)(e))return In.Kind.SCALAR_TYPE_EXTENSION;if((0,il.isObjectType)(e))return In.Kind.OBJECT_TYPE_EXTENSION;if((0,il.isInterfaceType)(e))return In.Kind.INTERFACE_TYPE_EXTENSION;if((0,il.isUnionType)(e))return In.Kind.UNION_TYPE_EXTENSION;if((0,il.isEnumType)(e))return In.Kind.ENUM_TYPE_EXTENSION;if((0,il.isInputObjectType)(e))return In.Kind.INPUT_OBJECT_TYPE_EXTENSION;(0,VF.invariant)(!1,"Unexpected type: "+(0,qF.inspect)(e))}function yz(e){switch(e){case In.Kind.SCALAR_TYPE_EXTENSION:return"scalar";case In.Kind.OBJECT_TYPE_EXTENSION:return"object";case In.Kind.INTERFACE_TYPE_EXTENSION:return"interface";case In.Kind.UNION_TYPE_EXTENSION:return"union";case In.Kind.ENUM_TYPE_EXTENSION:return"enum";case In.Kind.INPUT_OBJECT_TYPE_EXTENSION:return"input object";default:(0,VF.invariant)(!1,"Unexpected kind: "+(0,qF.inspect)(e))}}});var Sg=w(nN=>{"use strict";m();T();N();Object.defineProperty(nN,"__esModule",{value:!0});nN.ProvidedRequiredArgumentsOnDirectivesRule=QF;nN.ProvidedRequiredArgumentsRule=_z;var KF=Yt(),jF=Wo(),GF=He(),$F=Pt(),Iz=ci(),vg=Ft(),gz=Gr();function _z(e){return Y(x({},QF(e)),{Field:{leave(t){var n;let r=e.getFieldDef();if(!r)return!1;let i=new Set((n=t.arguments)===null||n===void 0?void 0:n.map(a=>a.name.value));for(let a of r.args)if(!i.has(a.name)&&(0,vg.isRequiredArgument)(a)){let o=(0,KF.inspect)(a.type);e.reportError(new GF.GraphQLError(`Field "${r.name}" argument "${a.name}" of type "${o}" is required, but it was not provided.`,{nodes:t}))}}}})}function QF(e){var t;let n=Object.create(null),r=e.getSchema(),i=(t=r==null?void 0:r.getDirectives())!==null&&t!==void 0?t:gz.specifiedDirectives;for(let c of i)n[c.name]=(0,jF.keyMap)(c.args.filter(vg.isRequiredArgument),l=>l.name);let a=e.getDocument().definitions;for(let c of a)if(c.kind===$F.Kind.DIRECTIVE_DEFINITION){var o;let l=(o=c.arguments)!==null&&o!==void 0?o:[];n[c.name.value]=(0,jF.keyMap)(l.filter(vz),p=>p.name.value)}return{Directive:{leave(c){let l=c.name.value,p=n[l];if(p){var f;let y=(f=c.arguments)!==null&&f!==void 0?f:[],g=new Set(y.map(v=>v.name.value));for(let[v,F]of Object.entries(p))if(!g.has(v)){let k=(0,vg.isType)(F.type)?(0,KF.inspect)(F.type):(0,Iz.print)(F.type);e.reportError(new GF.GraphQLError(`Directive "@${l}" argument "${v}" of type "${k}" is required, but it was not provided.`,{nodes:c}))}}}}}}function vz(e){return e.type.kind===$F.Kind.NON_NULL_TYPE&&e.defaultValue==null}});var Dg=w(Og=>{"use strict";m();T();N();Object.defineProperty(Og,"__esModule",{value:!0});Og.ScalarLeafsRule=Sz;var YF=Yt(),JF=He(),HF=Ft();function Sz(e){return{Field(t){let n=e.getType(),r=t.selectionSet;if(n){if((0,HF.isLeafType)((0,HF.getNamedType)(n))){if(r){let i=t.name.value,a=(0,YF.inspect)(n);e.reportError(new JF.GraphQLError(`Field "${i}" must not have a selection since type "${a}" has no subfields.`,{nodes:r}))}}else if(!r){let i=t.name.value,a=(0,YF.inspect)(n);e.reportError(new JF.GraphQLError(`Field "${i}" of type "${a}" must have a selection of subfields. Did you mean "${i} { ... }"?`,{nodes:t}))}}}}}});var Ag=w(bg=>{"use strict";m();T();N();Object.defineProperty(bg,"__esModule",{value:!0});bg.printPathArray=Oz;function Oz(e){return e.map(t=>typeof t=="number"?"["+t.toString()+"]":"."+t).join("")}});var Zd=w(rN=>{"use strict";m();T();N();Object.defineProperty(rN,"__esModule",{value:!0});rN.addPath=Dz;rN.pathToArray=bz;function Dz(e,t,n){return{prev:e,key:t,typename:n}}function bz(e){let t=[],n=e;for(;n;)t.push(n.key),n=n.prev;return t.reverse()}});var Pg=w(Rg=>{"use strict";m();T();N();Object.defineProperty(Rg,"__esModule",{value:!0});Rg.coerceInputValue=Cz;var Az=zo(),iN=Yt(),Rz=yr(),Pz=Qm(),Fz=va(),ea=Zd(),wz=Ag(),Lz=Xo(),ps=He(),ep=Ft();function Cz(e,t,n=Bz){return tp(e,t,n,void 0)}function Bz(e,t,n){let r="Invalid value "+(0,iN.inspect)(t);throw e.length>0&&(r+=` at "value${(0,wz.printPathArray)(e)}"`),n.message=r+": "+n.message,n}function tp(e,t,n,r){if((0,ep.isNonNullType)(t)){if(e!=null)return tp(e,t.ofType,n,r);n((0,ea.pathToArray)(r),e,new ps.GraphQLError(`Expected non-nullable type "${(0,iN.inspect)(t)}" not to be null.`));return}if(e==null)return null;if((0,ep.isListType)(t)){let i=t.ofType;return(0,Pz.isIterableObject)(e)?Array.from(e,(a,o)=>{let c=(0,ea.addPath)(r,o,void 0);return tp(a,i,n,c)}):[tp(e,i,n,r)]}if((0,ep.isInputObjectType)(t)){if(!(0,Fz.isObjectLike)(e)){n((0,ea.pathToArray)(r),e,new ps.GraphQLError(`Expected type "${t.name}" to be an object.`));return}let i={},a=t.getFields();for(let o of Object.values(a)){let c=e[o.name];if(c===void 0){if(o.defaultValue!==void 0)i[o.name]=o.defaultValue;else if((0,ep.isNonNullType)(o.type)){let l=(0,iN.inspect)(o.type);n((0,ea.pathToArray)(r),e,new ps.GraphQLError(`Field "${o.name}" of required type "${l}" was not provided.`))}continue}i[o.name]=tp(c,o.type,n,(0,ea.addPath)(r,o.name,t.name))}for(let o of Object.keys(e))if(!a[o]){let c=(0,Lz.suggestionList)(o,Object.keys(t.getFields()));n((0,ea.pathToArray)(r),e,new ps.GraphQLError(`Field "${o}" is not defined by type "${t.name}".`+(0,Az.didYouMean)(c)))}if(t.isOneOf){let o=Object.keys(i);o.length!==1&&n((0,ea.pathToArray)(r),e,new ps.GraphQLError(`Exactly one key must be specified for OneOf type "${t.name}".`));let c=o[0],l=i[c];l===null&&n((0,ea.pathToArray)(r).concat(c),l,new ps.GraphQLError(`Field "${c}" must be non-null.`))}return i}if((0,ep.isLeafType)(t)){let i;try{i=t.parseValue(e)}catch(a){a instanceof ps.GraphQLError?n((0,ea.pathToArray)(r),e,a):n((0,ea.pathToArray)(r),e,new ps.GraphQLError(`Expected type "${t.name}". `+a.message,{originalError:a}));return}return i===void 0&&n((0,ea.pathToArray)(r),e,new ps.GraphQLError(`Expected type "${t.name}".`)),i}(0,Rz.invariant)(!1,"Unexpected input type: "+(0,iN.inspect)(t))}});var rp=w(Fg=>{"use strict";m();T();N();Object.defineProperty(Fg,"__esModule",{value:!0});Fg.valueFromAST=np;var Uz=Yt(),kz=yr(),Mz=Wo(),al=Pt(),Wu=Ft();function np(e,t,n){if(e){if(e.kind===al.Kind.VARIABLE){let r=e.name.value;if(n==null||n[r]===void 0)return;let i=n[r];return i===null&&(0,Wu.isNonNullType)(t)?void 0:i}if((0,Wu.isNonNullType)(t))return e.kind===al.Kind.NULL?void 0:np(e,t.ofType,n);if(e.kind===al.Kind.NULL)return null;if((0,Wu.isListType)(t)){let r=t.ofType;if(e.kind===al.Kind.LIST){let a=[];for(let o of e.values)if(zF(o,n)){if((0,Wu.isNonNullType)(r))return;a.push(null)}else{let c=np(o,r,n);if(c===void 0)return;a.push(c)}return a}let i=np(e,r,n);return i===void 0?void 0:[i]}if((0,Wu.isInputObjectType)(t)){if(e.kind!==al.Kind.OBJECT)return;let r=Object.create(null),i=(0,Mz.keyMap)(e.fields,a=>a.name.value);for(let a of Object.values(t.getFields())){let o=i[a.name];if(!o||zF(o.value,n)){if(a.defaultValue!==void 0)r[a.name]=a.defaultValue;else if((0,Wu.isNonNullType)(a.type))return;continue}let c=np(o.value,a.type,n);if(c===void 0)return;r[a.name]=c}if(t.isOneOf){let a=Object.keys(r);if(a.length!==1||r[a[0]]===null)return}return r}if((0,Wu.isLeafType)(t)){let r;try{r=t.parseLiteral(e,n)}catch(i){return}return r===void 0?void 0:r}(0,kz.invariant)(!1,"Unexpected input type: "+(0,Uz.inspect)(t))}}function zF(e,t){return e.kind===al.Kind.VARIABLE&&(t==null||t[e.name.value]===void 0)}});var ul=w(ip=>{"use strict";m();T();N();Object.defineProperty(ip,"__esModule",{value:!0});ip.getArgumentValues=ew;ip.getDirectiveValues=$z;ip.getVariableValues=Kz;var sl=Yt(),xz=Wo(),qz=Ag(),fs=He(),WF=Pt(),XF=ci(),ol=Ft(),Vz=Pg(),jz=Aa(),ZF=rp();function Kz(e,t,n,r){let i=[],a=r==null?void 0:r.maxErrors;try{let o=Gz(e,t,n,c=>{if(a!=null&&i.length>=a)throw new fs.GraphQLError("Too many errors processing variables, error limit reached. Execution aborted.");i.push(c)});if(i.length===0)return{coerced:o}}catch(o){i.push(o)}return{errors:i}}function Gz(e,t,n,r){let i={};for(let a of t){let o=a.variable.name.value,c=(0,jz.typeFromAST)(e,a.type);if(!(0,ol.isInputType)(c)){let p=(0,XF.print)(a.type);r(new fs.GraphQLError(`Variable "$${o}" expected value of type "${p}" which cannot be used as an input type.`,{nodes:a.type}));continue}if(!tw(n,o)){if(a.defaultValue)i[o]=(0,ZF.valueFromAST)(a.defaultValue,c);else if((0,ol.isNonNullType)(c)){let p=(0,sl.inspect)(c);r(new fs.GraphQLError(`Variable "$${o}" of required type "${p}" was not provided.`,{nodes:a}))}continue}let l=n[o];if(l===null&&(0,ol.isNonNullType)(c)){let p=(0,sl.inspect)(c);r(new fs.GraphQLError(`Variable "$${o}" of non-null type "${p}" must not be null.`,{nodes:a}));continue}i[o]=(0,Vz.coerceInputValue)(l,c,(p,f,y)=>{let g=`Variable "$${o}" got invalid value `+(0,sl.inspect)(f);p.length>0&&(g+=` at "${o}${(0,qz.printPathArray)(p)}"`),r(new fs.GraphQLError(g+"; "+y.message,{nodes:a,originalError:y}))})}return i}function ew(e,t,n){var r;let i={},a=(r=t.arguments)!==null&&r!==void 0?r:[],o=(0,xz.keyMap)(a,c=>c.name.value);for(let c of e.args){let l=c.name,p=c.type,f=o[l];if(!f){if(c.defaultValue!==void 0)i[l]=c.defaultValue;else if((0,ol.isNonNullType)(p))throw new fs.GraphQLError(`Argument "${l}" of required type "${(0,sl.inspect)(p)}" was not provided.`,{nodes:t});continue}let y=f.value,g=y.kind===WF.Kind.NULL;if(y.kind===WF.Kind.VARIABLE){let F=y.name.value;if(n==null||!tw(n,F)){if(c.defaultValue!==void 0)i[l]=c.defaultValue;else if((0,ol.isNonNullType)(p))throw new fs.GraphQLError(`Argument "${l}" of required type "${(0,sl.inspect)(p)}" was provided the variable "$${F}" which was not provided a runtime value.`,{nodes:y});continue}g=n[F]==null}if(g&&(0,ol.isNonNullType)(p))throw new fs.GraphQLError(`Argument "${l}" of non-null type "${(0,sl.inspect)(p)}" must not be null.`,{nodes:y});let v=(0,ZF.valueFromAST)(y,p,n);if(v===void 0)throw new fs.GraphQLError(`Argument "${l}" has invalid value ${(0,XF.print)(y)}.`,{nodes:y});i[l]=v}return i}function $z(e,t,n){var r;let i=(r=t.directives)===null||r===void 0?void 0:r.find(a=>a.name.value===e.name);if(i)return ew(e,i,n)}function tw(e,t){return Object.prototype.hasOwnProperty.call(e,t)}});var oN=w(sN=>{"use strict";m();T();N();Object.defineProperty(sN,"__esModule",{value:!0});sN.collectFields=Jz;sN.collectSubfields=Hz;var wg=Pt(),Qz=Ft(),nw=Gr(),Yz=Aa(),rw=ul();function Jz(e,t,n,r,i){let a=new Map;return aN(e,t,n,r,i,a,new Set),a}function Hz(e,t,n,r,i){let a=new Map,o=new Set;for(let c of i)c.selectionSet&&aN(e,t,n,r,c.selectionSet,a,o);return a}function aN(e,t,n,r,i,a,o){for(let c of i.selections)switch(c.kind){case wg.Kind.FIELD:{if(!Lg(n,c))continue;let l=zz(c),p=a.get(l);p!==void 0?p.push(c):a.set(l,[c]);break}case wg.Kind.INLINE_FRAGMENT:{if(!Lg(n,c)||!iw(e,c,r))continue;aN(e,t,n,r,c.selectionSet,a,o);break}case wg.Kind.FRAGMENT_SPREAD:{let l=c.name.value;if(o.has(l)||!Lg(n,c))continue;o.add(l);let p=t[l];if(!p||!iw(e,p,r))continue;aN(e,t,n,r,p.selectionSet,a,o);break}}}function Lg(e,t){let n=(0,rw.getDirectiveValues)(nw.GraphQLSkipDirective,t,e);if((n==null?void 0:n.if)===!0)return!1;let r=(0,rw.getDirectiveValues)(nw.GraphQLIncludeDirective,t,e);return(r==null?void 0:r.if)!==!1}function iw(e,t,n){let r=t.typeCondition;if(!r)return!0;let i=(0,Yz.typeFromAST)(e,r);return i===n?!0:(0,Qz.isAbstractType)(i)?e.isSubType(i,n):!1}function zz(e){return e.alias?e.alias.value:e.name.value}});var Bg=w(Cg=>{"use strict";m();T();N();Object.defineProperty(Cg,"__esModule",{value:!0});Cg.SingleFieldSubscriptionsRule=Zz;var aw=He(),Wz=Pt(),Xz=oN();function Zz(e){return{OperationDefinition(t){if(t.operation==="subscription"){let n=e.getSchema(),r=n.getSubscriptionType();if(r){let i=t.name?t.name.value:null,a=Object.create(null),o=e.getDocument(),c=Object.create(null);for(let p of o.definitions)p.kind===Wz.Kind.FRAGMENT_DEFINITION&&(c[p.name.value]=p);let l=(0,Xz.collectFields)(n,c,a,r,t.selectionSet);if(l.size>1){let y=[...l.values()].slice(1).flat();e.reportError(new aw.GraphQLError(i!=null?`Subscription "${i}" must select only one top level field.`:"Anonymous Subscription must select only one top level field.",{nodes:y}))}for(let p of l.values())p[0].name.value.startsWith("__")&&e.reportError(new aw.GraphQLError(i!=null?`Subscription "${i}" must not select an introspection top level field.`:"Anonymous Subscription must not select an introspection top level field.",{nodes:p}))}}}}}});var uN=w(Ug=>{"use strict";m();T();N();Object.defineProperty(Ug,"__esModule",{value:!0});Ug.groupBy=e4;function e4(e,t){let n=new Map;for(let r of e){let i=t(r),a=n.get(i);a===void 0?n.set(i,[r]):a.push(r)}return n}});var Mg=w(kg=>{"use strict";m();T();N();Object.defineProperty(kg,"__esModule",{value:!0});kg.UniqueArgumentDefinitionNamesRule=r4;var t4=uN(),n4=He();function r4(e){return{DirectiveDefinition(r){var i;let a=(i=r.arguments)!==null&&i!==void 0?i:[];return n(`@${r.name.value}`,a)},InterfaceTypeDefinition:t,InterfaceTypeExtension:t,ObjectTypeDefinition:t,ObjectTypeExtension:t};function t(r){var i;let a=r.name.value,o=(i=r.fields)!==null&&i!==void 0?i:[];for(let l of o){var c;let p=l.name.value,f=(c=l.arguments)!==null&&c!==void 0?c:[];n(`${a}.${p}`,f)}return!1}function n(r,i){let a=(0,t4.groupBy)(i,o=>o.name.value);for(let[o,c]of a)c.length>1&&e.reportError(new n4.GraphQLError(`Argument "${r}(${o}:)" can only be defined once.`,{nodes:c.map(l=>l.name)}));return!1}}});var qg=w(xg=>{"use strict";m();T();N();Object.defineProperty(xg,"__esModule",{value:!0});xg.UniqueArgumentNamesRule=s4;var i4=uN(),a4=He();function s4(e){return{Field:t,Directive:t};function t(n){var r;let i=(r=n.arguments)!==null&&r!==void 0?r:[],a=(0,i4.groupBy)(i,o=>o.name.value);for(let[o,c]of a)c.length>1&&e.reportError(new a4.GraphQLError(`There can be only one argument named "${o}".`,{nodes:c.map(l=>l.name)}))}}});var jg=w(Vg=>{"use strict";m();T();N();Object.defineProperty(Vg,"__esModule",{value:!0});Vg.UniqueDirectiveNamesRule=o4;var sw=He();function o4(e){let t=Object.create(null),n=e.getSchema();return{DirectiveDefinition(r){let i=r.name.value;if(n!=null&&n.getDirective(i)){e.reportError(new sw.GraphQLError(`Directive "@${i}" already exists in the schema. It cannot be redefined.`,{nodes:r.name}));return}return t[i]?e.reportError(new sw.GraphQLError(`There can be only one directive named "@${i}".`,{nodes:[t[i],r.name]})):t[i]=r.name,!1}}}});var $g=w(Gg=>{"use strict";m();T();N();Object.defineProperty(Gg,"__esModule",{value:!0});Gg.UniqueDirectivesPerLocationRule=l4;var u4=He(),Kg=Pt(),ow=zu(),c4=Gr();function l4(e){let t=Object.create(null),n=e.getSchema(),r=n?n.getDirectives():c4.specifiedDirectives;for(let c of r)t[c.name]=!c.isRepeatable;let i=e.getDocument().definitions;for(let c of i)c.kind===Kg.Kind.DIRECTIVE_DEFINITION&&(t[c.name.value]=!c.repeatable);let a=Object.create(null),o=Object.create(null);return{enter(c){if(!("directives"in c)||!c.directives)return;let l;if(c.kind===Kg.Kind.SCHEMA_DEFINITION||c.kind===Kg.Kind.SCHEMA_EXTENSION)l=a;else if((0,ow.isTypeDefinitionNode)(c)||(0,ow.isTypeExtensionNode)(c)){let p=c.name.value;l=o[p],l===void 0&&(o[p]=l=Object.create(null))}else l=Object.create(null);for(let p of c.directives){let f=p.name.value;t[f]&&(l[f]?e.reportError(new u4.GraphQLError(`The directive "@${f}" can only be used once at this location.`,{nodes:[l[f],p]})):l[f]=p)}}}}});var Yg=w(Qg=>{"use strict";m();T();N();Object.defineProperty(Qg,"__esModule",{value:!0});Qg.UniqueEnumValueNamesRule=p4;var uw=He(),d4=Ft();function p4(e){let t=e.getSchema(),n=t?t.getTypeMap():Object.create(null),r=Object.create(null);return{EnumTypeDefinition:i,EnumTypeExtension:i};function i(a){var o;let c=a.name.value;r[c]||(r[c]=Object.create(null));let l=(o=a.values)!==null&&o!==void 0?o:[],p=r[c];for(let f of l){let y=f.name.value,g=n[c];(0,d4.isEnumType)(g)&&g.getValue(y)?e.reportError(new uw.GraphQLError(`Enum value "${c}.${y}" already exists in the schema. It cannot also be defined in this type extension.`,{nodes:f.name})):p[y]?e.reportError(new uw.GraphQLError(`Enum value "${c}.${y}" can only be defined once.`,{nodes:[p[y],f.name]})):p[y]=f.name}return!1}}});var zg=w(Hg=>{"use strict";m();T();N();Object.defineProperty(Hg,"__esModule",{value:!0});Hg.UniqueFieldDefinitionNamesRule=f4;var cw=He(),Jg=Ft();function f4(e){let t=e.getSchema(),n=t?t.getTypeMap():Object.create(null),r=Object.create(null);return{InputObjectTypeDefinition:i,InputObjectTypeExtension:i,InterfaceTypeDefinition:i,InterfaceTypeExtension:i,ObjectTypeDefinition:i,ObjectTypeExtension:i};function i(a){var o;let c=a.name.value;r[c]||(r[c]=Object.create(null));let l=(o=a.fields)!==null&&o!==void 0?o:[],p=r[c];for(let f of l){let y=f.name.value;m4(n[c],y)?e.reportError(new cw.GraphQLError(`Field "${c}.${y}" already exists in the schema. It cannot also be defined in this type extension.`,{nodes:f.name})):p[y]?e.reportError(new cw.GraphQLError(`Field "${c}.${y}" can only be defined once.`,{nodes:[p[y],f.name]})):p[y]=f.name}return!1}}function m4(e,t){return(0,Jg.isObjectType)(e)||(0,Jg.isInterfaceType)(e)||(0,Jg.isInputObjectType)(e)?e.getFields()[t]!=null:!1}});var Xg=w(Wg=>{"use strict";m();T();N();Object.defineProperty(Wg,"__esModule",{value:!0});Wg.UniqueFragmentNamesRule=T4;var N4=He();function T4(e){let t=Object.create(null);return{OperationDefinition:()=>!1,FragmentDefinition(n){let r=n.name.value;return t[r]?e.reportError(new N4.GraphQLError(`There can be only one fragment named "${r}".`,{nodes:[t[r],n.name]})):t[r]=n.name,!1}}}});var e_=w(Zg=>{"use strict";m();T();N();Object.defineProperty(Zg,"__esModule",{value:!0});Zg.UniqueInputFieldNamesRule=y4;var E4=yr(),h4=He();function y4(e){let t=[],n=Object.create(null);return{ObjectValue:{enter(){t.push(n),n=Object.create(null)},leave(){let r=t.pop();r||(0,E4.invariant)(!1),n=r}},ObjectField(r){let i=r.name.value;n[i]?e.reportError(new h4.GraphQLError(`There can be only one input field named "${i}".`,{nodes:[n[i],r.name]})):n[i]=r.name}}}});var n_=w(t_=>{"use strict";m();T();N();Object.defineProperty(t_,"__esModule",{value:!0});t_.UniqueOperationNamesRule=g4;var I4=He();function g4(e){let t=Object.create(null);return{OperationDefinition(n){let r=n.name;return r&&(t[r.value]?e.reportError(new I4.GraphQLError(`There can be only one operation named "${r.value}".`,{nodes:[t[r.value],r]})):t[r.value]=r),!1},FragmentDefinition:()=>!1}}});var i_=w(r_=>{"use strict";m();T();N();Object.defineProperty(r_,"__esModule",{value:!0});r_.UniqueOperationTypesRule=_4;var lw=He();function _4(e){let t=e.getSchema(),n=Object.create(null),r=t?{query:t.getQueryType(),mutation:t.getMutationType(),subscription:t.getSubscriptionType()}:{};return{SchemaDefinition:i,SchemaExtension:i};function i(a){var o;let c=(o=a.operationTypes)!==null&&o!==void 0?o:[];for(let l of c){let p=l.operation,f=n[p];r[p]?e.reportError(new lw.GraphQLError(`Type for ${p} already defined in the schema. It cannot be redefined.`,{nodes:l})):f?e.reportError(new lw.GraphQLError(`There can be only one ${p} type in schema.`,{nodes:[f,l]})):n[p]=l}return!1}}});var s_=w(a_=>{"use strict";m();T();N();Object.defineProperty(a_,"__esModule",{value:!0});a_.UniqueTypeNamesRule=v4;var dw=He();function v4(e){let t=Object.create(null),n=e.getSchema();return{ScalarTypeDefinition:r,ObjectTypeDefinition:r,InterfaceTypeDefinition:r,UnionTypeDefinition:r,EnumTypeDefinition:r,InputObjectTypeDefinition:r};function r(i){let a=i.name.value;if(n!=null&&n.getType(a)){e.reportError(new dw.GraphQLError(`Type "${a}" already exists in the schema. It cannot also be defined in this type definition.`,{nodes:i.name}));return}return t[a]?e.reportError(new dw.GraphQLError(`There can be only one type named "${a}".`,{nodes:[t[a],i.name]})):t[a]=i.name,!1}}});var u_=w(o_=>{"use strict";m();T();N();Object.defineProperty(o_,"__esModule",{value:!0});o_.UniqueVariableNamesRule=D4;var S4=uN(),O4=He();function D4(e){return{OperationDefinition(t){var n;let r=(n=t.variableDefinitions)!==null&&n!==void 0?n:[],i=(0,S4.groupBy)(r,a=>a.variable.name.value);for(let[a,o]of i)o.length>1&&e.reportError(new O4.GraphQLError(`There can be only one variable named "$${a}".`,{nodes:o.map(c=>c.variable.name)}))}}}});var d_=w(l_=>{"use strict";m();T();N();Object.defineProperty(l_,"__esModule",{value:!0});l_.ValuesOfCorrectTypeRule=P4;var b4=zo(),ap=Yt(),A4=Wo(),R4=Xo(),Pa=He(),c_=Pt(),cN=ci(),Ra=Ft();function P4(e){let t={};return{OperationDefinition:{enter(){t={}}},VariableDefinition(n){t[n.variable.name.value]=n},ListValue(n){let r=(0,Ra.getNullableType)(e.getParentInputType());if(!(0,Ra.isListType)(r))return Xu(e,n),!1},ObjectValue(n){let r=(0,Ra.getNamedType)(e.getInputType());if(!(0,Ra.isInputObjectType)(r))return Xu(e,n),!1;let i=(0,A4.keyMap)(n.fields,a=>a.name.value);for(let a of Object.values(r.getFields()))if(!i[a.name]&&(0,Ra.isRequiredInputField)(a)){let c=(0,ap.inspect)(a.type);e.reportError(new Pa.GraphQLError(`Field "${r.name}.${a.name}" of required type "${c}" was not provided.`,{nodes:n}))}r.isOneOf&&F4(e,n,r,i,t)},ObjectField(n){let r=(0,Ra.getNamedType)(e.getParentInputType());if(!e.getInputType()&&(0,Ra.isInputObjectType)(r)){let a=(0,R4.suggestionList)(n.name.value,Object.keys(r.getFields()));e.reportError(new Pa.GraphQLError(`Field "${n.name.value}" is not defined by type "${r.name}".`+(0,b4.didYouMean)(a),{nodes:n}))}},NullValue(n){let r=e.getInputType();(0,Ra.isNonNullType)(r)&&e.reportError(new Pa.GraphQLError(`Expected value of type "${(0,ap.inspect)(r)}", found ${(0,cN.print)(n)}.`,{nodes:n}))},EnumValue:n=>Xu(e,n),IntValue:n=>Xu(e,n),FloatValue:n=>Xu(e,n),StringValue:n=>Xu(e,n),BooleanValue:n=>Xu(e,n)}}function Xu(e,t){let n=e.getInputType();if(!n)return;let r=(0,Ra.getNamedType)(n);if(!(0,Ra.isLeafType)(r)){let i=(0,ap.inspect)(n);e.reportError(new Pa.GraphQLError(`Expected value of type "${i}", found ${(0,cN.print)(t)}.`,{nodes:t}));return}try{if(r.parseLiteral(t,void 0)===void 0){let a=(0,ap.inspect)(n);e.reportError(new Pa.GraphQLError(`Expected value of type "${a}", found ${(0,cN.print)(t)}.`,{nodes:t}))}}catch(i){let a=(0,ap.inspect)(n);i instanceof Pa.GraphQLError?e.reportError(i):e.reportError(new Pa.GraphQLError(`Expected value of type "${a}", found ${(0,cN.print)(t)}; `+i.message,{nodes:t,originalError:i}))}}function F4(e,t,n,r,i){var a;let o=Object.keys(r);if(o.length!==1){e.reportError(new Pa.GraphQLError(`OneOf Input Object "${n.name}" must specify exactly one key.`,{nodes:[t]}));return}let l=(a=r[o[0]])===null||a===void 0?void 0:a.value,p=!l||l.kind===c_.Kind.NULL,f=(l==null?void 0:l.kind)===c_.Kind.VARIABLE;if(p){e.reportError(new Pa.GraphQLError(`Field "${n.name}.${o[0]}" must be non-null.`,{nodes:[t]}));return}if(f){let y=l.name.value;i[y].type.kind!==c_.Kind.NON_NULL_TYPE&&e.reportError(new Pa.GraphQLError(`Variable "${y}" must be non-nullable to be used for OneOf Input Object "${n.name}".`,{nodes:[t]}))}}});var f_=w(p_=>{"use strict";m();T();N();Object.defineProperty(p_,"__esModule",{value:!0});p_.VariablesAreInputTypesRule=U4;var w4=He(),L4=ci(),C4=Ft(),B4=Aa();function U4(e){return{VariableDefinition(t){let n=(0,B4.typeFromAST)(e.getSchema(),t.type);if(n!==void 0&&!(0,C4.isInputType)(n)){let r=t.variable.name.value,i=(0,L4.print)(t.type);e.reportError(new w4.GraphQLError(`Variable "$${r}" cannot be non-input type "${i}".`,{nodes:t.type}))}}}}});var N_=w(m_=>{"use strict";m();T();N();Object.defineProperty(m_,"__esModule",{value:!0});m_.VariablesInAllowedPositionRule=q4;var pw=Yt(),k4=He(),M4=Pt(),fw=Ft(),mw=qd(),x4=Aa();function q4(e){let t=Object.create(null);return{OperationDefinition:{enter(){t=Object.create(null)},leave(n){let r=e.getRecursiveVariableUsages(n);for(let{node:i,type:a,defaultValue:o}of r){let c=i.name.value,l=t[c];if(l&&a){let p=e.getSchema(),f=(0,x4.typeFromAST)(p,l.type);if(f&&!V4(p,f,l.defaultValue,a,o)){let y=(0,pw.inspect)(f),g=(0,pw.inspect)(a);e.reportError(new k4.GraphQLError(`Variable "$${c}" of type "${y}" used in position expecting type "${g}".`,{nodes:[l,i]}))}}}}},VariableDefinition(n){t[n.variable.name.value]=n}}}function V4(e,t,n,r,i){if((0,fw.isNonNullType)(r)&&!(0,fw.isNonNullType)(t)){if(!(n!=null&&n.kind!==M4.Kind.NULL)&&!(i!==void 0))return!1;let c=r.ofType;return(0,mw.isTypeSubTypeOf)(e,t,c)}return(0,mw.isTypeSubTypeOf)(e,t,r)}});var T_=w(nu=>{"use strict";m();T();N();Object.defineProperty(nu,"__esModule",{value:!0});nu.specifiedSDLRules=nu.specifiedRules=nu.recommendedRules=void 0;var j4=LI(),K4=BI(),G4=kI(),Nw=MI(),Tw=jI(),$4=GI(),Ew=YI(),Q4=HI(),Y4=WI(),J4=ZI(),H4=tg(),z4=rg(),W4=ag(),X4=og(),Z4=Eg(),eW=Ig(),tW=_g(),hw=Sg(),nW=Dg(),rW=Bg(),iW=Mg(),yw=qg(),aW=jg(),Iw=$g(),sW=Yg(),oW=zg(),uW=Xg(),gw=e_(),cW=n_(),lW=i_(),dW=s_(),pW=u_(),fW=d_(),mW=f_(),NW=N_(),_w=Object.freeze([J4.MaxIntrospectionDepthRule]);nu.recommendedRules=_w;var TW=Object.freeze([j4.ExecutableDefinitionsRule,cW.UniqueOperationNamesRule,Q4.LoneAnonymousOperationRule,rW.SingleFieldSubscriptionsRule,Ew.KnownTypeNamesRule,G4.FragmentsOnCompositeTypesRule,mW.VariablesAreInputTypesRule,nW.ScalarLeafsRule,K4.FieldsOnCorrectTypeRule,uW.UniqueFragmentNamesRule,$4.KnownFragmentNamesRule,W4.NoUnusedFragmentsRule,eW.PossibleFragmentSpreadsRule,H4.NoFragmentCyclesRule,pW.UniqueVariableNamesRule,z4.NoUndefinedVariablesRule,X4.NoUnusedVariablesRule,Tw.KnownDirectivesRule,Iw.UniqueDirectivesPerLocationRule,Nw.KnownArgumentNamesRule,yw.UniqueArgumentNamesRule,fW.ValuesOfCorrectTypeRule,hw.ProvidedRequiredArgumentsRule,NW.VariablesInAllowedPositionRule,Z4.OverlappingFieldsCanBeMergedRule,gw.UniqueInputFieldNamesRule,..._w]);nu.specifiedRules=TW;var EW=Object.freeze([Y4.LoneSchemaDefinitionRule,lW.UniqueOperationTypesRule,dW.UniqueTypeNamesRule,sW.UniqueEnumValueNamesRule,oW.UniqueFieldDefinitionNamesRule,iW.UniqueArgumentDefinitionNamesRule,aW.UniqueDirectiveNamesRule,Ew.KnownTypeNamesRule,Tw.KnownDirectivesRule,Iw.UniqueDirectivesPerLocationRule,tW.PossibleTypeExtensionsRule,Nw.KnownArgumentNamesOnDirectivesRule,yw.UniqueArgumentNamesRule,gw.UniqueInputFieldNamesRule,hw.ProvidedRequiredArgumentsOnDirectivesRule]);nu.specifiedSDLRules=EW});var y_=w(ru=>{"use strict";m();T();N();Object.defineProperty(ru,"__esModule",{value:!0});ru.ValidationContext=ru.SDLValidationContext=ru.ASTValidationContext=void 0;var vw=Pt(),hW=ju(),Sw=zm(),sp=class{constructor(t,n){this._ast=t,this._fragments=void 0,this._fragmentSpreads=new Map,this._recursivelyReferencedFragments=new Map,this._onError=n}get[Symbol.toStringTag](){return"ASTValidationContext"}reportError(t){this._onError(t)}getDocument(){return this._ast}getFragment(t){let n;if(this._fragments)n=this._fragments;else{n=Object.create(null);for(let r of this.getDocument().definitions)r.kind===vw.Kind.FRAGMENT_DEFINITION&&(n[r.name.value]=r);this._fragments=n}return n[t]}getFragmentSpreads(t){let n=this._fragmentSpreads.get(t);if(!n){n=[];let r=[t],i;for(;i=r.pop();)for(let a of i.selections)a.kind===vw.Kind.FRAGMENT_SPREAD?n.push(a):a.selectionSet&&r.push(a.selectionSet);this._fragmentSpreads.set(t,n)}return n}getRecursivelyReferencedFragments(t){let n=this._recursivelyReferencedFragments.get(t);if(!n){n=[];let r=Object.create(null),i=[t.selectionSet],a;for(;a=i.pop();)for(let o of this.getFragmentSpreads(a)){let c=o.name.value;if(r[c]!==!0){r[c]=!0;let l=this.getFragment(c);l&&(n.push(l),i.push(l.selectionSet))}}this._recursivelyReferencedFragments.set(t,n)}return n}};ru.ASTValidationContext=sp;var E_=class extends sp{constructor(t,n,r){super(t,r),this._schema=n}get[Symbol.toStringTag](){return"SDLValidationContext"}getSchema(){return this._schema}};ru.SDLValidationContext=E_;var h_=class extends sp{constructor(t,n,r,i){super(n,i),this._schema=t,this._typeInfo=r,this._variableUsages=new Map,this._recursiveVariableUsages=new Map}get[Symbol.toStringTag](){return"ValidationContext"}getSchema(){return this._schema}getVariableUsages(t){let n=this._variableUsages.get(t);if(!n){let r=[],i=new Sw.TypeInfo(this._schema);(0,hW.visit)(t,(0,Sw.visitWithTypeInfo)(i,{VariableDefinition:()=>!1,Variable(a){r.push({node:a,type:i.getInputType(),defaultValue:i.getDefaultValue()})}})),n=r,this._variableUsages.set(t,n)}return n}getRecursiveVariableUsages(t){let n=this._recursiveVariableUsages.get(t);if(!n){n=this.getVariableUsages(t);for(let r of this.getRecursivelyReferencedFragments(t))n=n.concat(this.getVariableUsages(r));this._recursiveVariableUsages.set(t,n)}return n}getType(){return this._typeInfo.getType()}getParentType(){return this._typeInfo.getParentType()}getInputType(){return this._typeInfo.getInputType()}getParentInputType(){return this._typeInfo.getParentInputType()}getFieldDef(){return this._typeInfo.getFieldDef()}getDirective(){return this._typeInfo.getDirective()}getArgument(){return this._typeInfo.getArgument()}getEnumValue(){return this._typeInfo.getEnumValue()}};ru.ValidationContext=h_});var ll=w(cl=>{"use strict";m();T();N();Object.defineProperty(cl,"__esModule",{value:!0});cl.assertValidSDL=vW;cl.assertValidSDLExtension=SW;cl.validate=_W;cl.validateSDL=I_;var yW=Lr(),IW=He(),lN=ju(),gW=zd(),Ow=zm(),Dw=T_(),bw=y_();function _W(e,t,n=Dw.specifiedRules,r,i=new Ow.TypeInfo(e)){var a;let o=(a=r==null?void 0:r.maxErrors)!==null&&a!==void 0?a:100;t||(0,yW.devAssert)(!1,"Must provide document."),(0,gW.assertValidSchema)(e);let c=Object.freeze({}),l=[],p=new bw.ValidationContext(e,t,i,y=>{if(l.length>=o)throw l.push(new IW.GraphQLError("Too many validation errors, error limit reached. Validation aborted.")),c;l.push(y)}),f=(0,lN.visitInParallel)(n.map(y=>y(p)));try{(0,lN.visit)(t,(0,Ow.visitWithTypeInfo)(i,f))}catch(y){if(y!==c)throw y}return l}function I_(e,t,n=Dw.specifiedSDLRules){let r=[],i=new bw.SDLValidationContext(e,t,o=>{r.push(o)}),a=n.map(o=>o(i));return(0,lN.visit)(e,(0,lN.visitInParallel)(a)),r}function vW(e){let t=I_(e);if(t.length!==0)throw new Error(t.map(n=>n.message).join(` +`))}var OI=class{constructor(t){this._errors=[],this.schema=t}reportError(t,n){let r=Array.isArray(n)?n.filter(Boolean):n;this._errors.push(new $H.GraphQLError(t,{nodes:r}))}getErrors(){return this._errors}};function HH(e){let t=e.schema,n=t.getQueryType();if(!n)e.reportError("Query root type must be provided.",t.astNode);else if(!(0,Rn.isObjectType)(n)){var r;e.reportError(`Query root type must be Object type, it cannot be ${(0,gr.inspect)(n)}.`,(r=SI(t,vI.OperationTypeNode.QUERY))!==null&&r!==void 0?r:n.astNode)}let i=t.getMutationType();if(i&&!(0,Rn.isObjectType)(i)){var a;e.reportError(`Mutation root type must be Object type if provided, it cannot be ${(0,gr.inspect)(i)}.`,(a=SI(t,vI.OperationTypeNode.MUTATION))!==null&&a!==void 0?a:i.astNode)}let o=t.getSubscriptionType();if(o&&!(0,Rn.isObjectType)(o)){var c;e.reportError(`Subscription root type must be Object type if provided, it cannot be ${(0,gr.inspect)(o)}.`,(c=SI(t,vI.OperationTypeNode.SUBSCRIPTION))!==null&&c!==void 0?c:o.astNode)}}function SI(e,t){var n;return(n=[e.astNode,...e.extensionASTNodes].flatMap(r=>{var i;return(i=r==null?void 0:r.operationTypes)!==null&&i!==void 0?i:[]}).find(r=>r.operation===t))===null||n===void 0?void 0:n.type}function zH(e){for(let n of e.schema.getDirectives()){if(!(0,sF.isDirective)(n)){e.reportError(`Expected directive but got: ${(0,gr.inspect)(n)}.`,n==null?void 0:n.astNode);continue}Hu(e,n);for(let r of n.args)if(Hu(e,r),(0,Rn.isInputType)(r.type)||e.reportError(`The type of @${n.name}(${r.name}:) must be Input Type but got: ${(0,gr.inspect)(r.type)}.`,r.astNode),(0,Rn.isRequiredArgument)(r)&&r.deprecationReason!=null){var t;e.reportError(`Required argument @${n.name}(${r.name}:) cannot be deprecated.`,[DI(r.astNode),(t=r.astNode)===null||t===void 0?void 0:t.type])}}}function Hu(e,t){t.name.startsWith("__")&&e.reportError(`Name "${t.name}" must not begin with "__", which is reserved by GraphQL introspection.`,t.astNode)}function WH(e){let t=i6(e),n=e.schema.getTypeMap();for(let r of Object.values(n)){if(!(0,Rn.isNamedType)(r)){e.reportError(`Expected GraphQL named type but got: ${(0,gr.inspect)(r)}.`,r.astNode);continue}(0,QH.isIntrospectionType)(r)||Hu(e,r),(0,Rn.isObjectType)(r)||(0,Rn.isInterfaceType)(r)?(rF(e,r),iF(e,r)):(0,Rn.isUnionType)(r)?e6(e,r):(0,Rn.isEnumType)(r)?t6(e,r):(0,Rn.isInputObjectType)(r)&&(n6(e,r),t(r))}}function rF(e,t){let n=Object.values(t.getFields());n.length===0&&e.reportError(`Type ${t.name} must define one or more fields.`,[t.astNode,...t.extensionASTNodes]);for(let o of n){if(Hu(e,o),!(0,Rn.isOutputType)(o.type)){var r;e.reportError(`The type of ${t.name}.${o.name} must be Output Type but got: ${(0,gr.inspect)(o.type)}.`,(r=o.astNode)===null||r===void 0?void 0:r.type)}for(let c of o.args){let l=c.name;if(Hu(e,c),!(0,Rn.isInputType)(c.type)){var i;e.reportError(`The type of ${t.name}.${o.name}(${l}:) must be Input Type but got: ${(0,gr.inspect)(c.type)}.`,(i=c.astNode)===null||i===void 0?void 0:i.type)}if((0,Rn.isRequiredArgument)(c)&&c.deprecationReason!=null){var a;e.reportError(`Required argument ${t.name}.${o.name}(${l}:) cannot be deprecated.`,[DI(c.astNode),(a=c.astNode)===null||a===void 0?void 0:a.type])}}}}function iF(e,t){let n=Object.create(null);for(let r of t.getInterfaces()){if(!(0,Rn.isInterfaceType)(r)){e.reportError(`Type ${(0,gr.inspect)(t)} must only implement Interface types, it cannot implement ${(0,gr.inspect)(r)}.`,Hd(t,r));continue}if(t===r){e.reportError(`Type ${t.name} cannot implement itself because it would create a circular reference.`,Hd(t,r));continue}if(n[r.name]){e.reportError(`Type ${t.name} can only implement ${r.name} once.`,Hd(t,r));continue}n[r.name]=!0,ZH(e,t,r),XH(e,t,r)}}function XH(e,t,n){let r=t.getFields();for(let l of Object.values(n.getFields())){let p=l.name,f=r[p];if(!f){e.reportError(`Interface field ${n.name}.${p} expected but ${t.name} does not provide it.`,[l.astNode,t.astNode,...t.extensionASTNodes]);continue}if(!(0,nF.isTypeSubTypeOf)(e.schema,f.type,l.type)){var i,a;e.reportError(`Interface field ${n.name}.${p} expects type ${(0,gr.inspect)(l.type)} but ${t.name}.${p} is type ${(0,gr.inspect)(f.type)}.`,[(i=l.astNode)===null||i===void 0?void 0:i.type,(a=f.astNode)===null||a===void 0?void 0:a.type])}for(let y of l.args){let g=y.name,v=f.args.find(P=>P.name===g);if(!v){e.reportError(`Interface field argument ${n.name}.${p}(${g}:) expected but ${t.name}.${p} does not provide it.`,[y.astNode,f.astNode]);continue}if(!(0,nF.isEqualType)(y.type,v.type)){var o,c;e.reportError(`Interface field argument ${n.name}.${p}(${g}:) expects type ${(0,gr.inspect)(y.type)} but ${t.name}.${p}(${g}:) is type ${(0,gr.inspect)(v.type)}.`,[(o=y.astNode)===null||o===void 0?void 0:o.type,(c=v.astNode)===null||c===void 0?void 0:c.type])}}for(let y of f.args){let g=y.name;!l.args.find(P=>P.name===g)&&(0,Rn.isRequiredArgument)(y)&&e.reportError(`Object field ${t.name}.${p} includes required argument ${g} that is missing from the Interface field ${n.name}.${p}.`,[y.astNode,l.astNode])}}}function ZH(e,t,n){let r=t.getInterfaces();for(let i of n.getInterfaces())r.includes(i)||e.reportError(i===t?`Type ${t.name} cannot implement ${n.name} because it would create a circular reference.`:`Type ${t.name} must implement ${i.name} because it is implemented by ${n.name}.`,[...Hd(n,i),...Hd(t,n)])}function e6(e,t){let n=t.getTypes();n.length===0&&e.reportError(`Union type ${t.name} must define one or more member types.`,[t.astNode,...t.extensionASTNodes]);let r=Object.create(null);for(let i of n){if(r[i.name]){e.reportError(`Union type ${t.name} can only include type ${i.name} once.`,aF(t,i.name));continue}r[i.name]=!0,(0,Rn.isObjectType)(i)||e.reportError(`Union type ${t.name} can only include Object types, it cannot include ${(0,gr.inspect)(i)}.`,aF(t,String(i)))}}function t6(e,t){let n=t.getValues();n.length===0&&e.reportError(`Enum type ${t.name} must define one or more values.`,[t.astNode,...t.extensionASTNodes]);for(let r of n)Hu(e,r)}function n6(e,t){let n=Object.values(t.getFields());n.length===0&&e.reportError(`Input Object type ${t.name} must define one or more fields.`,[t.astNode,...t.extensionASTNodes]);for(let a of n){if(Hu(e,a),!(0,Rn.isInputType)(a.type)){var r;e.reportError(`The type of ${t.name}.${a.name} must be Input Type but got: ${(0,gr.inspect)(a.type)}.`,(r=a.astNode)===null||r===void 0?void 0:r.type)}if((0,Rn.isRequiredInputField)(a)&&a.deprecationReason!=null){var i;e.reportError(`Required input field ${t.name}.${a.name} cannot be deprecated.`,[DI(a.astNode),(i=a.astNode)===null||i===void 0?void 0:i.type])}t.isOneOf&&r6(t,a,e)}}function r6(e,t,n){if((0,Rn.isNonNullType)(t.type)){var r;n.reportError(`OneOf input field ${e.name}.${t.name} must be nullable.`,(r=t.astNode)===null||r===void 0?void 0:r.type)}t.defaultValue!==void 0&&n.reportError(`OneOf input field ${e.name}.${t.name} cannot have a default value.`,t.astNode)}function i6(e){let t=Object.create(null),n=[],r=Object.create(null);return i;function i(a){if(t[a.name])return;t[a.name]=!0,r[a.name]=n.length;let o=Object.values(a.getFields());for(let c of o)if((0,Rn.isNonNullType)(c.type)&&(0,Rn.isInputObjectType)(c.type.ofType)){let l=c.type.ofType,p=r[l.name];if(n.push(c),p===void 0)i(l);else{let f=n.slice(p),y=f.map(g=>g.name).join(".");e.reportError(`Cannot reference Input Object "${l.name}" within itself through a series of non-null fields: "${y}".`,f.map(g=>g.astNode))}n.pop()}r[a.name]=void 0}}function Hd(e,t){let{astNode:n,extensionASTNodes:r}=e;return(n!=null?[n,...r]:r).flatMap(a=>{var o;return(o=a.interfaces)!==null&&o!==void 0?o:[]}).filter(a=>a.name.value===t.name)}function aF(e,t){let{astNode:n,extensionASTNodes:r}=e;return(n!=null?[n,...r]:r).flatMap(a=>{var o;return(o=a.types)!==null&&o!==void 0?o:[]}).filter(a=>a.name.value===t)}function DI(e){var t;return e==null||(t=e.directives)===null||t===void 0?void 0:t.find(n=>n.name.value===sF.GraphQLDeprecatedDirective.name)}});var Aa=w(RI=>{"use strict";m();T();N();Object.defineProperty(RI,"__esModule",{value:!0});RI.typeFromAST=AI;var bI=Pt(),uF=Ft();function AI(e,t){switch(t.kind){case bI.Kind.LIST_TYPE:{let n=AI(e,t.type);return n&&new uF.GraphQLList(n)}case bI.Kind.NON_NULL_TYPE:{let n=AI(e,t.type);return n&&new uF.GraphQLNonNull(n)}case bI.Kind.NAMED_TYPE:return e.getType(t.name.value)}}});var zm=w(Wd=>{"use strict";m();T();N();Object.defineProperty(Wd,"__esModule",{value:!0});Wd.TypeInfo=void 0;Wd.visitWithTypeInfo=o6;var a6=Sa(),Pn=Pt(),cF=ju(),Fn=Ft(),rl=Ai(),lF=Aa(),PI=class{constructor(t,n,r){this._schema=t,this._typeStack=[],this._parentTypeStack=[],this._inputTypeStack=[],this._fieldDefStack=[],this._defaultValueStack=[],this._directive=null,this._argument=null,this._enumValue=null,this._getFieldDef=r!=null?r:s6,n&&((0,Fn.isInputType)(n)&&this._inputTypeStack.push(n),(0,Fn.isCompositeType)(n)&&this._parentTypeStack.push(n),(0,Fn.isOutputType)(n)&&this._typeStack.push(n))}get[Symbol.toStringTag](){return"TypeInfo"}getType(){if(this._typeStack.length>0)return this._typeStack[this._typeStack.length-1]}getParentType(){if(this._parentTypeStack.length>0)return this._parentTypeStack[this._parentTypeStack.length-1]}getInputType(){if(this._inputTypeStack.length>0)return this._inputTypeStack[this._inputTypeStack.length-1]}getParentInputType(){if(this._inputTypeStack.length>1)return this._inputTypeStack[this._inputTypeStack.length-2]}getFieldDef(){if(this._fieldDefStack.length>0)return this._fieldDefStack[this._fieldDefStack.length-1]}getDefaultValue(){if(this._defaultValueStack.length>0)return this._defaultValueStack[this._defaultValueStack.length-1]}getDirective(){return this._directive}getArgument(){return this._argument}getEnumValue(){return this._enumValue}enter(t){let n=this._schema;switch(t.kind){case Pn.Kind.SELECTION_SET:{let i=(0,Fn.getNamedType)(this.getType());this._parentTypeStack.push((0,Fn.isCompositeType)(i)?i:void 0);break}case Pn.Kind.FIELD:{let i=this.getParentType(),a,o;i&&(a=this._getFieldDef(n,i,t),a&&(o=a.type)),this._fieldDefStack.push(a),this._typeStack.push((0,Fn.isOutputType)(o)?o:void 0);break}case Pn.Kind.DIRECTIVE:this._directive=n.getDirective(t.name.value);break;case Pn.Kind.OPERATION_DEFINITION:{let i=n.getRootType(t.operation);this._typeStack.push((0,Fn.isObjectType)(i)?i:void 0);break}case Pn.Kind.INLINE_FRAGMENT:case Pn.Kind.FRAGMENT_DEFINITION:{let i=t.typeCondition,a=i?(0,lF.typeFromAST)(n,i):(0,Fn.getNamedType)(this.getType());this._typeStack.push((0,Fn.isOutputType)(a)?a:void 0);break}case Pn.Kind.VARIABLE_DEFINITION:{let i=(0,lF.typeFromAST)(n,t.type);this._inputTypeStack.push((0,Fn.isInputType)(i)?i:void 0);break}case Pn.Kind.ARGUMENT:{var r;let i,a,o=(r=this.getDirective())!==null&&r!==void 0?r:this.getFieldDef();o&&(i=o.args.find(c=>c.name===t.name.value),i&&(a=i.type)),this._argument=i,this._defaultValueStack.push(i?i.defaultValue:void 0),this._inputTypeStack.push((0,Fn.isInputType)(a)?a:void 0);break}case Pn.Kind.LIST:{let i=(0,Fn.getNullableType)(this.getInputType()),a=(0,Fn.isListType)(i)?i.ofType:i;this._defaultValueStack.push(void 0),this._inputTypeStack.push((0,Fn.isInputType)(a)?a:void 0);break}case Pn.Kind.OBJECT_FIELD:{let i=(0,Fn.getNamedType)(this.getInputType()),a,o;(0,Fn.isInputObjectType)(i)&&(o=i.getFields()[t.name.value],o&&(a=o.type)),this._defaultValueStack.push(o?o.defaultValue:void 0),this._inputTypeStack.push((0,Fn.isInputType)(a)?a:void 0);break}case Pn.Kind.ENUM:{let i=(0,Fn.getNamedType)(this.getInputType()),a;(0,Fn.isEnumType)(i)&&(a=i.getValue(t.value)),this._enumValue=a;break}default:}}leave(t){switch(t.kind){case Pn.Kind.SELECTION_SET:this._parentTypeStack.pop();break;case Pn.Kind.FIELD:this._fieldDefStack.pop(),this._typeStack.pop();break;case Pn.Kind.DIRECTIVE:this._directive=null;break;case Pn.Kind.OPERATION_DEFINITION:case Pn.Kind.INLINE_FRAGMENT:case Pn.Kind.FRAGMENT_DEFINITION:this._typeStack.pop();break;case Pn.Kind.VARIABLE_DEFINITION:this._inputTypeStack.pop();break;case Pn.Kind.ARGUMENT:this._argument=null,this._defaultValueStack.pop(),this._inputTypeStack.pop();break;case Pn.Kind.LIST:case Pn.Kind.OBJECT_FIELD:this._defaultValueStack.pop(),this._inputTypeStack.pop();break;case Pn.Kind.ENUM:this._enumValue=null;break;default:}}};Wd.TypeInfo=PI;function s6(e,t,n){let r=n.name.value;if(r===rl.SchemaMetaFieldDef.name&&e.getQueryType()===t)return rl.SchemaMetaFieldDef;if(r===rl.TypeMetaFieldDef.name&&e.getQueryType()===t)return rl.TypeMetaFieldDef;if(r===rl.TypeNameMetaFieldDef.name&&(0,Fn.isCompositeType)(t))return rl.TypeNameMetaFieldDef;if((0,Fn.isObjectType)(t)||(0,Fn.isInterfaceType)(t))return t.getFields()[r]}function o6(e,t){return{enter(...n){let r=n[0];e.enter(r);let i=(0,cF.getEnterLeaveForKind)(t,r.kind).enter;if(i){let a=i.apply(t,n);return a!==void 0&&(e.leave(r),(0,a6.isNode)(a)&&e.enter(a)),a}},leave(...n){let r=n[0],i=(0,cF.getEnterLeaveForKind)(t,r.kind).leave,a;return i&&(a=i.apply(t,n)),e.leave(r),a}}}});var zu=w(Ri=>{"use strict";m();T();N();Object.defineProperty(Ri,"__esModule",{value:!0});Ri.isConstValueNode=FI;Ri.isDefinitionNode=u6;Ri.isExecutableDefinitionNode=dF;Ri.isSelectionNode=c6;Ri.isTypeDefinitionNode=mF;Ri.isTypeExtensionNode=TF;Ri.isTypeNode=l6;Ri.isTypeSystemDefinitionNode=fF;Ri.isTypeSystemExtensionNode=NF;Ri.isValueNode=pF;var wt=Pt();function u6(e){return dF(e)||fF(e)||NF(e)}function dF(e){return e.kind===wt.Kind.OPERATION_DEFINITION||e.kind===wt.Kind.FRAGMENT_DEFINITION}function c6(e){return e.kind===wt.Kind.FIELD||e.kind===wt.Kind.FRAGMENT_SPREAD||e.kind===wt.Kind.INLINE_FRAGMENT}function pF(e){return e.kind===wt.Kind.VARIABLE||e.kind===wt.Kind.INT||e.kind===wt.Kind.FLOAT||e.kind===wt.Kind.STRING||e.kind===wt.Kind.BOOLEAN||e.kind===wt.Kind.NULL||e.kind===wt.Kind.ENUM||e.kind===wt.Kind.LIST||e.kind===wt.Kind.OBJECT}function FI(e){return pF(e)&&(e.kind===wt.Kind.LIST?e.values.some(FI):e.kind===wt.Kind.OBJECT?e.fields.some(t=>FI(t.value)):e.kind!==wt.Kind.VARIABLE)}function l6(e){return e.kind===wt.Kind.NAMED_TYPE||e.kind===wt.Kind.LIST_TYPE||e.kind===wt.Kind.NON_NULL_TYPE}function fF(e){return e.kind===wt.Kind.SCHEMA_DEFINITION||mF(e)||e.kind===wt.Kind.DIRECTIVE_DEFINITION}function mF(e){return e.kind===wt.Kind.SCALAR_TYPE_DEFINITION||e.kind===wt.Kind.OBJECT_TYPE_DEFINITION||e.kind===wt.Kind.INTERFACE_TYPE_DEFINITION||e.kind===wt.Kind.UNION_TYPE_DEFINITION||e.kind===wt.Kind.ENUM_TYPE_DEFINITION||e.kind===wt.Kind.INPUT_OBJECT_TYPE_DEFINITION}function NF(e){return e.kind===wt.Kind.SCHEMA_EXTENSION||TF(e)}function TF(e){return e.kind===wt.Kind.SCALAR_TYPE_EXTENSION||e.kind===wt.Kind.OBJECT_TYPE_EXTENSION||e.kind===wt.Kind.INTERFACE_TYPE_EXTENSION||e.kind===wt.Kind.UNION_TYPE_EXTENSION||e.kind===wt.Kind.ENUM_TYPE_EXTENSION||e.kind===wt.Kind.INPUT_OBJECT_TYPE_EXTENSION}});var LI=w(wI=>{"use strict";m();T();N();Object.defineProperty(wI,"__esModule",{value:!0});wI.ExecutableDefinitionsRule=f6;var d6=He(),EF=Pt(),p6=zu();function f6(e){return{Document(t){for(let n of t.definitions)if(!(0,p6.isExecutableDefinitionNode)(n)){let r=n.kind===EF.Kind.SCHEMA_DEFINITION||n.kind===EF.Kind.SCHEMA_EXTENSION?"schema":'"'+n.name.value+'"';e.reportError(new d6.GraphQLError(`The ${r} definition is not executable.`,{nodes:n}))}return!1}}}});var BI=w(CI=>{"use strict";m();T();N();Object.defineProperty(CI,"__esModule",{value:!0});CI.FieldsOnCorrectTypeRule=E6;var hF=zo(),m6=Cd(),N6=Xo(),T6=He(),Xd=Ft();function E6(e){return{Field(t){let n=e.getParentType();if(n&&!e.getFieldDef()){let i=e.getSchema(),a=t.name.value,o=(0,hF.didYouMean)("to use an inline fragment on",h6(i,n,a));o===""&&(o=(0,hF.didYouMean)(y6(n,a))),e.reportError(new T6.GraphQLError(`Cannot query field "${a}" on type "${n.name}".`+o,{nodes:t}))}}}}function h6(e,t,n){if(!(0,Xd.isAbstractType)(t))return[];let r=new Set,i=Object.create(null);for(let o of e.getPossibleTypes(t))if(o.getFields()[n]){r.add(o),i[o.name]=1;for(let c of o.getInterfaces()){var a;c.getFields()[n]&&(r.add(c),i[c.name]=((a=i[c.name])!==null&&a!==void 0?a:0)+1)}}return[...r].sort((o,c)=>{let l=i[c.name]-i[o.name];return l!==0?l:(0,Xd.isInterfaceType)(o)&&e.isSubType(o,c)?-1:(0,Xd.isInterfaceType)(c)&&e.isSubType(c,o)?1:(0,m6.naturalCompare)(o.name,c.name)}).map(o=>o.name)}function y6(e,t){if((0,Xd.isObjectType)(e)||(0,Xd.isInterfaceType)(e)){let n=Object.keys(e.getFields());return(0,N6.suggestionList)(t,n)}return[]}});var kI=w(UI=>{"use strict";m();T();N();Object.defineProperty(UI,"__esModule",{value:!0});UI.FragmentsOnCompositeTypesRule=I6;var yF=He(),IF=ci(),gF=Ft(),_F=Aa();function I6(e){return{InlineFragment(t){let n=t.typeCondition;if(n){let r=(0,_F.typeFromAST)(e.getSchema(),n);if(r&&!(0,gF.isCompositeType)(r)){let i=(0,IF.print)(n);e.reportError(new yF.GraphQLError(`Fragment cannot condition on non composite type "${i}".`,{nodes:n}))}}},FragmentDefinition(t){let n=(0,_F.typeFromAST)(e.getSchema(),t.typeCondition);if(n&&!(0,gF.isCompositeType)(n)){let r=(0,IF.print)(t.typeCondition);e.reportError(new yF.GraphQLError(`Fragment "${t.name.value}" cannot condition on non composite type "${r}".`,{nodes:t.typeCondition}))}}}}});var MI=w(Wm=>{"use strict";m();T();N();Object.defineProperty(Wm,"__esModule",{value:!0});Wm.KnownArgumentNamesOnDirectivesRule=DF;Wm.KnownArgumentNamesRule=v6;var vF=zo(),SF=Xo(),OF=He(),g6=Pt(),_6=Gr();function v6(e){return Y(x({},DF(e)),{Argument(t){let n=e.getArgument(),r=e.getFieldDef(),i=e.getParentType();if(!n&&r&&i){let a=t.name.value,o=r.args.map(l=>l.name),c=(0,SF.suggestionList)(a,o);e.reportError(new OF.GraphQLError(`Unknown argument "${a}" on field "${i.name}.${r.name}".`+(0,vF.didYouMean)(c),{nodes:t}))}}})}function DF(e){let t=Object.create(null),n=e.getSchema(),r=n?n.getDirectives():_6.specifiedDirectives;for(let o of r)t[o.name]=o.args.map(c=>c.name);let i=e.getDocument().definitions;for(let o of i)if(o.kind===g6.Kind.DIRECTIVE_DEFINITION){var a;let c=(a=o.arguments)!==null&&a!==void 0?a:[];t[o.name.value]=c.map(l=>l.name.value)}return{Directive(o){let c=o.name.value,l=t[c];if(o.arguments&&l)for(let p of o.arguments){let f=p.name.value;if(!l.includes(f)){let y=(0,SF.suggestionList)(f,l);e.reportError(new OF.GraphQLError(`Unknown argument "${f}" on directive "@${c}".`+(0,vF.didYouMean)(y),{nodes:p}))}}return!1}}}});var jI=w(VI=>{"use strict";m();T();N();Object.defineProperty(VI,"__esModule",{value:!0});VI.KnownDirectivesRule=D6;var S6=Yt(),xI=yr(),bF=He(),qI=Sa(),Xn=zc(),En=Pt(),O6=Gr();function D6(e){let t=Object.create(null),n=e.getSchema(),r=n?n.getDirectives():O6.specifiedDirectives;for(let a of r)t[a.name]=a.locations;let i=e.getDocument().definitions;for(let a of i)a.kind===En.Kind.DIRECTIVE_DEFINITION&&(t[a.name.value]=a.locations.map(o=>o.value));return{Directive(a,o,c,l,p){let f=a.name.value,y=t[f];if(!y){e.reportError(new bF.GraphQLError(`Unknown directive "@${f}".`,{nodes:a}));return}let g=b6(p);g&&!y.includes(g)&&e.reportError(new bF.GraphQLError(`Directive "@${f}" may not be used on ${g}.`,{nodes:a}))}}}function b6(e){let t=e[e.length-1];switch("kind"in t||(0,xI.invariant)(!1),t.kind){case En.Kind.OPERATION_DEFINITION:return A6(t.operation);case En.Kind.FIELD:return Xn.DirectiveLocation.FIELD;case En.Kind.FRAGMENT_SPREAD:return Xn.DirectiveLocation.FRAGMENT_SPREAD;case En.Kind.INLINE_FRAGMENT:return Xn.DirectiveLocation.INLINE_FRAGMENT;case En.Kind.FRAGMENT_DEFINITION:return Xn.DirectiveLocation.FRAGMENT_DEFINITION;case En.Kind.VARIABLE_DEFINITION:return Xn.DirectiveLocation.VARIABLE_DEFINITION;case En.Kind.SCHEMA_DEFINITION:case En.Kind.SCHEMA_EXTENSION:return Xn.DirectiveLocation.SCHEMA;case En.Kind.SCALAR_TYPE_DEFINITION:case En.Kind.SCALAR_TYPE_EXTENSION:return Xn.DirectiveLocation.SCALAR;case En.Kind.OBJECT_TYPE_DEFINITION:case En.Kind.OBJECT_TYPE_EXTENSION:return Xn.DirectiveLocation.OBJECT;case En.Kind.FIELD_DEFINITION:return Xn.DirectiveLocation.FIELD_DEFINITION;case En.Kind.INTERFACE_TYPE_DEFINITION:case En.Kind.INTERFACE_TYPE_EXTENSION:return Xn.DirectiveLocation.INTERFACE;case En.Kind.UNION_TYPE_DEFINITION:case En.Kind.UNION_TYPE_EXTENSION:return Xn.DirectiveLocation.UNION;case En.Kind.ENUM_TYPE_DEFINITION:case En.Kind.ENUM_TYPE_EXTENSION:return Xn.DirectiveLocation.ENUM;case En.Kind.ENUM_VALUE_DEFINITION:return Xn.DirectiveLocation.ENUM_VALUE;case En.Kind.INPUT_OBJECT_TYPE_DEFINITION:case En.Kind.INPUT_OBJECT_TYPE_EXTENSION:return Xn.DirectiveLocation.INPUT_OBJECT;case En.Kind.INPUT_VALUE_DEFINITION:{let n=e[e.length-3];return"kind"in n||(0,xI.invariant)(!1),n.kind===En.Kind.INPUT_OBJECT_TYPE_DEFINITION?Xn.DirectiveLocation.INPUT_FIELD_DEFINITION:Xn.DirectiveLocation.ARGUMENT_DEFINITION}default:(0,xI.invariant)(!1,"Unexpected kind: "+(0,S6.inspect)(t.kind))}}function A6(e){switch(e){case qI.OperationTypeNode.QUERY:return Xn.DirectiveLocation.QUERY;case qI.OperationTypeNode.MUTATION:return Xn.DirectiveLocation.MUTATION;case qI.OperationTypeNode.SUBSCRIPTION:return Xn.DirectiveLocation.SUBSCRIPTION}}});var GI=w(KI=>{"use strict";m();T();N();Object.defineProperty(KI,"__esModule",{value:!0});KI.KnownFragmentNamesRule=P6;var R6=He();function P6(e){return{FragmentSpread(t){let n=t.name.value;e.getFragment(n)||e.reportError(new R6.GraphQLError(`Unknown fragment "${n}".`,{nodes:t.name}))}}}});var YI=w(QI=>{"use strict";m();T();N();Object.defineProperty(QI,"__esModule",{value:!0});QI.KnownTypeNamesRule=U6;var F6=zo(),w6=Xo(),L6=He(),$I=zu(),C6=Ai(),B6=ba();function U6(e){let t=e.getSchema(),n=t?t.getTypeMap():Object.create(null),r=Object.create(null);for(let a of e.getDocument().definitions)(0,$I.isTypeDefinitionNode)(a)&&(r[a.name.value]=!0);let i=[...Object.keys(n),...Object.keys(r)];return{NamedType(a,o,c,l,p){let f=a.name.value;if(!n[f]&&!r[f]){var y;let g=(y=p[2])!==null&&y!==void 0?y:c,v=g!=null&&k6(g);if(v&&AF.includes(f))return;let P=(0,w6.suggestionList)(f,v?AF.concat(i):i);e.reportError(new L6.GraphQLError(`Unknown type "${f}".`+(0,F6.didYouMean)(P),{nodes:a}))}}}}var AF=[...B6.specifiedScalarTypes,...C6.introspectionTypes].map(e=>e.name);function k6(e){return"kind"in e&&((0,$I.isTypeSystemDefinitionNode)(e)||(0,$I.isTypeSystemExtensionNode)(e))}});var HI=w(JI=>{"use strict";m();T();N();Object.defineProperty(JI,"__esModule",{value:!0});JI.LoneAnonymousOperationRule=q6;var M6=He(),x6=Pt();function q6(e){let t=0;return{Document(n){t=n.definitions.filter(r=>r.kind===x6.Kind.OPERATION_DEFINITION).length},OperationDefinition(n){!n.name&&t>1&&e.reportError(new M6.GraphQLError("This anonymous operation must be the only defined operation.",{nodes:n}))}}}});var WI=w(zI=>{"use strict";m();T();N();Object.defineProperty(zI,"__esModule",{value:!0});zI.LoneSchemaDefinitionRule=V6;var RF=He();function V6(e){var t,n,r;let i=e.getSchema(),a=(t=(n=(r=i==null?void 0:i.astNode)!==null&&r!==void 0?r:i==null?void 0:i.getQueryType())!==null&&n!==void 0?n:i==null?void 0:i.getMutationType())!==null&&t!==void 0?t:i==null?void 0:i.getSubscriptionType(),o=0;return{SchemaDefinition(c){if(a){e.reportError(new RF.GraphQLError("Cannot define a new schema within a schema extension.",{nodes:c}));return}o>0&&e.reportError(new RF.GraphQLError("Must provide only one schema definition.",{nodes:c})),++o}}}});var ZI=w(XI=>{"use strict";m();T();N();Object.defineProperty(XI,"__esModule",{value:!0});XI.MaxIntrospectionDepthRule=G6;var j6=He(),PF=Pt(),K6=3;function G6(e){function t(n,r=Object.create(null),i=0){if(n.kind===PF.Kind.FRAGMENT_SPREAD){let a=n.name.value;if(r[a]===!0)return!1;let o=e.getFragment(a);if(!o)return!1;try{return r[a]=!0,t(o,r,i)}finally{r[a]=void 0}}if(n.kind===PF.Kind.FIELD&&(n.name.value==="fields"||n.name.value==="interfaces"||n.name.value==="possibleTypes"||n.name.value==="inputFields")&&(i++,i>=K6))return!0;if("selectionSet"in n&&n.selectionSet){for(let a of n.selectionSet.selections)if(t(a,r,i))return!0}return!1}return{Field(n){if((n.name.value==="__schema"||n.name.value==="__type")&&t(n))return e.reportError(new j6.GraphQLError("Maximum introspection depth exceeded",{nodes:[n]})),!1}}}});var tg=w(eg=>{"use strict";m();T();N();Object.defineProperty(eg,"__esModule",{value:!0});eg.NoFragmentCyclesRule=Q6;var $6=He();function Q6(e){let t=Object.create(null),n=[],r=Object.create(null);return{OperationDefinition:()=>!1,FragmentDefinition(a){return i(a),!1}};function i(a){if(t[a.name.value])return;let o=a.name.value;t[o]=!0;let c=e.getFragmentSpreads(a.selectionSet);if(c.length!==0){r[o]=n.length;for(let l of c){let p=l.name.value,f=r[p];if(n.push(l),f===void 0){let y=e.getFragment(p);y&&i(y)}else{let y=n.slice(f),g=y.slice(0,-1).map(v=>'"'+v.name.value+'"').join(", ");e.reportError(new $6.GraphQLError(`Cannot spread fragment "${p}" within itself`+(g!==""?` via ${g}.`:"."),{nodes:y}))}n.pop()}r[o]=void 0}}}});var rg=w(ng=>{"use strict";m();T();N();Object.defineProperty(ng,"__esModule",{value:!0});ng.NoUndefinedVariablesRule=J6;var Y6=He();function J6(e){let t=Object.create(null);return{OperationDefinition:{enter(){t=Object.create(null)},leave(n){let r=e.getRecursiveVariableUsages(n);for(let{node:i}of r){let a=i.name.value;t[a]!==!0&&e.reportError(new Y6.GraphQLError(n.name?`Variable "$${a}" is not defined by operation "${n.name.value}".`:`Variable "$${a}" is not defined.`,{nodes:[i,n]}))}}},VariableDefinition(n){t[n.variable.name.value]=!0}}}});var ag=w(ig=>{"use strict";m();T();N();Object.defineProperty(ig,"__esModule",{value:!0});ig.NoUnusedFragmentsRule=z6;var H6=He();function z6(e){let t=[],n=[];return{OperationDefinition(r){return t.push(r),!1},FragmentDefinition(r){return n.push(r),!1},Document:{leave(){let r=Object.create(null);for(let i of t)for(let a of e.getRecursivelyReferencedFragments(i))r[a.name.value]=!0;for(let i of n){let a=i.name.value;r[a]!==!0&&e.reportError(new H6.GraphQLError(`Fragment "${a}" is never used.`,{nodes:i}))}}}}}});var og=w(sg=>{"use strict";m();T();N();Object.defineProperty(sg,"__esModule",{value:!0});sg.NoUnusedVariablesRule=X6;var W6=He();function X6(e){let t=[];return{OperationDefinition:{enter(){t=[]},leave(n){let r=Object.create(null),i=e.getRecursiveVariableUsages(n);for(let{node:a}of i)r[a.name.value]=!0;for(let a of t){let o=a.variable.name.value;r[o]!==!0&&e.reportError(new W6.GraphQLError(n.name?`Variable "$${o}" is never used in operation "${n.name.value}".`:`Variable "$${o}" is never used.`,{nodes:a}))}}},VariableDefinition(n){t.push(n)}}}});var lg=w(cg=>{"use strict";m();T();N();Object.defineProperty(cg,"__esModule",{value:!0});cg.sortValueNode=ug;var Z6=Cd(),ds=Pt();function ug(e){switch(e.kind){case ds.Kind.OBJECT:return Y(x({},e),{fields:ez(e.fields)});case ds.Kind.LIST:return Y(x({},e),{values:e.values.map(ug)});case ds.Kind.INT:case ds.Kind.FLOAT:case ds.Kind.STRING:case ds.Kind.BOOLEAN:case ds.Kind.NULL:case ds.Kind.ENUM:case ds.Kind.VARIABLE:return e}}function ez(e){return e.map(t=>Y(x({},t),{value:ug(t.value)})).sort((t,n)=>(0,Z6.naturalCompare)(t.name.value,n.name.value))}});var Eg=w(Tg=>{"use strict";m();T();N();Object.defineProperty(Tg,"__esModule",{value:!0});Tg.OverlappingFieldsCanBeMergedRule=iz;var FF=Yt(),tz=He(),dg=Pt(),nz=ci(),$r=Ft(),rz=lg(),LF=Aa();function CF(e){return Array.isArray(e)?e.map(([t,n])=>`subfields "${t}" conflict because `+CF(n)).join(" and "):e}function iz(e){let t=new mg,n=new Map;return{SelectionSet(r){let i=az(e,n,t,e.getParentType(),r);for(let[[a,o],c,l]of i){let p=CF(o);e.reportError(new tz.GraphQLError(`Fields "${a}" conflict because ${p}. Use different aliases on the fields to fetch both if this was intentional.`,{nodes:c.concat(l)}))}}}}function az(e,t,n,r,i){let a=[],[o,c]=eN(e,t,r,i);if(oz(e,a,t,n,o),c.length!==0)for(let l=0;l1)for(let c=0;c[a.value,o]));return n.every(a=>{let o=a.value,c=i.get(a.name.value);return c===void 0?!1:wF(o)===wF(c)})}function wF(e){return(0,nz.print)((0,rz.sortValueNode)(e))}function pg(e,t){return(0,$r.isListType)(e)?(0,$r.isListType)(t)?pg(e.ofType,t.ofType):!0:(0,$r.isListType)(t)?!0:(0,$r.isNonNullType)(e)?(0,$r.isNonNullType)(t)?pg(e.ofType,t.ofType):!0:(0,$r.isNonNullType)(t)?!0:(0,$r.isLeafType)(e)||(0,$r.isLeafType)(t)?e!==t:!1}function eN(e,t,n,r){let i=t.get(r);if(i)return i;let a=Object.create(null),o=Object.create(null);UF(e,n,r,a,o);let c=[a,Object.keys(o)];return t.set(r,c),c}function fg(e,t,n){let r=t.get(n.selectionSet);if(r)return r;let i=(0,LF.typeFromAST)(e.getSchema(),n.typeCondition);return eN(e,t,i,n.selectionSet)}function UF(e,t,n,r,i){for(let a of n.selections)switch(a.kind){case dg.Kind.FIELD:{let o=a.name.value,c;((0,$r.isObjectType)(t)||(0,$r.isInterfaceType)(t))&&(c=t.getFields()[o]);let l=a.alias?a.alias.value:o;r[l]||(r[l]=[]),r[l].push([t,a,c]);break}case dg.Kind.FRAGMENT_SPREAD:i[a.name.value]=!0;break;case dg.Kind.INLINE_FRAGMENT:{let o=a.typeCondition,c=o?(0,LF.typeFromAST)(e.getSchema(),o):t;UF(e,c,a.selectionSet,r,i);break}}}function cz(e,t,n,r){if(e.length>0)return[[t,e.map(([i])=>i)],[n,...e.map(([,i])=>i).flat()],[r,...e.map(([,,i])=>i).flat()]]}var mg=class{constructor(){this._data=new Map}has(t,n,r){var i;let[a,o]=t{"use strict";m();T();N();Object.defineProperty(yg,"__esModule",{value:!0});yg.PossibleFragmentSpreadsRule=dz;var tN=Yt(),kF=He(),hg=Ft(),MF=qd(),lz=Aa();function dz(e){return{InlineFragment(t){let n=e.getType(),r=e.getParentType();if((0,hg.isCompositeType)(n)&&(0,hg.isCompositeType)(r)&&!(0,MF.doTypesOverlap)(e.getSchema(),n,r)){let i=(0,tN.inspect)(r),a=(0,tN.inspect)(n);e.reportError(new kF.GraphQLError(`Fragment cannot be spread here as objects of type "${i}" can never be of type "${a}".`,{nodes:t}))}},FragmentSpread(t){let n=t.name.value,r=pz(e,n),i=e.getParentType();if(r&&i&&!(0,MF.doTypesOverlap)(e.getSchema(),r,i)){let a=(0,tN.inspect)(i),o=(0,tN.inspect)(r);e.reportError(new kF.GraphQLError(`Fragment "${n}" cannot be spread here as objects of type "${a}" can never be of type "${o}".`,{nodes:t}))}}}}function pz(e,t){let n=e.getFragment(t);if(n){let r=(0,lz.typeFromAST)(e.getSchema(),n.typeCondition);if((0,hg.isCompositeType)(r))return r}}});var _g=w(gg=>{"use strict";m();T();N();Object.defineProperty(gg,"__esModule",{value:!0});gg.PossibleTypeExtensionsRule=Tz;var fz=zo(),qF=Yt(),VF=yr(),mz=Xo(),xF=He(),In=Pt(),Nz=zu(),il=Ft();function Tz(e){let t=e.getSchema(),n=Object.create(null);for(let i of e.getDocument().definitions)(0,Nz.isTypeDefinitionNode)(i)&&(n[i.name.value]=i);return{ScalarTypeExtension:r,ObjectTypeExtension:r,InterfaceTypeExtension:r,UnionTypeExtension:r,EnumTypeExtension:r,InputObjectTypeExtension:r};function r(i){let a=i.name.value,o=n[a],c=t==null?void 0:t.getType(a),l;if(o?l=Ez[o.kind]:c&&(l=hz(c)),l){if(l!==i.kind){let p=yz(i.kind);e.reportError(new xF.GraphQLError(`Cannot extend non-${p} type "${a}".`,{nodes:o?[o,i]:i}))}}else{let p=Object.keys(x(x({},n),t==null?void 0:t.getTypeMap())),f=(0,mz.suggestionList)(a,p);e.reportError(new xF.GraphQLError(`Cannot extend type "${a}" because it is not defined.`+(0,fz.didYouMean)(f),{nodes:i.name}))}}}var Ez={[In.Kind.SCALAR_TYPE_DEFINITION]:In.Kind.SCALAR_TYPE_EXTENSION,[In.Kind.OBJECT_TYPE_DEFINITION]:In.Kind.OBJECT_TYPE_EXTENSION,[In.Kind.INTERFACE_TYPE_DEFINITION]:In.Kind.INTERFACE_TYPE_EXTENSION,[In.Kind.UNION_TYPE_DEFINITION]:In.Kind.UNION_TYPE_EXTENSION,[In.Kind.ENUM_TYPE_DEFINITION]:In.Kind.ENUM_TYPE_EXTENSION,[In.Kind.INPUT_OBJECT_TYPE_DEFINITION]:In.Kind.INPUT_OBJECT_TYPE_EXTENSION};function hz(e){if((0,il.isScalarType)(e))return In.Kind.SCALAR_TYPE_EXTENSION;if((0,il.isObjectType)(e))return In.Kind.OBJECT_TYPE_EXTENSION;if((0,il.isInterfaceType)(e))return In.Kind.INTERFACE_TYPE_EXTENSION;if((0,il.isUnionType)(e))return In.Kind.UNION_TYPE_EXTENSION;if((0,il.isEnumType)(e))return In.Kind.ENUM_TYPE_EXTENSION;if((0,il.isInputObjectType)(e))return In.Kind.INPUT_OBJECT_TYPE_EXTENSION;(0,VF.invariant)(!1,"Unexpected type: "+(0,qF.inspect)(e))}function yz(e){switch(e){case In.Kind.SCALAR_TYPE_EXTENSION:return"scalar";case In.Kind.OBJECT_TYPE_EXTENSION:return"object";case In.Kind.INTERFACE_TYPE_EXTENSION:return"interface";case In.Kind.UNION_TYPE_EXTENSION:return"union";case In.Kind.ENUM_TYPE_EXTENSION:return"enum";case In.Kind.INPUT_OBJECT_TYPE_EXTENSION:return"input object";default:(0,VF.invariant)(!1,"Unexpected kind: "+(0,qF.inspect)(e))}}});var Sg=w(nN=>{"use strict";m();T();N();Object.defineProperty(nN,"__esModule",{value:!0});nN.ProvidedRequiredArgumentsOnDirectivesRule=QF;nN.ProvidedRequiredArgumentsRule=_z;var KF=Yt(),jF=Wo(),GF=He(),$F=Pt(),Iz=ci(),vg=Ft(),gz=Gr();function _z(e){return Y(x({},QF(e)),{Field:{leave(t){var n;let r=e.getFieldDef();if(!r)return!1;let i=new Set((n=t.arguments)===null||n===void 0?void 0:n.map(a=>a.name.value));for(let a of r.args)if(!i.has(a.name)&&(0,vg.isRequiredArgument)(a)){let o=(0,KF.inspect)(a.type);e.reportError(new GF.GraphQLError(`Field "${r.name}" argument "${a.name}" of type "${o}" is required, but it was not provided.`,{nodes:t}))}}}})}function QF(e){var t;let n=Object.create(null),r=e.getSchema(),i=(t=r==null?void 0:r.getDirectives())!==null&&t!==void 0?t:gz.specifiedDirectives;for(let c of i)n[c.name]=(0,jF.keyMap)(c.args.filter(vg.isRequiredArgument),l=>l.name);let a=e.getDocument().definitions;for(let c of a)if(c.kind===$F.Kind.DIRECTIVE_DEFINITION){var o;let l=(o=c.arguments)!==null&&o!==void 0?o:[];n[c.name.value]=(0,jF.keyMap)(l.filter(vz),p=>p.name.value)}return{Directive:{leave(c){let l=c.name.value,p=n[l];if(p){var f;let y=(f=c.arguments)!==null&&f!==void 0?f:[],g=new Set(y.map(v=>v.name.value));for(let[v,P]of Object.entries(p))if(!g.has(v)){let U=(0,vg.isType)(P.type)?(0,KF.inspect)(P.type):(0,Iz.print)(P.type);e.reportError(new GF.GraphQLError(`Directive "@${l}" argument "${v}" of type "${U}" is required, but it was not provided.`,{nodes:c}))}}}}}}function vz(e){return e.type.kind===$F.Kind.NON_NULL_TYPE&&e.defaultValue==null}});var Dg=w(Og=>{"use strict";m();T();N();Object.defineProperty(Og,"__esModule",{value:!0});Og.ScalarLeafsRule=Sz;var YF=Yt(),JF=He(),HF=Ft();function Sz(e){return{Field(t){let n=e.getType(),r=t.selectionSet;if(n){if((0,HF.isLeafType)((0,HF.getNamedType)(n))){if(r){let i=t.name.value,a=(0,YF.inspect)(n);e.reportError(new JF.GraphQLError(`Field "${i}" must not have a selection since type "${a}" has no subfields.`,{nodes:r}))}}else if(!r){let i=t.name.value,a=(0,YF.inspect)(n);e.reportError(new JF.GraphQLError(`Field "${i}" of type "${a}" must have a selection of subfields. Did you mean "${i} { ... }"?`,{nodes:t}))}}}}}});var Ag=w(bg=>{"use strict";m();T();N();Object.defineProperty(bg,"__esModule",{value:!0});bg.printPathArray=Oz;function Oz(e){return e.map(t=>typeof t=="number"?"["+t.toString()+"]":"."+t).join("")}});var Zd=w(rN=>{"use strict";m();T();N();Object.defineProperty(rN,"__esModule",{value:!0});rN.addPath=Dz;rN.pathToArray=bz;function Dz(e,t,n){return{prev:e,key:t,typename:n}}function bz(e){let t=[],n=e;for(;n;)t.push(n.key),n=n.prev;return t.reverse()}});var Pg=w(Rg=>{"use strict";m();T();N();Object.defineProperty(Rg,"__esModule",{value:!0});Rg.coerceInputValue=Cz;var Az=zo(),iN=Yt(),Rz=yr(),Pz=Qm(),Fz=va(),ea=Zd(),wz=Ag(),Lz=Xo(),ps=He(),ep=Ft();function Cz(e,t,n=Bz){return tp(e,t,n,void 0)}function Bz(e,t,n){let r="Invalid value "+(0,iN.inspect)(t);throw e.length>0&&(r+=` at "value${(0,wz.printPathArray)(e)}"`),n.message=r+": "+n.message,n}function tp(e,t,n,r){if((0,ep.isNonNullType)(t)){if(e!=null)return tp(e,t.ofType,n,r);n((0,ea.pathToArray)(r),e,new ps.GraphQLError(`Expected non-nullable type "${(0,iN.inspect)(t)}" not to be null.`));return}if(e==null)return null;if((0,ep.isListType)(t)){let i=t.ofType;return(0,Pz.isIterableObject)(e)?Array.from(e,(a,o)=>{let c=(0,ea.addPath)(r,o,void 0);return tp(a,i,n,c)}):[tp(e,i,n,r)]}if((0,ep.isInputObjectType)(t)){if(!(0,Fz.isObjectLike)(e)){n((0,ea.pathToArray)(r),e,new ps.GraphQLError(`Expected type "${t.name}" to be an object.`));return}let i={},a=t.getFields();for(let o of Object.values(a)){let c=e[o.name];if(c===void 0){if(o.defaultValue!==void 0)i[o.name]=o.defaultValue;else if((0,ep.isNonNullType)(o.type)){let l=(0,iN.inspect)(o.type);n((0,ea.pathToArray)(r),e,new ps.GraphQLError(`Field "${o.name}" of required type "${l}" was not provided.`))}continue}i[o.name]=tp(c,o.type,n,(0,ea.addPath)(r,o.name,t.name))}for(let o of Object.keys(e))if(!a[o]){let c=(0,Lz.suggestionList)(o,Object.keys(t.getFields()));n((0,ea.pathToArray)(r),e,new ps.GraphQLError(`Field "${o}" is not defined by type "${t.name}".`+(0,Az.didYouMean)(c)))}if(t.isOneOf){let o=Object.keys(i);o.length!==1&&n((0,ea.pathToArray)(r),e,new ps.GraphQLError(`Exactly one key must be specified for OneOf type "${t.name}".`));let c=o[0],l=i[c];l===null&&n((0,ea.pathToArray)(r).concat(c),l,new ps.GraphQLError(`Field "${c}" must be non-null.`))}return i}if((0,ep.isLeafType)(t)){let i;try{i=t.parseValue(e)}catch(a){a instanceof ps.GraphQLError?n((0,ea.pathToArray)(r),e,a):n((0,ea.pathToArray)(r),e,new ps.GraphQLError(`Expected type "${t.name}". `+a.message,{originalError:a}));return}return i===void 0&&n((0,ea.pathToArray)(r),e,new ps.GraphQLError(`Expected type "${t.name}".`)),i}(0,Rz.invariant)(!1,"Unexpected input type: "+(0,iN.inspect)(t))}});var rp=w(Fg=>{"use strict";m();T();N();Object.defineProperty(Fg,"__esModule",{value:!0});Fg.valueFromAST=np;var Uz=Yt(),kz=yr(),Mz=Wo(),al=Pt(),Wu=Ft();function np(e,t,n){if(e){if(e.kind===al.Kind.VARIABLE){let r=e.name.value;if(n==null||n[r]===void 0)return;let i=n[r];return i===null&&(0,Wu.isNonNullType)(t)?void 0:i}if((0,Wu.isNonNullType)(t))return e.kind===al.Kind.NULL?void 0:np(e,t.ofType,n);if(e.kind===al.Kind.NULL)return null;if((0,Wu.isListType)(t)){let r=t.ofType;if(e.kind===al.Kind.LIST){let a=[];for(let o of e.values)if(zF(o,n)){if((0,Wu.isNonNullType)(r))return;a.push(null)}else{let c=np(o,r,n);if(c===void 0)return;a.push(c)}return a}let i=np(e,r,n);return i===void 0?void 0:[i]}if((0,Wu.isInputObjectType)(t)){if(e.kind!==al.Kind.OBJECT)return;let r=Object.create(null),i=(0,Mz.keyMap)(e.fields,a=>a.name.value);for(let a of Object.values(t.getFields())){let o=i[a.name];if(!o||zF(o.value,n)){if(a.defaultValue!==void 0)r[a.name]=a.defaultValue;else if((0,Wu.isNonNullType)(a.type))return;continue}let c=np(o.value,a.type,n);if(c===void 0)return;r[a.name]=c}if(t.isOneOf){let a=Object.keys(r);if(a.length!==1||r[a[0]]===null)return}return r}if((0,Wu.isLeafType)(t)){let r;try{r=t.parseLiteral(e,n)}catch(i){return}return r===void 0?void 0:r}(0,kz.invariant)(!1,"Unexpected input type: "+(0,Uz.inspect)(t))}}function zF(e,t){return e.kind===al.Kind.VARIABLE&&(t==null||t[e.name.value]===void 0)}});var ul=w(ip=>{"use strict";m();T();N();Object.defineProperty(ip,"__esModule",{value:!0});ip.getArgumentValues=ew;ip.getDirectiveValues=$z;ip.getVariableValues=Kz;var sl=Yt(),xz=Wo(),qz=Ag(),fs=He(),WF=Pt(),XF=ci(),ol=Ft(),Vz=Pg(),jz=Aa(),ZF=rp();function Kz(e,t,n,r){let i=[],a=r==null?void 0:r.maxErrors;try{let o=Gz(e,t,n,c=>{if(a!=null&&i.length>=a)throw new fs.GraphQLError("Too many errors processing variables, error limit reached. Execution aborted.");i.push(c)});if(i.length===0)return{coerced:o}}catch(o){i.push(o)}return{errors:i}}function Gz(e,t,n,r){let i={};for(let a of t){let o=a.variable.name.value,c=(0,jz.typeFromAST)(e,a.type);if(!(0,ol.isInputType)(c)){let p=(0,XF.print)(a.type);r(new fs.GraphQLError(`Variable "$${o}" expected value of type "${p}" which cannot be used as an input type.`,{nodes:a.type}));continue}if(!tw(n,o)){if(a.defaultValue)i[o]=(0,ZF.valueFromAST)(a.defaultValue,c);else if((0,ol.isNonNullType)(c)){let p=(0,sl.inspect)(c);r(new fs.GraphQLError(`Variable "$${o}" of required type "${p}" was not provided.`,{nodes:a}))}continue}let l=n[o];if(l===null&&(0,ol.isNonNullType)(c)){let p=(0,sl.inspect)(c);r(new fs.GraphQLError(`Variable "$${o}" of non-null type "${p}" must not be null.`,{nodes:a}));continue}i[o]=(0,Vz.coerceInputValue)(l,c,(p,f,y)=>{let g=`Variable "$${o}" got invalid value `+(0,sl.inspect)(f);p.length>0&&(g+=` at "${o}${(0,qz.printPathArray)(p)}"`),r(new fs.GraphQLError(g+"; "+y.message,{nodes:a,originalError:y}))})}return i}function ew(e,t,n){var r;let i={},a=(r=t.arguments)!==null&&r!==void 0?r:[],o=(0,xz.keyMap)(a,c=>c.name.value);for(let c of e.args){let l=c.name,p=c.type,f=o[l];if(!f){if(c.defaultValue!==void 0)i[l]=c.defaultValue;else if((0,ol.isNonNullType)(p))throw new fs.GraphQLError(`Argument "${l}" of required type "${(0,sl.inspect)(p)}" was not provided.`,{nodes:t});continue}let y=f.value,g=y.kind===WF.Kind.NULL;if(y.kind===WF.Kind.VARIABLE){let P=y.name.value;if(n==null||!tw(n,P)){if(c.defaultValue!==void 0)i[l]=c.defaultValue;else if((0,ol.isNonNullType)(p))throw new fs.GraphQLError(`Argument "${l}" of required type "${(0,sl.inspect)(p)}" was provided the variable "$${P}" which was not provided a runtime value.`,{nodes:y});continue}g=n[P]==null}if(g&&(0,ol.isNonNullType)(p))throw new fs.GraphQLError(`Argument "${l}" of non-null type "${(0,sl.inspect)(p)}" must not be null.`,{nodes:y});let v=(0,ZF.valueFromAST)(y,p,n);if(v===void 0)throw new fs.GraphQLError(`Argument "${l}" has invalid value ${(0,XF.print)(y)}.`,{nodes:y});i[l]=v}return i}function $z(e,t,n){var r;let i=(r=t.directives)===null||r===void 0?void 0:r.find(a=>a.name.value===e.name);if(i)return ew(e,i,n)}function tw(e,t){return Object.prototype.hasOwnProperty.call(e,t)}});var oN=w(sN=>{"use strict";m();T();N();Object.defineProperty(sN,"__esModule",{value:!0});sN.collectFields=Jz;sN.collectSubfields=Hz;var wg=Pt(),Qz=Ft(),nw=Gr(),Yz=Aa(),rw=ul();function Jz(e,t,n,r,i){let a=new Map;return aN(e,t,n,r,i,a,new Set),a}function Hz(e,t,n,r,i){let a=new Map,o=new Set;for(let c of i)c.selectionSet&&aN(e,t,n,r,c.selectionSet,a,o);return a}function aN(e,t,n,r,i,a,o){for(let c of i.selections)switch(c.kind){case wg.Kind.FIELD:{if(!Lg(n,c))continue;let l=zz(c),p=a.get(l);p!==void 0?p.push(c):a.set(l,[c]);break}case wg.Kind.INLINE_FRAGMENT:{if(!Lg(n,c)||!iw(e,c,r))continue;aN(e,t,n,r,c.selectionSet,a,o);break}case wg.Kind.FRAGMENT_SPREAD:{let l=c.name.value;if(o.has(l)||!Lg(n,c))continue;o.add(l);let p=t[l];if(!p||!iw(e,p,r))continue;aN(e,t,n,r,p.selectionSet,a,o);break}}}function Lg(e,t){let n=(0,rw.getDirectiveValues)(nw.GraphQLSkipDirective,t,e);if((n==null?void 0:n.if)===!0)return!1;let r=(0,rw.getDirectiveValues)(nw.GraphQLIncludeDirective,t,e);return(r==null?void 0:r.if)!==!1}function iw(e,t,n){let r=t.typeCondition;if(!r)return!0;let i=(0,Yz.typeFromAST)(e,r);return i===n?!0:(0,Qz.isAbstractType)(i)?e.isSubType(i,n):!1}function zz(e){return e.alias?e.alias.value:e.name.value}});var Bg=w(Cg=>{"use strict";m();T();N();Object.defineProperty(Cg,"__esModule",{value:!0});Cg.SingleFieldSubscriptionsRule=Zz;var aw=He(),Wz=Pt(),Xz=oN();function Zz(e){return{OperationDefinition(t){if(t.operation==="subscription"){let n=e.getSchema(),r=n.getSubscriptionType();if(r){let i=t.name?t.name.value:null,a=Object.create(null),o=e.getDocument(),c=Object.create(null);for(let p of o.definitions)p.kind===Wz.Kind.FRAGMENT_DEFINITION&&(c[p.name.value]=p);let l=(0,Xz.collectFields)(n,c,a,r,t.selectionSet);if(l.size>1){let y=[...l.values()].slice(1).flat();e.reportError(new aw.GraphQLError(i!=null?`Subscription "${i}" must select only one top level field.`:"Anonymous Subscription must select only one top level field.",{nodes:y}))}for(let p of l.values())p[0].name.value.startsWith("__")&&e.reportError(new aw.GraphQLError(i!=null?`Subscription "${i}" must not select an introspection top level field.`:"Anonymous Subscription must not select an introspection top level field.",{nodes:p}))}}}}}});var uN=w(Ug=>{"use strict";m();T();N();Object.defineProperty(Ug,"__esModule",{value:!0});Ug.groupBy=e4;function e4(e,t){let n=new Map;for(let r of e){let i=t(r),a=n.get(i);a===void 0?n.set(i,[r]):a.push(r)}return n}});var Mg=w(kg=>{"use strict";m();T();N();Object.defineProperty(kg,"__esModule",{value:!0});kg.UniqueArgumentDefinitionNamesRule=r4;var t4=uN(),n4=He();function r4(e){return{DirectiveDefinition(r){var i;let a=(i=r.arguments)!==null&&i!==void 0?i:[];return n(`@${r.name.value}`,a)},InterfaceTypeDefinition:t,InterfaceTypeExtension:t,ObjectTypeDefinition:t,ObjectTypeExtension:t};function t(r){var i;let a=r.name.value,o=(i=r.fields)!==null&&i!==void 0?i:[];for(let l of o){var c;let p=l.name.value,f=(c=l.arguments)!==null&&c!==void 0?c:[];n(`${a}.${p}`,f)}return!1}function n(r,i){let a=(0,t4.groupBy)(i,o=>o.name.value);for(let[o,c]of a)c.length>1&&e.reportError(new n4.GraphQLError(`Argument "${r}(${o}:)" can only be defined once.`,{nodes:c.map(l=>l.name)}));return!1}}});var qg=w(xg=>{"use strict";m();T();N();Object.defineProperty(xg,"__esModule",{value:!0});xg.UniqueArgumentNamesRule=s4;var i4=uN(),a4=He();function s4(e){return{Field:t,Directive:t};function t(n){var r;let i=(r=n.arguments)!==null&&r!==void 0?r:[],a=(0,i4.groupBy)(i,o=>o.name.value);for(let[o,c]of a)c.length>1&&e.reportError(new a4.GraphQLError(`There can be only one argument named "${o}".`,{nodes:c.map(l=>l.name)}))}}});var jg=w(Vg=>{"use strict";m();T();N();Object.defineProperty(Vg,"__esModule",{value:!0});Vg.UniqueDirectiveNamesRule=o4;var sw=He();function o4(e){let t=Object.create(null),n=e.getSchema();return{DirectiveDefinition(r){let i=r.name.value;if(n!=null&&n.getDirective(i)){e.reportError(new sw.GraphQLError(`Directive "@${i}" already exists in the schema. It cannot be redefined.`,{nodes:r.name}));return}return t[i]?e.reportError(new sw.GraphQLError(`There can be only one directive named "@${i}".`,{nodes:[t[i],r.name]})):t[i]=r.name,!1}}}});var $g=w(Gg=>{"use strict";m();T();N();Object.defineProperty(Gg,"__esModule",{value:!0});Gg.UniqueDirectivesPerLocationRule=l4;var u4=He(),Kg=Pt(),ow=zu(),c4=Gr();function l4(e){let t=Object.create(null),n=e.getSchema(),r=n?n.getDirectives():c4.specifiedDirectives;for(let c of r)t[c.name]=!c.isRepeatable;let i=e.getDocument().definitions;for(let c of i)c.kind===Kg.Kind.DIRECTIVE_DEFINITION&&(t[c.name.value]=!c.repeatable);let a=Object.create(null),o=Object.create(null);return{enter(c){if(!("directives"in c)||!c.directives)return;let l;if(c.kind===Kg.Kind.SCHEMA_DEFINITION||c.kind===Kg.Kind.SCHEMA_EXTENSION)l=a;else if((0,ow.isTypeDefinitionNode)(c)||(0,ow.isTypeExtensionNode)(c)){let p=c.name.value;l=o[p],l===void 0&&(o[p]=l=Object.create(null))}else l=Object.create(null);for(let p of c.directives){let f=p.name.value;t[f]&&(l[f]?e.reportError(new u4.GraphQLError(`The directive "@${f}" can only be used once at this location.`,{nodes:[l[f],p]})):l[f]=p)}}}}});var Yg=w(Qg=>{"use strict";m();T();N();Object.defineProperty(Qg,"__esModule",{value:!0});Qg.UniqueEnumValueNamesRule=p4;var uw=He(),d4=Ft();function p4(e){let t=e.getSchema(),n=t?t.getTypeMap():Object.create(null),r=Object.create(null);return{EnumTypeDefinition:i,EnumTypeExtension:i};function i(a){var o;let c=a.name.value;r[c]||(r[c]=Object.create(null));let l=(o=a.values)!==null&&o!==void 0?o:[],p=r[c];for(let f of l){let y=f.name.value,g=n[c];(0,d4.isEnumType)(g)&&g.getValue(y)?e.reportError(new uw.GraphQLError(`Enum value "${c}.${y}" already exists in the schema. It cannot also be defined in this type extension.`,{nodes:f.name})):p[y]?e.reportError(new uw.GraphQLError(`Enum value "${c}.${y}" can only be defined once.`,{nodes:[p[y],f.name]})):p[y]=f.name}return!1}}});var zg=w(Hg=>{"use strict";m();T();N();Object.defineProperty(Hg,"__esModule",{value:!0});Hg.UniqueFieldDefinitionNamesRule=f4;var cw=He(),Jg=Ft();function f4(e){let t=e.getSchema(),n=t?t.getTypeMap():Object.create(null),r=Object.create(null);return{InputObjectTypeDefinition:i,InputObjectTypeExtension:i,InterfaceTypeDefinition:i,InterfaceTypeExtension:i,ObjectTypeDefinition:i,ObjectTypeExtension:i};function i(a){var o;let c=a.name.value;r[c]||(r[c]=Object.create(null));let l=(o=a.fields)!==null&&o!==void 0?o:[],p=r[c];for(let f of l){let y=f.name.value;m4(n[c],y)?e.reportError(new cw.GraphQLError(`Field "${c}.${y}" already exists in the schema. It cannot also be defined in this type extension.`,{nodes:f.name})):p[y]?e.reportError(new cw.GraphQLError(`Field "${c}.${y}" can only be defined once.`,{nodes:[p[y],f.name]})):p[y]=f.name}return!1}}function m4(e,t){return(0,Jg.isObjectType)(e)||(0,Jg.isInterfaceType)(e)||(0,Jg.isInputObjectType)(e)?e.getFields()[t]!=null:!1}});var Xg=w(Wg=>{"use strict";m();T();N();Object.defineProperty(Wg,"__esModule",{value:!0});Wg.UniqueFragmentNamesRule=T4;var N4=He();function T4(e){let t=Object.create(null);return{OperationDefinition:()=>!1,FragmentDefinition(n){let r=n.name.value;return t[r]?e.reportError(new N4.GraphQLError(`There can be only one fragment named "${r}".`,{nodes:[t[r],n.name]})):t[r]=n.name,!1}}}});var e_=w(Zg=>{"use strict";m();T();N();Object.defineProperty(Zg,"__esModule",{value:!0});Zg.UniqueInputFieldNamesRule=y4;var E4=yr(),h4=He();function y4(e){let t=[],n=Object.create(null);return{ObjectValue:{enter(){t.push(n),n=Object.create(null)},leave(){let r=t.pop();r||(0,E4.invariant)(!1),n=r}},ObjectField(r){let i=r.name.value;n[i]?e.reportError(new h4.GraphQLError(`There can be only one input field named "${i}".`,{nodes:[n[i],r.name]})):n[i]=r.name}}}});var n_=w(t_=>{"use strict";m();T();N();Object.defineProperty(t_,"__esModule",{value:!0});t_.UniqueOperationNamesRule=g4;var I4=He();function g4(e){let t=Object.create(null);return{OperationDefinition(n){let r=n.name;return r&&(t[r.value]?e.reportError(new I4.GraphQLError(`There can be only one operation named "${r.value}".`,{nodes:[t[r.value],r]})):t[r.value]=r),!1},FragmentDefinition:()=>!1}}});var i_=w(r_=>{"use strict";m();T();N();Object.defineProperty(r_,"__esModule",{value:!0});r_.UniqueOperationTypesRule=_4;var lw=He();function _4(e){let t=e.getSchema(),n=Object.create(null),r=t?{query:t.getQueryType(),mutation:t.getMutationType(),subscription:t.getSubscriptionType()}:{};return{SchemaDefinition:i,SchemaExtension:i};function i(a){var o;let c=(o=a.operationTypes)!==null&&o!==void 0?o:[];for(let l of c){let p=l.operation,f=n[p];r[p]?e.reportError(new lw.GraphQLError(`Type for ${p} already defined in the schema. It cannot be redefined.`,{nodes:l})):f?e.reportError(new lw.GraphQLError(`There can be only one ${p} type in schema.`,{nodes:[f,l]})):n[p]=l}return!1}}});var s_=w(a_=>{"use strict";m();T();N();Object.defineProperty(a_,"__esModule",{value:!0});a_.UniqueTypeNamesRule=v4;var dw=He();function v4(e){let t=Object.create(null),n=e.getSchema();return{ScalarTypeDefinition:r,ObjectTypeDefinition:r,InterfaceTypeDefinition:r,UnionTypeDefinition:r,EnumTypeDefinition:r,InputObjectTypeDefinition:r};function r(i){let a=i.name.value;if(n!=null&&n.getType(a)){e.reportError(new dw.GraphQLError(`Type "${a}" already exists in the schema. It cannot also be defined in this type definition.`,{nodes:i.name}));return}return t[a]?e.reportError(new dw.GraphQLError(`There can be only one type named "${a}".`,{nodes:[t[a],i.name]})):t[a]=i.name,!1}}});var u_=w(o_=>{"use strict";m();T();N();Object.defineProperty(o_,"__esModule",{value:!0});o_.UniqueVariableNamesRule=D4;var S4=uN(),O4=He();function D4(e){return{OperationDefinition(t){var n;let r=(n=t.variableDefinitions)!==null&&n!==void 0?n:[],i=(0,S4.groupBy)(r,a=>a.variable.name.value);for(let[a,o]of i)o.length>1&&e.reportError(new O4.GraphQLError(`There can be only one variable named "$${a}".`,{nodes:o.map(c=>c.variable.name)}))}}}});var d_=w(l_=>{"use strict";m();T();N();Object.defineProperty(l_,"__esModule",{value:!0});l_.ValuesOfCorrectTypeRule=P4;var b4=zo(),ap=Yt(),A4=Wo(),R4=Xo(),Pa=He(),c_=Pt(),cN=ci(),Ra=Ft();function P4(e){let t={};return{OperationDefinition:{enter(){t={}}},VariableDefinition(n){t[n.variable.name.value]=n},ListValue(n){let r=(0,Ra.getNullableType)(e.getParentInputType());if(!(0,Ra.isListType)(r))return Xu(e,n),!1},ObjectValue(n){let r=(0,Ra.getNamedType)(e.getInputType());if(!(0,Ra.isInputObjectType)(r))return Xu(e,n),!1;let i=(0,A4.keyMap)(n.fields,a=>a.name.value);for(let a of Object.values(r.getFields()))if(!i[a.name]&&(0,Ra.isRequiredInputField)(a)){let c=(0,ap.inspect)(a.type);e.reportError(new Pa.GraphQLError(`Field "${r.name}.${a.name}" of required type "${c}" was not provided.`,{nodes:n}))}r.isOneOf&&F4(e,n,r,i,t)},ObjectField(n){let r=(0,Ra.getNamedType)(e.getParentInputType());if(!e.getInputType()&&(0,Ra.isInputObjectType)(r)){let a=(0,R4.suggestionList)(n.name.value,Object.keys(r.getFields()));e.reportError(new Pa.GraphQLError(`Field "${n.name.value}" is not defined by type "${r.name}".`+(0,b4.didYouMean)(a),{nodes:n}))}},NullValue(n){let r=e.getInputType();(0,Ra.isNonNullType)(r)&&e.reportError(new Pa.GraphQLError(`Expected value of type "${(0,ap.inspect)(r)}", found ${(0,cN.print)(n)}.`,{nodes:n}))},EnumValue:n=>Xu(e,n),IntValue:n=>Xu(e,n),FloatValue:n=>Xu(e,n),StringValue:n=>Xu(e,n),BooleanValue:n=>Xu(e,n)}}function Xu(e,t){let n=e.getInputType();if(!n)return;let r=(0,Ra.getNamedType)(n);if(!(0,Ra.isLeafType)(r)){let i=(0,ap.inspect)(n);e.reportError(new Pa.GraphQLError(`Expected value of type "${i}", found ${(0,cN.print)(t)}.`,{nodes:t}));return}try{if(r.parseLiteral(t,void 0)===void 0){let a=(0,ap.inspect)(n);e.reportError(new Pa.GraphQLError(`Expected value of type "${a}", found ${(0,cN.print)(t)}.`,{nodes:t}))}}catch(i){let a=(0,ap.inspect)(n);i instanceof Pa.GraphQLError?e.reportError(i):e.reportError(new Pa.GraphQLError(`Expected value of type "${a}", found ${(0,cN.print)(t)}; `+i.message,{nodes:t,originalError:i}))}}function F4(e,t,n,r,i){var a;let o=Object.keys(r);if(o.length!==1){e.reportError(new Pa.GraphQLError(`OneOf Input Object "${n.name}" must specify exactly one key.`,{nodes:[t]}));return}let l=(a=r[o[0]])===null||a===void 0?void 0:a.value,p=!l||l.kind===c_.Kind.NULL,f=(l==null?void 0:l.kind)===c_.Kind.VARIABLE;if(p){e.reportError(new Pa.GraphQLError(`Field "${n.name}.${o[0]}" must be non-null.`,{nodes:[t]}));return}if(f){let y=l.name.value;i[y].type.kind!==c_.Kind.NON_NULL_TYPE&&e.reportError(new Pa.GraphQLError(`Variable "${y}" must be non-nullable to be used for OneOf Input Object "${n.name}".`,{nodes:[t]}))}}});var f_=w(p_=>{"use strict";m();T();N();Object.defineProperty(p_,"__esModule",{value:!0});p_.VariablesAreInputTypesRule=U4;var w4=He(),L4=ci(),C4=Ft(),B4=Aa();function U4(e){return{VariableDefinition(t){let n=(0,B4.typeFromAST)(e.getSchema(),t.type);if(n!==void 0&&!(0,C4.isInputType)(n)){let r=t.variable.name.value,i=(0,L4.print)(t.type);e.reportError(new w4.GraphQLError(`Variable "$${r}" cannot be non-input type "${i}".`,{nodes:t.type}))}}}}});var N_=w(m_=>{"use strict";m();T();N();Object.defineProperty(m_,"__esModule",{value:!0});m_.VariablesInAllowedPositionRule=q4;var pw=Yt(),k4=He(),M4=Pt(),fw=Ft(),mw=qd(),x4=Aa();function q4(e){let t=Object.create(null);return{OperationDefinition:{enter(){t=Object.create(null)},leave(n){let r=e.getRecursiveVariableUsages(n);for(let{node:i,type:a,defaultValue:o}of r){let c=i.name.value,l=t[c];if(l&&a){let p=e.getSchema(),f=(0,x4.typeFromAST)(p,l.type);if(f&&!V4(p,f,l.defaultValue,a,o)){let y=(0,pw.inspect)(f),g=(0,pw.inspect)(a);e.reportError(new k4.GraphQLError(`Variable "$${c}" of type "${y}" used in position expecting type "${g}".`,{nodes:[l,i]}))}}}}},VariableDefinition(n){t[n.variable.name.value]=n}}}function V4(e,t,n,r,i){if((0,fw.isNonNullType)(r)&&!(0,fw.isNonNullType)(t)){if(!(n!=null&&n.kind!==M4.Kind.NULL)&&!(i!==void 0))return!1;let c=r.ofType;return(0,mw.isTypeSubTypeOf)(e,t,c)}return(0,mw.isTypeSubTypeOf)(e,t,r)}});var T_=w(nu=>{"use strict";m();T();N();Object.defineProperty(nu,"__esModule",{value:!0});nu.specifiedSDLRules=nu.specifiedRules=nu.recommendedRules=void 0;var j4=LI(),K4=BI(),G4=kI(),Nw=MI(),Tw=jI(),$4=GI(),Ew=YI(),Q4=HI(),Y4=WI(),J4=ZI(),H4=tg(),z4=rg(),W4=ag(),X4=og(),Z4=Eg(),eW=Ig(),tW=_g(),hw=Sg(),nW=Dg(),rW=Bg(),iW=Mg(),yw=qg(),aW=jg(),Iw=$g(),sW=Yg(),oW=zg(),uW=Xg(),gw=e_(),cW=n_(),lW=i_(),dW=s_(),pW=u_(),fW=d_(),mW=f_(),NW=N_(),_w=Object.freeze([J4.MaxIntrospectionDepthRule]);nu.recommendedRules=_w;var TW=Object.freeze([j4.ExecutableDefinitionsRule,cW.UniqueOperationNamesRule,Q4.LoneAnonymousOperationRule,rW.SingleFieldSubscriptionsRule,Ew.KnownTypeNamesRule,G4.FragmentsOnCompositeTypesRule,mW.VariablesAreInputTypesRule,nW.ScalarLeafsRule,K4.FieldsOnCorrectTypeRule,uW.UniqueFragmentNamesRule,$4.KnownFragmentNamesRule,W4.NoUnusedFragmentsRule,eW.PossibleFragmentSpreadsRule,H4.NoFragmentCyclesRule,pW.UniqueVariableNamesRule,z4.NoUndefinedVariablesRule,X4.NoUnusedVariablesRule,Tw.KnownDirectivesRule,Iw.UniqueDirectivesPerLocationRule,Nw.KnownArgumentNamesRule,yw.UniqueArgumentNamesRule,fW.ValuesOfCorrectTypeRule,hw.ProvidedRequiredArgumentsRule,NW.VariablesInAllowedPositionRule,Z4.OverlappingFieldsCanBeMergedRule,gw.UniqueInputFieldNamesRule,..._w]);nu.specifiedRules=TW;var EW=Object.freeze([Y4.LoneSchemaDefinitionRule,lW.UniqueOperationTypesRule,dW.UniqueTypeNamesRule,sW.UniqueEnumValueNamesRule,oW.UniqueFieldDefinitionNamesRule,iW.UniqueArgumentDefinitionNamesRule,aW.UniqueDirectiveNamesRule,Ew.KnownTypeNamesRule,Tw.KnownDirectivesRule,Iw.UniqueDirectivesPerLocationRule,tW.PossibleTypeExtensionsRule,Nw.KnownArgumentNamesOnDirectivesRule,yw.UniqueArgumentNamesRule,gw.UniqueInputFieldNamesRule,hw.ProvidedRequiredArgumentsOnDirectivesRule]);nu.specifiedSDLRules=EW});var y_=w(ru=>{"use strict";m();T();N();Object.defineProperty(ru,"__esModule",{value:!0});ru.ValidationContext=ru.SDLValidationContext=ru.ASTValidationContext=void 0;var vw=Pt(),hW=ju(),Sw=zm(),sp=class{constructor(t,n){this._ast=t,this._fragments=void 0,this._fragmentSpreads=new Map,this._recursivelyReferencedFragments=new Map,this._onError=n}get[Symbol.toStringTag](){return"ASTValidationContext"}reportError(t){this._onError(t)}getDocument(){return this._ast}getFragment(t){let n;if(this._fragments)n=this._fragments;else{n=Object.create(null);for(let r of this.getDocument().definitions)r.kind===vw.Kind.FRAGMENT_DEFINITION&&(n[r.name.value]=r);this._fragments=n}return n[t]}getFragmentSpreads(t){let n=this._fragmentSpreads.get(t);if(!n){n=[];let r=[t],i;for(;i=r.pop();)for(let a of i.selections)a.kind===vw.Kind.FRAGMENT_SPREAD?n.push(a):a.selectionSet&&r.push(a.selectionSet);this._fragmentSpreads.set(t,n)}return n}getRecursivelyReferencedFragments(t){let n=this._recursivelyReferencedFragments.get(t);if(!n){n=[];let r=Object.create(null),i=[t.selectionSet],a;for(;a=i.pop();)for(let o of this.getFragmentSpreads(a)){let c=o.name.value;if(r[c]!==!0){r[c]=!0;let l=this.getFragment(c);l&&(n.push(l),i.push(l.selectionSet))}}this._recursivelyReferencedFragments.set(t,n)}return n}};ru.ASTValidationContext=sp;var E_=class extends sp{constructor(t,n,r){super(t,r),this._schema=n}get[Symbol.toStringTag](){return"SDLValidationContext"}getSchema(){return this._schema}};ru.SDLValidationContext=E_;var h_=class extends sp{constructor(t,n,r,i){super(n,i),this._schema=t,this._typeInfo=r,this._variableUsages=new Map,this._recursiveVariableUsages=new Map}get[Symbol.toStringTag](){return"ValidationContext"}getSchema(){return this._schema}getVariableUsages(t){let n=this._variableUsages.get(t);if(!n){let r=[],i=new Sw.TypeInfo(this._schema);(0,hW.visit)(t,(0,Sw.visitWithTypeInfo)(i,{VariableDefinition:()=>!1,Variable(a){r.push({node:a,type:i.getInputType(),defaultValue:i.getDefaultValue()})}})),n=r,this._variableUsages.set(t,n)}return n}getRecursiveVariableUsages(t){let n=this._recursiveVariableUsages.get(t);if(!n){n=this.getVariableUsages(t);for(let r of this.getRecursivelyReferencedFragments(t))n=n.concat(this.getVariableUsages(r));this._recursiveVariableUsages.set(t,n)}return n}getType(){return this._typeInfo.getType()}getParentType(){return this._typeInfo.getParentType()}getInputType(){return this._typeInfo.getInputType()}getParentInputType(){return this._typeInfo.getParentInputType()}getFieldDef(){return this._typeInfo.getFieldDef()}getDirective(){return this._typeInfo.getDirective()}getArgument(){return this._typeInfo.getArgument()}getEnumValue(){return this._typeInfo.getEnumValue()}};ru.ValidationContext=h_});var ll=w(cl=>{"use strict";m();T();N();Object.defineProperty(cl,"__esModule",{value:!0});cl.assertValidSDL=vW;cl.assertValidSDLExtension=SW;cl.validate=_W;cl.validateSDL=I_;var yW=Lr(),IW=He(),lN=ju(),gW=zd(),Ow=zm(),Dw=T_(),bw=y_();function _W(e,t,n=Dw.specifiedRules,r,i=new Ow.TypeInfo(e)){var a;let o=(a=r==null?void 0:r.maxErrors)!==null&&a!==void 0?a:100;t||(0,yW.devAssert)(!1,"Must provide document."),(0,gW.assertValidSchema)(e);let c=Object.freeze({}),l=[],p=new bw.ValidationContext(e,t,i,y=>{if(l.length>=o)throw l.push(new IW.GraphQLError("Too many validation errors, error limit reached. Validation aborted.")),c;l.push(y)}),f=(0,lN.visitInParallel)(n.map(y=>y(p)));try{(0,lN.visit)(t,(0,Ow.visitWithTypeInfo)(i,f))}catch(y){if(y!==c)throw y}return l}function I_(e,t,n=Dw.specifiedSDLRules){let r=[],i=new bw.SDLValidationContext(e,t,o=>{r.push(o)}),a=n.map(o=>o(i));return(0,lN.visit)(e,(0,lN.visitInParallel)(a)),r}function vW(e){let t=I_(e);if(t.length!==0)throw new Error(t.map(n=>n.message).join(` `))}function SW(e,t){let n=I_(e,t);if(n.length!==0)throw new Error(n.map(r=>r.message).join(` -`))}});var Aw=w(g_=>{"use strict";m();T();N();Object.defineProperty(g_,"__esModule",{value:!0});g_.memoize3=OW;function OW(e){let t;return function(r,i,a){t===void 0&&(t=new WeakMap);let o=t.get(r);o===void 0&&(o=new WeakMap,t.set(r,o));let c=o.get(i);c===void 0&&(c=new WeakMap,o.set(i,c));let l=c.get(a);return l===void 0&&(l=e(r,i,a),c.set(a,l)),l}}});var Rw=w(__=>{"use strict";m();T();N();Object.defineProperty(__,"__esModule",{value:!0});__.promiseForObject=DW;function DW(e){return Promise.all(Object.values(e)).then(t=>{let n=Object.create(null);for(let[r,i]of Object.keys(e).entries())n[i]=t[r];return n})}});var Pw=w(v_=>{"use strict";m();T();N();Object.defineProperty(v_,"__esModule",{value:!0});v_.promiseReduce=AW;var bW=pm();function AW(e,t,n){let r=n;for(let i of e)r=(0,bW.isPromise)(r)?r.then(a=>t(a,i)):t(r,i);return r}});var Fw=w(O_=>{"use strict";m();T();N();Object.defineProperty(O_,"__esModule",{value:!0});O_.toError=PW;var RW=Yt();function PW(e){return e instanceof Error?e:new S_(e)}var S_=class extends Error{constructor(t){super("Unexpected error value: "+(0,RW.inspect)(t)),this.name="NonErrorThrown",this.thrownValue=t}}});var dN=w(D_=>{"use strict";m();T();N();Object.defineProperty(D_,"__esModule",{value:!0});D_.locatedError=LW;var FW=Fw(),wW=He();function LW(e,t,n){var r;let i=(0,FW.toError)(e);return CW(i)?i:new wW.GraphQLError(i.message,{nodes:(r=i.nodes)!==null&&r!==void 0?r:t,source:i.source,positions:i.positions,path:n,originalError:i})}function CW(e){return Array.isArray(e.path)}});var up=w(Fi=>{"use strict";m();T();N();Object.defineProperty(Fi,"__esModule",{value:!0});Fi.assertValidExecutionArguments=xw;Fi.buildExecutionContext=qw;Fi.buildResolveInfo=jw;Fi.defaultTypeResolver=Fi.defaultFieldResolver=void 0;Fi.execute=Mw;Fi.executeSync=VW;Fi.getFieldDef=Gw;var A_=Lr(),Zu=Yt(),BW=yr(),UW=Qm(),F_=va(),ta=pm(),kW=Aw(),ec=Zd(),ww=Rw(),MW=Pw(),Pi=He(),fN=dN(),b_=Sa(),Lw=Pt(),iu=Ft(),dl=Ai(),xW=zd(),Uw=oN(),kw=ul(),qW=(0,kW.memoize3)((e,t,n)=>(0,Uw.collectSubfields)(e.schema,e.fragments,e.variableValues,t,n));function Mw(e){arguments.length<2||(0,A_.devAssert)(!1,"graphql@16 dropped long-deprecated support for positional arguments, please pass an object instead.");let{schema:t,document:n,variableValues:r,rootValue:i}=e;xw(t,n,r);let a=qw(e);if(!("schema"in a))return{errors:a};try{let{operation:o}=a,c=jW(a,o,i);return(0,ta.isPromise)(c)?c.then(l=>pN(l,a.errors),l=>(a.errors.push(l),pN(null,a.errors))):pN(c,a.errors)}catch(o){return a.errors.push(o),pN(null,a.errors)}}function VW(e){let t=Mw(e);if((0,ta.isPromise)(t))throw new Error("GraphQL execution failed to complete synchronously.");return t}function pN(e,t){return t.length===0?{data:e}:{errors:t,data:e}}function xw(e,t,n){t||(0,A_.devAssert)(!1,"Must provide document."),(0,xW.assertValidSchema)(e),n==null||(0,F_.isObjectLike)(n)||(0,A_.devAssert)(!1,"Variables must be provided as an Object where each property is a variable value. Perhaps look to see if an unparsed JSON string was provided.")}function qw(e){var t,n;let{schema:r,document:i,rootValue:a,contextValue:o,variableValues:c,operationName:l,fieldResolver:p,typeResolver:f,subscribeFieldResolver:y}=e,g,v=Object.create(null);for(let K of i.definitions)switch(K.kind){case Lw.Kind.OPERATION_DEFINITION:if(l==null){if(g!==void 0)return[new Pi.GraphQLError("Must provide operation name if query contains multiple operations.")];g=K}else((t=K.name)===null||t===void 0?void 0:t.value)===l&&(g=K);break;case Lw.Kind.FRAGMENT_DEFINITION:v[K.name.value]=K;break;default:}if(!g)return l!=null?[new Pi.GraphQLError(`Unknown operation named "${l}".`)]:[new Pi.GraphQLError("Must provide an operation.")];let F=(n=g.variableDefinitions)!==null&&n!==void 0?n:[],k=(0,kw.getVariableValues)(r,F,c!=null?c:{},{maxErrors:50});return k.errors?k.errors:{schema:r,fragments:v,rootValue:a,contextValue:o,operation:g,variableValues:k.coerced,fieldResolver:p!=null?p:P_,typeResolver:f!=null?f:Kw,subscribeFieldResolver:y!=null?y:P_,errors:[]}}function jW(e,t,n){let r=e.schema.getRootType(t.operation);if(r==null)throw new Pi.GraphQLError(`Schema is not configured to execute ${t.operation} operation.`,{nodes:t});let i=(0,Uw.collectFields)(e.schema,e.fragments,e.variableValues,r,t.selectionSet),a=void 0;switch(t.operation){case b_.OperationTypeNode.QUERY:return mN(e,r,n,a,i);case b_.OperationTypeNode.MUTATION:return KW(e,r,n,a,i);case b_.OperationTypeNode.SUBSCRIPTION:return mN(e,r,n,a,i)}}function KW(e,t,n,r,i){return(0,MW.promiseReduce)(i.entries(),(a,[o,c])=>{let l=(0,ec.addPath)(r,o,t.name),p=Vw(e,t,n,c,l);return p===void 0?a:(0,ta.isPromise)(p)?p.then(f=>(a[o]=f,a)):(a[o]=p,a)},Object.create(null))}function mN(e,t,n,r,i){let a=Object.create(null),o=!1;try{for(let[c,l]of i.entries()){let p=(0,ec.addPath)(r,c,t.name),f=Vw(e,t,n,l,p);f!==void 0&&(a[c]=f,(0,ta.isPromise)(f)&&(o=!0))}}catch(c){if(o)return(0,ww.promiseForObject)(a).finally(()=>{throw c});throw c}return o?(0,ww.promiseForObject)(a):a}function Vw(e,t,n,r,i){var a;let o=Gw(e.schema,t,r[0]);if(!o)return;let c=o.type,l=(a=o.resolve)!==null&&a!==void 0?a:e.fieldResolver,p=jw(e,o,r,t,i);try{let f=(0,kw.getArgumentValues)(o,r[0],e.variableValues),y=e.contextValue,g=l(n,f,y,p),v;return(0,ta.isPromise)(g)?v=g.then(F=>op(e,c,r,p,i,F)):v=op(e,c,r,p,i,g),(0,ta.isPromise)(v)?v.then(void 0,F=>{let k=(0,fN.locatedError)(F,r,(0,ec.pathToArray)(i));return NN(k,c,e)}):v}catch(f){let y=(0,fN.locatedError)(f,r,(0,ec.pathToArray)(i));return NN(y,c,e)}}function jw(e,t,n,r,i){return{fieldName:t.name,fieldNodes:n,returnType:t.type,parentType:r,path:i,schema:e.schema,fragments:e.fragments,rootValue:e.rootValue,operation:e.operation,variableValues:e.variableValues}}function NN(e,t,n){if((0,iu.isNonNullType)(t))throw e;return n.errors.push(e),null}function op(e,t,n,r,i,a){if(a instanceof Error)throw a;if((0,iu.isNonNullType)(t)){let o=op(e,t.ofType,n,r,i,a);if(o===null)throw new Error(`Cannot return null for non-nullable field ${r.parentType.name}.${r.fieldName}.`);return o}if(a==null)return null;if((0,iu.isListType)(t))return GW(e,t,n,r,i,a);if((0,iu.isLeafType)(t))return $W(t,a);if((0,iu.isAbstractType)(t))return QW(e,t,n,r,i,a);if((0,iu.isObjectType)(t))return R_(e,t,n,r,i,a);(0,BW.invariant)(!1,"Cannot complete value of unexpected output type: "+(0,Zu.inspect)(t))}function GW(e,t,n,r,i,a){if(!(0,UW.isIterableObject)(a))throw new Pi.GraphQLError(`Expected Iterable, but did not find one for field "${r.parentType.name}.${r.fieldName}".`);let o=t.ofType,c=!1,l=Array.from(a,(p,f)=>{let y=(0,ec.addPath)(i,f,void 0);try{let g;return(0,ta.isPromise)(p)?g=p.then(v=>op(e,o,n,r,y,v)):g=op(e,o,n,r,y,p),(0,ta.isPromise)(g)?(c=!0,g.then(void 0,v=>{let F=(0,fN.locatedError)(v,n,(0,ec.pathToArray)(y));return NN(F,o,e)})):g}catch(g){let v=(0,fN.locatedError)(g,n,(0,ec.pathToArray)(y));return NN(v,o,e)}});return c?Promise.all(l):l}function $W(e,t){let n=e.serialize(t);if(n==null)throw new Error(`Expected \`${(0,Zu.inspect)(e)}.serialize(${(0,Zu.inspect)(t)})\` to return non-nullable value, returned: ${(0,Zu.inspect)(n)}`);return n}function QW(e,t,n,r,i,a){var o;let c=(o=t.resolveType)!==null&&o!==void 0?o:e.typeResolver,l=e.contextValue,p=c(a,l,r,t);return(0,ta.isPromise)(p)?p.then(f=>R_(e,Cw(f,e,t,n,r,a),n,r,i,a)):R_(e,Cw(p,e,t,n,r,a),n,r,i,a)}function Cw(e,t,n,r,i,a){if(e==null)throw new Pi.GraphQLError(`Abstract type "${n.name}" must resolve to an Object type at runtime for field "${i.parentType.name}.${i.fieldName}". Either the "${n.name}" type should provide a "resolveType" function or each possible type should provide an "isTypeOf" function.`,r);if((0,iu.isObjectType)(e))throw new Pi.GraphQLError("Support for returning GraphQLObjectType from resolveType was removed in graphql-js@16.0.0 please return type name instead.");if(typeof e!="string")throw new Pi.GraphQLError(`Abstract type "${n.name}" must resolve to an Object type at runtime for field "${i.parentType.name}.${i.fieldName}" with value ${(0,Zu.inspect)(a)}, received "${(0,Zu.inspect)(e)}".`);let o=t.schema.getType(e);if(o==null)throw new Pi.GraphQLError(`Abstract type "${n.name}" was resolved to a type "${e}" that does not exist inside the schema.`,{nodes:r});if(!(0,iu.isObjectType)(o))throw new Pi.GraphQLError(`Abstract type "${n.name}" was resolved to a non-object type "${e}".`,{nodes:r});if(!t.schema.isSubType(n,o))throw new Pi.GraphQLError(`Runtime Object type "${o.name}" is not a possible type for "${n.name}".`,{nodes:r});return o}function R_(e,t,n,r,i,a){let o=qW(e,t,n);if(t.isTypeOf){let c=t.isTypeOf(a,e.contextValue,r);if((0,ta.isPromise)(c))return c.then(l=>{if(!l)throw Bw(t,a,n);return mN(e,t,a,i,o)});if(!c)throw Bw(t,a,n)}return mN(e,t,a,i,o)}function Bw(e,t,n){return new Pi.GraphQLError(`Expected value of type "${e.name}" but got: ${(0,Zu.inspect)(t)}.`,{nodes:n})}var Kw=function(e,t,n,r){if((0,F_.isObjectLike)(e)&&typeof e.__typename=="string")return e.__typename;let i=n.schema.getPossibleTypes(r),a=[];for(let o=0;o{for(let c=0;c{"use strict";m();T();N();Object.defineProperty(TN,"__esModule",{value:!0});TN.graphql=ZW;TN.graphqlSync=e8;var YW=Lr(),JW=pm(),HW=Xc(),zW=zd(),WW=ll(),XW=up();function ZW(e){return new Promise(t=>t($w(e)))}function e8(e){let t=$w(e);if((0,JW.isPromise)(t))throw new Error("GraphQL execution failed to complete synchronously.");return t}function $w(e){arguments.length<2||(0,YW.devAssert)(!1,"graphql@16 dropped long-deprecated support for positional arguments, please pass an object instead.");let{schema:t,source:n,rootValue:r,contextValue:i,variableValues:a,operationName:o,fieldResolver:c,typeResolver:l}=e,p=(0,zW.validateSchema)(t);if(p.length>0)return{errors:p};let f;try{f=(0,HW.parse)(n)}catch(g){return{errors:[g]}}let y=(0,WW.validate)(t,f);return y.length>0?{errors:y}:(0,XW.execute)({schema:t,document:f,rootValue:r,contextValue:i,variableValues:a,operationName:o,fieldResolver:c,typeResolver:l})}});var Hw=w(ye=>{"use strict";m();T();N();Object.defineProperty(ye,"__esModule",{value:!0});Object.defineProperty(ye,"DEFAULT_DEPRECATION_REASON",{enumerable:!0,get:function(){return na.DEFAULT_DEPRECATION_REASON}});Object.defineProperty(ye,"GRAPHQL_MAX_INT",{enumerable:!0,get:function(){return ms.GRAPHQL_MAX_INT}});Object.defineProperty(ye,"GRAPHQL_MIN_INT",{enumerable:!0,get:function(){return ms.GRAPHQL_MIN_INT}});Object.defineProperty(ye,"GraphQLBoolean",{enumerable:!0,get:function(){return ms.GraphQLBoolean}});Object.defineProperty(ye,"GraphQLDeprecatedDirective",{enumerable:!0,get:function(){return na.GraphQLDeprecatedDirective}});Object.defineProperty(ye,"GraphQLDirective",{enumerable:!0,get:function(){return na.GraphQLDirective}});Object.defineProperty(ye,"GraphQLEnumType",{enumerable:!0,get:function(){return nt.GraphQLEnumType}});Object.defineProperty(ye,"GraphQLFloat",{enumerable:!0,get:function(){return ms.GraphQLFloat}});Object.defineProperty(ye,"GraphQLID",{enumerable:!0,get:function(){return ms.GraphQLID}});Object.defineProperty(ye,"GraphQLIncludeDirective",{enumerable:!0,get:function(){return na.GraphQLIncludeDirective}});Object.defineProperty(ye,"GraphQLInputObjectType",{enumerable:!0,get:function(){return nt.GraphQLInputObjectType}});Object.defineProperty(ye,"GraphQLInt",{enumerable:!0,get:function(){return ms.GraphQLInt}});Object.defineProperty(ye,"GraphQLInterfaceType",{enumerable:!0,get:function(){return nt.GraphQLInterfaceType}});Object.defineProperty(ye,"GraphQLList",{enumerable:!0,get:function(){return nt.GraphQLList}});Object.defineProperty(ye,"GraphQLNonNull",{enumerable:!0,get:function(){return nt.GraphQLNonNull}});Object.defineProperty(ye,"GraphQLObjectType",{enumerable:!0,get:function(){return nt.GraphQLObjectType}});Object.defineProperty(ye,"GraphQLOneOfDirective",{enumerable:!0,get:function(){return na.GraphQLOneOfDirective}});Object.defineProperty(ye,"GraphQLScalarType",{enumerable:!0,get:function(){return nt.GraphQLScalarType}});Object.defineProperty(ye,"GraphQLSchema",{enumerable:!0,get:function(){return w_.GraphQLSchema}});Object.defineProperty(ye,"GraphQLSkipDirective",{enumerable:!0,get:function(){return na.GraphQLSkipDirective}});Object.defineProperty(ye,"GraphQLSpecifiedByDirective",{enumerable:!0,get:function(){return na.GraphQLSpecifiedByDirective}});Object.defineProperty(ye,"GraphQLString",{enumerable:!0,get:function(){return ms.GraphQLString}});Object.defineProperty(ye,"GraphQLUnionType",{enumerable:!0,get:function(){return nt.GraphQLUnionType}});Object.defineProperty(ye,"SchemaMetaFieldDef",{enumerable:!0,get:function(){return Qr.SchemaMetaFieldDef}});Object.defineProperty(ye,"TypeKind",{enumerable:!0,get:function(){return Qr.TypeKind}});Object.defineProperty(ye,"TypeMetaFieldDef",{enumerable:!0,get:function(){return Qr.TypeMetaFieldDef}});Object.defineProperty(ye,"TypeNameMetaFieldDef",{enumerable:!0,get:function(){return Qr.TypeNameMetaFieldDef}});Object.defineProperty(ye,"__Directive",{enumerable:!0,get:function(){return Qr.__Directive}});Object.defineProperty(ye,"__DirectiveLocation",{enumerable:!0,get:function(){return Qr.__DirectiveLocation}});Object.defineProperty(ye,"__EnumValue",{enumerable:!0,get:function(){return Qr.__EnumValue}});Object.defineProperty(ye,"__Field",{enumerable:!0,get:function(){return Qr.__Field}});Object.defineProperty(ye,"__InputValue",{enumerable:!0,get:function(){return Qr.__InputValue}});Object.defineProperty(ye,"__Schema",{enumerable:!0,get:function(){return Qr.__Schema}});Object.defineProperty(ye,"__Type",{enumerable:!0,get:function(){return Qr.__Type}});Object.defineProperty(ye,"__TypeKind",{enumerable:!0,get:function(){return Qr.__TypeKind}});Object.defineProperty(ye,"assertAbstractType",{enumerable:!0,get:function(){return nt.assertAbstractType}});Object.defineProperty(ye,"assertCompositeType",{enumerable:!0,get:function(){return nt.assertCompositeType}});Object.defineProperty(ye,"assertDirective",{enumerable:!0,get:function(){return na.assertDirective}});Object.defineProperty(ye,"assertEnumType",{enumerable:!0,get:function(){return nt.assertEnumType}});Object.defineProperty(ye,"assertEnumValueName",{enumerable:!0,get:function(){return Jw.assertEnumValueName}});Object.defineProperty(ye,"assertInputObjectType",{enumerable:!0,get:function(){return nt.assertInputObjectType}});Object.defineProperty(ye,"assertInputType",{enumerable:!0,get:function(){return nt.assertInputType}});Object.defineProperty(ye,"assertInterfaceType",{enumerable:!0,get:function(){return nt.assertInterfaceType}});Object.defineProperty(ye,"assertLeafType",{enumerable:!0,get:function(){return nt.assertLeafType}});Object.defineProperty(ye,"assertListType",{enumerable:!0,get:function(){return nt.assertListType}});Object.defineProperty(ye,"assertName",{enumerable:!0,get:function(){return Jw.assertName}});Object.defineProperty(ye,"assertNamedType",{enumerable:!0,get:function(){return nt.assertNamedType}});Object.defineProperty(ye,"assertNonNullType",{enumerable:!0,get:function(){return nt.assertNonNullType}});Object.defineProperty(ye,"assertNullableType",{enumerable:!0,get:function(){return nt.assertNullableType}});Object.defineProperty(ye,"assertObjectType",{enumerable:!0,get:function(){return nt.assertObjectType}});Object.defineProperty(ye,"assertOutputType",{enumerable:!0,get:function(){return nt.assertOutputType}});Object.defineProperty(ye,"assertScalarType",{enumerable:!0,get:function(){return nt.assertScalarType}});Object.defineProperty(ye,"assertSchema",{enumerable:!0,get:function(){return w_.assertSchema}});Object.defineProperty(ye,"assertType",{enumerable:!0,get:function(){return nt.assertType}});Object.defineProperty(ye,"assertUnionType",{enumerable:!0,get:function(){return nt.assertUnionType}});Object.defineProperty(ye,"assertValidSchema",{enumerable:!0,get:function(){return Yw.assertValidSchema}});Object.defineProperty(ye,"assertWrappingType",{enumerable:!0,get:function(){return nt.assertWrappingType}});Object.defineProperty(ye,"getNamedType",{enumerable:!0,get:function(){return nt.getNamedType}});Object.defineProperty(ye,"getNullableType",{enumerable:!0,get:function(){return nt.getNullableType}});Object.defineProperty(ye,"introspectionTypes",{enumerable:!0,get:function(){return Qr.introspectionTypes}});Object.defineProperty(ye,"isAbstractType",{enumerable:!0,get:function(){return nt.isAbstractType}});Object.defineProperty(ye,"isCompositeType",{enumerable:!0,get:function(){return nt.isCompositeType}});Object.defineProperty(ye,"isDirective",{enumerable:!0,get:function(){return na.isDirective}});Object.defineProperty(ye,"isEnumType",{enumerable:!0,get:function(){return nt.isEnumType}});Object.defineProperty(ye,"isInputObjectType",{enumerable:!0,get:function(){return nt.isInputObjectType}});Object.defineProperty(ye,"isInputType",{enumerable:!0,get:function(){return nt.isInputType}});Object.defineProperty(ye,"isInterfaceType",{enumerable:!0,get:function(){return nt.isInterfaceType}});Object.defineProperty(ye,"isIntrospectionType",{enumerable:!0,get:function(){return Qr.isIntrospectionType}});Object.defineProperty(ye,"isLeafType",{enumerable:!0,get:function(){return nt.isLeafType}});Object.defineProperty(ye,"isListType",{enumerable:!0,get:function(){return nt.isListType}});Object.defineProperty(ye,"isNamedType",{enumerable:!0,get:function(){return nt.isNamedType}});Object.defineProperty(ye,"isNonNullType",{enumerable:!0,get:function(){return nt.isNonNullType}});Object.defineProperty(ye,"isNullableType",{enumerable:!0,get:function(){return nt.isNullableType}});Object.defineProperty(ye,"isObjectType",{enumerable:!0,get:function(){return nt.isObjectType}});Object.defineProperty(ye,"isOutputType",{enumerable:!0,get:function(){return nt.isOutputType}});Object.defineProperty(ye,"isRequiredArgument",{enumerable:!0,get:function(){return nt.isRequiredArgument}});Object.defineProperty(ye,"isRequiredInputField",{enumerable:!0,get:function(){return nt.isRequiredInputField}});Object.defineProperty(ye,"isScalarType",{enumerable:!0,get:function(){return nt.isScalarType}});Object.defineProperty(ye,"isSchema",{enumerable:!0,get:function(){return w_.isSchema}});Object.defineProperty(ye,"isSpecifiedDirective",{enumerable:!0,get:function(){return na.isSpecifiedDirective}});Object.defineProperty(ye,"isSpecifiedScalarType",{enumerable:!0,get:function(){return ms.isSpecifiedScalarType}});Object.defineProperty(ye,"isType",{enumerable:!0,get:function(){return nt.isType}});Object.defineProperty(ye,"isUnionType",{enumerable:!0,get:function(){return nt.isUnionType}});Object.defineProperty(ye,"isWrappingType",{enumerable:!0,get:function(){return nt.isWrappingType}});Object.defineProperty(ye,"resolveObjMapThunk",{enumerable:!0,get:function(){return nt.resolveObjMapThunk}});Object.defineProperty(ye,"resolveReadonlyArrayThunk",{enumerable:!0,get:function(){return nt.resolveReadonlyArrayThunk}});Object.defineProperty(ye,"specifiedDirectives",{enumerable:!0,get:function(){return na.specifiedDirectives}});Object.defineProperty(ye,"specifiedScalarTypes",{enumerable:!0,get:function(){return ms.specifiedScalarTypes}});Object.defineProperty(ye,"validateSchema",{enumerable:!0,get:function(){return Yw.validateSchema}});var w_=Ju(),nt=Ft(),na=Gr(),ms=ba(),Qr=Ai(),Yw=zd(),Jw=Bd()});var Ww=w(Ct=>{"use strict";m();T();N();Object.defineProperty(Ct,"__esModule",{value:!0});Object.defineProperty(Ct,"BREAK",{enumerable:!0,get:function(){return cp.BREAK}});Object.defineProperty(Ct,"DirectiveLocation",{enumerable:!0,get:function(){return o8.DirectiveLocation}});Object.defineProperty(Ct,"Kind",{enumerable:!0,get:function(){return r8.Kind}});Object.defineProperty(Ct,"Lexer",{enumerable:!0,get:function(){return a8.Lexer}});Object.defineProperty(Ct,"Location",{enumerable:!0,get:function(){return L_.Location}});Object.defineProperty(Ct,"OperationTypeNode",{enumerable:!0,get:function(){return L_.OperationTypeNode}});Object.defineProperty(Ct,"Source",{enumerable:!0,get:function(){return t8.Source}});Object.defineProperty(Ct,"Token",{enumerable:!0,get:function(){return L_.Token}});Object.defineProperty(Ct,"TokenKind",{enumerable:!0,get:function(){return i8.TokenKind}});Object.defineProperty(Ct,"getEnterLeaveForKind",{enumerable:!0,get:function(){return cp.getEnterLeaveForKind}});Object.defineProperty(Ct,"getLocation",{enumerable:!0,get:function(){return n8.getLocation}});Object.defineProperty(Ct,"getVisitFn",{enumerable:!0,get:function(){return cp.getVisitFn}});Object.defineProperty(Ct,"isConstValueNode",{enumerable:!0,get:function(){return Fa.isConstValueNode}});Object.defineProperty(Ct,"isDefinitionNode",{enumerable:!0,get:function(){return Fa.isDefinitionNode}});Object.defineProperty(Ct,"isExecutableDefinitionNode",{enumerable:!0,get:function(){return Fa.isExecutableDefinitionNode}});Object.defineProperty(Ct,"isSelectionNode",{enumerable:!0,get:function(){return Fa.isSelectionNode}});Object.defineProperty(Ct,"isTypeDefinitionNode",{enumerable:!0,get:function(){return Fa.isTypeDefinitionNode}});Object.defineProperty(Ct,"isTypeExtensionNode",{enumerable:!0,get:function(){return Fa.isTypeExtensionNode}});Object.defineProperty(Ct,"isTypeNode",{enumerable:!0,get:function(){return Fa.isTypeNode}});Object.defineProperty(Ct,"isTypeSystemDefinitionNode",{enumerable:!0,get:function(){return Fa.isTypeSystemDefinitionNode}});Object.defineProperty(Ct,"isTypeSystemExtensionNode",{enumerable:!0,get:function(){return Fa.isTypeSystemExtensionNode}});Object.defineProperty(Ct,"isValueNode",{enumerable:!0,get:function(){return Fa.isValueNode}});Object.defineProperty(Ct,"parse",{enumerable:!0,get:function(){return EN.parse}});Object.defineProperty(Ct,"parseConstValue",{enumerable:!0,get:function(){return EN.parseConstValue}});Object.defineProperty(Ct,"parseType",{enumerable:!0,get:function(){return EN.parseType}});Object.defineProperty(Ct,"parseValue",{enumerable:!0,get:function(){return EN.parseValue}});Object.defineProperty(Ct,"print",{enumerable:!0,get:function(){return s8.print}});Object.defineProperty(Ct,"printLocation",{enumerable:!0,get:function(){return zw.printLocation}});Object.defineProperty(Ct,"printSourceLocation",{enumerable:!0,get:function(){return zw.printSourceLocation}});Object.defineProperty(Ct,"visit",{enumerable:!0,get:function(){return cp.visit}});Object.defineProperty(Ct,"visitInParallel",{enumerable:!0,get:function(){return cp.visitInParallel}});var t8=_m(),n8=fm(),zw=Ry(),r8=Pt(),i8=bd(),a8=hm(),EN=Xc(),s8=ci(),cp=ju(),L_=Sa(),Fa=zu(),o8=zc()});var Xw=w(C_=>{"use strict";m();T();N();Object.defineProperty(C_,"__esModule",{value:!0});C_.isAsyncIterable=u8;function u8(e){return typeof(e==null?void 0:e[Symbol.asyncIterator])=="function"}});var Zw=w(B_=>{"use strict";m();T();N();Object.defineProperty(B_,"__esModule",{value:!0});B_.mapAsyncIterator=c8;function c8(e,t){let n=e[Symbol.asyncIterator]();function r(a){return vi(this,null,function*(){if(a.done)return a;try{return{value:yield t(a.value),done:!1}}catch(o){if(typeof n.return=="function")try{yield n.return()}catch(c){}throw o}})}return{next(){return vi(this,null,function*(){return r(yield n.next())})},return(){return vi(this,null,function*(){return typeof n.return=="function"?r(yield n.return()):{value:void 0,done:!0}})},throw(a){return vi(this,null,function*(){if(typeof n.throw=="function")return r(yield n.throw(a));throw a})},[Symbol.asyncIterator](){return this}}}});var rL=w(hN=>{"use strict";m();T();N();Object.defineProperty(hN,"__esModule",{value:!0});hN.createSourceEventStream=nL;hN.subscribe=T8;var l8=Lr(),d8=Yt(),tL=Xw(),eL=Zd(),U_=He(),p8=dN(),f8=oN(),lp=up(),m8=Zw(),N8=ul();function T8(t){return vi(this,arguments,function*(e){arguments.length<2||(0,l8.devAssert)(!1,"graphql@16 dropped long-deprecated support for positional arguments, please pass an object instead.");let n=yield nL(e);if(!(0,tL.isAsyncIterable)(n))return n;let r=i=>(0,lp.execute)(Y(x({},e),{rootValue:i}));return(0,m8.mapAsyncIterator)(n,r)})}function E8(e){let t=e[0];return t&&"document"in t?t:{schema:t,document:e[1],rootValue:e[2],contextValue:e[3],variableValues:e[4],operationName:e[5],subscribeFieldResolver:e[6]}}function nL(...e){return vi(this,null,function*(){let t=E8(e),{schema:n,document:r,variableValues:i}=t;(0,lp.assertValidExecutionArguments)(n,r,i);let a=(0,lp.buildExecutionContext)(t);if(!("schema"in a))return{errors:a};try{let o=yield h8(a);if(!(0,tL.isAsyncIterable)(o))throw new Error(`Subscription field must return Async Iterable. Received: ${(0,d8.inspect)(o)}.`);return o}catch(o){if(o instanceof U_.GraphQLError)return{errors:[o]};throw o}})}function h8(e){return vi(this,null,function*(){let{schema:t,fragments:n,operation:r,variableValues:i,rootValue:a}=e,o=t.getSubscriptionType();if(o==null)throw new U_.GraphQLError("Schema is not configured to execute subscription operation.",{nodes:r});let c=(0,f8.collectFields)(t,n,i,o,r.selectionSet),[l,p]=[...c.entries()][0],f=(0,lp.getFieldDef)(t,o,p[0]);if(!f){let F=p[0].name.value;throw new U_.GraphQLError(`The subscription field "${F}" is not defined.`,{nodes:p})}let y=(0,eL.addPath)(void 0,l,o.name),g=(0,lp.buildResolveInfo)(e,f,p,o,y);try{var v;let F=(0,N8.getArgumentValues)(f,p[0],i),k=e.contextValue,$=yield((v=f.subscribe)!==null&&v!==void 0?v:e.subscribeFieldResolver)(a,F,k,g);if($ instanceof Error)throw $;return $}catch(F){throw(0,p8.locatedError)(F,p,(0,eL.pathToArray)(y))}})}});var aL=w(wi=>{"use strict";m();T();N();Object.defineProperty(wi,"__esModule",{value:!0});Object.defineProperty(wi,"createSourceEventStream",{enumerable:!0,get:function(){return iL.createSourceEventStream}});Object.defineProperty(wi,"defaultFieldResolver",{enumerable:!0,get:function(){return yN.defaultFieldResolver}});Object.defineProperty(wi,"defaultTypeResolver",{enumerable:!0,get:function(){return yN.defaultTypeResolver}});Object.defineProperty(wi,"execute",{enumerable:!0,get:function(){return yN.execute}});Object.defineProperty(wi,"executeSync",{enumerable:!0,get:function(){return yN.executeSync}});Object.defineProperty(wi,"getArgumentValues",{enumerable:!0,get:function(){return k_.getArgumentValues}});Object.defineProperty(wi,"getDirectiveValues",{enumerable:!0,get:function(){return k_.getDirectiveValues}});Object.defineProperty(wi,"getVariableValues",{enumerable:!0,get:function(){return k_.getVariableValues}});Object.defineProperty(wi,"responsePathAsArray",{enumerable:!0,get:function(){return y8.pathToArray}});Object.defineProperty(wi,"subscribe",{enumerable:!0,get:function(){return iL.subscribe}});var y8=Zd(),yN=up(),iL=rL(),k_=ul()});var sL=w(q_=>{"use strict";m();T();N();Object.defineProperty(q_,"__esModule",{value:!0});q_.NoDeprecatedCustomRule=I8;var M_=yr(),dp=He(),x_=Ft();function I8(e){return{Field(t){let n=e.getFieldDef(),r=n==null?void 0:n.deprecationReason;if(n&&r!=null){let i=e.getParentType();i!=null||(0,M_.invariant)(!1),e.reportError(new dp.GraphQLError(`The field ${i.name}.${n.name} is deprecated. ${r}`,{nodes:t}))}},Argument(t){let n=e.getArgument(),r=n==null?void 0:n.deprecationReason;if(n&&r!=null){let i=e.getDirective();if(i!=null)e.reportError(new dp.GraphQLError(`Directive "@${i.name}" argument "${n.name}" is deprecated. ${r}`,{nodes:t}));else{let a=e.getParentType(),o=e.getFieldDef();a!=null&&o!=null||(0,M_.invariant)(!1),e.reportError(new dp.GraphQLError(`Field "${a.name}.${o.name}" argument "${n.name}" is deprecated. ${r}`,{nodes:t}))}}},ObjectField(t){let n=(0,x_.getNamedType)(e.getParentInputType());if((0,x_.isInputObjectType)(n)){let r=n.getFields()[t.name.value],i=r==null?void 0:r.deprecationReason;i!=null&&e.reportError(new dp.GraphQLError(`The input field ${n.name}.${r.name} is deprecated. ${i}`,{nodes:t}))}},EnumValue(t){let n=e.getEnumValue(),r=n==null?void 0:n.deprecationReason;if(n&&r!=null){let i=(0,x_.getNamedType)(e.getInputType());i!=null||(0,M_.invariant)(!1),e.reportError(new dp.GraphQLError(`The enum value "${i.name}.${n.name}" is deprecated. ${r}`,{nodes:t}))}}}}});var oL=w(V_=>{"use strict";m();T();N();Object.defineProperty(V_,"__esModule",{value:!0});V_.NoSchemaIntrospectionCustomRule=S8;var g8=He(),_8=Ft(),v8=Ai();function S8(e){return{Field(t){let n=(0,_8.getNamedType)(e.getType());n&&(0,v8.isIntrospectionType)(n)&&e.reportError(new g8.GraphQLError(`GraphQL introspection has been disabled, but the requested query contained the field "${t.name.value}".`,{nodes:t}))}}}});var cL=w(dt=>{"use strict";m();T();N();Object.defineProperty(dt,"__esModule",{value:!0});Object.defineProperty(dt,"ExecutableDefinitionsRule",{enumerable:!0,get:function(){return b8.ExecutableDefinitionsRule}});Object.defineProperty(dt,"FieldsOnCorrectTypeRule",{enumerable:!0,get:function(){return A8.FieldsOnCorrectTypeRule}});Object.defineProperty(dt,"FragmentsOnCompositeTypesRule",{enumerable:!0,get:function(){return R8.FragmentsOnCompositeTypesRule}});Object.defineProperty(dt,"KnownArgumentNamesRule",{enumerable:!0,get:function(){return P8.KnownArgumentNamesRule}});Object.defineProperty(dt,"KnownDirectivesRule",{enumerable:!0,get:function(){return F8.KnownDirectivesRule}});Object.defineProperty(dt,"KnownFragmentNamesRule",{enumerable:!0,get:function(){return w8.KnownFragmentNamesRule}});Object.defineProperty(dt,"KnownTypeNamesRule",{enumerable:!0,get:function(){return L8.KnownTypeNamesRule}});Object.defineProperty(dt,"LoneAnonymousOperationRule",{enumerable:!0,get:function(){return C8.LoneAnonymousOperationRule}});Object.defineProperty(dt,"LoneSchemaDefinitionRule",{enumerable:!0,get:function(){return e5.LoneSchemaDefinitionRule}});Object.defineProperty(dt,"MaxIntrospectionDepthRule",{enumerable:!0,get:function(){return Z8.MaxIntrospectionDepthRule}});Object.defineProperty(dt,"NoDeprecatedCustomRule",{enumerable:!0,get:function(){return u5.NoDeprecatedCustomRule}});Object.defineProperty(dt,"NoFragmentCyclesRule",{enumerable:!0,get:function(){return B8.NoFragmentCyclesRule}});Object.defineProperty(dt,"NoSchemaIntrospectionCustomRule",{enumerable:!0,get:function(){return c5.NoSchemaIntrospectionCustomRule}});Object.defineProperty(dt,"NoUndefinedVariablesRule",{enumerable:!0,get:function(){return U8.NoUndefinedVariablesRule}});Object.defineProperty(dt,"NoUnusedFragmentsRule",{enumerable:!0,get:function(){return k8.NoUnusedFragmentsRule}});Object.defineProperty(dt,"NoUnusedVariablesRule",{enumerable:!0,get:function(){return M8.NoUnusedVariablesRule}});Object.defineProperty(dt,"OverlappingFieldsCanBeMergedRule",{enumerable:!0,get:function(){return x8.OverlappingFieldsCanBeMergedRule}});Object.defineProperty(dt,"PossibleFragmentSpreadsRule",{enumerable:!0,get:function(){return q8.PossibleFragmentSpreadsRule}});Object.defineProperty(dt,"PossibleTypeExtensionsRule",{enumerable:!0,get:function(){return o5.PossibleTypeExtensionsRule}});Object.defineProperty(dt,"ProvidedRequiredArgumentsRule",{enumerable:!0,get:function(){return V8.ProvidedRequiredArgumentsRule}});Object.defineProperty(dt,"ScalarLeafsRule",{enumerable:!0,get:function(){return j8.ScalarLeafsRule}});Object.defineProperty(dt,"SingleFieldSubscriptionsRule",{enumerable:!0,get:function(){return K8.SingleFieldSubscriptionsRule}});Object.defineProperty(dt,"UniqueArgumentDefinitionNamesRule",{enumerable:!0,get:function(){return a5.UniqueArgumentDefinitionNamesRule}});Object.defineProperty(dt,"UniqueArgumentNamesRule",{enumerable:!0,get:function(){return G8.UniqueArgumentNamesRule}});Object.defineProperty(dt,"UniqueDirectiveNamesRule",{enumerable:!0,get:function(){return s5.UniqueDirectiveNamesRule}});Object.defineProperty(dt,"UniqueDirectivesPerLocationRule",{enumerable:!0,get:function(){return $8.UniqueDirectivesPerLocationRule}});Object.defineProperty(dt,"UniqueEnumValueNamesRule",{enumerable:!0,get:function(){return r5.UniqueEnumValueNamesRule}});Object.defineProperty(dt,"UniqueFieldDefinitionNamesRule",{enumerable:!0,get:function(){return i5.UniqueFieldDefinitionNamesRule}});Object.defineProperty(dt,"UniqueFragmentNamesRule",{enumerable:!0,get:function(){return Q8.UniqueFragmentNamesRule}});Object.defineProperty(dt,"UniqueInputFieldNamesRule",{enumerable:!0,get:function(){return Y8.UniqueInputFieldNamesRule}});Object.defineProperty(dt,"UniqueOperationNamesRule",{enumerable:!0,get:function(){return J8.UniqueOperationNamesRule}});Object.defineProperty(dt,"UniqueOperationTypesRule",{enumerable:!0,get:function(){return t5.UniqueOperationTypesRule}});Object.defineProperty(dt,"UniqueTypeNamesRule",{enumerable:!0,get:function(){return n5.UniqueTypeNamesRule}});Object.defineProperty(dt,"UniqueVariableNamesRule",{enumerable:!0,get:function(){return H8.UniqueVariableNamesRule}});Object.defineProperty(dt,"ValidationContext",{enumerable:!0,get:function(){return D8.ValidationContext}});Object.defineProperty(dt,"ValuesOfCorrectTypeRule",{enumerable:!0,get:function(){return z8.ValuesOfCorrectTypeRule}});Object.defineProperty(dt,"VariablesAreInputTypesRule",{enumerable:!0,get:function(){return W8.VariablesAreInputTypesRule}});Object.defineProperty(dt,"VariablesInAllowedPositionRule",{enumerable:!0,get:function(){return X8.VariablesInAllowedPositionRule}});Object.defineProperty(dt,"recommendedRules",{enumerable:!0,get:function(){return uL.recommendedRules}});Object.defineProperty(dt,"specifiedRules",{enumerable:!0,get:function(){return uL.specifiedRules}});Object.defineProperty(dt,"validate",{enumerable:!0,get:function(){return O8.validate}});var O8=ll(),D8=y_(),uL=T_(),b8=LI(),A8=BI(),R8=kI(),P8=MI(),F8=jI(),w8=GI(),L8=YI(),C8=HI(),B8=tg(),U8=rg(),k8=ag(),M8=og(),x8=Eg(),q8=Ig(),V8=Sg(),j8=Dg(),K8=Bg(),G8=qg(),$8=$g(),Q8=Xg(),Y8=e_(),J8=n_(),H8=u_(),z8=d_(),W8=f_(),X8=N_(),Z8=ZI(),e5=WI(),t5=i_(),n5=s_(),r5=Yg(),i5=zg(),a5=Mg(),s5=jg(),o5=_g(),u5=sL(),c5=oL()});var lL=w(tc=>{"use strict";m();T();N();Object.defineProperty(tc,"__esModule",{value:!0});Object.defineProperty(tc,"GraphQLError",{enumerable:!0,get:function(){return j_.GraphQLError}});Object.defineProperty(tc,"formatError",{enumerable:!0,get:function(){return j_.formatError}});Object.defineProperty(tc,"locatedError",{enumerable:!0,get:function(){return d5.locatedError}});Object.defineProperty(tc,"printError",{enumerable:!0,get:function(){return j_.printError}});Object.defineProperty(tc,"syntaxError",{enumerable:!0,get:function(){return l5.syntaxError}});var j_=He(),l5=Nm(),d5=dN()});var G_=w(K_=>{"use strict";m();T();N();Object.defineProperty(K_,"__esModule",{value:!0});K_.getIntrospectionQuery=p5;function p5(e){let t=x({descriptions:!0,specifiedByUrl:!1,directiveIsRepeatable:!1,schemaDescription:!1,inputValueDeprecation:!1,oneOf:!1},e),n=t.descriptions?"description":"",r=t.specifiedByUrl?"specifiedByURL":"",i=t.directiveIsRepeatable?"isRepeatable":"",a=t.schemaDescription?n:"";function o(l){return t.inputValueDeprecation?l:""}let c=t.oneOf?"isOneOf":"";return` +`))}});var Aw=w(g_=>{"use strict";m();T();N();Object.defineProperty(g_,"__esModule",{value:!0});g_.memoize3=OW;function OW(e){let t;return function(r,i,a){t===void 0&&(t=new WeakMap);let o=t.get(r);o===void 0&&(o=new WeakMap,t.set(r,o));let c=o.get(i);c===void 0&&(c=new WeakMap,o.set(i,c));let l=c.get(a);return l===void 0&&(l=e(r,i,a),c.set(a,l)),l}}});var Rw=w(__=>{"use strict";m();T();N();Object.defineProperty(__,"__esModule",{value:!0});__.promiseForObject=DW;function DW(e){return Promise.all(Object.values(e)).then(t=>{let n=Object.create(null);for(let[r,i]of Object.keys(e).entries())n[i]=t[r];return n})}});var Pw=w(v_=>{"use strict";m();T();N();Object.defineProperty(v_,"__esModule",{value:!0});v_.promiseReduce=AW;var bW=pm();function AW(e,t,n){let r=n;for(let i of e)r=(0,bW.isPromise)(r)?r.then(a=>t(a,i)):t(r,i);return r}});var Fw=w(O_=>{"use strict";m();T();N();Object.defineProperty(O_,"__esModule",{value:!0});O_.toError=PW;var RW=Yt();function PW(e){return e instanceof Error?e:new S_(e)}var S_=class extends Error{constructor(t){super("Unexpected error value: "+(0,RW.inspect)(t)),this.name="NonErrorThrown",this.thrownValue=t}}});var dN=w(D_=>{"use strict";m();T();N();Object.defineProperty(D_,"__esModule",{value:!0});D_.locatedError=LW;var FW=Fw(),wW=He();function LW(e,t,n){var r;let i=(0,FW.toError)(e);return CW(i)?i:new wW.GraphQLError(i.message,{nodes:(r=i.nodes)!==null&&r!==void 0?r:t,source:i.source,positions:i.positions,path:n,originalError:i})}function CW(e){return Array.isArray(e.path)}});var up=w(Fi=>{"use strict";m();T();N();Object.defineProperty(Fi,"__esModule",{value:!0});Fi.assertValidExecutionArguments=xw;Fi.buildExecutionContext=qw;Fi.buildResolveInfo=jw;Fi.defaultTypeResolver=Fi.defaultFieldResolver=void 0;Fi.execute=Mw;Fi.executeSync=VW;Fi.getFieldDef=Gw;var A_=Lr(),Zu=Yt(),BW=yr(),UW=Qm(),F_=va(),ta=pm(),kW=Aw(),ec=Zd(),ww=Rw(),MW=Pw(),Pi=He(),fN=dN(),b_=Sa(),Lw=Pt(),iu=Ft(),dl=Ai(),xW=zd(),Uw=oN(),kw=ul(),qW=(0,kW.memoize3)((e,t,n)=>(0,Uw.collectSubfields)(e.schema,e.fragments,e.variableValues,t,n));function Mw(e){arguments.length<2||(0,A_.devAssert)(!1,"graphql@16 dropped long-deprecated support for positional arguments, please pass an object instead.");let{schema:t,document:n,variableValues:r,rootValue:i}=e;xw(t,n,r);let a=qw(e);if(!("schema"in a))return{errors:a};try{let{operation:o}=a,c=jW(a,o,i);return(0,ta.isPromise)(c)?c.then(l=>pN(l,a.errors),l=>(a.errors.push(l),pN(null,a.errors))):pN(c,a.errors)}catch(o){return a.errors.push(o),pN(null,a.errors)}}function VW(e){let t=Mw(e);if((0,ta.isPromise)(t))throw new Error("GraphQL execution failed to complete synchronously.");return t}function pN(e,t){return t.length===0?{data:e}:{errors:t,data:e}}function xw(e,t,n){t||(0,A_.devAssert)(!1,"Must provide document."),(0,xW.assertValidSchema)(e),n==null||(0,F_.isObjectLike)(n)||(0,A_.devAssert)(!1,"Variables must be provided as an Object where each property is a variable value. Perhaps look to see if an unparsed JSON string was provided.")}function qw(e){var t,n;let{schema:r,document:i,rootValue:a,contextValue:o,variableValues:c,operationName:l,fieldResolver:p,typeResolver:f,subscribeFieldResolver:y}=e,g,v=Object.create(null);for(let K of i.definitions)switch(K.kind){case Lw.Kind.OPERATION_DEFINITION:if(l==null){if(g!==void 0)return[new Pi.GraphQLError("Must provide operation name if query contains multiple operations.")];g=K}else((t=K.name)===null||t===void 0?void 0:t.value)===l&&(g=K);break;case Lw.Kind.FRAGMENT_DEFINITION:v[K.name.value]=K;break;default:}if(!g)return l!=null?[new Pi.GraphQLError(`Unknown operation named "${l}".`)]:[new Pi.GraphQLError("Must provide an operation.")];let P=(n=g.variableDefinitions)!==null&&n!==void 0?n:[],U=(0,kw.getVariableValues)(r,P,c!=null?c:{},{maxErrors:50});return U.errors?U.errors:{schema:r,fragments:v,rootValue:a,contextValue:o,operation:g,variableValues:U.coerced,fieldResolver:p!=null?p:P_,typeResolver:f!=null?f:Kw,subscribeFieldResolver:y!=null?y:P_,errors:[]}}function jW(e,t,n){let r=e.schema.getRootType(t.operation);if(r==null)throw new Pi.GraphQLError(`Schema is not configured to execute ${t.operation} operation.`,{nodes:t});let i=(0,Uw.collectFields)(e.schema,e.fragments,e.variableValues,r,t.selectionSet),a=void 0;switch(t.operation){case b_.OperationTypeNode.QUERY:return mN(e,r,n,a,i);case b_.OperationTypeNode.MUTATION:return KW(e,r,n,a,i);case b_.OperationTypeNode.SUBSCRIPTION:return mN(e,r,n,a,i)}}function KW(e,t,n,r,i){return(0,MW.promiseReduce)(i.entries(),(a,[o,c])=>{let l=(0,ec.addPath)(r,o,t.name),p=Vw(e,t,n,c,l);return p===void 0?a:(0,ta.isPromise)(p)?p.then(f=>(a[o]=f,a)):(a[o]=p,a)},Object.create(null))}function mN(e,t,n,r,i){let a=Object.create(null),o=!1;try{for(let[c,l]of i.entries()){let p=(0,ec.addPath)(r,c,t.name),f=Vw(e,t,n,l,p);f!==void 0&&(a[c]=f,(0,ta.isPromise)(f)&&(o=!0))}}catch(c){if(o)return(0,ww.promiseForObject)(a).finally(()=>{throw c});throw c}return o?(0,ww.promiseForObject)(a):a}function Vw(e,t,n,r,i){var a;let o=Gw(e.schema,t,r[0]);if(!o)return;let c=o.type,l=(a=o.resolve)!==null&&a!==void 0?a:e.fieldResolver,p=jw(e,o,r,t,i);try{let f=(0,kw.getArgumentValues)(o,r[0],e.variableValues),y=e.contextValue,g=l(n,f,y,p),v;return(0,ta.isPromise)(g)?v=g.then(P=>op(e,c,r,p,i,P)):v=op(e,c,r,p,i,g),(0,ta.isPromise)(v)?v.then(void 0,P=>{let U=(0,fN.locatedError)(P,r,(0,ec.pathToArray)(i));return NN(U,c,e)}):v}catch(f){let y=(0,fN.locatedError)(f,r,(0,ec.pathToArray)(i));return NN(y,c,e)}}function jw(e,t,n,r,i){return{fieldName:t.name,fieldNodes:n,returnType:t.type,parentType:r,path:i,schema:e.schema,fragments:e.fragments,rootValue:e.rootValue,operation:e.operation,variableValues:e.variableValues}}function NN(e,t,n){if((0,iu.isNonNullType)(t))throw e;return n.errors.push(e),null}function op(e,t,n,r,i,a){if(a instanceof Error)throw a;if((0,iu.isNonNullType)(t)){let o=op(e,t.ofType,n,r,i,a);if(o===null)throw new Error(`Cannot return null for non-nullable field ${r.parentType.name}.${r.fieldName}.`);return o}if(a==null)return null;if((0,iu.isListType)(t))return GW(e,t,n,r,i,a);if((0,iu.isLeafType)(t))return $W(t,a);if((0,iu.isAbstractType)(t))return QW(e,t,n,r,i,a);if((0,iu.isObjectType)(t))return R_(e,t,n,r,i,a);(0,BW.invariant)(!1,"Cannot complete value of unexpected output type: "+(0,Zu.inspect)(t))}function GW(e,t,n,r,i,a){if(!(0,UW.isIterableObject)(a))throw new Pi.GraphQLError(`Expected Iterable, but did not find one for field "${r.parentType.name}.${r.fieldName}".`);let o=t.ofType,c=!1,l=Array.from(a,(p,f)=>{let y=(0,ec.addPath)(i,f,void 0);try{let g;return(0,ta.isPromise)(p)?g=p.then(v=>op(e,o,n,r,y,v)):g=op(e,o,n,r,y,p),(0,ta.isPromise)(g)?(c=!0,g.then(void 0,v=>{let P=(0,fN.locatedError)(v,n,(0,ec.pathToArray)(y));return NN(P,o,e)})):g}catch(g){let v=(0,fN.locatedError)(g,n,(0,ec.pathToArray)(y));return NN(v,o,e)}});return c?Promise.all(l):l}function $W(e,t){let n=e.serialize(t);if(n==null)throw new Error(`Expected \`${(0,Zu.inspect)(e)}.serialize(${(0,Zu.inspect)(t)})\` to return non-nullable value, returned: ${(0,Zu.inspect)(n)}`);return n}function QW(e,t,n,r,i,a){var o;let c=(o=t.resolveType)!==null&&o!==void 0?o:e.typeResolver,l=e.contextValue,p=c(a,l,r,t);return(0,ta.isPromise)(p)?p.then(f=>R_(e,Cw(f,e,t,n,r,a),n,r,i,a)):R_(e,Cw(p,e,t,n,r,a),n,r,i,a)}function Cw(e,t,n,r,i,a){if(e==null)throw new Pi.GraphQLError(`Abstract type "${n.name}" must resolve to an Object type at runtime for field "${i.parentType.name}.${i.fieldName}". Either the "${n.name}" type should provide a "resolveType" function or each possible type should provide an "isTypeOf" function.`,r);if((0,iu.isObjectType)(e))throw new Pi.GraphQLError("Support for returning GraphQLObjectType from resolveType was removed in graphql-js@16.0.0 please return type name instead.");if(typeof e!="string")throw new Pi.GraphQLError(`Abstract type "${n.name}" must resolve to an Object type at runtime for field "${i.parentType.name}.${i.fieldName}" with value ${(0,Zu.inspect)(a)}, received "${(0,Zu.inspect)(e)}".`);let o=t.schema.getType(e);if(o==null)throw new Pi.GraphQLError(`Abstract type "${n.name}" was resolved to a type "${e}" that does not exist inside the schema.`,{nodes:r});if(!(0,iu.isObjectType)(o))throw new Pi.GraphQLError(`Abstract type "${n.name}" was resolved to a non-object type "${e}".`,{nodes:r});if(!t.schema.isSubType(n,o))throw new Pi.GraphQLError(`Runtime Object type "${o.name}" is not a possible type for "${n.name}".`,{nodes:r});return o}function R_(e,t,n,r,i,a){let o=qW(e,t,n);if(t.isTypeOf){let c=t.isTypeOf(a,e.contextValue,r);if((0,ta.isPromise)(c))return c.then(l=>{if(!l)throw Bw(t,a,n);return mN(e,t,a,i,o)});if(!c)throw Bw(t,a,n)}return mN(e,t,a,i,o)}function Bw(e,t,n){return new Pi.GraphQLError(`Expected value of type "${e.name}" but got: ${(0,Zu.inspect)(t)}.`,{nodes:n})}var Kw=function(e,t,n,r){if((0,F_.isObjectLike)(e)&&typeof e.__typename=="string")return e.__typename;let i=n.schema.getPossibleTypes(r),a=[];for(let o=0;o{for(let c=0;c{"use strict";m();T();N();Object.defineProperty(TN,"__esModule",{value:!0});TN.graphql=ZW;TN.graphqlSync=e8;var YW=Lr(),JW=pm(),HW=Xc(),zW=zd(),WW=ll(),XW=up();function ZW(e){return new Promise(t=>t($w(e)))}function e8(e){let t=$w(e);if((0,JW.isPromise)(t))throw new Error("GraphQL execution failed to complete synchronously.");return t}function $w(e){arguments.length<2||(0,YW.devAssert)(!1,"graphql@16 dropped long-deprecated support for positional arguments, please pass an object instead.");let{schema:t,source:n,rootValue:r,contextValue:i,variableValues:a,operationName:o,fieldResolver:c,typeResolver:l}=e,p=(0,zW.validateSchema)(t);if(p.length>0)return{errors:p};let f;try{f=(0,HW.parse)(n)}catch(g){return{errors:[g]}}let y=(0,WW.validate)(t,f);return y.length>0?{errors:y}:(0,XW.execute)({schema:t,document:f,rootValue:r,contextValue:i,variableValues:a,operationName:o,fieldResolver:c,typeResolver:l})}});var Hw=w(ye=>{"use strict";m();T();N();Object.defineProperty(ye,"__esModule",{value:!0});Object.defineProperty(ye,"DEFAULT_DEPRECATION_REASON",{enumerable:!0,get:function(){return na.DEFAULT_DEPRECATION_REASON}});Object.defineProperty(ye,"GRAPHQL_MAX_INT",{enumerable:!0,get:function(){return ms.GRAPHQL_MAX_INT}});Object.defineProperty(ye,"GRAPHQL_MIN_INT",{enumerable:!0,get:function(){return ms.GRAPHQL_MIN_INT}});Object.defineProperty(ye,"GraphQLBoolean",{enumerable:!0,get:function(){return ms.GraphQLBoolean}});Object.defineProperty(ye,"GraphQLDeprecatedDirective",{enumerable:!0,get:function(){return na.GraphQLDeprecatedDirective}});Object.defineProperty(ye,"GraphQLDirective",{enumerable:!0,get:function(){return na.GraphQLDirective}});Object.defineProperty(ye,"GraphQLEnumType",{enumerable:!0,get:function(){return nt.GraphQLEnumType}});Object.defineProperty(ye,"GraphQLFloat",{enumerable:!0,get:function(){return ms.GraphQLFloat}});Object.defineProperty(ye,"GraphQLID",{enumerable:!0,get:function(){return ms.GraphQLID}});Object.defineProperty(ye,"GraphQLIncludeDirective",{enumerable:!0,get:function(){return na.GraphQLIncludeDirective}});Object.defineProperty(ye,"GraphQLInputObjectType",{enumerable:!0,get:function(){return nt.GraphQLInputObjectType}});Object.defineProperty(ye,"GraphQLInt",{enumerable:!0,get:function(){return ms.GraphQLInt}});Object.defineProperty(ye,"GraphQLInterfaceType",{enumerable:!0,get:function(){return nt.GraphQLInterfaceType}});Object.defineProperty(ye,"GraphQLList",{enumerable:!0,get:function(){return nt.GraphQLList}});Object.defineProperty(ye,"GraphQLNonNull",{enumerable:!0,get:function(){return nt.GraphQLNonNull}});Object.defineProperty(ye,"GraphQLObjectType",{enumerable:!0,get:function(){return nt.GraphQLObjectType}});Object.defineProperty(ye,"GraphQLOneOfDirective",{enumerable:!0,get:function(){return na.GraphQLOneOfDirective}});Object.defineProperty(ye,"GraphQLScalarType",{enumerable:!0,get:function(){return nt.GraphQLScalarType}});Object.defineProperty(ye,"GraphQLSchema",{enumerable:!0,get:function(){return w_.GraphQLSchema}});Object.defineProperty(ye,"GraphQLSkipDirective",{enumerable:!0,get:function(){return na.GraphQLSkipDirective}});Object.defineProperty(ye,"GraphQLSpecifiedByDirective",{enumerable:!0,get:function(){return na.GraphQLSpecifiedByDirective}});Object.defineProperty(ye,"GraphQLString",{enumerable:!0,get:function(){return ms.GraphQLString}});Object.defineProperty(ye,"GraphQLUnionType",{enumerable:!0,get:function(){return nt.GraphQLUnionType}});Object.defineProperty(ye,"SchemaMetaFieldDef",{enumerable:!0,get:function(){return Qr.SchemaMetaFieldDef}});Object.defineProperty(ye,"TypeKind",{enumerable:!0,get:function(){return Qr.TypeKind}});Object.defineProperty(ye,"TypeMetaFieldDef",{enumerable:!0,get:function(){return Qr.TypeMetaFieldDef}});Object.defineProperty(ye,"TypeNameMetaFieldDef",{enumerable:!0,get:function(){return Qr.TypeNameMetaFieldDef}});Object.defineProperty(ye,"__Directive",{enumerable:!0,get:function(){return Qr.__Directive}});Object.defineProperty(ye,"__DirectiveLocation",{enumerable:!0,get:function(){return Qr.__DirectiveLocation}});Object.defineProperty(ye,"__EnumValue",{enumerable:!0,get:function(){return Qr.__EnumValue}});Object.defineProperty(ye,"__Field",{enumerable:!0,get:function(){return Qr.__Field}});Object.defineProperty(ye,"__InputValue",{enumerable:!0,get:function(){return Qr.__InputValue}});Object.defineProperty(ye,"__Schema",{enumerable:!0,get:function(){return Qr.__Schema}});Object.defineProperty(ye,"__Type",{enumerable:!0,get:function(){return Qr.__Type}});Object.defineProperty(ye,"__TypeKind",{enumerable:!0,get:function(){return Qr.__TypeKind}});Object.defineProperty(ye,"assertAbstractType",{enumerable:!0,get:function(){return nt.assertAbstractType}});Object.defineProperty(ye,"assertCompositeType",{enumerable:!0,get:function(){return nt.assertCompositeType}});Object.defineProperty(ye,"assertDirective",{enumerable:!0,get:function(){return na.assertDirective}});Object.defineProperty(ye,"assertEnumType",{enumerable:!0,get:function(){return nt.assertEnumType}});Object.defineProperty(ye,"assertEnumValueName",{enumerable:!0,get:function(){return Jw.assertEnumValueName}});Object.defineProperty(ye,"assertInputObjectType",{enumerable:!0,get:function(){return nt.assertInputObjectType}});Object.defineProperty(ye,"assertInputType",{enumerable:!0,get:function(){return nt.assertInputType}});Object.defineProperty(ye,"assertInterfaceType",{enumerable:!0,get:function(){return nt.assertInterfaceType}});Object.defineProperty(ye,"assertLeafType",{enumerable:!0,get:function(){return nt.assertLeafType}});Object.defineProperty(ye,"assertListType",{enumerable:!0,get:function(){return nt.assertListType}});Object.defineProperty(ye,"assertName",{enumerable:!0,get:function(){return Jw.assertName}});Object.defineProperty(ye,"assertNamedType",{enumerable:!0,get:function(){return nt.assertNamedType}});Object.defineProperty(ye,"assertNonNullType",{enumerable:!0,get:function(){return nt.assertNonNullType}});Object.defineProperty(ye,"assertNullableType",{enumerable:!0,get:function(){return nt.assertNullableType}});Object.defineProperty(ye,"assertObjectType",{enumerable:!0,get:function(){return nt.assertObjectType}});Object.defineProperty(ye,"assertOutputType",{enumerable:!0,get:function(){return nt.assertOutputType}});Object.defineProperty(ye,"assertScalarType",{enumerable:!0,get:function(){return nt.assertScalarType}});Object.defineProperty(ye,"assertSchema",{enumerable:!0,get:function(){return w_.assertSchema}});Object.defineProperty(ye,"assertType",{enumerable:!0,get:function(){return nt.assertType}});Object.defineProperty(ye,"assertUnionType",{enumerable:!0,get:function(){return nt.assertUnionType}});Object.defineProperty(ye,"assertValidSchema",{enumerable:!0,get:function(){return Yw.assertValidSchema}});Object.defineProperty(ye,"assertWrappingType",{enumerable:!0,get:function(){return nt.assertWrappingType}});Object.defineProperty(ye,"getNamedType",{enumerable:!0,get:function(){return nt.getNamedType}});Object.defineProperty(ye,"getNullableType",{enumerable:!0,get:function(){return nt.getNullableType}});Object.defineProperty(ye,"introspectionTypes",{enumerable:!0,get:function(){return Qr.introspectionTypes}});Object.defineProperty(ye,"isAbstractType",{enumerable:!0,get:function(){return nt.isAbstractType}});Object.defineProperty(ye,"isCompositeType",{enumerable:!0,get:function(){return nt.isCompositeType}});Object.defineProperty(ye,"isDirective",{enumerable:!0,get:function(){return na.isDirective}});Object.defineProperty(ye,"isEnumType",{enumerable:!0,get:function(){return nt.isEnumType}});Object.defineProperty(ye,"isInputObjectType",{enumerable:!0,get:function(){return nt.isInputObjectType}});Object.defineProperty(ye,"isInputType",{enumerable:!0,get:function(){return nt.isInputType}});Object.defineProperty(ye,"isInterfaceType",{enumerable:!0,get:function(){return nt.isInterfaceType}});Object.defineProperty(ye,"isIntrospectionType",{enumerable:!0,get:function(){return Qr.isIntrospectionType}});Object.defineProperty(ye,"isLeafType",{enumerable:!0,get:function(){return nt.isLeafType}});Object.defineProperty(ye,"isListType",{enumerable:!0,get:function(){return nt.isListType}});Object.defineProperty(ye,"isNamedType",{enumerable:!0,get:function(){return nt.isNamedType}});Object.defineProperty(ye,"isNonNullType",{enumerable:!0,get:function(){return nt.isNonNullType}});Object.defineProperty(ye,"isNullableType",{enumerable:!0,get:function(){return nt.isNullableType}});Object.defineProperty(ye,"isObjectType",{enumerable:!0,get:function(){return nt.isObjectType}});Object.defineProperty(ye,"isOutputType",{enumerable:!0,get:function(){return nt.isOutputType}});Object.defineProperty(ye,"isRequiredArgument",{enumerable:!0,get:function(){return nt.isRequiredArgument}});Object.defineProperty(ye,"isRequiredInputField",{enumerable:!0,get:function(){return nt.isRequiredInputField}});Object.defineProperty(ye,"isScalarType",{enumerable:!0,get:function(){return nt.isScalarType}});Object.defineProperty(ye,"isSchema",{enumerable:!0,get:function(){return w_.isSchema}});Object.defineProperty(ye,"isSpecifiedDirective",{enumerable:!0,get:function(){return na.isSpecifiedDirective}});Object.defineProperty(ye,"isSpecifiedScalarType",{enumerable:!0,get:function(){return ms.isSpecifiedScalarType}});Object.defineProperty(ye,"isType",{enumerable:!0,get:function(){return nt.isType}});Object.defineProperty(ye,"isUnionType",{enumerable:!0,get:function(){return nt.isUnionType}});Object.defineProperty(ye,"isWrappingType",{enumerable:!0,get:function(){return nt.isWrappingType}});Object.defineProperty(ye,"resolveObjMapThunk",{enumerable:!0,get:function(){return nt.resolveObjMapThunk}});Object.defineProperty(ye,"resolveReadonlyArrayThunk",{enumerable:!0,get:function(){return nt.resolveReadonlyArrayThunk}});Object.defineProperty(ye,"specifiedDirectives",{enumerable:!0,get:function(){return na.specifiedDirectives}});Object.defineProperty(ye,"specifiedScalarTypes",{enumerable:!0,get:function(){return ms.specifiedScalarTypes}});Object.defineProperty(ye,"validateSchema",{enumerable:!0,get:function(){return Yw.validateSchema}});var w_=Ju(),nt=Ft(),na=Gr(),ms=ba(),Qr=Ai(),Yw=zd(),Jw=Bd()});var Ww=w(Ct=>{"use strict";m();T();N();Object.defineProperty(Ct,"__esModule",{value:!0});Object.defineProperty(Ct,"BREAK",{enumerable:!0,get:function(){return cp.BREAK}});Object.defineProperty(Ct,"DirectiveLocation",{enumerable:!0,get:function(){return o8.DirectiveLocation}});Object.defineProperty(Ct,"Kind",{enumerable:!0,get:function(){return r8.Kind}});Object.defineProperty(Ct,"Lexer",{enumerable:!0,get:function(){return a8.Lexer}});Object.defineProperty(Ct,"Location",{enumerable:!0,get:function(){return L_.Location}});Object.defineProperty(Ct,"OperationTypeNode",{enumerable:!0,get:function(){return L_.OperationTypeNode}});Object.defineProperty(Ct,"Source",{enumerable:!0,get:function(){return t8.Source}});Object.defineProperty(Ct,"Token",{enumerable:!0,get:function(){return L_.Token}});Object.defineProperty(Ct,"TokenKind",{enumerable:!0,get:function(){return i8.TokenKind}});Object.defineProperty(Ct,"getEnterLeaveForKind",{enumerable:!0,get:function(){return cp.getEnterLeaveForKind}});Object.defineProperty(Ct,"getLocation",{enumerable:!0,get:function(){return n8.getLocation}});Object.defineProperty(Ct,"getVisitFn",{enumerable:!0,get:function(){return cp.getVisitFn}});Object.defineProperty(Ct,"isConstValueNode",{enumerable:!0,get:function(){return Fa.isConstValueNode}});Object.defineProperty(Ct,"isDefinitionNode",{enumerable:!0,get:function(){return Fa.isDefinitionNode}});Object.defineProperty(Ct,"isExecutableDefinitionNode",{enumerable:!0,get:function(){return Fa.isExecutableDefinitionNode}});Object.defineProperty(Ct,"isSelectionNode",{enumerable:!0,get:function(){return Fa.isSelectionNode}});Object.defineProperty(Ct,"isTypeDefinitionNode",{enumerable:!0,get:function(){return Fa.isTypeDefinitionNode}});Object.defineProperty(Ct,"isTypeExtensionNode",{enumerable:!0,get:function(){return Fa.isTypeExtensionNode}});Object.defineProperty(Ct,"isTypeNode",{enumerable:!0,get:function(){return Fa.isTypeNode}});Object.defineProperty(Ct,"isTypeSystemDefinitionNode",{enumerable:!0,get:function(){return Fa.isTypeSystemDefinitionNode}});Object.defineProperty(Ct,"isTypeSystemExtensionNode",{enumerable:!0,get:function(){return Fa.isTypeSystemExtensionNode}});Object.defineProperty(Ct,"isValueNode",{enumerable:!0,get:function(){return Fa.isValueNode}});Object.defineProperty(Ct,"parse",{enumerable:!0,get:function(){return EN.parse}});Object.defineProperty(Ct,"parseConstValue",{enumerable:!0,get:function(){return EN.parseConstValue}});Object.defineProperty(Ct,"parseType",{enumerable:!0,get:function(){return EN.parseType}});Object.defineProperty(Ct,"parseValue",{enumerable:!0,get:function(){return EN.parseValue}});Object.defineProperty(Ct,"print",{enumerable:!0,get:function(){return s8.print}});Object.defineProperty(Ct,"printLocation",{enumerable:!0,get:function(){return zw.printLocation}});Object.defineProperty(Ct,"printSourceLocation",{enumerable:!0,get:function(){return zw.printSourceLocation}});Object.defineProperty(Ct,"visit",{enumerable:!0,get:function(){return cp.visit}});Object.defineProperty(Ct,"visitInParallel",{enumerable:!0,get:function(){return cp.visitInParallel}});var t8=_m(),n8=fm(),zw=Ry(),r8=Pt(),i8=bd(),a8=hm(),EN=Xc(),s8=ci(),cp=ju(),L_=Sa(),Fa=zu(),o8=zc()});var Xw=w(C_=>{"use strict";m();T();N();Object.defineProperty(C_,"__esModule",{value:!0});C_.isAsyncIterable=u8;function u8(e){return typeof(e==null?void 0:e[Symbol.asyncIterator])=="function"}});var Zw=w(B_=>{"use strict";m();T();N();Object.defineProperty(B_,"__esModule",{value:!0});B_.mapAsyncIterator=c8;function c8(e,t){let n=e[Symbol.asyncIterator]();function r(a){return vi(this,null,function*(){if(a.done)return a;try{return{value:yield t(a.value),done:!1}}catch(o){if(typeof n.return=="function")try{yield n.return()}catch(c){}throw o}})}return{next(){return vi(this,null,function*(){return r(yield n.next())})},return(){return vi(this,null,function*(){return typeof n.return=="function"?r(yield n.return()):{value:void 0,done:!0}})},throw(a){return vi(this,null,function*(){if(typeof n.throw=="function")return r(yield n.throw(a));throw a})},[Symbol.asyncIterator](){return this}}}});var rL=w(hN=>{"use strict";m();T();N();Object.defineProperty(hN,"__esModule",{value:!0});hN.createSourceEventStream=nL;hN.subscribe=T8;var l8=Lr(),d8=Yt(),tL=Xw(),eL=Zd(),U_=He(),p8=dN(),f8=oN(),lp=up(),m8=Zw(),N8=ul();function T8(t){return vi(this,arguments,function*(e){arguments.length<2||(0,l8.devAssert)(!1,"graphql@16 dropped long-deprecated support for positional arguments, please pass an object instead.");let n=yield nL(e);if(!(0,tL.isAsyncIterable)(n))return n;let r=i=>(0,lp.execute)(Y(x({},e),{rootValue:i}));return(0,m8.mapAsyncIterator)(n,r)})}function E8(e){let t=e[0];return t&&"document"in t?t:{schema:t,document:e[1],rootValue:e[2],contextValue:e[3],variableValues:e[4],operationName:e[5],subscribeFieldResolver:e[6]}}function nL(...e){return vi(this,null,function*(){let t=E8(e),{schema:n,document:r,variableValues:i}=t;(0,lp.assertValidExecutionArguments)(n,r,i);let a=(0,lp.buildExecutionContext)(t);if(!("schema"in a))return{errors:a};try{let o=yield h8(a);if(!(0,tL.isAsyncIterable)(o))throw new Error(`Subscription field must return Async Iterable. Received: ${(0,d8.inspect)(o)}.`);return o}catch(o){if(o instanceof U_.GraphQLError)return{errors:[o]};throw o}})}function h8(e){return vi(this,null,function*(){let{schema:t,fragments:n,operation:r,variableValues:i,rootValue:a}=e,o=t.getSubscriptionType();if(o==null)throw new U_.GraphQLError("Schema is not configured to execute subscription operation.",{nodes:r});let c=(0,f8.collectFields)(t,n,i,o,r.selectionSet),[l,p]=[...c.entries()][0],f=(0,lp.getFieldDef)(t,o,p[0]);if(!f){let P=p[0].name.value;throw new U_.GraphQLError(`The subscription field "${P}" is not defined.`,{nodes:p})}let y=(0,eL.addPath)(void 0,l,o.name),g=(0,lp.buildResolveInfo)(e,f,p,o,y);try{var v;let P=(0,N8.getArgumentValues)(f,p[0],i),U=e.contextValue,$=yield((v=f.subscribe)!==null&&v!==void 0?v:e.subscribeFieldResolver)(a,P,U,g);if($ instanceof Error)throw $;return $}catch(P){throw(0,p8.locatedError)(P,p,(0,eL.pathToArray)(y))}})}});var aL=w(wi=>{"use strict";m();T();N();Object.defineProperty(wi,"__esModule",{value:!0});Object.defineProperty(wi,"createSourceEventStream",{enumerable:!0,get:function(){return iL.createSourceEventStream}});Object.defineProperty(wi,"defaultFieldResolver",{enumerable:!0,get:function(){return yN.defaultFieldResolver}});Object.defineProperty(wi,"defaultTypeResolver",{enumerable:!0,get:function(){return yN.defaultTypeResolver}});Object.defineProperty(wi,"execute",{enumerable:!0,get:function(){return yN.execute}});Object.defineProperty(wi,"executeSync",{enumerable:!0,get:function(){return yN.executeSync}});Object.defineProperty(wi,"getArgumentValues",{enumerable:!0,get:function(){return k_.getArgumentValues}});Object.defineProperty(wi,"getDirectiveValues",{enumerable:!0,get:function(){return k_.getDirectiveValues}});Object.defineProperty(wi,"getVariableValues",{enumerable:!0,get:function(){return k_.getVariableValues}});Object.defineProperty(wi,"responsePathAsArray",{enumerable:!0,get:function(){return y8.pathToArray}});Object.defineProperty(wi,"subscribe",{enumerable:!0,get:function(){return iL.subscribe}});var y8=Zd(),yN=up(),iL=rL(),k_=ul()});var sL=w(q_=>{"use strict";m();T();N();Object.defineProperty(q_,"__esModule",{value:!0});q_.NoDeprecatedCustomRule=I8;var M_=yr(),dp=He(),x_=Ft();function I8(e){return{Field(t){let n=e.getFieldDef(),r=n==null?void 0:n.deprecationReason;if(n&&r!=null){let i=e.getParentType();i!=null||(0,M_.invariant)(!1),e.reportError(new dp.GraphQLError(`The field ${i.name}.${n.name} is deprecated. ${r}`,{nodes:t}))}},Argument(t){let n=e.getArgument(),r=n==null?void 0:n.deprecationReason;if(n&&r!=null){let i=e.getDirective();if(i!=null)e.reportError(new dp.GraphQLError(`Directive "@${i.name}" argument "${n.name}" is deprecated. ${r}`,{nodes:t}));else{let a=e.getParentType(),o=e.getFieldDef();a!=null&&o!=null||(0,M_.invariant)(!1),e.reportError(new dp.GraphQLError(`Field "${a.name}.${o.name}" argument "${n.name}" is deprecated. ${r}`,{nodes:t}))}}},ObjectField(t){let n=(0,x_.getNamedType)(e.getParentInputType());if((0,x_.isInputObjectType)(n)){let r=n.getFields()[t.name.value],i=r==null?void 0:r.deprecationReason;i!=null&&e.reportError(new dp.GraphQLError(`The input field ${n.name}.${r.name} is deprecated. ${i}`,{nodes:t}))}},EnumValue(t){let n=e.getEnumValue(),r=n==null?void 0:n.deprecationReason;if(n&&r!=null){let i=(0,x_.getNamedType)(e.getInputType());i!=null||(0,M_.invariant)(!1),e.reportError(new dp.GraphQLError(`The enum value "${i.name}.${n.name}" is deprecated. ${r}`,{nodes:t}))}}}}});var oL=w(V_=>{"use strict";m();T();N();Object.defineProperty(V_,"__esModule",{value:!0});V_.NoSchemaIntrospectionCustomRule=S8;var g8=He(),_8=Ft(),v8=Ai();function S8(e){return{Field(t){let n=(0,_8.getNamedType)(e.getType());n&&(0,v8.isIntrospectionType)(n)&&e.reportError(new g8.GraphQLError(`GraphQL introspection has been disabled, but the requested query contained the field "${t.name.value}".`,{nodes:t}))}}}});var cL=w(dt=>{"use strict";m();T();N();Object.defineProperty(dt,"__esModule",{value:!0});Object.defineProperty(dt,"ExecutableDefinitionsRule",{enumerable:!0,get:function(){return b8.ExecutableDefinitionsRule}});Object.defineProperty(dt,"FieldsOnCorrectTypeRule",{enumerable:!0,get:function(){return A8.FieldsOnCorrectTypeRule}});Object.defineProperty(dt,"FragmentsOnCompositeTypesRule",{enumerable:!0,get:function(){return R8.FragmentsOnCompositeTypesRule}});Object.defineProperty(dt,"KnownArgumentNamesRule",{enumerable:!0,get:function(){return P8.KnownArgumentNamesRule}});Object.defineProperty(dt,"KnownDirectivesRule",{enumerable:!0,get:function(){return F8.KnownDirectivesRule}});Object.defineProperty(dt,"KnownFragmentNamesRule",{enumerable:!0,get:function(){return w8.KnownFragmentNamesRule}});Object.defineProperty(dt,"KnownTypeNamesRule",{enumerable:!0,get:function(){return L8.KnownTypeNamesRule}});Object.defineProperty(dt,"LoneAnonymousOperationRule",{enumerable:!0,get:function(){return C8.LoneAnonymousOperationRule}});Object.defineProperty(dt,"LoneSchemaDefinitionRule",{enumerable:!0,get:function(){return e5.LoneSchemaDefinitionRule}});Object.defineProperty(dt,"MaxIntrospectionDepthRule",{enumerable:!0,get:function(){return Z8.MaxIntrospectionDepthRule}});Object.defineProperty(dt,"NoDeprecatedCustomRule",{enumerable:!0,get:function(){return u5.NoDeprecatedCustomRule}});Object.defineProperty(dt,"NoFragmentCyclesRule",{enumerable:!0,get:function(){return B8.NoFragmentCyclesRule}});Object.defineProperty(dt,"NoSchemaIntrospectionCustomRule",{enumerable:!0,get:function(){return c5.NoSchemaIntrospectionCustomRule}});Object.defineProperty(dt,"NoUndefinedVariablesRule",{enumerable:!0,get:function(){return U8.NoUndefinedVariablesRule}});Object.defineProperty(dt,"NoUnusedFragmentsRule",{enumerable:!0,get:function(){return k8.NoUnusedFragmentsRule}});Object.defineProperty(dt,"NoUnusedVariablesRule",{enumerable:!0,get:function(){return M8.NoUnusedVariablesRule}});Object.defineProperty(dt,"OverlappingFieldsCanBeMergedRule",{enumerable:!0,get:function(){return x8.OverlappingFieldsCanBeMergedRule}});Object.defineProperty(dt,"PossibleFragmentSpreadsRule",{enumerable:!0,get:function(){return q8.PossibleFragmentSpreadsRule}});Object.defineProperty(dt,"PossibleTypeExtensionsRule",{enumerable:!0,get:function(){return o5.PossibleTypeExtensionsRule}});Object.defineProperty(dt,"ProvidedRequiredArgumentsRule",{enumerable:!0,get:function(){return V8.ProvidedRequiredArgumentsRule}});Object.defineProperty(dt,"ScalarLeafsRule",{enumerable:!0,get:function(){return j8.ScalarLeafsRule}});Object.defineProperty(dt,"SingleFieldSubscriptionsRule",{enumerable:!0,get:function(){return K8.SingleFieldSubscriptionsRule}});Object.defineProperty(dt,"UniqueArgumentDefinitionNamesRule",{enumerable:!0,get:function(){return a5.UniqueArgumentDefinitionNamesRule}});Object.defineProperty(dt,"UniqueArgumentNamesRule",{enumerable:!0,get:function(){return G8.UniqueArgumentNamesRule}});Object.defineProperty(dt,"UniqueDirectiveNamesRule",{enumerable:!0,get:function(){return s5.UniqueDirectiveNamesRule}});Object.defineProperty(dt,"UniqueDirectivesPerLocationRule",{enumerable:!0,get:function(){return $8.UniqueDirectivesPerLocationRule}});Object.defineProperty(dt,"UniqueEnumValueNamesRule",{enumerable:!0,get:function(){return r5.UniqueEnumValueNamesRule}});Object.defineProperty(dt,"UniqueFieldDefinitionNamesRule",{enumerable:!0,get:function(){return i5.UniqueFieldDefinitionNamesRule}});Object.defineProperty(dt,"UniqueFragmentNamesRule",{enumerable:!0,get:function(){return Q8.UniqueFragmentNamesRule}});Object.defineProperty(dt,"UniqueInputFieldNamesRule",{enumerable:!0,get:function(){return Y8.UniqueInputFieldNamesRule}});Object.defineProperty(dt,"UniqueOperationNamesRule",{enumerable:!0,get:function(){return J8.UniqueOperationNamesRule}});Object.defineProperty(dt,"UniqueOperationTypesRule",{enumerable:!0,get:function(){return t5.UniqueOperationTypesRule}});Object.defineProperty(dt,"UniqueTypeNamesRule",{enumerable:!0,get:function(){return n5.UniqueTypeNamesRule}});Object.defineProperty(dt,"UniqueVariableNamesRule",{enumerable:!0,get:function(){return H8.UniqueVariableNamesRule}});Object.defineProperty(dt,"ValidationContext",{enumerable:!0,get:function(){return D8.ValidationContext}});Object.defineProperty(dt,"ValuesOfCorrectTypeRule",{enumerable:!0,get:function(){return z8.ValuesOfCorrectTypeRule}});Object.defineProperty(dt,"VariablesAreInputTypesRule",{enumerable:!0,get:function(){return W8.VariablesAreInputTypesRule}});Object.defineProperty(dt,"VariablesInAllowedPositionRule",{enumerable:!0,get:function(){return X8.VariablesInAllowedPositionRule}});Object.defineProperty(dt,"recommendedRules",{enumerable:!0,get:function(){return uL.recommendedRules}});Object.defineProperty(dt,"specifiedRules",{enumerable:!0,get:function(){return uL.specifiedRules}});Object.defineProperty(dt,"validate",{enumerable:!0,get:function(){return O8.validate}});var O8=ll(),D8=y_(),uL=T_(),b8=LI(),A8=BI(),R8=kI(),P8=MI(),F8=jI(),w8=GI(),L8=YI(),C8=HI(),B8=tg(),U8=rg(),k8=ag(),M8=og(),x8=Eg(),q8=Ig(),V8=Sg(),j8=Dg(),K8=Bg(),G8=qg(),$8=$g(),Q8=Xg(),Y8=e_(),J8=n_(),H8=u_(),z8=d_(),W8=f_(),X8=N_(),Z8=ZI(),e5=WI(),t5=i_(),n5=s_(),r5=Yg(),i5=zg(),a5=Mg(),s5=jg(),o5=_g(),u5=sL(),c5=oL()});var lL=w(tc=>{"use strict";m();T();N();Object.defineProperty(tc,"__esModule",{value:!0});Object.defineProperty(tc,"GraphQLError",{enumerable:!0,get:function(){return j_.GraphQLError}});Object.defineProperty(tc,"formatError",{enumerable:!0,get:function(){return j_.formatError}});Object.defineProperty(tc,"locatedError",{enumerable:!0,get:function(){return d5.locatedError}});Object.defineProperty(tc,"printError",{enumerable:!0,get:function(){return j_.printError}});Object.defineProperty(tc,"syntaxError",{enumerable:!0,get:function(){return l5.syntaxError}});var j_=He(),l5=Nm(),d5=dN()});var G_=w(K_=>{"use strict";m();T();N();Object.defineProperty(K_,"__esModule",{value:!0});K_.getIntrospectionQuery=p5;function p5(e){let t=x({descriptions:!0,specifiedByUrl:!1,directiveIsRepeatable:!1,schemaDescription:!1,inputValueDeprecation:!1,oneOf:!1},e),n=t.descriptions?"description":"",r=t.specifiedByUrl?"specifiedByURL":"",i=t.directiveIsRepeatable?"isRepeatable":"",a=t.schemaDescription?n:"";function o(l){return t.inputValueDeprecation?l:""}let c=t.oneOf?"isOneOf":"";return` query IntrospectionQuery { __schema { ${a} @@ -177,7 +177,7 @@ In some cases, you need to provide options to alter GraphQL's execution behavior } } } - `}});var dL=w($_=>{"use strict";m();T();N();Object.defineProperty($_,"__esModule",{value:!0});$_.getOperationAST=m5;var f5=Pt();function m5(e,t){let n=null;for(let i of e.definitions)if(i.kind===f5.Kind.OPERATION_DEFINITION){var r;if(t==null){if(n)return null;n=i}else if(((r=i.name)===null||r===void 0?void 0:r.value)===t)return i}return n}});var pL=w(Q_=>{"use strict";m();T();N();Object.defineProperty(Q_,"__esModule",{value:!0});Q_.getOperationRootType=N5;var IN=He();function N5(e,t){if(t.operation==="query"){let n=e.getQueryType();if(!n)throw new IN.GraphQLError("Schema does not define the required query root type.",{nodes:t});return n}if(t.operation==="mutation"){let n=e.getMutationType();if(!n)throw new IN.GraphQLError("Schema is not configured for mutations.",{nodes:t});return n}if(t.operation==="subscription"){let n=e.getSubscriptionType();if(!n)throw new IN.GraphQLError("Schema is not configured for subscriptions.",{nodes:t});return n}throw new IN.GraphQLError("Can only have query, mutation and subscription operations.",{nodes:t})}});var fL=w(Y_=>{"use strict";m();T();N();Object.defineProperty(Y_,"__esModule",{value:!0});Y_.introspectionFromSchema=I5;var T5=yr(),E5=Xc(),h5=up(),y5=G_();function I5(e,t){let n=x({specifiedByUrl:!0,directiveIsRepeatable:!0,schemaDescription:!0,inputValueDeprecation:!0,oneOf:!0},t),r=(0,E5.parse)((0,y5.getIntrospectionQuery)(n)),i=(0,h5.executeSync)({schema:e,document:r});return!i.errors&&i.data||(0,T5.invariant)(!1),i.data}});var NL=w(J_=>{"use strict";m();T();N();Object.defineProperty(J_,"__esModule",{value:!0});J_.buildClientSchema=b5;var g5=Lr(),li=Yt(),mL=va(),gN=Ld(),_5=Xc(),di=Ft(),v5=Gr(),wa=Ai(),S5=ba(),O5=Ju(),D5=rp();function b5(e,t){(0,mL.isObjectLike)(e)&&(0,mL.isObjectLike)(e.__schema)||(0,g5.devAssert)(!1,`Invalid or incomplete introspection result. Ensure that you are passing "data" property of introspection response and no "errors" was returned alongside: ${(0,li.inspect)(e)}.`);let n=e.__schema,r=(0,gN.keyValMap)(n.types,X=>X.name,X=>g(X));for(let X of[...S5.specifiedScalarTypes,...wa.introspectionTypes])r[X.name]&&(r[X.name]=X);let i=n.queryType?f(n.queryType):null,a=n.mutationType?f(n.mutationType):null,o=n.subscriptionType?f(n.subscriptionType):null,c=n.directives?n.directives.map(et):[];return new O5.GraphQLSchema({description:n.description,query:i,mutation:a,subscription:o,types:Object.values(r),directives:c,assumeValid:t==null?void 0:t.assumeValid});function l(X){if(X.kind===wa.TypeKind.LIST){let ve=X.ofType;if(!ve)throw new Error("Decorated type deeper than introspection query.");return new di.GraphQLList(l(ve))}if(X.kind===wa.TypeKind.NON_NULL){let ve=X.ofType;if(!ve)throw new Error("Decorated type deeper than introspection query.");let gt=l(ve);return new di.GraphQLNonNull((0,di.assertNullableType)(gt))}return p(X)}function p(X){let ve=X.name;if(!ve)throw new Error(`Unknown type reference: ${(0,li.inspect)(X)}.`);let gt=r[ve];if(!gt)throw new Error(`Invalid or incomplete schema, unknown type: ${ve}. Ensure that a full introspection query is used in order to build a client schema.`);return gt}function f(X){return(0,di.assertObjectType)(p(X))}function y(X){return(0,di.assertInterfaceType)(p(X))}function g(X){if(X!=null&&X.name!=null&&X.kind!=null)switch(X.kind){case wa.TypeKind.SCALAR:return v(X);case wa.TypeKind.OBJECT:return k(X);case wa.TypeKind.INTERFACE:return K(X);case wa.TypeKind.UNION:return $(X);case wa.TypeKind.ENUM:return ne(X);case wa.TypeKind.INPUT_OBJECT:return z(X)}let ve=(0,li.inspect)(X);throw new Error(`Invalid or incomplete introspection result. Ensure that a full introspection query is used in order to build a client schema: ${ve}.`)}function v(X){return new di.GraphQLScalarType({name:X.name,description:X.description,specifiedByURL:X.specifiedByURL})}function F(X){if(X.interfaces===null&&X.kind===wa.TypeKind.INTERFACE)return[];if(!X.interfaces){let ve=(0,li.inspect)(X);throw new Error(`Introspection result missing interfaces: ${ve}.`)}return X.interfaces.map(y)}function k(X){return new di.GraphQLObjectType({name:X.name,description:X.description,interfaces:()=>F(X),fields:()=>Te(X)})}function K(X){return new di.GraphQLInterfaceType({name:X.name,description:X.description,interfaces:()=>F(X),fields:()=>Te(X)})}function $(X){if(!X.possibleTypes){let ve=(0,li.inspect)(X);throw new Error(`Introspection result missing possibleTypes: ${ve}.`)}return new di.GraphQLUnionType({name:X.name,description:X.description,types:()=>X.possibleTypes.map(f)})}function ne(X){if(!X.enumValues){let ve=(0,li.inspect)(X);throw new Error(`Introspection result missing enumValues: ${ve}.`)}return new di.GraphQLEnumType({name:X.name,description:X.description,values:(0,gN.keyValMap)(X.enumValues,ve=>ve.name,ve=>({description:ve.description,deprecationReason:ve.deprecationReason}))})}function z(X){if(!X.inputFields){let ve=(0,li.inspect)(X);throw new Error(`Introspection result missing inputFields: ${ve}.`)}return new di.GraphQLInputObjectType({name:X.name,description:X.description,fields:()=>Fe(X.inputFields),isOneOf:X.isOneOf})}function Te(X){if(!X.fields)throw new Error(`Introspection result missing fields: ${(0,li.inspect)(X)}.`);return(0,gN.keyValMap)(X.fields,ve=>ve.name,pe)}function pe(X){let ve=l(X.type);if(!(0,di.isOutputType)(ve)){let gt=(0,li.inspect)(ve);throw new Error(`Introspection must provide output type for fields, but received: ${gt}.`)}if(!X.args){let gt=(0,li.inspect)(X);throw new Error(`Introspection result missing field args: ${gt}.`)}return{description:X.description,deprecationReason:X.deprecationReason,type:ve,args:Fe(X.args)}}function Fe(X){return(0,gN.keyValMap)(X,ve=>ve.name,Ve)}function Ve(X){let ve=l(X.type);if(!(0,di.isInputType)(ve)){let zt=(0,li.inspect)(ve);throw new Error(`Introspection must provide input type for arguments, but received: ${zt}.`)}let gt=X.defaultValue!=null?(0,D5.valueFromAST)((0,_5.parseValue)(X.defaultValue),ve):void 0;return{description:X.description,type:ve,defaultValue:gt,deprecationReason:X.deprecationReason}}function et(X){if(!X.args){let ve=(0,li.inspect)(X);throw new Error(`Introspection result missing directive args: ${ve}.`)}if(!X.locations){let ve=(0,li.inspect)(X);throw new Error(`Introspection result missing directive locations: ${ve}.`)}return new v5.GraphQLDirective({name:X.name,description:X.description,isRepeatable:X.isRepeatable,locations:X.locations.slice(),args:Fe(X.args)})}}});var z_=w(vN=>{"use strict";m();T();N();Object.defineProperty(vN,"__esModule",{value:!0});vN.extendSchema=L5;vN.extendSchemaImpl=vL;var A5=Lr(),R5=Yt(),P5=yr(),F5=Wo(),pp=Hy(),Li=Pt(),TL=zu(),gn=Ft(),fp=Gr(),gL=Ai(),_L=ba(),EL=Ju(),w5=ll(),H_=ul(),hL=rp();function L5(e,t,n){(0,EL.assertSchema)(e),t!=null&&t.kind===Li.Kind.DOCUMENT||(0,A5.devAssert)(!1,"Must provide valid Document AST."),(n==null?void 0:n.assumeValid)!==!0&&(n==null?void 0:n.assumeValidSDL)!==!0&&(0,w5.assertValidSDLExtension)(t,e);let r=e.toConfig(),i=vL(r,t,n);return r===i?e:new EL.GraphQLSchema(i)}function vL(e,t,n){var r,i,a,o;let c=[],l=Object.create(null),p=[],f,y=[];for(let oe of t.definitions)if(oe.kind===Li.Kind.SCHEMA_DEFINITION)f=oe;else if(oe.kind===Li.Kind.SCHEMA_EXTENSION)y.push(oe);else if((0,TL.isTypeDefinitionNode)(oe))c.push(oe);else if((0,TL.isTypeExtensionNode)(oe)){let De=oe.name.value,_e=l[De];l[De]=_e?_e.concat([oe]):[oe]}else oe.kind===Li.Kind.DIRECTIVE_DEFINITION&&p.push(oe);if(Object.keys(l).length===0&&c.length===0&&p.length===0&&y.length===0&&f==null)return e;let g=Object.create(null);for(let oe of e.types)g[oe.name]=ne(oe);for(let oe of c){var v;let De=oe.name.value;g[De]=(v=yL[De])!==null&&v!==void 0?v:bn(oe)}let F=x(x({query:e.query&&K(e.query),mutation:e.mutation&&K(e.mutation),subscription:e.subscription&&K(e.subscription)},f&>([f])),gt(y));return Y(x({description:(r=f)===null||r===void 0||(i=r.description)===null||i===void 0?void 0:i.value},F),{types:Object.values(g),directives:[...e.directives.map($),...p.map(Dn)],extensions:Object.create(null),astNode:(a=f)!==null&&a!==void 0?a:e.astNode,extensionASTNodes:e.extensionASTNodes.concat(y),assumeValid:(o=n==null?void 0:n.assumeValid)!==null&&o!==void 0?o:!1});function k(oe){return(0,gn.isListType)(oe)?new gn.GraphQLList(k(oe.ofType)):(0,gn.isNonNullType)(oe)?new gn.GraphQLNonNull(k(oe.ofType)):K(oe)}function K(oe){return g[oe.name]}function $(oe){let De=oe.toConfig();return new fp.GraphQLDirective(Y(x({},De),{args:(0,pp.mapValue)(De.args,ve)}))}function ne(oe){if((0,gL.isIntrospectionType)(oe)||(0,_L.isSpecifiedScalarType)(oe))return oe;if((0,gn.isScalarType)(oe))return pe(oe);if((0,gn.isObjectType)(oe))return Fe(oe);if((0,gn.isInterfaceType)(oe))return Ve(oe);if((0,gn.isUnionType)(oe))return et(oe);if((0,gn.isEnumType)(oe))return Te(oe);if((0,gn.isInputObjectType)(oe))return z(oe);(0,P5.invariant)(!1,"Unexpected type: "+(0,R5.inspect)(oe))}function z(oe){var De;let _e=oe.toConfig(),Ce=(De=l[_e.name])!==null&&De!==void 0?De:[];return new gn.GraphQLInputObjectType(Y(x({},_e),{fields:()=>x(x({},(0,pp.mapValue)(_e.fields,_t=>Y(x({},_t),{type:k(_t.type)}))),Ar(Ce)),extensionASTNodes:_e.extensionASTNodes.concat(Ce)}))}function Te(oe){var De;let _e=oe.toConfig(),Ce=(De=l[oe.name])!==null&&De!==void 0?De:[];return new gn.GraphQLEnumType(Y(x({},_e),{values:x(x({},_e.values),Rr(Ce)),extensionASTNodes:_e.extensionASTNodes.concat(Ce)}))}function pe(oe){var De;let _e=oe.toConfig(),Ce=(De=l[_e.name])!==null&&De!==void 0?De:[],_t=_e.specifiedByURL;for(let se of Ce){var J;_t=(J=IL(se))!==null&&J!==void 0?J:_t}return new gn.GraphQLScalarType(Y(x({},_e),{specifiedByURL:_t,extensionASTNodes:_e.extensionASTNodes.concat(Ce)}))}function Fe(oe){var De;let _e=oe.toConfig(),Ce=(De=l[_e.name])!==null&&De!==void 0?De:[];return new gn.GraphQLObjectType(Y(x({},_e),{interfaces:()=>[...oe.getInterfaces().map(K),...Un(Ce)],fields:()=>x(x({},(0,pp.mapValue)(_e.fields,X)),Vt(Ce)),extensionASTNodes:_e.extensionASTNodes.concat(Ce)}))}function Ve(oe){var De;let _e=oe.toConfig(),Ce=(De=l[_e.name])!==null&&De!==void 0?De:[];return new gn.GraphQLInterfaceType(Y(x({},_e),{interfaces:()=>[...oe.getInterfaces().map(K),...Un(Ce)],fields:()=>x(x({},(0,pp.mapValue)(_e.fields,X)),Vt(Ce)),extensionASTNodes:_e.extensionASTNodes.concat(Ce)}))}function et(oe){var De;let _e=oe.toConfig(),Ce=(De=l[_e.name])!==null&&De!==void 0?De:[];return new gn.GraphQLUnionType(Y(x({},_e),{types:()=>[...oe.getTypes().map(K),...$t(Ce)],extensionASTNodes:_e.extensionASTNodes.concat(Ce)}))}function X(oe){return Y(x({},oe),{type:k(oe.type),args:oe.args&&(0,pp.mapValue)(oe.args,ve)})}function ve(oe){return Y(x({},oe),{type:k(oe.type)})}function gt(oe){let De={};for(let Ce of oe){var _e;let _t=(_e=Ce.operationTypes)!==null&&_e!==void 0?_e:[];for(let J of _t)De[J.operation]=zt(J.type)}return De}function zt(oe){var De;let _e=oe.name.value,Ce=(De=yL[_e])!==null&&De!==void 0?De:g[_e];if(Ce===void 0)throw new Error(`Unknown type: "${_e}".`);return Ce}function Wt(oe){return oe.kind===Li.Kind.LIST_TYPE?new gn.GraphQLList(Wt(oe.type)):oe.kind===Li.Kind.NON_NULL_TYPE?new gn.GraphQLNonNull(Wt(oe.type)):zt(oe)}function Dn(oe){var De;return new fp.GraphQLDirective({name:oe.name.value,description:(De=oe.description)===null||De===void 0?void 0:De.value,locations:oe.locations.map(({value:_e})=>_e),isRepeatable:oe.repeatable,args:dn(oe.arguments),astNode:oe})}function Vt(oe){let De=Object.create(null);for(let _t of oe){var _e;let J=(_e=_t.fields)!==null&&_e!==void 0?_e:[];for(let se of J){var Ce;De[se.name.value]={type:Wt(se.type),description:(Ce=se.description)===null||Ce===void 0?void 0:Ce.value,args:dn(se.arguments),deprecationReason:_N(se),astNode:se}}}return De}function dn(oe){let De=oe!=null?oe:[],_e=Object.create(null);for(let _t of De){var Ce;let J=Wt(_t.type);_e[_t.name.value]={type:J,description:(Ce=_t.description)===null||Ce===void 0?void 0:Ce.value,defaultValue:(0,hL.valueFromAST)(_t.defaultValue,J),deprecationReason:_N(_t),astNode:_t}}return _e}function Ar(oe){let De=Object.create(null);for(let _t of oe){var _e;let J=(_e=_t.fields)!==null&&_e!==void 0?_e:[];for(let se of J){var Ce;let xe=Wt(se.type);De[se.name.value]={type:xe,description:(Ce=se.description)===null||Ce===void 0?void 0:Ce.value,defaultValue:(0,hL.valueFromAST)(se.defaultValue,xe),deprecationReason:_N(se),astNode:se}}}return De}function Rr(oe){let De=Object.create(null);for(let _t of oe){var _e;let J=(_e=_t.values)!==null&&_e!==void 0?_e:[];for(let se of J){var Ce;De[se.name.value]={description:(Ce=se.description)===null||Ce===void 0?void 0:Ce.value,deprecationReason:_N(se),astNode:se}}}return De}function Un(oe){return oe.flatMap(De=>{var _e,Ce;return(_e=(Ce=De.interfaces)===null||Ce===void 0?void 0:Ce.map(zt))!==null&&_e!==void 0?_e:[]})}function $t(oe){return oe.flatMap(De=>{var _e,Ce;return(_e=(Ce=De.types)===null||Ce===void 0?void 0:Ce.map(zt))!==null&&_e!==void 0?_e:[]})}function bn(oe){var De;let _e=oe.name.value,Ce=(De=l[_e])!==null&&De!==void 0?De:[];switch(oe.kind){case Li.Kind.OBJECT_TYPE_DEFINITION:{var _t;let tt=[oe,...Ce];return new gn.GraphQLObjectType({name:_e,description:(_t=oe.description)===null||_t===void 0?void 0:_t.value,interfaces:()=>Un(tt),fields:()=>Vt(tt),astNode:oe,extensionASTNodes:Ce})}case Li.Kind.INTERFACE_TYPE_DEFINITION:{var J;let tt=[oe,...Ce];return new gn.GraphQLInterfaceType({name:_e,description:(J=oe.description)===null||J===void 0?void 0:J.value,interfaces:()=>Un(tt),fields:()=>Vt(tt),astNode:oe,extensionASTNodes:Ce})}case Li.Kind.ENUM_TYPE_DEFINITION:{var se;let tt=[oe,...Ce];return new gn.GraphQLEnumType({name:_e,description:(se=oe.description)===null||se===void 0?void 0:se.value,values:Rr(tt),astNode:oe,extensionASTNodes:Ce})}case Li.Kind.UNION_TYPE_DEFINITION:{var xe;let tt=[oe,...Ce];return new gn.GraphQLUnionType({name:_e,description:(xe=oe.description)===null||xe===void 0?void 0:xe.value,types:()=>$t(tt),astNode:oe,extensionASTNodes:Ce})}case Li.Kind.SCALAR_TYPE_DEFINITION:{var Qe;return new gn.GraphQLScalarType({name:_e,description:(Qe=oe.description)===null||Qe===void 0?void 0:Qe.value,specifiedByURL:IL(oe),astNode:oe,extensionASTNodes:Ce})}case Li.Kind.INPUT_OBJECT_TYPE_DEFINITION:{var Lt;let tt=[oe,...Ce];return new gn.GraphQLInputObjectType({name:_e,description:(Lt=oe.description)===null||Lt===void 0?void 0:Lt.value,fields:()=>Ar(tt),astNode:oe,extensionASTNodes:Ce,isOneOf:C5(oe)})}}}}var yL=(0,F5.keyMap)([..._L.specifiedScalarTypes,...gL.introspectionTypes],e=>e.name);function _N(e){let t=(0,H_.getDirectiveValues)(fp.GraphQLDeprecatedDirective,e);return t==null?void 0:t.reason}function IL(e){let t=(0,H_.getDirectiveValues)(fp.GraphQLSpecifiedByDirective,e);return t==null?void 0:t.url}function C5(e){return!!(0,H_.getDirectiveValues)(fp.GraphQLOneOfDirective,e)}});var OL=w(SN=>{"use strict";m();T();N();Object.defineProperty(SN,"__esModule",{value:!0});SN.buildASTSchema=SL;SN.buildSchema=j5;var B5=Lr(),U5=Pt(),k5=Xc(),M5=Gr(),x5=Ju(),q5=ll(),V5=z_();function SL(e,t){e!=null&&e.kind===U5.Kind.DOCUMENT||(0,B5.devAssert)(!1,"Must provide valid Document AST."),(t==null?void 0:t.assumeValid)!==!0&&(t==null?void 0:t.assumeValidSDL)!==!0&&(0,q5.assertValidSDL)(e);let n={description:void 0,types:[],directives:[],extensions:Object.create(null),extensionASTNodes:[],assumeValid:!1},r=(0,V5.extendSchemaImpl)(n,e,t);if(r.astNode==null)for(let a of r.types)switch(a.name){case"Query":r.query=a;break;case"Mutation":r.mutation=a;break;case"Subscription":r.subscription=a;break}let i=[...r.directives,...M5.specifiedDirectives.filter(a=>r.directives.every(o=>o.name!==a.name))];return new x5.GraphQLSchema(Y(x({},r),{directives:i}))}function j5(e,t){let n=(0,k5.parse)(e,{noLocation:t==null?void 0:t.noLocation,allowLegacyFragmentVariables:t==null?void 0:t.allowLegacyFragmentVariables});return SL(n,{assumeValidSDL:t==null?void 0:t.assumeValidSDL,assumeValid:t==null?void 0:t.assumeValid})}});var AL=w(X_=>{"use strict";m();T();N();Object.defineProperty(X_,"__esModule",{value:!0});X_.lexicographicSortSchema=H5;var K5=Yt(),G5=yr(),$5=Ld(),DL=Cd(),Cr=Ft(),Q5=Gr(),Y5=Ai(),J5=Ju();function H5(e){let t=e.toConfig(),n=(0,$5.keyValMap)(W_(t.types),g=>g.name,y);return new J5.GraphQLSchema(Y(x({},t),{types:Object.values(n),directives:W_(t.directives).map(o),query:a(t.query),mutation:a(t.mutation),subscription:a(t.subscription)}));function r(g){return(0,Cr.isListType)(g)?new Cr.GraphQLList(r(g.ofType)):(0,Cr.isNonNullType)(g)?new Cr.GraphQLNonNull(r(g.ofType)):i(g)}function i(g){return n[g.name]}function a(g){return g&&i(g)}function o(g){let v=g.toConfig();return new Q5.GraphQLDirective(Y(x({},v),{locations:bL(v.locations,F=>F),args:c(v.args)}))}function c(g){return ON(g,v=>Y(x({},v),{type:r(v.type)}))}function l(g){return ON(g,v=>Y(x({},v),{type:r(v.type),args:v.args&&c(v.args)}))}function p(g){return ON(g,v=>Y(x({},v),{type:r(v.type)}))}function f(g){return W_(g).map(i)}function y(g){if((0,Cr.isScalarType)(g)||(0,Y5.isIntrospectionType)(g))return g;if((0,Cr.isObjectType)(g)){let v=g.toConfig();return new Cr.GraphQLObjectType(Y(x({},v),{interfaces:()=>f(v.interfaces),fields:()=>l(v.fields)}))}if((0,Cr.isInterfaceType)(g)){let v=g.toConfig();return new Cr.GraphQLInterfaceType(Y(x({},v),{interfaces:()=>f(v.interfaces),fields:()=>l(v.fields)}))}if((0,Cr.isUnionType)(g)){let v=g.toConfig();return new Cr.GraphQLUnionType(Y(x({},v),{types:()=>f(v.types)}))}if((0,Cr.isEnumType)(g)){let v=g.toConfig();return new Cr.GraphQLEnumType(Y(x({},v),{values:ON(v.values,F=>F)}))}if((0,Cr.isInputObjectType)(g)){let v=g.toConfig();return new Cr.GraphQLInputObjectType(Y(x({},v),{fields:()=>p(v.fields)}))}(0,G5.invariant)(!1,"Unexpected type: "+(0,K5.inspect)(g))}}function ON(e,t){let n=Object.create(null);for(let r of Object.keys(e).sort(DL.naturalCompare))n[r]=t(e[r]);return n}function W_(e){return bL(e,t=>t.name)}function bL(e,t){return e.slice().sort((n,r)=>{let i=t(n),a=t(r);return(0,DL.naturalCompare)(i,a)})}});var BL=w(mp=>{"use strict";m();T();N();Object.defineProperty(mp,"__esModule",{value:!0});mp.printIntrospectionSchema=nX;mp.printSchema=tX;mp.printType=FL;var z5=Yt(),W5=yr(),X5=Od(),ev=Pt(),DN=ci(),pl=Ft(),tv=Gr(),RL=Ai(),Z5=ba(),eX=Yd();function tX(e){return PL(e,t=>!(0,tv.isSpecifiedDirective)(t),rX)}function nX(e){return PL(e,tv.isSpecifiedDirective,RL.isIntrospectionType)}function rX(e){return!(0,Z5.isSpecifiedScalarType)(e)&&!(0,RL.isIntrospectionType)(e)}function PL(e,t,n){let r=e.getDirectives().filter(t),i=Object.values(e.getTypeMap()).filter(n);return[iX(e),...r.map(a=>pX(a)),...i.map(a=>FL(a))].filter(Boolean).join(` + `}});var dL=w($_=>{"use strict";m();T();N();Object.defineProperty($_,"__esModule",{value:!0});$_.getOperationAST=m5;var f5=Pt();function m5(e,t){let n=null;for(let i of e.definitions)if(i.kind===f5.Kind.OPERATION_DEFINITION){var r;if(t==null){if(n)return null;n=i}else if(((r=i.name)===null||r===void 0?void 0:r.value)===t)return i}return n}});var pL=w(Q_=>{"use strict";m();T();N();Object.defineProperty(Q_,"__esModule",{value:!0});Q_.getOperationRootType=N5;var IN=He();function N5(e,t){if(t.operation==="query"){let n=e.getQueryType();if(!n)throw new IN.GraphQLError("Schema does not define the required query root type.",{nodes:t});return n}if(t.operation==="mutation"){let n=e.getMutationType();if(!n)throw new IN.GraphQLError("Schema is not configured for mutations.",{nodes:t});return n}if(t.operation==="subscription"){let n=e.getSubscriptionType();if(!n)throw new IN.GraphQLError("Schema is not configured for subscriptions.",{nodes:t});return n}throw new IN.GraphQLError("Can only have query, mutation and subscription operations.",{nodes:t})}});var fL=w(Y_=>{"use strict";m();T();N();Object.defineProperty(Y_,"__esModule",{value:!0});Y_.introspectionFromSchema=I5;var T5=yr(),E5=Xc(),h5=up(),y5=G_();function I5(e,t){let n=x({specifiedByUrl:!0,directiveIsRepeatable:!0,schemaDescription:!0,inputValueDeprecation:!0,oneOf:!0},t),r=(0,E5.parse)((0,y5.getIntrospectionQuery)(n)),i=(0,h5.executeSync)({schema:e,document:r});return!i.errors&&i.data||(0,T5.invariant)(!1),i.data}});var NL=w(J_=>{"use strict";m();T();N();Object.defineProperty(J_,"__esModule",{value:!0});J_.buildClientSchema=b5;var g5=Lr(),li=Yt(),mL=va(),gN=Ld(),_5=Xc(),di=Ft(),v5=Gr(),wa=Ai(),S5=ba(),O5=Ju(),D5=rp();function b5(e,t){(0,mL.isObjectLike)(e)&&(0,mL.isObjectLike)(e.__schema)||(0,g5.devAssert)(!1,`Invalid or incomplete introspection result. Ensure that you are passing "data" property of introspection response and no "errors" was returned alongside: ${(0,li.inspect)(e)}.`);let n=e.__schema,r=(0,gN.keyValMap)(n.types,X=>X.name,X=>g(X));for(let X of[...S5.specifiedScalarTypes,...wa.introspectionTypes])r[X.name]&&(r[X.name]=X);let i=n.queryType?f(n.queryType):null,a=n.mutationType?f(n.mutationType):null,o=n.subscriptionType?f(n.subscriptionType):null,c=n.directives?n.directives.map(et):[];return new O5.GraphQLSchema({description:n.description,query:i,mutation:a,subscription:o,types:Object.values(r),directives:c,assumeValid:t==null?void 0:t.assumeValid});function l(X){if(X.kind===wa.TypeKind.LIST){let ve=X.ofType;if(!ve)throw new Error("Decorated type deeper than introspection query.");return new di.GraphQLList(l(ve))}if(X.kind===wa.TypeKind.NON_NULL){let ve=X.ofType;if(!ve)throw new Error("Decorated type deeper than introspection query.");let gt=l(ve);return new di.GraphQLNonNull((0,di.assertNullableType)(gt))}return p(X)}function p(X){let ve=X.name;if(!ve)throw new Error(`Unknown type reference: ${(0,li.inspect)(X)}.`);let gt=r[ve];if(!gt)throw new Error(`Invalid or incomplete schema, unknown type: ${ve}. Ensure that a full introspection query is used in order to build a client schema.`);return gt}function f(X){return(0,di.assertObjectType)(p(X))}function y(X){return(0,di.assertInterfaceType)(p(X))}function g(X){if(X!=null&&X.name!=null&&X.kind!=null)switch(X.kind){case wa.TypeKind.SCALAR:return v(X);case wa.TypeKind.OBJECT:return U(X);case wa.TypeKind.INTERFACE:return K(X);case wa.TypeKind.UNION:return $(X);case wa.TypeKind.ENUM:return ne(X);case wa.TypeKind.INPUT_OBJECT:return z(X)}let ve=(0,li.inspect)(X);throw new Error(`Invalid or incomplete introspection result. Ensure that a full introspection query is used in order to build a client schema: ${ve}.`)}function v(X){return new di.GraphQLScalarType({name:X.name,description:X.description,specifiedByURL:X.specifiedByURL})}function P(X){if(X.interfaces===null&&X.kind===wa.TypeKind.INTERFACE)return[];if(!X.interfaces){let ve=(0,li.inspect)(X);throw new Error(`Introspection result missing interfaces: ${ve}.`)}return X.interfaces.map(y)}function U(X){return new di.GraphQLObjectType({name:X.name,description:X.description,interfaces:()=>P(X),fields:()=>Te(X)})}function K(X){return new di.GraphQLInterfaceType({name:X.name,description:X.description,interfaces:()=>P(X),fields:()=>Te(X)})}function $(X){if(!X.possibleTypes){let ve=(0,li.inspect)(X);throw new Error(`Introspection result missing possibleTypes: ${ve}.`)}return new di.GraphQLUnionType({name:X.name,description:X.description,types:()=>X.possibleTypes.map(f)})}function ne(X){if(!X.enumValues){let ve=(0,li.inspect)(X);throw new Error(`Introspection result missing enumValues: ${ve}.`)}return new di.GraphQLEnumType({name:X.name,description:X.description,values:(0,gN.keyValMap)(X.enumValues,ve=>ve.name,ve=>({description:ve.description,deprecationReason:ve.deprecationReason}))})}function z(X){if(!X.inputFields){let ve=(0,li.inspect)(X);throw new Error(`Introspection result missing inputFields: ${ve}.`)}return new di.GraphQLInputObjectType({name:X.name,description:X.description,fields:()=>Fe(X.inputFields),isOneOf:X.isOneOf})}function Te(X){if(!X.fields)throw new Error(`Introspection result missing fields: ${(0,li.inspect)(X)}.`);return(0,gN.keyValMap)(X.fields,ve=>ve.name,pe)}function pe(X){let ve=l(X.type);if(!(0,di.isOutputType)(ve)){let gt=(0,li.inspect)(ve);throw new Error(`Introspection must provide output type for fields, but received: ${gt}.`)}if(!X.args){let gt=(0,li.inspect)(X);throw new Error(`Introspection result missing field args: ${gt}.`)}return{description:X.description,deprecationReason:X.deprecationReason,type:ve,args:Fe(X.args)}}function Fe(X){return(0,gN.keyValMap)(X,ve=>ve.name,xe)}function xe(X){let ve=l(X.type);if(!(0,di.isInputType)(ve)){let zt=(0,li.inspect)(ve);throw new Error(`Introspection must provide input type for arguments, but received: ${zt}.`)}let gt=X.defaultValue!=null?(0,D5.valueFromAST)((0,_5.parseValue)(X.defaultValue),ve):void 0;return{description:X.description,type:ve,defaultValue:gt,deprecationReason:X.deprecationReason}}function et(X){if(!X.args){let ve=(0,li.inspect)(X);throw new Error(`Introspection result missing directive args: ${ve}.`)}if(!X.locations){let ve=(0,li.inspect)(X);throw new Error(`Introspection result missing directive locations: ${ve}.`)}return new v5.GraphQLDirective({name:X.name,description:X.description,isRepeatable:X.isRepeatable,locations:X.locations.slice(),args:Fe(X.args)})}}});var z_=w(vN=>{"use strict";m();T();N();Object.defineProperty(vN,"__esModule",{value:!0});vN.extendSchema=L5;vN.extendSchemaImpl=vL;var A5=Lr(),R5=Yt(),P5=yr(),F5=Wo(),pp=Hy(),Li=Pt(),TL=zu(),gn=Ft(),fp=Gr(),gL=Ai(),_L=ba(),EL=Ju(),w5=ll(),H_=ul(),hL=rp();function L5(e,t,n){(0,EL.assertSchema)(e),t!=null&&t.kind===Li.Kind.DOCUMENT||(0,A5.devAssert)(!1,"Must provide valid Document AST."),(n==null?void 0:n.assumeValid)!==!0&&(n==null?void 0:n.assumeValidSDL)!==!0&&(0,w5.assertValidSDLExtension)(t,e);let r=e.toConfig(),i=vL(r,t,n);return r===i?e:new EL.GraphQLSchema(i)}function vL(e,t,n){var r,i,a,o;let c=[],l=Object.create(null),p=[],f,y=[];for(let oe of t.definitions)if(oe.kind===Li.Kind.SCHEMA_DEFINITION)f=oe;else if(oe.kind===Li.Kind.SCHEMA_EXTENSION)y.push(oe);else if((0,TL.isTypeDefinitionNode)(oe))c.push(oe);else if((0,TL.isTypeExtensionNode)(oe)){let De=oe.name.value,_e=l[De];l[De]=_e?_e.concat([oe]):[oe]}else oe.kind===Li.Kind.DIRECTIVE_DEFINITION&&p.push(oe);if(Object.keys(l).length===0&&c.length===0&&p.length===0&&y.length===0&&f==null)return e;let g=Object.create(null);for(let oe of e.types)g[oe.name]=ne(oe);for(let oe of c){var v;let De=oe.name.value;g[De]=(v=yL[De])!==null&&v!==void 0?v:bn(oe)}let P=x(x({query:e.query&&K(e.query),mutation:e.mutation&&K(e.mutation),subscription:e.subscription&&K(e.subscription)},f&>([f])),gt(y));return Y(x({description:(r=f)===null||r===void 0||(i=r.description)===null||i===void 0?void 0:i.value},P),{types:Object.values(g),directives:[...e.directives.map($),...p.map(Dn)],extensions:Object.create(null),astNode:(a=f)!==null&&a!==void 0?a:e.astNode,extensionASTNodes:e.extensionASTNodes.concat(y),assumeValid:(o=n==null?void 0:n.assumeValid)!==null&&o!==void 0?o:!1});function U(oe){return(0,gn.isListType)(oe)?new gn.GraphQLList(U(oe.ofType)):(0,gn.isNonNullType)(oe)?new gn.GraphQLNonNull(U(oe.ofType)):K(oe)}function K(oe){return g[oe.name]}function $(oe){let De=oe.toConfig();return new fp.GraphQLDirective(Y(x({},De),{args:(0,pp.mapValue)(De.args,ve)}))}function ne(oe){if((0,gL.isIntrospectionType)(oe)||(0,_L.isSpecifiedScalarType)(oe))return oe;if((0,gn.isScalarType)(oe))return pe(oe);if((0,gn.isObjectType)(oe))return Fe(oe);if((0,gn.isInterfaceType)(oe))return xe(oe);if((0,gn.isUnionType)(oe))return et(oe);if((0,gn.isEnumType)(oe))return Te(oe);if((0,gn.isInputObjectType)(oe))return z(oe);(0,P5.invariant)(!1,"Unexpected type: "+(0,R5.inspect)(oe))}function z(oe){var De;let _e=oe.toConfig(),Ce=(De=l[_e.name])!==null&&De!==void 0?De:[];return new gn.GraphQLInputObjectType(Y(x({},_e),{fields:()=>x(x({},(0,pp.mapValue)(_e.fields,_t=>Y(x({},_t),{type:U(_t.type)}))),Ar(Ce)),extensionASTNodes:_e.extensionASTNodes.concat(Ce)}))}function Te(oe){var De;let _e=oe.toConfig(),Ce=(De=l[oe.name])!==null&&De!==void 0?De:[];return new gn.GraphQLEnumType(Y(x({},_e),{values:x(x({},_e.values),Rr(Ce)),extensionASTNodes:_e.extensionASTNodes.concat(Ce)}))}function pe(oe){var De;let _e=oe.toConfig(),Ce=(De=l[_e.name])!==null&&De!==void 0?De:[],_t=_e.specifiedByURL;for(let se of Ce){var J;_t=(J=IL(se))!==null&&J!==void 0?J:_t}return new gn.GraphQLScalarType(Y(x({},_e),{specifiedByURL:_t,extensionASTNodes:_e.extensionASTNodes.concat(Ce)}))}function Fe(oe){var De;let _e=oe.toConfig(),Ce=(De=l[_e.name])!==null&&De!==void 0?De:[];return new gn.GraphQLObjectType(Y(x({},_e),{interfaces:()=>[...oe.getInterfaces().map(K),...Un(Ce)],fields:()=>x(x({},(0,pp.mapValue)(_e.fields,X)),Vt(Ce)),extensionASTNodes:_e.extensionASTNodes.concat(Ce)}))}function xe(oe){var De;let _e=oe.toConfig(),Ce=(De=l[_e.name])!==null&&De!==void 0?De:[];return new gn.GraphQLInterfaceType(Y(x({},_e),{interfaces:()=>[...oe.getInterfaces().map(K),...Un(Ce)],fields:()=>x(x({},(0,pp.mapValue)(_e.fields,X)),Vt(Ce)),extensionASTNodes:_e.extensionASTNodes.concat(Ce)}))}function et(oe){var De;let _e=oe.toConfig(),Ce=(De=l[_e.name])!==null&&De!==void 0?De:[];return new gn.GraphQLUnionType(Y(x({},_e),{types:()=>[...oe.getTypes().map(K),...$t(Ce)],extensionASTNodes:_e.extensionASTNodes.concat(Ce)}))}function X(oe){return Y(x({},oe),{type:U(oe.type),args:oe.args&&(0,pp.mapValue)(oe.args,ve)})}function ve(oe){return Y(x({},oe),{type:U(oe.type)})}function gt(oe){let De={};for(let Ce of oe){var _e;let _t=(_e=Ce.operationTypes)!==null&&_e!==void 0?_e:[];for(let J of _t)De[J.operation]=zt(J.type)}return De}function zt(oe){var De;let _e=oe.name.value,Ce=(De=yL[_e])!==null&&De!==void 0?De:g[_e];if(Ce===void 0)throw new Error(`Unknown type: "${_e}".`);return Ce}function Wt(oe){return oe.kind===Li.Kind.LIST_TYPE?new gn.GraphQLList(Wt(oe.type)):oe.kind===Li.Kind.NON_NULL_TYPE?new gn.GraphQLNonNull(Wt(oe.type)):zt(oe)}function Dn(oe){var De;return new fp.GraphQLDirective({name:oe.name.value,description:(De=oe.description)===null||De===void 0?void 0:De.value,locations:oe.locations.map(({value:_e})=>_e),isRepeatable:oe.repeatable,args:dn(oe.arguments),astNode:oe})}function Vt(oe){let De=Object.create(null);for(let _t of oe){var _e;let J=(_e=_t.fields)!==null&&_e!==void 0?_e:[];for(let se of J){var Ce;De[se.name.value]={type:Wt(se.type),description:(Ce=se.description)===null||Ce===void 0?void 0:Ce.value,args:dn(se.arguments),deprecationReason:_N(se),astNode:se}}}return De}function dn(oe){let De=oe!=null?oe:[],_e=Object.create(null);for(let _t of De){var Ce;let J=Wt(_t.type);_e[_t.name.value]={type:J,description:(Ce=_t.description)===null||Ce===void 0?void 0:Ce.value,defaultValue:(0,hL.valueFromAST)(_t.defaultValue,J),deprecationReason:_N(_t),astNode:_t}}return _e}function Ar(oe){let De=Object.create(null);for(let _t of oe){var _e;let J=(_e=_t.fields)!==null&&_e!==void 0?_e:[];for(let se of J){var Ce;let qe=Wt(se.type);De[se.name.value]={type:qe,description:(Ce=se.description)===null||Ce===void 0?void 0:Ce.value,defaultValue:(0,hL.valueFromAST)(se.defaultValue,qe),deprecationReason:_N(se),astNode:se}}}return De}function Rr(oe){let De=Object.create(null);for(let _t of oe){var _e;let J=(_e=_t.values)!==null&&_e!==void 0?_e:[];for(let se of J){var Ce;De[se.name.value]={description:(Ce=se.description)===null||Ce===void 0?void 0:Ce.value,deprecationReason:_N(se),astNode:se}}}return De}function Un(oe){return oe.flatMap(De=>{var _e,Ce;return(_e=(Ce=De.interfaces)===null||Ce===void 0?void 0:Ce.map(zt))!==null&&_e!==void 0?_e:[]})}function $t(oe){return oe.flatMap(De=>{var _e,Ce;return(_e=(Ce=De.types)===null||Ce===void 0?void 0:Ce.map(zt))!==null&&_e!==void 0?_e:[]})}function bn(oe){var De;let _e=oe.name.value,Ce=(De=l[_e])!==null&&De!==void 0?De:[];switch(oe.kind){case Li.Kind.OBJECT_TYPE_DEFINITION:{var _t;let tt=[oe,...Ce];return new gn.GraphQLObjectType({name:_e,description:(_t=oe.description)===null||_t===void 0?void 0:_t.value,interfaces:()=>Un(tt),fields:()=>Vt(tt),astNode:oe,extensionASTNodes:Ce})}case Li.Kind.INTERFACE_TYPE_DEFINITION:{var J;let tt=[oe,...Ce];return new gn.GraphQLInterfaceType({name:_e,description:(J=oe.description)===null||J===void 0?void 0:J.value,interfaces:()=>Un(tt),fields:()=>Vt(tt),astNode:oe,extensionASTNodes:Ce})}case Li.Kind.ENUM_TYPE_DEFINITION:{var se;let tt=[oe,...Ce];return new gn.GraphQLEnumType({name:_e,description:(se=oe.description)===null||se===void 0?void 0:se.value,values:Rr(tt),astNode:oe,extensionASTNodes:Ce})}case Li.Kind.UNION_TYPE_DEFINITION:{var qe;let tt=[oe,...Ce];return new gn.GraphQLUnionType({name:_e,description:(qe=oe.description)===null||qe===void 0?void 0:qe.value,types:()=>$t(tt),astNode:oe,extensionASTNodes:Ce})}case Li.Kind.SCALAR_TYPE_DEFINITION:{var Qe;return new gn.GraphQLScalarType({name:_e,description:(Qe=oe.description)===null||Qe===void 0?void 0:Qe.value,specifiedByURL:IL(oe),astNode:oe,extensionASTNodes:Ce})}case Li.Kind.INPUT_OBJECT_TYPE_DEFINITION:{var Lt;let tt=[oe,...Ce];return new gn.GraphQLInputObjectType({name:_e,description:(Lt=oe.description)===null||Lt===void 0?void 0:Lt.value,fields:()=>Ar(tt),astNode:oe,extensionASTNodes:Ce,isOneOf:C5(oe)})}}}}var yL=(0,F5.keyMap)([..._L.specifiedScalarTypes,...gL.introspectionTypes],e=>e.name);function _N(e){let t=(0,H_.getDirectiveValues)(fp.GraphQLDeprecatedDirective,e);return t==null?void 0:t.reason}function IL(e){let t=(0,H_.getDirectiveValues)(fp.GraphQLSpecifiedByDirective,e);return t==null?void 0:t.url}function C5(e){return!!(0,H_.getDirectiveValues)(fp.GraphQLOneOfDirective,e)}});var OL=w(SN=>{"use strict";m();T();N();Object.defineProperty(SN,"__esModule",{value:!0});SN.buildASTSchema=SL;SN.buildSchema=j5;var B5=Lr(),U5=Pt(),k5=Xc(),M5=Gr(),x5=Ju(),q5=ll(),V5=z_();function SL(e,t){e!=null&&e.kind===U5.Kind.DOCUMENT||(0,B5.devAssert)(!1,"Must provide valid Document AST."),(t==null?void 0:t.assumeValid)!==!0&&(t==null?void 0:t.assumeValidSDL)!==!0&&(0,q5.assertValidSDL)(e);let n={description:void 0,types:[],directives:[],extensions:Object.create(null),extensionASTNodes:[],assumeValid:!1},r=(0,V5.extendSchemaImpl)(n,e,t);if(r.astNode==null)for(let a of r.types)switch(a.name){case"Query":r.query=a;break;case"Mutation":r.mutation=a;break;case"Subscription":r.subscription=a;break}let i=[...r.directives,...M5.specifiedDirectives.filter(a=>r.directives.every(o=>o.name!==a.name))];return new x5.GraphQLSchema(Y(x({},r),{directives:i}))}function j5(e,t){let n=(0,k5.parse)(e,{noLocation:t==null?void 0:t.noLocation,allowLegacyFragmentVariables:t==null?void 0:t.allowLegacyFragmentVariables});return SL(n,{assumeValidSDL:t==null?void 0:t.assumeValidSDL,assumeValid:t==null?void 0:t.assumeValid})}});var AL=w(X_=>{"use strict";m();T();N();Object.defineProperty(X_,"__esModule",{value:!0});X_.lexicographicSortSchema=H5;var K5=Yt(),G5=yr(),$5=Ld(),DL=Cd(),Cr=Ft(),Q5=Gr(),Y5=Ai(),J5=Ju();function H5(e){let t=e.toConfig(),n=(0,$5.keyValMap)(W_(t.types),g=>g.name,y);return new J5.GraphQLSchema(Y(x({},t),{types:Object.values(n),directives:W_(t.directives).map(o),query:a(t.query),mutation:a(t.mutation),subscription:a(t.subscription)}));function r(g){return(0,Cr.isListType)(g)?new Cr.GraphQLList(r(g.ofType)):(0,Cr.isNonNullType)(g)?new Cr.GraphQLNonNull(r(g.ofType)):i(g)}function i(g){return n[g.name]}function a(g){return g&&i(g)}function o(g){let v=g.toConfig();return new Q5.GraphQLDirective(Y(x({},v),{locations:bL(v.locations,P=>P),args:c(v.args)}))}function c(g){return ON(g,v=>Y(x({},v),{type:r(v.type)}))}function l(g){return ON(g,v=>Y(x({},v),{type:r(v.type),args:v.args&&c(v.args)}))}function p(g){return ON(g,v=>Y(x({},v),{type:r(v.type)}))}function f(g){return W_(g).map(i)}function y(g){if((0,Cr.isScalarType)(g)||(0,Y5.isIntrospectionType)(g))return g;if((0,Cr.isObjectType)(g)){let v=g.toConfig();return new Cr.GraphQLObjectType(Y(x({},v),{interfaces:()=>f(v.interfaces),fields:()=>l(v.fields)}))}if((0,Cr.isInterfaceType)(g)){let v=g.toConfig();return new Cr.GraphQLInterfaceType(Y(x({},v),{interfaces:()=>f(v.interfaces),fields:()=>l(v.fields)}))}if((0,Cr.isUnionType)(g)){let v=g.toConfig();return new Cr.GraphQLUnionType(Y(x({},v),{types:()=>f(v.types)}))}if((0,Cr.isEnumType)(g)){let v=g.toConfig();return new Cr.GraphQLEnumType(Y(x({},v),{values:ON(v.values,P=>P)}))}if((0,Cr.isInputObjectType)(g)){let v=g.toConfig();return new Cr.GraphQLInputObjectType(Y(x({},v),{fields:()=>p(v.fields)}))}(0,G5.invariant)(!1,"Unexpected type: "+(0,K5.inspect)(g))}}function ON(e,t){let n=Object.create(null);for(let r of Object.keys(e).sort(DL.naturalCompare))n[r]=t(e[r]);return n}function W_(e){return bL(e,t=>t.name)}function bL(e,t){return e.slice().sort((n,r)=>{let i=t(n),a=t(r);return(0,DL.naturalCompare)(i,a)})}});var BL=w(mp=>{"use strict";m();T();N();Object.defineProperty(mp,"__esModule",{value:!0});mp.printIntrospectionSchema=nX;mp.printSchema=tX;mp.printType=FL;var z5=Yt(),W5=yr(),X5=Od(),ev=Pt(),DN=ci(),pl=Ft(),tv=Gr(),RL=Ai(),Z5=ba(),eX=Yd();function tX(e){return PL(e,t=>!(0,tv.isSpecifiedDirective)(t),rX)}function nX(e){return PL(e,tv.isSpecifiedDirective,RL.isIntrospectionType)}function rX(e){return!(0,Z5.isSpecifiedScalarType)(e)&&!(0,RL.isIntrospectionType)(e)}function PL(e,t,n){let r=e.getDirectives().filter(t),i=Object.values(e.getTypeMap()).filter(n);return[iX(e),...r.map(a=>pX(a)),...i.map(a=>FL(a))].filter(Boolean).join(` `)}function iX(e){if(e.description==null&&aX(e))return;let t=[],n=e.getQueryType();n&&t.push(` query: ${n.name}`);let r=e.getMutationType();r&&t.push(` mutation: ${r.name}`);let i=e.getSubscriptionType();return i&&t.push(` subscription: ${i.name}`),Ci(e)+`schema { ${t.join(` @@ -191,13 +191,13 @@ ${t.join(` `+t+")"}function Z_(e){let t=(0,eX.astFromValue)(e.defaultValue,e.type),n=e.name+": "+String(e.type);return t&&(n+=` = ${(0,DN.print)(t)}`),n+rv(e.deprecationReason)}function pX(e){return Ci(e)+"directive @"+e.name+CL(e.args)+(e.isRepeatable?" repeatable":"")+" on "+e.locations.join(" | ")}function rv(e){return e==null?"":e!==tv.DEFAULT_DEPRECATION_REASON?` @deprecated(reason: ${(0,DN.print)({kind:ev.Kind.STRING,value:e})})`:" @deprecated"}function fX(e){return e.specifiedByURL==null?"":` @specifiedBy(url: ${(0,DN.print)({kind:ev.Kind.STRING,value:e.specifiedByURL})})`}function Ci(e,t="",n=!0){let{description:r}=e;if(r==null)return"";let i=(0,DN.print)({kind:ev.Kind.STRING,value:r,block:(0,X5.isPrintableAsBlockString)(r)});return(t&&!n?` `+t:t)+i.replace(/\n/g,` `+t)+` -`}});var UL=w(iv=>{"use strict";m();T();N();Object.defineProperty(iv,"__esModule",{value:!0});iv.concatAST=NX;var mX=Pt();function NX(e){let t=[];for(let n of e)t.push(...n.definitions);return{kind:mX.Kind.DOCUMENT,definitions:t}}});var xL=w(av=>{"use strict";m();T();N();Object.defineProperty(av,"__esModule",{value:!0});av.separateOperations=EX;var bN=Pt(),TX=ju();function EX(e){let t=[],n=Object.create(null);for(let i of e.definitions)switch(i.kind){case bN.Kind.OPERATION_DEFINITION:t.push(i);break;case bN.Kind.FRAGMENT_DEFINITION:n[i.name.value]=kL(i.selectionSet);break;default:}let r=Object.create(null);for(let i of t){let a=new Set;for(let c of kL(i.selectionSet))ML(a,n,c);let o=i.name?i.name.value:"";r[o]={kind:bN.Kind.DOCUMENT,definitions:e.definitions.filter(c=>c===i||c.kind===bN.Kind.FRAGMENT_DEFINITION&&a.has(c.name.value))}}return r}function ML(e,t,n){if(!e.has(n)){e.add(n);let r=t[n];if(r!==void 0)for(let i of r)ML(e,t,i)}}function kL(e){let t=[];return(0,TX.visit)(e,{FragmentSpread(n){t.push(n.name.value)}}),t}});var jL=w(ov=>{"use strict";m();T();N();Object.defineProperty(ov,"__esModule",{value:!0});ov.stripIgnoredCharacters=yX;var hX=Od(),qL=hm(),VL=_m(),sv=bd();function yX(e){let t=(0,VL.isSource)(e)?e:new VL.Source(e),n=t.body,r=new qL.Lexer(t),i="",a=!1;for(;r.advance().kind!==sv.TokenKind.EOF;){let o=r.token,c=o.kind,l=!(0,qL.isPunctuatorTokenKind)(o.kind);a&&(l||o.kind===sv.TokenKind.SPREAD)&&(i+=" ");let p=n.slice(o.start,o.end);c===sv.TokenKind.BLOCK_STRING?i+=(0,hX.printBlockString)(o.value,{minimize:!0}):i+=p,a=l}return i}});var GL=w(AN=>{"use strict";m();T();N();Object.defineProperty(AN,"__esModule",{value:!0});AN.assertValidName=vX;AN.isValidNameError=KL;var IX=Lr(),gX=He(),_X=Bd();function vX(e){let t=KL(e);if(t)throw t;return e}function KL(e){if(typeof e=="string"||(0,IX.devAssert)(!1,"Expected name to be a string."),e.startsWith("__"))return new gX.GraphQLError(`Name "${e}" must not begin with "__", which is reserved by GraphQL introspection.`);try{(0,_X.assertName)(e)}catch(t){return t}}});var XL=w(La=>{"use strict";m();T();N();Object.defineProperty(La,"__esModule",{value:!0});La.DangerousChangeType=La.BreakingChangeType=void 0;La.findBreakingChanges=RX;La.findDangerousChanges=PX;var SX=Yt(),zL=yr(),$L=Wo(),OX=ci(),qt=Ft(),DX=ba(),bX=Yd(),AX=lg(),wn;La.BreakingChangeType=wn;(function(e){e.TYPE_REMOVED="TYPE_REMOVED",e.TYPE_CHANGED_KIND="TYPE_CHANGED_KIND",e.TYPE_REMOVED_FROM_UNION="TYPE_REMOVED_FROM_UNION",e.VALUE_REMOVED_FROM_ENUM="VALUE_REMOVED_FROM_ENUM",e.REQUIRED_INPUT_FIELD_ADDED="REQUIRED_INPUT_FIELD_ADDED",e.IMPLEMENTED_INTERFACE_REMOVED="IMPLEMENTED_INTERFACE_REMOVED",e.FIELD_REMOVED="FIELD_REMOVED",e.FIELD_CHANGED_KIND="FIELD_CHANGED_KIND",e.REQUIRED_ARG_ADDED="REQUIRED_ARG_ADDED",e.ARG_REMOVED="ARG_REMOVED",e.ARG_CHANGED_KIND="ARG_CHANGED_KIND",e.DIRECTIVE_REMOVED="DIRECTIVE_REMOVED",e.DIRECTIVE_ARG_REMOVED="DIRECTIVE_ARG_REMOVED",e.REQUIRED_DIRECTIVE_ARG_ADDED="REQUIRED_DIRECTIVE_ARG_ADDED",e.DIRECTIVE_REPEATABLE_REMOVED="DIRECTIVE_REPEATABLE_REMOVED",e.DIRECTIVE_LOCATION_REMOVED="DIRECTIVE_LOCATION_REMOVED"})(wn||(La.BreakingChangeType=wn={}));var ra;La.DangerousChangeType=ra;(function(e){e.VALUE_ADDED_TO_ENUM="VALUE_ADDED_TO_ENUM",e.TYPE_ADDED_TO_UNION="TYPE_ADDED_TO_UNION",e.OPTIONAL_INPUT_FIELD_ADDED="OPTIONAL_INPUT_FIELD_ADDED",e.OPTIONAL_ARG_ADDED="OPTIONAL_ARG_ADDED",e.IMPLEMENTED_INTERFACE_ADDED="IMPLEMENTED_INTERFACE_ADDED",e.ARG_DEFAULT_VALUE_CHANGE="ARG_DEFAULT_VALUE_CHANGE"})(ra||(La.DangerousChangeType=ra={}));function RX(e,t){return WL(e,t).filter(n=>n.type in wn)}function PX(e,t){return WL(e,t).filter(n=>n.type in ra)}function WL(e,t){return[...wX(e,t),...FX(e,t)]}function FX(e,t){let n=[],r=Ns(e.getDirectives(),t.getDirectives());for(let i of r.removed)n.push({type:wn.DIRECTIVE_REMOVED,description:`${i.name} was removed.`});for(let[i,a]of r.persisted){let o=Ns(i.args,a.args);for(let c of o.added)(0,qt.isRequiredArgument)(c)&&n.push({type:wn.REQUIRED_DIRECTIVE_ARG_ADDED,description:`A required arg ${c.name} on directive ${i.name} was added.`});for(let c of o.removed)n.push({type:wn.DIRECTIVE_ARG_REMOVED,description:`${c.name} was removed from ${i.name}.`});i.isRepeatable&&!a.isRepeatable&&n.push({type:wn.DIRECTIVE_REPEATABLE_REMOVED,description:`Repeatable flag was removed from ${i.name}.`});for(let c of i.locations)a.locations.includes(c)||n.push({type:wn.DIRECTIVE_LOCATION_REMOVED,description:`${c} was removed from ${i.name}.`})}return n}function wX(e,t){let n=[],r=Ns(Object.values(e.getTypeMap()),Object.values(t.getTypeMap()));for(let i of r.removed)n.push({type:wn.TYPE_REMOVED,description:(0,DX.isSpecifiedScalarType)(i)?`Standard scalar ${i.name} was removed because it is not referenced anymore.`:`${i.name} was removed.`});for(let[i,a]of r.persisted)(0,qt.isEnumType)(i)&&(0,qt.isEnumType)(a)?n.push(...BX(i,a)):(0,qt.isUnionType)(i)&&(0,qt.isUnionType)(a)?n.push(...CX(i,a)):(0,qt.isInputObjectType)(i)&&(0,qt.isInputObjectType)(a)?n.push(...LX(i,a)):(0,qt.isObjectType)(i)&&(0,qt.isObjectType)(a)?n.push(...YL(i,a),...QL(i,a)):(0,qt.isInterfaceType)(i)&&(0,qt.isInterfaceType)(a)?n.push(...YL(i,a),...QL(i,a)):i.constructor!==a.constructor&&n.push({type:wn.TYPE_CHANGED_KIND,description:`${i.name} changed from ${JL(i)} to ${JL(a)}.`});return n}function LX(e,t){let n=[],r=Ns(Object.values(e.getFields()),Object.values(t.getFields()));for(let i of r.added)(0,qt.isRequiredInputField)(i)?n.push({type:wn.REQUIRED_INPUT_FIELD_ADDED,description:`A required field ${i.name} on input type ${e.name} was added.`}):n.push({type:ra.OPTIONAL_INPUT_FIELD_ADDED,description:`An optional field ${i.name} on input type ${e.name} was added.`});for(let i of r.removed)n.push({type:wn.FIELD_REMOVED,description:`${e.name}.${i.name} was removed.`});for(let[i,a]of r.persisted)Tp(i.type,a.type)||n.push({type:wn.FIELD_CHANGED_KIND,description:`${e.name}.${i.name} changed type from ${String(i.type)} to ${String(a.type)}.`});return n}function CX(e,t){let n=[],r=Ns(e.getTypes(),t.getTypes());for(let i of r.added)n.push({type:ra.TYPE_ADDED_TO_UNION,description:`${i.name} was added to union type ${e.name}.`});for(let i of r.removed)n.push({type:wn.TYPE_REMOVED_FROM_UNION,description:`${i.name} was removed from union type ${e.name}.`});return n}function BX(e,t){let n=[],r=Ns(e.getValues(),t.getValues());for(let i of r.added)n.push({type:ra.VALUE_ADDED_TO_ENUM,description:`${i.name} was added to enum type ${e.name}.`});for(let i of r.removed)n.push({type:wn.VALUE_REMOVED_FROM_ENUM,description:`${i.name} was removed from enum type ${e.name}.`});return n}function QL(e,t){let n=[],r=Ns(e.getInterfaces(),t.getInterfaces());for(let i of r.added)n.push({type:ra.IMPLEMENTED_INTERFACE_ADDED,description:`${i.name} added to interfaces implemented by ${e.name}.`});for(let i of r.removed)n.push({type:wn.IMPLEMENTED_INTERFACE_REMOVED,description:`${e.name} no longer implements interface ${i.name}.`});return n}function YL(e,t){let n=[],r=Ns(Object.values(e.getFields()),Object.values(t.getFields()));for(let i of r.removed)n.push({type:wn.FIELD_REMOVED,description:`${e.name}.${i.name} was removed.`});for(let[i,a]of r.persisted)n.push(...UX(e,i,a)),Np(i.type,a.type)||n.push({type:wn.FIELD_CHANGED_KIND,description:`${e.name}.${i.name} changed type from ${String(i.type)} to ${String(a.type)}.`});return n}function UX(e,t,n){let r=[],i=Ns(t.args,n.args);for(let a of i.removed)r.push({type:wn.ARG_REMOVED,description:`${e.name}.${t.name} arg ${a.name} was removed.`});for(let[a,o]of i.persisted)if(!Tp(a.type,o.type))r.push({type:wn.ARG_CHANGED_KIND,description:`${e.name}.${t.name} arg ${a.name} has changed type from ${String(a.type)} to ${String(o.type)}.`});else if(a.defaultValue!==void 0)if(o.defaultValue===void 0)r.push({type:ra.ARG_DEFAULT_VALUE_CHANGE,description:`${e.name}.${t.name} arg ${a.name} defaultValue was removed.`});else{let l=HL(a.defaultValue,a.type),p=HL(o.defaultValue,o.type);l!==p&&r.push({type:ra.ARG_DEFAULT_VALUE_CHANGE,description:`${e.name}.${t.name} arg ${a.name} has changed defaultValue from ${l} to ${p}.`})}for(let a of i.added)(0,qt.isRequiredArgument)(a)?r.push({type:wn.REQUIRED_ARG_ADDED,description:`A required arg ${a.name} on ${e.name}.${t.name} was added.`}):r.push({type:ra.OPTIONAL_ARG_ADDED,description:`An optional arg ${a.name} on ${e.name}.${t.name} was added.`});return r}function Np(e,t){return(0,qt.isListType)(e)?(0,qt.isListType)(t)&&Np(e.ofType,t.ofType)||(0,qt.isNonNullType)(t)&&Np(e,t.ofType):(0,qt.isNonNullType)(e)?(0,qt.isNonNullType)(t)&&Np(e.ofType,t.ofType):(0,qt.isNamedType)(t)&&e.name===t.name||(0,qt.isNonNullType)(t)&&Np(e,t.ofType)}function Tp(e,t){return(0,qt.isListType)(e)?(0,qt.isListType)(t)&&Tp(e.ofType,t.ofType):(0,qt.isNonNullType)(e)?(0,qt.isNonNullType)(t)&&Tp(e.ofType,t.ofType)||!(0,qt.isNonNullType)(t)&&Tp(e.ofType,t):(0,qt.isNamedType)(t)&&e.name===t.name}function JL(e){if((0,qt.isScalarType)(e))return"a Scalar type";if((0,qt.isObjectType)(e))return"an Object type";if((0,qt.isInterfaceType)(e))return"an Interface type";if((0,qt.isUnionType)(e))return"a Union type";if((0,qt.isEnumType)(e))return"an Enum type";if((0,qt.isInputObjectType)(e))return"an Input type";(0,zL.invariant)(!1,"Unexpected type: "+(0,SX.inspect)(e))}function HL(e,t){let n=(0,bX.astFromValue)(e,t);return n!=null||(0,zL.invariant)(!1),(0,OX.print)((0,AX.sortValueNode)(n))}function Ns(e,t){let n=[],r=[],i=[],a=(0,$L.keyMap)(e,({name:c})=>c),o=(0,$L.keyMap)(t,({name:c})=>c);for(let c of e){let l=o[c.name];l===void 0?r.push(c):i.push([c,l])}for(let c of t)a[c.name]===void 0&&n.push(c);return{added:n,persisted:i,removed:r}}});var nC=w(Bt=>{"use strict";m();T();N();Object.defineProperty(Bt,"__esModule",{value:!0});Object.defineProperty(Bt,"BreakingChangeType",{enumerable:!0,get:function(){return RN.BreakingChangeType}});Object.defineProperty(Bt,"DangerousChangeType",{enumerable:!0,get:function(){return RN.DangerousChangeType}});Object.defineProperty(Bt,"TypeInfo",{enumerable:!0,get:function(){return eC.TypeInfo}});Object.defineProperty(Bt,"assertValidName",{enumerable:!0,get:function(){return tC.assertValidName}});Object.defineProperty(Bt,"astFromValue",{enumerable:!0,get:function(){return YX.astFromValue}});Object.defineProperty(Bt,"buildASTSchema",{enumerable:!0,get:function(){return ZL.buildASTSchema}});Object.defineProperty(Bt,"buildClientSchema",{enumerable:!0,get:function(){return VX.buildClientSchema}});Object.defineProperty(Bt,"buildSchema",{enumerable:!0,get:function(){return ZL.buildSchema}});Object.defineProperty(Bt,"coerceInputValue",{enumerable:!0,get:function(){return JX.coerceInputValue}});Object.defineProperty(Bt,"concatAST",{enumerable:!0,get:function(){return HX.concatAST}});Object.defineProperty(Bt,"doTypesOverlap",{enumerable:!0,get:function(){return cv.doTypesOverlap}});Object.defineProperty(Bt,"extendSchema",{enumerable:!0,get:function(){return jX.extendSchema}});Object.defineProperty(Bt,"findBreakingChanges",{enumerable:!0,get:function(){return RN.findBreakingChanges}});Object.defineProperty(Bt,"findDangerousChanges",{enumerable:!0,get:function(){return RN.findDangerousChanges}});Object.defineProperty(Bt,"getIntrospectionQuery",{enumerable:!0,get:function(){return kX.getIntrospectionQuery}});Object.defineProperty(Bt,"getOperationAST",{enumerable:!0,get:function(){return MX.getOperationAST}});Object.defineProperty(Bt,"getOperationRootType",{enumerable:!0,get:function(){return xX.getOperationRootType}});Object.defineProperty(Bt,"introspectionFromSchema",{enumerable:!0,get:function(){return qX.introspectionFromSchema}});Object.defineProperty(Bt,"isEqualType",{enumerable:!0,get:function(){return cv.isEqualType}});Object.defineProperty(Bt,"isTypeSubTypeOf",{enumerable:!0,get:function(){return cv.isTypeSubTypeOf}});Object.defineProperty(Bt,"isValidNameError",{enumerable:!0,get:function(){return tC.isValidNameError}});Object.defineProperty(Bt,"lexicographicSortSchema",{enumerable:!0,get:function(){return KX.lexicographicSortSchema}});Object.defineProperty(Bt,"printIntrospectionSchema",{enumerable:!0,get:function(){return uv.printIntrospectionSchema}});Object.defineProperty(Bt,"printSchema",{enumerable:!0,get:function(){return uv.printSchema}});Object.defineProperty(Bt,"printType",{enumerable:!0,get:function(){return uv.printType}});Object.defineProperty(Bt,"separateOperations",{enumerable:!0,get:function(){return zX.separateOperations}});Object.defineProperty(Bt,"stripIgnoredCharacters",{enumerable:!0,get:function(){return WX.stripIgnoredCharacters}});Object.defineProperty(Bt,"typeFromAST",{enumerable:!0,get:function(){return GX.typeFromAST}});Object.defineProperty(Bt,"valueFromAST",{enumerable:!0,get:function(){return $X.valueFromAST}});Object.defineProperty(Bt,"valueFromASTUntyped",{enumerable:!0,get:function(){return QX.valueFromASTUntyped}});Object.defineProperty(Bt,"visitWithTypeInfo",{enumerable:!0,get:function(){return eC.visitWithTypeInfo}});var kX=G_(),MX=dL(),xX=pL(),qX=fL(),VX=NL(),ZL=OL(),jX=z_(),KX=AL(),uv=BL(),GX=Aa(),$X=rp(),QX=sI(),YX=Yd(),eC=zm(),JX=Pg(),HX=UL(),zX=xL(),WX=jL(),cv=qd(),tC=GL(),RN=XL()});var Ae=w(V=>{"use strict";m();T();N();Object.defineProperty(V,"__esModule",{value:!0});Object.defineProperty(V,"BREAK",{enumerable:!0,get:function(){return Kt.BREAK}});Object.defineProperty(V,"BreakingChangeType",{enumerable:!0,get:function(){return Gt.BreakingChangeType}});Object.defineProperty(V,"DEFAULT_DEPRECATION_REASON",{enumerable:!0,get:function(){return Ie.DEFAULT_DEPRECATION_REASON}});Object.defineProperty(V,"DangerousChangeType",{enumerable:!0,get:function(){return Gt.DangerousChangeType}});Object.defineProperty(V,"DirectiveLocation",{enumerable:!0,get:function(){return Kt.DirectiveLocation}});Object.defineProperty(V,"ExecutableDefinitionsRule",{enumerable:!0,get:function(){return Tt.ExecutableDefinitionsRule}});Object.defineProperty(V,"FieldsOnCorrectTypeRule",{enumerable:!0,get:function(){return Tt.FieldsOnCorrectTypeRule}});Object.defineProperty(V,"FragmentsOnCompositeTypesRule",{enumerable:!0,get:function(){return Tt.FragmentsOnCompositeTypesRule}});Object.defineProperty(V,"GRAPHQL_MAX_INT",{enumerable:!0,get:function(){return Ie.GRAPHQL_MAX_INT}});Object.defineProperty(V,"GRAPHQL_MIN_INT",{enumerable:!0,get:function(){return Ie.GRAPHQL_MIN_INT}});Object.defineProperty(V,"GraphQLBoolean",{enumerable:!0,get:function(){return Ie.GraphQLBoolean}});Object.defineProperty(V,"GraphQLDeprecatedDirective",{enumerable:!0,get:function(){return Ie.GraphQLDeprecatedDirective}});Object.defineProperty(V,"GraphQLDirective",{enumerable:!0,get:function(){return Ie.GraphQLDirective}});Object.defineProperty(V,"GraphQLEnumType",{enumerable:!0,get:function(){return Ie.GraphQLEnumType}});Object.defineProperty(V,"GraphQLError",{enumerable:!0,get:function(){return Ep.GraphQLError}});Object.defineProperty(V,"GraphQLFloat",{enumerable:!0,get:function(){return Ie.GraphQLFloat}});Object.defineProperty(V,"GraphQLID",{enumerable:!0,get:function(){return Ie.GraphQLID}});Object.defineProperty(V,"GraphQLIncludeDirective",{enumerable:!0,get:function(){return Ie.GraphQLIncludeDirective}});Object.defineProperty(V,"GraphQLInputObjectType",{enumerable:!0,get:function(){return Ie.GraphQLInputObjectType}});Object.defineProperty(V,"GraphQLInt",{enumerable:!0,get:function(){return Ie.GraphQLInt}});Object.defineProperty(V,"GraphQLInterfaceType",{enumerable:!0,get:function(){return Ie.GraphQLInterfaceType}});Object.defineProperty(V,"GraphQLList",{enumerable:!0,get:function(){return Ie.GraphQLList}});Object.defineProperty(V,"GraphQLNonNull",{enumerable:!0,get:function(){return Ie.GraphQLNonNull}});Object.defineProperty(V,"GraphQLObjectType",{enumerable:!0,get:function(){return Ie.GraphQLObjectType}});Object.defineProperty(V,"GraphQLOneOfDirective",{enumerable:!0,get:function(){return Ie.GraphQLOneOfDirective}});Object.defineProperty(V,"GraphQLScalarType",{enumerable:!0,get:function(){return Ie.GraphQLScalarType}});Object.defineProperty(V,"GraphQLSchema",{enumerable:!0,get:function(){return Ie.GraphQLSchema}});Object.defineProperty(V,"GraphQLSkipDirective",{enumerable:!0,get:function(){return Ie.GraphQLSkipDirective}});Object.defineProperty(V,"GraphQLSpecifiedByDirective",{enumerable:!0,get:function(){return Ie.GraphQLSpecifiedByDirective}});Object.defineProperty(V,"GraphQLString",{enumerable:!0,get:function(){return Ie.GraphQLString}});Object.defineProperty(V,"GraphQLUnionType",{enumerable:!0,get:function(){return Ie.GraphQLUnionType}});Object.defineProperty(V,"Kind",{enumerable:!0,get:function(){return Kt.Kind}});Object.defineProperty(V,"KnownArgumentNamesRule",{enumerable:!0,get:function(){return Tt.KnownArgumentNamesRule}});Object.defineProperty(V,"KnownDirectivesRule",{enumerable:!0,get:function(){return Tt.KnownDirectivesRule}});Object.defineProperty(V,"KnownFragmentNamesRule",{enumerable:!0,get:function(){return Tt.KnownFragmentNamesRule}});Object.defineProperty(V,"KnownTypeNamesRule",{enumerable:!0,get:function(){return Tt.KnownTypeNamesRule}});Object.defineProperty(V,"Lexer",{enumerable:!0,get:function(){return Kt.Lexer}});Object.defineProperty(V,"Location",{enumerable:!0,get:function(){return Kt.Location}});Object.defineProperty(V,"LoneAnonymousOperationRule",{enumerable:!0,get:function(){return Tt.LoneAnonymousOperationRule}});Object.defineProperty(V,"LoneSchemaDefinitionRule",{enumerable:!0,get:function(){return Tt.LoneSchemaDefinitionRule}});Object.defineProperty(V,"MaxIntrospectionDepthRule",{enumerable:!0,get:function(){return Tt.MaxIntrospectionDepthRule}});Object.defineProperty(V,"NoDeprecatedCustomRule",{enumerable:!0,get:function(){return Tt.NoDeprecatedCustomRule}});Object.defineProperty(V,"NoFragmentCyclesRule",{enumerable:!0,get:function(){return Tt.NoFragmentCyclesRule}});Object.defineProperty(V,"NoSchemaIntrospectionCustomRule",{enumerable:!0,get:function(){return Tt.NoSchemaIntrospectionCustomRule}});Object.defineProperty(V,"NoUndefinedVariablesRule",{enumerable:!0,get:function(){return Tt.NoUndefinedVariablesRule}});Object.defineProperty(V,"NoUnusedFragmentsRule",{enumerable:!0,get:function(){return Tt.NoUnusedFragmentsRule}});Object.defineProperty(V,"NoUnusedVariablesRule",{enumerable:!0,get:function(){return Tt.NoUnusedVariablesRule}});Object.defineProperty(V,"OperationTypeNode",{enumerable:!0,get:function(){return Kt.OperationTypeNode}});Object.defineProperty(V,"OverlappingFieldsCanBeMergedRule",{enumerable:!0,get:function(){return Tt.OverlappingFieldsCanBeMergedRule}});Object.defineProperty(V,"PossibleFragmentSpreadsRule",{enumerable:!0,get:function(){return Tt.PossibleFragmentSpreadsRule}});Object.defineProperty(V,"PossibleTypeExtensionsRule",{enumerable:!0,get:function(){return Tt.PossibleTypeExtensionsRule}});Object.defineProperty(V,"ProvidedRequiredArgumentsRule",{enumerable:!0,get:function(){return Tt.ProvidedRequiredArgumentsRule}});Object.defineProperty(V,"ScalarLeafsRule",{enumerable:!0,get:function(){return Tt.ScalarLeafsRule}});Object.defineProperty(V,"SchemaMetaFieldDef",{enumerable:!0,get:function(){return Ie.SchemaMetaFieldDef}});Object.defineProperty(V,"SingleFieldSubscriptionsRule",{enumerable:!0,get:function(){return Tt.SingleFieldSubscriptionsRule}});Object.defineProperty(V,"Source",{enumerable:!0,get:function(){return Kt.Source}});Object.defineProperty(V,"Token",{enumerable:!0,get:function(){return Kt.Token}});Object.defineProperty(V,"TokenKind",{enumerable:!0,get:function(){return Kt.TokenKind}});Object.defineProperty(V,"TypeInfo",{enumerable:!0,get:function(){return Gt.TypeInfo}});Object.defineProperty(V,"TypeKind",{enumerable:!0,get:function(){return Ie.TypeKind}});Object.defineProperty(V,"TypeMetaFieldDef",{enumerable:!0,get:function(){return Ie.TypeMetaFieldDef}});Object.defineProperty(V,"TypeNameMetaFieldDef",{enumerable:!0,get:function(){return Ie.TypeNameMetaFieldDef}});Object.defineProperty(V,"UniqueArgumentDefinitionNamesRule",{enumerable:!0,get:function(){return Tt.UniqueArgumentDefinitionNamesRule}});Object.defineProperty(V,"UniqueArgumentNamesRule",{enumerable:!0,get:function(){return Tt.UniqueArgumentNamesRule}});Object.defineProperty(V,"UniqueDirectiveNamesRule",{enumerable:!0,get:function(){return Tt.UniqueDirectiveNamesRule}});Object.defineProperty(V,"UniqueDirectivesPerLocationRule",{enumerable:!0,get:function(){return Tt.UniqueDirectivesPerLocationRule}});Object.defineProperty(V,"UniqueEnumValueNamesRule",{enumerable:!0,get:function(){return Tt.UniqueEnumValueNamesRule}});Object.defineProperty(V,"UniqueFieldDefinitionNamesRule",{enumerable:!0,get:function(){return Tt.UniqueFieldDefinitionNamesRule}});Object.defineProperty(V,"UniqueFragmentNamesRule",{enumerable:!0,get:function(){return Tt.UniqueFragmentNamesRule}});Object.defineProperty(V,"UniqueInputFieldNamesRule",{enumerable:!0,get:function(){return Tt.UniqueInputFieldNamesRule}});Object.defineProperty(V,"UniqueOperationNamesRule",{enumerable:!0,get:function(){return Tt.UniqueOperationNamesRule}});Object.defineProperty(V,"UniqueOperationTypesRule",{enumerable:!0,get:function(){return Tt.UniqueOperationTypesRule}});Object.defineProperty(V,"UniqueTypeNamesRule",{enumerable:!0,get:function(){return Tt.UniqueTypeNamesRule}});Object.defineProperty(V,"UniqueVariableNamesRule",{enumerable:!0,get:function(){return Tt.UniqueVariableNamesRule}});Object.defineProperty(V,"ValidationContext",{enumerable:!0,get:function(){return Tt.ValidationContext}});Object.defineProperty(V,"ValuesOfCorrectTypeRule",{enumerable:!0,get:function(){return Tt.ValuesOfCorrectTypeRule}});Object.defineProperty(V,"VariablesAreInputTypesRule",{enumerable:!0,get:function(){return Tt.VariablesAreInputTypesRule}});Object.defineProperty(V,"VariablesInAllowedPositionRule",{enumerable:!0,get:function(){return Tt.VariablesInAllowedPositionRule}});Object.defineProperty(V,"__Directive",{enumerable:!0,get:function(){return Ie.__Directive}});Object.defineProperty(V,"__DirectiveLocation",{enumerable:!0,get:function(){return Ie.__DirectiveLocation}});Object.defineProperty(V,"__EnumValue",{enumerable:!0,get:function(){return Ie.__EnumValue}});Object.defineProperty(V,"__Field",{enumerable:!0,get:function(){return Ie.__Field}});Object.defineProperty(V,"__InputValue",{enumerable:!0,get:function(){return Ie.__InputValue}});Object.defineProperty(V,"__Schema",{enumerable:!0,get:function(){return Ie.__Schema}});Object.defineProperty(V,"__Type",{enumerable:!0,get:function(){return Ie.__Type}});Object.defineProperty(V,"__TypeKind",{enumerable:!0,get:function(){return Ie.__TypeKind}});Object.defineProperty(V,"assertAbstractType",{enumerable:!0,get:function(){return Ie.assertAbstractType}});Object.defineProperty(V,"assertCompositeType",{enumerable:!0,get:function(){return Ie.assertCompositeType}});Object.defineProperty(V,"assertDirective",{enumerable:!0,get:function(){return Ie.assertDirective}});Object.defineProperty(V,"assertEnumType",{enumerable:!0,get:function(){return Ie.assertEnumType}});Object.defineProperty(V,"assertEnumValueName",{enumerable:!0,get:function(){return Ie.assertEnumValueName}});Object.defineProperty(V,"assertInputObjectType",{enumerable:!0,get:function(){return Ie.assertInputObjectType}});Object.defineProperty(V,"assertInputType",{enumerable:!0,get:function(){return Ie.assertInputType}});Object.defineProperty(V,"assertInterfaceType",{enumerable:!0,get:function(){return Ie.assertInterfaceType}});Object.defineProperty(V,"assertLeafType",{enumerable:!0,get:function(){return Ie.assertLeafType}});Object.defineProperty(V,"assertListType",{enumerable:!0,get:function(){return Ie.assertListType}});Object.defineProperty(V,"assertName",{enumerable:!0,get:function(){return Ie.assertName}});Object.defineProperty(V,"assertNamedType",{enumerable:!0,get:function(){return Ie.assertNamedType}});Object.defineProperty(V,"assertNonNullType",{enumerable:!0,get:function(){return Ie.assertNonNullType}});Object.defineProperty(V,"assertNullableType",{enumerable:!0,get:function(){return Ie.assertNullableType}});Object.defineProperty(V,"assertObjectType",{enumerable:!0,get:function(){return Ie.assertObjectType}});Object.defineProperty(V,"assertOutputType",{enumerable:!0,get:function(){return Ie.assertOutputType}});Object.defineProperty(V,"assertScalarType",{enumerable:!0,get:function(){return Ie.assertScalarType}});Object.defineProperty(V,"assertSchema",{enumerable:!0,get:function(){return Ie.assertSchema}});Object.defineProperty(V,"assertType",{enumerable:!0,get:function(){return Ie.assertType}});Object.defineProperty(V,"assertUnionType",{enumerable:!0,get:function(){return Ie.assertUnionType}});Object.defineProperty(V,"assertValidName",{enumerable:!0,get:function(){return Gt.assertValidName}});Object.defineProperty(V,"assertValidSchema",{enumerable:!0,get:function(){return Ie.assertValidSchema}});Object.defineProperty(V,"assertWrappingType",{enumerable:!0,get:function(){return Ie.assertWrappingType}});Object.defineProperty(V,"astFromValue",{enumerable:!0,get:function(){return Gt.astFromValue}});Object.defineProperty(V,"buildASTSchema",{enumerable:!0,get:function(){return Gt.buildASTSchema}});Object.defineProperty(V,"buildClientSchema",{enumerable:!0,get:function(){return Gt.buildClientSchema}});Object.defineProperty(V,"buildSchema",{enumerable:!0,get:function(){return Gt.buildSchema}});Object.defineProperty(V,"coerceInputValue",{enumerable:!0,get:function(){return Gt.coerceInputValue}});Object.defineProperty(V,"concatAST",{enumerable:!0,get:function(){return Gt.concatAST}});Object.defineProperty(V,"createSourceEventStream",{enumerable:!0,get:function(){return Ca.createSourceEventStream}});Object.defineProperty(V,"defaultFieldResolver",{enumerable:!0,get:function(){return Ca.defaultFieldResolver}});Object.defineProperty(V,"defaultTypeResolver",{enumerable:!0,get:function(){return Ca.defaultTypeResolver}});Object.defineProperty(V,"doTypesOverlap",{enumerable:!0,get:function(){return Gt.doTypesOverlap}});Object.defineProperty(V,"execute",{enumerable:!0,get:function(){return Ca.execute}});Object.defineProperty(V,"executeSync",{enumerable:!0,get:function(){return Ca.executeSync}});Object.defineProperty(V,"extendSchema",{enumerable:!0,get:function(){return Gt.extendSchema}});Object.defineProperty(V,"findBreakingChanges",{enumerable:!0,get:function(){return Gt.findBreakingChanges}});Object.defineProperty(V,"findDangerousChanges",{enumerable:!0,get:function(){return Gt.findDangerousChanges}});Object.defineProperty(V,"formatError",{enumerable:!0,get:function(){return Ep.formatError}});Object.defineProperty(V,"getArgumentValues",{enumerable:!0,get:function(){return Ca.getArgumentValues}});Object.defineProperty(V,"getDirectiveValues",{enumerable:!0,get:function(){return Ca.getDirectiveValues}});Object.defineProperty(V,"getEnterLeaveForKind",{enumerable:!0,get:function(){return Kt.getEnterLeaveForKind}});Object.defineProperty(V,"getIntrospectionQuery",{enumerable:!0,get:function(){return Gt.getIntrospectionQuery}});Object.defineProperty(V,"getLocation",{enumerable:!0,get:function(){return Kt.getLocation}});Object.defineProperty(V,"getNamedType",{enumerable:!0,get:function(){return Ie.getNamedType}});Object.defineProperty(V,"getNullableType",{enumerable:!0,get:function(){return Ie.getNullableType}});Object.defineProperty(V,"getOperationAST",{enumerable:!0,get:function(){return Gt.getOperationAST}});Object.defineProperty(V,"getOperationRootType",{enumerable:!0,get:function(){return Gt.getOperationRootType}});Object.defineProperty(V,"getVariableValues",{enumerable:!0,get:function(){return Ca.getVariableValues}});Object.defineProperty(V,"getVisitFn",{enumerable:!0,get:function(){return Kt.getVisitFn}});Object.defineProperty(V,"graphql",{enumerable:!0,get:function(){return iC.graphql}});Object.defineProperty(V,"graphqlSync",{enumerable:!0,get:function(){return iC.graphqlSync}});Object.defineProperty(V,"introspectionFromSchema",{enumerable:!0,get:function(){return Gt.introspectionFromSchema}});Object.defineProperty(V,"introspectionTypes",{enumerable:!0,get:function(){return Ie.introspectionTypes}});Object.defineProperty(V,"isAbstractType",{enumerable:!0,get:function(){return Ie.isAbstractType}});Object.defineProperty(V,"isCompositeType",{enumerable:!0,get:function(){return Ie.isCompositeType}});Object.defineProperty(V,"isConstValueNode",{enumerable:!0,get:function(){return Kt.isConstValueNode}});Object.defineProperty(V,"isDefinitionNode",{enumerable:!0,get:function(){return Kt.isDefinitionNode}});Object.defineProperty(V,"isDirective",{enumerable:!0,get:function(){return Ie.isDirective}});Object.defineProperty(V,"isEnumType",{enumerable:!0,get:function(){return Ie.isEnumType}});Object.defineProperty(V,"isEqualType",{enumerable:!0,get:function(){return Gt.isEqualType}});Object.defineProperty(V,"isExecutableDefinitionNode",{enumerable:!0,get:function(){return Kt.isExecutableDefinitionNode}});Object.defineProperty(V,"isInputObjectType",{enumerable:!0,get:function(){return Ie.isInputObjectType}});Object.defineProperty(V,"isInputType",{enumerable:!0,get:function(){return Ie.isInputType}});Object.defineProperty(V,"isInterfaceType",{enumerable:!0,get:function(){return Ie.isInterfaceType}});Object.defineProperty(V,"isIntrospectionType",{enumerable:!0,get:function(){return Ie.isIntrospectionType}});Object.defineProperty(V,"isLeafType",{enumerable:!0,get:function(){return Ie.isLeafType}});Object.defineProperty(V,"isListType",{enumerable:!0,get:function(){return Ie.isListType}});Object.defineProperty(V,"isNamedType",{enumerable:!0,get:function(){return Ie.isNamedType}});Object.defineProperty(V,"isNonNullType",{enumerable:!0,get:function(){return Ie.isNonNullType}});Object.defineProperty(V,"isNullableType",{enumerable:!0,get:function(){return Ie.isNullableType}});Object.defineProperty(V,"isObjectType",{enumerable:!0,get:function(){return Ie.isObjectType}});Object.defineProperty(V,"isOutputType",{enumerable:!0,get:function(){return Ie.isOutputType}});Object.defineProperty(V,"isRequiredArgument",{enumerable:!0,get:function(){return Ie.isRequiredArgument}});Object.defineProperty(V,"isRequiredInputField",{enumerable:!0,get:function(){return Ie.isRequiredInputField}});Object.defineProperty(V,"isScalarType",{enumerable:!0,get:function(){return Ie.isScalarType}});Object.defineProperty(V,"isSchema",{enumerable:!0,get:function(){return Ie.isSchema}});Object.defineProperty(V,"isSelectionNode",{enumerable:!0,get:function(){return Kt.isSelectionNode}});Object.defineProperty(V,"isSpecifiedDirective",{enumerable:!0,get:function(){return Ie.isSpecifiedDirective}});Object.defineProperty(V,"isSpecifiedScalarType",{enumerable:!0,get:function(){return Ie.isSpecifiedScalarType}});Object.defineProperty(V,"isType",{enumerable:!0,get:function(){return Ie.isType}});Object.defineProperty(V,"isTypeDefinitionNode",{enumerable:!0,get:function(){return Kt.isTypeDefinitionNode}});Object.defineProperty(V,"isTypeExtensionNode",{enumerable:!0,get:function(){return Kt.isTypeExtensionNode}});Object.defineProperty(V,"isTypeNode",{enumerable:!0,get:function(){return Kt.isTypeNode}});Object.defineProperty(V,"isTypeSubTypeOf",{enumerable:!0,get:function(){return Gt.isTypeSubTypeOf}});Object.defineProperty(V,"isTypeSystemDefinitionNode",{enumerable:!0,get:function(){return Kt.isTypeSystemDefinitionNode}});Object.defineProperty(V,"isTypeSystemExtensionNode",{enumerable:!0,get:function(){return Kt.isTypeSystemExtensionNode}});Object.defineProperty(V,"isUnionType",{enumerable:!0,get:function(){return Ie.isUnionType}});Object.defineProperty(V,"isValidNameError",{enumerable:!0,get:function(){return Gt.isValidNameError}});Object.defineProperty(V,"isValueNode",{enumerable:!0,get:function(){return Kt.isValueNode}});Object.defineProperty(V,"isWrappingType",{enumerable:!0,get:function(){return Ie.isWrappingType}});Object.defineProperty(V,"lexicographicSortSchema",{enumerable:!0,get:function(){return Gt.lexicographicSortSchema}});Object.defineProperty(V,"locatedError",{enumerable:!0,get:function(){return Ep.locatedError}});Object.defineProperty(V,"parse",{enumerable:!0,get:function(){return Kt.parse}});Object.defineProperty(V,"parseConstValue",{enumerable:!0,get:function(){return Kt.parseConstValue}});Object.defineProperty(V,"parseType",{enumerable:!0,get:function(){return Kt.parseType}});Object.defineProperty(V,"parseValue",{enumerable:!0,get:function(){return Kt.parseValue}});Object.defineProperty(V,"print",{enumerable:!0,get:function(){return Kt.print}});Object.defineProperty(V,"printError",{enumerable:!0,get:function(){return Ep.printError}});Object.defineProperty(V,"printIntrospectionSchema",{enumerable:!0,get:function(){return Gt.printIntrospectionSchema}});Object.defineProperty(V,"printLocation",{enumerable:!0,get:function(){return Kt.printLocation}});Object.defineProperty(V,"printSchema",{enumerable:!0,get:function(){return Gt.printSchema}});Object.defineProperty(V,"printSourceLocation",{enumerable:!0,get:function(){return Kt.printSourceLocation}});Object.defineProperty(V,"printType",{enumerable:!0,get:function(){return Gt.printType}});Object.defineProperty(V,"recommendedRules",{enumerable:!0,get:function(){return Tt.recommendedRules}});Object.defineProperty(V,"resolveObjMapThunk",{enumerable:!0,get:function(){return Ie.resolveObjMapThunk}});Object.defineProperty(V,"resolveReadonlyArrayThunk",{enumerable:!0,get:function(){return Ie.resolveReadonlyArrayThunk}});Object.defineProperty(V,"responsePathAsArray",{enumerable:!0,get:function(){return Ca.responsePathAsArray}});Object.defineProperty(V,"separateOperations",{enumerable:!0,get:function(){return Gt.separateOperations}});Object.defineProperty(V,"specifiedDirectives",{enumerable:!0,get:function(){return Ie.specifiedDirectives}});Object.defineProperty(V,"specifiedRules",{enumerable:!0,get:function(){return Tt.specifiedRules}});Object.defineProperty(V,"specifiedScalarTypes",{enumerable:!0,get:function(){return Ie.specifiedScalarTypes}});Object.defineProperty(V,"stripIgnoredCharacters",{enumerable:!0,get:function(){return Gt.stripIgnoredCharacters}});Object.defineProperty(V,"subscribe",{enumerable:!0,get:function(){return Ca.subscribe}});Object.defineProperty(V,"syntaxError",{enumerable:!0,get:function(){return Ep.syntaxError}});Object.defineProperty(V,"typeFromAST",{enumerable:!0,get:function(){return Gt.typeFromAST}});Object.defineProperty(V,"validate",{enumerable:!0,get:function(){return Tt.validate}});Object.defineProperty(V,"validateSchema",{enumerable:!0,get:function(){return Ie.validateSchema}});Object.defineProperty(V,"valueFromAST",{enumerable:!0,get:function(){return Gt.valueFromAST}});Object.defineProperty(V,"valueFromASTUntyped",{enumerable:!0,get:function(){return Gt.valueFromASTUntyped}});Object.defineProperty(V,"version",{enumerable:!0,get:function(){return rC.version}});Object.defineProperty(V,"versionInfo",{enumerable:!0,get:function(){return rC.versionInfo}});Object.defineProperty(V,"visit",{enumerable:!0,get:function(){return Kt.visit}});Object.defineProperty(V,"visitInParallel",{enumerable:!0,get:function(){return Kt.visitInParallel}});Object.defineProperty(V,"visitWithTypeInfo",{enumerable:!0,get:function(){return Gt.visitWithTypeInfo}});var rC=XR(),iC=Qw(),Ie=Hw(),Kt=Ww(),Ca=aL(),Tt=cL(),Ep=lL(),Gt=nC()});var ur=w(P=>{"use strict";m();T();N();Object.defineProperty(P,"__esModule",{value:!0});P.FLOAT_SCALAR=P.FIRST_ORDINAL=P.FIELD_DEFINITION_UPPER=P.FIELDS=P.FIELD_SET_SCALAR=P.FIELD_UPPER=P.FIELD_PATH=P.FIELD=P.EXTENSIONS=P.EXTENDS=P.EXTERNAL=P.EXECUTION=P.ENUM_VALUE_UPPER=P.ENUM_VALUE=P.ENUM_UPPER=P.ENUM=P.ENTITY_UNION=P.ENTITIES_FIELD=P.ENTITIES=P.EDFS_REDIS_SUBSCRIBE=P.EDFS_REDIS_PUBLISH=P.EDFS_NATS_STREAM_CONFIGURATION=P.EDFS_PUBLISH_RESULT=P.EDFS_NATS_SUBSCRIBE=P.EDFS_NATS_REQUEST=P.EDFS_NATS_PUBLISH=P.EDFS_KAFKA_SUBSCRIBE=P.EDFS_KAFKA_PUBLISH=P.DIRECTIVE_DEFINITION=P.DESCRIPTION_OVERRIDE=P.DEPRECATED_DEFAULT_ARGUMENT_VALUE=P.DEPRECATED=P.DEFAULT_SUBSCRIPTION=P.DEFAULT_QUERY=P.DEFAULT_MUTATION=P.DEFAULT_EDFS_PROVIDER_ID=P.DEFAULT=P.CONSUMER_NAME=P.CONFIGURE_CHILD_DESCRIPTIONS=P.CONFIGURE_DESCRIPTION=P.CONDITION=P.COMPOSE_DIRECTIVE=P.BOOLEAN_SCALAR=P.BOOLEAN=P.ARGUMENT_DEFINITION_UPPER=P.AUTHENTICATED=P.ARGUMENT=P.ANY_SCALAR=P.AND_UPPER=P.AS=void 0;P.PARENT_DEFINITION_DATA=P.OVERRIDE=P.OR_UPPER=P.OBJECT_UPPER=P.OBJECT=P.OPERATION_TO_DEFAULT=P.NULL=P.NOT_UPPER=P.NON_NULLABLE_STRING=P.NON_NULLABLE_INT=P.NON_NULLABLE_BOOLEAN=P.NON_NULLABLE_EDFS_PUBLISH_EVENT_RESULT=P.NAME=P.NOT_APPLICABLE=P.PROVIDER_TYPE_REDIS=P.PROVIDER_TYPE_NATS=P.PROVIDER_TYPE_KAFKA=P.PROPAGATE=P.MUTATION_UPPER=P.MUTATION=P.NUMBER=P.LITERAL_NEW_LINE=P.LITERAL_SPACE=P.LIST=P.LINK_PURPOSE=P.LINK_IMPORT=P.LINK=P.LEFT_PARENTHESIS=P.KEY=P.INTERFACE_OBJECT=P.INTERFACE_UPPER=P.INTERFACE=P.INT_SCALAR=P.INPUT_VALUE=P.INPUT_OBJECT_UPPER=P.INPUT_OBJECT=P.INPUT_FIELD_DEFINITION_UPPER=P.INPUT_FIELD=P.INPUT=P.INLINE_FRAGMENT_UPPER=P.INLINE_FRAGMENT=P.INACCESSIBLE=P.IN_UPPER=P.IMPORT=P.ID_SCALAR=P.HYPHEN_JOIN=P.FROM=P.FRAGMENT_SPREAD_UPPER=P.FRAGMENT_DEFINITION_UPPER=P.FOR=void 0;P.CHANNEL=P.VARIABLE_DEFINITION_UPPER=P.VALUES=P.URL_LOWER=P.UNION_UPPER=P.UNION=P.TOPICS=P.TOPIC=P.TAG=P.SUCCESS=P.SUBSCRIPTION_UPPER=P.SUBSCRIBE=P.SUBSCRIPTION_FILTER_VALUE=P.SUBSCRIPTION_FILTER_CONDITION=P.SUBSCRIPTION_FILTER=P.SUBSCRIPTION_FIELD_CONDITION=P.SUBSCRIPTION=P.SUBJECTS=P.SUBJECT=P.STRING_SCALAR=P.STRING=P.STREAM_NAME=P.CONSUMER_INACTIVE_THRESHOLD=P.STREAM_CONFIGURATION=P.SPECIFIED_BY=P.SHAREABLE=P.SERVICE_FIELD=P.SERVICE_OBJECT=P.SELECTION_REPRESENTATION=P.SECURITY=P.SCOPE_SCALAR=P.SCOPES=P.SCHEMA_UPPER=P.SCHEMA=P.SCALAR_UPPER=P.SCALAR=P.RESOLVABLE=P.REQUIRES_SCOPES=P.REQUIRES=P.REQUEST=P.REASON=P.QUOTATION_JOIN=P.QUERY_UPPER=P.QUERY=P.PUBLISH=P.PROVIDES=P.PROVIDER_ID=P.PERIOD=P.PARENT_EXTENSION_DATA_MAP=P.PARENT_DEFINITION_DATA_MAP=void 0;P.OUTPUT_NODE_KINDS=P.INPUT_NODE_KINDS=P.IGNORED_FIELDS=P.INHERITABLE_DIRECTIVE_NAMES=P.PERSISTED_CLIENT_DIRECTIVES=P.AUTHORIZATION_DIRECTIVES=P.ROOT_TYPE_NAMES=P.EXECUTABLE_DIRECTIVE_LOCATIONS=P.CHANNELS=void 0;var au=Ae();P.AS="as";P.AND_UPPER="AND";P.ANY_SCALAR="_Any";P.ARGUMENT="argument";P.AUTHENTICATED="authenticated";P.ARGUMENT_DEFINITION_UPPER="ARGUMENT_DEFINITION";P.BOOLEAN="boolean";P.BOOLEAN_SCALAR="Boolean";P.COMPOSE_DIRECTIVE="composeDirective";P.CONDITION="condition";P.CONFIGURE_DESCRIPTION="openfed__configureDescription";P.CONFIGURE_CHILD_DESCRIPTIONS="openfed__configureChildDescriptions";P.CONSUMER_NAME="consumerName";P.DEFAULT="default";P.DEFAULT_EDFS_PROVIDER_ID="default";P.DEFAULT_MUTATION="Mutation";P.DEFAULT_QUERY="Query";P.DEFAULT_SUBSCRIPTION="Subscription";P.DEPRECATED="deprecated";P.DEPRECATED_DEFAULT_ARGUMENT_VALUE="No longer supported";P.DESCRIPTION_OVERRIDE="descriptionOverride";P.DIRECTIVE_DEFINITION="directive definition";P.EDFS_KAFKA_PUBLISH="edfs__kafkaPublish";P.EDFS_KAFKA_SUBSCRIBE="edfs__kafkaSubscribe";P.EDFS_NATS_PUBLISH="edfs__natsPublish";P.EDFS_NATS_REQUEST="edfs__natsRequest";P.EDFS_NATS_SUBSCRIBE="edfs__natsSubscribe";P.EDFS_PUBLISH_RESULT="edfs__PublishResult";P.EDFS_NATS_STREAM_CONFIGURATION="edfs__NatsStreamConfiguration";P.EDFS_REDIS_PUBLISH="edfs__redisPublish";P.EDFS_REDIS_SUBSCRIBE="edfs__redisSubscribe";P.ENTITIES="entities";P.ENTITIES_FIELD="_entities";P.ENTITY_UNION="_Entity";P.ENUM="Enum";P.ENUM_UPPER="ENUM";P.ENUM_VALUE="Enum Value";P.ENUM_VALUE_UPPER="ENUM_VALUE";P.EXECUTION="EXECUTION";P.EXTERNAL="external";P.EXTENDS="extends";P.EXTENSIONS="extensions";P.FIELD="field";P.FIELD_PATH="fieldPath";P.FIELD_UPPER="FIELD";P.FIELD_SET_SCALAR="openfed__FieldSet";P.FIELDS="fields";P.FIELD_DEFINITION_UPPER="FIELD_DEFINITION";P.FIRST_ORDINAL="1st";P.FLOAT_SCALAR="Float";P.FOR="for";P.FRAGMENT_DEFINITION_UPPER="FRAGMENT_DEFINITION";P.FRAGMENT_SPREAD_UPPER="FRAGMENT_SPREAD";P.FROM="from";P.HYPHEN_JOIN=` - -`;P.ID_SCALAR="ID";P.IMPORT="import";P.IN_UPPER="IN";P.INACCESSIBLE="inaccessible";P.INLINE_FRAGMENT="inlineFragment";P.INLINE_FRAGMENT_UPPER="INLINE_FRAGMENT";P.INPUT="Input";P.INPUT_FIELD="Input field";P.INPUT_FIELD_DEFINITION_UPPER="INPUT_FIELD_DEFINITION";P.INPUT_OBJECT="Input Object";P.INPUT_OBJECT_UPPER="INPUT_OBJECT";P.INPUT_VALUE="Input Value";P.INT_SCALAR="Int";P.INTERFACE="Interface";P.INTERFACE_UPPER="INTERFACE";P.INTERFACE_OBJECT="interfaceObject";P.KEY="key";P.LEFT_PARENTHESIS="(";P.LINK="link";P.LINK_IMPORT="link__Import";P.LINK_PURPOSE="link__Purpose";P.LIST="list";P.LITERAL_SPACE=" ";P.LITERAL_NEW_LINE=` -`;P.NUMBER="number";P.MUTATION="Mutation";P.MUTATION_UPPER="MUTATION";P.PROPAGATE="propagate";P.PROVIDER_TYPE_KAFKA="kafka";P.PROVIDER_TYPE_NATS="nats";P.PROVIDER_TYPE_REDIS="redis";P.NOT_APPLICABLE="N/A";P.NAME="name";P.NON_NULLABLE_EDFS_PUBLISH_EVENT_RESULT="edfs__PublishResult!";P.NON_NULLABLE_BOOLEAN="Boolean!";P.NON_NULLABLE_INT="Int!";P.NON_NULLABLE_STRING="String!";P.NOT_UPPER="NOT";P.NULL="Null";P.OPERATION_TO_DEFAULT="operationTypeNodeToDefaultType";P.OBJECT="Object";P.OBJECT_UPPER="OBJECT";P.OR_UPPER="OR";P.OVERRIDE="override";P.PARENT_DEFINITION_DATA="parentDefinitionDataByTypeName";P.PARENT_DEFINITION_DATA_MAP="parentDefinitionDataByParentTypeName";P.PARENT_EXTENSION_DATA_MAP="parentExtensionDataByParentTypeName";P.PERIOD=".";P.PROVIDER_ID="providerId";P.PROVIDES="provides";P.PUBLISH="publish";P.QUERY="Query";P.QUERY_UPPER="QUERY";P.QUOTATION_JOIN='", "';P.REASON="reason";P.REQUEST="request";P.REQUIRES="requires";P.REQUIRES_SCOPES="requiresScopes";P.RESOLVABLE="resolvable";P.SCALAR="Scalar";P.SCALAR_UPPER="SCALAR";P.SCHEMA="schema";P.SCHEMA_UPPER="SCHEMA";P.SCOPES="scopes";P.SCOPE_SCALAR="openfed__Scope";P.SECURITY="SECURITY";P.SELECTION_REPRESENTATION=" { ... }";P.SERVICE_OBJECT="_Service";P.SERVICE_FIELD="_service";P.SHAREABLE="shareable";P.SPECIFIED_BY="specifiedBy";P.STREAM_CONFIGURATION="streamConfiguration";P.CONSUMER_INACTIVE_THRESHOLD="consumerInactiveThreshold";P.STREAM_NAME="streamName";P.STRING="string";P.STRING_SCALAR="String";P.SUBJECT="subject";P.SUBJECTS="subjects";P.SUBSCRIPTION="Subscription";P.SUBSCRIPTION_FIELD_CONDITION="openfed__SubscriptionFieldCondition";P.SUBSCRIPTION_FILTER="openfed__subscriptionFilter";P.SUBSCRIPTION_FILTER_CONDITION="openfed__SubscriptionFilterCondition";P.SUBSCRIPTION_FILTER_VALUE="openfed__SubscriptionFilterValue";P.SUBSCRIBE="subscribe";P.SUBSCRIPTION_UPPER="SUBSCRIPTION";P.SUCCESS="success";P.TAG="tag";P.TOPIC="topic";P.TOPICS="topics";P.UNION="Union";P.UNION_UPPER="UNION";P.URL_LOWER="url";P.VALUES="values";P.VARIABLE_DEFINITION_UPPER="VARIABLE_DEFINITION";P.CHANNEL="channel";P.CHANNELS="channels";P.EXECUTABLE_DIRECTIVE_LOCATIONS=new Set([P.FIELD_UPPER,P.FRAGMENT_DEFINITION_UPPER,P.FRAGMENT_SPREAD_UPPER,P.INLINE_FRAGMENT_UPPER,P.MUTATION_UPPER,P.QUERY_UPPER,P.SUBSCRIPTION_UPPER]);P.ROOT_TYPE_NAMES=new Set([P.MUTATION,P.QUERY,P.SUBSCRIPTION]);P.AUTHORIZATION_DIRECTIVES=new Set([P.AUTHENTICATED,P.REQUIRES_SCOPES]);P.PERSISTED_CLIENT_DIRECTIVES=new Set([P.DEPRECATED]);P.INHERITABLE_DIRECTIVE_NAMES=new Set([P.EXTERNAL,P.SHAREABLE]);P.IGNORED_FIELDS=new Set([P.ENTITIES_FIELD,P.SERVICE_FIELD]);P.INPUT_NODE_KINDS=new Set([au.Kind.ENUM_TYPE_DEFINITION,au.Kind.INPUT_OBJECT_TYPE_DEFINITION,au.Kind.SCALAR_TYPE_DEFINITION]);P.OUTPUT_NODE_KINDS=new Set([au.Kind.ENUM_TYPE_DEFINITION,au.Kind.INTERFACE_TYPE_DEFINITION,au.Kind.OBJECT_TYPE_DEFINITION,au.Kind.SCALAR_TYPE_DEFINITION,au.Kind.UNION_TYPE_DEFINITION])});var Yr=w($n=>{"use strict";m();T();N();Object.defineProperty($n,"__esModule",{value:!0});$n.operationTypeNodeToDefaultType=void 0;$n.isObjectLikeNodeEntity=XX;$n.isNodeInterfaceObject=ZX;$n.stringToNameNode=FN;$n.stringArrayToNameNodeArray=e9;$n.setToNameNodeArray=t9;$n.stringToNamedTypeNode=aC;$n.setToNamedTypeNodeArray=n9;$n.nodeKindToDirectiveLocation=r9;$n.isKindAbstract=i9;$n.extractExecutableDirectiveLocations=a9;$n.formatDescription=s9;$n.lexicographicallySortArgumentNodes=sC;$n.lexicographicallySortSelectionSetNode=PN;$n.lexicographicallySortDocumentNode=o9;$n.parse=oC;$n.safeParse=u9;var Ut=Ae(),vn=ur();function XX(e){var t;if(!((t=e.directives)!=null&&t.length))return!1;for(let n of e.directives)if(n.name.value===vn.KEY)return!0;return!1}function ZX(e){var t;if(!((t=e.directives)!=null&&t.length))return!1;for(let n of e.directives)if(n.name.value===vn.INTERFACE_OBJECT)return!0;return!1}function FN(e){return{kind:Ut.Kind.NAME,value:e}}function e9(e){let t=[];for(let n of e)t.push(FN(n));return t}function t9(e){let t=[];for(let n of e)t.push(FN(n));return t}function aC(e){return{kind:Ut.Kind.NAMED_TYPE,name:FN(e)}}function n9(e){let t=[];for(let n of e)t.push(aC(n));return t}function r9(e){switch(e){case Ut.Kind.ARGUMENT:return vn.ARGUMENT_DEFINITION_UPPER;case Ut.Kind.ENUM_TYPE_DEFINITION:case Ut.Kind.ENUM_TYPE_EXTENSION:return vn.ENUM_UPPER;case Ut.Kind.ENUM_VALUE_DEFINITION:return vn.ENUM_VALUE_UPPER;case Ut.Kind.FIELD_DEFINITION:return vn.FIELD_DEFINITION_UPPER;case Ut.Kind.FRAGMENT_DEFINITION:return vn.FRAGMENT_DEFINITION_UPPER;case Ut.Kind.FRAGMENT_SPREAD:return vn.FRAGMENT_SPREAD_UPPER;case Ut.Kind.INLINE_FRAGMENT:return vn.INLINE_FRAGMENT_UPPER;case Ut.Kind.INPUT_VALUE_DEFINITION:return vn.INPUT_FIELD_DEFINITION_UPPER;case Ut.Kind.INPUT_OBJECT_TYPE_DEFINITION:case Ut.Kind.INPUT_OBJECT_TYPE_EXTENSION:return vn.INPUT_OBJECT_UPPER;case Ut.Kind.INTERFACE_TYPE_DEFINITION:case Ut.Kind.INTERFACE_TYPE_EXTENSION:return vn.INTERFACE_UPPER;case Ut.Kind.OBJECT_TYPE_DEFINITION:case Ut.Kind.OBJECT_TYPE_EXTENSION:return vn.OBJECT_UPPER;case Ut.Kind.SCALAR_TYPE_DEFINITION:case Ut.Kind.SCALAR_TYPE_EXTENSION:return vn.SCALAR_UPPER;case Ut.Kind.SCHEMA_DEFINITION:case Ut.Kind.SCHEMA_EXTENSION:return vn.SCHEMA_UPPER;case Ut.Kind.UNION_TYPE_DEFINITION:case Ut.Kind.UNION_TYPE_EXTENSION:return vn.UNION_UPPER;default:return e}}$n.operationTypeNodeToDefaultType=new Map([[Ut.OperationTypeNode.MUTATION,vn.MUTATION],[Ut.OperationTypeNode.QUERY,vn.QUERY],[Ut.OperationTypeNode.SUBSCRIPTION,vn.SUBSCRIPTION]]);function i9(e){return e===Ut.Kind.INTERFACE_TYPE_DEFINITION||e===Ut.Kind.UNION_TYPE_DEFINITION}function a9(e,t){for(let n of e){let r=n.value;vn.EXECUTABLE_DIRECTIVE_LOCATIONS.has(r)&&t.add(r)}return t}function s9(e){if(!e)return e;let t=e.value;if(e.block){let n=t.split(` +`}});var UL=w(iv=>{"use strict";m();T();N();Object.defineProperty(iv,"__esModule",{value:!0});iv.concatAST=NX;var mX=Pt();function NX(e){let t=[];for(let n of e)t.push(...n.definitions);return{kind:mX.Kind.DOCUMENT,definitions:t}}});var xL=w(av=>{"use strict";m();T();N();Object.defineProperty(av,"__esModule",{value:!0});av.separateOperations=EX;var bN=Pt(),TX=ju();function EX(e){let t=[],n=Object.create(null);for(let i of e.definitions)switch(i.kind){case bN.Kind.OPERATION_DEFINITION:t.push(i);break;case bN.Kind.FRAGMENT_DEFINITION:n[i.name.value]=kL(i.selectionSet);break;default:}let r=Object.create(null);for(let i of t){let a=new Set;for(let c of kL(i.selectionSet))ML(a,n,c);let o=i.name?i.name.value:"";r[o]={kind:bN.Kind.DOCUMENT,definitions:e.definitions.filter(c=>c===i||c.kind===bN.Kind.FRAGMENT_DEFINITION&&a.has(c.name.value))}}return r}function ML(e,t,n){if(!e.has(n)){e.add(n);let r=t[n];if(r!==void 0)for(let i of r)ML(e,t,i)}}function kL(e){let t=[];return(0,TX.visit)(e,{FragmentSpread(n){t.push(n.name.value)}}),t}});var jL=w(ov=>{"use strict";m();T();N();Object.defineProperty(ov,"__esModule",{value:!0});ov.stripIgnoredCharacters=yX;var hX=Od(),qL=hm(),VL=_m(),sv=bd();function yX(e){let t=(0,VL.isSource)(e)?e:new VL.Source(e),n=t.body,r=new qL.Lexer(t),i="",a=!1;for(;r.advance().kind!==sv.TokenKind.EOF;){let o=r.token,c=o.kind,l=!(0,qL.isPunctuatorTokenKind)(o.kind);a&&(l||o.kind===sv.TokenKind.SPREAD)&&(i+=" ");let p=n.slice(o.start,o.end);c===sv.TokenKind.BLOCK_STRING?i+=(0,hX.printBlockString)(o.value,{minimize:!0}):i+=p,a=l}return i}});var GL=w(AN=>{"use strict";m();T();N();Object.defineProperty(AN,"__esModule",{value:!0});AN.assertValidName=vX;AN.isValidNameError=KL;var IX=Lr(),gX=He(),_X=Bd();function vX(e){let t=KL(e);if(t)throw t;return e}function KL(e){if(typeof e=="string"||(0,IX.devAssert)(!1,"Expected name to be a string."),e.startsWith("__"))return new gX.GraphQLError(`Name "${e}" must not begin with "__", which is reserved by GraphQL introspection.`);try{(0,_X.assertName)(e)}catch(t){return t}}});var XL=w(La=>{"use strict";m();T();N();Object.defineProperty(La,"__esModule",{value:!0});La.DangerousChangeType=La.BreakingChangeType=void 0;La.findBreakingChanges=RX;La.findDangerousChanges=PX;var SX=Yt(),zL=yr(),$L=Wo(),OX=ci(),qt=Ft(),DX=ba(),bX=Yd(),AX=lg(),wn;La.BreakingChangeType=wn;(function(e){e.TYPE_REMOVED="TYPE_REMOVED",e.TYPE_CHANGED_KIND="TYPE_CHANGED_KIND",e.TYPE_REMOVED_FROM_UNION="TYPE_REMOVED_FROM_UNION",e.VALUE_REMOVED_FROM_ENUM="VALUE_REMOVED_FROM_ENUM",e.REQUIRED_INPUT_FIELD_ADDED="REQUIRED_INPUT_FIELD_ADDED",e.IMPLEMENTED_INTERFACE_REMOVED="IMPLEMENTED_INTERFACE_REMOVED",e.FIELD_REMOVED="FIELD_REMOVED",e.FIELD_CHANGED_KIND="FIELD_CHANGED_KIND",e.REQUIRED_ARG_ADDED="REQUIRED_ARG_ADDED",e.ARG_REMOVED="ARG_REMOVED",e.ARG_CHANGED_KIND="ARG_CHANGED_KIND",e.DIRECTIVE_REMOVED="DIRECTIVE_REMOVED",e.DIRECTIVE_ARG_REMOVED="DIRECTIVE_ARG_REMOVED",e.REQUIRED_DIRECTIVE_ARG_ADDED="REQUIRED_DIRECTIVE_ARG_ADDED",e.DIRECTIVE_REPEATABLE_REMOVED="DIRECTIVE_REPEATABLE_REMOVED",e.DIRECTIVE_LOCATION_REMOVED="DIRECTIVE_LOCATION_REMOVED"})(wn||(La.BreakingChangeType=wn={}));var ra;La.DangerousChangeType=ra;(function(e){e.VALUE_ADDED_TO_ENUM="VALUE_ADDED_TO_ENUM",e.TYPE_ADDED_TO_UNION="TYPE_ADDED_TO_UNION",e.OPTIONAL_INPUT_FIELD_ADDED="OPTIONAL_INPUT_FIELD_ADDED",e.OPTIONAL_ARG_ADDED="OPTIONAL_ARG_ADDED",e.IMPLEMENTED_INTERFACE_ADDED="IMPLEMENTED_INTERFACE_ADDED",e.ARG_DEFAULT_VALUE_CHANGE="ARG_DEFAULT_VALUE_CHANGE"})(ra||(La.DangerousChangeType=ra={}));function RX(e,t){return WL(e,t).filter(n=>n.type in wn)}function PX(e,t){return WL(e,t).filter(n=>n.type in ra)}function WL(e,t){return[...wX(e,t),...FX(e,t)]}function FX(e,t){let n=[],r=Ns(e.getDirectives(),t.getDirectives());for(let i of r.removed)n.push({type:wn.DIRECTIVE_REMOVED,description:`${i.name} was removed.`});for(let[i,a]of r.persisted){let o=Ns(i.args,a.args);for(let c of o.added)(0,qt.isRequiredArgument)(c)&&n.push({type:wn.REQUIRED_DIRECTIVE_ARG_ADDED,description:`A required arg ${c.name} on directive ${i.name} was added.`});for(let c of o.removed)n.push({type:wn.DIRECTIVE_ARG_REMOVED,description:`${c.name} was removed from ${i.name}.`});i.isRepeatable&&!a.isRepeatable&&n.push({type:wn.DIRECTIVE_REPEATABLE_REMOVED,description:`Repeatable flag was removed from ${i.name}.`});for(let c of i.locations)a.locations.includes(c)||n.push({type:wn.DIRECTIVE_LOCATION_REMOVED,description:`${c} was removed from ${i.name}.`})}return n}function wX(e,t){let n=[],r=Ns(Object.values(e.getTypeMap()),Object.values(t.getTypeMap()));for(let i of r.removed)n.push({type:wn.TYPE_REMOVED,description:(0,DX.isSpecifiedScalarType)(i)?`Standard scalar ${i.name} was removed because it is not referenced anymore.`:`${i.name} was removed.`});for(let[i,a]of r.persisted)(0,qt.isEnumType)(i)&&(0,qt.isEnumType)(a)?n.push(...BX(i,a)):(0,qt.isUnionType)(i)&&(0,qt.isUnionType)(a)?n.push(...CX(i,a)):(0,qt.isInputObjectType)(i)&&(0,qt.isInputObjectType)(a)?n.push(...LX(i,a)):(0,qt.isObjectType)(i)&&(0,qt.isObjectType)(a)?n.push(...YL(i,a),...QL(i,a)):(0,qt.isInterfaceType)(i)&&(0,qt.isInterfaceType)(a)?n.push(...YL(i,a),...QL(i,a)):i.constructor!==a.constructor&&n.push({type:wn.TYPE_CHANGED_KIND,description:`${i.name} changed from ${JL(i)} to ${JL(a)}.`});return n}function LX(e,t){let n=[],r=Ns(Object.values(e.getFields()),Object.values(t.getFields()));for(let i of r.added)(0,qt.isRequiredInputField)(i)?n.push({type:wn.REQUIRED_INPUT_FIELD_ADDED,description:`A required field ${i.name} on input type ${e.name} was added.`}):n.push({type:ra.OPTIONAL_INPUT_FIELD_ADDED,description:`An optional field ${i.name} on input type ${e.name} was added.`});for(let i of r.removed)n.push({type:wn.FIELD_REMOVED,description:`${e.name}.${i.name} was removed.`});for(let[i,a]of r.persisted)Tp(i.type,a.type)||n.push({type:wn.FIELD_CHANGED_KIND,description:`${e.name}.${i.name} changed type from ${String(i.type)} to ${String(a.type)}.`});return n}function CX(e,t){let n=[],r=Ns(e.getTypes(),t.getTypes());for(let i of r.added)n.push({type:ra.TYPE_ADDED_TO_UNION,description:`${i.name} was added to union type ${e.name}.`});for(let i of r.removed)n.push({type:wn.TYPE_REMOVED_FROM_UNION,description:`${i.name} was removed from union type ${e.name}.`});return n}function BX(e,t){let n=[],r=Ns(e.getValues(),t.getValues());for(let i of r.added)n.push({type:ra.VALUE_ADDED_TO_ENUM,description:`${i.name} was added to enum type ${e.name}.`});for(let i of r.removed)n.push({type:wn.VALUE_REMOVED_FROM_ENUM,description:`${i.name} was removed from enum type ${e.name}.`});return n}function QL(e,t){let n=[],r=Ns(e.getInterfaces(),t.getInterfaces());for(let i of r.added)n.push({type:ra.IMPLEMENTED_INTERFACE_ADDED,description:`${i.name} added to interfaces implemented by ${e.name}.`});for(let i of r.removed)n.push({type:wn.IMPLEMENTED_INTERFACE_REMOVED,description:`${e.name} no longer implements interface ${i.name}.`});return n}function YL(e,t){let n=[],r=Ns(Object.values(e.getFields()),Object.values(t.getFields()));for(let i of r.removed)n.push({type:wn.FIELD_REMOVED,description:`${e.name}.${i.name} was removed.`});for(let[i,a]of r.persisted)n.push(...UX(e,i,a)),Np(i.type,a.type)||n.push({type:wn.FIELD_CHANGED_KIND,description:`${e.name}.${i.name} changed type from ${String(i.type)} to ${String(a.type)}.`});return n}function UX(e,t,n){let r=[],i=Ns(t.args,n.args);for(let a of i.removed)r.push({type:wn.ARG_REMOVED,description:`${e.name}.${t.name} arg ${a.name} was removed.`});for(let[a,o]of i.persisted)if(!Tp(a.type,o.type))r.push({type:wn.ARG_CHANGED_KIND,description:`${e.name}.${t.name} arg ${a.name} has changed type from ${String(a.type)} to ${String(o.type)}.`});else if(a.defaultValue!==void 0)if(o.defaultValue===void 0)r.push({type:ra.ARG_DEFAULT_VALUE_CHANGE,description:`${e.name}.${t.name} arg ${a.name} defaultValue was removed.`});else{let l=HL(a.defaultValue,a.type),p=HL(o.defaultValue,o.type);l!==p&&r.push({type:ra.ARG_DEFAULT_VALUE_CHANGE,description:`${e.name}.${t.name} arg ${a.name} has changed defaultValue from ${l} to ${p}.`})}for(let a of i.added)(0,qt.isRequiredArgument)(a)?r.push({type:wn.REQUIRED_ARG_ADDED,description:`A required arg ${a.name} on ${e.name}.${t.name} was added.`}):r.push({type:ra.OPTIONAL_ARG_ADDED,description:`An optional arg ${a.name} on ${e.name}.${t.name} was added.`});return r}function Np(e,t){return(0,qt.isListType)(e)?(0,qt.isListType)(t)&&Np(e.ofType,t.ofType)||(0,qt.isNonNullType)(t)&&Np(e,t.ofType):(0,qt.isNonNullType)(e)?(0,qt.isNonNullType)(t)&&Np(e.ofType,t.ofType):(0,qt.isNamedType)(t)&&e.name===t.name||(0,qt.isNonNullType)(t)&&Np(e,t.ofType)}function Tp(e,t){return(0,qt.isListType)(e)?(0,qt.isListType)(t)&&Tp(e.ofType,t.ofType):(0,qt.isNonNullType)(e)?(0,qt.isNonNullType)(t)&&Tp(e.ofType,t.ofType)||!(0,qt.isNonNullType)(t)&&Tp(e.ofType,t):(0,qt.isNamedType)(t)&&e.name===t.name}function JL(e){if((0,qt.isScalarType)(e))return"a Scalar type";if((0,qt.isObjectType)(e))return"an Object type";if((0,qt.isInterfaceType)(e))return"an Interface type";if((0,qt.isUnionType)(e))return"a Union type";if((0,qt.isEnumType)(e))return"an Enum type";if((0,qt.isInputObjectType)(e))return"an Input type";(0,zL.invariant)(!1,"Unexpected type: "+(0,SX.inspect)(e))}function HL(e,t){let n=(0,bX.astFromValue)(e,t);return n!=null||(0,zL.invariant)(!1),(0,OX.print)((0,AX.sortValueNode)(n))}function Ns(e,t){let n=[],r=[],i=[],a=(0,$L.keyMap)(e,({name:c})=>c),o=(0,$L.keyMap)(t,({name:c})=>c);for(let c of e){let l=o[c.name];l===void 0?r.push(c):i.push([c,l])}for(let c of t)a[c.name]===void 0&&n.push(c);return{added:n,persisted:i,removed:r}}});var nC=w(Bt=>{"use strict";m();T();N();Object.defineProperty(Bt,"__esModule",{value:!0});Object.defineProperty(Bt,"BreakingChangeType",{enumerable:!0,get:function(){return RN.BreakingChangeType}});Object.defineProperty(Bt,"DangerousChangeType",{enumerable:!0,get:function(){return RN.DangerousChangeType}});Object.defineProperty(Bt,"TypeInfo",{enumerable:!0,get:function(){return eC.TypeInfo}});Object.defineProperty(Bt,"assertValidName",{enumerable:!0,get:function(){return tC.assertValidName}});Object.defineProperty(Bt,"astFromValue",{enumerable:!0,get:function(){return YX.astFromValue}});Object.defineProperty(Bt,"buildASTSchema",{enumerable:!0,get:function(){return ZL.buildASTSchema}});Object.defineProperty(Bt,"buildClientSchema",{enumerable:!0,get:function(){return VX.buildClientSchema}});Object.defineProperty(Bt,"buildSchema",{enumerable:!0,get:function(){return ZL.buildSchema}});Object.defineProperty(Bt,"coerceInputValue",{enumerable:!0,get:function(){return JX.coerceInputValue}});Object.defineProperty(Bt,"concatAST",{enumerable:!0,get:function(){return HX.concatAST}});Object.defineProperty(Bt,"doTypesOverlap",{enumerable:!0,get:function(){return cv.doTypesOverlap}});Object.defineProperty(Bt,"extendSchema",{enumerable:!0,get:function(){return jX.extendSchema}});Object.defineProperty(Bt,"findBreakingChanges",{enumerable:!0,get:function(){return RN.findBreakingChanges}});Object.defineProperty(Bt,"findDangerousChanges",{enumerable:!0,get:function(){return RN.findDangerousChanges}});Object.defineProperty(Bt,"getIntrospectionQuery",{enumerable:!0,get:function(){return kX.getIntrospectionQuery}});Object.defineProperty(Bt,"getOperationAST",{enumerable:!0,get:function(){return MX.getOperationAST}});Object.defineProperty(Bt,"getOperationRootType",{enumerable:!0,get:function(){return xX.getOperationRootType}});Object.defineProperty(Bt,"introspectionFromSchema",{enumerable:!0,get:function(){return qX.introspectionFromSchema}});Object.defineProperty(Bt,"isEqualType",{enumerable:!0,get:function(){return cv.isEqualType}});Object.defineProperty(Bt,"isTypeSubTypeOf",{enumerable:!0,get:function(){return cv.isTypeSubTypeOf}});Object.defineProperty(Bt,"isValidNameError",{enumerable:!0,get:function(){return tC.isValidNameError}});Object.defineProperty(Bt,"lexicographicSortSchema",{enumerable:!0,get:function(){return KX.lexicographicSortSchema}});Object.defineProperty(Bt,"printIntrospectionSchema",{enumerable:!0,get:function(){return uv.printIntrospectionSchema}});Object.defineProperty(Bt,"printSchema",{enumerable:!0,get:function(){return uv.printSchema}});Object.defineProperty(Bt,"printType",{enumerable:!0,get:function(){return uv.printType}});Object.defineProperty(Bt,"separateOperations",{enumerable:!0,get:function(){return zX.separateOperations}});Object.defineProperty(Bt,"stripIgnoredCharacters",{enumerable:!0,get:function(){return WX.stripIgnoredCharacters}});Object.defineProperty(Bt,"typeFromAST",{enumerable:!0,get:function(){return GX.typeFromAST}});Object.defineProperty(Bt,"valueFromAST",{enumerable:!0,get:function(){return $X.valueFromAST}});Object.defineProperty(Bt,"valueFromASTUntyped",{enumerable:!0,get:function(){return QX.valueFromASTUntyped}});Object.defineProperty(Bt,"visitWithTypeInfo",{enumerable:!0,get:function(){return eC.visitWithTypeInfo}});var kX=G_(),MX=dL(),xX=pL(),qX=fL(),VX=NL(),ZL=OL(),jX=z_(),KX=AL(),uv=BL(),GX=Aa(),$X=rp(),QX=sI(),YX=Yd(),eC=zm(),JX=Pg(),HX=UL(),zX=xL(),WX=jL(),cv=qd(),tC=GL(),RN=XL()});var Ae=w(V=>{"use strict";m();T();N();Object.defineProperty(V,"__esModule",{value:!0});Object.defineProperty(V,"BREAK",{enumerable:!0,get:function(){return Kt.BREAK}});Object.defineProperty(V,"BreakingChangeType",{enumerable:!0,get:function(){return Gt.BreakingChangeType}});Object.defineProperty(V,"DEFAULT_DEPRECATION_REASON",{enumerable:!0,get:function(){return Ie.DEFAULT_DEPRECATION_REASON}});Object.defineProperty(V,"DangerousChangeType",{enumerable:!0,get:function(){return Gt.DangerousChangeType}});Object.defineProperty(V,"DirectiveLocation",{enumerable:!0,get:function(){return Kt.DirectiveLocation}});Object.defineProperty(V,"ExecutableDefinitionsRule",{enumerable:!0,get:function(){return Tt.ExecutableDefinitionsRule}});Object.defineProperty(V,"FieldsOnCorrectTypeRule",{enumerable:!0,get:function(){return Tt.FieldsOnCorrectTypeRule}});Object.defineProperty(V,"FragmentsOnCompositeTypesRule",{enumerable:!0,get:function(){return Tt.FragmentsOnCompositeTypesRule}});Object.defineProperty(V,"GRAPHQL_MAX_INT",{enumerable:!0,get:function(){return Ie.GRAPHQL_MAX_INT}});Object.defineProperty(V,"GRAPHQL_MIN_INT",{enumerable:!0,get:function(){return Ie.GRAPHQL_MIN_INT}});Object.defineProperty(V,"GraphQLBoolean",{enumerable:!0,get:function(){return Ie.GraphQLBoolean}});Object.defineProperty(V,"GraphQLDeprecatedDirective",{enumerable:!0,get:function(){return Ie.GraphQLDeprecatedDirective}});Object.defineProperty(V,"GraphQLDirective",{enumerable:!0,get:function(){return Ie.GraphQLDirective}});Object.defineProperty(V,"GraphQLEnumType",{enumerable:!0,get:function(){return Ie.GraphQLEnumType}});Object.defineProperty(V,"GraphQLError",{enumerable:!0,get:function(){return Ep.GraphQLError}});Object.defineProperty(V,"GraphQLFloat",{enumerable:!0,get:function(){return Ie.GraphQLFloat}});Object.defineProperty(V,"GraphQLID",{enumerable:!0,get:function(){return Ie.GraphQLID}});Object.defineProperty(V,"GraphQLIncludeDirective",{enumerable:!0,get:function(){return Ie.GraphQLIncludeDirective}});Object.defineProperty(V,"GraphQLInputObjectType",{enumerable:!0,get:function(){return Ie.GraphQLInputObjectType}});Object.defineProperty(V,"GraphQLInt",{enumerable:!0,get:function(){return Ie.GraphQLInt}});Object.defineProperty(V,"GraphQLInterfaceType",{enumerable:!0,get:function(){return Ie.GraphQLInterfaceType}});Object.defineProperty(V,"GraphQLList",{enumerable:!0,get:function(){return Ie.GraphQLList}});Object.defineProperty(V,"GraphQLNonNull",{enumerable:!0,get:function(){return Ie.GraphQLNonNull}});Object.defineProperty(V,"GraphQLObjectType",{enumerable:!0,get:function(){return Ie.GraphQLObjectType}});Object.defineProperty(V,"GraphQLOneOfDirective",{enumerable:!0,get:function(){return Ie.GraphQLOneOfDirective}});Object.defineProperty(V,"GraphQLScalarType",{enumerable:!0,get:function(){return Ie.GraphQLScalarType}});Object.defineProperty(V,"GraphQLSchema",{enumerable:!0,get:function(){return Ie.GraphQLSchema}});Object.defineProperty(V,"GraphQLSkipDirective",{enumerable:!0,get:function(){return Ie.GraphQLSkipDirective}});Object.defineProperty(V,"GraphQLSpecifiedByDirective",{enumerable:!0,get:function(){return Ie.GraphQLSpecifiedByDirective}});Object.defineProperty(V,"GraphQLString",{enumerable:!0,get:function(){return Ie.GraphQLString}});Object.defineProperty(V,"GraphQLUnionType",{enumerable:!0,get:function(){return Ie.GraphQLUnionType}});Object.defineProperty(V,"Kind",{enumerable:!0,get:function(){return Kt.Kind}});Object.defineProperty(V,"KnownArgumentNamesRule",{enumerable:!0,get:function(){return Tt.KnownArgumentNamesRule}});Object.defineProperty(V,"KnownDirectivesRule",{enumerable:!0,get:function(){return Tt.KnownDirectivesRule}});Object.defineProperty(V,"KnownFragmentNamesRule",{enumerable:!0,get:function(){return Tt.KnownFragmentNamesRule}});Object.defineProperty(V,"KnownTypeNamesRule",{enumerable:!0,get:function(){return Tt.KnownTypeNamesRule}});Object.defineProperty(V,"Lexer",{enumerable:!0,get:function(){return Kt.Lexer}});Object.defineProperty(V,"Location",{enumerable:!0,get:function(){return Kt.Location}});Object.defineProperty(V,"LoneAnonymousOperationRule",{enumerable:!0,get:function(){return Tt.LoneAnonymousOperationRule}});Object.defineProperty(V,"LoneSchemaDefinitionRule",{enumerable:!0,get:function(){return Tt.LoneSchemaDefinitionRule}});Object.defineProperty(V,"MaxIntrospectionDepthRule",{enumerable:!0,get:function(){return Tt.MaxIntrospectionDepthRule}});Object.defineProperty(V,"NoDeprecatedCustomRule",{enumerable:!0,get:function(){return Tt.NoDeprecatedCustomRule}});Object.defineProperty(V,"NoFragmentCyclesRule",{enumerable:!0,get:function(){return Tt.NoFragmentCyclesRule}});Object.defineProperty(V,"NoSchemaIntrospectionCustomRule",{enumerable:!0,get:function(){return Tt.NoSchemaIntrospectionCustomRule}});Object.defineProperty(V,"NoUndefinedVariablesRule",{enumerable:!0,get:function(){return Tt.NoUndefinedVariablesRule}});Object.defineProperty(V,"NoUnusedFragmentsRule",{enumerable:!0,get:function(){return Tt.NoUnusedFragmentsRule}});Object.defineProperty(V,"NoUnusedVariablesRule",{enumerable:!0,get:function(){return Tt.NoUnusedVariablesRule}});Object.defineProperty(V,"OperationTypeNode",{enumerable:!0,get:function(){return Kt.OperationTypeNode}});Object.defineProperty(V,"OverlappingFieldsCanBeMergedRule",{enumerable:!0,get:function(){return Tt.OverlappingFieldsCanBeMergedRule}});Object.defineProperty(V,"PossibleFragmentSpreadsRule",{enumerable:!0,get:function(){return Tt.PossibleFragmentSpreadsRule}});Object.defineProperty(V,"PossibleTypeExtensionsRule",{enumerable:!0,get:function(){return Tt.PossibleTypeExtensionsRule}});Object.defineProperty(V,"ProvidedRequiredArgumentsRule",{enumerable:!0,get:function(){return Tt.ProvidedRequiredArgumentsRule}});Object.defineProperty(V,"ScalarLeafsRule",{enumerable:!0,get:function(){return Tt.ScalarLeafsRule}});Object.defineProperty(V,"SchemaMetaFieldDef",{enumerable:!0,get:function(){return Ie.SchemaMetaFieldDef}});Object.defineProperty(V,"SingleFieldSubscriptionsRule",{enumerable:!0,get:function(){return Tt.SingleFieldSubscriptionsRule}});Object.defineProperty(V,"Source",{enumerable:!0,get:function(){return Kt.Source}});Object.defineProperty(V,"Token",{enumerable:!0,get:function(){return Kt.Token}});Object.defineProperty(V,"TokenKind",{enumerable:!0,get:function(){return Kt.TokenKind}});Object.defineProperty(V,"TypeInfo",{enumerable:!0,get:function(){return Gt.TypeInfo}});Object.defineProperty(V,"TypeKind",{enumerable:!0,get:function(){return Ie.TypeKind}});Object.defineProperty(V,"TypeMetaFieldDef",{enumerable:!0,get:function(){return Ie.TypeMetaFieldDef}});Object.defineProperty(V,"TypeNameMetaFieldDef",{enumerable:!0,get:function(){return Ie.TypeNameMetaFieldDef}});Object.defineProperty(V,"UniqueArgumentDefinitionNamesRule",{enumerable:!0,get:function(){return Tt.UniqueArgumentDefinitionNamesRule}});Object.defineProperty(V,"UniqueArgumentNamesRule",{enumerable:!0,get:function(){return Tt.UniqueArgumentNamesRule}});Object.defineProperty(V,"UniqueDirectiveNamesRule",{enumerable:!0,get:function(){return Tt.UniqueDirectiveNamesRule}});Object.defineProperty(V,"UniqueDirectivesPerLocationRule",{enumerable:!0,get:function(){return Tt.UniqueDirectivesPerLocationRule}});Object.defineProperty(V,"UniqueEnumValueNamesRule",{enumerable:!0,get:function(){return Tt.UniqueEnumValueNamesRule}});Object.defineProperty(V,"UniqueFieldDefinitionNamesRule",{enumerable:!0,get:function(){return Tt.UniqueFieldDefinitionNamesRule}});Object.defineProperty(V,"UniqueFragmentNamesRule",{enumerable:!0,get:function(){return Tt.UniqueFragmentNamesRule}});Object.defineProperty(V,"UniqueInputFieldNamesRule",{enumerable:!0,get:function(){return Tt.UniqueInputFieldNamesRule}});Object.defineProperty(V,"UniqueOperationNamesRule",{enumerable:!0,get:function(){return Tt.UniqueOperationNamesRule}});Object.defineProperty(V,"UniqueOperationTypesRule",{enumerable:!0,get:function(){return Tt.UniqueOperationTypesRule}});Object.defineProperty(V,"UniqueTypeNamesRule",{enumerable:!0,get:function(){return Tt.UniqueTypeNamesRule}});Object.defineProperty(V,"UniqueVariableNamesRule",{enumerable:!0,get:function(){return Tt.UniqueVariableNamesRule}});Object.defineProperty(V,"ValidationContext",{enumerable:!0,get:function(){return Tt.ValidationContext}});Object.defineProperty(V,"ValuesOfCorrectTypeRule",{enumerable:!0,get:function(){return Tt.ValuesOfCorrectTypeRule}});Object.defineProperty(V,"VariablesAreInputTypesRule",{enumerable:!0,get:function(){return Tt.VariablesAreInputTypesRule}});Object.defineProperty(V,"VariablesInAllowedPositionRule",{enumerable:!0,get:function(){return Tt.VariablesInAllowedPositionRule}});Object.defineProperty(V,"__Directive",{enumerable:!0,get:function(){return Ie.__Directive}});Object.defineProperty(V,"__DirectiveLocation",{enumerable:!0,get:function(){return Ie.__DirectiveLocation}});Object.defineProperty(V,"__EnumValue",{enumerable:!0,get:function(){return Ie.__EnumValue}});Object.defineProperty(V,"__Field",{enumerable:!0,get:function(){return Ie.__Field}});Object.defineProperty(V,"__InputValue",{enumerable:!0,get:function(){return Ie.__InputValue}});Object.defineProperty(V,"__Schema",{enumerable:!0,get:function(){return Ie.__Schema}});Object.defineProperty(V,"__Type",{enumerable:!0,get:function(){return Ie.__Type}});Object.defineProperty(V,"__TypeKind",{enumerable:!0,get:function(){return Ie.__TypeKind}});Object.defineProperty(V,"assertAbstractType",{enumerable:!0,get:function(){return Ie.assertAbstractType}});Object.defineProperty(V,"assertCompositeType",{enumerable:!0,get:function(){return Ie.assertCompositeType}});Object.defineProperty(V,"assertDirective",{enumerable:!0,get:function(){return Ie.assertDirective}});Object.defineProperty(V,"assertEnumType",{enumerable:!0,get:function(){return Ie.assertEnumType}});Object.defineProperty(V,"assertEnumValueName",{enumerable:!0,get:function(){return Ie.assertEnumValueName}});Object.defineProperty(V,"assertInputObjectType",{enumerable:!0,get:function(){return Ie.assertInputObjectType}});Object.defineProperty(V,"assertInputType",{enumerable:!0,get:function(){return Ie.assertInputType}});Object.defineProperty(V,"assertInterfaceType",{enumerable:!0,get:function(){return Ie.assertInterfaceType}});Object.defineProperty(V,"assertLeafType",{enumerable:!0,get:function(){return Ie.assertLeafType}});Object.defineProperty(V,"assertListType",{enumerable:!0,get:function(){return Ie.assertListType}});Object.defineProperty(V,"assertName",{enumerable:!0,get:function(){return Ie.assertName}});Object.defineProperty(V,"assertNamedType",{enumerable:!0,get:function(){return Ie.assertNamedType}});Object.defineProperty(V,"assertNonNullType",{enumerable:!0,get:function(){return Ie.assertNonNullType}});Object.defineProperty(V,"assertNullableType",{enumerable:!0,get:function(){return Ie.assertNullableType}});Object.defineProperty(V,"assertObjectType",{enumerable:!0,get:function(){return Ie.assertObjectType}});Object.defineProperty(V,"assertOutputType",{enumerable:!0,get:function(){return Ie.assertOutputType}});Object.defineProperty(V,"assertScalarType",{enumerable:!0,get:function(){return Ie.assertScalarType}});Object.defineProperty(V,"assertSchema",{enumerable:!0,get:function(){return Ie.assertSchema}});Object.defineProperty(V,"assertType",{enumerable:!0,get:function(){return Ie.assertType}});Object.defineProperty(V,"assertUnionType",{enumerable:!0,get:function(){return Ie.assertUnionType}});Object.defineProperty(V,"assertValidName",{enumerable:!0,get:function(){return Gt.assertValidName}});Object.defineProperty(V,"assertValidSchema",{enumerable:!0,get:function(){return Ie.assertValidSchema}});Object.defineProperty(V,"assertWrappingType",{enumerable:!0,get:function(){return Ie.assertWrappingType}});Object.defineProperty(V,"astFromValue",{enumerable:!0,get:function(){return Gt.astFromValue}});Object.defineProperty(V,"buildASTSchema",{enumerable:!0,get:function(){return Gt.buildASTSchema}});Object.defineProperty(V,"buildClientSchema",{enumerable:!0,get:function(){return Gt.buildClientSchema}});Object.defineProperty(V,"buildSchema",{enumerable:!0,get:function(){return Gt.buildSchema}});Object.defineProperty(V,"coerceInputValue",{enumerable:!0,get:function(){return Gt.coerceInputValue}});Object.defineProperty(V,"concatAST",{enumerable:!0,get:function(){return Gt.concatAST}});Object.defineProperty(V,"createSourceEventStream",{enumerable:!0,get:function(){return Ca.createSourceEventStream}});Object.defineProperty(V,"defaultFieldResolver",{enumerable:!0,get:function(){return Ca.defaultFieldResolver}});Object.defineProperty(V,"defaultTypeResolver",{enumerable:!0,get:function(){return Ca.defaultTypeResolver}});Object.defineProperty(V,"doTypesOverlap",{enumerable:!0,get:function(){return Gt.doTypesOverlap}});Object.defineProperty(V,"execute",{enumerable:!0,get:function(){return Ca.execute}});Object.defineProperty(V,"executeSync",{enumerable:!0,get:function(){return Ca.executeSync}});Object.defineProperty(V,"extendSchema",{enumerable:!0,get:function(){return Gt.extendSchema}});Object.defineProperty(V,"findBreakingChanges",{enumerable:!0,get:function(){return Gt.findBreakingChanges}});Object.defineProperty(V,"findDangerousChanges",{enumerable:!0,get:function(){return Gt.findDangerousChanges}});Object.defineProperty(V,"formatError",{enumerable:!0,get:function(){return Ep.formatError}});Object.defineProperty(V,"getArgumentValues",{enumerable:!0,get:function(){return Ca.getArgumentValues}});Object.defineProperty(V,"getDirectiveValues",{enumerable:!0,get:function(){return Ca.getDirectiveValues}});Object.defineProperty(V,"getEnterLeaveForKind",{enumerable:!0,get:function(){return Kt.getEnterLeaveForKind}});Object.defineProperty(V,"getIntrospectionQuery",{enumerable:!0,get:function(){return Gt.getIntrospectionQuery}});Object.defineProperty(V,"getLocation",{enumerable:!0,get:function(){return Kt.getLocation}});Object.defineProperty(V,"getNamedType",{enumerable:!0,get:function(){return Ie.getNamedType}});Object.defineProperty(V,"getNullableType",{enumerable:!0,get:function(){return Ie.getNullableType}});Object.defineProperty(V,"getOperationAST",{enumerable:!0,get:function(){return Gt.getOperationAST}});Object.defineProperty(V,"getOperationRootType",{enumerable:!0,get:function(){return Gt.getOperationRootType}});Object.defineProperty(V,"getVariableValues",{enumerable:!0,get:function(){return Ca.getVariableValues}});Object.defineProperty(V,"getVisitFn",{enumerable:!0,get:function(){return Kt.getVisitFn}});Object.defineProperty(V,"graphql",{enumerable:!0,get:function(){return iC.graphql}});Object.defineProperty(V,"graphqlSync",{enumerable:!0,get:function(){return iC.graphqlSync}});Object.defineProperty(V,"introspectionFromSchema",{enumerable:!0,get:function(){return Gt.introspectionFromSchema}});Object.defineProperty(V,"introspectionTypes",{enumerable:!0,get:function(){return Ie.introspectionTypes}});Object.defineProperty(V,"isAbstractType",{enumerable:!0,get:function(){return Ie.isAbstractType}});Object.defineProperty(V,"isCompositeType",{enumerable:!0,get:function(){return Ie.isCompositeType}});Object.defineProperty(V,"isConstValueNode",{enumerable:!0,get:function(){return Kt.isConstValueNode}});Object.defineProperty(V,"isDefinitionNode",{enumerable:!0,get:function(){return Kt.isDefinitionNode}});Object.defineProperty(V,"isDirective",{enumerable:!0,get:function(){return Ie.isDirective}});Object.defineProperty(V,"isEnumType",{enumerable:!0,get:function(){return Ie.isEnumType}});Object.defineProperty(V,"isEqualType",{enumerable:!0,get:function(){return Gt.isEqualType}});Object.defineProperty(V,"isExecutableDefinitionNode",{enumerable:!0,get:function(){return Kt.isExecutableDefinitionNode}});Object.defineProperty(V,"isInputObjectType",{enumerable:!0,get:function(){return Ie.isInputObjectType}});Object.defineProperty(V,"isInputType",{enumerable:!0,get:function(){return Ie.isInputType}});Object.defineProperty(V,"isInterfaceType",{enumerable:!0,get:function(){return Ie.isInterfaceType}});Object.defineProperty(V,"isIntrospectionType",{enumerable:!0,get:function(){return Ie.isIntrospectionType}});Object.defineProperty(V,"isLeafType",{enumerable:!0,get:function(){return Ie.isLeafType}});Object.defineProperty(V,"isListType",{enumerable:!0,get:function(){return Ie.isListType}});Object.defineProperty(V,"isNamedType",{enumerable:!0,get:function(){return Ie.isNamedType}});Object.defineProperty(V,"isNonNullType",{enumerable:!0,get:function(){return Ie.isNonNullType}});Object.defineProperty(V,"isNullableType",{enumerable:!0,get:function(){return Ie.isNullableType}});Object.defineProperty(V,"isObjectType",{enumerable:!0,get:function(){return Ie.isObjectType}});Object.defineProperty(V,"isOutputType",{enumerable:!0,get:function(){return Ie.isOutputType}});Object.defineProperty(V,"isRequiredArgument",{enumerable:!0,get:function(){return Ie.isRequiredArgument}});Object.defineProperty(V,"isRequiredInputField",{enumerable:!0,get:function(){return Ie.isRequiredInputField}});Object.defineProperty(V,"isScalarType",{enumerable:!0,get:function(){return Ie.isScalarType}});Object.defineProperty(V,"isSchema",{enumerable:!0,get:function(){return Ie.isSchema}});Object.defineProperty(V,"isSelectionNode",{enumerable:!0,get:function(){return Kt.isSelectionNode}});Object.defineProperty(V,"isSpecifiedDirective",{enumerable:!0,get:function(){return Ie.isSpecifiedDirective}});Object.defineProperty(V,"isSpecifiedScalarType",{enumerable:!0,get:function(){return Ie.isSpecifiedScalarType}});Object.defineProperty(V,"isType",{enumerable:!0,get:function(){return Ie.isType}});Object.defineProperty(V,"isTypeDefinitionNode",{enumerable:!0,get:function(){return Kt.isTypeDefinitionNode}});Object.defineProperty(V,"isTypeExtensionNode",{enumerable:!0,get:function(){return Kt.isTypeExtensionNode}});Object.defineProperty(V,"isTypeNode",{enumerable:!0,get:function(){return Kt.isTypeNode}});Object.defineProperty(V,"isTypeSubTypeOf",{enumerable:!0,get:function(){return Gt.isTypeSubTypeOf}});Object.defineProperty(V,"isTypeSystemDefinitionNode",{enumerable:!0,get:function(){return Kt.isTypeSystemDefinitionNode}});Object.defineProperty(V,"isTypeSystemExtensionNode",{enumerable:!0,get:function(){return Kt.isTypeSystemExtensionNode}});Object.defineProperty(V,"isUnionType",{enumerable:!0,get:function(){return Ie.isUnionType}});Object.defineProperty(V,"isValidNameError",{enumerable:!0,get:function(){return Gt.isValidNameError}});Object.defineProperty(V,"isValueNode",{enumerable:!0,get:function(){return Kt.isValueNode}});Object.defineProperty(V,"isWrappingType",{enumerable:!0,get:function(){return Ie.isWrappingType}});Object.defineProperty(V,"lexicographicSortSchema",{enumerable:!0,get:function(){return Gt.lexicographicSortSchema}});Object.defineProperty(V,"locatedError",{enumerable:!0,get:function(){return Ep.locatedError}});Object.defineProperty(V,"parse",{enumerable:!0,get:function(){return Kt.parse}});Object.defineProperty(V,"parseConstValue",{enumerable:!0,get:function(){return Kt.parseConstValue}});Object.defineProperty(V,"parseType",{enumerable:!0,get:function(){return Kt.parseType}});Object.defineProperty(V,"parseValue",{enumerable:!0,get:function(){return Kt.parseValue}});Object.defineProperty(V,"print",{enumerable:!0,get:function(){return Kt.print}});Object.defineProperty(V,"printError",{enumerable:!0,get:function(){return Ep.printError}});Object.defineProperty(V,"printIntrospectionSchema",{enumerable:!0,get:function(){return Gt.printIntrospectionSchema}});Object.defineProperty(V,"printLocation",{enumerable:!0,get:function(){return Kt.printLocation}});Object.defineProperty(V,"printSchema",{enumerable:!0,get:function(){return Gt.printSchema}});Object.defineProperty(V,"printSourceLocation",{enumerable:!0,get:function(){return Kt.printSourceLocation}});Object.defineProperty(V,"printType",{enumerable:!0,get:function(){return Gt.printType}});Object.defineProperty(V,"recommendedRules",{enumerable:!0,get:function(){return Tt.recommendedRules}});Object.defineProperty(V,"resolveObjMapThunk",{enumerable:!0,get:function(){return Ie.resolveObjMapThunk}});Object.defineProperty(V,"resolveReadonlyArrayThunk",{enumerable:!0,get:function(){return Ie.resolveReadonlyArrayThunk}});Object.defineProperty(V,"responsePathAsArray",{enumerable:!0,get:function(){return Ca.responsePathAsArray}});Object.defineProperty(V,"separateOperations",{enumerable:!0,get:function(){return Gt.separateOperations}});Object.defineProperty(V,"specifiedDirectives",{enumerable:!0,get:function(){return Ie.specifiedDirectives}});Object.defineProperty(V,"specifiedRules",{enumerable:!0,get:function(){return Tt.specifiedRules}});Object.defineProperty(V,"specifiedScalarTypes",{enumerable:!0,get:function(){return Ie.specifiedScalarTypes}});Object.defineProperty(V,"stripIgnoredCharacters",{enumerable:!0,get:function(){return Gt.stripIgnoredCharacters}});Object.defineProperty(V,"subscribe",{enumerable:!0,get:function(){return Ca.subscribe}});Object.defineProperty(V,"syntaxError",{enumerable:!0,get:function(){return Ep.syntaxError}});Object.defineProperty(V,"typeFromAST",{enumerable:!0,get:function(){return Gt.typeFromAST}});Object.defineProperty(V,"validate",{enumerable:!0,get:function(){return Tt.validate}});Object.defineProperty(V,"validateSchema",{enumerable:!0,get:function(){return Ie.validateSchema}});Object.defineProperty(V,"valueFromAST",{enumerable:!0,get:function(){return Gt.valueFromAST}});Object.defineProperty(V,"valueFromASTUntyped",{enumerable:!0,get:function(){return Gt.valueFromASTUntyped}});Object.defineProperty(V,"version",{enumerable:!0,get:function(){return rC.version}});Object.defineProperty(V,"versionInfo",{enumerable:!0,get:function(){return rC.versionInfo}});Object.defineProperty(V,"visit",{enumerable:!0,get:function(){return Kt.visit}});Object.defineProperty(V,"visitInParallel",{enumerable:!0,get:function(){return Kt.visitInParallel}});Object.defineProperty(V,"visitWithTypeInfo",{enumerable:!0,get:function(){return Gt.visitWithTypeInfo}});var rC=XR(),iC=Qw(),Ie=Hw(),Kt=Ww(),Ca=aL(),Tt=cL(),Ep=lL(),Gt=nC()});var ur=w(F=>{"use strict";m();T();N();Object.defineProperty(F,"__esModule",{value:!0});F.FLOAT_SCALAR=F.FIRST_ORDINAL=F.FIELD_DEFINITION_UPPER=F.FIELDS=F.FIELD_SET_SCALAR=F.FIELD_UPPER=F.FIELD_PATH=F.FIELD=F.EXTENSIONS=F.EXTENDS=F.EXTERNAL=F.EXECUTION=F.ENUM_VALUE_UPPER=F.ENUM_VALUE=F.ENUM_UPPER=F.ENUM=F.ENTITY_UNION=F.ENTITIES_FIELD=F.ENTITIES=F.EDFS_REDIS_SUBSCRIBE=F.EDFS_REDIS_PUBLISH=F.EDFS_NATS_STREAM_CONFIGURATION=F.EDFS_PUBLISH_RESULT=F.EDFS_NATS_SUBSCRIBE=F.EDFS_NATS_REQUEST=F.EDFS_NATS_PUBLISH=F.EDFS_KAFKA_SUBSCRIBE=F.EDFS_KAFKA_PUBLISH=F.DIRECTIVE_DEFINITION=F.DESCRIPTION_OVERRIDE=F.DEPRECATED_DEFAULT_ARGUMENT_VALUE=F.DEPRECATED=F.DEFAULT_SUBSCRIPTION=F.DEFAULT_QUERY=F.DEFAULT_MUTATION=F.DEFAULT_EDFS_PROVIDER_ID=F.DEFAULT=F.CONSUMER_NAME=F.CONFIGURE_CHILD_DESCRIPTIONS=F.CONFIGURE_DESCRIPTION=F.CONDITION=F.COMPOSE_DIRECTIVE=F.BOOLEAN_SCALAR=F.BOOLEAN=F.ARGUMENT_DEFINITION_UPPER=F.AUTHENTICATED=F.ARGUMENT=F.ANY_SCALAR=F.AND_UPPER=F.AS=void 0;F.PARENT_DEFINITION_DATA=F.OVERRIDE=F.OR_UPPER=F.OBJECT_UPPER=F.OBJECT=F.OPERATION_TO_DEFAULT=F.NULL=F.NOT_UPPER=F.NON_NULLABLE_STRING=F.NON_NULLABLE_INT=F.NON_NULLABLE_BOOLEAN=F.NON_NULLABLE_EDFS_PUBLISH_EVENT_RESULT=F.NAME=F.NOT_APPLICABLE=F.PROVIDER_TYPE_REDIS=F.PROVIDER_TYPE_NATS=F.PROVIDER_TYPE_KAFKA=F.PROPAGATE=F.MUTATION_UPPER=F.MUTATION=F.NUMBER=F.LITERAL_NEW_LINE=F.LITERAL_SPACE=F.LIST=F.LINK_PURPOSE=F.LINK_IMPORT=F.LINK=F.LEFT_PARENTHESIS=F.KEY=F.INTERFACE_OBJECT=F.INTERFACE_UPPER=F.INTERFACE=F.INT_SCALAR=F.INPUT_VALUE=F.INPUT_OBJECT_UPPER=F.INPUT_OBJECT=F.INPUT_FIELD_DEFINITION_UPPER=F.INPUT_FIELD=F.INPUT=F.INLINE_FRAGMENT_UPPER=F.INLINE_FRAGMENT=F.INACCESSIBLE=F.IN_UPPER=F.IMPORT=F.ID_SCALAR=F.HYPHEN_JOIN=F.FROM=F.FRAGMENT_SPREAD_UPPER=F.FRAGMENT_DEFINITION_UPPER=F.FOR=void 0;F.CHANNEL=F.VARIABLE_DEFINITION_UPPER=F.VALUES=F.URL_LOWER=F.UNION_UPPER=F.UNION=F.TOPICS=F.TOPIC=F.TAG=F.SUCCESS=F.SUBSCRIPTION_UPPER=F.SUBSCRIBE=F.SUBSCRIPTION_FILTER_VALUE=F.SUBSCRIPTION_FILTER_CONDITION=F.SUBSCRIPTION_FILTER=F.SUBSCRIPTION_FIELD_CONDITION=F.SUBSCRIPTION=F.SUBJECTS=F.SUBJECT=F.STRING_SCALAR=F.STRING=F.STREAM_NAME=F.CONSUMER_INACTIVE_THRESHOLD=F.STREAM_CONFIGURATION=F.SPECIFIED_BY=F.SHAREABLE=F.SERVICE_FIELD=F.SERVICE_OBJECT=F.SELECTION_REPRESENTATION=F.SECURITY=F.SCOPE_SCALAR=F.SCOPES=F.SCHEMA_UPPER=F.SCHEMA=F.SCALAR_UPPER=F.SCALAR=F.RESOLVABLE=F.REQUIRES_SCOPES=F.REQUIRES=F.REQUEST=F.REASON=F.QUOTATION_JOIN=F.QUERY_UPPER=F.QUERY=F.PUBLISH=F.PROVIDES=F.PROVIDER_ID=F.PERIOD=F.PARENT_EXTENSION_DATA_MAP=F.PARENT_DEFINITION_DATA_MAP=void 0;F.OUTPUT_NODE_KINDS=F.INPUT_NODE_KINDS=F.IGNORED_FIELDS=F.INHERITABLE_DIRECTIVE_NAMES=F.PERSISTED_CLIENT_DIRECTIVES=F.AUTHORIZATION_DIRECTIVES=F.ROOT_TYPE_NAMES=F.EXECUTABLE_DIRECTIVE_LOCATIONS=F.CHANNELS=void 0;var au=Ae();F.AS="as";F.AND_UPPER="AND";F.ANY_SCALAR="_Any";F.ARGUMENT="argument";F.AUTHENTICATED="authenticated";F.ARGUMENT_DEFINITION_UPPER="ARGUMENT_DEFINITION";F.BOOLEAN="boolean";F.BOOLEAN_SCALAR="Boolean";F.COMPOSE_DIRECTIVE="composeDirective";F.CONDITION="condition";F.CONFIGURE_DESCRIPTION="openfed__configureDescription";F.CONFIGURE_CHILD_DESCRIPTIONS="openfed__configureChildDescriptions";F.CONSUMER_NAME="consumerName";F.DEFAULT="default";F.DEFAULT_EDFS_PROVIDER_ID="default";F.DEFAULT_MUTATION="Mutation";F.DEFAULT_QUERY="Query";F.DEFAULT_SUBSCRIPTION="Subscription";F.DEPRECATED="deprecated";F.DEPRECATED_DEFAULT_ARGUMENT_VALUE="No longer supported";F.DESCRIPTION_OVERRIDE="descriptionOverride";F.DIRECTIVE_DEFINITION="directive definition";F.EDFS_KAFKA_PUBLISH="edfs__kafkaPublish";F.EDFS_KAFKA_SUBSCRIBE="edfs__kafkaSubscribe";F.EDFS_NATS_PUBLISH="edfs__natsPublish";F.EDFS_NATS_REQUEST="edfs__natsRequest";F.EDFS_NATS_SUBSCRIBE="edfs__natsSubscribe";F.EDFS_PUBLISH_RESULT="edfs__PublishResult";F.EDFS_NATS_STREAM_CONFIGURATION="edfs__NatsStreamConfiguration";F.EDFS_REDIS_PUBLISH="edfs__redisPublish";F.EDFS_REDIS_SUBSCRIBE="edfs__redisSubscribe";F.ENTITIES="entities";F.ENTITIES_FIELD="_entities";F.ENTITY_UNION="_Entity";F.ENUM="Enum";F.ENUM_UPPER="ENUM";F.ENUM_VALUE="Enum Value";F.ENUM_VALUE_UPPER="ENUM_VALUE";F.EXECUTION="EXECUTION";F.EXTERNAL="external";F.EXTENDS="extends";F.EXTENSIONS="extensions";F.FIELD="field";F.FIELD_PATH="fieldPath";F.FIELD_UPPER="FIELD";F.FIELD_SET_SCALAR="openfed__FieldSet";F.FIELDS="fields";F.FIELD_DEFINITION_UPPER="FIELD_DEFINITION";F.FIRST_ORDINAL="1st";F.FLOAT_SCALAR="Float";F.FOR="for";F.FRAGMENT_DEFINITION_UPPER="FRAGMENT_DEFINITION";F.FRAGMENT_SPREAD_UPPER="FRAGMENT_SPREAD";F.FROM="from";F.HYPHEN_JOIN=` + -`;F.ID_SCALAR="ID";F.IMPORT="import";F.IN_UPPER="IN";F.INACCESSIBLE="inaccessible";F.INLINE_FRAGMENT="inlineFragment";F.INLINE_FRAGMENT_UPPER="INLINE_FRAGMENT";F.INPUT="Input";F.INPUT_FIELD="Input field";F.INPUT_FIELD_DEFINITION_UPPER="INPUT_FIELD_DEFINITION";F.INPUT_OBJECT="Input Object";F.INPUT_OBJECT_UPPER="INPUT_OBJECT";F.INPUT_VALUE="Input Value";F.INT_SCALAR="Int";F.INTERFACE="Interface";F.INTERFACE_UPPER="INTERFACE";F.INTERFACE_OBJECT="interfaceObject";F.KEY="key";F.LEFT_PARENTHESIS="(";F.LINK="link";F.LINK_IMPORT="link__Import";F.LINK_PURPOSE="link__Purpose";F.LIST="list";F.LITERAL_SPACE=" ";F.LITERAL_NEW_LINE=` +`;F.NUMBER="number";F.MUTATION="Mutation";F.MUTATION_UPPER="MUTATION";F.PROPAGATE="propagate";F.PROVIDER_TYPE_KAFKA="kafka";F.PROVIDER_TYPE_NATS="nats";F.PROVIDER_TYPE_REDIS="redis";F.NOT_APPLICABLE="N/A";F.NAME="name";F.NON_NULLABLE_EDFS_PUBLISH_EVENT_RESULT="edfs__PublishResult!";F.NON_NULLABLE_BOOLEAN="Boolean!";F.NON_NULLABLE_INT="Int!";F.NON_NULLABLE_STRING="String!";F.NOT_UPPER="NOT";F.NULL="Null";F.OPERATION_TO_DEFAULT="operationTypeNodeToDefaultType";F.OBJECT="Object";F.OBJECT_UPPER="OBJECT";F.OR_UPPER="OR";F.OVERRIDE="override";F.PARENT_DEFINITION_DATA="parentDefinitionDataByTypeName";F.PARENT_DEFINITION_DATA_MAP="parentDefinitionDataByParentTypeName";F.PARENT_EXTENSION_DATA_MAP="parentExtensionDataByParentTypeName";F.PERIOD=".";F.PROVIDER_ID="providerId";F.PROVIDES="provides";F.PUBLISH="publish";F.QUERY="Query";F.QUERY_UPPER="QUERY";F.QUOTATION_JOIN='", "';F.REASON="reason";F.REQUEST="request";F.REQUIRES="requires";F.REQUIRES_SCOPES="requiresScopes";F.RESOLVABLE="resolvable";F.SCALAR="Scalar";F.SCALAR_UPPER="SCALAR";F.SCHEMA="schema";F.SCHEMA_UPPER="SCHEMA";F.SCOPES="scopes";F.SCOPE_SCALAR="openfed__Scope";F.SECURITY="SECURITY";F.SELECTION_REPRESENTATION=" { ... }";F.SERVICE_OBJECT="_Service";F.SERVICE_FIELD="_service";F.SHAREABLE="shareable";F.SPECIFIED_BY="specifiedBy";F.STREAM_CONFIGURATION="streamConfiguration";F.CONSUMER_INACTIVE_THRESHOLD="consumerInactiveThreshold";F.STREAM_NAME="streamName";F.STRING="string";F.STRING_SCALAR="String";F.SUBJECT="subject";F.SUBJECTS="subjects";F.SUBSCRIPTION="Subscription";F.SUBSCRIPTION_FIELD_CONDITION="openfed__SubscriptionFieldCondition";F.SUBSCRIPTION_FILTER="openfed__subscriptionFilter";F.SUBSCRIPTION_FILTER_CONDITION="openfed__SubscriptionFilterCondition";F.SUBSCRIPTION_FILTER_VALUE="openfed__SubscriptionFilterValue";F.SUBSCRIBE="subscribe";F.SUBSCRIPTION_UPPER="SUBSCRIPTION";F.SUCCESS="success";F.TAG="tag";F.TOPIC="topic";F.TOPICS="topics";F.UNION="Union";F.UNION_UPPER="UNION";F.URL_LOWER="url";F.VALUES="values";F.VARIABLE_DEFINITION_UPPER="VARIABLE_DEFINITION";F.CHANNEL="channel";F.CHANNELS="channels";F.EXECUTABLE_DIRECTIVE_LOCATIONS=new Set([F.FIELD_UPPER,F.FRAGMENT_DEFINITION_UPPER,F.FRAGMENT_SPREAD_UPPER,F.INLINE_FRAGMENT_UPPER,F.MUTATION_UPPER,F.QUERY_UPPER,F.SUBSCRIPTION_UPPER]);F.ROOT_TYPE_NAMES=new Set([F.MUTATION,F.QUERY,F.SUBSCRIPTION]);F.AUTHORIZATION_DIRECTIVES=new Set([F.AUTHENTICATED,F.REQUIRES_SCOPES]);F.PERSISTED_CLIENT_DIRECTIVES=new Set([F.DEPRECATED]);F.INHERITABLE_DIRECTIVE_NAMES=new Set([F.EXTERNAL,F.SHAREABLE]);F.IGNORED_FIELDS=new Set([F.ENTITIES_FIELD,F.SERVICE_FIELD]);F.INPUT_NODE_KINDS=new Set([au.Kind.ENUM_TYPE_DEFINITION,au.Kind.INPUT_OBJECT_TYPE_DEFINITION,au.Kind.SCALAR_TYPE_DEFINITION]);F.OUTPUT_NODE_KINDS=new Set([au.Kind.ENUM_TYPE_DEFINITION,au.Kind.INTERFACE_TYPE_DEFINITION,au.Kind.OBJECT_TYPE_DEFINITION,au.Kind.SCALAR_TYPE_DEFINITION,au.Kind.UNION_TYPE_DEFINITION])});var Yr=w($n=>{"use strict";m();T();N();Object.defineProperty($n,"__esModule",{value:!0});$n.operationTypeNodeToDefaultType=void 0;$n.isObjectLikeNodeEntity=XX;$n.isNodeInterfaceObject=ZX;$n.stringToNameNode=FN;$n.stringArrayToNameNodeArray=e9;$n.setToNameNodeArray=t9;$n.stringToNamedTypeNode=aC;$n.setToNamedTypeNodeArray=n9;$n.nodeKindToDirectiveLocation=r9;$n.isKindAbstract=i9;$n.extractExecutableDirectiveLocations=a9;$n.formatDescription=s9;$n.lexicographicallySortArgumentNodes=sC;$n.lexicographicallySortSelectionSetNode=PN;$n.lexicographicallySortDocumentNode=o9;$n.parse=oC;$n.safeParse=u9;var Ut=Ae(),vn=ur();function XX(e){var t;if(!((t=e.directives)!=null&&t.length))return!1;for(let n of e.directives)if(n.name.value===vn.KEY)return!0;return!1}function ZX(e){var t;if(!((t=e.directives)!=null&&t.length))return!1;for(let n of e.directives)if(n.name.value===vn.INTERFACE_OBJECT)return!0;return!1}function FN(e){return{kind:Ut.Kind.NAME,value:e}}function e9(e){let t=[];for(let n of e)t.push(FN(n));return t}function t9(e){let t=[];for(let n of e)t.push(FN(n));return t}function aC(e){return{kind:Ut.Kind.NAMED_TYPE,name:FN(e)}}function n9(e){let t=[];for(let n of e)t.push(aC(n));return t}function r9(e){switch(e){case Ut.Kind.ARGUMENT:return vn.ARGUMENT_DEFINITION_UPPER;case Ut.Kind.ENUM_TYPE_DEFINITION:case Ut.Kind.ENUM_TYPE_EXTENSION:return vn.ENUM_UPPER;case Ut.Kind.ENUM_VALUE_DEFINITION:return vn.ENUM_VALUE_UPPER;case Ut.Kind.FIELD_DEFINITION:return vn.FIELD_DEFINITION_UPPER;case Ut.Kind.FRAGMENT_DEFINITION:return vn.FRAGMENT_DEFINITION_UPPER;case Ut.Kind.FRAGMENT_SPREAD:return vn.FRAGMENT_SPREAD_UPPER;case Ut.Kind.INLINE_FRAGMENT:return vn.INLINE_FRAGMENT_UPPER;case Ut.Kind.INPUT_VALUE_DEFINITION:return vn.INPUT_FIELD_DEFINITION_UPPER;case Ut.Kind.INPUT_OBJECT_TYPE_DEFINITION:case Ut.Kind.INPUT_OBJECT_TYPE_EXTENSION:return vn.INPUT_OBJECT_UPPER;case Ut.Kind.INTERFACE_TYPE_DEFINITION:case Ut.Kind.INTERFACE_TYPE_EXTENSION:return vn.INTERFACE_UPPER;case Ut.Kind.OBJECT_TYPE_DEFINITION:case Ut.Kind.OBJECT_TYPE_EXTENSION:return vn.OBJECT_UPPER;case Ut.Kind.SCALAR_TYPE_DEFINITION:case Ut.Kind.SCALAR_TYPE_EXTENSION:return vn.SCALAR_UPPER;case Ut.Kind.SCHEMA_DEFINITION:case Ut.Kind.SCHEMA_EXTENSION:return vn.SCHEMA_UPPER;case Ut.Kind.UNION_TYPE_DEFINITION:case Ut.Kind.UNION_TYPE_EXTENSION:return vn.UNION_UPPER;default:return e}}$n.operationTypeNodeToDefaultType=new Map([[Ut.OperationTypeNode.MUTATION,vn.MUTATION],[Ut.OperationTypeNode.QUERY,vn.QUERY],[Ut.OperationTypeNode.SUBSCRIPTION,vn.SUBSCRIPTION]]);function i9(e){return e===Ut.Kind.INTERFACE_TYPE_DEFINITION||e===Ut.Kind.UNION_TYPE_DEFINITION}function a9(e,t){for(let n of e){let r=n.value;vn.EXECUTABLE_DIRECTIVE_LOCATIONS.has(r)&&t.add(r)}return t}function s9(e){if(!e)return e;let t=e.value;if(e.block){let n=t.split(` `);n.length>1&&(t=n.map(r=>r.trimStart()).join(` -`))}return Y(x({},e),{value:t,block:!0})}function sC(e){return e.arguments?e.arguments.sort((n,r)=>n.name.value.localeCompare(r.name.value)):e.arguments}function PN(e){let t=e.selections;return Y(x({},e),{selections:t.sort((n,r)=>{var a,o,c,l;return vn.NAME in n?vn.NAME in r?n.name.value.localeCompare(r.name.value):-1:vn.NAME in r?1:((o=(a=n.typeCondition)==null?void 0:a.name.value)!=null?o:"").localeCompare((l=(c=r.typeCondition)==null?void 0:c.name.value)!=null?l:"")}).map(n=>{switch(n.kind){case Ut.Kind.FIELD:return Y(x({},n),{arguments:sC(n),selectionSet:n.selectionSet?PN(n.selectionSet):n.selectionSet});case Ut.Kind.FRAGMENT_SPREAD:return n;case Ut.Kind.INLINE_FRAGMENT:return Y(x({},n),{selectionSet:PN(n.selectionSet)})}})})}function o9(e){return Y(x({},e),{definitions:e.definitions.map(t=>t.kind!==Ut.Kind.OPERATION_DEFINITION?t:Y(x({},t),{selectionSet:PN(t.selectionSet)}))})}function oC(e,t=!0){return(0,Ut.parse)(e,{noLocation:t})}function u9(e,t=!0){try{return{documentNode:oC(e,t)}}catch(n){return{error:n}}}});var lC=w(ml=>{"use strict";m();T();N();Object.defineProperty(ml,"__esModule",{value:!0});ml.AccumulatorMap=void 0;ml.mapValue=fl;ml.extendSchemaImpl=c9;var Ue=Ae(),Ts=class extends Map{get[Symbol.toStringTag](){return"AccumulatorMap"}add(t,n){let r=this.get(t);r===void 0?this.set(t,[n]):r.push(n)}};ml.AccumulatorMap=Ts;function fl(e,t){let n=Object.create(null);for(let r of Object.keys(e))n[r]=t(e[r],r);return n}function c9(e,t,n){var De,_e,Ce,_t;let r=[],i=new Ts,a=new Ts,o=new Ts,c=new Ts,l=new Ts,p=new Ts,f=[],y,g=[],v=!1;for(let J of t.definitions){switch(J.kind){case Ue.Kind.SCHEMA_DEFINITION:y=J;break;case Ue.Kind.SCHEMA_EXTENSION:g.push(J);break;case Ue.Kind.DIRECTIVE_DEFINITION:f.push(J);break;case Ue.Kind.SCALAR_TYPE_DEFINITION:case Ue.Kind.OBJECT_TYPE_DEFINITION:case Ue.Kind.INTERFACE_TYPE_DEFINITION:case Ue.Kind.UNION_TYPE_DEFINITION:case Ue.Kind.ENUM_TYPE_DEFINITION:case Ue.Kind.INPUT_OBJECT_TYPE_DEFINITION:r.push(J);break;case Ue.Kind.SCALAR_TYPE_EXTENSION:i.add(J.name.value,J);break;case Ue.Kind.OBJECT_TYPE_EXTENSION:a.add(J.name.value,J);break;case Ue.Kind.INTERFACE_TYPE_EXTENSION:o.add(J.name.value,J);break;case Ue.Kind.UNION_TYPE_EXTENSION:c.add(J.name.value,J);break;case Ue.Kind.ENUM_TYPE_EXTENSION:l.add(J.name.value,J);break;case Ue.Kind.INPUT_OBJECT_TYPE_EXTENSION:p.add(J.name.value,J);break;default:continue}v=!0}if(!v)return e;let F=new Map;for(let J of e.types){let se=z(J);se&&F.set(J.name,se)}for(let J of r){let se=J.name.value;F.set(se,(De=uC.get(se))!=null?De:oe(J))}for(let[J,se]of a)F.set(J,new Ue.GraphQLObjectType({name:J,interfaces:()=>$t(se),fields:()=>dn(se),extensionASTNodes:se}));if(n!=null&&n.addInvalidExtensionOrphans){for(let[J,se]of o)F.set(J,new Ue.GraphQLInterfaceType({name:J,interfaces:()=>$t(se),fields:()=>dn(se),extensionASTNodes:se}));for(let[J,se]of l)F.set(J,new Ue.GraphQLEnumType({name:J,values:Un(se),extensionASTNodes:se}));for(let[J,se]of c)F.set(J,new Ue.GraphQLUnionType({name:J,types:()=>bn(se),extensionASTNodes:se}));for(let[J,se]of i)F.set(J,new Ue.GraphQLScalarType({name:J,extensionASTNodes:se}));for(let[J,se]of p)F.set(J,new Ue.GraphQLInputObjectType({name:J,fields:()=>Rr(se),extensionASTNodes:se}))}let k=x(x({query:e.query&&$(e.query),mutation:e.mutation&&$(e.mutation),subscription:e.subscription&&$(e.subscription)},y&&zt([y])),zt(g));return Y(x({description:(Ce=(_e=y==null?void 0:y.description)==null?void 0:_e.value)!=null?Ce:e.description},k),{types:Array.from(F.values()),directives:[...e.directives.map(ne),...f.map(Vt)],extensions:e.extensions,astNode:y!=null?y:e.astNode,extensionASTNodes:e.extensionASTNodes.concat(g),assumeValid:(_t=n==null?void 0:n.assumeValid)!=null?_t:!1});function K(J){return(0,Ue.isListType)(J)?new Ue.GraphQLList(K(J.ofType)):(0,Ue.isNonNullType)(J)?new Ue.GraphQLNonNull(K(J.ofType)):$(J)}function $(J){return F.get(J.name)}function ne(J){if((0,Ue.isSpecifiedDirective)(J))return J;let se=J.toConfig();return new Ue.GraphQLDirective(Y(x({},se),{args:fl(se.args,gt)}))}function z(J){if((0,Ue.isIntrospectionType)(J)||(0,Ue.isSpecifiedScalarType)(J))return J;if((0,Ue.isScalarType)(J))return Fe(J);if((0,Ue.isObjectType)(J))return Ve(J);if((0,Ue.isInterfaceType)(J))return et(J);if((0,Ue.isUnionType)(J))return X(J);if((0,Ue.isEnumType)(J))return pe(J);if((0,Ue.isInputObjectType)(J))return Te(J)}function Te(J){var Qe;let se=J.toConfig(),xe=(Qe=p.get(se.name))!=null?Qe:[];return new Ue.GraphQLInputObjectType(Y(x({},se),{fields:()=>x(x({},fl(se.fields,Lt=>Y(x({},Lt),{type:K(Lt.type)}))),Rr(xe)),extensionASTNodes:se.extensionASTNodes.concat(xe)}))}function pe(J){var Qe;let se=J.toConfig(),xe=(Qe=l.get(J.name))!=null?Qe:[];return new Ue.GraphQLEnumType(Y(x({},se),{values:x(x({},se.values),Un(xe)),extensionASTNodes:se.extensionASTNodes.concat(xe)}))}function Fe(J){var Lt,tt;let se=J.toConfig(),xe=(Lt=i.get(se.name))!=null?Lt:[],Qe=se.specifiedByURL;for(let At of xe)Qe=(tt=cC(At))!=null?tt:Qe;return new Ue.GraphQLScalarType(Y(x({},se),{specifiedByURL:Qe,extensionASTNodes:se.extensionASTNodes.concat(xe)}))}function Ve(J){var Qe;let se=J.toConfig(),xe=(Qe=a.get(se.name))!=null?Qe:[];return new Ue.GraphQLObjectType(Y(x({},se),{interfaces:()=>[...J.getInterfaces().map($),...$t(xe)],fields:()=>x(x({},fl(se.fields,ve)),dn(xe)),extensionASTNodes:se.extensionASTNodes.concat(xe)}))}function et(J){var Qe;let se=J.toConfig(),xe=(Qe=o.get(se.name))!=null?Qe:[];return new Ue.GraphQLInterfaceType(Y(x({},se),{interfaces:()=>[...J.getInterfaces().map($),...$t(xe)],fields:()=>x(x({},fl(se.fields,ve)),dn(xe)),extensionASTNodes:se.extensionASTNodes.concat(xe)}))}function X(J){var Qe;let se=J.toConfig(),xe=(Qe=c.get(se.name))!=null?Qe:[];return new Ue.GraphQLUnionType(Y(x({},se),{types:()=>[...J.getTypes().map($),...bn(xe)],extensionASTNodes:se.extensionASTNodes.concat(xe)}))}function ve(J){return Y(x({},J),{type:K(J.type),args:J.args&&fl(J.args,gt)})}function gt(J){return Y(x({},J),{type:K(J.type)})}function zt(J){var xe;let se={};for(let Qe of J){let Lt=(xe=Qe.operationTypes)!=null?xe:[];for(let tt of Lt)se[tt.operation]=Wt(tt.type)}return se}function Wt(J){var Qe;let se=J.name.value,xe=(Qe=uC.get(se))!=null?Qe:F.get(se);if(xe===void 0)throw new Error(`Unknown type: "${se}".`);return xe}function Dn(J){return J.kind===Ue.Kind.LIST_TYPE?new Ue.GraphQLList(Dn(J.type)):J.kind===Ue.Kind.NON_NULL_TYPE?new Ue.GraphQLNonNull(Dn(J.type)):Wt(J)}function Vt(J){var se;return new Ue.GraphQLDirective({name:J.name.value,description:(se=J.description)==null?void 0:se.value,locations:J.locations.map(({value:xe})=>xe),isRepeatable:J.repeatable,args:Ar(J.arguments),astNode:J})}function dn(J){var xe,Qe;let se=Object.create(null);for(let Lt of J){let tt=(xe=Lt.fields)!=null?xe:[];for(let At of tt)se[At.name.value]={type:Dn(At.type),description:(Qe=At.description)==null?void 0:Qe.value,args:Ar(At.arguments),deprecationReason:wN(At),astNode:At}}return se}function Ar(J){var Qe;let se=J!=null?J:[],xe=Object.create(null);for(let Lt of se){let tt=Dn(Lt.type);xe[Lt.name.value]={type:tt,description:(Qe=Lt.description)==null?void 0:Qe.value,defaultValue:(0,Ue.valueFromAST)(Lt.defaultValue,tt),deprecationReason:wN(Lt),astNode:Lt}}return xe}function Rr(J){var xe,Qe;let se=Object.create(null);for(let Lt of J){let tt=(xe=Lt.fields)!=null?xe:[];for(let At of tt){let Ha=Dn(At.type);se[At.name.value]={type:Ha,description:(Qe=At.description)==null?void 0:Qe.value,defaultValue:(0,Ue.valueFromAST)(At.defaultValue,Ha),deprecationReason:wN(At),astNode:At}}}return se}function Un(J){var xe,Qe;let se=Object.create(null);for(let Lt of J){let tt=(xe=Lt.values)!=null?xe:[];for(let At of tt)se[At.name.value]={description:(Qe=At.description)==null?void 0:Qe.value,deprecationReason:wN(At),astNode:At}}return se}function $t(J){return J.flatMap(se=>{var xe,Qe;return(Qe=(xe=se.interfaces)==null?void 0:xe.map(Wt))!=null?Qe:[]})}function bn(J){return J.flatMap(se=>{var xe,Qe;return(Qe=(xe=se.types)==null?void 0:xe.map(Wt))!=null?Qe:[]})}function oe(J){var xe,Qe,Lt,tt,At,Ha,xr,za,Lc,ha,pr,ni;let se=J.name.value;switch(J.kind){case Ue.Kind.OBJECT_TYPE_DEFINITION:{let xt=(xe=a.get(se))!=null?xe:[],fr=[J,...xt];return a.delete(se),new Ue.GraphQLObjectType({name:se,description:(Qe=J.description)==null?void 0:Qe.value,interfaces:()=>$t(fr),fields:()=>dn(fr),astNode:J,extensionASTNodes:xt})}case Ue.Kind.INTERFACE_TYPE_DEFINITION:{let xt=(Lt=o.get(se))!=null?Lt:[],fr=[J,...xt];return o.delete(se),new Ue.GraphQLInterfaceType({name:se,description:(tt=J.description)==null?void 0:tt.value,interfaces:()=>$t(fr),fields:()=>dn(fr),astNode:J,extensionASTNodes:xt})}case Ue.Kind.ENUM_TYPE_DEFINITION:{let xt=(At=l.get(se))!=null?At:[],fr=[J,...xt];return l.delete(se),new Ue.GraphQLEnumType({name:se,description:(Ha=J.description)==null?void 0:Ha.value,values:Un(fr),astNode:J,extensionASTNodes:xt})}case Ue.Kind.UNION_TYPE_DEFINITION:{let xt=(xr=c.get(se))!=null?xr:[],fr=[J,...xt];return c.delete(se),new Ue.GraphQLUnionType({name:se,description:(za=J.description)==null?void 0:za.value,types:()=>bn(fr),astNode:J,extensionASTNodes:xt})}case Ue.Kind.SCALAR_TYPE_DEFINITION:{let xt=(Lc=i.get(se))!=null?Lc:[];return i.delete(se),new Ue.GraphQLScalarType({name:se,description:(ha=J.description)==null?void 0:ha.value,specifiedByURL:cC(J),astNode:J,extensionASTNodes:xt})}case Ue.Kind.INPUT_OBJECT_TYPE_DEFINITION:{let xt=(pr=p.get(se))!=null?pr:[],fr=[J,...xt];return p.delete(se),new Ue.GraphQLInputObjectType({name:se,description:(ni=J.description)==null?void 0:ni.value,fields:()=>Rr(fr),astNode:J,extensionASTNodes:xt})}}}}var uC=new Map([...Ue.specifiedScalarTypes,...Ue.introspectionTypes].map(e=>[e.name,e]));function wN(e){let t=(0,Ue.getDirectiveValues)(Ue.GraphQLDeprecatedDirective,e);return t==null?void 0:t.reason}function cC(e){let t=(0,Ue.getDirectiveValues)(Ue.GraphQLSpecifiedByDirective,e);return t==null?void 0:t.url}});var dv=w(lv=>{"use strict";m();T();N();Object.defineProperty(lv,"__esModule",{value:!0});lv.buildASTSchema=p9;var dC=Ae(),l9=ll(),d9=lC();function p9(e,t){(t==null?void 0:t.assumeValid)!==!0&&(t==null?void 0:t.assumeValidSDL)!==!0&&(0,l9.assertValidSDL)(e);let n={description:void 0,types:[],directives:[],extensions:Object.create(null),extensionASTNodes:[],assumeValid:!1},r=(0,d9.extendSchemaImpl)(n,e,t);if(r.astNode==null)for(let a of r.types)switch(a.name){case"Query":r.query=a;break;case"Mutation":r.mutation=a;break;case"Subscription":r.subscription=a;break}let i=[...r.directives,...dC.specifiedDirectives.filter(a=>r.directives.every(o=>o.name!==a.name))];return new dC.GraphQLSchema(Y(x({},r),{directives:i}))}});var Nl=w(su=>{"use strict";m();T();N();Object.defineProperty(su,"__esModule",{value:!0});su.MAX_INT32=su.MAX_SUBSCRIPTION_FILTER_DEPTH=su.MAXIMUM_TYPE_NESTING=void 0;su.MAXIMUM_TYPE_NESTING=30;su.MAX_SUBSCRIPTION_FILTER_DEPTH=5;su.MAX_INT32=nn(2,31)-1});var Jr=w(Nr=>{"use strict";m();T();N();Object.defineProperty(Nr,"__esModule",{value:!0});Nr.getOrThrowError=m9;Nr.getEntriesNotInHashSet=N9;Nr.numberToOrdinal=T9;Nr.addIterableValuesToSet=E9;Nr.addSets=h9;Nr.kindToNodeType=y9;Nr.getValueOrDefault=I9;Nr.add=g9;Nr.generateSimpleDirective=_9;Nr.generateRequiresScopesDirective=v9;Nr.copyObjectValueMap=S9;Nr.addNewObjectValueMapEntries=O9;Nr.copyArrayValueMap=D9;Nr.addMapEntries=b9;Nr.getSingleSetEntry=A9;var an=Ae(),_r=ur(),f9=ia(),pv=Yr();function m9(e,t,n){let r=e.get(t);if(r===void 0)throw(0,f9.invalidKeyFatalError)(t,n);return r}function N9(e,t){let n=[];for(let r of e)t.has(r)||n.push(r);return n}function T9(e){let t=e.toString();switch(t[t.length-1]){case"1":return`${t}st`;case"2":return`${t}nd`;case"3":return`${t}rd`;default:return`${t}th`}}function E9(e,t){for(let n of e)t.add(n)}function h9(e,t){let n=new Set(e);for(let r of t)n.add(r);return n}function y9(e){switch(e){case an.Kind.BOOLEAN:return _r.BOOLEAN_SCALAR;case an.Kind.ENUM:case an.Kind.ENUM_TYPE_DEFINITION:return _r.ENUM;case an.Kind.ENUM_TYPE_EXTENSION:return"Enum extension";case an.Kind.ENUM_VALUE_DEFINITION:return _r.ENUM_VALUE;case an.Kind.FIELD_DEFINITION:return _r.FIELD;case an.Kind.FLOAT:return _r.FLOAT_SCALAR;case an.Kind.INPUT_OBJECT_TYPE_DEFINITION:return _r.INPUT_OBJECT;case an.Kind.INPUT_OBJECT_TYPE_EXTENSION:return"Input Object extension";case an.Kind.INPUT_VALUE_DEFINITION:return _r.INPUT_VALUE;case an.Kind.INT:return _r.INT_SCALAR;case an.Kind.INTERFACE_TYPE_DEFINITION:return _r.INTERFACE;case an.Kind.INTERFACE_TYPE_EXTENSION:return"Interface extension";case an.Kind.NULL:return _r.NULL;case an.Kind.OBJECT:case an.Kind.OBJECT_TYPE_DEFINITION:return _r.OBJECT;case an.Kind.OBJECT_TYPE_EXTENSION:return"Object extension";case an.Kind.STRING:return _r.STRING_SCALAR;case an.Kind.SCALAR_TYPE_DEFINITION:return _r.SCALAR;case an.Kind.SCALAR_TYPE_EXTENSION:return"Scalar extension";case an.Kind.UNION_TYPE_DEFINITION:return _r.UNION;case an.Kind.UNION_TYPE_EXTENSION:return"Union extension";default:return e}}function I9(e,t,n){let r=e.get(t);if(r)return r;let i=n();return e.set(t,i),i}function g9(e,t){return e.has(t)?!1:(e.add(t),!0)}function _9(e){return{kind:an.Kind.DIRECTIVE,name:(0,pv.stringToNameNode)(e)}}function v9(e){let t=[];for(let n of e){let r=[];for(let i of n)r.push({kind:an.Kind.STRING,value:i});t.push({kind:an.Kind.LIST,values:r})}return{kind:an.Kind.DIRECTIVE,name:(0,pv.stringToNameNode)(_r.REQUIRES_SCOPES),arguments:[{kind:an.Kind.ARGUMENT,name:(0,pv.stringToNameNode)(_r.SCOPES),value:{kind:an.Kind.LIST,values:t}}]}}function S9(e){let t=new Map;for(let[n,r]of e)t.set(n,x({},r));return t}function O9(e,t){for(let[n,r]of e)t.set(n,x({},r))}function D9(e){let t=new Map;for(let[n,r]of e)t.set(n,[...r]);return t}function b9(e,t){for(let[n,r]of e)t.set(n,r)}function A9(e){let{value:t,done:n}=e.values().next();if(!n)return t}});var hp=w(LN=>{"use strict";m();T();N();Object.defineProperty(LN,"__esModule",{value:!0});LN.ExtensionType=void 0;var pC;(function(e){e[e.EXTENDS=0]="EXTENDS",e[e.NONE=1]="NONE",e[e.REAL=2]="REAL"})(pC||(LN.ExtensionType=pC={}))});var ou=w(Sr=>{"use strict";m();T();N();Object.defineProperty(Sr,"__esModule",{value:!0});Sr.getMutableDirectiveDefinitionNode=P9;Sr.getMutableEnumNode=F9;Sr.getMutableEnumValueNode=w9;Sr.getMutableFieldNode=L9;Sr.getMutableInputObjectNode=C9;Sr.getMutableInputValueNode=B9;Sr.getMutableInterfaceNode=U9;Sr.getMutableObjectNode=k9;Sr.getMutableObjectExtensionNode=M9;Sr.getMutableScalarNode=x9;Sr.getMutableTypeNode=fv;Sr.getMutableUnionNode=q9;Sr.getTypeNodeNamedTypeName=mv;Sr.getNamedTypeNode=mC;var vr=Ae(),Tl=Yr(),fC=ia(),R9=Nl();function P9(e){return{arguments:[],kind:e.kind,locations:[],name:x({},e.name),repeatable:e.repeatable,description:(0,Tl.formatDescription)(e.description)}}function F9(e){return{kind:vr.Kind.ENUM_TYPE_DEFINITION,name:x({},e)}}function w9(e){return{directives:[],kind:e.kind,name:x({},e.name),description:(0,Tl.formatDescription)(e.description)}}function L9(e,t,n){return{arguments:[],directives:[],kind:e.kind,name:x({},e.name),type:fv(e.type,t,n),description:(0,Tl.formatDescription)(e.description)}}function C9(e){return{kind:vr.Kind.INPUT_OBJECT_TYPE_DEFINITION,name:x({},e)}}function B9(e,t,n){return{directives:[],kind:e.kind,name:x({},e.name),type:fv(e.type,t,n),defaultValue:e.defaultValue,description:(0,Tl.formatDescription)(e.description)}}function U9(e){return{kind:vr.Kind.INTERFACE_TYPE_DEFINITION,name:x({},e)}}function k9(e){return{kind:vr.Kind.OBJECT_TYPE_DEFINITION,name:x({},e)}}function M9(e){let t=e.kind===vr.Kind.OBJECT_TYPE_DEFINITION?e.description:void 0;return{kind:vr.Kind.OBJECT_TYPE_EXTENSION,name:x({},e.name),description:(0,Tl.formatDescription)(t)}}function x9(e){return{kind:vr.Kind.SCALAR_TYPE_DEFINITION,name:x({},e)}}function fv(e,t,n){let r={kind:e.kind},i=r;for(let a=0;a{"use strict";m();T();N();Object.defineProperty(CN,"__esModule",{value:!0});CN.DEFAULT_CONSUMER_INACTIVE_THRESHOLD=void 0;CN.DEFAULT_CONSUMER_INACTIVE_THRESHOLD=30});var Es=w(ee=>{"use strict";m();T();N();Object.defineProperty(ee,"__esModule",{value:!0});ee.MAX_OR_SCOPES=ee.EDFS_ARGS_REGEXP=ee.CONFIGURE_CHILD_DESCRIPTIONS_DEFINITION=ee.CONFIGURE_DESCRIPTION_DEFINITION=ee.EDFS_NATS_STREAM_CONFIGURATION_DEFINITION=ee.SCOPE_SCALAR_DEFINITION=ee.FIELD_SET_SCALAR_DEFINITION=ee.VERSION_TWO_DIRECTIVE_DEFINITIONS=ee.EVENT_DRIVEN_DIRECTIVE_DEFINITIONS_BY_DIRECTIVE_NAME=ee.BASE_DIRECTIVE_DEFINITIONS=ee.V2_DIRECTIVE_DEFINITION_BY_DIRECTIVE_NAME=ee.SUBSCRIPTION_FIELD_CONDITION_DEFINITION=ee.SUBSCRIPTION_FILTER_VALUE_DEFINITION=ee.SUBSCRIPTION_FILTER_CONDITION_DEFINITION=ee.SUBSCRIPTION_FILTER_DEFINITION=ee.SHAREABLE_DEFINITION=ee.REQUIRES_SCOPES_DEFINITION=ee.OVERRIDE_DEFINITION=ee.LINK_DEFINITION=ee.LINK_PURPOSE_DEFINITION=ee.LINK_IMPORT_DEFINITION=ee.INTERFACE_OBJECT_DEFINITION=ee.INACCESSIBLE_DEFINITION=ee.COMPOSE_DIRECTIVE_DEFINITION=ee.AUTHENTICATED_DEFINITION=ee.ALL_IN_BUILT_DIRECTIVE_NAMES=ee.BASE_DIRECTIVE_DEFINITION_BY_DIRECTIVE_NAME=ee.EDFS_REDIS_SUBSCRIBE_DEFINITION=ee.EDFS_REDIS_PUBLISH_DEFINITION=ee.TAG_DEFINITION=ee.SPECIFIED_BY_DEFINITION=ee.REQUIRES_DEFINITION=ee.PROVIDES_DEFINITION=ee.KEY_DEFINITION=ee.REQUIRED_FIELDSET_TYPE_NODE=ee.EDFS_NATS_SUBSCRIBE_DEFINITION=ee.EDFS_NATS_REQUEST_DEFINITION=ee.EDFS_NATS_PUBLISH_DEFINITION=ee.EDFS_KAFKA_SUBSCRIBE_DEFINITION=ee.EDFS_KAFKA_PUBLISH_DEFINITION=ee.EXTERNAL_DEFINITION=ee.EXTENDS_DEFINITION=ee.DEPRECATED_DEFINITION=ee.BASE_SCALARS=ee.REQUIRED_STRING_TYPE_NODE=void 0;var ue=Ae(),ae=Yr(),V9=Nv(),U=ur();ee.REQUIRED_STRING_TYPE_NODE={kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(U.STRING_SCALAR)};ee.BASE_SCALARS=new Set(["_Any","_Entities",U.BOOLEAN_SCALAR,U.FLOAT_SCALAR,U.ID_SCALAR,U.INT_SCALAR,U.FIELD_SET_SCALAR,U.SCOPE_SCALAR,U.STRING_SCALAR]);ee.DEPRECATED_DEFINITION={arguments:[{directives:[],kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.REASON),type:(0,ae.stringToNamedTypeNode)(U.STRING_SCALAR),defaultValue:{kind:ue.Kind.STRING,value:ue.DEFAULT_DEPRECATION_REASON}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([U.ARGUMENT_DEFINITION_UPPER,U.ENUM_VALUE_UPPER,U.FIELD_DEFINITION_UPPER,U.INPUT_FIELD_DEFINITION_UPPER]),name:(0,ae.stringToNameNode)(U.DEPRECATED),repeatable:!1};ee.EXTENDS_DEFINITION={kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([U.INTERFACE_UPPER,U.OBJECT_UPPER]),name:(0,ae.stringToNameNode)(U.EXTENDS),repeatable:!1};ee.EXTERNAL_DEFINITION={kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([U.FIELD_DEFINITION_UPPER,U.OBJECT_UPPER]),name:(0,ae.stringToNameNode)(U.EXTERNAL),repeatable:!1};ee.EDFS_KAFKA_PUBLISH_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.TOPIC),type:ee.REQUIRED_STRING_TYPE_NODE},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.PROVIDER_ID),type:ee.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ue.Kind.STRING,value:U.DEFAULT_EDFS_PROVIDER_ID}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:[(0,ae.stringToNameNode)(U.FIELD_DEFINITION_UPPER)],name:(0,ae.stringToNameNode)(U.EDFS_KAFKA_PUBLISH),repeatable:!1};ee.EDFS_KAFKA_SUBSCRIBE_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.TOPICS),type:{kind:ue.Kind.NON_NULL_TYPE,type:{kind:ue.Kind.LIST_TYPE,type:ee.REQUIRED_STRING_TYPE_NODE}}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.PROVIDER_ID),type:ee.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ue.Kind.STRING,value:U.DEFAULT_EDFS_PROVIDER_ID}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:[(0,ae.stringToNameNode)(U.FIELD_DEFINITION_UPPER)],name:(0,ae.stringToNameNode)(U.EDFS_KAFKA_SUBSCRIBE),repeatable:!1};ee.EDFS_NATS_PUBLISH_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.SUBJECT),type:ee.REQUIRED_STRING_TYPE_NODE},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.PROVIDER_ID),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(U.STRING_SCALAR)},defaultValue:{kind:ue.Kind.STRING,value:U.DEFAULT_EDFS_PROVIDER_ID}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:[(0,ae.stringToNameNode)(U.FIELD_DEFINITION_UPPER)],name:(0,ae.stringToNameNode)(U.EDFS_NATS_PUBLISH),repeatable:!1};ee.EDFS_NATS_REQUEST_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.SUBJECT),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(U.STRING_SCALAR)}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.PROVIDER_ID),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(U.STRING_SCALAR)},defaultValue:{kind:ue.Kind.STRING,value:U.DEFAULT_EDFS_PROVIDER_ID}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:[(0,ae.stringToNameNode)(U.FIELD_DEFINITION_UPPER)],name:(0,ae.stringToNameNode)(U.EDFS_NATS_REQUEST),repeatable:!1};ee.EDFS_NATS_SUBSCRIBE_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.SUBJECTS),type:{kind:ue.Kind.NON_NULL_TYPE,type:{kind:ue.Kind.LIST_TYPE,type:ee.REQUIRED_STRING_TYPE_NODE}}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.PROVIDER_ID),type:ee.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ue.Kind.STRING,value:U.DEFAULT_EDFS_PROVIDER_ID}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.STREAM_CONFIGURATION),type:(0,ae.stringToNamedTypeNode)(U.EDFS_NATS_STREAM_CONFIGURATION)}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:[(0,ae.stringToNameNode)(U.FIELD_DEFINITION_UPPER)],name:(0,ae.stringToNameNode)(U.EDFS_NATS_SUBSCRIBE),repeatable:!1};ee.REQUIRED_FIELDSET_TYPE_NODE={kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(U.FIELD_SET_SCALAR)};ee.KEY_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.FIELDS),type:ee.REQUIRED_FIELDSET_TYPE_NODE},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.RESOLVABLE),type:(0,ae.stringToNamedTypeNode)(U.BOOLEAN_SCALAR),defaultValue:{kind:ue.Kind.BOOLEAN,value:!0}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([U.INTERFACE_UPPER,U.OBJECT_UPPER]),name:(0,ae.stringToNameNode)(U.KEY),repeatable:!0};ee.PROVIDES_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.FIELDS),type:ee.REQUIRED_FIELDSET_TYPE_NODE}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:[(0,ae.stringToNameNode)(U.FIELD_DEFINITION_UPPER)],name:(0,ae.stringToNameNode)(U.PROVIDES),repeatable:!1};ee.REQUIRES_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.FIELDS),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(U.FIELD_SET_SCALAR)}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:[(0,ae.stringToNameNode)(U.FIELD_DEFINITION_UPPER)],name:(0,ae.stringToNameNode)(U.REQUIRES),repeatable:!1};ee.SPECIFIED_BY_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.URL_LOWER),type:ee.REQUIRED_STRING_TYPE_NODE}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([U.SCALAR_UPPER]),name:(0,ae.stringToNameNode)(U.SPECIFIED_BY),repeatable:!1};ee.TAG_DEFINITION={arguments:[{directives:[],kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.NAME),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(U.STRING_SCALAR)}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([U.ARGUMENT_DEFINITION_UPPER,U.ENUM_UPPER,U.ENUM_VALUE_UPPER,U.FIELD_DEFINITION_UPPER,U.INPUT_FIELD_DEFINITION_UPPER,U.INPUT_OBJECT_UPPER,U.INTERFACE_UPPER,U.OBJECT_UPPER,U.SCALAR_UPPER,U.UNION_UPPER]),name:(0,ae.stringToNameNode)(U.TAG),repeatable:!0};ee.EDFS_REDIS_PUBLISH_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.CHANNEL),type:ee.REQUIRED_STRING_TYPE_NODE},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.PROVIDER_ID),type:ee.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ue.Kind.STRING,value:U.DEFAULT_EDFS_PROVIDER_ID}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:[(0,ae.stringToNameNode)(U.FIELD_DEFINITION_UPPER)],name:(0,ae.stringToNameNode)(U.EDFS_REDIS_PUBLISH),repeatable:!1};ee.EDFS_REDIS_SUBSCRIBE_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.CHANNELS),type:{kind:ue.Kind.NON_NULL_TYPE,type:{kind:ue.Kind.LIST_TYPE,type:ee.REQUIRED_STRING_TYPE_NODE}}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.PROVIDER_ID),type:ee.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ue.Kind.STRING,value:U.DEFAULT_EDFS_PROVIDER_ID}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:[(0,ae.stringToNameNode)(U.FIELD_DEFINITION_UPPER)],name:(0,ae.stringToNameNode)(U.EDFS_REDIS_SUBSCRIBE),repeatable:!1};ee.BASE_DIRECTIVE_DEFINITION_BY_DIRECTIVE_NAME=new Map([[U.DEPRECATED,ee.DEPRECATED_DEFINITION],[U.EXTENDS,ee.EXTENDS_DEFINITION],[U.EXTERNAL,ee.EXTERNAL_DEFINITION],[U.EDFS_KAFKA_PUBLISH,ee.EDFS_KAFKA_PUBLISH_DEFINITION],[U.EDFS_KAFKA_SUBSCRIBE,ee.EDFS_KAFKA_SUBSCRIBE_DEFINITION],[U.EDFS_NATS_PUBLISH,ee.EDFS_NATS_PUBLISH_DEFINITION],[U.EDFS_NATS_REQUEST,ee.EDFS_NATS_REQUEST_DEFINITION],[U.EDFS_NATS_SUBSCRIBE,ee.EDFS_NATS_SUBSCRIBE_DEFINITION],[U.EDFS_REDIS_PUBLISH,ee.EDFS_REDIS_PUBLISH_DEFINITION],[U.EDFS_REDIS_SUBSCRIBE,ee.EDFS_REDIS_SUBSCRIBE_DEFINITION],[U.KEY,ee.KEY_DEFINITION],[U.PROVIDES,ee.PROVIDES_DEFINITION],[U.REQUIRES,ee.REQUIRES_DEFINITION],[U.SPECIFIED_BY,ee.SPECIFIED_BY_DEFINITION],[U.TAG,ee.TAG_DEFINITION]]);ee.ALL_IN_BUILT_DIRECTIVE_NAMES=new Set([U.AUTHENTICATED,U.COMPOSE_DIRECTIVE,U.CONFIGURE_DESCRIPTION,U.CONFIGURE_CHILD_DESCRIPTIONS,U.DEPRECATED,U.EDFS_NATS_PUBLISH,U.EDFS_NATS_REQUEST,U.EDFS_NATS_SUBSCRIBE,U.EDFS_KAFKA_PUBLISH,U.EDFS_KAFKA_SUBSCRIBE,U.EDFS_REDIS_PUBLISH,U.EDFS_REDIS_SUBSCRIBE,U.EXTENDS,U.EXTERNAL,U.INACCESSIBLE,U.INTERFACE_OBJECT,U.KEY,U.LINK,U.OVERRIDE,U.PROVIDES,U.REQUIRES,U.REQUIRES_SCOPES,U.SHAREABLE,U.SPECIFIED_BY,U.SUBSCRIPTION_FILTER,U.TAG]);ee.AUTHENTICATED_DEFINITION={arguments:[],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([U.ENUM_UPPER,U.FIELD_DEFINITION_UPPER,U.INTERFACE_UPPER,U.OBJECT_UPPER,U.SCALAR_UPPER]),name:(0,ae.stringToNameNode)(U.AUTHENTICATED),repeatable:!1};ee.COMPOSE_DIRECTIVE_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.NAME),type:ee.REQUIRED_STRING_TYPE_NODE}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([U.SCHEMA_UPPER]),name:(0,ae.stringToNameNode)(U.COMPOSE_DIRECTIVE),repeatable:!0};ee.INACCESSIBLE_DEFINITION={arguments:[],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([U.ARGUMENT_DEFINITION_UPPER,U.ENUM_UPPER,U.ENUM_VALUE_UPPER,U.FIELD_DEFINITION_UPPER,U.INPUT_FIELD_DEFINITION_UPPER,U.INPUT_OBJECT_UPPER,U.INTERFACE_UPPER,U.OBJECT_UPPER,U.SCALAR_UPPER,U.UNION_UPPER]),name:(0,ae.stringToNameNode)(U.INACCESSIBLE),repeatable:!1};ee.INTERFACE_OBJECT_DEFINITION={kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([U.OBJECT_UPPER]),name:(0,ae.stringToNameNode)(U.INTERFACE_OBJECT),repeatable:!1};ee.LINK_IMPORT_DEFINITION={kind:ue.Kind.SCALAR_TYPE_DEFINITION,name:(0,ae.stringToNameNode)(U.LINK_IMPORT)};ee.LINK_PURPOSE_DEFINITION={kind:ue.Kind.ENUM_TYPE_DEFINITION,name:(0,ae.stringToNameNode)(U.LINK_PURPOSE),values:[{directives:[],kind:ue.Kind.ENUM_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.EXECUTION)},{directives:[],kind:ue.Kind.ENUM_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.SECURITY)}]};ee.LINK_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.URL_LOWER),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(U.STRING_SCALAR)}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.AS),type:(0,ae.stringToNamedTypeNode)(U.STRING_SCALAR)},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.FOR),type:(0,ae.stringToNamedTypeNode)(U.LINK_PURPOSE)},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.IMPORT),type:{kind:ue.Kind.LIST_TYPE,type:(0,ae.stringToNamedTypeNode)(U.LINK_IMPORT)}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([U.SCHEMA_UPPER]),name:(0,ae.stringToNameNode)(U.LINK),repeatable:!0};ee.OVERRIDE_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.FROM),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(U.STRING_SCALAR)}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([U.FIELD_DEFINITION_UPPER]),name:(0,ae.stringToNameNode)(U.OVERRIDE),repeatable:!1};ee.REQUIRES_SCOPES_DEFINITION={arguments:[{directives:[],kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.SCOPES),type:{kind:ue.Kind.NON_NULL_TYPE,type:{kind:ue.Kind.LIST_TYPE,type:{kind:ue.Kind.NON_NULL_TYPE,type:{kind:ue.Kind.LIST_TYPE,type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(U.SCOPE_SCALAR)}}}}}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([U.ENUM_UPPER,U.FIELD_DEFINITION_UPPER,U.INTERFACE_UPPER,U.OBJECT_UPPER,U.SCALAR_UPPER]),name:(0,ae.stringToNameNode)(U.REQUIRES_SCOPES),repeatable:!1};ee.SHAREABLE_DEFINITION={kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([U.FIELD_DEFINITION_UPPER,U.OBJECT_UPPER]),name:(0,ae.stringToNameNode)(U.SHAREABLE),repeatable:!0};ee.SUBSCRIPTION_FILTER_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.CONDITION),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(U.SUBSCRIPTION_FILTER_CONDITION)}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([U.FIELD_DEFINITION_UPPER]),name:(0,ae.stringToNameNode)(U.SUBSCRIPTION_FILTER),repeatable:!1};ee.SUBSCRIPTION_FILTER_CONDITION_DEFINITION={fields:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.AND_UPPER),type:{kind:ue.Kind.LIST_TYPE,type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(U.SUBSCRIPTION_FILTER_CONDITION)}}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.IN_UPPER),type:(0,ae.stringToNamedTypeNode)(U.SUBSCRIPTION_FIELD_CONDITION)},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.OR_UPPER),type:{kind:ue.Kind.LIST_TYPE,type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(U.SUBSCRIPTION_FILTER_CONDITION)}}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.NOT_UPPER),type:(0,ae.stringToNamedTypeNode)(U.SUBSCRIPTION_FILTER_CONDITION)}],kind:ue.Kind.INPUT_OBJECT_TYPE_DEFINITION,name:(0,ae.stringToNameNode)(U.SUBSCRIPTION_FILTER_CONDITION)};ee.SUBSCRIPTION_FILTER_VALUE_DEFINITION={kind:ue.Kind.SCALAR_TYPE_DEFINITION,name:(0,ae.stringToNameNode)(U.SUBSCRIPTION_FILTER_VALUE)};ee.SUBSCRIPTION_FIELD_CONDITION_DEFINITION={fields:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.FIELD_PATH),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(U.STRING_SCALAR)}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.VALUES),type:{kind:ue.Kind.NON_NULL_TYPE,type:{kind:ue.Kind.LIST_TYPE,type:(0,ae.stringToNamedTypeNode)(U.SUBSCRIPTION_FILTER_VALUE)}}}],kind:ue.Kind.INPUT_OBJECT_TYPE_DEFINITION,name:(0,ae.stringToNameNode)(U.SUBSCRIPTION_FIELD_CONDITION)};ee.V2_DIRECTIVE_DEFINITION_BY_DIRECTIVE_NAME=new Map([[U.AUTHENTICATED,ee.AUTHENTICATED_DEFINITION],[U.COMPOSE_DIRECTIVE,ee.COMPOSE_DIRECTIVE_DEFINITION],[U.INACCESSIBLE,ee.INACCESSIBLE_DEFINITION],[U.INTERFACE_OBJECT,ee.INTERFACE_OBJECT_DEFINITION],[U.LINK,ee.LINK_DEFINITION],[U.OVERRIDE,ee.OVERRIDE_DEFINITION],[U.REQUIRES_SCOPES,ee.REQUIRES_SCOPES_DEFINITION],[U.SHAREABLE,ee.SHAREABLE_DEFINITION]]);ee.BASE_DIRECTIVE_DEFINITIONS=[ee.DEPRECATED_DEFINITION,ee.EXTENDS_DEFINITION,ee.EXTERNAL_DEFINITION,ee.KEY_DEFINITION,ee.PROVIDES_DEFINITION,ee.REQUIRES_DEFINITION,ee.SPECIFIED_BY_DEFINITION,ee.TAG_DEFINITION];ee.EVENT_DRIVEN_DIRECTIVE_DEFINITIONS_BY_DIRECTIVE_NAME=new Map([[U.EDFS_KAFKA_PUBLISH,ee.EDFS_KAFKA_PUBLISH_DEFINITION],[U.EDFS_KAFKA_SUBSCRIBE,ee.EDFS_KAFKA_SUBSCRIBE_DEFINITION],[U.EDFS_NATS_PUBLISH,ee.EDFS_NATS_PUBLISH_DEFINITION],[U.EDFS_NATS_REQUEST,ee.EDFS_NATS_REQUEST_DEFINITION],[U.EDFS_NATS_SUBSCRIBE,ee.EDFS_NATS_SUBSCRIBE_DEFINITION],[U.EDFS_REDIS_PUBLISH,ee.EDFS_REDIS_PUBLISH_DEFINITION],[U.EDFS_REDIS_SUBSCRIBE,ee.EDFS_REDIS_SUBSCRIBE_DEFINITION]]);ee.VERSION_TWO_DIRECTIVE_DEFINITIONS=[ee.AUTHENTICATED_DEFINITION,ee.COMPOSE_DIRECTIVE_DEFINITION,ee.INACCESSIBLE_DEFINITION,ee.INTERFACE_OBJECT_DEFINITION,ee.OVERRIDE_DEFINITION,ee.REQUIRES_SCOPES_DEFINITION,ee.SHAREABLE_DEFINITION];ee.FIELD_SET_SCALAR_DEFINITION={kind:ue.Kind.SCALAR_TYPE_DEFINITION,name:(0,ae.stringToNameNode)(U.FIELD_SET_SCALAR)};ee.SCOPE_SCALAR_DEFINITION={kind:ue.Kind.SCALAR_TYPE_DEFINITION,name:(0,ae.stringToNameNode)(U.SCOPE_SCALAR)};ee.EDFS_NATS_STREAM_CONFIGURATION_DEFINITION={kind:ue.Kind.INPUT_OBJECT_TYPE_DEFINITION,name:(0,ae.stringToNameNode)(U.EDFS_NATS_STREAM_CONFIGURATION),fields:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.CONSUMER_NAME),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(U.STRING_SCALAR)}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.STREAM_NAME),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(U.STRING_SCALAR)}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.CONSUMER_INACTIVE_THRESHOLD),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(U.INT_SCALAR)},defaultValue:{kind:ue.Kind.INT,value:V9.DEFAULT_CONSUMER_INACTIVE_THRESHOLD.toString()}}]};ee.CONFIGURE_DESCRIPTION_DEFINITION={arguments:[{directives:[],kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.PROPAGATE),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(U.BOOLEAN_SCALAR)},defaultValue:{kind:ue.Kind.BOOLEAN,value:!0}},{directives:[],kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.DESCRIPTION_OVERRIDE),type:(0,ae.stringToNamedTypeNode)(U.STRING_SCALAR)}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([U.ARGUMENT_DEFINITION_UPPER,U.ENUM_UPPER,U.ENUM_VALUE_UPPER,U.FIELD_DEFINITION_UPPER,U.INTERFACE_UPPER,U.INPUT_OBJECT_UPPER,U.INPUT_FIELD_DEFINITION_UPPER,U.OBJECT_UPPER,U.SCALAR_UPPER,U.SCHEMA_UPPER,U.UNION_UPPER]),name:(0,ae.stringToNameNode)(U.CONFIGURE_DESCRIPTION),repeatable:!1};ee.CONFIGURE_CHILD_DESCRIPTIONS_DEFINITION={arguments:[{directives:[],kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(U.PROPAGATE),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(U.BOOLEAN_SCALAR)},defaultValue:{kind:ue.Kind.BOOLEAN,value:!0}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([U.ENUM_UPPER,U.INPUT_OBJECT_UPPER,U.INTERFACE_UPPER,U.OBJECT_UPPER]),name:(0,ae.stringToNameNode)(U.CONFIGURE_CHILD_DESCRIPTIONS),repeatable:!1};ee.EDFS_ARGS_REGEXP=/{{\s*args\.([a-zA-Z0-9_]+)\s*}}/g;ee.MAX_OR_SCOPES=16});var BN=w(nc=>{"use strict";m();T();N();Object.defineProperty(nc,"__esModule",{value:!0});nc.newParentTagData=$9;nc.newChildTagData=Q9;nc.validateImplicitFieldSets=Y9;nc.newContractTagOptionsFromArrays=J9;nc.getDescriptionFromString=H9;var Hr=Ae(),j9=ou(),K9=Es(),G9=Yr(),NC=Jr();function $9(e){return{childTagDataByChildName:new Map,tagNames:new Set,typeName:e}}function Q9(e){return{name:e,tagNames:new Set,tagNamesByArgumentName:new Map}}function Y9({conditionalFieldDataByCoords:e,currentSubgraphName:t,entityData:n,implicitKeys:r,objectData:i,parentDefinitionDataByTypeName:a,graphNode:o}){let c=(0,NC.getValueOrDefault)(n.keyFieldSetDatasBySubgraphName,t,()=>new Map);for(let[l,p]of n.documentNodeByKeyFieldSet){if(c.has(l))continue;let f=[i],y=[],g=[],v=-1,F=!0,k=!0;(0,Hr.visit)(p,{Argument:{enter(){return k=!1,Hr.BREAK}},Field:{enter(K){let $=f[v];if(F)return k=!1,Hr.BREAK;let ne=K.name.value,z=$.fieldDataByName.get(ne);if(!z||z.argumentDataByName.size||y[v].has(ne))return k=!1,Hr.BREAK;let{isUnconditionallyProvided:Te}=(0,NC.getOrThrowError)(z.externalFieldDataBySubgraphName,t,`${z.originalParentTypeName}.${ne}.externalFieldDataBySubgraphName`),pe=e.get(`${z.renamedParentTypeName}.${ne}`);if(pe){if(pe.providedBy.length>0)g.push(...pe.providedBy);else if(pe.requiredBy.length>0)return k=!1,Hr.BREAK}else if(!Te)return k=!1,Hr.BREAK;y[v].add(ne);let Fe=(0,j9.getTypeNodeNamedTypeName)(z.node.type);if(K9.BASE_SCALARS.has(Fe))return;let Ve=a.get(Fe);if(!Ve)return k=!1,Hr.BREAK;if(Ve.kind===Hr.Kind.OBJECT_TYPE_DEFINITION){F=!0,f.push(Ve);return}if((0,G9.isKindAbstract)(Ve.kind))return k=!1,Hr.BREAK}},InlineFragment:{enter(){return k=!1,Hr.BREAK}},SelectionSet:{enter(){if(!F||(v+=1,F=!1,v<0||v>=f.length))return k=!1,Hr.BREAK;y.push(new Set)},leave(){if(F)return k=!1,Hr.BREAK;v-=1,f.pop(),y.pop()}}}),k&&(r.push(Y(x({fieldName:"",selectionSet:l},g.length>0?{conditions:g}:{}),{disableEntityResolver:!0})),o&&o.satisfiedFieldSets.add(l))}}function J9(e,t){return{tagNamesToExclude:new Set(e),tagNamesToInclude:new Set(t)}}function H9(e){if(e)return{block:!0,kind:Hr.Kind.STRING,value:e}}});var hl=w(mt=>{"use strict";m();T();N();Object.defineProperty(mt,"__esModule",{value:!0});mt.MergeMethod=void 0;mt.newPersistedDirectivesData=W9;mt.isNodeExternalOrShareable=X9;mt.isTypeRequired=Z9;mt.areDefaultValuesCompatible=EC;mt.compareAndValidateInputValueDefaultValues=e7;mt.setMutualExecutableLocations=t7;mt.isTypeNameRootType=n7;mt.getRenamedRootTypeName=r7;mt.childMapToValueArray=a7;mt.setLongestDescription=s7;mt.isParentDataRootType=hC;mt.isParentDataInterfaceType=o7;mt.setParentDataExtensionType=u7;mt.extractPersistedDirectives=d7;mt.propagateAuthDirectives=p7;mt.propagateFieldAuthDirectives=f7;mt.generateDeprecatedDirective=yv;mt.getClientPersistedDirectiveNodes=Ev;mt.getNodeForRouterSchemaByData=N7;mt.getClientSchemaFieldNodeByFieldData=T7;mt.getNodeWithPersistedDirectivesByInputValueData=IC;mt.addValidPersistedDirectiveDefinitionNodeByData=h7;mt.newInvalidFieldNames=y7;mt.validateExternalAndShareable=I7;mt.isTypeValidImplementation=UN;mt.isNodeDataInaccessible=gC;mt.isLeafKind=g7;mt.getSubscriptionFilterValue=_7;mt.getParentTypeName=v7;mt.newConditionalFieldData=S7;mt.getDefinitionDataCoords=O7;mt.isParentDataCompositeOutputType=D7;mt.newExternalFieldData=b7;mt.getInitialFederatedDescription=A7;mt.areKindsEqual=R7;mt.isFieldData=_C;mt.isInputNodeKind=P7;mt.isOutputNodeKind=F7;var st=Ae(),Tv=hp(),El=Yr(),hv=ia(),kt=ur(),yp=Jr(),z9=BN();function W9(){return{deprecatedReason:"",directivesByDirectiveName:new Map,isDeprecated:!1,tagDirectiveByName:new Map}}function X9(e,t,n){var i;let r={isExternal:n.has(kt.EXTERNAL),isShareable:t||n.has(kt.SHAREABLE)};if(!((i=e.directives)!=null&&i.length))return r;for(let a of e.directives){let o=a.name.value;if(o===kt.EXTERNAL){r.isExternal=!0;continue}o===kt.SHAREABLE&&(r.isShareable=!0)}return r}function Z9(e){return e.kind===st.Kind.NON_NULL_TYPE}function EC(e,t){switch(e.kind){case st.Kind.LIST_TYPE:return t.kind===st.Kind.LIST||t.kind===st.Kind.NULL;case st.Kind.NAMED_TYPE:if(t.kind===st.Kind.NULL)return!0;switch(e.name.value){case kt.BOOLEAN_SCALAR:return t.kind===st.Kind.BOOLEAN;case kt.FLOAT_SCALAR:return t.kind===st.Kind.INT||t.kind===st.Kind.FLOAT;case kt.INT_SCALAR:return t.kind===st.Kind.INT;case kt.STRING_SCALAR:return t.kind===st.Kind.STRING;default:return!0}case st.Kind.NON_NULL_TYPE:return t.kind===st.Kind.NULL?!1:EC(e.type,t)}}function e7(e,t,n){if(!e.defaultValue)return;if(!t.defaultValue){e.includeDefaultValue=!1;return}let r=(0,st.print)(e.defaultValue),i=(0,st.print)(t.defaultValue);if(r!==i){n.push((0,hv.incompatibleInputValueDefaultValuesError)(`${e.isArgument?kt.ARGUMENT:kt.INPUT_FIELD} "${e.name}"`,e.originalCoords,[...t.subgraphNames],r,i));return}}function t7(e,t){let n=new Set;for(let r of t)e.executableLocations.has(r)&&n.add(r);e.executableLocations=n}function n7(e,t){return kt.ROOT_TYPE_NAMES.has(e)||t.has(e)}function r7(e,t){let n=t.get(e);if(!n)return e;switch(n){case st.OperationTypeNode.MUTATION:return kt.MUTATION;case st.OperationTypeNode.SUBSCRIPTION:return kt.SUBSCRIPTION;default:return kt.QUERY}}function i7(e){for(let t of e.argumentDataByName.values()){for(let n of t.directivesByDirectiveName.values())t.node.directives.push(...n);e.node.arguments.push(t.node)}}function a7(e){let t=[];for(let n of e.values()){_C(n)&&i7(n);for(let r of n.directivesByDirectiveName.values())n.node.directives.push(...r);t.push(n.node)}return t}function s7(e,t){if(t.description){if("configureDescriptionDataBySubgraphName"in t){for(let{propagate:n}of t.configureDescriptionDataBySubgraphName.values())if(!n)return}(!e.description||e.description.value.length0&&e.persistedDirectivesData.directivesByDirectiveName.set(kt.REQUIRES_SCOPES,[(0,yp.generateRequiresScopesDirective)(t.requiredScopes)]))}function f7(e,t){if(!t)return;let n=t.fieldAuthDataByFieldName.get(e.name);n&&(n.originalData.requiresAuthentication&&e.persistedDirectivesData.directivesByDirectiveName.set(kt.AUTHENTICATED,[(0,yp.generateSimpleDirective)(kt.AUTHENTICATED)]),n.originalData.requiredScopes.length>0&&e.persistedDirectivesData.directivesByDirectiveName.set(kt.REQUIRES_SCOPES,[(0,yp.generateRequiresScopesDirective)(n.originalData.requiredScopes)]))}function yv(e){return{kind:st.Kind.DIRECTIVE,name:(0,El.stringToNameNode)(kt.DEPRECATED),arguments:[{kind:st.Kind.ARGUMENT,name:(0,El.stringToNameNode)(kt.REASON),value:{kind:st.Kind.STRING,value:e||kt.DEPRECATED_DEFAULT_ARGUMENT_VALUE}}]}}function m7(e,t,n,r){let i=[];for(let[a,o]of e){let c=t.get(a);if(c){if(o.length<2){i.push(...o);continue}if(!c.repeatable){r.push((0,hv.invalidRepeatedFederatedDirectiveErrorMessage)(a,n));continue}i.push(...o)}}return i}function yC(e,t,n){let r=[...e.persistedDirectivesData.tagDirectiveByName.values()];return e.persistedDirectivesData.isDeprecated&&r.push(yv(e.persistedDirectivesData.deprecatedReason)),r.push(...m7(e.persistedDirectivesData.directivesByDirectiveName,t,e.name,n)),r}function Ev(e){let t=[];e.persistedDirectivesData.isDeprecated&&t.push(yv(e.persistedDirectivesData.deprecatedReason));for(let[n,r]of e.persistedDirectivesData.directivesByDirectiveName)kt.PERSISTED_CLIENT_DIRECTIVES.has(n)&&t.push(r[0]);return t}function N7(e,t,n){return e.node.name=(0,El.stringToNameNode)(e.name),e.node.description=e.description,e.node.directives=yC(e,t,n),e.node}function T7(e){let t=Ev(e),n=[];for(let r of e.argumentDataByName.values())gC(r)||n.push(Y(x({},r.node),{directives:Ev(r)}));return Y(x({},e.node),{directives:t,arguments:n})}function IC(e,t,n){return e.node.name=(0,El.stringToNameNode)(e.name),e.node.type=e.type,e.node.description=e.description,e.node.directives=yC(e,t,n),e.includeDefaultValue&&(e.node.defaultValue=e.defaultValue),e.node}function E7(e,t,n,r,i){let a=[];for(let[o,c]of t.argumentDataByArgumentName){let l=(0,yp.getEntriesNotInHashSet)(t.subgraphNames,c.subgraphNames);if(l.length>0){c.requiredSubgraphNames.size>0&&a.push({inputValueName:o,missingSubgraphs:l,requiredSubgraphs:[...c.requiredSubgraphNames]});continue}e.push(IC(c,n,r)),i&&i.add(o)}return a.length>0?(r.push((0,hv.invalidRequiredInputValueError)(kt.DIRECTIVE_DEFINITION,`@${t.name}`,a)),!1):!0}function h7(e,t,n,r){let i=[];E7(i,t,n,r)&&e.push({arguments:i,kind:st.Kind.DIRECTIVE_DEFINITION,locations:(0,El.setToNameNodeArray)(t.executableLocations),name:(0,El.stringToNameNode)(t.name),repeatable:t.repeatable,description:t.description})}function y7(){return{byShareable:new Set,subgraphNamesByExternalFieldName:new Map}}function I7(e,t){let n=e.isShareableBySubgraphName.size,r=new Array,i=0;for(let[a,o]of e.isShareableBySubgraphName){let c=e.externalFieldDataBySubgraphName.get(a);if(c&&!c.isUnconditionallyProvided){r.push(a);continue}o||(i+=1)}switch(i){case 0:n===r.length&&t.subgraphNamesByExternalFieldName.set(e.name,r);return;case 1:if(n===1)return;n-r.length!==1&&t.byShareable.add(e.name);return;default:t.byShareable.add(e.name)}}var TC;(function(e){e[e.UNION=0]="UNION",e[e.INTERSECTION=1]="INTERSECTION",e[e.CONSISTENT=2]="CONSISTENT"})(TC||(mt.MergeMethod=TC={}));function UN(e,t,n){if(e.kind===st.Kind.NON_NULL_TYPE)return t.kind!==st.Kind.NON_NULL_TYPE?!1:UN(e.type,t.type,n);if(t.kind===st.Kind.NON_NULL_TYPE)return UN(e,t.type,n);switch(e.kind){case st.Kind.NAMED_TYPE:if(t.kind===st.Kind.NAMED_TYPE){let r=e.name.value,i=t.name.value;if(r===i)return!0;let a=n.get(r);return a?a.has(i):!1}return!1;default:return t.kind===st.Kind.LIST_TYPE?UN(e.type,t.type,n):!1}}function gC(e){return e.persistedDirectivesData.directivesByDirectiveName.has(kt.INACCESSIBLE)||e.directivesByDirectiveName.has(kt.INACCESSIBLE)}function g7(e){return e===st.Kind.SCALAR_TYPE_DEFINITION||e===st.Kind.ENUM_TYPE_DEFINITION}function _7(e){switch(e.kind){case st.Kind.BOOLEAN:return e.value;case st.Kind.ENUM:case st.Kind.STRING:return e.value;case st.Kind.FLOAT:case st.Kind.INT:try{return parseFloat(e.value)}catch(t){return"NaN"}case st.Kind.NULL:return null}}function v7(e){return e.kind===st.Kind.OBJECT_TYPE_DEFINITION&&e.renamedTypeName||e.name}function S7(){return{providedBy:[],requiredBy:[]}}function O7(e,t){switch(e.kind){case st.Kind.ENUM_VALUE_DEFINITION:return`${e.parentTypeName}.${e.name}`;case st.Kind.FIELD_DEFINITION:return`${t?e.renamedParentTypeName:e.originalParentTypeName}.${e.name}`;case st.Kind.ARGUMENT:case st.Kind.INPUT_VALUE_DEFINITION:return t?e.federatedCoords:e.originalCoords;case st.Kind.OBJECT_TYPE_DEFINITION:return t?e.renamedTypeName:e.name;default:return e.name}}function D7(e){return e.kind===st.Kind.OBJECT_TYPE_DEFINITION||e.kind===st.Kind.INTERFACE_TYPE_DEFINITION}function b7(e){return{isDefinedExternal:e,isUnconditionallyProvided:!e}}function A7(e){let{value:t,done:n}=e.configureDescriptionDataBySubgraphName.values().next();if(n)return e.description;if(t.propagate)return(0,z9.getDescriptionFromString)(t.description)||e.description}function R7(e,t){return e.kind===t.kind}function _C(e){return e.kind===st.Kind.FIELD_DEFINITION}function P7(e){return kt.INPUT_NODE_KINDS.has(e)}function F7(e){return kt.OUTPUT_NODE_KINDS.has(e)}});var _v={};sm(_v,{__addDisposableResource:()=>KC,__assign:()=>kN,__asyncDelegator:()=>BC,__asyncGenerator:()=>CC,__asyncValues:()=>UC,__await:()=>yl,__awaiter:()=>AC,__classPrivateFieldGet:()=>qC,__classPrivateFieldIn:()=>jC,__classPrivateFieldSet:()=>VC,__createBinding:()=>xN,__decorate:()=>OC,__disposeResources:()=>GC,__esDecorate:()=>w7,__exportStar:()=>PC,__extends:()=>vC,__generator:()=>RC,__importDefault:()=>xC,__importStar:()=>MC,__makeTemplateObject:()=>kC,__metadata:()=>bC,__param:()=>DC,__propKey:()=>C7,__read:()=>gv,__rest:()=>SC,__runInitializers:()=>L7,__setFunctionName:()=>B7,__spread:()=>FC,__spreadArray:()=>LC,__spreadArrays:()=>wC,__values:()=>MN,default:()=>M7});function vC(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");Iv(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}function SC(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i=0;c--)(o=e[c])&&(a=(i<3?o(a):i>3?o(t,n,a):o(t,n))||a);return i>3&&a&&Object.defineProperty(t,n,a),a}function DC(e,t){return function(n,r){t(n,r,e)}}function w7(e,t,n,r,i,a){function o($){if($!==void 0&&typeof $!="function")throw new TypeError("Function expected");return $}for(var c=r.kind,l=c==="getter"?"get":c==="setter"?"set":"value",p=!t&&e?r.static?e:e.prototype:null,f=t||(p?Object.getOwnPropertyDescriptor(p,r.name):{}),y,g=!1,v=n.length-1;v>=0;v--){var F={};for(var k in r)F[k]=k==="access"?{}:r[k];for(var k in r.access)F.access[k]=r.access[k];F.addInitializer=function($){if(g)throw new TypeError("Cannot add initializers after decoration has completed");a.push(o($||null))};var K=(0,n[v])(c==="accessor"?{get:f.get,set:f.set}:f[l],F);if(c==="accessor"){if(K===void 0)continue;if(K===null||typeof K!="object")throw new TypeError("Object expected");(y=o(K.get))&&(f.get=y),(y=o(K.set))&&(f.set=y),(y=o(K.init))&&i.unshift(y)}else(y=o(K))&&(c==="field"?i.unshift(y):f[l]=y)}p&&Object.defineProperty(p,r.name,f),g=!0}function L7(e,t,n){for(var r=arguments.length>2,i=0;i0&&a[a.length-1])&&(p[0]===6||p[0]===2)){n=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function gv(e,t){var n=typeof Symbol=="function"&&e[Symbol.iterator];if(!n)return e;var r=n.call(e),i,a=[],o;try{for(;(t===void 0||t-- >0)&&!(i=r.next()).done;)a.push(i.value)}catch(c){o={error:c}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(o)throw o.error}}return a}function FC(){for(var e=[],t=0;t1||c(g,v)})})}function c(g,v){try{l(r[g](v))}catch(F){y(a[0][3],F)}}function l(g){g.value instanceof yl?Promise.resolve(g.value.v).then(p,f):y(a[0][2],g)}function p(g){c("next",g)}function f(g){c("throw",g)}function y(g,v){g(v),a.shift(),a.length&&c(a[0][0],a[0][1])}}function BC(e){var t,n;return t={},r("next"),r("throw",function(i){throw i}),r("return"),t[Symbol.iterator]=function(){return this},t;function r(i,a){t[i]=e[i]?function(o){return(n=!n)?{value:yl(e[i](o)),done:!1}:a?a(o):o}:a}}function UC(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],n;return t?t.call(e):(e=typeof MN=="function"?MN(e):e[Symbol.iterator](),n={},r("next"),r("throw"),r("return"),n[Symbol.asyncIterator]=function(){return this},n);function r(a){n[a]=e[a]&&function(o){return new Promise(function(c,l){o=e[a](o),i(c,l,o.done,o.value)})}}function i(a,o,c,l){Promise.resolve(l).then(function(p){a({value:p,done:c})},o)}}function kC(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}function MC(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var n in e)n!=="default"&&Object.prototype.hasOwnProperty.call(e,n)&&xN(t,e,n);return U7(t,e),t}function xC(e){return e&&e.__esModule?e:{default:e}}function qC(e,t,n,r){if(n==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof t=="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return n==="m"?r:n==="a"?r.call(e):r?r.value:t.get(e)}function VC(e,t,n,r,i){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t=="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?i.call(e,n):i?i.value=n:t.set(e,n),n}function jC(e,t){if(t===null||typeof t!="object"&&typeof t!="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof e=="function"?t===e:e.has(t)}function KC(e,t,n){if(t!=null){if(typeof t!="object"&&typeof t!="function")throw new TypeError("Object expected.");var r;if(n){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose]}if(r===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose]}if(typeof r!="function")throw new TypeError("Object not disposable.");e.stack.push({value:t,dispose:r,async:n})}else n&&e.stack.push({async:!0});return t}function GC(e){function t(r){e.error=e.hasError?new k7(r,e.error,"An error was suppressed during disposal."):r,e.hasError=!0}function n(){for(;e.stack.length;){var r=e.stack.pop();try{var i=r.dispose&&r.dispose.call(r.value);if(r.async)return Promise.resolve(i).then(n,function(a){return t(a),n()})}catch(a){t(a)}}if(e.hasError)throw e.error}return n()}var Iv,kN,xN,U7,k7,M7,vv=Lu(()=>{"use strict";m();T();N();Iv=function(e,t){return Iv=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i])},Iv(e,t)};kN=function(){return kN=Object.assign||function(t){for(var n,r=1,i=arguments.length;rdB,__assign:()=>qN,__asyncDelegator:()=>rB,__asyncGenerator:()=>nB,__asyncValues:()=>iB,__await:()=>Il,__awaiter:()=>zC,__classPrivateFieldGet:()=>uB,__classPrivateFieldIn:()=>lB,__classPrivateFieldSet:()=>cB,__createBinding:()=>jN,__decorate:()=>YC,__disposeResources:()=>pB,__esDecorate:()=>x7,__exportStar:()=>XC,__extends:()=>$C,__generator:()=>WC,__importDefault:()=>oB,__importStar:()=>sB,__makeTemplateObject:()=>aB,__metadata:()=>HC,__param:()=>JC,__propKey:()=>V7,__read:()=>Ov,__rest:()=>QC,__runInitializers:()=>q7,__setFunctionName:()=>j7,__spread:()=>ZC,__spreadArray:()=>tB,__spreadArrays:()=>eB,__values:()=>VN,default:()=>$7});function $C(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");Sv(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}function QC(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i=0;c--)(o=e[c])&&(a=(i<3?o(a):i>3?o(t,n,a):o(t,n))||a);return i>3&&a&&Object.defineProperty(t,n,a),a}function JC(e,t){return function(n,r){t(n,r,e)}}function x7(e,t,n,r,i,a){function o($){if($!==void 0&&typeof $!="function")throw new TypeError("Function expected");return $}for(var c=r.kind,l=c==="getter"?"get":c==="setter"?"set":"value",p=!t&&e?r.static?e:e.prototype:null,f=t||(p?Object.getOwnPropertyDescriptor(p,r.name):{}),y,g=!1,v=n.length-1;v>=0;v--){var F={};for(var k in r)F[k]=k==="access"?{}:r[k];for(var k in r.access)F.access[k]=r.access[k];F.addInitializer=function($){if(g)throw new TypeError("Cannot add initializers after decoration has completed");a.push(o($||null))};var K=(0,n[v])(c==="accessor"?{get:f.get,set:f.set}:f[l],F);if(c==="accessor"){if(K===void 0)continue;if(K===null||typeof K!="object")throw new TypeError("Object expected");(y=o(K.get))&&(f.get=y),(y=o(K.set))&&(f.set=y),(y=o(K.init))&&i.unshift(y)}else(y=o(K))&&(c==="field"?i.unshift(y):f[l]=y)}p&&Object.defineProperty(p,r.name,f),g=!0}function q7(e,t,n){for(var r=arguments.length>2,i=0;i0&&a[a.length-1])&&(p[0]===6||p[0]===2)){n=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function Ov(e,t){var n=typeof Symbol=="function"&&e[Symbol.iterator];if(!n)return e;var r=n.call(e),i,a=[],o;try{for(;(t===void 0||t-- >0)&&!(i=r.next()).done;)a.push(i.value)}catch(c){o={error:c}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(o)throw o.error}}return a}function ZC(){for(var e=[],t=0;t1||c(g,v)})})}function c(g,v){try{l(r[g](v))}catch(F){y(a[0][3],F)}}function l(g){g.value instanceof Il?Promise.resolve(g.value.v).then(p,f):y(a[0][2],g)}function p(g){c("next",g)}function f(g){c("throw",g)}function y(g,v){g(v),a.shift(),a.length&&c(a[0][0],a[0][1])}}function rB(e){var t,n;return t={},r("next"),r("throw",function(i){throw i}),r("return"),t[Symbol.iterator]=function(){return this},t;function r(i,a){t[i]=e[i]?function(o){return(n=!n)?{value:Il(e[i](o)),done:!1}:a?a(o):o}:a}}function iB(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],n;return t?t.call(e):(e=typeof VN=="function"?VN(e):e[Symbol.iterator](),n={},r("next"),r("throw"),r("return"),n[Symbol.asyncIterator]=function(){return this},n);function r(a){n[a]=e[a]&&function(o){return new Promise(function(c,l){o=e[a](o),i(c,l,o.done,o.value)})}}function i(a,o,c,l){Promise.resolve(l).then(function(p){a({value:p,done:c})},o)}}function aB(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}function sB(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var n in e)n!=="default"&&Object.prototype.hasOwnProperty.call(e,n)&&jN(t,e,n);return K7(t,e),t}function oB(e){return e&&e.__esModule?e:{default:e}}function uB(e,t,n,r){if(n==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof t=="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return n==="m"?r:n==="a"?r.call(e):r?r.value:t.get(e)}function cB(e,t,n,r,i){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t=="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?i.call(e,n):i?i.value=n:t.set(e,n),n}function lB(e,t){if(t===null||typeof t!="object"&&typeof t!="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof e=="function"?t===e:e.has(t)}function dB(e,t,n){if(t!=null){if(typeof t!="object"&&typeof t!="function")throw new TypeError("Object expected.");var r;if(n){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose]}if(r===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose]}if(typeof r!="function")throw new TypeError("Object not disposable.");e.stack.push({value:t,dispose:r,async:n})}else n&&e.stack.push({async:!0});return t}function pB(e){function t(r){e.error=e.hasError?new G7(r,e.error,"An error was suppressed during disposal."):r,e.hasError=!0}function n(){for(;e.stack.length;){var r=e.stack.pop();try{var i=r.dispose&&r.dispose.call(r.value);if(r.async)return Promise.resolve(i).then(n,function(a){return t(a),n()})}catch(a){t(a)}}if(e.hasError)throw e.error}return n()}var Sv,qN,jN,K7,G7,$7,mB=Lu(()=>{"use strict";m();T();N();Sv=function(e,t){return Sv=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i])},Sv(e,t)};qN=function(){return qN=Object.assign||function(t){for(var n,r=1,i=arguments.length;r{"use strict";m();T();N()});var Ip=w(cr=>{"use strict";m();T();N();Object.defineProperty(cr,"__esModule",{value:!0});cr.assertSome=cr.isSome=cr.compareNodes=cr.nodeToString=cr.compareStrings=cr.isValidPath=cr.isDocumentString=cr.asArray=void 0;var Q7=Ae(),Y7=e=>Array.isArray(e)?e:e?[e]:[];cr.asArray=Y7;var J7=/\.[a-z0-9]+$/i;function H7(e){if(typeof e!="string"||J7.test(e))return!1;try{return(0,Q7.parse)(e),!0}catch(t){}return!1}cr.isDocumentString=H7;var z7=/[‘“!%^<>`]/;function W7(e){return typeof e=="string"&&!z7.test(e)}cr.isValidPath=W7;function TB(e,t){return String(e)String(t)?1:0}cr.compareStrings=TB;function Dv(e){var n,r;let t;return"alias"in e&&(t=(n=e.alias)==null?void 0:n.value),t==null&&"name"in e&&(t=(r=e.name)==null?void 0:r.value),t==null&&(t=e.kind),t}cr.nodeToString=Dv;function X7(e,t,n){let r=Dv(e),i=Dv(t);return typeof n=="function"?n(r,i):TB(r,i)}cr.compareNodes=X7;function Z7(e){return e!=null}cr.isSome=Z7;function eZ(e,t="Value should be something"){if(e==null)throw new Error(t)}cr.assertSome=eZ});var gp=w(GN=>{"use strict";m();T();N();Object.defineProperty(GN,"__esModule",{value:!0});GN.inspect=void 0;var yB=3;function tZ(e){return KN(e,[])}GN.inspect=tZ;function KN(e,t){switch(typeof e){case"string":return JSON.stringify(e);case"function":return e.name?`[function ${e.name}]`:"[function]";case"object":return nZ(e,t);default:return String(e)}}function EB(e){return(e.name="GraphQLError")?e.toString():`${e.name}: ${e.message}; +`))}return Y(x({},e),{value:t,block:!0})}function sC(e){return e.arguments?e.arguments.sort((n,r)=>n.name.value.localeCompare(r.name.value)):e.arguments}function PN(e){let t=e.selections;return Y(x({},e),{selections:t.sort((n,r)=>{var a,o,c,l;return vn.NAME in n?vn.NAME in r?n.name.value.localeCompare(r.name.value):-1:vn.NAME in r?1:((o=(a=n.typeCondition)==null?void 0:a.name.value)!=null?o:"").localeCompare((l=(c=r.typeCondition)==null?void 0:c.name.value)!=null?l:"")}).map(n=>{switch(n.kind){case Ut.Kind.FIELD:return Y(x({},n),{arguments:sC(n),selectionSet:n.selectionSet?PN(n.selectionSet):n.selectionSet});case Ut.Kind.FRAGMENT_SPREAD:return n;case Ut.Kind.INLINE_FRAGMENT:return Y(x({},n),{selectionSet:PN(n.selectionSet)})}})})}function o9(e){return Y(x({},e),{definitions:e.definitions.map(t=>t.kind!==Ut.Kind.OPERATION_DEFINITION?t:Y(x({},t),{selectionSet:PN(t.selectionSet)}))})}function oC(e,t=!0){return(0,Ut.parse)(e,{noLocation:t})}function u9(e,t=!0){try{return{documentNode:oC(e,t)}}catch(n){return{error:n}}}});var lC=w(ml=>{"use strict";m();T();N();Object.defineProperty(ml,"__esModule",{value:!0});ml.AccumulatorMap=void 0;ml.mapValue=fl;ml.extendSchemaImpl=c9;var Ue=Ae(),Ts=class extends Map{get[Symbol.toStringTag](){return"AccumulatorMap"}add(t,n){let r=this.get(t);r===void 0?this.set(t,[n]):r.push(n)}};ml.AccumulatorMap=Ts;function fl(e,t){let n=Object.create(null);for(let r of Object.keys(e))n[r]=t(e[r],r);return n}function c9(e,t,n){var De,_e,Ce,_t;let r=[],i=new Ts,a=new Ts,o=new Ts,c=new Ts,l=new Ts,p=new Ts,f=[],y,g=[],v=!1;for(let J of t.definitions){switch(J.kind){case Ue.Kind.SCHEMA_DEFINITION:y=J;break;case Ue.Kind.SCHEMA_EXTENSION:g.push(J);break;case Ue.Kind.DIRECTIVE_DEFINITION:f.push(J);break;case Ue.Kind.SCALAR_TYPE_DEFINITION:case Ue.Kind.OBJECT_TYPE_DEFINITION:case Ue.Kind.INTERFACE_TYPE_DEFINITION:case Ue.Kind.UNION_TYPE_DEFINITION:case Ue.Kind.ENUM_TYPE_DEFINITION:case Ue.Kind.INPUT_OBJECT_TYPE_DEFINITION:r.push(J);break;case Ue.Kind.SCALAR_TYPE_EXTENSION:i.add(J.name.value,J);break;case Ue.Kind.OBJECT_TYPE_EXTENSION:a.add(J.name.value,J);break;case Ue.Kind.INTERFACE_TYPE_EXTENSION:o.add(J.name.value,J);break;case Ue.Kind.UNION_TYPE_EXTENSION:c.add(J.name.value,J);break;case Ue.Kind.ENUM_TYPE_EXTENSION:l.add(J.name.value,J);break;case Ue.Kind.INPUT_OBJECT_TYPE_EXTENSION:p.add(J.name.value,J);break;default:continue}v=!0}if(!v)return e;let P=new Map;for(let J of e.types){let se=z(J);se&&P.set(J.name,se)}for(let J of r){let se=J.name.value;P.set(se,(De=uC.get(se))!=null?De:oe(J))}for(let[J,se]of a)P.set(J,new Ue.GraphQLObjectType({name:J,interfaces:()=>$t(se),fields:()=>dn(se),extensionASTNodes:se}));if(n!=null&&n.addInvalidExtensionOrphans){for(let[J,se]of o)P.set(J,new Ue.GraphQLInterfaceType({name:J,interfaces:()=>$t(se),fields:()=>dn(se),extensionASTNodes:se}));for(let[J,se]of l)P.set(J,new Ue.GraphQLEnumType({name:J,values:Un(se),extensionASTNodes:se}));for(let[J,se]of c)P.set(J,new Ue.GraphQLUnionType({name:J,types:()=>bn(se),extensionASTNodes:se}));for(let[J,se]of i)P.set(J,new Ue.GraphQLScalarType({name:J,extensionASTNodes:se}));for(let[J,se]of p)P.set(J,new Ue.GraphQLInputObjectType({name:J,fields:()=>Rr(se),extensionASTNodes:se}))}let U=x(x({query:e.query&&$(e.query),mutation:e.mutation&&$(e.mutation),subscription:e.subscription&&$(e.subscription)},y&&zt([y])),zt(g));return Y(x({description:(Ce=(_e=y==null?void 0:y.description)==null?void 0:_e.value)!=null?Ce:e.description},U),{types:Array.from(P.values()),directives:[...e.directives.map(ne),...f.map(Vt)],extensions:e.extensions,astNode:y!=null?y:e.astNode,extensionASTNodes:e.extensionASTNodes.concat(g),assumeValid:(_t=n==null?void 0:n.assumeValid)!=null?_t:!1});function K(J){return(0,Ue.isListType)(J)?new Ue.GraphQLList(K(J.ofType)):(0,Ue.isNonNullType)(J)?new Ue.GraphQLNonNull(K(J.ofType)):$(J)}function $(J){return P.get(J.name)}function ne(J){if((0,Ue.isSpecifiedDirective)(J))return J;let se=J.toConfig();return new Ue.GraphQLDirective(Y(x({},se),{args:fl(se.args,gt)}))}function z(J){if((0,Ue.isIntrospectionType)(J)||(0,Ue.isSpecifiedScalarType)(J))return J;if((0,Ue.isScalarType)(J))return Fe(J);if((0,Ue.isObjectType)(J))return xe(J);if((0,Ue.isInterfaceType)(J))return et(J);if((0,Ue.isUnionType)(J))return X(J);if((0,Ue.isEnumType)(J))return pe(J);if((0,Ue.isInputObjectType)(J))return Te(J)}function Te(J){var Qe;let se=J.toConfig(),qe=(Qe=p.get(se.name))!=null?Qe:[];return new Ue.GraphQLInputObjectType(Y(x({},se),{fields:()=>x(x({},fl(se.fields,Lt=>Y(x({},Lt),{type:K(Lt.type)}))),Rr(qe)),extensionASTNodes:se.extensionASTNodes.concat(qe)}))}function pe(J){var Qe;let se=J.toConfig(),qe=(Qe=l.get(J.name))!=null?Qe:[];return new Ue.GraphQLEnumType(Y(x({},se),{values:x(x({},se.values),Un(qe)),extensionASTNodes:se.extensionASTNodes.concat(qe)}))}function Fe(J){var Lt,tt;let se=J.toConfig(),qe=(Lt=i.get(se.name))!=null?Lt:[],Qe=se.specifiedByURL;for(let At of qe)Qe=(tt=cC(At))!=null?tt:Qe;return new Ue.GraphQLScalarType(Y(x({},se),{specifiedByURL:Qe,extensionASTNodes:se.extensionASTNodes.concat(qe)}))}function xe(J){var Qe;let se=J.toConfig(),qe=(Qe=a.get(se.name))!=null?Qe:[];return new Ue.GraphQLObjectType(Y(x({},se),{interfaces:()=>[...J.getInterfaces().map($),...$t(qe)],fields:()=>x(x({},fl(se.fields,ve)),dn(qe)),extensionASTNodes:se.extensionASTNodes.concat(qe)}))}function et(J){var Qe;let se=J.toConfig(),qe=(Qe=o.get(se.name))!=null?Qe:[];return new Ue.GraphQLInterfaceType(Y(x({},se),{interfaces:()=>[...J.getInterfaces().map($),...$t(qe)],fields:()=>x(x({},fl(se.fields,ve)),dn(qe)),extensionASTNodes:se.extensionASTNodes.concat(qe)}))}function X(J){var Qe;let se=J.toConfig(),qe=(Qe=c.get(se.name))!=null?Qe:[];return new Ue.GraphQLUnionType(Y(x({},se),{types:()=>[...J.getTypes().map($),...bn(qe)],extensionASTNodes:se.extensionASTNodes.concat(qe)}))}function ve(J){return Y(x({},J),{type:K(J.type),args:J.args&&fl(J.args,gt)})}function gt(J){return Y(x({},J),{type:K(J.type)})}function zt(J){var qe;let se={};for(let Qe of J){let Lt=(qe=Qe.operationTypes)!=null?qe:[];for(let tt of Lt)se[tt.operation]=Wt(tt.type)}return se}function Wt(J){var Qe;let se=J.name.value,qe=(Qe=uC.get(se))!=null?Qe:P.get(se);if(qe===void 0)throw new Error(`Unknown type: "${se}".`);return qe}function Dn(J){return J.kind===Ue.Kind.LIST_TYPE?new Ue.GraphQLList(Dn(J.type)):J.kind===Ue.Kind.NON_NULL_TYPE?new Ue.GraphQLNonNull(Dn(J.type)):Wt(J)}function Vt(J){var se;return new Ue.GraphQLDirective({name:J.name.value,description:(se=J.description)==null?void 0:se.value,locations:J.locations.map(({value:qe})=>qe),isRepeatable:J.repeatable,args:Ar(J.arguments),astNode:J})}function dn(J){var qe,Qe;let se=Object.create(null);for(let Lt of J){let tt=(qe=Lt.fields)!=null?qe:[];for(let At of tt)se[At.name.value]={type:Dn(At.type),description:(Qe=At.description)==null?void 0:Qe.value,args:Ar(At.arguments),deprecationReason:wN(At),astNode:At}}return se}function Ar(J){var Qe;let se=J!=null?J:[],qe=Object.create(null);for(let Lt of se){let tt=Dn(Lt.type);qe[Lt.name.value]={type:tt,description:(Qe=Lt.description)==null?void 0:Qe.value,defaultValue:(0,Ue.valueFromAST)(Lt.defaultValue,tt),deprecationReason:wN(Lt),astNode:Lt}}return qe}function Rr(J){var qe,Qe;let se=Object.create(null);for(let Lt of J){let tt=(qe=Lt.fields)!=null?qe:[];for(let At of tt){let Ha=Dn(At.type);se[At.name.value]={type:Ha,description:(Qe=At.description)==null?void 0:Qe.value,defaultValue:(0,Ue.valueFromAST)(At.defaultValue,Ha),deprecationReason:wN(At),astNode:At}}}return se}function Un(J){var qe,Qe;let se=Object.create(null);for(let Lt of J){let tt=(qe=Lt.values)!=null?qe:[];for(let At of tt)se[At.name.value]={description:(Qe=At.description)==null?void 0:Qe.value,deprecationReason:wN(At),astNode:At}}return se}function $t(J){return J.flatMap(se=>{var qe,Qe;return(Qe=(qe=se.interfaces)==null?void 0:qe.map(Wt))!=null?Qe:[]})}function bn(J){return J.flatMap(se=>{var qe,Qe;return(Qe=(qe=se.types)==null?void 0:qe.map(Wt))!=null?Qe:[]})}function oe(J){var qe,Qe,Lt,tt,At,Ha,xr,za,Lc,ha,pr,ni;let se=J.name.value;switch(J.kind){case Ue.Kind.OBJECT_TYPE_DEFINITION:{let xt=(qe=a.get(se))!=null?qe:[],fr=[J,...xt];return a.delete(se),new Ue.GraphQLObjectType({name:se,description:(Qe=J.description)==null?void 0:Qe.value,interfaces:()=>$t(fr),fields:()=>dn(fr),astNode:J,extensionASTNodes:xt})}case Ue.Kind.INTERFACE_TYPE_DEFINITION:{let xt=(Lt=o.get(se))!=null?Lt:[],fr=[J,...xt];return o.delete(se),new Ue.GraphQLInterfaceType({name:se,description:(tt=J.description)==null?void 0:tt.value,interfaces:()=>$t(fr),fields:()=>dn(fr),astNode:J,extensionASTNodes:xt})}case Ue.Kind.ENUM_TYPE_DEFINITION:{let xt=(At=l.get(se))!=null?At:[],fr=[J,...xt];return l.delete(se),new Ue.GraphQLEnumType({name:se,description:(Ha=J.description)==null?void 0:Ha.value,values:Un(fr),astNode:J,extensionASTNodes:xt})}case Ue.Kind.UNION_TYPE_DEFINITION:{let xt=(xr=c.get(se))!=null?xr:[],fr=[J,...xt];return c.delete(se),new Ue.GraphQLUnionType({name:se,description:(za=J.description)==null?void 0:za.value,types:()=>bn(fr),astNode:J,extensionASTNodes:xt})}case Ue.Kind.SCALAR_TYPE_DEFINITION:{let xt=(Lc=i.get(se))!=null?Lc:[];return i.delete(se),new Ue.GraphQLScalarType({name:se,description:(ha=J.description)==null?void 0:ha.value,specifiedByURL:cC(J),astNode:J,extensionASTNodes:xt})}case Ue.Kind.INPUT_OBJECT_TYPE_DEFINITION:{let xt=(pr=p.get(se))!=null?pr:[],fr=[J,...xt];return p.delete(se),new Ue.GraphQLInputObjectType({name:se,description:(ni=J.description)==null?void 0:ni.value,fields:()=>Rr(fr),astNode:J,extensionASTNodes:xt})}}}}var uC=new Map([...Ue.specifiedScalarTypes,...Ue.introspectionTypes].map(e=>[e.name,e]));function wN(e){let t=(0,Ue.getDirectiveValues)(Ue.GraphQLDeprecatedDirective,e);return t==null?void 0:t.reason}function cC(e){let t=(0,Ue.getDirectiveValues)(Ue.GraphQLSpecifiedByDirective,e);return t==null?void 0:t.url}});var dv=w(lv=>{"use strict";m();T();N();Object.defineProperty(lv,"__esModule",{value:!0});lv.buildASTSchema=p9;var dC=Ae(),l9=ll(),d9=lC();function p9(e,t){(t==null?void 0:t.assumeValid)!==!0&&(t==null?void 0:t.assumeValidSDL)!==!0&&(0,l9.assertValidSDL)(e);let n={description:void 0,types:[],directives:[],extensions:Object.create(null),extensionASTNodes:[],assumeValid:!1},r=(0,d9.extendSchemaImpl)(n,e,t);if(r.astNode==null)for(let a of r.types)switch(a.name){case"Query":r.query=a;break;case"Mutation":r.mutation=a;break;case"Subscription":r.subscription=a;break}let i=[...r.directives,...dC.specifiedDirectives.filter(a=>r.directives.every(o=>o.name!==a.name))];return new dC.GraphQLSchema(Y(x({},r),{directives:i}))}});var Nl=w(su=>{"use strict";m();T();N();Object.defineProperty(su,"__esModule",{value:!0});su.MAX_INT32=su.MAX_SUBSCRIPTION_FILTER_DEPTH=su.MAXIMUM_TYPE_NESTING=void 0;su.MAXIMUM_TYPE_NESTING=30;su.MAX_SUBSCRIPTION_FILTER_DEPTH=5;su.MAX_INT32=nn(2,31)-1});var Jr=w(Nr=>{"use strict";m();T();N();Object.defineProperty(Nr,"__esModule",{value:!0});Nr.getOrThrowError=m9;Nr.getEntriesNotInHashSet=N9;Nr.numberToOrdinal=T9;Nr.addIterableValuesToSet=E9;Nr.addSets=h9;Nr.kindToNodeType=y9;Nr.getValueOrDefault=I9;Nr.add=g9;Nr.generateSimpleDirective=_9;Nr.generateRequiresScopesDirective=v9;Nr.copyObjectValueMap=S9;Nr.addNewObjectValueMapEntries=O9;Nr.copyArrayValueMap=D9;Nr.addMapEntries=b9;Nr.getSingleSetEntry=A9;var an=Ae(),_r=ur(),f9=ia(),pv=Yr();function m9(e,t,n){let r=e.get(t);if(r===void 0)throw(0,f9.invalidKeyFatalError)(t,n);return r}function N9(e,t){let n=[];for(let r of e)t.has(r)||n.push(r);return n}function T9(e){let t=e.toString();switch(t[t.length-1]){case"1":return`${t}st`;case"2":return`${t}nd`;case"3":return`${t}rd`;default:return`${t}th`}}function E9(e,t){for(let n of e)t.add(n)}function h9(e,t){let n=new Set(e);for(let r of t)n.add(r);return n}function y9(e){switch(e){case an.Kind.BOOLEAN:return _r.BOOLEAN_SCALAR;case an.Kind.ENUM:case an.Kind.ENUM_TYPE_DEFINITION:return _r.ENUM;case an.Kind.ENUM_TYPE_EXTENSION:return"Enum extension";case an.Kind.ENUM_VALUE_DEFINITION:return _r.ENUM_VALUE;case an.Kind.FIELD_DEFINITION:return _r.FIELD;case an.Kind.FLOAT:return _r.FLOAT_SCALAR;case an.Kind.INPUT_OBJECT_TYPE_DEFINITION:return _r.INPUT_OBJECT;case an.Kind.INPUT_OBJECT_TYPE_EXTENSION:return"Input Object extension";case an.Kind.INPUT_VALUE_DEFINITION:return _r.INPUT_VALUE;case an.Kind.INT:return _r.INT_SCALAR;case an.Kind.INTERFACE_TYPE_DEFINITION:return _r.INTERFACE;case an.Kind.INTERFACE_TYPE_EXTENSION:return"Interface extension";case an.Kind.NULL:return _r.NULL;case an.Kind.OBJECT:case an.Kind.OBJECT_TYPE_DEFINITION:return _r.OBJECT;case an.Kind.OBJECT_TYPE_EXTENSION:return"Object extension";case an.Kind.STRING:return _r.STRING_SCALAR;case an.Kind.SCALAR_TYPE_DEFINITION:return _r.SCALAR;case an.Kind.SCALAR_TYPE_EXTENSION:return"Scalar extension";case an.Kind.UNION_TYPE_DEFINITION:return _r.UNION;case an.Kind.UNION_TYPE_EXTENSION:return"Union extension";default:return e}}function I9(e,t,n){let r=e.get(t);if(r)return r;let i=n();return e.set(t,i),i}function g9(e,t){return e.has(t)?!1:(e.add(t),!0)}function _9(e){return{kind:an.Kind.DIRECTIVE,name:(0,pv.stringToNameNode)(e)}}function v9(e){let t=[];for(let n of e){let r=[];for(let i of n)r.push({kind:an.Kind.STRING,value:i});t.push({kind:an.Kind.LIST,values:r})}return{kind:an.Kind.DIRECTIVE,name:(0,pv.stringToNameNode)(_r.REQUIRES_SCOPES),arguments:[{kind:an.Kind.ARGUMENT,name:(0,pv.stringToNameNode)(_r.SCOPES),value:{kind:an.Kind.LIST,values:t}}]}}function S9(e){let t=new Map;for(let[n,r]of e)t.set(n,x({},r));return t}function O9(e,t){for(let[n,r]of e)t.set(n,x({},r))}function D9(e){let t=new Map;for(let[n,r]of e)t.set(n,[...r]);return t}function b9(e,t){for(let[n,r]of e)t.set(n,r)}function A9(e){let{value:t,done:n}=e.values().next();if(!n)return t}});var hp=w(LN=>{"use strict";m();T();N();Object.defineProperty(LN,"__esModule",{value:!0});LN.ExtensionType=void 0;var pC;(function(e){e[e.EXTENDS=0]="EXTENDS",e[e.NONE=1]="NONE",e[e.REAL=2]="REAL"})(pC||(LN.ExtensionType=pC={}))});var ou=w(Sr=>{"use strict";m();T();N();Object.defineProperty(Sr,"__esModule",{value:!0});Sr.getMutableDirectiveDefinitionNode=P9;Sr.getMutableEnumNode=F9;Sr.getMutableEnumValueNode=w9;Sr.getMutableFieldNode=L9;Sr.getMutableInputObjectNode=C9;Sr.getMutableInputValueNode=B9;Sr.getMutableInterfaceNode=U9;Sr.getMutableObjectNode=k9;Sr.getMutableObjectExtensionNode=M9;Sr.getMutableScalarNode=x9;Sr.getMutableTypeNode=fv;Sr.getMutableUnionNode=q9;Sr.getTypeNodeNamedTypeName=mv;Sr.getNamedTypeNode=mC;var vr=Ae(),Tl=Yr(),fC=ia(),R9=Nl();function P9(e){return{arguments:[],kind:e.kind,locations:[],name:x({},e.name),repeatable:e.repeatable,description:(0,Tl.formatDescription)(e.description)}}function F9(e){return{kind:vr.Kind.ENUM_TYPE_DEFINITION,name:x({},e)}}function w9(e){return{directives:[],kind:e.kind,name:x({},e.name),description:(0,Tl.formatDescription)(e.description)}}function L9(e,t,n){return{arguments:[],directives:[],kind:e.kind,name:x({},e.name),type:fv(e.type,t,n),description:(0,Tl.formatDescription)(e.description)}}function C9(e){return{kind:vr.Kind.INPUT_OBJECT_TYPE_DEFINITION,name:x({},e)}}function B9(e,t,n){return{directives:[],kind:e.kind,name:x({},e.name),type:fv(e.type,t,n),defaultValue:e.defaultValue,description:(0,Tl.formatDescription)(e.description)}}function U9(e){return{kind:vr.Kind.INTERFACE_TYPE_DEFINITION,name:x({},e)}}function k9(e){return{kind:vr.Kind.OBJECT_TYPE_DEFINITION,name:x({},e)}}function M9(e){let t=e.kind===vr.Kind.OBJECT_TYPE_DEFINITION?e.description:void 0;return{kind:vr.Kind.OBJECT_TYPE_EXTENSION,name:x({},e.name),description:(0,Tl.formatDescription)(t)}}function x9(e){return{kind:vr.Kind.SCALAR_TYPE_DEFINITION,name:x({},e)}}function fv(e,t,n){let r={kind:e.kind},i=r;for(let a=0;a{"use strict";m();T();N();Object.defineProperty(CN,"__esModule",{value:!0});CN.DEFAULT_CONSUMER_INACTIVE_THRESHOLD=void 0;CN.DEFAULT_CONSUMER_INACTIVE_THRESHOLD=30});var Es=w(ee=>{"use strict";m();T();N();Object.defineProperty(ee,"__esModule",{value:!0});ee.MAX_OR_SCOPES=ee.EDFS_ARGS_REGEXP=ee.CONFIGURE_CHILD_DESCRIPTIONS_DEFINITION=ee.CONFIGURE_DESCRIPTION_DEFINITION=ee.EDFS_NATS_STREAM_CONFIGURATION_DEFINITION=ee.SCOPE_SCALAR_DEFINITION=ee.FIELD_SET_SCALAR_DEFINITION=ee.VERSION_TWO_DIRECTIVE_DEFINITIONS=ee.EVENT_DRIVEN_DIRECTIVE_DEFINITIONS_BY_DIRECTIVE_NAME=ee.BASE_DIRECTIVE_DEFINITIONS=ee.V2_DIRECTIVE_DEFINITION_BY_DIRECTIVE_NAME=ee.SUBSCRIPTION_FIELD_CONDITION_DEFINITION=ee.SUBSCRIPTION_FILTER_VALUE_DEFINITION=ee.SUBSCRIPTION_FILTER_CONDITION_DEFINITION=ee.SUBSCRIPTION_FILTER_DEFINITION=ee.SHAREABLE_DEFINITION=ee.REQUIRES_SCOPES_DEFINITION=ee.OVERRIDE_DEFINITION=ee.LINK_DEFINITION=ee.LINK_PURPOSE_DEFINITION=ee.LINK_IMPORT_DEFINITION=ee.INTERFACE_OBJECT_DEFINITION=ee.INACCESSIBLE_DEFINITION=ee.COMPOSE_DIRECTIVE_DEFINITION=ee.AUTHENTICATED_DEFINITION=ee.ALL_IN_BUILT_DIRECTIVE_NAMES=ee.BASE_DIRECTIVE_DEFINITION_BY_DIRECTIVE_NAME=ee.EDFS_REDIS_SUBSCRIBE_DEFINITION=ee.EDFS_REDIS_PUBLISH_DEFINITION=ee.TAG_DEFINITION=ee.SPECIFIED_BY_DEFINITION=ee.REQUIRES_DEFINITION=ee.PROVIDES_DEFINITION=ee.KEY_DEFINITION=ee.REQUIRED_FIELDSET_TYPE_NODE=ee.EDFS_NATS_SUBSCRIBE_DEFINITION=ee.EDFS_NATS_REQUEST_DEFINITION=ee.EDFS_NATS_PUBLISH_DEFINITION=ee.EDFS_KAFKA_SUBSCRIBE_DEFINITION=ee.EDFS_KAFKA_PUBLISH_DEFINITION=ee.EXTERNAL_DEFINITION=ee.EXTENDS_DEFINITION=ee.DEPRECATED_DEFINITION=ee.BASE_SCALARS=ee.REQUIRED_STRING_TYPE_NODE=void 0;var ue=Ae(),ae=Yr(),V9=Nv(),k=ur();ee.REQUIRED_STRING_TYPE_NODE={kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(k.STRING_SCALAR)};ee.BASE_SCALARS=new Set(["_Any","_Entities",k.BOOLEAN_SCALAR,k.FLOAT_SCALAR,k.ID_SCALAR,k.INT_SCALAR,k.FIELD_SET_SCALAR,k.SCOPE_SCALAR,k.STRING_SCALAR]);ee.DEPRECATED_DEFINITION={arguments:[{directives:[],kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.REASON),type:(0,ae.stringToNamedTypeNode)(k.STRING_SCALAR),defaultValue:{kind:ue.Kind.STRING,value:ue.DEFAULT_DEPRECATION_REASON}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([k.ARGUMENT_DEFINITION_UPPER,k.ENUM_VALUE_UPPER,k.FIELD_DEFINITION_UPPER,k.INPUT_FIELD_DEFINITION_UPPER]),name:(0,ae.stringToNameNode)(k.DEPRECATED),repeatable:!1};ee.EXTENDS_DEFINITION={kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([k.INTERFACE_UPPER,k.OBJECT_UPPER]),name:(0,ae.stringToNameNode)(k.EXTENDS),repeatable:!1};ee.EXTERNAL_DEFINITION={kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([k.FIELD_DEFINITION_UPPER,k.OBJECT_UPPER]),name:(0,ae.stringToNameNode)(k.EXTERNAL),repeatable:!1};ee.EDFS_KAFKA_PUBLISH_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.TOPIC),type:ee.REQUIRED_STRING_TYPE_NODE},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.PROVIDER_ID),type:ee.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ue.Kind.STRING,value:k.DEFAULT_EDFS_PROVIDER_ID}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:[(0,ae.stringToNameNode)(k.FIELD_DEFINITION_UPPER)],name:(0,ae.stringToNameNode)(k.EDFS_KAFKA_PUBLISH),repeatable:!1};ee.EDFS_KAFKA_SUBSCRIBE_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.TOPICS),type:{kind:ue.Kind.NON_NULL_TYPE,type:{kind:ue.Kind.LIST_TYPE,type:ee.REQUIRED_STRING_TYPE_NODE}}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.PROVIDER_ID),type:ee.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ue.Kind.STRING,value:k.DEFAULT_EDFS_PROVIDER_ID}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:[(0,ae.stringToNameNode)(k.FIELD_DEFINITION_UPPER)],name:(0,ae.stringToNameNode)(k.EDFS_KAFKA_SUBSCRIBE),repeatable:!1};ee.EDFS_NATS_PUBLISH_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.SUBJECT),type:ee.REQUIRED_STRING_TYPE_NODE},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.PROVIDER_ID),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(k.STRING_SCALAR)},defaultValue:{kind:ue.Kind.STRING,value:k.DEFAULT_EDFS_PROVIDER_ID}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:[(0,ae.stringToNameNode)(k.FIELD_DEFINITION_UPPER)],name:(0,ae.stringToNameNode)(k.EDFS_NATS_PUBLISH),repeatable:!1};ee.EDFS_NATS_REQUEST_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.SUBJECT),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(k.STRING_SCALAR)}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.PROVIDER_ID),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(k.STRING_SCALAR)},defaultValue:{kind:ue.Kind.STRING,value:k.DEFAULT_EDFS_PROVIDER_ID}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:[(0,ae.stringToNameNode)(k.FIELD_DEFINITION_UPPER)],name:(0,ae.stringToNameNode)(k.EDFS_NATS_REQUEST),repeatable:!1};ee.EDFS_NATS_SUBSCRIBE_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.SUBJECTS),type:{kind:ue.Kind.NON_NULL_TYPE,type:{kind:ue.Kind.LIST_TYPE,type:ee.REQUIRED_STRING_TYPE_NODE}}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.PROVIDER_ID),type:ee.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ue.Kind.STRING,value:k.DEFAULT_EDFS_PROVIDER_ID}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.STREAM_CONFIGURATION),type:(0,ae.stringToNamedTypeNode)(k.EDFS_NATS_STREAM_CONFIGURATION)}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:[(0,ae.stringToNameNode)(k.FIELD_DEFINITION_UPPER)],name:(0,ae.stringToNameNode)(k.EDFS_NATS_SUBSCRIBE),repeatable:!1};ee.REQUIRED_FIELDSET_TYPE_NODE={kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(k.FIELD_SET_SCALAR)};ee.KEY_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.FIELDS),type:ee.REQUIRED_FIELDSET_TYPE_NODE},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.RESOLVABLE),type:(0,ae.stringToNamedTypeNode)(k.BOOLEAN_SCALAR),defaultValue:{kind:ue.Kind.BOOLEAN,value:!0}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([k.INTERFACE_UPPER,k.OBJECT_UPPER]),name:(0,ae.stringToNameNode)(k.KEY),repeatable:!0};ee.PROVIDES_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.FIELDS),type:ee.REQUIRED_FIELDSET_TYPE_NODE}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:[(0,ae.stringToNameNode)(k.FIELD_DEFINITION_UPPER)],name:(0,ae.stringToNameNode)(k.PROVIDES),repeatable:!1};ee.REQUIRES_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.FIELDS),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(k.FIELD_SET_SCALAR)}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:[(0,ae.stringToNameNode)(k.FIELD_DEFINITION_UPPER)],name:(0,ae.stringToNameNode)(k.REQUIRES),repeatable:!1};ee.SPECIFIED_BY_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.URL_LOWER),type:ee.REQUIRED_STRING_TYPE_NODE}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([k.SCALAR_UPPER]),name:(0,ae.stringToNameNode)(k.SPECIFIED_BY),repeatable:!1};ee.TAG_DEFINITION={arguments:[{directives:[],kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.NAME),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(k.STRING_SCALAR)}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([k.ARGUMENT_DEFINITION_UPPER,k.ENUM_UPPER,k.ENUM_VALUE_UPPER,k.FIELD_DEFINITION_UPPER,k.INPUT_FIELD_DEFINITION_UPPER,k.INPUT_OBJECT_UPPER,k.INTERFACE_UPPER,k.OBJECT_UPPER,k.SCALAR_UPPER,k.UNION_UPPER]),name:(0,ae.stringToNameNode)(k.TAG),repeatable:!0};ee.EDFS_REDIS_PUBLISH_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.CHANNEL),type:ee.REQUIRED_STRING_TYPE_NODE},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.PROVIDER_ID),type:ee.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ue.Kind.STRING,value:k.DEFAULT_EDFS_PROVIDER_ID}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:[(0,ae.stringToNameNode)(k.FIELD_DEFINITION_UPPER)],name:(0,ae.stringToNameNode)(k.EDFS_REDIS_PUBLISH),repeatable:!1};ee.EDFS_REDIS_SUBSCRIBE_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.CHANNELS),type:{kind:ue.Kind.NON_NULL_TYPE,type:{kind:ue.Kind.LIST_TYPE,type:ee.REQUIRED_STRING_TYPE_NODE}}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.PROVIDER_ID),type:ee.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ue.Kind.STRING,value:k.DEFAULT_EDFS_PROVIDER_ID}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:[(0,ae.stringToNameNode)(k.FIELD_DEFINITION_UPPER)],name:(0,ae.stringToNameNode)(k.EDFS_REDIS_SUBSCRIBE),repeatable:!1};ee.BASE_DIRECTIVE_DEFINITION_BY_DIRECTIVE_NAME=new Map([[k.DEPRECATED,ee.DEPRECATED_DEFINITION],[k.EXTENDS,ee.EXTENDS_DEFINITION],[k.EXTERNAL,ee.EXTERNAL_DEFINITION],[k.EDFS_KAFKA_PUBLISH,ee.EDFS_KAFKA_PUBLISH_DEFINITION],[k.EDFS_KAFKA_SUBSCRIBE,ee.EDFS_KAFKA_SUBSCRIBE_DEFINITION],[k.EDFS_NATS_PUBLISH,ee.EDFS_NATS_PUBLISH_DEFINITION],[k.EDFS_NATS_REQUEST,ee.EDFS_NATS_REQUEST_DEFINITION],[k.EDFS_NATS_SUBSCRIBE,ee.EDFS_NATS_SUBSCRIBE_DEFINITION],[k.EDFS_REDIS_PUBLISH,ee.EDFS_REDIS_PUBLISH_DEFINITION],[k.EDFS_REDIS_SUBSCRIBE,ee.EDFS_REDIS_SUBSCRIBE_DEFINITION],[k.KEY,ee.KEY_DEFINITION],[k.PROVIDES,ee.PROVIDES_DEFINITION],[k.REQUIRES,ee.REQUIRES_DEFINITION],[k.SPECIFIED_BY,ee.SPECIFIED_BY_DEFINITION],[k.TAG,ee.TAG_DEFINITION]]);ee.ALL_IN_BUILT_DIRECTIVE_NAMES=new Set([k.AUTHENTICATED,k.COMPOSE_DIRECTIVE,k.CONFIGURE_DESCRIPTION,k.CONFIGURE_CHILD_DESCRIPTIONS,k.DEPRECATED,k.EDFS_NATS_PUBLISH,k.EDFS_NATS_REQUEST,k.EDFS_NATS_SUBSCRIBE,k.EDFS_KAFKA_PUBLISH,k.EDFS_KAFKA_SUBSCRIBE,k.EDFS_REDIS_PUBLISH,k.EDFS_REDIS_SUBSCRIBE,k.EXTENDS,k.EXTERNAL,k.INACCESSIBLE,k.INTERFACE_OBJECT,k.KEY,k.LINK,k.OVERRIDE,k.PROVIDES,k.REQUIRES,k.REQUIRES_SCOPES,k.SHAREABLE,k.SPECIFIED_BY,k.SUBSCRIPTION_FILTER,k.TAG]);ee.AUTHENTICATED_DEFINITION={arguments:[],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([k.ENUM_UPPER,k.FIELD_DEFINITION_UPPER,k.INTERFACE_UPPER,k.OBJECT_UPPER,k.SCALAR_UPPER]),name:(0,ae.stringToNameNode)(k.AUTHENTICATED),repeatable:!1};ee.COMPOSE_DIRECTIVE_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.NAME),type:ee.REQUIRED_STRING_TYPE_NODE}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([k.SCHEMA_UPPER]),name:(0,ae.stringToNameNode)(k.COMPOSE_DIRECTIVE),repeatable:!0};ee.INACCESSIBLE_DEFINITION={arguments:[],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([k.ARGUMENT_DEFINITION_UPPER,k.ENUM_UPPER,k.ENUM_VALUE_UPPER,k.FIELD_DEFINITION_UPPER,k.INPUT_FIELD_DEFINITION_UPPER,k.INPUT_OBJECT_UPPER,k.INTERFACE_UPPER,k.OBJECT_UPPER,k.SCALAR_UPPER,k.UNION_UPPER]),name:(0,ae.stringToNameNode)(k.INACCESSIBLE),repeatable:!1};ee.INTERFACE_OBJECT_DEFINITION={kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([k.OBJECT_UPPER]),name:(0,ae.stringToNameNode)(k.INTERFACE_OBJECT),repeatable:!1};ee.LINK_IMPORT_DEFINITION={kind:ue.Kind.SCALAR_TYPE_DEFINITION,name:(0,ae.stringToNameNode)(k.LINK_IMPORT)};ee.LINK_PURPOSE_DEFINITION={kind:ue.Kind.ENUM_TYPE_DEFINITION,name:(0,ae.stringToNameNode)(k.LINK_PURPOSE),values:[{directives:[],kind:ue.Kind.ENUM_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.EXECUTION)},{directives:[],kind:ue.Kind.ENUM_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.SECURITY)}]};ee.LINK_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.URL_LOWER),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(k.STRING_SCALAR)}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.AS),type:(0,ae.stringToNamedTypeNode)(k.STRING_SCALAR)},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.FOR),type:(0,ae.stringToNamedTypeNode)(k.LINK_PURPOSE)},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.IMPORT),type:{kind:ue.Kind.LIST_TYPE,type:(0,ae.stringToNamedTypeNode)(k.LINK_IMPORT)}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([k.SCHEMA_UPPER]),name:(0,ae.stringToNameNode)(k.LINK),repeatable:!0};ee.OVERRIDE_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.FROM),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(k.STRING_SCALAR)}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([k.FIELD_DEFINITION_UPPER]),name:(0,ae.stringToNameNode)(k.OVERRIDE),repeatable:!1};ee.REQUIRES_SCOPES_DEFINITION={arguments:[{directives:[],kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.SCOPES),type:{kind:ue.Kind.NON_NULL_TYPE,type:{kind:ue.Kind.LIST_TYPE,type:{kind:ue.Kind.NON_NULL_TYPE,type:{kind:ue.Kind.LIST_TYPE,type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(k.SCOPE_SCALAR)}}}}}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([k.ENUM_UPPER,k.FIELD_DEFINITION_UPPER,k.INTERFACE_UPPER,k.OBJECT_UPPER,k.SCALAR_UPPER]),name:(0,ae.stringToNameNode)(k.REQUIRES_SCOPES),repeatable:!1};ee.SHAREABLE_DEFINITION={kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([k.FIELD_DEFINITION_UPPER,k.OBJECT_UPPER]),name:(0,ae.stringToNameNode)(k.SHAREABLE),repeatable:!0};ee.SUBSCRIPTION_FILTER_DEFINITION={arguments:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.CONDITION),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(k.SUBSCRIPTION_FILTER_CONDITION)}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([k.FIELD_DEFINITION_UPPER]),name:(0,ae.stringToNameNode)(k.SUBSCRIPTION_FILTER),repeatable:!1};ee.SUBSCRIPTION_FILTER_CONDITION_DEFINITION={fields:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.AND_UPPER),type:{kind:ue.Kind.LIST_TYPE,type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(k.SUBSCRIPTION_FILTER_CONDITION)}}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.IN_UPPER),type:(0,ae.stringToNamedTypeNode)(k.SUBSCRIPTION_FIELD_CONDITION)},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.OR_UPPER),type:{kind:ue.Kind.LIST_TYPE,type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(k.SUBSCRIPTION_FILTER_CONDITION)}}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.NOT_UPPER),type:(0,ae.stringToNamedTypeNode)(k.SUBSCRIPTION_FILTER_CONDITION)}],kind:ue.Kind.INPUT_OBJECT_TYPE_DEFINITION,name:(0,ae.stringToNameNode)(k.SUBSCRIPTION_FILTER_CONDITION)};ee.SUBSCRIPTION_FILTER_VALUE_DEFINITION={kind:ue.Kind.SCALAR_TYPE_DEFINITION,name:(0,ae.stringToNameNode)(k.SUBSCRIPTION_FILTER_VALUE)};ee.SUBSCRIPTION_FIELD_CONDITION_DEFINITION={fields:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.FIELD_PATH),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(k.STRING_SCALAR)}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.VALUES),type:{kind:ue.Kind.NON_NULL_TYPE,type:{kind:ue.Kind.LIST_TYPE,type:(0,ae.stringToNamedTypeNode)(k.SUBSCRIPTION_FILTER_VALUE)}}}],kind:ue.Kind.INPUT_OBJECT_TYPE_DEFINITION,name:(0,ae.stringToNameNode)(k.SUBSCRIPTION_FIELD_CONDITION)};ee.V2_DIRECTIVE_DEFINITION_BY_DIRECTIVE_NAME=new Map([[k.AUTHENTICATED,ee.AUTHENTICATED_DEFINITION],[k.COMPOSE_DIRECTIVE,ee.COMPOSE_DIRECTIVE_DEFINITION],[k.INACCESSIBLE,ee.INACCESSIBLE_DEFINITION],[k.INTERFACE_OBJECT,ee.INTERFACE_OBJECT_DEFINITION],[k.LINK,ee.LINK_DEFINITION],[k.OVERRIDE,ee.OVERRIDE_DEFINITION],[k.REQUIRES_SCOPES,ee.REQUIRES_SCOPES_DEFINITION],[k.SHAREABLE,ee.SHAREABLE_DEFINITION]]);ee.BASE_DIRECTIVE_DEFINITIONS=[ee.DEPRECATED_DEFINITION,ee.EXTENDS_DEFINITION,ee.EXTERNAL_DEFINITION,ee.KEY_DEFINITION,ee.PROVIDES_DEFINITION,ee.REQUIRES_DEFINITION,ee.SPECIFIED_BY_DEFINITION,ee.TAG_DEFINITION];ee.EVENT_DRIVEN_DIRECTIVE_DEFINITIONS_BY_DIRECTIVE_NAME=new Map([[k.EDFS_KAFKA_PUBLISH,ee.EDFS_KAFKA_PUBLISH_DEFINITION],[k.EDFS_KAFKA_SUBSCRIBE,ee.EDFS_KAFKA_SUBSCRIBE_DEFINITION],[k.EDFS_NATS_PUBLISH,ee.EDFS_NATS_PUBLISH_DEFINITION],[k.EDFS_NATS_REQUEST,ee.EDFS_NATS_REQUEST_DEFINITION],[k.EDFS_NATS_SUBSCRIBE,ee.EDFS_NATS_SUBSCRIBE_DEFINITION],[k.EDFS_REDIS_PUBLISH,ee.EDFS_REDIS_PUBLISH_DEFINITION],[k.EDFS_REDIS_SUBSCRIBE,ee.EDFS_REDIS_SUBSCRIBE_DEFINITION]]);ee.VERSION_TWO_DIRECTIVE_DEFINITIONS=[ee.AUTHENTICATED_DEFINITION,ee.COMPOSE_DIRECTIVE_DEFINITION,ee.INACCESSIBLE_DEFINITION,ee.INTERFACE_OBJECT_DEFINITION,ee.OVERRIDE_DEFINITION,ee.REQUIRES_SCOPES_DEFINITION,ee.SHAREABLE_DEFINITION];ee.FIELD_SET_SCALAR_DEFINITION={kind:ue.Kind.SCALAR_TYPE_DEFINITION,name:(0,ae.stringToNameNode)(k.FIELD_SET_SCALAR)};ee.SCOPE_SCALAR_DEFINITION={kind:ue.Kind.SCALAR_TYPE_DEFINITION,name:(0,ae.stringToNameNode)(k.SCOPE_SCALAR)};ee.EDFS_NATS_STREAM_CONFIGURATION_DEFINITION={kind:ue.Kind.INPUT_OBJECT_TYPE_DEFINITION,name:(0,ae.stringToNameNode)(k.EDFS_NATS_STREAM_CONFIGURATION),fields:[{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.CONSUMER_NAME),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(k.STRING_SCALAR)}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.STREAM_NAME),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(k.STRING_SCALAR)}},{kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.CONSUMER_INACTIVE_THRESHOLD),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(k.INT_SCALAR)},defaultValue:{kind:ue.Kind.INT,value:V9.DEFAULT_CONSUMER_INACTIVE_THRESHOLD.toString()}}]};ee.CONFIGURE_DESCRIPTION_DEFINITION={arguments:[{directives:[],kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.PROPAGATE),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(k.BOOLEAN_SCALAR)},defaultValue:{kind:ue.Kind.BOOLEAN,value:!0}},{directives:[],kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.DESCRIPTION_OVERRIDE),type:(0,ae.stringToNamedTypeNode)(k.STRING_SCALAR)}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([k.ARGUMENT_DEFINITION_UPPER,k.ENUM_UPPER,k.ENUM_VALUE_UPPER,k.FIELD_DEFINITION_UPPER,k.INTERFACE_UPPER,k.INPUT_OBJECT_UPPER,k.INPUT_FIELD_DEFINITION_UPPER,k.OBJECT_UPPER,k.SCALAR_UPPER,k.SCHEMA_UPPER,k.UNION_UPPER]),name:(0,ae.stringToNameNode)(k.CONFIGURE_DESCRIPTION),repeatable:!1};ee.CONFIGURE_CHILD_DESCRIPTIONS_DEFINITION={arguments:[{directives:[],kind:ue.Kind.INPUT_VALUE_DEFINITION,name:(0,ae.stringToNameNode)(k.PROPAGATE),type:{kind:ue.Kind.NON_NULL_TYPE,type:(0,ae.stringToNamedTypeNode)(k.BOOLEAN_SCALAR)},defaultValue:{kind:ue.Kind.BOOLEAN,value:!0}}],kind:ue.Kind.DIRECTIVE_DEFINITION,locations:(0,ae.stringArrayToNameNodeArray)([k.ENUM_UPPER,k.INPUT_OBJECT_UPPER,k.INTERFACE_UPPER,k.OBJECT_UPPER]),name:(0,ae.stringToNameNode)(k.CONFIGURE_CHILD_DESCRIPTIONS),repeatable:!1};ee.EDFS_ARGS_REGEXP=/{{\s*args\.([a-zA-Z0-9_]+)\s*}}/g;ee.MAX_OR_SCOPES=16});var BN=w(nc=>{"use strict";m();T();N();Object.defineProperty(nc,"__esModule",{value:!0});nc.newParentTagData=$9;nc.newChildTagData=Q9;nc.validateImplicitFieldSets=Y9;nc.newContractTagOptionsFromArrays=J9;nc.getDescriptionFromString=H9;var Hr=Ae(),j9=ou(),K9=Es(),G9=Yr(),NC=Jr();function $9(e){return{childTagDataByChildName:new Map,tagNames:new Set,typeName:e}}function Q9(e){return{name:e,tagNames:new Set,tagNamesByArgumentName:new Map}}function Y9({conditionalFieldDataByCoords:e,currentSubgraphName:t,entityData:n,implicitKeys:r,objectData:i,parentDefinitionDataByTypeName:a,graphNode:o}){let c=(0,NC.getValueOrDefault)(n.keyFieldSetDatasBySubgraphName,t,()=>new Map);for(let[l,p]of n.documentNodeByKeyFieldSet){if(c.has(l))continue;let f=[i],y=[],g=[],v=-1,P=!0,U=!0;(0,Hr.visit)(p,{Argument:{enter(){return U=!1,Hr.BREAK}},Field:{enter(K){let $=f[v];if(P)return U=!1,Hr.BREAK;let ne=K.name.value,z=$.fieldDataByName.get(ne);if(!z||z.argumentDataByName.size||y[v].has(ne))return U=!1,Hr.BREAK;let{isUnconditionallyProvided:Te}=(0,NC.getOrThrowError)(z.externalFieldDataBySubgraphName,t,`${z.originalParentTypeName}.${ne}.externalFieldDataBySubgraphName`),pe=e.get(`${z.renamedParentTypeName}.${ne}`);if(pe){if(pe.providedBy.length>0)g.push(...pe.providedBy);else if(pe.requiredBy.length>0)return U=!1,Hr.BREAK}else if(!Te)return U=!1,Hr.BREAK;y[v].add(ne);let Fe=(0,j9.getTypeNodeNamedTypeName)(z.node.type);if(K9.BASE_SCALARS.has(Fe))return;let xe=a.get(Fe);if(!xe)return U=!1,Hr.BREAK;if(xe.kind===Hr.Kind.OBJECT_TYPE_DEFINITION){P=!0,f.push(xe);return}if((0,G9.isKindAbstract)(xe.kind))return U=!1,Hr.BREAK}},InlineFragment:{enter(){return U=!1,Hr.BREAK}},SelectionSet:{enter(){if(!P||(v+=1,P=!1,v<0||v>=f.length))return U=!1,Hr.BREAK;y.push(new Set)},leave(){if(P)return U=!1,Hr.BREAK;v-=1,f.pop(),y.pop()}}}),U&&(r.push(Y(x({fieldName:"",selectionSet:l},g.length>0?{conditions:g}:{}),{disableEntityResolver:!0})),o&&o.satisfiedFieldSets.add(l))}}function J9(e,t){return{tagNamesToExclude:new Set(e),tagNamesToInclude:new Set(t)}}function H9(e){if(e)return{block:!0,kind:Hr.Kind.STRING,value:e}}});var hl=w(mt=>{"use strict";m();T();N();Object.defineProperty(mt,"__esModule",{value:!0});mt.MergeMethod=void 0;mt.newPersistedDirectivesData=W9;mt.isNodeExternalOrShareable=X9;mt.isTypeRequired=Z9;mt.areDefaultValuesCompatible=EC;mt.compareAndValidateInputValueDefaultValues=e7;mt.setMutualExecutableLocations=t7;mt.isTypeNameRootType=n7;mt.getRenamedRootTypeName=r7;mt.childMapToValueArray=a7;mt.setLongestDescription=s7;mt.isParentDataRootType=hC;mt.isParentDataInterfaceType=o7;mt.setParentDataExtensionType=u7;mt.extractPersistedDirectives=d7;mt.propagateAuthDirectives=p7;mt.propagateFieldAuthDirectives=f7;mt.generateDeprecatedDirective=yv;mt.getClientPersistedDirectiveNodes=Ev;mt.getNodeForRouterSchemaByData=N7;mt.getClientSchemaFieldNodeByFieldData=T7;mt.getNodeWithPersistedDirectivesByInputValueData=IC;mt.addValidPersistedDirectiveDefinitionNodeByData=h7;mt.newInvalidFieldNames=y7;mt.validateExternalAndShareable=I7;mt.isTypeValidImplementation=UN;mt.isNodeDataInaccessible=gC;mt.isLeafKind=g7;mt.getSubscriptionFilterValue=_7;mt.getParentTypeName=v7;mt.newConditionalFieldData=S7;mt.getDefinitionDataCoords=O7;mt.isParentDataCompositeOutputType=D7;mt.newExternalFieldData=b7;mt.getInitialFederatedDescription=A7;mt.areKindsEqual=R7;mt.isFieldData=_C;mt.isInputNodeKind=P7;mt.isOutputNodeKind=F7;var st=Ae(),Tv=hp(),El=Yr(),hv=ia(),kt=ur(),yp=Jr(),z9=BN();function W9(){return{deprecatedReason:"",directivesByDirectiveName:new Map,isDeprecated:!1,tagDirectiveByName:new Map}}function X9(e,t,n){var i;let r={isExternal:n.has(kt.EXTERNAL),isShareable:t||n.has(kt.SHAREABLE)};if(!((i=e.directives)!=null&&i.length))return r;for(let a of e.directives){let o=a.name.value;if(o===kt.EXTERNAL){r.isExternal=!0;continue}o===kt.SHAREABLE&&(r.isShareable=!0)}return r}function Z9(e){return e.kind===st.Kind.NON_NULL_TYPE}function EC(e,t){switch(e.kind){case st.Kind.LIST_TYPE:return t.kind===st.Kind.LIST||t.kind===st.Kind.NULL;case st.Kind.NAMED_TYPE:if(t.kind===st.Kind.NULL)return!0;switch(e.name.value){case kt.BOOLEAN_SCALAR:return t.kind===st.Kind.BOOLEAN;case kt.FLOAT_SCALAR:return t.kind===st.Kind.INT||t.kind===st.Kind.FLOAT;case kt.INT_SCALAR:return t.kind===st.Kind.INT;case kt.STRING_SCALAR:return t.kind===st.Kind.STRING;default:return!0}case st.Kind.NON_NULL_TYPE:return t.kind===st.Kind.NULL?!1:EC(e.type,t)}}function e7(e,t,n){if(!e.defaultValue)return;if(!t.defaultValue){e.includeDefaultValue=!1;return}let r=(0,st.print)(e.defaultValue),i=(0,st.print)(t.defaultValue);if(r!==i){n.push((0,hv.incompatibleInputValueDefaultValuesError)(`${e.isArgument?kt.ARGUMENT:kt.INPUT_FIELD} "${e.name}"`,e.originalCoords,[...t.subgraphNames],r,i));return}}function t7(e,t){let n=new Set;for(let r of t)e.executableLocations.has(r)&&n.add(r);e.executableLocations=n}function n7(e,t){return kt.ROOT_TYPE_NAMES.has(e)||t.has(e)}function r7(e,t){let n=t.get(e);if(!n)return e;switch(n){case st.OperationTypeNode.MUTATION:return kt.MUTATION;case st.OperationTypeNode.SUBSCRIPTION:return kt.SUBSCRIPTION;default:return kt.QUERY}}function i7(e){for(let t of e.argumentDataByName.values()){for(let n of t.directivesByDirectiveName.values())t.node.directives.push(...n);e.node.arguments.push(t.node)}}function a7(e){let t=[];for(let n of e.values()){_C(n)&&i7(n);for(let r of n.directivesByDirectiveName.values())n.node.directives.push(...r);t.push(n.node)}return t}function s7(e,t){if(t.description){if("configureDescriptionDataBySubgraphName"in t){for(let{propagate:n}of t.configureDescriptionDataBySubgraphName.values())if(!n)return}(!e.description||e.description.value.length0&&e.persistedDirectivesData.directivesByDirectiveName.set(kt.REQUIRES_SCOPES,[(0,yp.generateRequiresScopesDirective)(t.requiredScopes)]))}function f7(e,t){if(!t)return;let n=t.fieldAuthDataByFieldName.get(e.name);n&&(n.originalData.requiresAuthentication&&e.persistedDirectivesData.directivesByDirectiveName.set(kt.AUTHENTICATED,[(0,yp.generateSimpleDirective)(kt.AUTHENTICATED)]),n.originalData.requiredScopes.length>0&&e.persistedDirectivesData.directivesByDirectiveName.set(kt.REQUIRES_SCOPES,[(0,yp.generateRequiresScopesDirective)(n.originalData.requiredScopes)]))}function yv(e){return{kind:st.Kind.DIRECTIVE,name:(0,El.stringToNameNode)(kt.DEPRECATED),arguments:[{kind:st.Kind.ARGUMENT,name:(0,El.stringToNameNode)(kt.REASON),value:{kind:st.Kind.STRING,value:e||kt.DEPRECATED_DEFAULT_ARGUMENT_VALUE}}]}}function m7(e,t,n,r){let i=[];for(let[a,o]of e){let c=t.get(a);if(c){if(o.length<2){i.push(...o);continue}if(!c.repeatable){r.push((0,hv.invalidRepeatedFederatedDirectiveErrorMessage)(a,n));continue}i.push(...o)}}return i}function yC(e,t,n){let r=[...e.persistedDirectivesData.tagDirectiveByName.values()];return e.persistedDirectivesData.isDeprecated&&r.push(yv(e.persistedDirectivesData.deprecatedReason)),r.push(...m7(e.persistedDirectivesData.directivesByDirectiveName,t,e.name,n)),r}function Ev(e){let t=[];e.persistedDirectivesData.isDeprecated&&t.push(yv(e.persistedDirectivesData.deprecatedReason));for(let[n,r]of e.persistedDirectivesData.directivesByDirectiveName)kt.PERSISTED_CLIENT_DIRECTIVES.has(n)&&t.push(r[0]);return t}function N7(e,t,n){return e.node.name=(0,El.stringToNameNode)(e.name),e.node.description=e.description,e.node.directives=yC(e,t,n),e.node}function T7(e){let t=Ev(e),n=[];for(let r of e.argumentDataByName.values())gC(r)||n.push(Y(x({},r.node),{directives:Ev(r)}));return Y(x({},e.node),{directives:t,arguments:n})}function IC(e,t,n){return e.node.name=(0,El.stringToNameNode)(e.name),e.node.type=e.type,e.node.description=e.description,e.node.directives=yC(e,t,n),e.includeDefaultValue&&(e.node.defaultValue=e.defaultValue),e.node}function E7(e,t,n,r,i){let a=[];for(let[o,c]of t.argumentDataByArgumentName){let l=(0,yp.getEntriesNotInHashSet)(t.subgraphNames,c.subgraphNames);if(l.length>0){c.requiredSubgraphNames.size>0&&a.push({inputValueName:o,missingSubgraphs:l,requiredSubgraphs:[...c.requiredSubgraphNames]});continue}e.push(IC(c,n,r)),i&&i.add(o)}return a.length>0?(r.push((0,hv.invalidRequiredInputValueError)(kt.DIRECTIVE_DEFINITION,`@${t.name}`,a)),!1):!0}function h7(e,t,n,r){let i=[];E7(i,t,n,r)&&e.push({arguments:i,kind:st.Kind.DIRECTIVE_DEFINITION,locations:(0,El.setToNameNodeArray)(t.executableLocations),name:(0,El.stringToNameNode)(t.name),repeatable:t.repeatable,description:t.description})}function y7(){return{byShareable:new Set,subgraphNamesByExternalFieldName:new Map}}function I7(e,t){let n=e.isShareableBySubgraphName.size,r=new Array,i=0;for(let[a,o]of e.isShareableBySubgraphName){let c=e.externalFieldDataBySubgraphName.get(a);if(c&&!c.isUnconditionallyProvided){r.push(a);continue}o||(i+=1)}switch(i){case 0:n===r.length&&t.subgraphNamesByExternalFieldName.set(e.name,r);return;case 1:if(n===1)return;n-r.length!==1&&t.byShareable.add(e.name);return;default:t.byShareable.add(e.name)}}var TC;(function(e){e[e.UNION=0]="UNION",e[e.INTERSECTION=1]="INTERSECTION",e[e.CONSISTENT=2]="CONSISTENT"})(TC||(mt.MergeMethod=TC={}));function UN(e,t,n){if(e.kind===st.Kind.NON_NULL_TYPE)return t.kind!==st.Kind.NON_NULL_TYPE?!1:UN(e.type,t.type,n);if(t.kind===st.Kind.NON_NULL_TYPE)return UN(e,t.type,n);switch(e.kind){case st.Kind.NAMED_TYPE:if(t.kind===st.Kind.NAMED_TYPE){let r=e.name.value,i=t.name.value;if(r===i)return!0;let a=n.get(r);return a?a.has(i):!1}return!1;default:return t.kind===st.Kind.LIST_TYPE?UN(e.type,t.type,n):!1}}function gC(e){return e.persistedDirectivesData.directivesByDirectiveName.has(kt.INACCESSIBLE)||e.directivesByDirectiveName.has(kt.INACCESSIBLE)}function g7(e){return e===st.Kind.SCALAR_TYPE_DEFINITION||e===st.Kind.ENUM_TYPE_DEFINITION}function _7(e){switch(e.kind){case st.Kind.BOOLEAN:return e.value;case st.Kind.ENUM:case st.Kind.STRING:return e.value;case st.Kind.FLOAT:case st.Kind.INT:try{return parseFloat(e.value)}catch(t){return"NaN"}case st.Kind.NULL:return null}}function v7(e){return e.kind===st.Kind.OBJECT_TYPE_DEFINITION&&e.renamedTypeName||e.name}function S7(){return{providedBy:[],requiredBy:[]}}function O7(e,t){switch(e.kind){case st.Kind.ENUM_VALUE_DEFINITION:return`${e.parentTypeName}.${e.name}`;case st.Kind.FIELD_DEFINITION:return`${t?e.renamedParentTypeName:e.originalParentTypeName}.${e.name}`;case st.Kind.ARGUMENT:case st.Kind.INPUT_VALUE_DEFINITION:return t?e.federatedCoords:e.originalCoords;case st.Kind.OBJECT_TYPE_DEFINITION:return t?e.renamedTypeName:e.name;default:return e.name}}function D7(e){return e.kind===st.Kind.OBJECT_TYPE_DEFINITION||e.kind===st.Kind.INTERFACE_TYPE_DEFINITION}function b7(e){return{isDefinedExternal:e,isUnconditionallyProvided:!e}}function A7(e){let{value:t,done:n}=e.configureDescriptionDataBySubgraphName.values().next();if(n)return e.description;if(t.propagate)return(0,z9.getDescriptionFromString)(t.description)||e.description}function R7(e,t){return e.kind===t.kind}function _C(e){return e.kind===st.Kind.FIELD_DEFINITION}function P7(e){return kt.INPUT_NODE_KINDS.has(e)}function F7(e){return kt.OUTPUT_NODE_KINDS.has(e)}});var _v={};sm(_v,{__addDisposableResource:()=>KC,__assign:()=>kN,__asyncDelegator:()=>BC,__asyncGenerator:()=>CC,__asyncValues:()=>UC,__await:()=>yl,__awaiter:()=>AC,__classPrivateFieldGet:()=>qC,__classPrivateFieldIn:()=>jC,__classPrivateFieldSet:()=>VC,__createBinding:()=>xN,__decorate:()=>OC,__disposeResources:()=>GC,__esDecorate:()=>w7,__exportStar:()=>PC,__extends:()=>vC,__generator:()=>RC,__importDefault:()=>xC,__importStar:()=>MC,__makeTemplateObject:()=>kC,__metadata:()=>bC,__param:()=>DC,__propKey:()=>C7,__read:()=>gv,__rest:()=>SC,__runInitializers:()=>L7,__setFunctionName:()=>B7,__spread:()=>FC,__spreadArray:()=>LC,__spreadArrays:()=>wC,__values:()=>MN,default:()=>M7});function vC(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");Iv(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}function SC(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i=0;c--)(o=e[c])&&(a=(i<3?o(a):i>3?o(t,n,a):o(t,n))||a);return i>3&&a&&Object.defineProperty(t,n,a),a}function DC(e,t){return function(n,r){t(n,r,e)}}function w7(e,t,n,r,i,a){function o($){if($!==void 0&&typeof $!="function")throw new TypeError("Function expected");return $}for(var c=r.kind,l=c==="getter"?"get":c==="setter"?"set":"value",p=!t&&e?r.static?e:e.prototype:null,f=t||(p?Object.getOwnPropertyDescriptor(p,r.name):{}),y,g=!1,v=n.length-1;v>=0;v--){var P={};for(var U in r)P[U]=U==="access"?{}:r[U];for(var U in r.access)P.access[U]=r.access[U];P.addInitializer=function($){if(g)throw new TypeError("Cannot add initializers after decoration has completed");a.push(o($||null))};var K=(0,n[v])(c==="accessor"?{get:f.get,set:f.set}:f[l],P);if(c==="accessor"){if(K===void 0)continue;if(K===null||typeof K!="object")throw new TypeError("Object expected");(y=o(K.get))&&(f.get=y),(y=o(K.set))&&(f.set=y),(y=o(K.init))&&i.unshift(y)}else(y=o(K))&&(c==="field"?i.unshift(y):f[l]=y)}p&&Object.defineProperty(p,r.name,f),g=!0}function L7(e,t,n){for(var r=arguments.length>2,i=0;i0&&a[a.length-1])&&(p[0]===6||p[0]===2)){n=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function gv(e,t){var n=typeof Symbol=="function"&&e[Symbol.iterator];if(!n)return e;var r=n.call(e),i,a=[],o;try{for(;(t===void 0||t-- >0)&&!(i=r.next()).done;)a.push(i.value)}catch(c){o={error:c}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(o)throw o.error}}return a}function FC(){for(var e=[],t=0;t1||c(g,v)})})}function c(g,v){try{l(r[g](v))}catch(P){y(a[0][3],P)}}function l(g){g.value instanceof yl?Promise.resolve(g.value.v).then(p,f):y(a[0][2],g)}function p(g){c("next",g)}function f(g){c("throw",g)}function y(g,v){g(v),a.shift(),a.length&&c(a[0][0],a[0][1])}}function BC(e){var t,n;return t={},r("next"),r("throw",function(i){throw i}),r("return"),t[Symbol.iterator]=function(){return this},t;function r(i,a){t[i]=e[i]?function(o){return(n=!n)?{value:yl(e[i](o)),done:!1}:a?a(o):o}:a}}function UC(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],n;return t?t.call(e):(e=typeof MN=="function"?MN(e):e[Symbol.iterator](),n={},r("next"),r("throw"),r("return"),n[Symbol.asyncIterator]=function(){return this},n);function r(a){n[a]=e[a]&&function(o){return new Promise(function(c,l){o=e[a](o),i(c,l,o.done,o.value)})}}function i(a,o,c,l){Promise.resolve(l).then(function(p){a({value:p,done:c})},o)}}function kC(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}function MC(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var n in e)n!=="default"&&Object.prototype.hasOwnProperty.call(e,n)&&xN(t,e,n);return U7(t,e),t}function xC(e){return e&&e.__esModule?e:{default:e}}function qC(e,t,n,r){if(n==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof t=="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return n==="m"?r:n==="a"?r.call(e):r?r.value:t.get(e)}function VC(e,t,n,r,i){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t=="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?i.call(e,n):i?i.value=n:t.set(e,n),n}function jC(e,t){if(t===null||typeof t!="object"&&typeof t!="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof e=="function"?t===e:e.has(t)}function KC(e,t,n){if(t!=null){if(typeof t!="object"&&typeof t!="function")throw new TypeError("Object expected.");var r;if(n){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose]}if(r===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose]}if(typeof r!="function")throw new TypeError("Object not disposable.");e.stack.push({value:t,dispose:r,async:n})}else n&&e.stack.push({async:!0});return t}function GC(e){function t(r){e.error=e.hasError?new k7(r,e.error,"An error was suppressed during disposal."):r,e.hasError=!0}function n(){for(;e.stack.length;){var r=e.stack.pop();try{var i=r.dispose&&r.dispose.call(r.value);if(r.async)return Promise.resolve(i).then(n,function(a){return t(a),n()})}catch(a){t(a)}}if(e.hasError)throw e.error}return n()}var Iv,kN,xN,U7,k7,M7,vv=Lu(()=>{"use strict";m();T();N();Iv=function(e,t){return Iv=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i])},Iv(e,t)};kN=function(){return kN=Object.assign||function(t){for(var n,r=1,i=arguments.length;rdB,__assign:()=>qN,__asyncDelegator:()=>rB,__asyncGenerator:()=>nB,__asyncValues:()=>iB,__await:()=>Il,__awaiter:()=>zC,__classPrivateFieldGet:()=>uB,__classPrivateFieldIn:()=>lB,__classPrivateFieldSet:()=>cB,__createBinding:()=>jN,__decorate:()=>YC,__disposeResources:()=>pB,__esDecorate:()=>x7,__exportStar:()=>XC,__extends:()=>$C,__generator:()=>WC,__importDefault:()=>oB,__importStar:()=>sB,__makeTemplateObject:()=>aB,__metadata:()=>HC,__param:()=>JC,__propKey:()=>V7,__read:()=>Ov,__rest:()=>QC,__runInitializers:()=>q7,__setFunctionName:()=>j7,__spread:()=>ZC,__spreadArray:()=>tB,__spreadArrays:()=>eB,__values:()=>VN,default:()=>$7});function $C(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");Sv(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}function QC(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i=0;c--)(o=e[c])&&(a=(i<3?o(a):i>3?o(t,n,a):o(t,n))||a);return i>3&&a&&Object.defineProperty(t,n,a),a}function JC(e,t){return function(n,r){t(n,r,e)}}function x7(e,t,n,r,i,a){function o($){if($!==void 0&&typeof $!="function")throw new TypeError("Function expected");return $}for(var c=r.kind,l=c==="getter"?"get":c==="setter"?"set":"value",p=!t&&e?r.static?e:e.prototype:null,f=t||(p?Object.getOwnPropertyDescriptor(p,r.name):{}),y,g=!1,v=n.length-1;v>=0;v--){var P={};for(var U in r)P[U]=U==="access"?{}:r[U];for(var U in r.access)P.access[U]=r.access[U];P.addInitializer=function($){if(g)throw new TypeError("Cannot add initializers after decoration has completed");a.push(o($||null))};var K=(0,n[v])(c==="accessor"?{get:f.get,set:f.set}:f[l],P);if(c==="accessor"){if(K===void 0)continue;if(K===null||typeof K!="object")throw new TypeError("Object expected");(y=o(K.get))&&(f.get=y),(y=o(K.set))&&(f.set=y),(y=o(K.init))&&i.unshift(y)}else(y=o(K))&&(c==="field"?i.unshift(y):f[l]=y)}p&&Object.defineProperty(p,r.name,f),g=!0}function q7(e,t,n){for(var r=arguments.length>2,i=0;i0&&a[a.length-1])&&(p[0]===6||p[0]===2)){n=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function Ov(e,t){var n=typeof Symbol=="function"&&e[Symbol.iterator];if(!n)return e;var r=n.call(e),i,a=[],o;try{for(;(t===void 0||t-- >0)&&!(i=r.next()).done;)a.push(i.value)}catch(c){o={error:c}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(o)throw o.error}}return a}function ZC(){for(var e=[],t=0;t1||c(g,v)})})}function c(g,v){try{l(r[g](v))}catch(P){y(a[0][3],P)}}function l(g){g.value instanceof Il?Promise.resolve(g.value.v).then(p,f):y(a[0][2],g)}function p(g){c("next",g)}function f(g){c("throw",g)}function y(g,v){g(v),a.shift(),a.length&&c(a[0][0],a[0][1])}}function rB(e){var t,n;return t={},r("next"),r("throw",function(i){throw i}),r("return"),t[Symbol.iterator]=function(){return this},t;function r(i,a){t[i]=e[i]?function(o){return(n=!n)?{value:Il(e[i](o)),done:!1}:a?a(o):o}:a}}function iB(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],n;return t?t.call(e):(e=typeof VN=="function"?VN(e):e[Symbol.iterator](),n={},r("next"),r("throw"),r("return"),n[Symbol.asyncIterator]=function(){return this},n);function r(a){n[a]=e[a]&&function(o){return new Promise(function(c,l){o=e[a](o),i(c,l,o.done,o.value)})}}function i(a,o,c,l){Promise.resolve(l).then(function(p){a({value:p,done:c})},o)}}function aB(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}function sB(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var n in e)n!=="default"&&Object.prototype.hasOwnProperty.call(e,n)&&jN(t,e,n);return K7(t,e),t}function oB(e){return e&&e.__esModule?e:{default:e}}function uB(e,t,n,r){if(n==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof t=="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return n==="m"?r:n==="a"?r.call(e):r?r.value:t.get(e)}function cB(e,t,n,r,i){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t=="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?i.call(e,n):i?i.value=n:t.set(e,n),n}function lB(e,t){if(t===null||typeof t!="object"&&typeof t!="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof e=="function"?t===e:e.has(t)}function dB(e,t,n){if(t!=null){if(typeof t!="object"&&typeof t!="function")throw new TypeError("Object expected.");var r;if(n){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose]}if(r===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose]}if(typeof r!="function")throw new TypeError("Object not disposable.");e.stack.push({value:t,dispose:r,async:n})}else n&&e.stack.push({async:!0});return t}function pB(e){function t(r){e.error=e.hasError?new G7(r,e.error,"An error was suppressed during disposal."):r,e.hasError=!0}function n(){for(;e.stack.length;){var r=e.stack.pop();try{var i=r.dispose&&r.dispose.call(r.value);if(r.async)return Promise.resolve(i).then(n,function(a){return t(a),n()})}catch(a){t(a)}}if(e.hasError)throw e.error}return n()}var Sv,qN,jN,K7,G7,$7,mB=Lu(()=>{"use strict";m();T();N();Sv=function(e,t){return Sv=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i])},Sv(e,t)};qN=function(){return qN=Object.assign||function(t){for(var n,r=1,i=arguments.length;r{"use strict";m();T();N()});var Ip=w(cr=>{"use strict";m();T();N();Object.defineProperty(cr,"__esModule",{value:!0});cr.assertSome=cr.isSome=cr.compareNodes=cr.nodeToString=cr.compareStrings=cr.isValidPath=cr.isDocumentString=cr.asArray=void 0;var Q7=Ae(),Y7=e=>Array.isArray(e)?e:e?[e]:[];cr.asArray=Y7;var J7=/\.[a-z0-9]+$/i;function H7(e){if(typeof e!="string"||J7.test(e))return!1;try{return(0,Q7.parse)(e),!0}catch(t){}return!1}cr.isDocumentString=H7;var z7=/[‘“!%^<>`]/;function W7(e){return typeof e=="string"&&!z7.test(e)}cr.isValidPath=W7;function TB(e,t){return String(e)String(t)?1:0}cr.compareStrings=TB;function Dv(e){var n,r;let t;return"alias"in e&&(t=(n=e.alias)==null?void 0:n.value),t==null&&"name"in e&&(t=(r=e.name)==null?void 0:r.value),t==null&&(t=e.kind),t}cr.nodeToString=Dv;function X7(e,t,n){let r=Dv(e),i=Dv(t);return typeof n=="function"?n(r,i):TB(r,i)}cr.compareNodes=X7;function Z7(e){return e!=null}cr.isSome=Z7;function eZ(e,t="Value should be something"){if(e==null)throw new Error(t)}cr.assertSome=eZ});var gp=w(GN=>{"use strict";m();T();N();Object.defineProperty(GN,"__esModule",{value:!0});GN.inspect=void 0;var yB=3;function tZ(e){return KN(e,[])}GN.inspect=tZ;function KN(e,t){switch(typeof e){case"string":return JSON.stringify(e);case"function":return e.name?`[function ${e.name}]`:"[function]";case"object":return nZ(e,t);default:return String(e)}}function EB(e){return(e.name="GraphQLError")?e.toString():`${e.name}: ${e.message}; ${e.stack}`}function nZ(e,t){if(e===null)return"null";if(e instanceof Error)return e.name==="AggregateError"?EB(e)+` -`+hB(e.errors,t):EB(e);if(t.includes(e))return"[Circular]";let n=[...t,e];if(rZ(e)){let r=e.toJSON();if(r!==e)return typeof r=="string"?r:KN(r,n)}else if(Array.isArray(e))return hB(e,n);return iZ(e,n)}function rZ(e){return typeof e.toJSON=="function"}function iZ(e,t){let n=Object.entries(e);return n.length===0?"{}":t.length>yB?"["+aZ(e)+"]":"{ "+n.map(([i,a])=>i+": "+KN(a,t)).join(", ")+" }"}function hB(e,t){if(e.length===0)return"[]";if(t.length>yB)return"[Array]";let n=e.length,r=[];for(let i=0;i{"use strict";m();T();N();Object.defineProperty(gl,"__esModule",{value:!0});gl.relocatedError=gl.createGraphQLError=void 0;var bv=Ae(),sZ=["message","locations","path","nodes","source","positions","originalError","name","stack","extensions"];function oZ(e){return e!=null&&typeof e=="object"&&Object.keys(e).every(t=>sZ.includes(t))}function Av(e,t){return t!=null&&t.originalError&&!(t.originalError instanceof Error)&&oZ(t.originalError)&&(t.originalError=Av(t.originalError.message,t.originalError)),bv.versionInfo.major>=17?new bv.GraphQLError(e,t):new bv.GraphQLError(e,t==null?void 0:t.nodes,t==null?void 0:t.source,t==null?void 0:t.positions,t==null?void 0:t.path,t==null?void 0:t.originalError,t==null?void 0:t.extensions)}gl.createGraphQLError=Av;function uZ(e,t){return Av(e.message,{nodes:e.nodes,source:e.source,positions:e.positions,path:t==null?e.path:t,originalError:e,extensions:e.extensions})}gl.relocatedError=uZ});var _p=w(Bi=>{"use strict";m();T();N();Object.defineProperty(Bi,"__esModule",{value:!0});Bi.hasOwnProperty=Bi.promiseReduce=Bi.isPromise=Bi.isObjectLike=Bi.isIterableObject=void 0;function cZ(e){return e!=null&&typeof e=="object"&&Symbol.iterator in e}Bi.isIterableObject=cZ;function lZ(e){return typeof e=="object"&&e!==null}Bi.isObjectLike=lZ;function IB(e){return(e==null?void 0:e.then)!=null}Bi.isPromise=IB;function dZ(e,t,n){let r=n;for(let i of e)r=IB(r)?r.then(a=>t(a,i)):t(r,i);return r}Bi.promiseReduce=dZ;function pZ(e,t){return Object.prototype.hasOwnProperty.call(e,t)}Bi.hasOwnProperty=pZ});var Pv=w(YN=>{"use strict";m();T();N();Object.defineProperty(YN,"__esModule",{value:!0});YN.getArgumentValues=void 0;var Rv=gp(),rc=Ae(),QN=$N(),fZ=_p();function mZ(e,t,n={}){var o;let r={},a=((o=t.arguments)!=null?o:[]).reduce((c,l)=>Y(x({},c),{[l.name.value]:l}),{});for(let{name:c,type:l,defaultValue:p}of e.args){let f=a[c];if(!f){if(p!==void 0)r[c]=p;else if((0,rc.isNonNullType)(l))throw(0,QN.createGraphQLError)(`Argument "${c}" of required type "${(0,Rv.inspect)(l)}" was not provided.`,{nodes:[t]});continue}let y=f.value,g=y.kind===rc.Kind.NULL;if(y.kind===rc.Kind.VARIABLE){let F=y.name.value;if(n==null||!(0,fZ.hasOwnProperty)(n,F)){if(p!==void 0)r[c]=p;else if((0,rc.isNonNullType)(l))throw(0,QN.createGraphQLError)(`Argument "${c}" of required type "${(0,Rv.inspect)(l)}" was provided the variable "$${F}" which was not provided a runtime value.`,{nodes:[y]});continue}g=n[F]==null}if(g&&(0,rc.isNonNullType)(l))throw(0,QN.createGraphQLError)(`Argument "${c}" of non-null type "${(0,Rv.inspect)(l)}" must not be null.`,{nodes:[y]});let v=(0,rc.valueFromAST)(y,l,n);if(v===void 0)throw(0,QN.createGraphQLError)(`Argument "${c}" has invalid value ${(0,rc.print)(y)}.`,{nodes:[y]});r[c]=v}return r}YN.getArgumentValues=mZ});var Fv=w(Ba=>{"use strict";m();T();N();Object.defineProperty(Ba,"__esModule",{value:!0});Ba.getDirective=Ba.getDirectives=Ba.getDirectiveInExtensions=Ba.getDirectivesInExtensions=void 0;var _B=Pv();function vB(e,t=["directives"]){return t.reduce((n,r)=>n==null?n:n[r],e==null?void 0:e.extensions)}Ba.getDirectivesInExtensions=vB;function gB(e,t){let n=e.filter(r=>r.name===t);if(n.length)return n.map(r=>{var i;return(i=r.args)!=null?i:{}})}function SB(e,t,n=["directives"]){let r=n.reduce((a,o)=>a==null?a:a[o],e==null?void 0:e.extensions);if(r===void 0)return;if(Array.isArray(r))return gB(r,t);let i=[];for(let[a,o]of Object.entries(r))if(Array.isArray(o))for(let c of o)i.push({name:a,args:c});else i.push({name:a,args:o});return gB(i,t)}Ba.getDirectiveInExtensions=SB;function NZ(e,t,n=["directives"]){let r=vB(t,n);if(r!=null&&r.length>0)return r;let a=(e&&e.getDirectives?e.getDirectives():[]).reduce((l,p)=>(l[p.name]=p,l),{}),o=[];t.astNode&&o.push(t.astNode),"extensionASTNodes"in t&&t.extensionASTNodes&&(o=[...o,...t.extensionASTNodes]);let c=[];for(let l of o)if(l.directives)for(let p of l.directives){let f=a[p.name.value];f&&c.push({name:p.name.value,args:(0,_B.getArgumentValues)(f,p)})}return c}Ba.getDirectives=NZ;function TZ(e,t,n,r=["directives"]){let i=SB(t,n,r);if(i!=null)return i;let a=e&&e.getDirective?e.getDirective(n):void 0;if(a==null)return;let o=[];t.astNode&&o.push(t.astNode),"extensionASTNodes"in t&&t.extensionASTNodes&&(o=[...o,...t.extensionASTNodes]);let c=[];for(let l of o)if(l.directives)for(let p of l.directives)p.name.value===n&&c.push((0,_B.getArgumentValues)(a,p));if(c.length)return c}Ba.getDirective=TZ});var wv=w(JN=>{"use strict";m();T();N();Object.defineProperty(JN,"__esModule",{value:!0});JN.getFieldsWithDirectives=void 0;var EZ=Ae();function hZ(e,t={}){let n={},r=["ObjectTypeDefinition","ObjectTypeExtension"];t.includeInputTypes&&(r=[...r,"InputObjectTypeDefinition","InputObjectTypeExtension"]);let i=e.definitions.filter(a=>r.includes(a.kind));for(let a of i){let o=a.name.value;if(a.fields!=null){for(let c of a.fields)if(c.directives&&c.directives.length>0){let l=c.name.value,p=`${o}.${l}`,f=c.directives.map(y=>({name:y.name.value,args:(y.arguments||[]).reduce((g,v)=>Y(x({},g),{[v.name.value]:(0,EZ.valueFromASTUntyped)(v.value)}),{})}));n[p]=f}}}return n}JN.getFieldsWithDirectives=hZ});var OB=w(HN=>{"use strict";m();T();N();Object.defineProperty(HN,"__esModule",{value:!0});HN.getArgumentsWithDirectives=void 0;var Lv=Ae();function yZ(e){return e.kind===Lv.Kind.OBJECT_TYPE_DEFINITION||e.kind===Lv.Kind.OBJECT_TYPE_EXTENSION}function IZ(e){var r;let t={},n=e.definitions.filter(yZ);for(let i of n)if(i.fields!=null)for(let a of i.fields){let o=(r=a.arguments)==null?void 0:r.filter(l=>{var p;return(p=l.directives)==null?void 0:p.length});if(!(o!=null&&o.length))continue;let c=t[`${i.name.value}.${a.name.value}`]={};for(let l of o){let p=l.directives.map(f=>({name:f.name.value,args:(f.arguments||[]).reduce((y,g)=>Y(x({},y),{[g.name.value]:(0,Lv.valueFromASTUntyped)(g.value)}),{})}));c[l.name.value]=p}}return t}HN.getArgumentsWithDirectives=IZ});var Cv=w(zN=>{"use strict";m();T();N();Object.defineProperty(zN,"__esModule",{value:!0});zN.getImplementingTypes=void 0;var gZ=Ae();function _Z(e,t){let n=t.getTypeMap(),r=[];for(let i in n){let a=n[i];(0,gZ.isObjectType)(a)&&a.getInterfaces().find(c=>c.name===e)&&r.push(a.name)}return r}zN.getImplementingTypes=_Z});var Uv=w(WN=>{"use strict";m();T();N();Object.defineProperty(WN,"__esModule",{value:!0});WN.astFromType=void 0;var vZ=gp(),ic=Ae();function Bv(e){if((0,ic.isNonNullType)(e)){let t=Bv(e.ofType);if(t.kind===ic.Kind.NON_NULL_TYPE)throw new Error(`Invalid type node ${(0,vZ.inspect)(e)}. Inner type of non-null type cannot be a non-null type.`);return{kind:ic.Kind.NON_NULL_TYPE,type:t}}else if((0,ic.isListType)(e))return{kind:ic.Kind.LIST_TYPE,type:Bv(e.ofType)};return{kind:ic.Kind.NAMED_TYPE,name:{kind:ic.Kind.NAME,value:e.name}}}WN.astFromType=Bv});var ZN=w(XN=>{"use strict";m();T();N();Object.defineProperty(XN,"__esModule",{value:!0});XN.astFromValueUntyped=void 0;var Ua=Ae();function kv(e){if(e===null)return{kind:Ua.Kind.NULL};if(e===void 0)return null;if(Array.isArray(e)){let t=[];for(let n of e){let r=kv(n);r!=null&&t.push(r)}return{kind:Ua.Kind.LIST,values:t}}if(typeof e=="object"){let t=[];for(let n in e){let r=e[n],i=kv(r);i&&t.push({kind:Ua.Kind.OBJECT_FIELD,name:{kind:Ua.Kind.NAME,value:n},value:i})}return{kind:Ua.Kind.OBJECT,fields:t}}if(typeof e=="boolean")return{kind:Ua.Kind.BOOLEAN,value:e};if(typeof e=="bigint")return{kind:Ua.Kind.INT,value:String(e)};if(typeof e=="number"&&isFinite(e)){let t=String(e);return SZ.test(t)?{kind:Ua.Kind.INT,value:t}:{kind:Ua.Kind.FLOAT,value:t}}if(typeof e=="string")return{kind:Ua.Kind.STRING,value:e};throw new TypeError(`Cannot convert value to AST: ${e}.`)}XN.astFromValueUntyped=kv;var SZ=/^-?(?:0|[1-9][0-9]*)$/});var bB=w(eT=>{"use strict";m();T();N();Object.defineProperty(eT,"__esModule",{value:!0});eT.astFromValue=void 0;var OZ=gp(),pi=Ae(),DZ=ZN(),DB=_p();function vp(e,t){if((0,pi.isNonNullType)(t)){let n=vp(e,t.ofType);return(n==null?void 0:n.kind)===pi.Kind.NULL?null:n}if(e===null)return{kind:pi.Kind.NULL};if(e===void 0)return null;if((0,pi.isListType)(t)){let n=t.ofType;if((0,DB.isIterableObject)(e)){let r=[];for(let i of e){let a=vp(i,n);a!=null&&r.push(a)}return{kind:pi.Kind.LIST,values:r}}return vp(e,n)}if((0,pi.isInputObjectType)(t)){if(!(0,DB.isObjectLike)(e))return null;let n=[];for(let r of Object.values(t.getFields())){let i=vp(e[r.name],r.type);i&&n.push({kind:pi.Kind.OBJECT_FIELD,name:{kind:pi.Kind.NAME,value:r.name},value:i})}return{kind:pi.Kind.OBJECT,fields:n}}if((0,pi.isLeafType)(t)){let n=t.serialize(e);return n==null?null:(0,pi.isEnumType)(t)?{kind:pi.Kind.ENUM,value:n}:t.name==="ID"&&typeof n=="string"&&bZ.test(n)?{kind:pi.Kind.INT,value:n}:(0,DZ.astFromValueUntyped)(n)}console.assert(!1,"Unexpected input type: "+(0,OZ.inspect)(t))}eT.astFromValue=vp;var bZ=/^-?(?:0|[1-9][0-9]*)$/});var AB=w(tT=>{"use strict";m();T();N();Object.defineProperty(tT,"__esModule",{value:!0});tT.getDescriptionNode=void 0;var AZ=Ae();function RZ(e){var t;if((t=e.astNode)!=null&&t.description)return Y(x({},e.astNode.description),{block:!0});if(e.description)return{kind:AZ.Kind.STRING,value:e.description,block:!0}}tT.getDescriptionNode=RZ});var _l=w(Or=>{"use strict";m();T();N();Object.defineProperty(Or,"__esModule",{value:!0});Or.memoize2of5=Or.memoize2of4=Or.memoize5=Or.memoize4=Or.memoize3=Or.memoize2=Or.memoize1=void 0;function PZ(e){let t=new WeakMap;return function(r){let i=t.get(r);if(i===void 0){let a=e(r);return t.set(r,a),a}return i}}Or.memoize1=PZ;function FZ(e){let t=new WeakMap;return function(r,i){let a=t.get(r);if(!a){a=new WeakMap,t.set(r,a);let c=e(r,i);return a.set(i,c),c}let o=a.get(i);if(o===void 0){let c=e(r,i);return a.set(i,c),c}return o}}Or.memoize2=FZ;function wZ(e){let t=new WeakMap;return function(r,i,a){let o=t.get(r);if(!o){o=new WeakMap,t.set(r,o);let p=new WeakMap;o.set(i,p);let f=e(r,i,a);return p.set(a,f),f}let c=o.get(i);if(!c){c=new WeakMap,o.set(i,c);let p=e(r,i,a);return c.set(a,p),p}let l=c.get(a);if(l===void 0){let p=e(r,i,a);return c.set(a,p),p}return l}}Or.memoize3=wZ;function LZ(e){let t=new WeakMap;return function(r,i,a,o){let c=t.get(r);if(!c){c=new WeakMap,t.set(r,c);let y=new WeakMap;c.set(i,y);let g=new WeakMap;y.set(a,g);let v=e(r,i,a,o);return g.set(o,v),v}let l=c.get(i);if(!l){l=new WeakMap,c.set(i,l);let y=new WeakMap;l.set(a,y);let g=e(r,i,a,o);return y.set(o,g),g}let p=l.get(a);if(!p){let y=new WeakMap;l.set(a,y);let g=e(r,i,a,o);return y.set(o,g),g}let f=p.get(o);if(f===void 0){let y=e(r,i,a,o);return p.set(o,y),y}return f}}Or.memoize4=LZ;function CZ(e){let t=new WeakMap;return function(r,i,a,o,c){let l=t.get(r);if(!l){l=new WeakMap,t.set(r,l);let v=new WeakMap;l.set(i,v);let F=new WeakMap;v.set(a,F);let k=new WeakMap;F.set(o,k);let K=e(r,i,a,o,c);return k.set(c,K),K}let p=l.get(i);if(!p){p=new WeakMap,l.set(i,p);let v=new WeakMap;p.set(a,v);let F=new WeakMap;v.set(o,F);let k=e(r,i,a,o,c);return F.set(c,k),k}let f=p.get(a);if(!f){f=new WeakMap,p.set(a,f);let v=new WeakMap;f.set(o,v);let F=e(r,i,a,o,c);return v.set(c,F),F}let y=f.get(o);if(!y){y=new WeakMap,f.set(o,y);let v=e(r,i,a,o,c);return y.set(c,v),v}let g=y.get(c);if(g===void 0){let v=e(r,i,a,o,c);return y.set(c,v),v}return g}}Or.memoize5=CZ;function BZ(e){let t=new WeakMap;return function(r,i,a,o){let c=t.get(r);if(!c){c=new WeakMap,t.set(r,c);let p=e(r,i,a,o);return c.set(i,p),p}let l=c.get(i);if(l===void 0){let p=e(r,i,a,o);return c.set(i,p),p}return l}}Or.memoize2of4=BZ;function UZ(e){let t=new WeakMap;return function(r,i,a,o,c){let l=t.get(r);if(!l){l=new WeakMap,t.set(r,l);let f=e(r,i,a,o,c);return l.set(i,f),f}let p=l.get(i);if(p===void 0){let f=e(r,i,a,o,c);return l.set(i,f),f}return p}}Or.memoize2of5=UZ});var Sp=w(fi=>{"use strict";m();T();N();Object.defineProperty(fi,"__esModule",{value:!0});fi.getRootTypeMap=fi.getRootTypes=fi.getRootTypeNames=fi.getDefinedRootType=void 0;var kZ=$N(),Mv=_l();function MZ(e,t,n){let i=(0,fi.getRootTypeMap)(e).get(t);if(i==null)throw(0,kZ.createGraphQLError)(`Schema is not configured to execute ${t} operation.`,{nodes:n});return i}fi.getDefinedRootType=MZ;fi.getRootTypeNames=(0,Mv.memoize1)(function(t){let n=(0,fi.getRootTypes)(t);return new Set([...n].map(r=>r.name))});fi.getRootTypes=(0,Mv.memoize1)(function(t){let n=(0,fi.getRootTypeMap)(t);return new Set(n.values())});fi.getRootTypeMap=(0,Mv.memoize1)(function(t){let n=new Map,r=t.getQueryType();r&&n.set("query",r);let i=t.getMutationType();i&&n.set("mutation",i);let a=t.getSubscriptionType();return a&&n.set("subscription",a),n})});var Kv=w(ht=>{"use strict";m();T();N();Object.defineProperty(ht,"__esModule",{value:!0});ht.makeDirectiveNodes=ht.makeDirectiveNode=ht.makeDeprecatedDirective=ht.astFromEnumValue=ht.astFromInputField=ht.astFromField=ht.astFromScalarType=ht.astFromEnumType=ht.astFromInputObjectType=ht.astFromUnionType=ht.astFromInterfaceType=ht.astFromObjectType=ht.astFromArg=ht.getDeprecatableDirectiveNodes=ht.getDirectiveNodes=ht.astFromDirective=ht.astFromSchema=ht.printSchemaWithDirectives=ht.getDocumentNodeFromSchema=void 0;var ut=Ae(),ac=Uv(),xv=bB(),xZ=ZN(),Ui=AB(),qv=Fv(),qZ=Ip(),VZ=Sp();function RB(e,t={}){let n=t.pathToDirectivesInExtensions,r=e.getTypeMap(),i=PB(e,n),a=i!=null?[i]:[],o=e.getDirectives();for(let c of o)(0,ut.isSpecifiedDirective)(c)||a.push(FB(c,e,n));for(let c in r){let l=r[c],p=(0,ut.isSpecifiedScalarType)(l),f=(0,ut.isIntrospectionType)(l);if(!(p||f))if((0,ut.isObjectType)(l))a.push(wB(l,e,n));else if((0,ut.isInterfaceType)(l))a.push(LB(l,e,n));else if((0,ut.isUnionType)(l))a.push(CB(l,e,n));else if((0,ut.isInputObjectType)(l))a.push(BB(l,e,n));else if((0,ut.isEnumType)(l))a.push(UB(l,e,n));else if((0,ut.isScalarType)(l))a.push(kB(l,e,n));else throw new Error(`Unknown type ${l}.`)}return{kind:ut.Kind.DOCUMENT,definitions:a}}ht.getDocumentNodeFromSchema=RB;function jZ(e,t={}){let n=RB(e,t);return(0,ut.print)(n)}ht.printSchemaWithDirectives=jZ;function PB(e,t){let n=new Map([["query",void 0],["mutation",void 0],["subscription",void 0]]),r=[];if(e.astNode!=null&&r.push(e.astNode),e.extensionASTNodes!=null)for(let p of e.extensionASTNodes)r.push(p);for(let p of r)if(p.operationTypes)for(let f of p.operationTypes)n.set(f.operation,f);let i=(0,VZ.getRootTypeMap)(e);for(let[p,f]of n){let y=i.get(p);if(y!=null){let g=(0,ac.astFromType)(y);f!=null?f.type=g:n.set(p,{kind:ut.Kind.OPERATION_TYPE_DEFINITION,operation:p,type:g})}}let a=[...n.values()].filter(qZ.isSome),o=sc(e,e,t);if(!a.length&&!o.length)return null;let c={kind:a!=null?ut.Kind.SCHEMA_DEFINITION:ut.Kind.SCHEMA_EXTENSION,operationTypes:a,directives:o},l=(0,Ui.getDescriptionNode)(e);return l&&(c.description=l),c}ht.astFromSchema=PB;function FB(e,t,n){var r,i;return{kind:ut.Kind.DIRECTIVE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},arguments:(r=e.args)==null?void 0:r.map(a=>Vv(a,t,n)),repeatable:e.isRepeatable,locations:((i=e.locations)==null?void 0:i.map(a=>({kind:ut.Kind.NAME,value:a})))||[]}}ht.astFromDirective=FB;function sc(e,t,n){let r=(0,qv.getDirectivesInExtensions)(e,n),i=[];e.astNode!=null&&i.push(e.astNode),"extensionASTNodes"in e&&e.extensionASTNodes!=null&&(i=i.concat(e.extensionASTNodes));let a;if(r!=null)a=nT(t,r);else{a=[];for(let o of i)o.directives&&a.push(...o.directives)}return a}ht.getDirectiveNodes=sc;function Dp(e,t,n){var c,l;let r=[],i=null,a=(0,qv.getDirectivesInExtensions)(e,n),o;return a!=null?o=nT(t,a):o=(c=e.astNode)==null?void 0:c.directives,o!=null&&(r=o.filter(p=>p.name.value!=="deprecated"),e.deprecationReason!=null&&(i=(l=o.filter(p=>p.name.value==="deprecated"))==null?void 0:l[0])),e.deprecationReason!=null&&i==null&&(i=qB(e.deprecationReason)),i==null?r:[i].concat(r)}ht.getDeprecatableDirectiveNodes=Dp;function Vv(e,t,n){var r;return{kind:ut.Kind.INPUT_VALUE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},type:(0,ac.astFromType)(e.type),defaultValue:e.defaultValue!==void 0&&(r=(0,xv.astFromValue)(e.defaultValue,e.type))!=null?r:void 0,directives:Dp(e,t,n)}}ht.astFromArg=Vv;function wB(e,t,n){return{kind:ut.Kind.OBJECT_TYPE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},fields:Object.values(e.getFields()).map(r=>jv(r,t,n)),interfaces:Object.values(e.getInterfaces()).map(r=>(0,ac.astFromType)(r)),directives:sc(e,t,n)}}ht.astFromObjectType=wB;function LB(e,t,n){let r={kind:ut.Kind.INTERFACE_TYPE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},fields:Object.values(e.getFields()).map(i=>jv(i,t,n)),directives:sc(e,t,n)};return"getInterfaces"in e&&(r.interfaces=Object.values(e.getInterfaces()).map(i=>(0,ac.astFromType)(i))),r}ht.astFromInterfaceType=LB;function CB(e,t,n){return{kind:ut.Kind.UNION_TYPE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},directives:sc(e,t,n),types:e.getTypes().map(r=>(0,ac.astFromType)(r))}}ht.astFromUnionType=CB;function BB(e,t,n){return{kind:ut.Kind.INPUT_OBJECT_TYPE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},fields:Object.values(e.getFields()).map(r=>MB(r,t,n)),directives:sc(e,t,n)}}ht.astFromInputObjectType=BB;function UB(e,t,n){return{kind:ut.Kind.ENUM_TYPE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},values:Object.values(e.getValues()).map(r=>xB(r,t,n)),directives:sc(e,t,n)}}ht.astFromEnumType=UB;function kB(e,t,n){var o;let r=(0,qv.getDirectivesInExtensions)(e,n),i=r?nT(t,r):((o=e.astNode)==null?void 0:o.directives)||[],a=e.specifiedByUrl||e.specifiedByURL;if(a&&!i.some(c=>c.name.value==="specifiedBy")){let c={url:a};i.push(Op("specifiedBy",c))}return{kind:ut.Kind.SCALAR_TYPE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},directives:i}}ht.astFromScalarType=kB;function jv(e,t,n){return{kind:ut.Kind.FIELD_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},arguments:e.args.map(r=>Vv(r,t,n)),type:(0,ac.astFromType)(e.type),directives:Dp(e,t,n)}}ht.astFromField=jv;function MB(e,t,n){var r;return{kind:ut.Kind.INPUT_VALUE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},type:(0,ac.astFromType)(e.type),directives:Dp(e,t,n),defaultValue:(r=(0,xv.astFromValue)(e.defaultValue,e.type))!=null?r:void 0}}ht.astFromInputField=MB;function xB(e,t,n){return{kind:ut.Kind.ENUM_VALUE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},directives:Dp(e,t,n)}}ht.astFromEnumValue=xB;function qB(e){return Op("deprecated",{reason:e},ut.GraphQLDeprecatedDirective)}ht.makeDeprecatedDirective=qB;function Op(e,t,n){let r=[];if(n!=null)for(let i of n.args){let a=i.name,o=t[a];if(o!==void 0){let c=(0,xv.astFromValue)(o,i.type);c&&r.push({kind:ut.Kind.ARGUMENT,name:{kind:ut.Kind.NAME,value:a},value:c})}}else for(let i in t){let a=t[i],o=(0,xZ.astFromValueUntyped)(a);o&&r.push({kind:ut.Kind.ARGUMENT,name:{kind:ut.Kind.NAME,value:i},value:o})}return{kind:ut.Kind.DIRECTIVE,name:{kind:ut.Kind.NAME,value:e},arguments:r}}ht.makeDirectiveNode=Op;function nT(e,t){let n=[];for(let r in t){let i=t[r],a=e==null?void 0:e.getDirective(r);if(Array.isArray(i))for(let o of i)n.push(Op(r,o,a));else n.push(Op(r,i,a))}return n}ht.makeDirectiveNodes=nT});var jB=w(vl=>{"use strict";m();T();N();Object.defineProperty(vl,"__esModule",{value:!0});vl.createDefaultRules=vl.validateGraphQlDocuments=void 0;var bp=Ae();function KZ(e,t,n=VB()){var c;let r=new Set,i=new Map;for(let l of t)for(let p of l.definitions)p.kind===bp.Kind.FRAGMENT_DEFINITION?i.set(p.name.value,p):r.add(p);let a={kind:bp.Kind.DOCUMENT,definitions:Array.from([...r,...i.values()])},o=(0,bp.validate)(e,a,n);for(let l of o)if(l.stack=l.message,l.locations)for(let p of l.locations)l.stack+=` +`+hB(e.errors,t):EB(e);if(t.includes(e))return"[Circular]";let n=[...t,e];if(rZ(e)){let r=e.toJSON();if(r!==e)return typeof r=="string"?r:KN(r,n)}else if(Array.isArray(e))return hB(e,n);return iZ(e,n)}function rZ(e){return typeof e.toJSON=="function"}function iZ(e,t){let n=Object.entries(e);return n.length===0?"{}":t.length>yB?"["+aZ(e)+"]":"{ "+n.map(([i,a])=>i+": "+KN(a,t)).join(", ")+" }"}function hB(e,t){if(e.length===0)return"[]";if(t.length>yB)return"[Array]";let n=e.length,r=[];for(let i=0;i{"use strict";m();T();N();Object.defineProperty(gl,"__esModule",{value:!0});gl.relocatedError=gl.createGraphQLError=void 0;var bv=Ae(),sZ=["message","locations","path","nodes","source","positions","originalError","name","stack","extensions"];function oZ(e){return e!=null&&typeof e=="object"&&Object.keys(e).every(t=>sZ.includes(t))}function Av(e,t){return t!=null&&t.originalError&&!(t.originalError instanceof Error)&&oZ(t.originalError)&&(t.originalError=Av(t.originalError.message,t.originalError)),bv.versionInfo.major>=17?new bv.GraphQLError(e,t):new bv.GraphQLError(e,t==null?void 0:t.nodes,t==null?void 0:t.source,t==null?void 0:t.positions,t==null?void 0:t.path,t==null?void 0:t.originalError,t==null?void 0:t.extensions)}gl.createGraphQLError=Av;function uZ(e,t){return Av(e.message,{nodes:e.nodes,source:e.source,positions:e.positions,path:t==null?e.path:t,originalError:e,extensions:e.extensions})}gl.relocatedError=uZ});var _p=w(Bi=>{"use strict";m();T();N();Object.defineProperty(Bi,"__esModule",{value:!0});Bi.hasOwnProperty=Bi.promiseReduce=Bi.isPromise=Bi.isObjectLike=Bi.isIterableObject=void 0;function cZ(e){return e!=null&&typeof e=="object"&&Symbol.iterator in e}Bi.isIterableObject=cZ;function lZ(e){return typeof e=="object"&&e!==null}Bi.isObjectLike=lZ;function IB(e){return(e==null?void 0:e.then)!=null}Bi.isPromise=IB;function dZ(e,t,n){let r=n;for(let i of e)r=IB(r)?r.then(a=>t(a,i)):t(r,i);return r}Bi.promiseReduce=dZ;function pZ(e,t){return Object.prototype.hasOwnProperty.call(e,t)}Bi.hasOwnProperty=pZ});var Pv=w(YN=>{"use strict";m();T();N();Object.defineProperty(YN,"__esModule",{value:!0});YN.getArgumentValues=void 0;var Rv=gp(),rc=Ae(),QN=$N(),fZ=_p();function mZ(e,t,n={}){var o;let r={},a=((o=t.arguments)!=null?o:[]).reduce((c,l)=>Y(x({},c),{[l.name.value]:l}),{});for(let{name:c,type:l,defaultValue:p}of e.args){let f=a[c];if(!f){if(p!==void 0)r[c]=p;else if((0,rc.isNonNullType)(l))throw(0,QN.createGraphQLError)(`Argument "${c}" of required type "${(0,Rv.inspect)(l)}" was not provided.`,{nodes:[t]});continue}let y=f.value,g=y.kind===rc.Kind.NULL;if(y.kind===rc.Kind.VARIABLE){let P=y.name.value;if(n==null||!(0,fZ.hasOwnProperty)(n,P)){if(p!==void 0)r[c]=p;else if((0,rc.isNonNullType)(l))throw(0,QN.createGraphQLError)(`Argument "${c}" of required type "${(0,Rv.inspect)(l)}" was provided the variable "$${P}" which was not provided a runtime value.`,{nodes:[y]});continue}g=n[P]==null}if(g&&(0,rc.isNonNullType)(l))throw(0,QN.createGraphQLError)(`Argument "${c}" of non-null type "${(0,Rv.inspect)(l)}" must not be null.`,{nodes:[y]});let v=(0,rc.valueFromAST)(y,l,n);if(v===void 0)throw(0,QN.createGraphQLError)(`Argument "${c}" has invalid value ${(0,rc.print)(y)}.`,{nodes:[y]});r[c]=v}return r}YN.getArgumentValues=mZ});var Fv=w(Ba=>{"use strict";m();T();N();Object.defineProperty(Ba,"__esModule",{value:!0});Ba.getDirective=Ba.getDirectives=Ba.getDirectiveInExtensions=Ba.getDirectivesInExtensions=void 0;var _B=Pv();function vB(e,t=["directives"]){return t.reduce((n,r)=>n==null?n:n[r],e==null?void 0:e.extensions)}Ba.getDirectivesInExtensions=vB;function gB(e,t){let n=e.filter(r=>r.name===t);if(n.length)return n.map(r=>{var i;return(i=r.args)!=null?i:{}})}function SB(e,t,n=["directives"]){let r=n.reduce((a,o)=>a==null?a:a[o],e==null?void 0:e.extensions);if(r===void 0)return;if(Array.isArray(r))return gB(r,t);let i=[];for(let[a,o]of Object.entries(r))if(Array.isArray(o))for(let c of o)i.push({name:a,args:c});else i.push({name:a,args:o});return gB(i,t)}Ba.getDirectiveInExtensions=SB;function NZ(e,t,n=["directives"]){let r=vB(t,n);if(r!=null&&r.length>0)return r;let a=(e&&e.getDirectives?e.getDirectives():[]).reduce((l,p)=>(l[p.name]=p,l),{}),o=[];t.astNode&&o.push(t.astNode),"extensionASTNodes"in t&&t.extensionASTNodes&&(o=[...o,...t.extensionASTNodes]);let c=[];for(let l of o)if(l.directives)for(let p of l.directives){let f=a[p.name.value];f&&c.push({name:p.name.value,args:(0,_B.getArgumentValues)(f,p)})}return c}Ba.getDirectives=NZ;function TZ(e,t,n,r=["directives"]){let i=SB(t,n,r);if(i!=null)return i;let a=e&&e.getDirective?e.getDirective(n):void 0;if(a==null)return;let o=[];t.astNode&&o.push(t.astNode),"extensionASTNodes"in t&&t.extensionASTNodes&&(o=[...o,...t.extensionASTNodes]);let c=[];for(let l of o)if(l.directives)for(let p of l.directives)p.name.value===n&&c.push((0,_B.getArgumentValues)(a,p));if(c.length)return c}Ba.getDirective=TZ});var wv=w(JN=>{"use strict";m();T();N();Object.defineProperty(JN,"__esModule",{value:!0});JN.getFieldsWithDirectives=void 0;var EZ=Ae();function hZ(e,t={}){let n={},r=["ObjectTypeDefinition","ObjectTypeExtension"];t.includeInputTypes&&(r=[...r,"InputObjectTypeDefinition","InputObjectTypeExtension"]);let i=e.definitions.filter(a=>r.includes(a.kind));for(let a of i){let o=a.name.value;if(a.fields!=null){for(let c of a.fields)if(c.directives&&c.directives.length>0){let l=c.name.value,p=`${o}.${l}`,f=c.directives.map(y=>({name:y.name.value,args:(y.arguments||[]).reduce((g,v)=>Y(x({},g),{[v.name.value]:(0,EZ.valueFromASTUntyped)(v.value)}),{})}));n[p]=f}}}return n}JN.getFieldsWithDirectives=hZ});var OB=w(HN=>{"use strict";m();T();N();Object.defineProperty(HN,"__esModule",{value:!0});HN.getArgumentsWithDirectives=void 0;var Lv=Ae();function yZ(e){return e.kind===Lv.Kind.OBJECT_TYPE_DEFINITION||e.kind===Lv.Kind.OBJECT_TYPE_EXTENSION}function IZ(e){var r;let t={},n=e.definitions.filter(yZ);for(let i of n)if(i.fields!=null)for(let a of i.fields){let o=(r=a.arguments)==null?void 0:r.filter(l=>{var p;return(p=l.directives)==null?void 0:p.length});if(!(o!=null&&o.length))continue;let c=t[`${i.name.value}.${a.name.value}`]={};for(let l of o){let p=l.directives.map(f=>({name:f.name.value,args:(f.arguments||[]).reduce((y,g)=>Y(x({},y),{[g.name.value]:(0,Lv.valueFromASTUntyped)(g.value)}),{})}));c[l.name.value]=p}}return t}HN.getArgumentsWithDirectives=IZ});var Cv=w(zN=>{"use strict";m();T();N();Object.defineProperty(zN,"__esModule",{value:!0});zN.getImplementingTypes=void 0;var gZ=Ae();function _Z(e,t){let n=t.getTypeMap(),r=[];for(let i in n){let a=n[i];(0,gZ.isObjectType)(a)&&a.getInterfaces().find(c=>c.name===e)&&r.push(a.name)}return r}zN.getImplementingTypes=_Z});var Uv=w(WN=>{"use strict";m();T();N();Object.defineProperty(WN,"__esModule",{value:!0});WN.astFromType=void 0;var vZ=gp(),ic=Ae();function Bv(e){if((0,ic.isNonNullType)(e)){let t=Bv(e.ofType);if(t.kind===ic.Kind.NON_NULL_TYPE)throw new Error(`Invalid type node ${(0,vZ.inspect)(e)}. Inner type of non-null type cannot be a non-null type.`);return{kind:ic.Kind.NON_NULL_TYPE,type:t}}else if((0,ic.isListType)(e))return{kind:ic.Kind.LIST_TYPE,type:Bv(e.ofType)};return{kind:ic.Kind.NAMED_TYPE,name:{kind:ic.Kind.NAME,value:e.name}}}WN.astFromType=Bv});var ZN=w(XN=>{"use strict";m();T();N();Object.defineProperty(XN,"__esModule",{value:!0});XN.astFromValueUntyped=void 0;var Ua=Ae();function kv(e){if(e===null)return{kind:Ua.Kind.NULL};if(e===void 0)return null;if(Array.isArray(e)){let t=[];for(let n of e){let r=kv(n);r!=null&&t.push(r)}return{kind:Ua.Kind.LIST,values:t}}if(typeof e=="object"){let t=[];for(let n in e){let r=e[n],i=kv(r);i&&t.push({kind:Ua.Kind.OBJECT_FIELD,name:{kind:Ua.Kind.NAME,value:n},value:i})}return{kind:Ua.Kind.OBJECT,fields:t}}if(typeof e=="boolean")return{kind:Ua.Kind.BOOLEAN,value:e};if(typeof e=="bigint")return{kind:Ua.Kind.INT,value:String(e)};if(typeof e=="number"&&isFinite(e)){let t=String(e);return SZ.test(t)?{kind:Ua.Kind.INT,value:t}:{kind:Ua.Kind.FLOAT,value:t}}if(typeof e=="string")return{kind:Ua.Kind.STRING,value:e};throw new TypeError(`Cannot convert value to AST: ${e}.`)}XN.astFromValueUntyped=kv;var SZ=/^-?(?:0|[1-9][0-9]*)$/});var bB=w(eT=>{"use strict";m();T();N();Object.defineProperty(eT,"__esModule",{value:!0});eT.astFromValue=void 0;var OZ=gp(),pi=Ae(),DZ=ZN(),DB=_p();function vp(e,t){if((0,pi.isNonNullType)(t)){let n=vp(e,t.ofType);return(n==null?void 0:n.kind)===pi.Kind.NULL?null:n}if(e===null)return{kind:pi.Kind.NULL};if(e===void 0)return null;if((0,pi.isListType)(t)){let n=t.ofType;if((0,DB.isIterableObject)(e)){let r=[];for(let i of e){let a=vp(i,n);a!=null&&r.push(a)}return{kind:pi.Kind.LIST,values:r}}return vp(e,n)}if((0,pi.isInputObjectType)(t)){if(!(0,DB.isObjectLike)(e))return null;let n=[];for(let r of Object.values(t.getFields())){let i=vp(e[r.name],r.type);i&&n.push({kind:pi.Kind.OBJECT_FIELD,name:{kind:pi.Kind.NAME,value:r.name},value:i})}return{kind:pi.Kind.OBJECT,fields:n}}if((0,pi.isLeafType)(t)){let n=t.serialize(e);return n==null?null:(0,pi.isEnumType)(t)?{kind:pi.Kind.ENUM,value:n}:t.name==="ID"&&typeof n=="string"&&bZ.test(n)?{kind:pi.Kind.INT,value:n}:(0,DZ.astFromValueUntyped)(n)}console.assert(!1,"Unexpected input type: "+(0,OZ.inspect)(t))}eT.astFromValue=vp;var bZ=/^-?(?:0|[1-9][0-9]*)$/});var AB=w(tT=>{"use strict";m();T();N();Object.defineProperty(tT,"__esModule",{value:!0});tT.getDescriptionNode=void 0;var AZ=Ae();function RZ(e){var t;if((t=e.astNode)!=null&&t.description)return Y(x({},e.astNode.description),{block:!0});if(e.description)return{kind:AZ.Kind.STRING,value:e.description,block:!0}}tT.getDescriptionNode=RZ});var _l=w(Or=>{"use strict";m();T();N();Object.defineProperty(Or,"__esModule",{value:!0});Or.memoize2of5=Or.memoize2of4=Or.memoize5=Or.memoize4=Or.memoize3=Or.memoize2=Or.memoize1=void 0;function PZ(e){let t=new WeakMap;return function(r){let i=t.get(r);if(i===void 0){let a=e(r);return t.set(r,a),a}return i}}Or.memoize1=PZ;function FZ(e){let t=new WeakMap;return function(r,i){let a=t.get(r);if(!a){a=new WeakMap,t.set(r,a);let c=e(r,i);return a.set(i,c),c}let o=a.get(i);if(o===void 0){let c=e(r,i);return a.set(i,c),c}return o}}Or.memoize2=FZ;function wZ(e){let t=new WeakMap;return function(r,i,a){let o=t.get(r);if(!o){o=new WeakMap,t.set(r,o);let p=new WeakMap;o.set(i,p);let f=e(r,i,a);return p.set(a,f),f}let c=o.get(i);if(!c){c=new WeakMap,o.set(i,c);let p=e(r,i,a);return c.set(a,p),p}let l=c.get(a);if(l===void 0){let p=e(r,i,a);return c.set(a,p),p}return l}}Or.memoize3=wZ;function LZ(e){let t=new WeakMap;return function(r,i,a,o){let c=t.get(r);if(!c){c=new WeakMap,t.set(r,c);let y=new WeakMap;c.set(i,y);let g=new WeakMap;y.set(a,g);let v=e(r,i,a,o);return g.set(o,v),v}let l=c.get(i);if(!l){l=new WeakMap,c.set(i,l);let y=new WeakMap;l.set(a,y);let g=e(r,i,a,o);return y.set(o,g),g}let p=l.get(a);if(!p){let y=new WeakMap;l.set(a,y);let g=e(r,i,a,o);return y.set(o,g),g}let f=p.get(o);if(f===void 0){let y=e(r,i,a,o);return p.set(o,y),y}return f}}Or.memoize4=LZ;function CZ(e){let t=new WeakMap;return function(r,i,a,o,c){let l=t.get(r);if(!l){l=new WeakMap,t.set(r,l);let v=new WeakMap;l.set(i,v);let P=new WeakMap;v.set(a,P);let U=new WeakMap;P.set(o,U);let K=e(r,i,a,o,c);return U.set(c,K),K}let p=l.get(i);if(!p){p=new WeakMap,l.set(i,p);let v=new WeakMap;p.set(a,v);let P=new WeakMap;v.set(o,P);let U=e(r,i,a,o,c);return P.set(c,U),U}let f=p.get(a);if(!f){f=new WeakMap,p.set(a,f);let v=new WeakMap;f.set(o,v);let P=e(r,i,a,o,c);return v.set(c,P),P}let y=f.get(o);if(!y){y=new WeakMap,f.set(o,y);let v=e(r,i,a,o,c);return y.set(c,v),v}let g=y.get(c);if(g===void 0){let v=e(r,i,a,o,c);return y.set(c,v),v}return g}}Or.memoize5=CZ;function BZ(e){let t=new WeakMap;return function(r,i,a,o){let c=t.get(r);if(!c){c=new WeakMap,t.set(r,c);let p=e(r,i,a,o);return c.set(i,p),p}let l=c.get(i);if(l===void 0){let p=e(r,i,a,o);return c.set(i,p),p}return l}}Or.memoize2of4=BZ;function UZ(e){let t=new WeakMap;return function(r,i,a,o,c){let l=t.get(r);if(!l){l=new WeakMap,t.set(r,l);let f=e(r,i,a,o,c);return l.set(i,f),f}let p=l.get(i);if(p===void 0){let f=e(r,i,a,o,c);return l.set(i,f),f}return p}}Or.memoize2of5=UZ});var Sp=w(fi=>{"use strict";m();T();N();Object.defineProperty(fi,"__esModule",{value:!0});fi.getRootTypeMap=fi.getRootTypes=fi.getRootTypeNames=fi.getDefinedRootType=void 0;var kZ=$N(),Mv=_l();function MZ(e,t,n){let i=(0,fi.getRootTypeMap)(e).get(t);if(i==null)throw(0,kZ.createGraphQLError)(`Schema is not configured to execute ${t} operation.`,{nodes:n});return i}fi.getDefinedRootType=MZ;fi.getRootTypeNames=(0,Mv.memoize1)(function(t){let n=(0,fi.getRootTypes)(t);return new Set([...n].map(r=>r.name))});fi.getRootTypes=(0,Mv.memoize1)(function(t){let n=(0,fi.getRootTypeMap)(t);return new Set(n.values())});fi.getRootTypeMap=(0,Mv.memoize1)(function(t){let n=new Map,r=t.getQueryType();r&&n.set("query",r);let i=t.getMutationType();i&&n.set("mutation",i);let a=t.getSubscriptionType();return a&&n.set("subscription",a),n})});var Kv=w(ht=>{"use strict";m();T();N();Object.defineProperty(ht,"__esModule",{value:!0});ht.makeDirectiveNodes=ht.makeDirectiveNode=ht.makeDeprecatedDirective=ht.astFromEnumValue=ht.astFromInputField=ht.astFromField=ht.astFromScalarType=ht.astFromEnumType=ht.astFromInputObjectType=ht.astFromUnionType=ht.astFromInterfaceType=ht.astFromObjectType=ht.astFromArg=ht.getDeprecatableDirectiveNodes=ht.getDirectiveNodes=ht.astFromDirective=ht.astFromSchema=ht.printSchemaWithDirectives=ht.getDocumentNodeFromSchema=void 0;var ut=Ae(),ac=Uv(),xv=bB(),xZ=ZN(),Ui=AB(),qv=Fv(),qZ=Ip(),VZ=Sp();function RB(e,t={}){let n=t.pathToDirectivesInExtensions,r=e.getTypeMap(),i=PB(e,n),a=i!=null?[i]:[],o=e.getDirectives();for(let c of o)(0,ut.isSpecifiedDirective)(c)||a.push(FB(c,e,n));for(let c in r){let l=r[c],p=(0,ut.isSpecifiedScalarType)(l),f=(0,ut.isIntrospectionType)(l);if(!(p||f))if((0,ut.isObjectType)(l))a.push(wB(l,e,n));else if((0,ut.isInterfaceType)(l))a.push(LB(l,e,n));else if((0,ut.isUnionType)(l))a.push(CB(l,e,n));else if((0,ut.isInputObjectType)(l))a.push(BB(l,e,n));else if((0,ut.isEnumType)(l))a.push(UB(l,e,n));else if((0,ut.isScalarType)(l))a.push(kB(l,e,n));else throw new Error(`Unknown type ${l}.`)}return{kind:ut.Kind.DOCUMENT,definitions:a}}ht.getDocumentNodeFromSchema=RB;function jZ(e,t={}){let n=RB(e,t);return(0,ut.print)(n)}ht.printSchemaWithDirectives=jZ;function PB(e,t){let n=new Map([["query",void 0],["mutation",void 0],["subscription",void 0]]),r=[];if(e.astNode!=null&&r.push(e.astNode),e.extensionASTNodes!=null)for(let p of e.extensionASTNodes)r.push(p);for(let p of r)if(p.operationTypes)for(let f of p.operationTypes)n.set(f.operation,f);let i=(0,VZ.getRootTypeMap)(e);for(let[p,f]of n){let y=i.get(p);if(y!=null){let g=(0,ac.astFromType)(y);f!=null?f.type=g:n.set(p,{kind:ut.Kind.OPERATION_TYPE_DEFINITION,operation:p,type:g})}}let a=[...n.values()].filter(qZ.isSome),o=sc(e,e,t);if(!a.length&&!o.length)return null;let c={kind:a!=null?ut.Kind.SCHEMA_DEFINITION:ut.Kind.SCHEMA_EXTENSION,operationTypes:a,directives:o},l=(0,Ui.getDescriptionNode)(e);return l&&(c.description=l),c}ht.astFromSchema=PB;function FB(e,t,n){var r,i;return{kind:ut.Kind.DIRECTIVE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},arguments:(r=e.args)==null?void 0:r.map(a=>Vv(a,t,n)),repeatable:e.isRepeatable,locations:((i=e.locations)==null?void 0:i.map(a=>({kind:ut.Kind.NAME,value:a})))||[]}}ht.astFromDirective=FB;function sc(e,t,n){let r=(0,qv.getDirectivesInExtensions)(e,n),i=[];e.astNode!=null&&i.push(e.astNode),"extensionASTNodes"in e&&e.extensionASTNodes!=null&&(i=i.concat(e.extensionASTNodes));let a;if(r!=null)a=nT(t,r);else{a=[];for(let o of i)o.directives&&a.push(...o.directives)}return a}ht.getDirectiveNodes=sc;function Dp(e,t,n){var c,l;let r=[],i=null,a=(0,qv.getDirectivesInExtensions)(e,n),o;return a!=null?o=nT(t,a):o=(c=e.astNode)==null?void 0:c.directives,o!=null&&(r=o.filter(p=>p.name.value!=="deprecated"),e.deprecationReason!=null&&(i=(l=o.filter(p=>p.name.value==="deprecated"))==null?void 0:l[0])),e.deprecationReason!=null&&i==null&&(i=qB(e.deprecationReason)),i==null?r:[i].concat(r)}ht.getDeprecatableDirectiveNodes=Dp;function Vv(e,t,n){var r;return{kind:ut.Kind.INPUT_VALUE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},type:(0,ac.astFromType)(e.type),defaultValue:e.defaultValue!==void 0&&(r=(0,xv.astFromValue)(e.defaultValue,e.type))!=null?r:void 0,directives:Dp(e,t,n)}}ht.astFromArg=Vv;function wB(e,t,n){return{kind:ut.Kind.OBJECT_TYPE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},fields:Object.values(e.getFields()).map(r=>jv(r,t,n)),interfaces:Object.values(e.getInterfaces()).map(r=>(0,ac.astFromType)(r)),directives:sc(e,t,n)}}ht.astFromObjectType=wB;function LB(e,t,n){let r={kind:ut.Kind.INTERFACE_TYPE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},fields:Object.values(e.getFields()).map(i=>jv(i,t,n)),directives:sc(e,t,n)};return"getInterfaces"in e&&(r.interfaces=Object.values(e.getInterfaces()).map(i=>(0,ac.astFromType)(i))),r}ht.astFromInterfaceType=LB;function CB(e,t,n){return{kind:ut.Kind.UNION_TYPE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},directives:sc(e,t,n),types:e.getTypes().map(r=>(0,ac.astFromType)(r))}}ht.astFromUnionType=CB;function BB(e,t,n){return{kind:ut.Kind.INPUT_OBJECT_TYPE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},fields:Object.values(e.getFields()).map(r=>MB(r,t,n)),directives:sc(e,t,n)}}ht.astFromInputObjectType=BB;function UB(e,t,n){return{kind:ut.Kind.ENUM_TYPE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},values:Object.values(e.getValues()).map(r=>xB(r,t,n)),directives:sc(e,t,n)}}ht.astFromEnumType=UB;function kB(e,t,n){var o;let r=(0,qv.getDirectivesInExtensions)(e,n),i=r?nT(t,r):((o=e.astNode)==null?void 0:o.directives)||[],a=e.specifiedByUrl||e.specifiedByURL;if(a&&!i.some(c=>c.name.value==="specifiedBy")){let c={url:a};i.push(Op("specifiedBy",c))}return{kind:ut.Kind.SCALAR_TYPE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},directives:i}}ht.astFromScalarType=kB;function jv(e,t,n){return{kind:ut.Kind.FIELD_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},arguments:e.args.map(r=>Vv(r,t,n)),type:(0,ac.astFromType)(e.type),directives:Dp(e,t,n)}}ht.astFromField=jv;function MB(e,t,n){var r;return{kind:ut.Kind.INPUT_VALUE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},type:(0,ac.astFromType)(e.type),directives:Dp(e,t,n),defaultValue:(r=(0,xv.astFromValue)(e.defaultValue,e.type))!=null?r:void 0}}ht.astFromInputField=MB;function xB(e,t,n){return{kind:ut.Kind.ENUM_VALUE_DEFINITION,description:(0,Ui.getDescriptionNode)(e),name:{kind:ut.Kind.NAME,value:e.name},directives:Dp(e,t,n)}}ht.astFromEnumValue=xB;function qB(e){return Op("deprecated",{reason:e},ut.GraphQLDeprecatedDirective)}ht.makeDeprecatedDirective=qB;function Op(e,t,n){let r=[];if(n!=null)for(let i of n.args){let a=i.name,o=t[a];if(o!==void 0){let c=(0,xv.astFromValue)(o,i.type);c&&r.push({kind:ut.Kind.ARGUMENT,name:{kind:ut.Kind.NAME,value:a},value:c})}}else for(let i in t){let a=t[i],o=(0,xZ.astFromValueUntyped)(a);o&&r.push({kind:ut.Kind.ARGUMENT,name:{kind:ut.Kind.NAME,value:i},value:o})}return{kind:ut.Kind.DIRECTIVE,name:{kind:ut.Kind.NAME,value:e},arguments:r}}ht.makeDirectiveNode=Op;function nT(e,t){let n=[];for(let r in t){let i=t[r],a=e==null?void 0:e.getDirective(r);if(Array.isArray(i))for(let o of i)n.push(Op(r,o,a));else n.push(Op(r,i,a))}return n}ht.makeDirectiveNodes=nT});var jB=w(vl=>{"use strict";m();T();N();Object.defineProperty(vl,"__esModule",{value:!0});vl.createDefaultRules=vl.validateGraphQlDocuments=void 0;var bp=Ae();function KZ(e,t,n=VB()){var c;let r=new Set,i=new Map;for(let l of t)for(let p of l.definitions)p.kind===bp.Kind.FRAGMENT_DEFINITION?i.set(p.name.value,p):r.add(p);let a={kind:bp.Kind.DOCUMENT,definitions:Array.from([...r,...i.values()])},o=(0,bp.validate)(e,a,n);for(let l of o)if(l.stack=l.message,l.locations)for(let p of l.locations)l.stack+=` at ${(c=l.source)==null?void 0:c.name}:${p.line}:${p.column}`;return o}vl.validateGraphQlDocuments=KZ;function VB(){let e=["NoUnusedFragmentsRule","NoUnusedVariablesRule","KnownDirectivesRule"];return bp.versionInfo.major<15&&(e=e.map(t=>t.replace(/Rule$/,""))),bp.specifiedRules.filter(t=>!e.includes(t.name))}vl.createDefaultRules=VB});var KB=w(rT=>{"use strict";m();T();N();Object.defineProperty(rT,"__esModule",{value:!0});rT.parseGraphQLJSON=void 0;var GZ=Ae();function $Z(e){return e=e.toString(),e.charCodeAt(0)===65279&&(e=e.slice(1)),e}function QZ(e){return JSON.parse($Z(e))}function YZ(e,t,n){let r=QZ(t);if(r.data&&(r=r.data),r.kind==="Document")return{location:e,document:r};if(r.__schema){let i=(0,GZ.buildClientSchema)(r,n);return{location:e,schema:i}}else if(typeof r=="string")return{location:e,rawSDL:r};throw new Error("Not valid JSON content")}rT.parseGraphQLJSON=YZ});var $v=w(Ln=>{"use strict";m();T();N();Object.defineProperty(Ln,"__esModule",{value:!0});Ln.getBlockStringIndentation=Ln.dedentBlockStringValue=Ln.getLeadingCommentBlock=Ln.getComment=Ln.getDescription=Ln.printWithComments=Ln.printComment=Ln.pushComment=Ln.collectComment=Ln.resetComments=void 0;var YB=Ae(),JZ=80,Sl={};function HZ(){Sl={}}Ln.resetComments=HZ;function zZ(e){var n;let t=(n=e.name)==null?void 0:n.value;if(t!=null)switch(Ap(e,t),e.kind){case"EnumTypeDefinition":if(e.values)for(let r of e.values)Ap(r,t,r.name.value);break;case"ObjectTypeDefinition":case"InputObjectTypeDefinition":case"InterfaceTypeDefinition":if(e.fields){for(let r of e.fields)if(Ap(r,t,r.name.value),tee(r)&&r.arguments)for(let i of r.arguments)Ap(i,t,r.name.value,i.name.value)}break}}Ln.collectComment=zZ;function Ap(e,t,n,r){let i=Gv(e);if(typeof i!="string"||i.length===0)return;let a=[t];n&&(a.push(n),r&&a.push(r));let o=a.join(".");Sl[o]||(Sl[o]=[]),Sl[o].push(i)}Ln.pushComment=Ap;function JB(e){return` # `+e.replace(/\n/g,` # `)}Ln.printComment=JB;function Me(e,t){return e?e.filter(n=>n).join(t||""):""}function GB(e){var t;return(t=e==null?void 0:e.some(n=>n.includes(` @@ -227,11 +227,11 @@ ${t}`)}Ln.getComment=Gv;function HB(e){let t=e.loc;if(!t)return;let n=[],r=t.sta `)}Ln.dedentBlockStringValue=zB;function WB(e){let t=null;for(let n=1;n{"use strict";m();T();N();Object.defineProperty(uu,"__esModule",{value:!0});uu.isDescribable=uu.transformCommentsToDescriptions=uu.parseGraphQLSDL=void 0;var ki=Ae(),ZB=$v();function ree(e,t,n={}){let r;try{n.commentDescriptions&&t.includes("#")?(r=eU(t,n),n.noLocation&&(r=(0,ki.parse)((0,ki.print)(r),n))):r=(0,ki.parse)(new ki.Source(t,e),n)}catch(i){if(i.message.includes("EOF")&&t.replace(/(\#[^*]*)/g,"").trim()==="")r={kind:ki.Kind.DOCUMENT,definitions:[]};else throw i}return{location:e,document:r}}uu.parseGraphQLSDL=ree;function eU(e,t={}){let n=(0,ki.parse)(e,Y(x({},t),{noLocation:!1}));return(0,ki.visit)(n,{leave:i=>{if(tU(i)){let a=(0,ZB.getLeadingCommentBlock)(i);if(a!==void 0){let o=(0,ZB.dedentBlockStringValue)(` `+a),c=o.includes(` `);return i.description?Y(x({},i),{description:Y(x({},i.description),{value:i.description.value+` -`+o,block:!0})}):Y(x({},i),{description:{kind:ki.Kind.STRING,value:o,block:c}})}}}})}uu.transformCommentsToDescriptions=eU;function tU(e){return(0,ki.isTypeSystemDefinitionNode)(e)||e.kind===ki.Kind.FIELD_DEFINITION||e.kind===ki.Kind.INPUT_VALUE_DEFINITION||e.kind===ki.Kind.ENUM_VALUE_DEFINITION}uu.isDescribable=tU});var lU=w(aT=>{"use strict";m();T();N();Object.defineProperty(aT,"__esModule",{value:!0});aT.buildOperationNodeForField=void 0;var ct=Ae(),sU=Sp(),Jv=[],iT=new Map;function oU(e){Jv.push(e)}function rU(){Jv=[]}function iU(){iT=new Map}function iee({schema:e,kind:t,field:n,models:r,ignore:i=[],depthLimit:a,circularReferenceDepth:o,argNames:c,selectedFields:l=!0}){rU(),iU();let p=(0,sU.getRootTypeNames)(e),f=aee({schema:e,fieldName:n,kind:t,models:r||[],ignore:i,depthLimit:a||1/0,circularReferenceDepth:o||1,argNames:c,selectedFields:l,rootTypeNames:p});return f.variableDefinitions=[...Jv],rU(),iU(),f}aT.buildOperationNodeForField=iee;function aee({schema:e,fieldName:t,kind:n,models:r,ignore:i,depthLimit:a,circularReferenceDepth:o,argNames:c,selectedFields:l,rootTypeNames:p}){let f=(0,sU.getDefinedRootType)(e,n),y=f.getFields()[t],g=`${t}_${n}`;if(y.args)for(let v of y.args){let F=v.name;(!c||c.includes(F))&&oU(uU(v,F))}return{kind:ct.Kind.OPERATION_DEFINITION,operation:n,name:{kind:ct.Kind.NAME,value:g},variableDefinitions:[],selectionSet:{kind:ct.Kind.SELECTION_SET,selections:[cU({type:f,field:y,models:r,firstCall:!0,path:[],ancestors:[],ignore:i,depthLimit:a,circularReferenceDepth:o,schema:e,depth:0,argNames:c,selectedFields:l,rootTypeNames:p})]}}}function Yv({parent:e,type:t,models:n,firstCall:r,path:i,ancestors:a,ignore:o,depthLimit:c,circularReferenceDepth:l,schema:p,depth:f,argNames:y,selectedFields:g,rootTypeNames:v}){if(!(typeof g=="boolean"&&f>c)){if((0,ct.isUnionType)(t)){let F=t.getTypes();return{kind:ct.Kind.SELECTION_SET,selections:F.filter(k=>!Qv([...a,k],{depth:l})).map(k=>({kind:ct.Kind.INLINE_FRAGMENT,typeCondition:{kind:ct.Kind.NAMED_TYPE,name:{kind:ct.Kind.NAME,value:k.name}},selectionSet:Yv({parent:t,type:k,models:n,path:i,ancestors:a,ignore:o,depthLimit:c,circularReferenceDepth:l,schema:p,depth:f,argNames:y,selectedFields:g,rootTypeNames:v})})).filter(k=>{var K,$;return(($=(K=k==null?void 0:k.selectionSet)==null?void 0:K.selections)==null?void 0:$.length)>0})}}if((0,ct.isInterfaceType)(t)){let F=Object.values(p.getTypeMap()).filter(k=>(0,ct.isObjectType)(k)&&k.getInterfaces().includes(t));return{kind:ct.Kind.SELECTION_SET,selections:F.filter(k=>!Qv([...a,k],{depth:l})).map(k=>({kind:ct.Kind.INLINE_FRAGMENT,typeCondition:{kind:ct.Kind.NAMED_TYPE,name:{kind:ct.Kind.NAME,value:k.name}},selectionSet:Yv({parent:t,type:k,models:n,path:i,ancestors:a,ignore:o,depthLimit:c,circularReferenceDepth:l,schema:p,depth:f,argNames:y,selectedFields:g,rootTypeNames:v})})).filter(k=>{var K,$;return(($=(K=k==null?void 0:k.selectionSet)==null?void 0:K.selections)==null?void 0:$.length)>0})}}if((0,ct.isObjectType)(t)&&!v.has(t.name)){let F=o.includes(t.name)||o.includes(`${e.name}.${i[i.length-1]}`),k=n.includes(t.name);if(!r&&k&&!F)return{kind:ct.Kind.SELECTION_SET,selections:[{kind:ct.Kind.FIELD,name:{kind:ct.Kind.NAME,value:"id"}}]};let K=t.getFields();return{kind:ct.Kind.SELECTION_SET,selections:Object.keys(K).filter($=>!Qv([...a,(0,ct.getNamedType)(K[$].type)],{depth:l})).map($=>{let ne=typeof g=="object"?g[$]:!0;return ne?cU({type:t,field:K[$],models:n,path:[...i,$],ancestors:a,ignore:o,depthLimit:c,circularReferenceDepth:l,schema:p,depth:f,argNames:y,selectedFields:ne,rootTypeNames:v}):null}).filter($=>{var ne,z;return $==null?!1:"selectionSet"in $?!!((z=(ne=$.selectionSet)==null?void 0:ne.selections)!=null&&z.length):!0})}}}}function uU(e,t){function n(r){return(0,ct.isListType)(r)?{kind:ct.Kind.LIST_TYPE,type:n(r.ofType)}:(0,ct.isNonNullType)(r)?{kind:ct.Kind.NON_NULL_TYPE,type:n(r.ofType)}:{kind:ct.Kind.NAMED_TYPE,name:{kind:ct.Kind.NAME,value:r.name}}}return{kind:ct.Kind.VARIABLE_DEFINITION,variable:{kind:ct.Kind.VARIABLE,name:{kind:ct.Kind.NAME,value:t||e.name}},type:n(e.type)}}function aU(e,t){return[...t,e].join("_")}function cU({type:e,field:t,models:n,firstCall:r,path:i,ancestors:a,ignore:o,depthLimit:c,circularReferenceDepth:l,schema:p,depth:f,argNames:y,selectedFields:g,rootTypeNames:v}){let F=(0,ct.getNamedType)(t.type),k=[],K=!1;if(t.args&&t.args.length&&(k=t.args.map(Te=>{let pe=aU(Te.name,i);return y&&!y.includes(pe)?((0,ct.isNonNullType)(Te.type)&&(K=!0),null):(r||oU(uU(Te,pe)),{kind:ct.Kind.ARGUMENT,name:{kind:ct.Kind.NAME,value:Te.name},value:{kind:ct.Kind.VARIABLE,name:{kind:ct.Kind.NAME,value:aU(Te.name,i)}}})}).filter(Boolean)),K)return null;let $=[...i,t.name],ne=$.join("."),z=t.name;return iT.has(ne)&&iT.get(ne)!==t.type.toString()&&(z+=t.type.toString().replace("!","NonNull").replace("[","List").replace("]","")),iT.set(ne,t.type.toString()),!(0,ct.isScalarType)(F)&&!(0,ct.isEnumType)(F)?Y(x({kind:ct.Kind.FIELD,name:{kind:ct.Kind.NAME,value:t.name}},z!==t.name&&{alias:{kind:ct.Kind.NAME,value:z}}),{selectionSet:Yv({parent:e,type:F,models:n,firstCall:r,path:$,ancestors:[...a,e],ignore:o,depthLimit:c,circularReferenceDepth:l,schema:p,depth:f+1,argNames:y,selectedFields:g,rootTypeNames:v})||void 0,arguments:k}):Y(x({kind:ct.Kind.FIELD,name:{kind:ct.Kind.NAME,value:t.name}},z!==t.name&&{alias:{kind:ct.Kind.NAME,value:z}}),{arguments:k})}function Qv(e,t={depth:1}){let n=e[e.length-1];return(0,ct.isScalarType)(n)?!1:e.filter(i=>i.name===n.name).length>t.depth}});var pU=w(sT=>{"use strict";m();T();N();Object.defineProperty(sT,"__esModule",{value:!0});sT.DirectiveLocation=void 0;var dU;(function(e){e.QUERY="QUERY",e.MUTATION="MUTATION",e.SUBSCRIPTION="SUBSCRIPTION",e.FIELD="FIELD",e.FRAGMENT_DEFINITION="FRAGMENT_DEFINITION",e.FRAGMENT_SPREAD="FRAGMENT_SPREAD",e.INLINE_FRAGMENT="INLINE_FRAGMENT",e.VARIABLE_DEFINITION="VARIABLE_DEFINITION",e.SCHEMA="SCHEMA",e.SCALAR="SCALAR",e.OBJECT="OBJECT",e.FIELD_DEFINITION="FIELD_DEFINITION",e.ARGUMENT_DEFINITION="ARGUMENT_DEFINITION",e.INTERFACE="INTERFACE",e.UNION="UNION",e.ENUM="ENUM",e.ENUM_VALUE="ENUM_VALUE",e.INPUT_OBJECT="INPUT_OBJECT",e.INPUT_FIELD_DEFINITION="INPUT_FIELD_DEFINITION"})(dU||(sT.DirectiveLocation=dU={}))});var oc=w(oT=>{"use strict";m();T();N();Object.defineProperty(oT,"__esModule",{value:!0});oT.MapperKind=void 0;var fU;(function(e){e.TYPE="MapperKind.TYPE",e.SCALAR_TYPE="MapperKind.SCALAR_TYPE",e.ENUM_TYPE="MapperKind.ENUM_TYPE",e.COMPOSITE_TYPE="MapperKind.COMPOSITE_TYPE",e.OBJECT_TYPE="MapperKind.OBJECT_TYPE",e.INPUT_OBJECT_TYPE="MapperKind.INPUT_OBJECT_TYPE",e.ABSTRACT_TYPE="MapperKind.ABSTRACT_TYPE",e.UNION_TYPE="MapperKind.UNION_TYPE",e.INTERFACE_TYPE="MapperKind.INTERFACE_TYPE",e.ROOT_OBJECT="MapperKind.ROOT_OBJECT",e.QUERY="MapperKind.QUERY",e.MUTATION="MapperKind.MUTATION",e.SUBSCRIPTION="MapperKind.SUBSCRIPTION",e.DIRECTIVE="MapperKind.DIRECTIVE",e.FIELD="MapperKind.FIELD",e.COMPOSITE_FIELD="MapperKind.COMPOSITE_FIELD",e.OBJECT_FIELD="MapperKind.OBJECT_FIELD",e.ROOT_FIELD="MapperKind.ROOT_FIELD",e.QUERY_ROOT_FIELD="MapperKind.QUERY_ROOT_FIELD",e.MUTATION_ROOT_FIELD="MapperKind.MUTATION_ROOT_FIELD",e.SUBSCRIPTION_ROOT_FIELD="MapperKind.SUBSCRIPTION_ROOT_FIELD",e.INTERFACE_FIELD="MapperKind.INTERFACE_FIELD",e.INPUT_OBJECT_FIELD="MapperKind.INPUT_OBJECT_FIELD",e.ARGUMENT="MapperKind.ARGUMENT",e.ENUM_VALUE="MapperKind.ENUM_VALUE"})(fU||(oT.MapperKind=fU={}))});var Hv=w(uT=>{"use strict";m();T();N();Object.defineProperty(uT,"__esModule",{value:!0});uT.getObjectTypeFromTypeMap=void 0;var see=Ae();function oee(e,t){if(t){let n=e[t.name];if((0,see.isObjectType)(n))return n}}uT.getObjectTypeFromTypeMap=oee});var Xv=w(ka=>{"use strict";m();T();N();Object.defineProperty(ka,"__esModule",{value:!0});ka.getBuiltInForStub=ka.isNamedStub=ka.createStub=ka.createNamedStub=void 0;var lr=Ae();function zv(e,t){let n;return t==="object"?n=lr.GraphQLObjectType:t==="interface"?n=lr.GraphQLInterfaceType:n=lr.GraphQLInputObjectType,new n({name:e,fields:{_fake:{type:lr.GraphQLString}}})}ka.createNamedStub=zv;function Wv(e,t){switch(e.kind){case lr.Kind.LIST_TYPE:return new lr.GraphQLList(Wv(e.type,t));case lr.Kind.NON_NULL_TYPE:return new lr.GraphQLNonNull(Wv(e.type,t));default:return t==="output"?zv(e.name.value,"object"):zv(e.name.value,"input")}}ka.createStub=Wv;function uee(e){if("getFields"in e){let t=e.getFields();for(let n in t)return t[n].name==="_fake"}return!1}ka.isNamedStub=uee;function cee(e){switch(e.name){case lr.GraphQLInt.name:return lr.GraphQLInt;case lr.GraphQLFloat.name:return lr.GraphQLFloat;case lr.GraphQLString.name:return lr.GraphQLString;case lr.GraphQLBoolean.name:return lr.GraphQLBoolean;case lr.GraphQLID.name:return lr.GraphQLID;default:return e}}ka.getBuiltInForStub=cee});var lT=w(cT=>{"use strict";m();T();N();Object.defineProperty(cT,"__esModule",{value:!0});cT.rewireTypes=void 0;var Qn=Ae(),mU=Xv();function lee(e,t){let n=Object.create(null);for(let g in e)n[g]=e[g];let r=Object.create(null);for(let g in n){let v=n[g];if(v==null||g.startsWith("__"))continue;let F=v.name;if(!F.startsWith("__")){if(r[F]!=null){console.warn(`Duplicate schema type name ${F} found; keeping the existing one found in the schema`);continue}r[F]=v}}for(let g in r)r[g]=c(r[g]);let i=t.map(g=>a(g));return{typeMap:r,directives:i};function a(g){if((0,Qn.isSpecifiedDirective)(g))return g;let v=g.toConfig();return v.args=o(v.args),new Qn.GraphQLDirective(v)}function o(g){let v={};for(let F in g){let k=g[F],K=y(k.type);K!=null&&(k.type=K,v[F]=k)}return v}function c(g){if((0,Qn.isObjectType)(g)){let v=g.toConfig(),F=Y(x({},v),{fields:()=>l(v.fields),interfaces:()=>f(v.interfaces)});return new Qn.GraphQLObjectType(F)}else if((0,Qn.isInterfaceType)(g)){let v=g.toConfig(),F=Y(x({},v),{fields:()=>l(v.fields)});return"interfaces"in F&&(F.interfaces=()=>f(v.interfaces)),new Qn.GraphQLInterfaceType(F)}else if((0,Qn.isUnionType)(g)){let v=g.toConfig(),F=Y(x({},v),{types:()=>f(v.types)});return new Qn.GraphQLUnionType(F)}else if((0,Qn.isInputObjectType)(g)){let v=g.toConfig(),F=Y(x({},v),{fields:()=>p(v.fields)});return new Qn.GraphQLInputObjectType(F)}else if((0,Qn.isEnumType)(g)){let v=g.toConfig();return new Qn.GraphQLEnumType(v)}else if((0,Qn.isScalarType)(g)){if((0,Qn.isSpecifiedScalarType)(g))return g;let v=g.toConfig();return new Qn.GraphQLScalarType(v)}throw new Error(`Unexpected schema type: ${g}`)}function l(g){let v={};for(let F in g){let k=g[F],K=y(k.type);K!=null&&k.args&&(k.type=K,k.args=o(k.args),v[F]=k)}return v}function p(g){let v={};for(let F in g){let k=g[F],K=y(k.type);K!=null&&(k.type=K,v[F]=k)}return v}function f(g){let v=[];for(let F of g){let k=y(F);k!=null&&v.push(k)}return v}function y(g){if((0,Qn.isListType)(g)){let v=y(g.ofType);return v!=null?new Qn.GraphQLList(v):null}else if((0,Qn.isNonNullType)(g)){let v=y(g.ofType);return v!=null?new Qn.GraphQLNonNull(v):null}else if((0,Qn.isNamedType)(g)){let v=n[g.name];return v===void 0&&(v=(0,mU.isNamedStub)(g)?(0,mU.getBuiltInForStub)(g):c(g),r[v.name]=n[g.name]=v),v!=null?r[v.name]:null}return null}}cT.rewireTypes=lee});var Zv=w(Ma=>{"use strict";m();T();N();Object.defineProperty(Ma,"__esModule",{value:!0});Ma.parseInputValueLiteral=Ma.parseInputValue=Ma.serializeInputValue=Ma.transformInputValue=void 0;var dT=Ae(),dee=Ip();function Ol(e,t,n=null,r=null){if(t==null)return t;let i=(0,dT.getNullableType)(e);if((0,dT.isLeafType)(i))return n!=null?n(i,t):t;if((0,dT.isListType)(i))return(0,dee.asArray)(t).map(a=>Ol(i.ofType,a,n,r));if((0,dT.isInputObjectType)(i)){let a=i.getFields(),o={};for(let c in t){let l=a[c];l!=null&&(o[c]=Ol(l.type,t[c],n,r))}return r!=null?r(i,o):o}}Ma.transformInputValue=Ol;function pee(e,t){return Ol(e,t,(n,r)=>{try{return n.serialize(r)}catch(i){return r}})}Ma.serializeInputValue=pee;function fee(e,t){return Ol(e,t,(n,r)=>{try{return n.parseValue(r)}catch(i){return r}})}Ma.parseInputValue=fee;function mee(e,t){return Ol(e,t,(n,r)=>n.parseLiteral(r,{}))}Ma.parseInputValueLiteral=mee});var Al=w(bl=>{"use strict";m();T();N();Object.defineProperty(bl,"__esModule",{value:!0});bl.correctASTNodes=bl.mapSchema=void 0;var rt=Ae(),Dl=Hv(),bt=oc(),Nee=lT(),NU=Zv();function Tee(e,t={}){let n=hU(EU(eS(TU(Eee(eS(TU(e.getTypeMap(),e,NU.serializeInputValue),e,t,c=>(0,rt.isLeafType)(c)),e,t),e,NU.parseInputValue),e,t,c=>!(0,rt.isLeafType)(c)),e,t),e,t),r=e.getDirectives(),i=hee(r,e,t),{typeMap:a,directives:o}=(0,Nee.rewireTypes)(n,i);return new rt.GraphQLSchema(Y(x({},e.toConfig()),{query:(0,Dl.getObjectTypeFromTypeMap)(a,(0,Dl.getObjectTypeFromTypeMap)(n,e.getQueryType())),mutation:(0,Dl.getObjectTypeFromTypeMap)(a,(0,Dl.getObjectTypeFromTypeMap)(n,e.getMutationType())),subscription:(0,Dl.getObjectTypeFromTypeMap)(a,(0,Dl.getObjectTypeFromTypeMap)(n,e.getSubscriptionType())),types:Object.values(a),directives:o}))}bl.mapSchema=Tee;function eS(e,t,n,r=()=>!0){let i={};for(let a in e)if(!a.startsWith("__")){let o=e[a];if(o==null||!r(o)){i[a]=o;continue}let c=Iee(t,n,a);if(c==null){i[a]=o;continue}let l=c(o,t);if(l===void 0){i[a]=o;continue}i[a]=l}return i}function Eee(e,t,n){let r=Oee(n);return r?eS(e,t,{[bt.MapperKind.ENUM_TYPE]:i=>{let a=i.toConfig(),o=a.values,c={};for(let l in o){let p=o[l],f=r(p,i.name,t,l);if(f===void 0)c[l]=p;else if(Array.isArray(f)){let[y,g]=f;c[y]=g===void 0?p:g}else f!==null&&(c[l]=f)}return Pp(new rt.GraphQLEnumType(Y(x({},a),{values:c})))}},i=>(0,rt.isEnumType)(i)):e}function TU(e,t,n){let r=hU(e,t,{[bt.MapperKind.ARGUMENT]:i=>{if(i.defaultValue===void 0)return i;let a=pT(e,i.type);if(a!=null)return Y(x({},i),{defaultValue:n(a,i.defaultValue)})}});return EU(r,t,{[bt.MapperKind.INPUT_OBJECT_FIELD]:i=>{if(i.defaultValue===void 0)return i;let a=pT(r,i.type);if(a!=null)return Y(x({},i),{defaultValue:n(a,i.defaultValue)})}})}function pT(e,t){if((0,rt.isListType)(t)){let n=pT(e,t.ofType);return n!=null?new rt.GraphQLList(n):null}else if((0,rt.isNonNullType)(t)){let n=pT(e,t.ofType);return n!=null?new rt.GraphQLNonNull(n):null}else if((0,rt.isNamedType)(t)){let n=e[t.name];return n!=null?n:null}return null}function EU(e,t,n){let r={};for(let i in e)if(!i.startsWith("__")){let a=e[i];if(!(0,rt.isObjectType)(a)&&!(0,rt.isInterfaceType)(a)&&!(0,rt.isInputObjectType)(a)){r[i]=a;continue}let o=_ee(t,n,i);if(o==null){r[i]=a;continue}let c=a.toConfig(),l=c.fields,p={};for(let f in l){let y=l[f],g=o(y,f,i,t);if(g===void 0)p[f]=y;else if(Array.isArray(g)){let[v,F]=g;F.astNode!=null&&(F.astNode=Y(x({},F.astNode),{name:Y(x({},F.astNode.name),{value:v})})),p[v]=F===void 0?y:F}else g!==null&&(p[f]=g)}(0,rt.isObjectType)(a)?r[i]=Pp(new rt.GraphQLObjectType(Y(x({},c),{fields:p}))):(0,rt.isInterfaceType)(a)?r[i]=Pp(new rt.GraphQLInterfaceType(Y(x({},c),{fields:p}))):r[i]=Pp(new rt.GraphQLInputObjectType(Y(x({},c),{fields:p})))}return r}function hU(e,t,n){let r={};for(let i in e)if(!i.startsWith("__")){let a=e[i];if(!(0,rt.isObjectType)(a)&&!(0,rt.isInterfaceType)(a)){r[i]=a;continue}let o=vee(n);if(o==null){r[i]=a;continue}let c=a.toConfig(),l=c.fields,p={};for(let f in l){let y=l[f],g=y.args;if(g==null){p[f]=y;continue}let v=Object.keys(g);if(!v.length){p[f]=y;continue}let F={};for(let k of v){let K=g[k],$=o(K,f,i,t);if($===void 0)F[k]=K;else if(Array.isArray($)){let[ne,z]=$;F[ne]=z}else $!==null&&(F[k]=$)}p[f]=Y(x({},y),{args:F})}(0,rt.isObjectType)(a)?r[i]=new rt.GraphQLObjectType(Y(x({},c),{fields:p})):(0,rt.isInterfaceType)(a)?r[i]=new rt.GraphQLInterfaceType(Y(x({},c),{fields:p})):r[i]=new rt.GraphQLInputObjectType(Y(x({},c),{fields:p}))}return r}function hee(e,t,n){let r=See(n);if(r==null)return e.slice();let i=[];for(let a of e){let o=r(a,t);o===void 0?i.push(a):o!==null&&i.push(o)}return i}function yee(e,t){var i,a,o;let n=e.getType(t),r=[bt.MapperKind.TYPE];return(0,rt.isObjectType)(n)?(r.push(bt.MapperKind.COMPOSITE_TYPE,bt.MapperKind.OBJECT_TYPE),t===((i=e.getQueryType())==null?void 0:i.name)?r.push(bt.MapperKind.ROOT_OBJECT,bt.MapperKind.QUERY):t===((a=e.getMutationType())==null?void 0:a.name)?r.push(bt.MapperKind.ROOT_OBJECT,bt.MapperKind.MUTATION):t===((o=e.getSubscriptionType())==null?void 0:o.name)&&r.push(bt.MapperKind.ROOT_OBJECT,bt.MapperKind.SUBSCRIPTION)):(0,rt.isInputObjectType)(n)?r.push(bt.MapperKind.INPUT_OBJECT_TYPE):(0,rt.isInterfaceType)(n)?r.push(bt.MapperKind.COMPOSITE_TYPE,bt.MapperKind.ABSTRACT_TYPE,bt.MapperKind.INTERFACE_TYPE):(0,rt.isUnionType)(n)?r.push(bt.MapperKind.COMPOSITE_TYPE,bt.MapperKind.ABSTRACT_TYPE,bt.MapperKind.UNION_TYPE):(0,rt.isEnumType)(n)?r.push(bt.MapperKind.ENUM_TYPE):(0,rt.isScalarType)(n)&&r.push(bt.MapperKind.SCALAR_TYPE),r}function Iee(e,t,n){let r=yee(e,n),i,a=[...r];for(;!i&&a.length>0;){let o=a.pop();i=t[o]}return i!=null?i:null}function gee(e,t){var i,a,o;let n=e.getType(t),r=[bt.MapperKind.FIELD];return(0,rt.isObjectType)(n)?(r.push(bt.MapperKind.COMPOSITE_FIELD,bt.MapperKind.OBJECT_FIELD),t===((i=e.getQueryType())==null?void 0:i.name)?r.push(bt.MapperKind.ROOT_FIELD,bt.MapperKind.QUERY_ROOT_FIELD):t===((a=e.getMutationType())==null?void 0:a.name)?r.push(bt.MapperKind.ROOT_FIELD,bt.MapperKind.MUTATION_ROOT_FIELD):t===((o=e.getSubscriptionType())==null?void 0:o.name)&&r.push(bt.MapperKind.ROOT_FIELD,bt.MapperKind.SUBSCRIPTION_ROOT_FIELD)):(0,rt.isInterfaceType)(n)?r.push(bt.MapperKind.COMPOSITE_FIELD,bt.MapperKind.INTERFACE_FIELD):(0,rt.isInputObjectType)(n)&&r.push(bt.MapperKind.INPUT_OBJECT_FIELD),r}function _ee(e,t,n){let r=gee(e,n),i,a=[...r];for(;!i&&a.length>0;){let o=a.pop();i=t[o]}return i!=null?i:null}function vee(e){let t=e[bt.MapperKind.ARGUMENT];return t!=null?t:null}function See(e){let t=e[bt.MapperKind.DIRECTIVE];return t!=null?t:null}function Oee(e){let t=e[bt.MapperKind.ENUM_VALUE];return t!=null?t:null}function Pp(e){if((0,rt.isObjectType)(e)){let t=e.toConfig();if(t.astNode!=null){let n=[];for(let r in t.fields){let i=t.fields[r];i.astNode!=null&&n.push(i.astNode)}t.astNode=Y(x({},t.astNode),{kind:rt.Kind.OBJECT_TYPE_DEFINITION,fields:n})}return t.extensionASTNodes!=null&&(t.extensionASTNodes=t.extensionASTNodes.map(n=>Y(x({},n),{kind:rt.Kind.OBJECT_TYPE_EXTENSION,fields:void 0}))),new rt.GraphQLObjectType(t)}else if((0,rt.isInterfaceType)(e)){let t=e.toConfig();if(t.astNode!=null){let n=[];for(let r in t.fields){let i=t.fields[r];i.astNode!=null&&n.push(i.astNode)}t.astNode=Y(x({},t.astNode),{kind:rt.Kind.INTERFACE_TYPE_DEFINITION,fields:n})}return t.extensionASTNodes!=null&&(t.extensionASTNodes=t.extensionASTNodes.map(n=>Y(x({},n),{kind:rt.Kind.INTERFACE_TYPE_EXTENSION,fields:void 0}))),new rt.GraphQLInterfaceType(t)}else if((0,rt.isInputObjectType)(e)){let t=e.toConfig();if(t.astNode!=null){let n=[];for(let r in t.fields){let i=t.fields[r];i.astNode!=null&&n.push(i.astNode)}t.astNode=Y(x({},t.astNode),{kind:rt.Kind.INPUT_OBJECT_TYPE_DEFINITION,fields:n})}return t.extensionASTNodes!=null&&(t.extensionASTNodes=t.extensionASTNodes.map(n=>Y(x({},n),{kind:rt.Kind.INPUT_OBJECT_TYPE_EXTENSION,fields:void 0}))),new rt.GraphQLInputObjectType(t)}else if((0,rt.isEnumType)(e)){let t=e.toConfig();if(t.astNode!=null){let n=[];for(let r in t.values){let i=t.values[r];i.astNode!=null&&n.push(i.astNode)}t.astNode=Y(x({},t.astNode),{values:n})}return t.extensionASTNodes!=null&&(t.extensionASTNodes=t.extensionASTNodes.map(n=>Y(x({},n),{values:void 0}))),new rt.GraphQLEnumType(t)}else return e}bl.correctASTNodes=Pp});var yU=w(mT=>{"use strict";m();T();N();Object.defineProperty(mT,"__esModule",{value:!0});mT.filterSchema=void 0;var fT=Ae(),hs=oc(),Dee=Al();function bee({schema:e,typeFilter:t=()=>!0,fieldFilter:n=void 0,rootFieldFilter:r=void 0,objectFieldFilter:i=void 0,interfaceFieldFilter:a=void 0,inputObjectFieldFilter:o=void 0,argumentFilter:c=void 0}){return(0,Dee.mapSchema)(e,{[hs.MapperKind.QUERY]:p=>tS(p,"Query",r,c),[hs.MapperKind.MUTATION]:p=>tS(p,"Mutation",r,c),[hs.MapperKind.SUBSCRIPTION]:p=>tS(p,"Subscription",r,c),[hs.MapperKind.OBJECT_TYPE]:p=>t(p.name,p)?nS(fT.GraphQLObjectType,p,i||n,c):null,[hs.MapperKind.INTERFACE_TYPE]:p=>t(p.name,p)?nS(fT.GraphQLInterfaceType,p,a||n,c):null,[hs.MapperKind.INPUT_OBJECT_TYPE]:p=>t(p.name,p)?nS(fT.GraphQLInputObjectType,p,o||n):null,[hs.MapperKind.UNION_TYPE]:p=>t(p.name,p)?void 0:null,[hs.MapperKind.ENUM_TYPE]:p=>t(p.name,p)?void 0:null,[hs.MapperKind.SCALAR_TYPE]:p=>t(p.name,p)?void 0:null})}mT.filterSchema=bee;function tS(e,t,n,r){if(n||r){let i=e.toConfig();for(let a in i.fields){let o=i.fields[a];if(n&&!n(t,a,i.fields[a]))delete i.fields[a];else if(r&&o.args)for(let c in o.args)r(t,a,c,o.args[c])||delete o.args[c]}return new fT.GraphQLObjectType(i)}return e}function nS(e,t,n,r){if(n||r){let i=t.toConfig();for(let a in i.fields){let o=i.fields[a];if(n&&!n(t.name,a,i.fields[a]))delete i.fields[a];else if(r&&"args"in o)for(let c in o.args)r(t.name,a,c,o.args[c])||delete o.args[c]}return new e(i)}}});var gU=w(Rl=>{"use strict";m();T();N();Object.defineProperty(Rl,"__esModule",{value:!0});Rl.healTypes=Rl.healSchema=void 0;var xa=Ae();function Aee(e){return IU(e.getTypeMap(),e.getDirectives()),e}Rl.healSchema=Aee;function IU(e,t){let n=Object.create(null);for(let p in e){let f=e[p];if(f==null||p.startsWith("__"))continue;let y=f.name;if(!y.startsWith("__")){if(n[y]!=null){console.warn(`Duplicate schema type name ${y} found; keeping the existing one found in the schema`);continue}n[y]=f}}for(let p in n){let f=n[p];e[p]=f}for(let p of t)p.args=p.args.filter(f=>(f.type=l(f.type),f.type!==null));for(let p in e){let f=e[p];!p.startsWith("__")&&p in n&&f!=null&&r(f)}for(let p in e)!p.startsWith("__")&&!(p in n)&&delete e[p];function r(p){if((0,xa.isObjectType)(p)){i(p),a(p);return}else if((0,xa.isInterfaceType)(p)){i(p),"getInterfaces"in p&&a(p);return}else if((0,xa.isUnionType)(p)){c(p);return}else if((0,xa.isInputObjectType)(p)){o(p);return}else if((0,xa.isLeafType)(p))return;throw new Error(`Unexpected schema type: ${p}`)}function i(p){let f=p.getFields();for(let[y,g]of Object.entries(f))g.args.map(v=>(v.type=l(v.type),v.type===null?null:v)).filter(Boolean),g.type=l(g.type),g.type===null&&delete f[y]}function a(p){if("getInterfaces"in p){let f=p.getInterfaces();f.push(...f.splice(0).map(y=>l(y)).filter(Boolean))}}function o(p){let f=p.getFields();for(let[y,g]of Object.entries(f))g.type=l(g.type),g.type===null&&delete f[y]}function c(p){let f=p.getTypes();f.push(...f.splice(0).map(y=>l(y)).filter(Boolean))}function l(p){if((0,xa.isListType)(p)){let f=l(p.ofType);return f!=null?new xa.GraphQLList(f):null}else if((0,xa.isNonNullType)(p)){let f=l(p.ofType);return f!=null?new xa.GraphQLNonNull(f):null}else if((0,xa.isNamedType)(p)){let f=e[p.name];if(f&&p!==f)return f}return p}}Rl.healTypes=IU});var _U=w(NT=>{"use strict";m();T();N();Object.defineProperty(NT,"__esModule",{value:!0});NT.getResolversFromSchema=void 0;var uc=Ae();function Ree(e,t){var i,a;let n=Object.create(null),r=e.getTypeMap();for(let o in r)if(!o.startsWith("__")){let c=r[o];if((0,uc.isScalarType)(c)){if(!(0,uc.isSpecifiedScalarType)(c)){let l=c.toConfig();delete l.astNode,n[o]=new uc.GraphQLScalarType(l)}}else if((0,uc.isEnumType)(c)){n[o]={};let l=c.getValues();for(let p of l)n[o][p.name]=p.value}else if((0,uc.isInterfaceType)(c))c.resolveType!=null&&(n[o]={__resolveType:c.resolveType});else if((0,uc.isUnionType)(c))c.resolveType!=null&&(n[o]={__resolveType:c.resolveType});else if((0,uc.isObjectType)(c)){n[o]={},c.isTypeOf!=null&&(n[o].__isTypeOf=c.isTypeOf);let l=c.getFields();for(let p in l){let f=l[p];if(f.subscribe!=null&&(n[o][p]=n[o][p]||{},n[o][p].subscribe=f.subscribe),f.resolve!=null&&((i=f.resolve)==null?void 0:i.name)!=="defaultFieldResolver"){switch((a=f.resolve)==null?void 0:a.name){case"defaultMergedResolver":if(!t)continue;break;case"defaultFieldResolver":continue}n[o][p]=n[o][p]||{},n[o][p].resolve=f.resolve}}}}return n}NT.getResolversFromSchema=Ree});var SU=w(TT=>{"use strict";m();T();N();Object.defineProperty(TT,"__esModule",{value:!0});TT.forEachField=void 0;var vU=Ae();function Pee(e,t){let n=e.getTypeMap();for(let r in n){let i=n[r];if(!(0,vU.getNamedType)(i).name.startsWith("__")&&(0,vU.isObjectType)(i)){let a=i.getFields();for(let o in a){let c=a[o];t(c,r,o)}}}}TT.forEachField=Pee});var OU=w(ET=>{"use strict";m();T();N();Object.defineProperty(ET,"__esModule",{value:!0});ET.forEachDefaultValue=void 0;var rS=Ae();function Fee(e,t){let n=e.getTypeMap();for(let r in n){let i=n[r];if(!(0,rS.getNamedType)(i).name.startsWith("__")){if((0,rS.isObjectType)(i)){let a=i.getFields();for(let o in a){let c=a[o];for(let l of c.args)l.defaultValue=t(l.type,l.defaultValue)}}else if((0,rS.isInputObjectType)(i)){let a=i.getFields();for(let o in a){let c=a[o];c.defaultValue=t(c.type,c.defaultValue)}}}}}ET.forEachDefaultValue=Fee});var sS=w(hT=>{"use strict";m();T();N();Object.defineProperty(hT,"__esModule",{value:!0});hT.addTypes=void 0;var iS=Ae(),aS=Hv(),wee=lT();function Lee(e,t){let n=e.toConfig(),r={};for(let c of n.types)r[c.name]=c;let i={};for(let c of n.directives)i[c.name]=c;for(let c of t)(0,iS.isNamedType)(c)?r[c.name]=c:(0,iS.isDirective)(c)&&(i[c.name]=c);let{typeMap:a,directives:o}=(0,wee.rewireTypes)(r,Object.values(i));return new iS.GraphQLSchema(Y(x({},n),{query:(0,aS.getObjectTypeFromTypeMap)(a,e.getQueryType()),mutation:(0,aS.getObjectTypeFromTypeMap)(a,e.getMutationType()),subscription:(0,aS.getObjectTypeFromTypeMap)(a,e.getSubscriptionType()),types:Object.values(a),directives:o}))}hT.addTypes=Lee});var bU=w(IT=>{"use strict";m();T();N();Object.defineProperty(IT,"__esModule",{value:!0});IT.pruneSchema=void 0;var Zn=Ae(),Cee=Cv(),Bee=oc(),Uee=Al(),kee=Sp();function Mee(e,t={}){let{skipEmptyCompositeTypePruning:n,skipEmptyUnionPruning:r,skipPruning:i,skipUnimplementedInterfacesPruning:a,skipUnusedTypesPruning:o}=t,c=[],l=e;do{let p=xee(l);if(i){let f=[];for(let y in l.getTypeMap()){if(y.startsWith("__"))continue;let g=l.getType(y);g&&i(g)&&f.push(y)}p=DU(f,l,p)}c=[],l=(0,Uee.mapSchema)(l,{[Bee.MapperKind.TYPE]:f=>!p.has(f.name)&&!(0,Zn.isSpecifiedScalarType)(f)?((0,Zn.isUnionType)(f)||(0,Zn.isInputObjectType)(f)||(0,Zn.isInterfaceType)(f)||(0,Zn.isObjectType)(f)||(0,Zn.isScalarType)(f))&&(o||(0,Zn.isUnionType)(f)&&r&&!Object.keys(f.getTypes()).length||((0,Zn.isInputObjectType)(f)||(0,Zn.isInterfaceType)(f)||(0,Zn.isObjectType)(f))&&n&&!Object.keys(f.getFields()).length||(0,Zn.isInterfaceType)(f)&&a)?f:(c.push(f.name),p.delete(f.name),null):f})}while(c.length);return l}IT.pruneSchema=Mee;function xee(e){let t=[];for(let n of(0,kee.getRootTypes)(e))t.push(n.name);return DU(t,e)}function DU(e,t,n=new Set){let r=new Map;for(;e.length;){let i=e.pop();if(n.has(i)&&r[i]!==!0)continue;let a=t.getType(i);if(a){if((0,Zn.isUnionType)(a)&&e.push(...a.getTypes().map(o=>o.name)),(0,Zn.isInterfaceType)(a)&&r[i]===!0&&(e.push(...(0,Cee.getImplementingTypes)(a.name,t)),r[i]=!1),(0,Zn.isEnumType)(a)&&e.push(...a.getValues().flatMap(o=>o.astNode?yT(t,o.astNode):[])),"getInterfaces"in a&&e.push(...a.getInterfaces().map(o=>o.name)),"getFields"in a){let o=a.getFields(),c=Object.entries(o);if(!c.length)continue;for(let[,l]of c){(0,Zn.isObjectType)(a)&&e.push(...l.args.flatMap(f=>{let y=[(0,Zn.getNamedType)(f.type).name];return f.astNode&&y.push(...yT(t,f.astNode)),y}));let p=(0,Zn.getNamedType)(l.type);e.push(p.name),l.astNode&&e.push(...yT(t,l.astNode)),(0,Zn.isInterfaceType)(p)&&!(p.name in r)&&(r[p.name]=!0)}}a.astNode&&e.push(...yT(t,a.astNode)),n.add(i)}}return n}function yT(e,t){var n;return((n=t.directives)!=null?n:[]).flatMap(r=>{var i,a;return(a=(i=e.getDirective(r.name.value))==null?void 0:i.args.map(o=>(0,Zn.getNamedType)(o.type).name))!=null?a:[]})}});var RU=w(gT=>{"use strict";m();T();N();Object.defineProperty(gT,"__esModule",{value:!0});gT.mergeDeep=void 0;var qee=Ip();function AU(e,t=!1,n=!1){let r=e[0]||{},i={};t&&Object.setPrototypeOf(i,Object.create(Object.getPrototypeOf(r)));for(let a of e)if(oS(r)&&oS(a)){if(t){let o=Object.getPrototypeOf(i),c=Object.getPrototypeOf(a);if(c)for(let l of Object.getOwnPropertyNames(c)){let p=Object.getOwnPropertyDescriptor(c,l);(0,qee.isSome)(p)&&Object.defineProperty(o,l,p)}}for(let o in a)oS(a[o])?o in i?i[o]=AU([i[o],a[o]],t,n):Object.assign(i,{[o]:a[o]}):n&&Array.isArray(i[o])?Array.isArray(a[o])?i[o].push(...a[o]):i[o].push(a[o]):Object.assign(i,{[o]:a[o]})}else if(n&&Array.isArray(r))Array.isArray(a)?r.push(...a):r.push(a);else if(n&&Array.isArray(a))return[r,...a];return i}gT.mergeDeep=AU;function oS(e){return e&&typeof e=="object"&&!Array.isArray(e)}});var PU=w(_T=>{"use strict";m();T();N();Object.defineProperty(_T,"__esModule",{value:!0});_T.parseSelectionSet=void 0;var Vee=Ae();function jee(e,t){return(0,Vee.parse)(e,t).definitions[0].selectionSet}_T.parseSelectionSet=jee});var FU=w(vT=>{"use strict";m();T();N();Object.defineProperty(vT,"__esModule",{value:!0});vT.getResponseKeyFromInfo=void 0;function Kee(e){return e.fieldNodes[0].alias!=null?e.fieldNodes[0].alias.value:e.fieldName}vT.getResponseKeyFromInfo=Kee});var wU=w(qa=>{"use strict";m();T();N();Object.defineProperty(qa,"__esModule",{value:!0});qa.modifyObjectFields=qa.selectObjectFields=qa.removeObjectFields=qa.appendObjectFields=void 0;var ST=Ae(),Gee=sS(),OT=oc(),cc=Al();function $ee(e,t,n){return e.getType(t)==null?(0,Gee.addTypes)(e,[new ST.GraphQLObjectType({name:t,fields:n})]):(0,cc.mapSchema)(e,{[OT.MapperKind.OBJECT_TYPE]:r=>{if(r.name===t){let i=r.toConfig(),a=i.fields,o={};for(let c in a)o[c]=a[c];for(let c in n)o[c]=n[c];return(0,cc.correctASTNodes)(new ST.GraphQLObjectType(Y(x({},i),{fields:o})))}}})}qa.appendObjectFields=$ee;function Qee(e,t,n){let r={};return[(0,cc.mapSchema)(e,{[OT.MapperKind.OBJECT_TYPE]:a=>{if(a.name===t){let o=a.toConfig(),c=o.fields,l={};for(let p in c){let f=c[p];n(p,f)?r[p]=f:l[p]=f}return(0,cc.correctASTNodes)(new ST.GraphQLObjectType(Y(x({},o),{fields:l})))}}}),r]}qa.removeObjectFields=Qee;function Yee(e,t,n){let r={};return(0,cc.mapSchema)(e,{[OT.MapperKind.OBJECT_TYPE]:i=>{if(i.name===t){let o=i.toConfig().fields;for(let c in o){let l=o[c];n(c,l)&&(r[c]=l)}}}}),r}qa.selectObjectFields=Yee;function Jee(e,t,n,r){let i={};return[(0,cc.mapSchema)(e,{[OT.MapperKind.OBJECT_TYPE]:o=>{if(o.name===t){let c=o.toConfig(),l=c.fields,p={};for(let f in l){let y=l[f];n(f,y)?i[f]=y:p[f]=y}for(let f in r){let y=r[f];p[f]=y}return(0,cc.correctASTNodes)(new ST.GraphQLObjectType(Y(x({},c),{fields:p})))}}}),i]}qa.modifyObjectFields=Jee});var LU=w(DT=>{"use strict";m();T();N();Object.defineProperty(DT,"__esModule",{value:!0});DT.renameType=void 0;var Mi=Ae();function Hee(e,t){if((0,Mi.isObjectType)(e))return new Mi.GraphQLObjectType(Y(x({},e.toConfig()),{name:t,astNode:e.astNode==null?e.astNode:Y(x({},e.astNode),{name:Y(x({},e.astNode.name),{value:t})}),extensionASTNodes:e.extensionASTNodes==null?e.extensionASTNodes:e.extensionASTNodes.map(n=>Y(x({},n),{name:Y(x({},n.name),{value:t})}))}));if((0,Mi.isInterfaceType)(e))return new Mi.GraphQLInterfaceType(Y(x({},e.toConfig()),{name:t,astNode:e.astNode==null?e.astNode:Y(x({},e.astNode),{name:Y(x({},e.astNode.name),{value:t})}),extensionASTNodes:e.extensionASTNodes==null?e.extensionASTNodes:e.extensionASTNodes.map(n=>Y(x({},n),{name:Y(x({},n.name),{value:t})}))}));if((0,Mi.isUnionType)(e))return new Mi.GraphQLUnionType(Y(x({},e.toConfig()),{name:t,astNode:e.astNode==null?e.astNode:Y(x({},e.astNode),{name:Y(x({},e.astNode.name),{value:t})}),extensionASTNodes:e.extensionASTNodes==null?e.extensionASTNodes:e.extensionASTNodes.map(n=>Y(x({},n),{name:Y(x({},n.name),{value:t})}))}));if((0,Mi.isInputObjectType)(e))return new Mi.GraphQLInputObjectType(Y(x({},e.toConfig()),{name:t,astNode:e.astNode==null?e.astNode:Y(x({},e.astNode),{name:Y(x({},e.astNode.name),{value:t})}),extensionASTNodes:e.extensionASTNodes==null?e.extensionASTNodes:e.extensionASTNodes.map(n=>Y(x({},n),{name:Y(x({},n.name),{value:t})}))}));if((0,Mi.isEnumType)(e))return new Mi.GraphQLEnumType(Y(x({},e.toConfig()),{name:t,astNode:e.astNode==null?e.astNode:Y(x({},e.astNode),{name:Y(x({},e.astNode.name),{value:t})}),extensionASTNodes:e.extensionASTNodes==null?e.extensionASTNodes:e.extensionASTNodes.map(n=>Y(x({},n),{name:Y(x({},n.name),{value:t})}))}));if((0,Mi.isScalarType)(e))return new Mi.GraphQLScalarType(Y(x({},e.toConfig()),{name:t,astNode:e.astNode==null?e.astNode:Y(x({},e.astNode),{name:Y(x({},e.astNode.name),{value:t})}),extensionASTNodes:e.extensionASTNodes==null?e.extensionASTNodes:e.extensionASTNodes.map(n=>Y(x({},n),{name:Y(x({},n.name),{value:t})}))}));throw new Error(`Unknown type ${e}.`)}DT.renameType=Hee});var UU=w(bT=>{"use strict";m();T();N();Object.defineProperty(bT,"__esModule",{value:!0});bT.mapAsyncIterator=void 0;var zee=_p();function Wee(e,t,n,r){let i,a,o;r&&(o=p=>{let f=r();return(0,zee.isPromise)(f)?f.then(()=>p):p}),typeof e.return=="function"&&(i=e.return,a=p=>{let f=()=>Promise.reject(p);return i.call(e).then(f,f)});function c(p){return p.done?o?o(p):p:CU(p.value,t).then(BU,a)}let l;if(n){let p=n;l=f=>CU(f,p).then(BU,a)}return{next(){return e.next().then(c,l)},return(){let p=i?i.call(e).then(c,l):Promise.resolve({value:void 0,done:!0});return o?p.then(o):p},throw(p){return typeof e.throw=="function"?e.throw(p).then(c,l):Promise.reject(p).catch(a)},[Symbol.asyncIterator](){return this}}}bT.mapAsyncIterator=Wee;function CU(e,t){return new Promise(n=>n(t(e)))}function BU(e){return{value:e,done:!1}}});var kU=w(Pl=>{"use strict";m();T();N();Object.defineProperty(Pl,"__esModule",{value:!0});Pl.createVariableNameGenerator=Pl.updateArgument=void 0;var lc=Ae(),Xee=Uv();function Zee(e,t,n,r,i,a,o){if(e[r]={kind:lc.Kind.ARGUMENT,name:{kind:lc.Kind.NAME,value:r},value:{kind:lc.Kind.VARIABLE,name:{kind:lc.Kind.NAME,value:i}}},t[i]={kind:lc.Kind.VARIABLE_DEFINITION,variable:{kind:lc.Kind.VARIABLE,name:{kind:lc.Kind.NAME,value:i}},type:(0,Xee.astFromType)(a)},o!==void 0){n[i]=o;return}i in n&&delete n[i]}Pl.updateArgument=Zee;function ete(e){let t=0;return n=>{let r;do r=`_v${(t++).toString()}_${n}`;while(r in e);return r}}Pl.createVariableNameGenerator=ete});var MU=w(AT=>{"use strict";m();T();N();Object.defineProperty(AT,"__esModule",{value:!0});AT.implementsAbstractType=void 0;var uS=Ae();function tte(e,t,n){return n==null||t==null?!1:t===n?!0:(0,uS.isCompositeType)(t)&&(0,uS.isCompositeType)(n)?(0,uS.doTypesOverlap)(e,t,n):!1}AT.implementsAbstractType=tte});var xU=w(RT=>{"use strict";m();T();N();Object.defineProperty(RT,"__esModule",{value:!0});RT.observableToAsyncIterable=void 0;function nte(e){let t=[],n=[],r=!0,i=f=>{t.length!==0?t.shift()({value:f,done:!1}):n.push({value:f,done:!1})},a=f=>{t.length!==0?t.shift()({value:{errors:[f]},done:!1}):n.push({value:{errors:[f]},done:!1})},o=()=>{t.length!==0?t.shift()({done:!0}):n.push({done:!0})},c=()=>new Promise(f=>{if(n.length!==0){let y=n.shift();f(y)}else t.push(f)}),l=e.subscribe({next(f){i(f)},error(f){a(f)},complete(){o()}}),p=()=>{if(r){r=!1,l.unsubscribe();for(let f of t)f({value:void 0,done:!0});t.length=0,n.length=0}};return{next(){return r?c():this.return()},return(){return p(),Promise.resolve({value:void 0,done:!0})},throw(f){return p(),Promise.reject(f)},[Symbol.asyncIterator](){return this}}}RT.observableToAsyncIterable=nte});var qU=w(PT=>{"use strict";m();T();N();Object.defineProperty(PT,"__esModule",{value:!0});PT.AccumulatorMap=void 0;var cS=class extends Map{get[Symbol.toStringTag](){return"AccumulatorMap"}add(t,n){let r=this.get(t);r===void 0?this.set(t,[n]):r.push(n)}};PT.AccumulatorMap=cS});var lS=w(Fl=>{"use strict";m();T();N();Object.defineProperty(Fl,"__esModule",{value:!0});Fl.GraphQLStreamDirective=Fl.GraphQLDeferDirective=void 0;var xi=Ae();Fl.GraphQLDeferDirective=new xi.GraphQLDirective({name:"defer",description:"Directs the executor to defer this fragment when the `if` argument is true or undefined.",locations:[xi.DirectiveLocation.FRAGMENT_SPREAD,xi.DirectiveLocation.INLINE_FRAGMENT],args:{if:{type:new xi.GraphQLNonNull(xi.GraphQLBoolean),description:"Deferred when true or undefined.",defaultValue:!0},label:{type:xi.GraphQLString,description:"Unique name"}}});Fl.GraphQLStreamDirective=new xi.GraphQLDirective({name:"stream",description:"Directs the executor to stream plural fields when the `if` argument is true or undefined.",locations:[xi.DirectiveLocation.FIELD],args:{if:{type:new xi.GraphQLNonNull(xi.GraphQLBoolean),description:"Stream when true or undefined.",defaultValue:!0},label:{type:xi.GraphQLString,description:"Unique name"},initialCount:{defaultValue:0,type:xi.GraphQLInt,description:"Number of items to return immediately"}}})});var fS=w(zr=>{"use strict";m();T();N();Object.defineProperty(zr,"__esModule",{value:!0});zr.collectSubFields=zr.getDeferValues=zr.getFieldEntryKey=zr.doesFragmentConditionMatch=zr.shouldIncludeNode=zr.collectFields=void 0;var Va=Ae(),wT=qU(),rte=lS(),ite=_l();function wl(e,t,n,r,i,a,o,c){for(let l of i.selections)switch(l.kind){case Va.Kind.FIELD:{if(!FT(n,l))continue;a.add(VU(l),l);break}case Va.Kind.INLINE_FRAGMENT:{if(!FT(n,l)||!dS(e,l,r))continue;let p=pS(n,l);if(p){let f=new wT.AccumulatorMap;wl(e,t,n,r,l.selectionSet,f,o,c),o.push({label:p.label,fields:f})}else wl(e,t,n,r,l.selectionSet,a,o,c);break}case Va.Kind.FRAGMENT_SPREAD:{let p=l.name.value;if(!FT(n,l))continue;let f=pS(n,l);if(c.has(p)&&!f)continue;let y=t[p];if(!y||!dS(e,y,r))continue;if(f||c.add(p),f){let g=new wT.AccumulatorMap;wl(e,t,n,r,y.selectionSet,g,o,c),o.push({label:f.label,fields:g})}else wl(e,t,n,r,y.selectionSet,a,o,c);break}}}function ate(e,t,n,r,i){let a=new wT.AccumulatorMap,o=[];return wl(e,t,n,r,i,a,o,new Set),{fields:a,patches:o}}zr.collectFields=ate;function FT(e,t){let n=(0,Va.getDirectiveValues)(Va.GraphQLSkipDirective,t,e);if((n==null?void 0:n.if)===!0)return!1;let r=(0,Va.getDirectiveValues)(Va.GraphQLIncludeDirective,t,e);return(r==null?void 0:r.if)!==!1}zr.shouldIncludeNode=FT;function dS(e,t,n){let r=t.typeCondition;if(!r)return!0;let i=(0,Va.typeFromAST)(e,r);return i===n?!0:(0,Va.isAbstractType)(i)?e.getPossibleTypes(i).includes(n):!1}zr.doesFragmentConditionMatch=dS;function VU(e){return e.alias?e.alias.value:e.name.value}zr.getFieldEntryKey=VU;function pS(e,t){let n=(0,Va.getDirectiveValues)(rte.GraphQLDeferDirective,t,e);if(n&&n.if!==!1)return{label:typeof n.label=="string"?n.label:void 0}}zr.getDeferValues=pS;zr.collectSubFields=(0,ite.memoize5)(function(t,n,r,i,a){let o=new wT.AccumulatorMap,c=new Set,l=[],p={fields:o,patches:l};for(let f of a)f.selectionSet&&wl(t,n,r,i,f.selectionSet,o,l,c);return p})});var mS=w(Ll=>{"use strict";m();T();N();Object.defineProperty(Ll,"__esModule",{value:!0});Ll.getOperationASTFromRequest=Ll.getOperationASTFromDocument=void 0;var ste=Ae(),ote=_l();function jU(e,t){let n=(0,ste.getOperationAST)(e,t);if(!n)throw new Error(`Cannot infer operation ${t||""}`);return n}Ll.getOperationASTFromDocument=jU;Ll.getOperationASTFromRequest=(0,ote.memoize1)(function(t){return jU(t.document,t.operationName)})});var $U=w(lu=>{"use strict";m();T();N();Object.defineProperty(lu,"__esModule",{value:!0});lu.visitResult=lu.visitErrors=lu.visitData=void 0;var cu=Ae(),NS=fS(),ute=mS();function TS(e,t,n){if(Array.isArray(e))return e.map(r=>TS(r,t,n));if(typeof e=="object"){let r=t!=null?t(e):e;if(r!=null)for(let i in r){let a=r[i];Object.defineProperty(r,i,{value:TS(a,t,n)})}return n!=null?n(r):r}return e}lu.visitData=TS;function cte(e,t){return e.map(n=>t(n))}lu.visitErrors=cte;function lte(e,t,n,r,i){let a=t.document.definitions.reduce((g,v)=>(v.kind===cu.Kind.FRAGMENT_DEFINITION&&(g[v.name.value]=v),g),{}),o=t.variables||{},c={segmentInfoMap:new Map,unpathedErrors:new Set},l=e.data,p=e.errors,f=p!=null&&i!=null,y=(0,ute.getOperationASTFromRequest)(t);return l!=null&&y!=null&&(e.data=fte(l,y,n,a,o,r,f?p:void 0,c)),p!=null&&i&&(e.errors=dte(p,i,c)),e}lu.visitResult=lte;function dte(e,t,n){let r=n.segmentInfoMap,i=n.unpathedErrors,a=t.__unpathed;return e.map(o=>{let c=r.get(o),l=c==null?o:c.reduceRight((p,f)=>{let y=f.type.name,g=t[y];if(g==null)return p;let v=g[f.fieldName];return v==null?p:v(p,f.pathIndex)},o);return a&&i.has(o)?a(l):l})}function pte(e,t){switch(t.operation){case"query":return e.getQueryType();case"mutation":return e.getMutationType();case"subscription":return e.getSubscriptionType()}}function fte(e,t,n,r,i,a,o,c){let l=pte(n,t),{fields:p}=(0,NS.collectFields)(n,r,i,l,t.selectionSet);return ES(e,l,p,n,r,i,a,0,o,c)}function ES(e,t,n,r,i,a,o,c,l,p){var ne;let f=t.getFields(),y=o==null?void 0:o[t.name],g=y==null?void 0:y.__enter,v=g!=null?g(e):e,F,k=null;if(l!=null){F=Nte(l,c),k=F.errorMap;for(let z of F.unpathedErrors)p.unpathedErrors.add(z)}for(let[z,Te]of n){let pe=Te[0].name.value,Fe=(ne=f[pe])==null?void 0:ne.type;if(Fe==null)switch(pe){case"__typename":Fe=cu.TypeNameMetaFieldDef.type;break;case"__schema":Fe=cu.SchemaMetaFieldDef.type;break;case"__type":Fe=cu.TypeMetaFieldDef.type;break}let Ve=c+1,et;k&&(et=k[z],et!=null&&delete k[z],Tte(t,pe,Ve,et,p));let X=GU(e[z],Fe,Te,r,i,a,o,Ve,et,p);KU(v,z,X,y,pe)}let K=v.__typename;if(K!=null&&KU(v,"__typename",K,y,"__typename"),k)for(let z in k){let Te=k[z];for(let pe of Te)p.unpathedErrors.add(pe)}let $=y==null?void 0:y.__leave;return $!=null?$(v):v}function KU(e,t,n,r,i){if(r==null){e[t]=n;return}let a=r[i];if(a==null){e[t]=n;return}let o=a(n);if(o===void 0){delete e[t];return}e[t]=o}function mte(e,t,n,r,i,a,o,c,l,p){return e.map(f=>GU(f,t,n,r,i,a,o,c+1,l,p))}function GU(e,t,n,r,i,a,o,c,l=[],p){if(e==null)return e;let f=(0,cu.getNullableType)(t);if((0,cu.isListType)(f))return mte(e,f.ofType,n,r,i,a,o,c,l,p);if((0,cu.isAbstractType)(f)){let v=r.getType(e.__typename),{fields:F}=(0,NS.collectSubFields)(r,i,a,v,n);return ES(e,v,F,r,i,a,o,c,l,p)}else if((0,cu.isObjectType)(f)){let{fields:v}=(0,NS.collectSubFields)(r,i,a,f,n);return ES(e,f,v,r,i,a,o,c,l,p)}let y=o==null?void 0:o[f.name];if(y==null)return e;let g=y(e);return g===void 0?e:g}function Nte(e,t){var i;let n=Object.create(null),r=new Set;for(let a of e){let o=(i=a.path)==null?void 0:i[t];if(o==null){r.add(a);continue}o in n?n[o].push(a):n[o]=[a]}return{errorMap:n,unpathedErrors:r}}function Tte(e,t,n,r=[],i){for(let a of r){let o={type:e,fieldName:t,pathIndex:n},c=i.segmentInfoMap.get(a);c==null?i.segmentInfoMap.set(a,[o]):c.push(o)}}});var QU=w(LT=>{"use strict";m();T();N();Object.defineProperty(LT,"__esModule",{value:!0});LT.valueMatchesCriteria=void 0;function hS(e,t){return e==null?e===t:Array.isArray(e)?Array.isArray(t)&&e.every((n,r)=>hS(n,t[r])):typeof e=="object"?typeof t=="object"&&t&&Object.keys(t).every(n=>hS(e[n],t[n])):t instanceof RegExp?t.test(e):e===t}LT.valueMatchesCriteria=hS});var YU=w(CT=>{"use strict";m();T();N();Object.defineProperty(CT,"__esModule",{value:!0});CT.isAsyncIterable=void 0;function Ete(e){return(e==null?void 0:e[Symbol.asyncIterator])!=null}CT.isAsyncIterable=Ete});var JU=w(BT=>{"use strict";m();T();N();Object.defineProperty(BT,"__esModule",{value:!0});BT.isDocumentNode=void 0;var hte=Ae();function yte(e){return e&&typeof e=="object"&&"kind"in e&&e.kind===hte.Kind.DOCUMENT}BT.isDocumentNode=yte});var HU=w(()=>{"use strict";m();T();N()});var ZU=w(du=>{"use strict";m();T();N();Object.defineProperty(du,"__esModule",{value:!0});du.withCancel=du.getAsyncIterableWithCancel=du.getAsyncIteratorWithCancel=void 0;var Ite=_l();function gte(e){return vi(this,null,function*(){return{value:e,done:!0}})}var zU=(0,Ite.memoize2)(function(t,n){return function(...i){return Reflect.apply(n,t,i)}});function WU(e,t){return new Proxy(e,{has(n,r){return r==="return"?!0:Reflect.has(n,r)},get(n,r,i){let a=Reflect.get(n,r,i);if(r==="return"){let o=a||gte;return function(l){return vi(this,null,function*(){let p=yield t(l);return Reflect.apply(o,n,[p])})}}else if(typeof a=="function")return zU(n,a);return a}})}du.getAsyncIteratorWithCancel=WU;function XU(e,t){return new Proxy(e,{get(n,r,i){let a=Reflect.get(n,r,i);return Symbol.asyncIterator===r?function(){let c=Reflect.apply(a,n,[]);return WU(c,t)}:typeof a=="function"?zU(n,a):a}})}du.getAsyncIterableWithCancel=XU;du.withCancel=XU});var ek=w(UT=>{"use strict";m();T();N();Object.defineProperty(UT,"__esModule",{value:!0});UT.fixSchemaAst=void 0;var _te=Ae(),vte=Kv();function Ste(e,t){let n=(0,vte.getDocumentNodeFromSchema)(e);return(0,_te.buildASTSchema)(n,x({},t||{}))}function Ote(e,t){let n;return(!e.astNode||!e.extensionASTNodes)&&(n=Ste(e,t)),!e.astNode&&(n!=null&&n.astNode)&&(e.astNode=n.astNode),!e.extensionASTNodes&&(n!=null&&n.astNode)&&(e.extensionASTNodes=n.extensionASTNodes),e}UT.fixSchemaAst=Ote});var tk=w(kT=>{"use strict";m();T();N();Object.defineProperty(kT,"__esModule",{value:!0});kT.extractExtensionsFromSchema=void 0;var ys=oc(),Dte=Al();function sa(e={}){let t=x({},e),n=t.directives;if(n!=null)for(let r in n){let i=n[r];Array.isArray(i)||(n[r]=[i])}return t}function bte(e){let t={schemaExtensions:sa(e.extensions),types:{}};return(0,Dte.mapSchema)(e,{[ys.MapperKind.OBJECT_TYPE]:n=>(t.types[n.name]={fields:{},type:"object",extensions:sa(n.extensions)},n),[ys.MapperKind.INTERFACE_TYPE]:n=>(t.types[n.name]={fields:{},type:"interface",extensions:sa(n.extensions)},n),[ys.MapperKind.FIELD]:(n,r,i)=>{t.types[i].fields[r]={arguments:{},extensions:sa(n.extensions)};let a=n.args;if(a!=null)for(let o in a)t.types[i].fields[r].arguments[o]=sa(a[o].extensions);return n},[ys.MapperKind.ENUM_TYPE]:n=>(t.types[n.name]={values:{},type:"enum",extensions:sa(n.extensions)},n),[ys.MapperKind.ENUM_VALUE]:(n,r,i,a)=>(t.types[r].values[a]=sa(n.extensions),n),[ys.MapperKind.SCALAR_TYPE]:n=>(t.types[n.name]={type:"scalar",extensions:sa(n.extensions)},n),[ys.MapperKind.UNION_TYPE]:n=>(t.types[n.name]={type:"union",extensions:sa(n.extensions)},n),[ys.MapperKind.INPUT_OBJECT_TYPE]:n=>(t.types[n.name]={fields:{},type:"input",extensions:sa(n.extensions)},n),[ys.MapperKind.INPUT_OBJECT_FIELD]:(n,r,i)=>(t.types[i].fields[r]={extensions:sa(n.extensions)},n)}),t}kT.extractExtensionsFromSchema=bte});var nk=w(pu=>{"use strict";m();T();N();Object.defineProperty(pu,"__esModule",{value:!0});pu.printPathArray=pu.pathToArray=pu.addPath=void 0;function Ate(e,t,n){return{prev:e,key:t,typename:n}}pu.addPath=Ate;function Rte(e){let t=[],n=e;for(;n;)t.push(n.key),n=n.prev;return t.reverse()}pu.pathToArray=Rte;function Pte(e){return e.map(t=>typeof t=="number"?"["+t.toString()+"]":"."+t).join("")}pu.printPathArray=Pte});var rk=w(yS=>{"use strict";m();T();N();function MT(e,t,n){if(typeof e=="object"&&typeof t=="object"){if(Array.isArray(e)&&Array.isArray(t))for(n=0;n{"use strict";m();T();N();Object.defineProperty(xT,"__esModule",{value:!0});xT.mergeIncrementalResult=void 0;var IS=rk();function ik({incrementalResult:e,executionResult:t}){var r;let n=["data",...(r=e.path)!=null?r:[]];if(e.items)for(let i of e.items)(0,IS.dset)(t,n,i),n[n.length-1]++;e.data&&(0,IS.dset)(t,n,e.data),e.errors&&(t.errors=t.errors||[],t.errors.push(...e.errors)),e.extensions&&(0,IS.dset)(t,"extensions",e.extensions),e.incremental&&e.incremental.forEach(i=>{ik({incrementalResult:i,executionResult:t})})}xT.mergeIncrementalResult=ik});var ok=w(Cl=>{"use strict";m();T();N();Object.defineProperty(Cl,"__esModule",{value:!0});Cl.debugTimerEnd=Cl.debugTimerStart=void 0;var sk=new Set;function wte(e){let t=(globalThis==null?void 0:globalThis.process.env.DEBUG)||globalThis.DEBUG;(t==="1"||t!=null&&t.includes(e))&&(sk.add(e),console.time(e))}Cl.debugTimerStart=wte;function Lte(e){sk.has(e)&&console.timeEnd(e)}Cl.debugTimerEnd=Lte});var oa=w(Ge=>{"use strict";m();T();N();Object.defineProperty(Ge,"__esModule",{value:!0});Ge.inspect=void 0;var Ye=(mB(),om(fB));Ye.__exportStar(NB(),Ge);Ye.__exportStar(Ip(),Ge);Ye.__exportStar(Fv(),Ge);Ye.__exportStar(wv(),Ge);Ye.__exportStar(OB(),Ge);Ye.__exportStar(Cv(),Ge);Ye.__exportStar(Kv(),Ge);Ye.__exportStar(wv(),Ge);Ye.__exportStar(jB(),Ge);Ye.__exportStar(KB(),Ge);Ye.__exportStar(nU(),Ge);Ye.__exportStar(lU(),Ge);Ye.__exportStar(pU(),Ge);Ye.__exportStar(yU(),Ge);Ye.__exportStar(gU(),Ge);Ye.__exportStar(_U(),Ge);Ye.__exportStar(SU(),Ge);Ye.__exportStar(OU(),Ge);Ye.__exportStar(Al(),Ge);Ye.__exportStar(sS(),Ge);Ye.__exportStar(lT(),Ge);Ye.__exportStar(bU(),Ge);Ye.__exportStar(RU(),Ge);Ye.__exportStar(oc(),Ge);Ye.__exportStar(Xv(),Ge);Ye.__exportStar(PU(),Ge);Ye.__exportStar(FU(),Ge);Ye.__exportStar(wU(),Ge);Ye.__exportStar(LU(),Ge);Ye.__exportStar(Zv(),Ge);Ye.__exportStar(UU(),Ge);Ye.__exportStar(kU(),Ge);Ye.__exportStar(MU(),Ge);Ye.__exportStar($N(),Ge);Ye.__exportStar(xU(),Ge);Ye.__exportStar($U(),Ge);Ye.__exportStar(Pv(),Ge);Ye.__exportStar(QU(),Ge);Ye.__exportStar(YU(),Ge);Ye.__exportStar(JU(),Ge);Ye.__exportStar(ZN(),Ge);Ye.__exportStar(HU(),Ge);Ye.__exportStar(ZU(),Ge);Ye.__exportStar(Sp(),Ge);Ye.__exportStar($v(),Ge);Ye.__exportStar(fS(),Ge);var Cte=gp();Object.defineProperty(Ge,"inspect",{enumerable:!0,get:function(){return Cte.inspect}});Ye.__exportStar(_l(),Ge);Ye.__exportStar(ek(),Ge);Ye.__exportStar(mS(),Ge);Ye.__exportStar(tk(),Ge);Ye.__exportStar(nk(),Ge);Ye.__exportStar(_p(),Ge);Ye.__exportStar(lS(),Ge);Ye.__exportStar(ak(),Ge);Ye.__exportStar(ok(),Ge)});var ck=w(qT=>{"use strict";m();T();N();Object.defineProperty(qT,"__esModule",{value:!0});qT.mergeResolvers=void 0;var Bte=oa();function uk(e,t){if(!e||Array.isArray(e)&&e.length===0)return{};if(!Array.isArray(e))return e;if(e.length===1)return e[0]||{};let n=new Array;for(let i of e)Array.isArray(i)&&(i=uk(i)),typeof i=="object"&&i&&n.push(i);let r=(0,Bte.mergeDeep)(n,!0);if(t!=null&&t.exclusions)for(let i of t.exclusions){let[a,o]=i.split(".");!o||o==="*"?delete r[a]:r[a]&&delete r[a][o]}return r}qT.mergeResolvers=uk});var gS=w(VT=>{"use strict";m();T();N();Object.defineProperty(VT,"__esModule",{value:!0});VT.mergeArguments=void 0;var lk=oa();function Ute(e,t,n){let r=kte([...t,...e].filter(lk.isSome),n);return n&&n.sort&&r.sort(lk.compareNodes),r}VT.mergeArguments=Ute;function kte(e,t){return e.reduce((n,r)=>{let i=n.findIndex(a=>a.name.value===r.name.value);return i===-1?n.concat([r]):(t!=null&&t.reverseArguments||(n[i]=r),n)},[])}});var qi=w(Bl=>{"use strict";m();T();N();Object.defineProperty(Bl,"__esModule",{value:!0});Bl.mergeDirective=Bl.mergeDirectives=void 0;var dk=Ae(),Mte=oa();function xte(e,t){return!!e.find(n=>n.name.value===t.name.value)}function pk(e,t){var n;return!!((n=t==null?void 0:t[e.name.value])!=null&&n.repeatable)}function qte(e,t){return t.some(({value:n})=>n===e.value)}function fk(e,t){let n=[...t];for(let r of e){let i=n.findIndex(a=>a.name.value===r.name.value);if(i>-1){let a=n[i];if(a.value.kind==="ListValue"){let o=a.value.values,c=r.value.values;a.value.values=$te(o,c,(l,p)=>{let f=l.value;return!f||!p.some(y=>y.value===f)})}else a.value=r.value}else n.push(r)}return n}function Vte(e,t){return e.map((n,r,i)=>{let a=i.findIndex(o=>o.name.value===n.name.value);if(a!==r&&!pk(n,t)){let o=i[a];return n.arguments=fk(n.arguments,o.arguments),null}return n}).filter(Mte.isSome)}function jte(e=[],t=[],n,r){let i=n&&n.reverseDirectives,a=i?e:t,o=i?t:e,c=Vte([...a],r);for(let l of o)if(xte(c,l)&&!pk(l,r)){let p=c.findIndex(y=>y.name.value===l.name.value),f=c[p];c[p].arguments=fk(l.arguments||[],f.arguments||[])}else c.push(l);return c}Bl.mergeDirectives=jte;function Kte(e,t){let n=(0,dk.print)(Y(x({},e),{description:void 0})),r=(0,dk.print)(Y(x({},t),{description:void 0})),i=new RegExp("(directive @w*d*)|( on .*$)","g");if(!(n.replace(i,"")===r.replace(i,"")))throw new Error(`Unable to merge GraphQL directive "${e.name.value}". +`+o,block:!0})}):Y(x({},i),{description:{kind:ki.Kind.STRING,value:o,block:c}})}}}})}uu.transformCommentsToDescriptions=eU;function tU(e){return(0,ki.isTypeSystemDefinitionNode)(e)||e.kind===ki.Kind.FIELD_DEFINITION||e.kind===ki.Kind.INPUT_VALUE_DEFINITION||e.kind===ki.Kind.ENUM_VALUE_DEFINITION}uu.isDescribable=tU});var lU=w(aT=>{"use strict";m();T();N();Object.defineProperty(aT,"__esModule",{value:!0});aT.buildOperationNodeForField=void 0;var ct=Ae(),sU=Sp(),Jv=[],iT=new Map;function oU(e){Jv.push(e)}function rU(){Jv=[]}function iU(){iT=new Map}function iee({schema:e,kind:t,field:n,models:r,ignore:i=[],depthLimit:a,circularReferenceDepth:o,argNames:c,selectedFields:l=!0}){rU(),iU();let p=(0,sU.getRootTypeNames)(e),f=aee({schema:e,fieldName:n,kind:t,models:r||[],ignore:i,depthLimit:a||1/0,circularReferenceDepth:o||1,argNames:c,selectedFields:l,rootTypeNames:p});return f.variableDefinitions=[...Jv],rU(),iU(),f}aT.buildOperationNodeForField=iee;function aee({schema:e,fieldName:t,kind:n,models:r,ignore:i,depthLimit:a,circularReferenceDepth:o,argNames:c,selectedFields:l,rootTypeNames:p}){let f=(0,sU.getDefinedRootType)(e,n),y=f.getFields()[t],g=`${t}_${n}`;if(y.args)for(let v of y.args){let P=v.name;(!c||c.includes(P))&&oU(uU(v,P))}return{kind:ct.Kind.OPERATION_DEFINITION,operation:n,name:{kind:ct.Kind.NAME,value:g},variableDefinitions:[],selectionSet:{kind:ct.Kind.SELECTION_SET,selections:[cU({type:f,field:y,models:r,firstCall:!0,path:[],ancestors:[],ignore:i,depthLimit:a,circularReferenceDepth:o,schema:e,depth:0,argNames:c,selectedFields:l,rootTypeNames:p})]}}}function Yv({parent:e,type:t,models:n,firstCall:r,path:i,ancestors:a,ignore:o,depthLimit:c,circularReferenceDepth:l,schema:p,depth:f,argNames:y,selectedFields:g,rootTypeNames:v}){if(!(typeof g=="boolean"&&f>c)){if((0,ct.isUnionType)(t)){let P=t.getTypes();return{kind:ct.Kind.SELECTION_SET,selections:P.filter(U=>!Qv([...a,U],{depth:l})).map(U=>({kind:ct.Kind.INLINE_FRAGMENT,typeCondition:{kind:ct.Kind.NAMED_TYPE,name:{kind:ct.Kind.NAME,value:U.name}},selectionSet:Yv({parent:t,type:U,models:n,path:i,ancestors:a,ignore:o,depthLimit:c,circularReferenceDepth:l,schema:p,depth:f,argNames:y,selectedFields:g,rootTypeNames:v})})).filter(U=>{var K,$;return(($=(K=U==null?void 0:U.selectionSet)==null?void 0:K.selections)==null?void 0:$.length)>0})}}if((0,ct.isInterfaceType)(t)){let P=Object.values(p.getTypeMap()).filter(U=>(0,ct.isObjectType)(U)&&U.getInterfaces().includes(t));return{kind:ct.Kind.SELECTION_SET,selections:P.filter(U=>!Qv([...a,U],{depth:l})).map(U=>({kind:ct.Kind.INLINE_FRAGMENT,typeCondition:{kind:ct.Kind.NAMED_TYPE,name:{kind:ct.Kind.NAME,value:U.name}},selectionSet:Yv({parent:t,type:U,models:n,path:i,ancestors:a,ignore:o,depthLimit:c,circularReferenceDepth:l,schema:p,depth:f,argNames:y,selectedFields:g,rootTypeNames:v})})).filter(U=>{var K,$;return(($=(K=U==null?void 0:U.selectionSet)==null?void 0:K.selections)==null?void 0:$.length)>0})}}if((0,ct.isObjectType)(t)&&!v.has(t.name)){let P=o.includes(t.name)||o.includes(`${e.name}.${i[i.length-1]}`),U=n.includes(t.name);if(!r&&U&&!P)return{kind:ct.Kind.SELECTION_SET,selections:[{kind:ct.Kind.FIELD,name:{kind:ct.Kind.NAME,value:"id"}}]};let K=t.getFields();return{kind:ct.Kind.SELECTION_SET,selections:Object.keys(K).filter($=>!Qv([...a,(0,ct.getNamedType)(K[$].type)],{depth:l})).map($=>{let ne=typeof g=="object"?g[$]:!0;return ne?cU({type:t,field:K[$],models:n,path:[...i,$],ancestors:a,ignore:o,depthLimit:c,circularReferenceDepth:l,schema:p,depth:f,argNames:y,selectedFields:ne,rootTypeNames:v}):null}).filter($=>{var ne,z;return $==null?!1:"selectionSet"in $?!!((z=(ne=$.selectionSet)==null?void 0:ne.selections)!=null&&z.length):!0})}}}}function uU(e,t){function n(r){return(0,ct.isListType)(r)?{kind:ct.Kind.LIST_TYPE,type:n(r.ofType)}:(0,ct.isNonNullType)(r)?{kind:ct.Kind.NON_NULL_TYPE,type:n(r.ofType)}:{kind:ct.Kind.NAMED_TYPE,name:{kind:ct.Kind.NAME,value:r.name}}}return{kind:ct.Kind.VARIABLE_DEFINITION,variable:{kind:ct.Kind.VARIABLE,name:{kind:ct.Kind.NAME,value:t||e.name}},type:n(e.type)}}function aU(e,t){return[...t,e].join("_")}function cU({type:e,field:t,models:n,firstCall:r,path:i,ancestors:a,ignore:o,depthLimit:c,circularReferenceDepth:l,schema:p,depth:f,argNames:y,selectedFields:g,rootTypeNames:v}){let P=(0,ct.getNamedType)(t.type),U=[],K=!1;if(t.args&&t.args.length&&(U=t.args.map(Te=>{let pe=aU(Te.name,i);return y&&!y.includes(pe)?((0,ct.isNonNullType)(Te.type)&&(K=!0),null):(r||oU(uU(Te,pe)),{kind:ct.Kind.ARGUMENT,name:{kind:ct.Kind.NAME,value:Te.name},value:{kind:ct.Kind.VARIABLE,name:{kind:ct.Kind.NAME,value:aU(Te.name,i)}}})}).filter(Boolean)),K)return null;let $=[...i,t.name],ne=$.join("."),z=t.name;return iT.has(ne)&&iT.get(ne)!==t.type.toString()&&(z+=t.type.toString().replace("!","NonNull").replace("[","List").replace("]","")),iT.set(ne,t.type.toString()),!(0,ct.isScalarType)(P)&&!(0,ct.isEnumType)(P)?Y(x({kind:ct.Kind.FIELD,name:{kind:ct.Kind.NAME,value:t.name}},z!==t.name&&{alias:{kind:ct.Kind.NAME,value:z}}),{selectionSet:Yv({parent:e,type:P,models:n,firstCall:r,path:$,ancestors:[...a,e],ignore:o,depthLimit:c,circularReferenceDepth:l,schema:p,depth:f+1,argNames:y,selectedFields:g,rootTypeNames:v})||void 0,arguments:U}):Y(x({kind:ct.Kind.FIELD,name:{kind:ct.Kind.NAME,value:t.name}},z!==t.name&&{alias:{kind:ct.Kind.NAME,value:z}}),{arguments:U})}function Qv(e,t={depth:1}){let n=e[e.length-1];return(0,ct.isScalarType)(n)?!1:e.filter(i=>i.name===n.name).length>t.depth}});var pU=w(sT=>{"use strict";m();T();N();Object.defineProperty(sT,"__esModule",{value:!0});sT.DirectiveLocation=void 0;var dU;(function(e){e.QUERY="QUERY",e.MUTATION="MUTATION",e.SUBSCRIPTION="SUBSCRIPTION",e.FIELD="FIELD",e.FRAGMENT_DEFINITION="FRAGMENT_DEFINITION",e.FRAGMENT_SPREAD="FRAGMENT_SPREAD",e.INLINE_FRAGMENT="INLINE_FRAGMENT",e.VARIABLE_DEFINITION="VARIABLE_DEFINITION",e.SCHEMA="SCHEMA",e.SCALAR="SCALAR",e.OBJECT="OBJECT",e.FIELD_DEFINITION="FIELD_DEFINITION",e.ARGUMENT_DEFINITION="ARGUMENT_DEFINITION",e.INTERFACE="INTERFACE",e.UNION="UNION",e.ENUM="ENUM",e.ENUM_VALUE="ENUM_VALUE",e.INPUT_OBJECT="INPUT_OBJECT",e.INPUT_FIELD_DEFINITION="INPUT_FIELD_DEFINITION"})(dU||(sT.DirectiveLocation=dU={}))});var oc=w(oT=>{"use strict";m();T();N();Object.defineProperty(oT,"__esModule",{value:!0});oT.MapperKind=void 0;var fU;(function(e){e.TYPE="MapperKind.TYPE",e.SCALAR_TYPE="MapperKind.SCALAR_TYPE",e.ENUM_TYPE="MapperKind.ENUM_TYPE",e.COMPOSITE_TYPE="MapperKind.COMPOSITE_TYPE",e.OBJECT_TYPE="MapperKind.OBJECT_TYPE",e.INPUT_OBJECT_TYPE="MapperKind.INPUT_OBJECT_TYPE",e.ABSTRACT_TYPE="MapperKind.ABSTRACT_TYPE",e.UNION_TYPE="MapperKind.UNION_TYPE",e.INTERFACE_TYPE="MapperKind.INTERFACE_TYPE",e.ROOT_OBJECT="MapperKind.ROOT_OBJECT",e.QUERY="MapperKind.QUERY",e.MUTATION="MapperKind.MUTATION",e.SUBSCRIPTION="MapperKind.SUBSCRIPTION",e.DIRECTIVE="MapperKind.DIRECTIVE",e.FIELD="MapperKind.FIELD",e.COMPOSITE_FIELD="MapperKind.COMPOSITE_FIELD",e.OBJECT_FIELD="MapperKind.OBJECT_FIELD",e.ROOT_FIELD="MapperKind.ROOT_FIELD",e.QUERY_ROOT_FIELD="MapperKind.QUERY_ROOT_FIELD",e.MUTATION_ROOT_FIELD="MapperKind.MUTATION_ROOT_FIELD",e.SUBSCRIPTION_ROOT_FIELD="MapperKind.SUBSCRIPTION_ROOT_FIELD",e.INTERFACE_FIELD="MapperKind.INTERFACE_FIELD",e.INPUT_OBJECT_FIELD="MapperKind.INPUT_OBJECT_FIELD",e.ARGUMENT="MapperKind.ARGUMENT",e.ENUM_VALUE="MapperKind.ENUM_VALUE"})(fU||(oT.MapperKind=fU={}))});var Hv=w(uT=>{"use strict";m();T();N();Object.defineProperty(uT,"__esModule",{value:!0});uT.getObjectTypeFromTypeMap=void 0;var see=Ae();function oee(e,t){if(t){let n=e[t.name];if((0,see.isObjectType)(n))return n}}uT.getObjectTypeFromTypeMap=oee});var Xv=w(ka=>{"use strict";m();T();N();Object.defineProperty(ka,"__esModule",{value:!0});ka.getBuiltInForStub=ka.isNamedStub=ka.createStub=ka.createNamedStub=void 0;var lr=Ae();function zv(e,t){let n;return t==="object"?n=lr.GraphQLObjectType:t==="interface"?n=lr.GraphQLInterfaceType:n=lr.GraphQLInputObjectType,new n({name:e,fields:{_fake:{type:lr.GraphQLString}}})}ka.createNamedStub=zv;function Wv(e,t){switch(e.kind){case lr.Kind.LIST_TYPE:return new lr.GraphQLList(Wv(e.type,t));case lr.Kind.NON_NULL_TYPE:return new lr.GraphQLNonNull(Wv(e.type,t));default:return t==="output"?zv(e.name.value,"object"):zv(e.name.value,"input")}}ka.createStub=Wv;function uee(e){if("getFields"in e){let t=e.getFields();for(let n in t)return t[n].name==="_fake"}return!1}ka.isNamedStub=uee;function cee(e){switch(e.name){case lr.GraphQLInt.name:return lr.GraphQLInt;case lr.GraphQLFloat.name:return lr.GraphQLFloat;case lr.GraphQLString.name:return lr.GraphQLString;case lr.GraphQLBoolean.name:return lr.GraphQLBoolean;case lr.GraphQLID.name:return lr.GraphQLID;default:return e}}ka.getBuiltInForStub=cee});var lT=w(cT=>{"use strict";m();T();N();Object.defineProperty(cT,"__esModule",{value:!0});cT.rewireTypes=void 0;var Qn=Ae(),mU=Xv();function lee(e,t){let n=Object.create(null);for(let g in e)n[g]=e[g];let r=Object.create(null);for(let g in n){let v=n[g];if(v==null||g.startsWith("__"))continue;let P=v.name;if(!P.startsWith("__")){if(r[P]!=null){console.warn(`Duplicate schema type name ${P} found; keeping the existing one found in the schema`);continue}r[P]=v}}for(let g in r)r[g]=c(r[g]);let i=t.map(g=>a(g));return{typeMap:r,directives:i};function a(g){if((0,Qn.isSpecifiedDirective)(g))return g;let v=g.toConfig();return v.args=o(v.args),new Qn.GraphQLDirective(v)}function o(g){let v={};for(let P in g){let U=g[P],K=y(U.type);K!=null&&(U.type=K,v[P]=U)}return v}function c(g){if((0,Qn.isObjectType)(g)){let v=g.toConfig(),P=Y(x({},v),{fields:()=>l(v.fields),interfaces:()=>f(v.interfaces)});return new Qn.GraphQLObjectType(P)}else if((0,Qn.isInterfaceType)(g)){let v=g.toConfig(),P=Y(x({},v),{fields:()=>l(v.fields)});return"interfaces"in P&&(P.interfaces=()=>f(v.interfaces)),new Qn.GraphQLInterfaceType(P)}else if((0,Qn.isUnionType)(g)){let v=g.toConfig(),P=Y(x({},v),{types:()=>f(v.types)});return new Qn.GraphQLUnionType(P)}else if((0,Qn.isInputObjectType)(g)){let v=g.toConfig(),P=Y(x({},v),{fields:()=>p(v.fields)});return new Qn.GraphQLInputObjectType(P)}else if((0,Qn.isEnumType)(g)){let v=g.toConfig();return new Qn.GraphQLEnumType(v)}else if((0,Qn.isScalarType)(g)){if((0,Qn.isSpecifiedScalarType)(g))return g;let v=g.toConfig();return new Qn.GraphQLScalarType(v)}throw new Error(`Unexpected schema type: ${g}`)}function l(g){let v={};for(let P in g){let U=g[P],K=y(U.type);K!=null&&U.args&&(U.type=K,U.args=o(U.args),v[P]=U)}return v}function p(g){let v={};for(let P in g){let U=g[P],K=y(U.type);K!=null&&(U.type=K,v[P]=U)}return v}function f(g){let v=[];for(let P of g){let U=y(P);U!=null&&v.push(U)}return v}function y(g){if((0,Qn.isListType)(g)){let v=y(g.ofType);return v!=null?new Qn.GraphQLList(v):null}else if((0,Qn.isNonNullType)(g)){let v=y(g.ofType);return v!=null?new Qn.GraphQLNonNull(v):null}else if((0,Qn.isNamedType)(g)){let v=n[g.name];return v===void 0&&(v=(0,mU.isNamedStub)(g)?(0,mU.getBuiltInForStub)(g):c(g),r[v.name]=n[g.name]=v),v!=null?r[v.name]:null}return null}}cT.rewireTypes=lee});var Zv=w(Ma=>{"use strict";m();T();N();Object.defineProperty(Ma,"__esModule",{value:!0});Ma.parseInputValueLiteral=Ma.parseInputValue=Ma.serializeInputValue=Ma.transformInputValue=void 0;var dT=Ae(),dee=Ip();function Ol(e,t,n=null,r=null){if(t==null)return t;let i=(0,dT.getNullableType)(e);if((0,dT.isLeafType)(i))return n!=null?n(i,t):t;if((0,dT.isListType)(i))return(0,dee.asArray)(t).map(a=>Ol(i.ofType,a,n,r));if((0,dT.isInputObjectType)(i)){let a=i.getFields(),o={};for(let c in t){let l=a[c];l!=null&&(o[c]=Ol(l.type,t[c],n,r))}return r!=null?r(i,o):o}}Ma.transformInputValue=Ol;function pee(e,t){return Ol(e,t,(n,r)=>{try{return n.serialize(r)}catch(i){return r}})}Ma.serializeInputValue=pee;function fee(e,t){return Ol(e,t,(n,r)=>{try{return n.parseValue(r)}catch(i){return r}})}Ma.parseInputValue=fee;function mee(e,t){return Ol(e,t,(n,r)=>n.parseLiteral(r,{}))}Ma.parseInputValueLiteral=mee});var Al=w(bl=>{"use strict";m();T();N();Object.defineProperty(bl,"__esModule",{value:!0});bl.correctASTNodes=bl.mapSchema=void 0;var rt=Ae(),Dl=Hv(),bt=oc(),Nee=lT(),NU=Zv();function Tee(e,t={}){let n=hU(EU(eS(TU(Eee(eS(TU(e.getTypeMap(),e,NU.serializeInputValue),e,t,c=>(0,rt.isLeafType)(c)),e,t),e,NU.parseInputValue),e,t,c=>!(0,rt.isLeafType)(c)),e,t),e,t),r=e.getDirectives(),i=hee(r,e,t),{typeMap:a,directives:o}=(0,Nee.rewireTypes)(n,i);return new rt.GraphQLSchema(Y(x({},e.toConfig()),{query:(0,Dl.getObjectTypeFromTypeMap)(a,(0,Dl.getObjectTypeFromTypeMap)(n,e.getQueryType())),mutation:(0,Dl.getObjectTypeFromTypeMap)(a,(0,Dl.getObjectTypeFromTypeMap)(n,e.getMutationType())),subscription:(0,Dl.getObjectTypeFromTypeMap)(a,(0,Dl.getObjectTypeFromTypeMap)(n,e.getSubscriptionType())),types:Object.values(a),directives:o}))}bl.mapSchema=Tee;function eS(e,t,n,r=()=>!0){let i={};for(let a in e)if(!a.startsWith("__")){let o=e[a];if(o==null||!r(o)){i[a]=o;continue}let c=Iee(t,n,a);if(c==null){i[a]=o;continue}let l=c(o,t);if(l===void 0){i[a]=o;continue}i[a]=l}return i}function Eee(e,t,n){let r=Oee(n);return r?eS(e,t,{[bt.MapperKind.ENUM_TYPE]:i=>{let a=i.toConfig(),o=a.values,c={};for(let l in o){let p=o[l],f=r(p,i.name,t,l);if(f===void 0)c[l]=p;else if(Array.isArray(f)){let[y,g]=f;c[y]=g===void 0?p:g}else f!==null&&(c[l]=f)}return Pp(new rt.GraphQLEnumType(Y(x({},a),{values:c})))}},i=>(0,rt.isEnumType)(i)):e}function TU(e,t,n){let r=hU(e,t,{[bt.MapperKind.ARGUMENT]:i=>{if(i.defaultValue===void 0)return i;let a=pT(e,i.type);if(a!=null)return Y(x({},i),{defaultValue:n(a,i.defaultValue)})}});return EU(r,t,{[bt.MapperKind.INPUT_OBJECT_FIELD]:i=>{if(i.defaultValue===void 0)return i;let a=pT(r,i.type);if(a!=null)return Y(x({},i),{defaultValue:n(a,i.defaultValue)})}})}function pT(e,t){if((0,rt.isListType)(t)){let n=pT(e,t.ofType);return n!=null?new rt.GraphQLList(n):null}else if((0,rt.isNonNullType)(t)){let n=pT(e,t.ofType);return n!=null?new rt.GraphQLNonNull(n):null}else if((0,rt.isNamedType)(t)){let n=e[t.name];return n!=null?n:null}return null}function EU(e,t,n){let r={};for(let i in e)if(!i.startsWith("__")){let a=e[i];if(!(0,rt.isObjectType)(a)&&!(0,rt.isInterfaceType)(a)&&!(0,rt.isInputObjectType)(a)){r[i]=a;continue}let o=_ee(t,n,i);if(o==null){r[i]=a;continue}let c=a.toConfig(),l=c.fields,p={};for(let f in l){let y=l[f],g=o(y,f,i,t);if(g===void 0)p[f]=y;else if(Array.isArray(g)){let[v,P]=g;P.astNode!=null&&(P.astNode=Y(x({},P.astNode),{name:Y(x({},P.astNode.name),{value:v})})),p[v]=P===void 0?y:P}else g!==null&&(p[f]=g)}(0,rt.isObjectType)(a)?r[i]=Pp(new rt.GraphQLObjectType(Y(x({},c),{fields:p}))):(0,rt.isInterfaceType)(a)?r[i]=Pp(new rt.GraphQLInterfaceType(Y(x({},c),{fields:p}))):r[i]=Pp(new rt.GraphQLInputObjectType(Y(x({},c),{fields:p})))}return r}function hU(e,t,n){let r={};for(let i in e)if(!i.startsWith("__")){let a=e[i];if(!(0,rt.isObjectType)(a)&&!(0,rt.isInterfaceType)(a)){r[i]=a;continue}let o=vee(n);if(o==null){r[i]=a;continue}let c=a.toConfig(),l=c.fields,p={};for(let f in l){let y=l[f],g=y.args;if(g==null){p[f]=y;continue}let v=Object.keys(g);if(!v.length){p[f]=y;continue}let P={};for(let U of v){let K=g[U],$=o(K,f,i,t);if($===void 0)P[U]=K;else if(Array.isArray($)){let[ne,z]=$;P[ne]=z}else $!==null&&(P[U]=$)}p[f]=Y(x({},y),{args:P})}(0,rt.isObjectType)(a)?r[i]=new rt.GraphQLObjectType(Y(x({},c),{fields:p})):(0,rt.isInterfaceType)(a)?r[i]=new rt.GraphQLInterfaceType(Y(x({},c),{fields:p})):r[i]=new rt.GraphQLInputObjectType(Y(x({},c),{fields:p}))}return r}function hee(e,t,n){let r=See(n);if(r==null)return e.slice();let i=[];for(let a of e){let o=r(a,t);o===void 0?i.push(a):o!==null&&i.push(o)}return i}function yee(e,t){var i,a,o;let n=e.getType(t),r=[bt.MapperKind.TYPE];return(0,rt.isObjectType)(n)?(r.push(bt.MapperKind.COMPOSITE_TYPE,bt.MapperKind.OBJECT_TYPE),t===((i=e.getQueryType())==null?void 0:i.name)?r.push(bt.MapperKind.ROOT_OBJECT,bt.MapperKind.QUERY):t===((a=e.getMutationType())==null?void 0:a.name)?r.push(bt.MapperKind.ROOT_OBJECT,bt.MapperKind.MUTATION):t===((o=e.getSubscriptionType())==null?void 0:o.name)&&r.push(bt.MapperKind.ROOT_OBJECT,bt.MapperKind.SUBSCRIPTION)):(0,rt.isInputObjectType)(n)?r.push(bt.MapperKind.INPUT_OBJECT_TYPE):(0,rt.isInterfaceType)(n)?r.push(bt.MapperKind.COMPOSITE_TYPE,bt.MapperKind.ABSTRACT_TYPE,bt.MapperKind.INTERFACE_TYPE):(0,rt.isUnionType)(n)?r.push(bt.MapperKind.COMPOSITE_TYPE,bt.MapperKind.ABSTRACT_TYPE,bt.MapperKind.UNION_TYPE):(0,rt.isEnumType)(n)?r.push(bt.MapperKind.ENUM_TYPE):(0,rt.isScalarType)(n)&&r.push(bt.MapperKind.SCALAR_TYPE),r}function Iee(e,t,n){let r=yee(e,n),i,a=[...r];for(;!i&&a.length>0;){let o=a.pop();i=t[o]}return i!=null?i:null}function gee(e,t){var i,a,o;let n=e.getType(t),r=[bt.MapperKind.FIELD];return(0,rt.isObjectType)(n)?(r.push(bt.MapperKind.COMPOSITE_FIELD,bt.MapperKind.OBJECT_FIELD),t===((i=e.getQueryType())==null?void 0:i.name)?r.push(bt.MapperKind.ROOT_FIELD,bt.MapperKind.QUERY_ROOT_FIELD):t===((a=e.getMutationType())==null?void 0:a.name)?r.push(bt.MapperKind.ROOT_FIELD,bt.MapperKind.MUTATION_ROOT_FIELD):t===((o=e.getSubscriptionType())==null?void 0:o.name)&&r.push(bt.MapperKind.ROOT_FIELD,bt.MapperKind.SUBSCRIPTION_ROOT_FIELD)):(0,rt.isInterfaceType)(n)?r.push(bt.MapperKind.COMPOSITE_FIELD,bt.MapperKind.INTERFACE_FIELD):(0,rt.isInputObjectType)(n)&&r.push(bt.MapperKind.INPUT_OBJECT_FIELD),r}function _ee(e,t,n){let r=gee(e,n),i,a=[...r];for(;!i&&a.length>0;){let o=a.pop();i=t[o]}return i!=null?i:null}function vee(e){let t=e[bt.MapperKind.ARGUMENT];return t!=null?t:null}function See(e){let t=e[bt.MapperKind.DIRECTIVE];return t!=null?t:null}function Oee(e){let t=e[bt.MapperKind.ENUM_VALUE];return t!=null?t:null}function Pp(e){if((0,rt.isObjectType)(e)){let t=e.toConfig();if(t.astNode!=null){let n=[];for(let r in t.fields){let i=t.fields[r];i.astNode!=null&&n.push(i.astNode)}t.astNode=Y(x({},t.astNode),{kind:rt.Kind.OBJECT_TYPE_DEFINITION,fields:n})}return t.extensionASTNodes!=null&&(t.extensionASTNodes=t.extensionASTNodes.map(n=>Y(x({},n),{kind:rt.Kind.OBJECT_TYPE_EXTENSION,fields:void 0}))),new rt.GraphQLObjectType(t)}else if((0,rt.isInterfaceType)(e)){let t=e.toConfig();if(t.astNode!=null){let n=[];for(let r in t.fields){let i=t.fields[r];i.astNode!=null&&n.push(i.astNode)}t.astNode=Y(x({},t.astNode),{kind:rt.Kind.INTERFACE_TYPE_DEFINITION,fields:n})}return t.extensionASTNodes!=null&&(t.extensionASTNodes=t.extensionASTNodes.map(n=>Y(x({},n),{kind:rt.Kind.INTERFACE_TYPE_EXTENSION,fields:void 0}))),new rt.GraphQLInterfaceType(t)}else if((0,rt.isInputObjectType)(e)){let t=e.toConfig();if(t.astNode!=null){let n=[];for(let r in t.fields){let i=t.fields[r];i.astNode!=null&&n.push(i.astNode)}t.astNode=Y(x({},t.astNode),{kind:rt.Kind.INPUT_OBJECT_TYPE_DEFINITION,fields:n})}return t.extensionASTNodes!=null&&(t.extensionASTNodes=t.extensionASTNodes.map(n=>Y(x({},n),{kind:rt.Kind.INPUT_OBJECT_TYPE_EXTENSION,fields:void 0}))),new rt.GraphQLInputObjectType(t)}else if((0,rt.isEnumType)(e)){let t=e.toConfig();if(t.astNode!=null){let n=[];for(let r in t.values){let i=t.values[r];i.astNode!=null&&n.push(i.astNode)}t.astNode=Y(x({},t.astNode),{values:n})}return t.extensionASTNodes!=null&&(t.extensionASTNodes=t.extensionASTNodes.map(n=>Y(x({},n),{values:void 0}))),new rt.GraphQLEnumType(t)}else return e}bl.correctASTNodes=Pp});var yU=w(mT=>{"use strict";m();T();N();Object.defineProperty(mT,"__esModule",{value:!0});mT.filterSchema=void 0;var fT=Ae(),hs=oc(),Dee=Al();function bee({schema:e,typeFilter:t=()=>!0,fieldFilter:n=void 0,rootFieldFilter:r=void 0,objectFieldFilter:i=void 0,interfaceFieldFilter:a=void 0,inputObjectFieldFilter:o=void 0,argumentFilter:c=void 0}){return(0,Dee.mapSchema)(e,{[hs.MapperKind.QUERY]:p=>tS(p,"Query",r,c),[hs.MapperKind.MUTATION]:p=>tS(p,"Mutation",r,c),[hs.MapperKind.SUBSCRIPTION]:p=>tS(p,"Subscription",r,c),[hs.MapperKind.OBJECT_TYPE]:p=>t(p.name,p)?nS(fT.GraphQLObjectType,p,i||n,c):null,[hs.MapperKind.INTERFACE_TYPE]:p=>t(p.name,p)?nS(fT.GraphQLInterfaceType,p,a||n,c):null,[hs.MapperKind.INPUT_OBJECT_TYPE]:p=>t(p.name,p)?nS(fT.GraphQLInputObjectType,p,o||n):null,[hs.MapperKind.UNION_TYPE]:p=>t(p.name,p)?void 0:null,[hs.MapperKind.ENUM_TYPE]:p=>t(p.name,p)?void 0:null,[hs.MapperKind.SCALAR_TYPE]:p=>t(p.name,p)?void 0:null})}mT.filterSchema=bee;function tS(e,t,n,r){if(n||r){let i=e.toConfig();for(let a in i.fields){let o=i.fields[a];if(n&&!n(t,a,i.fields[a]))delete i.fields[a];else if(r&&o.args)for(let c in o.args)r(t,a,c,o.args[c])||delete o.args[c]}return new fT.GraphQLObjectType(i)}return e}function nS(e,t,n,r){if(n||r){let i=t.toConfig();for(let a in i.fields){let o=i.fields[a];if(n&&!n(t.name,a,i.fields[a]))delete i.fields[a];else if(r&&"args"in o)for(let c in o.args)r(t.name,a,c,o.args[c])||delete o.args[c]}return new e(i)}}});var gU=w(Rl=>{"use strict";m();T();N();Object.defineProperty(Rl,"__esModule",{value:!0});Rl.healTypes=Rl.healSchema=void 0;var xa=Ae();function Aee(e){return IU(e.getTypeMap(),e.getDirectives()),e}Rl.healSchema=Aee;function IU(e,t){let n=Object.create(null);for(let p in e){let f=e[p];if(f==null||p.startsWith("__"))continue;let y=f.name;if(!y.startsWith("__")){if(n[y]!=null){console.warn(`Duplicate schema type name ${y} found; keeping the existing one found in the schema`);continue}n[y]=f}}for(let p in n){let f=n[p];e[p]=f}for(let p of t)p.args=p.args.filter(f=>(f.type=l(f.type),f.type!==null));for(let p in e){let f=e[p];!p.startsWith("__")&&p in n&&f!=null&&r(f)}for(let p in e)!p.startsWith("__")&&!(p in n)&&delete e[p];function r(p){if((0,xa.isObjectType)(p)){i(p),a(p);return}else if((0,xa.isInterfaceType)(p)){i(p),"getInterfaces"in p&&a(p);return}else if((0,xa.isUnionType)(p)){c(p);return}else if((0,xa.isInputObjectType)(p)){o(p);return}else if((0,xa.isLeafType)(p))return;throw new Error(`Unexpected schema type: ${p}`)}function i(p){let f=p.getFields();for(let[y,g]of Object.entries(f))g.args.map(v=>(v.type=l(v.type),v.type===null?null:v)).filter(Boolean),g.type=l(g.type),g.type===null&&delete f[y]}function a(p){if("getInterfaces"in p){let f=p.getInterfaces();f.push(...f.splice(0).map(y=>l(y)).filter(Boolean))}}function o(p){let f=p.getFields();for(let[y,g]of Object.entries(f))g.type=l(g.type),g.type===null&&delete f[y]}function c(p){let f=p.getTypes();f.push(...f.splice(0).map(y=>l(y)).filter(Boolean))}function l(p){if((0,xa.isListType)(p)){let f=l(p.ofType);return f!=null?new xa.GraphQLList(f):null}else if((0,xa.isNonNullType)(p)){let f=l(p.ofType);return f!=null?new xa.GraphQLNonNull(f):null}else if((0,xa.isNamedType)(p)){let f=e[p.name];if(f&&p!==f)return f}return p}}Rl.healTypes=IU});var _U=w(NT=>{"use strict";m();T();N();Object.defineProperty(NT,"__esModule",{value:!0});NT.getResolversFromSchema=void 0;var uc=Ae();function Ree(e,t){var i,a;let n=Object.create(null),r=e.getTypeMap();for(let o in r)if(!o.startsWith("__")){let c=r[o];if((0,uc.isScalarType)(c)){if(!(0,uc.isSpecifiedScalarType)(c)){let l=c.toConfig();delete l.astNode,n[o]=new uc.GraphQLScalarType(l)}}else if((0,uc.isEnumType)(c)){n[o]={};let l=c.getValues();for(let p of l)n[o][p.name]=p.value}else if((0,uc.isInterfaceType)(c))c.resolveType!=null&&(n[o]={__resolveType:c.resolveType});else if((0,uc.isUnionType)(c))c.resolveType!=null&&(n[o]={__resolveType:c.resolveType});else if((0,uc.isObjectType)(c)){n[o]={},c.isTypeOf!=null&&(n[o].__isTypeOf=c.isTypeOf);let l=c.getFields();for(let p in l){let f=l[p];if(f.subscribe!=null&&(n[o][p]=n[o][p]||{},n[o][p].subscribe=f.subscribe),f.resolve!=null&&((i=f.resolve)==null?void 0:i.name)!=="defaultFieldResolver"){switch((a=f.resolve)==null?void 0:a.name){case"defaultMergedResolver":if(!t)continue;break;case"defaultFieldResolver":continue}n[o][p]=n[o][p]||{},n[o][p].resolve=f.resolve}}}}return n}NT.getResolversFromSchema=Ree});var SU=w(TT=>{"use strict";m();T();N();Object.defineProperty(TT,"__esModule",{value:!0});TT.forEachField=void 0;var vU=Ae();function Pee(e,t){let n=e.getTypeMap();for(let r in n){let i=n[r];if(!(0,vU.getNamedType)(i).name.startsWith("__")&&(0,vU.isObjectType)(i)){let a=i.getFields();for(let o in a){let c=a[o];t(c,r,o)}}}}TT.forEachField=Pee});var OU=w(ET=>{"use strict";m();T();N();Object.defineProperty(ET,"__esModule",{value:!0});ET.forEachDefaultValue=void 0;var rS=Ae();function Fee(e,t){let n=e.getTypeMap();for(let r in n){let i=n[r];if(!(0,rS.getNamedType)(i).name.startsWith("__")){if((0,rS.isObjectType)(i)){let a=i.getFields();for(let o in a){let c=a[o];for(let l of c.args)l.defaultValue=t(l.type,l.defaultValue)}}else if((0,rS.isInputObjectType)(i)){let a=i.getFields();for(let o in a){let c=a[o];c.defaultValue=t(c.type,c.defaultValue)}}}}}ET.forEachDefaultValue=Fee});var sS=w(hT=>{"use strict";m();T();N();Object.defineProperty(hT,"__esModule",{value:!0});hT.addTypes=void 0;var iS=Ae(),aS=Hv(),wee=lT();function Lee(e,t){let n=e.toConfig(),r={};for(let c of n.types)r[c.name]=c;let i={};for(let c of n.directives)i[c.name]=c;for(let c of t)(0,iS.isNamedType)(c)?r[c.name]=c:(0,iS.isDirective)(c)&&(i[c.name]=c);let{typeMap:a,directives:o}=(0,wee.rewireTypes)(r,Object.values(i));return new iS.GraphQLSchema(Y(x({},n),{query:(0,aS.getObjectTypeFromTypeMap)(a,e.getQueryType()),mutation:(0,aS.getObjectTypeFromTypeMap)(a,e.getMutationType()),subscription:(0,aS.getObjectTypeFromTypeMap)(a,e.getSubscriptionType()),types:Object.values(a),directives:o}))}hT.addTypes=Lee});var bU=w(IT=>{"use strict";m();T();N();Object.defineProperty(IT,"__esModule",{value:!0});IT.pruneSchema=void 0;var Zn=Ae(),Cee=Cv(),Bee=oc(),Uee=Al(),kee=Sp();function Mee(e,t={}){let{skipEmptyCompositeTypePruning:n,skipEmptyUnionPruning:r,skipPruning:i,skipUnimplementedInterfacesPruning:a,skipUnusedTypesPruning:o}=t,c=[],l=e;do{let p=xee(l);if(i){let f=[];for(let y in l.getTypeMap()){if(y.startsWith("__"))continue;let g=l.getType(y);g&&i(g)&&f.push(y)}p=DU(f,l,p)}c=[],l=(0,Uee.mapSchema)(l,{[Bee.MapperKind.TYPE]:f=>!p.has(f.name)&&!(0,Zn.isSpecifiedScalarType)(f)?((0,Zn.isUnionType)(f)||(0,Zn.isInputObjectType)(f)||(0,Zn.isInterfaceType)(f)||(0,Zn.isObjectType)(f)||(0,Zn.isScalarType)(f))&&(o||(0,Zn.isUnionType)(f)&&r&&!Object.keys(f.getTypes()).length||((0,Zn.isInputObjectType)(f)||(0,Zn.isInterfaceType)(f)||(0,Zn.isObjectType)(f))&&n&&!Object.keys(f.getFields()).length||(0,Zn.isInterfaceType)(f)&&a)?f:(c.push(f.name),p.delete(f.name),null):f})}while(c.length);return l}IT.pruneSchema=Mee;function xee(e){let t=[];for(let n of(0,kee.getRootTypes)(e))t.push(n.name);return DU(t,e)}function DU(e,t,n=new Set){let r=new Map;for(;e.length;){let i=e.pop();if(n.has(i)&&r[i]!==!0)continue;let a=t.getType(i);if(a){if((0,Zn.isUnionType)(a)&&e.push(...a.getTypes().map(o=>o.name)),(0,Zn.isInterfaceType)(a)&&r[i]===!0&&(e.push(...(0,Cee.getImplementingTypes)(a.name,t)),r[i]=!1),(0,Zn.isEnumType)(a)&&e.push(...a.getValues().flatMap(o=>o.astNode?yT(t,o.astNode):[])),"getInterfaces"in a&&e.push(...a.getInterfaces().map(o=>o.name)),"getFields"in a){let o=a.getFields(),c=Object.entries(o);if(!c.length)continue;for(let[,l]of c){(0,Zn.isObjectType)(a)&&e.push(...l.args.flatMap(f=>{let y=[(0,Zn.getNamedType)(f.type).name];return f.astNode&&y.push(...yT(t,f.astNode)),y}));let p=(0,Zn.getNamedType)(l.type);e.push(p.name),l.astNode&&e.push(...yT(t,l.astNode)),(0,Zn.isInterfaceType)(p)&&!(p.name in r)&&(r[p.name]=!0)}}a.astNode&&e.push(...yT(t,a.astNode)),n.add(i)}}return n}function yT(e,t){var n;return((n=t.directives)!=null?n:[]).flatMap(r=>{var i,a;return(a=(i=e.getDirective(r.name.value))==null?void 0:i.args.map(o=>(0,Zn.getNamedType)(o.type).name))!=null?a:[]})}});var RU=w(gT=>{"use strict";m();T();N();Object.defineProperty(gT,"__esModule",{value:!0});gT.mergeDeep=void 0;var qee=Ip();function AU(e,t=!1,n=!1){let r=e[0]||{},i={};t&&Object.setPrototypeOf(i,Object.create(Object.getPrototypeOf(r)));for(let a of e)if(oS(r)&&oS(a)){if(t){let o=Object.getPrototypeOf(i),c=Object.getPrototypeOf(a);if(c)for(let l of Object.getOwnPropertyNames(c)){let p=Object.getOwnPropertyDescriptor(c,l);(0,qee.isSome)(p)&&Object.defineProperty(o,l,p)}}for(let o in a)oS(a[o])?o in i?i[o]=AU([i[o],a[o]],t,n):Object.assign(i,{[o]:a[o]}):n&&Array.isArray(i[o])?Array.isArray(a[o])?i[o].push(...a[o]):i[o].push(a[o]):Object.assign(i,{[o]:a[o]})}else if(n&&Array.isArray(r))Array.isArray(a)?r.push(...a):r.push(a);else if(n&&Array.isArray(a))return[r,...a];return i}gT.mergeDeep=AU;function oS(e){return e&&typeof e=="object"&&!Array.isArray(e)}});var PU=w(_T=>{"use strict";m();T();N();Object.defineProperty(_T,"__esModule",{value:!0});_T.parseSelectionSet=void 0;var Vee=Ae();function jee(e,t){return(0,Vee.parse)(e,t).definitions[0].selectionSet}_T.parseSelectionSet=jee});var FU=w(vT=>{"use strict";m();T();N();Object.defineProperty(vT,"__esModule",{value:!0});vT.getResponseKeyFromInfo=void 0;function Kee(e){return e.fieldNodes[0].alias!=null?e.fieldNodes[0].alias.value:e.fieldName}vT.getResponseKeyFromInfo=Kee});var wU=w(qa=>{"use strict";m();T();N();Object.defineProperty(qa,"__esModule",{value:!0});qa.modifyObjectFields=qa.selectObjectFields=qa.removeObjectFields=qa.appendObjectFields=void 0;var ST=Ae(),Gee=sS(),OT=oc(),cc=Al();function $ee(e,t,n){return e.getType(t)==null?(0,Gee.addTypes)(e,[new ST.GraphQLObjectType({name:t,fields:n})]):(0,cc.mapSchema)(e,{[OT.MapperKind.OBJECT_TYPE]:r=>{if(r.name===t){let i=r.toConfig(),a=i.fields,o={};for(let c in a)o[c]=a[c];for(let c in n)o[c]=n[c];return(0,cc.correctASTNodes)(new ST.GraphQLObjectType(Y(x({},i),{fields:o})))}}})}qa.appendObjectFields=$ee;function Qee(e,t,n){let r={};return[(0,cc.mapSchema)(e,{[OT.MapperKind.OBJECT_TYPE]:a=>{if(a.name===t){let o=a.toConfig(),c=o.fields,l={};for(let p in c){let f=c[p];n(p,f)?r[p]=f:l[p]=f}return(0,cc.correctASTNodes)(new ST.GraphQLObjectType(Y(x({},o),{fields:l})))}}}),r]}qa.removeObjectFields=Qee;function Yee(e,t,n){let r={};return(0,cc.mapSchema)(e,{[OT.MapperKind.OBJECT_TYPE]:i=>{if(i.name===t){let o=i.toConfig().fields;for(let c in o){let l=o[c];n(c,l)&&(r[c]=l)}}}}),r}qa.selectObjectFields=Yee;function Jee(e,t,n,r){let i={};return[(0,cc.mapSchema)(e,{[OT.MapperKind.OBJECT_TYPE]:o=>{if(o.name===t){let c=o.toConfig(),l=c.fields,p={};for(let f in l){let y=l[f];n(f,y)?i[f]=y:p[f]=y}for(let f in r){let y=r[f];p[f]=y}return(0,cc.correctASTNodes)(new ST.GraphQLObjectType(Y(x({},c),{fields:p})))}}}),i]}qa.modifyObjectFields=Jee});var LU=w(DT=>{"use strict";m();T();N();Object.defineProperty(DT,"__esModule",{value:!0});DT.renameType=void 0;var Mi=Ae();function Hee(e,t){if((0,Mi.isObjectType)(e))return new Mi.GraphQLObjectType(Y(x({},e.toConfig()),{name:t,astNode:e.astNode==null?e.astNode:Y(x({},e.astNode),{name:Y(x({},e.astNode.name),{value:t})}),extensionASTNodes:e.extensionASTNodes==null?e.extensionASTNodes:e.extensionASTNodes.map(n=>Y(x({},n),{name:Y(x({},n.name),{value:t})}))}));if((0,Mi.isInterfaceType)(e))return new Mi.GraphQLInterfaceType(Y(x({},e.toConfig()),{name:t,astNode:e.astNode==null?e.astNode:Y(x({},e.astNode),{name:Y(x({},e.astNode.name),{value:t})}),extensionASTNodes:e.extensionASTNodes==null?e.extensionASTNodes:e.extensionASTNodes.map(n=>Y(x({},n),{name:Y(x({},n.name),{value:t})}))}));if((0,Mi.isUnionType)(e))return new Mi.GraphQLUnionType(Y(x({},e.toConfig()),{name:t,astNode:e.astNode==null?e.astNode:Y(x({},e.astNode),{name:Y(x({},e.astNode.name),{value:t})}),extensionASTNodes:e.extensionASTNodes==null?e.extensionASTNodes:e.extensionASTNodes.map(n=>Y(x({},n),{name:Y(x({},n.name),{value:t})}))}));if((0,Mi.isInputObjectType)(e))return new Mi.GraphQLInputObjectType(Y(x({},e.toConfig()),{name:t,astNode:e.astNode==null?e.astNode:Y(x({},e.astNode),{name:Y(x({},e.astNode.name),{value:t})}),extensionASTNodes:e.extensionASTNodes==null?e.extensionASTNodes:e.extensionASTNodes.map(n=>Y(x({},n),{name:Y(x({},n.name),{value:t})}))}));if((0,Mi.isEnumType)(e))return new Mi.GraphQLEnumType(Y(x({},e.toConfig()),{name:t,astNode:e.astNode==null?e.astNode:Y(x({},e.astNode),{name:Y(x({},e.astNode.name),{value:t})}),extensionASTNodes:e.extensionASTNodes==null?e.extensionASTNodes:e.extensionASTNodes.map(n=>Y(x({},n),{name:Y(x({},n.name),{value:t})}))}));if((0,Mi.isScalarType)(e))return new Mi.GraphQLScalarType(Y(x({},e.toConfig()),{name:t,astNode:e.astNode==null?e.astNode:Y(x({},e.astNode),{name:Y(x({},e.astNode.name),{value:t})}),extensionASTNodes:e.extensionASTNodes==null?e.extensionASTNodes:e.extensionASTNodes.map(n=>Y(x({},n),{name:Y(x({},n.name),{value:t})}))}));throw new Error(`Unknown type ${e}.`)}DT.renameType=Hee});var UU=w(bT=>{"use strict";m();T();N();Object.defineProperty(bT,"__esModule",{value:!0});bT.mapAsyncIterator=void 0;var zee=_p();function Wee(e,t,n,r){let i,a,o;r&&(o=p=>{let f=r();return(0,zee.isPromise)(f)?f.then(()=>p):p}),typeof e.return=="function"&&(i=e.return,a=p=>{let f=()=>Promise.reject(p);return i.call(e).then(f,f)});function c(p){return p.done?o?o(p):p:CU(p.value,t).then(BU,a)}let l;if(n){let p=n;l=f=>CU(f,p).then(BU,a)}return{next(){return e.next().then(c,l)},return(){let p=i?i.call(e).then(c,l):Promise.resolve({value:void 0,done:!0});return o?p.then(o):p},throw(p){return typeof e.throw=="function"?e.throw(p).then(c,l):Promise.reject(p).catch(a)},[Symbol.asyncIterator](){return this}}}bT.mapAsyncIterator=Wee;function CU(e,t){return new Promise(n=>n(t(e)))}function BU(e){return{value:e,done:!1}}});var kU=w(Pl=>{"use strict";m();T();N();Object.defineProperty(Pl,"__esModule",{value:!0});Pl.createVariableNameGenerator=Pl.updateArgument=void 0;var lc=Ae(),Xee=Uv();function Zee(e,t,n,r,i,a,o){if(e[r]={kind:lc.Kind.ARGUMENT,name:{kind:lc.Kind.NAME,value:r},value:{kind:lc.Kind.VARIABLE,name:{kind:lc.Kind.NAME,value:i}}},t[i]={kind:lc.Kind.VARIABLE_DEFINITION,variable:{kind:lc.Kind.VARIABLE,name:{kind:lc.Kind.NAME,value:i}},type:(0,Xee.astFromType)(a)},o!==void 0){n[i]=o;return}i in n&&delete n[i]}Pl.updateArgument=Zee;function ete(e){let t=0;return n=>{let r;do r=`_v${(t++).toString()}_${n}`;while(r in e);return r}}Pl.createVariableNameGenerator=ete});var MU=w(AT=>{"use strict";m();T();N();Object.defineProperty(AT,"__esModule",{value:!0});AT.implementsAbstractType=void 0;var uS=Ae();function tte(e,t,n){return n==null||t==null?!1:t===n?!0:(0,uS.isCompositeType)(t)&&(0,uS.isCompositeType)(n)?(0,uS.doTypesOverlap)(e,t,n):!1}AT.implementsAbstractType=tte});var xU=w(RT=>{"use strict";m();T();N();Object.defineProperty(RT,"__esModule",{value:!0});RT.observableToAsyncIterable=void 0;function nte(e){let t=[],n=[],r=!0,i=f=>{t.length!==0?t.shift()({value:f,done:!1}):n.push({value:f,done:!1})},a=f=>{t.length!==0?t.shift()({value:{errors:[f]},done:!1}):n.push({value:{errors:[f]},done:!1})},o=()=>{t.length!==0?t.shift()({done:!0}):n.push({done:!0})},c=()=>new Promise(f=>{if(n.length!==0){let y=n.shift();f(y)}else t.push(f)}),l=e.subscribe({next(f){i(f)},error(f){a(f)},complete(){o()}}),p=()=>{if(r){r=!1,l.unsubscribe();for(let f of t)f({value:void 0,done:!0});t.length=0,n.length=0}};return{next(){return r?c():this.return()},return(){return p(),Promise.resolve({value:void 0,done:!0})},throw(f){return p(),Promise.reject(f)},[Symbol.asyncIterator](){return this}}}RT.observableToAsyncIterable=nte});var qU=w(PT=>{"use strict";m();T();N();Object.defineProperty(PT,"__esModule",{value:!0});PT.AccumulatorMap=void 0;var cS=class extends Map{get[Symbol.toStringTag](){return"AccumulatorMap"}add(t,n){let r=this.get(t);r===void 0?this.set(t,[n]):r.push(n)}};PT.AccumulatorMap=cS});var lS=w(Fl=>{"use strict";m();T();N();Object.defineProperty(Fl,"__esModule",{value:!0});Fl.GraphQLStreamDirective=Fl.GraphQLDeferDirective=void 0;var xi=Ae();Fl.GraphQLDeferDirective=new xi.GraphQLDirective({name:"defer",description:"Directs the executor to defer this fragment when the `if` argument is true or undefined.",locations:[xi.DirectiveLocation.FRAGMENT_SPREAD,xi.DirectiveLocation.INLINE_FRAGMENT],args:{if:{type:new xi.GraphQLNonNull(xi.GraphQLBoolean),description:"Deferred when true or undefined.",defaultValue:!0},label:{type:xi.GraphQLString,description:"Unique name"}}});Fl.GraphQLStreamDirective=new xi.GraphQLDirective({name:"stream",description:"Directs the executor to stream plural fields when the `if` argument is true or undefined.",locations:[xi.DirectiveLocation.FIELD],args:{if:{type:new xi.GraphQLNonNull(xi.GraphQLBoolean),description:"Stream when true or undefined.",defaultValue:!0},label:{type:xi.GraphQLString,description:"Unique name"},initialCount:{defaultValue:0,type:xi.GraphQLInt,description:"Number of items to return immediately"}}})});var fS=w(zr=>{"use strict";m();T();N();Object.defineProperty(zr,"__esModule",{value:!0});zr.collectSubFields=zr.getDeferValues=zr.getFieldEntryKey=zr.doesFragmentConditionMatch=zr.shouldIncludeNode=zr.collectFields=void 0;var Va=Ae(),wT=qU(),rte=lS(),ite=_l();function wl(e,t,n,r,i,a,o,c){for(let l of i.selections)switch(l.kind){case Va.Kind.FIELD:{if(!FT(n,l))continue;a.add(VU(l),l);break}case Va.Kind.INLINE_FRAGMENT:{if(!FT(n,l)||!dS(e,l,r))continue;let p=pS(n,l);if(p){let f=new wT.AccumulatorMap;wl(e,t,n,r,l.selectionSet,f,o,c),o.push({label:p.label,fields:f})}else wl(e,t,n,r,l.selectionSet,a,o,c);break}case Va.Kind.FRAGMENT_SPREAD:{let p=l.name.value;if(!FT(n,l))continue;let f=pS(n,l);if(c.has(p)&&!f)continue;let y=t[p];if(!y||!dS(e,y,r))continue;if(f||c.add(p),f){let g=new wT.AccumulatorMap;wl(e,t,n,r,y.selectionSet,g,o,c),o.push({label:f.label,fields:g})}else wl(e,t,n,r,y.selectionSet,a,o,c);break}}}function ate(e,t,n,r,i){let a=new wT.AccumulatorMap,o=[];return wl(e,t,n,r,i,a,o,new Set),{fields:a,patches:o}}zr.collectFields=ate;function FT(e,t){let n=(0,Va.getDirectiveValues)(Va.GraphQLSkipDirective,t,e);if((n==null?void 0:n.if)===!0)return!1;let r=(0,Va.getDirectiveValues)(Va.GraphQLIncludeDirective,t,e);return(r==null?void 0:r.if)!==!1}zr.shouldIncludeNode=FT;function dS(e,t,n){let r=t.typeCondition;if(!r)return!0;let i=(0,Va.typeFromAST)(e,r);return i===n?!0:(0,Va.isAbstractType)(i)?e.getPossibleTypes(i).includes(n):!1}zr.doesFragmentConditionMatch=dS;function VU(e){return e.alias?e.alias.value:e.name.value}zr.getFieldEntryKey=VU;function pS(e,t){let n=(0,Va.getDirectiveValues)(rte.GraphQLDeferDirective,t,e);if(n&&n.if!==!1)return{label:typeof n.label=="string"?n.label:void 0}}zr.getDeferValues=pS;zr.collectSubFields=(0,ite.memoize5)(function(t,n,r,i,a){let o=new wT.AccumulatorMap,c=new Set,l=[],p={fields:o,patches:l};for(let f of a)f.selectionSet&&wl(t,n,r,i,f.selectionSet,o,l,c);return p})});var mS=w(Ll=>{"use strict";m();T();N();Object.defineProperty(Ll,"__esModule",{value:!0});Ll.getOperationASTFromRequest=Ll.getOperationASTFromDocument=void 0;var ste=Ae(),ote=_l();function jU(e,t){let n=(0,ste.getOperationAST)(e,t);if(!n)throw new Error(`Cannot infer operation ${t||""}`);return n}Ll.getOperationASTFromDocument=jU;Ll.getOperationASTFromRequest=(0,ote.memoize1)(function(t){return jU(t.document,t.operationName)})});var $U=w(lu=>{"use strict";m();T();N();Object.defineProperty(lu,"__esModule",{value:!0});lu.visitResult=lu.visitErrors=lu.visitData=void 0;var cu=Ae(),NS=fS(),ute=mS();function TS(e,t,n){if(Array.isArray(e))return e.map(r=>TS(r,t,n));if(typeof e=="object"){let r=t!=null?t(e):e;if(r!=null)for(let i in r){let a=r[i];Object.defineProperty(r,i,{value:TS(a,t,n)})}return n!=null?n(r):r}return e}lu.visitData=TS;function cte(e,t){return e.map(n=>t(n))}lu.visitErrors=cte;function lte(e,t,n,r,i){let a=t.document.definitions.reduce((g,v)=>(v.kind===cu.Kind.FRAGMENT_DEFINITION&&(g[v.name.value]=v),g),{}),o=t.variables||{},c={segmentInfoMap:new Map,unpathedErrors:new Set},l=e.data,p=e.errors,f=p!=null&&i!=null,y=(0,ute.getOperationASTFromRequest)(t);return l!=null&&y!=null&&(e.data=fte(l,y,n,a,o,r,f?p:void 0,c)),p!=null&&i&&(e.errors=dte(p,i,c)),e}lu.visitResult=lte;function dte(e,t,n){let r=n.segmentInfoMap,i=n.unpathedErrors,a=t.__unpathed;return e.map(o=>{let c=r.get(o),l=c==null?o:c.reduceRight((p,f)=>{let y=f.type.name,g=t[y];if(g==null)return p;let v=g[f.fieldName];return v==null?p:v(p,f.pathIndex)},o);return a&&i.has(o)?a(l):l})}function pte(e,t){switch(t.operation){case"query":return e.getQueryType();case"mutation":return e.getMutationType();case"subscription":return e.getSubscriptionType()}}function fte(e,t,n,r,i,a,o,c){let l=pte(n,t),{fields:p}=(0,NS.collectFields)(n,r,i,l,t.selectionSet);return ES(e,l,p,n,r,i,a,0,o,c)}function ES(e,t,n,r,i,a,o,c,l,p){var ne;let f=t.getFields(),y=o==null?void 0:o[t.name],g=y==null?void 0:y.__enter,v=g!=null?g(e):e,P,U=null;if(l!=null){P=Nte(l,c),U=P.errorMap;for(let z of P.unpathedErrors)p.unpathedErrors.add(z)}for(let[z,Te]of n){let pe=Te[0].name.value,Fe=(ne=f[pe])==null?void 0:ne.type;if(Fe==null)switch(pe){case"__typename":Fe=cu.TypeNameMetaFieldDef.type;break;case"__schema":Fe=cu.SchemaMetaFieldDef.type;break;case"__type":Fe=cu.TypeMetaFieldDef.type;break}let xe=c+1,et;U&&(et=U[z],et!=null&&delete U[z],Tte(t,pe,xe,et,p));let X=GU(e[z],Fe,Te,r,i,a,o,xe,et,p);KU(v,z,X,y,pe)}let K=v.__typename;if(K!=null&&KU(v,"__typename",K,y,"__typename"),U)for(let z in U){let Te=U[z];for(let pe of Te)p.unpathedErrors.add(pe)}let $=y==null?void 0:y.__leave;return $!=null?$(v):v}function KU(e,t,n,r,i){if(r==null){e[t]=n;return}let a=r[i];if(a==null){e[t]=n;return}let o=a(n);if(o===void 0){delete e[t];return}e[t]=o}function mte(e,t,n,r,i,a,o,c,l,p){return e.map(f=>GU(f,t,n,r,i,a,o,c+1,l,p))}function GU(e,t,n,r,i,a,o,c,l=[],p){if(e==null)return e;let f=(0,cu.getNullableType)(t);if((0,cu.isListType)(f))return mte(e,f.ofType,n,r,i,a,o,c,l,p);if((0,cu.isAbstractType)(f)){let v=r.getType(e.__typename),{fields:P}=(0,NS.collectSubFields)(r,i,a,v,n);return ES(e,v,P,r,i,a,o,c,l,p)}else if((0,cu.isObjectType)(f)){let{fields:v}=(0,NS.collectSubFields)(r,i,a,f,n);return ES(e,f,v,r,i,a,o,c,l,p)}let y=o==null?void 0:o[f.name];if(y==null)return e;let g=y(e);return g===void 0?e:g}function Nte(e,t){var i;let n=Object.create(null),r=new Set;for(let a of e){let o=(i=a.path)==null?void 0:i[t];if(o==null){r.add(a);continue}o in n?n[o].push(a):n[o]=[a]}return{errorMap:n,unpathedErrors:r}}function Tte(e,t,n,r=[],i){for(let a of r){let o={type:e,fieldName:t,pathIndex:n},c=i.segmentInfoMap.get(a);c==null?i.segmentInfoMap.set(a,[o]):c.push(o)}}});var QU=w(LT=>{"use strict";m();T();N();Object.defineProperty(LT,"__esModule",{value:!0});LT.valueMatchesCriteria=void 0;function hS(e,t){return e==null?e===t:Array.isArray(e)?Array.isArray(t)&&e.every((n,r)=>hS(n,t[r])):typeof e=="object"?typeof t=="object"&&t&&Object.keys(t).every(n=>hS(e[n],t[n])):t instanceof RegExp?t.test(e):e===t}LT.valueMatchesCriteria=hS});var YU=w(CT=>{"use strict";m();T();N();Object.defineProperty(CT,"__esModule",{value:!0});CT.isAsyncIterable=void 0;function Ete(e){return(e==null?void 0:e[Symbol.asyncIterator])!=null}CT.isAsyncIterable=Ete});var JU=w(BT=>{"use strict";m();T();N();Object.defineProperty(BT,"__esModule",{value:!0});BT.isDocumentNode=void 0;var hte=Ae();function yte(e){return e&&typeof e=="object"&&"kind"in e&&e.kind===hte.Kind.DOCUMENT}BT.isDocumentNode=yte});var HU=w(()=>{"use strict";m();T();N()});var ZU=w(du=>{"use strict";m();T();N();Object.defineProperty(du,"__esModule",{value:!0});du.withCancel=du.getAsyncIterableWithCancel=du.getAsyncIteratorWithCancel=void 0;var Ite=_l();function gte(e){return vi(this,null,function*(){return{value:e,done:!0}})}var zU=(0,Ite.memoize2)(function(t,n){return function(...i){return Reflect.apply(n,t,i)}});function WU(e,t){return new Proxy(e,{has(n,r){return r==="return"?!0:Reflect.has(n,r)},get(n,r,i){let a=Reflect.get(n,r,i);if(r==="return"){let o=a||gte;return function(l){return vi(this,null,function*(){let p=yield t(l);return Reflect.apply(o,n,[p])})}}else if(typeof a=="function")return zU(n,a);return a}})}du.getAsyncIteratorWithCancel=WU;function XU(e,t){return new Proxy(e,{get(n,r,i){let a=Reflect.get(n,r,i);return Symbol.asyncIterator===r?function(){let c=Reflect.apply(a,n,[]);return WU(c,t)}:typeof a=="function"?zU(n,a):a}})}du.getAsyncIterableWithCancel=XU;du.withCancel=XU});var ek=w(UT=>{"use strict";m();T();N();Object.defineProperty(UT,"__esModule",{value:!0});UT.fixSchemaAst=void 0;var _te=Ae(),vte=Kv();function Ste(e,t){let n=(0,vte.getDocumentNodeFromSchema)(e);return(0,_te.buildASTSchema)(n,x({},t||{}))}function Ote(e,t){let n;return(!e.astNode||!e.extensionASTNodes)&&(n=Ste(e,t)),!e.astNode&&(n!=null&&n.astNode)&&(e.astNode=n.astNode),!e.extensionASTNodes&&(n!=null&&n.astNode)&&(e.extensionASTNodes=n.extensionASTNodes),e}UT.fixSchemaAst=Ote});var tk=w(kT=>{"use strict";m();T();N();Object.defineProperty(kT,"__esModule",{value:!0});kT.extractExtensionsFromSchema=void 0;var ys=oc(),Dte=Al();function sa(e={}){let t=x({},e),n=t.directives;if(n!=null)for(let r in n){let i=n[r];Array.isArray(i)||(n[r]=[i])}return t}function bte(e){let t={schemaExtensions:sa(e.extensions),types:{}};return(0,Dte.mapSchema)(e,{[ys.MapperKind.OBJECT_TYPE]:n=>(t.types[n.name]={fields:{},type:"object",extensions:sa(n.extensions)},n),[ys.MapperKind.INTERFACE_TYPE]:n=>(t.types[n.name]={fields:{},type:"interface",extensions:sa(n.extensions)},n),[ys.MapperKind.FIELD]:(n,r,i)=>{t.types[i].fields[r]={arguments:{},extensions:sa(n.extensions)};let a=n.args;if(a!=null)for(let o in a)t.types[i].fields[r].arguments[o]=sa(a[o].extensions);return n},[ys.MapperKind.ENUM_TYPE]:n=>(t.types[n.name]={values:{},type:"enum",extensions:sa(n.extensions)},n),[ys.MapperKind.ENUM_VALUE]:(n,r,i,a)=>(t.types[r].values[a]=sa(n.extensions),n),[ys.MapperKind.SCALAR_TYPE]:n=>(t.types[n.name]={type:"scalar",extensions:sa(n.extensions)},n),[ys.MapperKind.UNION_TYPE]:n=>(t.types[n.name]={type:"union",extensions:sa(n.extensions)},n),[ys.MapperKind.INPUT_OBJECT_TYPE]:n=>(t.types[n.name]={fields:{},type:"input",extensions:sa(n.extensions)},n),[ys.MapperKind.INPUT_OBJECT_FIELD]:(n,r,i)=>(t.types[i].fields[r]={extensions:sa(n.extensions)},n)}),t}kT.extractExtensionsFromSchema=bte});var nk=w(pu=>{"use strict";m();T();N();Object.defineProperty(pu,"__esModule",{value:!0});pu.printPathArray=pu.pathToArray=pu.addPath=void 0;function Ate(e,t,n){return{prev:e,key:t,typename:n}}pu.addPath=Ate;function Rte(e){let t=[],n=e;for(;n;)t.push(n.key),n=n.prev;return t.reverse()}pu.pathToArray=Rte;function Pte(e){return e.map(t=>typeof t=="number"?"["+t.toString()+"]":"."+t).join("")}pu.printPathArray=Pte});var rk=w(yS=>{"use strict";m();T();N();function MT(e,t,n){if(typeof e=="object"&&typeof t=="object"){if(Array.isArray(e)&&Array.isArray(t))for(n=0;n{"use strict";m();T();N();Object.defineProperty(xT,"__esModule",{value:!0});xT.mergeIncrementalResult=void 0;var IS=rk();function ik({incrementalResult:e,executionResult:t}){var r;let n=["data",...(r=e.path)!=null?r:[]];if(e.items)for(let i of e.items)(0,IS.dset)(t,n,i),n[n.length-1]++;e.data&&(0,IS.dset)(t,n,e.data),e.errors&&(t.errors=t.errors||[],t.errors.push(...e.errors)),e.extensions&&(0,IS.dset)(t,"extensions",e.extensions),e.incremental&&e.incremental.forEach(i=>{ik({incrementalResult:i,executionResult:t})})}xT.mergeIncrementalResult=ik});var ok=w(Cl=>{"use strict";m();T();N();Object.defineProperty(Cl,"__esModule",{value:!0});Cl.debugTimerEnd=Cl.debugTimerStart=void 0;var sk=new Set;function wte(e){let t=(globalThis==null?void 0:globalThis.process.env.DEBUG)||globalThis.DEBUG;(t==="1"||t!=null&&t.includes(e))&&(sk.add(e),console.time(e))}Cl.debugTimerStart=wte;function Lte(e){sk.has(e)&&console.timeEnd(e)}Cl.debugTimerEnd=Lte});var oa=w(Ge=>{"use strict";m();T();N();Object.defineProperty(Ge,"__esModule",{value:!0});Ge.inspect=void 0;var Ye=(mB(),om(fB));Ye.__exportStar(NB(),Ge);Ye.__exportStar(Ip(),Ge);Ye.__exportStar(Fv(),Ge);Ye.__exportStar(wv(),Ge);Ye.__exportStar(OB(),Ge);Ye.__exportStar(Cv(),Ge);Ye.__exportStar(Kv(),Ge);Ye.__exportStar(wv(),Ge);Ye.__exportStar(jB(),Ge);Ye.__exportStar(KB(),Ge);Ye.__exportStar(nU(),Ge);Ye.__exportStar(lU(),Ge);Ye.__exportStar(pU(),Ge);Ye.__exportStar(yU(),Ge);Ye.__exportStar(gU(),Ge);Ye.__exportStar(_U(),Ge);Ye.__exportStar(SU(),Ge);Ye.__exportStar(OU(),Ge);Ye.__exportStar(Al(),Ge);Ye.__exportStar(sS(),Ge);Ye.__exportStar(lT(),Ge);Ye.__exportStar(bU(),Ge);Ye.__exportStar(RU(),Ge);Ye.__exportStar(oc(),Ge);Ye.__exportStar(Xv(),Ge);Ye.__exportStar(PU(),Ge);Ye.__exportStar(FU(),Ge);Ye.__exportStar(wU(),Ge);Ye.__exportStar(LU(),Ge);Ye.__exportStar(Zv(),Ge);Ye.__exportStar(UU(),Ge);Ye.__exportStar(kU(),Ge);Ye.__exportStar(MU(),Ge);Ye.__exportStar($N(),Ge);Ye.__exportStar(xU(),Ge);Ye.__exportStar($U(),Ge);Ye.__exportStar(Pv(),Ge);Ye.__exportStar(QU(),Ge);Ye.__exportStar(YU(),Ge);Ye.__exportStar(JU(),Ge);Ye.__exportStar(ZN(),Ge);Ye.__exportStar(HU(),Ge);Ye.__exportStar(ZU(),Ge);Ye.__exportStar(Sp(),Ge);Ye.__exportStar($v(),Ge);Ye.__exportStar(fS(),Ge);var Cte=gp();Object.defineProperty(Ge,"inspect",{enumerable:!0,get:function(){return Cte.inspect}});Ye.__exportStar(_l(),Ge);Ye.__exportStar(ek(),Ge);Ye.__exportStar(mS(),Ge);Ye.__exportStar(tk(),Ge);Ye.__exportStar(nk(),Ge);Ye.__exportStar(_p(),Ge);Ye.__exportStar(lS(),Ge);Ye.__exportStar(ak(),Ge);Ye.__exportStar(ok(),Ge)});var ck=w(qT=>{"use strict";m();T();N();Object.defineProperty(qT,"__esModule",{value:!0});qT.mergeResolvers=void 0;var Bte=oa();function uk(e,t){if(!e||Array.isArray(e)&&e.length===0)return{};if(!Array.isArray(e))return e;if(e.length===1)return e[0]||{};let n=new Array;for(let i of e)Array.isArray(i)&&(i=uk(i)),typeof i=="object"&&i&&n.push(i);let r=(0,Bte.mergeDeep)(n,!0);if(t!=null&&t.exclusions)for(let i of t.exclusions){let[a,o]=i.split(".");!o||o==="*"?delete r[a]:r[a]&&delete r[a][o]}return r}qT.mergeResolvers=uk});var gS=w(VT=>{"use strict";m();T();N();Object.defineProperty(VT,"__esModule",{value:!0});VT.mergeArguments=void 0;var lk=oa();function Ute(e,t,n){let r=kte([...t,...e].filter(lk.isSome),n);return n&&n.sort&&r.sort(lk.compareNodes),r}VT.mergeArguments=Ute;function kte(e,t){return e.reduce((n,r)=>{let i=n.findIndex(a=>a.name.value===r.name.value);return i===-1?n.concat([r]):(t!=null&&t.reverseArguments||(n[i]=r),n)},[])}});var qi=w(Bl=>{"use strict";m();T();N();Object.defineProperty(Bl,"__esModule",{value:!0});Bl.mergeDirective=Bl.mergeDirectives=void 0;var dk=Ae(),Mte=oa();function xte(e,t){return!!e.find(n=>n.name.value===t.name.value)}function pk(e,t){var n;return!!((n=t==null?void 0:t[e.name.value])!=null&&n.repeatable)}function qte(e,t){return t.some(({value:n})=>n===e.value)}function fk(e,t){let n=[...t];for(let r of e){let i=n.findIndex(a=>a.name.value===r.name.value);if(i>-1){let a=n[i];if(a.value.kind==="ListValue"){let o=a.value.values,c=r.value.values;a.value.values=$te(o,c,(l,p)=>{let f=l.value;return!f||!p.some(y=>y.value===f)})}else a.value=r.value}else n.push(r)}return n}function Vte(e,t){return e.map((n,r,i)=>{let a=i.findIndex(o=>o.name.value===n.name.value);if(a!==r&&!pk(n,t)){let o=i[a];return n.arguments=fk(n.arguments,o.arguments),null}return n}).filter(Mte.isSome)}function jte(e=[],t=[],n,r){let i=n&&n.reverseDirectives,a=i?e:t,o=i?t:e,c=Vte([...a],r);for(let l of o)if(xte(c,l)&&!pk(l,r)){let p=c.findIndex(y=>y.name.value===l.name.value),f=c[p];c[p].arguments=fk(l.arguments||[],f.arguments||[])}else c.push(l);return c}Bl.mergeDirectives=jte;function Kte(e,t){let n=(0,dk.print)(Y(x({},e),{description:void 0})),r=(0,dk.print)(Y(x({},t),{description:void 0})),i=new RegExp("(directive @w*d*)|( on .*$)","g");if(!(n.replace(i,"")===r.replace(i,"")))throw new Error(`Unable to merge GraphQL directive "${e.name.value}". Existing directive: ${r} Received directive: - ${n}`)}function Gte(e,t){return t?(Kte(e,t),Y(x({},e),{locations:[...t.locations,...e.locations.filter(n=>!qte(n,t.locations))]})):e}Bl.mergeDirective=Gte;function $te(e,t,n){return e.concat(t.filter(r=>n(r,e)))}});var _S=w(jT=>{"use strict";m();T();N();Object.defineProperty(jT,"__esModule",{value:!0});jT.mergeEnumValues=void 0;var Qte=qi(),Yte=oa();function Jte(e,t,n,r){if(n!=null&&n.consistentEnumMerge){let o=[];e&&o.push(...e),e=t,t=o}let i=new Map;if(e)for(let o of e)i.set(o.name.value,o);if(t)for(let o of t){let c=o.name.value;if(i.has(c)){let l=i.get(c);l.description=o.description||l.description,l.directives=(0,Qte.mergeDirectives)(o.directives,l.directives,r)}else i.set(c,o)}let a=[...i.values()];return n&&n.sort&&a.sort(Yte.compareNodes),a}jT.mergeEnumValues=Jte});var vS=w(KT=>{"use strict";m();T();N();Object.defineProperty(KT,"__esModule",{value:!0});KT.mergeEnum=void 0;var Hte=Ae(),zte=qi(),Wte=_S();function Xte(e,t,n,r){return t?{name:e.name,description:e.description||t.description,kind:n!=null&&n.convertExtensions||e.kind==="EnumTypeDefinition"||t.kind==="EnumTypeDefinition"?"EnumTypeDefinition":"EnumTypeExtension",loc:e.loc,directives:(0,zte.mergeDirectives)(e.directives,t.directives,n,r),values:(0,Wte.mergeEnumValues)(e.values,t.values,n)}:n!=null&&n.convertExtensions?Y(x({},e),{kind:Hte.Kind.ENUM_TYPE_DEFINITION}):e}KT.mergeEnum=Xte});var GT=w(qn=>{"use strict";m();T();N();Object.defineProperty(qn,"__esModule",{value:!0});qn.defaultStringComparator=qn.CompareVal=qn.printTypeNode=qn.isNonNullTypeNode=qn.isListTypeNode=qn.isWrappingTypeNode=qn.extractType=qn.isSourceTypes=qn.isStringTypes=void 0;var Fp=Ae();function Zte(e){return typeof e=="string"}qn.isStringTypes=Zte;function ene(e){return e instanceof Fp.Source}qn.isSourceTypes=ene;function tne(e){let t=e;for(;t.kind===Fp.Kind.LIST_TYPE||t.kind==="NonNullType";)t=t.type;return t}qn.extractType=tne;function nne(e){return e.kind!==Fp.Kind.NAMED_TYPE}qn.isWrappingTypeNode=nne;function mk(e){return e.kind===Fp.Kind.LIST_TYPE}qn.isListTypeNode=mk;function Nk(e){return e.kind===Fp.Kind.NON_NULL_TYPE}qn.isNonNullTypeNode=Nk;function SS(e){return mk(e)?`[${SS(e.type)}]`:Nk(e)?`${SS(e.type)}!`:e.name.value}qn.printTypeNode=SS;var dc;(function(e){e[e.A_SMALLER_THAN_B=-1]="A_SMALLER_THAN_B",e[e.A_EQUALS_B=0]="A_EQUALS_B",e[e.A_GREATER_THAN_B=1]="A_GREATER_THAN_B"})(dc=qn.CompareVal||(qn.CompareVal={}));function rne(e,t){return e==null&&t==null?dc.A_EQUALS_B:e==null?dc.A_SMALLER_THAN_B:t==null?dc.A_GREATER_THAN_B:et?dc.A_GREATER_THAN_B:dc.A_EQUALS_B}qn.defaultStringComparator=rne});var Lp=w($T=>{"use strict";m();T();N();Object.defineProperty($T,"__esModule",{value:!0});$T.mergeFields=void 0;var Wr=GT(),ine=qi(),ane=oa(),sne=gS();function one(e,t){let n=e.findIndex(r=>r.name.value===t.name.value);return[n>-1?e[n]:null,n]}function une(e,t,n,r,i){let a=[];if(n!=null&&a.push(...n),t!=null)for(let o of t){let[c,l]=one(a,o);if(c&&!(r!=null&&r.ignoreFieldConflicts)){let p=(r==null?void 0:r.onFieldTypeConflict)&&r.onFieldTypeConflict(c,o,e,r==null?void 0:r.throwOnConflict)||cne(e,c,o,r==null?void 0:r.throwOnConflict);p.arguments=(0,sne.mergeArguments)(o.arguments||[],c.arguments||[],r),p.directives=(0,ine.mergeDirectives)(o.directives,c.directives,r,i),p.description=o.description||c.description,a[l]=p}else a.push(o)}if(r&&r.sort&&a.sort(ane.compareNodes),r&&r.exclusions){let o=r.exclusions;return a.filter(c=>!o.includes(`${e.name.value}.${c.name.value}`))}return a}$T.mergeFields=une;function cne(e,t,n,r=!1){let i=(0,Wr.printTypeNode)(t.type),a=(0,Wr.printTypeNode)(n.type);if(i!==a){let o=(0,Wr.extractType)(t.type),c=(0,Wr.extractType)(n.type);if(o.name.value!==c.name.value)throw new Error(`Field "${n.name.value}" already defined with a different type. Declared as "${o.name.value}", but you tried to override with "${c.name.value}"`);if(!wp(t.type,n.type,!r))throw new Error(`Field '${e.name.value}.${t.name.value}' changed type from '${i}' to '${a}'`)}return(0,Wr.isNonNullTypeNode)(n.type)&&!(0,Wr.isNonNullTypeNode)(t.type)&&(t.type=n.type),t}function wp(e,t,n=!1){if(!(0,Wr.isWrappingTypeNode)(e)&&!(0,Wr.isWrappingTypeNode)(t))return e.toString()===t.toString();if((0,Wr.isNonNullTypeNode)(t)){let r=(0,Wr.isNonNullTypeNode)(e)?e.type:e;return wp(r,t.type)}return(0,Wr.isNonNullTypeNode)(e)?wp(t,e,n):(0,Wr.isListTypeNode)(e)?(0,Wr.isListTypeNode)(t)&&wp(e.type,t.type)||(0,Wr.isNonNullTypeNode)(t)&&wp(e,t.type):!1}});var OS=w(QT=>{"use strict";m();T();N();Object.defineProperty(QT,"__esModule",{value:!0});QT.mergeInputType=void 0;var lne=Ae(),dne=Lp(),pne=qi();function fne(e,t,n,r){if(t)try{return{name:e.name,description:e.description||t.description,kind:n!=null&&n.convertExtensions||e.kind==="InputObjectTypeDefinition"||t.kind==="InputObjectTypeDefinition"?"InputObjectTypeDefinition":"InputObjectTypeExtension",loc:e.loc,fields:(0,dne.mergeFields)(e,e.fields,t.fields,n),directives:(0,pne.mergeDirectives)(e.directives,t.directives,n,r)}}catch(i){throw new Error(`Unable to merge GraphQL input type "${e.name.value}": ${i.message}`)}return n!=null&&n.convertExtensions?Y(x({},e),{kind:lne.Kind.INPUT_OBJECT_TYPE_DEFINITION}):e}QT.mergeInputType=fne});var Cp=w(YT=>{"use strict";m();T();N();Object.defineProperty(YT,"__esModule",{value:!0});YT.mergeNamedTypeArray=void 0;var mne=oa();function Nne(e,t){return!!e.find(n=>n.name.value===t.name.value)}function Tne(e=[],t=[],n={}){let r=[...t,...e.filter(i=>!Nne(t,i))];return n&&n.sort&&r.sort(mne.compareNodes),r}YT.mergeNamedTypeArray=Tne});var DS=w(JT=>{"use strict";m();T();N();Object.defineProperty(JT,"__esModule",{value:!0});JT.mergeInterface=void 0;var Ene=Ae(),hne=Lp(),yne=qi(),Ine=Cp();function gne(e,t,n,r){if(t)try{return{name:e.name,description:e.description||t.description,kind:n!=null&&n.convertExtensions||e.kind==="InterfaceTypeDefinition"||t.kind==="InterfaceTypeDefinition"?"InterfaceTypeDefinition":"InterfaceTypeExtension",loc:e.loc,fields:(0,hne.mergeFields)(e,e.fields,t.fields,n),directives:(0,yne.mergeDirectives)(e.directives,t.directives,n,r),interfaces:e.interfaces?(0,Ine.mergeNamedTypeArray)(e.interfaces,t.interfaces,n):void 0}}catch(i){throw new Error(`Unable to merge GraphQL interface "${e.name.value}": ${i.message}`)}return n!=null&&n.convertExtensions?Y(x({},e),{kind:Ene.Kind.INTERFACE_TYPE_DEFINITION}):e}JT.mergeInterface=gne});var bS=w(HT=>{"use strict";m();T();N();Object.defineProperty(HT,"__esModule",{value:!0});HT.mergeType=void 0;var _ne=Ae(),vne=Lp(),Sne=qi(),One=Cp();function Dne(e,t,n,r){if(t)try{return{name:e.name,description:e.description||t.description,kind:n!=null&&n.convertExtensions||e.kind==="ObjectTypeDefinition"||t.kind==="ObjectTypeDefinition"?"ObjectTypeDefinition":"ObjectTypeExtension",loc:e.loc,fields:(0,vne.mergeFields)(e,e.fields,t.fields,n),directives:(0,Sne.mergeDirectives)(e.directives,t.directives,n,r),interfaces:(0,One.mergeNamedTypeArray)(e.interfaces,t.interfaces,n)}}catch(i){throw new Error(`Unable to merge GraphQL type "${e.name.value}": ${i.message}`)}return n!=null&&n.convertExtensions?Y(x({},e),{kind:_ne.Kind.OBJECT_TYPE_DEFINITION}):e}HT.mergeType=Dne});var AS=w(zT=>{"use strict";m();T();N();Object.defineProperty(zT,"__esModule",{value:!0});zT.mergeScalar=void 0;var bne=Ae(),Ane=qi();function Rne(e,t,n,r){return t?{name:e.name,description:e.description||t.description,kind:n!=null&&n.convertExtensions||e.kind==="ScalarTypeDefinition"||t.kind==="ScalarTypeDefinition"?"ScalarTypeDefinition":"ScalarTypeExtension",loc:e.loc,directives:(0,Ane.mergeDirectives)(e.directives,t.directives,n,r)}:n!=null&&n.convertExtensions?Y(x({},e),{kind:bne.Kind.SCALAR_TYPE_DEFINITION}):e}zT.mergeScalar=Rne});var PS=w(WT=>{"use strict";m();T();N();Object.defineProperty(WT,"__esModule",{value:!0});WT.mergeUnion=void 0;var RS=Ae(),Pne=qi(),Fne=Cp();function wne(e,t,n,r){return t?{name:e.name,description:e.description||t.description,directives:(0,Pne.mergeDirectives)(e.directives,t.directives,n,r),kind:n!=null&&n.convertExtensions||e.kind==="UnionTypeDefinition"||t.kind==="UnionTypeDefinition"?RS.Kind.UNION_TYPE_DEFINITION:RS.Kind.UNION_TYPE_EXTENSION,loc:e.loc,types:(0,Fne.mergeNamedTypeArray)(e.types,t.types,n)}:n!=null&&n.convertExtensions?Y(x({},e),{kind:RS.Kind.UNION_TYPE_DEFINITION}):e}WT.mergeUnion=wne});var FS=w(pc=>{"use strict";m();T();N();Object.defineProperty(pc,"__esModule",{value:!0});pc.mergeSchemaDefs=pc.DEFAULT_OPERATION_TYPE_NAME_MAP=void 0;var Bp=Ae(),Lne=qi();pc.DEFAULT_OPERATION_TYPE_NAME_MAP={query:"Query",mutation:"Mutation",subscription:"Subscription"};function Cne(e=[],t=[]){let n=[];for(let r in pc.DEFAULT_OPERATION_TYPE_NAME_MAP){let i=e.find(a=>a.operation===r)||t.find(a=>a.operation===r);i&&n.push(i)}return n}function Bne(e,t,n,r){return t?{kind:e.kind===Bp.Kind.SCHEMA_DEFINITION||t.kind===Bp.Kind.SCHEMA_DEFINITION?Bp.Kind.SCHEMA_DEFINITION:Bp.Kind.SCHEMA_EXTENSION,description:e.description||t.description,directives:(0,Lne.mergeDirectives)(e.directives,t.directives,n,r),operationTypes:Cne(e.operationTypes,t.operationTypes)}:n!=null&&n.convertExtensions?Y(x({},e),{kind:Bp.Kind.SCHEMA_DEFINITION}):e}pc.mergeSchemaDefs=Bne});var wS=w(ja=>{"use strict";m();T();N();Object.defineProperty(ja,"__esModule",{value:!0});ja.mergeGraphQLNodes=ja.isNamedDefinitionNode=ja.schemaDefSymbol=void 0;var Br=Ae(),Une=bS(),kne=vS(),Mne=AS(),xne=PS(),qne=OS(),Vne=DS(),jne=qi(),Kne=FS(),Gne=oa();ja.schemaDefSymbol="SCHEMA_DEF_SYMBOL";function Tk(e){return"name"in e}ja.isNamedDefinitionNode=Tk;function $ne(e,t,n={}){var i,a,o;let r=n;for(let c of e)if(Tk(c)){let l=(i=c.name)==null?void 0:i.value;if(t!=null&&t.commentDescriptions&&(0,Gne.collectComment)(c),l==null)continue;if((a=t==null?void 0:t.exclusions)!=null&&a.includes(l+".*")||(o=t==null?void 0:t.exclusions)!=null&&o.includes(l))delete r[l];else switch(c.kind){case Br.Kind.OBJECT_TYPE_DEFINITION:case Br.Kind.OBJECT_TYPE_EXTENSION:r[l]=(0,Une.mergeType)(c,r[l],t,n);break;case Br.Kind.ENUM_TYPE_DEFINITION:case Br.Kind.ENUM_TYPE_EXTENSION:r[l]=(0,kne.mergeEnum)(c,r[l],t,n);break;case Br.Kind.UNION_TYPE_DEFINITION:case Br.Kind.UNION_TYPE_EXTENSION:r[l]=(0,xne.mergeUnion)(c,r[l],t,n);break;case Br.Kind.SCALAR_TYPE_DEFINITION:case Br.Kind.SCALAR_TYPE_EXTENSION:r[l]=(0,Mne.mergeScalar)(c,r[l],t,n);break;case Br.Kind.INPUT_OBJECT_TYPE_DEFINITION:case Br.Kind.INPUT_OBJECT_TYPE_EXTENSION:r[l]=(0,qne.mergeInputType)(c,r[l],t,n);break;case Br.Kind.INTERFACE_TYPE_DEFINITION:case Br.Kind.INTERFACE_TYPE_EXTENSION:r[l]=(0,Vne.mergeInterface)(c,r[l],t,n);break;case Br.Kind.DIRECTIVE_DEFINITION:r[l]=(0,jne.mergeDirective)(c,r[l]);break}}else(c.kind===Br.Kind.SCHEMA_DEFINITION||c.kind===Br.Kind.SCHEMA_EXTENSION)&&(r[ja.schemaDefSymbol]=(0,Kne.mergeSchemaDefs)(c,r[ja.schemaDefSymbol],t));return r}ja.mergeGraphQLNodes=$ne});var yk=w(xl=>{"use strict";m();T();N();Object.defineProperty(xl,"__esModule",{value:!0});xl.mergeGraphQLTypes=xl.mergeTypeDefs=void 0;var Vi=Ae(),LS=GT(),Ul=wS(),Ml=oa(),Ek=FS();function Qne(e,t){(0,Ml.resetComments)();let n={kind:Vi.Kind.DOCUMENT,definitions:hk(e,x({useSchemaDefinition:!0,forceSchemaDefinition:!1,throwOnConflict:!1,commentDescriptions:!1},t))},r;return t!=null&&t.commentDescriptions?r=(0,Ml.printWithComments)(n):r=n,(0,Ml.resetComments)(),r}xl.mergeTypeDefs=Qne;function kl(e,t,n=[],r=[],i=new Set){if(e&&!i.has(e))if(i.add(e),typeof e=="function")kl(e(),t,n,r,i);else if(Array.isArray(e))for(let a of e)kl(a,t,n,r,i);else if((0,Vi.isSchema)(e)){let a=(0,Ml.getDocumentNodeFromSchema)(e,t);kl(a.definitions,t,n,r,i)}else if((0,LS.isStringTypes)(e)||(0,LS.isSourceTypes)(e)){let a=(0,Vi.parse)(e,t);kl(a.definitions,t,n,r,i)}else if(typeof e=="object"&&(0,Vi.isDefinitionNode)(e))e.kind===Vi.Kind.DIRECTIVE_DEFINITION?n.push(e):r.push(e);else if((0,Ml.isDocumentNode)(e))kl(e.definitions,t,n,r,i);else throw new Error(`typeDefs must contain only strings, documents, schemas, or functions, got ${typeof e}`);return{allDirectives:n,allNodes:r}}function hk(e,t){var c,l,p;(0,Ml.resetComments)();let{allDirectives:n,allNodes:r}=kl(e,t),i=(0,Ul.mergeGraphQLNodes)(n,t),a=(0,Ul.mergeGraphQLNodes)(r,t,i);if(t!=null&&t.useSchemaDefinition){let f=a[Ul.schemaDefSymbol]||{kind:Vi.Kind.SCHEMA_DEFINITION,operationTypes:[]},y=f.operationTypes;for(let g in Ek.DEFAULT_OPERATION_TYPE_NAME_MAP)if(!y.find(F=>F.operation===g)){let F=Ek.DEFAULT_OPERATION_TYPE_NAME_MAP[g],k=a[F];k!=null&&k.name!=null&&y.push({kind:Vi.Kind.OPERATION_TYPE_DEFINITION,type:{kind:Vi.Kind.NAMED_TYPE,name:k.name},operation:g})}((c=f==null?void 0:f.operationTypes)==null?void 0:c.length)!=null&&f.operationTypes.length>0&&(a[Ul.schemaDefSymbol]=f)}t!=null&&t.forceSchemaDefinition&&!((p=(l=a[Ul.schemaDefSymbol])==null?void 0:l.operationTypes)!=null&&p.length)&&(a[Ul.schemaDefSymbol]={kind:Vi.Kind.SCHEMA_DEFINITION,operationTypes:[{kind:Vi.Kind.OPERATION_TYPE_DEFINITION,operation:"query",type:{kind:Vi.Kind.NAMED_TYPE,name:{kind:Vi.Kind.NAME,value:"Query"}}}]});let o=Object.values(a);if(t!=null&&t.sort){let f=typeof t.sort=="function"?t.sort:LS.defaultStringComparator;o.sort((y,g)=>{var v,F;return f((v=y.name)==null?void 0:v.value,(F=g.name)==null?void 0:F.value)})}return o}xl.mergeGraphQLTypes=hk});var Ik=w(Dr=>{"use strict";m();T();N();Object.defineProperty(Dr,"__esModule",{value:!0});var Xr=(vv(),om(_v));Xr.__exportStar(gS(),Dr);Xr.__exportStar(qi(),Dr);Xr.__exportStar(_S(),Dr);Xr.__exportStar(vS(),Dr);Xr.__exportStar(Lp(),Dr);Xr.__exportStar(OS(),Dr);Xr.__exportStar(DS(),Dr);Xr.__exportStar(Cp(),Dr);Xr.__exportStar(wS(),Dr);Xr.__exportStar(yk(),Dr);Xr.__exportStar(AS(),Dr);Xr.__exportStar(bS(),Dr);Xr.__exportStar(PS(),Dr);Xr.__exportStar(GT(),Dr)});var _k=w(fu=>{"use strict";m();T();N();Object.defineProperty(fu,"__esModule",{value:!0});fu.applyExtensions=fu.mergeExtensions=fu.extractExtensionsFromSchema=void 0;var gk=oa(),Yne=oa();Object.defineProperty(fu,"extractExtensionsFromSchema",{enumerable:!0,get:function(){return Yne.extractExtensionsFromSchema}});function Jne(e){return(0,gk.mergeDeep)(e)}fu.mergeExtensions=Jne;function ql(e,t){e&&(e.extensions=(0,gk.mergeDeep)([e.extensions||{},t||{}]))}function Hne(e,t){ql(e,t.schemaExtensions);for(let[n,r]of Object.entries(t.types||{})){let i=e.getType(n);if(i){if(ql(i,r.extensions),r.type==="object"||r.type==="interface")for(let[a,o]of Object.entries(r.fields)){let c=i.getFields()[a];if(c){ql(c,o.extensions);for(let[l,p]of Object.entries(o.arguments))ql(c.args.find(f=>f.name===l),p)}}else if(r.type==="input")for(let[a,o]of Object.entries(r.fields)){let c=i.getFields()[a];ql(c,o.extensions)}else if(r.type==="enum")for(let[a,o]of Object.entries(r.values)){let c=i.getValue(a);ql(c,o)}}}return e}fu.applyExtensions=Hne});var XT=w(Up=>{"use strict";m();T();N();Object.defineProperty(Up,"__esModule",{value:!0});var CS=(vv(),om(_v));CS.__exportStar(ck(),Up);CS.__exportStar(Ik(),Up);CS.__exportStar(_k(),Up)});var ia=w(W=>{"use strict";m();T();N();Object.defineProperty(W,"__esModule",{value:!0});W.invalidEventProviderIdErrorMessage=W.invalidNatsStreamConfigurationDefinitionErrorMessage=W.invalidEdfsPublishResultObjectErrorMessage=W.invalidNatsStreamInputErrorMessage=W.inlineFragmentInFieldSetErrorMessage=W.inaccessibleQueryRootTypeError=W.subgraphValidationFailureError=W.minimumSubgraphRequirementError=void 0;W.multipleNamedTypeDefinitionError=Xne;W.incompatibleInputValueDefaultValueTypeError=Zne;W.incompatibleMergedTypesError=ere;W.incompatibleInputValueDefaultValuesError=tre;W.incompatibleSharedEnumError=nre;W.invalidSubgraphNamesError=rre;W.duplicateDirectiveDefinitionError=ire;W.duplicateEnumValueDefinitionError=are;W.duplicateFieldDefinitionError=sre;W.duplicateInputFieldDefinitionError=ore;W.duplicateImplementedInterfaceError=ure;W.duplicateUnionMemberDefinitionError=cre;W.duplicateTypeDefinitionError=lre;W.duplicateOperationTypeDefinitionError=dre;W.noBaseDefinitionForExtensionError=pre;W.noBaseScalarDefinitionError=fre;W.noDefinedUnionMembersError=mre;W.noDefinedEnumValuesError=Nre;W.operationDefinitionError=Tre;W.invalidFieldShareabilityError=Ere;W.undefinedDirectiveError=hre;W.undefinedTypeError=yre;W.invalidRepeatedDirectiveErrorMessage=Ire;W.invalidDirectiveError=gre;W.invalidRepeatedFederatedDirectiveErrorMessage=_re;W.invalidDirectiveLocationErrorMessage=vre;W.undefinedRequiredArgumentsErrorMessage=Sre;W.unexpectedDirectiveArgumentErrorMessage=Ore;W.duplicateDirectiveArgumentDefinitionsErrorMessage=Dre;W.invalidArgumentValueErrorMessage=bre;W.maximumTypeNestingExceededError=Are;W.unexpectedKindFatalError=Rre;W.incompatibleParentKindFatalError=Pre;W.unexpectedEdgeFatalError=Fre;W.incompatibleParentKindMergeError=wre;W.fieldTypeMergeFatalError=Lre;W.unexpectedTypeNodeKindFatalError=Cre;W.invalidKeyFatalError=Bre;W.unexpectedParentKindForChildError=Ure;W.subgraphValidationError=kre;W.invalidSubgraphNameErrorMessage=Mre;W.invalidOperationTypeDefinitionError=xre;W.invalidRootTypeDefinitionError=qre;W.subgraphInvalidSyntaxError=Vre;W.invalidInterfaceImplementationError=jre;W.invalidRequiredInputValueError=Kre;W.duplicateArgumentsError=Gre;W.noQueryRootTypeError=$re;W.expectedEntityError=Qre;W.abstractTypeInKeyFieldSetErrorMessage=Yre;W.unknownTypeInFieldSetErrorMessage=Jre;W.invalidSelectionSetErrorMessage=Hre;W.invalidSelectionSetDefinitionErrorMessage=zre;W.undefinedFieldInFieldSetErrorMessage=Wre;W.unparsableFieldSetErrorMessage=Xre;W.unparsableFieldSetSelectionErrorMessage=Zre;W.undefinedCompositeOutputTypeError=eie;W.unexpectedArgumentErrorMessage=tie;W.argumentsInKeyFieldSetErrorMessage=nie;W.invalidProvidesOrRequiresDirectivesError=rie;W.duplicateFieldInFieldSetErrorMessage=iie;W.invalidConfigurationDataErrorMessage=aie;W.incompatibleTypeWithProvidesErrorMessage=sie;W.invalidInlineFragmentTypeErrorMessage=oie;W.inlineFragmentWithoutTypeConditionErrorMessage=uie;W.unknownInlineFragmentTypeConditionErrorMessage=cie;W.invalidInlineFragmentTypeConditionTypeErrorMessage=lie;W.invalidInlineFragmentTypeConditionErrorMessage=die;W.invalidSelectionOnUnionErrorMessage=pie;W.duplicateOverriddenFieldErrorMessage=fie;W.duplicateOverriddenFieldsError=mie;W.noFieldDefinitionsError=Nie;W.noInputValueDefinitionsError=Tie;W.allChildDefinitionsAreInaccessibleError=Eie;W.equivalentSourceAndTargetOverrideErrorMessage=hie;W.undefinedEntityInterfaceImplementationsError=yie;W.orScopesLimitError=Iie;W.invalidEventDrivenGraphError=gie;W.invalidRootTypeFieldEventsDirectivesErrorMessage=_ie;W.invalidEventDrivenMutationResponseTypeErrorMessage=vie;W.invalidRootTypeFieldResponseTypesEventDrivenErrorMessage=Sie;W.invalidNatsStreamInputFieldsErrorMessage=Oie;W.invalidKeyFieldSetsEventDrivenErrorMessage=Die;W.nonExternalKeyFieldNamesEventDrivenErrorMessage=bie;W.nonKeyFieldNamesEventDrivenErrorMessage=Aie;W.nonEntityObjectExtensionsEventDrivenErrorMessage=Rie;W.nonKeyComposingObjectTypeNamesEventDrivenErrorMessage=Pie;W.invalidEdfsDirectiveName=Fie;W.invalidImplementedTypeError=wie;W.selfImplementationError=Lie;W.invalidEventSubjectErrorMessage=Cie;W.invalidEventSubjectsErrorMessage=Bie;W.invalidEventSubjectsItemErrorMessage=Uie;W.invalidEventSubjectsArgumentErrorMessage=kie;W.undefinedEventSubjectsArgumentErrorMessage=Mie;W.invalidEventDirectiveError=xie;W.invalidReferencesOfInaccessibleTypeError=qie;W.inaccessibleRequiredInputValueError=Vie;W.invalidUnionMemberTypeError=jie;W.invalidRootTypeError=Kie;W.invalidSubscriptionFilterLocationError=Gie;W.invalidSubscriptionFilterDirectiveError=$ie;W.subscriptionFilterNamedTypeErrorMessage=Qie;W.subscriptionFilterConditionDepthExceededErrorMessage=Yie;W.subscriptionFilterConditionInvalidInputFieldNumberErrorMessage=Jie;W.subscriptionFilterConditionInvalidInputFieldErrorMessage=Hie;W.subscriptionFilterConditionInvalidInputFieldTypeErrorMessage=zie;W.subscriptionFilterArrayConditionInvalidItemTypeErrorMessage=Wie;W.subscriptionFilterArrayConditionInvalidLengthErrorMessage=Xie;W.invalidInputFieldTypeErrorMessage=Zie;W.subscriptionFieldConditionInvalidInputFieldErrorMessage=eae;W.subscriptionFieldConditionInvalidValuesArrayErrorMessage=tae;W.subscriptionFieldConditionEmptyValuesArrayErrorMessage=nae;W.unknownFieldSubgraphNameError=rae;W.invalidSubscriptionFieldConditionFieldPathErrorMessage=iae;W.invalidSubscriptionFieldConditionFieldPathParentErrorMessage=aae;W.undefinedSubscriptionFieldConditionFieldPathFieldErrorMessage=sae;W.invalidSubscriptionFieldConditionFieldPathFieldErrorMessage=oae;W.inaccessibleSubscriptionFieldConditionFieldPathFieldErrorMessage=uae;W.nonLeafSubscriptionFieldConditionFieldPathFinalFieldErrorMessage=cae;W.unresolvablePathError=lae;W.allExternalFieldInstancesError=dae;W.externalInterfaceFieldsError=pae;W.nonExternalConditionalFieldError=fae;W.incompatibleFederatedFieldNamedTypeError=mae;W.unknownNamedTypeErrorMessage=Ak;W.unknownNamedTypeError=Nae;W.unknownFieldDataError=Tae;W.unexpectedNonCompositeOutputTypeError=Eae;W.invalidExternalDirectiveError=hae;W.configureDescriptionNoDescriptionError=yae;W.configureDescriptionPropagationError=Iae;W.duplicateDirectiveDefinitionArgumentErrorMessage=gae;W.duplicateDirectiveDefinitionLocationErrorMessage=_ae;W.invalidDirectiveDefinitionLocationErrorMessage=vae;W.invalidDirectiveDefinitionError=Sae;W.fieldAlreadyProvidedErrorMessage=Oae;W.invalidInterfaceObjectImplementationDefinitionsError=Dae;W.invalidNamedTypeError=bae;var vk=Ae(),We=ur(),Sk=Nl(),Vl=Jr(),zne=hl(),Wne=XT();W.minimumSubgraphRequirementError=new Error("At least one subgraph is required for federation.");function Xne(e,t,n){return new Error(`The named type "${e}" is defined as both types "${t}" and "${n}". + ${n}`)}function Gte(e,t){return t?(Kte(e,t),Y(x({},e),{locations:[...t.locations,...e.locations.filter(n=>!qte(n,t.locations))]})):e}Bl.mergeDirective=Gte;function $te(e,t,n){return e.concat(t.filter(r=>n(r,e)))}});var _S=w(jT=>{"use strict";m();T();N();Object.defineProperty(jT,"__esModule",{value:!0});jT.mergeEnumValues=void 0;var Qte=qi(),Yte=oa();function Jte(e,t,n,r){if(n!=null&&n.consistentEnumMerge){let o=[];e&&o.push(...e),e=t,t=o}let i=new Map;if(e)for(let o of e)i.set(o.name.value,o);if(t)for(let o of t){let c=o.name.value;if(i.has(c)){let l=i.get(c);l.description=o.description||l.description,l.directives=(0,Qte.mergeDirectives)(o.directives,l.directives,r)}else i.set(c,o)}let a=[...i.values()];return n&&n.sort&&a.sort(Yte.compareNodes),a}jT.mergeEnumValues=Jte});var vS=w(KT=>{"use strict";m();T();N();Object.defineProperty(KT,"__esModule",{value:!0});KT.mergeEnum=void 0;var Hte=Ae(),zte=qi(),Wte=_S();function Xte(e,t,n,r){return t?{name:e.name,description:e.description||t.description,kind:n!=null&&n.convertExtensions||e.kind==="EnumTypeDefinition"||t.kind==="EnumTypeDefinition"?"EnumTypeDefinition":"EnumTypeExtension",loc:e.loc,directives:(0,zte.mergeDirectives)(e.directives,t.directives,n,r),values:(0,Wte.mergeEnumValues)(e.values,t.values,n)}:n!=null&&n.convertExtensions?Y(x({},e),{kind:Hte.Kind.ENUM_TYPE_DEFINITION}):e}KT.mergeEnum=Xte});var GT=w(qn=>{"use strict";m();T();N();Object.defineProperty(qn,"__esModule",{value:!0});qn.defaultStringComparator=qn.CompareVal=qn.printTypeNode=qn.isNonNullTypeNode=qn.isListTypeNode=qn.isWrappingTypeNode=qn.extractType=qn.isSourceTypes=qn.isStringTypes=void 0;var Fp=Ae();function Zte(e){return typeof e=="string"}qn.isStringTypes=Zte;function ene(e){return e instanceof Fp.Source}qn.isSourceTypes=ene;function tne(e){let t=e;for(;t.kind===Fp.Kind.LIST_TYPE||t.kind==="NonNullType";)t=t.type;return t}qn.extractType=tne;function nne(e){return e.kind!==Fp.Kind.NAMED_TYPE}qn.isWrappingTypeNode=nne;function mk(e){return e.kind===Fp.Kind.LIST_TYPE}qn.isListTypeNode=mk;function Nk(e){return e.kind===Fp.Kind.NON_NULL_TYPE}qn.isNonNullTypeNode=Nk;function SS(e){return mk(e)?`[${SS(e.type)}]`:Nk(e)?`${SS(e.type)}!`:e.name.value}qn.printTypeNode=SS;var dc;(function(e){e[e.A_SMALLER_THAN_B=-1]="A_SMALLER_THAN_B",e[e.A_EQUALS_B=0]="A_EQUALS_B",e[e.A_GREATER_THAN_B=1]="A_GREATER_THAN_B"})(dc=qn.CompareVal||(qn.CompareVal={}));function rne(e,t){return e==null&&t==null?dc.A_EQUALS_B:e==null?dc.A_SMALLER_THAN_B:t==null?dc.A_GREATER_THAN_B:et?dc.A_GREATER_THAN_B:dc.A_EQUALS_B}qn.defaultStringComparator=rne});var Lp=w($T=>{"use strict";m();T();N();Object.defineProperty($T,"__esModule",{value:!0});$T.mergeFields=void 0;var Wr=GT(),ine=qi(),ane=oa(),sne=gS();function one(e,t){let n=e.findIndex(r=>r.name.value===t.name.value);return[n>-1?e[n]:null,n]}function une(e,t,n,r,i){let a=[];if(n!=null&&a.push(...n),t!=null)for(let o of t){let[c,l]=one(a,o);if(c&&!(r!=null&&r.ignoreFieldConflicts)){let p=(r==null?void 0:r.onFieldTypeConflict)&&r.onFieldTypeConflict(c,o,e,r==null?void 0:r.throwOnConflict)||cne(e,c,o,r==null?void 0:r.throwOnConflict);p.arguments=(0,sne.mergeArguments)(o.arguments||[],c.arguments||[],r),p.directives=(0,ine.mergeDirectives)(o.directives,c.directives,r,i),p.description=o.description||c.description,a[l]=p}else a.push(o)}if(r&&r.sort&&a.sort(ane.compareNodes),r&&r.exclusions){let o=r.exclusions;return a.filter(c=>!o.includes(`${e.name.value}.${c.name.value}`))}return a}$T.mergeFields=une;function cne(e,t,n,r=!1){let i=(0,Wr.printTypeNode)(t.type),a=(0,Wr.printTypeNode)(n.type);if(i!==a){let o=(0,Wr.extractType)(t.type),c=(0,Wr.extractType)(n.type);if(o.name.value!==c.name.value)throw new Error(`Field "${n.name.value}" already defined with a different type. Declared as "${o.name.value}", but you tried to override with "${c.name.value}"`);if(!wp(t.type,n.type,!r))throw new Error(`Field '${e.name.value}.${t.name.value}' changed type from '${i}' to '${a}'`)}return(0,Wr.isNonNullTypeNode)(n.type)&&!(0,Wr.isNonNullTypeNode)(t.type)&&(t.type=n.type),t}function wp(e,t,n=!1){if(!(0,Wr.isWrappingTypeNode)(e)&&!(0,Wr.isWrappingTypeNode)(t))return e.toString()===t.toString();if((0,Wr.isNonNullTypeNode)(t)){let r=(0,Wr.isNonNullTypeNode)(e)?e.type:e;return wp(r,t.type)}return(0,Wr.isNonNullTypeNode)(e)?wp(t,e,n):(0,Wr.isListTypeNode)(e)?(0,Wr.isListTypeNode)(t)&&wp(e.type,t.type)||(0,Wr.isNonNullTypeNode)(t)&&wp(e,t.type):!1}});var OS=w(QT=>{"use strict";m();T();N();Object.defineProperty(QT,"__esModule",{value:!0});QT.mergeInputType=void 0;var lne=Ae(),dne=Lp(),pne=qi();function fne(e,t,n,r){if(t)try{return{name:e.name,description:e.description||t.description,kind:n!=null&&n.convertExtensions||e.kind==="InputObjectTypeDefinition"||t.kind==="InputObjectTypeDefinition"?"InputObjectTypeDefinition":"InputObjectTypeExtension",loc:e.loc,fields:(0,dne.mergeFields)(e,e.fields,t.fields,n),directives:(0,pne.mergeDirectives)(e.directives,t.directives,n,r)}}catch(i){throw new Error(`Unable to merge GraphQL input type "${e.name.value}": ${i.message}`)}return n!=null&&n.convertExtensions?Y(x({},e),{kind:lne.Kind.INPUT_OBJECT_TYPE_DEFINITION}):e}QT.mergeInputType=fne});var Cp=w(YT=>{"use strict";m();T();N();Object.defineProperty(YT,"__esModule",{value:!0});YT.mergeNamedTypeArray=void 0;var mne=oa();function Nne(e,t){return!!e.find(n=>n.name.value===t.name.value)}function Tne(e=[],t=[],n={}){let r=[...t,...e.filter(i=>!Nne(t,i))];return n&&n.sort&&r.sort(mne.compareNodes),r}YT.mergeNamedTypeArray=Tne});var DS=w(JT=>{"use strict";m();T();N();Object.defineProperty(JT,"__esModule",{value:!0});JT.mergeInterface=void 0;var Ene=Ae(),hne=Lp(),yne=qi(),Ine=Cp();function gne(e,t,n,r){if(t)try{return{name:e.name,description:e.description||t.description,kind:n!=null&&n.convertExtensions||e.kind==="InterfaceTypeDefinition"||t.kind==="InterfaceTypeDefinition"?"InterfaceTypeDefinition":"InterfaceTypeExtension",loc:e.loc,fields:(0,hne.mergeFields)(e,e.fields,t.fields,n),directives:(0,yne.mergeDirectives)(e.directives,t.directives,n,r),interfaces:e.interfaces?(0,Ine.mergeNamedTypeArray)(e.interfaces,t.interfaces,n):void 0}}catch(i){throw new Error(`Unable to merge GraphQL interface "${e.name.value}": ${i.message}`)}return n!=null&&n.convertExtensions?Y(x({},e),{kind:Ene.Kind.INTERFACE_TYPE_DEFINITION}):e}JT.mergeInterface=gne});var bS=w(HT=>{"use strict";m();T();N();Object.defineProperty(HT,"__esModule",{value:!0});HT.mergeType=void 0;var _ne=Ae(),vne=Lp(),Sne=qi(),One=Cp();function Dne(e,t,n,r){if(t)try{return{name:e.name,description:e.description||t.description,kind:n!=null&&n.convertExtensions||e.kind==="ObjectTypeDefinition"||t.kind==="ObjectTypeDefinition"?"ObjectTypeDefinition":"ObjectTypeExtension",loc:e.loc,fields:(0,vne.mergeFields)(e,e.fields,t.fields,n),directives:(0,Sne.mergeDirectives)(e.directives,t.directives,n,r),interfaces:(0,One.mergeNamedTypeArray)(e.interfaces,t.interfaces,n)}}catch(i){throw new Error(`Unable to merge GraphQL type "${e.name.value}": ${i.message}`)}return n!=null&&n.convertExtensions?Y(x({},e),{kind:_ne.Kind.OBJECT_TYPE_DEFINITION}):e}HT.mergeType=Dne});var AS=w(zT=>{"use strict";m();T();N();Object.defineProperty(zT,"__esModule",{value:!0});zT.mergeScalar=void 0;var bne=Ae(),Ane=qi();function Rne(e,t,n,r){return t?{name:e.name,description:e.description||t.description,kind:n!=null&&n.convertExtensions||e.kind==="ScalarTypeDefinition"||t.kind==="ScalarTypeDefinition"?"ScalarTypeDefinition":"ScalarTypeExtension",loc:e.loc,directives:(0,Ane.mergeDirectives)(e.directives,t.directives,n,r)}:n!=null&&n.convertExtensions?Y(x({},e),{kind:bne.Kind.SCALAR_TYPE_DEFINITION}):e}zT.mergeScalar=Rne});var PS=w(WT=>{"use strict";m();T();N();Object.defineProperty(WT,"__esModule",{value:!0});WT.mergeUnion=void 0;var RS=Ae(),Pne=qi(),Fne=Cp();function wne(e,t,n,r){return t?{name:e.name,description:e.description||t.description,directives:(0,Pne.mergeDirectives)(e.directives,t.directives,n,r),kind:n!=null&&n.convertExtensions||e.kind==="UnionTypeDefinition"||t.kind==="UnionTypeDefinition"?RS.Kind.UNION_TYPE_DEFINITION:RS.Kind.UNION_TYPE_EXTENSION,loc:e.loc,types:(0,Fne.mergeNamedTypeArray)(e.types,t.types,n)}:n!=null&&n.convertExtensions?Y(x({},e),{kind:RS.Kind.UNION_TYPE_DEFINITION}):e}WT.mergeUnion=wne});var FS=w(pc=>{"use strict";m();T();N();Object.defineProperty(pc,"__esModule",{value:!0});pc.mergeSchemaDefs=pc.DEFAULT_OPERATION_TYPE_NAME_MAP=void 0;var Bp=Ae(),Lne=qi();pc.DEFAULT_OPERATION_TYPE_NAME_MAP={query:"Query",mutation:"Mutation",subscription:"Subscription"};function Cne(e=[],t=[]){let n=[];for(let r in pc.DEFAULT_OPERATION_TYPE_NAME_MAP){let i=e.find(a=>a.operation===r)||t.find(a=>a.operation===r);i&&n.push(i)}return n}function Bne(e,t,n,r){return t?{kind:e.kind===Bp.Kind.SCHEMA_DEFINITION||t.kind===Bp.Kind.SCHEMA_DEFINITION?Bp.Kind.SCHEMA_DEFINITION:Bp.Kind.SCHEMA_EXTENSION,description:e.description||t.description,directives:(0,Lne.mergeDirectives)(e.directives,t.directives,n,r),operationTypes:Cne(e.operationTypes,t.operationTypes)}:n!=null&&n.convertExtensions?Y(x({},e),{kind:Bp.Kind.SCHEMA_DEFINITION}):e}pc.mergeSchemaDefs=Bne});var wS=w(ja=>{"use strict";m();T();N();Object.defineProperty(ja,"__esModule",{value:!0});ja.mergeGraphQLNodes=ja.isNamedDefinitionNode=ja.schemaDefSymbol=void 0;var Br=Ae(),Une=bS(),kne=vS(),Mne=AS(),xne=PS(),qne=OS(),Vne=DS(),jne=qi(),Kne=FS(),Gne=oa();ja.schemaDefSymbol="SCHEMA_DEF_SYMBOL";function Tk(e){return"name"in e}ja.isNamedDefinitionNode=Tk;function $ne(e,t,n={}){var i,a,o;let r=n;for(let c of e)if(Tk(c)){let l=(i=c.name)==null?void 0:i.value;if(t!=null&&t.commentDescriptions&&(0,Gne.collectComment)(c),l==null)continue;if((a=t==null?void 0:t.exclusions)!=null&&a.includes(l+".*")||(o=t==null?void 0:t.exclusions)!=null&&o.includes(l))delete r[l];else switch(c.kind){case Br.Kind.OBJECT_TYPE_DEFINITION:case Br.Kind.OBJECT_TYPE_EXTENSION:r[l]=(0,Une.mergeType)(c,r[l],t,n);break;case Br.Kind.ENUM_TYPE_DEFINITION:case Br.Kind.ENUM_TYPE_EXTENSION:r[l]=(0,kne.mergeEnum)(c,r[l],t,n);break;case Br.Kind.UNION_TYPE_DEFINITION:case Br.Kind.UNION_TYPE_EXTENSION:r[l]=(0,xne.mergeUnion)(c,r[l],t,n);break;case Br.Kind.SCALAR_TYPE_DEFINITION:case Br.Kind.SCALAR_TYPE_EXTENSION:r[l]=(0,Mne.mergeScalar)(c,r[l],t,n);break;case Br.Kind.INPUT_OBJECT_TYPE_DEFINITION:case Br.Kind.INPUT_OBJECT_TYPE_EXTENSION:r[l]=(0,qne.mergeInputType)(c,r[l],t,n);break;case Br.Kind.INTERFACE_TYPE_DEFINITION:case Br.Kind.INTERFACE_TYPE_EXTENSION:r[l]=(0,Vne.mergeInterface)(c,r[l],t,n);break;case Br.Kind.DIRECTIVE_DEFINITION:r[l]=(0,jne.mergeDirective)(c,r[l]);break}}else(c.kind===Br.Kind.SCHEMA_DEFINITION||c.kind===Br.Kind.SCHEMA_EXTENSION)&&(r[ja.schemaDefSymbol]=(0,Kne.mergeSchemaDefs)(c,r[ja.schemaDefSymbol],t));return r}ja.mergeGraphQLNodes=$ne});var yk=w(xl=>{"use strict";m();T();N();Object.defineProperty(xl,"__esModule",{value:!0});xl.mergeGraphQLTypes=xl.mergeTypeDefs=void 0;var Vi=Ae(),LS=GT(),Ul=wS(),Ml=oa(),Ek=FS();function Qne(e,t){(0,Ml.resetComments)();let n={kind:Vi.Kind.DOCUMENT,definitions:hk(e,x({useSchemaDefinition:!0,forceSchemaDefinition:!1,throwOnConflict:!1,commentDescriptions:!1},t))},r;return t!=null&&t.commentDescriptions?r=(0,Ml.printWithComments)(n):r=n,(0,Ml.resetComments)(),r}xl.mergeTypeDefs=Qne;function kl(e,t,n=[],r=[],i=new Set){if(e&&!i.has(e))if(i.add(e),typeof e=="function")kl(e(),t,n,r,i);else if(Array.isArray(e))for(let a of e)kl(a,t,n,r,i);else if((0,Vi.isSchema)(e)){let a=(0,Ml.getDocumentNodeFromSchema)(e,t);kl(a.definitions,t,n,r,i)}else if((0,LS.isStringTypes)(e)||(0,LS.isSourceTypes)(e)){let a=(0,Vi.parse)(e,t);kl(a.definitions,t,n,r,i)}else if(typeof e=="object"&&(0,Vi.isDefinitionNode)(e))e.kind===Vi.Kind.DIRECTIVE_DEFINITION?n.push(e):r.push(e);else if((0,Ml.isDocumentNode)(e))kl(e.definitions,t,n,r,i);else throw new Error(`typeDefs must contain only strings, documents, schemas, or functions, got ${typeof e}`);return{allDirectives:n,allNodes:r}}function hk(e,t){var c,l,p;(0,Ml.resetComments)();let{allDirectives:n,allNodes:r}=kl(e,t),i=(0,Ul.mergeGraphQLNodes)(n,t),a=(0,Ul.mergeGraphQLNodes)(r,t,i);if(t!=null&&t.useSchemaDefinition){let f=a[Ul.schemaDefSymbol]||{kind:Vi.Kind.SCHEMA_DEFINITION,operationTypes:[]},y=f.operationTypes;for(let g in Ek.DEFAULT_OPERATION_TYPE_NAME_MAP)if(!y.find(P=>P.operation===g)){let P=Ek.DEFAULT_OPERATION_TYPE_NAME_MAP[g],U=a[P];U!=null&&U.name!=null&&y.push({kind:Vi.Kind.OPERATION_TYPE_DEFINITION,type:{kind:Vi.Kind.NAMED_TYPE,name:U.name},operation:g})}((c=f==null?void 0:f.operationTypes)==null?void 0:c.length)!=null&&f.operationTypes.length>0&&(a[Ul.schemaDefSymbol]=f)}t!=null&&t.forceSchemaDefinition&&!((p=(l=a[Ul.schemaDefSymbol])==null?void 0:l.operationTypes)!=null&&p.length)&&(a[Ul.schemaDefSymbol]={kind:Vi.Kind.SCHEMA_DEFINITION,operationTypes:[{kind:Vi.Kind.OPERATION_TYPE_DEFINITION,operation:"query",type:{kind:Vi.Kind.NAMED_TYPE,name:{kind:Vi.Kind.NAME,value:"Query"}}}]});let o=Object.values(a);if(t!=null&&t.sort){let f=typeof t.sort=="function"?t.sort:LS.defaultStringComparator;o.sort((y,g)=>{var v,P;return f((v=y.name)==null?void 0:v.value,(P=g.name)==null?void 0:P.value)})}return o}xl.mergeGraphQLTypes=hk});var Ik=w(Dr=>{"use strict";m();T();N();Object.defineProperty(Dr,"__esModule",{value:!0});var Xr=(vv(),om(_v));Xr.__exportStar(gS(),Dr);Xr.__exportStar(qi(),Dr);Xr.__exportStar(_S(),Dr);Xr.__exportStar(vS(),Dr);Xr.__exportStar(Lp(),Dr);Xr.__exportStar(OS(),Dr);Xr.__exportStar(DS(),Dr);Xr.__exportStar(Cp(),Dr);Xr.__exportStar(wS(),Dr);Xr.__exportStar(yk(),Dr);Xr.__exportStar(AS(),Dr);Xr.__exportStar(bS(),Dr);Xr.__exportStar(PS(),Dr);Xr.__exportStar(GT(),Dr)});var _k=w(fu=>{"use strict";m();T();N();Object.defineProperty(fu,"__esModule",{value:!0});fu.applyExtensions=fu.mergeExtensions=fu.extractExtensionsFromSchema=void 0;var gk=oa(),Yne=oa();Object.defineProperty(fu,"extractExtensionsFromSchema",{enumerable:!0,get:function(){return Yne.extractExtensionsFromSchema}});function Jne(e){return(0,gk.mergeDeep)(e)}fu.mergeExtensions=Jne;function ql(e,t){e&&(e.extensions=(0,gk.mergeDeep)([e.extensions||{},t||{}]))}function Hne(e,t){ql(e,t.schemaExtensions);for(let[n,r]of Object.entries(t.types||{})){let i=e.getType(n);if(i){if(ql(i,r.extensions),r.type==="object"||r.type==="interface")for(let[a,o]of Object.entries(r.fields)){let c=i.getFields()[a];if(c){ql(c,o.extensions);for(let[l,p]of Object.entries(o.arguments))ql(c.args.find(f=>f.name===l),p)}}else if(r.type==="input")for(let[a,o]of Object.entries(r.fields)){let c=i.getFields()[a];ql(c,o.extensions)}else if(r.type==="enum")for(let[a,o]of Object.entries(r.values)){let c=i.getValue(a);ql(c,o)}}}return e}fu.applyExtensions=Hne});var XT=w(Up=>{"use strict";m();T();N();Object.defineProperty(Up,"__esModule",{value:!0});var CS=(vv(),om(_v));CS.__exportStar(ck(),Up);CS.__exportStar(Ik(),Up);CS.__exportStar(_k(),Up)});var ia=w(W=>{"use strict";m();T();N();Object.defineProperty(W,"__esModule",{value:!0});W.invalidEventProviderIdErrorMessage=W.invalidNatsStreamConfigurationDefinitionErrorMessage=W.invalidEdfsPublishResultObjectErrorMessage=W.invalidNatsStreamInputErrorMessage=W.inlineFragmentInFieldSetErrorMessage=W.inaccessibleQueryRootTypeError=W.subgraphValidationFailureError=W.minimumSubgraphRequirementError=void 0;W.multipleNamedTypeDefinitionError=Xne;W.incompatibleInputValueDefaultValueTypeError=Zne;W.incompatibleMergedTypesError=ere;W.incompatibleInputValueDefaultValuesError=tre;W.incompatibleSharedEnumError=nre;W.invalidSubgraphNamesError=rre;W.duplicateDirectiveDefinitionError=ire;W.duplicateEnumValueDefinitionError=are;W.duplicateFieldDefinitionError=sre;W.duplicateInputFieldDefinitionError=ore;W.duplicateImplementedInterfaceError=ure;W.duplicateUnionMemberDefinitionError=cre;W.duplicateTypeDefinitionError=lre;W.duplicateOperationTypeDefinitionError=dre;W.noBaseDefinitionForExtensionError=pre;W.noBaseScalarDefinitionError=fre;W.noDefinedUnionMembersError=mre;W.noDefinedEnumValuesError=Nre;W.operationDefinitionError=Tre;W.invalidFieldShareabilityError=Ere;W.undefinedDirectiveError=hre;W.undefinedTypeError=yre;W.invalidRepeatedDirectiveErrorMessage=Ire;W.invalidDirectiveError=gre;W.invalidRepeatedFederatedDirectiveErrorMessage=_re;W.invalidDirectiveLocationErrorMessage=vre;W.undefinedRequiredArgumentsErrorMessage=Sre;W.unexpectedDirectiveArgumentErrorMessage=Ore;W.duplicateDirectiveArgumentDefinitionsErrorMessage=Dre;W.invalidArgumentValueErrorMessage=bre;W.maximumTypeNestingExceededError=Are;W.unexpectedKindFatalError=Rre;W.incompatibleParentKindFatalError=Pre;W.unexpectedEdgeFatalError=Fre;W.incompatibleParentKindMergeError=wre;W.fieldTypeMergeFatalError=Lre;W.unexpectedTypeNodeKindFatalError=Cre;W.invalidKeyFatalError=Bre;W.unexpectedParentKindForChildError=Ure;W.subgraphValidationError=kre;W.invalidSubgraphNameErrorMessage=Mre;W.invalidOperationTypeDefinitionError=xre;W.invalidRootTypeDefinitionError=qre;W.subgraphInvalidSyntaxError=Vre;W.invalidInterfaceImplementationError=jre;W.invalidRequiredInputValueError=Kre;W.duplicateArgumentsError=Gre;W.noQueryRootTypeError=$re;W.expectedEntityError=Qre;W.abstractTypeInKeyFieldSetErrorMessage=Yre;W.unknownTypeInFieldSetErrorMessage=Jre;W.invalidSelectionSetErrorMessage=Hre;W.invalidSelectionSetDefinitionErrorMessage=zre;W.undefinedFieldInFieldSetErrorMessage=Wre;W.unparsableFieldSetErrorMessage=Xre;W.unparsableFieldSetSelectionErrorMessage=Zre;W.undefinedCompositeOutputTypeError=eie;W.unexpectedArgumentErrorMessage=tie;W.argumentsInKeyFieldSetErrorMessage=nie;W.invalidProvidesOrRequiresDirectivesError=rie;W.duplicateFieldInFieldSetErrorMessage=iie;W.invalidConfigurationDataErrorMessage=aie;W.incompatibleTypeWithProvidesErrorMessage=sie;W.invalidInlineFragmentTypeErrorMessage=oie;W.inlineFragmentWithoutTypeConditionErrorMessage=uie;W.unknownInlineFragmentTypeConditionErrorMessage=cie;W.invalidInlineFragmentTypeConditionTypeErrorMessage=lie;W.invalidInlineFragmentTypeConditionErrorMessage=die;W.invalidSelectionOnUnionErrorMessage=pie;W.duplicateOverriddenFieldErrorMessage=fie;W.duplicateOverriddenFieldsError=mie;W.noFieldDefinitionsError=Nie;W.noInputValueDefinitionsError=Tie;W.allChildDefinitionsAreInaccessibleError=Eie;W.equivalentSourceAndTargetOverrideErrorMessage=hie;W.undefinedEntityInterfaceImplementationsError=yie;W.orScopesLimitError=Iie;W.invalidEventDrivenGraphError=gie;W.invalidRootTypeFieldEventsDirectivesErrorMessage=_ie;W.invalidEventDrivenMutationResponseTypeErrorMessage=vie;W.invalidRootTypeFieldResponseTypesEventDrivenErrorMessage=Sie;W.invalidNatsStreamInputFieldsErrorMessage=Oie;W.invalidKeyFieldSetsEventDrivenErrorMessage=Die;W.nonExternalKeyFieldNamesEventDrivenErrorMessage=bie;W.nonKeyFieldNamesEventDrivenErrorMessage=Aie;W.nonEntityObjectExtensionsEventDrivenErrorMessage=Rie;W.nonKeyComposingObjectTypeNamesEventDrivenErrorMessage=Pie;W.invalidEdfsDirectiveName=Fie;W.invalidImplementedTypeError=wie;W.selfImplementationError=Lie;W.invalidEventSubjectErrorMessage=Cie;W.invalidEventSubjectsErrorMessage=Bie;W.invalidEventSubjectsItemErrorMessage=Uie;W.invalidEventSubjectsArgumentErrorMessage=kie;W.undefinedEventSubjectsArgumentErrorMessage=Mie;W.invalidEventDirectiveError=xie;W.invalidReferencesOfInaccessibleTypeError=qie;W.inaccessibleRequiredInputValueError=Vie;W.invalidUnionMemberTypeError=jie;W.invalidRootTypeError=Kie;W.invalidSubscriptionFilterLocationError=Gie;W.invalidSubscriptionFilterDirectiveError=$ie;W.subscriptionFilterNamedTypeErrorMessage=Qie;W.subscriptionFilterConditionDepthExceededErrorMessage=Yie;W.subscriptionFilterConditionInvalidInputFieldNumberErrorMessage=Jie;W.subscriptionFilterConditionInvalidInputFieldErrorMessage=Hie;W.subscriptionFilterConditionInvalidInputFieldTypeErrorMessage=zie;W.subscriptionFilterArrayConditionInvalidItemTypeErrorMessage=Wie;W.subscriptionFilterArrayConditionInvalidLengthErrorMessage=Xie;W.invalidInputFieldTypeErrorMessage=Zie;W.subscriptionFieldConditionInvalidInputFieldErrorMessage=eae;W.subscriptionFieldConditionInvalidValuesArrayErrorMessage=tae;W.subscriptionFieldConditionEmptyValuesArrayErrorMessage=nae;W.unknownFieldSubgraphNameError=rae;W.invalidSubscriptionFieldConditionFieldPathErrorMessage=iae;W.invalidSubscriptionFieldConditionFieldPathParentErrorMessage=aae;W.undefinedSubscriptionFieldConditionFieldPathFieldErrorMessage=sae;W.invalidSubscriptionFieldConditionFieldPathFieldErrorMessage=oae;W.inaccessibleSubscriptionFieldConditionFieldPathFieldErrorMessage=uae;W.nonLeafSubscriptionFieldConditionFieldPathFinalFieldErrorMessage=cae;W.unresolvablePathError=lae;W.allExternalFieldInstancesError=dae;W.externalInterfaceFieldsError=pae;W.nonExternalConditionalFieldError=fae;W.incompatibleFederatedFieldNamedTypeError=mae;W.unknownNamedTypeErrorMessage=Ak;W.unknownNamedTypeError=Nae;W.unknownFieldDataError=Tae;W.unexpectedNonCompositeOutputTypeError=Eae;W.invalidExternalDirectiveError=hae;W.configureDescriptionNoDescriptionError=yae;W.configureDescriptionPropagationError=Iae;W.duplicateDirectiveDefinitionArgumentErrorMessage=gae;W.duplicateDirectiveDefinitionLocationErrorMessage=_ae;W.invalidDirectiveDefinitionLocationErrorMessage=vae;W.invalidDirectiveDefinitionError=Sae;W.fieldAlreadyProvidedErrorMessage=Oae;W.invalidInterfaceObjectImplementationDefinitionsError=Dae;W.invalidNamedTypeError=bae;var vk=Ae(),We=ur(),Sk=Nl(),Vl=Jr(),zne=hl(),Wne=XT();W.minimumSubgraphRequirementError=new Error("At least one subgraph is required for federation.");function Xne(e,t,n){return new Error(`The named type "${e}" is defined as both types "${t}" and "${n}". However, there must be only one type named "${e}".`)}function Zne(e,t,n,r){return new Error(`The ${e} of type "${n}" defined on path "${t}" is incompatible with the default value of "${r}".`)}function ere({actualType:e,coords:t,expectedType:n,isArgument:r}){return new Error(`Incompatible types when merging two instances of ${r?"field argument":We.FIELD} "${t}": Expected type "${n}" but received "${e}".`)}function tre(e,t,n,r,i){return new Error(`Expected the ${e} defined on path "${t}" to define the default value "${r}". "However, the default value "${i}" is defined in the following subgraph`+(n.length>1?"s":"")+`: @@ -323,10 +323,12 @@ For federation, it is only possible to use the default root types names ("Mutati "${e}" This is because of the selection set corresponding to the `+ZT(t,n,We.UNION)+` Union types such as "${n}" must define field selections (besides "__typename") on an inline fragment whose type condition corresponds to a constituent union member.`}function fie(e,t){return` The field "${e}" declares an @override directive in the following subgraphs: "`+t.join(We.QUOTATION_JOIN)+'".'}function mie(e){return new Error('The "@override" directive must only be declared on one single instance of a field. However, an "@override" directive was declared on more than one instance of the following field'+(e.length>1?"s":"")+': "'+e.join(We.QUOTATION_JOIN)+`". `)}function Nie(e,t){return new Error(`The ${e} "${t}" is invalid because it does not define any fields.`)}function Tie(e){return new Error(`The Input Object "${e}" is invalid because it does not define any input values.`)}function Eie(e,t,n){return new Error(`The ${e} "${t}" is invalid because all its ${n} definitions are declared "@inaccessible".`)}function hie(e,t){return`Cannot override field "${t}" because the source and target subgraph names are both "${e}"`}function yie(e,t){let n=`Federation was unsuccessful because any one subgraph that defines a specific entity interface must also define each and every entity object that implements that entity interface. + + Each entity object must also each explicitly define the implementation of the entity interface. `;for(let[r,i]of e){let o=(0,Vl.getOrThrowError)(t,r,"entityInterfaceFederationDataByTypeName").concreteTypeNames;n+=` Across all subgraphs, the entity interface "${r}" is implemented by the following entit`+(o.size>1?"ies":"y")+`: "`+Array.from(o).join(We.QUOTATION_JOIN)+`" However, the definition of at least one of these implementations is missing in a subgraph that defines the entity interface "${r}": -`;for(let{subgraphName:c,concreteTypeNames:l}of i){let p=(0,Vl.getEntriesNotInHashSet)(o,l);n+=` Subgraph "${c}" does not define the following implementations: "`+p.join(We.QUOTATION_JOIN)+`" +`;for(let{subgraphName:c,definedConcreteTypeNames:l}of i){let p=(0,Vl.getEntriesNotInHashSet)(o,l);n+=` Subgraph "${c}" does not define the following implementations: "`+p.join(We.QUOTATION_JOIN)+`" `}}return new Error(n)}function Iie(e,t){return new Error(`The maximum number of OR scopes that can be defined by @requiresScopes on a single field is ${e}. However, the following coordinates attempt to define more: "`+t.join(We.QUOTATION_JOIN)+`" If you require more, please contact support.`)}function gie(e){return new Error(`An "Event Driven" graph\u2014a subgraph that defines event driven directives\u2014must not define any resolvers. @@ -427,7 +429,7 @@ This should never happen. Please report this issue on GitHub.`)}function hae(e){ A federated graph only supports a single description; consequently, only one subgraph may define argument "propagate" as true (this is the default value).`)}function gae(e){return"- The following argument"+(e.length>1?"s are":" is")+` defined more than once: "`+e.join(We.QUOTATION_JOIN)+'"'}function _ae(e){return`- The location "${e}" is defined multiple times.`}function vae(e){return`- "${e}" is not a valid directive location.`}function Sae(e,t){return new Error(`The directive definition for "@${e}" is invalid for the following reason`+(t.length>1?"s":"")+`: `+t.join(We.LITERAL_NEW_LINE)+'"')}function Oae(e,t,n){return` The field "${e}" is unconditionally provided by subgraph "${t}" and should not form part of any "@${n}" field set. Although "${e}" is declared "@external", it is part of a "@key" directive on an extension type. Such fields are only declared "@external" for legacy syntactical reasons and are not internally considered "@external".`}function Dae(e,t,n){return new Error(`The subgraph that defines an entity Interface Object (using "@interfaceObject") must not define any implementation types of that interface. However, the subgraph "${t}" defines the entity Interface "${e}" as an Interface Object alongside the following implementation type`+(n.length>1?"s":"")+` of "${e}": - "`+n.join(We.QUOTATION_JOIN)+'"')}function bae({data:e,namedTypeData:t,nodeType:n}){let r=(0,zne.isFieldData)(e),i=r?`${e.originalParentTypeName}.${e.name}`:e.originalCoords;return new Error(`The ${n} "${i}" is invalid because it defines type `+(0,Wne.printTypeNode)(e.type)+`; however, ${(0,Vl.kindToNodeType)(t.kind)} "${t.name}" is not a valid `+(r?"output":"input")+" type.")}});var Pk=w(Rk=>{"use strict";m();T();N();Object.defineProperty(Rk,"__esModule",{value:!0})});var kp=w(ji=>{"use strict";m();T();N();Object.defineProperty(ji,"__esModule",{value:!0});ji.SUBSCRIPTION_FILTER_LIST_INPUT_NAMES=ji.SUBSCRIPTION_FILTER_INPUT_NAMES=ji.STREAM_CONFIGURATION_FIELD_NAMES=ji.EVENT_DIRECTIVE_NAMES=ji.TYPE_SYSTEM_DIRECTIVE_LOCATIONS=void 0;var cn=ur();ji.TYPE_SYSTEM_DIRECTIVE_LOCATIONS=new Set([cn.ARGUMENT_DEFINITION_UPPER,cn.ENUM_UPPER,cn.ENUM_VALUE_UPPER,cn.FIELD_DEFINITION_UPPER,cn.INPUT_FIELD_DEFINITION_UPPER,cn.INPUT_OBJECT_UPPER,cn.INTERFACE_UPPER,cn.OBJECT_UPPER,cn.SCALAR_UPPER,cn.SCHEMA_UPPER,cn.UNION_UPPER]);ji.EVENT_DIRECTIVE_NAMES=new Set([cn.EDFS_KAFKA_PUBLISH,cn.EDFS_KAFKA_SUBSCRIBE,cn.EDFS_NATS_PUBLISH,cn.EDFS_NATS_REQUEST,cn.EDFS_NATS_SUBSCRIBE,cn.EDFS_REDIS_PUBLISH,cn.EDFS_REDIS_SUBSCRIBE]);ji.STREAM_CONFIGURATION_FIELD_NAMES=new Set([cn.CONSUMER_INACTIVE_THRESHOLD,cn.CONSUMER_NAME,cn.STREAM_NAME]);ji.SUBSCRIPTION_FILTER_INPUT_NAMES=new Set([cn.AND_UPPER,cn.IN_UPPER,cn.NOT_UPPER,cn.OR_UPPER]);ji.SUBSCRIPTION_FILTER_LIST_INPUT_NAMES=new Set([cn.AND_UPPER,cn.OR_UPPER])});var Ki=w((US,Fk)=>{"use strict";m();T();N();var Mp=function(e){return e&&e.Math===Math&&e};Fk.exports=Mp(typeof globalThis=="object"&&globalThis)||Mp(typeof window=="object"&&window)||Mp(typeof self=="object"&&self)||Mp(typeof global=="object"&&global)||Mp(typeof US=="object"&&US)||function(){return this}()||Function("return this")()});var Is=w((nAe,wk)=>{"use strict";m();T();N();wk.exports=function(e){try{return!!e()}catch(t){return!0}}});var mu=w((sAe,Lk)=>{"use strict";m();T();N();var Aae=Is();Lk.exports=!Aae(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!==7})});var kS=w((lAe,Ck)=>{"use strict";m();T();N();var Rae=Is();Ck.exports=!Rae(function(){var e=function(){}.bind();return typeof e!="function"||e.hasOwnProperty("prototype")})});var fc=w((mAe,Bk)=>{"use strict";m();T();N();var Pae=kS(),eE=Function.prototype.call;Bk.exports=Pae?eE.bind(eE):function(){return eE.apply(eE,arguments)}});var xk=w(Mk=>{"use strict";m();T();N();var Uk={}.propertyIsEnumerable,kk=Object.getOwnPropertyDescriptor,Fae=kk&&!Uk.call({1:2},1);Mk.f=Fae?function(t){var n=kk(this,t);return!!n&&n.enumerable}:Uk});var MS=w((_Ae,qk)=>{"use strict";m();T();N();qk.exports=function(e,t){return{enumerable:!(e&1),configurable:!(e&2),writable:!(e&4),value:t}}});var mi=w((DAe,Kk)=>{"use strict";m();T();N();var Vk=kS(),jk=Function.prototype,xS=jk.call,wae=Vk&&jk.bind.bind(xS,xS);Kk.exports=Vk?wae:function(e){return function(){return xS.apply(e,arguments)}}});var Qk=w((PAe,$k)=>{"use strict";m();T();N();var Gk=mi(),Lae=Gk({}.toString),Cae=Gk("".slice);$k.exports=function(e){return Cae(Lae(e),8,-1)}});var Jk=w((CAe,Yk)=>{"use strict";m();T();N();var Bae=mi(),Uae=Is(),kae=Qk(),qS=Object,Mae=Bae("".split);Yk.exports=Uae(function(){return!qS("z").propertyIsEnumerable(0)})?function(e){return kae(e)==="String"?Mae(e,""):qS(e)}:qS});var VS=w((MAe,Hk)=>{"use strict";m();T();N();Hk.exports=function(e){return e==null}});var jS=w((jAe,zk)=>{"use strict";m();T();N();var xae=VS(),qae=TypeError;zk.exports=function(e){if(xae(e))throw new qae("Can't call method on "+e);return e}});var tE=w((QAe,Wk)=>{"use strict";m();T();N();var Vae=Jk(),jae=jS();Wk.exports=function(e){return Vae(jae(e))}});var ua=w((zAe,Xk)=>{"use strict";m();T();N();var KS=typeof document=="object"&&document.all;Xk.exports=typeof KS=="undefined"&&KS!==void 0?function(e){return typeof e=="function"||e===KS}:function(e){return typeof e=="function"}});var jl=w((eRe,Zk)=>{"use strict";m();T();N();var Kae=ua();Zk.exports=function(e){return typeof e=="object"?e!==null:Kae(e)}});var nE=w((iRe,eM)=>{"use strict";m();T();N();var GS=Ki(),Gae=ua(),$ae=function(e){return Gae(e)?e:void 0};eM.exports=function(e,t){return arguments.length<2?$ae(GS[e]):GS[e]&&GS[e][t]}});var nM=w((uRe,tM)=>{"use strict";m();T();N();var Qae=mi();tM.exports=Qae({}.isPrototypeOf)});var sM=w((pRe,aM)=>{"use strict";m();T();N();var Yae=Ki(),rM=Yae.navigator,iM=rM&&rM.userAgent;aM.exports=iM?String(iM):""});var fM=w((TRe,pM)=>{"use strict";m();T();N();var dM=Ki(),$S=sM(),oM=dM.process,uM=dM.Deno,cM=oM&&oM.versions||uM&&uM.version,lM=cM&&cM.v8,ca,rE;lM&&(ca=lM.split("."),rE=ca[0]>0&&ca[0]<4?1:+(ca[0]+ca[1]));!rE&&$S&&(ca=$S.match(/Edge\/(\d+)/),(!ca||ca[1]>=74)&&(ca=$S.match(/Chrome\/(\d+)/),ca&&(rE=+ca[1])));pM.exports=rE});var QS=w((IRe,NM)=>{"use strict";m();T();N();var mM=fM(),Jae=Is(),Hae=Ki(),zae=Hae.String;NM.exports=!!Object.getOwnPropertySymbols&&!Jae(function(){var e=Symbol("symbol detection");return!zae(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&mM&&mM<41})});var YS=w((SRe,TM)=>{"use strict";m();T();N();var Wae=QS();TM.exports=Wae&&!Symbol.sham&&typeof Symbol.iterator=="symbol"});var JS=w((ARe,EM)=>{"use strict";m();T();N();var Xae=nE(),Zae=ua(),ese=nM(),tse=YS(),nse=Object;EM.exports=tse?function(e){return typeof e=="symbol"}:function(e){var t=Xae("Symbol");return Zae(t)&&ese(t.prototype,nse(e))}});var yM=w((wRe,hM)=>{"use strict";m();T();N();var rse=String;hM.exports=function(e){try{return rse(e)}catch(t){return"Object"}}});var iE=w((URe,IM)=>{"use strict";m();T();N();var ise=ua(),ase=yM(),sse=TypeError;IM.exports=function(e){if(ise(e))return e;throw new sse(ase(e)+" is not a function")}});var HS=w((qRe,gM)=>{"use strict";m();T();N();var ose=iE(),use=VS();gM.exports=function(e,t){var n=e[t];return use(n)?void 0:ose(n)}});var vM=w((GRe,_M)=>{"use strict";m();T();N();var zS=fc(),WS=ua(),XS=jl(),cse=TypeError;_M.exports=function(e,t){var n,r;if(t==="string"&&WS(n=e.toString)&&!XS(r=zS(n,e))||WS(n=e.valueOf)&&!XS(r=zS(n,e))||t!=="string"&&WS(n=e.toString)&&!XS(r=zS(n,e)))return r;throw new cse("Can't convert object to primitive value")}});var OM=w((JRe,SM)=>{"use strict";m();T();N();SM.exports=!1});var aE=w((XRe,bM)=>{"use strict";m();T();N();var DM=Ki(),lse=Object.defineProperty;bM.exports=function(e,t){try{lse(DM,e,{value:t,configurable:!0,writable:!0})}catch(n){DM[e]=t}return t}});var sE=w((nPe,PM)=>{"use strict";m();T();N();var dse=OM(),pse=Ki(),fse=aE(),AM="__core-js_shared__",RM=PM.exports=pse[AM]||fse(AM,{});(RM.versions||(RM.versions=[])).push({version:"3.41.0",mode:dse?"pure":"global",copyright:"\xA9 2014-2025 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.41.0/LICENSE",source:"https://github.com/zloirock/core-js"})});var ZS=w((sPe,wM)=>{"use strict";m();T();N();var FM=sE();wM.exports=function(e,t){return FM[e]||(FM[e]=t||{})}});var CM=w((lPe,LM)=>{"use strict";m();T();N();var mse=jS(),Nse=Object;LM.exports=function(e){return Nse(mse(e))}});var Nu=w((mPe,BM)=>{"use strict";m();T();N();var Tse=mi(),Ese=CM(),hse=Tse({}.hasOwnProperty);BM.exports=Object.hasOwn||function(t,n){return hse(Ese(t),n)}});var eO=w((hPe,UM)=>{"use strict";m();T();N();var yse=mi(),Ise=0,gse=Math.random(),_se=yse(1 .toString);UM.exports=function(e){return"Symbol("+(e===void 0?"":e)+")_"+_se(++Ise+gse,36)}});var xM=w((_Pe,MM)=>{"use strict";m();T();N();var vse=Ki(),Sse=ZS(),kM=Nu(),Ose=eO(),Dse=QS(),bse=YS(),Kl=vse.Symbol,tO=Sse("wks"),Ase=bse?Kl.for||Kl:Kl&&Kl.withoutSetter||Ose;MM.exports=function(e){return kM(tO,e)||(tO[e]=Dse&&kM(Kl,e)?Kl[e]:Ase("Symbol."+e)),tO[e]}});var KM=w((DPe,jM)=>{"use strict";m();T();N();var Rse=fc(),qM=jl(),VM=JS(),Pse=HS(),Fse=vM(),wse=xM(),Lse=TypeError,Cse=wse("toPrimitive");jM.exports=function(e,t){if(!qM(e)||VM(e))return e;var n=Pse(e,Cse),r;if(n){if(t===void 0&&(t="default"),r=Rse(n,e,t),!qM(r)||VM(r))return r;throw new Lse("Can't convert object to primitive value")}return t===void 0&&(t="number"),Fse(e,t)}});var nO=w((PPe,GM)=>{"use strict";m();T();N();var Bse=KM(),Use=JS();GM.exports=function(e){var t=Bse(e,"string");return Use(t)?t:t+""}});var YM=w((CPe,QM)=>{"use strict";m();T();N();var kse=Ki(),$M=jl(),rO=kse.document,Mse=$M(rO)&&$M(rO.createElement);QM.exports=function(e){return Mse?rO.createElement(e):{}}});var iO=w((MPe,JM)=>{"use strict";m();T();N();var xse=mu(),qse=Is(),Vse=YM();JM.exports=!xse&&!qse(function(){return Object.defineProperty(Vse("div"),"a",{get:function(){return 7}}).a!==7})});var aO=w(zM=>{"use strict";m();T();N();var jse=mu(),Kse=fc(),Gse=xk(),$se=MS(),Qse=tE(),Yse=nO(),Jse=Nu(),Hse=iO(),HM=Object.getOwnPropertyDescriptor;zM.f=jse?HM:function(t,n){if(t=Qse(t),n=Yse(n),Hse)try{return HM(t,n)}catch(r){}if(Jse(t,n))return $se(!Kse(Gse.f,t,n),t[n])}});var XM=w((QPe,WM)=>{"use strict";m();T();N();var zse=mu(),Wse=Is();WM.exports=zse&&Wse(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!==42})});var xp=w((zPe,ZM)=>{"use strict";m();T();N();var Xse=jl(),Zse=String,eoe=TypeError;ZM.exports=function(e){if(Xse(e))return e;throw new eoe(Zse(e)+" is not an object")}});var uE=w(tx=>{"use strict";m();T();N();var toe=mu(),noe=iO(),roe=XM(),oE=xp(),ex=nO(),ioe=TypeError,sO=Object.defineProperty,aoe=Object.getOwnPropertyDescriptor,oO="enumerable",uO="configurable",cO="writable";tx.f=toe?roe?function(t,n,r){if(oE(t),n=ex(n),oE(r),typeof t=="function"&&n==="prototype"&&"value"in r&&cO in r&&!r[cO]){var i=aoe(t,n);i&&i[cO]&&(t[n]=r.value,r={configurable:uO in r?r[uO]:i[uO],enumerable:oO in r?r[oO]:i[oO],writable:!1})}return sO(t,n,r)}:sO:function(t,n,r){if(oE(t),n=ex(n),oE(r),noe)try{return sO(t,n,r)}catch(i){}if("get"in r||"set"in r)throw new ioe("Accessors not supported");return"value"in r&&(t[n]=r.value),t}});var lO=w((iFe,nx)=>{"use strict";m();T();N();var soe=mu(),ooe=uE(),uoe=MS();nx.exports=soe?function(e,t,n){return ooe.f(e,t,uoe(1,n))}:function(e,t,n){return e[t]=n,e}});var ax=w((uFe,ix)=>{"use strict";m();T();N();var dO=mu(),coe=Nu(),rx=Function.prototype,loe=dO&&Object.getOwnPropertyDescriptor,pO=coe(rx,"name"),doe=pO&&function(){}.name==="something",poe=pO&&(!dO||dO&&loe(rx,"name").configurable);ix.exports={EXISTS:pO,PROPER:doe,CONFIGURABLE:poe}});var ox=w((pFe,sx)=>{"use strict";m();T();N();var foe=mi(),moe=ua(),fO=sE(),Noe=foe(Function.toString);moe(fO.inspectSource)||(fO.inspectSource=function(e){return Noe(e)});sx.exports=fO.inspectSource});var lx=w((TFe,cx)=>{"use strict";m();T();N();var Toe=Ki(),Eoe=ua(),ux=Toe.WeakMap;cx.exports=Eoe(ux)&&/native code/.test(String(ux))});var fx=w((IFe,px)=>{"use strict";m();T();N();var hoe=ZS(),yoe=eO(),dx=hoe("keys");px.exports=function(e){return dx[e]||(dx[e]=yoe(e))}});var mO=w((SFe,mx)=>{"use strict";m();T();N();mx.exports={}});var hx=w((AFe,Ex)=>{"use strict";m();T();N();var Ioe=lx(),Tx=Ki(),goe=jl(),_oe=lO(),NO=Nu(),TO=sE(),voe=fx(),Soe=mO(),Nx="Object already initialized",EO=Tx.TypeError,Ooe=Tx.WeakMap,cE,qp,lE,Doe=function(e){return lE(e)?qp(e):cE(e,{})},boe=function(e){return function(t){var n;if(!goe(t)||(n=qp(t)).type!==e)throw new EO("Incompatible receiver, "+e+" required");return n}};Ioe||TO.state?(la=TO.state||(TO.state=new Ooe),la.get=la.get,la.has=la.has,la.set=la.set,cE=function(e,t){if(la.has(e))throw new EO(Nx);return t.facade=e,la.set(e,t),t},qp=function(e){return la.get(e)||{}},lE=function(e){return la.has(e)}):(mc=voe("state"),Soe[mc]=!0,cE=function(e,t){if(NO(e,mc))throw new EO(Nx);return t.facade=e,_oe(e,mc,t),t},qp=function(e){return NO(e,mc)?e[mc]:{}},lE=function(e){return NO(e,mc)});var la,mc;Ex.exports={set:cE,get:qp,has:lE,enforce:Doe,getterFor:boe}});var _x=w((wFe,gx)=>{"use strict";m();T();N();var yO=mi(),Aoe=Is(),Roe=ua(),dE=Nu(),hO=mu(),Poe=ax().CONFIGURABLE,Foe=ox(),Ix=hx(),woe=Ix.enforce,Loe=Ix.get,yx=String,pE=Object.defineProperty,Coe=yO("".slice),Boe=yO("".replace),Uoe=yO([].join),koe=hO&&!Aoe(function(){return pE(function(){},"length",{value:8}).length!==8}),Moe=String(String).split("String"),xoe=gx.exports=function(e,t,n){Coe(yx(t),0,7)==="Symbol("&&(t="["+Boe(yx(t),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),n&&n.getter&&(t="get "+t),n&&n.setter&&(t="set "+t),(!dE(e,"name")||Poe&&e.name!==t)&&(hO?pE(e,"name",{value:t,configurable:!0}):e.name=t),koe&&n&&dE(n,"arity")&&e.length!==n.arity&&pE(e,"length",{value:n.arity});try{n&&dE(n,"constructor")&&n.constructor?hO&&pE(e,"prototype",{writable:!1}):e.prototype&&(e.prototype=void 0)}catch(i){}var r=woe(e);return dE(r,"source")||(r.source=Uoe(Moe,typeof t=="string"?t:"")),e};Function.prototype.toString=xoe(function(){return Roe(this)&&Loe(this).source||Foe(this)},"toString")});var Sx=w((UFe,vx)=>{"use strict";m();T();N();var qoe=ua(),Voe=uE(),joe=_x(),Koe=aE();vx.exports=function(e,t,n,r){r||(r={});var i=r.enumerable,a=r.name!==void 0?r.name:t;if(qoe(n)&&joe(n,a,r),r.global)i?e[t]=n:Koe(t,n);else{try{r.unsafe?e[t]&&(i=!0):delete e[t]}catch(o){}i?e[t]=n:Voe.f(e,t,{value:n,enumerable:!1,configurable:!r.nonConfigurable,writable:!r.nonWritable})}return e}});var Dx=w((qFe,Ox)=>{"use strict";m();T();N();var Goe=Math.ceil,$oe=Math.floor;Ox.exports=Math.trunc||function(t){var n=+t;return(n>0?$oe:Goe)(n)}});var fE=w((GFe,bx)=>{"use strict";m();T();N();var Qoe=Dx();bx.exports=function(e){var t=+e;return t!==t||t===0?0:Qoe(t)}});var Rx=w((JFe,Ax)=>{"use strict";m();T();N();var Yoe=fE(),Joe=Math.max,Hoe=Math.min;Ax.exports=function(e,t){var n=Yoe(e);return n<0?Joe(n+t,0):Hoe(n,t)}});var Fx=w((XFe,Px)=>{"use strict";m();T();N();var zoe=fE(),Woe=Math.min;Px.exports=function(e){var t=zoe(e);return t>0?Woe(t,9007199254740991):0}});var Lx=w((nwe,wx)=>{"use strict";m();T();N();var Xoe=Fx();wx.exports=function(e){return Xoe(e.length)}});var Ux=w((swe,Bx)=>{"use strict";m();T();N();var Zoe=tE(),eue=Rx(),tue=Lx(),Cx=function(e){return function(t,n,r){var i=Zoe(t),a=tue(i);if(a===0)return!e&&-1;var o=eue(r,a),c;if(e&&n!==n){for(;a>o;)if(c=i[o++],c!==c)return!0}else for(;a>o;o++)if((e||o in i)&&i[o]===n)return e||o||0;return!e&&-1}};Bx.exports={includes:Cx(!0),indexOf:Cx(!1)}});var xx=w((lwe,Mx)=>{"use strict";m();T();N();var nue=mi(),IO=Nu(),rue=tE(),iue=Ux().indexOf,aue=mO(),kx=nue([].push);Mx.exports=function(e,t){var n=rue(e),r=0,i=[],a;for(a in n)!IO(aue,a)&&IO(n,a)&&kx(i,a);for(;t.length>r;)IO(n,a=t[r++])&&(~iue(i,a)||kx(i,a));return i}});var Vx=w((mwe,qx)=>{"use strict";m();T();N();qx.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]});var Kx=w(jx=>{"use strict";m();T();N();var sue=xx(),oue=Vx(),uue=oue.concat("length","prototype");jx.f=Object.getOwnPropertyNames||function(t){return sue(t,uue)}});var $x=w(Gx=>{"use strict";m();T();N();Gx.f=Object.getOwnPropertySymbols});var Yx=w((Dwe,Qx)=>{"use strict";m();T();N();var cue=nE(),lue=mi(),due=Kx(),pue=$x(),fue=xp(),mue=lue([].concat);Qx.exports=cue("Reflect","ownKeys")||function(t){var n=due.f(fue(t)),r=pue.f;return r?mue(n,r(t)):n}});var zx=w((Pwe,Hx)=>{"use strict";m();T();N();var Jx=Nu(),Nue=Yx(),Tue=aO(),Eue=uE();Hx.exports=function(e,t,n){for(var r=Nue(t),i=Eue.f,a=Tue.f,o=0;o{"use strict";m();T();N();var hue=Is(),yue=ua(),Iue=/#|\.prototype\./,Vp=function(e,t){var n=_ue[gue(e)];return n===Sue?!0:n===vue?!1:yue(t)?hue(t):!!t},gue=Vp.normalize=function(e){return String(e).replace(Iue,".").toLowerCase()},_ue=Vp.data={},vue=Vp.NATIVE="N",Sue=Vp.POLYFILL="P";Wx.exports=Vp});var gO=w((Mwe,Zx)=>{"use strict";m();T();N();var mE=Ki(),Oue=aO().f,Due=lO(),bue=Sx(),Aue=aE(),Rue=zx(),Pue=Xx();Zx.exports=function(e,t){var n=e.target,r=e.global,i=e.stat,a,o,c,l,p,f;if(r?o=mE:i?o=mE[n]||Aue(n,{}):o=mE[n]&&mE[n].prototype,o)for(c in t){if(p=t[c],e.dontCallGetSet?(f=Oue(o,c),l=f&&f.value):l=o[c],a=Pue(r?c:n+(i?".":"#")+c,e.forced),!a&&l!==void 0){if(typeof p==typeof l)continue;Rue(p,l)}(e.sham||l&&l.sham)&&Due(p,"sham",!0),bue(o,c,p,e)}}});var jp=w((jwe,eq)=>{"use strict";m();T();N();var _O=mi(),NE=Set.prototype;eq.exports={Set,add:_O(NE.add),has:_O(NE.has),remove:_O(NE.delete),proto:NE}});var vO=w((Qwe,tq)=>{"use strict";m();T();N();var Fue=jp().has;tq.exports=function(e){return Fue(e),e}});var rq=w((zwe,nq)=>{"use strict";m();T();N();var wue=mi(),Lue=iE();nq.exports=function(e,t,n){try{return wue(Lue(Object.getOwnPropertyDescriptor(e,t)[n]))}catch(r){}}});var SO=w((eLe,iq)=>{"use strict";m();T();N();var Cue=rq(),Bue=jp();iq.exports=Cue(Bue.proto,"size","get")||function(e){return e.size}});var OO=w((iLe,aq)=>{"use strict";m();T();N();var Uue=fc();aq.exports=function(e,t,n){for(var r=n?e:e.iterator,i=e.next,a,o;!(a=Uue(i,r)).done;)if(o=t(a.value),o!==void 0)return o}});var dq=w((uLe,lq)=>{"use strict";m();T();N();var sq=mi(),kue=OO(),oq=jp(),Mue=oq.Set,uq=oq.proto,xue=sq(uq.forEach),cq=sq(uq.keys),que=cq(new Mue).next;lq.exports=function(e,t,n){return n?kue({iterator:cq(e),next:que},t):xue(e,t)}});var fq=w((pLe,pq)=>{"use strict";m();T();N();pq.exports=function(e){return{iterator:e,next:e.next,done:!1}}});var DO=w((TLe,yq)=>{"use strict";m();T();N();var mq=iE(),Eq=xp(),Nq=fc(),Vue=fE(),jue=fq(),Tq="Invalid size",Kue=RangeError,Gue=TypeError,$ue=Math.max,hq=function(e,t){this.set=e,this.size=$ue(t,0),this.has=mq(e.has),this.keys=mq(e.keys)};hq.prototype={getIterator:function(){return jue(Eq(Nq(this.keys,this.set)))},includes:function(e){return Nq(this.has,this.set,e)}};yq.exports=function(e){Eq(e);var t=+e.size;if(t!==t)throw new Gue(Tq);var n=Vue(t);if(n<0)throw new Kue(Tq);return new hq(e,n)}});var gq=w((ILe,Iq)=>{"use strict";m();T();N();var Que=vO(),Yue=SO(),Jue=dq(),Hue=DO();Iq.exports=function(t){var n=Que(this),r=Hue(t);return Yue(n)>r.size?!1:Jue(n,function(i){if(!r.includes(i))return!1},!0)!==!1}});var bO=w((SLe,Sq)=>{"use strict";m();T();N();var zue=nE(),_q=function(e){return{size:e,has:function(){return!1},keys:function(){return{next:function(){return{done:!0}}}}}},vq=function(e){return{size:e,has:function(){return!0},keys:function(){throw new Error("e")}}};Sq.exports=function(e,t){var n=zue("Set");try{new n()[e](_q(0));try{return new n()[e](_q(-1)),!1}catch(i){if(!t)return!0;try{return new n()[e](vq(-1/0)),!1}catch(a){var r=new n;return r.add(1),r.add(2),t(r[e](vq(1/0)))}}}catch(i){return!1}}});var Oq=w(()=>{"use strict";m();T();N();var Wue=gO(),Xue=gq(),Zue=bO(),ece=!Zue("isSubsetOf",function(e){return e});Wue({target:"Set",proto:!0,real:!0,forced:ece},{isSubsetOf:Xue})});var Dq=w(()=>{"use strict";m();T();N();Oq()});var Rq=w((MLe,Aq)=>{"use strict";m();T();N();var tce=fc(),bq=xp(),nce=HS();Aq.exports=function(e,t,n){var r,i;bq(e);try{if(r=nce(e,"return"),!r){if(t==="throw")throw n;return n}r=tce(r,e)}catch(a){i=!0,r=a}if(t==="throw")throw n;if(i)throw r;return bq(r),n}});var Fq=w((jLe,Pq)=>{"use strict";m();T();N();var rce=vO(),ice=jp().has,ace=SO(),sce=DO(),oce=OO(),uce=Rq();Pq.exports=function(t){var n=rce(this),r=sce(t);if(ace(n){"use strict";m();T();N();var cce=gO(),lce=Fq(),dce=bO(),pce=!dce("isSupersetOf",function(e){return!e});cce({target:"Set",proto:!0,real:!0,forced:pce},{isSupersetOf:lce})});var Lq=w(()=>{"use strict";m();T();N();wq()});var Kp=w(Cn=>{"use strict";m();T();N();Object.defineProperty(Cn,"__esModule",{value:!0});Cn.subtractSet=fce;Cn.mapToArrayOfValues=mce;Cn.kindToConvertedTypeString=Nce;Cn.fieldDatasToSimpleFieldDatas=Tce;Cn.isNodeLeaf=Ece;Cn.newEntityInterfaceFederationData=hce;Cn.upsertEntityInterfaceFederationData=yce;Cn.upsertEntityData=gce;Cn.updateEntityData=Cq;Cn.newFieldAuthorizationData=_ce;Cn.newAuthorizationData=vce;Cn.addScopes=AO;Cn.mergeRequiredScopesByAND=hE;Cn.mergeRequiredScopesByOR=RO;Cn.upsertFieldAuthorizationData=Bq;Cn.upsertAuthorizationData=Dce;Cn.upsertAuthorizationConfiguration=bce;Cn.isNodeKindObject=Ace;Cn.isInterfaceDefinitionData=Rce;Cn.isObjectDefinitionData=Pce;var en=Ae(),Zr=ur(),TE=Jr(),EE=Es();Dq();Lq();function fce(e,t){for(let n of e)t.delete(n)}function mce(e){let t=[];for(let n of e.values())t.push(n);return t}function Nce(e){switch(e){case en.Kind.BOOLEAN:return Zr.BOOLEAN_SCALAR;case en.Kind.ENUM:case en.Kind.ENUM_TYPE_DEFINITION:case en.Kind.ENUM_TYPE_EXTENSION:return Zr.ENUM;case en.Kind.ENUM_VALUE_DEFINITION:return Zr.ENUM_VALUE;case en.Kind.FIELD_DEFINITION:return Zr.FIELD;case en.Kind.FLOAT:return Zr.FLOAT_SCALAR;case en.Kind.INPUT_OBJECT_TYPE_DEFINITION:case en.Kind.INPUT_OBJECT_TYPE_EXTENSION:return Zr.INPUT_OBJECT;case en.Kind.INPUT_VALUE_DEFINITION:return Zr.INPUT_VALUE;case en.Kind.INT:return Zr.INT_SCALAR;case en.Kind.INTERFACE_TYPE_DEFINITION:case en.Kind.INTERFACE_TYPE_EXTENSION:return Zr.INTERFACE;case en.Kind.NULL:return Zr.NULL;case en.Kind.OBJECT:case en.Kind.OBJECT_TYPE_DEFINITION:case en.Kind.OBJECT_TYPE_EXTENSION:return Zr.OBJECT;case en.Kind.STRING:return Zr.STRING_SCALAR;case en.Kind.SCALAR_TYPE_DEFINITION:case en.Kind.SCALAR_TYPE_EXTENSION:return Zr.SCALAR;case en.Kind.UNION_TYPE_DEFINITION:case en.Kind.UNION_TYPE_EXTENSION:return Zr.UNION;default:return e}}function Tce(e){let t=[];for(let{name:n,namedTypeName:r}of e)t.push({name:n,namedTypeName:r});return t}function Ece(e){if(!e)return!0;switch(e){case en.Kind.OBJECT_TYPE_DEFINITION:case en.Kind.INTERFACE_TYPE_DEFINITION:case en.Kind.UNION_TYPE_DEFINITION:return!1;default:return!0}}function hce(e,t){return{concreteTypeNames:new Set(e.concreteTypeNames),fieldDatasBySubgraphName:new Map([[t,e.fieldDatas]]),interfaceFieldNames:new Set(e.interfaceFieldNames),interfaceObjectFieldNames:new Set(e.interfaceObjectFieldNames),interfaceObjectSubgraphs:new Set(e.isInterfaceObject?[t]:[]),subgraphDataByTypeName:new Map([[t,e]]),typeName:e.typeName}}function yce(e,t,n){(0,TE.addIterableValuesToSet)(t.concreteTypeNames,e.concreteTypeNames),e.subgraphDataByTypeName.set(n,t),e.fieldDatasBySubgraphName.set(n,t.fieldDatas),(0,TE.addIterableValuesToSet)(t.interfaceFieldNames,e.interfaceFieldNames),(0,TE.addIterableValuesToSet)(t.interfaceObjectFieldNames,e.interfaceObjectFieldNames),t.isInterfaceObject&&e.interfaceObjectSubgraphs.add(n)}function Ice({keyFieldSetDataByFieldSet:e,subgraphName:t,typeName:n}){let r=new Map([[t,e]]),i=new Map;for(let[a,{documentNode:o,isUnresolvable:c}]of e)c||i.set(a,o);return{keyFieldSetDatasBySubgraphName:r,documentNodeByKeyFieldSet:i,keyFieldSets:new Set,subgraphNames:new Set([t]),typeName:n}}function gce({entityDataByTypeName:e,keyFieldSetDataByFieldSet:t,subgraphName:n,typeName:r}){let i=e.get(r);i?Cq({entityData:i,keyFieldSetDataByFieldSet:t,subgraphName:n}):e.set(r,Ice({keyFieldSetDataByFieldSet:t,subgraphName:n,typeName:r}))}function Cq({entityData:e,keyFieldSetDataByFieldSet:t,subgraphName:n}){e.subgraphNames.add(n);let r=e.keyFieldSetDatasBySubgraphName.get(n);if(!r){e.keyFieldSetDatasBySubgraphName.set(n,t);for(let[i,{documentNode:a,isUnresolvable:o}]of t)o||e.documentNodeByKeyFieldSet.set(i,a);return}for(let[i,a]of t){a.isUnresolvable||e.documentNodeByKeyFieldSet.set(i,a.documentNode);let o=r.get(i);if(o){o.isUnresolvable||(o.isUnresolvable=a.isUnresolvable);continue}r.set(i,a)}}function _ce(e){return{fieldName:e,inheritedData:{requiredScopes:[],requiredScopesByOR:[],requiresAuthentication:!1},originalData:{requiredScopes:[],requiresAuthentication:!1}}}function vce(e){return{fieldAuthDataByFieldName:new Map,requiredScopes:[],requiredScopesByOR:[],requiresAuthentication:!1,typeName:e}}function AO(e,t){for(let n=e.length-1;n>-1;n--){if(e[n].isSubsetOf(t))return;e[n].isSupersetOf(t)&&e.splice(n,1)}e.push(t)}function hE(e,t){if(e.length<1||t.length<1){for(let r of t)e.push(new Set(r));return e}let n=[];for(let r of t)for(let i of e){let a=(0,TE.addSets)(r,i);AO(n,a)}return n}function RO(e,t){for(let n of t)AO(e,n);return e.length<=EE.MAX_OR_SCOPES}function Bq(e,t){var i,a;let n=t.fieldName,r=e.get(n);return r?((i=r.inheritedData).requiresAuthentication||(i.requiresAuthentication=t.inheritedData.requiresAuthentication),(a=r.originalData).requiresAuthentication||(a.requiresAuthentication=t.originalData.requiresAuthentication),!RO(r.inheritedData.requiredScopesByOR,t.inheritedData.requiredScopes)||r.inheritedData.requiredScopes.length*t.inheritedData.requiredScopes.length>EE.MAX_OR_SCOPES||r.originalData.requiredScopes.length*t.originalData.requiredScopes.length>EE.MAX_OR_SCOPES?!1:(r.inheritedData.requiredScopes=hE(r.inheritedData.requiredScopes,t.inheritedData.requiredScopes),r.originalData.requiredScopes=hE(r.originalData.requiredScopes,t.originalData.requiredScopes),!0)):(e.set(n,Uq(t)),!0)}function Sce(e){let t=new Map;for(let[n,r]of e)t.set(n,Uq(r));return t}function Uq(e){return{fieldName:e.fieldName,inheritedData:{requiredScopes:[...e.inheritedData.requiredScopes],requiredScopesByOR:[...e.inheritedData.requiredScopes],requiresAuthentication:e.inheritedData.requiresAuthentication},originalData:{requiredScopes:[...e.originalData.requiredScopes],requiresAuthentication:e.originalData.requiresAuthentication}}}function Oce(e){return{fieldAuthDataByFieldName:Sce(e.fieldAuthDataByFieldName),requiredScopes:[...e.requiredScopes],requiredScopesByOR:[...e.requiredScopes],requiresAuthentication:e.requiresAuthentication,typeName:e.typeName}}function Dce(e,t,n){let r=e.get(t.typeName);if(!r){e.set(t.typeName,Oce(t));return}r.requiresAuthentication||(r.requiresAuthentication=t.requiresAuthentication),!RO(r.requiredScopesByOR,t.requiredScopes)||r.requiredScopes.length*t.requiredScopes.length>EE.MAX_OR_SCOPES?n.add(t.typeName):r.requiredScopes=hE(r.requiredScopes,t.requiredScopes);for(let[i,a]of t.fieldAuthDataByFieldName)Bq(r.fieldAuthDataByFieldName,a)||n.add(`${t.typeName}.${i}`)}function bce(e,t){let n=t.typeName;for(let[r,i]of t.fieldAuthDataByFieldName){let a=`${n}.${r}`,o=e.get(a);o?(o.requiresAuthentication=i.inheritedData.requiresAuthentication,o.requiredScopes=i.inheritedData.requiredScopes.map(c=>[...c]),o.requiredScopesByOR=i.inheritedData.requiredScopesByOR.map(c=>[...c])):e.set(a,{argumentNames:[],typeName:n,fieldName:r,requiresAuthentication:i.inheritedData.requiresAuthentication,requiredScopes:i.inheritedData.requiredScopes.map(c=>[...c]),requiredScopesByOR:i.inheritedData.requiredScopesByOR.map(c=>[...c])})}}function Ace(e){return e===en.Kind.OBJECT_TYPE_DEFINITION||e===en.Kind.OBJECT_TYPE_EXTENSION}function Rce(e){return e.kind===en.Kind.INTERFACE_TYPE_DEFINITION}function Pce(e){return e?e.kind===en.Kind.OBJECT_TYPE_DEFINITION:!1}});var PO=w(Je=>{"use strict";m();T();N();Object.defineProperty(Je,"__esModule",{value:!0});Je.TAG_DEFINITION_DATA=Je.SUBSCRIPTION_FILTER_DEFINITION_DATA=Je.SHAREABLE_DEFINITION_DATA=Je.SPECIFIED_BY_DEFINITION_DATA=Je.REQUIRES_SCOPES_DEFINITION_DATA=Je.REQUIRES_DEFINITION_DATA=Je.PROVIDES_DEFINITION_DATA=Je.LINK_DEFINITION_DATA=Je.KEY_DEFINITION_DATA=Je.OVERRIDE_DEFINITION_DATA=Je.REDIS_SUBSCRIBE_DEFINITION_DATA=Je.REDIS_PUBLISH_DEFINITION_DATA=Je.NATS_SUBSCRIBE_DEFINITION_DATA=Je.NATS_REQUEST_DEFINITION_DATA=Je.NATS_PUBLISH_DEFINITION_DATA=Je.KAFKA_SUBSCRIBE_DEFINITION_DATA=Je.KAFKA_PUBLISH_DEFINITION_DATA=Je.INTERFACE_OBJECT_DEFINITION_DATA=Je.INACCESSIBLE_DEFINITION_DATA=Je.EXTERNAL_DEFINITION_DATA=Je.EXTENDS_DEFINITION_DATA=Je.DEPRECATED_DEFINITION_DATA=Je.CONFIGURE_CHILD_DESCRIPTIONS_DEFINITION_DATA=Je.CONFIGURE_DESCRIPTION_DEFINITION_DATA=Je.COMPOSE_DIRECTIVE_DEFINITION_DATA=Je.AUTHENTICATED_DEFINITION_DATA=void 0;var it=Es(),da=Yr(),ln=Ae(),q=ur();Je.AUTHENTICATED_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([]),isRepeatable:!1,locations:new Set([q.ENUM_UPPER,q.FIELD_DEFINITION_UPPER,q.INTERFACE_UPPER,q.OBJECT_UPPER,q.SCALAR_UPPER]),name:q.AUTHENTICATED,node:it.AUTHENTICATED_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set};Je.COMPOSE_DIRECTIVE_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.NAME,{name:q.NAME,typeNode:it.REQUIRED_STRING_TYPE_NODE}]]),isRepeatable:!0,locations:new Set([q.SCHEMA_UPPER]),name:q.COMPOSE_DIRECTIVE,node:it.COMPOSE_DIRECTIVE_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set([q.NAME])};Je.CONFIGURE_DESCRIPTION_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.PROPAGATE,{name:q.PROPAGATE,typeNode:{kind:ln.Kind.NON_NULL_TYPE,type:(0,da.stringToNamedTypeNode)(q.BOOLEAN_SCALAR)},defaultValue:{kind:ln.Kind.BOOLEAN,value:!0}}],[q.DESCRIPTION_OVERRIDE,{name:q.DESCRIPTION_OVERRIDE,typeNode:(0,da.stringToNamedTypeNode)(q.STRING_SCALAR)}]]),isRepeatable:!1,locations:new Set([q.ARGUMENT_DEFINITION_UPPER,q.ENUM_UPPER,q.ENUM_VALUE_UPPER,q.FIELD_DEFINITION_UPPER,q.INTERFACE_UPPER,q.INPUT_OBJECT_UPPER,q.INPUT_FIELD_DEFINITION_UPPER,q.OBJECT_UPPER,q.SCALAR_UPPER,q.SCHEMA_UPPER,q.UNION_UPPER]),name:q.CONFIGURE_DESCRIPTION,node:it.CONFIGURE_DESCRIPTION_DEFINITION,optionalArgumentNames:new Set([q.PROPAGATE,q.DESCRIPTION_OVERRIDE]),requiredArgumentNames:new Set};Je.CONFIGURE_CHILD_DESCRIPTIONS_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.PROPAGATE,{name:q.PROPAGATE,typeNode:{kind:ln.Kind.NON_NULL_TYPE,type:(0,da.stringToNamedTypeNode)(q.BOOLEAN_SCALAR)},defaultValue:{kind:ln.Kind.BOOLEAN,value:!0}}]]),isRepeatable:!1,locations:new Set([q.ENUM_UPPER,q.INPUT_OBJECT_UPPER,q.INTERFACE_UPPER,q.OBJECT_UPPER]),name:q.CONFIGURE_CHILD_DESCRIPTIONS,node:it.CONFIGURE_CHILD_DESCRIPTIONS_DEFINITION,optionalArgumentNames:new Set([q.PROPAGATE]),requiredArgumentNames:new Set};Je.DEPRECATED_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.REASON,{name:q.REASON,typeNode:(0,da.stringToNamedTypeNode)(q.STRING_SCALAR),defaultValue:{kind:ln.Kind.STRING,value:ln.DEFAULT_DEPRECATION_REASON}}]]),isRepeatable:!1,locations:new Set([q.ARGUMENT_DEFINITION_UPPER,q.ENUM_VALUE_UPPER,q.FIELD_DEFINITION_UPPER,q.INPUT_FIELD_DEFINITION_UPPER]),name:q.DEPRECATED,node:it.DEPRECATED_DEFINITION,optionalArgumentNames:new Set([q.REASON]),requiredArgumentNames:new Set};Je.EXTENDS_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map,isRepeatable:!1,locations:new Set([q.INTERFACE_UPPER,q.OBJECT_UPPER]),name:q.EXTENDS,node:it.EXTENDS_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set};Je.EXTERNAL_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map,isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER,q.OBJECT_UPPER]),name:q.EXTERNAL,node:it.EXTERNAL_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set};Je.INACCESSIBLE_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map,isRepeatable:!1,locations:new Set([q.ARGUMENT_DEFINITION_UPPER,q.ENUM_UPPER,q.ENUM_VALUE_UPPER,q.FIELD_DEFINITION_UPPER,q.INPUT_FIELD_DEFINITION_UPPER,q.INPUT_OBJECT_UPPER,q.INTERFACE_UPPER,q.OBJECT_UPPER,q.SCALAR_UPPER,q.UNION_UPPER]),name:q.INACCESSIBLE,node:it.INACCESSIBLE_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set};Je.INTERFACE_OBJECT_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map,isRepeatable:!1,locations:new Set([q.OBJECT_UPPER]),name:q.INTERFACE_OBJECT,node:it.INTERFACE_OBJECT_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set};Je.KAFKA_PUBLISH_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.TOPIC,{name:q.TOPIC,typeNode:it.REQUIRED_STRING_TYPE_NODE}],[q.PROVIDER_ID,{name:q.PROVIDER_ID,typeNode:it.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ln.Kind.STRING,value:q.DEFAULT_EDFS_PROVIDER_ID}}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.EDFS_KAFKA_PUBLISH,node:it.EDFS_KAFKA_PUBLISH_DEFINITION,optionalArgumentNames:new Set([q.PROVIDER_ID]),requiredArgumentNames:new Set([q.TOPIC])};Je.KAFKA_SUBSCRIBE_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.TOPICS,{name:q.TOPICS,typeNode:{kind:ln.Kind.NON_NULL_TYPE,type:{kind:ln.Kind.LIST_TYPE,type:it.REQUIRED_STRING_TYPE_NODE}}}],[q.PROVIDER_ID,{name:q.PROVIDER_ID,typeNode:it.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ln.Kind.STRING,value:q.DEFAULT_EDFS_PROVIDER_ID}}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.EDFS_KAFKA_SUBSCRIBE,node:it.EDFS_KAFKA_SUBSCRIBE_DEFINITION,optionalArgumentNames:new Set([q.PROVIDER_ID]),requiredArgumentNames:new Set([q.TOPICS])};Je.NATS_PUBLISH_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.SUBJECT,{name:q.SUBJECT,typeNode:it.REQUIRED_STRING_TYPE_NODE}],[q.PROVIDER_ID,{name:q.PROVIDER_ID,typeNode:it.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ln.Kind.STRING,value:q.DEFAULT_EDFS_PROVIDER_ID}}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.EDFS_NATS_PUBLISH,node:it.EDFS_NATS_PUBLISH_DEFINITION,optionalArgumentNames:new Set([q.PROVIDER_ID]),requiredArgumentNames:new Set([q.SUBJECT])};Je.NATS_REQUEST_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.SUBJECT,{name:q.SUBJECT,typeNode:it.REQUIRED_STRING_TYPE_NODE}],[q.PROVIDER_ID,{name:q.PROVIDER_ID,typeNode:it.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ln.Kind.STRING,value:q.DEFAULT_EDFS_PROVIDER_ID}}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.EDFS_NATS_REQUEST,node:it.EDFS_NATS_REQUEST_DEFINITION,optionalArgumentNames:new Set([q.PROVIDER_ID]),requiredArgumentNames:new Set([q.SUBJECT])};Je.NATS_SUBSCRIBE_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.SUBJECTS,{name:q.SUBJECTS,typeNode:{kind:ln.Kind.NON_NULL_TYPE,type:{kind:ln.Kind.LIST_TYPE,type:it.REQUIRED_STRING_TYPE_NODE}}}],[q.PROVIDER_ID,{name:q.PROVIDER_ID,typeNode:it.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ln.Kind.STRING,value:q.DEFAULT_EDFS_PROVIDER_ID}}],[q.STREAM_CONFIGURATION,{name:q.STREAM_CONFIGURATION,typeNode:(0,da.stringToNamedTypeNode)(q.EDFS_NATS_STREAM_CONFIGURATION)}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.EDFS_NATS_SUBSCRIBE,node:it.EDFS_NATS_SUBSCRIBE_DEFINITION,optionalArgumentNames:new Set([q.PROVIDER_ID]),requiredArgumentNames:new Set([q.SUBJECTS])};Je.REDIS_PUBLISH_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.CHANNEL,{name:q.CHANNEL,typeNode:it.REQUIRED_STRING_TYPE_NODE}],[q.PROVIDER_ID,{name:q.PROVIDER_ID,typeNode:it.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ln.Kind.STRING,value:q.DEFAULT_EDFS_PROVIDER_ID}}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.EDFS_REDIS_PUBLISH,node:it.EDFS_REDIS_PUBLISH_DEFINITION,optionalArgumentNames:new Set([q.PROVIDER_ID]),requiredArgumentNames:new Set([q.CHANNEL])};Je.REDIS_SUBSCRIBE_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.CHANNELS,{name:q.CHANNELS,typeNode:{kind:ln.Kind.NON_NULL_TYPE,type:{kind:ln.Kind.LIST_TYPE,type:it.REQUIRED_STRING_TYPE_NODE}}}],[q.PROVIDER_ID,{name:q.PROVIDER_ID,typeNode:it.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ln.Kind.STRING,value:q.DEFAULT_EDFS_PROVIDER_ID}}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.EDFS_REDIS_SUBSCRIBE,node:it.EDFS_REDIS_SUBSCRIBE_DEFINITION,optionalArgumentNames:new Set([q.PROVIDER_ID]),requiredArgumentNames:new Set([q.CHANNELS])};Je.OVERRIDE_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.FROM,{name:q.FROM,typeNode:it.REQUIRED_STRING_TYPE_NODE}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.OVERRIDE,node:it.OVERRIDE_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set([q.FROM])};Je.KEY_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.FIELDS,{name:q.FIELDS,typeNode:it.REQUIRED_FIELDSET_TYPE_NODE}],[q.RESOLVABLE,{name:q.RESOLVABLE,typeNode:(0,da.stringToNamedTypeNode)(q.BOOLEAN_SCALAR),defaultValue:{kind:ln.Kind.BOOLEAN,value:!0}}]]),isRepeatable:!0,locations:new Set([q.INTERFACE_UPPER,q.OBJECT_UPPER]),name:q.KEY,node:it.KEY_DEFINITION,optionalArgumentNames:new Set([q.RESOLVABLE]),requiredArgumentNames:new Set([q.FIELDS])};Je.LINK_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.URL_LOWER,{name:q.URL_LOWER,typeNode:it.REQUIRED_STRING_TYPE_NODE}],[q.AS,{name:q.AS,typeNode:(0,da.stringToNamedTypeNode)(q.STRING_SCALAR)}],[q.FOR,{name:q.FOR,typeNode:(0,da.stringToNamedTypeNode)(q.LINK_PURPOSE)}],[q.IMPORT,{name:q.IMPORT,typeNode:{kind:ln.Kind.LIST_TYPE,type:(0,da.stringToNamedTypeNode)(q.LINK_IMPORT)}}]]),isRepeatable:!0,locations:new Set([q.SCHEMA_UPPER]),name:q.LINK,node:it.LINK_DEFINITION,optionalArgumentNames:new Set([q.AS,q.FOR,q.IMPORT]),requiredArgumentNames:new Set([q.URL_LOWER])};Je.PROVIDES_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.FIELDS,{name:q.FIELDS,typeNode:it.REQUIRED_FIELDSET_TYPE_NODE}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.PROVIDES,node:it.PROVIDES_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set([q.FIELDS])};Je.REQUIRES_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.FIELDS,{name:q.FIELDS,typeNode:it.REQUIRED_FIELDSET_TYPE_NODE}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.REQUIRES,node:it.REQUIRES_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set([q.FIELDS])};Je.REQUIRES_SCOPES_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.SCOPES,{name:q.SCOPES,typeNode:{kind:ln.Kind.NON_NULL_TYPE,type:{kind:ln.Kind.LIST_TYPE,type:{kind:ln.Kind.NON_NULL_TYPE,type:{kind:ln.Kind.LIST_TYPE,type:{kind:ln.Kind.NON_NULL_TYPE,type:(0,da.stringToNamedTypeNode)(q.SCOPE_SCALAR)}}}}}}]]),isRepeatable:!1,locations:new Set([q.ENUM_UPPER,q.FIELD_DEFINITION_UPPER,q.INTERFACE_UPPER,q.OBJECT_UPPER,q.SCALAR_UPPER]),name:q.REQUIRES_SCOPES,node:it.REQUIRES_SCOPES_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set([q.SCOPES])};Je.SPECIFIED_BY_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.URL_LOWER,{name:q.URL_LOWER,typeNode:it.REQUIRED_STRING_TYPE_NODE}]]),isRepeatable:!1,locations:new Set([q.SCALAR_UPPER]),name:q.SPECIFIED_BY,node:it.SPECIFIED_BY_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set([q.URL_LOWER])};Je.SHAREABLE_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map,isRepeatable:!0,locations:new Set([q.FIELD_DEFINITION_UPPER,q.OBJECT_UPPER]),name:q.SHAREABLE,node:it.SHAREABLE_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set};Je.SUBSCRIPTION_FILTER_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.CONDITION,{name:q.CONDITION,typeNode:{kind:ln.Kind.NON_NULL_TYPE,type:(0,da.stringToNamedTypeNode)(q.SUBSCRIPTION_FILTER_CONDITION)}}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.SUBSCRIPTION_FILTER,node:it.SUBSCRIPTION_FILTER_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set([q.CONDITION])};Je.TAG_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.NAME,{name:q.NAME,typeNode:it.REQUIRED_STRING_TYPE_NODE}]]),isRepeatable:!0,locations:new Set([q.ARGUMENT_DEFINITION_UPPER,q.ENUM_UPPER,q.ENUM_VALUE_UPPER,q.FIELD_DEFINITION_UPPER,q.INPUT_FIELD_DEFINITION_UPPER,q.INPUT_OBJECT_UPPER,q.INTERFACE_UPPER,q.OBJECT_UPPER,q.SCALAR_UPPER,q.UNION_UPPER]),name:q.TAG,node:it.TAG_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set([q.NAME])}});var Gp=w(pa=>{"use strict";m();T();N();Object.defineProperty(pa,"__esModule",{value:!0});pa.newFieldSetData=Fce;pa.extractFieldSetValue=wce;pa.getNormalizedFieldSet=Lce;pa.getInitialFieldCoordsPath=Cce;pa.validateKeyFieldSets=Bce;pa.getConditionalFieldSetDirectiveName=Uce;pa.isNodeQuery=kce;pa.validateArgumentTemplateReferences=Mce;pa.initializeDirectiveDefinitionDatas=xce;var er=Ae(),kq=Yr(),br=ia(),Mq=Es(),FO=ou(),mn=PO(),Mt=ur(),Tu=Jr();function Fce(){return{provides:new Map,requires:new Map}}function wce(e,t,n){if(!n||n.length>1)return;let r=n[0].arguments;if(!r||r.length!==1)return;let i=r[0];i.name.value!==Mt.FIELDS||i.value.kind!==er.Kind.STRING||t.set(e,i.value.value)}function Lce(e){return(0,er.print)((0,kq.lexicographicallySortDocumentNode)(e)).replaceAll(/\s+/g," ").slice(2,-2)}function Cce(e,t){return e?[t]:[]}function Bce(e,t,n){let r=e.entityInterfaceDataByTypeName.get(t.name),i=t.name,a=[],o=[],c=r?void 0:e.internalGraph.addEntityDataNode(t.name),l=e.internalGraph.addOrUpdateNode(t.name),p=0;for(let[f,{documentNode:y,isUnresolvable:g,rawFieldSet:v}]of n){r&&(r.resolvable||(r.resolvable=!g)),p+=1;let F=[],k=[t],K=[],$=[],ne=new Set,z=-1,Te=!0,pe="";if((0,er.visit)(y,{Argument:{enter(Fe){return F.push((0,br.unexpectedArgumentErrorMessage)(v,`${k[z].name}.${pe}`,Fe.name.value)),er.BREAK}},Field:{enter(Fe){let Ve=k[z],et=Ve.name;if(Te){let Dn=`${et}.${pe}`,Vt=Ve.fieldDataByName.get(pe);if(!Vt)return F.push((0,br.undefinedFieldInFieldSetErrorMessage)(v,Dn,pe)),er.BREAK;let dn=(0,FO.getTypeNodeNamedTypeName)(Vt.node.type),Ar=e.parentDefinitionDataByTypeName.get(dn),Rr=Ar?Ar.kind:er.Kind.SCALAR_TYPE_DEFINITION;return F.push((0,br.invalidSelectionSetErrorMessage)(v,[Dn],dn,(0,Tu.kindToNodeType)(Rr))),er.BREAK}let X=Fe.name.value,ve=`${et}.${X}`;pe=X;let gt=Ve.fieldDataByName.get(X);if(!gt)return F.push((0,br.undefinedFieldInFieldSetErrorMessage)(v,et,X)),er.BREAK;if(gt.argumentDataByName.size)return F.push((0,br.argumentsInKeyFieldSetErrorMessage)(v,ve)),er.BREAK;if(K[z].has(X))return F.push((0,br.duplicateFieldInFieldSetErrorMessage)(v,ve)),er.BREAK;(0,Tu.getValueOrDefault)((0,Tu.getValueOrDefault)(e.keyFieldSetsByEntityTypeNameByFieldCoords,ve,()=>new Map),i,()=>new Set).add(f),$.push(X),gt.isShareableBySubgraphName.set(e.subgraphName,!0),K[z].add(X),(0,Tu.getValueOrDefault)(e.keyFieldNamesByParentTypeName,et,()=>new Set).add(X);let zt=(0,FO.getTypeNodeNamedTypeName)(gt.node.type);if(Mq.BASE_SCALARS.has(zt)){ne.add($.join(Mt.PERIOD)),$.pop();return}let Wt=e.parentDefinitionDataByTypeName.get(zt);if(!Wt)return F.push((0,br.unknownTypeInFieldSetErrorMessage)(v,ve,zt)),er.BREAK;if(Wt.kind===er.Kind.OBJECT_TYPE_DEFINITION){Te=!0,k.push(Wt);return}if((0,kq.isKindAbstract)(Wt.kind))return F.push((0,br.abstractTypeInKeyFieldSetErrorMessage)(v,ve,zt,(0,Tu.kindToNodeType)(Wt.kind))),er.BREAK;ne.add($.join(Mt.PERIOD)),$.pop()}},InlineFragment:{enter(){return F.push(br.inlineFragmentInFieldSetErrorMessage),er.BREAK}},SelectionSet:{enter(){if(!Te){let Fe=k[z],et=`${Fe.name}.${pe}`,X=Fe.fieldDataByName.get(pe);if(!X)return F.push((0,br.undefinedFieldInFieldSetErrorMessage)(v,et,pe)),er.BREAK;let ve=(0,FO.getTypeNodeNamedTypeName)(X.node.type),gt=e.parentDefinitionDataByTypeName.get(ve),zt=gt?gt.kind:er.Kind.SCALAR_TYPE_DEFINITION;return F.push((0,br.invalidSelectionSetDefinitionErrorMessage)(v,[et],ve,(0,Tu.kindToNodeType)(zt))),er.BREAK}if(z+=1,Te=!1,z<0||z>=k.length)return F.push((0,br.unparsableFieldSetSelectionErrorMessage)(v,pe)),er.BREAK;K.push(new Set)},leave(){if(Te){let Ve=k[z].name,et=k[z+1],X=`${Ve}.${pe}`;F.push((0,br.invalidSelectionSetErrorMessage)(v,[X],et.name,(0,Tu.kindToNodeType)(et.kind))),Te=!1}z-=1,k.pop(),K.pop()}}}),F.length>0){e.errors.push((0,br.invalidDirectiveError)(Mt.KEY,i,(0,Tu.numberToOrdinal)(p),F));continue}a.push(x({fieldName:"",selectionSet:f},g?{disableEntityResolver:!0}:{})),l.satisfiedFieldSets.add(f),!g&&(c==null||c.addTargetSubgraphByFieldSet(f,e.subgraphName),o.push(ne))}if(a.length>0)return a}function Uce(e){return e?Mt.PROVIDES:Mt.REQUIRES}function kce(e,t){return e===Mt.QUERY||t===er.OperationTypeNode.QUERY}function Mce(e,t,n){let r=e.matchAll(Mq.EDFS_ARGS_REGEXP),i=new Set,a=new Set;for(let o of r){if(o.length<2){a.add(o[0]);continue}t.has(o[1])||i.add(o[1])}for(let o of i)n.push((0,br.undefinedEventSubjectsArgumentErrorMessage)(o));for(let o of a)n.push((0,br.invalidEventSubjectsArgumentErrorMessage)(o))}function xce(){return new Map([[Mt.AUTHENTICATED,mn.AUTHENTICATED_DEFINITION_DATA],[Mt.COMPOSE_DIRECTIVE,mn.COMPOSE_DIRECTIVE_DEFINITION_DATA],[Mt.CONFIGURE_DESCRIPTION,mn.CONFIGURE_DESCRIPTION_DEFINITION_DATA],[Mt.CONFIGURE_CHILD_DESCRIPTIONS,mn.CONFIGURE_CHILD_DESCRIPTIONS_DEFINITION_DATA],[Mt.DEPRECATED,mn.DEPRECATED_DEFINITION_DATA],[Mt.EDFS_KAFKA_PUBLISH,mn.KAFKA_PUBLISH_DEFINITION_DATA],[Mt.EDFS_KAFKA_SUBSCRIBE,mn.KAFKA_SUBSCRIBE_DEFINITION_DATA],[Mt.EDFS_NATS_PUBLISH,mn.NATS_PUBLISH_DEFINITION_DATA],[Mt.EDFS_NATS_REQUEST,mn.NATS_REQUEST_DEFINITION_DATA],[Mt.EDFS_NATS_SUBSCRIBE,mn.NATS_SUBSCRIBE_DEFINITION_DATA],[Mt.EDFS_REDIS_PUBLISH,mn.REDIS_PUBLISH_DEFINITION_DATA],[Mt.EDFS_REDIS_SUBSCRIBE,mn.REDIS_SUBSCRIBE_DEFINITION_DATA],[Mt.EXTENDS,mn.EXTENDS_DEFINITION_DATA],[Mt.EXTERNAL,mn.EXTERNAL_DEFINITION_DATA],[Mt.INACCESSIBLE,mn.INACCESSIBLE_DEFINITION_DATA],[Mt.INTERFACE_OBJECT,mn.INTERFACE_OBJECT_DEFINITION_DATA],[Mt.KEY,mn.KEY_DEFINITION_DATA],[Mt.LINK,mn.LINK_DEFINITION_DATA],[Mt.OVERRIDE,mn.OVERRIDE_DEFINITION_DATA],[Mt.PROVIDES,mn.PROVIDES_DEFINITION_DATA],[Mt.REQUIRES,mn.REQUIRES_DEFINITION_DATA],[Mt.REQUIRES_SCOPES,mn.REQUIRES_SCOPES_DEFINITION_DATA],[Mt.SHAREABLE,mn.SHAREABLE_DEFINITION_DATA],[Mt.SPECIFIED_BY,mn.SPECIFIED_BY_DEFINITION_DATA],[Mt.SUBSCRIPTION_FILTER,mn.SUBSCRIPTION_FILTER_DEFINITION_DATA],[Mt.TAG,mn.TAG_DEFINITION_DATA]])}});var LO=w(wO=>{"use strict";m();T();N();Object.defineProperty(wO,"__esModule",{value:!0});wO.recordSubgraphName=qce;function qce(e,t,n){if(!t.has(e)){t.add(e);return}n.add(e)}});var BO=w(yE=>{"use strict";m();T();N();Object.defineProperty(yE,"__esModule",{value:!0});yE.Warning=void 0;var CO=class extends Error{constructor(n){super(n.message);_(this,"subgraph");this.name="Warning",this.subgraph=n.subgraph}};yE.Warning=CO});var gE=w(fa=>{"use strict";m();T();N();Object.defineProperty(fa,"__esModule",{value:!0});fa.invalidOverrideTargetSubgraphNameWarning=Vce;fa.externalInterfaceFieldsWarning=jce;fa.nonExternalConditionalFieldWarning=Kce;fa.unimplementedInterfaceOutputTypeWarning=Gce;fa.invalidExternalFieldWarning=$ce;fa.requiresDefinedOnNonEntityFieldWarning=Qce;fa.consumerInactiveThresholdInvalidValueWarning=Yce;fa.externalEntityExtensionKeyFieldWarning=Jce;fa.fieldAlreadyProvidedWarning=Hce;var gs=BO(),UO=ur();function Vce(e,t,n,r){return new gs.Warning({message:`The Object type "${t}" defines the directive "@override(from: "${e}")" on the following field`+(n.length>1?"s":"")+': "'+n.join(UO.QUOTATION_JOIN)+`". + "`+n.join(We.QUOTATION_JOIN)+'"')}function bae({data:e,namedTypeData:t,nodeType:n}){let r=(0,zne.isFieldData)(e),i=r?`${e.originalParentTypeName}.${e.name}`:e.originalCoords;return new Error(`The ${n} "${i}" is invalid because it defines type `+(0,Wne.printTypeNode)(e.type)+`; however, ${(0,Vl.kindToNodeType)(t.kind)} "${t.name}" is not a valid `+(r?"output":"input")+" type.")}});var Pk=w(Rk=>{"use strict";m();T();N();Object.defineProperty(Rk,"__esModule",{value:!0})});var kp=w(ji=>{"use strict";m();T();N();Object.defineProperty(ji,"__esModule",{value:!0});ji.SUBSCRIPTION_FILTER_LIST_INPUT_NAMES=ji.SUBSCRIPTION_FILTER_INPUT_NAMES=ji.STREAM_CONFIGURATION_FIELD_NAMES=ji.EVENT_DIRECTIVE_NAMES=ji.TYPE_SYSTEM_DIRECTIVE_LOCATIONS=void 0;var cn=ur();ji.TYPE_SYSTEM_DIRECTIVE_LOCATIONS=new Set([cn.ARGUMENT_DEFINITION_UPPER,cn.ENUM_UPPER,cn.ENUM_VALUE_UPPER,cn.FIELD_DEFINITION_UPPER,cn.INPUT_FIELD_DEFINITION_UPPER,cn.INPUT_OBJECT_UPPER,cn.INTERFACE_UPPER,cn.OBJECT_UPPER,cn.SCALAR_UPPER,cn.SCHEMA_UPPER,cn.UNION_UPPER]);ji.EVENT_DIRECTIVE_NAMES=new Set([cn.EDFS_KAFKA_PUBLISH,cn.EDFS_KAFKA_SUBSCRIBE,cn.EDFS_NATS_PUBLISH,cn.EDFS_NATS_REQUEST,cn.EDFS_NATS_SUBSCRIBE,cn.EDFS_REDIS_PUBLISH,cn.EDFS_REDIS_SUBSCRIBE]);ji.STREAM_CONFIGURATION_FIELD_NAMES=new Set([cn.CONSUMER_INACTIVE_THRESHOLD,cn.CONSUMER_NAME,cn.STREAM_NAME]);ji.SUBSCRIPTION_FILTER_INPUT_NAMES=new Set([cn.AND_UPPER,cn.IN_UPPER,cn.NOT_UPPER,cn.OR_UPPER]);ji.SUBSCRIPTION_FILTER_LIST_INPUT_NAMES=new Set([cn.AND_UPPER,cn.OR_UPPER])});var Ki=w((US,Fk)=>{"use strict";m();T();N();var Mp=function(e){return e&&e.Math===Math&&e};Fk.exports=Mp(typeof globalThis=="object"&&globalThis)||Mp(typeof window=="object"&&window)||Mp(typeof self=="object"&&self)||Mp(typeof global=="object"&&global)||Mp(typeof US=="object"&&US)||function(){return this}()||Function("return this")()});var Is=w((nAe,wk)=>{"use strict";m();T();N();wk.exports=function(e){try{return!!e()}catch(t){return!0}}});var mu=w((sAe,Lk)=>{"use strict";m();T();N();var Aae=Is();Lk.exports=!Aae(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!==7})});var kS=w((lAe,Ck)=>{"use strict";m();T();N();var Rae=Is();Ck.exports=!Rae(function(){var e=function(){}.bind();return typeof e!="function"||e.hasOwnProperty("prototype")})});var fc=w((mAe,Bk)=>{"use strict";m();T();N();var Pae=kS(),eE=Function.prototype.call;Bk.exports=Pae?eE.bind(eE):function(){return eE.apply(eE,arguments)}});var xk=w(Mk=>{"use strict";m();T();N();var Uk={}.propertyIsEnumerable,kk=Object.getOwnPropertyDescriptor,Fae=kk&&!Uk.call({1:2},1);Mk.f=Fae?function(t){var n=kk(this,t);return!!n&&n.enumerable}:Uk});var MS=w((_Ae,qk)=>{"use strict";m();T();N();qk.exports=function(e,t){return{enumerable:!(e&1),configurable:!(e&2),writable:!(e&4),value:t}}});var mi=w((DAe,Kk)=>{"use strict";m();T();N();var Vk=kS(),jk=Function.prototype,xS=jk.call,wae=Vk&&jk.bind.bind(xS,xS);Kk.exports=Vk?wae:function(e){return function(){return xS.apply(e,arguments)}}});var Qk=w((PAe,$k)=>{"use strict";m();T();N();var Gk=mi(),Lae=Gk({}.toString),Cae=Gk("".slice);$k.exports=function(e){return Cae(Lae(e),8,-1)}});var Jk=w((CAe,Yk)=>{"use strict";m();T();N();var Bae=mi(),Uae=Is(),kae=Qk(),qS=Object,Mae=Bae("".split);Yk.exports=Uae(function(){return!qS("z").propertyIsEnumerable(0)})?function(e){return kae(e)==="String"?Mae(e,""):qS(e)}:qS});var VS=w((MAe,Hk)=>{"use strict";m();T();N();Hk.exports=function(e){return e==null}});var jS=w((jAe,zk)=>{"use strict";m();T();N();var xae=VS(),qae=TypeError;zk.exports=function(e){if(xae(e))throw new qae("Can't call method on "+e);return e}});var tE=w((QAe,Wk)=>{"use strict";m();T();N();var Vae=Jk(),jae=jS();Wk.exports=function(e){return Vae(jae(e))}});var ua=w((zAe,Xk)=>{"use strict";m();T();N();var KS=typeof document=="object"&&document.all;Xk.exports=typeof KS=="undefined"&&KS!==void 0?function(e){return typeof e=="function"||e===KS}:function(e){return typeof e=="function"}});var jl=w((eRe,Zk)=>{"use strict";m();T();N();var Kae=ua();Zk.exports=function(e){return typeof e=="object"?e!==null:Kae(e)}});var nE=w((iRe,eM)=>{"use strict";m();T();N();var GS=Ki(),Gae=ua(),$ae=function(e){return Gae(e)?e:void 0};eM.exports=function(e,t){return arguments.length<2?$ae(GS[e]):GS[e]&&GS[e][t]}});var nM=w((uRe,tM)=>{"use strict";m();T();N();var Qae=mi();tM.exports=Qae({}.isPrototypeOf)});var sM=w((pRe,aM)=>{"use strict";m();T();N();var Yae=Ki(),rM=Yae.navigator,iM=rM&&rM.userAgent;aM.exports=iM?String(iM):""});var fM=w((TRe,pM)=>{"use strict";m();T();N();var dM=Ki(),$S=sM(),oM=dM.process,uM=dM.Deno,cM=oM&&oM.versions||uM&&uM.version,lM=cM&&cM.v8,ca,rE;lM&&(ca=lM.split("."),rE=ca[0]>0&&ca[0]<4?1:+(ca[0]+ca[1]));!rE&&$S&&(ca=$S.match(/Edge\/(\d+)/),(!ca||ca[1]>=74)&&(ca=$S.match(/Chrome\/(\d+)/),ca&&(rE=+ca[1])));pM.exports=rE});var QS=w((IRe,NM)=>{"use strict";m();T();N();var mM=fM(),Jae=Is(),Hae=Ki(),zae=Hae.String;NM.exports=!!Object.getOwnPropertySymbols&&!Jae(function(){var e=Symbol("symbol detection");return!zae(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&mM&&mM<41})});var YS=w((SRe,TM)=>{"use strict";m();T();N();var Wae=QS();TM.exports=Wae&&!Symbol.sham&&typeof Symbol.iterator=="symbol"});var JS=w((ARe,EM)=>{"use strict";m();T();N();var Xae=nE(),Zae=ua(),ese=nM(),tse=YS(),nse=Object;EM.exports=tse?function(e){return typeof e=="symbol"}:function(e){var t=Xae("Symbol");return Zae(t)&&ese(t.prototype,nse(e))}});var yM=w((wRe,hM)=>{"use strict";m();T();N();var rse=String;hM.exports=function(e){try{return rse(e)}catch(t){return"Object"}}});var iE=w((URe,IM)=>{"use strict";m();T();N();var ise=ua(),ase=yM(),sse=TypeError;IM.exports=function(e){if(ise(e))return e;throw new sse(ase(e)+" is not a function")}});var HS=w((qRe,gM)=>{"use strict";m();T();N();var ose=iE(),use=VS();gM.exports=function(e,t){var n=e[t];return use(n)?void 0:ose(n)}});var vM=w((GRe,_M)=>{"use strict";m();T();N();var zS=fc(),WS=ua(),XS=jl(),cse=TypeError;_M.exports=function(e,t){var n,r;if(t==="string"&&WS(n=e.toString)&&!XS(r=zS(n,e))||WS(n=e.valueOf)&&!XS(r=zS(n,e))||t!=="string"&&WS(n=e.toString)&&!XS(r=zS(n,e)))return r;throw new cse("Can't convert object to primitive value")}});var OM=w((JRe,SM)=>{"use strict";m();T();N();SM.exports=!1});var aE=w((XRe,bM)=>{"use strict";m();T();N();var DM=Ki(),lse=Object.defineProperty;bM.exports=function(e,t){try{lse(DM,e,{value:t,configurable:!0,writable:!0})}catch(n){DM[e]=t}return t}});var sE=w((nPe,PM)=>{"use strict";m();T();N();var dse=OM(),pse=Ki(),fse=aE(),AM="__core-js_shared__",RM=PM.exports=pse[AM]||fse(AM,{});(RM.versions||(RM.versions=[])).push({version:"3.41.0",mode:dse?"pure":"global",copyright:"\xA9 2014-2025 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.41.0/LICENSE",source:"https://github.com/zloirock/core-js"})});var ZS=w((sPe,wM)=>{"use strict";m();T();N();var FM=sE();wM.exports=function(e,t){return FM[e]||(FM[e]=t||{})}});var CM=w((lPe,LM)=>{"use strict";m();T();N();var mse=jS(),Nse=Object;LM.exports=function(e){return Nse(mse(e))}});var Nu=w((mPe,BM)=>{"use strict";m();T();N();var Tse=mi(),Ese=CM(),hse=Tse({}.hasOwnProperty);BM.exports=Object.hasOwn||function(t,n){return hse(Ese(t),n)}});var eO=w((hPe,UM)=>{"use strict";m();T();N();var yse=mi(),Ise=0,gse=Math.random(),_se=yse(1 .toString);UM.exports=function(e){return"Symbol("+(e===void 0?"":e)+")_"+_se(++Ise+gse,36)}});var xM=w((_Pe,MM)=>{"use strict";m();T();N();var vse=Ki(),Sse=ZS(),kM=Nu(),Ose=eO(),Dse=QS(),bse=YS(),Kl=vse.Symbol,tO=Sse("wks"),Ase=bse?Kl.for||Kl:Kl&&Kl.withoutSetter||Ose;MM.exports=function(e){return kM(tO,e)||(tO[e]=Dse&&kM(Kl,e)?Kl[e]:Ase("Symbol."+e)),tO[e]}});var KM=w((DPe,jM)=>{"use strict";m();T();N();var Rse=fc(),qM=jl(),VM=JS(),Pse=HS(),Fse=vM(),wse=xM(),Lse=TypeError,Cse=wse("toPrimitive");jM.exports=function(e,t){if(!qM(e)||VM(e))return e;var n=Pse(e,Cse),r;if(n){if(t===void 0&&(t="default"),r=Rse(n,e,t),!qM(r)||VM(r))return r;throw new Lse("Can't convert object to primitive value")}return t===void 0&&(t="number"),Fse(e,t)}});var nO=w((PPe,GM)=>{"use strict";m();T();N();var Bse=KM(),Use=JS();GM.exports=function(e){var t=Bse(e,"string");return Use(t)?t:t+""}});var YM=w((CPe,QM)=>{"use strict";m();T();N();var kse=Ki(),$M=jl(),rO=kse.document,Mse=$M(rO)&&$M(rO.createElement);QM.exports=function(e){return Mse?rO.createElement(e):{}}});var iO=w((MPe,JM)=>{"use strict";m();T();N();var xse=mu(),qse=Is(),Vse=YM();JM.exports=!xse&&!qse(function(){return Object.defineProperty(Vse("div"),"a",{get:function(){return 7}}).a!==7})});var aO=w(zM=>{"use strict";m();T();N();var jse=mu(),Kse=fc(),Gse=xk(),$se=MS(),Qse=tE(),Yse=nO(),Jse=Nu(),Hse=iO(),HM=Object.getOwnPropertyDescriptor;zM.f=jse?HM:function(t,n){if(t=Qse(t),n=Yse(n),Hse)try{return HM(t,n)}catch(r){}if(Jse(t,n))return $se(!Kse(Gse.f,t,n),t[n])}});var XM=w((QPe,WM)=>{"use strict";m();T();N();var zse=mu(),Wse=Is();WM.exports=zse&&Wse(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!==42})});var xp=w((zPe,ZM)=>{"use strict";m();T();N();var Xse=jl(),Zse=String,eoe=TypeError;ZM.exports=function(e){if(Xse(e))return e;throw new eoe(Zse(e)+" is not an object")}});var uE=w(tx=>{"use strict";m();T();N();var toe=mu(),noe=iO(),roe=XM(),oE=xp(),ex=nO(),ioe=TypeError,sO=Object.defineProperty,aoe=Object.getOwnPropertyDescriptor,oO="enumerable",uO="configurable",cO="writable";tx.f=toe?roe?function(t,n,r){if(oE(t),n=ex(n),oE(r),typeof t=="function"&&n==="prototype"&&"value"in r&&cO in r&&!r[cO]){var i=aoe(t,n);i&&i[cO]&&(t[n]=r.value,r={configurable:uO in r?r[uO]:i[uO],enumerable:oO in r?r[oO]:i[oO],writable:!1})}return sO(t,n,r)}:sO:function(t,n,r){if(oE(t),n=ex(n),oE(r),noe)try{return sO(t,n,r)}catch(i){}if("get"in r||"set"in r)throw new ioe("Accessors not supported");return"value"in r&&(t[n]=r.value),t}});var lO=w((iFe,nx)=>{"use strict";m();T();N();var soe=mu(),ooe=uE(),uoe=MS();nx.exports=soe?function(e,t,n){return ooe.f(e,t,uoe(1,n))}:function(e,t,n){return e[t]=n,e}});var ax=w((uFe,ix)=>{"use strict";m();T();N();var dO=mu(),coe=Nu(),rx=Function.prototype,loe=dO&&Object.getOwnPropertyDescriptor,pO=coe(rx,"name"),doe=pO&&function(){}.name==="something",poe=pO&&(!dO||dO&&loe(rx,"name").configurable);ix.exports={EXISTS:pO,PROPER:doe,CONFIGURABLE:poe}});var ox=w((pFe,sx)=>{"use strict";m();T();N();var foe=mi(),moe=ua(),fO=sE(),Noe=foe(Function.toString);moe(fO.inspectSource)||(fO.inspectSource=function(e){return Noe(e)});sx.exports=fO.inspectSource});var lx=w((TFe,cx)=>{"use strict";m();T();N();var Toe=Ki(),Eoe=ua(),ux=Toe.WeakMap;cx.exports=Eoe(ux)&&/native code/.test(String(ux))});var fx=w((IFe,px)=>{"use strict";m();T();N();var hoe=ZS(),yoe=eO(),dx=hoe("keys");px.exports=function(e){return dx[e]||(dx[e]=yoe(e))}});var mO=w((SFe,mx)=>{"use strict";m();T();N();mx.exports={}});var hx=w((AFe,Ex)=>{"use strict";m();T();N();var Ioe=lx(),Tx=Ki(),goe=jl(),_oe=lO(),NO=Nu(),TO=sE(),voe=fx(),Soe=mO(),Nx="Object already initialized",EO=Tx.TypeError,Ooe=Tx.WeakMap,cE,qp,lE,Doe=function(e){return lE(e)?qp(e):cE(e,{})},boe=function(e){return function(t){var n;if(!goe(t)||(n=qp(t)).type!==e)throw new EO("Incompatible receiver, "+e+" required");return n}};Ioe||TO.state?(la=TO.state||(TO.state=new Ooe),la.get=la.get,la.has=la.has,la.set=la.set,cE=function(e,t){if(la.has(e))throw new EO(Nx);return t.facade=e,la.set(e,t),t},qp=function(e){return la.get(e)||{}},lE=function(e){return la.has(e)}):(mc=voe("state"),Soe[mc]=!0,cE=function(e,t){if(NO(e,mc))throw new EO(Nx);return t.facade=e,_oe(e,mc,t),t},qp=function(e){return NO(e,mc)?e[mc]:{}},lE=function(e){return NO(e,mc)});var la,mc;Ex.exports={set:cE,get:qp,has:lE,enforce:Doe,getterFor:boe}});var _x=w((wFe,gx)=>{"use strict";m();T();N();var yO=mi(),Aoe=Is(),Roe=ua(),dE=Nu(),hO=mu(),Poe=ax().CONFIGURABLE,Foe=ox(),Ix=hx(),woe=Ix.enforce,Loe=Ix.get,yx=String,pE=Object.defineProperty,Coe=yO("".slice),Boe=yO("".replace),Uoe=yO([].join),koe=hO&&!Aoe(function(){return pE(function(){},"length",{value:8}).length!==8}),Moe=String(String).split("String"),xoe=gx.exports=function(e,t,n){Coe(yx(t),0,7)==="Symbol("&&(t="["+Boe(yx(t),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),n&&n.getter&&(t="get "+t),n&&n.setter&&(t="set "+t),(!dE(e,"name")||Poe&&e.name!==t)&&(hO?pE(e,"name",{value:t,configurable:!0}):e.name=t),koe&&n&&dE(n,"arity")&&e.length!==n.arity&&pE(e,"length",{value:n.arity});try{n&&dE(n,"constructor")&&n.constructor?hO&&pE(e,"prototype",{writable:!1}):e.prototype&&(e.prototype=void 0)}catch(i){}var r=woe(e);return dE(r,"source")||(r.source=Uoe(Moe,typeof t=="string"?t:"")),e};Function.prototype.toString=xoe(function(){return Roe(this)&&Loe(this).source||Foe(this)},"toString")});var Sx=w((UFe,vx)=>{"use strict";m();T();N();var qoe=ua(),Voe=uE(),joe=_x(),Koe=aE();vx.exports=function(e,t,n,r){r||(r={});var i=r.enumerable,a=r.name!==void 0?r.name:t;if(qoe(n)&&joe(n,a,r),r.global)i?e[t]=n:Koe(t,n);else{try{r.unsafe?e[t]&&(i=!0):delete e[t]}catch(o){}i?e[t]=n:Voe.f(e,t,{value:n,enumerable:!1,configurable:!r.nonConfigurable,writable:!r.nonWritable})}return e}});var Dx=w((qFe,Ox)=>{"use strict";m();T();N();var Goe=Math.ceil,$oe=Math.floor;Ox.exports=Math.trunc||function(t){var n=+t;return(n>0?$oe:Goe)(n)}});var fE=w((GFe,bx)=>{"use strict";m();T();N();var Qoe=Dx();bx.exports=function(e){var t=+e;return t!==t||t===0?0:Qoe(t)}});var Rx=w((JFe,Ax)=>{"use strict";m();T();N();var Yoe=fE(),Joe=Math.max,Hoe=Math.min;Ax.exports=function(e,t){var n=Yoe(e);return n<0?Joe(n+t,0):Hoe(n,t)}});var Fx=w((XFe,Px)=>{"use strict";m();T();N();var zoe=fE(),Woe=Math.min;Px.exports=function(e){var t=zoe(e);return t>0?Woe(t,9007199254740991):0}});var Lx=w((nwe,wx)=>{"use strict";m();T();N();var Xoe=Fx();wx.exports=function(e){return Xoe(e.length)}});var Ux=w((swe,Bx)=>{"use strict";m();T();N();var Zoe=tE(),eue=Rx(),tue=Lx(),Cx=function(e){return function(t,n,r){var i=Zoe(t),a=tue(i);if(a===0)return!e&&-1;var o=eue(r,a),c;if(e&&n!==n){for(;a>o;)if(c=i[o++],c!==c)return!0}else for(;a>o;o++)if((e||o in i)&&i[o]===n)return e||o||0;return!e&&-1}};Bx.exports={includes:Cx(!0),indexOf:Cx(!1)}});var xx=w((lwe,Mx)=>{"use strict";m();T();N();var nue=mi(),IO=Nu(),rue=tE(),iue=Ux().indexOf,aue=mO(),kx=nue([].push);Mx.exports=function(e,t){var n=rue(e),r=0,i=[],a;for(a in n)!IO(aue,a)&&IO(n,a)&&kx(i,a);for(;t.length>r;)IO(n,a=t[r++])&&(~iue(i,a)||kx(i,a));return i}});var Vx=w((mwe,qx)=>{"use strict";m();T();N();qx.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]});var Kx=w(jx=>{"use strict";m();T();N();var sue=xx(),oue=Vx(),uue=oue.concat("length","prototype");jx.f=Object.getOwnPropertyNames||function(t){return sue(t,uue)}});var $x=w(Gx=>{"use strict";m();T();N();Gx.f=Object.getOwnPropertySymbols});var Yx=w((Dwe,Qx)=>{"use strict";m();T();N();var cue=nE(),lue=mi(),due=Kx(),pue=$x(),fue=xp(),mue=lue([].concat);Qx.exports=cue("Reflect","ownKeys")||function(t){var n=due.f(fue(t)),r=pue.f;return r?mue(n,r(t)):n}});var zx=w((Pwe,Hx)=>{"use strict";m();T();N();var Jx=Nu(),Nue=Yx(),Tue=aO(),Eue=uE();Hx.exports=function(e,t,n){for(var r=Nue(t),i=Eue.f,a=Tue.f,o=0;o{"use strict";m();T();N();var hue=Is(),yue=ua(),Iue=/#|\.prototype\./,Vp=function(e,t){var n=_ue[gue(e)];return n===Sue?!0:n===vue?!1:yue(t)?hue(t):!!t},gue=Vp.normalize=function(e){return String(e).replace(Iue,".").toLowerCase()},_ue=Vp.data={},vue=Vp.NATIVE="N",Sue=Vp.POLYFILL="P";Wx.exports=Vp});var gO=w((Mwe,Zx)=>{"use strict";m();T();N();var mE=Ki(),Oue=aO().f,Due=lO(),bue=Sx(),Aue=aE(),Rue=zx(),Pue=Xx();Zx.exports=function(e,t){var n=e.target,r=e.global,i=e.stat,a,o,c,l,p,f;if(r?o=mE:i?o=mE[n]||Aue(n,{}):o=mE[n]&&mE[n].prototype,o)for(c in t){if(p=t[c],e.dontCallGetSet?(f=Oue(o,c),l=f&&f.value):l=o[c],a=Pue(r?c:n+(i?".":"#")+c,e.forced),!a&&l!==void 0){if(typeof p==typeof l)continue;Rue(p,l)}(e.sham||l&&l.sham)&&Due(p,"sham",!0),bue(o,c,p,e)}}});var jp=w((jwe,eq)=>{"use strict";m();T();N();var _O=mi(),NE=Set.prototype;eq.exports={Set,add:_O(NE.add),has:_O(NE.has),remove:_O(NE.delete),proto:NE}});var vO=w((Qwe,tq)=>{"use strict";m();T();N();var Fue=jp().has;tq.exports=function(e){return Fue(e),e}});var rq=w((zwe,nq)=>{"use strict";m();T();N();var wue=mi(),Lue=iE();nq.exports=function(e,t,n){try{return wue(Lue(Object.getOwnPropertyDescriptor(e,t)[n]))}catch(r){}}});var SO=w((eLe,iq)=>{"use strict";m();T();N();var Cue=rq(),Bue=jp();iq.exports=Cue(Bue.proto,"size","get")||function(e){return e.size}});var OO=w((iLe,aq)=>{"use strict";m();T();N();var Uue=fc();aq.exports=function(e,t,n){for(var r=n?e:e.iterator,i=e.next,a,o;!(a=Uue(i,r)).done;)if(o=t(a.value),o!==void 0)return o}});var dq=w((uLe,lq)=>{"use strict";m();T();N();var sq=mi(),kue=OO(),oq=jp(),Mue=oq.Set,uq=oq.proto,xue=sq(uq.forEach),cq=sq(uq.keys),que=cq(new Mue).next;lq.exports=function(e,t,n){return n?kue({iterator:cq(e),next:que},t):xue(e,t)}});var fq=w((pLe,pq)=>{"use strict";m();T();N();pq.exports=function(e){return{iterator:e,next:e.next,done:!1}}});var DO=w((TLe,yq)=>{"use strict";m();T();N();var mq=iE(),Eq=xp(),Nq=fc(),Vue=fE(),jue=fq(),Tq="Invalid size",Kue=RangeError,Gue=TypeError,$ue=Math.max,hq=function(e,t){this.set=e,this.size=$ue(t,0),this.has=mq(e.has),this.keys=mq(e.keys)};hq.prototype={getIterator:function(){return jue(Eq(Nq(this.keys,this.set)))},includes:function(e){return Nq(this.has,this.set,e)}};yq.exports=function(e){Eq(e);var t=+e.size;if(t!==t)throw new Gue(Tq);var n=Vue(t);if(n<0)throw new Kue(Tq);return new hq(e,n)}});var gq=w((ILe,Iq)=>{"use strict";m();T();N();var Que=vO(),Yue=SO(),Jue=dq(),Hue=DO();Iq.exports=function(t){var n=Que(this),r=Hue(t);return Yue(n)>r.size?!1:Jue(n,function(i){if(!r.includes(i))return!1},!0)!==!1}});var bO=w((SLe,Sq)=>{"use strict";m();T();N();var zue=nE(),_q=function(e){return{size:e,has:function(){return!1},keys:function(){return{next:function(){return{done:!0}}}}}},vq=function(e){return{size:e,has:function(){return!0},keys:function(){throw new Error("e")}}};Sq.exports=function(e,t){var n=zue("Set");try{new n()[e](_q(0));try{return new n()[e](_q(-1)),!1}catch(i){if(!t)return!0;try{return new n()[e](vq(-1/0)),!1}catch(a){var r=new n;return r.add(1),r.add(2),t(r[e](vq(1/0)))}}}catch(i){return!1}}});var Oq=w(()=>{"use strict";m();T();N();var Wue=gO(),Xue=gq(),Zue=bO(),ece=!Zue("isSubsetOf",function(e){return e});Wue({target:"Set",proto:!0,real:!0,forced:ece},{isSubsetOf:Xue})});var Dq=w(()=>{"use strict";m();T();N();Oq()});var Rq=w((MLe,Aq)=>{"use strict";m();T();N();var tce=fc(),bq=xp(),nce=HS();Aq.exports=function(e,t,n){var r,i;bq(e);try{if(r=nce(e,"return"),!r){if(t==="throw")throw n;return n}r=tce(r,e)}catch(a){i=!0,r=a}if(t==="throw")throw n;if(i)throw r;return bq(r),n}});var Fq=w((jLe,Pq)=>{"use strict";m();T();N();var rce=vO(),ice=jp().has,ace=SO(),sce=DO(),oce=OO(),uce=Rq();Pq.exports=function(t){var n=rce(this),r=sce(t);if(ace(n){"use strict";m();T();N();var cce=gO(),lce=Fq(),dce=bO(),pce=!dce("isSupersetOf",function(e){return!e});cce({target:"Set",proto:!0,real:!0,forced:pce},{isSupersetOf:lce})});var Lq=w(()=>{"use strict";m();T();N();wq()});var Kp=w(Cn=>{"use strict";m();T();N();Object.defineProperty(Cn,"__esModule",{value:!0});Cn.subtractSet=fce;Cn.mapToArrayOfValues=mce;Cn.kindToConvertedTypeString=Nce;Cn.fieldDatasToSimpleFieldDatas=Tce;Cn.isNodeLeaf=Ece;Cn.newEntityInterfaceFederationData=hce;Cn.upsertEntityInterfaceFederationData=yce;Cn.upsertEntityData=gce;Cn.updateEntityData=Cq;Cn.newFieldAuthorizationData=_ce;Cn.newAuthorizationData=vce;Cn.addScopes=AO;Cn.mergeRequiredScopesByAND=hE;Cn.mergeRequiredScopesByOR=RO;Cn.upsertFieldAuthorizationData=Bq;Cn.upsertAuthorizationData=Dce;Cn.upsertAuthorizationConfiguration=bce;Cn.isNodeKindObject=Ace;Cn.isInterfaceDefinitionData=Rce;Cn.isObjectDefinitionData=Pce;var en=Ae(),Zr=ur(),TE=Jr(),EE=Es();Dq();Lq();function fce(e,t){for(let n of e)t.delete(n)}function mce(e){let t=[];for(let n of e.values())t.push(n);return t}function Nce(e){switch(e){case en.Kind.BOOLEAN:return Zr.BOOLEAN_SCALAR;case en.Kind.ENUM:case en.Kind.ENUM_TYPE_DEFINITION:case en.Kind.ENUM_TYPE_EXTENSION:return Zr.ENUM;case en.Kind.ENUM_VALUE_DEFINITION:return Zr.ENUM_VALUE;case en.Kind.FIELD_DEFINITION:return Zr.FIELD;case en.Kind.FLOAT:return Zr.FLOAT_SCALAR;case en.Kind.INPUT_OBJECT_TYPE_DEFINITION:case en.Kind.INPUT_OBJECT_TYPE_EXTENSION:return Zr.INPUT_OBJECT;case en.Kind.INPUT_VALUE_DEFINITION:return Zr.INPUT_VALUE;case en.Kind.INT:return Zr.INT_SCALAR;case en.Kind.INTERFACE_TYPE_DEFINITION:case en.Kind.INTERFACE_TYPE_EXTENSION:return Zr.INTERFACE;case en.Kind.NULL:return Zr.NULL;case en.Kind.OBJECT:case en.Kind.OBJECT_TYPE_DEFINITION:case en.Kind.OBJECT_TYPE_EXTENSION:return Zr.OBJECT;case en.Kind.STRING:return Zr.STRING_SCALAR;case en.Kind.SCALAR_TYPE_DEFINITION:case en.Kind.SCALAR_TYPE_EXTENSION:return Zr.SCALAR;case en.Kind.UNION_TYPE_DEFINITION:case en.Kind.UNION_TYPE_EXTENSION:return Zr.UNION;default:return e}}function Tce(e){let t=[];for(let{name:n,namedTypeName:r}of e)t.push({name:n,namedTypeName:r});return t}function Ece(e){if(!e)return!0;switch(e){case en.Kind.OBJECT_TYPE_DEFINITION:case en.Kind.INTERFACE_TYPE_DEFINITION:case en.Kind.UNION_TYPE_DEFINITION:return!1;default:return!0}}function hce(e,t){return{concreteTypeNames:new Set(e.concreteTypeNames),fieldDatasBySubgraphName:new Map([[t,e.fieldDatas]]),interfaceFieldNames:new Set(e.interfaceFieldNames),interfaceObjectFieldNames:new Set(e.interfaceObjectFieldNames),interfaceObjectSubgraphs:new Set(e.isInterfaceObject?[t]:[]),subgraphDataByTypeName:new Map([[t,e]]),typeName:e.typeName}}function yce(e,t,n){(0,TE.addIterableValuesToSet)(t.concreteTypeNames,e.concreteTypeNames),e.subgraphDataByTypeName.set(n,t),e.fieldDatasBySubgraphName.set(n,t.fieldDatas),(0,TE.addIterableValuesToSet)(t.interfaceFieldNames,e.interfaceFieldNames),(0,TE.addIterableValuesToSet)(t.interfaceObjectFieldNames,e.interfaceObjectFieldNames),t.isInterfaceObject&&e.interfaceObjectSubgraphs.add(n)}function Ice({keyFieldSetDataByFieldSet:e,subgraphName:t,typeName:n}){let r=new Map([[t,e]]),i=new Map;for(let[a,{documentNode:o,isUnresolvable:c}]of e)c||i.set(a,o);return{keyFieldSetDatasBySubgraphName:r,documentNodeByKeyFieldSet:i,keyFieldSets:new Set,subgraphNames:new Set([t]),typeName:n}}function gce({entityDataByTypeName:e,keyFieldSetDataByFieldSet:t,subgraphName:n,typeName:r}){let i=e.get(r);i?Cq({entityData:i,keyFieldSetDataByFieldSet:t,subgraphName:n}):e.set(r,Ice({keyFieldSetDataByFieldSet:t,subgraphName:n,typeName:r}))}function Cq({entityData:e,keyFieldSetDataByFieldSet:t,subgraphName:n}){e.subgraphNames.add(n);let r=e.keyFieldSetDatasBySubgraphName.get(n);if(!r){e.keyFieldSetDatasBySubgraphName.set(n,t);for(let[i,{documentNode:a,isUnresolvable:o}]of t)o||e.documentNodeByKeyFieldSet.set(i,a);return}for(let[i,a]of t){a.isUnresolvable||e.documentNodeByKeyFieldSet.set(i,a.documentNode);let o=r.get(i);if(o){o.isUnresolvable||(o.isUnresolvable=a.isUnresolvable);continue}r.set(i,a)}}function _ce(e){return{fieldName:e,inheritedData:{requiredScopes:[],requiredScopesByOR:[],requiresAuthentication:!1},originalData:{requiredScopes:[],requiresAuthentication:!1}}}function vce(e){return{fieldAuthDataByFieldName:new Map,requiredScopes:[],requiredScopesByOR:[],requiresAuthentication:!1,typeName:e}}function AO(e,t){for(let n=e.length-1;n>-1;n--){if(e[n].isSubsetOf(t))return;e[n].isSupersetOf(t)&&e.splice(n,1)}e.push(t)}function hE(e,t){if(e.length<1||t.length<1){for(let r of t)e.push(new Set(r));return e}let n=[];for(let r of t)for(let i of e){let a=(0,TE.addSets)(r,i);AO(n,a)}return n}function RO(e,t){for(let n of t)AO(e,n);return e.length<=EE.MAX_OR_SCOPES}function Bq(e,t){var i,a;let n=t.fieldName,r=e.get(n);return r?((i=r.inheritedData).requiresAuthentication||(i.requiresAuthentication=t.inheritedData.requiresAuthentication),(a=r.originalData).requiresAuthentication||(a.requiresAuthentication=t.originalData.requiresAuthentication),!RO(r.inheritedData.requiredScopesByOR,t.inheritedData.requiredScopes)||r.inheritedData.requiredScopes.length*t.inheritedData.requiredScopes.length>EE.MAX_OR_SCOPES||r.originalData.requiredScopes.length*t.originalData.requiredScopes.length>EE.MAX_OR_SCOPES?!1:(r.inheritedData.requiredScopes=hE(r.inheritedData.requiredScopes,t.inheritedData.requiredScopes),r.originalData.requiredScopes=hE(r.originalData.requiredScopes,t.originalData.requiredScopes),!0)):(e.set(n,Uq(t)),!0)}function Sce(e){let t=new Map;for(let[n,r]of e)t.set(n,Uq(r));return t}function Uq(e){return{fieldName:e.fieldName,inheritedData:{requiredScopes:[...e.inheritedData.requiredScopes],requiredScopesByOR:[...e.inheritedData.requiredScopes],requiresAuthentication:e.inheritedData.requiresAuthentication},originalData:{requiredScopes:[...e.originalData.requiredScopes],requiresAuthentication:e.originalData.requiresAuthentication}}}function Oce(e){return{fieldAuthDataByFieldName:Sce(e.fieldAuthDataByFieldName),requiredScopes:[...e.requiredScopes],requiredScopesByOR:[...e.requiredScopes],requiresAuthentication:e.requiresAuthentication,typeName:e.typeName}}function Dce(e,t,n){let r=e.get(t.typeName);if(!r){e.set(t.typeName,Oce(t));return}r.requiresAuthentication||(r.requiresAuthentication=t.requiresAuthentication),!RO(r.requiredScopesByOR,t.requiredScopes)||r.requiredScopes.length*t.requiredScopes.length>EE.MAX_OR_SCOPES?n.add(t.typeName):r.requiredScopes=hE(r.requiredScopes,t.requiredScopes);for(let[i,a]of t.fieldAuthDataByFieldName)Bq(r.fieldAuthDataByFieldName,a)||n.add(`${t.typeName}.${i}`)}function bce(e,t){let n=t.typeName;for(let[r,i]of t.fieldAuthDataByFieldName){let a=`${n}.${r}`,o=e.get(a);o?(o.requiresAuthentication=i.inheritedData.requiresAuthentication,o.requiredScopes=i.inheritedData.requiredScopes.map(c=>[...c]),o.requiredScopesByOR=i.inheritedData.requiredScopesByOR.map(c=>[...c])):e.set(a,{argumentNames:[],typeName:n,fieldName:r,requiresAuthentication:i.inheritedData.requiresAuthentication,requiredScopes:i.inheritedData.requiredScopes.map(c=>[...c]),requiredScopesByOR:i.inheritedData.requiredScopesByOR.map(c=>[...c])})}}function Ace(e){return e===en.Kind.OBJECT_TYPE_DEFINITION||e===en.Kind.OBJECT_TYPE_EXTENSION}function Rce(e){return e.kind===en.Kind.INTERFACE_TYPE_DEFINITION}function Pce(e){return e?e.kind===en.Kind.OBJECT_TYPE_DEFINITION:!1}});var PO=w(Je=>{"use strict";m();T();N();Object.defineProperty(Je,"__esModule",{value:!0});Je.TAG_DEFINITION_DATA=Je.SUBSCRIPTION_FILTER_DEFINITION_DATA=Je.SHAREABLE_DEFINITION_DATA=Je.SPECIFIED_BY_DEFINITION_DATA=Je.REQUIRES_SCOPES_DEFINITION_DATA=Je.REQUIRES_DEFINITION_DATA=Je.PROVIDES_DEFINITION_DATA=Je.LINK_DEFINITION_DATA=Je.KEY_DEFINITION_DATA=Je.OVERRIDE_DEFINITION_DATA=Je.REDIS_SUBSCRIBE_DEFINITION_DATA=Je.REDIS_PUBLISH_DEFINITION_DATA=Je.NATS_SUBSCRIBE_DEFINITION_DATA=Je.NATS_REQUEST_DEFINITION_DATA=Je.NATS_PUBLISH_DEFINITION_DATA=Je.KAFKA_SUBSCRIBE_DEFINITION_DATA=Je.KAFKA_PUBLISH_DEFINITION_DATA=Je.INTERFACE_OBJECT_DEFINITION_DATA=Je.INACCESSIBLE_DEFINITION_DATA=Je.EXTERNAL_DEFINITION_DATA=Je.EXTENDS_DEFINITION_DATA=Je.DEPRECATED_DEFINITION_DATA=Je.CONFIGURE_CHILD_DESCRIPTIONS_DEFINITION_DATA=Je.CONFIGURE_DESCRIPTION_DEFINITION_DATA=Je.COMPOSE_DIRECTIVE_DEFINITION_DATA=Je.AUTHENTICATED_DEFINITION_DATA=void 0;var it=Es(),da=Yr(),ln=Ae(),q=ur();Je.AUTHENTICATED_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([]),isRepeatable:!1,locations:new Set([q.ENUM_UPPER,q.FIELD_DEFINITION_UPPER,q.INTERFACE_UPPER,q.OBJECT_UPPER,q.SCALAR_UPPER]),name:q.AUTHENTICATED,node:it.AUTHENTICATED_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set};Je.COMPOSE_DIRECTIVE_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.NAME,{name:q.NAME,typeNode:it.REQUIRED_STRING_TYPE_NODE}]]),isRepeatable:!0,locations:new Set([q.SCHEMA_UPPER]),name:q.COMPOSE_DIRECTIVE,node:it.COMPOSE_DIRECTIVE_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set([q.NAME])};Je.CONFIGURE_DESCRIPTION_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.PROPAGATE,{name:q.PROPAGATE,typeNode:{kind:ln.Kind.NON_NULL_TYPE,type:(0,da.stringToNamedTypeNode)(q.BOOLEAN_SCALAR)},defaultValue:{kind:ln.Kind.BOOLEAN,value:!0}}],[q.DESCRIPTION_OVERRIDE,{name:q.DESCRIPTION_OVERRIDE,typeNode:(0,da.stringToNamedTypeNode)(q.STRING_SCALAR)}]]),isRepeatable:!1,locations:new Set([q.ARGUMENT_DEFINITION_UPPER,q.ENUM_UPPER,q.ENUM_VALUE_UPPER,q.FIELD_DEFINITION_UPPER,q.INTERFACE_UPPER,q.INPUT_OBJECT_UPPER,q.INPUT_FIELD_DEFINITION_UPPER,q.OBJECT_UPPER,q.SCALAR_UPPER,q.SCHEMA_UPPER,q.UNION_UPPER]),name:q.CONFIGURE_DESCRIPTION,node:it.CONFIGURE_DESCRIPTION_DEFINITION,optionalArgumentNames:new Set([q.PROPAGATE,q.DESCRIPTION_OVERRIDE]),requiredArgumentNames:new Set};Je.CONFIGURE_CHILD_DESCRIPTIONS_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.PROPAGATE,{name:q.PROPAGATE,typeNode:{kind:ln.Kind.NON_NULL_TYPE,type:(0,da.stringToNamedTypeNode)(q.BOOLEAN_SCALAR)},defaultValue:{kind:ln.Kind.BOOLEAN,value:!0}}]]),isRepeatable:!1,locations:new Set([q.ENUM_UPPER,q.INPUT_OBJECT_UPPER,q.INTERFACE_UPPER,q.OBJECT_UPPER]),name:q.CONFIGURE_CHILD_DESCRIPTIONS,node:it.CONFIGURE_CHILD_DESCRIPTIONS_DEFINITION,optionalArgumentNames:new Set([q.PROPAGATE]),requiredArgumentNames:new Set};Je.DEPRECATED_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.REASON,{name:q.REASON,typeNode:(0,da.stringToNamedTypeNode)(q.STRING_SCALAR),defaultValue:{kind:ln.Kind.STRING,value:ln.DEFAULT_DEPRECATION_REASON}}]]),isRepeatable:!1,locations:new Set([q.ARGUMENT_DEFINITION_UPPER,q.ENUM_VALUE_UPPER,q.FIELD_DEFINITION_UPPER,q.INPUT_FIELD_DEFINITION_UPPER]),name:q.DEPRECATED,node:it.DEPRECATED_DEFINITION,optionalArgumentNames:new Set([q.REASON]),requiredArgumentNames:new Set};Je.EXTENDS_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map,isRepeatable:!1,locations:new Set([q.INTERFACE_UPPER,q.OBJECT_UPPER]),name:q.EXTENDS,node:it.EXTENDS_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set};Je.EXTERNAL_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map,isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER,q.OBJECT_UPPER]),name:q.EXTERNAL,node:it.EXTERNAL_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set};Je.INACCESSIBLE_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map,isRepeatable:!1,locations:new Set([q.ARGUMENT_DEFINITION_UPPER,q.ENUM_UPPER,q.ENUM_VALUE_UPPER,q.FIELD_DEFINITION_UPPER,q.INPUT_FIELD_DEFINITION_UPPER,q.INPUT_OBJECT_UPPER,q.INTERFACE_UPPER,q.OBJECT_UPPER,q.SCALAR_UPPER,q.UNION_UPPER]),name:q.INACCESSIBLE,node:it.INACCESSIBLE_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set};Je.INTERFACE_OBJECT_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map,isRepeatable:!1,locations:new Set([q.OBJECT_UPPER]),name:q.INTERFACE_OBJECT,node:it.INTERFACE_OBJECT_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set};Je.KAFKA_PUBLISH_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.TOPIC,{name:q.TOPIC,typeNode:it.REQUIRED_STRING_TYPE_NODE}],[q.PROVIDER_ID,{name:q.PROVIDER_ID,typeNode:it.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ln.Kind.STRING,value:q.DEFAULT_EDFS_PROVIDER_ID}}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.EDFS_KAFKA_PUBLISH,node:it.EDFS_KAFKA_PUBLISH_DEFINITION,optionalArgumentNames:new Set([q.PROVIDER_ID]),requiredArgumentNames:new Set([q.TOPIC])};Je.KAFKA_SUBSCRIBE_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.TOPICS,{name:q.TOPICS,typeNode:{kind:ln.Kind.NON_NULL_TYPE,type:{kind:ln.Kind.LIST_TYPE,type:it.REQUIRED_STRING_TYPE_NODE}}}],[q.PROVIDER_ID,{name:q.PROVIDER_ID,typeNode:it.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ln.Kind.STRING,value:q.DEFAULT_EDFS_PROVIDER_ID}}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.EDFS_KAFKA_SUBSCRIBE,node:it.EDFS_KAFKA_SUBSCRIBE_DEFINITION,optionalArgumentNames:new Set([q.PROVIDER_ID]),requiredArgumentNames:new Set([q.TOPICS])};Je.NATS_PUBLISH_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.SUBJECT,{name:q.SUBJECT,typeNode:it.REQUIRED_STRING_TYPE_NODE}],[q.PROVIDER_ID,{name:q.PROVIDER_ID,typeNode:it.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ln.Kind.STRING,value:q.DEFAULT_EDFS_PROVIDER_ID}}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.EDFS_NATS_PUBLISH,node:it.EDFS_NATS_PUBLISH_DEFINITION,optionalArgumentNames:new Set([q.PROVIDER_ID]),requiredArgumentNames:new Set([q.SUBJECT])};Je.NATS_REQUEST_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.SUBJECT,{name:q.SUBJECT,typeNode:it.REQUIRED_STRING_TYPE_NODE}],[q.PROVIDER_ID,{name:q.PROVIDER_ID,typeNode:it.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ln.Kind.STRING,value:q.DEFAULT_EDFS_PROVIDER_ID}}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.EDFS_NATS_REQUEST,node:it.EDFS_NATS_REQUEST_DEFINITION,optionalArgumentNames:new Set([q.PROVIDER_ID]),requiredArgumentNames:new Set([q.SUBJECT])};Je.NATS_SUBSCRIBE_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.SUBJECTS,{name:q.SUBJECTS,typeNode:{kind:ln.Kind.NON_NULL_TYPE,type:{kind:ln.Kind.LIST_TYPE,type:it.REQUIRED_STRING_TYPE_NODE}}}],[q.PROVIDER_ID,{name:q.PROVIDER_ID,typeNode:it.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ln.Kind.STRING,value:q.DEFAULT_EDFS_PROVIDER_ID}}],[q.STREAM_CONFIGURATION,{name:q.STREAM_CONFIGURATION,typeNode:(0,da.stringToNamedTypeNode)(q.EDFS_NATS_STREAM_CONFIGURATION)}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.EDFS_NATS_SUBSCRIBE,node:it.EDFS_NATS_SUBSCRIBE_DEFINITION,optionalArgumentNames:new Set([q.PROVIDER_ID]),requiredArgumentNames:new Set([q.SUBJECTS])};Je.REDIS_PUBLISH_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.CHANNEL,{name:q.CHANNEL,typeNode:it.REQUIRED_STRING_TYPE_NODE}],[q.PROVIDER_ID,{name:q.PROVIDER_ID,typeNode:it.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ln.Kind.STRING,value:q.DEFAULT_EDFS_PROVIDER_ID}}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.EDFS_REDIS_PUBLISH,node:it.EDFS_REDIS_PUBLISH_DEFINITION,optionalArgumentNames:new Set([q.PROVIDER_ID]),requiredArgumentNames:new Set([q.CHANNEL])};Je.REDIS_SUBSCRIBE_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.CHANNELS,{name:q.CHANNELS,typeNode:{kind:ln.Kind.NON_NULL_TYPE,type:{kind:ln.Kind.LIST_TYPE,type:it.REQUIRED_STRING_TYPE_NODE}}}],[q.PROVIDER_ID,{name:q.PROVIDER_ID,typeNode:it.REQUIRED_STRING_TYPE_NODE,defaultValue:{kind:ln.Kind.STRING,value:q.DEFAULT_EDFS_PROVIDER_ID}}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.EDFS_REDIS_SUBSCRIBE,node:it.EDFS_REDIS_SUBSCRIBE_DEFINITION,optionalArgumentNames:new Set([q.PROVIDER_ID]),requiredArgumentNames:new Set([q.CHANNELS])};Je.OVERRIDE_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.FROM,{name:q.FROM,typeNode:it.REQUIRED_STRING_TYPE_NODE}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.OVERRIDE,node:it.OVERRIDE_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set([q.FROM])};Je.KEY_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.FIELDS,{name:q.FIELDS,typeNode:it.REQUIRED_FIELDSET_TYPE_NODE}],[q.RESOLVABLE,{name:q.RESOLVABLE,typeNode:(0,da.stringToNamedTypeNode)(q.BOOLEAN_SCALAR),defaultValue:{kind:ln.Kind.BOOLEAN,value:!0}}]]),isRepeatable:!0,locations:new Set([q.INTERFACE_UPPER,q.OBJECT_UPPER]),name:q.KEY,node:it.KEY_DEFINITION,optionalArgumentNames:new Set([q.RESOLVABLE]),requiredArgumentNames:new Set([q.FIELDS])};Je.LINK_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.URL_LOWER,{name:q.URL_LOWER,typeNode:it.REQUIRED_STRING_TYPE_NODE}],[q.AS,{name:q.AS,typeNode:(0,da.stringToNamedTypeNode)(q.STRING_SCALAR)}],[q.FOR,{name:q.FOR,typeNode:(0,da.stringToNamedTypeNode)(q.LINK_PURPOSE)}],[q.IMPORT,{name:q.IMPORT,typeNode:{kind:ln.Kind.LIST_TYPE,type:(0,da.stringToNamedTypeNode)(q.LINK_IMPORT)}}]]),isRepeatable:!0,locations:new Set([q.SCHEMA_UPPER]),name:q.LINK,node:it.LINK_DEFINITION,optionalArgumentNames:new Set([q.AS,q.FOR,q.IMPORT]),requiredArgumentNames:new Set([q.URL_LOWER])};Je.PROVIDES_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.FIELDS,{name:q.FIELDS,typeNode:it.REQUIRED_FIELDSET_TYPE_NODE}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.PROVIDES,node:it.PROVIDES_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set([q.FIELDS])};Je.REQUIRES_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.FIELDS,{name:q.FIELDS,typeNode:it.REQUIRED_FIELDSET_TYPE_NODE}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.REQUIRES,node:it.REQUIRES_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set([q.FIELDS])};Je.REQUIRES_SCOPES_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.SCOPES,{name:q.SCOPES,typeNode:{kind:ln.Kind.NON_NULL_TYPE,type:{kind:ln.Kind.LIST_TYPE,type:{kind:ln.Kind.NON_NULL_TYPE,type:{kind:ln.Kind.LIST_TYPE,type:{kind:ln.Kind.NON_NULL_TYPE,type:(0,da.stringToNamedTypeNode)(q.SCOPE_SCALAR)}}}}}}]]),isRepeatable:!1,locations:new Set([q.ENUM_UPPER,q.FIELD_DEFINITION_UPPER,q.INTERFACE_UPPER,q.OBJECT_UPPER,q.SCALAR_UPPER]),name:q.REQUIRES_SCOPES,node:it.REQUIRES_SCOPES_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set([q.SCOPES])};Je.SPECIFIED_BY_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.URL_LOWER,{name:q.URL_LOWER,typeNode:it.REQUIRED_STRING_TYPE_NODE}]]),isRepeatable:!1,locations:new Set([q.SCALAR_UPPER]),name:q.SPECIFIED_BY,node:it.SPECIFIED_BY_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set([q.URL_LOWER])};Je.SHAREABLE_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map,isRepeatable:!0,locations:new Set([q.FIELD_DEFINITION_UPPER,q.OBJECT_UPPER]),name:q.SHAREABLE,node:it.SHAREABLE_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set};Je.SUBSCRIPTION_FILTER_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.CONDITION,{name:q.CONDITION,typeNode:{kind:ln.Kind.NON_NULL_TYPE,type:(0,da.stringToNamedTypeNode)(q.SUBSCRIPTION_FILTER_CONDITION)}}]]),isRepeatable:!1,locations:new Set([q.FIELD_DEFINITION_UPPER]),name:q.SUBSCRIPTION_FILTER,node:it.SUBSCRIPTION_FILTER_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set([q.CONDITION])};Je.TAG_DEFINITION_DATA={argumentTypeNodeByArgumentName:new Map([[q.NAME,{name:q.NAME,typeNode:it.REQUIRED_STRING_TYPE_NODE}]]),isRepeatable:!0,locations:new Set([q.ARGUMENT_DEFINITION_UPPER,q.ENUM_UPPER,q.ENUM_VALUE_UPPER,q.FIELD_DEFINITION_UPPER,q.INPUT_FIELD_DEFINITION_UPPER,q.INPUT_OBJECT_UPPER,q.INTERFACE_UPPER,q.OBJECT_UPPER,q.SCALAR_UPPER,q.UNION_UPPER]),name:q.TAG,node:it.TAG_DEFINITION,optionalArgumentNames:new Set,requiredArgumentNames:new Set([q.NAME])}});var Gp=w(pa=>{"use strict";m();T();N();Object.defineProperty(pa,"__esModule",{value:!0});pa.newFieldSetData=Fce;pa.extractFieldSetValue=wce;pa.getNormalizedFieldSet=Lce;pa.getInitialFieldCoordsPath=Cce;pa.validateKeyFieldSets=Bce;pa.getConditionalFieldSetDirectiveName=Uce;pa.isNodeQuery=kce;pa.validateArgumentTemplateReferences=Mce;pa.initializeDirectiveDefinitionDatas=xce;var er=Ae(),kq=Yr(),br=ia(),Mq=Es(),FO=ou(),mn=PO(),Mt=ur(),Tu=Jr();function Fce(){return{provides:new Map,requires:new Map}}function wce(e,t,n){if(!n||n.length>1)return;let r=n[0].arguments;if(!r||r.length!==1)return;let i=r[0];i.name.value!==Mt.FIELDS||i.value.kind!==er.Kind.STRING||t.set(e,i.value.value)}function Lce(e){return(0,er.print)((0,kq.lexicographicallySortDocumentNode)(e)).replaceAll(/\s+/g," ").slice(2,-2)}function Cce(e,t){return e?[t]:[]}function Bce(e,t,n){let r=e.entityInterfaceDataByTypeName.get(t.name),i=t.name,a=[],o=[],c=r?void 0:e.internalGraph.addEntityDataNode(t.name),l=e.internalGraph.addOrUpdateNode(t.name),p=0;for(let[f,{documentNode:y,isUnresolvable:g,rawFieldSet:v}]of n){r&&(r.resolvable||(r.resolvable=!g)),p+=1;let P=[],U=[t],K=[],$=[],ne=new Set,z=-1,Te=!0,pe="";if((0,er.visit)(y,{Argument:{enter(Fe){return P.push((0,br.unexpectedArgumentErrorMessage)(v,`${U[z].name}.${pe}`,Fe.name.value)),er.BREAK}},Field:{enter(Fe){let xe=U[z],et=xe.name;if(Te){let Dn=`${et}.${pe}`,Vt=xe.fieldDataByName.get(pe);if(!Vt)return P.push((0,br.undefinedFieldInFieldSetErrorMessage)(v,Dn,pe)),er.BREAK;let dn=(0,FO.getTypeNodeNamedTypeName)(Vt.node.type),Ar=e.parentDefinitionDataByTypeName.get(dn),Rr=Ar?Ar.kind:er.Kind.SCALAR_TYPE_DEFINITION;return P.push((0,br.invalidSelectionSetErrorMessage)(v,[Dn],dn,(0,Tu.kindToNodeType)(Rr))),er.BREAK}let X=Fe.name.value,ve=`${et}.${X}`;pe=X;let gt=xe.fieldDataByName.get(X);if(!gt)return P.push((0,br.undefinedFieldInFieldSetErrorMessage)(v,et,X)),er.BREAK;if(gt.argumentDataByName.size)return P.push((0,br.argumentsInKeyFieldSetErrorMessage)(v,ve)),er.BREAK;if(K[z].has(X))return P.push((0,br.duplicateFieldInFieldSetErrorMessage)(v,ve)),er.BREAK;(0,Tu.getValueOrDefault)((0,Tu.getValueOrDefault)(e.keyFieldSetsByEntityTypeNameByFieldCoords,ve,()=>new Map),i,()=>new Set).add(f),$.push(X),gt.isShareableBySubgraphName.set(e.subgraphName,!0),K[z].add(X),(0,Tu.getValueOrDefault)(e.keyFieldNamesByParentTypeName,et,()=>new Set).add(X);let zt=(0,FO.getTypeNodeNamedTypeName)(gt.node.type);if(Mq.BASE_SCALARS.has(zt)){ne.add($.join(Mt.PERIOD)),$.pop();return}let Wt=e.parentDefinitionDataByTypeName.get(zt);if(!Wt)return P.push((0,br.unknownTypeInFieldSetErrorMessage)(v,ve,zt)),er.BREAK;if(Wt.kind===er.Kind.OBJECT_TYPE_DEFINITION){Te=!0,U.push(Wt);return}if((0,kq.isKindAbstract)(Wt.kind))return P.push((0,br.abstractTypeInKeyFieldSetErrorMessage)(v,ve,zt,(0,Tu.kindToNodeType)(Wt.kind))),er.BREAK;ne.add($.join(Mt.PERIOD)),$.pop()}},InlineFragment:{enter(){return P.push(br.inlineFragmentInFieldSetErrorMessage),er.BREAK}},SelectionSet:{enter(){if(!Te){let Fe=U[z],et=`${Fe.name}.${pe}`,X=Fe.fieldDataByName.get(pe);if(!X)return P.push((0,br.undefinedFieldInFieldSetErrorMessage)(v,et,pe)),er.BREAK;let ve=(0,FO.getTypeNodeNamedTypeName)(X.node.type),gt=e.parentDefinitionDataByTypeName.get(ve),zt=gt?gt.kind:er.Kind.SCALAR_TYPE_DEFINITION;return P.push((0,br.invalidSelectionSetDefinitionErrorMessage)(v,[et],ve,(0,Tu.kindToNodeType)(zt))),er.BREAK}if(z+=1,Te=!1,z<0||z>=U.length)return P.push((0,br.unparsableFieldSetSelectionErrorMessage)(v,pe)),er.BREAK;K.push(new Set)},leave(){if(Te){let xe=U[z].name,et=U[z+1],X=`${xe}.${pe}`;P.push((0,br.invalidSelectionSetErrorMessage)(v,[X],et.name,(0,Tu.kindToNodeType)(et.kind))),Te=!1}z-=1,U.pop(),K.pop()}}}),P.length>0){e.errors.push((0,br.invalidDirectiveError)(Mt.KEY,i,(0,Tu.numberToOrdinal)(p),P));continue}a.push(x({fieldName:"",selectionSet:f},g?{disableEntityResolver:!0}:{})),l.satisfiedFieldSets.add(f),!g&&(c==null||c.addTargetSubgraphByFieldSet(f,e.subgraphName),o.push(ne))}if(a.length>0)return a}function Uce(e){return e?Mt.PROVIDES:Mt.REQUIRES}function kce(e,t){return e===Mt.QUERY||t===er.OperationTypeNode.QUERY}function Mce(e,t,n){let r=e.matchAll(Mq.EDFS_ARGS_REGEXP),i=new Set,a=new Set;for(let o of r){if(o.length<2){a.add(o[0]);continue}t.has(o[1])||i.add(o[1])}for(let o of i)n.push((0,br.undefinedEventSubjectsArgumentErrorMessage)(o));for(let o of a)n.push((0,br.invalidEventSubjectsArgumentErrorMessage)(o))}function xce(){return new Map([[Mt.AUTHENTICATED,mn.AUTHENTICATED_DEFINITION_DATA],[Mt.COMPOSE_DIRECTIVE,mn.COMPOSE_DIRECTIVE_DEFINITION_DATA],[Mt.CONFIGURE_DESCRIPTION,mn.CONFIGURE_DESCRIPTION_DEFINITION_DATA],[Mt.CONFIGURE_CHILD_DESCRIPTIONS,mn.CONFIGURE_CHILD_DESCRIPTIONS_DEFINITION_DATA],[Mt.DEPRECATED,mn.DEPRECATED_DEFINITION_DATA],[Mt.EDFS_KAFKA_PUBLISH,mn.KAFKA_PUBLISH_DEFINITION_DATA],[Mt.EDFS_KAFKA_SUBSCRIBE,mn.KAFKA_SUBSCRIBE_DEFINITION_DATA],[Mt.EDFS_NATS_PUBLISH,mn.NATS_PUBLISH_DEFINITION_DATA],[Mt.EDFS_NATS_REQUEST,mn.NATS_REQUEST_DEFINITION_DATA],[Mt.EDFS_NATS_SUBSCRIBE,mn.NATS_SUBSCRIBE_DEFINITION_DATA],[Mt.EDFS_REDIS_PUBLISH,mn.REDIS_PUBLISH_DEFINITION_DATA],[Mt.EDFS_REDIS_SUBSCRIBE,mn.REDIS_SUBSCRIBE_DEFINITION_DATA],[Mt.EXTENDS,mn.EXTENDS_DEFINITION_DATA],[Mt.EXTERNAL,mn.EXTERNAL_DEFINITION_DATA],[Mt.INACCESSIBLE,mn.INACCESSIBLE_DEFINITION_DATA],[Mt.INTERFACE_OBJECT,mn.INTERFACE_OBJECT_DEFINITION_DATA],[Mt.KEY,mn.KEY_DEFINITION_DATA],[Mt.LINK,mn.LINK_DEFINITION_DATA],[Mt.OVERRIDE,mn.OVERRIDE_DEFINITION_DATA],[Mt.PROVIDES,mn.PROVIDES_DEFINITION_DATA],[Mt.REQUIRES,mn.REQUIRES_DEFINITION_DATA],[Mt.REQUIRES_SCOPES,mn.REQUIRES_SCOPES_DEFINITION_DATA],[Mt.SHAREABLE,mn.SHAREABLE_DEFINITION_DATA],[Mt.SPECIFIED_BY,mn.SPECIFIED_BY_DEFINITION_DATA],[Mt.SUBSCRIPTION_FILTER,mn.SUBSCRIPTION_FILTER_DEFINITION_DATA],[Mt.TAG,mn.TAG_DEFINITION_DATA]])}});var LO=w(wO=>{"use strict";m();T();N();Object.defineProperty(wO,"__esModule",{value:!0});wO.recordSubgraphName=qce;function qce(e,t,n){if(!t.has(e)){t.add(e);return}n.add(e)}});var BO=w(yE=>{"use strict";m();T();N();Object.defineProperty(yE,"__esModule",{value:!0});yE.Warning=void 0;var CO=class extends Error{constructor(n){super(n.message);_(this,"subgraph");this.name="Warning",this.subgraph=n.subgraph}};yE.Warning=CO});var gE=w(fa=>{"use strict";m();T();N();Object.defineProperty(fa,"__esModule",{value:!0});fa.invalidOverrideTargetSubgraphNameWarning=Vce;fa.externalInterfaceFieldsWarning=jce;fa.nonExternalConditionalFieldWarning=Kce;fa.unimplementedInterfaceOutputTypeWarning=Gce;fa.invalidExternalFieldWarning=$ce;fa.requiresDefinedOnNonEntityFieldWarning=Qce;fa.consumerInactiveThresholdInvalidValueWarning=Yce;fa.externalEntityExtensionKeyFieldWarning=Jce;fa.fieldAlreadyProvidedWarning=Hce;var gs=BO(),UO=ur();function Vce(e,t,n,r){return new gs.Warning({message:`The Object type "${t}" defines the directive "@override(from: "${e}")" on the following field`+(n.length>1?"s":"")+': "'+n.join(UO.QUOTATION_JOIN)+`". The required "from" argument of type "String!" should be provided with an existing subgraph name. However, a subgraph by the name of "${e}" does not exist. If this subgraph has been recently deleted, remember to clean up unused "@override" directives that reference this subgraph.`,subgraph:{name:r}})}function IE(e){return`The subgraph "${e}" is currently a "version one" subgraph, but if it were updated to "version two" in its current state, composition would be unsuccessful due to the following warning that would instead propagate as an error: @@ -442,16 +444,16 @@ The following field coordinates that form part of that field set are declared "@ "`+n.join(UO.QUOTATION_JOIN)+`" Please note fields that form part of entity extension "@key" field sets are always provided in that subgraph. Any such "@external" declarations are unnecessary relics of Federation Version 1 syntax and are effectively ignored.`,subgraph:{name:r}})}function Hce(e,t,n,r){return new gs.Warning({message:IE(r)+`The field "${e}" is unconditionally provided by subgraph "${r}" and should not form part of any "@${t}" field set. However, "${e}" forms part of the "@${t}" field set defined "${n}". -Although "${e}" is declared "@external", it is part of a "@key" directive on an extension type. Such fields are only declared "@external" for legacy syntactical reasons and are not internally considered "@external".`,subgraph:{name:r}})}});var MO=w(vE=>{"use strict";m();T();N();Object.defineProperty(vE,"__esModule",{value:!0});vE.upsertDirectiveSchemaAndEntityDefinitions=Xce;vE.upsertParentsAndChildren=Zce;var Vn=Ae(),Eu=ia(),Tc=Es(),_E=Kp(),Gl=Yr(),kO=Gp(),zce=kp(),Nc=hl(),$p=ou(),Wce=gE(),tr=ur(),dr=Jr();function Xce(e,t){(0,Vn.visit)(t,{Directive:{enter(n){let r=n.name.value;if(zce.EVENT_DIRECTIVE_NAMES.has(r)&&e.edfsDirectiveReferences.add(r),Tc.V2_DIRECTIVE_DEFINITION_BY_DIRECTIVE_NAME.has(r))return e.isSubgraphVersionTwo=!0,!1;if(Tc.BASE_DIRECTIVE_DEFINITION_BY_DIRECTIVE_NAME.has(r))return!1;switch(r){case tr.SUBSCRIPTION_FILTER:{e.directiveDefinitionByDirectiveName.set(tr.SUBSCRIPTION_FILTER,Tc.SUBSCRIPTION_FILTER_DEFINITION);break}case tr.CONFIGURE_DESCRIPTION:{e.directiveDefinitionByDirectiveName.set(tr.CONFIGURE_DESCRIPTION,Tc.CONFIGURE_DESCRIPTION_DEFINITION);break}case tr.CONFIGURE_CHILD_DESCRIPTIONS:{e.directiveDefinitionByDirectiveName.set(tr.CONFIGURE_CHILD_DESCRIPTIONS,Tc.CONFIGURE_CHILD_DESCRIPTIONS_DEFINITION);break}}e.referencedDirectiveNames.add(r)}},DirectiveDefinition:{enter(n){return e.addDirectiveDefinitionDataByNode(n)&&e.customDirectiveDefinitions.set(n.name.value,n),!1}},InterfaceTypeDefinition:{enter(n){let r=n.name.value;if(e.internalGraph.addOrUpdateNode(r,{isAbstract:!0}),!(0,Gl.isObjectLikeNodeEntity)(n))return;let i=(0,dr.getValueOrDefault)(e.keyFieldSetDatasByTypeName,r,()=>new Map);e.extractKeyFieldSets(n,i),(0,_E.upsertEntityData)({entityDataByTypeName:e.entityDataByTypeName,keyFieldSetDataByFieldSet:i,subgraphName:e.subgraphName,typeName:r}),(0,dr.getValueOrDefault)(e.entityInterfaceDataByTypeName,r,()=>({concreteTypeNames:new Set,fieldDatas:[],interfaceFieldNames:new Set,interfaceObjectFieldNames:new Set,isInterfaceObject:!1,resolvable:!1,typeName:r}))}},InterfaceTypeExtension:{enter(n){let r=n.name.value;if(e.internalGraph.addOrUpdateNode(r,{isAbstract:!0}),!(0,Gl.isObjectLikeNodeEntity)(n))return;let i=(0,dr.getValueOrDefault)(e.keyFieldSetDatasByTypeName,r,()=>new Map);e.extractKeyFieldSets(n,i),(0,_E.upsertEntityData)({entityDataByTypeName:e.entityDataByTypeName,keyFieldSetDataByFieldSet:i,subgraphName:e.subgraphName,typeName:r}),(0,dr.getValueOrDefault)(e.entityInterfaceDataByTypeName,r,()=>({concreteTypeNames:new Set,fieldDatas:[],interfaceFieldNames:new Set,interfaceObjectFieldNames:new Set,isInterfaceObject:!1,resolvable:!1,typeName:r}))}},ObjectTypeDefinition:{enter(n){if(!(0,Gl.isObjectLikeNodeEntity)(n))return;let r=n.name.value;(0,Gl.isNodeInterfaceObject)(n)&&(e.entityInterfaceDataByTypeName.set(r,{concreteTypeNames:new Set,fieldDatas:[],interfaceObjectFieldNames:new Set,interfaceFieldNames:new Set,isInterfaceObject:!0,resolvable:!1,typeName:r}),e.internalGraph.addOrUpdateNode(r,{isAbstract:!0}));let i=(0,dr.getValueOrDefault)(e.keyFieldSetDatasByTypeName,r,()=>new Map);e.extractKeyFieldSets(n,i),(0,_E.upsertEntityData)({entityDataByTypeName:e.entityDataByTypeName,keyFieldSetDataByFieldSet:i,subgraphName:e.subgraphName,typeName:r})}},ObjectTypeExtension:{enter(n){if(!(0,Gl.isObjectLikeNodeEntity)(n))return;let r=n.name.value,i=(0,dr.getValueOrDefault)(e.keyFieldSetDatasByTypeName,r,()=>new Map);e.extractKeyFieldSets(n,i),(0,_E.upsertEntityData)({entityDataByTypeName:e.entityDataByTypeName,keyFieldSetDataByFieldSet:i,subgraphName:e.subgraphName,typeName:r})}},OperationTypeDefinition:{enter(n){let r=n.operation,i=e.schemaData.operationTypes.get(r),a=(0,$p.getTypeNodeNamedTypeName)(n.type);if(i)return(0,Eu.duplicateOperationTypeDefinitionError)(r,a,(0,$p.getTypeNodeNamedTypeName)(i.type)),!1;let o=e.operationTypeNodeByTypeName.get(a);return o?(e.errors.push((0,Eu.invalidOperationTypeDefinitionError)(o,a,r)),!1):(e.operationTypeNodeByTypeName.set(a,r),e.schemaData.operationTypes.set(r,n),!1)}},SchemaDefinition:{enter(n){e.schemaData.description=n.description,e.extractDirectives(n,e.schemaData.directivesByDirectiveName)}},SchemaExtension:{enter(n){e.extractDirectives(n,e.schemaData.directivesByDirectiveName)}}})}function Zce(e,t){let n=!1,r;(0,Vn.visit)(t,{EnumTypeDefinition:{enter(i){e.originalParentTypeName=i.name.value,e.lastParentNodeKind=i.kind,e.upsertEnumDataByNode(i)},leave(){e.originalParentTypeName="",e.lastParentNodeKind=Vn.Kind.NULL}},EnumTypeExtension:{enter(i){e.originalParentTypeName=i.name.value,e.lastParentNodeKind=i.kind,e.upsertEnumDataByNode(i,!0)},leave(){e.originalParentTypeName="",e.lastParentNodeKind=Vn.Kind.NULL}},EnumValueDefinition:{enter(i){let a=i.name.value;e.lastChildNodeKind=i.kind;let o=(0,dr.getOrThrowError)(e.parentDefinitionDataByTypeName,e.originalParentTypeName,tr.PARENT_DEFINITION_DATA);if(o.kind!==Vn.Kind.ENUM_TYPE_DEFINITION){e.errors.push((0,Eu.unexpectedParentKindForChildError)(e.originalParentTypeName,"Enum or Enum extension",(0,dr.kindToNodeType)(o.kind),a,(0,dr.kindToNodeType)(i.kind)));return}if(o.enumValueDataByValueName.has(a)){e.errors.push((0,Eu.duplicateEnumValueDefinitionError)(e.originalParentTypeName,a));return}o.enumValueDataByValueName.set(a,{appearances:1,configureDescriptionDataBySubgraphName:new Map,directivesByDirectiveName:e.extractDirectives(i,new Map),federatedCoords:`${e.originalParentTypeName}.${a}`,kind:Vn.Kind.ENUM_VALUE_DEFINITION,name:a,node:(0,$p.getMutableEnumValueNode)(i),parentTypeName:e.originalParentTypeName,persistedDirectivesData:(0,Nc.newPersistedDirectivesData)(),subgraphNames:new Set([e.subgraphName]),description:(0,Gl.formatDescription)(i.description)})},leave(){e.lastChildNodeKind=Vn.Kind.NULL}},FieldDefinition:{enter(i){let a=i.name.value;if(n&&tr.IGNORED_FIELDS.has(a))return!1;e.edfsDirectiveReferences.size>0&&e.validateSubscriptionFilterDirectiveLocation(i),e.lastChildNodeKind=i.kind;let o=(0,$p.getTypeNodeNamedTypeName)(i.type);(0,dr.getValueOrDefault)(e.fieldCoordsByNamedTypeName,o,()=>new Set).add(`${e.renamedParentTypeName||e.originalParentTypeName}.${a}`),r&&!r.isAbstract&&e.internalGraph.addEdge(r,e.internalGraph.addOrUpdateNode(o),a),Tc.BASE_SCALARS.has(o)||e.referencedTypeNames.add(o);let c=(0,dr.getOrThrowError)(e.parentDefinitionDataByTypeName,e.originalParentTypeName,tr.PARENT_DEFINITION_DATA);if(!(0,Nc.isParentDataCompositeOutputType)(c)){e.errors.push((0,Eu.unexpectedParentKindForChildError)(e.originalParentTypeName,'"Object" or "Interface"',(0,dr.kindToNodeType)(c.kind),a,(0,dr.kindToNodeType)(i.kind)));return}if(c.fieldDataByName.has(a)){e.errors.push((0,Eu.duplicateFieldDefinitionError)((0,dr.kindToNodeType)(c.kind),c.name,a));return}let l=e.extractArguments(new Map,i),p=e.extractDirectives(i,new Map),f=new Set;(0,Nc.isParentDataInterfaceType)(c)||(e.addInheritedDirectivesToFieldData(p,f),p.has(tr.EXTERNAL)&&e.unvalidatedExternalFieldCoords.add(`${e.originalParentTypeName}.${a}`));let y=e.addFieldDataByNode(c.fieldDataByName,i,l,p,f);n&&e.extractEventDirectivesToConfiguration(i,l);let g=y.directivesByDirectiveName.get(tr.PROVIDES),v=y.directivesByDirectiveName.get(tr.REQUIRES);if(!v&&!g)return;let F=e.entityDataByTypeName.get(e.originalParentTypeName),k=(0,dr.getValueOrDefault)(e.fieldSetDataByTypeName,e.originalParentTypeName,kO.newFieldSetData);g&&(0,kO.extractFieldSetValue)(a,k.provides,g),v&&(F||e.warnings.push((0,Wce.requiresDefinedOnNonEntityFieldWarning)(`${e.originalParentTypeName}.${a}`,e.subgraphName)),(0,kO.extractFieldSetValue)(a,k.requires,v))},leave(){e.lastChildNodeKind=Vn.Kind.NULL}},InputObjectTypeDefinition:{enter(i){e.originalParentTypeName=i.name.value,e.lastParentNodeKind=i.kind,e.upsertInputObjectByNode(i)},leave(){e.lastParentNodeKind=Vn.Kind.NULL,e.originalParentTypeName=""}},InputObjectTypeExtension:{enter(i){e.originalParentTypeName=i.name.value,e.lastParentNodeKind=i.kind,e.upsertInputObjectByNode(i,!0)},leave(){e.originalParentTypeName="",e.lastParentNodeKind=Vn.Kind.NULL}},InputValueDefinition:{enter(i){let a=i.name.value;if(e.lastParentNodeKind!==Vn.Kind.INPUT_OBJECT_TYPE_DEFINITION&&e.lastParentNodeKind!==Vn.Kind.INPUT_OBJECT_TYPE_EXTENSION){e.argumentName=a;return}e.lastChildNodeKind=i.kind;let o=(0,$p.getTypeNodeNamedTypeName)(i.type);Tc.BASE_SCALARS.has(o)||e.referencedTypeNames.add(o);let c=(0,dr.getOrThrowError)(e.parentDefinitionDataByTypeName,e.originalParentTypeName,tr.PARENT_DEFINITION_DATA);if(c.kind!==Vn.Kind.INPUT_OBJECT_TYPE_DEFINITION)return e.errors.push((0,Eu.unexpectedParentKindForChildError)(e.originalParentTypeName,"input object or input object extension",(0,dr.kindToNodeType)(c.kind),a,(0,dr.kindToNodeType)(i.kind))),!1;if(c.inputValueDataByName.has(a)){e.errors.push((0,Eu.duplicateInputFieldDefinitionError)(e.originalParentTypeName,a));return}e.addInputValueDataByNode({inputValueDataByName:c.inputValueDataByName,isArgument:!1,node:i,originalParentTypeName:e.originalParentTypeName})},leave(){e.argumentName="",e.lastChildNodeKind===Vn.Kind.INPUT_VALUE_DEFINITION&&(e.lastChildNodeKind=Vn.Kind.NULL)}},InterfaceTypeDefinition:{enter(i){e.originalParentTypeName=i.name.value,e.lastParentNodeKind=i.kind,e.upsertInterfaceDataByNode(i)},leave(){e.originalParentTypeName="",e.lastParentNodeKind=Vn.Kind.NULL}},InterfaceTypeExtension:{enter(i){e.originalParentTypeName=i.name.value,e.lastParentNodeKind=i.kind,e.upsertInterfaceDataByNode(i,!0)},leave(){e.originalParentTypeName="",e.lastParentNodeKind=Vn.Kind.NULL}},ObjectTypeDefinition:{enter(i){if(i.name.value===tr.SERVICE_OBJECT)return!1;e.originalParentTypeName=i.name.value,n=(0,Nc.isTypeNameRootType)(e.originalParentTypeName,e.operationTypeNodeByTypeName),e.renamedParentTypeName=(0,Nc.getRenamedRootTypeName)(e.originalParentTypeName,e.operationTypeNodeByTypeName),e.originalTypeNameByRenamedTypeName.set(e.renamedParentTypeName,e.originalParentTypeName),r=n?e.internalGraph.getRootNode(e.renamedParentTypeName):e.internalGraph.addOrUpdateNode(e.renamedParentTypeName),e.lastParentNodeKind=i.kind,e.upsertObjectDataByNode(i)},leave(){r=void 0,n=!1,e.originalParentTypeName="",e.renamedParentTypeName="",e.lastParentNodeKind=Vn.Kind.NULL,e.isParentObjectExternal=!1,e.isParentObjectShareable=!1}},ObjectTypeExtension:{enter(i){if(i.name.value===tr.SERVICE_OBJECT)return!1;e.originalParentTypeName=i.name.value,n=(0,Nc.isTypeNameRootType)(e.originalParentTypeName,e.operationTypeNodeByTypeName),e.renamedParentTypeName=(0,Nc.getRenamedRootTypeName)(e.originalParentTypeName,e.operationTypeNodeByTypeName),e.originalTypeNameByRenamedTypeName.set(e.renamedParentTypeName,e.originalParentTypeName),r=n?e.internalGraph.getRootNode(e.renamedParentTypeName):e.internalGraph.addOrUpdateNode(e.renamedParentTypeName),e.lastParentNodeKind=i.kind,e.upsertObjectDataByNode(i,!0)},leave(){r=void 0,n=!1,e.originalParentTypeName="",e.renamedParentTypeName="",e.lastParentNodeKind=Vn.Kind.NULL,e.isParentObjectExternal=!1,e.isParentObjectShareable=!1}},ScalarTypeDefinition:{enter(i){if(i.name.value===tr.ANY_SCALAR)return!1;e.originalParentTypeName=i.name.value,e.lastParentNodeKind=i.kind,e.upsertScalarByNode(i)},leave(){e.originalParentTypeName="",e.lastParentNodeKind=Vn.Kind.NULL}},ScalarTypeExtension:{enter(i){if(i.name.value===tr.ANY_SCALAR)return!1;e.originalParentTypeName=i.name.value,e.lastParentNodeKind=i.kind,e.upsertScalarByNode(i,!0)},leave(){e.originalParentTypeName="",e.lastParentNodeKind=Vn.Kind.NULL}},UnionTypeDefinition:{enter(i){i.name.value!==tr.ENTITY_UNION&&e.upsertUnionByNode(i)}},UnionTypeExtension:{enter(i){if(i.name.value===tr.ENTITY_UNION)return!1;e.upsertUnionByNode(i,!0)}}})}});var KO=w(Ka=>{"use strict";m();T();N();Object.defineProperty(Ka,"__esModule",{value:!0});Ka.EntityDataNode=Ka.RootNode=Ka.GraphNode=Ka.Edge=void 0;var SE=Jr(),xO=class{constructor(t,n,r,i=!1){_(this,"edgeName");_(this,"id");_(this,"isAbstractEdge");_(this,"isInaccessible",!1);_(this,"node");_(this,"visitedIndices",new Set);this.edgeName=i?`... on ${r}`:r,this.id=t,this.isAbstractEdge=i,this.node=n}};Ka.Edge=xO;var qO=class{constructor(t,n,r){_(this,"fieldDataByFieldName",new Map);_(this,"headToTailEdges",new Map);_(this,"entityEdges",[]);_(this,"nodeName");_(this,"hasEntitySiblings",!1);_(this,"isAbstract");_(this,"isInaccessible",!1);_(this,"isLeaf",!1);_(this,"isRootNode",!1);_(this,"satisfiedFieldSets",new Set);_(this,"subgraphName");_(this,"typeName");this.isAbstract=!!(r!=null&&r.isAbstract),this.isLeaf=!!(r!=null&&r.isLeaf),this.nodeName=`${t}.${n}`,this.subgraphName=t,this.typeName=n}handleInaccessibleEdges(){if(this.isAbstract)return;let t=(0,SE.getEntriesNotInHashSet)(this.headToTailEdges.keys(),this.fieldDataByFieldName);for(let n of t){let r=this.headToTailEdges.get(n);r&&(r.isInaccessible=!0)}}getAllAccessibleEntityNodeNames(){let t=new Set([this.nodeName]);return this.getAccessibleEntityNodeNames(this,t),t.delete(this.nodeName),t}getAccessibleEntityNodeNames(t,n){for(let r of t.entityEdges)(0,SE.add)(n,r.node.nodeName)&&this.getAccessibleEntityNodeNames(r.node,n)}};Ka.GraphNode=qO;var VO=class{constructor(t){_(this,"fieldDataByFieldName",new Map);_(this,"headToShareableTailEdges",new Map);_(this,"isAbstract",!1);_(this,"isRootNode",!0);_(this,"typeName");this.typeName=t}removeInaccessibleEdges(t){for(let[n,r]of this.headToShareableTailEdges)if(!t.has(n))for(let i of r)i.isInaccessible=!0}};Ka.RootNode=VO;var jO=class{constructor(t){_(this,"fieldSetsByTargetSubgraphName",new Map);_(this,"targetSubgraphNamesByFieldSet",new Map);_(this,"typeName");this.typeName=t}addTargetSubgraphByFieldSet(t,n){(0,SE.getValueOrDefault)(this.targetSubgraphNamesByFieldSet,t,()=>new Set).add(n),(0,SE.getValueOrDefault)(this.fieldSetsByTargetSubgraphName,n,()=>new Set).add(t)}};Ka.EntityDataNode=jO});var $O=w(_s=>{"use strict";m();T();N();Object.defineProperty(_s,"__esModule",{value:!0});_s.NodeResolutionData=void 0;_s.newRootFieldData=ele;_s.generateResolvabilityErrorReasons=Vq;_s.generateSelectionSetSegments=jq;_s.renderSelectionSet=Kq;_s.generateResolvabilityErrors=rle;var xq=ia(),Ec=ur(),qq=Jr(),GO=class{constructor(t,n){_(this,"fieldDataByFieldName");_(this,"isResolved",!1);_(this,"resolvedFieldNames",new Set);_(this,"typeName");this.fieldDataByFieldName=n,this.typeName=t}add(t){if(this.resolvedFieldNames.add(t),this.resolvedFieldNames.size>this.fieldDataByFieldName.size){let n=(0,qq.getEntriesNotInHashSet)(this.resolvedFieldNames,this.fieldDataByFieldName);throw(0,xq.unexpectedEdgeFatalError)(this.typeName,n)}return this.isResolved=this.resolvedFieldNames.size===this.fieldDataByFieldName.size,this.isResolved}};_s.NodeResolutionData=GO;function ele(e,t,n){return{coordinate:`${e}.${t}`,message:`The root type field "${e}.${t}" is defined in the following subgraph`+(n.size>1?"s":"")+`: "${[...n].join(Ec.QUOTATION_JOIN)}".`,subgraphNames:n}}function tle(e,t){return e.isLeaf?e.name+` <-- +Although "${e}" is declared "@external", it is part of a "@key" directive on an extension type. Such fields are only declared "@external" for legacy syntactical reasons and are not internally considered "@external".`,subgraph:{name:r}})}});var MO=w(vE=>{"use strict";m();T();N();Object.defineProperty(vE,"__esModule",{value:!0});vE.upsertDirectiveSchemaAndEntityDefinitions=Xce;vE.upsertParentsAndChildren=Zce;var Vn=Ae(),Eu=ia(),Tc=Es(),_E=Kp(),Gl=Yr(),kO=Gp(),zce=kp(),Nc=hl(),$p=ou(),Wce=gE(),tr=ur(),dr=Jr();function Xce(e,t){(0,Vn.visit)(t,{Directive:{enter(n){let r=n.name.value;if(zce.EVENT_DIRECTIVE_NAMES.has(r)&&e.edfsDirectiveReferences.add(r),Tc.V2_DIRECTIVE_DEFINITION_BY_DIRECTIVE_NAME.has(r))return e.isSubgraphVersionTwo=!0,!1;if(Tc.BASE_DIRECTIVE_DEFINITION_BY_DIRECTIVE_NAME.has(r))return!1;switch(r){case tr.SUBSCRIPTION_FILTER:{e.directiveDefinitionByDirectiveName.set(tr.SUBSCRIPTION_FILTER,Tc.SUBSCRIPTION_FILTER_DEFINITION);break}case tr.CONFIGURE_DESCRIPTION:{e.directiveDefinitionByDirectiveName.set(tr.CONFIGURE_DESCRIPTION,Tc.CONFIGURE_DESCRIPTION_DEFINITION);break}case tr.CONFIGURE_CHILD_DESCRIPTIONS:{e.directiveDefinitionByDirectiveName.set(tr.CONFIGURE_CHILD_DESCRIPTIONS,Tc.CONFIGURE_CHILD_DESCRIPTIONS_DEFINITION);break}}e.referencedDirectiveNames.add(r)}},DirectiveDefinition:{enter(n){return e.addDirectiveDefinitionDataByNode(n)&&e.customDirectiveDefinitions.set(n.name.value,n),!1}},InterfaceTypeDefinition:{enter(n){let r=n.name.value;if(e.internalGraph.addOrUpdateNode(r,{isAbstract:!0}),!(0,Gl.isObjectLikeNodeEntity)(n))return;let i=(0,dr.getValueOrDefault)(e.keyFieldSetDatasByTypeName,r,()=>new Map);e.extractKeyFieldSets(n,i),(0,_E.upsertEntityData)({entityDataByTypeName:e.entityDataByTypeName,keyFieldSetDataByFieldSet:i,subgraphName:e.subgraphName,typeName:r}),(0,dr.getValueOrDefault)(e.entityInterfaceDataByTypeName,r,()=>({concreteTypeNames:new Set,fieldDatas:[],interfaceFieldNames:new Set,interfaceObjectFieldNames:new Set,isInterfaceObject:!1,resolvable:!1,typeName:r}))}},InterfaceTypeExtension:{enter(n){let r=n.name.value;if(e.internalGraph.addOrUpdateNode(r,{isAbstract:!0}),!(0,Gl.isObjectLikeNodeEntity)(n))return;let i=(0,dr.getValueOrDefault)(e.keyFieldSetDatasByTypeName,r,()=>new Map);e.extractKeyFieldSets(n,i),(0,_E.upsertEntityData)({entityDataByTypeName:e.entityDataByTypeName,keyFieldSetDataByFieldSet:i,subgraphName:e.subgraphName,typeName:r}),(0,dr.getValueOrDefault)(e.entityInterfaceDataByTypeName,r,()=>({concreteTypeNames:new Set,fieldDatas:[],interfaceFieldNames:new Set,interfaceObjectFieldNames:new Set,isInterfaceObject:!1,resolvable:!1,typeName:r}))}},ObjectTypeDefinition:{enter(n){if(!(0,Gl.isObjectLikeNodeEntity)(n))return;let r=n.name.value;(0,Gl.isNodeInterfaceObject)(n)&&(e.entityInterfaceDataByTypeName.set(r,{concreteTypeNames:new Set,fieldDatas:[],interfaceObjectFieldNames:new Set,interfaceFieldNames:new Set,isInterfaceObject:!0,resolvable:!1,typeName:r}),e.internalGraph.addOrUpdateNode(r,{isAbstract:!0}));let i=(0,dr.getValueOrDefault)(e.keyFieldSetDatasByTypeName,r,()=>new Map);e.extractKeyFieldSets(n,i),(0,_E.upsertEntityData)({entityDataByTypeName:e.entityDataByTypeName,keyFieldSetDataByFieldSet:i,subgraphName:e.subgraphName,typeName:r})}},ObjectTypeExtension:{enter(n){if(!(0,Gl.isObjectLikeNodeEntity)(n))return;let r=n.name.value,i=(0,dr.getValueOrDefault)(e.keyFieldSetDatasByTypeName,r,()=>new Map);e.extractKeyFieldSets(n,i),(0,_E.upsertEntityData)({entityDataByTypeName:e.entityDataByTypeName,keyFieldSetDataByFieldSet:i,subgraphName:e.subgraphName,typeName:r})}},OperationTypeDefinition:{enter(n){let r=n.operation,i=e.schemaData.operationTypes.get(r),a=(0,$p.getTypeNodeNamedTypeName)(n.type);if(i)return(0,Eu.duplicateOperationTypeDefinitionError)(r,a,(0,$p.getTypeNodeNamedTypeName)(i.type)),!1;let o=e.operationTypeNodeByTypeName.get(a);return o?(e.errors.push((0,Eu.invalidOperationTypeDefinitionError)(o,a,r)),!1):(e.operationTypeNodeByTypeName.set(a,r),e.schemaData.operationTypes.set(r,n),!1)}},SchemaDefinition:{enter(n){e.schemaData.description=n.description,e.extractDirectives(n,e.schemaData.directivesByDirectiveName)}},SchemaExtension:{enter(n){e.extractDirectives(n,e.schemaData.directivesByDirectiveName)}}})}function Zce(e,t){let n=!1,r;(0,Vn.visit)(t,{EnumTypeDefinition:{enter(i){e.originalParentTypeName=i.name.value,e.lastParentNodeKind=i.kind,e.upsertEnumDataByNode(i)},leave(){e.originalParentTypeName="",e.lastParentNodeKind=Vn.Kind.NULL}},EnumTypeExtension:{enter(i){e.originalParentTypeName=i.name.value,e.lastParentNodeKind=i.kind,e.upsertEnumDataByNode(i,!0)},leave(){e.originalParentTypeName="",e.lastParentNodeKind=Vn.Kind.NULL}},EnumValueDefinition:{enter(i){let a=i.name.value;e.lastChildNodeKind=i.kind;let o=(0,dr.getOrThrowError)(e.parentDefinitionDataByTypeName,e.originalParentTypeName,tr.PARENT_DEFINITION_DATA);if(o.kind!==Vn.Kind.ENUM_TYPE_DEFINITION){e.errors.push((0,Eu.unexpectedParentKindForChildError)(e.originalParentTypeName,"Enum or Enum extension",(0,dr.kindToNodeType)(o.kind),a,(0,dr.kindToNodeType)(i.kind)));return}if(o.enumValueDataByValueName.has(a)){e.errors.push((0,Eu.duplicateEnumValueDefinitionError)(e.originalParentTypeName,a));return}o.enumValueDataByValueName.set(a,{appearances:1,configureDescriptionDataBySubgraphName:new Map,directivesByDirectiveName:e.extractDirectives(i,new Map),federatedCoords:`${e.originalParentTypeName}.${a}`,kind:Vn.Kind.ENUM_VALUE_DEFINITION,name:a,node:(0,$p.getMutableEnumValueNode)(i),parentTypeName:e.originalParentTypeName,persistedDirectivesData:(0,Nc.newPersistedDirectivesData)(),subgraphNames:new Set([e.subgraphName]),description:(0,Gl.formatDescription)(i.description)})},leave(){e.lastChildNodeKind=Vn.Kind.NULL}},FieldDefinition:{enter(i){let a=i.name.value;if(n&&tr.IGNORED_FIELDS.has(a))return!1;e.edfsDirectiveReferences.size>0&&e.validateSubscriptionFilterDirectiveLocation(i),e.lastChildNodeKind=i.kind;let o=(0,$p.getTypeNodeNamedTypeName)(i.type);(0,dr.getValueOrDefault)(e.fieldCoordsByNamedTypeName,o,()=>new Set).add(`${e.renamedParentTypeName||e.originalParentTypeName}.${a}`),r&&!r.isAbstract&&e.internalGraph.addEdge(r,e.internalGraph.addOrUpdateNode(o),a),Tc.BASE_SCALARS.has(o)||e.referencedTypeNames.add(o);let c=(0,dr.getOrThrowError)(e.parentDefinitionDataByTypeName,e.originalParentTypeName,tr.PARENT_DEFINITION_DATA);if(!(0,Nc.isParentDataCompositeOutputType)(c)){e.errors.push((0,Eu.unexpectedParentKindForChildError)(e.originalParentTypeName,'"Object" or "Interface"',(0,dr.kindToNodeType)(c.kind),a,(0,dr.kindToNodeType)(i.kind)));return}if(c.fieldDataByName.has(a)){e.errors.push((0,Eu.duplicateFieldDefinitionError)((0,dr.kindToNodeType)(c.kind),c.name,a));return}let l=e.extractArguments(new Map,i),p=e.extractDirectives(i,new Map),f=new Set;(0,Nc.isParentDataInterfaceType)(c)||(e.addInheritedDirectivesToFieldData(p,f),p.has(tr.EXTERNAL)&&e.unvalidatedExternalFieldCoords.add(`${e.originalParentTypeName}.${a}`));let y=e.addFieldDataByNode(c.fieldDataByName,i,l,p,f);n&&e.extractEventDirectivesToConfiguration(i,l);let g=y.directivesByDirectiveName.get(tr.PROVIDES),v=y.directivesByDirectiveName.get(tr.REQUIRES);if(!v&&!g)return;let P=e.entityDataByTypeName.get(e.originalParentTypeName),U=(0,dr.getValueOrDefault)(e.fieldSetDataByTypeName,e.originalParentTypeName,kO.newFieldSetData);g&&(0,kO.extractFieldSetValue)(a,U.provides,g),v&&(P||e.warnings.push((0,Wce.requiresDefinedOnNonEntityFieldWarning)(`${e.originalParentTypeName}.${a}`,e.subgraphName)),(0,kO.extractFieldSetValue)(a,U.requires,v))},leave(){e.lastChildNodeKind=Vn.Kind.NULL}},InputObjectTypeDefinition:{enter(i){e.originalParentTypeName=i.name.value,e.lastParentNodeKind=i.kind,e.upsertInputObjectByNode(i)},leave(){e.lastParentNodeKind=Vn.Kind.NULL,e.originalParentTypeName=""}},InputObjectTypeExtension:{enter(i){e.originalParentTypeName=i.name.value,e.lastParentNodeKind=i.kind,e.upsertInputObjectByNode(i,!0)},leave(){e.originalParentTypeName="",e.lastParentNodeKind=Vn.Kind.NULL}},InputValueDefinition:{enter(i){let a=i.name.value;if(e.lastParentNodeKind!==Vn.Kind.INPUT_OBJECT_TYPE_DEFINITION&&e.lastParentNodeKind!==Vn.Kind.INPUT_OBJECT_TYPE_EXTENSION){e.argumentName=a;return}e.lastChildNodeKind=i.kind;let o=(0,$p.getTypeNodeNamedTypeName)(i.type);Tc.BASE_SCALARS.has(o)||e.referencedTypeNames.add(o);let c=(0,dr.getOrThrowError)(e.parentDefinitionDataByTypeName,e.originalParentTypeName,tr.PARENT_DEFINITION_DATA);if(c.kind!==Vn.Kind.INPUT_OBJECT_TYPE_DEFINITION)return e.errors.push((0,Eu.unexpectedParentKindForChildError)(e.originalParentTypeName,"input object or input object extension",(0,dr.kindToNodeType)(c.kind),a,(0,dr.kindToNodeType)(i.kind))),!1;if(c.inputValueDataByName.has(a)){e.errors.push((0,Eu.duplicateInputFieldDefinitionError)(e.originalParentTypeName,a));return}e.addInputValueDataByNode({inputValueDataByName:c.inputValueDataByName,isArgument:!1,node:i,originalParentTypeName:e.originalParentTypeName})},leave(){e.argumentName="",e.lastChildNodeKind===Vn.Kind.INPUT_VALUE_DEFINITION&&(e.lastChildNodeKind=Vn.Kind.NULL)}},InterfaceTypeDefinition:{enter(i){e.originalParentTypeName=i.name.value,e.lastParentNodeKind=i.kind,e.upsertInterfaceDataByNode(i)},leave(){e.originalParentTypeName="",e.lastParentNodeKind=Vn.Kind.NULL}},InterfaceTypeExtension:{enter(i){e.originalParentTypeName=i.name.value,e.lastParentNodeKind=i.kind,e.upsertInterfaceDataByNode(i,!0)},leave(){e.originalParentTypeName="",e.lastParentNodeKind=Vn.Kind.NULL}},ObjectTypeDefinition:{enter(i){if(i.name.value===tr.SERVICE_OBJECT)return!1;e.originalParentTypeName=i.name.value,n=(0,Nc.isTypeNameRootType)(e.originalParentTypeName,e.operationTypeNodeByTypeName),e.renamedParentTypeName=(0,Nc.getRenamedRootTypeName)(e.originalParentTypeName,e.operationTypeNodeByTypeName),e.originalTypeNameByRenamedTypeName.set(e.renamedParentTypeName,e.originalParentTypeName),r=n?e.internalGraph.getRootNode(e.renamedParentTypeName):e.internalGraph.addOrUpdateNode(e.renamedParentTypeName),e.lastParentNodeKind=i.kind,e.upsertObjectDataByNode(i)},leave(){r=void 0,n=!1,e.originalParentTypeName="",e.renamedParentTypeName="",e.lastParentNodeKind=Vn.Kind.NULL,e.isParentObjectExternal=!1,e.isParentObjectShareable=!1}},ObjectTypeExtension:{enter(i){if(i.name.value===tr.SERVICE_OBJECT)return!1;e.originalParentTypeName=i.name.value,n=(0,Nc.isTypeNameRootType)(e.originalParentTypeName,e.operationTypeNodeByTypeName),e.renamedParentTypeName=(0,Nc.getRenamedRootTypeName)(e.originalParentTypeName,e.operationTypeNodeByTypeName),e.originalTypeNameByRenamedTypeName.set(e.renamedParentTypeName,e.originalParentTypeName),r=n?e.internalGraph.getRootNode(e.renamedParentTypeName):e.internalGraph.addOrUpdateNode(e.renamedParentTypeName),e.lastParentNodeKind=i.kind,e.upsertObjectDataByNode(i,!0)},leave(){r=void 0,n=!1,e.originalParentTypeName="",e.renamedParentTypeName="",e.lastParentNodeKind=Vn.Kind.NULL,e.isParentObjectExternal=!1,e.isParentObjectShareable=!1}},ScalarTypeDefinition:{enter(i){if(i.name.value===tr.ANY_SCALAR)return!1;e.originalParentTypeName=i.name.value,e.lastParentNodeKind=i.kind,e.upsertScalarByNode(i)},leave(){e.originalParentTypeName="",e.lastParentNodeKind=Vn.Kind.NULL}},ScalarTypeExtension:{enter(i){if(i.name.value===tr.ANY_SCALAR)return!1;e.originalParentTypeName=i.name.value,e.lastParentNodeKind=i.kind,e.upsertScalarByNode(i,!0)},leave(){e.originalParentTypeName="",e.lastParentNodeKind=Vn.Kind.NULL}},UnionTypeDefinition:{enter(i){i.name.value!==tr.ENTITY_UNION&&e.upsertUnionByNode(i)}},UnionTypeExtension:{enter(i){if(i.name.value===tr.ENTITY_UNION)return!1;e.upsertUnionByNode(i,!0)}}})}});var KO=w(Ka=>{"use strict";m();T();N();Object.defineProperty(Ka,"__esModule",{value:!0});Ka.EntityDataNode=Ka.RootNode=Ka.GraphNode=Ka.Edge=void 0;var SE=Jr(),xO=class{constructor(t,n,r,i=!1){_(this,"edgeName");_(this,"id");_(this,"isAbstractEdge");_(this,"isInaccessible",!1);_(this,"node");_(this,"visitedIndices",new Set);this.edgeName=i?`... on ${r}`:r,this.id=t,this.isAbstractEdge=i,this.node=n}};Ka.Edge=xO;var qO=class{constructor(t,n,r){_(this,"fieldDataByFieldName",new Map);_(this,"headToTailEdges",new Map);_(this,"entityEdges",[]);_(this,"nodeName");_(this,"hasEntitySiblings",!1);_(this,"isAbstract");_(this,"isInaccessible",!1);_(this,"isLeaf",!1);_(this,"isRootNode",!1);_(this,"satisfiedFieldSets",new Set);_(this,"subgraphName");_(this,"typeName");this.isAbstract=!!(r!=null&&r.isAbstract),this.isLeaf=!!(r!=null&&r.isLeaf),this.nodeName=`${t}.${n}`,this.subgraphName=t,this.typeName=n}handleInaccessibleEdges(){if(this.isAbstract)return;let t=(0,SE.getEntriesNotInHashSet)(this.headToTailEdges.keys(),this.fieldDataByFieldName);for(let n of t){let r=this.headToTailEdges.get(n);r&&(r.isInaccessible=!0)}}getAllAccessibleEntityNodeNames(){let t=new Set([this.nodeName]);return this.getAccessibleEntityNodeNames(this,t),t.delete(this.nodeName),t}getAccessibleEntityNodeNames(t,n){for(let r of t.entityEdges)(0,SE.add)(n,r.node.nodeName)&&this.getAccessibleEntityNodeNames(r.node,n)}};Ka.GraphNode=qO;var VO=class{constructor(t){_(this,"fieldDataByFieldName",new Map);_(this,"headToShareableTailEdges",new Map);_(this,"isAbstract",!1);_(this,"isRootNode",!0);_(this,"typeName");this.typeName=t}removeInaccessibleEdges(t){for(let[n,r]of this.headToShareableTailEdges)if(!t.has(n))for(let i of r)i.isInaccessible=!0}};Ka.RootNode=VO;var jO=class{constructor(t){_(this,"fieldSetsByTargetSubgraphName",new Map);_(this,"targetSubgraphNamesByFieldSet",new Map);_(this,"typeName");this.typeName=t}addTargetSubgraphByFieldSet(t,n){(0,SE.getValueOrDefault)(this.targetSubgraphNamesByFieldSet,t,()=>new Set).add(n),(0,SE.getValueOrDefault)(this.fieldSetsByTargetSubgraphName,n,()=>new Set).add(t)}};Ka.EntityDataNode=jO});var $O=w(_s=>{"use strict";m();T();N();Object.defineProperty(_s,"__esModule",{value:!0});_s.NodeResolutionData=void 0;_s.newRootFieldData=ele;_s.generateResolvabilityErrorReasons=Vq;_s.generateSelectionSetSegments=jq;_s.renderSelectionSet=Kq;_s.generateResolvabilityErrors=rle;var xq=ia(),Ec=ur(),qq=Jr(),GO=class{constructor(t,n){_(this,"fieldDataByFieldName");_(this,"isResolved",!1);_(this,"resolvedFieldNames",new Set);_(this,"typeName");this.fieldDataByFieldName=n,this.typeName=t}add(t){if(this.resolvedFieldNames.add(t),this.resolvedFieldNames.size>this.fieldDataByFieldName.size){let n=(0,qq.getEntriesNotInHashSet)(this.resolvedFieldNames,this.fieldDataByFieldName);throw(0,xq.unexpectedEdgeFatalError)(this.typeName,n)}return this.isResolved=this.resolvedFieldNames.size===this.fieldDataByFieldName.size,this.isResolved}};_s.NodeResolutionData=GO;function ele(e,t,n){return{coordinate:`${e}.${t}`,message:`The root type field "${e}.${t}" is defined in the following subgraph`+(n.size>1?"s":"")+`: "${[...n].join(Ec.QUOTATION_JOIN)}".`,subgraphNames:n}}function tle(e,t){return e.isLeaf?e.name+` <-- `:e.name+` { <-- `+Ec.LITERAL_SPACE.repeat(t+3)+`... `+Ec.LITERAL_SPACE.repeat(t+2)+`} `}function Vq({entityAncestorData:e,rootFieldData:t,unresolvableFieldData:n}){let{fieldName:r,typeName:i,subgraphNames:a}=n,o=[t.message,`The field "${i}.${r}" is defined in the following subgraph`+(a.size>1?"s":"")+`: "${[...a].join(Ec.QUOTATION_JOIN)}".`];if(e){let c=!1;for(let[l,p]of e.fieldSetsByTargetSubgraphName)if(a.has(l)){c=!0;for(let f of p)o.push(`The entity ancestor "${e.typeName}" in subgraph "${e.subgraphName}" does not satisfy the key field set "${f}" to access subgraph "${l}".`)}c||o.push(`The entity ancestor "${e.typeName}" in subgraph "${e.subgraphName}" has no accessible target entities (resolvable @key directives) in the subgraphs where "${i}.${r}" is defined.`),o.push(`The type "${i}" is not a descendent of any other entity ancestors that can provide a shared route to access "${r}".`)}else t.subgraphNames.size>1&&o.push(`None of the subgraphs that share the same root type field "${t.coordinate}" can provide a route to access "${r}".`),o.push(`The type "${i}" is not a descendent of an entity ancestor that can provide a shared route to access "${r}".`);return i!==(e==null?void 0:e.typeName)&&o.push(`The type "${i}" has no accessible target entities (resolvable @key directives) in any other subgraph, so accessing other subgraphs is not possible.`),o}function jq(e){let t=e.split(new RegExp("(?<=\\w)\\.")),n="",r="";for(let i=0;i{"use strict";m();T();N();Object.defineProperty(OE,"__esModule",{value:!0});OE.Graph=void 0;var $l=KO(),Ql=$O(),Gq=ur(),Ur=Jr(),QO=class{constructor(){_(this,"edgeId",-1);_(this,"entityDataNodes",new Map);_(this,"entityNodeNamesBySharedFieldPath",new Map);_(this,"nodeByNodeName",new Map);_(this,"nodesByTypeName",new Map);_(this,"rootNodeByRootTypeName",new Map);_(this,"subgraphName",Gq.NOT_APPLICABLE);_(this,"resolvableFieldNamesByRelativeFieldPathByEntityNodeName",new Map);_(this,"nodeResolutionDataByFieldPath",new Map);_(this,"unresolvableFieldPaths",new Set);_(this,"failureResultByEntityNodeName",new Map);_(this,"walkerIndex",-1)}getRootNode(t){return(0,Ur.getValueOrDefault)(this.rootNodeByRootTypeName,t,()=>new $l.RootNode(t))}addOrUpdateNode(t,n){let r=`${this.subgraphName}.${t}`,i=this.nodeByNodeName.get(r);if(i)return i.isAbstract||(i.isAbstract=!!(n!=null&&n.isAbstract)),!i.isLeaf&&(n!=null&&n.isLeaf)&&(i.isLeaf=!0),i;let a=new $l.GraphNode(this.subgraphName,t,n);return this.nodeByNodeName.set(r,a),(0,Ur.getValueOrDefault)(this.nodesByTypeName,t,()=>[]).push(a),a}addEdge(t,n,r,i=!1){if(t.isRootNode){let c=new $l.Edge(this.getNextEdgeId(),n,r);return(0,Ur.getValueOrDefault)(t.headToShareableTailEdges,r,()=>[]).push(c),c}let a=t,o=new $l.Edge(this.getNextEdgeId(),n,i?n.typeName:r,i);return a.headToTailEdges.set(r,o),o}addEntityDataNode(t){let n=this.entityDataNodes.get(t);if(n)return n;let r=new $l.EntityDataNode(t);return this.entityDataNodes.set(t,r),r}getNextEdgeId(){return this.edgeId+=1}setNodeInaccessible(t){let n=this.nodesByTypeName.get(t);if(n)for(let r of n)r.isInaccessible=!0}initializeNode(t,n){let r=this.entityDataNodes.get(t);if(Gq.ROOT_TYPE_NAMES.has(t)){let a=this.getRootNode(t);a.removeInaccessibleEdges(n),a.fieldDataByFieldName=n;return}let i=this.nodesByTypeName.get(t);if(i){for(let a of i)if(a.fieldDataByFieldName=n,a.handleInaccessibleEdges(),a.isLeaf=!1,!!r){a.hasEntitySiblings=!0;for(let o of a.satisfiedFieldSets){let c=r.targetSubgraphNamesByFieldSet.get(o);for(let l of c||[]){if(l===a.subgraphName)continue;let p=this.nodeByNodeName.get(`${l}.${a.typeName}`);p&&a.entityEdges.push(new $l.Edge(this.getNextEdgeId(),p,""))}}}}}setSubgraphName(t){this.subgraphName=t}validateEntities(t,n){let r=new Map;for(let[i,a]of t){let o=a.size>1,c,l=o?new Map:void 0,p=new Set,f=new Map;for(let y of a){let g=this.nodeByNodeName.get(y);if(!g)throw new Error(`Fatal: Could not find entity node for "${y}".`);if(this.resolvableFieldNamesByRelativeFieldPathByEntityNodeName.get(y)){let $=this.failureResultByEntityNodeName.get(y);if(!$){c=void 0;break}if(!o)return $}let F=this.nodesByTypeName.get(g.typeName)||[],k=(0,Ur.getValueOrDefault)(r,y,()=>o?f:new Map),K=new YO({interSubgraphNodes:F,entityNodeNamesBySharedFieldPath:k,originNode:g,resolvableFieldNamesByRelativeFieldPathByEntityNodeName:this.resolvableFieldNamesByRelativeFieldPathByEntityNodeName,walkerIndex:this.walkerIndex+=1,sharedResolvableFieldNamesByRelativeFieldPath:l,unresolvableSharedFieldPaths:p});if(K.visitEntityNode(g),K.unresolvableFieldPaths.size>0){if(o&&p.size<1){c=void 0;break}c={entityAncestorData:{fieldSetsByTargetSubgraphName:(0,Ur.getOrThrowError)(this.entityDataNodes,g.typeName,"entityDataNodes").fieldSetsByTargetSubgraphName,subgraphName:g.subgraphName,typeName:g.typeName},nodeName:y,parentFieldPathForEntityReference:[i],success:!1,typeName:g.typeName,unresolvableFieldPaths:o?p:K.unresolvableFieldPaths},this.failureResultByEntityNodeName.set(y,c);continue}c=void 0;break}if(c)return o&&l&&this.resolvableFieldNamesByRelativeFieldPathByEntityNodeName.set(c.nodeName,l),c}if(r.size>0)for(let[i,a]of r){let o=this.validateEntities(a,n);if(!o.success){for(let[c,l]of t)if(l.has(i)){o.parentFieldPathForEntityReference.push(c);break}return o}}return{success:!0}}validate(){let t=[];for(let n of this.rootNodeByRootTypeName.values())e:for(let[r,i]of n.headToShareableTailEdges){for(let c of i){if(c.isInaccessible)continue e;this.walkerIndex+=1,this.visitEdge(c,`${n.typeName.toLowerCase()}`)}let a=(0,Ur.getOrThrowError)(n.fieldDataByFieldName,r,"fieldDataByFieldName"),o=(0,Ql.newRootFieldData)(n.typeName,r,a.subgraphNames);if(this.unresolvableFieldPaths.size>0&&(0,Ql.generateResolvabilityErrors)({unresolvableFieldPaths:this.unresolvableFieldPaths,nodeResolutionDataByFieldPath:this.nodeResolutionDataByFieldPath,rootFieldData:o,errors:t}),this.entityNodeNamesBySharedFieldPath.size>0){let c=this.validateEntities(this.entityNodeNamesBySharedFieldPath,o);c.success||this.generateEntityResolvabilityErrors(c,o,t)}if(t.length>0)return t;this.entityNodeNamesBySharedFieldPath=new Map}return[]}visitEdge(t,n){return t.isInaccessible||t.node.isInaccessible?!1:(!(0,Ur.add)(t.visitedIndices,this.walkerIndex)||t.node.isLeaf||(t.node.isAbstract?this.validateAbstractNode(t.node,`${n}.${t.edgeName}`):this.validateConcreteNode(t.node,`${n}.${t.edgeName}`)),!0)}validateConcreteNode(t,n){if(t.headToTailEdges.size<1)return;if(t.hasEntitySiblings){(0,Ur.getValueOrDefault)(this.entityNodeNamesBySharedFieldPath,n,()=>new Set).add(t.nodeName);return}let r=(0,Ur.getValueOrDefault)(this.nodeResolutionDataByFieldPath,n,()=>new Ql.NodeResolutionData(t.typeName,t.fieldDataByFieldName));for(let[i,a]of t.headToTailEdges)this.visitEdge(a,n)&&r.add(i);r.isResolved?this.unresolvableFieldPaths.delete(n):this.unresolvableFieldPaths.add(n)}validateAbstractNode(t,n){if(!(t.headToTailEdges.size<1))for(let r of t.headToTailEdges.values())this.visitEdge(r,n)}generateEntityResolvabilityErrors(t,n,r){let i=(0,Ur.getOrThrowError)(this.resolvableFieldNamesByRelativeFieldPathByEntityNodeName,t.nodeName,"resolvableFieldNamesByRelativeFieldPathByEntityNodeName"),a="";for(let o of t.parentFieldPathForEntityReference)a=o+a;(0,Ql.generateResolvabilityErrors)({unresolvableFieldPaths:t.unresolvableFieldPaths,nodeResolutionDataByFieldPath:i,rootFieldData:n,errors:r,pathFromRoot:a,entityAncestorData:t.entityAncestorData})}};OE.Graph=QO;var YO=class{constructor({entityNodeNamesBySharedFieldPath:t,interSubgraphNodes:n,originNode:r,resolvableFieldNamesByRelativeFieldPathByEntityNodeName:i,unresolvableSharedFieldPaths:a,walkerIndex:o,sharedResolvableFieldNamesByRelativeFieldPath:c}){_(this,"entityNodeNamesBySharedFieldPath");_(this,"interSubgraphNodes");_(this,"originNode");_(this,"resolvableFieldNamesByRelativeFieldPath");_(this,"resolvableFieldNamesByRelativeFieldPathByEntityNodeName");_(this,"unresolvableFieldPaths",new Set);_(this,"unresolvableSharedFieldPaths");_(this,"walkerIndex");_(this,"sharedResolvableFieldNamesByRelativeFieldPath");this.entityNodeNamesBySharedFieldPath=t,this.interSubgraphNodes=n,this.originNode=r,this.resolvableFieldNamesByRelativeFieldPathByEntityNodeName=i,this.resolvableFieldNamesByRelativeFieldPath=(0,Ur.getValueOrDefault)(this.resolvableFieldNamesByRelativeFieldPathByEntityNodeName,r.nodeName,()=>new Map),this.unresolvableSharedFieldPaths=a,this.walkerIndex=o,this.sharedResolvableFieldNamesByRelativeFieldPath=c}visitEntityNode(t){this.validateEntityRelatedConcreteNode(t,"");let n=t.getAllAccessibleEntityNodeNames();for(let r of this.interSubgraphNodes){if(this.unresolvableFieldPaths.size<0)return;n.has(r.nodeName)&&this.validateEntityRelatedConcreteNode(r,"")}}visitEntityRelatedEdge(t,n){return t.isInaccessible||t.node.isInaccessible?!1:!(0,Ur.add)(t.visitedIndices,this.walkerIndex)||t.node.isLeaf?!0:t.node.hasEntitySiblings?((0,Ur.getValueOrDefault)(this.entityNodeNamesBySharedFieldPath,`${n}.${t.edgeName}`,()=>new Set).add(t.node.nodeName),!0):(t.node.isAbstract?this.validateEntityRelatedAbstractNode(t.node,`${n}.${t.edgeName}`):this.validateEntityRelatedConcreteNode(t.node,`${n}.${t.edgeName}`),!0)}validateEntityRelatedConcreteNode(t,n){if(t.headToTailEdges.size<1)return;let r=(0,Ur.getValueOrDefault)(this.resolvableFieldNamesByRelativeFieldPath,n,()=>new Ql.NodeResolutionData(t.typeName,t.fieldDataByFieldName)),i=this.sharedResolvableFieldNamesByRelativeFieldPath?(0,Ur.getValueOrDefault)(this.sharedResolvableFieldNamesByRelativeFieldPath,n,()=>new Ql.NodeResolutionData(t.typeName,t.fieldDataByFieldName)):void 0;for(let[a,o]of t.headToTailEdges)this.visitEntityRelatedEdge(o,n)&&(r.add(a),i==null||i.add(a));r.isResolved?this.unresolvableFieldPaths.delete(n):this.unresolvableFieldPaths.add(n),i&&(i.isResolved?this.unresolvableSharedFieldPaths.delete(n):this.unresolvableSharedFieldPaths.add(n))}validateEntityRelatedAbstractNode(t,n){if(!(t.headToTailEdges.size<1))for(let r of t.headToTailEdges.values())this.visitEntityRelatedEdge(r,n)}}});var HO=w(DE=>{"use strict";m();T();N();Object.defineProperty(DE,"__esModule",{value:!0});DE.newFieldSetConditionData=ile;DE.newConfigurationData=ale;function ile({fieldCoordinatesPath:e,fieldPath:t}){return{fieldCoordinatesPath:e,fieldPath:t}}function ale(e,t){return{fieldNames:new Set,isRootNode:e,typeName:t}}});var WO=w(hc=>{"use strict";m();T();N();Object.defineProperty(hc,"__esModule",{value:!0});hc.NormalizationFactory=void 0;hc.normalizeSubgraphFromString=cle;hc.normalizeSubgraph=Qq;hc.batchNormalize=lle;var Z=Ae(),On=Yr(),ei=Gp(),Ht=Es(),rr=Kp(),de=ia(),bE=kp(),sle=dv(),ma=XT(),ole=LO(),vs=gE(),$q=MO(),Ga=hp(),Nn=hl(),nr=ou(),zO=JO(),AE=Nv(),te=ur(),ule=Nl(),$e=Jr(),Qp=HO();function cle(e,t=!0){let{error:n,documentNode:r}=(0,On.safeParse)(e,t);return n||!r?{errors:[(0,de.subgraphInvalidSyntaxError)(n)],success:!1,warnings:[]}:new Yp(new zO.Graph).normalize(r)}function Qq(e,t,n){return new Yp(n||new zO.Graph,t).normalize(e)}var Yp=class{constructor(t,n){_(this,"argumentName","");_(this,"authorizationDataByParentTypeName",new Map);_(this,"concreteTypeNamesByAbstractTypeName",new Map);_(this,"conditionalFieldDataByCoords",new Map);_(this,"configurationDataByTypeName",new Map);_(this,"customDirectiveDefinitions",new Map);_(this,"definedDirectiveNames",new Set);_(this,"directiveDefinitionByDirectiveName",new Map);_(this,"directiveDefinitionDataByDirectiveName",(0,ei.initializeDirectiveDefinitionDatas)());_(this,"edfsDirectiveReferences",new Set);_(this,"errors",[]);_(this,"entityDataByTypeName",new Map);_(this,"entityInterfaceDataByTypeName",new Map);_(this,"eventsConfigurations",new Map);_(this,"fieldSetDataByTypeName",new Map);_(this,"internalGraph");_(this,"invalidConfigureDescriptionNodeDatas",[]);_(this,"invalidORScopesCoords",new Set);_(this,"invalidRepeatedDirectiveNameByCoords",new Map);_(this,"isCurrentParentExtension",!1);_(this,"isParentObjectExternal",!1);_(this,"isParentObjectShareable",!1);_(this,"isSubgraphEventDrivenGraph",!1);_(this,"isSubgraphVersionTwo",!1);_(this,"keyFieldSetDatasByTypeName",new Map);_(this,"lastParentNodeKind",Z.Kind.NULL);_(this,"lastChildNodeKind",Z.Kind.NULL);_(this,"parentTypeNamesWithAuthDirectives",new Set);_(this,"keyFieldSetDataByTypeName",new Map);_(this,"keyFieldSetsByEntityTypeNameByFieldCoords",new Map);_(this,"keyFieldNamesByParentTypeName",new Map);_(this,"fieldCoordsByNamedTypeName",new Map);_(this,"operationTypeNodeByTypeName",new Map);_(this,"originalParentTypeName","");_(this,"originalTypeNameByRenamedTypeName",new Map);_(this,"overridesByTargetSubgraphName",new Map);_(this,"parentDefinitionDataByTypeName",new Map);_(this,"schemaData");_(this,"referencedDirectiveNames",new Set);_(this,"referencedTypeNames",new Set);_(this,"renamedParentTypeName","");_(this,"subgraphName");_(this,"unvalidatedExternalFieldCoords",new Set);_(this,"usesEdfsNatsStreamConfiguration",!1);_(this,"warnings",[]);for(let[r,i]of Ht.BASE_DIRECTIVE_DEFINITION_BY_DIRECTIVE_NAME)this.directiveDefinitionByDirectiveName.set(r,i);this.subgraphName=n||te.NOT_APPLICABLE,this.internalGraph=t,this.internalGraph.setSubgraphName(this.subgraphName),this.schemaData={directivesByDirectiveName:new Map,kind:Z.Kind.SCHEMA_DEFINITION,name:te.SCHEMA,operationTypes:new Map}}validateArguments(t,n){for(let r of t.argumentDataByName.values()){let i=(0,nr.getTypeNodeNamedTypeName)(r.type);if(Ht.BASE_SCALARS.has(i)){r.namedTypeKind=Z.Kind.SCALAR_TYPE_DEFINITION;continue}let a=this.parentDefinitionDataByTypeName.get(i);if(a){if((0,Nn.isInputNodeKind)(a.kind)){r.namedTypeKind=a.kind;continue}this.errors.push((0,de.invalidNamedTypeError)({data:r,namedTypeData:a,nodeType:`${(0,$e.kindToNodeType)(n)} field argument`}))}}}isTypeNameRootType(t){return te.ROOT_TYPE_NAMES.has(t)||this.operationTypeNodeByTypeName.has(t)}isArgumentValueValid(t,n){if(n.kind===Z.Kind.NULL)return t.kind!==Z.Kind.NON_NULL_TYPE;switch(t.kind){case Z.Kind.LIST_TYPE:{if(n.kind!==Z.Kind.LIST)return this.isArgumentValueValid((0,nr.getNamedTypeNode)(t.type),n);for(let r of n.values)if(!this.isArgumentValueValid(t.type,r))return!1;return!0}case Z.Kind.NAMED_TYPE:switch(t.name.value){case te.BOOLEAN_SCALAR:return n.kind===Z.Kind.BOOLEAN;case te.FLOAT_SCALAR:return n.kind===Z.Kind.FLOAT||n.kind===Z.Kind.INT;case te.ID_SCALAR:return n.kind===Z.Kind.STRING||n.kind===Z.Kind.INT;case te.INT_SCALAR:return n.kind===Z.Kind.INT;case te.FIELD_SET_SCALAR:case te.SCOPE_SCALAR:case te.STRING_SCALAR:return n.kind===Z.Kind.STRING;case te.LINK_IMPORT:return!0;case te.LINK_PURPOSE:return n.kind!==Z.Kind.ENUM?!1:n.value===te.SECURITY||n.value===te.EXECUTION;case te.SUBSCRIPTION_FIELD_CONDITION:case te.SUBSCRIPTION_FILTER_CONDITION:return n.kind===Z.Kind.OBJECT;default:{let r=this.parentDefinitionDataByTypeName.get(t.name.value);if(!r)return!1;if(r.kind===Z.Kind.SCALAR_TYPE_DEFINITION)return!0;if(r.kind===Z.Kind.ENUM_TYPE_DEFINITION){if(n.kind!==Z.Kind.ENUM)return!1;let i=r.enumValueDataByValueName.get(n.value);return i?!i.directivesByDirectiveName.has(te.INACCESSIBLE):!1}return r.kind!==Z.Kind.INPUT_OBJECT_TYPE_DEFINITION?!1:n.kind===Z.Kind.OBJECT}}default:return this.isArgumentValueValid(t.type,n)}}addInheritedDirectivesToFieldData(t,n){return this.isParentObjectShareable&&!t.has(te.SHAREABLE)&&(t.set(te.SHAREABLE,[(0,$e.generateSimpleDirective)(te.SHAREABLE)]),n.add(te.SHAREABLE)),this.isParentObjectExternal&&!t.has(te.EXTERNAL)&&(t.set(te.EXTERNAL,[(0,$e.generateSimpleDirective)(te.EXTERNAL)]),n.add(te.EXTERNAL)),t}extractDirectives(t,n){if(!t.directives)return n;for(let r of t.directives){let i=r.name.value;i===te.SHAREABLE?(0,$e.getValueOrDefault)(n,i,()=>[r]):(0,$e.getValueOrDefault)(n,i,()=>[]).push(r),(0,rr.isNodeKindObject)(t.kind)&&(this.isParentObjectExternal||(this.isParentObjectExternal=i===te.EXTERNAL),this.isParentObjectShareable||(this.isParentObjectShareable=i===te.SHAREABLE))}return n}validateDirective({data:t,definitionData:n,directiveCoords:r,directiveNode:i,errorMessages:a,requiredArgumentNames:o}){let c=i.name.value,l=t.kind===Z.Kind.FIELD_DEFINITION?t.renamedParentTypeName||t.originalParentTypeName:t.name,p=c===te.AUTHENTICATED,f=c===te.OVERRIDE,y=c===te.REQUIRES_SCOPES;if(!i.arguments||i.arguments.length<1)return n.requiredArgumentNames.size>0&&a.push((0,de.undefinedRequiredArgumentsErrorMessage)(c,o,[])),p&&this.handleAuthenticatedDirective(t,l),a;let g=new Set,v=new Set,F=new Set,k=[];for(let ne of i.arguments){let z=ne.name.value;if(g.has(z)){v.add(z);continue}g.add(z);let Te=n.argumentTypeNodeByArgumentName.get(z);if(!Te){F.add(z);continue}if(!this.isArgumentValueValid(Te.typeNode,ne.value)){a.push((0,de.invalidArgumentValueErrorMessage)((0,Z.print)(ne.value),`@${c}`,z,(0,ma.printTypeNode)(Te.typeNode)));continue}if(f&&t.kind===Z.Kind.FIELD_DEFINITION){this.handleOverrideDirective({data:t,directiveCoords:r,errorMessages:a,targetSubgraphName:ne.value.value});continue}!y||z!==te.SCOPES||this.extractRequiredScopes({directiveCoords:r,orScopes:ne.value.values,requiredScopes:k})}v.size>0&&a.push((0,de.duplicateDirectiveArgumentDefinitionsErrorMessage)([...v])),F.size>0&&a.push((0,de.unexpectedDirectiveArgumentErrorMessage)(c,[...F]));let K=(0,$e.getEntriesNotInHashSet)(o,g);if(K.length>0&&a.push((0,de.undefinedRequiredArgumentsErrorMessage)(c,o,K)),a.length>0||!y)return a;let $=(0,$e.getValueOrDefault)(this.authorizationDataByParentTypeName,l,()=>(0,rr.newAuthorizationData)(l));if(t.kind!==Z.Kind.FIELD_DEFINITION)this.parentTypeNamesWithAuthDirectives.add(l),$.requiredScopes.push(...k);else{let ne=(0,$e.getValueOrDefault)($.fieldAuthDataByFieldName,t.name,()=>(0,rr.newFieldAuthorizationData)(t.name));ne.inheritedData.requiredScopes.push(...k),ne.originalData.requiredScopes.push(...k)}return a}validateDirectives(t,n){let r=new Set;for(let[i,a]of t.directivesByDirectiveName){let o=this.directiveDefinitionDataByDirectiveName.get(i);if(!o){r.has(i)||(this.errors.push((0,de.undefinedDirectiveError)(i,n)),r.add(i));continue}let c=[],l=(0,On.nodeKindToDirectiveLocation)(t.kind);if(o.locations.has(l)||c.push((0,de.invalidDirectiveLocationErrorMessage)(i,l)),a.length>1&&!o.isRepeatable){let f=(0,$e.getValueOrDefault)(this.invalidRepeatedDirectiveNameByCoords,n,()=>new Set);f.has(i)||(f.add(i),c.push((0,de.invalidRepeatedDirectiveErrorMessage)(i)))}let p=[...o.requiredArgumentNames];for(let f=0;f0&&this.errors.push((0,de.invalidDirectiveError)(i,n,(0,$e.numberToOrdinal)(f+1),y))}}switch(t.kind){case Z.Kind.ENUM_TYPE_DEFINITION:{for(let[i,a]of t.enumValueDataByValueName)this.validateDirectives(a,`${t.name}.${i}`);return}case Z.Kind.FIELD_DEFINITION:{for(let[i,a]of t.argumentDataByName)this.validateDirectives(a,`${t.originalParentTypeName}.${t.name}(${i}: ...)`);return}case Z.Kind.INPUT_OBJECT_TYPE_DEFINITION:{for(let[i,a]of t.inputValueDataByName)this.validateDirectives(a,`${t.name}.${i}`);return}case Z.Kind.INTERFACE_TYPE_DEFINITION:case Z.Kind.OBJECT_TYPE_DEFINITION:{for(let[i,a]of t.fieldDataByName)this.validateDirectives(a,`${t.name}.${i}`);return}default:return}}getNodeExtensionType(t,n,r=!1){return t?Ga.ExtensionType.REAL:r||!n.has(te.EXTENDS)?Ga.ExtensionType.NONE:Ga.ExtensionType.EXTENDS}setParentDataExtensionType(t,n){switch(t.extensionType){case Ga.ExtensionType.EXTENDS:case Ga.ExtensionType.NONE:{if(n===Ga.ExtensionType.REAL)return;this.errors.push((0,de.duplicateTypeDefinitionError)((0,$e.kindToNodeType)(t.kind),t.name));return}default:t.extensionType=n}}extractConfigureDescriptionData(t,n){var i,a;if(!n.arguments||n.arguments.length<1){t.description||this.invalidConfigureDescriptionNodeDatas.push(t),t.configureDescriptionDataBySubgraphName.set(this.subgraphName,{propagate:!0,description:((i=t.description)==null?void 0:i.value)||""});return}let r={propagate:!0,description:((a=t.description)==null?void 0:a.value)||""};for(let o of n.arguments)switch(o.name.value){case te.PROPAGATE:{if(o.value.kind!=Z.Kind.BOOLEAN)return;r.propagate=o.value.value;break}case te.DESCRIPTION_OVERRIDE:{if(o.value.kind!=Z.Kind.STRING)return;r.description=o.value.value;break}default:return}!t.description&&!r.description&&this.invalidConfigureDescriptionNodeDatas.push(t),t.configureDescriptionDataBySubgraphName.set(this.subgraphName,r)}extractConfigureDescriptionsData(t){let n=t.directivesByDirectiveName.get(te.CONFIGURE_DESCRIPTION);n&&n.length==1&&this.extractConfigureDescriptionData(t,n[0])}extractImplementedInterfaceTypeNames(t,n){if(!t.interfaces)return n;let r=t.name.value;for(let i of t.interfaces){let a=i.name.value;if(n.has(a)){this.errors.push((0,de.duplicateImplementedInterfaceError)((0,rr.kindToConvertedTypeString)(t.kind),r,a));continue}n.add(a)}return n}updateCompositeOutputDataByNode(t,n,r){this.setParentDataExtensionType(n,r),this.extractImplementedInterfaceTypeNames(t,n.implementedInterfaceTypeNames),n.description||(n.description=(0,On.formatDescription)("description"in t?t.description:void 0)),this.extractConfigureDescriptionsData(n),n.isEntity||(n.isEntity=n.directivesByDirectiveName.has(te.KEY)),n.isInaccessible||(n.isInaccessible=n.directivesByDirectiveName.has(te.INACCESSIBLE)),n.subgraphNames.add(this.subgraphName)}addConcreteTypeNamesForImplementedInterfaces(t,n){for(let r of t)(0,$e.getValueOrDefault)(this.concreteTypeNamesByAbstractTypeName,r,()=>new Set).add(n),this.internalGraph.addEdge(this.internalGraph.addOrUpdateNode(r,{isAbstract:!0}),this.internalGraph.addOrUpdateNode(n),n,!0)}extractArguments(t,n){var o;if(!((o=n.arguments)!=null&&o.length))return t;let r=n.name.value,i=`${this.originalParentTypeName}.${r}`,a=new Set;for(let c of n.arguments){let l=c.name.value;if(t.has(l)){a.add(l);continue}this.addInputValueDataByNode({fieldName:r,inputValueDataByName:t,isArgument:!0,node:c,originalParentTypeName:this.originalParentTypeName,renamedParentTypeName:this.renamedParentTypeName})}return a.size>0&&this.errors.push((0,de.duplicateArgumentsError)(i,[...a])),t}addPersistedDirectiveDefinitionDataByNode(t,n,r){let i=n.name.value,a=`@${i}`,o=new Map;for(let c of n.arguments||[])this.addInputValueDataByNode({inputValueDataByName:o,isArgument:!0,node:c,originalParentTypeName:a});t.set(i,{argumentDataByArgumentName:o,executableLocations:r,name:i,repeatable:n.repeatable,subgraphNames:new Set([this.subgraphName]),description:(0,On.formatDescription)(n.description)})}extractDirectiveLocations(t,n){let r=new Set,i=new Set;for(let a of t.locations){let o=a.value;if(!i.has(o)){if(!te.EXECUTABLE_DIRECTIVE_LOCATIONS.has(o)&&!bE.TYPE_SYSTEM_DIRECTIVE_LOCATIONS.has(o)){n.push((0,de.invalidDirectiveDefinitionLocationErrorMessage)(o)),i.add(o);continue}if(r.has(o)){n.push((0,de.duplicateDirectiveDefinitionLocationErrorMessage)(o)),i.add(o);continue}r.add(o)}}return r}extractArgumentData(t,n){let r=new Map,i=new Set,a=new Set,o={argumentTypeNodeByArgumentName:r,optionalArgumentNames:i,requiredArgumentNames:a};if(!t)return o;let c=new Set;for(let l of t){let p=l.name.value;if(r.has(p)){c.add(p);continue}l.defaultValue&&i.add(p),(0,Nn.isTypeRequired)(l.type)&&!l.defaultValue&&a.add(p),r.set(p,{name:p,typeNode:l.type,defaultValue:l.defaultValue})}return c.size>0&&n.push((0,de.duplicateDirectiveDefinitionArgumentErrorMessage)([...c])),o}addDirectiveDefinitionDataByNode(t){let n=t.name.value;if(this.definedDirectiveNames.has(n))return this.errors.push((0,de.duplicateDirectiveDefinitionError)(n)),!1;if(this.definedDirectiveNames.add(n),this.directiveDefinitionByDirectiveName.set(n,t),Ht.V2_DIRECTIVE_DEFINITION_BY_DIRECTIVE_NAME.has(n))return this.isSubgraphVersionTwo=!0,!1;if(Ht.ALL_IN_BUILT_DIRECTIVE_NAMES.has(n))return!1;let r=[],{argumentTypeNodeByArgumentName:i,optionalArgumentNames:a,requiredArgumentNames:o}=this.extractArgumentData(t.arguments,r);return this.directiveDefinitionDataByDirectiveName.set(n,{argumentTypeNodeByArgumentName:i,isRepeatable:t.repeatable,locations:this.extractDirectiveLocations(t,r),name:n,node:t,optionalArgumentNames:a,requiredArgumentNames:o}),r.length>0&&this.errors.push((0,de.invalidDirectiveDefinitionError)(n,r)),!0}addFieldDataByNode(t,n,r,i,a=new Set){let o=n.name.value,c=this.renamedParentTypeName||this.originalParentTypeName,l=`${this.originalParentTypeName}.${o}`,{isExternal:p,isShareable:f}=(0,Nn.isNodeExternalOrShareable)(n,!this.isSubgraphVersionTwo,i),y=(0,nr.getTypeNodeNamedTypeName)(n.type),g={argumentDataByName:r,configureDescriptionDataBySubgraphName:new Map,externalFieldDataBySubgraphName:new Map([[this.subgraphName,(0,Nn.newExternalFieldData)(p)]]),federatedCoords:`${c}.${o}`,inheritedDirectiveNames:a,isInaccessible:i.has(te.INACCESSIBLE),isShareableBySubgraphName:new Map([[this.subgraphName,f]]),kind:Z.Kind.FIELD_DEFINITION,name:o,namedTypeKind:Ht.BASE_SCALARS.has(y)?Z.Kind.SCALAR_TYPE_DEFINITION:Z.Kind.NULL,namedTypeName:y,node:(0,nr.getMutableFieldNode)(n,l,this.errors),originalParentTypeName:this.originalParentTypeName,persistedDirectivesData:(0,Nn.newPersistedDirectivesData)(),renamedParentTypeName:c,subgraphNames:new Set([this.subgraphName]),type:(0,nr.getMutableTypeNode)(n.type,l,this.errors),directivesByDirectiveName:i,description:(0,On.formatDescription)(n.description)};return Ht.BASE_SCALARS.has(g.namedTypeName)||this.referencedTypeNames.add(g.namedTypeName),this.extractConfigureDescriptionsData(g),t.set(o,g),g}addInputValueDataByNode({fieldName:t,inputValueDataByName:n,isArgument:r,node:i,originalParentTypeName:a,renamedParentTypeName:o}){let c=o||a,l=i.name.value,p=r?`${a}${t?`.${t}`:""}(${l}: ...)`:`${a}.${l}`;i.defaultValue&&!(0,Nn.areDefaultValuesCompatible)(i.type,i.defaultValue)&&this.errors.push((0,de.incompatibleInputValueDefaultValueTypeError)((r?te.ARGUMENT:te.INPUT_FIELD)+` "${l}"`,p,(0,ma.printTypeNode)(i.type),(0,Z.print)(i.defaultValue)));let f=r?`${c}${t?`.${t}`:""}(${l}: ...)`:`${c}.${l}`,y=(0,nr.getTypeNodeNamedTypeName)(i.type),g={configureDescriptionDataBySubgraphName:new Map,directivesByDirectiveName:this.extractDirectives(i,new Map),federatedCoords:f,fieldName:t,includeDefaultValue:!!i.defaultValue,isArgument:r,kind:r?Z.Kind.ARGUMENT:Z.Kind.INPUT_VALUE_DEFINITION,name:l,namedTypeKind:Ht.BASE_SCALARS.has(y)?Z.Kind.SCALAR_TYPE_DEFINITION:Z.Kind.NULL,namedTypeName:y,node:(0,nr.getMutableInputValueNode)(i,a,this.errors),originalCoords:p,originalParentTypeName:a,persistedDirectivesData:(0,Nn.newPersistedDirectivesData)(),renamedParentTypeName:c,requiredSubgraphNames:new Set((0,Nn.isTypeRequired)(i.type)?[this.subgraphName]:[]),subgraphNames:new Set([this.subgraphName]),type:(0,nr.getMutableTypeNode)(i.type,a,this.errors),defaultValue:i.defaultValue,description:(0,On.formatDescription)(i.description)};this.extractConfigureDescriptionsData(g),n.set(l,g)}upsertInterfaceDataByNode(t,n=!1){let r=t.name.value,i=this.parentDefinitionDataByTypeName.get(r),a=this.extractDirectives(t,(i==null?void 0:i.directivesByDirectiveName)||new Map),o=this.getNodeExtensionType(n,a),c=this.entityInterfaceDataByTypeName.get(r);if(c&&t.fields)for(let p of t.fields)c.interfaceFieldNames.add(p.name.value);if(i){if(i.kind!==Z.Kind.INTERFACE_TYPE_DEFINITION){this.errors.push((0,de.multipleNamedTypeDefinitionError)(r,(0,$e.kindToNodeType)(i.kind),(0,rr.kindToConvertedTypeString)(t.kind)));return}this.updateCompositeOutputDataByNode(t,i,o);return}let l={configureDescriptionDataBySubgraphName:new Map,directivesByDirectiveName:a,extensionType:o,fieldDataByName:new Map,implementedInterfaceTypeNames:this.extractImplementedInterfaceTypeNames(t,new Set),isEntity:a.has(te.KEY),isInaccessible:a.has(te.INACCESSIBLE),kind:Z.Kind.INTERFACE_TYPE_DEFINITION,name:r,node:(0,nr.getMutableInterfaceNode)(t.name),persistedDirectivesData:(0,Nn.newPersistedDirectivesData)(),subgraphNames:new Set([this.subgraphName]),description:(0,On.formatDescription)("description"in t?t.description:void 0)};this.extractConfigureDescriptionsData(l),this.parentDefinitionDataByTypeName.set(r,l)}getRenamedRootTypeName(t){let n=this.operationTypeNodeByTypeName.get(t);if(!n)return t;switch(n){case Z.OperationTypeNode.MUTATION:return te.MUTATION;case Z.OperationTypeNode.SUBSCRIPTION:return te.SUBSCRIPTION;default:return te.QUERY}}addInterfaceObjectFieldsByNode(t){let n=t.name.value,r=this.entityInterfaceDataByTypeName.get(n);if(!(!r||!r.isInterfaceObject||!t.fields))for(let i of t.fields)r.interfaceObjectFieldNames.add(i.name.value)}upsertObjectDataByNode(t,n=!1){let r=t.name.value,i=this.parentDefinitionDataByTypeName.get(r),a=this.extractDirectives(t,(i==null?void 0:i.directivesByDirectiveName)||new Map),o=this.isTypeNameRootType(r),c=this.getNodeExtensionType(n,a,o);if(this.addInterfaceObjectFieldsByNode(t),i){if(i.kind!==Z.Kind.OBJECT_TYPE_DEFINITION){this.errors.push((0,de.multipleNamedTypeDefinitionError)(r,(0,$e.kindToNodeType)(i.kind),(0,rr.kindToConvertedTypeString)(t.kind)));return}this.updateCompositeOutputDataByNode(t,i,c),a.has(te.INTERFACE_OBJECT)||this.addConcreteTypeNamesForImplementedInterfaces(i.implementedInterfaceTypeNames,r);return}let l=this.extractImplementedInterfaceTypeNames(t,new Set);a.has(te.INTERFACE_OBJECT)||this.addConcreteTypeNamesForImplementedInterfaces(l,r);let p={configureDescriptionDataBySubgraphName:new Map,directivesByDirectiveName:a,extensionType:c,fieldDataByName:new Map,implementedInterfaceTypeNames:l,isEntity:a.has(te.KEY),isInaccessible:a.has(te.INACCESSIBLE),isRootType:o,kind:Z.Kind.OBJECT_TYPE_DEFINITION,name:r,node:(0,nr.getMutableObjectNode)(t.name),persistedDirectivesData:(0,Nn.newPersistedDirectivesData)(),renamedTypeName:this.getRenamedRootTypeName(r),subgraphNames:new Set([this.subgraphName]),description:(0,On.formatDescription)("description"in t?t.description:void 0)};this.extractConfigureDescriptionsData(p),this.parentDefinitionDataByTypeName.set(r,p)}upsertEnumDataByNode(t,n=!1){let r=t.name.value;this.internalGraph.addOrUpdateNode(r,{isLeaf:!0});let i=this.parentDefinitionDataByTypeName.get(r),a=this.extractDirectives(t,(i==null?void 0:i.directivesByDirectiveName)||new Map),o=this.getNodeExtensionType(n,a);if(i){if(i.kind!==Z.Kind.ENUM_TYPE_DEFINITION){this.errors.push((0,de.multipleNamedTypeDefinitionError)(r,(0,$e.kindToNodeType)(i.kind),(0,rr.kindToConvertedTypeString)(t.kind)));return}this.setParentDataExtensionType(i,o),i.isInaccessible||(i.isInaccessible=a.has(te.INACCESSIBLE)),i.subgraphNames.add(this.subgraphName),i.description||(i.description=(0,On.formatDescription)("description"in t?t.description:void 0)),this.extractConfigureDescriptionsData(i);return}let c={appearances:1,configureDescriptionDataBySubgraphName:new Map,directivesByDirectiveName:a,extensionType:o,enumValueDataByValueName:new Map,isInaccessible:a.has(te.INACCESSIBLE),kind:Z.Kind.ENUM_TYPE_DEFINITION,name:r,node:(0,nr.getMutableEnumNode)(t.name),persistedDirectivesData:(0,Nn.newPersistedDirectivesData)(),subgraphNames:new Set([this.subgraphName]),description:(0,On.formatDescription)("description"in t?t.description:void 0)};this.extractConfigureDescriptionsData(c),this.parentDefinitionDataByTypeName.set(r,c)}upsertInputObjectByNode(t,n=!1){let r=t.name.value,i=this.parentDefinitionDataByTypeName.get(r),a=this.extractDirectives(t,(i==null?void 0:i.directivesByDirectiveName)||new Map),o=this.getNodeExtensionType(n,a);if(i){if(i.kind!==Z.Kind.INPUT_OBJECT_TYPE_DEFINITION){this.errors.push((0,de.multipleNamedTypeDefinitionError)(r,(0,$e.kindToNodeType)(i.kind),(0,rr.kindToConvertedTypeString)(t.kind)));return}this.setParentDataExtensionType(i,o),i.isInaccessible||(i.isInaccessible=a.has(te.INACCESSIBLE)),i.subgraphNames.add(this.subgraphName),i.description||(i.description=(0,On.formatDescription)("description"in t?t.description:void 0)),this.extractConfigureDescriptionsData(i);return}let c={configureDescriptionDataBySubgraphName:new Map,directivesByDirectiveName:a,extensionType:o,inputValueDataByName:new Map,isInaccessible:a.has(te.INACCESSIBLE),kind:Z.Kind.INPUT_OBJECT_TYPE_DEFINITION,name:r,node:(0,nr.getMutableInputObjectNode)(t.name),persistedDirectivesData:(0,Nn.newPersistedDirectivesData)(),subgraphNames:new Set([this.subgraphName]),description:(0,On.formatDescription)("description"in t?t.description:void 0)};this.extractConfigureDescriptionsData(c),this.parentDefinitionDataByTypeName.set(r,c)}upsertScalarByNode(t,n=!1){let r=t.name.value;this.internalGraph.addOrUpdateNode(r,{isLeaf:!0});let i=this.parentDefinitionDataByTypeName.get(r),a=this.extractDirectives(t,(i==null?void 0:i.directivesByDirectiveName)||new Map),o=this.getNodeExtensionType(n,a);if(i){if(i.kind!==Z.Kind.SCALAR_TYPE_DEFINITION){this.errors.push((0,de.multipleNamedTypeDefinitionError)(r,(0,$e.kindToNodeType)(i.kind),(0,rr.kindToConvertedTypeString)(t.kind)));return}this.setParentDataExtensionType(i,o),i.description||(i.description=(0,On.formatDescription)("description"in t?t.description:void 0)),i.subgraphNames.add(this.subgraphName),this.extractConfigureDescriptionsData(i);return}let c={configureDescriptionDataBySubgraphName:new Map,directivesByDirectiveName:a,extensionType:o,kind:Z.Kind.SCALAR_TYPE_DEFINITION,name:r,node:(0,nr.getMutableScalarNode)(t.name),persistedDirectivesData:(0,Nn.newPersistedDirectivesData)(),subgraphNames:new Set([this.subgraphName]),description:(0,On.formatDescription)("description"in t?t.description:void 0)};this.extractConfigureDescriptionsData(c),this.parentDefinitionDataByTypeName.set(r,c)}extractUnionMembers(t,n){if(!t.types)return n;let r=t.name.value;for(let i of t.types){let a=i.name.value;if(n.has(a)){this.errors.push((0,de.duplicateUnionMemberDefinitionError)(r,a));continue}(0,$e.getValueOrDefault)(this.concreteTypeNamesByAbstractTypeName,r,()=>new Set).add(a),Ht.BASE_SCALARS.has(a)||this.referencedTypeNames.add(a),n.set(a,i)}return n}upsertUnionByNode(t,n=!1){let r=t.name.value,i=this.parentDefinitionDataByTypeName.get(r),a=this.extractDirectives(t,(i==null?void 0:i.directivesByDirectiveName)||new Map),o=this.getNodeExtensionType(n,a);if(this.addConcreteTypeNamesForUnion(t),i){if(i.kind!==Z.Kind.UNION_TYPE_DEFINITION){this.errors.push((0,de.multipleNamedTypeDefinitionError)(r,(0,$e.kindToNodeType)(i.kind),(0,rr.kindToConvertedTypeString)(t.kind)));return}this.setParentDataExtensionType(i,o),this.extractUnionMembers(t,i.memberByMemberTypeName),i.description||(i.description=(0,On.formatDescription)("description"in t?t.description:void 0)),i.subgraphNames.add(this.subgraphName),this.extractConfigureDescriptionsData(i);return}let c={configureDescriptionDataBySubgraphName:new Map,directivesByDirectiveName:a,extensionType:o,kind:Z.Kind.UNION_TYPE_DEFINITION,memberByMemberTypeName:this.extractUnionMembers(t,new Map),name:r,node:(0,nr.getMutableUnionNode)(t.name),persistedDirectivesData:(0,Nn.newPersistedDirectivesData)(),subgraphNames:new Set([this.subgraphName]),description:(0,On.formatDescription)("description"in t?t.description:void 0)};this.extractConfigureDescriptionsData(c),this.parentDefinitionDataByTypeName.set(r,c)}extractKeyFieldSets(t,n){var a;let r=t.name.value;if(!((a=t.directives)!=null&&a.length)){this.errors.push((0,de.expectedEntityError)(r));return}let i=0;for(let o of t.directives){if(o.name.value!==te.KEY||(i+=1,!o.arguments||o.arguments.length<1))continue;let c,l=!1;for(let v of o.arguments){if(v.name.value===te.RESOLVABLE){v.value.kind===Z.Kind.BOOLEAN&&!v.value.value&&(l=!0);continue}if(v.name.value!==te.FIELDS){c=void 0;break}if(v.value.kind!==Z.Kind.STRING){c=void 0;break}c=v.value.value}if(c===void 0)continue;let{error:p,documentNode:f}=(0,On.safeParse)("{"+c+"}");if(p||!f){this.errors.push((0,de.invalidDirectiveError)(te.KEY,r,(0,$e.numberToOrdinal)(i),[(0,de.unparsableFieldSetErrorMessage)(c,p)]));continue}let y=(0,ei.getNormalizedFieldSet)(f),g=n.get(y);g?g.isUnresolvable||(g.isUnresolvable=l):n.set(y,{documentNode:f,isUnresolvable:l,normalizedFieldSet:y,rawFieldSet:c})}}getFieldSetParent(t,n,r,i){if(!t)return{fieldSetParentData:n};let a=(0,$e.getOrThrowError)(n.fieldDataByName,r,`${i}.fieldDataByFieldName`),o=(0,nr.getTypeNodeNamedTypeName)(a.node.type),c=this.parentDefinitionDataByTypeName.get(o);return c?c.kind!==Z.Kind.INTERFACE_TYPE_DEFINITION&&c.kind!==Z.Kind.OBJECT_TYPE_DEFINITION?{errorString:(0,de.incompatibleTypeWithProvidesErrorMessage)(`${i}.${r}`,o)}:{fieldSetParentData:c}:{errorString:(0,de.unknownNamedTypeErrorMessage)(`${i}.${r}`,o)}}validateConditionalFieldSet(t,n,r,i,a){let{error:o,documentNode:c}=(0,On.safeParse)("{"+n+"}");if(o||!c)return{errorMessages:[(0,de.unparsableFieldSetErrorMessage)(n,o)]};let l=this,p=[t],f=(0,ei.getConditionalFieldSetDirectiveName)(i),y=[],g=`${a}.${r}`,v=(0,ei.getInitialFieldCoordsPath)(i,g),F=[r],k=new Set,K=[],$=-1,ne=!0,z=r,Te=!1;return(0,Z.visit)(c,{Argument:{enter(){return!1}},Field:{enter(pe){let Fe=p[$],Ve=Fe.name;if(Fe.kind===Z.Kind.UNION_TYPE_DEFINITION)return K.push((0,de.invalidSelectionOnUnionErrorMessage)(n,v,Ve)),Z.BREAK;let et=pe.name.value,X=`${Ve}.${et}`;if(l.unvalidatedExternalFieldCoords.delete(X),ne)return K.push((0,de.invalidSelectionSetErrorMessage)(n,v,Ve,(0,$e.kindToNodeType)(Fe.kind))),Z.BREAK;v.push(X),F.push(et),z=et;let ve=Fe.fieldDataByName.get(et);if(!ve)return K.push((0,de.undefinedFieldInFieldSetErrorMessage)(n,Ve,et)),Z.BREAK;if(y[$].has(et))return K.push((0,de.duplicateFieldInFieldSetErrorMessage)(n,X)),Z.BREAK;y[$].add(et);let{isDefinedExternal:gt,isUnconditionallyProvided:zt}=(0,$e.getOrThrowError)(ve.externalFieldDataBySubgraphName,l.subgraphName,`${X}.externalFieldDataBySubgraphName`),Wt=gt&&!zt;zt||(Te=!0);let Dn=(0,nr.getTypeNodeNamedTypeName)(ve.node.type),Vt=l.parentDefinitionDataByTypeName.get(Dn);if(Ht.BASE_SCALARS.has(Dn)||(Vt==null?void 0:Vt.kind)===Z.Kind.SCALAR_TYPE_DEFINITION||(Vt==null?void 0:Vt.kind)===Z.Kind.ENUM_TYPE_DEFINITION){if(k.size<1&&!gt){if(l.isSubgraphVersionTwo){l.errors.push((0,de.nonExternalConditionalFieldError)(g,l.subgraphName,X,n,f));return}l.warnings.push((0,vs.nonExternalConditionalFieldWarning)(g,l.subgraphName,X,n,f));return}if(k.size<1&&zt){l.isSubgraphVersionTwo?K.push((0,de.fieldAlreadyProvidedErrorMessage)(X,l.subgraphName,f)):l.warnings.push((0,vs.fieldAlreadyProvidedWarning)(X,f,g,l.subgraphName));return}if(!Wt&&!i)return;let dn=(0,$e.getValueOrDefault)(l.conditionalFieldDataByCoords,X,Nn.newConditionalFieldData),Ar=(0,Qp.newFieldSetConditionData)({fieldCoordinatesPath:[...v],fieldPath:[...F]});i?dn.providedBy.push(Ar):dn.requiredBy.push(Ar);return}if(!Vt)return K.push((0,de.unknownTypeInFieldSetErrorMessage)(n,X,Dn)),Z.BREAK;if(gt&&(i&&(0,$e.getValueOrDefault)(l.conditionalFieldDataByCoords,X,Nn.newConditionalFieldData).providedBy.push((0,Qp.newFieldSetConditionData)({fieldCoordinatesPath:[...v],fieldPath:[...F]})),k.add(X)),Vt.kind===Z.Kind.OBJECT_TYPE_DEFINITION||Vt.kind===Z.Kind.INTERFACE_TYPE_DEFINITION||Vt.kind===Z.Kind.UNION_TYPE_DEFINITION){ne=!0,p.push(Vt);return}},leave(){k.delete(v.pop()||""),F.pop()}},InlineFragment:{enter(pe){let Fe=p[$],Ve=Fe.name,et=v.length<1?t.name:v[v.length-1];if(!pe.typeCondition)return K.push((0,de.inlineFragmentWithoutTypeConditionErrorMessage)(n,et)),Z.BREAK;let X=pe.typeCondition.name.value;if(X===Ve){p.push(Fe),ne=!0;return}if(!(0,On.isKindAbstract)(Fe.kind))return K.push((0,de.invalidInlineFragmentTypeErrorMessage)(n,v,X,Ve)),Z.BREAK;let ve=l.parentDefinitionDataByTypeName.get(X);if(!ve)return K.push((0,de.unknownInlineFragmentTypeConditionErrorMessage)(n,v,Ve,X)),Z.BREAK;switch(ne=!0,ve.kind){case Z.Kind.INTERFACE_TYPE_DEFINITION:{if(!ve.implementedInterfaceTypeNames.has(Ve))break;p.push(ve);return}case Z.Kind.OBJECT_TYPE_DEFINITION:{let gt=l.concreteTypeNamesByAbstractTypeName.get(Ve);if(!gt||!gt.has(X))break;p.push(ve);return}case Z.Kind.UNION_TYPE_DEFINITION:{p.push(ve);return}default:return K.push((0,de.invalidInlineFragmentTypeConditionTypeErrorMessage)(n,v,Ve,X,(0,$e.kindToNodeType)(ve.kind))),Z.BREAK}return K.push((0,de.invalidInlineFragmentTypeConditionErrorMessage)(n,v,X,(0,$e.kindToNodeType)(Fe.kind),Ve)),Z.BREAK}},SelectionSet:{enter(){if(!ne){let pe=p[$];if(pe.kind===Z.Kind.UNION_TYPE_DEFINITION)return K.push((0,de.unparsableFieldSetSelectionErrorMessage)(n,z)),Z.BREAK;let Fe=pe.fieldDataByName.get(z);if(!Fe)return K.push((0,de.undefinedFieldInFieldSetErrorMessage)(n,pe.name,z)),Z.BREAK;let Ve=(0,nr.getTypeNodeNamedTypeName)(Fe.node.type),et=l.parentDefinitionDataByTypeName.get(Ve),X=et?et.kind:Z.Kind.SCALAR_TYPE_DEFINITION;return K.push((0,de.invalidSelectionSetDefinitionErrorMessage)(n,v,Ve,(0,$e.kindToNodeType)(X))),Z.BREAK}if($+=1,ne=!1,$<0||$>=p.length)return K.push((0,de.unparsableFieldSetSelectionErrorMessage)(n,z)),Z.BREAK;y.push(new Set)},leave(){if(ne){let pe=p[$+1];K.push((0,de.invalidSelectionSetErrorMessage)(n,v,pe.name,(0,$e.kindToNodeType)(pe.kind))),ne=!1}$-=1,p.pop(),y.pop()}}}),K.length>0||!Te?{errorMessages:K}:{configuration:{fieldName:r,selectionSet:(0,ei.getNormalizedFieldSet)(c)},errorMessages:K}}validateProvidesOrRequires(t,n,r){let i=[],a=[],o=(0,Nn.getParentTypeName)(t);for(let[c,l]of n){let{fieldSetParentData:p,errorString:f}=this.getFieldSetParent(r,t,c,o),y=`${o}.${c}`;if(f){i.push(f);continue}if(!p)continue;let{errorMessages:g,configuration:v}=this.validateConditionalFieldSet(p,l,c,r,o);if(g.length>0){i.push(` On field "${y}": - -`+g.join(te.HYPHEN_JOIN));continue}v&&a.push(v)}if(i.length>0){this.errors.push((0,de.invalidProvidesOrRequiresDirectivesError)((0,ei.getConditionalFieldSetDirectiveName)(r),i));return}if(a.length>0)return a}validateInterfaceImplementations(t){if(t.implementedInterfaceTypeNames.size<1)return;let n=t.directivesByDirectiveName.has(te.INACCESSIBLE),r=new Map,i=new Map,a=!1;for(let o of t.implementedInterfaceTypeNames){let c=this.parentDefinitionDataByTypeName.get(o);if(Ht.BASE_SCALARS.has(o)&&this.referencedTypeNames.add(o),!c)continue;if(c.kind!==Z.Kind.INTERFACE_TYPE_DEFINITION){i.set(c.name,(0,$e.kindToNodeType)(c.kind));continue}if(t.name===c.name){a=!0;continue}let l={invalidFieldImplementations:new Map,unimplementedFields:[]},p=!1;for(let[f,y]of c.fieldDataByName){this.unvalidatedExternalFieldCoords.delete(`${t.name}.${f}`);let g=!1,v=t.fieldDataByName.get(f);if(!v){p=!0,l.unimplementedFields.push(f);continue}let F={invalidAdditionalArguments:new Set,invalidImplementedArguments:[],isInaccessible:!1,originalResponseType:(0,ma.printTypeNode)(y.node.type),unimplementedArguments:new Set};(0,Nn.isTypeValidImplementation)(y.node.type,v.node.type,this.concreteTypeNamesByAbstractTypeName)||(p=!0,g=!0,F.implementedResponseType=(0,ma.printTypeNode)(v.node.type));let k=new Set;for(let[K,$]of y.argumentDataByName){k.add(K);let ne=v.argumentDataByName.get(K);if(!ne){p=!0,g=!0,F.unimplementedArguments.add(K);continue}let z=(0,ma.printTypeNode)(ne.type),Te=(0,ma.printTypeNode)($.type);Te!==z&&(p=!0,g=!0,F.invalidImplementedArguments.push({actualType:z,argumentName:K,expectedType:Te}))}for(let[K,$]of v.argumentDataByName)k.has(K)||$.type.kind===Z.Kind.NON_NULL_TYPE&&(p=!0,g=!0,F.invalidAdditionalArguments.add(K));!n&&v.isInaccessible&&!y.isInaccessible&&(p=!0,g=!0,F.isInaccessible=!0),g&&l.invalidFieldImplementations.set(f,F)}p&&r.set(o,l)}i.size>0&&this.errors.push((0,de.invalidImplementedTypeError)(t.name,i)),a&&this.errors.push((0,de.selfImplementationError)(t.name)),r.size>0&&this.errors.push((0,de.invalidInterfaceImplementationError)(t.name,(0,$e.kindToNodeType)(t.kind),r))}handleAuthenticatedDirective(t,n){let r=(0,$e.getValueOrDefault)(this.authorizationDataByParentTypeName,n,()=>(0,rr.newAuthorizationData)(n));if(t.kind===Z.Kind.FIELD_DEFINITION){let i=(0,$e.getValueOrDefault)(r.fieldAuthDataByFieldName,t.name,()=>(0,rr.newFieldAuthorizationData)(t.name));i.inheritedData.requiresAuthentication=!0,i.originalData.requiresAuthentication=!0}else r.requiresAuthentication=!0,this.parentTypeNamesWithAuthDirectives.add(n)}handleOverrideDirective({data:t,directiveCoords:n,errorMessages:r,targetSubgraphName:i}){if(i===this.subgraphName){r.push((0,de.equivalentSourceAndTargetOverrideErrorMessage)(i,n));return}let a=(0,$e.getValueOrDefault)(this.overridesByTargetSubgraphName,i,()=>new Map);(0,$e.getValueOrDefault)(a,t.renamedParentTypeName,()=>new Set).add(t.name)}extractRequiredScopes({directiveCoords:t,orScopes:n,requiredScopes:r}){if(n.length>Ht.MAX_OR_SCOPES){this.invalidORScopesCoords.add(t);return}for(let i of n){let a=new Set;for(let o of i.values)a.add(o.value);a.size<1||(0,rr.addScopes)(r,a)}}getKafkaPublishConfiguration(t,n,r,i){let a=[],o=te.DEFAULT_EDFS_PROVIDER_ID;for(let c of t.arguments||[])switch(c.name.value){case te.TOPIC:{if(c.value.kind!==Z.Kind.STRING||c.value.value.length<1){i.push((0,de.invalidEventSubjectErrorMessage)(te.TOPIC));continue}(0,ei.validateArgumentTemplateReferences)(c.value.value,n,i),a.push(c.value.value);break}case te.PROVIDER_ID:{if(c.value.kind!==Z.Kind.STRING||c.value.value.length<1){i.push(de.invalidEventProviderIdErrorMessage);continue}o=c.value.value;break}}if(!(i.length>0))return{fieldName:r,providerId:o,providerType:te.PROVIDER_TYPE_KAFKA,topics:a,type:te.PUBLISH}}getKafkaSubscribeConfiguration(t,n,r,i){let a=[],o=te.DEFAULT_EDFS_PROVIDER_ID;for(let c of t.arguments||[])switch(c.name.value){case te.TOPICS:{if(c.value.kind!==Z.Kind.LIST){i.push((0,de.invalidEventSubjectsErrorMessage)(te.TOPICS));continue}for(let l of c.value.values){if(l.kind!==Z.Kind.STRING||l.value.length<1){i.push((0,de.invalidEventSubjectsItemErrorMessage)(te.TOPICS));break}(0,ei.validateArgumentTemplateReferences)(l.value,n,i),a.push(l.value)}break}case te.PROVIDER_ID:{if(c.value.kind!==Z.Kind.STRING||c.value.value.length<1){i.push(de.invalidEventProviderIdErrorMessage);continue}o=c.value.value;break}}if(!(i.length>0))return{fieldName:r,providerId:o,providerType:te.PROVIDER_TYPE_KAFKA,topics:a,type:te.SUBSCRIBE}}getNatsPublishAndRequestConfiguration(t,n,r,i,a){let o=[],c=te.DEFAULT_EDFS_PROVIDER_ID;for(let l of n.arguments||[])switch(l.name.value){case te.SUBJECT:{if(l.value.kind!==Z.Kind.STRING||l.value.value.length<1){a.push((0,de.invalidEventSubjectErrorMessage)(te.SUBJECT));continue}(0,ei.validateArgumentTemplateReferences)(l.value.value,r,a),o.push(l.value.value);break}case te.PROVIDER_ID:{if(l.value.kind!==Z.Kind.STRING||l.value.value.length<1){a.push(de.invalidEventProviderIdErrorMessage);continue}c=l.value.value;break}}if(!(a.length>0))return{fieldName:i,providerId:c,providerType:te.PROVIDER_TYPE_NATS,subjects:o,type:t}}getNatsSubscribeConfiguration(t,n,r,i){let a=[],o=te.DEFAULT_EDFS_PROVIDER_ID,c=AE.DEFAULT_CONSUMER_INACTIVE_THRESHOLD,l="",p="";for(let f of t.arguments||[])switch(f.name.value){case te.SUBJECTS:{if(f.value.kind!==Z.Kind.LIST){i.push((0,de.invalidEventSubjectsErrorMessage)(te.SUBJECTS));continue}for(let y of f.value.values){if(y.kind!==Z.Kind.STRING||y.value.length<1){i.push((0,de.invalidEventSubjectsItemErrorMessage)(te.SUBJECTS));break}(0,ei.validateArgumentTemplateReferences)(y.value,n,i),a.push(y.value)}break}case te.PROVIDER_ID:{if(f.value.kind!==Z.Kind.STRING||f.value.value.length<1){i.push(de.invalidEventProviderIdErrorMessage);continue}o=f.value.value;break}case te.STREAM_CONFIGURATION:{if(this.usesEdfsNatsStreamConfiguration=!0,f.value.kind!==Z.Kind.OBJECT||f.value.fields.length<1){i.push(de.invalidNatsStreamInputErrorMessage);continue}let y=!0,g=new Set,v=new Set(bE.STREAM_CONFIGURATION_FIELD_NAMES),F=new Set([te.CONSUMER_NAME,te.STREAM_NAME]),k=new Set,K=new Set;for(let $ of f.value.fields){let ne=$.name.value;if(!bE.STREAM_CONFIGURATION_FIELD_NAMES.has(ne)){g.add(ne),y=!1;continue}if(v.has(ne))v.delete(ne);else{k.add(ne),y=!1;continue}switch(F.has(ne)&&F.delete(ne),ne){case te.CONSUMER_NAME:if($.value.kind!=Z.Kind.STRING||$.value.value.length<1){K.add(ne),y=!1;continue}l=$.value.value;break;case te.STREAM_NAME:if($.value.kind!=Z.Kind.STRING||$.value.value.length<1){K.add(ne),y=!1;continue}p=$.value.value;break;case te.CONSUMER_INACTIVE_THRESHOLD:if($.value.kind!=Z.Kind.INT){i.push((0,de.invalidArgumentValueErrorMessage)((0,Z.print)($.value),"edfs__NatsStreamConfiguration","consumerInactiveThreshold",te.INT_SCALAR)),y=!1;continue}try{c=parseInt($.value.value,10)}catch(z){i.push((0,de.invalidArgumentValueErrorMessage)((0,Z.print)($.value),"edfs__NatsStreamConfiguration","consumerInactiveThreshold",te.INT_SCALAR)),y=!1}break}}(!y||F.size>0)&&i.push((0,de.invalidNatsStreamInputFieldsErrorMessage)([...F],[...k],[...K],[...g]))}}if(!(i.length>0))return c<0?(c=AE.DEFAULT_CONSUMER_INACTIVE_THRESHOLD,this.warnings.push((0,vs.consumerInactiveThresholdInvalidValueWarning)(this.subgraphName,`The value has been set to ${AE.DEFAULT_CONSUMER_INACTIVE_THRESHOLD}.`))):c>ule.MAX_INT32&&(c=0,this.warnings.push((0,vs.consumerInactiveThresholdInvalidValueWarning)(this.subgraphName,"The value has been set to 0. This means the consumer will remain indefinitely active until its manual deletion."))),x({fieldName:r,providerId:o,providerType:te.PROVIDER_TYPE_NATS,subjects:a,type:te.SUBSCRIBE},l&&p?{streamConfiguration:{consumerInactiveThreshold:c,consumerName:l,streamName:p}}:{})}getRedisPublishConfiguration(t,n,r,i){let a=[],o=te.DEFAULT_EDFS_PROVIDER_ID;for(let c of t.arguments||[])switch(c.name.value){case te.CHANNEL:{if(c.value.kind!==Z.Kind.STRING||c.value.value.length<1){i.push((0,de.invalidEventSubjectErrorMessage)(te.CHANNEL));continue}(0,ei.validateArgumentTemplateReferences)(c.value.value,n,i),a.push(c.value.value);break}case te.PROVIDER_ID:{if(c.value.kind!==Z.Kind.STRING||c.value.value.length<1){i.push(de.invalidEventProviderIdErrorMessage);continue}o=c.value.value;break}}if(!(i.length>0))return{fieldName:r,providerId:o,providerType:te.PROVIDER_TYPE_REDIS,channels:a,type:te.PUBLISH}}getRedisSubscribeConfiguration(t,n,r,i){let a=[],o=te.DEFAULT_EDFS_PROVIDER_ID;for(let c of t.arguments||[])switch(c.name.value){case te.CHANNELS:{if(c.value.kind!==Z.Kind.LIST){i.push((0,de.invalidEventSubjectsErrorMessage)(te.CHANNELS));continue}for(let l of c.value.values){if(l.kind!==Z.Kind.STRING||l.value.length<1){i.push((0,de.invalidEventSubjectsItemErrorMessage)(te.CHANNELS));break}(0,ei.validateArgumentTemplateReferences)(l.value,n,i),a.push(l.value)}break}case te.PROVIDER_ID:{if(c.value.kind!==Z.Kind.STRING||c.value.value.length<1){i.push(de.invalidEventProviderIdErrorMessage);continue}o=c.value.value;break}}if(!(i.length>0))return{fieldName:r,providerId:o,providerType:te.PROVIDER_TYPE_REDIS,channels:a,type:te.SUBSCRIBE}}validateSubscriptionFilterDirectiveLocation(t){if(!t.directives)return;let n=this.renamedParentTypeName||this.originalParentTypeName,r=`${n}.${t.name.value}`,i=this.getOperationTypeNodeForRootTypeName(n)===Z.OperationTypeNode.SUBSCRIPTION;for(let a of t.directives)if(a.name.value===te.SUBSCRIPTION_FILTER&&!i){this.errors.push((0,de.invalidSubscriptionFilterLocationError)(r));return}}extractEventDirectivesToConfiguration(t,n){if(!t.directives)return;let r=t.name.value,i=`${this.renamedParentTypeName||this.originalParentTypeName}.${r}`;for(let a of t.directives){let o=[],c;switch(a.name.value){case te.EDFS_KAFKA_PUBLISH:c=this.getKafkaPublishConfiguration(a,n,r,o);break;case te.EDFS_KAFKA_SUBSCRIBE:c=this.getKafkaSubscribeConfiguration(a,n,r,o);break;case te.EDFS_NATS_PUBLISH:{c=this.getNatsPublishAndRequestConfiguration(te.PUBLISH,a,n,r,o);break}case te.EDFS_NATS_REQUEST:{c=this.getNatsPublishAndRequestConfiguration(te.REQUEST,a,n,r,o);break}case te.EDFS_NATS_SUBSCRIBE:{c=this.getNatsSubscribeConfiguration(a,n,r,o);break}case te.EDFS_REDIS_PUBLISH:{c=this.getRedisPublishConfiguration(a,n,r,o);break}case te.EDFS_REDIS_SUBSCRIBE:{c=this.getRedisSubscribeConfiguration(a,n,r,o);break}default:continue}if(o.length>0){this.errors.push((0,de.invalidEventDirectiveError)(a.name.value,i,o));continue}c&&(0,$e.getValueOrDefault)(this.eventsConfigurations,this.renamedParentTypeName||this.originalParentTypeName,()=>[]).push(c)}}getValidEventsDirectiveNamesForOperationTypeNode(t){switch(t){case Z.OperationTypeNode.MUTATION:return new Set([te.EDFS_KAFKA_PUBLISH,te.EDFS_NATS_PUBLISH,te.EDFS_NATS_REQUEST,te.EDFS_REDIS_PUBLISH]);case Z.OperationTypeNode.QUERY:return new Set([te.EDFS_NATS_REQUEST]);case Z.OperationTypeNode.SUBSCRIPTION:return new Set([te.EDFS_KAFKA_SUBSCRIBE,te.EDFS_NATS_SUBSCRIBE,te.EDFS_REDIS_SUBSCRIBE])}}getOperationTypeNodeForRootTypeName(t){let n=this.operationTypeNodeByTypeName.get(t);if(n)return n;switch(t){case te.MUTATION:return Z.OperationTypeNode.MUTATION;case te.QUERY:return Z.OperationTypeNode.QUERY;case te.SUBSCRIPTION:return Z.OperationTypeNode.SUBSCRIPTION;default:return}}validateEventDrivenRootType(t,n,r,i){let a=this.getOperationTypeNodeForRootTypeName(t.name);if(!a){this.errors.push((0,de.invalidRootTypeError)(t.name));return}let o=this.getValidEventsDirectiveNamesForOperationTypeNode(a);for(let[c,l]of t.fieldDataByName){let p=`${l.originalParentTypeName}.${c}`,f=new Set;for(let K of bE.EVENT_DIRECTIVE_NAMES)l.directivesByDirectiveName.has(K)&&f.add(K);let y=new Set;for(let K of f)o.has(K)||y.add(K);if((f.size<1||y.size>0)&&n.set(p,{definesDirectives:f.size>0,invalidDirectiveNames:[...y]}),a===Z.OperationTypeNode.MUTATION){let K=(0,ma.printTypeNode)(l.type);K!==te.NON_NULLABLE_EDFS_PUBLISH_EVENT_RESULT&&i.set(p,K);continue}let g=(0,ma.printTypeNode)(l.type),v=l.namedTypeName+"!",F=!1,k=this.concreteTypeNamesByAbstractTypeName.get(l.namedTypeName)||new Set([l.namedTypeName]);for(let K of k)if(F||(F=this.entityDataByTypeName.has(K)),F)break;(!F||g!==v)&&r.set(p,g)}}validateEventDrivenKeyDefinition(t,n){let r=this.keyFieldSetDatasByTypeName.get(t);if(r)for(let[i,{isUnresolvable:a}]of r)a||(0,$e.getValueOrDefault)(n,t,()=>[]).push(i)}validateEventDrivenObjectFields(t,n,r,i){var a;for(let[o,c]of t){let l=`${c.originalParentTypeName}.${o}`;if(n.has(o)){(a=c.externalFieldDataBySubgraphName.get(this.subgraphName))!=null&&a.isDefinedExternal||r.set(l,o);continue}i.set(l,o)}}isEdfsPublishResultValid(){let t=this.parentDefinitionDataByTypeName.get(te.EDFS_PUBLISH_RESULT);if(!t)return!0;if(t.kind!==Z.Kind.OBJECT_TYPE_DEFINITION||t.fieldDataByName.size!=1)return!1;for(let[n,r]of t.fieldDataByName)if(r.argumentDataByName.size>0||n!==te.SUCCESS||(0,ma.printTypeNode)(r.type)!==te.NON_NULLABLE_BOOLEAN)return!1;return!0}isNatsStreamConfigurationInputObjectValid(t){if(t.kind!==Z.Kind.INPUT_OBJECT_TYPE_DEFINITION||t.inputValueDataByName.size!=3)return!1;for(let[n,r]of t.inputValueDataByName)switch(n){case te.CONSUMER_INACTIVE_THRESHOLD:{if((0,ma.printTypeNode)(r.type)!==te.NON_NULLABLE_INT||!r.defaultValue||r.defaultValue.kind!==Z.Kind.INT||r.defaultValue.value!==`${AE.DEFAULT_CONSUMER_INACTIVE_THRESHOLD}`)return!1;break}case te.CONSUMER_NAME:case te.STREAM_NAME:{if((0,ma.printTypeNode)(r.type)!==te.NON_NULLABLE_STRING)return!1;break}default:return!1}return!0}validateEventDrivenSubgraph(t){let n=[],r=new Map,i=new Map,a=new Map,o=new Map,c=new Map,l=new Map,p=new Set,f=new Set;for(let[y,g]of this.parentDefinitionDataByTypeName){if(y===te.EDFS_PUBLISH_RESULT||y===te.EDFS_NATS_STREAM_CONFIGURATION||g.kind!==Z.Kind.OBJECT_TYPE_DEFINITION)continue;if(g.isRootType){this.validateEventDrivenRootType(g,r,i,a);continue}let v=this.keyFieldNamesByParentTypeName.get(y);if(!v){f.add(y);continue}this.validateEventDrivenKeyDefinition(y,o),this.validateEventDrivenObjectFields(g.fieldDataByName,v,c,l)}if(this.isEdfsPublishResultValid()||n.push(de.invalidEdfsPublishResultObjectErrorMessage),this.edfsDirectiveReferences.has(te.EDFS_NATS_SUBSCRIBE)){let y=this.parentDefinitionDataByTypeName.get(te.EDFS_NATS_STREAM_CONFIGURATION);y&&this.usesEdfsNatsStreamConfiguration&&!this.isNatsStreamConfigurationInputObjectValid(y)&&n.push(de.invalidNatsStreamConfigurationDefinitionErrorMessage),this.parentDefinitionDataByTypeName.delete(te.EDFS_NATS_STREAM_CONFIGURATION),t.push(Ht.EDFS_NATS_STREAM_CONFIGURATION_DEFINITION)}this.referencedDirectiveNames.has(te.LINK)&&(t.push(Ht.LINK_DEFINITION),t.push(Ht.LINK_IMPORT_DEFINITION),t.push(Ht.LINK_PURPOSE_DEFINITION)),r.size>0&&n.push((0,de.invalidRootTypeFieldEventsDirectivesErrorMessage)(r)),a.size>0&&n.push((0,de.invalidEventDrivenMutationResponseTypeErrorMessage)(a)),i.size>0&&n.push((0,de.invalidRootTypeFieldResponseTypesEventDrivenErrorMessage)(i)),o.size>0&&n.push((0,de.invalidKeyFieldSetsEventDrivenErrorMessage)(o)),c.size>0&&n.push((0,de.nonExternalKeyFieldNamesEventDrivenErrorMessage)(c)),l.size>0&&n.push((0,de.nonKeyFieldNamesEventDrivenErrorMessage)(l)),p.size>0&&n.push((0,de.nonEntityObjectExtensionsEventDrivenErrorMessage)([...p])),f.size>0&&n.push((0,de.nonKeyComposingObjectTypeNamesEventDrivenErrorMessage)([...f])),n.length>0&&this.errors.push((0,de.invalidEventDrivenGraphError)(n))}validateUnionMembers(t){if(t.memberByMemberTypeName.size<1){this.errors.push((0,de.noDefinedUnionMembersError)(t.name));return}let n=[];for(let r of t.memberByMemberTypeName.keys()){let i=this.parentDefinitionDataByTypeName.get(r);i&&i.kind!==Z.Kind.OBJECT_TYPE_DEFINITION&&n.push(`"${r}", which is type "${(0,$e.kindToNodeType)(i.kind)}"`)}n.length>0&&this.errors.push((0,de.invalidUnionMemberTypeError)(t.name,n))}addConcreteTypeNamesForUnion(t){if(!t.types||t.types.length<1)return;let n=t.name.value;for(let r of t.types){let i=r.name.value;(0,$e.getValueOrDefault)(this.concreteTypeNamesByAbstractTypeName,n,()=>new Set).add(i),this.internalGraph.addEdge(this.internalGraph.addOrUpdateNode(n,{isAbstract:!0}),this.internalGraph.addOrUpdateNode(i),i,!0)}}addValidKeyFieldSetConfigurations(){for(let[t,n]of this.keyFieldSetDatasByTypeName){let r=this.parentDefinitionDataByTypeName.get(t);if(!r||r.kind!==Z.Kind.OBJECT_TYPE_DEFINITION&&r.kind!==Z.Kind.INTERFACE_TYPE_DEFINITION){this.errors.push((0,de.undefinedCompositeOutputTypeError)(t));continue}let i=(0,Nn.getParentTypeName)(r),a=(0,$e.getValueOrDefault)(this.configurationDataByTypeName,i,()=>(0,Qp.newConfigurationData)(!0,i)),o=(0,ei.validateKeyFieldSets)(this,r,n);o&&(a.keys=o)}}getValidFlattenedDirectiveArray(t,n,r=!1){let i=[];for(let[a,o]of t){if(r&&te.INHERITABLE_DIRECTIVE_NAMES.has(a))continue;let c=this.directiveDefinitionDataByDirectiveName.get(a);if(!c)continue;if(!c.isRepeatable&&o.length>1){let f=(0,$e.getValueOrDefault)(this.invalidRepeatedDirectiveNameByCoords,n,()=>new Set);f.has(a)||(f.add(a),this.errors.push((0,de.invalidDirectiveError)(a,n,"1st",[(0,de.invalidRepeatedDirectiveErrorMessage)(a)])));continue}if(a!==te.KEY){i.push(...o);continue}let l=[],p=new Set;for(let f=0;fnew Set).add(k)),(0,$e.getValueOrDefault)(a.keyFieldNamesByParentTypeName,v,()=>new Set).add(F);let ne=(0,nr.getTypeNodeNamedTypeName)(K.node.type);if(Ht.BASE_SCALARS.has(ne))return;let z=a.parentDefinitionDataByTypeName.get(ne);if(!z)return Z.BREAK;if(z.kind===Z.Kind.OBJECT_TYPE_DEFINITION){f=!0,c.push(z);return}if((0,On.isKindAbstract)(z.kind))return Z.BREAK}},InlineFragment:{enter(){return Z.BREAK}},SelectionSet:{enter(){if(!f||(p+=1,f=!1,p<0||p>=c.length))return Z.BREAK},leave(){f&&(f=!1),p-=1,c.pop()}}}),!(l.size<1))for(let[y,g]of l)this.warnings.push((0,vs.externalEntityExtensionKeyFieldWarning)(i.name,y,[...g],this.subgraphName))}}for(let n of t)this.keyFieldSetDatasByTypeName.delete(n)}addValidConditionalFieldSetConfigurations(){for(let[t,n]of this.fieldSetDataByTypeName){let r=this.parentDefinitionDataByTypeName.get(t);if(!r||r.kind!==Z.Kind.OBJECT_TYPE_DEFINITION&&r.kind!==Z.Kind.INTERFACE_TYPE_DEFINITION){this.errors.push((0,de.undefinedCompositeOutputTypeError)(t));continue}let i=(0,Nn.getParentTypeName)(r),a=(0,$e.getValueOrDefault)(this.configurationDataByTypeName,i,()=>(0,Qp.newConfigurationData)(!1,i)),o=this.validateProvidesOrRequires(r,n.provides,!0);o&&(a.provides=o);let c=this.validateProvidesOrRequires(r,n.requires,!1);c&&(a.requires=c)}}addFieldNamesToConfigurationData(t,n){let r=new Set;for(let[i,a]of t){let o=a.externalFieldDataBySubgraphName.get(this.subgraphName);if(!o||o.isUnconditionallyProvided){n.fieldNames.add(i);continue}r.add(i),this.edfsDirectiveReferences.size>0&&n.fieldNames.add(i)}r.size>0&&(n.externalFieldNames=r)}normalize(t){var a;(0,$q.upsertDirectiveSchemaAndEntityDefinitions)(this,t),(0,$q.upsertParentsAndChildren)(this,t),this.validateDirectives(this.schemaData,te.SCHEMA);for(let[o,c]of this.parentDefinitionDataByTypeName)this.validateDirectives(c,o);this.invalidORScopesCoords.size>0&&this.errors.push((0,de.orScopesLimitError)(Ht.MAX_OR_SCOPES,[...this.invalidORScopesCoords]));let n=[];for(let o of Ht.BASE_DIRECTIVE_DEFINITIONS)n.push(o);if(n.push(Ht.FIELD_SET_SCALAR_DEFINITION),this.isSubgraphVersionTwo){for(let o of Ht.VERSION_TWO_DIRECTIVE_DEFINITIONS)n.push(o),this.directiveDefinitionByDirectiveName.set(o.name.value,o);n.push(Ht.SCOPE_SCALAR_DEFINITION)}for(let o of this.edfsDirectiveReferences){let c=Ht.EVENT_DRIVEN_DIRECTIVE_DEFINITIONS_BY_DIRECTIVE_NAME.get(o);if(!c){this.errors.push((0,de.invalidEdfsDirectiveName)(o));continue}n.push(c)}this.edfsDirectiveReferences.size>0&&this.referencedDirectiveNames.has(te.SUBSCRIPTION_FILTER)&&(n.push(Ht.SUBSCRIPTION_FILTER_DEFINITION),n.push(Ht.SUBSCRIPTION_FILTER_CONDITION_DEFINITION),n.push(Ht.SUBSCRIPTION_FIELD_CONDITION_DEFINITION),n.push(Ht.SUBSCRIPTION_FILTER_VALUE_DEFINITION)),this.referencedDirectiveNames.has(te.CONFIGURE_DESCRIPTION)&&n.push(Ht.CONFIGURE_DESCRIPTION_DEFINITION),this.referencedDirectiveNames.has(te.CONFIGURE_CHILD_DESCRIPTIONS)&&n.push(Ht.CONFIGURE_CHILD_DESCRIPTIONS_DEFINITION);for(let o of this.customDirectiveDefinitions.values())n.push(o);this.schemaData.operationTypes.size>0&&n.push(this.getSchemaNodeByData(this.schemaData));for(let o of this.invalidConfigureDescriptionNodeDatas)o.description||this.errors.push((0,de.configureDescriptionNoDescriptionError)((0,$e.kindToNodeType)(o.kind),o.name));this.evaluateExternalKeyFields();for(let[o,c]of this.parentDefinitionDataByTypeName)switch(c.kind){case Z.Kind.ENUM_TYPE_DEFINITION:if(c.enumValueDataByValueName.size<1){this.errors.push((0,de.noDefinedEnumValuesError)(o));break}n.push(this.getEnumNodeByData(c));break;case Z.Kind.INPUT_OBJECT_TYPE_DEFINITION:if(c.inputValueDataByName.size<1){this.errors.push((0,de.noInputValueDefinitionsError)(o));break}for(let K of c.inputValueDataByName.values()){if(K.namedTypeKind!==Z.Kind.NULL)continue;let $=this.parentDefinitionDataByTypeName.get(K.namedTypeName);if($){if(!(0,Nn.isInputNodeKind)($.kind)){this.errors.push((0,de.invalidNamedTypeError)({data:K,namedTypeData:$,nodeType:`${(0,$e.kindToNodeType)(c.kind)} field`}));continue}K.namedTypeKind=$.kind}}n.push(this.getInputObjectNodeByData(c));break;case Z.Kind.INTERFACE_TYPE_DEFINITION:case Z.Kind.OBJECT_TYPE_DEFINITION:let l=this.entityDataByTypeName.has(o),p=this.operationTypeNodeByTypeName.get(o),f=c.kind===Z.Kind.OBJECT_TYPE_DEFINITION;this.isSubgraphVersionTwo&&c.extensionType===Ga.ExtensionType.EXTENDS&&(c.extensionType=Ga.ExtensionType.NONE),p&&(c.fieldDataByName.delete(te.SERVICE_FIELD),c.fieldDataByName.delete(te.ENTITIES_FIELD));let y=[];for(let[K,$]of c.fieldDataByName){if(!f&&((a=$.externalFieldDataBySubgraphName.get(this.subgraphName))!=null&&a.isDefinedExternal)&&y.push(K),this.validateArguments($,c.kind),$.namedTypeKind!==Z.Kind.NULL)continue;let ne=this.parentDefinitionDataByTypeName.get($.namedTypeName);if(ne){if(!(0,Nn.isOutputNodeKind)(ne.kind)){this.errors.push((0,de.invalidNamedTypeError)({data:$,namedTypeData:ne,nodeType:`${(0,$e.kindToNodeType)(c.kind)} field`}));continue}$.namedTypeKind=this.entityInterfaceDataByTypeName.get(ne.name)?Z.Kind.INTERFACE_TYPE_DEFINITION:ne.kind}}y.length>0&&(this.isSubgraphVersionTwo?this.errors.push((0,de.externalInterfaceFieldsError)(o,y)):this.warnings.push((0,vs.externalInterfaceFieldsWarning)(this.subgraphName,o,y)));let g=(0,Nn.getParentTypeName)(c),v=(0,$e.getValueOrDefault)(this.configurationDataByTypeName,g,()=>(0,Qp.newConfigurationData)(l,o)),F=this.entityInterfaceDataByTypeName.get(o);if(F){F.fieldDatas=(0,rr.fieldDatasToSimpleFieldDatas)(c.fieldDataByName.values());let K=this.concreteTypeNamesByAbstractTypeName.get(o);K&&(0,$e.addIterableValuesToSet)(K,F.concreteTypeNames),v.isInterfaceObject=F.isInterfaceObject,v.entityInterfaceConcreteTypeNames=F.concreteTypeNames}let k=this.eventsConfigurations.get(g);k&&(v.events=k),this.addFieldNamesToConfigurationData(c.fieldDataByName,v),this.validateInterfaceImplementations(c),n.push(this.getCompositeOutputNodeByData(c)),c.fieldDataByName.size<1&&!(0,ei.isNodeQuery)(o,p)&&this.errors.push((0,de.noFieldDefinitionsError)((0,$e.kindToNodeType)(c.kind),o));break;case Z.Kind.SCALAR_TYPE_DEFINITION:if(c.extensionType===Ga.ExtensionType.REAL){this.errors.push((0,de.noBaseScalarDefinitionError)(o));break}n.push(this.getScalarNodeByData(c));break;case Z.Kind.UNION_TYPE_DEFINITION:n.push(this.getUnionNodeByData(c)),this.validateUnionMembers(c);break;default:throw(0,de.unexpectedKindFatalError)(o)}this.addValidConditionalFieldSetConfigurations(),this.addValidKeyFieldSetConfigurations();for(let o of Object.values(Z.OperationTypeNode)){let c=this.schemaData.operationTypes.get(o),l=(0,$e.getOrThrowError)(On.operationTypeNodeToDefaultType,o,te.OPERATION_TO_DEFAULT),p=c?(0,nr.getTypeNodeNamedTypeName)(c.type):l;if(Ht.BASE_SCALARS.has(p)&&this.referencedTypeNames.add(p),p!==l&&this.parentDefinitionDataByTypeName.has(l)){this.errors.push((0,de.invalidRootTypeDefinitionError)(o,p,l));continue}let f=this.parentDefinitionDataByTypeName.get(p);if(c){if(!f)continue;this.operationTypeNodeByTypeName.set(p,o)}if(!f)continue;let y=this.configurationDataByTypeName.get(l);y&&(y.isRootNode=!0,y.typeName=l),f.kind!==Z.Kind.OBJECT_TYPE_DEFINITION&&this.errors.push((0,de.operationDefinitionError)(p,o,f.kind))}for(let o of this.referencedTypeNames){let c=this.parentDefinitionDataByTypeName.get(o);if(!c){this.errors.push((0,de.undefinedTypeError)(o));continue}if(c.kind!==Z.Kind.INTERFACE_TYPE_DEFINITION)continue;let l=this.concreteTypeNamesByAbstractTypeName.get(o);(!l||l.size<0)&&this.warnings.push((0,vs.unimplementedInterfaceOutputTypeWarning)(this.subgraphName,o))}let r=new Map;for(let o of this.directiveDefinitionByDirectiveName.values()){let c=(0,On.extractExecutableDirectiveLocations)(o.locations,new Set);c.size<1||this.addPersistedDirectiveDefinitionDataByNode(r,o,c)}this.isSubgraphEventDrivenGraph=this.edfsDirectiveReferences.size>0,this.isSubgraphEventDrivenGraph&&this.validateEventDrivenSubgraph(n);for(let o of this.unvalidatedExternalFieldCoords)this.isSubgraphVersionTwo?this.errors.push((0,de.invalidExternalDirectiveError)(o)):this.warnings.push((0,vs.invalidExternalFieldWarning)(o,this.subgraphName));if(this.errors.length>0)return{success:!1,errors:this.errors,warnings:this.warnings};let i={kind:Z.Kind.DOCUMENT,definitions:n};return{authorizationDataByParentTypeName:this.authorizationDataByParentTypeName,concreteTypeNamesByAbstractTypeName:this.concreteTypeNamesByAbstractTypeName,conditionalFieldDataByCoordinates:this.conditionalFieldDataByCoords,configurationDataByTypeName:this.configurationDataByTypeName,entityDataByTypeName:this.entityDataByTypeName,entityInterfaces:this.entityInterfaceDataByTypeName,fieldCoordsByNamedTypeName:this.fieldCoordsByNamedTypeName,isEventDrivenGraph:this.isSubgraphEventDrivenGraph,isVersionTwo:this.isSubgraphVersionTwo,keyFieldNamesByParentTypeName:this.keyFieldNamesByParentTypeName,keyFieldSetsByEntityTypeNameByKeyFieldCoords:this.keyFieldSetsByEntityTypeNameByFieldCoords,operationTypes:this.operationTypeNodeByTypeName,originalTypeNameByRenamedTypeName:this.originalTypeNameByRenamedTypeName,overridesByTargetSubgraphName:this.overridesByTargetSubgraphName,parentDefinitionDataByTypeName:this.parentDefinitionDataByTypeName,persistedDirectiveDefinitionDataByDirectiveName:r,subgraphAST:i,subgraphString:(0,Z.print)(i),schema:(0,sle.buildASTSchema)(i,{assumeValid:!0,assumeValidSDL:!0}),success:!0,warnings:this.warnings}}};hc.NormalizationFactory=Yp;function lle(e){let t=new Map,n=new Map,r=new Map,i=new Map,a=new Map,o=new Map,c=new Set,l=new Map,p=new Set,f=new Set,y=[],g=new Set,v=new Map,F=[],k=[];for(let ne of e)ne.name&&(0,ole.recordSubgraphName)(ne.name,p,f);let K=new zO.Graph;for(let ne=0;ne0&&F.push(...pe.warnings),!pe.success){k.push((0,de.subgraphValidationError)(Te,pe.errors));continue}if(!pe){k.push((0,de.subgraphValidationError)(Te,[de.subgraphValidationFailureError]));continue}l.set(Te,pe.parentDefinitionDataByTypeName);for(let Fe of pe.authorizationDataByParentTypeName.values())(0,rr.upsertAuthorizationData)(t,Fe,g);for(let[Fe,Ve]of pe.fieldCoordsByNamedTypeName)(0,$e.addIterableValuesToSet)(Ve,(0,$e.getValueOrDefault)(v,Fe,()=>new Set));for(let[Fe,Ve]of pe.concreteTypeNamesByAbstractTypeName){let et=n.get(Fe);if(!et){n.set(Fe,new Set(Ve));continue}(0,$e.addIterableValuesToSet)(Ve,et)}for(let[Fe,Ve]of pe.entityDataByTypeName){let et=Ve.keyFieldSetDatasBySubgraphName.get(Te);et&&(0,rr.upsertEntityData)({entityDataByTypeName:r,keyFieldSetDataByFieldSet:et,typeName:Fe,subgraphName:Te})}if(z.name&&i.set(Te,{conditionalFieldDataByCoordinates:pe.conditionalFieldDataByCoordinates,configurationDataByTypeName:pe.configurationDataByTypeName,definitions:pe.subgraphAST,entityInterfaces:pe.entityInterfaces,isVersionTwo:pe.isVersionTwo,keyFieldNamesByParentTypeName:pe.keyFieldNamesByParentTypeName,name:Te,operationTypes:pe.operationTypes,overriddenFieldNamesByParentTypeName:new Map,parentDefinitionDataByTypeName:pe.parentDefinitionDataByTypeName,persistedDirectiveDefinitionDataByDirectiveName:pe.persistedDirectiveDefinitionDataByDirectiveName,schema:pe.schema,url:z.url}),!(pe.overridesByTargetSubgraphName.size<1))for(let[Fe,Ve]of pe.overridesByTargetSubgraphName){let et=p.has(Fe);for(let[X,ve]of Ve){let gt=pe.originalTypeNameByRenamedTypeName.get(X)||X;if(!et)F.push((0,vs.invalidOverrideTargetSubgraphNameWarning)(Fe,gt,[...ve],z.name));else{let zt=(0,$e.getValueOrDefault)(a,Fe,()=>new Map),Wt=(0,$e.getValueOrDefault)(zt,X,()=>new Set(ve));(0,$e.addIterableValuesToSet)(ve,Wt)}for(let zt of ve){let Wt=`${gt}.${zt}`,Dn=o.get(Wt);if(!Dn){o.set(Wt,[Te]);continue}Dn.push(Te),c.add(Wt)}}}}let $=[];if(g.size>0&&$.push((0,de.orScopesLimitError)(Ht.MAX_OR_SCOPES,[...g])),(y.length>0||f.size>0)&&$.push((0,de.invalidSubgraphNamesError)([...f],y)),c.size>0){let ne=[];for(let z of c){let Te=(0,$e.getOrThrowError)(o,z,"overrideSourceSubgraphNamesByFieldPath");ne.push((0,de.duplicateOverriddenFieldErrorMessage)(z,Te))}$.push((0,de.duplicateOverriddenFieldsError)(ne))}if($.push(...k),$.length>0)return{errors:$,success:!1,warnings:F};for(let[ne,z]of a){let Te=(0,$e.getOrThrowError)(i,ne,"internalSubgraphBySubgraphName");Te.overriddenFieldNamesByParentTypeName=z;for(let[pe,Fe]of z){let Ve=Te.configurationDataByTypeName.get(pe);Ve&&((0,rr.subtractSet)(Fe,Ve.fieldNames),Ve.fieldNames.size<1&&Te.configurationDataByTypeName.delete(pe))}}return{authorizationDataByParentTypeName:t,concreteTypeNamesByAbstractTypeName:n,entityDataByTypeName:r,fieldCoordsByNamedTypeName:v,internalSubgraphBySubgraphName:i,internalGraph:K,success:!0,warnings:F}}});var RE=w(gc=>{"use strict";m();T();N();Object.defineProperty(gc,"__esModule",{value:!0});gc.DivergentType=void 0;gc.getLeastRestrictiveMergedTypeNode=ple;gc.getMostRestrictiveMergedTypeNode=fle;gc.renameNamedTypeName=mle;var yc=Ae(),Jq=ia(),dle=ou(),Yq=Yr(),Hq=Nl(),Ic;(function(e){e[e.NONE=0]="NONE",e[e.CURRENT=1]="CURRENT",e[e.OTHER=2]="OTHER"})(Ic||(gc.DivergentType=Ic={}));function zq(e,t,n,r,i){t=(0,dle.getMutableTypeNode)(t,n,i);let a={kind:e.kind},o=Ic.NONE,c=a;for(let l=0;l{"use strict";m();T();N();Object.defineProperty(ZO,"__esModule",{value:!0});ZO.renameRootTypes=Ele;var Nle=Ae(),XO=Yr(),Tle=RE(),hu=ur(),_c=Jr();function Ele(e,t){let n,r=!1,i;(0,Nle.visit)(t.definitions,{FieldDefinition:{enter(a){let o=a.name.value;if(r&&(o===hu.SERVICE_FIELD||o===hu.ENTITIES_FIELD))return n.fieldDataByName.delete(o),!1;let c=n.name,l=(0,_c.getOrThrowError)(n.fieldDataByName,o,`${c}.fieldDataByFieldName`),p=t.operationTypes.get(l.namedTypeName);if(p){let f=(0,_c.getOrThrowError)(XO.operationTypeNodeToDefaultType,p,hu.OPERATION_TO_DEFAULT);l.namedTypeName!==f&&(0,Tle.renameNamedTypeName)(l,f,e.errors)}return i!=null&&i.has(o)&&l.isShareableBySubgraphName.delete(t.name),!1}},InterfaceTypeDefinition:{enter(a){let o=a.name.value;if(!e.entityInterfaceFederationDataByTypeName.get(o))return!1;n=(0,_c.getOrThrowError)(t.parentDefinitionDataByTypeName,o,hu.PARENT_DEFINITION_DATA)},leave(){n=void 0}},ObjectTypeDefinition:{enter(a){let o=a.name.value,c=t.operationTypes.get(o),l=c?(0,_c.getOrThrowError)(XO.operationTypeNodeToDefaultType,c,hu.OPERATION_TO_DEFAULT):o;n=(0,_c.getOrThrowError)(t.parentDefinitionDataByTypeName,o,hu.PARENT_DEFINITION_DATA),r=n.isRootType,!e.entityInterfaceFederationDataByTypeName.get(o)&&(e.addValidPrimaryKeyTargetsToEntityData(o),i=t.overriddenFieldNamesByParentTypeName.get(l),o!==l&&(n.name=l,t.parentDefinitionDataByTypeName.set(l,n),t.parentDefinitionDataByTypeName.delete(o)))},leave(){n=void 0,r=!1,i=void 0}},ObjectTypeExtension:{enter(a){let o=a.name.value,c=t.operationTypes.get(o),l=c?(0,_c.getOrThrowError)(XO.operationTypeNodeToDefaultType,c,hu.OPERATION_TO_DEFAULT):o;n=(0,_c.getOrThrowError)(t.parentDefinitionDataByTypeName,o,hu.PARENT_DEFINITION_DATA),r=n.isRootType,e.addValidPrimaryKeyTargetsToEntityData(o),i=t.overriddenFieldNamesByParentTypeName.get(o),o!==l&&(n.name=l,t.parentDefinitionDataByTypeName.set(l,n),t.parentDefinitionDataByTypeName.delete(o))},leave(){n=void 0,r=!1,i=void 0}}})}});var Wq=w((Yl,Jp)=>{"use strict";m();T();N();(function(){var e,t="4.17.21",n=200,r="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",i="Expected a function",a="Invalid `variable` option passed into `_.template`",o="__lodash_hash_undefined__",c=500,l="__lodash_placeholder__",p=1,f=2,y=4,g=1,v=2,F=1,k=2,K=4,$=8,ne=16,z=32,Te=64,pe=128,Fe=256,Ve=512,et=30,X="...",ve=800,gt=16,zt=1,Wt=2,Dn=3,Vt=1/0,dn=9007199254740991,Ar=17976931348623157e292,Rr=NaN,Un=4294967295,$t=Un-1,bn=Un>>>1,oe=[["ary",pe],["bind",F],["bindKey",k],["curry",$],["curryRight",ne],["flip",Ve],["partial",z],["partialRight",Te],["rearg",Fe]],De="[object Arguments]",_e="[object Array]",Ce="[object AsyncFunction]",_t="[object Boolean]",J="[object Date]",se="[object DOMException]",xe="[object Error]",Qe="[object Function]",Lt="[object GeneratorFunction]",tt="[object Map]",At="[object Number]",Ha="[object Null]",xr="[object Object]",za="[object Promise]",Lc="[object Proxy]",ha="[object RegExp]",pr="[object Set]",ni="[object String]",xt="[object Symbol]",fr="[object Undefined]",_u="[object WeakMap]",ya="[object WeakSet]",vu="[object ArrayBuffer]",A="[object DataView]",h="[object Float32Array]",I="[object Float64Array]",C="[object Int8Array]",G="[object Int16Array]",re="[object Int32Array]",le="[object Uint8Array]",ft="[object Uint8ClampedArray]",pn="[object Uint16Array]",tn="[object Uint32Array]",hn=/\b__p \+= '';/g,Xt=/\b(__p \+=) '' \+/g,D1=/(__e\(.*?\)|\b__t\)) \+\n'';/g,eb=/&(?:amp|lt|gt|quot|#39);/g,tb=/[&<>"']/g,b1=RegExp(eb.source),A1=RegExp(tb.source),R1=/<%-([\s\S]+?)%>/g,P1=/<%([\s\S]+?)%>/g,nb=/<%=([\s\S]+?)%>/g,F1=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,w1=/^\w*$/,L1=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,uh=/[\\^$.*+?()[\]{}|]/g,C1=RegExp(uh.source),ch=/^\s+/,B1=/\s/,U1=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,k1=/\{\n\/\* \[wrapped with (.+)\] \*/,M1=/,? & /,x1=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,q1=/[()=,{}\[\]\/\s]/,V1=/\\(\\)?/g,j1=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,rb=/\w*$/,K1=/^[-+]0x[0-9a-f]+$/i,G1=/^0b[01]+$/i,$1=/^\[object .+?Constructor\]$/,Q1=/^0o[0-7]+$/i,Y1=/^(?:0|[1-9]\d*)$/,J1=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,hf=/($^)/,H1=/['\n\r\u2028\u2029\\]/g,yf="\\ud800-\\udfff",z1="\\u0300-\\u036f",W1="\\ufe20-\\ufe2f",X1="\\u20d0-\\u20ff",ib=z1+W1+X1,ab="\\u2700-\\u27bf",sb="a-z\\xdf-\\xf6\\xf8-\\xff",Z1="\\xac\\xb1\\xd7\\xf7",ej="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",tj="\\u2000-\\u206f",nj=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",ob="A-Z\\xc0-\\xd6\\xd8-\\xde",ub="\\ufe0e\\ufe0f",cb=Z1+ej+tj+nj,lh="['\u2019]",rj="["+yf+"]",lb="["+cb+"]",If="["+ib+"]",db="\\d+",ij="["+ab+"]",pb="["+sb+"]",fb="[^"+yf+cb+db+ab+sb+ob+"]",dh="\\ud83c[\\udffb-\\udfff]",aj="(?:"+If+"|"+dh+")",mb="[^"+yf+"]",ph="(?:\\ud83c[\\udde6-\\uddff]){2}",fh="[\\ud800-\\udbff][\\udc00-\\udfff]",Cc="["+ob+"]",Nb="\\u200d",Tb="(?:"+pb+"|"+fb+")",sj="(?:"+Cc+"|"+fb+")",Eb="(?:"+lh+"(?:d|ll|m|re|s|t|ve))?",hb="(?:"+lh+"(?:D|LL|M|RE|S|T|VE))?",yb=aj+"?",Ib="["+ub+"]?",oj="(?:"+Nb+"(?:"+[mb,ph,fh].join("|")+")"+Ib+yb+")*",uj="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",cj="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",gb=Ib+yb+oj,lj="(?:"+[ij,ph,fh].join("|")+")"+gb,dj="(?:"+[mb+If+"?",If,ph,fh,rj].join("|")+")",pj=RegExp(lh,"g"),fj=RegExp(If,"g"),mh=RegExp(dh+"(?="+dh+")|"+dj+gb,"g"),mj=RegExp([Cc+"?"+pb+"+"+Eb+"(?="+[lb,Cc,"$"].join("|")+")",sj+"+"+hb+"(?="+[lb,Cc+Tb,"$"].join("|")+")",Cc+"?"+Tb+"+"+Eb,Cc+"+"+hb,cj,uj,db,lj].join("|"),"g"),Nj=RegExp("["+Nb+yf+ib+ub+"]"),Tj=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Ej=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],hj=-1,Tn={};Tn[h]=Tn[I]=Tn[C]=Tn[G]=Tn[re]=Tn[le]=Tn[ft]=Tn[pn]=Tn[tn]=!0,Tn[De]=Tn[_e]=Tn[vu]=Tn[_t]=Tn[A]=Tn[J]=Tn[xe]=Tn[Qe]=Tn[tt]=Tn[At]=Tn[xr]=Tn[ha]=Tn[pr]=Tn[ni]=Tn[_u]=!1;var fn={};fn[De]=fn[_e]=fn[vu]=fn[A]=fn[_t]=fn[J]=fn[h]=fn[I]=fn[C]=fn[G]=fn[re]=fn[tt]=fn[At]=fn[xr]=fn[ha]=fn[pr]=fn[ni]=fn[xt]=fn[le]=fn[ft]=fn[pn]=fn[tn]=!0,fn[xe]=fn[Qe]=fn[_u]=!1;var yj={\u00C0:"A",\u00C1:"A",\u00C2:"A",\u00C3:"A",\u00C4:"A",\u00C5:"A",\u00E0:"a",\u00E1:"a",\u00E2:"a",\u00E3:"a",\u00E4:"a",\u00E5:"a",\u00C7:"C",\u00E7:"c",\u00D0:"D",\u00F0:"d",\u00C8:"E",\u00C9:"E",\u00CA:"E",\u00CB:"E",\u00E8:"e",\u00E9:"e",\u00EA:"e",\u00EB:"e",\u00CC:"I",\u00CD:"I",\u00CE:"I",\u00CF:"I",\u00EC:"i",\u00ED:"i",\u00EE:"i",\u00EF:"i",\u00D1:"N",\u00F1:"n",\u00D2:"O",\u00D3:"O",\u00D4:"O",\u00D5:"O",\u00D6:"O",\u00D8:"O",\u00F2:"o",\u00F3:"o",\u00F4:"o",\u00F5:"o",\u00F6:"o",\u00F8:"o",\u00D9:"U",\u00DA:"U",\u00DB:"U",\u00DC:"U",\u00F9:"u",\u00FA:"u",\u00FB:"u",\u00FC:"u",\u00DD:"Y",\u00FD:"y",\u00FF:"y",\u00C6:"Ae",\u00E6:"ae",\u00DE:"Th",\u00FE:"th",\u00DF:"ss",\u0100:"A",\u0102:"A",\u0104:"A",\u0101:"a",\u0103:"a",\u0105:"a",\u0106:"C",\u0108:"C",\u010A:"C",\u010C:"C",\u0107:"c",\u0109:"c",\u010B:"c",\u010D:"c",\u010E:"D",\u0110:"D",\u010F:"d",\u0111:"d",\u0112:"E",\u0114:"E",\u0116:"E",\u0118:"E",\u011A:"E",\u0113:"e",\u0115:"e",\u0117:"e",\u0119:"e",\u011B:"e",\u011C:"G",\u011E:"G",\u0120:"G",\u0122:"G",\u011D:"g",\u011F:"g",\u0121:"g",\u0123:"g",\u0124:"H",\u0126:"H",\u0125:"h",\u0127:"h",\u0128:"I",\u012A:"I",\u012C:"I",\u012E:"I",\u0130:"I",\u0129:"i",\u012B:"i",\u012D:"i",\u012F:"i",\u0131:"i",\u0134:"J",\u0135:"j",\u0136:"K",\u0137:"k",\u0138:"k",\u0139:"L",\u013B:"L",\u013D:"L",\u013F:"L",\u0141:"L",\u013A:"l",\u013C:"l",\u013E:"l",\u0140:"l",\u0142:"l",\u0143:"N",\u0145:"N",\u0147:"N",\u014A:"N",\u0144:"n",\u0146:"n",\u0148:"n",\u014B:"n",\u014C:"O",\u014E:"O",\u0150:"O",\u014D:"o",\u014F:"o",\u0151:"o",\u0154:"R",\u0156:"R",\u0158:"R",\u0155:"r",\u0157:"r",\u0159:"r",\u015A:"S",\u015C:"S",\u015E:"S",\u0160:"S",\u015B:"s",\u015D:"s",\u015F:"s",\u0161:"s",\u0162:"T",\u0164:"T",\u0166:"T",\u0163:"t",\u0165:"t",\u0167:"t",\u0168:"U",\u016A:"U",\u016C:"U",\u016E:"U",\u0170:"U",\u0172:"U",\u0169:"u",\u016B:"u",\u016D:"u",\u016F:"u",\u0171:"u",\u0173:"u",\u0174:"W",\u0175:"w",\u0176:"Y",\u0177:"y",\u0178:"Y",\u0179:"Z",\u017B:"Z",\u017D:"Z",\u017A:"z",\u017C:"z",\u017E:"z",\u0132:"IJ",\u0133:"ij",\u0152:"Oe",\u0153:"oe",\u0149:"'n",\u017F:"s"},Ij={"&":"&","<":"<",">":">",'"':""","'":"'"},gj={"&":"&","<":"<",">":">",""":'"',"'":"'"},_j={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},vj=parseFloat,Sj=parseInt,_b=typeof global=="object"&&global&&global.Object===Object&&global,Oj=typeof self=="object"&&self&&self.Object===Object&&self,ir=_b||Oj||Function("return this")(),Nh=typeof Yl=="object"&&Yl&&!Yl.nodeType&&Yl,Su=Nh&&typeof Jp=="object"&&Jp&&!Jp.nodeType&&Jp,vb=Su&&Su.exports===Nh,Th=vb&&_b.process,Ni=function(){try{var Q=Su&&Su.require&&Su.require("util").types;return Q||Th&&Th.binding&&Th.binding("util")}catch(ce){}}(),Sb=Ni&&Ni.isArrayBuffer,Ob=Ni&&Ni.isDate,Db=Ni&&Ni.isMap,bb=Ni&&Ni.isRegExp,Ab=Ni&&Ni.isSet,Rb=Ni&&Ni.isTypedArray;function ri(Q,ce,ie){switch(ie.length){case 0:return Q.call(ce);case 1:return Q.call(ce,ie[0]);case 2:return Q.call(ce,ie[0],ie[1]);case 3:return Q.call(ce,ie[0],ie[1],ie[2])}return Q.apply(ce,ie)}function Dj(Q,ce,ie,Be){for(var ot=-1,jt=Q==null?0:Q.length;++ot-1}function Eh(Q,ce,ie){for(var Be=-1,ot=Q==null?0:Q.length;++Be-1;);return ie}function kb(Q,ce){for(var ie=Q.length;ie--&&Bc(ce,Q[ie],0)>-1;);return ie}function Bj(Q,ce){for(var ie=Q.length,Be=0;ie--;)Q[ie]===ce&&++Be;return Be}var Uj=gh(yj),kj=gh(Ij);function Mj(Q){return"\\"+_j[Q]}function xj(Q,ce){return Q==null?e:Q[ce]}function Uc(Q){return Nj.test(Q)}function qj(Q){return Tj.test(Q)}function Vj(Q){for(var ce,ie=[];!(ce=Q.next()).done;)ie.push(ce.value);return ie}function Oh(Q){var ce=-1,ie=Array(Q.size);return Q.forEach(function(Be,ot){ie[++ce]=[ot,Be]}),ie}function Mb(Q,ce){return function(ie){return Q(ce(ie))}}function qo(Q,ce){for(var ie=-1,Be=Q.length,ot=0,jt=[];++ie-1}function AK(s,u){var d=this.__data__,E=Mf(d,s);return E<0?(++this.size,d.push([s,u])):d[E][1]=u,this}Wa.prototype.clear=SK,Wa.prototype.delete=OK,Wa.prototype.get=DK,Wa.prototype.has=bK,Wa.prototype.set=AK;function Xa(s){var u=-1,d=s==null?0:s.length;for(this.clear();++u=u?s:u)),s}function yi(s,u,d,E,S,L){var M,j=u&p,H=u&f,fe=u&y;if(d&&(M=S?d(s,E,S,L):d(s)),M!==e)return M;if(!_n(s))return s;var me=lt(s);if(me){if(M=wG(s),!j)return qr(s,M)}else{var Ee=Er(s),be=Ee==Qe||Ee==Lt;if(Yo(s))return I0(s,j);if(Ee==xr||Ee==De||be&&!S){if(M=H||be?{}:x0(s),!j)return H?gG(s,GK(M,s)):IG(s,zb(M,s))}else{if(!fn[Ee])return S?s:{};M=LG(s,Ee,j)}}L||(L=new Qi);var je=L.get(s);if(je)return je;L.set(s,M),mA(s)?s.forEach(function(Ze){M.add(yi(Ze,u,d,Ze,s,L))}):pA(s)&&s.forEach(function(Ze,vt){M.set(vt,yi(Ze,u,d,vt,s,L))});var Xe=fe?H?Wh:zh:H?jr:ar,Et=me?e:Xe(s);return Ti(Et||s,function(Ze,vt){Et&&(vt=Ze,Ze=s[vt]),dd(M,vt,yi(Ze,u,d,vt,s,L))}),M}function $K(s){var u=ar(s);return function(d){return Wb(d,s,u)}}function Wb(s,u,d){var E=d.length;if(s==null)return!E;for(s=on(s);E--;){var S=d[E],L=u[S],M=s[S];if(M===e&&!(S in s)||!L(M))return!1}return!0}function Xb(s,u,d){if(typeof s!="function")throw new Ei(i);return hd(function(){s.apply(e,d)},u)}function pd(s,u,d,E){var S=-1,L=gf,M=!0,j=s.length,H=[],fe=u.length;if(!j)return H;d&&(u=yn(u,ii(d))),E?(L=Eh,M=!1):u.length>=n&&(L=ad,M=!1,u=new bu(u));e:for(;++SS?0:S+d),E=E===e||E>S?S:Nt(E),E<0&&(E+=S),E=d>E?0:TA(E);d0&&d(j)?u>1?mr(j,u-1,d,E,S):xo(S,j):E||(S[S.length]=j)}return S}var wh=D0(),t0=D0(!0);function Ia(s,u){return s&&wh(s,u,ar)}function Lh(s,u){return s&&t0(s,u,ar)}function qf(s,u){return Mo(u,function(d){return rs(s[d])})}function Ru(s,u){u=$o(u,s);for(var d=0,E=u.length;s!=null&&du}function JK(s,u){return s!=null&&Zt.call(s,u)}function HK(s,u){return s!=null&&u in on(s)}function zK(s,u,d){return s>=Tr(u,d)&&s=120&&me.length>=120)?new bu(M&&me):e}me=s[0];var Ee=-1,be=j[0];e:for(;++Ee-1;)j!==s&&Ff.call(j,H,1),Ff.call(s,H,1);return s}function p0(s,u){for(var d=s?u.length:0,E=d-1;d--;){var S=u[d];if(d==E||S!==L){var L=S;ns(S)?Ff.call(s,S,1):Kh(s,S)}}return s}function qh(s,u){return s+Cf(Qb()*(u-s+1))}function cG(s,u,d,E){for(var S=-1,L=Jn(Lf((u-s)/(d||1)),0),M=ie(L);L--;)M[E?L:++S]=s,s+=d;return M}function Vh(s,u){var d="";if(!s||u<1||u>dn)return d;do u%2&&(d+=s),u=Cf(u/2),u&&(s+=s);while(u);return d}function yt(s,u){return iy(j0(s,u,Kr),s+"")}function lG(s){return Hb(Qc(s))}function dG(s,u){var d=Qc(s);return Wf(d,Au(u,0,d.length))}function Nd(s,u,d,E){if(!_n(s))return s;u=$o(u,s);for(var S=-1,L=u.length,M=L-1,j=s;j!=null&&++SS?0:S+u),d=d>S?S:d,d<0&&(d+=S),S=u>d?0:d-u>>>0,u>>>=0;for(var L=ie(S);++E>>1,M=s[L];M!==null&&!si(M)&&(d?M<=u:M=n){var fe=u?null:OG(s);if(fe)return vf(fe);M=!1,S=ad,H=new bu}else H=u?[]:j;e:for(;++E=E?s:Ii(s,u,d)}var y0=nK||function(s){return ir.clearTimeout(s)};function I0(s,u){if(u)return s.slice();var d=s.length,E=Vb?Vb(d):new s.constructor(d);return s.copy(E),E}function Yh(s){var u=new s.constructor(s.byteLength);return new Rf(u).set(new Rf(s)),u}function TG(s,u){var d=u?Yh(s.buffer):s.buffer;return new s.constructor(d,s.byteOffset,s.byteLength)}function EG(s){var u=new s.constructor(s.source,rb.exec(s));return u.lastIndex=s.lastIndex,u}function hG(s){return ld?on(ld.call(s)):{}}function g0(s,u){var d=u?Yh(s.buffer):s.buffer;return new s.constructor(d,s.byteOffset,s.length)}function _0(s,u){if(s!==u){var d=s!==e,E=s===null,S=s===s,L=si(s),M=u!==e,j=u===null,H=u===u,fe=si(u);if(!j&&!fe&&!L&&s>u||L&&M&&H&&!j&&!fe||E&&M&&H||!d&&H||!S)return 1;if(!E&&!L&&!fe&&s=j)return H;var fe=d[E];return H*(fe=="desc"?-1:1)}}return s.index-u.index}function v0(s,u,d,E){for(var S=-1,L=s.length,M=d.length,j=-1,H=u.length,fe=Jn(L-M,0),me=ie(H+fe),Ee=!E;++j1?d[S-1]:e,M=S>2?d[2]:e;for(L=s.length>3&&typeof L=="function"?(S--,L):e,M&&Fr(d[0],d[1],M)&&(L=S<3?e:L,S=1),u=on(u);++E-1?S[L?u[M]:M]:e}}function R0(s){return ts(function(u){var d=u.length,E=d,S=hi.prototype.thru;for(s&&u.reverse();E--;){var L=u[E];if(typeof L!="function")throw new Ei(i);if(S&&!M&&Hf(L)=="wrapper")var M=new hi([],!0)}for(E=M?E:d;++E1&&Rt.reverse(),me&&Hj))return!1;var fe=L.get(s),me=L.get(u);if(fe&&me)return fe==u&&me==s;var Ee=-1,be=!0,je=d&v?new bu:e;for(L.set(s,u),L.set(u,s);++Ee1?"& ":"")+u[E],u=u.join(d>2?", ":" "),s.replace(U1,`{ +`+r;return{outputEnd:r,outputStart:n,pathNodes:t}}function Kq({outputEnd:e,outputStart:t,pathNodes:n},r){return t+Ec.LITERAL_SPACE.repeat(n.length+1)+tle(r,n.length)+e}function nle(e,t){return t?e?`${t}${e}`:t:e}function rle({entityAncestorData:e,errors:t,nodeResolutionDataByFieldPath:n,pathFromRoot:r,rootFieldData:i,unresolvableFieldPaths:a}){let o=[];for(let c of a){let l=(0,qq.getOrThrowError)(n,c,"nodeResolutionDataByFieldPath"),p=new Map;for(let[g,v]of l.fieldDataByFieldName)l.resolvedFieldNames.has(g)||p.set(g,v);let f=nle(c,r),y=jq(f);for(let[g,v]of p)o.push({fieldName:g,selectionSet:Kq(y,v),subgraphNames:v.subgraphNames,typeName:l.typeName})}for(let c of o)t.push((0,xq.unresolvablePathError)(c,Vq({rootFieldData:i,unresolvableFieldData:c,entityAncestorData:e})))}});var JO=w(OE=>{"use strict";m();T();N();Object.defineProperty(OE,"__esModule",{value:!0});OE.Graph=void 0;var $l=KO(),Ql=$O(),Gq=ur(),Ur=Jr(),QO=class{constructor(){_(this,"edgeId",-1);_(this,"entityDataNodes",new Map);_(this,"entityNodeNamesBySharedFieldPath",new Map);_(this,"nodeByNodeName",new Map);_(this,"nodesByTypeName",new Map);_(this,"rootNodeByRootTypeName",new Map);_(this,"subgraphName",Gq.NOT_APPLICABLE);_(this,"resolvableFieldNamesByRelativeFieldPathByEntityNodeName",new Map);_(this,"nodeResolutionDataByFieldPath",new Map);_(this,"unresolvableFieldPaths",new Set);_(this,"failureResultByEntityNodeName",new Map);_(this,"walkerIndex",-1)}getRootNode(t){return(0,Ur.getValueOrDefault)(this.rootNodeByRootTypeName,t,()=>new $l.RootNode(t))}addOrUpdateNode(t,n){let r=`${this.subgraphName}.${t}`,i=this.nodeByNodeName.get(r);if(i)return i.isAbstract||(i.isAbstract=!!(n!=null&&n.isAbstract)),!i.isLeaf&&(n!=null&&n.isLeaf)&&(i.isLeaf=!0),i;let a=new $l.GraphNode(this.subgraphName,t,n);return this.nodeByNodeName.set(r,a),(0,Ur.getValueOrDefault)(this.nodesByTypeName,t,()=>[]).push(a),a}addEdge(t,n,r,i=!1){if(t.isRootNode){let c=new $l.Edge(this.getNextEdgeId(),n,r);return(0,Ur.getValueOrDefault)(t.headToShareableTailEdges,r,()=>[]).push(c),c}let a=t,o=new $l.Edge(this.getNextEdgeId(),n,i?n.typeName:r,i);return a.headToTailEdges.set(r,o),o}addEntityDataNode(t){let n=this.entityDataNodes.get(t);if(n)return n;let r=new $l.EntityDataNode(t);return this.entityDataNodes.set(t,r),r}getNextEdgeId(){return this.edgeId+=1}setNodeInaccessible(t){let n=this.nodesByTypeName.get(t);if(n)for(let r of n)r.isInaccessible=!0}initializeNode(t,n){let r=this.entityDataNodes.get(t);if(Gq.ROOT_TYPE_NAMES.has(t)){let a=this.getRootNode(t);a.removeInaccessibleEdges(n),a.fieldDataByFieldName=n;return}let i=this.nodesByTypeName.get(t);if(i){for(let a of i)if(a.fieldDataByFieldName=n,a.handleInaccessibleEdges(),a.isLeaf=!1,!!r){a.hasEntitySiblings=!0;for(let o of a.satisfiedFieldSets){let c=r.targetSubgraphNamesByFieldSet.get(o);for(let l of c||[]){if(l===a.subgraphName)continue;let p=this.nodeByNodeName.get(`${l}.${a.typeName}`);p&&a.entityEdges.push(new $l.Edge(this.getNextEdgeId(),p,""))}}}}}setSubgraphName(t){this.subgraphName=t}validateEntities(t,n){let r=new Map;for(let[i,a]of t){let o=a.size>1,c,l=o?new Map:void 0,p=new Set,f=new Map;for(let y of a){let g=this.nodeByNodeName.get(y);if(!g)throw new Error(`Fatal: Could not find entity node for "${y}".`);if(this.resolvableFieldNamesByRelativeFieldPathByEntityNodeName.get(y)){let $=this.failureResultByEntityNodeName.get(y);if(!$){c=void 0;break}if(!o)return $}let P=this.nodesByTypeName.get(g.typeName)||[],U=(0,Ur.getValueOrDefault)(r,y,()=>o?f:new Map),K=new YO({interSubgraphNodes:P,entityNodeNamesBySharedFieldPath:U,originNode:g,resolvableFieldNamesByRelativeFieldPathByEntityNodeName:this.resolvableFieldNamesByRelativeFieldPathByEntityNodeName,walkerIndex:this.walkerIndex+=1,sharedResolvableFieldNamesByRelativeFieldPath:l,unresolvableSharedFieldPaths:p});if(K.visitEntityNode(g),K.unresolvableFieldPaths.size>0){if(o&&p.size<1){c=void 0;break}c={entityAncestorData:{fieldSetsByTargetSubgraphName:(0,Ur.getOrThrowError)(this.entityDataNodes,g.typeName,"entityDataNodes").fieldSetsByTargetSubgraphName,subgraphName:g.subgraphName,typeName:g.typeName},nodeName:y,parentFieldPathForEntityReference:[i],success:!1,typeName:g.typeName,unresolvableFieldPaths:o?p:K.unresolvableFieldPaths},this.failureResultByEntityNodeName.set(y,c);continue}c=void 0;break}if(c)return o&&l&&this.resolvableFieldNamesByRelativeFieldPathByEntityNodeName.set(c.nodeName,l),c}if(r.size>0)for(let[i,a]of r){let o=this.validateEntities(a,n);if(!o.success){for(let[c,l]of t)if(l.has(i)){o.parentFieldPathForEntityReference.push(c);break}return o}}return{success:!0}}validate(){let t=[];for(let n of this.rootNodeByRootTypeName.values())e:for(let[r,i]of n.headToShareableTailEdges){for(let c of i){if(c.isInaccessible)continue e;this.walkerIndex+=1,this.visitEdge(c,`${n.typeName.toLowerCase()}`)}let a=(0,Ur.getOrThrowError)(n.fieldDataByFieldName,r,"fieldDataByFieldName"),o=(0,Ql.newRootFieldData)(n.typeName,r,a.subgraphNames);if(this.unresolvableFieldPaths.size>0&&(0,Ql.generateResolvabilityErrors)({unresolvableFieldPaths:this.unresolvableFieldPaths,nodeResolutionDataByFieldPath:this.nodeResolutionDataByFieldPath,rootFieldData:o,errors:t}),this.entityNodeNamesBySharedFieldPath.size>0){let c=this.validateEntities(this.entityNodeNamesBySharedFieldPath,o);c.success||this.generateEntityResolvabilityErrors(c,o,t)}if(t.length>0)return t;this.entityNodeNamesBySharedFieldPath=new Map}return[]}visitEdge(t,n){return t.isInaccessible||t.node.isInaccessible?!1:(!(0,Ur.add)(t.visitedIndices,this.walkerIndex)||t.node.isLeaf||(t.node.isAbstract?this.validateAbstractNode(t.node,`${n}.${t.edgeName}`):this.validateConcreteNode(t.node,`${n}.${t.edgeName}`)),!0)}validateConcreteNode(t,n){if(t.headToTailEdges.size<1)return;if(t.hasEntitySiblings){(0,Ur.getValueOrDefault)(this.entityNodeNamesBySharedFieldPath,n,()=>new Set).add(t.nodeName);return}let r=(0,Ur.getValueOrDefault)(this.nodeResolutionDataByFieldPath,n,()=>new Ql.NodeResolutionData(t.typeName,t.fieldDataByFieldName));for(let[i,a]of t.headToTailEdges)this.visitEdge(a,n)&&r.add(i);r.isResolved?this.unresolvableFieldPaths.delete(n):this.unresolvableFieldPaths.add(n)}validateAbstractNode(t,n){if(!(t.headToTailEdges.size<1))for(let r of t.headToTailEdges.values())this.visitEdge(r,n)}generateEntityResolvabilityErrors(t,n,r){let i=(0,Ur.getOrThrowError)(this.resolvableFieldNamesByRelativeFieldPathByEntityNodeName,t.nodeName,"resolvableFieldNamesByRelativeFieldPathByEntityNodeName"),a="";for(let o of t.parentFieldPathForEntityReference)a=o+a;(0,Ql.generateResolvabilityErrors)({unresolvableFieldPaths:t.unresolvableFieldPaths,nodeResolutionDataByFieldPath:i,rootFieldData:n,errors:r,pathFromRoot:a,entityAncestorData:t.entityAncestorData})}};OE.Graph=QO;var YO=class{constructor({entityNodeNamesBySharedFieldPath:t,interSubgraphNodes:n,originNode:r,resolvableFieldNamesByRelativeFieldPathByEntityNodeName:i,unresolvableSharedFieldPaths:a,walkerIndex:o,sharedResolvableFieldNamesByRelativeFieldPath:c}){_(this,"entityNodeNamesBySharedFieldPath");_(this,"interSubgraphNodes");_(this,"originNode");_(this,"resolvableFieldNamesByRelativeFieldPath");_(this,"resolvableFieldNamesByRelativeFieldPathByEntityNodeName");_(this,"unresolvableFieldPaths",new Set);_(this,"unresolvableSharedFieldPaths");_(this,"walkerIndex");_(this,"sharedResolvableFieldNamesByRelativeFieldPath");this.entityNodeNamesBySharedFieldPath=t,this.interSubgraphNodes=n,this.originNode=r,this.resolvableFieldNamesByRelativeFieldPathByEntityNodeName=i,this.resolvableFieldNamesByRelativeFieldPath=(0,Ur.getValueOrDefault)(this.resolvableFieldNamesByRelativeFieldPathByEntityNodeName,r.nodeName,()=>new Map),this.unresolvableSharedFieldPaths=a,this.walkerIndex=o,this.sharedResolvableFieldNamesByRelativeFieldPath=c}visitEntityNode(t){this.validateEntityRelatedConcreteNode(t,"");let n=t.getAllAccessibleEntityNodeNames();for(let r of this.interSubgraphNodes){if(this.unresolvableFieldPaths.size<0)return;n.has(r.nodeName)&&this.validateEntityRelatedConcreteNode(r,"")}}visitEntityRelatedEdge(t,n){return t.isInaccessible||t.node.isInaccessible?!1:!(0,Ur.add)(t.visitedIndices,this.walkerIndex)||t.node.isLeaf?!0:t.node.hasEntitySiblings?((0,Ur.getValueOrDefault)(this.entityNodeNamesBySharedFieldPath,`${n}.${t.edgeName}`,()=>new Set).add(t.node.nodeName),!0):(t.node.isAbstract?this.validateEntityRelatedAbstractNode(t.node,`${n}.${t.edgeName}`):this.validateEntityRelatedConcreteNode(t.node,`${n}.${t.edgeName}`),!0)}validateEntityRelatedConcreteNode(t,n){if(t.headToTailEdges.size<1)return;let r=(0,Ur.getValueOrDefault)(this.resolvableFieldNamesByRelativeFieldPath,n,()=>new Ql.NodeResolutionData(t.typeName,t.fieldDataByFieldName)),i=this.sharedResolvableFieldNamesByRelativeFieldPath?(0,Ur.getValueOrDefault)(this.sharedResolvableFieldNamesByRelativeFieldPath,n,()=>new Ql.NodeResolutionData(t.typeName,t.fieldDataByFieldName)):void 0;for(let[a,o]of t.headToTailEdges)this.visitEntityRelatedEdge(o,n)&&(r.add(a),i==null||i.add(a));r.isResolved?this.unresolvableFieldPaths.delete(n):this.unresolvableFieldPaths.add(n),i&&(i.isResolved?this.unresolvableSharedFieldPaths.delete(n):this.unresolvableSharedFieldPaths.add(n))}validateEntityRelatedAbstractNode(t,n){if(!(t.headToTailEdges.size<1))for(let r of t.headToTailEdges.values())this.visitEntityRelatedEdge(r,n)}}});var HO=w(DE=>{"use strict";m();T();N();Object.defineProperty(DE,"__esModule",{value:!0});DE.newFieldSetConditionData=ile;DE.newConfigurationData=ale;function ile({fieldCoordinatesPath:e,fieldPath:t}){return{fieldCoordinatesPath:e,fieldPath:t}}function ale(e,t){return{fieldNames:new Set,isRootNode:e,typeName:t}}});var WO=w(hc=>{"use strict";m();T();N();Object.defineProperty(hc,"__esModule",{value:!0});hc.NormalizationFactory=void 0;hc.normalizeSubgraphFromString=cle;hc.normalizeSubgraph=Qq;hc.batchNormalize=lle;var Z=Ae(),On=Yr(),ei=Gp(),Ht=Es(),rr=Kp(),de=ia(),bE=kp(),sle=dv(),ma=XT(),ole=LO(),vs=gE(),$q=MO(),Ga=hp(),Nn=hl(),nr=ou(),zO=JO(),AE=Nv(),te=ur(),ule=Nl(),$e=Jr(),Qp=HO();function cle(e,t=!0){let{error:n,documentNode:r}=(0,On.safeParse)(e,t);return n||!r?{errors:[(0,de.subgraphInvalidSyntaxError)(n)],success:!1,warnings:[]}:new Yp(new zO.Graph).normalize(r)}function Qq(e,t,n){return new Yp(n||new zO.Graph,t).normalize(e)}var Yp=class{constructor(t,n){_(this,"argumentName","");_(this,"authorizationDataByParentTypeName",new Map);_(this,"concreteTypeNamesByAbstractTypeName",new Map);_(this,"conditionalFieldDataByCoords",new Map);_(this,"configurationDataByTypeName",new Map);_(this,"customDirectiveDefinitions",new Map);_(this,"definedDirectiveNames",new Set);_(this,"directiveDefinitionByDirectiveName",new Map);_(this,"directiveDefinitionDataByDirectiveName",(0,ei.initializeDirectiveDefinitionDatas)());_(this,"edfsDirectiveReferences",new Set);_(this,"errors",[]);_(this,"entityDataByTypeName",new Map);_(this,"entityInterfaceDataByTypeName",new Map);_(this,"eventsConfigurations",new Map);_(this,"fieldSetDataByTypeName",new Map);_(this,"internalGraph");_(this,"invalidConfigureDescriptionNodeDatas",[]);_(this,"invalidORScopesCoords",new Set);_(this,"invalidRepeatedDirectiveNameByCoords",new Map);_(this,"isCurrentParentExtension",!1);_(this,"isParentObjectExternal",!1);_(this,"isParentObjectShareable",!1);_(this,"isSubgraphEventDrivenGraph",!1);_(this,"isSubgraphVersionTwo",!1);_(this,"keyFieldSetDatasByTypeName",new Map);_(this,"lastParentNodeKind",Z.Kind.NULL);_(this,"lastChildNodeKind",Z.Kind.NULL);_(this,"parentTypeNamesWithAuthDirectives",new Set);_(this,"keyFieldSetDataByTypeName",new Map);_(this,"keyFieldSetsByEntityTypeNameByFieldCoords",new Map);_(this,"keyFieldNamesByParentTypeName",new Map);_(this,"fieldCoordsByNamedTypeName",new Map);_(this,"operationTypeNodeByTypeName",new Map);_(this,"originalParentTypeName","");_(this,"originalTypeNameByRenamedTypeName",new Map);_(this,"overridesByTargetSubgraphName",new Map);_(this,"parentDefinitionDataByTypeName",new Map);_(this,"schemaData");_(this,"referencedDirectiveNames",new Set);_(this,"referencedTypeNames",new Set);_(this,"renamedParentTypeName","");_(this,"subgraphName");_(this,"unvalidatedExternalFieldCoords",new Set);_(this,"usesEdfsNatsStreamConfiguration",!1);_(this,"warnings",[]);for(let[r,i]of Ht.BASE_DIRECTIVE_DEFINITION_BY_DIRECTIVE_NAME)this.directiveDefinitionByDirectiveName.set(r,i);this.subgraphName=n||te.NOT_APPLICABLE,this.internalGraph=t,this.internalGraph.setSubgraphName(this.subgraphName),this.schemaData={directivesByDirectiveName:new Map,kind:Z.Kind.SCHEMA_DEFINITION,name:te.SCHEMA,operationTypes:new Map}}validateArguments(t,n){for(let r of t.argumentDataByName.values()){let i=(0,nr.getTypeNodeNamedTypeName)(r.type);if(Ht.BASE_SCALARS.has(i)){r.namedTypeKind=Z.Kind.SCALAR_TYPE_DEFINITION;continue}let a=this.parentDefinitionDataByTypeName.get(i);if(a){if((0,Nn.isInputNodeKind)(a.kind)){r.namedTypeKind=a.kind;continue}this.errors.push((0,de.invalidNamedTypeError)({data:r,namedTypeData:a,nodeType:`${(0,$e.kindToNodeType)(n)} field argument`}))}}}isTypeNameRootType(t){return te.ROOT_TYPE_NAMES.has(t)||this.operationTypeNodeByTypeName.has(t)}isArgumentValueValid(t,n){if(n.kind===Z.Kind.NULL)return t.kind!==Z.Kind.NON_NULL_TYPE;switch(t.kind){case Z.Kind.LIST_TYPE:{if(n.kind!==Z.Kind.LIST)return this.isArgumentValueValid((0,nr.getNamedTypeNode)(t.type),n);for(let r of n.values)if(!this.isArgumentValueValid(t.type,r))return!1;return!0}case Z.Kind.NAMED_TYPE:switch(t.name.value){case te.BOOLEAN_SCALAR:return n.kind===Z.Kind.BOOLEAN;case te.FLOAT_SCALAR:return n.kind===Z.Kind.FLOAT||n.kind===Z.Kind.INT;case te.ID_SCALAR:return n.kind===Z.Kind.STRING||n.kind===Z.Kind.INT;case te.INT_SCALAR:return n.kind===Z.Kind.INT;case te.FIELD_SET_SCALAR:case te.SCOPE_SCALAR:case te.STRING_SCALAR:return n.kind===Z.Kind.STRING;case te.LINK_IMPORT:return!0;case te.LINK_PURPOSE:return n.kind!==Z.Kind.ENUM?!1:n.value===te.SECURITY||n.value===te.EXECUTION;case te.SUBSCRIPTION_FIELD_CONDITION:case te.SUBSCRIPTION_FILTER_CONDITION:return n.kind===Z.Kind.OBJECT;default:{let r=this.parentDefinitionDataByTypeName.get(t.name.value);if(!r)return!1;if(r.kind===Z.Kind.SCALAR_TYPE_DEFINITION)return!0;if(r.kind===Z.Kind.ENUM_TYPE_DEFINITION){if(n.kind!==Z.Kind.ENUM)return!1;let i=r.enumValueDataByValueName.get(n.value);return i?!i.directivesByDirectiveName.has(te.INACCESSIBLE):!1}return r.kind!==Z.Kind.INPUT_OBJECT_TYPE_DEFINITION?!1:n.kind===Z.Kind.OBJECT}}default:return this.isArgumentValueValid(t.type,n)}}addInheritedDirectivesToFieldData(t,n){return this.isParentObjectShareable&&!t.has(te.SHAREABLE)&&(t.set(te.SHAREABLE,[(0,$e.generateSimpleDirective)(te.SHAREABLE)]),n.add(te.SHAREABLE)),this.isParentObjectExternal&&!t.has(te.EXTERNAL)&&(t.set(te.EXTERNAL,[(0,$e.generateSimpleDirective)(te.EXTERNAL)]),n.add(te.EXTERNAL)),t}extractDirectives(t,n){if(!t.directives)return n;for(let r of t.directives){let i=r.name.value;i===te.SHAREABLE?(0,$e.getValueOrDefault)(n,i,()=>[r]):(0,$e.getValueOrDefault)(n,i,()=>[]).push(r),(0,rr.isNodeKindObject)(t.kind)&&(this.isParentObjectExternal||(this.isParentObjectExternal=i===te.EXTERNAL),this.isParentObjectShareable||(this.isParentObjectShareable=i===te.SHAREABLE))}return n}validateDirective({data:t,definitionData:n,directiveCoords:r,directiveNode:i,errorMessages:a,requiredArgumentNames:o}){let c=i.name.value,l=t.kind===Z.Kind.FIELD_DEFINITION?t.renamedParentTypeName||t.originalParentTypeName:t.name,p=c===te.AUTHENTICATED,f=c===te.OVERRIDE,y=c===te.REQUIRES_SCOPES;if(!i.arguments||i.arguments.length<1)return n.requiredArgumentNames.size>0&&a.push((0,de.undefinedRequiredArgumentsErrorMessage)(c,o,[])),p&&this.handleAuthenticatedDirective(t,l),a;let g=new Set,v=new Set,P=new Set,U=[];for(let ne of i.arguments){let z=ne.name.value;if(g.has(z)){v.add(z);continue}g.add(z);let Te=n.argumentTypeNodeByArgumentName.get(z);if(!Te){P.add(z);continue}if(!this.isArgumentValueValid(Te.typeNode,ne.value)){a.push((0,de.invalidArgumentValueErrorMessage)((0,Z.print)(ne.value),`@${c}`,z,(0,ma.printTypeNode)(Te.typeNode)));continue}if(f&&t.kind===Z.Kind.FIELD_DEFINITION){this.handleOverrideDirective({data:t,directiveCoords:r,errorMessages:a,targetSubgraphName:ne.value.value});continue}!y||z!==te.SCOPES||this.extractRequiredScopes({directiveCoords:r,orScopes:ne.value.values,requiredScopes:U})}v.size>0&&a.push((0,de.duplicateDirectiveArgumentDefinitionsErrorMessage)([...v])),P.size>0&&a.push((0,de.unexpectedDirectiveArgumentErrorMessage)(c,[...P]));let K=(0,$e.getEntriesNotInHashSet)(o,g);if(K.length>0&&a.push((0,de.undefinedRequiredArgumentsErrorMessage)(c,o,K)),a.length>0||!y)return a;let $=(0,$e.getValueOrDefault)(this.authorizationDataByParentTypeName,l,()=>(0,rr.newAuthorizationData)(l));if(t.kind!==Z.Kind.FIELD_DEFINITION)this.parentTypeNamesWithAuthDirectives.add(l),$.requiredScopes.push(...U);else{let ne=(0,$e.getValueOrDefault)($.fieldAuthDataByFieldName,t.name,()=>(0,rr.newFieldAuthorizationData)(t.name));ne.inheritedData.requiredScopes.push(...U),ne.originalData.requiredScopes.push(...U)}return a}validateDirectives(t,n){let r=new Set;for(let[i,a]of t.directivesByDirectiveName){let o=this.directiveDefinitionDataByDirectiveName.get(i);if(!o){r.has(i)||(this.errors.push((0,de.undefinedDirectiveError)(i,n)),r.add(i));continue}let c=[],l=(0,On.nodeKindToDirectiveLocation)(t.kind);if(o.locations.has(l)||c.push((0,de.invalidDirectiveLocationErrorMessage)(i,l)),a.length>1&&!o.isRepeatable){let f=(0,$e.getValueOrDefault)(this.invalidRepeatedDirectiveNameByCoords,n,()=>new Set);f.has(i)||(f.add(i),c.push((0,de.invalidRepeatedDirectiveErrorMessage)(i)))}let p=[...o.requiredArgumentNames];for(let f=0;f0&&this.errors.push((0,de.invalidDirectiveError)(i,n,(0,$e.numberToOrdinal)(f+1),y))}}switch(t.kind){case Z.Kind.ENUM_TYPE_DEFINITION:{for(let[i,a]of t.enumValueDataByValueName)this.validateDirectives(a,`${t.name}.${i}`);return}case Z.Kind.FIELD_DEFINITION:{for(let[i,a]of t.argumentDataByName)this.validateDirectives(a,`${t.originalParentTypeName}.${t.name}(${i}: ...)`);return}case Z.Kind.INPUT_OBJECT_TYPE_DEFINITION:{for(let[i,a]of t.inputValueDataByName)this.validateDirectives(a,`${t.name}.${i}`);return}case Z.Kind.INTERFACE_TYPE_DEFINITION:case Z.Kind.OBJECT_TYPE_DEFINITION:{for(let[i,a]of t.fieldDataByName)this.validateDirectives(a,`${t.name}.${i}`);return}default:return}}getNodeExtensionType(t,n,r=!1){return t?Ga.ExtensionType.REAL:r||!n.has(te.EXTENDS)?Ga.ExtensionType.NONE:Ga.ExtensionType.EXTENDS}setParentDataExtensionType(t,n){switch(t.extensionType){case Ga.ExtensionType.EXTENDS:case Ga.ExtensionType.NONE:{if(n===Ga.ExtensionType.REAL)return;this.errors.push((0,de.duplicateTypeDefinitionError)((0,$e.kindToNodeType)(t.kind),t.name));return}default:t.extensionType=n}}extractConfigureDescriptionData(t,n){var i,a;if(!n.arguments||n.arguments.length<1){t.description||this.invalidConfigureDescriptionNodeDatas.push(t),t.configureDescriptionDataBySubgraphName.set(this.subgraphName,{propagate:!0,description:((i=t.description)==null?void 0:i.value)||""});return}let r={propagate:!0,description:((a=t.description)==null?void 0:a.value)||""};for(let o of n.arguments)switch(o.name.value){case te.PROPAGATE:{if(o.value.kind!=Z.Kind.BOOLEAN)return;r.propagate=o.value.value;break}case te.DESCRIPTION_OVERRIDE:{if(o.value.kind!=Z.Kind.STRING)return;r.description=o.value.value;break}default:return}!t.description&&!r.description&&this.invalidConfigureDescriptionNodeDatas.push(t),t.configureDescriptionDataBySubgraphName.set(this.subgraphName,r)}extractConfigureDescriptionsData(t){let n=t.directivesByDirectiveName.get(te.CONFIGURE_DESCRIPTION);n&&n.length==1&&this.extractConfigureDescriptionData(t,n[0])}extractImplementedInterfaceTypeNames(t,n){if(!t.interfaces)return n;let r=t.name.value;for(let i of t.interfaces){let a=i.name.value;if(n.has(a)){this.errors.push((0,de.duplicateImplementedInterfaceError)((0,rr.kindToConvertedTypeString)(t.kind),r,a));continue}n.add(a)}return n}updateCompositeOutputDataByNode(t,n,r){this.setParentDataExtensionType(n,r),this.extractImplementedInterfaceTypeNames(t,n.implementedInterfaceTypeNames),n.description||(n.description=(0,On.formatDescription)("description"in t?t.description:void 0)),this.extractConfigureDescriptionsData(n),n.isEntity||(n.isEntity=n.directivesByDirectiveName.has(te.KEY)),n.isInaccessible||(n.isInaccessible=n.directivesByDirectiveName.has(te.INACCESSIBLE)),n.subgraphNames.add(this.subgraphName)}addConcreteTypeNamesForImplementedInterfaces(t,n){for(let r of t)(0,$e.getValueOrDefault)(this.concreteTypeNamesByAbstractTypeName,r,()=>new Set).add(n),this.internalGraph.addEdge(this.internalGraph.addOrUpdateNode(r,{isAbstract:!0}),this.internalGraph.addOrUpdateNode(n),n,!0)}extractArguments(t,n){var o;if(!((o=n.arguments)!=null&&o.length))return t;let r=n.name.value,i=`${this.originalParentTypeName}.${r}`,a=new Set;for(let c of n.arguments){let l=c.name.value;if(t.has(l)){a.add(l);continue}this.addInputValueDataByNode({fieldName:r,inputValueDataByName:t,isArgument:!0,node:c,originalParentTypeName:this.originalParentTypeName,renamedParentTypeName:this.renamedParentTypeName})}return a.size>0&&this.errors.push((0,de.duplicateArgumentsError)(i,[...a])),t}addPersistedDirectiveDefinitionDataByNode(t,n,r){let i=n.name.value,a=`@${i}`,o=new Map;for(let c of n.arguments||[])this.addInputValueDataByNode({inputValueDataByName:o,isArgument:!0,node:c,originalParentTypeName:a});t.set(i,{argumentDataByArgumentName:o,executableLocations:r,name:i,repeatable:n.repeatable,subgraphNames:new Set([this.subgraphName]),description:(0,On.formatDescription)(n.description)})}extractDirectiveLocations(t,n){let r=new Set,i=new Set;for(let a of t.locations){let o=a.value;if(!i.has(o)){if(!te.EXECUTABLE_DIRECTIVE_LOCATIONS.has(o)&&!bE.TYPE_SYSTEM_DIRECTIVE_LOCATIONS.has(o)){n.push((0,de.invalidDirectiveDefinitionLocationErrorMessage)(o)),i.add(o);continue}if(r.has(o)){n.push((0,de.duplicateDirectiveDefinitionLocationErrorMessage)(o)),i.add(o);continue}r.add(o)}}return r}extractArgumentData(t,n){let r=new Map,i=new Set,a=new Set,o={argumentTypeNodeByArgumentName:r,optionalArgumentNames:i,requiredArgumentNames:a};if(!t)return o;let c=new Set;for(let l of t){let p=l.name.value;if(r.has(p)){c.add(p);continue}l.defaultValue&&i.add(p),(0,Nn.isTypeRequired)(l.type)&&!l.defaultValue&&a.add(p),r.set(p,{name:p,typeNode:l.type,defaultValue:l.defaultValue})}return c.size>0&&n.push((0,de.duplicateDirectiveDefinitionArgumentErrorMessage)([...c])),o}addDirectiveDefinitionDataByNode(t){let n=t.name.value;if(this.definedDirectiveNames.has(n))return this.errors.push((0,de.duplicateDirectiveDefinitionError)(n)),!1;if(this.definedDirectiveNames.add(n),this.directiveDefinitionByDirectiveName.set(n,t),Ht.V2_DIRECTIVE_DEFINITION_BY_DIRECTIVE_NAME.has(n))return this.isSubgraphVersionTwo=!0,!1;if(Ht.ALL_IN_BUILT_DIRECTIVE_NAMES.has(n))return!1;let r=[],{argumentTypeNodeByArgumentName:i,optionalArgumentNames:a,requiredArgumentNames:o}=this.extractArgumentData(t.arguments,r);return this.directiveDefinitionDataByDirectiveName.set(n,{argumentTypeNodeByArgumentName:i,isRepeatable:t.repeatable,locations:this.extractDirectiveLocations(t,r),name:n,node:t,optionalArgumentNames:a,requiredArgumentNames:o}),r.length>0&&this.errors.push((0,de.invalidDirectiveDefinitionError)(n,r)),!0}addFieldDataByNode(t,n,r,i,a=new Set){let o=n.name.value,c=this.renamedParentTypeName||this.originalParentTypeName,l=`${this.originalParentTypeName}.${o}`,{isExternal:p,isShareable:f}=(0,Nn.isNodeExternalOrShareable)(n,!this.isSubgraphVersionTwo,i),y=(0,nr.getTypeNodeNamedTypeName)(n.type),g={argumentDataByName:r,configureDescriptionDataBySubgraphName:new Map,externalFieldDataBySubgraphName:new Map([[this.subgraphName,(0,Nn.newExternalFieldData)(p)]]),federatedCoords:`${c}.${o}`,inheritedDirectiveNames:a,isInaccessible:i.has(te.INACCESSIBLE),isShareableBySubgraphName:new Map([[this.subgraphName,f]]),kind:Z.Kind.FIELD_DEFINITION,name:o,namedTypeKind:Ht.BASE_SCALARS.has(y)?Z.Kind.SCALAR_TYPE_DEFINITION:Z.Kind.NULL,namedTypeName:y,node:(0,nr.getMutableFieldNode)(n,l,this.errors),originalParentTypeName:this.originalParentTypeName,persistedDirectivesData:(0,Nn.newPersistedDirectivesData)(),renamedParentTypeName:c,subgraphNames:new Set([this.subgraphName]),type:(0,nr.getMutableTypeNode)(n.type,l,this.errors),directivesByDirectiveName:i,description:(0,On.formatDescription)(n.description)};return Ht.BASE_SCALARS.has(g.namedTypeName)||this.referencedTypeNames.add(g.namedTypeName),this.extractConfigureDescriptionsData(g),t.set(o,g),g}addInputValueDataByNode({fieldName:t,inputValueDataByName:n,isArgument:r,node:i,originalParentTypeName:a,renamedParentTypeName:o}){let c=o||a,l=i.name.value,p=r?`${a}${t?`.${t}`:""}(${l}: ...)`:`${a}.${l}`;i.defaultValue&&!(0,Nn.areDefaultValuesCompatible)(i.type,i.defaultValue)&&this.errors.push((0,de.incompatibleInputValueDefaultValueTypeError)((r?te.ARGUMENT:te.INPUT_FIELD)+` "${l}"`,p,(0,ma.printTypeNode)(i.type),(0,Z.print)(i.defaultValue)));let f=r?`${c}${t?`.${t}`:""}(${l}: ...)`:`${c}.${l}`,y=(0,nr.getTypeNodeNamedTypeName)(i.type),g={configureDescriptionDataBySubgraphName:new Map,directivesByDirectiveName:this.extractDirectives(i,new Map),federatedCoords:f,fieldName:t,includeDefaultValue:!!i.defaultValue,isArgument:r,kind:r?Z.Kind.ARGUMENT:Z.Kind.INPUT_VALUE_DEFINITION,name:l,namedTypeKind:Ht.BASE_SCALARS.has(y)?Z.Kind.SCALAR_TYPE_DEFINITION:Z.Kind.NULL,namedTypeName:y,node:(0,nr.getMutableInputValueNode)(i,a,this.errors),originalCoords:p,originalParentTypeName:a,persistedDirectivesData:(0,Nn.newPersistedDirectivesData)(),renamedParentTypeName:c,requiredSubgraphNames:new Set((0,Nn.isTypeRequired)(i.type)?[this.subgraphName]:[]),subgraphNames:new Set([this.subgraphName]),type:(0,nr.getMutableTypeNode)(i.type,a,this.errors),defaultValue:i.defaultValue,description:(0,On.formatDescription)(i.description)};this.extractConfigureDescriptionsData(g),n.set(l,g)}upsertInterfaceDataByNode(t,n=!1){let r=t.name.value,i=this.parentDefinitionDataByTypeName.get(r),a=this.extractDirectives(t,(i==null?void 0:i.directivesByDirectiveName)||new Map),o=this.getNodeExtensionType(n,a),c=this.entityInterfaceDataByTypeName.get(r);if(c&&t.fields)for(let p of t.fields)c.interfaceFieldNames.add(p.name.value);if(i){if(i.kind!==Z.Kind.INTERFACE_TYPE_DEFINITION){this.errors.push((0,de.multipleNamedTypeDefinitionError)(r,(0,$e.kindToNodeType)(i.kind),(0,rr.kindToConvertedTypeString)(t.kind)));return}this.updateCompositeOutputDataByNode(t,i,o);return}let l={configureDescriptionDataBySubgraphName:new Map,directivesByDirectiveName:a,extensionType:o,fieldDataByName:new Map,implementedInterfaceTypeNames:this.extractImplementedInterfaceTypeNames(t,new Set),isEntity:a.has(te.KEY),isInaccessible:a.has(te.INACCESSIBLE),kind:Z.Kind.INTERFACE_TYPE_DEFINITION,name:r,node:(0,nr.getMutableInterfaceNode)(t.name),persistedDirectivesData:(0,Nn.newPersistedDirectivesData)(),subgraphNames:new Set([this.subgraphName]),description:(0,On.formatDescription)("description"in t?t.description:void 0)};this.extractConfigureDescriptionsData(l),this.parentDefinitionDataByTypeName.set(r,l)}getRenamedRootTypeName(t){let n=this.operationTypeNodeByTypeName.get(t);if(!n)return t;switch(n){case Z.OperationTypeNode.MUTATION:return te.MUTATION;case Z.OperationTypeNode.SUBSCRIPTION:return te.SUBSCRIPTION;default:return te.QUERY}}addInterfaceObjectFieldsByNode(t){let n=t.name.value,r=this.entityInterfaceDataByTypeName.get(n);if(!(!r||!r.isInterfaceObject||!t.fields))for(let i of t.fields)r.interfaceObjectFieldNames.add(i.name.value)}upsertObjectDataByNode(t,n=!1){let r=t.name.value,i=this.parentDefinitionDataByTypeName.get(r),a=this.extractDirectives(t,(i==null?void 0:i.directivesByDirectiveName)||new Map),o=this.isTypeNameRootType(r),c=this.getNodeExtensionType(n,a,o);if(this.addInterfaceObjectFieldsByNode(t),i){if(i.kind!==Z.Kind.OBJECT_TYPE_DEFINITION){this.errors.push((0,de.multipleNamedTypeDefinitionError)(r,(0,$e.kindToNodeType)(i.kind),(0,rr.kindToConvertedTypeString)(t.kind)));return}this.updateCompositeOutputDataByNode(t,i,c),a.has(te.INTERFACE_OBJECT)||this.addConcreteTypeNamesForImplementedInterfaces(i.implementedInterfaceTypeNames,r);return}let l=this.extractImplementedInterfaceTypeNames(t,new Set);a.has(te.INTERFACE_OBJECT)||this.addConcreteTypeNamesForImplementedInterfaces(l,r);let p={configureDescriptionDataBySubgraphName:new Map,directivesByDirectiveName:a,extensionType:c,fieldDataByName:new Map,implementedInterfaceTypeNames:l,isEntity:a.has(te.KEY),isInaccessible:a.has(te.INACCESSIBLE),isRootType:o,kind:Z.Kind.OBJECT_TYPE_DEFINITION,name:r,node:(0,nr.getMutableObjectNode)(t.name),persistedDirectivesData:(0,Nn.newPersistedDirectivesData)(),renamedTypeName:this.getRenamedRootTypeName(r),subgraphNames:new Set([this.subgraphName]),description:(0,On.formatDescription)("description"in t?t.description:void 0)};this.extractConfigureDescriptionsData(p),this.parentDefinitionDataByTypeName.set(r,p)}upsertEnumDataByNode(t,n=!1){let r=t.name.value;this.internalGraph.addOrUpdateNode(r,{isLeaf:!0});let i=this.parentDefinitionDataByTypeName.get(r),a=this.extractDirectives(t,(i==null?void 0:i.directivesByDirectiveName)||new Map),o=this.getNodeExtensionType(n,a);if(i){if(i.kind!==Z.Kind.ENUM_TYPE_DEFINITION){this.errors.push((0,de.multipleNamedTypeDefinitionError)(r,(0,$e.kindToNodeType)(i.kind),(0,rr.kindToConvertedTypeString)(t.kind)));return}this.setParentDataExtensionType(i,o),i.isInaccessible||(i.isInaccessible=a.has(te.INACCESSIBLE)),i.subgraphNames.add(this.subgraphName),i.description||(i.description=(0,On.formatDescription)("description"in t?t.description:void 0)),this.extractConfigureDescriptionsData(i);return}let c={appearances:1,configureDescriptionDataBySubgraphName:new Map,directivesByDirectiveName:a,extensionType:o,enumValueDataByValueName:new Map,isInaccessible:a.has(te.INACCESSIBLE),kind:Z.Kind.ENUM_TYPE_DEFINITION,name:r,node:(0,nr.getMutableEnumNode)(t.name),persistedDirectivesData:(0,Nn.newPersistedDirectivesData)(),subgraphNames:new Set([this.subgraphName]),description:(0,On.formatDescription)("description"in t?t.description:void 0)};this.extractConfigureDescriptionsData(c),this.parentDefinitionDataByTypeName.set(r,c)}upsertInputObjectByNode(t,n=!1){let r=t.name.value,i=this.parentDefinitionDataByTypeName.get(r),a=this.extractDirectives(t,(i==null?void 0:i.directivesByDirectiveName)||new Map),o=this.getNodeExtensionType(n,a);if(i){if(i.kind!==Z.Kind.INPUT_OBJECT_TYPE_DEFINITION){this.errors.push((0,de.multipleNamedTypeDefinitionError)(r,(0,$e.kindToNodeType)(i.kind),(0,rr.kindToConvertedTypeString)(t.kind)));return}this.setParentDataExtensionType(i,o),i.isInaccessible||(i.isInaccessible=a.has(te.INACCESSIBLE)),i.subgraphNames.add(this.subgraphName),i.description||(i.description=(0,On.formatDescription)("description"in t?t.description:void 0)),this.extractConfigureDescriptionsData(i);return}let c={configureDescriptionDataBySubgraphName:new Map,directivesByDirectiveName:a,extensionType:o,inputValueDataByName:new Map,isInaccessible:a.has(te.INACCESSIBLE),kind:Z.Kind.INPUT_OBJECT_TYPE_DEFINITION,name:r,node:(0,nr.getMutableInputObjectNode)(t.name),persistedDirectivesData:(0,Nn.newPersistedDirectivesData)(),subgraphNames:new Set([this.subgraphName]),description:(0,On.formatDescription)("description"in t?t.description:void 0)};this.extractConfigureDescriptionsData(c),this.parentDefinitionDataByTypeName.set(r,c)}upsertScalarByNode(t,n=!1){let r=t.name.value;this.internalGraph.addOrUpdateNode(r,{isLeaf:!0});let i=this.parentDefinitionDataByTypeName.get(r),a=this.extractDirectives(t,(i==null?void 0:i.directivesByDirectiveName)||new Map),o=this.getNodeExtensionType(n,a);if(i){if(i.kind!==Z.Kind.SCALAR_TYPE_DEFINITION){this.errors.push((0,de.multipleNamedTypeDefinitionError)(r,(0,$e.kindToNodeType)(i.kind),(0,rr.kindToConvertedTypeString)(t.kind)));return}this.setParentDataExtensionType(i,o),i.description||(i.description=(0,On.formatDescription)("description"in t?t.description:void 0)),i.subgraphNames.add(this.subgraphName),this.extractConfigureDescriptionsData(i);return}let c={configureDescriptionDataBySubgraphName:new Map,directivesByDirectiveName:a,extensionType:o,kind:Z.Kind.SCALAR_TYPE_DEFINITION,name:r,node:(0,nr.getMutableScalarNode)(t.name),persistedDirectivesData:(0,Nn.newPersistedDirectivesData)(),subgraphNames:new Set([this.subgraphName]),description:(0,On.formatDescription)("description"in t?t.description:void 0)};this.extractConfigureDescriptionsData(c),this.parentDefinitionDataByTypeName.set(r,c)}extractUnionMembers(t,n){if(!t.types)return n;let r=t.name.value;for(let i of t.types){let a=i.name.value;if(n.has(a)){this.errors.push((0,de.duplicateUnionMemberDefinitionError)(r,a));continue}(0,$e.getValueOrDefault)(this.concreteTypeNamesByAbstractTypeName,r,()=>new Set).add(a),Ht.BASE_SCALARS.has(a)||this.referencedTypeNames.add(a),n.set(a,i)}return n}upsertUnionByNode(t,n=!1){let r=t.name.value,i=this.parentDefinitionDataByTypeName.get(r),a=this.extractDirectives(t,(i==null?void 0:i.directivesByDirectiveName)||new Map),o=this.getNodeExtensionType(n,a);if(this.addConcreteTypeNamesForUnion(t),i){if(i.kind!==Z.Kind.UNION_TYPE_DEFINITION){this.errors.push((0,de.multipleNamedTypeDefinitionError)(r,(0,$e.kindToNodeType)(i.kind),(0,rr.kindToConvertedTypeString)(t.kind)));return}this.setParentDataExtensionType(i,o),this.extractUnionMembers(t,i.memberByMemberTypeName),i.description||(i.description=(0,On.formatDescription)("description"in t?t.description:void 0)),i.subgraphNames.add(this.subgraphName),this.extractConfigureDescriptionsData(i);return}let c={configureDescriptionDataBySubgraphName:new Map,directivesByDirectiveName:a,extensionType:o,kind:Z.Kind.UNION_TYPE_DEFINITION,memberByMemberTypeName:this.extractUnionMembers(t,new Map),name:r,node:(0,nr.getMutableUnionNode)(t.name),persistedDirectivesData:(0,Nn.newPersistedDirectivesData)(),subgraphNames:new Set([this.subgraphName]),description:(0,On.formatDescription)("description"in t?t.description:void 0)};this.extractConfigureDescriptionsData(c),this.parentDefinitionDataByTypeName.set(r,c)}extractKeyFieldSets(t,n){var a;let r=t.name.value;if(!((a=t.directives)!=null&&a.length)){this.errors.push((0,de.expectedEntityError)(r));return}let i=0;for(let o of t.directives){if(o.name.value!==te.KEY||(i+=1,!o.arguments||o.arguments.length<1))continue;let c,l=!1;for(let v of o.arguments){if(v.name.value===te.RESOLVABLE){v.value.kind===Z.Kind.BOOLEAN&&!v.value.value&&(l=!0);continue}if(v.name.value!==te.FIELDS){c=void 0;break}if(v.value.kind!==Z.Kind.STRING){c=void 0;break}c=v.value.value}if(c===void 0)continue;let{error:p,documentNode:f}=(0,On.safeParse)("{"+c+"}");if(p||!f){this.errors.push((0,de.invalidDirectiveError)(te.KEY,r,(0,$e.numberToOrdinal)(i),[(0,de.unparsableFieldSetErrorMessage)(c,p)]));continue}let y=(0,ei.getNormalizedFieldSet)(f),g=n.get(y);g?g.isUnresolvable||(g.isUnresolvable=l):n.set(y,{documentNode:f,isUnresolvable:l,normalizedFieldSet:y,rawFieldSet:c})}}getFieldSetParent(t,n,r,i){if(!t)return{fieldSetParentData:n};let a=(0,$e.getOrThrowError)(n.fieldDataByName,r,`${i}.fieldDataByFieldName`),o=(0,nr.getTypeNodeNamedTypeName)(a.node.type),c=this.parentDefinitionDataByTypeName.get(o);return c?c.kind!==Z.Kind.INTERFACE_TYPE_DEFINITION&&c.kind!==Z.Kind.OBJECT_TYPE_DEFINITION?{errorString:(0,de.incompatibleTypeWithProvidesErrorMessage)(`${i}.${r}`,o)}:{fieldSetParentData:c}:{errorString:(0,de.unknownNamedTypeErrorMessage)(`${i}.${r}`,o)}}validateConditionalFieldSet(t,n,r,i,a){let{error:o,documentNode:c}=(0,On.safeParse)("{"+n+"}");if(o||!c)return{errorMessages:[(0,de.unparsableFieldSetErrorMessage)(n,o)]};let l=this,p=[t],f=(0,ei.getConditionalFieldSetDirectiveName)(i),y=[],g=`${a}.${r}`,v=(0,ei.getInitialFieldCoordsPath)(i,g),P=[r],U=new Set,K=[],$=-1,ne=!0,z=r,Te=!1;return(0,Z.visit)(c,{Argument:{enter(){return!1}},Field:{enter(pe){let Fe=p[$],xe=Fe.name;if(Fe.kind===Z.Kind.UNION_TYPE_DEFINITION)return K.push((0,de.invalidSelectionOnUnionErrorMessage)(n,v,xe)),Z.BREAK;let et=pe.name.value,X=`${xe}.${et}`;if(l.unvalidatedExternalFieldCoords.delete(X),ne)return K.push((0,de.invalidSelectionSetErrorMessage)(n,v,xe,(0,$e.kindToNodeType)(Fe.kind))),Z.BREAK;v.push(X),P.push(et),z=et;let ve=Fe.fieldDataByName.get(et);if(!ve)return K.push((0,de.undefinedFieldInFieldSetErrorMessage)(n,xe,et)),Z.BREAK;if(y[$].has(et))return K.push((0,de.duplicateFieldInFieldSetErrorMessage)(n,X)),Z.BREAK;y[$].add(et);let{isDefinedExternal:gt,isUnconditionallyProvided:zt}=(0,$e.getOrThrowError)(ve.externalFieldDataBySubgraphName,l.subgraphName,`${X}.externalFieldDataBySubgraphName`),Wt=gt&&!zt;zt||(Te=!0);let Dn=(0,nr.getTypeNodeNamedTypeName)(ve.node.type),Vt=l.parentDefinitionDataByTypeName.get(Dn);if(Ht.BASE_SCALARS.has(Dn)||(Vt==null?void 0:Vt.kind)===Z.Kind.SCALAR_TYPE_DEFINITION||(Vt==null?void 0:Vt.kind)===Z.Kind.ENUM_TYPE_DEFINITION){if(U.size<1&&!gt){if(l.isSubgraphVersionTwo){l.errors.push((0,de.nonExternalConditionalFieldError)(g,l.subgraphName,X,n,f));return}l.warnings.push((0,vs.nonExternalConditionalFieldWarning)(g,l.subgraphName,X,n,f));return}if(U.size<1&&zt){l.isSubgraphVersionTwo?K.push((0,de.fieldAlreadyProvidedErrorMessage)(X,l.subgraphName,f)):l.warnings.push((0,vs.fieldAlreadyProvidedWarning)(X,f,g,l.subgraphName));return}if(!Wt&&!i)return;let dn=(0,$e.getValueOrDefault)(l.conditionalFieldDataByCoords,X,Nn.newConditionalFieldData),Ar=(0,Qp.newFieldSetConditionData)({fieldCoordinatesPath:[...v],fieldPath:[...P]});i?dn.providedBy.push(Ar):dn.requiredBy.push(Ar);return}if(!Vt)return K.push((0,de.unknownTypeInFieldSetErrorMessage)(n,X,Dn)),Z.BREAK;if(gt&&(i&&(0,$e.getValueOrDefault)(l.conditionalFieldDataByCoords,X,Nn.newConditionalFieldData).providedBy.push((0,Qp.newFieldSetConditionData)({fieldCoordinatesPath:[...v],fieldPath:[...P]})),U.add(X)),Vt.kind===Z.Kind.OBJECT_TYPE_DEFINITION||Vt.kind===Z.Kind.INTERFACE_TYPE_DEFINITION||Vt.kind===Z.Kind.UNION_TYPE_DEFINITION){ne=!0,p.push(Vt);return}},leave(){U.delete(v.pop()||""),P.pop()}},InlineFragment:{enter(pe){let Fe=p[$],xe=Fe.name,et=v.length<1?t.name:v[v.length-1];if(!pe.typeCondition)return K.push((0,de.inlineFragmentWithoutTypeConditionErrorMessage)(n,et)),Z.BREAK;let X=pe.typeCondition.name.value;if(X===xe){p.push(Fe),ne=!0;return}if(!(0,On.isKindAbstract)(Fe.kind))return K.push((0,de.invalidInlineFragmentTypeErrorMessage)(n,v,X,xe)),Z.BREAK;let ve=l.parentDefinitionDataByTypeName.get(X);if(!ve)return K.push((0,de.unknownInlineFragmentTypeConditionErrorMessage)(n,v,xe,X)),Z.BREAK;switch(ne=!0,ve.kind){case Z.Kind.INTERFACE_TYPE_DEFINITION:{if(!ve.implementedInterfaceTypeNames.has(xe))break;p.push(ve);return}case Z.Kind.OBJECT_TYPE_DEFINITION:{let gt=l.concreteTypeNamesByAbstractTypeName.get(xe);if(!gt||!gt.has(X))break;p.push(ve);return}case Z.Kind.UNION_TYPE_DEFINITION:{p.push(ve);return}default:return K.push((0,de.invalidInlineFragmentTypeConditionTypeErrorMessage)(n,v,xe,X,(0,$e.kindToNodeType)(ve.kind))),Z.BREAK}return K.push((0,de.invalidInlineFragmentTypeConditionErrorMessage)(n,v,X,(0,$e.kindToNodeType)(Fe.kind),xe)),Z.BREAK}},SelectionSet:{enter(){if(!ne){let pe=p[$];if(pe.kind===Z.Kind.UNION_TYPE_DEFINITION)return K.push((0,de.unparsableFieldSetSelectionErrorMessage)(n,z)),Z.BREAK;let Fe=pe.fieldDataByName.get(z);if(!Fe)return K.push((0,de.undefinedFieldInFieldSetErrorMessage)(n,pe.name,z)),Z.BREAK;let xe=(0,nr.getTypeNodeNamedTypeName)(Fe.node.type),et=l.parentDefinitionDataByTypeName.get(xe),X=et?et.kind:Z.Kind.SCALAR_TYPE_DEFINITION;return K.push((0,de.invalidSelectionSetDefinitionErrorMessage)(n,v,xe,(0,$e.kindToNodeType)(X))),Z.BREAK}if($+=1,ne=!1,$<0||$>=p.length)return K.push((0,de.unparsableFieldSetSelectionErrorMessage)(n,z)),Z.BREAK;y.push(new Set)},leave(){if(ne){let pe=p[$+1];K.push((0,de.invalidSelectionSetErrorMessage)(n,v,pe.name,(0,$e.kindToNodeType)(pe.kind))),ne=!1}$-=1,p.pop(),y.pop()}}}),K.length>0||!Te?{errorMessages:K}:{configuration:{fieldName:r,selectionSet:(0,ei.getNormalizedFieldSet)(c)},errorMessages:K}}validateProvidesOrRequires(t,n,r){let i=[],a=[],o=(0,Nn.getParentTypeName)(t);for(let[c,l]of n){let{fieldSetParentData:p,errorString:f}=this.getFieldSetParent(r,t,c,o),y=`${o}.${c}`;if(f){i.push(f);continue}if(!p)continue;let{errorMessages:g,configuration:v}=this.validateConditionalFieldSet(p,l,c,r,o);if(g.length>0){i.push(` On field "${y}": + -`+g.join(te.HYPHEN_JOIN));continue}v&&a.push(v)}if(i.length>0){this.errors.push((0,de.invalidProvidesOrRequiresDirectivesError)((0,ei.getConditionalFieldSetDirectiveName)(r),i));return}if(a.length>0)return a}validateInterfaceImplementations(t){if(t.implementedInterfaceTypeNames.size<1)return;let n=t.directivesByDirectiveName.has(te.INACCESSIBLE),r=new Map,i=new Map,a=!1;for(let o of t.implementedInterfaceTypeNames){let c=this.parentDefinitionDataByTypeName.get(o);if(Ht.BASE_SCALARS.has(o)&&this.referencedTypeNames.add(o),!c)continue;if(c.kind!==Z.Kind.INTERFACE_TYPE_DEFINITION){i.set(c.name,(0,$e.kindToNodeType)(c.kind));continue}if(t.name===c.name){a=!0;continue}let l={invalidFieldImplementations:new Map,unimplementedFields:[]},p=!1;for(let[f,y]of c.fieldDataByName){this.unvalidatedExternalFieldCoords.delete(`${t.name}.${f}`);let g=!1,v=t.fieldDataByName.get(f);if(!v){p=!0,l.unimplementedFields.push(f);continue}let P={invalidAdditionalArguments:new Set,invalidImplementedArguments:[],isInaccessible:!1,originalResponseType:(0,ma.printTypeNode)(y.node.type),unimplementedArguments:new Set};(0,Nn.isTypeValidImplementation)(y.node.type,v.node.type,this.concreteTypeNamesByAbstractTypeName)||(p=!0,g=!0,P.implementedResponseType=(0,ma.printTypeNode)(v.node.type));let U=new Set;for(let[K,$]of y.argumentDataByName){U.add(K);let ne=v.argumentDataByName.get(K);if(!ne){p=!0,g=!0,P.unimplementedArguments.add(K);continue}let z=(0,ma.printTypeNode)(ne.type),Te=(0,ma.printTypeNode)($.type);Te!==z&&(p=!0,g=!0,P.invalidImplementedArguments.push({actualType:z,argumentName:K,expectedType:Te}))}for(let[K,$]of v.argumentDataByName)U.has(K)||$.type.kind===Z.Kind.NON_NULL_TYPE&&(p=!0,g=!0,P.invalidAdditionalArguments.add(K));!n&&v.isInaccessible&&!y.isInaccessible&&(p=!0,g=!0,P.isInaccessible=!0),g&&l.invalidFieldImplementations.set(f,P)}p&&r.set(o,l)}i.size>0&&this.errors.push((0,de.invalidImplementedTypeError)(t.name,i)),a&&this.errors.push((0,de.selfImplementationError)(t.name)),r.size>0&&this.errors.push((0,de.invalidInterfaceImplementationError)(t.name,(0,$e.kindToNodeType)(t.kind),r))}handleAuthenticatedDirective(t,n){let r=(0,$e.getValueOrDefault)(this.authorizationDataByParentTypeName,n,()=>(0,rr.newAuthorizationData)(n));if(t.kind===Z.Kind.FIELD_DEFINITION){let i=(0,$e.getValueOrDefault)(r.fieldAuthDataByFieldName,t.name,()=>(0,rr.newFieldAuthorizationData)(t.name));i.inheritedData.requiresAuthentication=!0,i.originalData.requiresAuthentication=!0}else r.requiresAuthentication=!0,this.parentTypeNamesWithAuthDirectives.add(n)}handleOverrideDirective({data:t,directiveCoords:n,errorMessages:r,targetSubgraphName:i}){if(i===this.subgraphName){r.push((0,de.equivalentSourceAndTargetOverrideErrorMessage)(i,n));return}let a=(0,$e.getValueOrDefault)(this.overridesByTargetSubgraphName,i,()=>new Map);(0,$e.getValueOrDefault)(a,t.renamedParentTypeName,()=>new Set).add(t.name)}extractRequiredScopes({directiveCoords:t,orScopes:n,requiredScopes:r}){if(n.length>Ht.MAX_OR_SCOPES){this.invalidORScopesCoords.add(t);return}for(let i of n){let a=new Set;for(let o of i.values)a.add(o.value);a.size<1||(0,rr.addScopes)(r,a)}}getKafkaPublishConfiguration(t,n,r,i){let a=[],o=te.DEFAULT_EDFS_PROVIDER_ID;for(let c of t.arguments||[])switch(c.name.value){case te.TOPIC:{if(c.value.kind!==Z.Kind.STRING||c.value.value.length<1){i.push((0,de.invalidEventSubjectErrorMessage)(te.TOPIC));continue}(0,ei.validateArgumentTemplateReferences)(c.value.value,n,i),a.push(c.value.value);break}case te.PROVIDER_ID:{if(c.value.kind!==Z.Kind.STRING||c.value.value.length<1){i.push(de.invalidEventProviderIdErrorMessage);continue}o=c.value.value;break}}if(!(i.length>0))return{fieldName:r,providerId:o,providerType:te.PROVIDER_TYPE_KAFKA,topics:a,type:te.PUBLISH}}getKafkaSubscribeConfiguration(t,n,r,i){let a=[],o=te.DEFAULT_EDFS_PROVIDER_ID;for(let c of t.arguments||[])switch(c.name.value){case te.TOPICS:{if(c.value.kind!==Z.Kind.LIST){i.push((0,de.invalidEventSubjectsErrorMessage)(te.TOPICS));continue}for(let l of c.value.values){if(l.kind!==Z.Kind.STRING||l.value.length<1){i.push((0,de.invalidEventSubjectsItemErrorMessage)(te.TOPICS));break}(0,ei.validateArgumentTemplateReferences)(l.value,n,i),a.push(l.value)}break}case te.PROVIDER_ID:{if(c.value.kind!==Z.Kind.STRING||c.value.value.length<1){i.push(de.invalidEventProviderIdErrorMessage);continue}o=c.value.value;break}}if(!(i.length>0))return{fieldName:r,providerId:o,providerType:te.PROVIDER_TYPE_KAFKA,topics:a,type:te.SUBSCRIBE}}getNatsPublishAndRequestConfiguration(t,n,r,i,a){let o=[],c=te.DEFAULT_EDFS_PROVIDER_ID;for(let l of n.arguments||[])switch(l.name.value){case te.SUBJECT:{if(l.value.kind!==Z.Kind.STRING||l.value.value.length<1){a.push((0,de.invalidEventSubjectErrorMessage)(te.SUBJECT));continue}(0,ei.validateArgumentTemplateReferences)(l.value.value,r,a),o.push(l.value.value);break}case te.PROVIDER_ID:{if(l.value.kind!==Z.Kind.STRING||l.value.value.length<1){a.push(de.invalidEventProviderIdErrorMessage);continue}c=l.value.value;break}}if(!(a.length>0))return{fieldName:i,providerId:c,providerType:te.PROVIDER_TYPE_NATS,subjects:o,type:t}}getNatsSubscribeConfiguration(t,n,r,i){let a=[],o=te.DEFAULT_EDFS_PROVIDER_ID,c=AE.DEFAULT_CONSUMER_INACTIVE_THRESHOLD,l="",p="";for(let f of t.arguments||[])switch(f.name.value){case te.SUBJECTS:{if(f.value.kind!==Z.Kind.LIST){i.push((0,de.invalidEventSubjectsErrorMessage)(te.SUBJECTS));continue}for(let y of f.value.values){if(y.kind!==Z.Kind.STRING||y.value.length<1){i.push((0,de.invalidEventSubjectsItemErrorMessage)(te.SUBJECTS));break}(0,ei.validateArgumentTemplateReferences)(y.value,n,i),a.push(y.value)}break}case te.PROVIDER_ID:{if(f.value.kind!==Z.Kind.STRING||f.value.value.length<1){i.push(de.invalidEventProviderIdErrorMessage);continue}o=f.value.value;break}case te.STREAM_CONFIGURATION:{if(this.usesEdfsNatsStreamConfiguration=!0,f.value.kind!==Z.Kind.OBJECT||f.value.fields.length<1){i.push(de.invalidNatsStreamInputErrorMessage);continue}let y=!0,g=new Set,v=new Set(bE.STREAM_CONFIGURATION_FIELD_NAMES),P=new Set([te.CONSUMER_NAME,te.STREAM_NAME]),U=new Set,K=new Set;for(let $ of f.value.fields){let ne=$.name.value;if(!bE.STREAM_CONFIGURATION_FIELD_NAMES.has(ne)){g.add(ne),y=!1;continue}if(v.has(ne))v.delete(ne);else{U.add(ne),y=!1;continue}switch(P.has(ne)&&P.delete(ne),ne){case te.CONSUMER_NAME:if($.value.kind!=Z.Kind.STRING||$.value.value.length<1){K.add(ne),y=!1;continue}l=$.value.value;break;case te.STREAM_NAME:if($.value.kind!=Z.Kind.STRING||$.value.value.length<1){K.add(ne),y=!1;continue}p=$.value.value;break;case te.CONSUMER_INACTIVE_THRESHOLD:if($.value.kind!=Z.Kind.INT){i.push((0,de.invalidArgumentValueErrorMessage)((0,Z.print)($.value),"edfs__NatsStreamConfiguration","consumerInactiveThreshold",te.INT_SCALAR)),y=!1;continue}try{c=parseInt($.value.value,10)}catch(z){i.push((0,de.invalidArgumentValueErrorMessage)((0,Z.print)($.value),"edfs__NatsStreamConfiguration","consumerInactiveThreshold",te.INT_SCALAR)),y=!1}break}}(!y||P.size>0)&&i.push((0,de.invalidNatsStreamInputFieldsErrorMessage)([...P],[...U],[...K],[...g]))}}if(!(i.length>0))return c<0?(c=AE.DEFAULT_CONSUMER_INACTIVE_THRESHOLD,this.warnings.push((0,vs.consumerInactiveThresholdInvalidValueWarning)(this.subgraphName,`The value has been set to ${AE.DEFAULT_CONSUMER_INACTIVE_THRESHOLD}.`))):c>ule.MAX_INT32&&(c=0,this.warnings.push((0,vs.consumerInactiveThresholdInvalidValueWarning)(this.subgraphName,"The value has been set to 0. This means the consumer will remain indefinitely active until its manual deletion."))),x({fieldName:r,providerId:o,providerType:te.PROVIDER_TYPE_NATS,subjects:a,type:te.SUBSCRIBE},l&&p?{streamConfiguration:{consumerInactiveThreshold:c,consumerName:l,streamName:p}}:{})}getRedisPublishConfiguration(t,n,r,i){let a=[],o=te.DEFAULT_EDFS_PROVIDER_ID;for(let c of t.arguments||[])switch(c.name.value){case te.CHANNEL:{if(c.value.kind!==Z.Kind.STRING||c.value.value.length<1){i.push((0,de.invalidEventSubjectErrorMessage)(te.CHANNEL));continue}(0,ei.validateArgumentTemplateReferences)(c.value.value,n,i),a.push(c.value.value);break}case te.PROVIDER_ID:{if(c.value.kind!==Z.Kind.STRING||c.value.value.length<1){i.push(de.invalidEventProviderIdErrorMessage);continue}o=c.value.value;break}}if(!(i.length>0))return{fieldName:r,providerId:o,providerType:te.PROVIDER_TYPE_REDIS,channels:a,type:te.PUBLISH}}getRedisSubscribeConfiguration(t,n,r,i){let a=[],o=te.DEFAULT_EDFS_PROVIDER_ID;for(let c of t.arguments||[])switch(c.name.value){case te.CHANNELS:{if(c.value.kind!==Z.Kind.LIST){i.push((0,de.invalidEventSubjectsErrorMessage)(te.CHANNELS));continue}for(let l of c.value.values){if(l.kind!==Z.Kind.STRING||l.value.length<1){i.push((0,de.invalidEventSubjectsItemErrorMessage)(te.CHANNELS));break}(0,ei.validateArgumentTemplateReferences)(l.value,n,i),a.push(l.value)}break}case te.PROVIDER_ID:{if(c.value.kind!==Z.Kind.STRING||c.value.value.length<1){i.push(de.invalidEventProviderIdErrorMessage);continue}o=c.value.value;break}}if(!(i.length>0))return{fieldName:r,providerId:o,providerType:te.PROVIDER_TYPE_REDIS,channels:a,type:te.SUBSCRIBE}}validateSubscriptionFilterDirectiveLocation(t){if(!t.directives)return;let n=this.renamedParentTypeName||this.originalParentTypeName,r=`${n}.${t.name.value}`,i=this.getOperationTypeNodeForRootTypeName(n)===Z.OperationTypeNode.SUBSCRIPTION;for(let a of t.directives)if(a.name.value===te.SUBSCRIPTION_FILTER&&!i){this.errors.push((0,de.invalidSubscriptionFilterLocationError)(r));return}}extractEventDirectivesToConfiguration(t,n){if(!t.directives)return;let r=t.name.value,i=`${this.renamedParentTypeName||this.originalParentTypeName}.${r}`;for(let a of t.directives){let o=[],c;switch(a.name.value){case te.EDFS_KAFKA_PUBLISH:c=this.getKafkaPublishConfiguration(a,n,r,o);break;case te.EDFS_KAFKA_SUBSCRIBE:c=this.getKafkaSubscribeConfiguration(a,n,r,o);break;case te.EDFS_NATS_PUBLISH:{c=this.getNatsPublishAndRequestConfiguration(te.PUBLISH,a,n,r,o);break}case te.EDFS_NATS_REQUEST:{c=this.getNatsPublishAndRequestConfiguration(te.REQUEST,a,n,r,o);break}case te.EDFS_NATS_SUBSCRIBE:{c=this.getNatsSubscribeConfiguration(a,n,r,o);break}case te.EDFS_REDIS_PUBLISH:{c=this.getRedisPublishConfiguration(a,n,r,o);break}case te.EDFS_REDIS_SUBSCRIBE:{c=this.getRedisSubscribeConfiguration(a,n,r,o);break}default:continue}if(o.length>0){this.errors.push((0,de.invalidEventDirectiveError)(a.name.value,i,o));continue}c&&(0,$e.getValueOrDefault)(this.eventsConfigurations,this.renamedParentTypeName||this.originalParentTypeName,()=>[]).push(c)}}getValidEventsDirectiveNamesForOperationTypeNode(t){switch(t){case Z.OperationTypeNode.MUTATION:return new Set([te.EDFS_KAFKA_PUBLISH,te.EDFS_NATS_PUBLISH,te.EDFS_NATS_REQUEST,te.EDFS_REDIS_PUBLISH]);case Z.OperationTypeNode.QUERY:return new Set([te.EDFS_NATS_REQUEST]);case Z.OperationTypeNode.SUBSCRIPTION:return new Set([te.EDFS_KAFKA_SUBSCRIBE,te.EDFS_NATS_SUBSCRIBE,te.EDFS_REDIS_SUBSCRIBE])}}getOperationTypeNodeForRootTypeName(t){let n=this.operationTypeNodeByTypeName.get(t);if(n)return n;switch(t){case te.MUTATION:return Z.OperationTypeNode.MUTATION;case te.QUERY:return Z.OperationTypeNode.QUERY;case te.SUBSCRIPTION:return Z.OperationTypeNode.SUBSCRIPTION;default:return}}validateEventDrivenRootType(t,n,r,i){let a=this.getOperationTypeNodeForRootTypeName(t.name);if(!a){this.errors.push((0,de.invalidRootTypeError)(t.name));return}let o=this.getValidEventsDirectiveNamesForOperationTypeNode(a);for(let[c,l]of t.fieldDataByName){let p=`${l.originalParentTypeName}.${c}`,f=new Set;for(let K of bE.EVENT_DIRECTIVE_NAMES)l.directivesByDirectiveName.has(K)&&f.add(K);let y=new Set;for(let K of f)o.has(K)||y.add(K);if((f.size<1||y.size>0)&&n.set(p,{definesDirectives:f.size>0,invalidDirectiveNames:[...y]}),a===Z.OperationTypeNode.MUTATION){let K=(0,ma.printTypeNode)(l.type);K!==te.NON_NULLABLE_EDFS_PUBLISH_EVENT_RESULT&&i.set(p,K);continue}let g=(0,ma.printTypeNode)(l.type),v=l.namedTypeName+"!",P=!1,U=this.concreteTypeNamesByAbstractTypeName.get(l.namedTypeName)||new Set([l.namedTypeName]);for(let K of U)if(P||(P=this.entityDataByTypeName.has(K)),P)break;(!P||g!==v)&&r.set(p,g)}}validateEventDrivenKeyDefinition(t,n){let r=this.keyFieldSetDatasByTypeName.get(t);if(r)for(let[i,{isUnresolvable:a}]of r)a||(0,$e.getValueOrDefault)(n,t,()=>[]).push(i)}validateEventDrivenObjectFields(t,n,r,i){var a;for(let[o,c]of t){let l=`${c.originalParentTypeName}.${o}`;if(n.has(o)){(a=c.externalFieldDataBySubgraphName.get(this.subgraphName))!=null&&a.isDefinedExternal||r.set(l,o);continue}i.set(l,o)}}isEdfsPublishResultValid(){let t=this.parentDefinitionDataByTypeName.get(te.EDFS_PUBLISH_RESULT);if(!t)return!0;if(t.kind!==Z.Kind.OBJECT_TYPE_DEFINITION||t.fieldDataByName.size!=1)return!1;for(let[n,r]of t.fieldDataByName)if(r.argumentDataByName.size>0||n!==te.SUCCESS||(0,ma.printTypeNode)(r.type)!==te.NON_NULLABLE_BOOLEAN)return!1;return!0}isNatsStreamConfigurationInputObjectValid(t){if(t.kind!==Z.Kind.INPUT_OBJECT_TYPE_DEFINITION||t.inputValueDataByName.size!=3)return!1;for(let[n,r]of t.inputValueDataByName)switch(n){case te.CONSUMER_INACTIVE_THRESHOLD:{if((0,ma.printTypeNode)(r.type)!==te.NON_NULLABLE_INT||!r.defaultValue||r.defaultValue.kind!==Z.Kind.INT||r.defaultValue.value!==`${AE.DEFAULT_CONSUMER_INACTIVE_THRESHOLD}`)return!1;break}case te.CONSUMER_NAME:case te.STREAM_NAME:{if((0,ma.printTypeNode)(r.type)!==te.NON_NULLABLE_STRING)return!1;break}default:return!1}return!0}validateEventDrivenSubgraph(t){let n=[],r=new Map,i=new Map,a=new Map,o=new Map,c=new Map,l=new Map,p=new Set,f=new Set;for(let[y,g]of this.parentDefinitionDataByTypeName){if(y===te.EDFS_PUBLISH_RESULT||y===te.EDFS_NATS_STREAM_CONFIGURATION||g.kind!==Z.Kind.OBJECT_TYPE_DEFINITION)continue;if(g.isRootType){this.validateEventDrivenRootType(g,r,i,a);continue}let v=this.keyFieldNamesByParentTypeName.get(y);if(!v){f.add(y);continue}this.validateEventDrivenKeyDefinition(y,o),this.validateEventDrivenObjectFields(g.fieldDataByName,v,c,l)}if(this.isEdfsPublishResultValid()||n.push(de.invalidEdfsPublishResultObjectErrorMessage),this.edfsDirectiveReferences.has(te.EDFS_NATS_SUBSCRIBE)){let y=this.parentDefinitionDataByTypeName.get(te.EDFS_NATS_STREAM_CONFIGURATION);y&&this.usesEdfsNatsStreamConfiguration&&!this.isNatsStreamConfigurationInputObjectValid(y)&&n.push(de.invalidNatsStreamConfigurationDefinitionErrorMessage),this.parentDefinitionDataByTypeName.delete(te.EDFS_NATS_STREAM_CONFIGURATION),t.push(Ht.EDFS_NATS_STREAM_CONFIGURATION_DEFINITION)}this.referencedDirectiveNames.has(te.LINK)&&(t.push(Ht.LINK_DEFINITION),t.push(Ht.LINK_IMPORT_DEFINITION),t.push(Ht.LINK_PURPOSE_DEFINITION)),r.size>0&&n.push((0,de.invalidRootTypeFieldEventsDirectivesErrorMessage)(r)),a.size>0&&n.push((0,de.invalidEventDrivenMutationResponseTypeErrorMessage)(a)),i.size>0&&n.push((0,de.invalidRootTypeFieldResponseTypesEventDrivenErrorMessage)(i)),o.size>0&&n.push((0,de.invalidKeyFieldSetsEventDrivenErrorMessage)(o)),c.size>0&&n.push((0,de.nonExternalKeyFieldNamesEventDrivenErrorMessage)(c)),l.size>0&&n.push((0,de.nonKeyFieldNamesEventDrivenErrorMessage)(l)),p.size>0&&n.push((0,de.nonEntityObjectExtensionsEventDrivenErrorMessage)([...p])),f.size>0&&n.push((0,de.nonKeyComposingObjectTypeNamesEventDrivenErrorMessage)([...f])),n.length>0&&this.errors.push((0,de.invalidEventDrivenGraphError)(n))}validateUnionMembers(t){if(t.memberByMemberTypeName.size<1){this.errors.push((0,de.noDefinedUnionMembersError)(t.name));return}let n=[];for(let r of t.memberByMemberTypeName.keys()){let i=this.parentDefinitionDataByTypeName.get(r);i&&i.kind!==Z.Kind.OBJECT_TYPE_DEFINITION&&n.push(`"${r}", which is type "${(0,$e.kindToNodeType)(i.kind)}"`)}n.length>0&&this.errors.push((0,de.invalidUnionMemberTypeError)(t.name,n))}addConcreteTypeNamesForUnion(t){if(!t.types||t.types.length<1)return;let n=t.name.value;for(let r of t.types){let i=r.name.value;(0,$e.getValueOrDefault)(this.concreteTypeNamesByAbstractTypeName,n,()=>new Set).add(i),this.internalGraph.addEdge(this.internalGraph.addOrUpdateNode(n,{isAbstract:!0}),this.internalGraph.addOrUpdateNode(i),i,!0)}}addValidKeyFieldSetConfigurations(){for(let[t,n]of this.keyFieldSetDatasByTypeName){let r=this.parentDefinitionDataByTypeName.get(t);if(!r||r.kind!==Z.Kind.OBJECT_TYPE_DEFINITION&&r.kind!==Z.Kind.INTERFACE_TYPE_DEFINITION){this.errors.push((0,de.undefinedCompositeOutputTypeError)(t));continue}let i=(0,Nn.getParentTypeName)(r),a=(0,$e.getValueOrDefault)(this.configurationDataByTypeName,i,()=>(0,Qp.newConfigurationData)(!0,i)),o=(0,ei.validateKeyFieldSets)(this,r,n);o&&(a.keys=o)}}getValidFlattenedDirectiveArray(t,n,r=!1){let i=[];for(let[a,o]of t){if(r&&te.INHERITABLE_DIRECTIVE_NAMES.has(a))continue;let c=this.directiveDefinitionDataByDirectiveName.get(a);if(!c)continue;if(!c.isRepeatable&&o.length>1){let f=(0,$e.getValueOrDefault)(this.invalidRepeatedDirectiveNameByCoords,n,()=>new Set);f.has(a)||(f.add(a),this.errors.push((0,de.invalidDirectiveError)(a,n,"1st",[(0,de.invalidRepeatedDirectiveErrorMessage)(a)])));continue}if(a!==te.KEY){i.push(...o);continue}let l=[],p=new Set;for(let f=0;fnew Set).add(U)),(0,$e.getValueOrDefault)(a.keyFieldNamesByParentTypeName,v,()=>new Set).add(P);let ne=(0,nr.getTypeNodeNamedTypeName)(K.node.type);if(Ht.BASE_SCALARS.has(ne))return;let z=a.parentDefinitionDataByTypeName.get(ne);if(!z)return Z.BREAK;if(z.kind===Z.Kind.OBJECT_TYPE_DEFINITION){f=!0,c.push(z);return}if((0,On.isKindAbstract)(z.kind))return Z.BREAK}},InlineFragment:{enter(){return Z.BREAK}},SelectionSet:{enter(){if(!f||(p+=1,f=!1,p<0||p>=c.length))return Z.BREAK},leave(){f&&(f=!1),p-=1,c.pop()}}}),!(l.size<1))for(let[y,g]of l)this.warnings.push((0,vs.externalEntityExtensionKeyFieldWarning)(i.name,y,[...g],this.subgraphName))}}for(let n of t)this.keyFieldSetDatasByTypeName.delete(n)}addValidConditionalFieldSetConfigurations(){for(let[t,n]of this.fieldSetDataByTypeName){let r=this.parentDefinitionDataByTypeName.get(t);if(!r||r.kind!==Z.Kind.OBJECT_TYPE_DEFINITION&&r.kind!==Z.Kind.INTERFACE_TYPE_DEFINITION){this.errors.push((0,de.undefinedCompositeOutputTypeError)(t));continue}let i=(0,Nn.getParentTypeName)(r),a=(0,$e.getValueOrDefault)(this.configurationDataByTypeName,i,()=>(0,Qp.newConfigurationData)(!1,i)),o=this.validateProvidesOrRequires(r,n.provides,!0);o&&(a.provides=o);let c=this.validateProvidesOrRequires(r,n.requires,!1);c&&(a.requires=c)}}addFieldNamesToConfigurationData(t,n){let r=new Set;for(let[i,a]of t){let o=a.externalFieldDataBySubgraphName.get(this.subgraphName);if(!o||o.isUnconditionallyProvided){n.fieldNames.add(i);continue}r.add(i),this.edfsDirectiveReferences.size>0&&n.fieldNames.add(i)}r.size>0&&(n.externalFieldNames=r)}normalize(t){var a;(0,$q.upsertDirectiveSchemaAndEntityDefinitions)(this,t),(0,$q.upsertParentsAndChildren)(this,t),this.validateDirectives(this.schemaData,te.SCHEMA);for(let[o,c]of this.parentDefinitionDataByTypeName)this.validateDirectives(c,o);this.invalidORScopesCoords.size>0&&this.errors.push((0,de.orScopesLimitError)(Ht.MAX_OR_SCOPES,[...this.invalidORScopesCoords]));let n=[];for(let o of Ht.BASE_DIRECTIVE_DEFINITIONS)n.push(o);if(n.push(Ht.FIELD_SET_SCALAR_DEFINITION),this.isSubgraphVersionTwo){for(let o of Ht.VERSION_TWO_DIRECTIVE_DEFINITIONS)n.push(o),this.directiveDefinitionByDirectiveName.set(o.name.value,o);n.push(Ht.SCOPE_SCALAR_DEFINITION)}for(let o of this.edfsDirectiveReferences){let c=Ht.EVENT_DRIVEN_DIRECTIVE_DEFINITIONS_BY_DIRECTIVE_NAME.get(o);if(!c){this.errors.push((0,de.invalidEdfsDirectiveName)(o));continue}n.push(c)}this.edfsDirectiveReferences.size>0&&this.referencedDirectiveNames.has(te.SUBSCRIPTION_FILTER)&&(n.push(Ht.SUBSCRIPTION_FILTER_DEFINITION),n.push(Ht.SUBSCRIPTION_FILTER_CONDITION_DEFINITION),n.push(Ht.SUBSCRIPTION_FIELD_CONDITION_DEFINITION),n.push(Ht.SUBSCRIPTION_FILTER_VALUE_DEFINITION)),this.referencedDirectiveNames.has(te.CONFIGURE_DESCRIPTION)&&n.push(Ht.CONFIGURE_DESCRIPTION_DEFINITION),this.referencedDirectiveNames.has(te.CONFIGURE_CHILD_DESCRIPTIONS)&&n.push(Ht.CONFIGURE_CHILD_DESCRIPTIONS_DEFINITION);for(let o of this.customDirectiveDefinitions.values())n.push(o);this.schemaData.operationTypes.size>0&&n.push(this.getSchemaNodeByData(this.schemaData));for(let o of this.invalidConfigureDescriptionNodeDatas)o.description||this.errors.push((0,de.configureDescriptionNoDescriptionError)((0,$e.kindToNodeType)(o.kind),o.name));this.evaluateExternalKeyFields();for(let[o,c]of this.parentDefinitionDataByTypeName)switch(c.kind){case Z.Kind.ENUM_TYPE_DEFINITION:if(c.enumValueDataByValueName.size<1){this.errors.push((0,de.noDefinedEnumValuesError)(o));break}n.push(this.getEnumNodeByData(c));break;case Z.Kind.INPUT_OBJECT_TYPE_DEFINITION:if(c.inputValueDataByName.size<1){this.errors.push((0,de.noInputValueDefinitionsError)(o));break}for(let K of c.inputValueDataByName.values()){if(K.namedTypeKind!==Z.Kind.NULL)continue;let $=this.parentDefinitionDataByTypeName.get(K.namedTypeName);if($){if(!(0,Nn.isInputNodeKind)($.kind)){this.errors.push((0,de.invalidNamedTypeError)({data:K,namedTypeData:$,nodeType:`${(0,$e.kindToNodeType)(c.kind)} field`}));continue}K.namedTypeKind=$.kind}}n.push(this.getInputObjectNodeByData(c));break;case Z.Kind.INTERFACE_TYPE_DEFINITION:case Z.Kind.OBJECT_TYPE_DEFINITION:let l=this.entityDataByTypeName.has(o),p=this.operationTypeNodeByTypeName.get(o),f=c.kind===Z.Kind.OBJECT_TYPE_DEFINITION;this.isSubgraphVersionTwo&&c.extensionType===Ga.ExtensionType.EXTENDS&&(c.extensionType=Ga.ExtensionType.NONE),p&&(c.fieldDataByName.delete(te.SERVICE_FIELD),c.fieldDataByName.delete(te.ENTITIES_FIELD));let y=[];for(let[K,$]of c.fieldDataByName){if(!f&&((a=$.externalFieldDataBySubgraphName.get(this.subgraphName))!=null&&a.isDefinedExternal)&&y.push(K),this.validateArguments($,c.kind),$.namedTypeKind!==Z.Kind.NULL)continue;let ne=this.parentDefinitionDataByTypeName.get($.namedTypeName);if(ne){if(!(0,Nn.isOutputNodeKind)(ne.kind)){this.errors.push((0,de.invalidNamedTypeError)({data:$,namedTypeData:ne,nodeType:`${(0,$e.kindToNodeType)(c.kind)} field`}));continue}$.namedTypeKind=this.entityInterfaceDataByTypeName.get(ne.name)?Z.Kind.INTERFACE_TYPE_DEFINITION:ne.kind}}y.length>0&&(this.isSubgraphVersionTwo?this.errors.push((0,de.externalInterfaceFieldsError)(o,y)):this.warnings.push((0,vs.externalInterfaceFieldsWarning)(this.subgraphName,o,y)));let g=(0,Nn.getParentTypeName)(c),v=(0,$e.getValueOrDefault)(this.configurationDataByTypeName,g,()=>(0,Qp.newConfigurationData)(l,o)),P=this.entityInterfaceDataByTypeName.get(o);if(P){P.fieldDatas=(0,rr.fieldDatasToSimpleFieldDatas)(c.fieldDataByName.values());let K=this.concreteTypeNamesByAbstractTypeName.get(o);K&&(0,$e.addIterableValuesToSet)(K,P.concreteTypeNames),v.isInterfaceObject=P.isInterfaceObject,v.entityInterfaceConcreteTypeNames=P.concreteTypeNames}let U=this.eventsConfigurations.get(g);U&&(v.events=U),this.addFieldNamesToConfigurationData(c.fieldDataByName,v),this.validateInterfaceImplementations(c),n.push(this.getCompositeOutputNodeByData(c)),c.fieldDataByName.size<1&&!(0,ei.isNodeQuery)(o,p)&&this.errors.push((0,de.noFieldDefinitionsError)((0,$e.kindToNodeType)(c.kind),o));break;case Z.Kind.SCALAR_TYPE_DEFINITION:if(c.extensionType===Ga.ExtensionType.REAL){this.errors.push((0,de.noBaseScalarDefinitionError)(o));break}n.push(this.getScalarNodeByData(c));break;case Z.Kind.UNION_TYPE_DEFINITION:n.push(this.getUnionNodeByData(c)),this.validateUnionMembers(c);break;default:throw(0,de.unexpectedKindFatalError)(o)}this.addValidConditionalFieldSetConfigurations(),this.addValidKeyFieldSetConfigurations();for(let o of Object.values(Z.OperationTypeNode)){let c=this.schemaData.operationTypes.get(o),l=(0,$e.getOrThrowError)(On.operationTypeNodeToDefaultType,o,te.OPERATION_TO_DEFAULT),p=c?(0,nr.getTypeNodeNamedTypeName)(c.type):l;if(Ht.BASE_SCALARS.has(p)&&this.referencedTypeNames.add(p),p!==l&&this.parentDefinitionDataByTypeName.has(l)){this.errors.push((0,de.invalidRootTypeDefinitionError)(o,p,l));continue}let f=this.parentDefinitionDataByTypeName.get(p);if(c){if(!f)continue;this.operationTypeNodeByTypeName.set(p,o)}if(!f)continue;let y=this.configurationDataByTypeName.get(l);y&&(y.isRootNode=!0,y.typeName=l),f.kind!==Z.Kind.OBJECT_TYPE_DEFINITION&&this.errors.push((0,de.operationDefinitionError)(p,o,f.kind))}for(let o of this.referencedTypeNames){let c=this.parentDefinitionDataByTypeName.get(o);if(!c){this.errors.push((0,de.undefinedTypeError)(o));continue}if(c.kind!==Z.Kind.INTERFACE_TYPE_DEFINITION)continue;let l=this.concreteTypeNamesByAbstractTypeName.get(o);(!l||l.size<0)&&this.warnings.push((0,vs.unimplementedInterfaceOutputTypeWarning)(this.subgraphName,o))}let r=new Map;for(let o of this.directiveDefinitionByDirectiveName.values()){let c=(0,On.extractExecutableDirectiveLocations)(o.locations,new Set);c.size<1||this.addPersistedDirectiveDefinitionDataByNode(r,o,c)}this.isSubgraphEventDrivenGraph=this.edfsDirectiveReferences.size>0,this.isSubgraphEventDrivenGraph&&this.validateEventDrivenSubgraph(n);for(let o of this.unvalidatedExternalFieldCoords)this.isSubgraphVersionTwo?this.errors.push((0,de.invalidExternalDirectiveError)(o)):this.warnings.push((0,vs.invalidExternalFieldWarning)(o,this.subgraphName));if(this.errors.length>0)return{success:!1,errors:this.errors,warnings:this.warnings};let i={kind:Z.Kind.DOCUMENT,definitions:n};return{authorizationDataByParentTypeName:this.authorizationDataByParentTypeName,concreteTypeNamesByAbstractTypeName:this.concreteTypeNamesByAbstractTypeName,conditionalFieldDataByCoordinates:this.conditionalFieldDataByCoords,configurationDataByTypeName:this.configurationDataByTypeName,entityDataByTypeName:this.entityDataByTypeName,entityInterfaces:this.entityInterfaceDataByTypeName,fieldCoordsByNamedTypeName:this.fieldCoordsByNamedTypeName,isEventDrivenGraph:this.isSubgraphEventDrivenGraph,isVersionTwo:this.isSubgraphVersionTwo,keyFieldNamesByParentTypeName:this.keyFieldNamesByParentTypeName,keyFieldSetsByEntityTypeNameByKeyFieldCoords:this.keyFieldSetsByEntityTypeNameByFieldCoords,operationTypes:this.operationTypeNodeByTypeName,originalTypeNameByRenamedTypeName:this.originalTypeNameByRenamedTypeName,overridesByTargetSubgraphName:this.overridesByTargetSubgraphName,parentDefinitionDataByTypeName:this.parentDefinitionDataByTypeName,persistedDirectiveDefinitionDataByDirectiveName:r,subgraphAST:i,subgraphString:(0,Z.print)(i),schema:(0,sle.buildASTSchema)(i,{assumeValid:!0,assumeValidSDL:!0}),success:!0,warnings:this.warnings}}};hc.NormalizationFactory=Yp;function lle(e){let t=new Map,n=new Map,r=new Map,i=new Map,a=new Map,o=new Map,c=new Set,l=new Map,p=new Set,f=new Set,y=[],g=new Set,v=new Map,P=[],U=[];for(let ne of e)ne.name&&(0,ole.recordSubgraphName)(ne.name,p,f);let K=new zO.Graph;for(let ne=0;ne0&&P.push(...pe.warnings),!pe.success){U.push((0,de.subgraphValidationError)(Te,pe.errors));continue}if(!pe){U.push((0,de.subgraphValidationError)(Te,[de.subgraphValidationFailureError]));continue}l.set(Te,pe.parentDefinitionDataByTypeName);for(let Fe of pe.authorizationDataByParentTypeName.values())(0,rr.upsertAuthorizationData)(t,Fe,g);for(let[Fe,xe]of pe.fieldCoordsByNamedTypeName)(0,$e.addIterableValuesToSet)(xe,(0,$e.getValueOrDefault)(v,Fe,()=>new Set));for(let[Fe,xe]of pe.concreteTypeNamesByAbstractTypeName){let et=n.get(Fe);if(!et){n.set(Fe,new Set(xe));continue}(0,$e.addIterableValuesToSet)(xe,et)}for(let[Fe,xe]of pe.entityDataByTypeName){let et=xe.keyFieldSetDatasBySubgraphName.get(Te);et&&(0,rr.upsertEntityData)({entityDataByTypeName:r,keyFieldSetDataByFieldSet:et,typeName:Fe,subgraphName:Te})}if(z.name&&i.set(Te,{conditionalFieldDataByCoordinates:pe.conditionalFieldDataByCoordinates,configurationDataByTypeName:pe.configurationDataByTypeName,definitions:pe.subgraphAST,entityInterfaces:pe.entityInterfaces,isVersionTwo:pe.isVersionTwo,keyFieldNamesByParentTypeName:pe.keyFieldNamesByParentTypeName,name:Te,operationTypes:pe.operationTypes,overriddenFieldNamesByParentTypeName:new Map,parentDefinitionDataByTypeName:pe.parentDefinitionDataByTypeName,persistedDirectiveDefinitionDataByDirectiveName:pe.persistedDirectiveDefinitionDataByDirectiveName,schema:pe.schema,url:z.url}),!(pe.overridesByTargetSubgraphName.size<1))for(let[Fe,xe]of pe.overridesByTargetSubgraphName){let et=p.has(Fe);for(let[X,ve]of xe){let gt=pe.originalTypeNameByRenamedTypeName.get(X)||X;if(!et)P.push((0,vs.invalidOverrideTargetSubgraphNameWarning)(Fe,gt,[...ve],z.name));else{let zt=(0,$e.getValueOrDefault)(a,Fe,()=>new Map),Wt=(0,$e.getValueOrDefault)(zt,X,()=>new Set(ve));(0,$e.addIterableValuesToSet)(ve,Wt)}for(let zt of ve){let Wt=`${gt}.${zt}`,Dn=o.get(Wt);if(!Dn){o.set(Wt,[Te]);continue}Dn.push(Te),c.add(Wt)}}}}let $=[];if(g.size>0&&$.push((0,de.orScopesLimitError)(Ht.MAX_OR_SCOPES,[...g])),(y.length>0||f.size>0)&&$.push((0,de.invalidSubgraphNamesError)([...f],y)),c.size>0){let ne=[];for(let z of c){let Te=(0,$e.getOrThrowError)(o,z,"overrideSourceSubgraphNamesByFieldPath");ne.push((0,de.duplicateOverriddenFieldErrorMessage)(z,Te))}$.push((0,de.duplicateOverriddenFieldsError)(ne))}if($.push(...U),$.length>0)return{errors:$,success:!1,warnings:P};for(let[ne,z]of a){let Te=(0,$e.getOrThrowError)(i,ne,"internalSubgraphBySubgraphName");Te.overriddenFieldNamesByParentTypeName=z;for(let[pe,Fe]of z){let xe=Te.configurationDataByTypeName.get(pe);xe&&((0,rr.subtractSet)(Fe,xe.fieldNames),xe.fieldNames.size<1&&Te.configurationDataByTypeName.delete(pe))}}return{authorizationDataByParentTypeName:t,concreteTypeNamesByAbstractTypeName:n,entityDataByTypeName:r,fieldCoordsByNamedTypeName:v,internalSubgraphBySubgraphName:i,internalGraph:K,success:!0,warnings:P}}});var RE=w(gc=>{"use strict";m();T();N();Object.defineProperty(gc,"__esModule",{value:!0});gc.DivergentType=void 0;gc.getLeastRestrictiveMergedTypeNode=ple;gc.getMostRestrictiveMergedTypeNode=fle;gc.renameNamedTypeName=mle;var yc=Ae(),Jq=ia(),dle=ou(),Yq=Yr(),Hq=Nl(),Ic;(function(e){e[e.NONE=0]="NONE",e[e.CURRENT=1]="CURRENT",e[e.OTHER=2]="OTHER"})(Ic||(gc.DivergentType=Ic={}));function zq(e,t,n,r,i){t=(0,dle.getMutableTypeNode)(t,n,i);let a={kind:e.kind},o=Ic.NONE,c=a;for(let l=0;l{"use strict";m();T();N();Object.defineProperty(ZO,"__esModule",{value:!0});ZO.renameRootTypes=Ele;var Nle=Ae(),XO=Yr(),Tle=RE(),hu=ur(),_c=Jr();function Ele(e,t){let n,r=!1,i;(0,Nle.visit)(t.definitions,{FieldDefinition:{enter(a){let o=a.name.value;if(r&&(o===hu.SERVICE_FIELD||o===hu.ENTITIES_FIELD))return n.fieldDataByName.delete(o),!1;let c=n.name,l=(0,_c.getOrThrowError)(n.fieldDataByName,o,`${c}.fieldDataByFieldName`),p=t.operationTypes.get(l.namedTypeName);if(p){let f=(0,_c.getOrThrowError)(XO.operationTypeNodeToDefaultType,p,hu.OPERATION_TO_DEFAULT);l.namedTypeName!==f&&(0,Tle.renameNamedTypeName)(l,f,e.errors)}return i!=null&&i.has(o)&&l.isShareableBySubgraphName.delete(t.name),!1}},InterfaceTypeDefinition:{enter(a){let o=a.name.value;if(!e.entityInterfaceFederationDataByTypeName.get(o))return!1;n=(0,_c.getOrThrowError)(t.parentDefinitionDataByTypeName,o,hu.PARENT_DEFINITION_DATA)},leave(){n=void 0}},ObjectTypeDefinition:{enter(a){let o=a.name.value,c=t.operationTypes.get(o),l=c?(0,_c.getOrThrowError)(XO.operationTypeNodeToDefaultType,c,hu.OPERATION_TO_DEFAULT):o;n=(0,_c.getOrThrowError)(t.parentDefinitionDataByTypeName,o,hu.PARENT_DEFINITION_DATA),r=n.isRootType,!e.entityInterfaceFederationDataByTypeName.get(o)&&(e.addValidPrimaryKeyTargetsToEntityData(o),i=t.overriddenFieldNamesByParentTypeName.get(l),o!==l&&(n.name=l,t.parentDefinitionDataByTypeName.set(l,n),t.parentDefinitionDataByTypeName.delete(o)))},leave(){n=void 0,r=!1,i=void 0}},ObjectTypeExtension:{enter(a){let o=a.name.value,c=t.operationTypes.get(o),l=c?(0,_c.getOrThrowError)(XO.operationTypeNodeToDefaultType,c,hu.OPERATION_TO_DEFAULT):o;n=(0,_c.getOrThrowError)(t.parentDefinitionDataByTypeName,o,hu.PARENT_DEFINITION_DATA),r=n.isRootType,e.addValidPrimaryKeyTargetsToEntityData(o),i=t.overriddenFieldNamesByParentTypeName.get(o),o!==l&&(n.name=l,t.parentDefinitionDataByTypeName.set(l,n),t.parentDefinitionDataByTypeName.delete(o))},leave(){n=void 0,r=!1,i=void 0}}})}});var Wq=w((Yl,Jp)=>{"use strict";m();T();N();(function(){var e,t="4.17.21",n=200,r="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",i="Expected a function",a="Invalid `variable` option passed into `_.template`",o="__lodash_hash_undefined__",c=500,l="__lodash_placeholder__",p=1,f=2,y=4,g=1,v=2,P=1,U=2,K=4,$=8,ne=16,z=32,Te=64,pe=128,Fe=256,xe=512,et=30,X="...",ve=800,gt=16,zt=1,Wt=2,Dn=3,Vt=1/0,dn=9007199254740991,Ar=17976931348623157e292,Rr=NaN,Un=4294967295,$t=Un-1,bn=Un>>>1,oe=[["ary",pe],["bind",P],["bindKey",U],["curry",$],["curryRight",ne],["flip",xe],["partial",z],["partialRight",Te],["rearg",Fe]],De="[object Arguments]",_e="[object Array]",Ce="[object AsyncFunction]",_t="[object Boolean]",J="[object Date]",se="[object DOMException]",qe="[object Error]",Qe="[object Function]",Lt="[object GeneratorFunction]",tt="[object Map]",At="[object Number]",Ha="[object Null]",xr="[object Object]",za="[object Promise]",Lc="[object Proxy]",ha="[object RegExp]",pr="[object Set]",ni="[object String]",xt="[object Symbol]",fr="[object Undefined]",_u="[object WeakMap]",ya="[object WeakSet]",vu="[object ArrayBuffer]",A="[object DataView]",h="[object Float32Array]",I="[object Float64Array]",C="[object Int8Array]",G="[object Int16Array]",re="[object Int32Array]",le="[object Uint8Array]",ft="[object Uint8ClampedArray]",pn="[object Uint16Array]",tn="[object Uint32Array]",hn=/\b__p \+= '';/g,Xt=/\b(__p \+=) '' \+/g,D1=/(__e\(.*?\)|\b__t\)) \+\n'';/g,eb=/&(?:amp|lt|gt|quot|#39);/g,tb=/[&<>"']/g,b1=RegExp(eb.source),A1=RegExp(tb.source),R1=/<%-([\s\S]+?)%>/g,P1=/<%([\s\S]+?)%>/g,nb=/<%=([\s\S]+?)%>/g,F1=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,w1=/^\w*$/,L1=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,uh=/[\\^$.*+?()[\]{}|]/g,C1=RegExp(uh.source),ch=/^\s+/,B1=/\s/,U1=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,k1=/\{\n\/\* \[wrapped with (.+)\] \*/,M1=/,? & /,x1=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,q1=/[()=,{}\[\]\/\s]/,V1=/\\(\\)?/g,j1=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,rb=/\w*$/,K1=/^[-+]0x[0-9a-f]+$/i,G1=/^0b[01]+$/i,$1=/^\[object .+?Constructor\]$/,Q1=/^0o[0-7]+$/i,Y1=/^(?:0|[1-9]\d*)$/,J1=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,hf=/($^)/,H1=/['\n\r\u2028\u2029\\]/g,yf="\\ud800-\\udfff",z1="\\u0300-\\u036f",W1="\\ufe20-\\ufe2f",X1="\\u20d0-\\u20ff",ib=z1+W1+X1,ab="\\u2700-\\u27bf",sb="a-z\\xdf-\\xf6\\xf8-\\xff",Z1="\\xac\\xb1\\xd7\\xf7",ej="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",tj="\\u2000-\\u206f",nj=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",ob="A-Z\\xc0-\\xd6\\xd8-\\xde",ub="\\ufe0e\\ufe0f",cb=Z1+ej+tj+nj,lh="['\u2019]",rj="["+yf+"]",lb="["+cb+"]",If="["+ib+"]",db="\\d+",ij="["+ab+"]",pb="["+sb+"]",fb="[^"+yf+cb+db+ab+sb+ob+"]",dh="\\ud83c[\\udffb-\\udfff]",aj="(?:"+If+"|"+dh+")",mb="[^"+yf+"]",ph="(?:\\ud83c[\\udde6-\\uddff]){2}",fh="[\\ud800-\\udbff][\\udc00-\\udfff]",Cc="["+ob+"]",Nb="\\u200d",Tb="(?:"+pb+"|"+fb+")",sj="(?:"+Cc+"|"+fb+")",Eb="(?:"+lh+"(?:d|ll|m|re|s|t|ve))?",hb="(?:"+lh+"(?:D|LL|M|RE|S|T|VE))?",yb=aj+"?",Ib="["+ub+"]?",oj="(?:"+Nb+"(?:"+[mb,ph,fh].join("|")+")"+Ib+yb+")*",uj="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",cj="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",gb=Ib+yb+oj,lj="(?:"+[ij,ph,fh].join("|")+")"+gb,dj="(?:"+[mb+If+"?",If,ph,fh,rj].join("|")+")",pj=RegExp(lh,"g"),fj=RegExp(If,"g"),mh=RegExp(dh+"(?="+dh+")|"+dj+gb,"g"),mj=RegExp([Cc+"?"+pb+"+"+Eb+"(?="+[lb,Cc,"$"].join("|")+")",sj+"+"+hb+"(?="+[lb,Cc+Tb,"$"].join("|")+")",Cc+"?"+Tb+"+"+Eb,Cc+"+"+hb,cj,uj,db,lj].join("|"),"g"),Nj=RegExp("["+Nb+yf+ib+ub+"]"),Tj=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Ej=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],hj=-1,Tn={};Tn[h]=Tn[I]=Tn[C]=Tn[G]=Tn[re]=Tn[le]=Tn[ft]=Tn[pn]=Tn[tn]=!0,Tn[De]=Tn[_e]=Tn[vu]=Tn[_t]=Tn[A]=Tn[J]=Tn[qe]=Tn[Qe]=Tn[tt]=Tn[At]=Tn[xr]=Tn[ha]=Tn[pr]=Tn[ni]=Tn[_u]=!1;var fn={};fn[De]=fn[_e]=fn[vu]=fn[A]=fn[_t]=fn[J]=fn[h]=fn[I]=fn[C]=fn[G]=fn[re]=fn[tt]=fn[At]=fn[xr]=fn[ha]=fn[pr]=fn[ni]=fn[xt]=fn[le]=fn[ft]=fn[pn]=fn[tn]=!0,fn[qe]=fn[Qe]=fn[_u]=!1;var yj={\u00C0:"A",\u00C1:"A",\u00C2:"A",\u00C3:"A",\u00C4:"A",\u00C5:"A",\u00E0:"a",\u00E1:"a",\u00E2:"a",\u00E3:"a",\u00E4:"a",\u00E5:"a",\u00C7:"C",\u00E7:"c",\u00D0:"D",\u00F0:"d",\u00C8:"E",\u00C9:"E",\u00CA:"E",\u00CB:"E",\u00E8:"e",\u00E9:"e",\u00EA:"e",\u00EB:"e",\u00CC:"I",\u00CD:"I",\u00CE:"I",\u00CF:"I",\u00EC:"i",\u00ED:"i",\u00EE:"i",\u00EF:"i",\u00D1:"N",\u00F1:"n",\u00D2:"O",\u00D3:"O",\u00D4:"O",\u00D5:"O",\u00D6:"O",\u00D8:"O",\u00F2:"o",\u00F3:"o",\u00F4:"o",\u00F5:"o",\u00F6:"o",\u00F8:"o",\u00D9:"U",\u00DA:"U",\u00DB:"U",\u00DC:"U",\u00F9:"u",\u00FA:"u",\u00FB:"u",\u00FC:"u",\u00DD:"Y",\u00FD:"y",\u00FF:"y",\u00C6:"Ae",\u00E6:"ae",\u00DE:"Th",\u00FE:"th",\u00DF:"ss",\u0100:"A",\u0102:"A",\u0104:"A",\u0101:"a",\u0103:"a",\u0105:"a",\u0106:"C",\u0108:"C",\u010A:"C",\u010C:"C",\u0107:"c",\u0109:"c",\u010B:"c",\u010D:"c",\u010E:"D",\u0110:"D",\u010F:"d",\u0111:"d",\u0112:"E",\u0114:"E",\u0116:"E",\u0118:"E",\u011A:"E",\u0113:"e",\u0115:"e",\u0117:"e",\u0119:"e",\u011B:"e",\u011C:"G",\u011E:"G",\u0120:"G",\u0122:"G",\u011D:"g",\u011F:"g",\u0121:"g",\u0123:"g",\u0124:"H",\u0126:"H",\u0125:"h",\u0127:"h",\u0128:"I",\u012A:"I",\u012C:"I",\u012E:"I",\u0130:"I",\u0129:"i",\u012B:"i",\u012D:"i",\u012F:"i",\u0131:"i",\u0134:"J",\u0135:"j",\u0136:"K",\u0137:"k",\u0138:"k",\u0139:"L",\u013B:"L",\u013D:"L",\u013F:"L",\u0141:"L",\u013A:"l",\u013C:"l",\u013E:"l",\u0140:"l",\u0142:"l",\u0143:"N",\u0145:"N",\u0147:"N",\u014A:"N",\u0144:"n",\u0146:"n",\u0148:"n",\u014B:"n",\u014C:"O",\u014E:"O",\u0150:"O",\u014D:"o",\u014F:"o",\u0151:"o",\u0154:"R",\u0156:"R",\u0158:"R",\u0155:"r",\u0157:"r",\u0159:"r",\u015A:"S",\u015C:"S",\u015E:"S",\u0160:"S",\u015B:"s",\u015D:"s",\u015F:"s",\u0161:"s",\u0162:"T",\u0164:"T",\u0166:"T",\u0163:"t",\u0165:"t",\u0167:"t",\u0168:"U",\u016A:"U",\u016C:"U",\u016E:"U",\u0170:"U",\u0172:"U",\u0169:"u",\u016B:"u",\u016D:"u",\u016F:"u",\u0171:"u",\u0173:"u",\u0174:"W",\u0175:"w",\u0176:"Y",\u0177:"y",\u0178:"Y",\u0179:"Z",\u017B:"Z",\u017D:"Z",\u017A:"z",\u017C:"z",\u017E:"z",\u0132:"IJ",\u0133:"ij",\u0152:"Oe",\u0153:"oe",\u0149:"'n",\u017F:"s"},Ij={"&":"&","<":"<",">":">",'"':""","'":"'"},gj={"&":"&","<":"<",">":">",""":'"',"'":"'"},_j={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},vj=parseFloat,Sj=parseInt,_b=typeof global=="object"&&global&&global.Object===Object&&global,Oj=typeof self=="object"&&self&&self.Object===Object&&self,ir=_b||Oj||Function("return this")(),Nh=typeof Yl=="object"&&Yl&&!Yl.nodeType&&Yl,Su=Nh&&typeof Jp=="object"&&Jp&&!Jp.nodeType&&Jp,vb=Su&&Su.exports===Nh,Th=vb&&_b.process,Ni=function(){try{var Q=Su&&Su.require&&Su.require("util").types;return Q||Th&&Th.binding&&Th.binding("util")}catch(ce){}}(),Sb=Ni&&Ni.isArrayBuffer,Ob=Ni&&Ni.isDate,Db=Ni&&Ni.isMap,bb=Ni&&Ni.isRegExp,Ab=Ni&&Ni.isSet,Rb=Ni&&Ni.isTypedArray;function ri(Q,ce,ie){switch(ie.length){case 0:return Q.call(ce);case 1:return Q.call(ce,ie[0]);case 2:return Q.call(ce,ie[0],ie[1]);case 3:return Q.call(ce,ie[0],ie[1],ie[2])}return Q.apply(ce,ie)}function Dj(Q,ce,ie,Be){for(var ot=-1,jt=Q==null?0:Q.length;++ot-1}function Eh(Q,ce,ie){for(var Be=-1,ot=Q==null?0:Q.length;++Be-1;);return ie}function kb(Q,ce){for(var ie=Q.length;ie--&&Bc(ce,Q[ie],0)>-1;);return ie}function Bj(Q,ce){for(var ie=Q.length,Be=0;ie--;)Q[ie]===ce&&++Be;return Be}var Uj=gh(yj),kj=gh(Ij);function Mj(Q){return"\\"+_j[Q]}function xj(Q,ce){return Q==null?e:Q[ce]}function Uc(Q){return Nj.test(Q)}function qj(Q){return Tj.test(Q)}function Vj(Q){for(var ce,ie=[];!(ce=Q.next()).done;)ie.push(ce.value);return ie}function Oh(Q){var ce=-1,ie=Array(Q.size);return Q.forEach(function(Be,ot){ie[++ce]=[ot,Be]}),ie}function Mb(Q,ce){return function(ie){return Q(ce(ie))}}function qo(Q,ce){for(var ie=-1,Be=Q.length,ot=0,jt=[];++ie-1}function AK(s,u){var d=this.__data__,E=Mf(d,s);return E<0?(++this.size,d.push([s,u])):d[E][1]=u,this}Wa.prototype.clear=SK,Wa.prototype.delete=OK,Wa.prototype.get=DK,Wa.prototype.has=bK,Wa.prototype.set=AK;function Xa(s){var u=-1,d=s==null?0:s.length;for(this.clear();++u=u?s:u)),s}function yi(s,u,d,E,S,L){var M,j=u&p,H=u&f,fe=u&y;if(d&&(M=S?d(s,E,S,L):d(s)),M!==e)return M;if(!_n(s))return s;var me=lt(s);if(me){if(M=wG(s),!j)return qr(s,M)}else{var Ee=Er(s),be=Ee==Qe||Ee==Lt;if(Yo(s))return I0(s,j);if(Ee==xr||Ee==De||be&&!S){if(M=H||be?{}:x0(s),!j)return H?gG(s,GK(M,s)):IG(s,zb(M,s))}else{if(!fn[Ee])return S?s:{};M=LG(s,Ee,j)}}L||(L=new Qi);var je=L.get(s);if(je)return je;L.set(s,M),mA(s)?s.forEach(function(Ze){M.add(yi(Ze,u,d,Ze,s,L))}):pA(s)&&s.forEach(function(Ze,vt){M.set(vt,yi(Ze,u,d,vt,s,L))});var Xe=fe?H?Wh:zh:H?jr:ar,Et=me?e:Xe(s);return Ti(Et||s,function(Ze,vt){Et&&(vt=Ze,Ze=s[vt]),dd(M,vt,yi(Ze,u,d,vt,s,L))}),M}function $K(s){var u=ar(s);return function(d){return Wb(d,s,u)}}function Wb(s,u,d){var E=d.length;if(s==null)return!E;for(s=on(s);E--;){var S=d[E],L=u[S],M=s[S];if(M===e&&!(S in s)||!L(M))return!1}return!0}function Xb(s,u,d){if(typeof s!="function")throw new Ei(i);return hd(function(){s.apply(e,d)},u)}function pd(s,u,d,E){var S=-1,L=gf,M=!0,j=s.length,H=[],fe=u.length;if(!j)return H;d&&(u=yn(u,ii(d))),E?(L=Eh,M=!1):u.length>=n&&(L=ad,M=!1,u=new bu(u));e:for(;++SS?0:S+d),E=E===e||E>S?S:Nt(E),E<0&&(E+=S),E=d>E?0:TA(E);d0&&d(j)?u>1?mr(j,u-1,d,E,S):xo(S,j):E||(S[S.length]=j)}return S}var wh=D0(),t0=D0(!0);function Ia(s,u){return s&&wh(s,u,ar)}function Lh(s,u){return s&&t0(s,u,ar)}function qf(s,u){return Mo(u,function(d){return rs(s[d])})}function Ru(s,u){u=$o(u,s);for(var d=0,E=u.length;s!=null&&du}function JK(s,u){return s!=null&&Zt.call(s,u)}function HK(s,u){return s!=null&&u in on(s)}function zK(s,u,d){return s>=Tr(u,d)&&s=120&&me.length>=120)?new bu(M&&me):e}me=s[0];var Ee=-1,be=j[0];e:for(;++Ee-1;)j!==s&&Ff.call(j,H,1),Ff.call(s,H,1);return s}function p0(s,u){for(var d=s?u.length:0,E=d-1;d--;){var S=u[d];if(d==E||S!==L){var L=S;ns(S)?Ff.call(s,S,1):Kh(s,S)}}return s}function qh(s,u){return s+Cf(Qb()*(u-s+1))}function cG(s,u,d,E){for(var S=-1,L=Jn(Lf((u-s)/(d||1)),0),M=ie(L);L--;)M[E?L:++S]=s,s+=d;return M}function Vh(s,u){var d="";if(!s||u<1||u>dn)return d;do u%2&&(d+=s),u=Cf(u/2),u&&(s+=s);while(u);return d}function yt(s,u){return iy(j0(s,u,Kr),s+"")}function lG(s){return Hb(Qc(s))}function dG(s,u){var d=Qc(s);return Wf(d,Au(u,0,d.length))}function Nd(s,u,d,E){if(!_n(s))return s;u=$o(u,s);for(var S=-1,L=u.length,M=L-1,j=s;j!=null&&++SS?0:S+u),d=d>S?S:d,d<0&&(d+=S),S=u>d?0:d-u>>>0,u>>>=0;for(var L=ie(S);++E>>1,M=s[L];M!==null&&!si(M)&&(d?M<=u:M=n){var fe=u?null:OG(s);if(fe)return vf(fe);M=!1,S=ad,H=new bu}else H=u?[]:j;e:for(;++E=E?s:Ii(s,u,d)}var y0=nK||function(s){return ir.clearTimeout(s)};function I0(s,u){if(u)return s.slice();var d=s.length,E=Vb?Vb(d):new s.constructor(d);return s.copy(E),E}function Yh(s){var u=new s.constructor(s.byteLength);return new Rf(u).set(new Rf(s)),u}function TG(s,u){var d=u?Yh(s.buffer):s.buffer;return new s.constructor(d,s.byteOffset,s.byteLength)}function EG(s){var u=new s.constructor(s.source,rb.exec(s));return u.lastIndex=s.lastIndex,u}function hG(s){return ld?on(ld.call(s)):{}}function g0(s,u){var d=u?Yh(s.buffer):s.buffer;return new s.constructor(d,s.byteOffset,s.length)}function _0(s,u){if(s!==u){var d=s!==e,E=s===null,S=s===s,L=si(s),M=u!==e,j=u===null,H=u===u,fe=si(u);if(!j&&!fe&&!L&&s>u||L&&M&&H&&!j&&!fe||E&&M&&H||!d&&H||!S)return 1;if(!E&&!L&&!fe&&s=j)return H;var fe=d[E];return H*(fe=="desc"?-1:1)}}return s.index-u.index}function v0(s,u,d,E){for(var S=-1,L=s.length,M=d.length,j=-1,H=u.length,fe=Jn(L-M,0),me=ie(H+fe),Ee=!E;++j1?d[S-1]:e,M=S>2?d[2]:e;for(L=s.length>3&&typeof L=="function"?(S--,L):e,M&&Fr(d[0],d[1],M)&&(L=S<3?e:L,S=1),u=on(u);++E-1?S[L?u[M]:M]:e}}function R0(s){return ts(function(u){var d=u.length,E=d,S=hi.prototype.thru;for(s&&u.reverse();E--;){var L=u[E];if(typeof L!="function")throw new Ei(i);if(S&&!M&&Hf(L)=="wrapper")var M=new hi([],!0)}for(E=M?E:d;++E1&&Rt.reverse(),me&&Hj))return!1;var fe=L.get(s),me=L.get(u);if(fe&&me)return fe==u&&me==s;var Ee=-1,be=!0,je=d&v?new bu:e;for(L.set(s,u),L.set(u,s);++Ee1?"& ":"")+u[E],u=u.join(d>2?", ":" "),s.replace(U1,`{ /* [wrapped with `+u+`] */ -`)}function BG(s){return lt(s)||wu(s)||!!(Gb&&s&&s[Gb])}function ns(s,u){var d=typeof s;return u=u==null?dn:u,!!u&&(d=="number"||d!="symbol"&&Y1.test(s))&&s>-1&&s%1==0&&s0){if(++u>=ve)return arguments[0]}else u=0;return s.apply(e,arguments)}}function Wf(s,u){var d=-1,E=s.length,S=E-1;for(u=u===e?E:u;++d1?s[u-1]:e;return d=typeof d=="function"?(s.pop(),d):e,eA(s,d)});function tA(s){var u=R(s);return u.__chain__=!0,u}function Q$(s,u){return u(s),s}function Xf(s,u){return u(s)}var Y$=ts(function(s){var u=s.length,d=u?s[0]:0,E=this.__wrapped__,S=function(L){return Fh(L,s)};return u>1||this.__actions__.length||!(E instanceof Ot)||!ns(d)?this.thru(S):(E=E.slice(d,+d+(u?1:0)),E.__actions__.push({func:Xf,args:[S],thisArg:e}),new hi(E,this.__chain__).thru(function(L){return u&&!L.length&&L.push(e),L}))});function J$(){return tA(this)}function H$(){return new hi(this.value(),this.__chain__)}function z$(){this.__values__===e&&(this.__values__=NA(this.value()));var s=this.__index__>=this.__values__.length,u=s?e:this.__values__[this.__index__++];return{done:s,value:u}}function W$(){return this}function X$(s){for(var u,d=this;d instanceof kf;){var E=J0(d);E.__index__=0,E.__values__=e,u?S.__wrapped__=E:u=E;var S=E;d=d.__wrapped__}return S.__wrapped__=s,u}function Z$(){var s=this.__wrapped__;if(s instanceof Ot){var u=s;return this.__actions__.length&&(u=new Ot(this)),u=u.reverse(),u.__actions__.push({func:Xf,args:[ay],thisArg:e}),new hi(u,this.__chain__)}return this.thru(ay)}function eQ(){return E0(this.__wrapped__,this.__actions__)}var tQ=Gf(function(s,u,d){Zt.call(s,d)?++s[d]:Za(s,d,1)});function nQ(s,u,d){var E=lt(s)?Pb:QK;return d&&Fr(s,u,d)&&(u=e),E(s,ze(u,3))}function rQ(s,u){var d=lt(s)?Mo:e0;return d(s,ze(u,3))}var iQ=A0(H0),aQ=A0(z0);function sQ(s,u){return mr(Zf(s,u),1)}function oQ(s,u){return mr(Zf(s,u),Vt)}function uQ(s,u,d){return d=d===e?1:Nt(d),mr(Zf(s,u),d)}function nA(s,u){var d=lt(s)?Ti:Ko;return d(s,ze(u,3))}function rA(s,u){var d=lt(s)?bj:Zb;return d(s,ze(u,3))}var cQ=Gf(function(s,u,d){Zt.call(s,d)?s[d].push(u):Za(s,d,[u])});function lQ(s,u,d,E){s=Vr(s)?s:Qc(s),d=d&&!E?Nt(d):0;var S=s.length;return d<0&&(d=Jn(S+d,0)),im(s)?d<=S&&s.indexOf(u,d)>-1:!!S&&Bc(s,u,d)>-1}var dQ=yt(function(s,u,d){var E=-1,S=typeof u=="function",L=Vr(s)?ie(s.length):[];return Ko(s,function(M){L[++E]=S?ri(u,M,d):fd(M,u,d)}),L}),pQ=Gf(function(s,u,d){Za(s,d,u)});function Zf(s,u){var d=lt(s)?yn:s0;return d(s,ze(u,3))}function fQ(s,u,d,E){return s==null?[]:(lt(u)||(u=u==null?[]:[u]),d=E?e:d,lt(d)||(d=d==null?[]:[d]),l0(s,u,d))}var mQ=Gf(function(s,u,d){s[d?0:1].push(u)},function(){return[[],[]]});function NQ(s,u,d){var E=lt(s)?hh:Cb,S=arguments.length<3;return E(s,ze(u,4),d,S,Ko)}function TQ(s,u,d){var E=lt(s)?Aj:Cb,S=arguments.length<3;return E(s,ze(u,4),d,S,Zb)}function EQ(s,u){var d=lt(s)?Mo:e0;return d(s,nm(ze(u,3)))}function hQ(s){var u=lt(s)?Hb:lG;return u(s)}function yQ(s,u,d){(d?Fr(s,u,d):u===e)?u=1:u=Nt(u);var E=lt(s)?VK:dG;return E(s,u)}function IQ(s){var u=lt(s)?jK:fG;return u(s)}function gQ(s){if(s==null)return 0;if(Vr(s))return im(s)?kc(s):s.length;var u=Er(s);return u==tt||u==pr?s.size:kh(s).length}function _Q(s,u,d){var E=lt(s)?yh:mG;return d&&Fr(s,u,d)&&(u=e),E(s,ze(u,3))}var vQ=yt(function(s,u){if(s==null)return[];var d=u.length;return d>1&&Fr(s,u[0],u[1])?u=[]:d>2&&Fr(u[0],u[1],u[2])&&(u=[u[0]]),l0(s,mr(u,1),[])}),em=rK||function(){return ir.Date.now()};function SQ(s,u){if(typeof u!="function")throw new Ei(i);return s=Nt(s),function(){if(--s<1)return u.apply(this,arguments)}}function iA(s,u,d){return u=d?e:u,u=s&&u==null?s.length:u,es(s,pe,e,e,e,e,u)}function aA(s,u){var d;if(typeof u!="function")throw new Ei(i);return s=Nt(s),function(){return--s>0&&(d=u.apply(this,arguments)),s<=1&&(u=e),d}}var oy=yt(function(s,u,d){var E=F;if(d.length){var S=qo(d,Gc(oy));E|=z}return es(s,E,u,d,S)}),sA=yt(function(s,u,d){var E=F|k;if(d.length){var S=qo(d,Gc(sA));E|=z}return es(u,E,s,d,S)});function oA(s,u,d){u=d?e:u;var E=es(s,$,e,e,e,e,e,u);return E.placeholder=oA.placeholder,E}function uA(s,u,d){u=d?e:u;var E=es(s,ne,e,e,e,e,e,u);return E.placeholder=uA.placeholder,E}function cA(s,u,d){var E,S,L,M,j,H,fe=0,me=!1,Ee=!1,be=!0;if(typeof s!="function")throw new Ei(i);u=_i(u)||0,_n(d)&&(me=!!d.leading,Ee="maxWait"in d,L=Ee?Jn(_i(d.maxWait)||0,u):L,be="trailing"in d?!!d.trailing:be);function je(Mn){var Ji=E,as=S;return E=S=e,fe=Mn,M=s.apply(as,Ji),M}function Xe(Mn){return fe=Mn,j=hd(vt,u),me?je(Mn):M}function Et(Mn){var Ji=Mn-H,as=Mn-fe,AA=u-Ji;return Ee?Tr(AA,L-as):AA}function Ze(Mn){var Ji=Mn-H,as=Mn-fe;return H===e||Ji>=u||Ji<0||Ee&&as>=L}function vt(){var Mn=em();if(Ze(Mn))return Rt(Mn);j=hd(vt,Et(Mn))}function Rt(Mn){return j=e,be&&E?je(Mn):(E=S=e,M)}function oi(){j!==e&&y0(j),fe=0,E=H=S=j=e}function wr(){return j===e?M:Rt(em())}function ui(){var Mn=em(),Ji=Ze(Mn);if(E=arguments,S=this,H=Mn,Ji){if(j===e)return Xe(H);if(Ee)return y0(j),j=hd(vt,u),je(H)}return j===e&&(j=hd(vt,u)),M}return ui.cancel=oi,ui.flush=wr,ui}var OQ=yt(function(s,u){return Xb(s,1,u)}),DQ=yt(function(s,u,d){return Xb(s,_i(u)||0,d)});function bQ(s){return es(s,Ve)}function tm(s,u){if(typeof s!="function"||u!=null&&typeof u!="function")throw new Ei(i);var d=function(){var E=arguments,S=u?u.apply(this,E):E[0],L=d.cache;if(L.has(S))return L.get(S);var M=s.apply(this,E);return d.cache=L.set(S,M)||L,M};return d.cache=new(tm.Cache||Xa),d}tm.Cache=Xa;function nm(s){if(typeof s!="function")throw new Ei(i);return function(){var u=arguments;switch(u.length){case 0:return!s.call(this);case 1:return!s.call(this,u[0]);case 2:return!s.call(this,u[0],u[1]);case 3:return!s.call(this,u[0],u[1],u[2])}return!s.apply(this,u)}}function AQ(s){return aA(2,s)}var RQ=NG(function(s,u){u=u.length==1&<(u[0])?yn(u[0],ii(ze())):yn(mr(u,1),ii(ze()));var d=u.length;return yt(function(E){for(var S=-1,L=Tr(E.length,d);++S=u}),wu=r0(function(){return arguments}())?r0:function(s){return An(s)&&Zt.call(s,"callee")&&!Kb.call(s,"callee")},lt=ie.isArray,GQ=Sb?ii(Sb):XK;function Vr(s){return s!=null&&rm(s.length)&&!rs(s)}function kn(s){return An(s)&&Vr(s)}function $Q(s){return s===!0||s===!1||An(s)&&Pr(s)==_t}var Yo=aK||yy,QQ=Ob?ii(Ob):ZK;function YQ(s){return An(s)&&s.nodeType===1&&!yd(s)}function JQ(s){if(s==null)return!0;if(Vr(s)&&(lt(s)||typeof s=="string"||typeof s.splice=="function"||Yo(s)||$c(s)||wu(s)))return!s.length;var u=Er(s);if(u==tt||u==pr)return!s.size;if(Ed(s))return!kh(s).length;for(var d in s)if(Zt.call(s,d))return!1;return!0}function HQ(s,u){return md(s,u)}function zQ(s,u,d){d=typeof d=="function"?d:e;var E=d?d(s,u):e;return E===e?md(s,u,e,d):!!E}function cy(s){if(!An(s))return!1;var u=Pr(s);return u==xe||u==se||typeof s.message=="string"&&typeof s.name=="string"&&!yd(s)}function WQ(s){return typeof s=="number"&&$b(s)}function rs(s){if(!_n(s))return!1;var u=Pr(s);return u==Qe||u==Lt||u==Ce||u==Lc}function dA(s){return typeof s=="number"&&s==Nt(s)}function rm(s){return typeof s=="number"&&s>-1&&s%1==0&&s<=dn}function _n(s){var u=typeof s;return s!=null&&(u=="object"||u=="function")}function An(s){return s!=null&&typeof s=="object"}var pA=Db?ii(Db):tG;function XQ(s,u){return s===u||Uh(s,u,Zh(u))}function ZQ(s,u,d){return d=typeof d=="function"?d:e,Uh(s,u,Zh(u),d)}function e2(s){return fA(s)&&s!=+s}function t2(s){if(MG(s))throw new ot(r);return i0(s)}function n2(s){return s===null}function r2(s){return s==null}function fA(s){return typeof s=="number"||An(s)&&Pr(s)==At}function yd(s){if(!An(s)||Pr(s)!=xr)return!1;var u=Pf(s);if(u===null)return!0;var d=Zt.call(u,"constructor")&&u.constructor;return typeof d=="function"&&d instanceof d&&Df.call(d)==Zj}var ly=bb?ii(bb):nG;function i2(s){return dA(s)&&s>=-dn&&s<=dn}var mA=Ab?ii(Ab):rG;function im(s){return typeof s=="string"||!lt(s)&&An(s)&&Pr(s)==ni}function si(s){return typeof s=="symbol"||An(s)&&Pr(s)==xt}var $c=Rb?ii(Rb):iG;function a2(s){return s===e}function s2(s){return An(s)&&Er(s)==_u}function o2(s){return An(s)&&Pr(s)==ya}var u2=Jf(Mh),c2=Jf(function(s,u){return s<=u});function NA(s){if(!s)return[];if(Vr(s))return im(s)?$i(s):qr(s);if(sd&&s[sd])return Vj(s[sd]());var u=Er(s),d=u==tt?Oh:u==pr?vf:Qc;return d(s)}function is(s){if(!s)return s===0?s:0;if(s=_i(s),s===Vt||s===-Vt){var u=s<0?-1:1;return u*Ar}return s===s?s:0}function Nt(s){var u=is(s),d=u%1;return u===u?d?u-d:u:0}function TA(s){return s?Au(Nt(s),0,Un):0}function _i(s){if(typeof s=="number")return s;if(si(s))return Rr;if(_n(s)){var u=typeof s.valueOf=="function"?s.valueOf():s;s=_n(u)?u+"":u}if(typeof s!="string")return s===0?s:+s;s=Bb(s);var d=G1.test(s);return d||Q1.test(s)?Sj(s.slice(2),d?2:8):K1.test(s)?Rr:+s}function EA(s){return ga(s,jr(s))}function l2(s){return s?Au(Nt(s),-dn,dn):s===0?s:0}function Qt(s){return s==null?"":ai(s)}var d2=jc(function(s,u){if(Ed(u)||Vr(u)){ga(u,ar(u),s);return}for(var d in u)Zt.call(u,d)&&dd(s,d,u[d])}),hA=jc(function(s,u){ga(u,jr(u),s)}),am=jc(function(s,u,d,E){ga(u,jr(u),s,E)}),p2=jc(function(s,u,d,E){ga(u,ar(u),s,E)}),f2=ts(Fh);function m2(s,u){var d=Vc(s);return u==null?d:zb(d,u)}var N2=yt(function(s,u){s=on(s);var d=-1,E=u.length,S=E>2?u[2]:e;for(S&&Fr(u[0],u[1],S)&&(E=1);++d1),L}),ga(s,Wh(s),d),E&&(d=yi(d,p|f|y,DG));for(var S=u.length;S--;)Kh(d,u[S]);return d});function L2(s,u){return IA(s,nm(ze(u)))}var C2=ts(function(s,u){return s==null?{}:oG(s,u)});function IA(s,u){if(s==null)return{};var d=yn(Wh(s),function(E){return[E]});return u=ze(u),d0(s,d,function(E,S){return u(E,S[0])})}function B2(s,u,d){u=$o(u,s);var E=-1,S=u.length;for(S||(S=1,s=e);++Eu){var E=s;s=u,u=E}if(d||s%1||u%1){var S=Qb();return Tr(s+S*(u-s+vj("1e-"+((S+"").length-1))),u)}return qh(s,u)}var Q2=Kc(function(s,u,d){return u=u.toLowerCase(),s+(d?vA(u):u)});function vA(s){return fy(Qt(s).toLowerCase())}function SA(s){return s=Qt(s),s&&s.replace(J1,Uj).replace(fj,"")}function Y2(s,u,d){s=Qt(s),u=ai(u);var E=s.length;d=d===e?E:Au(Nt(d),0,E);var S=d;return d-=u.length,d>=0&&s.slice(d,S)==u}function J2(s){return s=Qt(s),s&&A1.test(s)?s.replace(tb,kj):s}function H2(s){return s=Qt(s),s&&C1.test(s)?s.replace(uh,"\\$&"):s}var z2=Kc(function(s,u,d){return s+(d?"-":"")+u.toLowerCase()}),W2=Kc(function(s,u,d){return s+(d?" ":"")+u.toLowerCase()}),X2=b0("toLowerCase");function Z2(s,u,d){s=Qt(s),u=Nt(u);var E=u?kc(s):0;if(!u||E>=u)return s;var S=(u-E)/2;return Yf(Cf(S),d)+s+Yf(Lf(S),d)}function eY(s,u,d){s=Qt(s),u=Nt(u);var E=u?kc(s):0;return u&&E>>0,d?(s=Qt(s),s&&(typeof u=="string"||u!=null&&!ly(u))&&(u=ai(u),!u&&Uc(s))?Qo($i(s),0,d):s.split(u,d)):[]}var oY=Kc(function(s,u,d){return s+(d?" ":"")+fy(u)});function uY(s,u,d){return s=Qt(s),d=d==null?0:Au(Nt(d),0,s.length),u=ai(u),s.slice(d,d+u.length)==u}function cY(s,u,d){var E=R.templateSettings;d&&Fr(s,u,d)&&(u=e),s=Qt(s),u=am({},u,E,C0);var S=am({},u.imports,E.imports,C0),L=ar(S),M=Sh(S,L),j,H,fe=0,me=u.interpolate||hf,Ee="__p += '",be=Dh((u.escape||hf).source+"|"+me.source+"|"+(me===nb?j1:hf).source+"|"+(u.evaluate||hf).source+"|$","g"),je="//# sourceURL="+(Zt.call(u,"sourceURL")?(u.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++hj+"]")+` +`)}function BG(s){return lt(s)||wu(s)||!!(Gb&&s&&s[Gb])}function ns(s,u){var d=typeof s;return u=u==null?dn:u,!!u&&(d=="number"||d!="symbol"&&Y1.test(s))&&s>-1&&s%1==0&&s0){if(++u>=ve)return arguments[0]}else u=0;return s.apply(e,arguments)}}function Wf(s,u){var d=-1,E=s.length,S=E-1;for(u=u===e?E:u;++d1?s[u-1]:e;return d=typeof d=="function"?(s.pop(),d):e,eA(s,d)});function tA(s){var u=R(s);return u.__chain__=!0,u}function Q$(s,u){return u(s),s}function Xf(s,u){return u(s)}var Y$=ts(function(s){var u=s.length,d=u?s[0]:0,E=this.__wrapped__,S=function(L){return Fh(L,s)};return u>1||this.__actions__.length||!(E instanceof Ot)||!ns(d)?this.thru(S):(E=E.slice(d,+d+(u?1:0)),E.__actions__.push({func:Xf,args:[S],thisArg:e}),new hi(E,this.__chain__).thru(function(L){return u&&!L.length&&L.push(e),L}))});function J$(){return tA(this)}function H$(){return new hi(this.value(),this.__chain__)}function z$(){this.__values__===e&&(this.__values__=NA(this.value()));var s=this.__index__>=this.__values__.length,u=s?e:this.__values__[this.__index__++];return{done:s,value:u}}function W$(){return this}function X$(s){for(var u,d=this;d instanceof kf;){var E=J0(d);E.__index__=0,E.__values__=e,u?S.__wrapped__=E:u=E;var S=E;d=d.__wrapped__}return S.__wrapped__=s,u}function Z$(){var s=this.__wrapped__;if(s instanceof Ot){var u=s;return this.__actions__.length&&(u=new Ot(this)),u=u.reverse(),u.__actions__.push({func:Xf,args:[ay],thisArg:e}),new hi(u,this.__chain__)}return this.thru(ay)}function eQ(){return E0(this.__wrapped__,this.__actions__)}var tQ=Gf(function(s,u,d){Zt.call(s,d)?++s[d]:Za(s,d,1)});function nQ(s,u,d){var E=lt(s)?Pb:QK;return d&&Fr(s,u,d)&&(u=e),E(s,ze(u,3))}function rQ(s,u){var d=lt(s)?Mo:e0;return d(s,ze(u,3))}var iQ=A0(H0),aQ=A0(z0);function sQ(s,u){return mr(Zf(s,u),1)}function oQ(s,u){return mr(Zf(s,u),Vt)}function uQ(s,u,d){return d=d===e?1:Nt(d),mr(Zf(s,u),d)}function nA(s,u){var d=lt(s)?Ti:Ko;return d(s,ze(u,3))}function rA(s,u){var d=lt(s)?bj:Zb;return d(s,ze(u,3))}var cQ=Gf(function(s,u,d){Zt.call(s,d)?s[d].push(u):Za(s,d,[u])});function lQ(s,u,d,E){s=Vr(s)?s:Qc(s),d=d&&!E?Nt(d):0;var S=s.length;return d<0&&(d=Jn(S+d,0)),im(s)?d<=S&&s.indexOf(u,d)>-1:!!S&&Bc(s,u,d)>-1}var dQ=yt(function(s,u,d){var E=-1,S=typeof u=="function",L=Vr(s)?ie(s.length):[];return Ko(s,function(M){L[++E]=S?ri(u,M,d):fd(M,u,d)}),L}),pQ=Gf(function(s,u,d){Za(s,d,u)});function Zf(s,u){var d=lt(s)?yn:s0;return d(s,ze(u,3))}function fQ(s,u,d,E){return s==null?[]:(lt(u)||(u=u==null?[]:[u]),d=E?e:d,lt(d)||(d=d==null?[]:[d]),l0(s,u,d))}var mQ=Gf(function(s,u,d){s[d?0:1].push(u)},function(){return[[],[]]});function NQ(s,u,d){var E=lt(s)?hh:Cb,S=arguments.length<3;return E(s,ze(u,4),d,S,Ko)}function TQ(s,u,d){var E=lt(s)?Aj:Cb,S=arguments.length<3;return E(s,ze(u,4),d,S,Zb)}function EQ(s,u){var d=lt(s)?Mo:e0;return d(s,nm(ze(u,3)))}function hQ(s){var u=lt(s)?Hb:lG;return u(s)}function yQ(s,u,d){(d?Fr(s,u,d):u===e)?u=1:u=Nt(u);var E=lt(s)?VK:dG;return E(s,u)}function IQ(s){var u=lt(s)?jK:fG;return u(s)}function gQ(s){if(s==null)return 0;if(Vr(s))return im(s)?kc(s):s.length;var u=Er(s);return u==tt||u==pr?s.size:kh(s).length}function _Q(s,u,d){var E=lt(s)?yh:mG;return d&&Fr(s,u,d)&&(u=e),E(s,ze(u,3))}var vQ=yt(function(s,u){if(s==null)return[];var d=u.length;return d>1&&Fr(s,u[0],u[1])?u=[]:d>2&&Fr(u[0],u[1],u[2])&&(u=[u[0]]),l0(s,mr(u,1),[])}),em=rK||function(){return ir.Date.now()};function SQ(s,u){if(typeof u!="function")throw new Ei(i);return s=Nt(s),function(){if(--s<1)return u.apply(this,arguments)}}function iA(s,u,d){return u=d?e:u,u=s&&u==null?s.length:u,es(s,pe,e,e,e,e,u)}function aA(s,u){var d;if(typeof u!="function")throw new Ei(i);return s=Nt(s),function(){return--s>0&&(d=u.apply(this,arguments)),s<=1&&(u=e),d}}var oy=yt(function(s,u,d){var E=P;if(d.length){var S=qo(d,Gc(oy));E|=z}return es(s,E,u,d,S)}),sA=yt(function(s,u,d){var E=P|U;if(d.length){var S=qo(d,Gc(sA));E|=z}return es(u,E,s,d,S)});function oA(s,u,d){u=d?e:u;var E=es(s,$,e,e,e,e,e,u);return E.placeholder=oA.placeholder,E}function uA(s,u,d){u=d?e:u;var E=es(s,ne,e,e,e,e,e,u);return E.placeholder=uA.placeholder,E}function cA(s,u,d){var E,S,L,M,j,H,fe=0,me=!1,Ee=!1,be=!0;if(typeof s!="function")throw new Ei(i);u=_i(u)||0,_n(d)&&(me=!!d.leading,Ee="maxWait"in d,L=Ee?Jn(_i(d.maxWait)||0,u):L,be="trailing"in d?!!d.trailing:be);function je(Mn){var Ji=E,as=S;return E=S=e,fe=Mn,M=s.apply(as,Ji),M}function Xe(Mn){return fe=Mn,j=hd(vt,u),me?je(Mn):M}function Et(Mn){var Ji=Mn-H,as=Mn-fe,AA=u-Ji;return Ee?Tr(AA,L-as):AA}function Ze(Mn){var Ji=Mn-H,as=Mn-fe;return H===e||Ji>=u||Ji<0||Ee&&as>=L}function vt(){var Mn=em();if(Ze(Mn))return Rt(Mn);j=hd(vt,Et(Mn))}function Rt(Mn){return j=e,be&&E?je(Mn):(E=S=e,M)}function oi(){j!==e&&y0(j),fe=0,E=H=S=j=e}function wr(){return j===e?M:Rt(em())}function ui(){var Mn=em(),Ji=Ze(Mn);if(E=arguments,S=this,H=Mn,Ji){if(j===e)return Xe(H);if(Ee)return y0(j),j=hd(vt,u),je(H)}return j===e&&(j=hd(vt,u)),M}return ui.cancel=oi,ui.flush=wr,ui}var OQ=yt(function(s,u){return Xb(s,1,u)}),DQ=yt(function(s,u,d){return Xb(s,_i(u)||0,d)});function bQ(s){return es(s,xe)}function tm(s,u){if(typeof s!="function"||u!=null&&typeof u!="function")throw new Ei(i);var d=function(){var E=arguments,S=u?u.apply(this,E):E[0],L=d.cache;if(L.has(S))return L.get(S);var M=s.apply(this,E);return d.cache=L.set(S,M)||L,M};return d.cache=new(tm.Cache||Xa),d}tm.Cache=Xa;function nm(s){if(typeof s!="function")throw new Ei(i);return function(){var u=arguments;switch(u.length){case 0:return!s.call(this);case 1:return!s.call(this,u[0]);case 2:return!s.call(this,u[0],u[1]);case 3:return!s.call(this,u[0],u[1],u[2])}return!s.apply(this,u)}}function AQ(s){return aA(2,s)}var RQ=NG(function(s,u){u=u.length==1&<(u[0])?yn(u[0],ii(ze())):yn(mr(u,1),ii(ze()));var d=u.length;return yt(function(E){for(var S=-1,L=Tr(E.length,d);++S=u}),wu=r0(function(){return arguments}())?r0:function(s){return An(s)&&Zt.call(s,"callee")&&!Kb.call(s,"callee")},lt=ie.isArray,GQ=Sb?ii(Sb):XK;function Vr(s){return s!=null&&rm(s.length)&&!rs(s)}function kn(s){return An(s)&&Vr(s)}function $Q(s){return s===!0||s===!1||An(s)&&Pr(s)==_t}var Yo=aK||yy,QQ=Ob?ii(Ob):ZK;function YQ(s){return An(s)&&s.nodeType===1&&!yd(s)}function JQ(s){if(s==null)return!0;if(Vr(s)&&(lt(s)||typeof s=="string"||typeof s.splice=="function"||Yo(s)||$c(s)||wu(s)))return!s.length;var u=Er(s);if(u==tt||u==pr)return!s.size;if(Ed(s))return!kh(s).length;for(var d in s)if(Zt.call(s,d))return!1;return!0}function HQ(s,u){return md(s,u)}function zQ(s,u,d){d=typeof d=="function"?d:e;var E=d?d(s,u):e;return E===e?md(s,u,e,d):!!E}function cy(s){if(!An(s))return!1;var u=Pr(s);return u==qe||u==se||typeof s.message=="string"&&typeof s.name=="string"&&!yd(s)}function WQ(s){return typeof s=="number"&&$b(s)}function rs(s){if(!_n(s))return!1;var u=Pr(s);return u==Qe||u==Lt||u==Ce||u==Lc}function dA(s){return typeof s=="number"&&s==Nt(s)}function rm(s){return typeof s=="number"&&s>-1&&s%1==0&&s<=dn}function _n(s){var u=typeof s;return s!=null&&(u=="object"||u=="function")}function An(s){return s!=null&&typeof s=="object"}var pA=Db?ii(Db):tG;function XQ(s,u){return s===u||Uh(s,u,Zh(u))}function ZQ(s,u,d){return d=typeof d=="function"?d:e,Uh(s,u,Zh(u),d)}function e2(s){return fA(s)&&s!=+s}function t2(s){if(MG(s))throw new ot(r);return i0(s)}function n2(s){return s===null}function r2(s){return s==null}function fA(s){return typeof s=="number"||An(s)&&Pr(s)==At}function yd(s){if(!An(s)||Pr(s)!=xr)return!1;var u=Pf(s);if(u===null)return!0;var d=Zt.call(u,"constructor")&&u.constructor;return typeof d=="function"&&d instanceof d&&Df.call(d)==Zj}var ly=bb?ii(bb):nG;function i2(s){return dA(s)&&s>=-dn&&s<=dn}var mA=Ab?ii(Ab):rG;function im(s){return typeof s=="string"||!lt(s)&&An(s)&&Pr(s)==ni}function si(s){return typeof s=="symbol"||An(s)&&Pr(s)==xt}var $c=Rb?ii(Rb):iG;function a2(s){return s===e}function s2(s){return An(s)&&Er(s)==_u}function o2(s){return An(s)&&Pr(s)==ya}var u2=Jf(Mh),c2=Jf(function(s,u){return s<=u});function NA(s){if(!s)return[];if(Vr(s))return im(s)?$i(s):qr(s);if(sd&&s[sd])return Vj(s[sd]());var u=Er(s),d=u==tt?Oh:u==pr?vf:Qc;return d(s)}function is(s){if(!s)return s===0?s:0;if(s=_i(s),s===Vt||s===-Vt){var u=s<0?-1:1;return u*Ar}return s===s?s:0}function Nt(s){var u=is(s),d=u%1;return u===u?d?u-d:u:0}function TA(s){return s?Au(Nt(s),0,Un):0}function _i(s){if(typeof s=="number")return s;if(si(s))return Rr;if(_n(s)){var u=typeof s.valueOf=="function"?s.valueOf():s;s=_n(u)?u+"":u}if(typeof s!="string")return s===0?s:+s;s=Bb(s);var d=G1.test(s);return d||Q1.test(s)?Sj(s.slice(2),d?2:8):K1.test(s)?Rr:+s}function EA(s){return ga(s,jr(s))}function l2(s){return s?Au(Nt(s),-dn,dn):s===0?s:0}function Qt(s){return s==null?"":ai(s)}var d2=jc(function(s,u){if(Ed(u)||Vr(u)){ga(u,ar(u),s);return}for(var d in u)Zt.call(u,d)&&dd(s,d,u[d])}),hA=jc(function(s,u){ga(u,jr(u),s)}),am=jc(function(s,u,d,E){ga(u,jr(u),s,E)}),p2=jc(function(s,u,d,E){ga(u,ar(u),s,E)}),f2=ts(Fh);function m2(s,u){var d=Vc(s);return u==null?d:zb(d,u)}var N2=yt(function(s,u){s=on(s);var d=-1,E=u.length,S=E>2?u[2]:e;for(S&&Fr(u[0],u[1],S)&&(E=1);++d1),L}),ga(s,Wh(s),d),E&&(d=yi(d,p|f|y,DG));for(var S=u.length;S--;)Kh(d,u[S]);return d});function L2(s,u){return IA(s,nm(ze(u)))}var C2=ts(function(s,u){return s==null?{}:oG(s,u)});function IA(s,u){if(s==null)return{};var d=yn(Wh(s),function(E){return[E]});return u=ze(u),d0(s,d,function(E,S){return u(E,S[0])})}function B2(s,u,d){u=$o(u,s);var E=-1,S=u.length;for(S||(S=1,s=e);++Eu){var E=s;s=u,u=E}if(d||s%1||u%1){var S=Qb();return Tr(s+S*(u-s+vj("1e-"+((S+"").length-1))),u)}return qh(s,u)}var Q2=Kc(function(s,u,d){return u=u.toLowerCase(),s+(d?vA(u):u)});function vA(s){return fy(Qt(s).toLowerCase())}function SA(s){return s=Qt(s),s&&s.replace(J1,Uj).replace(fj,"")}function Y2(s,u,d){s=Qt(s),u=ai(u);var E=s.length;d=d===e?E:Au(Nt(d),0,E);var S=d;return d-=u.length,d>=0&&s.slice(d,S)==u}function J2(s){return s=Qt(s),s&&A1.test(s)?s.replace(tb,kj):s}function H2(s){return s=Qt(s),s&&C1.test(s)?s.replace(uh,"\\$&"):s}var z2=Kc(function(s,u,d){return s+(d?"-":"")+u.toLowerCase()}),W2=Kc(function(s,u,d){return s+(d?" ":"")+u.toLowerCase()}),X2=b0("toLowerCase");function Z2(s,u,d){s=Qt(s),u=Nt(u);var E=u?kc(s):0;if(!u||E>=u)return s;var S=(u-E)/2;return Yf(Cf(S),d)+s+Yf(Lf(S),d)}function eY(s,u,d){s=Qt(s),u=Nt(u);var E=u?kc(s):0;return u&&E>>0,d?(s=Qt(s),s&&(typeof u=="string"||u!=null&&!ly(u))&&(u=ai(u),!u&&Uc(s))?Qo($i(s),0,d):s.split(u,d)):[]}var oY=Kc(function(s,u,d){return s+(d?" ":"")+fy(u)});function uY(s,u,d){return s=Qt(s),d=d==null?0:Au(Nt(d),0,s.length),u=ai(u),s.slice(d,d+u.length)==u}function cY(s,u,d){var E=R.templateSettings;d&&Fr(s,u,d)&&(u=e),s=Qt(s),u=am({},u,E,C0);var S=am({},u.imports,E.imports,C0),L=ar(S),M=Sh(S,L),j,H,fe=0,me=u.interpolate||hf,Ee="__p += '",be=Dh((u.escape||hf).source+"|"+me.source+"|"+(me===nb?j1:hf).source+"|"+(u.evaluate||hf).source+"|$","g"),je="//# sourceURL="+(Zt.call(u,"sourceURL")?(u.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++hj+"]")+` `;s.replace(be,function(Ze,vt,Rt,oi,wr,ui){return Rt||(Rt=oi),Ee+=s.slice(fe,ui).replace(H1,Mj),vt&&(j=!0,Ee+=`' + __e(`+vt+`) + '`),wr&&(H=!0,Ee+=`'; @@ -468,10 +470,10 @@ __p += '`),Rt&&(Ee+=`' + function print() { __p += __j.call(arguments, '') } `:`; `)+Ee+`return __p -}`;var Et=DA(function(){return jt(L,je+"return "+Ee).apply(e,M)});if(Et.source=Ee,cy(Et))throw Et;return Et}function lY(s){return Qt(s).toLowerCase()}function dY(s){return Qt(s).toUpperCase()}function pY(s,u,d){if(s=Qt(s),s&&(d||u===e))return Bb(s);if(!s||!(u=ai(u)))return s;var E=$i(s),S=$i(u),L=Ub(E,S),M=kb(E,S)+1;return Qo(E,L,M).join("")}function fY(s,u,d){if(s=Qt(s),s&&(d||u===e))return s.slice(0,xb(s)+1);if(!s||!(u=ai(u)))return s;var E=$i(s),S=kb(E,$i(u))+1;return Qo(E,0,S).join("")}function mY(s,u,d){if(s=Qt(s),s&&(d||u===e))return s.replace(ch,"");if(!s||!(u=ai(u)))return s;var E=$i(s),S=Ub(E,$i(u));return Qo(E,S).join("")}function NY(s,u){var d=et,E=X;if(_n(u)){var S="separator"in u?u.separator:S;d="length"in u?Nt(u.length):d,E="omission"in u?ai(u.omission):E}s=Qt(s);var L=s.length;if(Uc(s)){var M=$i(s);L=M.length}if(d>=L)return s;var j=d-kc(E);if(j<1)return E;var H=M?Qo(M,0,j).join(""):s.slice(0,j);if(S===e)return H+E;if(M&&(j+=H.length-j),ly(S)){if(s.slice(j).search(S)){var fe,me=H;for(S.global||(S=Dh(S.source,Qt(rb.exec(S))+"g")),S.lastIndex=0;fe=S.exec(me);)var Ee=fe.index;H=H.slice(0,Ee===e?j:Ee)}}else if(s.indexOf(ai(S),j)!=j){var be=H.lastIndexOf(S);be>-1&&(H=H.slice(0,be))}return H+E}function TY(s){return s=Qt(s),s&&b1.test(s)?s.replace(eb,$j):s}var EY=Kc(function(s,u,d){return s+(d?" ":"")+u.toUpperCase()}),fy=b0("toUpperCase");function OA(s,u,d){return s=Qt(s),u=d?e:u,u===e?qj(s)?Jj(s):Fj(s):s.match(u)||[]}var DA=yt(function(s,u){try{return ri(s,e,u)}catch(d){return cy(d)?d:new ot(d)}}),hY=ts(function(s,u){return Ti(u,function(d){d=_a(d),Za(s,d,oy(s[d],s))}),s});function yY(s){var u=s==null?0:s.length,d=ze();return s=u?yn(s,function(E){if(typeof E[1]!="function")throw new Ei(i);return[d(E[0]),E[1]]}):[],yt(function(E){for(var S=-1;++Sdn)return[];var d=Un,E=Tr(s,Un);u=ze(u),s-=Un;for(var S=vh(E,u);++d0||u<0)?new Ot(d):(s<0?d=d.takeRight(-s):s&&(d=d.drop(s)),u!==e&&(u=Nt(u),d=u<0?d.dropRight(-u):d.take(u-s)),d)},Ot.prototype.takeRightWhile=function(s){return this.reverse().takeWhile(s).reverse()},Ot.prototype.toArray=function(){return this.take(Un)},Ia(Ot.prototype,function(s,u){var d=/^(?:filter|find|map|reject)|While$/.test(u),E=/^(?:head|last)$/.test(u),S=R[E?"take"+(u=="last"?"Right":""):u],L=E||/^find/.test(u);S&&(R.prototype[u]=function(){var M=this.__wrapped__,j=E?[1]:arguments,H=M instanceof Ot,fe=j[0],me=H||lt(M),Ee=function(vt){var Rt=S.apply(R,xo([vt],j));return E&&be?Rt[0]:Rt};me&&d&&typeof fe=="function"&&fe.length!=1&&(H=me=!1);var be=this.__chain__,je=!!this.__actions__.length,Xe=L&&!be,Et=H&&!je;if(!L&&me){M=Et?M:new Ot(this);var Ze=s.apply(M,j);return Ze.__actions__.push({func:Xf,args:[Ee],thisArg:e}),new hi(Ze,be)}return Xe&&Et?s.apply(this,j):(Ze=this.thru(Ee),Xe?E?Ze.value()[0]:Ze.value():Ze)})}),Ti(["pop","push","shift","sort","splice","unshift"],function(s){var u=Sf[s],d=/^(?:push|sort|unshift)$/.test(s)?"tap":"thru",E=/^(?:pop|shift)$/.test(s);R.prototype[s]=function(){var S=arguments;if(E&&!this.__chain__){var L=this.value();return u.apply(lt(L)?L:[],S)}return this[d](function(M){return u.apply(lt(M)?M:[],S)})}}),Ia(Ot.prototype,function(s,u){var d=R[u];if(d){var E=d.name+"";Zt.call(qc,E)||(qc[E]=[]),qc[E].push({name:u,func:d})}}),qc[$f(e,k).name]=[{name:"wrapper",func:e}],Ot.prototype.clone=TK,Ot.prototype.reverse=EK,Ot.prototype.value=hK,R.prototype.at=Y$,R.prototype.chain=J$,R.prototype.commit=H$,R.prototype.next=z$,R.prototype.plant=X$,R.prototype.reverse=Z$,R.prototype.toJSON=R.prototype.valueOf=R.prototype.value=eQ,R.prototype.first=R.prototype.head,sd&&(R.prototype[sd]=W$),R},Vo=Hj();typeof define=="function"&&typeof define.amd=="object"&&define.amd?(ir._=Vo,define(function(){return Vo})):Su?((Su.exports=Vo)._=Vo,Nh._=Vo):ir._=Vo}).call(Yl)});var nV=w(Sc=>{"use strict";m();T();N();Object.defineProperty(Sc,"__esModule",{value:!0});Sc.FederationFactory=void 0;Sc.federateSubgraphs=gle;Sc.federateSubgraphsWithContracts=_le;Sc.federateSubgraphsContract=vle;var Re=Ae(),Xq=ou(),kr=Yr(),we=ia(),vc=BN(),Zq=kp(),ti=Kp(),PE=XT(),jn=Es(),hle=WO(),yle=Gp(),eV=hp(),ge=hl(),Ile=eD(),tV=Wq(),Jl=RE(),Oe=ur(),FE=Nl(),he=Jr(),wE=class{constructor({authorizationDataByParentTypeName:t,concreteTypeNamesByAbstractTypeName:n,disableResolvabilityValidation:r,entityDataByTypeName:i,entityInterfaceFederationDataByTypeName:a,fieldCoordsByNamedTypeName:o,internalGraph:c,internalSubgraphBySubgraphName:l,warnings:p}){_(this,"authorizationDataByParentTypeName");_(this,"coordsByNamedTypeName",new Map);_(this,"disableResolvabilityValidation",!1);_(this,"clientDefinitions",[jn.DEPRECATED_DEFINITION]);_(this,"currentSubgraphName","");_(this,"concreteTypeNamesByAbstractTypeName");_(this,"subgraphNamesByNamedTypeNameByFieldCoords",new Map);_(this,"entityDataByTypeName");_(this,"entityInterfaceFederationDataByTypeName");_(this,"errors",[]);_(this,"fieldConfigurationByFieldCoords",new Map);_(this,"fieldCoordsByNamedTypeName");_(this,"inaccessibleCoords",new Set);_(this,"inaccessibleRequiredInputValueErrorByCoords",new Map);_(this,"internalGraph");_(this,"internalSubgraphBySubgraphName");_(this,"invalidORScopesCoords",new Set);_(this,"isMaxDepth",!1);_(this,"isVersionTwo",!1);_(this,"namedInputValueTypeNames",new Set);_(this,"namedOutputTypeNames",new Set);_(this,"parentDefinitionDataByTypeName",new Map);_(this,"parentTagDataByTypeName",new Map);_(this,"persistedDirectiveDefinitionByDirectiveName",new Map([[Oe.AUTHENTICATED,jn.AUTHENTICATED_DEFINITION],[Oe.DEPRECATED,jn.DEPRECATED_DEFINITION],[Oe.INACCESSIBLE,jn.INACCESSIBLE_DEFINITION],[Oe.REQUIRES_SCOPES,jn.REQUIRES_SCOPES_DEFINITION],[Oe.TAG,jn.TAG_DEFINITION]]));_(this,"persistedDirectiveDefinitions",new Set([Oe.AUTHENTICATED,Oe.DEPRECATED,Oe.INACCESSIBLE,Oe.TAG,Oe.REQUIRES_SCOPES]));_(this,"potentialPersistedDirectiveDefinitionDataByDirectiveName",new Map);_(this,"routerDefinitions",[jn.DEPRECATED_DEFINITION,jn.TAG_DEFINITION]);_(this,"subscriptionFilterDataByFieldPath",new Map);_(this,"tagNamesByCoords",new Map);_(this,"warnings");this.authorizationDataByParentTypeName=t,this.concreteTypeNamesByAbstractTypeName=n,this.disableResolvabilityValidation=r!=null?r:!1,this.entityDataByTypeName=i,this.entityInterfaceFederationDataByTypeName=a,this.fieldCoordsByNamedTypeName=o,this.internalGraph=c,this.internalSubgraphBySubgraphName=l,this.warnings=p}getValidImplementedInterfaces(t){var o;let n=[];if(t.implementedInterfaceTypeNames.size<1)return n;let r=(0,ge.isNodeDataInaccessible)(t),i=new Map,a=new Map;for(let c of t.implementedInterfaceTypeNames){n.push((0,kr.stringToNamedTypeNode)(c));let l=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,c,Oe.PARENT_DEFINITION_DATA);if(l.kind!==Re.Kind.INTERFACE_TYPE_DEFINITION){a.set(l.name,(0,he.kindToNodeType)(l.kind));continue}let p={invalidFieldImplementations:new Map,unimplementedFields:[]},f=!1;for(let[y,g]of l.fieldDataByName){let v=!1,F=t.fieldDataByName.get(y);if(!F){f=!0,p.unimplementedFields.push(y);continue}let k={invalidAdditionalArguments:new Set,invalidImplementedArguments:[],isInaccessible:!1,originalResponseType:(0,PE.printTypeNode)(g.node.type),unimplementedArguments:new Set};(0,ge.isTypeValidImplementation)(g.node.type,F.node.type,this.concreteTypeNamesByAbstractTypeName)||(f=!0,v=!0,k.implementedResponseType=(0,PE.printTypeNode)(F.node.type));let K=new Set;for(let[$,ne]of g.argumentDataByName){let z=ne.node;K.add($);let Te=(o=F.argumentDataByName.get($))==null?void 0:o.node;if(!Te){f=!0,v=!0,k.unimplementedArguments.add($);continue}let pe=(0,PE.printTypeNode)(Te.type),Fe=(0,PE.printTypeNode)(z.type);Fe!==pe&&(f=!0,v=!0,k.invalidImplementedArguments.push({actualType:pe,argumentName:$,expectedType:Fe}))}for(let[$,ne]of F.argumentDataByName){let z=ne.node;K.has($)||z.type.kind===Re.Kind.NON_NULL_TYPE&&(f=!0,v=!0,k.invalidAdditionalArguments.add($))}!r&&F.isInaccessible&&!g.isInaccessible&&(f=!0,v=!0,k.isInaccessible=!0),v&&p.invalidFieldImplementations.set(y,k)}f&&i.set(c,p)}return a.size>0&&this.errors.push((0,we.invalidImplementedTypeError)(t.name,a)),i.size>0&&this.errors.push((0,we.invalidInterfaceImplementationError)(t.node.name.value,(0,he.kindToNodeType)(t.kind),i)),n}addValidPrimaryKeyTargetsToEntityData(t){var f;let n=this.entityDataByTypeName.get(t);if(!n)return;let r=(0,he.getOrThrowError)(this.internalSubgraphBySubgraphName,this.currentSubgraphName,"internalSubgraphBySubgraphName"),i=r.parentDefinitionDataByTypeName,a=i.get(n.typeName);if(!a||a.kind!==Re.Kind.OBJECT_TYPE_DEFINITION)throw(0,we.incompatibleParentKindFatalError)(n.typeName,Re.Kind.OBJECT_TYPE_DEFINITION,(a==null?void 0:a.kind)||Re.Kind.NULL);let o=r.configurationDataByTypeName.get(n.typeName);if(!o)return;let c=[],l=this.internalGraph.nodeByNodeName.get(`${this.currentSubgraphName}.${n.typeName}`);(0,vc.validateImplicitFieldSets)({conditionalFieldDataByCoords:r.conditionalFieldDataByCoordinates,currentSubgraphName:this.currentSubgraphName,entityData:n,implicitKeys:c,objectData:a,parentDefinitionDataByTypeName:i,graphNode:l});for(let[y,g]of this.entityInterfaceFederationDataByTypeName){if(!((f=g.concreteTypeNames)!=null&&f.has(n.typeName)))continue;let v=this.entityDataByTypeName.get(y);v&&(0,vc.validateImplicitFieldSets)({conditionalFieldDataByCoords:r.conditionalFieldDataByCoordinates,currentSubgraphName:this.currentSubgraphName,entityData:v,implicitKeys:c,objectData:a,parentDefinitionDataByTypeName:i,graphNode:l})}if(c.length<1)return;if(!o.keys||o.keys.length<1){o.isRootNode=!0,o.keys=c;return}let p=new Set(o.keys.map(y=>y.selectionSet));for(let y of c)p.has(y.selectionSet)||(o.keys.push(y),p.add(y.selectionSet))}addValidPrimaryKeyTargetsFromInterfaceObject(t,n,r,i){let a=t.parentDefinitionDataByTypeName,o=a.get(n);if(!o||!(0,ge.isParentDataCompositeOutputType)(o))throw(0,we.incompatibleParentKindFatalError)(n,Re.Kind.INTERFACE_TYPE_DEFINITION,(o==null?void 0:o.kind)||Re.Kind.NULL);let c=(0,he.getOrThrowError)(t.configurationDataByTypeName,r.typeName,"internalSubgraph.configurationDataByTypeName"),l=[];if((0,vc.validateImplicitFieldSets)({conditionalFieldDataByCoords:t.conditionalFieldDataByCoordinates,currentSubgraphName:t.name,entityData:r,implicitKeys:l,objectData:o,parentDefinitionDataByTypeName:a,graphNode:i}),l.length<1)return;if(!c.keys||c.keys.length<1){c.isRootNode=!0,c.keys=l;return}let p=new Set(c.keys.map(f=>f.selectionSet));for(let f of l)p.has(f.selectionSet)||(c.keys.push(f),p.add(f.selectionSet))}getEnumValueMergeMethod(t){return this.namedInputValueTypeNames.has(t)?this.namedOutputTypeNames.has(t)?ge.MergeMethod.CONSISTENT:ge.MergeMethod.INTERSECTION:ge.MergeMethod.UNION}generateTagData(){for(let[t,n]of this.tagNamesByCoords){let r=t.split(".");if(r.length<1)continue;let i=(0,he.getValueOrDefault)(this.parentTagDataByTypeName,r[0],()=>(0,vc.newParentTagData)(r[0]));switch(r.length){case 1:for(let l of n)i.tagNames.add(l);break;case 2:let a=(0,he.getValueOrDefault)(i.childTagDataByChildName,r[1],()=>(0,vc.newChildTagData)(r[1]));for(let l of n)a.tagNames.add(l);break;case 3:let o=(0,he.getValueOrDefault)(i.childTagDataByChildName,r[1],()=>(0,vc.newChildTagData)(r[1])),c=(0,he.getValueOrDefault)(o.tagNamesByArgumentName,r[2],()=>new Set);for(let l of n)c.add(l);break;default:break}}}upsertEnumValueData(t,n,r){let i=t.get(n.name),a=i||this.copyEnumValueData(n);(0,ge.extractPersistedDirectives)(a.persistedDirectivesData,n.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName);let o=(0,ge.isNodeDataInaccessible)(n);if((r||o)&&this.inaccessibleCoords.add(a.federatedCoords),this.recordTagNamesByCoords(a,a.federatedCoords),!i){t.set(a.name,a);return}a.appearances+=1,(0,he.addNewObjectValueMapEntries)(n.configureDescriptionDataBySubgraphName,a.configureDescriptionDataBySubgraphName),(0,ge.setLongestDescription)(a,n),(0,he.addIterableValuesToSet)(n.subgraphNames,a.subgraphNames)}upsertInputValueData(t,n,r,i){let a=t.get(n.name),o=a||this.copyInputValueData(n);if((0,ge.extractPersistedDirectives)(o.persistedDirectivesData,n.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),this.recordTagNamesByCoords(o,`${r}.${o.name}`),this.namedInputValueTypeNames.add(o.namedTypeName),(0,he.getValueOrDefault)(this.coordsByNamedTypeName,o.namedTypeName,()=>new Set).add(o.federatedCoords),!a){t.set(o.name,o);return}(0,he.addNewObjectValueMapEntries)(n.configureDescriptionDataBySubgraphName,o.configureDescriptionDataBySubgraphName),(0,ge.setLongestDescription)(o,n),(0,he.addIterableValuesToSet)(n.requiredSubgraphNames,o.requiredSubgraphNames),(0,he.addIterableValuesToSet)(n.subgraphNames,o.subgraphNames),this.handleInputValueInaccessibility(i,o,r);let c=(0,Jl.getMostRestrictiveMergedTypeNode)(o.type,n.type,o.originalCoords,this.errors);c.success?o.type=c.typeNode:this.errors.push((0,we.incompatibleMergedTypesError)({actualType:c.actualType,isArgument:a.isArgument,coords:a.federatedCoords,expectedType:c.expectedType})),(0,ge.compareAndValidateInputValueDefaultValues)(o,n,this.errors)}handleInputValueInaccessibility(t,n,r){if(t){this.inaccessibleRequiredInputValueErrorByCoords.delete(n.federatedCoords),this.inaccessibleCoords.add(n.federatedCoords);return}if((0,ge.isNodeDataInaccessible)(n)){if((0,ge.isTypeRequired)(n.type)){this.inaccessibleRequiredInputValueErrorByCoords.set(n.federatedCoords,(0,we.inaccessibleRequiredInputValueError)(n,r));return}this.inaccessibleCoords.add(n.federatedCoords)}}handleSubscriptionFilterDirective(t,n){let r=t.directivesByDirectiveName.get(Oe.SUBSCRIPTION_FILTER);if(!r)return;let i=(0,he.getSingleSetEntry)(t.subgraphNames);if(i===void 0){this.errors.push((0,we.unknownFieldSubgraphNameError)(t.federatedCoords));return}this.subscriptionFilterDataByFieldPath.set(t.federatedCoords,{directive:r[0],fieldData:n||t,directiveSubgraphName:i})}federateOutputType({current:t,other:n,coords:r,mostRestrictive:i}){n=(0,Xq.getMutableTypeNode)(n,r,this.errors);let a={kind:t.kind},o=Jl.DivergentType.NONE,c=a;for(let l=0;lnew Set))}upsertFieldData(t,n,r){let i=t.get(n.name),a=i||this.copyFieldData(n,r||(0,ge.isNodeDataInaccessible)(n));(0,he.getValueOrDefault)(this.coordsByNamedTypeName,n.namedTypeName,()=>new Set).add(a.federatedCoords),this.namedOutputTypeNames.add(n.namedTypeName),this.handleSubscriptionFilterDirective(n,a),(0,ge.extractPersistedDirectives)(a.persistedDirectivesData,n.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName);let o=r||(0,ge.isNodeDataInaccessible)(a);if(o&&this.inaccessibleCoords.add(a.federatedCoords),this.recordTagNamesByCoords(a,a.federatedCoords),!i){t.set(a.name,a);return}let c=this.federateOutputType({current:a.type,other:n.type,coords:a.federatedCoords,mostRestrictive:!1});if(c.success)if(a.type=c.typeNode,a.namedTypeName!==n.namedTypeName){let l=(0,he.getValueOrDefault)(this.subgraphNamesByNamedTypeNameByFieldCoords,a.federatedCoords,()=>new Map),p=(0,he.getValueOrDefault)(l,a.namedTypeName,()=>new Set);if(p.size<1)for(let f of a.subgraphNames)n.subgraphNames.has(f)||p.add(f);(0,he.addIterableValuesToSet)(n.subgraphNames,(0,he.getValueOrDefault)(l,n.namedTypeName,()=>new Set))}else this.addSubgraphNameToExistingFieldNamedTypeDisparity(n);for(let l of n.argumentDataByName.values())this.upsertInputValueData(a.argumentDataByName,l,a.federatedCoords,o);(0,he.addNewObjectValueMapEntries)(n.configureDescriptionDataBySubgraphName,i.configureDescriptionDataBySubgraphName),(0,ge.setLongestDescription)(a,n),a.isInaccessible||(a.isInaccessible=n.isInaccessible),(0,he.addNewObjectValueMapEntries)(n.externalFieldDataBySubgraphName,a.externalFieldDataBySubgraphName),(0,he.addMapEntries)(n.isShareableBySubgraphName,a.isShareableBySubgraphName),(0,he.addIterableValuesToSet)(n.subgraphNames,a.subgraphNames)}getClientSchemaUnionMembers(t){let n=[];for(let[r,i]of t.memberByMemberTypeName)this.inaccessibleCoords.has(r)||n.push(i);return n}recordTagNamesByCoords(t,n){let r=n||t.name;if(t.persistedDirectivesData.tagDirectiveByName.size<1)return;let i=(0,he.getValueOrDefault)(this.tagNamesByCoords,r,()=>new Set);for(let a of t.persistedDirectivesData.tagDirectiveByName.keys())i.add(a)}copyMutualParentDefinitionData(t){return{configureDescriptionDataBySubgraphName:(0,he.copyObjectValueMap)(t.configureDescriptionDataBySubgraphName),directivesByDirectiveName:(0,he.copyArrayValueMap)(t.directivesByDirectiveName),extensionType:t.extensionType,name:t.name,persistedDirectivesData:(0,ge.extractPersistedDirectives)((0,ge.newPersistedDirectivesData)(),t.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),description:(0,ge.getInitialFederatedDescription)(t)}}copyEnumValueData(t){return{appearances:t.appearances,configureDescriptionDataBySubgraphName:(0,he.copyObjectValueMap)(t.configureDescriptionDataBySubgraphName),federatedCoords:t.federatedCoords,directivesByDirectiveName:(0,he.copyArrayValueMap)(t.directivesByDirectiveName),kind:t.kind,name:t.name,node:{directives:[],kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},parentTypeName:t.parentTypeName,persistedDirectivesData:(0,ge.extractPersistedDirectives)((0,ge.newPersistedDirectivesData)(),t.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),subgraphNames:new Set(t.subgraphNames),description:(0,ge.getInitialFederatedDescription)(t)}}copyInputValueData(t){return{configureDescriptionDataBySubgraphName:(0,he.copyObjectValueMap)(t.configureDescriptionDataBySubgraphName),directivesByDirectiveName:(0,he.copyArrayValueMap)(t.directivesByDirectiveName),federatedCoords:t.federatedCoords,fieldName:t.fieldName,includeDefaultValue:t.includeDefaultValue,isArgument:t.isArgument,kind:t.kind,name:t.name,namedTypeKind:t.namedTypeKind,namedTypeName:t.namedTypeName,node:{directives:[],kind:Re.Kind.INPUT_VALUE_DEFINITION,name:(0,kr.stringToNameNode)(t.name),type:t.type},originalCoords:t.originalCoords,originalParentTypeName:t.originalParentTypeName,persistedDirectivesData:(0,ge.extractPersistedDirectives)((0,ge.newPersistedDirectivesData)(),t.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),renamedParentTypeName:t.renamedParentTypeName,requiredSubgraphNames:new Set(t.requiredSubgraphNames),subgraphNames:new Set(t.subgraphNames),type:t.type,defaultValue:t.defaultValue,description:(0,ge.getInitialFederatedDescription)(t)}}copyInputValueDataByValueName(t,n,r){let i=new Map;for(let[a,o]of t){let c=this.copyInputValueData(o);this.handleInputValueInaccessibility(n,c,r),(0,he.getValueOrDefault)(this.coordsByNamedTypeName,c.namedTypeName,()=>new Set).add(c.federatedCoords),this.namedInputValueTypeNames.add(c.namedTypeName),this.recordTagNamesByCoords(c,`${r}.${o.name}`),i.set(a,c)}return i}copyFieldData(t,n){return{argumentDataByName:this.copyInputValueDataByValueName(t.argumentDataByName,n,t.federatedCoords),configureDescriptionDataBySubgraphName:(0,he.copyObjectValueMap)(t.configureDescriptionDataBySubgraphName),directivesByDirectiveName:(0,he.copyArrayValueMap)(t.directivesByDirectiveName),externalFieldDataBySubgraphName:(0,he.copyObjectValueMap)(t.externalFieldDataBySubgraphName),federatedCoords:t.federatedCoords,inheritedDirectiveNames:new Set,isInaccessible:t.isInaccessible,isShareableBySubgraphName:new Map(t.isShareableBySubgraphName),kind:t.kind,name:t.name,namedTypeKind:t.namedTypeKind,namedTypeName:t.namedTypeName,node:{arguments:[],directives:[],kind:t.kind,name:(0,kr.stringToNameNode)(t.name),type:t.type},originalParentTypeName:t.originalParentTypeName,persistedDirectivesData:(0,ge.extractPersistedDirectives)((0,ge.newPersistedDirectivesData)(),t.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),renamedParentTypeName:t.renamedParentTypeName,subgraphNames:new Set(t.subgraphNames),type:t.type,description:(0,ge.getInitialFederatedDescription)(t)}}copyEnumValueDataByValueName(t,n){let r=new Map;for(let[i,a]of t){let o=this.copyEnumValueData(a);this.recordTagNamesByCoords(o,o.federatedCoords),(n||(0,ge.isNodeDataInaccessible)(o))&&this.inaccessibleCoords.add(o.federatedCoords),r.set(i,o)}return r}copyFieldDataByName(t,n){let r=new Map;for(let[i,a]of t){let o=n||(0,ge.isNodeDataInaccessible)(a),c=this.copyFieldData(a,o);this.handleSubscriptionFilterDirective(c),(0,he.getValueOrDefault)(this.coordsByNamedTypeName,c.namedTypeName,()=>new Set).add(c.federatedCoords),this.namedOutputTypeNames.add(c.namedTypeName),this.recordTagNamesByCoords(c,c.federatedCoords),o&&this.inaccessibleCoords.add(c.federatedCoords),r.set(i,c)}return r}copyParentDefinitionData(t){let n=this.copyMutualParentDefinitionData(t);switch(t.kind){case Re.Kind.ENUM_TYPE_DEFINITION:return Y(x({},n),{appearances:t.appearances,enumValueDataByValueName:this.copyEnumValueDataByValueName(t.enumValueDataByValueName,t.isInaccessible),isInaccessible:t.isInaccessible,kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},subgraphNames:new Set(t.subgraphNames)});case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:return Y(x({},n),{inputValueDataByName:this.copyInputValueDataByValueName(t.inputValueDataByName,t.isInaccessible,t.name),isInaccessible:t.isInaccessible,kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},subgraphNames:new Set(t.subgraphNames)});case Re.Kind.INTERFACE_TYPE_DEFINITION:return Y(x({},n),{fieldDataByName:this.copyFieldDataByName(t.fieldDataByName,t.isInaccessible),implementedInterfaceTypeNames:new Set(t.implementedInterfaceTypeNames),isEntity:t.isEntity,isInaccessible:t.isInaccessible,kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},subgraphNames:new Set(t.subgraphNames)});case Re.Kind.OBJECT_TYPE_DEFINITION:return Y(x({},n),{fieldDataByName:this.copyFieldDataByName(t.fieldDataByName,t.isInaccessible),implementedInterfaceTypeNames:new Set(t.implementedInterfaceTypeNames),isEntity:t.isEntity,isInaccessible:t.isInaccessible,isRootType:t.isRootType,kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.renamedTypeName||t.name)},renamedTypeName:t.renamedTypeName,subgraphNames:new Set(t.subgraphNames)});case Re.Kind.SCALAR_TYPE_DEFINITION:return Y(x({},n),{kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},subgraphNames:new Set(t.subgraphNames)});case Re.Kind.UNION_TYPE_DEFINITION:return Y(x({},n),{kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},memberByMemberTypeName:new Map(t.memberByMemberTypeName),subgraphNames:new Set(t.subgraphNames)})}}getParentTargetData({existingData:t,incomingData:n}){if(!t){let r=this.copyParentDefinitionData(n);return(0,ge.isParentDataRootType)(r)&&(r.extensionType=eV.ExtensionType.NONE),r}return(0,ge.extractPersistedDirectives)(t.persistedDirectivesData,n.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),t}upsertParentDefinitionData(t,n){let r=this.entityInterfaceFederationDataByTypeName.get(t.name),i=this.parentDefinitionDataByTypeName.get(t.name),a=this.getParentTargetData({existingData:i,incomingData:t});this.recordTagNamesByCoords(a);let o=(0,ge.isNodeDataInaccessible)(a);if(o&&this.inaccessibleCoords.add(a.name),r&&r.interfaceObjectSubgraphs.has(n)&&(a.kind=Re.Kind.INTERFACE_TYPE_DEFINITION,a.node.kind=Re.Kind.INTERFACE_TYPE_DEFINITION),!i){this.parentDefinitionDataByTypeName.set(a.name,a);return}if(a.kind!==t.kind&&(!r||!r.interfaceObjectSubgraphs.has(n)||a.kind!==Re.Kind.INTERFACE_TYPE_DEFINITION||t.kind!==Re.Kind.OBJECT_TYPE_DEFINITION)){this.errors.push((0,we.incompatibleParentKindMergeError)(a.name,(0,he.kindToNodeType)(a.kind),(0,he.kindToNodeType)(t.kind)));return}switch((0,he.addNewObjectValueMapEntries)(t.configureDescriptionDataBySubgraphName,a.configureDescriptionDataBySubgraphName),(0,ge.setLongestDescription)(a,t),(0,ge.setParentDataExtensionType)(a,t),a.kind){case Re.Kind.ENUM_TYPE_DEFINITION:if(!(0,ge.areKindsEqual)(a,t))return;a.appearances+=1,a.isInaccessible||(a.isInaccessible=o),(0,he.addIterableValuesToSet)(t.subgraphNames,a.subgraphNames);for(let l of t.enumValueDataByValueName.values())this.upsertEnumValueData(a.enumValueDataByValueName,l,o);return;case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:if(!(0,ge.areKindsEqual)(a,t))return;o&&!a.isInaccessible&&this.propagateInaccessibilityToExistingChildren(a),a.isInaccessible||(a.isInaccessible=o),(0,he.addIterableValuesToSet)(t.subgraphNames,a.subgraphNames);for(let l of t.inputValueDataByName.values())this.upsertInputValueData(a.inputValueDataByName,l,a.name,a.isInaccessible);return;case Re.Kind.INTERFACE_TYPE_DEFINITION:case Re.Kind.OBJECT_TYPE_DEFINITION:let c=t;o&&!a.isInaccessible&&this.propagateInaccessibilityToExistingChildren(a),a.isInaccessible||(a.isInaccessible=o),(0,he.addIterableValuesToSet)(c.implementedInterfaceTypeNames,a.implementedInterfaceTypeNames),(0,he.addIterableValuesToSet)(c.subgraphNames,a.subgraphNames);for(let l of c.fieldDataByName.values())this.upsertFieldData(a.fieldDataByName,l,a.isInaccessible);return;case Re.Kind.UNION_TYPE_DEFINITION:if(!(0,ge.areKindsEqual)(a,t))return;(0,he.addMapEntries)(t.memberByMemberTypeName,a.memberByMemberTypeName),(0,he.addIterableValuesToSet)(t.subgraphNames,a.subgraphNames);return;default:(0,he.addIterableValuesToSet)(t.subgraphNames,a.subgraphNames);return}}propagateInaccessibilityToExistingChildren(t){switch(t.kind){case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:for(let n of t.inputValueDataByName.values())this.inaccessibleCoords.add(n.federatedCoords);break;default:for(let n of t.fieldDataByName.values()){this.inaccessibleCoords.add(n.federatedCoords);for(let r of n.argumentDataByName.values())this.inaccessibleCoords.add(r.federatedCoords)}}}upsertPersistedDirectiveDefinitionData(t,n){let r=t.name,i=this.potentialPersistedDirectiveDefinitionDataByDirectiveName.get(r);if(!i){if(n>1)return;let a=new Map;for(let o of t.argumentDataByArgumentName.values())this.namedInputValueTypeNames.add(o.namedTypeName),this.upsertInputValueData(a,o,`@${t.name}`,!1);this.potentialPersistedDirectiveDefinitionDataByDirectiveName.set(r,{argumentDataByArgumentName:a,executableLocations:new Set(t.executableLocations),name:r,repeatable:t.repeatable,subgraphNames:new Set(t.subgraphNames),description:t.description});return}if(i.subgraphNames.size+1!==n){this.potentialPersistedDirectiveDefinitionDataByDirectiveName.delete(r);return}if((0,ge.setMutualExecutableLocations)(i,t.executableLocations),i.executableLocations.size<1){this.potentialPersistedDirectiveDefinitionDataByDirectiveName.delete(r);return}for(let a of t.argumentDataByArgumentName.values())this.namedInputValueTypeNames.add((0,Xq.getTypeNodeNamedTypeName)(a.type)),this.upsertInputValueData(i.argumentDataByArgumentName,a,`@${i.name}`,!1);(0,ge.setLongestDescription)(i,t),i.repeatable&&(i.repeatable=t.repeatable),(0,he.addIterableValuesToSet)(t.subgraphNames,i.subgraphNames)}shouldUpdateFederatedFieldAbstractNamedType(t,n){if(!t)return!1;let r=this.concreteTypeNamesByAbstractTypeName.get(t);if(!r||r.size<1)return!1;for(let i of n)if(!r.has(i))return!1;return!0}updateTypeNodeNamedType(t,n){let r=t;for(let i=0;i1){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}break}case Re.Kind.UNION_TYPE_DEFINITION:{if(l){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}l=f;break}default:{this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));break}}}if(o.size<0&&!l){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}let p=l;if(o.size>0){if(l){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}for(let f of o.keys()){p=f;for(let[y,g]of o)if(f!==y&&!g.implementedInterfaceTypeNames.has(f)){p="";break}if(p)break}}if(!this.shouldUpdateFederatedFieldAbstractNamedType(p,c)){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}a.namedTypeName=p,this.updateTypeNodeNamedType(a.type,p)}}federateInternalSubgraphData(){let t=0,n=!1;for(let r of this.internalSubgraphBySubgraphName.values()){t+=1,this.currentSubgraphName=r.name,this.isVersionTwo||(this.isVersionTwo=r.isVersionTwo),(0,Ile.renameRootTypes)(this,r);for(let i of r.parentDefinitionDataByTypeName.values())this.upsertParentDefinitionData(i,r.name);if(!n){if(!r.persistedDirectiveDefinitionDataByDirectiveName.size){n=!0;continue}for(let i of r.persistedDirectiveDefinitionDataByDirectiveName.values())this.upsertPersistedDirectiveDefinitionData(i,t);this.potentialPersistedDirectiveDefinitionDataByDirectiveName.size<1&&(n=!0)}}this.handleDisparateFieldNamedTypes()}handleInterfaceObjectForInternalGraph({entityData:t,internalSubgraph:n,interfaceObjectData:r,interfaceObjectNode:i,resolvableKeyFieldSets:a,subgraphName:o}){let c=this.internalGraph.addOrUpdateNode(t.typeName),l=this.internalGraph.addEntityDataNode(t.typeName);for(let f of i.satisfiedFieldSets)c.satisfiedFieldSets.add(f),a.has(f)&&l.addTargetSubgraphByFieldSet(f,o);let p=r.fieldDatasBySubgraphName.get(o);for(let{name:f,namedTypeName:y}of p||[])this.internalGraph.addEdge(c,this.internalGraph.addOrUpdateNode(y),f);this.internalGraph.addEdge(i,c,t.typeName,!0),this.addValidPrimaryKeyTargetsFromInterfaceObject(n,i.typeName,t,c)}handleEntityInterfaces(){var t;for(let[n,r]of this.entityInterfaceFederationDataByTypeName){let i=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,n,Oe.PARENT_DEFINITION_DATA);if(i.kind===Re.Kind.INTERFACE_TYPE_DEFINITION)for(let a of r.interfaceObjectSubgraphs){let o=(0,he.getOrThrowError)(this.internalSubgraphBySubgraphName,a,"internalSubgraphBySubgraphName"),c=o.configurationDataByTypeName,l=this.concreteTypeNamesByAbstractTypeName.get(n);if(!l)continue;let p=(0,he.getOrThrowError)(c,n,"configurationDataByTypeName"),f=p.keys;if(!f)continue;p.entityInterfaceConcreteTypeNames=new Set(r.concreteTypeNames),this.internalGraph.setSubgraphName(a);let y=this.internalGraph.addOrUpdateNode(n,{isAbstract:!0});for(let g of l){let v=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,g,Oe.PARENT_DEFINITION_DATA);if(!(0,ti.isObjectDefinitionData)(v))continue;let F=(0,he.getOrThrowError)(this.entityDataByTypeName,g,"entityDataByTypeName");F.subgraphNames.add(a);let k=c.get(g);if(k)if((0,he.addIterableValuesToSet)(p.fieldNames,k.fieldNames),!k.keys)k.keys=[...f];else e:for(let z of f){for(let{selectionSet:Te}of k.keys)if(z.selectionSet===Te)continue e;k.keys.push(z)}else c.set(g,{fieldNames:new Set(p.fieldNames),isRootNode:!0,keys:[...f],typeName:g});let K=new Set;for(let z of f.filter(Te=>!Te.disableEntityResolver))K.add(z.selectionSet);let $=this.authorizationDataByParentTypeName.get(n),ne=(0,he.getOrThrowError)(o.parentDefinitionDataByTypeName,n,"internalSubgraph.parentDefinitionDataByTypeName");if((0,ti.isObjectDefinitionData)(ne)){for(let[z,Te]of ne.fieldDataByName){let pe=`${g}.${z}`;(0,he.getValueOrDefault)(this.fieldCoordsByNamedTypeName,Te.namedTypeName,()=>new Set).add(pe);let Fe=$==null?void 0:$.fieldAuthDataByFieldName.get(z);if(Fe){let X=(0,he.getValueOrDefault)(this.authorizationDataByParentTypeName,g,()=>(0,ti.newAuthorizationData)(g));(0,ti.upsertFieldAuthorizationData)(X.fieldAuthDataByFieldName,Fe)||this.invalidORScopesCoords.add(pe)}let Ve=v.fieldDataByName.get(z);if(Ve){let X=(t=Te.isShareableBySubgraphName.get(a))!=null?t:!1;Ve.isShareableBySubgraphName.set(a,X),Ve.subgraphNames.add(a);continue}let et=i.isInaccessible||v.isInaccessible||Te.isInaccessible;v.fieldDataByName.set(z,this.copyFieldData(Te,et))}this.handleInterfaceObjectForInternalGraph({internalSubgraph:o,subgraphName:a,interfaceObjectData:r,interfaceObjectNode:y,resolvableKeyFieldSets:K,entityData:F})}}}}}fieldDataToGraphFieldData(t){var n;return{name:t.name,namedTypeName:t.namedTypeName,isLeaf:(0,ti.isNodeLeaf)((n=this.parentDefinitionDataByTypeName.get(t.namedTypeName))==null?void 0:n.kind),subgraphNames:t.subgraphNames}}getValidFlattenedPersistedDirectiveNodeArray(t,n){let r=[];for(let[i,a]of t){let o=this.persistedDirectiveDefinitionByDirectiveName.get(i);if(o){if(a.length<2){r.push(...a);continue}if(!o.repeatable){this.errors.push((0,we.invalidRepeatedFederatedDirectiveErrorMessage)(i,n));continue}r.push(...a)}}return r}getRouterPersistedDirectiveNodes(t){let n=[...t.persistedDirectivesData.tagDirectiveByName.values()];return t.persistedDirectivesData.isDeprecated&&n.push((0,ge.generateDeprecatedDirective)(t.persistedDirectivesData.deprecatedReason)),n.push(...this.getValidFlattenedPersistedDirectiveNodeArray(t.persistedDirectivesData.directivesByDirectiveName,t.name)),n}getFederatedGraphNodeDescription(t){if(t.configureDescriptionDataBySubgraphName.size<1)return t.description;let n=[],r="";for(let[i,{propagate:a,description:o}]of t.configureDescriptionDataBySubgraphName)a&&(n.push(i),r=o);if(n.length===1)return(0,vc.getDescriptionFromString)(r);if(n.length<1)return t.description;this.errors.push((0,we.configureDescriptionPropagationError)((0,ge.getDefinitionDataCoords)(t,!0),n))}getNodeForRouterSchemaByData(t){return t.node.name=(0,kr.stringToNameNode)(t.name),t.node.description=this.getFederatedGraphNodeDescription(t),t.node.directives=this.getRouterPersistedDirectiveNodes(t),t.node}getNodeWithPersistedDirectivesByInputValueData(t){return t.node.name=(0,kr.stringToNameNode)(t.name),t.node.type=t.type,t.node.description=this.getFederatedGraphNodeDescription(t),t.node.directives=this.getRouterPersistedDirectiveNodes(t),t.includeDefaultValue&&(t.node.defaultValue=t.defaultValue),t.node}getValidFieldArgumentNodes(t){let n=[],r=[],i=[],a=`${t.renamedParentTypeName}.${t.name}`;for(let[o,c]of t.argumentDataByName)t.subgraphNames.size===c.subgraphNames.size?(r.push(o),n.push(this.getNodeWithPersistedDirectivesByInputValueData(c))):(0,ge.isTypeRequired)(c.type)&&i.push({inputValueName:o,missingSubgraphs:(0,he.getEntriesNotInHashSet)(t.subgraphNames,c.subgraphNames),requiredSubgraphs:[...c.requiredSubgraphNames]});return i.length>0?this.errors.push((0,we.invalidRequiredInputValueError)(Oe.FIELD,a,i)):r.length>0&&((0,he.getValueOrDefault)(this.fieldConfigurationByFieldCoords,a,()=>({argumentNames:r,fieldName:t.name,typeName:t.renamedParentTypeName})).argumentNames=r),n}getNodeWithPersistedDirectivesByFieldData(t,n){return t.node.arguments=n,t.node.name=(0,kr.stringToNameNode)(t.name),t.node.type=t.type,t.node.description=this.getFederatedGraphNodeDescription(t),t.node.directives=this.getRouterPersistedDirectiveNodes(t),t.node}pushParentDefinitionDataToDocumentDefinitions(t){for(let[n,r]of this.parentDefinitionDataByTypeName)switch(r.extensionType!==eV.ExtensionType.NONE&&this.errors.push((0,we.noBaseDefinitionForExtensionError)((0,he.kindToNodeType)(r.kind),n)),r.kind){case Re.Kind.ENUM_TYPE_DEFINITION:let i=[],a=[],o=this.getEnumValueMergeMethod(n);(0,ge.propagateAuthDirectives)(r,this.authorizationDataByParentTypeName.get(n));for(let ne of r.enumValueDataByValueName.values()){let z=(0,ge.getNodeForRouterSchemaByData)(ne,this.persistedDirectiveDefinitionByDirectiveName,this.errors),Te=(0,ge.isNodeDataInaccessible)(ne),pe=Y(x({},ne.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(ne)});switch(o){case ge.MergeMethod.CONSISTENT:!Te&&r.appearances>ne.appearances&&this.errors.push((0,we.incompatibleSharedEnumError)(n)),i.push(z),Te||a.push(pe);break;case ge.MergeMethod.INTERSECTION:r.appearances===ne.appearances&&(i.push(z),Te||a.push(pe));break;default:i.push(z),Te||a.push(pe);break}}if(r.node.values=i,this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r)),(0,ge.isNodeDataInaccessible)(r)){this.validateReferencesOfInaccessibleType(r),this.internalGraph.setNodeInaccessible(r.name);break}if(a.length<1){this.errors.push((0,we.allChildDefinitionsAreInaccessibleError)((0,he.kindToNodeType)(r.kind),n,Oe.ENUM_VALUE));break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r),values:a}));break;case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:let c=[],l=[],p=[];for(let[ne,z]of r.inputValueDataByName)if(r.subgraphNames.size===z.subgraphNames.size){if(l.push(this.getNodeWithPersistedDirectivesByInputValueData(z)),(0,ge.isNodeDataInaccessible)(z))continue;p.push(Y(x({},z.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(z)}))}else(0,ge.isTypeRequired)(z.type)&&c.push({inputValueName:ne,missingSubgraphs:(0,he.getEntriesNotInHashSet)(r.subgraphNames,z.subgraphNames),requiredSubgraphs:[...z.requiredSubgraphNames]});if(c.length>0){this.errors.push((0,we.invalidRequiredInputValueError)(Oe.INPUT_OBJECT,n,c,!1));break}if(r.node.fields=l,this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r)),(0,ge.isNodeDataInaccessible)(r)){this.validateReferencesOfInaccessibleType(r);break}if(p.length<1){this.errors.push((0,we.allChildDefinitionsAreInaccessibleError)((0,he.kindToNodeType)(r.kind),n,"input field"));break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r),fields:p}));break;case Re.Kind.INTERFACE_TYPE_DEFINITION:case Re.Kind.OBJECT_TYPE_DEFINITION:let f=[],y=[],g=new Map,v=(0,ge.newInvalidFieldNames)(),F=r.kind===Re.Kind.OBJECT_TYPE_DEFINITION,k=this.authorizationDataByParentTypeName.get(n);(0,ge.propagateAuthDirectives)(r,k);for(let[ne,z]of r.fieldDataByName){(0,ge.propagateFieldAuthDirectives)(z,k);let Te=this.getValidFieldArgumentNodes(z);F&&(0,ge.validateExternalAndShareable)(z,v),f.push(this.getNodeWithPersistedDirectivesByFieldData(z,Te)),!(0,ge.isNodeDataInaccessible)(z)&&(y.push((0,ge.getClientSchemaFieldNodeByFieldData)(z)),g.set(ne,this.fieldDataToGraphFieldData(z)))}if(F&&(v.byShareable.size>0&&this.errors.push((0,we.invalidFieldShareabilityError)(r,v.byShareable)),v.subgraphNamesByExternalFieldName.size>0&&this.errors.push((0,we.allExternalFieldInstancesError)(n,v.subgraphNamesByExternalFieldName))),r.node.fields=f,this.internalGraph.initializeNode(n,g),r.implementedInterfaceTypeNames.size>0){t.push({data:r,clientSchemaFieldNodes:y});break}this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r));let K=(0,yle.isNodeQuery)(n);if((0,ge.isNodeDataInaccessible)(r)){if(K){this.errors.push(we.inaccessibleQueryRootTypeError);break}this.validateReferencesOfInaccessibleType(r),this.internalGraph.setNodeInaccessible(r.name);break}if(y.length<1){let ne=K?(0,we.noQueryRootTypeError)(!1):(0,we.allChildDefinitionsAreInaccessibleError)((0,he.kindToNodeType)(r.kind),n,Oe.FIELD);this.errors.push(ne);break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r),fields:y}));break;case Re.Kind.SCALAR_TYPE_DEFINITION:if(jn.BASE_SCALARS.has(n))break;if((0,ge.propagateAuthDirectives)(r,this.authorizationDataByParentTypeName.get(n)),this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r)),(0,ge.isNodeDataInaccessible)(r)){this.validateReferencesOfInaccessibleType(r),this.internalGraph.setNodeInaccessible(r.name);break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r)}));break;case Re.Kind.UNION_TYPE_DEFINITION:if(r.node.types=(0,ti.mapToArrayOfValues)(r.memberByMemberTypeName),this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r)),(0,ge.isNodeDataInaccessible)(r)){this.validateReferencesOfInaccessibleType(r),this.internalGraph.setNodeInaccessible(r.name);break}let $=this.getClientSchemaUnionMembers(r);if($.length<1){this.errors.push((0,we.allChildDefinitionsAreInaccessibleError)(Oe.UNION,n,"union member type"));break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r),types:$}));break}}pushNamedTypeAuthDataToFields(){var t;for(let[n,r]of this.authorizationDataByParentTypeName){if(!r.requiresAuthentication&&r.requiredScopes.length<1)continue;let i=this.fieldCoordsByNamedTypeName.get(n);if(i)for(let a of i){let o=a.split(Oe.PERIOD);switch(o.length){case 2:{let c=(0,he.getValueOrDefault)(this.authorizationDataByParentTypeName,o[0],()=>(0,ti.newAuthorizationData)(o[0])),l=(0,he.getValueOrDefault)(c.fieldAuthDataByFieldName,o[1],()=>(0,ti.newFieldAuthorizationData)(o[1]));(t=l.inheritedData).requiresAuthentication||(t.requiresAuthentication=r.requiresAuthentication),l.inheritedData.requiredScopes.length*r.requiredScopes.length>jn.MAX_OR_SCOPES?this.invalidORScopesCoords.add(a):(l.inheritedData.requiredScopesByOR=(0,ti.mergeRequiredScopesByAND)(l.inheritedData.requiredScopesByOR,r.requiredScopesByOR),l.inheritedData.requiredScopes=(0,ti.mergeRequiredScopesByAND)(l.inheritedData.requiredScopes,r.requiredScopes));break}default:break}}}}federateSubgraphData(){this.federateInternalSubgraphData(),this.handleEntityInterfaces(),this.generateTagData(),this.pushVersionTwoDirectiveDefinitionsToDocumentDefinitions(),this.pushNamedTypeAuthDataToFields()}validateInterfaceImplementationsAndPushToDocumentDefinitions(t){for(let{data:n,clientSchemaFieldNodes:r}of t){if(n.node.interfaces=this.getValidImplementedInterfaces(n),this.routerDefinitions.push((0,ge.getNodeForRouterSchemaByData)(n,this.persistedDirectiveDefinitionByDirectiveName,this.errors)),(0,ge.isNodeDataInaccessible)(n)){this.validateReferencesOfInaccessibleType(n),this.internalGraph.setNodeInaccessible(n.name);continue}let i=[];for(let a of n.implementedInterfaceTypeNames)this.inaccessibleCoords.has(a)||i.push((0,kr.stringToNamedTypeNode)(a));this.clientDefinitions.push(Y(x({},n.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(n),fields:r,interfaces:i}))}}pushVersionTwoDirectiveDefinitionsToDocumentDefinitions(){this.isVersionTwo&&(this.routerDefinitions=[jn.AUTHENTICATED_DEFINITION,jn.DEPRECATED_DEFINITION,jn.INACCESSIBLE_DEFINITION,jn.REQUIRES_SCOPES_DEFINITION,jn.TAG_DEFINITION,jn.SCOPE_SCALAR_DEFINITION],this.clientDefinitions=[jn.DEPRECATED_DEFINITION])}validatePathSegmentInaccessibility(t){if(!t)return!1;let r=t.split(Oe.LEFT_PARENTHESIS)[0].split(Oe.PERIOD),i=r[0];for(let a=0;a0&&this.errors.push((0,we.invalidReferencesOfInaccessibleTypeError)((0,he.kindToNodeType)(t.kind),t.name,r))}validateQueryRootType(){let t=this.parentDefinitionDataByTypeName.get(Oe.QUERY);if(!t||t.kind!==Re.Kind.OBJECT_TYPE_DEFINITION||t.fieldDataByName.size<1){this.errors.push((0,we.noQueryRootTypeError)());return}for(let n of t.fieldDataByName.values())if(!(0,ge.isNodeDataInaccessible)(n))return;this.errors.push((0,we.noQueryRootTypeError)())}validateSubscriptionFieldConditionFieldPath(t,n,r,i,a){let o=t.split(Oe.PERIOD);if(o.length<1)return a.push((0,we.invalidSubscriptionFieldConditionFieldPathErrorMessage)(r,t)),[];let c=n;if(this.inaccessibleCoords.has(c.renamedTypeName))return a.push((0,we.inaccessibleSubscriptionFieldConditionFieldPathFieldErrorMessage)(r,t,o[0],c.renamedTypeName)),[];let l="";for(let p=0;p0?`.${f}`:f,c.kind!==Re.Kind.OBJECT_TYPE_DEFINITION)return a.push((0,we.invalidSubscriptionFieldConditionFieldPathParentErrorMessage)(r,t,l)),[];let y=c.fieldDataByName.get(f);if(!y)return a.push((0,we.undefinedSubscriptionFieldConditionFieldPathFieldErrorMessage)(r,t,l,f,c.renamedTypeName)),[];let g=`${c.renamedTypeName}.${f}`;if(!y.subgraphNames.has(i))return a.push((0,we.invalidSubscriptionFieldConditionFieldPathFieldErrorMessage)(r,t,l,g,i)),[];if(this.inaccessibleCoords.has(g))return a.push((0,we.inaccessibleSubscriptionFieldConditionFieldPathFieldErrorMessage)(r,t,l,g)),[];if(jn.BASE_SCALARS.has(y.namedTypeName)){c={kind:Re.Kind.SCALAR_TYPE_DEFINITION,name:y.namedTypeName};continue}c=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,y.namedTypeName,Oe.PARENT_DEFINITION_DATA)}return(0,ge.isLeafKind)(c.kind)?o:(a.push((0,we.nonLeafSubscriptionFieldConditionFieldPathFinalFieldErrorMessage)(r,t,o[o.length-1],(0,he.kindToNodeType)(c.kind),c.name)),[])}validateSubscriptionFieldCondition(t,n,r,i,a,o,c){if(i>FE.MAX_SUBSCRIPTION_FILTER_DEPTH||this.isMaxDepth)return c.push((0,we.subscriptionFilterConditionDepthExceededErrorMessage)(a)),this.isMaxDepth=!0,!1;let l=!1,p=new Set([Oe.FIELD_PATH,Oe.VALUES]),f=new Set,y=new Set,g=[];for(let v of t.fields){let F=v.name.value,k=a+`.${F}`;switch(F){case Oe.FIELD_PATH:{if(p.has(Oe.FIELD_PATH))p.delete(Oe.FIELD_PATH);else{l=!0,f.add(Oe.FIELD_PATH);break}if(v.value.kind!==Re.Kind.STRING){g.push((0,we.invalidInputFieldTypeErrorMessage)(k,Oe.STRING,(0,he.kindToNodeType)(v.value.kind))),l=!0;break}let K=this.validateSubscriptionFieldConditionFieldPath(v.value.value,r,k,o,g);if(K.length<1){l=!0;break}n.fieldPath=K;break}case Oe.VALUES:{if(p.has(Oe.VALUES))p.delete(Oe.VALUES);else{l=!0,f.add(Oe.VALUES);break}let K=v.value.kind;if(K==Re.Kind.NULL||K==Re.Kind.OBJECT){g.push((0,we.invalidInputFieldTypeErrorMessage)(k,Oe.LIST,(0,he.kindToNodeType)(v.value.kind))),l=!0;break}if(K!==Re.Kind.LIST){n.values=[(0,ge.getSubscriptionFilterValue)(v.value)];break}let $=new Set,ne=[];for(let z=0;z0){g.push((0,we.subscriptionFieldConditionInvalidValuesArrayErrorMessage)(k,ne));continue}if($.size<1){l=!0,g.push((0,we.subscriptionFieldConditionEmptyValuesArrayErrorMessage)(k));continue}n.values=[...$];break}default:l=!0,y.add(F)}}return l?(c.push((0,we.subscriptionFieldConditionInvalidInputFieldErrorMessage)(a,[...p],[...f],[...y],g)),!1):!0}validateSubscriptionFilterCondition(t,n,r,i,a,o,c){if(i>FE.MAX_SUBSCRIPTION_FILTER_DEPTH||this.isMaxDepth)return c.push((0,we.subscriptionFilterConditionDepthExceededErrorMessage)(a)),this.isMaxDepth=!0,!1;if(i+=1,t.fields.length!==1)return c.push((0,we.subscriptionFilterConditionInvalidInputFieldNumberErrorMessage)(a,t.fields.length)),!1;let l=t.fields[0],p=l.name.value;if(!Zq.SUBSCRIPTION_FILTER_INPUT_NAMES.has(p))return c.push((0,we.subscriptionFilterConditionInvalidInputFieldErrorMessage)(a,p)),!1;let f=a+`.${p}`;switch(l.value.kind){case Re.Kind.OBJECT:switch(p){case Oe.IN_UPPER:return n.in={fieldPath:[],values:[]},this.validateSubscriptionFieldCondition(l.value,n.in,r,i,a+".IN",o,c);case Oe.NOT_UPPER:return n.not={},this.validateSubscriptionFilterCondition(l.value,n.not,r,i,a+".NOT",o,c);default:return c.push((0,we.subscriptionFilterConditionInvalidInputFieldTypeErrorMessage)(f,Oe.LIST,Oe.OBJECT)),!1}case Re.Kind.LIST:{let y=[];switch(p){case Oe.AND_UPPER:{n.and=y;break}case Oe.OR_UPPER:{n.or=y;break}default:return c.push((0,we.subscriptionFilterConditionInvalidInputFieldTypeErrorMessage)(f,Oe.OBJECT,Oe.LIST)),!1}let g=l.value.values.length;if(g<1||g>5)return c.push((0,we.subscriptionFilterArrayConditionInvalidLengthErrorMessage)(f,g)),!1;let v=!0,F=[];for(let k=0;k0?(c.push((0,we.subscriptionFilterArrayConditionInvalidItemTypeErrorMessage)(f,F)),!1):v}default:{let y=Zq.SUBSCRIPTION_FILTER_LIST_INPUT_NAMES.has(p)?Oe.LIST:Oe.OBJECT;return c.push((0,we.subscriptionFilterConditionInvalidInputFieldTypeErrorMessage)(f,y,(0,he.kindToNodeType)(l.value.kind))),!1}}}validateSubscriptionFilterAndGenerateConfiguration(t,n,r,i,a,o){if(!t.arguments||t.arguments.length!==1)return;let c=t.arguments[0];if(c.value.kind!==Re.Kind.OBJECT){this.errors.push((0,we.invalidSubscriptionFilterDirectiveError)(r,[(0,we.subscriptionFilterConditionInvalidInputFieldTypeErrorMessage)(Oe.CONDITION,Oe.OBJECT,(0,he.kindToNodeType)(c.value.kind))]));return}let l={},p=[];if(!this.validateSubscriptionFilterCondition(c.value,l,n,0,Oe.CONDITION,o,p)){this.errors.push((0,we.invalidSubscriptionFilterDirectiveError)(r,p)),this.isMaxDepth=!1;return}(0,he.getValueOrDefault)(this.fieldConfigurationByFieldCoords,r,()=>({argumentNames:[],fieldName:i,typeName:a})).subscriptionFilterCondition=l}validateSubscriptionFiltersAndGenerateConfiguration(){for(let[t,n]of this.subscriptionFilterDataByFieldPath){if(this.inaccessibleCoords.has(t))continue;let r=this.parentDefinitionDataByTypeName.get(n.fieldData.namedTypeName);if(!r){this.errors.push((0,we.invalidSubscriptionFilterDirectiveError)(t,[(0,we.subscriptionFilterNamedTypeErrorMessage)(n.fieldData.namedTypeName)]));continue}(0,ge.isNodeDataInaccessible)(r)||r.kind===Re.Kind.OBJECT_TYPE_DEFINITION&&this.validateSubscriptionFilterAndGenerateConfiguration(n.directive,r,t,n.fieldData.name,n.fieldData.renamedParentTypeName,n.directiveSubgraphName)}}buildFederationResult(){this.subscriptionFilterDataByFieldPath.size>0&&this.validateSubscriptionFiltersAndGenerateConfiguration(),this.invalidORScopesCoords.size>0&&this.errors.push((0,we.orScopesLimitError)(jn.MAX_OR_SCOPES,[...this.invalidORScopesCoords]));for(let a of this.potentialPersistedDirectiveDefinitionDataByDirectiveName.values())(0,ge.addValidPersistedDirectiveDefinitionNodeByData)(this.routerDefinitions,a,this.persistedDirectiveDefinitionByDirectiveName,this.errors);let t=[];this.pushParentDefinitionDataToDocumentDefinitions(t),this.validateInterfaceImplementationsAndPushToDocumentDefinitions(t),this.validateQueryRootType();for(let a of this.inaccessibleRequiredInputValueErrorByCoords.values())this.errors.push(a);if(this.errors.length>0)return{errors:this.errors,success:!1,warnings:this.warnings};if(!this.disableResolvabilityValidation&&this.internalSubgraphBySubgraphName.size>1){let a=this.internalGraph.validate();if(a.length>0)return{errors:a,success:!1,warnings:this.warnings}}let n={kind:Re.Kind.DOCUMENT,definitions:this.routerDefinitions},r=(0,Re.buildASTSchema)({kind:Re.Kind.DOCUMENT,definitions:this.clientDefinitions},{assumeValid:!0,assumeValidSDL:!0}),i=new Map;for(let a of this.internalSubgraphBySubgraphName.values())i.set(a.name,{configurationDataByTypeName:a.configurationDataByTypeName,isVersionTwo:a.isVersionTwo,parentDefinitionDataByTypeName:a.parentDefinitionDataByTypeName,schema:a.schema});for(let a of this.authorizationDataByParentTypeName.values())(0,ti.upsertAuthorizationConfiguration)(this.fieldConfigurationByFieldCoords,a);return x({fieldConfigurations:Array.from(this.fieldConfigurationByFieldCoords.values()),subgraphConfigBySubgraphName:i,federatedGraphAST:n,federatedGraphSchema:(0,Re.buildASTSchema)(n,{assumeValid:!0,assumeValidSDL:!0}),federatedGraphClientSchema:r,parentDefinitionDataByTypeName:this.parentDefinitionDataByTypeName,success:!0,warnings:this.warnings},this.getClientSchemaObjectBoolean())}getClientSchemaObjectBoolean(){return this.inaccessibleCoords.size<1&&this.tagNamesByCoords.size<1?{}:{shouldIncludeClientSchema:!0}}handleChildTagExclusions(t,n,r,i){let a=n.size;for(let[o,c]of r){let l=(0,he.getOrThrowError)(n,o,`${t.name}.childDataByChildName`);if((0,ge.isNodeDataInaccessible)(l)){a-=1;continue}i.isDisjointFrom(c.tagNames)||((0,he.getValueOrDefault)(l.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(`${t.name}.${o}`),a-=1)}a<1&&(t.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(t.name))}handleChildTagInclusions(t,n,r,i){let a=n.size;for(let[o,c]of n){if((0,ge.isNodeDataInaccessible)(c)){a-=1;continue}let l=r.get(o);(!l||i.isDisjointFrom(l.tagNames))&&((0,he.getValueOrDefault)(c.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(`${t.name}.${o}`),a-=1)}a<1&&(t.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(t.name))}buildFederationContractResult(t){if(this.isVersionTwo||this.routerDefinitions.push(jn.INACCESSIBLE_DEFINITION),t.tagNamesToExclude.size>0)for(let[o,c]of this.parentTagDataByTypeName){let l=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,o,Oe.PARENT_DEFINITION_DATA);if(!(0,ge.isNodeDataInaccessible)(l)){if(!t.tagNamesToExclude.isDisjointFrom(c.tagNames)){l.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o);continue}if(!(c.childTagDataByChildName.size<1))switch(l.kind){case Re.Kind.SCALAR_TYPE_DEFINITION:case Re.Kind.UNION_TYPE_DEFINITION:continue;case Re.Kind.ENUM_TYPE_DEFINITION:this.handleChildTagExclusions(l,l.enumValueDataByValueName,c.childTagDataByChildName,t.tagNamesToExclude);break;case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:this.handleChildTagExclusions(l,l.inputValueDataByName,c.childTagDataByChildName,t.tagNamesToExclude);break;default:let p=l.fieldDataByName.size;for(let[f,y]of c.childTagDataByChildName){let g=(0,he.getOrThrowError)(l.fieldDataByName,f,`${o}.fieldDataByFieldName`);if((0,ge.isNodeDataInaccessible)(g)){p-=1;continue}if(!t.tagNamesToExclude.isDisjointFrom(y.tagNames)){(0,he.getValueOrDefault)(g.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(g.federatedCoords),p-=1;continue}for(let[v,F]of y.tagNamesByArgumentName){let k=(0,he.getOrThrowError)(g.argumentDataByName,v,`${f}.argumentDataByArgumentName`);(0,ge.isNodeDataInaccessible)(k)||F.isDisjointFrom(F)||((0,he.getValueOrDefault)(k.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(k.federatedCoords))}}p<1&&(l.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o))}}}else if(t.tagNamesToInclude.size>0)for(let[o,c]of this.parentDefinitionDataByTypeName){if((0,ge.isNodeDataInaccessible)(c))continue;let l=this.parentTagDataByTypeName.get(o);if(!l){c.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o);continue}if(t.tagNamesToInclude.isDisjointFrom(l.tagNames)){if(l.childTagDataByChildName.size<1){c.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o);continue}switch(c.kind){case Re.Kind.SCALAR_TYPE_DEFINITION:case Re.Kind.UNION_TYPE_DEFINITION:continue;case Re.Kind.ENUM_TYPE_DEFINITION:this.handleChildTagInclusions(c,c.enumValueDataByValueName,l.childTagDataByChildName,t.tagNamesToInclude);break;case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:this.handleChildTagInclusions(c,c.inputValueDataByName,l.childTagDataByChildName,t.tagNamesToInclude);break;default:let p=c.fieldDataByName.size;for(let[f,y]of c.fieldDataByName){if((0,ge.isNodeDataInaccessible)(y)){p-=1;continue}let g=l.childTagDataByChildName.get(f);(!g||t.tagNamesToInclude.isDisjointFrom(g.tagNames))&&((0,he.getValueOrDefault)(y.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(y.federatedCoords),p-=1)}p<1&&(c.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o))}}}this.subscriptionFilterDataByFieldPath.size>0&&this.validateSubscriptionFiltersAndGenerateConfiguration();for(let o of this.potentialPersistedDirectiveDefinitionDataByDirectiveName.values())(0,ge.addValidPersistedDirectiveDefinitionNodeByData)(this.routerDefinitions,o,this.persistedDirectiveDefinitionByDirectiveName,this.errors);let n=[];if(this.pushParentDefinitionDataToDocumentDefinitions(n),this.validateInterfaceImplementationsAndPushToDocumentDefinitions(n),this.validateQueryRootType(),this.errors.length>0)return{errors:this.errors,success:!1,warnings:this.warnings};let r={kind:Re.Kind.DOCUMENT,definitions:this.routerDefinitions},i=(0,Re.buildASTSchema)({kind:Re.Kind.DOCUMENT,definitions:this.clientDefinitions},{assumeValid:!0,assumeValidSDL:!0}),a=new Map;for(let o of this.internalSubgraphBySubgraphName.values())a.set(o.name,{configurationDataByTypeName:o.configurationDataByTypeName,isVersionTwo:o.isVersionTwo,parentDefinitionDataByTypeName:o.parentDefinitionDataByTypeName,schema:o.schema});for(let o of this.authorizationDataByParentTypeName.values())(0,ti.upsertAuthorizationConfiguration)(this.fieldConfigurationByFieldCoords,o);return x({fieldConfigurations:Array.from(this.fieldConfigurationByFieldCoords.values()),subgraphConfigBySubgraphName:a,federatedGraphAST:r,federatedGraphSchema:(0,Re.buildASTSchema)(r,{assumeValid:!0,assumeValidSDL:!0}),federatedGraphClientSchema:i,parentDefinitionDataByTypeName:this.parentDefinitionDataByTypeName,success:!0,warnings:this.warnings},this.getClientSchemaObjectBoolean())}federateSubgraphsInternal(){return this.federateSubgraphData(),this.buildFederationResult()}};Sc.FederationFactory=wE;function tD({disableResolvabilityValidation:e,subgraphs:t}){if(t.length<1)return{errors:[we.minimumSubgraphRequirementError],success:!1,warnings:[]};let n=(0,hle.batchNormalize)(t);if(!n.success)return{errors:n.errors,success:!1,warnings:n.warnings};let r=new Map,i=new Map;for(let[o,c]of n.internalSubgraphBySubgraphName)for(let[l,p]of c.entityInterfaces){let f=r.get(l);if(!f){r.set(l,(0,ti.newEntityInterfaceFederationData)(p,o));continue}(0,ti.upsertEntityInterfaceFederationData)(f,p,o)}let a=new Array;for(let[o,c]of r){let l=c.concreteTypeNames.size;for(let[p,f]of c.subgraphDataByTypeName){if(!f.isInterfaceObject){f.resolvable&&f.concreteTypeNames.size!==l&&(0,he.getValueOrDefault)(i,o,()=>[]).push({subgraphName:p,concreteTypeNames:f.concreteTypeNames});continue}let{parentDefinitionDataByTypeName:y}=(0,he.getOrThrowError)(n.internalSubgraphBySubgraphName,p,"internalSubgraphBySubgraphName"),g=[];for(let v of c.concreteTypeNames)y.has(v)&&g.push(v);g.length>0&&a.push((0,we.invalidInterfaceObjectImplementationDefinitionsError)(o,p,g))}}return i.size>0&&a.push((0,we.undefinedEntityInterfaceImplementationsError)(i,r)),a.length>0?{errors:a,success:!1,warnings:n.warnings}:{federationFactory:new wE({authorizationDataByParentTypeName:n.authorizationDataByParentTypeName,concreteTypeNamesByAbstractTypeName:n.concreteTypeNamesByAbstractTypeName,disableResolvabilityValidation:e,entityDataByTypeName:n.entityDataByTypeName,entityInterfaceFederationDataByTypeName:r,fieldCoordsByNamedTypeName:n.fieldCoordsByNamedTypeName,internalSubgraphBySubgraphName:n.internalSubgraphBySubgraphName,internalGraph:n.internalGraph,warnings:n.warnings}),success:!0,warnings:n.warnings}}function gle({disableResolvabilityValidation:e,subgraphs:t}){let n=tD({subgraphs:t,disableResolvabilityValidation:e});return n.success?n.federationFactory.federateSubgraphsInternal():{errors:n.errors,success:!1,warnings:n.warnings}}function _le({subgraphs:e,tagOptionsByContractName:t,disableResolvabilityValidation:n}){let r=tD({subgraphs:e,disableResolvabilityValidation:n});if(!r.success)return{errors:r.errors,success:!1,warnings:r.warnings};r.federationFactory.federateSubgraphData();let i=[(0,tV.cloneDeep)(r.federationFactory)],a=r.federationFactory.buildFederationResult();if(!a.success)return{errors:a.errors,success:!1,warnings:a.warnings};let o=t.size-1,c=new Map,l=0;for(let[p,f]of t){l!==o&&i.push((0,tV.cloneDeep)(i[l]));let y=i[l].buildFederationContractResult(f);c.set(p,y),l++}return Y(x({},a),{federationResultByContractName:c})}function vle({contractTagOptions:e,disableResolvabilityValidation:t,subgraphs:n}){let r=tD({subgraphs:n,disableResolvabilityValidation:t});return r.success?(r.federationFactory.federateSubgraphData(),r.federationFactory.buildFederationContractResult(e)):{errors:r.errors,success:!1,warnings:r.warnings}}});var LE=w(Ss=>{"use strict";m();T();N();Object.defineProperty(Ss,"__esModule",{value:!0});Ss.LATEST_ROUTER_COMPATIBILITY_VERSION=Ss.ROUTER_COMPATIBILITY_VERSIONS=Ss.ROUTER_COMPATIBILITY_VERSION_ONE=void 0;Ss.ROUTER_COMPATIBILITY_VERSION_ONE="1";Ss.ROUTER_COMPATIBILITY_VERSIONS=new Set([Ss.ROUTER_COMPATIBILITY_VERSION_ONE]);Ss.LATEST_ROUTER_COMPATIBILITY_VERSION="1"});var rV=w(Hp=>{"use strict";m();T();N();Object.defineProperty(Hp,"__esModule",{value:!0});Hp.federateSubgraphs=Sle;Hp.federateSubgraphsWithContracts=Ole;Hp.federateSubgraphsContract=Dle;var nD=nV(),rD=LE();function Sle({disableResolvabilityValidation:e,subgraphs:t,version:n=rD.ROUTER_COMPATIBILITY_VERSION_ONE}){switch(n){default:return(0,nD.federateSubgraphs)({disableResolvabilityValidation:e,subgraphs:t})}}function Ole({disableResolvabilityValidation:e,subgraphs:t,tagOptionsByContractName:n,version:r=rD.ROUTER_COMPATIBILITY_VERSION_ONE}){switch(r){default:return(0,nD.federateSubgraphsWithContracts)({disableResolvabilityValidation:e,subgraphs:t,tagOptionsByContractName:n})}}function Dle({contractTagOptions:e,disableResolvabilityValidation:t,subgraphs:n,version:r=rD.ROUTER_COMPATIBILITY_VERSION_ONE}){switch(r){default:return(0,nD.federateSubgraphsContract)({disableResolvabilityValidation:t,subgraphs:n,contractTagOptions:e})}}});var aV=w(iV=>{"use strict";m();T();N();Object.defineProperty(iV,"__esModule",{value:!0})});var sV=w(zp=>{"use strict";m();T();N();Object.defineProperty(zp,"__esModule",{value:!0});zp.normalizeSubgraphFromString=ble;zp.normalizeSubgraph=Ale;zp.batchNormalize=Rle;var iD=WO(),aD=LE();function ble(e,t=!0,n=aD.ROUTER_COMPATIBILITY_VERSION_ONE){switch(n){default:return(0,iD.normalizeSubgraphFromString)(e,t)}}function Ale(e,t,n,r=aD.ROUTER_COMPATIBILITY_VERSION_ONE){switch(r){default:return(0,iD.normalizeSubgraph)(e,t,n)}}function Rle(e,t=aD.ROUTER_COMPATIBILITY_VERSION_ONE){switch(t){default:return(0,iD.batchNormalize)(e)}}});var uV=w(oV=>{"use strict";m();T();N();Object.defineProperty(oV,"__esModule",{value:!0})});var lV=w(cV=>{"use strict";m();T();N();Object.defineProperty(cV,"__esModule",{value:!0})});var pV=w(dV=>{"use strict";m();T();N();Object.defineProperty(dV,"__esModule",{value:!0})});var mV=w(fV=>{"use strict";m();T();N();Object.defineProperty(fV,"__esModule",{value:!0})});var NV=w(CE=>{"use strict";m();T();N();Object.defineProperty(CE,"__esModule",{value:!0});CE.COMPOSITION_VERSION=void 0;CE.COMPOSITION_VERSION="{{$COMPOSITION__VERSION}}"});var EV=w(TV=>{"use strict";m();T();N();Object.defineProperty(TV,"__esModule",{value:!0})});var yV=w(hV=>{"use strict";m();T();N();Object.defineProperty(hV,"__esModule",{value:!0})});var gV=w(IV=>{"use strict";m();T();N();Object.defineProperty(IV,"__esModule",{value:!0})});var BE=w(pt=>{"use strict";m();T();N();var Ple=pt&&pt.__createBinding||(Object.create?function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]}),St=pt&&pt.__exportStar||function(e,t){for(var n in e)n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n)&&Ple(t,e,n)};Object.defineProperty(pt,"__esModule",{value:!0});St(Yr(),pt);St(dv(),pt);St(ia(),pt);St(Pk(),pt);St(rV(),pt);St(aV(),pt);St(sV(),pt);St(uV(),pt);St(JO(),pt);St(KO(),pt);St($O(),pt);St(LE(),pt);St(lV(),pt);St(HO(),pt);St(ou(),pt);St(hp(),pt);St(hl(),pt);St(pV(),pt);St(mV(),pt);St(NV(),pt);St(ur(),pt);St(EV(),pt);St(Jr(),pt);St(BO(),pt);St(BN(),pt);St(eD(),pt);St(yV(),pt);St(PO(),pt);St(Gp(),pt);St(gV(),pt);St(MO(),pt);St(RE(),pt);St(LO(),pt);St(Es(),pt);St(Kp(),pt);St(kp(),pt);St(gE(),pt)});var vde={};sm(vde,{buildRouterConfiguration:()=>_de,federateSubgraphs:()=>gde});m();T();N();var Fc=ss(BE());m();T();N();m();T();N();function sD(e){if(!e)return e;if(!URL.canParse(e))throw new Error("Invalid URL");let t=e.indexOf("?"),n=e.indexOf("#"),r=e;return t>0?r=r.slice(0,n>0?Math.min(t,n):t):n>0&&(r=r.slice(0,n)),r}m();T();N();m();T();N();var _V={};m();T();N();function vV(e){return e!=null}m();T();N();m();T();N();var AV=ss(Ae(),1);m();T();N();var SV;if(typeof AggregateError=="undefined"){class e extends Error{constructor(n,r=""){super(r),this.errors=n,this.name="AggregateError",Error.captureStackTrace(this,e)}}SV=function(t,n){return new e(t,n)}}else SV=AggregateError;function OV(e){return"errors"in e&&Array.isArray(e.errors)}var RV=3;function PV(e){return UE(e,[])}function UE(e,t){switch(typeof e){case"string":return JSON.stringify(e);case"function":return e.name?`[function ${e.name}]`:"[function]";case"object":return Fle(e,t);default:return String(e)}}function DV(e){return e instanceof AV.GraphQLError?e.toString():`${e.name}: ${e.message}; +}`;var Et=DA(function(){return jt(L,je+"return "+Ee).apply(e,M)});if(Et.source=Ee,cy(Et))throw Et;return Et}function lY(s){return Qt(s).toLowerCase()}function dY(s){return Qt(s).toUpperCase()}function pY(s,u,d){if(s=Qt(s),s&&(d||u===e))return Bb(s);if(!s||!(u=ai(u)))return s;var E=$i(s),S=$i(u),L=Ub(E,S),M=kb(E,S)+1;return Qo(E,L,M).join("")}function fY(s,u,d){if(s=Qt(s),s&&(d||u===e))return s.slice(0,xb(s)+1);if(!s||!(u=ai(u)))return s;var E=$i(s),S=kb(E,$i(u))+1;return Qo(E,0,S).join("")}function mY(s,u,d){if(s=Qt(s),s&&(d||u===e))return s.replace(ch,"");if(!s||!(u=ai(u)))return s;var E=$i(s),S=Ub(E,$i(u));return Qo(E,S).join("")}function NY(s,u){var d=et,E=X;if(_n(u)){var S="separator"in u?u.separator:S;d="length"in u?Nt(u.length):d,E="omission"in u?ai(u.omission):E}s=Qt(s);var L=s.length;if(Uc(s)){var M=$i(s);L=M.length}if(d>=L)return s;var j=d-kc(E);if(j<1)return E;var H=M?Qo(M,0,j).join(""):s.slice(0,j);if(S===e)return H+E;if(M&&(j+=H.length-j),ly(S)){if(s.slice(j).search(S)){var fe,me=H;for(S.global||(S=Dh(S.source,Qt(rb.exec(S))+"g")),S.lastIndex=0;fe=S.exec(me);)var Ee=fe.index;H=H.slice(0,Ee===e?j:Ee)}}else if(s.indexOf(ai(S),j)!=j){var be=H.lastIndexOf(S);be>-1&&(H=H.slice(0,be))}return H+E}function TY(s){return s=Qt(s),s&&b1.test(s)?s.replace(eb,$j):s}var EY=Kc(function(s,u,d){return s+(d?" ":"")+u.toUpperCase()}),fy=b0("toUpperCase");function OA(s,u,d){return s=Qt(s),u=d?e:u,u===e?qj(s)?Jj(s):Fj(s):s.match(u)||[]}var DA=yt(function(s,u){try{return ri(s,e,u)}catch(d){return cy(d)?d:new ot(d)}}),hY=ts(function(s,u){return Ti(u,function(d){d=_a(d),Za(s,d,oy(s[d],s))}),s});function yY(s){var u=s==null?0:s.length,d=ze();return s=u?yn(s,function(E){if(typeof E[1]!="function")throw new Ei(i);return[d(E[0]),E[1]]}):[],yt(function(E){for(var S=-1;++Sdn)return[];var d=Un,E=Tr(s,Un);u=ze(u),s-=Un;for(var S=vh(E,u);++d0||u<0)?new Ot(d):(s<0?d=d.takeRight(-s):s&&(d=d.drop(s)),u!==e&&(u=Nt(u),d=u<0?d.dropRight(-u):d.take(u-s)),d)},Ot.prototype.takeRightWhile=function(s){return this.reverse().takeWhile(s).reverse()},Ot.prototype.toArray=function(){return this.take(Un)},Ia(Ot.prototype,function(s,u){var d=/^(?:filter|find|map|reject)|While$/.test(u),E=/^(?:head|last)$/.test(u),S=R[E?"take"+(u=="last"?"Right":""):u],L=E||/^find/.test(u);S&&(R.prototype[u]=function(){var M=this.__wrapped__,j=E?[1]:arguments,H=M instanceof Ot,fe=j[0],me=H||lt(M),Ee=function(vt){var Rt=S.apply(R,xo([vt],j));return E&&be?Rt[0]:Rt};me&&d&&typeof fe=="function"&&fe.length!=1&&(H=me=!1);var be=this.__chain__,je=!!this.__actions__.length,Xe=L&&!be,Et=H&&!je;if(!L&&me){M=Et?M:new Ot(this);var Ze=s.apply(M,j);return Ze.__actions__.push({func:Xf,args:[Ee],thisArg:e}),new hi(Ze,be)}return Xe&&Et?s.apply(this,j):(Ze=this.thru(Ee),Xe?E?Ze.value()[0]:Ze.value():Ze)})}),Ti(["pop","push","shift","sort","splice","unshift"],function(s){var u=Sf[s],d=/^(?:push|sort|unshift)$/.test(s)?"tap":"thru",E=/^(?:pop|shift)$/.test(s);R.prototype[s]=function(){var S=arguments;if(E&&!this.__chain__){var L=this.value();return u.apply(lt(L)?L:[],S)}return this[d](function(M){return u.apply(lt(M)?M:[],S)})}}),Ia(Ot.prototype,function(s,u){var d=R[u];if(d){var E=d.name+"";Zt.call(qc,E)||(qc[E]=[]),qc[E].push({name:u,func:d})}}),qc[$f(e,U).name]=[{name:"wrapper",func:e}],Ot.prototype.clone=TK,Ot.prototype.reverse=EK,Ot.prototype.value=hK,R.prototype.at=Y$,R.prototype.chain=J$,R.prototype.commit=H$,R.prototype.next=z$,R.prototype.plant=X$,R.prototype.reverse=Z$,R.prototype.toJSON=R.prototype.valueOf=R.prototype.value=eQ,R.prototype.first=R.prototype.head,sd&&(R.prototype[sd]=W$),R},Vo=Hj();typeof define=="function"&&typeof define.amd=="object"&&define.amd?(ir._=Vo,define(function(){return Vo})):Su?((Su.exports=Vo)._=Vo,Nh._=Vo):ir._=Vo}).call(Yl)});var nV=w(Sc=>{"use strict";m();T();N();Object.defineProperty(Sc,"__esModule",{value:!0});Sc.FederationFactory=void 0;Sc.federateSubgraphs=gle;Sc.federateSubgraphsWithContracts=_le;Sc.federateSubgraphsContract=vle;var Re=Ae(),Xq=ou(),kr=Yr(),we=ia(),vc=BN(),Zq=kp(),ti=Kp(),PE=XT(),jn=Es(),hle=WO(),yle=Gp(),eV=hp(),ge=hl(),Ile=eD(),tV=Wq(),Jl=RE(),Oe=ur(),FE=Nl(),he=Jr(),wE=class{constructor({authorizationDataByParentTypeName:t,concreteTypeNamesByAbstractTypeName:n,disableResolvabilityValidation:r,entityDataByTypeName:i,entityInterfaceFederationDataByTypeName:a,fieldCoordsByNamedTypeName:o,internalGraph:c,internalSubgraphBySubgraphName:l,warnings:p}){_(this,"authorizationDataByParentTypeName");_(this,"coordsByNamedTypeName",new Map);_(this,"disableResolvabilityValidation",!1);_(this,"clientDefinitions",[jn.DEPRECATED_DEFINITION]);_(this,"currentSubgraphName","");_(this,"concreteTypeNamesByAbstractTypeName");_(this,"subgraphNamesByNamedTypeNameByFieldCoords",new Map);_(this,"entityDataByTypeName");_(this,"entityInterfaceFederationDataByTypeName");_(this,"errors",[]);_(this,"fieldConfigurationByFieldCoords",new Map);_(this,"fieldCoordsByNamedTypeName");_(this,"inaccessibleCoords",new Set);_(this,"inaccessibleRequiredInputValueErrorByCoords",new Map);_(this,"internalGraph");_(this,"internalSubgraphBySubgraphName");_(this,"invalidORScopesCoords",new Set);_(this,"isMaxDepth",!1);_(this,"isVersionTwo",!1);_(this,"namedInputValueTypeNames",new Set);_(this,"namedOutputTypeNames",new Set);_(this,"parentDefinitionDataByTypeName",new Map);_(this,"parentTagDataByTypeName",new Map);_(this,"persistedDirectiveDefinitionByDirectiveName",new Map([[Oe.AUTHENTICATED,jn.AUTHENTICATED_DEFINITION],[Oe.DEPRECATED,jn.DEPRECATED_DEFINITION],[Oe.INACCESSIBLE,jn.INACCESSIBLE_DEFINITION],[Oe.REQUIRES_SCOPES,jn.REQUIRES_SCOPES_DEFINITION],[Oe.TAG,jn.TAG_DEFINITION]]));_(this,"persistedDirectiveDefinitions",new Set([Oe.AUTHENTICATED,Oe.DEPRECATED,Oe.INACCESSIBLE,Oe.TAG,Oe.REQUIRES_SCOPES]));_(this,"potentialPersistedDirectiveDefinitionDataByDirectiveName",new Map);_(this,"routerDefinitions",[jn.DEPRECATED_DEFINITION,jn.TAG_DEFINITION]);_(this,"subscriptionFilterDataByFieldPath",new Map);_(this,"tagNamesByCoords",new Map);_(this,"warnings");this.authorizationDataByParentTypeName=t,this.concreteTypeNamesByAbstractTypeName=n,this.disableResolvabilityValidation=r!=null?r:!1,this.entityDataByTypeName=i,this.entityInterfaceFederationDataByTypeName=a,this.fieldCoordsByNamedTypeName=o,this.internalGraph=c,this.internalSubgraphBySubgraphName=l,this.warnings=p}getValidImplementedInterfaces(t){var o;let n=[];if(t.implementedInterfaceTypeNames.size<1)return n;let r=(0,ge.isNodeDataInaccessible)(t),i=new Map,a=new Map;for(let c of t.implementedInterfaceTypeNames){n.push((0,kr.stringToNamedTypeNode)(c));let l=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,c,Oe.PARENT_DEFINITION_DATA);if(l.kind!==Re.Kind.INTERFACE_TYPE_DEFINITION){a.set(l.name,(0,he.kindToNodeType)(l.kind));continue}let p={invalidFieldImplementations:new Map,unimplementedFields:[]},f=!1;for(let[y,g]of l.fieldDataByName){let v=!1,P=t.fieldDataByName.get(y);if(!P){f=!0,p.unimplementedFields.push(y);continue}let U={invalidAdditionalArguments:new Set,invalidImplementedArguments:[],isInaccessible:!1,originalResponseType:(0,PE.printTypeNode)(g.node.type),unimplementedArguments:new Set};(0,ge.isTypeValidImplementation)(g.node.type,P.node.type,this.concreteTypeNamesByAbstractTypeName)||(f=!0,v=!0,U.implementedResponseType=(0,PE.printTypeNode)(P.node.type));let K=new Set;for(let[$,ne]of g.argumentDataByName){let z=ne.node;K.add($);let Te=(o=P.argumentDataByName.get($))==null?void 0:o.node;if(!Te){f=!0,v=!0,U.unimplementedArguments.add($);continue}let pe=(0,PE.printTypeNode)(Te.type),Fe=(0,PE.printTypeNode)(z.type);Fe!==pe&&(f=!0,v=!0,U.invalidImplementedArguments.push({actualType:pe,argumentName:$,expectedType:Fe}))}for(let[$,ne]of P.argumentDataByName){let z=ne.node;K.has($)||z.type.kind===Re.Kind.NON_NULL_TYPE&&(f=!0,v=!0,U.invalidAdditionalArguments.add($))}!r&&P.isInaccessible&&!g.isInaccessible&&(f=!0,v=!0,U.isInaccessible=!0),v&&p.invalidFieldImplementations.set(y,U)}f&&i.set(c,p)}return a.size>0&&this.errors.push((0,we.invalidImplementedTypeError)(t.name,a)),i.size>0&&this.errors.push((0,we.invalidInterfaceImplementationError)(t.node.name.value,(0,he.kindToNodeType)(t.kind),i)),n}addValidPrimaryKeyTargetsToEntityData(t){var f;let n=this.entityDataByTypeName.get(t);if(!n)return;let r=(0,he.getOrThrowError)(this.internalSubgraphBySubgraphName,this.currentSubgraphName,"internalSubgraphBySubgraphName"),i=r.parentDefinitionDataByTypeName,a=i.get(n.typeName);if(!a||a.kind!==Re.Kind.OBJECT_TYPE_DEFINITION)throw(0,we.incompatibleParentKindFatalError)(n.typeName,Re.Kind.OBJECT_TYPE_DEFINITION,(a==null?void 0:a.kind)||Re.Kind.NULL);let o=r.configurationDataByTypeName.get(n.typeName);if(!o)return;let c=[],l=this.internalGraph.nodeByNodeName.get(`${this.currentSubgraphName}.${n.typeName}`);(0,vc.validateImplicitFieldSets)({conditionalFieldDataByCoords:r.conditionalFieldDataByCoordinates,currentSubgraphName:this.currentSubgraphName,entityData:n,implicitKeys:c,objectData:a,parentDefinitionDataByTypeName:i,graphNode:l});for(let[y,g]of this.entityInterfaceFederationDataByTypeName){if(!((f=g.concreteTypeNames)!=null&&f.has(n.typeName)))continue;let v=this.entityDataByTypeName.get(y);v&&(0,vc.validateImplicitFieldSets)({conditionalFieldDataByCoords:r.conditionalFieldDataByCoordinates,currentSubgraphName:this.currentSubgraphName,entityData:v,implicitKeys:c,objectData:a,parentDefinitionDataByTypeName:i,graphNode:l})}if(c.length<1)return;if(!o.keys||o.keys.length<1){o.isRootNode=!0,o.keys=c;return}let p=new Set(o.keys.map(y=>y.selectionSet));for(let y of c)p.has(y.selectionSet)||(o.keys.push(y),p.add(y.selectionSet))}addValidPrimaryKeyTargetsFromInterfaceObject(t,n,r,i){let a=t.parentDefinitionDataByTypeName,o=a.get(n);if(!o||!(0,ge.isParentDataCompositeOutputType)(o))throw(0,we.incompatibleParentKindFatalError)(n,Re.Kind.INTERFACE_TYPE_DEFINITION,(o==null?void 0:o.kind)||Re.Kind.NULL);let c=(0,he.getOrThrowError)(t.configurationDataByTypeName,r.typeName,"internalSubgraph.configurationDataByTypeName"),l=[];if((0,vc.validateImplicitFieldSets)({conditionalFieldDataByCoords:t.conditionalFieldDataByCoordinates,currentSubgraphName:t.name,entityData:r,implicitKeys:l,objectData:o,parentDefinitionDataByTypeName:a,graphNode:i}),l.length<1)return;if(!c.keys||c.keys.length<1){c.isRootNode=!0,c.keys=l;return}let p=new Set(c.keys.map(f=>f.selectionSet));for(let f of l)p.has(f.selectionSet)||(c.keys.push(f),p.add(f.selectionSet))}getEnumValueMergeMethod(t){return this.namedInputValueTypeNames.has(t)?this.namedOutputTypeNames.has(t)?ge.MergeMethod.CONSISTENT:ge.MergeMethod.INTERSECTION:ge.MergeMethod.UNION}generateTagData(){for(let[t,n]of this.tagNamesByCoords){let r=t.split(".");if(r.length<1)continue;let i=(0,he.getValueOrDefault)(this.parentTagDataByTypeName,r[0],()=>(0,vc.newParentTagData)(r[0]));switch(r.length){case 1:for(let l of n)i.tagNames.add(l);break;case 2:let a=(0,he.getValueOrDefault)(i.childTagDataByChildName,r[1],()=>(0,vc.newChildTagData)(r[1]));for(let l of n)a.tagNames.add(l);break;case 3:let o=(0,he.getValueOrDefault)(i.childTagDataByChildName,r[1],()=>(0,vc.newChildTagData)(r[1])),c=(0,he.getValueOrDefault)(o.tagNamesByArgumentName,r[2],()=>new Set);for(let l of n)c.add(l);break;default:break}}}upsertEnumValueData(t,n,r){let i=t.get(n.name),a=i||this.copyEnumValueData(n);(0,ge.extractPersistedDirectives)(a.persistedDirectivesData,n.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName);let o=(0,ge.isNodeDataInaccessible)(n);if((r||o)&&this.inaccessibleCoords.add(a.federatedCoords),this.recordTagNamesByCoords(a,a.federatedCoords),!i){t.set(a.name,a);return}a.appearances+=1,(0,he.addNewObjectValueMapEntries)(n.configureDescriptionDataBySubgraphName,a.configureDescriptionDataBySubgraphName),(0,ge.setLongestDescription)(a,n),(0,he.addIterableValuesToSet)(n.subgraphNames,a.subgraphNames)}upsertInputValueData(t,n,r,i){let a=t.get(n.name),o=a||this.copyInputValueData(n);if((0,ge.extractPersistedDirectives)(o.persistedDirectivesData,n.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),this.recordTagNamesByCoords(o,`${r}.${o.name}`),this.namedInputValueTypeNames.add(o.namedTypeName),(0,he.getValueOrDefault)(this.coordsByNamedTypeName,o.namedTypeName,()=>new Set).add(o.federatedCoords),!a){t.set(o.name,o);return}(0,he.addNewObjectValueMapEntries)(n.configureDescriptionDataBySubgraphName,o.configureDescriptionDataBySubgraphName),(0,ge.setLongestDescription)(o,n),(0,he.addIterableValuesToSet)(n.requiredSubgraphNames,o.requiredSubgraphNames),(0,he.addIterableValuesToSet)(n.subgraphNames,o.subgraphNames),this.handleInputValueInaccessibility(i,o,r);let c=(0,Jl.getMostRestrictiveMergedTypeNode)(o.type,n.type,o.originalCoords,this.errors);c.success?o.type=c.typeNode:this.errors.push((0,we.incompatibleMergedTypesError)({actualType:c.actualType,isArgument:a.isArgument,coords:a.federatedCoords,expectedType:c.expectedType})),(0,ge.compareAndValidateInputValueDefaultValues)(o,n,this.errors)}handleInputValueInaccessibility(t,n,r){if(t){this.inaccessibleRequiredInputValueErrorByCoords.delete(n.federatedCoords),this.inaccessibleCoords.add(n.federatedCoords);return}if((0,ge.isNodeDataInaccessible)(n)){if((0,ge.isTypeRequired)(n.type)){this.inaccessibleRequiredInputValueErrorByCoords.set(n.federatedCoords,(0,we.inaccessibleRequiredInputValueError)(n,r));return}this.inaccessibleCoords.add(n.federatedCoords)}}handleSubscriptionFilterDirective(t,n){let r=t.directivesByDirectiveName.get(Oe.SUBSCRIPTION_FILTER);if(!r)return;let i=(0,he.getSingleSetEntry)(t.subgraphNames);if(i===void 0){this.errors.push((0,we.unknownFieldSubgraphNameError)(t.federatedCoords));return}this.subscriptionFilterDataByFieldPath.set(t.federatedCoords,{directive:r[0],fieldData:n||t,directiveSubgraphName:i})}federateOutputType({current:t,other:n,coords:r,mostRestrictive:i}){n=(0,Xq.getMutableTypeNode)(n,r,this.errors);let a={kind:t.kind},o=Jl.DivergentType.NONE,c=a;for(let l=0;lnew Set))}upsertFieldData(t,n,r){let i=t.get(n.name),a=i||this.copyFieldData(n,r||(0,ge.isNodeDataInaccessible)(n));(0,he.getValueOrDefault)(this.coordsByNamedTypeName,n.namedTypeName,()=>new Set).add(a.federatedCoords),this.namedOutputTypeNames.add(n.namedTypeName),this.handleSubscriptionFilterDirective(n,a),(0,ge.extractPersistedDirectives)(a.persistedDirectivesData,n.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName);let o=r||(0,ge.isNodeDataInaccessible)(a);if(o&&this.inaccessibleCoords.add(a.federatedCoords),this.recordTagNamesByCoords(a,a.federatedCoords),!i){t.set(a.name,a);return}let c=this.federateOutputType({current:a.type,other:n.type,coords:a.federatedCoords,mostRestrictive:!1});if(c.success)if(a.type=c.typeNode,a.namedTypeName!==n.namedTypeName){let l=(0,he.getValueOrDefault)(this.subgraphNamesByNamedTypeNameByFieldCoords,a.federatedCoords,()=>new Map),p=(0,he.getValueOrDefault)(l,a.namedTypeName,()=>new Set);if(p.size<1)for(let f of a.subgraphNames)n.subgraphNames.has(f)||p.add(f);(0,he.addIterableValuesToSet)(n.subgraphNames,(0,he.getValueOrDefault)(l,n.namedTypeName,()=>new Set))}else this.addSubgraphNameToExistingFieldNamedTypeDisparity(n);for(let l of n.argumentDataByName.values())this.upsertInputValueData(a.argumentDataByName,l,a.federatedCoords,o);(0,he.addNewObjectValueMapEntries)(n.configureDescriptionDataBySubgraphName,i.configureDescriptionDataBySubgraphName),(0,ge.setLongestDescription)(a,n),a.isInaccessible||(a.isInaccessible=n.isInaccessible),(0,he.addNewObjectValueMapEntries)(n.externalFieldDataBySubgraphName,a.externalFieldDataBySubgraphName),(0,he.addMapEntries)(n.isShareableBySubgraphName,a.isShareableBySubgraphName),(0,he.addIterableValuesToSet)(n.subgraphNames,a.subgraphNames)}getClientSchemaUnionMembers(t){let n=[];for(let[r,i]of t.memberByMemberTypeName)this.inaccessibleCoords.has(r)||n.push(i);return n}recordTagNamesByCoords(t,n){let r=n||t.name;if(t.persistedDirectivesData.tagDirectiveByName.size<1)return;let i=(0,he.getValueOrDefault)(this.tagNamesByCoords,r,()=>new Set);for(let a of t.persistedDirectivesData.tagDirectiveByName.keys())i.add(a)}copyMutualParentDefinitionData(t){return{configureDescriptionDataBySubgraphName:(0,he.copyObjectValueMap)(t.configureDescriptionDataBySubgraphName),directivesByDirectiveName:(0,he.copyArrayValueMap)(t.directivesByDirectiveName),extensionType:t.extensionType,name:t.name,persistedDirectivesData:(0,ge.extractPersistedDirectives)((0,ge.newPersistedDirectivesData)(),t.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),description:(0,ge.getInitialFederatedDescription)(t)}}copyEnumValueData(t){return{appearances:t.appearances,configureDescriptionDataBySubgraphName:(0,he.copyObjectValueMap)(t.configureDescriptionDataBySubgraphName),federatedCoords:t.federatedCoords,directivesByDirectiveName:(0,he.copyArrayValueMap)(t.directivesByDirectiveName),kind:t.kind,name:t.name,node:{directives:[],kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},parentTypeName:t.parentTypeName,persistedDirectivesData:(0,ge.extractPersistedDirectives)((0,ge.newPersistedDirectivesData)(),t.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),subgraphNames:new Set(t.subgraphNames),description:(0,ge.getInitialFederatedDescription)(t)}}copyInputValueData(t){return{configureDescriptionDataBySubgraphName:(0,he.copyObjectValueMap)(t.configureDescriptionDataBySubgraphName),directivesByDirectiveName:(0,he.copyArrayValueMap)(t.directivesByDirectiveName),federatedCoords:t.federatedCoords,fieldName:t.fieldName,includeDefaultValue:t.includeDefaultValue,isArgument:t.isArgument,kind:t.kind,name:t.name,namedTypeKind:t.namedTypeKind,namedTypeName:t.namedTypeName,node:{directives:[],kind:Re.Kind.INPUT_VALUE_DEFINITION,name:(0,kr.stringToNameNode)(t.name),type:t.type},originalCoords:t.originalCoords,originalParentTypeName:t.originalParentTypeName,persistedDirectivesData:(0,ge.extractPersistedDirectives)((0,ge.newPersistedDirectivesData)(),t.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),renamedParentTypeName:t.renamedParentTypeName,requiredSubgraphNames:new Set(t.requiredSubgraphNames),subgraphNames:new Set(t.subgraphNames),type:t.type,defaultValue:t.defaultValue,description:(0,ge.getInitialFederatedDescription)(t)}}copyInputValueDataByValueName(t,n,r){let i=new Map;for(let[a,o]of t){let c=this.copyInputValueData(o);this.handleInputValueInaccessibility(n,c,r),(0,he.getValueOrDefault)(this.coordsByNamedTypeName,c.namedTypeName,()=>new Set).add(c.federatedCoords),this.namedInputValueTypeNames.add(c.namedTypeName),this.recordTagNamesByCoords(c,`${r}.${o.name}`),i.set(a,c)}return i}copyFieldData(t,n){return{argumentDataByName:this.copyInputValueDataByValueName(t.argumentDataByName,n,t.federatedCoords),configureDescriptionDataBySubgraphName:(0,he.copyObjectValueMap)(t.configureDescriptionDataBySubgraphName),directivesByDirectiveName:(0,he.copyArrayValueMap)(t.directivesByDirectiveName),externalFieldDataBySubgraphName:(0,he.copyObjectValueMap)(t.externalFieldDataBySubgraphName),federatedCoords:t.federatedCoords,inheritedDirectiveNames:new Set,isInaccessible:t.isInaccessible,isShareableBySubgraphName:new Map(t.isShareableBySubgraphName),kind:t.kind,name:t.name,namedTypeKind:t.namedTypeKind,namedTypeName:t.namedTypeName,node:{arguments:[],directives:[],kind:t.kind,name:(0,kr.stringToNameNode)(t.name),type:t.type},originalParentTypeName:t.originalParentTypeName,persistedDirectivesData:(0,ge.extractPersistedDirectives)((0,ge.newPersistedDirectivesData)(),t.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),renamedParentTypeName:t.renamedParentTypeName,subgraphNames:new Set(t.subgraphNames),type:t.type,description:(0,ge.getInitialFederatedDescription)(t)}}copyEnumValueDataByValueName(t,n){let r=new Map;for(let[i,a]of t){let o=this.copyEnumValueData(a);this.recordTagNamesByCoords(o,o.federatedCoords),(n||(0,ge.isNodeDataInaccessible)(o))&&this.inaccessibleCoords.add(o.federatedCoords),r.set(i,o)}return r}copyFieldDataByName(t,n){let r=new Map;for(let[i,a]of t){let o=n||(0,ge.isNodeDataInaccessible)(a),c=this.copyFieldData(a,o);this.handleSubscriptionFilterDirective(c),(0,he.getValueOrDefault)(this.coordsByNamedTypeName,c.namedTypeName,()=>new Set).add(c.federatedCoords),this.namedOutputTypeNames.add(c.namedTypeName),this.recordTagNamesByCoords(c,c.federatedCoords),o&&this.inaccessibleCoords.add(c.federatedCoords),r.set(i,c)}return r}copyParentDefinitionData(t){let n=this.copyMutualParentDefinitionData(t);switch(t.kind){case Re.Kind.ENUM_TYPE_DEFINITION:return Y(x({},n),{appearances:t.appearances,enumValueDataByValueName:this.copyEnumValueDataByValueName(t.enumValueDataByValueName,t.isInaccessible),isInaccessible:t.isInaccessible,kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},subgraphNames:new Set(t.subgraphNames)});case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:return Y(x({},n),{inputValueDataByName:this.copyInputValueDataByValueName(t.inputValueDataByName,t.isInaccessible,t.name),isInaccessible:t.isInaccessible,kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},subgraphNames:new Set(t.subgraphNames)});case Re.Kind.INTERFACE_TYPE_DEFINITION:return Y(x({},n),{fieldDataByName:this.copyFieldDataByName(t.fieldDataByName,t.isInaccessible),implementedInterfaceTypeNames:new Set(t.implementedInterfaceTypeNames),isEntity:t.isEntity,isInaccessible:t.isInaccessible,kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},subgraphNames:new Set(t.subgraphNames)});case Re.Kind.OBJECT_TYPE_DEFINITION:return Y(x({},n),{fieldDataByName:this.copyFieldDataByName(t.fieldDataByName,t.isInaccessible),implementedInterfaceTypeNames:new Set(t.implementedInterfaceTypeNames),isEntity:t.isEntity,isInaccessible:t.isInaccessible,isRootType:t.isRootType,kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.renamedTypeName||t.name)},renamedTypeName:t.renamedTypeName,subgraphNames:new Set(t.subgraphNames)});case Re.Kind.SCALAR_TYPE_DEFINITION:return Y(x({},n),{kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},subgraphNames:new Set(t.subgraphNames)});case Re.Kind.UNION_TYPE_DEFINITION:return Y(x({},n),{kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},memberByMemberTypeName:new Map(t.memberByMemberTypeName),subgraphNames:new Set(t.subgraphNames)})}}getParentTargetData({existingData:t,incomingData:n}){if(!t){let r=this.copyParentDefinitionData(n);return(0,ge.isParentDataRootType)(r)&&(r.extensionType=eV.ExtensionType.NONE),r}return(0,ge.extractPersistedDirectives)(t.persistedDirectivesData,n.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),t}upsertParentDefinitionData(t,n){let r=this.entityInterfaceFederationDataByTypeName.get(t.name),i=this.parentDefinitionDataByTypeName.get(t.name),a=this.getParentTargetData({existingData:i,incomingData:t});this.recordTagNamesByCoords(a);let o=(0,ge.isNodeDataInaccessible)(a);if(o&&this.inaccessibleCoords.add(a.name),r&&r.interfaceObjectSubgraphs.has(n)&&(a.kind=Re.Kind.INTERFACE_TYPE_DEFINITION,a.node.kind=Re.Kind.INTERFACE_TYPE_DEFINITION),!i){this.parentDefinitionDataByTypeName.set(a.name,a);return}if(a.kind!==t.kind&&(!r||!r.interfaceObjectSubgraphs.has(n)||a.kind!==Re.Kind.INTERFACE_TYPE_DEFINITION||t.kind!==Re.Kind.OBJECT_TYPE_DEFINITION)){this.errors.push((0,we.incompatibleParentKindMergeError)(a.name,(0,he.kindToNodeType)(a.kind),(0,he.kindToNodeType)(t.kind)));return}switch((0,he.addNewObjectValueMapEntries)(t.configureDescriptionDataBySubgraphName,a.configureDescriptionDataBySubgraphName),(0,ge.setLongestDescription)(a,t),(0,ge.setParentDataExtensionType)(a,t),a.kind){case Re.Kind.ENUM_TYPE_DEFINITION:if(!(0,ge.areKindsEqual)(a,t))return;a.appearances+=1,a.isInaccessible||(a.isInaccessible=o),(0,he.addIterableValuesToSet)(t.subgraphNames,a.subgraphNames);for(let l of t.enumValueDataByValueName.values())this.upsertEnumValueData(a.enumValueDataByValueName,l,o);return;case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:if(!(0,ge.areKindsEqual)(a,t))return;o&&!a.isInaccessible&&this.propagateInaccessibilityToExistingChildren(a),a.isInaccessible||(a.isInaccessible=o),(0,he.addIterableValuesToSet)(t.subgraphNames,a.subgraphNames);for(let l of t.inputValueDataByName.values())this.upsertInputValueData(a.inputValueDataByName,l,a.name,a.isInaccessible);return;case Re.Kind.INTERFACE_TYPE_DEFINITION:case Re.Kind.OBJECT_TYPE_DEFINITION:let c=t;o&&!a.isInaccessible&&this.propagateInaccessibilityToExistingChildren(a),a.isInaccessible||(a.isInaccessible=o),(0,he.addIterableValuesToSet)(c.implementedInterfaceTypeNames,a.implementedInterfaceTypeNames),(0,he.addIterableValuesToSet)(c.subgraphNames,a.subgraphNames);for(let l of c.fieldDataByName.values())this.upsertFieldData(a.fieldDataByName,l,a.isInaccessible);return;case Re.Kind.UNION_TYPE_DEFINITION:if(!(0,ge.areKindsEqual)(a,t))return;(0,he.addMapEntries)(t.memberByMemberTypeName,a.memberByMemberTypeName),(0,he.addIterableValuesToSet)(t.subgraphNames,a.subgraphNames);return;default:(0,he.addIterableValuesToSet)(t.subgraphNames,a.subgraphNames);return}}propagateInaccessibilityToExistingChildren(t){switch(t.kind){case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:for(let n of t.inputValueDataByName.values())this.inaccessibleCoords.add(n.federatedCoords);break;default:for(let n of t.fieldDataByName.values()){this.inaccessibleCoords.add(n.federatedCoords);for(let r of n.argumentDataByName.values())this.inaccessibleCoords.add(r.federatedCoords)}}}upsertPersistedDirectiveDefinitionData(t,n){let r=t.name,i=this.potentialPersistedDirectiveDefinitionDataByDirectiveName.get(r);if(!i){if(n>1)return;let a=new Map;for(let o of t.argumentDataByArgumentName.values())this.namedInputValueTypeNames.add(o.namedTypeName),this.upsertInputValueData(a,o,`@${t.name}`,!1);this.potentialPersistedDirectiveDefinitionDataByDirectiveName.set(r,{argumentDataByArgumentName:a,executableLocations:new Set(t.executableLocations),name:r,repeatable:t.repeatable,subgraphNames:new Set(t.subgraphNames),description:t.description});return}if(i.subgraphNames.size+1!==n){this.potentialPersistedDirectiveDefinitionDataByDirectiveName.delete(r);return}if((0,ge.setMutualExecutableLocations)(i,t.executableLocations),i.executableLocations.size<1){this.potentialPersistedDirectiveDefinitionDataByDirectiveName.delete(r);return}for(let a of t.argumentDataByArgumentName.values())this.namedInputValueTypeNames.add((0,Xq.getTypeNodeNamedTypeName)(a.type)),this.upsertInputValueData(i.argumentDataByArgumentName,a,`@${i.name}`,!1);(0,ge.setLongestDescription)(i,t),i.repeatable&&(i.repeatable=t.repeatable),(0,he.addIterableValuesToSet)(t.subgraphNames,i.subgraphNames)}shouldUpdateFederatedFieldAbstractNamedType(t,n){if(!t)return!1;let r=this.concreteTypeNamesByAbstractTypeName.get(t);if(!r||r.size<1)return!1;for(let i of n)if(!r.has(i))return!1;return!0}updateTypeNodeNamedType(t,n){let r=t;for(let i=0;i1){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}break}case Re.Kind.UNION_TYPE_DEFINITION:{if(l){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}l=f;break}default:{this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));break}}}if(o.size<0&&!l){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}let p=l;if(o.size>0){if(l){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}for(let f of o.keys()){p=f;for(let[y,g]of o)if(f!==y&&!g.implementedInterfaceTypeNames.has(f)){p="";break}if(p)break}}if(!this.shouldUpdateFederatedFieldAbstractNamedType(p,c)){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}a.namedTypeName=p,this.updateTypeNodeNamedType(a.type,p)}}federateInternalSubgraphData(){let t=0,n=!1;for(let r of this.internalSubgraphBySubgraphName.values()){t+=1,this.currentSubgraphName=r.name,this.isVersionTwo||(this.isVersionTwo=r.isVersionTwo),(0,Ile.renameRootTypes)(this,r);for(let i of r.parentDefinitionDataByTypeName.values())this.upsertParentDefinitionData(i,r.name);if(!n){if(!r.persistedDirectiveDefinitionDataByDirectiveName.size){n=!0;continue}for(let i of r.persistedDirectiveDefinitionDataByDirectiveName.values())this.upsertPersistedDirectiveDefinitionData(i,t);this.potentialPersistedDirectiveDefinitionDataByDirectiveName.size<1&&(n=!0)}}this.handleDisparateFieldNamedTypes()}handleInterfaceObjectForInternalGraph({entityData:t,internalSubgraph:n,interfaceObjectData:r,interfaceObjectNode:i,resolvableKeyFieldSets:a,subgraphName:o}){let c=this.internalGraph.addOrUpdateNode(t.typeName),l=this.internalGraph.addEntityDataNode(t.typeName);for(let f of i.satisfiedFieldSets)c.satisfiedFieldSets.add(f),a.has(f)&&l.addTargetSubgraphByFieldSet(f,o);let p=r.fieldDatasBySubgraphName.get(o);for(let{name:f,namedTypeName:y}of p||[])this.internalGraph.addEdge(c,this.internalGraph.addOrUpdateNode(y),f);this.internalGraph.addEdge(i,c,t.typeName,!0),this.addValidPrimaryKeyTargetsFromInterfaceObject(n,i.typeName,t,c)}handleEntityInterfaces(){var t;for(let[n,r]of this.entityInterfaceFederationDataByTypeName){let i=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,n,Oe.PARENT_DEFINITION_DATA);if(i.kind===Re.Kind.INTERFACE_TYPE_DEFINITION)for(let a of r.interfaceObjectSubgraphs){let o=(0,he.getOrThrowError)(this.internalSubgraphBySubgraphName,a,"internalSubgraphBySubgraphName"),c=o.configurationDataByTypeName,l=this.concreteTypeNamesByAbstractTypeName.get(n);if(!l)continue;let p=(0,he.getOrThrowError)(c,n,"configurationDataByTypeName"),f=p.keys;if(!f)continue;p.entityInterfaceConcreteTypeNames=new Set(r.concreteTypeNames),this.internalGraph.setSubgraphName(a);let y=this.internalGraph.addOrUpdateNode(n,{isAbstract:!0});for(let g of l){let v=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,g,Oe.PARENT_DEFINITION_DATA);if(!(0,ti.isObjectDefinitionData)(v))continue;let P=(0,he.getOrThrowError)(this.entityDataByTypeName,g,"entityDataByTypeName");P.subgraphNames.add(a);let U=c.get(g);if(U)if((0,he.addIterableValuesToSet)(p.fieldNames,U.fieldNames),!U.keys)U.keys=[...f];else e:for(let z of f){for(let{selectionSet:Te}of U.keys)if(z.selectionSet===Te)continue e;U.keys.push(z)}else c.set(g,{fieldNames:new Set(p.fieldNames),isRootNode:!0,keys:[...f],typeName:g});let K=new Set;for(let z of f.filter(Te=>!Te.disableEntityResolver))K.add(z.selectionSet);let $=this.authorizationDataByParentTypeName.get(n),ne=(0,he.getOrThrowError)(o.parentDefinitionDataByTypeName,n,"internalSubgraph.parentDefinitionDataByTypeName");if((0,ti.isObjectDefinitionData)(ne)){for(let[z,Te]of ne.fieldDataByName){let pe=`${g}.${z}`;(0,he.getValueOrDefault)(this.fieldCoordsByNamedTypeName,Te.namedTypeName,()=>new Set).add(pe);let Fe=$==null?void 0:$.fieldAuthDataByFieldName.get(z);if(Fe){let X=(0,he.getValueOrDefault)(this.authorizationDataByParentTypeName,g,()=>(0,ti.newAuthorizationData)(g));(0,ti.upsertFieldAuthorizationData)(X.fieldAuthDataByFieldName,Fe)||this.invalidORScopesCoords.add(pe)}let xe=v.fieldDataByName.get(z);if(xe){let X=(t=Te.isShareableBySubgraphName.get(a))!=null?t:!1;xe.isShareableBySubgraphName.set(a,X),xe.subgraphNames.add(a);let ve=Te.externalFieldDataBySubgraphName.get(a);if(!ve)continue;xe.externalFieldDataBySubgraphName.set(a,ve);continue}let et=i.isInaccessible||v.isInaccessible||Te.isInaccessible;v.fieldDataByName.set(z,this.copyFieldData(Te,et))}this.handleInterfaceObjectForInternalGraph({internalSubgraph:o,subgraphName:a,interfaceObjectData:r,interfaceObjectNode:y,resolvableKeyFieldSets:K,entityData:P})}}}}}fieldDataToGraphFieldData(t){var n;return{name:t.name,namedTypeName:t.namedTypeName,isLeaf:(0,ti.isNodeLeaf)((n=this.parentDefinitionDataByTypeName.get(t.namedTypeName))==null?void 0:n.kind),subgraphNames:t.subgraphNames}}getValidFlattenedPersistedDirectiveNodeArray(t,n){let r=[];for(let[i,a]of t){let o=this.persistedDirectiveDefinitionByDirectiveName.get(i);if(o){if(a.length<2){r.push(...a);continue}if(!o.repeatable){this.errors.push((0,we.invalidRepeatedFederatedDirectiveErrorMessage)(i,n));continue}r.push(...a)}}return r}getRouterPersistedDirectiveNodes(t){let n=[...t.persistedDirectivesData.tagDirectiveByName.values()];return t.persistedDirectivesData.isDeprecated&&n.push((0,ge.generateDeprecatedDirective)(t.persistedDirectivesData.deprecatedReason)),n.push(...this.getValidFlattenedPersistedDirectiveNodeArray(t.persistedDirectivesData.directivesByDirectiveName,t.name)),n}getFederatedGraphNodeDescription(t){if(t.configureDescriptionDataBySubgraphName.size<1)return t.description;let n=[],r="";for(let[i,{propagate:a,description:o}]of t.configureDescriptionDataBySubgraphName)a&&(n.push(i),r=o);if(n.length===1)return(0,vc.getDescriptionFromString)(r);if(n.length<1)return t.description;this.errors.push((0,we.configureDescriptionPropagationError)((0,ge.getDefinitionDataCoords)(t,!0),n))}getNodeForRouterSchemaByData(t){return t.node.name=(0,kr.stringToNameNode)(t.name),t.node.description=this.getFederatedGraphNodeDescription(t),t.node.directives=this.getRouterPersistedDirectiveNodes(t),t.node}getNodeWithPersistedDirectivesByInputValueData(t){return t.node.name=(0,kr.stringToNameNode)(t.name),t.node.type=t.type,t.node.description=this.getFederatedGraphNodeDescription(t),t.node.directives=this.getRouterPersistedDirectiveNodes(t),t.includeDefaultValue&&(t.node.defaultValue=t.defaultValue),t.node}getValidFieldArgumentNodes(t){let n=[],r=[],i=[],a=`${t.renamedParentTypeName}.${t.name}`;for(let[o,c]of t.argumentDataByName)t.subgraphNames.size===c.subgraphNames.size?(r.push(o),n.push(this.getNodeWithPersistedDirectivesByInputValueData(c))):(0,ge.isTypeRequired)(c.type)&&i.push({inputValueName:o,missingSubgraphs:(0,he.getEntriesNotInHashSet)(t.subgraphNames,c.subgraphNames),requiredSubgraphs:[...c.requiredSubgraphNames]});return i.length>0?this.errors.push((0,we.invalidRequiredInputValueError)(Oe.FIELD,a,i)):r.length>0&&((0,he.getValueOrDefault)(this.fieldConfigurationByFieldCoords,a,()=>({argumentNames:r,fieldName:t.name,typeName:t.renamedParentTypeName})).argumentNames=r),n}getNodeWithPersistedDirectivesByFieldData(t,n){return t.node.arguments=n,t.node.name=(0,kr.stringToNameNode)(t.name),t.node.type=t.type,t.node.description=this.getFederatedGraphNodeDescription(t),t.node.directives=this.getRouterPersistedDirectiveNodes(t),t.node}pushParentDefinitionDataToDocumentDefinitions(t){for(let[n,r]of this.parentDefinitionDataByTypeName)switch(r.extensionType!==eV.ExtensionType.NONE&&this.errors.push((0,we.noBaseDefinitionForExtensionError)((0,he.kindToNodeType)(r.kind),n)),r.kind){case Re.Kind.ENUM_TYPE_DEFINITION:let i=[],a=[],o=this.getEnumValueMergeMethod(n);(0,ge.propagateAuthDirectives)(r,this.authorizationDataByParentTypeName.get(n));for(let ne of r.enumValueDataByValueName.values()){let z=(0,ge.getNodeForRouterSchemaByData)(ne,this.persistedDirectiveDefinitionByDirectiveName,this.errors),Te=(0,ge.isNodeDataInaccessible)(ne),pe=Y(x({},ne.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(ne)});switch(o){case ge.MergeMethod.CONSISTENT:!Te&&r.appearances>ne.appearances&&this.errors.push((0,we.incompatibleSharedEnumError)(n)),i.push(z),Te||a.push(pe);break;case ge.MergeMethod.INTERSECTION:r.appearances===ne.appearances&&(i.push(z),Te||a.push(pe));break;default:i.push(z),Te||a.push(pe);break}}if(r.node.values=i,this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r)),(0,ge.isNodeDataInaccessible)(r)){this.validateReferencesOfInaccessibleType(r),this.internalGraph.setNodeInaccessible(r.name);break}if(a.length<1){this.errors.push((0,we.allChildDefinitionsAreInaccessibleError)((0,he.kindToNodeType)(r.kind),n,Oe.ENUM_VALUE));break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r),values:a}));break;case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:let c=[],l=[],p=[];for(let[ne,z]of r.inputValueDataByName)if(r.subgraphNames.size===z.subgraphNames.size){if(l.push(this.getNodeWithPersistedDirectivesByInputValueData(z)),(0,ge.isNodeDataInaccessible)(z))continue;p.push(Y(x({},z.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(z)}))}else(0,ge.isTypeRequired)(z.type)&&c.push({inputValueName:ne,missingSubgraphs:(0,he.getEntriesNotInHashSet)(r.subgraphNames,z.subgraphNames),requiredSubgraphs:[...z.requiredSubgraphNames]});if(c.length>0){this.errors.push((0,we.invalidRequiredInputValueError)(Oe.INPUT_OBJECT,n,c,!1));break}if(r.node.fields=l,this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r)),(0,ge.isNodeDataInaccessible)(r)){this.validateReferencesOfInaccessibleType(r);break}if(p.length<1){this.errors.push((0,we.allChildDefinitionsAreInaccessibleError)((0,he.kindToNodeType)(r.kind),n,"input field"));break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r),fields:p}));break;case Re.Kind.INTERFACE_TYPE_DEFINITION:case Re.Kind.OBJECT_TYPE_DEFINITION:let f=[],y=[],g=new Map,v=(0,ge.newInvalidFieldNames)(),P=r.kind===Re.Kind.OBJECT_TYPE_DEFINITION,U=this.authorizationDataByParentTypeName.get(n);(0,ge.propagateAuthDirectives)(r,U);for(let[ne,z]of r.fieldDataByName){(0,ge.propagateFieldAuthDirectives)(z,U);let Te=this.getValidFieldArgumentNodes(z);P&&(0,ge.validateExternalAndShareable)(z,v),f.push(this.getNodeWithPersistedDirectivesByFieldData(z,Te)),!(0,ge.isNodeDataInaccessible)(z)&&(y.push((0,ge.getClientSchemaFieldNodeByFieldData)(z)),g.set(ne,this.fieldDataToGraphFieldData(z)))}if(P&&(v.byShareable.size>0&&this.errors.push((0,we.invalidFieldShareabilityError)(r,v.byShareable)),v.subgraphNamesByExternalFieldName.size>0&&this.errors.push((0,we.allExternalFieldInstancesError)(n,v.subgraphNamesByExternalFieldName))),r.node.fields=f,this.internalGraph.initializeNode(n,g),r.implementedInterfaceTypeNames.size>0){t.push({data:r,clientSchemaFieldNodes:y});break}this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r));let K=(0,yle.isNodeQuery)(n);if((0,ge.isNodeDataInaccessible)(r)){if(K){this.errors.push(we.inaccessibleQueryRootTypeError);break}this.validateReferencesOfInaccessibleType(r),this.internalGraph.setNodeInaccessible(r.name);break}if(y.length<1){let ne=K?(0,we.noQueryRootTypeError)(!1):(0,we.allChildDefinitionsAreInaccessibleError)((0,he.kindToNodeType)(r.kind),n,Oe.FIELD);this.errors.push(ne);break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r),fields:y}));break;case Re.Kind.SCALAR_TYPE_DEFINITION:if(jn.BASE_SCALARS.has(n))break;if((0,ge.propagateAuthDirectives)(r,this.authorizationDataByParentTypeName.get(n)),this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r)),(0,ge.isNodeDataInaccessible)(r)){this.validateReferencesOfInaccessibleType(r),this.internalGraph.setNodeInaccessible(r.name);break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r)}));break;case Re.Kind.UNION_TYPE_DEFINITION:if(r.node.types=(0,ti.mapToArrayOfValues)(r.memberByMemberTypeName),this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r)),(0,ge.isNodeDataInaccessible)(r)){this.validateReferencesOfInaccessibleType(r),this.internalGraph.setNodeInaccessible(r.name);break}let $=this.getClientSchemaUnionMembers(r);if($.length<1){this.errors.push((0,we.allChildDefinitionsAreInaccessibleError)(Oe.UNION,n,"union member type"));break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r),types:$}));break}}pushNamedTypeAuthDataToFields(){var t;for(let[n,r]of this.authorizationDataByParentTypeName){if(!r.requiresAuthentication&&r.requiredScopes.length<1)continue;let i=this.fieldCoordsByNamedTypeName.get(n);if(i)for(let a of i){let o=a.split(Oe.PERIOD);switch(o.length){case 2:{let c=(0,he.getValueOrDefault)(this.authorizationDataByParentTypeName,o[0],()=>(0,ti.newAuthorizationData)(o[0])),l=(0,he.getValueOrDefault)(c.fieldAuthDataByFieldName,o[1],()=>(0,ti.newFieldAuthorizationData)(o[1]));(t=l.inheritedData).requiresAuthentication||(t.requiresAuthentication=r.requiresAuthentication),l.inheritedData.requiredScopes.length*r.requiredScopes.length>jn.MAX_OR_SCOPES?this.invalidORScopesCoords.add(a):(l.inheritedData.requiredScopesByOR=(0,ti.mergeRequiredScopesByAND)(l.inheritedData.requiredScopesByOR,r.requiredScopesByOR),l.inheritedData.requiredScopes=(0,ti.mergeRequiredScopesByAND)(l.inheritedData.requiredScopes,r.requiredScopes));break}default:break}}}}federateSubgraphData(){this.federateInternalSubgraphData(),this.handleEntityInterfaces(),this.generateTagData(),this.pushVersionTwoDirectiveDefinitionsToDocumentDefinitions(),this.pushNamedTypeAuthDataToFields()}validateInterfaceImplementationsAndPushToDocumentDefinitions(t){for(let{data:n,clientSchemaFieldNodes:r}of t){if(n.node.interfaces=this.getValidImplementedInterfaces(n),this.routerDefinitions.push((0,ge.getNodeForRouterSchemaByData)(n,this.persistedDirectiveDefinitionByDirectiveName,this.errors)),(0,ge.isNodeDataInaccessible)(n)){this.validateReferencesOfInaccessibleType(n),this.internalGraph.setNodeInaccessible(n.name);continue}let i=[];for(let a of n.implementedInterfaceTypeNames)this.inaccessibleCoords.has(a)||i.push((0,kr.stringToNamedTypeNode)(a));this.clientDefinitions.push(Y(x({},n.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(n),fields:r,interfaces:i}))}}pushVersionTwoDirectiveDefinitionsToDocumentDefinitions(){this.isVersionTwo&&(this.routerDefinitions=[jn.AUTHENTICATED_DEFINITION,jn.DEPRECATED_DEFINITION,jn.INACCESSIBLE_DEFINITION,jn.REQUIRES_SCOPES_DEFINITION,jn.TAG_DEFINITION,jn.SCOPE_SCALAR_DEFINITION],this.clientDefinitions=[jn.DEPRECATED_DEFINITION])}validatePathSegmentInaccessibility(t){if(!t)return!1;let r=t.split(Oe.LEFT_PARENTHESIS)[0].split(Oe.PERIOD),i=r[0];for(let a=0;a0&&this.errors.push((0,we.invalidReferencesOfInaccessibleTypeError)((0,he.kindToNodeType)(t.kind),t.name,r))}validateQueryRootType(){let t=this.parentDefinitionDataByTypeName.get(Oe.QUERY);if(!t||t.kind!==Re.Kind.OBJECT_TYPE_DEFINITION||t.fieldDataByName.size<1){this.errors.push((0,we.noQueryRootTypeError)());return}for(let n of t.fieldDataByName.values())if(!(0,ge.isNodeDataInaccessible)(n))return;this.errors.push((0,we.noQueryRootTypeError)())}validateSubscriptionFieldConditionFieldPath(t,n,r,i,a){let o=t.split(Oe.PERIOD);if(o.length<1)return a.push((0,we.invalidSubscriptionFieldConditionFieldPathErrorMessage)(r,t)),[];let c=n;if(this.inaccessibleCoords.has(c.renamedTypeName))return a.push((0,we.inaccessibleSubscriptionFieldConditionFieldPathFieldErrorMessage)(r,t,o[0],c.renamedTypeName)),[];let l="";for(let p=0;p0?`.${f}`:f,c.kind!==Re.Kind.OBJECT_TYPE_DEFINITION)return a.push((0,we.invalidSubscriptionFieldConditionFieldPathParentErrorMessage)(r,t,l)),[];let y=c.fieldDataByName.get(f);if(!y)return a.push((0,we.undefinedSubscriptionFieldConditionFieldPathFieldErrorMessage)(r,t,l,f,c.renamedTypeName)),[];let g=`${c.renamedTypeName}.${f}`;if(!y.subgraphNames.has(i))return a.push((0,we.invalidSubscriptionFieldConditionFieldPathFieldErrorMessage)(r,t,l,g,i)),[];if(this.inaccessibleCoords.has(g))return a.push((0,we.inaccessibleSubscriptionFieldConditionFieldPathFieldErrorMessage)(r,t,l,g)),[];if(jn.BASE_SCALARS.has(y.namedTypeName)){c={kind:Re.Kind.SCALAR_TYPE_DEFINITION,name:y.namedTypeName};continue}c=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,y.namedTypeName,Oe.PARENT_DEFINITION_DATA)}return(0,ge.isLeafKind)(c.kind)?o:(a.push((0,we.nonLeafSubscriptionFieldConditionFieldPathFinalFieldErrorMessage)(r,t,o[o.length-1],(0,he.kindToNodeType)(c.kind),c.name)),[])}validateSubscriptionFieldCondition(t,n,r,i,a,o,c){if(i>FE.MAX_SUBSCRIPTION_FILTER_DEPTH||this.isMaxDepth)return c.push((0,we.subscriptionFilterConditionDepthExceededErrorMessage)(a)),this.isMaxDepth=!0,!1;let l=!1,p=new Set([Oe.FIELD_PATH,Oe.VALUES]),f=new Set,y=new Set,g=[];for(let v of t.fields){let P=v.name.value,U=a+`.${P}`;switch(P){case Oe.FIELD_PATH:{if(p.has(Oe.FIELD_PATH))p.delete(Oe.FIELD_PATH);else{l=!0,f.add(Oe.FIELD_PATH);break}if(v.value.kind!==Re.Kind.STRING){g.push((0,we.invalidInputFieldTypeErrorMessage)(U,Oe.STRING,(0,he.kindToNodeType)(v.value.kind))),l=!0;break}let K=this.validateSubscriptionFieldConditionFieldPath(v.value.value,r,U,o,g);if(K.length<1){l=!0;break}n.fieldPath=K;break}case Oe.VALUES:{if(p.has(Oe.VALUES))p.delete(Oe.VALUES);else{l=!0,f.add(Oe.VALUES);break}let K=v.value.kind;if(K==Re.Kind.NULL||K==Re.Kind.OBJECT){g.push((0,we.invalidInputFieldTypeErrorMessage)(U,Oe.LIST,(0,he.kindToNodeType)(v.value.kind))),l=!0;break}if(K!==Re.Kind.LIST){n.values=[(0,ge.getSubscriptionFilterValue)(v.value)];break}let $=new Set,ne=[];for(let z=0;z0){g.push((0,we.subscriptionFieldConditionInvalidValuesArrayErrorMessage)(U,ne));continue}if($.size<1){l=!0,g.push((0,we.subscriptionFieldConditionEmptyValuesArrayErrorMessage)(U));continue}n.values=[...$];break}default:l=!0,y.add(P)}}return l?(c.push((0,we.subscriptionFieldConditionInvalidInputFieldErrorMessage)(a,[...p],[...f],[...y],g)),!1):!0}validateSubscriptionFilterCondition(t,n,r,i,a,o,c){if(i>FE.MAX_SUBSCRIPTION_FILTER_DEPTH||this.isMaxDepth)return c.push((0,we.subscriptionFilterConditionDepthExceededErrorMessage)(a)),this.isMaxDepth=!0,!1;if(i+=1,t.fields.length!==1)return c.push((0,we.subscriptionFilterConditionInvalidInputFieldNumberErrorMessage)(a,t.fields.length)),!1;let l=t.fields[0],p=l.name.value;if(!Zq.SUBSCRIPTION_FILTER_INPUT_NAMES.has(p))return c.push((0,we.subscriptionFilterConditionInvalidInputFieldErrorMessage)(a,p)),!1;let f=a+`.${p}`;switch(l.value.kind){case Re.Kind.OBJECT:switch(p){case Oe.IN_UPPER:return n.in={fieldPath:[],values:[]},this.validateSubscriptionFieldCondition(l.value,n.in,r,i,a+".IN",o,c);case Oe.NOT_UPPER:return n.not={},this.validateSubscriptionFilterCondition(l.value,n.not,r,i,a+".NOT",o,c);default:return c.push((0,we.subscriptionFilterConditionInvalidInputFieldTypeErrorMessage)(f,Oe.LIST,Oe.OBJECT)),!1}case Re.Kind.LIST:{let y=[];switch(p){case Oe.AND_UPPER:{n.and=y;break}case Oe.OR_UPPER:{n.or=y;break}default:return c.push((0,we.subscriptionFilterConditionInvalidInputFieldTypeErrorMessage)(f,Oe.OBJECT,Oe.LIST)),!1}let g=l.value.values.length;if(g<1||g>5)return c.push((0,we.subscriptionFilterArrayConditionInvalidLengthErrorMessage)(f,g)),!1;let v=!0,P=[];for(let U=0;U0?(c.push((0,we.subscriptionFilterArrayConditionInvalidItemTypeErrorMessage)(f,P)),!1):v}default:{let y=Zq.SUBSCRIPTION_FILTER_LIST_INPUT_NAMES.has(p)?Oe.LIST:Oe.OBJECT;return c.push((0,we.subscriptionFilterConditionInvalidInputFieldTypeErrorMessage)(f,y,(0,he.kindToNodeType)(l.value.kind))),!1}}}validateSubscriptionFilterAndGenerateConfiguration(t,n,r,i,a,o){if(!t.arguments||t.arguments.length!==1)return;let c=t.arguments[0];if(c.value.kind!==Re.Kind.OBJECT){this.errors.push((0,we.invalidSubscriptionFilterDirectiveError)(r,[(0,we.subscriptionFilterConditionInvalidInputFieldTypeErrorMessage)(Oe.CONDITION,Oe.OBJECT,(0,he.kindToNodeType)(c.value.kind))]));return}let l={},p=[];if(!this.validateSubscriptionFilterCondition(c.value,l,n,0,Oe.CONDITION,o,p)){this.errors.push((0,we.invalidSubscriptionFilterDirectiveError)(r,p)),this.isMaxDepth=!1;return}(0,he.getValueOrDefault)(this.fieldConfigurationByFieldCoords,r,()=>({argumentNames:[],fieldName:i,typeName:a})).subscriptionFilterCondition=l}validateSubscriptionFiltersAndGenerateConfiguration(){for(let[t,n]of this.subscriptionFilterDataByFieldPath){if(this.inaccessibleCoords.has(t))continue;let r=this.parentDefinitionDataByTypeName.get(n.fieldData.namedTypeName);if(!r){this.errors.push((0,we.invalidSubscriptionFilterDirectiveError)(t,[(0,we.subscriptionFilterNamedTypeErrorMessage)(n.fieldData.namedTypeName)]));continue}(0,ge.isNodeDataInaccessible)(r)||r.kind===Re.Kind.OBJECT_TYPE_DEFINITION&&this.validateSubscriptionFilterAndGenerateConfiguration(n.directive,r,t,n.fieldData.name,n.fieldData.renamedParentTypeName,n.directiveSubgraphName)}}buildFederationResult(){this.subscriptionFilterDataByFieldPath.size>0&&this.validateSubscriptionFiltersAndGenerateConfiguration(),this.invalidORScopesCoords.size>0&&this.errors.push((0,we.orScopesLimitError)(jn.MAX_OR_SCOPES,[...this.invalidORScopesCoords]));for(let a of this.potentialPersistedDirectiveDefinitionDataByDirectiveName.values())(0,ge.addValidPersistedDirectiveDefinitionNodeByData)(this.routerDefinitions,a,this.persistedDirectiveDefinitionByDirectiveName,this.errors);let t=[];this.pushParentDefinitionDataToDocumentDefinitions(t),this.validateInterfaceImplementationsAndPushToDocumentDefinitions(t),this.validateQueryRootType();for(let a of this.inaccessibleRequiredInputValueErrorByCoords.values())this.errors.push(a);if(this.errors.length>0)return{errors:this.errors,success:!1,warnings:this.warnings};if(!this.disableResolvabilityValidation&&this.internalSubgraphBySubgraphName.size>1){let a=this.internalGraph.validate();if(a.length>0)return{errors:a,success:!1,warnings:this.warnings}}let n={kind:Re.Kind.DOCUMENT,definitions:this.routerDefinitions},r=(0,Re.buildASTSchema)({kind:Re.Kind.DOCUMENT,definitions:this.clientDefinitions},{assumeValid:!0,assumeValidSDL:!0}),i=new Map;for(let a of this.internalSubgraphBySubgraphName.values())i.set(a.name,{configurationDataByTypeName:a.configurationDataByTypeName,isVersionTwo:a.isVersionTwo,parentDefinitionDataByTypeName:a.parentDefinitionDataByTypeName,schema:a.schema});for(let a of this.authorizationDataByParentTypeName.values())(0,ti.upsertAuthorizationConfiguration)(this.fieldConfigurationByFieldCoords,a);return x({fieldConfigurations:Array.from(this.fieldConfigurationByFieldCoords.values()),subgraphConfigBySubgraphName:i,federatedGraphAST:n,federatedGraphSchema:(0,Re.buildASTSchema)(n,{assumeValid:!0,assumeValidSDL:!0}),federatedGraphClientSchema:r,parentDefinitionDataByTypeName:this.parentDefinitionDataByTypeName,success:!0,warnings:this.warnings},this.getClientSchemaObjectBoolean())}getClientSchemaObjectBoolean(){return this.inaccessibleCoords.size<1&&this.tagNamesByCoords.size<1?{}:{shouldIncludeClientSchema:!0}}handleChildTagExclusions(t,n,r,i){let a=n.size;for(let[o,c]of r){let l=(0,he.getOrThrowError)(n,o,`${t.name}.childDataByChildName`);if((0,ge.isNodeDataInaccessible)(l)){a-=1;continue}i.isDisjointFrom(c.tagNames)||((0,he.getValueOrDefault)(l.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(`${t.name}.${o}`),a-=1)}a<1&&(t.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(t.name))}handleChildTagInclusions(t,n,r,i){let a=n.size;for(let[o,c]of n){if((0,ge.isNodeDataInaccessible)(c)){a-=1;continue}let l=r.get(o);(!l||i.isDisjointFrom(l.tagNames))&&((0,he.getValueOrDefault)(c.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(`${t.name}.${o}`),a-=1)}a<1&&(t.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(t.name))}buildFederationContractResult(t){if(this.isVersionTwo||this.routerDefinitions.push(jn.INACCESSIBLE_DEFINITION),t.tagNamesToExclude.size>0)for(let[o,c]of this.parentTagDataByTypeName){let l=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,o,Oe.PARENT_DEFINITION_DATA);if(!(0,ge.isNodeDataInaccessible)(l)){if(!t.tagNamesToExclude.isDisjointFrom(c.tagNames)){l.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o);continue}if(!(c.childTagDataByChildName.size<1))switch(l.kind){case Re.Kind.SCALAR_TYPE_DEFINITION:case Re.Kind.UNION_TYPE_DEFINITION:continue;case Re.Kind.ENUM_TYPE_DEFINITION:this.handleChildTagExclusions(l,l.enumValueDataByValueName,c.childTagDataByChildName,t.tagNamesToExclude);break;case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:this.handleChildTagExclusions(l,l.inputValueDataByName,c.childTagDataByChildName,t.tagNamesToExclude);break;default:let p=l.fieldDataByName.size;for(let[f,y]of c.childTagDataByChildName){let g=(0,he.getOrThrowError)(l.fieldDataByName,f,`${o}.fieldDataByFieldName`);if((0,ge.isNodeDataInaccessible)(g)){p-=1;continue}if(!t.tagNamesToExclude.isDisjointFrom(y.tagNames)){(0,he.getValueOrDefault)(g.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(g.federatedCoords),p-=1;continue}for(let[v,P]of y.tagNamesByArgumentName){let U=(0,he.getOrThrowError)(g.argumentDataByName,v,`${f}.argumentDataByArgumentName`);(0,ge.isNodeDataInaccessible)(U)||P.isDisjointFrom(P)||((0,he.getValueOrDefault)(U.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(U.federatedCoords))}}p<1&&(l.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o))}}}else if(t.tagNamesToInclude.size>0)for(let[o,c]of this.parentDefinitionDataByTypeName){if((0,ge.isNodeDataInaccessible)(c))continue;let l=this.parentTagDataByTypeName.get(o);if(!l){c.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o);continue}if(t.tagNamesToInclude.isDisjointFrom(l.tagNames)){if(l.childTagDataByChildName.size<1){c.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o);continue}switch(c.kind){case Re.Kind.SCALAR_TYPE_DEFINITION:case Re.Kind.UNION_TYPE_DEFINITION:continue;case Re.Kind.ENUM_TYPE_DEFINITION:this.handleChildTagInclusions(c,c.enumValueDataByValueName,l.childTagDataByChildName,t.tagNamesToInclude);break;case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:this.handleChildTagInclusions(c,c.inputValueDataByName,l.childTagDataByChildName,t.tagNamesToInclude);break;default:let p=c.fieldDataByName.size;for(let[f,y]of c.fieldDataByName){if((0,ge.isNodeDataInaccessible)(y)){p-=1;continue}let g=l.childTagDataByChildName.get(f);(!g||t.tagNamesToInclude.isDisjointFrom(g.tagNames))&&((0,he.getValueOrDefault)(y.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(y.federatedCoords),p-=1)}p<1&&(c.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o))}}}this.subscriptionFilterDataByFieldPath.size>0&&this.validateSubscriptionFiltersAndGenerateConfiguration();for(let o of this.potentialPersistedDirectiveDefinitionDataByDirectiveName.values())(0,ge.addValidPersistedDirectiveDefinitionNodeByData)(this.routerDefinitions,o,this.persistedDirectiveDefinitionByDirectiveName,this.errors);let n=[];if(this.pushParentDefinitionDataToDocumentDefinitions(n),this.validateInterfaceImplementationsAndPushToDocumentDefinitions(n),this.validateQueryRootType(),this.errors.length>0)return{errors:this.errors,success:!1,warnings:this.warnings};let r={kind:Re.Kind.DOCUMENT,definitions:this.routerDefinitions},i=(0,Re.buildASTSchema)({kind:Re.Kind.DOCUMENT,definitions:this.clientDefinitions},{assumeValid:!0,assumeValidSDL:!0}),a=new Map;for(let o of this.internalSubgraphBySubgraphName.values())a.set(o.name,{configurationDataByTypeName:o.configurationDataByTypeName,isVersionTwo:o.isVersionTwo,parentDefinitionDataByTypeName:o.parentDefinitionDataByTypeName,schema:o.schema});for(let o of this.authorizationDataByParentTypeName.values())(0,ti.upsertAuthorizationConfiguration)(this.fieldConfigurationByFieldCoords,o);return x({fieldConfigurations:Array.from(this.fieldConfigurationByFieldCoords.values()),subgraphConfigBySubgraphName:a,federatedGraphAST:r,federatedGraphSchema:(0,Re.buildASTSchema)(r,{assumeValid:!0,assumeValidSDL:!0}),federatedGraphClientSchema:i,parentDefinitionDataByTypeName:this.parentDefinitionDataByTypeName,success:!0,warnings:this.warnings},this.getClientSchemaObjectBoolean())}federateSubgraphsInternal(){return this.federateSubgraphData(),this.buildFederationResult()}};Sc.FederationFactory=wE;function tD({disableResolvabilityValidation:e,subgraphs:t}){if(t.length<1)return{errors:[we.minimumSubgraphRequirementError],success:!1,warnings:[]};let n=(0,hle.batchNormalize)(t);if(!n.success)return{errors:n.errors,success:!1,warnings:n.warnings};let r=new Map,i=new Map;for(let[c,l]of n.internalSubgraphBySubgraphName)for(let[p,f]of l.entityInterfaces){let y=r.get(p);if(!y){r.set(p,(0,ti.newEntityInterfaceFederationData)(f,c));continue}(0,ti.upsertEntityInterfaceFederationData)(y,f,c)}let a=new Array,o=new Map;for(let[c,l]of r){let p=l.concreteTypeNames.size;for(let[f,y]of l.subgraphDataByTypeName){let g=(0,he.getValueOrDefault)(o,f,()=>new Set);if((0,he.addIterableValuesToSet)(y.concreteTypeNames,g),!y.isInterfaceObject){y.resolvable&&y.concreteTypeNames.size!==p&&(0,he.getValueOrDefault)(i,c,()=>new Array).push({subgraphName:f,definedConcreteTypeNames:new Set(y.concreteTypeNames),requiredConcreteTypeNames:new Set(l.concreteTypeNames)});continue}(0,he.addIterableValuesToSet)(l.concreteTypeNames,g);let{parentDefinitionDataByTypeName:v}=(0,he.getOrThrowError)(n.internalSubgraphBySubgraphName,f,"internalSubgraphBySubgraphName"),P=[];for(let U of l.concreteTypeNames)v.has(U)&&P.push(U);P.length>0&&a.push((0,we.invalidInterfaceObjectImplementationDefinitionsError)(c,f,P))}}for(let[c,l]of i){let p=new Array;for(let f of l){let y=o.get(f.subgraphName);if(!y){p.push(f);continue}let g=f.requiredConcreteTypeNames.intersection(y);f.requiredConcreteTypeNames.size!==g.size&&(f.definedConcreteTypeNames=g,p.push(f))}if(p.length>0){i.set(c,p);continue}i.delete(c)}return i.size>0&&a.push((0,we.undefinedEntityInterfaceImplementationsError)(i,r)),a.length>0?{errors:a,success:!1,warnings:n.warnings}:{federationFactory:new wE({authorizationDataByParentTypeName:n.authorizationDataByParentTypeName,concreteTypeNamesByAbstractTypeName:n.concreteTypeNamesByAbstractTypeName,disableResolvabilityValidation:e,entityDataByTypeName:n.entityDataByTypeName,entityInterfaceFederationDataByTypeName:r,fieldCoordsByNamedTypeName:n.fieldCoordsByNamedTypeName,internalSubgraphBySubgraphName:n.internalSubgraphBySubgraphName,internalGraph:n.internalGraph,warnings:n.warnings}),success:!0,warnings:n.warnings}}function gle({disableResolvabilityValidation:e,subgraphs:t}){let n=tD({subgraphs:t,disableResolvabilityValidation:e});return n.success?n.federationFactory.federateSubgraphsInternal():{errors:n.errors,success:!1,warnings:n.warnings}}function _le({subgraphs:e,tagOptionsByContractName:t,disableResolvabilityValidation:n}){let r=tD({subgraphs:e,disableResolvabilityValidation:n});if(!r.success)return{errors:r.errors,success:!1,warnings:r.warnings};r.federationFactory.federateSubgraphData();let i=[(0,tV.cloneDeep)(r.federationFactory)],a=r.federationFactory.buildFederationResult();if(!a.success)return{errors:a.errors,success:!1,warnings:a.warnings};let o=t.size-1,c=new Map,l=0;for(let[p,f]of t){l!==o&&i.push((0,tV.cloneDeep)(i[l]));let y=i[l].buildFederationContractResult(f);c.set(p,y),l++}return Y(x({},a),{federationResultByContractName:c})}function vle({contractTagOptions:e,disableResolvabilityValidation:t,subgraphs:n}){let r=tD({subgraphs:n,disableResolvabilityValidation:t});return r.success?(r.federationFactory.federateSubgraphData(),r.federationFactory.buildFederationContractResult(e)):{errors:r.errors,success:!1,warnings:r.warnings}}});var LE=w(Ss=>{"use strict";m();T();N();Object.defineProperty(Ss,"__esModule",{value:!0});Ss.LATEST_ROUTER_COMPATIBILITY_VERSION=Ss.ROUTER_COMPATIBILITY_VERSIONS=Ss.ROUTER_COMPATIBILITY_VERSION_ONE=void 0;Ss.ROUTER_COMPATIBILITY_VERSION_ONE="1";Ss.ROUTER_COMPATIBILITY_VERSIONS=new Set([Ss.ROUTER_COMPATIBILITY_VERSION_ONE]);Ss.LATEST_ROUTER_COMPATIBILITY_VERSION="1"});var rV=w(Hp=>{"use strict";m();T();N();Object.defineProperty(Hp,"__esModule",{value:!0});Hp.federateSubgraphs=Sle;Hp.federateSubgraphsWithContracts=Ole;Hp.federateSubgraphsContract=Dle;var nD=nV(),rD=LE();function Sle({disableResolvabilityValidation:e,subgraphs:t,version:n=rD.ROUTER_COMPATIBILITY_VERSION_ONE}){switch(n){default:return(0,nD.federateSubgraphs)({disableResolvabilityValidation:e,subgraphs:t})}}function Ole({disableResolvabilityValidation:e,subgraphs:t,tagOptionsByContractName:n,version:r=rD.ROUTER_COMPATIBILITY_VERSION_ONE}){switch(r){default:return(0,nD.federateSubgraphsWithContracts)({disableResolvabilityValidation:e,subgraphs:t,tagOptionsByContractName:n})}}function Dle({contractTagOptions:e,disableResolvabilityValidation:t,subgraphs:n,version:r=rD.ROUTER_COMPATIBILITY_VERSION_ONE}){switch(r){default:return(0,nD.federateSubgraphsContract)({disableResolvabilityValidation:t,subgraphs:n,contractTagOptions:e})}}});var aV=w(iV=>{"use strict";m();T();N();Object.defineProperty(iV,"__esModule",{value:!0})});var sV=w(zp=>{"use strict";m();T();N();Object.defineProperty(zp,"__esModule",{value:!0});zp.normalizeSubgraphFromString=ble;zp.normalizeSubgraph=Ale;zp.batchNormalize=Rle;var iD=WO(),aD=LE();function ble(e,t=!0,n=aD.ROUTER_COMPATIBILITY_VERSION_ONE){switch(n){default:return(0,iD.normalizeSubgraphFromString)(e,t)}}function Ale(e,t,n,r=aD.ROUTER_COMPATIBILITY_VERSION_ONE){switch(r){default:return(0,iD.normalizeSubgraph)(e,t,n)}}function Rle(e,t=aD.ROUTER_COMPATIBILITY_VERSION_ONE){switch(t){default:return(0,iD.batchNormalize)(e)}}});var uV=w(oV=>{"use strict";m();T();N();Object.defineProperty(oV,"__esModule",{value:!0})});var lV=w(cV=>{"use strict";m();T();N();Object.defineProperty(cV,"__esModule",{value:!0})});var pV=w(dV=>{"use strict";m();T();N();Object.defineProperty(dV,"__esModule",{value:!0})});var mV=w(fV=>{"use strict";m();T();N();Object.defineProperty(fV,"__esModule",{value:!0})});var NV=w(CE=>{"use strict";m();T();N();Object.defineProperty(CE,"__esModule",{value:!0});CE.COMPOSITION_VERSION=void 0;CE.COMPOSITION_VERSION="{{$COMPOSITION__VERSION}}"});var EV=w(TV=>{"use strict";m();T();N();Object.defineProperty(TV,"__esModule",{value:!0})});var yV=w(hV=>{"use strict";m();T();N();Object.defineProperty(hV,"__esModule",{value:!0})});var gV=w(IV=>{"use strict";m();T();N();Object.defineProperty(IV,"__esModule",{value:!0})});var BE=w(pt=>{"use strict";m();T();N();var Ple=pt&&pt.__createBinding||(Object.create?function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]}),St=pt&&pt.__exportStar||function(e,t){for(var n in e)n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n)&&Ple(t,e,n)};Object.defineProperty(pt,"__esModule",{value:!0});St(Yr(),pt);St(dv(),pt);St(ia(),pt);St(Pk(),pt);St(rV(),pt);St(aV(),pt);St(sV(),pt);St(uV(),pt);St(JO(),pt);St(KO(),pt);St($O(),pt);St(LE(),pt);St(lV(),pt);St(HO(),pt);St(ou(),pt);St(hp(),pt);St(hl(),pt);St(pV(),pt);St(mV(),pt);St(NV(),pt);St(ur(),pt);St(EV(),pt);St(Jr(),pt);St(BO(),pt);St(BN(),pt);St(eD(),pt);St(yV(),pt);St(PO(),pt);St(Gp(),pt);St(gV(),pt);St(MO(),pt);St(RE(),pt);St(LO(),pt);St(Es(),pt);St(Kp(),pt);St(kp(),pt);St(gE(),pt)});var vde={};sm(vde,{buildRouterConfiguration:()=>_de,federateSubgraphs:()=>gde});m();T();N();var Fc=ss(BE());m();T();N();m();T();N();function sD(e){if(!e)return e;if(!URL.canParse(e))throw new Error("Invalid URL");let t=e.indexOf("?"),n=e.indexOf("#"),r=e;return t>0?r=r.slice(0,n>0?Math.min(t,n):t):n>0&&(r=r.slice(0,n)),r}m();T();N();m();T();N();var _V={};m();T();N();function vV(e){return e!=null}m();T();N();m();T();N();var AV=ss(Ae(),1);m();T();N();var SV;if(typeof AggregateError=="undefined"){class e extends Error{constructor(n,r=""){super(r),this.errors=n,this.name="AggregateError",Error.captureStackTrace(this,e)}}SV=function(t,n){return new e(t,n)}}else SV=AggregateError;function OV(e){return"errors"in e&&Array.isArray(e.errors)}var RV=3;function PV(e){return UE(e,[])}function UE(e,t){switch(typeof e){case"string":return JSON.stringify(e);case"function":return e.name?`[function ${e.name}]`:"[function]";case"object":return Fle(e,t);default:return String(e)}}function DV(e){return e instanceof AV.GraphQLError?e.toString():`${e.name}: ${e.message}; ${e.stack}`}function Fle(e,t){if(e===null)return"null";if(e instanceof Error)return OV(e)?DV(e)+` `+bV(e.errors,t):DV(e);if(t.includes(e))return"[Circular]";let n=[...t,e];if(wle(e)){let r=e.toJSON();if(r!==e)return typeof r=="string"?r:UE(r,n)}else if(Array.isArray(e))return bV(e,n);return Lle(e,n)}function wle(e){return typeof e.toJSON=="function"}function Lle(e,t){let n=Object.entries(e);return n.length===0?"{}":t.length>RV?"["+Cle(e)+"]":"{ "+n.map(([i,a])=>i+": "+UE(a,t)).join(", ")+" }"}function bV(e,t){if(e.length===0)return"[]";if(t.length>RV)return"[Array]";let n=e.length,r=[];for(let i=0;in==null?n:n[r],e==null?void 0:e.extensions)}m();T();N();var Pe=ss(Ae(),1);m();T();N();var $a=ss(Ae(),1);function Qa(e){if((0,$a.isNonNullType)(e)){let t=Qa(e.ofType);if(t.kind===$a.Kind.NON_NULL_TYPE)throw new Error(`Invalid type node ${PV(e)}. Inner type of non-null type cannot be a non-null type.`);return{kind:$a.Kind.NON_NULL_TYPE,type:t}}else if((0,$a.isListType)(e))return{kind:$a.Kind.LIST_TYPE,type:Qa(e.ofType)};return{kind:$a.Kind.NAMED_TYPE,name:{kind:$a.Kind.NAME,value:e.name}}}m();T();N();var Ya=ss(Ae(),1);function ME(e){if(e===null)return{kind:Ya.Kind.NULL};if(e===void 0)return null;if(Array.isArray(e)){let t=[];for(let n of e){let r=ME(n);r!=null&&t.push(r)}return{kind:Ya.Kind.LIST,values:t}}if(typeof e=="object"){let t=[];for(let n in e){let r=e[n],i=ME(r);i&&t.push({kind:Ya.Kind.OBJECT_FIELD,name:{kind:Ya.Kind.NAME,value:n},value:i})}return{kind:Ya.Kind.OBJECT,fields:t}}if(typeof e=="boolean")return{kind:Ya.Kind.BOOLEAN,value:e};if(typeof e=="number"&&isFinite(e)){let t=String(e);return Ble.test(t)?{kind:Ya.Kind.INT,value:t}:{kind:Ya.Kind.FLOAT,value:t}}if(typeof e=="string")return{kind:Ya.Kind.STRING,value:e};throw new TypeError(`Cannot convert value to AST: ${e}.`)}var Ble=/^-?(?:0|[1-9][0-9]*)$/;m();T();N();m();T();N();function xE(e){let t=new WeakMap;return function(r){let i=t.get(r);if(i===void 0){let a=e(r);return t.set(r,a),a}return i}}var tke=xE(function(t){let n=Ule(t);return new Set([...n].map(r=>r.name))}),Ule=xE(function(t){let n=oD(t);return new Set(n.values())}),oD=xE(function(t){let n=new Map,r=t.getQueryType();r&&n.set("query",r);let i=t.getMutationType();i&&n.set("mutation",i);let a=t.getSubscriptionType();return a&&n.set("subscription",a),n});function kle(e,t={}){let n=t.pathToDirectivesInExtensions,r=e.getTypeMap(),i=Mle(e,n),a=i!=null?[i]:[],o=e.getDirectives();for(let c of o)(0,Pe.isSpecifiedDirective)(c)||a.push(xle(c,e,n));for(let c in r){let l=r[c],p=(0,Pe.isSpecifiedScalarType)(l),f=(0,Pe.isIntrospectionType)(l);if(!(p||f))if((0,Pe.isObjectType)(l))a.push(qle(l,e,n));else if((0,Pe.isInterfaceType)(l))a.push(Vle(l,e,n));else if((0,Pe.isUnionType)(l))a.push(jle(l,e,n));else if((0,Pe.isInputObjectType)(l))a.push(Kle(l,e,n));else if((0,Pe.isEnumType)(l))a.push(Gle(l,e,n));else if((0,Pe.isScalarType)(l))a.push($le(l,e,n));else throw new Error(`Unknown type ${l}.`)}return{kind:Pe.Kind.DOCUMENT,definitions:a}}function FV(e,t={}){let n=kle(e,t);return(0,Pe.print)(n)}function Mle(e,t){var n,r;let i=new Map([["query",void 0],["mutation",void 0],["subscription",void 0]]),a=[];if(e.astNode!=null&&a.push(e.astNode),e.extensionASTNodes!=null)for(let f of e.extensionASTNodes)a.push(f);for(let f of a)if(f.operationTypes)for(let y of f.operationTypes)i.set(y.operation,y);let o=oD(e);for(let[f,y]of i){let g=o.get(f);if(g!=null){let v=Qa(g);y!=null?y.type=v:i.set(f,{kind:Pe.Kind.OPERATION_TYPE_DEFINITION,operation:f,type:v})}}let c=[...i.values()].filter(vV),l=Hl(e,e,t);if(!c.length&&!l.length)return null;let p={kind:c!=null?Pe.Kind.SCHEMA_DEFINITION:Pe.Kind.SCHEMA_EXTENSION,operationTypes:c,directives:l};return p.description=((r=(n=e.astNode)===null||n===void 0?void 0:n.description)!==null&&r!==void 0?r:e.description!=null)?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,p}function xle(e,t,n){var r,i,a,o;return{kind:Pe.Kind.DIRECTIVE_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},arguments:(a=e.args)===null||a===void 0?void 0:a.map(c=>wV(c,t,n)),repeatable:e.isRepeatable,locations:((o=e.locations)===null||o===void 0?void 0:o.map(c=>({kind:Pe.Kind.NAME,value:c})))||[]}}function Hl(e,t,n){let r=kE(e,n),i=[];e.astNode!=null&&i.push(e.astNode),"extensionASTNodes"in e&&e.extensionASTNodes!=null&&(i=i.concat(e.extensionASTNodes));let a;if(r!=null)a=uD(t,r);else{a=[];for(let o of i)o.directives&&a.push(...o.directives)}return a}function VE(e,t,n){var r,i;let a=[],o=null,c=kE(e,n),l;return c!=null?l=uD(t,c):l=(r=e.astNode)===null||r===void 0?void 0:r.directives,l!=null&&(a=l.filter(p=>p.name.value!=="deprecated"),e.deprecationReason!=null&&(o=(i=l.filter(p=>p.name.value==="deprecated"))===null||i===void 0?void 0:i[0])),e.deprecationReason!=null&&o==null&&(o=Jle(e.deprecationReason)),o==null?a:[o].concat(a)}function wV(e,t,n){var r,i,a;return{kind:Pe.Kind.INPUT_VALUE_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},type:Qa(e.type),defaultValue:e.defaultValue!==void 0&&(a=(0,Pe.astFromValue)(e.defaultValue,e.type))!==null&&a!==void 0?a:void 0,directives:VE(e,t,n)}}function qle(e,t,n){var r,i;return{kind:Pe.Kind.OBJECT_TYPE_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},fields:Object.values(e.getFields()).map(a=>LV(a,t,n)),interfaces:Object.values(e.getInterfaces()).map(a=>Qa(a)),directives:Hl(e,t,n)}}function Vle(e,t,n){var r,i;let a={kind:Pe.Kind.INTERFACE_TYPE_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},fields:Object.values(e.getFields()).map(o=>LV(o,t,n)),directives:Hl(e,t,n)};return"getInterfaces"in e&&(a.interfaces=Object.values(e.getInterfaces()).map(o=>Qa(o))),a}function jle(e,t,n){var r,i;return{kind:Pe.Kind.UNION_TYPE_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},directives:Hl(e,t,n),types:e.getTypes().map(a=>Qa(a))}}function Kle(e,t,n){var r,i;return{kind:Pe.Kind.INPUT_OBJECT_TYPE_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},fields:Object.values(e.getFields()).map(a=>Qle(a,t,n)),directives:Hl(e,t,n)}}function Gle(e,t,n){var r,i;return{kind:Pe.Kind.ENUM_TYPE_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},values:Object.values(e.getValues()).map(a=>Yle(a,t,n)),directives:Hl(e,t,n)}}function $le(e,t,n){var r,i,a;let o=kE(e,n),c=o?uD(t,o):((r=e.astNode)===null||r===void 0?void 0:r.directives)||[],l=e.specifiedByUrl||e.specifiedByURL;if(l&&!c.some(p=>p.name.value==="specifiedBy")){let p={url:l};c.push(qE("specifiedBy",p))}return{kind:Pe.Kind.SCALAR_TYPE_DEFINITION,description:(a=(i=e.astNode)===null||i===void 0?void 0:i.description)!==null&&a!==void 0?a:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},directives:c}}function LV(e,t,n){var r,i;return{kind:Pe.Kind.FIELD_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},arguments:e.args.map(a=>wV(a,t,n)),type:Qa(e.type),directives:VE(e,t,n)}}function Qle(e,t,n){var r,i,a;return{kind:Pe.Kind.INPUT_VALUE_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},type:Qa(e.type),directives:VE(e,t,n),defaultValue:(a=(0,Pe.astFromValue)(e.defaultValue,e.type))!==null&&a!==void 0?a:void 0}}function Yle(e,t,n){var r,i;return{kind:Pe.Kind.ENUM_VALUE_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},directives:VE(e,t,n)}}function Jle(e){return qE("deprecated",{reason:e},Pe.GraphQLDeprecatedDirective)}function qE(e,t,n){let r=[];if(n!=null)for(let i of n.args){let a=i.name,o=t[a];if(o!==void 0){let c=(0,Pe.astFromValue)(o,i.type);c&&r.push({kind:Pe.Kind.ARGUMENT,name:{kind:Pe.Kind.NAME,value:a},value:c})}}else for(let i in t){let a=t[i],o=ME(a);o&&r.push({kind:Pe.Kind.ARGUMENT,name:{kind:Pe.Kind.NAME,value:i},value:o})}return{kind:Pe.Kind.DIRECTIVE,name:{kind:Pe.Kind.NAME,value:e},arguments:r}}function uD(e,t){let n=[];for(let r in t){let i=t[r],a=e==null?void 0:e.getDirective(r);if(Array.isArray(i))for(let o of i)n.push(qE(r,o,a));else n.push(qE(r,i,a))}return n}var id=ss(BE(),1);m();T();N();m();T();N();m();T();N();m();T();N();m();T();N();m();T();N();function sn(e,t){if(!e)throw new Error(t)}var Hle=34028234663852886e22,zle=-34028234663852886e22,Wle=4294967295,Xle=2147483647,Zle=-2147483648;function zl(e){if(typeof e!="number")throw new Error("invalid int 32: "+typeof e);if(!Number.isInteger(e)||e>Xle||eWle||e<0)throw new Error("invalid uint 32: "+e)}function jE(e){if(typeof e!="number")throw new Error("invalid float 32: "+typeof e);if(Number.isFinite(e)&&(e>Hle||e({no:i.no,name:i.name,localName:e[i.no]})),r)}function lD(e,t,n){let r=Object.create(null),i=Object.create(null),a=[];for(let o of t){let c=kV(o);a.push(c),r[o.name]=c,i[o.no]=c}return{typeName:e,values:a,findName(o){return r[o]},findNumber(o){return i[o]}}}function UV(e,t,n){let r={};for(let i of t){let a=kV(i);r[a.localName]=a.no,r[a.no]=a.localName}return cD(r,e,t,n),r}function kV(e){return"localName"in e?e:Object.assign(Object.assign({},e),{localName:e.name})}m();T();N();m();T();N();var Le=class{equals(t){return this.getType().runtime.util.equals(this.getType(),this,t)}clone(){return this.getType().runtime.util.clone(this)}fromBinary(t,n){let r=this.getType(),i=r.runtime.bin,a=i.makeReadOptions(n);return i.readMessage(this,a.readerFactory(t),t.byteLength,a),this}fromJson(t,n){let r=this.getType(),i=r.runtime.json,a=i.makeReadOptions(n);return i.readMessage(r,t,a,this),this}fromJsonString(t,n){let r;try{r=JSON.parse(t)}catch(i){throw new Error(`cannot decode ${this.getType().typeName} from JSON: ${i instanceof Error?i.message:String(i)}`)}return this.fromJson(r,n)}toBinary(t){let n=this.getType(),r=n.runtime.bin,i=r.makeWriteOptions(t),a=i.writerFactory();return r.writeMessage(this,a,i),a.finish()}toJson(t){let n=this.getType(),r=n.runtime.json,i=r.makeWriteOptions(t);return r.writeMessage(this,i)}toJsonString(t){var n;let r=this.toJson(t);return JSON.stringify(r,null,(n=t==null?void 0:t.prettySpaces)!==null&&n!==void 0?n:0)}toJSON(){return this.toJson({emitDefaultValues:!0})}getType(){return Object.getPrototypeOf(this).constructor}};function MV(e,t,n,r){var i;let a=(i=r==null?void 0:r.localName)!==null&&i!==void 0?i:t.substring(t.lastIndexOf(".")+1),o={[a]:function(c){e.util.initFields(this),e.util.initPartial(c,this)}}[a];return Object.setPrototypeOf(o.prototype,new Le),Object.assign(o,{runtime:e,typeName:t,fields:e.util.newFieldList(n),fromBinary(c,l){return new o().fromBinary(c,l)},fromJson(c,l){return new o().fromJson(c,l)},fromJsonString(c,l){return new o().fromJsonString(c,l)},equals(c,l){return e.util.equals(o,c,l)}}),o}m();T();N();m();T();N();m();T();N();m();T();N();function qV(){let e=0,t=0;for(let r=0;r<28;r+=7){let i=this.buf[this.pos++];if(e|=(i&127)<>4,!(n&128))return this.assertBounds(),[e,t];for(let r=3;r<=31;r+=7){let i=this.buf[this.pos++];if(t|=(i&127)<>>a,c=!(!(o>>>7)&&t==0),l=(c?o|128:o)&255;if(n.push(l),!c)return}let r=e>>>28&15|(t&7)<<4,i=!!(t>>3);if(n.push((i?r|128:r)&255),!!i){for(let a=3;a<31;a=a+7){let o=t>>>a,c=!!(o>>>7),l=(c?o|128:o)&255;if(n.push(l),!c)return}n.push(t>>>31&1)}}var KE=4294967296;function dD(e){let t=e[0]==="-";t&&(e=e.slice(1));let n=1e6,r=0,i=0;function a(o,c){let l=Number(e.slice(o,c));i*=n,r=r*n+l,r>=KE&&(i=i+(r/KE|0),r=r%KE)}return a(-24,-18),a(-18,-12),a(-12,-6),a(-6),t?jV(r,i):fD(r,i)}function VV(e,t){let n=fD(e,t),r=n.hi&2147483648;r&&(n=jV(n.lo,n.hi));let i=pD(n.lo,n.hi);return r?"-"+i:i}function pD(e,t){if({lo:e,hi:t}=ede(e,t),t<=2097151)return String(KE*t+e);let n=e&16777215,r=(e>>>24|t<<8)&16777215,i=t>>16&65535,a=n+r*6777216+i*6710656,o=r+i*8147497,c=i*2,l=1e7;return a>=l&&(o+=Math.floor(a/l),a%=l),o>=l&&(c+=Math.floor(o/l),o%=l),c.toString()+xV(o)+xV(a)}function ede(e,t){return{lo:e>>>0,hi:t>>>0}}function fD(e,t){return{lo:e|0,hi:t|0}}function jV(e,t){return t=~t,e?e=~e+1:t+=1,fD(e,t)}var xV=e=>{let t=String(e);return"0000000".slice(t.length)+t};function mD(e,t){if(e>=0){for(;e>127;)t.push(e&127|128),e=e>>>7;t.push(e)}else{for(let n=0;n<9;n++)t.push(e&127|128),e=e>>7;t.push(1)}}function KV(){let e=this.buf[this.pos++],t=e&127;if(!(e&128))return this.assertBounds(),t;if(e=this.buf[this.pos++],t|=(e&127)<<7,!(e&128))return this.assertBounds(),t;if(e=this.buf[this.pos++],t|=(e&127)<<14,!(e&128))return this.assertBounds(),t;if(e=this.buf[this.pos++],t|=(e&127)<<21,!(e&128))return this.assertBounds(),t;e=this.buf[this.pos++],t|=(e&15)<<28;for(let n=5;e&128&&n<10;n++)e=this.buf[this.pos++];if(e&128)throw new Error("invalid varint");return this.assertBounds(),t>>>0}function tde(){let 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"&&(typeof O!="object"||typeof O.env!="object"||O.env.BUF_BIGINT_DISABLE!=="1")){let i=BigInt("-9223372036854775808"),a=BigInt("9223372036854775807"),o=BigInt("0"),c=BigInt("18446744073709551615");return{zero:BigInt(0),supported:!0,parse(l){let p=typeof l=="bigint"?l:BigInt(l);if(p>a||pc||psn(/^-?[0-9]+$/.test(i),`int64 invalid: ${i}`),r=i=>sn(/^[0-9]+$/.test(i),`uint64 invalid: ${i}`);return{zero:"0",supported:!1,parse(i){return typeof i!="string"&&(i=i.toString()),n(i),i},uParse(i){return typeof i!="string"&&(i=i.toString()),r(i),i},enc(i){return typeof i!="string"&&(i=i.toString()),n(i),dD(i)},uEnc(i){return typeof i!="string"&&(i=i.toString()),r(i),dD(i)},dec(i,a){return VV(i,a)},uDec(i,a){return pD(i,a)}}}var Kn=tde();m();T();N();var Ne;(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"})(Ne||(Ne={}));var Na;(function(e){e[e.BIGINT=0]="BIGINT",e[e.STRING=1]="STRING"})(Na||(Na={}));function Os(e,t,n){if(t===n)return!0;if(e==Ne.BYTES){if(!(t instanceof Uint8Array)||!(n instanceof Uint8Array)||t.length!==n.length)return!1;for(let r=0;r>>0)}raw(t){return this.buf.length&&(this.chunks.push(new Uint8Array(this.buf)),this.buf=[]),this.chunks.push(t),this}uint32(t){for(Wp(t);t>127;)this.buf.push(t&127|128),t=t>>>7;return this.buf.push(t),this}int32(t){return zl(t),mD(t,this.buf),this}bool(t){return this.buf.push(t?1:0),this}bytes(t){return this.uint32(t.byteLength),this.raw(t)}string(t){let n=this.textEncoder.encode(t);return this.uint32(n.byteLength),this.raw(n)}float(t){jE(t);let n=new Uint8Array(4);return new DataView(n.buffer).setFloat32(0,t,!0),this.raw(n)}double(t){let n=new Uint8Array(8);return new DataView(n.buffer).setFloat64(0,t,!0),this.raw(n)}fixed32(t){Wp(t);let n=new Uint8Array(4);return new DataView(n.buffer).setUint32(0,t,!0),this.raw(n)}sfixed32(t){zl(t);let n=new Uint8Array(4);return new DataView(n.buffer).setInt32(0,t,!0),this.raw(n)}sint32(t){return zl(t),t=(t<<1^t>>31)>>>0,mD(t,this.buf),this}sfixed64(t){let n=new Uint8Array(8),r=new DataView(n.buffer),i=Kn.enc(t);return r.setInt32(0,i.lo,!0),r.setInt32(4,i.hi,!0),this.raw(n)}fixed64(t){let n=new Uint8Array(8),r=new DataView(n.buffer),i=Kn.uEnc(t);return r.setInt32(0,i.lo,!0),r.setInt32(4,i.hi,!0),this.raw(n)}int64(t){let n=Kn.enc(t);return GE(n.lo,n.hi,this.buf),this}sint64(t){let n=Kn.enc(t),r=n.hi>>31,i=n.lo<<1^r,a=(n.hi<<1|n.lo>>>31)^r;return GE(i,a,this.buf),this}uint64(t){let n=Kn.uEnc(t);return GE(n.lo,n.hi,this.buf),this}},YE=class{constructor(t,n){this.varint64=qV,this.uint32=KV,this.buf=t,this.len=t.length,this.pos=0,this.view=new DataView(t.buffer,t.byteOffset,t.byteLength),this.textDecoder=n!=null?n:new TextDecoder}tag(){let t=this.uint32(),n=t>>>3,r=t&7;if(n<=0||r<0||r>5)throw new Error("illegal tag: field no "+n+" wire type "+r);return[n,r]}skip(t){let n=this.pos;switch(t){case Bn.Varint:for(;this.buf[this.pos++]&128;);break;case Bn.Bit64:this.pos+=4;case Bn.Bit32:this.pos+=4;break;case Bn.LengthDelimited:let r=this.uint32();this.pos+=r;break;case Bn.StartGroup:let i;for(;(i=this.tag()[1])!==Bn.EndGroup;)this.skip(i);break;default:throw new Error("cant skip wire type "+t)}return this.assertBounds(),this.buf.subarray(n,this.pos)}assertBounds(){if(this.pos>this.len)throw new RangeError("premature EOF")}int32(){return this.uint32()|0}sint32(){let t=this.uint32();return t>>>1^-(t&1)}int64(){return Kn.dec(...this.varint64())}uint64(){return Kn.uDec(...this.varint64())}sint64(){let[t,n]=this.varint64(),r=-(t&1);return t=(t>>>1|(n&1)<<31)^r,n=n>>>1^r,Kn.dec(t,n)}bool(){let[t,n]=this.varint64();return t!==0||n!==0}fixed32(){return this.view.getUint32((this.pos+=4)-4,!0)}sfixed32(){return this.view.getInt32((this.pos+=4)-4,!0)}fixed64(){return Kn.uDec(this.sfixed32(),this.sfixed32())}sfixed64(){return Kn.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 t=this.uint32(),n=this.pos;return this.pos+=t,this.assertBounds(),this.buf.subarray(n,n+t)}string(){return this.textDecoder.decode(this.bytes())}};function GV(e,t,n,r){let i;return{typeName:t,extendee:n,get field(){if(!i){let a=typeof r=="function"?r():r;a.name=t.split(".").pop(),a.jsonName=`[${t}]`,i=e.util.newFieldList([a]).list()[0]}return i},runtime:e}}function JE(e){let t=e.field.localName,n=Object.create(null);return n[t]=nde(e),[n,()=>n[t]]}function nde(e){let t=e.field;if(t.repeated)return[];if(t.default!==void 0)return t.default;switch(t.kind){case"enum":return t.T.values[0].no;case"scalar":return Ta(t.T,t.L);case"message":let n=t.T,r=new n;return n.fieldWrapper?n.fieldWrapper.unwrapField(r):r;case"map":throw"map fields are not allowed to be extensions"}}function $V(e,t){if(!t.repeated&&(t.kind=="enum"||t.kind=="scalar")){for(let n=e.length-1;n>=0;--n)if(e[n].no==t.no)return[e[n]];return[]}return e.filter(n=>n.no===t.no)}m();T();N();m();T();N();var Ds="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split(""),HE=[];for(let e=0;e>4,o=a,i=2;break;case 2:n[r++]=(o&15)<<4|(a&60)>>2,o=a,i=3;break;case 3:n[r++]=(o&3)<<6|a,i=0;break}}if(i==1)throw Error("invalid base64 string.");return n.subarray(0,r)},enc(e){let t="",n=0,r,i=0;for(let a=0;a>2],i=(r&3)<<4,n=1;break;case 1:t+=Ds[i|r>>4],i=(r&15)<<2,n=2;break;case 2:t+=Ds[i|r>>6],t+=Ds[r&63],n=0;break}return n&&(t+=Ds[i],t+="=",n==1&&(t+="=")),t}};m();T();N();function QV(e,t,n){JV(t,e);let r=t.runtime.bin.makeReadOptions(n),i=$V(e.getType().runtime.bin.listUnknownFields(e),t.field),[a,o]=JE(t);for(let c of i)t.runtime.bin.readField(a,r.readerFactory(c.data),t.field,c.wireType,r);return o()}function YV(e,t,n,r){JV(t,e);let i=t.runtime.bin.makeReadOptions(r),a=t.runtime.bin.makeWriteOptions(r);if(TD(e,t)){let p=e.getType().runtime.bin.listUnknownFields(e).filter(f=>f.no!=t.field.no);e.getType().runtime.bin.discardUnknownFields(e);for(let f of p)e.getType().runtime.bin.onUnknownField(e,f.no,f.wireType,f.data)}let o=a.writerFactory(),c=t.field;!c.opt&&!c.repeated&&(c.kind=="enum"||c.kind=="scalar")&&(c=Object.assign(Object.assign({},t.field),{opt:!0})),t.runtime.bin.writeField(c,n,o,a);let l=i.readerFactory(o.finish());for(;l.posr.no==t.field.no)}function JV(e,t){sn(e.extendee.typeName==t.getType().typeName,`extension ${e.typeName} can only be applied to message ${e.extendee.typeName}`)}m();T();N();function zE(e,t){let n=e.localName;if(e.repeated)return t[n].length>0;if(e.oneof)return t[e.oneof.localName].case===n;switch(e.kind){case"enum":case"scalar":return e.opt||e.req?t[n]!==void 0:e.kind=="enum"?t[n]!==e.T.values[0].no:!$E(e.T,t[n]);case"message":return t[n]!==void 0;case"map":return Object.keys(t[n]).length>0}}function ED(e,t){let n=e.localName,r=!e.opt&&!e.req;if(e.repeated)t[n]=[];else if(e.oneof)t[e.oneof.localName]={case:void 0};else switch(e.kind){case"map":t[n]={};break;case"enum":t[n]=r?e.T.values[0].no:void 0;break;case"scalar":t[n]=r?Ta(e.T,e.L):void 0;break;case"message":t[n]=void 0;break}}m();T();N();m();T();N();function Ea(e,t){if(e===null||typeof e!="object"||!Object.getOwnPropertyNames(Le.prototype).every(r=>r in e&&typeof e[r]=="function"))return!1;let n=e.getType();return n===null||typeof n!="function"||!("typeName"in n)||typeof n.typeName!="string"?!1:t===void 0?!0:n.typeName==t.typeName}function WE(e,t){return Ea(t)||!e.fieldWrapper?t:e.fieldWrapper.wrapField(t)}var CMe={"google.protobuf.DoubleValue":Ne.DOUBLE,"google.protobuf.FloatValue":Ne.FLOAT,"google.protobuf.Int64Value":Ne.INT64,"google.protobuf.UInt64Value":Ne.UINT64,"google.protobuf.Int32Value":Ne.INT32,"google.protobuf.UInt32Value":Ne.UINT32,"google.protobuf.BoolValue":Ne.BOOL,"google.protobuf.StringValue":Ne.STRING,"google.protobuf.BytesValue":Ne.BYTES};var HV={ignoreUnknownFields:!1},zV={emitDefaultValues:!1,enumAsInteger:!1,useProtoFieldName:!1,prettySpaces:0};function rde(e){return e?Object.assign(Object.assign({},HV),e):HV}function ide(e){return e?Object.assign(Object.assign({},zV),e):zV}var eh=Symbol(),XE=Symbol();function ZV(){return{makeReadOptions:rde,makeWriteOptions:ide,readMessage(e,t,n,r){if(t==null||Array.isArray(t)||typeof t!="object")throw new Error(`cannot decode message ${e.typeName} from JSON: ${Ja(t)}`);r=r!=null?r:new e;let i=new Map,a=n.typeRegistry;for(let[o,c]of Object.entries(t)){let l=e.fields.findJsonName(o);if(l){if(l.oneof){if(c===null&&l.kind=="scalar")continue;let p=i.get(l.oneof);if(p!==void 0)throw new Error(`cannot decode message ${e.typeName} from JSON: multiple keys for oneof "${l.oneof.name}" present: "${p}", "${o}"`);i.set(l.oneof,o)}WV(r,c,l,n,e)}else{let p=!1;if(a!=null&&a.findExtension&&o.startsWith("[")&&o.endsWith("]")){let f=a.findExtension(o.substring(1,o.length-1));if(f&&f.extendee.typeName==e.typeName){p=!0;let[y,g]=JE(f);WV(y,c,f.field,n,f),YV(r,f,g(),n)}}if(!p&&!n.ignoreUnknownFields)throw new Error(`cannot decode message ${e.typeName} from JSON: key "${o}" is unknown`)}}return r},writeMessage(e,t){let n=e.getType(),r={},i;try{for(i of n.fields.byNumber()){if(!zE(i,e)){if(i.req)throw"required field not set";if(!t.emitDefaultValues||!sde(i))continue}let o=i.oneof?e[i.oneof.localName].value:e[i.localName],c=XV(i,o,t);c!==void 0&&(r[t.useProtoFieldName?i.name:i.jsonName]=c)}let a=t.typeRegistry;if(a!=null&&a.findExtensionFor)for(let o of n.runtime.bin.listUnknownFields(e)){let c=a.findExtensionFor(n.typeName,o.no);if(c&&TD(e,c)){let l=QV(e,c,t),p=XV(c.field,l,t);p!==void 0&&(r[c.field.jsonName]=p)}}}catch(a){let o=i?`cannot encode field ${n.typeName}.${i.name} to JSON`:`cannot encode message ${n.typeName} to JSON`,c=a instanceof Error?a.message:String(a);throw new Error(o+(c.length>0?`: ${c}`:""))}return r},readScalar(e,t,n){return Xp(e,t,n!=null?n:Na.BIGINT,!0)},writeScalar(e,t,n){if(t!==void 0&&(n||$E(e,t)))return ZE(e,t)},debug:Ja}}function Ja(e){if(e===null)return"null";switch(typeof e){case"object":return Array.isArray(e)?"array":"object";case"string":return e.length>100?"string":`"${e.split('"').join('\\"')}"`;default:return String(e)}}function WV(e,t,n,r,i){let a=n.localName;if(n.repeated){if(sn(n.kind!="map"),t===null)return;if(!Array.isArray(t))throw new Error(`cannot decode field ${i.typeName}.${n.name} from JSON: ${Ja(t)}`);let o=e[a];for(let c of t){if(c===null)throw new Error(`cannot decode field ${i.typeName}.${n.name} from JSON: ${Ja(c)}`);switch(n.kind){case"message":o.push(n.T.fromJson(c,r));break;case"enum":let l=hD(n.T,c,r.ignoreUnknownFields,!0);l!==XE&&o.push(l);break;case"scalar":try{o.push(Xp(n.T,c,n.L,!0))}catch(p){let f=`cannot decode field ${i.typeName}.${n.name} from JSON: ${Ja(c)}`;throw p instanceof Error&&p.message.length>0&&(f+=`: ${p.message}`),new Error(f)}break}}}else if(n.kind=="map"){if(t===null)return;if(typeof t!="object"||Array.isArray(t))throw new Error(`cannot decode field ${i.typeName}.${n.name} from JSON: ${Ja(t)}`);let o=e[a];for(let[c,l]of Object.entries(t)){if(l===null)throw new Error(`cannot decode field ${i.typeName}.${n.name} from JSON: map value null`);let p;try{p=ade(n.K,c)}catch(f){let y=`cannot decode map key for field ${i.typeName}.${n.name} from JSON: ${Ja(t)}`;throw f instanceof Error&&f.message.length>0&&(y+=`: ${f.message}`),new Error(y)}switch(n.V.kind){case"message":o[p]=n.V.T.fromJson(l,r);break;case"enum":let f=hD(n.V.T,l,r.ignoreUnknownFields,!0);f!==XE&&(o[p]=f);break;case"scalar":try{o[p]=Xp(n.V.T,l,Na.BIGINT,!0)}catch(y){let g=`cannot decode map value for field ${i.typeName}.${n.name} from JSON: ${Ja(t)}`;throw y instanceof Error&&y.message.length>0&&(g+=`: ${y.message}`),new Error(g)}break}}}else switch(n.oneof&&(e=e[n.oneof.localName]={case:a},a="value"),n.kind){case"message":let o=n.T;if(t===null&&o.typeName!="google.protobuf.Value")return;let c=e[a];Ea(c)?c.fromJson(t,r):(e[a]=c=o.fromJson(t,r),o.fieldWrapper&&!n.oneof&&(e[a]=o.fieldWrapper.unwrapField(c)));break;case"enum":let l=hD(n.T,t,r.ignoreUnknownFields,!1);switch(l){case eh:ED(n,e);break;case XE:break;default:e[a]=l;break}break;case"scalar":try{let p=Xp(n.T,t,n.L,!1);switch(p){case eh:ED(n,e);break;default:e[a]=p;break}}catch(p){let f=`cannot decode field ${i.typeName}.${n.name} from JSON: ${Ja(t)}`;throw p instanceof Error&&p.message.length>0&&(f+=`: ${p.message}`),new Error(f)}break}}function ade(e,t){if(e===Ne.BOOL)switch(t){case"true":t=!0;break;case"false":t=!1;break}return Xp(e,t,Na.BIGINT,!0).toString()}function Xp(e,t,n,r){if(t===null)return r?Ta(e,n):eh;switch(e){case Ne.DOUBLE:case Ne.FLOAT:if(t==="NaN")return Number.NaN;if(t==="Infinity")return Number.POSITIVE_INFINITY;if(t==="-Infinity")return Number.NEGATIVE_INFINITY;if(t===""||typeof t=="string"&&t.trim().length!==t.length||typeof t!="string"&&typeof t!="number")break;let i=Number(t);if(Number.isNaN(i)||!Number.isFinite(i))break;return e==Ne.FLOAT&&jE(i),i;case Ne.INT32:case Ne.FIXED32:case Ne.SFIXED32:case Ne.SINT32:case Ne.UINT32:let a;if(typeof t=="number"?a=t:typeof t=="string"&&t.length>0&&t.trim().length===t.length&&(a=Number(t)),a===void 0)break;return e==Ne.UINT32||e==Ne.FIXED32?Wp(a):zl(a),a;case Ne.INT64:case Ne.SFIXED64:case Ne.SINT64:if(typeof t!="number"&&typeof t!="string")break;let o=Kn.parse(t);return n?o.toString():o;case Ne.FIXED64:case Ne.UINT64:if(typeof t!="number"&&typeof t!="string")break;let c=Kn.uParse(t);return n?c.toString():c;case Ne.BOOL:if(typeof t!="boolean")break;return t;case Ne.STRING:if(typeof t!="string")break;try{encodeURIComponent(t)}catch(l){throw new Error("invalid UTF8")}return t;case Ne.BYTES:if(t==="")return new Uint8Array(0);if(typeof t!="string")break;return ND.dec(t)}throw new Error}function hD(e,t,n,r){if(t===null)return e.typeName=="google.protobuf.NullValue"?0:r?e.values[0].no:eh;switch(typeof t){case"number":if(Number.isInteger(t))return t;break;case"string":let i=e.findName(t);if(i!==void 0)return i.no;if(n)return XE;break}throw new Error(`cannot decode enum ${e.typeName} from JSON: ${Ja(t)}`)}function sde(e){return e.repeated||e.kind=="map"?!0:!(e.oneof||e.kind=="message"||e.opt||e.req)}function XV(e,t,n){if(e.kind=="map"){sn(typeof t=="object"&&t!=null);let r={},i=Object.entries(t);switch(e.V.kind){case"scalar":for(let[o,c]of i)r[o.toString()]=ZE(e.V.T,c);break;case"message":for(let[o,c]of i)r[o.toString()]=c.toJson(n);break;case"enum":let a=e.V.T;for(let[o,c]of i)r[o.toString()]=yD(a,c,n.enumAsInteger);break}return n.emitDefaultValues||i.length>0?r:void 0}if(e.repeated){sn(Array.isArray(t));let r=[];switch(e.kind){case"scalar":for(let i=0;i0?r:void 0}switch(e.kind){case"scalar":return ZE(e.T,t);case"enum":return yD(e.T,t,n.enumAsInteger);case"message":return WE(e.T,t).toJson(n)}}function yD(e,t,n){var r;if(sn(typeof t=="number"),e.typeName=="google.protobuf.NullValue")return null;if(n)return t;let i=e.findNumber(t);return(r=i==null?void 0:i.name)!==null&&r!==void 0?r:t}function ZE(e,t){switch(e){case Ne.INT32:case Ne.SFIXED32:case Ne.SINT32:case Ne.FIXED32:case Ne.UINT32:return sn(typeof t=="number"),t;case Ne.FLOAT:case Ne.DOUBLE:return sn(typeof t=="number"),Number.isNaN(t)?"NaN":t===Number.POSITIVE_INFINITY?"Infinity":t===Number.NEGATIVE_INFINITY?"-Infinity":t;case Ne.STRING:return sn(typeof t=="string"),t;case Ne.BOOL:return sn(typeof t=="boolean"),t;case Ne.UINT64:case Ne.FIXED64:case Ne.INT64:case Ne.SFIXED64:case Ne.SINT64:return sn(typeof t=="bigint"||typeof t=="string"||typeof t=="number"),t.toString();case Ne.BYTES:return sn(t instanceof Uint8Array),ND.enc(t)}}m();T();N();var Wl=Symbol("@bufbuild/protobuf/unknown-fields"),e1={readUnknownFields:!0,readerFactory:e=>new YE(e)},t1={writeUnknownFields:!0,writerFactory:()=>new QE};function ode(e){return e?Object.assign(Object.assign({},e1),e):e1}function ude(e){return e?Object.assign(Object.assign({},t1),e):t1}function a1(){return{makeReadOptions:ode,makeWriteOptions:ude,listUnknownFields(e){var t;return(t=e[Wl])!==null&&t!==void 0?t:[]},discardUnknownFields(e){delete e[Wl]},writeUnknownFields(e,t){let r=e[Wl];if(r)for(let i of r)t.tag(i.no,i.wireType).raw(i.data)},onUnknownField(e,t,n,r){let i=e;Array.isArray(i[Wl])||(i[Wl]=[]),i[Wl].push({no:t,wireType:n,data:r})},readMessage(e,t,n,r,i){let a=e.getType(),o=i?t.len:t.pos+n,c,l;for(;t.pos0&&(l=lde),a){let g=e[o];if(r==Bn.LengthDelimited&&c!=Ne.STRING&&c!=Ne.BYTES){let F=t.uint32()+t.pos;for(;t.posEa(g,y)?g:new y(g));else{let g=o[i];y.fieldWrapper?y.typeName==="google.protobuf.BytesValue"?a[i]=ef(g):a[i]=g:a[i]=Ea(g,y)?g:new y(g)}break}}},equals(e,t,n){return t===n?!0:!t||!n?!1:e.fields.byMember().every(r=>{let i=t[r.localName],a=n[r.localName];if(r.repeated){if(i.length!==a.length)return!1;switch(r.kind){case"message":return i.every((o,c)=>r.T.equals(o,a[c]));case"scalar":return i.every((o,c)=>Os(r.T,o,a[c]));case"enum":return i.every((o,c)=>Os(Ne.INT32,o,a[c]))}throw new Error(`repeated cannot contain ${r.kind}`)}switch(r.kind){case"message":return r.T.equals(i,a);case"enum":return Os(Ne.INT32,i,a);case"scalar":return Os(r.T,i,a);case"oneof":if(i.case!==a.case)return!1;let o=r.findField(i.case);if(o===void 0)return!0;switch(o.kind){case"message":return o.T.equals(i.value,a.value);case"enum":return Os(Ne.INT32,i.value,a.value);case"scalar":return Os(o.T,i.value,a.value)}throw new Error(`oneof cannot contain ${o.kind}`);case"map":let c=Object.keys(i).concat(Object.keys(a));switch(r.V.kind){case"message":let l=r.V.T;return c.every(f=>l.equals(i[f],a[f]));case"enum":return c.every(f=>Os(Ne.INT32,i[f],a[f]));case"scalar":let p=r.V.T;return c.every(f=>Os(p,i[f],a[f]))}break}})},clone(e){let t=e.getType(),n=new t,r=n;for(let i of t.fields.byMember()){let a=e[i.localName],o;if(i.repeated)o=a.map(rh);else if(i.kind=="map"){o=r[i.localName];for(let[c,l]of Object.entries(a))o[c]=rh(l)}else i.kind=="oneof"?o=i.findField(a.case)?{case:a.case,value:rh(a.value)}:{case:void 0}:o=rh(a);r[i.localName]=o}for(let i of t.runtime.bin.listUnknownFields(e))t.runtime.bin.onUnknownField(r,i.no,i.wireType,i.data);return n}}}function rh(e){if(e===void 0)return e;if(Ea(e))return e.clone();if(e instanceof Uint8Array){let t=new Uint8Array(e.byteLength);return t.set(e),t}return e}function ef(e){return e instanceof Uint8Array?e:new Uint8Array(e)}function u1(e,t,n){return{syntax:e,json:ZV(),bin:a1(),util:Object.assign(Object.assign({},o1()),{newFieldList:t,initFields:n}),makeMessageType(r,i,a){return MV(this,r,i,a)},makeEnum:UV,makeEnumType:lD,getEnumType:BV,makeExtension(r,i,a){return GV(this,r,i,a)}}}m();T();N();var ih=class{constructor(t,n){this._fields=t,this._normalizer=n}findJsonName(t){if(!this.jsonNames){let n={};for(let r of this.list())n[r.jsonName]=n[r.name]=r;this.jsonNames=n}return this.jsonNames[t]}find(t){if(!this.numbers){let n={};for(let r of this.list())n[r.no]=r;this.numbers=n}return this.numbers[t]}list(){return this.all||(this.all=this._normalizer(this._fields)),this.all}byNumber(){return this.numbersAsc||(this.numbersAsc=this.list().concat().sort((t,n)=>t.no-n.no)),this.numbersAsc}byMember(){if(!this.members){this.members=[];let t=this.members,n;for(let r of this.list())r.oneof?r.oneof!==n&&(n=r.oneof,t.push(n)):t.push(r)}return this.members}};m();T();N();m();T();N();m();T();N();function ID(e,t){let n=d1(e);return t?n:Tde(Nde(n))}function c1(e){return ID(e,!1)}var l1=d1;function d1(e){let t=!1,n=[];for(let r=0;r`${e}$`,Nde=e=>mde.has(e)?p1(e):e,Tde=e=>fde.has(e)?p1(e):e;var ah=class{constructor(t){this.kind="oneof",this.repeated=!1,this.packed=!1,this.opt=!1,this.req=!1,this.default=void 0,this.fields=[],this.name=t,this.localName=c1(t)}addField(t){sn(t.oneof===this,`field ${t.name} not one of ${this.name}`),this.fields.push(t)}findField(t){if(!this._lookup){this._lookup=Object.create(null);for(let n=0;nnew ih(e,t=>f1(t,!0)),e=>{for(let t of e.getType().fields.byMember()){if(t.opt)continue;let n=t.localName,r=e;if(t.repeated){r[n]=[];continue}switch(t.kind){case"oneof":r[n]={case:void 0};break;case"enum":r[n]=0;break;case"map":r[n]={};break;case"scalar":r[n]=Ta(t.T,t.L);break;case"message":break}}});var Xl;(function(e){e[e.OK=0]="OK",e[e.ERR=1]="ERR",e[e.ERR_NOT_FOUND=2]="ERR_NOT_FOUND",e[e.ERR_ALREADY_EXISTS=3]="ERR_ALREADY_EXISTS",e[e.ERR_INVALID_SUBGRAPH_SCHEMA=4]="ERR_INVALID_SUBGRAPH_SCHEMA",e[e.ERR_SUBGRAPH_COMPOSITION_FAILED=5]="ERR_SUBGRAPH_COMPOSITION_FAILED",e[e.ERR_SUBGRAPH_CHECK_FAILED=6]="ERR_SUBGRAPH_CHECK_FAILED",e[e.ERR_INVALID_LABELS=7]="ERR_INVALID_LABELS",e[e.ERR_ANALYTICS_DISABLED=8]="ERR_ANALYTICS_DISABLED",e[e.ERROR_NOT_AUTHENTICATED=9]="ERROR_NOT_AUTHENTICATED",e[e.ERR_OPENAI_DISABLED=10]="ERR_OPENAI_DISABLED",e[e.ERR_FREE_TRIAL_EXPIRED=11]="ERR_FREE_TRIAL_EXPIRED",e[e.ERROR_NOT_AUTHORIZED=12]="ERROR_NOT_AUTHORIZED",e[e.ERR_LIMIT_REACHED=13]="ERR_LIMIT_REACHED",e[e.ERR_DEPLOYMENT_FAILED=14]="ERR_DEPLOYMENT_FAILED",e[e.ERR_INVALID_NAME=15]="ERR_INVALID_NAME",e[e.ERR_UPGRADE_PLAN=16]="ERR_UPGRADE_PLAN",e[e.ERR_BAD_REQUEST=17]="ERR_BAD_REQUEST",e[e.ERR_SCHEMA_MISMATCH_WITH_APPROVED_PROPOSAL=18]="ERR_SCHEMA_MISMATCH_WITH_APPROVED_PROPOSAL"})(Xl||(Xl={}));B.util.setEnumType(Xl,"wg.cosmo.common.EnumStatusCode",[{no:0,name:"OK"},{no:1,name:"ERR"},{no:2,name:"ERR_NOT_FOUND"},{no:3,name:"ERR_ALREADY_EXISTS"},{no:4,name:"ERR_INVALID_SUBGRAPH_SCHEMA"},{no:5,name:"ERR_SUBGRAPH_COMPOSITION_FAILED"},{no:6,name:"ERR_SUBGRAPH_CHECK_FAILED"},{no:7,name:"ERR_INVALID_LABELS"},{no:8,name:"ERR_ANALYTICS_DISABLED"},{no:9,name:"ERROR_NOT_AUTHENTICATED"},{no:10,name:"ERR_OPENAI_DISABLED"},{no:11,name:"ERR_FREE_TRIAL_EXPIRED"},{no:12,name:"ERROR_NOT_AUTHORIZED"},{no:13,name:"ERR_LIMIT_REACHED"},{no:14,name:"ERR_DEPLOYMENT_FAILED"},{no:15,name:"ERR_INVALID_NAME"},{no:16,name:"ERR_UPGRADE_PLAN"},{no:17,name:"ERR_BAD_REQUEST"},{no:18,name:"ERR_SCHEMA_MISMATCH_WITH_APPROVED_PROPOSAL"}]);var bs;(function(e){e[e.GRAPHQL_SUBSCRIPTION_PROTOCOL_WS=0]="GRAPHQL_SUBSCRIPTION_PROTOCOL_WS",e[e.GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE=1]="GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE",e[e.GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE_POST=2]="GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE_POST"})(bs||(bs={}));B.util.setEnumType(bs,"wg.cosmo.common.GraphQLSubscriptionProtocol",[{no:0,name:"GRAPHQL_SUBSCRIPTION_PROTOCOL_WS"},{no:1,name:"GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE"},{no:2,name:"GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE_POST"}]);var As;(function(e){e[e.GRAPHQL_WEBSOCKET_SUBPROTOCOL_AUTO=0]="GRAPHQL_WEBSOCKET_SUBPROTOCOL_AUTO",e[e.GRAPHQL_WEBSOCKET_SUBPROTOCOL_WS=1]="GRAPHQL_WEBSOCKET_SUBPROTOCOL_WS",e[e.GRAPHQL_WEBSOCKET_SUBPROTOCOL_TRANSPORT_WS=2]="GRAPHQL_WEBSOCKET_SUBPROTOCOL_TRANSPORT_WS"})(As||(As={}));B.util.setEnumType(As,"wg.cosmo.common.GraphQLWebsocketSubprotocol",[{no:0,name:"GRAPHQL_WEBSOCKET_SUBPROTOCOL_AUTO"},{no:1,name:"GRAPHQL_WEBSOCKET_SUBPROTOCOL_WS"},{no:2,name:"GRAPHQL_WEBSOCKET_SUBPROTOCOL_TRANSPORT_WS"}]);var v1=ss(Ae(),1);m();T();N();var gD;(function(e){e[e.RENDER_ARGUMENT_DEFAULT=0]="RENDER_ARGUMENT_DEFAULT",e[e.RENDER_ARGUMENT_AS_GRAPHQL_VALUE=1]="RENDER_ARGUMENT_AS_GRAPHQL_VALUE",e[e.RENDER_ARGUMENT_AS_ARRAY_CSV=2]="RENDER_ARGUMENT_AS_ARRAY_CSV"})(gD||(gD={}));B.util.setEnumType(gD,"wg.cosmo.node.v1.ArgumentRenderConfiguration",[{no:0,name:"RENDER_ARGUMENT_DEFAULT"},{no:1,name:"RENDER_ARGUMENT_AS_GRAPHQL_VALUE"},{no:2,name:"RENDER_ARGUMENT_AS_ARRAY_CSV"}]);var Dc;(function(e){e[e.OBJECT_FIELD=0]="OBJECT_FIELD",e[e.FIELD_ARGUMENT=1]="FIELD_ARGUMENT"})(Dc||(Dc={}));B.util.setEnumType(Dc,"wg.cosmo.node.v1.ArgumentSource",[{no:0,name:"OBJECT_FIELD"},{no:1,name:"FIELD_ARGUMENT"}]);var yu;(function(e){e[e.STATIC=0]="STATIC",e[e.GRAPHQL=1]="GRAPHQL",e[e.PUBSUB=2]="PUBSUB"})(yu||(yu={}));B.util.setEnumType(yu,"wg.cosmo.node.v1.DataSourceKind",[{no:0,name:"STATIC"},{no:1,name:"GRAPHQL"},{no:2,name:"PUBSUB"}]);var tf;(function(e){e[e.UNSPECIFIED=0]="UNSPECIFIED",e[e.QUERY=1]="QUERY",e[e.MUTATION=2]="MUTATION",e[e.SUBSCRIPTION=3]="SUBSCRIPTION"})(tf||(tf={}));B.util.setEnumType(tf,"wg.cosmo.node.v1.OperationType",[{no:0,name:"OPERATION_TYPE_UNSPECIFIED"},{no:1,name:"OPERATION_TYPE_QUERY"},{no:2,name:"OPERATION_TYPE_MUTATION"},{no:3,name:"OPERATION_TYPE_SUBSCRIPTION"}]);var Uo;(function(e){e[e.PUBLISH=0]="PUBLISH",e[e.REQUEST=1]="REQUEST",e[e.SUBSCRIBE=2]="SUBSCRIBE"})(Uo||(Uo={}));B.util.setEnumType(Uo,"wg.cosmo.node.v1.EventType",[{no:0,name:"PUBLISH"},{no:1,name:"REQUEST"},{no:2,name:"SUBSCRIBE"}]);var Iu;(function(e){e[e.STATIC_CONFIGURATION_VARIABLE=0]="STATIC_CONFIGURATION_VARIABLE",e[e.ENV_CONFIGURATION_VARIABLE=1]="ENV_CONFIGURATION_VARIABLE",e[e.PLACEHOLDER_CONFIGURATION_VARIABLE=2]="PLACEHOLDER_CONFIGURATION_VARIABLE"})(Iu||(Iu={}));B.util.setEnumType(Iu,"wg.cosmo.node.v1.ConfigurationVariableKind",[{no:0,name:"STATIC_CONFIGURATION_VARIABLE"},{no:1,name:"ENV_CONFIGURATION_VARIABLE"},{no:2,name:"PLACEHOLDER_CONFIGURATION_VARIABLE"}]);var bc;(function(e){e[e.GET=0]="GET",e[e.POST=1]="POST",e[e.PUT=2]="PUT",e[e.DELETE=3]="DELETE",e[e.OPTIONS=4]="OPTIONS"})(bc||(bc={}));B.util.setEnumType(bc,"wg.cosmo.node.v1.HTTPMethod",[{no:0,name:"GET"},{no:1,name:"POST"},{no:2,name:"PUT"},{no:3,name:"DELETE"},{no:4,name:"OPTIONS"}]);var Rs=class Rs extends Le{constructor(n){super();_(this,"id","");_(this,"name","");_(this,"routingUrl","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Rs().fromBinary(n,r)}static fromJson(n,r){return new Rs().fromJson(n,r)}static fromJsonString(n,r){return new Rs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Rs,n,r)}};_(Rs,"runtime",B),_(Rs,"typeName","wg.cosmo.node.v1.Subgraph"),_(Rs,"fields",B.util.newFieldList(()=>[{no:1,name:"id",kind:"scalar",T:9},{no:2,name:"name",kind:"scalar",T:9},{no:3,name:"routing_url",kind:"scalar",T:9}]));var sh=Rs,Ps=class Ps extends Le{constructor(n){super();_(this,"configByFeatureFlagName",{});B.util.initPartial(n,this)}static fromBinary(n,r){return new Ps().fromBinary(n,r)}static fromJson(n,r){return new Ps().fromJson(n,r)}static fromJsonString(n,r){return new Ps().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ps,n,r)}};_(Ps,"runtime",B),_(Ps,"typeName","wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs"),_(Ps,"fields",B.util.newFieldList(()=>[{no:1,name:"config_by_feature_flag_name",kind:"map",K:9,V:{kind:"message",T:vD}}]));var _D=Ps,Fs=class Fs extends Le{constructor(n){super();_(this,"engineConfig");_(this,"version","");_(this,"subgraphs",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Fs().fromBinary(n,r)}static fromJson(n,r){return new Fs().fromJson(n,r)}static fromJsonString(n,r){return new Fs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Fs,n,r)}};_(Fs,"runtime",B),_(Fs,"typeName","wg.cosmo.node.v1.FeatureFlagRouterExecutionConfig"),_(Fs,"fields",B.util.newFieldList(()=>[{no:1,name:"engine_config",kind:"message",T:Zl},{no:2,name:"version",kind:"scalar",T:9},{no:3,name:"subgraphs",kind:"message",T:sh,repeated:!0}]));var vD=Fs,ws=class ws extends Le{constructor(n){super();_(this,"engineConfig");_(this,"version","");_(this,"subgraphs",[]);_(this,"featureFlagConfigs");_(this,"compatibilityVersion","");B.util.initPartial(n,this)}static fromBinary(n,r){return new ws().fromBinary(n,r)}static fromJson(n,r){return new ws().fromJson(n,r)}static fromJsonString(n,r){return new ws().fromJsonString(n,r)}static equals(n,r){return B.util.equals(ws,n,r)}};_(ws,"runtime",B),_(ws,"typeName","wg.cosmo.node.v1.RouterConfig"),_(ws,"fields",B.util.newFieldList(()=>[{no:1,name:"engine_config",kind:"message",T:Zl},{no:2,name:"version",kind:"scalar",T:9},{no:3,name:"subgraphs",kind:"message",T:sh,repeated:!0},{no:4,name:"feature_flag_configs",kind:"message",T:_D,opt:!0},{no:5,name:"compatibility_version",kind:"scalar",T:9}]));var nf=ws,Ls=class Ls extends Le{constructor(n){super();_(this,"code",Xl.OK);_(this,"details");B.util.initPartial(n,this)}static fromBinary(n,r){return new Ls().fromBinary(n,r)}static fromJson(n,r){return new Ls().fromJson(n,r)}static fromJsonString(n,r){return new Ls().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ls,n,r)}};_(Ls,"runtime",B),_(Ls,"typeName","wg.cosmo.node.v1.Response"),_(Ls,"fields",B.util.newFieldList(()=>[{no:1,name:"code",kind:"enum",T:B.getEnumType(Xl)},{no:2,name:"details",kind:"scalar",T:9,opt:!0}]));var SD=Ls,Cs=class Cs extends Le{constructor(n){super();_(this,"code",0);_(this,"message","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Cs().fromBinary(n,r)}static fromJson(n,r){return new Cs().fromJson(n,r)}static fromJsonString(n,r){return new Cs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Cs,n,r)}};_(Cs,"runtime",B),_(Cs,"typeName","wg.cosmo.node.v1.ResponseStatus"),_(Cs,"fields",B.util.newFieldList(()=>[{no:1,name:"code",kind:"scalar",T:5},{no:2,name:"message",kind:"scalar",T:9}]));var m1=Cs,Bs=class Bs extends Le{constructor(n){super();_(this,"accountLimits");_(this,"graphPublicKey","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Bs().fromBinary(n,r)}static fromJson(n,r){return new Bs().fromJson(n,r)}static fromJsonString(n,r){return new Bs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Bs,n,r)}};_(Bs,"runtime",B),_(Bs,"typeName","wg.cosmo.node.v1.RegistrationInfo"),_(Bs,"fields",B.util.newFieldList(()=>[{no:1,name:"account_limits",kind:"message",T:DD},{no:2,name:"graph_public_key",kind:"scalar",T:9}]));var OD=Bs,Us=class Us extends Le{constructor(n){super();_(this,"traceSamplingRate",0);B.util.initPartial(n,this)}static fromBinary(n,r){return new Us().fromBinary(n,r)}static fromJson(n,r){return new Us().fromJson(n,r)}static fromJsonString(n,r){return new Us().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Us,n,r)}};_(Us,"runtime",B),_(Us,"typeName","wg.cosmo.node.v1.AccountLimits"),_(Us,"fields",B.util.newFieldList(()=>[{no:1,name:"trace_sampling_rate",kind:"scalar",T:2}]));var DD=Us,ks=class ks extends Le{constructor(t){super(),B.util.initPartial(t,this)}static fromBinary(t,n){return new ks().fromBinary(t,n)}static fromJson(t,n){return new ks().fromJson(t,n)}static fromJsonString(t,n){return new ks().fromJsonString(t,n)}static equals(t,n){return B.util.equals(ks,t,n)}};_(ks,"runtime",B),_(ks,"typeName","wg.cosmo.node.v1.SelfRegisterRequest"),_(ks,"fields",B.util.newFieldList(()=>[]));var N1=ks,Ms=class Ms extends Le{constructor(n){super();_(this,"response");_(this,"registrationInfo");B.util.initPartial(n,this)}static fromBinary(n,r){return new Ms().fromBinary(n,r)}static fromJson(n,r){return new Ms().fromJson(n,r)}static fromJsonString(n,r){return new Ms().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ms,n,r)}};_(Ms,"runtime",B),_(Ms,"typeName","wg.cosmo.node.v1.SelfRegisterResponse"),_(Ms,"fields",B.util.newFieldList(()=>[{no:1,name:"response",kind:"message",T:SD},{no:2,name:"registrationInfo",kind:"message",T:OD,opt:!0}]));var T1=Ms,xs=class xs extends Le{constructor(n){super();_(this,"defaultFlushInterval",Kn.zero);_(this,"datasourceConfigurations",[]);_(this,"fieldConfigurations",[]);_(this,"graphqlSchema","");_(this,"typeConfigurations",[]);_(this,"stringStorage",{});_(this,"graphqlClientSchema");B.util.initPartial(n,this)}static fromBinary(n,r){return new xs().fromBinary(n,r)}static fromJson(n,r){return new xs().fromJson(n,r)}static fromJsonString(n,r){return new xs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(xs,n,r)}};_(xs,"runtime",B),_(xs,"typeName","wg.cosmo.node.v1.EngineConfiguration"),_(xs,"fields",B.util.newFieldList(()=>[{no:1,name:"defaultFlushInterval",kind:"scalar",T:3},{no:2,name:"datasource_configurations",kind:"message",T:rf,repeated:!0},{no:3,name:"field_configurations",kind:"message",T:of,repeated:!0},{no:4,name:"graphqlSchema",kind:"scalar",T:9},{no:5,name:"type_configurations",kind:"message",T:bD,repeated:!0},{no:6,name:"string_storage",kind:"map",K:9,V:{kind:"scalar",T:9}},{no:7,name:"graphql_client_schema",kind:"scalar",T:9,opt:!0}]));var Zl=xs,qs=class qs extends Le{constructor(n){super();_(this,"kind",yu.STATIC);_(this,"rootNodes",[]);_(this,"childNodes",[]);_(this,"overrideFieldPathFromAlias",!1);_(this,"customGraphql");_(this,"customStatic");_(this,"directives",[]);_(this,"requestTimeoutSeconds",Kn.zero);_(this,"id","");_(this,"keys",[]);_(this,"provides",[]);_(this,"requires",[]);_(this,"customEvents");_(this,"entityInterfaces",[]);_(this,"interfaceObjects",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new qs().fromBinary(n,r)}static fromJson(n,r){return new qs().fromJson(n,r)}static fromJsonString(n,r){return new qs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(qs,n,r)}};_(qs,"runtime",B),_(qs,"typeName","wg.cosmo.node.v1.DataSourceConfiguration"),_(qs,"fields",B.util.newFieldList(()=>[{no:1,name:"kind",kind:"enum",T:B.getEnumType(yu)},{no:2,name:"root_nodes",kind:"message",T:ed,repeated:!0},{no:3,name:"child_nodes",kind:"message",T:ed,repeated:!0},{no:4,name:"override_field_path_from_alias",kind:"scalar",T:8},{no:5,name:"custom_graphql",kind:"message",T:lf},{no:6,name:"custom_static",kind:"message",T:MD},{no:7,name:"directives",kind:"message",T:xD,repeated:!0},{no:8,name:"request_timeout_seconds",kind:"scalar",T:3},{no:9,name:"id",kind:"scalar",T:9},{no:10,name:"keys",kind:"message",T:Oc,repeated:!0},{no:11,name:"provides",kind:"message",T:Oc,repeated:!0},{no:12,name:"requires",kind:"message",T:Oc,repeated:!0},{no:13,name:"custom_events",kind:"message",T:Rc},{no:14,name:"entity_interfaces",kind:"message",T:td,repeated:!0},{no:15,name:"interface_objects",kind:"message",T:td,repeated:!0}]));var rf=qs,Vs=class Vs extends Le{constructor(n){super();_(this,"name","");_(this,"sourceType",Dc.OBJECT_FIELD);B.util.initPartial(n,this)}static fromBinary(n,r){return new Vs().fromBinary(n,r)}static fromJson(n,r){return new Vs().fromJson(n,r)}static fromJsonString(n,r){return new Vs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Vs,n,r)}};_(Vs,"runtime",B),_(Vs,"typeName","wg.cosmo.node.v1.ArgumentConfiguration"),_(Vs,"fields",B.util.newFieldList(()=>[{no:1,name:"name",kind:"scalar",T:9},{no:2,name:"source_type",kind:"enum",T:B.getEnumType(Dc)}]));var af=Vs,js=class js extends Le{constructor(n){super();_(this,"requiredAndScopes",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new js().fromBinary(n,r)}static fromJson(n,r){return new js().fromJson(n,r)}static fromJsonString(n,r){return new js().fromJsonString(n,r)}static equals(n,r){return B.util.equals(js,n,r)}};_(js,"runtime",B),_(js,"typeName","wg.cosmo.node.v1.Scopes"),_(js,"fields",B.util.newFieldList(()=>[{no:1,name:"required_and_scopes",kind:"scalar",T:9,repeated:!0}]));var Ac=js,Ks=class Ks extends Le{constructor(n){super();_(this,"requiresAuthentication",!1);_(this,"requiredOrScopes",[]);_(this,"requiredOrScopesByOr",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Ks().fromBinary(n,r)}static fromJson(n,r){return new Ks().fromJson(n,r)}static fromJsonString(n,r){return new Ks().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ks,n,r)}};_(Ks,"runtime",B),_(Ks,"typeName","wg.cosmo.node.v1.AuthorizationConfiguration"),_(Ks,"fields",B.util.newFieldList(()=>[{no:1,name:"requires_authentication",kind:"scalar",T:8},{no:2,name:"required_or_scopes",kind:"message",T:Ac,repeated:!0},{no:3,name:"required_or_scopes_by_or",kind:"message",T:Ac,repeated:!0}]));var sf=Ks,Gs=class Gs extends Le{constructor(n){super();_(this,"typeName","");_(this,"fieldName","");_(this,"argumentsConfiguration",[]);_(this,"authorizationConfiguration");_(this,"subscriptionFilterCondition");B.util.initPartial(n,this)}static fromBinary(n,r){return new Gs().fromBinary(n,r)}static fromJson(n,r){return new Gs().fromJson(n,r)}static fromJsonString(n,r){return new Gs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Gs,n,r)}};_(Gs,"runtime",B),_(Gs,"typeName","wg.cosmo.node.v1.FieldConfiguration"),_(Gs,"fields",B.util.newFieldList(()=>[{no:1,name:"type_name",kind:"scalar",T:9},{no:2,name:"field_name",kind:"scalar",T:9},{no:3,name:"arguments_configuration",kind:"message",T:af,repeated:!0},{no:4,name:"authorization_configuration",kind:"message",T:sf},{no:5,name:"subscription_filter_condition",kind:"message",T:gu,opt:!0}]));var of=Gs,$s=class $s extends Le{constructor(n){super();_(this,"typeName","");_(this,"renameTo","");B.util.initPartial(n,this)}static fromBinary(n,r){return new $s().fromBinary(n,r)}static fromJson(n,r){return new $s().fromJson(n,r)}static fromJsonString(n,r){return new $s().fromJsonString(n,r)}static equals(n,r){return B.util.equals($s,n,r)}};_($s,"runtime",B),_($s,"typeName","wg.cosmo.node.v1.TypeConfiguration"),_($s,"fields",B.util.newFieldList(()=>[{no:1,name:"type_name",kind:"scalar",T:9},{no:2,name:"rename_to",kind:"scalar",T:9}]));var bD=$s,Qs=class Qs extends Le{constructor(n){super();_(this,"typeName","");_(this,"fieldNames",[]);_(this,"externalFieldNames",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Qs().fromBinary(n,r)}static fromJson(n,r){return new Qs().fromJson(n,r)}static fromJsonString(n,r){return new Qs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Qs,n,r)}};_(Qs,"runtime",B),_(Qs,"typeName","wg.cosmo.node.v1.TypeField"),_(Qs,"fields",B.util.newFieldList(()=>[{no:1,name:"type_name",kind:"scalar",T:9},{no:2,name:"field_names",kind:"scalar",T:9,repeated:!0},{no:3,name:"external_field_names",kind:"scalar",T:9,repeated:!0}]));var ed=Qs,Ys=class Ys extends Le{constructor(n){super();_(this,"fieldName","");_(this,"typeName","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Ys().fromBinary(n,r)}static fromJson(n,r){return new Ys().fromJson(n,r)}static fromJsonString(n,r){return new Ys().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ys,n,r)}};_(Ys,"runtime",B),_(Ys,"typeName","wg.cosmo.node.v1.FieldCoordinates"),_(Ys,"fields",B.util.newFieldList(()=>[{no:1,name:"field_name",kind:"scalar",T:9},{no:2,name:"type_name",kind:"scalar",T:9}]));var uf=Ys,Js=class Js extends Le{constructor(n){super();_(this,"fieldCoordinatesPath",[]);_(this,"fieldPath",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Js().fromBinary(n,r)}static fromJson(n,r){return new Js().fromJson(n,r)}static fromJsonString(n,r){return new Js().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Js,n,r)}};_(Js,"runtime",B),_(Js,"typeName","wg.cosmo.node.v1.FieldSetCondition"),_(Js,"fields",B.util.newFieldList(()=>[{no:1,name:"field_coordinates_path",kind:"message",T:uf,repeated:!0},{no:2,name:"field_path",kind:"scalar",T:9,repeated:!0}]));var cf=Js,Hs=class Hs extends Le{constructor(n){super();_(this,"typeName","");_(this,"fieldName","");_(this,"selectionSet","");_(this,"disableEntityResolver",!1);_(this,"conditions",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Hs().fromBinary(n,r)}static fromJson(n,r){return new Hs().fromJson(n,r)}static fromJsonString(n,r){return new Hs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Hs,n,r)}};_(Hs,"runtime",B),_(Hs,"typeName","wg.cosmo.node.v1.RequiredField"),_(Hs,"fields",B.util.newFieldList(()=>[{no:1,name:"type_name",kind:"scalar",T:9},{no:2,name:"field_name",kind:"scalar",T:9},{no:3,name:"selection_set",kind:"scalar",T:9},{no:4,name:"disable_entity_resolver",kind:"scalar",T:8},{no:5,name:"conditions",kind:"message",T:cf,repeated:!0}]));var Oc=Hs,zs=class zs extends Le{constructor(n){super();_(this,"interfaceTypeName","");_(this,"concreteTypeNames",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new zs().fromBinary(n,r)}static fromJson(n,r){return new zs().fromJson(n,r)}static fromJsonString(n,r){return new zs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(zs,n,r)}};_(zs,"runtime",B),_(zs,"typeName","wg.cosmo.node.v1.EntityInterfaceConfiguration"),_(zs,"fields",B.util.newFieldList(()=>[{no:1,name:"interface_type_name",kind:"scalar",T:9},{no:2,name:"concrete_type_names",kind:"scalar",T:9,repeated:!0}]));var td=zs,Ws=class Ws extends Le{constructor(n){super();_(this,"url");_(this,"method",bc.GET);_(this,"header",{});_(this,"body");_(this,"query",[]);_(this,"urlEncodeBody",!1);_(this,"mtls");_(this,"baseUrl");_(this,"path");_(this,"httpProxyUrl");B.util.initPartial(n,this)}static fromBinary(n,r){return new Ws().fromBinary(n,r)}static fromJson(n,r){return new Ws().fromJson(n,r)}static fromJsonString(n,r){return new Ws().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ws,n,r)}};_(Ws,"runtime",B),_(Ws,"typeName","wg.cosmo.node.v1.FetchConfiguration"),_(Ws,"fields",B.util.newFieldList(()=>[{no:1,name:"url",kind:"message",T:Mr},{no:2,name:"method",kind:"enum",T:B.getEnumType(bc)},{no:3,name:"header",kind:"map",K:9,V:{kind:"message",T:VD}},{no:4,name:"body",kind:"message",T:Mr},{no:5,name:"query",kind:"message",T:qD,repeated:!0},{no:7,name:"url_encode_body",kind:"scalar",T:8},{no:8,name:"mtls",kind:"message",T:jD},{no:9,name:"base_url",kind:"message",T:Mr},{no:10,name:"path",kind:"message",T:Mr},{no:11,name:"http_proxy_url",kind:"message",T:Mr,opt:!0}]));var AD=Ws,Xs=class Xs extends Le{constructor(n){super();_(this,"statusCode",Kn.zero);_(this,"typeName","");_(this,"injectStatusCodeIntoBody",!1);B.util.initPartial(n,this)}static fromBinary(n,r){return new Xs().fromBinary(n,r)}static fromJson(n,r){return new Xs().fromJson(n,r)}static fromJsonString(n,r){return new Xs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Xs,n,r)}};_(Xs,"runtime",B),_(Xs,"typeName","wg.cosmo.node.v1.StatusCodeTypeMapping"),_(Xs,"fields",B.util.newFieldList(()=>[{no:1,name:"status_code",kind:"scalar",T:3},{no:2,name:"type_name",kind:"scalar",T:9},{no:3,name:"inject_status_code_into_body",kind:"scalar",T:8}]));var E1=Xs,Zs=class Zs extends Le{constructor(n){super();_(this,"fetch");_(this,"subscription");_(this,"federation");_(this,"upstreamSchema");_(this,"customScalarTypeFields",[]);_(this,"grpc");B.util.initPartial(n,this)}static fromBinary(n,r){return new Zs().fromBinary(n,r)}static fromJson(n,r){return new Zs().fromJson(n,r)}static fromJsonString(n,r){return new Zs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Zs,n,r)}};_(Zs,"runtime",B),_(Zs,"typeName","wg.cosmo.node.v1.DataSourceCustom_GraphQL"),_(Zs,"fields",B.util.newFieldList(()=>[{no:1,name:"fetch",kind:"message",T:AD},{no:2,name:"subscription",kind:"message",T:KD},{no:3,name:"federation",kind:"message",T:GD},{no:4,name:"upstream_schema",kind:"message",T:Tf},{no:6,name:"custom_scalar_type_fields",kind:"message",T:$D,repeated:!0},{no:7,name:"grpc",kind:"message",T:nd}]));var lf=Zs,eo=class eo extends Le{constructor(n){super();_(this,"mapping");_(this,"protoSchema","");_(this,"plugin");B.util.initPartial(n,this)}static fromBinary(n,r){return new eo().fromBinary(n,r)}static fromJson(n,r){return new eo().fromJson(n,r)}static fromJsonString(n,r){return new eo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(eo,n,r)}};_(eo,"runtime",B),_(eo,"typeName","wg.cosmo.node.v1.GRPCConfiguration"),_(eo,"fields",B.util.newFieldList(()=>[{no:1,name:"mapping",kind:"message",T:PD},{no:2,name:"proto_schema",kind:"scalar",T:9},{no:3,name:"plugin",kind:"message",T:df}]));var nd=eo,to=class to extends Le{constructor(n){super();_(this,"repository","");_(this,"reference","");B.util.initPartial(n,this)}static fromBinary(n,r){return new to().fromBinary(n,r)}static fromJson(n,r){return new to().fromJson(n,r)}static fromJsonString(n,r){return new to().fromJsonString(n,r)}static equals(n,r){return B.util.equals(to,n,r)}};_(to,"runtime",B),_(to,"typeName","wg.cosmo.node.v1.ImageReference"),_(to,"fields",B.util.newFieldList(()=>[{no:1,name:"repository",kind:"scalar",T:9},{no:2,name:"reference",kind:"scalar",T:9}]));var RD=to,no=class no extends Le{constructor(n){super();_(this,"name","");_(this,"version","");_(this,"imageReference");B.util.initPartial(n,this)}static fromBinary(n,r){return new no().fromBinary(n,r)}static fromJson(n,r){return new no().fromJson(n,r)}static fromJsonString(n,r){return new no().fromJsonString(n,r)}static equals(n,r){return B.util.equals(no,n,r)}};_(no,"runtime",B),_(no,"typeName","wg.cosmo.node.v1.PluginConfiguration"),_(no,"fields",B.util.newFieldList(()=>[{no:1,name:"name",kind:"scalar",T:9},{no:2,name:"version",kind:"scalar",T:9},{no:3,name:"image_reference",kind:"message",T:RD,opt:!0}]));var df=no,ro=class ro extends Le{constructor(n){super();_(this,"enabled",!1);B.util.initPartial(n,this)}static fromBinary(n,r){return new ro().fromBinary(n,r)}static fromJson(n,r){return new ro().fromJson(n,r)}static fromJsonString(n,r){return new ro().fromJsonString(n,r)}static equals(n,r){return B.util.equals(ro,n,r)}};_(ro,"runtime",B),_(ro,"typeName","wg.cosmo.node.v1.SSLConfiguration"),_(ro,"fields",B.util.newFieldList(()=>[{no:1,name:"enabled",kind:"scalar",T:8}]));var h1=ro,io=class io extends Le{constructor(n){super();_(this,"version",0);_(this,"service","");_(this,"operationMappings",[]);_(this,"entityMappings",[]);_(this,"typeFieldMappings",[]);_(this,"enumMappings",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new io().fromBinary(n,r)}static fromJson(n,r){return new io().fromJson(n,r)}static fromJsonString(n,r){return new io().fromJsonString(n,r)}static equals(n,r){return B.util.equals(io,n,r)}};_(io,"runtime",B),_(io,"typeName","wg.cosmo.node.v1.GRPCMapping"),_(io,"fields",B.util.newFieldList(()=>[{no:1,name:"version",kind:"scalar",T:5},{no:2,name:"service",kind:"scalar",T:9},{no:3,name:"operation_mappings",kind:"message",T:FD,repeated:!0},{no:4,name:"entity_mappings",kind:"message",T:wD,repeated:!0},{no:5,name:"type_field_mappings",kind:"message",T:LD,repeated:!0},{no:6,name:"enum_mappings",kind:"message",T:UD,repeated:!0}]));var PD=io,ao=class ao extends Le{constructor(n){super();_(this,"type",tf.UNSPECIFIED);_(this,"original","");_(this,"mapped","");_(this,"request","");_(this,"response","");B.util.initPartial(n,this)}static fromBinary(n,r){return new ao().fromBinary(n,r)}static fromJson(n,r){return new ao().fromJson(n,r)}static fromJsonString(n,r){return new ao().fromJsonString(n,r)}static equals(n,r){return B.util.equals(ao,n,r)}};_(ao,"runtime",B),_(ao,"typeName","wg.cosmo.node.v1.OperationMapping"),_(ao,"fields",B.util.newFieldList(()=>[{no:1,name:"type",kind:"enum",T:B.getEnumType(tf)},{no:2,name:"original",kind:"scalar",T:9},{no:3,name:"mapped",kind:"scalar",T:9},{no:4,name:"request",kind:"scalar",T:9},{no:5,name:"response",kind:"scalar",T:9}]));var FD=ao,so=class so extends Le{constructor(n){super();_(this,"typeName","");_(this,"kind","");_(this,"key","");_(this,"rpc","");_(this,"request","");_(this,"response","");B.util.initPartial(n,this)}static fromBinary(n,r){return new so().fromBinary(n,r)}static fromJson(n,r){return new so().fromJson(n,r)}static fromJsonString(n,r){return new so().fromJsonString(n,r)}static equals(n,r){return B.util.equals(so,n,r)}};_(so,"runtime",B),_(so,"typeName","wg.cosmo.node.v1.EntityMapping"),_(so,"fields",B.util.newFieldList(()=>[{no:1,name:"type_name",kind:"scalar",T:9},{no:2,name:"kind",kind:"scalar",T:9},{no:3,name:"key",kind:"scalar",T:9},{no:4,name:"rpc",kind:"scalar",T:9},{no:5,name:"request",kind:"scalar",T:9},{no:6,name:"response",kind:"scalar",T:9}]));var wD=so,oo=class oo extends Le{constructor(n){super();_(this,"type","");_(this,"fieldMappings",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new oo().fromBinary(n,r)}static fromJson(n,r){return new oo().fromJson(n,r)}static fromJsonString(n,r){return new oo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(oo,n,r)}};_(oo,"runtime",B),_(oo,"typeName","wg.cosmo.node.v1.TypeFieldMapping"),_(oo,"fields",B.util.newFieldList(()=>[{no:1,name:"type",kind:"scalar",T:9},{no:2,name:"field_mappings",kind:"message",T:CD,repeated:!0}]));var LD=oo,uo=class uo extends Le{constructor(n){super();_(this,"original","");_(this,"mapped","");_(this,"argumentMappings",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new uo().fromBinary(n,r)}static fromJson(n,r){return new uo().fromJson(n,r)}static fromJsonString(n,r){return new uo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(uo,n,r)}};_(uo,"runtime",B),_(uo,"typeName","wg.cosmo.node.v1.FieldMapping"),_(uo,"fields",B.util.newFieldList(()=>[{no:1,name:"original",kind:"scalar",T:9},{no:2,name:"mapped",kind:"scalar",T:9},{no:3,name:"argument_mappings",kind:"message",T:BD,repeated:!0}]));var CD=uo,co=class co extends Le{constructor(n){super();_(this,"original","");_(this,"mapped","");B.util.initPartial(n,this)}static fromBinary(n,r){return new co().fromBinary(n,r)}static fromJson(n,r){return new co().fromJson(n,r)}static fromJsonString(n,r){return new co().fromJsonString(n,r)}static equals(n,r){return B.util.equals(co,n,r)}};_(co,"runtime",B),_(co,"typeName","wg.cosmo.node.v1.ArgumentMapping"),_(co,"fields",B.util.newFieldList(()=>[{no:1,name:"original",kind:"scalar",T:9},{no:2,name:"mapped",kind:"scalar",T:9}]));var BD=co,lo=class lo extends Le{constructor(n){super();_(this,"type","");_(this,"values",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new lo().fromBinary(n,r)}static fromJson(n,r){return new lo().fromJson(n,r)}static fromJsonString(n,r){return new lo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(lo,n,r)}};_(lo,"runtime",B),_(lo,"typeName","wg.cosmo.node.v1.EnumMapping"),_(lo,"fields",B.util.newFieldList(()=>[{no:1,name:"type",kind:"scalar",T:9},{no:2,name:"values",kind:"message",T:kD,repeated:!0}]));var UD=lo,po=class po extends Le{constructor(n){super();_(this,"original","");_(this,"mapped","");B.util.initPartial(n,this)}static fromBinary(n,r){return new po().fromBinary(n,r)}static fromJson(n,r){return new po().fromJson(n,r)}static fromJsonString(n,r){return new po().fromJsonString(n,r)}static equals(n,r){return B.util.equals(po,n,r)}};_(po,"runtime",B),_(po,"typeName","wg.cosmo.node.v1.EnumValueMapping"),_(po,"fields",B.util.newFieldList(()=>[{no:1,name:"original",kind:"scalar",T:9},{no:2,name:"mapped",kind:"scalar",T:9}]));var kD=po,fo=class fo extends Le{constructor(n){super();_(this,"consumerName","");_(this,"streamName","");_(this,"consumerInactiveThreshold",0);B.util.initPartial(n,this)}static fromBinary(n,r){return new fo().fromBinary(n,r)}static fromJson(n,r){return new fo().fromJson(n,r)}static fromJsonString(n,r){return new fo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(fo,n,r)}};_(fo,"runtime",B),_(fo,"typeName","wg.cosmo.node.v1.NatsStreamConfiguration"),_(fo,"fields",B.util.newFieldList(()=>[{no:1,name:"consumer_name",kind:"scalar",T:9},{no:2,name:"stream_name",kind:"scalar",T:9},{no:3,name:"consumer_inactive_threshold",kind:"scalar",T:5}]));var pf=fo,mo=class mo extends Le{constructor(n){super();_(this,"engineEventConfiguration");_(this,"subjects",[]);_(this,"streamConfiguration");B.util.initPartial(n,this)}static fromBinary(n,r){return new mo().fromBinary(n,r)}static fromJson(n,r){return new mo().fromJson(n,r)}static fromJsonString(n,r){return new mo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(mo,n,r)}};_(mo,"runtime",B),_(mo,"typeName","wg.cosmo.node.v1.NatsEventConfiguration"),_(mo,"fields",B.util.newFieldList(()=>[{no:1,name:"engine_event_configuration",kind:"message",T:ko},{no:2,name:"subjects",kind:"scalar",T:9,repeated:!0},{no:3,name:"stream_configuration",kind:"message",T:pf}]));var ff=mo,No=class No extends Le{constructor(n){super();_(this,"engineEventConfiguration");_(this,"topics",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new No().fromBinary(n,r)}static fromJson(n,r){return new No().fromJson(n,r)}static fromJsonString(n,r){return new No().fromJsonString(n,r)}static equals(n,r){return B.util.equals(No,n,r)}};_(No,"runtime",B),_(No,"typeName","wg.cosmo.node.v1.KafkaEventConfiguration"),_(No,"fields",B.util.newFieldList(()=>[{no:1,name:"engine_event_configuration",kind:"message",T:ko},{no:2,name:"topics",kind:"scalar",T:9,repeated:!0}]));var mf=No,To=class To extends Le{constructor(n){super();_(this,"engineEventConfiguration");_(this,"channels",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new To().fromBinary(n,r)}static fromJson(n,r){return new To().fromJson(n,r)}static fromJsonString(n,r){return new To().fromJsonString(n,r)}static equals(n,r){return B.util.equals(To,n,r)}};_(To,"runtime",B),_(To,"typeName","wg.cosmo.node.v1.RedisEventConfiguration"),_(To,"fields",B.util.newFieldList(()=>[{no:1,name:"engine_event_configuration",kind:"message",T:ko},{no:2,name:"channels",kind:"scalar",T:9,repeated:!0}]));var Nf=To,Eo=class Eo extends Le{constructor(n){super();_(this,"providerId","");_(this,"type",Uo.PUBLISH);_(this,"typeName","");_(this,"fieldName","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Eo().fromBinary(n,r)}static fromJson(n,r){return new Eo().fromJson(n,r)}static fromJsonString(n,r){return new Eo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Eo,n,r)}};_(Eo,"runtime",B),_(Eo,"typeName","wg.cosmo.node.v1.EngineEventConfiguration"),_(Eo,"fields",B.util.newFieldList(()=>[{no:1,name:"provider_id",kind:"scalar",T:9},{no:2,name:"type",kind:"enum",T:B.getEnumType(Uo)},{no:3,name:"type_name",kind:"scalar",T:9},{no:4,name:"field_name",kind:"scalar",T:9}]));var ko=Eo,ho=class ho extends Le{constructor(n){super();_(this,"nats",[]);_(this,"kafka",[]);_(this,"redis",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new ho().fromBinary(n,r)}static fromJson(n,r){return new ho().fromJson(n,r)}static fromJsonString(n,r){return new ho().fromJsonString(n,r)}static equals(n,r){return B.util.equals(ho,n,r)}};_(ho,"runtime",B),_(ho,"typeName","wg.cosmo.node.v1.DataSourceCustomEvents"),_(ho,"fields",B.util.newFieldList(()=>[{no:1,name:"nats",kind:"message",T:ff,repeated:!0},{no:2,name:"kafka",kind:"message",T:mf,repeated:!0},{no:3,name:"redis",kind:"message",T:Nf,repeated:!0}]));var Rc=ho,yo=class yo extends Le{constructor(n){super();_(this,"data");B.util.initPartial(n,this)}static fromBinary(n,r){return new yo().fromBinary(n,r)}static fromJson(n,r){return new yo().fromJson(n,r)}static fromJsonString(n,r){return new yo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(yo,n,r)}};_(yo,"runtime",B),_(yo,"typeName","wg.cosmo.node.v1.DataSourceCustom_Static"),_(yo,"fields",B.util.newFieldList(()=>[{no:1,name:"data",kind:"message",T:Mr}]));var MD=yo,Io=class Io extends Le{constructor(n){super();_(this,"kind",Iu.STATIC_CONFIGURATION_VARIABLE);_(this,"staticVariableContent","");_(this,"environmentVariableName","");_(this,"environmentVariableDefaultValue","");_(this,"placeholderVariableName","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Io().fromBinary(n,r)}static fromJson(n,r){return new Io().fromJson(n,r)}static fromJsonString(n,r){return new Io().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Io,n,r)}};_(Io,"runtime",B),_(Io,"typeName","wg.cosmo.node.v1.ConfigurationVariable"),_(Io,"fields",B.util.newFieldList(()=>[{no:1,name:"kind",kind:"enum",T:B.getEnumType(Iu)},{no:2,name:"static_variable_content",kind:"scalar",T:9},{no:3,name:"environment_variable_name",kind:"scalar",T:9},{no:4,name:"environment_variable_default_value",kind:"scalar",T:9},{no:5,name:"placeholder_variable_name",kind:"scalar",T:9}]));var Mr=Io,go=class go extends Le{constructor(n){super();_(this,"directiveName","");_(this,"renameTo","");B.util.initPartial(n,this)}static fromBinary(n,r){return new go().fromBinary(n,r)}static fromJson(n,r){return new go().fromJson(n,r)}static fromJsonString(n,r){return new go().fromJsonString(n,r)}static equals(n,r){return B.util.equals(go,n,r)}};_(go,"runtime",B),_(go,"typeName","wg.cosmo.node.v1.DirectiveConfiguration"),_(go,"fields",B.util.newFieldList(()=>[{no:1,name:"directive_name",kind:"scalar",T:9},{no:2,name:"rename_to",kind:"scalar",T:9}]));var xD=go,_o=class _o extends Le{constructor(n){super();_(this,"name","");_(this,"value","");B.util.initPartial(n,this)}static fromBinary(n,r){return new _o().fromBinary(n,r)}static fromJson(n,r){return new _o().fromJson(n,r)}static fromJsonString(n,r){return new _o().fromJsonString(n,r)}static equals(n,r){return B.util.equals(_o,n,r)}};_(_o,"runtime",B),_(_o,"typeName","wg.cosmo.node.v1.URLQueryConfiguration"),_(_o,"fields",B.util.newFieldList(()=>[{no:1,name:"name",kind:"scalar",T:9},{no:2,name:"value",kind:"scalar",T:9}]));var qD=_o,vo=class vo extends Le{constructor(n){super();_(this,"values",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new vo().fromBinary(n,r)}static fromJson(n,r){return new vo().fromJson(n,r)}static fromJsonString(n,r){return new vo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(vo,n,r)}};_(vo,"runtime",B),_(vo,"typeName","wg.cosmo.node.v1.HTTPHeader"),_(vo,"fields",B.util.newFieldList(()=>[{no:1,name:"values",kind:"message",T:Mr,repeated:!0}]));var VD=vo,So=class So extends Le{constructor(n){super();_(this,"key");_(this,"cert");_(this,"insecureSkipVerify",!1);B.util.initPartial(n,this)}static fromBinary(n,r){return new So().fromBinary(n,r)}static fromJson(n,r){return new So().fromJson(n,r)}static fromJsonString(n,r){return new So().fromJsonString(n,r)}static equals(n,r){return B.util.equals(So,n,r)}};_(So,"runtime",B),_(So,"typeName","wg.cosmo.node.v1.MTLSConfiguration"),_(So,"fields",B.util.newFieldList(()=>[{no:1,name:"key",kind:"message",T:Mr},{no:2,name:"cert",kind:"message",T:Mr},{no:3,name:"insecureSkipVerify",kind:"scalar",T:8}]));var jD=So,Oo=class Oo extends Le{constructor(n){super();_(this,"enabled",!1);_(this,"url");_(this,"useSSE");_(this,"protocol");_(this,"websocketSubprotocol");B.util.initPartial(n,this)}static fromBinary(n,r){return new Oo().fromBinary(n,r)}static fromJson(n,r){return new Oo().fromJson(n,r)}static fromJsonString(n,r){return new Oo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Oo,n,r)}};_(Oo,"runtime",B),_(Oo,"typeName","wg.cosmo.node.v1.GraphQLSubscriptionConfiguration"),_(Oo,"fields",B.util.newFieldList(()=>[{no:1,name:"enabled",kind:"scalar",T:8},{no:2,name:"url",kind:"message",T:Mr},{no:3,name:"useSSE",kind:"scalar",T:8,opt:!0},{no:4,name:"protocol",kind:"enum",T:B.getEnumType(bs),opt:!0},{no:5,name:"websocketSubprotocol",kind:"enum",T:B.getEnumType(As),opt:!0}]));var KD=Oo,Do=class Do extends Le{constructor(n){super();_(this,"enabled",!1);_(this,"serviceSdl","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Do().fromBinary(n,r)}static fromJson(n,r){return new Do().fromJson(n,r)}static fromJsonString(n,r){return new Do().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Do,n,r)}};_(Do,"runtime",B),_(Do,"typeName","wg.cosmo.node.v1.GraphQLFederationConfiguration"),_(Do,"fields",B.util.newFieldList(()=>[{no:1,name:"enabled",kind:"scalar",T:8},{no:2,name:"serviceSdl",kind:"scalar",T:9}]));var GD=Do,bo=class bo extends Le{constructor(n){super();_(this,"key","");B.util.initPartial(n,this)}static fromBinary(n,r){return new bo().fromBinary(n,r)}static fromJson(n,r){return new bo().fromJson(n,r)}static fromJsonString(n,r){return new bo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(bo,n,r)}};_(bo,"runtime",B),_(bo,"typeName","wg.cosmo.node.v1.InternedString"),_(bo,"fields",B.util.newFieldList(()=>[{no:1,name:"key",kind:"scalar",T:9}]));var Tf=bo,Ao=class Ao extends Le{constructor(n){super();_(this,"typeName","");_(this,"fieldName","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Ao().fromBinary(n,r)}static fromJson(n,r){return new Ao().fromJson(n,r)}static fromJsonString(n,r){return new Ao().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ao,n,r)}};_(Ao,"runtime",B),_(Ao,"typeName","wg.cosmo.node.v1.SingleTypeField"),_(Ao,"fields",B.util.newFieldList(()=>[{no:1,name:"type_name",kind:"scalar",T:9},{no:2,name:"field_name",kind:"scalar",T:9}]));var $D=Ao,Ro=class Ro extends Le{constructor(n){super();_(this,"fieldPath",[]);_(this,"json","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Ro().fromBinary(n,r)}static fromJson(n,r){return new Ro().fromJson(n,r)}static fromJsonString(n,r){return new Ro().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ro,n,r)}};_(Ro,"runtime",B),_(Ro,"typeName","wg.cosmo.node.v1.SubscriptionFieldCondition"),_(Ro,"fields",B.util.newFieldList(()=>[{no:1,name:"field_path",kind:"scalar",T:9,repeated:!0},{no:2,name:"json",kind:"scalar",T:9}]));var Ef=Ro,Gi=class Gi extends Le{constructor(n){super();_(this,"and",[]);_(this,"in");_(this,"not");_(this,"or",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Gi().fromBinary(n,r)}static fromJson(n,r){return new Gi().fromJson(n,r)}static fromJsonString(n,r){return new Gi().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Gi,n,r)}};_(Gi,"runtime",B),_(Gi,"typeName","wg.cosmo.node.v1.SubscriptionFilterCondition"),_(Gi,"fields",B.util.newFieldList(()=>[{no:1,name:"and",kind:"message",T:Gi,repeated:!0},{no:2,name:"in",kind:"message",T:Ef,opt:!0},{no:3,name:"not",kind:"message",T:Gi,opt:!0},{no:4,name:"or",kind:"message",T:Gi,repeated:!0}]));var gu=Gi,Po=class Po extends Le{constructor(n){super();_(this,"operations",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Po().fromBinary(n,r)}static fromJson(n,r){return new Po().fromJson(n,r)}static fromJsonString(n,r){return new Po().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Po,n,r)}};_(Po,"runtime",B),_(Po,"typeName","wg.cosmo.node.v1.CacheWarmerOperations"),_(Po,"fields",B.util.newFieldList(()=>[{no:1,name:"operations",kind:"message",T:QD,repeated:!0}]));var y1=Po,Fo=class Fo extends Le{constructor(n){super();_(this,"request");_(this,"client");B.util.initPartial(n,this)}static fromBinary(n,r){return new Fo().fromBinary(n,r)}static fromJson(n,r){return new Fo().fromJson(n,r)}static fromJsonString(n,r){return new Fo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Fo,n,r)}};_(Fo,"runtime",B),_(Fo,"typeName","wg.cosmo.node.v1.Operation"),_(Fo,"fields",B.util.newFieldList(()=>[{no:1,name:"request",kind:"message",T:YD},{no:2,name:"client",kind:"message",T:zD}]));var QD=Fo,wo=class wo extends Le{constructor(n){super();_(this,"operationName","");_(this,"query","");_(this,"extensions");B.util.initPartial(n,this)}static fromBinary(n,r){return new wo().fromBinary(n,r)}static fromJson(n,r){return new wo().fromJson(n,r)}static fromJsonString(n,r){return new wo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(wo,n,r)}};_(wo,"runtime",B),_(wo,"typeName","wg.cosmo.node.v1.OperationRequest"),_(wo,"fields",B.util.newFieldList(()=>[{no:1,name:"operation_name",kind:"scalar",T:9},{no:2,name:"query",kind:"scalar",T:9},{no:3,name:"extensions",kind:"message",T:JD}]));var YD=wo,Lo=class Lo extends Le{constructor(n){super();_(this,"persistedQuery");B.util.initPartial(n,this)}static fromBinary(n,r){return new Lo().fromBinary(n,r)}static fromJson(n,r){return new Lo().fromJson(n,r)}static fromJsonString(n,r){return new Lo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Lo,n,r)}};_(Lo,"runtime",B),_(Lo,"typeName","wg.cosmo.node.v1.Extension"),_(Lo,"fields",B.util.newFieldList(()=>[{no:1,name:"persisted_query",kind:"message",T:HD}]));var JD=Lo,Co=class Co extends Le{constructor(n){super();_(this,"sha256Hash","");_(this,"version",0);B.util.initPartial(n,this)}static fromBinary(n,r){return new Co().fromBinary(n,r)}static fromJson(n,r){return new Co().fromJson(n,r)}static fromJsonString(n,r){return new Co().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Co,n,r)}};_(Co,"runtime",B),_(Co,"typeName","wg.cosmo.node.v1.PersistedQuery"),_(Co,"fields",B.util.newFieldList(()=>[{no:1,name:"sha256_hash",kind:"scalar",T:9},{no:2,name:"version",kind:"scalar",T:5}]));var HD=Co,Bo=class Bo extends Le{constructor(n){super();_(this,"name","");_(this,"version","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Bo().fromBinary(n,r)}static fromJson(n,r){return new Bo().fromJson(n,r)}static fromJsonString(n,r){return new Bo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Bo,n,r)}};_(Bo,"runtime",B),_(Bo,"typeName","wg.cosmo.node.v1.ClientInfo"),_(Bo,"fields",B.util.newFieldList(()=>[{no:1,name:"name",kind:"scalar",T:9},{no:2,name:"version",kind:"scalar",T:9}]));var zD=Bo;m();T();N();function WD(e){return new Error(`Normalization failed to return a ${e}.`)}function I1(e){return new Error(`Invalid router compatibility version "${e}".`)}m();T();N();var rd=ss(BE(),1);function Ede(e){if(!e.conditions)return;let t=[];for(let n of e.conditions){let r=[];for(let i of n.fieldCoordinatesPath){let a=i.split(".");if(a.length!==2)throw new Error(`fatal: malformed conditional field coordinates "${i}" for field set "${e.selectionSet}".`);r.push(new uf({fieldName:a[1],typeName:a[0]}))}t.push(new cf({fieldCoordinatesPath:r,fieldPath:n.fieldPath}))}return t}function XD(e,t,n){if(e)for(let r of e){let i=Ede(r);t.push(new Oc(x(x({typeName:n,fieldName:r.fieldName,selectionSet:r.selectionSet},r.disableEntityResolver?{disableEntityResolver:!0}:{}),i?{conditions:i}:{})))}}function ZD(e){switch(e){case"publish":return Uo.PUBLISH;case"request":return Uo.REQUEST;case"subscribe":return Uo.SUBSCRIBE}}function g1(e){var n;let t={rootNodes:[],childNodes:[],keys:[],provides:[],events:new Rc({nats:[],kafka:[],redis:[]}),requires:[],entityInterfaces:[],interfaceObjects:[]};for(let r of e.values()){let i=r.typeName,a=[...r.fieldNames],o=new ed({typeName:i,fieldNames:a});if(r.externalFieldNames&&r.externalFieldNames.size>0&&(o.externalFieldNames=[...r.externalFieldNames]),r.isRootNode?t.rootNodes.push(o):t.childNodes.push(o),r.entityInterfaceConcreteTypeNames){let f=new td({interfaceTypeName:i,concreteTypeNames:[...r.entityInterfaceConcreteTypeNames]});r.isInterfaceObject?t.interfaceObjects.push(f):t.entityInterfaces.push(f)}XD(r.keys,t.keys,i),XD(r.provides,t.provides,i),XD(r.requires,t.requires,i);let c=[],l=[],p=[];for(let f of(n=r.events)!=null?n:[])switch(f.providerType){case rd.PROVIDER_TYPE_KAFKA:{l.push(new mf({engineEventConfiguration:new ko({fieldName:f.fieldName,providerId:f.providerId,type:ZD(f.type),typeName:i}),topics:f.topics}));break}case rd.PROVIDER_TYPE_NATS:{c.push(new ff(x({engineEventConfiguration:new ko({fieldName:f.fieldName,providerId:f.providerId,type:ZD(f.type),typeName:i}),subjects:f.subjects},f.streamConfiguration?{streamConfiguration:new pf({consumerInactiveThreshold:f.streamConfiguration.consumerInactiveThreshold,consumerName:f.streamConfiguration.consumerName,streamName:f.streamConfiguration.streamName})}:{})));break}case rd.PROVIDER_TYPE_REDIS:{p.push(new Nf({engineEventConfiguration:new ko({fieldName:f.fieldName,providerId:f.providerId,type:ZD(f.type),typeName:i}),channels:f.channels}));break}default:throw new Error("Fatal: Unknown event provider.")}t.events.nats.push(...c),t.events.kafka.push(...l),t.events.redis.push(...p)}return t}function _1(e){var n,r;let t=[];for(let i of e){let a=i.argumentNames.map(f=>new af({name:f,sourceType:Dc.FIELD_ARGUMENT})),o=new of({argumentsConfiguration:a,fieldName:i.fieldName,typeName:i.typeName}),c=((n=i.requiredScopes)==null?void 0:n.map(f=>new Ac({requiredAndScopes:f})))||[],l=((r=i.requiredScopesByOR)==null?void 0:r.map(f=>new Ac({requiredAndScopes:f})))||[],p=c.length>0;if((i.requiresAuthentication||p)&&(o.authorizationConfiguration=new sf({requiresAuthentication:i.requiresAuthentication||p,requiredOrScopes:c,requiredOrScopesByOr:l})),i.subscriptionFilterCondition){let f=new gu;oh(f,i.subscriptionFilterCondition),o.subscriptionFilterCondition=f}t.push(o)}return t}function oh(e,t){if(t.and!==void 0){let n=[];for(let r of t.and){let i=new gu;oh(i,r),n.push(i)}e.and=n;return}if(t.in!==void 0){e.in=new Ef({fieldPath:t.in.fieldPath,json:JSON.stringify(t.in.values)});return}if(t.not!==void 0){e.not=new gu,oh(e.not,t.not);return}if(t.or!==void 0){let n=[];for(let r of t.or){let i=new gu;oh(i,r),n.push(i)}e.or=n;return}throw new Error("Fatal: Incoming SubscriptionCondition object was malformed.")}var Pc;(function(e){e[e.Plugin=0]="Plugin",e[e.Standard=1]="Standard",e[e.GRPC=2]="GRPC"})(Pc||(Pc={}));var hde=(e,t)=>{let n=stringHash(t);return e.stringStorage[n]=t,new Tf({key:n})},yde=e=>{switch(e){case"ws":return bs.GRAPHQL_SUBSCRIPTION_PROTOCOL_WS;case"sse":return bs.GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE;case"sse_post":return bs.GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE_POST}},Ide=e=>{switch(e){case"auto":return As.GRAPHQL_WEBSOCKET_SUBPROTOCOL_AUTO;case"graphql-ws":return As.GRAPHQL_WEBSOCKET_SUBPROTOCOL_WS;case"graphql-transport-ws":return As.GRAPHQL_WEBSOCKET_SUBPROTOCOL_TRANSPORT_WS}},S1=function(e){if(!id.ROUTER_COMPATIBILITY_VERSIONS.has(e.routerCompatibilityVersion))throw I1(e.routerCompatibilityVersion);let t=new Zl({defaultFlushInterval:BigInt(500),datasourceConfigurations:[],fieldConfigurations:[],graphqlSchema:"",stringStorage:{},typeConfigurations:[]});for(let n of e.subgraphs){if(!n.configurationDataByTypeName)throw WD("ConfigurationDataByTypeName");if(!n.schema)throw WD("GraphQLSchema");let r={enabled:!0},i=hde(t,FV((0,v1.lexicographicSortSchema)(n.schema))),{childNodes:a,entityInterfaces:o,events:c,interfaceObjects:l,keys:p,provides:f,requires:y,rootNodes:g}=g1(n.configurationDataByTypeName),v;switch(n.kind){case Pc.Standard:{r.enabled=!0,r.protocol=yde(n.subscriptionProtocol||"ws"),r.websocketSubprotocol=Ide(n.websocketSubprotocol||"auto"),r.url=new Mr({kind:Iu.STATIC_CONFIGURATION_VARIABLE,staticVariableContent:n.subscriptionUrl||n.url});break}case Pc.Plugin:{v=new nd({mapping:n.mapping,protoSchema:n.protoSchema,plugin:new df({name:n.name,version:n.version,imageReference:n.imageReference})});break}case Pc.GRPC:{v=new nd({mapping:n.mapping,protoSchema:n.protoSchema});break}}let F,k,K;if(c.kafka.length>0||c.nats.length>0||c.redis.length>0){F=yu.PUBSUB,K=new Rc({kafka:c.kafka,nats:c.nats,redis:c.redis});let ne=pe=>id.ROOT_TYPE_NAMES.has(pe.typeName),z=0,Te=0;for(;z({id:n.id,name:n.name,routingUrl:n.url})),compatibilityVersion:`${e.routerCompatibilityVersion}:${id.COMPOSITION_VERSION}`})};m();T();N();var wc=ss(Ae());function O1(e){let t;try{t=(0,wc.parse)(e.schema)}catch(n){throw new Error(`could not parse schema for Graph ${e.name}: ${n}`)}return{definitions:t,name:e.name,url:e.url}}function gde(e){let t=(0,Fc.federateSubgraphs)({subgraphs:e.map(O1),version:Fc.LATEST_ROUTER_COMPATIBILITY_VERSION});if(!t.success)throw new Error(`could not federate schema: ${t.errors.map(n=>n.message).join(", ")}`);return{fieldConfigurations:t.fieldConfigurations,sdl:(0,wc.print)(t.federatedGraphAST)}}function _de(e){let t=(0,Fc.federateSubgraphs)({subgraphs:e.map(O1),version:Fc.LATEST_ROUTER_COMPATIBILITY_VERSION});if(!t.success)throw new Error(`could not federate schema: ${t.errors.map(r=>r.message).join(", ")}`);return S1({federatedClientSDL:(0,wc.printSchema)(t.federatedGraphClientSchema),federatedSDL:(0,wc.printSchema)(t.federatedGraphSchema),fieldConfigurations:t.fieldConfigurations,routerCompatibilityVersion:Fc.LATEST_ROUTER_COMPATIBILITY_VERSION,schemaVersionId:"",subgraphs:e.map((r,i)=>{var l,p;let a=t.subgraphConfigBySubgraphName.get(r.name),o=a==null?void 0:a.schema,c=a==null?void 0:a.configurationDataByTypeName;return{kind:Pc.Standard,id:`${i}`,name:r.name,url:sD(r.url),sdl:r.schema,subscriptionUrl:sD((l=r.subscription_url)!=null?l:r.url),subscriptionProtocol:(p=r.subscription_protocol)!=null?p:"ws",websocketSubprotocol:r.subscription_protocol==="ws"?r.websocketSubprotocol||"auto":void 0,schema:o,configurationDataByTypeName:c}})}).toJsonString()}return om(vde);})(); +`:case"\r":case" ":case" ":continue;default:throw Error("invalid base64 string.")}switch(i){case 0:o=a,i=1;break;case 1:n[r++]=o<<2|(a&48)>>4,o=a,i=2;break;case 2:n[r++]=(o&15)<<4|(a&60)>>2,o=a,i=3;break;case 3:n[r++]=(o&3)<<6|a,i=0;break}}if(i==1)throw Error("invalid base64 string.");return n.subarray(0,r)},enc(e){let t="",n=0,r,i=0;for(let a=0;a>2],i=(r&3)<<4,n=1;break;case 1:t+=Ds[i|r>>4],i=(r&15)<<2,n=2;break;case 2:t+=Ds[i|r>>6],t+=Ds[r&63],n=0;break}return n&&(t+=Ds[i],t+="=",n==1&&(t+="=")),t}};m();T();N();function QV(e,t,n){JV(t,e);let r=t.runtime.bin.makeReadOptions(n),i=$V(e.getType().runtime.bin.listUnknownFields(e),t.field),[a,o]=JE(t);for(let c of i)t.runtime.bin.readField(a,r.readerFactory(c.data),t.field,c.wireType,r);return o()}function YV(e,t,n,r){JV(t,e);let i=t.runtime.bin.makeReadOptions(r),a=t.runtime.bin.makeWriteOptions(r);if(TD(e,t)){let p=e.getType().runtime.bin.listUnknownFields(e).filter(f=>f.no!=t.field.no);e.getType().runtime.bin.discardUnknownFields(e);for(let f of p)e.getType().runtime.bin.onUnknownField(e,f.no,f.wireType,f.data)}let o=a.writerFactory(),c=t.field;!c.opt&&!c.repeated&&(c.kind=="enum"||c.kind=="scalar")&&(c=Object.assign(Object.assign({},t.field),{opt:!0})),t.runtime.bin.writeField(c,n,o,a);let l=i.readerFactory(o.finish());for(;l.posr.no==t.field.no)}function JV(e,t){sn(e.extendee.typeName==t.getType().typeName,`extension ${e.typeName} can only be applied to message ${e.extendee.typeName}`)}m();T();N();function zE(e,t){let n=e.localName;if(e.repeated)return t[n].length>0;if(e.oneof)return t[e.oneof.localName].case===n;switch(e.kind){case"enum":case"scalar":return e.opt||e.req?t[n]!==void 0:e.kind=="enum"?t[n]!==e.T.values[0].no:!$E(e.T,t[n]);case"message":return t[n]!==void 0;case"map":return Object.keys(t[n]).length>0}}function ED(e,t){let n=e.localName,r=!e.opt&&!e.req;if(e.repeated)t[n]=[];else if(e.oneof)t[e.oneof.localName]={case:void 0};else switch(e.kind){case"map":t[n]={};break;case"enum":t[n]=r?e.T.values[0].no:void 0;break;case"scalar":t[n]=r?Ta(e.T,e.L):void 0;break;case"message":t[n]=void 0;break}}m();T();N();m();T();N();function Ea(e,t){if(e===null||typeof e!="object"||!Object.getOwnPropertyNames(Le.prototype).every(r=>r in e&&typeof e[r]=="function"))return!1;let n=e.getType();return n===null||typeof n!="function"||!("typeName"in n)||typeof n.typeName!="string"?!1:t===void 0?!0:n.typeName==t.typeName}function WE(e,t){return Ea(t)||!e.fieldWrapper?t:e.fieldWrapper.wrapField(t)}var CMe={"google.protobuf.DoubleValue":Ne.DOUBLE,"google.protobuf.FloatValue":Ne.FLOAT,"google.protobuf.Int64Value":Ne.INT64,"google.protobuf.UInt64Value":Ne.UINT64,"google.protobuf.Int32Value":Ne.INT32,"google.protobuf.UInt32Value":Ne.UINT32,"google.protobuf.BoolValue":Ne.BOOL,"google.protobuf.StringValue":Ne.STRING,"google.protobuf.BytesValue":Ne.BYTES};var HV={ignoreUnknownFields:!1},zV={emitDefaultValues:!1,enumAsInteger:!1,useProtoFieldName:!1,prettySpaces:0};function rde(e){return e?Object.assign(Object.assign({},HV),e):HV}function ide(e){return e?Object.assign(Object.assign({},zV),e):zV}var eh=Symbol(),XE=Symbol();function ZV(){return{makeReadOptions:rde,makeWriteOptions:ide,readMessage(e,t,n,r){if(t==null||Array.isArray(t)||typeof t!="object")throw new Error(`cannot decode message ${e.typeName} from JSON: ${Ja(t)}`);r=r!=null?r:new e;let i=new Map,a=n.typeRegistry;for(let[o,c]of Object.entries(t)){let l=e.fields.findJsonName(o);if(l){if(l.oneof){if(c===null&&l.kind=="scalar")continue;let p=i.get(l.oneof);if(p!==void 0)throw new Error(`cannot decode message ${e.typeName} from JSON: multiple keys for oneof "${l.oneof.name}" present: "${p}", "${o}"`);i.set(l.oneof,o)}WV(r,c,l,n,e)}else{let p=!1;if(a!=null&&a.findExtension&&o.startsWith("[")&&o.endsWith("]")){let f=a.findExtension(o.substring(1,o.length-1));if(f&&f.extendee.typeName==e.typeName){p=!0;let[y,g]=JE(f);WV(y,c,f.field,n,f),YV(r,f,g(),n)}}if(!p&&!n.ignoreUnknownFields)throw new Error(`cannot decode message ${e.typeName} from JSON: key "${o}" is unknown`)}}return r},writeMessage(e,t){let n=e.getType(),r={},i;try{for(i of n.fields.byNumber()){if(!zE(i,e)){if(i.req)throw"required field not set";if(!t.emitDefaultValues||!sde(i))continue}let o=i.oneof?e[i.oneof.localName].value:e[i.localName],c=XV(i,o,t);c!==void 0&&(r[t.useProtoFieldName?i.name:i.jsonName]=c)}let a=t.typeRegistry;if(a!=null&&a.findExtensionFor)for(let o of n.runtime.bin.listUnknownFields(e)){let c=a.findExtensionFor(n.typeName,o.no);if(c&&TD(e,c)){let l=QV(e,c,t),p=XV(c.field,l,t);p!==void 0&&(r[c.field.jsonName]=p)}}}catch(a){let o=i?`cannot encode field ${n.typeName}.${i.name} to JSON`:`cannot encode message ${n.typeName} to JSON`,c=a instanceof Error?a.message:String(a);throw new Error(o+(c.length>0?`: ${c}`:""))}return r},readScalar(e,t,n){return Xp(e,t,n!=null?n:Na.BIGINT,!0)},writeScalar(e,t,n){if(t!==void 0&&(n||$E(e,t)))return ZE(e,t)},debug:Ja}}function Ja(e){if(e===null)return"null";switch(typeof e){case"object":return Array.isArray(e)?"array":"object";case"string":return e.length>100?"string":`"${e.split('"').join('\\"')}"`;default:return String(e)}}function WV(e,t,n,r,i){let a=n.localName;if(n.repeated){if(sn(n.kind!="map"),t===null)return;if(!Array.isArray(t))throw new Error(`cannot decode field ${i.typeName}.${n.name} from JSON: ${Ja(t)}`);let o=e[a];for(let c of t){if(c===null)throw new Error(`cannot decode field ${i.typeName}.${n.name} from JSON: ${Ja(c)}`);switch(n.kind){case"message":o.push(n.T.fromJson(c,r));break;case"enum":let l=hD(n.T,c,r.ignoreUnknownFields,!0);l!==XE&&o.push(l);break;case"scalar":try{o.push(Xp(n.T,c,n.L,!0))}catch(p){let f=`cannot decode field ${i.typeName}.${n.name} from JSON: ${Ja(c)}`;throw p instanceof Error&&p.message.length>0&&(f+=`: ${p.message}`),new Error(f)}break}}}else if(n.kind=="map"){if(t===null)return;if(typeof t!="object"||Array.isArray(t))throw new Error(`cannot decode field ${i.typeName}.${n.name} from JSON: ${Ja(t)}`);let o=e[a];for(let[c,l]of Object.entries(t)){if(l===null)throw new Error(`cannot decode field ${i.typeName}.${n.name} from JSON: map value null`);let p;try{p=ade(n.K,c)}catch(f){let y=`cannot decode map key for field ${i.typeName}.${n.name} from JSON: ${Ja(t)}`;throw f instanceof Error&&f.message.length>0&&(y+=`: ${f.message}`),new Error(y)}switch(n.V.kind){case"message":o[p]=n.V.T.fromJson(l,r);break;case"enum":let f=hD(n.V.T,l,r.ignoreUnknownFields,!0);f!==XE&&(o[p]=f);break;case"scalar":try{o[p]=Xp(n.V.T,l,Na.BIGINT,!0)}catch(y){let g=`cannot decode map value for field ${i.typeName}.${n.name} from JSON: ${Ja(t)}`;throw y instanceof Error&&y.message.length>0&&(g+=`: ${y.message}`),new Error(g)}break}}}else switch(n.oneof&&(e=e[n.oneof.localName]={case:a},a="value"),n.kind){case"message":let o=n.T;if(t===null&&o.typeName!="google.protobuf.Value")return;let c=e[a];Ea(c)?c.fromJson(t,r):(e[a]=c=o.fromJson(t,r),o.fieldWrapper&&!n.oneof&&(e[a]=o.fieldWrapper.unwrapField(c)));break;case"enum":let l=hD(n.T,t,r.ignoreUnknownFields,!1);switch(l){case eh:ED(n,e);break;case XE:break;default:e[a]=l;break}break;case"scalar":try{let p=Xp(n.T,t,n.L,!1);switch(p){case eh:ED(n,e);break;default:e[a]=p;break}}catch(p){let f=`cannot decode field ${i.typeName}.${n.name} from JSON: ${Ja(t)}`;throw p instanceof Error&&p.message.length>0&&(f+=`: ${p.message}`),new Error(f)}break}}function ade(e,t){if(e===Ne.BOOL)switch(t){case"true":t=!0;break;case"false":t=!1;break}return Xp(e,t,Na.BIGINT,!0).toString()}function Xp(e,t,n,r){if(t===null)return r?Ta(e,n):eh;switch(e){case Ne.DOUBLE:case Ne.FLOAT:if(t==="NaN")return Number.NaN;if(t==="Infinity")return Number.POSITIVE_INFINITY;if(t==="-Infinity")return Number.NEGATIVE_INFINITY;if(t===""||typeof t=="string"&&t.trim().length!==t.length||typeof t!="string"&&typeof t!="number")break;let i=Number(t);if(Number.isNaN(i)||!Number.isFinite(i))break;return e==Ne.FLOAT&&jE(i),i;case Ne.INT32:case Ne.FIXED32:case Ne.SFIXED32:case Ne.SINT32:case Ne.UINT32:let a;if(typeof t=="number"?a=t:typeof t=="string"&&t.length>0&&t.trim().length===t.length&&(a=Number(t)),a===void 0)break;return e==Ne.UINT32||e==Ne.FIXED32?Wp(a):zl(a),a;case Ne.INT64:case Ne.SFIXED64:case Ne.SINT64:if(typeof t!="number"&&typeof t!="string")break;let o=Kn.parse(t);return n?o.toString():o;case Ne.FIXED64:case Ne.UINT64:if(typeof t!="number"&&typeof t!="string")break;let c=Kn.uParse(t);return n?c.toString():c;case Ne.BOOL:if(typeof t!="boolean")break;return t;case Ne.STRING:if(typeof t!="string")break;try{encodeURIComponent(t)}catch(l){throw new Error("invalid UTF8")}return t;case Ne.BYTES:if(t==="")return new Uint8Array(0);if(typeof t!="string")break;return ND.dec(t)}throw new Error}function hD(e,t,n,r){if(t===null)return e.typeName=="google.protobuf.NullValue"?0:r?e.values[0].no:eh;switch(typeof t){case"number":if(Number.isInteger(t))return t;break;case"string":let i=e.findName(t);if(i!==void 0)return i.no;if(n)return XE;break}throw new Error(`cannot decode enum ${e.typeName} from JSON: ${Ja(t)}`)}function sde(e){return e.repeated||e.kind=="map"?!0:!(e.oneof||e.kind=="message"||e.opt||e.req)}function XV(e,t,n){if(e.kind=="map"){sn(typeof t=="object"&&t!=null);let r={},i=Object.entries(t);switch(e.V.kind){case"scalar":for(let[o,c]of i)r[o.toString()]=ZE(e.V.T,c);break;case"message":for(let[o,c]of i)r[o.toString()]=c.toJson(n);break;case"enum":let a=e.V.T;for(let[o,c]of i)r[o.toString()]=yD(a,c,n.enumAsInteger);break}return n.emitDefaultValues||i.length>0?r:void 0}if(e.repeated){sn(Array.isArray(t));let r=[];switch(e.kind){case"scalar":for(let i=0;i0?r:void 0}switch(e.kind){case"scalar":return ZE(e.T,t);case"enum":return yD(e.T,t,n.enumAsInteger);case"message":return WE(e.T,t).toJson(n)}}function yD(e,t,n){var r;if(sn(typeof t=="number"),e.typeName=="google.protobuf.NullValue")return null;if(n)return t;let i=e.findNumber(t);return(r=i==null?void 0:i.name)!==null&&r!==void 0?r:t}function ZE(e,t){switch(e){case Ne.INT32:case Ne.SFIXED32:case Ne.SINT32:case Ne.FIXED32:case Ne.UINT32:return sn(typeof t=="number"),t;case Ne.FLOAT:case Ne.DOUBLE:return sn(typeof t=="number"),Number.isNaN(t)?"NaN":t===Number.POSITIVE_INFINITY?"Infinity":t===Number.NEGATIVE_INFINITY?"-Infinity":t;case Ne.STRING:return sn(typeof t=="string"),t;case Ne.BOOL:return sn(typeof t=="boolean"),t;case Ne.UINT64:case Ne.FIXED64:case Ne.INT64:case Ne.SFIXED64:case Ne.SINT64:return sn(typeof t=="bigint"||typeof t=="string"||typeof t=="number"),t.toString();case Ne.BYTES:return sn(t instanceof Uint8Array),ND.enc(t)}}m();T();N();var Wl=Symbol("@bufbuild/protobuf/unknown-fields"),e1={readUnknownFields:!0,readerFactory:e=>new YE(e)},t1={writeUnknownFields:!0,writerFactory:()=>new QE};function ode(e){return e?Object.assign(Object.assign({},e1),e):e1}function ude(e){return e?Object.assign(Object.assign({},t1),e):t1}function a1(){return{makeReadOptions:ode,makeWriteOptions:ude,listUnknownFields(e){var t;return(t=e[Wl])!==null&&t!==void 0?t:[]},discardUnknownFields(e){delete e[Wl]},writeUnknownFields(e,t){let r=e[Wl];if(r)for(let i of r)t.tag(i.no,i.wireType).raw(i.data)},onUnknownField(e,t,n,r){let i=e;Array.isArray(i[Wl])||(i[Wl]=[]),i[Wl].push({no:t,wireType:n,data:r})},readMessage(e,t,n,r,i){let a=e.getType(),o=i?t.len:t.pos+n,c,l;for(;t.pos0&&(l=lde),a){let g=e[o];if(r==Bn.LengthDelimited&&c!=Ne.STRING&&c!=Ne.BYTES){let P=t.uint32()+t.pos;for(;t.posEa(g,y)?g:new y(g));else{let g=o[i];y.fieldWrapper?y.typeName==="google.protobuf.BytesValue"?a[i]=ef(g):a[i]=g:a[i]=Ea(g,y)?g:new y(g)}break}}},equals(e,t,n){return t===n?!0:!t||!n?!1:e.fields.byMember().every(r=>{let i=t[r.localName],a=n[r.localName];if(r.repeated){if(i.length!==a.length)return!1;switch(r.kind){case"message":return i.every((o,c)=>r.T.equals(o,a[c]));case"scalar":return i.every((o,c)=>Os(r.T,o,a[c]));case"enum":return i.every((o,c)=>Os(Ne.INT32,o,a[c]))}throw new Error(`repeated cannot contain ${r.kind}`)}switch(r.kind){case"message":return r.T.equals(i,a);case"enum":return Os(Ne.INT32,i,a);case"scalar":return Os(r.T,i,a);case"oneof":if(i.case!==a.case)return!1;let o=r.findField(i.case);if(o===void 0)return!0;switch(o.kind){case"message":return o.T.equals(i.value,a.value);case"enum":return Os(Ne.INT32,i.value,a.value);case"scalar":return Os(o.T,i.value,a.value)}throw new Error(`oneof cannot contain ${o.kind}`);case"map":let c=Object.keys(i).concat(Object.keys(a));switch(r.V.kind){case"message":let l=r.V.T;return c.every(f=>l.equals(i[f],a[f]));case"enum":return c.every(f=>Os(Ne.INT32,i[f],a[f]));case"scalar":let p=r.V.T;return c.every(f=>Os(p,i[f],a[f]))}break}})},clone(e){let t=e.getType(),n=new t,r=n;for(let i of t.fields.byMember()){let a=e[i.localName],o;if(i.repeated)o=a.map(rh);else if(i.kind=="map"){o=r[i.localName];for(let[c,l]of Object.entries(a))o[c]=rh(l)}else i.kind=="oneof"?o=i.findField(a.case)?{case:a.case,value:rh(a.value)}:{case:void 0}:o=rh(a);r[i.localName]=o}for(let i of t.runtime.bin.listUnknownFields(e))t.runtime.bin.onUnknownField(r,i.no,i.wireType,i.data);return n}}}function rh(e){if(e===void 0)return e;if(Ea(e))return e.clone();if(e instanceof Uint8Array){let t=new Uint8Array(e.byteLength);return t.set(e),t}return e}function ef(e){return e instanceof Uint8Array?e:new Uint8Array(e)}function u1(e,t,n){return{syntax:e,json:ZV(),bin:a1(),util:Object.assign(Object.assign({},o1()),{newFieldList:t,initFields:n}),makeMessageType(r,i,a){return MV(this,r,i,a)},makeEnum:UV,makeEnumType:lD,getEnumType:BV,makeExtension(r,i,a){return GV(this,r,i,a)}}}m();T();N();var ih=class{constructor(t,n){this._fields=t,this._normalizer=n}findJsonName(t){if(!this.jsonNames){let n={};for(let r of this.list())n[r.jsonName]=n[r.name]=r;this.jsonNames=n}return this.jsonNames[t]}find(t){if(!this.numbers){let n={};for(let r of this.list())n[r.no]=r;this.numbers=n}return this.numbers[t]}list(){return this.all||(this.all=this._normalizer(this._fields)),this.all}byNumber(){return this.numbersAsc||(this.numbersAsc=this.list().concat().sort((t,n)=>t.no-n.no)),this.numbersAsc}byMember(){if(!this.members){this.members=[];let t=this.members,n;for(let r of this.list())r.oneof?r.oneof!==n&&(n=r.oneof,t.push(n)):t.push(r)}return this.members}};m();T();N();m();T();N();m();T();N();function ID(e,t){let n=d1(e);return t?n:Tde(Nde(n))}function c1(e){return ID(e,!1)}var l1=d1;function d1(e){let t=!1,n=[];for(let r=0;r`${e}$`,Nde=e=>mde.has(e)?p1(e):e,Tde=e=>fde.has(e)?p1(e):e;var ah=class{constructor(t){this.kind="oneof",this.repeated=!1,this.packed=!1,this.opt=!1,this.req=!1,this.default=void 0,this.fields=[],this.name=t,this.localName=c1(t)}addField(t){sn(t.oneof===this,`field ${t.name} not one of ${this.name}`),this.fields.push(t)}findField(t){if(!this._lookup){this._lookup=Object.create(null);for(let n=0;nnew ih(e,t=>f1(t,!0)),e=>{for(let t of e.getType().fields.byMember()){if(t.opt)continue;let n=t.localName,r=e;if(t.repeated){r[n]=[];continue}switch(t.kind){case"oneof":r[n]={case:void 0};break;case"enum":r[n]=0;break;case"map":r[n]={};break;case"scalar":r[n]=Ta(t.T,t.L);break;case"message":break}}});var Xl;(function(e){e[e.OK=0]="OK",e[e.ERR=1]="ERR",e[e.ERR_NOT_FOUND=2]="ERR_NOT_FOUND",e[e.ERR_ALREADY_EXISTS=3]="ERR_ALREADY_EXISTS",e[e.ERR_INVALID_SUBGRAPH_SCHEMA=4]="ERR_INVALID_SUBGRAPH_SCHEMA",e[e.ERR_SUBGRAPH_COMPOSITION_FAILED=5]="ERR_SUBGRAPH_COMPOSITION_FAILED",e[e.ERR_SUBGRAPH_CHECK_FAILED=6]="ERR_SUBGRAPH_CHECK_FAILED",e[e.ERR_INVALID_LABELS=7]="ERR_INVALID_LABELS",e[e.ERR_ANALYTICS_DISABLED=8]="ERR_ANALYTICS_DISABLED",e[e.ERROR_NOT_AUTHENTICATED=9]="ERROR_NOT_AUTHENTICATED",e[e.ERR_OPENAI_DISABLED=10]="ERR_OPENAI_DISABLED",e[e.ERR_FREE_TRIAL_EXPIRED=11]="ERR_FREE_TRIAL_EXPIRED",e[e.ERROR_NOT_AUTHORIZED=12]="ERROR_NOT_AUTHORIZED",e[e.ERR_LIMIT_REACHED=13]="ERR_LIMIT_REACHED",e[e.ERR_DEPLOYMENT_FAILED=14]="ERR_DEPLOYMENT_FAILED",e[e.ERR_INVALID_NAME=15]="ERR_INVALID_NAME",e[e.ERR_UPGRADE_PLAN=16]="ERR_UPGRADE_PLAN",e[e.ERR_BAD_REQUEST=17]="ERR_BAD_REQUEST",e[e.ERR_SCHEMA_MISMATCH_WITH_APPROVED_PROPOSAL=18]="ERR_SCHEMA_MISMATCH_WITH_APPROVED_PROPOSAL"})(Xl||(Xl={}));B.util.setEnumType(Xl,"wg.cosmo.common.EnumStatusCode",[{no:0,name:"OK"},{no:1,name:"ERR"},{no:2,name:"ERR_NOT_FOUND"},{no:3,name:"ERR_ALREADY_EXISTS"},{no:4,name:"ERR_INVALID_SUBGRAPH_SCHEMA"},{no:5,name:"ERR_SUBGRAPH_COMPOSITION_FAILED"},{no:6,name:"ERR_SUBGRAPH_CHECK_FAILED"},{no:7,name:"ERR_INVALID_LABELS"},{no:8,name:"ERR_ANALYTICS_DISABLED"},{no:9,name:"ERROR_NOT_AUTHENTICATED"},{no:10,name:"ERR_OPENAI_DISABLED"},{no:11,name:"ERR_FREE_TRIAL_EXPIRED"},{no:12,name:"ERROR_NOT_AUTHORIZED"},{no:13,name:"ERR_LIMIT_REACHED"},{no:14,name:"ERR_DEPLOYMENT_FAILED"},{no:15,name:"ERR_INVALID_NAME"},{no:16,name:"ERR_UPGRADE_PLAN"},{no:17,name:"ERR_BAD_REQUEST"},{no:18,name:"ERR_SCHEMA_MISMATCH_WITH_APPROVED_PROPOSAL"}]);var bs;(function(e){e[e.GRAPHQL_SUBSCRIPTION_PROTOCOL_WS=0]="GRAPHQL_SUBSCRIPTION_PROTOCOL_WS",e[e.GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE=1]="GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE",e[e.GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE_POST=2]="GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE_POST"})(bs||(bs={}));B.util.setEnumType(bs,"wg.cosmo.common.GraphQLSubscriptionProtocol",[{no:0,name:"GRAPHQL_SUBSCRIPTION_PROTOCOL_WS"},{no:1,name:"GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE"},{no:2,name:"GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE_POST"}]);var As;(function(e){e[e.GRAPHQL_WEBSOCKET_SUBPROTOCOL_AUTO=0]="GRAPHQL_WEBSOCKET_SUBPROTOCOL_AUTO",e[e.GRAPHQL_WEBSOCKET_SUBPROTOCOL_WS=1]="GRAPHQL_WEBSOCKET_SUBPROTOCOL_WS",e[e.GRAPHQL_WEBSOCKET_SUBPROTOCOL_TRANSPORT_WS=2]="GRAPHQL_WEBSOCKET_SUBPROTOCOL_TRANSPORT_WS"})(As||(As={}));B.util.setEnumType(As,"wg.cosmo.common.GraphQLWebsocketSubprotocol",[{no:0,name:"GRAPHQL_WEBSOCKET_SUBPROTOCOL_AUTO"},{no:1,name:"GRAPHQL_WEBSOCKET_SUBPROTOCOL_WS"},{no:2,name:"GRAPHQL_WEBSOCKET_SUBPROTOCOL_TRANSPORT_WS"}]);var v1=ss(Ae(),1);m();T();N();var gD;(function(e){e[e.RENDER_ARGUMENT_DEFAULT=0]="RENDER_ARGUMENT_DEFAULT",e[e.RENDER_ARGUMENT_AS_GRAPHQL_VALUE=1]="RENDER_ARGUMENT_AS_GRAPHQL_VALUE",e[e.RENDER_ARGUMENT_AS_ARRAY_CSV=2]="RENDER_ARGUMENT_AS_ARRAY_CSV"})(gD||(gD={}));B.util.setEnumType(gD,"wg.cosmo.node.v1.ArgumentRenderConfiguration",[{no:0,name:"RENDER_ARGUMENT_DEFAULT"},{no:1,name:"RENDER_ARGUMENT_AS_GRAPHQL_VALUE"},{no:2,name:"RENDER_ARGUMENT_AS_ARRAY_CSV"}]);var Dc;(function(e){e[e.OBJECT_FIELD=0]="OBJECT_FIELD",e[e.FIELD_ARGUMENT=1]="FIELD_ARGUMENT"})(Dc||(Dc={}));B.util.setEnumType(Dc,"wg.cosmo.node.v1.ArgumentSource",[{no:0,name:"OBJECT_FIELD"},{no:1,name:"FIELD_ARGUMENT"}]);var yu;(function(e){e[e.STATIC=0]="STATIC",e[e.GRAPHQL=1]="GRAPHQL",e[e.PUBSUB=2]="PUBSUB"})(yu||(yu={}));B.util.setEnumType(yu,"wg.cosmo.node.v1.DataSourceKind",[{no:0,name:"STATIC"},{no:1,name:"GRAPHQL"},{no:2,name:"PUBSUB"}]);var tf;(function(e){e[e.UNSPECIFIED=0]="UNSPECIFIED",e[e.QUERY=1]="QUERY",e[e.MUTATION=2]="MUTATION",e[e.SUBSCRIPTION=3]="SUBSCRIPTION"})(tf||(tf={}));B.util.setEnumType(tf,"wg.cosmo.node.v1.OperationType",[{no:0,name:"OPERATION_TYPE_UNSPECIFIED"},{no:1,name:"OPERATION_TYPE_QUERY"},{no:2,name:"OPERATION_TYPE_MUTATION"},{no:3,name:"OPERATION_TYPE_SUBSCRIPTION"}]);var Uo;(function(e){e[e.PUBLISH=0]="PUBLISH",e[e.REQUEST=1]="REQUEST",e[e.SUBSCRIBE=2]="SUBSCRIBE"})(Uo||(Uo={}));B.util.setEnumType(Uo,"wg.cosmo.node.v1.EventType",[{no:0,name:"PUBLISH"},{no:1,name:"REQUEST"},{no:2,name:"SUBSCRIBE"}]);var Iu;(function(e){e[e.STATIC_CONFIGURATION_VARIABLE=0]="STATIC_CONFIGURATION_VARIABLE",e[e.ENV_CONFIGURATION_VARIABLE=1]="ENV_CONFIGURATION_VARIABLE",e[e.PLACEHOLDER_CONFIGURATION_VARIABLE=2]="PLACEHOLDER_CONFIGURATION_VARIABLE"})(Iu||(Iu={}));B.util.setEnumType(Iu,"wg.cosmo.node.v1.ConfigurationVariableKind",[{no:0,name:"STATIC_CONFIGURATION_VARIABLE"},{no:1,name:"ENV_CONFIGURATION_VARIABLE"},{no:2,name:"PLACEHOLDER_CONFIGURATION_VARIABLE"}]);var bc;(function(e){e[e.GET=0]="GET",e[e.POST=1]="POST",e[e.PUT=2]="PUT",e[e.DELETE=3]="DELETE",e[e.OPTIONS=4]="OPTIONS"})(bc||(bc={}));B.util.setEnumType(bc,"wg.cosmo.node.v1.HTTPMethod",[{no:0,name:"GET"},{no:1,name:"POST"},{no:2,name:"PUT"},{no:3,name:"DELETE"},{no:4,name:"OPTIONS"}]);var Rs=class Rs extends Le{constructor(n){super();_(this,"id","");_(this,"name","");_(this,"routingUrl","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Rs().fromBinary(n,r)}static fromJson(n,r){return new Rs().fromJson(n,r)}static fromJsonString(n,r){return new Rs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Rs,n,r)}};_(Rs,"runtime",B),_(Rs,"typeName","wg.cosmo.node.v1.Subgraph"),_(Rs,"fields",B.util.newFieldList(()=>[{no:1,name:"id",kind:"scalar",T:9},{no:2,name:"name",kind:"scalar",T:9},{no:3,name:"routing_url",kind:"scalar",T:9}]));var sh=Rs,Ps=class Ps extends Le{constructor(n){super();_(this,"configByFeatureFlagName",{});B.util.initPartial(n,this)}static fromBinary(n,r){return new Ps().fromBinary(n,r)}static fromJson(n,r){return new Ps().fromJson(n,r)}static fromJsonString(n,r){return new Ps().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ps,n,r)}};_(Ps,"runtime",B),_(Ps,"typeName","wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs"),_(Ps,"fields",B.util.newFieldList(()=>[{no:1,name:"config_by_feature_flag_name",kind:"map",K:9,V:{kind:"message",T:vD}}]));var _D=Ps,Fs=class Fs extends Le{constructor(n){super();_(this,"engineConfig");_(this,"version","");_(this,"subgraphs",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Fs().fromBinary(n,r)}static fromJson(n,r){return new Fs().fromJson(n,r)}static fromJsonString(n,r){return new Fs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Fs,n,r)}};_(Fs,"runtime",B),_(Fs,"typeName","wg.cosmo.node.v1.FeatureFlagRouterExecutionConfig"),_(Fs,"fields",B.util.newFieldList(()=>[{no:1,name:"engine_config",kind:"message",T:Zl},{no:2,name:"version",kind:"scalar",T:9},{no:3,name:"subgraphs",kind:"message",T:sh,repeated:!0}]));var vD=Fs,ws=class ws extends Le{constructor(n){super();_(this,"engineConfig");_(this,"version","");_(this,"subgraphs",[]);_(this,"featureFlagConfigs");_(this,"compatibilityVersion","");B.util.initPartial(n,this)}static fromBinary(n,r){return new ws().fromBinary(n,r)}static fromJson(n,r){return new ws().fromJson(n,r)}static fromJsonString(n,r){return new ws().fromJsonString(n,r)}static equals(n,r){return B.util.equals(ws,n,r)}};_(ws,"runtime",B),_(ws,"typeName","wg.cosmo.node.v1.RouterConfig"),_(ws,"fields",B.util.newFieldList(()=>[{no:1,name:"engine_config",kind:"message",T:Zl},{no:2,name:"version",kind:"scalar",T:9},{no:3,name:"subgraphs",kind:"message",T:sh,repeated:!0},{no:4,name:"feature_flag_configs",kind:"message",T:_D,opt:!0},{no:5,name:"compatibility_version",kind:"scalar",T:9}]));var nf=ws,Ls=class Ls extends Le{constructor(n){super();_(this,"code",Xl.OK);_(this,"details");B.util.initPartial(n,this)}static fromBinary(n,r){return new Ls().fromBinary(n,r)}static fromJson(n,r){return new Ls().fromJson(n,r)}static fromJsonString(n,r){return new Ls().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ls,n,r)}};_(Ls,"runtime",B),_(Ls,"typeName","wg.cosmo.node.v1.Response"),_(Ls,"fields",B.util.newFieldList(()=>[{no:1,name:"code",kind:"enum",T:B.getEnumType(Xl)},{no:2,name:"details",kind:"scalar",T:9,opt:!0}]));var SD=Ls,Cs=class Cs extends Le{constructor(n){super();_(this,"code",0);_(this,"message","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Cs().fromBinary(n,r)}static fromJson(n,r){return new Cs().fromJson(n,r)}static fromJsonString(n,r){return new Cs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Cs,n,r)}};_(Cs,"runtime",B),_(Cs,"typeName","wg.cosmo.node.v1.ResponseStatus"),_(Cs,"fields",B.util.newFieldList(()=>[{no:1,name:"code",kind:"scalar",T:5},{no:2,name:"message",kind:"scalar",T:9}]));var m1=Cs,Bs=class Bs extends Le{constructor(n){super();_(this,"accountLimits");_(this,"graphPublicKey","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Bs().fromBinary(n,r)}static fromJson(n,r){return new Bs().fromJson(n,r)}static fromJsonString(n,r){return new Bs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Bs,n,r)}};_(Bs,"runtime",B),_(Bs,"typeName","wg.cosmo.node.v1.RegistrationInfo"),_(Bs,"fields",B.util.newFieldList(()=>[{no:1,name:"account_limits",kind:"message",T:DD},{no:2,name:"graph_public_key",kind:"scalar",T:9}]));var OD=Bs,Us=class Us extends Le{constructor(n){super();_(this,"traceSamplingRate",0);B.util.initPartial(n,this)}static fromBinary(n,r){return new Us().fromBinary(n,r)}static fromJson(n,r){return new Us().fromJson(n,r)}static fromJsonString(n,r){return new Us().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Us,n,r)}};_(Us,"runtime",B),_(Us,"typeName","wg.cosmo.node.v1.AccountLimits"),_(Us,"fields",B.util.newFieldList(()=>[{no:1,name:"trace_sampling_rate",kind:"scalar",T:2}]));var DD=Us,ks=class ks extends Le{constructor(t){super(),B.util.initPartial(t,this)}static fromBinary(t,n){return new ks().fromBinary(t,n)}static fromJson(t,n){return new ks().fromJson(t,n)}static fromJsonString(t,n){return new ks().fromJsonString(t,n)}static equals(t,n){return B.util.equals(ks,t,n)}};_(ks,"runtime",B),_(ks,"typeName","wg.cosmo.node.v1.SelfRegisterRequest"),_(ks,"fields",B.util.newFieldList(()=>[]));var N1=ks,Ms=class Ms extends Le{constructor(n){super();_(this,"response");_(this,"registrationInfo");B.util.initPartial(n,this)}static fromBinary(n,r){return new Ms().fromBinary(n,r)}static fromJson(n,r){return new Ms().fromJson(n,r)}static fromJsonString(n,r){return new Ms().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ms,n,r)}};_(Ms,"runtime",B),_(Ms,"typeName","wg.cosmo.node.v1.SelfRegisterResponse"),_(Ms,"fields",B.util.newFieldList(()=>[{no:1,name:"response",kind:"message",T:SD},{no:2,name:"registrationInfo",kind:"message",T:OD,opt:!0}]));var T1=Ms,xs=class xs extends Le{constructor(n){super();_(this,"defaultFlushInterval",Kn.zero);_(this,"datasourceConfigurations",[]);_(this,"fieldConfigurations",[]);_(this,"graphqlSchema","");_(this,"typeConfigurations",[]);_(this,"stringStorage",{});_(this,"graphqlClientSchema");B.util.initPartial(n,this)}static fromBinary(n,r){return new xs().fromBinary(n,r)}static fromJson(n,r){return new xs().fromJson(n,r)}static fromJsonString(n,r){return new xs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(xs,n,r)}};_(xs,"runtime",B),_(xs,"typeName","wg.cosmo.node.v1.EngineConfiguration"),_(xs,"fields",B.util.newFieldList(()=>[{no:1,name:"defaultFlushInterval",kind:"scalar",T:3},{no:2,name:"datasource_configurations",kind:"message",T:rf,repeated:!0},{no:3,name:"field_configurations",kind:"message",T:of,repeated:!0},{no:4,name:"graphqlSchema",kind:"scalar",T:9},{no:5,name:"type_configurations",kind:"message",T:bD,repeated:!0},{no:6,name:"string_storage",kind:"map",K:9,V:{kind:"scalar",T:9}},{no:7,name:"graphql_client_schema",kind:"scalar",T:9,opt:!0}]));var Zl=xs,qs=class qs extends Le{constructor(n){super();_(this,"kind",yu.STATIC);_(this,"rootNodes",[]);_(this,"childNodes",[]);_(this,"overrideFieldPathFromAlias",!1);_(this,"customGraphql");_(this,"customStatic");_(this,"directives",[]);_(this,"requestTimeoutSeconds",Kn.zero);_(this,"id","");_(this,"keys",[]);_(this,"provides",[]);_(this,"requires",[]);_(this,"customEvents");_(this,"entityInterfaces",[]);_(this,"interfaceObjects",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new qs().fromBinary(n,r)}static fromJson(n,r){return new qs().fromJson(n,r)}static fromJsonString(n,r){return new qs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(qs,n,r)}};_(qs,"runtime",B),_(qs,"typeName","wg.cosmo.node.v1.DataSourceConfiguration"),_(qs,"fields",B.util.newFieldList(()=>[{no:1,name:"kind",kind:"enum",T:B.getEnumType(yu)},{no:2,name:"root_nodes",kind:"message",T:ed,repeated:!0},{no:3,name:"child_nodes",kind:"message",T:ed,repeated:!0},{no:4,name:"override_field_path_from_alias",kind:"scalar",T:8},{no:5,name:"custom_graphql",kind:"message",T:lf},{no:6,name:"custom_static",kind:"message",T:MD},{no:7,name:"directives",kind:"message",T:xD,repeated:!0},{no:8,name:"request_timeout_seconds",kind:"scalar",T:3},{no:9,name:"id",kind:"scalar",T:9},{no:10,name:"keys",kind:"message",T:Oc,repeated:!0},{no:11,name:"provides",kind:"message",T:Oc,repeated:!0},{no:12,name:"requires",kind:"message",T:Oc,repeated:!0},{no:13,name:"custom_events",kind:"message",T:Rc},{no:14,name:"entity_interfaces",kind:"message",T:td,repeated:!0},{no:15,name:"interface_objects",kind:"message",T:td,repeated:!0}]));var rf=qs,Vs=class Vs extends Le{constructor(n){super();_(this,"name","");_(this,"sourceType",Dc.OBJECT_FIELD);B.util.initPartial(n,this)}static fromBinary(n,r){return new Vs().fromBinary(n,r)}static fromJson(n,r){return new Vs().fromJson(n,r)}static fromJsonString(n,r){return new Vs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Vs,n,r)}};_(Vs,"runtime",B),_(Vs,"typeName","wg.cosmo.node.v1.ArgumentConfiguration"),_(Vs,"fields",B.util.newFieldList(()=>[{no:1,name:"name",kind:"scalar",T:9},{no:2,name:"source_type",kind:"enum",T:B.getEnumType(Dc)}]));var af=Vs,js=class js extends Le{constructor(n){super();_(this,"requiredAndScopes",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new js().fromBinary(n,r)}static fromJson(n,r){return new js().fromJson(n,r)}static fromJsonString(n,r){return new js().fromJsonString(n,r)}static equals(n,r){return B.util.equals(js,n,r)}};_(js,"runtime",B),_(js,"typeName","wg.cosmo.node.v1.Scopes"),_(js,"fields",B.util.newFieldList(()=>[{no:1,name:"required_and_scopes",kind:"scalar",T:9,repeated:!0}]));var Ac=js,Ks=class Ks extends Le{constructor(n){super();_(this,"requiresAuthentication",!1);_(this,"requiredOrScopes",[]);_(this,"requiredOrScopesByOr",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Ks().fromBinary(n,r)}static fromJson(n,r){return new Ks().fromJson(n,r)}static fromJsonString(n,r){return new Ks().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ks,n,r)}};_(Ks,"runtime",B),_(Ks,"typeName","wg.cosmo.node.v1.AuthorizationConfiguration"),_(Ks,"fields",B.util.newFieldList(()=>[{no:1,name:"requires_authentication",kind:"scalar",T:8},{no:2,name:"required_or_scopes",kind:"message",T:Ac,repeated:!0},{no:3,name:"required_or_scopes_by_or",kind:"message",T:Ac,repeated:!0}]));var sf=Ks,Gs=class Gs extends Le{constructor(n){super();_(this,"typeName","");_(this,"fieldName","");_(this,"argumentsConfiguration",[]);_(this,"authorizationConfiguration");_(this,"subscriptionFilterCondition");B.util.initPartial(n,this)}static fromBinary(n,r){return new Gs().fromBinary(n,r)}static fromJson(n,r){return new Gs().fromJson(n,r)}static fromJsonString(n,r){return new Gs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Gs,n,r)}};_(Gs,"runtime",B),_(Gs,"typeName","wg.cosmo.node.v1.FieldConfiguration"),_(Gs,"fields",B.util.newFieldList(()=>[{no:1,name:"type_name",kind:"scalar",T:9},{no:2,name:"field_name",kind:"scalar",T:9},{no:3,name:"arguments_configuration",kind:"message",T:af,repeated:!0},{no:4,name:"authorization_configuration",kind:"message",T:sf},{no:5,name:"subscription_filter_condition",kind:"message",T:gu,opt:!0}]));var of=Gs,$s=class $s extends Le{constructor(n){super();_(this,"typeName","");_(this,"renameTo","");B.util.initPartial(n,this)}static fromBinary(n,r){return new $s().fromBinary(n,r)}static fromJson(n,r){return new $s().fromJson(n,r)}static fromJsonString(n,r){return new $s().fromJsonString(n,r)}static equals(n,r){return B.util.equals($s,n,r)}};_($s,"runtime",B),_($s,"typeName","wg.cosmo.node.v1.TypeConfiguration"),_($s,"fields",B.util.newFieldList(()=>[{no:1,name:"type_name",kind:"scalar",T:9},{no:2,name:"rename_to",kind:"scalar",T:9}]));var bD=$s,Qs=class Qs extends Le{constructor(n){super();_(this,"typeName","");_(this,"fieldNames",[]);_(this,"externalFieldNames",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Qs().fromBinary(n,r)}static fromJson(n,r){return new Qs().fromJson(n,r)}static fromJsonString(n,r){return new Qs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Qs,n,r)}};_(Qs,"runtime",B),_(Qs,"typeName","wg.cosmo.node.v1.TypeField"),_(Qs,"fields",B.util.newFieldList(()=>[{no:1,name:"type_name",kind:"scalar",T:9},{no:2,name:"field_names",kind:"scalar",T:9,repeated:!0},{no:3,name:"external_field_names",kind:"scalar",T:9,repeated:!0}]));var ed=Qs,Ys=class Ys extends Le{constructor(n){super();_(this,"fieldName","");_(this,"typeName","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Ys().fromBinary(n,r)}static fromJson(n,r){return new Ys().fromJson(n,r)}static fromJsonString(n,r){return new Ys().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ys,n,r)}};_(Ys,"runtime",B),_(Ys,"typeName","wg.cosmo.node.v1.FieldCoordinates"),_(Ys,"fields",B.util.newFieldList(()=>[{no:1,name:"field_name",kind:"scalar",T:9},{no:2,name:"type_name",kind:"scalar",T:9}]));var uf=Ys,Js=class Js extends Le{constructor(n){super();_(this,"fieldCoordinatesPath",[]);_(this,"fieldPath",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Js().fromBinary(n,r)}static fromJson(n,r){return new Js().fromJson(n,r)}static fromJsonString(n,r){return new Js().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Js,n,r)}};_(Js,"runtime",B),_(Js,"typeName","wg.cosmo.node.v1.FieldSetCondition"),_(Js,"fields",B.util.newFieldList(()=>[{no:1,name:"field_coordinates_path",kind:"message",T:uf,repeated:!0},{no:2,name:"field_path",kind:"scalar",T:9,repeated:!0}]));var cf=Js,Hs=class Hs extends Le{constructor(n){super();_(this,"typeName","");_(this,"fieldName","");_(this,"selectionSet","");_(this,"disableEntityResolver",!1);_(this,"conditions",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Hs().fromBinary(n,r)}static fromJson(n,r){return new Hs().fromJson(n,r)}static fromJsonString(n,r){return new Hs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Hs,n,r)}};_(Hs,"runtime",B),_(Hs,"typeName","wg.cosmo.node.v1.RequiredField"),_(Hs,"fields",B.util.newFieldList(()=>[{no:1,name:"type_name",kind:"scalar",T:9},{no:2,name:"field_name",kind:"scalar",T:9},{no:3,name:"selection_set",kind:"scalar",T:9},{no:4,name:"disable_entity_resolver",kind:"scalar",T:8},{no:5,name:"conditions",kind:"message",T:cf,repeated:!0}]));var Oc=Hs,zs=class zs extends Le{constructor(n){super();_(this,"interfaceTypeName","");_(this,"concreteTypeNames",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new zs().fromBinary(n,r)}static fromJson(n,r){return new zs().fromJson(n,r)}static fromJsonString(n,r){return new zs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(zs,n,r)}};_(zs,"runtime",B),_(zs,"typeName","wg.cosmo.node.v1.EntityInterfaceConfiguration"),_(zs,"fields",B.util.newFieldList(()=>[{no:1,name:"interface_type_name",kind:"scalar",T:9},{no:2,name:"concrete_type_names",kind:"scalar",T:9,repeated:!0}]));var td=zs,Ws=class Ws extends Le{constructor(n){super();_(this,"url");_(this,"method",bc.GET);_(this,"header",{});_(this,"body");_(this,"query",[]);_(this,"urlEncodeBody",!1);_(this,"mtls");_(this,"baseUrl");_(this,"path");_(this,"httpProxyUrl");B.util.initPartial(n,this)}static fromBinary(n,r){return new Ws().fromBinary(n,r)}static fromJson(n,r){return new Ws().fromJson(n,r)}static fromJsonString(n,r){return new Ws().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ws,n,r)}};_(Ws,"runtime",B),_(Ws,"typeName","wg.cosmo.node.v1.FetchConfiguration"),_(Ws,"fields",B.util.newFieldList(()=>[{no:1,name:"url",kind:"message",T:Mr},{no:2,name:"method",kind:"enum",T:B.getEnumType(bc)},{no:3,name:"header",kind:"map",K:9,V:{kind:"message",T:VD}},{no:4,name:"body",kind:"message",T:Mr},{no:5,name:"query",kind:"message",T:qD,repeated:!0},{no:7,name:"url_encode_body",kind:"scalar",T:8},{no:8,name:"mtls",kind:"message",T:jD},{no:9,name:"base_url",kind:"message",T:Mr},{no:10,name:"path",kind:"message",T:Mr},{no:11,name:"http_proxy_url",kind:"message",T:Mr,opt:!0}]));var AD=Ws,Xs=class Xs extends Le{constructor(n){super();_(this,"statusCode",Kn.zero);_(this,"typeName","");_(this,"injectStatusCodeIntoBody",!1);B.util.initPartial(n,this)}static fromBinary(n,r){return new Xs().fromBinary(n,r)}static fromJson(n,r){return new Xs().fromJson(n,r)}static fromJsonString(n,r){return new Xs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Xs,n,r)}};_(Xs,"runtime",B),_(Xs,"typeName","wg.cosmo.node.v1.StatusCodeTypeMapping"),_(Xs,"fields",B.util.newFieldList(()=>[{no:1,name:"status_code",kind:"scalar",T:3},{no:2,name:"type_name",kind:"scalar",T:9},{no:3,name:"inject_status_code_into_body",kind:"scalar",T:8}]));var E1=Xs,Zs=class Zs extends Le{constructor(n){super();_(this,"fetch");_(this,"subscription");_(this,"federation");_(this,"upstreamSchema");_(this,"customScalarTypeFields",[]);_(this,"grpc");B.util.initPartial(n,this)}static fromBinary(n,r){return new Zs().fromBinary(n,r)}static fromJson(n,r){return new Zs().fromJson(n,r)}static fromJsonString(n,r){return new Zs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Zs,n,r)}};_(Zs,"runtime",B),_(Zs,"typeName","wg.cosmo.node.v1.DataSourceCustom_GraphQL"),_(Zs,"fields",B.util.newFieldList(()=>[{no:1,name:"fetch",kind:"message",T:AD},{no:2,name:"subscription",kind:"message",T:KD},{no:3,name:"federation",kind:"message",T:GD},{no:4,name:"upstream_schema",kind:"message",T:Tf},{no:6,name:"custom_scalar_type_fields",kind:"message",T:$D,repeated:!0},{no:7,name:"grpc",kind:"message",T:nd}]));var lf=Zs,eo=class eo extends Le{constructor(n){super();_(this,"mapping");_(this,"protoSchema","");_(this,"plugin");B.util.initPartial(n,this)}static fromBinary(n,r){return new eo().fromBinary(n,r)}static fromJson(n,r){return new eo().fromJson(n,r)}static fromJsonString(n,r){return new eo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(eo,n,r)}};_(eo,"runtime",B),_(eo,"typeName","wg.cosmo.node.v1.GRPCConfiguration"),_(eo,"fields",B.util.newFieldList(()=>[{no:1,name:"mapping",kind:"message",T:PD},{no:2,name:"proto_schema",kind:"scalar",T:9},{no:3,name:"plugin",kind:"message",T:df}]));var nd=eo,to=class to extends Le{constructor(n){super();_(this,"repository","");_(this,"reference","");B.util.initPartial(n,this)}static fromBinary(n,r){return new to().fromBinary(n,r)}static fromJson(n,r){return new to().fromJson(n,r)}static fromJsonString(n,r){return new to().fromJsonString(n,r)}static equals(n,r){return B.util.equals(to,n,r)}};_(to,"runtime",B),_(to,"typeName","wg.cosmo.node.v1.ImageReference"),_(to,"fields",B.util.newFieldList(()=>[{no:1,name:"repository",kind:"scalar",T:9},{no:2,name:"reference",kind:"scalar",T:9}]));var RD=to,no=class no extends Le{constructor(n){super();_(this,"name","");_(this,"version","");_(this,"imageReference");B.util.initPartial(n,this)}static fromBinary(n,r){return new no().fromBinary(n,r)}static fromJson(n,r){return new no().fromJson(n,r)}static fromJsonString(n,r){return new no().fromJsonString(n,r)}static equals(n,r){return B.util.equals(no,n,r)}};_(no,"runtime",B),_(no,"typeName","wg.cosmo.node.v1.PluginConfiguration"),_(no,"fields",B.util.newFieldList(()=>[{no:1,name:"name",kind:"scalar",T:9},{no:2,name:"version",kind:"scalar",T:9},{no:3,name:"image_reference",kind:"message",T:RD,opt:!0}]));var df=no,ro=class ro extends Le{constructor(n){super();_(this,"enabled",!1);B.util.initPartial(n,this)}static fromBinary(n,r){return new ro().fromBinary(n,r)}static fromJson(n,r){return new ro().fromJson(n,r)}static fromJsonString(n,r){return new ro().fromJsonString(n,r)}static equals(n,r){return B.util.equals(ro,n,r)}};_(ro,"runtime",B),_(ro,"typeName","wg.cosmo.node.v1.SSLConfiguration"),_(ro,"fields",B.util.newFieldList(()=>[{no:1,name:"enabled",kind:"scalar",T:8}]));var h1=ro,io=class io extends Le{constructor(n){super();_(this,"version",0);_(this,"service","");_(this,"operationMappings",[]);_(this,"entityMappings",[]);_(this,"typeFieldMappings",[]);_(this,"enumMappings",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new io().fromBinary(n,r)}static fromJson(n,r){return new io().fromJson(n,r)}static fromJsonString(n,r){return new io().fromJsonString(n,r)}static equals(n,r){return B.util.equals(io,n,r)}};_(io,"runtime",B),_(io,"typeName","wg.cosmo.node.v1.GRPCMapping"),_(io,"fields",B.util.newFieldList(()=>[{no:1,name:"version",kind:"scalar",T:5},{no:2,name:"service",kind:"scalar",T:9},{no:3,name:"operation_mappings",kind:"message",T:FD,repeated:!0},{no:4,name:"entity_mappings",kind:"message",T:wD,repeated:!0},{no:5,name:"type_field_mappings",kind:"message",T:LD,repeated:!0},{no:6,name:"enum_mappings",kind:"message",T:UD,repeated:!0}]));var PD=io,ao=class ao extends Le{constructor(n){super();_(this,"type",tf.UNSPECIFIED);_(this,"original","");_(this,"mapped","");_(this,"request","");_(this,"response","");B.util.initPartial(n,this)}static fromBinary(n,r){return new ao().fromBinary(n,r)}static fromJson(n,r){return new ao().fromJson(n,r)}static fromJsonString(n,r){return new ao().fromJsonString(n,r)}static equals(n,r){return B.util.equals(ao,n,r)}};_(ao,"runtime",B),_(ao,"typeName","wg.cosmo.node.v1.OperationMapping"),_(ao,"fields",B.util.newFieldList(()=>[{no:1,name:"type",kind:"enum",T:B.getEnumType(tf)},{no:2,name:"original",kind:"scalar",T:9},{no:3,name:"mapped",kind:"scalar",T:9},{no:4,name:"request",kind:"scalar",T:9},{no:5,name:"response",kind:"scalar",T:9}]));var FD=ao,so=class so extends Le{constructor(n){super();_(this,"typeName","");_(this,"kind","");_(this,"key","");_(this,"rpc","");_(this,"request","");_(this,"response","");B.util.initPartial(n,this)}static fromBinary(n,r){return new so().fromBinary(n,r)}static fromJson(n,r){return new so().fromJson(n,r)}static fromJsonString(n,r){return new so().fromJsonString(n,r)}static equals(n,r){return B.util.equals(so,n,r)}};_(so,"runtime",B),_(so,"typeName","wg.cosmo.node.v1.EntityMapping"),_(so,"fields",B.util.newFieldList(()=>[{no:1,name:"type_name",kind:"scalar",T:9},{no:2,name:"kind",kind:"scalar",T:9},{no:3,name:"key",kind:"scalar",T:9},{no:4,name:"rpc",kind:"scalar",T:9},{no:5,name:"request",kind:"scalar",T:9},{no:6,name:"response",kind:"scalar",T:9}]));var wD=so,oo=class oo extends Le{constructor(n){super();_(this,"type","");_(this,"fieldMappings",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new oo().fromBinary(n,r)}static fromJson(n,r){return new oo().fromJson(n,r)}static fromJsonString(n,r){return new oo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(oo,n,r)}};_(oo,"runtime",B),_(oo,"typeName","wg.cosmo.node.v1.TypeFieldMapping"),_(oo,"fields",B.util.newFieldList(()=>[{no:1,name:"type",kind:"scalar",T:9},{no:2,name:"field_mappings",kind:"message",T:CD,repeated:!0}]));var LD=oo,uo=class uo extends Le{constructor(n){super();_(this,"original","");_(this,"mapped","");_(this,"argumentMappings",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new uo().fromBinary(n,r)}static fromJson(n,r){return new uo().fromJson(n,r)}static fromJsonString(n,r){return new uo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(uo,n,r)}};_(uo,"runtime",B),_(uo,"typeName","wg.cosmo.node.v1.FieldMapping"),_(uo,"fields",B.util.newFieldList(()=>[{no:1,name:"original",kind:"scalar",T:9},{no:2,name:"mapped",kind:"scalar",T:9},{no:3,name:"argument_mappings",kind:"message",T:BD,repeated:!0}]));var CD=uo,co=class co extends Le{constructor(n){super();_(this,"original","");_(this,"mapped","");B.util.initPartial(n,this)}static fromBinary(n,r){return new co().fromBinary(n,r)}static fromJson(n,r){return new co().fromJson(n,r)}static fromJsonString(n,r){return new co().fromJsonString(n,r)}static equals(n,r){return B.util.equals(co,n,r)}};_(co,"runtime",B),_(co,"typeName","wg.cosmo.node.v1.ArgumentMapping"),_(co,"fields",B.util.newFieldList(()=>[{no:1,name:"original",kind:"scalar",T:9},{no:2,name:"mapped",kind:"scalar",T:9}]));var BD=co,lo=class lo extends Le{constructor(n){super();_(this,"type","");_(this,"values",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new lo().fromBinary(n,r)}static fromJson(n,r){return new lo().fromJson(n,r)}static fromJsonString(n,r){return new lo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(lo,n,r)}};_(lo,"runtime",B),_(lo,"typeName","wg.cosmo.node.v1.EnumMapping"),_(lo,"fields",B.util.newFieldList(()=>[{no:1,name:"type",kind:"scalar",T:9},{no:2,name:"values",kind:"message",T:kD,repeated:!0}]));var UD=lo,po=class po extends Le{constructor(n){super();_(this,"original","");_(this,"mapped","");B.util.initPartial(n,this)}static fromBinary(n,r){return new po().fromBinary(n,r)}static fromJson(n,r){return new po().fromJson(n,r)}static fromJsonString(n,r){return new po().fromJsonString(n,r)}static equals(n,r){return B.util.equals(po,n,r)}};_(po,"runtime",B),_(po,"typeName","wg.cosmo.node.v1.EnumValueMapping"),_(po,"fields",B.util.newFieldList(()=>[{no:1,name:"original",kind:"scalar",T:9},{no:2,name:"mapped",kind:"scalar",T:9}]));var kD=po,fo=class fo extends Le{constructor(n){super();_(this,"consumerName","");_(this,"streamName","");_(this,"consumerInactiveThreshold",0);B.util.initPartial(n,this)}static fromBinary(n,r){return new fo().fromBinary(n,r)}static fromJson(n,r){return new fo().fromJson(n,r)}static fromJsonString(n,r){return new fo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(fo,n,r)}};_(fo,"runtime",B),_(fo,"typeName","wg.cosmo.node.v1.NatsStreamConfiguration"),_(fo,"fields",B.util.newFieldList(()=>[{no:1,name:"consumer_name",kind:"scalar",T:9},{no:2,name:"stream_name",kind:"scalar",T:9},{no:3,name:"consumer_inactive_threshold",kind:"scalar",T:5}]));var pf=fo,mo=class mo extends Le{constructor(n){super();_(this,"engineEventConfiguration");_(this,"subjects",[]);_(this,"streamConfiguration");B.util.initPartial(n,this)}static fromBinary(n,r){return new mo().fromBinary(n,r)}static fromJson(n,r){return new mo().fromJson(n,r)}static fromJsonString(n,r){return new mo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(mo,n,r)}};_(mo,"runtime",B),_(mo,"typeName","wg.cosmo.node.v1.NatsEventConfiguration"),_(mo,"fields",B.util.newFieldList(()=>[{no:1,name:"engine_event_configuration",kind:"message",T:ko},{no:2,name:"subjects",kind:"scalar",T:9,repeated:!0},{no:3,name:"stream_configuration",kind:"message",T:pf}]));var ff=mo,No=class No extends Le{constructor(n){super();_(this,"engineEventConfiguration");_(this,"topics",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new No().fromBinary(n,r)}static fromJson(n,r){return new No().fromJson(n,r)}static fromJsonString(n,r){return new No().fromJsonString(n,r)}static equals(n,r){return B.util.equals(No,n,r)}};_(No,"runtime",B),_(No,"typeName","wg.cosmo.node.v1.KafkaEventConfiguration"),_(No,"fields",B.util.newFieldList(()=>[{no:1,name:"engine_event_configuration",kind:"message",T:ko},{no:2,name:"topics",kind:"scalar",T:9,repeated:!0}]));var mf=No,To=class To extends Le{constructor(n){super();_(this,"engineEventConfiguration");_(this,"channels",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new To().fromBinary(n,r)}static fromJson(n,r){return new To().fromJson(n,r)}static fromJsonString(n,r){return new To().fromJsonString(n,r)}static equals(n,r){return B.util.equals(To,n,r)}};_(To,"runtime",B),_(To,"typeName","wg.cosmo.node.v1.RedisEventConfiguration"),_(To,"fields",B.util.newFieldList(()=>[{no:1,name:"engine_event_configuration",kind:"message",T:ko},{no:2,name:"channels",kind:"scalar",T:9,repeated:!0}]));var Nf=To,Eo=class Eo extends Le{constructor(n){super();_(this,"providerId","");_(this,"type",Uo.PUBLISH);_(this,"typeName","");_(this,"fieldName","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Eo().fromBinary(n,r)}static fromJson(n,r){return new Eo().fromJson(n,r)}static fromJsonString(n,r){return new Eo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Eo,n,r)}};_(Eo,"runtime",B),_(Eo,"typeName","wg.cosmo.node.v1.EngineEventConfiguration"),_(Eo,"fields",B.util.newFieldList(()=>[{no:1,name:"provider_id",kind:"scalar",T:9},{no:2,name:"type",kind:"enum",T:B.getEnumType(Uo)},{no:3,name:"type_name",kind:"scalar",T:9},{no:4,name:"field_name",kind:"scalar",T:9}]));var ko=Eo,ho=class ho extends Le{constructor(n){super();_(this,"nats",[]);_(this,"kafka",[]);_(this,"redis",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new ho().fromBinary(n,r)}static fromJson(n,r){return new ho().fromJson(n,r)}static fromJsonString(n,r){return new ho().fromJsonString(n,r)}static equals(n,r){return B.util.equals(ho,n,r)}};_(ho,"runtime",B),_(ho,"typeName","wg.cosmo.node.v1.DataSourceCustomEvents"),_(ho,"fields",B.util.newFieldList(()=>[{no:1,name:"nats",kind:"message",T:ff,repeated:!0},{no:2,name:"kafka",kind:"message",T:mf,repeated:!0},{no:3,name:"redis",kind:"message",T:Nf,repeated:!0}]));var Rc=ho,yo=class yo extends Le{constructor(n){super();_(this,"data");B.util.initPartial(n,this)}static fromBinary(n,r){return new yo().fromBinary(n,r)}static fromJson(n,r){return new yo().fromJson(n,r)}static fromJsonString(n,r){return new yo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(yo,n,r)}};_(yo,"runtime",B),_(yo,"typeName","wg.cosmo.node.v1.DataSourceCustom_Static"),_(yo,"fields",B.util.newFieldList(()=>[{no:1,name:"data",kind:"message",T:Mr}]));var MD=yo,Io=class Io extends Le{constructor(n){super();_(this,"kind",Iu.STATIC_CONFIGURATION_VARIABLE);_(this,"staticVariableContent","");_(this,"environmentVariableName","");_(this,"environmentVariableDefaultValue","");_(this,"placeholderVariableName","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Io().fromBinary(n,r)}static fromJson(n,r){return new Io().fromJson(n,r)}static fromJsonString(n,r){return new Io().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Io,n,r)}};_(Io,"runtime",B),_(Io,"typeName","wg.cosmo.node.v1.ConfigurationVariable"),_(Io,"fields",B.util.newFieldList(()=>[{no:1,name:"kind",kind:"enum",T:B.getEnumType(Iu)},{no:2,name:"static_variable_content",kind:"scalar",T:9},{no:3,name:"environment_variable_name",kind:"scalar",T:9},{no:4,name:"environment_variable_default_value",kind:"scalar",T:9},{no:5,name:"placeholder_variable_name",kind:"scalar",T:9}]));var Mr=Io,go=class go extends Le{constructor(n){super();_(this,"directiveName","");_(this,"renameTo","");B.util.initPartial(n,this)}static fromBinary(n,r){return new go().fromBinary(n,r)}static fromJson(n,r){return new go().fromJson(n,r)}static fromJsonString(n,r){return new go().fromJsonString(n,r)}static equals(n,r){return B.util.equals(go,n,r)}};_(go,"runtime",B),_(go,"typeName","wg.cosmo.node.v1.DirectiveConfiguration"),_(go,"fields",B.util.newFieldList(()=>[{no:1,name:"directive_name",kind:"scalar",T:9},{no:2,name:"rename_to",kind:"scalar",T:9}]));var xD=go,_o=class _o extends Le{constructor(n){super();_(this,"name","");_(this,"value","");B.util.initPartial(n,this)}static fromBinary(n,r){return new _o().fromBinary(n,r)}static fromJson(n,r){return new _o().fromJson(n,r)}static fromJsonString(n,r){return new _o().fromJsonString(n,r)}static equals(n,r){return B.util.equals(_o,n,r)}};_(_o,"runtime",B),_(_o,"typeName","wg.cosmo.node.v1.URLQueryConfiguration"),_(_o,"fields",B.util.newFieldList(()=>[{no:1,name:"name",kind:"scalar",T:9},{no:2,name:"value",kind:"scalar",T:9}]));var qD=_o,vo=class vo extends Le{constructor(n){super();_(this,"values",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new vo().fromBinary(n,r)}static fromJson(n,r){return new vo().fromJson(n,r)}static fromJsonString(n,r){return new vo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(vo,n,r)}};_(vo,"runtime",B),_(vo,"typeName","wg.cosmo.node.v1.HTTPHeader"),_(vo,"fields",B.util.newFieldList(()=>[{no:1,name:"values",kind:"message",T:Mr,repeated:!0}]));var VD=vo,So=class So extends Le{constructor(n){super();_(this,"key");_(this,"cert");_(this,"insecureSkipVerify",!1);B.util.initPartial(n,this)}static fromBinary(n,r){return new So().fromBinary(n,r)}static fromJson(n,r){return new So().fromJson(n,r)}static fromJsonString(n,r){return new So().fromJsonString(n,r)}static equals(n,r){return B.util.equals(So,n,r)}};_(So,"runtime",B),_(So,"typeName","wg.cosmo.node.v1.MTLSConfiguration"),_(So,"fields",B.util.newFieldList(()=>[{no:1,name:"key",kind:"message",T:Mr},{no:2,name:"cert",kind:"message",T:Mr},{no:3,name:"insecureSkipVerify",kind:"scalar",T:8}]));var jD=So,Oo=class Oo extends Le{constructor(n){super();_(this,"enabled",!1);_(this,"url");_(this,"useSSE");_(this,"protocol");_(this,"websocketSubprotocol");B.util.initPartial(n,this)}static fromBinary(n,r){return new Oo().fromBinary(n,r)}static fromJson(n,r){return new Oo().fromJson(n,r)}static fromJsonString(n,r){return new Oo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Oo,n,r)}};_(Oo,"runtime",B),_(Oo,"typeName","wg.cosmo.node.v1.GraphQLSubscriptionConfiguration"),_(Oo,"fields",B.util.newFieldList(()=>[{no:1,name:"enabled",kind:"scalar",T:8},{no:2,name:"url",kind:"message",T:Mr},{no:3,name:"useSSE",kind:"scalar",T:8,opt:!0},{no:4,name:"protocol",kind:"enum",T:B.getEnumType(bs),opt:!0},{no:5,name:"websocketSubprotocol",kind:"enum",T:B.getEnumType(As),opt:!0}]));var KD=Oo,Do=class Do extends Le{constructor(n){super();_(this,"enabled",!1);_(this,"serviceSdl","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Do().fromBinary(n,r)}static fromJson(n,r){return new Do().fromJson(n,r)}static fromJsonString(n,r){return new Do().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Do,n,r)}};_(Do,"runtime",B),_(Do,"typeName","wg.cosmo.node.v1.GraphQLFederationConfiguration"),_(Do,"fields",B.util.newFieldList(()=>[{no:1,name:"enabled",kind:"scalar",T:8},{no:2,name:"serviceSdl",kind:"scalar",T:9}]));var GD=Do,bo=class bo extends Le{constructor(n){super();_(this,"key","");B.util.initPartial(n,this)}static fromBinary(n,r){return new bo().fromBinary(n,r)}static fromJson(n,r){return new bo().fromJson(n,r)}static fromJsonString(n,r){return new bo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(bo,n,r)}};_(bo,"runtime",B),_(bo,"typeName","wg.cosmo.node.v1.InternedString"),_(bo,"fields",B.util.newFieldList(()=>[{no:1,name:"key",kind:"scalar",T:9}]));var Tf=bo,Ao=class Ao extends Le{constructor(n){super();_(this,"typeName","");_(this,"fieldName","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Ao().fromBinary(n,r)}static fromJson(n,r){return new Ao().fromJson(n,r)}static fromJsonString(n,r){return new Ao().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ao,n,r)}};_(Ao,"runtime",B),_(Ao,"typeName","wg.cosmo.node.v1.SingleTypeField"),_(Ao,"fields",B.util.newFieldList(()=>[{no:1,name:"type_name",kind:"scalar",T:9},{no:2,name:"field_name",kind:"scalar",T:9}]));var $D=Ao,Ro=class Ro extends Le{constructor(n){super();_(this,"fieldPath",[]);_(this,"json","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Ro().fromBinary(n,r)}static fromJson(n,r){return new Ro().fromJson(n,r)}static fromJsonString(n,r){return new Ro().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ro,n,r)}};_(Ro,"runtime",B),_(Ro,"typeName","wg.cosmo.node.v1.SubscriptionFieldCondition"),_(Ro,"fields",B.util.newFieldList(()=>[{no:1,name:"field_path",kind:"scalar",T:9,repeated:!0},{no:2,name:"json",kind:"scalar",T:9}]));var Ef=Ro,Gi=class Gi extends Le{constructor(n){super();_(this,"and",[]);_(this,"in");_(this,"not");_(this,"or",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Gi().fromBinary(n,r)}static fromJson(n,r){return new Gi().fromJson(n,r)}static fromJsonString(n,r){return new Gi().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Gi,n,r)}};_(Gi,"runtime",B),_(Gi,"typeName","wg.cosmo.node.v1.SubscriptionFilterCondition"),_(Gi,"fields",B.util.newFieldList(()=>[{no:1,name:"and",kind:"message",T:Gi,repeated:!0},{no:2,name:"in",kind:"message",T:Ef,opt:!0},{no:3,name:"not",kind:"message",T:Gi,opt:!0},{no:4,name:"or",kind:"message",T:Gi,repeated:!0}]));var gu=Gi,Po=class Po extends Le{constructor(n){super();_(this,"operations",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Po().fromBinary(n,r)}static fromJson(n,r){return new Po().fromJson(n,r)}static fromJsonString(n,r){return new Po().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Po,n,r)}};_(Po,"runtime",B),_(Po,"typeName","wg.cosmo.node.v1.CacheWarmerOperations"),_(Po,"fields",B.util.newFieldList(()=>[{no:1,name:"operations",kind:"message",T:QD,repeated:!0}]));var y1=Po,Fo=class Fo extends Le{constructor(n){super();_(this,"request");_(this,"client");B.util.initPartial(n,this)}static fromBinary(n,r){return new Fo().fromBinary(n,r)}static fromJson(n,r){return new Fo().fromJson(n,r)}static fromJsonString(n,r){return new Fo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Fo,n,r)}};_(Fo,"runtime",B),_(Fo,"typeName","wg.cosmo.node.v1.Operation"),_(Fo,"fields",B.util.newFieldList(()=>[{no:1,name:"request",kind:"message",T:YD},{no:2,name:"client",kind:"message",T:zD}]));var QD=Fo,wo=class wo extends Le{constructor(n){super();_(this,"operationName","");_(this,"query","");_(this,"extensions");B.util.initPartial(n,this)}static fromBinary(n,r){return new wo().fromBinary(n,r)}static fromJson(n,r){return new wo().fromJson(n,r)}static fromJsonString(n,r){return new wo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(wo,n,r)}};_(wo,"runtime",B),_(wo,"typeName","wg.cosmo.node.v1.OperationRequest"),_(wo,"fields",B.util.newFieldList(()=>[{no:1,name:"operation_name",kind:"scalar",T:9},{no:2,name:"query",kind:"scalar",T:9},{no:3,name:"extensions",kind:"message",T:JD}]));var YD=wo,Lo=class Lo extends Le{constructor(n){super();_(this,"persistedQuery");B.util.initPartial(n,this)}static fromBinary(n,r){return new Lo().fromBinary(n,r)}static fromJson(n,r){return new Lo().fromJson(n,r)}static fromJsonString(n,r){return new Lo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Lo,n,r)}};_(Lo,"runtime",B),_(Lo,"typeName","wg.cosmo.node.v1.Extension"),_(Lo,"fields",B.util.newFieldList(()=>[{no:1,name:"persisted_query",kind:"message",T:HD}]));var JD=Lo,Co=class Co extends Le{constructor(n){super();_(this,"sha256Hash","");_(this,"version",0);B.util.initPartial(n,this)}static fromBinary(n,r){return new Co().fromBinary(n,r)}static fromJson(n,r){return new Co().fromJson(n,r)}static fromJsonString(n,r){return new Co().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Co,n,r)}};_(Co,"runtime",B),_(Co,"typeName","wg.cosmo.node.v1.PersistedQuery"),_(Co,"fields",B.util.newFieldList(()=>[{no:1,name:"sha256_hash",kind:"scalar",T:9},{no:2,name:"version",kind:"scalar",T:5}]));var HD=Co,Bo=class Bo extends Le{constructor(n){super();_(this,"name","");_(this,"version","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Bo().fromBinary(n,r)}static fromJson(n,r){return new Bo().fromJson(n,r)}static fromJsonString(n,r){return new Bo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Bo,n,r)}};_(Bo,"runtime",B),_(Bo,"typeName","wg.cosmo.node.v1.ClientInfo"),_(Bo,"fields",B.util.newFieldList(()=>[{no:1,name:"name",kind:"scalar",T:9},{no:2,name:"version",kind:"scalar",T:9}]));var zD=Bo;m();T();N();function WD(e){return new Error(`Normalization failed to return a ${e}.`)}function I1(e){return new Error(`Invalid router compatibility version "${e}".`)}m();T();N();var rd=ss(BE(),1);function Ede(e){if(!e.conditions)return;let t=[];for(let n of e.conditions){let r=[];for(let i of n.fieldCoordinatesPath){let a=i.split(".");if(a.length!==2)throw new Error(`fatal: malformed conditional field coordinates "${i}" for field set "${e.selectionSet}".`);r.push(new uf({fieldName:a[1],typeName:a[0]}))}t.push(new cf({fieldCoordinatesPath:r,fieldPath:n.fieldPath}))}return t}function XD(e,t,n){if(e)for(let r of e){let i=Ede(r);t.push(new Oc(x(x({typeName:n,fieldName:r.fieldName,selectionSet:r.selectionSet},r.disableEntityResolver?{disableEntityResolver:!0}:{}),i?{conditions:i}:{})))}}function ZD(e){switch(e){case"publish":return Uo.PUBLISH;case"request":return Uo.REQUEST;case"subscribe":return Uo.SUBSCRIBE}}function g1(e){var n;let t={rootNodes:[],childNodes:[],keys:[],provides:[],events:new Rc({nats:[],kafka:[],redis:[]}),requires:[],entityInterfaces:[],interfaceObjects:[]};for(let r of e.values()){let i=r.typeName,a=[...r.fieldNames],o=new ed({typeName:i,fieldNames:a});if(r.externalFieldNames&&r.externalFieldNames.size>0&&(o.externalFieldNames=[...r.externalFieldNames]),r.isRootNode?t.rootNodes.push(o):t.childNodes.push(o),r.entityInterfaceConcreteTypeNames){let f=new td({interfaceTypeName:i,concreteTypeNames:[...r.entityInterfaceConcreteTypeNames]});r.isInterfaceObject?t.interfaceObjects.push(f):t.entityInterfaces.push(f)}XD(r.keys,t.keys,i),XD(r.provides,t.provides,i),XD(r.requires,t.requires,i);let c=[],l=[],p=[];for(let f of(n=r.events)!=null?n:[])switch(f.providerType){case rd.PROVIDER_TYPE_KAFKA:{l.push(new mf({engineEventConfiguration:new ko({fieldName:f.fieldName,providerId:f.providerId,type:ZD(f.type),typeName:i}),topics:f.topics}));break}case rd.PROVIDER_TYPE_NATS:{c.push(new ff(x({engineEventConfiguration:new ko({fieldName:f.fieldName,providerId:f.providerId,type:ZD(f.type),typeName:i}),subjects:f.subjects},f.streamConfiguration?{streamConfiguration:new pf({consumerInactiveThreshold:f.streamConfiguration.consumerInactiveThreshold,consumerName:f.streamConfiguration.consumerName,streamName:f.streamConfiguration.streamName})}:{})));break}case rd.PROVIDER_TYPE_REDIS:{p.push(new Nf({engineEventConfiguration:new ko({fieldName:f.fieldName,providerId:f.providerId,type:ZD(f.type),typeName:i}),channels:f.channels}));break}default:throw new Error("Fatal: Unknown event provider.")}t.events.nats.push(...c),t.events.kafka.push(...l),t.events.redis.push(...p)}return t}function _1(e){var n,r;let t=[];for(let i of e){let a=i.argumentNames.map(f=>new af({name:f,sourceType:Dc.FIELD_ARGUMENT})),o=new of({argumentsConfiguration:a,fieldName:i.fieldName,typeName:i.typeName}),c=((n=i.requiredScopes)==null?void 0:n.map(f=>new Ac({requiredAndScopes:f})))||[],l=((r=i.requiredScopesByOR)==null?void 0:r.map(f=>new Ac({requiredAndScopes:f})))||[],p=c.length>0;if((i.requiresAuthentication||p)&&(o.authorizationConfiguration=new sf({requiresAuthentication:i.requiresAuthentication||p,requiredOrScopes:c,requiredOrScopesByOr:l})),i.subscriptionFilterCondition){let f=new gu;oh(f,i.subscriptionFilterCondition),o.subscriptionFilterCondition=f}t.push(o)}return t}function oh(e,t){if(t.and!==void 0){let n=[];for(let r of t.and){let i=new gu;oh(i,r),n.push(i)}e.and=n;return}if(t.in!==void 0){e.in=new Ef({fieldPath:t.in.fieldPath,json:JSON.stringify(t.in.values)});return}if(t.not!==void 0){e.not=new gu,oh(e.not,t.not);return}if(t.or!==void 0){let n=[];for(let r of t.or){let i=new gu;oh(i,r),n.push(i)}e.or=n;return}throw new Error("Fatal: Incoming SubscriptionCondition object was malformed.")}var Pc;(function(e){e[e.Plugin=0]="Plugin",e[e.Standard=1]="Standard",e[e.GRPC=2]="GRPC"})(Pc||(Pc={}));var hde=(e,t)=>{let n=stringHash(t);return e.stringStorage[n]=t,new Tf({key:n})},yde=e=>{switch(e){case"ws":return bs.GRAPHQL_SUBSCRIPTION_PROTOCOL_WS;case"sse":return bs.GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE;case"sse_post":return bs.GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE_POST}},Ide=e=>{switch(e){case"auto":return As.GRAPHQL_WEBSOCKET_SUBPROTOCOL_AUTO;case"graphql-ws":return As.GRAPHQL_WEBSOCKET_SUBPROTOCOL_WS;case"graphql-transport-ws":return As.GRAPHQL_WEBSOCKET_SUBPROTOCOL_TRANSPORT_WS}},S1=function(e){if(!id.ROUTER_COMPATIBILITY_VERSIONS.has(e.routerCompatibilityVersion))throw I1(e.routerCompatibilityVersion);let t=new Zl({defaultFlushInterval:BigInt(500),datasourceConfigurations:[],fieldConfigurations:[],graphqlSchema:"",stringStorage:{},typeConfigurations:[]});for(let n of e.subgraphs){if(!n.configurationDataByTypeName)throw WD("ConfigurationDataByTypeName");if(!n.schema)throw WD("GraphQLSchema");let r={enabled:!0},i=hde(t,FV((0,v1.lexicographicSortSchema)(n.schema))),{childNodes:a,entityInterfaces:o,events:c,interfaceObjects:l,keys:p,provides:f,requires:y,rootNodes:g}=g1(n.configurationDataByTypeName),v;switch(n.kind){case Pc.Standard:{r.enabled=!0,r.protocol=yde(n.subscriptionProtocol||"ws"),r.websocketSubprotocol=Ide(n.websocketSubprotocol||"auto"),r.url=new Mr({kind:Iu.STATIC_CONFIGURATION_VARIABLE,staticVariableContent:n.subscriptionUrl||n.url});break}case Pc.Plugin:{v=new nd({mapping:n.mapping,protoSchema:n.protoSchema,plugin:new df({name:n.name,version:n.version,imageReference:n.imageReference})});break}case Pc.GRPC:{v=new nd({mapping:n.mapping,protoSchema:n.protoSchema});break}}let P,U,K;if(c.kafka.length>0||c.nats.length>0||c.redis.length>0){P=yu.PUBSUB,K=new Rc({kafka:c.kafka,nats:c.nats,redis:c.redis});let ne=pe=>id.ROOT_TYPE_NAMES.has(pe.typeName),z=0,Te=0;for(;z({id:n.id,name:n.name,routingUrl:n.url})),compatibilityVersion:`${e.routerCompatibilityVersion}:${id.COMPOSITION_VERSION}`})};m();T();N();var wc=ss(Ae());function O1(e){let t;try{t=(0,wc.parse)(e.schema)}catch(n){throw new Error(`could not parse schema for Graph ${e.name}: ${n}`)}return{definitions:t,name:e.name,url:e.url}}function gde(e){let t=(0,Fc.federateSubgraphs)({subgraphs:e.map(O1),version:Fc.LATEST_ROUTER_COMPATIBILITY_VERSION});if(!t.success)throw new Error(`could not federate schema: ${t.errors.map(n=>n.message).join(", ")}`);return{fieldConfigurations:t.fieldConfigurations,sdl:(0,wc.print)(t.federatedGraphAST)}}function _de(e){let t=(0,Fc.federateSubgraphs)({subgraphs:e.map(O1),version:Fc.LATEST_ROUTER_COMPATIBILITY_VERSION});if(!t.success)throw new Error(`could not federate schema: ${t.errors.map(r=>r.message).join(", ")}`);return S1({federatedClientSDL:(0,wc.printSchema)(t.federatedGraphClientSchema),federatedSDL:(0,wc.printSchema)(t.federatedGraphSchema),fieldConfigurations:t.fieldConfigurations,routerCompatibilityVersion:Fc.LATEST_ROUTER_COMPATIBILITY_VERSION,schemaVersionId:"",subgraphs:e.map((r,i)=>{var l,p;let a=t.subgraphConfigBySubgraphName.get(r.name),o=a==null?void 0:a.schema,c=a==null?void 0:a.configurationDataByTypeName;return{kind:Pc.Standard,id:`${i}`,name:r.name,url:sD(r.url),sdl:r.schema,subscriptionUrl:sD((l=r.subscription_url)!=null?l:r.url),subscriptionProtocol:(p=r.subscription_protocol)!=null?p:"ws",websocketSubprotocol:r.subscription_protocol==="ws"?r.websocketSubprotocol||"auto":void 0,schema:o,configurationDataByTypeName:c}})}).toJsonString()}return om(vde);})(); /*! Bundled license information: @jspm/core/nodelibs/browser/buffer.js: diff --git a/composition/src/errors/errors.ts b/composition/src/errors/errors.ts index 26ab47d626..a300e972ac 100644 --- a/composition/src/errors/errors.ts +++ b/composition/src/errors/errors.ts @@ -848,7 +848,8 @@ export function undefinedEntityInterfaceImplementationsError( ): Error { let message = `Federation was unsuccessful because any one subgraph that defines a specific entity interface` + - ` must also define each and every entity object that implements that entity interface.\n`; + ` must also define each and every entity object that implements that entity interface.\n + Each entity object must also each explicitly define the implementation of the entity interface.\n`; for (const [typeName, undefinedImplementations] of invalidEntityInterfacesByTypeName) { const entityInterfaceDatas = getOrThrowError( entityInterfaceFederationDataByTypeName, @@ -864,8 +865,8 @@ export function undefinedEntityInterfaceImplementationsError( `"\n` + ` However, the definition of at least one of these implementations is missing in a subgraph that` + ` defines the entity interface "${typeName}":\n`; - for (const { subgraphName, concreteTypeNames } of undefinedImplementations) { - const disparities = getEntriesNotInHashSet(implementedConcreteTypeNames, concreteTypeNames); + for (const { subgraphName, definedConcreteTypeNames } of undefinedImplementations) { + const disparities = getEntriesNotInHashSet(implementedConcreteTypeNames, definedConcreteTypeNames); message += ` Subgraph "${subgraphName}" does not define the following implementations: "` + disparities.join(QUOTATION_JOIN) + diff --git a/composition/src/utils/types.ts b/composition/src/utils/types.ts index ec069c4d92..856f939ce6 100644 --- a/composition/src/utils/types.ts +++ b/composition/src/utils/types.ts @@ -37,8 +37,9 @@ export type InvalidRequiredInputValueData = { }; export type InvalidEntityInterface = { + definedConcreteTypeNames: Set; + requiredConcreteTypeNames: Set; subgraphName: string; - concreteTypeNames: Set; }; export type InputNodeKind = Kind.ENUM_TYPE_DEFINITION | Kind.INPUT_OBJECT_TYPE_DEFINITION | Kind.SCALAR_TYPE_DEFINITION; diff --git a/composition/src/v1/federation/federation-factory.ts b/composition/src/v1/federation/federation-factory.ts index 133606a698..9e02d6de25 100644 --- a/composition/src/v1/federation/federation-factory.ts +++ b/composition/src/v1/federation/federation-factory.ts @@ -230,7 +230,7 @@ import { InvalidRequiredInputValueData, } from '../../utils/types'; import { FederateSubgraphsContractV1Params, FederateSubgraphsWithContractsV1Params, FederationParams } from './types'; -import { ContractName, FieldCoords, TypeName } from '../../types/types'; +import { ContractName, FieldCoords, SubgraphName, TypeName } from '../../types/types'; export class FederationFactory { authorizationDataByParentTypeName: Map; @@ -1617,7 +1617,7 @@ export class FederationFactory { if (!isObjectDefinitionData(concreteTypeData)) { continue; } - // The subgraph locations of the interface object must be added to the concrete types that implement it + // The subgraph locations of the Interface Object must be added to the concrete types that implement it const entityData = getOrThrowError(this.entityDataByTypeName, concreteTypeName, 'entityDataByTypeName'); entityData.subgraphNames.add(subgraphName); const configurationData = configurationDataByTypeName.get(concreteTypeName); @@ -1673,10 +1673,16 @@ export class FederationFactory { } } const existingFieldData = concreteTypeData.fieldDataByName.get(fieldName); + // @shareable and @external need to be propagated (e.g., to satisfy interfaces) if (existingFieldData) { const isShareable = fieldData.isShareableBySubgraphName.get(subgraphName) ?? false; existingFieldData.isShareableBySubgraphName.set(subgraphName, isShareable); existingFieldData.subgraphNames.add(subgraphName); + const externalData = fieldData.externalFieldDataBySubgraphName.get(subgraphName); + if (!externalData) { + continue; + } + existingFieldData.externalFieldDataBySubgraphName.set(subgraphName, externalData); continue; } const isInaccessible = @@ -3061,18 +3067,31 @@ function initializeFederationFactory({ } } const entityInterfaceErrors = new Array(); + const definedConcreteTypeNamesBySubgraphName = new Map>(); for (const [typeName, entityInterfaceData] of entityInterfaceFederationDataByTypeName) { const implementations = entityInterfaceData.concreteTypeNames.size; for (const [subgraphName, subgraphData] of entityInterfaceData.subgraphDataByTypeName) { + const definedConcreteTypeNames = getValueOrDefault( + definedConcreteTypeNamesBySubgraphName, + subgraphName, + () => new Set(), + ); + addIterableValuesToSet(subgraphData.concreteTypeNames, definedConcreteTypeNames); if (!subgraphData.isInterfaceObject) { if (subgraphData.resolvable && subgraphData.concreteTypeNames.size !== implementations) { - getValueOrDefault(invalidEntityInterfacesByTypeName, typeName, () => []).push({ + getValueOrDefault( + invalidEntityInterfacesByTypeName, + typeName, + () => new Array(), + ).push({ subgraphName, - concreteTypeNames: subgraphData.concreteTypeNames, + definedConcreteTypeNames: new Set(subgraphData.concreteTypeNames), + requiredConcreteTypeNames: new Set(entityInterfaceData.concreteTypeNames), }); } continue; } + addIterableValuesToSet(entityInterfaceData.concreteTypeNames, definedConcreteTypeNames); const { parentDefinitionDataByTypeName } = getOrThrowError( result.internalSubgraphBySubgraphName, subgraphName, @@ -3091,6 +3110,26 @@ function initializeFederationFactory({ } } } + for (const [typeName, invalidInterfaces] of invalidEntityInterfacesByTypeName) { + const checkedInvalidInterfaces = new Array(); + for (const invalidInterface of invalidInterfaces) { + const validTypeNames = definedConcreteTypeNamesBySubgraphName.get(invalidInterface.subgraphName); + if (!validTypeNames) { + checkedInvalidInterfaces.push(invalidInterface); + continue; + } + const definedTypeNames = invalidInterface.requiredConcreteTypeNames.intersection(validTypeNames); + if (invalidInterface.requiredConcreteTypeNames.size !== definedTypeNames.size) { + invalidInterface.definedConcreteTypeNames = definedTypeNames; + checkedInvalidInterfaces.push(invalidInterface); + } + } + if (checkedInvalidInterfaces.length > 0) { + invalidEntityInterfacesByTypeName.set(typeName, checkedInvalidInterfaces); + continue; + } + invalidEntityInterfacesByTypeName.delete(typeName); + } if (invalidEntityInterfacesByTypeName.size > 0) { entityInterfaceErrors.push( undefinedEntityInterfaceImplementationsError( diff --git a/composition/tests/v1/directives/interface-object.test.ts b/composition/tests/v1/directives/interface-object.test.ts index 57081c926c..c23faadf7a 100644 --- a/composition/tests/v1/directives/interface-object.test.ts +++ b/composition/tests/v1/directives/interface-object.test.ts @@ -1,18 +1,23 @@ import { describe, expect, test } from 'vitest'; import { ConfigurationData, + EntityInterfaceFederationData, + EntityInterfaceSubgraphData, FieldData, FieldName, ImplementationErrors, INTERFACE, + InvalidEntityInterface, InvalidFieldImplementation, invalidFieldShareabilityError, invalidInterfaceImplementationError, invalidInterfaceObjectImplementationDefinitionsError, ObjectDefinitionData, ROUTER_COMPATIBILITY_VERSION_ONE, + SimpleFieldData, Subgraph, SubgraphName, + undefinedEntityInterfaceImplementationsError, } from '../../../src'; import { parse } from 'graphql'; import { @@ -675,6 +680,237 @@ describe('@interfaceObject tests', () => { ), ); }); + + test('that @external fields to satisfy an entity Interface are propagated from Interface Object to implementations', () => { + const { federatedGraphSchema } = federateSubgraphsSuccess([fda, fdb], ROUTER_COMPATIBILITY_VERSION_ONE); + expect(schemaToSortedNormalizedString(federatedGraphSchema)).toBe( + normalizeString( + versionTwoRouterDefinitions + + ` + type Entity implements EntityInterfaceA & EntityInterfaceB { + id: ID! + name: String! + newField: String! + } + + interface EntityInterfaceA { + id: ID! + name: String! + } + + interface EntityInterfaceB implements EntityInterfaceA { + id: ID! + name: String! + newField: String! + } + + type Query { + interfacesA: [EntityInterfaceA] + interfacesB: [EntityInterfaceB] + } + + scalar openfed__Scope + `, + ), + ); + }); + + test('that @external fields to satisfy an Interface are propagated from Interface Object to implementations', () => { + const { federatedGraphSchema } = federateSubgraphsSuccess([fda, fdc], ROUTER_COMPATIBILITY_VERSION_ONE); + expect(schemaToSortedNormalizedString(federatedGraphSchema)).toBe( + normalizeString( + versionTwoRouterDefinitions + + ` + type Entity implements EntityInterfaceA & EntityInterfaceB { + id: ID! + name: String! + newField: String! + } + + interface EntityInterfaceA { + id: ID! + name: String! + } + + interface EntityInterfaceB implements EntityInterfaceA { + id: ID! + name: String! + newField: String! + } + + type Query { + interfacesA: [EntityInterfaceA] + interfacesB: [EntityInterfaceB] + } + + scalar openfed__Scope + `, + ), + ); + }); + + test('that an error is returned if implementations of an entity Interface are not included in the graph or through an Interface Object', () => { + const { errors } = federateSubgraphsFailure([fea, feb], ROUTER_COMPATIBILITY_VERSION_ONE); + expect(errors).toHaveLength(1); + expect(errors[0]).toStrictEqual( + undefinedEntityInterfaceImplementationsError( + new Map([ + [ + 'EntityInterfaceA', + [ + { + subgraphName: feb.name, + definedConcreteTypeNames: new Set(['EntityA']), + requiredConcreteTypeNames: new Set(['EntityA', 'EntityB']), + }, + ], + ], + ]), + new Map([ + [ + 'EntityInterfaceA', + { + concreteTypeNames: new Set(['EntityA', 'EntityB']), + fieldDatasBySubgraphName: new Map>(), + interfaceFieldNames: new Set(['id', 'name']), + interfaceObjectFieldNames: new Set(), + interfaceObjectSubgraphs: new Set(), + subgraphDataByTypeName: new Map(), + typeName: 'EntityInterfaceA', + }, + ], + ]), + ), + ); + }); + + test('that multiple Interface Objects can provide the implementations for an entity Interface', () => { + const { federatedGraphSchema } = federateSubgraphsSuccess([ffa, ffb], ROUTER_COMPATIBILITY_VERSION_ONE); + expect(schemaToSortedNormalizedString(federatedGraphSchema)).toBe( + normalizeString( + versionTwoRouterDefinitions + + ` + type EntityA implements EntityInterfaceA & EntityInterfaceB { + id: ID! + name: String! + } + + type EntityB implements EntityInterfaceA { + id: ID! + name: String! + } + + type EntityC implements EntityInterfaceA { + id: ID! + name: String! + } + + type EntityD implements EntityInterfaceC { + id: ID! + name: String! + } + + type EntityE implements EntityInterfaceA & EntityInterfaceC { + id: ID! + name: String! + } + + interface EntityInterfaceA { + id: ID! + name: String! + } + + interface EntityInterfaceB implements EntityInterfaceA { + id: ID! + name: String! + } + + interface EntityInterfaceC { + id: ID! + name: String! + } + + type Query { + interfacesA: [EntityInterfaceA] + interfacesB: [EntityInterfaceB] + interfacesC: [EntityInterfaceC] + } + + scalar openfed__Scope + `, + ), + ); + }); + + test('that an error is returned if implementations of an entity Interface are not included in the graph or through Interface Objects', () => { + const { errors } = federateSubgraphsFailure([ffa, ffc], ROUTER_COMPATIBILITY_VERSION_ONE); + expect(errors).toHaveLength(1); + expect(errors[0]).toStrictEqual( + undefinedEntityInterfaceImplementationsError( + new Map([ + [ + 'EntityInterfaceA', + [ + { + subgraphName: ffc.name, + definedConcreteTypeNames: new Set(['EntityA', 'EntityC', 'EntityE']), + requiredConcreteTypeNames: new Set(['EntityA', 'EntityB', 'EntityC', 'EntityE']), + }, + ], + ], + ]), + new Map([ + [ + 'EntityInterfaceA', + { + concreteTypeNames: new Set(['EntityA', 'EntityB', 'EntityC', 'EntityE']), + fieldDatasBySubgraphName: new Map>(), + interfaceFieldNames: new Set(['id', 'name']), + interfaceObjectFieldNames: new Set(), + interfaceObjectSubgraphs: new Set(), + subgraphDataByTypeName: new Map(), + typeName: 'EntityInterfaceA', + }, + ], + ]), + ), + ); + }); + + test('that an error is returned if implementations of an entity Interface are included without explicit implementation of the entity Interface', () => { + const { errors } = federateSubgraphsFailure([ffa, ffd], ROUTER_COMPATIBILITY_VERSION_ONE); + expect(errors).toHaveLength(1); + expect(errors[0]).toStrictEqual( + undefinedEntityInterfaceImplementationsError( + new Map([ + [ + 'EntityInterfaceA', + [ + { + subgraphName: ffd.name, + definedConcreteTypeNames: new Set(['EntityA', 'EntityB', 'EntityE']), + requiredConcreteTypeNames: new Set(['EntityA', 'EntityB', 'EntityC', 'EntityE']), + }, + ], + ], + ]), + new Map([ + [ + 'EntityInterfaceA', + { + concreteTypeNames: new Set(['EntityA', 'EntityB', 'EntityC', 'EntityE']), + fieldDatasBySubgraphName: new Map>(), + interfaceFieldNames: new Set(['id', 'name']), + interfaceObjectFieldNames: new Set(), + interfaceObjectSubgraphs: new Set(), + subgraphDataByTypeName: new Map(), + typeName: 'EntityInterfaceA', + }, + ], + ]), + ), + ); + }); }); const faa: Subgraph = { @@ -898,3 +1134,237 @@ const fcf: Subgraph = { } `), }; + +const fda: Subgraph = { + name: 'fda', + url: '', + definitions: parse(` + type Entity implements EntityInterfaceA & EntityInterfaceB @key(fields: "id") { + id: ID! + name: String! + } + + interface EntityInterfaceA @key(fields: "id") { + id: ID! + name: String! + } + + interface EntityInterfaceB implements EntityInterfaceA @key(fields: "id") { + id: ID! + name: String! + } + + type Query { + interfacesA: [EntityInterfaceA] + interfacesB: [EntityInterfaceB] + } + `), +}; + +const fdb: Subgraph = { + name: 'fdb', + url: '', + definitions: parse(` + interface EntityInterfaceA @key(fields: "id") { + id: ID! + name: String! + } + + type EntityInterfaceB implements EntityInterfaceA @key(fields: "id") @interfaceObject { + id: ID! + name: String! @external + newField: String! + } + `), +}; + +const fdc: Subgraph = { + name: 'fdc', + url: '', + definitions: parse(` + interface EntityInterfaceA { + id: ID! + name: String! + } + + type EntityInterfaceB implements EntityInterfaceA @key(fields: "id") @interfaceObject { + id: ID! + name: String! @external + newField: String! + } + `), +}; + +const fea: Subgraph = { + name: 'fea', + url: '', + definitions: parse(` + type EntityA implements EntityInterfaceA & EntityInterfaceB @key(fields: "id") { + id: ID! + name: String! + } + + type EntityB implements EntityInterfaceA @key(fields: "id") { + id: ID! + name: String! + } + + interface EntityInterfaceA @key(fields: "id") { + id: ID! + name: String! + } + + interface EntityInterfaceB implements EntityInterfaceA @key(fields: "id") { + id: ID! + name: String! + } + + type Query { + interfacesA: [EntityInterfaceA] + interfacesB: [EntityInterfaceB] + } + `), +}; + +const feb: Subgraph = { + name: 'feb', + url: '', + definitions: parse(` + interface EntityInterfaceA @key(fields: "id") { + id: ID! + name: String! + } + + type EntityInterfaceB implements EntityInterfaceA @key(fields: "id") @interfaceObject { + id: ID! + name: String! @external + newField: String! + } + `), +}; + +const ffa: Subgraph = { + name: 'ffa', + url: '', + definitions: parse(` + type EntityA implements EntityInterfaceA & EntityInterfaceB @key(fields: "id") { + id: ID! + name: String! + } + + type EntityB implements EntityInterfaceA @key(fields: "id") { + id: ID! + name: String! + } + + type EntityC implements EntityInterfaceA @key(fields: "id") { + id: ID! + name: String! + } + + type EntityD implements EntityInterfaceC @key(fields: "id") { + id: ID! + name: String! + } + + type EntityE implements EntityInterfaceA & EntityInterfaceC @key(fields: "id") { + id: ID! + name: String! + } + + interface EntityInterfaceA @key(fields: "id") { + id: ID! + name: String! + } + + interface EntityInterfaceB implements EntityInterfaceA @key(fields: "id") { + id: ID! + name: String! + } + + interface EntityInterfaceC @key(fields: "id") { + id: ID! + name: String! + } + + type Query { + interfacesA: [EntityInterfaceA] + interfacesB: [EntityInterfaceB] + interfacesC: [EntityInterfaceC] + } + `), +}; + +const ffb: Subgraph = { + name: 'ffb', + url: '', + definitions: parse(` + type EntityB implements EntityInterfaceA @key(fields: "id") { + id: ID! + } + + type EntityC implements EntityInterfaceA @key(fields: "id") { + id: ID! + } + + interface EntityInterfaceA @key(fields: "id") { + id: ID! + } + + type EntityInterfaceB @key(fields: "id") @interfaceObject { + id: ID! + } + + type EntityInterfaceC @key(fields: "id") @interfaceObject { + id: ID! + } + `), +}; + +const ffc: Subgraph = { + name: 'ffc', + url: '', + definitions: parse(` + type EntityC implements EntityInterfaceA @key(fields: "id") { + id: ID! + } + + interface EntityInterfaceA @key(fields: "id") { + id: ID! + } + + type EntityInterfaceB @key(fields: "id") @interfaceObject { + id: ID! + } + + type EntityInterfaceC @key(fields: "id") @interfaceObject { + id: ID! + } + `), +}; + +const ffd: Subgraph = { + name: 'ffd', + url: '', + definitions: parse(` + type EntityB implements EntityInterfaceA @key(fields: "id") { + id: ID! + } + + type EntityC @key(fields: "id") { + id: ID! + } + + interface EntityInterfaceA @key(fields: "id") { + id: ID! + } + + type EntityInterfaceB @key(fields: "id") @interfaceObject { + id: ID! + } + + type EntityInterfaceC @key(fields: "id") @interfaceObject { + id: ID! + } + `), +}; diff --git a/composition/tests/v1/entity-interface.test.ts b/composition/tests/v1/entity-interface.test.ts index da6d3ea22f..84bf4bebe9 100644 --- a/composition/tests/v1/entity-interface.test.ts +++ b/composition/tests/v1/entity-interface.test.ts @@ -2,6 +2,7 @@ import { ConfigurationData, EntityInterfaceFederationData, EntityInterfaceSubgraphData, + INTERFACE, InvalidEntityInterface, ROUTER_COMPATIBILITY_VERSION_ONE, SimpleFieldData, @@ -142,29 +143,30 @@ describe('Entity Interface Tests', () => { }); test('that an error is returned if a subgraph does not define all implementations of an entity interface', () => { - const result = federateSubgraphsFailure([subgraphE, subgraphF], ROUTER_COMPATIBILITY_VERSION_ONE); - expect(result.success).toBe(false); - expect(result.errors).toHaveLength(1); - expect(result.errors[0]).toStrictEqual( + const { errors } = federateSubgraphsFailure([subgraphE, subgraphF], ROUTER_COMPATIBILITY_VERSION_ONE); + expect(errors).toHaveLength(1); + expect(errors[0]).toStrictEqual( undefinedEntityInterfaceImplementationsError( new Map([ [ - 'Interface', + INTERFACE, [ { subgraphName: 'subgraph-e', - concreteTypeNames: new Set(['EntityOne', 'EntityTwo']), + definedConcreteTypeNames: new Set(['EntityOne', 'EntityTwo']), + requiredConcreteTypeNames: new Set(['EntityOne', 'EntityTwo', 'EntityThree']), }, { subgraphName: 'subgraph-f', - concreteTypeNames: new Set(['EntityOne', 'EntityThree']), + definedConcreteTypeNames: new Set(['EntityOne', 'EntityThree']), + requiredConcreteTypeNames: new Set(['EntityOne', 'EntityTwo', 'EntityThree']), }, ], ], ]), new Map([ [ - 'Interface', + INTERFACE, { concreteTypeNames: new Set(['EntityOne', 'EntityTwo', 'EntityThree']), fieldDatasBySubgraphName: new Map>(), From e8429cae6090fbbe0bb1037e98e047656f9cc202 Mon Sep 17 00:00:00 2001 From: Aenimus Date: Fri, 15 Aug 2025 21:35:02 +0100 Subject: [PATCH 2/3] chore: fix typos --- composition-go/index.global.js | 6 +++--- composition/src/errors/errors.ts | 6 +++--- composition/src/v1/federation/federation-factory.ts | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/composition-go/index.global.js b/composition-go/index.global.js index 1a8c9da943..681f4df2d1 100644 --- a/composition-go/index.global.js +++ b/composition-go/index.global.js @@ -322,9 +322,9 @@ For federation, it is only possible to use the default root types names ("Mutati This is because an inline fragment with the type condition "${n}" is defined on the selection set corresponding to the `+ZT(t,i,r);return r===We.INTERFACE?a+` However, "${n}" does not implement "${i}"`:a+` However, "${n}" is not a member of "${i}".`}function pie(e,t,n){return` The following field set is invalid: "${e}" This is because of the selection set corresponding to the `+ZT(t,n,We.UNION)+` Union types such as "${n}" must define field selections (besides "__typename") on an inline fragment whose type condition corresponds to a constituent union member.`}function fie(e,t){return` The field "${e}" declares an @override directive in the following subgraphs: "`+t.join(We.QUOTATION_JOIN)+'".'}function mie(e){return new Error('The "@override" directive must only be declared on one single instance of a field. However, an "@override" directive was declared on more than one instance of the following field'+(e.length>1?"s":"")+': "'+e.join(We.QUOTATION_JOIN)+`". -`)}function Nie(e,t){return new Error(`The ${e} "${t}" is invalid because it does not define any fields.`)}function Tie(e){return new Error(`The Input Object "${e}" is invalid because it does not define any input values.`)}function Eie(e,t,n){return new Error(`The ${e} "${t}" is invalid because all its ${n} definitions are declared "@inaccessible".`)}function hie(e,t){return`Cannot override field "${t}" because the source and target subgraph names are both "${e}"`}function yie(e,t){let n=`Federation was unsuccessful because any one subgraph that defines a specific entity interface must also define each and every entity object that implements that entity interface. +`)}function Nie(e,t){return new Error(`The ${e} "${t}" is invalid because it does not define any fields.`)}function Tie(e){return new Error(`The Input Object "${e}" is invalid because it does not define any input values.`)}function Eie(e,t,n){return new Error(`The ${e} "${t}" is invalid because all its ${n} definitions are declared "@inaccessible".`)}function hie(e,t){return`Cannot override field "${t}" because the source and target subgraph names are both "${e}"`}function yie(e,t){let n=`Federation was unsuccessful because any one subgraph that defines a specific entity Interface must also define each and every entity Object that implements that entity Interface. - Each entity object must also each explicitly define the implementation of the entity interface. + Each entity Object must also explicitly define its implementation of the entity Interface. `;for(let[r,i]of e){let o=(0,Vl.getOrThrowError)(t,r,"entityInterfaceFederationDataByTypeName").concreteTypeNames;n+=` Across all subgraphs, the entity interface "${r}" is implemented by the following entit`+(o.size>1?"ies":"y")+`: "`+Array.from(o).join(We.QUOTATION_JOIN)+`" However, the definition of at least one of these implementations is missing in a subgraph that defines the entity interface "${r}": @@ -470,7 +470,7 @@ __p += '`),Rt&&(Ee+=`' + function print() { __p += __j.call(arguments, '') } `:`; `)+Ee+`return __p -}`;var Et=DA(function(){return jt(L,je+"return "+Ee).apply(e,M)});if(Et.source=Ee,cy(Et))throw Et;return Et}function lY(s){return Qt(s).toLowerCase()}function dY(s){return Qt(s).toUpperCase()}function pY(s,u,d){if(s=Qt(s),s&&(d||u===e))return Bb(s);if(!s||!(u=ai(u)))return s;var E=$i(s),S=$i(u),L=Ub(E,S),M=kb(E,S)+1;return Qo(E,L,M).join("")}function fY(s,u,d){if(s=Qt(s),s&&(d||u===e))return s.slice(0,xb(s)+1);if(!s||!(u=ai(u)))return s;var E=$i(s),S=kb(E,$i(u))+1;return Qo(E,0,S).join("")}function mY(s,u,d){if(s=Qt(s),s&&(d||u===e))return s.replace(ch,"");if(!s||!(u=ai(u)))return s;var E=$i(s),S=Ub(E,$i(u));return Qo(E,S).join("")}function NY(s,u){var d=et,E=X;if(_n(u)){var S="separator"in u?u.separator:S;d="length"in u?Nt(u.length):d,E="omission"in u?ai(u.omission):E}s=Qt(s);var L=s.length;if(Uc(s)){var M=$i(s);L=M.length}if(d>=L)return s;var j=d-kc(E);if(j<1)return E;var H=M?Qo(M,0,j).join(""):s.slice(0,j);if(S===e)return H+E;if(M&&(j+=H.length-j),ly(S)){if(s.slice(j).search(S)){var fe,me=H;for(S.global||(S=Dh(S.source,Qt(rb.exec(S))+"g")),S.lastIndex=0;fe=S.exec(me);)var Ee=fe.index;H=H.slice(0,Ee===e?j:Ee)}}else if(s.indexOf(ai(S),j)!=j){var be=H.lastIndexOf(S);be>-1&&(H=H.slice(0,be))}return H+E}function TY(s){return s=Qt(s),s&&b1.test(s)?s.replace(eb,$j):s}var EY=Kc(function(s,u,d){return s+(d?" ":"")+u.toUpperCase()}),fy=b0("toUpperCase");function OA(s,u,d){return s=Qt(s),u=d?e:u,u===e?qj(s)?Jj(s):Fj(s):s.match(u)||[]}var DA=yt(function(s,u){try{return ri(s,e,u)}catch(d){return cy(d)?d:new ot(d)}}),hY=ts(function(s,u){return Ti(u,function(d){d=_a(d),Za(s,d,oy(s[d],s))}),s});function yY(s){var u=s==null?0:s.length,d=ze();return s=u?yn(s,function(E){if(typeof E[1]!="function")throw new Ei(i);return[d(E[0]),E[1]]}):[],yt(function(E){for(var S=-1;++Sdn)return[];var d=Un,E=Tr(s,Un);u=ze(u),s-=Un;for(var S=vh(E,u);++d0||u<0)?new Ot(d):(s<0?d=d.takeRight(-s):s&&(d=d.drop(s)),u!==e&&(u=Nt(u),d=u<0?d.dropRight(-u):d.take(u-s)),d)},Ot.prototype.takeRightWhile=function(s){return this.reverse().takeWhile(s).reverse()},Ot.prototype.toArray=function(){return this.take(Un)},Ia(Ot.prototype,function(s,u){var d=/^(?:filter|find|map|reject)|While$/.test(u),E=/^(?:head|last)$/.test(u),S=R[E?"take"+(u=="last"?"Right":""):u],L=E||/^find/.test(u);S&&(R.prototype[u]=function(){var M=this.__wrapped__,j=E?[1]:arguments,H=M instanceof Ot,fe=j[0],me=H||lt(M),Ee=function(vt){var Rt=S.apply(R,xo([vt],j));return E&&be?Rt[0]:Rt};me&&d&&typeof fe=="function"&&fe.length!=1&&(H=me=!1);var be=this.__chain__,je=!!this.__actions__.length,Xe=L&&!be,Et=H&&!je;if(!L&&me){M=Et?M:new Ot(this);var Ze=s.apply(M,j);return Ze.__actions__.push({func:Xf,args:[Ee],thisArg:e}),new hi(Ze,be)}return Xe&&Et?s.apply(this,j):(Ze=this.thru(Ee),Xe?E?Ze.value()[0]:Ze.value():Ze)})}),Ti(["pop","push","shift","sort","splice","unshift"],function(s){var u=Sf[s],d=/^(?:push|sort|unshift)$/.test(s)?"tap":"thru",E=/^(?:pop|shift)$/.test(s);R.prototype[s]=function(){var S=arguments;if(E&&!this.__chain__){var L=this.value();return u.apply(lt(L)?L:[],S)}return this[d](function(M){return u.apply(lt(M)?M:[],S)})}}),Ia(Ot.prototype,function(s,u){var d=R[u];if(d){var E=d.name+"";Zt.call(qc,E)||(qc[E]=[]),qc[E].push({name:u,func:d})}}),qc[$f(e,U).name]=[{name:"wrapper",func:e}],Ot.prototype.clone=TK,Ot.prototype.reverse=EK,Ot.prototype.value=hK,R.prototype.at=Y$,R.prototype.chain=J$,R.prototype.commit=H$,R.prototype.next=z$,R.prototype.plant=X$,R.prototype.reverse=Z$,R.prototype.toJSON=R.prototype.valueOf=R.prototype.value=eQ,R.prototype.first=R.prototype.head,sd&&(R.prototype[sd]=W$),R},Vo=Hj();typeof define=="function"&&typeof define.amd=="object"&&define.amd?(ir._=Vo,define(function(){return Vo})):Su?((Su.exports=Vo)._=Vo,Nh._=Vo):ir._=Vo}).call(Yl)});var nV=w(Sc=>{"use strict";m();T();N();Object.defineProperty(Sc,"__esModule",{value:!0});Sc.FederationFactory=void 0;Sc.federateSubgraphs=gle;Sc.federateSubgraphsWithContracts=_le;Sc.federateSubgraphsContract=vle;var Re=Ae(),Xq=ou(),kr=Yr(),we=ia(),vc=BN(),Zq=kp(),ti=Kp(),PE=XT(),jn=Es(),hle=WO(),yle=Gp(),eV=hp(),ge=hl(),Ile=eD(),tV=Wq(),Jl=RE(),Oe=ur(),FE=Nl(),he=Jr(),wE=class{constructor({authorizationDataByParentTypeName:t,concreteTypeNamesByAbstractTypeName:n,disableResolvabilityValidation:r,entityDataByTypeName:i,entityInterfaceFederationDataByTypeName:a,fieldCoordsByNamedTypeName:o,internalGraph:c,internalSubgraphBySubgraphName:l,warnings:p}){_(this,"authorizationDataByParentTypeName");_(this,"coordsByNamedTypeName",new Map);_(this,"disableResolvabilityValidation",!1);_(this,"clientDefinitions",[jn.DEPRECATED_DEFINITION]);_(this,"currentSubgraphName","");_(this,"concreteTypeNamesByAbstractTypeName");_(this,"subgraphNamesByNamedTypeNameByFieldCoords",new Map);_(this,"entityDataByTypeName");_(this,"entityInterfaceFederationDataByTypeName");_(this,"errors",[]);_(this,"fieldConfigurationByFieldCoords",new Map);_(this,"fieldCoordsByNamedTypeName");_(this,"inaccessibleCoords",new Set);_(this,"inaccessibleRequiredInputValueErrorByCoords",new Map);_(this,"internalGraph");_(this,"internalSubgraphBySubgraphName");_(this,"invalidORScopesCoords",new Set);_(this,"isMaxDepth",!1);_(this,"isVersionTwo",!1);_(this,"namedInputValueTypeNames",new Set);_(this,"namedOutputTypeNames",new Set);_(this,"parentDefinitionDataByTypeName",new Map);_(this,"parentTagDataByTypeName",new Map);_(this,"persistedDirectiveDefinitionByDirectiveName",new Map([[Oe.AUTHENTICATED,jn.AUTHENTICATED_DEFINITION],[Oe.DEPRECATED,jn.DEPRECATED_DEFINITION],[Oe.INACCESSIBLE,jn.INACCESSIBLE_DEFINITION],[Oe.REQUIRES_SCOPES,jn.REQUIRES_SCOPES_DEFINITION],[Oe.TAG,jn.TAG_DEFINITION]]));_(this,"persistedDirectiveDefinitions",new Set([Oe.AUTHENTICATED,Oe.DEPRECATED,Oe.INACCESSIBLE,Oe.TAG,Oe.REQUIRES_SCOPES]));_(this,"potentialPersistedDirectiveDefinitionDataByDirectiveName",new Map);_(this,"routerDefinitions",[jn.DEPRECATED_DEFINITION,jn.TAG_DEFINITION]);_(this,"subscriptionFilterDataByFieldPath",new Map);_(this,"tagNamesByCoords",new Map);_(this,"warnings");this.authorizationDataByParentTypeName=t,this.concreteTypeNamesByAbstractTypeName=n,this.disableResolvabilityValidation=r!=null?r:!1,this.entityDataByTypeName=i,this.entityInterfaceFederationDataByTypeName=a,this.fieldCoordsByNamedTypeName=o,this.internalGraph=c,this.internalSubgraphBySubgraphName=l,this.warnings=p}getValidImplementedInterfaces(t){var o;let n=[];if(t.implementedInterfaceTypeNames.size<1)return n;let r=(0,ge.isNodeDataInaccessible)(t),i=new Map,a=new Map;for(let c of t.implementedInterfaceTypeNames){n.push((0,kr.stringToNamedTypeNode)(c));let l=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,c,Oe.PARENT_DEFINITION_DATA);if(l.kind!==Re.Kind.INTERFACE_TYPE_DEFINITION){a.set(l.name,(0,he.kindToNodeType)(l.kind));continue}let p={invalidFieldImplementations:new Map,unimplementedFields:[]},f=!1;for(let[y,g]of l.fieldDataByName){let v=!1,P=t.fieldDataByName.get(y);if(!P){f=!0,p.unimplementedFields.push(y);continue}let U={invalidAdditionalArguments:new Set,invalidImplementedArguments:[],isInaccessible:!1,originalResponseType:(0,PE.printTypeNode)(g.node.type),unimplementedArguments:new Set};(0,ge.isTypeValidImplementation)(g.node.type,P.node.type,this.concreteTypeNamesByAbstractTypeName)||(f=!0,v=!0,U.implementedResponseType=(0,PE.printTypeNode)(P.node.type));let K=new Set;for(let[$,ne]of g.argumentDataByName){let z=ne.node;K.add($);let Te=(o=P.argumentDataByName.get($))==null?void 0:o.node;if(!Te){f=!0,v=!0,U.unimplementedArguments.add($);continue}let pe=(0,PE.printTypeNode)(Te.type),Fe=(0,PE.printTypeNode)(z.type);Fe!==pe&&(f=!0,v=!0,U.invalidImplementedArguments.push({actualType:pe,argumentName:$,expectedType:Fe}))}for(let[$,ne]of P.argumentDataByName){let z=ne.node;K.has($)||z.type.kind===Re.Kind.NON_NULL_TYPE&&(f=!0,v=!0,U.invalidAdditionalArguments.add($))}!r&&P.isInaccessible&&!g.isInaccessible&&(f=!0,v=!0,U.isInaccessible=!0),v&&p.invalidFieldImplementations.set(y,U)}f&&i.set(c,p)}return a.size>0&&this.errors.push((0,we.invalidImplementedTypeError)(t.name,a)),i.size>0&&this.errors.push((0,we.invalidInterfaceImplementationError)(t.node.name.value,(0,he.kindToNodeType)(t.kind),i)),n}addValidPrimaryKeyTargetsToEntityData(t){var f;let n=this.entityDataByTypeName.get(t);if(!n)return;let r=(0,he.getOrThrowError)(this.internalSubgraphBySubgraphName,this.currentSubgraphName,"internalSubgraphBySubgraphName"),i=r.parentDefinitionDataByTypeName,a=i.get(n.typeName);if(!a||a.kind!==Re.Kind.OBJECT_TYPE_DEFINITION)throw(0,we.incompatibleParentKindFatalError)(n.typeName,Re.Kind.OBJECT_TYPE_DEFINITION,(a==null?void 0:a.kind)||Re.Kind.NULL);let o=r.configurationDataByTypeName.get(n.typeName);if(!o)return;let c=[],l=this.internalGraph.nodeByNodeName.get(`${this.currentSubgraphName}.${n.typeName}`);(0,vc.validateImplicitFieldSets)({conditionalFieldDataByCoords:r.conditionalFieldDataByCoordinates,currentSubgraphName:this.currentSubgraphName,entityData:n,implicitKeys:c,objectData:a,parentDefinitionDataByTypeName:i,graphNode:l});for(let[y,g]of this.entityInterfaceFederationDataByTypeName){if(!((f=g.concreteTypeNames)!=null&&f.has(n.typeName)))continue;let v=this.entityDataByTypeName.get(y);v&&(0,vc.validateImplicitFieldSets)({conditionalFieldDataByCoords:r.conditionalFieldDataByCoordinates,currentSubgraphName:this.currentSubgraphName,entityData:v,implicitKeys:c,objectData:a,parentDefinitionDataByTypeName:i,graphNode:l})}if(c.length<1)return;if(!o.keys||o.keys.length<1){o.isRootNode=!0,o.keys=c;return}let p=new Set(o.keys.map(y=>y.selectionSet));for(let y of c)p.has(y.selectionSet)||(o.keys.push(y),p.add(y.selectionSet))}addValidPrimaryKeyTargetsFromInterfaceObject(t,n,r,i){let a=t.parentDefinitionDataByTypeName,o=a.get(n);if(!o||!(0,ge.isParentDataCompositeOutputType)(o))throw(0,we.incompatibleParentKindFatalError)(n,Re.Kind.INTERFACE_TYPE_DEFINITION,(o==null?void 0:o.kind)||Re.Kind.NULL);let c=(0,he.getOrThrowError)(t.configurationDataByTypeName,r.typeName,"internalSubgraph.configurationDataByTypeName"),l=[];if((0,vc.validateImplicitFieldSets)({conditionalFieldDataByCoords:t.conditionalFieldDataByCoordinates,currentSubgraphName:t.name,entityData:r,implicitKeys:l,objectData:o,parentDefinitionDataByTypeName:a,graphNode:i}),l.length<1)return;if(!c.keys||c.keys.length<1){c.isRootNode=!0,c.keys=l;return}let p=new Set(c.keys.map(f=>f.selectionSet));for(let f of l)p.has(f.selectionSet)||(c.keys.push(f),p.add(f.selectionSet))}getEnumValueMergeMethod(t){return this.namedInputValueTypeNames.has(t)?this.namedOutputTypeNames.has(t)?ge.MergeMethod.CONSISTENT:ge.MergeMethod.INTERSECTION:ge.MergeMethod.UNION}generateTagData(){for(let[t,n]of this.tagNamesByCoords){let r=t.split(".");if(r.length<1)continue;let i=(0,he.getValueOrDefault)(this.parentTagDataByTypeName,r[0],()=>(0,vc.newParentTagData)(r[0]));switch(r.length){case 1:for(let l of n)i.tagNames.add(l);break;case 2:let a=(0,he.getValueOrDefault)(i.childTagDataByChildName,r[1],()=>(0,vc.newChildTagData)(r[1]));for(let l of n)a.tagNames.add(l);break;case 3:let o=(0,he.getValueOrDefault)(i.childTagDataByChildName,r[1],()=>(0,vc.newChildTagData)(r[1])),c=(0,he.getValueOrDefault)(o.tagNamesByArgumentName,r[2],()=>new Set);for(let l of n)c.add(l);break;default:break}}}upsertEnumValueData(t,n,r){let i=t.get(n.name),a=i||this.copyEnumValueData(n);(0,ge.extractPersistedDirectives)(a.persistedDirectivesData,n.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName);let o=(0,ge.isNodeDataInaccessible)(n);if((r||o)&&this.inaccessibleCoords.add(a.federatedCoords),this.recordTagNamesByCoords(a,a.federatedCoords),!i){t.set(a.name,a);return}a.appearances+=1,(0,he.addNewObjectValueMapEntries)(n.configureDescriptionDataBySubgraphName,a.configureDescriptionDataBySubgraphName),(0,ge.setLongestDescription)(a,n),(0,he.addIterableValuesToSet)(n.subgraphNames,a.subgraphNames)}upsertInputValueData(t,n,r,i){let a=t.get(n.name),o=a||this.copyInputValueData(n);if((0,ge.extractPersistedDirectives)(o.persistedDirectivesData,n.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),this.recordTagNamesByCoords(o,`${r}.${o.name}`),this.namedInputValueTypeNames.add(o.namedTypeName),(0,he.getValueOrDefault)(this.coordsByNamedTypeName,o.namedTypeName,()=>new Set).add(o.federatedCoords),!a){t.set(o.name,o);return}(0,he.addNewObjectValueMapEntries)(n.configureDescriptionDataBySubgraphName,o.configureDescriptionDataBySubgraphName),(0,ge.setLongestDescription)(o,n),(0,he.addIterableValuesToSet)(n.requiredSubgraphNames,o.requiredSubgraphNames),(0,he.addIterableValuesToSet)(n.subgraphNames,o.subgraphNames),this.handleInputValueInaccessibility(i,o,r);let c=(0,Jl.getMostRestrictiveMergedTypeNode)(o.type,n.type,o.originalCoords,this.errors);c.success?o.type=c.typeNode:this.errors.push((0,we.incompatibleMergedTypesError)({actualType:c.actualType,isArgument:a.isArgument,coords:a.federatedCoords,expectedType:c.expectedType})),(0,ge.compareAndValidateInputValueDefaultValues)(o,n,this.errors)}handleInputValueInaccessibility(t,n,r){if(t){this.inaccessibleRequiredInputValueErrorByCoords.delete(n.federatedCoords),this.inaccessibleCoords.add(n.federatedCoords);return}if((0,ge.isNodeDataInaccessible)(n)){if((0,ge.isTypeRequired)(n.type)){this.inaccessibleRequiredInputValueErrorByCoords.set(n.federatedCoords,(0,we.inaccessibleRequiredInputValueError)(n,r));return}this.inaccessibleCoords.add(n.federatedCoords)}}handleSubscriptionFilterDirective(t,n){let r=t.directivesByDirectiveName.get(Oe.SUBSCRIPTION_FILTER);if(!r)return;let i=(0,he.getSingleSetEntry)(t.subgraphNames);if(i===void 0){this.errors.push((0,we.unknownFieldSubgraphNameError)(t.federatedCoords));return}this.subscriptionFilterDataByFieldPath.set(t.federatedCoords,{directive:r[0],fieldData:n||t,directiveSubgraphName:i})}federateOutputType({current:t,other:n,coords:r,mostRestrictive:i}){n=(0,Xq.getMutableTypeNode)(n,r,this.errors);let a={kind:t.kind},o=Jl.DivergentType.NONE,c=a;for(let l=0;lnew Set))}upsertFieldData(t,n,r){let i=t.get(n.name),a=i||this.copyFieldData(n,r||(0,ge.isNodeDataInaccessible)(n));(0,he.getValueOrDefault)(this.coordsByNamedTypeName,n.namedTypeName,()=>new Set).add(a.federatedCoords),this.namedOutputTypeNames.add(n.namedTypeName),this.handleSubscriptionFilterDirective(n,a),(0,ge.extractPersistedDirectives)(a.persistedDirectivesData,n.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName);let o=r||(0,ge.isNodeDataInaccessible)(a);if(o&&this.inaccessibleCoords.add(a.federatedCoords),this.recordTagNamesByCoords(a,a.federatedCoords),!i){t.set(a.name,a);return}let c=this.federateOutputType({current:a.type,other:n.type,coords:a.federatedCoords,mostRestrictive:!1});if(c.success)if(a.type=c.typeNode,a.namedTypeName!==n.namedTypeName){let l=(0,he.getValueOrDefault)(this.subgraphNamesByNamedTypeNameByFieldCoords,a.federatedCoords,()=>new Map),p=(0,he.getValueOrDefault)(l,a.namedTypeName,()=>new Set);if(p.size<1)for(let f of a.subgraphNames)n.subgraphNames.has(f)||p.add(f);(0,he.addIterableValuesToSet)(n.subgraphNames,(0,he.getValueOrDefault)(l,n.namedTypeName,()=>new Set))}else this.addSubgraphNameToExistingFieldNamedTypeDisparity(n);for(let l of n.argumentDataByName.values())this.upsertInputValueData(a.argumentDataByName,l,a.federatedCoords,o);(0,he.addNewObjectValueMapEntries)(n.configureDescriptionDataBySubgraphName,i.configureDescriptionDataBySubgraphName),(0,ge.setLongestDescription)(a,n),a.isInaccessible||(a.isInaccessible=n.isInaccessible),(0,he.addNewObjectValueMapEntries)(n.externalFieldDataBySubgraphName,a.externalFieldDataBySubgraphName),(0,he.addMapEntries)(n.isShareableBySubgraphName,a.isShareableBySubgraphName),(0,he.addIterableValuesToSet)(n.subgraphNames,a.subgraphNames)}getClientSchemaUnionMembers(t){let n=[];for(let[r,i]of t.memberByMemberTypeName)this.inaccessibleCoords.has(r)||n.push(i);return n}recordTagNamesByCoords(t,n){let r=n||t.name;if(t.persistedDirectivesData.tagDirectiveByName.size<1)return;let i=(0,he.getValueOrDefault)(this.tagNamesByCoords,r,()=>new Set);for(let a of t.persistedDirectivesData.tagDirectiveByName.keys())i.add(a)}copyMutualParentDefinitionData(t){return{configureDescriptionDataBySubgraphName:(0,he.copyObjectValueMap)(t.configureDescriptionDataBySubgraphName),directivesByDirectiveName:(0,he.copyArrayValueMap)(t.directivesByDirectiveName),extensionType:t.extensionType,name:t.name,persistedDirectivesData:(0,ge.extractPersistedDirectives)((0,ge.newPersistedDirectivesData)(),t.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),description:(0,ge.getInitialFederatedDescription)(t)}}copyEnumValueData(t){return{appearances:t.appearances,configureDescriptionDataBySubgraphName:(0,he.copyObjectValueMap)(t.configureDescriptionDataBySubgraphName),federatedCoords:t.federatedCoords,directivesByDirectiveName:(0,he.copyArrayValueMap)(t.directivesByDirectiveName),kind:t.kind,name:t.name,node:{directives:[],kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},parentTypeName:t.parentTypeName,persistedDirectivesData:(0,ge.extractPersistedDirectives)((0,ge.newPersistedDirectivesData)(),t.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),subgraphNames:new Set(t.subgraphNames),description:(0,ge.getInitialFederatedDescription)(t)}}copyInputValueData(t){return{configureDescriptionDataBySubgraphName:(0,he.copyObjectValueMap)(t.configureDescriptionDataBySubgraphName),directivesByDirectiveName:(0,he.copyArrayValueMap)(t.directivesByDirectiveName),federatedCoords:t.federatedCoords,fieldName:t.fieldName,includeDefaultValue:t.includeDefaultValue,isArgument:t.isArgument,kind:t.kind,name:t.name,namedTypeKind:t.namedTypeKind,namedTypeName:t.namedTypeName,node:{directives:[],kind:Re.Kind.INPUT_VALUE_DEFINITION,name:(0,kr.stringToNameNode)(t.name),type:t.type},originalCoords:t.originalCoords,originalParentTypeName:t.originalParentTypeName,persistedDirectivesData:(0,ge.extractPersistedDirectives)((0,ge.newPersistedDirectivesData)(),t.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),renamedParentTypeName:t.renamedParentTypeName,requiredSubgraphNames:new Set(t.requiredSubgraphNames),subgraphNames:new Set(t.subgraphNames),type:t.type,defaultValue:t.defaultValue,description:(0,ge.getInitialFederatedDescription)(t)}}copyInputValueDataByValueName(t,n,r){let i=new Map;for(let[a,o]of t){let c=this.copyInputValueData(o);this.handleInputValueInaccessibility(n,c,r),(0,he.getValueOrDefault)(this.coordsByNamedTypeName,c.namedTypeName,()=>new Set).add(c.federatedCoords),this.namedInputValueTypeNames.add(c.namedTypeName),this.recordTagNamesByCoords(c,`${r}.${o.name}`),i.set(a,c)}return i}copyFieldData(t,n){return{argumentDataByName:this.copyInputValueDataByValueName(t.argumentDataByName,n,t.federatedCoords),configureDescriptionDataBySubgraphName:(0,he.copyObjectValueMap)(t.configureDescriptionDataBySubgraphName),directivesByDirectiveName:(0,he.copyArrayValueMap)(t.directivesByDirectiveName),externalFieldDataBySubgraphName:(0,he.copyObjectValueMap)(t.externalFieldDataBySubgraphName),federatedCoords:t.federatedCoords,inheritedDirectiveNames:new Set,isInaccessible:t.isInaccessible,isShareableBySubgraphName:new Map(t.isShareableBySubgraphName),kind:t.kind,name:t.name,namedTypeKind:t.namedTypeKind,namedTypeName:t.namedTypeName,node:{arguments:[],directives:[],kind:t.kind,name:(0,kr.stringToNameNode)(t.name),type:t.type},originalParentTypeName:t.originalParentTypeName,persistedDirectivesData:(0,ge.extractPersistedDirectives)((0,ge.newPersistedDirectivesData)(),t.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),renamedParentTypeName:t.renamedParentTypeName,subgraphNames:new Set(t.subgraphNames),type:t.type,description:(0,ge.getInitialFederatedDescription)(t)}}copyEnumValueDataByValueName(t,n){let r=new Map;for(let[i,a]of t){let o=this.copyEnumValueData(a);this.recordTagNamesByCoords(o,o.federatedCoords),(n||(0,ge.isNodeDataInaccessible)(o))&&this.inaccessibleCoords.add(o.federatedCoords),r.set(i,o)}return r}copyFieldDataByName(t,n){let r=new Map;for(let[i,a]of t){let o=n||(0,ge.isNodeDataInaccessible)(a),c=this.copyFieldData(a,o);this.handleSubscriptionFilterDirective(c),(0,he.getValueOrDefault)(this.coordsByNamedTypeName,c.namedTypeName,()=>new Set).add(c.federatedCoords),this.namedOutputTypeNames.add(c.namedTypeName),this.recordTagNamesByCoords(c,c.federatedCoords),o&&this.inaccessibleCoords.add(c.federatedCoords),r.set(i,c)}return r}copyParentDefinitionData(t){let n=this.copyMutualParentDefinitionData(t);switch(t.kind){case Re.Kind.ENUM_TYPE_DEFINITION:return Y(x({},n),{appearances:t.appearances,enumValueDataByValueName:this.copyEnumValueDataByValueName(t.enumValueDataByValueName,t.isInaccessible),isInaccessible:t.isInaccessible,kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},subgraphNames:new Set(t.subgraphNames)});case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:return Y(x({},n),{inputValueDataByName:this.copyInputValueDataByValueName(t.inputValueDataByName,t.isInaccessible,t.name),isInaccessible:t.isInaccessible,kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},subgraphNames:new Set(t.subgraphNames)});case Re.Kind.INTERFACE_TYPE_DEFINITION:return Y(x({},n),{fieldDataByName:this.copyFieldDataByName(t.fieldDataByName,t.isInaccessible),implementedInterfaceTypeNames:new Set(t.implementedInterfaceTypeNames),isEntity:t.isEntity,isInaccessible:t.isInaccessible,kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},subgraphNames:new Set(t.subgraphNames)});case Re.Kind.OBJECT_TYPE_DEFINITION:return Y(x({},n),{fieldDataByName:this.copyFieldDataByName(t.fieldDataByName,t.isInaccessible),implementedInterfaceTypeNames:new Set(t.implementedInterfaceTypeNames),isEntity:t.isEntity,isInaccessible:t.isInaccessible,isRootType:t.isRootType,kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.renamedTypeName||t.name)},renamedTypeName:t.renamedTypeName,subgraphNames:new Set(t.subgraphNames)});case Re.Kind.SCALAR_TYPE_DEFINITION:return Y(x({},n),{kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},subgraphNames:new Set(t.subgraphNames)});case Re.Kind.UNION_TYPE_DEFINITION:return Y(x({},n),{kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},memberByMemberTypeName:new Map(t.memberByMemberTypeName),subgraphNames:new Set(t.subgraphNames)})}}getParentTargetData({existingData:t,incomingData:n}){if(!t){let r=this.copyParentDefinitionData(n);return(0,ge.isParentDataRootType)(r)&&(r.extensionType=eV.ExtensionType.NONE),r}return(0,ge.extractPersistedDirectives)(t.persistedDirectivesData,n.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),t}upsertParentDefinitionData(t,n){let r=this.entityInterfaceFederationDataByTypeName.get(t.name),i=this.parentDefinitionDataByTypeName.get(t.name),a=this.getParentTargetData({existingData:i,incomingData:t});this.recordTagNamesByCoords(a);let o=(0,ge.isNodeDataInaccessible)(a);if(o&&this.inaccessibleCoords.add(a.name),r&&r.interfaceObjectSubgraphs.has(n)&&(a.kind=Re.Kind.INTERFACE_TYPE_DEFINITION,a.node.kind=Re.Kind.INTERFACE_TYPE_DEFINITION),!i){this.parentDefinitionDataByTypeName.set(a.name,a);return}if(a.kind!==t.kind&&(!r||!r.interfaceObjectSubgraphs.has(n)||a.kind!==Re.Kind.INTERFACE_TYPE_DEFINITION||t.kind!==Re.Kind.OBJECT_TYPE_DEFINITION)){this.errors.push((0,we.incompatibleParentKindMergeError)(a.name,(0,he.kindToNodeType)(a.kind),(0,he.kindToNodeType)(t.kind)));return}switch((0,he.addNewObjectValueMapEntries)(t.configureDescriptionDataBySubgraphName,a.configureDescriptionDataBySubgraphName),(0,ge.setLongestDescription)(a,t),(0,ge.setParentDataExtensionType)(a,t),a.kind){case Re.Kind.ENUM_TYPE_DEFINITION:if(!(0,ge.areKindsEqual)(a,t))return;a.appearances+=1,a.isInaccessible||(a.isInaccessible=o),(0,he.addIterableValuesToSet)(t.subgraphNames,a.subgraphNames);for(let l of t.enumValueDataByValueName.values())this.upsertEnumValueData(a.enumValueDataByValueName,l,o);return;case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:if(!(0,ge.areKindsEqual)(a,t))return;o&&!a.isInaccessible&&this.propagateInaccessibilityToExistingChildren(a),a.isInaccessible||(a.isInaccessible=o),(0,he.addIterableValuesToSet)(t.subgraphNames,a.subgraphNames);for(let l of t.inputValueDataByName.values())this.upsertInputValueData(a.inputValueDataByName,l,a.name,a.isInaccessible);return;case Re.Kind.INTERFACE_TYPE_DEFINITION:case Re.Kind.OBJECT_TYPE_DEFINITION:let c=t;o&&!a.isInaccessible&&this.propagateInaccessibilityToExistingChildren(a),a.isInaccessible||(a.isInaccessible=o),(0,he.addIterableValuesToSet)(c.implementedInterfaceTypeNames,a.implementedInterfaceTypeNames),(0,he.addIterableValuesToSet)(c.subgraphNames,a.subgraphNames);for(let l of c.fieldDataByName.values())this.upsertFieldData(a.fieldDataByName,l,a.isInaccessible);return;case Re.Kind.UNION_TYPE_DEFINITION:if(!(0,ge.areKindsEqual)(a,t))return;(0,he.addMapEntries)(t.memberByMemberTypeName,a.memberByMemberTypeName),(0,he.addIterableValuesToSet)(t.subgraphNames,a.subgraphNames);return;default:(0,he.addIterableValuesToSet)(t.subgraphNames,a.subgraphNames);return}}propagateInaccessibilityToExistingChildren(t){switch(t.kind){case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:for(let n of t.inputValueDataByName.values())this.inaccessibleCoords.add(n.federatedCoords);break;default:for(let n of t.fieldDataByName.values()){this.inaccessibleCoords.add(n.federatedCoords);for(let r of n.argumentDataByName.values())this.inaccessibleCoords.add(r.federatedCoords)}}}upsertPersistedDirectiveDefinitionData(t,n){let r=t.name,i=this.potentialPersistedDirectiveDefinitionDataByDirectiveName.get(r);if(!i){if(n>1)return;let a=new Map;for(let o of t.argumentDataByArgumentName.values())this.namedInputValueTypeNames.add(o.namedTypeName),this.upsertInputValueData(a,o,`@${t.name}`,!1);this.potentialPersistedDirectiveDefinitionDataByDirectiveName.set(r,{argumentDataByArgumentName:a,executableLocations:new Set(t.executableLocations),name:r,repeatable:t.repeatable,subgraphNames:new Set(t.subgraphNames),description:t.description});return}if(i.subgraphNames.size+1!==n){this.potentialPersistedDirectiveDefinitionDataByDirectiveName.delete(r);return}if((0,ge.setMutualExecutableLocations)(i,t.executableLocations),i.executableLocations.size<1){this.potentialPersistedDirectiveDefinitionDataByDirectiveName.delete(r);return}for(let a of t.argumentDataByArgumentName.values())this.namedInputValueTypeNames.add((0,Xq.getTypeNodeNamedTypeName)(a.type)),this.upsertInputValueData(i.argumentDataByArgumentName,a,`@${i.name}`,!1);(0,ge.setLongestDescription)(i,t),i.repeatable&&(i.repeatable=t.repeatable),(0,he.addIterableValuesToSet)(t.subgraphNames,i.subgraphNames)}shouldUpdateFederatedFieldAbstractNamedType(t,n){if(!t)return!1;let r=this.concreteTypeNamesByAbstractTypeName.get(t);if(!r||r.size<1)return!1;for(let i of n)if(!r.has(i))return!1;return!0}updateTypeNodeNamedType(t,n){let r=t;for(let i=0;i1){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}break}case Re.Kind.UNION_TYPE_DEFINITION:{if(l){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}l=f;break}default:{this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));break}}}if(o.size<0&&!l){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}let p=l;if(o.size>0){if(l){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}for(let f of o.keys()){p=f;for(let[y,g]of o)if(f!==y&&!g.implementedInterfaceTypeNames.has(f)){p="";break}if(p)break}}if(!this.shouldUpdateFederatedFieldAbstractNamedType(p,c)){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}a.namedTypeName=p,this.updateTypeNodeNamedType(a.type,p)}}federateInternalSubgraphData(){let t=0,n=!1;for(let r of this.internalSubgraphBySubgraphName.values()){t+=1,this.currentSubgraphName=r.name,this.isVersionTwo||(this.isVersionTwo=r.isVersionTwo),(0,Ile.renameRootTypes)(this,r);for(let i of r.parentDefinitionDataByTypeName.values())this.upsertParentDefinitionData(i,r.name);if(!n){if(!r.persistedDirectiveDefinitionDataByDirectiveName.size){n=!0;continue}for(let i of r.persistedDirectiveDefinitionDataByDirectiveName.values())this.upsertPersistedDirectiveDefinitionData(i,t);this.potentialPersistedDirectiveDefinitionDataByDirectiveName.size<1&&(n=!0)}}this.handleDisparateFieldNamedTypes()}handleInterfaceObjectForInternalGraph({entityData:t,internalSubgraph:n,interfaceObjectData:r,interfaceObjectNode:i,resolvableKeyFieldSets:a,subgraphName:o}){let c=this.internalGraph.addOrUpdateNode(t.typeName),l=this.internalGraph.addEntityDataNode(t.typeName);for(let f of i.satisfiedFieldSets)c.satisfiedFieldSets.add(f),a.has(f)&&l.addTargetSubgraphByFieldSet(f,o);let p=r.fieldDatasBySubgraphName.get(o);for(let{name:f,namedTypeName:y}of p||[])this.internalGraph.addEdge(c,this.internalGraph.addOrUpdateNode(y),f);this.internalGraph.addEdge(i,c,t.typeName,!0),this.addValidPrimaryKeyTargetsFromInterfaceObject(n,i.typeName,t,c)}handleEntityInterfaces(){var t;for(let[n,r]of this.entityInterfaceFederationDataByTypeName){let i=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,n,Oe.PARENT_DEFINITION_DATA);if(i.kind===Re.Kind.INTERFACE_TYPE_DEFINITION)for(let a of r.interfaceObjectSubgraphs){let o=(0,he.getOrThrowError)(this.internalSubgraphBySubgraphName,a,"internalSubgraphBySubgraphName"),c=o.configurationDataByTypeName,l=this.concreteTypeNamesByAbstractTypeName.get(n);if(!l)continue;let p=(0,he.getOrThrowError)(c,n,"configurationDataByTypeName"),f=p.keys;if(!f)continue;p.entityInterfaceConcreteTypeNames=new Set(r.concreteTypeNames),this.internalGraph.setSubgraphName(a);let y=this.internalGraph.addOrUpdateNode(n,{isAbstract:!0});for(let g of l){let v=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,g,Oe.PARENT_DEFINITION_DATA);if(!(0,ti.isObjectDefinitionData)(v))continue;let P=(0,he.getOrThrowError)(this.entityDataByTypeName,g,"entityDataByTypeName");P.subgraphNames.add(a);let U=c.get(g);if(U)if((0,he.addIterableValuesToSet)(p.fieldNames,U.fieldNames),!U.keys)U.keys=[...f];else e:for(let z of f){for(let{selectionSet:Te}of U.keys)if(z.selectionSet===Te)continue e;U.keys.push(z)}else c.set(g,{fieldNames:new Set(p.fieldNames),isRootNode:!0,keys:[...f],typeName:g});let K=new Set;for(let z of f.filter(Te=>!Te.disableEntityResolver))K.add(z.selectionSet);let $=this.authorizationDataByParentTypeName.get(n),ne=(0,he.getOrThrowError)(o.parentDefinitionDataByTypeName,n,"internalSubgraph.parentDefinitionDataByTypeName");if((0,ti.isObjectDefinitionData)(ne)){for(let[z,Te]of ne.fieldDataByName){let pe=`${g}.${z}`;(0,he.getValueOrDefault)(this.fieldCoordsByNamedTypeName,Te.namedTypeName,()=>new Set).add(pe);let Fe=$==null?void 0:$.fieldAuthDataByFieldName.get(z);if(Fe){let X=(0,he.getValueOrDefault)(this.authorizationDataByParentTypeName,g,()=>(0,ti.newAuthorizationData)(g));(0,ti.upsertFieldAuthorizationData)(X.fieldAuthDataByFieldName,Fe)||this.invalidORScopesCoords.add(pe)}let xe=v.fieldDataByName.get(z);if(xe){let X=(t=Te.isShareableBySubgraphName.get(a))!=null?t:!1;xe.isShareableBySubgraphName.set(a,X),xe.subgraphNames.add(a);let ve=Te.externalFieldDataBySubgraphName.get(a);if(!ve)continue;xe.externalFieldDataBySubgraphName.set(a,ve);continue}let et=i.isInaccessible||v.isInaccessible||Te.isInaccessible;v.fieldDataByName.set(z,this.copyFieldData(Te,et))}this.handleInterfaceObjectForInternalGraph({internalSubgraph:o,subgraphName:a,interfaceObjectData:r,interfaceObjectNode:y,resolvableKeyFieldSets:K,entityData:P})}}}}}fieldDataToGraphFieldData(t){var n;return{name:t.name,namedTypeName:t.namedTypeName,isLeaf:(0,ti.isNodeLeaf)((n=this.parentDefinitionDataByTypeName.get(t.namedTypeName))==null?void 0:n.kind),subgraphNames:t.subgraphNames}}getValidFlattenedPersistedDirectiveNodeArray(t,n){let r=[];for(let[i,a]of t){let o=this.persistedDirectiveDefinitionByDirectiveName.get(i);if(o){if(a.length<2){r.push(...a);continue}if(!o.repeatable){this.errors.push((0,we.invalidRepeatedFederatedDirectiveErrorMessage)(i,n));continue}r.push(...a)}}return r}getRouterPersistedDirectiveNodes(t){let n=[...t.persistedDirectivesData.tagDirectiveByName.values()];return t.persistedDirectivesData.isDeprecated&&n.push((0,ge.generateDeprecatedDirective)(t.persistedDirectivesData.deprecatedReason)),n.push(...this.getValidFlattenedPersistedDirectiveNodeArray(t.persistedDirectivesData.directivesByDirectiveName,t.name)),n}getFederatedGraphNodeDescription(t){if(t.configureDescriptionDataBySubgraphName.size<1)return t.description;let n=[],r="";for(let[i,{propagate:a,description:o}]of t.configureDescriptionDataBySubgraphName)a&&(n.push(i),r=o);if(n.length===1)return(0,vc.getDescriptionFromString)(r);if(n.length<1)return t.description;this.errors.push((0,we.configureDescriptionPropagationError)((0,ge.getDefinitionDataCoords)(t,!0),n))}getNodeForRouterSchemaByData(t){return t.node.name=(0,kr.stringToNameNode)(t.name),t.node.description=this.getFederatedGraphNodeDescription(t),t.node.directives=this.getRouterPersistedDirectiveNodes(t),t.node}getNodeWithPersistedDirectivesByInputValueData(t){return t.node.name=(0,kr.stringToNameNode)(t.name),t.node.type=t.type,t.node.description=this.getFederatedGraphNodeDescription(t),t.node.directives=this.getRouterPersistedDirectiveNodes(t),t.includeDefaultValue&&(t.node.defaultValue=t.defaultValue),t.node}getValidFieldArgumentNodes(t){let n=[],r=[],i=[],a=`${t.renamedParentTypeName}.${t.name}`;for(let[o,c]of t.argumentDataByName)t.subgraphNames.size===c.subgraphNames.size?(r.push(o),n.push(this.getNodeWithPersistedDirectivesByInputValueData(c))):(0,ge.isTypeRequired)(c.type)&&i.push({inputValueName:o,missingSubgraphs:(0,he.getEntriesNotInHashSet)(t.subgraphNames,c.subgraphNames),requiredSubgraphs:[...c.requiredSubgraphNames]});return i.length>0?this.errors.push((0,we.invalidRequiredInputValueError)(Oe.FIELD,a,i)):r.length>0&&((0,he.getValueOrDefault)(this.fieldConfigurationByFieldCoords,a,()=>({argumentNames:r,fieldName:t.name,typeName:t.renamedParentTypeName})).argumentNames=r),n}getNodeWithPersistedDirectivesByFieldData(t,n){return t.node.arguments=n,t.node.name=(0,kr.stringToNameNode)(t.name),t.node.type=t.type,t.node.description=this.getFederatedGraphNodeDescription(t),t.node.directives=this.getRouterPersistedDirectiveNodes(t),t.node}pushParentDefinitionDataToDocumentDefinitions(t){for(let[n,r]of this.parentDefinitionDataByTypeName)switch(r.extensionType!==eV.ExtensionType.NONE&&this.errors.push((0,we.noBaseDefinitionForExtensionError)((0,he.kindToNodeType)(r.kind),n)),r.kind){case Re.Kind.ENUM_TYPE_DEFINITION:let i=[],a=[],o=this.getEnumValueMergeMethod(n);(0,ge.propagateAuthDirectives)(r,this.authorizationDataByParentTypeName.get(n));for(let ne of r.enumValueDataByValueName.values()){let z=(0,ge.getNodeForRouterSchemaByData)(ne,this.persistedDirectiveDefinitionByDirectiveName,this.errors),Te=(0,ge.isNodeDataInaccessible)(ne),pe=Y(x({},ne.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(ne)});switch(o){case ge.MergeMethod.CONSISTENT:!Te&&r.appearances>ne.appearances&&this.errors.push((0,we.incompatibleSharedEnumError)(n)),i.push(z),Te||a.push(pe);break;case ge.MergeMethod.INTERSECTION:r.appearances===ne.appearances&&(i.push(z),Te||a.push(pe));break;default:i.push(z),Te||a.push(pe);break}}if(r.node.values=i,this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r)),(0,ge.isNodeDataInaccessible)(r)){this.validateReferencesOfInaccessibleType(r),this.internalGraph.setNodeInaccessible(r.name);break}if(a.length<1){this.errors.push((0,we.allChildDefinitionsAreInaccessibleError)((0,he.kindToNodeType)(r.kind),n,Oe.ENUM_VALUE));break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r),values:a}));break;case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:let c=[],l=[],p=[];for(let[ne,z]of r.inputValueDataByName)if(r.subgraphNames.size===z.subgraphNames.size){if(l.push(this.getNodeWithPersistedDirectivesByInputValueData(z)),(0,ge.isNodeDataInaccessible)(z))continue;p.push(Y(x({},z.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(z)}))}else(0,ge.isTypeRequired)(z.type)&&c.push({inputValueName:ne,missingSubgraphs:(0,he.getEntriesNotInHashSet)(r.subgraphNames,z.subgraphNames),requiredSubgraphs:[...z.requiredSubgraphNames]});if(c.length>0){this.errors.push((0,we.invalidRequiredInputValueError)(Oe.INPUT_OBJECT,n,c,!1));break}if(r.node.fields=l,this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r)),(0,ge.isNodeDataInaccessible)(r)){this.validateReferencesOfInaccessibleType(r);break}if(p.length<1){this.errors.push((0,we.allChildDefinitionsAreInaccessibleError)((0,he.kindToNodeType)(r.kind),n,"input field"));break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r),fields:p}));break;case Re.Kind.INTERFACE_TYPE_DEFINITION:case Re.Kind.OBJECT_TYPE_DEFINITION:let f=[],y=[],g=new Map,v=(0,ge.newInvalidFieldNames)(),P=r.kind===Re.Kind.OBJECT_TYPE_DEFINITION,U=this.authorizationDataByParentTypeName.get(n);(0,ge.propagateAuthDirectives)(r,U);for(let[ne,z]of r.fieldDataByName){(0,ge.propagateFieldAuthDirectives)(z,U);let Te=this.getValidFieldArgumentNodes(z);P&&(0,ge.validateExternalAndShareable)(z,v),f.push(this.getNodeWithPersistedDirectivesByFieldData(z,Te)),!(0,ge.isNodeDataInaccessible)(z)&&(y.push((0,ge.getClientSchemaFieldNodeByFieldData)(z)),g.set(ne,this.fieldDataToGraphFieldData(z)))}if(P&&(v.byShareable.size>0&&this.errors.push((0,we.invalidFieldShareabilityError)(r,v.byShareable)),v.subgraphNamesByExternalFieldName.size>0&&this.errors.push((0,we.allExternalFieldInstancesError)(n,v.subgraphNamesByExternalFieldName))),r.node.fields=f,this.internalGraph.initializeNode(n,g),r.implementedInterfaceTypeNames.size>0){t.push({data:r,clientSchemaFieldNodes:y});break}this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r));let K=(0,yle.isNodeQuery)(n);if((0,ge.isNodeDataInaccessible)(r)){if(K){this.errors.push(we.inaccessibleQueryRootTypeError);break}this.validateReferencesOfInaccessibleType(r),this.internalGraph.setNodeInaccessible(r.name);break}if(y.length<1){let ne=K?(0,we.noQueryRootTypeError)(!1):(0,we.allChildDefinitionsAreInaccessibleError)((0,he.kindToNodeType)(r.kind),n,Oe.FIELD);this.errors.push(ne);break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r),fields:y}));break;case Re.Kind.SCALAR_TYPE_DEFINITION:if(jn.BASE_SCALARS.has(n))break;if((0,ge.propagateAuthDirectives)(r,this.authorizationDataByParentTypeName.get(n)),this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r)),(0,ge.isNodeDataInaccessible)(r)){this.validateReferencesOfInaccessibleType(r),this.internalGraph.setNodeInaccessible(r.name);break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r)}));break;case Re.Kind.UNION_TYPE_DEFINITION:if(r.node.types=(0,ti.mapToArrayOfValues)(r.memberByMemberTypeName),this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r)),(0,ge.isNodeDataInaccessible)(r)){this.validateReferencesOfInaccessibleType(r),this.internalGraph.setNodeInaccessible(r.name);break}let $=this.getClientSchemaUnionMembers(r);if($.length<1){this.errors.push((0,we.allChildDefinitionsAreInaccessibleError)(Oe.UNION,n,"union member type"));break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r),types:$}));break}}pushNamedTypeAuthDataToFields(){var t;for(let[n,r]of this.authorizationDataByParentTypeName){if(!r.requiresAuthentication&&r.requiredScopes.length<1)continue;let i=this.fieldCoordsByNamedTypeName.get(n);if(i)for(let a of i){let o=a.split(Oe.PERIOD);switch(o.length){case 2:{let c=(0,he.getValueOrDefault)(this.authorizationDataByParentTypeName,o[0],()=>(0,ti.newAuthorizationData)(o[0])),l=(0,he.getValueOrDefault)(c.fieldAuthDataByFieldName,o[1],()=>(0,ti.newFieldAuthorizationData)(o[1]));(t=l.inheritedData).requiresAuthentication||(t.requiresAuthentication=r.requiresAuthentication),l.inheritedData.requiredScopes.length*r.requiredScopes.length>jn.MAX_OR_SCOPES?this.invalidORScopesCoords.add(a):(l.inheritedData.requiredScopesByOR=(0,ti.mergeRequiredScopesByAND)(l.inheritedData.requiredScopesByOR,r.requiredScopesByOR),l.inheritedData.requiredScopes=(0,ti.mergeRequiredScopesByAND)(l.inheritedData.requiredScopes,r.requiredScopes));break}default:break}}}}federateSubgraphData(){this.federateInternalSubgraphData(),this.handleEntityInterfaces(),this.generateTagData(),this.pushVersionTwoDirectiveDefinitionsToDocumentDefinitions(),this.pushNamedTypeAuthDataToFields()}validateInterfaceImplementationsAndPushToDocumentDefinitions(t){for(let{data:n,clientSchemaFieldNodes:r}of t){if(n.node.interfaces=this.getValidImplementedInterfaces(n),this.routerDefinitions.push((0,ge.getNodeForRouterSchemaByData)(n,this.persistedDirectiveDefinitionByDirectiveName,this.errors)),(0,ge.isNodeDataInaccessible)(n)){this.validateReferencesOfInaccessibleType(n),this.internalGraph.setNodeInaccessible(n.name);continue}let i=[];for(let a of n.implementedInterfaceTypeNames)this.inaccessibleCoords.has(a)||i.push((0,kr.stringToNamedTypeNode)(a));this.clientDefinitions.push(Y(x({},n.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(n),fields:r,interfaces:i}))}}pushVersionTwoDirectiveDefinitionsToDocumentDefinitions(){this.isVersionTwo&&(this.routerDefinitions=[jn.AUTHENTICATED_DEFINITION,jn.DEPRECATED_DEFINITION,jn.INACCESSIBLE_DEFINITION,jn.REQUIRES_SCOPES_DEFINITION,jn.TAG_DEFINITION,jn.SCOPE_SCALAR_DEFINITION],this.clientDefinitions=[jn.DEPRECATED_DEFINITION])}validatePathSegmentInaccessibility(t){if(!t)return!1;let r=t.split(Oe.LEFT_PARENTHESIS)[0].split(Oe.PERIOD),i=r[0];for(let a=0;a0&&this.errors.push((0,we.invalidReferencesOfInaccessibleTypeError)((0,he.kindToNodeType)(t.kind),t.name,r))}validateQueryRootType(){let t=this.parentDefinitionDataByTypeName.get(Oe.QUERY);if(!t||t.kind!==Re.Kind.OBJECT_TYPE_DEFINITION||t.fieldDataByName.size<1){this.errors.push((0,we.noQueryRootTypeError)());return}for(let n of t.fieldDataByName.values())if(!(0,ge.isNodeDataInaccessible)(n))return;this.errors.push((0,we.noQueryRootTypeError)())}validateSubscriptionFieldConditionFieldPath(t,n,r,i,a){let o=t.split(Oe.PERIOD);if(o.length<1)return a.push((0,we.invalidSubscriptionFieldConditionFieldPathErrorMessage)(r,t)),[];let c=n;if(this.inaccessibleCoords.has(c.renamedTypeName))return a.push((0,we.inaccessibleSubscriptionFieldConditionFieldPathFieldErrorMessage)(r,t,o[0],c.renamedTypeName)),[];let l="";for(let p=0;p0?`.${f}`:f,c.kind!==Re.Kind.OBJECT_TYPE_DEFINITION)return a.push((0,we.invalidSubscriptionFieldConditionFieldPathParentErrorMessage)(r,t,l)),[];let y=c.fieldDataByName.get(f);if(!y)return a.push((0,we.undefinedSubscriptionFieldConditionFieldPathFieldErrorMessage)(r,t,l,f,c.renamedTypeName)),[];let g=`${c.renamedTypeName}.${f}`;if(!y.subgraphNames.has(i))return a.push((0,we.invalidSubscriptionFieldConditionFieldPathFieldErrorMessage)(r,t,l,g,i)),[];if(this.inaccessibleCoords.has(g))return a.push((0,we.inaccessibleSubscriptionFieldConditionFieldPathFieldErrorMessage)(r,t,l,g)),[];if(jn.BASE_SCALARS.has(y.namedTypeName)){c={kind:Re.Kind.SCALAR_TYPE_DEFINITION,name:y.namedTypeName};continue}c=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,y.namedTypeName,Oe.PARENT_DEFINITION_DATA)}return(0,ge.isLeafKind)(c.kind)?o:(a.push((0,we.nonLeafSubscriptionFieldConditionFieldPathFinalFieldErrorMessage)(r,t,o[o.length-1],(0,he.kindToNodeType)(c.kind),c.name)),[])}validateSubscriptionFieldCondition(t,n,r,i,a,o,c){if(i>FE.MAX_SUBSCRIPTION_FILTER_DEPTH||this.isMaxDepth)return c.push((0,we.subscriptionFilterConditionDepthExceededErrorMessage)(a)),this.isMaxDepth=!0,!1;let l=!1,p=new Set([Oe.FIELD_PATH,Oe.VALUES]),f=new Set,y=new Set,g=[];for(let v of t.fields){let P=v.name.value,U=a+`.${P}`;switch(P){case Oe.FIELD_PATH:{if(p.has(Oe.FIELD_PATH))p.delete(Oe.FIELD_PATH);else{l=!0,f.add(Oe.FIELD_PATH);break}if(v.value.kind!==Re.Kind.STRING){g.push((0,we.invalidInputFieldTypeErrorMessage)(U,Oe.STRING,(0,he.kindToNodeType)(v.value.kind))),l=!0;break}let K=this.validateSubscriptionFieldConditionFieldPath(v.value.value,r,U,o,g);if(K.length<1){l=!0;break}n.fieldPath=K;break}case Oe.VALUES:{if(p.has(Oe.VALUES))p.delete(Oe.VALUES);else{l=!0,f.add(Oe.VALUES);break}let K=v.value.kind;if(K==Re.Kind.NULL||K==Re.Kind.OBJECT){g.push((0,we.invalidInputFieldTypeErrorMessage)(U,Oe.LIST,(0,he.kindToNodeType)(v.value.kind))),l=!0;break}if(K!==Re.Kind.LIST){n.values=[(0,ge.getSubscriptionFilterValue)(v.value)];break}let $=new Set,ne=[];for(let z=0;z0){g.push((0,we.subscriptionFieldConditionInvalidValuesArrayErrorMessage)(U,ne));continue}if($.size<1){l=!0,g.push((0,we.subscriptionFieldConditionEmptyValuesArrayErrorMessage)(U));continue}n.values=[...$];break}default:l=!0,y.add(P)}}return l?(c.push((0,we.subscriptionFieldConditionInvalidInputFieldErrorMessage)(a,[...p],[...f],[...y],g)),!1):!0}validateSubscriptionFilterCondition(t,n,r,i,a,o,c){if(i>FE.MAX_SUBSCRIPTION_FILTER_DEPTH||this.isMaxDepth)return c.push((0,we.subscriptionFilterConditionDepthExceededErrorMessage)(a)),this.isMaxDepth=!0,!1;if(i+=1,t.fields.length!==1)return c.push((0,we.subscriptionFilterConditionInvalidInputFieldNumberErrorMessage)(a,t.fields.length)),!1;let l=t.fields[0],p=l.name.value;if(!Zq.SUBSCRIPTION_FILTER_INPUT_NAMES.has(p))return c.push((0,we.subscriptionFilterConditionInvalidInputFieldErrorMessage)(a,p)),!1;let f=a+`.${p}`;switch(l.value.kind){case Re.Kind.OBJECT:switch(p){case Oe.IN_UPPER:return n.in={fieldPath:[],values:[]},this.validateSubscriptionFieldCondition(l.value,n.in,r,i,a+".IN",o,c);case Oe.NOT_UPPER:return n.not={},this.validateSubscriptionFilterCondition(l.value,n.not,r,i,a+".NOT",o,c);default:return c.push((0,we.subscriptionFilterConditionInvalidInputFieldTypeErrorMessage)(f,Oe.LIST,Oe.OBJECT)),!1}case Re.Kind.LIST:{let y=[];switch(p){case Oe.AND_UPPER:{n.and=y;break}case Oe.OR_UPPER:{n.or=y;break}default:return c.push((0,we.subscriptionFilterConditionInvalidInputFieldTypeErrorMessage)(f,Oe.OBJECT,Oe.LIST)),!1}let g=l.value.values.length;if(g<1||g>5)return c.push((0,we.subscriptionFilterArrayConditionInvalidLengthErrorMessage)(f,g)),!1;let v=!0,P=[];for(let U=0;U0?(c.push((0,we.subscriptionFilterArrayConditionInvalidItemTypeErrorMessage)(f,P)),!1):v}default:{let y=Zq.SUBSCRIPTION_FILTER_LIST_INPUT_NAMES.has(p)?Oe.LIST:Oe.OBJECT;return c.push((0,we.subscriptionFilterConditionInvalidInputFieldTypeErrorMessage)(f,y,(0,he.kindToNodeType)(l.value.kind))),!1}}}validateSubscriptionFilterAndGenerateConfiguration(t,n,r,i,a,o){if(!t.arguments||t.arguments.length!==1)return;let c=t.arguments[0];if(c.value.kind!==Re.Kind.OBJECT){this.errors.push((0,we.invalidSubscriptionFilterDirectiveError)(r,[(0,we.subscriptionFilterConditionInvalidInputFieldTypeErrorMessage)(Oe.CONDITION,Oe.OBJECT,(0,he.kindToNodeType)(c.value.kind))]));return}let l={},p=[];if(!this.validateSubscriptionFilterCondition(c.value,l,n,0,Oe.CONDITION,o,p)){this.errors.push((0,we.invalidSubscriptionFilterDirectiveError)(r,p)),this.isMaxDepth=!1;return}(0,he.getValueOrDefault)(this.fieldConfigurationByFieldCoords,r,()=>({argumentNames:[],fieldName:i,typeName:a})).subscriptionFilterCondition=l}validateSubscriptionFiltersAndGenerateConfiguration(){for(let[t,n]of this.subscriptionFilterDataByFieldPath){if(this.inaccessibleCoords.has(t))continue;let r=this.parentDefinitionDataByTypeName.get(n.fieldData.namedTypeName);if(!r){this.errors.push((0,we.invalidSubscriptionFilterDirectiveError)(t,[(0,we.subscriptionFilterNamedTypeErrorMessage)(n.fieldData.namedTypeName)]));continue}(0,ge.isNodeDataInaccessible)(r)||r.kind===Re.Kind.OBJECT_TYPE_DEFINITION&&this.validateSubscriptionFilterAndGenerateConfiguration(n.directive,r,t,n.fieldData.name,n.fieldData.renamedParentTypeName,n.directiveSubgraphName)}}buildFederationResult(){this.subscriptionFilterDataByFieldPath.size>0&&this.validateSubscriptionFiltersAndGenerateConfiguration(),this.invalidORScopesCoords.size>0&&this.errors.push((0,we.orScopesLimitError)(jn.MAX_OR_SCOPES,[...this.invalidORScopesCoords]));for(let a of this.potentialPersistedDirectiveDefinitionDataByDirectiveName.values())(0,ge.addValidPersistedDirectiveDefinitionNodeByData)(this.routerDefinitions,a,this.persistedDirectiveDefinitionByDirectiveName,this.errors);let t=[];this.pushParentDefinitionDataToDocumentDefinitions(t),this.validateInterfaceImplementationsAndPushToDocumentDefinitions(t),this.validateQueryRootType();for(let a of this.inaccessibleRequiredInputValueErrorByCoords.values())this.errors.push(a);if(this.errors.length>0)return{errors:this.errors,success:!1,warnings:this.warnings};if(!this.disableResolvabilityValidation&&this.internalSubgraphBySubgraphName.size>1){let a=this.internalGraph.validate();if(a.length>0)return{errors:a,success:!1,warnings:this.warnings}}let n={kind:Re.Kind.DOCUMENT,definitions:this.routerDefinitions},r=(0,Re.buildASTSchema)({kind:Re.Kind.DOCUMENT,definitions:this.clientDefinitions},{assumeValid:!0,assumeValidSDL:!0}),i=new Map;for(let a of this.internalSubgraphBySubgraphName.values())i.set(a.name,{configurationDataByTypeName:a.configurationDataByTypeName,isVersionTwo:a.isVersionTwo,parentDefinitionDataByTypeName:a.parentDefinitionDataByTypeName,schema:a.schema});for(let a of this.authorizationDataByParentTypeName.values())(0,ti.upsertAuthorizationConfiguration)(this.fieldConfigurationByFieldCoords,a);return x({fieldConfigurations:Array.from(this.fieldConfigurationByFieldCoords.values()),subgraphConfigBySubgraphName:i,federatedGraphAST:n,federatedGraphSchema:(0,Re.buildASTSchema)(n,{assumeValid:!0,assumeValidSDL:!0}),federatedGraphClientSchema:r,parentDefinitionDataByTypeName:this.parentDefinitionDataByTypeName,success:!0,warnings:this.warnings},this.getClientSchemaObjectBoolean())}getClientSchemaObjectBoolean(){return this.inaccessibleCoords.size<1&&this.tagNamesByCoords.size<1?{}:{shouldIncludeClientSchema:!0}}handleChildTagExclusions(t,n,r,i){let a=n.size;for(let[o,c]of r){let l=(0,he.getOrThrowError)(n,o,`${t.name}.childDataByChildName`);if((0,ge.isNodeDataInaccessible)(l)){a-=1;continue}i.isDisjointFrom(c.tagNames)||((0,he.getValueOrDefault)(l.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(`${t.name}.${o}`),a-=1)}a<1&&(t.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(t.name))}handleChildTagInclusions(t,n,r,i){let a=n.size;for(let[o,c]of n){if((0,ge.isNodeDataInaccessible)(c)){a-=1;continue}let l=r.get(o);(!l||i.isDisjointFrom(l.tagNames))&&((0,he.getValueOrDefault)(c.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(`${t.name}.${o}`),a-=1)}a<1&&(t.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(t.name))}buildFederationContractResult(t){if(this.isVersionTwo||this.routerDefinitions.push(jn.INACCESSIBLE_DEFINITION),t.tagNamesToExclude.size>0)for(let[o,c]of this.parentTagDataByTypeName){let l=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,o,Oe.PARENT_DEFINITION_DATA);if(!(0,ge.isNodeDataInaccessible)(l)){if(!t.tagNamesToExclude.isDisjointFrom(c.tagNames)){l.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o);continue}if(!(c.childTagDataByChildName.size<1))switch(l.kind){case Re.Kind.SCALAR_TYPE_DEFINITION:case Re.Kind.UNION_TYPE_DEFINITION:continue;case Re.Kind.ENUM_TYPE_DEFINITION:this.handleChildTagExclusions(l,l.enumValueDataByValueName,c.childTagDataByChildName,t.tagNamesToExclude);break;case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:this.handleChildTagExclusions(l,l.inputValueDataByName,c.childTagDataByChildName,t.tagNamesToExclude);break;default:let p=l.fieldDataByName.size;for(let[f,y]of c.childTagDataByChildName){let g=(0,he.getOrThrowError)(l.fieldDataByName,f,`${o}.fieldDataByFieldName`);if((0,ge.isNodeDataInaccessible)(g)){p-=1;continue}if(!t.tagNamesToExclude.isDisjointFrom(y.tagNames)){(0,he.getValueOrDefault)(g.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(g.federatedCoords),p-=1;continue}for(let[v,P]of y.tagNamesByArgumentName){let U=(0,he.getOrThrowError)(g.argumentDataByName,v,`${f}.argumentDataByArgumentName`);(0,ge.isNodeDataInaccessible)(U)||P.isDisjointFrom(P)||((0,he.getValueOrDefault)(U.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(U.federatedCoords))}}p<1&&(l.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o))}}}else if(t.tagNamesToInclude.size>0)for(let[o,c]of this.parentDefinitionDataByTypeName){if((0,ge.isNodeDataInaccessible)(c))continue;let l=this.parentTagDataByTypeName.get(o);if(!l){c.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o);continue}if(t.tagNamesToInclude.isDisjointFrom(l.tagNames)){if(l.childTagDataByChildName.size<1){c.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o);continue}switch(c.kind){case Re.Kind.SCALAR_TYPE_DEFINITION:case Re.Kind.UNION_TYPE_DEFINITION:continue;case Re.Kind.ENUM_TYPE_DEFINITION:this.handleChildTagInclusions(c,c.enumValueDataByValueName,l.childTagDataByChildName,t.tagNamesToInclude);break;case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:this.handleChildTagInclusions(c,c.inputValueDataByName,l.childTagDataByChildName,t.tagNamesToInclude);break;default:let p=c.fieldDataByName.size;for(let[f,y]of c.fieldDataByName){if((0,ge.isNodeDataInaccessible)(y)){p-=1;continue}let g=l.childTagDataByChildName.get(f);(!g||t.tagNamesToInclude.isDisjointFrom(g.tagNames))&&((0,he.getValueOrDefault)(y.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(y.federatedCoords),p-=1)}p<1&&(c.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o))}}}this.subscriptionFilterDataByFieldPath.size>0&&this.validateSubscriptionFiltersAndGenerateConfiguration();for(let o of this.potentialPersistedDirectiveDefinitionDataByDirectiveName.values())(0,ge.addValidPersistedDirectiveDefinitionNodeByData)(this.routerDefinitions,o,this.persistedDirectiveDefinitionByDirectiveName,this.errors);let n=[];if(this.pushParentDefinitionDataToDocumentDefinitions(n),this.validateInterfaceImplementationsAndPushToDocumentDefinitions(n),this.validateQueryRootType(),this.errors.length>0)return{errors:this.errors,success:!1,warnings:this.warnings};let r={kind:Re.Kind.DOCUMENT,definitions:this.routerDefinitions},i=(0,Re.buildASTSchema)({kind:Re.Kind.DOCUMENT,definitions:this.clientDefinitions},{assumeValid:!0,assumeValidSDL:!0}),a=new Map;for(let o of this.internalSubgraphBySubgraphName.values())a.set(o.name,{configurationDataByTypeName:o.configurationDataByTypeName,isVersionTwo:o.isVersionTwo,parentDefinitionDataByTypeName:o.parentDefinitionDataByTypeName,schema:o.schema});for(let o of this.authorizationDataByParentTypeName.values())(0,ti.upsertAuthorizationConfiguration)(this.fieldConfigurationByFieldCoords,o);return x({fieldConfigurations:Array.from(this.fieldConfigurationByFieldCoords.values()),subgraphConfigBySubgraphName:a,federatedGraphAST:r,federatedGraphSchema:(0,Re.buildASTSchema)(r,{assumeValid:!0,assumeValidSDL:!0}),federatedGraphClientSchema:i,parentDefinitionDataByTypeName:this.parentDefinitionDataByTypeName,success:!0,warnings:this.warnings},this.getClientSchemaObjectBoolean())}federateSubgraphsInternal(){return this.federateSubgraphData(),this.buildFederationResult()}};Sc.FederationFactory=wE;function tD({disableResolvabilityValidation:e,subgraphs:t}){if(t.length<1)return{errors:[we.minimumSubgraphRequirementError],success:!1,warnings:[]};let n=(0,hle.batchNormalize)(t);if(!n.success)return{errors:n.errors,success:!1,warnings:n.warnings};let r=new Map,i=new Map;for(let[c,l]of n.internalSubgraphBySubgraphName)for(let[p,f]of l.entityInterfaces){let y=r.get(p);if(!y){r.set(p,(0,ti.newEntityInterfaceFederationData)(f,c));continue}(0,ti.upsertEntityInterfaceFederationData)(y,f,c)}let a=new Array,o=new Map;for(let[c,l]of r){let p=l.concreteTypeNames.size;for(let[f,y]of l.subgraphDataByTypeName){let g=(0,he.getValueOrDefault)(o,f,()=>new Set);if((0,he.addIterableValuesToSet)(y.concreteTypeNames,g),!y.isInterfaceObject){y.resolvable&&y.concreteTypeNames.size!==p&&(0,he.getValueOrDefault)(i,c,()=>new Array).push({subgraphName:f,definedConcreteTypeNames:new Set(y.concreteTypeNames),requiredConcreteTypeNames:new Set(l.concreteTypeNames)});continue}(0,he.addIterableValuesToSet)(l.concreteTypeNames,g);let{parentDefinitionDataByTypeName:v}=(0,he.getOrThrowError)(n.internalSubgraphBySubgraphName,f,"internalSubgraphBySubgraphName"),P=[];for(let U of l.concreteTypeNames)v.has(U)&&P.push(U);P.length>0&&a.push((0,we.invalidInterfaceObjectImplementationDefinitionsError)(c,f,P))}}for(let[c,l]of i){let p=new Array;for(let f of l){let y=o.get(f.subgraphName);if(!y){p.push(f);continue}let g=f.requiredConcreteTypeNames.intersection(y);f.requiredConcreteTypeNames.size!==g.size&&(f.definedConcreteTypeNames=g,p.push(f))}if(p.length>0){i.set(c,p);continue}i.delete(c)}return i.size>0&&a.push((0,we.undefinedEntityInterfaceImplementationsError)(i,r)),a.length>0?{errors:a,success:!1,warnings:n.warnings}:{federationFactory:new wE({authorizationDataByParentTypeName:n.authorizationDataByParentTypeName,concreteTypeNamesByAbstractTypeName:n.concreteTypeNamesByAbstractTypeName,disableResolvabilityValidation:e,entityDataByTypeName:n.entityDataByTypeName,entityInterfaceFederationDataByTypeName:r,fieldCoordsByNamedTypeName:n.fieldCoordsByNamedTypeName,internalSubgraphBySubgraphName:n.internalSubgraphBySubgraphName,internalGraph:n.internalGraph,warnings:n.warnings}),success:!0,warnings:n.warnings}}function gle({disableResolvabilityValidation:e,subgraphs:t}){let n=tD({subgraphs:t,disableResolvabilityValidation:e});return n.success?n.federationFactory.federateSubgraphsInternal():{errors:n.errors,success:!1,warnings:n.warnings}}function _le({subgraphs:e,tagOptionsByContractName:t,disableResolvabilityValidation:n}){let r=tD({subgraphs:e,disableResolvabilityValidation:n});if(!r.success)return{errors:r.errors,success:!1,warnings:r.warnings};r.federationFactory.federateSubgraphData();let i=[(0,tV.cloneDeep)(r.federationFactory)],a=r.federationFactory.buildFederationResult();if(!a.success)return{errors:a.errors,success:!1,warnings:a.warnings};let o=t.size-1,c=new Map,l=0;for(let[p,f]of t){l!==o&&i.push((0,tV.cloneDeep)(i[l]));let y=i[l].buildFederationContractResult(f);c.set(p,y),l++}return Y(x({},a),{federationResultByContractName:c})}function vle({contractTagOptions:e,disableResolvabilityValidation:t,subgraphs:n}){let r=tD({subgraphs:n,disableResolvabilityValidation:t});return r.success?(r.federationFactory.federateSubgraphData(),r.federationFactory.buildFederationContractResult(e)):{errors:r.errors,success:!1,warnings:r.warnings}}});var LE=w(Ss=>{"use strict";m();T();N();Object.defineProperty(Ss,"__esModule",{value:!0});Ss.LATEST_ROUTER_COMPATIBILITY_VERSION=Ss.ROUTER_COMPATIBILITY_VERSIONS=Ss.ROUTER_COMPATIBILITY_VERSION_ONE=void 0;Ss.ROUTER_COMPATIBILITY_VERSION_ONE="1";Ss.ROUTER_COMPATIBILITY_VERSIONS=new Set([Ss.ROUTER_COMPATIBILITY_VERSION_ONE]);Ss.LATEST_ROUTER_COMPATIBILITY_VERSION="1"});var rV=w(Hp=>{"use strict";m();T();N();Object.defineProperty(Hp,"__esModule",{value:!0});Hp.federateSubgraphs=Sle;Hp.federateSubgraphsWithContracts=Ole;Hp.federateSubgraphsContract=Dle;var nD=nV(),rD=LE();function Sle({disableResolvabilityValidation:e,subgraphs:t,version:n=rD.ROUTER_COMPATIBILITY_VERSION_ONE}){switch(n){default:return(0,nD.federateSubgraphs)({disableResolvabilityValidation:e,subgraphs:t})}}function Ole({disableResolvabilityValidation:e,subgraphs:t,tagOptionsByContractName:n,version:r=rD.ROUTER_COMPATIBILITY_VERSION_ONE}){switch(r){default:return(0,nD.federateSubgraphsWithContracts)({disableResolvabilityValidation:e,subgraphs:t,tagOptionsByContractName:n})}}function Dle({contractTagOptions:e,disableResolvabilityValidation:t,subgraphs:n,version:r=rD.ROUTER_COMPATIBILITY_VERSION_ONE}){switch(r){default:return(0,nD.federateSubgraphsContract)({disableResolvabilityValidation:t,subgraphs:n,contractTagOptions:e})}}});var aV=w(iV=>{"use strict";m();T();N();Object.defineProperty(iV,"__esModule",{value:!0})});var sV=w(zp=>{"use strict";m();T();N();Object.defineProperty(zp,"__esModule",{value:!0});zp.normalizeSubgraphFromString=ble;zp.normalizeSubgraph=Ale;zp.batchNormalize=Rle;var iD=WO(),aD=LE();function ble(e,t=!0,n=aD.ROUTER_COMPATIBILITY_VERSION_ONE){switch(n){default:return(0,iD.normalizeSubgraphFromString)(e,t)}}function Ale(e,t,n,r=aD.ROUTER_COMPATIBILITY_VERSION_ONE){switch(r){default:return(0,iD.normalizeSubgraph)(e,t,n)}}function Rle(e,t=aD.ROUTER_COMPATIBILITY_VERSION_ONE){switch(t){default:return(0,iD.batchNormalize)(e)}}});var uV=w(oV=>{"use strict";m();T();N();Object.defineProperty(oV,"__esModule",{value:!0})});var lV=w(cV=>{"use strict";m();T();N();Object.defineProperty(cV,"__esModule",{value:!0})});var pV=w(dV=>{"use strict";m();T();N();Object.defineProperty(dV,"__esModule",{value:!0})});var mV=w(fV=>{"use strict";m();T();N();Object.defineProperty(fV,"__esModule",{value:!0})});var NV=w(CE=>{"use strict";m();T();N();Object.defineProperty(CE,"__esModule",{value:!0});CE.COMPOSITION_VERSION=void 0;CE.COMPOSITION_VERSION="{{$COMPOSITION__VERSION}}"});var EV=w(TV=>{"use strict";m();T();N();Object.defineProperty(TV,"__esModule",{value:!0})});var yV=w(hV=>{"use strict";m();T();N();Object.defineProperty(hV,"__esModule",{value:!0})});var gV=w(IV=>{"use strict";m();T();N();Object.defineProperty(IV,"__esModule",{value:!0})});var BE=w(pt=>{"use strict";m();T();N();var Ple=pt&&pt.__createBinding||(Object.create?function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]}),St=pt&&pt.__exportStar||function(e,t){for(var n in e)n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n)&&Ple(t,e,n)};Object.defineProperty(pt,"__esModule",{value:!0});St(Yr(),pt);St(dv(),pt);St(ia(),pt);St(Pk(),pt);St(rV(),pt);St(aV(),pt);St(sV(),pt);St(uV(),pt);St(JO(),pt);St(KO(),pt);St($O(),pt);St(LE(),pt);St(lV(),pt);St(HO(),pt);St(ou(),pt);St(hp(),pt);St(hl(),pt);St(pV(),pt);St(mV(),pt);St(NV(),pt);St(ur(),pt);St(EV(),pt);St(Jr(),pt);St(BO(),pt);St(BN(),pt);St(eD(),pt);St(yV(),pt);St(PO(),pt);St(Gp(),pt);St(gV(),pt);St(MO(),pt);St(RE(),pt);St(LO(),pt);St(Es(),pt);St(Kp(),pt);St(kp(),pt);St(gE(),pt)});var vde={};sm(vde,{buildRouterConfiguration:()=>_de,federateSubgraphs:()=>gde});m();T();N();var Fc=ss(BE());m();T();N();m();T();N();function sD(e){if(!e)return e;if(!URL.canParse(e))throw new Error("Invalid URL");let t=e.indexOf("?"),n=e.indexOf("#"),r=e;return t>0?r=r.slice(0,n>0?Math.min(t,n):t):n>0&&(r=r.slice(0,n)),r}m();T();N();m();T();N();var _V={};m();T();N();function vV(e){return e!=null}m();T();N();m();T();N();var AV=ss(Ae(),1);m();T();N();var SV;if(typeof AggregateError=="undefined"){class e extends Error{constructor(n,r=""){super(r),this.errors=n,this.name="AggregateError",Error.captureStackTrace(this,e)}}SV=function(t,n){return new e(t,n)}}else SV=AggregateError;function OV(e){return"errors"in e&&Array.isArray(e.errors)}var RV=3;function PV(e){return UE(e,[])}function UE(e,t){switch(typeof e){case"string":return JSON.stringify(e);case"function":return e.name?`[function ${e.name}]`:"[function]";case"object":return Fle(e,t);default:return String(e)}}function DV(e){return e instanceof AV.GraphQLError?e.toString():`${e.name}: ${e.message}; +}`;var Et=DA(function(){return jt(L,je+"return "+Ee).apply(e,M)});if(Et.source=Ee,cy(Et))throw Et;return Et}function lY(s){return Qt(s).toLowerCase()}function dY(s){return Qt(s).toUpperCase()}function pY(s,u,d){if(s=Qt(s),s&&(d||u===e))return Bb(s);if(!s||!(u=ai(u)))return s;var E=$i(s),S=$i(u),L=Ub(E,S),M=kb(E,S)+1;return Qo(E,L,M).join("")}function fY(s,u,d){if(s=Qt(s),s&&(d||u===e))return s.slice(0,xb(s)+1);if(!s||!(u=ai(u)))return s;var E=$i(s),S=kb(E,$i(u))+1;return Qo(E,0,S).join("")}function mY(s,u,d){if(s=Qt(s),s&&(d||u===e))return s.replace(ch,"");if(!s||!(u=ai(u)))return s;var E=$i(s),S=Ub(E,$i(u));return Qo(E,S).join("")}function NY(s,u){var d=et,E=X;if(_n(u)){var S="separator"in u?u.separator:S;d="length"in u?Nt(u.length):d,E="omission"in u?ai(u.omission):E}s=Qt(s);var L=s.length;if(Uc(s)){var M=$i(s);L=M.length}if(d>=L)return s;var j=d-kc(E);if(j<1)return E;var H=M?Qo(M,0,j).join(""):s.slice(0,j);if(S===e)return H+E;if(M&&(j+=H.length-j),ly(S)){if(s.slice(j).search(S)){var fe,me=H;for(S.global||(S=Dh(S.source,Qt(rb.exec(S))+"g")),S.lastIndex=0;fe=S.exec(me);)var Ee=fe.index;H=H.slice(0,Ee===e?j:Ee)}}else if(s.indexOf(ai(S),j)!=j){var be=H.lastIndexOf(S);be>-1&&(H=H.slice(0,be))}return H+E}function TY(s){return s=Qt(s),s&&b1.test(s)?s.replace(eb,$j):s}var EY=Kc(function(s,u,d){return s+(d?" ":"")+u.toUpperCase()}),fy=b0("toUpperCase");function OA(s,u,d){return s=Qt(s),u=d?e:u,u===e?qj(s)?Jj(s):Fj(s):s.match(u)||[]}var DA=yt(function(s,u){try{return ri(s,e,u)}catch(d){return cy(d)?d:new ot(d)}}),hY=ts(function(s,u){return Ti(u,function(d){d=_a(d),Za(s,d,oy(s[d],s))}),s});function yY(s){var u=s==null?0:s.length,d=ze();return s=u?yn(s,function(E){if(typeof E[1]!="function")throw new Ei(i);return[d(E[0]),E[1]]}):[],yt(function(E){for(var S=-1;++Sdn)return[];var d=Un,E=Tr(s,Un);u=ze(u),s-=Un;for(var S=vh(E,u);++d0||u<0)?new Ot(d):(s<0?d=d.takeRight(-s):s&&(d=d.drop(s)),u!==e&&(u=Nt(u),d=u<0?d.dropRight(-u):d.take(u-s)),d)},Ot.prototype.takeRightWhile=function(s){return this.reverse().takeWhile(s).reverse()},Ot.prototype.toArray=function(){return this.take(Un)},Ia(Ot.prototype,function(s,u){var d=/^(?:filter|find|map|reject)|While$/.test(u),E=/^(?:head|last)$/.test(u),S=R[E?"take"+(u=="last"?"Right":""):u],L=E||/^find/.test(u);S&&(R.prototype[u]=function(){var M=this.__wrapped__,j=E?[1]:arguments,H=M instanceof Ot,fe=j[0],me=H||lt(M),Ee=function(vt){var Rt=S.apply(R,xo([vt],j));return E&&be?Rt[0]:Rt};me&&d&&typeof fe=="function"&&fe.length!=1&&(H=me=!1);var be=this.__chain__,je=!!this.__actions__.length,Xe=L&&!be,Et=H&&!je;if(!L&&me){M=Et?M:new Ot(this);var Ze=s.apply(M,j);return Ze.__actions__.push({func:Xf,args:[Ee],thisArg:e}),new hi(Ze,be)}return Xe&&Et?s.apply(this,j):(Ze=this.thru(Ee),Xe?E?Ze.value()[0]:Ze.value():Ze)})}),Ti(["pop","push","shift","sort","splice","unshift"],function(s){var u=Sf[s],d=/^(?:push|sort|unshift)$/.test(s)?"tap":"thru",E=/^(?:pop|shift)$/.test(s);R.prototype[s]=function(){var S=arguments;if(E&&!this.__chain__){var L=this.value();return u.apply(lt(L)?L:[],S)}return this[d](function(M){return u.apply(lt(M)?M:[],S)})}}),Ia(Ot.prototype,function(s,u){var d=R[u];if(d){var E=d.name+"";Zt.call(qc,E)||(qc[E]=[]),qc[E].push({name:u,func:d})}}),qc[$f(e,U).name]=[{name:"wrapper",func:e}],Ot.prototype.clone=TK,Ot.prototype.reverse=EK,Ot.prototype.value=hK,R.prototype.at=Y$,R.prototype.chain=J$,R.prototype.commit=H$,R.prototype.next=z$,R.prototype.plant=X$,R.prototype.reverse=Z$,R.prototype.toJSON=R.prototype.valueOf=R.prototype.value=eQ,R.prototype.first=R.prototype.head,sd&&(R.prototype[sd]=W$),R},Vo=Hj();typeof define=="function"&&typeof define.amd=="object"&&define.amd?(ir._=Vo,define(function(){return Vo})):Su?((Su.exports=Vo)._=Vo,Nh._=Vo):ir._=Vo}).call(Yl)});var nV=w(Sc=>{"use strict";m();T();N();Object.defineProperty(Sc,"__esModule",{value:!0});Sc.FederationFactory=void 0;Sc.federateSubgraphs=gle;Sc.federateSubgraphsWithContracts=_le;Sc.federateSubgraphsContract=vle;var Re=Ae(),Xq=ou(),kr=Yr(),we=ia(),vc=BN(),Zq=kp(),ti=Kp(),PE=XT(),jn=Es(),hle=WO(),yle=Gp(),eV=hp(),ge=hl(),Ile=eD(),tV=Wq(),Jl=RE(),Oe=ur(),FE=Nl(),he=Jr(),wE=class{constructor({authorizationDataByParentTypeName:t,concreteTypeNamesByAbstractTypeName:n,disableResolvabilityValidation:r,entityDataByTypeName:i,entityInterfaceFederationDataByTypeName:a,fieldCoordsByNamedTypeName:o,internalGraph:c,internalSubgraphBySubgraphName:l,warnings:p}){_(this,"authorizationDataByParentTypeName");_(this,"coordsByNamedTypeName",new Map);_(this,"disableResolvabilityValidation",!1);_(this,"clientDefinitions",[jn.DEPRECATED_DEFINITION]);_(this,"currentSubgraphName","");_(this,"concreteTypeNamesByAbstractTypeName");_(this,"subgraphNamesByNamedTypeNameByFieldCoords",new Map);_(this,"entityDataByTypeName");_(this,"entityInterfaceFederationDataByTypeName");_(this,"errors",[]);_(this,"fieldConfigurationByFieldCoords",new Map);_(this,"fieldCoordsByNamedTypeName");_(this,"inaccessibleCoords",new Set);_(this,"inaccessibleRequiredInputValueErrorByCoords",new Map);_(this,"internalGraph");_(this,"internalSubgraphBySubgraphName");_(this,"invalidORScopesCoords",new Set);_(this,"isMaxDepth",!1);_(this,"isVersionTwo",!1);_(this,"namedInputValueTypeNames",new Set);_(this,"namedOutputTypeNames",new Set);_(this,"parentDefinitionDataByTypeName",new Map);_(this,"parentTagDataByTypeName",new Map);_(this,"persistedDirectiveDefinitionByDirectiveName",new Map([[Oe.AUTHENTICATED,jn.AUTHENTICATED_DEFINITION],[Oe.DEPRECATED,jn.DEPRECATED_DEFINITION],[Oe.INACCESSIBLE,jn.INACCESSIBLE_DEFINITION],[Oe.REQUIRES_SCOPES,jn.REQUIRES_SCOPES_DEFINITION],[Oe.TAG,jn.TAG_DEFINITION]]));_(this,"persistedDirectiveDefinitions",new Set([Oe.AUTHENTICATED,Oe.DEPRECATED,Oe.INACCESSIBLE,Oe.TAG,Oe.REQUIRES_SCOPES]));_(this,"potentialPersistedDirectiveDefinitionDataByDirectiveName",new Map);_(this,"routerDefinitions",[jn.DEPRECATED_DEFINITION,jn.TAG_DEFINITION]);_(this,"subscriptionFilterDataByFieldPath",new Map);_(this,"tagNamesByCoords",new Map);_(this,"warnings");this.authorizationDataByParentTypeName=t,this.concreteTypeNamesByAbstractTypeName=n,this.disableResolvabilityValidation=r!=null?r:!1,this.entityDataByTypeName=i,this.entityInterfaceFederationDataByTypeName=a,this.fieldCoordsByNamedTypeName=o,this.internalGraph=c,this.internalSubgraphBySubgraphName=l,this.warnings=p}getValidImplementedInterfaces(t){var o;let n=[];if(t.implementedInterfaceTypeNames.size<1)return n;let r=(0,ge.isNodeDataInaccessible)(t),i=new Map,a=new Map;for(let c of t.implementedInterfaceTypeNames){n.push((0,kr.stringToNamedTypeNode)(c));let l=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,c,Oe.PARENT_DEFINITION_DATA);if(l.kind!==Re.Kind.INTERFACE_TYPE_DEFINITION){a.set(l.name,(0,he.kindToNodeType)(l.kind));continue}let p={invalidFieldImplementations:new Map,unimplementedFields:[]},f=!1;for(let[y,g]of l.fieldDataByName){let v=!1,P=t.fieldDataByName.get(y);if(!P){f=!0,p.unimplementedFields.push(y);continue}let U={invalidAdditionalArguments:new Set,invalidImplementedArguments:[],isInaccessible:!1,originalResponseType:(0,PE.printTypeNode)(g.node.type),unimplementedArguments:new Set};(0,ge.isTypeValidImplementation)(g.node.type,P.node.type,this.concreteTypeNamesByAbstractTypeName)||(f=!0,v=!0,U.implementedResponseType=(0,PE.printTypeNode)(P.node.type));let K=new Set;for(let[$,ne]of g.argumentDataByName){let z=ne.node;K.add($);let Te=(o=P.argumentDataByName.get($))==null?void 0:o.node;if(!Te){f=!0,v=!0,U.unimplementedArguments.add($);continue}let pe=(0,PE.printTypeNode)(Te.type),Fe=(0,PE.printTypeNode)(z.type);Fe!==pe&&(f=!0,v=!0,U.invalidImplementedArguments.push({actualType:pe,argumentName:$,expectedType:Fe}))}for(let[$,ne]of P.argumentDataByName){let z=ne.node;K.has($)||z.type.kind===Re.Kind.NON_NULL_TYPE&&(f=!0,v=!0,U.invalidAdditionalArguments.add($))}!r&&P.isInaccessible&&!g.isInaccessible&&(f=!0,v=!0,U.isInaccessible=!0),v&&p.invalidFieldImplementations.set(y,U)}f&&i.set(c,p)}return a.size>0&&this.errors.push((0,we.invalidImplementedTypeError)(t.name,a)),i.size>0&&this.errors.push((0,we.invalidInterfaceImplementationError)(t.node.name.value,(0,he.kindToNodeType)(t.kind),i)),n}addValidPrimaryKeyTargetsToEntityData(t){var f;let n=this.entityDataByTypeName.get(t);if(!n)return;let r=(0,he.getOrThrowError)(this.internalSubgraphBySubgraphName,this.currentSubgraphName,"internalSubgraphBySubgraphName"),i=r.parentDefinitionDataByTypeName,a=i.get(n.typeName);if(!a||a.kind!==Re.Kind.OBJECT_TYPE_DEFINITION)throw(0,we.incompatibleParentKindFatalError)(n.typeName,Re.Kind.OBJECT_TYPE_DEFINITION,(a==null?void 0:a.kind)||Re.Kind.NULL);let o=r.configurationDataByTypeName.get(n.typeName);if(!o)return;let c=[],l=this.internalGraph.nodeByNodeName.get(`${this.currentSubgraphName}.${n.typeName}`);(0,vc.validateImplicitFieldSets)({conditionalFieldDataByCoords:r.conditionalFieldDataByCoordinates,currentSubgraphName:this.currentSubgraphName,entityData:n,implicitKeys:c,objectData:a,parentDefinitionDataByTypeName:i,graphNode:l});for(let[y,g]of this.entityInterfaceFederationDataByTypeName){if(!((f=g.concreteTypeNames)!=null&&f.has(n.typeName)))continue;let v=this.entityDataByTypeName.get(y);v&&(0,vc.validateImplicitFieldSets)({conditionalFieldDataByCoords:r.conditionalFieldDataByCoordinates,currentSubgraphName:this.currentSubgraphName,entityData:v,implicitKeys:c,objectData:a,parentDefinitionDataByTypeName:i,graphNode:l})}if(c.length<1)return;if(!o.keys||o.keys.length<1){o.isRootNode=!0,o.keys=c;return}let p=new Set(o.keys.map(y=>y.selectionSet));for(let y of c)p.has(y.selectionSet)||(o.keys.push(y),p.add(y.selectionSet))}addValidPrimaryKeyTargetsFromInterfaceObject(t,n,r,i){let a=t.parentDefinitionDataByTypeName,o=a.get(n);if(!o||!(0,ge.isParentDataCompositeOutputType)(o))throw(0,we.incompatibleParentKindFatalError)(n,Re.Kind.INTERFACE_TYPE_DEFINITION,(o==null?void 0:o.kind)||Re.Kind.NULL);let c=(0,he.getOrThrowError)(t.configurationDataByTypeName,r.typeName,"internalSubgraph.configurationDataByTypeName"),l=[];if((0,vc.validateImplicitFieldSets)({conditionalFieldDataByCoords:t.conditionalFieldDataByCoordinates,currentSubgraphName:t.name,entityData:r,implicitKeys:l,objectData:o,parentDefinitionDataByTypeName:a,graphNode:i}),l.length<1)return;if(!c.keys||c.keys.length<1){c.isRootNode=!0,c.keys=l;return}let p=new Set(c.keys.map(f=>f.selectionSet));for(let f of l)p.has(f.selectionSet)||(c.keys.push(f),p.add(f.selectionSet))}getEnumValueMergeMethod(t){return this.namedInputValueTypeNames.has(t)?this.namedOutputTypeNames.has(t)?ge.MergeMethod.CONSISTENT:ge.MergeMethod.INTERSECTION:ge.MergeMethod.UNION}generateTagData(){for(let[t,n]of this.tagNamesByCoords){let r=t.split(".");if(r.length<1)continue;let i=(0,he.getValueOrDefault)(this.parentTagDataByTypeName,r[0],()=>(0,vc.newParentTagData)(r[0]));switch(r.length){case 1:for(let l of n)i.tagNames.add(l);break;case 2:let a=(0,he.getValueOrDefault)(i.childTagDataByChildName,r[1],()=>(0,vc.newChildTagData)(r[1]));for(let l of n)a.tagNames.add(l);break;case 3:let o=(0,he.getValueOrDefault)(i.childTagDataByChildName,r[1],()=>(0,vc.newChildTagData)(r[1])),c=(0,he.getValueOrDefault)(o.tagNamesByArgumentName,r[2],()=>new Set);for(let l of n)c.add(l);break;default:break}}}upsertEnumValueData(t,n,r){let i=t.get(n.name),a=i||this.copyEnumValueData(n);(0,ge.extractPersistedDirectives)(a.persistedDirectivesData,n.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName);let o=(0,ge.isNodeDataInaccessible)(n);if((r||o)&&this.inaccessibleCoords.add(a.federatedCoords),this.recordTagNamesByCoords(a,a.federatedCoords),!i){t.set(a.name,a);return}a.appearances+=1,(0,he.addNewObjectValueMapEntries)(n.configureDescriptionDataBySubgraphName,a.configureDescriptionDataBySubgraphName),(0,ge.setLongestDescription)(a,n),(0,he.addIterableValuesToSet)(n.subgraphNames,a.subgraphNames)}upsertInputValueData(t,n,r,i){let a=t.get(n.name),o=a||this.copyInputValueData(n);if((0,ge.extractPersistedDirectives)(o.persistedDirectivesData,n.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),this.recordTagNamesByCoords(o,`${r}.${o.name}`),this.namedInputValueTypeNames.add(o.namedTypeName),(0,he.getValueOrDefault)(this.coordsByNamedTypeName,o.namedTypeName,()=>new Set).add(o.federatedCoords),!a){t.set(o.name,o);return}(0,he.addNewObjectValueMapEntries)(n.configureDescriptionDataBySubgraphName,o.configureDescriptionDataBySubgraphName),(0,ge.setLongestDescription)(o,n),(0,he.addIterableValuesToSet)(n.requiredSubgraphNames,o.requiredSubgraphNames),(0,he.addIterableValuesToSet)(n.subgraphNames,o.subgraphNames),this.handleInputValueInaccessibility(i,o,r);let c=(0,Jl.getMostRestrictiveMergedTypeNode)(o.type,n.type,o.originalCoords,this.errors);c.success?o.type=c.typeNode:this.errors.push((0,we.incompatibleMergedTypesError)({actualType:c.actualType,isArgument:a.isArgument,coords:a.federatedCoords,expectedType:c.expectedType})),(0,ge.compareAndValidateInputValueDefaultValues)(o,n,this.errors)}handleInputValueInaccessibility(t,n,r){if(t){this.inaccessibleRequiredInputValueErrorByCoords.delete(n.federatedCoords),this.inaccessibleCoords.add(n.federatedCoords);return}if((0,ge.isNodeDataInaccessible)(n)){if((0,ge.isTypeRequired)(n.type)){this.inaccessibleRequiredInputValueErrorByCoords.set(n.federatedCoords,(0,we.inaccessibleRequiredInputValueError)(n,r));return}this.inaccessibleCoords.add(n.federatedCoords)}}handleSubscriptionFilterDirective(t,n){let r=t.directivesByDirectiveName.get(Oe.SUBSCRIPTION_FILTER);if(!r)return;let i=(0,he.getSingleSetEntry)(t.subgraphNames);if(i===void 0){this.errors.push((0,we.unknownFieldSubgraphNameError)(t.federatedCoords));return}this.subscriptionFilterDataByFieldPath.set(t.federatedCoords,{directive:r[0],fieldData:n||t,directiveSubgraphName:i})}federateOutputType({current:t,other:n,coords:r,mostRestrictive:i}){n=(0,Xq.getMutableTypeNode)(n,r,this.errors);let a={kind:t.kind},o=Jl.DivergentType.NONE,c=a;for(let l=0;lnew Set))}upsertFieldData(t,n,r){let i=t.get(n.name),a=i||this.copyFieldData(n,r||(0,ge.isNodeDataInaccessible)(n));(0,he.getValueOrDefault)(this.coordsByNamedTypeName,n.namedTypeName,()=>new Set).add(a.federatedCoords),this.namedOutputTypeNames.add(n.namedTypeName),this.handleSubscriptionFilterDirective(n,a),(0,ge.extractPersistedDirectives)(a.persistedDirectivesData,n.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName);let o=r||(0,ge.isNodeDataInaccessible)(a);if(o&&this.inaccessibleCoords.add(a.federatedCoords),this.recordTagNamesByCoords(a,a.federatedCoords),!i){t.set(a.name,a);return}let c=this.federateOutputType({current:a.type,other:n.type,coords:a.federatedCoords,mostRestrictive:!1});if(c.success)if(a.type=c.typeNode,a.namedTypeName!==n.namedTypeName){let l=(0,he.getValueOrDefault)(this.subgraphNamesByNamedTypeNameByFieldCoords,a.federatedCoords,()=>new Map),p=(0,he.getValueOrDefault)(l,a.namedTypeName,()=>new Set);if(p.size<1)for(let f of a.subgraphNames)n.subgraphNames.has(f)||p.add(f);(0,he.addIterableValuesToSet)(n.subgraphNames,(0,he.getValueOrDefault)(l,n.namedTypeName,()=>new Set))}else this.addSubgraphNameToExistingFieldNamedTypeDisparity(n);for(let l of n.argumentDataByName.values())this.upsertInputValueData(a.argumentDataByName,l,a.federatedCoords,o);(0,he.addNewObjectValueMapEntries)(n.configureDescriptionDataBySubgraphName,i.configureDescriptionDataBySubgraphName),(0,ge.setLongestDescription)(a,n),a.isInaccessible||(a.isInaccessible=n.isInaccessible),(0,he.addNewObjectValueMapEntries)(n.externalFieldDataBySubgraphName,a.externalFieldDataBySubgraphName),(0,he.addMapEntries)(n.isShareableBySubgraphName,a.isShareableBySubgraphName),(0,he.addIterableValuesToSet)(n.subgraphNames,a.subgraphNames)}getClientSchemaUnionMembers(t){let n=[];for(let[r,i]of t.memberByMemberTypeName)this.inaccessibleCoords.has(r)||n.push(i);return n}recordTagNamesByCoords(t,n){let r=n||t.name;if(t.persistedDirectivesData.tagDirectiveByName.size<1)return;let i=(0,he.getValueOrDefault)(this.tagNamesByCoords,r,()=>new Set);for(let a of t.persistedDirectivesData.tagDirectiveByName.keys())i.add(a)}copyMutualParentDefinitionData(t){return{configureDescriptionDataBySubgraphName:(0,he.copyObjectValueMap)(t.configureDescriptionDataBySubgraphName),directivesByDirectiveName:(0,he.copyArrayValueMap)(t.directivesByDirectiveName),extensionType:t.extensionType,name:t.name,persistedDirectivesData:(0,ge.extractPersistedDirectives)((0,ge.newPersistedDirectivesData)(),t.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),description:(0,ge.getInitialFederatedDescription)(t)}}copyEnumValueData(t){return{appearances:t.appearances,configureDescriptionDataBySubgraphName:(0,he.copyObjectValueMap)(t.configureDescriptionDataBySubgraphName),federatedCoords:t.federatedCoords,directivesByDirectiveName:(0,he.copyArrayValueMap)(t.directivesByDirectiveName),kind:t.kind,name:t.name,node:{directives:[],kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},parentTypeName:t.parentTypeName,persistedDirectivesData:(0,ge.extractPersistedDirectives)((0,ge.newPersistedDirectivesData)(),t.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),subgraphNames:new Set(t.subgraphNames),description:(0,ge.getInitialFederatedDescription)(t)}}copyInputValueData(t){return{configureDescriptionDataBySubgraphName:(0,he.copyObjectValueMap)(t.configureDescriptionDataBySubgraphName),directivesByDirectiveName:(0,he.copyArrayValueMap)(t.directivesByDirectiveName),federatedCoords:t.federatedCoords,fieldName:t.fieldName,includeDefaultValue:t.includeDefaultValue,isArgument:t.isArgument,kind:t.kind,name:t.name,namedTypeKind:t.namedTypeKind,namedTypeName:t.namedTypeName,node:{directives:[],kind:Re.Kind.INPUT_VALUE_DEFINITION,name:(0,kr.stringToNameNode)(t.name),type:t.type},originalCoords:t.originalCoords,originalParentTypeName:t.originalParentTypeName,persistedDirectivesData:(0,ge.extractPersistedDirectives)((0,ge.newPersistedDirectivesData)(),t.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),renamedParentTypeName:t.renamedParentTypeName,requiredSubgraphNames:new Set(t.requiredSubgraphNames),subgraphNames:new Set(t.subgraphNames),type:t.type,defaultValue:t.defaultValue,description:(0,ge.getInitialFederatedDescription)(t)}}copyInputValueDataByValueName(t,n,r){let i=new Map;for(let[a,o]of t){let c=this.copyInputValueData(o);this.handleInputValueInaccessibility(n,c,r),(0,he.getValueOrDefault)(this.coordsByNamedTypeName,c.namedTypeName,()=>new Set).add(c.federatedCoords),this.namedInputValueTypeNames.add(c.namedTypeName),this.recordTagNamesByCoords(c,`${r}.${o.name}`),i.set(a,c)}return i}copyFieldData(t,n){return{argumentDataByName:this.copyInputValueDataByValueName(t.argumentDataByName,n,t.federatedCoords),configureDescriptionDataBySubgraphName:(0,he.copyObjectValueMap)(t.configureDescriptionDataBySubgraphName),directivesByDirectiveName:(0,he.copyArrayValueMap)(t.directivesByDirectiveName),externalFieldDataBySubgraphName:(0,he.copyObjectValueMap)(t.externalFieldDataBySubgraphName),federatedCoords:t.federatedCoords,inheritedDirectiveNames:new Set,isInaccessible:t.isInaccessible,isShareableBySubgraphName:new Map(t.isShareableBySubgraphName),kind:t.kind,name:t.name,namedTypeKind:t.namedTypeKind,namedTypeName:t.namedTypeName,node:{arguments:[],directives:[],kind:t.kind,name:(0,kr.stringToNameNode)(t.name),type:t.type},originalParentTypeName:t.originalParentTypeName,persistedDirectivesData:(0,ge.extractPersistedDirectives)((0,ge.newPersistedDirectivesData)(),t.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),renamedParentTypeName:t.renamedParentTypeName,subgraphNames:new Set(t.subgraphNames),type:t.type,description:(0,ge.getInitialFederatedDescription)(t)}}copyEnumValueDataByValueName(t,n){let r=new Map;for(let[i,a]of t){let o=this.copyEnumValueData(a);this.recordTagNamesByCoords(o,o.federatedCoords),(n||(0,ge.isNodeDataInaccessible)(o))&&this.inaccessibleCoords.add(o.federatedCoords),r.set(i,o)}return r}copyFieldDataByName(t,n){let r=new Map;for(let[i,a]of t){let o=n||(0,ge.isNodeDataInaccessible)(a),c=this.copyFieldData(a,o);this.handleSubscriptionFilterDirective(c),(0,he.getValueOrDefault)(this.coordsByNamedTypeName,c.namedTypeName,()=>new Set).add(c.federatedCoords),this.namedOutputTypeNames.add(c.namedTypeName),this.recordTagNamesByCoords(c,c.federatedCoords),o&&this.inaccessibleCoords.add(c.federatedCoords),r.set(i,c)}return r}copyParentDefinitionData(t){let n=this.copyMutualParentDefinitionData(t);switch(t.kind){case Re.Kind.ENUM_TYPE_DEFINITION:return Y(x({},n),{appearances:t.appearances,enumValueDataByValueName:this.copyEnumValueDataByValueName(t.enumValueDataByValueName,t.isInaccessible),isInaccessible:t.isInaccessible,kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},subgraphNames:new Set(t.subgraphNames)});case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:return Y(x({},n),{inputValueDataByName:this.copyInputValueDataByValueName(t.inputValueDataByName,t.isInaccessible,t.name),isInaccessible:t.isInaccessible,kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},subgraphNames:new Set(t.subgraphNames)});case Re.Kind.INTERFACE_TYPE_DEFINITION:return Y(x({},n),{fieldDataByName:this.copyFieldDataByName(t.fieldDataByName,t.isInaccessible),implementedInterfaceTypeNames:new Set(t.implementedInterfaceTypeNames),isEntity:t.isEntity,isInaccessible:t.isInaccessible,kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},subgraphNames:new Set(t.subgraphNames)});case Re.Kind.OBJECT_TYPE_DEFINITION:return Y(x({},n),{fieldDataByName:this.copyFieldDataByName(t.fieldDataByName,t.isInaccessible),implementedInterfaceTypeNames:new Set(t.implementedInterfaceTypeNames),isEntity:t.isEntity,isInaccessible:t.isInaccessible,isRootType:t.isRootType,kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.renamedTypeName||t.name)},renamedTypeName:t.renamedTypeName,subgraphNames:new Set(t.subgraphNames)});case Re.Kind.SCALAR_TYPE_DEFINITION:return Y(x({},n),{kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},subgraphNames:new Set(t.subgraphNames)});case Re.Kind.UNION_TYPE_DEFINITION:return Y(x({},n),{kind:t.kind,node:{kind:t.kind,name:(0,kr.stringToNameNode)(t.name)},memberByMemberTypeName:new Map(t.memberByMemberTypeName),subgraphNames:new Set(t.subgraphNames)})}}getParentTargetData({existingData:t,incomingData:n}){if(!t){let r=this.copyParentDefinitionData(n);return(0,ge.isParentDataRootType)(r)&&(r.extensionType=eV.ExtensionType.NONE),r}return(0,ge.extractPersistedDirectives)(t.persistedDirectivesData,n.directivesByDirectiveName,this.persistedDirectiveDefinitionByDirectiveName),t}upsertParentDefinitionData(t,n){let r=this.entityInterfaceFederationDataByTypeName.get(t.name),i=this.parentDefinitionDataByTypeName.get(t.name),a=this.getParentTargetData({existingData:i,incomingData:t});this.recordTagNamesByCoords(a);let o=(0,ge.isNodeDataInaccessible)(a);if(o&&this.inaccessibleCoords.add(a.name),r&&r.interfaceObjectSubgraphs.has(n)&&(a.kind=Re.Kind.INTERFACE_TYPE_DEFINITION,a.node.kind=Re.Kind.INTERFACE_TYPE_DEFINITION),!i){this.parentDefinitionDataByTypeName.set(a.name,a);return}if(a.kind!==t.kind&&(!r||!r.interfaceObjectSubgraphs.has(n)||a.kind!==Re.Kind.INTERFACE_TYPE_DEFINITION||t.kind!==Re.Kind.OBJECT_TYPE_DEFINITION)){this.errors.push((0,we.incompatibleParentKindMergeError)(a.name,(0,he.kindToNodeType)(a.kind),(0,he.kindToNodeType)(t.kind)));return}switch((0,he.addNewObjectValueMapEntries)(t.configureDescriptionDataBySubgraphName,a.configureDescriptionDataBySubgraphName),(0,ge.setLongestDescription)(a,t),(0,ge.setParentDataExtensionType)(a,t),a.kind){case Re.Kind.ENUM_TYPE_DEFINITION:if(!(0,ge.areKindsEqual)(a,t))return;a.appearances+=1,a.isInaccessible||(a.isInaccessible=o),(0,he.addIterableValuesToSet)(t.subgraphNames,a.subgraphNames);for(let l of t.enumValueDataByValueName.values())this.upsertEnumValueData(a.enumValueDataByValueName,l,o);return;case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:if(!(0,ge.areKindsEqual)(a,t))return;o&&!a.isInaccessible&&this.propagateInaccessibilityToExistingChildren(a),a.isInaccessible||(a.isInaccessible=o),(0,he.addIterableValuesToSet)(t.subgraphNames,a.subgraphNames);for(let l of t.inputValueDataByName.values())this.upsertInputValueData(a.inputValueDataByName,l,a.name,a.isInaccessible);return;case Re.Kind.INTERFACE_TYPE_DEFINITION:case Re.Kind.OBJECT_TYPE_DEFINITION:let c=t;o&&!a.isInaccessible&&this.propagateInaccessibilityToExistingChildren(a),a.isInaccessible||(a.isInaccessible=o),(0,he.addIterableValuesToSet)(c.implementedInterfaceTypeNames,a.implementedInterfaceTypeNames),(0,he.addIterableValuesToSet)(c.subgraphNames,a.subgraphNames);for(let l of c.fieldDataByName.values())this.upsertFieldData(a.fieldDataByName,l,a.isInaccessible);return;case Re.Kind.UNION_TYPE_DEFINITION:if(!(0,ge.areKindsEqual)(a,t))return;(0,he.addMapEntries)(t.memberByMemberTypeName,a.memberByMemberTypeName),(0,he.addIterableValuesToSet)(t.subgraphNames,a.subgraphNames);return;default:(0,he.addIterableValuesToSet)(t.subgraphNames,a.subgraphNames);return}}propagateInaccessibilityToExistingChildren(t){switch(t.kind){case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:for(let n of t.inputValueDataByName.values())this.inaccessibleCoords.add(n.federatedCoords);break;default:for(let n of t.fieldDataByName.values()){this.inaccessibleCoords.add(n.federatedCoords);for(let r of n.argumentDataByName.values())this.inaccessibleCoords.add(r.federatedCoords)}}}upsertPersistedDirectiveDefinitionData(t,n){let r=t.name,i=this.potentialPersistedDirectiveDefinitionDataByDirectiveName.get(r);if(!i){if(n>1)return;let a=new Map;for(let o of t.argumentDataByArgumentName.values())this.namedInputValueTypeNames.add(o.namedTypeName),this.upsertInputValueData(a,o,`@${t.name}`,!1);this.potentialPersistedDirectiveDefinitionDataByDirectiveName.set(r,{argumentDataByArgumentName:a,executableLocations:new Set(t.executableLocations),name:r,repeatable:t.repeatable,subgraphNames:new Set(t.subgraphNames),description:t.description});return}if(i.subgraphNames.size+1!==n){this.potentialPersistedDirectiveDefinitionDataByDirectiveName.delete(r);return}if((0,ge.setMutualExecutableLocations)(i,t.executableLocations),i.executableLocations.size<1){this.potentialPersistedDirectiveDefinitionDataByDirectiveName.delete(r);return}for(let a of t.argumentDataByArgumentName.values())this.namedInputValueTypeNames.add((0,Xq.getTypeNodeNamedTypeName)(a.type)),this.upsertInputValueData(i.argumentDataByArgumentName,a,`@${i.name}`,!1);(0,ge.setLongestDescription)(i,t),i.repeatable&&(i.repeatable=t.repeatable),(0,he.addIterableValuesToSet)(t.subgraphNames,i.subgraphNames)}shouldUpdateFederatedFieldAbstractNamedType(t,n){if(!t)return!1;let r=this.concreteTypeNamesByAbstractTypeName.get(t);if(!r||r.size<1)return!1;for(let i of n)if(!r.has(i))return!1;return!0}updateTypeNodeNamedType(t,n){let r=t;for(let i=0;i1){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}break}case Re.Kind.UNION_TYPE_DEFINITION:{if(l){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}l=f;break}default:{this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));break}}}if(o.size<0&&!l){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}let p=l;if(o.size>0){if(l){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}for(let f of o.keys()){p=f;for(let[y,g]of o)if(f!==y&&!g.implementedInterfaceTypeNames.has(f)){p="";break}if(p)break}}if(!this.shouldUpdateFederatedFieldAbstractNamedType(p,c)){this.errors.push((0,we.incompatibleFederatedFieldNamedTypeError)(t,n));continue}a.namedTypeName=p,this.updateTypeNodeNamedType(a.type,p)}}federateInternalSubgraphData(){let t=0,n=!1;for(let r of this.internalSubgraphBySubgraphName.values()){t+=1,this.currentSubgraphName=r.name,this.isVersionTwo||(this.isVersionTwo=r.isVersionTwo),(0,Ile.renameRootTypes)(this,r);for(let i of r.parentDefinitionDataByTypeName.values())this.upsertParentDefinitionData(i,r.name);if(!n){if(!r.persistedDirectiveDefinitionDataByDirectiveName.size){n=!0;continue}for(let i of r.persistedDirectiveDefinitionDataByDirectiveName.values())this.upsertPersistedDirectiveDefinitionData(i,t);this.potentialPersistedDirectiveDefinitionDataByDirectiveName.size<1&&(n=!0)}}this.handleDisparateFieldNamedTypes()}handleInterfaceObjectForInternalGraph({entityData:t,internalSubgraph:n,interfaceObjectData:r,interfaceObjectNode:i,resolvableKeyFieldSets:a,subgraphName:o}){let c=this.internalGraph.addOrUpdateNode(t.typeName),l=this.internalGraph.addEntityDataNode(t.typeName);for(let f of i.satisfiedFieldSets)c.satisfiedFieldSets.add(f),a.has(f)&&l.addTargetSubgraphByFieldSet(f,o);let p=r.fieldDatasBySubgraphName.get(o);for(let{name:f,namedTypeName:y}of p||[])this.internalGraph.addEdge(c,this.internalGraph.addOrUpdateNode(y),f);this.internalGraph.addEdge(i,c,t.typeName,!0),this.addValidPrimaryKeyTargetsFromInterfaceObject(n,i.typeName,t,c)}handleEntityInterfaces(){var t;for(let[n,r]of this.entityInterfaceFederationDataByTypeName){let i=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,n,Oe.PARENT_DEFINITION_DATA);if(i.kind===Re.Kind.INTERFACE_TYPE_DEFINITION)for(let a of r.interfaceObjectSubgraphs){let o=(0,he.getOrThrowError)(this.internalSubgraphBySubgraphName,a,"internalSubgraphBySubgraphName"),c=o.configurationDataByTypeName,l=this.concreteTypeNamesByAbstractTypeName.get(n);if(!l)continue;let p=(0,he.getOrThrowError)(c,n,"configurationDataByTypeName"),f=p.keys;if(!f)continue;p.entityInterfaceConcreteTypeNames=new Set(r.concreteTypeNames),this.internalGraph.setSubgraphName(a);let y=this.internalGraph.addOrUpdateNode(n,{isAbstract:!0});for(let g of l){let v=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,g,Oe.PARENT_DEFINITION_DATA);if(!(0,ti.isObjectDefinitionData)(v))continue;let P=(0,he.getOrThrowError)(this.entityDataByTypeName,g,"entityDataByTypeName");P.subgraphNames.add(a);let U=c.get(g);if(U)if((0,he.addIterableValuesToSet)(p.fieldNames,U.fieldNames),!U.keys)U.keys=[...f];else e:for(let z of f){for(let{selectionSet:Te}of U.keys)if(z.selectionSet===Te)continue e;U.keys.push(z)}else c.set(g,{fieldNames:new Set(p.fieldNames),isRootNode:!0,keys:[...f],typeName:g});let K=new Set;for(let z of f.filter(Te=>!Te.disableEntityResolver))K.add(z.selectionSet);let $=this.authorizationDataByParentTypeName.get(n),ne=(0,he.getOrThrowError)(o.parentDefinitionDataByTypeName,n,"internalSubgraph.parentDefinitionDataByTypeName");if((0,ti.isObjectDefinitionData)(ne)){for(let[z,Te]of ne.fieldDataByName){let pe=`${g}.${z}`;(0,he.getValueOrDefault)(this.fieldCoordsByNamedTypeName,Te.namedTypeName,()=>new Set).add(pe);let Fe=$==null?void 0:$.fieldAuthDataByFieldName.get(z);if(Fe){let X=(0,he.getValueOrDefault)(this.authorizationDataByParentTypeName,g,()=>(0,ti.newAuthorizationData)(g));(0,ti.upsertFieldAuthorizationData)(X.fieldAuthDataByFieldName,Fe)||this.invalidORScopesCoords.add(pe)}let xe=v.fieldDataByName.get(z);if(xe){let X=(t=Te.isShareableBySubgraphName.get(a))!=null?t:!1;xe.isShareableBySubgraphName.set(a,X),xe.subgraphNames.add(a);let ve=Te.externalFieldDataBySubgraphName.get(a);if(!ve)continue;xe.externalFieldDataBySubgraphName.set(a,x({},ve));continue}let et=i.isInaccessible||v.isInaccessible||Te.isInaccessible;v.fieldDataByName.set(z,this.copyFieldData(Te,et))}this.handleInterfaceObjectForInternalGraph({internalSubgraph:o,subgraphName:a,interfaceObjectData:r,interfaceObjectNode:y,resolvableKeyFieldSets:K,entityData:P})}}}}}fieldDataToGraphFieldData(t){var n;return{name:t.name,namedTypeName:t.namedTypeName,isLeaf:(0,ti.isNodeLeaf)((n=this.parentDefinitionDataByTypeName.get(t.namedTypeName))==null?void 0:n.kind),subgraphNames:t.subgraphNames}}getValidFlattenedPersistedDirectiveNodeArray(t,n){let r=[];for(let[i,a]of t){let o=this.persistedDirectiveDefinitionByDirectiveName.get(i);if(o){if(a.length<2){r.push(...a);continue}if(!o.repeatable){this.errors.push((0,we.invalidRepeatedFederatedDirectiveErrorMessage)(i,n));continue}r.push(...a)}}return r}getRouterPersistedDirectiveNodes(t){let n=[...t.persistedDirectivesData.tagDirectiveByName.values()];return t.persistedDirectivesData.isDeprecated&&n.push((0,ge.generateDeprecatedDirective)(t.persistedDirectivesData.deprecatedReason)),n.push(...this.getValidFlattenedPersistedDirectiveNodeArray(t.persistedDirectivesData.directivesByDirectiveName,t.name)),n}getFederatedGraphNodeDescription(t){if(t.configureDescriptionDataBySubgraphName.size<1)return t.description;let n=[],r="";for(let[i,{propagate:a,description:o}]of t.configureDescriptionDataBySubgraphName)a&&(n.push(i),r=o);if(n.length===1)return(0,vc.getDescriptionFromString)(r);if(n.length<1)return t.description;this.errors.push((0,we.configureDescriptionPropagationError)((0,ge.getDefinitionDataCoords)(t,!0),n))}getNodeForRouterSchemaByData(t){return t.node.name=(0,kr.stringToNameNode)(t.name),t.node.description=this.getFederatedGraphNodeDescription(t),t.node.directives=this.getRouterPersistedDirectiveNodes(t),t.node}getNodeWithPersistedDirectivesByInputValueData(t){return t.node.name=(0,kr.stringToNameNode)(t.name),t.node.type=t.type,t.node.description=this.getFederatedGraphNodeDescription(t),t.node.directives=this.getRouterPersistedDirectiveNodes(t),t.includeDefaultValue&&(t.node.defaultValue=t.defaultValue),t.node}getValidFieldArgumentNodes(t){let n=[],r=[],i=[],a=`${t.renamedParentTypeName}.${t.name}`;for(let[o,c]of t.argumentDataByName)t.subgraphNames.size===c.subgraphNames.size?(r.push(o),n.push(this.getNodeWithPersistedDirectivesByInputValueData(c))):(0,ge.isTypeRequired)(c.type)&&i.push({inputValueName:o,missingSubgraphs:(0,he.getEntriesNotInHashSet)(t.subgraphNames,c.subgraphNames),requiredSubgraphs:[...c.requiredSubgraphNames]});return i.length>0?this.errors.push((0,we.invalidRequiredInputValueError)(Oe.FIELD,a,i)):r.length>0&&((0,he.getValueOrDefault)(this.fieldConfigurationByFieldCoords,a,()=>({argumentNames:r,fieldName:t.name,typeName:t.renamedParentTypeName})).argumentNames=r),n}getNodeWithPersistedDirectivesByFieldData(t,n){return t.node.arguments=n,t.node.name=(0,kr.stringToNameNode)(t.name),t.node.type=t.type,t.node.description=this.getFederatedGraphNodeDescription(t),t.node.directives=this.getRouterPersistedDirectiveNodes(t),t.node}pushParentDefinitionDataToDocumentDefinitions(t){for(let[n,r]of this.parentDefinitionDataByTypeName)switch(r.extensionType!==eV.ExtensionType.NONE&&this.errors.push((0,we.noBaseDefinitionForExtensionError)((0,he.kindToNodeType)(r.kind),n)),r.kind){case Re.Kind.ENUM_TYPE_DEFINITION:let i=[],a=[],o=this.getEnumValueMergeMethod(n);(0,ge.propagateAuthDirectives)(r,this.authorizationDataByParentTypeName.get(n));for(let ne of r.enumValueDataByValueName.values()){let z=(0,ge.getNodeForRouterSchemaByData)(ne,this.persistedDirectiveDefinitionByDirectiveName,this.errors),Te=(0,ge.isNodeDataInaccessible)(ne),pe=Y(x({},ne.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(ne)});switch(o){case ge.MergeMethod.CONSISTENT:!Te&&r.appearances>ne.appearances&&this.errors.push((0,we.incompatibleSharedEnumError)(n)),i.push(z),Te||a.push(pe);break;case ge.MergeMethod.INTERSECTION:r.appearances===ne.appearances&&(i.push(z),Te||a.push(pe));break;default:i.push(z),Te||a.push(pe);break}}if(r.node.values=i,this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r)),(0,ge.isNodeDataInaccessible)(r)){this.validateReferencesOfInaccessibleType(r),this.internalGraph.setNodeInaccessible(r.name);break}if(a.length<1){this.errors.push((0,we.allChildDefinitionsAreInaccessibleError)((0,he.kindToNodeType)(r.kind),n,Oe.ENUM_VALUE));break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r),values:a}));break;case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:let c=[],l=[],p=[];for(let[ne,z]of r.inputValueDataByName)if(r.subgraphNames.size===z.subgraphNames.size){if(l.push(this.getNodeWithPersistedDirectivesByInputValueData(z)),(0,ge.isNodeDataInaccessible)(z))continue;p.push(Y(x({},z.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(z)}))}else(0,ge.isTypeRequired)(z.type)&&c.push({inputValueName:ne,missingSubgraphs:(0,he.getEntriesNotInHashSet)(r.subgraphNames,z.subgraphNames),requiredSubgraphs:[...z.requiredSubgraphNames]});if(c.length>0){this.errors.push((0,we.invalidRequiredInputValueError)(Oe.INPUT_OBJECT,n,c,!1));break}if(r.node.fields=l,this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r)),(0,ge.isNodeDataInaccessible)(r)){this.validateReferencesOfInaccessibleType(r);break}if(p.length<1){this.errors.push((0,we.allChildDefinitionsAreInaccessibleError)((0,he.kindToNodeType)(r.kind),n,"input field"));break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r),fields:p}));break;case Re.Kind.INTERFACE_TYPE_DEFINITION:case Re.Kind.OBJECT_TYPE_DEFINITION:let f=[],y=[],g=new Map,v=(0,ge.newInvalidFieldNames)(),P=r.kind===Re.Kind.OBJECT_TYPE_DEFINITION,U=this.authorizationDataByParentTypeName.get(n);(0,ge.propagateAuthDirectives)(r,U);for(let[ne,z]of r.fieldDataByName){(0,ge.propagateFieldAuthDirectives)(z,U);let Te=this.getValidFieldArgumentNodes(z);P&&(0,ge.validateExternalAndShareable)(z,v),f.push(this.getNodeWithPersistedDirectivesByFieldData(z,Te)),!(0,ge.isNodeDataInaccessible)(z)&&(y.push((0,ge.getClientSchemaFieldNodeByFieldData)(z)),g.set(ne,this.fieldDataToGraphFieldData(z)))}if(P&&(v.byShareable.size>0&&this.errors.push((0,we.invalidFieldShareabilityError)(r,v.byShareable)),v.subgraphNamesByExternalFieldName.size>0&&this.errors.push((0,we.allExternalFieldInstancesError)(n,v.subgraphNamesByExternalFieldName))),r.node.fields=f,this.internalGraph.initializeNode(n,g),r.implementedInterfaceTypeNames.size>0){t.push({data:r,clientSchemaFieldNodes:y});break}this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r));let K=(0,yle.isNodeQuery)(n);if((0,ge.isNodeDataInaccessible)(r)){if(K){this.errors.push(we.inaccessibleQueryRootTypeError);break}this.validateReferencesOfInaccessibleType(r),this.internalGraph.setNodeInaccessible(r.name);break}if(y.length<1){let ne=K?(0,we.noQueryRootTypeError)(!1):(0,we.allChildDefinitionsAreInaccessibleError)((0,he.kindToNodeType)(r.kind),n,Oe.FIELD);this.errors.push(ne);break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r),fields:y}));break;case Re.Kind.SCALAR_TYPE_DEFINITION:if(jn.BASE_SCALARS.has(n))break;if((0,ge.propagateAuthDirectives)(r,this.authorizationDataByParentTypeName.get(n)),this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r)),(0,ge.isNodeDataInaccessible)(r)){this.validateReferencesOfInaccessibleType(r),this.internalGraph.setNodeInaccessible(r.name);break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r)}));break;case Re.Kind.UNION_TYPE_DEFINITION:if(r.node.types=(0,ti.mapToArrayOfValues)(r.memberByMemberTypeName),this.routerDefinitions.push(this.getNodeForRouterSchemaByData(r)),(0,ge.isNodeDataInaccessible)(r)){this.validateReferencesOfInaccessibleType(r),this.internalGraph.setNodeInaccessible(r.name);break}let $=this.getClientSchemaUnionMembers(r);if($.length<1){this.errors.push((0,we.allChildDefinitionsAreInaccessibleError)(Oe.UNION,n,"union member type"));break}this.clientDefinitions.push(Y(x({},r.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(r),types:$}));break}}pushNamedTypeAuthDataToFields(){var t;for(let[n,r]of this.authorizationDataByParentTypeName){if(!r.requiresAuthentication&&r.requiredScopes.length<1)continue;let i=this.fieldCoordsByNamedTypeName.get(n);if(i)for(let a of i){let o=a.split(Oe.PERIOD);switch(o.length){case 2:{let c=(0,he.getValueOrDefault)(this.authorizationDataByParentTypeName,o[0],()=>(0,ti.newAuthorizationData)(o[0])),l=(0,he.getValueOrDefault)(c.fieldAuthDataByFieldName,o[1],()=>(0,ti.newFieldAuthorizationData)(o[1]));(t=l.inheritedData).requiresAuthentication||(t.requiresAuthentication=r.requiresAuthentication),l.inheritedData.requiredScopes.length*r.requiredScopes.length>jn.MAX_OR_SCOPES?this.invalidORScopesCoords.add(a):(l.inheritedData.requiredScopesByOR=(0,ti.mergeRequiredScopesByAND)(l.inheritedData.requiredScopesByOR,r.requiredScopesByOR),l.inheritedData.requiredScopes=(0,ti.mergeRequiredScopesByAND)(l.inheritedData.requiredScopes,r.requiredScopes));break}default:break}}}}federateSubgraphData(){this.federateInternalSubgraphData(),this.handleEntityInterfaces(),this.generateTagData(),this.pushVersionTwoDirectiveDefinitionsToDocumentDefinitions(),this.pushNamedTypeAuthDataToFields()}validateInterfaceImplementationsAndPushToDocumentDefinitions(t){for(let{data:n,clientSchemaFieldNodes:r}of t){if(n.node.interfaces=this.getValidImplementedInterfaces(n),this.routerDefinitions.push((0,ge.getNodeForRouterSchemaByData)(n,this.persistedDirectiveDefinitionByDirectiveName,this.errors)),(0,ge.isNodeDataInaccessible)(n)){this.validateReferencesOfInaccessibleType(n),this.internalGraph.setNodeInaccessible(n.name);continue}let i=[];for(let a of n.implementedInterfaceTypeNames)this.inaccessibleCoords.has(a)||i.push((0,kr.stringToNamedTypeNode)(a));this.clientDefinitions.push(Y(x({},n.node),{directives:(0,ge.getClientPersistedDirectiveNodes)(n),fields:r,interfaces:i}))}}pushVersionTwoDirectiveDefinitionsToDocumentDefinitions(){this.isVersionTwo&&(this.routerDefinitions=[jn.AUTHENTICATED_DEFINITION,jn.DEPRECATED_DEFINITION,jn.INACCESSIBLE_DEFINITION,jn.REQUIRES_SCOPES_DEFINITION,jn.TAG_DEFINITION,jn.SCOPE_SCALAR_DEFINITION],this.clientDefinitions=[jn.DEPRECATED_DEFINITION])}validatePathSegmentInaccessibility(t){if(!t)return!1;let r=t.split(Oe.LEFT_PARENTHESIS)[0].split(Oe.PERIOD),i=r[0];for(let a=0;a0&&this.errors.push((0,we.invalidReferencesOfInaccessibleTypeError)((0,he.kindToNodeType)(t.kind),t.name,r))}validateQueryRootType(){let t=this.parentDefinitionDataByTypeName.get(Oe.QUERY);if(!t||t.kind!==Re.Kind.OBJECT_TYPE_DEFINITION||t.fieldDataByName.size<1){this.errors.push((0,we.noQueryRootTypeError)());return}for(let n of t.fieldDataByName.values())if(!(0,ge.isNodeDataInaccessible)(n))return;this.errors.push((0,we.noQueryRootTypeError)())}validateSubscriptionFieldConditionFieldPath(t,n,r,i,a){let o=t.split(Oe.PERIOD);if(o.length<1)return a.push((0,we.invalidSubscriptionFieldConditionFieldPathErrorMessage)(r,t)),[];let c=n;if(this.inaccessibleCoords.has(c.renamedTypeName))return a.push((0,we.inaccessibleSubscriptionFieldConditionFieldPathFieldErrorMessage)(r,t,o[0],c.renamedTypeName)),[];let l="";for(let p=0;p0?`.${f}`:f,c.kind!==Re.Kind.OBJECT_TYPE_DEFINITION)return a.push((0,we.invalidSubscriptionFieldConditionFieldPathParentErrorMessage)(r,t,l)),[];let y=c.fieldDataByName.get(f);if(!y)return a.push((0,we.undefinedSubscriptionFieldConditionFieldPathFieldErrorMessage)(r,t,l,f,c.renamedTypeName)),[];let g=`${c.renamedTypeName}.${f}`;if(!y.subgraphNames.has(i))return a.push((0,we.invalidSubscriptionFieldConditionFieldPathFieldErrorMessage)(r,t,l,g,i)),[];if(this.inaccessibleCoords.has(g))return a.push((0,we.inaccessibleSubscriptionFieldConditionFieldPathFieldErrorMessage)(r,t,l,g)),[];if(jn.BASE_SCALARS.has(y.namedTypeName)){c={kind:Re.Kind.SCALAR_TYPE_DEFINITION,name:y.namedTypeName};continue}c=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,y.namedTypeName,Oe.PARENT_DEFINITION_DATA)}return(0,ge.isLeafKind)(c.kind)?o:(a.push((0,we.nonLeafSubscriptionFieldConditionFieldPathFinalFieldErrorMessage)(r,t,o[o.length-1],(0,he.kindToNodeType)(c.kind),c.name)),[])}validateSubscriptionFieldCondition(t,n,r,i,a,o,c){if(i>FE.MAX_SUBSCRIPTION_FILTER_DEPTH||this.isMaxDepth)return c.push((0,we.subscriptionFilterConditionDepthExceededErrorMessage)(a)),this.isMaxDepth=!0,!1;let l=!1,p=new Set([Oe.FIELD_PATH,Oe.VALUES]),f=new Set,y=new Set,g=[];for(let v of t.fields){let P=v.name.value,U=a+`.${P}`;switch(P){case Oe.FIELD_PATH:{if(p.has(Oe.FIELD_PATH))p.delete(Oe.FIELD_PATH);else{l=!0,f.add(Oe.FIELD_PATH);break}if(v.value.kind!==Re.Kind.STRING){g.push((0,we.invalidInputFieldTypeErrorMessage)(U,Oe.STRING,(0,he.kindToNodeType)(v.value.kind))),l=!0;break}let K=this.validateSubscriptionFieldConditionFieldPath(v.value.value,r,U,o,g);if(K.length<1){l=!0;break}n.fieldPath=K;break}case Oe.VALUES:{if(p.has(Oe.VALUES))p.delete(Oe.VALUES);else{l=!0,f.add(Oe.VALUES);break}let K=v.value.kind;if(K==Re.Kind.NULL||K==Re.Kind.OBJECT){g.push((0,we.invalidInputFieldTypeErrorMessage)(U,Oe.LIST,(0,he.kindToNodeType)(v.value.kind))),l=!0;break}if(K!==Re.Kind.LIST){n.values=[(0,ge.getSubscriptionFilterValue)(v.value)];break}let $=new Set,ne=[];for(let z=0;z0){g.push((0,we.subscriptionFieldConditionInvalidValuesArrayErrorMessage)(U,ne));continue}if($.size<1){l=!0,g.push((0,we.subscriptionFieldConditionEmptyValuesArrayErrorMessage)(U));continue}n.values=[...$];break}default:l=!0,y.add(P)}}return l?(c.push((0,we.subscriptionFieldConditionInvalidInputFieldErrorMessage)(a,[...p],[...f],[...y],g)),!1):!0}validateSubscriptionFilterCondition(t,n,r,i,a,o,c){if(i>FE.MAX_SUBSCRIPTION_FILTER_DEPTH||this.isMaxDepth)return c.push((0,we.subscriptionFilterConditionDepthExceededErrorMessage)(a)),this.isMaxDepth=!0,!1;if(i+=1,t.fields.length!==1)return c.push((0,we.subscriptionFilterConditionInvalidInputFieldNumberErrorMessage)(a,t.fields.length)),!1;let l=t.fields[0],p=l.name.value;if(!Zq.SUBSCRIPTION_FILTER_INPUT_NAMES.has(p))return c.push((0,we.subscriptionFilterConditionInvalidInputFieldErrorMessage)(a,p)),!1;let f=a+`.${p}`;switch(l.value.kind){case Re.Kind.OBJECT:switch(p){case Oe.IN_UPPER:return n.in={fieldPath:[],values:[]},this.validateSubscriptionFieldCondition(l.value,n.in,r,i,a+".IN",o,c);case Oe.NOT_UPPER:return n.not={},this.validateSubscriptionFilterCondition(l.value,n.not,r,i,a+".NOT",o,c);default:return c.push((0,we.subscriptionFilterConditionInvalidInputFieldTypeErrorMessage)(f,Oe.LIST,Oe.OBJECT)),!1}case Re.Kind.LIST:{let y=[];switch(p){case Oe.AND_UPPER:{n.and=y;break}case Oe.OR_UPPER:{n.or=y;break}default:return c.push((0,we.subscriptionFilterConditionInvalidInputFieldTypeErrorMessage)(f,Oe.OBJECT,Oe.LIST)),!1}let g=l.value.values.length;if(g<1||g>5)return c.push((0,we.subscriptionFilterArrayConditionInvalidLengthErrorMessage)(f,g)),!1;let v=!0,P=[];for(let U=0;U0?(c.push((0,we.subscriptionFilterArrayConditionInvalidItemTypeErrorMessage)(f,P)),!1):v}default:{let y=Zq.SUBSCRIPTION_FILTER_LIST_INPUT_NAMES.has(p)?Oe.LIST:Oe.OBJECT;return c.push((0,we.subscriptionFilterConditionInvalidInputFieldTypeErrorMessage)(f,y,(0,he.kindToNodeType)(l.value.kind))),!1}}}validateSubscriptionFilterAndGenerateConfiguration(t,n,r,i,a,o){if(!t.arguments||t.arguments.length!==1)return;let c=t.arguments[0];if(c.value.kind!==Re.Kind.OBJECT){this.errors.push((0,we.invalidSubscriptionFilterDirectiveError)(r,[(0,we.subscriptionFilterConditionInvalidInputFieldTypeErrorMessage)(Oe.CONDITION,Oe.OBJECT,(0,he.kindToNodeType)(c.value.kind))]));return}let l={},p=[];if(!this.validateSubscriptionFilterCondition(c.value,l,n,0,Oe.CONDITION,o,p)){this.errors.push((0,we.invalidSubscriptionFilterDirectiveError)(r,p)),this.isMaxDepth=!1;return}(0,he.getValueOrDefault)(this.fieldConfigurationByFieldCoords,r,()=>({argumentNames:[],fieldName:i,typeName:a})).subscriptionFilterCondition=l}validateSubscriptionFiltersAndGenerateConfiguration(){for(let[t,n]of this.subscriptionFilterDataByFieldPath){if(this.inaccessibleCoords.has(t))continue;let r=this.parentDefinitionDataByTypeName.get(n.fieldData.namedTypeName);if(!r){this.errors.push((0,we.invalidSubscriptionFilterDirectiveError)(t,[(0,we.subscriptionFilterNamedTypeErrorMessage)(n.fieldData.namedTypeName)]));continue}(0,ge.isNodeDataInaccessible)(r)||r.kind===Re.Kind.OBJECT_TYPE_DEFINITION&&this.validateSubscriptionFilterAndGenerateConfiguration(n.directive,r,t,n.fieldData.name,n.fieldData.renamedParentTypeName,n.directiveSubgraphName)}}buildFederationResult(){this.subscriptionFilterDataByFieldPath.size>0&&this.validateSubscriptionFiltersAndGenerateConfiguration(),this.invalidORScopesCoords.size>0&&this.errors.push((0,we.orScopesLimitError)(jn.MAX_OR_SCOPES,[...this.invalidORScopesCoords]));for(let a of this.potentialPersistedDirectiveDefinitionDataByDirectiveName.values())(0,ge.addValidPersistedDirectiveDefinitionNodeByData)(this.routerDefinitions,a,this.persistedDirectiveDefinitionByDirectiveName,this.errors);let t=[];this.pushParentDefinitionDataToDocumentDefinitions(t),this.validateInterfaceImplementationsAndPushToDocumentDefinitions(t),this.validateQueryRootType();for(let a of this.inaccessibleRequiredInputValueErrorByCoords.values())this.errors.push(a);if(this.errors.length>0)return{errors:this.errors,success:!1,warnings:this.warnings};if(!this.disableResolvabilityValidation&&this.internalSubgraphBySubgraphName.size>1){let a=this.internalGraph.validate();if(a.length>0)return{errors:a,success:!1,warnings:this.warnings}}let n={kind:Re.Kind.DOCUMENT,definitions:this.routerDefinitions},r=(0,Re.buildASTSchema)({kind:Re.Kind.DOCUMENT,definitions:this.clientDefinitions},{assumeValid:!0,assumeValidSDL:!0}),i=new Map;for(let a of this.internalSubgraphBySubgraphName.values())i.set(a.name,{configurationDataByTypeName:a.configurationDataByTypeName,isVersionTwo:a.isVersionTwo,parentDefinitionDataByTypeName:a.parentDefinitionDataByTypeName,schema:a.schema});for(let a of this.authorizationDataByParentTypeName.values())(0,ti.upsertAuthorizationConfiguration)(this.fieldConfigurationByFieldCoords,a);return x({fieldConfigurations:Array.from(this.fieldConfigurationByFieldCoords.values()),subgraphConfigBySubgraphName:i,federatedGraphAST:n,federatedGraphSchema:(0,Re.buildASTSchema)(n,{assumeValid:!0,assumeValidSDL:!0}),federatedGraphClientSchema:r,parentDefinitionDataByTypeName:this.parentDefinitionDataByTypeName,success:!0,warnings:this.warnings},this.getClientSchemaObjectBoolean())}getClientSchemaObjectBoolean(){return this.inaccessibleCoords.size<1&&this.tagNamesByCoords.size<1?{}:{shouldIncludeClientSchema:!0}}handleChildTagExclusions(t,n,r,i){let a=n.size;for(let[o,c]of r){let l=(0,he.getOrThrowError)(n,o,`${t.name}.childDataByChildName`);if((0,ge.isNodeDataInaccessible)(l)){a-=1;continue}i.isDisjointFrom(c.tagNames)||((0,he.getValueOrDefault)(l.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(`${t.name}.${o}`),a-=1)}a<1&&(t.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(t.name))}handleChildTagInclusions(t,n,r,i){let a=n.size;for(let[o,c]of n){if((0,ge.isNodeDataInaccessible)(c)){a-=1;continue}let l=r.get(o);(!l||i.isDisjointFrom(l.tagNames))&&((0,he.getValueOrDefault)(c.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(`${t.name}.${o}`),a-=1)}a<1&&(t.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(t.name))}buildFederationContractResult(t){if(this.isVersionTwo||this.routerDefinitions.push(jn.INACCESSIBLE_DEFINITION),t.tagNamesToExclude.size>0)for(let[o,c]of this.parentTagDataByTypeName){let l=(0,he.getOrThrowError)(this.parentDefinitionDataByTypeName,o,Oe.PARENT_DEFINITION_DATA);if(!(0,ge.isNodeDataInaccessible)(l)){if(!t.tagNamesToExclude.isDisjointFrom(c.tagNames)){l.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o);continue}if(!(c.childTagDataByChildName.size<1))switch(l.kind){case Re.Kind.SCALAR_TYPE_DEFINITION:case Re.Kind.UNION_TYPE_DEFINITION:continue;case Re.Kind.ENUM_TYPE_DEFINITION:this.handleChildTagExclusions(l,l.enumValueDataByValueName,c.childTagDataByChildName,t.tagNamesToExclude);break;case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:this.handleChildTagExclusions(l,l.inputValueDataByName,c.childTagDataByChildName,t.tagNamesToExclude);break;default:let p=l.fieldDataByName.size;for(let[f,y]of c.childTagDataByChildName){let g=(0,he.getOrThrowError)(l.fieldDataByName,f,`${o}.fieldDataByFieldName`);if((0,ge.isNodeDataInaccessible)(g)){p-=1;continue}if(!t.tagNamesToExclude.isDisjointFrom(y.tagNames)){(0,he.getValueOrDefault)(g.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(g.federatedCoords),p-=1;continue}for(let[v,P]of y.tagNamesByArgumentName){let U=(0,he.getOrThrowError)(g.argumentDataByName,v,`${f}.argumentDataByArgumentName`);(0,ge.isNodeDataInaccessible)(U)||P.isDisjointFrom(P)||((0,he.getValueOrDefault)(U.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(U.federatedCoords))}}p<1&&(l.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o))}}}else if(t.tagNamesToInclude.size>0)for(let[o,c]of this.parentDefinitionDataByTypeName){if((0,ge.isNodeDataInaccessible)(c))continue;let l=this.parentTagDataByTypeName.get(o);if(!l){c.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o);continue}if(t.tagNamesToInclude.isDisjointFrom(l.tagNames)){if(l.childTagDataByChildName.size<1){c.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o);continue}switch(c.kind){case Re.Kind.SCALAR_TYPE_DEFINITION:case Re.Kind.UNION_TYPE_DEFINITION:continue;case Re.Kind.ENUM_TYPE_DEFINITION:this.handleChildTagInclusions(c,c.enumValueDataByValueName,l.childTagDataByChildName,t.tagNamesToInclude);break;case Re.Kind.INPUT_OBJECT_TYPE_DEFINITION:this.handleChildTagInclusions(c,c.inputValueDataByName,l.childTagDataByChildName,t.tagNamesToInclude);break;default:let p=c.fieldDataByName.size;for(let[f,y]of c.fieldDataByName){if((0,ge.isNodeDataInaccessible)(y)){p-=1;continue}let g=l.childTagDataByChildName.get(f);(!g||t.tagNamesToInclude.isDisjointFrom(g.tagNames))&&((0,he.getValueOrDefault)(y.persistedDirectivesData.directivesByDirectiveName,Oe.INACCESSIBLE,()=>[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(y.federatedCoords),p-=1)}p<1&&(c.persistedDirectivesData.directivesByDirectiveName.set(Oe.INACCESSIBLE,[(0,he.generateSimpleDirective)(Oe.INACCESSIBLE)]),this.inaccessibleCoords.add(o))}}}this.subscriptionFilterDataByFieldPath.size>0&&this.validateSubscriptionFiltersAndGenerateConfiguration();for(let o of this.potentialPersistedDirectiveDefinitionDataByDirectiveName.values())(0,ge.addValidPersistedDirectiveDefinitionNodeByData)(this.routerDefinitions,o,this.persistedDirectiveDefinitionByDirectiveName,this.errors);let n=[];if(this.pushParentDefinitionDataToDocumentDefinitions(n),this.validateInterfaceImplementationsAndPushToDocumentDefinitions(n),this.validateQueryRootType(),this.errors.length>0)return{errors:this.errors,success:!1,warnings:this.warnings};let r={kind:Re.Kind.DOCUMENT,definitions:this.routerDefinitions},i=(0,Re.buildASTSchema)({kind:Re.Kind.DOCUMENT,definitions:this.clientDefinitions},{assumeValid:!0,assumeValidSDL:!0}),a=new Map;for(let o of this.internalSubgraphBySubgraphName.values())a.set(o.name,{configurationDataByTypeName:o.configurationDataByTypeName,isVersionTwo:o.isVersionTwo,parentDefinitionDataByTypeName:o.parentDefinitionDataByTypeName,schema:o.schema});for(let o of this.authorizationDataByParentTypeName.values())(0,ti.upsertAuthorizationConfiguration)(this.fieldConfigurationByFieldCoords,o);return x({fieldConfigurations:Array.from(this.fieldConfigurationByFieldCoords.values()),subgraphConfigBySubgraphName:a,federatedGraphAST:r,federatedGraphSchema:(0,Re.buildASTSchema)(r,{assumeValid:!0,assumeValidSDL:!0}),federatedGraphClientSchema:i,parentDefinitionDataByTypeName:this.parentDefinitionDataByTypeName,success:!0,warnings:this.warnings},this.getClientSchemaObjectBoolean())}federateSubgraphsInternal(){return this.federateSubgraphData(),this.buildFederationResult()}};Sc.FederationFactory=wE;function tD({disableResolvabilityValidation:e,subgraphs:t}){if(t.length<1)return{errors:[we.minimumSubgraphRequirementError],success:!1,warnings:[]};let n=(0,hle.batchNormalize)(t);if(!n.success)return{errors:n.errors,success:!1,warnings:n.warnings};let r=new Map,i=new Map;for(let[c,l]of n.internalSubgraphBySubgraphName)for(let[p,f]of l.entityInterfaces){let y=r.get(p);if(!y){r.set(p,(0,ti.newEntityInterfaceFederationData)(f,c));continue}(0,ti.upsertEntityInterfaceFederationData)(y,f,c)}let a=new Array,o=new Map;for(let[c,l]of r){let p=l.concreteTypeNames.size;for(let[f,y]of l.subgraphDataByTypeName){let g=(0,he.getValueOrDefault)(o,f,()=>new Set);if((0,he.addIterableValuesToSet)(y.concreteTypeNames,g),!y.isInterfaceObject){y.resolvable&&y.concreteTypeNames.size!==p&&(0,he.getValueOrDefault)(i,c,()=>new Array).push({subgraphName:f,definedConcreteTypeNames:new Set(y.concreteTypeNames),requiredConcreteTypeNames:new Set(l.concreteTypeNames)});continue}(0,he.addIterableValuesToSet)(l.concreteTypeNames,g);let{parentDefinitionDataByTypeName:v}=(0,he.getOrThrowError)(n.internalSubgraphBySubgraphName,f,"internalSubgraphBySubgraphName"),P=[];for(let U of l.concreteTypeNames)v.has(U)&&P.push(U);P.length>0&&a.push((0,we.invalidInterfaceObjectImplementationDefinitionsError)(c,f,P))}}for(let[c,l]of i){let p=new Array;for(let f of l){let y=o.get(f.subgraphName);if(!y){p.push(f);continue}let g=f.requiredConcreteTypeNames.intersection(y);f.requiredConcreteTypeNames.size!==g.size&&(f.definedConcreteTypeNames=g,p.push(f))}if(p.length>0){i.set(c,p);continue}i.delete(c)}return i.size>0&&a.push((0,we.undefinedEntityInterfaceImplementationsError)(i,r)),a.length>0?{errors:a,success:!1,warnings:n.warnings}:{federationFactory:new wE({authorizationDataByParentTypeName:n.authorizationDataByParentTypeName,concreteTypeNamesByAbstractTypeName:n.concreteTypeNamesByAbstractTypeName,disableResolvabilityValidation:e,entityDataByTypeName:n.entityDataByTypeName,entityInterfaceFederationDataByTypeName:r,fieldCoordsByNamedTypeName:n.fieldCoordsByNamedTypeName,internalSubgraphBySubgraphName:n.internalSubgraphBySubgraphName,internalGraph:n.internalGraph,warnings:n.warnings}),success:!0,warnings:n.warnings}}function gle({disableResolvabilityValidation:e,subgraphs:t}){let n=tD({subgraphs:t,disableResolvabilityValidation:e});return n.success?n.federationFactory.federateSubgraphsInternal():{errors:n.errors,success:!1,warnings:n.warnings}}function _le({subgraphs:e,tagOptionsByContractName:t,disableResolvabilityValidation:n}){let r=tD({subgraphs:e,disableResolvabilityValidation:n});if(!r.success)return{errors:r.errors,success:!1,warnings:r.warnings};r.federationFactory.federateSubgraphData();let i=[(0,tV.cloneDeep)(r.federationFactory)],a=r.federationFactory.buildFederationResult();if(!a.success)return{errors:a.errors,success:!1,warnings:a.warnings};let o=t.size-1,c=new Map,l=0;for(let[p,f]of t){l!==o&&i.push((0,tV.cloneDeep)(i[l]));let y=i[l].buildFederationContractResult(f);c.set(p,y),l++}return Y(x({},a),{federationResultByContractName:c})}function vle({contractTagOptions:e,disableResolvabilityValidation:t,subgraphs:n}){let r=tD({subgraphs:n,disableResolvabilityValidation:t});return r.success?(r.federationFactory.federateSubgraphData(),r.federationFactory.buildFederationContractResult(e)):{errors:r.errors,success:!1,warnings:r.warnings}}});var LE=w(Ss=>{"use strict";m();T();N();Object.defineProperty(Ss,"__esModule",{value:!0});Ss.LATEST_ROUTER_COMPATIBILITY_VERSION=Ss.ROUTER_COMPATIBILITY_VERSIONS=Ss.ROUTER_COMPATIBILITY_VERSION_ONE=void 0;Ss.ROUTER_COMPATIBILITY_VERSION_ONE="1";Ss.ROUTER_COMPATIBILITY_VERSIONS=new Set([Ss.ROUTER_COMPATIBILITY_VERSION_ONE]);Ss.LATEST_ROUTER_COMPATIBILITY_VERSION="1"});var rV=w(Hp=>{"use strict";m();T();N();Object.defineProperty(Hp,"__esModule",{value:!0});Hp.federateSubgraphs=Sle;Hp.federateSubgraphsWithContracts=Ole;Hp.federateSubgraphsContract=Dle;var nD=nV(),rD=LE();function Sle({disableResolvabilityValidation:e,subgraphs:t,version:n=rD.ROUTER_COMPATIBILITY_VERSION_ONE}){switch(n){default:return(0,nD.federateSubgraphs)({disableResolvabilityValidation:e,subgraphs:t})}}function Ole({disableResolvabilityValidation:e,subgraphs:t,tagOptionsByContractName:n,version:r=rD.ROUTER_COMPATIBILITY_VERSION_ONE}){switch(r){default:return(0,nD.federateSubgraphsWithContracts)({disableResolvabilityValidation:e,subgraphs:t,tagOptionsByContractName:n})}}function Dle({contractTagOptions:e,disableResolvabilityValidation:t,subgraphs:n,version:r=rD.ROUTER_COMPATIBILITY_VERSION_ONE}){switch(r){default:return(0,nD.federateSubgraphsContract)({disableResolvabilityValidation:t,subgraphs:n,contractTagOptions:e})}}});var aV=w(iV=>{"use strict";m();T();N();Object.defineProperty(iV,"__esModule",{value:!0})});var sV=w(zp=>{"use strict";m();T();N();Object.defineProperty(zp,"__esModule",{value:!0});zp.normalizeSubgraphFromString=ble;zp.normalizeSubgraph=Ale;zp.batchNormalize=Rle;var iD=WO(),aD=LE();function ble(e,t=!0,n=aD.ROUTER_COMPATIBILITY_VERSION_ONE){switch(n){default:return(0,iD.normalizeSubgraphFromString)(e,t)}}function Ale(e,t,n,r=aD.ROUTER_COMPATIBILITY_VERSION_ONE){switch(r){default:return(0,iD.normalizeSubgraph)(e,t,n)}}function Rle(e,t=aD.ROUTER_COMPATIBILITY_VERSION_ONE){switch(t){default:return(0,iD.batchNormalize)(e)}}});var uV=w(oV=>{"use strict";m();T();N();Object.defineProperty(oV,"__esModule",{value:!0})});var lV=w(cV=>{"use strict";m();T();N();Object.defineProperty(cV,"__esModule",{value:!0})});var pV=w(dV=>{"use strict";m();T();N();Object.defineProperty(dV,"__esModule",{value:!0})});var mV=w(fV=>{"use strict";m();T();N();Object.defineProperty(fV,"__esModule",{value:!0})});var NV=w(CE=>{"use strict";m();T();N();Object.defineProperty(CE,"__esModule",{value:!0});CE.COMPOSITION_VERSION=void 0;CE.COMPOSITION_VERSION="{{$COMPOSITION__VERSION}}"});var EV=w(TV=>{"use strict";m();T();N();Object.defineProperty(TV,"__esModule",{value:!0})});var yV=w(hV=>{"use strict";m();T();N();Object.defineProperty(hV,"__esModule",{value:!0})});var gV=w(IV=>{"use strict";m();T();N();Object.defineProperty(IV,"__esModule",{value:!0})});var BE=w(pt=>{"use strict";m();T();N();var Ple=pt&&pt.__createBinding||(Object.create?function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]}),St=pt&&pt.__exportStar||function(e,t){for(var n in e)n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n)&&Ple(t,e,n)};Object.defineProperty(pt,"__esModule",{value:!0});St(Yr(),pt);St(dv(),pt);St(ia(),pt);St(Pk(),pt);St(rV(),pt);St(aV(),pt);St(sV(),pt);St(uV(),pt);St(JO(),pt);St(KO(),pt);St($O(),pt);St(LE(),pt);St(lV(),pt);St(HO(),pt);St(ou(),pt);St(hp(),pt);St(hl(),pt);St(pV(),pt);St(mV(),pt);St(NV(),pt);St(ur(),pt);St(EV(),pt);St(Jr(),pt);St(BO(),pt);St(BN(),pt);St(eD(),pt);St(yV(),pt);St(PO(),pt);St(Gp(),pt);St(gV(),pt);St(MO(),pt);St(RE(),pt);St(LO(),pt);St(Es(),pt);St(Kp(),pt);St(kp(),pt);St(gE(),pt)});var vde={};sm(vde,{buildRouterConfiguration:()=>_de,federateSubgraphs:()=>gde});m();T();N();var Fc=ss(BE());m();T();N();m();T();N();function sD(e){if(!e)return e;if(!URL.canParse(e))throw new Error("Invalid URL");let t=e.indexOf("?"),n=e.indexOf("#"),r=e;return t>0?r=r.slice(0,n>0?Math.min(t,n):t):n>0&&(r=r.slice(0,n)),r}m();T();N();m();T();N();var _V={};m();T();N();function vV(e){return e!=null}m();T();N();m();T();N();var AV=ss(Ae(),1);m();T();N();var SV;if(typeof AggregateError=="undefined"){class e extends Error{constructor(n,r=""){super(r),this.errors=n,this.name="AggregateError",Error.captureStackTrace(this,e)}}SV=function(t,n){return new e(t,n)}}else SV=AggregateError;function OV(e){return"errors"in e&&Array.isArray(e.errors)}var RV=3;function PV(e){return UE(e,[])}function UE(e,t){switch(typeof e){case"string":return JSON.stringify(e);case"function":return e.name?`[function ${e.name}]`:"[function]";case"object":return Fle(e,t);default:return String(e)}}function DV(e){return e instanceof AV.GraphQLError?e.toString():`${e.name}: ${e.message}; ${e.stack}`}function Fle(e,t){if(e===null)return"null";if(e instanceof Error)return OV(e)?DV(e)+` `+bV(e.errors,t):DV(e);if(t.includes(e))return"[Circular]";let n=[...t,e];if(wle(e)){let r=e.toJSON();if(r!==e)return typeof r=="string"?r:UE(r,n)}else if(Array.isArray(e))return bV(e,n);return Lle(e,n)}function wle(e){return typeof e.toJSON=="function"}function Lle(e,t){let n=Object.entries(e);return n.length===0?"{}":t.length>RV?"["+Cle(e)+"]":"{ "+n.map(([i,a])=>i+": "+UE(a,t)).join(", ")+" }"}function bV(e,t){if(e.length===0)return"[]";if(t.length>RV)return"[Array]";let n=e.length,r=[];for(let i=0;in==null?n:n[r],e==null?void 0:e.extensions)}m();T();N();var Pe=ss(Ae(),1);m();T();N();var $a=ss(Ae(),1);function Qa(e){if((0,$a.isNonNullType)(e)){let t=Qa(e.ofType);if(t.kind===$a.Kind.NON_NULL_TYPE)throw new Error(`Invalid type node ${PV(e)}. Inner type of non-null type cannot be a non-null type.`);return{kind:$a.Kind.NON_NULL_TYPE,type:t}}else if((0,$a.isListType)(e))return{kind:$a.Kind.LIST_TYPE,type:Qa(e.ofType)};return{kind:$a.Kind.NAMED_TYPE,name:{kind:$a.Kind.NAME,value:e.name}}}m();T();N();var Ya=ss(Ae(),1);function ME(e){if(e===null)return{kind:Ya.Kind.NULL};if(e===void 0)return null;if(Array.isArray(e)){let t=[];for(let n of e){let r=ME(n);r!=null&&t.push(r)}return{kind:Ya.Kind.LIST,values:t}}if(typeof e=="object"){let t=[];for(let n in e){let r=e[n],i=ME(r);i&&t.push({kind:Ya.Kind.OBJECT_FIELD,name:{kind:Ya.Kind.NAME,value:n},value:i})}return{kind:Ya.Kind.OBJECT,fields:t}}if(typeof e=="boolean")return{kind:Ya.Kind.BOOLEAN,value:e};if(typeof e=="number"&&isFinite(e)){let t=String(e);return Ble.test(t)?{kind:Ya.Kind.INT,value:t}:{kind:Ya.Kind.FLOAT,value:t}}if(typeof e=="string")return{kind:Ya.Kind.STRING,value:e};throw new TypeError(`Cannot convert value to AST: ${e}.`)}var Ble=/^-?(?:0|[1-9][0-9]*)$/;m();T();N();m();T();N();function xE(e){let t=new WeakMap;return function(r){let i=t.get(r);if(i===void 0){let a=e(r);return t.set(r,a),a}return i}}var tke=xE(function(t){let n=Ule(t);return new Set([...n].map(r=>r.name))}),Ule=xE(function(t){let n=oD(t);return new Set(n.values())}),oD=xE(function(t){let n=new Map,r=t.getQueryType();r&&n.set("query",r);let i=t.getMutationType();i&&n.set("mutation",i);let a=t.getSubscriptionType();return a&&n.set("subscription",a),n});function kle(e,t={}){let n=t.pathToDirectivesInExtensions,r=e.getTypeMap(),i=Mle(e,n),a=i!=null?[i]:[],o=e.getDirectives();for(let c of o)(0,Pe.isSpecifiedDirective)(c)||a.push(xle(c,e,n));for(let c in r){let l=r[c],p=(0,Pe.isSpecifiedScalarType)(l),f=(0,Pe.isIntrospectionType)(l);if(!(p||f))if((0,Pe.isObjectType)(l))a.push(qle(l,e,n));else if((0,Pe.isInterfaceType)(l))a.push(Vle(l,e,n));else if((0,Pe.isUnionType)(l))a.push(jle(l,e,n));else if((0,Pe.isInputObjectType)(l))a.push(Kle(l,e,n));else if((0,Pe.isEnumType)(l))a.push(Gle(l,e,n));else if((0,Pe.isScalarType)(l))a.push($le(l,e,n));else throw new Error(`Unknown type ${l}.`)}return{kind:Pe.Kind.DOCUMENT,definitions:a}}function FV(e,t={}){let n=kle(e,t);return(0,Pe.print)(n)}function Mle(e,t){var n,r;let i=new Map([["query",void 0],["mutation",void 0],["subscription",void 0]]),a=[];if(e.astNode!=null&&a.push(e.astNode),e.extensionASTNodes!=null)for(let f of e.extensionASTNodes)a.push(f);for(let f of a)if(f.operationTypes)for(let y of f.operationTypes)i.set(y.operation,y);let o=oD(e);for(let[f,y]of i){let g=o.get(f);if(g!=null){let v=Qa(g);y!=null?y.type=v:i.set(f,{kind:Pe.Kind.OPERATION_TYPE_DEFINITION,operation:f,type:v})}}let c=[...i.values()].filter(vV),l=Hl(e,e,t);if(!c.length&&!l.length)return null;let p={kind:c!=null?Pe.Kind.SCHEMA_DEFINITION:Pe.Kind.SCHEMA_EXTENSION,operationTypes:c,directives:l};return p.description=((r=(n=e.astNode)===null||n===void 0?void 0:n.description)!==null&&r!==void 0?r:e.description!=null)?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,p}function xle(e,t,n){var r,i,a,o;return{kind:Pe.Kind.DIRECTIVE_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},arguments:(a=e.args)===null||a===void 0?void 0:a.map(c=>wV(c,t,n)),repeatable:e.isRepeatable,locations:((o=e.locations)===null||o===void 0?void 0:o.map(c=>({kind:Pe.Kind.NAME,value:c})))||[]}}function Hl(e,t,n){let r=kE(e,n),i=[];e.astNode!=null&&i.push(e.astNode),"extensionASTNodes"in e&&e.extensionASTNodes!=null&&(i=i.concat(e.extensionASTNodes));let a;if(r!=null)a=uD(t,r);else{a=[];for(let o of i)o.directives&&a.push(...o.directives)}return a}function VE(e,t,n){var r,i;let a=[],o=null,c=kE(e,n),l;return c!=null?l=uD(t,c):l=(r=e.astNode)===null||r===void 0?void 0:r.directives,l!=null&&(a=l.filter(p=>p.name.value!=="deprecated"),e.deprecationReason!=null&&(o=(i=l.filter(p=>p.name.value==="deprecated"))===null||i===void 0?void 0:i[0])),e.deprecationReason!=null&&o==null&&(o=Jle(e.deprecationReason)),o==null?a:[o].concat(a)}function wV(e,t,n){var r,i,a;return{kind:Pe.Kind.INPUT_VALUE_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},type:Qa(e.type),defaultValue:e.defaultValue!==void 0&&(a=(0,Pe.astFromValue)(e.defaultValue,e.type))!==null&&a!==void 0?a:void 0,directives:VE(e,t,n)}}function qle(e,t,n){var r,i;return{kind:Pe.Kind.OBJECT_TYPE_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},fields:Object.values(e.getFields()).map(a=>LV(a,t,n)),interfaces:Object.values(e.getInterfaces()).map(a=>Qa(a)),directives:Hl(e,t,n)}}function Vle(e,t,n){var r,i;let a={kind:Pe.Kind.INTERFACE_TYPE_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},fields:Object.values(e.getFields()).map(o=>LV(o,t,n)),directives:Hl(e,t,n)};return"getInterfaces"in e&&(a.interfaces=Object.values(e.getInterfaces()).map(o=>Qa(o))),a}function jle(e,t,n){var r,i;return{kind:Pe.Kind.UNION_TYPE_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},directives:Hl(e,t,n),types:e.getTypes().map(a=>Qa(a))}}function Kle(e,t,n){var r,i;return{kind:Pe.Kind.INPUT_OBJECT_TYPE_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},fields:Object.values(e.getFields()).map(a=>Qle(a,t,n)),directives:Hl(e,t,n)}}function Gle(e,t,n){var r,i;return{kind:Pe.Kind.ENUM_TYPE_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},values:Object.values(e.getValues()).map(a=>Yle(a,t,n)),directives:Hl(e,t,n)}}function $le(e,t,n){var r,i,a;let o=kE(e,n),c=o?uD(t,o):((r=e.astNode)===null||r===void 0?void 0:r.directives)||[],l=e.specifiedByUrl||e.specifiedByURL;if(l&&!c.some(p=>p.name.value==="specifiedBy")){let p={url:l};c.push(qE("specifiedBy",p))}return{kind:Pe.Kind.SCALAR_TYPE_DEFINITION,description:(a=(i=e.astNode)===null||i===void 0?void 0:i.description)!==null&&a!==void 0?a:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},directives:c}}function LV(e,t,n){var r,i;return{kind:Pe.Kind.FIELD_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},arguments:e.args.map(a=>wV(a,t,n)),type:Qa(e.type),directives:VE(e,t,n)}}function Qle(e,t,n){var r,i,a;return{kind:Pe.Kind.INPUT_VALUE_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},type:Qa(e.type),directives:VE(e,t,n),defaultValue:(a=(0,Pe.astFromValue)(e.defaultValue,e.type))!==null&&a!==void 0?a:void 0}}function Yle(e,t,n){var r,i;return{kind:Pe.Kind.ENUM_VALUE_DEFINITION,description:(i=(r=e.astNode)===null||r===void 0?void 0:r.description)!==null&&i!==void 0?i:e.description?{kind:Pe.Kind.STRING,value:e.description,block:!0}:void 0,name:{kind:Pe.Kind.NAME,value:e.name},directives:VE(e,t,n)}}function Jle(e){return qE("deprecated",{reason:e},Pe.GraphQLDeprecatedDirective)}function qE(e,t,n){let r=[];if(n!=null)for(let i of n.args){let a=i.name,o=t[a];if(o!==void 0){let c=(0,Pe.astFromValue)(o,i.type);c&&r.push({kind:Pe.Kind.ARGUMENT,name:{kind:Pe.Kind.NAME,value:a},value:c})}}else for(let i in t){let a=t[i],o=ME(a);o&&r.push({kind:Pe.Kind.ARGUMENT,name:{kind:Pe.Kind.NAME,value:i},value:o})}return{kind:Pe.Kind.DIRECTIVE,name:{kind:Pe.Kind.NAME,value:e},arguments:r}}function uD(e,t){let n=[];for(let r in t){let i=t[r],a=e==null?void 0:e.getDirective(r);if(Array.isArray(i))for(let o of i)n.push(qE(r,o,a));else n.push(qE(r,i,a))}return n}var id=ss(BE(),1);m();T();N();m();T();N();m();T();N();m();T();N();m();T();N();m();T();N();function sn(e,t){if(!e)throw new Error(t)}var Hle=34028234663852886e22,zle=-34028234663852886e22,Wle=4294967295,Xle=2147483647,Zle=-2147483648;function zl(e){if(typeof e!="number")throw new Error("invalid int 32: "+typeof e);if(!Number.isInteger(e)||e>Xle||eWle||e<0)throw new Error("invalid uint 32: "+e)}function jE(e){if(typeof e!="number")throw new Error("invalid float 32: "+typeof e);if(Number.isFinite(e)&&(e>Hle||e({no:i.no,name:i.name,localName:e[i.no]})),r)}function lD(e,t,n){let r=Object.create(null),i=Object.create(null),a=[];for(let o of t){let c=kV(o);a.push(c),r[o.name]=c,i[o.no]=c}return{typeName:e,values:a,findName(o){return r[o]},findNumber(o){return i[o]}}}function UV(e,t,n){let r={};for(let i of t){let a=kV(i);r[a.localName]=a.no,r[a.no]=a.localName}return cD(r,e,t,n),r}function kV(e){return"localName"in e?e:Object.assign(Object.assign({},e),{localName:e.name})}m();T();N();m();T();N();var Le=class{equals(t){return this.getType().runtime.util.equals(this.getType(),this,t)}clone(){return this.getType().runtime.util.clone(this)}fromBinary(t,n){let r=this.getType(),i=r.runtime.bin,a=i.makeReadOptions(n);return i.readMessage(this,a.readerFactory(t),t.byteLength,a),this}fromJson(t,n){let r=this.getType(),i=r.runtime.json,a=i.makeReadOptions(n);return i.readMessage(r,t,a,this),this}fromJsonString(t,n){let r;try{r=JSON.parse(t)}catch(i){throw new Error(`cannot decode ${this.getType().typeName} from JSON: ${i instanceof Error?i.message:String(i)}`)}return this.fromJson(r,n)}toBinary(t){let n=this.getType(),r=n.runtime.bin,i=r.makeWriteOptions(t),a=i.writerFactory();return r.writeMessage(this,a,i),a.finish()}toJson(t){let n=this.getType(),r=n.runtime.json,i=r.makeWriteOptions(t);return r.writeMessage(this,i)}toJsonString(t){var n;let r=this.toJson(t);return JSON.stringify(r,null,(n=t==null?void 0:t.prettySpaces)!==null&&n!==void 0?n:0)}toJSON(){return this.toJson({emitDefaultValues:!0})}getType(){return Object.getPrototypeOf(this).constructor}};function MV(e,t,n,r){var i;let a=(i=r==null?void 0:r.localName)!==null&&i!==void 0?i:t.substring(t.lastIndexOf(".")+1),o={[a]:function(c){e.util.initFields(this),e.util.initPartial(c,this)}}[a];return Object.setPrototypeOf(o.prototype,new Le),Object.assign(o,{runtime:e,typeName:t,fields:e.util.newFieldList(n),fromBinary(c,l){return new o().fromBinary(c,l)},fromJson(c,l){return new o().fromJson(c,l)},fromJsonString(c,l){return new o().fromJsonString(c,l)},equals(c,l){return e.util.equals(o,c,l)}}),o}m();T();N();m();T();N();m();T();N();m();T();N();function qV(){let e=0,t=0;for(let r=0;r<28;r+=7){let i=this.buf[this.pos++];if(e|=(i&127)<>4,!(n&128))return this.assertBounds(),[e,t];for(let r=3;r<=31;r+=7){let i=this.buf[this.pos++];if(t|=(i&127)<>>a,c=!(!(o>>>7)&&t==0),l=(c?o|128:o)&255;if(n.push(l),!c)return}let r=e>>>28&15|(t&7)<<4,i=!!(t>>3);if(n.push((i?r|128:r)&255),!!i){for(let a=3;a<31;a=a+7){let o=t>>>a,c=!!(o>>>7),l=(c?o|128:o)&255;if(n.push(l),!c)return}n.push(t>>>31&1)}}var KE=4294967296;function dD(e){let t=e[0]==="-";t&&(e=e.slice(1));let n=1e6,r=0,i=0;function a(o,c){let l=Number(e.slice(o,c));i*=n,r=r*n+l,r>=KE&&(i=i+(r/KE|0),r=r%KE)}return a(-24,-18),a(-18,-12),a(-12,-6),a(-6),t?jV(r,i):fD(r,i)}function VV(e,t){let n=fD(e,t),r=n.hi&2147483648;r&&(n=jV(n.lo,n.hi));let i=pD(n.lo,n.hi);return r?"-"+i:i}function pD(e,t){if({lo:e,hi:t}=ede(e,t),t<=2097151)return String(KE*t+e);let n=e&16777215,r=(e>>>24|t<<8)&16777215,i=t>>16&65535,a=n+r*6777216+i*6710656,o=r+i*8147497,c=i*2,l=1e7;return a>=l&&(o+=Math.floor(a/l),a%=l),o>=l&&(c+=Math.floor(o/l),o%=l),c.toString()+xV(o)+xV(a)}function ede(e,t){return{lo:e>>>0,hi:t>>>0}}function fD(e,t){return{lo:e|0,hi:t|0}}function jV(e,t){return t=~t,e?e=~e+1:t+=1,fD(e,t)}var xV=e=>{let t=String(e);return"0000000".slice(t.length)+t};function mD(e,t){if(e>=0){for(;e>127;)t.push(e&127|128),e=e>>>7;t.push(e)}else{for(let n=0;n<9;n++)t.push(e&127|128),e=e>>7;t.push(1)}}function KV(){let e=this.buf[this.pos++],t=e&127;if(!(e&128))return this.assertBounds(),t;if(e=this.buf[this.pos++],t|=(e&127)<<7,!(e&128))return this.assertBounds(),t;if(e=this.buf[this.pos++],t|=(e&127)<<14,!(e&128))return this.assertBounds(),t;if(e=this.buf[this.pos++],t|=(e&127)<<21,!(e&128))return this.assertBounds(),t;e=this.buf[this.pos++],t|=(e&15)<<28;for(let n=5;e&128&&n<10;n++)e=this.buf[this.pos++];if(e&128)throw new Error("invalid varint");return this.assertBounds(),t>>>0}function tde(){let 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"&&(typeof O!="object"||typeof O.env!="object"||O.env.BUF_BIGINT_DISABLE!=="1")){let i=BigInt("-9223372036854775808"),a=BigInt("9223372036854775807"),o=BigInt("0"),c=BigInt("18446744073709551615");return{zero:BigInt(0),supported:!0,parse(l){let p=typeof l=="bigint"?l:BigInt(l);if(p>a||pc||psn(/^-?[0-9]+$/.test(i),`int64 invalid: ${i}`),r=i=>sn(/^[0-9]+$/.test(i),`uint64 invalid: ${i}`);return{zero:"0",supported:!1,parse(i){return typeof i!="string"&&(i=i.toString()),n(i),i},uParse(i){return typeof i!="string"&&(i=i.toString()),r(i),i},enc(i){return typeof i!="string"&&(i=i.toString()),n(i),dD(i)},uEnc(i){return typeof i!="string"&&(i=i.toString()),r(i),dD(i)},dec(i,a){return VV(i,a)},uDec(i,a){return pD(i,a)}}}var Kn=tde();m();T();N();var Ne;(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"})(Ne||(Ne={}));var Na;(function(e){e[e.BIGINT=0]="BIGINT",e[e.STRING=1]="STRING"})(Na||(Na={}));function Os(e,t,n){if(t===n)return!0;if(e==Ne.BYTES){if(!(t instanceof Uint8Array)||!(n instanceof Uint8Array)||t.length!==n.length)return!1;for(let r=0;r>>0)}raw(t){return this.buf.length&&(this.chunks.push(new Uint8Array(this.buf)),this.buf=[]),this.chunks.push(t),this}uint32(t){for(Wp(t);t>127;)this.buf.push(t&127|128),t=t>>>7;return this.buf.push(t),this}int32(t){return zl(t),mD(t,this.buf),this}bool(t){return this.buf.push(t?1:0),this}bytes(t){return this.uint32(t.byteLength),this.raw(t)}string(t){let n=this.textEncoder.encode(t);return this.uint32(n.byteLength),this.raw(n)}float(t){jE(t);let n=new Uint8Array(4);return new DataView(n.buffer).setFloat32(0,t,!0),this.raw(n)}double(t){let n=new Uint8Array(8);return new DataView(n.buffer).setFloat64(0,t,!0),this.raw(n)}fixed32(t){Wp(t);let n=new Uint8Array(4);return new DataView(n.buffer).setUint32(0,t,!0),this.raw(n)}sfixed32(t){zl(t);let n=new Uint8Array(4);return new DataView(n.buffer).setInt32(0,t,!0),this.raw(n)}sint32(t){return zl(t),t=(t<<1^t>>31)>>>0,mD(t,this.buf),this}sfixed64(t){let n=new Uint8Array(8),r=new DataView(n.buffer),i=Kn.enc(t);return r.setInt32(0,i.lo,!0),r.setInt32(4,i.hi,!0),this.raw(n)}fixed64(t){let n=new Uint8Array(8),r=new DataView(n.buffer),i=Kn.uEnc(t);return r.setInt32(0,i.lo,!0),r.setInt32(4,i.hi,!0),this.raw(n)}int64(t){let n=Kn.enc(t);return GE(n.lo,n.hi,this.buf),this}sint64(t){let n=Kn.enc(t),r=n.hi>>31,i=n.lo<<1^r,a=(n.hi<<1|n.lo>>>31)^r;return GE(i,a,this.buf),this}uint64(t){let n=Kn.uEnc(t);return GE(n.lo,n.hi,this.buf),this}},YE=class{constructor(t,n){this.varint64=qV,this.uint32=KV,this.buf=t,this.len=t.length,this.pos=0,this.view=new DataView(t.buffer,t.byteOffset,t.byteLength),this.textDecoder=n!=null?n:new TextDecoder}tag(){let t=this.uint32(),n=t>>>3,r=t&7;if(n<=0||r<0||r>5)throw new Error("illegal tag: field no "+n+" wire type "+r);return[n,r]}skip(t){let n=this.pos;switch(t){case Bn.Varint:for(;this.buf[this.pos++]&128;);break;case Bn.Bit64:this.pos+=4;case Bn.Bit32:this.pos+=4;break;case Bn.LengthDelimited:let r=this.uint32();this.pos+=r;break;case Bn.StartGroup:let i;for(;(i=this.tag()[1])!==Bn.EndGroup;)this.skip(i);break;default:throw new Error("cant skip wire type "+t)}return this.assertBounds(),this.buf.subarray(n,this.pos)}assertBounds(){if(this.pos>this.len)throw new RangeError("premature EOF")}int32(){return this.uint32()|0}sint32(){let t=this.uint32();return t>>>1^-(t&1)}int64(){return Kn.dec(...this.varint64())}uint64(){return Kn.uDec(...this.varint64())}sint64(){let[t,n]=this.varint64(),r=-(t&1);return t=(t>>>1|(n&1)<<31)^r,n=n>>>1^r,Kn.dec(t,n)}bool(){let[t,n]=this.varint64();return t!==0||n!==0}fixed32(){return this.view.getUint32((this.pos+=4)-4,!0)}sfixed32(){return this.view.getInt32((this.pos+=4)-4,!0)}fixed64(){return Kn.uDec(this.sfixed32(),this.sfixed32())}sfixed64(){return Kn.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 t=this.uint32(),n=this.pos;return this.pos+=t,this.assertBounds(),this.buf.subarray(n,n+t)}string(){return this.textDecoder.decode(this.bytes())}};function GV(e,t,n,r){let i;return{typeName:t,extendee:n,get field(){if(!i){let a=typeof r=="function"?r():r;a.name=t.split(".").pop(),a.jsonName=`[${t}]`,i=e.util.newFieldList([a]).list()[0]}return i},runtime:e}}function JE(e){let t=e.field.localName,n=Object.create(null);return n[t]=nde(e),[n,()=>n[t]]}function nde(e){let t=e.field;if(t.repeated)return[];if(t.default!==void 0)return t.default;switch(t.kind){case"enum":return t.T.values[0].no;case"scalar":return Ta(t.T,t.L);case"message":let n=t.T,r=new n;return n.fieldWrapper?n.fieldWrapper.unwrapField(r):r;case"map":throw"map fields are not allowed to be extensions"}}function $V(e,t){if(!t.repeated&&(t.kind=="enum"||t.kind=="scalar")){for(let n=e.length-1;n>=0;--n)if(e[n].no==t.no)return[e[n]];return[]}return e.filter(n=>n.no===t.no)}m();T();N();m();T();N();var Ds="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split(""),HE=[];for(let e=0;e>4,o=a,i=2;break;case 2:n[r++]=(o&15)<<4|(a&60)>>2,o=a,i=3;break;case 3:n[r++]=(o&3)<<6|a,i=0;break}}if(i==1)throw Error("invalid base64 string.");return n.subarray(0,r)},enc(e){let t="",n=0,r,i=0;for(let a=0;a>2],i=(r&3)<<4,n=1;break;case 1:t+=Ds[i|r>>4],i=(r&15)<<2,n=2;break;case 2:t+=Ds[i|r>>6],t+=Ds[r&63],n=0;break}return n&&(t+=Ds[i],t+="=",n==1&&(t+="=")),t}};m();T();N();function QV(e,t,n){JV(t,e);let r=t.runtime.bin.makeReadOptions(n),i=$V(e.getType().runtime.bin.listUnknownFields(e),t.field),[a,o]=JE(t);for(let c of i)t.runtime.bin.readField(a,r.readerFactory(c.data),t.field,c.wireType,r);return o()}function YV(e,t,n,r){JV(t,e);let i=t.runtime.bin.makeReadOptions(r),a=t.runtime.bin.makeWriteOptions(r);if(TD(e,t)){let p=e.getType().runtime.bin.listUnknownFields(e).filter(f=>f.no!=t.field.no);e.getType().runtime.bin.discardUnknownFields(e);for(let f of p)e.getType().runtime.bin.onUnknownField(e,f.no,f.wireType,f.data)}let o=a.writerFactory(),c=t.field;!c.opt&&!c.repeated&&(c.kind=="enum"||c.kind=="scalar")&&(c=Object.assign(Object.assign({},t.field),{opt:!0})),t.runtime.bin.writeField(c,n,o,a);let l=i.readerFactory(o.finish());for(;l.posr.no==t.field.no)}function JV(e,t){sn(e.extendee.typeName==t.getType().typeName,`extension ${e.typeName} can only be applied to message ${e.extendee.typeName}`)}m();T();N();function zE(e,t){let n=e.localName;if(e.repeated)return t[n].length>0;if(e.oneof)return t[e.oneof.localName].case===n;switch(e.kind){case"enum":case"scalar":return e.opt||e.req?t[n]!==void 0:e.kind=="enum"?t[n]!==e.T.values[0].no:!$E(e.T,t[n]);case"message":return t[n]!==void 0;case"map":return Object.keys(t[n]).length>0}}function ED(e,t){let n=e.localName,r=!e.opt&&!e.req;if(e.repeated)t[n]=[];else if(e.oneof)t[e.oneof.localName]={case:void 0};else switch(e.kind){case"map":t[n]={};break;case"enum":t[n]=r?e.T.values[0].no:void 0;break;case"scalar":t[n]=r?Ta(e.T,e.L):void 0;break;case"message":t[n]=void 0;break}}m();T();N();m();T();N();function Ea(e,t){if(e===null||typeof e!="object"||!Object.getOwnPropertyNames(Le.prototype).every(r=>r in e&&typeof e[r]=="function"))return!1;let n=e.getType();return n===null||typeof n!="function"||!("typeName"in n)||typeof n.typeName!="string"?!1:t===void 0?!0:n.typeName==t.typeName}function WE(e,t){return Ea(t)||!e.fieldWrapper?t:e.fieldWrapper.wrapField(t)}var CMe={"google.protobuf.DoubleValue":Ne.DOUBLE,"google.protobuf.FloatValue":Ne.FLOAT,"google.protobuf.Int64Value":Ne.INT64,"google.protobuf.UInt64Value":Ne.UINT64,"google.protobuf.Int32Value":Ne.INT32,"google.protobuf.UInt32Value":Ne.UINT32,"google.protobuf.BoolValue":Ne.BOOL,"google.protobuf.StringValue":Ne.STRING,"google.protobuf.BytesValue":Ne.BYTES};var HV={ignoreUnknownFields:!1},zV={emitDefaultValues:!1,enumAsInteger:!1,useProtoFieldName:!1,prettySpaces:0};function rde(e){return e?Object.assign(Object.assign({},HV),e):HV}function ide(e){return e?Object.assign(Object.assign({},zV),e):zV}var eh=Symbol(),XE=Symbol();function ZV(){return{makeReadOptions:rde,makeWriteOptions:ide,readMessage(e,t,n,r){if(t==null||Array.isArray(t)||typeof t!="object")throw new Error(`cannot decode message ${e.typeName} from JSON: ${Ja(t)}`);r=r!=null?r:new e;let i=new Map,a=n.typeRegistry;for(let[o,c]of Object.entries(t)){let l=e.fields.findJsonName(o);if(l){if(l.oneof){if(c===null&&l.kind=="scalar")continue;let p=i.get(l.oneof);if(p!==void 0)throw new Error(`cannot decode message ${e.typeName} from JSON: multiple keys for oneof "${l.oneof.name}" present: "${p}", "${o}"`);i.set(l.oneof,o)}WV(r,c,l,n,e)}else{let p=!1;if(a!=null&&a.findExtension&&o.startsWith("[")&&o.endsWith("]")){let f=a.findExtension(o.substring(1,o.length-1));if(f&&f.extendee.typeName==e.typeName){p=!0;let[y,g]=JE(f);WV(y,c,f.field,n,f),YV(r,f,g(),n)}}if(!p&&!n.ignoreUnknownFields)throw new Error(`cannot decode message ${e.typeName} from JSON: key "${o}" is unknown`)}}return r},writeMessage(e,t){let n=e.getType(),r={},i;try{for(i of n.fields.byNumber()){if(!zE(i,e)){if(i.req)throw"required field not set";if(!t.emitDefaultValues||!sde(i))continue}let o=i.oneof?e[i.oneof.localName].value:e[i.localName],c=XV(i,o,t);c!==void 0&&(r[t.useProtoFieldName?i.name:i.jsonName]=c)}let a=t.typeRegistry;if(a!=null&&a.findExtensionFor)for(let o of n.runtime.bin.listUnknownFields(e)){let c=a.findExtensionFor(n.typeName,o.no);if(c&&TD(e,c)){let l=QV(e,c,t),p=XV(c.field,l,t);p!==void 0&&(r[c.field.jsonName]=p)}}}catch(a){let o=i?`cannot encode field ${n.typeName}.${i.name} to JSON`:`cannot encode message ${n.typeName} to JSON`,c=a instanceof Error?a.message:String(a);throw new Error(o+(c.length>0?`: ${c}`:""))}return r},readScalar(e,t,n){return Xp(e,t,n!=null?n:Na.BIGINT,!0)},writeScalar(e,t,n){if(t!==void 0&&(n||$E(e,t)))return ZE(e,t)},debug:Ja}}function Ja(e){if(e===null)return"null";switch(typeof e){case"object":return Array.isArray(e)?"array":"object";case"string":return e.length>100?"string":`"${e.split('"').join('\\"')}"`;default:return String(e)}}function WV(e,t,n,r,i){let a=n.localName;if(n.repeated){if(sn(n.kind!="map"),t===null)return;if(!Array.isArray(t))throw new Error(`cannot decode field ${i.typeName}.${n.name} from JSON: ${Ja(t)}`);let o=e[a];for(let c of t){if(c===null)throw new Error(`cannot decode field ${i.typeName}.${n.name} from JSON: ${Ja(c)}`);switch(n.kind){case"message":o.push(n.T.fromJson(c,r));break;case"enum":let l=hD(n.T,c,r.ignoreUnknownFields,!0);l!==XE&&o.push(l);break;case"scalar":try{o.push(Xp(n.T,c,n.L,!0))}catch(p){let f=`cannot decode field ${i.typeName}.${n.name} from JSON: ${Ja(c)}`;throw p instanceof Error&&p.message.length>0&&(f+=`: ${p.message}`),new Error(f)}break}}}else if(n.kind=="map"){if(t===null)return;if(typeof t!="object"||Array.isArray(t))throw new Error(`cannot decode field ${i.typeName}.${n.name} from JSON: ${Ja(t)}`);let o=e[a];for(let[c,l]of Object.entries(t)){if(l===null)throw new Error(`cannot decode field ${i.typeName}.${n.name} from JSON: map value null`);let p;try{p=ade(n.K,c)}catch(f){let y=`cannot decode map key for field ${i.typeName}.${n.name} from JSON: ${Ja(t)}`;throw f instanceof Error&&f.message.length>0&&(y+=`: ${f.message}`),new Error(y)}switch(n.V.kind){case"message":o[p]=n.V.T.fromJson(l,r);break;case"enum":let f=hD(n.V.T,l,r.ignoreUnknownFields,!0);f!==XE&&(o[p]=f);break;case"scalar":try{o[p]=Xp(n.V.T,l,Na.BIGINT,!0)}catch(y){let g=`cannot decode map value for field ${i.typeName}.${n.name} from JSON: ${Ja(t)}`;throw y instanceof Error&&y.message.length>0&&(g+=`: ${y.message}`),new Error(g)}break}}}else switch(n.oneof&&(e=e[n.oneof.localName]={case:a},a="value"),n.kind){case"message":let o=n.T;if(t===null&&o.typeName!="google.protobuf.Value")return;let c=e[a];Ea(c)?c.fromJson(t,r):(e[a]=c=o.fromJson(t,r),o.fieldWrapper&&!n.oneof&&(e[a]=o.fieldWrapper.unwrapField(c)));break;case"enum":let l=hD(n.T,t,r.ignoreUnknownFields,!1);switch(l){case eh:ED(n,e);break;case XE:break;default:e[a]=l;break}break;case"scalar":try{let p=Xp(n.T,t,n.L,!1);switch(p){case eh:ED(n,e);break;default:e[a]=p;break}}catch(p){let f=`cannot decode field ${i.typeName}.${n.name} from JSON: ${Ja(t)}`;throw p instanceof Error&&p.message.length>0&&(f+=`: ${p.message}`),new Error(f)}break}}function ade(e,t){if(e===Ne.BOOL)switch(t){case"true":t=!0;break;case"false":t=!1;break}return Xp(e,t,Na.BIGINT,!0).toString()}function Xp(e,t,n,r){if(t===null)return r?Ta(e,n):eh;switch(e){case Ne.DOUBLE:case Ne.FLOAT:if(t==="NaN")return Number.NaN;if(t==="Infinity")return Number.POSITIVE_INFINITY;if(t==="-Infinity")return Number.NEGATIVE_INFINITY;if(t===""||typeof t=="string"&&t.trim().length!==t.length||typeof t!="string"&&typeof t!="number")break;let i=Number(t);if(Number.isNaN(i)||!Number.isFinite(i))break;return e==Ne.FLOAT&&jE(i),i;case Ne.INT32:case Ne.FIXED32:case Ne.SFIXED32:case Ne.SINT32:case Ne.UINT32:let a;if(typeof t=="number"?a=t:typeof t=="string"&&t.length>0&&t.trim().length===t.length&&(a=Number(t)),a===void 0)break;return e==Ne.UINT32||e==Ne.FIXED32?Wp(a):zl(a),a;case Ne.INT64:case Ne.SFIXED64:case Ne.SINT64:if(typeof t!="number"&&typeof t!="string")break;let o=Kn.parse(t);return n?o.toString():o;case Ne.FIXED64:case Ne.UINT64:if(typeof t!="number"&&typeof t!="string")break;let c=Kn.uParse(t);return n?c.toString():c;case Ne.BOOL:if(typeof t!="boolean")break;return t;case Ne.STRING:if(typeof t!="string")break;try{encodeURIComponent(t)}catch(l){throw new Error("invalid UTF8")}return t;case Ne.BYTES:if(t==="")return new Uint8Array(0);if(typeof t!="string")break;return ND.dec(t)}throw new Error}function hD(e,t,n,r){if(t===null)return e.typeName=="google.protobuf.NullValue"?0:r?e.values[0].no:eh;switch(typeof t){case"number":if(Number.isInteger(t))return t;break;case"string":let i=e.findName(t);if(i!==void 0)return i.no;if(n)return XE;break}throw new Error(`cannot decode enum ${e.typeName} from JSON: ${Ja(t)}`)}function sde(e){return e.repeated||e.kind=="map"?!0:!(e.oneof||e.kind=="message"||e.opt||e.req)}function XV(e,t,n){if(e.kind=="map"){sn(typeof t=="object"&&t!=null);let r={},i=Object.entries(t);switch(e.V.kind){case"scalar":for(let[o,c]of i)r[o.toString()]=ZE(e.V.T,c);break;case"message":for(let[o,c]of i)r[o.toString()]=c.toJson(n);break;case"enum":let a=e.V.T;for(let[o,c]of i)r[o.toString()]=yD(a,c,n.enumAsInteger);break}return n.emitDefaultValues||i.length>0?r:void 0}if(e.repeated){sn(Array.isArray(t));let r=[];switch(e.kind){case"scalar":for(let i=0;i0?r:void 0}switch(e.kind){case"scalar":return ZE(e.T,t);case"enum":return yD(e.T,t,n.enumAsInteger);case"message":return WE(e.T,t).toJson(n)}}function yD(e,t,n){var r;if(sn(typeof t=="number"),e.typeName=="google.protobuf.NullValue")return null;if(n)return t;let i=e.findNumber(t);return(r=i==null?void 0:i.name)!==null&&r!==void 0?r:t}function ZE(e,t){switch(e){case Ne.INT32:case Ne.SFIXED32:case Ne.SINT32:case Ne.FIXED32:case Ne.UINT32:return sn(typeof t=="number"),t;case Ne.FLOAT:case Ne.DOUBLE:return sn(typeof t=="number"),Number.isNaN(t)?"NaN":t===Number.POSITIVE_INFINITY?"Infinity":t===Number.NEGATIVE_INFINITY?"-Infinity":t;case Ne.STRING:return sn(typeof t=="string"),t;case Ne.BOOL:return sn(typeof t=="boolean"),t;case Ne.UINT64:case Ne.FIXED64:case Ne.INT64:case Ne.SFIXED64:case Ne.SINT64:return sn(typeof t=="bigint"||typeof t=="string"||typeof t=="number"),t.toString();case Ne.BYTES:return sn(t instanceof Uint8Array),ND.enc(t)}}m();T();N();var Wl=Symbol("@bufbuild/protobuf/unknown-fields"),e1={readUnknownFields:!0,readerFactory:e=>new YE(e)},t1={writeUnknownFields:!0,writerFactory:()=>new QE};function ode(e){return e?Object.assign(Object.assign({},e1),e):e1}function ude(e){return e?Object.assign(Object.assign({},t1),e):t1}function a1(){return{makeReadOptions:ode,makeWriteOptions:ude,listUnknownFields(e){var t;return(t=e[Wl])!==null&&t!==void 0?t:[]},discardUnknownFields(e){delete e[Wl]},writeUnknownFields(e,t){let r=e[Wl];if(r)for(let i of r)t.tag(i.no,i.wireType).raw(i.data)},onUnknownField(e,t,n,r){let i=e;Array.isArray(i[Wl])||(i[Wl]=[]),i[Wl].push({no:t,wireType:n,data:r})},readMessage(e,t,n,r,i){let a=e.getType(),o=i?t.len:t.pos+n,c,l;for(;t.pos0&&(l=lde),a){let g=e[o];if(r==Bn.LengthDelimited&&c!=Ne.STRING&&c!=Ne.BYTES){let P=t.uint32()+t.pos;for(;t.posEa(g,y)?g:new y(g));else{let g=o[i];y.fieldWrapper?y.typeName==="google.protobuf.BytesValue"?a[i]=ef(g):a[i]=g:a[i]=Ea(g,y)?g:new y(g)}break}}},equals(e,t,n){return t===n?!0:!t||!n?!1:e.fields.byMember().every(r=>{let i=t[r.localName],a=n[r.localName];if(r.repeated){if(i.length!==a.length)return!1;switch(r.kind){case"message":return i.every((o,c)=>r.T.equals(o,a[c]));case"scalar":return i.every((o,c)=>Os(r.T,o,a[c]));case"enum":return i.every((o,c)=>Os(Ne.INT32,o,a[c]))}throw new Error(`repeated cannot contain ${r.kind}`)}switch(r.kind){case"message":return r.T.equals(i,a);case"enum":return Os(Ne.INT32,i,a);case"scalar":return Os(r.T,i,a);case"oneof":if(i.case!==a.case)return!1;let o=r.findField(i.case);if(o===void 0)return!0;switch(o.kind){case"message":return o.T.equals(i.value,a.value);case"enum":return Os(Ne.INT32,i.value,a.value);case"scalar":return Os(o.T,i.value,a.value)}throw new Error(`oneof cannot contain ${o.kind}`);case"map":let c=Object.keys(i).concat(Object.keys(a));switch(r.V.kind){case"message":let l=r.V.T;return c.every(f=>l.equals(i[f],a[f]));case"enum":return c.every(f=>Os(Ne.INT32,i[f],a[f]));case"scalar":let p=r.V.T;return c.every(f=>Os(p,i[f],a[f]))}break}})},clone(e){let t=e.getType(),n=new t,r=n;for(let i of t.fields.byMember()){let a=e[i.localName],o;if(i.repeated)o=a.map(rh);else if(i.kind=="map"){o=r[i.localName];for(let[c,l]of Object.entries(a))o[c]=rh(l)}else i.kind=="oneof"?o=i.findField(a.case)?{case:a.case,value:rh(a.value)}:{case:void 0}:o=rh(a);r[i.localName]=o}for(let i of t.runtime.bin.listUnknownFields(e))t.runtime.bin.onUnknownField(r,i.no,i.wireType,i.data);return n}}}function rh(e){if(e===void 0)return e;if(Ea(e))return e.clone();if(e instanceof Uint8Array){let t=new Uint8Array(e.byteLength);return t.set(e),t}return e}function ef(e){return e instanceof Uint8Array?e:new Uint8Array(e)}function u1(e,t,n){return{syntax:e,json:ZV(),bin:a1(),util:Object.assign(Object.assign({},o1()),{newFieldList:t,initFields:n}),makeMessageType(r,i,a){return MV(this,r,i,a)},makeEnum:UV,makeEnumType:lD,getEnumType:BV,makeExtension(r,i,a){return GV(this,r,i,a)}}}m();T();N();var ih=class{constructor(t,n){this._fields=t,this._normalizer=n}findJsonName(t){if(!this.jsonNames){let n={};for(let r of this.list())n[r.jsonName]=n[r.name]=r;this.jsonNames=n}return this.jsonNames[t]}find(t){if(!this.numbers){let n={};for(let r of this.list())n[r.no]=r;this.numbers=n}return this.numbers[t]}list(){return this.all||(this.all=this._normalizer(this._fields)),this.all}byNumber(){return this.numbersAsc||(this.numbersAsc=this.list().concat().sort((t,n)=>t.no-n.no)),this.numbersAsc}byMember(){if(!this.members){this.members=[];let t=this.members,n;for(let r of this.list())r.oneof?r.oneof!==n&&(n=r.oneof,t.push(n)):t.push(r)}return this.members}};m();T();N();m();T();N();m();T();N();function ID(e,t){let n=d1(e);return t?n:Tde(Nde(n))}function c1(e){return ID(e,!1)}var l1=d1;function d1(e){let t=!1,n=[];for(let r=0;r`${e}$`,Nde=e=>mde.has(e)?p1(e):e,Tde=e=>fde.has(e)?p1(e):e;var ah=class{constructor(t){this.kind="oneof",this.repeated=!1,this.packed=!1,this.opt=!1,this.req=!1,this.default=void 0,this.fields=[],this.name=t,this.localName=c1(t)}addField(t){sn(t.oneof===this,`field ${t.name} not one of ${this.name}`),this.fields.push(t)}findField(t){if(!this._lookup){this._lookup=Object.create(null);for(let n=0;nnew ih(e,t=>f1(t,!0)),e=>{for(let t of e.getType().fields.byMember()){if(t.opt)continue;let n=t.localName,r=e;if(t.repeated){r[n]=[];continue}switch(t.kind){case"oneof":r[n]={case:void 0};break;case"enum":r[n]=0;break;case"map":r[n]={};break;case"scalar":r[n]=Ta(t.T,t.L);break;case"message":break}}});var Xl;(function(e){e[e.OK=0]="OK",e[e.ERR=1]="ERR",e[e.ERR_NOT_FOUND=2]="ERR_NOT_FOUND",e[e.ERR_ALREADY_EXISTS=3]="ERR_ALREADY_EXISTS",e[e.ERR_INVALID_SUBGRAPH_SCHEMA=4]="ERR_INVALID_SUBGRAPH_SCHEMA",e[e.ERR_SUBGRAPH_COMPOSITION_FAILED=5]="ERR_SUBGRAPH_COMPOSITION_FAILED",e[e.ERR_SUBGRAPH_CHECK_FAILED=6]="ERR_SUBGRAPH_CHECK_FAILED",e[e.ERR_INVALID_LABELS=7]="ERR_INVALID_LABELS",e[e.ERR_ANALYTICS_DISABLED=8]="ERR_ANALYTICS_DISABLED",e[e.ERROR_NOT_AUTHENTICATED=9]="ERROR_NOT_AUTHENTICATED",e[e.ERR_OPENAI_DISABLED=10]="ERR_OPENAI_DISABLED",e[e.ERR_FREE_TRIAL_EXPIRED=11]="ERR_FREE_TRIAL_EXPIRED",e[e.ERROR_NOT_AUTHORIZED=12]="ERROR_NOT_AUTHORIZED",e[e.ERR_LIMIT_REACHED=13]="ERR_LIMIT_REACHED",e[e.ERR_DEPLOYMENT_FAILED=14]="ERR_DEPLOYMENT_FAILED",e[e.ERR_INVALID_NAME=15]="ERR_INVALID_NAME",e[e.ERR_UPGRADE_PLAN=16]="ERR_UPGRADE_PLAN",e[e.ERR_BAD_REQUEST=17]="ERR_BAD_REQUEST",e[e.ERR_SCHEMA_MISMATCH_WITH_APPROVED_PROPOSAL=18]="ERR_SCHEMA_MISMATCH_WITH_APPROVED_PROPOSAL"})(Xl||(Xl={}));B.util.setEnumType(Xl,"wg.cosmo.common.EnumStatusCode",[{no:0,name:"OK"},{no:1,name:"ERR"},{no:2,name:"ERR_NOT_FOUND"},{no:3,name:"ERR_ALREADY_EXISTS"},{no:4,name:"ERR_INVALID_SUBGRAPH_SCHEMA"},{no:5,name:"ERR_SUBGRAPH_COMPOSITION_FAILED"},{no:6,name:"ERR_SUBGRAPH_CHECK_FAILED"},{no:7,name:"ERR_INVALID_LABELS"},{no:8,name:"ERR_ANALYTICS_DISABLED"},{no:9,name:"ERROR_NOT_AUTHENTICATED"},{no:10,name:"ERR_OPENAI_DISABLED"},{no:11,name:"ERR_FREE_TRIAL_EXPIRED"},{no:12,name:"ERROR_NOT_AUTHORIZED"},{no:13,name:"ERR_LIMIT_REACHED"},{no:14,name:"ERR_DEPLOYMENT_FAILED"},{no:15,name:"ERR_INVALID_NAME"},{no:16,name:"ERR_UPGRADE_PLAN"},{no:17,name:"ERR_BAD_REQUEST"},{no:18,name:"ERR_SCHEMA_MISMATCH_WITH_APPROVED_PROPOSAL"}]);var bs;(function(e){e[e.GRAPHQL_SUBSCRIPTION_PROTOCOL_WS=0]="GRAPHQL_SUBSCRIPTION_PROTOCOL_WS",e[e.GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE=1]="GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE",e[e.GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE_POST=2]="GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE_POST"})(bs||(bs={}));B.util.setEnumType(bs,"wg.cosmo.common.GraphQLSubscriptionProtocol",[{no:0,name:"GRAPHQL_SUBSCRIPTION_PROTOCOL_WS"},{no:1,name:"GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE"},{no:2,name:"GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE_POST"}]);var As;(function(e){e[e.GRAPHQL_WEBSOCKET_SUBPROTOCOL_AUTO=0]="GRAPHQL_WEBSOCKET_SUBPROTOCOL_AUTO",e[e.GRAPHQL_WEBSOCKET_SUBPROTOCOL_WS=1]="GRAPHQL_WEBSOCKET_SUBPROTOCOL_WS",e[e.GRAPHQL_WEBSOCKET_SUBPROTOCOL_TRANSPORT_WS=2]="GRAPHQL_WEBSOCKET_SUBPROTOCOL_TRANSPORT_WS"})(As||(As={}));B.util.setEnumType(As,"wg.cosmo.common.GraphQLWebsocketSubprotocol",[{no:0,name:"GRAPHQL_WEBSOCKET_SUBPROTOCOL_AUTO"},{no:1,name:"GRAPHQL_WEBSOCKET_SUBPROTOCOL_WS"},{no:2,name:"GRAPHQL_WEBSOCKET_SUBPROTOCOL_TRANSPORT_WS"}]);var v1=ss(Ae(),1);m();T();N();var gD;(function(e){e[e.RENDER_ARGUMENT_DEFAULT=0]="RENDER_ARGUMENT_DEFAULT",e[e.RENDER_ARGUMENT_AS_GRAPHQL_VALUE=1]="RENDER_ARGUMENT_AS_GRAPHQL_VALUE",e[e.RENDER_ARGUMENT_AS_ARRAY_CSV=2]="RENDER_ARGUMENT_AS_ARRAY_CSV"})(gD||(gD={}));B.util.setEnumType(gD,"wg.cosmo.node.v1.ArgumentRenderConfiguration",[{no:0,name:"RENDER_ARGUMENT_DEFAULT"},{no:1,name:"RENDER_ARGUMENT_AS_GRAPHQL_VALUE"},{no:2,name:"RENDER_ARGUMENT_AS_ARRAY_CSV"}]);var Dc;(function(e){e[e.OBJECT_FIELD=0]="OBJECT_FIELD",e[e.FIELD_ARGUMENT=1]="FIELD_ARGUMENT"})(Dc||(Dc={}));B.util.setEnumType(Dc,"wg.cosmo.node.v1.ArgumentSource",[{no:0,name:"OBJECT_FIELD"},{no:1,name:"FIELD_ARGUMENT"}]);var yu;(function(e){e[e.STATIC=0]="STATIC",e[e.GRAPHQL=1]="GRAPHQL",e[e.PUBSUB=2]="PUBSUB"})(yu||(yu={}));B.util.setEnumType(yu,"wg.cosmo.node.v1.DataSourceKind",[{no:0,name:"STATIC"},{no:1,name:"GRAPHQL"},{no:2,name:"PUBSUB"}]);var tf;(function(e){e[e.UNSPECIFIED=0]="UNSPECIFIED",e[e.QUERY=1]="QUERY",e[e.MUTATION=2]="MUTATION",e[e.SUBSCRIPTION=3]="SUBSCRIPTION"})(tf||(tf={}));B.util.setEnumType(tf,"wg.cosmo.node.v1.OperationType",[{no:0,name:"OPERATION_TYPE_UNSPECIFIED"},{no:1,name:"OPERATION_TYPE_QUERY"},{no:2,name:"OPERATION_TYPE_MUTATION"},{no:3,name:"OPERATION_TYPE_SUBSCRIPTION"}]);var Uo;(function(e){e[e.PUBLISH=0]="PUBLISH",e[e.REQUEST=1]="REQUEST",e[e.SUBSCRIBE=2]="SUBSCRIBE"})(Uo||(Uo={}));B.util.setEnumType(Uo,"wg.cosmo.node.v1.EventType",[{no:0,name:"PUBLISH"},{no:1,name:"REQUEST"},{no:2,name:"SUBSCRIBE"}]);var Iu;(function(e){e[e.STATIC_CONFIGURATION_VARIABLE=0]="STATIC_CONFIGURATION_VARIABLE",e[e.ENV_CONFIGURATION_VARIABLE=1]="ENV_CONFIGURATION_VARIABLE",e[e.PLACEHOLDER_CONFIGURATION_VARIABLE=2]="PLACEHOLDER_CONFIGURATION_VARIABLE"})(Iu||(Iu={}));B.util.setEnumType(Iu,"wg.cosmo.node.v1.ConfigurationVariableKind",[{no:0,name:"STATIC_CONFIGURATION_VARIABLE"},{no:1,name:"ENV_CONFIGURATION_VARIABLE"},{no:2,name:"PLACEHOLDER_CONFIGURATION_VARIABLE"}]);var bc;(function(e){e[e.GET=0]="GET",e[e.POST=1]="POST",e[e.PUT=2]="PUT",e[e.DELETE=3]="DELETE",e[e.OPTIONS=4]="OPTIONS"})(bc||(bc={}));B.util.setEnumType(bc,"wg.cosmo.node.v1.HTTPMethod",[{no:0,name:"GET"},{no:1,name:"POST"},{no:2,name:"PUT"},{no:3,name:"DELETE"},{no:4,name:"OPTIONS"}]);var Rs=class Rs extends Le{constructor(n){super();_(this,"id","");_(this,"name","");_(this,"routingUrl","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Rs().fromBinary(n,r)}static fromJson(n,r){return new Rs().fromJson(n,r)}static fromJsonString(n,r){return new Rs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Rs,n,r)}};_(Rs,"runtime",B),_(Rs,"typeName","wg.cosmo.node.v1.Subgraph"),_(Rs,"fields",B.util.newFieldList(()=>[{no:1,name:"id",kind:"scalar",T:9},{no:2,name:"name",kind:"scalar",T:9},{no:3,name:"routing_url",kind:"scalar",T:9}]));var sh=Rs,Ps=class Ps extends Le{constructor(n){super();_(this,"configByFeatureFlagName",{});B.util.initPartial(n,this)}static fromBinary(n,r){return new Ps().fromBinary(n,r)}static fromJson(n,r){return new Ps().fromJson(n,r)}static fromJsonString(n,r){return new Ps().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ps,n,r)}};_(Ps,"runtime",B),_(Ps,"typeName","wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs"),_(Ps,"fields",B.util.newFieldList(()=>[{no:1,name:"config_by_feature_flag_name",kind:"map",K:9,V:{kind:"message",T:vD}}]));var _D=Ps,Fs=class Fs extends Le{constructor(n){super();_(this,"engineConfig");_(this,"version","");_(this,"subgraphs",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Fs().fromBinary(n,r)}static fromJson(n,r){return new Fs().fromJson(n,r)}static fromJsonString(n,r){return new Fs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Fs,n,r)}};_(Fs,"runtime",B),_(Fs,"typeName","wg.cosmo.node.v1.FeatureFlagRouterExecutionConfig"),_(Fs,"fields",B.util.newFieldList(()=>[{no:1,name:"engine_config",kind:"message",T:Zl},{no:2,name:"version",kind:"scalar",T:9},{no:3,name:"subgraphs",kind:"message",T:sh,repeated:!0}]));var vD=Fs,ws=class ws extends Le{constructor(n){super();_(this,"engineConfig");_(this,"version","");_(this,"subgraphs",[]);_(this,"featureFlagConfigs");_(this,"compatibilityVersion","");B.util.initPartial(n,this)}static fromBinary(n,r){return new ws().fromBinary(n,r)}static fromJson(n,r){return new ws().fromJson(n,r)}static fromJsonString(n,r){return new ws().fromJsonString(n,r)}static equals(n,r){return B.util.equals(ws,n,r)}};_(ws,"runtime",B),_(ws,"typeName","wg.cosmo.node.v1.RouterConfig"),_(ws,"fields",B.util.newFieldList(()=>[{no:1,name:"engine_config",kind:"message",T:Zl},{no:2,name:"version",kind:"scalar",T:9},{no:3,name:"subgraphs",kind:"message",T:sh,repeated:!0},{no:4,name:"feature_flag_configs",kind:"message",T:_D,opt:!0},{no:5,name:"compatibility_version",kind:"scalar",T:9}]));var nf=ws,Ls=class Ls extends Le{constructor(n){super();_(this,"code",Xl.OK);_(this,"details");B.util.initPartial(n,this)}static fromBinary(n,r){return new Ls().fromBinary(n,r)}static fromJson(n,r){return new Ls().fromJson(n,r)}static fromJsonString(n,r){return new Ls().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ls,n,r)}};_(Ls,"runtime",B),_(Ls,"typeName","wg.cosmo.node.v1.Response"),_(Ls,"fields",B.util.newFieldList(()=>[{no:1,name:"code",kind:"enum",T:B.getEnumType(Xl)},{no:2,name:"details",kind:"scalar",T:9,opt:!0}]));var SD=Ls,Cs=class Cs extends Le{constructor(n){super();_(this,"code",0);_(this,"message","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Cs().fromBinary(n,r)}static fromJson(n,r){return new Cs().fromJson(n,r)}static fromJsonString(n,r){return new Cs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Cs,n,r)}};_(Cs,"runtime",B),_(Cs,"typeName","wg.cosmo.node.v1.ResponseStatus"),_(Cs,"fields",B.util.newFieldList(()=>[{no:1,name:"code",kind:"scalar",T:5},{no:2,name:"message",kind:"scalar",T:9}]));var m1=Cs,Bs=class Bs extends Le{constructor(n){super();_(this,"accountLimits");_(this,"graphPublicKey","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Bs().fromBinary(n,r)}static fromJson(n,r){return new Bs().fromJson(n,r)}static fromJsonString(n,r){return new Bs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Bs,n,r)}};_(Bs,"runtime",B),_(Bs,"typeName","wg.cosmo.node.v1.RegistrationInfo"),_(Bs,"fields",B.util.newFieldList(()=>[{no:1,name:"account_limits",kind:"message",T:DD},{no:2,name:"graph_public_key",kind:"scalar",T:9}]));var OD=Bs,Us=class Us extends Le{constructor(n){super();_(this,"traceSamplingRate",0);B.util.initPartial(n,this)}static fromBinary(n,r){return new Us().fromBinary(n,r)}static fromJson(n,r){return new Us().fromJson(n,r)}static fromJsonString(n,r){return new Us().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Us,n,r)}};_(Us,"runtime",B),_(Us,"typeName","wg.cosmo.node.v1.AccountLimits"),_(Us,"fields",B.util.newFieldList(()=>[{no:1,name:"trace_sampling_rate",kind:"scalar",T:2}]));var DD=Us,ks=class ks extends Le{constructor(t){super(),B.util.initPartial(t,this)}static fromBinary(t,n){return new ks().fromBinary(t,n)}static fromJson(t,n){return new ks().fromJson(t,n)}static fromJsonString(t,n){return new ks().fromJsonString(t,n)}static equals(t,n){return B.util.equals(ks,t,n)}};_(ks,"runtime",B),_(ks,"typeName","wg.cosmo.node.v1.SelfRegisterRequest"),_(ks,"fields",B.util.newFieldList(()=>[]));var N1=ks,Ms=class Ms extends Le{constructor(n){super();_(this,"response");_(this,"registrationInfo");B.util.initPartial(n,this)}static fromBinary(n,r){return new Ms().fromBinary(n,r)}static fromJson(n,r){return new Ms().fromJson(n,r)}static fromJsonString(n,r){return new Ms().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ms,n,r)}};_(Ms,"runtime",B),_(Ms,"typeName","wg.cosmo.node.v1.SelfRegisterResponse"),_(Ms,"fields",B.util.newFieldList(()=>[{no:1,name:"response",kind:"message",T:SD},{no:2,name:"registrationInfo",kind:"message",T:OD,opt:!0}]));var T1=Ms,xs=class xs extends Le{constructor(n){super();_(this,"defaultFlushInterval",Kn.zero);_(this,"datasourceConfigurations",[]);_(this,"fieldConfigurations",[]);_(this,"graphqlSchema","");_(this,"typeConfigurations",[]);_(this,"stringStorage",{});_(this,"graphqlClientSchema");B.util.initPartial(n,this)}static fromBinary(n,r){return new xs().fromBinary(n,r)}static fromJson(n,r){return new xs().fromJson(n,r)}static fromJsonString(n,r){return new xs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(xs,n,r)}};_(xs,"runtime",B),_(xs,"typeName","wg.cosmo.node.v1.EngineConfiguration"),_(xs,"fields",B.util.newFieldList(()=>[{no:1,name:"defaultFlushInterval",kind:"scalar",T:3},{no:2,name:"datasource_configurations",kind:"message",T:rf,repeated:!0},{no:3,name:"field_configurations",kind:"message",T:of,repeated:!0},{no:4,name:"graphqlSchema",kind:"scalar",T:9},{no:5,name:"type_configurations",kind:"message",T:bD,repeated:!0},{no:6,name:"string_storage",kind:"map",K:9,V:{kind:"scalar",T:9}},{no:7,name:"graphql_client_schema",kind:"scalar",T:9,opt:!0}]));var Zl=xs,qs=class qs extends Le{constructor(n){super();_(this,"kind",yu.STATIC);_(this,"rootNodes",[]);_(this,"childNodes",[]);_(this,"overrideFieldPathFromAlias",!1);_(this,"customGraphql");_(this,"customStatic");_(this,"directives",[]);_(this,"requestTimeoutSeconds",Kn.zero);_(this,"id","");_(this,"keys",[]);_(this,"provides",[]);_(this,"requires",[]);_(this,"customEvents");_(this,"entityInterfaces",[]);_(this,"interfaceObjects",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new qs().fromBinary(n,r)}static fromJson(n,r){return new qs().fromJson(n,r)}static fromJsonString(n,r){return new qs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(qs,n,r)}};_(qs,"runtime",B),_(qs,"typeName","wg.cosmo.node.v1.DataSourceConfiguration"),_(qs,"fields",B.util.newFieldList(()=>[{no:1,name:"kind",kind:"enum",T:B.getEnumType(yu)},{no:2,name:"root_nodes",kind:"message",T:ed,repeated:!0},{no:3,name:"child_nodes",kind:"message",T:ed,repeated:!0},{no:4,name:"override_field_path_from_alias",kind:"scalar",T:8},{no:5,name:"custom_graphql",kind:"message",T:lf},{no:6,name:"custom_static",kind:"message",T:MD},{no:7,name:"directives",kind:"message",T:xD,repeated:!0},{no:8,name:"request_timeout_seconds",kind:"scalar",T:3},{no:9,name:"id",kind:"scalar",T:9},{no:10,name:"keys",kind:"message",T:Oc,repeated:!0},{no:11,name:"provides",kind:"message",T:Oc,repeated:!0},{no:12,name:"requires",kind:"message",T:Oc,repeated:!0},{no:13,name:"custom_events",kind:"message",T:Rc},{no:14,name:"entity_interfaces",kind:"message",T:td,repeated:!0},{no:15,name:"interface_objects",kind:"message",T:td,repeated:!0}]));var rf=qs,Vs=class Vs extends Le{constructor(n){super();_(this,"name","");_(this,"sourceType",Dc.OBJECT_FIELD);B.util.initPartial(n,this)}static fromBinary(n,r){return new Vs().fromBinary(n,r)}static fromJson(n,r){return new Vs().fromJson(n,r)}static fromJsonString(n,r){return new Vs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Vs,n,r)}};_(Vs,"runtime",B),_(Vs,"typeName","wg.cosmo.node.v1.ArgumentConfiguration"),_(Vs,"fields",B.util.newFieldList(()=>[{no:1,name:"name",kind:"scalar",T:9},{no:2,name:"source_type",kind:"enum",T:B.getEnumType(Dc)}]));var af=Vs,js=class js extends Le{constructor(n){super();_(this,"requiredAndScopes",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new js().fromBinary(n,r)}static fromJson(n,r){return new js().fromJson(n,r)}static fromJsonString(n,r){return new js().fromJsonString(n,r)}static equals(n,r){return B.util.equals(js,n,r)}};_(js,"runtime",B),_(js,"typeName","wg.cosmo.node.v1.Scopes"),_(js,"fields",B.util.newFieldList(()=>[{no:1,name:"required_and_scopes",kind:"scalar",T:9,repeated:!0}]));var Ac=js,Ks=class Ks extends Le{constructor(n){super();_(this,"requiresAuthentication",!1);_(this,"requiredOrScopes",[]);_(this,"requiredOrScopesByOr",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Ks().fromBinary(n,r)}static fromJson(n,r){return new Ks().fromJson(n,r)}static fromJsonString(n,r){return new Ks().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ks,n,r)}};_(Ks,"runtime",B),_(Ks,"typeName","wg.cosmo.node.v1.AuthorizationConfiguration"),_(Ks,"fields",B.util.newFieldList(()=>[{no:1,name:"requires_authentication",kind:"scalar",T:8},{no:2,name:"required_or_scopes",kind:"message",T:Ac,repeated:!0},{no:3,name:"required_or_scopes_by_or",kind:"message",T:Ac,repeated:!0}]));var sf=Ks,Gs=class Gs extends Le{constructor(n){super();_(this,"typeName","");_(this,"fieldName","");_(this,"argumentsConfiguration",[]);_(this,"authorizationConfiguration");_(this,"subscriptionFilterCondition");B.util.initPartial(n,this)}static fromBinary(n,r){return new Gs().fromBinary(n,r)}static fromJson(n,r){return new Gs().fromJson(n,r)}static fromJsonString(n,r){return new Gs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Gs,n,r)}};_(Gs,"runtime",B),_(Gs,"typeName","wg.cosmo.node.v1.FieldConfiguration"),_(Gs,"fields",B.util.newFieldList(()=>[{no:1,name:"type_name",kind:"scalar",T:9},{no:2,name:"field_name",kind:"scalar",T:9},{no:3,name:"arguments_configuration",kind:"message",T:af,repeated:!0},{no:4,name:"authorization_configuration",kind:"message",T:sf},{no:5,name:"subscription_filter_condition",kind:"message",T:gu,opt:!0}]));var of=Gs,$s=class $s extends Le{constructor(n){super();_(this,"typeName","");_(this,"renameTo","");B.util.initPartial(n,this)}static fromBinary(n,r){return new $s().fromBinary(n,r)}static fromJson(n,r){return new $s().fromJson(n,r)}static fromJsonString(n,r){return new $s().fromJsonString(n,r)}static equals(n,r){return B.util.equals($s,n,r)}};_($s,"runtime",B),_($s,"typeName","wg.cosmo.node.v1.TypeConfiguration"),_($s,"fields",B.util.newFieldList(()=>[{no:1,name:"type_name",kind:"scalar",T:9},{no:2,name:"rename_to",kind:"scalar",T:9}]));var bD=$s,Qs=class Qs extends Le{constructor(n){super();_(this,"typeName","");_(this,"fieldNames",[]);_(this,"externalFieldNames",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Qs().fromBinary(n,r)}static fromJson(n,r){return new Qs().fromJson(n,r)}static fromJsonString(n,r){return new Qs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Qs,n,r)}};_(Qs,"runtime",B),_(Qs,"typeName","wg.cosmo.node.v1.TypeField"),_(Qs,"fields",B.util.newFieldList(()=>[{no:1,name:"type_name",kind:"scalar",T:9},{no:2,name:"field_names",kind:"scalar",T:9,repeated:!0},{no:3,name:"external_field_names",kind:"scalar",T:9,repeated:!0}]));var ed=Qs,Ys=class Ys extends Le{constructor(n){super();_(this,"fieldName","");_(this,"typeName","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Ys().fromBinary(n,r)}static fromJson(n,r){return new Ys().fromJson(n,r)}static fromJsonString(n,r){return new Ys().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ys,n,r)}};_(Ys,"runtime",B),_(Ys,"typeName","wg.cosmo.node.v1.FieldCoordinates"),_(Ys,"fields",B.util.newFieldList(()=>[{no:1,name:"field_name",kind:"scalar",T:9},{no:2,name:"type_name",kind:"scalar",T:9}]));var uf=Ys,Js=class Js extends Le{constructor(n){super();_(this,"fieldCoordinatesPath",[]);_(this,"fieldPath",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Js().fromBinary(n,r)}static fromJson(n,r){return new Js().fromJson(n,r)}static fromJsonString(n,r){return new Js().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Js,n,r)}};_(Js,"runtime",B),_(Js,"typeName","wg.cosmo.node.v1.FieldSetCondition"),_(Js,"fields",B.util.newFieldList(()=>[{no:1,name:"field_coordinates_path",kind:"message",T:uf,repeated:!0},{no:2,name:"field_path",kind:"scalar",T:9,repeated:!0}]));var cf=Js,Hs=class Hs extends Le{constructor(n){super();_(this,"typeName","");_(this,"fieldName","");_(this,"selectionSet","");_(this,"disableEntityResolver",!1);_(this,"conditions",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Hs().fromBinary(n,r)}static fromJson(n,r){return new Hs().fromJson(n,r)}static fromJsonString(n,r){return new Hs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Hs,n,r)}};_(Hs,"runtime",B),_(Hs,"typeName","wg.cosmo.node.v1.RequiredField"),_(Hs,"fields",B.util.newFieldList(()=>[{no:1,name:"type_name",kind:"scalar",T:9},{no:2,name:"field_name",kind:"scalar",T:9},{no:3,name:"selection_set",kind:"scalar",T:9},{no:4,name:"disable_entity_resolver",kind:"scalar",T:8},{no:5,name:"conditions",kind:"message",T:cf,repeated:!0}]));var Oc=Hs,zs=class zs extends Le{constructor(n){super();_(this,"interfaceTypeName","");_(this,"concreteTypeNames",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new zs().fromBinary(n,r)}static fromJson(n,r){return new zs().fromJson(n,r)}static fromJsonString(n,r){return new zs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(zs,n,r)}};_(zs,"runtime",B),_(zs,"typeName","wg.cosmo.node.v1.EntityInterfaceConfiguration"),_(zs,"fields",B.util.newFieldList(()=>[{no:1,name:"interface_type_name",kind:"scalar",T:9},{no:2,name:"concrete_type_names",kind:"scalar",T:9,repeated:!0}]));var td=zs,Ws=class Ws extends Le{constructor(n){super();_(this,"url");_(this,"method",bc.GET);_(this,"header",{});_(this,"body");_(this,"query",[]);_(this,"urlEncodeBody",!1);_(this,"mtls");_(this,"baseUrl");_(this,"path");_(this,"httpProxyUrl");B.util.initPartial(n,this)}static fromBinary(n,r){return new Ws().fromBinary(n,r)}static fromJson(n,r){return new Ws().fromJson(n,r)}static fromJsonString(n,r){return new Ws().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ws,n,r)}};_(Ws,"runtime",B),_(Ws,"typeName","wg.cosmo.node.v1.FetchConfiguration"),_(Ws,"fields",B.util.newFieldList(()=>[{no:1,name:"url",kind:"message",T:Mr},{no:2,name:"method",kind:"enum",T:B.getEnumType(bc)},{no:3,name:"header",kind:"map",K:9,V:{kind:"message",T:VD}},{no:4,name:"body",kind:"message",T:Mr},{no:5,name:"query",kind:"message",T:qD,repeated:!0},{no:7,name:"url_encode_body",kind:"scalar",T:8},{no:8,name:"mtls",kind:"message",T:jD},{no:9,name:"base_url",kind:"message",T:Mr},{no:10,name:"path",kind:"message",T:Mr},{no:11,name:"http_proxy_url",kind:"message",T:Mr,opt:!0}]));var AD=Ws,Xs=class Xs extends Le{constructor(n){super();_(this,"statusCode",Kn.zero);_(this,"typeName","");_(this,"injectStatusCodeIntoBody",!1);B.util.initPartial(n,this)}static fromBinary(n,r){return new Xs().fromBinary(n,r)}static fromJson(n,r){return new Xs().fromJson(n,r)}static fromJsonString(n,r){return new Xs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Xs,n,r)}};_(Xs,"runtime",B),_(Xs,"typeName","wg.cosmo.node.v1.StatusCodeTypeMapping"),_(Xs,"fields",B.util.newFieldList(()=>[{no:1,name:"status_code",kind:"scalar",T:3},{no:2,name:"type_name",kind:"scalar",T:9},{no:3,name:"inject_status_code_into_body",kind:"scalar",T:8}]));var E1=Xs,Zs=class Zs extends Le{constructor(n){super();_(this,"fetch");_(this,"subscription");_(this,"federation");_(this,"upstreamSchema");_(this,"customScalarTypeFields",[]);_(this,"grpc");B.util.initPartial(n,this)}static fromBinary(n,r){return new Zs().fromBinary(n,r)}static fromJson(n,r){return new Zs().fromJson(n,r)}static fromJsonString(n,r){return new Zs().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Zs,n,r)}};_(Zs,"runtime",B),_(Zs,"typeName","wg.cosmo.node.v1.DataSourceCustom_GraphQL"),_(Zs,"fields",B.util.newFieldList(()=>[{no:1,name:"fetch",kind:"message",T:AD},{no:2,name:"subscription",kind:"message",T:KD},{no:3,name:"federation",kind:"message",T:GD},{no:4,name:"upstream_schema",kind:"message",T:Tf},{no:6,name:"custom_scalar_type_fields",kind:"message",T:$D,repeated:!0},{no:7,name:"grpc",kind:"message",T:nd}]));var lf=Zs,eo=class eo extends Le{constructor(n){super();_(this,"mapping");_(this,"protoSchema","");_(this,"plugin");B.util.initPartial(n,this)}static fromBinary(n,r){return new eo().fromBinary(n,r)}static fromJson(n,r){return new eo().fromJson(n,r)}static fromJsonString(n,r){return new eo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(eo,n,r)}};_(eo,"runtime",B),_(eo,"typeName","wg.cosmo.node.v1.GRPCConfiguration"),_(eo,"fields",B.util.newFieldList(()=>[{no:1,name:"mapping",kind:"message",T:PD},{no:2,name:"proto_schema",kind:"scalar",T:9},{no:3,name:"plugin",kind:"message",T:df}]));var nd=eo,to=class to extends Le{constructor(n){super();_(this,"repository","");_(this,"reference","");B.util.initPartial(n,this)}static fromBinary(n,r){return new to().fromBinary(n,r)}static fromJson(n,r){return new to().fromJson(n,r)}static fromJsonString(n,r){return new to().fromJsonString(n,r)}static equals(n,r){return B.util.equals(to,n,r)}};_(to,"runtime",B),_(to,"typeName","wg.cosmo.node.v1.ImageReference"),_(to,"fields",B.util.newFieldList(()=>[{no:1,name:"repository",kind:"scalar",T:9},{no:2,name:"reference",kind:"scalar",T:9}]));var RD=to,no=class no extends Le{constructor(n){super();_(this,"name","");_(this,"version","");_(this,"imageReference");B.util.initPartial(n,this)}static fromBinary(n,r){return new no().fromBinary(n,r)}static fromJson(n,r){return new no().fromJson(n,r)}static fromJsonString(n,r){return new no().fromJsonString(n,r)}static equals(n,r){return B.util.equals(no,n,r)}};_(no,"runtime",B),_(no,"typeName","wg.cosmo.node.v1.PluginConfiguration"),_(no,"fields",B.util.newFieldList(()=>[{no:1,name:"name",kind:"scalar",T:9},{no:2,name:"version",kind:"scalar",T:9},{no:3,name:"image_reference",kind:"message",T:RD,opt:!0}]));var df=no,ro=class ro extends Le{constructor(n){super();_(this,"enabled",!1);B.util.initPartial(n,this)}static fromBinary(n,r){return new ro().fromBinary(n,r)}static fromJson(n,r){return new ro().fromJson(n,r)}static fromJsonString(n,r){return new ro().fromJsonString(n,r)}static equals(n,r){return B.util.equals(ro,n,r)}};_(ro,"runtime",B),_(ro,"typeName","wg.cosmo.node.v1.SSLConfiguration"),_(ro,"fields",B.util.newFieldList(()=>[{no:1,name:"enabled",kind:"scalar",T:8}]));var h1=ro,io=class io extends Le{constructor(n){super();_(this,"version",0);_(this,"service","");_(this,"operationMappings",[]);_(this,"entityMappings",[]);_(this,"typeFieldMappings",[]);_(this,"enumMappings",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new io().fromBinary(n,r)}static fromJson(n,r){return new io().fromJson(n,r)}static fromJsonString(n,r){return new io().fromJsonString(n,r)}static equals(n,r){return B.util.equals(io,n,r)}};_(io,"runtime",B),_(io,"typeName","wg.cosmo.node.v1.GRPCMapping"),_(io,"fields",B.util.newFieldList(()=>[{no:1,name:"version",kind:"scalar",T:5},{no:2,name:"service",kind:"scalar",T:9},{no:3,name:"operation_mappings",kind:"message",T:FD,repeated:!0},{no:4,name:"entity_mappings",kind:"message",T:wD,repeated:!0},{no:5,name:"type_field_mappings",kind:"message",T:LD,repeated:!0},{no:6,name:"enum_mappings",kind:"message",T:UD,repeated:!0}]));var PD=io,ao=class ao extends Le{constructor(n){super();_(this,"type",tf.UNSPECIFIED);_(this,"original","");_(this,"mapped","");_(this,"request","");_(this,"response","");B.util.initPartial(n,this)}static fromBinary(n,r){return new ao().fromBinary(n,r)}static fromJson(n,r){return new ao().fromJson(n,r)}static fromJsonString(n,r){return new ao().fromJsonString(n,r)}static equals(n,r){return B.util.equals(ao,n,r)}};_(ao,"runtime",B),_(ao,"typeName","wg.cosmo.node.v1.OperationMapping"),_(ao,"fields",B.util.newFieldList(()=>[{no:1,name:"type",kind:"enum",T:B.getEnumType(tf)},{no:2,name:"original",kind:"scalar",T:9},{no:3,name:"mapped",kind:"scalar",T:9},{no:4,name:"request",kind:"scalar",T:9},{no:5,name:"response",kind:"scalar",T:9}]));var FD=ao,so=class so extends Le{constructor(n){super();_(this,"typeName","");_(this,"kind","");_(this,"key","");_(this,"rpc","");_(this,"request","");_(this,"response","");B.util.initPartial(n,this)}static fromBinary(n,r){return new so().fromBinary(n,r)}static fromJson(n,r){return new so().fromJson(n,r)}static fromJsonString(n,r){return new so().fromJsonString(n,r)}static equals(n,r){return B.util.equals(so,n,r)}};_(so,"runtime",B),_(so,"typeName","wg.cosmo.node.v1.EntityMapping"),_(so,"fields",B.util.newFieldList(()=>[{no:1,name:"type_name",kind:"scalar",T:9},{no:2,name:"kind",kind:"scalar",T:9},{no:3,name:"key",kind:"scalar",T:9},{no:4,name:"rpc",kind:"scalar",T:9},{no:5,name:"request",kind:"scalar",T:9},{no:6,name:"response",kind:"scalar",T:9}]));var wD=so,oo=class oo extends Le{constructor(n){super();_(this,"type","");_(this,"fieldMappings",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new oo().fromBinary(n,r)}static fromJson(n,r){return new oo().fromJson(n,r)}static fromJsonString(n,r){return new oo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(oo,n,r)}};_(oo,"runtime",B),_(oo,"typeName","wg.cosmo.node.v1.TypeFieldMapping"),_(oo,"fields",B.util.newFieldList(()=>[{no:1,name:"type",kind:"scalar",T:9},{no:2,name:"field_mappings",kind:"message",T:CD,repeated:!0}]));var LD=oo,uo=class uo extends Le{constructor(n){super();_(this,"original","");_(this,"mapped","");_(this,"argumentMappings",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new uo().fromBinary(n,r)}static fromJson(n,r){return new uo().fromJson(n,r)}static fromJsonString(n,r){return new uo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(uo,n,r)}};_(uo,"runtime",B),_(uo,"typeName","wg.cosmo.node.v1.FieldMapping"),_(uo,"fields",B.util.newFieldList(()=>[{no:1,name:"original",kind:"scalar",T:9},{no:2,name:"mapped",kind:"scalar",T:9},{no:3,name:"argument_mappings",kind:"message",T:BD,repeated:!0}]));var CD=uo,co=class co extends Le{constructor(n){super();_(this,"original","");_(this,"mapped","");B.util.initPartial(n,this)}static fromBinary(n,r){return new co().fromBinary(n,r)}static fromJson(n,r){return new co().fromJson(n,r)}static fromJsonString(n,r){return new co().fromJsonString(n,r)}static equals(n,r){return B.util.equals(co,n,r)}};_(co,"runtime",B),_(co,"typeName","wg.cosmo.node.v1.ArgumentMapping"),_(co,"fields",B.util.newFieldList(()=>[{no:1,name:"original",kind:"scalar",T:9},{no:2,name:"mapped",kind:"scalar",T:9}]));var BD=co,lo=class lo extends Le{constructor(n){super();_(this,"type","");_(this,"values",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new lo().fromBinary(n,r)}static fromJson(n,r){return new lo().fromJson(n,r)}static fromJsonString(n,r){return new lo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(lo,n,r)}};_(lo,"runtime",B),_(lo,"typeName","wg.cosmo.node.v1.EnumMapping"),_(lo,"fields",B.util.newFieldList(()=>[{no:1,name:"type",kind:"scalar",T:9},{no:2,name:"values",kind:"message",T:kD,repeated:!0}]));var UD=lo,po=class po extends Le{constructor(n){super();_(this,"original","");_(this,"mapped","");B.util.initPartial(n,this)}static fromBinary(n,r){return new po().fromBinary(n,r)}static fromJson(n,r){return new po().fromJson(n,r)}static fromJsonString(n,r){return new po().fromJsonString(n,r)}static equals(n,r){return B.util.equals(po,n,r)}};_(po,"runtime",B),_(po,"typeName","wg.cosmo.node.v1.EnumValueMapping"),_(po,"fields",B.util.newFieldList(()=>[{no:1,name:"original",kind:"scalar",T:9},{no:2,name:"mapped",kind:"scalar",T:9}]));var kD=po,fo=class fo extends Le{constructor(n){super();_(this,"consumerName","");_(this,"streamName","");_(this,"consumerInactiveThreshold",0);B.util.initPartial(n,this)}static fromBinary(n,r){return new fo().fromBinary(n,r)}static fromJson(n,r){return new fo().fromJson(n,r)}static fromJsonString(n,r){return new fo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(fo,n,r)}};_(fo,"runtime",B),_(fo,"typeName","wg.cosmo.node.v1.NatsStreamConfiguration"),_(fo,"fields",B.util.newFieldList(()=>[{no:1,name:"consumer_name",kind:"scalar",T:9},{no:2,name:"stream_name",kind:"scalar",T:9},{no:3,name:"consumer_inactive_threshold",kind:"scalar",T:5}]));var pf=fo,mo=class mo extends Le{constructor(n){super();_(this,"engineEventConfiguration");_(this,"subjects",[]);_(this,"streamConfiguration");B.util.initPartial(n,this)}static fromBinary(n,r){return new mo().fromBinary(n,r)}static fromJson(n,r){return new mo().fromJson(n,r)}static fromJsonString(n,r){return new mo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(mo,n,r)}};_(mo,"runtime",B),_(mo,"typeName","wg.cosmo.node.v1.NatsEventConfiguration"),_(mo,"fields",B.util.newFieldList(()=>[{no:1,name:"engine_event_configuration",kind:"message",T:ko},{no:2,name:"subjects",kind:"scalar",T:9,repeated:!0},{no:3,name:"stream_configuration",kind:"message",T:pf}]));var ff=mo,No=class No extends Le{constructor(n){super();_(this,"engineEventConfiguration");_(this,"topics",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new No().fromBinary(n,r)}static fromJson(n,r){return new No().fromJson(n,r)}static fromJsonString(n,r){return new No().fromJsonString(n,r)}static equals(n,r){return B.util.equals(No,n,r)}};_(No,"runtime",B),_(No,"typeName","wg.cosmo.node.v1.KafkaEventConfiguration"),_(No,"fields",B.util.newFieldList(()=>[{no:1,name:"engine_event_configuration",kind:"message",T:ko},{no:2,name:"topics",kind:"scalar",T:9,repeated:!0}]));var mf=No,To=class To extends Le{constructor(n){super();_(this,"engineEventConfiguration");_(this,"channels",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new To().fromBinary(n,r)}static fromJson(n,r){return new To().fromJson(n,r)}static fromJsonString(n,r){return new To().fromJsonString(n,r)}static equals(n,r){return B.util.equals(To,n,r)}};_(To,"runtime",B),_(To,"typeName","wg.cosmo.node.v1.RedisEventConfiguration"),_(To,"fields",B.util.newFieldList(()=>[{no:1,name:"engine_event_configuration",kind:"message",T:ko},{no:2,name:"channels",kind:"scalar",T:9,repeated:!0}]));var Nf=To,Eo=class Eo extends Le{constructor(n){super();_(this,"providerId","");_(this,"type",Uo.PUBLISH);_(this,"typeName","");_(this,"fieldName","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Eo().fromBinary(n,r)}static fromJson(n,r){return new Eo().fromJson(n,r)}static fromJsonString(n,r){return new Eo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Eo,n,r)}};_(Eo,"runtime",B),_(Eo,"typeName","wg.cosmo.node.v1.EngineEventConfiguration"),_(Eo,"fields",B.util.newFieldList(()=>[{no:1,name:"provider_id",kind:"scalar",T:9},{no:2,name:"type",kind:"enum",T:B.getEnumType(Uo)},{no:3,name:"type_name",kind:"scalar",T:9},{no:4,name:"field_name",kind:"scalar",T:9}]));var ko=Eo,ho=class ho extends Le{constructor(n){super();_(this,"nats",[]);_(this,"kafka",[]);_(this,"redis",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new ho().fromBinary(n,r)}static fromJson(n,r){return new ho().fromJson(n,r)}static fromJsonString(n,r){return new ho().fromJsonString(n,r)}static equals(n,r){return B.util.equals(ho,n,r)}};_(ho,"runtime",B),_(ho,"typeName","wg.cosmo.node.v1.DataSourceCustomEvents"),_(ho,"fields",B.util.newFieldList(()=>[{no:1,name:"nats",kind:"message",T:ff,repeated:!0},{no:2,name:"kafka",kind:"message",T:mf,repeated:!0},{no:3,name:"redis",kind:"message",T:Nf,repeated:!0}]));var Rc=ho,yo=class yo extends Le{constructor(n){super();_(this,"data");B.util.initPartial(n,this)}static fromBinary(n,r){return new yo().fromBinary(n,r)}static fromJson(n,r){return new yo().fromJson(n,r)}static fromJsonString(n,r){return new yo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(yo,n,r)}};_(yo,"runtime",B),_(yo,"typeName","wg.cosmo.node.v1.DataSourceCustom_Static"),_(yo,"fields",B.util.newFieldList(()=>[{no:1,name:"data",kind:"message",T:Mr}]));var MD=yo,Io=class Io extends Le{constructor(n){super();_(this,"kind",Iu.STATIC_CONFIGURATION_VARIABLE);_(this,"staticVariableContent","");_(this,"environmentVariableName","");_(this,"environmentVariableDefaultValue","");_(this,"placeholderVariableName","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Io().fromBinary(n,r)}static fromJson(n,r){return new Io().fromJson(n,r)}static fromJsonString(n,r){return new Io().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Io,n,r)}};_(Io,"runtime",B),_(Io,"typeName","wg.cosmo.node.v1.ConfigurationVariable"),_(Io,"fields",B.util.newFieldList(()=>[{no:1,name:"kind",kind:"enum",T:B.getEnumType(Iu)},{no:2,name:"static_variable_content",kind:"scalar",T:9},{no:3,name:"environment_variable_name",kind:"scalar",T:9},{no:4,name:"environment_variable_default_value",kind:"scalar",T:9},{no:5,name:"placeholder_variable_name",kind:"scalar",T:9}]));var Mr=Io,go=class go extends Le{constructor(n){super();_(this,"directiveName","");_(this,"renameTo","");B.util.initPartial(n,this)}static fromBinary(n,r){return new go().fromBinary(n,r)}static fromJson(n,r){return new go().fromJson(n,r)}static fromJsonString(n,r){return new go().fromJsonString(n,r)}static equals(n,r){return B.util.equals(go,n,r)}};_(go,"runtime",B),_(go,"typeName","wg.cosmo.node.v1.DirectiveConfiguration"),_(go,"fields",B.util.newFieldList(()=>[{no:1,name:"directive_name",kind:"scalar",T:9},{no:2,name:"rename_to",kind:"scalar",T:9}]));var xD=go,_o=class _o extends Le{constructor(n){super();_(this,"name","");_(this,"value","");B.util.initPartial(n,this)}static fromBinary(n,r){return new _o().fromBinary(n,r)}static fromJson(n,r){return new _o().fromJson(n,r)}static fromJsonString(n,r){return new _o().fromJsonString(n,r)}static equals(n,r){return B.util.equals(_o,n,r)}};_(_o,"runtime",B),_(_o,"typeName","wg.cosmo.node.v1.URLQueryConfiguration"),_(_o,"fields",B.util.newFieldList(()=>[{no:1,name:"name",kind:"scalar",T:9},{no:2,name:"value",kind:"scalar",T:9}]));var qD=_o,vo=class vo extends Le{constructor(n){super();_(this,"values",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new vo().fromBinary(n,r)}static fromJson(n,r){return new vo().fromJson(n,r)}static fromJsonString(n,r){return new vo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(vo,n,r)}};_(vo,"runtime",B),_(vo,"typeName","wg.cosmo.node.v1.HTTPHeader"),_(vo,"fields",B.util.newFieldList(()=>[{no:1,name:"values",kind:"message",T:Mr,repeated:!0}]));var VD=vo,So=class So extends Le{constructor(n){super();_(this,"key");_(this,"cert");_(this,"insecureSkipVerify",!1);B.util.initPartial(n,this)}static fromBinary(n,r){return new So().fromBinary(n,r)}static fromJson(n,r){return new So().fromJson(n,r)}static fromJsonString(n,r){return new So().fromJsonString(n,r)}static equals(n,r){return B.util.equals(So,n,r)}};_(So,"runtime",B),_(So,"typeName","wg.cosmo.node.v1.MTLSConfiguration"),_(So,"fields",B.util.newFieldList(()=>[{no:1,name:"key",kind:"message",T:Mr},{no:2,name:"cert",kind:"message",T:Mr},{no:3,name:"insecureSkipVerify",kind:"scalar",T:8}]));var jD=So,Oo=class Oo extends Le{constructor(n){super();_(this,"enabled",!1);_(this,"url");_(this,"useSSE");_(this,"protocol");_(this,"websocketSubprotocol");B.util.initPartial(n,this)}static fromBinary(n,r){return new Oo().fromBinary(n,r)}static fromJson(n,r){return new Oo().fromJson(n,r)}static fromJsonString(n,r){return new Oo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Oo,n,r)}};_(Oo,"runtime",B),_(Oo,"typeName","wg.cosmo.node.v1.GraphQLSubscriptionConfiguration"),_(Oo,"fields",B.util.newFieldList(()=>[{no:1,name:"enabled",kind:"scalar",T:8},{no:2,name:"url",kind:"message",T:Mr},{no:3,name:"useSSE",kind:"scalar",T:8,opt:!0},{no:4,name:"protocol",kind:"enum",T:B.getEnumType(bs),opt:!0},{no:5,name:"websocketSubprotocol",kind:"enum",T:B.getEnumType(As),opt:!0}]));var KD=Oo,Do=class Do extends Le{constructor(n){super();_(this,"enabled",!1);_(this,"serviceSdl","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Do().fromBinary(n,r)}static fromJson(n,r){return new Do().fromJson(n,r)}static fromJsonString(n,r){return new Do().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Do,n,r)}};_(Do,"runtime",B),_(Do,"typeName","wg.cosmo.node.v1.GraphQLFederationConfiguration"),_(Do,"fields",B.util.newFieldList(()=>[{no:1,name:"enabled",kind:"scalar",T:8},{no:2,name:"serviceSdl",kind:"scalar",T:9}]));var GD=Do,bo=class bo extends Le{constructor(n){super();_(this,"key","");B.util.initPartial(n,this)}static fromBinary(n,r){return new bo().fromBinary(n,r)}static fromJson(n,r){return new bo().fromJson(n,r)}static fromJsonString(n,r){return new bo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(bo,n,r)}};_(bo,"runtime",B),_(bo,"typeName","wg.cosmo.node.v1.InternedString"),_(bo,"fields",B.util.newFieldList(()=>[{no:1,name:"key",kind:"scalar",T:9}]));var Tf=bo,Ao=class Ao extends Le{constructor(n){super();_(this,"typeName","");_(this,"fieldName","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Ao().fromBinary(n,r)}static fromJson(n,r){return new Ao().fromJson(n,r)}static fromJsonString(n,r){return new Ao().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ao,n,r)}};_(Ao,"runtime",B),_(Ao,"typeName","wg.cosmo.node.v1.SingleTypeField"),_(Ao,"fields",B.util.newFieldList(()=>[{no:1,name:"type_name",kind:"scalar",T:9},{no:2,name:"field_name",kind:"scalar",T:9}]));var $D=Ao,Ro=class Ro extends Le{constructor(n){super();_(this,"fieldPath",[]);_(this,"json","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Ro().fromBinary(n,r)}static fromJson(n,r){return new Ro().fromJson(n,r)}static fromJsonString(n,r){return new Ro().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Ro,n,r)}};_(Ro,"runtime",B),_(Ro,"typeName","wg.cosmo.node.v1.SubscriptionFieldCondition"),_(Ro,"fields",B.util.newFieldList(()=>[{no:1,name:"field_path",kind:"scalar",T:9,repeated:!0},{no:2,name:"json",kind:"scalar",T:9}]));var Ef=Ro,Gi=class Gi extends Le{constructor(n){super();_(this,"and",[]);_(this,"in");_(this,"not");_(this,"or",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Gi().fromBinary(n,r)}static fromJson(n,r){return new Gi().fromJson(n,r)}static fromJsonString(n,r){return new Gi().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Gi,n,r)}};_(Gi,"runtime",B),_(Gi,"typeName","wg.cosmo.node.v1.SubscriptionFilterCondition"),_(Gi,"fields",B.util.newFieldList(()=>[{no:1,name:"and",kind:"message",T:Gi,repeated:!0},{no:2,name:"in",kind:"message",T:Ef,opt:!0},{no:3,name:"not",kind:"message",T:Gi,opt:!0},{no:4,name:"or",kind:"message",T:Gi,repeated:!0}]));var gu=Gi,Po=class Po extends Le{constructor(n){super();_(this,"operations",[]);B.util.initPartial(n,this)}static fromBinary(n,r){return new Po().fromBinary(n,r)}static fromJson(n,r){return new Po().fromJson(n,r)}static fromJsonString(n,r){return new Po().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Po,n,r)}};_(Po,"runtime",B),_(Po,"typeName","wg.cosmo.node.v1.CacheWarmerOperations"),_(Po,"fields",B.util.newFieldList(()=>[{no:1,name:"operations",kind:"message",T:QD,repeated:!0}]));var y1=Po,Fo=class Fo extends Le{constructor(n){super();_(this,"request");_(this,"client");B.util.initPartial(n,this)}static fromBinary(n,r){return new Fo().fromBinary(n,r)}static fromJson(n,r){return new Fo().fromJson(n,r)}static fromJsonString(n,r){return new Fo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Fo,n,r)}};_(Fo,"runtime",B),_(Fo,"typeName","wg.cosmo.node.v1.Operation"),_(Fo,"fields",B.util.newFieldList(()=>[{no:1,name:"request",kind:"message",T:YD},{no:2,name:"client",kind:"message",T:zD}]));var QD=Fo,wo=class wo extends Le{constructor(n){super();_(this,"operationName","");_(this,"query","");_(this,"extensions");B.util.initPartial(n,this)}static fromBinary(n,r){return new wo().fromBinary(n,r)}static fromJson(n,r){return new wo().fromJson(n,r)}static fromJsonString(n,r){return new wo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(wo,n,r)}};_(wo,"runtime",B),_(wo,"typeName","wg.cosmo.node.v1.OperationRequest"),_(wo,"fields",B.util.newFieldList(()=>[{no:1,name:"operation_name",kind:"scalar",T:9},{no:2,name:"query",kind:"scalar",T:9},{no:3,name:"extensions",kind:"message",T:JD}]));var YD=wo,Lo=class Lo extends Le{constructor(n){super();_(this,"persistedQuery");B.util.initPartial(n,this)}static fromBinary(n,r){return new Lo().fromBinary(n,r)}static fromJson(n,r){return new Lo().fromJson(n,r)}static fromJsonString(n,r){return new Lo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Lo,n,r)}};_(Lo,"runtime",B),_(Lo,"typeName","wg.cosmo.node.v1.Extension"),_(Lo,"fields",B.util.newFieldList(()=>[{no:1,name:"persisted_query",kind:"message",T:HD}]));var JD=Lo,Co=class Co extends Le{constructor(n){super();_(this,"sha256Hash","");_(this,"version",0);B.util.initPartial(n,this)}static fromBinary(n,r){return new Co().fromBinary(n,r)}static fromJson(n,r){return new Co().fromJson(n,r)}static fromJsonString(n,r){return new Co().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Co,n,r)}};_(Co,"runtime",B),_(Co,"typeName","wg.cosmo.node.v1.PersistedQuery"),_(Co,"fields",B.util.newFieldList(()=>[{no:1,name:"sha256_hash",kind:"scalar",T:9},{no:2,name:"version",kind:"scalar",T:5}]));var HD=Co,Bo=class Bo extends Le{constructor(n){super();_(this,"name","");_(this,"version","");B.util.initPartial(n,this)}static fromBinary(n,r){return new Bo().fromBinary(n,r)}static fromJson(n,r){return new Bo().fromJson(n,r)}static fromJsonString(n,r){return new Bo().fromJsonString(n,r)}static equals(n,r){return B.util.equals(Bo,n,r)}};_(Bo,"runtime",B),_(Bo,"typeName","wg.cosmo.node.v1.ClientInfo"),_(Bo,"fields",B.util.newFieldList(()=>[{no:1,name:"name",kind:"scalar",T:9},{no:2,name:"version",kind:"scalar",T:9}]));var zD=Bo;m();T();N();function WD(e){return new Error(`Normalization failed to return a ${e}.`)}function I1(e){return new Error(`Invalid router compatibility version "${e}".`)}m();T();N();var rd=ss(BE(),1);function Ede(e){if(!e.conditions)return;let t=[];for(let n of e.conditions){let r=[];for(let i of n.fieldCoordinatesPath){let a=i.split(".");if(a.length!==2)throw new Error(`fatal: malformed conditional field coordinates "${i}" for field set "${e.selectionSet}".`);r.push(new uf({fieldName:a[1],typeName:a[0]}))}t.push(new cf({fieldCoordinatesPath:r,fieldPath:n.fieldPath}))}return t}function XD(e,t,n){if(e)for(let r of e){let i=Ede(r);t.push(new Oc(x(x({typeName:n,fieldName:r.fieldName,selectionSet:r.selectionSet},r.disableEntityResolver?{disableEntityResolver:!0}:{}),i?{conditions:i}:{})))}}function ZD(e){switch(e){case"publish":return Uo.PUBLISH;case"request":return Uo.REQUEST;case"subscribe":return Uo.SUBSCRIBE}}function g1(e){var n;let t={rootNodes:[],childNodes:[],keys:[],provides:[],events:new Rc({nats:[],kafka:[],redis:[]}),requires:[],entityInterfaces:[],interfaceObjects:[]};for(let r of e.values()){let i=r.typeName,a=[...r.fieldNames],o=new ed({typeName:i,fieldNames:a});if(r.externalFieldNames&&r.externalFieldNames.size>0&&(o.externalFieldNames=[...r.externalFieldNames]),r.isRootNode?t.rootNodes.push(o):t.childNodes.push(o),r.entityInterfaceConcreteTypeNames){let f=new td({interfaceTypeName:i,concreteTypeNames:[...r.entityInterfaceConcreteTypeNames]});r.isInterfaceObject?t.interfaceObjects.push(f):t.entityInterfaces.push(f)}XD(r.keys,t.keys,i),XD(r.provides,t.provides,i),XD(r.requires,t.requires,i);let c=[],l=[],p=[];for(let f of(n=r.events)!=null?n:[])switch(f.providerType){case rd.PROVIDER_TYPE_KAFKA:{l.push(new mf({engineEventConfiguration:new ko({fieldName:f.fieldName,providerId:f.providerId,type:ZD(f.type),typeName:i}),topics:f.topics}));break}case rd.PROVIDER_TYPE_NATS:{c.push(new ff(x({engineEventConfiguration:new ko({fieldName:f.fieldName,providerId:f.providerId,type:ZD(f.type),typeName:i}),subjects:f.subjects},f.streamConfiguration?{streamConfiguration:new pf({consumerInactiveThreshold:f.streamConfiguration.consumerInactiveThreshold,consumerName:f.streamConfiguration.consumerName,streamName:f.streamConfiguration.streamName})}:{})));break}case rd.PROVIDER_TYPE_REDIS:{p.push(new Nf({engineEventConfiguration:new ko({fieldName:f.fieldName,providerId:f.providerId,type:ZD(f.type),typeName:i}),channels:f.channels}));break}default:throw new Error("Fatal: Unknown event provider.")}t.events.nats.push(...c),t.events.kafka.push(...l),t.events.redis.push(...p)}return t}function _1(e){var n,r;let t=[];for(let i of e){let a=i.argumentNames.map(f=>new af({name:f,sourceType:Dc.FIELD_ARGUMENT})),o=new of({argumentsConfiguration:a,fieldName:i.fieldName,typeName:i.typeName}),c=((n=i.requiredScopes)==null?void 0:n.map(f=>new Ac({requiredAndScopes:f})))||[],l=((r=i.requiredScopesByOR)==null?void 0:r.map(f=>new Ac({requiredAndScopes:f})))||[],p=c.length>0;if((i.requiresAuthentication||p)&&(o.authorizationConfiguration=new sf({requiresAuthentication:i.requiresAuthentication||p,requiredOrScopes:c,requiredOrScopesByOr:l})),i.subscriptionFilterCondition){let f=new gu;oh(f,i.subscriptionFilterCondition),o.subscriptionFilterCondition=f}t.push(o)}return t}function oh(e,t){if(t.and!==void 0){let n=[];for(let r of t.and){let i=new gu;oh(i,r),n.push(i)}e.and=n;return}if(t.in!==void 0){e.in=new Ef({fieldPath:t.in.fieldPath,json:JSON.stringify(t.in.values)});return}if(t.not!==void 0){e.not=new gu,oh(e.not,t.not);return}if(t.or!==void 0){let n=[];for(let r of t.or){let i=new gu;oh(i,r),n.push(i)}e.or=n;return}throw new Error("Fatal: Incoming SubscriptionCondition object was malformed.")}var Pc;(function(e){e[e.Plugin=0]="Plugin",e[e.Standard=1]="Standard",e[e.GRPC=2]="GRPC"})(Pc||(Pc={}));var hde=(e,t)=>{let n=stringHash(t);return e.stringStorage[n]=t,new Tf({key:n})},yde=e=>{switch(e){case"ws":return bs.GRAPHQL_SUBSCRIPTION_PROTOCOL_WS;case"sse":return bs.GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE;case"sse_post":return bs.GRAPHQL_SUBSCRIPTION_PROTOCOL_SSE_POST}},Ide=e=>{switch(e){case"auto":return As.GRAPHQL_WEBSOCKET_SUBPROTOCOL_AUTO;case"graphql-ws":return As.GRAPHQL_WEBSOCKET_SUBPROTOCOL_WS;case"graphql-transport-ws":return As.GRAPHQL_WEBSOCKET_SUBPROTOCOL_TRANSPORT_WS}},S1=function(e){if(!id.ROUTER_COMPATIBILITY_VERSIONS.has(e.routerCompatibilityVersion))throw I1(e.routerCompatibilityVersion);let t=new Zl({defaultFlushInterval:BigInt(500),datasourceConfigurations:[],fieldConfigurations:[],graphqlSchema:"",stringStorage:{},typeConfigurations:[]});for(let n of e.subgraphs){if(!n.configurationDataByTypeName)throw WD("ConfigurationDataByTypeName");if(!n.schema)throw WD("GraphQLSchema");let r={enabled:!0},i=hde(t,FV((0,v1.lexicographicSortSchema)(n.schema))),{childNodes:a,entityInterfaces:o,events:c,interfaceObjects:l,keys:p,provides:f,requires:y,rootNodes:g}=g1(n.configurationDataByTypeName),v;switch(n.kind){case Pc.Standard:{r.enabled=!0,r.protocol=yde(n.subscriptionProtocol||"ws"),r.websocketSubprotocol=Ide(n.websocketSubprotocol||"auto"),r.url=new Mr({kind:Iu.STATIC_CONFIGURATION_VARIABLE,staticVariableContent:n.subscriptionUrl||n.url});break}case Pc.Plugin:{v=new nd({mapping:n.mapping,protoSchema:n.protoSchema,plugin:new df({name:n.name,version:n.version,imageReference:n.imageReference})});break}case Pc.GRPC:{v=new nd({mapping:n.mapping,protoSchema:n.protoSchema});break}}let P,U,K;if(c.kafka.length>0||c.nats.length>0||c.redis.length>0){P=yu.PUBSUB,K=new Rc({kafka:c.kafka,nats:c.nats,redis:c.redis});let ne=pe=>id.ROOT_TYPE_NAMES.has(pe.typeName),z=0,Te=0;for(;z({id:n.id,name:n.name,routingUrl:n.url})),compatibilityVersion:`${e.routerCompatibilityVersion}:${id.COMPOSITION_VERSION}`})};m();T();N();var wc=ss(Ae());function O1(e){let t;try{t=(0,wc.parse)(e.schema)}catch(n){throw new Error(`could not parse schema for Graph ${e.name}: ${n}`)}return{definitions:t,name:e.name,url:e.url}}function gde(e){let t=(0,Fc.federateSubgraphs)({subgraphs:e.map(O1),version:Fc.LATEST_ROUTER_COMPATIBILITY_VERSION});if(!t.success)throw new Error(`could not federate schema: ${t.errors.map(n=>n.message).join(", ")}`);return{fieldConfigurations:t.fieldConfigurations,sdl:(0,wc.print)(t.federatedGraphAST)}}function _de(e){let t=(0,Fc.federateSubgraphs)({subgraphs:e.map(O1),version:Fc.LATEST_ROUTER_COMPATIBILITY_VERSION});if(!t.success)throw new Error(`could not federate schema: ${t.errors.map(r=>r.message).join(", ")}`);return S1({federatedClientSDL:(0,wc.printSchema)(t.federatedGraphClientSchema),federatedSDL:(0,wc.printSchema)(t.federatedGraphSchema),fieldConfigurations:t.fieldConfigurations,routerCompatibilityVersion:Fc.LATEST_ROUTER_COMPATIBILITY_VERSION,schemaVersionId:"",subgraphs:e.map((r,i)=>{var l,p;let a=t.subgraphConfigBySubgraphName.get(r.name),o=a==null?void 0:a.schema,c=a==null?void 0:a.configurationDataByTypeName;return{kind:Pc.Standard,id:`${i}`,name:r.name,url:sD(r.url),sdl:r.schema,subscriptionUrl:sD((l=r.subscription_url)!=null?l:r.url),subscriptionProtocol:(p=r.subscription_protocol)!=null?p:"ws",websocketSubprotocol:r.subscription_protocol==="ws"?r.websocketSubprotocol||"auto":void 0,schema:o,configurationDataByTypeName:c}})}).toJsonString()}return om(vde);})(); diff --git a/composition/src/errors/errors.ts b/composition/src/errors/errors.ts index a300e972ac..e508d67b36 100644 --- a/composition/src/errors/errors.ts +++ b/composition/src/errors/errors.ts @@ -847,9 +847,9 @@ export function undefinedEntityInterfaceImplementationsError( entityInterfaceFederationDataByTypeName: Map, ): Error { let message = - `Federation was unsuccessful because any one subgraph that defines a specific entity interface` + - ` must also define each and every entity object that implements that entity interface.\n - Each entity object must also each explicitly define the implementation of the entity interface.\n`; + `Federation was unsuccessful because any one subgraph that defines a specific entity Interface` + + ` must also define each and every entity Object that implements that entity Interface.\n + Each entity Object must also explicitly define its implementation of the entity Interface.\n`; for (const [typeName, undefinedImplementations] of invalidEntityInterfacesByTypeName) { const entityInterfaceDatas = getOrThrowError( entityInterfaceFederationDataByTypeName, diff --git a/composition/src/v1/federation/federation-factory.ts b/composition/src/v1/federation/federation-factory.ts index 9e02d6de25..b3ff679388 100644 --- a/composition/src/v1/federation/federation-factory.ts +++ b/composition/src/v1/federation/federation-factory.ts @@ -1682,7 +1682,7 @@ export class FederationFactory { if (!externalData) { continue; } - existingFieldData.externalFieldDataBySubgraphName.set(subgraphName, externalData); + existingFieldData.externalFieldDataBySubgraphName.set(subgraphName, { ...externalData }); continue; } const isInaccessible = From c9cfa9af021f447b3b3c82ff42c477fa235c374e Mon Sep 17 00:00:00 2001 From: Aenimus Date: Fri, 15 Aug 2025 21:37:32 +0100 Subject: [PATCH 3/3] chore: fix typos --- composition-go/index.global.js | 3 +-- composition/src/errors/errors.ts | 4 ++-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/composition-go/index.global.js b/composition-go/index.global.js index 681f4df2d1..789c0acfc8 100644 --- a/composition-go/index.global.js +++ b/composition-go/index.global.js @@ -323,8 +323,7 @@ For federation, it is only possible to use the default root types names ("Mutati "${e}" This is because of the selection set corresponding to the `+ZT(t,n,We.UNION)+` Union types such as "${n}" must define field selections (besides "__typename") on an inline fragment whose type condition corresponds to a constituent union member.`}function fie(e,t){return` The field "${e}" declares an @override directive in the following subgraphs: "`+t.join(We.QUOTATION_JOIN)+'".'}function mie(e){return new Error('The "@override" directive must only be declared on one single instance of a field. However, an "@override" directive was declared on more than one instance of the following field'+(e.length>1?"s":"")+': "'+e.join(We.QUOTATION_JOIN)+`". `)}function Nie(e,t){return new Error(`The ${e} "${t}" is invalid because it does not define any fields.`)}function Tie(e){return new Error(`The Input Object "${e}" is invalid because it does not define any input values.`)}function Eie(e,t,n){return new Error(`The ${e} "${t}" is invalid because all its ${n} definitions are declared "@inaccessible".`)}function hie(e,t){return`Cannot override field "${t}" because the source and target subgraph names are both "${e}"`}function yie(e,t){let n=`Federation was unsuccessful because any one subgraph that defines a specific entity Interface must also define each and every entity Object that implements that entity Interface. - - Each entity Object must also explicitly define its implementation of the entity Interface. +Each entity Object must also explicitly define its implementation of the entity Interface. `;for(let[r,i]of e){let o=(0,Vl.getOrThrowError)(t,r,"entityInterfaceFederationDataByTypeName").concreteTypeNames;n+=` Across all subgraphs, the entity interface "${r}" is implemented by the following entit`+(o.size>1?"ies":"y")+`: "`+Array.from(o).join(We.QUOTATION_JOIN)+`" However, the definition of at least one of these implementations is missing in a subgraph that defines the entity interface "${r}": diff --git a/composition/src/errors/errors.ts b/composition/src/errors/errors.ts index e508d67b36..9a1cc896d8 100644 --- a/composition/src/errors/errors.ts +++ b/composition/src/errors/errors.ts @@ -848,8 +848,8 @@ export function undefinedEntityInterfaceImplementationsError( ): Error { let message = `Federation was unsuccessful because any one subgraph that defines a specific entity Interface` + - ` must also define each and every entity Object that implements that entity Interface.\n - Each entity Object must also explicitly define its implementation of the entity Interface.\n`; + ` must also define each and every entity Object that implements that entity Interface.\n` + + `Each entity Object must also explicitly define its implementation of the entity Interface.\n`; for (const [typeName, undefinedImplementations] of invalidEntityInterfacesByTypeName) { const entityInterfaceDatas = getOrThrowError( entityInterfaceFederationDataByTypeName,